/*
    Atlas Property Group - Responsive Design
    Senior UI/UX Designer
*/

/* =========================================================
   AGENT SIDEBAR
========================================================= */

.agent-sidebar-card.is-sticky-active .agent-card-main-body {
    opacity: 0;
    max-height: 0;
    overflow: hidden;
    pointer-events: none;
}

.agent-sidebar-card.is-sticky-active.is-expanded .agent-card-main-body {
    opacity: 1;
    max-height: 1800px;
    overflow: visible;
    pointer-events: auto;
}

.agent-sidebar-card.is-sticky-active.is-expanded .agent-card-toggle i {
    transform: rotate(180deg);
}

.agent-sidebar-card.is-sticky-active.is-expanded .agent-card-main-body .agent-info h4 {
    display: none;
}


/* =========================================================
   TABLET
========================================================= */

@media (max-width: 1024px) {

    .hero-content h1 {
        font-size: 44px;
    }

    .mega-menu {
        width: 90vw;
    }

    .main-header .nav-actions {
        gap: 8px;
    }

    .main-header .auth-group .btn-gold-sm {
        padding: 7px 10px;
        min-height: 32px;
        font-size: 0.78rem;
        line-height: 1;
    }
}


/* =========================================================
   MOBILE NAVBAR
   ONLY MOBILE/TABLET NAVBAR IS MODIFIED HERE
========================================================= */

@media (max-width: 1024px) {

    /*
        IMPORTANT:
        Keep navbar fixed.
        Do NOT change desktop positioning.
    */

    .main-header {
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        right: 0 !important;

        height: 70px !important;

        padding: 0 !important;

        /*
            Slightly black glass background
        */
        background: rgba(133, 141, 150, 0.58) !important;

        /*
            Glass effect
        */
        -webkit-backdrop-filter: blur(18px) saturate(140%);
        backdrop-filter: blur(18px) saturate(140%);

        /*
            Very subtle separation
        */
        border-bottom: 1px solid rgba(248, 246, 246, 0.08) !important;

        box-shadow:
            0 8px 30px rgba(222, 219, 219, 0.22) !important;

        z-index: 2000 !important;

        /*
            Prevent transparency from disappearing
            while scrolling.
        */
        isolation: isolate;
    }


    /*
        Navbar container
    */

    .navbar {
        display: flex;
        align-items: center;
        justify-content: space-between;

        position: relative;

        height: 70px;

        gap: 8px;

        padding: 0 14px 0 0;
    }


    /*
        Header container
    */

    .main-header > .container {
        padding-left: 0;
        padding-right: 0;
    }


    /*
        Logo
    */

    .logo {
        position: absolute;

        left: 50%;
        top: 46%;

        transform: translate(-50%, -50%);

        display: flex;
        align-items: center;
        justify-content: center;

        z-index: 2100;

        min-width: 0;

        pointer-events: auto;
    }


    .logo-img {
        width: auto;
        max-width: 130px;
        height: 52px;

        object-fit: contain;

        display: block;

        background: transparent;
    }


    /*
        Hamburger
    */

    .mobile-menu-toggle {
        position: absolute;

        left: 0;
        top: 50%;

        transform: translateY(-50%);

        display: flex;

        align-items: center;
        justify-content: center;

        width: 46px;
        height: 46px;

        background: transparent !important;

        border: none !important;

        cursor: pointer;

        z-index: 2200;

        padding: 0;
        margin: 0;

        color: #ffffff !important;
    }


    /*
        Make hamburger icon clearly visible
    */

    .mobile-menu-toggle svg,
    .mobile-menu-toggle i {
        color: #ffffff !important;

        fill: currentColor;

        opacity: 1 !important;

        filter:
            drop-shadow(0 1px 3px rgba(0, 0, 0, 0.45));
        display: block;
        line-height: 1;
        text-align: center;
    }

    .mobile-menu-toggle.is-active {
        position: fixed;
        left: calc(100vw - 320px + 18px);
        right: auto;
        top: 18px;
        transform: none;
        width: 42px;
        height: 42px;
        border-radius: 12px;
        background: rgba(255, 255, 255, 0.08) !important;
        box-shadow: 0 8px 22px rgba(0, 0, 0, 0.18);
        z-index: 2300;
    }


    /*
        Navbar right-side actions
    */

    .nav-actions {
        display: flex;

        align-items: center;
        justify-content: flex-end;

        gap: 8px;

        margin-left: auto;

        min-height: 40px;

        z-index: 2100;
    }


    /* Keep mobile actions focused on account access and navigation. */

    #dark-mode-toggle {
        display: none !important;
    }


    #dark-mode-toggle svg,
    #dark-mode-toggle i {
        color: #ffffff !important;

        fill: currentColor;

        opacity: 1 !important;
    }


    /*
        Logout remains hidden on mobile
    */

    .logout-icon {
        display: none !important;
    }


    /*
        User avatar
    */

    .user-avatar-button {
        width: 40px !important;
        height: 40px !important;

        border-radius: 50%;

        padding: 0;

        border: 1px solid rgba(255, 255, 255, 0.12) !important;
    }


    /*
        Mobile sign-in pinned to the far right edge.
        Leave the hamburger on the left untouched.
    */

    .main-header .auth-group {
        position: absolute;
        right: 12px;
        top: 50%;
        transform: translateY(-50%);
        z-index: 2201;
        margin-left: 0;
    }

    .main-header .auth-group .btn-gold-sm {
        width: 40px;
        min-width: 40px;
        padding: 0;
        min-height: 40px;
        font-size: 0;
        line-height: 1;
        border-radius: 50%;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        color: transparent;
        overflow: hidden;
        position: relative;
        background: transparent !important;
        border-color: rgba(255, 255, 255, 0.15) !important;
        box-shadow: none !important;
    }

    .main-header .auth-group .btn-gold-sm::before {
        content: "\f007";
        font-family: "Font Awesome 6 Free";
        font-weight: 900;
        font-size: 1rem;
        line-height: 1;
        color: #ffffff;
        display: inline-block;
    }

    .main-header .nav-actions {
        gap: 0;
        padding-right: 0;
    }


    /*
        Hero starts underneath fixed navbar
    */

    .hero-slider {
        height: auto;

        min-height: calc(100vh - 70px);

        padding-top: 70px;
        overflow: visible;
    }
}


