:root {
  --paper: #ffffff;
  --ink: #050505;
  --purple: #6c4fe0;
  --lilac: #cd82f0;
  --green: #33c875;
  --red: #e45454;
  --neutral-50: #fafafa;
  --neutral-100: #f4f4f3;
  --neutral-200: #e7e7e5;
  --neutral-300: #b9b9b5;
  --neutral-500: #737373;
  --neutral-700: #404040;
  --border: rgba(0, 0, 0, .09);
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --serif: "Instrument Serif", Georgia, "Times New Roman", serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
}

* { box-sizing: border-box; }

html { background: var(--neutral-50); }

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  background: var(--neutral-50);
  color: var(--ink);
  font: 16px/1.45 var(--sans);
  -webkit-font-smoothing: antialiased;
}

button,
textarea,
select,
summary { font: inherit; }

a { color: inherit; }

.wrap {
  display: flex;
  flex-direction: column;
  width: min(calc(100% - 32px), 1240px);
  min-height: 100vh;
  min-height: 100dvh;
  margin: 0 auto;
  border-right: 1px solid var(--border);
  border-left: 1px solid var(--border);
  background: var(--paper);
}

.site-header {
  margin-top: auto;
  padding: 20px 30px 17px;
  border-bottom: 1px solid var(--border);
}

h1 {
  margin: 0 0 7px;
  color: var(--ink);
  font: 400 clamp(40px, 4.3vw, 51px)/.98 var(--serif);
  letter-spacing: .002em;
}

h1 em {
  color: var(--purple);
  font-weight: 400;
  font-style: italic;
}

.sub {
  max-width: 860px;
  margin: 0;
  overflow: hidden;
  color: var(--neutral-500);
  font-size: 15px;
  line-height: 1.45;
  text-overflow: ellipsis;
  white-space: nowrap;
  transition: color .16s, padding-right .16s;
}

/* model status row — mirrors the masked-diffusion Space */
.model-strip {
  display: grid;
  grid-template-columns: 48px 280px minmax(240px, 1fr);
  align-items: center;
  column-gap: 16px;
  min-height: 76px;
  padding: 12px 30px;
  border-bottom: 1px solid var(--border);
  background: linear-gradient(90deg, rgba(108, 79, 224, .018), rgba(205, 130, 240, .035), rgba(108, 79, 224, .018));
  transition: background .3s ease;
}
.model-logo-frame { position: relative; display: block; width: 48px; height: 48px; overflow: hidden; }
.model-logo { position: absolute; top: 50%; left: 50%; display: block; width: 56px; height: auto; max-width: none; transform: translate(-50%, -50%); image-rendering: pixelated; }
.model-copy { display: flex; min-width: 0; align-items: center; }
.model-name-row { display: flex; min-height: 25px; align-items: center; gap: 10px; white-space: nowrap; }
.model-copy a { font: 400 22px/1.15 var(--serif); text-decoration: none; }
.model-copy a:hover { color: var(--purple); }
.model-variant { display: inline-flex; height: 18px; align-items: center; box-sizing: border-box; padding: 0 7px; border: 1px solid rgba(108, 79, 224, .14); border-radius: 999px; background: rgba(108, 79, 224, .05); color: var(--purple); font: 700 9px/1 var(--mono); letter-spacing: .035em; text-transform: uppercase; }
.load-block { min-width: 0; }
.load-meta { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 8px; color: var(--neutral-500); font-size: 12px; font-weight: 600; }
#load-percent { font: 600 11px/1 var(--mono); font-variant-numeric: tabular-nums; }
.load-track { height: 7px; overflow: hidden; border-radius: 999px; background: rgba(108, 79, 224, .09); }
.load-track span { display: block; width: 0; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--purple), var(--lilac)); transition: width .18s ease; }
.model-strip.is-ready .load-track { background: rgba(45, 189, 112, .09); }
.model-strip.is-ready .load-track span { background: var(--green); }
.model-strip.is-ready .load-meta { color: #188e50; }
.model-strip.is-error .load-track span { background: var(--red); }
.model-strip.is-error .load-meta { color: var(--red); }
@media (max-width: 720px) {
  .model-strip { grid-template-columns: 48px minmax(0, 1fr); column-gap: 16px; row-gap: 10px; padding: 12px 20px; }
  .model-strip .load-block { grid-column: 1 / -1; }
  .model-name-row { align-items: flex-start; flex-direction: column; gap: 2px; }
}

main { flex: 0 0 auto; margin-bottom: auto; padding: 18px 30px 22px; }

.flow-grid {
  position: relative;
  display: grid;
  grid-template-columns: minmax(285px, .88fr) 250px minmax(368px, 1fr);
  align-items: center;
  gap: clamp(42px, 4.4vw, 58px);
  min-height: 432px;
}

.flow-card {
  position: relative;
  z-index: 2;
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--paper);
}

