/* A1 (2026-10-13): layout and light styling for the site shell's inner pages.
   Visual rule for this round: use only what V25 already fixed (header, amber capsule, shared ivory paper,
   fonts, ink colours). No new paper-cut art, illustration or material here. Every value the art window may
   want to change sits in the custom properties below, so restyling does not touch page structure.
   Loaded after the V25 stylesheets (hero.css, header-v15.css, water-button.css, capsule-tint-v16.css …). */
/* Fonts: one @font-face set for the whole site, in v25/hero.css (generated by tools/build-fonts.py; its URLs are
   relative to hero.css, so it works at any site root). */

:root {
  --shell-ink: #243f33;            /* V25 --ink */
  --shell-body: #50564a;           /* V25 --body */
  --shell-forest: #234b3b;         /* V25 capsule text */
  --shell-muted: #5d6253;
  --shell-accent: #7a5c2a;         /* eyebrow / small labels on ivory, >= 4.5:1 */
  --shell-line: #8179524d;
  --shell-card: #fffaf0b8;
  --shell-card-border: #a5947245;
  --shell-radius: 18px;
  --shell-width: 1180px;
  --shell-reading: 720px;
  --shell-gutter: 6%;
  --shell-gap: clamp(48px, 7vw, 96px);
  --shell-title-serif: Georgia, 'Times New Roman', serif;   /* V25 English display face */
}

/* ---------- page frame ---------- */
.shell-page main { display: block; }
.shell-main { max-width: var(--shell-width); margin: 0 auto; padding: 0 var(--shell-gutter) var(--shell-gap); }
.shell-hero { max-width: var(--shell-width); margin: 0 auto; padding: clamp(28px, 5vw, 72px) var(--shell-gutter) clamp(32px, 4vw, 56px); }
.shell-eyebrow { margin: 0 0 14px; font-size: 14px; letter-spacing: .02em; color: var(--shell-accent); }
.shell-page h1 { font-size: clamp(40px, 4.4vw, 64px); letter-spacing: -1.6px; line-height: 1.12; margin: 0 0 22px; max-width: 18ch; }
:root:not(:lang(en)) .shell-page h1 { font-size: clamp(30px, 3.2vw, 46px); letter-spacing: -.5px; line-height: 1.4; max-width: 22em; }
.shell-page main h2 { font-family: var(--font); font-weight: 600; font-size: clamp(22px, 2.2vw, 28px); line-height: 1.4; margin: 0 0 14px; color: var(--shell-ink); }
:root:lang(en) .shell-page .shell-section > h2 { font-family: var(--shell-title-serif); font-weight: 400; font-size: clamp(26px, 2.6vw, 34px); letter-spacing: -.4px; }
.shell-page main h3 { font-size: 17px; font-weight: 600; margin: 0 0 6px; line-height: 1.5; }
.shell-lead { max-width: 40em; margin: 0; font-size: clamp(16px, 1.3vw, 18px); line-height: 1.85; color: var(--shell-body); }
.shell-page p { color: var(--shell-body); }
.shell-page :is(p, li, dd) { text-wrap: pretty; overflow-wrap: anywhere; }
:root:lang(ko) .shell-page :is(h1, h2, h3, p, li) { word-break: keep-all; }
:root:lang(ja) .shell-page :is(h1, h2) { word-break: auto-phrase; }
.shell-section { padding-top: var(--shell-gap); }
.shell-section + .shell-section { border-top: 1px solid var(--shell-line); margin-top: var(--shell-gap); }
.shell-section > p { max-width: 40em; }
.shell-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 18px 28px; margin-top: 30px; }
.shell-text-link { display: inline-flex; align-items: center; min-height: 44px; font-size: 15px; color: var(--shell-ink); text-underline-offset: 5px; }
.shell-text-link:hover { color: #647b53; }
a.droplet { display: inline-flex; align-items: center; justify-content: center; text-align: center; text-decoration: none; color: var(--capsule-text, var(--shell-forest)); }
a.droplet[aria-disabled] { opacity: .55; cursor: not-allowed; }
.tool-note { flex-basis: 100%; margin: 0; font-size: 14px; color: var(--shell-muted); }
.shell-small { font-size: 14px; color: var(--shell-muted); }
.shell-badge { display: inline-block; padding: 2px 10px; border: 1px solid var(--shell-card-border); border-radius: 999px; font-size: 13px; color: var(--shell-accent); background: #fffaf080; }

/* ---------- cards and lists ---------- */
.shell-card { background: var(--shell-card); border: 1px solid var(--shell-card-border); border-radius: var(--shell-radius); padding: 24px; }
.shell-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr)); gap: 18px; }
.shell-steps { list-style: none; margin: 34px 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(260px, 100%), 1fr)); gap: 18px; counter-reset: step; }
.shell-steps li { counter-increment: step; position: relative; padding: 24px 24px 24px 72px; background: var(--shell-card); border: 1px solid var(--shell-card-border); border-radius: var(--shell-radius); }
.shell-steps li::before { content: counter(step); position: absolute; left: 24px; top: 22px; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; font-weight: 600; font-size: 14px; color: var(--shell-forest); border: 1px solid #ba864580; background: #ba86451f; }
.shell-steps p { margin: 0; font-size: 15px; line-height: 1.75; }
.shell-term-list { list-style: none; margin: 18px 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(250px, 100%), 1fr)); gap: 14px; }
.shell-term-list a, .shell-term-list .is-soon { display: flex; flex-direction: column; gap: 4px; height: 100%; padding: 18px 20px; border-radius: 14px; background: var(--shell-card); border: 1px solid var(--shell-card-border); text-decoration: none; color: var(--shell-ink); }
.shell-term-list a:hover { border-color: #ba8645a0; }
.shell-term-list strong { font-size: 17px; }
.shell-term-list span { font-size: 14px; line-height: 1.7; color: var(--shell-body); }
.shell-term-list .is-soon { border-style: dashed; color: var(--shell-muted); }
.shell-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 16px 0 0; padding: 0; list-style: none; }
.shell-chips li { padding: 8px 14px; min-height: 40px; display: inline-flex; align-items: center; border-radius: 999px; border: 1px solid var(--shell-card-border); background: #fffaf080; font-size: 14px; }
.shell-two { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr)); gap: 36px; }

