/*
 * The invite page. Colours, type, radii and strokes are the tokens of DESIGN.md (front matter);
 * the page has no other values of its own. Gabarito, two of its three weights.
 */
@font-face {
  font-family: 'Gabarito';
  src: url('/invite/fonts/Gabarito-SemiBold.ttf') format('truetype');
  font-weight: 600;
  font-display: swap;
}
@font-face {
  font-family: 'Gabarito';
  src: url('/invite/fonts/Gabarito-ExtraBold.ttf') format('truetype');
  font-weight: 800;
  font-display: swap;
}

:root {
  --background: #EDF3EE;
  --surface: #FFFFFF;
  --ink: #10231A;
  --ink-secondary: #33493E;
  --on-ink: #FFFFFF;
  --pressed: #FFFFFF;
}

@media (prefers-color-scheme: dark) {
  :root {
    --background: #0E1712;
    --surface: #1A2A21;
    --ink: #EAF2EC;
    --ink-secondary: #A9BDB1;
    --on-ink: #0E1712;
    --pressed: #1A2A21;
  }
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  background: var(--background);
  color: var(--ink);
  font-family: 'Gabarito', system-ui, sans-serif;
  font-weight: 600;
}

.page {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  min-height: 100vh;
  min-height: 100dvh;
  max-width: 360px;
  margin: 0 auto;
  padding: max(24px, env(safe-area-inset-top)) 24px max(24px, env(safe-area-inset-bottom));
  text-align: center;
}

.jar {
  width: 144px;
  height: 200px;
  margin-bottom: 8px;
}

.lid {
  fill: var(--ink);
}

.slot {
  fill: var(--surface);
}

/* 3.5 dp for the jar body (DESIGN.md stroke), whatever size the drawing is shown at. */
.glass {
  fill: var(--surface);
  stroke: var(--ink);
  stroke-width: 3.5px;
  vector-effect: non-scaling-stroke;
}

.name {
  margin: 0;
  font-size: 30px;
  font-weight: 800;
  line-height: 1.1;
}

.sentence {
  margin: 0 0 16px;
  font-size: 16px;
  line-height: 1.3;
}

.button {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 56px;
  border: 2.5px solid var(--ink);
  border-radius: 16px;
  background: var(--ink);
  color: var(--on-ink);
  font-size: 20px;
  font-weight: 800;
  text-decoration: none;
  transition: background-color 120ms linear, color 120ms linear;
}

.button:active {
  background: var(--pressed);
  color: var(--ink);
}

.button:focus-visible {
  outline: 2.5px solid var(--ink);
  outline-offset: 4px;
}

.code {
  margin: 8px 0 0;
  color: var(--ink-secondary);
  font-size: 14px;
}

.code-value {
  font-weight: 800;
  letter-spacing: 0.04em;
  font-variant-numeric: tabular-nums;
}

@media (prefers-reduced-motion: reduce) {
  .button {
    transition: none;
  }
}