/* =========================================================
   MOBILE SIDE MENU
========================================================= */

@media (max-width: 768px) {

    /*
        Mobile navigation drawer
    */

    .nav-menu {
        position: fixed !important;

        top: 0 !important;

        right: 0 !important;

        display: none !important;

        height: 100vh;

        width: 320px;

        background: rgba(8, 10, 15, 0.97) !important;

        /*
            Glass drawer
        */

        -webkit-backdrop-filter: blur(22px) saturate(140%);
        backdrop-filter: blur(22px) saturate(140%);

        flex-direction: column;

        padding: 100px 24px;

        transition: none;

        box-shadow:
            -10px 0 40px rgba(0, 0, 0, 0.35);

        border-left: 1px solid rgba(255, 255, 255, 0.08);

        z-index: 2100;

        gap: 20px;

        overflow-y: auto;

        color: #ffffff !important;
    }


    /*
        Open mobile menu
    */

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


    /*
        Mobile menu links
    */

    .nav-menu a {
        display: block;

        font-size: 16px;

        padding: 12px 0;

        color: #ffffff !important;

        text-decoration: none;
    }


    /*
        Hover
    */

    .nav-menu a:hover,
    .nav-menu a:focus-visible {
        color: #ffffff !important;
    }


    /*
        Properties menu
    */

    .nav-menu .has-mega {
        display: flex;

        flex-direction: row;

        flex-wrap: wrap;

        align-items: center;

        justify-content: space-between;

        gap: 0;

        position: relative;
    }


    .nav-menu .has-mega .mega-link {
        width: auto;

        font-weight: 700;

        display: flex !important;

        justify-content: flex-start;

        align-items: center;

        padding: 12px 8px;

        gap: 8px;

        color: #ffffff !important;
    }


    /*
        Properties arrow
    */

    .nav-menu .has-mega .mega-toggle {
        display: inline-flex;

        align-items: center;
        justify-content: center;

        background: transparent !important;

        border: none !important;

        color: #ffffff !important;

        cursor: pointer;

        font-size: 11px;

        width: 20px;
        height: 20px;
        padding: 0;

        margin-left: auto;

        align-self: center;
    }


    .nav-menu .has-mega .mega-toggle svg,
    .nav-menu .has-mega .mega-toggle i {
        color: #ffffff !important;

        fill: currentColor;

        opacity: 1 !important;
    }


    /*
        Mega menu
    */

    .nav-menu .has-mega .mega-menu {
        width: 100%;

        flex-basis: 100%;

        display: grid;

        grid-template-columns: 1fr;

        gap: 10px;

        padding: 0 12px;

        border-radius: 10px;

        background: transparent !important;

        box-shadow: none;

        color: #ffffff !important;
    }


    .nav-menu .has-mega .mega-menu .mega-grid {
        width: 100%;

        display: flex;

        flex-direction: column;

        gap: 8px;

        align-items: stretch;
    }


    .nav-menu .has-mega .mega-menu .mega-col {
        width: 100%;

        padding: 0;
    }


    .nav-menu .has-mega .mega-menu .mega-col:last-child {
        border-bottom: none;
    }


    .nav-menu .has-mega .mega-menu .mega-col h4 {
        margin: 0 0 6px;

        padding-left: 6px;

        font-size: 14px;

        font-weight: 700;

        letter-spacing: 0.08em;

        text-transform: uppercase;

        color: #ffffff !important;
    }


    .nav-menu .has-mega .mega-menu .mega-col a {
        display: flex;

        align-items: center;

        justify-content: flex-start;

        width: 100%;

        padding: 12px 10px;

        margin: 0;

        font-size: 16px;

        line-height: 1.4;

        color: rgba(255, 255, 255, 0.88) !important;

        text-align: left;

        border-radius: 8px;
    }

    .nav-menu .has-mega .mega-menu .mega-col .mega-item {
        display: flex;

        align-items: center;

        justify-content: flex-start;

        width: 100%;

        padding: 12px 10px;

        margin: 0;

        font-size: 16px;

        line-height: 1.4;

        color: rgba(255, 255, 255, 0.88) !important;

        text-align: left;

        border-radius: 8px;
    }


    .nav-menu .has-mega .mega-menu .mega-col a:hover,
    .nav-menu .has-mega .mega-menu .mega-col a:focus-visible {
        background: rgba(255, 255, 255, 0.07) !important;

        color: #ffffff !important;
    }


    /*
        Open mega menu
    */

    .nav-menu .has-mega.open .mega-menu {
        max-height: none !important;

        opacity: 1 !important;

        visibility: visible !important;

        padding: 6px 0 !important;

        transform: none !important;

        display: flex !important;

        flex-direction: column !important;

        position: static !important;

        width: 100% !important;

        margin: 4px 0 0 !important;

        border-radius: 0 !important;

        box-shadow: none !important;

        overflow: visible !important;

        background: transparent !important;
    }


    .nav-menu .has-mega.open .mega-menu .mega-grid {
        display: flex !important;

        flex-direction: column !important;

        gap: 2px !important;

        width: 100% !important;

        padding-top: 2px !important;
    }


    .nav-menu .has-mega.open .mega-menu .mega-col {
        width: 100% !important;

        padding: 0 !important;

        border-bottom: 1px solid rgba(255, 255, 255, 0.07);
    }


    .nav-menu .has-mega.open .mega-menu .mega-col:last-child {
        border-bottom: none;
    }


    .nav-menu .has-mega.open .mega-menu .mega-col h4 {
        margin: 0 0 2px 0 !important;

        padding-left: 0 !important;

        font-size: 10px !important;

        line-height: 1.2 !important;

        color: rgba(255, 255, 255, 0.65) !important;
    }


    .nav-menu .has-mega.open .mega-menu .mega-col a {
        font-size: 13px !important;

        padding: 6px 0 !important;

        display: flex !important;

        align-items: center !important;

        justify-content: flex-start !important;

        width: 100% !important;

        border-radius: 0 !important;

        text-align: left !important;

        line-height: 1.2 !important;

        color: rgba(255, 255, 255, 0.88) !important;
    }

    .nav-menu .has-mega.open .mega-menu .mega-col .mega-item {
        font-size: 13px !important;

        padding: 6px 0 !important;

        display: flex !important;

        align-items: center !important;

        justify-content: flex-start !important;

        width: 100% !important;

        border-radius: 0 !important;

        text-align: left !important;

        line-height: 1.2 !important;

        color: rgba(255, 255, 255, 0.88) !important;
    }


    .nav-menu .has-mega.open .mega-menu .mega-col a:hover,
    .nav-menu .has-mega.open .mega-menu .mega-col a:focus-visible {
        background: rgba(255, 255, 255, 0.06) !important;
    }
}


