/* UC Campus Rent's pages: a bright scheme with one colour theme per campus (set by data-campus on <html>, or on a
   home-page card). Spacing, type sizes and radii come from tokens.css; the colours here replace its greys.
   Fluid from 320 px phones to 2560 px screens: the root size grows past ~1500 px. */

:root {
  --ink: #172038;
  --body: #434c66;
  --mute: #646c87;
  --paper: #fffdf8;
  --card: #ffffff;
  --line: #ebe5d6;
  --good: #0f7a55;
  --warn: #b45309;
  --bad: #c62828;
  /* the theme: the home page's own, then one per campus */
  --brand: #2548c9;
  --brand-deep: #1a318f;
  --pop: #ffc531;
  --tint: #fff3c9;
  --tint2: #e6edff;
  --shadow-card: 0 1px 2px rgba(23, 32, 56, 0.06), 0 8px 24px rgba(23, 32, 56, 0.08);
  --color-focus: var(--brand-deep);
}

[data-campus="berkeley"] {
  --brand: #003262;
  --brand-deep: #00254a;
  --pop: #fdb515;
  --tint: #fff1c7;
  --tint2: #e1edfa;
}

[data-campus="irvine"] {
  --brand: #0064a4;
  --brand-deep: #004a7a;
  --pop: #ffd200;
  --tint: #fff7bf;
  --tint2: #dcf0fb;
}

[data-campus="riverside"] {
  --brand: #c2410c;
  --brand-deep: #9a3412;
  --pop: #ffb81c;
  --tint: #ffe8cf;
  --tint2: #fff5d1;
}

[data-campus="san_diego"] {
  --brand: #0f766e;
  --brand-deep: #0b5c56;
  --pop: #ffcd00;
  --tint: #d3f4ee;
  --tint2: #fff6c4;
}

[data-campus="ucla"] {
  --brand: #2774ae;
  --brand-deep: #1b5a8a;
  --pop: #ffd100;
  --tint: #fff3b8;
  --tint2: #dbeafa;
}

[data-campus="davis"] {
  --brand: #266041;
  --brand-deep: #1b4730;
  --pop: #ffbf00;
  --tint: #dff3e4;
  --tint2: #fff6cf;
}

[data-campus="merced"] {
  --brand: #7a5c00;
  --brand-deep: #5c4500;
  --pop: #daa900;
  --tint: #fff0c2;
  --tint2: #f3ead6;
}

[data-campus="santa_barbara"] {
  --brand: #b23a2e;
  --brand-deep: #8a2c23;
  --pop: #febc11;
  --tint: #ffe1dc;
  --tint2: #fff3cf;
}

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

html {
  font-size: clamp(1rem, 0.646rem + 0.377vw, 1.25rem);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: var(--type-body-md);
  line-height: var(--lh-body);
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}

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

h1 {
  color: var(--brand-deep);
  font-size: var(--type-display-xxl);
  line-height: 1.1;
  letter-spacing: var(--tracking-display);
  text-wrap: balance;
}

h2 {
  color: var(--brand-deep);
  font-size: var(--type-display-lg);
  line-height: var(--lh-display-lg);
  letter-spacing: var(--tracking-display);
  text-wrap: balance;
}

h3 {
  font-size: var(--type-body-lg);
  line-height: var(--lh-display-sm);
}

a {
  color: inherit;
}

strong {
  color: var(--ink);
}

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

.wrap {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--space-gutter);
}

.skip {
  position: absolute;
  left: var(--space-lg);
  top: -10rem;
  padding: var(--space-sm) var(--space-lg);
  background: var(--brand-deep);
  color: #fff;
  border-radius: var(--radius-md);
  z-index: 5;
}

.skip:focus {
  top: var(--space-sm);
}

/* --- header, nav and the reading-progress bar --------------------------------------------------------------------- */
.top {
  position: sticky;
  top: 0;
  z-index: 4;
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}

.top__in {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0 var(--space-lg);
  padding-block: var(--space-xs);
}

.brand,
.nav a {
  display: inline-flex;
  align-items: center;
  min-height: var(--touch-target);
  text-decoration: none;
}

.brand {
  color: var(--brand-deep);
  font-weight: 700;
}

.brand::before {
  content: "";
  width: 0.9rem;
  height: 0.9rem;
  border-radius: 50%;
  background: var(--pop);
  box-shadow: 0.35rem 0 0 var(--brand);
  margin-right: 0.85rem;
}

.nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xxs);
  margin: 0;
  padding: 0;
  list-style: none;
}

.nav a {
  padding-inline: var(--space-md);
  border-radius: var(--radius-pill);
  font-size: var(--type-body-sm);
  font-weight: 500;
  transition: background var(--duration-fast) var(--ease-standard);
}

.nav a:hover {
  background: var(--tint);
}

.nav a[aria-current="page"] {
  background: var(--brand);
  color: #fff;
}

.progress {
  position: absolute;
  left: 0;
  bottom: -3px;
  width: 100%;
  height: 3px;
  background: var(--pop);
  transform: scaleX(var(--read, 0));
  transform-origin: left;
}

/* --- the hero ------------------------------------------------------------------------------------------------------ */
.hero {
  position: relative;
  overflow: hidden;
  background: var(--tint);
}

/* the moving background, behind the hero's words; with it running, the plain circles step aside */
.hero__fx {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.hero--fx::before,
.hero--fx::after {
  display: none;
}

.hero::before,
.hero::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
}

.hero::before {
  width: 22rem;
  height: 22rem;
  right: -9rem;
  bottom: -12rem;
  background: var(--tint2);
}

.hero::after {
  width: 7rem;
  height: 7rem;
  left: -3rem;
  bottom: -3rem;
  background: var(--pop);
  opacity: 0.55;
}

.hero__in {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: var(--space-2xl);
  padding-block: var(--space-4xl) var(--space-5xl);
}

