:root {
  --paper: #faf6f1;
  --paper-2: #f3ebe3;
  --card: #fffdfa;
  --ink: #1c1a19;
  --ink-2: #3b3735;
  --muted: #6e6560;
  --line: #e6dbd2;
  --accent: #a3161f;      /* rojo del logo */
  --accent-2: #c8262c;
  --hl: #ecc9c0;          /* resaltado rosado suave */
  --hl-soft: #f5e1db;
  --ok: #2f6b4a;
  --err: #a33a2a;

  --font-display: 'Playfair Display', 'Georgia', serif;
  --font-brand: 'Cinzel', 'Playfair Display', serif;
  --font-body: 'General Sans', 'Helvetica Neue', sans-serif;

  --text-xs: clamp(0.75rem, 0.72rem + 0.15vw, 0.8125rem);
  --text-sm: clamp(0.875rem, 0.85rem + 0.12vw, 0.9375rem);
  --text-base: clamp(1rem, 0.97rem + 0.15vw, 1.0625rem);
  --text-lg: clamp(1.125rem, 1.05rem + 0.35vw, 1.3125rem);
  --text-xl: clamp(1.625rem, 1.3rem + 1.4vw, 2.375rem);
  --text-hero: clamp(2.5rem, 1.4rem + 4.8vw, 5rem);

  --radius: 10px;
  --radius-lg: 16px;
  --shadow: 0 1px 2px rgba(30, 27, 22, .06), 0 8px 24px -12px rgba(30, 27, 22, .18);
  --ease: cubic-bezier(.2, .7, .2, 1);
  --wrap: 1180px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; height: auto; }
h1, h2, h3 { margin: 0; line-height: 1.1; text-wrap: balance; }
h1, h2 { font-family: var(--font-display); font-weight: 500; letter-spacing: -0.015em; }
h2 { font-size: var(--text-xl); }
h3 { font-size: var(--text-lg); font-weight: 600; }
p { margin: 0; }
a { color: inherit; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

.wrap { width: min(100% - 2.5rem, var(--wrap)); margin-inline: auto; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 0; background: var(--ink); color: var(--paper); padding: .5rem 1rem; z-index: 100; }
.skip:focus { left: 1rem; top: 1rem; }
.muted { color: var(--muted); }
.eyebrow {
  font-size: var(--text-xs); font-weight: 600; letter-spacing: .12em; text-transform: uppercase;
  color: var(--muted); margin-bottom: .75rem;
}
.lead { font-size: var(--text-base); color: var(--ink-2); max-width: 54ch; }

mark {
  background: linear-gradient(transparent 58%, var(--hl) 58%, var(--hl) 92%, transparent 92%);
  color: inherit; padding: 0 .08em;
}

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  min-height: 48px; padding: .75rem 1.35rem;
  background: var(--ink); color: var(--paper);
  border: 1.5px solid var(--ink); border-radius: 999px;
  font-size: var(--text-sm); font-weight: 600; text-decoration: none; cursor: pointer;
  transition: transform .2s var(--ease), background .2s, color .2s, box-shadow .2s;
}
.btn:hover { transform: translateY(-1px); box-shadow: 0 6px 16px -8px rgba(30,27,22,.5); }
.btn:active { transform: translateY(0); }
.btn--ghost { background: transparent; color: var(--ink); }
.btn:not(.btn--ghost):hover { background: var(--accent); border-color: var(--accent); }
.btn--ghost:hover { background: var(--ink); color: var(--paper); }
.btn--sm { min-height: 40px; padding: .5rem 1rem; }
.btn--block { width: 100%; }
.btn[disabled] { opacity: .6; cursor: progress; transform: none; }
.link { background: none; border: 0; padding: 0; text-decoration: underline; cursor: pointer; }

/* Header */
.top { position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--paper) 88%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid transparent; transition: border-color .2s; }
.top.is-scrolled { border-bottom-color: var(--line); }
.top__inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; height: 68px; }
.brand { display: inline-flex; align-items: center; gap: .55rem; text-decoration: none; color: var(--ink); }
.brand img { height: 44px; width: auto; }
.brand__txt { display: grid; line-height: 1; }
.brand__txt b { font-family: var(--font-brand); font-weight: 700; font-size: 1.3rem; letter-spacing: .03em; text-transform: uppercase; }
.brand__txt small { font-size: .62rem; font-weight: 500; letter-spacing: .48em; text-transform: uppercase; color: var(--muted); margin-top: .3rem; padding-left: .1em; }
.nav { display: flex; gap: 1.75rem; font-size: var(--text-sm); }
.nav a { text-decoration: none; color: var(--ink-2); }
.nav a:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; }