/* =========================================================
   TABLET NAV MENU BEHAVIOR
========================================================= */

@media (max-width: 1024px) and (min-width: 769px) {

    .nav-menu {
        display: none !important;
    }
}


/* =========================================================
   SMALL PHONES
========================================================= */

@media (max-width: 480px) {

    .hero-content {
        padding: 26px 16px 0;
        top: 42px;
    }

    .hero-content p {
        font-size: 14px;
        line-height: 1.6;
        margin-bottom: 22px;
        max-width: 100%;
    }

    .hero-btns {
        gap: 11px;
        margin-bottom: 16px;
    }

    .hero-btns .btn {
        padding: 12px 20px;
        font-size: 13px;
    }

    .nav-menu {
        width: 100%;

        max-width: 320px;

        padding: 80px 14px;

        right: 0 !important;
    }


    .nav-menu .has-mega .mega-link {
        font-size: 15px;

        padding: 10px 6px;
    }


    .nav-menu .has-mega .mega-toggle {
        padding: 6px;
    }


    .nav-menu .has-mega .mega-menu {
        padding: 12px 12px;

        width: calc(100% - 28px);
    }


    .nav-menu .has-mega .mega-menu .mega-col a {
        font-size: 15px;

        padding: 8px 0;
    }
}


/* =========================================================
   VERY SMALL PHONES
========================================================= */

@media (max-width: 360px) {

    .hero-content {
        padding: 24px 14px 0;
        top: 38px;
    }

    .hero-content p {
        font-size: 13px;
        line-height: 1.6;
        margin-bottom: 20px;
        max-width: 100%;
    }

    .hero-btns {
        gap: 11px;
        margin-bottom: 14px;
    }

    .hero-btns .btn {
        padding: 11px 18px;
        font-size: 12px;
    }

    .nav-menu {
        padding: 72px 10px;
    }


    .nav-menu .has-mega .mega-link {
        font-size: 14px;

        padding: 8px 6px;
    }


    .nav-menu .has-mega .mega-menu .mega-col a {
        font-size: 14px;

        padding: 6px 0;
    }


    .nav-menu .has-mega .mega-menu {
        padding: 10px 10px;
    }
}


/* =========================================================
   MOBILE HERO
   ONLY MOBILE HERO LAYOUT - DESKTOP UNCHANGED
========================================================= */