.prompt-card {
  display: flex;
  flex-direction: column;
  min-height: 320px;
  padding: 20px;
}

.prompt-card::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 3;
  background: linear-gradient(90deg, transparent 20%, rgba(108,79,224,.08) 48%, rgba(255,255,255,.8) 52%, transparent 80%);
  transform: translateX(-120%);
  opacity: 0;
  pointer-events: none;
}

.is-routing .prompt-card::after {
  opacity: 1;
  animation: panel-sweep 900ms cubic-bezier(.45,0,.25,1) infinite;
}

label,
.model-label {
  display: block;
  margin: 0 0 11px;
  color: var(--neutral-500);
  font: 600 12px/1.25 var(--mono);
  letter-spacing: .08em;
  text-transform: uppercase;
}

textarea {
  width: 100%;
  min-height: 145px;
  padding: 14px 15px;
  border: 1px solid var(--border);
  border-radius: 8px;
  outline: 0;
  background: var(--paper);
  color: var(--ink);
  font: 16px/1.5 var(--sans);
  resize: vertical;
  transition: border-color .17s, box-shadow .17s;
}

textarea:focus {
  border-color: var(--purple);
  box-shadow: 0 0 0 3px rgba(108,79,224,.14);
}

#text {
  flex: 1;
  min-height: 232px;
  padding: 7px 0 0;
  border: 0;
  border-radius: 0;
  font-size: 16px;
  line-height: 1.55;
  resize: none;
}

#text:focus { border-color: transparent; box-shadow: none; }

.model-card {
  position: relative;
  z-index: 6;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 250px;
  min-height: 264px;
  padding: 24px;
  overflow: hidden;
  border: 1px solid rgba(108,79,224,.2);
  border-radius: 14px;
  background:
    radial-gradient(circle at 86% 10%, rgba(205,130,240,.2), transparent 36%),
    radial-gradient(circle at 12% 92%, rgba(108,79,224,.055), transparent 32%),
    linear-gradient(145deg, #fff 0%, #fbfaff 100%);
  color: var(--ink);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.9), 0 16px 42px rgba(53,43,90,.11);
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}

.model-card::after {
  content: "";
  position: absolute;
  inset: -45%;
  z-index: 0;
  pointer-events: none;
  background: linear-gradient(105deg, transparent 38%, rgba(108,79,224,.06) 46%, rgba(255,255,255,.9) 51%, rgba(205,130,240,.16) 56%, transparent 63%);
  transform: translateX(-75%) rotate(8deg);
  opacity: 0;
}

.model-card > * { position: relative; z-index: 1; }

.model-card.busy {
  transform: scale(1.035);
  border-color: rgba(108,79,224,.4);
  box-shadow: 0 18px 46px rgba(83,61,166,.16), 0 0 0 3px rgba(108,79,224,.07);
}

.model-card.busy::after {
  opacity: 1;
  animation: model-scan 820ms cubic-bezier(.45,0,.25,1) infinite;
}

.model-label {
  color: var(--neutral-500);
  font: 600 12px/1.25 var(--mono);
  letter-spacing: .08em;
  text-transform: uppercase;
}

