@font-face {
  font-family: Geist;
  src: url("./brand/geist-variable.woff2") format("woff2");
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}

:root {
  color-scheme: light;
  font-family: Geist, "Segoe UI", sans-serif;
  --ink: #172b37;
  --muted: #4e6068;
  --paper: #f4f7f6;
  --white: #fff;
  --nav: #142e38;
  --nav-light: #b9cdd0;
  --line: #d6e1dd;
  --green: #126453;
  --green-dark: #094c3e;
  --mint: #dcefe7;
  --warning: #75501b;
  --warning-bg: #fff4dc;
  --curve: cubic-bezier(.22, 1, .36, 1);
}

*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; background: var(--paper); color: var(--ink); font-size: 1rem; line-height: 1.5; }
h1, h2, h3, p, dl, dd { margin: 0; }
h1, h2, h3 { text-wrap: balance; }
p { text-wrap: pretty; }
small { font-size: .75rem; line-height: 1rem; }
strong { font-weight: 650; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
button, input, select { font: inherit; }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible {
  outline: 3px solid #1d9880;
  outline-offset: 3px;
}
main:focus { outline: none; }

.heading-1 { font-size: 3.75rem; line-height: 1; font-weight: 650; letter-spacing: -.055em; }
.heading-2 { font-size: 3rem; line-height: 1; font-weight: 650; letter-spacing: -.045em; }
.heading-3 { font-size: 2.25rem; line-height: 2.5rem; font-weight: 650; letter-spacing: -.035em; }
.heading-4 { font-size: 1.875rem; line-height: 2.25rem; font-weight: 650; letter-spacing: -.035em; }
.heading-5 { font-size: 1.5rem; line-height: 2rem; font-weight: 650; letter-spacing: -.02em; }
.heading-6 { font-size: 1.25rem; line-height: 1.75rem; font-weight: 650; letter-spacing: -.02em; }
.title-1 { font-size: 1.25rem; line-height: 1.75rem; font-weight: 550; }
.title-4, .body-5 { font-size: .875rem; line-height: 1.25rem; font-weight: 550; }
.body-3 { font-size: 1rem; line-height: 1.5rem; }
.body-6 { font-size: .875rem; line-height: 1.25rem; }
.muted { color: var(--muted); }

.skip { position: fixed; z-index: 10; top: 12px; left: 12px; transform: translateY(-150%); }
.skip:focus { transform: none; }
.button {
  display: inline-flex; gap: 8px; align-items: center; justify-content: center; width: fit-content; max-width: 100%;
  border: 1px solid transparent; border-radius: 8px; padding: 8px 12px; background: var(--green);
  color: var(--white); text-decoration: none; cursor: pointer; overflow-wrap: anywhere; text-align: center;
  transition: transform 280ms var(--curve);
}
.button:hover { background: var(--green-dark); }
.button:active:not(:disabled) { transform: scale(.98); }
.button:disabled { cursor: default; background: #dce4e0; color: #53645d; }
.button-md { font-size: 1rem; line-height: 1.5rem; font-weight: 650; }
.button-sm { font-size: .875rem; line-height: 1.25rem; font-weight: 650; }
.button.secondary { color: var(--green-dark); background: var(--white); border-color: var(--line); }
.button.secondary:hover { background: var(--mint); }
.button.light { background: #d2efe2; color: #153d35; }
.button.light:hover { background: #b6e4d1; }
.text-link { color: var(--green-dark); font-weight: 650; text-underline-offset: 3px; overflow-wrap: anywhere; }
.text-link:hover { color: var(--green); }
.text-button { background: transparent; border: 0; color: inherit; cursor: pointer; padding: 4px; }
.text-button:hover { text-decoration: underline; }

.workspace { display: grid; grid-template-columns: 232px minmax(0, 1fr); min-height: 100dvh; }
.sidebar {
  position: sticky; top: 0; height: 100dvh; display: flex; flex-direction: column; gap: 32px;
  background: var(--nav); color: #f6fbfb; padding: 32px 16px 16px;
}
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; min-width: 0; }
.brand img { flex: none; padding: 4px; background: #fff; border-radius: 8px; }
.brand strong { display: block; font-size: 1rem; font-weight: 700; letter-spacing: .08em; }
.brand small { display: block; color: var(--nav-light); }
.sidebar nav { display: grid; gap: 4px; }
.sidebar nav a {
  color: #d3e1e2; border-radius: 8px; padding: 8px 12px;
  text-decoration: none; font-size: .875rem; line-height: 1.25rem; font-weight: 550;
  border: 1px solid transparent;
}
.sidebar nav a:hover { background: #21434d; color: white; }
.sidebar nav a[aria-current="page"] { color: #dcf4e8; background: #285349; border-color: #416e63; }
.profile {
  display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 8px;
  border-top: 1px solid #36515b; margin-top: auto; padding-top: 16px;
  font-size: .75rem; line-height: 1rem; overflow-wrap: anywhere;
}
.profile a { display: block; color: var(--nav-light); margin-top: 4px; }
.avatar {
  width: 32px; height: 32px; border-radius: 999px; display: grid; place-items: center;
  background: #36545c; font-weight: 700;
}
.topbar {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 16px 32px; background: var(--white); border-bottom: 1px solid var(--line);
}
.topbar > span { color: var(--muted); }
.year-form { display: flex; align-items: center; gap: 8px; flex: none; }
.year-form label { font-size: .875rem; line-height: 1.25rem; color: var(--muted); }
.year-form select { width: auto; padding: 4px 8px; min-height: 32px; }
.content { padding: 32px; margin-inline: auto; max-width: 1380px; }
.page-head { display: grid; gap: 8px; margin-bottom: 24px; }
.page-head .text-link { font-size: .875rem; line-height: 1.25rem; width: fit-content; margin-bottom: 4px; }

.banner {
  display: flex; align-items: center; justify-content: space-between; gap: 24px; overflow: hidden;
  background: #17413c; color: #fff; border-radius: 16px; padding: 32px; min-height: 248px;
}
.banner .title-4 { color: #cae8dc; margin-bottom: 12px; }
.banner p { color: #d7eae3; max-width: 42ch; margin-top: 12px; }
.banner .button { margin-top: 24px; }
.section { margin-top: 24px; }
.tool-grid, .lower-grid { display: grid; gap: 16px; }
.tool-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); margin-top: 12px; }
.lower-grid { grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); }
.card {
  background: var(--white); border: 1px solid var(--line); border-radius: 12px; padding: 24px;
  min-width: 0;
}
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.card > p { margin-top: 8px; }
.card > .button { margin-top: 12px; }
.tool-card {
  position: relative; display: flex; flex-direction: column; gap: 16px;
  text-decoration: none; padding-right: 40px; transition: transform 280ms var(--curve);
}
.tool-card:hover { transform: translateY(-2px); border-color: #71a996; }
.tool-card:active { transform: scale(.98); }
.tool-label {
  width: fit-content; color: var(--green-dark); background: var(--mint); border-radius: 6px;
  font-size: .75rem; line-height: 1rem; letter-spacing: .05em; font-weight: 700; padding: 4px 8px;
}
.tool-arrow { position: absolute; right: 24px; top: 24px; color: var(--green); font-size: 1.125rem; line-height: 1.75rem; }
.tool-card p { margin-top: 4px; }
.record {
  display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 8px;
  text-decoration: none; padding: 12px; border-radius: 8px; background: #f5f8f7;
  font-size: .875rem; line-height: 1.25rem;
}
.record:hover { background: var(--mint); }
.record strong, td strong { overflow-wrap: anywhere; }
.record small, td small { display: block; margin-top: 4px; color: var(--muted); }
.status {
  display: inline-flex; align-items: center; border-radius: 999px; padding: 4px 8px;
  background: #e9efed; color: #455952; font-size: .75rem; line-height: 1rem; font-weight: 650;
}
.status.success, .status.ready { background: var(--mint); color: var(--green-dark); }
.status.running, .status.pending, .status.queued { background: #e6effa; color: #214d71; }
.status.failed, .status.invalid { background: var(--warning-bg); color: var(--warning); }
.empty { padding: 12px 0; }
.notice {
  padding: 12px; border: 1px solid var(--line); border-radius: 8px;
  background: #e9f2ef; color: #234d45; overflow-wrap: anywhere; font-size: .875rem; line-height: 1.25rem;
}
.notice.success { background: var(--mint); margin-bottom: 16px; }
.notice.warning { background: var(--warning-bg); border-color: #efd5a1; color: var(--warning); }
.warning-text, td .warning-text { color: var(--warning); }
.notice .errorlist, .field-error .errorlist { margin: 0; padding-inline-start: 16px; }

.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.form-stack { display: grid; gap: 16px; }
.card h2 + form, .card h2 + .table-wrap { margin-top: 16px; }
.field { display: grid; align-content: start; min-width: 0; gap: 4px; }
.field label { font-size: .875rem; line-height: 1.25rem; font-weight: 650; }
.field-error { color: #92282c; font-size: .875rem; line-height: 1.25rem; }
input:not([type="hidden"]), select {
  min-height: 40px; width: 100%; min-width: 0; padding: 8px 12px;
  border: 1px solid #aabfb7; border-radius: 8px; background: white; color: var(--ink);
  font-size: .875rem; line-height: 1.25rem;
}
input[type="file"] { min-height: 48px; }
input[type="file"]::file-selector-button {
  border: 0; background: var(--mint); color: var(--green-dark); padding: 4px 8px; border-radius: 4px;
  font: inherit; font-weight: 650; cursor: pointer; margin-right: 8px;
}
[aria-invalid="true"] { border-color: #92282c !important; }
.form-actions, .form-grid > .notice { grid-column: 1 / -1; }
.form-actions { padding-top: 16px; }
.form-grid > .form-actions { padding-top: 0; }
.review { margin-top: 24px; padding: 16px; border: 1px solid var(--line); border-radius: 8px; background: #f5f8f7; }
.review > :not(:first-child) { margin-top: 12px; }
.metrics { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.metrics dt, .totals dt, .source-list dt { color: var(--muted); font-size: .875rem; line-height: 1.25rem; }
.metrics dd { font-size: 1.5rem; line-height: 2rem; font-weight: 650; }

.table-wrap { overflow-x: auto; margin-top: 12px; }
table { width: 100%; border-collapse: collapse; text-align: left; font-size: .875rem; line-height: 1.25rem; }
th, td { padding: 12px; vertical-align: top; border-bottom: 1px solid var(--line); }
th { color: #3d555b; background: #f3f7f5; font-weight: 650; }
td { min-width: 96px; max-width: 400px; }
.amount, dd { font-variant-numeric: tabular-nums; }
.amount { text-align: right; white-space: nowrap; }
.source-list, .totals { display: grid; gap: 8px; margin-top: 12px; }
.source-list > div, .totals > div { display: grid; grid-template-columns: minmax(96px, 1fr) minmax(0, 2fr); gap: 12px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.source-list dd, .totals dd { overflow-wrap: anywhere; }
.totals dd { text-align: right; font-size: .875rem; line-height: 1.25rem; }
.pagination { display: flex; flex-wrap: wrap; gap: 16px; margin-top: 16px; font-size: .875rem; line-height: 1.25rem; }

.public { min-height: 100dvh; display: grid; place-items: center; padding: 24px; }
.public > main { width: min(100%, 1040px); }
.login-shell {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  border: 1px solid var(--line);
  border-radius: 24px;
  overflow: hidden;
  background: var(--white);
  box-shadow: 0 24px 80px #254b4230;
}
.login-brand {
  display: grid;
  align-content: space-between;
  gap: 24px;
  background: #edf4ea;
  color: var(--ink);
  padding: 32px 40px 40px;
  min-height: 520px;
}
.login-brand .brand small { color: var(--muted); }
.login-copy h1 {
  max-width: 12ch;
  color: #16241c;
  background-image: linear-gradient(100deg, #000, #666);
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.login-copy p { max-width: 38ch; margin-top: 12px; color: var(--muted); }
.login-panel { align-self: center; padding: 48px; }
.login-panel > p { margin-top: 8px; max-width: 38ch; }
.login-panel form { margin-top: 32px; gap: 16px; }
.login-panel input:not([type="hidden"]) { min-height: 48px; }
.login-panel .login-submit {
  width: 100%;
  min-height: 48px;
  justify-content: space-between;
  padding-right: 16px;
}
.login-submit span {
  font-size: 1.25rem;
  line-height: 1.75rem;
  transition: transform 300ms var(--curve);
}
.login-submit:hover span { transform: translateX(4px); }

.password-entry { position: relative; }
.password-entry:has(.password-toggle:not([hidden])) input { padding-inline-end: 3rem; }
.password-toggle {
  position: absolute;
  inset-block: 4px;
  inset-inline-end: 4px;
  width: 40px;
  border: 0;
  border-radius: 6px;
  padding: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}
.password-toggle:not([hidden]) { display: grid; place-items: center; }
.password-toggle:hover { background: var(--mint); color: var(--green-dark); }
.password-toggle:active { transform: scale(.98); }
.password-eye {
  position: relative;
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
}
.password-eye::before {
  content: "";
  width: 15px;
  height: 15px;
  border: 1.5px solid currentColor;
  border-radius: 70% 15%;
  transform: rotate(45deg);
}
.password-eye > span {
  position: absolute;
  width: 5px;
  height: 5px;
  border: 1.5px solid currentColor;
  border-radius: 50%;
}
.password-entry.is-revealed .password-eye::after {
  content: "";
  position: absolute;
  width: 22px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  box-shadow: 0 -2px var(--white);
  transform: rotate(-43deg);
}

.puppy-stage {
  position: relative;
  border-radius: 16px;
}
.puppy-scene {
  position: relative;
  display: grid;
  place-items: center;
  pointer-events: none;
  min-height: 208px;
  overflow: hidden;
  border: 1px solid #c6dfc9;
  border-radius: inherit;
  background: #dfecdb;
}
.puppy-scene::before {
  content: "";
  position: absolute;
  width: 172px;
  height: 172px;
  border-radius: 50%;
  background: #f1f7ed;
  inset-block-start: 14%;
}
.puppy-note {
  position: absolute;
  right: 12%;
  bottom: 14%;
  width: 40px;
  height: 48px;
  border: 1px solid #acc8b4;
  border-radius: 8px;
  background: #f4f8f1;
  transform: rotate(13deg);
}
.puppy-note::before {
  content: "";
  position: absolute;
  left: 8px;
  top: 12px;
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: #84a691;
  box-shadow: 0 7px #b2caba, 0 14px #b2caba;
}
.puppy-pet {
  position: absolute;
  inset: 0;
  z-index: 5;
  width: 100%;
  border: 0;
  border-radius: inherit;
  background: transparent;
  cursor: pointer;
}
.puppy-pet:hover { box-shadow: inset 0 0 0 2px #90bda6; }
.puppy-pet > span {
  position: absolute;
  bottom: 8px;
  right: 8px;
  padding: 4px 8px;
  border-radius: 6px;
  background: #f4f8f1;
  color: var(--green-dark);
  font-size: .75rem;
  line-height: 1rem;
  font-weight: 650;
}
.puppy-pet:hover > span { background: #fff; }

.puppy-art {
  --fur: #dfa16b;
  --light-fur: #ffe5bb;
  --dark-fur: #7c4b34;
  --detail: #432d26;
  position: relative;
  width: 16em;
  height: 11.4em;
  font-size: max(.65rem, min(1rem, 1.3vw));
}
.puppy-art span { position: absolute; display: block; }
.puppy-shadow {
  width: 10em;
  height: 1em;
  bottom: .08em;
  left: 3.05em;
  border-radius: 50%;
  background: #9baa994d;
}
.puppy-tail {
  bottom: 1.42em;
  left: 10.35em;
  width: 3.3em;
  height: 1.22em;
  border: .1em solid #8e5a3e;
  border-radius: 1.5em 1.5em 1.2em .5em;
  background: #a56a47;
  transform: rotate(-28deg);
  transform-origin: 12% 70%;
}
.puppy-body {
  width: 5.95em;
  height: 4.68em;
  bottom: .55em;
  left: 5.02em;
  border: .1em solid #aa7851;
  border-radius: 46% 46% 2em 2em;
  background: var(--fur);
  box-shadow: inset -.42em -.3em #c78e60;
}
.puppy-body::after {
  content: "";
  position: absolute;
  inset: .9em 1.15em .18em;
  border-radius: 50% 50% 45% 45%;
  background: var(--light-fur);
}
.puppy-head {
  position: absolute;
  z-index: 2;
  top: 1.05em;
  left: 4.16em;
  width: 7.7em;
  height: 6.45em;
  transform-origin: 50% 85%;
}
.puppy-ear {
  top: .62em;
  width: 2.5em;
  height: 4.35em;
  border: .1em solid #633b2c;
  border-radius: 55% 48% 51% 62%;
  background: var(--dark-fur);
  box-shadow: inset .28em -.22em #a46948;
  transform-origin: 50% 15%;
  transition: transform 500ms var(--curve);
}
.puppy-ear-left { left: -.55em; transform: rotate(24deg); }
.puppy-ear-right { right: -.55em; transform: rotate(-24deg); }
.puppy-face {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border: .1em solid #a26c48;
  border-radius: 47% 47% 42% 42%;
  background: #eeb782;
  box-shadow: inset -.34em -.3em #dba471;
}
.puppy-spot {
  top: -.55em;
  left: -.45em;
  width: 3.85em;
  height: 3.95em;
  border-radius: 0 0 55% 50%;
  background: #c88759;
  transform: rotate(-16deg);
}
.puppy-eye {
  top: 2.65em;
  width: .61em;
  height: .73em;
  border-radius: 50%;
  background: var(--detail);
  box-shadow: inset 0 -.11em #31211c;
  transform: translate(var(--gaze-x, 0), var(--gaze-y, 0));
  transition: transform 400ms var(--curve), opacity 250ms var(--curve);
}
.puppy-eye::after {
  content: "";
  position: absolute;
  top: .11em;
  left: .14em;
  width: .17em;
  height: .17em;
  border-radius: 50%;
  background: #fff3dd;
}
.puppy-eye-left { left: 2.05em; }
.puppy-eye-right { right: 2.05em; }
.puppy-snout {
  top: 3.47em;
  left: 1.91em;
  width: 3.7em;
  height: 2.14em;
  border-radius: 52% 52% 46% 46%;
  background: var(--light-fur);
  box-shadow: inset 0 -.14em #ebcba3;
}
.puppy-nose {
  z-index: 1;
  top: 3.55em;
  left: 3.18em;
  width: 1.15em;
  height: .72em;
  border-radius: 42% 42% 66% 66%;
  background: var(--detail);
}
.puppy-nose::after {
  content: "";
  position: absolute;
  top: .12em;
  left: .23em;
  width: .44em;
  height: .14em;
  border-radius: 50%;
  background: #79564a;
}
.puppy-mouth {
  top: 4.28em;
  left: 3.05em;
  width: 1.4em;
  height: .78em;
  border: .09em solid var(--detail);
  border-top: 0;
  border-radius: 0 0 1em 1em;
  background: #855247;
  transform-origin: top;
}
.puppy-mouth::after {
  content: "";
  position: absolute;
  inset: .35em .28em 0;
  border-radius: .6em .6em .4em .4em;
  background: #f4a59d;
}
.puppy-collar {
  z-index: 1;
  top: 7.05em;
  left: 5.6em;
  width: 4.8em;
  height: .83em;
  border-radius: .5em;
  background: #387461;
}
.puppy-collar::after {
  content: "";
  position: absolute;
  top: .3em;
  left: 2.02em;
  width: .76em;
  height: .76em;
  border: .08em solid #a16f41;
  border-radius: 50%;
  background: #f6cd79;
}
.puppy-paw {
  z-index: 3;
  bottom: .45em;
  width: 1.85em;
  height: 1.84em;
  border: .1em solid #a76d42;
  border-radius: 48% 48% .66em .66em;
  background: #f6c998;
  box-shadow: inset -.13em -.16em #e1ad77;
  transition: transform 500ms var(--curve);
}
.puppy-paw-left { left: 5.93em; }
.puppy-paw-right { right: 5.93em; }
.puppy-paw::before {
  content: "";
  position: absolute;
  top: 1.43em;
  left: .35em;
  width: 1em;
  height: 3em;
  border: .09em solid #a76d42;
  border-radius: .5em;
  background: #e6aa75;
  opacity: 0;
  transform: scaleY(.25);
  transform-origin: top;
  transition: transform 500ms var(--curve), opacity 300ms var(--curve);
}
.puppy-paw::after {
  content: "";
  position: absolute;
  bottom: .18em;
  left: .51em;
  width: .07em;
  height: .38em;
  border-radius: .1em;
  background: #bb8558;
  box-shadow: .38em 0 #bb8558, .76em 0 #bb8558;
}

.login-shell:has(#id_username:focus) .puppy-art {
  --gaze-x: .27em;
  --gaze-y: -.06em;
}
.login-shell:has(#id_username:focus) .puppy-ear-left { transform: rotate(14deg); }
.login-shell:has(#id_username:focus) .puppy-ear-right { transform: rotate(-14deg); }
.login-shell:has(.password-entry:is(:focus-within, .is-revealed)) .puppy-paw-left {
  transform: translate(-.32em, -5.53em) rotate(12deg);
}
.login-shell:has(.password-entry:is(:focus-within, .is-revealed)) .puppy-paw-right {
  transform: translate(.32em, -5.53em) rotate(-12deg);
}
.login-shell:has(.password-entry:is(:focus-within, .is-revealed)) .puppy-eye { opacity: 0; }
.login-shell:has(.password-entry:is(:focus-within, .is-revealed)) .puppy-paw::before {
  opacity: 1;
  transform: scaleY(1);
}

.puppy-hearts { position: absolute; inset: 0; z-index: 4; pointer-events: none; }
.puppy-hearts span {
  top: 3.35em;
  left: 3.02em;
  width: .78em;
  height: .78em;
  transform: rotate(-45deg);
  background: #a25364;
  opacity: 0;
}
.puppy-hearts span:nth-child(2) { top: 1.85em; left: 12.45em; }
.puppy-hearts span:nth-child(3) { top: 4.65em; left: 13em; }
.puppy-hearts span::before, .puppy-hearts span::after {
  content: "";
  position: absolute;
  width: inherit;
  height: inherit;
  border-radius: 50%;
  background: inherit;
}
.puppy-hearts span::before { top: -.39em; }
.puppy-hearts span::after { left: .39em; }
.puppy-stage.is-happy .puppy-hearts span { opacity: 1; }

@keyframes login-enter {
  from { opacity: .45; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes puppy-wag {
  from { transform: rotate(-40deg); }
  to { transform: rotate(-15deg); }
}
@keyframes puppy-nod {
  0%, 100% { transform: rotate(0); }
  50% { transform: rotate(-7deg); }
}
@keyframes puppy-heart {
  0% { opacity: 0; transform: translateY(.4em) rotate(-45deg) scale(.55); }
  24%, 75% { opacity: 1; }
  100% { opacity: 0; transform: translateY(-1.25em) rotate(-45deg); }
}
@media (prefers-reduced-motion: no-preference) {
  .login-shell { animation: login-enter 600ms var(--curve) both; }
  .login-copy, .login-panel { animation: login-enter 620ms var(--curve) 85ms both; }
  .puppy-stage.is-happy .puppy-tail { animation: puppy-wag 280ms var(--curve) 4 alternate; }
  .puppy-stage.is-happy .puppy-head { animation: puppy-nod 650ms var(--curve); }
  .puppy-stage.is-happy .puppy-hearts span { animation: puppy-heart 1000ms var(--curve) both; }
  .puppy-stage.is-happy .puppy-hearts span:nth-child(2) { animation-delay: 95ms; }
  .puppy-stage.is-happy .puppy-hearts span:nth-child(3) { animation-delay: 170ms; }
}
.missing-page { display: grid; justify-items: start; gap: 12px; }

@media (max-width: 1080px) {
  .workspace { grid-template-columns: 200px minmax(0, 1fr); }
  .tool-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 760px) {
  .workspace { display: block; }
  .sidebar { position: static; height: auto; gap: 12px; padding: 12px 16px; }
  .sidebar nav { display: flex; flex-wrap: wrap; }
  .sidebar nav a { padding: 4px 8px; }
  .profile { grid-template-columns: auto minmax(0, 1fr) auto; padding-top: 8px; }
  .topbar { padding: 8px 16px; }
  .content { padding: 16px; }
  .banner { padding: 24px; min-height: 0; }
  .heading-2 { font-size: 2.25rem; line-height: 2.5rem; }
  .lower-grid { grid-template-columns: 1fr; }
  .card { padding: 16px; }
  .login-shell { grid-template-columns: 1fr; }
  .login-brand { min-height: 0; gap: 16px; padding: 24px; }
  .login-brand .heading-1 { font-size: 2.25rem; line-height: 2.5rem; }
  .login-copy p { margin-top: 8px; }
  .login-panel { padding: 24px 24px 32px; }
  .login-panel .heading-3 { font-size: 1.875rem; line-height: 2.25rem; }
  .login-panel form { margin-top: 24px; }
  .puppy-scene { min-height: 132px; }
  .puppy-scene::before { width: 112px; height: 112px; }
  .puppy-note { width: 32px; height: 40px; }
  .puppy-note::before { left: 6px; top: 8px; }
}
@media (max-width: 470px) {
  .tool-grid, .form-grid { grid-template-columns: 1fr; }
  .public { padding: 16px; }
  .metrics { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  .button, .tool-card, .login-submit span, .puppy-ear, .puppy-eye, .puppy-paw, .puppy-paw::before { transition: none; }
  .login-submit:hover span { transform: none; }
}
@media (forced-colors: active) {
  .login-copy h1 { background: none; color: CanvasText; -webkit-text-fill-color: CanvasText; }
}
