/* Fuentes: se cargan por <link rel="preconnect"> + <link> en el <head> de cada página
   (más rápido que @import, que bloquea el render en cadena). display=swap se mantiene. */

:root {
    --primary: #0a0f1c; /* Deep premium navy/black */
    --primary-light: #162032;
    --accent: #dc2626; /* RE/MAX Red refined */
    --accent-hover: #b91c1c;
    --gold: #d4af37; /* Premium Gold Accent */
    --gold-light: #f3e5ab;
    --bg-main: #f8fafc;
    --bg-alt: #ffffff;
    --text-main: #334155;
    --text-light: #64748b;
    --border: #e2e8f0;
    
    /* Premium Shadows */
    --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 10px 20px -5px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 25px 50px -12px rgba(0, 0, 0, 0.15);
    --shadow-gold: 0 10px 25px -5px rgba(212, 175, 55, 0.3);
    
    /* Border Radius */
    --radius-sm: 6px;
    --radius-md: 12px;
    --radius-lg: 20px;
    
    --transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

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

body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--bg-main);
    color: var(--text-main);
    line-height: 1.7;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
    color: var(--primary);
    font-weight: 600;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

.font-serif {
    font-family: 'Playfair Display', serif;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
}

.section {
    padding: 100px 0;
}

.section-title {
    font-size: 2.75rem;
    text-align: center;
    margin-bottom: 1rem;
    font-family: 'Playfair Display', serif;
    color: var(--primary);
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background: var(--gold);
    margin: 20px auto 0;
    border-radius: 2px;
}

.section-subtitle {
    text-align: center;
    color: var(--text-light);
    font-size: 1.15rem;
    max-width: 650px;
    margin: 0 auto 50px auto;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 16px 32px;
    border-radius: var(--radius-sm);
    font-weight: 500;
    font-size: 1.05rem;
    cursor: pointer;
    border: none;
    transition: var(--transition);
    text-align: center;
    letter-spacing: 0.5px;
}

.btn i {
    margin-right: 8px;
}

.btn-primary {
    background-color: var(--accent);
    color: white;
}

.btn-primary:hover {
    background-color: var(--accent-hover);
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(220, 38, 38, 0.25);
}

.btn-secondary {
    background-color: var(--primary);
    color: white;
}

.btn-secondary:hover {
    background-color: var(--primary-light);
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(10, 15, 28, 0.25);
}

.btn-gold {
    background-color: var(--gold);
    color: var(--primary);
    font-weight: 600;
}

.btn-gold:hover {
    background-color: #e5c158;
    transform: translateY(-3px);
    box-shadow: var(--shadow-gold);
}

.btn-outline {
    background-color: transparent;
    border: 1px solid var(--border);
    color: var(--primary);
}

.btn-outline:hover {
    border-color: var(--primary);
    background-color: var(--primary);
    color: white;
}

.btn-whatsapp {
    background-color: #25D366;
    color: white;
    font-weight: 600;
}

.btn-whatsapp:hover {
    background-color: #20bd5a;
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(37, 211, 102, 0.3);
}

/* Navbar */
.navbar {
    background-color: rgba(10, 15, 28, 0.95);
    backdrop-filter: blur(12px);
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: var(--transition);
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 85px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.nav-links {
    display: flex;
    gap: 2.5rem;
    align-items: center;
}

.nav-links a {
    font-size: 0.95rem;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.7);
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gold);
    transition: var(--transition);
}

.nav-links a:hover,
.nav-links a.active {
    color: white;
}

.nav-links a:hover::after,
.nav-links a.active::after {
    width: 100%;
}

.nav-links .btn {
    padding: 10px 24px;
}

.nav-links .btn::after {
    display: none;
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: white;
    cursor: pointer;
}

@media (max-width: 900px) {
    .nav-links {
        display: none;
        position: absolute;
        top: 85px;
        left: 0;
        width: 100%;
        background: var(--primary);
        flex-direction: column;
        padding: 30px 0;
        box-shadow: var(--shadow-lg);
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }
    .nav-links a {
        padding: 12px 0;
        font-size: 1.1rem;
    }
    .nav-links.active {
        display: flex;
    }
    .mobile-menu-btn {
        display: block;
    }
}

/* Hero Section Premium */
.hero {
    position: relative;
    padding: 140px 0;
    background-color: var(--primary);
    color: white;
    overflow: hidden;
    min-height: 90vh;
    display: flex;
    align-items: center;
}

.hero::after {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: linear-gradient(135deg, rgba(10,15,28,0.95) 0%, rgba(10,15,28,0.7) 100%);
    z-index: 1;
}

.hero-bg {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    object-fit: cover;
    z-index: 0;
    transform: scale(1.05);
    animation: slowZoom 20s infinite alternate;
}

@keyframes slowZoom {
    0% { transform: scale(1.05); }
    100% { transform: scale(1.15); }
}

.hero .container {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 60px;
    width: 100%;
}

