/* Fonts are served from this site, so pages make no third-party requests */
@font-face {
  font-family: 'Figtree';
  src: url('fonts/Figtree.ttf') format('truetype');
  font-weight: 300 900;
  font-display: swap;
}

@font-face {
  font-family: 'Fredoka';
  src: url('fonts/Fredoka.ttf') format('truetype');
  font-weight: 300 700;
  font-display: swap;
}

/* Same palette as the app */
:root {
  --amber: #FFB627;
  --ink: #10223F;
  --deep: #0A1730;
  --text: #EAF0FA;
  --mist: #9FB3D1;
  --heading: #C9D6EA;
  --idle-chip: #22385E;
  --idle-text: #8FA3C4;
  --edge: rgba(255, 255, 255, 0.1);
  --surface: rgba(255, 255, 255, 0.05);
  --measure: 34rem;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  background: var(--deep);
  scroll-behavior: smooth;
}

body {
  background: radial-gradient(140% 70rem at 70% -10rem, #1D3A66 0%, #10223F 50%, #0A1730 100%) no-repeat;
  color: var(--text);
  font-family: 'Figtree', system-ui, sans-serif;
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--amber);
  text-underline-offset: 0.18em;
}

a:focus-visible,
.btn:focus-visible {
  outline: 2px solid var(--amber);
  outline-offset: 3px;
  border-radius: 6px;
}

.wrap {
  width: min(68rem, 100% - 3rem);
  margin-inline: auto;
}

/* Header */
.site-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-block: 1.5rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--text);
  text-decoration: none;
  font-family: 'Fredoka', sans-serif;
  font-weight: 600;
  font-size: 1.35rem;
}

.brand img {
  width: 2.25rem;
  height: 2.25rem;
}

.site-head nav {
  display: flex;
  gap: 1.5rem;
  font-size: 0.95rem;
}

.site-head nav a {
  color: var(--mist);
  text-decoration: none;
}

.site-head nav a:hover {
  color: var(--text);
}

/* Hero */
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: 3rem;
  align-items: center;
  padding-block: 3rem 5rem;
}

h1,
h2 {
  font-family: 'Fredoka', sans-serif;
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.01em;
}

h1 {
  font-size: clamp(2.4rem, 5vw, 3.6rem);
  max-width: 14ch;
}

.lede {
  margin-top: 1.25rem;
  max-width: var(--measure);
  color: var(--heading);
  font-size: 1.2rem;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.5rem;
  margin-top: 2rem;
}

.btn {
  display: inline-block;
  padding: 0.8rem 1.4rem;
  border-radius: 999px;
  background: var(--amber);
  color: var(--ink);
  font-weight: 700;
  text-decoration: none;
}

.btn:hover {
  background: #FFC54F;
}

.small {
  color: var(--mist);
  font-size: 0.9rem;
}

/* The app window, with a notification arriving above it */
.stage {
  position: relative;
  justify-self: center;
  width: min(100%, 21rem);
  padding-top: 6.25rem;
}

.window {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 14px;
  border: 1px solid var(--edge);
  box-shadow: 0 30px 60px -20px rgba(0, 0, 0, 0.6);
}

.banner {
  position: absolute;
  top: 0;
  left: 50%;
  width: min(23rem, 108%);
  translate: -50% 0;
  display: grid;
  grid-template-columns: 2.4rem minmax(0, 1fr);
  gap: 0.75rem;
  align-items: start;
  padding: 0.8rem 0.95rem;
  border-radius: 16px;
  background: rgba(236, 240, 247, 0.94);
  color: #1B2433;
  box-shadow: 0 12px 30px -8px rgba(0, 0, 0, 0.55);
  font-size: 0.85rem;
  line-height: 1.35;
  animation: arrive 0.7s cubic-bezier(0.2, 0.9, 0.3, 1.15) 0.9s both;
}

.banner img {
  width: 2.4rem;
  height: 2.4rem;
}

