/* mcgann.dev. Warm dark panels, gold lettering, and a parchment drawing sheet. */

@font-face { font-family: "Zilla Slab"; src: url("assets/fonts/zilla-slab-500.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: "Zilla Slab"; src: url("assets/fonts/zilla-slab-700.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: "Alegreya Sans"; src: url("assets/fonts/alegreya-sans-400.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Alegreya Sans"; src: url("assets/fonts/alegreya-sans-400-italic.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "Alegreya Sans"; src: url("assets/fonts/alegreya-sans-500.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: "Alegreya Sans"; src: url("assets/fonts/alegreya-sans-700.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: "IBM Plex Mono"; src: url("assets/fonts/ibm-plex-mono-400.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "IBM Plex Mono"; src: url("assets/fonts/ibm-plex-mono-600.woff2") format("woff2"); font-weight: 600; font-style: normal; font-display: swap; }
/* Layout: a left-aligned masthead over one framed window. Tabs along the window's bottom edge
   switch between a clickable network drawing, a list of work, a console and a path.
   One deliberate look: warm dark panels, gold lettering, and a parchment drawing sheet. */
:root {
  --ground: #130d08;
  --panel: #1f160e;
  --panel-hi: #2b1e12;
  --panel-lo: #170f09;
  --line: #5a4424;
  --line-hi: #8f6d34;
  --gold: #eab94a;
  --gold-soft: #c79c45;
  --parch: #ead9b6;
  --parch-dim: #b9a581;
  --ember: #7a1d13;
  --ember-hi: #9d2b1b;
  --ember-ink: #f6d98a;
  --sheet: #e9d9b2;
  --sheet-hi: #f5ead0;
  --ink: #2c1e11;
  --ink-dim: #6a5435;
  --ink-red: #8f2a19;
  --sel: #f2c8a2;
  --ok: #8fc866;

  --display: "Zilla Slab", "Rockwell", Georgia, serif;
  --display-weight: 700;
  --display-track: -0.005em;
  --text: "Alegreya Sans", "Segoe UI", system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, Menlo, Consolas, monospace;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
  margin: 0;
  background: var(--ground);
  background-image: radial-gradient(1100px 520px at 18% -8%, rgba(190, 118, 40, 0.16), transparent 62%);
  background-repeat: no-repeat;
  color: var(--parch);
  font-family: var(--text);
  font-size: 17px;
  line-height: 1.5;
}
h1, h2, h3, p, ul, ol, dl, dd { margin: 0; }
ul, ol { padding: 0; list-style: none; }
button { font: inherit; color: inherit; cursor: pointer; }
a { color: var(--gold); text-underline-offset: 3px; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }

.wrap {
  max-width: 1360px;
  margin: 0 auto;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
}

/* Masthead */
.mast { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 20px 40px; padding-block: 24px 20px; }
.mast h1 { font-family: var(--display); font-weight: var(--display-weight); letter-spacing: var(--display-track); font-size: clamp(44px, 6vw, 78px); line-height: 0.94; color: var(--gold); text-wrap: balance; }
.mast .role { font-family: var(--display); font-weight: 500; font-size: clamp(20px, 2.2vw, 26px); line-height: 1.2; color: var(--parch); margin-top: 8px; }
.mast .line { color: var(--parch-dim); max-width: 60ch; margin-top: 4px; }
.reach { display: grid; gap: 6px; justify-items: start; }
.reach .where { color: var(--parch-dim); }
.reach .mail { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.reach .addr { font-family: var(--mono); font-size: 15px; color: var(--parch); }

.btn { background: var(--ember); color: var(--ember-ink); border: 1px solid var(--line-hi); border-radius: 3px; padding: 8px 14px; font-weight: 700; font-size: 15px; line-height: 1.2; box-shadow: inset 0 1px 0 rgba(255, 220, 150, 0.18); }
.btn:hover { background: var(--ember-hi); }
.btn.quiet { background: var(--panel-hi); color: var(--parch); }
.btn.quiet:hover { background: #38281a; }

/* Window */
.win { border: 1px solid var(--line-hi); background: var(--panel); box-shadow: 0 0 0 3px var(--panel-lo), 0 0 0 4px var(--line), 0 24px 60px rgba(0, 0, 0, 0.5); }
.win-title { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 12px; padding: 9px 14px; background: var(--panel-hi); border-bottom: 1px solid var(--line); }
.mono-tile { flex: none; width: 34px; height: 34px; display: grid; place-items: center; border: 1px solid var(--line-hi); background: var(--panel-lo); color: var(--gold); font-family: var(--display); font-weight: var(--display-weight); font-size: 17px; }
.win-title h2 { font-family: var(--display); font-weight: var(--display-weight); letter-spacing: var(--display-track); font-size: 22px; line-height: 1.1; color: var(--gold); }
.tabs { display: flex; flex-wrap: wrap; gap: 5px; margin-left: auto; }
.tabs button { background: var(--panel-lo); border: 1px solid var(--line); border-radius: 3px; padding: 7px 16px 8px; color: var(--parch-dim); font-weight: 700; font-size: 16px; line-height: 1.2; }
.tabs button:hover { color: var(--parch); border-color: var(--line-hi); }
.tabs button[aria-selected="true"] { background: var(--ember); color: var(--ember-ink); border-color: var(--line-hi); box-shadow: inset 0 1px 0 rgba(255, 220, 150, 0.18); }
@media (max-width: 620px) { .tabs { margin-left: 0; width: 100%; } .tabs button { flex: 1 1 auto; padding-inline: 8px; } }

.foot { display: flex; flex-wrap: wrap; gap: 6px 24px; justify-content: space-between; color: var(--parch-dim); font-size: 15px; padding-block: 26px 40px; }

/* Shared detail block */
.detail { display: grid; gap: 14px; align-content: start; min-width: 0; }
.detail .kicker { color: var(--parch-dim); font-size: 15px; }
.detail h3 { font-family: var(--display); font-weight: var(--display-weight); letter-spacing: var(--display-track); font-size: 28px; line-height: 1.05; color: var(--gold); text-wrap: balance; }
.detail .sum { font-size: 18px; line-height: 1.45; color: var(--parch); max-width: 58ch; }
.facts { display: grid; gap: 6px; font-size: 16px; }
.facts div { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 10px; }
.facts dt { color: var(--gold-soft); }
.facts dd { color: var(--parch); }
.pts { display: grid; gap: 8px; }
.pts li { display: grid; grid-template-columns: 22px minmax(0, 1fr); gap: 10px; align-items: start; }
.pts li::before { content: ""; width: 14px; height: 14px; margin-top: 5px; border: 1px solid var(--line-hi); background: var(--panel-lo); box-shadow: inset 0 0 0 3px var(--panel-lo), inset 0 0 0 7px var(--gold-soft); }
.acts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.aside { color: var(--parch-dim); font-size: 15px; border-top: 1px solid var(--line); padding-top: 12px; }
.mytools { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; font-size: 16px; }
.mytools span { color: var(--gold-soft); }
.mytools button { background: var(--panel-lo); border: 1px solid var(--line-hi); border-radius: 3px; padding: 5px 10px; color: var(--gold); font-size: 15.5px; }
.mytools button:hover { background: var(--panel-hi); }
.shot { grid-column: 1 / -1; aspect-ratio: 16 / 9; max-width: 760px; width: 100%; display: grid; place-items: center; text-align: center; padding: 20px; border: 1px dashed var(--line-hi); background: var(--panel-lo); color: var(--parch-dim); font-size: 16px; }
.linkish { background: none; border: 0; padding: 0; color: var(--gold); text-decoration: underline; text-underline-offset: 3px; }

/* Network tab */
.net { display: grid; }
@media (min-width: 1040px) { .net { grid-template-columns: minmax(0, 1fr) 320px; } }
.net > div:first-child { min-width: 0; }
.sheet-scroll { overflow-x: auto; background: var(--panel-lo); padding: 12px; min-width: 0; }
.sheet { display: block; width: 100%; min-width: 860px; height: auto; background: var(--sheet); box-shadow: 0 2px 0 rgba(0, 0, 0, 0.5), 0 0 0 1px #000; }
.pan-hint { display: none; color: var(--parch-dim); font-size: 14px; padding: 8px 14px 0; }
@media (max-width: 900px) { .pan-hint { display: block; } }
.net .detail { padding: 20px; border-top: 1px solid var(--line); }
@media (min-width: 1040px) { .net .detail { border-top: 0; border-left: 1px solid var(--line); } }
.picks { display: flex; flex-wrap: wrap; gap: 6px; padding: 12px 14px 14px; border-top: 1px solid var(--line); }
.picks button { background: var(--panel-hi); border: 1px solid var(--line); border-radius: 3px; padding: 6px 10px; font-size: 15px; color: var(--parch); }
.picks button[aria-pressed="true"] { border-color: var(--gold-soft); color: var(--gold); }
@media (min-width: 1040px) { .picks { display: none; } }

/* Drawing styles (on the sheet) */
.sheet text { font-family: var(--text); fill: var(--ink); }
.sheet .host { font-family: var(--mono); font-size: 13px; font-weight: 600; }
.sheet .role { font-size: 11.2px; fill: var(--ink-dim); }
.sheet .lbl { font-size: 12px; fill: var(--ink-dim); font-style: italic; }
.sheet .ztitle { font-size: 13.5px; font-weight: 700; }
.sheet .note { font-size: 12.4px; fill: var(--ink); }
.sheet .ref { font-family: var(--mono); font-size: 9.5px; fill: var(--ink-dim); }
.sheet .tb-title { font-family: var(--display); font-weight: var(--display-weight); font-size: 21px; }
.sheet .frame { fill: none; stroke: var(--ink); }
.sheet .ln { stroke: var(--ink); stroke-width: 1.4; fill: none; }
.sheet .agg-o { stroke: var(--ink); stroke-width: 4.4; fill: none; }
.sheet .agg-i { stroke: var(--sheet); stroke-width: 1.8; fill: none; }
.sheet .tun { stroke: var(--ink); stroke-width: 1.3; stroke-dasharray: 7 5; fill: none; }
.sheet .rep { stroke: var(--ink); stroke-width: 1.6; stroke-dasharray: 1.5 4.5; stroke-linecap: round; fill: none; }
.sheet .pair { fill: none; stroke: var(--ink-dim); stroke-width: 1; }
.sheet .zone { fill: rgba(44, 30, 17, 0.045); stroke: var(--ink-dim); stroke-width: 1; stroke-dasharray: 3 3; }
.sheet .plate { fill: var(--sheet-hi); stroke: var(--ink); stroke-width: 1.4; }
.sheet .band { fill: rgba(44, 30, 17, 0.12); stroke: none; }
.sheet .band-mine { fill: var(--ink); stroke: none; }
.sheet .mark-lt { stroke: var(--sheet-hi); stroke-width: 1.2; fill: none; }
.sheet .dot-lt { fill: var(--sheet-hi); }
.sheet .plate.cov { fill: #f9e6c9; stroke: var(--ink-red); stroke-width: 1.8; stroke-dasharray: 5 3; }
.sheet .mark { stroke: var(--ink); stroke-width: 1; fill: none; }
.sheet .dot { fill: var(--ink); }
.sheet .glyph { fill: var(--sheet-hi); stroke: var(--ink); stroke-width: 1.3; }
.sheet .hit { fill: transparent; }
.sheet .halo { fill: none; stroke: var(--ink-red); stroke-width: 2; stroke-dasharray: 6 4; opacity: 0; }
.sheet .hs { cursor: pointer; }
.sheet .hs:focus { outline: none; }
.sheet .hs:hover .plate, .sheet .hs:hover .glyph, .sheet .hs:focus-visible .plate, .sheet .hs:focus-visible .glyph { fill: #fbf3df; stroke: var(--ink-red); }
.sheet .hs:hover .zone, .sheet .hs:focus-visible .zone { stroke: var(--ink-red); }
.sheet .hs:focus-visible .halo { opacity: 0.55; }
.sheet .hs.sel .plate, .sheet .hs.sel .glyph { fill: var(--sel); stroke: var(--ink-red); stroke-width: 1.8; }
.sheet .hs.sel .zone { fill: rgba(143, 42, 25, 0.07); stroke: var(--ink-red); }
.sheet .hs.sel .halo { opacity: 1; }

/* Work tab */
.work { display: grid; }
@media (min-width: 860px) { .work { grid-template-columns: 320px minmax(0, 1fr); } }
.cats { padding: 14px; display: grid; gap: 12px; align-content: start; background: var(--panel-lo); }
@media (min-width: 860px) { .cats { border-right: 1px solid var(--line); } }
.cat > button { width: 100%; display: flex; justify-content: space-between; align-items: center; gap: 10px; text-align: left; background: var(--panel-hi); border: 1px solid var(--line); padding: 7px 10px; font-family: var(--display); font-weight: var(--display-weight); letter-spacing: var(--display-track); font-size: 19px; line-height: 1.15; color: var(--gold); }
.cat > button .tog { font-family: var(--mono); font-size: 16px; color: var(--gold-soft); }
.cat ul { display: grid; gap: 1px; padding: 6px 0 0; }
.cat li button { width: 100%; text-align: left; background: transparent; border: 1px solid transparent; padding: 6px 10px 6px 22px; font-size: 16.5px; color: var(--parch); }
.cat li button:hover { background: rgba(234, 185, 74, 0.08); }
.cat li button[aria-pressed="true"] { background: linear-gradient(90deg, rgba(234, 185, 74, 0.26), rgba(234, 185, 74, 0.05)); border-color: var(--line); color: #fff3d2; }
.work .detail { padding: 24px; }
@media (min-width: 1180px) { .work .detail.has-mini { grid-template-columns: minmax(0, 1fr) 380px; column-gap: 28px; } .work .detail.has-mini > * { grid-column: 1; } .work .detail.has-mini > .mini { grid-column: 2; grid-row: 1 / span 6; align-self: start; } .work .detail.has-mini > .shot { grid-column: 1 / -1; } }
.mini { display: grid; gap: 8px; background: none; border: 0; padding: 0; text-align: left; color: var(--parch-dim); font-size: 15px; max-width: 420px; }
.mini svg { min-width: 0; }
.mini .hs { pointer-events: none; }
.mini:hover { color: var(--gold); }

/* Console tab */
.con { background: #0e0905; font-family: var(--mono); font-size: 14.5px; line-height: 1.6; color: #e6d3a6; display: grid; grid-template-rows: minmax(0, 1fr) auto auto; min-height: 460px; }
.con-out { padding: 18px 18px 6px; white-space: pre-wrap; overflow-wrap: anywhere; max-height: 520px; overflow-y: auto; }
.con-out .cmd { color: var(--gold); }
.con-out .hi { color: #fff3d2; font-weight: 600; }
.con-out .dim { color: #9a8763; }
.con-out .okc { color: var(--ok); }
.con-chips { display: flex; flex-wrap: wrap; gap: 6px; padding: 8px 18px; }
.con-chips button { background: var(--panel-hi); border: 1px solid var(--line); border-radius: 3px; padding: 6px 10px; font-family: var(--mono); font-size: 13.5px; color: var(--gold); }
.con-chips button:hover { border-color: var(--gold-soft); }
.con-in { display: flex; gap: 10px; align-items: center; padding: 10px 18px 16px; border-top: 1px solid var(--line); }
.con-in label { color: var(--ok); white-space: nowrap; }
.con-in input { flex: 1; min-width: 0; background: transparent; border: 0; outline: 0; color: #fff3d2; font: inherit; padding: 6px 0; }
.con-in:focus-within { box-shadow: inset 0 0 0 1px var(--gold-soft); }

/* Path tab */
.path { padding: 22px 24px 26px; display: grid; gap: 16px; }
.path .lead { color: var(--gold); font-size: 18px; }
.steps { width: 100%; border-collapse: collapse; font-size: 17px; }
.steps th { text-align: left; font-weight: 500; color: var(--gold-soft); padding: 6px 12px 8px 0; border-bottom: 1px solid var(--line); font-size: 15.5px; }
.steps td { padding: 12px 12px 12px 0; border-bottom: 1px solid rgba(90, 68, 36, 0.55); vertical-align: top; }
.steps td:first-child { font-family: var(--mono); font-size: 15px; color: var(--gold); white-space: nowrap; font-variant-numeric: tabular-nums; }
.steps .what { color: #fff3d2; font-weight: 700; }
.steps .where { color: var(--parch-dim); }
.steps tr.now td { background: rgba(234, 185, 74, 0.1); }
.steps .tag { display: inline-block; margin-left: 8px; color: var(--ok); font-size: 15px; font-weight: 500; }
.table-scroll { overflow-x: auto; }
@media (max-width: 620px) { .steps th:nth-child(3), .steps td:nth-child(3) { display: none; } .steps .where-s { display: block; color: var(--parch-dim); font-weight: 400; } }
@media (min-width: 621px) { .steps .where-s { display: none; } }

@media (prefers-reduced-motion: no-preference) { .sheet .halo { transition: opacity 0.15s; } }

/* Without JavaScript */
.nojs { padding: 20px; display: grid; gap: 10px; max-width: 70ch; }

/* 404 */
.notfound { min-height: 70vh; display: grid; align-content: center; gap: 16px; padding-block: 60px; }
.notfound h1 { font-family: var(--display); font-weight: 700; font-size: clamp(40px, 6vw, 72px); line-height: 1; color: var(--gold); }
.notfound p { color: var(--parch-dim); font-size: 19px; }
.notfound .btn { justify-self: start; text-decoration: none; display: inline-block; }
