/* Static condition pages (/conditions/, /ko/conditions/) — editorial "clinic journal" look:
   warm paper, deep navy ink, gold rule accents shared with the app's brand. */
:root {
  --paper: #faf6ee;
  --surface: #ffffff;
  --ink: #0b1a33;
  --ink-soft: #46546b;
  --rule: #e2d8c3;
  --gold: #a9812f;
  --gold-soft: #f3e9d2;
  --navy: #0b1a33;
  --on-navy: #f7f1e3;
  --care: #1f6b4f;
  --care-soft: #e6f2ec;

  --font-display: 'Cormorant Garamond', 'Noto Serif KR', Georgia, serif;
  --font-body: 'Inter', 'Apple SD Gothic Neo', 'Malgun Gothic', system-ui, sans-serif;

  --text-base: clamp(1rem, 0.96rem + 0.2vw, 1.0625rem);
  --text-h1: clamp(2.2rem, 1.4rem + 3.6vw, 3.6rem);
  --text-h2: clamp(1.5rem, 1.25rem + 1vw, 1.9rem);
  --measure: 44rem;
  --gutter: clamp(1rem, 0.5rem + 2.5vw, 2rem);
  --space-section: clamp(2rem, 1.5rem + 2vw, 3.25rem);
  --radius: 4px;
  --duration-fast: 150ms;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #070f1f;
    --surface: #0e1a30;
    --ink: #f1ead9;
    --ink-soft: #a9b3c4;
    --rule: #23324d;
    --gold: #d6b161;
    --gold-soft: #1b2437;
    --navy: #030812;
    --care: #7fd0ad;
    --care-soft: #10261f;
  }
}

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration-color: var(--gold); text-underline-offset: 0.2em; }
a:hover { color: var(--gold); }
a:focus-visible, button:focus-visible, input:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }

h1, h2, h3 { font-family: var(--font-display); line-height: 1.15; margin: 0; text-wrap: balance; }
h1 { font-size: var(--text-h1); font-weight: 700; letter-spacing: -0.01em; }
h2 { font-size: var(--text-h2); font-weight: 700; }
h3 { font-size: 1.2rem; font-weight: 700; margin-top: 1.75rem; }
p { margin: 0.75rem 0 0; }

/* ── Header ── */
.site-header {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.5rem 1.5rem;
  padding: 0.9rem var(--gutter);
  background: var(--navy); color: var(--on-navy);
  border-bottom: 2px solid var(--gold);
}
.brand { font-family: var(--font-display); font-size: 1.3rem; font-weight: 700; text-decoration: none; letter-spacing: 0.01em; }
.site-header nav { display: flex; gap: 1.25rem; font-size: 0.9rem; }
.site-header nav a { text-decoration: none; opacity: 0.85; transition: opacity var(--duration-fast); }
.site-header nav a:hover { opacity: 1; color: var(--on-navy); }
.lang-switch { border: 1px solid rgba(247, 241, 227, 0.4); border-radius: 999px; padding: 0 0.75rem; }

/* ── Layout ── */
main { max-width: calc(var(--measure) + 2 * var(--gutter)); margin: 0 auto; padding: 0 var(--gutter) var(--space-section); }
main.hub { max-width: 68rem; }
section, aside, .related { margin-top: var(--space-section); }

.breadcrumb { display: flex; flex-wrap: wrap; gap: 0.5rem; padding-top: 1.5rem; font-size: 0.85rem; color: var(--ink-soft); }
.breadcrumb a { text-decoration: none; }

.hero { padding: clamp(1.5rem, 1rem + 3vw, 3rem) 0 1.75rem; border-bottom: 1px solid var(--rule); }
.eyebrow { margin: 0 0 0.6rem; font-size: 0.75rem; font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase; color: var(--gold); }
.alt-name { margin-top: 0.4rem; font-family: var(--font-display); font-size: 1.25rem; color: var(--ink-soft); }
.byline { margin-top: 1rem; font-size: 0.82rem; color: var(--ink-soft); }
.byline a { font-weight: 600; color: var(--ink); }
.lead { font-size: 1.15rem; line-height: 1.6; max-width: 38rem; }

.facts { display: flex; flex-wrap: wrap; gap: 0.75rem 2.5rem; margin: 1.5rem 0 0; }
.facts dt { font-size: 0.72rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-soft); }
.facts dd { margin: 0.1rem 0 0; font-weight: 600; }

article h2 { padding-top: 1rem; border-top: 3px double var(--rule); }
.note { font-size: 0.92rem; color: var(--ink-soft); }

/* ── Lists ── */
.items, .steps, .plain { margin: 1rem 0 0; padding: 0; list-style: none; }
.items li, .steps li { padding: 0.8rem 0; border-bottom: 1px solid var(--rule); }
.items li:last-child, .steps li:last-child { border-bottom: 0; }
.items strong, .steps strong { display: block; }
.items span, .steps span { display: block; color: var(--ink-soft); font-size: 0.95rem; }

.steps { counter-reset: step; }
.steps li { position: relative; padding-left: 3rem; counter-increment: step; }
.steps li::before {
  content: counter(step, decimal-leading-zero);
  position: absolute; left: 0; top: 0.75rem;
  font-family: var(--font-display); font-size: 1.5rem; font-weight: 700; line-height: 1; color: var(--gold);
}

.plain li { position: relative; padding: 0.25rem 0 0.25rem 1.25rem; }
.plain li::before { content: ''; position: absolute; left: 0; top: 0.95em; width: 0.5rem; height: 1px; background: var(--gold); }

