/* Rally — shared tokens and primitives
   One reflex-blue ink printed on carbonless form stock; red is stamp ink. */

@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
  src: url("../fonts/archivo-var.woff2") format("woff2");
}

@font-face {
  font-family: "Public Sans";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("../fonts/public-sans-var.woff2") format("woff2");
}

@font-face {
  font-family: "Public Sans";
  font-style: italic;
  font-weight: 100 900;
  font-display: swap;
  src: url("../fonts/public-sans-italic-var.woff2") format("woff2");
}

:root {
  /* Ink */
  --ink: #1d3aa8;
  --ink-deep: #142b82;
  --ink-soft: #3d52a8;
  --ink-faint: #6f7fbf;
  --rule: rgba(29, 58, 168, 0.26);
  --rule-strong: rgba(29, 58, 168, 0.55);
  --hair: rgba(29, 58, 168, 0.13);

  /* Stock */
  --white: #fdfdfb;
  --canary: #f3dc5c;
  --canary-2: #faefb0;
  --canary-3: #fdf7d8;
  --pink: #f7c6d1;
  --pink-2: #fde5eb;
  --gold: #e9b43c;
  --gold-2: #f8e3b0;
  --green: #bfe2c0;
  --green-2: #e4f3e2;
  --sky: #c9d8f6;
  --sky-2: #e8eefb;
  --lilac: #dccff3;
  --desk: #e5e9f1;

  /* Stamp and state ink */
  --red: #d8262e;
  --red-text: #b81d25;
  --green-ink: #1c7440;
  --amber-ink: #8a5a00;

  --display: "Archivo", "Public Sans", ui-sans-serif, system-ui, sans-serif;
  --text: "Public Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;

  --u: 12px; /* the form's rule module */
  --radius: 3px;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
  -webkit-text-size-adjust: 100%;
  scrollbar-color: var(--rule-strong) transparent;
}

body {
  margin: 0;
  font-family: var(--text);
  font-size: 15px;
  line-height: 1.6;
  color: var(--ink-deep);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  caret-color: var(--red);
}

::selection {
  background: var(--canary);
  color: var(--ink-deep);
}

img,
svg {
  display: block;
}

a {
  color: inherit;
  text-underline-offset: 0.2em;
  text-decoration-thickness: 1px;
}

button,
input {
  font: inherit;
  color: inherit;
}

h1,
h2,
h3,
h4 {
  margin: 0;
  font-family: var(--display);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -0.01em;
  color: var(--ink);
  text-wrap: balance;
}

p {
  margin: 0;
  text-wrap: pretty;
}

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

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.tabular {
  font-variant-numeric: tabular-nums;
}

/* Wordmark: a printed ball and the name set wide */
.logo {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-family: var(--display);
  font-weight: 850;
  font-stretch: 118%;
  font-size: 21px;
  letter-spacing: 0.01em;
  line-height: 1;
  text-decoration: none;
  color: var(--ink);
}

.logo-mark {
  width: 26px;
  height: 26px;
  flex: none;
}

/* Buttons: printed boxes, solid ink or outlined */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 40px;
  padding: 0 16px;
  border: 1.5px solid var(--ink);
  border-radius: var(--radius);
  background: transparent;
  color: var(--ink);
  font-family: var(--text);
  font-weight: 700;
  font-size: 14px;
  line-height: 1.2;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.15s, color 0.15s, border-color 0.15s;
}

.btn svg {
  flex: none;
}

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

.btn-lg {
  min-height: 52px;
  padding: 0 22px;
  font-size: 16px;
}

.btn-sm {
  min-height: 32px;
  padding: 0 11px;
  font-size: 13px;
}

.btn-ink {
  background: var(--ink);
  color: var(--white);
}

.btn-ink:hover {
  background: var(--ink-deep);
  border-color: var(--ink-deep);
}

.btn-outline {
  background: var(--white);
}

.btn-outline:hover,
.btn-ghost:hover {
  background: var(--canary-2);
}

.btn-ghost {
  border-color: transparent;
  color: var(--ink);
}

.btn-red {
  background: var(--red);
  border-color: var(--red);
  color: #fff;
}

.btn-red:hover {
  background: var(--red-text);
  border-color: var(--red-text);
}

.btn-canary {
  background: var(--canary);
  border-color: var(--canary);
  color: var(--ink-deep);
}

.btn-canary:hover {
  background: #f7e57f;
}

.btn[disabled] {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Rubber stamp: outlined caps that overprint the ink beneath */
.stamp {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 8px 2px;
  border: 2px solid currentColor;
  border-radius: 4px;
  color: var(--red-text);
  font-family: var(--display);
  font-weight: 800;
  font-stretch: 88%;
  font-size: 12px;
  line-height: 1.2;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
  mix-blend-mode: multiply;
}

.stamp-green {
  color: var(--green-ink);
}

.stamp-ink {
  color: var(--ink);
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
