/* Amplified Architect. Colors, fonts and wording come from brand.md. */

/* ---------- Fonts (served from the fontsource packages) ---------- */

@font-face {
  font-family: "Montserrat Variable";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("/fonts/montserrat/montserrat-latin-wght-normal.woff2") format("woff2");
  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: "Montserrat Variable";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("/fonts/montserrat/montserrat-latin-ext-wght-normal.woff2") format("woff2");
  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;
}

@font-face {
  font-family: "Inter Variable";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("/fonts/inter/inter-latin-wght-normal.woff2") format("woff2");
  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: "Inter Variable";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("/fonts/inter/inter-latin-ext-wght-normal.woff2") format("woff2");
  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;
}

/* Stand-ins sized like the real fonts, so the page barely moves when they arrive. */
@font-face {
  font-family: "Montserrat Fallback";
  src: local("Arial");
  size-adjust: 112.8%;
  ascent-override: 85.8%;
  descent-override: 22.3%;
  line-gap-override: 0%;
}

@font-face {
  font-family: "Inter Fallback";
  src: local("Arial");
  size-adjust: 107.1%;
  ascent-override: 90.5%;
  descent-override: 22.6%;
  line-gap-override: 0%;
}

/* ---------- Brand ---------- */

:root {
  --ground: #0E1116;
  --panel: #151A22;
  --line: #232B37;
  --text: #F5F7FA;
  --muted: #B0B8C4;
  --accent: #5B9BFF;

  --font-head: "Montserrat Variable", "Montserrat Fallback", system-ui, sans-serif;
  --font-body: "Inter Variable", "Inter Fallback", system-ui, sans-serif;

  --wrap: 77.5rem;
  --gutter: clamp(1.25rem, 5vw, 3rem);
  --section: clamp(5rem, 11vw, 10rem);
  --header: 4.5rem;
  --radius: 0.875rem;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);

  /* Sized so each sentence of the headline fits on one line on a laptop, and breaks in two on a phone. */
  --hero-size: clamp(2.25rem, max(min(11vw, 3.5rem), 7.7vw - 0.46rem), 5.5rem);

  color-scheme: dark;
}

/* ---------- Base ---------- */

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

html {
  background: var(--ground);
  scroll-padding-top: calc(var(--header) + 1rem);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

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

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

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

img,
svg {
  display: block;
}

img {
  max-width: 100%;
  height: auto;
}

a {
  color: inherit;
  text-decoration: none;
}

[hidden] {
  display: none !important;
}

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

::selection {
  background: var(--accent);
  color: var(--ground);
}

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

.icon {
  flex: none;
  width: 1.125em;
  height: 1.125em;
}

.text-link {
  color: var(--accent);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
  transition: color 0.2s;
}

/* A button that reads as a link, for actions such as logging out. */
.link-button {
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  cursor: pointer;
  transition: color 0.2s;
}

@media (hover: hover) {
  .text-link:hover {
    color: var(--text);
  }
}

.skip-link {
  position: absolute;
  left: var(--gutter);
  top: 0.75rem;
  z-index: 100;
  padding: 0.625rem 1rem;
  border-radius: 0.5rem;
  background: var(--accent);
  color: var(--ground);
  font-weight: 600;
  transform: translateY(-300%);
}

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

/* A short blue beam, like the one in the logo, leads into each label. */
.eyebrow {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--muted);
  font-family: var(--font-head);
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1.4;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.eyebrow::before {
  content: "";
  flex: none;
  width: 2rem;
  height: 2px;
  background: var(--accent);
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.625rem;
  min-height: 3.25rem;
  padding: 0.75rem 1.5rem;
  border: 1px solid transparent;
  border-radius: 0.75rem;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.2;
  white-space: nowrap;
  transition: background-color 0.2s, border-color 0.2s, color 0.2s, transform 0.2s var(--ease);
}

.btn .icon {
  transition: transform 0.3s var(--ease);
}

.btn--primary {
  background: var(--accent);
  color: var(--ground);
}

.btn--ghost {
  border-color: var(--line);
  background: var(--ground);
  color: var(--text);
}

.btn--small {
  min-height: 2.5rem;
  padding: 0.5rem 1rem;
  border-radius: 0.625rem;
  font-size: 0.875rem;
  gap: 0.5rem;
}

.btn:active {
  transform: scale(0.97);
}

@media (hover: hover) {
  .btn--primary:hover {
    background: var(--text);
  }

  .btn--ghost:hover {
    border-color: var(--muted);
    background: var(--panel);
  }

  .btn:hover .icon {
    transform: translateX(3px);
  }

  .btn[href^="#"]:hover .icon {
    transform: translateY(3px);
  }
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--ground);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s;
}

