/* -------------------------------------------------------------
 * DESIGN SYSTEM & ROOT VARIABLES
 * ------------------------------------------------------------- */
:root {
    --bg: #FAF8F5;
    --surface: #FFFFFF;
    --text-primary: #121212;
    --text-secondary: #6B7280;
    --primary: #121212;
    --accent: #4F46E5;
    --border: #ECECEC;
    --font-heading: 'Playfair Display', Georgia, serif;
    --font-body: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    --shadow-sm: 0 2px 12px rgba(0, 0, 0, 0.02);
    --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.04);
    --shadow-lg: 0 20px 48px rgba(0, 0, 0, 0.06);
    --transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
    scroll-behavior: smooth;
    font-size: 16px;
    background-color: var(--bg);
    color: var(--text-primary);
    font-family: var(--font-body);
    overflow-x: hidden;
}

body {
    position: relative;
    overflow-x: hidden;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
}

/* -------------------------------------------------------------
 * DECORATIVE OVERLAYS (Grain, Grid)
 * ------------------------------------------------------------- */
.grain-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
    opacity: 0.03;
    pointer-events: none;
    z-index: 9999;
}

.grid-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: 100px 100px;
    background-image: 
        linear-gradient(to right, rgba(236, 236, 236, 0.3) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(236, 236, 236, 0.3) 1px, transparent 1px);
    pointer-events: none;
    z-index: 1;
}

/* -------------------------------------------------------------
 * LAYOUT CONTAINER & TYPOGRAPHY
 * ------------------------------------------------------------- */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    position: relative;
    z-index: 2;
}

h1, h2, h3 {
    font-family: var(--font-heading);
    font-weight: 500;
    color: var(--text-primary);
    line-height: 1.15;
}

p {
    font-size: 1.05rem;
    line-height: 1.6;
    color: var(--text-secondary);
}

a {
    text-decoration: none;
    color: inherit;
}

/* -------------------------------------------------------------
 * BUTTONS
 * ------------------------------------------------------------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 28px;
    font-family: var(--font-body);
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    border-radius: 6px;
    transition: var(--transition);
    cursor: pointer;
    border: none;
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background-color: var(--text-primary);
    color: #FFFFFF;
}

.btn-primary:hover {
    background-color: #2a2a2a;
    transform: translateY(-2px);
}

.btn-secondary {
    background-color: transparent;
    color: var(--text-primary);
    border: 1px solid transparent;
    gap: 8px;
}

.btn-secondary:hover {
    background-color: rgba(0, 0, 0, 0.03);
    transform: translateY(-2px);
}

.arrow-icon {
    width: 16px;
    height: 16px;
}

/* Ripple effect container */
.ripple-btn .ripple-effect {
    position: absolute;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.2);
    transform: scale(0);
    animation: ripple 0.6s linear;
    pointer-events: none;
}

@keyframes ripple {
    to {
        transform: scale(4);
        opacity: 0;
    }
}

/* -------------------------------------------------------------
 * NAVBAR
 * ------------------------------------------------------------- */
.navbar {
    position: fixed;
    top: 24px;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 1200px;
    height: 76px;
    background-color: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(238, 238, 238, 0.5);
    border-radius: 999px;
    z-index: 1000;
    transition: var(--transition);
}

.navbar.scrolled {
    top: 12px;
    height: 64px;
    box-shadow: var(--shadow-md);
    background-color: rgba(255, 255, 255, 0.9);
}

.nav-container {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 28px;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--text-primary);
}

.nav-logo .logo-icon {
    width: 24px;
    height: 24px;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 36px;
}

.nav-link {
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    color: var(--text-secondary);
    transition: var(--transition);
}

.nav-link:hover, .nav-link.active {
    color: var(--text-primary);
}

.btn-nav {
    padding: 10px 20px;
    font-size: 0.8rem;
    background-color: var(--text-primary);
    color: #FFFFFF;
    border-radius: 999px;
}

.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
}

.menu-toggle .bar {
    width: 20px;
    height: 2px;
    background-color: var(--text-primary);
    transition: var(--transition);
}

/* Mobile Nav */
.mobile-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: var(--bg);
    z-index: 999;
    display: flex;
    align-items: center;
    justify-content: center;
    transform: translateY(-100%);
    transition: var(--transition);
}

