:root {
    --color-anthracite: #383838;
    --color-anthracite-dark: #2a2a2a;
    --color-background: #f2f2f2;
    --color-gold: #D4AF37;
    --color-sand: #E6D0B3;
    --color-white: #FFFFFF;
    --color-text-main: #383838;
    --color-text-light: #F5F5F5;

    /* Even softer icon color (lighter grey) */
    --color-icon-soft: #888888;

    --font-main: 'Outfit', sans-serif;

    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 2rem;
    --spacing-lg: 4rem;
    --spacing-xl: 6rem;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-main);
    background-color: var(--color-background);
    color: var(--color-text-main);
    line-height: 1.6;
    overflow-x: hidden;
}

body.no-scroll {
    overflow: hidden;
}

/* 0. INTRO LOADER ANIMATION */
.intro-loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    pointer-events: none;
}

.loader-door {
    position: absolute;
    top: 0;
    width: 50%;
    height: 100%;
    background-color: var(--color-background);
    /* V4: Light intro background */
    transition: transform 1.2s cubic-bezier(0.85, 0, 0.15, 1);
}

.door-left {
    left: 0;
}

.door-right {
    right: 0;
}

.loader-logo-container {
    position: relative;
    z-index: 10000;
    width: 300px;
    max-width: 80%;
    text-align: center;
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.loader-logo {
    width: 100%;
    height: auto;
}

/* Animation States */
.intro-loader.loaded .door-left {
    transform: translateX(-100%);
}

.intro-loader.loaded .door-right {
    transform: translateX(100%);
}

.intro-loader.loaded .loader-logo-container {
    opacity: 0;
    transform: scale(0.9);
}

.intro-loader.hidden {
    display: none;
}

/* Language Toggle */
.lang-toggle-container {
    position: fixed;
    top: 28px;
    /* Slightly lower to align vertically with logo center */
    right: 20px;
    z-index: 1000;
}

#lang-toggle {
    background: rgba(56, 56, 56, 0.1);
    border: 1px solid var(--color-anthracite);
    color: var(--color-anthracite);
    padding: 8px 16px;
    cursor: pointer;
    font-family: var(--font-main);
    font-size: 0.9rem;
    border-radius: 4px;
    backdrop-filter: blur(5px);
    transition: all 0.3s ease;
    font-weight: 500;
}

#lang-toggle:hover {
    background-color: var(--color-anthracite);
    color: var(--color-white);
}

/* Header & Logo */
.header {
    position: absolute;
    top: 20px;
    /* Align with toggle height */
    left: 0;
    width: 100%;
    padding: 0 var(--spacing-md);
    z-index: 10;
    display: flex;
    justify-content: center;
    pointer-events: none;
    /* Allow clicks through to background if needed */
}

.logo-container {
    width: 144px;
    /* Increased by another 20% from 120px */
    max-width: 50%;
    pointer-events: auto;
}

.logo {
    width: 100%;
    height: auto;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

/* V4: Hero Logo Styles */
.hero-logo-container {
    margin-bottom: var(--spacing-lg);
    /* More spacing */
    width: 240px;
    /* 10% larger */
    max-width: 70%;
    text-align: center;
    /* Center the logo */
    margin-left: auto;
    margin-right: auto;
}

.hero-logo {
    width: 100%;
    height: auto;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.15));
}

/* 1. HERO SECTION (Version 2: Light Theme) */
.hero-section {
    position: relative;
    height: 100vh;
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 0 var(--spacing-sm);
    color: var(--color-anthracite);
    /* Changed to Anthracite for Light Theme */
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('images/dubai_background.png');
    background-size: 120%;
    /* V4: Zoomed in more */
    background-position: center 20%;
    /* V4: Aggressive crop - show much less desert */
    z-index: -2;
    filter: brightness(1.1) saturate(0.8);
    transition: transform 0.5s ease-out;
    will-change: transform;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* Light gradient for Anthracite text visibility */
    background: linear-gradient(to bottom,
            rgba(255, 255, 255, 0.5),
            rgba(255, 255, 255, 0.2));
    z-index: -1;
}

.hero-content {
    max-width: 800px;
    /* Animation handled via JS stagger in V2 */
}