.site-header.is-scrolled {
  border-bottom-color: var(--line);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  height: var(--header);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
}

.brand__logo {
  width: 2.25rem;
}

/* The name: capitals, wide spacing, AMPLIFIED extra bold, ARCHITECT medium and blue. */
.wordmark {
  display: flex;
  flex-direction: column;
  font-family: var(--font-head);
  font-size: 0.6875rem;
  line-height: 1.3;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  white-space: nowrap;
}

.wordmark__first {
  font-weight: 800;
}

.wordmark__second {
  font-weight: 500;
  color: var(--accent);
}

.nav {
  display: none;
}

.nav a {
  position: relative;
  padding-block: 0.5rem;
  color: var(--muted);
  font-size: 0.9375rem;
  transition: color 0.2s;
}

.nav a::after {
  content: "";
  position: absolute;
  inset: auto 0 0.125rem;
  height: 2px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s var(--ease);
}

.btn__long {
  display: none;
}

@media (hover: hover) {
  .nav a:hover {
    color: var(--text);
  }

  .nav a:hover::after {
    transform: scaleX(1);
  }
}

.site-header__actions {
  display: flex;
  align-items: center;
  gap: 0.875rem;
}

.site-header__link {
  padding-block: 0.5rem;
  font-size: 0.9375rem;
  font-weight: 500;
  white-space: nowrap;
  transition: color 0.2s;
}

/* On the narrowest phones the YouTube button is just its play icon. */
.site-header__watch {
  width: 2.5rem;
  padding-inline: 0;
}

.site-header__watch .btn__short {
  display: none;
}

@media (hover: hover) {
  .site-header__link:hover {
    color: var(--accent);
  }
}

@media (min-width: 30rem) {
  .site-header__watch {
    width: auto;
    padding-inline: 1rem;
  }

  .site-header__watch .btn__short {
    display: inline;
  }
}

@media (min-width: 40rem) {
  .wordmark {
    flex-direction: row;
    gap: 0.5em;
    font-size: 0.8125rem;
  }
}

@media (min-width: 48rem) {
  .btn__long {
    display: inline;
  }

  .site-header__watch .btn__short {
    display: none;
  }
}

@media (min-width: 70rem) {
  .nav {
    display: flex;
    gap: 2.25rem;
    margin-left: auto;
    margin-right: 1.25rem;
  }
}

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

.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
}

