/* GeNMuGamers - hoja de estilos. Pensada primero para teléfono; los anchos mayores suman columnas.
   Tema CLARO por defecto. El oscuro se activa con el botón de la luna (html[data-theme="dark"]). */
:root {
  --bg: #f2f5fa;
  --bg-2: #e8edf5;
  --panel: #ffffff;
  --panel-2: #f6f8fc;
  --line: #d9e0ec;
  --line-2: #c3cddd;
  --text: #172033;
  --text-2: #36415a;
  --muted: #586379;
  --link: #a91228;
  --link-hover: #6f0a19;
  --crimson: #c4162a;
  --crimson-2: #e02a3f;
  --gold: #d9b56c;
  --gold-2: #f0d595;
  --gold-text: #8a6007;
  --green: #238a43;
  --green-2: #2fa653;
  --ok-bg: #e7f6ec; --ok-line: #8fd0a3; --ok-text: #14572a;
  --err-bg: #fdecee; --err-line: #f0a3ad; --err-text: #8c1023;
  --info-bg: #fdf6e3; --info-line: #e6cd8a; --info-text: #5e4504;
  --head: #141a2b;
  --head-2: #0e1320;
  --head-line: #273049;
  --head-text: #e9ecf5;
  --head-muted: #a9b1c6;
  --input-bg: #ffffff;
  --input-line: #b9c3d4;
  --shadow: 0 1px 2px rgba(23, 32, 51, .06), 0 6px 20px rgba(23, 32, 51, .06);
  --radius: 12px;
  --wrap: 1180px;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --display: "Palatino Linotype", Palatino, "Book Antiqua", Georgia, "Times New Roman", serif;
  color-scheme: light;
}
html[data-theme="dark"] {
  --bg: #0b0d13;
  --bg-2: #12151e;
  --panel: #171b26;
  --panel-2: #1d2230;
  --line: #2a3142;
  --line-2: #3a4358;
  --text: #ecebf1;
  --text-2: #d3d6e0;
  --muted: #a4aabb;
  --link: #f0d595;
  --link-hover: #ffffff;
  --gold-text: #e3c27c;
  --ok-bg: #10241a; --ok-line: #2c7a45; --ok-text: #c9f0d5;
  --err-bg: #2a1016; --err-line: #a12a38; --err-text: #ffd0d6;
  --info-bg: #241e10; --info-line: #7a6a3a; --info-text: #f3e3b5;
  --head: #0e1119;
  --head-2: #090b11;
  --input-bg: #0e1118;
  --input-line: #3a4358;
  --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 24px rgba(0, 0, 0, .25);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 90px; }
body { margin: 0; background: var(--bg); color: var(--text); font: 16px/1.6 var(--font); min-height: 100vh; display: flex; flex-direction: column; }
main { flex: 1; }
img, svg { max-width: 100%; height: auto; vertical-align: middle; }
a { color: var(--link); text-underline-offset: 3px; }
a:hover { color: var(--link-hover); }
h1, h2, h3 { font-family: var(--display); font-weight: 700; line-height: 1.2; letter-spacing: .01em; text-wrap: balance; margin: 0 0 .5em; color: var(--text); }
h1 { font-size: clamp(1.7rem, 5.2vw, 2.5rem); }
h2 { font-size: clamp(1.25rem, 3.6vw, 1.6rem); }
h3 { font-size: 1.08rem; }
p { margin: 0 0 1em; }
code { font-size: .86em; word-break: break-all; color: var(--text-2); background: var(--bg-2); padding: 1px 5px; border-radius: 5px; }
kbd { display: inline-block; min-width: 2.2em; text-align: center; font: 700 .82rem/1.5 var(--font); padding: 1px 7px; border: 1px solid var(--line-2); border-bottom-width: 3px; border-radius: 6px; background: var(--panel-2); color: var(--text); }
:focus-visible { outline: 3px solid #2f6fe0; outline-offset: 2px; border-radius: 4px; }
[hidden] { display: none !important; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--gold); color: #111; padding: 8px 14px; border-radius: 8px; z-index: 100; }
.skip:focus { left: 8px; }
.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: 16px; }
.page { padding-block: 24px 52px; }
.page-end { height: 52px; }
.muted { color: var(--muted); }
.small { font-size: .875rem; }
.center { text-align: center; }
.bad { color: var(--err-text); font-weight: 700; }
.good { color: var(--ok-text); font-weight: 700; }
.lead { font-size: 1.08rem; color: var(--text-2); max-width: 68ch; }
.eyebrow { text-transform: uppercase; letter-spacing: .16em; font-size: .78rem; color: var(--gold-text); font-weight: 800; margin-bottom: .6em; }

