/* Recruiting page. Builds on style.css (tokens, header, base table styles). */

:root {
  /* Supporting hues, used for icon badges and card stripes only. */
  --coral-soft: #fce8df;
  --coral-deep: #b04a28;
  --sage: #6f7f52;
  --sage-soft: #e8ead4;
  --gold: #a87619;
  --gold-soft: #f7eecf;
  --plum: #8b5a6b;
  --plum-soft: #f0dde2;
  --notice-text: #6b4a10;
  /* Recruiting need: warm means "we want you here". Kept apart from the
     test map's green-is-fast scale on purpose. */
  --need-empty: #b04a28;
  --need-many: #d9663f;
  --need-some: #f0b9a0;
  --need-none: #e3dccb;
  --need-text: #ffffff;
  --open-bg: #fce8df;
  --open-text: #9a3f20;
}

/* Dark: same two cases as style.css (system choice, or the visitor's pick). */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --coral-soft: #3b2219;
    --coral-deep: #f0a184;
    --sage: #a9b98a;
    --sage-soft: #2a2e1f;
    --gold: #e0b45a;
    --gold-soft: #332a14;
    --plum: #d3a2b3;
    --plum-soft: #33222a;
    --notice-text: #e9cf95;
    --need-empty: #e0714a;
    --need-many: #b5573a;
    --need-some: #6e3d2c;
    --need-none: #2f2a21;
    --need-text: #1a0f08;
    --open-bg: #3b2219;
    --open-text: #f5b9a0;
  }
}
:root[data-theme="dark"] {
  --coral-soft: #3b2219;
  --coral-deep: #f0a184;
  --sage: #a9b98a;
  --sage-soft: #2a2e1f;
  --gold: #e0b45a;
  --gold-soft: #332a14;
  --plum: #d3a2b3;
  --plum-soft: #33222a;
  --notice-text: #e9cf95;
  --need-empty: #e0714a;
  --need-many: #b5573a;
  --need-some: #6e3d2c;
  --need-none: #2f2a21;
  --need-text: #1a0f08;
  --open-bg: #3b2219;
  --open-text: #f5b9a0;
}

html { scroll-behavior: smooth; }
/* The tinted band is drawn a full window wide; do not let that add a scrollbar. */
body.join { overflow-x: clip; }
body.join main a, body.join footer a { color: var(--accent); }
body.join main > section { margin: 0; padding: 44px 0 12px; scroll-margin-top: 56px; }
body.join h3 { font-size: 16px; margin: 0 0 8px; }
body.join svg.defs { position: absolute; }

/* ---- page navigation: stays in view on a long page ---- */

.pagenav {
  position: sticky;
  top: 0;
  z-index: 20;
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  backdrop-filter: blur(14px) saturate(140%);
  border-bottom: 1px solid var(--line);
}
.pagenav-in {
  max-width: 1160px;
  margin: 0 auto;
  padding: 8px 20px;
  display: flex;
  align-items: center;
  gap: 4px;
  overflow-x: auto;
  scrollbar-width: none;
}
.pagenav-in::-webkit-scrollbar { display: none; }
.pagenav a {
  flex: none;
  padding: 6px 14px;
  border-radius: 999px;
  color: var(--text-2);
  font-size: 13.5px;
  font-weight: 500;
  text-decoration: none;
  white-space: nowrap;
}
.pagenav a:hover { background: var(--soft); color: var(--text); }
.pagenav a[aria-current="true"] { background: var(--ink); color: #fff; font-weight: 600; }
.pagenav a.go {
  margin-left: auto;
  background: var(--coral);
  color: #fff;
  font-weight: 600;
  box-shadow: 0 3px 10px color-mix(in srgb, var(--coral) 32%, transparent);
}
.pagenav a.go:hover { background: var(--coral-deep); color: #fff; }

/* ---- hero ---- */

.jhero { padding-top: 36px !important; }
.tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 22px;
  padding: 6px 14px;
  border-radius: 999px;
  background: var(--sage-soft);
  border: 1px solid color-mix(in srgb, var(--sage) 25%, transparent);
  color: var(--sage);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.3px;
}
.live-dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; animation: live 2.4s ease-in-out infinite; }
@keyframes live {
  0%, 100% { box-shadow: 0 0 0 0 color-mix(in srgb, currentColor 50%, transparent); }
  50% { box-shadow: 0 0 0 7px transparent; }
}
.jhero h1 {
  margin: 0 0 16px;
  font-family: var(--serif);
  font-size: clamp(30px, 5vw, 48px);
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -1px;
}
.lead { font-size: 16px; line-height: 1.8; color: var(--text-2); max-width: 40em; margin: 0 0 14px; }
.lead strong { color: var(--text); }
.updated { margin: 0 0 26px; font: 12.5px/1.6 var(--mono); color: var(--muted); }
.updated strong { color: var(--coral-deep); font-weight: 700; }

