/* Yes, Singaporean. — brand sheet. Newsreader + Hanken Grotesk, both SIL OFL 1.1, stored in fonts/. */
@font-face {
  font-family: "Newsreader";
  src: url("fonts/newsreader-latin-opsz-normal.woff2") format("woff2");
  font-weight: 200 800; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Newsreader";
  src: url("fonts/newsreader-latin-opsz-italic.woff2") format("woff2");
  font-weight: 200 800; font-style: italic; font-display: swap;
}
@font-face {
  font-family: "Hanken Grotesk";
  src: url("fonts/hanken-grotesk-latin-wght-normal.woff2") format("woff2");
  font-weight: 100 900; font-style: normal; font-display: swap;
}

:root {
  --paper: #f6f1e9;
  --ink: #191512;
  --stone: #6f675f;
  --rule: #e3dbcf;
  --red: #ef3340;
  --serif: "Newsreader", Georgia, "Times New Roman", serif;
  --sans: "Hanken Grotesk", "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font: 400 17px/1.6 var(--sans);
  font-variant-numeric: lining-nums;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.nb { white-space: nowrap; }
.wrap { max-width: 1200px; margin: 0 auto; padding: 0 48px; }

/* Wordmark: the name in sentence case, then the little red dot on the baseline. */
.mark {
  font: 300 25px/1 var(--serif); letter-spacing: -0.02em; white-space: nowrap;
  color: var(--ink); text-decoration: none; display: inline-flex; align-items: baseline;
}
.dot {
  display: inline-block; width: 0.2em; height: 0.2em; border-radius: 50%;
  background: var(--red); margin-left: 0.05em;
}
/* In the wordmark the dot sits about 1.3 times a Newsreader full stop, so it still reads as one. */
.mark .dot { width: 0.24em; height: 0.24em; }
/* A name that doesn't say Singapore carries a line under the wordmark. */
.mark.has-tag { flex-direction: column; align-items: flex-start; gap: 5px; }
.mark .word { display: inline-flex; align-items: baseline; }
.mark .tag { font: 400 12px/1.2 var(--sans); letter-spacing: 0.01em; color: var(--stone); }

header.top { display: flex; align-items: center; justify-content: space-between; padding: 28px 0; }
header.top nav { display: flex; align-items: center; gap: 28px; }
header.top nav a.quiet { color: var(--stone); text-decoration: none; font-size: 15px; }
header.top nav a.quiet:hover { color: var(--ink); }
/* The phone menu (built in): hidden on a wide screen, where the links fit in the bar. */
header.top { position: relative; }
.menu { display: none; }
.menu summary {
  list-style: none; cursor: pointer; font-size: 14px; padding: 11px 18px; border-radius: 999px;
  box-shadow: inset 0 0 0 1px var(--ink); color: var(--ink); user-select: none;
}
.menu summary::-webkit-details-marker { display: none; }
.menu[open] summary { background: var(--ink); color: var(--paper); }
.menu-links {
  position: absolute; left: 0; right: 0; top: 100%; z-index: 10; background: var(--paper);
  border-top: 1px solid var(--ink); display: flex; flex-direction: column;
  /* Open, it covers the rest of the screen: no page text shows cut off under it. */
  min-height: 100vh; min-height: 100dvh;
}
.menu-links a:not(.pill) {
  color: var(--ink); text-decoration: none; font: 400 24px/1.2 var(--serif); padding: 16px 0; border-bottom: 1px solid var(--rule);
}
.menu-links a[aria-current="page"] { color: var(--stone); }
.menu-links .pill { align-self: flex-start; margin: 20px 0 22px; }

.pill {
  display: inline-block; background: var(--ink); color: var(--paper);
  font: 500 15px/1 var(--sans); text-decoration: none; border: 0; cursor: pointer;
  padding: 13px 22px; border-radius: 999px;
}
.pill:hover { background: #000; }
.pill.big { font-size: 17px; padding: 17px 30px; }

/* Hero */
.hero { padding: 104px 0 112px; }
h1 {
  /* At most 86px, so each line of a two-line heading fits the 1104px column on one line. */
  font: 300 clamp(52px, 6vw, 86px)/0.98 var(--serif);
  letter-spacing: -0.02em; margin: 0;
  font-variation-settings: "opsz" 72;
}
.hero .sub { font-size: 22px; line-height: 1.45; max-width: 31ch; margin: 40px 0 0; }
.hero .act { display: flex; align-items: center; gap: 24px; margin-top: 40px; flex-wrap: wrap; }
.hero .act .aside { color: var(--stone); font-size: 15px; }

/* Receipt: the numbers, each with its source right under it */
.receipt {
  border-top: 1px solid var(--ink);
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 48px;
  padding: 40px 0 96px;
}
.receipt.two { grid-template-columns: 1fr 1fr 1fr; }
.num {
  display: block; font: 300 clamp(64px, 7vw, 104px)/1 var(--serif);
  letter-spacing: -0.02em; font-variation-settings: "opsz" 72;
}
.num.red { color: var(--red); }
.receipt .claim { font-size: 19px; margin: 14px 0 6px; max-width: 22ch; }
.src { display: block; color: var(--stone); font-size: 13px; line-height: 1.45; max-width: 34ch; }

/* Editorial sections: heading on the left, text on the right */
section.part {
  border-top: 1px solid var(--rule);
  display: grid; grid-template-columns: 5fr 7fr; gap: 48px;
  padding: 56px 0 72px;
}
section.part h2 {
  font: 300 clamp(32px, 3.4vw, 46px)/1.08 var(--serif);
  letter-spacing: -0.02em; margin: 0; max-width: 13ch;
  font-variation-settings: "opsz" 48;
}
section.part .body p { margin: 0 0 16px; max-width: 46ch; font-size: 18px; }
section.part .body p.small { color: var(--stone); font-size: 15px; }

ol.steps { list-style: none; margin: 0; padding: 0; }
ol.steps li { display: grid; grid-template-columns: 48px 1fr; padding: 18px 0; border-bottom: 1px solid var(--rule); }
ol.steps li:first-child { padding-top: 4px; }
ol.steps .k { font: 400 20px/1.4 var(--serif); color: var(--stone); }
ol.steps strong { display: block; font-weight: 500; font-size: 18px; }
ol.steps span.d { display: block; color: var(--stone); font-size: 15px; margin-top: 2px; }

/* Public-record employer list */
ul.who { list-style: none; margin: 0; padding: 0; columns: 2; column-gap: 40px; }
ul.who li {
  display: flex; justify-content: space-between; gap: 16px; break-inside: avoid;
  padding: 11px 0; border-bottom: 1px solid var(--rule); font-size: 16px;
}
ul.who li b { font: 400 18px/1.3 var(--serif); }
ul.who li.more { color: var(--stone); }
.who-note { margin-top: 18px; }
section.part .body p.src { font-size: 13px; max-width: 60ch; }
section.part .body p.tight { margin-bottom: 4px; }
section.part .body p.tight + p.src { margin-bottom: 16px; }

/* Comparison table */
table.compare { width: 100%; border-collapse: collapse; font-size: 16px; table-layout: fixed; }
table.compare th, table.compare td { text-align: left; padding: 14px 10px; border-bottom: 1px solid var(--rule); vertical-align: top; }
table.compare thead th { font-weight: 500; border-bottom-color: var(--ink); }
table.compare thead small { display: block; font-weight: 400; color: var(--stone); font-size: 13px; }
table.compare tbody th { font-weight: 400; color: var(--stone); }
table.compare tr > :first-child { width: 27%; padding-left: 0; }
table.compare .us { font-weight: 500; }
table.compare td.muted { color: var(--stone); }

/* Two-route table on the renewal page */
table.compare.routes tr > :first-child { width: 22%; }
table.compare.routes td { line-height: 1.45; }
table.compare + p.src { margin-top: 16px; }

/* Where Legal Counsel's text goes; replaced word for word once it lands */
.legal-slot {
  display: inline-block; border: 1px dashed var(--stone); color: var(--stone);
  padding: 4px 8px; font-size: 13px; line-height: 1.4;
}

/* Notes in Legal Counsel's words: the renewal disclaimer, the line under each button, the privacy page */
.hero .note { color: var(--stone); font-size: 15px; line-height: 1.55; max-width: 64ch; margin: 36px 0 0; }
.submit p.fine { color: var(--stone); font-size: 13px; line-height: 1.5; max-width: 52ch; margin: 14px 0 0; }
.check label a { color: var(--ink); }
main.legal section.part .body ul { margin: 0 0 16px; padding-left: 20px; max-width: 46ch; font-size: 18px; }
main.legal section.part .body ul li { margin-bottom: 8px; }
main.legal .hero { padding-bottom: 72px; }

/* Form: no card, no shadow; ruled lines on paper */
section.ask {
  border-top: 1px solid var(--ink);
  display: grid; grid-template-columns: 5fr 7fr; gap: 48px; padding: 56px 0 96px;
}
section.ask h2 {
  font: 300 clamp(40px, 4.6vw, 64px)/1 var(--serif); letter-spacing: -0.02em; margin: 0 0 18px;
  font-variation-settings: "opsz" 72;
}
section.ask .lead p { margin: 0 0 12px; max-width: 30ch; font-size: 18px; }
section.ask .lead p.small { color: var(--stone); font-size: 15px; }
.fields { display: grid; grid-template-columns: 1fr 1fr; column-gap: 28px; }
.field { grid-column: span 2; }
.field.half { grid-column: span 1; }
.field label { display: block; color: var(--stone); font-size: 14px; margin: 22px 0 2px; }
.field label span { color: var(--stone); }
.field input, .field select {
  width: 100%; font: 400 19px/1.3 var(--sans); color: var(--ink);
  background: transparent; border: 0; border-bottom: 1px solid var(--ink); border-radius: 0;
  padding: 8px 0 10px; appearance: none;
}
.field input::placeholder { color: #a39a90; }
.field select {
  background-image: linear-gradient(45deg, transparent 50%, var(--ink) 50%), linear-gradient(135deg, var(--ink) 50%, transparent 50%);
  background-position: calc(100% - 10px) 55%, calc(100% - 5px) 55%;
  background-size: 5px 5px; background-repeat: no-repeat; padding-right: 26px;
}
.field select:invalid { color: #a39a90; }
.field input:focus, .field select:focus { outline: none; border-bottom: 2px solid var(--ink); padding-bottom: 9px; }
.check { display: flex; gap: 12px; align-items: flex-start; margin-top: 22px; font-size: 15px; grid-column: span 2; }
.check input { width: 18px; height: 18px; margin: 3px 0 0; accent-color: var(--ink); flex: none; }
.check label { color: var(--ink); }
.submit { grid-column: span 2; margin-top: 34px; }
.done { display: none; }
.ask.sent form { display: none; }
.ask.sent .done { display: block; }
.done h3 { font: 300 40px/1.05 var(--serif); letter-spacing: -0.02em; margin: 0 0 12px; }
.done p { margin: 0; color: var(--stone); }

footer { border-top: 1px solid var(--rule); padding: 32px 0 56px; color: var(--stone); font-size: 13px; line-height: 1.55; }
footer p { margin: 0 0 8px; max-width: 110ch; }
footer .mark { font-size: 22px; margin-bottom: 18px; }

/* Roles page: ruled rows on paper, like the employer list. Empty, it says so plainly. */
section.roles { border-top: 1px solid var(--ink); padding: 40px 0 96px; }
.empty h2 {
  font: 300 clamp(40px, 4.6vw, 64px)/1 var(--serif); letter-spacing: -0.02em; margin: 0 0 18px;
  font-variation-settings: "opsz" 72;
}
.empty p { font-size: 19px; max-width: 40ch; margin: 0; }
.empty .act, form.act { display: flex; align-items: center; gap: 24px; margin-top: 32px; flex-wrap: wrap; }
.empty .aside { color: var(--stone); font-size: 15px; }
ul.roles-list { list-style: none; margin: 0; padding: 0; }
ul.roles-list li {
  display: grid; grid-template-columns: 6fr 5fr auto; gap: 32px; align-items: center;
  padding: 22px 0; border-bottom: 1px solid var(--rule);
}
ul.roles-list li:first-child { padding-top: 4px; }
.r-main strong { display: block; font: 400 26px/1.2 var(--serif); letter-spacing: -0.01em; }
.r-main span { color: var(--stone); font-size: 16px; }
.r-meta { color: var(--stone); font-size: 15px; display: flex; flex-wrap: wrap; gap: 2px 18px; }
.roles-note { margin-top: 20px; max-width: 70ch; }
.pill.ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.pill.ghost:hover { background: transparent; box-shadow: inset 0 0 0 2px var(--ink); }
.pill:disabled { opacity: 0.55; cursor: default; }
table.compare.review { max-width: 760px; margin: 8px 0 24px; }
.form-error { color: var(--red); font-size: 15px; margin: 14px 0 0; }
/* Shown above a form only while sign-ups are shut. */
.form-shut { font-size: 15px; margin: 0 0 18px; padding-left: 12px; box-shadow: inset 2px 0 0 var(--ink); }
/* A field only bots fill in. */
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

@media (max-width: 860px) {
  body { font-size: 16px; }
  .wrap { padding: 0 22px; }
  header.top { padding: 20px 0; }
  header.top nav { gap: 16px; }
  header.top nav a.quiet, header.top nav > a.pill { display: none; }
  .menu { display: block; }
  .mark { font-size: 22px; }
  .pill { padding: 11px 18px; font-size: 14px; }
  .pill.big { font-size: 16px; padding: 15px 26px; }
  .hero { padding: 48px 0 64px; }
  h1 { font-size: 54px; line-height: 0.98; }
  br.d { display: none; }
  .hero .sub { font-size: 19px; margin-top: 26px; }
  .hero .act { margin-top: 30px; gap: 16px; }
  .receipt, .receipt.two { grid-template-columns: 1fr; gap: 30px; padding: 28px 0 56px; }
  .num { font-size: 72px; }
  .receipt .claim { font-size: 18px; margin-top: 8px; }
  section.part, section.ask { grid-template-columns: 1fr; gap: 22px; padding: 40px 0 48px; }
  section.part h2 { font-size: 34px; }
  section.part .body p { font-size: 17px; }
  main.legal section.part .body ul { font-size: 17px; }
  .hero .note { font-size: 14px; margin-top: 26px; }
  ul.who { columns: 1; }
  table.compare { font-size: 13px; }
  table.compare th, table.compare td { padding: 11px 4px; }
  table.compare thead small { font-size: 11px; }
  .fields { grid-template-columns: 1fr; }
  .field, .field.half, .check, .submit { grid-column: span 1; }
  .submit .pill { width: 100%; }
  section.roles { padding: 28px 0 56px; }
  .empty p { font-size: 18px; }
  ul.roles-list li { grid-template-columns: 1fr; gap: 10px; }
  ul.roles-list li .pill { justify-self: start; margin-top: 6px; }
  .r-main strong { font-size: 23px; }
}