@media (max-width: 768px) {
    .hero-slider {
        position: relative;
        height: 80vh !important;
        min-height: 80vh !important;
        overflow: hidden;
        padding-bottom: 0;
        padding-top: 0;
    }

    .slides-wrapper {
        position: absolute;
        inset: 0;
        width: 100%;
        height: 100%;
        min-height: 80vh;
    }

    .slide {
        background-size: cover;
        background-position: center center;
        transform: scale(1.02);
    }

    .slide::after {
        background:
            linear-gradient(180deg, rgba(8, 26, 50, 0.18) 0%, rgba(8, 26, 50, 0.22) 26%, rgba(8, 26, 50, 0.52) 70%, rgba(8, 26, 50, 0.82) 100%),
            linear-gradient(90deg, rgba(8, 26, 50, 0.8) 0%, rgba(8, 26, 50, 0.55) 36%, rgba(8, 26, 50, 0.18) 100%);
    }

    .hero-overlay {
        position: absolute;
        inset: 0;
        z-index: 5;
        display: flex;
        align-items: flex-end;
        justify-content: flex-start;
        padding: 18px 10px 72px 8px;
        pointer-events: none;
    }

    .hero-content {
        position: relative;
        z-index: 3;
        width: min(100%, 300px);
        max-width: 100%;
        margin: 0;
        padding: 0;
        text-align: left;
        pointer-events: auto;
        animation: heroFadeUp 0.8s ease-out both;
    }

    .hero-content h1 {
        font-family: "Cormorant Garamond", Georgia, serif;
        font-size: clamp(2.7rem, 10vw, 4rem);
        line-height: 0.9;
        letter-spacing: -0.03em;
        margin: 0 0 10px;
        color: #ffffff;
        font-weight: 700;
        max-width: 260px;
        animation: heroFadeUp 0.75s ease-out both;
    }

    .hero-content h1 .hero-line-one {
        display: block;
        white-space: nowrap;
    }

    .hero-content h1 .hero-line-two {
        display: block;
        margin-top: 2px;
    }

    .hero-content h1 .nowrap {
        white-space: nowrap;
    }

    .hero-content h1 .accent {
        display: inline-block;
        margin-top: 0;
    }

    .hero-content p {
        margin: 0 0 16px;
        max-width: 100%;
        font-size: 14px;
        line-height: 1.55;
        color: rgba(255, 255, 255, 0.88);
        animation: heroFadeUp 0.9s ease-out both;
    }

    .hero-content .hero-btns {
        display: flex;
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
        width: 100%;
        max-width: 100%;
        pointer-events: auto;
        animation: heroFadeUp 1s ease-out both;
    }

    .hero-btns .btn {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-height: 48px;
        height: 48px;
        width: 100%;
        padding: 12px 18px;
        border-radius: 999px;
        font-size: 13px;
        font-weight: 700;
        line-height: 1;
        letter-spacing: 0.02em;
        box-shadow: 0 10px 24px rgba(8, 26, 50, 0.18);
        transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease, border-color 0.25s ease, color 0.25s ease;
    }

    .hero-btns .btn:hover,
    .hero-btns .btn:focus-visible {
        transform: translateY(-3px);
        box-shadow: 0 14px 28px rgba(8, 26, 50, 0.22);
    }

    .hero-btns .btn-primary {
        background: #0B3D91;
        color: #ffffff;
        border: 1px solid #0B3D91;
    }

    .hero-btns .btn-primary:hover,
    .hero-btns .btn-primary:focus-visible {
        background: #6fb7dc;
        border-color: #6fb7dc;
        color: #ffffff;
    }

    .hero-btns .btn-outline {
        background: rgba(255, 255, 255, 0.08);
        color: #ffffff;
        border: 1px solid rgba(255, 255, 255, 0.36);
    }

    .hero-btns .btn-outline:hover,
    .hero-btns .btn-outline:focus-visible {
        background: #ffffff;
        border-color: #ffffff;
        color: #0B3D91;
    }

    .hero-search-container {
        position: absolute;
        left: 16px;
        right: 16px;
        bottom: 8px;
        z-index: 10;
        width: auto;
        max-width: none;
        margin: 0;
        padding: 0;
        background: transparent;
        transform: translateY(-52px);
        pointer-events: auto;
    }

    .hero-search-form {
        display: none !important;
    }

    .hero-search-mobile {
        display: flex !important;
        align-items: center;
        width: 100%;
        min-height: 56px;
        background: transparent;
        border: 1px solid rgba(255, 255, 255, 0.22);
        border-radius: 18px;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
        box-shadow: 0 18px 40px rgba(8, 26, 50, 0.12);
        overflow: hidden;
        padding: 0;
        animation: heroFadeUp 1.1s ease-out both;
    }

    .hero-search-mobile input {
        flex: 1 1 auto;
        width: 100%;
        min-width: 0;
        height: 56px;
        background: transparent;
        border: 0;
        color: #ffffff;
        padding: 0 14px;
        font-size: 14px;
        outline: none;
        border-radius: 0;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }

    .hero-search-mobile input::placeholder {
        color: rgba(255, 255, 255, 0.72);
        opacity: 1;
    }

    .hero-search-mobile button {
        width: 56px;
        height: 56px;
        border: 0;
        background: #0B3D91;
        color: #ffffff;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        border-radius: 0 18px 18px 0;
        font-size: 16px;
    }

    .slider-indicators {
        bottom: 18px;
        z-index: 12;
    }

    @keyframes heroFadeUp {
        from {
            opacity: 0;
            transform: translateY(16px);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }
}

@media (max-width: 390px) {
    .hero-overlay {
        padding: 18px 18px 66px;
    }

    .hero-content {
        width: min(100%, 240px);
    }

    .hero-content h1 {
        font-size: clamp(30px, 10vw, 38px);
        line-height: 0.9;
        max-width: 210px;
        margin-bottom: 10px;
    }

    .hero-content h1 .hero-line-one {
        display: block;
        white-space: nowrap;
    }

    .hero-content h1 .accent {
        display: block;
        margin-top: 2px;
    }

    .hero-content p {
        max-width: 100%;
        font-size: 13.5px;
        line-height: 1.5;
    }

    .hero-content .hero-btns {
        max-width: 100%;
        gap: 10px;
    }

    .hero-btns .btn {
        min-height: 50px;
        height: 50px;
        font-size: 13px;
    }

    .hero-search-container {
        left: 18px;
        right: 18px;
        bottom: 6px;
        transform: translateY(-54px);
    }

    .hero-search-mobile {
        min-height: 56px;
    }

    .hero-search-mobile input {
        height: 56px;
        font-size: 14px;
        padding: 0 14px;
    }

    .hero-search-mobile button {
        width: 56px;
        height: 56px;
    }
}

@media (max-width: 320px) {
    .hero-content {
        width: min(100%, 200px);
    }

    .hero-content h1 {
        font-size: clamp(28px, 10vw, 32px);
        line-height: 0.88;
        max-width: 188px;
    }

    .hero-content p {
        font-size: 13px;
    }

    .hero-btns .btn {
        font-size: 12.5px;
    }

    .hero-search-mobile {
        border-radius: 16px;
    }

    .hero-search-container {
        transform: translateY(-56px);
    }

    .hero-search-mobile button {
        border-radius: 0 16px 16px 0;
    }
}


@media (min-width: 769px) {
    .property-details-page .side-column,
    .property-details-page .agent-box,
    .property-details-page .agent-sticky {
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
    }

    .property-details-page .mobile-contact-bar {
        display: none !important;
    }
}

/* =========================================================
   MOBILE CONTACT
========================================================= */

@media (max-width: 768px) {

    body.dark-mode .main-header .mobile-menu-toggle,
    body.dark-mode .main-header .mobile-menu-toggle:hover,
    body.dark-mode .main-header .mobile-menu-toggle:focus,
    body.dark-mode .main-header .mobile-menu-toggle:focus-visible,
    body.dark-mode .main-header .mobile-menu-toggle:active {
        background: transparent !important;
        border: 0 !important;
        border-color: transparent !important;
        outline: 0 !important;
        box-shadow: none !important;
    }

    body.dark-mode .main-header {
        border-bottom: 0 !important;
        box-shadow: none !important;
    }

    body.property-details-page {
        padding-top: 88px;
        padding-bottom: calc(100px + env(safe-area-inset-bottom));
    }

    body.property-details-page #detailsPage {
        padding-top: 0;
    }

    body.property-details-page .details-top {
        padding-top: 10px;
    }

    .property-details-page .agent-sidebar-card {
        display: none;
    }


    .mobile-contact-bar {
        display: flex !important;

        position: fixed !important;

        left: 0 !important;
        right: 0 !important;
        bottom: 0 !important;

        z-index: 2100 !important;

        align-items: center;

        justify-content: center;

        gap: 12px;

        padding: 12px 20px calc(12px + env(safe-area-inset-bottom));

        background: #ffffff;

        border-top: 1px solid rgba(0,0,0,0.08);

        box-shadow: 0 -12px 34px rgba(0,0,0,0.12);

        border-top-left-radius: 16px;
        border-top-right-radius: 16px;

        min-height: 84px;

        width: 100%;

        transform: none !important;

        opacity: 1 !important;

        visibility: visible !important;

        pointer-events: auto !important;
    }


    .mobile-contact-modal {
        display: none;

        position: fixed;

        inset: 0;

        z-index: 9999;

        background: rgba(0,0,0,0.4);

        align-items: center;

        justify-content: center;

        padding: 16px;
    }


    .mobile-contact-modal.visible {
        display: flex;
    }


    .mobile-contact-modal-content {
        width: 100%;

        max-width: 540px;

        background: #fff;

        border-radius: 20px;

        overflow: hidden;

        box-shadow: 0 24px 64px rgba(0,0,0,0.18);

        position: relative;
    }


    .mobile-contact-modal-close {
        position: absolute;

        top: 12px;
        right: 12px;

        width: 40px;
        height: 40px;

        border: none;

        border-radius: 50%;

        background: var(--white);

        color: var(--primary-blue);

        font-size: 22px;

        font-weight: 700;

        cursor: pointer;

        box-shadow: 0 8px 18px rgba(0,0,0,0.08);
    }


    .mobile-contact-modal-body {
        padding: 24px;
    }


    .mobile-agent-name-container {
        display: block;

        margin-bottom: 16px;

        padding: 14px 16px;

        background: #f7f7f7;

        border-radius: 14px;
    }


    .mobile-agent-name-label {
        margin: 0;

        color: var(--primary-blue);

        font-size: 0.95rem;

        font-weight: 700;
    }


    .agent-details-desktop-only {
        display: none !important;

        visibility: hidden !important;

        opacity: 0 !important;

        height: 0 !important;

        margin: 0 !important;

        padding: 0 !important;

        overflow: hidden !important;
    }


    .agent-sidebar-card.is-expanded .agent-info-compact .agent-compact-copy h4 {
        display: none;
    }


    .mobile-contact-bar.mobile-contact-bar-visible {
        transform: none !important;

        opacity: 1 !important;

        visibility: visible !important;
    }


    .mobile-contact-left {
        display: none !important;
    }


    .mobile-contact-actions {
        display: flex;

        align-items: center;

        gap: 8px;

        flex-wrap: wrap;

        justify-content: flex-end;
    }


    .mobile-contact-avatar {
        width: 42px;
        height: 42px;

        border-radius: 50%;

        object-fit: cover;

        flex-shrink: 0;
    }


    .mobile-contact-copy {
        display: flex;

        flex-direction: column;

        min-width: 0;
    }


    .mobile-contact-name {
        font-size: 14px;

        font-weight: 700;

        line-height: 1.1;

        white-space: nowrap;

        overflow: hidden;

        text-overflow: ellipsis;
    }


    .mobile-contact-role {
        font-size: 12px;

        color: var(--medium-gray);

        line-height: 1.2;
    }


    .mobile-contact-btn {
        position: relative;

        z-index: 2101;

        width: 100%;

        max-width: 400px;

        border: none;

        background: var(--primary-blue);

        color: white;

        border-radius: 999px;

        padding: 14px 20px;

        font-size: 15px;

        font-weight: 700;

        cursor: pointer;
    }


    .mobile-contact-icon {
        display: inline-flex;

        align-items: center;

        justify-content: center;

        width: 44px;

        height: 44px;

        border-radius: 50%;

        background: var(--light-gray);

        color: var(--primary-blue);

        text-decoration: none;
    }
}


