@import url("./design-tokens.css");

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-ui);
  font-size: var(--fs-base);
  line-height: var(--lh-body);
  color: var(--ink);
  background: var(--paper);
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }

img { max-width: 100%; display: block; }

h1, h2, h3, .display {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: var(--lh-tight);
  color: var(--ink);
  letter-spacing: -0.01em;
}

h1 { font-size: var(--fs-2xl); margin: 0 0 var(--sp-4); }
h2 { font-size: var(--fs-xl); margin: 0 0 var(--sp-3); }
h3 { font-size: var(--fs-lg); margin: 0 0 var(--sp-2); }

p { margin: 0 0 var(--sp-4); color: var(--ink-soft); }
p:last-child { margin-bottom: 0; }

.muted { color: var(--ink-muted); }
.faint { color: var(--ink-faint); }
.small { font-size: var(--fs-sm); }
.xs { font-size: var(--fs-xs); }

/* ——— Top nav ——— */
.topnav {
  position: sticky;
  top: 0;
  z-index: 40;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--sp-6);
  background: rgba(247, 244, 239, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}

.brand {
  display: flex;
  align-items: baseline;
  gap: var(--sp-3);
  color: var(--ink);
  text-decoration: none;
}
.brand:hover { text-decoration: none; }
.brand-mark {
  font-family: var(--font-display);
  font-size: var(--fs-md);
  font-weight: 600;
  letter-spacing: -0.02em;
}
.brand-sub {
  font-size: var(--fs-xs);
  color: var(--ink-faint);
  font-family: var(--font-ui);
  letter-spacing: 0.02em;
}

.topnav-links {
  display: flex;
  align-items: center;
  gap: var(--sp-1);
}
.topnav-links a {
  padding: var(--sp-2) var(--sp-3);
  border-radius: var(--r-sm);
  color: var(--ink-muted);
  font-size: var(--fs-sm);
  text-decoration: none;
}
.topnav-links a:hover { color: var(--ink); background: var(--paper-sunken); }
.topnav-links a.is-active { color: var(--ink); background: var(--stone-soft); }

.topnav-actions { display: flex; align-items: center; gap: var(--sp-3); }

.avatar {
  width: 32px; height: 32px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent);
  display: grid; place-items: center;
  font-size: var(--fs-xs);
  font-weight: 600;
  border: 1px solid var(--accent-line);
}

/* ——— Buttons ——— */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  padding: 0.625rem 1.125rem;
  border-radius: var(--r-md);
  font-family: var(--font-ui);
  font-size: var(--fs-sm);
  font-weight: 500;
  line-height: 1.2;
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: background .15s, border-color .15s, color .15s, box-shadow .15s;
  white-space: nowrap;
}
.btn:focus-visible { outline: none; box-shadow: var(--shadow-focus); }
.btn:hover { text-decoration: none; }

