/* clariastrix.com - Osservatorio
   Handwritten CSS. Direction: instrument night, particle field, one quiet light.
   Flat surfaces, hairline borders, no shadows, no glow. Mobile-first, full-bleed. */

:root {
  /* Surfaces: near-black midnight, muted cool steps */
  --void: #05070b;
  --carbon: #0a0e14;
  --graphite: #111720;
  --line: #1b2430;
  --line-lit: #2c3a4a;

  /* Ink */
  --frost: #eef3f8;
  --ash: #b6c4d2;
  --smoke: #8697a8;
  --slate: #5d6b7a;

  /* The single quiet light accent. Used for: CTA, luminosità, the star. Nothing else. */
  --luce: #e6c07b;
  --luce-ink: #05070b;
  --luce-dim: #6d5a34;

  --gutter: clamp(20px, 5vw, 96px);
  --measure: 66ch;

  --step-cap: clamp(10.5px, 0.28vw + 9.8px, 12px);
  --step-body: clamp(15px, 0.35vw + 14.2px, 17px);
  --step-lead: clamp(18px, 0.9vw + 15.5px, 24px);
  --step-sm: clamp(19px, 0.7vw + 17px, 24px);
  --step-md: clamp(24px, 1.6vw + 19px, 34px);
  --step-lg: clamp(30px, 3vw + 21px, 52px);
  --step-xl: clamp(38px, 5.4vw + 22px, 82px);

  --rhythm: clamp(56px, 7vw, 108px);
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--void);
  color: var(--ash);
  font-family: 'Exo 2', system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-weight: 300;
  font-size: var(--step-body);
  line-height: 1.62;
  letter-spacing: 0.012em;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: 'Bitter', Georgia, serif;
  font-weight: 400;
  color: var(--frost);
  letter-spacing: -0.018em;
  line-height: 1.16;
  margin: 0;
  text-wrap: balance;
}

p { margin: 0 0 1em; max-width: var(--measure); }
p:last-child { margin-bottom: 0; }

a { color: var(--frost); text-decoration-color: var(--line-lit); text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--luce); }

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

:focus-visible {
  outline: 2px solid var(--luce);
  outline-offset: 3px;
}

.skip {
  position: absolute; left: -9999px; top: 0; z-index: 60;
  background: var(--luce); color: var(--luce-ink);
  padding: 12px 20px; font-size: var(--step-cap);
  text-transform: uppercase; letter-spacing: 0.09em;
}
.skip:focus { left: 0; }

/* ---------- shared primitives ---------- */

.bleed { padding-inline: var(--gutter); }

.cap {
  font-family: 'Exo 2', sans-serif;
  font-size: var(--step-cap);
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--smoke);
  margin: 0;
}
.cap-num { color: var(--luce); font-variant-numeric: tabular-nums; }

.rule { border: 0; border-top: 1px solid var(--line); margin: 0; }

.lead {
  font-size: var(--step-lead);
  line-height: 1.48;
  color: var(--frost);
  font-weight: 300;
  letter-spacing: -0.004em;
}

.muted { color: var(--smoke); }
.small { font-size: 0.86em; line-height: 1.55; }

/* Buttons: zero radius, flat, terminal */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 13px 24px;
  font-family: 'Exo 2', sans-serif;
  font-size: var(--step-cap);
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.11em;
  text-decoration: none;
  border: 1px solid var(--line-lit);
  color: var(--frost);
  background: transparent;
  white-space: nowrap;
  transition: border-color .2s ease, color .2s ease, background-color .2s ease, transform .12s ease;
}
.btn:hover { border-color: var(--smoke); background: var(--carbon); }
.btn:active { transform: translateY(1px); }

