/* ==========================================================================
   Responsive Design
   ========================================================================== */

@media (max-width: 1400px) {
    .pricing-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 1200px) {
    .pricing-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 1024px) {
    .hero-title {
        font-size: 36px;
        line-height: 44px;
    }

    .hook-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .feature-header {
        flex-direction: column;
    }

    .posts-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-links {
        grid-template-columns: repeat(2, 1fr);
    }

    .cta-card {
        flex-direction: column;
        text-align: center;
    }

    .cta-content {
        max-width: 100%;
        margin-bottom: var(--spacing-2xl);
    }
}

@media (max-width: 768px) {
    /* Mobile header - floating pill design per Figma */
    .site-header {
        padding: 8px 0;
    }

    .home-template .site-header {
        top: 43px;
    }

    .header-container {
        display: flex;
        justify-content: center;
        padding: 0 18px;
    }

    .header-nav {
        width: 100%;
        max-width: 413px;
        padding: 12px 17px;
        border-radius: 30px;
        gap: 0;
        justify-content: space-between;
    }

    .header-logo img {
        height: 40px;
    }

    .header-menu {
        display: none;
    }

    .header-actions {
        gap: 12px;
    }

    .header-actions .btn-login {
        display: block;
        padding: 8px 16px;
        font-size: 14px;
    }

    .header-actions .theme-toggle {
        display: none;
    }

    .mobile-menu-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
        padding: 4px;
    }

    .hamburger {
        width: 20px;
        height: 2px;
    }

    .hamburger::before { top: -6px; }
    .hamburger::after { top: 6px; }

    /* Mobile nav - expanding pill design */
    .mobile-nav {
        display: none;
        position: fixed;
        top: 8px;
        left: 50%;
        transform: translateX(-50%);
        width: calc(100% - 36px);
        max-width: 413px;
        background: rgba(255, 255, 255, 0.95);
        backdrop-filter: blur(5px);
        -webkit-backdrop-filter: blur(5px);
        border: 2px solid var(--color-white);
        border-radius: 30px;
        z-index: 101;
        padding: 12px 17px 20px;
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    }

    .home-template .mobile-nav {
        top: 51px;
    }

    .mobile-nav.active {
        display: block;
    }

    .mobile-nav-header {
        display: flex;
        align-items: center;
        justify-content: space-between;
        margin-bottom: 16px;
    }

    .mobile-nav-header .header-logo img {
        height: 40px;
    }

    .mobile-nav-close {
        background: none;
        border: none;
        cursor: pointer;
        padding: 4px;
        font-size: 20px;
        color: var(--color-text);
        line-height: 1;
    }

    .mobile-nav-list {
        display: flex;
        flex-direction: column;
        gap: 8px;
        list-style: none;
        padding: 0;
        margin: 0;
    }

    .mobile-nav-list a {
        display: block;
        padding: 12px 0;
        font-size: 20px;
        font-weight: var(--font-regular);
        color: #3d3d3d;
        text-decoration: none;
    }

    .mobile-nav-list a:hover {
        color: var(--color-primary);
    }

    .mobile-nav-list .btn {
        margin-top: 8px;
    }

    /* Hide header when mobile nav is open */
    body.mobile-nav-open .site-header {
        visibility: hidden;
    }

    /* Hero badges - mobile per Figma */
    .hero-badges {
        flex-direction: column;
        align-items: center;
        gap: 20px;
    }

    .hero-badge {
        padding: 5px 15px;
        border-radius: 67px;
    }

    .hero-badge span {
        font-size: 16px;
    }

    /* Hero title - mobile per Figma (48px/60px) */
    .hero-title {
        font-size: 48px;
        line-height: 60px;
    }

    /* Hero subtitle - mobile per Figma */
    .hero-subtitle {
        font-size: 16px;
        color: #58556c;
    }

    .hero-ctas {
        flex-direction: column;
        align-items: center;
        gap: 16px;
    }

    /* CTA buttons - mobile per Figma (fixed widths) */
    .btn-trial {
        width: 260px;
        height: 67px;
        justify-content: center;
        font-size: 16px;
        padding: 8px 7px 8px 24px;
        gap: 32px;
    }

    .btn-trial .play-icon {
        width: 40px;
        height: 40px;
    }

    .btn-browse {
        width: 217px;
        height: 54px;
        justify-content: center;
        font-size: 16px;
        padding: 8px 22px;
        gap: 20px;
    }

    /* Feature tabs - mobile slider per Figma */
    .feature-tabs-container {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 8px;
        width: 100%;
        max-width: 398px;
        margin: 0 auto;
    }

    .feature-tabs-arrow {
        display: flex !important;
        align-items: center;
        justify-content: center;
        width: 32px;
        height: 32px;
        background: rgba(255, 255, 255, 0.8);
        border: none;
        border-radius: 50%;
        cursor: pointer;
        flex-shrink: 0;
        color: #58556c;
        transition: background 0.2s, color 0.2s;
    }

    .feature-tabs-arrow:hover {
        background: var(--color-white);
        color: var(--color-primary);
    }

    .feature-tabs-arrow svg {
        width: 8px;
        height: 14px;
    }

    .feature-tabs {
        display: flex;
        overflow-x: auto;
        overflow-y: hidden;
        background: rgba(255, 255, 255, 0.5);
        border: 1px solid var(--color-white);
        border-radius: 11px;
        padding: 5px;
        flex: 1;
        max-width: 320px;
        gap: 0;
        scroll-behavior: smooth;
        -ms-overflow-style: none;
        scrollbar-width: none;
    }

    .feature-tabs::-webkit-scrollbar {
        display: none;
    }

    .hero-showcase .feature-tab {
        flex-shrink: 0;
        white-space: nowrap;
        font-size: 14px;
        padding: 5px 8px;
    }

    .hook-grid,
    .pricing-grid,
    .posts-grid {
        grid-template-columns: 1fr;
    }

    .pricing-card {
        margin: 20px 0 0;
    }

    .footer-top {
        flex-direction: column;
        gap: var(--spacing-xl);
    }

    .footer-links {
        grid-template-columns: 1fr;
        gap: var(--spacing-xl);
    }

    .footer-bottom {
        flex-direction: column;
        gap: var(--spacing-lg);
        text-align: center;
    }

    .section-title {
        font-size: 28px;
    }

    .faq-question h3 {
        font-size: 18px;
    }

    .review-platforms {
        flex-direction: column;
        align-items: center;
    }

    .testimonial-card {
        min-width: 300px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 var(--spacing-md);
    }

    .site-footer {
        margin: 0 var(--spacing-md);
        padding: var(--spacing-2xl) var(--spacing-lg);
    }

    .hero-title {
        font-size: 28px;
        line-height: 36px;
    }

    .post-title {
        font-size: 28px;
    }
}

/* ==========================================================================
   Dark Mode Support
   ========================================================================== */

body.dark-mode {
    --color-bg: #1a1a2e;
    --color-bg-light: #16213e;
    --color-text: #e0e0e0;
    --color-text-muted: #a0a0a0;
    --color-black: #ffffff;
    --color-border: #3d3d5c;
}

body.dark-mode .header-nav {
    background: rgba(26, 26, 46, 0.8);
    border-color: #3d3d5c;
}

body.dark-mode .site-footer {
    background: #16213e;
}

body.dark-mode .pricing-card {
    background: linear-gradient(180deg, #16213e 47.7%, #1a1a2e 225.2%);
}

body.dark-mode .faq-item {
    border-color: #3d3d5c;
}

body.dark-mode .testimonial-card {
    background: #16213e;
}

body.dark-mode .toggle-container {
    background: #16213e;
}

body.dark-mode .toggle-btn.active {
    background: #1a1a2e;
}
