:root {
    --primary: #1877F2;
    --primary-dark: #0f5dc2;
    --primary-deeper: #0a3f88;
    --accent: #10b981;
    --accent-dark: #059669;
    --bg-body: #f4f7fb;
    --bg-card: #ffffff;
    --text-main: #0f172a;
    --text-muted: #475569;
    --text-light: #64748b;
    --border-color: #e2e8f0;
    --shadow-sm: 0 2px 8px rgba(15, 23, 42, 0.05);
    --shadow-md: 0 10px 30px rgba(24, 119, 242, 0.12);
    --shadow-lg: 0 20px 45px rgba(15, 23, 42, 0.1);
    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 20px;
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--bg-body);
    color: var(--text-main);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    color: var(--primary-dark);
}

.container {
    width: 100%;
    max-width: 1120px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header & Navigation */
.site-header {
    background: #ffffff;
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.03);
}

.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 70px;
}

.brand-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    font-size: 1.35rem;
    color: var(--text-main);
    letter-spacing: -0.02em;
}

.brand-logo:hover {
    color: var(--primary);
}

.logo-icon {
    width: 40px;
    height: 40px;
    border-radius: 11px;
    background: linear-gradient(135deg, #1877F2 0%, #0b5cff 100%);
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(24, 119, 242, 0.3);
}

.logo-text small {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--primary);
    margin-left: 1px;
}

.site-nav {
    display: flex;
    align-items: center;
    gap: 6px;
}

.nav-link {
    color: var(--text-muted);
    font-weight: 600;
    font-size: 0.93rem;
    padding: 8px 14px;
    border-radius: 9px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary);
    background: rgba(24, 119, 242, 0.08);
}

.badge-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--accent);
    display: inline-block;
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 7px;
    cursor: pointer;
    color: var(--text-main);
}

/* Hero Downloader Box (DownVideo style) */
.hero-section {
    background: linear-gradient(135deg, #1877F2 0%, #0d47a1 100%);
    color: #ffffff;
    padding: 56px 0 68px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: -120px;
    right: -120px;
    width: 360px;
    height: 360px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255,255,255,0.14) 0%, rgba(255,255,255,0) 70%);
    pointer-events: none;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.25);
    padding: 6px 15px;
    border-radius: 999px;
    font-size: 0.84rem;
    font-weight: 600;
    margin-bottom: 18px;
    backdrop-filter: blur(4px);
}

.hero-title {
    font-size: clamp(1.85rem, 4vw, 2.75rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    margin-bottom: 12px;
    line-height: 1.2;
}

.hero-subtitle {
    font-size: 1.05rem;
    color: rgba(255, 255, 255, 0.9);
    max-width: 680px;
    margin: 0 auto 28px;
}

/* Downloader Search Box */
.downloader-card {
    max-width: 820px;
    margin: 0 auto;
    background: #ffffff;
    padding: 10px;
    border-radius: 16px;
    box-shadow: 0 18px 40px rgba(7, 29, 73, 0.28);
}

.downloader-form {
    display: flex;
    align-items: stretch;
    gap: 8px;
}

.input-wrapper {
    position: relative;
    flex: 1;
    display: flex;
    align-items: center;
}

.input-icon {
    position: absolute;
    left: 16px;
    color: #94a3b8;
    display: flex;
    align-items: center;
    pointer-events: none;
}

.url-input {
    width: 100%;
    height: 58px;
    padding: 0 105px 0 46px;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    font-size: 1rem;
    color: var(--text-main);
    font-family: inherit;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    outline: none;
}

.url-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(24, 119, 242, 0.12);
}

.btn-paste {
    position: absolute;
    right: 8px;
    height: 42px;
    padding: 0 14px;
    border: 1px solid #cbd5e1;
    background: #f8fafc;
    color: #334155;
    border-radius: 9px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.15s ease;
}

.btn-paste:hover {
    background: #e2e8f0;
    color: var(--text-main);
}

