/*
 * The pages that are read rather than looked at: support, privacy, about and
 * the engineering journal.
 *
 * Loaded after styles.css, which supplies the palette, the header and the
 * footer. Only what a document needs is added here — a measure narrow enough
 * to read, and headings that separate sections without shouting.
 *
 * Deliberately not part of styles.css: that file is the landing page, where
 * every rule earns its place against a screenshot. None of this is wanted
 * there, and the landing page's weight is on the critical path.
 */

.doc {
  /* 68 characters or so at this size. The landing page's 1180px shell is for
     images sitting beside text; a paragraph that wide is hard to track back. */
  width: min(760px, 100% - 3rem);
  margin: 0 auto;
  padding: 7rem 0 5rem;
}

.doc__kicker {
  font-family: ui-monospace, 'SF Mono', Menlo, monospace;
  font-size: 0.78rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--amber);
  margin: 0 0 0.75rem;
}

.doc h1 {
  font-size: clamp(2rem, 5vw, 2.9rem);
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin: 0 0 1rem;
}

.doc__lede {
  font-size: 1.15rem;
  color: var(--text-dim);
  margin: 0 0 3.5rem;
}

.doc h2 {
  font-size: 1.35rem;
  letter-spacing: -0.01em;
  margin: 3.5rem 0 1rem;
  padding-top: 2rem;
  border-top: 1px solid var(--line);
}

.doc h3 {
  font-size: 1.02rem;
  margin: 2rem 0 0.5rem;
}

.doc p,
.doc li {
  color: var(--text-dim);
}

.doc p {
  margin: 0 0 1.1rem;
}

.doc ul {
  margin: 0 0 1.1rem;
  padding-left: 1.2rem;
}

.doc li {
  margin-bottom: 0.5rem;
}

.doc strong {
  color: var(--text);
  font-weight: 600;
}

.doc a {
  color: var(--amber);
  text-decoration-color: var(--amber-glow);
  text-underline-offset: 3px;
}

.doc a:hover {
  color: var(--amber-hot);
}

/* Keyboard keys and menu paths, which both pages are full of. */
.doc kbd {
  font-family: ui-monospace, 'SF Mono', Menlo, monospace;
  font-size: 0.85em;
  background: var(--ink-2);
  border: 1px solid var(--line-strong);
  border-radius: 5px;
  padding: 0.1em 0.42em;
  color: var(--text);
  white-space: nowrap;
}

/* A question and its answer, kept together so the eye can skip by question. */
.faq {
  border-top: 1px solid var(--line);
  padding: 1.6rem 0 0.5rem;
}

.faq:first-of-type {
  border-top: 0;
}

.faq h3 {
  margin-top: 0;
}

/* The one thing on either page that has to be found without reading: how to
   reach a human. */
.doc__card {
  background: var(--ink-1);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.75rem;
  margin: 0 0 1.5rem;
}

.doc__card p:last-child {
  margin-bottom: 0;
}

/* ------------------------------------------- about and journal pages */

.doc--wide {
  width: min(920px, 100% - 3rem);
}

.doc figure {
  margin: 1.6rem 0 2rem;
}

.doc figure img,
.doc figure svg {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #000;
}

.doc figcaption {
  font-size: 0.85rem;
  color: var(--text-faint);
  margin-top: 0.6rem;
}

/* Before and after, side by side, stacking on a phone. */
.pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.pair figure {
  margin: 0;
}

.pair img {
  aspect-ratio: 16 / 10;
  object-fit: cover;
}

.blackout {
  display: grid;
  place-items: center;
  aspect-ratio: 16 / 10;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #010101;
  color: var(--text-faint);
  font-family: ui-monospace, 'SF Mono', Menlo, monospace;
  font-size: 0.8rem;
  text-align: center;
  padding: 1rem;
}

/* The five beats of an engineering story, labelled down the left. */
.story {
  border-top: 1px solid var(--line);
  padding-top: 2.2rem;
  margin-top: 3rem;
}

.story h2 {
  border: 0;
  padding: 0;
  margin: 0 0 1.2rem;
}

.beats {
  display: grid;
  grid-template-columns: 9.5rem 1fr;
  gap: 0.2rem 1.4rem;
  margin: 0;
}

.beats dt {
  font-family: ui-monospace, 'SF Mono', Menlo, monospace;
  font-size: 0.74rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--amber);
  padding-top: 0.28rem;
}

.beats dd {
  margin: 0 0 1rem;
  color: var(--text-dim);
}

/* Short facts: a label column and its answer. */
.facts {
  display: grid;
  grid-template-columns: 11rem 1fr;
  gap: 0.6rem 1.4rem;
  margin: 0;
}

.facts dt {
  color: var(--text);
  font-weight: 600;
}

.facts dd {
  margin: 0;
  color: var(--text-dim);
}

.timeline {
  list-style: none;
  padding: 0;
  border-left: 1px solid var(--line-strong);
}

.timeline li {
  position: relative;
  padding-left: 1.4rem;
  margin-bottom: 1rem;
}

.timeline li::before {
  content: '';
  position: absolute;
  left: -4px;
  top: 0.55em;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--amber);
}

.timeline time {
  display: block;
  font-family: ui-monospace, 'SF Mono', Menlo, monospace;
  font-size: 0.78rem;
  color: var(--text-faint);
}

.scores {
  list-style: none;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr));
  gap: 0.6rem;
}

.scores li {
  margin: 0;
  background: var(--ink-1);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.8rem 1rem;
}

.scores small {
  display: block;
  color: var(--text-faint);
}

.listen {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 0.6rem;
}

.listen li {
  margin: 0;
  background: var(--ink-1);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.9rem 1rem 1rem;
}

.listen p {
  margin: 0 0 0.6rem;
}

.listen audio {
  display: block;
  width: 100%;
  height: 2.4rem;
  color-scheme: dark;
}

@media (max-width: 640px) {
  .pair,
  .beats,
  .facts {
    grid-template-columns: 1fr;
  }

  .beats dd {
    margin-bottom: 1.2rem;
  }
}

.doc__meta {
  font-family: ui-monospace, 'SF Mono', Menlo, monospace;
  font-size: 0.8rem;
  color: var(--text-faint);
  margin-top: 4rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--line);
}
