/* ============================================================================
   ARDUZ ONLINE — Rediseño moderno "Dark Gaming" (2026)
   Mantiene la marca: rojo #C00000 + dorado + fondo oscuro. Responsive/mobile.
   Reemplaza style.css/heads.css/gh.css legacy (2004). Servido en /s/css/app.css
   ============================================================================ */

:root {
  /* Marca */
  --red: #c00000;
  --red-2: #e01515;
  --red-deep: #7a0000;
  --red-glow: rgba(224, 21, 21, 0.45);
  --gold: #d8b066;
  --gold-soft: #9e7b51;
  --gold-bright: #f0cd84;

  /* Superficies oscuras */
  --bg: #0a0908;
  --bg-2: #121010;
  --bg-3: #1a1614;
  --panel: #161210;
  --line: #38271f;
  --line-2: #4a3328;

  /* Texto */
  --text: #cdbb9c;
  --text-dim: #8a7a64;
  --white: #f1e8d7;

  /* Estados */
  --ok: #46d486;
  --armada: #92cdff;
  --caos: #e2685c;

  --radius: 12px;
  --radius-sm: 8px;
  --maxw: 1140px;
  --header-h: 68px;
  --font: "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
  --shadow: 0 8px 24px rgba(0, 0, 0, 0.55);
  --shadow-red: 0 6px 22px rgba(204, 0, 0, 0.28);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.6;
  color: var(--text);
  background:
    radial-gradient(1100px 500px at 50% -120px, rgba(122, 0, 0, 0.35), transparent 60%),
    var(--bg);
  background-attachment: fixed;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--gold); text-decoration: none; transition: color .15s ease; }
a:hover { color: var(--gold-bright); }

h1, h2, h3, h4 {
  color: var(--white);
  font-weight: 700;
  line-height: 1.2;
  margin: 0 0 .6em;
  letter-spacing: .3px;
}
h1 { font-size: 1.9rem; }
h2 { font-size: 1.4rem; }
h3 { font-size: 1.15rem; }
p { margin: 0 0 1em; }
img { max-width: 100%; height: auto; }
hr, .hr { border: 0; height: 1px; background: linear-gradient(90deg, transparent, var(--line-2), transparent); margin: 1.2em 0; }
.clear { clear: both; }

/* ----------------------------------------------------------------- HEADER --*/
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--header-h);
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 0 24px;
  background: linear-gradient(180deg, rgba(18, 14, 13, 0.96), rgba(10, 9, 8, 0.92));
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 2px 0 rgba(204, 0, 0, 0.25), var(--shadow);
}
.brand { display: flex; align-items: center; flex: 0 0 auto; }
.brand img { height: 42px; width: auto; display: block; }

.nav { display: flex; align-items: center; gap: 4px; margin-left: 8px; }
.nav a {
  position: relative;
  display: inline-block;
  padding: 8px 14px;
  color: var(--text);
  font-size: .82rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .8px;
  border-radius: var(--radius-sm);
}
.nav a:hover { color: var(--white); background: rgba(255, 255, 255, 0.04); }
.nav a::after {
  content: "";
  position: absolute; left: 14px; right: 14px; bottom: 3px;
  height: 2px; background: var(--red-2); border-radius: 2px;
  transform: scaleX(0); transform-origin: left; transition: transform .18s ease;
}
.nav a:hover::after, .nav a.active::after { transform: scaleX(1); }

.header-spacer { flex: 1 1 auto; }

/* Cuenta (dropdown) */
.account { position: relative; flex: 0 0 auto; }
.account > .account-btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 14px; border-radius: 999px;
  border: 1px solid var(--line-2); background: var(--bg-3);
  color: var(--white); font-weight: 600; font-size: .85rem; cursor: pointer;
}
.account > .account-btn:hover { border-color: var(--red); color: var(--white); }
.account .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 8px var(--ok); }
.account-menu {
  position: absolute; right: 0; top: calc(100% + 10px);
  min-width: 190px; padding: 8px;
  background: var(--bg-2); border: 1px solid var(--line-2); border-radius: var(--radius);
  box-shadow: var(--shadow); display: none; flex-direction: column;
}
.account.open .account-menu { display: flex; }
.account-menu a {
  display: block; padding: 9px 12px; border-radius: var(--radius-sm);
  color: var(--text); font-size: .9rem; font-weight: 600;
}
.account-menu a:hover { background: rgba(204, 0, 0, 0.14); color: var(--white); }
.account-menu a.gm { color: var(--gold); }
.account-menu .sep { height: 1px; background: var(--line); margin: 6px 4px; }
.account-menu a.danger:hover { background: rgba(224, 21, 21, 0.18); color: #ffd9d2; }

/* Hamburger */
.burger {
  display: none; flex: 0 0 auto;
  width: 42px; height: 42px; border-radius: var(--radius-sm);
  border: 1px solid var(--line-2); background: var(--bg-3); cursor: pointer;
  color: var(--white); font-size: 1.3rem; line-height: 1;
}

/* --------------------------------------------------------------- BUTTONS ---*/
.btn, button.btn, input.btn, #formulario #Submit, input[type="submit"], .bton {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 11px 22px; border-radius: 999px; cursor: pointer;
  font-family: var(--font); font-size: .9rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .6px;
  border: 1px solid transparent; text-decoration: none;
  background: linear-gradient(180deg, var(--red-2), var(--red)); color: #fff;
  box-shadow: var(--shadow-red); transition: transform .12s ease, box-shadow .15s ease, filter .15s ease;
  width: auto; height: auto;
}
.btn:hover, #formulario #Submit:hover, input[type="submit"]:hover, .bton:hover {
  color: #fff; filter: brightness(1.08);
  box-shadow: 0 8px 28px rgba(224, 21, 21, 0.5); transform: translateY(-1px);
}
.btn:active { transform: translateY(0); }
.btn-ghost {
  background: transparent; border-color: var(--line-2); color: var(--white); box-shadow: none;
}
.btn-ghost:hover { border-color: var(--red); background: rgba(204, 0, 0, 0.1); filter: none; }
.btn-lg { padding: 15px 34px; font-size: 1.05rem; }