.hero-content {
    flex: 1.2;
    max-width: 700px;
}

.hero-tagline {
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 3px;
    color: var(--gold);
    margin-bottom: 1.5rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 15px;
}

.hero-tagline::before {
    content: '';
    width: 40px;
    height: 1px;
    background: var(--gold);
}

.hero-title {
    font-size: 4.5rem;
    color: white;
    margin-bottom: 1.5rem;
    font-family: 'Playfair Display', serif;
    line-height: 1.1;
}

.hero-subtitle {
    font-size: 1.2rem;
    color: rgba(255,255,255,0.8);
    margin-bottom: 3rem;
    line-height: 1.8;
    font-weight: 300;
}

.hero-buttons {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.hero-image {
    flex: 0.8;
    display: flex;
    justify-content: flex-end;
}

.hero-agent-card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 30px;
    border-radius: var(--radius-lg);
    box-shadow: 0 30px 60px rgba(0,0,0,0.4);
    color: white;
    text-align: center;
    max-width: 340px;
    position: relative;
    overflow: hidden;
}

.hero-agent-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 100%; height: 5px;
    background: linear-gradient(90deg, var(--gold), var(--accent));
}

.hero-agent-card img {
    width: 180px;
    height: 180px;
    border-radius: 50%;
    object-fit: cover;
    object-position: top;
    margin: 0 auto 25px auto;
    border: 3px solid rgba(255,255,255,0.2);
    display: block;
    box-shadow: 0 10px 20px rgba(0,0,0,0.3);
}

.hero-agent-card h3 {
    font-size: 1.5rem;
    margin-bottom: 5px;
    color: white;
}

.hero-agent-card p {
    color: rgba(255,255,255,0.7);
    font-size: 0.95rem;
    margin-bottom: 15px;
}

.hero-agent-card .badge {
    display: inline-block;
    background: rgba(212, 175, 55, 0.15);
    color: var(--gold);
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
    border: 1px solid rgba(212, 175, 55, 0.3);
}

@media (max-width: 1024px) {
    .hero .container { flex-direction: column; text-align: center; }
    .hero-title { font-size: 3.5rem; }
    .hero-tagline { justify-content: center; }
    .hero-tagline::before { display: none; }
    .hero-buttons { justify-content: center; }
    .hero-image { justify-content: center; margin-top: 40px; }
}

/* Cards Generales */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 40px;
}

.service-card {
    background: var(--bg-alt);
    padding: 50px 40px;
    border-radius: var(--radius-lg);
    text-align: center;
    border: 1px solid var(--border);
    transition: var(--transition);
    position: relative;
    z-index: 1;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(180deg, rgba(212, 175, 55, 0.03) 0%, rgba(255,255,255,0) 100%);
    z-index: -1;
    opacity: 0;
    transition: var(--transition);
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg);
    border-color: rgba(212, 175, 55, 0.3);
}

.service-card:hover::before {
    opacity: 1;
}

.service-icon {
    width: 80px;
    height: 80px;
    background: rgba(10, 15, 28, 0.03);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: var(--primary);
    margin: 0 auto 30px auto;
    transition: var(--transition);
}

.service-card:hover .service-icon {
    background: var(--primary);
    color: white;
}

.service-card h3 {
    margin-bottom: 15px;
    font-size: 1.5rem;
}

.service-card p {
    color: var(--text-light);
    margin-bottom: 30px;
}

/* Propiedades Cards */
.prop-card {
    background: var(--bg-alt);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    border: 1px solid var(--border);
    display: flex;
    flex-direction: column;
}

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

.prop-img {
    height: 250px;
    background-color: #E2E8F0;
    position: relative;
    overflow: hidden;
}

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

.prop-card:hover .prop-img img {
    transform: scale(1.08);
}