.intro {
  display: grid;
  justify-items: start;
  gap: var(--space-lg);
  min-width: 0;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  min-height: 2rem;
  padding-inline: var(--space-md);
  background: var(--card);
  border-radius: var(--radius-pill);
  color: var(--brand-deep);
  font-size: var(--type-body-sm);
  font-weight: 700;
}

/* a word of the main heading, drawn: its outline is traced, then its fill sweeps in (common.js builds these) */
.drawn {
  display: inline-block;
  height: 0.78em;
  overflow: visible;
  vertical-align: baseline;
}

.drawn__line {
  fill: none;
  stroke: var(--brand);
  stroke-width: 1.5px;
  stroke-linejoin: round;
  stroke-dasharray: 9em;
  stroke-dashoffset: 9em;
  animation: title-line 1500ms cubic-bezier(0.3, 0.6, 0.3, 1) calc(var(--i) * 110ms) forwards;
}

.drawn__fill {
  fill: currentColor;
  fill-opacity: 0;
  animation: title-fill 700ms ease-in-out calc(1300ms + var(--i) * 110ms) forwards;
}

.lede {
  max-width: 58ch;
  color: var(--body);
  font-size: var(--type-body-lg);
}

.note {
  max-width: var(--measure);
  color: var(--body);
}

.herostat {
  display: grid;
  gap: var(--space-xxs);
  padding: var(--space-lg) var(--space-2xl);
  background: var(--card);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-card);
}

.herostat__value {
  color: var(--brand);
  font-size: clamp(2.75rem, 1.6rem + 6vw, 5rem);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}

.herostat__value small {
  color: var(--body);
  font-size: var(--type-body-lg);
  font-weight: 500;
  letter-spacing: 0;
}

.herostat__sub {
  color: var(--body);
  font-size: var(--type-body-sm);
}

.scrollcue {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  min-height: var(--touch-target);
  color: var(--brand-deep);
  font-weight: 700;
  text-decoration: none;
}

.scrollcue::after {
  content: "↓";
  display: inline-grid;
  place-items: center;
  width: 2rem;
  height: 2rem;
  background: var(--pop);
  border-radius: 50%;
  animation: bob 1.6s var(--ease-standard) infinite;
}

/* the mascot: click it and it cheers */
.mascotbox {
  position: relative;
  display: grid;
  justify-items: center;
  gap: var(--space-lg);
}

.mascot {
  position: relative;
  display: grid;
  place-items: center;
  width: clamp(9rem, 26vw, 17rem);
  padding: var(--space-lg);
  border: 0;
  border-radius: var(--radius-xl);
  background: #fff; /* the logo keeps its own colours */
  box-shadow: 0 0.5rem 0 var(--brand), var(--shadow-card);
  cursor: pointer;
  transition: transform var(--duration-fast) var(--ease-standard), box-shadow var(--duration-fast) var(--ease-standard);
}

.mascot img {
  display: block;
  width: 100%;
  height: clamp(3rem, 9vw, 6rem);
  object-fit: contain;
}

.mascot:hover {
  transform: translateY(-3px) rotate(-2deg);
}

.mascot:active,
.mascot.is-hit {
  transform: translateY(0.35rem);
  box-shadow: 0 0.15rem 0 var(--brand);
}

/* the line under the logo: "Click to cheer along with 12 Gauchos" */
.tally {
  min-height: 1.5em;
  color: var(--brand-deep);
  font-size: 1rem; /* a paragraph: never under 16 px */
  font-weight: 600;
  text-align: center;
}

.tally b {
  display: inline-block;
  font-variant-numeric: tabular-nums;
  font-weight: 800;
}

.tally.is-bump b {
  animation: tally-bump 360ms var(--ease-standard);
}

/* the celebration when the logo is pressed: over the whole screen, and never in the way of a click */
.party {
  position: fixed;
  inset: 0;
  z-index: 50;
  overflow: hidden;
  pointer-events: none;
}

/* the cheer, glowing in the middle of the screen */
.party__cheer {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: var(--space-lg);
  color: #fff;
  font-size: clamp(2.5rem, 11vw, 8rem);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: var(--tracking-display);
  text-align: center;
  -webkit-text-stroke: 2px var(--brand-deep);
  paint-order: stroke fill;
  text-shadow: 0 0 0.12em var(--pop), 0 0 0.4em var(--brand), 0 0 0.9em var(--brand), 0 0 1.6em var(--pop);
  animation: party-cheer 2600ms var(--ease-standard) both;
}

/* confetti in the campus colours, falling from the top */
.party__fall,
.party__shot i {
  display: block;
  width: 0.6rem;
  height: 0.9rem;
  border-radius: 2px;
  background: var(--brand);
}

.party__fall {
  position: absolute;
  top: -1.5rem;
  left: var(--x);
  animation: party-fall var(--time) linear var(--delay) both;
}

.party__fall:nth-child(3n),
.party__shot:nth-child(3n) i {
  height: 0.6rem;
  border-radius: 50%;
  background: var(--pop);
}

.party__fall:nth-child(3n + 1),
.party__shot:nth-child(3n + 1) i {
  background: var(--brand-deep);
}

/* and more of it shot up from a cannon in each bottom corner: the outer piece crosses, the inner one rises and falls */
.party__shot {
  position: absolute;
  bottom: 2.4rem;
  animation: party-across var(--time) linear var(--delay) both;
}

.party__shot--left {
  left: 2.6rem;
}

.party__shot--right {
  right: 2.6rem;
}

.party__shot i {
  animation: party-arc var(--time) var(--delay) both;
}

/* a cannon: a barrel on a wheel, tipped up and inward */
.party__cannon {
  --flip: scaleX(1);
  position: absolute;
  bottom: 1.1rem;
  left: 0.7rem;
  width: 3.4rem;
  height: 1.4rem;
  border: 3px solid var(--ink);
  border-radius: 0.5rem 0.2rem 0.2rem 0.5rem;
  background: var(--brand-deep);
  transform-origin: 25% 50%;
  animation: party-cannon 2600ms var(--ease-standard) both;
}