.btn-luce {
  background: var(--luce);
  border-color: var(--luce);
  color: var(--luce-ink);
  font-weight: 500;
}
.btn-luce:hover { background: #f0cf95; border-color: #f0cf95; color: var(--luce-ink); }

/* ---------- header ---------- */

.top {
  position: sticky; top: 0; z-index: 40;
  background: rgba(5, 7, 11, 0.92);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(8px);
}
.top-in {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; min-height: 62px;
}

.brand { display: flex; align-items: center; gap: 11px; text-decoration: none; }
.brand svg { display: block; flex: none; }
.brand-t b {
  display: block;
  font-family: 'Bitter', serif; font-weight: 400; font-size: 17px;
  color: var(--frost); letter-spacing: 0.01em; line-height: 1.1;
}
.brand-t span {
  font-size: 9.5px; text-transform: uppercase; letter-spacing: 0.2em;
  color: var(--slate); display: block; margin-top: 2px;
}

.nav-toggle {
  display: inline-flex; align-items: center; gap: 8px;
  background: none; border: 1px solid var(--line-lit); color: var(--ash);
  font-family: inherit; font-size: 10.5px; text-transform: uppercase;
  letter-spacing: 0.12em; padding: 9px 13px; cursor: pointer;
}
.nav-toggle:hover { border-color: var(--smoke); color: var(--frost); }

.nav { display: none; }
.nav[data-open='true'] {
  display: block;
  position: absolute; left: 0; right: 0; top: 100%;
  background: var(--carbon); border-bottom: 1px solid var(--line);
  padding: 8px var(--gutter) 22px;
}
.nav ul { list-style: none; margin: 0; padding: 0; }
.nav li { border-top: 1px solid var(--line); }
.nav a {
  display: block; padding: 13px 0;
  font-size: 13px; letter-spacing: 0.05em;
  color: var(--ash); text-decoration: none;
}
.nav a:hover, .nav a[aria-current='page'] { color: var(--frost); }
.nav a[aria-current='page'] { border-left: 2px solid var(--luce); padding-left: 12px; }

@media (min-width: 900px) {
  .nav-toggle { display: none; }
  .nav, .nav[data-open='true'] {
    display: block; position: static; background: none;
    border: 0; padding: 0;
  }
  .nav ul { display: flex; align-items: center; gap: 26px; }
  .nav li { border-top: 0; }
  .nav a { padding: 4px 0; font-size: 12.5px; }
  .nav a[aria-current='page'] {
    border-left: 0; padding-left: 0; border-bottom: 1px solid var(--luce);
  }
}

/* ---------- hero: typographic, left, particle field behind ---------- */

.hero { position: relative; overflow: hidden; border-bottom: 1px solid var(--line); }
#stelle {
  position: absolute; inset: 0; width: 100%; height: 100%;
  display: block; pointer-events: none;
}
/* The field spreads to the right of the headline, so the copy stops well short
   of the full width and leaves that side to the particles. */
.hero-in {
  position: relative; z-index: 1;
  padding-block: clamp(52px, 9vw, 96px) clamp(48px, 7vw, 88px);
}
@media (min-width: 1000px) { .hero-in > div { max-width: 62%; } }

.hero h1 {
  font-size: var(--step-xl);
  line-height: 1.04;
  letter-spacing: -0.03em;
  max-width: 15ch;
}
.hero h1 em {
  font-style: normal;
  color: var(--luce);
}
.hero .lead { margin-top: 22px; max-width: 46ch; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.hero-trust {
  margin-top: 26px; padding-top: 16px;
  border-top: 1px solid var(--line);
  max-width: 44ch;
}

/* ---------- section frame ---------- */

.sec { padding-block: var(--rhythm); border-bottom: 1px solid var(--line); }
.sec-head { display: grid; gap: 14px; margin-bottom: clamp(30px, 3.4vw, 52px); }
.sec-head h2 { font-size: var(--step-lg); max-width: 20ch; }

/* ---------- chi osserva: narrow column + hanging rail ---------- */

.osserva { display: grid; gap: clamp(28px, 3vw, 44px); }
@media (min-width: 940px) {
  .osserva { grid-template-columns: 15rem minmax(0, 1fr); gap: clamp(40px, 5vw, 76px); }
}
.osserva-rail { display: grid; gap: 16px; align-content: start; }
.osserva-rail p { margin: 0; }
.osserva-sig {
  font-family: 'Bitter', serif; color: var(--frost);
  font-size: 20px; line-height: 1.3;
}
.osserva-body > p { font-size: calc(var(--step-body) + 0.5px); }
.osserva-body .lead { margin-bottom: 20px; }

.caveat {
  border-left: 2px solid var(--luce-dim);
  padding: 4px 0 4px 18px;
  margin: 26px 0 0;
  color: var(--smoke);
  max-width: 58ch;
}
.caveat strong { color: var(--ash); font-weight: 400; }

/* ---------- metodo: numbered annotation rows (aaru pattern) ---------- */

.metodo-grid { display: grid; gap: 0; }
@media (min-width: 900px) { .metodo-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: clamp(40px, 5vw, 80px); } }

