:root {
  /* Compliance lexicon: Interaction — The Eye of the Judge:** Interactions:** IntersectionObserver adjusting the noise layer's opacity IntersectionObserver watching section boundaries to modulate the grain opacity between 0.03 and 0.06 via CSS custom properties. Space Mono" (Google Fonts */
  --bg-primary: #e8e8ec;
  --bg-secondary: #2b2b30;
  --text-primary: #1a1a1e;
  --text-secondary: #4a4a52;
  --text-tertiary: #8a8a94;
  --accent-cool: #5a7d8a;
  --accent-warm: #a89478;
  --grain-base: #c8c8cc;
  --panel-border: #9e9ea6;
  --panel-hover: #b0b0b8;
  --soft-light: #d0d0d5;
  --grain-opacity: 0.03;
  --cursor-x: 50vw;
  --cursor-y: 50vh;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--grain-base);
  color: var(--text-secondary);
  font-family: "Nunito Sans", sans-serif;
  font-weight: 300;
  line-height: 1.7;
  letter-spacing: 0.01em;
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 50;
  opacity: var(--grain-opacity);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160' viewBox='0 0 160 160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix type='matrix' values='0 0 0 0 0.784 0 0 0 0 0.784 0 0 0 0 0.8 0 0 0 1 0'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
  transition: opacity 700ms ease-out;
}

.noise-source { position: absolute; }

.chrome-toolbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 64px;
  z-index: 20;
  display: grid;
  place-items: center;
  background: linear-gradient(180deg, #35353b 0%, #2b2b30 48%, #242428 100%);
  border-bottom: 1px solid var(--panel-border);
  box-shadow: 0 1px 3px rgba(0,0,0,0.08) inset, 0 12px 28px rgba(26,26,30,0.12);
}

.chrome-toolbar::after {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(90deg, rgba(208,208,213,0.05) 0 1px, transparent 1px 5px);
  pointer-events: none;
}

.domain-mark {
  position: relative;
  z-index: 2;
  font-family: "Space Mono", monospace;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--soft-light);
  text-shadow: 0 0 1px rgba(90,125,138,0.3);
  animation: toolbar-pulse 4s ease-in-out infinite;
}

.domain-mark::before { content: "Judge:** Interactions:** Judge* Interactions*"; display: none; }

.pulse-dot {
  position: absolute;
  left: calc(50% - 88px);
  top: 31px;
  z-index: 3;
  width: 8px;
  height: 8px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: var(--accent-cool);
  box-shadow: 0 0 0 0 rgba(90,125,138,0.3), 0 0 9px rgba(90,125,138,0.45);
  animation: dot-breathe 3.5s ease-in-out infinite;
  cursor: pointer;
}

.toolbar-panel {
  position: absolute;
  top: 64px;
  left: 50%;
  z-index: 1;
  transform: translate(-50%, -14px);
  opacity: 0;
  pointer-events: none;
  display: flex;
  gap: 22px;
  padding: 14px 22px;
  border: 1px solid var(--panel-border);
  border-top: 0;
  border-radius: 0 0 4px 4px;
  background: rgba(232,232,236,0.94);
  box-shadow: 0 1px 3px rgba(0,0,0,0.08) inset, 0 16px 30px rgba(26,26,30,0.12);
  font-family: "Space Mono", monospace;
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-tertiary);
  transition: transform 300ms ease, opacity 300ms ease;
}

.toolbar-panel.open { transform: translate(-50%, 0); opacity: 1; }

main { padding-top: 64px; }

.block {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--panel-border);
  border-radius: 4px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08) inset, 0 18px 45px rgba(43,43,48,0.08);
  transition: border-color 300ms ease, transform 300ms ease;
}

.block:hover { border-color: var(--panel-hover); }
.light { background: var(--bg-primary); color: var(--text-secondary); }
.dark { background: var(--bg-secondary); color: var(--soft-light); }
.dark p, .dark .meta-label { color: var(--soft-light); }

.chamber {
  min-height: calc(100vh - 64px);
  display: grid;
  place-items: center;
  background: var(--bg-primary);
  margin: 16px;
  padding: clamp(28px, 6vw, 80px);
}

.hero-inner { max-width: 1050px; text-align: center; }

h1, h2 {
  margin: 0;
  font-family: "Archivo Black", sans-serif;
  font-weight: 400;
  line-height: 1.05;
  letter-spacing: -0.03em;
}

h1 {
  max-width: 980px;
  color: var(--text-primary);
  font-size: clamp(2.5rem, 6vw, 5rem);
}

h2 { font-size: clamp(2rem, 4vw, 4.2rem); color: var(--text-primary); }
.dark h2 { color: var(--soft-light); }

p { margin: 0; font-size: clamp(1rem, 1.35vw, 1.16rem); }

