/* 
   Casa Rural Mil Mariposas - Design System & Global Styles
   Aesthetic: Rustic-Modern Fusion
*/

:root {
    /* Color Palette */
    --primary-burgos: #4B3621;   /* Deep Walnut Stone */
    --secondary-rust: #D2691E;   /* Terracotta / Autumn Leaf */
    --accent-butterfly: #EADDCA; /* Soft Beige / Butterfly Wing */
    --nature-green: #2F4F4F;     /* Forest Slate */
    --luxury-gold: #C5A059;      /* Sunset Accent */
    --bg-light: #FAF9F6;         /* Off-white canvas */
    --text-main: #2C2C2C;
    --text-muted: #666666;

    /* Typography */
    --font-heading: 'Playfair Display', serif;
    --font-body: 'Outfit', sans-serif;

    /* Spacing & Effects */
    --glass-bg: rgba(255, 255, 255, 0.85);
    --glass-border: rgba(255, 255, 255, 0.3);
    --transition-smooth: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
    --shadow-premium: 0 20px 40px rgba(0, 0, 0, 0.08);
}

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

html {
    scroll-behavior: smooth;
}

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

h1, h2, h3, h4 {
    font-family: var(--font-heading);
    font-weight: 700;
}

/* --- Navigation --- */
nav {
    position: fixed;
    top: 0;
    width: 100%;
    padding: 1.5rem 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 1000;
    transition: var(--transition-smooth);
}

nav.scrolled {
    background: var(--glass-bg);
    backdrop-filter: blur(15px);
    padding: 1rem 5%;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.03);
}

.logo {
    font-family: var(--font-heading);
    font-size: clamp(1.2rem, 4vw, 1.8rem);
    font-weight: 900;
    color: var(--primary-burgos);
    text-transform: uppercase;
    letter-spacing: 2px;
}

.nav-links {
    display: flex;
    gap: clamp(1rem, 3vw, 3rem);
    list-style: none;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-main);
    font-weight: 500;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
}

.nav-links a:hover {
    color: var(--secondary-rust);
}

@media (max-width: 768px) {
    .nav-links { display: none; } /* Mobile menu simplified */
}