/* ----------------------------------------------------------------- LAYOUT --*/
.container { max-width: var(--maxw); margin: 0 auto; padding: 28px 24px 60px; }

.page-head {
  margin: 6px 0 22px; padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}
.page-head h1 { margin: 0; }
.page-head .sub { color: var(--text-dim); margin: 4px 0 0; font-size: .95rem; }

/* Panel (theme 1): contenido + sidebar */
.layout-panel { display: grid; grid-template-columns: 1fr 280px; gap: 26px; align-items: start; }
.sidebar {
  position: sticky; top: calc(var(--header-h) + 20px);
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 18px; box-shadow: var(--shadow);
}
.sidebar .who { color: var(--gold); font-weight: 700; font-size: 1.05rem; margin-bottom: 12px; word-break: break-word; }
.sidebar nav a { display: block; padding: 9px 12px; border-radius: var(--radius-sm); color: var(--text); font-weight: 600; }
.sidebar nav a:hover { background: rgba(204, 0, 0, 0.14); color: var(--white); }
.sidebar nav a.gm { color: var(--gold); }
.sidebar nav .sep { height: 1px; background: var(--line); margin: 8px 4px; }

/* ------------------------------------------------------------------ CARDS --*/
.card {
  background: linear-gradient(180deg, var(--bg-2), var(--bg-3));
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px; box-shadow: var(--shadow);
}
.grid { display: grid; gap: 20px; }
.grid-2 { grid-template-columns: 1fr 1fr; }
/* Home: enlaces rápidos a la IZQUIERDA (como el original) + noticias a la derecha. */
.grid-home { grid-template-columns: 300px 1fr; gap: 26px; align-items: start; }
.grid-home > aside { position: sticky; top: calc(var(--header-h) + 20px); }

/* Tabs (sub-nav de ranking): horizontal, arriba, en vez del toolbox al fondo. */
.tabs { display: flex; gap: 2px; flex-wrap: wrap; margin: 0 0 24px; border-bottom: 1px solid var(--line); }
.tabs a {
  padding: 11px 20px; margin-bottom: -1px;
  font-weight: 700; font-size: .82rem; text-transform: uppercase; letter-spacing: .8px;
  color: var(--text-dim); border-bottom: 2px solid transparent;
}
.tabs a:hover { color: var(--white); }
.tabs a.active { color: var(--white); border-bottom-color: var(--red-2); }

/* Ranking más aireado dentro de card. */
table.rank { margin: 0; }
table.rank td { padding: 12px 14px; }
.rpj { display: flex; justify-content: space-between; align-items: center; padding: 12px 4px; }
.rpj .right { color: var(--gold-soft); }
.rpj-head { border-bottom: 1px solid var(--line-2) !important; margin-bottom: 4px; }
.cloud { line-height: 2.2; }
.cloud a { margin-right: 6px; }

/* Noticia card */
.news-card { transition: transform .15s ease, border-color .15s ease, box-shadow .15s ease; }
.news-card:hover { transform: translateY(-2px); border-color: var(--line-2); box-shadow: 0 12px 30px rgba(0,0,0,.6); }
.news-card h2, .news-card h1, .news-card h3 { color: var(--gold); }
.news-card .meta { color: var(--text-dim); font-size: .8rem; text-transform: uppercase; letter-spacing: .5px; margin-top: 10px; }
.news-card + .news-card { margin-top: 20px; }
.lead { font-size: 1.02rem; color: var(--text); }

/* Chips (enlaces rápidos) — arregla el overflow del box fijo legacy */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips a {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 13px; border-radius: 999px; font-size: .85rem; font-weight: 600;
  background: var(--bg-3); border: 1px solid var(--line-2); color: var(--text);
}
.chips a:hover { border-color: var(--red); color: var(--white); background: rgba(204,0,0,.12); }
.online-pill { display: inline-flex; align-items: center; gap: 8px; color: var(--text); font-weight: 600; }
.online-pill .dot { width: 9px; height: 9px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 10px var(--ok); }

/* Barra horizontal de enlaces rápidos (arriba, bajo el hero). */
.quickbar {
  display: flex; align-items: center; gap: 16px 22px; flex-wrap: wrap;
  margin-bottom: 26px; padding: 16px 20px;
}
.quickbar .online-pill { margin: 0; padding-right: 22px; border-right: 1px solid var(--line); }
.quickbar .chips { flex: 1 1 auto; }
@media (max-width: 600px) {
  .quickbar .online-pill { border-right: 0; padding-right: 0; width: 100%; }
}