.party__cannon--right {
  --flip: scaleX(-1);
  left: auto;
  right: 0.7rem;
}

.party__cannon::after {
  content: "";
  position: absolute;
  left: 0.1rem;
  top: 0.35rem;
  width: 1.3rem;
  height: 1.3rem;
  border: 3px solid var(--ink);
  border-radius: 50%;
  background: var(--pop);
}

/* --- chapters: one idea each, alternating backgrounds ----------------------------------------------------------- */
.chapter {
  padding-block: var(--space-section);
}

.chapter--alt {
  background: var(--tint2);
}

.chapter--alt .kicker {
  color: var(--brand-deep);
}

.chapter__in {
  display: grid;
  gap: var(--space-3xl);
  align-items: center;
}

@media (min-width: 56rem) {
  .chapter__in--split {
    grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
    gap: var(--space-5xl);
  }

  .chapter--alt .chapter__in--split > :first-child {
    order: 2;
  }
}

.chapter__text {
  display: grid;
  gap: var(--space-lg);
  min-width: 0;
  max-width: 62ch;
  color: var(--body);
}

.chapter__viz {
  display: grid;
  gap: var(--space-lg);
  min-width: 0;
}

.kicker {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  color: var(--brand);
  font-size: var(--type-body-sm);
  font-weight: 700;
  letter-spacing: var(--tracking-eyebrow);
  text-transform: uppercase;
}

.kicker__n {
  display: inline-grid;
  place-items: center;
  width: 2rem;
  height: 2rem;
  background: var(--pop);
  border-radius: 50%;
  color: var(--ink);
  letter-spacing: 0;
}

.explain {
  display: grid;
  gap: var(--space-xxs);
  padding-left: var(--space-lg);
  border-left: 4px solid var(--pop);
}

.explain h3 {
  color: var(--brand-deep);
  font-size: var(--type-body-md);
}

/* things appear as you reach them (only when scripts run; reduced motion turns the movement off) */
.js .reveal {
  opacity: 0;
  transform: translateY(1.25rem);
  transition: opacity 500ms var(--ease-standard), transform 500ms var(--ease-standard);
}

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

/* --- cards and small pieces ------------------------------------------------------------------------------------- */
.panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--space-lg);
  padding: var(--space-card);
  background: var(--card);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-card);
  min-width: 0;
}

.panel__title {
  color: var(--brand-deep);
  font-size: var(--type-body-md);
  font-weight: 700;
}

.pill {
  display: inline-flex;
  align-items: center;
  justify-self: start;
  min-height: 2rem;
  padding-inline: var(--space-md);
  background: var(--tint);
  border-radius: var(--radius-pill);
  color: var(--brand-deep);
  font-size: var(--type-body-sm);
  font-weight: 700;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs);
  margin: 0;
  padding: 0;
  list-style: none;
}

.chip {
  padding: var(--space-xxs) var(--space-md);
  background: var(--tint);
  border-radius: var(--radius-pill);
  color: var(--brand-deep);
  font-size: var(--type-body-sm);
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}

/* a campus-only ZIP code: outlined, not filled */
.chip--quiet {
  background: transparent;
  box-shadow: inset 0 0 0 2px var(--brand);
  color: var(--brand-deep);
}

.js .chips .chip {
  opacity: 0;
  transform: scale(0.6);
  transition: opacity 300ms var(--ease-standard), transform 300ms var(--ease-standard);
  transition-delay: calc(var(--i, 0) * 45ms);
}

.js .is-in .chip {
  opacity: 1;
  transform: none;
}

.small {
  color: var(--mute);
  font-size: var(--type-body-sm);
  line-height: var(--lh-body-sm);
}

/* horizontal bars that grow when they come into view */
.bars {
  display: grid;
  gap: var(--space-lg);
  margin: 0;
  padding: 0;
  list-style: none;
}

.bar {
  display: grid;
  gap: var(--space-xxs);
}

.bar__label {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0 var(--space-md);
  color: var(--body);
  font-size: var(--type-body-sm);
}

.bar__label b {
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}

.bar__track {
  display: block;
  height: 1.5rem;
  background: var(--tint);
  border-radius: var(--radius-pill);
  overflow: hidden;
}

.bar__fill {
  display: block;
  width: calc(var(--w) * 1%);
  height: 100%;
  background: var(--brand);
  border-radius: var(--radius-pill);
  transform-origin: left;
}

.bar--pop .bar__fill {
  background: var(--pop);
}

.bar--soft .bar__fill {
  background: color-mix(in srgb, var(--brand) 45%, white);
}

.js .bar__fill {
  transform: scaleX(0);
  transition: transform 900ms var(--ease-standard);
  transition-delay: calc(var(--i, 0) * 120ms);
}

.js .is-in .bar__fill {
  transform: none;
}

/* --- the rent chart ----------------------------------------------------------------------------------------------- */
.controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-sm) var(--space-xl);
}

.seg {
  display: inline-flex;
  flex-wrap: wrap;
  gap: var(--space-xxs);
  padding: var(--space-xxs);
  background: var(--tint2);
  border-radius: var(--radius-xl);
}

.chapter--alt .seg {
  background: var(--tint);
}

.seg button,
.toggle {
  min-height: var(--touch-target);
  padding: 0 var(--space-lg);
  border: 0;
  border-radius: var(--radius-pill);
  background: transparent;
  color: var(--brand-deep);
  font: inherit;
  font-size: var(--type-body-sm);
  font-weight: 700;
  cursor: pointer;
}

.seg button[aria-pressed="true"] {
  background: var(--brand);
  color: #fff;
}

.toggle {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  background: var(--tint);
}

