:root {
    /* Paleta Requerida */
    --midnight-navy: #0B0F1A;
    --deep-emerald: #0E3B2E;
    --champagne-gold: #D4AF37;
    --graphite-gray: #1F1F1F;
    --soft-sand: #E8DFC8;
    
    /* Tipografía */
    --font-serif: 'Cormorant Garamond', serif;
    --font-sans: 'Montserrat', sans-serif;
    
    /* Transiciones */
    --transition-slow: 0.6s cubic-bezier(0.25, 0.8, 0.25, 1);
    --transition-fast: 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--midnight-navy);
    color: var(--soft-sand);
    font-family: var(--font-sans);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Evitar scroll cuando el modal está abierto */
body.modal-open {
    overflow: hidden;
}

html {
    scroll-behavior: smooth;
}

/* Tipografía */
h1, h2, h3, .logo {
    font-family: var(--font-serif);
    font-weight: 600;
}
.dot { color: var(--champagne-gold); }

/* --- Navbar Glassmorphism --- */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 25px 5%;
    z-index: 1000;
    transition: var(--transition-fast);
}

.navbar.scrolled {
    background: rgba(11, 15, 26, 0.85);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border-bottom: 1px solid rgba(212, 175, 55, 0.1);
    padding: 15px 5%;
}

.logo {
    font-size: 2rem;
    letter-spacing: 2px;
}

.nav-links {
    display: flex;
    gap: 30px;
    align-items: center;
}

.nav-links a {
    color: var(--soft-sand);
    text-decoration: none;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    transition: var(--transition-fast);
}

.nav-links a:hover {
    color: var(--champagne-gold);
}

.lang-btn {
    background: transparent;
    border: 1px solid var(--soft-sand);
    color: var(--soft-sand);
    padding: 5px 10px;
    cursor: pointer;
    font-family: var(--font-sans);
    transition: var(--transition-fast);
}
.lang-btn:hover {
    border-color: var(--champagne-gold);
    color: var(--champagne-gold);
}

/* --- Hero Section - ACTUALIZACIÓN IMAGEN PREMIUM --- */
.hero {
    height: 100vh;
    background: url('https://images.unsplash.com/photo-1577717903315-1691ae25ab3f?q=80&w=2070&auto=format&fit=crop') center/cover no-repeat;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(11,15,26,0.3), var(--midnight-navy));
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    padding: 0 20px;
}

.hero h1 {
    font-size: 4.5rem;
    color: var(--soft-sand);
    margin-bottom: 20px;
    line-height: 1.1;
    text-shadow: 0 4px 10px rgba(0,0,0,0.5);
}

.hero p {
    font-size: 1.2rem;
    font-weight: 300;
    letter-spacing: 1px;
}

/* --- Search Bar --- */
.search-section {
    padding: 0 5%;
    margin-top: -50px;
    position: relative;
    z-index: 10;
}

.search-container {
    background: var(--graphite-gray);
    padding: 30px;
    display: flex;
    gap: 20px;
    justify-content: center;
    border: 1px solid rgba(212, 175, 55, 0.2);
    box-shadow: 0 20px 40px rgba(0,0,0,0.5);
}

.search-container select {
    background: var(--midnight-navy);
    color: var(--soft-sand);
    border: 1px solid rgba(232, 223, 200, 0.2);
    padding: 15px 20px;
    font-family: var(--font-sans);
    font-size: 0.9rem;
    outline: none;
    flex: 1;
    cursor: pointer;
}

/* Botones */
.btn-gold {
    background: var(--champagne-gold);
    color: var(--midnight-navy);
    border: none;
    padding: 15px 30px;
    font-family: var(--font-sans);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    transition: var(--transition-fast);
}
.btn-gold:hover {
    background: #e5c357;
    transform: translateY(-2px);
}

.btn-gold-outline {
    background: transparent;
    color: var(--champagne-gold);
    border: 2px solid var(--champagne-gold);
    padding: 15px 40px;
    font-family: var(--font-sans);
    text-transform: uppercase;
    letter-spacing: 2px;
    cursor: pointer;
    transition: var(--transition-fast);
}
.btn-gold-outline:hover {
    background: var(--champagne-gold);
    color: var(--midnight-navy);
}

/* --- Properties Grid --- */
.properties-section {
    padding: 100px 5%;
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-header h2 {
    font-size: 3rem;
    margin-bottom: 20px;
}

.line-separator {
    width: 60px;
    height: 2px;
    background: var(--champagne-gold);
    margin: 0 auto;
}

.properties-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 40px;
}

.property-card {
    background: var(--graphite-gray);
    position: relative;
    overflow: hidden;
    cursor: pointer;
    border: 1px solid transparent;
    transition: var(--transition-slow);
}

.property-card:hover {
    border-color: rgba(212, 175, 55, 0.5);
    box-shadow: 0 15px 30px rgba(0,0,0,0.4);
}

.property-img {
    height: 350px;
    overflow: hidden;
    position: relative;
}

.property-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.8s ease;
}

.property-card:hover .property-img img {
    transform: scale(1.08);
}

.property-tag {
    position: absolute;
    top: 20px;
    left: 20px;
    background: var(--deep-emerald);
    color: var(--soft-sand);
    padding: 5px 15px;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    z-index: 2;
}

.property-info {
    padding: 30px;
}

.property-info h3 {
    font-size: 1.8rem;
    margin-bottom: 10px;
}

.location {
    color: rgba(232, 223, 200, 0.7);
    font-size: 0.9rem;
    margin-bottom: 20px;
}