.mobile-menu.open {
    transform: translateY(0);
}

.mobile-nav-links {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 28px;
    text-align: center;
}

.mobile-link {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
}

.btn-mobile {
    display: block;
    padding: 12px 32px;
    background-color: var(--text-primary);
    color: #FFFFFF;
    border-radius: 999px;
    font-size: 1rem;
}

/* -------------------------------------------------------------
 * HERO SECTION
 * ------------------------------------------------------------- */
.hero-section {
    padding-top: 220px;
    padding-bottom: 120px;
    background-image: linear-gradient(to right, rgba(250, 248, 245, 0.98) 45%, rgba(250, 248, 245, 0.6) 70%, rgba(250, 248, 245, 0.1) 100%), url('assets/hero_villa.png');
    background-size: cover;
    background-position: right center;
    background-repeat: no-repeat;
    position: relative;
}

.hero-container {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 48px;
}

.hero-content {
    max-width: 580px;
    position: relative;
}

.hero-visual {
    display: none; /* Hidden on desktop too, image is now the section background */
}

.hero-stats {
    display: flex;
    gap: 48px;
}

.hero-tag {
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    color: var(--text-secondary);
    margin-bottom: 24px;
}

.hero-title {
    font-size: clamp(3rem, 5vw, 4.5rem);
    letter-spacing: -0.02em;
    margin-bottom: 24px;
}

.hero-description {
    font-size: 1.15rem;
    color: var(--text-secondary);
    max-width: 480px;
    margin-bottom: 36px;
}

.hero-buttons {
    display: flex;
    gap: 16px;
    margin-bottom: 60px;
}

/* Stats */
.hero-stats {
    display: flex;
    gap: 48px;
}

.stat-item {
    display: flex;
    flex-direction: column;
}

.stat-number {
    font-family: var(--font-body);
    font-size: 2.25rem;
    font-weight: 700;
    color: var(--text-primary);
}

.stat-label {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-top: 4px;
}

/* Hero Right Side - Sloping frame */
.hero-visual {
    position: relative;
    width: 100%;
}

.hero-image-wrapper {
    position: relative;
    width: 100%;
    height: 540px;
    border-radius: 12px 12px 12px 220px; /* Custom sloping look matching image */
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    background-color: var(--border);
}

.hero-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.hero-image-wrapper:hover .hero-img {
    transform: scale(1.05);
}

/* Hero Floating Info Cards */
.floating-card {
    position: absolute;
    background-color: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    padding: 20px;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.4);
    box-shadow: var(--shadow-lg);
    transition: transform 0.2s ease-out;
    z-index: 10;
}

.card-price {
    top: 40px;
    right: -100px;
    width: 200px;
}

.card-tag {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--accent);
    letter-spacing: 0.05em;
}

.card-title {
    font-size: 1rem;
    font-weight: 700;
    margin-top: 4px;
}

.card-price-val {
    font-size: 1.25rem;
    font-weight: 800;
    margin-top: 8px;
    color: var(--text-primary);
}

.card-location {
    bottom: 40px;
    right: -420px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.95rem;
    font-weight: 600;
    padding: 14px 20px;
}

.loc-icon {
    width: 18px;
    height: 18px;
    color: var(--accent);
}

.card-agent {
    bottom: 120px;
    right: -160px;
    display: flex;
    align-items: center;
    gap: 12px;
    width: 240px;
}

.agent-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
}

.agent-name {
    font-size: 0.95rem;
    font-weight: 700;
}

.agent-rating {
    font-size: 0.8rem;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 2px;
}

.agent-rating .star {
    color: #FBBF24;
}

/* -------------------------------------------------------------
 * FEATURED LISTINGS
 * ------------------------------------------------------------- */
.featured-section {
    padding: 100px 0;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 48px;
}

.section-subtitle {
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    color: var(--text-secondary);
    margin-bottom: 12px;
    display: block;
}

.section-title {
    font-size: clamp(2.25rem, 3.5vw, 3rem);
}

/* Filter tabs on right */
.filter-tabs {
    display: flex;
    gap: 12px;
    align-items: center;
}

