/* =========================================
   VYLEPŠENÝ TMAVÝ REŽIM (Poster Theme)
   ========================================= */
:root {
    --transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

body.dark-mode {
    background-color: #000000 !important;
    --bg-main: #000000 !important;
    --bg-card: #08090b !important;
    --primary-color: #0ea5e9;
    --accent-color: #8b5cf6;
    --primary-light: rgba(14, 165, 233, 0.1);
    --text-dark: #f8fafc !important;
    --border-color: rgba(255, 255, 255, 0.05);
    --glass-bg: rgba(3, 4, 6, 0.5) !important;
    --glass-border: rgba(255, 255, 255, 0.04) !important;
}

body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(var(--border-color) 1px, transparent 1px),
        linear-gradient(90deg, var(--border-color) 1px, transparent 1px);
    background-size: 50px 50px;
    opacity: 0.15;
    z-index: -2;
}

body.dark-mode .text-gradient {
    /* Absolútne najpestrejší tech neónový gradient (Neon Mint cez Modrú a Fuchsia až do Cyber Magenta) */
    background: linear-gradient(90deg, #00ffcc, #00d4ff, #d500f9, #ff007f);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    color: transparent;
    /* Odstránená aura pre čistejší vzhľad */
    filter: none !important;
}

.bg-stars {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        radial-gradient(1.5px 1.5px at 10% 15%, #00d4ff, transparent),
        radial-gradient(2px 2px at 25% 45%, #d500f9, transparent),
        radial-gradient(2.5px 2.5px at 60% 80%, rgba(255, 255, 255, 0.9), transparent),
        radial-gradient(1.5px 1.5px at 85% 20%, #00d4ff, transparent),
        radial-gradient(2px 2px at 40% 70%, #d500f9, transparent);
    background-size: 250px 250px;
    opacity: 0 !important;
    display: none !important;
    z-index: -1;
    pointer-events: none;
    transition: opacity 0.8s ease;
}

.bg-glow-1 {
    position: fixed;
    bottom: -15%;
    left: -10%;
    width: 45vw;
    height: 45vw;
    background: radial-gradient(circle at 35% 35%, rgba(0, 160, 255, 0.9), rgba(0, 80, 255, 0.4) 65%, transparent 75%);
    filter: blur(8px);
    z-index: -1;
    border-radius: 50%;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.8s ease;
}

.bg-glow-2 {
    position: fixed;
    top: -20%;
    right: -15%;
    width: 55vw;
    height: 55vw;
    background: radial-gradient(circle at 65% 35%, rgba(181, 23, 158, 0.9), rgba(114, 9, 183, 0.5) 65%, transparent 75%);
    filter: blur(8px);
    z-index: -1;
    border-radius: 50%;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.8s ease;
}

.bg-glow-3 {
    position: fixed;
    bottom: -5%;
    right: 5%;
    width: 25vw;
    height: 25vw;
    background: radial-gradient(circle at 50% 50%, rgba(213, 0, 249, 0.7), transparent 70%);
    filter: blur(12px);
    z-index: -1;
    border-radius: 50%;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.8s ease;
}

/* Odstránený náhodný orb vľavo hore */

body.dark-mode .bg-stars,
body.dark-mode .bg-glow-1,
body.dark-mode .bg-glow-2,
body.dark-mode .bg-glow-3 {
    opacity: 0 !important;
    display: none !important;
}

/* ROBUST NAVIGATION FIX */
nav {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    padding: 15px 40px !important;
    position: sticky !important;
    top: 0 !important;
    z-index: 1001 !important;
    background: var(--glass-bg, rgba(255, 255, 255, 0.8)) !important;
    backdrop-filter: blur(12px) !important;
    border-bottom: 1px solid var(--border-color) !important;
    width: 100% !important;
    box-sizing: border-box !important;
}

.nav-right-wrap {
    display: flex !important;
    align-items: center !important;
    gap: 25px !important;
}

.desktop-only {
    display: block;
}

@media (max-width: 992px) {
    .desktop-only {
        display: none !important;
    }
}

.nav-links {
    display: flex !important;
    gap: 25px !important;
    align-items: center !important;
}

@media (max-width: 992px) {
    nav {
        padding: 12px 20px !important;
    }

    /* KILL DROPDOWN ON MOBILE FOR CONSISTENCY */
    .nav-dropdown-content {
        display: none !important;
    }

    .nav-dropdown-btn svg {
        display: none !important;
    }

    .nav-dropdown-btn i {
        display: none !important;
    }

    /* MOBILE PERFORMANCE - ZERO DELAY */
    .guarantee-banner,
    .guarantee-banner svg,
    .guarantee-banner i,
    .guarantee-banner .lucide {
        transition: all 0.1s ease-out !important;
    }

    .nav-right-wrap {
        display: none !important;
        position: absolute !important;
        top: 100% !important;
        left: 0 !important;
        width: 100% !important;
        background: rgba(10, 15, 30, 0.98) !important;
        /* solid/high-opacity background for visibility */
        backdrop-filter: blur(25px) !important;
        -webkit-backdrop-filter: blur(25px) !important;
        flex-direction: column !important;
        padding: 40px 20px !important;
        gap: 20px !important;
        box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8) !important;
        z-index: 2000 !important;
        margin-left: 0 !important;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important;
    }

    .nav-right-wrap.active {
        display: flex !important;
        animation: navSlideDown 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    }

    .nav-links {
        flex-direction: column !important;
        width: 100% !important;
        gap: 15px !important;
    }

    .nav-links a {
        text-align: center !important;
        width: 100% !important;
        font-size: 1.2rem !important;
        font-weight: 700 !important;
        padding: 5px 0 !important;
    }

    .nav-controls {
        display: flex !important;
        align-items: center !important;
        gap: 15px !important;
    }

    .hamburger {
        display: block !important;
        cursor: pointer;
    }

    .btn-nav-mobile {
        border-radius: 50px !important;
        transform: scale(1.05);
    }

    /* Ensure only the correct button shows on mobile */
    .nav-links .btn-nav {
        display: none !important;
    }
}

/* =========================================
   FOOTER & GLOBAL MOBILE REFINEMENTS
   ========================================= */
/* RAINBOW HOVER FOR GUARANTEE BANNER (GLOBAL) */
.guarantee-banner {
    -webkit-tap-highlight-color: transparent !important;
    outline: none !important;
    user-select: none !important;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1) !important;
    cursor: pointer;
}

.guarantee-banner:hover, 
.guarantee-banner:active, 
.guarantee-banner:focus { 
    transform: scale(1.02) !important; 
    border-color: inherit !important; 
    box-shadow: none !important; 
    outline: none !important; 
    background: transparent !important; 
}

.guarantee-banner svg,
.guarantee-banner i,
.guarantee-banner .lucide {
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.guarantee-banner:hover svg,
.guarantee-banner:hover i,
.guarantee-banner:hover .lucide {
    stroke: url(#neon-svg-gradient) !important;
    transform: scale(1.2) rotate(5deg) !important;
    filter: none !important;
}

.guarantee-banner:hover h3 {
    color: var(--primary-color) !important;
    transition: color 0.4s ease;
}

@media (max-width: 768px) {
    footer .contact-info {
        flex-direction: column !important;
        gap: 15px !important;
        align-items: center !important;
    }

    footer .contact-info span {
        display: flex !important;
        align-items: center !important;
        gap: 8px !important;
    }

    .hero-panel h1 {
        font-size: 2.2rem !important;
    }

    .section h2 {
        font-size: 1.8rem !important;
    }
}

/* Ensure icons have correct colors in Dark Mode */
body.dark-mode .theme-toggle,
body.dark-mode .nav-avatar-btn,
body.dark-mode .auth-profile-toggle,
body.dark-mode .hamburger {
    color: #f8fafc !important;
    stroke: #f8fafc !important;
}

body.dark-mode .nav-dropdown-content,
body.dark-mode .auth-profile-dropdown {
    background: #111827 !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
}

/* Enhanced Visibility for Navbar Icons */
body.dark-mode .theme-toggle {
    background: rgba(255, 255, 255, 0.1) !important;
    border-color: rgba(255, 255, 255, 0.2) !important;
    color: #ffffff !important;
    box-shadow: 0 0 10px rgba(14, 165, 233, 0.2);
}

body.dark-mode .hamburger {
    background: transparent !important;
    border: none !important;
    color: #ffffff !important;
    box-shadow: none !important;
}

/* User Profile Button Style (Match Materials Link Style) */
.auth-profile-toggle,
.nav-avatar-btn {
    border: 2px solid var(--primary-color) !important;
    border-radius: 50% !important;
    width: 44px !important;
    height: 44px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    box-shadow: 0 0 10px rgba(37, 99, 235, 0.2) !important;
    padding: 0 !important;
    transition: all 0.3s ease !important;
    overflow: hidden !important;
    background: #ffffff !important;
    cursor: pointer !important;
}

body.dark-mode .auth-profile-toggle,
body.dark-mode .nav-avatar-btn {
    background: rgba(255, 255, 255, 0.05) !important;
    border-color: #0ea5e9 !important;
    box-shadow: 0 0 15px rgba(14, 165, 233, 0.4) !important;
    color: #ffffff !important;
}

.auth-profile-toggle:hover,
.nav-avatar-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 0 20px rgba(14, 165, 233, 0.5) !important;
}

body.dark-mode .theme-toggle svg,
body.dark-mode .auth-profile-toggle svg {
    stroke: #ffffff !important;
    filter: none !important;
}

/* 
   GLOBLÁRNA ŠTANDARDIZÁCIA BLOKOV (Glassmorphism Content Blocks) 
   Apply the light-blue glass aesthetics to all major content containers
*/

:root {
    --block-gap: clamp(2.5rem, 6vh, 4.5rem);
}

.glass-field,
.section,
.card,
.form-container,
.article-card,
.cta-box,
.stats-container,
.reservation-card,
.subject-card,
.plan-option-card,
.how-it-works-accordion,
.success-msg,
.modal-content,
.pricing-card,
.faq-item,
.guarantee-banner,
.billing-toggle-wrap,
.filter-container,
.highlight-box,
.login-container,
.auth-box,
.subject-pill,
.calc-card,
.variant-selector {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.95), rgba(240, 249, 255, 0.9)) !important;
    backdrop-filter: blur(32px) !important;
    -webkit-backdrop-filter: blur(32px) !important;
    border: 1px solid rgba(15, 23, 42, 0.1) !important;
    border-top: 2px solid rgba(79, 70, 229, 0.12) !important;
    border-radius: 28px !important;
    margin-bottom: var(--block-gap) !important;
    box-shadow:
        0 15px 35px -5px rgba(37, 99, 235, 0.1),
        0 5px 15px rgba(0, 0, 0, 0.05),
        inset 0 1px 0 0 rgba(255, 255, 255, 0.8) !important;
}

body.dark-mode .glass-field,
body.dark-mode .section,
body.dark-mode .card,
body.dark-mode .form-container,
body.dark-mode .article-card,
body.dark-mode .cta-box,
body.dark-mode .stats-container,
body.dark-mode .reservation-card,
body.dark-mode .subject-card,
body.dark-mode .plan-option-card,
body.dark-mode .how-it-works-accordion,
body.dark-mode .success-msg,
body.dark-mode .modal-content,
body.dark-mode .pricing-card,
body.dark-mode .faq-item,
body.dark-mode .guarantee-banner,
body.dark-mode .billing-toggle-wrap,
body.dark-mode .filter-container,
body.dark-mode .highlight-box,
body.dark-mode .login-container,
body.dark-mode .auth-box,
body.dark-mode .subject-pill,
body.dark-mode .calc-card,
body.dark-mode .variant-selector {
    background: linear-gradient(135deg, rgba(10, 15, 30, 0.98), rgba(20, 35, 75, 0.85)) !important;
    backdrop-filter: blur(32px) !important;
    -webkit-backdrop-filter: blur(32px) !important;
    border: 1px solid rgba(56, 189, 248, 0.45) !important;
    border-top: 2px solid rgba(56, 189, 248, 0.7) !important;
    margin-bottom: var(--block-gap) !important;
    box-shadow:
        0 40px 80px -15px rgba(0, 0, 0, 0.6),
        0 0 30px rgba(14, 165, 233, 0.05),
        0 0 0 1px rgba(255, 255, 255, 0.05),
        inset 0 1px 0 0 rgba(255, 255, 255, 0.08) !important;
}

/* Specific paddings and margins for content types */
.glass-field {
    padding: 50px 40px !important;
    margin: 40px auto !important;
    max-width: 850px !important;
    display: flex;
    flex-direction: column;
    gap: 32px;
    align-items: center;
    /* Default to centered for Homepage Hero */
    text-align: center;
}

/* Specific Alignment overrides for Calculators */
.sidebar.glass-field,
.calc-card.glass-field,
.calc-main header.glass-field {
    align-items: flex-start !important;
    text-align: left !important;
}

/* --- GLOBAL UNIFIED DROPDOWNS --- */
.nav-dropdown {
    position: relative;
    display: flex;
    align-items: center;
}

.nav-dropdown-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.nav-dropdown-content,
.auth-profile-dropdown {
    display: none;
    position: absolute;
    background: #111827 !important;
    backdrop-filter: blur(20px) !important;
    -webkit-backdrop-filter: blur(20px) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    border-top: 1px solid rgba(255, 255, 255, 0.1) !important;
    border-radius: 8px !important;
    min-width: 160px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.2) !important;
    z-index: 1000;
    top: 100%;
    padding: 8px 0 !important;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.nav-dropdown-content {
    left: 50%;
    transform: translateX(-50%) translateY(10px);
}

.auth-profile-dropdown {
    left: auto !important;
    right: 0 !important;
    transform: translateY(10px) !important;
}

.nav-dropdown:hover .nav-dropdown-content,
.auth-profile-dropdown.active {
    display: block !important;
    opacity: 1 !important;
    visibility: visible !important;
    transform: translateY(0) !important;
}

.nav-dropdown:hover .nav-dropdown-content {
    transform: translateX(-50%) translateY(0) !important;
}

.nav-dropdown-content a,
.auth-dropdown-item {
    color: var(--text-dark) !important;
    padding: 12px 16px !important;
    text-decoration: none !important;
    display: block !important;
    font-size: 0.95rem !important;
    font-weight: 600 !important;
    border-radius: 12px !important;
    transition: var(--transition) !important;
    border: none !important;
    text-align: left !important;
}

.nav-dropdown-content a:hover,
.auth-dropdown-item:hover {
    background: var(--primary-light) !important;
    color: var(--primary-color) !important;
    transform: translateX(5px);
}

.nav-dropdown-content a::after,
.auth-dropdown-item::after {
    content: '' !important;
    position: absolute !important;
    width: 0 !important;
    height: 2px !important;
    bottom: 4px !important;
    left: 16px !important;
    background-color: var(--primary-color) !important;
    transition: width 0.3s ease !important;
    transform: none !important;
}

.nav-dropdown-content a:hover::after,
.auth-dropdown-item:hover::after {
    width: calc(100% - 32px) !important;
}

/* Global Nav Link Animation */
.nav-links a:not(.btn-nav)::after {
    content: '' !important;
    position: absolute !important;
    width: 0 !important;
    height: 2px !important;
    bottom: -4px !important;
    left: 0 !important;
    background-color: var(--primary-color) !important;
    transition: width 0.3s ease !important;
}

.nav-links a:not(.btn-nav):hover::after {
    width: 100% !important;
}

.sidebar.glass-field,
.calc-card.glass-field,
.calc-main header.glass-field {
    align-items: flex-start !important;
    text-align: left !important;
}

.sidebar-item:hover,
.mode-btn:hover {
    box-shadow: 0 0 15px rgba(14, 165, 233, 0.4) !important;
    border-color: #0ea5e9 !important;
}

/* GLOBLÁLNA REAKTÍVNA FARBA IKON (White to Neon) */
body.dark-mode .plan-icon .lucide,
body.dark-mode .feature-icon .lucide,
body.dark-mode .subject-card-icon .lucide,
body.dark-mode .plan-option-icon .lucide,
body.dark-mode .card-icon .lucide,
body.dark-mode .article-icon .lucide,
body.dark-mode .modal-icon .lucide,
body.dark-mode .calc-card-icon .lucide,
body.dark-mode .subject-pill .lucide {
    stroke: #ffffff !important;
    transition: transform 0.3s ease, filter 0.3s ease !important;
    /* Removed stroke transition to fix rainbow delay */
    filter: none !important;
}

/* Neonová farba pri vybranom stave, aktívnom stave alebo hoveri */
body.dark-mode .subject-card.selected .subject-card-icon .lucide,
body.dark-mode .plan-option-card.selected .plan-option-icon .lucide,
body.dark-mode .sidebar-item.active .lucide,
body.dark-mode .mode-btn.active .lucide,
body.dark-mode .inner-pill.active .lucide,
body.dark-mode .nav-links.active .lucide,
body.dark-mode .feature-item:hover .feature-icon .lucide,
body.dark-mode .pricing-card:hover .plan-icon .lucide,
body.dark-mode .plan-option-card:hover .plan-option-icon .lucide,
body.dark-mode .category-card:hover .card-icon .lucide,
body.dark-mode .material-card:hover .card-icon .lucide,
body.dark-mode .article-card:hover .article-icon .lucide,
body.dark-mode .stat-item:hover .lucide,
body.dark-mode .calc-card:hover .calc-card-icon .lucide,
body.dark-mode .subject-card:hover .subject-card-icon .lucide,
body.dark-mode .accordion-item:hover .feature-icon .lucide,
body.dark-mode .subject-pill:hover .lucide {
    stroke: url(#neon-svg-gradient) !important;
}

/* Refined Button Utility */
.btn-pricing-refined {
    max-width: 260px !important;
    width: 90% !important;
    margin: 0 auto !important;
    padding: 12px 20px !important;
    font-size: 0.95rem !important;
    font-weight: 700 !important;
    border-radius: 12px !important;
    display: block !important;
}


@keyframes slideDown {
    from {
        transform: translateY(-20px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Ensure no horizontal scroll */
html,
body {
    overflow-x: hidden !important;
    width: 100% !important;
}

/* FAQ Gap Override - Definitívna oprava */
.faq-item,
body.dark-mode .faq-item {
    margin-bottom: 0 !important;
}

/* GLOBLÁLNY DÚHOVÝ HOVER EFEKT PRE IKONY V KARTÁCH */
.card:hover .card-icon .lucide,
.card:hover .card-icon svg,
.category-card:hover .card-icon .lucide,
.category-card:hover .card-icon svg,
.article-card:hover .card-icon .lucide,
.material-card:hover .card-icon .lucide {
    stroke: url(#neon-svg-gradient) !important;
    transform: scale(1.15) !important;
    stroke-width: 2.2 !important;
}

/* Base Lucide Icon Transition for standardized hovers */
.lucide {
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) !important;
}

/* --- GLOBAL FOOTER STANDARDIZATION --- */
footer {
    width: 100% !important;
    border-top: 1px solid var(--border-color) !important;
    margin-top: 60px !important;
    padding: 60px 20px !important;
    text-align: center !important;
    background: transparent !important;
    box-sizing: border-box !important;
}

.footer-content {
    max-width: 1000px !important;
    margin: 0 auto !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 30px !important;
    align-items: center !important;
}

.footer-logo {
    max-width: 65px !important;
    filter: grayscale(100%) opacity(0.4) !important;
    transition: var(--transition) !important;
}

body.dark-mode .footer-logo {
    filter: grayscale(100%) opacity(0.6) invert(1) !important;
}

.footer-logo:hover,
body.dark-mode .footer-logo:hover {
    filter: grayscale(0%) opacity(1) invert(0) !important;
    transform: scale(1.1) !important;
}

.contact-info {
    display: flex !important;
    justify-content: center !important;
    gap: 40px !important;
    flex-wrap: wrap !important;
    color: var(--text-dark) !important;
    font-weight: 600 !important;
    font-size: 1.05rem !important;
}

.contact-info a {
    color: var(--primary-color) !important;
    text-decoration: none !important;
    transition: 0.3s !important;
}

.contact-info a:hover {
    text-decoration: underline !important;
    color: var(--primary-hover) !important;
}

/* =========================================
   GLOBAL MOBILE ENHANCEMENTS
   ========================================= */
@media (max-width: 768px) {

    /* --- Base Sizing --- */
    html {
        font-size: 15px;
    }

    /* --- Global Spacing --- */
    .container,
    .main-container,
    main,
    .page-content {
        padding-left: 12px !important;
        padding-right: 12px !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }

    /* --- Hero / Header --- */
    header,
    .hero-panel,
    .glass-field {
        padding: 28px 18px !important;
        border-radius: 20px !important;
        text-align: left !important;
        margin: 12px auto !important;
    }

    header h1,
    .hero-panel h1,
    .glass-field h1 {
        font-size: clamp(1.6rem, 6vw, 2.4rem) !important;
        line-height: 1.25 !important;
        letter-spacing: -0.5px !important;
    }

    header p,
    .hero-panel p,
    .glass-field p {
        font-size: 0.95rem !important;
        line-height: 1.6 !important;
    }

    /* --- Section Headings --- */
    h2 {
        font-size: clamp(1.4rem, 5vw, 2rem) !important;
    }

    h3 {
        font-size: clamp(1.1rem, 4vw, 1.5rem) !important;
    }

    /* --- Cards: Force Full Width, Better Padding --- */
    .card,
    .pricing-card,
    .reservation-card,
    .subject-card,
    .article-card,
    .category-card,
    .material-card,
    .plan-option-card,
    .faq-item,
    .how-it-works-accordion,
    .calc-card {
        width: 100% !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        padding: 22px 18px !important;
        border-radius: 18px !important;
    }

    .pricing-card.featured {
        padding-top: 60px !important;
    }

    /* --- Card Grids: Stack on Mobile --- */
    .cards-grid,
    .pricing-grid,
    .subjects-grid,
    .plan-selector-grid,
    .articles-grid,
    .materials-grid,
    .stats-container,
    .features-grid {
        grid-template-columns: 1fr !important;
        gap: 16px !important;
    }

    /* --- Buttons: Bigger Touch Targets --- */
    .btn,
    .btn-primary,
    .btn-secondary,
    .empty-btn,
    button[type="submit"]:not(#vzdelko-send),
    .btn-nav,
    .btn-pricing-refined,
    .btn-view-payment,
    .delete-record-btn {
        min-height: 52px !important;
        font-size: 1.05rem !important;
        padding: 14px 20px !important;
        border-radius: 14px !important;
        width: 100% !important;
        max-width: 100% !important;
        margin: 12px auto !important;
        display: flex !important;
        align-items: center;
        justify-content: center;
        gap: 10px;
    }

    /* --- Forms --- */
    form {
        grid-template-columns: 1fr !important;
    }

    input,
    textarea,
    select {
        font-size: 16px !important;
        /* Prevents iOS zoom on focus */
        padding: 13px 15px !important;
        border-radius: 12px !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }

    /* --- Reservation & Detail Cards --- */
    .res-header {
        flex-direction: column !important;
        gap: 12px !important;
    }

    .res-details {
        grid-template-columns: 1fr !important;
    }

    .status-badge {
        align-self: flex-start !important;
        font-size: 0.75rem !important;
    }

    /* --- Modals --- */
    .auth-modal,
    .modal {
        width: 96% !important;
        max-width: 100% !important;
        padding: 24px 18px !important;
        border-radius: 20px !important;
    }

    /* --- Footer --- */
    footer {
        padding: 40px 16px !important;
    }

    .contact-info {
        flex-direction: column !important;
        gap: 14px !important;
        font-size: 0.95rem !important;
    }

    /* --- Reservation Success Block --- */
    .success-msg,
    #s4 {
        padding: 28px 18px !important;
        border-radius: 20px !important;
    }

    /* --- Calc Sidebar/Layout --- */
    .calc-main {
        flex-direction: column !important;
    }

    .sidebar {
        width: 100% !important;
        position: static !important;
    }

    /* --- Empty State Centering --- */
    .empty-state {
        padding: 40px 20px !important;
        border-radius: 20px !important;
    }

    .empty-icon {
        font-size: 3rem !important;
    }

    .empty-state h3 {
        font-size: 1.4rem !important;
    }

    /* --- Plan Option Cards Row on Mobile: horizontal pill style --- */
    .plan-option-card {
        flex-direction: row !important;
        text-align: left !important;
        padding: 16px 20px !important;
        gap: 14px !important;
        align-items: center !important;
    }

    .plan-option-icon {
        margin-bottom: 0 !important;
        font-size: 1.5rem !important;
    }

    .inner-variants {
        width: 100% !important;
        flex-wrap: wrap !important;
        justify-content: center !important;
        gap: 6px !important;
    }
}

@media (max-width: 480px) {
    nav {
        padding: 12px 14px !important;
    }

    .logo {
        font-size: 1.2rem !important;
    }

    .nav-logo {
        height: 28px !important;
    }

    header h1,
    .glass-field h1 {
        font-size: 1.5rem !important;
    }
}

/* 🚨 ULTIMATE GLOBAL MOBILE RESCUE 🚨 */
@media (max-width: 650px) {
    :root {
        --block-gap: 1.4rem !important;
        /* Compressed gaps for mobile flow */
    }

    /* 1. Global Layout & Spacing - Force Symmetrical spacing & KILL OVERFLOW */
    body,
    html {
        overflow-x: hidden !important;
        width: 100% !important;
        background-attachment: scroll !important;
        /* Fix mobile background jumps */
    }

    .container,
    .main-container,
    .content-wrap,
    .section,
    main,
    header,
    .how-it-works-wrapper {
        padding-left: 12px !important;
        padding-right: 12px !important;
        width: 100% !important;
        max-width: 100% !important;
        /* KILL FIXED WIDTHS */
        min-width: 0 !important;
        box-sizing: border-box !important;
    }

    * {
        -webkit-tap-highlight-color: transparent !important;
        outline: none !important;
    }

    .guarantee-banner * {
        -webkit-tap-highlight-color: transparent !important;
        outline: none !important;
    }

    /* 2. Grid & Flex Stacking - Force all common layout types to vertical & Fix Symmetries */
    .grid,
    .grid-2,
    .grid-3,
    .pricing-grid,
    .features,
    .features-grid,
    .stats-container,
    .articles-grid,
    .materials-grid,
    .content-grid,
    .footer-content,
    .pricing-cards-wrap,
    .cards-container,
    .features-wrap,
    .subject-pill,
    .subjects-filter,
    .billing-toggle-wrap,
    .lecturers-grid,
    .cat-group,
    .feature-item,
    .accordion-item,
    .plan-options {
        display: flex !important;
        flex-direction: column !important;
        flex-wrap: wrap !important;
        gap: var(--block-gap) !important;
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        align-items: stretch !important;
        margin-top: 0 !important;
        margin-bottom: var(--block-gap) !important;
    }

    .subjects-grid {
        display: flex !important;
        flex-direction: row !important;
        /* Force side-by-side as requested */
        gap: 8px !important;
        width: 100% !important;
        margin-bottom: var(--block-gap) !important;
    }

    /* 3. Global Card & Block Sizing - FORCE FLUIDITY & COMPACTNESS */
    .glass-field,
    .section,
    .feature-item,
    .pricing-card,
    .card,
    .article-card,
    .material-card,
    .reservation-card,
    .calc-card,
    .form-container,
    .auth-box,
    .cta-box,
    .lecturer-card,
    #card-single,
    #card-classic,
    #card-premium,
    #card-unlimited,
    .subject-card,
    .btn-cat,
    .accordion-item,
    .plan-option-card,
    .how-it-works-accordion {
        padding: 20px 14px !important;
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        box-sizing: border-box !important;
        border-radius: 20px !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        margin-top: 0 !important;
        margin-bottom: var(--block-gap) !important;
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        /* Force Centering for standard blocks */
        text-align: center !important;
    }

    .feature-icon {
        margin: 0 auto 12px !important;
        /* Center symbols in the 6 blocks */
    }

    .pricing-card.featured {
        padding-top: 60px !important;
    }

    .subject-pill {
        flex: 1 !important;
        width: auto !important;
        padding: 12px 6px !important;
        min-width: 0 !important;
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 5px !important;
    }

    .subject-pill i,
    .subject-pill .lucide {
        font-size: 1.4rem !important;
        width: 1.4rem !important;
        height: 1.4rem !important;
    }

    .subject-pill {
        font-size: 0.78rem !important;
        white-space: nowrap !important;
    }

    .most-popular-badge {
        top: 10px !important;
        transform: translateX(-50%) scale(0.9) !important;
        padding: 4px 12px !important;
    }

    /* 4. ONE-LINER TOGGLES & VARIANTS */
    .billing-toggle-wrap,
    .variant-selector,
    .subjects-filter,
    .filter-container {
        display: flex !important;
        flex-direction: row !important;
        flex-wrap: nowrap !important;
        overflow-x: auto !important;
        justify-content: center !important;
        gap: 4px !important;
        padding: 4px !important;
        width: 96% !important;
        max-width: 500px !important;
        margin: 0 auto 30px !important;
        scrollbar-width: none;
        border-radius: 50px !important;
    }

    .billing-toggle-wrap::-webkit-scrollbar,
    .filter-container::-webkit-scrollbar {
        display: none;
    }

    .toggle-label,
    .variant-pill,
    .filter-chip {
        flex: 1 !important;
        padding: 8px 4px !important;
        font-size: 0.76rem !important;
        /* Small enough for one line */
        white-space: nowrap !important;
        min-width: 0 !important;
        text-align: center !important;
    }

    /* SPECIFIC 2x2 GRID FOR SUBJECTS IN CENNIK */
    .billing-toggle-wrap {
        display: grid !important;
        grid-template-columns: 1fr 1fr !important;
        gap: 6px !important;
        width: 100% !important;
        padding: 6px !important;
        background: rgba(255, 255, 255, 0.05);
        border-radius: 20px !important;
    }

    .billing-toggle-wrap .toggle-label {
        width: 100% !important;
        padding: 10px 4px !important;
    }

    .filter-glider {
        display: block !important;
        /* Restore glider as requested */
        position: absolute !important;
        z-index: 0 !important;
        /* Removed height and top overrides so JS can control them */
    }

    /* 5. Typography Scalers */
    header h1,
    .hero-panel h1,
    .glass-field h1 {
        font-size: 2.6rem !important;
        line-height: 1.1 !important;
        margin-top: 5px !important;
        margin-bottom: 8px !important;
        letter-spacing: -1.5px !important;
        font-weight: 800 !important;
        text-align: center !important;
    }

    .faq-grid {
        gap: 8px !important;
    }

    .faq-item {
        padding: 14px 18px !important;
        background: rgba(255, 255, 255, 0.02) !important;
        border-radius: 20px !important;
        border: 1px solid rgba(255, 255, 255, 0.05) !important;
    }

    .faq-q {
        font-size: 1rem !important;
        margin: 0 !important;
    }

    .faq-a-inner {
        font-size: 0.9rem !important;
        line-height: 1.5 !important;
    }

    .faq-title,
    .section h2 {
        font-size: 1.5rem !important;
        margin-bottom: 15px !important;
    }

    .price-amount {
        font-size: 3.2rem !important;
        color: var(--primary-color) !important;
        line-height: 1 !important;
    }

    .price-label {
        margin: 2px 0 6px !important;
        font-size: 0.85rem !important;
        display: block !important;
    }

    .divider {
        margin: 8px 0 !important;
    }

    .pricing-features {
        margin-top: 4px !important;
        gap: 8px !important;
    }

    /* 6. Centering Trust & Footer Assets */
    .trust-indicator {
        flex-direction: column !important;
        align-items: center !important;
        gap: 12px !important;
        margin-top: 25px !important;
    }

    .footer-content {
        align-items: center !important;
        text-align: center !important;
    }

    .footer-logo {
        margin: 0 auto 15px !important;
        display: block !important;
    }

    .contact-info {
        align-items: center !important;
        text-align: center !important;
    }

    /* 7. Image & Logo Precision */
    .hero-logo {
        max-width: 115px !important;
        /* Increased as requested */
        max-height: 115px !important;
        height: auto !important;
        margin-bottom: 5px !important;
    }

    .nav-logo {
        height: 30px !important;
        max-width: 110px !important;
    }

    /* 8. ELIMINATE ALL GLOWS & FLOATING ELEMENTS ON MOBILE */
    .bg-glow-1,
    .bg-glow-2,
    .bg-glow-3,
    .floating-symbol,
    .sym-1,
    .sym-2,
    .sym-3,
    .sym-4,
    .sym-5,
    .desktop-only {
        display: none !important;
    }

    /* 9. Navbar Stability & Dropdown Kill */
    nav {
        flex-wrap: nowrap !important;
        justify-content: space-between !important;
        padding: 0 15px !important;
        height: 65px !important;
    }

    .nav-dropdown-content {
        display: none !important;
    }

    .nav-dropdown-btn svg {
        display: none !important;
    }

    .nav-dropdown-btn i {
        display: none !important;
    }

    /* MOBILE PERFORMANCE - ZERO DELAY */
    .guarantee-banner,
    .guarantee-banner svg,
    .guarantee-banner i,
    .guarantee-banner .lucide {
        transition: all 0.1s ease-out !important;
    }

    .btn-nav-mobile {
        width: auto !important;
        margin: 0 !important;
        padding: 7px 11px !important;
        font-size: 0.76rem !important;
    }
}

@keyframes navSlideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}
/* TOTAL SUPPRESSION OF MOBILE SELECTION BOX - FINAL ATTEMPT */
.guarantee-banner, 
.guarantee-banner *, 
.guarantee-banner:focus, 
.guarantee-banner:active, 
.guarantee-banner:hover,
.guarantee-banner:focus-within,
.guarantee-banner:focus-visible {
    outline: 0 !important;
    outline: none !important;
    -webkit-tap-highlight-color: transparent !important;
    -webkit-tap-highlight-color: rgba(0,0,0,0) !important;
    box-shadow: none !important;
    -webkit-user-select: none !important;
    user-select: none !important;
}

/* =========================================
   🚨 ULTRA COMPACT NAVIGATION (V2.1) 🚨
   ========================================= */

@media (max-width: 992px) {
    .nav-right-wrap {
        padding: 12px 10px !important;
        gap: 5px !important;
        max-height: 65vh !important;
        border-radius: 0 0 25px 25px !important;
    }

    .nav-links {
        gap: 5px !important;
    }

    .nav-links a {
        font-size: 1.0rem !important; /* Smaller text */
        padding: 5px 15px !important;
        font-weight: 500 !important;
    }

    .nav-links .btn-nav {
        display: none !important; /* Never in dropdown */
    }
    
    .nav-controls .btn-nav-mobile {
        padding: 6px 15px !important;
        font-size: 0.8rem !important;
    }
}

/* Ensure no ghost icons */
@media (min-width: 993px) {
    .hamburger { display: none !important; }
}

/* =========================================
   🚨 MASTER SCALING COMPATIBILITY LOCK 🚨
   ========================================= */

/* 1. UNIVERSAL HEADER PILL (Zero Inconsistency) */
.btn-nav, .btn-nav-mobile, nav .btn-nav-mobile {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    background: linear-gradient(135deg, #0ea5e9, #2563eb) !important;
    color: #ffffff !important;
    border-radius: 50px !important;
    padding: 10px 22px !important;
    font-size: 0.9rem !important;
    font-weight: 800 !important;
    text-decoration: none !important;
    white-space: nowrap !important;
    box-shadow: 0 4px 15px rgba(37, 99, 235, 0.3) !important;
    border: none !important;
    transition: all 0.3s ease !important;
}

.btn-nav:hover, .btn-nav-mobile:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 20px rgba(37, 99, 235, 0.5) !important;
}

/* 2. RESPONSIVE COMPONENT HANDOFF (992px Master Switch) */
@media (min-width: 993px) {
    .nav-links .btn-nav { display: inline-flex !important; }
    .nav-controls .btn-nav-mobile { display: none !important; }
    .hamburger { display: none !important; }
    
    /* Ensure desktop links aren't cramped on small laptops */
    .nav-links { gap: clamp(15px, 2.5vw, 35px) !important; }
}

@media (max-width: 992px) {
    .nav-links .btn-nav { display: none !important; } /* Hide in vertical list */
    .nav-controls .btn-nav-mobile { display: inline-flex !important; } /* KEEP IN HEADER PILL */
    .hamburger { display: flex !important; }
    
    /* Absolute compact dropdown logic */
    .nav-right-wrap {
        padding: 15px 10px !important;
        gap: 8px !important;
        background: rgba(2, 6, 23, 0.98) !important;
        backdrop-filter: blur(20px) !important;
        border-bottom-left-radius: 25px !important;
        border-bottom-right-radius: 25px !important;
    }
}

/* 3. HERO & BUTTON SCALING SAFETY */
.btn-hero {
    display: inline-flex !important;
    padding: clamp(14px, 3vw, 18px) clamp(30px, 6vw, 45px) !important;
    font-size: clamp(1rem, 2.5vw, 1.25rem) !important;
    margin: 25px auto !important;
    text-align: center !important;
}

/* Ensure no text collisions in the hero block */
.hero-desc {
    max-width: 800px !important;
    margin: 0 auto !important;
    padding: 0 20px !important;
}

.hero-desc p {
    margin-bottom: 20px !important;
}

/* Fix for the profile icon size consistency */
.auth-profile-toggle, .nav-avatar-btn {
    width: 40px !important;
    height: 40px !important;
    flex-shrink: 0 !important;
}

/* =========================================
   🚨 NARROW MOBILE LINKS & HOVER FIX 🚨
   ========================================= */

@media (max-width: 992px) {
    .nav-links {
        align-items: center !important; /* Centered items */
    }

    .nav-links a {
        width: fit-content !important; /* Narrow buttons */
        margin: 0 auto !important;
        text-align: center !important;
        padding: 10px 30px !important;
        position: relative !important;
    }

    /* Fix the animation width so it doesn't cross the screen */
    .nav-links a::after {
        left: 50% !important;
        transform: translateX(-50%) !important;
        width: 0 !important;
    }

    .nav-links a:hover::after {
        width: 60% !important; /* Only 60% of the button width */
    }
    
    /* Ensure the actual nav container is centered */
    .nav-right-wrap {
        align-items: center !important;
    }
}

/* =========================================
   🚨 FINAL MOBILE RATIO & ANIMATION FIX 🚨
   ========================================= */

@media (max-width: 992px) {
    /* Correct the displaced animation */
    .nav-links a::after {
        content: "" !important;
        position: absolute !important;
        bottom: 0 !important;
        left: 50% !important;
        transform: translateX(-50%) !important;
        height: 2px !important;
        background: var(--primary-color) !important;
        width: 0 !important;
        transition: width 0.3s ease !important;
    }

    .nav-links a:hover::after {
        width: 40px !important; /* Fixed narrow width for high-quality feel */
    }

    /* Shrink the overwhelming bulb image on smaller screens */
    .hero-logo {
        max-width: 120px !important;
        margin-bottom: 5px !important;
    }

    /* Tighten the central glass block - No more swimming in empty space */
    .glass-field {
        padding: 25px 20px !important;
        margin-top: 5px !important;
        gap: 20px !important; /* Reduced gap between internal items */
    }

    header h1 {
        font-size: 2.2rem !important;
        margin-bottom: 2px !important;
    }

    .badge {
        font-size: 0.85rem !important;
        padding: 6px 16px !important;
    }

    .hero-desc p {
        font-size: 1.0rem !important;
        line-height: 1.5 !important;
        color: rgba(255, 255, 255, 0.9) !important;
    }

    /* Ensure the social proof section has room */
    .trust-indicator {
        margin-top: 15px !important;
        padding-top: 10px !important;
        border-top: 1px solid rgba(255, 255, 255, 0.05) !important;
        width: 100% !important;
    }
}

/* Ensure no text collisions or overlaps */
.hero-desc p {
    margin: 0 !important;
}

/* Fix for the Hero Button height on mobile */
@media (max-width: 768px) {
    .btn-hero {
        padding: 12px 28px !important;
        font-size: 1.0rem !important;
        margin-top: 10px !important;
        margin-bottom: 10px !important;
    }
}

/* =========================================
   🚨 ABSOLUTE ANIMATION CENTERING LOCK 🚨
   ========================================= */

/* Wipe legacy animations */
.nav-links a::after, 
.nav-links a:not(.btn-nav)::after,
.nav-dropdown-content a::after {
    display: none !important;
}

/* Unified New Centered Animation */
.nav-links a:not(.btn-nav) {
    position: relative !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.nav-links a:not(.btn-nav)::before {
    content: "" !important;
    position: absolute !important;
    bottom: -5px !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    height: 2px !important;
    background: var(--primary-color) !important;
    width: 0 !important;
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    display: block !important;
}

.nav-links a:not(.btn-nav):hover::before {
    width: 25px !important; /* Elegant, small centered indicator */
}

@media (max-width: 992px) {
    .nav-links a:not(.btn-nav):hover::before {
        width: 40px !important; /* Slightly wider for mobile touch targets */
    }
}

/* =========================================
   🚨 HIGH-ENERGY ANIMATION & RATIO BOOST 🚨
   ========================================= */

/* Replace 'Lazy' animation with an Elastic, High-Energy pop */
.nav-links a:not(.btn-nav)::before {
    transition: width 0.4s cubic-bezier(0.68, -0.6, 0.32, 1.6) !important;
}

.nav-links a:not(.btn-nav):hover {
    transform: translateY(-1px) !important;
    transition: transform 0.2s ease-out !important;
}

/* Mobile Ratio Boost (Larger Headline & Impactful Text) */
@media (max-width: 992px) {
    header h1 {
        font-size: 3.2rem !important; /* SIGNIFICANT BOOST */
        line-height: 1.1 !important;
        letter-spacing: -1.5px !important;
        margin-top: 10px !important;
        margin-bottom: 8px !important;
    }

    .badge {
        font-size: 1.0rem !important; /* Bigger subtitle badge */
        padding: 8px 20px !important;
        font-weight: 700 !important;
        margin-bottom: 20px !important;
    }

    .hero-desc p {
        font-size: 1.15rem !important; /* More readable, 'Pro' feel */
        line-height: 1.6 !important;
        font-weight: 500 !important;
        color: #ffffff !important;
        opacity: 0.95 !important;
    }

    /* Tighten the glass container but keep internal breathing room */
    .glass-field {
        padding: 35px 25px !important;
        gap: 25px !important;
    }
}

/* Boost the Hero Button on mobile even more */
@media (max-width: 768px) {
    .btn-hero {
        padding: 16px 36px !important;
        font-size: 1.1rem !important;
        font-weight: 900 !important;
    }
}

/* =========================================
   🚨 HYPER-RESPONSIVE MENU REBUILD 🚨
   ========================================= */

/* High-speed interaction feedback */
.nav-links a:not(.btn-nav) {
    transition: all 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275) !important;
}

.nav-links a:not(.btn-nav):hover {
    transform: scale(1.1) translateY(-2px) !important; /* Scale pop */
    color: var(--primary-color) !important;
    text-shadow: 0 0 15px rgba(14, 165, 233, 0.6) !important; /* Neon glow */
}

/* Flashy Underline (Rainbow Shimmer) */
.nav-links a:not(.btn-nav)::before {
    height: 3px !important;
    background: linear-gradient(90deg, #00d4ff, #d500f9, #ff007f) !important;
    background-size: 200% auto !important;
    animation: shimmer 2s linear infinite !important;
    transition: width 0.3s cubic-bezier(0.68, -0.6, 0.32, 1.6) !important;
}

.nav-links a:not(.btn-nav):hover::before {
    width: 100% !important; /* Full width for 'Not Lazy' feel */
}

@keyframes shimmer {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

@media (max-width: 992px) {
    .nav-links a:not(.btn-nav):hover::before {
        width: 60px !important; /* Centered but impactful on mobile */
    }
}

/* =========================================
   🚨 ELECTRIC BLUE SPEED BOOST 🚨
   ========================================= */

/* Faster, leaner interaction speed */
.nav-links a:not(.btn-nav) {
    transition: all 0.15s ease-out !important; /* Shaved 50ms for 'Instant' feel */
}

.nav-links a:not(.btn-nav):hover {
    transform: scale(1.08) translateY(-1px) !important; /* Slightly more subtle pop */
    color: var(--primary-color) !important;
}

/* Electric Blue Velocity Underline */
.nav-links a:not(.btn-nav)::before {
    background: var(--primary-color) !important; /* BACK TO BLUE */
    height: 2px !important;
    animation: none !important; /* Kill shimmer */
    transition: width 0.2s cubic-bezier(0.2, 1, 0.3, 1) !important; /* Fast and precise */
}

.nav-links a:not(.btn-nav):hover::before {
    width: 35px !important; /* Decisive, centered, fast */
}

@media (max-width: 992px) {
    .nav-links a:not(.btn-nav):hover::before {
        width: 50px !important;
    }
}

/* =========================================
   🚨 LEFT-TO-RIGHT WIPE RESTORATION 🚨
   ========================================= */

/* Reset the pseudo-element for Left anchor */
.nav-links a:not(.btn-nav)::before {
    left: 0 !important; /* ANCHOR LEFT */
    transform: none !important; /* REMOVE CENTERING */
    width: 0 !important;
    transition: width 0.25s cubic-bezier(0.2, 1, 0.3, 1) !important;
}

/* Full Width Expansion */
.nav-links a:not(.btn-nav):hover::before {
    width: 100% !important; /* THROUGH WHOLE TEXT */
}

/* Ensure link items have enough padding for the full underline */
.nav-links a:not(.btn-nav) {
    padding: 10px 15px !important;
}

@media (max-width: 992px) {
    .nav-links a:not(.btn-nav)::before {
        bottom: 2px !important;
    }
}

/* =========================================
   🚨 SMOOTH LIQUID NAVIGATION REFINEMENT 🚨
   ========================================= */

/* Tighten the spacing between nav items */
.nav-links {
    gap: 15px !important; /* Reduced from 25px-35px to bring items closer */
}

.nav-links a:not(.btn-nav) {
    padding: 8px 10px !important; /* Reduced padding for tighter layout */
    transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1) !important; /* Smoother, liquid transition */
}

/* Re-calibrated Wipe Animation (Liquid & Smooth) */
.nav-links a:not(.btn-nav)::before {
    height: 2px !important;
    bottom: -2px !important;
    transition: width 0.4s cubic-bezier(0.16, 1, 0.3, 1) !important; /* Premium 'Liquid' feel */
}

/* Ensure mobile items aren't too crowded but remain centered */
@media (max-width: 992px) {
    .nav-links {
        gap: 10px !important;
    }
    
    .nav-links a:not(.btn-nav) {
        margin: 5px 0 !important;
    }
}

/* =========================================
   🚨 CINEMATIC NAVIGATION REFINEMENT 🚨
   ========================================= */

/* Soften the hover response for more presence */
.nav-links a:not(.btn-nav) {
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1) !important; /* Gentle and smooth */
}

.nav-links a:not(.btn-nav):hover {
    transform: scale(1.05) !important; /* Extremely subtle pop */
}

/* Cinematic Wipe (0.6s - Noble and smooth) */
.nav-links a:not(.btn-nav)::before {
    transition: width 0.6s cubic-bezier(0.33, 1, 0.68, 1) !important; /* Slow, noble flow */
}

/* =========================================
   🚨 GOLDEN RATIO NAVIGATION TIMING 🚨
   ========================================= */

/* Shifting to the precise 0.45s balance point */
.nav-links a:not(.btn-nav) {
    transition: all 0.4s cubic-bezier(0.2, 0.8, 0.2, 1) !important;
}

/* Golden Wipe (0.45s - Perfect snappy fluidity) */
.nav-links a:not(.btn-nav)::before {
    transition: width 0.45s cubic-bezier(0.3, 1, 0.4, 1) !important;
}









/* =========================================
   🚨 AKO TO FUNGUJE - MOBILE GAP FIX 🚨
   ========================================= */
@media (max-width: 650px) {
    .how-it-works-accordion .features {
        margin-top: 35px !important; /* Zväčší medzeru pod nadpisom */
    }
}

/* =========================================
   🚨 RESERVATION SPACING FIX 🚨
   ========================================= */
#plan-container {
    margin-top: 50px !important; /* Spacing between How it Works and Selector */
}

@media (max-width: 650px) {
    #plan-container {
        margin-top: 30px !important;
    }
}

/* =========================================
   🚨 RESERVATION UI REFINEMENTS 🚨
   ========================================= */
@media (max-width: 650px) {
    /* 1. Plan Variant Cards - More Natural & Consistent */
    .plan-option-card {
        padding: 22px 18px !important;
        min-height: 110px !important; /* Approximately same height */
        display: flex !important;
        flex-direction: column !important;
        justify-content: center !important;
        gap: 8px !important;
    }

    .plan-option-name {
        font-size: 1rem !important;
    }

    /* 2. Subject Cards - Font Fitting Fix */
    .subject-card {
        padding: 15px 8px !important;
        flex: 1 !important;
        min-width: 0 !important; /* Allow shrinking */
        min-height: 110px !important; /* Match vertical rhythm */
    }

    .subject-card-title {
        font-size: 0.82rem !important; /* Shrink to fit Matematika/Slovenčina */
        font-weight: 800 !important;
        margin-top: 5px !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }
}

/* =========================================
   🚨 GAP COMPRESSION (MOBILE) 🚨
   ========================================= */
@media (max-width: 650px) {
    /* 1. Category/Focus Buttons - Tighten */
    .cat-group, .subjects-filter, .filter-container {
        gap: 8px !important;
        margin-bottom: 20px !important;
    }

    /* 2. "How it Works" Steps - Tighten */
    .features {
        gap: 12px !important;
    }

    .accordion-item {
        margin-bottom: 0 !important; /* Remove individual block gaps */
        padding: 15px 12px !important; /* Slightly more compact */
    }
}
/* =========================================
   TESTIMONIAL SECTION STYLES (GRID)
   ========================================= */
.testimonial-section {
    width: 100% !important;
    max-width: 1100px !important;
    margin: 0 auto 60px !important;
    text-align: center;
    box-sizing: border-box !important;
}

.testimonial-slider-wrapper {
    position: relative;
    width: 100%;
    padding: 0;
    overflow: visible;
}

.slider-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 48px;
    height: 48px;
    background: var(--glass-bg) !important;
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
    border: 1px solid var(--border-color) !important;
    border-radius: 50% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    cursor: pointer !important;
    z-index: 50 !important;
    transition: var(--transition) !important;
    color: var(--text-dark) !important;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1) !important;
    padding: 0 !important;
}

.slider-arrow:hover {
    background: var(--primary-color) !important;
    color: white !important;
    transform: translateY(-50%) scale(1.1) !important;
    box-shadow: 0 8px 25px rgba(37, 99, 235, 0.3) !important;
}

.slider-arrow.prev { left: -25px; }
.slider-arrow.next { right: -25px; }

@media (max-width: 1200px) {
    .slider-arrow.prev { left: 5px; }
    .slider-arrow.next { right: 5px; }
}

@media (max-width: 768px) {
    .slider-arrow { display: none !important; }
    .load-more-wrap { display: none !important; }
}

.testimonial-grid {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    overflow-x: auto !important;
    scroll-snap-type: x mandatory !important;
    gap: 20px !important;
    width: 100% !important;
    margin-top: 30px !important;
    padding: 20px 10px !important; /* Safety for card shadows and scroll snap */
    scrollbar-width: none !important; /* Firefox */
    -ms-overflow-style: none !important; /* IE 10+ */
    -webkit-overflow-scrolling: touch !important;
    align-items: stretch !important; /* Prevents stretching all cards when one expands */
}

.testimonial-grid::-webkit-scrollbar {
    display: none !important; /* Chrome, Safari, Opera */
}

.testimonial-card {
    flex: 0 0 88% !important;
    scroll-snap-align: center !important;
    margin: 0 5px; /* Slight gap for snapping */
    background: var(--bg-card);
    border: 2px solid rgba(37, 99, 235, 0.15);
    border-radius: 24px;
    padding: 25px;
    position: relative;
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.05);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    text-align: left;
    min-height: 350px !important; /* Increased height */
    cursor: pointer !important; /* Entire card is clickable */
}

