/* NextKnocks — one stylesheet, no build step. */

@font-face {
  font-family: "Atkinson Hyperlegible Next";
  src: url("fonts/atkinson-hyperlegible-next-latin-wght-normal.woff2") format("woff2");
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
}

:root {
  --paper: #ffffff;
  --wash: #f3f5f7;
  --ink: #1b1e23;
  --ink-2: #4b5360;
  --rule: #dde1e6;
  --accent: #2343a8;       /* ballpoint blue */
  --accent-dark: #1a3285;
  --accent-wash: #eceffa;

  --font: "Atkinson Hyperlegible Next", ui-sans-serif, system-ui, -apple-system,
    "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

  --wrap: 68rem;
  --gutter: clamp(1.25rem, 5vw, 3rem);
  --section: clamp(4.5rem, 11vw, 8rem);

  color-scheme: light;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

@media (min-width: 48em) {
  body {
    font-size: 1.125rem;
  }
}

h1, h2, h3, p, ul, ol, dl, dd, figure {
  margin: 0;
}

ul, ol {
  padding: 0;
  list-style: none;
}

::selection {
  background: var(--accent-wash);
}

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

a:hover {
  text-decoration-thickness: 2px;
}

:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
  border-radius: 2px;
}

.wrap {
  width: 100%;
  max-width: calc(var(--wrap) + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* Two columns on wide screens, shared by the product and "plain" sections */
@media (min-width: 60em) {
  .split {
    display: grid;
    grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
    column-gap: clamp(3rem, 6vw, 5.5rem);
    align-items: start;
  }
}

/* Header ------------------------------------------------------------ */

.site-header {
  padding-top: clamp(1.25rem, 3vw, 2rem);
}

.wordmark {
  font-size: 1.25rem;
  font-weight: 760;
  letter-spacing: -0.01em;
  line-height: 1;
}

/* Hero -------------------------------------------------------------- */

.hero {
  padding-top: clamp(3.5rem, 11vw, 8rem);
  padding-bottom: var(--section);
}

.hero h1 {
  max-width: 11em;
  font-size: clamp(2.5rem, 1.55rem + 4.7vw, 4.75rem);
  font-weight: 760;
  line-height: 1.03;
  letter-spacing: -0.03em;
  text-wrap: balance;
}

.lede {
  max-width: 34em;
  margin-top: clamp(1.25rem, 3vw, 1.75rem);
  font-size: clamp(1.125rem, 1rem + 0.55vw, 1.375rem);
  line-height: 1.5;
  color: var(--ink-2);
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1.25rem;
  margin-top: clamp(2rem, 4vw, 2.5rem);
}

.hint {
  font-size: 0.9375rem;
  color: var(--ink-2);
}

/* Button ------------------------------------------------------------ */

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 3rem;
  padding: 0.75rem 1.4rem;
  border-radius: 0.5rem;
  background: var(--accent);
  color: #fff;
  font-weight: 650;
  line-height: 1.2;
  text-decoration: none;
  transition: background-color 150ms ease;
}

.button:hover {
  background: var(--accent-dark);
}

.button:active {
  transform: translateY(1px);
}

/* Product ----------------------------------------------------------- */

.product,
.plain {
  padding-bottom: var(--section);
}

.product-grid,
.plain > .split {
  padding-top: clamp(2.5rem, 6vw, 4rem);
  border-top: 1px solid var(--rule);
}

/* Phone: intro, then the example email, then the details.
   Wide: intro and details on the left, the example email on the right. */
@media (min-width: 60em) {
  .product-grid {
    display: grid;
    grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
    grid-template-rows: auto 1fr;
    grid-template-areas:
      "head    sample"
      "details sample";
    column-gap: clamp(3rem, 6vw, 5.5rem);
  }

  .product-head { grid-area: head; }
  .product-details { grid-area: details; }
  .product-grid .sample { grid-area: sample; }
}

h2 {
  font-size: clamp(1.875rem, 1.35rem + 2.1vw, 2.75rem);
  font-weight: 760;
  line-height: 1.1;
  letter-spacing: -0.02em;
  text-wrap: balance;
}

.section-lede {
  max-width: 28em;
  margin-top: 0.75rem;
  font-size: clamp(1.125rem, 1.05rem + 0.3vw, 1.25rem);
  color: var(--ink-2);
}

.for {
  margin-top: 2.5rem;
  font-weight: 650;
}

.features {
  margin-top: 1rem;
  border-bottom: 1px solid var(--rule);
}

.features li {
  padding-block: 1.125rem;
  border-top: 1px solid var(--rule);
}

.features h3 {
  font-size: 1.125rem;
  font-weight: 700;
  line-height: 1.3;
}

.features p {
  margin-top: 0.25rem;
  color: var(--ink-2);
}

.source {
  margin-top: 1.5rem;
  color: var(--ink);
}

/* The example email */

.sample {
  margin-top: 2rem;
}

@media (min-width: 60em) {
  .sample {
    margin-block: 0.5rem 0;
  }
}

.email {
  overflow: hidden;
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: 0.875rem;
  box-shadow:
    0 1px 2px rgb(27 30 35 / 0.04),
    0 18px 40px -24px rgb(27 30 35 / 0.22);
}

.email-head {
  display: grid;
  gap: 0.25rem;
  padding: 1rem 1.25rem;
  background: var(--wash);
  border-bottom: 1px solid var(--rule);
  font-size: 0.9375rem;
}

.email-head > div {
  display: grid;
  grid-template-columns: 4.25rem minmax(0, 1fr);
  gap: 0.5rem;
}

.email-head dt {
  color: var(--ink-2);
}

.email-head .subject {
  font-weight: 650;
}

.email-body {
  padding: 1.25rem 1.25rem 1.5rem;
}

@media (min-width: 30em) {
  .email-head,
  .email-body {
    padding-inline: 1.5rem;
  }
}

.area {
  font-size: 0.9375rem;
  color: var(--ink-2);
}

.list-title {
  margin-top: 1.5rem;
  font-size: 1rem;
  font-weight: 700;
}

.count {
  display: inline-block;
  min-width: 1.5rem;
  margin-left: 0.35rem;
  vertical-align: 0.08em;
  padding: 0.05rem 0.45rem;
  border-radius: 999px;
  background: var(--accent-wash);
  color: var(--accent);
  font-size: 0.8125rem;
  font-weight: 700;
  text-align: center;
  font-variant-numeric: tabular-nums;
}

.rows {
  margin-top: 0.5rem;
}

.rows li {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  column-gap: 1rem;
  padding-block: 0.7rem;
  border-top: 1px solid var(--rule);
  font-size: 1rem;
  line-height: 1.4;
}

.place b {
  font-weight: 700;
}

.dist {
  color: var(--ink-2);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.when {
  grid-column: 1 / -1;
  margin-top: 0.125rem;
  font-size: 0.9375rem;
  color: var(--ink-2);
}

.sample figcaption {
  margin-top: 0.875rem;
  font-size: 0.875rem;
  color: var(--ink-2);
}

/* Plain ------------------------------------------------------------- */

.plain p {
  max-width: 32em;
  margin-top: 1rem;
  font-size: clamp(1.125rem, 1.05rem + 0.4vw, 1.3125rem);
  color: var(--ink-2);
}

@media (min-width: 60em) {
  .plain p {
    margin-top: 0.35rem;
  }
}

/* Contact ----------------------------------------------------------- */

.contact {
  padding-bottom: clamp(3rem, 7vw, 5rem);
}

.panel {
  padding: clamp(1.75rem, 5vw, 3.5rem);
  background: var(--wash);
  border-radius: 1rem;
}

.panel p {
  max-width: 34em;
  margin-top: 1rem;
  font-size: clamp(1.0625rem, 1rem + 0.3vw, 1.1875rem);
  color: var(--ink-2);
}

.panel .signature {
  margin-top: 0.75rem;
  color: var(--ink);
  font-weight: 650;
}

.panel .button {
  margin-top: 1.75rem;
}

/* Footer ------------------------------------------------------------ */

.site-footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.5rem 2rem;
  padding-bottom: 2.5rem;
  font-size: 0.9375rem;
  color: var(--ink-2);
}

/* Motion ------------------------------------------------------------ */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition: none !important;
  }
}