.btn-primary {
  background: var(--accent);
  color: #f7f4ef;
  border-color: var(--accent);
}
.btn-primary:hover { background: var(--accent-hover); color: #f7f4ef; }

.btn-secondary {
  background: var(--paper-raised);
  color: var(--ink);
  border-color: var(--line-strong);
}
.btn-secondary:hover { background: var(--paper-sunken); border-color: var(--ink-faint); }

.btn-ghost {
  background: transparent;
  color: var(--ink-muted);
  border-color: transparent;
}
.btn-ghost:hover { color: var(--ink); background: var(--paper-sunken); }

.btn-danger {
  background: var(--danger-soft);
  color: var(--danger);
  border-color: transparent;
}
.btn-danger:hover { background: #ecd5d5; }

.btn-lg { padding: 0.85rem 1.5rem; font-size: var(--fs-base); }
.btn-sm { padding: 0.4rem 0.75rem; font-size: var(--fs-xs); }
.btn-block { width: 100%; }

.btn-google {
  background: var(--paper-raised);
  color: var(--ink);
  border-color: var(--line-strong);
  gap: var(--sp-3);
}
.btn-google:hover { border-color: var(--ink-faint); background: #fff; }
.btn-google .g-icon {
  width: 18px; height: 18px;
  background: conic-gradient(from -45deg, #ea4335 0 25%, #fbbc05 25% 50%, #34a853 50% 75%, #4285f4 75%);
  border-radius: 2px;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M22.56 12.25c0-.78-.07-1.53-.2-2.25H12v4.26h5.92c-.26 1.37-1.04 2.53-2.21 3.31v2.77h3.57c2.08-1.92 3.28-4.74 3.28-8.09z'/%3E%3C/svg%3E") center/contain no-repeat;
  -webkit-mask: none;
  display: inline-block;
  position: relative;
}
.g-mark {
  width: 18px; height: 18px;
  display: inline-grid; place-items: center;
  font-weight: 700; font-size: 13px; color: #4285f4;
  font-family: Arial, sans-serif;
}

/* ——— Layout shells ——— */
.shell {
  max-width: var(--max-content);
  margin: 0 auto;
  padding: var(--sp-8) var(--sp-6) var(--sp-16);
}
.shell-narrow { max-width: var(--max-narrow); }
.shell-wide { max-width: 1280px; }

.page-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--sp-6);
  margin-bottom: var(--sp-8);
  flex-wrap: wrap;
}
.page-head .eyebrow {
  font-size: var(--fs-xs);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-bottom: var(--sp-2);
  font-family: var(--font-ui);
  font-weight: 500;
}

/* ——— Cards ——— */
.card {
  background: var(--paper-raised);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-soft);
  padding: var(--sp-6);
}
.card-flush { padding: 0; overflow: hidden; }

/* ——— Forms ——— */
label.field-label {
  display: block;
  font-size: var(--fs-sm);
  font-weight: 500;
  color: var(--ink-soft);
  margin-bottom: var(--sp-2);
}
.field-hint { font-size: var(--fs-xs); color: var(--ink-faint); margin-top: var(--sp-2); }

input[type="text"],
input[type="password"],
input[type="url"],
input[type="number"],
textarea,
select {
  width: 100%;
  padding: 0.65rem 0.85rem;
  font-family: var(--font-ui);
  font-size: var(--fs-base);
  color: var(--ink);
  background: var(--paper-raised);
  border: 1px solid var(--line-strong);
  border-radius: var(--r-md);
  transition: border-color .15s, box-shadow .15s;
}
input:focus, textarea:focus, select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: var(--shadow-focus);
}
textarea { min-height: 140px; resize: vertical; line-height: var(--lh-body); }
input::placeholder, textarea::placeholder { color: var(--ink-faint); }

.field { margin-bottom: var(--sp-5); }

/* ——— Wizard chrome ——— */
.wizard-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-4);
  padding: var(--sp-4) var(--sp-6);
  border-bottom: 1px solid var(--line);
  background: var(--paper-raised);
  position: sticky;
  top: var(--nav-h);
  z-index: 30;
}
.wizard-steps {
  display: flex;
  align-items: center;
  gap: 0;
  list-style: none;
  margin: 0;
  padding: 0;
}
.wizard-steps li {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  font-size: var(--fs-sm);
  color: var(--ink-faint);
  padding: 0 var(--sp-2);
}
.wizard-steps li + li::before {
  content: "";
  width: 24px;
  height: 1px;
  background: var(--line-strong);
  margin-right: var(--sp-2);
}
.wizard-steps .step-num {
  width: 22px; height: 22px;
  border-radius: 50%;
  display: grid; place-items: center;
  font-size: var(--fs-xs);
  font-weight: 600;
  border: 1px solid var(--line-strong);
  color: var(--ink-faint);
  background: var(--paper);
}
.wizard-steps li.is-done { color: var(--ok); }
.wizard-steps li.is-done .step-num {
  background: var(--ok-soft);
  border-color: var(--ok);
  color: var(--ok);
}
.wizard-steps li.is-current { color: var(--ink); font-weight: 500; }
.wizard-steps li.is-current .step-num {
  background: var(--accent);
  border-color: var(--accent);
  color: #f7f4ef;
}
.wizard-steps .step-skin {
  font-size: var(--fs-xs);
  color: var(--ink-faint);
  font-weight: 400;
  margin-left: 2px;
}

