/* ==========================================================
   페이지투웹 kit · 디자인 1 "라벨" — 모든 고객 페이지가 같이 쓴다.
   고객마다 바뀌는 것은 content.js(글, 수치, 색)와 이미지뿐이다.
   ========================================================== */

:root {
  --night: #061634;
  --night-2: #0b2250;
  --navy: #0a2b5e;
  --paper: #f1f4f9;
  --card: #ffffff;
  --line: #dde3ee;
  --ink: #0e1f3d;
  --muted: #5d6a80;
  --comp: #b3bbc8;
  --comp-deep: #5f687a;
  --brand-dot: #e5004f;

  /* product theme (overridden from content.js) */
  --accent: #e8457f;
  --accent-soft: color-mix(in srgb, var(--accent) 12%, #fff); /* content.js가 안 주면 accent에서 만든다 */
  --accent-2: #3db5a6;
  --glow: color-mix(in srgb, var(--accent) 72%, #fff);

  --f-body: "Pretendard Variable", Pretendard, system-ui, sans-serif;
  --f-num: "Anybody", "Pretendard Variable", sans-serif;
  --f-mono: var(--f-body); /* 고정폭 글꼴은 쓰지 않는다(심의 번호 · 참고문헌 번호 · p값도 본문 글꼴) */
  --ease: cubic-bezier(.16, 1, .3, 1);
  --spring: cubic-bezier(.34, 1.56, .64, 1);
  --radius: 14px;
  --band: color-mix(in srgb, var(--accent-2) 62%, #fff);
  --gutter: clamp(18px, 6vw, 96px);
  /* shared content column: logo, hero copy, evidence and footer line up; 1280px max on wide screens */
  --edge: max(var(--gutter), calc((100vw - 1280px) / 2));
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--f-body);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.55;
  word-break: keep-all;
  overflow-wrap: anywhere;
}
/* scroll lock (intro/popup): pad by the vanished scrollbar width so nothing jumps sideways,
   while overlays still cover the full width (a reserved gutter would show a pale strip) */
body.is-locked { overflow: hidden; padding-right: var(--lock-gap, 0px); }
body.is-locked .topbar { padding-right: calc(var(--edge) + var(--lock-gap, 0px)); }
img { max-width: 100%; display: block; }
button { font: inherit; color: inherit; }
sup { font-size: max(.62em, 11px); line-height: 0; margin-left: 1px; }
.nobr { white-space: nowrap; } /* 시간 범위 · 단위 붙은 숫자는 한 줄에 */
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 8px; }

/* ---------- Top bar ---------- */
.topbar {
  position: fixed; inset: 0 0 auto 0; z-index: 30;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: max(20px, env(safe-area-inset-top)) var(--edge) 20px;
  color: var(--ink);
  transition: background .4s ease, box-shadow .4s ease, padding-block .4s ease; /* not inline: scroll-lock padding must apply instantly */
}
.topbar .logo { height: 22px; width: auto; }
.topbar.is-solid {
  background: color-mix(in srgb, #fff 92%, transparent);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 var(--line);
  padding-block: 12px;
}
.topbar-product { font-weight: 700; font-size: 15px; opacity: 0; transform: translateY(6px); transition: .4s var(--ease); }
.topbar.is-solid .topbar-product { opacity: 1; transform: none; }
.topbar-actions { display: flex; gap: 24px; }
.chip-btn {
  border: 0; border-bottom: 1.5px solid transparent; background: none; padding: 5px 0; cursor: pointer;
  font-size: 14px; font-weight: 600; color: var(--muted); white-space: nowrap;
}
.chip-btn:hover, .chip-btn:focus-visible { color: var(--ink); border-bottom-color: var(--ink); }

/* ---------- Hero: composition borrowed from the product label ----------
   accent tab (label "전문" mark) + product name + full-width dose band.
   Height follows the content so the evidence title shows on the first desktop screen. */
.hero {
  position: relative; overflow: hidden;
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); grid-template-rows: 1fr auto;
  padding-top: 72px;
  background: #fff;
}
.hero-copy { grid-column: 1; grid-row: 1; align-self: center; padding: clamp(36px, 6vh, 72px) 0 clamp(56px, 8vh, 88px) var(--edge); }
.hero-kicker { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; font-size: clamp(15px, 1.3vw, 18px); font-weight: 600; color: var(--muted); }
.label-tab { background: var(--accent); color: #fff; font-size: 13px; font-weight: 700; padding: 5px 10px; border-radius: 3px; }
.product-name {
  margin: 16px 0 14px;
  font-size: clamp(48px, 5vw, 72px); font-weight: 800; line-height: 1; letter-spacing: -.045em;
  color: var(--accent);
}
.product-name .line { display: block; overflow: hidden; padding-bottom: .08em; }
.product-name .line > span { display: inline-block; transform: translateY(105%); transition: transform 1.1s var(--ease) .15s; }
.hero.is-ready .product-name .line > span { transform: none; }
.product-name .suffix { font-size: .3em; font-weight: 700; color: var(--ink); letter-spacing: 0; margin-left: .15em; }
.ingredients { margin: 0; font-size: clamp(17px, 1.4vw, 21px); font-weight: 600; color: var(--ink); }
.ingredients .sep { color: var(--comp); margin: 0 .45em; }
.hero-link {
  display: inline-flex; align-items: center; gap: 10px; margin-top: 26px;
  min-height: 52px; padding: 0 24px; border: 0; border-radius: 8px; cursor: pointer;
  background: var(--accent); color: #fff; font-size: 16px; font-weight: 700;
  transition: background-color .25s, transform .2s var(--ease);
}
.hero-link:hover, .hero-link:focus-visible { background: color-mix(in srgb, var(--accent) 82%, #000); }
.hero-link:active { transform: translateY(1px); }
.hero-link svg { width: 18px; height: 18px; transition: transform .3s var(--ease); }
.hero-link:hover svg, .hero-link:focus-visible svg { transform: translateY(3px); }

.stage {
  grid-column: 2; grid-row: 1; align-self: end; justify-self: end;
  position: relative; z-index: 2; width: min(88%, 470px); margin: 0 var(--edge) -44px 0;
}
.stage-parallax { transform-origin: 50% 100%; }
.stage .product { width: 100%; height: auto; opacity: 0; filter: drop-shadow(0 16px 16px rgba(14, 31, 61, .14)); }
.hero.is-ready .stage .product { animation: land 1.15s var(--ease) .75s forwards; }
@keyframes land {
  0% { opacity: 0; transform: translateY(-160px); }
  50% { opacity: 1; transform: translateY(8px); }
  70% { transform: translateY(-7px); }
  100% { opacity: 1; transform: none; }
}
.stage-shadow {
  position: absolute; left: 14%; right: 14%; bottom: 3%; height: 9%; z-index: -1; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(10, 60, 52, .38), transparent);
  opacity: 0; transform: scaleX(.3);
}
.hero.is-ready .stage-shadow { animation: shadow 1.15s var(--ease) .75s forwards; }
@keyframes shadow {
  0% { opacity: 0; transform: scaleX(.3); }
  50% { opacity: 1; transform: scaleX(1.08); }
  100% { opacity: .85; transform: none; }
}

.hero-band {
  grid-column: 1 / -1; grid-row: 2;
  display: flex; align-items: center; gap: clamp(20px, 3vw, 48px);
  padding: 24px calc(var(--edge) + min(40%, 500px)) 24px var(--edge);
  background: var(--band); color: var(--ink);
  clip-path: inset(0 100% 0 0); transition: clip-path 1s cubic-bezier(.77, 0, .18, 1) .1s;
}
.hero.is-ready .hero-band { clip-path: inset(0); }
.band-strength { font-family: var(--f-num); font-weight: 800; font-size: clamp(36px, 3.6vw, 54px); line-height: 1; letter-spacing: -.02em; white-space: nowrap; }
.band-strength small { font-size: .6em; font-weight: 700; margin-left: .08em; }
.band-tagline { font-size: clamp(16px, 1.45vw, 20px); font-weight: 600; line-height: 1.4; }

/* ---------- Intro: the label assembles, then glides into the hero (brochure.js playIntro) ---------- */
.intro {
  position: fixed; inset: 0; z-index: 70;
  display: grid; align-content: center; gap: clamp(22px, 4vh, 44px);
  background: rgb(255 255 255 / 1); transition: background-color .65s ease;
}
.intro-label { padding: 0 var(--edge); }
.intro-tab { display: inline-block; font-size: clamp(13px, 1.2vw, 17px); padding: 6px 12px; animation: intro-stamp .35s var(--spring) both; }
.intro-name { margin-top: 18px; font-size: clamp(52px, 6.4vw, 96px); font-weight: 800; line-height: .95; letter-spacing: -.045em; color: var(--accent); }
.intro-name .line { display: inline-block; overflow: hidden; padding-bottom: .08em; transform-origin: 0 0; }
.intro-name .line > span { display: inline-block; animation: intro-rise .6s var(--ease) .1s both; }
.intro-name .suffix { font-size: .3em; font-weight: 700; color: var(--ink); letter-spacing: 0; margin-left: .15em; }
.intro-band {
  padding: clamp(18px, 3vh, 30px) var(--edge); background: var(--band); transform-origin: 0 0;
  animation: intro-wipe .5s cubic-bezier(.77, 0, .18, 1) .35s both;
}
.intro-band .band-strength { display: inline-block; animation: intro-fade .35s ease .6s both; }
.intro.is-leaving { background-color: rgb(255 255 255 / 0); transition-duration: .55s; }
.intro.is-leaving .intro-tab, .intro.is-leaving .intro-band > * { animation: none; opacity: 0; }
.intro.is-leaving .intro-name .line > span, .intro.is-leaving .intro-band { animation: none; }
.intro.is-fading { opacity: 0; transition: opacity .4s ease; }
@keyframes intro-stamp { from { opacity: 0; transform: scale(1.3); } to { opacity: 1; transform: none; } }
@keyframes intro-rise { from { transform: translateY(105%); } to { transform: none; } }
@keyframes intro-wipe { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0); } }
@keyframes intro-fade { from { opacity: 0; } to { opacity: 1; } }

/* the gliding intro name/band stand in for the hero's own until they land */
.hero.from-intro .product-name .line > span { transition: none; transform: none; opacity: 0; }
.hero.from-intro .hero-band { transition: none; clip-path: inset(0); opacity: 0; }
.hero.intro-done .product-name .line > span, .hero.intro-done .hero-band { opacity: 1; }
.hero.intro-done .hero-band > * { animation: intro-fade .45s ease both; }
.hero.from-intro.is-ready .stage .product, .hero.from-intro.is-ready .stage-shadow { animation-delay: .2s; }

/* ---------- Evidence board ---------- */
.evidence { padding: clamp(64px, 9vw, 120px) var(--edge) clamp(56px, 7vw, 96px); }
.evidence-head { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 12px 32px; margin-bottom: clamp(28px, 4vw, 48px); }
.evidence-head h2 { margin: 0; font-size: clamp(28px, 3vw, 44px); font-weight: 820; letter-spacing: -.03em; line-height: 1.1; }
.evidence-head p { margin: 0; color: var(--muted); font-size: 15px; }
.pillars { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(14px, 1.6vw, 22px); }
.pillars { grid-template-rows: auto 1fr 1fr; }
.pillar { display: grid; grid-row: span 3; grid-template-rows: subgrid; gap: clamp(14px, 1.6vw, 22px); }
.pillar-cards { display: contents; }
.pillars.is-row { grid-template-columns: repeat(var(--cards), minmax(0, 1fr)); grid-template-rows: auto 1fr; }
.pillars.is-row .pillar { grid-row: span 2; grid-column: span var(--span); grid-template-columns: subgrid; }
.pillars.is-row .pillar-head { grid-column: 1 / -1; }
.pillar-head { padding: 0 4px 6px; border-bottom: 2px solid var(--ink); }
.pillar-label {
  display: flex; align-items: center; gap: 10px;
  font-size: clamp(22px, 1.9vw, 28px); font-weight: 800; letter-spacing: -.02em; color: var(--ink); line-height: 1;
}
.pillar-summary { margin: 8px 0 8px; font-size: 14px; color: var(--muted); line-height: 1.45; }

.card {
  position: relative; overflow: hidden; isolation: isolate; cursor: pointer;
  display: flex; flex-direction: column; min-height: 250px;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: clamp(20px, 2vw, 28px);
  transition: transform .45s var(--ease), box-shadow .45s var(--ease), border-color .25s;
  -webkit-tap-highlight-color: transparent;
}
@media (hover: hover) {
  .card:hover { transform: translateY(-3px); box-shadow: 0 18px 36px -24px rgba(10, 43, 94, .32); border-color: var(--accent); }
  .card:hover .card-more { color: var(--accent); transform: translateX(4px); }
}
.card:focus-visible { border-color: var(--accent); outline-offset: 2px; }
.card:focus-visible .card-more { color: var(--accent); transform: translateX(4px); }
.card:active { transform: scale(.99); }
.card-eyebrow { font-size: 13px; font-weight: 600; color: var(--muted); }
.card-stat {
  margin-top: 4px; display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap;
}
.num {
  font-family: var(--f-num); font-weight: 820; font-variation-settings: "wdth" 100;
  font-variant-numeric: tabular-nums; letter-spacing: -.02em; line-height: .95;
}
.card-stat .num { font-size: clamp(46px, 4.4vw, 70px); color: var(--accent); }
.num .u { font-size: .6em; margin-left: .04em; letter-spacing: 0; }
.card-stat .stat-text { font-size: clamp(26px, 2.3vw, 34px); font-weight: 820; color: var(--accent); letter-spacing: -.02em; line-height: 1.1; }
.card-stat .stat-label { font-size: 14px; font-weight: 700; color: var(--ink); }
/* 숫자가 먼저, 그 아래 무슨 숫자인지(2026-11-21 사용자: 숫자 위 작은 머리말 없앰) */
.card-what { margin-top: 8px; font-size: 15px; font-weight: 700; color: var(--ink); }
.card-compare { margin-top: 4px; font-size: 14px; color: var(--muted); }
.card-compare b { font-family: var(--f-num); font-variation-settings: "wdth" 90; font-weight: 700; color: var(--comp-deep); }
.card-mini { margin-top: auto; padding-top: 14px; height: 126px; }
.card-mini svg { width: 100%; height: 100%; overflow: visible; }
.card-mini:empty { display: none; }
.card-mini:has(.mini-figs) { height: auto; }
.mini-figs { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.mini-figs li { padding: 9px 0 0; font-size: 13px; font-weight: 600; color: var(--muted); line-height: 1.4; }
/* 휴대폰 카드 줄의 "1 / 2" */
.pillar-count { display: none; margin: -6px 0 0; font-size: 13px; font-weight: 600; color: var(--muted); font-variant-numeric: tabular-nums; }
.pillar-count b { color: var(--ink); }
.card-more {
  position: absolute; right: 16px; top: 18px; width: 32px; height: 32px;
  display: grid; place-items: center; color: var(--muted); transition: color .25s, transform .35s var(--ease);
}
.card-more svg { width: 20px; height: 20px; }

.extras { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: clamp(14px, 1.6vw, 22px); margin-top: clamp(14px, 1.6vw, 22px); }
.extras:has(> .card:only-child) { grid-template-columns: 1fr; }
.card.is-wide { min-height: 0; }
.card.is-wide h3 { margin: 8px 0 6px; font-size: clamp(20px, 1.7vw, 25px); font-weight: 780; letter-spacing: -.02em; line-height: 1.3; padding-right: 44px; }
.card.is-wide p { margin: 0; color: var(--muted); font-size: 15px; }
.org-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px 20px; margin-top: auto; padding-top: 18px; }
.org-item { display: grid; justify-items: start; align-content: start; gap: 8px; }
.extras:not(:has(.drug-extra)) .org-item p { display: none; } /* 옆 제품 정보 카드가 짧으면(알약 그림 · 수치 없음) 기관 이름만: 두 카드 높이를 맞춘다 */
.card.is-wide .org-item p { font-size: 15px; line-height: 1.5; color: var(--ink); }
.org { font-size: 13px; font-weight: 600; padding: 5px 10px; border-radius: 4px; background: var(--paper); color: var(--navy); }
/* 제품 정보 카드: 짧은 수치 셋 + 성상대로 그린 알약 */
.drug-extra { margin-top: auto; padding-top: 18px; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: 16px 24px; }
.drug-facts { margin: 0; display: flex; flex-wrap: wrap; gap: 10px 28px; align-self: end; }
.drug-facts div { display: flex; flex-direction: column-reverse; }
.drug-facts dt { font-size: 13px; font-weight: 600; color: var(--muted); }
.drug-facts dd { margin: 0; font-size: 18px; font-weight: 780; letter-spacing: -.02em; color: var(--ink); }
.drug-pic { width: 140px; }
.drug-pic.is-photo { overflow: hidden; border-radius: 8px; }
.drug-pic.is-photo img { display: block; width: 100%; aspect-ratio: 1; object-fit: cover; transform: scale(1.7); transform-origin: 53% 44%; } /* 카드 칸은 작아서 알약 쪽으로 당겨 자른다 */
.tablet { width: 100%; height: auto; display: block; overflow: visible; }
.tablet .tab-mark { font: 800 22px var(--f-body); letter-spacing: .02em; }
.tablet .tab-cap { font: 600 13px var(--f-body); fill: var(--muted); }
.drug-figure { margin: 0 0 22px; padding: 22px 24px 18px; background: var(--paper); border-radius: 10px; }
.drug-figure .tablet { max-width: 420px; }
.drug-figure.is-photo { padding: 0; background: none; }
.drug-figure.is-photo img { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; object-position: 50% 45%; border-radius: 10px; }
.drug-figure figcaption { margin-top: 10px; font-size: 14px; color: var(--muted); }
.card.is-band { background: var(--band); border-color: var(--band); }
.card.is-band p, .card.is-band .card-eyebrow, .card.is-band .card-more { color: color-mix(in srgb, var(--ink) 72%, transparent); }
.card.is-band .org { background: #fff; }

/* ---------- Footer: 전문의약품 자료의 마지막 줄 (알림 · 부작용 신고 · 제조원 · 허가 · 보험코드 · 개정일 · 심의필) ---------- */
.footer { background: var(--night); color: color-mix(in srgb, #fff 80%, transparent); padding: 48px var(--edge) 56px; font-size: 14px; line-height: 1.7; }
.footer-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 32px 56px; }
.footer ul { margin: 0; padding: 0; list-style: none; }
.footer li + li { margin-top: 4px; }
.footer .logo { height: 26px; width: auto; filter: grayscale(1) invert(1) brightness(1.6); /* 어두운 색은 흰색, 네모 안 흰 무늬는 어둡게 남김 */ margin-bottom: 16px; }
.footer a { color: #fff; }
.footer-notes li { padding-left: 1em; text-indent: -1em; }
.footer-notes li::before { content: "※ "; }
.footer-ae { margin: 22px 0 0; padding: 16px 20px; display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 2px 18px; align-items: baseline; background: color-mix(in srgb, #fff 9%, transparent); color: #fff; }
.footer-ae b { grid-row: span 2; font-size: 15px; font-weight: 800; }
.footer-ae span { color: color-mix(in srgb, #fff 86%, transparent); }
.footer-ae-call { font-weight: 700; }
.footer-ae a { color: #fff; font-weight: 800; text-underline-offset: 3px; }
.footer-facts { margin: 0; display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 3px 18px; }
.footer-facts div { display: contents; }
.footer-facts dt { color: color-mix(in srgb, #fff 64%, transparent); }
.footer-facts dd { margin: 0; }
.footer-doc { display: inline-flex; align-items: center; min-height: 44px; margin-top: 10px; padding: 0; border: 0; background: none; cursor: pointer; color: #fff; font: 700 15px var(--f-body); text-decoration: underline; text-underline-offset: 5px; text-decoration-thickness: 1.5px; }
.footer-doc:hover, .footer-doc:focus-visible { text-decoration-thickness: 3px; }

/* ---------- Modal ---------- */
.modal { position: fixed; inset: 0; z-index: 60; display: grid; place-items: center; padding: 16px; }
.modal[hidden] { display: none; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(6, 22, 52, .58); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); opacity: 0; transition: opacity .45s ease; }
.modal.is-open .modal-backdrop { opacity: 1; }
.modal-panel {
  position: relative; width: min(980px, 100%); max-height: calc(100svh - 32px); overflow: auto; overscroll-behavior: contain;
  background: var(--card); border-radius: 20px; padding: clamp(22px, 4vw, 52px);
  box-shadow: 0 50px 120px -40px rgba(0, 0, 0, .55);
  transform-origin: 0 0;
}
.modal-close {
  position: sticky; top: 0; float: right; margin: -6px -6px 0 12px; z-index: 2; /* 내려도 오른쪽 위에 붙어 따라온다 */
  width: 44px; height: 44px; border-radius: 50%; border: 0; cursor: pointer; background: var(--paper);
  display: grid; place-items: center;
}
.modal-close svg { width: 18px; height: 18px; }
.modal-close:hover, .modal-close:focus-visible { background: var(--ink); color: #fff; }
.modal-eyebrow { display: flex; align-items: center; gap: 8px; font-weight: 800; color: var(--accent); font-size: 15px; }
.modal h2 { margin: 10px 0 18px; font-size: clamp(24px, 3vw, 38px); font-weight: 820; letter-spacing: -.03em; line-height: 1.2; }
.messages { margin: 0 0 28px; padding: 0; list-style: none; display: grid; gap: 10px; }
.messages li { position: relative; padding: 14px 18px 14px 46px; border-radius: 10px; background: var(--accent-soft); font-size: clamp(15px, 1.5vw, 18px); line-height: 1.5; }
.messages li::before { content: ""; position: absolute; left: 16px; top: 19px; width: 18px; height: 18px; border-radius: 50%; background: var(--accent); box-shadow: inset 0 0 0 5px var(--accent-soft), 0 0 0 0 var(--accent); }
.messages b { font-weight: 800; }
.figure { margin: 0 0 24px; padding: clamp(14px, 2.4vw, 28px); border: 1px solid var(--line); border-radius: var(--radius); }
.figure svg { width: 100%; height: auto; overflow: visible; display: block; }
.figure figcaption { margin-top: 12px; font-size: 13px; color: var(--muted); display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.figure figcaption .p { font-style: italic; }
.figure .note { margin-top: 6px; font-size: 13px; color: var(--muted); }
.figure.is-info figcaption { margin-top: 0; }
.fig-facts { margin: 0 0 12px; display: grid; gap: 0; }
.fig-facts div { display: grid; grid-template-columns: 92px minmax(0, 1fr); gap: 12px; padding: 9px 0; border-bottom: 1px solid var(--line); }
.fig-facts div:first-child { border-top: 2px solid var(--ink); }
.fig-facts dt { font-size: 13px; font-weight: 700; color: var(--accent); }
.fig-facts dd { margin: 0; font-size: 14.5px; color: var(--ink); }
.risk-table + .risk-table { margin-top: 22px; }
.risk-table { width: 100%; border-collapse: collapse; margin-top: 16px; font-size: 13px; font-variant-numeric: tabular-nums; }
.risk-table th, .risk-table td { padding: 7px 8px; text-align: right; border-bottom: 1px solid var(--line); }
.risk-table th:first-child, .risk-table td:first-child { text-align: left; }
.risk-table td:not(:first-child) { white-space: nowrap; }
.risk-table caption { text-align: left; color: var(--muted); font-size: 13px; padding-bottom: 4px; }
.risk-table tr.hl td { color: var(--accent); font-weight: 700; background: var(--accent-soft); }
.details { border-top: 1px solid var(--line); padding-top: 8px; }
.details summary:hover, .details summary:focus-visible { color: var(--accent); }
.details summary { cursor: pointer; font-weight: 700; padding: 10px 0; list-style: none; display: flex; align-items: center; gap: 8px; }
.details summary::-webkit-details-marker { display: none; }
.details summary::before { content: "+"; display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--paper); font-weight: 700; }
.details[open] summary::before { content: "−"; }
.details-body { font-size: 13px; color: var(--muted); display: grid; gap: 10px; padding-bottom: 8px; }
.details-body b { color: var(--accent); }
/* 연구 설계 한눈에: 대상 · 배정 · 기간 · 1차 평가변수 */
.design-facts { margin: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 8px; }
.design-facts div { padding: 12px 14px; background: var(--paper); border-radius: 8px; }
.design-facts dt { font-size: 13px; font-weight: 600; color: var(--muted); }
.design-facts dd { margin: 2px 0 0; font-size: 15px; font-weight: 700; color: var(--ink); line-height: 1.4; }
.refs { margin: 0; padding-left: 0; list-style: none; display: grid; gap: 8px; }
.refs li { display: grid; grid-template-columns: 26px 1fr; font-size: 13px; color: var(--muted); }
.refs .ref-no { color: var(--accent); font-weight: 700; font-variant-numeric: tabular-nums; }
.info-table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
.info-table th { width: 118px; text-align: left; vertical-align: top; padding: 14px 12px 14px 0; color: var(--accent); font-weight: 700; white-space: nowrap; }
.info-table td { padding: 14px 0; border-bottom: 1px solid var(--line); line-height: 1.65; }
.info-table tr:first-child td { border-top: 2px solid var(--ink); }
.info-table tr:first-child th { border-top: 2px solid var(--ink); }
.info-table th { border-bottom: 1px solid var(--line); }
.guide-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin-bottom: 24px; }
.guide { border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.guide .org { display: inline-block; margin-bottom: 10px; }
.guide p { margin: 0; font-size: 15.5px; line-height: 1.6; }
.lead { font-size: clamp(16px, 1.7vw, 20px); margin: 0 0 22px; padding: 18px 22px; border-radius: 10px; background: var(--band); }

/* ---------- Charts ----------
   막대는 통짜 색(그라데이션 없음). 값 글자는 그래프 바탕색 테두리(--chart-bg)로 눈금선 위에서도 읽힌다 */
.chart { --chart-bg: var(--card); }
.chart text { font-family: var(--f-body); fill: var(--muted); }
.chart .tick { font-size: 13px; font-variant-numeric: tabular-nums; }
.chart .grid { stroke: var(--line); stroke-width: 1; }
.chart .zero { stroke: var(--ink); stroke-width: 1.6; }
.chart .bar { fill: var(--comp); transform-box: fill-box; transform: scaleY(0); transition: transform 1.3s var(--ease); transition-delay: calc(var(--k, 0) * 140ms + 120ms); }
.chart .bar.hl { fill: var(--accent); }
.chart .bar.neg { transform-origin: 50% 0%; }
.chart .bar.pos { transform-origin: 50% 100%; }
.chart .cap { stroke: var(--comp-deep); stroke-width: 2; opacity: 0; transition: opacity .4s ease; transition-delay: calc(var(--k, 0) * 140ms + 900ms); }
.chart .cap.hl { stroke: var(--accent); }
.chart .val { font-family: var(--f-num); font-weight: 820; font-size: 30px; fill: var(--comp-deep); opacity: 0; transition: opacity .5s ease; transition-delay: calc(var(--k, 0) * 140ms + 700ms);
  paint-order: stroke; stroke: var(--chart-bg); stroke-width: 7px; stroke-linejoin: round; }
.chart .val.hl { fill: var(--accent); }
.chart .val.end { font-size: 21px; }
.chart .u { font-size: .6em; }
.chart .lbl { font-size: 15px; font-weight: 600; fill: var(--ink); }
.chart .lbl.hl { fill: var(--accent); font-weight: 800; }
.chart .sub { font-size: 13px; }
.chart .mini { font-weight: 600; fill: var(--muted); }
.chart .mini.hl { font-weight: 800; fill: var(--accent); }
.chart .axis-title { font-size: 13px; }
.chart .callout path { fill: none; stroke: var(--accent); stroke-width: 2; stroke-linejoin: round; opacity: 0; transition: opacity .5s ease 1.4s; }
.chart .callout text { font-family: var(--f-num); font-weight: 860; font-size: 28px; fill: var(--accent); opacity: 0; transition: opacity .5s ease 1.6s; paint-order: stroke; stroke: var(--chart-bg); stroke-width: 7px; }
.chart .person { transform-box: fill-box; transform-origin: 50% 100%; transform: scale(.6); opacity: 0; transition: transform .8s var(--spring), opacity .4s; transition-delay: calc(var(--k, 0) * 160ms + 150ms); }
.chart .person.hl { fill: var(--accent); }
.chart .person.dim { fill: var(--comp); }
.chart .chev { fill: none; stroke: color-mix(in srgb, var(--accent) 40%, #fff); stroke-width: 12; stroke-linecap: round; stroke-linejoin: round; opacity: 0; transition: opacity .5s ease 1s; }
.chart.is-playing .bar { transform: scaleY(1); }
.chart.is-playing .val, .chart.is-playing .cap, .chart.is-playing .callout path, .chart.is-playing .callout text, .chart.is-playing .chev { opacity: 1; }
.chart.is-playing .person { transform: none; opacity: 1; }
.chart.compact .bar { transition-duration: 1.1s; }
.chart.narrow .tick { font-size: 17px; }
.chart.narrow .lbl { font-size: 18px; }
.chart.narrow .val { font-size: 34px; }
.chart.narrow .val.end { font-size: 24px; }
.chart.narrow .sub { font-size: 15px; }
.chart.narrow .callout text { font-size: 32px; }

/* ---------- Reveal ---------- */
.reveal { opacity: 0; transform: translateY(36px); transition: opacity .9s var(--ease), transform .9s var(--ease); transition-delay: var(--delay, 0s); }
.reveal.is-in { opacity: 1; transform: none; }
.reveal-shown .reveal:not(.is-in) { opacity: 1; transform: translateY(14px); transition: none; } /* page.js: 1.6초 뒤 화면 밖 구역도 보임 */
@media print { .reveal { opacity: 1 !important; transform: none !important; } }
.hero .rise { opacity: 0; transform: translateY(20px); transition: opacity .9s var(--ease), transform .9s var(--ease); transition-delay: var(--delay, 0s); }
.hero.is-ready .rise { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (orientation: portrait) and (min-width: 761px) {
  .hero-copy { padding-top: 56px; padding-bottom: 96px; }
  .stage { width: min(88%, 400px); }
}
@media (max-width: 980px) {
  .pillars { grid-template-columns: 1fr; }
  .pillars { grid-template-rows: none; }
  .pillar { grid-row: auto; grid-template-rows: auto; }
  .pillar-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(14px, 1.6vw, 22px); }
  .pillars.is-row { grid-template-columns: 1fr; grid-template-rows: none; }
  .pillars.is-row .pillar { grid-row: auto; grid-column: auto; grid-template-columns: none; }
  .pillar-cards:has(> .card:only-child) { grid-template-columns: 1fr; }
  .extras { grid-template-columns: 1fr; }
  .guide-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .drug-pic { width: 128px; }
}
@media (max-width: 760px) {
  .pillars { gap: 34px; }
  .pillar-cards {
    display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory;
    margin: 0 calc(-1 * var(--gutter)); padding: 4px var(--gutter) 18px; scrollbar-width: none;
  }
  .pillar-cards::-webkit-scrollbar { display: none; }
  .pillar-cards .card { flex: 0 0 86%; scroll-snap-align: center; min-height: 236px; }
  .pillar-cards .card:only-child { flex-basis: 100%; }
  .pillar-count { display: block; }
  .hero { grid-template-columns: 1fr; grid-template-rows: auto auto auto; padding-top: 64px; }
  .hero-copy { grid-row: 1; padding: 16px var(--gutter) 0; }
  .product-name { margin: 16px 0 12px; }
  .hero-link { margin-top: 22px; }
  .stage { grid-column: 1; grid-row: 2; align-self: end; justify-self: center; width: min(56vw, 250px); margin: 4px auto -36px; }
  .hero-band { grid-row: 3; flex-direction: column; align-items: flex-start; gap: 8px; padding: 52px var(--gutter) 24px; }
  .topbar-product { display: none; }
  .topbar-actions { gap: 16px; }
  .modal { padding: 0; align-items: end; }
  .modal-panel { border-radius: 18px 18px 0 0; max-height: 92svh; padding-bottom: max(22px, env(safe-area-inset-bottom)); }
  .product-name { font-size: clamp(36px, 11vw, 44px); }
  .info-table th { width: 84px; white-space: normal; }
}

/* ---------- Calm motion (prefers-reduced-motion, e.g. Windows "animation effects" off) ----------
   keep wipes, fades, number rolls and chart growth; drop travel, bounce, zoom and parallax */
@media (prefers-reduced-motion: reduce) {
  html:not(.force-motion) { scroll-behavior: auto; }
  html:not(.force-motion) .reveal,
  html:not(.force-motion) .hero .rise { transform: none; }
  html:not(.force-motion) .hero .product-name .line > span { transform: none; opacity: 0; transition: opacity .9s ease .15s; }
  html:not(.force-motion) .hero.is-ready .product-name .line > span { opacity: 1; }
  html:not(.force-motion) .hero.is-ready .stage .product { animation: calm-appear 1s ease .6s forwards; }
  html:not(.force-motion) .hero.is-ready .stage-shadow { animation: calm-shadow 1s ease .6s forwards; }
  html:not(.force-motion) .intro-tab,
  html:not(.force-motion) .intro-name .line > span { animation: intro-fade .5s ease both; }
  html:not(.force-motion) .intro-name .line > span { animation-delay: .15s; }
}
@keyframes calm-appear { from { opacity: 0; transform: scale(.97); } to { opacity: 1; transform: none; } }
@keyframes calm-shadow { from { opacity: 0; } to { opacity: .85; } }
