@font-face {
  font-family: "Plus Jakarta Sans";
  src: url("/PlusJakartaSans-latin.woff2") format("woff2");
  font-style: normal;
  font-weight: 300 800;
  font-display: swap;
}
@font-face {
  font-family: "JetBrains Mono";
  src: url("/JetBrainsMono-latin.woff2") format("woff2");
  font-style: normal;
  font-weight: 100 800;
  font-display: swap;
}
:root {
  color-scheme: dark;
  --foreground: hsl(210 40% 98%);
  --muted: hsl(215 16% 76%);
  --card: hsl(220 25% 10% / .80);
  --border: hsl(210 30% 85% / .21);
  --primary: hsl(142 76% 36%);
  --green: hsl(145 66% 67%);
  --error: hsl(0 88% 79%);
  --ease-out: cubic-bezier(.23, 1, .32, 1);
  font-family: "Plus Jakarta Sans", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  color: var(--foreground);
  background: linear-gradient(to top left, #F7941E, #004E8F) fixed;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; min-height: 100vh; }
.shell { max-width: 76rem; padding: 1.8rem clamp(1rem, 4.5vw, 3rem) 4rem; margin: 0 auto; }
.masthead {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 1rem;
}
.brand {
  grid-column: 2;
  display: flex;
  align-items: center;
  gap: .65rem;
  align-self: center;
  min-height: 44px;
  color: var(--foreground);
  text-decoration: none;
  font-size: clamp(1.22rem, 2.5vw, 1.85rem);
  letter-spacing: -.04em;
  font-weight: 700;
}
.intro { max-width: 44rem; margin: 3.15rem auto 2rem; text-align: center; }
h1, h2, h3, p, dl { margin: 0; }
h1, h2, h3 { text-wrap: balance; }
h1 { font-size: clamp(1.85rem, 4vw, 3rem); font-weight: 750; line-height: 1.13; letter-spacing: -.05em; }
.lead { margin-top: .75rem; color: var(--foreground); font-size: clamp(.95rem, 1.5vw, 1.1rem); }
p, dd { line-height: 1.64; text-wrap: pretty; }
.layout { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); gap: 1.25rem; align-items: start; }
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 1rem;
  padding: clamp(1rem, 2.8vw, 1.8rem);
  box-shadow: 0 8px 22px hsl(220 40% 6% / .16), 0 25px 50px hsl(220 40% 5% / .13);
  backdrop-filter: blur(14px);
}
h2 { font-size: 1.25rem; font-weight: 700; letter-spacing: -.025em; line-height: 1.3; }
h3 { font-size: 1.125rem; letter-spacing: -.015em; }
.upload > p, .receipt > p { margin-top: .55rem; color: var(--muted); font-size: .875rem; }
.upload p strong { color: var(--foreground); font-weight: 650; }
form, .receipt { margin-top: 1.2rem; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; clip-path: inset(50%); white-space: nowrap; overflow: hidden; }
.dropzone {
  display: grid;
  justify-items: center;
  gap: .4rem;
  padding: 1.55rem 1rem;
  border: 1px dashed hsl(215 28% 73% / .62);
  border-radius: .75rem;
  background: hsl(220 25% 14% / .56);
  text-align: center;
  cursor: pointer;
  transition: background-color 160ms var(--ease-out), border-color 160ms var(--ease-out);
}
.dropzone:hover, .dropzone[data-dragging] {
  border-color: var(--green);
  background: hsl(145 36% 21% / .36);
}
.dropzone[aria-disabled="true"] { opacity: .7; cursor: wait; }
#file:focus-visible + .dropzone { outline: 2px solid var(--green); outline-offset: 3px; }
.file-symbol {
  display: grid;
  place-items: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: .52rem;
  background: hsl(145 41% 29% / .63);
  color: var(--green);
  font-size: 1.45rem;
  font-weight: 650;
  margin-bottom: .25rem;
}
.drop-title { font-weight: 700; font-size: .95rem; line-height: 1.4; }
.file-help, .form-status, .form-footer > span { font-size: .8rem; line-height: 1.5; color: var(--muted); }
.preview {
  display: grid;
  gap: .1rem;
  margin-top: .75rem;
  padding: .62rem .8rem;
  border-radius: .6rem;
  border: 1px solid hsl(145 45% 51% / .36);
  background: hsl(145 37% 20% / .62);
  color: var(--green);
  font-size: .86rem;
  overflow-wrap: anywhere;
}
.preview > span { color: hsl(145 31% 80%); font-size: .77rem; font-variant-numeric: tabular-nums; }
#verification:not(:empty) { margin-top: .8rem; }
.form-status:not(:empty) { margin-top: .7rem; }
.form-status:empty { display: none; }
.form-status[data-error] { color: var(--error); }
.form-footer, .receipt-actions { display: flex; align-items: center; gap: .7rem 1rem; flex-wrap: wrap; margin-top: 1rem; }
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .45rem;
  min-height: 42px;
  padding: .55rem .95rem;
  border: 1px solid transparent;
  border-radius: .45rem;
  font: 670 .85rem/1.35 "Plus Jakarta Sans", system-ui, sans-serif;
  text-decoration: none;
  color: var(--foreground);
  cursor: pointer;
  transition: background-color 160ms var(--ease-out), box-shadow 160ms var(--ease-out), scale 120ms var(--ease-out);
}
.primary { background: var(--primary); color: hsl(146 60% 8%); }
.primary:hover:not(:disabled) { background: hsl(142 70% 47%); box-shadow: 0 0 16px hsl(142 76% 38% / .35); }
.outline { background: hsl(220 25% 12% / .40); border-color: var(--border); }
.outline:hover { background: hsl(220 25% 19% / .72); }
.back { justify-self: end; }
.button:disabled { opacity: .54; cursor: default; }
.button:active:not(:disabled) { scale: .96; }
:focus-visible { outline: 2px solid var(--green); outline-offset: 3px; }
.details dl { margin-top: .75rem; }
.details dl div { border-top: 1px solid var(--border); padding-block: .78rem; }
.details dl div:last-child { padding-bottom: 0; }
.details dt { color: var(--green); font-size: .875rem; font-weight: 700; }
.details dd { margin: .28rem 0 0; color: var(--muted); font-size: .84rem; }
.receipt { border: 1px solid hsl(145 41% 62% / .37); background: hsl(145 39% 15% / .75); border-radius: .75rem; padding: 1rem; }
.receipt label { display: block; margin-top: 1rem; color: var(--green); font-size: .85rem; font-weight: 650; }
.receipt-actions { margin-top: .45rem; }
#receipt-code {
  flex: 1 1 240px;
  min-width: 0;
  padding: .65rem .75rem;
  border: 1px solid var(--border);
  border-radius: .45rem;
  background: hsl(220 26% 10% / .65);
  color: var(--foreground);
  font: 400 .82rem "JetBrains Mono", monospace;
}
@media (max-width: 48rem) {
  .layout { grid-template-columns: 1fr; }
  .masthead { display: flex; justify-content: space-between; gap: .5rem; }
  .brand img { width: 32px; height: 32px; }
  .intro { margin: 2rem 0 1.4rem; }
  .form-footer .primary { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  .button, .dropzone { transition: none; }
  .button:active:not(:disabled) { scale: 1; }
}