/* Drawing-paper grid, strongest on the right and gone before it reaches the words. */
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -2;
  background-image:
    linear-gradient(to right, var(--line) 1px, transparent 1px),
    linear-gradient(to bottom, var(--line) 1px, transparent 1px);
  background-size: 4.5rem 4.5rem;
  background-position: right top;
  opacity: 0.6;
  -webkit-mask-image: radial-gradient(ellipse 75% 85% at 100% 0%, #000 0%, transparent 72%);
  mask-image: radial-gradient(ellipse 75% 85% at 100% 0%, #000 0%, transparent 72%);
}

.hero__inner {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: min(100svh - var(--header), 56rem);
  padding-block: clamp(3.5rem, 9vw, 7rem);
}

.hero__title {
  margin-top: 1.5rem;
  font-family: var(--font-head);
  font-size: var(--hero-size);
  font-weight: 800;
  line-height: 1.04;
  letter-spacing: -0.03em;
}

.hero__title span {
  display: block;
  text-wrap: balance;
}

.hero__title-accent {
  color: var(--accent);
}

.hero__intro {
  max-width: 37rem;
  margin-top: clamp(1.5rem, 3vw, 2rem);
  color: var(--muted);
  font-size: clamp(1.0625rem, 1.7vw, 1.3125rem);
  line-height: 1.55;
  text-wrap: pretty;
}

.hero__intro strong {
  color: var(--text);
  font-weight: 500;
}

.hero__actions {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: clamp(2rem, 4vw, 2.75rem);
}

.hero__facts {
  display: flex;
  flex-direction: column;
  gap: 0.625rem 2.5rem;
  margin-top: clamp(2.5rem, 6vw, 4.5rem);
  padding-top: 1.5rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.9375rem;
}

.hero__facts li {
  display: flex;
  align-items: center;
  gap: 0.625rem;
}

.hero__facts .icon {
  color: var(--accent);
}

/* The logo, drawn large behind the right-hand side. Hidden on small screens. */
.hero__mark {
  display: none;
}

.hero__mark path {
  fill: none;
  stroke-linejoin: miter;
  stroke-miterlimit: 14;
}

.hero__mark-edge {
  stroke: var(--line);
  stroke-width: 18;
}

.hero__mark-face {
  stroke: var(--panel);
  stroke-width: 17.2;
}

.hero__mark-beam-edge {
  stroke: color-mix(in srgb, var(--accent) 60%, var(--ground));
  stroke-width: 12;
}

.hero__mark-beam {
  stroke: color-mix(in srgb, var(--accent) 16%, var(--ground));
  stroke-width: 11.2;
}

@media (min-width: 30rem) {
  .hero__actions {
    flex-direction: row;
    flex-wrap: wrap;
  }
}

@media (min-width: 48rem) {
  .hero__facts {
    flex-direction: row;
    flex-wrap: wrap;
  }
}

@media (min-width: 60rem) {
  .hero__mark {
    display: block;
    position: absolute;
    z-index: -1;
    top: 50%;
    left: 54%;
    width: min(60vw, 54rem);
    height: auto;
    transform: translateY(-50%);
    pointer-events: none;
  }
}

/* ---------- Sections ---------- */

.section {
  padding-block: var(--section);
}

.section--lined {
  border-block: 1px solid var(--line);
}

.section__head {
  display: grid;
  gap: 1.25rem 3rem;
  margin-bottom: clamp(2.5rem, 6vw, 4.5rem);
}

.section__title {
  margin-top: 1.25rem;
  font-family: var(--font-head);
  font-size: clamp(2rem, 5.2vw, 3.75rem);
  font-weight: 800;
  line-height: 1.06;
  letter-spacing: -0.028em;
  text-wrap: balance;
}

.section__lead {
  max-width: 27rem;
  color: var(--muted);
  text-wrap: pretty;
}

@media (min-width: 58rem) {
  .section__head {
    grid-template-columns: 1fr auto;
    align-items: end;
  }
}

/* ---------- What you'll learn ---------- */

/* The 1px gaps show the grid's own color, which gives hairlines at any column count. */
.learn {
  display: grid;
  gap: 1px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--line);
}

.learn__item {
  position: relative;
  display: grid;
  background: var(--ground);
  transition: background-color 0.3s;
}

.learn__item::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 2px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.5s var(--ease);
}

.learn__card {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: clamp(1.5rem, 3vw, 2.25rem);
}

.learn__number {
  color: var(--accent);
  font-family: var(--font-head);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.14em;
}

.learn__title {
  margin-top: 1.25rem;
  font-family: var(--font-head);
  font-size: 1.375rem;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.015em;
}

.learn__text {
  margin-top: 0.625rem;
  color: var(--muted);
  font-size: 1rem;
}

@media (hover: hover) {
  .learn__item:hover {
    background: var(--panel);
  }

  .learn__item:hover::before {
    transform: scaleX(1);
  }
}

@media (min-width: 40rem) {
  .learn {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 68rem) {
  .learn {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .learn__card {
    min-height: 17rem;
  }

  .learn__title {
    margin-top: auto;
    padding-top: 2rem;
  }
}

/* ---------- Videos ---------- */

.videos {
  display: grid;
  gap: 1.25rem;
}

.videos__item {
  display: grid;
}

.card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  transition: transform 0.4s var(--ease), border-color 0.25s;
}

.card__media {
  position: relative;
  display: block;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  background: var(--ground);
}

.card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.7s var(--ease);
}

.card__play {
  position: absolute;
  right: 0.75rem;
  bottom: 0.75rem;
  display: grid;
  place-items: center;
  width: 2.25rem;
  height: 2.25rem;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--ground);
  color: var(--text);
  font-size: 0.875rem;
  transition: background-color 0.25s, border-color 0.25s, color 0.25s;
}

.card__body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 0.5rem;
  padding: 1.125rem 1.25rem 1.375rem;
}