@media (min-width: 769px) {
    .testimonial-card {
        flex: 0 0 calc(33.333% - 15px) !important; /* Slightly smaller to fit 3 cards perfectly with gaps */
        min-height: 380px !important; /* Even taller on desktop */
    }
}

.testimonial-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.1);
    border-color: var(--primary-color);
}

.quote-icon {
    position: absolute;
    top: 15px;
    right: 20px;
    color: var(--primary-color);
    opacity: 0.1;
}

.testimonial-text {
    font-size: 1.15rem !important; /* Increased font size */
    line-height: 1.6;
    color: var(--text-dark);
    font-weight: 600;
    margin-bottom: 15px;
    font-style: italic;
    position: relative;
    max-height: 180px !important; /* Increased preview height */
    overflow: hidden;
    transition: max-height 0.5s ease;
}

.testimonial-card.expanded {
    border-color: var(--primary-color) !important;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.2) !important;
    z-index: 5 !important;
}

.testimonial-card.expanded .testimonial-text {
    max-height: 1000px !important;
}

.text-overlay {
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    height: 80px;
    background: linear-gradient(to bottom, transparent, var(--bg-card) 95%);
    pointer-events: none;
    transition: opacity 0.3s;
}

.testimonial-card.expanded .text-overlay,
.testimonial-card.no-overflow .text-overlay {
    opacity: 0 !important;
    pointer-events: none !important;
}