.model-top {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
}

.model-top .model-label { margin: 0; }

.model-core {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 16px;
  margin: 19px 0 18px;
}

.model-core::before {
  content: "";
  position: absolute;
  top: -18px;
  left: -18px;
  z-index: 0;
  width: 88px;
  height: 88px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(205,130,240,.28) 0 12%, rgba(108,79,224,.12) 28%, transparent 68%);
  opacity: 0;
  pointer-events: none;
}

.model-card.busy .model-core::before,
.model-card.initializing .model-core::before {
  animation: energy-bloom 1.05s ease-in-out infinite;
}

.model-orbit {
  position: relative;
  display: grid;
  z-index: 1;
  width: 50px;
  height: 50px;
  place-items: center;
  border: 1px solid rgba(108,79,224,.32);
  border-radius: 50%;
  box-shadow: inset 0 0 0 10px rgba(108,79,224,.045);
  transition: transform .25s ease, box-shadow .25s ease;
}

.model-orbit::before,
.model-orbit::after,
.model-orbit span {
  content: "";
  position: absolute;
  border-radius: 50%;
}

.model-orbit::before {
  width: 9px;
  height: 9px;
  background: var(--purple);
  box-shadow: 0 0 0 5px rgba(108,79,224,.1);
}

.model-orbit::after {
  top: 1px;
  left: 22px;
  width: 6px;
  height: 6px;
  background: var(--lilac);
  transform-origin: 3px 24px;
}

.model-card.busy .model-orbit,
.model-card.initializing .model-orbit {
  transform: scale(1.22);
  box-shadow: inset 0 0 0 10px rgba(108,79,224,.065), 0 0 0 10px rgba(108,79,224,.045), 0 0 28px rgba(205,130,240,.3);
}

.model-card.busy .model-orbit::after,
.model-card.initializing .model-orbit::after { animation: orbit-turn 1.05s linear infinite; }
.model-card.busy .model-orbit::before,
.model-card.initializing .model-orbit::before { animation: orbit-pulse 1.05s ease-in-out infinite; }

.model-orbit span {
  width: 20px;
  height: 20px;
  border: 1px solid rgba(108,79,224,.2);
}

.model-name {
  align-self: flex-start;
  color: var(--ink);
  position: relative;
  z-index: 1;
  font: 400 26px/1.02 var(--serif);
  letter-spacing: -.015em;
  text-decoration: none;
}

.model-identity {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 7px;
}

.model-size {
  display: inline-flex;
  padding: 4px 7px;
  border: 1px solid rgba(108,79,224,.13);
  border-radius: 999px;
  background: rgba(108,79,224,.055);
  color: var(--purple);
  font: 700 10px/1 var(--mono);
  letter-spacing: .035em;
  text-transform: uppercase;
}

.model-load-track {
  height: 3px;
  overflow: hidden;
  border-radius: 99px;
  background: rgba(108,79,224,.09);
  transition: opacity .25s ease;
}

.model-load-track span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--purple), var(--lilac));
  transition: width .22s ease;
}

.model-load-track.indeterminate span {
  width: 36% !important;
  animation: load-track 1s ease-in-out infinite;
}

.model-card.ready .model-load-track { opacity: 0; }

.model-status {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--neutral-500);
  font-size: 13px;
  font-weight: 500;
  white-space: nowrap;
  align-self: flex-start;
  padding: 6px 9px;
  border: 1px solid rgba(108,79,224,.08);
  border-radius: 999px;
  background: rgba(108,79,224,.035);
}

.model-card.ready .model-status {
  border-color: rgba(51,200,117,.12);
  background: rgba(51,200,117,.055);
}

.status-dot {
  width: 8px;
  height: 8px;
  flex: none;
  border-radius: 50%;
  background: #efb640;
  box-shadow: 0 0 0 4px rgba(239,182,64,.12);
  animation: status-pulse 1.45s ease-in-out infinite;
}