.hero-content h1 {
    font-size: 2.8rem;
    font-weight: 300;
    margin-bottom: var(--spacing-sm);
    letter-spacing: 1px;
    line-height: 1.2;
    color: var(--color-anthracite);
}

.subline {
    font-size: 1.2rem;
    font-weight: 300;
    margin-bottom: var(--spacing-md);
    color: rgba(56, 56, 56, 0.8);
    /* Anthracite with opacity */
}

.hero-buttons {
    display: flex;
    gap: var(--spacing-sm);
    justify-content: center;
    flex-wrap: wrap;
}

.hero-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background-color: rgba(56, 56, 56, 0.05);
    /* Very light anthracite */
    border: 1px solid var(--color-anthracite);
    color: var(--color-anthracite);
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    backdrop-filter: blur(5px);
}

.hero-btn:hover {
    background-color: var(--color-anthracite);
    color: var(--color-white);
    transform: translateY(-2px);
}

/* 2. PROFILE SECTION */
.profile-section {
    padding: var(--spacing-xl) var(--spacing-md);
    padding-bottom: var(--spacing-lg);
    background-color: var(--color-background);
    color: var(--color-text-main);
}

.container {
    max-width: 1000px;
    margin: 0 auto;
}

.profile-card {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-lg);
    text-align: center;
}

@media (min-width: 768px) {
    .profile-card {
        flex-direction: row;
        text-align: left;
        align-items: flex-start;
    }

    .profile-image-container {
        flex: 0 0 350px;
    }

    .profile-info {
        flex: 1;
    }
}

@media (max-width: 767px) {
    .profile-card {
        gap: var(--spacing-md);
        /* Reduce invalid blank space on mobile */
    }
}

.profile-image {
    width: 100%;
    max-width: 350px;
    /* Constrain on desktop */
    height: auto;
    border-radius: 2px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1),
        box-shadow 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

/* V4: Premium fade-in animation for profile image */
.profile-image-container.reveal {
    opacity: 0;
    transform: translateY(20px) scale(0.98);
    /* V4: Softer transition (less travel/scale) */
}