/* The four facts someone decides on, in one band. */
.strip {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin: 0 0 22px;
  padding: 30px 8px 26px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: var(--shadow);
  overflow: hidden;
}
.strip::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 4px;
  background: linear-gradient(90deg, var(--coral), var(--gold), var(--sage), var(--plum));
}
.strip > div {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  column-gap: 16px;
  align-items: center;
  padding: 2px 22px;
  border-left: 1px solid var(--line);
  min-width: 0;
}
.strip > div:first-child { border-left: 0; }
.strip .ibadge { grid-row: span 2; }
.strip dt { align-self: end; font-size: 13px; font-weight: 500; letter-spacing: 0.3px; color: var(--muted); }
.strip dd {
  align-self: start;
  margin: 2px 0 0;
  font: 800 22px/1.25 var(--serif);
  letter-spacing: -0.5px;
  overflow-wrap: anywhere;
}
.strip dd small { display: block; margin-top: 3px; font: 500 12.5px/1.4 var(--sans); letter-spacing: 0; color: var(--muted); }

.ibadge {
  display: inline-grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border-radius: 12px;
  flex: none;
}
.ibadge svg { width: 26px; height: 26px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.ibadge.coral { background: var(--coral-soft); color: var(--coral-deep); }
.ibadge.sage { background: var(--sage-soft); color: var(--sage); }
.ibadge.gold { background: var(--gold-soft); color: var(--gold); }
.ibadge.plum { background: var(--plum-soft); color: var(--plum); }

.notice {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin: 0 0 22px;
  padding: 13px 18px;
  border-radius: 10px;
  background: var(--gold-soft);
  border: 1px solid color-mix(in srgb, var(--gold) 28%, transparent);
  color: var(--notice-text);
  font-size: 13px;
  line-height: 1.65;
}

.actions { display: flex; gap: 12px; flex-wrap: wrap; margin: 0; }
.button {
  display: inline-block;
  padding: 13px 30px;
  border-radius: 999px;
  border: 1.5px solid var(--ink);
  background: transparent;
  color: var(--ink) !important;
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.3px;
  transition: transform 0.2s, box-shadow 0.2s, background-color 0.2s;
}
.button:hover { transform: translateY(-1px); }
.button.primary { background: var(--btn); border-color: var(--btn); color: var(--btn-text) !important; box-shadow: var(--btn-shadow); }
.button.primary:hover { background: var(--btn-hover); border-color: var(--btn-hover); }
:root[data-theme="dark"] .button:not(.primary) { color: var(--ink-deep) !important; border-color: var(--ink-deep); }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .button:not(.primary) { color: var(--ink-deep) !important; border-color: var(--ink-deep); }
}

/* ---- section heading: a number, a title, one line of context ---- */

.zone {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 18px;
  max-width: none;
  margin: 0 0 30px;
  padding: 0 0 0 20px;
}
.zone::before {
  content: "";
  position: absolute;
  left: 0;
  top: 6px;
  bottom: 6px;
  width: 4px;
  border-radius: 2px;
  background: var(--coral);
}
.znum { font: 900 56px/0.9 var(--serif); letter-spacing: -2.5px; color: var(--line-strong); }
.zone h2 { margin: 0 0 6px; font: 800 28px/1.2 var(--serif); letter-spacing: -0.8px; }
.zone p { margin: 0; font-size: 13.5px; color: var(--muted); letter-spacing: 0.2px; }

/* A band with its own tint, edge to edge. */
.band { position: relative; }
.band::before {
  content: "";
  position: absolute;
  z-index: -1;
  top: 16px;
  bottom: -18px;
  left: 50%;
  width: 100vw;
  transform: translateX(-50%);
  background: color-mix(in srgb, var(--panel) 55%, var(--bg));
  border-block: 1px solid var(--line);
}
body.join main > section.band { padding-bottom: 36px; }

/* ---- cards ---- */

.cards, .reqs {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}
.cards li, .reqs li {
  position: relative;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 24px 22px 22px;
  box-shadow: var(--shadow-xs);
  overflow: hidden;
  transition: transform 0.3s, box-shadow 0.3s;
}
.cards li:hover, .reqs li:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.cards li::before, .reqs li::before { content: ""; position: absolute; background: var(--stripe, var(--line-strong)); }
.cards li::before { inset: 0 auto 0 0; width: 4px; }
.reqs li::before { inset: 0 0 auto 0; height: 4px; }
.c1 { --stripe: var(--coral); }
.c2 { --stripe: var(--sage); }
.c3 { --stripe: var(--gold); }
.c4 { --stripe: var(--plum); }
.cards .ibadge { width: 44px; height: 44px; margin-bottom: 14px; }
.cards .ibadge svg { width: 22px; height: 22px; }
.cards p, .reqs p { margin: 0; color: var(--text-2); font-size: 13.5px; line-height: 1.75; }
.cards strong, .reqs strong { color: var(--text); }