/* Hero */
.hero { padding-block: clamp(2.5rem, 6vw, 5.5rem) clamp(3rem, 7vw, 6rem); }
.hero__grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }
.hero h1 { font-size: var(--text-hero); line-height: 1.02; margin-bottom: 1.5rem; }
.hero__cta { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 2rem; }
.facts { list-style: none; padding: 0; margin: 2.75rem 0 0; display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--line); }
.facts li { padding: 1rem 1rem 0 0; display: flex; flex-direction: column; gap: .15rem; }
.facts li + li { padding-left: 1rem; border-left: 1px solid var(--line); }
.facts strong { font-family: var(--font-display); font-size: var(--text-lg); font-weight: 500; }
.facts span { font-size: var(--text-xs); color: var(--muted); }
.hero__media { margin: 0; position: relative; }
.hero__media img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; border-radius: var(--radius-lg); box-shadow: var(--shadow); }
.hero__media::before {
  content: ""; position: absolute; inset: auto -14px -14px auto; width: 55%; height: 40%;
  background: var(--accent); border-radius: var(--radius-lg); z-index: -1;
}

/* Sections */
.section { padding-block: clamp(3.5rem, 8vw, 7rem); }
.section--alt { background: var(--paper-2); }
.section__head { display: flex; justify-content: space-between; align-items: end; gap: 1.5rem; flex-wrap: wrap; margin-bottom: 1.5rem; }

.search { position: relative; display: block; width: min(100%, 340px); }
.search svg { position: absolute; left: 14px; top: 50%; width: 18px; height: 18px; transform: translateY(-50%); fill: none; stroke: var(--muted); stroke-width: 2; stroke-linecap: round; }
.search input {
  width: 100%; height: 46px; padding: 0 1rem 0 2.6rem; font: inherit; font-size: var(--text-sm);
  background: var(--card); border: 1px solid var(--line); border-radius: 999px; color: var(--ink);
}
.search input:focus { outline: none; border-color: var(--ink); }

.chips { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 2rem; }
.chip {
  min-height: 38px; padding: .4rem 1rem; border-radius: 999px; border: 1px solid var(--line);
  background: transparent; font-size: var(--text-sm); cursor: pointer; transition: background .15s, border-color .15s;
}
.chip:hover { border-color: var(--ink); }
.chip[aria-pressed="true"] { background: var(--ink); color: var(--paper); border-color: var(--ink); }

.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem; }
.card {
  display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius-lg); padding: 1.5rem; transition: transform .25s var(--ease), box-shadow .25s;
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.card__top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.25rem; }
.tag { font-size: var(--text-xs); font-weight: 600; padding: .2rem .6rem; border-radius: 4px; background: var(--hl-soft); }
.card__lvl { font-size: var(--text-xs); color: var(--muted); }
.card h3 { font-family: var(--font-display); font-weight: 500; font-size: 1.35rem; line-height: 1.2; margin-bottom: .6rem; }
.card__desc { font-size: var(--text-sm); color: var(--ink-2); flex: 1; }
.card__meta { display: flex; gap: 1rem; font-size: var(--text-xs); color: var(--muted); margin: 1.25rem 0; padding-top: 1rem; border-top: 1px dashed var(--line); }
.card__foot { display: flex; align-items: center; justify-content: space-between; gap: .75rem; }
.price { font-family: var(--font-display); font-size: 1.6rem; font-weight: 500; }
.price small { font-family: var(--font-body); font-size: var(--text-xs); color: var(--muted); margin-left: .2rem; }
.card__actions { display: flex; gap: .5rem; }
.card__actions .btn { min-height: 42px; padding: .5rem 1rem; }
.empty { padding: 2rem 0; color: var(--muted); }
.more { margin-top: 1.75rem; font-size: var(--text-sm); text-align: center; }

