/* nutopia: community directory styled after the front of a 4-node block */

@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
  src: url(fonts/archivo-latin-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
  src: url(fonts/archivo-latin.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --fog: #e9edf0;
  --surface: #f6f8f9;
  --ink: #18202b;
  --steel: #56657a;
  --line: #c6cfd8;
  --cobalt: #2f4be0;
  --cobalt-hover: #2238b8;
  --on-cobalt: #ffffff;
  --led-ok: #2e9d6a;
  --led-wait: #e3a231;
  --led-off: #8f9cab;
  --danger: #b4342d;
  --chassis: #1f2935;
  --chassis-edge: #34414f;
  --bay: #28333f;
  --bay-hover: #313e4c;
  --bay-ink: #e7edf3;
  --bay-muted: #9fb0c2;
  --focus: #2f4be0;

  --step--1: 0.875rem;
  --step-0: 1.0625rem;
  --step-1: 1.25rem;
  --step-2: 1.5625rem;
  --step-3: 1.953rem;
  --step-4: clamp(2.2rem, 5.2vw, 3.9rem);

  --gutter: 1rem;
  --radius: 6px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --fog: #111820;
    --surface: #17202a;
    --ink: #e3e9ef;
    --steel: #97a6b7;
    --line: #2d3a48;
    --cobalt: #8297ff;
    --cobalt-hover: #a3b3ff;
    --on-cobalt: #0c1222;
    --led-off: #5d6b7a;
    --danger: #ff8a80;
    --chassis: #1b2530;
    --chassis-edge: #3a4858;
    --bay: #243040;
    --bay-hover: #2d3b4d;
    --focus: #a3b3ff;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --fog: #111820;
  --surface: #17202a;
  --ink: #e3e9ef;
  --steel: #97a6b7;
  --line: #2d3a48;
  --cobalt: #8297ff;
  --cobalt-hover: #a3b3ff;
  --on-cobalt: #0c1222;
  --led-off: #5d6b7a;
  --danger: #ff8a80;
  --chassis: #1b2530;
  --chassis-edge: #3a4858;
  --bay: #243040;
  --bay-hover: #2d3b4d;
  --focus: #a3b3ff;
  color-scheme: dark;
}

@media (min-width: 720px) {
  :root { --gutter: 2rem; }
}

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

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--fog);
  color: var(--ink);
  font-family: "Archivo", system-ui, sans-serif;
  font-size: var(--step-0);
  line-height: 1.55;
  font-stretch: 100%;
  font-variant-numeric: tabular-nums;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main { flex: 1; }

h1, h2, h3 {
  margin: 0;
  line-height: 1.1;
  font-weight: 760;
  text-wrap: balance;
}
h1 { font-size: var(--step-4); font-stretch: 125%; font-weight: 820; letter-spacing: -0.012em; line-height: 1.02; }
h2 { font-size: var(--step-2); font-stretch: 112%; }
h3 { font-size: var(--step-1); }
p { margin: 0 0 1em; }

a { color: var(--cobalt); text-underline-offset: 0.18em; text-decoration-thickness: 1px; }
a:hover { color: var(--cobalt-hover); text-decoration-thickness: 2px; }

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

.wrap { width: 100%; max-width: 74rem; margin-inline: auto; padding-inline: var(--gutter); }

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip { position: absolute; left: 1rem; top: -3rem; background: var(--ink); color: var(--fog); padding: 0.5rem 1rem; z-index: 10; }
.skip:focus { top: 1rem; }

.lead { font-size: var(--step-1); color: var(--steel); max-width: 38rem; line-height: 1.5; }
.break { overflow-wrap: anywhere; }

/* ---------- Header ---------- */

.site-header { border-bottom: 1px solid var(--line); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 4rem; }

