/* === LUMA — Skin Diagnostic & Consult Platform === */
/* Clinical Premium aesthetic — Apple Health풍 화이트/소프트 뉴트럴 */

:root {
  /* Surfaces */
  --bg-canvas:   #F4F4F6;
  --bg-page:     #FAFAFA;
  --bg-surface:  #FFFFFF;
  --bg-subtle:   #F2F2F4;
  --bg-elevated: #FFFFFF;
  --bg-inverse:  #111113;

  /* Borders */
  --line-hair:   rgba(60, 60, 67, 0.10);
  --line-soft:   rgba(60, 60, 67, 0.14);
  --line-medium: rgba(60, 60, 67, 0.22);

  /* Text */
  --ink-1: #0F0F11;
  --ink-2: #1D1D1F;
  --ink-3: #6E6E73;
  --ink-4: #9A9AA0;
  --ink-5: #C0C0C6;
  --ink-on-dark: #F5F5F7;

  /* Brand — skin clinic palette */
  --skin-coral:    #E07A6C;
  --skin-coral-2:  #F4C2B9;
  --skin-coral-10: rgba(224, 122, 108, 0.10);

  /* Data accents (Apple Health-ish) */
  --data-blue:     #2F6FE0;
  --data-blue-10:  rgba(47, 111, 224, 0.10);
  --data-teal:     #18A3A8;
  --data-violet:   #6A56D6;
  --data-amber:    #D98B2A;
  --data-pink:     #D85F92;
  --data-lime:     #6FA82B;

  /* Semantic */
  --good:    #1F9D6E;
  --good-10: rgba(31, 157, 110, 0.10);
  --watch:   #C8862C;
  --watch-10:rgba(200, 134, 44, 0.10);
  --alert:   #C7493E;
  --alert-10:rgba(199, 73, 62, 0.10);

  /* Phase-tinted accents (toggled by tweaks) */
  --phase-tint: var(--data-blue);

  /* Radius & spacing */
  --r-xs: 6px;
  --r-sm: 10px;
  --r-md: 14px;
  --r-lg: 20px;
  --r-xl: 28px;
  --r-pill: 999px;

  /* Shadows — restrained */
  --shadow-card: 0 1px 0 rgba(0,0,0,0.02), 0 1px 2px rgba(0,0,0,0.04);
  --shadow-pop:  0 8px 24px rgba(15, 15, 17, 0.08), 0 1px 2px rgba(0,0,0,0.04);
  --shadow-deep: 0 20px 60px rgba(15, 15, 17, 0.12);

  /* Type */
  --font-kr: "Pretendard Variable", Pretendard, -apple-system, system-ui, "Apple SD Gothic Neo", sans-serif;
  --font-num: "Inter", -apple-system, system-ui, sans-serif;
  --font-mono: "JetBrains Mono", "SF Mono", ui-monospace, monospace;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--font-kr);
  background: var(--bg-canvas);
  color: var(--ink-2);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-feature-settings: "ss01", "cv01", "tnum" off;
  font-size: 14px;
  line-height: 1.45;
  letter-spacing: -0.005em;
  min-width: 1440px;
}

button { font-family: inherit; cursor: pointer; border: 0; background: none; padding: 0; color: inherit; }
input, select, textarea { font-family: inherit; }

.num { font-family: var(--font-num); font-feature-settings: "tnum" on, "lnum" on; letter-spacing: -0.01em; }
.mono { font-family: var(--font-mono); letter-spacing: -0.01em; }

/* --- Root layout shell --- */
.app-shell {
  display: grid;
  grid-template-columns: 268px 1fr;
  min-height: 100vh;
  background: var(--bg-canvas);
}

.sidebar {
  background: #FBFBFC;
  border-right: 1px solid var(--line-hair);
  padding: 22px 14px 24px;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  word-break: keep-all;
}

.workspace {
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.topbar {
  height: 60px;
  padding: 0 28px;
  background: rgba(250,250,250,0.85);
  backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--line-hair);
  display: flex;
  align-items: center;
  gap: 16px;
  position: sticky;
  top: 0;
  z-index: 20;
}

.page {
  padding: 28px 32px 64px;
  max-width: 1480px;
  width: 100%;
  margin: 0 auto;
}

.page-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 22px;
  gap: 24px;
}

.page-eyebrow {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: var(--ink-4);
  text-transform: uppercase;
  margin-bottom: 6px;
}

.page-title {
  font-size: 28px;
  font-weight: 700;
  color: var(--ink-1);
  margin: 0;
  letter-spacing: -0.022em;
}

.page-sub {
  font-size: 14px;
  color: var(--ink-3);
  margin-top: 6px;
  max-width: 720px;
}

