* ====================================================================
   HERO SECTION - COMPLETE MOBILE FIX
==================================================================== */

/* Prevent page-wide horizontal overflow */
@media (max-width: 768px) {
    html, body {
        width: 100% !important;
        max-width: 100% !important;
        overflow-x: hidden !important;
        box-sizing: border-box !important;
    }

    /* Fix hero container - key solution */
    .hero {
        width: 100% !important;
        max-width: 100% !important;
        height: auto !important;
        aspect-ratio: 16 / 9 !important; /* Force video proportions */
        margin: 0 !important;
        padding: 0 !important;
        
        /* Kill all curves/rounding */
        border-radius: 0 !important;
        border-bottom-left-radius: 0 !important;
        border-bottom-right-radius: 0 !important;
        
        /* Contain everything */
        overflow: hidden !important;
        position: relative !important;
        background: #000 !important;
    }

    .hero-video-container {
        width: 100% !important;
        height: 100% !important;
        position: relative !important;
        border-radius: 0 !important;
        overflow: hidden !important;
    }

    /* Show desktop video (has the correct flag design) */
    .hero-video-desktop {
        display: block !important;
        width: 100% !important;
        height: 100% !important;
        object-fit: contain !important; /* Show FULL flag - no cropping */
        position: relative !important;
        top: 0 !important;
        left: 0 !important;
        transform: none !important;
        border-radius: 0 !important;
    }

    /* Hide mobile video (may be causing issues) */
    .hero-video-mobile {
        display: none !important;
    }

    /* Remove any pseudo-elements causing curves */
    .hero::before,
    .hero::after,
    .hero-video-container::before,
    .hero-video-container::after {
        display: none !important;
        content: none !important;
    }
}

/* ====================================================================
   DEVELOPER TICKER - SHOW ACTUAL LOGOS
==================================================================== */
@media (max-width: 768px) {
    .developer-ticker {
        width: 100% !important;
        display: block !important;
        padding: 20px 0 !important;
        background: #000 !important;
        overflow: hidden !important;
        margin: 0 !important;
    }

    .developer-ticker-wrapper {
        overflow: hidden !important;
        width: 100% !important;
    }

    .developer-ticker-content {
        display: flex !important;
        gap: 40px !important;
        animation: scroll-dev 60s linear infinite !important;
        align-items: center !important;
    }

    .developer-item {
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        flex-shrink: 0 !important;
        min-width: 120px !important;
    }

    .developer-logo {
        display: block !important;
        visibility: visible !important;
        height: 36px !important;
        width: auto !important;
        max-width: 140px !important;
        object-fit: contain !important;
        filter: brightness(0) invert(1) !important;
        opacity: 1 !important;
    }
}

@keyframes scroll-dev {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* ====================================================================
   STATS SECTION - VERTICAL LAYOUT FIX
==================================================================== */
@media (max-width: 768px) {
    .main-title-section {
        width: 100% !important;
        max-width: 100% !important;
        padding: 32px 16px 24px !important;
        overflow-x: hidden !important;
        box-sizing: border-box !important;
    }

    .main-heading {
        font-size: 28px !important;
        line-height: 1.2 !important;
        word-wrap: break-word !important;
        margin-bottom: 16px !important;
    }

    .main-subtitle {
        font-size: 15px !important;
        line-height: 1.6 !important;
        word-wrap: break-word !important;
        margin-bottom: 32px !important;
    }

    .stats-bar {
        display: flex !important;
        flex-direction: column !important;
        gap: 16px !important;
        width: 100% !important;
        max-width: 100% !important;
        padding: 24px 16px !important;
        border-top: 1px solid #e5e7eb !important;
        box-sizing: border-box !important;
    }

    .stat-item {
        width: 100% !important;
        padding: 20px 16px !important;
        background: #f9fafb !important;
        border: 1px solid #e5e7eb !important;
        border-radius: 8px !important;
        text-align: center !important;
        box-sizing: border-box !important;
    }

    .stat-value {
        font-size: 28px !important;
        font-weight: 800 !important;
        margin-bottom: 8px !important;
        display: block !important;
        color: #000 !important;
        line-height: 1.2 !important;
    }

    .stat-label {
        font-size: 11px !important;
        color: #6b7280 !important;
        text-transform: uppercase !important;
        letter-spacing: 0.8px !important;
    }
}

/* ====================================================================
   AGENTS SECTION - HORIZONTAL SCROLL + VERTICAL CARDS
==================================================================== */
@media (max-width: 768px) {
    .main-content-wrapper {
        width: 100% !important;
        max-width: 100% !important;
        padding: 0 16px 60px !important;
        box-sizing: border-box !important;
        overflow-x: hidden !important;
    }

    .agents-column {
        position: relative !important;
        top: 0 !important;
        max-height: none !important;
        width: 100% !important;
        padding: 20px 0 !important;
        background: transparent !important;
        overflow-x: hidden !important;
    }

    .agents-list {
        display: flex !important;
        flex-direction: row !important;
        overflow-x: auto !important;
        gap: 16px !important;
        scroll-snap-type: x mandatory !important;
        -webkit-overflow-scrolling: touch !important;
        padding: 0 16px 20px 16px !important;
    }

    .agents-list::-webkit-scrollbar {
        display: none !important;
    }

    .agent-card-compact {
        min-width: 200px !important;
        max-width: 200px !important;
        flex-shrink: 0 !important;
        flex-direction: column !important;
        align-items: center !important;
        text-align: center !important;
        padding: 20px 16px !important;
        scroll-snap-align: center !important;
        background: #fff !important;
        border: 2px solid #dc2626 !important;
        border-radius: 12px !important;
    }

    .agent-photo-compact {
        width: 80px !important;
        height: 80px !important;
        margin-bottom: 12px !important;
        margin-right: 0 !important;
    }

    .agent-name-compact {
        font-size: 14px !important;
        white-space: normal !important;
        line-height: 1.3 !important;
        text-align: center !important;
        margin-bottom: 6px !important;
    }

    .agent-company-compact {
        font-size: 12px !important;
        white-space: normal !important;
        text-align: center !important;
        margin-bottom: 8px !important;
    }
}

/* Layout fixes for larger screens */
@media (max-width: 1200px) {
    .main-content-wrapper {
        flex-direction: column-reverse !important;
    }

    .deals-column,
    .agents-column {
        flex: 0 0 100% !important;
        width: 100% !important;
    }
}