/* Steps */
.steps { list-style: none; padding: 0; margin: 3rem 0 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; counter-reset: s; }
.steps li { border-top: 2px solid var(--ink); padding-top: 1.25rem; }
.steps__n { display: inline-block; font-family: var(--font-display); font-size: 2.25rem; line-height: 1; margin-bottom: 1rem; background: linear-gradient(transparent 55%, var(--hl) 55%); }
.steps h3 { margin-bottom: .5rem; }
.steps p { color: var(--ink-2); font-size: var(--text-sm); max-width: 36ch; }

/* Feature */
.feature { position: relative; min-height: clamp(460px, 60vw, 640px); display: flex; align-items: center; overflow: hidden; }
.feature__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.feature__inner { position: relative; display: flex; justify-content: flex-end; padding-block: 3rem; }
.feature__card { background: var(--card); border-radius: var(--radius-lg); padding: clamp(1.5rem, 3vw, 2.5rem); max-width: 440px; box-shadow: var(--shadow); }
.feature__card h2 { margin-bottom: 1.25rem; }
.checks { list-style: none; padding: 0; margin: 0; display: grid; gap: .75rem; }
.checks li { position: relative; padding-left: 1.75rem; font-size: var(--text-sm); }
.checks li::before { content: ""; position: absolute; left: 0; top: .35em; width: 1rem; height: .55rem; border-left: 2px solid var(--ink); border-bottom: 2px solid var(--ink); transform: rotate(-45deg); }