.toggle::before {
  content: "";
  width: 1.25rem;
  height: 0.75rem;
  border-radius: var(--radius-sm);
  background: var(--pop);
  box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--pop) 60%, var(--ink));
}

.toggle[aria-pressed="false"] {
  background: transparent;
  box-shadow: inset 0 0 0 1.5px var(--line);
  color: var(--mute);
}

.toggle[aria-pressed="false"]::before {
  background: transparent;
  box-shadow: inset 0 0 0 1.5px var(--mute);
}

.legend {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs) var(--space-xl);
  margin: 0;
  padding: 0;
  list-style: none;
  color: var(--body);
  font-size: var(--type-body-sm);
}

.legend li {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
}

.legend i {
  display: inline-block;
  width: 1.5rem;
  height: 0.75rem;
  border-radius: var(--radius-sm);
}

.legend .key-rent {
  height: 4px;
  background: var(--brand);
}

.legend .key-guess {
  height: 4px;
  background: color-mix(in srgb, var(--brand) 50%, white);
}

.legend .key-band {
  background: color-mix(in srgb, var(--pop) 45%, white);
}

.chart {
  position: relative;
  min-width: 0;
  touch-action: pan-y;
  border-radius: var(--radius-md);
}

.chart__svg {
  display: block;
  max-width: 100%;
  overflow: visible;
}

.chart__grid {
  stroke: var(--line);
}

.chart__tick {
  fill: var(--mute);
  font-size: var(--type-caption);
}

.chart__flag {
  fill: var(--brand-deep);
  font-weight: 700;
}

.chart__rent,
.chart__p50 {
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.chart__rent {
  stroke: var(--brand);
  stroke-width: 3;
}

.chart__area {
  fill: var(--brand);
  opacity: 0.08;
}

.chart__band {
  fill: var(--pop);
  opacity: 0.45;
}

.chart__p50 {
  stroke: color-mix(in srgb, var(--brand) 50%, white);
  stroke-width: 3;
}

.chart__now {
  fill: var(--brand);
  stroke: var(--card);
  stroke-width: 2;
}

.chart__guide {
  stroke: var(--mute);
}

.chart__dot {
  fill: var(--card);
  stroke: var(--brand);
  stroke-width: 2.5;
}

.chart--draw .chart__rent {
  stroke-dasharray: 1;
  animation: draw 1.6s var(--ease-standard) both;
}

.chart--draw .chart__area,
.chart--draw .chart__band,
.chart--draw .chart__p50,
.chart--draw .chart__now,
.chart--draw .chart__flag {
  animation: fade 600ms var(--ease-standard) 1.1s both;
}

.tooltip {
  position: absolute;
  top: 0;
  max-width: min(18rem, 100%);
  padding: var(--space-xs) var(--space-md);
  background: var(--brand-deep);
  color: #fff;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-3);
  font-size: var(--type-body-sm);
  line-height: var(--lh-body-sm);
  pointer-events: none;
}

.tooltip strong {
  color: #fff;
}

.tooltip[hidden] {
  display: none;
}

/* --- the table behind the chart ----------------------------------------------------------------------------------- */
summary {
  display: flex;
  align-items: center;
  min-height: var(--touch-target);
  color: var(--brand-deep);
  cursor: pointer;
  font-weight: 700;
}

.table-wrap {
  max-height: 24rem;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--type-body-sm);
  font-variant-numeric: tabular-nums;
}

th,
td {
  padding: var(--space-xs) var(--space-md);
  text-align: right;
  white-space: nowrap;
  border-bottom: 1px solid var(--line);
}

th:first-child,
td:first-child {
  text-align: left;
}

thead th {
  position: sticky;
  top: 0;
  background: var(--tint);
  color: var(--brand-deep);
}

/* --- the affordability meter and the try-it-yourself sliders ---------------------------------------------------- */
.donut {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: var(--space-xl);
}

.donut svg {
  width: clamp(7rem, 30vw, 10rem);
  height: auto;
  transform: rotate(-90deg);
}

.donut__track,
.donut__fill,
.donut__line {
  fill: none;
  stroke-width: 12;
}

.donut__track {
  stroke: var(--tint);
}

.donut__fill {
  stroke: var(--brand);
  stroke-linecap: round;
  stroke-dasharray: var(--v) 100;
}

.js .donut__fill {
  stroke-dasharray: 0 100;
  transition: stroke-dasharray 1.2s var(--ease-standard);
}

.js .is-in .donut__fill {
  stroke-dasharray: var(--v) 100;
}

.donut__line {
  stroke: var(--ink);
  stroke-width: 18;
  stroke-dasharray: 0.8 99.2;
  stroke-dashoffset: -29.6;
}

.donut__value {
  color: var(--brand);
  font-size: var(--type-stat);
  font-weight: 700;
  line-height: var(--lh-stat);
  font-variant-numeric: tabular-nums;
}

.try {
  display: grid;
  gap: var(--space-md);
}

.try label,
.try__row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-xs) var(--space-md);
  font-weight: 700;
}

.try output {
  color: var(--brand);
  font-variant-numeric: tabular-nums;
}

input[type="range"] {
  width: 100%;
  min-height: var(--touch-target);
  margin: 0;
  accent-color: var(--brand);
  cursor: pointer;
}

.meter {
  position: relative;
  height: 1.5rem;
  background: var(--tint);
  border-radius: var(--radius-pill);
}

.meter__fill {
  display: block;
  width: calc(var(--w) * 1%);
  height: 100%;
  background: var(--state, var(--brand));
  border-radius: var(--radius-pill);
  transition: width var(--duration-base) var(--ease-standard), background var(--duration-base) var(--ease-standard);
}

.meter__line {
  position: absolute;
  left: 30%;
  top: -0.35rem;
  bottom: -0.35rem;
  width: 3px;
  background: var(--ink);
  border-radius: 2px;
}