.features {
    font-size: 0.85rem;
    letter-spacing: 1px;
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 20px;
    margin-bottom: 20px;
}

.price {
    font-family: var(--font-serif);
    font-size: 1.5rem;
    color: var(--champagne-gold);
    font-weight: bold;
}

/* --- About & Services --- */
.about-services {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    padding: 100px 5%;
    background: var(--graphite-gray);
    align-items: center;
}

.about-content h2 { font-size: 3rem; margin-bottom: 30px; }
.about-content p { font-size: 1.1rem; color: rgba(232,223,200,0.8); }

.services-grid { display: flex; flex-direction: column; gap: 30px; }
.service-card {
    padding: 40px;
    background: var(--midnight-navy);
    border-left: 3px solid var(--champagne-gold);
}
.service-card h3 { font-size: 1.5rem; margin-bottom: 15px; }

/* --- Cinematic CTA --- */
.cinematic-cta {
    height: 60vh;
    background: url('https://images.unsplash.com/photo-1545324418-cc1a3fa10c00?q=80&w=2070&auto=format&fit=crop') center/cover fixed;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    text-align: center;
}
.cinematic-cta::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(11, 15, 26, 0.7);
}
.cta-content { position: relative; z-index: 2; }
.cta-content h2 { font-size: 3.5rem; margin-bottom: 40px; }

/* --- Testimonials --- */
.testimonials { padding: 100px 5%; text-align: center; background: var(--deep-emerald); }
.testimonials h2 { font-size: 2.5rem; margin-bottom: 50px; color: var(--champagne-gold); }
.slide { display: none; max-width: 800px; margin: 0 auto; }
.slide.active { display: block; animation: fadeIn 1s ease; }
.quote { font-family: var(--font-serif); font-size: 1.8rem; font-style: italic; margin-bottom: 20px; }
.author { font-size: 0.9rem; text-transform: uppercase; letter-spacing: 2px; }

/* --- Footer --- */
.premium-footer { background: var(--midnight-navy); padding: 80px 5% 30px; border-top: 1px solid rgba(255,255,255,0.05); }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 50px; margin-bottom: 60px; }
.footer-brand h2 { font-size: 2.5rem; margin-bottom: 15px; }
.footer-contact h3 { color: var(--champagne-gold); margin-bottom: 20px; }
.footer-contact p { margin-bottom: 10px; opacity: 0.7; }
.footer-bottom { text-align: center; border-top: 1px solid rgba(255,255,255,0.1); padding-top: 30px; font-size: 0.8rem; opacity: 0.5; }

/* --- Animations --- */
.reveal { opacity: 0; transform: translateY(40px); transition: 0.8s all ease; }
.reveal.active { opacity: 1; transform: translateY(0); }

@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

/* --- INICIO ESTILOS MODAL CINEMATOGRÁFICO --- */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.9);
    z-index: 2000;
    display: none; /* Hidden by default */
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity var(--transition-slow);
}

.modal-overlay.active {
    display: flex;
    opacity: 1;
}

.modal-content {
    background: var(--midnight-navy);
    width: 90%;
    max-width: 1200px;
    height: 85vh;
    border: 1px solid rgba(212, 175, 55, 0.3);
    position: relative;
    display: flex;
    overflow: hidden;
    transform: scale(0.9);
    transition: transform var(--transition-slow);
}

.modal-overlay.active .modal-content {
    transform: scale(1);
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 2.5rem;
    color: var(--soft-sand);
    cursor: pointer;
    z-index: 10;
    transition: var(--transition-fast);
}
.modal-close:hover {
    color: var(--champagne-gold);
}

/* Split Screen Layout */
.modal-left {
    flex: 1.5;
    background: black;
    height: 100%;
    position: relative;
}

.modal-right {
    flex: 1;
    padding: 60px 40px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    overflow-y: auto; /* For small screens */
}

/* Gallery inside modal */
.modal-gallery img#modal-main-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gallery-thumbs {
    position: absolute;
    bottom: 20px;
    left: 20px;
    display: flex;
    gap: 10px;
    z-index: 5;
}

.gallery-thumbs img {
    width: 80px;
    height: 60px;
    object-fit: cover;
    border: 2px solid transparent;
    cursor: pointer;
    transition: var(--transition-fast);
}

.gallery-thumbs img.active-thumb {
    border-color: var(--champagne-gold);
}

/* Modal Content Details */
.modal-header h2 { font-size: 2.8rem; margin: 20px 0 5px 0; }
.modal-body { flex-grow: 1; margin-top: 30px;}
.modal-body .description { font-size: 1rem; color: rgba(232, 223, 200, 0.8); margin-bottom: 30px; font-weight: 300; }
.modal-right .property-tag { position: relative; top: 0; left: 0; display: inline-block; }
.modal-footer { margin-top: 40px; }

/* Responsive Modal */
@media (max-width: 992px) {
    .modal-content { flex-direction: column; height: 95vh; overflow-y: auto; }
    .modal-left { height: 300px; flex: none; }
    .modal-right { padding: 30px; }
    .modal-header h2 { font-size: 2rem; }
}
/* --- FIN ESTILOS MODAL --- */

/* --- Responsive General --- */
@media (max-width: 768px) {
    .hero h1 { font-size: 3rem; }
    .search-container { flex-direction: column; }
    .about-services, .footer-grid { grid-template-columns: 1fr; }
    .navbar { flex-direction: column; background: rgba(11, 15, 26, 0.95); padding: 20px;}
    .nav-links { margin-top: 20px; flex-wrap: wrap; justify-content: center; }
}