   VARIABLES — SE MANTIENEN TUS COLORES
========================================================= */

:root {
    --purple: #892be2;
    --purple-light: #a855f7;

    --pink: #ff00aa;
    --pink-light: #ff59c7;

    --gradient: linear-gradient(110deg, #892be2c8 0%, #ff00aaa0 100%);

    --gold: #d4af37;
    --gold-light: #e8c58e;
    --gold-soft: #f3d8b1;

    --white: #ffffff;
    --glass: rgba(255, 255, 255, 0.78);
    --glass-strong: rgba(255, 255, 255, 0.90);
    --dark: #18121c;
    --text: #27212b;
    --muted: #6d6472;

    --radius: 30px;
    --shadow: 0 20px 60px rgba(57, 0, 80, .18);
    --glow: 0 0 35px rgba(255, 255, 255, .55);

    /* Nav — antes se peleaban varias media queries por estos valores.
       Ahora es fluido: escala solo con el ancho de pantalla. */
    --nav-height: clamp(40px, 6vw, 50px);
    --menu-font: clamp(9px, 1.6vw, 20px);
}


/* =========================================================
   RESET GLOBAL
========================================================= */

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

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
    width: 100%;
    height: 100dvh;
    background-image: url(../IMG/FONDOS.jpg);
    background-size: cover;
	background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
}

body {
    width: 100%;
    min-width: 0;
    min-height: 100%;   /* fallback navegadores antiguos */
    height: 100dvh;      /* altura dinámica en móviles */
    background: none;
    overflow-x: hidden;
    color: var(--text);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    .menu-item,
    .menu-text,
    .menu-item::before,
    .menu-indicator,
    .card,
    .card__image img {
        transition: none !important;
    }
}


/* =========================================================
   TIPOGRAFÍAS
========================================================= */

.aladin-regular {
    font-family: "Aladin", system-ui;
    font-weight: 400;
    font-style: normal;
}


/* =========================================================
   IMÁGENES / MEDIA
========================================================= */

img,
video,
iframe {
    max-width: 100%;
}

img {
    height: auto;
}


/* =========================================================
   HEADER GENERAL
========================================================= */

header {
    width: 100%;
    min-width: 0;
    height: var(--nav-height);
}


/* =========================================================
   NAV
========================================================= */
.bottom-menu {
    position: static;
    width: 100%;
    height: 50px;
    display: flex;
    flex-direction: row;
    align-items: center;
    padding: 0 30px;
    box-sizing: border-box;
 
    background: linear-gradient(
        135deg,
        #3d1b61 100%     /* lila oscuro/violeta profundo */
        #c0b8d8 25%,     /* plata-lila */
        #9b7fc7 50%,     /* lila medio */
        #6b3fb0 75%,     /* lila intenso */
        #3d1b61 100%     /* lila oscuro/violeta profundo */
    );
 
    border: 1px solid rgba(212, 175, 55, 0.28);
    border-bottom: 1px solid rgba(212, 175, 55, 0.85);
 
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
 
    box-shadow:
        0 10px 40px rgba(0, 0, 0, 0.45),
        0 -1px 8px rgba(212, 175, 55, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.04);
 
    overflow: visible;
}
 
/* =========================================================
   ELEMENTOS DEL NAV
========================================================= */
.menu-item {
    position: relative;
    z-index: 101;
    flex: 1 1 0;
    min-width: 0;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(245, 235, 241, 0.78);
    text-decoration: none;
    font-family: "Edu TAS Beginner", cursive;
    font-size: clamp(13px, 1.6vw, 20px);
    cursor: pointer;
    padding: 0 clamp(4px, 1vw, 12px);
    transition:
        color 0.3s ease,
        background 0.35s ease,
        text-shadow 0.3s ease;
}
 
/* =========================================================
   TEXTO NAV
========================================================= */
.menu-text {
    position: relative;
    z-index: 2;
    display: block;
    visibility: visible;
    opacity: 1;
    transform: none;
    width: auto;
    height: auto;
    margin: 0;
    padding: 0;
    text-align: center;
    white-space: nowrap;
    pointer-events: none;
    color: inherit;
    font-family: inherit;
    font-size: inherit;
	font-weight: bold;
    transition:
        color 0.3s ease,
        text-shadow 0.3s ease;
    line-height: 1.1;
}
 
