/* ==========================================
   POSADA CABROJO - styles.css
   Diseño por modelatic.com
   ========================================== */

:root {
    --primary: #2D5016;
    --primary-light: #4A7C2E;
    --primary-dark: #1A3009;
    --accent: #C8A961;
    --accent-light: #E8D5A3;
    --cream: #FDF8F0;
    --warm-white: #FEFCF7;
    --text-dark: #2C2C2C;
    --text-medium: #555555;
    --text-light: #888888;
    --shadow-sm: 0 2px 8px rgba(0,0,0,0.06);
    --shadow-md: 0 8px 30px rgba(0,0,0,0.1);
    --shadow-lg: 0 20px 60px rgba(0,0,0,0.15);
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --radius-xl: 32px;
}

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

body {
    font-family: 'Inter', sans-serif;
    color: var(--text-dark);
    background: var(--warm-white);
    overflow-x: hidden;
    line-height: 1.6;
}

h1, h2, h3, h4, h5 {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    line-height: 1.2;
}

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

/* ===== NAVBAR ===== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 1rem 2rem;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.navbar.scrolled {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 0.6rem 2rem;
    box-shadow: 0 4px 30px rgba(0,0,0,0.08);
}

.navbar-inner {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nav-logo img {
    height: 55px;
    transition: all 0.3s ease;
    filter: brightness(0) invert(1);
}

.navbar.scrolled .nav-logo img {
    filter: none;
    height: 45px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 2rem;
    list-style: none;
}

.nav-links a {
    text-decoration: none;
    color: white;
    font-weight: 500;
    font-size: 0.95rem;
    position: relative;
    padding: 0.5rem 0;
    transition: color 0.3s ease;
}

.navbar.scrolled .nav-links a { color: var(--text-dark); }

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

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

.nav-cta {
    background: var(--accent) !important;
    color: white !important;
    padding: 0.7rem 1.5rem !important;
    border-radius: 50px;
    font-weight: 600 !important;
    transition: all 0.3s ease !important;
}

.nav-cta:hover {
    background: var(--primary) !important;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(45, 80, 22, 0.3);
}

.nav-cta::after { display: none !important; }

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

.navbar.scrolled .mobile-toggle { color: var(--text-dark); }

/* ===== HERO ===== */
.hero {
    position: relative;
    height: 100vh;
    min-height: 700px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('assets/images/posada-cabrojo-intro.jpg') center/cover no-repeat;
    transform: scale(1.1);
    transition: transform 0.5s ease;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, rgba(26, 48, 9, 0.4) 0%, rgba(26, 48, 9, 0.6) 50%, rgba(26, 48, 9, 0.8) 100%);
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    color: white;
    padding: 0 2rem;
    max-width: 900px;
}

.hero-badge {
    display: inline-block;
    background: rgba(255,255,255,0.15);
    backdrop-filter: blur(10px);
    padding: 0.5rem 1.5rem;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 500;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 1.5rem;
    border: 1px solid rgba(255,255,255,0.2);
    opacity: 0;
    animation: fadeInUp 1s ease forwards 0.3s;
}

.hero h1 {
    font-size: clamp(2.5rem, 7vw, 5rem);
    margin-bottom: 1rem;
    opacity: 0;
    animation: fadeInUp 1s ease forwards 0.5s;
    text-shadow: 0 4px 30px rgba(0,0,0,0.3);
}

.hero h1 span {
    font-style: italic;
    color: var(--accent-light);
}

.hero-subtitle {
    font-size: clamp(1rem, 2.5vw, 1.3rem);
    font-weight: 300;
    margin-bottom: 2.5rem;
    opacity: 0;
    animation: fadeInUp 1s ease forwards 0.7s;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    opacity: 0;
    animation: fadeInUp 1s ease forwards 0.9s;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 2rem;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1rem;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    border: none;
}

.btn-primary {
    background: var(--accent);
    color: white;
    box-shadow: 0 8px 25px rgba(200, 169, 97, 0.4);
}

.btn-primary:hover {
    background: #D4B56A;
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(200, 169, 97, 0.5);
}

.btn-outline {
    background: transparent;
    color: white;
    border: 2px solid rgba(255,255,255,0.6);
}

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

.hero-scroll {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
    color: white;
    font-size: 0.85rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    opacity: 0;
    animation: fadeIn 1s ease forwards 1.5s;
}

.hero-scroll .mouse {
    width: 24px;
    height: 38px;
    border: 2px solid white;
    border-radius: 12px;
    position: relative;
}

.hero-scroll .mouse::after {
    content: '';
    position: absolute;
    top: 6px;
    left: 50%;
    transform: translateX(-50%);
    width: 3px;
    height: 8px;
    background: white;
    border-radius: 2px;
    animation: scrollWheel 2s infinite;
}

