
/* Force navbar to be above everything including search bar and hero */
.navbar {
    z-index: 100000 !important;
}
.navbar .container {
    z-index: 100000 !important;
}

/* ============================================
   CCDSITEL — MOBILE RESPONSIVE OVERRIDES
   Loaded AFTER corporate_redesign.css
   ============================================ */

/* ===== TABLET (max-width: 1024px) ===== */
@media (max-width: 1024px) {
    .hero-grid {
        grid-template-columns: 1fr !important;
        text-align: center !important;
        gap: 30px !important;
    }

    .hero-content .hero-sub {
        margin-left: auto !important;
        margin-right: auto !important;
    }

    .hero-buttons {
        justify-content: center !important;
    }

    .hero-stats {
        max-width: 420px !important;
        margin: 30px auto 0 !important;
    }

    .services-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 20px !important;
    }

    .catalog-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 20px !important;
    }

    .why-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 20px !important;
    }

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

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

    .footer-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 30px !important;
    }

    .clients-grid {
        grid-template-columns: repeat(3, 1fr) !important;
    }

    .video-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }

    /* Construction popup */
    .under-construction-popup {
        width: 340px !important;
        right: 20px !important;
        padding: 22px !important;
    }

    .under-construction-popup h4 {
        font-size: 20px !important;
    }

    .under-construction-popup p {
        font-size: 15px !important;
    }
}