.model-card.ready .status-dot {
  background: var(--green);
  box-shadow: 0 0 0 4px rgba(51,200,117,.13);
  animation: none;
}

.model-card.error .status-dot {
  background: #f06464;
  box-shadow: 0 0 0 4px rgba(240,100,100,.13);
  animation: none;
}

.route-card {
  min-height: 418px;
  padding: 20px;
}

.route-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

h2 {
  margin: 0;
  color: var(--neutral-500);
  font: 600 12px/1.25 var(--mono);
  letter-spacing: .08em;
  text-transform: uppercase;
}

.stats {
  color: var(--neutral-500);
  font: 500 11px/1.35 var(--mono);
  text-align: right;
  white-space: nowrap;
}

.has-result .stats { animation: soft-in .45s ease both; }

.route {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.rrow {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 66px 40px 24px;
  align-items: center;
  gap: 8px;
  min-height: 34px;
  padding: 4px 7px 4px 12px;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--paper);
  transform-origin: left center;
}

.rrow::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(100deg, transparent 20%, rgba(108,79,224,.04) 40%, rgba(205,130,240,.17) 50%, rgba(255,255,255,.72) 54%, transparent 74%);
  opacity: 0;
  transform: translateX(-110%);
}

.has-result .rrow {
  animation: row-arrive .44s cubic-bezier(.2,.8,.2,1) both;
  animation-delay: calc(var(--row-index) * 32ms + 110ms);
}

.has-result .rrow.just-added,
.has-result .rrow.no-arrive { animation: none; }

.rrow.no-arrive .rfill { transition: none; }

.category-name {
  position: relative;
  z-index: 1;
  display: flex;
  min-width: 0;
  align-items: center;
  border-radius: 6px;
  transition: background .16s, box-shadow .16s;
}

.rname-input {
  position: relative;
  z-index: 1;
  width: 100%;
  min-width: 0;
  overflow: hidden;
  padding: 2px 4px;
  border: 0;
  border-radius: 4px;
  outline: 0;
  background: transparent;
  color: var(--neutral-700);
  font-family: var(--sans);
  font-size: 13px;
  font-weight: 500;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.edit-hint {
  position: absolute;
  top: 50%;
  right: 5px;
  color: var(--purple);
  font-size: 13px;
  opacity: 0;
  pointer-events: none;
  transform: translate(-3px, -50%);
  transition: opacity .16s, transform .16s;
}

.rrow:hover {
  border-color: rgba(108,79,224,.3);
}

.rrow:hover .category-name {
  background: rgba(108,79,224,.06);
  box-shadow: inset 0 0 0 1px rgba(108,79,224,.14);
}

.rrow:hover .edit-hint {
  opacity: 1;
  transform: translate(0, -50%);
}

.rrow:hover .rname-input { padding-right: 22px; color: var(--purple); }

.category-name:focus-within {
  background: var(--paper);
  box-shadow: 0 0 0 2px rgba(108,79,224,.2);
}

.rname-input:focus {
  background: var(--paper);
  box-shadow: none;
  text-overflow: clip;
}

.remove-category {
  position: relative;
  z-index: 1;
  display: grid;
  width: 24px;
  height: 24px;
  padding: 0;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--neutral-300);
  font: 400 16px/1 var(--sans);
  cursor: pointer;
  transition: color .15s, background .15s, transform .15s;
}

.remove-category:hover {
  background: rgba(0,0,0,.05);
  color: var(--neutral-700);
  transform: scale(1.06);
}

.add-category {
  align-self: flex-start;
  margin-top: 2px;
  padding: 7px 12px;
  border: 1px dashed rgba(108,79,224,.24);
  border-radius: 999px;
  background: rgba(108,79,224,.025);
  color: var(--purple);
  font-size: 12px;
  font-weight: 650;
  cursor: pointer;
  transition: border-color .15s, background .15s, transform .15s;
}

.add-category:hover {
  border-color: rgba(108,79,224,.5);
  background: rgba(108,79,224,.065);
  transform: translateY(-1px);
}