.wizard-actions { display: flex; gap: var(--sp-3); }

/* ——— Tags / chips ——— */
.chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  font-size: var(--fs-xs);
  background: var(--paper-sunken);
  color: var(--ink-muted);
  border: 1px solid var(--line);
}
.chip-accent { background: var(--accent-soft); color: var(--accent); border-color: var(--accent-line); }
.chip-ok { background: var(--ok-soft); color: var(--ok); border-color: transparent; }
.chip-warn { background: var(--warn-soft); color: var(--warn); border-color: transparent; }

.tag-select {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2);
}
.tag-select label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0.4rem 0.75rem;
  border-radius: var(--r-md);
  border: 1px solid var(--line);
  background: var(--paper-raised);
  font-size: var(--fs-sm);
  color: var(--ink-soft);
  cursor: pointer;
  user-select: none;
}
.tag-select input { width: auto; accent-color: var(--accent); }
.tag-select label:has(input:checked) {
  border-color: var(--accent);
  background: var(--accent-soft);
  color: var(--accent);
}

/* ——— Scene cards ——— */
.scene-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: var(--sp-3);
}
.scene-card {
  position: relative;
  padding: var(--sp-5);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  background: var(--paper-raised);
  cursor: pointer;
  transition: border-color .15s, box-shadow .15s;
}
.scene-card:hover { border-color: var(--line-strong); box-shadow: var(--shadow-soft); }
.scene-card.is-selected {
  border-color: var(--accent);
  box-shadow: var(--shadow-focus);
  background: var(--accent-soft);
}
.scene-card input { position: absolute; opacity: 0; pointer-events: none; }
.scene-card .sc-name { font-weight: 600; color: var(--ink); margin-bottom: 4px; }
.scene-card .sc-skel { font-size: var(--fs-xs); color: var(--ink-muted); line-height: 1.45; }

/* ——— Structure editor ——— */
.struct-list { display: flex; flex-direction: column; gap: var(--sp-3); }
.struct-item {
  display: grid;
  grid-template-columns: 36px 1fr auto;
  gap: var(--sp-3);
  align-items: start;
  padding: var(--sp-4);
  background: var(--paper-raised);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
}
.struct-item .ord {
  width: 28px; height: 28px;
  border-radius: 50%;
  background: var(--paper-sunken);
  display: grid; place-items: center;
  font-size: var(--fs-xs);
  font-weight: 600;
  color: var(--ink-muted);
  margin-top: 4px;
}
.struct-item .sec-title {
  font-weight: 600;
  border: none;
  background: transparent;
  padding: 4px 0;
  font-size: var(--fs-md);
  width: 100%;
}
.struct-item .sec-title:focus { outline: none; box-shadow: none; border-bottom: 1px solid var(--accent); border-radius: 0; }
.struct-item .bullets {
  margin: var(--sp-2) 0 0;
  padding: 0;
  list-style: none;
}
.struct-item .bullets li {
  display: flex;
  gap: var(--sp-2);
  align-items: flex-start;
  margin-bottom: var(--sp-2);
}
.struct-item .bullets li::before {
  content: "·";
  color: var(--ink-faint);
  font-weight: 700;
  margin-top: 2px;
}
.struct-item .bullets input {
  border: none;
  background: transparent;
  padding: 2px 0;
  font-size: var(--fs-sm);
  color: var(--ink-soft);
}
.struct-item .bullets input:focus { outline: none; box-shadow: none; border-bottom: 1px dashed var(--accent); border-radius: 0; }
.struct-item .drag { color: var(--ink-faint); cursor: grab; padding: 6px; }

