:root {
  --ink: #111111;
  --muted: #555555;
  --soft: #6b6b6b;
  --line: #e2e2e2;
  --noise: #c9c9c9;
  --paper: #ffffff;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
}

a { color: var(--ink); }
a:hover { color: var(--muted); }

button { font-family: inherit; }

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

/* her lavender highlighter, scanned from her notes */
.hl { position: relative; display: inline-block; }
.hl::before {
  content: "";
  position: absolute;
  left: -5px; right: -5px; top: 14%; bottom: 4%;
  background: url("../assets/highlight.png") center / 100% 100% no-repeat;
  z-index: 0;
}
.hl > span { position: relative; z-index: 1; }

.kicker {
  margin: 0;
  font-size: 13px;
  color: var(--soft);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.btn {
  display: inline-block;
  font-size: 14px;
  text-decoration: none;
  color: var(--ink);
  background: var(--paper);
  border: 1px solid var(--ink);
  padding: 11px 15px;
  cursor: pointer;
  transition: transform .15s ease;
}
.btn:hover { transform: translate(-2px, -2px); color: var(--ink); }
.btn.dark { color: var(--paper); background: var(--ink); }
.btn.dark:hover { color: var(--paper); }
.btn.quiet { color: var(--muted); }

.arrow { height: 15px; width: auto; vertical-align: -2px; }

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

/* ---------- dark mode (switched by the pull chain) ---------- */
html[data-theme="dark"] { --ink: #ececec; --muted: #a8a8a8; --soft: #8a8a8a; --line: #2c2c2c; --noise: #3d3d3d; --paper: #121212; }
html[data-theme="dark"] img:not(.keep-color) { filter: invert(1) hue-rotate(180deg); }
html, body { transition: background-color .5s, color .5s; }

/* ---------- the pull chain, bulb and maintenance guy ---------- */
.lamp-layer { position: fixed; inset: 0; z-index: 50; pointer-events: none; overflow: hidden; }
.chain { position: absolute; top: -210px; left: 50%; margin-left: -12px; width: 24px; display: flex; justify-content: center; cursor: grab; touch-action: none; outline: none; pointer-events: auto; }
.chain:active { cursor: grabbing; }
.chain .sway { display: flex; flex-direction: column; align-items: center; transform-origin: 50% 0; animation: sway 5s ease-in-out infinite; }
.chain.held .sway { animation-play-state: paused; }
@keyframes sway { 0%, 100% { transform: rotate(-2deg); } 50% { transform: rotate(2deg); } }
.chain i { display: block; width: 6px; height: 9px; margin-top: -2px; border: 1.5px solid var(--ink); border-radius: 50%; }
.chain i:nth-child(even) { width: 2px; }
.chain b { display: block; width: 14px; height: 14px; margin-top: -1px; border-radius: 50%; background: var(--ink); }
.chain:focus-visible b { outline: 2px solid var(--ink); outline-offset: 3px; }
.flash { position: fixed; inset: 0; background: #000; opacity: 0; pointer-events: none; }
.bulb { position: absolute; left: 0; top: 0; width: 34px; height: 50px; pointer-events: none; overflow: visible; }
.bulb path, .bulb line { fill: none; stroke: var(--ink); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.bulb.ready { pointer-events: auto; cursor: pointer; }
.walker { position: absolute; left: 0; top: 0; width: 44px; height: 84px; overflow: visible; }
.walker path, .walker line, .walker circle { fill: none; stroke: var(--ink); stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.walker .hat { fill: var(--ink); }
.walker .eye { fill: var(--ink); stroke: none; transition: transform .25s; }
.walker.look .eye { transform: translateX(2px) translateY(1px); }
.bubble { position: absolute; left: 0; top: 0; font-size: 12px; padding: 5px 9px; border: 1.5px solid var(--ink); background: var(--paper); color: var(--ink); border-radius: 12px; white-space: nowrap; }
@media (max-width: 560px) { .chain { left: 58%; } }
html[data-theme="dark"] .hl::before, html[data-theme="dark"] .dot[aria-pressed="true"] span { opacity: .45; }