/* ------------------------------------------------------------------- HERO --*/
.hero {
  position: relative; overflow: hidden;
  border-radius: 16px; border: 1px solid var(--line);
  margin-bottom: 28px; padding: 56px 28px;
  text-align: center;
  background:
    radial-gradient(700px 320px at 50% -40px, rgba(204, 0, 0, 0.5), transparent 70%),
    linear-gradient(180deg, #1b0d0a, #0a0807);
  box-shadow: var(--shadow);
}
/* El logo.png trae el fondo rojo HORNEADO (rectángulo opaco). Para que no se
   marque contra el hero: (1) el hero pinta detrás el MISMO logo agrandado y
   blureado (backdrop ambiente) => los bordes del rectángulo mueren contra sus
   propios colores; (2) máscara que esfuma los 4 bordes del PNG (suave a los
   costados, donde las letras llegan casi al filo). */
.hero::before {
  content: ''; position: absolute; inset: -40px; z-index: 0;
  background: url('/s/img/logo.png') center / cover no-repeat;
  filter: blur(48px) saturate(1.1) brightness(.65);
  opacity: .5;
}
.hero > * { position: relative; z-index: 1; }
.hero img.hero-logo {
  width: min(420px, 80%); height: auto;
  -webkit-mask-image:
    linear-gradient(90deg, transparent 0, #000 8%, #000 92%, transparent 100%),
    linear-gradient(180deg, transparent 0, #000 18%, #000 82%, transparent 100%);
  -webkit-mask-composite: source-in;
  mask-image:
    linear-gradient(90deg, transparent 0, #000 8%, #000 92%, transparent 100%),
    linear-gradient(180deg, transparent 0, #000 18%, #000 82%, transparent 100%);
  mask-composite: intersect;
}
.hero .tagline { color: var(--text); font-size: 1.15rem; margin: 18px auto 26px; max-width: 560px; }
.hero .cta { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* ----------------------------------------------------------------- TABLES --*/
table { width: 100%; border-collapse: collapse; margin: 0 0 1em; }
th, td { padding: 10px 12px; text-align: left; }
thead th, tr th { color: var(--gold); font-size: .8rem; text-transform: uppercase; letter-spacing: .6px; border-bottom: 1px solid var(--line-2); }
tbody td { border-bottom: 1px solid var(--line); }
tbody tr:hover td { background: rgba(255, 255, 255, 0.025); }

/* ------------------------------------------------------------------ FORMS --*/
label { display: inline-block; color: var(--text-dim); font-weight: 600; font-size: .9rem; margin: 6px 8px 6px 0; }
input[type="text"], input[type="password"], input[type="email"], input[type="number"],
select, textarea, #formulario input, .input_big {
  background: var(--bg); border: 1px solid var(--line-2); color: var(--white);
  padding: 10px 12px; border-radius: var(--radius-sm); font-family: var(--font); font-size: .95rem;
  width: auto; max-width: 100%; margin: 2px 0;
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--red); box-shadow: 0 0 0 3px var(--red-glow); }
textarea { width: 100%; min-height: 160px; resize: vertical; }
select { min-width: 180px; }
input[type="checkbox"] { width: 16px; height: 16px; accent-color: var(--red); vertical-align: middle; }

/* Form contenedor legacy */
#formulario { max-width: 520px; }

/* .mini_bt: botón chico (ghost) reutilizado en clan/mercado/bóveda. */
.mini_bt, #formulario .mini_bt {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  width: auto; height: auto; padding: 7px 14px; cursor: pointer;
  font-family: var(--font); font-size: .8rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .5px;
  border-radius: 999px; border: 1px solid var(--line-2);
  background: var(--bg-3); color: var(--text); text-decoration: none;
  transition: border-color .15s ease, color .15s ease, background .15s ease;
}
.mini_bt:hover { border-color: var(--red); color: var(--white); background: rgba(204,0,0,.12); }

/* ------------------------------------------------------------------ FLASH --*/
.flash, #err, #ok {
  display: block; padding: 12px 16px; border-radius: var(--radius-sm);
  margin: 0 0 18px; font-weight: 600; border: 1px solid;
}
.flash.ok, #ok { background: rgba(70, 212, 134, 0.1); border-color: rgba(70, 212, 134, 0.4); color: #bff5d6; }
.flash.error, #err { background: rgba(224, 21, 21, 0.12); border-color: rgba(224, 21, 21, 0.45); color: #ffd2cb; }
.flash.info { background: rgba(146, 205, 255, 0.1); border-color: rgba(146, 205, 255, 0.4); color: #cfe9ff; }

/* ----------------------------------------------------------------- FOOTER --*/
.site-footer {
  border-top: 1px solid var(--line); margin-top: 40px; padding: 26px 24px;
  text-align: center; color: var(--text-dim); font-size: .9rem;
  background: linear-gradient(180deg, transparent, rgba(0,0,0,.4));
}
.site-footer a { color: var(--gold-soft); font-weight: 600; }
.site-footer a:hover { color: var(--gold-bright); }
.site-footer .sep { opacity: .5; margin: 0 8px; }
.site-footer small { display: block; margin-top: 8px; opacity: .7; }

/* ----------------------------------------------- SHIMS clases legacy 2004 --*/
/* .flashtext: el original era texto renderizado por SWF. Le damos JERARQUÍA según
   el atributo `estilo` (lo emite headerTitle): 22-24=título de página, 3=título de
   noticia, 4-5=subtítulo de sección, 10=encabezado de columna/etiqueta, 8=capital. */
.flashtext { display: block; color: var(--gold); font-weight: 800; line-height: 1.2; margin: 0 0 .6em; }

/* Título de página (H1) — el más grande, con acento rojo abajo. */
.flashtext[estilo="22"], .flashtext[estilo="23"], .flashtext[estilo="24"] {
  font-size: 1.75rem; letter-spacing: .3px; color: var(--white);
  padding-bottom: 12px; margin-bottom: 22px;
  border-bottom: 2px solid var(--line);
  background: linear-gradient(90deg, var(--red-2), transparent) left bottom / 90px 2px no-repeat;
}

/* Título de noticia (dentro de card). */
.news-card .flashtext[estilo="3"], .flashtext[estilo="3"] { font-size: 1.35rem; color: var(--gold-bright); margin-bottom: .3em; }

/* Subtítulo de sección. */
.flashtext[estilo="4"], .flashtext[estilo="5"] { font-size: 1.12rem; color: var(--white); font-weight: 700; }

/* Encabezado de columna / etiqueta pequeña (estilo 10): tipo "table header". */
.flashtext[estilo="10"] {
  font-size: .78rem; color: var(--gold-soft); font-weight: 700;
  text-transform: uppercase; letter-spacing: 1.4px; margin-bottom: .4em;
}

/* Capital decorativa al inicio de una noticia (estilo 8). */
.flashtext[estilo="8"] {
  display: block; float: left; margin: 2px 12px 0 0;
  font-size: 3rem; line-height: .8; font-weight: 800;
  color: var(--red-2); text-shadow: 0 2px 10px rgba(224,21,21,.4);
}

/* Widget "toolbox" (sub-nav de ranking, etc.): título chico + links en lista.
   Anula el tamaño grande del estilo 23 cuando vive dentro del toolbox. */
#toolbox {
  margin-top: 22px; padding: 16px 18px;
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
}
#toolbox .flashtext {
  font-size: .8rem; color: var(--gold-soft); font-weight: 700;
  text-transform: uppercase; letter-spacing: 1.4px;
  padding: 0 0 8px 10px; margin: 0 0 8px; border: 0; background: none;
  border-left: 3px solid var(--red); border-bottom: 1px solid var(--line);
}
#toolbox a { display: block; padding: 7px 10px; border-radius: var(--radius-sm); color: var(--text); font-weight: 600; }
#toolbox a:hover { background: rgba(204, 0, 0, 0.14); color: var(--white); }

/* "Última actualización": acento sobrio en vez del cyan chillón. */
.upd-time { color: var(--gold-soft); font-weight: 700; }
.ma20 { margin: 0; }
.acao25 { color: var(--armada); } .acao5 { color: var(--caos); } .acao4 { color: var(--gold-soft); }
.boldi { font-weight: 700; color: #e7d1a8; }
/* Oro/monedas (idv) y estados de requisito (verde/rojo). */
.idv { color: var(--gold); font-weight: 700; }
.cgreen { color: var(--ok); font-weight: 700; }
.cred { color: var(--caos); font-weight: 700; }
.pj, .shpj, .rpj { display: block; padding: 8px 0; border-bottom: 1px solid var(--line); }
.barras { display: inline-block; width: 120px; }
.barra_fondo { background: var(--bg); border: 1px solid var(--line-2); border-radius: 6px; height: 10px; overflow: hidden; }
.barra_verde { height: 100%; background: linear-gradient(90deg, var(--red-deep), var(--red-2)); }
/* tooltip flotante (mercado/bóveda) */
#tooltip { position: absolute; display: none; z-index: 999; max-width: 280px; padding: 10px 12px;
  background: var(--bg-2); border: 1px solid var(--line-2); border-radius: var(--radius-sm);
  box-shadow: var(--shadow); color: var(--text); font-size: .85rem; pointer-events: none; }

/* ------------------------------------------------------- PANEL PERSONAJE ---*/
.pj-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; margin-bottom: 8px; }
.pj-card { display: flex; flex-direction: column; gap: 14px; padding: 18px; }
.pj-card-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; }
.pj-nick { font-size: 1.2rem; font-weight: 800; }
.pj-clan { color: var(--gold-soft); font-size: .85rem; font-weight: 700; }
.pj-train { color: var(--text-dim); font-weight: 600; }
.pj-card .btn { margin-top: auto; }
.pj-add { align-items: center; justify-content: center; text-align: center; color: var(--text-dim);
  border-style: dashed; gap: 6px; text-decoration: none; transition: border-color .15s, color .15s; }