.meter__cap {
  display: flex;
  justify-content: space-between;
  color: var(--mute);
  font-size: var(--type-caption);
}

.try__result {
  color: var(--ink);
  font-weight: 500;
}

.try__result b {
  color: var(--state, var(--brand));
}

/* --- homes: one little house per home (or per N homes) ---------------------------------------------------------- */
.houses {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.house {
  width: 0.85rem;
  height: 0.85rem;
  background: var(--brand);
  clip-path: polygon(50% 0, 100% 42%, 100% 100%, 0 100%, 0 42%);
}

.houses--pop .house {
  background: color-mix(in srgb, var(--pop) 80%, var(--ink));
}

.js .house {
  opacity: 0;
  transform: translateY(-0.5rem) scale(0.5);
  transition: opacity 250ms var(--ease-standard), transform 250ms var(--ease-standard);
  transition-delay: calc(var(--i, 0) * 9ms);
}

.js .is-in .house {
  opacity: 1;
  transform: none;
}

.figure {
  color: var(--brand);
  font-size: var(--type-stat);
  font-weight: 700;
  line-height: var(--lh-stat);
  font-variant-numeric: tabular-nums;
}

/* --- openings ----------------------------------------------------------------------------------------------------- */
.openings {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 22rem), 1fr));
  gap: var(--space-grid);
  margin: 0;
  padding: 0;
  list-style: none;
}

.opening {
  display: grid;
  align-content: start;
  gap: var(--space-md);
  padding: var(--space-card);
  background: var(--card);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-card);
  color: var(--body);
}

.opening h3 {
  color: var(--brand-deep);
}

.range {
  position: relative;
  height: 2.5rem;
  margin-block: var(--space-xs) var(--space-lg);
}

.range__axis {
  position: absolute;
  inset: 50% 0 auto;
  height: 2px;
  background: var(--line);
}

.range__span {
  position: absolute;
  top: calc(50% - 0.4rem);
  left: calc(var(--lo) * 1%);
  width: calc((var(--hi) - var(--lo)) * 1%);
  height: 0.8rem;
  background: var(--pop);
  border-radius: var(--radius-pill);
}

.range__mid {
  position: absolute;
  top: calc(50% - 0.6rem);
  left: calc(var(--at) * 1% - 0.6rem);
  width: 1.2rem;
  height: 1.2rem;
  background: var(--brand);
  border: 3px solid var(--card);
  border-radius: 50%;
}

.range__zero {
  position: absolute;
  top: 0;
  bottom: 0;
  left: calc(var(--zero) * 1%);
  width: 2px;
  background: var(--ink);
}

.range__zero::after {
  content: "no change";
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  color: var(--mute);
  font-size: var(--type-caption);
  white-space: nowrap;
}

.js .range__span {
  transform: scaleX(0);
  transition: transform 800ms var(--ease-standard) 200ms;
}

.js .is-in .range__span {
  transform: none;
}

/* --- the home page: one row per campus (logo, name, rent bar) and the list of terms ------------------------------ */
.rows {
  display: grid;
  gap: var(--space-md);
  margin: 0;
  padding: 0;
  list-style: none;
}

.row {
  display: grid;
  grid-template-columns: 11rem minmax(0, 1fr) minmax(0, 1.4fr);
  align-items: center;
  gap: var(--space-lg);
  min-height: var(--touch-target);
  padding: var(--space-lg);
  background: var(--card);
  border: 1px solid var(--line);
  border-left: 6px solid var(--brand);
  border-radius: var(--radius-xl);
  text-decoration: none;
  transition: background var(--duration-base) var(--ease-standard), transform var(--duration-base) var(--ease-standard);
}

.row:hover,
.row:focus-visible {
  background: var(--tint);
}

/* the rows pop in one after another when the list comes into view (the second timing is a spring, where a browser
   knows linear()) */
.js .rows > li:not(.rows__ring) {
  opacity: 0;
  transform: translateY(12px) scale(0.8);
  transition: transform 620ms cubic-bezier(0.34, 1.4, 0.64, 1), opacity 300ms var(--ease-standard);
  transition-timing-function: linear(0, 0.06, 0.2, 0.38, 0.56, 0.73, 0.86, 0.96, 1.02, 1.06, 1.08, 1.08, 1.07, 1.06, 1.05, 1.03, 1.02, 1.01, 1, 1), var(--ease-standard);
  transition-delay: calc(var(--i) * 60ms);
}

.js .rows.is-in > li:not(.rows__ring) {
  opacity: 1;
  transform: none;
}

/* a ring in the row's campus colour that slides to the row under the pointer or the keyboard */
.rows {
  position: relative;
}

.rows__ring {
  position: absolute;
  inset: 0 0 auto;
  height: 0;
  border-radius: var(--radius-xl);
  box-shadow: 0 0 0 3px var(--brand), 0 0.6rem 1.4rem -0.6rem var(--brand);
  opacity: 0;
  pointer-events: none;
  transition: transform 380ms cubic-bezier(0.34, 1.4, 0.64, 1), height 380ms cubic-bezier(0.34, 1.4, 0.64, 1), opacity 200ms var(--ease-standard);
}

.rows__ring.is-on {
  opacity: 1;
}

/* the logos keep their own colours, so they always sit on white */
.row__logo {
  display: grid;
  align-items: center;
  height: 4rem;
  padding: var(--space-sm) var(--space-md);
  background: #fff;
  border-radius: var(--radius-md);
}

.row__logo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: left center;
}

.row__name {
  display: grid;
  gap: var(--space-xxs);
}

.row h3 {
  color: var(--brand-deep);
  font-size: var(--type-display-sm);
}

.row__meta {
  color: var(--body);
  font-size: var(--type-body-sm);
}

/* the face-off: two campuses picked from lists, their rents as two bars on one scale */
.faceoff {
  display: grid;
  gap: var(--space-lg);
  margin-top: var(--space-xl);
}