/* ---------- botones */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 10px 20px;
  border: 1px solid transparent; border-radius: 10px; font: 700 1rem/1.2 var(--font); text-decoration: none; cursor: pointer;
  transition: background-color .15s, border-color .15s, transform .15s, box-shadow .15s; color: #fff; text-align: center;
}
.btn:hover { transform: translateY(-1px); color: #fff; }
.btn:active { transform: none; }
.btn[disabled] { opacity: .5; cursor: not-allowed; transform: none; }
.btn-primary { background: linear-gradient(180deg, var(--crimson-2), var(--crimson)); box-shadow: 0 6px 16px rgba(196, 22, 42, .28); }
.btn-primary:hover { background: linear-gradient(180deg, #ea3a4f, #b3122a); }
.btn-green { background: linear-gradient(180deg, var(--green-2), var(--green)); box-shadow: 0 6px 16px rgba(35, 138, 67, .26); }
.btn-green:hover { background: linear-gradient(180deg, #35b25b, #1d7a3a); }
.btn-gold { background: linear-gradient(180deg, var(--gold-2), var(--gold)); color: #2a1e04; box-shadow: 0 4px 12px rgba(217, 181, 108, .35); }
.btn-gold:hover { color: #000; }
.btn-ghost { background: var(--panel); border-color: var(--line-2); color: var(--text); }
.btn-ghost:hover { border-color: var(--crimson); color: var(--link); background: var(--panel-2); }
.btn-light { background: rgba(255, 255, 255, .94); color: #172033; border-color: rgba(255, 255, 255, .6); }
.btn-light:hover { background: #fff; color: #a91228; }
.btn-danger { background: transparent; border-color: var(--err-line); color: var(--err-text); }
.btn-danger:hover { background: var(--err-bg); color: var(--err-text); }
.btn-sm { min-height: 38px; padding: 7px 14px; font-size: .9rem; }
.btn-lg { min-height: 52px; padding: 14px 28px; font-size: 1.08rem; }
.btn-block { width: 100%; }

/* ---------- cabecera (oscura en los dos temas: el logo está hecho para fondo oscuro) */
.top { position: sticky; top: 0; z-index: 50; background: var(--head); color: var(--head-text); box-shadow: 0 2px 14px rgba(10, 14, 26, .25); border-bottom: 3px solid var(--crimson); }
.topbar { display: none; background: var(--head-2); border-bottom: 1px solid var(--head-line); font-size: .82rem; }
.topbar-in { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 34px; }
.topbar-tools { display: flex; align-items: center; gap: 10px; }
.top-in { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 62px; flex-wrap: wrap; }
.brand img { height: 40px; width: auto; display: block; }
.burger { display: inline-flex; flex-direction: column; justify-content: center; gap: 5px; width: 44px; height: 44px; padding: 10px; background: transparent; border: 1px solid var(--head-line); border-radius: 10px; cursor: pointer; }
.burger span { display: block; height: 2px; background: var(--head-text); border-radius: 2px; transition: transform .2s, opacity .2s; }
.burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
.menu { display: none; flex-basis: 100%; padding-bottom: 14px; }
.menu.open { display: block; }
.menu ul { list-style: none; margin: 0; padding: 0; }
.menu ul a { display: block; padding: 12px 6px; color: var(--head-text); text-decoration: none; font-weight: 600; border-bottom: 1px solid var(--head-line); }
.menu ul a[aria-current="page"] { color: var(--gold-2); }
.menu-user { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; padding-top: 14px; }
.menu-user form { margin: 0; }
.top .btn-ghost { background: rgba(255, 255, 255, .06); border-color: var(--head-line); color: var(--head-text); }
.top .btn-ghost:hover { border-color: var(--gold); background: rgba(217, 181, 108, .12); color: #fff; }
.menu-user a[aria-current="page"] { border-color: var(--gold); }
.menu-extra { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; padding-top: 14px; margin-top: 14px; border-top: 1px solid var(--head-line); }
@media (min-width: 960px) {
  .topbar { display: block; }
  .top-in { flex-wrap: nowrap; }
  .burger, .menu-extra { display: none; }
  .menu { display: flex; flex: 1; flex-basis: auto; align-items: center; justify-content: space-between; gap: 16px; padding: 0; margin-left: 18px; }
  .menu ul { display: flex; gap: 2px; }
  .menu ul a { border: 0; padding: 8px 13px; border-radius: 8px; font-size: .97rem; }
  .menu ul a:hover { background: rgba(255, 255, 255, .08); }
  .menu ul a[aria-current="page"] { background: rgba(217, 181, 108, .14); }
  .menu-user { padding: 0; flex-wrap: nowrap; }
  .brand img { height: 46px; }
}

/* idiomas, tema y redes */
.langs { display: inline-flex; gap: 2px; align-items: center; }
.langs a { display: inline-flex; align-items: center; gap: 5px; padding: 3px 7px; border-radius: 6px; color: var(--head-muted); text-decoration: none; font-weight: 700; font-size: .78rem; letter-spacing: .04em; border: 1px solid transparent; }
.langs a:hover { color: #fff; background: rgba(255, 255, 255, .08); }
.langs a[aria-current="true"] { color: #fff; border-color: var(--head-line); background: rgba(255, 255, 255, .07); }
.flag { border-radius: 2px; box-shadow: 0 0 0 1px rgba(255, 255, 255, .25); flex: none; }
.theme-btn { display: inline-grid; place-items: center; width: 30px; height: 26px; border-radius: 6px; border: 1px solid var(--head-line); background: rgba(255, 255, 255, .06); color: var(--gold-2); cursor: pointer; padding: 0; }
.theme-btn:hover { background: rgba(255, 255, 255, .14); color: #fff; }
.theme-btn .i-sun { display: none; }
html[data-theme="dark"] .theme-btn .i-sun { display: block; }
html[data-theme="dark"] .theme-btn .i-moon { display: none; }
.social { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.soc { display: inline-grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; color: #fff; background: #3a4563; text-decoration: none; transition: transform .15s, filter .15s; }
.soc:hover { transform: translateY(-2px); filter: brightness(1.12); color: #fff; }
.soc-facebook { background: #1877f2; } .soc-instagram { background: linear-gradient(45deg, #f09433, #dc2743 55%, #bc1888); } .soc-tiktok { background: #010101; box-shadow: inset 0 0 0 1px #3b3b3b; }
.soc-whatsapp { background: #1faa55; } .soc-discord { background: #5865f2; } .soc-forum { background: var(--crimson); }
.social-sm .soc { width: 26px; height: 26px; }
.menu-extra .social-sm .soc { width: 34px; height: 34px; }
.social-lg .soc { width: auto; height: auto; border-radius: 10px; padding: 9px 16px 9px 12px; gap: 8px; display: inline-flex; font-weight: 700; }

/* ---------- portada */
.hero { position: relative; overflow: hidden; isolation: isolate; background: #101627; color: #fff; }
.hero-slides { position: absolute; inset: 0; z-index: -2; }
.hero-slide { position: absolute; inset: 0; opacity: 0; transition: opacity 1.2s ease; }
.hero-slide.on { opacity: 1; }
.hero-slide img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 45%; display: block; }
.hero::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(9, 14, 28, .86) 0%, rgba(9, 14, 28, .55) 46%, rgba(9, 14, 28, .05) 100%), linear-gradient(180deg, rgba(9, 14, 28, .25) 0%, rgba(9, 14, 28, 0) 40%, rgba(9, 14, 28, .55) 100%); }
.hero-in { padding-block: 40px 28px; }
.hero h1 { font-size: clamp(1.9rem, 7vw, 3.3rem); color: #fff; text-shadow: 0 2px 18px rgba(0, 0, 0, .65); max-width: 17ch; }
.hero .eyebrow { color: var(--gold-2); }
.hero .lead { color: #e8ecf6; text-shadow: 0 1px 8px rgba(0, 0, 0, .6); max-width: 54ch; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 10px; margin: 20px 0 6px; align-items: center; }
.hero-cta .btn { flex: 1 1 220px; }
.stats { list-style: none; display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; padding: 0; margin: 24px 0 0; }
.stats li { background: rgba(255, 255, 255, .95); color: #172033; border: 1px solid rgba(255, 255, 255, .7); border-radius: var(--radius); padding: 11px 14px; display: flex; flex-direction: column; box-shadow: 0 6px 20px rgba(0, 0, 0, .25); }
.stats b { font-size: 1.3rem; font-family: var(--display); display: flex; align-items: center; gap: 8px; }
.stats span:last-child { color: #586379; font-size: .82rem; }
html[data-theme="dark"] .stats li { background: rgba(23, 27, 38, .9); color: #ecebf1; border-color: #2a3142; }
html[data-theme="dark"] .stats span:last-child { color: #a4aabb; }
/* en el teléfono la foto queda detrás del texto: se oscurece más para que se lea */
@media (max-width: 719px) { .hero::after { background: linear-gradient(180deg, rgba(9, 14, 28, .8) 0%, rgba(9, 14, 28, .7) 60%, rgba(9, 14, 28, .82) 100%); } }
@media (min-width: 720px) {
  .hero-in { padding-block: 84px 46px; }
  .hero-cta .btn { flex: 0 0 auto; }
  .stats { grid-template-columns: repeat(4, 1fr); max-width: 780px; }
}

.section { margin-top: 36px; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 12px; flex-wrap: wrap; }
.section-head h2 { margin: 0; }
.section-head h2::after { content: ""; display: block; width: 44px; height: 3px; border-radius: 3px; background: var(--crimson); margin-top: 6px; }
.card .section-head h2::after { display: none; }
.section-head a { font-size: .9rem; white-space: nowrap; font-weight: 600; }
.cols { display: grid; gap: 8px 28px; }
@media (min-width: 960px) { .cols { grid-template-columns: minmax(0, 1fr) 350px; } }
.side { display: grid; gap: 16px; align-content: start; margin-top: 36px; }

/* promo de Android con el afiche */
.promo { display: grid; gap: 20px; background: linear-gradient(135deg, #0f1a33 0%, #132a4a 55%, #0f3a3a 100%); color: #fff; border-radius: 16px; padding: 20px; overflow: hidden; box-shadow: var(--shadow); }
.promo h2 { color: #fff; font-size: clamp(1.5rem, 4.5vw, 2.1rem); }
.promo .eyebrow { color: #8fe5a8; }
.promo .lead { color: #dbe5f5; }
.promo .dl-meta { color: #b9c6dc; }
.promo .btn-ghost { background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .35); color: #fff; }
.promo .btn-ghost:hover { background: rgba(255, 255, 255, .16); color: #fff; border-color: #fff; }
.promo-img { display: block; max-width: 210px; margin-inline: auto; border-radius: 14px; overflow: hidden; box-shadow: 0 14px 34px rgba(0, 0, 0, .45); transform: rotate(-2deg); transition: transform .2s; }
.promo-img:hover { transform: rotate(0) scale(1.02); }
.promo-img img { display: block; width: 100%; }
.ticks { list-style: none; padding: 0; margin: 0 0 6px; display: grid; gap: 6px; }
.ticks li { padding-left: 28px; position: relative; color: #e6edf8; }
.ticks li::before { content: "✓"; position: absolute; left: 0; top: 0; width: 20px; height: 20px; border-radius: 50%; background: #2fa653; color: #fff; font-size: .78rem; font-weight: 800; display: grid; place-items: center; margin-top: 3px; }
@media (min-width: 760px) { .promo { grid-template-columns: 270px 1fr; align-items: center; padding: 28px 36px; gap: 36px; } .promo-img { margin: 0; max-width: 250px; } }

/* ---------- tarjetas */
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow); }
.card > :last-child { margin-bottom: 0; }
.cards { display: grid; gap: 16px; }
@media (min-width: 720px) { .cards { grid-template-columns: 1fr 1fr; } .card { padding: 24px; } .side .card { padding: 20px; } }
.narrow { max-width: 520px; margin-inline: auto; }
.crumb { font-size: .85rem; margin-bottom: 8px; font-weight: 600; }
.crumb a::before { content: "‹ "; }

/* ---------- descargas */
.dl-grid { display: grid; gap: 14px; }
@media (min-width: 760px) { .dl-grid { grid-template-columns: repeat(3, 1fr); } }
.dl-card { position: relative; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; display: flex; flex-direction: column; box-shadow: var(--shadow); }
.dl-card h3 { font-size: 1.3rem; margin-bottom: 4px; }
.dl-card p.muted { flex: 1; font-size: .94rem; }
.dl-ico { width: 54px; height: 54px; display: grid; place-items: center; border-radius: 12px; background: #fdeef0; color: var(--crimson); margin-bottom: 12px; }
.dl-android { border-color: #8fd0a3; box-shadow: 0 0 0 1px rgba(47, 166, 83, .14), 0 10px 26px rgba(35, 138, 67, .12); }
.dl-android .dl-ico { color: var(--green); background: #e7f6ec; }
.dl-play .dl-ico { color: #2f6fe0; background: #e9f0fd; }
html[data-theme="dark"] .dl-ico { background: rgba(255, 255, 255, .06); color: var(--gold-2); }
html[data-theme="dark"] .dl-android .dl-ico { color: #6fe08f; }
.dl-meta { font-size: .84rem; color: var(--muted); margin: 10px 0 0; }
.tag { position: absolute; top: 14px; right: 14px; background: var(--green); color: #fff; font-size: .72rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; padding: 3px 9px; border-radius: 999px; }
.badge-soon { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 10px 18px; border: 1px dashed var(--line-2); border-radius: 10px; color: var(--muted); font-weight: 700; }
.dl-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.dl-list li { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; }
.dl-list li > div:first-child { display: flex; flex-direction: column; min-width: 0; flex: 1 1 220px; }
.dl-list span.muted { font-size: .86rem; overflow-wrap: anywhere; }
.row-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.row-actions form { margin: 0; }
.android-hero { display: grid; gap: 22px; background: linear-gradient(135deg, #0f1a33 0%, #132a4a 55%, #0f3a3a 100%); border: 0; color: #fff; padding: 22px; }
.android-hero h1 { color: #fff; }
.android-hero .eyebrow { color: #8fe5a8; }
.android-hero .lead { color: #dbe5f5; }
.android-hero .dl-meta { color: #b9c6dc; }
.android-hero .badge-soon { color: #dbe5f5; border-color: rgba(255, 255, 255, .4); }
.android-hero .btn-ghost { background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .35); color: #fff; }
.android-poster { max-width: 280px; margin-inline: auto; border-radius: 14px; overflow: hidden; box-shadow: 0 14px 34px rgba(0, 0, 0, .45); }
.android-poster img { display: block; width: 100%; }
@media (min-width: 760px) { .android-hero { grid-template-columns: 300px 1fr; align-items: center; padding: 34px 40px; gap: 40px; } .android-poster { margin: 0; max-width: none; } }

/* ---------- pasos */
.steps { list-style: none; counter-reset: paso; padding: 0; margin: 0 0 16px; display: grid; gap: 10px; }
.steps li { counter-increment: paso; position: relative; background: var(--panel); border: 1px solid var(--line); border-left: 4px solid var(--crimson); border-radius: 10px; padding: 14px 14px 14px 60px; }
.steps li::before { content: counter(paso); position: absolute; left: 14px; top: 12px; width: 32px; height: 32px; border-radius: 50%; background: var(--crimson); color: #fff; display: grid; place-items: center; font-weight: 800; }
.faq dt { font-weight: 700; margin-top: 14px; }
.faq dd { margin: 2px 0 0; color: var(--text-2); }
.cmd { margin: 0; display: grid; gap: 0; }
.cmd div { display: grid; grid-template-columns: minmax(96px, 38%) 1fr; gap: 12px; padding: 8px 0; border-bottom: 1px solid var(--line); align-items: baseline; }
.cmd div:last-child { border-bottom: 0; }
.cmd dt { font-weight: 700; } .cmd dd { margin: 0; color: var(--text-2); font-size: .95rem; }
.cmd code { word-break: normal; overflow-wrap: anywhere; }

/* ---------- noticias */
.news-list { display: grid; gap: 12px; }
.news-item { display: flex; flex-direction: column; gap: 12px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; text-decoration: none; color: var(--text); transition: border-color .15s, transform .15s, box-shadow .15s; box-shadow: var(--shadow); }
.news-item:hover { border-color: var(--crimson); transform: translateY(-1px); color: var(--text); }
.news-item img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 8px; background: var(--bg-2); }
.news-item time, .art-body time { font-size: .78rem; color: var(--gold-text); text-transform: uppercase; letter-spacing: .08em; font-weight: 700; }
.news-item h3 { margin: 4px 0 6px; font-size: 1.1rem; }
.news-item p { margin: 0; color: var(--muted); font-size: .93rem; overflow-wrap: anywhere; }
.news-first h3 { font-size: 1.4rem; }
@media (min-width: 620px) {
  .news-item:not(.news-first) { flex-direction: row; align-items: center; }
  .news-item:not(.news-first) img { width: 190px; flex: none; }
}
.info-banner { display: flex; align-items: center; gap: 14px; margin-top: 16px; padding: 16px 18px; border-radius: var(--radius); border: 1px solid var(--info-line); background: var(--info-bg); color: var(--info-text); text-decoration: none; }
.info-banner > span:nth-child(2) { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.info-banner b { font-family: var(--display); font-size: 1.12rem; color: var(--text); }
.info-banner:hover { border-color: var(--crimson); color: var(--info-text); }

/* listas de guías / noticias / changelogs */
.art-grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.art-card { display: flex; flex-direction: column; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; text-decoration: none; color: var(--text); box-shadow: var(--shadow); transition: border-color .15s, transform .15s; }
.art-card:hover { border-color: var(--crimson); transform: translateY(-2px); color: var(--text); }
.art-img { display: grid; place-items: center; aspect-ratio: 16 / 9; background: linear-gradient(135deg, #e6ecf7, #d5deee); color: #8b97ae; overflow: hidden; }
html[data-theme="dark"] .art-img { background: linear-gradient(135deg, #1d2230, #141823); color: #59627a; }
.art-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.art-body { display: flex; flex-direction: column; gap: 4px; padding: 14px 16px 16px; }
.art-body b { font-family: var(--display); font-size: 1.12rem; line-height: 1.25; overflow-wrap: anywhere; }
.art-body > span { color: var(--muted); font-size: .92rem; overflow-wrap: anywhere; }
.art-plain { grid-template-columns: 1fr; gap: 10px; }
.art-plain .art-card { border-left: 4px solid var(--crimson); }
.article { max-width: 880px; margin-inline: auto; }
.article-date { color: var(--gold-text); font-size: .82rem; text-transform: uppercase; letter-spacing: .08em; font-weight: 700; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.article-wide .prose { max-width: none; }
.article-nav { max-width: 880px; margin: 16px auto 0; display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.article-nav a { display: flex; flex-direction: column; gap: 2px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel); text-decoration: none; color: var(--text); min-width: 0; }
.article-nav a:hover { border-color: var(--crimson); }
.article-nav span { font-size: .78rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.article-nav b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.article-nav .next { text-align: right; grid-column: 2; }

/* Texto escrito con el editor. Las notas viejas traen colores pensados para fondo blanco,
   por eso el cuerpo del artículo va SIEMPRE sobre papel claro, también en el tema oscuro. */
.prose { overflow-wrap: anywhere; color: #1b2233; font-size: 1.02rem; line-height: 1.7; }
html[data-theme="dark"] .prose { background: #f6f7fa; border-radius: 10px; padding: 16px; margin-top: 14px; }
.prose > :first-child { margin-top: 0; } .prose > :last-child { margin-bottom: 0; }
.prose h1, .prose h2, .prose h3, .prose h4 { color: #1b2233; margin: 1.1em 0 .5em; }
.prose h1 { font-size: 1.6rem; } .prose h2 { font-size: 1.35rem; } .prose h3 { font-size: 1.12rem; }
.prose p { margin: 0 0 .9em; }
.prose img { height: auto !important; max-width: 100% !important; border-radius: 8px; }
.prose a { color: #a91228; font-weight: 600; }
.prose ul, .prose ol { padding-left: 1.4em; margin: 0 0 1em; }
.prose blockquote { margin: 0 0 1em; padding: 10px 16px; border-left: 4px solid #c4162a; background: #f3f5fa; border-radius: 0 8px 8px 0; }
.prose table { display: block; max-width: 100%; overflow-x: auto; border-collapse: collapse; margin: 0 0 1em; }
.prose td, .prose th { border: 1px solid #cfd6e3; padding: 6px 10px; }
.prose th { background: #eef1f7; }
.prose iframe { display: block; width: 100%; max-width: 720px; height: auto; aspect-ratio: 16 / 9; margin: 0 auto 1em; border: 0; border-radius: 10px; background: #000; }
.prose hr { border: 0; border-top: 1px solid #d9e0ec; margin: 1.4em 0; }
.prose pre { background: #f3f5fa; padding: 12px; border-radius: 8px; overflow-x: auto; }
.prose .marker { background: transparent; }
.prose div[style*="background"] { border-radius: 8px; }

/* ---------- pestañas y filtros */
.tabs, .chips { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 6px; margin: 4px 0 14px; scrollbar-width: thin; }
.tabs a, .chips a { flex: none; padding: 9px 16px; border-radius: 999px; border: 1px solid var(--line-2); background: var(--panel); color: var(--text); text-decoration: none; font-weight: 600; font-size: .93rem; }
.tabs a:hover, .chips a:hover { border-color: var(--crimson); color: var(--link); }
.chips a { padding: 6px 13px; font-size: .86rem; }
.tabs a[aria-current="page"] { background: var(--crimson); border-color: var(--crimson); color: #fff; }
.chips a[aria-current="page"] { border-color: var(--crimson); color: var(--link); background: var(--err-bg); }
.rank-tools { display: flex; gap: 10px 18px; flex-wrap: wrap; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.rank-tools p { margin: 0; font-size: .9rem; }
.rank-tools .input { max-width: 260px; }

/* ---------- tablas */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); box-shadow: var(--shadow); }
table.rank { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.rank th, .rank td { padding: 10px 12px; text-align: left; border-bottom: 1px solid var(--line); white-space: nowrap; }
.rank thead th { font-size: .76rem; text-transform: uppercase; letter-spacing: .08em; color: var(--head-muted); background: var(--head); }
.rank tbody tr:last-child td { border-bottom: 0; }
.rank tbody tr:nth-child(even) { background: var(--panel-2); }
.rank tbody tr:hover { background: var(--bg-2); }
.rank .num { text-align: right; }
.rank .n { width: 44px; color: var(--muted); font-weight: 700; }
.rank .who { display: table-cell; }
.rank .who > * { vertical-align: middle; margin-right: 8px; }
.rank .who a { display: inline-block; color: var(--text); font-weight: 700; text-decoration: none; }
.rank .who a:hover { color: var(--link); text-decoration: underline; }
.rank td a { font-weight: 600; }
.rank small { color: var(--muted); font-size: .76rem; }
.rank .top1 td.n, .rank .top2 td.n, .rank .top3 td.n { font-weight: 800; }
.rank .top1 td.n { color: #a87400; } .rank .top2 td.n { color: #6b7385; } .rank .top3 td.n { color: #a2602d; }
html[data-theme="dark"] .rank .top1 td.n { color: #f6d77a; } html[data-theme="dark"] .rank .top2 td.n { color: #d5d8e0; } html[data-theme="dark"] .rank .top3 td.n { color: #d79a66; }
.rank tbody tr.top1 { background: linear-gradient(90deg, rgba(240, 213, 149, .45), transparent 60%); }
html[data-theme="dark"] .rank tbody tr.top1 { background: linear-gradient(90deg, rgba(246, 215, 122, .1), transparent 60%); }
.avatar { border-radius: 8px; object-fit: cover; flex: none; background: var(--bg-2); }
.gmark { border-radius: 4px; flex: none; image-rendering: pixelated; }
.show-sm { display: inline; }
.hide-sm { display: none; }
@media (min-width: 720px) { .show-sm { display: none; } .hide-sm { display: table-cell; } }
.dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: #9aa3b5; flex: none; }
.dot.on { background: #22b455; box-shadow: 0 0 0 3px rgba(34, 180, 85, .2); }

.mini-rank { list-style: none; padding: 0; margin: 0; counter-reset: pos; display: grid; gap: 8px; }
.mini-rank li { counter-increment: pos; display: flex; align-items: center; gap: 10px; }
.mini-rank li::before { content: counter(pos); width: 18px; color: var(--muted); font-weight: 700; font-size: .9rem; }
.mini-rank a, .mini-rank b { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; color: var(--text); font-weight: 700; text-decoration: none; }
.mini-rank a:hover { color: var(--link); }
.mini-rank span { color: var(--gold-text); font-size: .88rem; font-variant-numeric: tabular-nums; font-weight: 700; }
.meter { height: 12px; border-radius: 999px; background: var(--bg-2); border: 1px solid var(--line); overflow: hidden; margin: 6px 0 8px; }
.meter span { display: block; height: 100%; background: linear-gradient(90deg, var(--crimson), var(--gold)); border-radius: 999px; min-width: 6px; }

/* ---------- equipo */
.staff { list-style: none; padding: 0; margin: 0 0 12px; display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.staff li { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; display: flex; align-items: center; gap: 12px; box-shadow: var(--shadow); }
.staff li > div { display: flex; flex-direction: column; flex: 1; min-width: 0; line-height: 1.3; }
.staff b { overflow-wrap: anywhere; }
.staff .muted { font-size: .86rem; }
.staff .state { flex: none; font-size: .78rem; font-weight: 700; display: inline-flex; align-items: center; gap: 6px; padding: 3px 9px; border-radius: 999px; background: var(--bg-2); color: var(--muted); white-space: nowrap; }
.staff .state.on { background: var(--ok-bg); color: var(--ok-text); }
.staff-compact { grid-template-columns: 1fr; gap: 0; }
.staff-compact li { border: 0; border-bottom: 1px solid var(--line); border-radius: 0; padding: 9px 0; box-shadow: none; background: none; }
.staff-compact li:last-child { border-bottom: 0; }

/* ---------- castillo */
.castle { border-top: 4px solid var(--gold); }
.castle-owner { display: flex; align-items: center; gap: 14px; }
.castle-owner > div { display: flex; flex-direction: column; min-width: 0; line-height: 1.35; }
.castle-guild { font-family: var(--display); font-size: 1.45rem; overflow: hidden; text-overflow: ellipsis; }
.castle-owner .gmark { border-radius: 8px; box-shadow: 0 0 0 2px var(--gold), 0 4px 12px rgba(0, 0, 0, .2); }
.castle-ally { margin: 12px 0 0; display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; font-size: .9rem; }
.ally { display: inline-flex; align-items: center; gap: 5px; font-weight: 700; }
.castle-next { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); display: flex; flex-direction: column; gap: 2px; }
.castle-next .muted { font-size: .78rem; text-transform: uppercase; letter-spacing: .08em; }
.countdown { font-family: var(--display); font-size: 1.3rem; font-weight: 700; color: var(--link); font-variant-numeric: tabular-nums; min-height: 1.6em; }
.castle-live { color: var(--link); font-size: 1.1rem; }

/* ---------- facebook */
.fb-box { position: relative; min-height: 130px; border-radius: 10px; overflow: hidden; background: var(--bg-2); display: grid; }
.fb-box iframe { position: relative; z-index: 1; display: block; width: 100%; height: 500px; border: 0; background: transparent; }
.fb-fallback { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; text-decoration: none; color: #1877f2; font-weight: 700; padding: 20px; text-align: center; }
html[data-theme="dark"] .fb-fallback { color: #7fb3ff; }

/* ---------- galería */
.gallery { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (min-width: 620px) { .gallery { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 960px) { .gallery { grid-template-columns: repeat(4, 1fr); } .gallery a:first-child { grid-column: span 2; grid-row: span 2; } }
.gallery a { display: block; border-radius: 10px; overflow: hidden; background: var(--bg-2); box-shadow: var(--shadow); aspect-ratio: 4 / 3; }
.gallery img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.gallery a:hover img { transform: scale(1.05); }
/* con 7 fotos, las dos últimas ocupan el doble de ancho para cerrar la grilla */
@media (min-width: 960px) { .gallery a:first-child:nth-last-child(7) ~ a:nth-last-child(-n+2) { grid-column: span 2; aspect-ratio: 8 / 3; } }
@media (max-width: 619px) { .gallery a:first-child:nth-last-child(odd) { grid-column: span 2; } }
.lightbox { position: fixed; inset: 0; z-index: 200; background: rgba(6, 9, 18, .93); display: grid; place-items: center; padding: 12px; }
.lightbox img { max-width: 100%; max-height: calc(100vh - 90px); border-radius: 8px; box-shadow: 0 10px 50px rgba(0, 0, 0, .6); }
.lightbox button { position: absolute; background: rgba(255, 255, 255, .12); color: #fff; border: 1px solid rgba(255, 255, 255, .3); border-radius: 50%; width: 46px; height: 46px; font-size: 1.4rem; cursor: pointer; line-height: 1; }
.lightbox button:hover { background: rgba(255, 255, 255, .25); }
.lightbox .lb-close { top: 14px; right: 14px; } .lightbox .lb-prev { left: 12px; top: 50%; margin-top: -23px; } .lightbox .lb-next { right: 12px; top: 50%; margin-top: -23px; }
.lightbox .lb-n { position: absolute; bottom: 14px; left: 0; right: 0; text-align: center; color: #cdd5e6; font-size: .9rem; }

/* ---------- datos */
.kv { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin: 16px 0 0; }
.kv div { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; }
.kv dt { font-size: .76rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.kv dd { margin: 2px 0 0; font-weight: 700; font-size: 1.1rem; }
.kv-wide { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.kv-wide div { box-shadow: var(--shadow); border-top: 3px solid var(--crimson); }
.kv-list { grid-template-columns: 1fr; gap: 0; margin: 0 0 14px; }
.kv-list div { display: flex; justify-content: space-between; gap: 12px; background: none; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; padding: 9px 0; }
.kv-list dt { text-transform: none; letter-spacing: 0; font-size: .95rem; }
.kv-list dd { font-size: .95rem; font-weight: 600; text-align: right; overflow-wrap: anywhere; }
.profile-head { display: flex; align-items: center; gap: 16px; }
.profile-head h1 { margin: 0; }
.profile-head p { margin: 0; }
.profile .kv div { background: var(--panel-2); }

/* ---------- formularios */
.form { display: grid; gap: 6px; }
.form label { font-weight: 600; margin-top: 10px; }
.form small { color: var(--muted); font-size: .84rem; }
.form .btn { margin-top: 16px; }
.form-wide .btn { justify-self: start; }
.input { width: 100%; min-height: 46px; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--input-line); background: var(--input-bg); color: var(--text); font: inherit; }
textarea.input { font-family: ui-monospace, Consolas, monospace; font-size: .9rem; line-height: 1.5; resize: vertical; }
.input:focus { border-color: var(--crimson); outline: 3px solid rgba(196, 22, 42, .18); outline-offset: 0; }
.input::placeholder { color: #8b95a8; }
.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400 !important; font-size: .93rem; }
.check input { width: 20px; height: 20px; margin-top: 2px; accent-color: var(--crimson); flex: none; }
.form-foot { margin-top: 18px; font-size: .93rem; text-align: center; }
.g-recaptcha { margin-top: 12px; }

.alert { border: 1px solid var(--line); border-left-width: 4px; border-radius: 10px; padding: 12px 14px; margin: 0 auto 16px; background: var(--panel); }
.alert-success { border-color: var(--ok-line); background: var(--ok-bg); color: var(--ok-text); }
.alert-error { border-color: var(--err-line); background: var(--err-bg); color: var(--err-text); }
.alert-info { border-color: var(--info-line); background: var(--info-bg); color: var(--info-text); }
main > .alert.wrap { margin-top: 16px; }

/* ---------- donaciones */
.packs { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; margin-bottom: 20px; }
.pack { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 14px; text-align: center; display: flex; flex-direction: column; gap: 2px; margin: 0; box-shadow: var(--shadow); }
.pack b { font-family: var(--display); font-size: 1.5rem; color: var(--gold-text); }
.pack span { color: var(--muted); font-size: .88rem; }
.pack em { font-style: normal; color: var(--green); font-size: .84rem; font-weight: 700; }
.pack .btn { margin-top: 12px; padding-inline: 8px; }
.pack-vip { border-color: var(--gold); border-top-width: 4px; }

/* ---------- tienda */
.shop-grid { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); }
.shop-item { display: flex; flex-direction: column; gap: 4px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; text-decoration: none; color: var(--text); box-shadow: var(--shadow); transition: border-color .15s, transform .15s; }
.shop-item:hover { border-color: var(--crimson); transform: translateY(-2px); color: var(--text); }
.shop-item b { font-family: var(--display); font-size: 1.08rem; overflow-wrap: anywhere; }
.shop-item .muted { font-size: .84rem; flex: 1; }
.shop-tag { align-self: flex-start; margin-top: 6px; background: linear-gradient(180deg, var(--gold-2), var(--gold)); color: #2a1e04; font-weight: 800; padding: 3px 12px; border-radius: 999px; }
.shop-tag small { font-weight: 600; }
.shop-price { font-size: 1.1rem; } .shop-price b { font-family: var(--display); font-size: 2.2rem; color: var(--gold-text); }
.rows .row-shop { grid-template-columns: 78px minmax(0, 2.4fr) minmax(0, 1.2fr) repeat(5, minmax(0, .7fr)) 28px auto; }
.row-shop.off { opacity: .62; }
.row-shop .check { margin: 0; justify-content: center; }
@media (max-width: 959px) { .rows .row-shop { grid-template-columns: repeat(4, 1fr); padding: 10px; border: 1px solid var(--line); border-radius: 10px; } .row-shop input[name="nombre"] { grid-column: span 3; } .row-shop .row-tools { grid-column: 1 / -1; } }

/* ---------- administración: ajustes */
.set { margin-top: 18px; scroll-margin-top: 110px; }
.set h3 { margin-top: 20px; }
.grid4 { display: grid; gap: 6px 14px; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); }
.grid4 > div { display: grid; gap: 6px; }
.checks { display: grid; gap: 10px 18px; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); margin-top: 6px; }
.checks .check { margin: 0; }
.rows { display: grid; gap: 8px; margin-top: 6px; }
.row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.5fr) auto; gap: 8px; align-items: center; }
.row5 { grid-template-columns: repeat(5, minmax(0, 1fr)) auto; }
.row4 { grid-template-columns: minmax(0, 1.6fr) repeat(3, minmax(0, 1fr)) auto; }
.row .input { min-height: 40px; padding: 7px 10px; }
.row-tools { display: inline-flex; gap: 4px; }
.row-tools .btn { margin: 0; min-height: 36px; padding: 4px 10px; }
.form .rows + .btn { margin-top: 8px; }
@media (max-width: 719px) { .row, .row5, .row4 { grid-template-columns: 1fr 1fr; padding: 10px; border: 1px solid var(--line); border-radius: 10px; } .row-tools { grid-column: 1 / -1; } }
.status { list-style: none; padding: 0; margin: 0; display: grid; gap: 0; }
.status li { display: grid; grid-template-columns: 28px minmax(0, 1fr); gap: 2px 10px; padding: 9px 0; border-bottom: 1px solid var(--line); align-items: start; }
.status li:last-child { border-bottom: 0; }
.status li > span:last-child { grid-column: 2; color: var(--muted); font-size: .9rem; overflow-wrap: anywhere; }
.st-ico { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: .8rem; color: #fff; grid-row: span 2; }
.status .ok .st-ico { background: #22a34e; } .status .no .st-ico { background: #d02238; } .status .warn .st-ico { background: #d79a1c; }
@media (min-width: 720px) { .status li { grid-template-columns: 28px 340px minmax(0, 1fr); } .status li > span:last-child { grid-column: 3; } .st-ico { grid-row: auto; } }
.jodit-container:not(.jodit_inline) { border-radius: 10px; overflow: hidden; border-color: var(--input-line) !important; }
.jodit-wysiwyg { color: #1b2233; background: #fff; }

/* ---------- pie */
.foot { background: var(--head); color: var(--head-muted); border-top: 3px solid var(--crimson); padding: 32px 0 18px; margin-top: 36px; }
.foot-in { display: grid; gap: 24px; }
.foot-text { color: var(--head-muted); margin: 10px 0 12px; max-width: 40ch; }
.foot nav { display: flex; flex-wrap: wrap; gap: 4px 18px; align-content: start; }
.foot nav a { color: var(--head-text); text-decoration: none; padding: 5px 0; }
.foot nav a:hover { color: var(--gold-2); text-decoration: underline; }
.foot-lang { padding-top: 10px; }
.foot .langs a { padding-block: 3px; }
.legal { color: #8b93a9; font-size: .8rem; margin-top: 22px; margin-bottom: 0; padding-top: 14px; border-top: 1px solid var(--head-line); }
@media (min-width: 720px) { .foot-in { grid-template-columns: 1.4fr 1fr 1fr; } .foot nav { flex-direction: column; flex-wrap: nowrap; } }

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; scroll-behavior: auto !important; }
}

/* ---------- tablas en teléfono: menos aire y el dato secundario debajo, para que entre sin deslizar */
@media (max-width: 719px) {
  .rank th, .rank td { padding: 9px 8px; }
  .rank .n { width: 30px; }
  .rank td.num small { display: block; }
  .rank .who a { max-width: 11ch; overflow: hidden; text-overflow: ellipsis; }
  .article-nav { grid-template-columns: 1fr; } .article-nav .next { grid-column: 1; text-align: left; }
}

/* =====================================================================================
   ANIMACIONES LIVIANAS (solo transform y opacity) Y TEMAS DE TEMPORADA
   Se prenden con html.fx-on (lo pone assets/js/fx.js). Sin esa clase la página queda quieta:
   visitantes con "menos movimiento", ahorro de datos, o que las apagaron con el botón.
   ===================================================================================== */
.hero-in { position: relative; z-index: 1; }
.fx-embers { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; }
.fx-season { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 60; pointer-events: none; }
.fx-btn[aria-pressed="false"] { opacity: .5; }
html.fx-off .fx-btn { opacity: .5; }

/* foto de la portada: acercamiento muy lento (se frena cuando la portada sale de la pantalla) */
.fx-on .hero-slide.on img { animation: fx-kb 24s ease-in-out infinite alternate; will-change: transform; }
.fx-on .hero.fx-paused .hero-slide img { animation-play-state: paused; }
@keyframes fx-kb { from { transform: scale(1) translate3d(0, 0, 0); } to { transform: scale(1.09) translate3d(-1.5%, -1%, 0); } }

/* aparecer al bajar */
.fx-on .reveal { opacity: 0; transform: translate3d(0, 22px, 0); transition: opacity .55s ease, transform .55s ease; }
.fx-on .reveal.in { opacity: 1; transform: none; }

/* botón principal con resplandor (anima la opacidad de una capa, no la sombra) */
.btn-glow { position: relative; }
.fx-on .btn-glow::after { content: ""; position: absolute; inset: -3px; border-radius: 13px; box-shadow: 0 0 22px 7px rgba(240, 70, 90, .6); opacity: 0; animation: fx-glow 2.8s ease-in-out infinite; pointer-events: none; }
@keyframes fx-glow { 0%, 100% { opacity: 0; } 50% { opacity: 1; } }

/* brillo que cruza el logo cada tanto */
.brand { position: relative; display: block; overflow: hidden; border-radius: 6px; }
.fx-on .brand::after { content: ""; position: absolute; top: -20%; bottom: -20%; left: 0; width: 34%; background: linear-gradient(100deg, transparent, rgba(255, 244, 210, .34), transparent); transform: translate3d(-140%, 0, 0) skewX(-18deg); animation: fx-shine 7s ease-in-out infinite; pointer-events: none; }
@keyframes fx-shine { 0%, 62% { transform: translate3d(-140%, 0, 0) skewX(-18deg); } 100% { transform: translate3d(420%, 0, 0) skewX(-18deg); } }

/* castillo: destello que recorre el borde dorado, y la cuenta regresiva late */
.castle { position: relative; overflow: hidden; }
.fx-on .castle::before { content: ""; position: absolute; top: 0; left: 0; height: 3px; width: 38%; background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .85), transparent); animation: fx-sweep 3.6s linear infinite; }
@keyframes fx-sweep { from { transform: translate3d(-110%, 0, 0); } to { transform: translate3d(290%, 0, 0); } }
.fx-on .countdown { animation: fx-beat 2s ease-in-out infinite; transform-origin: left center; }
@keyframes fx-beat { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.035); } }

/* al pasar el mouse */
.art-img img, .gallery img { transition: transform .35s ease; }
.art-card:hover .art-img img { transform: scale(1.05); }
.rank tbody tr { transition: background-color .15s; }
.rank tbody tr:hover td:first-child { box-shadow: inset 3px 0 0 var(--crimson); }
.rank .who .avatar, .mini-rank .avatar, .staff .avatar { transition: transform .2s ease; }
.rank tbody tr:hover .avatar, .mini-rank li:hover .avatar, .staff li:hover .avatar { transform: scale(1.12); }
.soc, .dl-ico { transition: transform .2s ease, filter .15s; }
.dl-card:hover .dl-ico { transform: translate3d(0, -3px, 0) scale(1.06); }

/* ---------- castle siege: página */
.castle-top { align-items: stretch; }
.castle-owner-lg .castle-guild { font-size: 1.9rem; }
.castle-battle .countdown-lg, .countdown-lg { display: block; font-size: clamp(1.8rem, 6vw, 2.6rem); margin: 0 0 12px; }
.castle-stage { margin: 12px 0 0; display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: center; font-size: .92rem; }
.ally-list { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px 16px; }
.ally-list li { display: inline-flex; align-items: center; gap: 6px; }
.pill { display: inline-block; padding: 2px 10px; border-radius: 999px; font-size: .78rem; font-weight: 800; background: var(--bg-2); color: var(--muted); white-space: nowrap; }
.pill-on { background: var(--ok-bg); color: var(--ok-text); }
.pill-off { background: var(--err-bg); color: var(--err-text); }
.pill-sign { background: linear-gradient(180deg, var(--gold-2), var(--gold)); color: #2a1e04; font-size: .9rem; }
.rank tbody tr.stage-now { background: var(--info-bg); }
.sched td { white-space: normal; }

/* ---------- cartel del evento */
.season-bar { margin: 0; padding: 7px 16px; text-align: center; font-weight: 700; font-size: .95rem; color: #fff; background: var(--crimson); }
html[data-evento="navidad"] .season-bar { background: linear-gradient(90deg, #a5121f, #1c7d43 50%, #a5121f); }
html[data-evento="anionuevo"] .season-bar { background: linear-gradient(90deg, #1b2440, #6a4d0c 50%, #1b2440); color: #ffe9a8; }
html[data-evento="halloween"] .season-bar { background: linear-gradient(90deg, #2a1433, #c8500a 50%, #2a1433); }
html[data-evento="sanvalentin"] .season-bar { background: linear-gradient(90deg, #b0124b, #f0527f 50%, #b0124b); }
html[data-evento="pascua"] .season-bar { background: linear-gradient(90deg, #6b46b8, #4fa66a 50%, #6b46b8); }

/* ---------- Navidad: guirnalda bajo el menú, gorro en el logo, toques verdes */
html[data-evento="navidad"] .top { border-bottom: 0; }
html[data-evento="navidad"] .top::after { content: ""; display: block; height: 5px; background: repeating-linear-gradient(90deg, #c4162a 0 26px, #1c7d43 26px 52px, #e9c46a 52px 62px); }
html[data-evento="navidad"] .brand { overflow: visible; }
html[data-evento="navidad"] .brand::after { display: none; }
html[data-evento="navidad"] .brand::before { content: ""; position: absolute; left: -9px; top: -7px; width: 30px; height: 26px; transform: rotate(-22deg); z-index: 1; pointer-events: none;
  background: no-repeat center / contain url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 26'%3E%3Cpath d='M3 19C5 9 11 3 18 3c5 0 8 4 10 9l-4 1c-1-3-3-5-6-5 3 3 5 7 5 11z' fill='%23d3202f'/%3E%3Crect x='1' y='18' width='24' height='6' rx='3' fill='%23fff'/%3E%3Ccircle cx='27' cy='13' r='3' fill='%23fff'/%3E%3C/svg%3E"); }
html[data-evento="navidad"] .section-head h2::after { background: linear-gradient(90deg, #c4162a 50%, #1c7d43 50%); width: 60px; }
html[data-evento="navidad"] .foot { border-top-color: #1c7d43; }
html[data-evento="navidad"] .tabs a[aria-current="page"] { background: #1c7d43; border-color: #1c7d43; }

/* ---------- Año Nuevo: dorado */
html[data-evento="anionuevo"] .top { border-bottom-color: var(--gold); }
html[data-evento="anionuevo"] .foot { border-top-color: var(--gold); }
html[data-evento="anionuevo"] .section-head h2::after { background: linear-gradient(90deg, var(--gold) 50%, #c9d1df 50%); width: 60px; }
html[data-evento="anionuevo"] .tabs a[aria-current="page"] { background: #8a6007; border-color: #8a6007; }
html[data-evento="anionuevo"] .kv-wide div { border-top-color: #b9c2d3; }

/* ---------- Halloween: naranja y niebla abajo */
html[data-evento="halloween"] { --crimson: #d0560a; --crimson-2: #f47b20; }
html[data-evento="halloween"]:not([data-theme="dark"]) { --link: #a8440a; --link-hover: #6e2c05; }
html[data-evento="halloween"] .btn-primary { background: linear-gradient(180deg, #f47b20, #d0560a); box-shadow: 0 6px 16px rgba(208, 86, 10, .32); }
html[data-evento="halloween"] .btn-primary:hover { background: linear-gradient(180deg, #ff8d36, #b84a06); }
html[data-evento="halloween"] .top, html[data-evento="halloween"] .foot { background: #1a1024; }
html[data-evento="halloween"] .topbar { background: #120a1a; }
html[data-evento="halloween"] body::after { content: ""; position: fixed; left: 0; right: 0; bottom: 0; height: 130px; z-index: 55; pointer-events: none; background: linear-gradient(0deg, rgba(60, 30, 80, .34), transparent); }
html[data-evento="halloween"].fx-on body::after { animation: fx-fog 7s ease-in-out infinite alternate; }
@keyframes fx-fog { from { opacity: .55; transform: translate3d(0, 10px, 0); } to { opacity: 1; transform: none; } }

/* ---------- San Valentín: rosa */
html[data-evento="sanvalentin"] { --crimson: #d81b60; --crimson-2: #f0527f; }
html[data-evento="sanvalentin"]:not([data-theme="dark"]) { --link: #b0124b; --link-hover: #7a0b33; }
html[data-evento="sanvalentin"] .btn-primary { background: linear-gradient(180deg, #f0527f, #d81b60); box-shadow: 0 6px 16px rgba(216, 27, 96, .3); }
html[data-evento="sanvalentin"] .btn-primary:hover { background: linear-gradient(180deg, #ff6b94, #bf1553); }

/* ---------- Pascua: violeta y verde claro */
html[data-evento="pascua"] { --crimson: #7a4fc0; --crimson-2: #9a6fe0; }
html[data-evento="pascua"]:not([data-theme="dark"]) { --link: #5b35a0; --link-hover: #3c2270; }
html[data-evento="pascua"] .btn-primary { background: linear-gradient(180deg, #9a6fe0, #7a4fc0); box-shadow: 0 6px 16px rgba(122, 79, 192, .3); }
html[data-evento="pascua"] .btn-primary:hover { background: linear-gradient(180deg, #ab84ea, #6941ac); }
html[data-evento="pascua"] .section-head h2::after { background: linear-gradient(90deg, #7a4fc0 50%, #4fa66a 50%); width: 60px; }

@media (prefers-reduced-motion: reduce) {
  .hero-slide img, .btn-glow::after, .brand::after, .castle::before, .countdown, body::after { animation: none !important; }
  .reveal { opacity: 1 !important; transform: none !important; }
}

/* ---------- tienda: dibujos de los ítems (pixel art: sin suavizar) y reglas fijas */
.item-img { image-rendering: pixelated; image-rendering: crisp-edges; flex: none; object-fit: contain; }
.item-none { display: inline-block; border-radius: 6px; background: repeating-linear-gradient(45deg, var(--bg-2) 0 6px, var(--panel-2) 6px 12px); border: 1px dashed var(--line-2); }
.shop-pic { display: grid; place-items: center; height: 132px; margin: -4px -6px 8px; border-radius: 10px; background: radial-gradient(circle at 50% 40%, #2a3350, #131829 75%); overflow: hidden; }
.shop-pic .item-img { max-height: 124px; width: auto; max-width: 100%; }
.shop-head { display: flex; align-items: center; gap: 18px; margin-bottom: 14px; }
.shop-head > .item-img, .shop-head > .item-none { padding: 8px; box-sizing: content-box; border-radius: 12px; background: radial-gradient(circle at 50% 40%, #2a3350, #131829 75%); }
.shop-head h1 { margin: 0 0 6px; } .shop-head p { margin: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.exc-pick { border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; margin: 12px 0 0; display: grid; gap: 8px; }
.exc-pick legend { font-weight: 700; padding: 0 6px; }
.exc-pick input:disabled + span { color: var(--muted); }
.rank .who .item-img { margin-right: 8px; }
.row-pic { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 8px; background: #1a2036; }
.rows .row-shop { grid-template-columns: 40px 78px minmax(0, 2.4fr) minmax(0, 1.2fr) repeat(5, minmax(0, .7fr)) 28px auto; }

/* tienda: ítems FULL (anillos, colgantes y alas) */
.pill-full { background: linear-gradient(180deg, #ff5a6e, #c4162a); color: #fff; letter-spacing: .08em; }
.ticks-dark li { color: var(--text); }

/* ---------- tienda: el baúl dibujado (8 x 15), como en el juego */
.confirm-cards { align-items: start; }
.wh-wrap { --c: min(34px, calc((100vw - 76px) / 8)); display: flex; justify-content: center; }
.wh { position: relative; display: grid; grid-template-columns: repeat(8, var(--c)); grid-template-rows: repeat(15, var(--c)); border: 2px solid #4a4334; border-radius: 6px; background-color: #17130f;
  background-image: linear-gradient(#3a3327 1px, transparent 1px), linear-gradient(90deg, #3a3327 1px, transparent 1px); background-size: var(--c) var(--c); box-shadow: inset 0 0 18px rgba(0, 0, 0, .7); }
.wh-bad { border-color: #c4162a; }
.wh-it { position: relative; display: grid; place-items: center; background: rgba(120, 100, 60, .22); box-shadow: inset 0 0 0 1px rgba(210, 180, 110, .35); cursor: help; min-width: 0; min-height: 0; }
.wh-it img { width: 100%; height: 100%; object-fit: contain; image-rendering: pixelated; image-rendering: crisp-edges; display: block; }
.wh-exc { background: rgba(60, 150, 90, .22); }
.wh-unk { background: #55585f; color: #d5d8de; font-size: calc(var(--c) * .6); }
.wh-new { background: rgba(50, 200, 100, .28); box-shadow: inset 0 0 0 2px #35d06b, 0 0 12px rgba(53, 208, 107, .7); z-index: 2; }
.wh-new img { opacity: .75; }
.fx-on .wh-new { animation: fx-glow-in 1.6s ease-in-out infinite alternate; }
@keyframes fx-glow-in { from { opacity: .7; } to { opacity: 1; } }
.wh-it:hover::after, .wh-it:focus::after { content: attr(data-tip); position: absolute; left: 50%; bottom: calc(100% + 6px); transform: translateX(-50%); z-index: 5; width: max-content; max-width: min(240px, 70vw); padding: 6px 9px; border-radius: 7px; background: #0e1320; color: #fff; font: 600 .78rem/1.35 var(--font); box-shadow: 0 6px 18px rgba(0, 0, 0, .45); white-space: normal; text-align: center; pointer-events: none; }
.wh-key { display: inline-block; width: 12px; height: 12px; border-radius: 3px; vertical-align: middle; }
.wh-key-new { background: #35d06b; }
/* sets */
.set-grid { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
.set-card h2 { font-size: 1.2rem; }
.set-parts { list-style: none; padding: 0; margin: 0 0 10px; display: grid; gap: 4px; }
.set-parts a { display: grid; grid-template-columns: 40px 1fr auto; gap: 10px; align-items: center; padding: 4px 6px; border-radius: 8px; text-decoration: none; color: var(--text); }
.set-parts a:hover { background: var(--bg-2); color: var(--link); }
.set-parts b { color: var(--gold-text); }
.set-total { margin: 0; font-weight: 700; border-top: 1px solid var(--line); padding-top: 8px; }
.fix-list { padding-left: 1.3em; display: grid; gap: 4px; }

/* tienda: comprar el set entero y panel de sets de la administración */
.set-row { display: grid; grid-template-columns: 40px 1fr auto; gap: 10px; align-items: center; padding: 4px 6px; }
.set-row b { color: var(--gold-text); }
.set-card .btn { margin-top: 10px; }
.set-lines { list-style: none; padding: 0; margin: 10px 0; display: grid; gap: 8px; }
.set-line { display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center; justify-content: space-between; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel-2); }
.set-line.set-bad { border-color: var(--err-line); background: var(--err-bg); }
.set-badges { display: flex; flex-wrap: wrap; gap: 4px 6px; margin-top: 6px; }
.set-enable { display: flex; gap: 8px; align-items: center; margin: 0; }
.set-enable .input { width: 170px; min-height: 38px; padding: 6px 10px; }
details > summary { cursor: pointer; font-weight: 700; padding: 8px 0; }

/* set: excelentes por parte */
.set-exc { display: block; color: var(--muted); font-size: .8rem; font-weight: 400; }
.switch-line { padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel-2); margin-bottom: 4px; }

/* ---------- tienda: pestañas de categoría con dibujo (se acomodan en varias filas, sin barra para deslizar) */
.cat-tabs { display: grid; grid-template-columns: repeat(auto-fill, minmax(132px, 1fr)); gap: 8px; margin: 6px 0 16px; }
.cat-tabs a { display: flex; align-items: center; gap: 8px; padding: 6px 10px 6px 6px; border: 1px solid var(--line-2); border-radius: 10px; background: var(--panel); color: var(--text); text-decoration: none; font-weight: 600; font-size: .86rem; line-height: 1.2; min-width: 0; }
.cat-tabs a > .item-img, .cat-tabs a > .item-none { width: 34px !important; height: 34px !important; padding: 3px; border-radius: 8px; background: #1a2036; box-sizing: border-box; }
.cat-tabs a span { min-width: 0; overflow-wrap: anywhere; }
.cat-tabs a small { color: var(--muted); font-weight: 400; }
.cat-tabs a:hover { border-color: var(--crimson); color: var(--link); }
.cat-tabs a[aria-current="page"] { background: var(--crimson); border-color: var(--crimson); color: #fff; }
.cat-tabs a[aria-current="page"] small { color: #ffd9de; }
@media (max-width: 480px) { .cat-tabs { grid-template-columns: repeat(2, 1fr); } }

/* ---------- /admin > Tienda: filtros, tarjetas y barra de guardar */
.cat-filters { display: grid; grid-template-columns: minmax(160px, 2fr) repeat(3, minmax(140px, 1fr)) auto; gap: 8px; align-items: center; margin-bottom: 12px; }
.cat-filters .input { min-height: 40px; padding: 7px 10px; }
@media (max-width: 899px) { .cat-filters { grid-template-columns: 1fr 1fr; } .cat-filters input[type="search"] { grid-column: 1 / -1; } }
.cat-bar { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center; justify-content: space-between; padding: 8px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel-2); margin-bottom: 12px; }
.cat-bar .check { margin: 0; }
.cat-bulk { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.cat-bulk .input { min-height: 38px; padding: 6px 10px; width: auto; }
.cat-bulk input.input { width: 96px; }
.cat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(168px, 1fr)); gap: 10px; }
@media (max-width: 480px) { .cat-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; } }
.cat-card { position: relative; display: flex; flex-direction: column; gap: 4px; padding: 10px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel); min-width: 0; opacity: .78; transition: border-color .15s, box-shadow .15s, opacity .15s; }
.cat-card.is-on { opacity: 1; border-color: var(--ok-line); }
.cat-card.is-ghost { opacity: .55; }
.cat-card.is-changed { opacity: 1; border-color: var(--gold); box-shadow: 0 0 0 3px rgba(217, 181, 108, .35); background: var(--info-bg); }
.cat-card.is-picked { box-shadow: 0 0 0 2px #2f6fe0; opacity: 1; }
.cat-sel { position: absolute; top: 6px; left: 6px; z-index: 1; line-height: 0; }
.cat-sel input { width: 18px; height: 18px; accent-color: #2f6fe0; }
.cat-pic { display: grid; place-items: center; height: 84px; border-radius: 8px; background: radial-gradient(circle at 50% 40%, #2a3350, #131829 75%); overflow: hidden; }
.cat-pic .item-img { max-height: 76px; width: auto; max-width: 100%; }
.cat-name { font-size: .92rem; line-height: 1.2; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cat-meta { font-size: .74rem; color: var(--muted); display: flex; flex-wrap: wrap; gap: 3px; align-items: center; }
.cls { font-style: normal; font-weight: 800; font-size: .66rem; padding: 0 5px; border-radius: 5px; color: #fff; background: #6b7385; }
.cls-dw { background: #3f6fd8; } .cls-dk { background: #b33a2b; } .cls-elf { background: #2e9a55; } .cls-mg { background: #7a4fc0; } .cls-dl { background: #b07d12; }
.cat-card .pill { align-self: flex-start; font-size: .66rem; }
.cat-ctl { display: grid; grid-template-columns: auto 1fr auto; gap: 6px; align-items: center; margin-top: auto; padding-top: 4px; }
.cat-price { min-height: 34px !important; padding: 4px 8px !important; text-align: right; font-weight: 700; min-width: 0; }
.cat-more { display: grid; place-items: center; width: 28px; height: 34px; border-radius: 8px; border: 1px solid var(--line-2); text-decoration: none; color: var(--muted); font-weight: 800; }
.cat-more:hover { border-color: var(--crimson); color: var(--link); }
.switch { position: relative; display: inline-block; width: 40px; height: 22px; flex: none; }
.switch input { position: absolute; inset: 0; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; z-index: 1; }
.switch span { position: absolute; inset: 0; border-radius: 999px; background: #a9b1c2; transition: background-color .15s; }
.switch span::after { content: ""; position: absolute; top: 2px; left: 2px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .35); transition: transform .15s; }
.switch input:checked + span { background: #22a34e; }
.switch input:checked + span::after { transform: translateX(18px); }
.switch input:focus-visible + span { outline: 3px solid #2f6fe0; outline-offset: 2px; }
.switch input:disabled + span { opacity: .4; }
.cat-save { position: sticky; bottom: 10px; z-index: 5; display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: space-between; margin-top: 14px; padding: 10px 14px; border-radius: 12px; background: var(--head); color: var(--head-text); box-shadow: 0 8px 26px rgba(0, 0, 0, .3); }
.cat-save.has-changes { background: #7a5a08; }
.cat-save .btn { margin: 0; }
.cat-add { margin-top: 16px; }
.pager { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; }
.pager a { min-width: 38px; padding: 7px 10px; text-align: center; border: 1px solid var(--line-2); border-radius: 8px; text-decoration: none; color: var(--text); font-weight: 700; background: var(--panel); }
.pager a[aria-current="page"] { background: var(--crimson); border-color: var(--crimson); color: #fff; }
.cat-admin.is-loading #cat-grid { opacity: .5; }
.set-line .row-pic { display: inline-grid; vertical-align: middle; margin-right: 4px; }
@media (max-width: 480px) { .shop-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; } .shop-item { padding: 10px; } .shop-pic { height: 96px; } .shop-pic .item-img { max-height: 88px; } }

.mail-test { display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center; margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); }
.mail-test-to { display: flex; flex-wrap: wrap; gap: 6px 8px; align-items: center; font-weight: 600; }
.mail-test-to input { width: min(280px, 100%); font-weight: 400; }
.rank td.duel-w { color: #15803d; }
.rank td.duel-l { color: #c0263a; }
html[data-theme="dark"] .rank td.duel-w { color: #4ade80; }
html[data-theme="dark"] .rank td.duel-l { color: #fb7185; }
.rank td.liga { display: flex; align-items: center; gap: 8px; }
.rank td.liga img { width: 34px; height: 34px; object-fit: contain; flex: none; }
.liga-info { margin: -4px 0 12px; }
@media (max-width: 640px) { .rank td.liga span { display: none; } }
.img-slot { padding: 14px 0 6px; border-top: 1px solid var(--line); margin-top: 14px; }
.img-slot h3 { margin: 0 0 4px; font-size: 1.05rem; }
.img-slot h3 small { font-weight: 400; font-size: .82rem; }
.rows .row-img { display: grid; grid-template-columns: 120px 1fr auto; gap: 12px; align-items: center; padding: 8px; border: 1px solid var(--line); border-radius: 10px; }
.row-img > img { width: 120px; height: auto; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 8px; background: var(--bg-2); display: block; }
.img-alts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.img-up { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center; margin: 4px 0 8px; padding: 10px 12px; border: 1px dashed var(--line); border-radius: 10px; }
.img-up label { display: inline-flex; flex-wrap: wrap; gap: 6px 8px; align-items: center; font-weight: 600; }
.img-up select.input { width: auto; min-height: 36px; padding: 4px 8px; }
.img-up input[type=file] { max-width: 100%; font-weight: 400; }
@media (max-width: 859px) { .img-alts { grid-template-columns: 1fr; } }
@media (max-width: 719px) { .rows .row-img { grid-template-columns: 90px 1fr; } .row-img > img { width: 90px; } .row-img .row-tools { grid-column: 1 / -1; } }

/* ================================================================= /admin: menú a la izquierda, tablero y páginas */
.is-admin .foot { display: none; }
.is-admin main.adm-page { padding: 0; }
.adm { --adm-w: 248px; display: grid; grid-template-columns: var(--adm-w) minmax(0, 1fr); min-height: calc(100vh - 110px); }
.adm.is-min { --adm-w: 62px; }
.adm-side { background: var(--panel); border-right: 1px solid var(--line); }
.adm-side-in { position: sticky; top: 112px; max-height: calc(100vh - 112px); overflow-y: auto; padding: 12px 8px 20px; scrollbar-width: thin; }
.adm-group { margin-bottom: 8px; }
.adm-group ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.adm-group-t { margin: 10px 10px 4px; font-size: .7rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.adm-side a, .adm-fold { display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px 10px; border-radius: 9px; border: 0; background: none; color: var(--text-2); text-decoration: none; font: inherit; font-size: .92rem; font-weight: 600; text-align: left; cursor: pointer; }
.adm-side a:hover, .adm-fold:hover { background: var(--bg-2); color: var(--text); }
.adm-side a[aria-current="page"] { background: var(--crimson); color: #fff; box-shadow: 0 2px 8px rgba(196, 22, 42, .3); }
.adm-ico { flex: none; }
.adm-lbl { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.adm-badge { flex: none; min-width: 20px; padding: 1px 6px; border-radius: 999px; background: #d79a1c; color: #fff; font-size: .72rem; font-weight: 800; text-align: center; line-height: 1.5; }
.adm-foot { margin-top: 14px; padding-top: 10px; border-top: 1px solid var(--line); }
.adm.is-min .adm-lbl, .adm.is-min .adm-group-t, .adm.is-min .adm-side .adm-badge { display: none; }
.adm.is-min .adm-side a, .adm.is-min .adm-fold { justify-content: center; padding: 10px 0; }
.adm.is-min .adm-fold .adm-ico { transform: rotate(180deg); }
.adm.is-min .adm-group { border-top: 1px solid var(--line); padding-top: 6px; }
.adm.is-min .adm-group:first-child { border-top: 0; }
.adm-main { min-width: 0; padding: 20px 16px 60px; max-width: 1240px; width: 100%; }
@media (min-width: 960px) { .adm-main { padding: 26px 32px 70px; } }
.adm-head { margin-bottom: 18px; }
.adm-head h1 { margin: 4px 0 2px; font-size: clamp(1.45rem, 2.4vw, 1.9rem); }
.adm-help { margin: 0; color: var(--muted); }
.adm-crumbs { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; font-size: .82rem; color: var(--muted); }
.adm-crumbs b { color: var(--text-2); }
.adm-open { display: none; align-items: center; gap: 8px; margin: 0 0 12px; padding: 9px 14px; border-radius: 10px; border: 1px solid var(--line-2); background: var(--panel); color: var(--text); font: inherit; font-weight: 700; cursor: pointer; }
.adm-shade { position: fixed; inset: 0; z-index: 59; border: 0; background: rgba(8, 11, 20, .55); }
.adm-main .card { margin-bottom: 16px; }
.adm-main .card h2 { margin-top: 0; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.adm-save { position: sticky; bottom: 0; z-index: 4; margin: 18px -18px -18px; padding: 12px 18px; background: var(--panel-2); border-top: 1px solid var(--line); border-radius: 0 0 var(--radius) var(--radius); display: flex; gap: 12px; align-items: center; }
@media (min-width: 720px) { .adm-save { margin: 22px -24px -24px; padding: 12px 24px; } }
.adm-save .btn { margin: 0; }
.adm-save.is-dirty { background: var(--info-bg); border-top-color: var(--info-line); }
.adm-save.is-dirty::after { content: "Hay cambios sin guardar"; color: var(--info-text); font-weight: 700; font-size: .9rem; }
.adm-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 14px; margin-bottom: 16px; }
.adm-tile { position: relative; display: grid; gap: 2px; padding: 16px 18px; border-radius: var(--radius); border: 1px solid var(--line); border-left: 4px solid var(--line-2); background: var(--panel); box-shadow: var(--shadow); color: var(--text); text-decoration: none; }
a.adm-tile:hover { border-color: var(--crimson); transform: translateY(-1px); }
.adm-tile.is-ok { border-left-color: #22a34e; } .adm-tile.is-no { border-left-color: #d02238; } .adm-tile.is-warn { border-left-color: #d79a1c; } .adm-tile.is-off { border-left-color: var(--line-2); }
.adm-tile-ico { position: absolute; top: 14px; right: 14px; color: var(--muted); }
.adm-tile-k { font-size: .76rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.adm-tile-v { font-family: var(--display); font-size: 1.7rem; line-height: 1.15; }
.adm-tile-s { font-size: .86rem; color: var(--muted); }
.adm-cols { display: grid; gap: 16px; grid-template-columns: 1fr; align-items: start; }
@media (min-width: 1100px) { .adm-cols { grid-template-columns: 1fr 1fr; } }
.adm-cols .card { margin-bottom: 0; }
.adm-todo li { grid-template-columns: 28px minmax(0, 1fr) !important; }
.adm-todo li > span:last-child { grid-column: 2 !important; }
.adm-todo .st-ico { grid-row: span 2 !important; }
.adm-note { margin: 14px 0 0; }
.adm-quick { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 10px; margin-bottom: 12px; }
.adm-quick a { display: grid; justify-items: center; gap: 8px; padding: 14px 8px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel-2); color: var(--text); text-decoration: none; font-weight: 700; font-size: .88rem; text-align: center; }
.adm-quick a:hover { border-color: var(--crimson); color: var(--link); }
.adm-quick .adm-ico { color: var(--crimson); }
.adm-empty { padding: 26px 16px; border: 1px dashed var(--line-2); border-radius: 12px; text-align: center; color: var(--muted); background: var(--panel-2); }
.adm-empty-ok { border-color: var(--ok-line); background: var(--ok-bg); color: var(--ok-text); font-weight: 700; }
.adm-table td, .adm-table th { padding: 8px 10px; font-size: .9rem; }
.adm-filter { display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: end; margin-bottom: 14px; }
.adm-filter label { display: grid; gap: 4px; font-weight: 700; font-size: .86rem; }
.adm-filter .input { min-width: 200px; }
.adm-filter .btn { margin: 0; }
.adm-log { margin: 0; padding: 0; list-style: none; font-family: ui-monospace, Consolas, monospace; font-size: .8rem; border: 1px solid var(--line); border-radius: 10px; max-height: 70vh; overflow: auto; }
.adm-log li { padding: 6px 10px; border-bottom: 1px solid var(--line); overflow-wrap: anywhere; }
.adm-log li:nth-child(even) { background: var(--panel-2); }
/* En el panel no hay barras que se corren de costado: las pestañas y los filtros bajan de renglón. */
.adm-main .tabs, .adm-main .chips { flex-wrap: wrap; overflow-x: visible; }
/* Avisos de "guardado" y errores de un formulario: carteles que aparecen abajo a la derecha. */
.is-admin main > .alert { position: fixed; right: 16px; bottom: 16px; z-index: 80; max-width: min(460px, calc(100vw - 32px)); margin: 0; box-shadow: 0 10px 30px rgba(10, 14, 26, .3); animation: adm-toast .25s ease-out; cursor: pointer; }
.is-admin main > .alert + .alert { bottom: 86px; }
.is-admin main > .alert.is-gone { opacity: 0; transform: translateY(8px); transition: opacity .3s, transform .3s; }
@keyframes adm-toast { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.is-admin a:focus-visible, .is-admin button:focus-visible, .is-admin .input:focus-visible, .is-admin select:focus-visible { outline: 3px solid #2f6fe0; outline-offset: 2px; }
@media (max-width: 899px) {
  .adm { display: block; }
  .adm-open { display: inline-flex; }
  .adm-side { position: fixed; z-index: 60; top: 0; bottom: 0; left: 0; width: min(290px, 86vw); transform: translateX(-102%); transition: transform .2s ease; box-shadow: 0 0 40px rgba(0, 0, 0, .35); }
  .adm-side-in { position: static; max-height: 100%; height: 100%; padding-top: 16px; }
  .adm.is-open .adm-side { transform: none; }
  .adm.is-min .adm-lbl, .adm.is-min .adm-group-t { display: revert; }
  .adm.is-min .adm-side a { justify-content: flex-start; padding: 8px 10px; }
  .adm-fold { display: none; }
}
@media (prefers-reduced-motion: reduce) { .adm-side, .is-admin main > .alert { transition: none; animation: none; } }

.adm-cols { grid-template-columns: minmax(0, 1fr); }
@media (min-width: 1100px) { .adm-cols { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } }
.adm-h { margin: 26px 0 12px; font-size: 1.25rem; }
.adm-acc { display: grid; gap: 18px; grid-template-columns: minmax(0, 1fr); margin-top: 8px; }
@media (min-width: 1000px) { .adm-acc { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } }
.adm-acc h3 { margin: 12px 0 6px; font-size: 1rem; }
.adm-chars { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.adm-chars li { display: flex; flex-wrap: wrap; gap: 6px 8px; align-items: center; padding: 6px 8px; border: 1px solid var(--line); border-radius: 8px; background: var(--panel-2); overflow-wrap: anywhere; }
.adm-spark { color: var(--crimson); margin: 4px 0 12px; padding: 10px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel-2); }
.adm-spark-gold { color: #c9972b; }
.adm-bars { list-style: none; margin: 0 0 10px; padding: 0; display: grid; gap: 6px; }
.adm-bars li { display: grid; grid-template-columns: 130px minmax(0, 1fr) 60px; gap: 10px; align-items: center; font-size: .9rem; }
.adm-bars i { display: block; height: 12px; border-radius: 6px; background: linear-gradient(90deg, var(--crimson), var(--gold)); }
.adm-bars b { text-align: right; font-variant-numeric: tabular-nums; }

/* ================================================================= portada: 5 datos del servidor */
.stats-5 li:first-child { grid-column: span 2; }
@media (min-width: 760px) { .stats.stats-5 { grid-template-columns: repeat(5, 1fr); max-width: 940px; } .stats-5 li:first-child { grid-column: auto; } }

/* ================================================================= panel del jugador */
.pn { display: grid; gap: 18px; grid-template-columns: minmax(0, 1fr); align-items: start; }
.pn-nav { display: flex; flex-wrap: wrap; gap: 8px; }
.pn-nav a { display: inline-flex; align-items: center; gap: 8px; padding: 9px 14px; border-radius: 10px; border: 1px solid var(--line-2); background: var(--panel); color: var(--text); text-decoration: none; font-weight: 700; font-size: .92rem; }
.pn-nav a:hover { border-color: var(--crimson); color: var(--link); }
.pn-nav a[aria-current="page"] { background: var(--crimson); border-color: var(--crimson); color: #fff; }
.pn-nav .pn-nav-adm { border-style: dashed; }
.pn-ico { flex: none; }
@media (max-width: 959px) { .pn-is-home .pn-nav a:not([aria-current]):not(.pn-nav-adm) { display: none; } .pn-is-home .pn-nav { justify-content: space-between; } }
@media (min-width: 960px) {
  .pn { grid-template-columns: 208px minmax(0, 1fr); gap: 26px; }
  .pn-nav { position: sticky; top: 124px; flex-direction: column; flex-wrap: nowrap; gap: 4px; padding: 10px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); box-shadow: var(--shadow); }
  .pn-nav a { border-color: transparent; background: none; padding: 9px 12px; }
  .pn-nav a:hover { background: var(--bg-2); border-color: transparent; }
}
.pn-main { min-width: 0; }
.pn-main > .eyebrow { margin-top: 0; }
.pn-hero { position: relative; overflow: hidden; display: grid; gap: 18px; padding: 22px 20px; border-radius: 16px; color: #f4f1e8; border: 1px solid #3a2a12;
  background: radial-gradient(120% 140% at 100% 0%, rgba(217, 181, 108, .28), transparent 55%), radial-gradient(90% 120% at 0% 100%, rgba(196, 22, 42, .38), transparent 60%), linear-gradient(135deg, #171b2c, #0f1220 70%); box-shadow: 0 10px 30px rgba(14, 18, 32, .28); }
.pn-hero::after { content: ""; position: absolute; inset: 0; pointer-events: none; border-radius: inherit; box-shadow: inset 0 0 0 1px rgba(240, 213, 149, .22); }
@media (min-width: 860px) { .pn-hero { grid-template-columns: minmax(0, 1fr) auto; align-items: center; padding: 26px 28px; } }
.pn-id { display: flex; gap: 16px; align-items: center; min-width: 0; }
.pn-avatar { position: relative; flex: none; }
.pn-avatar .avatar { width: 76px; height: 76px; border-radius: 50%; border: 3px solid var(--gold); box-shadow: 0 0 0 4px rgba(217, 181, 108, .18); object-fit: cover; }
.pn-avatar .dot { position: absolute; right: 2px; bottom: 4px; width: 16px; height: 16px; border: 3px solid #141a2b; }
.pn-hero .eyebrow { color: var(--gold-2); margin: 0; }
.pn-hero h1 { margin: 0 0 6px; color: #fff; font-size: clamp(1.6rem, 4vw, 2.2rem); overflow-wrap: anywhere; }
.pn-badges { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; }
.pn-badge { display: inline-flex; align-items: center; gap: 4px; padding: 3px 10px; border-radius: 999px; font-size: .78rem; font-weight: 800; background: var(--bg-2); color: var(--text-2); border: 1px solid var(--line-2); text-decoration: none; white-space: nowrap; }
.pn-hero .pn-badge { background: rgba(255, 255, 255, .1); color: #e9ecf5; border-color: rgba(255, 255, 255, .2); }
.pn-badge.is-on, .pn-hero .pn-badge.is-on { background: #1f8a45; border-color: #2fa653; color: #fff; }
.pn-badge.is-vip, .pn-hero .pn-badge.is-vip { background: linear-gradient(180deg, #f0d595, #d9b56c); border-color: #b9954a; color: #3a2a06; }
.pn-badge.is-bad, .pn-hero .pn-badge.is-bad { background: #c4162a; border-color: #e02a3f; color: #fff; }
.pn-money { display: flex; flex-wrap: wrap; gap: 10px; align-items: stretch; }
.pn-coin { display: grid; grid-template-columns: auto 1fr; gap: 0 10px; align-items: center; min-width: 136px; padding: 10px 14px; border-radius: 12px; background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .16); }
.pn-coin .pn-ico { grid-row: span 2; color: #c9d2e6; }
.pn-coin.is-gold .pn-ico { color: var(--gold-2); }
.pn-coin span { font-size: .74rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: #b9c1d6; }
.pn-coin b { font-family: var(--display); font-size: 1.5rem; line-height: 1.1; color: #fff; font-variant-numeric: tabular-nums; }
.pn-coin.is-gold b { color: var(--gold-2); }
.pn-cta { align-self: center; margin: 0; }
.pn-acts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin: 16px 0 6px; }
@media (min-width: 560px) { .pn-acts { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (min-width: 1180px) { .pn-acts { grid-template-columns: repeat(auto-fit, minmax(118px, 1fr)); } }
.pn-act { display: grid; justify-items: center; gap: 4px; padding: 14px 8px; border-radius: 12px; border: 1px solid var(--line); background: var(--panel); box-shadow: var(--shadow); color: var(--text); text-decoration: none; text-align: center; transition: transform .15s ease, border-color .15s ease; }
.pn-act:hover { transform: translateY(-2px); border-color: var(--gold); }
.pn-act .pn-ico { color: var(--crimson); width: 26px; height: 26px; }
.pn-act b { font-size: .9rem; }
.pn-act small { color: var(--muted); font-size: .76rem; }
.pn-chars { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
.pn-char { display: grid; gap: 12px; padding: 14px; border-radius: 14px; border: 1px solid var(--line); border-top: 3px solid var(--gold); background: var(--panel); box-shadow: var(--shadow); color: var(--text); text-decoration: none; transition: transform .15s ease, box-shadow .15s ease; }
.pn-char:hover { transform: translateY(-2px); box-shadow: 0 10px 26px rgba(23, 32, 51, .14); }
.pn-char.is-here { border-top-color: #22a34e; }
.pn-char-top { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 12px; align-items: center; }
.pn-char-top .avatar { width: 58px; height: 58px; border-radius: 12px; border: 2px solid var(--line-2); object-fit: cover; }
.pn-char-top b { display: block; font-family: var(--display); font-size: 1.15rem; overflow: hidden; text-overflow: ellipsis; }
.pn-char-top small { color: var(--muted); }
.pn-char-nums { display: grid; grid-template-columns: repeat(auto-fit, minmax(58px, 1fr)); gap: 6px; }
.pn-char-nums > span { display: grid; justify-items: center; padding: 6px 4px; border-radius: 8px; background: var(--panel-2); border: 1px solid var(--line); }
.pn-char-nums b { font-size: 1.05rem; font-variant-numeric: tabular-nums; }
.pn-char-nums > span:first-child b { color: var(--crimson); }
.pn-char-nums small { font-size: .68rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.pn-char-foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 12px; font-size: .86rem; color: var(--text-2); }
.pn-char-foot > span { display: inline-flex; align-items: center; gap: 5px; }
.pn-grid { display: grid; gap: 16px; grid-template-columns: minmax(0, 1fr); margin-top: 22px; }
@media (min-width: 760px) { .pn-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.pn-box h2 { display: flex; align-items: center; gap: 8px; margin-top: 0; font-size: 1.15rem; }
.pn-box h2 .pn-ico, .pn-prot h2 .pn-ico { color: var(--crimson); }
.pn-tips { margin: 10px 0 0; padding-left: 20px; color: var(--text-2); font-size: .9rem; display: grid; gap: 4px; }
.pn-warn { margin: 12px 0 0; padding: 8px 12px; border-radius: 8px; background: var(--info-bg); border: 1px solid var(--info-line); color: var(--info-text); font-size: .86rem; }
.pn-link { border: 0; background: none; padding: 0; color: var(--link); font: inherit; font-size: .84rem; text-decoration: underline; cursor: pointer; }
.pn-devs, .pn-feed { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.pn-devs li, .pn-feed li { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 12px; align-items: center; padding: 9px 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--panel-2); }
.pn-devs .pn-ico, .pn-feed .pn-ico { color: var(--gold-text); }
.pn-devs b, .pn-feed b { display: block; overflow-wrap: anywhere; }
.pn-devs small, .pn-feed small { color: var(--muted); font-size: .82rem; }
.pn-empty { display: grid; justify-items: center; gap: 6px; padding: 30px 16px; border: 1px dashed var(--line-2); border-radius: 14px; background: var(--panel-2); color: var(--muted); text-align: center; }
.pn-empty .pn-ico { color: var(--gold-text); }
.pn-empty b { color: var(--text); }
.pn-empty-sm { padding: 18px 12px; }
.pn-pin { display: grid; gap: 14px; margin-bottom: 16px; padding: 18px 20px; border-radius: 14px; border: 2px solid var(--gold); background: var(--info-bg); color: var(--info-text); }
@media (min-width: 760px) { .pn-pin { grid-template-columns: minmax(0, 1fr) auto; align-items: center; } }
.pn-pin h2 { margin: 0 0 4px; font-size: 1.2rem; }
.pn-pin p { margin: 0; }
.pn-pin-code { display: flex; gap: 10px; align-items: center; }
.pn-pin-code code { font-size: 1.7rem; font-weight: 800; letter-spacing: .22em; padding: 6px 14px; border-radius: 10px; background: var(--panel); color: var(--text); border: 1px solid var(--line-2); }
.pn-pin-code .btn { margin: 0; }
.pn-prot h2 { display: flex; align-items: center; gap: 8px; }
.pn-prot-state { padding: 12px 14px; border-radius: 10px; font-weight: 800; border: 1px solid var(--line-2); }
.pn-prot-state.is-on { background: var(--ok-bg); border-color: var(--ok-line); color: var(--ok-text); }
.pn-prot-state.is-off { background: var(--info-bg); border-color: var(--info-line); color: var(--info-text); }
.pin-help { margin: 2px 0 10px; padding: 8px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel-2); font-size: .9rem; }
.pin-help summary { cursor: pointer; font-weight: 700; color: var(--link); }
.pin-help ul { margin: 8px 0; padding-left: 20px; }
.pin-help p { margin: 6px 0 2px; color: var(--muted); }
.fx-on .pn-hero .pn-coin.is-gold { animation: pn-glow 3.6s ease-in-out infinite; }
@keyframes pn-glow { 0%, 100% { box-shadow: 0 0 0 0 rgba(240, 213, 149, 0); } 50% { box-shadow: 0 0 18px 0 rgba(240, 213, 149, .28); } }
@media (prefers-reduced-motion: reduce) { .pn-act, .pn-char { transition: none; } .fx-on .pn-hero .pn-coin.is-gold { animation: none; } }