.rbar {
  height: 9px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--neutral-100);
}

.rfill {
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: rgba(108,79,224,.42);
  transition: width 780ms cubic-bezier(.16,.8,.25,1);
  transition-delay: calc(var(--row-index) * 34ms + 100ms);
}

.rpct {
  color: var(--neutral-500);
  font: 600 12px/1 var(--mono);
  font-variant-numeric: tabular-nums;
  text-align: right;
}

.categories-changing .rrow {
  border-color: rgba(108,79,224,.16);
  animation: category-breathe .72s ease-in-out infinite alternate;
  animation-delay: calc(var(--row-index) * 24ms);
}

.categories-changing .rrow::after {
  opacity: 1;
  animation: category-scan .86s cubic-bezier(.4,0,.2,1) infinite;
  animation-delay: calc(var(--row-index) * 28ms);
}

.categories-changing .rname-input,
.categories-changing .rpct { color: var(--neutral-300); }

.categories-changing .rbar {
  background: linear-gradient(90deg, var(--neutral-100), rgba(108,79,224,.1), var(--neutral-100));
  background-size: 220% 100%;
  animation: probability-wait .86s ease-in-out infinite;
}

.rrow.top {
  border-color: rgba(108,79,224,.55);
  background: rgba(108,79,224,.035);
  box-shadow: inset 3px 0 0 var(--purple);
}

.rrow.top .rname-input,
.rrow.top .rpct { color: var(--purple); font-weight: 700; }
.rrow.top .rfill { background: var(--purple); }

.flow-connectors {
  position: absolute;
  inset: 0;
  z-index: 4;
  overflow: visible;
  pointer-events: none;
}

.flow-connectors path {
  fill: none;
  vector-effect: non-scaling-stroke;
}

.connector-base {
  stroke: rgba(108,79,224,.18);
  stroke-width: 1.25;
}

.connector-base.input-base { stroke: rgba(0,0,0,.17); }
.connector-base.output-base.top { stroke: var(--purple); stroke-width: 2.2; }

.flow-connectors .endpoint {
  fill: var(--paper);
  stroke: rgba(108,79,224,.32);
  stroke-width: 1.2;
  vector-effect: non-scaling-stroke;
}

.flow-connectors .endpoint.top {
  fill: var(--purple);
  stroke: var(--purple);
  filter: drop-shadow(0 0 5px rgba(108,79,224,.45));
}

.flow-connectors .travel-light {
  fill: #fff;
  stroke: var(--purple);
  stroke-width: 1.5;
  vector-effect: non-scaling-stroke;
  filter: drop-shadow(0 0 3px #fff) drop-shadow(0 0 7px var(--purple)) drop-shadow(0 0 12px var(--lilac));
}

.flow-connectors .travel-light.top {
  stroke-width: 2;
  filter: drop-shadow(0 0 4px #fff) drop-shadow(0 0 9px var(--purple)) drop-shadow(0 0 15px var(--lilac));
}

.below-stage {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 10px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}

demo-examples { display: block; }

.example-browser {
  display: grid;
  grid-template-columns: 210px minmax(0, 1fr);
  align-items: end;
  gap: 20px;
}

.scenario-control label { margin-bottom: 10px; }

.select-shell {
  position: relative;
  display: block;
}

.select-shell::after {
  content: "";
  position: absolute;
  top: 50%;
  right: 13px;
  width: 7px;
  height: 7px;
  border-right: 1.5px solid var(--neutral-500);
  border-bottom: 1.5px solid var(--neutral-500);
  pointer-events: none;
  transform: translateY(-72%) rotate(45deg);
}

#preset-select {
  width: 100%;
  height: 39px;
  padding: 0 34px 0 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  outline: 0;
  appearance: none;
  background: var(--paper);
  color: var(--neutral-700);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

#preset-select:focus {
  border-color: var(--purple);
  box-shadow: 0 0 0 3px rgba(108,79,224,.12);
}

.example-label {
  margin: 0 0 10px;
  color: var(--neutral-500);
  font: 600 12px/1.25 var(--mono);
  letter-spacing: .07em;
  text-transform: uppercase;
}

.request-options {
  display: flex;
  flex-wrap: nowrap;
  gap: 7px;
  overflow-x: auto;
  margin: -3px 0 -2px;
  padding: 3px 0 2px;
  scrollbar-width: none;
}

.request-options::-webkit-scrollbar { display: none; }

button.ex {
  width: auto;
  padding: 9px 13px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--paper);
  color: var(--neutral-700);
  font-size: 13px;
  font-weight: 500;
  white-space: nowrap;
  cursor: pointer;
  transition: border-color .15s, background .15s, color .15s, transform .15s;
}