.pj-add:hover { border-color: var(--red); color: var(--white); }
.pj-add-plus { font-size: 2rem; line-height: 1; color: var(--red-2); }
/* Colores de tipografía por facción (army/caos/neutro). */
.pj-nick.acao25 { color: var(--armada); }
.pj-nick.acao5 { color: var(--caos); }
.pj-nick.acao4 { color: var(--gold); }

.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 12px; }
.stat { background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 14px; }
.stat-label { display: block; color: var(--text-dim); font-size: .75rem; text-transform: uppercase; letter-spacing: .8px; margin-bottom: 6px; }
.stat-val { font-size: 1.4rem; font-weight: 800; color: var(--white); }
.stat-val.rank-big { color: var(--gold-bright); }

.banlog-box { margin-top: 24px; }
.banlog-box > summary { cursor: pointer; color: var(--gold-soft); font-weight: 600; padding: 8px 0; }
.banlog-box > summary:hover { color: var(--gold-bright); }
.banlog-box[open] > summary { margin-bottom: 12px; }

/* Ficha de personaje (ver): preview de cabeza + stats en barras. */
.pj-sheet { display: grid; grid-template-columns: 160px 1fr; gap: 26px; align-items: start; }
/* Render compuesto del PJ (cuerpo+cabeza[+equipo]); pixel-art nítido. */
.pj-render-img { image-rendering: crisp-edges; image-rendering: pixelated; display: block; height: 150px; width: auto; }
.pj-card-art { height: 112px; margin: 0 auto 6px; }
.pj-render {
  display: flex; align-items: center; justify-content: center;
  min-height: 130px; padding: 14px;
  background: radial-gradient(120px 120px at 50% 40%, rgba(204,0,0,.18), transparent 70%), var(--bg);
  border: 1px solid var(--line-2); border-radius: var(--radius-sm);
}
/* Plato oscuro interior donde se dibuja la cabeza del PJ. */
.pj-render #render_pj {
  display: flex; align-items: center; justify-content: center;
  width: 92px; height: 92px;
  background: #07090d;
  border: 1px solid var(--line-2); border-radius: var(--radius-sm);
  box-shadow: inset 0 0 18px rgba(0,0,0,.75);
  overflow: hidden;
}
/* Cabeza: tile 16x16 del sprite heads.png. La posición exacta la pone .heads_N
   (heads.css, linkeado en el layout vía /assets/). Se agranda con transform:scale
   (NO background-size: rompería los offsets) y pixelated para que el pixel-art quede nítido. */