/* ——— Template skin cards ——— */
.tpl-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--sp-4);
}
@media (max-width: 900px) {
  .tpl-grid { grid-template-columns: 1fr; }
}
.tpl-card {
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  background: var(--paper-raised);
  overflow: hidden;
  cursor: pointer;
  transition: border-color .15s, box-shadow .15s;
}
.tpl-card:hover { border-color: var(--line-strong); }
.tpl-card.is-selected {
  border-color: var(--accent);
  box-shadow: var(--shadow-focus);
}
.tpl-thumb {
  aspect-ratio: 16/10;
  background: linear-gradient(145deg, var(--paper-sunken), var(--stone-soft));
  border-bottom: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  padding: var(--sp-5);
  gap: var(--sp-2);
  position: relative;
}
.tpl-thumb .fake-bar {
  height: 8px; width: 40%; background: var(--ink); opacity: 0.7; border-radius: 2px;
}
.tpl-thumb .fake-line {
  height: 4px; background: var(--ink-faint); opacity: 0.35; border-radius: 2px;
}
.tpl-thumb .fake-line.w60 { width: 60%; }
.tpl-thumb .fake-line.w80 { width: 80%; }
.tpl-thumb .fake-line.w45 { width: 45%; }
.tpl-thumb .skin-badge {
  position: absolute;
  top: var(--sp-3); right: var(--sp-3);
  font-size: 10px;
  letter-spacing: 0.04em;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(247,244,239,0.92);
  color: var(--ink-muted);
  border: 1px solid var(--line);
}
.tpl-body { padding: var(--sp-4); }
.tpl-body .name { font-weight: 600; margin-bottom: 4px; }
.tpl-body .meta { font-size: var(--fs-xs); color: var(--ink-muted); display: flex; flex-wrap: wrap; gap: 6px; margin-top: var(--sp-2); }