.care { background: var(--care-soft); border-left: 4px solid var(--care); border-radius: var(--radius); padding: 0.25rem 1.5rem 1.5rem; }
.care h2 { border-top: 0; color: var(--care); }

/* ── Calls to action ── */
.cta { padding: 1.75rem; border-radius: var(--radius); }
.cta h2 { font-size: 1.5rem; }
.cta-clinic { background: var(--navy); color: var(--on-navy); box-shadow: 0.5rem 0.5rem 0 var(--gold); }
.cta-app { background: var(--gold-soft); border: 1px solid var(--rule); }
.cta-actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 1.25rem; }

.btn {
  display: inline-block; padding: 0.7rem 1.4rem; border-radius: var(--radius); border: 1px solid transparent;
  font: 600 0.95rem var(--font-body); text-decoration: none; cursor: pointer;
  transition: transform var(--duration-fast), opacity var(--duration-fast);
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); opacity: 0.85; }
.btn-primary { background: var(--gold); color: #0b1a33; }
.btn-primary:hover { color: #0b1a33; }
.btn-ghost { border-color: currentColor; }

/* ── Clinic pages ── */
.svc-link { font-weight: 600; }
.service-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr)); gap: 1rem; margin: 1.25rem 0 0; padding: 0; list-style: none; }
.service-grid a {
  display: block; height: 100%; padding: 1.25rem; border: 1px solid var(--rule); border-top: 3px solid var(--gold); border-radius: var(--radius);
  background: var(--surface); text-decoration: none; transition: transform var(--duration-fast), border-color var(--duration-fast);
}
.service-grid a:hover { transform: translateY(-3px); border-color: var(--gold); color: inherit; }
.service-grid strong { display: block; font-family: var(--font-display); font-size: 1.35rem; }
.service-grid span { display: block; margin-top: 0.4rem; font-size: 0.86rem; line-height: 1.5; color: var(--ink-soft); }
.plain-items li { padding: 0.55rem 0; }
.red-flags { background: var(--surface); border: 1px solid var(--rule); border-left: 4px solid #b3261e; border-radius: var(--radius); padding: 0.25rem 1.5rem 1.25rem; }
.red-flags h2 { border-top: 0; font-size: 1.3rem; }
.faq { border-bottom: 1px solid var(--rule); padding: 0.75rem 0; }
.faq summary { cursor: pointer; font-weight: 600; list-style: none; position: relative; padding-right: 1.5rem; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; position: absolute; right: 0; top: 0; color: var(--gold); font-weight: 700; }
.faq[open] summary::after { content: '–'; }
.faq p { color: var(--ink-soft); }
.find-us address { font-style: normal; line-height: 1.8; margin-top: 0.75rem; }

/* ── Related + hub ── */
.related ul { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 1rem 0 0; padding: 0; list-style: none; }
.related a { display: block; padding: 0.4rem 0.9rem; border: 1px solid var(--rule); border-radius: 999px; background: var(--surface); font-size: 0.9rem; text-decoration: none; }
.related a:hover { border-color: var(--gold); }

.group > h2 { font-size: clamp(1.8rem, 1.4rem + 1.6vw, 2.6rem); padding-bottom: 0.5rem; border-bottom: 2px solid var(--gold); }
.region { margin-top: 2.25rem; scroll-margin-top: 1rem; }
.region h3 { display: flex; align-items: baseline; gap: 0.6rem; margin: 0; font-size: 1.45rem; }
.count { font: 600 0.75rem var(--font-body); color: var(--gold); letter-spacing: 0.08em; }
.region ul { display: grid; grid-template-columns: repeat(auto-fill, minmax(17rem, 1fr)); gap: 0 2rem; margin: 0.5rem 0 0; padding: 0; list-style: none; }
.region li { padding: 0.65rem 0; border-bottom: 1px solid var(--rule); }
.region li a { font-weight: 600; text-decoration: none; }
.region li span { display: block; font-size: 0.86rem; line-height: 1.45; color: var(--ink-soft); }

/* ── Signup + footer ── */
.signup { padding: 1.75rem; background: var(--surface); border: 1px solid var(--rule); border-top: 3px solid var(--gold); border-radius: var(--radius); max-width: var(--measure); }
.signup h2 { font-size: 1.5rem; }
.signup label { display: block; margin-top: 1rem; font-size: 0.85rem; font-weight: 600; }
.signup-row { display: flex; flex-wrap: wrap; gap: 0.6rem; margin-top: 0.4rem; }
.signup input[type='email'] {
  flex: 1 1 14rem; min-width: 0; padding: 0.7rem 0.9rem;
  border: 1px solid var(--rule); border-radius: var(--radius);
  background: var(--paper); color: var(--ink); font: inherit;
}
.hp { position: absolute; left: -9999px; }
.fine { font-size: 0.8rem; color: var(--ink-soft); }

.site-footer { padding: var(--space-section) var(--gutter); background: var(--navy); color: var(--on-navy); }
.site-footer > * { max-width: 68rem; margin-left: auto; margin-right: auto; }
.disclaimer { margin-top: 0; }
.disclaimer h2 { font-size: 1.15rem; color: var(--gold); }
.disclaimer p { font-size: 0.9rem; opacity: 0.85; max-width: 52rem; }
.site-footer .fine { margin-top: 1.5rem; color: inherit; opacity: 0.7; }

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
}