/* =========================================================
   ORNAMENTO (solo hover)
========================================================= */
.menu-item::before {
    content: "༺───༻";
    position: absolute;
    z-index: 1;
    top: 25px;
    transform: translate(-50%, 8px);
    color: #d6b477;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 20px;
    font-weight: normal;
    letter-spacing: 0.5px;
    white-space: nowrap;
    line-height: 1;
    opacity: 0;
    pointer-events: none;
    transition:
        opacity 0.4s ease,
        transform 0.4s cubic-bezier(.22, 1, .36, 1);
}
 
/* =========================================================
   HOVER
========================================================= */
.menu-item:hover {
    color: #f3d8b1;
    text-shadow: 0 0 6px rgba(243, 216, 177, 0.22);
    background: linear-gradient(
        135deg,
        #7a5c1e 0%,
        #d4af37 15%,
        #fff6d5 25%,
        #ffffff 32%,
        #fff6d5 40%,
        #d4af37 50%,
        #a67c1e 62%,
        #f9e08c 75%,
        #b8860b 88%,
        #7a5c1e 100%
    );
    background-size: 300% 300%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
    animation: shine 4s linear infinite;
}
  
@keyframes shine {
  0%   { background-position: 0% 50%; }
  50%  { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

.menu-item:hover .menu-text {
    color: #f3d8b1;
    text-shadow:
        0 0 5px rgba(232, 197, 142, 0.25),
        0 0 12px rgba(232, 197, 142, 0.08);
}
 
/* =========================================================
   SEPARADORES
========================================================= */
.menu-item:nth-child(1)::after,
.menu-item:nth-child(2)::after,
.menu-item:nth-child(3)::after {
    content: "";
    position: absolute;
    right: 0;
    top: 50%;
    width: 1px;
    height: 34px;
    transform: translateY(-50%);
    background: rgba(212, 175, 55, 0.85);
    pointer-events: none;
}
 
/* =========================================================
   ACTIVO
========================================================= */
.menu-item.active {
    color: rgba(255, 245, 250, 0.95);
    text-shadow: 0 0 8px rgba(232, 197, 142, 0.12);
}
 
/* =========================================================
   INDICADOR
========================================================= */
.menu-indicator {
    position: absolute;
    z-index: 3;
    left: 50%;
    bottom: 0;
    width: 48px;
    height: 2px;
    transform: translateX(-50%);
    color: transparent;
    background-color: #cca638;
    background-image:
        radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0.2) 0%, transparent 80%),
        linear-gradient(135deg,
            #996515 0%,
            #d4af37 20%,
            #fff3a8 40%,
            #aa771c 55%,
            #ffe875 70%,
            #8c6218 85%,
            #e6ca65 100%
        );
    background-blend-mode: overlay;
    background-size: cover;
    -webkit-background-clip: text;
    background-clip: text;
    text-shadow: 0 0 6px rgba(243, 216, 177, 0.22);
    pointer-events: none;
    opacity: 0;
    transition:
        opacity 0.3s ease,
        background 0.3s ease,
        width 0.35s ease;
}
 
/* =========================================================
   SEGURIDAD TEXTO
========================================================= */
.bottom-menu .menu-text,
.bottom-menu .menu-item .menu-text {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    transform: none !important;
}
 
.bottom-menu,
.menu-item,
.menu-icon,
.menu-text,
.menu-indicator {
    box-sizing: border-box;
}


/* =========================================================
   GRID PRINCIPAL: FOTO IZQUIERDA / TEXTO DERECHA
========================================================= */

.espectaculo-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.5fr) minmax(0, 2fr);
    gap: clamp(8px, 2vw, 16px);
    align-items: start;      /* CAMBIO: ya no "stretch" */
}