.testimonial-card.no-overflow .read-more-hint {
    display: none !important;
}

.read-more-hint {
    position: absolute;
    bottom: 30px; /* Slight adjustment */
    left: 50%;
    transform: translateX(-50%) translateY(10px);
    opacity: 0;
    color: var(--primary-color);
    font-weight: 700;
    font-size: 0.85rem;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    pointer-events: none;
    white-space: nowrap;
}

.testimonial-card:hover .read-more-hint {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

@media (max-width: 768px) {
    .read-more-hint {
        opacity: 1 !important;
        transform: translateX(-50%) translateY(0) !important;
        bottom: 20px; /* Slightly lower on mobile to save space */
        font-size: 0.8rem;
    }
}

.testimonial-user {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-top: auto !important; /* Pin to bottom */
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

.testimonial-avatar {
    width: 54px !important;
    height: 54px !important;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--primary-color);
}

.testimonial-avatar-placeholder {
    width: 54px !important;
    height: 54px !important;
    border-radius: 50%;
    background: var(--primary-light);
    color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--primary-color);
}

.user-info {
    display: flex;
    flex-direction: column;
}

.user-name {
    font-size: 1.1rem !important;
    font-weight: 800;
    color: var(--text-dark);
}

.user-meta {
    font-size: 0.85rem !important;
    color: var(--text-dim);
    font-weight: 600;
}