/* =========================================================
   OTHER RESPONSIVE SECTIONS
   KEPT AS PROVIDED
========================================================= */

@media (max-width: 768px) {

    .section-header h2 {
        font-size: 36px;
    }

    .stats-section {
        padding: 18px 16px 58px;
        margin-top: 0 !important;
    }

    .stats-section > .container {
        width: 100%;
        max-width: none;
        margin: 0;
        padding: 0;
    }

    .stats-section .section-header {
        margin: 0 0 26px;
        text-align: left;
    }

    .stats-section .section-header h2 {
        font-size: 30px;
    }

    .stats-grid {
        grid-template-columns: 1fr 1fr;
        gap: 12px;
    }

    .stat-card {
        min-width: 0;
        padding: 18px 10px !important;
        border-radius: 15px;
        background: rgba(10, 27, 50, .68);
    }

    .stats-section .stat-card {
        padding: 18px 10px !important;
        background: none;
        box-shadow: none;
        border: 0;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }

    .stat-card i {
        font-size: 22px;
        margin-bottom: 8px;
    }

    .stat-card h2 {
        font-size: 30px;
        margin-bottom: 4px;
    }

    .stat-card p {
        font-size: 12px;
        line-height: 1.35;
    }

    .why-grid,
    .about-details,
    .about-media,
    .categories-grid,
    .developments-grid,
    .investment-grid,
    .team-grid,
    .blog-grid {
        grid-template-columns: 1fr;
    }

    .why-choose {
        padding: 52px 0;
        background: #eef3f7;
    }

    .why-choose > .container {
        width: calc(100% - 32px);
        max-width: 560px;
        padding: 28px 0;
        background: transparent;
        border-radius: 0;
        box-shadow: none;
    }

    .why-choose .section-header {
        margin-bottom: 22px;
    }

    .why-choose .section-header h2 {
        font-size: 29px;
    }

    .why-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .why-card {
        width: 100%;
        padding: 24px 18px !important;
        border-radius: 14px !important;
        background: #ffffff !important;
        box-shadow: 0 8px 20px rgba(15, 35, 55, 0.08) !important;
    }

    .why-card:nth-child(odd) {
        border-right: 0;
    }

    .why-card:not(:last-child),
    .why-card:nth-child(odd) {
        border-bottom: 0;
    }

    .why-card i {
        font-size: 28px !important;
        margin-bottom: 10px !important;
    }

    .why-card h3 {
        font-size: 17px;
        line-height: 1.25;
    }

    .why-card p {
        font-size: 13px;
        line-height: 1.45;
    }

    .atlas-why-us {
        padding: 60px 16px;
        background: #f7f8fa;
    }

    .atlas-why-us > .atlas-why-container {
        width: 100%;
        max-width: 560px;
        margin: 0 auto;
        padding: 0;
    }

    .atlas-why-us .section-header {
        margin-bottom: 32px;
        text-align: left;
    }

    .atlas-why-us .section-header h2 {
        margin: 10px 0 12px;
        font-size: clamp(32px, 9vw, 40px);
        line-height: 1.08;
    }

    .atlas-why-us .section-header p {
        font-size: 14px;
        line-height: 1.65;
    }

    .atlas-why-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .atlas-why-card {
        min-height: 0;
        padding: 20px 18px;
        border-radius: 18px;
        gap: 14px;
        box-shadow: 0 5px 16px rgba(10, 27, 50, .05);
    }

    .atlas-why-card:hover {
        transform: none;
    }

    .atlas-why-card-icon {
        flex-basis: 48px;
        width: 48px;
        height: 48px;
        border-radius: 13px;
    }

    .atlas-why-card h3 {
        margin-bottom: 6px;
        font-size: 16px;
    }

    .atlas-why-card p {
        font-size: 13px;
        line-height: 1.6;
    }

    .about-atlas {
        margin-top: -10px !important;
        padding-top: 0 !important;
    }

    .about-grid,
    .map-grid,
    .cta-inner {
        grid-template-columns: 1fr;
    }

    .about-grid {
        width: calc(100% - 32px);
        margin: 0 auto;
        padding: 32px 18px;
        border-radius: 22px;
        gap: 24px;
    }

    .about-copy h2 {
        margin: 14px 0 16px;
        font-size: 34px;
        line-height: 1.1;
    }

    .about-details {
        grid-template-columns: 1fr;
        gap: 14px;
        margin: 22px 0;
    }

    .about-details h4 {
        margin-bottom: 6px;
        font-size: 15px;
    }

    .about-details p {
        font-size: 13px;
        line-height: 1.5;
    }

    .about-media {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .about-image {
        min-height: 170px;
        border-radius: 14px;
    }

    .cta-inner {
        text-align: center;
    }

    .cta-banner {
        padding: 58px 16px;
    }

    .cta-banner > .container {
        width: 100%;
        max-width: none;
        margin: 0;
        padding: 0;
    }

    .cta-inner {
        display: flex;
        flex-direction: column;
        align-items: stretch;
        gap: 28px;
    }

    .cta-copy h2 {
        margin: 12px 0 12px;
        font-size: 32px;
        line-height: 1.1;
    }

    .cta-copy p {
        max-width: none;
        font-size: 14px;
        line-height: 1.65;
    }

    .cta-buttons {
        display: grid;
        grid-template-columns: 1fr;
        gap: 12px;
        width: 100%;
    }

    .cta-buttons .btn {
        width: 100%;
        justify-content: center;
    }

    .map-section {
        padding: 60px 16px;
    }

    .map-section > .container {
        width: 100%;
        max-width: none;
        margin: 0;
        padding: 0;
    }

    .map-grid {
        gap: 18px;
    }

    .map-frame,
    .map-frame iframe {
        min-height: 260px;
        height: 260px;
        border-radius: 18px;
    }

    .map-section .map-frame {
        min-height: 260px;
    }

    .map-info {
        padding: 24px 20px;
        border-radius: 18px;
    }

    .map-info h2 {
        margin: 12px 0 14px;
        font-size: 28px;
        line-height: 1.15;
    }

    .map-info p {
        margin-bottom: 18px;
        font-size: 14px;
        line-height: 1.6;
    }

    .map-highlights {
        grid-template-columns: 1fr;
        gap: 12px;
        margin-bottom: 20px;
    }

    .testimonial-controls {
        position: static;

        justify-content: center;

        margin-top: 20px;
    }

    .footer-grid {
        grid-template-columns: 1fr;

        gap: 24px;
    }

    .newsletter-card {
        flex-direction: column;

        text-align: center;

        gap: 30px;

        align-items: stretch;
        padding: 28px 20px;
    }

    .newsletter-form {
        width: 100%;
        flex-direction: column;
    }

    .newsletter-form input,
    .newsletter-form button {
        width: 100%;
        min-width: 0;
    }

    .newsletter-status {
        width: 100%;
        margin: 0;
        font-size: 12px;
        line-height: 1.4;
    }

    .trusted-by {
        margin-top: -18px !important;
        padding-top: 0 !important;
        margin-bottom: -18px !important;
    }

    .trusted-by .section-header {
        margin-bottom: 8px;
    }

    .trusted-by .logo-marquee {
        width: 100%;
    }

    .trusted-by .logo-track {
        gap: 12px;
        animation-duration: 20s;
    }

    .trusted-by .trusted-logo {
        min-width: 118px;
        width: 118px;
        height: 58px;
        padding: 8px 10px;
        border-radius: 12px;
    }

    .trusted-by .brand-mark {
        gap: 7px;
        font-size: 13px;
    }

    .trusted-by .brand-mark i {
        font-size: 22px;
    }

    .trusted-by .trusted-logo span {
        font-size: 10px;
        letter-spacing: 1px;
    }

    .footer-contact li {
        min-width: 0;
        overflow-wrap: anywhere;
    }
}


/* =========================================================
   DESKTOP SEARCH
   UNCHANGED
========================================================= */

@media (min-width: 769px) {

    body:not(.property-details-page) .side-column,
    body:not(.property-details-page) .agent-box,
    body:not(.property-details-page) .agent-sticky,
    .zpd-agent-panel,
    .zpd-agent-card-panel,
    .pd-agent-card {
        display: none !important;
    }

    body:not(.property-details-page) .detail-layout {
        grid-template-columns: minmax(0, 1fr) !important;
    }

    body:not(.property-details-page) .main-column {
        grid-column: 1 / -1 !important;
    }

    .hero-search-container {
        position: relative;

        width: 100vw;

        max-width: none;

        left: 60%;

        right: 50%;

        margin-left: -50vw;

        margin-right: -50vw;

        padding: 0 40px 24px;

        transform: translateX(-10vw);

        box-sizing: border-box;
    }


    .hero-search-form {
        max-width: none;

        width: 100%;

        padding: 18px 40px;

        gap: 12px;

        border-radius: 32px;
    }
}


/* =========================================================
   SMALL SCREEN TYPOGRAPHY
========================================================= */

@media (max-width: 480px) {

    .property-grid {
        grid-template-columns: 1fr;
    }

    .stats-grid {
        grid-template-columns: 1fr 1fr;
        gap: 12px;
    }
}


/* =========================================================
   SERVICES
========================================================= */

@media (max-width: 1024px) {

    .service-banner {
        height: 50vh;
    }

    .service-banner h1 {
        font-size: 48px;
    }

    .service-banner p {
        font-size: 18px;
    }

    .service-card-large {
        gap: 48px;
    }
}


@media (max-width: 768px) {

    .service-banner {
        height: 40vh;

        padding: 36px 0;

        display: flex;

        align-items: center;
    }

    .service-banner h1 {
        font-size: 32px;

        margin: 0;
    }

    .service-banner p {
        font-size: 15px;

        max-width: 92%;

        margin: 12px auto 0;
    }

    .service-card-large {
        grid-template-columns: 1fr;

        gap: 28px;

        align-items: stretch;

        margin-bottom: 48px;
    }

    .service-card-large:nth-child(even) {
        direction: ltr;
    }

    .service-card-large .service-image,
    .service-card-large .service-text {
        width: 100%;
    }

    .service-image img {
        width: 100%;

        height: auto;

        display: block;

        border-radius: 12px;
    }

    .service-text {
        padding: 0;
    }

    .service-icon-box {
        margin-bottom: 16px;

        width: 64px;

        height: 64px;

        font-size: 24px;
    }
}


@media (max-width: 480px) {

    .service-banner {
        height: 36vh;

        padding: 28px 0;
    }

    .service-banner h1 {
        font-size: 26px;
    }

    .service-banner p {
        font-size: 14px;
    }

    .service-card-large {
        gap: 20px;

        margin-bottom: 36px;
    }
}


/* =========================================================
   PROPERTIES
========================================================= */

@media (max-width: 1200px) {

    .listing-container {
        grid-template-columns: 260px 1fr;

        gap: 24px;
    }
}


@media (max-width: 992px) {

    .listing-container {
        grid-template-columns: 1fr;

        gap: 24px;
    }

    .filter-sidebar {
        position: static;

        top: auto;

        padding: 24px;
    }

    .property-toolbar {
        flex-direction: column;

        align-items: flex-start;

        gap: 12px;
    }

    .property-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));

        gap: 22px;
    }
}