.wordmark {
  display: inline-flex; align-items: center; gap: 0.55rem;
  color: var(--ink); text-decoration: none;
  font-weight: 800; font-stretch: 125%; font-size: 1.3rem; letter-spacing: -0.01em;
}
.wordmark:hover { color: var(--ink); }
.mark { width: 1.6rem; height: 1.6rem; }
/* Logo parts: full colour in the header; one muted tone elsewhere, with the cut-outs in the surface colour. */
.mark .m-sun { fill: var(--led-wait); }
.mark .m-block { fill: var(--ink); }
.mark .m-lit { fill: var(--led-ok); }
.mark .m-cut { fill: var(--fog); }

.nav { display: flex; align-items: center; gap: 1.25rem; font-size: var(--step--1); font-weight: 560; }
.nav a { color: var(--ink); text-decoration: none; }
.nav a:hover { color: var(--cobalt); }
.nav .nav-cta { color: var(--cobalt); }
.inline { display: inline; margin: 0; }
.who { color: var(--steel); }
@media (max-width: 560px) { .who { display: none; } }
.linklike { background: none; border: 0; padding: 0; font: inherit; color: var(--ink); cursor: pointer; }
.linklike:hover { color: var(--cobalt); }

.lang { position: relative; }
.lang summary {
  list-style: none; cursor: pointer; padding: 0.3rem 0.6rem;
  border: 1px solid var(--line); border-radius: var(--radius);
}
.lang summary::-webkit-details-marker { display: none; }
.lang summary::after { content: ""; display: inline-block; margin-left: 0.45rem; border: 4px solid transparent; border-top-color: currentColor; transform: translateY(2px); }
.lang ul {
  position: absolute; right: 0; top: calc(100% + 0.4rem); z-index: 5;
  list-style: none; margin: 0; padding: 0.35rem; min-width: 10rem;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: 0 8px 24px -12px rgba(24, 32, 43, 0.35);
}
.lang li a { display: block; padding: 0.4rem 0.6rem; border-radius: 4px; }
.lang li a:hover { background: var(--fog); }
.lang li a[aria-current] { font-weight: 760; }

@media (max-width: 560px) {
  .nav { gap: 0.85rem; }
  .nav > a:first-child { display: none; }
}

/* ---------- Buttons ---------- */

.button {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 2.75rem; padding: 0.55rem 1.15rem;
  font: inherit; font-weight: 640; font-size: var(--step-0); line-height: 1.2;
  color: var(--on-cobalt); background: var(--cobalt);
  border: 1px solid var(--cobalt); border-radius: var(--radius);
  text-decoration: none; cursor: pointer;
}
.button:hover { background: var(--cobalt-hover); border-color: var(--cobalt-hover); color: var(--on-cobalt); }
.button-quiet { background: transparent; color: var(--ink); border-color: var(--line); }
.button-quiet:hover { background: var(--surface); color: var(--ink); border-color: var(--steel); }
.button-danger { background: transparent; color: var(--danger); border-color: var(--danger); }
.button-danger:hover { background: var(--danger); color: var(--surface); border-color: var(--danger); }
.actions, .button-row { display: flex; flex-wrap: wrap; gap: 0.75rem; }

/* ---------- LEDs ---------- */

.led {
  display: inline-block; flex: none;
  width: 0.55rem; height: 0.55rem; border-radius: 50%;
  background: var(--led-off);
}
.led-ok { background: var(--led-ok); box-shadow: 0 0 0 3px color-mix(in srgb, var(--led-ok) 22%, transparent), 0 0 10px var(--led-ok); }
.led-wait { background: var(--led-wait); box-shadow: 0 0 0 3px color-mix(in srgb, var(--led-wait) 25%, transparent); }
.led-off { box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.35); }

/* ---------- Hero and chassis ---------- */

.hero {
  display: grid; gap: 2.5rem; align-items: center;
  padding-block: 3rem 3.5rem;
}
.hero h1 { max-width: 15ch; margin-bottom: 1.25rem; }
.hero .lead { margin-bottom: 1.75rem; }

@media (min-width: 940px) {
  .hero { grid-template-columns: 1.05fr 1fr; gap: 4rem; padding-block: 5rem 5.5rem; }
}

