/* Utility Works Studio. Survey-sheet identity: white paper, blue-black ink, one action blue.
   The only strong colours are the four rank colours, so colour on the page is data. */

@font-face { font-family: "Public Sans"; src: url(/fonts/public-sans-latin-400-normal.woff2) format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Public Sans"; src: url(/fonts/public-sans-latin-400-italic.woff2) format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "Public Sans"; src: url(/fonts/public-sans-latin-600-normal.woff2) format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Public Sans"; src: url(/fonts/public-sans-latin-700-normal.woff2) format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "IBM Plex Mono"; src: url(/fonts/ibm-plex-mono-latin-400-normal.woff2) format("woff2"); font-weight: 400; font-display: swap; }

:root {
  --paper: #ffffff;
  --ink: #1d2a36;
  --ink-2: #536170;
  --rule: #dde3e8;
  --wash: #f3f5f7;
  --action: #1f5b92;
  --action-dark: #17466f;
  --r-top: #1e7d46;
  --r-mid: #e3b13c;
  --r-low: #e3893b;
  --error: #b3362c;
  --measure: 66ch;
  --page: 1120px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; overflow-x: clip; background: var(--paper); color: var(--ink); font: 17px/1.6 "Public Sans", system-ui, sans-serif; font-variant-numeric: tabular-nums; }
a { color: var(--action); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { color: var(--action-dark); }
:focus-visible { outline: 2px solid var(--action); outline-offset: 2px; border-radius: 2px; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 8px; background: var(--paper); padding: 6px 10px; z-index: 2; }
q { quotes: "\201C" "\201D"; }
code { font: 0.9em "IBM Plex Mono", ui-monospace, monospace; }

/* type scale: 14 / 17 / 20 / 26 / 44 */
h1 { font-size: 44px; line-height: 1.08; font-weight: 700; letter-spacing: -0.022em; margin: 0 0 18px; max-width: 22ch; }
h2 { font-size: 26px; line-height: 1.2; font-weight: 700; letter-spacing: -0.012em; margin: 56px 0 14px; }
h3 { font-size: 17px; font-weight: 600; margin: 28px 0 8px; }
p { margin: 0 0 14px; }
.lede { font-size: 20px; line-height: 1.5; color: var(--ink-2); max-width: 58ch; }
.note { font-size: 14px; color: var(--ink-2); }

/* frame */
header.site, main, footer.site { max-width: var(--page); margin: 0 auto; padding-left: 24px; padding-right: 24px; }
header.site { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding-top: 22px; padding-bottom: 22px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font-weight: 700; font-size: 18px; letter-spacing: -0.012em; }
.mark { width: 22px; height: 22px; color: var(--ink); }
header.site nav { display: flex; gap: 26px; flex-wrap: wrap; }
header.site nav a { color: var(--ink-2); text-decoration: none; font-size: 15px; padding: 4px 0; border-bottom: 2px solid transparent; }
header.site nav a:hover { color: var(--ink); }
header.site nav .short { display: none; }
header.site nav a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--ink); }
main > section { margin-top: 64px; }
main > section:first-child { margin-top: 40px; }
footer.site { display: flex; justify-content: space-between; gap: 32px; flex-wrap: wrap; margin-top: 96px; padding-top: 28px; padding-bottom: 40px; border-top: 1px solid var(--rule); font-size: 14px; color: var(--ink-2); }
footer.site p { margin: 0 0 6px; }
.brand-foot { display: flex; align-items: center; gap: 8px; font-weight: 700; color: var(--ink); }
.foot-links p:last-child a { margin-right: 16px; }