/* Pack */
.pack { display: grid; grid-template-columns: 1.2fr .8fr; gap: clamp(2rem, 5vw, 4rem); align-items: center; }
.pack__copy h2 { margin-bottom: 1rem; }
.pack__box { background: var(--ink); color: var(--paper); border-radius: var(--radius-lg); padding: clamp(1.75rem, 3vw, 2.5rem); }
.pack__old { color: #b9ae9d; font-size: var(--text-sm); }
.pack__price { font-family: var(--font-display); font-size: clamp(3rem, 2rem + 3vw, 4.25rem); line-height: 1; margin: .25rem 0 .5rem; }
.pack__save { display: inline-block; background: var(--accent-2); color: #fff; font-size: var(--text-xs); font-weight: 600; padding: .2rem .6rem; border-radius: 4px; margin-bottom: 1.75rem; }
.pack__box .btn { background: var(--accent-2); color: #fff; border-color: var(--accent-2); }
.pack__box .btn:hover { background: var(--accent); border-color: var(--accent); }
.pack__note { font-size: var(--text-xs); color: #b9ae9d; margin-top: .9rem; text-align: center; }

/* FAQ */
.faq { display: grid; grid-template-columns: .8fr 1.2fr; gap: clamp(2rem, 5vw, 4rem); }
.faq h2 { margin-bottom: 1rem; }
.faq__list details { border-bottom: 1px solid var(--line); }
.faq__list details:first-child { border-top: 1px solid var(--line); }
.faq__list summary { list-style: none; cursor: pointer; padding: 1.15rem 2rem 1.15rem 0; font-weight: 600; position: relative; }
.faq__list summary::-webkit-details-marker { display: none; }
.faq__list summary::after { content: "+"; position: absolute; right: .25rem; top: 50%; transform: translateY(-50%); font-size: 1.4rem; font-weight: 400; transition: transform .2s; }
.faq__list details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq__list details p { padding: 0 2rem 1.25rem 0; color: var(--ink-2); font-size: var(--text-sm); }

/* Footer */
.foot { padding-block: 2.5rem; border-top: 1px solid var(--line); }
.foot__brand { display: grid; gap: .5rem; }
.foot__tag { font-size: var(--text-xs); letter-spacing: .02em; }
.foot__inner { display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; font-size: var(--text-sm); }

/* Modal */
.modal {
  width: min(100% - 2rem, 460px); padding: clamp(1.5rem, 4vw, 2.25rem); border: 0; border-radius: var(--radius-lg);
  background: var(--card); color: var(--ink); box-shadow: 0 30px 80px -20px rgba(0,0,0,.45);
}
.modal::backdrop { background: rgba(30, 27, 22, .55); backdrop-filter: blur(3px); }
.modal[open] { animation: pop .25s var(--ease); }
@keyframes pop { from { opacity: 0; transform: translateY(12px) scale(.98); } }
.modal__close-form { position: absolute; top: .75rem; right: .75rem; margin: 0; }
.modal__x { width: 40px; height: 40px; border: 0; background: transparent; font-size: 1.6rem; line-height: 1; cursor: pointer; border-radius: 50%; }
.modal__x:hover { background: var(--paper-2); }
.modal h2 { font-size: 1.75rem; margin-bottom: 1.25rem; padding-right: 2rem; }
.co-sum { display: flex; justify-content: space-between; gap: 1rem; align-items: start; padding: 1rem; background: var(--paper); border-radius: var(--radius); margin-bottom: 1.25rem; }
.co-sum__title { font-weight: 600; line-height: 1.3; }
.co-sum__meta { font-size: var(--text-xs); color: var(--muted); margin-top: .2rem; }
.co-sum__price { font-family: var(--font-display); font-size: 1.5rem; white-space: nowrap; }
.field { display: grid; gap: .4rem; margin-bottom: 1rem; font-size: var(--text-sm); font-weight: 500; }
.field input, .field select { height: 48px; padding: 0 1rem; font: inherit; font-weight: 400; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; color: var(--ink); }
.field select { appearance: auto; }
.field__hint { color: var(--muted); font-weight: 400; font-size: var(--text-xs); }
#co-err2 { display: block; color: var(--err); font-size: var(--text-sm); margin: -.25rem 0 1rem; }
#co-err2[hidden] { display: none; }
.gate h2 { padding-right: 0; }
.gate .muted { margin-bottom: 1.5rem; }
.gate .btn + .btn { margin-top: .6rem; }
.foot__legal { flex: 1 1 320px; font-size: var(--text-xs); max-width: 52ch; }
.field input:focus, .field select:focus { outline: none; border-color: var(--ink); }
.field input[aria-invalid], .field select[aria-invalid] { border-color: var(--err); }
.field__err { color: var(--err); font-weight: 400; }
.demo-note { font-size: var(--text-xs); line-height: 1.5; background: var(--hl-soft); padding: .75rem .9rem; border-radius: var(--radius); margin-bottom: 1rem; }
.demo-note code { font-size: .95em; }
.co-secure { display: flex; align-items: center; justify-content: center; gap: .4rem; font-size: var(--text-xs); color: var(--muted); margin-top: .9rem; }
.co-secure svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 2; }
.co-step[data-step="done"] .muted { margin-bottom: 1.5rem; }
.co-step[data-step="done"] .btn + .btn { margin-top: .6rem; }
.co-step[data-step="loading"] { padding: 3rem 0; text-align: center; }
.co-center { color: var(--muted); }
.spinner { width: 40px; height: 40px; margin: 0 auto 1rem; border: 3px solid var(--line); border-top-color: var(--ink); border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.toast {
  position: fixed; left: 50%; bottom: 1.5rem; transform: translate(-50%, 20px); opacity: 0; pointer-events: none;
  background: var(--ink); color: var(--paper); padding: .75rem 1.1rem; border-radius: 999px; font-size: var(--text-sm);
  transition: opacity .25s, transform .25s var(--ease); z-index: 60; max-width: calc(100% - 2rem); text-align: center;
}
.toast.is-on { opacity: 1; transform: translate(-50%, 0); }

/* Reveal */
.reveal { opacity: 0; transform: translateY(14px); transition: opacity .6s var(--ease), transform .6s var(--ease); }
.reveal.is-in { opacity: 1; transform: none; }

/* Responsive */
@media (max-width: 960px) {
  .grid { grid-template-columns: repeat(2, 1fr); }
  .nav { display: none; }
}
@media (max-width: 760px) {
  .hero__grid, .pack, .faq { grid-template-columns: 1fr; }
  .hero__media { order: -1; max-width: 520px; }
  .hero__media img { aspect-ratio: 4 / 3; }
  .steps { grid-template-columns: 1fr; gap: 1.75rem; }
  .feature { display: block; min-height: 0; }
  .feature__img { position: relative; height: 300px; }
  .feature__inner { justify-content: center; padding-block: 0 3rem; margin-top: -4rem; }
}
@media (max-width: 600px) {
  .grid { grid-template-columns: 1fr; }
  .facts { grid-template-columns: 1fr; }
  .facts li, .facts li + li { padding: .85rem 0; border-left: 0; border-bottom: 1px solid var(--line); flex-direction: row; align-items: baseline; gap: .6rem; }
  .search { width: 100%; }
  .chips { flex-wrap: nowrap; overflow-x: auto; margin-inline: -1.25rem; padding-inline: 1.25rem; padding-bottom: .25rem; scrollbar-width: none; }
  .chips::-webkit-scrollbar { display: none; }
  .chip { flex: 0 0 auto; }
  .hero__media::before { inset: auto -8px -8px auto; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; }
}

/* ---------- Catálogo a escala ---------- */
.badge { display: inline-flex; align-items: center; gap: .5rem; font-size: var(--text-xs); font-weight: 600; letter-spacing: .04em; padding: .35rem .8rem; border: 1px solid var(--line); border-radius: 999px; background: var(--card); margin-bottom: 1.25rem; }
.badge__dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent-2); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent-2) 22%, transparent); }
.section--tight { padding-block: clamp(3rem, 6vw, 5rem); }
.section__aside { max-width: 38ch; font-size: var(--text-sm); }