.stars {
    display: flex;
    gap: 4px;
    color: #f59e0b;
    margin-top: 10px;
}

.testimonial-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(6, 11, 25, 0.9);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 15px; /* Minimal padding for mobile safety */
    opacity: 0;
    transition: opacity 0.4s ease;
    box-sizing: border-box;
}

.testimonial-overlay.active {
    display: flex;
    opacity: 1;
}

.overlay-content {
    background: var(--bg-card);
    border: 2px solid var(--primary-color);
    border-radius: 25px;
    padding: 40px 30px;
    max-width: 850px;
    width: 100%;
    position: relative;
    box-shadow: 0 40px 100px rgba(0, 0, 0, 0.5);
    transform: scale(0.9) translateY(20px);
    transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    max-height: 90vh;
    overflow-y: auto;
    box-sizing: border-box;
}

.testimonial-overlay.active .overlay-content {
    transform: scale(1) translateY(0);
}

.close-overlay {
    position: absolute;
    top: 25px;
    right: 25px;
    background: var(--primary-light);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--primary-color);
    transition: var(--transition);
    z-index: 10;
}

.close-overlay:hover {
    background: var(--primary-color);
    color: white;
    transform: rotate(90deg);
}

.overlay-quote {
    position: absolute;
    top: 40px;
    right: 50px;
    color: var(--primary-color);
    opacity: 0.1;
    font-size: 80px;
    pointer-events: none;
}