/* ---------- footer (frosted, on the shared paper) ---------- */

/* ---------- structure notes: visible only in the preview with notes switched on ---------- */
.structure-note { display: none; }
:root[data-structure-notes] .structure-note { display: block; margin: 16px 0; padding: 10px 14px; border: 1px dashed #7a5c2a; border-radius: 10px; background: #fff6e2e6; color: #4a3a12; font: 13px/1.7 'AM TC', 'Microsoft JhengHei', sans-serif; }
:root[data-structure-notes] [data-slot] { outline: 1px dashed #7a5c2a66; outline-offset: 6px; }

/* ---------- forms (ask flow) ---------- */
.shell-progress { list-style: none; margin: 0 0 28px; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 18px; }
.shell-progress li { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--shell-muted); }
.shell-progress li span { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; font-size: 13px; border: 1px solid var(--shell-card-border); }
.shell-progress li[aria-current] { color: var(--shell-ink); font-weight: 600; }
.shell-progress li[aria-current] span { background: var(--shell-forest); color: #fffaf0; border-color: var(--shell-forest); }
.shell-progress li.is-done span { background: #ba864540; border-color: #ba8645; }
.shell-form { max-width: var(--shell-reading); }
.shell-panel { padding: clamp(22px, 3vw, 36px); }
.shell-choices { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(200px, 100%), 1fr)); gap: 12px; margin: 18px 0 0; padding: 0; border: 0; }
.shell-choice { position: relative; display: flex; flex-direction: column; gap: 2px; min-height: 84px; padding: 14px 16px; border: 1px solid var(--shell-card-border); border-radius: 14px; background: #fffdf7; cursor: pointer; }
.shell-choice input { position: absolute; opacity: 0; pointer-events: none; }
.shell-choice strong { font-size: 16px; }
.shell-choice small { font-size: 14px; color: var(--shell-body); }
.shell-choice:has(input:checked) { border-color: var(--shell-forest); box-shadow: inset 0 0 0 1px var(--shell-forest); background: #eef1e6; }
.shell-choice:has(input:focus-visible) { outline: 2px solid #42694c; outline-offset: 3px; }
.shell-field { margin: 0 0 22px; }
.shell-field label { display: block; font-weight: 600; margin-bottom: 4px; }
.shell-field .hint { margin: 0 0 8px; font-size: 14px; color: var(--shell-muted); }
.shell-field :is(input[type=text], input[type=email], textarea) { width: 100%; min-height: 48px; padding: 11px 13px; border: 1px solid #91a28c; border-radius: 10px; background: #fffef9; font: inherit; color: var(--shell-ink); }
.shell-field textarea { min-height: 120px; resize: vertical; }
.shell-field [aria-invalid=true] { border: 2px solid #973d35; }
.shell-error { margin: 6px 0 0; font-size: 14px; color: #973d35; }
.shell-check { display: flex; gap: 12px; align-items: flex-start; margin: 0 0 14px; font-size: 15px; line-height: 1.7; }
.shell-check input { width: 20px; height: 20px; margin-top: 4px; flex: none; accent-color: var(--shell-forest); }
.shell-review { margin: 0 0 24px; border-top: 1px solid var(--shell-line); }
.shell-review div { display: grid; grid-template-columns: 9em 1fr; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--shell-line); }
.shell-review dt { color: var(--shell-muted); font-size: 14px; }
.shell-review dd { margin: 0; white-space: pre-wrap; }
.shell-form-actions { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 14px; margin-top: 26px; }
.shell-button { min-height: 48px; padding: 10px 22px; border-radius: 999px; border: 1px solid #a5947280; background: transparent; font-size: 15px; color: var(--shell-ink); }
.shell-button:hover { background: #fffaf0; }
.shell-button[disabled] { opacity: .5; cursor: not-allowed; }
@media (max-width: 600px) { .shell-review div { grid-template-columns: 1fr; gap: 2px; } }

/* ---------- motion (spec: rise once on entry; no loops) ---------- */
@keyframes shell-rise { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
.shell-hero > * { animation: shell-rise 280ms cubic-bezier(.2,.7,.2,1) both; }
.shell-hero > :nth-child(2) { animation-delay: 60ms; } .shell-hero > :nth-child(n+3) { animation-delay: 120ms; }
.shell-panel[data-entering] { animation: shell-rise 320ms cubic-bezier(.2,.7,.2,1) both; }
@media (prefers-reduced-motion: reduce) { .shell-hero > *, .shell-panel[data-entering] { animation: none; } }

/* ---------- page components ---------- */
.visually-hidden { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.shell-list { margin: 10px 0 0; padding-left: 1.2em; display: flex; flex-direction: column; gap: 8px; }
.shell-list li { line-height: 1.75; color: var(--shell-body); }
.shell-cta { text-align: left; }
.shell-cta .shell-actions { margin-top: 18px; }
.shell-notice { max-width: 760px; margin: 0 0 32px; padding: 14px 18px; border-left: 3px solid #ba8645; border-radius: 0 10px 10px 0; background: #fff6e2d9; color: #3f3418; font-size: 15px; line-height: 1.75; }
.shell-placeholder { padding: 12px 16px; border: 1px dashed #a58e54; border-radius: 10px; background: #fff6e2b3; color: #5c4a22; font-size: 15px; }
.shell-price { margin: 4px 0 10px; font-family: var(--shell-title-serif); font-size: 34px; color: var(--shell-ink); }
.shell-quote { margin: 0; }
.shell-quote blockquote { margin: 6px 0 0; font-size: 16px; line-height: 1.8; color: var(--shell-ink); }
.shell-faq details { border-bottom: 1px solid var(--shell-line); }
.shell-faq summary { min-height: 52px; padding: 14px 0; cursor: pointer; font-weight: 600; line-height: 1.6; }
.shell-faq details p { margin: 0 0 18px; max-width: 42em; }
.shell-thumbs { list-style: none; margin: 22px 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(150px, 44%), 1fr)); gap: 16px; }
.shell-thumb { display: block; width: 100%; padding: 0; border: 1px solid var(--shell-card-border); border-radius: 6px; background: #fffdf7; box-shadow: 0 6px 16px #4b3c2214; transition: transform 220ms ease, box-shadow 220ms ease; }
.shell-thumb img { display: block; width: 100%; height: auto; border-radius: 6px; }
@media (hover: hover) { .shell-thumb:hover { transform: translateY(-3px); box-shadow: 0 10px 22px #4b3c2222; } }
@media (prefers-reduced-motion: reduce) { .shell-thumb { transition: none; } }
.shell-defs { margin: 22px 0 0; }
.shell-tag dt { font-weight: 600; color: var(--tag, var(--shell-ink)); }
.shell-tag dd { margin: 6px 0 0; font-size: 15px; line-height: 1.75; color: var(--shell-body); }
.shell-tag { border-top: 3px solid var(--tag, #ad925d); }
.tag-fact { --tag: #46594f; } .tag-calc { --tag: #6b5120; } .tag-system { --tag: #335c64; } .tag-prompt { --tag: #80524a; } .tag-advice { --tag: #2f5a45; }
.shell-scope { margin: 0; }
.shell-scope figcaption { font-weight: 600; margin-bottom: 8px; }
.shell-scope dl { margin: 0; }
.shell-scope dl > div { display: grid; grid-template-columns: 7.5em 1fr; gap: 12px; padding: 10px 0; border-top: 1px solid var(--shell-line); }
.shell-scope dt { font-size: 14px; font-weight: 600; color: var(--shell-muted); }
.shell-scope dd { margin: 0; display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 15px; }
@media (max-width: 600px) { .shell-scope dl > div { grid-template-columns: 1fr; gap: 2px; } }
.shell-legal { max-width: 760px; font-family: 'AM Sans', Arial, sans-serif; }
.shell-legal h2 { font-size: 20px !important; margin: 40px 0 10px !important; }
.shell-legal h2:first-child { margin-top: 0 !important; }
.shell-legal p, .shell-legal li { font-size: 16px; line-height: 1.8; }
.shell-legal .tbd { background: #f3e3b8; color: #4a3a12; padding: 0 .12em; border-radius: 2px; box-decoration-break: clone; -webkit-box-decoration-break: clone; }
.shell-chip-link { display: inline-flex; align-items: center; min-height: 44px; padding: 6px 16px; border: 1px solid var(--shell-card-border); border-radius: 999px; background: #fffaf080; text-decoration: none; font-size: 14px; color: var(--shell-ink); }
.shell-chip-link[aria-current] { background: var(--shell-forest); border-color: var(--shell-forest); color: #fffaf0; font-weight: 600; }
.shell-tabs, .shell-state { margin-top: 22px; }
.shell-stages { list-style: none; margin: 0; padding: 0; max-width: 560px; }
.shell-stages li { position: relative; display: flex; align-items: center; gap: 14px; min-height: 52px; padding-left: 2px; color: var(--shell-muted); }
.shell-stages li span { width: 20px; height: 20px; flex: none; border-radius: 50%; border: 1px solid #a5947280; background: transparent; }
.shell-stages li.is-done { color: var(--shell-ink); }
.shell-stages li.is-done span { background: #ba8645; border-color: #ba8645; }
.shell-stages li.is-current { color: var(--shell-ink); font-weight: 600; }
.shell-stages li.is-current span { background: #f0d79e; border-color: #ba8645; box-shadow: 0 0 0 6px #f0d79e40; animation: shell-breathe 2.4s ease-in-out infinite; }
@keyframes shell-breathe { 50% { box-shadow: 0 0 0 10px #f0d79e18; } }
@media (prefers-reduced-motion: reduce) { .shell-stages li.is-current span { animation: none; } }
.shell-flow { list-style: none; margin: 18px 0 0; padding: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 10px; counter-reset: flow; }
.shell-flow li { counter-increment: flow; display: inline-flex; align-items: center; gap: 8px; padding: 10px 16px; border-radius: 999px; border: 1px solid var(--shell-card-border); background: var(--shell-card); font-size: 15px; }
.shell-flow li::before { content: counter(flow); font-size: 13px; font-weight: 600; color: var(--shell-accent); }
.shell-flow li + li { position: relative; margin-left: 18px; }
.shell-flow li + li::after { content: '→'; position: absolute; left: -22px; color: var(--shell-muted); }

/* ---------- logo K1 (Kevin 2026-11-18): the wordmark replaces the old symbol and serif name in header and footer ---------- */
.brand img.brand-wordmark { width: auto; height: 32px; }
.home-footer .brand img.brand-wordmark { width: auto; height: 28px; }
@media (max-width: 1100px) { .brand img.brand-wordmark { height: 28px; } }
@media (max-width: 540px) { .brand img.brand-wordmark { height: 24px; } .home-footer .brand img.brand-wordmark { height: 26px; } }
@media (max-width: 370px) { .brand img.brand-wordmark { height: 21px; } }
