/* 🌐 RESET Y BASE */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    outline: none;
    -webkit-tap-highlight-color: transparent;
}

html,
body {
    width: 100%;
    min-height: 100%;
    margin: 1;
    padding: 1;
    font-family: "Segoe UI", sans-serif;
    scroll-behavior: smooth;
    overflow-x: hidden;
    background-size: cover;
    background-attachment: fixed;
}

/* 🎩 CHAPA */
.chapa {
    position: fixed;
    top: 10px;
    left: 8px;
    width: clamp(300px, 38vw, 350px);
    z-index: 1001;
    pointer-events: none;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.4));
    transition: opacity 0.4s ease;
}
.chapa img {
    width: 100%;
    border-radius: 6px;
}

body.active .chapa {
    opacity: 0;
    pointer-events: none;
    visibility: hidden;
}
.chapa.hidden,

/* 🍔 MENÚ */
.hamburguesa {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 30px;
    height: 25px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    cursor: pointer;
    z-index: 1000;
}
.hamburguesa div {
    background: #c18513;
    height: 4px;
    box-shadow: 0 0 40px #cccccc;
    border-radius: 5px;
    transition: 0.3s ease;
    filter: brightness(1.2) drop-shadow(0 0 6px gold);
    transform: scale(1.05);
}

.hamburguesa.active div {
    box-shadow: 0 0 40px #cccccc;
}
.hamburguesa.active div:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}
.hamburguesa.active div:nth-child(2) {
    opacity: 0;
}
.hamburguesa.active div:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

.menu-lateral {
    position: fixed;
    top: 0;
    right: -250px;
    width: 250px;
    height: 100%;
    background: url("../img/menu.jpg") no-repeat center center/cover;
    box-shadow: -2px 0 10px rgba(0, 0, 0, 0.1);
    padding-top: 70px;
    z-index: 998;
    transition: right 0.4s ease;
    border-radius: 10px;
}
.menu-lateral.active {
    right: 0;
}
.menu-lateral ul {
    margin-top: 10px;
    list-style: none;
    padding: 4px;
}
.menu-lateral ul li {
    text-align: center;
    margin: 40px 0;
}

.menu-lateral ul li a {
    font-size: 20px;
}

.menu-legal {
    position: absolute;
    bottom: 45px;
    width: 100%;
    text-align: center;
    font-size: 0.75rem;
    padding: 10px;
}

/* 🏛️ HERO */
.hero {
    padding-top: 80px;
}
.title h2 {
    font-size: 1.8rem;
    text-align: left;
}
.hero .descripcion {
    margin-top: 1rem;
    text-align: justify;
    line-height: 1.6;
}
.logo-fundacion {
    margin-left: 50px;
    width: 200px;
    max-width: 80vw;
    margin-top: 10px;
    border-radius: 60%;
    justify-content: center;
    align-items: center;
    filter: drop-shadow(0 8px 10px rgba(0, 0, 0, 0.4));
}

/* 🎨 GALERÍA */
.section {
    padding: 40px 20px;
}
.section_title {
    font-size: 1.5rem;
    margin-bottom: 15px;
    text-align: left;
}

button {
    border: none;
    padding: 10px 15px;
    border-radius: 3px;
    cursor: pointer;
    margin: 5px;
}
button:hover {
    background: #444;
}
.vitrina {
    overflow-x: auto;
}
.shelf__track {
    display: flex;
    gap: 16px;
    scroll-snap-type: x mandatory;
    overflow-x: auto;
    padding: 10px 0;
}

/* 🎥 REELS */

.reel-container {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    gap: 20px;
    padding: 20px;
    background: #000;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
}

.reel-item {
    flex: 0 0 100%;
    max-width: 390px;
    aspect-ratio: 9 / 16;
    border-radius: 16px;
    overflow: hidden;
    position: relative;
    scroll-snap-align: center;
    background: #000;
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.08);
    margin: 0 auto;
}

.reel-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    pointer-events: none;
}

.reel-video {
    pointer-events: auto;
    touch-action: manipulation;
}

/* 📞 FOOTER */
footer {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 3rem 1rem;
    min-height: 350px;
    text-align: center;
}

.footer-columnas {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: stretch;
    gap: 2rem;
    width: 100%;
    max-width: 800px;
    margin: 3rem auto 2rem auto;
    text-align: center;
    padding: 1rem;
}

.footer-columnas .contacto,
.footer-columnas .apoya {
    flex: 1 1 250px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    min-height: 220px;
}

.footer-columnas h2 {
    font-size: 1.7rem;
    margin-bottom: 1rem;
    font-weight: bold;
}

.footer-columnas a {
    margin: 0.3rem 0;
    font-size: 1.1rem;
    text-decoration: none;
}

/* Responsivo perfecto en móviles */
@media (max-width: 600px) {
    .footer-columnas {
        gap: 1rem;
        padding: 0.5rem;
    }

    .footer-columnas .contacto,
    .footer-columnas .apoya {
        flex: 1 1 45%;
    }
}

.footer-columnas h2 {
    font-size: 1.7rem;
    margin-bottom: 1rem;
    font-weight: bold;
}

.footer-columnas a {
    margin: 0.3rem 0;
    font-size: 1.1rem;
    text-decoration: none;
}

@media (max-width: 600px) {
    .footer-columnas {
        flex-direction: row;
        justify-content: space-evenly;
        text-align: center;
    }
}

.foot-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.foot-list li {
    margin-bottom: 10px;
}

.foot-list li a {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 500;
    text-decoration: none;
    transition: 0.3s;
}

.foot-list li a:hover {
    outline: none;
    box-shadow: none;
    transform: scale(0.9);
}