.tpl-card.tone-formal .tpl-thumb { background: linear-gradient(160deg, #e8eef4, #d4dde8); }
.tpl-card.tone-formal .fake-bar { background: var(--accent); opacity: 0.85; }
.tpl-card.tone-crisp .tpl-thumb { background: linear-gradient(160deg, #f0ebe3, #e2d8ca); }
.tpl-card.tone-data .tpl-thumb { background: linear-gradient(160deg, #e9efe9, #d5e0d6); }

/* ——— Notes hero layout ——— */
.notes-layout {
  display: grid;
  grid-template-columns: minmax(280px, 1fr) minmax(320px, 1.1fr);
  gap: var(--sp-6);
  min-height: calc(100vh - var(--nav-h) - 120px);
}
@media (max-width: 900px) {
  .notes-layout { grid-template-columns: 1fr; }
}
.slide-preview {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-card);
  aspect-ratio: 16/10;
  padding: var(--sp-8);
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
}
.slide-preview .sp-kicker {
  font-size: var(--fs-xs);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-bottom: var(--sp-3);
}
.slide-preview .sp-title {
  font-family: var(--font-display);
  font-size: var(--fs-xl);
  margin-bottom: var(--sp-4);
}
.slide-preview ul {
  margin: 0;
  padding-left: 1.1rem;
  color: var(--ink-soft);
  font-size: var(--fs-sm);
}
.slide-preview li { margin-bottom: 6px; }
.slide-preview .sp-page {
  position: absolute;
  bottom: var(--sp-4); right: var(--sp-5);
  font-size: var(--fs-xs);
  color: var(--ink-faint);
}

.notes-panel {
  display: flex;
  flex-direction: column;
  gap: var(--sp-4);
}
.note-field {
  background: var(--paper-raised);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  padding: var(--sp-4);
}
.note-field .nf-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-muted);
  margin-bottom: var(--sp-2);
}
.note-field textarea, .note-field input {
  border: none;
  background: transparent;
  padding: 0;
  font-size: var(--fs-sm);
  min-height: auto;
  box-shadow: none;
}
.note-field textarea:focus, .note-field input:focus {
  outline: none; box-shadow: none; border: none;
}
.note-field.core { border-left: 3px solid var(--accent); }
.note-field.onslide { border-left: 3px solid var(--stone); }
.note-field.extend { border-left: 3px solid var(--warn); }
.note-field.logic { border-left: 3px solid var(--ok); }

.page-switcher {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  flex-wrap: wrap;
  margin-bottom: var(--sp-4);
}
.page-switcher button {
  width: 36px; height: 36px;
  border-radius: var(--r-md);
  border: 1px solid var(--line);
  background: var(--paper-raised);
  color: var(--ink-muted);
  font-size: var(--fs-sm);
  cursor: pointer;
}
.page-switcher button.is-active {
  background: var(--accent);
  border-color: var(--accent);
  color: #f7f4ef;
}
.page-switcher button:hover:not(.is-active) { border-color: var(--line-strong); }

/* ——— Briefing list ——— */
.briefing-table { width: 100%; border-collapse: collapse; }
.briefing-table th {
  text-align: left;
  font-size: var(--fs-xs);
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-faint);
  padding: var(--sp-3) var(--sp-4);
  border-bottom: 1px solid var(--line);
}
.briefing-table td {
  padding: var(--sp-4);
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
}
.briefing-table tr:hover td { background: rgba(255,252,247,0.6); }
.briefing-table .title { font-weight: 550; color: var(--ink); }
.briefing-table .title a { color: inherit; text-decoration: none; }
.briefing-table .title a:hover { color: var(--accent); }

.empty-state {
  text-align: center;
  padding: var(--sp-16) var(--sp-6);
  color: var(--ink-muted);
}
.empty-state h3 { font-family: var(--font-display); color: var(--ink); margin-bottom: var(--sp-2); }

/* ——— Admin ——— */
.admin-shell {
  display: grid;
  grid-template-columns: var(--side-w) 1fr;
  min-height: calc(100vh - var(--nav-h));
}
@media (max-width: 800px) {
  .admin-shell { grid-template-columns: 1fr; }
}
.admin-side {
  border-right: 1px solid var(--line);
  background: var(--paper-raised);
  padding: var(--sp-6) var(--sp-4);
}
.admin-side a {
  display: block;
  padding: var(--sp-3) var(--sp-4);
  border-radius: var(--r-md);
  color: var(--ink-muted);
  font-size: var(--fs-sm);
  text-decoration: none;
  margin-bottom: 2px;
}
.admin-side a:hover { background: var(--paper-sunken); color: var(--ink); text-decoration: none; }
.admin-side a.is-active { background: var(--accent-soft); color: var(--accent); font-weight: 500; }
.admin-main { padding: var(--sp-8) var(--sp-6); }

.upload-zone {
  border: 1.5px dashed var(--line-strong);
  border-radius: var(--r-lg);
  padding: var(--sp-10) var(--sp-6);
  text-align: center;
  background: var(--paper-sunken);
  color: var(--ink-muted);
  cursor: pointer;
  transition: border-color .15s, background .15s;
}
.upload-zone:hover { border-color: var(--accent); background: var(--accent-soft); color: var(--accent); }
.upload-zone strong { display: block; color: var(--ink); margin-bottom: var(--sp-2); font-weight: 550; }

.status-dot {
  display: inline-block;
  width: 8px; height: 8px;
  border-radius: 50%;
  margin-right: 6px;
}
.status-dot.on { background: var(--ok); }
.status-dot.off { background: var(--ink-faint); }

/* ——— Landing ——— */
.hero {
  padding: var(--sp-20) var(--sp-6) var(--sp-16);
  max-width: var(--max-content);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: var(--sp-12);
  align-items: center;
}
@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; padding-top: var(--sp-12); gap: var(--sp-8); }
}
.hero-eyebrow {
  font-size: var(--fs-xs);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-bottom: var(--sp-4);
  font-weight: 500;
}
.hero h1 {
  font-size: var(--fs-hero);
  margin-bottom: var(--sp-5);
  max-width: 14em;
}
.hero-lead {
  font-size: var(--fs-md);
  color: var(--ink-soft);
  max-width: 32em;
  margin-bottom: var(--sp-8);
}
.hero-ctas { display: flex; flex-wrap: wrap; gap: var(--sp-3); align-items: center; }
.hero-note { font-size: var(--fs-xs); color: var(--ink-faint); margin-top: var(--sp-4); }

