/* ============================================
   Real Estate Website Template - Stylesheet
   Based on Design Token System
   ============================================ */

/* ============================================
   CSS Variables - Design Tokens
   ============================================ */
:root {
    /* Primary Colors */
    --color-primary-600: #1e40af;
    --color-primary-700: #1e3a8a;
    --color-primary-500: #3b82f6;
    --color-primary-400: #60a5fa;
    
    /* Secondary Colors */
    --color-secondary-600: #0d9488;
    --color-secondary-500: #14b8a6;
    --color-accent-500: #f59e0b;
    
    /* Neutral Scale */
    --color-neutral-900: #0f172a;
    --color-neutral-800: #1e293b;
    --color-neutral-700: #334155;
    --color-neutral-600: #475569;
    --color-neutral-500: #64748b;
    --color-neutral-400: #94a3b8;
    --color-neutral-300: #cbd5e1;
    --color-neutral-200: #e2e8f0;
    --color-neutral-100: #f1f5f9;
    --color-neutral-50: #ffffff;
    
    /* Semantic Colors */
    --color-success-600: #059669;
    --color-success-500: #10b981;
    --color-warning-600: #d97706;
    --color-warning-500: #f59e0b;
    --color-danger-600: #dc2626;
    --color-danger-500: #ef4444;
    --color-focus-500: #3b82f6;
    
    /* Background Gradients */
    --gradient-hero: linear-gradient(180deg, #f8fafc 0%, #e2e8f0 50%, #cbd5e1 100%);
    --gradient-primary: linear-gradient(135deg, #1e40af 0%, #3b82f6 100%);
    --gradient-surface: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
    
    /* Glassmorphism */
    --glass-light: rgba(255, 255, 255, 0.95);
    --glass-medium: rgba(255, 255, 255, 0.85);
    --glass-dark: rgba(15, 23, 42, 0.85);
    --glass-blur: 20px;
    
    /* Spacing System */
    --space-xs: 0.5rem;    /* 8px */
    --space-sm: 1rem;      /* 16px */
    --space-md: 1.5rem;    /* 24px */
    --space-lg: 2rem;      /* 32px */
    --space-xl: 3rem;      /* 48px */
    --space-2xl: 4rem;     /* 64px */
    --space-3xl: 5rem;     /* 80px */
    --space-4xl: 6rem;     /* 96px */
    --space-5xl: 7.5rem;   /* 120px */
    
    /* Section Spacing - 150px total gap between sections (75px top + 75px bottom) */
    --section-padding-desktop: 75px;
    --section-padding-tablet: 60px;
    --section-padding-mobile: 50px;
    
    /* Border Radius */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --radius-full: 9999px;
    
    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    
    /* Focus States */
    --focus-ring: 0 0 0 3px rgba(59, 130, 246, 0.5);
    
    /* Typography */
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-size-base: 16px;
    --line-height-base: 1.6;
    --line-height-tight: 1.2;
    
    /* Z-Index Layers */
    --z-base: 1;
    --z-leaves: 50;
    --z-dropdown: 100;
    --z-sticky: 200;
    --z-fixed: 300;
    --z-modal-backdrop: 400;
    --z-modal: 500;
    --z-popover: 600;
    --z-tooltip: 700;
    
    /* Container */
    --container-max-width: 1280px;
    --container-padding-mobile: 1.5rem;
    --container-padding-desktop: 2rem;
}

/* ============================================
   Reset & Base Styles
   ============================================ */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: var(--font-size-base);
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-family);
    font-size: var(--font-size-base);
    line-height: var(--line-height-base);
    color: var(--color-neutral-900);
    background-color: var(--color-neutral-50);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
    text-rendering: optimizeLegibility;
}

/* ============================================
   Typography
   ============================================ */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: var(--line-height-tight);
    color: var(--color-neutral-900);
    margin-bottom: var(--space-md);
}

h1 { 
    font-size: clamp(2rem, 5vw, 3.5rem);
    letter-spacing: -0.02em;
}