.btn-download-submit {
    height: 58px;
    padding: 0 28px;
    border: none;
    border-radius: 12px;
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: #ffffff;
    font-size: 1.05rem;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    white-space: nowrap;
    box-shadow: 0 8px 20px rgba(16, 185, 129, 0.35);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.btn-download-submit:hover {
    transform: translateY(-1px);
    box-shadow: 0 12px 24px rgba(16, 185, 129, 0.45);
}

.btn-download-submit:disabled {
    opacity: 0.7;
    cursor: wait;
    transform: none;
}

.hero-Supported-pills {
    margin-top: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 16px;
    font-size: 0.87rem;
    color: rgba(255, 255, 255, 0.88);
}

.hero-Supported-pills span {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

/* Loading & Alert States */
.result-wrapper {
    max-width: 860px;
    margin: -28px auto 30px;
    position: relative;
    z-index: 10;
}

.loader-box {
    display: none;
    background: #ffffff;
    border-radius: var(--radius-md);
    padding: 32px 24px;
    text-align: center;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border-color);
}

.spinner {
    width: 46px;
    height: 46px;
    border: 4px solid #e2e8f0;
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin: 0 auto 14px;
}

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

.alert-box {
    background: #fff1f2;
    border: 1px solid #fecdd3;
    color: #be123c;
    padding: 18px 22px;
    border-radius: var(--radius-md);
    margin-top: 18px;
    box-shadow: var(--shadow-sm);
    text-align: left;
}

.alert-box.alert-success {
    background: #ecfdf5;
    border-color: #a7f3d0;
    color: #047857;
}

/* Video Result Card */
.video-result-card {
    background: #ffffff;
    border-radius: var(--radius-lg);
    padding: 26px;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border-color);
    margin-top: 18px;
}

.video-result-grid {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 26px;
    align-items: start;
}

.video-thumb-box {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    background: #0f172a;
    aspect-ratio: 16 / 10;
    display: flex;
    align-items: center;
    justify-content: center;
}

.video-thumb-box img,
.video-thumb-box video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.duration-badge {
    position: absolute;
    bottom: 10px;
    right: 10px;
    background: rgba(15, 23, 42, 0.84);
    color: #fff;
    padding: 3px 9px;
    border-radius: 6px;
    font-size: 0.78rem;
    font-weight: 700;
}

.video-meta-title {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text-main);
    margin-bottom: 6px;
    line-height: 1.4;
}

.video-meta-author {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 18px;
}

.streams-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 14px;
}

.streams-table th,
.streams-table td {
    padding: 12px 14px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.streams-table th {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--text-light);
    background: #f8fafc;
}

.badge-quality {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 800;
    margin-left: 6px;
}

.badge-hd {
    background: #dbeafe;
    color: #1d4ed8;
}

.badge-sd {
    background: #f1f5f9;
    color: #475569;
}

.badge-audio {
    background: #fef3c7;
    color: #b45309;
}

.btn-dl-row {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    background: var(--primary);
    color: #ffffff;
    font-weight: 600;
    font-size: 0.88rem;
    padding: 9px 16px;
    border-radius: 8px;
    transition: background 0.15s ease, transform 0.15s ease;
}

.btn-dl-row:hover {
    background: var(--primary-dark);
    color: #ffffff;
    transform: translateY(-1px);
}