@media (max-width: 768px) {

    .page-banner {
        padding: 100px 0 50px;
    }

    .page-banner h1 {
        font-size: 2.2rem;

        line-height: 1.15;
    }

    .page-banner p {
        font-size: 1rem;

        max-width: 90%;

        margin: 0 auto;
    }

    .listing-container {
        margin-top: 30px;

        gap: 18px;
    }

    .filter-sidebar {
        padding: 18px;

        border-radius: 10px;
    }

    .filter-group label {
        font-size: 13px;
    }

    .filter-group select,
    .filter-group input {
        padding: 10px;
    }

    .property-grid {
        grid-template-columns: 1fr;

        gap: 18px;
    }

    .property-image {
        height: 220px;
    }

    .property-info {
        padding: 20px;
    }

    .property-info h3 {
        font-size: 20px;
    }

    .property-features {
        flex-wrap: wrap;

        gap: 10px;
    }

    .feature {
        font-size: 13px;
    }

    .pagination {
        gap: 8px;

        flex-wrap: wrap;

        margin-top: 35px;
    }

    .page-link {
        width: 40px;

        height: 40px;
    }
}


@media (max-width: 480px) {

    .page-banner {
        padding: 88px 0 40px;
    }

    .page-banner h1 {
        font-size: 1.8rem;
    }

    .page-banner p {
        font-size: 0.95rem;

        max-width: 100%;
    }

    .listing-container {
        margin-top: 24px;

        gap: 16px;
    }

    .filter-sidebar {
        padding: 16px;
    }

    .property-toolbar {
        margin-bottom: 20px;

        padding-bottom: 14px;
    }

    .results-count {
        font-size: 14px;
    }

    .sort-select {
        width: 100%;
    }

    .property-image {
        height: 190px;
    }

    .property-info {
        padding: 16px;
    }

    .property-info h3 {
        font-size: 18px;
    }

    .property-location {
        font-size: 13px;

        margin-bottom: 16px;
    }

    .property-features {
        flex-direction: column;

        align-items: flex-start;
    }

    .property-status {
        top: 12px;

        left: 12px;

        padding: 4px 10px;

        font-size: 11px;
    }

    .property-price {
        right: 12px;

        bottom: 12px;

        padding: 6px 10px;

        font-size: 13px;
    }

    .pagination {
        gap: 6px;
    }

    .page-link {
        width: 36px;

        height: 36px;

        font-size: 14px;
    }
}