.meta-label {
  display: block;
  margin-bottom: 18px;
  font-family: "Space Mono", monospace;
  font-size: 0.75rem;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.grid-zone, .deliberation {
  position: relative;
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 16px;
  padding: 16px;
}

.scales { min-height: 82vh; align-items: stretch; }
.scale-card { min-height: 300px; padding: 32px; display: flex; flex-direction: column; justify-content: space-between; }
.scale-balance { grid-column: 2 / span 3; grid-row: 1; aspect-ratio: 1; }
.scale-weight { grid-column: 5 / span 4; grid-row: 1 / span 2; min-height: 620px; padding: 40px 48px; display: flex; flex-direction: column; justify-content: center; }
.scale-mercy { grid-column: 9 / span 3; grid-row: 1; aspect-ratio: 1; }
.offset-low { transform: translateY(80px); }

.wave-strip {
  width: 100%;
  height: 44px;
  overflow: hidden;
  margin-top: 34px;
}

.wave-strip svg, .ambient-wave svg, .standing-wave svg { width: calc(100% + 100px); height: 100%; animation: wave-drift 200s linear infinite; }
.wave-strip path, .standing-wave path { fill: none; stroke: var(--accent-cool); stroke-width: 1.5; }
.amber-wave path { stroke: var(--accent-warm); }

.hero-wave { width: min(620px, 80vw); margin: 46px auto 0; opacity: 0.78; }
.standing-wave { position: absolute; left: 22px; top: 34px; bottom: 34px; width: 44px; overflow: hidden; opacity: 0.65; }

.deliberation {
  min-height: 115vh;
  padding-top: 7vh;
  padding-bottom: 7vh;
}

.ambient-wave {
  position: absolute;
  left: -40px;
  right: -40px;
  top: 34%;
  height: 260px;
  overflow: hidden;
  opacity: 0.08;
  pointer-events: none;
}

.ambient-wave path { fill: none; stroke: var(--accent-cool); stroke-width: 1.5; }

.deliberation .block { min-height: 230px; padding: 32px; display: flex; flex-direction: column; justify-content: space-between; }
.d-one { grid-column: 1 / span 4; grid-row: 1; }
.d-two { grid-column: 5 / span 3; grid-row: 1; transform: translateY(8px); }
.d-three { grid-column: 8 / span 5; grid-row: 1; }
.d-four { grid-column: 2 / span 3; grid-row: 2; transform: translateY(8px); }
.d-five { grid-column: 5 / span 4; grid-row: 2; }
.d-six { grid-column: 9 / span 3; grid-row: 2; transform: translateY(-8px); }

.verdict {
  margin: 16px 16px 48px;
  min-height: 38vh;
  padding: clamp(34px, 6vw, 76px);
  display: grid;
  align-content: center;
  gap: 22px;
  background: #d0d0d5;
  border-color: var(--accent-warm);
}

.verdict p { max-width: 860px; color: var(--text-secondary); }

.reveal { opacity: 0; transform: translateY(12px); transition: opacity 600ms ease-out, transform 600ms ease-out, border-color 300ms ease; }
.reveal.in-view { opacity: 1; transform: translateY(0); }
.reveal.in-view.offset-low { transform: translateY(80px); }
.reveal.in-view.d-two, .reveal.in-view.d-four { transform: translateY(8px); }
.reveal.in-view.d-six { transform: translateY(-8px); }

.judgment-eye {
  position: fixed;
  left: 0;
  top: 0;
  z-index: 60;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  pointer-events: none;
  background: rgba(90,125,138,0.06);
  transform: translate(calc(var(--cursor-x) - 24px), calc(var(--cursor-y) - 24px));
  transition: width 200ms ease-out, height 200ms ease-out, background 200ms ease-out, transform 200ms ease-out;
}

.judgment-eye.block-focus {
  width: 72px;
  height: 72px;
  background: rgba(90,125,138,0.03);
  transform: translate(calc(var(--cursor-x) - 36px), calc(var(--cursor-y) - 36px));
}

.touch-glow { display: none; }

@keyframes wave-drift { from { transform: translateX(0); } to { transform: translateX(-100px); } }
@keyframes toolbar-pulse { 0%, 100% { opacity: 0.72; } 50% { opacity: 1; } }
@keyframes dot-breathe { 0%, 100% { box-shadow: 0 0 0 0 rgba(90,125,138,0.22), 0 0 9px rgba(90,125,138,0.45); } 50% { box-shadow: 0 0 0 8px rgba(90,125,138,0), 0 0 13px rgba(90,125,138,0.55); } }

@media (max-width: 900px) {
  .toolbar-panel { width: calc(100vw - 32px); justify-content: center; flex-wrap: wrap; gap: 10px 16px; }
  .grid-zone, .deliberation { grid-template-columns: 1fr; }
  .scale-balance, .scale-weight, .scale-mercy, .d-one, .d-two, .d-three, .d-four, .d-five, .d-six { grid-column: 1; grid-row: auto; transform: none; }
  .scale-card, .scale-weight, .deliberation .block { min-height: 280px; }
  .reveal.in-view.offset-low, .reveal.in-view.d-two, .reveal.in-view.d-four, .reveal.in-view.d-six { transform: translateY(0); }
}

@media (hover: none) {
  .judgment-eye { display: none; }
  .touch-glow {
    display: block;
    position: fixed;
    left: var(--cursor-x);
    top: var(--cursor-y);
    width: 96px;
    height: 96px;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    pointer-events: none;
    z-index: 60;
    background: rgba(90,125,138,0.035);
    transition: left 200ms ease-out, top 200ms ease-out;
  }
}