.rnum { display: block; margin-bottom: 10px; font: 900 42px/1 var(--serif); letter-spacing: -1.5px; color: var(--soft); }
.reqs .tags { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.reqs .tags span {
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--soft);
  border: 1px solid var(--line);
  color: var(--text-2);
  font-size: 12px;
  font-weight: 500;
  white-space: nowrap;
}
.reqs .big { display: flex; align-items: baseline; gap: 8px; margin-bottom: 10px; }
.reqs .big strong { font: 800 26px/1.2 var(--serif); letter-spacing: -0.5px; color: var(--sage); }
.reqs .big span { font-size: 12px; color: var(--muted); }
.reqs .warn {
  margin-top: 12px;
  padding: 7px 12px;
  border-radius: 6px;
  background: var(--coral-soft);
  border: 1px solid color-mix(in srgb, var(--coral) 22%, transparent);
  color: var(--coral-deep);
  font-size: 12px;
  font-weight: 600;
}

.note {
  margin: 16px 0 0;
  padding: 13px 18px;
  border-radius: 10px;
  background: var(--soft);
  color: var(--text-2);
  font-size: 13.5px;
  line-height: 1.7;
}
.hint { color: var(--muted); font-size: 13.5px; margin: 12px 2px; }

/* ---- the three steps, joined by a line ---- */

.flow { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.flow li { position: relative; display: flex; flex-direction: column; align-items: center; text-align: center; padding: 0 20px; }
/* The connector runs from one circle to the next. */
.flow li + li::before {
  content: "";
  position: absolute;
  top: 61px;
  right: calc(50% + 46px);
  width: calc(100% - 92px);
  height: 2px;
  border-radius: 1px;
  background: linear-gradient(90deg, var(--coral), var(--sage));
}
.fstep { font: 700 10.5px/1 var(--mono); letter-spacing: 2.5px; color: var(--muted); margin-bottom: 14px; }
.fnum {
  display: grid;
  place-items: center;
  width: 68px;
  height: 68px;
  margin-bottom: 20px;
  border-radius: 50%;
  border: 2px solid currentColor;
  font: 800 28px/1 var(--serif);
  transition: transform 0.3s;
}
.flow li:hover .fnum { transform: scale(1.07); }
.fnum.coral { background: var(--coral-soft); color: var(--coral-deep); }
.fnum.sage { background: var(--sage-soft); color: var(--sage); }
.fnum.gold { background: var(--gold-soft); color: var(--gold); }
.flow h3 { font: 700 18px/1.3 var(--serif); margin: 0 0 8px; }
.flow p { margin: 0; max-width: 260px; font-size: 13px; line-height: 1.7; color: var(--text-2); }

/* ---- status ---- */

.totals {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 36px;
  margin: 0;
  padding: 18px 24px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: var(--shadow-xs);
}
.totals dt { order: 2; font-size: 11.5px; letter-spacing: 0.3px; color: var(--muted); }
.totals dd { margin: 0; font: 800 26px/1.1 var(--serif); letter-spacing: -0.5px; font-variant-numeric: tabular-nums; }
.totals > div { display: flex; flex-direction: column; gap: 4px; }
.totals .want dd { color: var(--coral-deep); }
.totals .key { margin-left: auto; flex-direction: row; align-items: center; gap: 14px; font-size: 12px; color: var(--text-2); }
.totals .key span { display: inline-flex; align-items: center; gap: 6px; }
.totals .key i { font-style: normal; }

#need-map {
  margin: 16px 0;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 10px 14px 12px;
  box-shadow: var(--shadow-xs);
}
#map { width: 100%; height: 400px; }
#need-map figcaption { color: var(--muted); font-size: 13px; }

.legend { list-style: none; padding: 0; margin: 4px 0 6px; display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 12px; color: var(--text-2); }
.legend li { display: flex; align-items: center; gap: 6px; }
.swatch { width: 14px; height: 14px; border-radius: 4px; display: inline-block; }

.need-empty { background: var(--need-empty); color: var(--need-text); }
.need-many { background: var(--need-many); color: var(--need-text); }
.need-some { background: var(--need-some); color: var(--text); }
.need-none { background: var(--need-none); color: var(--muted); }

.toolbar {
  position: sticky;
  top: 49px; /* below the page navigation */
  z-index: 10;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin: 0 0 4px;
  padding: 10px 0;
  background: var(--bg);
}
#q {
  flex: 1 1 220px;
  min-width: 0;
  padding: 10px 16px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--panel);
  color: var(--text);
  font: inherit;
  font-size: 14px;
  box-shadow: var(--shadow-xs);
}
#q:focus { outline: none; border-color: var(--ink); box-shadow: 0 0 0 3px color-mix(in srgb, var(--ink) 16%, transparent); }
.seg { display: inline-flex; padding: 3px; gap: 2px; border: 1px solid var(--line); border-radius: 999px; background: var(--panel); box-shadow: var(--shadow-xs); }
.seg label { padding: 6px 14px; border-radius: 999px; cursor: pointer; font-size: 13.5px; color: var(--text-2); }
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg label:has(input:checked) { background: var(--btn); color: var(--btn-text); font-weight: 600; }
.seg label:has(input:focus-visible) { outline: 2px solid var(--accent); outline-offset: 1px; }
.check { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; cursor: pointer; }

