/* The front page: "a letter to ShortKeys users" (Kev picked version 1 of six, 2026-11-17).
   Mockup: .planning/mockups/landing-2026-11/v1-letter.html. Loaded after styles.css by index.html only.
   The site's header, footer and theme toggle stay as they are; this file re-tints the shared tokens to
   warm paper on body.letter and styles the letter itself, every rule scoped so no other page changes. */

body.letter {
    --surface: #faf6ee;
    --surface-alt: #fffdf8;
    --surface-sunken: #f1eadb;
    --ink: #1b1a17;
    --ink-soft: #5a5549;
    --ink-faint: #5f594d;
    --line: #d9d0bd;
    --line-strong: #c4b89f;
    --display: "Segoe UI Variable Display", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", sans-serif;
}

[data-theme="dark"] body.letter {
    --surface: #16140f;
    --surface-alt: #1e1c16;
    --surface-sunken: #25221a;
    --ink: #efe9dc;
    --ink-soft: #b6ae9d;
    --ink-faint: #a69e8d;
    --line: #3a362c;
    --line-strong: #4d4839;
}

.letter main {
    font-size: 1.125rem;
    line-height: 1.7;
    padding-bottom: 4rem;
    overflow-wrap: break-word;
}

.letter .col { max-width: 40rem; margin: 0 auto; padding: 0 16px; }
.letter .wide { max-width: 56rem; margin: 0 auto; padding: 0 16px; }
.letter .wide > .col { padding: 0; }

.letter main a:not(.btn) { text-decoration: underline; text-underline-offset: 0.18em; }
.letter :focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 2px; }

.letter main h1,
.letter main h2,
.letter main h3 { font-family: var(--display); line-height: 1.15; margin: 0; letter-spacing: -0.01em; }
.letter main h1 { font-size: clamp(2.1rem, 7.2vw, 3.4rem); font-weight: 600; letter-spacing: -0.02em; margin: 0.4em 0 0.5em; }
.letter main h2 { font-size: clamp(1.6rem, 5vw, 2.1rem); font-weight: 600; margin: 0 0 0.6em; }
.letter main h3 { font-size: 1.25rem; font-weight: 600; }
.letter main p { margin: 0 0 1.1em; }
.letter main .eyebrow { font-size: 0.875rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-soft); margin: 3.5rem 0 0; font-weight: 600; }
.letter main .lede { font-size: 1.3rem; line-height: 1.6; color: var(--ink); max-width: none; }
.letter .salutation { font-style: italic; color: var(--ink-soft); }

.letter main section { padding: 3.5rem 0 0; }
.letter main hr { border: 0; border-top: 1px solid var(--line); margin: 3.5rem auto 0; max-width: 40rem; }

.letter main .btn { font-size: 1.125rem; padding: 14px 24px; min-height: 48px; touch-action: manipulation; }
.letter .cta-note { font-size: 0.9375rem; color: var(--ink-soft); margin: 0.9em 0 0; }

/* Tables. The site's base table has a 620px minimum for a scrolling wrapper; the letter's tables
   restack into cards below 680px instead, so that minimum goes. */
