/*
  oklart.com/mail. The same black, white and grey as the app on mail.oklart.com, in the same typeface.

  The page is a grey desk. The one thing that lies on it as a white sheet is the letter in the middle of the
  first screen: the same letter as its reader sees it, and as it lies stored with us. What is not readable
  stands in grey, as the o in the logo does.

  No script: the page is plain HTML and this one stylesheet. The switch between light and dark is a checkbox,
  so the choice lasts while the page is open.
*/

@font-face { font-family: "Instrument Sans"; src: url("/mail/fonts/instrument-sans-latin-standard-normal.woff2") format("woff2"); font-weight: 400 700; font-stretch: 75% 100%; font-display: swap; 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; }
@font-face { font-family: "Instrument Sans"; src: url("/mail/fonts/instrument-sans-latin-ext-standard-normal.woff2") format("woff2"); font-weight: 400 700; font-stretch: 75% 100%; font-display: swap; 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-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }

:root {
  --desk: #efefec;
  --paper: #ffffff;
  --ink: #000000;
  --read: #595959;
  --faint: #696969;
  --ghost: #bdbdba;
  --line: #e2e2df;
  --inv: #000000;
  --on-inv: #ffffff;
  --logo-o: #b4b4b0;
  --shade: 14px 26px 50px -22px rgba(0, 0, 0, 0.34), 0 0 0 1px rgba(0, 0, 0, 0.03);
  --text: "Instrument Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  color-scheme: light;
}
/* Dark, while the switch is on. */
:root:has(#mode:checked) {
  --desk: #0b0b0b;
  --paper: #1b1b1b;
  --ink: #ffffff;
  --read: #b0b0b0;
  --faint: #8c8c8c;
  --ghost: #4c4c4c;
  --line: #303030;
  --inv: #ffffff;
  --on-inv: #000000;
  --logo-o: #666666;
  --shade: 14px 26px 50px -22px rgba(0, 0, 0, 0.9), 0 0 0 1px rgba(255, 255, 255, 0.05);
  color-scheme: dark;
}
@media (prefers-contrast: more) {
  :root { --read: #333333; --faint: #4a4a4a; --ghost: #7a7a7a; --logo-o: #7a7a7a; }
  :root:has(#mode:checked) { --read: #dddddd; --faint: #c2c2c2; --ghost: #9a9a9a; --logo-o: #9a9a9a; }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; background: var(--desk); }
body { margin: 0; background: var(--desk); color: var(--ink); font: 400 18px/1.5 var(--text); -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
h1, h2, h3, p, ul, dl, dd, figure, fieldset { margin: 0; padding: 0; }
ul { list-style: none; }
fieldset { border: 0; min-width: 0; }
h1, h2 { font-weight: 600; line-height: 1; letter-spacing: -0.05em; }
h3 { font-weight: 700; letter-spacing: -0.015em; }
a { color: inherit; text-decoration: underline; text-underline-offset: 0.2em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
strong { font-weight: 700; }
::selection { background: var(--inv); color: var(--on-inv); }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.wrap { width: 100%; max-width: 1380px; margin-inline: auto; padding-inline: 60px; }
.ghost { color: var(--ghost); }

/* ---- the top row ---------------------------------------------------------------------------------- */
.top { display: flex; align-items: center; justify-content: space-between; gap: 20px; height: 76px; }
.logo { display: inline-flex; align-items: baseline; font-size: 26px; font-weight: 700; letter-spacing: -0.05em; line-height: 1; white-space: nowrap; text-decoration: none; }
.logo-o { color: var(--logo-o); }
.logo-product { margin-left: 0.3em; font-weight: 400; letter-spacing: -0.03em; }
/* On a program's pages the logo is two links: oklart leads to the front page, the program's name to its own first page. */
.logo a { color: inherit; text-decoration: none; }
.logo a:hover { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 0.14em; }
.top-right { display: flex; align-items: center; gap: 30px; font-size: 16px; color: var(--read); white-space: nowrap; }
.top-link, .mode { text-decoration: none; cursor: pointer; }
.top-link:hover, .mode:hover { color: var(--ink); }
.mode-input { position: absolute; opacity: 0; pointer-events: none; }
.mode-input:focus-visible + .mode { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 4px; }
.to-light, :root:has(#mode:checked) .to-dark { display: none; }
:root:has(#mode:checked) .to-light { display: inline; }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 24px; border: 0; border-radius: 22px; background: var(--inv); color: var(--on-inv); font: 600 16px/1 var(--text); text-decoration: none; white-space: nowrap; cursor: pointer; }
.btn:hover { opacity: 0.86; }
.btn-big { min-height: 54px; padding: 0 32px; border-radius: 27px; font-size: 18px; }
/* the second of two choices: the same pill, drawn as an outline */
.btn-line { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--ink); }

/* ---- the first screen: the sentence, the two ways in, the letter --------------------------------------- */
.hero { padding-top: 34px; padding-bottom: 40px; }
.hero h1 { display: grid; font-size: clamp(46px, 8.6vw, 132px); line-height: 0.96; letter-spacing: -0.058em; margin-left: -0.04em; }
.hero-cols { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: 60px 80px; align-items: start; margin-top: 64px; }
.lead { max-width: 480px; font-size: 24px; line-height: 1.34; letter-spacing: -0.015em; color: var(--read); }
.ways { display: grid; grid-template-columns: repeat(2, max-content); gap: 30px 34px; margin-top: 42px; }
.ways p { max-width: 232px; margin: 12px 4px 0; font-size: 15.5px; line-height: 1.4; color: var(--faint); }

.letter-tabs { display: flex; gap: 24px; margin: 0 0 14px 2px; font-size: 17px; color: var(--faint); }
.letter-tabs input { position: absolute; opacity: 0; pointer-events: none; }
.letter-tabs label { cursor: pointer; }
.letter-tabs label:hover { color: var(--ink); }
.letter-tabs input:checked + label { color: var(--ink); font-weight: 700; text-decoration: underline; text-underline-offset: 0.35em; text-decoration-thickness: 2px; }
.letter-tabs input:focus-visible + label { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 4px; }
.sheet { min-height: 330px; padding: 46px 52px; border-radius: 5px; background: var(--paper); box-shadow: var(--shade); }
.letter-meta { display: grid; grid-template-columns: max-content 1fr; gap: 4px 18px; margin-bottom: 26px; font-size: 16px; }
.letter-meta dt { color: var(--faint); }
.letter-meta dd { font-weight: 600; overflow-wrap: anywhere; }
.letter-text { display: grid; gap: 14px; font-size: 21px; line-height: 1.5; }
.cipher { font-family: var(--mono); font-size: 0.86em; font-weight: 400; line-height: 1.6; color: var(--faint); overflow-wrap: anywhere; }
.letter figcaption { margin: 16px 2px 0; font-size: 15.5px; color: var(--faint); }
/* One of the two readings is shown: the reader's, or ours. */
.us, .letter:has(#r-us:checked) .you { display: none; }
.letter:has(#r-us:checked) .us { display: block; }
.letter:has(#r-us:checked) dd .us, .letter:has(#r-us:checked) figcaption .us { display: inline; }

/* ---- the sections ----------------------------------------------------------------------------------- */
.block { padding-top: 130px; }
.block h2, .closing h2 { font-size: clamp(36px, 4.6vw, 66px); max-width: 16ch; }
.block-lead { max-width: 560px; margin-top: 18px; font-size: 22px; line-height: 1.36; letter-spacing: -0.01em; color: var(--read); }
.gets { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 34px 80px; margin-top: 50px; }
.gets dt { font-size: 21px; font-weight: 700; letter-spacing: -0.02em; }
.gets dd { max-width: 520px; margin-top: 4px; color: var(--read); }

.ledger { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 40px 80px; margin-top: 50px; }
.ledger h3 { margin-bottom: 14px; font-size: 21px; letter-spacing: -0.02em; }
.ledger ul { display: grid; gap: 10px; max-width: 520px; }
/* What we cannot read stands in grey here too. What we can see stands in black. */
.ledger-sealed li { color: var(--faint); }
/* Each thing we can see carries its reason right under it, so nobody has to guess what the line means. */
.ledger-open ul { gap: 24px; }
.ledger-open li strong { display: block; font-weight: 600; }
.ledger-open li p { margin-top: 6px; color: var(--read); }
.ledger-open li p + p { margin-top: 10px; }
.ledger-note { max-width: 760px; margin-top: 50px; padding-top: 26px; border-top: 1px solid var(--line); color: var(--read); }
.ledger-note strong { color: var(--ink); }

.choice { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 30px 80px; margin-top: 44px; }
.choice h3 { font-size: clamp(44px, 5.4vw, 78px); font-weight: 600; line-height: 1; letter-spacing: -0.05em; }
.choice p { max-width: 520px; margin-top: 12px; color: var(--read); }

.closing { padding-top: 150px; padding-bottom: 20px; }
.closing p { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 30px; margin-top: 34px; }
.closing-link { color: var(--read); font-size: 17px; }

.foot { display: grid; gap: 4px; margin-top: 110px; padding-top: 26px; padding-bottom: 50px; font-size: 15px; color: var(--faint); }
.foot::before { content: ""; display: block; height: 1px; margin-bottom: 22px; background: var(--line); }

/* ---- narrow screens ----------------------------------------------------------------------------------- */
@media (max-width: 980px) {
  .wrap { padding-inline: 32px; }
  .hero-cols { grid-template-columns: minmax(0, 1fr); gap: 50px; margin-top: 44px; }
  .gets, .ledger, .choice { gap: 30px 44px; }
  .block { padding-top: 100px; }
}
@media (max-width: 640px) {
  body { font-size: 17px; }
  .wrap { padding-inline: 20px; }
  .top { height: 62px; }
  .logo { font-size: 23px; }
  .top-right { gap: 18px; font-size: 15.5px; }
  .top .btn { display: none; }
  .hero { padding-top: 18px; }
  .hero-cols { margin-top: 30px; gap: 44px; }
  .lead { font-size: 20px; }
  .ways { grid-template-columns: minmax(0, 1fr); gap: 22px; margin-top: 30px; }
  .ways .btn { width: 100%; }
  .ways p { max-width: none; }
  .closing .btn { width: 100%; }
  .sheet { min-height: 0; padding: 28px 24px; }
  .letter-text { font-size: 18px; }
  .gets, .ledger, .choice { grid-template-columns: minmax(0, 1fr); }
  .gets { gap: 26px; margin-top: 34px; }
  .ledger, .choice { margin-top: 34px; }
  .block { padding-top: 80px; }
  .block-lead { font-size: 19px; }
  .closing { padding-top: 90px; }
  .foot { margin-top: 70px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }
