/* Layout: the GIA colour description for coloured stones. Pick a hue on the wheel, then tone and saturation on the
   grid; a ray-traced stone and a flat comparator chip show the result, with the written notation (e.g. slpR 6/5). */
:root {
  --paper: #ffffff; --ink: #16161a; --ink-soft: #3d3d45; --muted: #6b6b75; --rule: #e4e2de; --mist: #f4f3f1;
  --ruby: #9b1b30; --gold: #b8892f;
  --font-display: "Newsreader", Georgia, "Times New Roman", serif;
  --font-body: "Instrument Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-data: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;
}

:root[data-theme="dark"] { --paper: #121216; --ink: #f1efe9; --ink-soft: #c9c6bf; --muted: #9a978f; --rule: #2c2c33; --mist: #1b1b21; --ruby: #e0566c; --gold: #e1b25a; color-scheme: dark; }
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { background: var(--paper); color: var(--ink); font-family: var(--font-body); font-size: 15px; line-height: 1.5; margin: 0; }
a { color: var(--ink); text-decoration-color: var(--ruby); text-underline-offset: 3px; }
.wrap { max-width: 1240px; margin: 0 auto; padding-inline: 16px; padding-block: 20px 48px; display: grid; gap: 24px; }
header.top { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 12px; border-bottom: 1px solid var(--ink); padding-bottom: 14px; }
.eyebrow { font-size: 12px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--ruby); display: inline-flex; align-items: center; gap: 10px; }
.eyebrow::before { content: ""; flex: none; width: 4px; height: 15px; background: var(--gold); clip-path: polygon(0 24%, 100% 0, 100% 76%, 0 100%); }
h1 { font-family: var(--font-display); font-weight: 500; font-size: clamp(30px, 4.6vw, 48px); line-height: 1.03; margin: 6px 0 0; }
h2.sec { font-family: var(--font-display); font-weight: 500; font-size: 28px; margin: 0; line-height: 1.1; }
.lede { max-width: 72ch; color: var(--ink-soft); margin: 6px 0 0; }
.prototype { font-size: 12px; color: var(--muted); border: 1px solid var(--rule); padding: 4px 10px; white-space: nowrap; }
.help { font-size: 12.5px; color: var(--muted); margin: 0; }
section.study { border-top: 1px solid var(--ink); padding-top: 18px; display: grid; gap: 14px; }
button:focus-visible, [tabindex]:focus-visible { outline: 2px solid var(--ruby); outline-offset: 2px; }

.lab { display: grid; gap: 20px; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); align-items: start; }
@media (max-width: 900px) { .lab { grid-template-columns: 1fr; } }
.show { display: grid; gap: 12px; }
.stage { position: relative; aspect-ratio: 5 / 4; background: radial-gradient(circle at 50% 40%, #f7f6f2, #d8d6cf 85%); display: grid; place-items: center; }
/* the stone keeps its place while it renders (speed check 2026-10-12) */
.stage img.pending { visibility: hidden; }
.stage img { width: min(50%, 250px); height: auto; aspect-ratio: 1; filter: drop-shadow(0 10px 14px rgba(0,0,0,.18)); }
.stage .chip { position: absolute; right: 14px; bottom: 14px; width: 64px; height: 64px; border: 3px solid #fff; box-shadow: 0 1px 4px rgba(0,0,0,.25); }
.stage .chiplab { position: absolute; right: 14px; bottom: 82px; font: 600 12px var(--font-body); letter-spacing: .06em; text-transform: uppercase; color: #5a5a62; }
.stage .loading { position: absolute; font-size: 12px; color: #6b6b75; }
.code { display: grid; gap: 4px; padding: 12px 14px; background: var(--ink); color: var(--paper); }
.code b { font: 500 34px var(--font-data); letter-spacing: .02em; }
.code span { font-size: 14px; opacity: .85; }
.wheelbox { display: grid; gap: 14px; grid-template-columns: minmax(0, 300px) minmax(0, 1fr); align-items: start; }
@media (max-width: 560px) { .wheelbox { grid-template-columns: 1fr; } }
.wheelbox svg { width: 100%; height: auto; display: block; }
.seg-hue { cursor: pointer; stroke: var(--paper); stroke-width: 1.2; }
.seg-hue.on { stroke: var(--ink); stroke-width: 3; }
.wheel-c { font: 500 30px var(--font-data); fill: var(--ink); }
.wheel-n { font: 500 12px var(--font-body); fill: var(--muted); }
.extra { display: flex; flex-wrap: wrap; gap: 6px; }
.extra button { font: 600 12.5px var(--font-body); border: 1px solid var(--ink); background: var(--paper); color: var(--ink); padding: 5px 10px; cursor: pointer; }
.extra button[aria-pressed="true"] { background: var(--ink); color: var(--paper); }
.grid { display: grid; grid-template-columns: 92px repeat(6, minmax(0, 1fr)); gap: 3px; font-size: 12px; }
.grid .h { color: var(--muted); display: flex; align-items: end; justify-content: center; text-align: center; line-height: 1.15; padding-bottom: 4px; }
.grid .r { color: var(--muted); display: flex; align-items: center; line-height: 1.15; }
.cell { aspect-ratio: 1.25; border: 0; cursor: pointer; padding: 0; }
.cell[aria-pressed="true"] { outline: 3px solid var(--ink); outline-offset: 1px; position: relative; z-index: 1; }
.axis { display: flex; justify-content: space-between; font-size: 12px; color: var(--muted); padding-left: 95px; }
.how { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.how div { border-top: 2px solid var(--gold); padding-top: 8px; font-size: 14px; color: var(--ink-soft); }
.how h3 { font-family: var(--font-display); font-weight: 500; font-size: 20px; margin: 0 0 4px; color: var(--ink); }
table.ref { border-collapse: collapse; width: 100%; font-size: 13.5px; }
.ref th, .ref td { text-align: left; padding: 6px 8px; border-bottom: 1px solid var(--rule); }
.ref th { border-bottom: 1px solid var(--ink); }
.ref td.n { font-family: var(--font-data); font-size: 12.5px; }
.tables { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.sources { display: grid; gap: 6px; font-size: 13px; color: var(--ink-soft); max-width: 92ch; }
.sources p { margin: 0; }
/* jewelloop.net: one column that never grows wider than the screen */
.wrap { grid-template-columns: minmax(0, 1fr); }
.jl-table-scroll { overflow-x: auto; max-width: 100%; }
/* shown once the page's script has run (static/visual/ready.js): no jump while loading */
html:not(.jl-ready) .wrap { visibility: hidden; }

/* On jewelloop.net the page around it shows the title and the introduction. */
header.top { display: none !important; }