.hero-panel {
  background: var(--paper-raised);
  border: 1px solid var(--line);
  border-radius: var(--r-xl);
  box-shadow: var(--shadow-card);
  padding: var(--sp-6);
}
.hero-panel .hp-label {
  font-size: var(--fs-xs);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-bottom: var(--sp-4);
}
.hp-flow {
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
}
.hp-step {
  display: grid;
  grid-template-columns: 28px 1fr;
  gap: var(--sp-3);
  padding: var(--sp-3);
  border-radius: var(--r-md);
  background: var(--paper);
  border: 1px solid transparent;
}
.hp-step.is-hero-path {
  background: var(--accent-soft);
  border-color: var(--accent-line);
}
.hp-step .n {
  width: 28px; height: 28px;
  border-radius: 50%;
  background: var(--paper-sunken);
  display: grid; place-items: center;
  font-size: var(--fs-xs);
  font-weight: 600;
  color: var(--ink-muted);
}
.hp-step.is-hero-path .n { background: var(--accent); color: #f7f4ef; }
.hp-step .t { font-weight: 550; font-size: var(--fs-sm); color: var(--ink); }
.hp-step .d { font-size: var(--fs-xs); color: var(--ink-muted); margin-top: 2px; }
.hp-step .skin-tag {
  display: inline-block;
  margin-left: 6px;
  font-size: 10px;
  padding: 1px 6px;
  border-radius: 999px;
  background: var(--paper-sunken);
  color: var(--ink-faint);
  font-weight: 400;
}

.section {
  max-width: var(--max-content);
  margin: 0 auto;
  padding: var(--sp-12) var(--sp-6);
}
.section-title {
  font-family: var(--font-display);
  font-size: var(--fs-xl);
  margin-bottom: var(--sp-2);
}
.compare {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--sp-4);
  margin-top: var(--sp-6);
}
@media (max-width: 700px) { .compare { grid-template-columns: 1fr; } }
.compare .col {
  padding: var(--sp-6);
  border-radius: var(--r-lg);
  border: 1px solid var(--line);
  background: var(--paper-raised);
}
.compare .col.bad { opacity: 0.85; }
.compare .col.good {
  border-color: var(--accent-line);
  background: linear-gradient(180deg, var(--accent-soft), var(--paper-raised));
}
.compare .col h3 { font-size: var(--fs-md); margin-bottom: var(--sp-3); }
.compare ul { margin: 0; padding-left: 1.1rem; color: var(--ink-soft); font-size: var(--fs-sm); }
.compare li { margin-bottom: 6px; }

.footer {
  border-top: 1px solid var(--line);
  padding: var(--sp-8) var(--sp-6);
  text-align: center;
  font-size: var(--fs-xs);
  color: var(--ink-faint);
}

/* ——— Preview / export ——— */
.preview-deck { display: flex; flex-direction: column; gap: var(--sp-6); }
.preview-slide {
  display: grid;
  grid-template-columns: minmax(220px, 340px) 1fr;
  gap: var(--sp-5);
  padding: var(--sp-5);
  background: var(--paper-raised);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
}
@media (max-width: 700px) {
  .preview-slide { grid-template-columns: 1fr; }
}
.preview-slide .mini {
  aspect-ratio: 16/10;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  padding: var(--sp-4);
  font-size: var(--fs-xs);
}
.preview-slide .mini .t {
  font-family: var(--font-display);
  font-size: var(--fs-sm);
  margin: 6px 0 8px;
}
.preview-notes dl { margin: 0; }
.preview-notes dt {
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-top: var(--sp-3);
}
.preview-notes dt:first-child { margin-top: 0; }
.preview-notes dd {
  margin: 4px 0 0;
  font-size: var(--fs-sm);
  color: var(--ink-soft);
}

.divider {
  height: 1px;
  background: var(--line);
  margin: var(--sp-8) 0;
  border: none;
}

.badge-skin {
  font-size: 10px;
  letter-spacing: 0.06em;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--paper-sunken);
  color: var(--ink-faint);
  border: 1px solid var(--line);
  vertical-align: middle;
}