.filter-tab {
    background: none;
    border: none;
    padding: 10px 20px;
    font-family: var(--font-body);
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-secondary);
    cursor: pointer;
    transition: var(--transition);
    border-radius: 999px;
}

.filter-tab.active {
    background-color: var(--text-primary);
    color: #FFFFFF;
}

/* Listings Grid - 4 Columns */
.listings-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 28px;
}

.property-card {
    background-color: var(--surface);
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid var(--border);
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.property-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.property-image-container {
    position: relative;
    width: 100%;
    height: 240px;
    overflow: hidden;
}

.property-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.property-card:hover .property-img {
    transform: scale(1.06);
}

.property-badge {
    position: absolute;
    top: 16px;
    left: 16px;
    background-color: var(--text-primary);
    color: #FFFFFF;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 6px 14px;
    border-radius: 99px;
}

.property-info {
    padding: 24px;
}

.property-price {
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.property-price span {
    font-size: 0.85rem;
    color: var(--text-secondary);
    font-weight: 400;
}

.property-name {
    font-size: 1.15rem;
    font-weight: 500;
    margin-bottom: 12px;
    letter-spacing: -0.01em;
}

.property-location {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 16px;
}

.icon-loc {
    width: 14px;
    height: 14px;
}

.property-specs {
    display: flex;
    gap: 16px;
    border-top: 1px solid var(--border);
    padding-top: 16px;
    font-size: 0.8rem;
    color: var(--text-secondary);
}

/* -------------------------------------------------------------
 * DREAM HOME CTA SECTION (Dark purple box)
 * ------------------------------------------------------------- */
.dream-home-section {
    padding: 60px 0;
}

.dream-home-container {
    background-color: #171520; /* Dark section color from uploaded design */
    border-radius: 32px;
    padding: 72px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    align-items: center;
    overflow: hidden;
    position: relative;
}

.dream-home-subtitle {
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    color: rgba(255, 255, 255, 0.6);
    margin-bottom: 16px;
    display: block;
}

.dream-home-title {
    color: #FFFFFF;
    font-size: clamp(2rem, 3.5vw, 2.75rem);
    margin-bottom: 20px;
}

.dream-home-description {
    color: rgba(255, 255, 255, 0.7);
    font-size: 1.05rem;
    margin-bottom: 36px;
    max-width: 440px;
}

.btn-dream {
    background-color: #FFFFFF;
    color: #171520;
    gap: 8px;
    border-radius: 999px;
}

.btn-dream:hover {
    background-color: rgba(255, 255, 255, 0.9);
    transform: translateY(-2px);
}

/* Gallery slider in dark CTA */
.dream-home-gallery {
    position: relative;
    display: flex;
    align-items: center;
}

.gallery-wrapper {
    display: flex;
    gap: 20px;
    width: 100%;
    overflow: hidden;
}

.gallery-img {
    width: calc(33.33% - 14px);
    height: 180px;
    object-fit: cover;
    border-radius: 12px;
    transition: var(--transition);
}

.gallery-img:hover {
    transform: scale(1.05);
}

.gallery-next {
    position: absolute;
    right: -24px;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background-color: #FFFFFF;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
}

.gallery-next:hover {
    transform: scale(1.1);
}

.gallery-next svg {
    width: 20px;
    height: 20px;
    color: #171520;
}

/* -------------------------------------------------------------
 * ADVANTAGES SECTION (Why Choose Us)
 * ------------------------------------------------------------- */
.advantages-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 64px;
    align-items: center;
    padding: 80px 0;
}

.advantages-left {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
}

.advantage-item {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.advantage-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-primary);
}

.advantage-icon svg {
    width: 20px;
    height: 20px;
}

