/* FlirtLogin one-pager. Plain CSS without a build step. The CSP only allows
   same-origin stylesheets and fonts, so the markup carries no inline styles. */

@font-face {
  font-family: "Bricolage Grotesque";
  font-style: normal;
  font-weight: 200 800;
  font-stretch: 75% 100%;
  font-display: swap;
  src: url("/fonts/bricolage-grotesque-latin.woff2") format("woff2");
}

:root {
  color-scheme: light dark;

  /* Brand: forest and emerald from the logo, blush as the warm counterpart. */
  --forest: #0b3d2e;
  --emerald: #059669;
  --emerald-light: #6ee7b7;
  --blush: #f6cfc6;
  --mint: #eaf6f0;
  --on-forest: #f3faf6;
  --on-forest-muted: #c3ddd2;

  --bg: #ffffff;
  --ink: var(--forest);
  --text: #2f4c44;
  --muted: #4f6b61;
  --line: #cde2d8;
  --band: var(--mint);
  --accent: #047857;
  --focus: var(--emerald);

  --font:
    "Bricolage Grotesque", ui-sans-serif, system-ui, -apple-system, "Segoe UI",
    sans-serif;
  --measure: 60ch;
  --page: 72rem;
  --gutter: clamp(1rem, 5vw, 3rem);
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #06231b;
    --ink: #eef8f3;
    --text: #bfd6cc;
    --muted: #97b2a7;
    --line: #1f5040;
    --band: #0a2e24;
    --accent: var(--emerald-light);
    --focus: var(--emerald-light);
  }
}

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

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

@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

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

p {
  text-wrap: pretty;
}

a {
  color: inherit;
}

::selection {
  background: var(--blush);
  color: var(--forest);
}

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

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  top: 1rem;
  left: 1rem;
  z-index: 10;
  padding: 0.625rem 1rem;
  border-radius: 0.5rem;
  background: var(--blush);
  color: var(--forest);
  font-weight: 600;
  text-decoration: none;
  transform: translateY(-200%);
}

.skip-link:focus-visible {
  transform: none;
}

.wrap {
  width: min(100% - 2 * var(--gutter), var(--page));
  margin-inline: auto;
}

/* Header and hero share the forest field in both color schemes. */

.site-header,
.hero {
  --focus: var(--emerald-light);
  background: var(--forest);
  color: var(--on-forest-muted);
}

/* A fixed height keeps the header edge on a whole pixel, so no seam shows
   between header and hero. */
.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  height: 4.75rem;
}

.brand {
  display: inline-flex;
  color: var(--on-forest);
}

.logo {
  display: block;
  width: auto;
  height: 1.625rem;
}

.logo-heart {
  fill: #34d399;
}

.logo-keyhole {
  fill: var(--forest);
}

.header-link {
  color: var(--on-forest);
  font-weight: 600;
  text-decoration-color: rgb(246 207 198 / 0.45);
  text-decoration-thickness: 2px;
  text-underline-offset: 0.3em;
}

.header-link:hover {
  text-decoration-color: var(--blush);
}

/* Hero: the four provider names, stacked, are the one loud element on the
   page. Everything after it stays quiet. */

.hero {
  --lead-size: clamp(1.375rem, 2.6vw, 2rem);
  padding-block: clamp(2.5rem, 7vw, 5.5rem) clamp(3.5rem, 9vw, 6.5rem);
}

.hero .wrap {
  display: grid;
  gap: clamp(1.75rem, 4vw, 2.75rem);
}

.hero-title {
  color: var(--blush);
  font-weight: 800;
}

.hero-lead,
.provider-or {
  color: var(--on-forest);
  font-size: var(--lead-size);
  font-weight: 500;
  font-stretch: 100%;
  letter-spacing: 0;
}

.hero-lead {
  display: block;
  margin-bottom: 0.75rem;
  line-height: 1.2;
}

.provider {
  display: block;
  /* "Microsoft" is about 3.5em wide at this width; it sets the limit. */
  font-size: clamp(3.75rem, 22vw, 8rem);
  font-stretch: 75%;
  line-height: 0.92;
  letter-spacing: -0.01em;
}

/* Centred on the lowercase band of "Yahoo" instead of hanging from its
   baseline. */
.provider-or {
  display: inline-block;
  vertical-align: middle;
  margin-right: 0.1em;
  line-height: 1;
}

.hero-intro {
  max-width: 40ch;
  font-size: clamp(1.125rem, 1.7vw, 1.3125rem);
  line-height: 1.55;
}

/* On wide screens the intro stands beside the names, its top on the first
   name, so the eye runs lead, names, intro. */
@media (min-width: 60rem) {
  .hero .wrap {
    grid-template-columns: minmax(0, 3fr) minmax(0, 2fr);
    align-items: start;
    column-gap: 3rem;
  }

  .provider {
    font-size: min(8rem, 10vw);
  }

  .hero-intro {
    padding-top: calc(var(--lead-size) * 1.2 + 1rem);
  }
}

/* Sections */

.section {
  padding-block: clamp(4rem, 9vw, 7rem);
}

.section-title {
  color: var(--ink);
  font-size: clamp(2rem, 4.2vw, 3rem);
  font-weight: 750;
  font-stretch: 87.5%;
  line-height: 1.05;
  letter-spacing: -0.015em;
  text-wrap: balance;
}

.section-lede {
  max-width: 36ch;
  margin-top: 1rem;
  color: var(--muted);
  font-size: 1.1875rem;
}

/* Explanatory sections share one layout: title and lede on the left, the
   content on the right. */