.crit { border-top: 1px solid var(--line); padding: 22px 0 24px; }
.crit-top { display: flex; align-items: baseline; gap: 14px; margin-bottom: 9px; }
.crit-top .n {
  font-family: 'Exo 2', sans-serif; font-size: 11px; color: var(--luce);
  font-variant-numeric: tabular-nums; letter-spacing: 0.08em; flex: none;
}
.crit-top h3 {
  font-family: 'Exo 2', sans-serif; font-size: 12px; font-weight: 400;
  text-transform: uppercase; letter-spacing: 0.14em; color: var(--frost);
}
.crit p { margin: 0; color: var(--smoke); max-width: 52ch; font-size: 14.5px; }

.metodo-note {
  margin-top: clamp(34px, 4vw, 56px);
  background: var(--graphite);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: clamp(22px, 2.6vw, 34px);
}
.metodo-note h3 { font-size: var(--step-sm); margin-bottom: 12px; }
.metodo-note p { max-width: 62ch; }

/* ---------- registro: observation records ---------- */

.registro { display: grid; gap: 0; }

.oss {
  border-top: 1px solid var(--line-lit);
  padding-block: clamp(40px, 4.6vw, 68px);
  display: grid;
  gap: clamp(24px, 2.6vw, 38px);
}
@media (min-width: 940px) {
  .oss { grid-template-columns: 11.5rem minmax(0, 1fr); gap: clamp(32px, 4vw, 60px); }
}

.oss-rail { display: grid; gap: 20px; align-content: start; }
@media (min-width: 940px) { .oss-rail { position: sticky; top: 86px; } }

.lum { display: grid; gap: 3px; }
.lum-val {
  font-family: 'Bitter', serif; font-size: clamp(40px, 4.4vw, 56px);
  line-height: 1; color: var(--luce); font-variant-numeric: tabular-nums;
  letter-spacing: -0.03em;
}
.lum-val i { font-style: normal; font-size: 0.42em; color: var(--slate); letter-spacing: 0; }
.lum-lab { font-size: 10.5px; text-transform: uppercase; letter-spacing: 0.15em; color: var(--slate); }

.tempo { border-top: 1px solid var(--line); padding-top: 14px; }
.tempo b { display: block; font-weight: 400; color: var(--ash); font-size: 14px; }

.oss-body { display: grid; gap: 22px; }
.oss-title { display: grid; gap: 8px; }
.oss-title h3 { font-size: var(--step-md); letter-spacing: -0.022em; }
.oss-studio { font-size: 13.5px; color: var(--smoke); }
.oss-hook { font-size: var(--step-lead); line-height: 1.44; color: var(--frost); font-weight: 300; max-width: 40ch; }

.shot {
  border: 1px solid var(--line);
  border-radius: 6px;
  overflow: hidden;
  background: var(--carbon);
}
.shot img { width: 100%; height: auto; }
.shot figcaption {
  font-size: 11px; color: var(--slate); padding: 9px 12px;
  border-top: 1px solid var(--line); letter-spacing: 0.04em;
}

/* record 01 runs its field full width; 02/03 sit beside a narrow plate;
   04 drops the plate below the prose; 05 keeps it tight next to the note. */
.oss-split { display: grid; gap: clamp(20px, 2.4vw, 32px); }
@media (min-width: 760px) {
  .oss-split { grid-template-columns: minmax(0, 1fr) 15rem; align-items: start; }
  .oss-split--wide { grid-template-columns: minmax(0, 1fr) 20rem; }
  .oss-split--flip > .shot { order: -1; }
}

.meta { border-top: 1px solid var(--line); margin: 0; padding-top: 18px;
  display: grid; gap: 0; }
.meta div {
  display: grid; grid-template-columns: 8.5rem minmax(0, 1fr);
  gap: 12px; padding: 7px 0; border-bottom: 1px solid rgba(27, 36, 48, 0.55);
  align-items: baseline;
}
.meta div:last-child { border-bottom: 0; }
.meta dt { font-size: 10.5px; text-transform: uppercase; letter-spacing: 0.13em; color: var(--slate); }
.meta dd { margin: 0; font-size: 14px; color: var(--ash); }
.meta dd b { font-weight: 400; color: var(--frost); }

