/* Spin Landmark — utility layer */
:root {
  --ink: #0b0b0b;
  --ink-soft: #2a2a2a;
  --muted: #5c5c5c;
  --paper: #f7f7f5;
  --paper-2: #efefec;
  --line: #0b0b0b;
  --accent: #00c853;
  --accent-tint: rgba(0, 200, 83, 0.12);
  --accent-tint-2: rgba(0, 200, 83, 0.08);
  --danger: #b00020;
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.5rem;
  --space-6: 2rem;
  --space-7: 3rem;
  --space-8: 4.5rem;
  --measure: 68ch;
  --wide: 72rem;
  --font-display: "Source Serif 4", "Iowan Old Style", "Palatino Linotype", Palatino, serif;
  --font-body: "Source Sans 3", "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  --font-mono: "IBM Plex Mono", "Consolas", "Courier New", monospace;
  --radius: 0;
  --border: 1px dashed var(--ink);
  --border-solid: 1px solid var(--ink);
  --border-dotted: 1px dotted var(--ink);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: auto;
}

body {
  margin: 0;
  color: var(--ink);
  background: linear-gradient(180deg, #fafaf8 0%, var(--paper) 45%, #f2f2ef 100%);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.6;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

a:hover {
  color: var(--ink);
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.15;
  margin: 0 0 var(--space-4);
  color: var(--ink);
}

p {
  margin: 0 0 var(--space-4);
  max-width: var(--measure);
}

ul,
ol {
  margin: 0 0 var(--space-4);
  padding-left: 1.25rem;
}

button,
input,
textarea,
select {
  font: inherit;
}

/* Layout utilities */
.wrap {
  width: min(100% - 2rem, var(--wide));
  margin-inline: auto;
}

.wrap--narrow {
  width: min(100% - 2rem, 48rem);
}

.stack {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.stack--tight {
  gap: var(--space-2);
}

.stack--loose {
  gap: var(--space-6);
}

.cluster {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-3);
}

.cluster--between {
  justify-content: space-between;
}

.cluster--end {
  justify-content: flex-end;
}

.grid-2 {
  display: grid;
  gap: var(--space-5);
}

@media (min-width: 768px) {
  .grid-2 {
    grid-template-columns: 1fr 1fr;
  }
}

.grid-3 {
  display: grid;
  gap: var(--space-4);
}

@media (min-width: 900px) {
  .grid-3 {
    grid-template-columns: repeat(3, 1fr);
  }
}

.grid-4 {
  display: grid;
  gap: var(--space-4);
}

@media (min-width: 700px) {
  .grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1000px) {
  .grid-4 {
    grid-template-columns: repeat(4, 1fr);
  }
}

.span-full {
  grid-column: 1 / -1;
}

/* Type utilities */
.display {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 7vw, 5.5rem);
  letter-spacing: -0.02em;
  line-height: 0.95;
}

.display-sm {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  letter-spacing: -0.015em;
  line-height: 1.05;
}

.lede {
  font-size: 1.2rem;
  max-width: 55ch;
  color: var(--ink-soft);
}

.mono {
  font-family: var(--font-mono);
  font-size: 0.875rem;
  letter-spacing: 0.02em;
}

.label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.accent {
  color: var(--accent);
}

.muted {
  color: var(--muted);
}

.measure {
  max-width: var(--measure);
}

.text-right {
  text-align: right;
}

/* Surfaces */
.band {
  padding-block: var(--space-7);
}

.band--tint {
  background: var(--paper-2);
}

.band--ruled {
  background-image: repeating-linear-gradient(
    to bottom,
    transparent,
    transparent 27px,
    rgba(11, 11, 11, 0.04) 28px
  );
}

.card {
  background: transparent;
  border: var(--border);
  padding: var(--space-5);
  border-radius: var(--radius);
}

.card--solid {
  background: #fff;
  border: var(--border-solid);
}

.panel {
  border: var(--border-dotted);
  padding: var(--space-5);
  background: rgba(255, 255, 255, 0.7);
}

.rule {
  border: 0;
  border-top: var(--border);
  margin: var(--space-6) 0;
}

.rule--solid {
  border-top: var(--border-solid);
}

/* Motif section break */
.break {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-3);
  margin: var(--space-6) 0;
  color: var(--accent);
  font-size: 0.85rem;
}

.break::before,
.break::after {
  content: "";
  flex: 1;
  border-top: var(--border-dotted);
}

.break__glyph {
  font-family: var(--font-mono);
}

/* Badges */
.badge {
  display: inline-block;
  padding: 0.2rem 0.55rem;
  background: var(--accent-tint);
  color: var(--ink-soft);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  border-radius: var(--radius);
  border: none;
}

.badge--ink {
  background: rgba(11, 11, 11, 0.06);
}

.badge--outline {
  background: transparent;
  border: 1px dashed var(--ink);
}

/* Buttons — sharp rectangular, zero radius */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: 0.7rem 1.15rem;
  border: 2px solid var(--ink);
  background: var(--accent);
  color: var(--ink);
  text-decoration: none;
  font-weight: 700;
  font-size: 0.95rem;
  border-radius: var(--radius);
  cursor: pointer;
  line-height: 1;
}

.btn:hover {
  background: var(--ink);
  color: #fff;
  text-decoration: none;
}

.btn--ghost {
  background: transparent;
  color: var(--ink);
}

.btn--ghost:hover {
  background: var(--ink);
  color: #fff;
}

.btn--small {
  padding: 0.5rem 0.85rem;
  font-size: 0.85rem;
}

/* Stars */
.stars {
  font-family: var(--font-mono);
  letter-spacing: 0.08em;
  color: var(--ink);
  white-space: nowrap;
}

.stars .half {
  color: var(--accent);
}

.stars .empty {
  color: #c8c8c4;
}

/* Numerals */
.numeral {
  font-family: var(--font-display);
  font-size: clamp(3rem, 8vw, 6rem);
  line-height: 0.85;
  color: var(--accent);
  font-weight: 700;
}

.tick {
  font-family: var(--font-mono);
  color: var(--accent);
}

/* Tables */
.table-wrap {
  overflow-x: auto;
  border: var(--border);
  background: #fff;
}

table.data {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}

table.data th,
table.data td {
  padding: 0.85rem 1rem;
  border-bottom: var(--border-dotted);
  text-align: left;
  vertical-align: top;
}

table.data th {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  background: var(--paper-2);
  border-bottom: var(--border-solid);
}

table.data td.num,
table.data th.num {
  text-align: right;
  font-variant-numeric: tabular-nums;
  font-family: var(--font-mono);
}

table.data tr.featured {
  background: var(--accent-tint-2);
}

table.data tr.featured td {
  border-bottom: 2px solid var(--accent);
}

/* Forms */
.field {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.field input,
.field textarea,
.field select {
  border: 2px solid var(--ink);
  border-radius: var(--radius);
  padding: 0.7rem 0.85rem;
  background: #fff;
}

.field input:focus,
.field textarea:focus {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* Visually hidden */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}
