* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #6c5ce7;
    --primary-dark: #5a4bd1;
    --secondary: #00cec9;
    --bg-dark: #0a0a1a;
    --bg-card: #12122a;
    --bg-card-hover: #1a1a3e;
    --text-primary: #ffffff;
    --text-secondary: #a0a0c0;
    --gradient-1: linear-gradient(135deg, #6c5ce7, #00cec9);
    --gradient-2: linear-gradient(135deg, #fd79a8, #6c5ce7);
    --border: rgba(108, 92, 231, 0.2);
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: var(--bg-dark);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Animated Background */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 50%, rgba(108, 92, 231, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(0, 206, 201, 0.08) 0%, transparent 50%),
        radial-gradient(circle at 50% 80%, rgba(253, 121, 168, 0.06) 0%, transparent 50%);
    z-index: -1;
}

/* Header */
.header {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(10, 10, 26, 0.95);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
    z-index: 1000;
}

.nav {
    max-width: 1200px;
    margin: 0 auto;
    padding: 15px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    text-decoration: none;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 8px;
}

.logo-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: var(--gradient-1);
    border-radius: 8px;
    font-size: 1rem;
}

.pro {
    background: var(--gradient-2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 30px;
}

.nav-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
    font-size: 0.95rem;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--text-primary);
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 1.5rem;
    cursor: pointer;
}

/* Hero Section */
.hero {
    padding: 140px 20px 60px;
    text-align: center;
}

.hero h1 {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 20px;
    line-height: 1.2;
}

.highlight {
    background: var(--gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.15rem;
    color: var(--text-secondary);
    max-width: 700px;
    margin: 0 auto;
}

/* Downloader Section */
.downloader-section {
    padding: 0 20px 40px;
    max-width: 800px;
    margin: 0 auto;
}

.downloader-box {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 30px;
    box-shadow: var(--shadow);
}

.input-group {
    display: flex;
    gap: 12px;
    margin-bottom: 15px;
}

.input-group input {
    flex: 1;
    padding: 16px 20px;
    font-size: 1rem;
    border: 2px solid var(--border);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
    outline: none;
    transition: border-color 0.3s;
}

.input-group input:focus {
    border-color: var(--primary);
}

.input-group input::placeholder {
    color: var(--text-secondary);
}

.input-group button {
    padding: 16px 32px;
    font-size: 1rem;
    font-weight: 600;
    border: none;
    border-radius: 12px;
    background: var(--gradient-1);
    color: white;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    white-space: nowrap;
    min-width: 160px;
}

.input-group button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(108, 92, 231, 0.4);
}

.spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255,255,255,0.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 0.8s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.supported-sites {
    text-align: center;
    color: var(--text-secondary);
    font-size: 0.85rem;
}

/* Ad Containers */
.ad-container {
    text-align: center;
    padding: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.ad-banner {
    margin-top: 20px;
}

/* Features Section */
.features {
    padding: 80px 20px;
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
}

.features h2,
.how-it-works h2,
.faq-section h2 {
    font-size: 2rem;
    margin-bottom: 50px;
    background: var(--gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
}

.feature-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 35px 25px;
    text-align: center;
    transition: transform 0.3s, border-color 0.3s;
}

.feature-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary);
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 15px;
}

.feature-card h3 {
    font-size: 1.2rem;
    margin-bottom: 12px;
    color: var(--text-primary);
}

.feature-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* How It Works */
.how-it-works {
    padding: 80px 20px;
    max-width: 1000px;
    margin: 0 auto;
    text-align: center;
}

.steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    margin-top: 20px;
}

.step {
    text-align: center;
}