/* --- Card primitive --- */
.card {
  background: var(--bg-surface);
  border-radius: var(--r-lg);
  border: 1px solid var(--line-hair);
  box-shadow: var(--shadow-card);
}
.card-pad { padding: 22px 24px; }
.card-pad-lg { padding: 28px 30px; }
.card-pad-sm { padding: 16px 18px; }

.card-title {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--ink-3);
  text-transform: uppercase;
  margin: 0 0 14px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.card-title-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 14px;
}
.card-title .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--phase-tint); }

/* --- Sidebar nav --- */
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 10px 22px;
}
.brand-mark {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: linear-gradient(135deg, #1D1D1F 0%, #3A3A3D 100%);
  color: #FFF;
  display: grid;
  place-items: center;
  font-family: var(--font-num);
  font-weight: 700;
  font-size: 13px;
  letter-spacing: -0.02em;
}
.brand-name {
  font-weight: 700;
  font-size: 16px;
  letter-spacing: -0.02em;
  color: var(--ink-1);
}
.brand-sub {
  font-size: 11px;
  color: var(--ink-4);
  margin-top: 1px;
}

.nav-group-label {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: var(--ink-4);
  text-transform: uppercase;
  padding: 14px 12px 8px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 8px;
  color: var(--ink-2);
  font-size: 13.5px;
  font-weight: 500;
  transition: background 120ms ease;
  position: relative;
  width: 100%;
  text-align: left;
}
.nav-item:hover { background: var(--bg-subtle); }
.nav-item.active {
  background: var(--ink-2);
  color: #FFF;
}
.nav-item .nav-ico {
  width: 18px;
  height: 18px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  opacity: 0.85;
}
.nav-item.active .nav-ico { opacity: 1; }
.nav-item .nav-tail {
  margin-left: auto;
  font-size: 10px;
  color: var(--ink-4);
  font-family: var(--font-mono);
}
.nav-item.active .nav-tail { color: rgba(255,255,255,0.55); }

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 16px;
  height: 36px;
  border-radius: var(--r-pill);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: -0.005em;
  transition: transform 80ms ease, background 120ms ease, box-shadow 120ms ease;
  white-space: nowrap;
}
.btn:active { transform: translateY(0.5px); }