.careers { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.career { text-align: left; display: grid; gap: .35rem; padding: 1.4rem 1.5rem; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-lg); cursor: pointer; transition: transform .2s var(--ease), box-shadow .2s, border-color .2s; }
.career:hover { transform: translateY(-2px); box-shadow: var(--shadow); border-color: var(--ink); }
.career__n { font-family: var(--font-display); font-size: var(--text-sm); color: var(--muted); }
.career__name { font-family: var(--font-display); font-size: 1.5rem; line-height: 1.15; }
.career__sum { font-size: var(--text-sm); color: var(--ink-2); }
.career__meta { font-size: var(--text-xs); color: var(--muted); margin-top: .4rem; padding-top: .6rem; border-top: 1px dashed var(--line); }

.cat { display: grid; grid-template-columns: 250px 1fr; gap: 2rem; align-items: start; }
.cat__side { position: sticky; top: 88px; }
.cat__toggle { display: none; }
.fgroup + .fgroup { margin-top: 1.5rem; }
.fgroup[hidden] { display: none; }
.fgroup__title { font-size: var(--text-xs); font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: .5rem; }
.flist { display: grid; gap: 2px; max-height: 340px; overflow-y: auto; }
.fopt { display: flex; justify-content: space-between; align-items: center; gap: .5rem; width: 100%; min-height: 38px; padding: .4rem .7rem; border: 0; border-radius: 8px; background: transparent; text-align: left; font-size: var(--text-sm); cursor: pointer; }
.fopt:hover { background: var(--card); }
.fopt[aria-pressed="true"] { background: var(--ink); color: var(--paper); }
.fopt__n { font-size: var(--text-xs); opacity: .65; }