#rpjcabeza {
  width: 16px; height: 16px;
  background-image: url(/assets/_images/_panel/heads.png);
  background-repeat: no-repeat;
  image-rendering: crisp-edges; image-rendering: pixelated;
  transform: scale(4);
  transform-origin: center center;
}
.pj-stats { min-width: 0; }
/* Vida / Maná reales (razas.vida+vidaup / razas.mana): cápsulas destacadas. */
.pj-hpmp { display: flex; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.hpmp-item {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 14px; border-radius: var(--radius-sm);
  border: 1px solid var(--line-2); background: var(--bg);
  flex: 1 1 0; min-width: 120px;
}
.hpmp-ico { font-size: 1.05rem; line-height: 1; }
.hpmp-label { color: var(--text-dim); font-weight: 600; text-transform: uppercase; letter-spacing: 1px; font-size: .72rem; }
.hpmp-val { margin-left: auto; font-size: 1.25rem; font-weight: 800; color: var(--white); }
.hpmp-vida { box-shadow: inset 0 0 18px rgba(204,0,0,.10); }
.hpmp-vida .hpmp-ico { color: var(--red); }
.hpmp-mana { box-shadow: inset 0 0 18px rgba(60,120,220,.12); }
.hpmp-mana .hpmp-ico { color: #5aa0ff; }
.pj-vida { color: var(--text-dim); font-weight: 600; margin-bottom: 14px; }
.jjk { color: var(--text); font-weight: 600; font-size: .9rem; margin: 0 0 12px; }
.jjk span { color: var(--gold-soft); }
.jjk .barras { display: block; width: 100%; margin-top: 5px; }
.jjk .barra_fondo { height: 12px; }

/* Acciones del personaje (ex menu_pj): tarjetas-botón. */
.pj-actions { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; margin-top: 22px; }
.pj-action {
  display: flex; flex-direction: column; gap: 4px;
  padding: 14px 16px; border-radius: var(--radius-sm);
  background: linear-gradient(180deg, var(--bg-2), var(--bg-3));
  border: 1px solid var(--line); color: var(--text);
  transition: transform .12s ease, border-color .15s ease, box-shadow .15s ease;
}
.pj-action:hover { transform: translateY(-2px); border-color: var(--red); color: var(--white); box-shadow: var(--shadow); }
.pj-action.danger:hover { border-color: var(--caos); }
.pj-action-t { font-weight: 800; font-size: 1rem; }
.pj-action.danger .pj-action-t { color: var(--caos); }
.pj-action-d { color: var(--text-dim); font-size: .82rem; }

/* Tienda de rangos (Meditaciones / Colores): billetera + grilla de cards.
   Compartido por views/meditaciones y views/colores (antes CSS inline). */
.rk-badge { display:inline-block; padding:3px 14px; border-radius:999px; color:#fff; font-weight:800; letter-spacing:.4px; }
.rk-wallet { display:flex; flex-wrap:wrap; gap:14px; margin:16px 0 4px; }
.rk-coin { padding:10px 16px; border:1px solid var(--line-2); border-radius:var(--radius-sm); background:var(--bg); color:var(--text); font-weight:600; }
.rk-coin b { color:var(--gold-bright); }
.rk-coin-ico { margin-right:4px; }
.rk-sec { margin:26px 0 10px; color:var(--gold); border-bottom:1px solid var(--line); padding-bottom:6px; }
.rk-shop { display:grid; grid-template-columns:repeat(auto-fill, minmax(260px,1fr)); gap:14px; }
.rk-item { display:flex; gap:14px; padding:14px; align-items:flex-start; }
.rk-item.rk-eq { border-color:var(--ok); box-shadow:inset 0 0 22px rgba(70,212,134,.10); }
.rk-item-ico { width:52px; height:52px; flex:0 0 auto; display:flex; align-items:center; justify-content:center;
  background:var(--bg); border:1px solid var(--line-2); border-radius:var(--radius-sm); }
.rk-item-ico img { width:40px; height:40px; image-rendering:pixelated; }
.rk-item-ico img.rk-fx-anim { width:48px; height:48px; object-fit:contain; image-rendering:pixelated; }
/* Las auras (FX) van hasta 256x256 y varias son ALTAS (Grande 80x169,
   Mayor 120x255): recuadro alto + contain para que se vean ENTERAS. */
.rk-item-ico.rk-ico-fx { width:110px; height:150px; }
.rk-item-ico.rk-ico-fx img.rk-fx-anim { width:100px; height:140px; object-fit:contain; }
.cos-swatch-lg { width:36px; height:36px; border-radius:6px; border:1px solid var(--line-2); }
.rk-fx { font-weight:800; color:var(--gold-soft); font-size:.85rem; }
.rk-item-body { min-width:0; flex:1; }
.rk-item-name { font-weight:800; color:var(--white); }
.rk-eq-tag { font-size:.62rem; font-weight:800; color:var(--ok); border:1px solid var(--ok); border-radius:4px; padding:1px 5px; vertical-align:middle; }
.rk-item-desc { color:var(--text-dim); font-size:.82rem; margin:3px 0 6px; }
.rk-item-price { font-weight:700; color:var(--text); margin-bottom:10px; }
.rk-free { color:var(--ok); }
.rk-owned { color:var(--armada); }
.rk-lock { color:var(--text-dim); font-size:.85rem; }
.rk-item-act .btn { padding:8px 16px; font-size:.8rem; }
.rk-item-act form { margin:0; }

/* Ficha del PJ: línea de ups de vida (nacimiento + cada nivel comprado). */
.pj-ups { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 10px 0 4px; }
.pj-ups-label { color: var(--text-dim); font-size: .8rem; text-transform: uppercase; letter-spacing: .6px; }
.up-chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 3px 9px; border-radius: 999px;
  background: var(--bg-3); border: 1px solid var(--line);
  font-size: .8rem;
}
.up-chip-n { color: var(--text-dim); }
.up-chip-v { color: var(--ok); }
.up-chip.zero .up-chip-v { color: var(--text-dim); }
.up-chip.max { border-color: var(--gold); }
.up-chip.max .up-chip-v { color: var(--gold); }

/* Panel GM: categorías desplegables (acordeón exclusivo via details[name]). */
.gm-cats { display: flex; flex-direction: column; gap: 12px; margin-top: 22px; }
.gm-cat {
  border: 1px solid var(--line); border-radius: var(--radius-sm);
  background: linear-gradient(180deg, var(--bg-2), var(--bg-3));
  overflow: hidden;
}
.gm-cat summary {
  display: flex; align-items: center; gap: 14px;
  padding: 16px 18px; cursor: pointer; list-style: none; user-select: none;
  transition: background .15s ease;
}
.gm-cat summary::-webkit-details-marker { display: none; }
.gm-cat summary:hover { background: rgba(255, 255, 255, .03); }
.gm-cat-ico { font-size: 1.4rem; line-height: 1; filter: grayscale(.25); }
.gm-cat-txt { display: flex; flex-direction: column; gap: 2px; flex: 1; }
.gm-cat-t { font-weight: 800; font-size: 1.05rem; color: var(--white); }
.gm-cat-d { color: var(--text-dim); font-size: .82rem; }
.gm-cat-n {
  min-width: 26px; text-align: center; padding: 3px 8px; border-radius: 999px;
  background: rgba(192, 0, 0, .18); border: 1px solid rgba(192, 0, 0, .45);
  color: var(--text); font-size: .78rem; font-weight: 700;
}
.gm-cat summary::after {
  content: '▾'; color: var(--text-dim); font-size: .9rem;
  transition: transform .15s ease;
}
.gm-cat[open] summary::after { transform: rotate(180deg); }
.gm-cat[open] summary { border-bottom: 1px solid var(--line); }
.gm-cat[open] { border-color: var(--red); }
.gm-cat .pj-actions { margin-top: 0; padding: 14px 16px 16px; }

/* Crear personaje: form + preview lado a lado. */
.pj-create { display: grid; grid-template-columns: 1fr 200px; gap: 28px; align-items: start; }
.pj-create-form { max-width: none; }
.pj-create-form select { width: 100%; margin: 0 0 18px; }
.pj-create-preview { display: flex; flex-direction: column; gap: 12px; align-items: center; }
.pj-create-preview .pj-render { width: 100%; }
.pj-head-picker { display: flex; align-items: center; gap: 14px; color: var(--text-dim); font-weight: 700; font-size: .85rem; text-transform: uppercase; letter-spacing: 1px; }
.pj-head-picker a { font-size: 1.2rem; color: var(--gold-soft); padding: 2px 8px; border: 1px solid var(--line-2); border-radius: var(--radius-sm); }
.pj-head-picker a:hover { color: var(--white); border-color: var(--red); }

.auth-form input:disabled, input:disabled { opacity: .55; cursor: not-allowed; }

/* ------------------------------------------------------------------ CLAN ---*/
.clan-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; align-items: start; }
.clan-grid .card { margin: 0; }
.card-title { color: var(--gold); font-size: 1.05rem; font-weight: 800; margin: 0 0 14px; padding-bottom: 10px; border-bottom: 1px solid var(--line); }
/* fila genérica nombre + acción (miembros, solicitudes). */
.clan-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 9px 0; border-bottom: 1px solid var(--line); }
.clan-row:last-child { border-bottom: 0; }
.clan-row .nick { font-weight: 700; color: var(--text); }
.clan-row .acts { display: flex; gap: 6px; }
.clan-empty { color: var(--text-dim); padding: 8px 0; }
.clan-toggle-box { margin-top: 12px; }
/* requisitos para crear clan. */
.req-step { padding: 14px 0; border-bottom: 1px solid var(--line); }
.req-step:last-child { border-bottom: 0; }
.req-step h3 { margin: 0 0 6px; color: var(--white); font-size: 1rem; }
.req-step p { margin: 0; color: var(--text-dim); }
/* chat del clan (reemplaza el #messagewindow legacy). */
#messagewindow {
  height: 160px; width: 100% !important;
  border: 1px solid var(--line-2) !important; border-radius: var(--radius-sm);
  padding: 10px !important; background: var(--bg) !important;
  color: var(--text); font-family: var(--font) !important; font-size: .85rem !important;
  overflow: auto;
}
#messagewindow b { color: var(--gold-soft); }
#chatform { display: flex; align-items: center; gap: 8px; padding: 10px 0 0 !important; margin: 0 !important; }
#chatform input.edit { flex: 1 1 auto; }
@media (max-width: 720px) { .clan-grid { grid-template-columns: 1fr; } }