.foot-list li img {
    width: 35px;
    height: 35px;
    object-fit: contain;
}

/* FOOTER LEGAL */
.footer-legal {
    margin-top: 2rem;
    text-align: center;
    font-size: 0.85rem;
    color: #ccc;
    width: 100%;
}

/* ☝️ FAB */
#fab {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    font-size: 2.5rem;
    cursor: pointer;
    background: none;
    z-index: 999;
    animation: heartbeat 1s infinite ease-in-out;
}
@keyframes heartbeat {
    0%,
    100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}
#fab:active {
    transform: scale(0.85);
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.3);
}
#fab-msg {
    position: fixed;
    bottom: 2.3rem;
    right: 5.8rem;
    font-size: 1.1rem;
    font-weight: bold;
    color: #28a745;
    background: transparent;
    opacity: 0;
    pointer-events: none;
    transform: scale(0.9);
    z-index: 998;
}
#fab-msg.show {
    animation:
        fadeInUp 0.6s ease forwards,
        msgBeat 2s infinite ease-in-out;
}
#fab-msg.hide {
    animation: fadeOutDown 0.4s ease forwards;
}
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(10px) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}
@keyframes fadeOutDown {
    from {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
    to {
        opacity: 0;
        transform: translateY(10px) scale(0.9);
    }
}
@keyframes msgBeat {
    0%,
    100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

/* 📱 RESPONSIVE */
@media (max-width: 768px) {
    .title h2 {
        font-size: 1.5rem;
    }
    .logo-fundacion {
        width: 250px;
        justify-content: center;
    }
    .footer-columnas {
        grid-template-columns: 1fr;
        align-items: center;
    }
    body {
        word-spacing: normal;
        white-space: normal;
    }
}

/* ✨ TEXTURAS Y DETALLES */
.menu-legal,
.menu-lateral ul li a,
.modal-museo .modal-museo-content,
.cerrar-modal,
.obra-titulo,
.texto-boton,
.section_title,
.title h2,
.descripcion,
.foot-list li a {
    background-image: url("../img/texturas/letras.jpg");
    background-size: cover;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    -webkit-text-fill-color: transparent;
}

/* 🎯 ESPACIADO FINAL */
section {
    padding: 20px 16px;
    margin: 0 auto;
}

.descripcion {
    width: 100%;
    padding: 1rem 1rem;
    font-size: 1.15rem;
    text-align: left;
    line-height: 1.5;
    font-family: "Segoe UI", sans-serif;
}

.logo-vitrina-inicial {
    display: flex;
    justify-content: center;
    overflow: hidden;
    align-items: center;
}

.logo-vitrina-inicial img {
    border-radius: 20px;
    width: 200px;
    height: 200px;
    object-fit: cover;
}

.obra-item {
    text-align: center;
    margin: 1rem;
}

.obra-item img {
    width: 200px;
    border-radius: 8px;
}

.reel-item {
    margin: 1rem;
    text-align: center;
}

.reel-item video {
    border-radius: 8px;
    box-shadow: 0 0 10px #000;
}

.galeria-selector {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    flex-wrap: nowrap;
    flex-direction: row;
    margin: 1rem auto;
    overflow-x: auto;
}

.boton-galeria-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 0;
    text-align: center;
    border: none;
    position: relative;
    width: auto;
    height: 74px;
    overflow: hidden;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
    min-width: auto;
    min-height: auto;
    filter: brightness(0.8);
    transform: scale(1);
}

.boton-galeria-wrapper.activo {
    transform: scale(0.9);
    filter: drop-shadow(0 0 3px gold);
    border-radius: 5px;
    transition: all 0.3s ease-in-out;
}

@media (min-width: 768px) {
    .boton-galeria-wrapper {
        transform: scale(1.3);
    }
}

.boton-galeria {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    pointer-events: none;
    border: none;
}

.texto-boton {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-weight: bold;
    font-size: 1rem;
    text-align: center;
    line-height: 0.9;
    padding: 1 10px;
    white-space: nowrap;
    word-break: break-word;
    max-width: 90%;
    pointer-events: none;
    justify-content: center;
}

/* 🎞️ Modal museo*/
#modalMuseo {
    position: fixed;
    inset: 0;
    background-size: cover;
    background-position: center;
    backdrop-filter: blur(2px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.5s ease;
}

#modalMuseo.visible {
    opacity: 1;
    pointer-events: auto;
}

#modalMuseoContent {
    padding: 20px;
    border-radius: 20px;
    max-width: 90%;
    max-height: 90%;
    overflow: auto;
    text-align: center;
    animation: fadeIn 0.5s ease;
}

#modalMuseoContent img {
    max-width: 100%;
    height: 100%;
    border-radius: 20px;
}

.cerrar-modal {
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 30px;
    font-weight: bold;
    cursor: pointer;
    z-index: 10000;
    transition: transform 0.3s ease;
}
.cerrar-modal:hover {
    transform: scale(1.2);
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* ✅ Estilo para cada obra en la galería horizontal */
.obra {
    flex: 0 0 auto;
    max-width: 600px;
    text-align: center;
    scroll-snap-align: center;
    padding: 0.5rem;
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.08);
    border-radius: 10px;
}

.obra img {
    width: 100%;
    height: 100%;
    max-height: 250px;
    object-fit: cover;
    border-radius: 10px;
}

.obra-titulo {
    margin-top: 0.6rem;
    font-size: 1rem;
    font-weight: bold;
    text-align: center;
}

/* Responsivo para pantallas pequeñas */
@media (max-width: 600px) {
    .obra {
        max-width: 200px;
    }
}

.shelf__track {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    gap: 1rem;
    padding: 1rem;
}