h2 { 
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    letter-spacing: -0.01em;
}

h3 { 
    font-size: clamp(1.5rem, 3vw, 2rem);
}

p {
    margin-bottom: var(--space-md);
    color: var(--color-neutral-700);
}

a {
    color: var(--color-primary-600);
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover,
a:focus {
    color: var(--color-primary-700);
    outline: none;
}

a:focus-visible {
    outline: 2px solid var(--color-focus-500);
    outline-offset: 2px;
    border-radius: var(--radius-sm);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

ul, ol {
    list-style: none;
}

button {
    font-family: inherit;
    cursor: pointer;
}

/* ============================================
   Container & Layout
   ============================================ */
.container {
    width: 100%;
    max-width: var(--container-max-width);
    margin: 0 auto;
    padding-left: var(--container-padding-mobile);
    padding-right: var(--container-padding-mobile);
}

@media (min-width: 768px) {
    .container {
        padding-left: var(--container-padding-desktop);
        padding-right: var(--container-padding-desktop);
    }
}

/* ============================================
   Section Styles
   ============================================ */
.section {
    padding-top: var(--section-padding-mobile);
    padding-bottom: var(--section-padding-mobile);
}

@media (min-width: 768px) {
    .section {
        padding-top: var(--section-padding-tablet);
        padding-bottom: var(--section-padding-tablet);
    }
}

@media (min-width: 1024px) {
    .section {
        padding-top: var(--section-padding-desktop);
        padding-bottom: var(--section-padding-desktop);
    }
}

.section-header {
    text-align: center;
    margin-bottom: 40px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.section-title {
    font-size: clamp(1.75rem, 4vw, 2.75rem);
    margin-bottom: var(--space-md);
    color: var(--color-neutral-900);
}

.section-subtitle {
    font-size: clamp(1rem, 2vw, 1.25rem);
    color: var(--color-neutral-600);
    line-height: 1.6;
}

/* ============================================
   Buttons
   ============================================ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.875rem 2rem;
    font-size: 1rem;
    font-weight: 600;
    text-align: center;
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    line-height: 1.5;
    white-space: nowrap;
}

.btn-primary {
    background: var(--gradient-primary);
    color: var(--color-neutral-50);
    box-shadow: var(--shadow-md);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
    color: var(--color-neutral-50);
}

.btn-secondary {
    background-color: var(--color-neutral-50);
    color: var(--color-primary-600);
    border: 2px solid var(--color-primary-600);
}

.btn-secondary:hover {
    background-color: var(--color-primary-600);
    color: var(--color-neutral-50);
}

.btn-large {
    padding: 1.125rem 2.5rem;
    font-size: clamp(1rem, 2vw, 1.125rem);
}

.btn-block {
    width: 100%;
    display: flex;
}

/* ============================================
   Header & Navigation
   ============================================ */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: var(--glass-light);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    z-index: var(--z-fixed);
    box-shadow: var(--shadow-sm);
    transition: box-shadow 0.3s ease;
}

.nav-container {
    max-width: var(--container-max-width);
    margin: 0 auto;
    padding: var(--space-md) var(--container-padding-mobile);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: var(--space-lg);
    width: 100%;
}

.logo {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    font-size: clamp(1.25rem, 2vw, 1.5rem);
    font-weight: 700;
    color: var(--color-primary-600);
    flex-shrink: 0;
}

.logo-img {
    height: clamp(32px, 4vw, 40px);
    width: auto;
    object-fit: contain;
    display: block;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: clamp(1rem, 2vw, 2rem);
    align-items: center;
    margin: 0;
    padding: 0;
}

.nav-link {
    color: var(--color-neutral-800);
    font-weight: 500;
    font-size: clamp(0.875rem, 1.5vw, 1rem);
    transition: color 0.2s ease;
    padding: var(--space-xs) 0;
}

.nav-link:hover {
    color: var(--color-primary-600);
}

.btn-cta-nav {
    background: var(--gradient-primary);
    color: var(--color-neutral-50);
    padding: 0.625rem 1.5rem;
    border-radius: var(--radius-md);
    white-space: nowrap;
    border: none;
    cursor: pointer;
    font-family: inherit;
    font-size: inherit;
}

.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    gap: 4px;
    background: none;
    border: none;
    cursor: pointer;
    padding: var(--space-xs);
    z-index: calc(var(--z-fixed) + 1);
}

.mobile-menu-toggle span {
    width: 25px;
    height: 3px;
    background-color: var(--color-neutral-900);
    border-radius: 2px;
    transition: all 0.3s ease;
}

/* ============================================
   Hero Section
   ============================================ */
.hero {
    position: relative;
    width: 100%;
    height: 90vh;
    min-height: 700px;
    max-height: 1100px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 72px;
}

.hero-slider {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: var(--z-base);
}

.hero-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 1.2s ease-in-out;
}