.espectaculo-media {
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.espectaculo-media img {
    width: 100%;
    height: 100%;             /* CAMBIO: ya no 97% */
    max-height: 100vh;         /* CAMBIO: límite razonable, ajusta a tu gusto */
    display: block;
    border-radius: 10px;
    object-fit: cover;
}

.espectaculo-texto {
    position: relative;
    min-width: 0;
    height: auto;             /* CAMBIO: crece según su contenido */
    width: 100%;
    box-sizing: border-box;

    display: flex;
    flex-direction: column;

    padding: clamp(0.8em, 2vw, 1.2em) clamp(1em, 3vw, 1.5em);

    border: 1px solid var(--gold);
    border-radius: 6px;

    box-shadow:
        0 0 0 4px rgba(212, 175, 55, 0.08),
        inset 0 0 12px rgba(212, 175, 55, 0.12);

    overflow: visible;        /* CAMBIO: nada se recorta nunca */
}

.espectaculo-texto p {
    margin: 0 0 0.6em;
    color: white;
    font-family: "Edu TAS Beginner", cursive;
    font-size: clamp(1rem, 1.6vw, 1.3rem);
    line-height: 1.4;
    text-align: justify;
    hyphens: auto;
}

.espectaculo-botones {
    margin-top: 1em;          /* CAMBIO: separación fija respecto al texto */
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    font-size: clamp(0.85rem, 1.1vw, 1.1rem);
    gap: clamp(16px, 6vw, 300px);
}

.espectaculo-texto > div {
    position: relative;
    inset: 0;
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    overflow-y: auto;
    margin: 0;
    padding: 0.8rem clamp(0.5rem, 2vw, 1.5rem);
    color: white;
    font-size: clamp(0.85rem, 1.1vw, 1.1rem);
    line-height: 1.4;
    text-align: justify;
    hyphens: auto;
    gap: 0.6rem;
}


/* =========================================================
   BOTONES
========================================================= */

.yellow-button {
  background-image: url("../IMG/BTN.png");
  background-position: center;
  background-repeat: no-repeat;
  background-size: 100% 100%;
    color: #ffffff;
    font-family: "Aladin", system-ui;
    font-style: italic;
    font-size: clamp(0.85rem, 1.4vw, 1.2rem);
    letter-spacing: 0.5px;

    padding: clamp(8px, 1.6vw, 12px) clamp(16px, 4vw, 40px);
    cursor: pointer;
    position: relative;
    outline: none;

    transition: all 0.3s ease;
}

.yellow-button-txt:hover {
   background: linear-gradient(
    135deg,
    #7a5c1e 0%,
    #d4af37 15%,
    #fff6d5 25%,
    #ffffff 32%,
    #fff6d5 40%,
    #d4af37 50%,
    #a67c1e 62%,
    #f9e08c 75%,
    #b8860b 88%,
    #7a5c1e 100%
  );
  background-size: 300% 300%;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  animation: shine 4s linear infinite;
}

@keyframes shine {
  0%   { background-position: 0% 50%; }
  50%  { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}


.logo-nombre {
    width: min(30%, 200px);
    height: auto;
    display: block;
    margin: 0 auto 10px;
}


/* =========================================================
   CONTENEDOR INTERIOR (.emociones__inner)
========================================================= */

.emociones__inner {
    position: relative;
    z-index: 1;
    height: auto;      /* la altura la decide el contenido de abajo, ya reducido */
    width: 100%;
    max-width: 1800px;

    margin: 0 auto;
    padding: clamp(6px, 0.8vw, 10px);   /* antes: clamp(7px, 1vw, 12px) */

    border: 1px solid rgba(0, 0, 0, 0.20);
    border-radius: 15px;

    background: linear-gradient(
        90deg,
        rgba(5, 0, 15, .78),
        rgba(15, 0, 20, .65),
        rgba(5, 0, 15, .78)
    );

    box-shadow:
        0 2px 7px rgba(0, 0, 0, 0.4),
        inset 0 0 20px rgba(255, 255, 255, 0.15);
}

.emociones {
    /* padding vertical recortado respecto a la versión anterior */
    padding: clamp(12px, 1.8vw, 36px) clamp(3vw, 4vw, 5vw) clamp(18px, 2.4vw, 36px);
    min-height: auto;
	display: flow-root;
}

.emociones__header {
    height: auto;
    min-height: 48px;                    /* antes: 70px */
    padding: clamp(8px, 1.2vw, 16px);    /* antes: clamp(12px, 2vw, 24px) */
}

.emociones__header h2 {
    font-size: clamp(14px, 2.4vw, 22px);   /* antes: clamp(16px, 3vw, 28px) */
}

.emociones__header p {
    font-size: clamp(9px, 1.3vw, 13px);    /* antes: clamp(10px, 1.6vw, 16px) */
}

/* Grid de tarjetas: mismas columnas fluidas, más compacto en alto */
.emociones__cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));  /* antes: 260px */
    gap: clamp(8px, 1.4vw, 16px);   /* antes: clamp(12px, 2vw, 24px) */
}

.card {
    max-width: 100%;
    width: 100%;
}

.card__content h3 {
    font-size: clamp(13px, 1.6vw, 18px);
}

.card__content p {
    font-size: clamp(12px, 1.4vw, 16px);
}


/* =========================================================
   TOOLTIPS DE BOTONES
========================================================= */

@media (max-width: 600px) {
    .button-tooltip_1,
    .button-tooltip_2,
    .button-tooltip_3,
    .button-tooltip_4,
    .button-tooltip_5 {
        bottom: auto;
        top: calc(100% + 8px);
        height: min(300px, 55vh);
    }
}


