/* Luminastis — foglio di stile unico. */

:root {
  --paper: #f6f1e7;
  --paper-2: #ede5d6;
  --card: #fcf9f3;
  --ink: #15203a;
  --ink-2: #3c4660;
  --muted: #6a7088;
  --line: #ddd3c1;
  --line-2: #c6b9a2;
  --accent: #a3172e;
  --accent-ink: #fff7f2;
  --gold: #9a7417;
  --focus: #1f5fbf;

  --ok: #2f7a4a;
  --maybe: #b07a12;
  --lore: #8a4fa8;

  --display: Didot, "Bodoni 72", "Bodoni MT", "Bodoni Moda", "Libre Bodoni", "Playfair Display", Georgia, serif;
  --serif: Charter, "Bitstream Charter", "Sitka Text", Cambria, Georgia, serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;

  --radius: 6px;
  --wrap: 1200px;
  --narrow: 760px;
  --gutter: clamp(16px, 4vw, 40px);

  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #0f1524;
    --paper-2: #161e31;
    --card: #19223a;
    --ink: #ece6da;
    --ink-2: #c7c3ba;
    --muted: #9a9eb0;
    --line: #2b3550;
    --line-2: #3d4867;
    --accent: #f0788a;
    --accent-ink: #1b0b10;
    --gold: #d9b45a;
    --focus: #8ab4ff;
    --ok: #6cc28c;
    --maybe: #e2b14f;
    --lore: #c193dc;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.1rem;
  line-height: 1.6;
  text-rendering: optimizeLegibility;
}

img, svg { display: block; max-width: 100%; height: auto; }

a { color: inherit; text-decoration-color: var(--line-2); text-underline-offset: 0.18em; text-decoration-thickness: 1px; }
a:hover { color: var(--accent); text-decoration-color: currentColor; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 3px; }

h1, h2, h3 { line-height: 1.12; font-weight: 600; text-wrap: balance; }
h1, h2 { font-family: var(--display); font-weight: 700; letter-spacing: -0.005em; }
h1 { font-size: clamp(2.2rem, 5vw, 3.6rem); margin: 0.15em 0 0.35em; }
h3 { font-family: var(--serif); }

.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }
.wrap.narrow, .narrow { max-width: calc(var(--narrow) + 2 * var(--gutter)); }
.narrow-wide { max-width: calc(980px + 2 * var(--gutter)); }

