/* Layout: a working dictionary of the gem and jewellery trade. Search or filter by subject; terms that name a part of
   a diamond, a ring or a pearl light it up on an anatomy drawing; every term links to the JewelLoop page that shows it
   in use. Definitions are our own wording, checked against the sources listed per subject. */
: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: 22px; }
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, input:focus-visible, [tabindex]:focus-visible { outline: 2px solid var(--ruby); outline-offset: 2px; }
.bar { display: grid; gap: 10px; position: sticky; top: 0; background: var(--paper); z-index: 2; padding: 10px 0; border-bottom: 1px solid var(--rule); }
.bar input { font: 500 16px var(--font-body); color: var(--ink); background: var(--paper); border: 1px solid var(--ink); padding: 10px 12px; width: 100%; border-radius: 0; }
.seg { display: flex; flex-wrap: wrap; gap: 6px; }
.seg button { font: 600 13px var(--font-body); border: 1px solid var(--ink); background: var(--paper); color: var(--ink); padding: 5px 10px; cursor: pointer; }
.seg button[aria-pressed="true"] { background: var(--ink); color: var(--paper); }
.seg button span { font-weight: 400; opacity: .7; margin-left: 4px; }
.az { display: flex; flex-wrap: wrap; gap: 2px; }
.az button { font: 600 12px var(--font-data); width: 26px; height: 26px; border: 1px solid var(--rule); background: var(--paper); color: var(--ink); cursor: pointer; padding: 0; }
.az button:disabled { opacity: .3; cursor: default; }
.layout { display: grid; gap: 22px; grid-template-columns: minmax(0, 1fr) minmax(0, 360px); align-items: start; }
.layout.noplates { grid-template-columns: minmax(0, 1fr); } .layout.noplates .plates { display: none; } /* owner feedback 2026-10-19: no drawing beside lists that have no drawn terms */
.plates .ptitle { margin: 0 0 8px; font-weight: 600; font-size: 14px; } .plates .phelp { margin: 0 0 10px; }
@media (max-width: 920px) { .layout { grid-template-columns: 1fr; } .plates { position: static !important; } .bar { position: static; } .plate { max-width: 560px; width: 100%; justify-self: center; } }
.list { display: grid; gap: 0; }
.letter { font-family: var(--font-display); font-size: 30px; color: var(--gold); border-bottom: 1px solid var(--rule); margin: 14px 0 0; scroll-margin-top: 150px; }
.term { display: grid; gap: 3px; padding: 10px 6px; border-bottom: 1px solid var(--rule); scroll-margin-top: 150px; }
.term:target, .term.on { background: var(--mist); }
.term h3 { margin: 0; font-family: var(--font-display); font-weight: 500; font-size: 21px; display: flex; flex-wrap: wrap; gap: 8px; align-items: baseline; }
.term h3 small { font: 600 12px var(--font-body); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.term p { margin: 0; color: var(--ink-soft); font-size: 14.5px; }
.term .meta { display: flex; flex-wrap: wrap; gap: 10px; font-size: 12.5px; }
.term .meta a { font-weight: 600; }
.term .meta button { font: 600 12px var(--font-body); border: 1px solid var(--gold); background: none; color: var(--ink); padding: 1px 8px; cursor: pointer; }
.empty { padding: 20px 6px; color: var(--muted); }
.plates { position: sticky; top: 160px; display: grid; gap: 10px; }
.plate { border: 1px solid var(--rule); padding: 10px; display: grid; gap: 8px; }
.plate svg.off { display: none; }
.plate .seg button { font-size: 12px; padding: 4px 8px; }
.plate svg { width: 100%; height: auto; display: block; overflow: visible; }
.plate .pt { cursor: pointer; stroke: #5a7896; stroke-width: 1; transition: fill .2s, stroke .2s; }
.plate #p-ring .pt, .plate #p-pearl .pt { stroke: #8a8070; }
.plate .facet { stroke: #6f8aa6; stroke-width: .7; fill: none; opacity: .75; pointer-events: none; }
.plate .outline { stroke: #5a7896; stroke-width: 1.3; fill: none; pointer-events: none; }
.plate #p-pearl .outline { stroke: #a8987a; }
.plate .rings path { fill: none; stroke: #b9a888; stroke-width: .8; pointer-events: none; }
.plate .cut { fill: none; stroke: #a8987a; stroke-width: .8; opacity: .7; pointer-events: none; }
.plate .guide { stroke: var(--muted); stroke-dasharray: 2 3; stroke-width: .8; }
.plate .dim { stroke: var(--muted) !important; stroke-width: 1.2; }
.plate .dimtick { stroke: var(--muted); stroke-width: 1.2; }
.plate .lead { stroke: var(--muted); stroke-width: .8; }
.plate .dot { fill: var(--muted); }
.plate .lbl { font: 500 12px var(--font-body); fill: var(--ink-soft); cursor: pointer; }
.plate .cap { font: 400 12px var(--font-body); fill: var(--muted); }
.plate .pt.hl { fill: rgba(155, 27, 48, .32); stroke: var(--ruby) !important; stroke-width: 2.2; }
.plate path.pt.hl[fill="none"], .plate line.pt.hl, .plate rect.pt.hl[fill="none"], .plate circle.pt.hl[fill="none"] { fill: none; stroke-width: 3.4; }
.plate .lead.hl { stroke: var(--ruby); stroke-width: 1.4; }
.plate .dot.hl { fill: var(--ruby); }
.plate .lbl.hl { fill: var(--ruby); font-weight: 700; }
.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; }