/* One card per province, the cities in a short scrolling list. */
.provinces {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr));
  gap: 16px;
  align-items: start;
}
.prov {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: var(--shadow-xs);
  overflow: hidden;
  scroll-margin-top: 118px;
  transition: box-shadow 0.3s;
}
.prov:hover { box-shadow: var(--shadow); }
.prov.target { border-color: var(--coral); box-shadow: 0 0 0 3px color-mix(in srgb, var(--coral) 22%, transparent); }
.prov > summary {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 6px 10px;
  padding: 13px 18px;
  background: color-mix(in srgb, var(--panel) 50%, var(--bg));
  cursor: pointer;
  list-style: none;
}
.prov[open] > summary { border-bottom: 1px solid var(--line); }
.prov > summary::-webkit-details-marker { display: none; }
.pname { font: 700 16px/1.3 var(--serif); letter-spacing: 0.2px; }
.pname::after { content: "▸"; margin-left: 8px; font: 12px var(--sans); color: var(--faint); }
.prov[open] .pname::after { content: "▾"; }
.badge { font-size: 11.5px; font-weight: 600; padding: 3px 10px; border-radius: 999px; white-space: nowrap; }
.plines { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 2px 14px; color: var(--muted); font: 11.5px/1.5 var(--mono); }
.prov[hidden] { display: none; }
.prov > .hint { margin: 8px 18px 0; font-size: 12.5px; }

.pscroll { max-height: 262px; overflow-y: auto; scrollbar-width: thin; }
table.cities { border: 0; }
table.cities th, table.cities td { padding: 8px 10px; }
table.cities thead th { position: sticky; top: 0; z-index: 1; background: var(--panel); font-size: 11.5px; }
table.cities th:first-child { padding-left: 18px; }
table.cities th[scope="row"] { color: var(--muted); font-size: 14px; font-weight: 600; border-left: 3px solid transparent; }
/* A city with something open stands out; the rest sit back. */
table.cities tr:not([data-open=""]) th[scope="row"] { color: var(--text); border-left-color: var(--coral); }
table.cities tbody tr:hover > * { background: var(--soft); }
table.cities th small { margin-left: 6px; font-size: 11px; font-weight: 400; color: var(--muted); }
table.cities tr[hidden] { display: none; }