/* ===== MOBILE (max-width: 768px) ===== */
@media (max-width: 768px) {
    /* Top bar: hide phone numbers, keep compact */
    .top-bar {
        padding: 6px 0 !important;
        font-size: 0.7rem !important;
    }

    .top-bar .container {
        justify-content: center !important;
        flex-wrap: wrap !important;
        gap: 4px !important;
    }

    .top-bar-left {
        display: none !important;
    }

    .top-bar-right {
        font-size: 0.7rem !important;
        text-align: center !important;
    }

    /* Navbar */
    .navbar .container {
        height: 60px !important;
        padding: 0 16px !important;
    }

    .logo-img {
        height: 34px !important;
    }

    .nav-links {
        display: none !important;
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        right: 0 !important;
        bottom: 0 !important;
        background: rgba(11, 17, 32, 0.97) !important;
        backdrop-filter: blur(24px) !important;
        -webkit-backdrop-filter: blur(24px) !important;
        flex-direction: column !important;
        justify-content: center !important;
        align-items: center !important;
        gap: 6px !important;
        padding: 80px 30px 40px !important;
        z-index: 99999 !important;
        overflow-y: auto !important;
    }

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

    .nav-links a {
        font-size: 1.05rem !important;
        padding: 16px 24px !important;
        color: rgba(255, 255, 255, 0.85) !important;
        text-align: center !important;
        width: 100% !important;
        max-width: 280px !important;
        border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
        letter-spacing: 0.02em !important;
        font-weight: 500 !important;
        transition: all 0.2s ease !important;
    }

    .nav-links a:last-child {
        border-bottom: none !important;
    }

    .nav-links a:hover,
    .nav-links a:active {
        background: rgba(37, 99, 235, 0.15) !important;
        border-radius: 12px !important;
        color: #ffffff !important;
        border-bottom-color: transparent !important;
    }

    .nav-links .btn-nav,
    .nav-links a.btn.btn-outline {
        margin-top: 12px !important;
        background: linear-gradient(135deg, #2563EB, #3B82F6) !important;
        border: none !important;
        border-radius: 50px !important;
        padding: 14px 32px !important;
        font-weight: 700 !important;
        color: #ffffff !important;
        border-bottom: none !important;
        box-shadow: 0 4px 15px rgba(37, 99, 235, 0.3) !important;
    }

    .hamburger {
        display: flex !important;
    }

    .hamburger span {
        background: #E2E8F0 !important;
    }

    /* Hero */
    .hero {
        padding: 80px 0 50px !important;
        min-height: auto !important;
    }

    .hero-content h1 {
        font-size: 1.9rem !important;
        line-height: 1.2 !important;
    }

    .hero-content h1 .hero-subtitle-line {
        font-size: 0.65em !important;
    }

    .hero-content .hero-sub {
        font-size: 0.95rem !important;
        margin-bottom: 25px !important;
    }

    .hero-buttons {
        flex-direction: column !important;
        align-items: center !important;
        gap: 12px !important;
    }

    .hero-buttons .btn {
        width: 100% !important;
        max-width: 280px !important;
        justify-content: center !important;
    }

    .hero-stats {
        grid-template-columns: 1fr 1fr !important;
        gap: 10px !important;
        max-width: 100% !important;
    }

    .stat-card {
        padding: 20px 16px !important;
    }

    .stat-number {
        font-size: 1.8rem !important;
    }

    .stat-label {
        font-size: 0.75rem !important;
    }

    /* Sections - General */
    section {
        padding: 60px 0 !important;
    }

    .container {
        padding: 0 16px !important;
    }

    .section-header {
        margin-bottom: 30px !important;
    }

    .section-header h2 {
        font-size: 1.6rem !important;
        line-height: 1.25 !important;
    }

    .section-header p {
        font-size: 0.9rem !important;
    }

    .section-label {
        font-size: 0.65rem !important;
        padding: 4px 12px !important;
    }

    /* Services - 1 column on mobile */
    .services-grid {
        grid-template-columns: 1fr !important;
        gap: 16px !important;
    }

    .service-card {
        padding: 28px 22px !important;
    }

    /* Catalog - 1 column */
    .catalog-grid {
        grid-template-columns: 1fr !important;
        gap: 16px !important;
    }

    .catalog-card {
        padding: 28px 20px !important;
    }

    /* Why Us - 1 column */
    .why-grid {
        grid-template-columns: 1fr !important;
        gap: 16px !important;
    }

    .why-card {
        padding: 28px 22px !important;
    }

    /* Videos */
    .video-grid {
        grid-template-columns: 1fr !important;
        gap: 16px !important;
    }

    .video-filter-btn {
        font-size: 0.75rem !important;
        padding: 8px 14px !important;
    }

    /* About */
    .about-grid {
        grid-template-columns: 1fr !important;
        gap: 20px !important;
    }

    .about .about-card-main {
        padding: 24px !important;
    }

    /* Clients */
    .clients-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 12px !important;
    }

    .client-item {
        padding: 16px !important;
    }

    /* Contact */
    .contact-grid {
        grid-template-columns: 1fr !important;
        gap: 20px !important;
    }

    .contact-info {
        padding: 24px !important;
    }

    .contact-form-wrapper {
        padding: 24px !important;
    }

    .form-row {
        grid-template-columns: 1fr !important;
    }

    /* Footer */
    .footer {
        padding: 40px 0 20px !important;
    }

    .footer-grid {
        grid-template-columns: 1fr !important;
        gap: 30px !important;
        text-align: center !important;
    }

    .footer-brand p {
        max-width: 100% !important;
        margin: 0 auto !important;
    }

    .footer-bottom {
        flex-direction: column !important;
        gap: 10px !important;
        text-align: center !important;
    }

    /* Search */
    .global-search-section {
        padding: 30px 16px 0 !important;
    }

    .global-search-input-wrap {
        max-width: 100% !important;
    }

    .global-search-input-wrap input {
        font-size: 0.9rem !important;
    }

    /* Banner carousel */
    .banner-carousel {
        margin-top: -15px !important;
        padding: 0 8px !important;
    }

    .banner-track {
        border-radius: 10px !important;
    }

    .banner-arrow {
        width: 32px !important;
        height: 32px !important;
        font-size: 1rem !important;
    }

    /* WhatsApp button */
    .whatsapp-float {
        width: 50px !important;
        height: 50px !important;
        bottom: 20px !important;
        right: 20px !important;
        font-size: 1.5rem !important;
    }

    /* Construction popup - mobile */
    .under-construction-popup {
        top: auto !important;
        bottom: 80px !important;
        right: 10px !important;
        left: 10px !important;
        width: auto !important;
        padding: 20px !important;
        border-radius: 14px !important;
    }

    .under-construction-popup h4 {
        font-size: 18px !important;
        gap: 8px !important;
    }

    .under-construction-popup h4 span {
        font-size: 22px !important;
    }

    .under-construction-popup p {
        font-size: 14px !important;
        line-height: 1.5 !important;
    }

    /* Brands section */
    .brands-section {
        padding: 25px 0 !important;
    }
}