.btn-primary { background: var(--ink-1); color: #FFF; }
.btn-primary:hover { background: #000; }

.btn-soft { background: var(--bg-subtle); color: var(--ink-2); }
.btn-soft:hover { background: #E8E8EB; }

.btn-ghost { background: transparent; color: var(--ink-2); }
.btn-ghost:hover { background: var(--bg-subtle); }

.btn-accent { background: var(--phase-tint); color: #FFF; }

.btn-sm { height: 30px; padding: 0 12px; font-size: 12px; }
.btn-lg { height: 44px; padding: 0 22px; font-size: 14px; }

/* --- Badge / Pill --- */
.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 9px;
  border-radius: var(--r-pill);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.005em;
  background: var(--bg-subtle);
  color: var(--ink-2);
  white-space: nowrap;
}
.pill-good   { background: var(--good-10); color: var(--good); }
.pill-watch  { background: var(--watch-10); color: var(--watch); }
.pill-alert  { background: var(--alert-10); color: var(--alert); }
.pill-info   { background: var(--data-blue-10); color: var(--data-blue); }
.pill-skin   { background: var(--skin-coral-10); color: var(--skin-coral); }
.pill-outline { background: transparent; border: 1px solid var(--line-soft); color: var(--ink-3); }
.pill .dot { width: 5px; height: 5px; border-radius: 50%; background: currentColor; }

/* --- Stat block --- */
.stat-label { font-size: 11px; color: var(--ink-4); letter-spacing: 0.02em; text-transform: uppercase; font-weight: 600; }
.stat-value { font-family: var(--font-num); font-size: 28px; font-weight: 600; color: var(--ink-1); letter-spacing: -0.02em; }
.stat-delta { font-family: var(--font-num); font-size: 12px; font-weight: 600; }
.stat-delta.up { color: var(--good); }
.stat-delta.down { color: var(--alert); }
.stat-sub { font-size: 12px; color: var(--ink-3); margin-top: 4px; }

/* --- Grid utilities --- */
.grid { display: grid; gap: 16px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-12 { grid-template-columns: repeat(12, 1fr); }
.col-3  { grid-column: span 3; }
.col-4  { grid-column: span 4; }
.col-5  { grid-column: span 5; }
.col-6  { grid-column: span 6; }
.col-7  { grid-column: span 7; }
.col-8  { grid-column: span 8; }
.col-9  { grid-column: span 9; }
.col-12 { grid-column: span 12; }

.row { display: flex; align-items: center; gap: 8px; }
.row-between { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.col { display: flex; flex-direction: column; gap: 6px; }

/* --- Score bar --- */
.score-bar {
  display: flex;
  align-items: center;
  gap: 12px;
}
.score-bar .label { width: 88px; font-size: 13px; color: var(--ink-2); font-weight: 500; }
.score-bar .track {
  flex: 1;
  height: 8px;
  background: var(--bg-subtle);
  border-radius: 999px;
  position: relative;
  overflow: hidden;
}
.score-bar .fill {
  position: absolute;
  inset: 0 auto 0 0;
  height: 100%;
  background: linear-gradient(90deg, var(--phase-tint), var(--data-teal));
  border-radius: 999px;
  transition: width 600ms cubic-bezier(0.2, 0.6, 0.2, 1);
}
.score-bar .benchmark {
  position: absolute;
  top: -2px;
  bottom: -2px;
  width: 2px;
  background: var(--ink-2);
  border-radius: 2px;
  transform: translateX(-1px);
}
.score-bar .value {
  width: 36px;
  text-align: right;
  font-family: var(--font-num);
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-1);
  letter-spacing: -0.01em;
}

/* --- Form inputs --- */
.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.field-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--ink-2);
  letter-spacing: -0.005em;
}
.field-hint { font-size: 11px; color: var(--ink-4); }

.input, .select, .textarea {
  border: 1px solid var(--line-soft);
  background: var(--bg-surface);
  border-radius: 10px;
  padding: 9px 12px;
  font-size: 13.5px;
  color: var(--ink-1);
  transition: border-color 120ms ease, box-shadow 120ms ease;
  width: 100%;
}
.input:focus, .select:focus, .textarea:focus {
  outline: none;
  border-color: var(--phase-tint);
  box-shadow: 0 0 0 3px var(--data-blue-10);
}
.textarea { resize: vertical; min-height: 80px; }

/* --- Chip group (multi-select) --- */
.chip-group { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  padding: 7px 12px;
  border-radius: 999px;
  background: var(--bg-surface);
  border: 1px solid var(--line-soft);
  font-size: 12.5px;
  font-weight: 500;
  color: var(--ink-2);
  cursor: pointer;
  transition: all 120ms ease;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.chip:hover { border-color: var(--line-medium); }
.chip.selected {
  background: var(--ink-1);
  border-color: var(--ink-1);
  color: #FFF;
}

/* --- Tabs --- */
.tabs {
  display: inline-flex;
  background: var(--bg-subtle);
  padding: 3px;
  border-radius: 10px;
  gap: 2px;
}
.tab {
  padding: 5px 12px;
  border-radius: 7px;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--ink-3);
  cursor: pointer;
}
.tab.active { background: #FFF; color: var(--ink-1); box-shadow: 0 1px 2px rgba(0,0,0,0.06); }

/* --- Progress dots (for stepper) --- */
.stepper { display: flex; align-items: center; gap: 6px; }
.stepper .seg {
  height: 4px;
  flex: 1;
  background: var(--bg-subtle);
  border-radius: 2px;
  overflow: hidden;
}
.stepper .seg.done { background: var(--ink-1); }
.stepper .seg.active { background: linear-gradient(90deg, var(--ink-1) 60%, var(--bg-subtle) 60%); }

/* --- Scrollbar polish --- */
.sidebar::-webkit-scrollbar, .scroll-area::-webkit-scrollbar { width: 6px; height: 6px; }
.sidebar::-webkit-scrollbar-thumb, .scroll-area::-webkit-scrollbar-thumb { background: rgba(0,0,0,0.12); border-radius: 999px; }

/* --- iPad frame for patient-facing flow --- */
.ipad-frame {
  background: #1D1D1F;
  border-radius: 28px;
  padding: 14px;
  box-shadow: 0 30px 80px rgba(15,15,17,0.18), 0 4px 12px rgba(0,0,0,0.04);
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
}
.ipad-screen {
  background: #FFFFFF;
  border-radius: 16px;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  position: relative;
}

/* --- Skin photo placeholder --- */
.skin-photo {
  background:
    radial-gradient(ellipse at 50% 35%, #F3D8CD 0%, #E8B9A8 35%, #C68B78 75%, #8E5A4B 100%);
  position: relative;
  overflow: hidden;
}
.skin-photo::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 30% 28%, rgba(255,255,255,0.35) 0%, transparent 18%),
    radial-gradient(circle at 70% 35%, rgba(255,255,255,0.25) 0%, transparent 14%),
    radial-gradient(circle at 50% 78%, rgba(0,0,0,0.18) 0%, transparent 30%);
  mix-blend-mode: overlay;
}
.skin-photo::after {
  content: "FACE CAPTURE";
  position: absolute;
  bottom: 12px;
  left: 12px;
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.15em;
  color: rgba(255,255,255,0.65);
}

/* --- Heatmap overlay (for analysis) --- */
.heatmap {
  position: absolute;
  inset: 0;
  pointer-events: none;
  mix-blend-mode: screen;
  opacity: 0.85;
}

/* --- Topbar bits --- */
.search {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-subtle);
  border-radius: 10px;
  padding: 6px 12px;
  width: 320px;
  font-size: 13px;
  color: var(--ink-3);
}

.kbd {
  font-family: var(--font-mono);
  font-size: 10px;
  padding: 1px 6px;
  border-radius: 4px;
  background: rgba(0,0,0,0.06);
  color: var(--ink-3);
}

/* --- Role switcher --- */
.role-switcher {
  display: inline-flex;
  background: var(--bg-subtle);
  border-radius: 999px;
  padding: 3px;
  gap: 1px;
}
.role-opt {
  padding: 5px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  color: var(--ink-3);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.role-opt.active { background: var(--ink-1); color: #FFF; }
.role-opt .swatch { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }

/* --- Mini bar chart (for BI dashboards) --- */
.minibar {
  display: flex;
  align-items: flex-end;
  gap: 4px;
  height: 44px;
}
.minibar .b {
  flex: 1;
  background: var(--bg-subtle);
  border-radius: 3px;
  position: relative;
}
.minibar .b.active { background: var(--phase-tint); }

/* --- Animations --- */
@keyframes pulse-ring {
  0% { transform: scale(0.8); opacity: 0.8; }
  100% { transform: scale(2.4); opacity: 0; }
}
.pulse-dot {
  position: relative;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--good);
}
.pulse-dot::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: var(--good);
  animation: pulse-ring 1.6s ease-out infinite;
}

@keyframes fadeup {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}
.fade-up { animation: fadeup 320ms cubic-bezier(0.2, 0.7, 0.2, 1) backwards; }

@keyframes spin { to { transform: rotate(360deg); } }
.spin { animation: spin 1.2s linear infinite; }

@keyframes shimmer {
  0% { background-position: -200px 0; }
  100% { background-position: 200px 0; }
}
.shimmer {
  background: linear-gradient(90deg, var(--bg-subtle) 0%, #FAFAFA 50%, var(--bg-subtle) 100%);
  background-size: 200px 100%;
  animation: shimmer 1.4s linear infinite;
}

/* --- Tweaks panel host overrides if needed --- */
.tweaks-panel { font-family: var(--font-kr); }

/* --- Divider --- */
.divider {
  height: 1px;
  background: var(--line-hair);
  margin: 18px 0;
}

/* --- Skin score donut --- */
.donut-wrap { position: relative; }
.donut-center {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  text-align: center;
  pointer-events: none;
}
.donut-center .v {
  font-family: var(--font-num);
  font-size: 30px;
  font-weight: 600;
  color: var(--ink-1);
  letter-spacing: -0.02em;
}
.donut-center .l {
  font-size: 11px;
  color: var(--ink-3);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-weight: 600;
}

/* === Phase tinting (Tweaks: Phase 1 / 2 / 3) === */
[data-phase="1"] { --phase-tint: #2F6FE0; }
[data-phase="2"] { --phase-tint: #1F9D6E; }
[data-phase="3"] { --phase-tint: #6A56D6; }

/* === Density === */
[data-density="compact"] .card-pad { padding: 16px 18px; }

/* --- Table --- */
.table { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 13px; }
.table th {
  text-align: left;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--ink-4);
  padding: 8px 12px;
  border-bottom: 1px solid var(--line-hair);
}
.table td {
  padding: 12px;
  border-bottom: 1px solid var(--line-hair);
  vertical-align: middle;
}
.table tr:last-child td { border-bottom: 0; }
.table tr:hover td { background: rgba(0,0,0,0.012); }

/* === Comparison row (본인 vs 일반) === */
.cmp-row {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 0.8fr;
  gap: 12px;
  padding: 10px 0;
  align-items: center;
  border-bottom: 1px dashed var(--line-hair);
  font-size: 13px;
}
.cmp-row:last-child { border-bottom: 0; }
.cmp-row .lbl { color: var(--ink-2); font-weight: 500; }
.cmp-row .val { font-family: var(--font-num); color: var(--ink-1); font-weight: 600; }
.cmp-row .base { font-family: var(--font-num); color: var(--ink-3); }
.cmp-row .verdict { text-align: right; }

/* === Phase 1 fringe banner (Bain-style 경고 띠) === */
.phase-fringe {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 8px 28px;
  background: linear-gradient(90deg, rgba(199, 73, 62, 0.08) 0%, rgba(199, 73, 62, 0.04) 100%);
  border-bottom: 1px solid rgba(199, 73, 62, 0.18);
  font-size: 11.5px;
  color: var(--alert);
  letter-spacing: 0.01em;
  font-weight: 500;
}
.phase-fringe .pf-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 10px;
  border: 1px solid var(--alert);
  border-radius: var(--r-pill);
  background: #FFF;
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-family: var(--font-num);
}
.phase-fringe .pf-tag::before {
  content: "";
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--alert);
}
.phase-fringe .pf-text { color: var(--ink-2); flex: 1; }
.phase-fringe .pf-meta { color: var(--ink-4); font-family: var(--font-mono); font-size: 10.5px; }
.phase-fringe .pf-link {
  color: var(--alert);
  text-decoration: underline;
  text-underline-offset: 2px;
  font-weight: 600;
  cursor: pointer;
}

/* === README / 면책 모달 === */
.modal-backdrop {
  position: fixed; inset: 0;
  background: rgba(15, 15, 17, 0.42);
  backdrop-filter: blur(4px);
  display: grid; place-items: center;
  z-index: 100;
  animation: fade-in 160ms ease-out;
}
.modal {
  width: min(820px, 92vw);
  max-height: 86vh;
  background: var(--bg-surface);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-deep);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.modal-head {
  padding: 22px 26px 16px;
  border-bottom: 1px solid var(--line-hair);
  display: flex;
  align-items: flex-start;
  gap: 16px;
}
.modal-title { font-size: 18px; font-weight: 700; color: var(--ink-1); margin: 0 0 4px; letter-spacing: -0.015em; }
.modal-sub { font-size: 12.5px; color: var(--ink-3); }
.modal-close {
  width: 32px; height: 32px; border-radius: 8px;
  display: grid; place-items: center;
  color: var(--ink-3);
}
.modal-close:hover { background: var(--bg-subtle); color: var(--ink-1); }
.modal-tabs {
  display: flex;
  gap: 4px;
  padding: 0 26px;
  border-bottom: 1px solid var(--line-hair);
  background: #FCFCFD;
}
.modal-tab {
  padding: 10px 14px;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--ink-3);
  border-bottom: 2px solid transparent;
  transition: all 120ms;
  margin-bottom: -1px;
}
.modal-tab:hover { color: var(--ink-1); }
.modal-tab.active { color: var(--ink-1); border-bottom-color: var(--ink-1); font-weight: 600; }
.modal-body {
  padding: 22px 26px 26px;
  overflow-y: auto;
  flex: 1;
  font-size: 13px;
  line-height: 1.65;
  color: var(--ink-2);
}
.modal-body h4 {
  margin: 18px 0 8px; font-size: 13px; font-weight: 700;
  color: var(--ink-1); letter-spacing: -0.005em;
}
.modal-body h4:first-child { margin-top: 0; }
.modal-body p { margin: 0 0 10px; }
.modal-body ul { margin: 6px 0 14px; padding-left: 20px; }
.modal-body li { margin: 3px 0; }
.modal-body code {
  font-family: var(--font-mono);
  font-size: 11.5px;
  background: var(--bg-subtle);
  padding: 1px 6px;
  border-radius: 4px;
}
.modal-body .callout {
  background: var(--alert-10);
  border-left: 3px solid var(--alert);
  padding: 10px 14px;
  border-radius: 0 8px 8px 0;
  margin: 12px 0;
  font-size: 12.5px;
  color: var(--ink-2);
}
.modal-body .callout.info {
  background: var(--data-blue-10);
  border-left-color: var(--data-blue);
}
.modal-body table.spec {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
  margin: 8px 0 14px;
}
.modal-body table.spec td {
  padding: 6px 10px;
  border-bottom: 1px dashed var(--line-hair);
  vertical-align: top;
}
.modal-body table.spec td:first-child {
  color: var(--ink-3);
  width: 32%;
  font-weight: 500;
}
.modal-body table.spec td:last-child { color: var(--ink-1); }

/* sidebar footer "About" link */
.sidebar-about {
  margin-top: 8px;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  color: var(--ink-3);
  padding: 6px 8px;
  border-radius: 6px;
  cursor: pointer;
}
.sidebar-about:hover { background: var(--bg-subtle); color: var(--ink-1); }

@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }
