@layer reset, base, layout, components, responsive;
@layer reset {
  *, *::before, *::after { box-sizing: border-box; }
  body, h1, h2, h3, h4, p, pre { margin: 0; }
  button, input { font: inherit; color: inherit; }
  button, label:has(input), summary { cursor: pointer; }svg { display: block; }
  [hidden] { display: none !important; }
  :where(a, button, input, pre, summary):focus-visible { outline: 3px solid #7771d8; outline-offset: 4px; }
}
@layer base {
  :root { color-scheme: light; font: 16px/1.75 "Avenir Next", "Hiragino Kaku Gothic ProN", "Yu Gothic", sans-serif; color: #203d33; background: #f4f3ec; --ink: #203d33; --muted: #617367; --green: #007967; --line: #ccd5c9; --paper: #fffef8; --lime: #c5ff80; }
  body { min-width: 320px; background: radial-gradient(ellipse at 95% 0, #dddcef70, transparent 28%); }
  code, pre { font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace; }:not(pre) > code { font-size: .9em; }
  h1 { font-size: clamp(36px, 4.5vw, 68px); line-height: 1.2; letter-spacing: 0; font-weight: 800; margin: 23px 0 20px; }h1 > span { color: var(--green); }
  h2 { font-size: clamp(22px, 2.2vw, 30px); line-height: 1.5; }h3 { font-size: 18px; line-height: 1.5; }
  a { color: var(--green); text-underline-offset: 4px; }a:hover { text-decoration-thickness: 2px; }
  .page { width: min(1560px, calc(100% - 80px)); margin-inline: auto; }.hero { padding: 38px 0 28px; }
  .eyebrow, .kicker { color: var(--green); font-size: 12px; letter-spacing: .1em; font-weight: 750; }.kicker { margin-bottom: 5px; }.eyebrow { display: flex; align-items: center; gap: 12px; }
  .brand-mark { display: grid; place-items: center; width: 34px; height: 34px; border: 1px solid var(--ink); border-radius: 10px; background: var(--lime); }.brand-mark svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; }
  .lead { max-width: 1140px; }.support-row { display: flex; flex-wrap: wrap; align-items: center; gap: 9px 12px; margin-top: 22px; font-size: 12px; color: var(--muted); }
  .support-badge { border: 1px solid var(--line); border-radius: 30px; padding: 5px 11px; background: var(--paper); }.support-badge[data-supported=true] { color: #006652; border-color: #a2bca8; background: #edf5e9; }.support-badge[data-supported=false] { color: #994614; border-color: #dcbda8; background: #fff3e6; }
  .notice { border-left: 3px solid #aa551b; background: #fff1dc; padding: 14px 18px; margin-top: 18px; font-size: 14px; }
  .icon-defs, .sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
}
@layer layout {
  .panel { border: 1px solid var(--line); border-radius: 23px; overflow: clip; background: var(--paper); }.panel-heading { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 24px 28px; border-bottom: 1px solid var(--line); }
  .lab-layout { display: grid; grid-template-columns: 260px minmax(0, 1fr); }.controls { min-width: 0; padding: 23px; background: #f5f7ee; border-right: 1px solid var(--line); }
  fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }legend { font-size: 14px; font-weight: 750; margin-bottom: 10px; }
  .range-control, .color-control { margin-top: 21px; padding-top: 19px; border-top: 1px solid var(--line); }.range-control > label { display: flex; justify-content: space-between; gap: 10px; margin-bottom: 8px; font-size: 13px; font-weight: 750; }.range-control output { color: var(--green); font-family: "SFMono-Regular", Consolas, monospace; }.range-control p { color: var(--muted); font-size: 11px; margin-top: 5px; }
  input[type=range] { display: block; margin: 0; width: 100%; min-height: 24px; accent-color: var(--green); cursor: ew-resize; }
  .color-control > label { font-size: 13px; font-weight: 750; }.color-control > div { display: flex; align-items: center; gap: 12px; margin-top: 8px; }.color-control output { font: 700 13px/1.6 "SFMono-Regular", Consolas, monospace; color: var(--green); }input[type=color] { width: 42px; height: 34px; padding: 2px; border: 1px solid #b6c3af; border-radius: 6px; background: var(--paper); cursor: pointer; }
  .check-controls { display: grid; gap: 12px; margin-top: 21px; padding-top: 19px; border-top: 1px solid var(--line); }.check-controls label { display: flex; align-items: center; gap: 9px; font-size: 12px; }input[type=checkbox] { accent-color: var(--green); width: 17px; height: 17px; flex-shrink: 0; margin: 0; }
  .comparison { padding: 23px 26px; min-width: 0; container: comparison / inline-size; background: #e8ede4; background-image: linear-gradient(#c9d6c54a 1px, transparent 1px), linear-gradient(90deg, #c9d6c54a 1px, transparent 1px); background-size: 22px 22px; }
  .comparison-intro { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 9px 18px; margin-bottom: 20px; font-size: 12px; color: var(--muted); }.guide-key { display: flex; align-items: center; gap: 7px; font-size: 10px; }.guide-key i { width: 13px; height: 10px; border: 1px dashed #776397; }
  .preview-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }.specimen { min-width: 0; border: 1px solid #bfccba; border-radius: 15px; background: #fffef8d9; overflow: clip; }.specimen > header { padding: 17px 19px; min-height: 89px; border-bottom: 1px solid var(--line); }.specimen-label { font-size: 12px; color: var(--muted); font-weight: 700; }.specimen h3 { font-size: 20px; margin-top: 4px; }
  .native-specimen { border-color: #739e83; }.native-specimen > header { background: #e4f0dc; }.native-specimen h3 { color: var(--green); }
  .sample-stage { min-height: 336px; padding: 35px 26px; display: grid; place-items: center; background: #fffef866; }
  .shape-shell { position: relative; }.shape-shell::after { content: ""; display: none; pointer-events: none; position: absolute; inset: 0; outline: 1px dashed #776397; outline-offset: 0; z-index: 2; }.show-bounds .shape-shell::after { display: block; }
  .shape-card { display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center; color: #203d33; gap: 5px; }
  .shape-kicker { font-size: 10px; line-height: 1.4; letter-spacing: .1em; font-weight: 750; }.shape-title { font-size: 20px; line-height: 1.3; font-weight: 800; }.shape-caption { font-size: 10px; line-height: 1.5; letter-spacing: .03em; }
  .measurement { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; padding: 12px 18px; border-top: 1px solid var(--line); background: var(--paper); font-size: 12px; color: var(--muted); }.measurement output { color: var(--green); font: 700 13px/1.6 "SFMono-Regular", Consolas, monospace; }
  .comparison-notes { margin-top: 22px; display: grid; gap: 10px; padding: 20px; background: #fffef8d9; border: 1px solid #bfccba; border-radius: 12px; font-size: 13px; color: var(--muted); }.comparison-notes strong { color: var(--ink); }
  .code-section { min-width: 0; background: #172d25; color: #e9f1e5; }.code-heading { padding: 18px 24px; display: flex; align-items: center; justify-content: space-between; gap: 18px; border-bottom: 1px solid #ffffff1d; }.code-heading .kicker { color: #a7c4ac; }.code-heading h3 { font-size: 17px; color: #f5f6ec; }
  pre { font-size: 13px; line-height: 1.85; tab-size: 2; padding: 22px 24px; overflow: auto; white-space: pre-wrap; overflow-wrap: anywhere; }.code-section > pre { max-height: 410px; }.code-note { padding: 14px 24px; font-size: 13px; border-top: 1px solid #ffffff1d; color: #b9cdbd; overflow-wrap: anywhere; }
  .mode-panel { margin-top: 38px; }.mode-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }.mode-grid > article { min-width: 0; padding: 25px 28px; }.mode-grid > article + article { border-left: 1px solid var(--line); }.mode-label { font-size: 12px; font-weight: 750; color: var(--green); }.mode-grid h3 { margin-top: 7px; font-size: 20px; }.mode-stage { display: grid; place-items: center; min-height: 240px; padding: 20px; }.mode-sample { display: grid; place-items: center; color: #443352; font-size: 16px; font-weight: 750; }.mode-grid article > p { font-size: 14px; color: var(--muted); }
  .code-details { padding: 18px 28px; border-top: 1px solid var(--line); background: #f7f8f0; }.code-details summary { font-size: 14px; font-weight: 700; }.detail-toolbar { margin-top: 17px; }.code-details pre { margin-top: 17px; background: #172d25; color: #e9f1e5; border-radius: 12px; }.code-details > p { font-size: 13px; color: var(--muted); margin-top: 14px; }
  .notes-section { padding: 38px 0; }.section-heading { margin-bottom: 22px; }.notes-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }.notes-grid article { min-width: 0; padding: 25px; border: 1px solid var(--line); border-radius: 17px; background: #fffef8b0; }.note-mark { font: 750 11px/1.5 "SFMono-Regular", Consolas, monospace; color: var(--green); letter-spacing: .04em; }.notes-grid h3 { margin: 12px 0; }.notes-grid p { font-size: 14px; color: var(--muted); }
  .compatibility { border: 1px solid var(--line); border-radius: 18px; padding: 27px 28px; background: #e7ede1; }.compatibility h2 { font-size: 24px; }.compatibility > p:not(.kicker) { font-size: 14px; margin: 15px 0; max-width: 1100px; }.compatibility nav { display: flex; gap: 12px 25px; flex-wrap: wrap; font-size: 14px; margin-top: 22px; }.page-footer { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 20px; color: var(--muted); font-size: 12px; padding: 26px 0 35px; }
}
@layer components {
  .shape-choices { display: grid; position: relative; isolation: isolate; gap: 5px; anchor-scope: --shape-choice; }
  .shape-choices::before { content: ""; position: absolute; z-index: -1; position-anchor: --shape-choice; left: anchor(left); top: anchor(top); width: anchor-size(width); height: anchor-size(height); background: var(--ink); border: 1px solid var(--ink); border-radius: 10px; transition: left .18s, top .18s; pointer-events: none; }
  .shape-choices label { display: grid; position: relative; grid-template-columns: 34px minmax(0, 1fr); align-items: center; gap: 11px; padding: 10px 12px; min-height: 62px; border: 1px solid var(--line); border-radius: 10px; background: #fffef855; font-size: 14px; }
  .shape-choices input { appearance: none; position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; border-radius: 10px; cursor: pointer; }.shape-choices label > span { pointer-events: none; }.shape-choices strong { display: block; font-size: 14px; font-weight: 750; }.shape-choices small { font: 11px/1.5 "SFMono-Regular", Consolas, monospace; color: var(--muted); display: block; margin-top: 2px; }
  .shape-choices label:has(input:checked) { anchor-name: --shape-choice; color: var(--lime); border-color: transparent; background: transparent; }.shape-choices label:has(input:checked) small { color: #c5d6c6; }.shape-choices label:hover { border-color: #91b594; }.shape-choices label:has(input:focus-visible) { outline: 3px solid #7771d8; outline-offset: 2px; }.shape-choices input:focus-visible { outline: none; }
  .shape-thumb { display: block; width: 32px; height: 25px; background: currentColor; clip-path: var(--thumb, polygon(25% 0, 75% 0, 100% 50%, 75% 100%, 25% 100%, 0 50%)); opacity: .8; }
  :disabled { cursor: not-allowed !important; }fieldset:disabled, label:has(input:disabled) { opacity: .55; }
  .copy-button, .plain-button { display: inline-flex; align-items: center; justify-content: center; gap: 7px; flex-shrink: 0; padding: 8px 12px; min-height: 38px; border: 1px solid #bdcbb8; border-radius: 8px; font-size: 13px; color: var(--ink); background: var(--paper); font-weight: 750; transition: background .18s; }.copy-button:hover, .plain-button:hover { background: #d9f0c5; }.copy-button:active, .plain-button:active { background: #c7e7af; }.copy-button svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
  .token-comment { color: #a2bcaa; }.token-property { color: #bceba4; }.token-value { color: #ffca9f; }.token-function { color: #c9c3ff; }
  .toast { position: fixed; bottom: 24px; left: 50%; transform: translate(-50%, 10px); z-index: 100; max-width: calc(100% - 32px); padding: 12px 19px; border-radius: 11px; background: var(--ink); color: white; font-size: 14px; box-shadow: 0 5px 22px #0002; opacity: 0; visibility: hidden; transition: .2s; }.toast.show { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
}
@layer responsive {
  @container comparison (max-width: 650px) { .preview-grid { gap: 12px; }.specimen > header { padding: 16px 14px; }.specimen-label { font-size: 11px; }.sample-stage { padding: 32px 22px; min-height: 290px; }.measurement { padding: 12px; font-size: 11px; }.measurement output { font-size: 12px; } }
  @container comparison (max-width: 520px) { .preview-grid { grid-template-columns: 1fr; }.specimen > header { min-height: 0; padding: 16px 18px; }.specimen-label { font-size: 12px; }.sample-stage { min-height: 250px; padding: 32px 24px; }.measurement { padding: 12px 18px; font-size: 12px; }.measurement output { font-size: 13px; } }
  @media (max-width: 1100px) { .lab-layout { grid-template-columns: 240px minmax(0, 1fr); }.controls { padding: 20px; }.comparison { padding: 23px 20px; }.notes-grid { gap: 14px; }.notes-grid article { padding: 22px; } }
  @media (max-width: 850px) { .page { width: calc(100% - 32px); }.hero { padding-top: 28px; }.lab-layout { grid-template-columns: 1fr; }.controls { display: grid; grid-template-columns: 1fr 1fr; gap: 21px; border-right: 0; border-bottom: 1px solid var(--line); }.controls > fieldset { grid-column: 1/-1; }.shape-choices { grid-template-columns: repeat(4, minmax(0, 1fr)); }.shape-choices label { grid-template-columns: 1fr; justify-items: center; gap: 7px; padding: 12px 7px; text-align: center; }.range-control,.color-control,.check-controls { border: 0; padding: 0; margin: 0; }.check-controls { align-content: center; }.panel-heading { padding: 22px; }.notes-grid { grid-template-columns: 1fr; } }
  @media (max-width: 520px) { h1 { font-size: clamp(32px, 7.3vw, 42px); }.lead { font-size: 15px; }.panel { border-radius: 17px; }.panel-heading { padding: 20px 18px; flex-wrap: wrap; }h2 { font-size: 22px; }.controls { padding: 20px 18px; gap: 20px 17px; }.shape-choices { grid-template-columns: 1fr 1fr; }.shape-choices label { grid-template-columns: 27px minmax(0, 1fr); text-align: left; justify-items: start; min-height: 62px; padding: 10px; gap: 8px; }.shape-thumb { width: 26px; height: 21px; }.shape-choices strong { font-size: 13px; }.shape-choices small { font-size: 10px; }.range-control label { font-size: 12px; flex-wrap: wrap; gap: 3px 10px; }.color-control > label { font-size: 12px; }.color-control output { font-size: 11px; }.color-control > div { gap: 7px; }.color-control input { width: 34px; }.check-controls { grid-column: 1/-1; }.comparison { padding: 22px 16px; }.comparison-notes { padding: 18px; font-size: 12px; }.code-heading { padding: 18px; flex-wrap: wrap; }.code-heading h3 { font-size: 16px; }pre { font-size: 12px; padding: 18px; }.code-note { padding: 14px 18px; font-size: 12px; }.mode-grid { grid-template-columns: 1fr; }.mode-grid > article { padding: 24px 20px; }.mode-grid > article + article { border-left: 0; border-top: 1px solid var(--line); }.mode-grid h3 { font-size: 18px; }.code-details { padding: 18px 20px; }.mode-stage { min-height: 215px; }.compatibility { padding: 23px 20px; }.compatibility h2 { font-size: 22px; }.page-footer { font-size: 11px; } }
  @supports not (left: anchor(left)) { .shape-choices::before { display: none; }.shape-choices label:has(input:checked) { background: var(--ink); } }
  @media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; } }
}