.profile-image-container.reveal.visible {
    opacity: 1;
    transform: translateY(0) scale(1);
    transition: opacity 1.6s cubic-bezier(0.16, 1, 0.3, 1),
        transform 1.6s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Mobile specific image crop */
@media (max-width: 767px) {
    .profile-image {
        width: 100%;
        max-width: 100%;
        /* Ensure full avail width on mobile */
        height: auto;
        /* V4: Show full image without crop */
        object-fit: contain;
        /* Show entire image */
        object-position: center;
    }
}

.profile-info h2 {
    font-size: 1.5rem;
    font-weight: 500;
    margin-bottom: var(--spacing-md);
    color: var(--color-anthracite);
    line-height: 1.4;
}

.profile-info .title-role {
    font-size: 1rem;
    font-weight: 400;
    /* Light weight */
    color: #999999;
    /* Light Grey */
    margin-bottom: var(--spacing-sm);
    display: block;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.bio {
    font-size: 1rem;
    color: #555;
    font-weight: 300;
    line-height: 1.8;
}

/* 3. SERVICES SECTION */
.services-section {
    padding: var(--spacing-lg) var(--spacing-md);
    background-color: #e8e8e8;
    text-align: center;
}

/* Default Mobile: Slider logic */
.services-slider-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    /* Helper for centering */
}

/* Filigree Arrow Styles */
.slider-arrow {
    background: transparent;
    /* No bubble */
    border: none;
    color: #999;
    /* Light grey for subtle look */
    font-size: 1.5rem;
    /* Adjust size */
    width: 40px;
    height: 60px;
    /* Taller hit area */
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: none;
    /* No shadow */
    z-index: 20;
    /* Ensure clickable above everything */
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    transition: color 0.3s, transform 0.1s;
    /* Ensure no background/border ghosting */
    background-color: transparent !important;
    border: none !important;
    box-shadow: none !important;
}

.slider-arrow:active {
    transform: translateY(-50%) scale(0.9);
}

.slider-arrow:hover {
    color: var(--color-anthracite);
}

/* Use thin font-weight for filigree effect on icons */
.slider-arrow i {
    font-weight: 100 !important;
    /* Try to force thinness */
    -webkit-text-stroke: 0px;
}

.slider-arrow.prev {
    left: 10px;
}

/* Inside the edge */
.slider-arrow.next {
    right: 10px;
}

/* Inside the edge */

.services-list {
    display: flex;
    overflow-x: auto;
    overflow-y: hidden;
    /* V4: Prevent vertical scroll */
    scroll-snap-type: x mandatory;
    gap: 0;
    /* No gap for single page feel */
    padding: 0;
    /* Remove padding to use full width */
    padding-bottom: 0;
    /* V4: Remove bottom padding to prevent icon cutoff */
    flex-wrap: nowrap;
    justify-content: flex-start;
    -webkit-overflow-scrolling: touch;
    width: 100%;

    /* Hide scrollbar visually */
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.services-list::-webkit-scrollbar {
    display: none;
}

/* Tablet: 2x2 Grid */
@media (min-width: 768px) {
    .slider-arrow {
        display: none;
    }

    /* Hide mobile arrows on desktop */

    .services-slider-wrapper {
        display: block;
        /* Remove flex wrapper behavior for desktop */
    }

    .services-list {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: var(--spacing-lg);
        justify-items: center;
        max-width: 1000px;
        margin: 0 auto;
        padding: 0;
        /* Reset padding */
        padding-bottom: 0;
        overflow-x: visible;
    }
}

/* Desktop: 4x1 Grid */
@media (min-width: 992px) {
    .services-list {
        grid-template-columns: repeat(4, 1fr);
    }
}


.service-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    width: 100%;
}

/* Mobile item sizing for slider */
@media (max-width: 767px) {
    .service-item {
        flex: 0 0 100%;
        /* Show ONLY one item fully */
        scroll-snap-align: center;
        max-width: none;
        padding: 0 40px;
        /* Internal padding to ensure text doesn't touch arrows */
    }
}

/* Desktop item sizing */
@media (min-width: 768px) {
    .service-item {
        max-width: 200px;
    }
}

@media (min-width: 992px) {
    .container {
        max-width: 1200px;
    }

    .br-desktop {
        display: block;
    }
}

.br-desktop {
    display: none;
}

.service-icon {
    font-size: 1.8rem;
    color: #888888;
    /* Light Grey */
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #888888;
    /* Filigree border */
    border-radius: 50%;
    transition: all 0.3s ease;
}

.service-item:hover .service-icon {
    background-color: var(--color-anthracite);
    border-color: var(--color-anthracite);
    color: var(--color-white);
}

.service-icon i,
.service-icon .bi::before {
    -webkit-text-stroke: 0px;
    font-weight: 300 !important;
}

.service-text {
    font-size: 0.95rem;
    font-weight: 400;
    color: var(--color-anthracite);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    line-height: 1.4;
    min-height: 2.8em;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}


/* 4. CONTACT SECTION */
.contact-section {
    padding-top: var(--spacing-md);
    padding-bottom: var(--spacing-xl);
    padding-left: var(--spacing-md);
    padding-right: var(--spacing-md);
    background-color: var(--color-background);
    text-align: center;
}

.contact-section h2 {
    font-size: 2rem;
    font-weight: 300;
    margin-bottom: var(--spacing-md);
    color: var(--color-anthracite);
}

.contact-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
}

.contact-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 25px;
    text-decoration: none;
    color: var(--color-anthracite);
    border: 1px solid var(--color-anthracite);
    transition: all 0.3s ease;
    background: transparent;
}

.contact-btn:hover {
    background-color: var(--color-anthracite);
    color: var(--color-white);
}

/* 5. COMPANY INFO SECTION (Footer Content) */
.company-info-section {
    padding: var(--spacing-lg) var(--spacing-md);
    background-color: var(--color-anthracite);
    color: var(--color-text-light);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--spacing-md);
    text-align: center;
}

@media (min-width: 768px) {
    .footer-grid {
        grid-template-columns: repeat(3, 1fr);
        text-align: left;
    }
}

.footer-col h3 {
    color: var(--color-white);
    font-weight: 500;
    font-size: 1rem;
    margin-bottom: var(--spacing-sm);
    letter-spacing: 0.5px;
}

.footer-col p,
.footer-col a {
    color: #ccc;
    font-size: 0.9rem;
    margin-bottom: 5px;
    text-decoration: none;
    transition: color 0.2s;
    font-weight: 300;
}