/* =========================================================
   FIND PROPERTY
========================================================= */

@media (max-width: 1024px) {

    .stats-showcase {
        grid-template-columns: repeat(3, 1fr);

        gap: 30px;
    }

    .stat-number {
        font-size: 48px;
    }

    .service-cards-grid {
        grid-template-columns: repeat(2, 1fr);

        gap: 24px;
    }

    .service-card {
        padding: 35px 25px;
    }

    .service-card h3 {
        font-size: 26px;
    }
}

/* Desktop view - Increase width and reduce height of service cards */
@media (min-width: 1025px) {
    .find-property-section .container {
        max-width: 100%;
        padding: 0;
    }

    .service-cards-grid {
        gap: 16px;
        margin-top: 60px;
        padding: 0;
    }

    .service-card {
        padding: 30px 35px;
        min-height: auto;
        height: auto;
    }

    .card-description {
        margin-bottom: 20px;
    }

    .card-features {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 8px 12px;
        margin: 16px 0;
    }

    .card-features li {
        font-size: 12px;
        line-height: 1.35;
    }

    .card-features li i {
        margin-right: 6px;
    }
}


@media (max-width: 768px) {

    .find-property-section {
        padding: 60px 16px;
    }

    .find-property-section > .container {
        width: 100%;
        max-width: none;
        margin: 0;
        padding: 0;
    }

    .find-property-section .section-header {
        margin-top: 0 !important;
        margin-bottom: 28px;
    }

    .find-property-section .section-header h2 {
        font-size: 32px;
        line-height: 1.1;
    }

    .find-property-section .section-subtitle {
        font-size: 14px;
        line-height: 1.6;
    }

    .find-property-section::before,
    .find-property-section::after {
        display: none;
    }

    .stats-showcase {
        grid-template-columns: 1fr;

        gap: 20px;

        margin-bottom: 40px;
    }

    .stat-item {
        padding: 24px;

        border-radius: 14px;
    }

    .stat-number {
        font-size: 40px;
    }

    .stat-label {
        font-size: 12px;

        margin-top: 10px;
    }

    .section-subtitle {
        font-size: 15px;

        line-height: 1.7;
    }

    .service-cards-grid {
        grid-template-columns: 1fr;

        gap: 16px;

        margin-top: 0;
    }

    .service-card {
        padding: 24px 18px;

        border-radius: 18px;
    }

    .card-icon {
        width: 58px;

        height: 58px;

        font-size: 30px;

        margin-bottom: 14px;
    }

    .service-card h3 {
        font-size: 22px;

        margin-bottom: 8px;
    }

    .card-description {
        font-size: 14px;

        margin-bottom: 20px;
    }

    .card-features {
        margin: 16px 0;
    }

    .card-features li {
        font-size: 13px;

        gap: 10px;

        margin-bottom: 10px;
    }

    .card-btn {
        padding: 13px 28px !important;

        font-size: 13px !important;

        margin-top: 18px;
    }
}