.faceoff__picks {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  gap: var(--space-md) var(--space-lg);
}

.faceoff__pick {
  display: grid;
  gap: var(--space-xxs);
  color: var(--body);
  font-size: var(--type-body-sm);
  font-weight: 700;
}

/* the pick-one menu (glide.js): a button showing the choice, and a list whose highlight glides from row to row */
.glide {
  position: relative;
  display: inline-block;
}

.glide__trigger {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
  min-width: 13rem;
  min-height: var(--touch-target);
  padding: 0 var(--space-md) 0 var(--space-lg);
  border: 2px solid var(--brand);
  border-radius: var(--radius-md);
  background: #fff;
  color: var(--brand-deep);
  font: inherit;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  touch-action: manipulation;
  transition: background var(--duration-fast) var(--ease-standard), transform 160ms cubic-bezier(0.23, 1, 0.32, 1);
}

.glide__trigger:hover,
.glide__trigger[aria-expanded="true"] {
  background: var(--tint);
}

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

.glide__label.is-swap {
  animation: glide-swap 160ms ease;
}

/* a chevron, drawn: it turns over while the menu is open */
.glide__chevron {
  width: 0.5rem;
  height: 0.5rem;
  margin-top: -0.25rem;
  border-right: 2.5px solid var(--brand);
  border-bottom: 2.5px solid var(--brand);
  transform: rotate(45deg);
  transition: transform 200ms cubic-bezier(0.23, 1, 0.32, 1);
}

.glide__trigger[aria-expanded="true"] .glide__chevron {
  margin-top: 0.25rem;
  transform: rotate(225deg);
}

.glide__menu {
  position: absolute;
  left: 0;
  z-index: 20;
  width: max-content;
  min-width: 100%;
  max-width: calc(100vw - 2 * var(--space-lg));
  padding: 4px;
  border: 2px solid var(--ink);
  border-radius: var(--radius-md);
  background: #fff;
  box-shadow: 4px 4px 0 var(--brand);
  opacity: 0;
  transform: scale(0.95);
  transform-origin: top left;
  transition: opacity 180ms cubic-bezier(0.23, 1, 0.32, 1), transform 180ms cubic-bezier(0.23, 1, 0.32, 1);
}

.glide__menu[data-state="open"] {
  opacity: 1;
  transform: none;
}

.glide__menu[data-state="closed"] {
  transition-duration: 120ms;
  pointer-events: none;
}

.glide__menu[data-side="bottom"] {
  top: calc(100% + 6px);
}

.glide__menu[data-side="top"] {
  bottom: calc(100% + 6px);
  transform-origin: bottom left;
}

.glide__list {
  position: relative;
  display: grid;
  gap: 1px;
}

.glide__pill {
  position: absolute;
  inset: 0 0 auto;
  height: 2.5rem;
  border-radius: var(--radius-sm);
  background: var(--tint);
  opacity: 0;
  pointer-events: none;
  transition: transform 220ms cubic-bezier(0.23, 1, 0.32, 1), opacity 150ms ease;
}

.glide__option {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: var(--space-md);
  min-height: 2.5rem;
  padding: 0 var(--space-sm) 0 var(--space-md);
  border-radius: var(--radius-sm);
  color: var(--ink);
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  user-select: none;
}

/* the chosen row is tinted until the highlight starts to move */
.glide__option[aria-selected="true"] {
  background: var(--tint);
}

.glide__list[data-live] .glide__option[aria-selected="true"] {
  background: transparent;
}

.glide__name {
  flex: 1 1 auto;
  white-space: nowrap;
}

.glide__tag {
  color: var(--body);
  font-size: var(--type-body-sm);
  font-variant-numeric: tabular-nums;
  font-weight: 400;
}

/* a tick, drawn, on the chosen row */
.glide__check {
  width: 0.4rem;
  height: 0.75rem;
  margin: 0 0.3rem 0.2rem;
  border-right: 2.5px solid var(--brand);
  border-bottom: 2.5px solid var(--brand);
  transform: rotate(45deg);
  visibility: hidden;
}

.glide__option[aria-selected="true"] .glide__check {
  visibility: visible;
}

.faceoff__vs {
  padding-bottom: 0.6rem;
  color: var(--brand-deep);
  font-weight: 800;
}

/* the dog park: every campus's dog in a row, each a link to its campus, with its cheers */
.park {
  padding-block: var(--space-section);
  background: var(--tint2);
}

.park p {
  margin-top: var(--space-md);
  color: var(--body);
}

.park__dogs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-lg);
  margin: var(--space-xl) 0 0;
  padding: 0;
  list-style: none;
}

.park__dog {
  display: grid;
  justify-items: center;
  gap: var(--space-xs);
  height: 100%;
  padding: var(--space-lg) var(--space-sm) var(--space-md);
  background: var(--card);
  border: 1px solid var(--line);
  border-bottom: 5px solid var(--brand);
  border-radius: var(--radius-xl);
  text-align: center;
  text-decoration: none;
  transition: background var(--duration-base) var(--ease-standard), transform var(--duration-base) var(--ease-standard);
}

.park__dog:hover,
.park__dog:focus-visible {
  background: var(--tint);
  transform: translateY(-3px);
}

.park__name {
  color: var(--brand-deep);
  font-weight: 700;
}

.park__n {
  color: var(--body);
  font-size: var(--type-body-sm);
}

/* its place in the cheering: a small plate, filled for the leader (or the leaders, when they're tied) */
.park__rank {
  padding: 0.1rem var(--space-md);
  border: 2px solid var(--brand);
  border-radius: var(--radius-pill);
  color: var(--brand-deep);
  font-size: var(--type-body-sm);
  font-weight: 800;
}

.is-lead .park__rank {
  background: var(--brand);
  color: #fff;
}

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

/* the shelf of caps: one per campus in its colour, hollow until its dog has been petted */
.caps {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  min-height: var(--touch-target);
}