.slot { display: inline-block; font-size: 12px; padding: 3px 11px; border-radius: 999px; white-space: nowrap; }
.slot.open { background: var(--open-bg); color: var(--open-text); font-weight: 600; }
.slot.priority { background: var(--need-many); color: #fff; }
.slot.full { color: var(--faint); }
.slot.paused { color: var(--faint); border: 1px dashed var(--line-strong); }

/* A line picked in the toolbar: fade the other columns. */
.provinces[data-line="telecom"] [data-line]:not([data-line="telecom"]),
.provinces[data-line="unicom"] [data-line]:not([data-line="unicom"]),
.provinces[data-line="mobile"] [data-line]:not([data-line="mobile"]) { opacity: 0.3; }

/* ---- questions ---- */

.faq { display: grid; gap: 10px; max-width: 860px; }
.faq details { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 0 20px; box-shadow: var(--shadow-xs); }
.faq details[open] { border-color: var(--line-strong); }
.faq summary { cursor: pointer; padding: 15px 0; font-weight: 600; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font: 400 20px/1 var(--mono); color: var(--coral-deep); }
.faq details[open] summary::after { content: "–"; }
.faq p { margin: 0 0 16px; color: var(--text-2); font-size: 14px; line-height: 1.8; }
code { font-family: var(--mono); font-size: 0.9em; background: var(--soft); padding: 2px 6px; border-radius: 4px; overflow-wrap: anywhere; }

/* ---- apply ---- */

.apply {
  padding: 28px 30px;
  border-radius: 20px;
  background: var(--ink-soft);
  border: 1px solid color-mix(in srgb, var(--ink) 18%, transparent);
}
.apply > p:first-child { margin: 0 0 14px; }
.apply .note { background: var(--panel); margin-top: 0; }
.apply .contacts + .note { margin-top: 16px; }
.contacts { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 12px; }
.contacts li { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 12px 20px; box-shadow: var(--shadow-xs); }
.clabel { display: block; color: var(--muted); font-size: 12px; letter-spacing: 0.3px; }
.cvalue, .contacts a { font: 800 20px/1.4 var(--serif); letter-spacing: -0.3px; user-select: all; }

.flow.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.flow.four li { padding: 0 14px; }
.fnum.plum { background: var(--plum-soft); color: var(--plum); }

/* ---- the install command, as it will look ---- */

.cmd-demo, .examples {
  margin: 30px 0 0;
  padding: 22px 26px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: var(--shadow-xs);
}
.cmd-demo ul, .examples ul { margin: 12px 0 0; padding-left: 1.2em; color: var(--text-2); font-size: 13.5px; line-height: 1.85; }
.cmd-demo .hint { margin: 10px 0 0; }
pre.cmd, .cmd-demo pre {
  margin: 0;
  padding: 14px 18px;
  border-radius: 10px;
  background: #1d2420;
  color: #e9efe9;
  font: 13.5px/1.6 var(--mono);
  overflow-x: auto;
  white-space: pre;
}
pre.cmd code, .cmd-demo pre code { background: none; padding: 0; color: inherit; overflow-wrap: normal; }
.ph { color: #f0b9a0; font-style: italic; }

/* ---- pay rules ---- */

.rules { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin: 0; }
.rules > div {
  position: relative;
  padding: 18px 20px 18px 24px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: var(--shadow-xs);
  overflow: hidden;
}
.rules > div::before { content: ""; position: absolute; inset: 0 auto 0 0; width: 4px; background: var(--stripe, var(--line-strong)); }
.rules dt { margin: 0 0 6px; font: 700 15px/1.3 var(--serif); }
.rules dd { margin: 0; color: var(--text-2); font-size: 13.5px; line-height: 1.8; }
.rules strong, .examples strong { color: var(--coral-deep); }
.examples { margin-top: 14px; }
.examples h3 { margin: 0; }

/* ---- the application form ---- */

.aform { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 18px; margin: 0 0 18px; }
.aform .wide { grid-column: 1 / -1; }
.aform label > span, .aform legend { display: block; margin: 0 0 6px; font-size: 13px; font-weight: 600; color: var(--text-2); }
.aform small { font-weight: 400; color: var(--muted); }
.aform fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
.aform input:not([type="radio"]):not([type="checkbox"]), .aform select, .aform textarea, .mform input:not([type="radio"]):not([type="checkbox"]) {
  width: 100%;
  box-sizing: border-box;
  padding: 11px 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--panel);
  color: var(--text);
  font: inherit;
  font-size: 14.5px;
}
.aform textarea { resize: vertical; }
.aform input:focus, .aform select:focus, .aform textarea:focus, .mform input:focus { outline: none; border-color: var(--ink); box-shadow: 0 0 0 3px color-mix(in srgb, var(--ink) 16%, transparent); }
.aform .agree { display: flex; align-items: flex-start; gap: 10px; font-size: 13.5px; color: var(--text-2); cursor: pointer; }
.aform .agree input { margin-top: 3px; }
.aform p { margin: 0; }
.aform button { cursor: pointer; font: inherit; font-weight: 600; }
.aform #f-slot { margin: -6px 2px 0; }
.aform #f-slot.bad { color: var(--coral-deep); }
.selfserve { margin: 20px 0 0; padding-left: 1.2em; color: var(--text-2); font-size: 14px; line-height: 1.9; }
.selfserve strong { color: var(--text); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.apply .ask { margin: 20px 0 10px; color: var(--text-2); font-size: 13.5px; }
a.slot { text-decoration: none; }
a.slot.open:hover { outline: 2px solid var(--coral); outline-offset: 1px; }

/* ---- the applicant's own page ---- */

body.me main { max-width: 860px; }
.me-head { padding: 36px 0 8px; }
.me-head h1 { margin: 6px 0 10px; font: 800 clamp(26px, 4vw, 36px)/1.2 var(--serif); letter-spacing: -0.8px; }
.me-head .sub { margin: 0; color: var(--muted); font: 12.5px/1.6 var(--mono); }
.state { display: inline-block; padding: 4px 12px; border-radius: 999px; font-size: 12px; font-weight: 700; letter-spacing: 0.3px; }
.state.pending { background: var(--gold-soft); color: var(--gold); }
.state.approved { background: var(--sage-soft); color: var(--sage); }
.state.rejected, .state.ended { background: var(--soft); color: var(--muted); }
.track { list-style: none; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin: 18px 0 0; padding: 0; counter-reset: t; }
.track li { padding: 10px 12px; border-radius: 10px; background: var(--soft); color: var(--muted); font-size: 13px; counter-increment: t; }
.track li::before { content: counter(t) " · "; font-family: var(--mono); }
.track li.done { background: var(--sage-soft); color: var(--sage); }
.track li.now { background: var(--coral); color: #fff; font-weight: 600; }
.box {
  margin: 18px 0 0;
  padding: 22px 24px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: var(--shadow-xs);
  scroll-margin-top: 16px;
}
.box > h2 { margin: 0 0 12px; font: 800 20px/1.3 var(--serif); letter-spacing: -0.3px; }
.box > p, .box li { color: var(--text-2); font-size: 14px; line-height: 1.8; }
.box > p { margin: 0 0 10px; }
.box ol, .box ul { margin: 0 0 10px; padding-left: 1.3em; }
.box.hi { border-color: var(--coral); box-shadow: 0 0 0 3px color-mix(in srgb, var(--coral) 18%, transparent); }
.box .link, .auth .link { display: block; margin: 10px 0; padding: 10px 14px; border-radius: 8px; background: var(--soft); font: 13px/1.5 var(--mono); overflow-wrap: anywhere; user-select: all; }
.cmdrow { display: flex; gap: 8px; align-items: stretch; margin: 8px 0 14px; }
.cmdrow pre { flex: 1; min-width: 0; }
.copy { flex: none; padding: 0 16px; border: 1.5px solid var(--ink); border-radius: 10px; background: transparent; color: var(--ink); font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; }
.copy.ok { background: var(--sage); border-color: var(--sage); color: #fff; }
.online { font-weight: 700; color: var(--sage); }
.offline { font-weight: 700; color: var(--coral-deep); }
table.months { width: 100%; font-size: 14px; }
table.months td, table.months th { padding: 9px 10px; text-align: left; }
table.months td.num { font-variant-numeric: tabular-nums; font-family: var(--mono); }
.paid { color: var(--sage); font-weight: 600; }
.mform { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 16px; margin: 6px 0 0; }
.mform .wide { grid-column: 1 / -1; }
.mform label > span, .mform legend { display: block; margin: 0 0 6px; font-size: 13px; font-weight: 600; color: var(--text-2); }
.mform fieldset { border: 0; margin: 0; padding: 0; }
.mform button { cursor: pointer; font: inherit; font-weight: 600; }
.mform .agree { display: flex; gap: 10px; align-items: flex-start; font-size: 13.5px; color: var(--text-2); }
.danger { border-color: var(--coral-deep) !important; color: var(--coral-deep) !important; }
.mform.one { grid-template-columns: minmax(0, 1fr); }
.mform select { width: 100%; box-sizing: border-box; padding: 11px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel); color: var(--text); font: inherit; font-size: 14.5px; }
.auth { max-width: 460px; margin: 40px auto 20px; padding: 28px 30px; background: var(--panel); border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow); }
.auth h1 { margin: 0 0 8px; font: 800 28px/1.2 var(--serif); letter-spacing: -0.6px; }
.auth .sub { margin: 0 0 18px; color: var(--text-2); font-size: 14px; line-height: 1.7; }
.auth .hint { margin: 16px 0 0; }
.auth p { margin: 0 0 12px; }
.err { margin: 0 0 14px; padding: 10px 14px; border-radius: 10px; background: var(--coral-soft); color: var(--coral-deep); font-size: 14px; font-weight: 600; }
.box-flash { margin: 14px 0 0; padding: 10px 14px; border-radius: 10px; background: var(--sage-soft); }
.err.box-flash { background: var(--coral-soft); }
.link.big { font-size: 20px; letter-spacing: 1px; text-align: center; padding: 16px; }
.linkbtn { border: 0; background: none; color: var(--text-2); font: inherit; font-size: 13.5px; cursor: pointer; padding: 6px 8px; }
.linkbtn:hover { color: var(--text); text-decoration: underline; }
.nhead { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin: 0 0 4px; }
.nhead h2 { margin: 0; font: 800 20px/1.3 var(--serif); }
.box .sub { margin: 0 0 12px; color: var(--muted); font: 12.5px/1.6 var(--mono); overflow-wrap: anywhere; }
.opnote { padding: 10px 14px; border-radius: 10px; background: var(--gold-soft); color: var(--notice-text) !important; }
.box details { margin: 12px 0 0; border-top: 1px solid var(--line); padding-top: 10px; }
.box details > summary { cursor: pointer; font-weight: 600; font-size: 14px; color: var(--text-2); }
.box details[open] > summary { margin-bottom: 10px; }
.box details.leave > summary { color: var(--muted); font-weight: 500; font-size: 13px; }
.saved { color: var(--sage); font-weight: 600; }

/* ---- the owner's console: side menu, one section per page ---- */

body.console-page main { max-width: none; margin: 0; padding: 0; }
.brand-sub { margin-left: 8px; font: 500 12px/1 var(--sans); color: var(--muted); letter-spacing: 0.3px; }
.who { font: 12.5px/1 var(--mono); color: var(--muted); }
.site-tools form { display: inline; }
.console { display: grid; grid-template-columns: 200px minmax(0, 1fr); max-width: 1240px; margin: 0 auto; min-height: calc(100vh - 140px); }
.side { position: sticky; top: 0; align-self: start; display: flex; flex-direction: column; gap: 2px; padding: 22px 12px; border-right: 1px solid var(--line); min-height: calc(100vh - 140px); box-sizing: border-box; }
.side a { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 10px; color: var(--text-2); text-decoration: none; font-size: 14px; font-weight: 500; }
.side a:hover { background: var(--soft); color: var(--text); }
.side a[aria-current="page"] { background: var(--ink-soft); color: var(--ink); font-weight: 700; }
.side svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.badge-n { margin-left: auto; min-width: 18px; padding: 1px 6px; border-radius: 999px; background: var(--soft); color: var(--text-2); font: 700 11px/16px var(--mono); font-style: normal; text-align: center; }
.badge-n.hot { background: var(--coral); color: #fff; }
th .badge-n { margin-left: 8px; }
.content { padding: 24px 28px 40px; min-width: 0; }
.phead { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 6px 16px; margin: 0 0 18px; }
.phead h1 { flex: 1 1 100%; margin: 0; font: 800 26px/1.25 var(--serif); letter-spacing: -0.5px; }
.phead p { flex: 1 1 auto; margin: 0; color: var(--muted); font-size: 13.5px; line-height: 1.7; }
.phead .button { margin-left: auto; }
.button.sm { padding: 7px 16px; font-size: 13px; }
.wide-btn { width: 100%; text-align: center; box-sizing: border-box; cursor: pointer; font: inherit; font-weight: 600; }
.alert { display: block; margin: 0 0 10px; padding: 11px 16px; border-radius: 10px; font-size: 14px; text-decoration: none; }
.alert.bad { background: var(--coral-soft); color: var(--coral-deep) !important; font-weight: 600; }
.alert.warn { background: var(--gold-soft); color: var(--notice-text) !important; }
.alert.info { background: var(--sage-soft); color: var(--sage) !important; font-weight: 600; }
.alert::after { content: " →"; }
.tbl-wrap { overflow-x: auto; background: var(--panel); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow-xs); }
.box .tbl-wrap { box-shadow: none; }
table.ntable { width: 100%; border: 0; font-size: 14px; white-space: nowrap; }
table.ntable th, table.ntable td { padding: 11px 14px; text-align: left; }
table.ntable thead th { font-size: 12px; color: var(--muted); font-weight: 600; background: color-mix(in srgb, var(--panel) 50%, var(--bg)); }
table.ntable tbody th { font-weight: 600; }
table.ntable td.num, table.months td.num { font-family: var(--mono); font-variant-numeric: tabular-nums; }
.mono { font-family: var(--mono); font-size: 12.5px; }
.muted { color: var(--muted); }
.pri { margin-left: 6px; padding: 1px 7px; border-radius: 999px; background: var(--need-many); color: #fff; font-size: 11px; }
tr.unread th a { font-weight: 800; }
.box.empty ol { margin: 0 0 14px; }
.tstate { display: inline-block; padding: 2px 10px; border-radius: 999px; font-size: 12px; font-weight: 600; background: var(--soft); color: var(--text-2); }
.tstate.open { background: var(--gold-soft); color: var(--gold); }
.tstate.working { background: var(--ink-soft); color: var(--ink); }
.tstate.solved { background: var(--sage-soft); color: var(--sage); }

/* install commands, one system at a time */
.ostabs { display: inline-flex; gap: 4px; padding: 3px; margin: 0 0 14px; border: 1px solid var(--line); border-radius: 999px; background: var(--bg); }
.ostabs button { padding: 7px 18px; border: 0; border-radius: 999px; background: none; color: var(--text-2); font: inherit; font-size: 13.5px; cursor: pointer; }
.ostabs button[aria-selected="true"] { background: var(--btn); color: var(--btn-text); font-weight: 600; }
.ostabs:not([hidden]) ~ .ospanel h3 { display: none; }
.ospanel { margin: 0 0 8px; }
.ospanel .hint { margin: 10px 0 4px; }

/* seven days, a cell per quarter of an hour */
.timeline { display: grid; gap: 3px; margin: 4px 0 10px; }
.tl-row, .tl-hours { display: grid; grid-template-columns: 52px repeat(96, minmax(0, 1fr)); gap: 1px; align-items: center; }
.tl-hours span { font: 10.5px/1 var(--mono); color: var(--muted); }
.tl-day { font: 11.5px/1 var(--mono); color: var(--text-2); }
.tl-row i, .tl-key i { display: block; height: 16px; border-radius: 2px; background: var(--soft); }
.tl-row i.up, .tl-key i.up { background: #3f9a63; }
.tl-row i.part, .tl-key i.part { background: #e0b34a; }
.tl-row i.down, .tl-key i.down { background: #d4553a; }
.tl-key { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; margin: 0 0 12px; font-size: 12.5px; color: var(--muted); }
.tl-key i { display: inline-block; width: 12px; height: 12px; vertical-align: -1px; margin-right: 4px; }
.outages { margin: 0; padding-left: 1.2em; font-size: 13.5px; color: var(--text-2); line-height: 1.9; }

/* ticket thread */
.thread { display: grid; gap: 10px; margin: 0 0 4px; }
.msg { max-width: 760px; padding: 12px 16px; border-radius: 14px; background: var(--panel); border: 1px solid var(--line); }
.msg.admin { background: var(--sage-soft); border-color: color-mix(in srgb, var(--sage) 30%, transparent); }
.msg .who { margin: 0 0 6px; font: 12px/1.4 var(--mono); color: var(--muted); }
.msg .text { margin: 0; white-space: pre-wrap; overflow-wrap: anywhere; font-size: 14px; line-height: 1.75; }
.mform textarea { width: 100%; box-sizing: border-box; padding: 11px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel); color: var(--text); font: inherit; font-size: 14.5px; resize: vertical; }
.qr { display: flex; align-items: flex-end; gap: 14px; margin: 14px 0 0; }
.qr img { display: block; border: 1px solid var(--line); border-radius: 10px; background: #fff; }

/* sign-in pages: what we offer on the left, the form on the right */
.auth-wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 460px); gap: 0; max-width: 980px; margin: 40px auto 20px; border-radius: 20px; overflow: hidden; box-shadow: var(--shadow); border: 1px solid var(--line); }
.auth-wrap .auth { margin: 0; border: 0; border-radius: 0; box-shadow: none; padding: 40px 38px; }
.auth-side { padding: 44px 40px; background: linear-gradient(160deg, #173a2a, #1f5f3f 60%, #2d7a52); color: #eaf3ec; }
.auth-side .eyebrow { margin: 0 0 14px; font: 12px/1 var(--mono); letter-spacing: 1px; opacity: 0.8; }
.auth-side h2 { margin: 0 0 14px; font: 800 30px/1.25 var(--serif); color: #fff; }
.auth-side > p { margin: 0 0 26px; font-size: 14px; line-height: 1.8; opacity: 0.9; }
.auth-side ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; }
.auth-side li { padding: 14px 0; border-top: 1px solid rgba(255, 255, 255, 0.14); }
.auth-side li strong { display: block; color: #fff; font-size: 15px; margin-bottom: 4px; }
.auth-side li span { font-size: 13px; opacity: 0.8; }

@media (max-width: 1000px) {
  .flow.four { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 30px; }
  .flow.four li:nth-child(3)::before { display: none; }
  .strip { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 22px; }
  .strip > div:nth-child(odd) { border-left: 0; }
  .cards, .reqs { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 720px) {
  body.join main > section { padding-top: 34px; }
  .pagenav-in { padding: 7px 16px; }
  .pagenav a { padding: 6px 11px; font-size: 13px; }
  .pagenav a.go { margin-left: 4px; }
  .strip { grid-template-columns: minmax(0, 1fr); padding: 22px 6px 18px; row-gap: 16px; border-radius: 16px; }
  .strip > div { padding: 2px 14px; column-gap: 14px; border-left: 0; }
  .strip dd { font-size: 20px; }
  .strip dd small { display: inline; margin-left: 8px; }
  .ibadge { width: 42px; height: 42px; border-radius: 10px; }
  .ibadge svg { width: 21px; height: 21px; }
  .znum { font-size: 42px; }
  .zone { gap: 14px; margin-bottom: 22px; padding-left: 16px; }
  .zone h2 { font-size: 23px; }
  .cards, .reqs { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .flow { grid-template-columns: minmax(0, 1fr); gap: 26px; }
  .flow li + li::before { display: none; }
  .totals { gap: 12px 26px; padding: 16px 18px; }
  .totals dd { font-size: 22px; }
  .totals .key { margin-left: 0; width: 100%; }
  .toolbar { top: 45px; }
  #map { height: 300px; }
  .provinces { gap: 10px; }
  .prov { scroll-margin-top: 170px; } /* the sticky toolbar wraps to two rows */
  .pscroll { max-height: none; } /* cards are folded on a phone, so no inner scrolling */
  .apply { padding: 20px 18px; }
  .flow.four { grid-template-columns: minmax(0, 1fr); }
  .cmd-demo, .examples, .box { padding: 18px 16px; }
  .rules, .aform, .mform { grid-template-columns: minmax(0, 1fr); }
  .track { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cmdrow { flex-direction: column; }
  .copy { padding: 9px 16px; }
  /* the side menu becomes a row of tabs above the section */
  .console { grid-template-columns: minmax(0, 1fr); }
  .side { position: static; flex-direction: row; overflow-x: auto; min-height: 0; padding: 8px 12px; border-right: 0; border-bottom: 1px solid var(--line); scrollbar-width: none; }
  .side a { flex: none; padding: 8px 12px; font-size: 13.5px; }
  .side svg { display: none; }
  .content { padding: 18px 16px 32px; }
  .auth-wrap { grid-template-columns: minmax(0, 1fr); margin: 16px 0; }
  .auth-side { padding: 26px 22px; }
  .auth-side h2 { font-size: 24px; }
  .auth-wrap .auth { padding: 26px 22px; }
  .tl-row, .tl-hours { grid-template-columns: 40px repeat(96, minmax(0, 1fr)); gap: 0; }
  .tl-hours span { font-size: 9px; }
  .who { display: none; }
}