/* --- Floating Contact --- */
.floating-contact {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 1001;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.contact-btn {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-decoration: none;
    font-size: 1.5rem;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    transition: transform 0.3s;
}

.contact-btn:hover {
    transform: scale(1.1) rotate(5deg);
}

.btn-whatsapp { background: #25D366; }
.btn-call { background: var(--secondary-rust); }

/* --- Hero Section --- */
.hero {
    height: 100vh;
    width: 100%;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.hero.full-width {
    max-width: none;
    padding: 0;
}

.hero-carousel {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 110%;
    z-index: -1;
    overflow: hidden;
    will-change: transform;
}

.carousel-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 1.5s ease-in-out;
    z-index: 1;
}

.carousel-slide.active {
    opacity: 1;
    z-index: 2;
}

.carousel-indicators {
    position: absolute;
    bottom: 10%;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 1rem;
    z-index: 10;
}

.carousel-indicators .dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(5px);
    cursor: pointer;
    transition: var(--transition-smooth);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.carousel-indicators .dot.active {
    background: white;
    transform: scale(1.3);
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.5);
}

.hero-content {
    text-align: center;
    color: white;
    max-width: 900px;
}

.hero-content h1 {
    font-size: clamp(3rem, 10vw, 6rem);
    margin-bottom: 1rem;
    line-height: 1;
    text-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

.hero-content p {
    font-size: clamp(1rem, 3vw, 1.5rem);
    letter-spacing: 4px;
    text-transform: uppercase;
    opacity: 0.9;
    margin-bottom: 2rem;
    font-weight: 500;
}

/* --- Scroll Indicator --- */
.scroll-indicator {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
}

.scroll-indicator span {
    width: 30px;
    height: 50px;
    border: 2px solid rgba(255, 255, 255, 0.5);
    border-radius: 25px;
    display: block;
    position: relative;
}

.scroll-indicator span::before {
    content: '';
    width: 6px;
    height: 6px;
    background: white;
    position: absolute;
    top: 10px;
    left: 50%;
    transform: translateX(-50%);
    border-radius: 50%;
    animation: scroll-anim 2s infinite;
}

@keyframes scroll-anim {
    0% { opacity: 0; top: 10px; }
    50% { opacity: 1; top: 25px; }
    100% { opacity: 0; top: 35px; }
}

/* --- Reveal System --- */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: var(--transition-smooth);
}

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

/* --- Sections --- */
section {
    padding: clamp(4rem, 10vh, 8rem) 5%;
}

.section-title {
    font-size: clamp(2rem, 5vw, 3.5rem);
    color: var(--primary-burgos);
    margin-bottom: 3rem;
    text-align: center;
}

section:not(.full-width) {
    max-width: 1400px;
    margin: 0 auto;
}

/* --- Calculator --- */
.calc-card {
    background: white;
    border-radius: 30px;
    padding: clamp(2rem, 5vw, 4rem);
    box-shadow: var(--shadow-premium);
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
}

@media (max-width: 968px) {
    .calc-card { grid-template-columns: 1fr; gap: 2rem; }
}

.calc-inputs {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.input-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.8rem;
    color: var(--primary-burgos);
}

.input-group input, .input-group select {
    width: 100%;
    padding: 1rem;
    border-radius: 12px;
    border: 2px solid #eee;
    font-family: var(--font-body);
    font-size: 1rem;
    transition: border-color 0.3s;
}

.input-group input:focus {
    border-color: var(--secondary-rust);
    outline: none;
}

.calc-result {
    background: #fdfaf5;
    border-radius: 20px;
    padding: 2.5rem;
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.price-display {
    font-size: 4rem;
    font-weight: 900;
    color: var(--secondary-rust);
    font-family: var(--font-heading);
}

.price-unit {
    font-size: 1.2rem;
    color: var(--text-muted);
}

/* --- Gallery Track --- */
.gallery-wrapper {
    height: 300vh;
    position: relative;
    background: var(--primary-burgos);
}

.gallery-sticky {
    position: sticky;
    top: 0;
    height: 100vh;
    overflow: hidden;
    display: flex;
    align-items: center;
}

.gallery-track {
    display: flex;
    gap: 2rem;
    padding: 0 5%;
}

.gallery-item {
    min-width: clamp(300px, 60vw, 800px);
    height: clamp(250px, 60vh, 600px);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 30px 60px rgba(0,0,0,0.3);
}

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

/* --- Amenity Cards --- */
.amenities-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.amenity-card {
    background: white;
    padding: 3rem 2rem;
    border-radius: 24px;
    text-align: center;
    transition: var(--transition-smooth);
    border: 1px solid rgba(0,0,0,0.03);
}

.amenity-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-premium);
}

/* --- Buttons --- */
.btn-premium {
    padding: 1.2rem 2.5rem;
    background: var(--primary-burgos);
    color: white !important;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.85rem;
    display: inline-block;
    transition: var(--transition-smooth);
    border: none;
    cursor: pointer;
}

.btn-premium:hover {
    background: var(--secondary-rust);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(210, 105, 30, 0.2);
}

#butterfly-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 999;
}

/* --- Contact Section --- */
.contact-container {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 4rem;
    background: white;
    border-radius: 30px;
    overflow: hidden;
    box-shadow: var(--shadow-premium);
}

@media (max-width: 968px) {
    .contact-container { grid-template-columns: 1fr; gap: 0; }
}

.contact-map {
    width: 100%;
    height: 100%;
    min-height: 450px;
}

.contact-info {
    padding: clamp(2rem, 5vw, 4rem);
    display: flex;
    flex-direction: column;
    gap: 2.5rem;
}

.info-item {
    display: flex;
    gap: 1.5rem;
    align-items: flex-start;
}

.info-item .icon {
    font-size: 2rem;
    background: #fdfaf5;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 15px;
    flex-shrink: 0;
}

.info-item h3 {
    font-size: 1.2rem;
    margin-bottom: 0.3rem;
    color: var(--primary-burgos);
}

.info-item p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

.phone-number {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--secondary-rust);
    text-decoration: none;
    display: block;
    margin-top: 0.5rem;
    transition: var(--transition-smooth);
}

.phone-number:hover {
    letter-spacing: 1px;
}

.text-link {
    color: var(--primary-burgos);
    font-weight: 600;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    text-decoration: underline;
    margin-top: 0.5rem;
    display: inline-block;
}

/* --- Footer --- */
footer {
    background: var(--primary-burgos);
    color: white;
    padding: 6rem 5% 2rem;
}

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

@media (max-width: 480px) {
    .hero-content h1 { font-size: 2.5rem; }
    .section-title { font-size: 1.8rem; }
    .price-display { font-size: 3rem; }
    section { padding: 4rem 5%; }
}