.store { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.store-note { font-size: 12px; color: var(--slate); }

.pill {
  display: inline-block; font-size: 10.5px; text-transform: uppercase;
  letter-spacing: 0.12em; padding: 4px 9px; border: 1px solid var(--line-lit);
  color: var(--smoke);
}
.pill-luce { border-color: var(--luce-dim); color: var(--luce); }

/* ---------- carta del cielo ---------- */

.carta-wrap { display: grid; gap: clamp(28px, 3vw, 44px); }
/* The chart and the table are both wider than a phone and scroll inside
   themselves. Grid children default to min-width:auto, which would let them
   push the whole page sideways instead, so they are told they may shrink. */
.carta-wrap > * { min-width: 0; }

.carta {
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--carbon);
  padding: clamp(16px, 2vw, 26px);
  overflow-x: auto;
}
.carta svg { display: block; min-width: 560px; width: 100%; height: auto; }
.carta-legend { font-size: 12px; color: var(--slate); margin-top: 14px; max-width: none; }

.tab-wrap { overflow-x: auto; min-width: 0; }
table.dati {
  width: 100%; border-collapse: collapse; min-width: 720px;
  font-size: 13.5px; font-variant-numeric: tabular-nums;
}
table.dati caption {
  text-align: left; font-size: var(--step-cap); text-transform: uppercase;
  letter-spacing: 0.14em; color: var(--smoke); padding-bottom: 14px;
}
table.dati th, table.dati td {
  text-align: left; padding: 12px 14px 12px 0; border-bottom: 1px solid var(--line);
  vertical-align: top;
}
table.dati thead th {
  font-family: 'Exo 2', sans-serif; font-weight: 400; font-size: 10.5px;
  text-transform: uppercase; letter-spacing: 0.12em; color: var(--slate);
  border-bottom-color: var(--line-lit);
}
table.dati tbody th { font-family: 'Bitter', serif; font-weight: 400; color: var(--frost); font-size: 14.5px; }
table.dati td { color: var(--smoke); }
table.dati td b { color: var(--luce); font-weight: 400; }

/* ---------- stella del registro ---------- */

.stella {
  border: 1px solid var(--luce-dim);
  border-radius: 6px;
  background: var(--graphite);
  padding: clamp(26px, 3.4vw, 52px);
  display: grid; gap: clamp(22px, 2.6vw, 36px);
}
@media (min-width: 900px) {
  .stella { grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); align-items: center; }
}
.stella h3 { font-size: var(--step-lg); margin: 10px 0 16px; }
.stella-why { display: grid; gap: 14px; }
.stella-why p { margin: 0; }
.stella-side { display: grid; gap: 14px; }
@media (min-width: 900px) { .stella-side { border-left: 1px solid var(--line-lit); padding-left: clamp(24px, 3vw, 44px); } }

/* ---------- note notturne ---------- */

.note { max-width: 72ch; }
.note h2 { margin-bottom: 22px; }
.note p { font-size: calc(var(--step-body) + 0.5px); }
.note .pull {
  font-family: 'Bitter', serif; font-size: var(--step-md); line-height: 1.32;
  color: var(--frost); border-top: 1px solid var(--line-lit);
  border-bottom: 1px solid var(--line-lit); padding: 26px 0; margin: 34px 0;
  max-width: 26ch; letter-spacing: -0.018em;
}

/* ---------- faq ---------- */

.faq { display: grid; }
.faq details {
  border-top: 1px solid var(--line);
}
.faq details:last-of-type { border-bottom: 1px solid var(--line); }
.faq summary {
  cursor: pointer; list-style: none;
  padding: 20px 34px 20px 0; position: relative;
  font-family: 'Bitter', serif; color: var(--frost);
  font-size: var(--step-sm); line-height: 1.35; letter-spacing: -0.012em;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ''; position: absolute; right: 6px; top: 50%;
  width: 9px; height: 9px; margin-top: -6px;
  border-right: 1px solid var(--smoke); border-bottom: 1px solid var(--smoke);
  transform: rotate(45deg); transition: transform .22s ease;
}
.faq details[open] summary::after { transform: rotate(-135deg); margin-top: -2px; }
.faq summary:hover { color: var(--luce); }
.faq-a { padding: 0 0 24px; }
.faq-a p { color: var(--smoke); }