/* actions */
.actions { display: flex; align-items: center; flex-wrap: wrap; gap: 14px 22px; margin-top: 26px; }
.button { display: inline-block; background: var(--action); color: #fff; font: 600 16px/1 "Public Sans", sans-serif; padding: 14px 20px; border: 0; border-radius: 6px; text-decoration: none; cursor: pointer; }
.button:hover { background: var(--action-dark); color: #fff; }
.button[disabled] { background: #7d98b3; cursor: progress; }
.quiet { font-weight: 600; }
.price { color: var(--ink-2); font-size: 15px; }

/* home hero: statement left, real scan right */
.hero { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 56px; align-items: center; }
.hero h1 { font-size: 48px; }

/* survey-sheet grid */
.grid-fig { margin: 0; }
.sheet { border: 1px solid var(--ink); padding: 10px 14px 12px; max-width: 460px; }
.sheet-top, .sheet-foot { display: flex; justify-content: space-between; align-items: center; font-size: 12px; color: var(--ink-2); }
.sheet-foot { margin-top: 6px; gap: 8px; }
.north { font-weight: 700; color: var(--ink); border: 1px solid var(--ink); border-radius: 50%; width: 22px; height: 22px; display: inline-grid; place-items: center; font-size: 11px; }
.scale { display: inline-flex; align-items: center; gap: 6px; }
.scale i { display: inline-block; width: 28px; height: 5px; border: 1px solid var(--ink); border-top: 0; }
.geo { display: grid; grid-template-columns: 16px repeat(5, minmax(0, 1fr)); gap: 0; margin-top: 4px; }
.geo .lab { font-size: 12px; font-weight: 600; color: var(--ink-2); display: grid; place-items: center; padding: 2px 0; }
.geo.n3 { grid-template-columns: 16px repeat(3, minmax(0, 1fr)); }
.geo.n7 { grid-template-columns: 16px repeat(7, minmax(0, 1fr)); }
.geo.n9 { grid-template-columns: 16px repeat(9, minmax(0, 1fr)); }
/* each point: a graticule cell with the rank disc inside; empty hatched disc = not found */
.geo .pt { aspect-ratio: 1; display: grid; place-items: center; position: relative; isolation: isolate; font-weight: 700; font-size: clamp(13px, 2.2vw, 17px); border-right: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
.geo .pt::before { content: ""; position: absolute; inset: 13%; border-radius: 50%; z-index: -1; }
.geo .pt.r-top { color: #fff; }
.geo .pt.r-mid, .geo .pt.r-low { color: var(--ink); }
.geo .pt.r-top::before { background: var(--r-top); }
.geo .pt.r-mid::before { background: var(--r-mid); }
.geo .pt.r-low::before { background: var(--r-low); }
/* the business's own location: a ring around its point */
.geo .pt.home::after { content: ""; position: absolute; inset: 5%; border: 2px solid var(--ink); border-radius: 50%; }
.legend i.home { background: transparent; border: 2px solid var(--ink); }
.geo .pt.r-none::before { background: repeating-linear-gradient(135deg, #e3e8ec 0 2px, transparent 2px 6px); border: 1px solid #cdd5dc; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.grid-fig figcaption { font-size: 14px; color: var(--ink-2); max-width: 460px; margin-top: 12px; }
.legend { list-style: none; padding: 0; margin: 10px 0 0; display: flex; flex-wrap: wrap; gap: 6px 18px; font-size: 13px; color: var(--ink-2); max-width: 460px; }
.legend i { display: inline-block; width: 11px; height: 11px; border-radius: 50%; margin-right: 6px; vertical-align: -1px; }
.legend i.r-top { background: var(--r-top); } .legend i.r-mid { background: var(--r-mid); } .legend i.r-low { background: var(--r-low); }
.legend i.r-none { background: repeating-linear-gradient(135deg, #e6eaee 0 2px, transparent 2px 4px); border: 1px solid #cdd5dc; }

/* reading of the scan */
.facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px; margin: 0; }
.facts div { border-top: 2px solid var(--ink); padding-top: 12px; }
.facts dt { font-size: 24px; font-weight: 700; letter-spacing: -0.01em; }
.facts dd { margin: 6px 0 0; color: var(--ink-2); }
.reading .note { margin-top: 22px; font-size: 15px; max-width: var(--measure); }

/* tables */
table.list, table.data, table.spec { border-collapse: collapse; width: 100%; margin-bottom: 18px; }
table.list th, table.data th { text-align: left; font-size: 14px; font-weight: 600; color: var(--ink-2); padding: 8px 12px 8px 0; border-bottom: 1px solid var(--ink); }
table.list td { padding: 16px 16px 16px 0; border-bottom: 1px solid var(--rule); vertical-align: top; }
table.list td:first-child { font-weight: 600; white-space: nowrap; width: 1%; padding-right: 40px; }
table.list td:first-child a { color: var(--ink); text-decoration-color: var(--rule); }
table.list td:first-child a:hover { text-decoration-color: var(--ink); }
table.data td { padding: 8px 12px 8px 0; border-bottom: 1px solid var(--rule); }
table.data tr.self td { font-weight: 600; border-top: 1px solid var(--ink); }
table.spec th { text-align: left; font-weight: 600; padding: 10px 24px 10px 0; border-bottom: 1px solid var(--rule); vertical-align: top; white-space: nowrap; width: 1%; }
table.spec td { padding: 10px 0; border-bottom: 1px solid var(--rule); }
.num, table.list th.num, table.data th.num { text-align: right; white-space: nowrap; }
table.data.fit { width: auto; min-width: 360px; }
table.data.fit td, table.data.fit th { padding-right: 32px; }
table.list tr.group th { text-align: left; font-size: 15px; font-weight: 600; color: var(--ink); padding: 32px 0 6px; border-bottom: 1px solid var(--ink); }
table.spec td.num { text-align: left; white-space: normal; }
table.list td:last-child, table.list th:last-child { padding-right: 0; }
.scroll { overflow-x: auto; }
table.wide { min-width: 640px; }

/* product pages */
.intro .lede { margin-bottom: 0; }
.split { display: grid; grid-template-columns: minmax(0, 460px) minmax(0, 1fr); gap: 56px; align-items: start; }
.split h2 { margin-top: 0; }
.prose { max-width: 760px; }
.prose p, .prose li { max-width: var(--measure); }
.steps { padding-left: 22px; }
.steps li { margin-bottom: 10px; padding-left: 4px; }
pre.code { background: var(--wash); border: 1px solid var(--rule); border-radius: 6px; padding: 14px 16px; overflow-x: auto; font: 14px/1.55 "IBM Plex Mono", ui-monospace, monospace; margin: 0 0 12px; }
details { border-bottom: 1px solid var(--rule); padding: 12px 0; }
details:first-of-type { border-top: 1px solid var(--rule); }
summary { font-weight: 600; cursor: pointer; }
details p { margin: 8px 0 4px; color: var(--ink-2); }
.sample h2 { margin-top: 0; }
.trend { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 40px; align-items: start; margin-top: 16px; }
.spark-wrap { position: relative; padding-left: 30px; }
.spark-wrap .y { position: absolute; left: 0; font-size: 12px; color: var(--ink-2); }
.spark-wrap .y100 { top: 0; } .spark-wrap .y0 { bottom: 0; }
.spark { width: 100%; height: 140px; display: block; border-bottom: 1px solid var(--ink); }
.spark .line { fill: none; stroke: var(--action); stroke-width: 2; vector-effect: non-scaling-stroke; }
.spark .base { stroke: none; }
.spark .peak { fill: var(--action); }
.axis { padding-left: 30px; display: flex; justify-content: space-between; font-size: 13px; color: var(--ink-2); margin-top: 6px; gap: 8px; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; margin-top: 8px; }

/* free checker */
.checker { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 56px; align-items: start; }
.form { display: grid; gap: 6px; max-width: 440px; margin-top: 24px; }
.form label { font-weight: 600; font-size: 15px; margin-top: 10px; display: flex; justify-content: space-between; gap: 12px; }
.form .hint { font-weight: 400; color: var(--ink-2); font-size: 14px; }
.form input { font: 17px "Public Sans", sans-serif; padding: 11px 12px; border: 1px solid #b9c3cc; border-radius: 6px; color: var(--ink); background: var(--paper); width: 100%; }
.form input:focus-visible { outline: 2px solid var(--action); outline-offset: 0; border-color: var(--action); }
.form input[aria-invalid="true"] { border-color: var(--error); }
.form .cf-turnstile { margin-top: 10px; }
.form .button { margin-top: 8px; justify-self: start; }
.form-error { color: var(--error); font-size: 15px; margin: 6px 0 0; }
.checker-out { background: var(--wash); border-radius: 8px; padding: 28px; min-height: 360px; margin-top: 8px; }
.form input::placeholder { color: #8f9aa5; }
.example-label { font-size: 14px; font-weight: 600; color: var(--ink-2); border-bottom: 1px solid var(--rule); padding-bottom: 8px; margin-bottom: 14px; }
.result.example .result-rank, .result.example .result-biz { opacity: .9; }
.result-rank { font-size: 64px; font-weight: 700; line-height: 1; letter-spacing: -0.03em; margin: 8px 0 6px; }
.result-rank.r-top { color: var(--r-top); } .result-rank.r-mid { color: #8a6511; } .result-rank.r-low { color: #a5541a; } .result-rank.r-none { color: var(--ink); font-size: 36px; }
.result-biz { font-weight: 600; margin-bottom: 2px; }
.result-meta { color: var(--ink-2); font-size: 15px; }
.result table.data { margin: 18px 0 20px; background: var(--paper); }
.result table.data td, .result table.data th { padding-left: 10px; }
.result .next { border-top: 1px solid var(--rule); padding-top: 16px; }
.working { color: var(--ink-2); }
.error-box h2 { font-size: 20px; margin: 0 0 8px; }
.next-title { font-size: 20px; margin: 0 0 8px; }
.handoff { padding-left: 22px; margin: 14px 0 18px; }
.handoff li { margin-bottom: 12px; }
.handoff pre.code { margin: 8px 0; font-size: 13px; background: var(--paper); white-space: pre-wrap; overflow-wrap: anywhere; }
.quiet-button { background: var(--paper); color: var(--action); border: 1px solid var(--action); padding: 9px 14px; font-size: 15px; }
.quiet-button:hover { background: var(--wash); color: var(--action-dark); }

/* legal */
.legal h2 { font-size: 20px; margin-top: 32px; }

@media (max-width: 900px) {
  .hero, .split, .checker, .trend { grid-template-columns: minmax(0, 1fr); gap: 36px; }
  .hero h1 { font-size: 38px; }
  .facts { grid-template-columns: minmax(0, 1fr); gap: 20px; }
}
@media (max-width: 600px) {
  body { font-size: 16px; }
  header.site, main, footer.site { padding-left: 16px; padding-right: 16px; }
  header.site { flex-direction: column; align-items: flex-start; gap: 10px; padding-top: 16px; padding-bottom: 10px; }
  header.site nav { gap: 0 18px; }
  header.site nav a { padding: 11px 0; } /* 44 px tap targets */
  h1, .hero h1 { font-size: 32px; }
  h2 { font-size: 22px; margin-top: 44px; }
  .lede { font-size: 18px; }
  main > section { margin-top: 48px; }
  main > section:first-child { margin-top: 20px; }
  table.list td:first-child { white-space: normal; width: auto; padding-right: 16px; }
  table.list thead { display: none; }
  table.list tr { display: grid; grid-template-columns: 1fr auto; padding: 14px 0; border-bottom: 1px solid var(--rule); }
  table.list td { border: 0; padding: 0; }
  table.list tr { grid-template-columns: minmax(0, 1fr); }
  table.list td:nth-child(2) { color: var(--ink-2); font-size: 15px; margin-top: 4px; }
  table.list td.num { text-align: left; font-size: 15px; margin-top: 4px; }
  table.list tr.group { border-bottom: 0; padding-bottom: 0; }
  header.site nav .long { display: none; }
  header.site nav .short { display: inline; }
  .two { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .checker-out { padding: 20px; min-height: 0; }
  .result-rank { font-size: 52px; }
  table.spec th { white-space: normal; width: 44%; font-size: 15px; padding-right: 14px; }
  table.data.fit { width: 100%; min-width: 0; }
  table.data.fit td, table.data.fit th { padding-right: 10px; white-space: normal; }
  table.data.fit td:last-child, table.data.fit th:last-child { padding-right: 0; }
}
/* Turnstile needs 300px: give very small phones the room */
@media (max-width: 340px) { header.site, main, footer.site { padding-left: 10px; padding-right: 10px; } }
@media (prefers-reduced-motion: reduce) { * { scroll-behavior: auto !important; } }

/* subscriber setup and report pages */
.form textarea, .form select { font: 17px "Public Sans", sans-serif; padding: 11px 12px; border: 1px solid #b9c3cc; border-radius: 6px; color: var(--ink); background: var(--paper); width: 100%; }
.form textarea:focus-visible, .form select:focus-visible { outline: 2px solid var(--action); outline-offset: 0; border-color: var(--action); }
.setup-form label { flex-direction: column; justify-content: flex-start; gap: 6px; }
.setup-form fieldset { border: 1px solid var(--rule); border-radius: 6px; padding: 12px 14px; margin: 10px 0 0; display: grid; gap: 8px; }
.setup-form fieldset label { flex-direction: row; font-weight: 400; margin: 0; gap: 8px; align-items: baseline; }
.setup-form fieldset input { width: auto; }
.reading ul .setup-form { display: inline; margin: 0 0 0 8px; }
.reading ul .setup-form .button { margin: 0; padding: 4px 10px; font-size: 14px; }
.plans td .button { padding: 10px 14px; font-size: 15px; white-space: nowrap; }
table.list caption, table.data caption { text-align: left; font-weight: 600; padding: 12px 0 6px; }
.soon-tag { display: inline-block; font-size: 14px; font-weight: 600; color: var(--ink); background: var(--wash); border: 1px solid var(--rule); border-radius: 4px; padding: 3px 8px; margin-right: 8px; white-space: nowrap; }
.data td .setup-form { margin: 0; display: inline; }
.data td .setup-form .button { margin: 0; padding: 4px 10px; font-size: 14px; }