.letter .tablewrap { margin: 1.6rem 0 0.5rem; }
.letter main table { width: 100%; min-width: 0; border-collapse: collapse; font-size: 1rem; line-height: 1.5; background: var(--surface-alt); border: 1px solid var(--line); }
.letter main caption { text-align: left; font-size: 0.9375rem; color: var(--ink-soft); padding: 0 0 0.6rem; caption-side: top; }
.letter main th,
.letter main td { text-align: left; vertical-align: top; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.letter main thead th { background: transparent; font-size: 0.875rem; letter-spacing: 0.04em; text-transform: uppercase; color: var(--ink-soft); font-weight: 600; border-bottom: 2px solid var(--ink); white-space: normal; }
.letter main tbody th { font-weight: 600; }
.letter main tbody tr:last-child > * { border-bottom: 0; }
.letter .cmp td.us,
.letter .cmp thead th.us { font-weight: 600; }
.letter .cmp td.us { background: var(--surface-sunken); }

@media (max-width: 680px) {
    .letter main table,
    .letter main thead,
    .letter main tbody,
    .letter main tr,
    .letter main th,
    .letter main td { display: block; }
    .letter main thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
    .letter main tbody tr { border-bottom: 1px solid var(--line); padding: 8px 0; }
    .letter main tbody tr:last-child { border-bottom: 0; }
    .letter main th,
    .letter main td { border: 0; padding: 4px 14px; }
    .letter main tbody th { padding-top: 10px; }
    .letter main td[data-label]::before { content: attr(data-label) ": "; color: var(--ink-soft); font-weight: 400; }
    .letter .cmp td.us { background: transparent; }
}

/* Screenshot: the site's light-only / dark-only pair, so it follows the theme toggle too. */
.letter main figure { margin: 2rem 0 0; }
.letter main figure img { width: 100%; height: auto; border: 1px solid var(--line); border-radius: 6px; }
.letter main figure img.dark-only { display: none; }
[data-theme="dark"] .letter main figure img.light-only { display: none; }
[data-theme="dark"] .letter main figure img.dark-only { display: block; }
.letter main figcaption { font-size: 0.9375rem; color: var(--ink-soft); margin-top: 0.7rem; line-height: 1.5; }

/* The demo */
.letter .demo { display: grid; gap: 14px; margin: 1.6rem 0 0; }
.letter .demo > div { border: 1px solid var(--line); background: var(--surface-alt); border-radius: 6px; padding: 14px 16px; }
.letter .demo .label { display: block; font-size: 0.8125rem; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-soft); font-weight: 600; margin-bottom: 8px; }
.letter main pre { margin: 0; font-family: var(--mono); white-space: pre-wrap; overflow-wrap: anywhere; font-size: 0.9375rem; line-height: 1.6; }
.letter main code { white-space: normal; overflow-wrap: anywhere; }
.letter .typed { font-size: 1.4rem; font-family: var(--mono); }

.letter ul.plain { padding-left: 1.2em; margin: 0 0 1.1em; }
.letter ul.plain li { margin-bottom: 0.55em; }

.letter .note { background: var(--surface-sunken); border-left: 4px solid var(--ink); padding: 16px 18px; margin: 1.6rem 0 0; border-radius: 0 6px 6px 0; }
.letter .note h3 { margin-bottom: 0.4em; }
.letter .note p:last-child,
.letter .note ul:last-child { margin-bottom: 0; }

/* Pricing. Own class names (lt-), because styles.css already styles .tiers, .tier and .price for pricing.html. */
.letter .lt-tiers { display: grid; gap: 16px; margin: 1.8rem 0 0; }
@media (min-width: 820px) { .letter .lt-tiers { grid-template-columns: repeat(3, 1fr); } }
.letter .lt-tier { border: 1px solid var(--line); background: var(--surface-alt); border-radius: 6px; padding: 20px 18px; }
.letter .lt-tier.pro { border: 2px solid var(--ink); }
.letter .lt-price { font-family: var(--display); font-size: 2rem; font-weight: 600; line-height: 1.1; margin: 0.4rem 0 0.2rem; }
.letter .lt-price small { font-size: 1rem; font-weight: 400; color: var(--ink-soft); }
.letter .lt-tier .sub { font-size: 0.9375rem; color: var(--ink-soft); margin: 0 0 0.9rem; line-height: 1.5; }
.letter .lt-tier ul { padding-left: 1.1em; margin: 0; font-size: 1rem; line-height: 1.55; }
.letter .lt-tier li { margin-bottom: 0.45em; }
.letter .tagline { font-size: 1.5rem; font-family: var(--display); font-weight: 600; margin: 2rem 0 0.2rem; }
.letter .fineprint { font-size: 0.9375rem; color: var(--ink-soft); }

@media (prefers-reduced-motion: reduce) {
    .letter * { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}