.step-number {
    width: 60px;
    height: 60px;
    background: var(--gradient-1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 auto 20px;
}

.step h3 {
    margin-bottom: 10px;
}

.step p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* Video Result */
.video-result {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    padding: 20px;
}

.result-box {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 35px;
    max-width: 700px;
    width: 100%;
    max-height: 85vh;
    overflow-y: auto;
    position: relative;
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from { transform: translateY(30px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.close-btn {
    position: absolute;
    top: 15px;
    right: 20px;
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 1.8rem;
    cursor: pointer;
    transition: color 0.3s;
}

.close-btn:hover {
    color: var(--text-primary);
}

.video-info {
    display: flex;
    gap: 20px;
    margin-bottom: 25px;
}

.video-info img {
    width: 200px;
    height: 120px;
    object-fit: cover;
    border-radius: 12px;
    border: 1px solid var(--border);
}

.video-details h3 {
    font-size: 1.1rem;
    margin-bottom: 8px;
    line-height: 1.4;
}

.video-details p {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.quality-section,
.audio-section {
    margin-top: 20px;
}

.quality-section h4,
.audio-section h4 {
    font-size: 1rem;
    margin-bottom: 15px;
    color: var(--secondary);
}

.formats-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.format-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 12px 18px;
    transition: border-color 0.3s, background 0.3s;
}

.format-item:hover {
    border-color: var(--primary);
    background: rgba(108, 92, 231, 0.1);
}

.format-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.format-quality {
    font-weight: 600;
    min-width: 70px;
}

.format-ext {
    background: var(--gradient-1);
    padding: 3px 10px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.format-size {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.format-item .download-btn {
    padding: 8px 20px;
    font-size: 0.9rem;
    font-weight: 600;
    border: none;
    border-radius: 8px;
    background: var(--gradient-1);
    color: white;
    cursor: pointer;
    transition: transform 0.2s;
}

.format-item .download-btn:hover {
    transform: scale(1.05);
}

/* FAQ Section */
.faq-section {
    padding: 80px 20px;
    max-width: 800px;
    margin: 0 auto;
}

.faq-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.faq-item {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
}

.faq-question {
    width: 100%;
    padding: 18px 24px;
    font-size: 1rem;
    font-weight: 600;
    background: none;
    border: none;
    color: var(--text-primary);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    text-align: left;
}

.faq-icon {
    font-size: 1.3rem;
    color: var(--secondary);
    transition: transform 0.3s;
}

.faq-answer {
    padding: 0 24px;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s, padding 0.3s;
    color: var(--text-secondary);
}

.faq-item.active .faq-answer {
    padding: 0 24px 18px;
    max-height: 200px;
}

.faq-item.active .faq-icon {
    transform: rotate(45deg);
}

/* Footer */
.footer {
    background: rgba(0, 0, 0, 0.3);
    border-top: 1px solid var(--border);
    margin-top: 60px;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 50px 20px 30px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
}

.footer-section h4 {
    margin-bottom: 20px;
    font-size: 1.1rem;
    background: var(--gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.footer-section p {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 10px;
}

.footer-section ul a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.3s;
}

.footer-section ul a:hover {
    color: var(--text-primary);
}

.footer-bottom {
    text-align: center;
    padding: 20px;
    border-top: 1px solid var(--border);
    color: var(--text-secondary);
    font-size: 0.85rem;
}

/* Error/Success Toast */
.toast {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    padding: 14px 28px;
    border-radius: 12px;
    font-weight: 500;
    z-index: 3000;
    animation: fadeInUp 0.3s ease;
    max-width: 90%;
    text-align: center;
}

.toast.error {
    background: #e74c3c;
    color: white;
}

.toast.success {
    background: #00b894;
    color: white;
}

@keyframes fadeInUp {
    from { transform: translateX(-50%) translateY(20px); opacity: 0; }
    to { transform: translateX(-50%) translateY(0); opacity: 1; }
}

/* Responsive */
@media (max-width: 768px) {
    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: rgba(10, 10, 26, 0.98);
        flex-direction: column;
        padding: 20px;
        gap: 15px;
        border-bottom: 1px solid var(--border);
    }

    .nav-links.active {
        display: flex;
    }

    .menu-toggle {
        display: block;
    }

    .hero {
        padding: 120px 15px 40px;
    }

    .hero h1 {
        font-size: 1.6rem;
    }

    .hero-subtitle {
        font-size: 0.95rem;
    }

    .downloader-box {
        padding: 20px 15px;
    }

    .input-group {
        flex-direction: column;
        gap: 10px;
    }

    .input-group input {
        padding: 14px 16px;
        font-size: 0.9rem;
    }

    .input-group button {
        width: 100%;
        padding: 14px;
        min-width: unset;
    }

    .features {
        padding: 50px 15px;
    }

    .features h2,
    .how-it-works h2,
    .faq-section h2 {
        font-size: 1.5rem;
        margin-bottom: 30px;
    }

    .features-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .feature-card {
        padding: 25px 20px;
    }

    .how-it-works {
        padding: 50px 15px;
    }

    .steps {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .faq-section {
        padding: 50px 15px;
    }

    .video-result {
        padding: 10px;
        align-items: flex-end;
    }

    .result-box {
        padding: 25px 20px;
        border-radius: 16px 16px 0 0;
        max-height: 90vh;
    }

    .video-info {
        flex-direction: column;
        gap: 15px;
    }

    .video-info img {
        width: 100%;
        height: auto;
    }

    .format-item {
        flex-direction: column;
        gap: 10px;
        padding: 14px;
    }

    .format-info {
        width: 100%;
        justify-content: space-between;
    }

    .format-item .download-btn {
        width: 100%;
        padding: 12px;
    }

    .page-content {
        margin: 100px auto 40px;
        padding: 25px 15px;
    }

    .page-content h1 {
        font-size: 1.6rem;
    }

    .page-content h2 {
        font-size: 1.2rem;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 30px;
        padding: 40px 15px 20px;
    }

    .footer-section {
        text-align: center;
    }

    .ad-container {
        padding: 10px;
    }
}

@media (max-width: 480px) {
    .hero h1 {
        font-size: 1.4rem;
    }

    .hero-subtitle {
        font-size: 0.85rem;
    }

    .downloader-box {
        padding: 15px 12px;
    }

    .input-group input {
        padding: 12px 14px;
        font-size: 0.85rem;
    }

    .feature-icon {
        font-size: 2.5rem;
    }

    .step-number {
        width: 50px;
        height: 50px;
        font-size: 1.2rem;
    }

    .result-box {
        padding: 20px 15px;
    }

    .video-details h3 {
        font-size: 0.95rem;
    }
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-dark);
}

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 4px;
}

/* Placeholder Pages */
.page-content {
    max-width: 800px;
    margin: 120px auto 60px;
    padding: 40px 20px;
}

.page-content h1 {
    font-size: 2.2rem;
    margin-bottom: 30px;
    background: var(--gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.page-content h2 {
    font-size: 1.4rem;
    margin: 25px 0 12px;
    color: var(--secondary);
}

.page-content p,
.page-content li {
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: 12px;
}

.page-content ul {
    padding-left: 20px;
}

.page-content a {
    color: var(--primary);
    text-decoration: none;
}

.page-content a:hover {
    text-decoration: underline;
}