.cap {
  position: relative;
  width: 1.1rem;
  height: 0.65rem;
  border: 2px solid var(--ink);
  border-radius: 0.6rem 0.6rem 0 0;
  opacity: 0.3;
}

.cap::after {
  content: "";
  position: absolute;
  right: -0.45rem;
  bottom: -2px;
  width: 0.5rem;
  height: 2px;
  background: var(--ink);
}

.cap.is-got {
  background: var(--brand);
  opacity: 1;
}

.caps__n {
  margin-left: var(--space-xs);
  color: var(--body);
  font-size: var(--type-body-sm);
  font-weight: 700;
}

/* the flat in the try-it card: a pixel person for each one splitting the rent, their share over their head */
.flat {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: center;
  gap: var(--space-sm) var(--space-lg);
  min-height: 7.5rem;
  padding: var(--space-md) var(--space-md) 0;
  background: var(--tint2);
  border: 3px solid var(--ink);
  border-bottom-width: 8px;
}

.chapter--alt .flat {
  background: var(--tint);
}

.flat__mate {
  display: grid;
  justify-items: center;
  gap: 2px;
  color: var(--body);
  font-size: var(--type-body-sm);
  animation: mate-in 320ms var(--ease-standard) both;
}

.flat__mate b {
  color: var(--brand-deep);
}

.flat__mate canvas {
  display: block;
  width: 2.5rem;
  height: auto;
  image-rendering: pixelated;
}

.terms {
  margin: 0;
  border-top: 2px solid var(--ink);
}

.terms > div {
  display: grid;
  grid-template-columns: minmax(0, 14rem) minmax(0, 1fr);
  gap: var(--space-xs) var(--space-xl);
  padding-block: var(--space-lg);
  border-bottom: 1px solid var(--line);
}

.terms dt {
  color: var(--ink);
  font-size: var(--type-display-sm);
  font-weight: 700;
}

.terms dd {
  margin: 0;
}

@media (max-width: 48rem) {
  .row,
  .terms > div {
    grid-template-columns: minmax(0, 1fr);
  }

  .row__logo {
    width: 11rem;
  }
}

/* --- messages and buttons ----------------------------------------------------------------------------------------- */
.message {
  display: grid;
  justify-items: start;
  gap: var(--space-md);
  padding: var(--space-lg);
  border-radius: var(--radius-md);
  background: var(--card);
}

.message--error {
  border-left: 4px solid var(--bad);
}

.button {
  min-height: var(--touch-target);
  padding: 0 var(--space-xl);
  border: 0;
  border-radius: var(--radius-pill);
  background: var(--brand);
  color: #fff;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.links {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
  margin: 0;
  padding: 0;
  list-style: none;
}

.links a {
  display: inline-flex;
  align-items: center;
  min-height: var(--touch-target);
  padding-inline: var(--space-lg);
  background: var(--card);
  border-radius: var(--radius-pill);
  color: var(--brand-deep);
  font-weight: 700;
  text-decoration: none;
}

/* --- footer ------------------------------------------------------------------------------------------------------- */
.foot {
  display: grid;
  gap: var(--space-sm);
  padding-block: var(--space-2xl) var(--space-4xl);
  border-top: 1px solid var(--line);
  color: var(--body);
}

.foot ul {
  display: grid;
  gap: var(--space-xxs);
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: var(--type-body-sm);
}

[hidden] {
  display: none !important;
}

@media (max-width: 40rem) {
  .hero__in {
    grid-template-columns: minmax(0, 1fr);
    padding-block: var(--space-2xl) var(--space-4xl);
  }

  .mascotbox {
    grid-row: 1;
    grid-auto-flow: column;
    justify-content: start;
    align-items: center;
  }

  .donut {
    grid-template-columns: minmax(0, 1fr);
  }
}

@keyframes bob {
  50% {
    transform: translateY(5px);
  }
}

@keyframes glide-swap {
  from {
    opacity: 0.6;
    filter: blur(2px);
  }
}

@keyframes mate-in {
  from {
    opacity: 0;
    transform: translateY(12px) scale(0.6);
  }
}

@keyframes tally-bump {
  35% {
    color: var(--brand);
    transform: translateY(-4px) scale(1.4);
  }
}

@keyframes party-cheer {
  0% {
    opacity: 0;
    transform: scale(0.4);
  }

  14% {
    opacity: 1;
    transform: scale(1.08);
  }

  24% {
    transform: scale(1);
  }

  80% {
    opacity: 1;
    transform: scale(1);
  }

  100% {
    opacity: 0;
    transform: scale(1.06);
  }
}

@keyframes party-fall {
  to {
    transform: translate(var(--drift), 108vh) rotate(var(--spin));
  }
}

@keyframes party-across {
  to {
    transform: translateX(var(--dx));
  }
}

@keyframes party-arc {
  0% {
    transform: translateY(0) rotate(0deg);
    animation-timing-function: cubic-bezier(0.15, 0.7, 0.4, 1);
  }

  45% {
    transform: translateY(calc(-1 * var(--up))) rotate(calc(var(--spin) * 0.5));
    animation-timing-function: cubic-bezier(0.6, 0, 0.9, 0.5);
  }

  100% {
    transform: translateY(12vh) rotate(var(--spin));
  }
}

@keyframes party-cannon {
  0%,
  100% {
    transform: translateY(6rem) var(--flip) rotate(-50deg);
  }

  9%,
  20%,
  86% {
    transform: translateY(0) var(--flip) rotate(-50deg);
  }

  13% {
    transform: translateY(0.5rem) var(--flip) rotate(-42deg); /* the kick as it fires */
  }
}

@keyframes title-line {
  to {
    stroke-dashoffset: 0;
  }
}

