/* ============================================================
   Bachillerato y Póker (2026-10-18): portadas ilustradas de cada juego
   (templates/_cover_*.html) y anuncio compartido de la portada
   (templates/_estreno_duo.html). Arte SVG en templates/_estreno_art.html.
   Los fondos son propios de cada ilustración (papel, paño): se ven igual
   en tema claro y oscuro.
   ============================================================ */
.ea-svg { display: block; width: 100%; height: auto; overflow: visible; }

/* palabra de letras de colores (como fichas de Bachillerato) */
.ea-word { display: flex; flex-wrap: wrap; gap: .06em; margin: 0; font-family: var(--font-display, "Source Serif 4", Georgia, serif); font-weight: 700; line-height: 1; }
.ea-word > span { display: inline-block; }
.ea-word .c0 { color: #E8483B; } .ea-word .c1 { color: #F08A1C; } .ea-word .c2 { color: #2F8F5B; }
.ea-word .c3 { color: #3D6FD1; } .ea-word .c4 { color: #8C4FD6; } .ea-word .c5 { color: #D63C83; }

/* ---------------------------------------------------------------- portadas */
.ea-cover {
  position: relative; display: grid; grid-template-columns: 1fr 1.15fr; align-items: center; gap: 12px;
  margin: 0 0 20px; padding: 22px 22px 22px 28px; border-radius: var(--r-lg, 18px); overflow: hidden;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, .06), 0 10px 30px -14px rgba(40, 20, 0, .35);
}
.ea-cover-copy { min-width: 0; display: flex; flex-direction: column; gap: 10px; }
.ea-cover-art { min-width: 0; }
.ea-cover-sub { margin: 0; font-size: 1.05rem; font-weight: 600; }

.ea-cover-bach {
  color: #2A2016;
  background:
    radial-gradient(circle at 12% 18%, rgba(232, 72, 59, .14) 0 22%, transparent 23%),
    radial-gradient(circle at 92% 88%, rgba(61, 111, 209, .14) 0 18%, transparent 19%),
    repeating-linear-gradient(0deg, transparent 0 27px, rgba(156, 195, 230, .35) 27px 28px),
    linear-gradient(160deg, #FFF8E6 0%, #FCEBC4 100%);
}
.ea-cover-bach .ea-word { font-size: clamp(1.9rem, 3.4vw, 2.7rem); letter-spacing: -.01em; text-shadow: 0 2px 0 rgba(255, 255, 255, .9); }
.ea-cover-bach .ea-cover-sub strong { color: #E8483B; letter-spacing: .04em; }
.ea-cover-tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 2px 0 0; }
.ea-cover-tags span { padding: 3px 10px; border-radius: 99px; font-size: .75rem; font-weight: 700; color: #fff; letter-spacing: .02em; }
.ea-cover-tags span:nth-child(9n+1) { background: #E8483B; } .ea-cover-tags span:nth-child(9n+2) { background: #3D6FD1; }
.ea-cover-tags span:nth-child(9n+3) { background: #2F8F5B; } .ea-cover-tags span:nth-child(9n+4) { background: #F08A1C; }
.ea-cover-tags span:nth-child(9n+5) { background: #D63C83; } .ea-cover-tags span:nth-child(9n+6) { background: #8A6A3A; }
.ea-cover-tags span:nth-child(9n+7) { background: #8C4FD6; } .ea-cover-tags span:nth-child(9n+8) { background: #138A8A; }
.ea-cover-tags span:nth-child(9n+9) { background: #5A6472; }

.ea-cover-poker {
  color: #F5EBD3;
  background:
    radial-gradient(70% 90% at 75% 45%, rgba(46, 154, 98, .35) 0%, transparent 70%),
    radial-gradient(40% 60% at 0% 100%, rgba(217, 181, 103, .16) 0%, transparent 70%),
    linear-gradient(150deg, #0F3B27 0%, #072217 100%);
  box-shadow: inset 0 0 0 1px rgba(217, 181, 103, .35), 0 10px 30px -14px rgba(0, 0, 0, .5);
}
.ea-kicker { margin: 0; font-size: .78rem; font-weight: 700; letter-spacing: .3em; text-transform: uppercase; color: #D9B567; }
.ea-poker-title {
  margin: 0; font-family: var(--font-display, "Source Serif 4", Georgia, serif); font-weight: 700; line-height: .95;
  font-size: clamp(2.6rem, 5vw, 3.6rem); letter-spacing: .02em;
  background: linear-gradient(180deg, #F7E2A8 0%, #D9B567 55%, #A9802F 100%); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.ea-fict { margin: 2px 0 0; display: inline-flex; align-self: flex-start; padding: 5px 12px; border-radius: 99px; font-size: .78rem; font-weight: 600;
  color: #F5EBD3; background: rgba(0, 0, 0, .28); box-shadow: inset 0 0 0 1px rgba(217, 181, 103, .45); }

@media (max-width: 720px) {
  .ea-cover { grid-template-columns: 1fr; padding: 18px 16px 14px; gap: 6px; }
  .ea-cover-art { max-width: 420px; width: 100%; justify-self: center; }
}

/* ------------------------------------------- anuncio compartido de la portada */
.estreno-duo {
  position: relative; margin: 16px 0 22px; border-radius: var(--r-lg, 18px); overflow: hidden;
  box-shadow: 0 0 0 1px var(--line, #e6ded2), 0 18px 40px -22px rgba(40, 20, 0, .45);
  container-type: inline-size;
}
.ed-grid { display: grid; grid-template-columns: 1fr 1fr; }
.ed-badge {
  position: absolute; z-index: 3; top: 14px; left: 50%; transform: translateX(-50%);
  display: inline-flex; align-items: center; gap: 6px; padding: 6px 14px; border-radius: 99px; white-space: nowrap;
  font-size: .74rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase;
  color: #2A1A06; background: linear-gradient(180deg, #FFE08A, #F2B735); box-shadow: 0 4px 14px -4px rgba(0, 0, 0, .35), inset 0 0 0 1px rgba(255, 255, 255, .5);
}
.ed-spark { color: #C8302A; }
.ed-half {
  position: relative; display: grid; align-items: center; column-gap: 10px; row-gap: 10px;
  grid-template-columns: minmax(0, .95fr) minmax(0, 1.05fr);
  grid-template-areas: "eye art" "title art" "sub art" "cta art";
  align-content: center;
  min-height: 300px; padding: 50px 18px 26px 32px; text-decoration: none; isolation: isolate;
  transition: filter .25s ease;
}
.ed-copy { display: contents; }
.ed-eyebrow { grid-area: eye; align-self: end; }
.ed-title { grid-area: title; }
.ed-sub { grid-area: sub; }
.ed-cta { grid-area: cta; }
.ed-art { grid-area: art; min-width: 0; position: relative; z-index: 1; }
.ed-eyebrow, .ed-title, .ed-sub, .ed-cta { position: relative; z-index: 2; }
.ed-half:hover { filter: brightness(1.04) saturate(1.05); }
.ed-half:focus-visible { outline: 3px solid var(--focus, #2563eb); outline-offset: -4px; }
.ed-eyebrow { font-size: .72rem; font-weight: 800; letter-spacing: .2em; text-transform: uppercase; white-space: nowrap; }
.ed-title { font-size: 2.9cqw; white-space: nowrap; flex-wrap: nowrap; }
.ed-sub { font-size: .95rem; line-height: 1.45; max-width: 32ch; }
.ed-cta {
  display: inline-flex; align-items: center; gap: 6px; justify-self: start; margin-top: 4px; white-space: nowrap;
  min-height: 44px; padding: 0 18px; border-radius: 99px; font-weight: 700; font-size: .95rem;
  transition: transform .2s ease, box-shadow .2s ease;
}
.ed-cta svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; transition: transform .2s ease; }
.ed-half:hover .ed-cta { transform: translateY(-1px); }
.ed-half:hover .ed-cta svg { transform: translateX(3px); }
.ed-art .ea-svg { transition: transform .5s cubic-bezier(.2, .8, .2, 1); }
.ed-half:hover .ed-art .ea-svg { transform: rotate(-1.5deg) scale(1.03); }

.ed-bach {
  color: #2A2016;
  background:
    repeating-linear-gradient(0deg, transparent 0 27px, rgba(156, 195, 230, .38) 27px 28px),
    linear-gradient(160deg, #FFF8E6 0%, #FCE7B8 100%);
}
.ed-bach::before { content: ""; position: absolute; top: 0; bottom: 0; left: 18px; width: 2px; background: rgba(227, 106, 94, .55); z-index: 0; }
.ed-bach .ed-eyebrow { color: #C8302A; }
.ed-bach .ed-title { text-shadow: 0 2px 0 rgba(255, 255, 255, .9); }
.ed-bach .ed-sub { color: #4A3B28; }
.ed-bach .ed-sub b { color: #E8483B; }
.ed-bach .ed-cta { color: #fff; background: #E8483B; box-shadow: 0 6px 16px -6px rgba(232, 72, 59, .8); }

.ed-poker {
  color: #F5EBD3;
  background:
    radial-gradient(70% 90% at 72% 50%, rgba(46, 154, 98, .4) 0%, transparent 70%),
    linear-gradient(150deg, #0F3B27 0%, #06200F 100%);
  box-shadow: inset 1px 0 0 rgba(217, 181, 103, .5);
}
.ed-poker .ed-eyebrow { color: #D9B567; }
.ed-title-poker {
  font-family: var(--font-display, "Source Serif 4", Georgia, serif); font-weight: 700; line-height: 1; display: flex; flex-direction: column;
  font-size: 3.3cqw;
  background: linear-gradient(180deg, #F7E2A8 0%, #D9B567 55%, #A9802F 100%); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.ed-title-poker em { font-size: .5em; font-style: italic; font-weight: 600; letter-spacing: .04em; margin-top: 4px; }
.ed-poker .ed-sub { color: rgba(245, 235, 211, .86); }
.ed-poker .ed-cta { color: #1E1406; background: linear-gradient(180deg, #F7E2A8, #D9B567); box-shadow: 0 6px 16px -6px rgba(217, 181, 103, .7); }

/* móvil y tablet estrecha: una mitad sobre la otra; título arriba, texto a la izquierda y arte a la derecha */
@container (max-width: 700px) {
  .ed-grid { grid-template-columns: 1fr; }
  .ed-badge { top: 10px; font-size: .68rem; }
  .ed-half {
    min-height: 0; padding: 46px 14px 20px 26px; row-gap: 8px; column-gap: 6px;
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
    grid-template-areas: "eye eye" "title title" "sub art" "cta cta";
  }
  .ed-poker { padding-top: 22px; box-shadow: inset 0 1px 0 rgba(217, 181, 103, .5); }
  .ed-title { font-size: 9.4cqw; }
  .ed-title-poker { font-size: 10cqw; flex-direction: row; align-items: baseline; gap: .3em; flex-wrap: wrap; }
  .ed-sub { font-size: .875rem; }
  .ed-cta { font-size: .9rem; padding: 0 16px; }
  .ed-art { align-self: center; }
}
@container (max-width: 360px) {
  .ed-half { padding-left: 22px; padding-right: 10px; }
  .ed-sub { font-size: .8rem; }
  .ed-cta { font-size: .85rem; padding: 0 14px; }
}

@media (max-width: 720px) { .estreno-duo { margin: 12px 0 18px; } }
@media (prefers-reduced-motion: reduce) {
  .ed-half, .ed-cta, .ed-cta svg, .ed-art .ea-svg { transition: none; }
  .ed-half:hover .ed-art .ea-svg { transform: none; }
}