button.ex:hover {
  border-color: rgba(0,0,0,.22);
  background: var(--neutral-50);
  transform: translateY(-1px);
}

button.ex.active {
  border-color: var(--ink);
  background: var(--ink);
  color: var(--paper);
}

button:focus-visible,
summary:focus-visible {
  outline: 2px solid var(--purple);
  outline-offset: 2px;
}

@keyframes panel-sweep {
  from { transform: translateX(-120%); }
  to { transform: translateX(120%); }
}

@keyframes model-scan {
  from { transform: translateX(-82%) rotate(8deg); }
  to { transform: translateX(82%) rotate(8deg); }
}

@keyframes energy-bloom {
  0%, 100% { opacity: .15; transform: scale(.72); }
  48% { opacity: 1; transform: scale(1.18); }
}

@keyframes orbit-turn {
  to { transform: rotate(360deg); }
}

@keyframes orbit-pulse {
  50% { transform: scale(.72); box-shadow: 0 0 0 8px rgba(108,79,224,.06); }
}

@keyframes load-track {
  from { transform: translateX(-115%); }
  to { transform: translateX(300%); }
}

@keyframes category-scan {
  from { transform: translateX(-110%); }
  to { transform: translateX(110%); }
}

@keyframes category-breathe {
  to { background-color: rgba(108,79,224,.018); }
}

@keyframes probability-wait {
  from { background-position: 100% 0; }
  to { background-position: -100% 0; }
}

@keyframes status-pulse {
  50% { opacity: .45; transform: scale(.84); }
}

@keyframes row-arrive {
  from { opacity: .2; transform: translateX(-9px) scale(.99); }
  to { opacity: 1; transform: translateX(0) scale(1); }
}

@keyframes soft-in {
  from { opacity: 0; transform: translateY(3px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 1080px) {
  .flow-grid {
    grid-template-columns: minmax(268px, .86fr) 228px minmax(338px, 1fr);
    gap: 36px;
  }
  .model-card { width: 228px; min-height: 250px; padding: 21px; }
  .model-name { font-size: 25px; }
  .rrow { grid-template-columns: minmax(0,1fr) 52px 38px 24px; gap: 6px; }
}

@media (max-width: 850px) {
  .sub { white-space: normal; }
  .flow-grid {
    grid-template-columns: 1fr;
    gap: 14px;
    min-height: 0;
  }
  .flow-connectors { display: none; }
  .prompt-card { min-height: 300px; }
  #text { min-height: 220px; }
  .model-card { width: 100%; min-height: 170px; }
  .route-card { min-height: 0; }
}

@media (max-width: 640px) {
  .wrap { width: 100%; border: 0; }
  .site-header { padding: 23px 18px 20px; }
  h1 { font-size: 37px; }
  main { padding: 20px 18px 32px; }
  .example-browser { grid-template-columns: 1fr; gap: 12px; }
  .stats { display: none; }
  .rrow { grid-template-columns: minmax(0,1fr) 42px 24px; }
  .rbar { grid-column: 1 / -1; grid-row: 2; }
  .rpct { grid-column: 2; grid-row: 1; }
  .remove-category { grid-column: 3; grid-row: 1; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}