/* ===== SECTIONS GENERAL ===== */
.section { padding: 6rem 2rem; }
.section-container { max-width: 1200px; margin: 0 auto; }

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-tag {
    display: inline-block;
    color: var(--accent);
    font-weight: 600;
    font-size: 0.85rem;
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-bottom: 1rem;
}

.section-title {
    font-size: clamp(2rem, 4vw, 3rem);
    color: var(--text-dark);
    margin-bottom: 1rem;
}

.section-title span {
    font-style: italic;
    color: var(--primary);
}

.section-desc {
    max-width: 600px;
    margin: 0 auto;
    color: var(--text-medium);
    font-size: 1.1rem;
}

/* ===== ABOUT ===== */
.about { background: var(--cream); }

.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.about-image { position: relative; }

.about-image img {
    width: 100%;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
}

.about-image-accent {
    position: absolute;
    bottom: -20px;
    right: -20px;
    width: 200px;
    height: 200px;
    border: 4px solid var(--accent);
    border-radius: var(--radius-lg);
    z-index: -1;
}

.about-content h2 {
    font-size: clamp(2rem, 3.5vw, 2.8rem);
    margin-bottom: 1.5rem;
    color: var(--text-dark);
}

.about-content h2 span {
    font-style: italic;
    color: var(--primary);
}

.about-content p {
    color: var(--text-medium);
    margin-bottom: 1.5rem;
    font-size: 1.05rem;
}

.about-stats {
    display: flex;
    gap: 2rem;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(0,0,0,0.1);
}

.stat-item { text-align: center; }

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

.stat-label {
    font-size: 0.85rem;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* ===== SERVICES ===== */
.services {
    background: var(--warm-white);
    position: relative;
}

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

.service-card {
    background: white;
    border-radius: var(--radius-md);
    padding: 2.5rem 2rem;
    text-align: center;
    box-shadow: var(--shadow-sm);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
}

.service-card:hover::before { transform: scaleX(1); }

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

.service-icon {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    color: white;
    font-size: 1.5rem;
    transition: all 0.3s ease;
}

.service-card:hover .service-icon {
    transform: scale(1.1) rotate(5deg);
    background: linear-gradient(135deg, var(--accent), var(--primary));
}

.service-card p {
    color: var(--text-light);
    font-size: 0.95rem;
}

/* ===== ROOMS ===== */
.rooms {
    background: linear-gradient(180deg, var(--cream) 0%, var(--warm-white) 100%);
}

.rooms-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2.5rem;
}

.room-card {
    background: white;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.room-card:hover {
    transform: translateY(-15px);
    box-shadow: 0 30px 80px rgba(0,0,0,0.15);
}

.room-image {
    position: relative;
    height: 250px;
    overflow: hidden;
}

.room-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

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

.room-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: var(--accent);
    color: white;
    padding: 0.4rem 1rem;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 600;
}

.room-content { padding: 2rem; }

.room-content h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--text-dark);
}

.room-features {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.room-feature {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.85rem;
    color: var(--text-medium);
    background: var(--cream);
    padding: 0.4rem 0.8rem;
    border-radius: 50px;
}

.room-feature i {
    color: var(--primary);
    font-size: 0.8rem;
}

.room-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(0,0,0,0.08);
}

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

.room-price .from {
    font-size: 0.8rem;
    color: var(--text-light);
    display: block;
}

.room-price .amount {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary);
}

.room-btn {
    background: var(--primary);
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.room-btn:hover {
    background: var(--accent);
    transform: translateX(3px);
}

/* ===== BOOKING WIDGET ===== */
.booking-widget {
    background: white;
    border-radius: var(--radius-lg);
    padding: 2.5rem;
    box-shadow: var(--shadow-lg);
    max-width: 900px;
    margin: -3rem auto 0;
    position: relative;
    z-index: 10;
    border: 1px solid rgba(0,0,0,0.05);
}

.booking-form {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1.5rem;
    align-items: end;
}

.form-group { display: flex; flex-direction: column; }

.form-group label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-medium);
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-group input, .form-group select {
    padding: 0.9rem 1rem;
    border: 2px solid #eee;
    border-radius: var(--radius-sm);
    font-size: 1rem;
    font-family: inherit;
    transition: border-color 0.3s ease;
    background: var(--warm-white);
}

.form-group input:focus, .form-group select:focus {
    outline: none;
    border-color: var(--accent);
}

.booking-submit {
    background: var(--primary);
    color: white;
    padding: 0.9rem 2rem;
    border: none;
    border-radius: var(--radius-sm);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.booking-submit:hover {
    background: var(--accent);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(200, 169, 97, 0.4);
}

/* ===== GALLERY SECTION ===== */
.gallery-section {
    background: var(--primary-dark);
    color: white;
    padding: 6rem 2rem;
    position: relative;
    overflow: hidden;
}

.gallery-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('assets/images/textbg.jpg') center/cover;
    opacity: 0.1;
}