.section-grid {
  display: grid;
  gap: 2.5rem;
}

@media (min-width: 60rem) {
  .section-grid {
    grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
    align-items: start;
    column-gap: 4rem;
  }

  .section-intro {
    position: sticky;
    top: 2rem;
  }
}

/* How it works: a real sequence, so the steps carry numbers. The connector
   runs from the first number down to the lock, where the sequence ends. */

.steps-body {
  --marker: 3.25rem;
  --marker-gap: 1rem;
}

.step-list {
  padding: 0;
  list-style: none;
  counter-reset: step;
}

.step,
.outcome {
  position: relative;
  display: grid;
  grid-template-columns: var(--marker) minmax(0, 1fr);
  column-gap: var(--marker-gap);
}

.step {
  align-items: baseline;
  padding-bottom: 2.25rem;
  counter-increment: step;
}

.step::before {
  content: counter(step);
  grid-row: 1;
  color: var(--accent);
  font-size: 2.5rem;
  font-weight: 800;
  font-stretch: 75%;
  font-variant-numeric: tabular-nums;
  line-height: 1;
  text-align: center;
}

.step::after {
  content: "";
  position: absolute;
  top: 3rem;
  bottom: 0.75rem;
  left: calc(var(--marker) / 2 - 1px);
  width: 2px;
  border-radius: 1px;
  background: var(--line);
}

.step h3,
.outcome h3 {
  grid-column: 2;
  color: var(--ink);
  font-size: 1.25rem;
  font-weight: 650;
  line-height: 1.3;
}

.step p,
.outcome p {
  grid-column: 2;
  max-width: var(--measure);
  margin-top: 0.25rem;
}

.outcome {
  align-items: start;
}

.outcome-mark {
  grid-row: 1 / span 2;
  justify-self: center;
  width: 2.5rem;
  height: 2.5rem;
  /* Sits on the cap height of the heading beside it. */
  margin-top: -0.1875rem;
}

.mark-heart {
  fill: var(--accent);
}

.mark-keyhole {
  fill: var(--bg);
}

/* What FlirtLogin does: three plain statements, read top to bottom. */

.facts {
  background: var(--band);
}

.fact-list {
  padding: 0;
  list-style: none;
}

.fact-list li {
  padding-block: 1.5rem;
  border-top: 2px solid var(--line);
}

.fact-list li:first-child {
  padding-top: 0;
  border-top: 0;
}

.fact-list li:last-child {
  padding-bottom: 0;
}

.fact-list h3 {
  color: var(--ink);
  font-size: 1.25rem;
  font-weight: 650;
  line-height: 1.3;
  text-wrap: balance;
}

.fact-list p {
  max-width: var(--measure);
  margin-top: 0.25rem;
}

/* Support: the address itself is the call to action. */

.support-mail {
  display: inline-block;
  margin-top: clamp(1.5rem, 4vw, 2.5rem);
  color: var(--ink);
  font-size: clamp(1.75rem, 5.5vw, 3.5rem);
  font-weight: 800;
  font-stretch: 75%;
  line-height: 1.1;
  letter-spacing: -0.01em;
  text-decoration-color: var(--blush);
  text-decoration-thickness: 0.12em;
  text-underline-offset: 0.16em;
  overflow-wrap: anywhere;
}

.support-mail:hover {
  text-decoration-color: var(--emerald);
}

.site-footer {
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.9375rem;
}

/* Legal links first, copyright last; they stack on narrow screens. */
.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem 2rem;
  padding-block: 2rem;
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
}

.footer-nav a {
  text-decoration-color: var(--line);
  text-decoration-thickness: 2px;
  text-underline-offset: 0.3em;
}

.footer-nav a:hover,
.footer-nav a[aria-current="page"] {
  color: var(--ink);
  text-decoration-color: var(--accent);
}

/* Legal pages: one reading column under the shared header. */

.legal {
  padding-block: clamp(3rem, 7vw, 5rem) clamp(4rem, 9vw, 7rem);
}

.legal-body {
  max-width: 44rem;
}

.legal-meta {
  margin-top: 1rem;
  color: var(--muted);
  font-size: 0.9375rem;
}

.legal-summary {
  margin-top: 1.5rem;
  color: var(--ink);
  font-size: 1.1875rem;
}

.legal-body h2 {
  margin-top: 3rem;
  color: var(--ink);
  font-size: 1.5rem;
  font-weight: 700;
  font-stretch: 87.5%;
  line-height: 1.2;
  text-wrap: balance;
}

.legal-body h3 {
  margin-top: 2rem;
  color: var(--ink);
  font-size: 1.1875rem;
  font-weight: 650;
  line-height: 1.3;
}

.legal-body p,
.legal-body ul,
.legal-body address {
  margin-top: 0.75rem;
}

.legal-body ul {
  padding-left: 1.25rem;
}

.legal-body li + li {
  margin-top: 0.375rem;
}

.legal-body address {
  font-style: normal;
}

.legal-body strong {
  color: var(--ink);
  font-weight: 650;
}

.legal-body a {
  color: var(--accent);
  text-underline-offset: 0.2em;
  overflow-wrap: anywhere;
}

.legal-body code {
  font-family: ui-monospace, "Cascadia Mono", Consolas, monospace;
  font-size: 0.875em;
}

/* 404 page */

.not-found .section-lede {
  max-width: 40ch;
}

.not-found .home-link {
  display: inline-block;
  margin-top: 2rem;
  color: var(--accent);
  font-weight: 600;
  text-decoration-thickness: 2px;
  text-underline-offset: 0.25em;
}