/* ===== SMALL PHONE (max-width: 480px) ===== */
@media (max-width: 480px) {
    .hero-content h1 {
        font-size: 1.55rem !important;
    }

    .hero-stats {
        grid-template-columns: 1fr 1fr !important;
        gap: 8px !important;
    }

    .stat-card {
        padding: 16px 12px !important;
    }

    .stat-number {
        font-size: 1.5rem !important;
    }

    .stat-label {
        font-size: 0.7rem !important;
    }

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

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

    .clients-grid {
        grid-template-columns: 1fr 1fr !important;
        gap: 10px !important;
    }

    .about-features {
        grid-template-columns: 1fr !important;
    }

    .btn {
        font-size: 0.85rem !important;
        padding: 12px 22px !important;
    }

    .navbar .container {
        height: 55px !important;
    }

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

    /* Make construction popup smaller */
    .under-construction-popup {
        bottom: 70px !important;
        padding: 16px !important;
    }

    .under-construction-popup h4 {
        font-size: 16px !important;
    }

    .under-construction-popup p {
        font-size: 13px !important;
    }
}

/* ===== VERY SMALL PHONE (max-width: 360px) ===== */
@media (max-width: 360px) {
    .hero-content h1 {
        font-size: 1.35rem !important;
    }

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

    .hero-stats {
        grid-template-columns: 1fr !important;
    }

    .stat-card {
        padding: 14px 10px !important;
    }
}


/* ============================================
   AGGRESSIVE MOBILE MENU FIX
   Forces fullscreen overlay regardless of
   conflicting styles from other CSS files
   ============================================ */
@media (max-width: 768px) {
    /* Kill the old dropdown positioning from styles.css */
    .nav-links,
    nav .nav-links,
    .navbar .nav-links {
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        right: 0 !important;
        bottom: 0 !important;
        width: 100vw !important;
        height: 100vh !important;
        background: #0B1120 !important;
        background-color: #0B1120 !important;
        opacity: 1 !important;
        flex-direction: column !important;
        justify-content: center !important;
        align-items: center !important;
        gap: 0 !important;
        padding: 60px 20px 40px !important;
        z-index: 999999 !important;
        overflow-y: auto !important;
        box-shadow: none !important;
        border: none !important;
        border-top: none !important;
    }

    .nav-links:not(.active),
    nav .nav-links:not(.active),
    .navbar .nav-links:not(.active) {
        display: none !important;
    }

    .nav-links.active,
    nav .nav-links.active,
    .navbar .nav-links.active {
        display: flex !important;
    }

    .nav-links a,
    .nav-links.active a {
        font-size: 1.1rem !important;
        padding: 18px 20px !important;
        color: #E2E8F0 !important;
        text-align: center !important;
        width: 90% !important;
        max-width: 300px !important;
        border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
        font-weight: 500 !important;
        background: transparent !important;
        display: block !important;
        text-decoration: none !important;
    }

    .nav-links a:last-child {
        border-bottom: none !important;
    }

    /* Animated underline off in mobile menu */
    .nav-links a:not(.btn-nav)::after {
        display: none !important;
    }

    .nav-links .btn-nav,
    .nav-links a.btn.btn-outline,
    .nav-links.active .btn-nav {
        margin-top: 20px !important;
        background: linear-gradient(135deg, #2563EB, #3B82F6) !important;
        border: none !important;
        border-radius: 50px !important;
        padding: 16px 36px !important;
        font-weight: 700 !important;
        color: #ffffff !important;
        border-bottom: none !important;
        box-shadow: 0 4px 15px rgba(37, 99, 235, 0.3) !important;
        font-size: 1.1rem !important;
    }

    /* Hamburger always visible and above overlay */
    .hamburger {
        display: flex !important;
        z-index: 9999999 !important;
        position: relative !important;
    }

    /* Banner fix: don't overlap with stat cards */
    .under-construction-popup {
        position: fixed !important;
        top: auto !important;
        bottom: 20px !important;
        left: 16px !important;
        right: 16px !important;
        width: auto !important;
        max-width: 100% !important;
        padding: 16px 20px !important;
        border-radius: 14px !important;
        z-index: 99998 !important;
    }

    .under-construction-popup h4 {
        font-size: 16px !important;
        margin-bottom: 8px !important;
    }

    .under-construction-popup h4 span {
        font-size: 20px !important;
    }

    .under-construction-popup p {
        font-size: 13px !important;
        line-height: 1.4 !important;
    }
}

@media (max-width: 480px) {
    .nav-links a,
    .nav-links.active a {
        font-size: 1rem !important;
        padding: 16px 16px !important;
    }

    .under-construction-popup {
        bottom: 14px !important;
        left: 10px !important;
        right: 10px !important;
        padding: 14px 16px !important;
    }

    .under-construction-popup h4 {
        font-size: 14px !important;
    }

    .under-construction-popup p {
        font-size: 12px !important;
    }
}
