/* GLOBAL */
.video-bg-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: 0;
}

.video-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* Default overlay, specific pages might override or use inline styles if different */
    background: linear-gradient(to bottom, rgba(35, 15, 18, 0.4) 0%, rgba(35, 15, 18, 0.1) 50%, rgba(35, 15, 18, 0.6) 100%);
    z-index: 1;
}

/* NAVIGATION */
.glass-nav {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.05);
    transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

/* NAV SCROLLED */
.header-scrolled .glass-nav,
.nav-force-light .glass-nav {
    background: rgba(252, 248, 246, 0.6);
    /* Sutil tinte Chukum */
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border: 1px solid rgba(212, 175, 55, 0.2);
    /* Borde oro Izamal muy sutil */
    box-shadow: 0 20px 40px -15px rgba(29, 12, 15, 0.15);
}

/* NAV PADDING */
.header-scrolled .glass-nav {
    padding-top: 0.75rem;
    padding-bottom: 0.75rem;
}

.header-scrolled .glass-nav a,
.nav-force-light .glass-nav a {
    color: #332a2c !important;
    /* Gris carbón suave */
    font-size: 0.8rem;
    letter-spacing: 0.05em;
}

.header-scrolled .glass-nav a:hover,
.nav-force-light .glass-nav a:hover {
    color: #ff6680 !important;
}

/* LOGO LOGIC */
.logo-dark {
    display: none;
}

.header-scrolled .logo-white,
.nav-force-light .logo-white {
    display: none !important;
}

.header-scrolled .logo-dark,
.nav-force-light .logo-dark {
    display: block !important;
    height: 1.75rem;
    /* Pequeño al hacer scroll */
    transition: all 0.6s ease;
}

/* En caso de que nav-force-light esté activo pero NO scrolled, mantener logo grande */
.nav-force-light:not(.header-scrolled) .logo-dark {
    height: 2.5rem;
    /* Equivale a h-10 */
}

.header-scrolled .md\:hidden.text-white,
.nav-force-light .md\:hidden.text-white {
    color: #332a2c !important;
}

@media (prefers-color-scheme: dark) {
    .glass-nav {
        /* background: rgba(35, 15, 18, 0.9); */
        /* Optional dark mode specific override if needed */
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }
}

/* ANIMATIONS */
.fade-in-up {
    animation: fadeInUp 1.2s ease-out forwards;
    opacity: 0;
    transform: translateY(20px);
}

.delay-200 {
    animation-delay: 0.2s;
}

.delay-400 {
    animation-delay: 0.4s;
}

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* TEXT UTILS */
.text-justify-last-center {
    text-align-last: center;
}

/* SCROLLBAR */
.no-scrollbar::-webkit-scrollbar {
    display: none;
}

.no-scrollbar {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

/* PAGE SPECIFIC */

/* LINEN BACKGROUND */
.linen-bg {
    background-color: #f8f5f6;
    background-image: url(https://www.transparenttextures.com/patterns/linen.png);
}

/* TIMELINE */
.timeline-line {
    position: absolute;
    left: 20px;
    top: 0;
    bottom: 50px;
    /* Stop before the bottom button area */
    width: 2px;
    background-color: #d4af37;
    z-index: 0;
}

@media (min-width: 768px) {
    .timeline-line {
        left: 50%;
        transform: translateX(-50%);
        bottom: 100px;
        /* Adjust bottom for desktop */
    }
}

/* Gallery and other styles */
#gallery-modal {
    backdrop-filter: blur(10px);
}

/* RADIO CARD */
.radio-card:checked+div {
    border-color: #6fb1c8;
    background-color: rgba(111, 177, 200, 0.05);
}

.radio-card:checked+div .check-icon {
    opacity: 1;
    transform: scale(1);
}

/* ARTICLE CARD */
.article-card:hover .article-image {
    transform: scale(1.05);
}

/* CHUKUM BACKGROUND */
.chukum-bg {
    background-color: #fcf9f6;
    background-image: url(https://lh3.googleusercontent.com/aida-public/AB6AXuB_ujlAflIk3YJUgbd6AlpvGwvN2cCxqfZDmuiw0R8SrSbWAlM4dNckV1vbDidKqfiFiIX3aghAjl4kVJZ8JQo9cLJ14VMMpp2XQBodu9kB7e96yoOdTcq2pIdi0SFF5wWxuHwh95be-EN1u5_Q-w-JvNeUxe4e1Dcah006LGDzfx8GdSL78uQjW8XtauZjI00DtkahZVyYMMAyco6SBSwqNA28vbTP0fMASLwWGQCfzmmNV0ZOJuOrRJkjMw61AG0XxuF4SQSeWAI_);
}

/* MAP & FORMS */
.map-container {
    filter: grayscale(100%) invert(10%) sepia(20%) hue-rotate(320deg) saturate(150%);
    transition: filter 0.5s ease;
}

.map-container:hover {
    filter: grayscale(0%);
}

.form-input {
    background-color: transparent;
    border-bottom-width: 1px;
    border-color: rgba(29, 12, 15, 0.2);
    transition: border-color 0.3s ease;
}

.form-input:focus {
    outline: none;
    border-color: #d4af37;
    box-shadow: none;
}

/* LEGAL CONTENT */
.legal-content h2 {
    font-family: 'Noto Serif', serif;
    font-weight: 600;
    font-size: 1.5rem;
    color: #1d0c0f;
    margin-top: 2.5rem;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #e5e7eb;
}

.legal-content h3 {
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
    font-size: 1.125rem;
    color: #4a4a4a;
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
}

.legal-content p,
.legal-content li {
    font-family: 'Montserrat', sans-serif;
    font-weight: 400;
    font-size: 1rem;
    line-height: 1.75;
    color: inherit;
    margin-bottom: 1rem;
}

.legal-content ul {
    list-style-type: disc;
    padding-left: 1.5rem;
    margin-bottom: 1.5rem;
}

.sidebar-link.active {
    color: #d4af37;
    border-left-color: #d4af37;
    font-weight: 500;
    background-color: rgba(212, 175, 55, 0.05);
}

html {
    scroll-behavior: smooth;
}

/* Spin animation for decorative elements */
@keyframes spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

/* Mobile Menu */
#mobile-menu {
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

#mobile-menu.open {
    display: flex;
}