/* =========================================================
   MODALES
========================================================= */

.modal {
    border: 1px solid rgba(212, 175, 55, 0.85);
    border-radius: 16px;
    padding: 0;
    width: 900px;
    height: 90vh;
    margin: auto;
    background: var(--dark);
      overflow: visible;   /* para que la X no se recorte */
}

.modal::backdrop {
    background: rgba(5, 0, 15, 0.85);
    backdrop-filter: blur(4px);
}

.modal__img {
   
    width: auto;
    height: auto;
    max-width: 100%;
    max-height: 90vh;
    object-fit: contain;
    margin: auto;
    border-radius: 16px;
}N

#modal-video {
    width: 960px;
    aspect-ratio: 16 / 9;
    height: auto;
    max-height: 90vh;

    border: 1px solid rgba(212, 175, 55, 0.85);
    border-radius: 16px;
    background: #000;
    overflow: hidden;
}

#modal-video .video-main {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #000;
}

#modal-video .modal__cerrar {
    top: 16px;
    right: 16px;
}

#modal-video_2 {
    width: 960px;
    aspect-ratio: 16 / 9;
    height: auto;
    max-height: 90vh;

    border: 1px solid rgba(212, 175, 55, 0.85);
    border-radius: 16px;
    background: #000;
    overflow: hidden;
}

#modal-video_2 .video-main {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #000;
}

.modal__cerrar {
    position: absolute;
    top: 10px;     
    right: 10px;    
    z-index: 2;

    width: 36px;
    height: 36px;

    border: 1px solid black;
    border-radius: 50%;
    background: linear-gradient(135deg, #9b35e8, #e83bc0);

    color: white;
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
}

dialog#modal-programa,
dialog#modal-programa_2 {
    width: 470px;
    height: 90vh;
}

/* Modal a pantalla casi completa en móvil, para que sea usable */
@media (max-width: 700px) {
    .modal {
        width: 90vw;
        height: 90vh;
    }
}


/* =========================================================
   EVITAR DESBORDAMIENTOS
========================================================= */

.emociones,
.emociones__inner,
.emociones__cards,
.card,
.card__content,
.footer,
.footer-container,
.footer-info,
.footer-links,
.footer-contact {
    min-width: 0;
}


/* =========================================================
   CORRECCIÓN FINAL PARA ELEMENTOS LARGOS
========================================================= */

h1, h2, h3, h4, h5, h6, p, a, span {
    overflow-wrap: break-word;
}


/* ===========================
   FOOTER
=========================== */

.footer {
    background:
        linear-gradient(rgba(0,0,0,0.6), rgba(0,0,0,0.6)),
        linear-gradient(to right, #892be2c8 0%, #ff00aaa0 100%);
    color: #f5f5f5;
    padding: clamp(40px, 5vw, 80px) clamp(14px, 4vw, 20px) 30px;
    width: 100%;
    margin: auto;
    display: flex;
    flex-direction: column;
    text-align: center;
}

.footer-container {
    display: grid;
    grid-template-columns: 1fr;
    gap: clamp(20px, 4vw, 40px);
    max-width: 1300px;
    width: 100%;
    margin: 0 auto;
    text-align: center;
}

.footer-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-bottom: 25px;
}

.footer-logo img {
    width: clamp(120px, 15.96vw, 216px);
    height: auto;
}

.footer-info p {
    max-width: 500px;
    margin: 0 auto;
    line-height: 1.8;
    color: #ffffff;
    font-family: "Edu TAS Beginner", cursive;
    font-size: clamp(1rem, 2.2vw, 1.721rem);
}

.footer h4 {
    margin-bottom: 20px;
    color: #e0468f;
    font-size: clamp(1.2rem, 2.4vw, 1.812rem);
    text-shadow: 0 0 6px rgba(255, 255, 255, 0.2);
    letter-spacing: 2px;
    font-family: "Aladin", system-ui;
}

.footer-links ul {
    list-style: none;
    padding: 0;
}

.footer-links li {
    margin-bottom: 14px;
}

.footer-links ul li a,
.footer-links a {
    font-family: "Edu TAS Beginner", cursive;
    font-size: clamp(1rem, 2.2vw, 1.721rem);
    color: #ffffff;
    text-decoration: none;
    transition: .3s;
}

.footer-links a:hover {
    color: white;
}

.footer-contact p {
    margin-bottom: 14px;
    color: #ffffff;
    font-family: "Edu TAS Beginner", cursive;
    font-size: clamp(1rem, 2.2vw, 1.721rem);
    word-break: break-word;
}