@keyframes title-fill {
  from {
    clip-path: inset(-20% 100% -40% -5%);
    fill-opacity: 1;
  }

  to {
    clip-path: inset(-20% -5% -40% -5%);
    fill-opacity: 1;
  }
}

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

@keyframes fade {
  from {
    opacity: 0;
  }
}

/* --- the tip dogs: a pixel-art dog beside a speech bubble; petting it barks the next tip ------------------------- */
/* text with its dog beside it, so the line length doesn't leave the right half empty */
.chapter__head {
  display: grid;
  gap: var(--space-xl);
  align-items: end;
}

@media (min-width: 56rem) {
  .chapter__head {
    grid-template-columns: minmax(0, 62ch) minmax(16rem, 1fr);
    gap: var(--space-4xl);
  }

  .hero .dog {
    max-width: 26rem;
  }
}

.dog {
  display: flex;
  align-items: flex-end;
  gap: var(--space-md);
  min-width: 0;
  padding: 0;
  border: 0;
  background: none;
  color: var(--ink);
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.dog__pet {
  position: relative;
  flex: none;
  width: 7.5rem;
  transition: transform var(--duration-fast) var(--ease-standard);
}

.dog:hover .dog__pet {
  transform: translateY(-3px) rotate(-3deg);
}

.dog__frame {
  display: block;
  width: 100%;
  height: auto;
  image-rendering: pixelated;
}

/* the hop when it's petted; dog.js redraws the canvas for the bark, the tail and the blink */
.is-bark .dog__pet {
  animation: bark 480ms var(--ease-standard);
}

/* the name on the cap follows the head: upside down on the ground when it rolls over, five rows down when it naps */
.is-roll .dog__tag {
  top: 78.9%;
  transform: rotate(180deg);
}

.is-nap .dog__tag {
  transform: translateY(166%);
}

/* in its party hat there's no cap to carry the name */
.is-party .dog__tag {
  display: none;
}

/* z's rising from its head to the top right while it's sleepy or asleep */
.dog__zzz {
  position: absolute;
  right: 12%;
  top: 8%;
  width: 1rem;
  height: 1rem;
  color: var(--brand-deep);
  font-family: ui-monospace, "Cascadia Mono", Consolas, monospace;
  font-style: normal;
  font-weight: 700;
  line-height: 1;
  visibility: hidden;
  pointer-events: none;
}

.is-nap .dog__zzz {
  top: 30%;
}

.dog__zzz i {
  position: absolute;
  font-style: normal;
  opacity: 0;
}

.is-sleepy .dog__zzz {
  visibility: visible;
}

.is-sleepy .dog__zzz i {
  animation: zzz 2400ms steps(8) infinite;
}

.is-sleepy .dog__zzz i:nth-child(2) {
  animation-delay: 800ms;
}

.is-sleepy .dog__zzz i:nth-child(3) {
  animation-delay: 1600ms;
}

/* the campus's short name, laid over the cap's crown (columns 8 to 15, rows 1 to 3 of the 24×19 drawing) */
.dog__tag {
  position: absolute;
  left: 33.3%;
  top: 5.3%;
  display: grid;
  place-items: center;
  width: 33.4%;
  height: 15.8%;
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.02em;
  white-space: nowrap;
  /* a one-pixel outline, so the name reads where a pointed ear crosses the cap */
  text-shadow: -1px 0 var(--ink), 1px 0 var(--ink), 0 -1px var(--ink), 0 1px var(--ink);
}

.dog__woof {
  position: absolute;
  right: -0.5rem;
  top: -0.75rem;
  color: var(--brand-deep);
  font-weight: 700;
  opacity: 0;
  pointer-events: none;
}

.is-bark .dog__woof {
  animation: woof 700ms var(--ease-standard);
}

.dog__bubble {
  position: relative;
  display: grid;
  gap: var(--space-xs);
  margin-bottom: 2.75rem; /* its tail is level with the dog's mouth */
  padding: var(--space-md) var(--space-lg);
  background: #fff;
  border: 3px solid var(--ink);
  box-shadow: 4px 4px 0 var(--brand);
  font-weight: 600;
  line-height: 1.4;
}

.dog__bubble::after {
  content: "";
  position: absolute;
  left: -11px;
  bottom: 12px;
  width: 8px;
  height: 8px;
  background: var(--ink);
  box-shadow: -8px 8px 0 var(--ink); /* a two-pixel stepped tail toward the dog */
}

.dog__bubble b {
  color: var(--brand-deep);
}

.dog__more {
  color: var(--mute);
  font-size: var(--type-body-sm);
  font-weight: 400;
}

.dog__more:empty {
  display: none;
}

@media (max-width: 30rem) {
  .dog__pet {
    width: 7rem;
  }

  /* paragraphs stay 16 px on phones, the small labels and notes too */
  p.eyebrow,
  p.kicker,
  p.small {
    font-size: 1rem;
  }
}

@keyframes zzz {
  0% {
    opacity: 0;
    transform: translate(0, 0) scale(0.7);
  }

  20% {
    opacity: 1;
  }

  100% {
    opacity: 0;
    transform: translate(1.75rem, -2.25rem) scale(1.3);
  }
}

@keyframes bark {
  25% {
    transform: translateY(-12px) rotate(-5deg);
  }

  50% {
    transform: translateY(0);
  }

  75% {
    transform: translateY(-7px) rotate(4deg);
  }
}

@keyframes woof {
  0% {
    opacity: 0;
    transform: translateY(6px) scale(0.8);
  }

  30% {
    opacity: 1;
    transform: translateY(-6px) scale(1.1);
  }

  100% {
    opacity: 0;
    transform: translateY(-22px);
  }
}

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

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }

  .js .reveal,
  .js .rows > li:not(.rows__ring),
  .js .chips .chip,
  .js .house,
  .js .bar__fill,
  .js .range__span {
    opacity: 1;
    transform: none;
  }

  .js .donut__fill {
    stroke-dasharray: var(--v) 100;
  }
}