@media (max-width: 480px) {

    .find-property-section {
        padding: 60px 0;
    }

    .stats-showcase {
        grid-template-columns: 1fr;

        gap: 16px;

        margin-bottom: 30px;
    }

    .stat-item {
        padding: 20px;

        border-radius: 12px;
    }

    .stat-number {
        font-size: 36px;
    }

    .stat-plus,
    .stat-percent {
        font-size: 28px;
    }

    .stat-label {
        font-size: 11px;

        margin-top: 8px;
    }

    .section-header {
        margin-top: 30px;

        margin-bottom: 30px;
    }

    .section-header span {
        font-size: 11px;
    }

    .section-header h2 {
        font-size: 28px;

        margin-top: 8px;
    }

    .section-subtitle {
        font-size: 14px;

        line-height: 1.6;
    }

    .service-cards-grid {
        gap: 16px;

        margin-top: 35px;
    }

    .service-card {
        padding: 24px 18px;

        border-radius: 16px;
    }

    .service-card::before {
        height: 3px;
    }

    .card-icon {
        width: 62px;

        height: 62px;

        font-size: 32px;

        margin-bottom: 16px;
    }

    .card-label {
        padding: 5px 12px;

        font-size: 11px;

        margin-bottom: 10px;
    }

    .service-card h3 {
        font-size: 20px;

        margin-bottom: 8px;
    }

    .card-features li {
        font-size: 12px;

        gap: 9px;

        margin-bottom: 8px;
    }

    .card-features i {
        font-size: 14px;
    }

    .card-btn {
        padding: 12px 24px !important;

        font-size: 12px !important;

        margin-top: 14px;
    }

    .find-property-section {
        padding: 60px 16px;
    }

    .find-property-section > .container {
        width: 100%;
        max-width: none;
        margin: 0;
        padding: 0;
    }

    .find-property-section .section-header {
        margin-top: 0;
        margin-bottom: 28px;
    }

    .find-property-section .service-cards-grid {
        margin-top: 0;
    }

    .find-property-section .service-card {
        padding: 20px 16px;
    }

    .find-property-section .card-icon {
        width: 54px;
        height: 54px;
        font-size: 28px;
        margin-bottom: 12px;
    }

    .find-property-section .service-card h3 {
        font-size: 19px;
    }

    .find-property-section .card-description {
        font-size: 13px;
        line-height: 1.55;
        margin-bottom: 14px;
    }

    .find-property-section .card-features {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 8px 10px;
        margin: 16px 0;
    }

    .find-property-section .card-features li {
        font-size: 11px;
        margin-bottom: 0;
        line-height: 1.35;
    }

    .testimonial-section {
        padding: 60px 16px;
    }

    .testimonial-section > .container {
        width: 100%;
        max-width: none;
        margin: 0;
        padding: 0;
    }

    .testimonial-section .section-header {
        margin: 0 0 28px;
    }

    .testimonial-section .section-header h2 {
        font-size: 32px;
        line-height: 1.1;
    }

    .testimonial-carousel {
        padding: 24px 18px 20px;
        border-radius: 18px;
        box-shadow: 0 8px 24px rgba(15, 35, 55, .08);
    }

    .testimonial-slider {
        min-height: 290px;
    }

    .testimonial-slide p {
        margin-bottom: 24px;
        font-size: 17px;
        line-height: 1.65;
    }

    .testimonial-author {
        gap: 12px;
        margin-bottom: 16px;
    }

    .testimonial-author img {
        width: 54px;
        height: 54px;
        border-width: 2px;
    }

    .testimonial-meta {
        flex-wrap: wrap;
        gap: 8px 14px;
        font-size: 12px;
    }

    .testimonial-controls {
        position: static;
        justify-content: space-between;
        transform: none;
        margin-top: 20px;
    }

    .testimonial-controls button {
        width: 42px;
        height: 42px;
    }

    .testimonial-dots {
        gap: 8px;
        margin-top: 18px;
    }

    .testimonial-dot {
        width: 10px;
        height: 10px;
    }

    .blog-section {
        padding: 60px 16px;
    }

    .blog-section > .container {
        width: 100%;
        max-width: none;
        margin: 0;
        padding: 0;
    }

    .blog-section .section-header {
        margin: 0 0 28px;
    }

    .blog-section .section-header h2 {
        font-size: 32px;
        line-height: 1.1;
    }

    .blog-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .blog-card {
        border-radius: 18px;
    }

    .blog-card img {
        height: 150px;
    }

    .blog-content {
        padding: 20px 18px 22px;
    }

    .blog-category {
        margin-bottom: 8px;
        font-size: 11px;
    }

    .blog-content h3 {
        margin-bottom: 8px;
        font-size: 20px;
        line-height: 1.25;
    }

    .blog-content p {
        margin-bottom: 16px;
        font-size: 13px;
        line-height: 1.55;
    }

    .blog-content .btn {
        padding: 11px 18px;
        font-size: 12px;
    }
}

/* Desktop view - Move hero content to the left */
@media (min-width: 1025px) {
    .hero-content {
        margin-left: -80px;
        margin-right: auto;
    }
}