.mono { font-family: var(--mono); font-size: 0.9em; letter-spacing: 0.02em; }
.muted { color: var(--muted); }
.sr-only { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.skip {
  position: absolute; left: 12px; top: -60px; z-index: 20;
  background: var(--ink); color: var(--paper); padding: 8px 14px; border-radius: 6px;
  font-family: var(--sans); font-size: 0.95rem;
}
.skip:focus { top: 12px; }

/* Testata */

.site-header { border-bottom: 1px solid var(--line); background: var(--paper); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 78px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.brand:hover { color: inherit; }
.brand-mark { width: 36px; height: 36px; color: var(--accent); flex: none; }
.brand-text { display: flex; flex-direction: column; line-height: 1.05; }
.brand-name { font-family: var(--display); font-size: 1.6rem; font-weight: 700; letter-spacing: 0.02em; }
.brand-tag { font-family: var(--sans); font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.16em; color: var(--muted); margin-top: 4px; }

.main-nav ul { display: flex; gap: 2px; list-style: none; margin: 0; padding: 0; }
.main-nav a {
  display: block; padding: 8px 11px; border-radius: 999px;
  font-family: var(--sans); font-size: 0.93rem; text-decoration: none; color: var(--ink-2);
}
.main-nav a:hover { background: var(--paper-2); color: var(--ink); }
.main-nav a[aria-current="page"] { color: var(--ink); background: var(--paper-2); box-shadow: inset 0 0 0 1px var(--line); }

@media (max-width: 920px) {
  .header-inner { flex-direction: column; align-items: stretch; gap: 6px; padding-block: 14px 8px; }
  .main-nav { margin-inline: calc(-1 * var(--gutter)); overflow-x: auto; scrollbar-width: none; }
  .main-nav::-webkit-scrollbar { display: none; }
  .main-nav ul { padding-inline: calc(var(--gutter) - 11px); width: max-content; }
}

/* Elementi comuni */

.kicker {
  font-family: var(--sans); font-size: 0.76rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.14em; color: var(--accent); margin: 0;
}
.kicker a { text-decoration: none; }

.lead-summary { font-size: 1.24rem; color: var(--ink-2); max-width: 62ch; margin: 0 0 1em; }

.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; flex-wrap: wrap; border-top: 2px solid var(--ink); padding-top: 14px; margin-bottom: 22px; }
.section-title { font-size: clamp(1.5rem, 2.6vw, 1.9rem); margin: 0; }
.section-head .section-title { flex: 1; }
section > .section-title { border-top: 2px solid var(--ink); padding-top: 14px; margin-bottom: 20px; }
.more { font-family: var(--sans); font-size: 0.92rem; font-weight: 600; text-decoration: none; color: var(--accent); }
.more::after { content: " →"; }

.block { margin-block: clamp(48px, 7vw, 88px); }
.page-head { padding-block: 28px 12px; }

.button {
  display: inline-block; padding: 12px 22px; border-radius: 999px;
  background: var(--ink); color: var(--paper); text-decoration: none; cursor: pointer;
  font-family: var(--sans); font-weight: 600; font-size: 0.98rem; border: 1px solid var(--ink);
}
.button:hover { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.button--ghost { background: transparent; color: var(--ink); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }

.crumbs ol { display: flex; flex-wrap: wrap; gap: 4px 0; list-style: none; margin: 0 0 18px; padding: 0; font-family: var(--sans); font-size: 0.85rem; color: var(--muted); }
.crumbs li + li::before { content: "/"; margin-inline: 8px; color: var(--line-2); }
.crumbs a { text-decoration: none; }
.crumbs [aria-current] { color: var(--ink-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 36ch; }
@media (max-width: 600px) {
  .crumbs [aria-current] { display: none; }
  .brand-tag { display: none; }
}

.figure-note { font-family: var(--sans); font-size: 0.85rem; color: var(--muted); margin: 12px 0 0; }

/* Tessere dei simboli: ogni stile ha il suo fondo, uguale in tema chiaro e scuro */

/* Il margine interno sta sull'SVG: un padding in % dipenderebbe dalla larghezza del contenitore, non della tessera. */
.tile { --inset: 72%; aspect-ratio: 1; border-radius: 4px; display: grid; place-items: center; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.08); }
.tile .glyph { width: var(--inset); height: var(--inset); }
.tile--incisione { background: #efe6d1 radial-gradient(circle at 30% 20%, #f7f0de, #e8dcc2 80%); }
.tile--smalto { background: #fffaf0 linear-gradient(180deg, #fffdf7, #f5ecd9); }
.tile--digitale { background: #1b2647 radial-gradient(circle at 50% 35%, #33467d, #141c36 75%); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08); }
.tile--xl { --inset: 76%; border-radius: 6px; }

.glyph-row { display: flex; flex-wrap: wrap; gap: 10px; }
.glyph-row .tile { width: 92px; }

/* Home */

.home-hero { border-bottom: 1px solid var(--line); background:
  radial-gradient(900px 420px at 88% 10%, color-mix(in srgb, var(--gold) 14%, transparent), transparent 70%); }
.home-hero-grid { display: grid; grid-template-columns: 1.2fr 0.8fr; gap: clamp(28px, 5vw, 80px); align-items: center; padding-block: clamp(40px, 7vw, 96px); }
.home-hero h1 { font-size: clamp(2.6rem, 6vw, 4.6rem); max-width: 13ch; }

.hero-plate { margin: 0; justify-self: center; width: 100%; max-width: 360px; }
.hero-main { padding: 16px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 1px 0 var(--line), 0 18px 40px -24px rgba(20, 20, 40, 0.45); }
.hero-evo { list-style: none; margin: 14px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; counter-reset: evo; }
.hero-evo li { display: grid; gap: 6px; font-family: var(--sans); font-size: 0.76rem; text-transform: uppercase; letter-spacing: 0.12em; color: var(--muted); text-align: center; }
.hero-plate figcaption { font-family: var(--sans); font-size: 0.85rem; color: var(--muted); margin-top: 14px; line-height: 1.45; }
@media (max-width: 800px) {
  .home-hero-grid { grid-template-columns: 1fr; }
  .hero-plate { max-width: 300px; justify-self: start; }
}

.entries { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.entry {
  display: flex; flex-direction: column; gap: 6px; padding: 20px 20px 22px; text-decoration: none;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
}
.entry:hover { border-color: var(--ink); color: inherit; }
.entry-art { display: flex; gap: 6px; margin-bottom: 10px; }
.entry-art svg { width: 44px; height: 44px; background: #efe6d1; border-radius: 4px; padding: 5px; }
.entry-title { font-family: var(--display); font-size: 1.4rem; font-weight: 700; line-height: 1.15; }
.entry-text { color: var(--ink-2); font-size: 0.98rem; line-height: 1.45; }
@media (max-width: 960px) { .entries { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .entries { grid-template-columns: 1fr; } }

.tl-strip { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(5, 1fr); gap: 18px; }
.tl-strip li { border-top: 3px solid var(--accent); padding-top: 12px; display: flex; flex-direction: column; gap: 4px; font-size: 1rem; line-height: 1.35; }
.tl-strip .tl-year { font-family: var(--mono); font-size: 1.05rem; }
@media (max-width: 960px) { .tl-strip { grid-template-columns: 1fr 1fr; } }
@media (max-width: 480px) { .tl-strip { grid-template-columns: 1fr; } }

.callout { background: var(--paper-2); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(24px, 4vw, 44px); max-width: calc(var(--wrap) - 2 * var(--gutter)); }
.callout h2 { margin-top: 0; font-size: 1.8rem; }
.method { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; margin-block: 18px; }
.method h3 { font-size: 1.15rem; margin: 0 0 6px; display: flex; align-items: center; gap: 8px; }
.method p { margin: 0; color: var(--ink-2); font-size: 1rem; }
@media (max-width: 760px) { .method { grid-template-columns: 1fr; } }
@media (max-width: 1280px) { .callout { margin-inline: var(--gutter); width: auto; } }

.note-block { max-width: calc(var(--narrow) + 2 * var(--gutter)); text-align: center; }
.note-block h2 { font-size: 1.5rem; margin: 0 0 8px; }
.note-block p { color: var(--ink-2); margin: 0 auto; max-width: 60ch; }

/* Livelli di affidabilità */

.claim-dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; background: var(--muted); flex: none; }
.method-documentato .claim-dot, .claims-group--documentato .claim-dot, .legend-item--documentato .claim-dot, .tl-item--documentato::before { background: var(--ok); }
.method-probabile .claim-dot, .claims-group--probabile .claim-dot, .legend-item--probabile .claim-dot, .tl-item--probabile::before { background: var(--maybe); }
.method-tradizione .claim-dot, .claims-group--tradizione .claim-dot, .legend-item--tradizione .claim-dot, .tl-item--tradizione::before { background: var(--lore); }

.doc-badge { display: inline-block; font-family: var(--sans); font-size: 0.74rem; font-weight: 600; letter-spacing: 0.02em; padding: 3px 9px; border-radius: 999px; border: 1px solid currentColor; margin: 0; line-height: 1.4; }
.doc-badge--documentata { color: var(--ok); }
.doc-badge--parziale { color: var(--maybe); }
.doc-badge--tradizione { color: var(--lore); }

/* Schede nel catalogo */

.grid { display: grid; gap: 20px; }
.grid--cards { grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); }
.grid--specimens { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }

.specimen { position: relative; display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.specimen:hover { border-color: var(--line-2); }
.specimen:hover .tile .glyph { transform: scale(1.04); }
.specimen > .tile { --inset: 56%; border-radius: 0; box-shadow: none; border-bottom: 1px solid var(--line); }
.specimen .tile .glyph { transition: transform 0.25s ease; }
.specimen-body { padding: 14px 16px 18px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.specimen-code { font-family: var(--mono); font-size: 0.76rem; color: var(--muted); margin: 0; letter-spacing: 0.04em; }
.specimen-title { font-family: var(--display); font-size: 1.45rem; margin: 0; }
.specimen-title a { text-decoration: none; }
.specimen-title a::after { content: ""; position: absolute; inset: 0; }
.specimen-q { margin: 0; color: var(--ink-2); font-size: 0.95rem; line-height: 1.45; flex: 1; }
.specimen .doc-badge { align-self: flex-start; margin-top: 4px; }

.card { display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; position: relative; }
.card:hover { border-color: var(--line-2); }
.card-media { aspect-ratio: 16 / 7; background: #efe6d1; display: flex; align-items: center; justify-content: center; gap: 8%; padding: 16px; border-bottom: 1px solid var(--line); }
.card-media svg { height: 78%; width: auto; }
.card-media--plain { background:
  repeating-linear-gradient(135deg, transparent 0 12px, color-mix(in srgb, var(--line) 60%, transparent) 12px 13px), var(--paper-2); }
.card-media--plain span { font-family: var(--sans); font-size: 0.78rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); background: var(--card); padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line); }
.card-body { padding: 18px 20px 22px; }
.card-title { font-family: var(--display); font-size: 1.4rem; margin: 8px 0; }
.card-title a { text-decoration: none; }
.card-title a::after { content: ""; position: absolute; inset: 0; }
.card-text { margin: 0; color: var(--ink-2); font-size: 0.98rem; line-height: 1.5; }

/* Filtri */

.filters { margin-bottom: 26px; display: grid; gap: 12px; }
.filter-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.filter-label { font-family: var(--sans); font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--muted); min-width: 64px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  font: 500 0.9rem var(--sans); padding: 7px 14px; border-radius: 999px; cursor: pointer;
  border: 1px solid var(--line-2); background: transparent; color: var(--ink-2);
}
.chip small { font-size: 0.78em; opacity: 0.75; margin-left: 4px; }
.chip:hover { border-color: var(--ink); color: var(--ink); }
.chip[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.filter-count, .empty { font-family: var(--sans); font-size: 0.9rem; color: var(--muted); margin: 0; }
[hidden] { display: none !important; }

/* Pagina del simbolo */

.symbol-head { padding-top: 28px; }
.symbol-hero { display: grid; grid-template-columns: 300px 1fr; gap: clamp(24px, 5vw, 64px); align-items: center; padding-bottom: 28px; }
.symbol-plate { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; box-shadow: 0 18px 40px -26px rgba(20, 20, 40, 0.5); }
.plate-label { font-family: var(--sans); font-size: 0.82rem; color: var(--muted); margin: 10px 2px 0; display: flex; gap: 8px; }
.research-q { margin: 8px 0 0; padding: 14px 18px; border-left: 3px solid var(--gold); background: var(--paper-2); border-radius: 0 var(--radius) var(--radius) 0; font-style: italic; max-width: 62ch; }
.research-q span { display: block; font-family: var(--sans); font-style: normal; font-size: 0.72rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.14em; color: var(--gold); margin-bottom: 4px; }
@media (max-width: 760px) {
  .symbol-hero { grid-template-columns: 1fr; }
  .symbol-plate { max-width: 240px; }
}

.symbol-grid { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 56px; align-items: start; }
.symbol-main { max-width: var(--narrow); }
.symbol-aside { position: sticky; top: 24px; display: grid; gap: 16px; }
@media (max-width: 1000px) {
  .symbol-grid { grid-template-columns: minmax(0, 1fr); gap: 28px; max-width: calc(var(--narrow) + 2 * var(--gutter)); }
  .symbol-aside { position: static; }
}

.facts { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px; font-family: var(--sans); }
.facts-title { text-transform: uppercase; letter-spacing: 0.12em; font-size: 0.72rem; color: var(--muted); margin: 0 0 6px; }
.facts dl { margin: 0; }
.facts dl > div { padding: 10px 0; border-top: 1px solid var(--line); }
.facts dl > div:first-child { border-top: 0; }
.facts dt { font-size: 0.76rem; color: var(--muted); }
.facts dd { margin: 3px 0 0; font-size: 0.95rem; line-height: 1.45; }
.facts > p:last-child { margin: 10px 0 0; }

.evolution { margin-top: 56px; }
.evolution h2, .claims-title { font-size: 1.7rem; margin: 0 0 6px; }
.evolution-note { font-family: var(--sans); font-size: 0.86rem; color: var(--muted); margin: 0 0 18px; }
.evolution-steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; position: relative; }
.evolution-steps li { display: flex; flex-direction: column; gap: 4px; }
.evolution-steps .tile { margin-bottom: 10px; }
.evo-era { font-family: var(--mono); font-size: 0.85rem; color: var(--accent); margin: 0; }
.evo-style { font-family: var(--display); font-size: 1.25rem; font-weight: 700; margin: 0; }
.evo-text { margin: 0; color: var(--ink-2); font-size: 0.98rem; line-height: 1.5; }
@media (max-width: 700px) {
  .evolution-steps { grid-template-columns: 1fr; }
  .evolution-steps li { display: grid; grid-template-columns: 110px 1fr; column-gap: 16px; }
  .evolution-steps .tile { grid-row: span 3; margin: 0; }
}

.claims { margin-top: 48px; padding: 24px clamp(18px, 3vw, 30px); background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); font-family: var(--sans); }
.prose .claims { margin-top: 3em; }
.claims-title { font-family: var(--display); }
.claims-group { padding-top: 14px; }
.claims-group + .claims-group { border-top: 1px solid var(--line); margin-top: 14px; }
.claims-level { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-weight: 600; margin: 0 0 6px; font-size: 0.98rem; }
.claims-hint { font-weight: 400; color: var(--muted); font-size: 0.84rem; flex-basis: 100%; padding-left: 18px; }
.claims ul { margin: 0; padding-left: 36px; font-size: 0.98rem; line-height: 1.5; color: var(--ink-2); }
.claims li + li { margin-top: 6px; }

.pager { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-block: 56px; }
.pager-link { display: flex; flex-direction: column; padding: 16px 20px; border: 1px solid var(--line); border-radius: var(--radius); text-decoration: none; font-family: var(--display); font-size: 1.3rem; font-weight: 700; background: var(--card); }
.pager-link span { font-family: var(--mono); font-size: 0.8rem; font-weight: 400; color: var(--muted); }
.pager-link--next { text-align: right; }
.pager-link:hover { border-color: var(--ink); }

/* Articolo */

.article-head { padding-top: 28px; }
.article-head h1 { max-width: 22ch; }
.byline { font-family: var(--sans); font-size: 0.9rem; color: var(--muted); margin: 0 0 28px; }

.article-grid { display: grid; grid-template-columns: 220px minmax(0, var(--narrow)); gap: 56px; justify-content: center; }
.article-aside { position: relative; }
.toc { position: sticky; top: 24px; font-family: var(--sans); font-size: 0.88rem; }
.toc-title { text-transform: uppercase; letter-spacing: 0.1em; font-size: 0.72rem; color: var(--muted); margin: 0 0 10px; }
.toc ol { list-style: none; margin: 0; padding: 0; border-left: 2px solid var(--line); }
.toc li a { display: block; padding: 5px 0 5px 14px; text-decoration: none; color: var(--ink-2); line-height: 1.35; }
.toc li a:hover { color: var(--accent); }
.symbol-main .toc { position: static; margin-bottom: 28px; padding: 16px 18px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--card); }
.symbol-main .toc ol { border: 0; columns: 2; column-gap: 24px; }
.symbol-main .toc li a { padding-left: 0; }
@media (max-width: 1000px) {
  .article-grid { grid-template-columns: minmax(0, 1fr); gap: 0; max-width: calc(var(--narrow) + 2 * var(--gutter)); }
  .toc { position: static; margin-bottom: 28px; padding: 16px 18px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--card); }
  .toc ol { border: 0; }
  .toc li a { padding-left: 0; }
}
@media (max-width: 600px) { .symbol-main .toc ol { columns: 1; } }

.prose { font-size: 1.13rem; line-height: 1.72; }
.prose > * + * { margin-top: 1.1em; }
.prose p { margin-block: 0; }
.prose p + p { margin-top: 1em; }
.prose .lead { font-size: 1.3rem; line-height: 1.55; color: var(--ink-2); }
.prose h2 { font-size: 1.85rem; margin-top: 2em; margin-bottom: 0.2em; scroll-margin-top: 20px; }
.prose h3 { font-size: 1.25rem; margin-top: 1.6em; margin-bottom: 0.1em; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li + li { margin-top: 0.35em; }
.prose a { text-decoration-color: color-mix(in srgb, var(--accent) 55%, transparent); }
.prose blockquote { margin-inline: 0; padding: 4px 0 4px 22px; border-left: 3px solid var(--accent); font-style: italic; color: var(--ink-2); }
.prose aside.note { padding: 18px 22px; background: var(--paper-2); border-radius: var(--radius); border-left: 4px solid var(--gold); font-size: 1.02rem; }
.prose aside.note p + p { margin-top: 0.6em; }
.prose figure { margin: 2em 0; }
.prose figure.glyphs { padding: 20px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--card); }
.prose figure.glyphs .glyph-row { justify-content: center; }
.prose figure.glyphs .tile { width: clamp(70px, 18vw, 110px); }
figcaption { font-family: var(--sans); font-size: 0.86rem; color: var(--muted); margin-top: 12px; line-height: 1.45; }
.prose figure.glyphs figcaption { text-align: center; }

.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; border: 1px solid var(--line); border-radius: var(--radius); }
.prose table { border-collapse: collapse; width: 100%; font-family: var(--sans); font-size: 0.92rem; line-height: 1.45; }
.prose th, .prose td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
.prose thead th { background: var(--paper-2); font-weight: 600; }
.prose tr:last-child td { border-bottom: 0; }

.sources { margin-top: 3em !important; padding-top: 6px; border-top: 2px solid var(--ink); font-family: var(--sans); font-size: 0.93rem; line-height: 1.5; }
.sources h2 { font-size: 1.4rem; margin-top: 0.8em; }
.sources ul { padding-left: 1.1em; }
.sources a { word-break: break-word; }

/* Storia */

.legend { list-style: none; padding: 0; margin: 8px 0 0; display: grid; gap: 8px; font-family: var(--sans); font-size: 0.92rem; color: var(--ink-2); }
.legend-item { display: flex; gap: 8px; align-items: baseline; }
.legend-item .claim-dot { position: relative; top: 1px; }

.timeline { list-style: none; margin: 8px 0 32px; padding: 0; position: relative; }
.timeline::before { content: ""; position: absolute; left: 132px; top: 6px; bottom: 6px; width: 2px; background: var(--line); }
.tl-item { display: grid; grid-template-columns: 116px 1fr; gap: 36px; padding: 14px 0 22px; position: relative; }
.tl-item::before { content: ""; position: absolute; left: 127px; top: 24px; width: 12px; height: 12px; border-radius: 50%; background: var(--muted); box-shadow: 0 0 0 3px var(--paper); }
.tl-year { font-family: var(--mono); font-size: 0.98rem; text-align: right; margin: 14px 0 0; color: var(--ink); line-height: 1.3; }
.tl-level { font-family: var(--sans); font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.12em; color: var(--muted); margin: 0; }
.tl-title { font-family: var(--display); font-size: 1.4rem; margin: 2px 0 6px; }
.tl-title a { text-decoration: none; }
.tl-body > p { margin: 0; color: var(--ink-2); font-size: 1.03rem; }
.tl-body .tl-source { font-family: var(--sans); font-size: 0.84rem; color: var(--muted); margin-top: 8px; }
.tl-strip .tl-level { margin-top: 4px; }
.tl-level--documentato { color: var(--ok); }
.tl-level--probabile { color: var(--maybe); }
.tl-level--tradizione { color: var(--lore); }
@media (max-width: 600px) {
  .timeline::before { left: 5px; }
  .tl-item { grid-template-columns: 1fr; gap: 0; padding-left: 28px; }
  .tl-item::before { left: 0; top: 18px; }
  .tl-year { text-align: left; margin-top: 12px; }
}

/* Design */

.principles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.principle { border-top: 3px solid var(--gold); padding-top: 12px; }
.principle-n { color: var(--gold); margin: 0; }
.principle h3 { font-family: var(--display); font-size: 1.4rem; margin: 4px 0 6px; }
.principle p:last-child { margin: 0; color: var(--ink-2); font-size: 1rem; line-height: 1.5; }
@media (max-width: 960px) { .principles { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .principles { grid-template-columns: 1fr; } }

.styles-compare { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.styles-compare .glyph-row { gap: 8px; flex-wrap: nowrap; }
.styles-compare .tile { width: 33%; }
.styles-compare h3 { font-family: var(--display); font-size: 1.45rem; margin: 14px 0 4px; }
.styles-compare p { margin: 0; color: var(--ink-2); font-size: 1rem; line-height: 1.5; }
@media (max-width: 860px) { .styles-compare { grid-template-columns: 1fr; } .styles-compare .tile { width: 96px; } }

.lab-intro { max-width: 70ch; color: var(--ink-2); margin: 0 0 20px; }
.lab-picker { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 10px; margin-bottom: 18px; scrollbar-width: thin; }
.lab-pick { flex: none; display: flex; flex-direction: column; align-items: center; gap: 6px; width: 92px; padding: 10px 6px 8px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--card); cursor: pointer; font: 500 0.8rem var(--sans); color: var(--ink-2); }
.lab-pick svg { width: 48px; height: 48px; background: #fffaf0; border-radius: 4px; padding: 4px; }
.lab-pick:hover { border-color: var(--ink); }
.lab-pick[aria-pressed="true"] { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); color: var(--ink); }
.lab-body { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 28px; align-items: start; }
.lab-stage { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; display: grid; gap: 18px; }
.lab-controls { display: grid; gap: 10px; }
.lab-sizes { display: flex; align-items: flex-end; flex-wrap: wrap; gap: 18px 22px; padding: 18px 4px 4px; }
.lab-size { margin: 0; display: flex; flex-direction: column; align-items: center; gap: 4px; }
.lab-frame { width: var(--px); }
.lab-frame .tile { --inset: 80%; }
.lab-size figcaption { margin: 0; font-family: var(--mono); font-size: 0.75rem; }
.lab-caption { margin: 0; font-family: var(--sans); font-size: 0.84rem; color: var(--muted); }
.lab-name { font-family: var(--display); font-size: 1.5rem; margin: 0 0 6px; }
.lab[data-test-silhouette] .lab-frame .glyph { filter: brightness(0); }
.lab-frame .glyph { transition: filter 0.2s ease; }
@media (max-width: 960px) { .lab-body { grid-template-columns: 1fr; } }

/* Meccanica */

.diagram-grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); gap: 40px; align-items: start; }
.diagram { margin: 0; padding: 20px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); color: var(--ink); }
.diagram-svg { width: 100%; }
.diagram-svg .d-case { fill: var(--paper-2); stroke: currentColor; stroke-width: 2.5; }
.diagram-svg .d-window { fill: none; stroke: var(--accent); stroke-width: 2.5; stroke-dasharray: 6 5; }
.diagram-svg .d-reel { fill: var(--card); stroke: currentColor; stroke-width: 2; }
.diagram-svg .d-strip { fill: #efe6d1; stroke: none; }
.diagram-svg .d-thin { stroke: #b9a888; stroke-width: 1; }
.diagram-svg .d-part { fill: var(--card); stroke: currentColor; stroke-width: 2; }
.diagram-svg .d-notch { fill: currentColor; }
.diagram-svg .d-line { fill: none; stroke: var(--accent); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.diagram-svg .d-axle { stroke: currentColor; stroke-width: 4; stroke-linecap: round; }
.diagram-svg .d-handle { fill: none; stroke: currentColor; stroke-width: 6; stroke-linecap: round; stroke-linejoin: round; }
.diagram-svg .d-knob { fill: var(--accent); }
.diagram-svg .d-labels text { font-family: var(--sans); font-size: 15px; fill: currentColor; }
@media (max-width: 860px) { .diagram-grid { grid-template-columns: 1fr; } }

.strip { display: grid; grid-template-columns: repeat(10, 1fr); gap: 0; border: 2px solid var(--ink); border-radius: 4px; overflow: hidden; background: #efe6d1; }
.strip .tile { border-radius: 0; box-shadow: none; border-right: 1px dashed #b9a888; }
.strip .tile:last-child { border-right: 0; }
@media (max-width: 640px) { .strip { grid-template-columns: repeat(5, 1fr); } .strip .tile:nth-child(5) { border-right: 0; } }

.phases { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; counter-reset: phase; }
.phases li { border-top: 3px solid var(--ink); padding-top: 12px; }
.phase-when { font-family: var(--mono); font-size: 0.82rem; color: var(--accent); margin: 0; }
.phases h3 { font-family: var(--display); font-size: 1.4rem; margin: 4px 0 6px; }
.phases p:last-child { margin: 0; color: var(--ink-2); font-size: 1rem; line-height: 1.5; }
@media (max-width: 960px) { .phases { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .phases { grid-template-columns: 1fr; } }

/* Glossario e fonti */

.letters { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.letters a { font-family: var(--display); font-weight: 700; font-size: 1.1rem; width: 38px; height: 38px; display: grid; place-items: center; border: 1px solid var(--line-2); border-radius: 50%; text-decoration: none; }
.letters a:hover { border-color: var(--ink); }
.letter { font-size: 2.2rem; color: var(--accent); margin: 1.4em 0 0.2em; scroll-margin-top: 16px; }
.glossary { margin: 0; }
.term { padding: 16px 0 18px; border-top: 1px solid var(--line); scroll-margin-top: 16px; }
.term:target { background: color-mix(in srgb, var(--gold) 12%, transparent); padding-inline: 14px; border-radius: var(--radius); }
.term dt { font-family: var(--display); font-weight: 700; font-size: 1.4rem; }
.term-alt { font-family: var(--sans); font-weight: 400; font-size: 0.85rem; color: var(--muted); font-style: italic; }
.term dd { margin: 6px 0 0; color: var(--ink-2); }
.term dd p { margin: 0; }
.term-see { font-family: var(--sans); font-size: 0.88rem; color: var(--muted); margin-top: 8px !important; }

.biblio { list-style: none; padding: 0 !important; }
.biblio li { padding: 14px 0; border-top: 1px solid var(--line); }
.biblio-main { display: block; }
.biblio-note { display: block; font-family: var(--sans); font-size: 0.9rem; color: var(--muted); margin-top: 4px; line-height: 1.5; }

.topic-links { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; margin: 4px 0 28px; }
.topic-links a { display: block; font-family: var(--sans); font-size: 0.9rem; padding: 7px 14px; border: 1px solid var(--line-2); border-radius: 999px; text-decoration: none; }
.topic-links a:hover { border-color: var(--ink); }

.related { margin-block: 64px; }
.page .prose h2 { font-size: 1.5rem; }
.not-found { padding-block: 72px; }
.not-found .glyph-row .tile { width: 72px; }

/* Piè di pagina */

.site-footer { margin-top: 96px; border-top: 1px solid var(--line); background: var(--paper-2); font-family: var(--sans); font-size: 0.92rem; color: var(--ink-2); }
.footer-grid { display: grid; grid-template-columns: 1.7fr 1fr 1fr 1fr; gap: 32px; padding-block: 48px 32px; }
.footer-brand { display: flex; align-items: center; gap: 10px; font-family: var(--display); font-size: 1.4rem; font-weight: 700; color: var(--ink); margin: 0 0 10px; }
.footer-brand svg { width: 28px; color: var(--accent); }
.footer-about p { max-width: 46ch; }
.footer-note { font-size: 0.84rem; color: var(--muted); border-left: 2px solid var(--line-2); padding-left: 12px; }
.footer-title { font-family: var(--sans); font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.14em; color: var(--muted); margin: 6px 0 12px; font-weight: 600; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.site-footer a { text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.linklike { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; text-align: left; }
.linklike:hover { color: var(--accent); text-decoration: underline; }
.footer-base { border-top: 1px solid var(--line); padding-block: 18px 28px; font-size: 0.84rem; color: var(--muted); }
.footer-base p { margin: 0; }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-about { grid-column: 1 / -1; } }
@media (max-width: 420px) { .footer-grid { grid-template-columns: 1fr; } }

/* Banner cookie */

.consent { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; padding: 12px var(--gutter) calc(12px + env(safe-area-inset-bottom)); }
.consent-inner { max-width: 980px; margin: 0 auto; display: flex; gap: 20px; align-items: center; background: var(--card); border: 1px solid var(--line-2); border-radius: 10px; padding: 18px 20px; box-shadow: 0 12px 40px -10px rgba(0, 0, 0, 0.35); font-family: var(--sans); font-size: 0.92rem; line-height: 1.5; }
.consent-inner p { margin: 0; flex: 1; }
.consent-actions { display: flex; gap: 10px; flex: none; }
.consent-actions .button { padding: 10px 20px; }
@media (max-width: 640px) { .consent-inner { flex-direction: column; align-items: stretch; } .consent-actions .button { flex: 1; text-align: center; } }

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

@media print {
  .site-header, .site-footer, .article-aside, .related, .toc, .consent, .pager, .lab { display: none; }
  body { background: #fff; color: #000; }
}