.prop-badge {
    position: absolute;
    top: 20px;
    left: 20px;
    background: rgba(10, 15, 28, 0.85);
    backdrop-filter: blur(4px);
    color: white;
    padding: 6px 14px;
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: 4px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.prop-content {
    padding: 30px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.prop-price {
    font-size: 1.75rem;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 10px;
    font-family: 'Playfair Display', serif;
}

.prop-title {
    font-size: 1.15rem;
    margin-bottom: 15px;
    line-height: 1.4;
    flex: 1;
}

.prop-meta {
    display: flex;
    gap: 20px;
    color: var(--text-light);
    font-size: 0.9rem;
    margin-bottom: 25px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border);
}

.prop-meta span {
    display: flex;
    align-items: center;
    gap: 8px;
}

.prop-meta i {
    color: var(--gold);
}

/* Formularios Premium */
.form-wrapper {
    background: var(--bg-alt);
    padding: 50px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    border: 1px solid rgba(0,0,0,0.05);
}

.form-group {
    margin-bottom: 25px;
}

.form-group label {
    display: block;
    margin-bottom: 10px;
    font-weight: 500;
    color: var(--primary);
    font-size: 0.95rem;
}

.form-control {
    width: 100%;
    padding: 16px 20px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 1rem;
    font-family: inherit;
    transition: var(--transition);
    background: var(--bg-main);
    color: var(--text-main);
}

.form-control:focus {
    outline: none;
    border-color: var(--primary);
    background: white;
    box-shadow: 0 0 0 4px rgba(10, 15, 28, 0.05);
}

textarea.form-control {
    resize: vertical;
    min-height: 150px;
}

/* Landing Pages Layout Genérico */
.landing-header {
    background: var(--primary);
    color: white;
    padding: 120px 0 80px 0;
    text-align: center;
    position: relative;
}

.landing-header::after {
    content: '';
    position: absolute;
    bottom: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(0deg, rgba(10,15,28,1) 0%, rgba(10,15,28,0) 100%);
    pointer-events: none;
}

.landing-header h1 {
    color: white;
    font-size: 3.5rem;
    margin-bottom: 20px;
    font-family: 'Playfair Display', serif;
    position: relative;
    z-index: 2;
}

.landing-header p {
    position: relative;
    z-index: 2;
    font-size: 1.2rem;
    color: rgba(255,255,255,0.8);
    max-width: 600px;
    margin: 0 auto;
}

.landing-layout {
    display: flex;
    gap: 60px;
    padding: 80px 0;
}

.landing-content {
    flex: 1.6;
}

.landing-sidebar {
    flex: 1;
}

@media(max-width: 960px) {
    .landing-layout { flex-direction: column; }
}

/* Beneficios List */
.benefits-list {
    margin: 40px 0;
}

.benefits-list li {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    margin-bottom: 30px;
    padding: 20px;
    background: white;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border);
    transition: var(--transition);
}

.benefits-list li:hover {
    transform: translateX(5px);
    box-shadow: var(--shadow-md);
    border-color: rgba(212, 175, 55, 0.3);
}

.benefits-list li i {
    color: var(--gold);
    font-size: 1.8rem;
    margin-top: 5px;
}

.benefits-list h4 {
    margin-bottom: 8px;
    font-size: 1.2rem;
}

.benefits-list p {
    color: var(--text-light);
    font-size: 1rem;
    line-height: 1.6;
}

/* Costo de Vida Específico */
.costo-summary {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-bottom: 60px;
}

.costo-stat {
    background: white;
    border: 1px solid var(--border);
    padding: 35px 25px;
    border-radius: var(--radius-lg);
    text-align: center;
    box-shadow: var(--shadow-sm);
    position: relative;
    overflow: hidden;
}

.costo-stat::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 100%; height: 4px;
    background: var(--gold);
}

.costo-stat h4 {
    color: var(--text-light);
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 15px;
}

.costo-stat .val {
    font-size: 2.5rem;
    color: var(--primary);
    font-weight: 700;
    font-family: 'Playfair Display', serif;
}

/* Footer */
footer {
    background-color: var(--primary);
    color: white;
    padding: 80px 0 30px 0;
    border-top: 1px solid rgba(255,255,255,0.05);
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 50px;
    margin-bottom: 60px;
}

.footer-col h4 {
    color: white;
    margin-bottom: 25px;
    font-size: 1.3rem;
    font-family: 'Playfair Display', serif;
}

.footer-col ul li {
    margin-bottom: 15px;
}

.footer-col ul li a {
    color: rgba(255,255,255,0.6);
    display: inline-block;
}

.footer-col ul li a:hover {
    color: var(--gold);
    transform: translateX(5px);
}

.footer-bottom {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.4);
    font-size: 0.95rem;
}

/* Floating WhatsApp */
.floating-whatsapp {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background-color: #25D366;
    color: white;
    width: 65px;
    height: 65px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 35px;
    box-shadow: 0 10px 25px rgba(37, 211, 102, 0.4);
    z-index: 1000;
    transition: var(--transition);
}

.floating-whatsapp:hover {
    transform: scale(1.1) translateY(-5px);
    box-shadow: 0 15px 35px rgba(37, 211, 102, 0.5);
}

/* Success Alert */
.alert-success {
    background-color: #ecfdf5;
    color: #065f46;
    padding: 20px;
    border-radius: var(--radius-sm);
    margin-bottom: 25px;
    border: 1px solid #10b981;
    display: none;
    font-weight: 500;
}

/* Costo Detallado Grid */
.detail-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
    margin: 50px 0;
}

.detail-card {
    background: white;
    padding: 35px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border);
}

.detail-card h3 {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 25px;
    color: var(--primary);
    font-size: 1.3rem;
}

.cost-item {
    display: flex;
    justify-content: space-between;
    padding: 15px 0;
    border-bottom: 1px solid var(--border);
    color: var(--text-main);
    font-size: 1rem;
}

.cost-item:last-child {
    border-bottom: none;
}

.cost-item span:last-child {
    font-weight: 600;
    color: var(--primary);
    text-align: right;
    min-width: 90px;
}