.banner b {
  display: block;
}

.banner .meta {
  display: flex;
  justify-content: space-between;
  color: #5B6577;
  font-size: 0.78rem;
}

@keyframes arrive {
  from {
    opacity: 0;
    transform: translateY(-1.5rem) scale(0.96);
  }
}

/* Sections */
section {
  padding-block: 4.5rem;
  border-top: 1px solid var(--edge);
}

h2 {
  font-size: clamp(1.8rem, 3.4vw, 2.4rem);
  max-width: 20ch;
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 3rem;
  align-items: start;
}

.split p,
.points {
  margin-top: 1rem;
  max-width: var(--measure);
  color: var(--heading);
}

/* Account states, drawn the way the app draws them */
.states {
  list-style: none;
  display: grid;
  gap: 1rem;
}

.states li {
  display: grid;
  grid-template-columns: 9.5rem minmax(0, 1fr);
  gap: 1rem;
  align-items: center;
  padding: 1rem 1.1rem;
  border-radius: 14px;
  background: var(--surface);
  border: 1px solid var(--edge);
}

.chip {
  justify-self: start;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.3rem 0.8rem 0.3rem 0.65rem;
  border-radius: 999px;
  color: #fff;
  font-weight: 600;
  font-size: 0.85rem;
  letter-spacing: 0.01em;
  text-shadow: 0 1px 1px rgba(0, 0, 0, 0.25);
}

.chip::before {
  content: '';
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  background: #FFE08A;
  box-shadow: 0 0 6px #FFB627;
}

.chip.idle {
  background: var(--idle-chip);
  color: var(--idle-text);
  text-shadow: none;
}

.chip.idle::before {
  background: #4A6694;
  box-shadow: none;
}

.states p {
  margin: 0;
  color: var(--heading);
  font-size: 0.95rem;
  line-height: 1.45;
}

.points {
  list-style: none;
  display: grid;
  gap: 0.9rem;
}

.points li {
  padding-left: 1.4rem;
  position: relative;
}

.points li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.62em;
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  background: var(--amber);
}

.points strong {
  color: var(--text);
}

/* Closing call to action */
.closing {
  text-align: center;
}

.closing h2,
.closing p {
  margin-inline: auto;
}

.closing h2 {
  max-width: none;
}

.closing p {
  margin-top: 1rem;
  max-width: var(--measure);
  color: var(--heading);
}

.closing .actions {
  justify-content: center;
}

/* Footer */
.site-foot {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 1.75rem;
  padding-block: 2rem 3rem;
  border-top: 1px solid var(--edge);
  color: var(--mist);
  font-size: 0.9rem;
}

.site-foot span {
  margin-right: auto;
}

.site-foot a {
  color: var(--mist);
}

/* Privacy policy page */
.policy {
  max-width: 40rem;
  padding-block: 2rem 4rem;
}

.policy h1 {
  max-width: none;
  font-size: clamp(2rem, 4vw, 2.8rem);
}

.policy h2 {
  max-width: none;
  margin-top: 2.5rem;
  font-size: 1.5rem;
}

.policy p,
.policy ul {
  margin-top: 0.9rem;
  color: var(--heading);
}

.policy ul {
  padding-left: 1.2rem;
}

.policy li + li {
  margin-top: 0.4rem;
}

.policy strong {
  color: var(--text);
}

.policy code {
  font-size: 0.9em;
  color: var(--text);
  overflow-wrap: anywhere;
}

/* Small screens */
@media (max-width: 48rem) {
  .hero,
  .split {
    grid-template-columns: minmax(0, 1fr);
  }

  .hero {
    padding-block: 1.5rem 3.5rem;
  }

  .states li {
    grid-template-columns: minmax(0, 1fr);
    gap: 0.6rem;
  }

  .banner {
    width: 100%;
  }

  .site-head nav a:first-child {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .banner {
    animation: none;
  }
}