.overlay-text {
    font-size: 1.3rem;
    line-height: 1.7;
    color: var(--text-dark);
    font-weight: 500;
    margin-bottom: 30px;
    font-style: italic;
    padding-right: 60px; /* Prevent overlap with X button */
}

.overlay-user-info {
    display: flex;
    align-items: center;
    gap: 20px;
    padding-top: 30px;
    border-top: 1px solid var(--border-color);
}

.overlay-avatar {
    width: 65px;
    height: 65px;
    border-radius: 50%;
    border: 2px solid var(--primary-color);
    object-fit: cover;
}

.overlay-avatar-placeholder {
    width: 65px;
    height: 65px;
    border-radius: 50%;
    background: var(--primary-light);
    color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--primary-color);
}

.overlay-user-details h4 {
    margin: 0;
    font-size: 1.3rem;
    font-weight: 800;
}

.overlay-user-details p {
    margin: 0;
    color: var(--text-dim);
    font-weight: 600;
}

@media (max-width: 768px) {
    .overlay-content {
        padding: 60px 20px 30px !important;
        border-radius: 20px !important;
        width: 100% !important;
        margin: 0 !important;
    }
    .overlay-text {
        font-size: 1.05rem !important;
        padding-right: 0 !important;
        text-align: left;
        line-height: 1.6 !important;
    }
    .close-overlay {
        top: 15px !important;
        right: 15px !important;
        width: 36px !important;
        height: 36px !important;
    }
    .overlay-user-info {
        gap: 15px !important;
    }
    .overlay-avatar, .overlay-avatar-placeholder {
        width: 55px !important;
        height: 55px !important;
    }
}