/* ---------- form ---------- */

.form { display: grid; gap: 20px; max-width: 34rem; }
.field { display: grid; gap: 7px; }
.field label {
  font-size: var(--step-cap); text-transform: uppercase;
  letter-spacing: 0.13em; color: var(--ash);
}
.field input, .field textarea {
  background: var(--carbon);
  border: 1px solid var(--line-lit);
  border-radius: 0;
  color: var(--frost);
  font-family: inherit; font-size: 15px; font-weight: 300;
  padding: 13px 14px; min-height: 46px; width: 100%;
}
.field textarea { min-height: 128px; resize: vertical; line-height: 1.55; }
.field input::placeholder, .field textarea::placeholder { color: var(--slate); }
.field input:focus, .field textarea:focus { border-color: var(--luce); outline: none; }
.hint { font-size: 12.5px; color: var(--slate); }

.consent { display: flex; gap: 12px; align-items: flex-start; }
.consent input { width: 18px; height: 18px; min-height: 0; flex: none; margin-top: 3px; accent-color: var(--luce); }
.consent label { text-transform: none; letter-spacing: 0.01em; font-size: 13.5px; color: var(--smoke); line-height: 1.5; }

/* ---------- footer ---------- */

.foot { background: var(--carbon); padding-block: clamp(44px, 5vw, 72px) 34px; }
.foot-grid { display: grid; gap: clamp(28px, 3vw, 44px); }
@media (min-width: 860px) { .foot-grid { grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr) minmax(0, 1fr); } }
.foot h2 { font-size: 18px; margin-bottom: 12px; }
.foot p { font-size: 14px; color: var(--smoke); max-width: 42ch; }
.foot ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 9px; }
.foot ul a { font-size: 13.5px; color: var(--smoke); text-decoration: none; }
.foot ul a:hover { color: var(--frost); }
.foot-zero {
  display: inline-block; margin-top: 16px;
  font-size: 11px; text-transform: uppercase; letter-spacing: 0.13em;
  color: var(--luce); border: 1px solid var(--luce-dim); padding: 6px 11px;
}
.foot-legal {
  margin-top: clamp(34px, 4vw, 52px); padding-top: 22px;
  border-top: 1px solid var(--line);
  display: grid; gap: 14px;
}
.foot-legal p { font-size: 11.5px; line-height: 1.6; color: var(--slate); max-width: 96ch; }

/* ---------- legal / long-read pages ---------- */

.doc { padding-block: clamp(44px, 5vw, 76px) var(--rhythm); }
.doc-head { border-bottom: 1px solid var(--line); padding-bottom: 26px; margin-bottom: 34px; }
.doc-head h1 { font-size: var(--step-lg); max-width: 22ch; }
.doc-head p { margin-top: 14px; }
.doc-body { max-width: 74ch; }
.doc-body h2 {
  font-size: var(--step-sm); margin: 40px 0 12px;
  padding-top: 22px; border-top: 1px solid var(--line);
}
.doc-body h2:first-child { border-top: 0; padding-top: 0; margin-top: 0; }
.doc-body h3 { font-size: 17px; margin: 24px 0 8px; }
.doc-body ul { padding-left: 20px; margin: 0 0 1em; max-width: var(--measure); }
.doc-body li { margin-bottom: 8px; }
.doc-body li::marker { color: var(--luce-dim); }

/* ---------- 404 ---------- */

.lost { min-height: 62vh; display: grid; align-content: center; gap: 20px;
  padding-block: clamp(60px, 9vw, 120px); }
.lost h1 { font-size: var(--step-xl); letter-spacing: -0.03em; }
.lost p { font-size: var(--step-lead); color: var(--smoke); max-width: 44ch; }

/* ---------- grazie ---------- */

.grazie { min-height: 58vh; display: grid; align-content: center; gap: 22px;
  padding-block: clamp(60px, 9vw, 110px); }
.grazie h1 { font-size: var(--step-lg); max-width: 18ch; }