.footer-contact p a {
text-decoration: none;
color: #ffffff;
font-size: 1.5rem;
font-family: "Edu TAS Beginner", cursive;	
}

.footer-bottom {
    max-width: 1300px;
    margin: 50px auto 0;
    padding-top: 25px;
    text-align: center;
    font-size: clamp(0.85rem, 1.6vw, 1.15rem);
    font-family: "Edu TAS Beginner", cursive;
    color: #d8d8d8;
    border-top: 1px solid rgba(255,255,255,.15);
}

/* Tablet: 2 columnas, info arriba a lo ancho */
@media (min-width: 768px) {
    .footer-container {
        grid-template-columns: repeat(2, 1fr);
        text-align: center;
    }

    .footer-info {
        grid-column: 1 / -1;
    }

    .footer-logo {
        justify-content: center;
    }

    .footer-info p {
        margin: 0;
    }
}

/* Escritorio: 3 columnas */
@media (min-width: 992px) {
    .footer-container {
        grid-template-columns: 2fr 1fr 1.3fr;
        gap: 80px;
    }

    .footer-info {
        grid-column: auto;
    }
}

/* Pantallas grandes */
@media (min-width: 1400px) {
    .footer {
        padding: 80px 40px 35px;
    }

    .footer-container {
        gap: 100px;
    }
}

/* Móvil: todo centrado en columna */
@media (max-width: 768px) {
    .footer-container {
        display: flex;
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .footer h4 {
        font-family: "Aladin", system-ui;
        color: #e0468f;
    }

    .footer-logo {
        justify-content: center;
    }

    .footer-bottom {
        padding: 15px 10px;
    }
}

@media (max-width: 1485px) {
    .espectaculo-grid {
        grid-template-columns: 1fr;
    }

    .espectaculo-media img {
        max-height: none;
		 height: auto;          /* que la altura la marque el aspect-ratio real de la imagen */
        object-fit: contain;
		width: 100%;
    }
}

@media (max-width: 679px) {
    html, body {
        height: 100%;
        min-height: 100dvh;
    }

    body {
        display: flex;
        flex-direction: column;
    }
}

/* =========================================================
   MODALES — ajuste por pantalla (van al final, junto al resto)
========================================================= */

@media (max-width: 1485px) {
    .modal {
        max-width: 85vw;
    }

    #modal-video {
        width: 85vw;
    }
}

@media (max-width: 992px) {
    .modal {
        max-width: 88vw;
    }

    #modal-video {
        width: 88vw;
    }
}

@media (max-width: 768px) {
    .modal {
        width: 360px;
		height: 800px;
    }

    #modal-video {
        width: 92vw;
    }

    /* Programas: mismos ajustes para ambos */
    dialog#modal-programa,
    dialog#modal-programa_2 {
        box-sizing: border-box;
        width: 360px;
		height: 480px;
        margin: auto;
        padding: 0;
    }

    #modal-programa .modal__img,
    #modal-programa_2 .modal__img {
        display: block;
        width: 360px;
		height: 480px;
        object-fit: contain;
        border-radius: 16px;
    }
}

@media (max-width: 679px) {
    .modal {
        max-width: 94vw;
        max-height: 85vh;
    }

    #modal-video {
        width: 94vw;
        max-height: 85vh;
    }
}

@media (max-width: 360px) {
    .modal {
        max-width: 96vw;
    }

    #modal-video {
        width: 96vw;
    }
}

@media (max-width: 359px) {

    .bottom-menu {
        height: 40px !important;
        padding: 0 2px !important;
        border-radius: 10px;
    }

    .menu-item {
        height: 52px !important;
        padding: 0 3px !important;
        min-width: 0;
    }

    .menu-text {
        font-size: 10px !important;
        white-space: nowrap;
    }

    .menu-indicator {
        width: 26px;
        max-width: 70%;
    }
}

@media (min-width: 360px) and (max-width: 479px) {

    .bottom-menu {
        height: 40px !important;
        padding: 0 3px !important;
        border-radius: 10px;
    }

    .menu-item {
        height: 55px !important;
        padding: 0 5px !important;
    }

    .menu-text {
        font-size: clamp(10px, 3vw, 12px);
    }
}

@media (min-width: 480px) and (max-width: 599px) {

    .bottom-menu {
        height: 40px !important;
        padding: 0 3px !important;
        border-radius: 10px;
    }

    .menu-item {
        height: 58px !important;
        padding: 0 8px !important;
    }

    .menu-text {
        font-size: 13px;
    }
}
