
:root {
  --bg: #f7f6f3; --surface: #ffffff; --surface-2: #f0eee9; --text: #1d1b18; --muted: #6b665d; --border: #e3dfd6;
  --accent: #6a4cdb; --accent-soft: #efeafd; --accent-text: #ffffff; --ok: #2f7d3a; --warn: #a3620a; --err: #b42318;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #121214; --surface: #1b1b1f; --surface-2: #24242a; --text: #ecebe8; --muted: #a29e96; --border: #2f2f36;
    --accent: #9d86ff; --accent-soft: #2a2540; --accent-text: #121214; --ok: #79d18a; --warn: #f1b45f; --err: #ff8a80;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #121214; --surface: #1b1b1f; --surface-2: #24242a; --text: #ecebe8; --muted: #a29e96; --border: #2f2f36;
  --accent: #9d86ff; --accent-soft: #2a2540; --accent-text: #121214; --ok: #79d18a; --warn: #f1b45f; --err: #ff8a80;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body { background: var(--bg); color: var(--text); font: 16px/1.55 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; }
.wrap { max-width: 1320px; margin: 0 auto; padding: 0 16px; }
.muted { color: var(--muted); }
.top { background: var(--surface); border-bottom: 1px solid var(--border); }
.top-in { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; padding-top: 18px; padding-bottom: 18px; }
h1 { margin: 0; font-size: 26px; letter-spacing: -0.015em; }
.top p { margin: 2px 0 0; font-size: 14px; max-width: 720px; }
.tech { color: var(--muted); font-size: 14px; text-decoration: none; border: 1px solid var(--border); padding: 6px 12px; border-radius: 999px; }
.tech:hover { color: var(--text); }
.layout { display: grid; grid-template-columns: 210px minmax(0, 1fr) minmax(300px, 400px); gap: 24px; align-items: start; padding-top: 22px; padding-bottom: 48px; }
/* pasos */
.steps ol { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; position: sticky; top: 16px; }
.steps button { display: flex; gap: 10px; align-items: center; width: 100%; text-align: left; background: none; border: 0; border-radius: 10px; padding: 8px 10px; font: inherit; font-size: 15px; color: var(--muted); cursor: pointer; }
.steps button:hover { background: var(--surface-2); color: var(--text); }
.steps button[aria-current="step"] { background: var(--accent-soft); color: var(--text); font-weight: 600; }
.steps .n { width: 24px; height: 24px; flex: none; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; background: var(--surface-2); color: var(--muted); }
.steps button[aria-current="step"] .n { background: var(--accent); color: var(--accent-text); }
/* panel del paso */
.panel { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 20px 22px; min-width: 0; }
.panel h2 { margin: 0 0 4px; font-size: 22px; letter-spacing: -0.01em; }
.panel .kicker { font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.panel .lead { margin: 0 0 18px; color: var(--muted); }
.panel h3 { margin: 22px 0 8px; font-size: 16px; }
.panel h3:first-of-type { margin-top: 6px; }
.field { display: flex; flex-direction: column; gap: 4px; margin-bottom: 14px; }
.field .lbl { font-weight: 600; font-size: 14px; }
.field .help, .help { font-size: 13px; color: var(--muted); }
input[type=text], input[type=number], textarea, select { font: inherit; font-size: 15px; color: var(--text); background: var(--bg); border: 1px solid var(--border); border-radius: 8px; padding: 8px 10px; width: 100%; }
textarea { resize: vertical; min-height: 64px; }
input:focus-visible, textarea:focus-visible, select:focus-visible, button:focus-visible, .drop:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 14px; }
.btn { border: 1px solid var(--border); background: var(--surface); color: var(--text); border-radius: 999px; padding: 7px 14px; font: inherit; font-size: 14px; cursor: pointer; }
.btn:hover { border-color: var(--accent); }
.btn.primary { background: var(--accent); color: var(--accent-text); border-color: var(--accent); font-weight: 600; }
.btn.small { padding: 4px 10px; font-size: 13px; }
.btns { display: flex; flex-wrap: wrap; gap: 8px; margin: 6px 0 14px; }
.pager { display: flex; justify-content: space-between; gap: 10px; margin-top: 22px; padding-top: 16px; border-top: 1px solid var(--border); }
.chip { border: 1px solid var(--border); background: var(--surface); color: var(--text); border-radius: 999px; padding: 5px 12px; font: inherit; font-size: 14px; cursor: pointer; }
.chip.active { background: var(--accent); color: var(--accent-text); border-color: var(--accent); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.notice { border-radius: 12px; padding: 12px 14px; margin-bottom: 18px; font-size: 15px; }
.notice ul { margin: 6px 0 0; padding-left: 20px; }
.notice.ok { background: color-mix(in srgb, var(--ok) 12%, transparent); }
.notice.warn { background: color-mix(in srgb, var(--warn) 14%, transparent); }
.notice.err { background: color-mix(in srgb, var(--err) 12%, transparent); }
/* inicio */
.starts { display: grid; gap: 14px; }
.start { border: 1px solid var(--border); border-radius: 12px; padding: 14px 16px; background: var(--bg); }
.start h3 { margin: 0 0 4px !important; }
.start p { margin: 0 0 10px; font-size: 14px; color: var(--muted); }
.drop { border: 2px dashed var(--border); border-radius: 12px; padding: 18px; text-align: center; cursor: pointer; display: flex; flex-direction: column; gap: 2px; margin-bottom: 10px; background: var(--surface); }
.drop span { font-size: 13px; color: var(--muted); }
.drop.over { border-color: var(--accent); background: var(--accent-soft); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.examples { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px; }
.example { border: 1px solid var(--border); border-radius: 12px; padding: 10px 12px; background: var(--surface); text-align: left; font: inherit; color: inherit; cursor: pointer; }
.example:hover { border-color: var(--accent); }
.example .nm { font-weight: 700; }
.example .meta { font-size: 12px; color: var(--muted); }
.dots { display: flex; gap: 4px; margin: 6px 0; }
.dots span { width: 20px; height: 20px; border-radius: 6px; border: 1px solid var(--border); }
/* colores */
.color-row { display: grid; grid-template-columns: 44px 1fr 96px; gap: 10px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--border); }
.color-row:last-child { border-bottom: 0; }
.color-row input[type=color] { width: 44px; height: 44px; border: 1px solid var(--border); border-radius: 10px; padding: 2px; background: var(--surface); cursor: pointer; }
.color-row .nm { font-weight: 600; font-size: 15px; }
.color-row .use { font-size: 13px; color: var(--muted); }
.color-row .hex { font: 14px ui-monospace, SFMono-Regular, Menlo, monospace; text-transform: uppercase; }
.hex.bad { border-color: var(--err); }
.palette { border: 1px solid var(--border); border-radius: 10px; padding: 6px 10px; background: var(--surface); font: inherit; font-size: 13px; color: inherit; cursor: pointer; display: inline-flex; flex-direction: column; gap: 2px; }
.palette:hover { border-color: var(--accent); }
.palette .dots span { width: 16px; height: 16px; border-radius: 4px; }
.gradbar { height: 64px; border-radius: 12px; border: 1px solid var(--border); margin: 6px 0 14px; }
input[type=range] { width: 100%; accent-color: var(--accent); }
/* chequeo de contraste */
.checks { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; font-size: 14px; }
.checks li { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.checks .st { font-weight: 700; width: 18px; text-align: center; }
.checks .ok .st { color: var(--ok); }
.checks .bad .st { color: var(--warn); }
.checks .r { font: 12px ui-monospace, SFMono-Regular, Menlo, monospace; color: var(--muted); }
.checks .sw { width: 14px; height: 14px; border-radius: 4px; border: 1px solid var(--border); display: inline-block; vertical-align: -2px; margin-right: 4px; }
/* tipografías y logos */
.weights { display: flex; flex-wrap: wrap; gap: 10px; margin: 4px 0 10px; font-size: 14px; }
.weights label { display: inline-flex; gap: 4px; align-items: center; }
.sample { border-radius: 10px; padding: 12px 14px; margin: 6px 0 18px; overflow-wrap: anywhere; }
.sample .big { font-size: 30px; line-height: 1.15; }
.sample .small { font-size: 15px; margin-top: 6px; }
.logos { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.logo-box { border: 1px solid var(--border); border-radius: 12px; min-height: 120px; display: flex; align-items: center; justify-content: center; padding: 16px; margin-bottom: 8px; }
.logo-box img { max-width: 100%; max-height: 90px; display: block; }
.logo-box .ph { font-size: 13px; opacity: .7; }
.examples-tbl { width: 100%; border-collapse: collapse; }
.examples-tbl th { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); padding: 0 8px 6px 0; }
.examples-tbl td { padding: 0 8px 8px 0; }
/* descargar */
.formats { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 10px; margin-bottom: 14px; }
.format { border: 1px solid var(--border); border-radius: 12px; padding: 12px 14px; background: var(--bg); display: flex; flex-direction: column; gap: 6px; }
.format.active { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
.format .nm { font-weight: 700; }
.format .file { font: 12px ui-monospace, SFMono-Regular, Menlo, monospace; color: var(--muted); overflow-wrap: anywhere; }
.format p { margin: 0; font-size: 13px; color: var(--muted); flex: 1; }
.format .btns { margin: 0; }
pre.out { background: var(--bg); border: 1px solid var(--border); border-radius: 10px; padding: 12px; font: 12.5px/1.5 ui-monospace, SFMono-Regular, Menlo, monospace; max-height: 420px; overflow: auto; white-space: pre-wrap; overflow-wrap: anywhere; margin: 0 0 14px; }
.howto { margin: 0; padding-left: 20px; }
.howto li { margin-bottom: 4px; }
/* vista previa */
.preview { position: sticky; top: 16px; display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.pv-card-wrap { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 14px; }
.pv-card-wrap h3 { margin: 0 0 8px; font-size: 15px; }
.pv-tabs { display: flex; gap: 6px; margin-bottom: 10px; }
.pv-scene { container-type: inline-size; position: relative; overflow: hidden; border-radius: 10px; border: 1px solid var(--border); aspect-ratio: 16 / 9; }
.pv-scene.v { aspect-ratio: 9 / 16; max-width: 240px; margin: 0 auto; }
/* el padding en cqw va en un hijo: en el propio contenedor se mediría contra el viewport */
.pv-in { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: space-between; padding: 5cqw 6cqw; }
.pv-scene.v .pv-in { padding: 9cqw 8cqw; }
.pv-glow { position: absolute; width: 60cqw; height: 60cqw; right: -18cqw; top: -22cqw; border-radius: 50%; opacity: .55; pointer-events: none; }
.pv-top { position: relative; display: flex; align-items: center; gap: 2cqw; min-height: 6cqw; }
.pv-logo { max-height: 7cqw; max-width: 30cqw; display: block; }
.pv-scene.v .pv-logo { max-height: 12cqw; max-width: 55cqw; }
.pv-name { font-weight: 800; font-size: 4.2cqw; }
.pv-scene.v .pv-name { font-size: 8cqw; }
.pv-body { position: relative; }
.pv-tag { display: inline-block; font-size: 2.4cqw; font-weight: 700; padding: .6cqw 1.6cqw; border-radius: 99px; margin-bottom: 1.6cqw; text-transform: uppercase; letter-spacing: .05em; }
.pv-scene.v .pv-tag { font-size: 4.4cqw; padding: 1.2cqw 3cqw; margin-bottom: 3cqw; }
.pv-title { font-size: 7cqw; font-weight: 800; line-height: 1.05; letter-spacing: -0.02em; }
.pv-scene.v .pv-title { font-size: 12cqw; }
.pv-sub { margin: 1.6cqw 0 0; font-size: 2.8cqw; line-height: 1.35; max-width: 70cqw; }
.pv-scene.v .pv-sub { font-size: 5cqw; margin-top: 3cqw; max-width: none; }
.pv-foot { position: relative; display: flex; align-items: flex-end; justify-content: space-between; gap: 3cqw; }
.pv-scene.v .pv-foot { flex-direction: column; align-items: stretch; gap: 4cqw; }
.pv-stat { border-radius: 2cqw; padding: 1.6cqw 2.4cqw; }
.pv-scene.v .pv-stat { border-radius: 4cqw; padding: 4cqw 5cqw; }
.pv-num { font-size: 5cqw; font-weight: 700; line-height: 1.1; }
.pv-scene.v .pv-num { font-size: 11cqw; }
.pv-cap { font-size: 2.2cqw; }
.pv-scene.v .pv-cap { font-size: 4.6cqw; }
.pv-cta { border-radius: 99px; padding: 1.4cqw 3cqw; font-size: 2.6cqw; font-weight: 700; white-space: nowrap; }
.pv-scene.v .pv-cta { font-size: 5cqw; padding: 3cqw 5cqw; text-align: center; }
.pv-palette { display: grid; grid-template-columns: repeat(8, 1fr); gap: 4px; margin-top: 10px; }
.pv-palette span { aspect-ratio: 1; border-radius: 6px; border: 1px solid var(--border); }
.pv-grad { height: 10px; border-radius: 99px; margin-top: 6px; border: 1px solid var(--border); }
@media (max-width: 1180px) {
  .layout { grid-template-columns: minmax(0, 1fr) minmax(280px, 360px); }
  .steps { grid-column: 1 / -1; }
  .steps ol { flex-direction: row; overflow-x: auto; position: static; padding-bottom: 4px; }
  .steps button { white-space: nowrap; }
}
@media (max-width: 820px) {
  .layout { grid-template-columns: minmax(0, 1fr); }
  .preview { position: static; }
  .row2 { grid-template-columns: 1fr; }
  .color-row { grid-template-columns: 44px 1fr; }
  .color-row .hex { grid-column: 2; }
}