.gallery-section .section-header {
    position: relative;
    z-index: 2;
}

.gallery-section .section-title { color: white; }
.gallery-section .section-desc { color: rgba(255,255,255,0.7); }

.video-container {
    position: relative;
    z-index: 2;
    max-width: 900px;
    margin: 0 auto;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: 0 30px 80px rgba(0,0,0,0.4);
}

.video-container iframe {
    width: 100%;
    aspect-ratio: 16/9;
    border: none;
    display: block;
}

/* ===== CONTACT ===== */
.contact { background: var(--cream); }

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

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

.contact-item-icon {
    width: 60px;
    height: 60px;
    background: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: var(--primary);
    box-shadow: var(--shadow-sm);
    flex-shrink: 0;
}

.contact-item-text h4 {
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.3rem;
}

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

.contact-item-text a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.contact-item-text a:hover { color: var(--accent); }

.contact-map {
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    min-height: 400px;
}

.contact-map iframe {
    width: 100%;
    height: 100%;
    min-height: 400px;
    border: none;
}

/* ===== FOOTER ===== */
.footer {
    background: var(--primary-dark);
    color: white;
    padding: 4rem 2rem 2rem;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 3rem;
    padding-bottom: 3rem;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.footer-brand img {
    height: 60px;
    margin-bottom: 1rem;
}

.footer-brand p {
    color: rgba(255,255,255,0.7);
    font-size: 0.95rem;
    max-width: 300px;
}

.footer-links h5 {
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    color: var(--accent);
}

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

.footer-links a {
    color: rgba(255,255,255,0.7);
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.footer-links a:hover {
    color: white;
    transform: translateX(5px);
}

.footer-social {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
}

.footer-social a {
    width: 45px;
    height: 45px;
    background: rgba(255,255,255,0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-decoration: none;
    font-size: 1.1rem;
    transition: all 0.3s ease;
}

.footer-social a:hover {
    background: var(--accent);
    transform: translateY(-3px);
}

.footer-bottom {
    max-width: 1200px;
    margin: 0 auto;
    padding-top: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-bottom p {
    color: rgba(255,255,255,0.5);
    font-size: 0.85rem;
}

.footer-bottom a:hover {
    color: white !important;
}

/* ===== WHATSAPP FLOAT ===== */
.whatsapp-float {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 60px;
    height: 60px;
    background: #25D366;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.8rem;
    text-decoration: none;
    box-shadow: 0 8px 25px rgba(37, 211, 102, 0.4);
    z-index: 999;
    transition: all 0.3s ease;
    animation: pulse 2s infinite;
}

.whatsapp-float:hover {
    transform: scale(1.1);
    box-shadow: 0 12px 35px rgba(37, 211, 102, 0.6);
}

/* ===== ANIMATIONS ===== */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes scrollWheel {
    0% { transform: translateX(-50%) translateY(0); opacity: 1; }
    100% { transform: translateX(-50%) translateY(10px); opacity: 0; }
}

@keyframes pulse {
    0%, 100% { box-shadow: 0 8px 25px rgba(37, 211, 102, 0.4); }
    50% { box-shadow: 0 8px 25px rgba(37, 211, 102, 0.7), 0 0 0 10px rgba(37, 211, 102, 0.1); }
}

.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

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

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
    .about-grid, .contact-grid { grid-template-columns: 1fr; }
    .footer-content { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        max-width: 350px;
        height: 100vh;
        background: white;
        flex-direction: column;
        align-items: flex-start;
        padding: 5rem 2rem 2rem;
        gap: 1.5rem;
        transition: right 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        box-shadow: -10px 0 30px rgba(0,0,0,0.1);
    }

    .nav-links.active { right: 0; }

    .nav-links a {
        color: var(--text-dark) !important;
        font-size: 1.1rem;
    }

    .mobile-toggle { display: block; }
    .hero h1 { font-size: 2.5rem; }

    .booking-widget {
        margin-top: 0;
        padding: 1.5rem;
        border-radius: var(--radius-md);
    }

    .booking-form { grid-template-columns: 1fr; }
    .rooms-grid { grid-template-columns: 1fr; }
    .footer-content { grid-template-columns: 1fr; }
    .footer-bottom { flex-direction: column; text-align: center; }
    .section { padding: 4rem 1.5rem; }
    .about-stats { gap: 1rem; }
    .stat-number { font-size: 1.8rem; }
}

.nav-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 998;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.nav-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* ===== ACCESSIBILITY ===== */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}


.nav-logo img,
.footer-brand img {
    height: 55px;
    width: auto;
    object-fit: contain;
    aspect-ratio: auto;
}

.navbar.scrolled .nav-logo img {
    height: 45px;
}

.footer-brand img {
    height: 60px;
}