.cat__bar { display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.25rem; }
.cat__bar-right { display: flex; align-items: center; gap: .75rem; flex-wrap: wrap; }
.crumbs { display: flex; gap: .4rem; flex-wrap: wrap; }
.crumb { border: 1px solid var(--ink); background: var(--card); border-radius: 999px; padding: .25rem .7rem; font-size: var(--text-xs); cursor: pointer; }
.crumb:hover { background: var(--ink); color: var(--paper); }
.sort select { height: 40px; padding: 0 .8rem; border: 1px solid var(--line); border-radius: 999px; background: var(--card); font: inherit; font-size: var(--text-sm); color: var(--ink); }
.cat__main .grid { grid-template-columns: repeat(2, 1fr); }
.card__esp { font-size: var(--text-xs); color: var(--muted); margin-bottom: .2rem; }
.tag--new { background: var(--ok); color: #fff; }
.upd { color: var(--ok); font-weight: 500; }
.upd::before { content: "● "; font-size: .7em; vertical-align: 1px; }
.loadmore { display: flex; justify-content: center; margin-top: 2rem; }
.loadmore .btn[hidden] { display: none; }
.empty[hidden] { display: none; }

@media (min-width: 1200px) { .cat__main .grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 960px) { .careers { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 860px) {
  .cat { grid-template-columns: 1fr; gap: 1rem; }
  .cat__side { position: static; }
  .cat__toggle { display: inline-flex; }
  .cat__panel { display: none; margin-top: 1rem; padding: 1.25rem; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-lg); }
  .cat__panel.is-open { display: block; }
  .flist { max-height: 260px; }
}
@media (max-width: 600px) {
  .careers { grid-template-columns: 1fr 1fr; gap: .6rem; }
  .career { padding: 1rem; }
  .career__name { font-size: 1.15rem; }
  .career__sum { display: none; }
  .cat__main .grid { grid-template-columns: 1fr; }
  .cat__bar { align-items: stretch; }
  .sort, .sort select { width: 100%; }
}

section[id] { scroll-margin-top: 72px; }
.cat__done { display: none; }
@media (max-width: 860px) {
  #f-carrera, #f-tipo { max-height: none; }
  .cat__done { display: flex; margin-top: 1.25rem; }
}

/* ---------- Visor de vista previa ---------- */
.viewer { width: min(100% - 2rem, 920px); height: min(100% - 2rem, 92vh); max-height: none; padding: 0; border: 0; border-radius: var(--radius-lg); background: #e9e2d4; color: var(--ink); box-shadow: 0 30px 80px -20px rgba(0,0,0,.5); overflow: hidden; }
.viewer[open] { display: flex; flex-direction: column; animation: pop .25s var(--ease); }
.viewer::backdrop { background: rgba(30,27,22,.6); backdrop-filter: blur(3px); }
.viewer__head { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: .9rem 1rem .9rem 1.5rem; background: var(--card); border-bottom: 1px solid var(--line); }
.viewer__info { min-width: 0; }
.viewer__eyebrow { font-size: var(--text-xs); color: var(--muted); }
.viewer h2 { font-size: 1.25rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.viewer__actions { display: flex; align-items: center; gap: .75rem; flex-shrink: 0; }
.viewer__actions form { margin: 0; }
.viewer__price { font-family: var(--font-display); font-size: 1.4rem; }
.viewer__body { flex: 1; overflow-y: auto; padding: 1.5rem; -webkit-user-select: none; user-select: none; }
.viewer__pages { display: grid; gap: 1.25rem; justify-items: center; max-width: 820px; margin: 0 auto; }
.vpage { position: relative; width: 100%; background: #fff; box-shadow: 0 2px 10px rgba(0,0,0,.12); border-radius: 4px; overflow: hidden; }
.vpage canvas { display: block; width: 100%; height: auto; pointer-events: none; }
.vpage::after { content: "VISTA PREVIA"; position: absolute; inset: 0; display: grid; place-items: center; font-family: var(--font-body); font-weight: 600; font-size: clamp(1.5rem, 6vw, 3.5rem); letter-spacing: .2em; color: rgba(30,27,22,.07); transform: rotate(-30deg); pointer-events: none; }
.viewer__status { text-align: center; padding: 3rem 1rem; color: var(--muted); }
.viewer__status[hidden], .viewer__end[hidden] { display: none; }
.viewer__end { max-width: 520px; margin: 2rem auto .5rem; text-align: center; background: var(--card); border-radius: var(--radius-lg); padding: 1.75rem; }
.viewer__end p:not(.eyebrow) { margin-bottom: 1.25rem; color: var(--ink-2); }
@media (max-width: 600px) {
  .viewer { width: 100%; height: 100%; border-radius: 0; }
  .viewer__head { flex-wrap: wrap; padding: .75rem 1rem; }
  .viewer__info { flex: 1 1 calc(100% - 50px); order: 1; }
  .viewer__actions { order: 2; width: 100%; justify-content: space-between; }
  .viewer__actions form { position: absolute; top: .5rem; right: .5rem; }
  .viewer__head { position: relative; padding-right: 3rem; }
  .viewer__body { padding: 1rem; }
}
@media print { .viewer { display: none !important; } }
.card__actions .btn { white-space: nowrap; padding: .5rem .85rem; }
.card__foot { flex-wrap: wrap; row-gap: .75rem; }
@media (max-width: 600px) { .viewer { max-width: 100%; max-height: 100%; margin: 0; } }
.card__meta { flex-wrap: wrap; gap: .25rem 1rem; } .card__meta span { white-space: nowrap; }