.card__label {
  color: var(--muted);
  font-family: var(--font-head);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.card__title {
  font-family: var(--font-head);
  font-size: 1.0625rem;
  font-weight: 600;
  line-height: 1.35;
  letter-spacing: -0.01em;
  overflow-wrap: break-word;
}

.card__more {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: auto;
  padding-top: 0.75rem;
  color: var(--accent);
  font-size: 0.9375rem;
  font-weight: 600;
}

.card__more .icon {
  transition: transform 0.3s var(--ease);
}

.card--featured .card__label {
  color: var(--accent);
}

.card--featured .card__title {
  font-size: clamp(1.25rem, 2.3vw, 1.75rem);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
  text-wrap: balance;
}

.card--channel {
  justify-content: space-between;
  gap: 0.5rem;
  min-height: 11rem;
  padding: 1.25rem 1.25rem 1.375rem;
  background: var(--ground);
}

.card--channel .card__title {
  margin-top: 0.5rem;
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

@media (hover: hover) {
  .card:hover {
    border-color: var(--accent);
    transform: translateY(-4px);
  }

  .card:hover .card__media img {
    transform: scale(1.04);
  }

  .card:hover .card__play {
    border-color: var(--accent);
    background: var(--accent);
    color: var(--ground);
  }

  .card:hover .card__more .icon {
    transform: translateX(4px);
  }
}

@media (min-width: 34rem) {
  .videos {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .videos__item--featured {
    grid-column: span 2;
  }

  .card--featured .card__body {
    gap: 0.625rem;
    padding: 1.5rem 1.75rem 1.75rem;
  }
}

/* From here the first video takes a 2 by 2 block and the rest fill in around it. */
@media (min-width: 52rem) {
  .videos {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .videos__item--featured {
    grid-row: span 2;
  }
}

@media (min-width: 72rem) {
  .videos {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

/* ---------- Skyhold ---------- */

.skyhold {
  display: grid;
  align-items: center;
  gap: clamp(1.75rem, 4vw, 3.5rem);
  padding: clamp(1rem, 4vw, 3.5rem);
  border: 1px solid var(--line);
  border-radius: calc(var(--radius) * 1.5);
  background: var(--panel);
}

.skyhold__art {
  position: relative;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--ground);
}

/* Shows only the game from the video thumbnail: the 610 by 457 patch starting at 640, 96. */
.skyhold__art img {
  position: absolute;
  top: -20.98%;
  left: -104.92%;
  width: 209.84%;
  max-width: none;
  transition: transform 0.9s var(--ease);
}

.skyhold__body {
  padding: 0.25rem clamp(0.25rem, 1.5vw, 0.75rem) 0.75rem;
}

.skyhold__intro {
  margin-top: 1.5rem;
  color: var(--muted);
}

.skyhold__title {
  margin-top: 0.25rem;
  font-family: var(--font-head);
  font-size: clamp(3rem, 8vw, 5.5rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.035em;
}

.skyhold__text {
  max-width: 28rem;
  margin-top: 1.25rem;
  color: var(--muted);
  font-size: clamp(1.0625rem, 1.5vw, 1.1875rem);
  text-wrap: pretty;
}

.skyhold__facts {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1.5rem;
}

.skyhold__facts li {
  padding: 0.3125rem 0.75rem;
  border: 1px solid var(--line);
  border-radius: 0.5rem;
  background: var(--ground);
  color: var(--text);
  font-size: 0.875rem;
  font-weight: 500;
}

.skyhold__actions {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 2rem;
}

@media (hover: hover) {
  .skyhold:hover .skyhold__art img {
    transform: scale(1.04);
  }
}

@media (min-width: 30rem) {
  .skyhold__actions {
    flex-direction: row;
    flex-wrap: wrap;
  }
}

@media (min-width: 58rem) {
  .skyhold {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  }

  .skyhold__art {
    order: 2;
  }

  .skyhold__body {
    padding-block: 0;
  }

  .skyhold__intro {
    margin-top: 2rem;
  }
}

/* ---------- Sign up ---------- */

.section--join {
  border-top: 1px solid var(--line);
}

.signup {
  display: grid;
  align-items: center;
  gap: clamp(2rem, 5vw, 4.5rem);
}

.signup__title {
  font-size: clamp(1.875rem, 4.2vw, 3.125rem);
}

.signup__label {
  display: block;
  margin-bottom: 0.625rem;
  font-size: 0.9375rem;
  font-weight: 500;
}

.signup__row {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.signup__input {
  flex: 1;
  min-width: 0;
}

.input {
  width: 100%;
  min-height: 3.25rem;
  padding: 0.75rem 1rem;
  border: 1px solid var(--line);
  border-radius: 0.75rem;
  background: var(--panel);
  color: var(--text);
  font: inherit;
  font-size: 1rem;
  transition: border-color 0.2s;
}

.input::placeholder {
  color: var(--muted);
  opacity: 0.6;
}

.input:focus-visible {
  border-color: var(--accent);
  outline-offset: 0;
}

.input[aria-invalid="true"] {
  border-color: var(--text);
}

.signup__form.is-sending .btn {
  opacity: 0.6;
  pointer-events: none;
}

.signup__problem {
  margin-top: 0.75rem;
  font-size: 0.9375rem;
  font-weight: 500;
}

.signup__note {
  margin-top: 0.75rem;
  color: var(--muted);
  font-size: 0.9375rem;
}

.signup__done {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  padding: clamp(1.25rem, 3vw, 1.75rem);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
}

.signup__done:focus {
  outline: none;
}

.signup__tick {
  display: grid;
  flex: none;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 50%;
  background: var(--accent);
  color: var(--ground);
  font-size: 1.25rem;
}

.signup__done-title {
  font-family: var(--font-head);
  font-size: 1.375rem;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.015em;
}

.signup__done-text {
  margin-top: 0.25rem;
  color: var(--muted);
}

@media (hover: hover) {
  .input:hover:not(:focus-visible) {
    border-color: var(--muted);
  }
}

@media (min-width: 30rem) {
  .signup__row {
    flex-direction: row;
  }
}

@media (min-width: 58rem) {
  .signup {
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  }
}

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

.site-footer {
  border-top: 1px solid var(--line);
  padding-block: clamp(3rem, 7vw, 5rem) 2rem;
}

.site-footer__top {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 2.5rem 1.5rem;
}

.site-footer__brand {
  grid-column: 1 / -1;
}

.site-footer__tagline {
  max-width: 22rem;
  margin-top: 1.25rem;
  font-family: var(--font-head);
  font-size: 1.25rem;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -0.015em;
  text-wrap: balance;
}

.site-footer__links {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.75rem;
}

.site-footer__heading {
  margin-bottom: 0.25rem;
  color: var(--muted);
  font-family: var(--font-head);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.site-footer__links a {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  transition: color 0.2s;
}

.site-footer__links .icon {
  color: var(--muted);
  font-size: 0.875rem;
}

.site-footer__bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem 2rem;
  margin-top: clamp(2.5rem, 6vw, 4rem);
  padding-top: 1.5rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.875rem;
}

.site-footer__small {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.75rem;
}

.site-footer__bottom a {
  transition: color 0.2s;
}

@media (hover: hover) {
  .site-footer__links a:hover,
  .site-footer__links .link-button:hover,
  .site-footer__bottom a:hover {
    color: var(--accent);
  }
}

@media (min-width: 48rem) {
  .site-footer__top {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (min-width: 64rem) {
  .site-footer__top {
    grid-template-columns: 1.6fr 1fr 1fr 1fr;
    gap: 2.5rem;
  }

  .site-footer__brand {
    grid-column: auto;
  }
}

/* ---------- Log in and create account ---------- */

.account {
  display: grid;
  place-items: center;
  min-height: min(100svh - var(--header), 52rem);
  padding: clamp(2.5rem, 7vw, 5rem) var(--gutter);
}

.account__panel {
  width: min(100%, 28rem);
  padding: clamp(1.5rem, 5vw, 2.5rem);
  border: 1px solid var(--line);
  border-radius: calc(var(--radius) * 1.5);
  background: var(--panel);
}

.account__title {
  margin-top: 1.25rem;
  font-family: var(--font-head);
  font-size: clamp(1.875rem, 5vw, 2.375rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.025em;
}

.account__lead {
  margin-top: 0.75rem;
  color: var(--muted);
}

.account__form {
  margin-top: 1.75rem;
}

.account__form .input {
  background: var(--ground);
}

.account__form .btn {
  width: 100%;
  margin-top: 1.75rem;
}

.account__other {
  margin-top: 1.5rem;
  color: var(--muted);
  font-size: 0.9375rem;
}

.field + .field {
  margin-top: 1.25rem;
}

.field__top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
}

.field__label {
  display: block;
  margin-bottom: 0.5rem;
  font-size: 0.9375rem;
  font-weight: 500;
}

.field__toggle {
  color: var(--accent);
  font-size: 0.875rem;
  font-weight: 500;
}

.field__hint {
  margin-top: 0.5rem;
  color: var(--muted);
  font-size: 0.875rem;
}

/* Says what went wrong, on the account pages and on My Path. */
.account__problem,
.path__problem {
  margin-top: 1.5rem;
  padding: 0.875rem 1rem;
  border: 1px solid var(--muted);
  border-radius: 0.75rem;
  background: var(--ground);
  font-size: 0.9375rem;
  font-weight: 500;
}

/* ---------- My Path ---------- */

.path {
  padding-block: clamp(3rem, 7vw, 5rem) var(--section);
}

.path__head {
  display: grid;
  gap: 1.75rem;
}

.path__lead {
  max-width: 30rem;
  margin-top: 1rem;
}

.path__who {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1rem;
  color: var(--muted);
  font-size: 0.9375rem;
}

.path__who strong {
  color: var(--text);
  font-weight: 500;
  overflow-wrap: anywhere;
}

/* Stays in view under the header while the steps scroll past. */
.progress {
  position: sticky;
  top: var(--header);
  z-index: 20;
  margin-top: clamp(2rem, 5vw, 3rem);
  padding-block: 1rem 1.125rem;
  border-bottom: 1px solid var(--line);
  background: var(--ground);
}

.progress__count {
  color: var(--muted);
  font-size: 0.9375rem;
}

.progress__count strong {
  margin-right: 0.125rem;
  color: var(--text);
  font-family: var(--font-head);
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

/* One part for each step. */
.progress__bar {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(0, 1fr);
  gap: 0.375rem;
  margin-top: 0.5rem;
}

.progress__part {
  height: 0.5rem;
  border-radius: 0.125rem;
  background: var(--line);
  transition: background-color 0.45s var(--ease);
}

.progress__part.is-done {
  background: var(--accent);
}

.path__all-done {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  margin-top: 1.5rem;
  font-family: var(--font-head);
  font-size: 1.125rem;
  font-weight: 600;
}

.path__all-done .icon {
  color: var(--accent);
}

.steps {
  display: grid;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.step {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: start;
  gap: 1rem;
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  scroll-margin-top: calc(var(--header) + 6.5rem);
}

.step__form {
  grid-row: 1 / span 2;
}

.step__thumb,
.step__words {
  grid-column: 2;
}

.step__check {
  display: grid;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  padding: 0;
  border: 1.5px solid var(--muted);
  border-radius: 0.75rem;
  background: var(--ground);
  color: transparent;
  font-size: 1.25rem;
  cursor: pointer;
  transition: background-color 0.25s, border-color 0.25s, color 0.25s, transform 0.2s var(--ease);
}

.step__check .icon {
  stroke-width: 2.5;
  transform: scale(0.5);
  transition: transform 0.4s var(--ease);
}

.step__check:active {
  transform: scale(0.92);
}

.step.is-done .step__check {
  border-color: var(--accent);
  background: var(--accent);
  color: var(--ground);
}

.step.is-done .step__check .icon {
  transform: none;
}

.step__thumb {
  display: block;
  overflow: hidden;
  max-width: 15rem;
  aspect-ratio: 16 / 9;
  border: 1px solid var(--line);
  border-radius: 0.5rem;
}

.step__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.7s var(--ease);
}

.step__label {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.625rem;
  color: var(--muted);
  font-family: var(--font-head);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.step__tag {
  display: none;
  padding: 0.125rem 0.5rem;
  border: 1px solid var(--line);
  border-radius: 0.375rem;
  font-size: 0.6875rem;
  letter-spacing: 0.08em;
}

.step.is-next .step__tag--next {
  display: inline-block;
  border-color: var(--accent);
  color: var(--accent);
}

.step.is-done .step__tag--done {
  display: inline-block;
  background: var(--ground);
  color: var(--text);
}

.step__title {
  margin-top: 0.5rem;
  font-family: var(--font-head);
  font-size: 1.0625rem;
  font-weight: 600;
  line-height: 1.35;
  letter-spacing: -0.01em;
  overflow-wrap: break-word;
  transition: color 0.3s;
}

.step.is-done .step__title {
  color: var(--muted);
}

.step__watch {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  margin-top: 0.625rem;
  color: var(--accent);
  font-size: 0.9375rem;
  font-weight: 600;
  transition: color 0.2s;
}

@media (hover: hover) {
  .step:not(.is-done) .step__check:hover {
    border-color: var(--accent);
  }

  .step__thumb:hover img {
    transform: scale(1.04);
  }

  .step__watch:hover {
    color: var(--text);
  }
}

@media (min-width: 40rem) {
  .step {
    grid-template-columns: auto 11rem minmax(0, 1fr);
    align-items: center;
    gap: 1.5rem;
    padding: 1.125rem 1.5rem 1.125rem 1.125rem;
  }

  .step__form {
    grid-row: auto;
  }

  .step__thumb,
  .step__words {
    grid-column: auto;
  }

  .step__title {
    font-size: 1.1875rem;
  }
}

@media (min-width: 52rem) {
  .path__head {
    grid-template-columns: 1fr auto;
    align-items: end;
  }
}

/* ---------- Page not found, and the confirm and unsubscribe pages ---------- */

.notice {
  display: grid;
  align-items: center;
  min-height: min(100svh - var(--header), 40rem);
  padding-block: var(--section);
}

.notice .section__lead {
  margin-block: 1.25rem 2rem;
  overflow-wrap: anywhere;
}

.notice button.btn {
  cursor: pointer;
}

/* ---------- Privacy ---------- */

.privacy {
  padding-block: clamp(3rem, 7vw, 5rem) var(--section);
}

.privacy__text {
  max-width: 42rem;
}

.privacy__text .section__lead {
  max-width: none;
  margin-top: 1.25rem;
  font-size: 1.125rem;
}

.privacy__section {
  margin-top: clamp(2.5rem, 6vw, 3.5rem);
  padding-top: clamp(1.75rem, 4vw, 2.25rem);
  border-top: 1px solid var(--line);
}

.privacy__heading {
  font-family: var(--font-head);
  font-size: clamp(1.375rem, 3vw, 1.625rem);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.015em;
}

.privacy__section p {
  margin-top: 1rem;
  color: var(--muted);
  text-wrap: pretty;
}

.privacy__stored {
  display: grid;
  gap: 0.75rem;
  margin-top: 1rem;
}

.privacy__stored li {
  padding: 1rem 1.25rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
}

.privacy__stored strong {
  display: block;
  font-weight: 600;
}

.privacy__stored span {
  display: block;
  margin-top: 0.25rem;
  color: var(--muted);
  font-size: 0.9375rem;
}

.privacy__updated {
  margin-top: clamp(2.5rem, 6vw, 3.5rem);
  color: var(--muted);
  font-size: 0.875rem;
}

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

/* All of it is opt-in: nothing below runs for people who ask their device for less motion. */
@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }

  /* The hero arrives one piece after another. */
  .enter {
    animation: enter 0.9s var(--ease) both;
    animation-delay: calc(var(--step) * 90ms);
  }

  .enter--1 { --step: 1; }
  .enter--2 { --step: 2; }
  .enter--3 { --step: 3; }
  .enter--4 { --step: 4; }
  .enter--5 { --step: 5; }
  .enter--6 { --step: 6; }

  /* The logo is drawn, then the beam slides across it. */
  .hero__mark path {
    stroke-dasharray: 1;
    stroke-dashoffset: 1;
    animation: draw 2s 0.3s cubic-bezier(0.65, 0, 0.35, 1) forwards;
  }

  .hero__mark .hero__mark-beam-edge,
  .hero__mark .hero__mark-beam {
    animation-duration: 1.1s;
    animation-delay: 1.7s;
  }

  /* Sections lift into place as they scroll into view (site.js adds .is-in). */
  .js [data-reveal] {
    opacity: 0;
    transform: translateY(1.5rem);
    transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
  }

  .js [data-reveal].is-in {
    opacity: 1;
    transform: none;
  }

  /* The confirmation settles in where the form was. */
  .signup__done {
    animation: enter 0.6s var(--ease) both;
  }
}

@keyframes enter {
  from {
    opacity: 0;
    transform: translateY(1.25rem);
  }
}

@keyframes draw {
  to {
    stroke-dashoffset: 0;
  }
}