.footer-col a:hover {
    color: var(--color-white);
}

.mt-2 {
    margin-top: 10px;
}


/* 6. BOTTOM FOOTER (Links) */
.footer {
    padding: var(--spacing-md);
    background-color: var(--color-anthracite-dark);
    text-align: center;
    font-size: 0.85rem;
    color: #888;
}

.footer-links {
    margin-bottom: var(--spacing-sm);
}

.footer-link {
    background: none;
    border: none;
    color: #aaa;
    cursor: pointer;
    font-family: var(--font-main);
    font-size: 0.85rem;
    padding: 0 5px;
    transition: color 0.2s;
}

.footer-link:hover {
    color: var(--color-white);
}

.separator {
    color: #444;
}

/* MODAL STYLES */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
}

.modal-content {
    background-color: var(--color-background);
    margin: 5% auto;
    padding: var(--spacing-md);
    border: none;
    width: 90%;
    max-width: 800px;
    color: var(--color-text-main);
    position: relative;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    border-radius: 4px;
}

.close {
    color: var(--color-anthracite);
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.close:hover,
.close:focus {
    color: var(--color-anthracite-dark);
    text-decoration: none;
}

.modal-content h2 {
    font-weight: 400;
    color: var(--color-anthracite);
    margin-bottom: var(--spacing-md);
    border-bottom: 1px solid #ddd;
    padding-bottom: 10px;
}

.modal-content p {
    margin-bottom: 15px;
    font-weight: 300;
    color: #555;
}

.modal-content a {
    color: var(--color-anthracite);
    text-decoration: underline;
}

/* High Quality Animations (V2) */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 1.2s cubic-bezier(0.16, 1, 0.3, 1),
        transform 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Wave Effect Reveal (Staggered Characters) */
.wave-text {
    display: inline-block;
    overflow: hidden;
    vertical-align: bottom;
    padding-bottom: 0.2em;
    /* Prevent "line" artifact from overflow:hidden */
    margin-bottom: -0.2em;
}

.wave-char {
    display: inline-block;
    transform: translateY(105%);
    /* Positioned just below the crop line */
    opacity: 0;
    will-change: transform, opacity;
    -webkit-font-smoothing: antialiased;
    /* Refined ease-out-back: Less overshoot (1.25) and slower (1.6s) for luxury feel */
    transition: transform 1.6s cubic-bezier(0.34, 1.25, 0.64, 1),
        opacity 1.6s cubic-bezier(0.34, 1.25, 0.64, 1);
}

.visible .wave-char {
    transform: translateY(0);
    opacity: 1;
}

/* Animations (Generic) */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

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

/* Responsive Tweaks */
@media (max-width: 768px) {
    .header {
        display: flex;
        /* Re-enable for mobile */
        top: 15px;
        /* Slightly higher on mobile to match smaller toggle */
    }

    .lang-toggle-container {
        top: 23px;
        /* Slightly lower on mobile to align with 15px header logo */
    }

    .hero-content h1 {
        font-size: 1.8rem;
        /* Slightly smaller for mobile */
        line-height: 1.3;
    }

    .subline {
        font-size: 1rem;
        /* Smaller subline on mobile */
    }

    /* V4: Mobile fixes - use cover to prevent duplication */
    .hero-background {
        background-image: url('images/dubai_background_mobile.png');
        /* Mobile uses specified .png */
        background-size: cover !important;
        /* Force cover on mobile to prevent duplication */
        background-position: center 30% !important;
        background-repeat: no-repeat;
        transform: scale(1);
        /* Start at normal scale, will be animated by JS */
        transition: transform 0.5s ease-out;
        /* Allow JS to animate zoom */
    }

    .hero-logo-container {
        width: 180px;
        /* Smaller logo on mobile */
        margin-bottom: var(--spacing-sm);
        /* Less spacing on mobile */
    }

    .hero-section {
        min-height: 500px;
        /* Ensure proper height on mobile */
        padding: var(--spacing-md) var(--spacing-sm);
    }

    /* Mobile-specific profile image */
    .profile-image {
        content: url('images/nicci_christensen_real-estate-agent_mobile.jpg');
    }
}