/* =========================================================
   DrumFest Chiloé — estilos
   Negro escenario + amarillo eléctrico (colores de sus afiches)
   ========================================================= */
:root {
  --negro: #0b0b0c;
  --fondo: #111113;
  --superficie: #18181b;
  --borde: rgba(255, 255, 255, .1);
  --texto: #ececec;
  --suave: #a1a1aa;
  --amarillo: #ffd21f;
  --amarillo-hover: #ffe15c;
  --rosa: #ff3d7f;
  --radio: 14px;
  --ancho: 1200px;
  --nav-h: 78px;
  --t-display: "Bebas Neue", Impact, "Arial Narrow", sans-serif;
  --t-base: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: var(--nav-h); -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--t-base); font-weight: 400; font-size: 1rem; line-height: 1.7; color: var(--texto); background: var(--negro); -webkit-font-smoothing: antialiased; overflow-x: hidden; }
img { max-width: 100%; height: auto; display: block; }
svg { width: 1em; height: 1em; flex-shrink: 0; }
a { color: inherit; text-decoration: none; transition: color .2s; }
ul { list-style: none; margin: 0; padding: 0; }
button { font: inherit; color: inherit; cursor: pointer; }
h1, h2, h3 { margin: 0; }
:focus-visible { outline: 2px solid var(--amarillo); outline-offset: 3px; border-radius: 4px; }
::selection { background: var(--amarillo); color: #000; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.contenedor { width: min(100% - 2.5rem, var(--ancho)); margin-inline: auto; }
.saltar { position: absolute; left: 1rem; top: -4rem; z-index: 100; background: var(--amarillo); color: #000; padding: .6rem 1rem; border-radius: 6px; font-weight: 600; }
.saltar:focus { top: 1rem; }

/* Tipografía */
.eyebrow { display: inline-flex; align-items: center; gap: .6rem; margin: 0 0 .7rem; font-size: .78rem; font-weight: 600; letter-spacing: .2em; text-transform: uppercase; color: var(--amarillo); }
.eyebrow::before { content: ""; width: 26px; height: 2px; background: currentColor; }
.eyebrow--centro { display: flex; justify-content: center; }
.titulo { font-family: var(--t-display); font-weight: 400; font-size: clamp(2.4rem, 1.6rem + 3vw, 4rem); line-height: .98; letter-spacing: .01em; color: #fff; text-wrap: balance; }
.titulo--xl { font-size: clamp(3.2rem, 2rem + 6vw, 6.5rem); }
.cabecera { margin-bottom: clamp(1.8rem, 4vw, 2.8rem); }
.cabecera--fila { display: flex; align-items: end; justify-content: space-between; gap: 1.5rem; flex-wrap: wrap; }
.seccion { padding: clamp(3.5rem, 7vw, 6rem) 0; }

/* Botones y enlaces */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .6rem; padding: .9rem 1.6rem; border-radius: 999px; font-weight: 600; font-size: .95rem; transition: background .2s, color .2s, border-color .2s, transform .2s; }
.btn:hover { transform: translateY(-2px); }
.btn--amarillo { background: var(--amarillo); color: #000; }
.btn--amarillo:hover { background: var(--amarillo-hover); color: #000; }
.btn--linea { border: 1px solid rgba(255, 255, 255, .5); color: #fff; }
.btn--linea:hover { background: #fff; color: #000; }
.btn--grande { padding: 1.05rem 1.9rem; font-size: clamp(.95rem, .85rem + .4vw, 1.1rem); word-break: break-all; }
.btn svg { width: 1.25em; height: 1.25em; }
.enlace-flecha { display: inline-flex; align-items: center; gap: .45rem; font-weight: 600; color: var(--amarillo); }
.enlace-flecha svg { transition: transform .2s; }
.enlace-flecha:hover svg { transform: translateX(4px); }
.chip { display: inline-block; padding: .15rem .6rem; border-radius: 999px; font-size: .72rem; font-weight: 600; letter-spacing: .06em; background: rgba(255, 255, 255, .08); color: #fff; }
.chip--video { background: var(--rosa); }

/* ============ Encabezado ============ */
.nav { position: fixed; inset: 0 0 auto; z-index: 50; height: var(--nav-h); transition: background .3s, box-shadow .3s; }
.nav.is-solido, .nav.is-menu { background: rgba(11, 11, 12, .9); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); box-shadow: 0 1px 0 var(--borde); }
.nav__in { height: 100%; width: min(100% - 2.5rem, 1320px); margin-inline: auto; display: flex; align-items: center; gap: 2rem; }
.nav__marca img { height: 58px; width: auto; }
.nav__menu { display: flex; gap: 2rem; margin-left: auto; }
.nav__menu a { position: relative; font-size: .93rem; font-weight: 500; color: rgba(255, 255, 255, .82); }
.nav__menu a::after { content: ""; position: absolute; left: 0; right: 0; bottom: -6px; height: 2px; background: var(--amarillo); transform: scaleX(0); transition: transform .25s; }
.nav__menu a:hover, .nav__menu a[aria-current="page"] { color: #fff; }
.nav__menu a:hover::after, .nav__menu a[aria-current="page"]::after { transform: scaleX(1); }
.nav__redes { display: flex; gap: 1rem; font-size: 1.1rem; }
.nav__redes a, .hero__redes a, .pie__redes a { display: flex; color: #fff; }
.nav__redes a:hover, .hero__redes a:hover, .pie__redes a:hover { color: var(--amarillo); }
.nav__toggle { display: none; }

@media (max-width: 920px) {
  :root { --nav-h: 66px; }
  .nav__marca img { height: 40px; }
  .nav__redes { margin-left: auto; }
  .nav__toggle { display: flex; flex-direction: column; justify-content: center; gap: 5px; width: 44px; height: 44px; padding: 10px; background: none; border: 0; }
  .nav__toggle span { height: 2px; background: #fff; border-radius: 2px; transition: transform .3s, opacity .3s; }
  .nav__toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav__toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .nav__toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
  .nav__menu { position: fixed; inset: var(--nav-h) 0 auto; margin: 0; flex-direction: column; gap: 0; padding: .5rem 1.25rem 1.25rem; background: rgba(11, 11, 12, .97); border-bottom: 1px solid var(--borde); opacity: 0; visibility: hidden; transform: translateY(-10px); transition: opacity .25s, transform .25s, visibility .25s; }
  .nav__menu.is-abierto { opacity: 1; visibility: visible; transform: none; }
  .nav__menu a { padding: .95rem 0; border-bottom: 1px solid var(--borde); font-size: 1.05rem; }
  .nav__menu a::after { display: none; }
  .nav__menu a[aria-current="page"] { color: var(--amarillo); }
}
@media (max-width: 400px) { .nav__redes { display: none; } .nav__toggle { margin-left: auto; } }

/* ============ Portada ============ */
.hero { position: relative; min-height: 100svh; display: grid; align-items: center; padding: calc(var(--nav-h) + 2rem) 0 6rem; overflow: hidden; isolation: isolate; }
.hero__bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; animation: acercar 16s ease-out both; }
.hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(11, 11, 12, .95) 0%, rgba(11, 11, 12, .7) 45%, rgba(11, 11, 12, .2) 100%), linear-gradient(0deg, var(--negro) 0%, transparent 35%); }
@keyframes acercar { from { transform: scale(1.1); } to { transform: scale(1); } }
.hero__in { max-width: var(--ancho); }
.hero__titulo { max-width: 16ch; font-family: var(--t-display); font-weight: 400; font-size: clamp(3.2rem, 1.6rem + 5vw, 6.2rem); line-height: .9; color: #fff; margin-bottom: 1.4rem; }
.hero__titulo em { font-style: normal; color: var(--amarillo); }
.hero__bajada { max-width: 48ch; margin: 0 0 2.2rem; font-size: clamp(1.02rem, .95rem + .35vw, 1.2rem); color: rgba(255, 255, 255, .8); }
.hero__cta { display: flex; flex-wrap: wrap; gap: .9rem; }
.hero__redes { position: absolute; right: clamp(1.25rem, 3vw, 2.5rem); top: 50%; translate: 0 -50%; display: flex; flex-direction: column; gap: 1.2rem; font-size: 1.15rem; }
.hero__redes::before, .hero__redes::after { content: ""; width: 1px; height: 60px; margin-inline: auto; background: rgba(255, 255, 255, .3); }
/* Ecualizador "ritmo" */
.ritmo { position: absolute; left: 50%; bottom: 2rem; translate: -50% 0; display: flex; align-items: end; gap: 5px; height: 28px; }
.ritmo span { width: 4px; height: 100%; border-radius: 2px; background: var(--amarillo); transform-origin: bottom; animation: golpe 1.1s ease-in-out infinite; }
.ritmo span:nth-child(2) { animation-delay: -.3s; } .ritmo span:nth-child(3) { animation-delay: -.6s; } .ritmo span:nth-child(4) { animation-delay: -.15s; }
.ritmo span:nth-child(5) { animation-delay: -.45s; } .ritmo span:nth-child(6) { animation-delay: -.75s; } .ritmo span:nth-child(7) { animation-delay: -.9s; }
@keyframes golpe { 0%, 100% { transform: scaleY(.2); } 50% { transform: scaleY(1); } }
@media (max-width: 760px) {
  .hero { align-items: end; }
  .hero::before { background: linear-gradient(0deg, rgba(11, 11, 12, .97) 15%, rgba(11, 11, 12, .55) 65%, rgba(11, 11, 12, .35) 100%); }
  .hero__redes { display: none; }
}

/* Cabecera de páginas interiores */
.pagina-hero { position: relative; padding: calc(var(--nav-h) + clamp(3rem, 8vw, 6rem)) 0 clamp(3rem, 6vw, 4.5rem); overflow: hidden; isolation: isolate; border-bottom: 1px solid var(--borde); }
.pagina-hero__bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.pagina-hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(11, 11, 12, .96) 20%, rgba(11, 11, 12, .65)), linear-gradient(0deg, var(--negro), transparent 60%); }
.pagina-hero__bajada { max-width: 56ch; margin: 1rem 0 0; font-size: clamp(1.02rem, .95rem + .35vw, 1.2rem); color: rgba(255, 255, 255, .78); }

/* ============ Cifras ============ */
.cifras { background: var(--amarillo); color: #000; }
.cifras__lista { display: grid; grid-template-columns: repeat(4, 1fr); }
.cifras li { padding: 1.6rem 1rem; text-align: center; border-left: 1px solid rgba(0, 0, 0, .15); }
.cifras li:first-child { border-left: 0; }
.cifras strong { display: block; font-family: var(--t-display); font-weight: 400; font-size: clamp(2.4rem, 1.8rem + 2vw, 3.4rem); line-height: 1; }
.cifras span { font-size: .85rem; font-weight: 600; letter-spacing: .02em; }
@media (max-width: 700px) {
  .cifras__lista { grid-template-columns: repeat(2, 1fr); }
  .cifras li:nth-child(3) { border-left: 0; }
  .cifras li:nth-child(n+3) { border-top: 1px solid rgba(0, 0, 0, .15); }
}

/* ============ Historia ============ */
.historia { padding: clamp(4.5rem, 9vw, 7.5rem) 0; }
.historia__grid { display: grid; grid-template-columns: 1fr 1.1fr; gap: clamp(2.5rem, 6vw, 5rem); align-items: center; }
.historia__foto { position: relative; margin: 0; }
.historia__foto img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; border-radius: var(--radio); }
.historia__foto::before { content: ""; position: absolute; inset: 1.2rem -1.2rem -1.2rem 1.2rem; z-index: -1; border: 2px solid var(--amarillo); border-radius: var(--radio); }
.historia .titulo { margin-bottom: 1.3rem; }
.historia p { margin: 0 0 1.1rem; color: rgba(236, 236, 236, .85); text-wrap: pretty; }
.historia__lead { font-size: clamp(1.15rem, 1rem + .5vw, 1.35rem); line-height: 1.55; color: #fff !important; }
@media (max-width: 860px) { .historia__grid { grid-template-columns: 1fr; } .historia__foto { max-width: 460px; margin-right: 1.2rem; } .historia__foto img { aspect-ratio: 4 / 3; } }

/* ============ Actividades ============ */
.actividades { padding: clamp(4.5rem, 8vw, 7rem) 0; background: var(--fondo); border-block: 1px solid var(--borde); }
.filtros { display: flex; flex-wrap: wrap; gap: .5rem; }
.filtro { padding: .5rem 1.1rem; border-radius: 999px; border: 1px solid var(--borde); background: transparent; font-size: .9rem; font-weight: 500; transition: background .2s, color .2s, border-color .2s; }
.filtro:hover { border-color: rgba(255, 255, 255, .35); }
.filtro[aria-pressed="true"] { background: var(--amarillo); border-color: var(--amarillo); color: #000; }
.act-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 1.25rem; }
.act { position: relative; display: flex; flex-direction: column; background: var(--superficie); border: 1px solid var(--borde); border-radius: var(--radio); overflow: hidden; transition: transform .3s, border-color .3s; }
.act:hover { transform: translateY(-4px); border-color: rgba(255, 210, 31, .5); }
.act[hidden] { display: none; }
.act__media { position: relative; aspect-ratio: 4 / 3; overflow: hidden; background: #000; }
.act__media > img { width: 100%; height: 100%; object-fit: cover; object-position: top; transition: transform .6s; }
.act:hover .act__media > img { transform: scale(1.05); }
.act__arte { position: absolute; inset: 0; display: grid; place-items: center; background: radial-gradient(circle at 30% 20%, rgba(255, 210, 31, .22), transparent 55%), radial-gradient(circle at 80% 90%, rgba(255, 61, 127, .25), transparent 50%), #0e0e10; }
.act__arte img { width: 62%; opacity: .9; }
.act__arte span { position: absolute; right: .9rem; bottom: .4rem; font-family: var(--t-display); font-size: 3rem; line-height: 1; color: rgba(255, 255, 255, .12); }
.act__play { position: absolute; left: 50%; top: 50%; translate: -50% -50%; display: grid; place-items: center; width: 64px; height: 64px; border-radius: 50%; background: var(--amarillo); color: #000; font-size: 1.5rem; box-shadow: 0 0 0 10px rgba(255, 210, 31, .2); transition: transform .3s, box-shadow .3s; }
.act:hover .act__play { transform: scale(1.1); box-shadow: 0 0 0 16px rgba(255, 210, 31, .18); }
.act__cuerpo { padding: 1.2rem 1.3rem 1.4rem; }
.act__meta { display: flex; gap: .4rem; margin: 0 0 .6rem; }
.act__titulo { font-size: 1.08rem; font-weight: 600; line-height: 1.35; color: #fff; margin-bottom: .4rem; }
.act__desc { margin: 0; font-size: .92rem; line-height: 1.6; color: var(--suave); }
.act__link { position: absolute; inset: 0; z-index: 2; }
@media (max-width: 560px) {
  .act-grid { grid-template-columns: 1fr; gap: .8rem; }
  .act { flex-direction: row; }
  .act__media { flex: 0 0 118px; aspect-ratio: auto; min-height: 140px; }
  .act__cuerpo { padding: .9rem 1rem; }
  .act__titulo { font-size: 1rem; }
  .act__desc { font-size: .85rem; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
  .act__play { width: 44px; height: 44px; font-size: 1.1rem; box-shadow: 0 0 0 6px rgba(255, 210, 31, .2); }
  .act__arte span { font-size: 1.8rem; }
  .artista h3 { font-size: 1.25rem; }
}

/* ============ Artistas ============ */
.destacados { padding: clamp(4.5rem, 8vw, 7rem) 0; }
.artistas-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 1.1rem; }
.destacados .artistas-grid { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 860px) { .destacados .artistas-grid { grid-template-columns: repeat(2, 1fr); } }
.artista { position: relative; overflow: hidden; border-radius: var(--radio); background: var(--superficie); isolation: isolate; }
.artista img { width: 100%; aspect-ratio: 1; object-fit: cover; filter: grayscale(1) contrast(1.05); transition: filter .5s, transform .6s; }
.artista:hover img { filter: none; transform: scale(1.05); }
.artista::after { content: ""; position: absolute; inset: 40% 0 0; background: linear-gradient(0deg, rgba(0, 0, 0, .92), transparent); pointer-events: none; }
.artista__info { position: absolute; left: 0; right: 0; bottom: 0; z-index: 1; padding: 1rem 1.1rem; }
.artista h3 { font-family: var(--t-display); font-weight: 400; font-size: 1.55rem; line-height: 1; letter-spacing: .02em; color: #fff; }
.artista p { margin: .3rem 0 0; font-size: .8rem; line-height: 1.4; color: var(--amarillo); }
@media (hover: none) { .artista img { filter: none; } }

/* ============ Equipo ============ */
.equipo-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 1.5rem; }
.miembro { background: var(--superficie); border: 1px solid var(--borde); border-radius: var(--radio); overflow: hidden; }
.miembro img { width: 100%; aspect-ratio: 5 / 6; object-fit: cover; }
.miembro__info { padding: 1.3rem 1.4rem 1.5rem; border-top: 3px solid var(--amarillo); }
.miembro h2 { font-family: var(--t-display); font-weight: 400; font-size: 2.1rem; line-height: 1; color: #fff; }
.miembro p { margin: .35rem 0 .7rem; color: var(--suave); }

/* ============ Galería ============ */
.galeria-grid { columns: 3 260px; column-gap: 1.1rem; }
.afiche { break-inside: avoid; margin-bottom: 1.1rem; }
.afiche a { display: block; overflow: hidden; border-radius: var(--radio); border: 1px solid var(--borde); }
.afiche img { width: 100%; transition: transform .5s; }
.afiche a:hover img { transform: scale(1.03); }

/* ============ Colaboradores ============ */
.colab-franja { padding: clamp(3rem, 6vw, 4.5rem) 0; background: var(--fondo); border-top: 1px solid var(--borde); }
.colab-logos { display: flex; flex-wrap: wrap; justify-content: center; gap: 1rem; margin-top: 1.5rem; }
.colab-logos li { display: grid; place-items: center; width: 170px; height: 96px; padding: .9rem 1.1rem; background: #fff; border-radius: 12px; opacity: .9; transition: opacity .2s, transform .2s; }
.colab-logos li:hover { opacity: 1; transform: translateY(-3px); }
.colab-logos img { max-width: 100%; max-height: 68px; width: auto; height: auto; }
.colab-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 1.25rem; }
.colab { display: flex; flex-direction: column; background: var(--superficie); border: 1px solid var(--borde); border-radius: var(--radio); overflow: hidden; }
.colab__logo { display: grid; place-items: center; height: 180px; padding: 1.8rem; background: #fff; }
.colab__logo img { max-width: 100%; max-height: 124px; width: auto; height: auto; }
.colab__info { padding: 1.3rem 1.4rem 1.5rem; }
.colab h2 { font-size: 1.1rem; font-weight: 600; line-height: 1.35; color: #fff; }
.colab p { margin: .35rem 0 .8rem; color: var(--suave); font-size: .92rem; }
@media (max-width: 400px) { .colab-grid { grid-template-columns: 1fr; } .colab-logos li { width: calc(50% - .5rem); } }

/* ============ Llamado a contacto ============ */
.cta { position: relative; padding: clamp(4.5rem, 9vw, 7rem) 0; overflow: hidden; isolation: isolate; }
.cta__bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.cta::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(11, 11, 12, .95) 30%, rgba(11, 11, 12, .6)); }
.cta__in { display: flex; align-items: center; justify-content: space-between; gap: 2rem; flex-wrap: wrap; }
.cta .titulo { max-width: 16ch; margin-bottom: .8rem; }
.cta p:not(.eyebrow) { margin: 0; color: var(--suave); max-width: 46ch; }

/* ============ Pie ============ */
.pie { background: #060607; border-top: 1px solid var(--borde); font-size: .9rem; color: var(--suave); }
.pie__in { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem 2rem; flex-wrap: wrap; padding: 2.5rem 0 2rem; }
.pie__logo img { height: 64px; width: auto; }
.pie__menu { display: flex; flex-wrap: wrap; gap: .5rem 1.6rem; }
.pie__menu a:hover { color: var(--amarillo); }
.pie__redes { display: flex; gap: 1.1rem; font-size: 1.15rem; }
.pie__final { display: flex; justify-content: space-between; gap: .5rem 2rem; flex-wrap: wrap; padding: 1.3rem 0 1.8rem; border-top: 1px solid var(--borde); font-size: .82rem; }
.pie__final p { margin: 0; }
.pie__final a { color: #fff; text-decoration: underline; text-underline-offset: 3px; }
.pie__final a:hover { color: var(--amarillo); }

/* ============ Visor (fotos y videos) ============ */
.visor { width: 100vw; height: 100dvh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: rgba(6, 6, 7, .96); color: #fff; }
.visor[open] { display: grid; place-items: center; }
.visor::backdrop { background: rgba(0, 0, 0, .8); }
.visor__cuerpo { display: grid; place-items: center; width: 100%; height: 100%; padding: 4.5rem 1rem; }
.visor__cuerpo img { max-width: min(92vw, 1400px); max-height: calc(100dvh - 9rem); width: auto; height: auto; object-fit: contain; border-radius: 8px; }
.visor__video { width: min(92vw, 1100px); aspect-ratio: 16 / 9; max-height: calc(100dvh - 9rem); }
.visor__video iframe { width: 100%; height: 100%; border: 0; border-radius: 10px; background: #000; }
.visor__contador { position: absolute; top: 1.2rem; left: 1.4rem; margin: 0; font-size: .9rem; letter-spacing: .1em; color: rgba(255, 255, 255, .75); }
.visor__btn { position: absolute; display: grid; place-items: center; width: 50px; height: 50px; border-radius: 50%; border: 1px solid rgba(255, 255, 255, .2); background: rgba(255, 255, 255, .06); font-size: 1.1rem; transition: background .2s, color .2s; }
.visor__btn:hover { background: var(--amarillo); border-color: var(--amarillo); color: #000; }
.visor__btn[hidden] { display: none; }
.visor__cerrar { top: .8rem; right: .8rem; }
.visor__prev { left: 1rem; top: 50%; translate: 0 -50%; }
.visor__next { right: 1rem; top: 50%; translate: 0 -50%; }
@media (max-width: 600px) { .visor__prev, .visor__next { top: auto; bottom: 1rem; translate: none; } }

/* Aparición suave */
.revelar { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .7s ease; }
.revelar.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .revelar { opacity: 1; transform: none; }
}