.advantage-info h3 {
    font-family: var(--font-body);
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.advantage-info p {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.advantages-right {
    height: 380px;
    border-radius: 20px;
    overflow: hidden;
}

.advantages-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* -------------------------------------------------------------
 * TESTIMONIALS SECTION
 * ------------------------------------------------------------- */
.testimonials-section {
    padding: 80px 0;
}

.testimonial-container {
    display: grid;
    grid-template-columns: 0.8fr 1.2fr;
    gap: 64px;
    align-items: center;
}

.testimonial-subtitle {
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    color: var(--text-secondary);
    margin-bottom: 12px;
    display: block;
}

.testimonial-title {
    font-size: clamp(2.25rem, 3.5vw, 3rem);
}

.testimonial-slider {
    position: relative;
    display: flex;
    align-items: center;
}

.testimonial-card {
    background-color: var(--surface);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 48px;
    box-shadow: var(--shadow-sm);
    width: 100%;
}

.quote-symbol {
    font-size: 6rem;
    font-family: var(--font-heading);
    color: rgba(0, 0, 0, 0.05);
    line-height: 1;
    margin-bottom: -32px;
    margin-top: -32px;
}

.testimonial-text {
    font-size: 1.35rem;
    color: var(--text-primary);
    line-height: 1.5;
    margin-bottom: 32px;
    font-weight: 400;
    transition: opacity 0.3s ease;
}

.testimonial-user {
    display: flex;
    align-items: center;
    gap: 16px;
}

.user-avatar {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    object-fit: cover;
}

.user-name {
    font-size: 1rem;
    font-weight: 700;
}

.user-role {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.slider-next {
    position: absolute;
    right: -24px;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background-color: var(--text-primary);
    color: #FFFFFF;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
}

.slider-next:hover {
    transform: scale(1.05);
}

.slider-next svg {
    width: 20px;
    height: 20px;
}

/* -------------------------------------------------------------
 * AGENT CONTACT SECTION
 * ------------------------------------------------------------- */
.agent-contact-section {
    background-color: #0E0E12;
    color: #FFFFFF;
    padding: 80px 0;
}

.agent-contact-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.agent-title {
    color: #FFFFFF;
    font-size: clamp(2rem, 3.5vw, 2.75rem);
}

.agent-form {
    display: flex;
    background-color: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 999px;
    padding: 6px 6px 6px 20px;
    width: 100%;
    max-width: 480px;
    align-items: center;
}

.agent-form input {
    background: none;
    border: none;
    padding: 10px 0;
    color: #FFFFFF;
    font-family: var(--font-body);
    flex-grow: 1;
    outline: none;
}

.agent-form input::placeholder {
    color: rgba(255, 255, 255, 0.3);
}

.btn-agent-submit {
    background-color: #FFFFFF;
    color: #0E0E12;
    font-weight: 800;
    border-radius: 999px;
    padding: 12px 28px;
}

.btn-agent-submit:hover {
    background-color: rgba(255, 255, 255, 0.9);
}

/* -------------------------------------------------------------
 * FOOTER
 * ------------------------------------------------------------- */
.footer {
    background-color: var(--surface);
    color: var(--text-primary);
    padding: 80px 0 40px;
    border-top: 1px solid var(--border);
}

.footer-container {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr;
    gap: 48px;
    margin-bottom: 60px;
}

.footer-brand {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
}

.footer-logo .logo-icon {
    width: 24px;
    height: 24px;
}

.footer-tagline {
    font-size: 0.9rem;
    color: var(--text-secondary);
    max-width: 260px;
}

.footer-links h4, .footer-socials-col h4 {
    font-size: 0.95rem;
    font-weight: 700;
    margin-bottom: 24px;
    color: var(--text-primary);
}

.footer-links ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.footer-links a {
    font-size: 0.9rem;
    color: var(--text-secondary);
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--text-primary);
}

.footer-socials {
    display: flex;
    gap: 12px;
}

.footer-socials a {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: rgba(0, 0, 0, 0.03);
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: 700;
    transition: var(--transition);
    border: 1px solid var(--border);
}

.footer-socials a:hover {
    background-color: var(--text-primary);
    color: #FFFFFF;
    border-color: var(--text-primary);
}

.footer-bottom {
    border-top: 1px solid var(--border);
    padding-top: 32px;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* -------------------------------------------------------------
 * REVEAL SCROLL ANIMATION
 * ------------------------------------------------------------- */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 1s cubic-bezier(0.16, 1, 0.3, 1), transform 1s cubic-bezier(0.16, 1, 0.3, 1);
}

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

/* -------------------------------------------------------------
 * RESPONSIVE MEDIA QUERIES
 * ------------------------------------------------------------- */
@media (max-width: 1024px) {
    .hero-container {
        grid-template-columns: 1fr;
        gap: 60px;
    }
    
    .hero-visual {
        max-width: 580px;
        margin: 0 auto;
    }
    
    .listings-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .dream-home-container {
        grid-template-columns: 1fr;
        padding: 48px;
    }
    
    .advantages-container {
        grid-template-columns: 1fr;
        gap: 48px;
    }
    
    .advantages-right {
        display: none;
    }
    
    .testimonial-container {
        grid-template-columns: 1fr;
        gap: 40px;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 0 20px;
    }

    .navbar {
        height: 64px;
        width: 92%;
        top: 16px;
    }
    
    .nav-links, .btn-nav {
        display: none;
    }
    
    .menu-toggle {
        display: flex;
    }
    
    .hero-container {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }

    .hero-section {
        padding-top: 140px;
        padding-bottom: 48px;
        background-image: linear-gradient(to bottom, rgba(250, 248, 245, 0.9) 30%, rgba(250, 248, 245, 0.4) 70%, rgba(250, 248, 245, 0.95) 100%), url('assets/hero_villa.png');
        background-size: cover;
        background-position: center;
        background-repeat: no-repeat;
    }

    .hero-title {
        font-size: 2.75rem;
        margin-bottom: 12px;
    }

    .hero-description {
        font-size: 1rem;
        margin-bottom: 20px;
    }
    
    .hero-buttons {
        display: flex;
        flex-direction: row;
        align-items: center;
        gap: 20px;
        margin-bottom: 0;
        width: 100%;
    }

    .hero-buttons .btn {
        width: auto;
        padding: 12px 24px;
    }

    .hero-buttons .btn-secondary {
        border: none;
        background: none;
        padding: 12px 0;
    }
    
    .hero-visual {
        display: none; /* Hide original image div since it is now the section background */
    }

    .hero-stats {
        width: 100%;
        order: 3;
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        padding: 20px 0;
        gap: 0;
        margin-top: 140px; /* Spacer to let the background image show through */
        background-color: rgba(255, 255, 255, 0.7);
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        border: 1px solid rgba(238, 238, 238, 0.5);
        border-radius: 16px;
    }

    .hero-stats .stat-item {
        text-align: center;
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .hero-stats .stat-item:not(:last-child) {
        border-right: 1px solid var(--border);
    }

    .hero-stats .stat-number {
        font-size: 1.75rem;
    }

    .hero-stats .stat-label {
        font-size: 0.75rem;
    }

    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
    }

    .filter-tabs {
        width: 100%;
        overflow-x: auto;
        white-space: nowrap;
        padding-bottom: 8px;
        -webkit-overflow-scrolling: touch;
    }

    .listings-grid {
        display: flex;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        gap: 20px;
        padding-bottom: 20px;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }

    .listings-grid::-webkit-scrollbar {
        display: none;
    }

    .listings-grid .property-card {
        flex: 0 0 300px;
        scroll-snap-align: start;
    }

    .dream-home-container {
        padding: 40px 24px;
    }

    .gallery-wrapper {
        gap: 12px;
    }

    .gallery-img {
        height: 140px;
    }

    .testimonial-card {
        padding: 32px 20px;
    }

    .testimonial-text {
        font-size: 1.15rem;
    }

    .slider-next {
        right: -12px;
        width: 48px;
        height: 48px;
    }
    
    .agent-contact-container {
        flex-direction: column;
        gap: 32px;
        text-align: center;
    }

    .agent-form {
        max-width: 100%;
        flex-direction: column;
        border-radius: 16px;
        padding: 16px;
        gap: 16px;
    }

    .agent-form input {
        width: 100%;
        text-align: center;
        padding: 8px 0;
    }

    .btn-agent-submit {
        width: 100%;
    }
    
    .footer-container {
        grid-template-columns: 1fr;
        gap: 32px;
    }
}

@media (max-width: 480px) {
    .listings-grid .property-card {
        flex: 0 0 270px;
    }
    
    .advantages-left {
        grid-template-columns: 1fr;
    }

    .gallery-img {
        width: 100%;
    }

    .gallery-img:not(:first-child) {
        display: none;
    }
}