/* ----------------------------------------------- MERCADO / BÓVEDA / SKILLS --*/
.arial11 { font-size: .85rem; }
.arial11.ma15, a .arial11 { color: var(--gold-soft); font-weight: 600; }
/* Grids de items (mochila/bóveda/comerciante). */
.invent, .boveda {
  width: auto; max-width: 100%; margin: 0 0 22px;
  border-collapse: separate; border-spacing: 5px;
  background: linear-gradient(180deg, var(--bg-2), var(--bg-3));
  border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 12px 14px;
}
.invent th, .boveda th { border: 0 !important; padding: 4px 4px 10px; }
.invent th .flashtext, .boveda th .flashtext {
  margin: 0; padding: 0 0 8px; border: 0; background: none; text-align: left;
  font-size: 1.05rem; color: var(--gold);
}
.initem {
  width: 46px; height: 46px; padding: 2px !important; text-align: center; vertical-align: middle;
  background: var(--bg) !important; border: 1px solid var(--line-2) !important; border-radius: 6px;
  cursor: pointer; transition: border-color .12s ease, box-shadow .12s ease;
}
.initem:hover { border-color: var(--red) !important; }
.initem img { max-width: 38px; max-height: 38px; vertical-align: middle; }
.initem.item_elegido {
  border-color: var(--gold) !important;
  box-shadow: 0 0 0 2px var(--red-glow); background: rgba(204, 0, 0, 0.14) !important;
}
.inbutton { border: 0 !important; padding: 12px 2px 2px !important; }
/* Preview del icono junto al campo grh en el editor de items (GM). */
.grh-prev { display: inline-flex; align-items: center; justify-content: center; cursor: default; vertical-align: middle; margin-left: 8px; }