.chassis {
  margin: 0;
  background: var(--chassis);
  border-radius: 12px;
  padding: 0.9rem 0.9rem 0.6rem;
  box-shadow: inset 0 0 0 1px var(--chassis-edge), 0 30px 60px -36px rgba(16, 24, 34, 0.6);
  color: var(--bay-ink);
}
.chassis-head {
  display: flex; align-items: center; gap: 0.6rem;
  padding: 0.15rem 0.35rem 0.8rem;
  font-size: var(--step--1); color: var(--bay-muted);
}

.bays { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.45rem; }
.chassis-note { margin-left: auto; color: var(--bay-muted); }
.chassis-all {
  display: block; margin-top: 0.55rem; padding: 0.35rem 0.35rem 0.1rem;
  color: var(--bay-ink); font-size: var(--step--1); font-weight: 600; text-decoration: none;
}
.chassis-all::after { content: "\00a0\2193"; }
.chassis-all:hover { color: #ffffff; text-decoration: underline; }
.chassis-all:focus-visible { outline-color: var(--led-wait); }

.bay {
  display: grid; grid-template-columns: auto 1fr 3.2rem; align-items: center; gap: 0.95rem;
  min-height: 4.6rem; padding: 0.8rem 0.9rem 0.8rem 1rem;
  background: var(--bay); border-radius: var(--radius);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04), inset 0 -1px 0 rgba(0, 0, 0, 0.25);
  color: var(--bay-ink); text-decoration: none;
}
.bay:hover { background: var(--bay-hover); color: var(--bay-ink); }
.bay:focus-visible { outline-color: var(--led-wait); }
.bay-text { display: flex; flex-direction: column; min-width: 0; }
.bay-title { font-weight: 680; font-size: var(--step-0); line-height: 1.25; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bay-meta { font-size: var(--step--1); color: var(--bay-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bay-empty .bay-title { color: var(--bay-muted); font-weight: 560; }
.bay-logo {
  justify-self: end; display: flex; align-items: center; justify-content: center;
  width: 2.75rem; height: 2.75rem; padding: 0.2rem; overflow: hidden;
  background: #ffffff; border-radius: 6px;
}
.bay-logo img { border-radius: 3px; }
.bay-logo img { display: block; max-width: 100%; max-height: 100%; width: auto; height: auto; }
.vents {
  align-self: stretch;
  background: repeating-linear-gradient(90deg, rgba(0, 0, 0, 0.38) 0 2px, transparent 2px 6px);
  border-radius: 3px; opacity: 0.8;
}

/* One orchestrated moment: the block boots, nodes light up in order. */
@media (prefers-reduced-motion: no-preference) {
  .boot { animation: boot 0.6s ease-out backwards; }
  .bays li:nth-child(1) .boot { animation-delay: 0.25s; }
  .bays li:nth-child(2) .boot { animation-delay: 0.45s; }
  .bays li:nth-child(3) .boot { animation-delay: 0.65s; }
  .bays li:nth-child(4) .boot { animation-delay: 0.85s; }
  @keyframes boot {
    0% { background: var(--led-off); box-shadow: none; }
    45% { background: var(--led-wait); box-shadow: 0 0 10px var(--led-wait); }
  }
}

/* ---------- Catalog ---------- */

.catalog { padding-block: 1rem 4rem; }
.catalog-head { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 1rem 2rem; margin-bottom: 1.25rem; }
.search { display: flex; gap: 0.5rem; flex: 1 1 20rem; max-width: 28rem; }
.search input { flex: 1; min-width: 0; }

.filters { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-bottom: 1.75rem; }
.filters a {
  padding: 0.35rem 0.75rem; border-radius: 999px;
  border: 1px solid var(--line); color: var(--ink); text-decoration: none; font-size: var(--step--1);
}
.filters a:hover { border-color: var(--steel); }
.filters a[aria-current] { background: var(--ink); color: var(--fog); border-color: var(--ink); }
.count { color: var(--steel); margin-left: 0.15rem; }
.filters a[aria-current] .count { color: inherit; opacity: 0.7; }

.inventory { border-top: 2px solid var(--ink); }
.inv-row {
  display: grid; gap: 0.25rem 1.5rem;
  padding: 1.1rem 0; border-bottom: 1px solid var(--line);
}
.inv-head { display: none; }
.inv-main a { font-weight: 700; font-size: var(--step-1); text-decoration: none; color: var(--ink); }
.inv-main a:hover { color: var(--cobalt); text-decoration: underline; }
.inv-summary { display: block; color: var(--steel); margin-top: 0.2rem; max-width: 46rem; }
.inv-cat, .inv-author, .inv-date { font-size: var(--step--1); color: var(--steel); }
.inv-row > .inv-cat, .inv-row > .inv-author, .inv-row > .inv-date { display: inline; }

/* Thumbnail: fixed 16:10 frame, whole image fits, small images are not stretched. */
.inv-thumb { display: block; width: 100%; max-width: 8rem; }
.inv-thumb a {
  display: flex; align-items: center; justify-content: center;
  aspect-ratio: 16 / 10; overflow: hidden;
  background: var(--chassis); border: 1px solid var(--line); border-radius: var(--radius);
}
.inv-thumb img { display: block; max-width: 100%; max-height: 100%; width: auto; height: auto; }
/* Logos sit on a white tile in both themes so dark or transparent logos stay readable. */
/* Logos: a square tile as tall as a 16:10 screenshot thumb (62.5% of its width). */
.inv-thumb a.is-logo { width: 62.5%; aspect-ratio: 1 / 1; padding: 0.3rem; background: #ffffff; }
.inv-thumb a.is-logo img { border-radius: 3px; }
.logo-tile {
  display: inline-flex; align-items: center; justify-content: center; flex: none;
  width: 5rem; height: 5rem; padding: 0.5rem; overflow: hidden;
  background: #ffffff; border: 1px solid var(--line); border-radius: 10px;
}
.logo-tile img { display: block; max-width: 100%; max-height: 100%; width: auto; height: auto; }
.project-head.has-logo { display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: 1.5rem; align-items: center; }
.project-head.has-logo > :not(.project-logo) { grid-column: 2; }
.project-head.has-logo .project-logo { grid-row: 1 / span 1; }
@media (min-width: 760px) {
  .project-head.has-logo .project-logo { width: 6.5rem; height: 6.5rem; grid-row: 1 / span 3; align-self: start; }
}
@media (max-width: 759px) {
  .project-head.has-logo > .lead, .project-head.has-logo > .actions { grid-column: 1 / -1; }
}
.logo-admin { display: flex; align-items: center; gap: 1rem; margin-bottom: 0.75rem; }
.logo-admin .shot-remove { margin: 0; }
.inv-placeholder { width: 34%; opacity: 0.45; }
.inv-placeholder .m-sun, .inv-placeholder .m-block, .inv-placeholder .m-lit { fill: var(--bay-muted); }
.inv-placeholder .m-sun { opacity: 0.6; }
.inv-placeholder .m-cut { fill: var(--chassis); }
.inv-row:hover .inv-thumb a { border-color: var(--steel); }

@media (max-width: 759px) {
  .inv-row { grid-template-columns: 6.5rem auto auto 1fr; column-gap: 1rem; align-items: start; }
  .inv-thumb { grid-row: 1 / span 2; }
  .inv-main { grid-column: 2 / -1; }
  .inv-cat { grid-column: 2; }
  .inv-date { justify-self: end; }
}
@media (max-width: 459px) {
  .inv-row { grid-template-columns: 5rem auto 1fr; }
  .inv-author { display: none !important; }
}
@media (min-width: 760px) {
  .inv-row { grid-template-columns: 8rem minmax(0, 1fr) 12rem 9rem 6.5rem; align-items: center; }
  .inv-head { display: grid; padding: 0.6rem 0; font-size: var(--step--1); font-weight: 640; color: var(--steel); }
}

.pager { display: flex; gap: 1.25rem; align-items: center; justify-content: flex-start; margin-top: 1.5rem; font-size: var(--step--1); }

.empty {
  padding: 2.5rem 1.5rem; text-align: left;
  border: 1px dashed var(--line); border-radius: var(--radius);
}
.empty p { font-size: var(--step-1); margin-bottom: 1rem; }

/* ---------- Project page ---------- */

.project { padding-block: 2rem 4rem; }
.back { display: inline-block; margin-bottom: 1.5rem; font-size: var(--step--1); }
.back::before { content: "\2190\00a0"; }
.project-head { padding-bottom: 2rem; border-bottom: 2px solid var(--ink); margin-bottom: 2rem; }
.project-head h1 { font-size: clamp(2rem, 4.4vw, 3.2rem); font-stretch: 115%; max-width: 22ch; margin-bottom: 1rem; }
.project-head .lead { margin-bottom: 1.5rem; }
.project-body { display: grid; gap: 2.5rem; }
@media (min-width: 860px) {
  .project-body { grid-template-columns: minmax(0, 1fr) 18rem; gap: 4rem; }
}
.prose { max-width: 40rem; }
.prose p { margin-bottom: 1.1em; }
.specs { margin: 0; display: grid; gap: 1rem; align-content: start; }
.specs div { padding-bottom: 1rem; border-bottom: 1px solid var(--line); }
.specs dt { font-size: var(--step--1); color: var(--steel); margin-bottom: 0.15rem; }
.specs dd { margin: 0; font-weight: 600; }

/* Screenshots: fixed 16:10 frames, the whole image always fits (contain), never taller than the screen. */
.shots { display: grid; gap: 0.75rem; margin-bottom: 2.5rem; }
.shot {
  display: block; aspect-ratio: 16 / 10; max-height: 75vh; overflow: hidden;
  border-radius: var(--radius); background: var(--chassis); border: 1px solid var(--line);
  cursor: zoom-in;
  display: flex; align-items: center; justify-content: center;
}
/* Shrink to fit, never stretch small images beyond their real size. */
.shot img { display: block; max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; }
.shot:hover { border-color: var(--steel); }
@media (min-width: 760px) {
  .shots-2, .shots-3 { grid-template-columns: 1fr 1fr; }
  .shots-3 .shot:first-child { grid-column: 1 / -1; }
}

.lightbox {
  display: none; position: fixed; inset: 0; z-index: 50;
  flex-direction: column; align-items: center; justify-content: center; gap: 0.75rem;
  padding: 1rem; background: rgba(10, 14, 20, 0.92);
}
.lightbox:target { display: flex; }
.lightbox-backdrop { position: absolute; inset: 0; cursor: zoom-out; }
.lightbox img {
  position: relative; display: block;
  max-width: 100%; max-height: calc(100vh - 5.5rem); max-height: calc(100dvh - 5.5rem);
  width: auto; height: auto; object-fit: contain;
  border-radius: var(--radius); box-shadow: 0 20px 60px -20px rgba(0, 0, 0, 0.7);
}
.lightbox-bar { position: relative; display: flex; align-items: center; gap: 1.25rem; color: #e7edf3; font-size: var(--step--1); }
.lightbox-bar a { color: #e7edf3; text-underline-offset: 0.2em; }
.lightbox-bar a:hover { color: #ffffff; }
.lightbox-bar a:focus-visible { outline-color: #f2b53a; }
.lightbox-close { margin-left: 0.75rem; font-weight: 700; }

/* ---------- Forms ---------- */

.page-head { padding-block: 3rem 2rem; }
.page-head h1 { font-size: clamp(2rem, 4.6vw, 3.3rem); margin-bottom: 1rem; }
.page-head.narrow { max-width: 44rem; margin-inline: auto; }
.page-head.narrow .actions { margin-top: 1.5rem; }

.submit-layout { display: grid; gap: 3rem; padding-bottom: 4rem; }
@media (min-width: 960px) {
  .submit-layout { grid-template-columns: minmax(0, 40rem) 1fr; gap: 5rem; }
  .process { position: sticky; top: 2rem; align-self: start; }
}

.form fieldset { border: 0; padding: 0; margin: 0 0 2rem; }
.form legend { font-weight: 760; font-stretch: 112%; font-size: var(--step-1); padding: 0; margin-bottom: 1rem; }
.field { margin-bottom: 1.35rem; }
.field label { display: block; font-weight: 620; margin-bottom: 0.35rem; }
.optional { font-weight: 400; color: var(--steel); }
.help { font-size: var(--step--1); color: var(--steel); margin: 0.35rem 0 0; max-width: 36rem; }
.error { font-size: var(--step--1); color: var(--danger); font-weight: 600; margin: 0.35rem 0 0; }

input[type="text"], input[type="email"], input[type="url"], input[type="search"], input[type="password"], select, textarea {
  width: 100%; font: inherit; color: var(--ink);
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 0.6rem 0.75rem; min-height: 2.75rem;
}
textarea { resize: vertical; line-height: 1.5; }
input:hover, select:hover, textarea:hover { border-color: var(--steel); }
input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 3px solid var(--focus); outline-offset: 0; border-color: var(--focus); }
.has-error input, .has-error select, .has-error textarea { border-color: var(--danger); }

.check { display: grid; grid-template-columns: auto 1fr; gap: 0.65rem; align-items: start; }
.check input { width: 1.15rem; height: 1.15rem; margin: 0.2rem 0 0; accent-color: var(--cobalt); }
.check label { font-weight: 400; margin: 0; }
.check .error { grid-column: 2; }

.shot-admin { list-style: none; margin: 0 0 0.75rem; padding: 0; display: flex; flex-wrap: wrap; gap: 0.75rem; }
.shot-admin li { width: 10rem; }
.shot-admin img { display: block; width: 100%; height: 6.25rem; object-fit: cover; object-position: top left; border-radius: var(--radius); border: 1px solid var(--line); }
.shot-remove { display: flex !important; gap: 0.4rem; align-items: center; font-weight: 400 !important; font-size: var(--step--1); margin-top: 0.35rem; }
input[type="file"] { font: inherit; font-size: var(--step--1); max-width: 100%; }
input[type="file"]::file-selector-button {
  font: inherit; font-weight: 620; margin-right: 0.75rem; padding: 0.5rem 0.9rem; cursor: pointer;
  color: var(--ink); background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
}
input[type="file"]::file-selector-button:hover { border-color: var(--steel); }

.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.alert { border-left: 4px solid var(--danger); background: var(--surface); padding: 0.85rem 1rem; margin-bottom: 1.75rem; border-radius: 0 var(--radius) var(--radius) 0; }
.alert p { margin: 0; font-weight: 600; }
.notice { border-left: 4px solid var(--led-ok); background: var(--surface); padding: 0.75rem 1rem; border-radius: 0 var(--radius) var(--radius) 0; margin-bottom: 1.25rem; }

.process h2 { font-size: var(--step-1); margin-bottom: 1rem; }
.process h2 + p { color: var(--steel); }
.process h2:not(:first-child) { margin-top: 2.25rem; }
.process ol { list-style: none; margin: 0; padding: 0; counter-reset: step; }
.process li {
  counter-increment: step; position: relative;
  padding: 0 0 1.25rem 2.6rem;
}
.process li::before {
  content: counter(step); position: absolute; left: 0; top: 0;
  width: 1.75rem; height: 1.75rem; display: grid; place-items: center;
  border-radius: 50%; border: 1px solid var(--ink); font-size: var(--step--1); font-weight: 700;
}
.process li:not(:last-child)::after {
  content: ""; position: absolute; left: 0.87rem; top: 2rem; bottom: 0.25rem; width: 1px; background: var(--line);
}
.process strong { display: block; }
.process li span { color: var(--steel); }

.status-line { display: flex; align-items: center; gap: 0.6rem; color: var(--steel); font-size: var(--step--1); margin-bottom: 1rem; }

.login { margin-top: 1.5rem; max-width: 22rem; }

/* ---------- Admin ---------- */

.admin { padding-block: 2rem 4rem; }
.admin h1 { font-size: clamp(1.8rem, 3.8vw, 2.6rem); margin-bottom: 1.25rem; }
.tabs { display: flex; flex-wrap: wrap; gap: 0.25rem; border-bottom: 1px solid var(--line); margin-bottom: 1.5rem; }
.tabs a {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.6rem 0.9rem; margin-bottom: -1px; color: var(--steel); text-decoration: none; font-weight: 600;
  border-bottom: 2px solid transparent;
}
.tabs a:hover { color: var(--ink); }
.tabs a[aria-current] { color: var(--ink); border-bottom-color: var(--ink); }

.queue { list-style: none; margin: 0; padding: 0; }
.queue-item { display: grid; gap: 1rem; padding: 1.25rem 0; border-bottom: 1px solid var(--line); }
.queue-item { grid-template-columns: 6rem minmax(0, 1fr); column-gap: 1.25rem; }
.queue-thumb { max-width: 6rem; }
.queue-actions { grid-column: 2; }
@media (min-width: 820px) {
  .queue-item { grid-template-columns: 8rem minmax(0, 1fr) auto; align-items: start; }
  .queue-thumb { max-width: 8rem; }
  .queue-actions { grid-column: 3; }
}
.queue-main h2 { font-size: var(--step-1); font-stretch: 100%; margin-bottom: 0.35rem; }
.queue-main h2 a { color: var(--ink); text-decoration: none; }
.queue-main h2 a:hover { color: var(--cobalt); text-decoration: underline; }
.queue-main > p { color: var(--steel); margin-bottom: 0.5rem; }
.queue-meta { display: flex; flex-wrap: wrap; gap: 0.25rem 1.25rem; font-size: var(--step--1); color: var(--steel); }
.queue-actions { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.queue-actions form { margin: 0; }

.admin .form { max-width: 44rem; margin-top: 1.5rem; }
.narrow-form { max-width: 30rem; }
.users { list-style: none; margin: 0 0 3rem; padding: 0; border-top: 2px solid var(--ink); }
.user { display: grid; gap: 0.75rem 2rem; padding: 1.1rem 0; border-bottom: 1px solid var(--line); }
@media (min-width: 900px) { .user { grid-template-columns: 16rem minmax(0, 1fr); align-items: center; } }
.user-id { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.35rem 0.6rem; }
.user-id strong { font-size: var(--step-1); }
.user-you { color: var(--steel); font-size: var(--step--1); }
.user-email { flex-basis: 100%; color: var(--steel); font-size: var(--step--1); overflow-wrap: anywhere; }
.role { font-size: var(--step--1); color: var(--steel); padding: 0.1rem 0.55rem; border: 1px solid var(--line); border-radius: 999px; }
.role-super { color: var(--ink); border-color: var(--ink); font-weight: 640; }
.user-note { margin: 0; font-size: var(--step--1); }
.user-actions { display: flex; flex-wrap: wrap; gap: 0.6rem 1rem; align-items: center; }
.user-actions form { margin: 0; display: flex; gap: 0.5rem; align-items: center; }
.user-pw input { width: 15rem; max-width: 100%; }
.check-inline { display: inline-flex; gap: 0.35rem; align-items: center; font-size: var(--step--1); }
.check-inline input { accent-color: var(--danger); }
.add-user legend { font-size: var(--step-2); }
.danger-zone { max-width: 44rem; margin-top: 3rem; padding-top: 1.5rem; border-top: 1px solid var(--line); }
.danger-zone h2 { font-size: var(--step-1); font-stretch: 100%; margin-bottom: 1rem; }

/* ---------- Description formatting ---------- */

.prose ul, .prose ol { margin: 0 0 1.1em; padding-left: 1.4em; }
.prose p + ul, .prose p + ol { margin-top: -0.6em; }
.prose li { margin-bottom: 0.3em; }
.prose code {
  font-family: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace; font-size: 0.88em;
  background: var(--surface); border: 1px solid var(--line); border-radius: 4px; padding: 0.05em 0.35em;
}
.prose pre {
  margin: 0 0 1.2em; padding: 0.9rem 1rem; overflow-x: auto;
  background: var(--chassis); color: var(--bay-ink); border-radius: var(--radius); line-height: 1.5;
}
.prose pre code { background: none; border: 0; padding: 0; color: inherit; font-size: 0.86rem; }
.prose a { overflow-wrap: anywhere; }

/* ---------- GitHub stats ---------- */

.gh dd { display: flex; flex-direction: column; gap: 0.2rem; font-weight: 500; }
.gh-stat { display: inline-flex; align-items: center; gap: 0.35rem; }
.gh-stat svg { width: 0.95rem; height: 0.95rem; fill: var(--led-wait); }
.gh-archived { color: var(--danger); font-weight: 600; font-size: var(--step--1); }

/* ---------- Report a problem ---------- */

.report { margin-top: 3rem; padding-top: 1.25rem; border-top: 1px solid var(--line); max-width: 40rem; }
.report summary { cursor: pointer; color: var(--steel); font-size: var(--step--1); }
.report summary:hover { color: var(--ink); }
.report-form { margin-top: 1.25rem; }
.report-form fieldset { border: 0; padding: 0; margin: 0 0 1.25rem; }
.report-form legend { font-size: var(--step-0); font-stretch: 100%; font-weight: 620; margin-bottom: 0.5rem; }
.radio { display: flex; gap: 0.55rem; align-items: center; margin-bottom: 0.4rem; }
.radio input { accent-color: var(--cobalt); width: 1.05rem; height: 1.05rem; margin: 0; }
.report-message { color: var(--ink); background: var(--surface); border-left: 3px solid var(--line); padding: 0.5rem 0.75rem; }
.edited { color: var(--led-wait); font-weight: 600; }
.account-email { margin-bottom: 2.5rem; }

/* ---------- Footer ---------- */

.site-footer { border-top: 1px solid var(--line); padding-block: 1.1rem; font-size: 0.8125rem; line-height: 1.45; color: var(--steel); }
.footer-inner { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 0.35rem 0.85rem; align-items: start; }
.footer-inner p { margin: 0; grid-column: 2; }
.footer-links { display: flex; flex-wrap: wrap; gap: 0.3rem 1.25rem; }
.footer-credit { display: block; margin-top: 0.3rem; color: var(--ink); }
.footer-credit a { color: var(--ink); font-weight: 640; }
.footer-credit a:hover { color: var(--cobalt); }
.footer-links a { color: var(--steel); }
.footer-links a:hover { color: var(--ink); }
.footer-mark { width: 1.1rem; height: 1.1rem; margin-top: 0.05rem; opacity: 0.7; grid-row: 1 / span 2; }
.footer-mark .m-sun, .footer-mark .m-block, .footer-mark .m-lit { fill: var(--steel); }
.footer-mark .m-sun { opacity: 0.55; }
.footer-mark .m-cut { fill: var(--fog); }
@media (min-width: 860px) {
  .footer-inner { grid-template-columns: auto minmax(0, 1.15fr) minmax(0, 1fr); column-gap: 2.5rem; }
  .footer-mark { grid-row: auto; }
  .footer-inner p { grid-column: auto; }
  .disclaimer { padding-left: 2.5rem; border-left: 1px solid var(--line); }
  .footer-inner { grid-template-columns: auto minmax(0, 1.15fr) minmax(0, 1fr) auto; }
  .footer-links { flex-direction: column; padding-left: 2.5rem; border-left: 1px solid var(--line); }
}

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