.btn-dl-row.btn-dl-hd {
    background: linear-gradient(135deg, #1877F2 0%, #0d5bd9 100%);
}

/* Ad Placeholders */
.ad-container {
    text-align: center;
    margin: 20px 0;
}

.ad-placeholder {
    background: #f8fafc;
    border: 1.5px dashed #cbd5e1;
    border-radius: 12px;
    padding: 18px;
    text-align: center;
    color: #64748b;
    font-size: 0.88rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin: 22px 0;
}

.ad-badge {
    background: #e2e8f0;
    color: #475569;
    font-weight: 700;
    font-size: 0.72rem;
    padding: 2px 7px;
    border-radius: 4px;
}

/* Content Sections */
.section-block {
    padding: 46px 0;
}

.section-header {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 38px;
}

.section-header h2 {
    font-size: 1.85rem;
    font-weight: 800;
    color: var(--text-main);
    margin-bottom: 10px;
    letter-spacing: -0.02em;
}

.section-header p {
    color: var(--text-muted);
    font-size: 1rem;
}

/* 3-Step Guide Grid */
.steps-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.step-card {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 28px 24px;
    box-shadow: var(--shadow-sm);
    position: relative;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.step-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.step-number {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: rgba(24, 119, 242, 0.1);
    color: var(--primary);
    font-weight: 800;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
}

.step-card h3 {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.step-card p {
    color: var(--text-muted);
    font-size: 0.94rem;
}

/* Features Grid */
.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
}

.feature-item {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 24px;
    box-shadow: var(--shadow-sm);
}

.feature-icon {
    width: 46px;
    height: 46px;
    border-radius: 12px;
    background: #eff6ff;
    color: var(--primary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 14px;
}

.feature-item h3 {
    font-size: 1.08rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.feature-item p {
    color: var(--text-muted);
    font-size: 0.92rem;
}

/* FAQ Accordion */
.faq-list {
    max-width: 820px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

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

.faq-question {
    width: 100%;
    background: none;
    border: none;
    padding: 18px 22px;
    text-align: left;
    font-size: 1.02rem;
    font-weight: 700;
    color: var(--text-main);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-family: inherit;
}

.faq-question:hover {
    color: var(--primary);
}

.faq-answer {
    display: none;
    padding: 0 22px 18px;
    color: var(--text-muted);
    font-size: 0.95rem;
    border-top: 1px solid #f1f5f9;
}

.faq-item.open .faq-answer {
    display: block;
    padding-top: 14px;
}

/* Private Downloader Form Styles */
.private-box {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 32px;
    max-width: 840px;
    margin: -34px auto 30px;
    box-shadow: var(--shadow-lg);
    position: relative;
    z-index: 10;
}

.form-group {
    margin-bottom: 20px;
    text-align: left;
}

.form-label {
    display: block;
    font-weight: 700;
    font-size: 0.95rem;
    margin-bottom: 8px;
    color: var(--text-main);
}

.form-control {
    width: 100%;
    padding: 12px 16px;
    border: 1.5px solid #cbd5e1;
    border-radius: 10px;
    font-size: 0.95rem;
    font-family: inherit;
    color: var(--text-main);
    outline: none;
    transition: border-color 0.2s ease;
}

.form-control:focus {
    border-color: var(--primary);
}

textarea.form-control {
    min-height: 150px;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    font-size: 0.85rem;
    resize: vertical;
}

.copy-row {
    display: flex;
    gap: 10px;
}

.btn-secondary {
    background: #0f172a;
    color: #fff;
    border: none;
    border-radius: 10px;
    padding: 0 20px;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
}

.btn-secondary:hover {
    background: #1e293b;
}

/* Content Page Card */
.page-card {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 36px;
    margin: 36px auto;
    max-width: 860px;
    box-shadow: var(--shadow-sm);
}

.page-card h1 {
    font-size: 2rem;
    margin-bottom: 16px;
}

.page-card h2 {
    font-size: 1.35rem;
    margin: 24px 0 10px;
}

.page-card p,
.page-card li {
    color: var(--text-muted);
    margin-bottom: 12px;
}

.page-card ul,
.page-card ol {
    padding-left: 22px;
    margin-bottom: 16px;
}

/* Footer */
.site-footer {
    background: #0f172a;
    color: #cbd5e1;
    padding: 56px 0 32px;
    margin-top: 50px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 40px;
    padding-bottom: 36px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-logo .logo-text {
    color: #ffffff;
}

.footer-desc {
    margin-top: 14px;
    color: #94a3b8;
    font-size: 0.92rem;
    max-width: 420px;
}

.footer-links-col h4 {
    color: #ffffff;
    font-size: 1rem;
    margin-bottom: 14px;
}

.footer-links-col ul {
    list-style: none;
}

.footer-links-col li {
    margin-bottom: 9px;
}

.footer-links-col a {
    color: #94a3b8;
    font-size: 0.92rem;
}

.footer-links-col a:hover {
    color: #ffffff;
}

.footer-bottom {
    padding-top: 24px;
    text-align: center;
    font-size: 0.88rem;
    color: #94a3b8;
}

.disclaimer-note {
    margin-top: 8px;
    font-size: 0.8rem;
    color: #64748b;
}

/* Responsive */
@media (max-width: 820px) {
    .mobile-menu-btn {
        display: inline-flex;
    }

    .site-nav {
        display: none;
        position: absolute;
        top: 70px;
        left: 0;
        right: 0;
        background: #ffffff;
        flex-direction: column;
        padding: 16px;
        border-bottom: 1px solid var(--border-color);
        box-shadow: var(--shadow-md);
    }

    .site-nav.open {
        display: flex;
    }

    .nav-link {
        width: 100%;
    }

    .downloader-form {
        flex-direction: column;
    }

    .btn-download-submit {
        width: 100%;
    }

    .video-result-grid {
        grid-template-columns: 1fr;
    }

    .steps-grid,
    .features-grid,
    .footer-grid {
        grid-template-columns: 1fr;
    }
}