.hero-slide.active {
    opacity: 1;
}

.hero-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        180deg,
        rgba(0, 0, 0, 0.5) 0%,
        rgba(0, 0, 0, 0.65) 40%,
        rgba(0, 0, 0, 0.75) 100%
    );
    mix-blend-mode: multiply;
    z-index: calc(var(--z-base) + 1);
}

.hero-content {
    position: relative;
    z-index: calc(var(--z-base) + 2);
    text-align: center;
    color: var(--color-neutral-50);
    padding: 0 var(--container-padding-mobile);
    max-width: 900px;
    width: 100%;
}

.hero-title {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 800;
    line-height: 1.2;
    color: #ffffff;
    text-shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
    margin-bottom: var(--space-lg);
    letter-spacing: -0.02em;
}

.hero-subtitle {
    font-size: clamp(1.2rem, 2vw, 1.6rem);
    color: rgba(255, 255, 255, 0.9);
    font-weight: 400;
    margin-bottom: var(--space-2xl);
    text-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
    line-height: 1.5;
}

.hero-cta {
    display: flex;
    gap: var(--space-md);
    justify-content: center;
    flex-wrap: wrap;
    align-items: center;
    margin-top: var(--space-xl);
}

.hero-indicators {
    position: absolute;
    bottom: var(--space-xl);
    left: 50%;
    transform: translateX(-50%);
    z-index: calc(var(--z-base) + 3);
    display: flex;
    gap: var(--space-sm);
}

.hero-indicator {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: 2px solid var(--color-neutral-50);
    background: transparent;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 0;
}

.hero-indicator.active {
    background: var(--color-neutral-50);
}

.hero-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: calc(var(--z-base) + 3);
    background: rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(10px);
    border: none;
    color: #fff;
    font-size: clamp(2rem, 4vw, 2.5rem);
    width: 54px;
    height: 54px;
    border-radius: 999px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.hero-nav-prev {
    left: var(--space-lg);
}

.hero-nav-next {
    right: var(--space-lg);
}

/* ============================================
   Responsive Design
   ============================================ */
@media (max-width: 768px) {
    .nav-menu {
        position: fixed;
        top: 72px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 72px);
        background: var(--glass-light);
        backdrop-filter: blur(var(--glass-blur));
        flex-direction: column;
        padding: var(--space-2xl);
        transition: left 0.3s ease;
        box-shadow: var(--shadow-xl);
        z-index: calc(var(--z-fixed) - 1);
        overflow-y: auto;
    }
    
    .nav-menu.active {
        left: 0;
    }
    
    .mobile-menu-toggle {
        display: flex;
    }
    
    .hero {
        height: 75vh;
        min-height: 500px;
        max-height: 800px;
    }
    
    .hero-nav {
        display: none;
    }
}

/* ============================================
   Additional Component Styles
   (Import from component-specific CSS files)
   ============================================ */

/* Note: Additional component styles (about, gallery, floor-plans, amenities, location, footer, modals) 
   should be imported or added here. For brevity, this template includes the core structure.
   Full component styles are available in the reference files. */