/* ---- Panel GM de items: toolbar + tabs por categoría + grilla compacta ---- */
.items-toolbar { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin: 0 0 16px; }
.items-search { flex: 1; min-width: 200px; max-width: 360px; }
.items-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 18px; }
.itab {
  cursor: pointer; padding: 8px 14px; border-radius: 999px; font-weight: 700; font-size: .85rem;
  background: var(--bg-2); border: 1px solid var(--line); color: var(--text-dim); transition: all .12s ease;
}
.itab:hover { color: var(--white); border-color: var(--line-2); }
.itab.active { background: var(--red); border-color: var(--red); color: #fff; }
.itab-n { opacity: .7; font-size: .78rem; margin-left: 3px; }
.item-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 10px; }
.item-card {
  display: flex; align-items: center; gap: 12px; padding: 10px 12px;
  background: linear-gradient(180deg, var(--bg-2), var(--bg-3)); border: 1px solid var(--line); border-radius: var(--radius-sm);
}
.item-card:hover { border-color: var(--line-2); }
.item-ico {
  width: 40px; height: 40px; flex: 0 0 auto; display: flex; align-items: center; justify-content: center;
  background: var(--bg); border: 1px solid var(--line-2); border-radius: 6px;
}
.item-ico img { max-width: 34px; max-height: 34px; image-rendering: pixelated; }
.item-info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.item-name { font-weight: 700; color: var(--white); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.item-meta { font-size: .78rem; color: var(--text-dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.item-meta .idv { color: var(--gold-soft); }
.item-edit { flex: 0 0 auto; padding: 6px 12px; font-size: .8rem; }
.newbie-tag { font-size: .62rem; color: var(--gold-bright); font-weight: 800; margin-left: 4px; }

/* ---- /admin/mercaderes: asignación de tienda por item ---- */
.merc-pills { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 16px; }
.merc-pill {
  cursor: pointer; padding: 6px 13px; font-size: .82rem; font-weight: 700;
  color: var(--text-dim); background: var(--bg-2); border: 1px solid var(--line); border-radius: 999px;
}
.merc-pill:hover { color: var(--white); border-color: var(--line-2); }
.merc-pill.active { color: var(--white); border-color: var(--red); background: var(--red-glow); }
.merc-select {
  flex: 0 0 auto; min-width: 116px; padding: 6px 8px; font-size: .82rem; font-weight: 700;
  color: var(--white); background: var(--bg); border: 1px solid var(--line-2); border-radius: 6px; cursor: pointer;
}
.merc-select:focus { outline: none; border-color: var(--red); }
.item-card.saved { border-color: var(--ok); box-shadow: 0 0 0 2px rgba(60,200,120,.18); transition: box-shadow .2s ease; }
.item-card.save-err { border-color: var(--caos); box-shadow: 0 0 0 2px rgba(220,60,60,.2); }

/* ------------------------------------------------- FOTO DE PERFIL (avatar) ---*/
.avatar-block { display: flex; gap: 22px; align-items: center; flex-wrap: wrap; }
.avatar-img {
  width: 112px; height: 112px; border-radius: 50%; object-fit: cover; flex: 0 0 auto;
  border: 2px solid var(--line-2); box-shadow: 0 0 0 4px rgba(0,0,0,.35); background: var(--bg);
}
.avatar-fallback {
  display: flex; align-items: center; justify-content: center;
  font-size: 2.7rem; font-weight: 800; color: var(--white); user-select: none;
  background: radial-gradient(circle at 50% 32%, var(--red-2), var(--red)); border-color: var(--red);
}
.avatar-actions { display: flex; flex-direction: column; gap: 8px; min-width: 190px; }
.avatar-form { margin: 0; display: flex; }
.avatar-form .btn { width: 100%; }
.avatar-pick { position: relative; overflow: hidden; cursor: pointer; }
.avatar-pick input[type=file] { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
.avatar-pick span { display: block; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.avatar-remove { color: var(--text-dim); }
.avatar-hint { margin: 2px 0 0; font-size: .72rem; color: var(--text-dim); }
.profile-sep { border: 0; border-top: 1px solid var(--line); margin: 22px 0; }
.inbutton span { color: var(--text-dim); }

/* Menús de acción del mercado (menu_pj) y entrenador (menu_ent): tarjetas-botón. */
#menu_pj, #menu_ent { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
#menu_pj li, #menu_ent li { margin: 0; }
#menu_pj a, #menu_ent a {
  display: block; padding: 14px 16px; border-radius: var(--radius-sm);
  background: linear-gradient(180deg, var(--bg-2), var(--bg-3));
  border: 1px solid var(--line); color: var(--white); font-weight: 700;
  transition: transform .12s ease, border-color .15s ease, box-shadow .15s ease;
}
#menu_pj a:hover, #menu_ent a:hover { transform: translateY(-2px); border-color: var(--red); box-shadow: var(--shadow); }
.desc { display: block; margin-top: 5px; color: var(--text-dim); font-weight: 500; font-size: .85rem; }
.desc .barras { display: block; width: 100%; max-width: 320px; margin-top: 6px; }
.verde { color: var(--ok); font-weight: 700; }
.rojo { color: var(--caos); font-weight: 700; }
input.edit { width: auto; }

/* Iconos de mercaderes (Armero/Herrero/Carpintero/Sastre) del original htdocs
   (_panel/trade1..4.png). Se superpone el icono sobre el gradiente de la card. */
#menu_pj li[id^="trade"] a {
  padding-left: 88px; min-height: 64px;
  background-repeat: no-repeat, no-repeat;
  background-position: 16px center, 0 0;
  background-size: 56px 56px, auto;
}
#trade1 a { background-image: url(/assets/_images/_panel/trade1.png), linear-gradient(180deg, var(--bg-2), var(--bg-3)); }
#trade2 a { background-image: url(/assets/_images/_panel/trade2.png), linear-gradient(180deg, var(--bg-2), var(--bg-3)); }
#trade3 a { background-image: url(/assets/_images/_panel/trade3.png), linear-gradient(180deg, var(--bg-2), var(--bg-3)); }
#trade4 a { background-image: url(/assets/_images/_panel/trade4.png), linear-gradient(180deg, var(--bg-2), var(--bg-3)); }

/* ----------------------------------------------------- COMERCIO (mercado) ---*/
.trade-bar {
  display: flex; flex-wrap: wrap; gap: 10px 28px; align-items: center;
  margin: 0 0 18px; padding: 12px 18px; border-radius: var(--radius-sm);
  background: linear-gradient(180deg, var(--bg-2), var(--bg-3)); border: 1px solid var(--line);
}
.trade-oro { font-size: 1.02rem; }
.trade-oro .idv { color: var(--gold-bright); font-size: 1.2rem; }
.trade-restock { margin-left: auto; color: var(--text-dim); font-size: .88rem; }
.trade-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; align-items: start; }
.trade-pane { padding: 16px 18px 18px; transition: border-color .15s ease, box-shadow .15s ease; }
.trade-pane-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; margin-bottom: 14px; }
.trade-pane-head h3 { margin: 0; }
.trade-hint { color: var(--text-dim); font-size: .76rem; }
.trade-hint b { color: var(--gold-soft); font-weight: 700; }
.trade-grid { display: grid; gap: 6px; }
.grid-com { grid-template-columns: repeat(6, 1fr); }
.grid-bov { grid-template-columns: repeat(6, 1fr); }
.grid-inv { grid-template-columns: repeat(4, 1fr); }
.trade-grid .initem { width: 100%; height: auto; min-height: 46px; aspect-ratio: 1 / 1; }
.initem.has-item { cursor: grab; }
.initem.has-item:active { cursor: grabbing; }
.initem.dragging { opacity: .35; }
.trade-pane.drop-ok { border-color: var(--gold) !important; box-shadow: 0 0 0 2px var(--red-glow); }
/* Drag image custom: el item "volando" (icono agrandado y resaltado). */
.drag-ghost {
  position: fixed; top: -1000px; left: -1000px; pointer-events: none;
  padding: 6px; border-radius: 8px; background: rgba(204, 0, 0, 0.18);
  border: 1px solid var(--gold); box-shadow: 0 8px 22px rgba(0, 0, 0, .55);
}
.drag-ghost img { display: block; width: 54px; height: 54px; max-width: none; max-height: none; }
/* Pulso del slot que acaba de recibir un item (feedback "en vivo" del depósito/retiro). */
.initem.just-landed { animation: initem-land .55s ease; }
@keyframes initem-land {
  0%   { transform: scale(.55); border-color: var(--gold) !important; box-shadow: 0 0 0 3px var(--gold); }
  55%  { transform: scale(1.14); box-shadow: 0 0 0 3px var(--red-glow); }
  100% { transform: scale(1); }
}
.trade-actions { margin-top: 14px; }
.trade-actions .btn { width: 100%; }
.trade-actions .btn:disabled { opacity: .5; cursor: default; }
@media (max-width: 760px) { .trade-cols { grid-template-columns: 1fr; } }

/* ------------------------------------------------- ESTADÍSTICAS / SERVERS ---*/
.table-wrap { overflow-x: auto; }
.server-table td { vertical-align: middle; }
.srv-empty { margin: 6px 0; color: var(--text-dim); }
.srv-dot {
  display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 8px;
  background: var(--ok); box-shadow: 0 0 0 3px rgba(70, 212, 134, .18); vertical-align: middle;
}
.srv-name { font-weight: 700; color: var(--white); }
.srv-oficial {
  margin-left: 8px; font-size: .62rem; font-weight: 800; letter-spacing: .6px; vertical-align: middle;
  color: var(--gold-bright); border: 1px solid var(--gold); border-radius: 4px; padding: 1px 6px;
}
.srv-cap { display: flex; align-items: center; gap: 9px; min-width: 130px; }
.srv-cap-bar { flex: 1; height: 8px; border-radius: 5px; background: var(--bg); border: 1px solid var(--line-2); overflow: hidden; }
.srv-cap-bar span { display: block; height: 100%; background: linear-gradient(90deg, var(--red), var(--gold)); }
.srv-cap-n { font-size: .82rem; color: var(--text-dim); font-weight: 700; white-space: nowrap; }
.srv-chart {
  display: flex; align-items: flex-end; gap: 3px; height: 110px; margin: 12px 0 8px;
  border-bottom: 1px solid var(--line-2); padding-bottom: 2px;
}
.srv-bar {
  flex: 1; min-width: 4px; border-radius: 3px 3px 0 0;
  background: linear-gradient(180deg, var(--gold-soft), var(--red-2)); transition: opacity .15s ease;
}
.srv-bar:hover { opacity: .65; }

/* ----------------------------------------------------------- GM / ADMIN ----*/
/* Forms densos legacy: label arriba, input full-width. (.input span + .clear). */
.input { display: block; margin: 0 0 12px; }
.input input[type="text"], .input input[type="password"], .input select, input.t { width: 100%; max-width: 380px; }
.mtahoma { font-size: .8rem; color: var(--text-dim); }
.lh8 { line-height: 1.55; }
#errdiv, .errdiv {
  display: block; padding: 12px 16px; border-radius: var(--radius-sm); margin: 0 0 18px;
  font-weight: 600; border: 1px solid rgba(224, 21, 21, 0.45);
  background: rgba(224, 21, 21, 0.12); color: #ffd2cb;
}
/* Tablas de listado admin (items/updates/balance) dentro de card visual. */
.admin-list { margin-top: 0; }
.admin-list td { vertical-align: middle; }
.admin-list .initem { width: 46px; height: 46px; }
.admin-list .initem img { max-width: 38px; max-height: 38px; }

