/* =============================================================
   Review Cards — base compartida (tarjeta + panel)
   ============================================================= */
:root {
  --paper: #faf8f4;
  --surface: #ffffff;
  --surface-2: #f2efe8;
  --ink: #1d1b16;
  --ink-soft: #3b3830;
  --mute: #6d685c;
  --line: rgba(29, 27, 22, 0.12);
  --line-soft: rgba(29, 27, 22, 0.07);
  --brand: #2f5d50;          /* acento de la plataforma (panel) */
  --brand-ink: #ffffff;
  --ok: #2f7a4a;  --ok-bg: #e5f2e9;
  --warn: #8a5a0b; --warn-bg: #f8edd5;
  --err: #9a2f1d; --err-bg: #f8e1da;
  --star: #e0a42c;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 1px 2px rgba(29,27,22,.05), 0 14px 32px -22px rgba(29,27,22,.45);
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #15140f; --surface: #1e1c17; --surface-2: #26241e;
    --ink: #f1ede3; --ink-soft: #d8d2c4; --mute: #a59f90;
    --line: rgba(241,237,227,.14); --line-soft: rgba(241,237,227,.08);
    --brand: #6fb3a0; --brand-ink: #0f1a17;
    --ok: #7fcc98; --ok-bg: #1d3325; --warn: #e8bf6a; --warn-bg: #3a2e14; --err: #f0907a; --err-bg: #3d1f18;
    --shadow: 0 1px 2px rgba(0,0,0,.4), 0 16px 34px -22px rgba(0,0,0,.9);
  }
}
:root[data-theme="dark"] {
  --paper: #15140f; --surface: #1e1c17; --surface-2: #26241e;
  --ink: #f1ede3; --ink-soft: #d8d2c4; --mute: #a59f90;
  --line: rgba(241,237,227,.14); --line-soft: rgba(241,237,227,.08);
  --brand: #6fb3a0; --brand-ink: #0f1a17;
  --ok: #7fcc98; --ok-bg: #1d3325; --warn: #e8bf6a; --warn-bg: #3a2e14; --err: #f0907a; --err-bg: #3d1f18;
  --shadow: 0 1px 2px rgba(0,0,0,.4), 0 16px 34px -22px rgba(0,0,0,.9);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--sans); font-size: 16px; line-height: 1.55;
  color: var(--ink); background: var(--paper);
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; }
a { color: inherit; }
h1, h2, h3 { line-height: 1.15; text-wrap: balance; letter-spacing: -0.01em; }
p { text-wrap: pretty; }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; border-radius: 6px; }

/* ---------- botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  padding: .7rem 1.2rem; border-radius: 999px; font-weight: 600; font-size: .95rem;
  text-decoration: none; white-space: nowrap;
  transition: transform .3s var(--ease), background-color .2s, box-shadow .2s, opacity .2s;
}
.btn:active { transform: scale(.97); }
.btn[disabled] { opacity: .55; cursor: wait; }
.btn-primary { background: var(--brand); color: var(--brand-ink); }
.btn-primary:hover { box-shadow: 0 8px 18px -10px var(--brand); }
.btn-ghost { box-shadow: inset 0 0 0 1.5px var(--line); }
.btn-ghost:hover { box-shadow: inset 0 0 0 1.5px var(--ink-soft); }
.btn-sm { padding: .45rem .85rem; font-size: .85rem; }
.btn-danger { color: var(--err); box-shadow: inset 0 0 0 1.5px currentColor; }

/* ---------- formularios ---------- */
.field { display: block; font-size: .85rem; font-weight: 600; color: var(--ink-soft); }
.field > :is(.input, .textarea, .select, .hint, .cp-hint, .cp-color) { display: block; margin-top: .35rem; }
.field > .color-row { margin-top: .35rem; }
.field .opt { font-weight: 400; color: var(--mute); }
.input, .textarea, .select {
  font: inherit; font-weight: 400; color: var(--ink); width: 100%;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm);
  padding: .65rem .8rem; transition: border-color .2s, box-shadow .2s;
}
.textarea { min-height: 110px; resize: vertical; }
.input:focus, .textarea:focus, .select:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 22%, transparent); }
.check { display: flex; gap: .55rem; align-items: flex-start; font-size: .85rem; font-weight: 400; color: var(--ink-soft); }
.check input { margin-top: .2rem; accent-color: var(--brand); }

.msg { font-size: .88rem; padding: .65rem .85rem; border-radius: var(--radius-sm); }
.msg-err { background: var(--err-bg); color: var(--err); }
.msg-ok { background: var(--ok-bg); color: var(--ok); }

.pill { display: inline-flex; align-items: center; gap: .3rem; font-size: .72rem; font-weight: 700; letter-spacing: .03em;
  padding: .2rem .55rem; border-radius: 999px; background: var(--surface-2); color: var(--ink-soft); white-space: nowrap; }
.pill.ok { background: var(--ok-bg); color: var(--ok); }
.pill.warn { background: var(--warn-bg); color: var(--warn); }
.pill.err { background: var(--err-bg); color: var(--err); }

.toast {
  position: fixed; left: 50%; bottom: 1.4rem; z-index: 100;
  transform: translate(-50%, 140%); opacity: 0; visibility: hidden;
  background: var(--ink); color: var(--paper); padding: .7rem 1.15rem; border-radius: 999px; font-size: .9rem;
  transition: transform .4s var(--ease), opacity .3s, visibility 0s .4s;
}
.toast.is-on { transform: translate(-50%, 0); opacity: 1; visibility: visible; transition-delay: 0s; }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; } }