/* Testimonial grid override removed in favor of flex slider above */

/* =========================================
   NEW PREMIUM FOOTER STYLES
   ========================================= */
.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 30px;
}

.contact-info {
    display: flex;
    gap: 30px;
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 10px;
}

.contact-link {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-dark);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    transition: var(--transition);
}

a.contact-link:hover {
    color: var(--primary-color);
    transform: translateY(-2px);
}

.footer-divider {
    width: 100%;
    max-width: 600px;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--border-color), transparent);
    margin: 10px 0;
}

.footer-social-btn-only {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    background: var(--bg-main);
    border: 1px solid var(--border-color);
    border-radius: 50%;
    color: var(--text-dark);
    text-decoration: none;
    transition: var(--transition);
}

.footer-social-btn-only:hover {
    background: var(--primary-light);
    border-color: var(--primary-color);
    color: var(--primary-color);
    transform: translateY(-5px) scale(1.1);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.footer-social-btn-only svg {
    color: #E1306C;
    width: 28px;
    height: 28px;
}

.footer-legal {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
    justify-content: center;
}

.legal-link {
    color: var(--text-dim);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: var(--transition);
}

.legal-link:hover {
    color: var(--text-dark);
}

.legal-sep {
    width: 4px;
    height: 4px;
    background: var(--text-dim);
    border-radius: 50%;
    opacity: 0.3;
}

.footer-copyright {
    color: var(--text-dim);
    font-size: 0.85rem;
    margin: 0;
    opacity: 0.8;
}

@media (max-width: 650px) {
    .contact-info {
        flex-direction: column;
        gap: 15px;
    }
    
    .footer-legal {
        flex-direction: column;
        gap: 12px;
    }
    
    .legal-sep {
        display: none;
    }
}