@media (max-width: 620px) {
  .pj-sheet, .pj-create { grid-template-columns: 1fr; }
  .pj-create-preview { order: -1; }
}

/* ------------------------------------------------------------------- AUTH --*/
.auth-wrap { display: flex; justify-content: center; padding: 24px 0 60px; }
.auth-card { width: 100%; max-width: 420px; padding: 34px 32px; }
.auth-title { text-align: center; margin-bottom: 26px; }
.auth-form label { display: block; color: var(--text-dim); font-size: .85rem; font-weight: 600; margin: 0 0 7px; }
.auth-form input[type="text"], .auth-form input[type="password"], .auth-form input[type="email"] {
  width: 100%; margin: 0 0 18px;
}
.auth-form label.check { display: flex; align-items: center; gap: 9px; color: var(--text); margin: 0 0 22px; font-size: .92rem; }
.auth-form label.check input { margin: 0; }
.auth-links { text-align: center; margin-top: 20px; padding-top: 18px; border-top: 1px solid var(--line); color: var(--text-dim); font-size: .9rem; }
.auth-note { color: var(--text-dim); font-size: .9rem; line-height: 1.5; margin: 0 0 20px; }

/* -------------------------------------------------------------- RESPONSIVE --*/
@media (max-width: 860px) {
  .grid-home, .grid-2, .layout-panel { grid-template-columns: 1fr; }
  .sidebar { position: static; }
  .nav, .header-spacer { display: none; }
  .burger { display: inline-flex; }
  /* menú móvil desplegable */
  .nav.open {
    display: flex; flex-direction: column; gap: 2px;
    position: absolute; top: var(--header-h); left: 0; right: 0;
    padding: 12px; background: var(--bg-2); border-bottom: 1px solid var(--line-2);
    box-shadow: var(--shadow);
  }
  .nav.open a { width: 100%; }
  .hero { padding: 40px 18px; }
  .container { padding: 20px 16px 48px; }
}
@media (max-width: 480px) {
  .account > .account-btn .uname { display: none; }
  h1 { font-size: 1.5rem; }
}
