/* monkeyapp design kit. One page, three directions, driven by data attributes
   on <html>: data-dir (carnival|dispatch|night), data-palette (a|b|c),
   data-nav (top|side), data-hero (split|bleed), data-density (cozy|compact).
   Everything visual hangs off the variables below. */

:root {
  --radius: 14px;
  --gap: 24px;
  --maxw: 1180px;
  --ease: cubic-bezier(.2,.8,.2,1);
}

/* ---------------------------------------------------------------- type */
html[data-dir="carnival"] { --font-display: "Fraunces", Georgia, serif; --font-body: "Inter", system-ui, sans-serif; --display-weight: 900; --display-tracking: -.02em; }
html[data-dir="dispatch"] { --font-display: "Space Grotesk", "Inter", sans-serif; --font-body: "Inter", system-ui, sans-serif; --display-weight: 700; --display-tracking: -.03em; }
html[data-dir="night"]    { --font-display: "Sora", "Inter", sans-serif; --font-body: "IBM Plex Sans", system-ui, sans-serif; --display-weight: 700; --display-tracking: -.02em; }

/* ------------------------------------------------------------ palettes */
/* Carnival: warm paper, saturated primaries */
html[data-dir="carnival"][data-palette="a"] { --bg:#fff6e8; --bg-2:#ffe9c7; --surface:#ffffff; --ink:#1d1410; --muted:#6b5a4e; --line:#f0dcc0; --accent:#ff5a36; --accent-ink:#fff; --accent-2:#ffc531; --accent-3:#2bb3c0; --ok:#1f9d55; --warn:#e4a11b; --bad:#d8341e; }
html[data-dir="carnival"][data-palette="b"] { --bg:#f3f7ff; --bg-2:#dbe7ff; --surface:#ffffff; --ink:#131a2b; --muted:#56607a; --line:#d4def5; --accent:#3b5bff; --accent-ink:#fff; --accent-2:#ff7ab6; --accent-3:#ffd23f; --ok:#1f9d55; --warn:#e4a11b; --bad:#d8341e; }
html[data-dir="carnival"][data-palette="c"] { --bg:#f6fff2; --bg-2:#dcf5cf; --surface:#ffffff; --ink:#15210f; --muted:#56664d; --line:#cfe8c2; --accent:#1fab5a; --accent-ink:#fff; --accent-2:#ff8a3d; --accent-3:#7b61ff; --ok:#1f9d55; --warn:#e4a11b; --bad:#d8341e; }
/* Dispatch: cool neutrals, one accent */
html[data-dir="dispatch"][data-palette="a"] { --bg:#f6f7f9; --bg-2:#eceef2; --surface:#ffffff; --ink:#111418; --muted:#5d6672; --line:#dde1e7; --accent:#f06a1f; --accent-ink:#fff; --accent-2:#111418; --accent-3:#2f6fed; --ok:#1a9c5b; --warn:#d99a12; --bad:#d6382b; }
html[data-dir="dispatch"][data-palette="b"] { --bg:#f7f7f5; --bg-2:#ecebe6; --surface:#ffffff; --ink:#15150f; --muted:#64645a; --line:#dedcd2; --accent:#0f766e; --accent-ink:#fff; --accent-2:#15150f; --accent-3:#c2410c; --ok:#1a9c5b; --warn:#d99a12; --bad:#d6382b; }
html[data-dir="dispatch"][data-palette="c"] { --bg:#f5f6fb; --bg-2:#e8eaf6; --surface:#ffffff; --ink:#12142a; --muted:#5c6080; --line:#d9dcee; --accent:#4f46e5; --accent-ink:#fff; --accent-2:#12142a; --accent-3:#e11d74; --ok:#1a9c5b; --warn:#d99a12; --bad:#d6382b; }
/* Night: near-black, neon accents */
html[data-dir="night"][data-palette="a"] { --bg:#0d0f14; --bg-2:#151922; --surface:#1b2030; --ink:#f3f5f9; --muted:#9aa3b5; --line:#2a3245; --accent:#6cf0a8; --accent-ink:#0d0f14; --accent-2:#ff6a3d; --accent-3:#5eb8ff; --ok:#6cf0a8; --warn:#ffcc4d; --bad:#ff5d5d; }
html[data-dir="night"][data-palette="b"] { --bg:#0e0b14; --bg-2:#181224; --surface:#211a33; --ink:#f6f2ff; --muted:#a79fbf; --line:#342a4d; --accent:#c084fc; --accent-ink:#0e0b14; --accent-2:#f6c445; --accent-3:#38bdf8; --ok:#4ade80; --warn:#ffcc4d; --bad:#ff5d5d; }
html[data-dir="night"][data-palette="c"] { --bg:#0b1210; --bg-2:#121c18; --surface:#182420; --ink:#eef7f2; --muted:#93a89d; --line:#263a32; --accent:#ffb347; --accent-ink:#0b1210; --accent-2:#5eead4; --accent-3:#f472b6; --ok:#4ade80; --warn:#ffcc4d; --bad:#ff5d5d; }

html[data-density="compact"] { --gap: 16px; --radius: 10px; }

/* ---------------------------------------------------------------- base */
* { box-sizing: border-box; }
html, body { margin: 0; }
body { font-family: var(--font-body); background: var(--bg); color: var(--ink); line-height: 1.5; -webkit-font-smoothing: antialiased; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--font-display); font-weight: var(--display-weight); letter-spacing: var(--display-tracking); line-height: 1.05; margin: 0; }
h1 { font-size: clamp(40px, 6vw, 76px); }
h2 { font-size: clamp(28px, 3.4vw, 40px); }
h3 { font-size: 20px; }
p { margin: 0; }
.muted { color: var(--muted); }
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
.eyebrow { font-size: 12px; letter-spacing: .18em; text-transform: uppercase; color: var(--accent); font-weight: 600; }

.btn { display: inline-flex; align-items: center; gap: 8px; padding: 12px 18px; border-radius: 999px; font-weight: 600; font-size: 15px; text-decoration: none; border: 1px solid transparent; cursor: pointer; transition: transform .15s var(--ease), background .15s, box-shadow .15s; }
.btn:active { transform: translateY(1px) scale(.99); }
.btn.primary { background: var(--accent); color: var(--accent-ink); }
.btn.primary:hover { box-shadow: 0 10px 24px color-mix(in srgb, var(--accent) 35%, transparent); transform: translateY(-1px); }
.btn.ghost { background: transparent; border-color: var(--line); color: var(--ink); }
.btn.ghost:hover { background: var(--bg-2); }
html[data-dir="dispatch"] .btn { border-radius: 10px; }
html[data-dir="night"] .btn { border-radius: 12px; }

.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
html[data-dir="carnival"] .card { box-shadow: 0 2px 0 var(--line); }
html[data-dir="night"] .card { box-shadow: 0 1px 0 rgba(255,255,255,.04) inset; }

/* ----------------------------------------------------------------- nav */
.topnav { position: sticky; top: 0; z-index: 20; backdrop-filter: blur(10px); background: color-mix(in srgb, var(--bg) 82%, transparent); border-bottom: 1px solid var(--line); }
.topnav .wrap { display: flex; align-items: center; gap: 28px; height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; font-family: var(--font-display); font-weight: var(--display-weight); font-size: 22px; text-decoration: none; letter-spacing: -.02em; }
/* The monkey mark (img/logo.svg, traced from the Leonardo logo). Its orange
   follows the direction's accent through --logo; the face stays light/dark. */
.brand .mark { width: 40px; height: 40px; display: block; --logo: var(--accent); --logo-face: #fafafa; --logo-ink: #112829; }
html[data-dir="night"] .brand .mark { --logo-ink: #0d0f14; }
html[data-dir="carnival"] .brand .mark { transform: rotate(-6deg); }
footer .brand .mark { width: 32px; height: 32px; }
.topnav nav { display: flex; gap: 6px; margin-left: 8px; }
.topnav nav a { text-decoration: none; padding: 8px 12px; border-radius: 999px; font-weight: 500; color: var(--muted); transition: background .15s, color .15s; }
.topnav nav a:hover, .topnav nav a.active { color: var(--ink); background: var(--bg-2); }
.topnav .spacer { flex: 1; }

/* ---------------------------------------------------------------- hero */
.hero { padding: 72px 0 56px; position: relative; overflow: hidden; }
.hero .wrap { display: grid; gap: 40px; align-items: center; }
html[data-hero="split"] .hero .wrap { grid-template-columns: 1.1fr .9fr; }
html[data-hero="bleed"] .hero .wrap { grid-template-columns: 1fr; text-align: center; }
html[data-hero="bleed"] .hero .copy { max-width: 760px; margin: 0 auto; }
html[data-hero="bleed"] .hero .art { height: 320px; }
.hero .copy { display: grid; gap: 18px; }
.hero .actions { display: flex; gap: 12px; }
html[data-hero="bleed"] .hero .actions { justify-content: center; }
.hero .art { position: relative; height: 420px; border-radius: calc(var(--radius) * 1.6); background: var(--bg-2); overflow: hidden; }
.art .blob { position: absolute; border-radius: 50%; filter: blur(2px); animation: drift 9s ease-in-out infinite alternate; }
.art .b1 { width: 260px; height: 260px; background: var(--accent); left: 8%; top: 12%; }
.art .b2 { width: 200px; height: 200px; background: var(--accent-2); right: 10%; top: 30%; animation-delay: -3s; }
.art .b3 { width: 150px; height: 150px; background: var(--accent-3); left: 40%; bottom: 8%; animation-delay: -6s; }
html[data-dir="dispatch"] .art .blob { filter: none; border-radius: 22px; }
html[data-dir="night"] .art .blob { filter: blur(30px); opacity: .7; }
.art .house { position: absolute; left: 50%; bottom: 36px; transform: translateX(-50%); width: 220px; height: 150px; background: var(--surface); border: 3px solid var(--ink); border-radius: 26px 26px 10px 10px; animation: bounce 2.6s var(--ease) infinite; }
.art .house:before { content: ""; position: absolute; inset: 14px 14px auto 14px; height: 36px; border-radius: 14px; background: var(--accent-2); }
.art .house:after { content: ""; position: absolute; left: 50%; bottom: 10px; transform: translateX(-50%); width: 70px; height: 60px; border-radius: 35px 35px 4px 4px; background: var(--accent); }
html[data-dir="night"] .art .house { border-color: var(--accent); box-shadow: 0 0 40px color-mix(in srgb, var(--accent) 40%, transparent); }
@keyframes drift { to { transform: translate(18px, -14px) scale(1.06); } }
@keyframes bounce { 0%, 100% { transform: translateX(-50%) translateY(0) } 50% { transform: translateX(-50%) translateY(-18px) scaleX(1.03) } }
html[data-dir="dispatch"] .art .house { animation: none; }

/* ---------------------------------------------------------------- sections */
section.block { padding: 56px 0; }
.sect-head { display: flex; align-items: end; justify-content: space-between; gap: 24px; margin-bottom: 28px; }
.sect-head .lede { max-width: 60ch; color: var(--muted); margin-top: 8px; }

.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--gap); }
.step { padding: 22px; display: grid; gap: 10px; }
.step .n { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; background: var(--accent); color: var(--accent-ink); font-weight: 700; font-family: var(--font-display); }
html[data-dir="dispatch"] .step .n { border-radius: 8px; }

.products { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--gap); }
.product { overflow: hidden; display: grid; grid-template-rows: 190px auto; transition: transform .2s var(--ease), box-shadow .2s; }
.product:hover { transform: translateY(-4px); box-shadow: 0 18px 40px color-mix(in srgb, var(--ink) 12%, transparent); }
.product .pic { background: var(--bg-2); position: relative; }
.product .pic i { position: absolute; inset: auto 20px 16px 20px; height: 70px; border-radius: 20px 20px 6px 6px; background: var(--accent); opacity: .9; }
.product .pic i.train { border-radius: 10px; height: 44px; background: var(--accent-3); }
.product .pic i.gen { border-radius: 8px; height: 56px; width: 110px; background: var(--accent-2); }
.product .info { padding: 18px; display: grid; gap: 6px; }
.product .price { font-weight: 700; color: var(--accent); }
.tag { display: inline-block; font-size: 12px; padding: 3px 9px; border-radius: 999px; background: var(--bg-2); color: var(--muted); font-weight: 600; }
.filters { display: flex; gap: 8px; margin-bottom: 20px; }
.filters .tag { cursor: pointer; }
.filters .tag.on { background: var(--accent); color: var(--accent-ink); }

/* -------------------------------------------------------------- booking */
.booking { display: grid; grid-template-columns: 1.1fr .9fr; gap: var(--gap); }
.cal { padding: 22px; }
.cal .month { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; font-weight: 600; }
.cal .days { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.cal .d { aspect-ratio: 1; display: grid; place-items: center; border-radius: 10px; font-weight: 500; cursor: pointer; transition: background .12s, transform .12s; }
.cal .d:hover { background: var(--bg-2); transform: scale(1.05); }
.cal .d.sel { background: var(--accent); color: var(--accent-ink); font-weight: 700; }
.cal .d.full { color: var(--muted); text-decoration: line-through; cursor: not-allowed; }
.cal .d.dim { opacity: .35; }
.cal .wk { font-size: 12px; text-align: center; color: var(--muted); }
.summary { padding: 22px; display: grid; gap: 14px; align-content: start; }
.opt { display: flex; align-items: center; justify-content: space-between; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; cursor: pointer; }
.opt.on { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 8%, transparent); }
.slots { display: flex; gap: 8px; flex-wrap: wrap; }
.total { display: flex; justify-content: space-between; font-weight: 700; font-size: 18px; border-top: 1px solid var(--line); padding-top: 14px; }

/* ----------------------------------------------------------------- staff */
.login { max-width: 440px; margin: 60px auto; padding: 28px; display: grid; gap: 16px; }
.field { display: grid; gap: 6px; }
.field label { font-size: 13px; font-weight: 600; color: var(--muted); }
.field input { padding: 12px 14px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); color: var(--ink); font: inherit; }
.field input:focus { outline: 2px solid var(--accent); outline-offset: 1px; }

.app { display: grid; gap: var(--gap); padding: 48px 0; }
html[data-nav="side"] .app { grid-template-columns: 220px 1fr; }
.sidenav { display: none; }
html[data-nav="side"] .sidenav { display: grid; gap: 4px; align-content: start; padding: 14px; position: sticky; top: 90px; }
.sidenav a { text-decoration: none; padding: 10px 12px; border-radius: 10px; color: var(--muted); font-weight: 500; }
.sidenav a.active, .sidenav a:hover { background: var(--bg-2); color: var(--ink); }
.subnav { display: flex; gap: 6px; margin-bottom: 18px; }
html[data-nav="side"] .subnav { display: none; }

.jobs { display: grid; grid-template-columns: 1fr 1.3fr; gap: var(--gap); align-items: start; }
.job { padding: 16px 18px; display: grid; grid-template-columns: 1fr auto; gap: 6px 12px; cursor: pointer; border-left: 4px solid transparent; }
.job.on { border-left-color: var(--accent); }
.job .t { font-weight: 700; }
.job .when { font-variant-numeric: tabular-nums; color: var(--muted); }
.pill { font-size: 12px; font-weight: 700; padding: 3px 9px; border-radius: 999px; }
.pill.ok { background: color-mix(in srgb, var(--ok) 18%, transparent); color: var(--ok); }
.pill.warn { background: color-mix(in srgb, var(--warn) 22%, transparent); color: var(--warn); }
.pill.bad { background: color-mix(in srgb, var(--bad) 18%, transparent); color: var(--bad); }

.checklist { padding: 20px; display: grid; gap: 14px; }
.scanbar { display: flex; gap: 10px; align-items: center; padding: 14px; border-radius: 12px; background: var(--bg-2); border: 1px dashed var(--line); }
.scanbar input { flex: 1; font: inherit; font-size: 18px; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); letter-spacing: .06em; }
.scanbar .state { font-weight: 700; min-width: 120px; text-align: right; }
.scanbar.hit { border-color: var(--ok); box-shadow: 0 0 0 4px color-mix(in srgb, var(--ok) 25%, transparent); }
.items { display: grid; gap: 8px; }
.item { display: grid; grid-template-columns: 28px 1fr auto auto; gap: 12px; align-items: center; padding: 12px 14px; border-radius: 10px; border: 1px solid var(--line); transition: background .2s, transform .2s var(--ease); }
.item .box { width: 24px; height: 24px; border-radius: 7px; border: 2px solid var(--line); display: grid; place-items: center; font-size: 14px; }
.item.done { background: color-mix(in srgb, var(--ok) 9%, transparent); border-color: color-mix(in srgb, var(--ok) 40%, transparent); }
.item.done .box { background: var(--ok); border-color: var(--ok); color: #fff; }
.item .code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 13px; color: var(--muted); }
.item .kit { color: var(--muted); font-size: 13px; }
.item.short { border-color: var(--warn); }
html[data-density="compact"] .item { padding: 8px 12px; }
.progress { height: 10px; border-radius: 999px; background: var(--bg-2); overflow: hidden; }
.progress i { display: block; height: 100%; width: 40%; background: var(--ok); transition: width .4s var(--ease); }
.incident { display: grid; gap: 10px; padding: 16px; border-radius: 12px; background: color-mix(in srgb, var(--bad) 7%, transparent); border: 1px solid color-mix(in srgb, var(--bad) 30%, transparent); }
.incident .row { display: flex; gap: 8px; flex-wrap: wrap; }

/* ----------------------------------------------------------- transitions */
.page { animation: enter .45s var(--ease) both; }
html[data-dir="carnival"] .page { animation-name: enter-slide; }
html[data-dir="night"] .page { animation-name: enter-up; }
@keyframes enter { from { opacity: 0 } to { opacity: 1 } }
@keyframes enter-slide { from { opacity: 0; transform: translateX(40px) } to { opacity: 1; transform: none } }
@keyframes enter-up { from { opacity: 0; transform: translateY(30px) } to { opacity: 1; transform: none } }
.reveal { opacity: 0; transform: translateY(16px); transition: opacity .5s var(--ease), transform .5s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
html[data-dir="carnival"] .reveal.in { animation: pop .6s var(--ease); }
@keyframes pop { 0% { transform: scale(.92) } 60% { transform: scale(1.03) } 100% { transform: none } }
@media (prefers-reduced-motion: reduce) { .page, .reveal, .art .blob, .art .house { animation: none !important; transition: none !important; opacity: 1; transform: none; } }

/* ---------------------------------------------------------------- footer */
footer { border-top: 1px solid var(--line); padding: 36px 0; color: var(--muted); font-size: 14px; }
footer .wrap { display: flex; justify-content: space-between; gap: 20px; }

/* ----------------------------------------------------------------- panel */
.panel { position: fixed; right: 16px; bottom: 16px; z-index: 50; width: 300px; background: var(--surface); color: var(--ink); border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 20px 60px rgba(0,0,0,.25); font-family: Inter, system-ui, sans-serif; font-size: 13px; }
.panel header { display: flex; justify-content: space-between; align-items: center; padding: 12px 14px; border-bottom: 1px solid var(--line); font-weight: 700; cursor: pointer; }
.panel .body { padding: 12px 14px; display: grid; gap: 12px; }
.panel.min .body { display: none; }
.panel .row { display: grid; gap: 6px; }
.panel .row span { color: var(--muted); font-weight: 600; font-size: 11px; letter-spacing: .1em; text-transform: uppercase; }
.panel .opts { display: flex; gap: 6px; flex-wrap: wrap; }
.panel button { font: inherit; padding: 6px 10px; border-radius: 8px; border: 1px solid var(--line); background: var(--bg); color: var(--ink); cursor: pointer; }
.panel button.on { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.panel .sw { display: inline-block; width: 12px; height: 12px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.panel code { font-size: 11px; word-break: break-all; color: var(--muted); }

@media (max-width: 860px) {
  html[data-hero="split"] .hero .wrap, .booking, .jobs, html[data-nav="side"] .app { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr 1fr; }
  .products { grid-template-columns: 1fr; }
  .topnav nav { display: none; }
}

/* ---------------------------------------------------------------- images */
.product .pic { display: block; height: 190px; overflow: hidden; }
.product .pic img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pic { --img-bg: var(--bg-2); }
.hero .art { display: grid; place-items: center; }
.hero-img { position: relative; width: 70%; max-width: 420px; filter: drop-shadow(0 16px 30px rgba(0,0,0,.18)); animation: bounce 2.6s var(--ease) infinite; }
html[data-dir="dispatch"] .hero-img { animation: none; }
html[data-dir="night"] .hero-img { filter: drop-shadow(0 0 30px color-mix(in srgb, var(--accent) 45%, transparent)); }
@keyframes bounce { 0%, 100% { transform: translateY(0) } 50% { transform: translateY(-16px) scaleX(1.02) } }
.step-img { width: 100%; border-radius: 12px; margin-bottom: 4px; }
.spec { margin: 4px 0 8px; padding-left: 18px; color: var(--muted); font-size: 14px; display: grid; gap: 3px; }
.step .price { font-weight: 700; color: var(--accent); margin-top: auto; }
.seasonal-banner { display: grid; grid-template-columns: .9fr 1.1fr; gap: 40px; align-items: center; background: var(--surface); border: 1px solid var(--line); border-radius: calc(var(--radius) * 1.6); padding: 32px; }
.seasonal-banner img { width: 100%; border-radius: 16px; }
.quote { max-width: 720px; padding: 26px; display: grid; gap: 16px; }

/* ----------------------------------------------------------------- crew */
.crewwrap { max-width: 720px; padding-top: 36px; padding-bottom: 60px; }
.crewwrap .sect-head { align-items: center; }
.crew-img { width: 150px; border-radius: 16px; flex: none; }
.dayline { display: grid; gap: 10px; margin: 8px 0 28px; padding-left: 6px; border-left: 3px solid var(--line); }
.stop { display: flex; gap: 14px; align-items: flex-start; padding-left: 12px; position: relative; }
.stop .dot { position: absolute; left: -12px; top: 6px; width: 15px; height: 15px; border-radius: 50%; background: var(--accent); border: 3px solid var(--bg); }
.crew-jobs { display: grid; gap: var(--gap); }
.crewjob { padding: 20px; display: grid; gap: 16px; }
.crewhead { display: flex; justify-content: space-between; align-items: start; gap: 12px; }
.crewhead h3 { font-size: 22px; margin-top: 4px; }
.route { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; padding: 14px; border-radius: 12px; background: var(--bg-2); }
.route > div { display: grid; gap: 2px; font-size: 14px; }
.route span { font-size: 12px; text-transform: uppercase; letter-spacing: .1em; font-weight: 600; }
.route a { font-size: 13px; }
.crewjob .checklist { padding: 0; border: 0; }
html[data-dir="night"] .crewjob .checklist .item { background: var(--bg-2); }
@media (max-width: 860px) { .route, .seasonal-banner { grid-template-columns: 1fr; } .crew-img { display: none; } }

/* ------------------------------------------------------- small screens */
.crewwrap { padding-top: 56px; }
.scanbar input { min-width: 0; }
.scanbar .state { min-width: 0; white-space: nowrap; }
.item > span:nth-child(2) { min-width: 0; overflow-wrap: anywhere; }
.sect-head { flex-wrap: wrap; }
@media (max-width: 600px) {
  .topnav .wrap { gap: 10px; }
  .topnav .btn.primary { display: none; }
  .crewwrap .lede { font-size: 15px; }
  .item { grid-template-columns: 24px 1fr auto; }
  .item .kit { display: none; }
  .crewjob { padding: 14px; }
  .panel { width: 240px; }
}

/* Hash navigation scrolls the target <main> under the sticky nav; keep it below. */
main.page { scroll-margin-top: 100px; }

/* ----------------------------------------------------------------- photos */
.hero .art.photo { padding: 0; background: none; }
.hero .art.photo img { width: 100%; height: 100%; object-fit: cover; border-radius: inherit; display: block; }
html[data-dir="carnival"] .hero .art.photo { transform: rotate(-1.5deg); box-shadow: 0 24px 60px rgba(0,0,0,.18); }
html[data-dir="night"] .hero .art.photo img { filter: saturate(1.1) contrast(1.05); }
.product .pic img { width: 100%; height: 100%; object-fit: cover; }
.step-img { aspect-ratio: 16/10; object-fit: cover; }
.seasonal-banner img { aspect-ratio: 4/3; object-fit: cover; }
.credit { font-size: 12px; margin-top: 18px; }

/* -------------------------------------------------------------- stepper */
.stepper { list-style: none; margin: 0 0 20px; padding: 0; display: grid; gap: 8px; }
.stepper li { display: grid; grid-template-columns: 36px 1fr auto; align-items: center; gap: 14px; padding: 12px 14px; border-radius: var(--radius); border: 1px solid var(--line); background: var(--surface); cursor: pointer; opacity: .75; }
.stepper li.on { opacity: 1; border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 18%, transparent); }
.stepper li .n { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-family: var(--font-display); background: var(--bg-2); }
.stepper li.on .n { background: var(--accent); color: var(--accent-ink); }
.stepper li div { display: grid; }
.stepper li div .muted { font-size: 13px; }
.loadout { padding: 20px; display: grid; gap: 16px; }
.loadhead { display: flex; justify-content: space-between; gap: 16px; align-items: start; }
.loadhead h3 { font-size: 22px; margin: 4px 0 6px; }
.scanbtn { flex: none; font-size: 16px; padding: 14px 20px; }
.progress.big { height: 14px; }
.loadsum { display: flex; gap: 18px; font-size: 14px; color: var(--muted); }
.loadsum b { color: var(--ink); font-size: 18px; margin-right: 4px; }
.loadsum .warn b { color: var(--warn); }
.loadjob { display: grid; gap: 10px; padding-top: 14px; border-top: 1px solid var(--line); }
.loadjobhead { display: flex; justify-content: space-between; align-items: end; gap: 12px; }
.loadjobhead strong { font-size: 16px; display: block; }
.loadfoot { display: flex; gap: 10px; justify-content: flex-end; flex-wrap: wrap; }
.loadfoot .btn[disabled] { opacity: .5; cursor: not-allowed; }
.item { font-size: 16px; }
.item .box { width: 28px; height: 28px; border-radius: 8px; }
.stop-card { padding: 20px; display: grid; gap: 14px; margin-bottom: var(--gap); opacity: .7; }
.stop-card.on { opacity: 1; border-color: var(--accent); }
.stop-card h3 { font-size: 20px; margin-top: 4px; }
.setup { display: grid; gap: 8px; }
.chk { display: flex; gap: 10px; align-items: center; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; font-size: 15px; }
.chk input { width: 20px; height: 20px; accent-color: var(--accent); }

/* ------------------------------------------------------------- scanner */
.scanner { position: fixed; inset: 0; z-index: 60; background: #000; display: grid; grid-template-rows: 1fr auto; }
.viewfinder { position: relative; background: radial-gradient(ellipse at center, #2a2a2a, #090909); display: grid; place-items: center; }
.viewfinder.ok { box-shadow: inset 0 0 0 8px var(--ok); }
.viewfinder.bad { box-shadow: inset 0 0 0 8px var(--bad); }
.reticle { width: min(70vw, 360px); aspect-ratio: 1.6; border: 3px solid #fff; border-radius: 16px; box-shadow: 0 0 0 999px rgba(0,0,0,.45); position: relative; }
.reticle:after { content: ""; position: absolute; left: 8%; right: 8%; top: 50%; height: 2px; background: var(--accent, #f06a1f); box-shadow: 0 0 12px var(--accent, #f06a1f); animation: sweep 1.6s ease-in-out infinite alternate; }
@keyframes sweep { from { transform: translateY(-40px) } to { transform: translateY(40px) } }
.viewfinder .hint { position: absolute; top: 18px; color: #fff; font-weight: 600; letter-spacing: .04em; }
.viewfinder .fake { position: absolute; bottom: 16px; display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; padding: 0 16px; }
.viewfinder .fake button { font: inherit; font-family: ui-monospace, Menlo, monospace; padding: 10px 14px; border-radius: 10px; border: 1px solid #fff; background: rgba(255,255,255,.08); color: #fff; cursor: pointer; }
.scanfoot { display: flex; justify-content: space-between; align-items: center; padding: 16px 20px; background: #111; color: #fff; }
.scanfoot .state { font-weight: 700; } .scanfoot .state.ok { color: var(--ok) } .scanfoot .state.bad { color: var(--bad) }

/* ------------------------------------------------------------- dispatch */
.kpis { display: flex; gap: 16px; font-size: 14px; color: var(--muted); }
.kpis b { color: var(--ink); font-size: 20px; margin-right: 4px; font-family: var(--font-display); }
.kpis .warn b { color: var(--warn); }
.attention { padding: 18px 20px; display: flex; justify-content: space-between; gap: 20px; align-items: center; border-left: 5px solid var(--warn); margin-bottom: var(--gap); }
.attention strong { display: block; font-size: 17px; margin: 2px 0 4px; }
.attention .row { display: flex; gap: 8px; flex: none; flex-wrap: wrap; }
.board { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--gap); align-items: start; }
.lane { display: grid; gap: 10px; }
.lanehead { display: grid; grid-template-columns: 1fr auto; align-items: baseline; gap: 2px 8px; padding: 0 4px 6px; border-bottom: 2px solid var(--line); }
.lanehead .muted { grid-column: 1; font-size: 12px; }
.lanehead .count { grid-row: 1 / span 2; font-family: var(--font-display); font-size: 22px; }
.lane .empty { font-size: 13px; padding: 10px 4px; }
.drawer { position: fixed; top: 0; right: 0; bottom: 0; width: min(560px, 100vw); z-index: 40; background: color-mix(in srgb, var(--bg) 96%, transparent); border-left: 1px solid var(--line); box-shadow: -20px 0 60px rgba(0,0,0,.25); overflow: auto; padding: 20px; animation: enter-slide .35s var(--ease); }
.drawer .checklist { border: 0; background: transparent; padding: 0; }

/* --------------------------------------------------------------- catalog */
.catalog { display: grid; grid-template-columns: 280px 1fr; gap: var(--gap); align-items: start; }
.catlist { padding: 10px; display: grid; gap: 4px; }
.cathead { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; padding: 8px 10px 10px; }
.cathead .muted { font-size: 13px; display: block; font-weight: 400; }
.catrow { display: grid; grid-template-columns: 52px 1fr; gap: 12px; align-items: center; padding: 8px 10px; border-radius: 10px; text-decoration: none; }
.catrow img { width: 52px; height: 40px; object-fit: cover; border-radius: 8px; }
.catrow div { display: grid; } .catrow .muted { font-size: 12px; }
.catrow.on, .catrow:hover { background: var(--bg-2); }
.catedit { padding: 18px; display: grid; gap: 22px; }
.catsec { display: grid; gap: 6px; }
.comp { display: grid; grid-template-columns: 26px 1fr auto auto; gap: 12px; align-items: center; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; }
.comp .box { width: 22px; height: 22px; border-radius: 6px; background: var(--ok); color: #fff; display: grid; place-items: center; font-size: 13px; }
.comp.add { opacity: .6; border-style: dashed; } .comp.add .box { background: transparent; border: 2px solid var(--line); }
.comp div { display: grid; } .comp .muted { font-size: 12px; }
.comp .qty { font-weight: 700; min-width: 48px; text-align: right; }
.comp .qty input { width: 56px; padding: 6px 8px; border-radius: 8px; border: 1px solid var(--line); background: var(--bg); color: var(--ink); font: inherit; font-weight: 700; text-align: center; }
.preview-out { padding: 14px 16px; border-radius: 12px; background: var(--bg-2); display: grid; gap: 6px; }

@media (max-width: 1000px) { .board { grid-template-columns: 1fr 1fr; } .catalog { grid-template-columns: 1fr; } }
@media (max-width: 600px) { .board { grid-template-columns: 1fr; } .attention { flex-direction: column; align-items: start; } .loadhead { flex-direction: column; } .scanbtn { width: 100%; justify-content: center; } }

/* fixes after review */
.scanner[hidden], .drawer[hidden] { display: none; }
.topnav nav a { font-size: 14px; padding: 8px 10px; white-space: nowrap; }
.board { grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }
.job.lanecard { display: grid; grid-template-columns: 1fr; gap: 4px; }
.jobtop { display: flex; justify-content: space-between; align-items: start; gap: 8px; }
.jobtop .pill { flex: none; }
.lanecard .when { font-size: 13px; }

/* ---------------------------------------------------------------- footer */
footer.sitefoot { padding: 48px 0 28px; }
footer.sitefoot .wrap { display: block; }
.footgrid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.3fr; gap: 32px; padding-bottom: 28px; border-bottom: 1px solid var(--line); }
.footgrid > div { display: grid; gap: 8px; align-content: start; font-size: 14px; }
.footgrid strong { color: var(--ink); margin-bottom: 4px; }
.footgrid a { text-decoration: none; color: var(--muted); }
.footgrid a:hover { color: var(--accent); }
.footbar { display: flex; justify-content: space-between; gap: 16px; padding-top: 18px; font-size: 13px; }
.footbar a { color: inherit; }
.map { height: 150px; border-radius: 12px; background: var(--bg-2); position: relative; display: grid; place-items: center; color: var(--muted); font-weight: 600; overflow: hidden; }
.map i { position: absolute; width: 14px; height: 14px; border-radius: 50%; background: var(--accent); top: 46%; left: 52%; box-shadow: 0 0 0 8px color-mix(in srgb, var(--accent) 25%, transparent); }
@media (max-width: 860px) { .footgrid { grid-template-columns: 1fr 1fr; } }

/* ------------------------------------------------------------ staff mode */
.staffbar { display: inline-flex; align-items: center; gap: 10px; }
.staffbar .who { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 600; color: var(--muted); margin-right: 6px; }
.staffbar .who i { width: 26px; height: 26px; border-radius: 50%; background: var(--accent); display: inline-block; }
html[data-mode="staff"] .topnav { background: color-mix(in srgb, var(--bg-2) 85%, transparent); }
html[data-mode="staff"] .topnav nav a.active { background: var(--accent); color: var(--accent-ink); }
html[data-mode="staff"] footer .footgrid { display: none; }

/* display rules above beat the hidden attribute; make hidden win */
[hidden] { display: none !important; }

/* --------------------------------------------------------------- booking */
.bsteps { list-style: none; margin: 0 0 24px; padding: 0; display: flex; gap: 8px; flex-wrap: wrap; }
.bsteps li { display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px 8px 8px; border-radius: 999px; border: 1px solid var(--line); font-weight: 600; font-size: 14px; color: var(--muted); }
.bsteps li .n { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; background: var(--bg-2); font-size: 13px; }
.bsteps li.on { color: var(--ink); border-color: var(--accent); } .bsteps li.on .n { background: var(--accent); color: var(--accent-ink); }
.bsteps li.done .n { background: var(--ok); color: #fff; }
.addon { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; cursor: pointer; }
.addon input { width: 18px; height: 18px; accent-color: var(--accent); }
.addon span { flex: 1; }
.line { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; border-bottom: 1px dashed var(--line); font-size: 15px; }
.line .muted { flex: none; min-width: 80px; }
.confirm { padding: 32px; display: grid; gap: 24px; max-width: 820px; }
.confirm-head { display: flex; gap: 20px; align-items: center; }
.bigcheck { width: 64px; height: 64px; border-radius: 50%; background: var(--ok); color: #fff; display: grid; place-items: center; font-size: 32px; font-weight: 800; flex: none; animation: pop .6s var(--ease); }
.confirm-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; padding: 18px; border-radius: 12px; background: var(--bg-2); }
.confirm-grid div { display: grid; gap: 4px; font-size: 14px; } .confirm-grid .muted { font-size: 12px; text-transform: uppercase; letter-spacing: .1em; font-weight: 600; }
.next ol { margin: 10px 0 0; padding-left: 20px; display: grid; gap: 8px; }
@media (max-width: 860px) { .confirm-grid { grid-template-columns: 1fr 1fr; } }
.roles { display: grid; gap: 8px; margin-top: 6px; }
.rolebtn { display: grid; text-align: left; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); color: var(--ink); font: inherit; cursor: pointer; }
.rolebtn:hover { border-color: var(--accent); }
.rolebtn .muted { font-size: 12px; }

/* ----------------------------------------------------------------- team */
.teamgrid { display: grid; grid-template-columns: 1fr 1.2fr; gap: var(--gap); align-items: start; }
.teamlist, .assign { padding: 10px 10px 14px; display: grid; gap: 6px; }
.emp { display: grid; grid-template-columns: 36px 1fr auto auto; gap: 12px; align-items: center; padding: 10px 12px; border-radius: 10px; }
.emp:hover { background: var(--bg-2); }
.emp div { display: grid; } .emp .muted { font-size: 12px; }
.avatar { width: 36px; height: 36px; border-radius: 50%; background: var(--accent); color: var(--accent-ink); display: grid; place-items: center; font-weight: 800; font-family: var(--font-display); }
.arow { display: grid; gap: 8px; padding: 12px; border-top: 1px solid var(--line); }
.arow > div:first-child { display: grid; } .arow .muted { font-size: 12px; }
.arow .pill { justify-self: start; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; }
.chip { font: inherit; font-size: 13px; font-weight: 600; padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); cursor: pointer; }
.chip.on { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.chip.off { opacity: .4; text-decoration: line-through; cursor: not-allowed; }
.addemp { padding: 20px; margin-bottom: var(--gap); display: grid; gap: 12px; }
.addgrid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
@media (max-width: 1000px) { .teamgrid, .addgrid { grid-template-columns: 1fr; } }

/* ------------------------------------------------------------ customers */
.custgrid { display: grid; grid-template-columns: 340px 1fr; gap: var(--gap); align-items: start; }
.custlist { padding: 10px; display: grid; gap: 6px; }
.search { font: inherit; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); color: var(--ink); margin: 4px 0; }
.crow { display: grid; grid-template-columns: 36px 1fr auto; gap: 12px; align-items: center; padding: 10px; border-radius: 10px; cursor: pointer; }
.crow div { display: grid; min-width: 0; } .crow .muted { font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.crow.on, .crow:hover { background: var(--bg-2); }
.avatar.lead { background: var(--warn); color: #1d1410; }
.avatar.big { width: 52px; height: 52px; font-size: 22px; }
.custrec { padding: 20px; display: grid; gap: 16px; }
.rechead { display: grid; grid-template-columns: 52px 1fr auto; gap: 14px; align-items: center; }
.rechead h3 { font-size: 24px; } .rechead .row { display: flex; gap: 8px; }
.recfacts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; padding: 14px; border-radius: 12px; background: var(--bg-2); }
.recfacts div { display: grid; gap: 2px; font-size: 14px; min-width: 0; } .recfacts .muted { font-size: 11px; text-transform: uppercase; letter-spacing: .1em; font-weight: 600; } .recfacts strong { overflow-wrap: anywhere; }
.nextbox { padding: 12px 14px; border-radius: 12px; border: 1px solid var(--line); display: grid; gap: 2px; }
.leadbox { margin: 0; }
.timeline { display: grid; gap: 0; border-left: 2px solid var(--line); margin-left: 14px; }
.tl { display: grid; grid-template-columns: 28px 1fr; gap: 10px; padding: 8px 0 8px 10px; position: relative; }
.tlicon { width: 28px; height: 28px; border-radius: 50%; background: var(--surface); border: 1px solid var(--line); display: grid; place-items: center; font-size: 14px; margin-left: -25px; }
.tl div { display: grid; gap: 1px; } .tl .muted { font-size: 12px; } .tl strong { font-weight: 500; }
.auto { padding: 14px; border-radius: 12px; background: var(--bg-2); display: grid; gap: 8px; }
@media (max-width: 1000px) { .custgrid, .recfacts { grid-template-columns: 1fr; } .rechead { grid-template-columns: 52px 1fr; } .rechead .row { grid-column: 1 / -1; } }

/* ================================================================ icons */
[data-lucide], svg.lucide { width: 18px; height: 18px; stroke-width: 2.2; vertical-align: -3px; flex: none; }
.topnav nav a { display: inline-flex; align-items: center; gap: 6px; }
.topnav nav a svg { width: 16px; height: 16px; opacity: .8; }
.step .n svg { width: 18px; height: 18px; }
.rowicon { width: 16px; height: 16px; margin-right: 8px; opacity: .6; vertical-align: -3px; }
.item.short .rowicon { color: var(--warn); opacity: 1; }
.tlicon svg { width: 14px; height: 14px; }
.footgrid a, .footgrid .muted { display: inline-flex; align-items: center; gap: 8px; }
.footgrid svg { width: 15px; height: 15px; opacity: .7; }
.eyebrow svg { width: 13px; height: 13px; vertical-align: -2px; }
html[data-dir="carnival"] svg.lucide { stroke-width: 2.6; }
html[data-dir="night"] svg.lucide { stroke-width: 1.8; }

/* =============================================================== motion */
.reveal { transition-delay: calc(var(--i, 0) * 70ms); }
html[data-dir="carnival"] .reveal.in { animation-delay: calc(var(--i, 0) * 70ms); }
.hero .art { animation: float 6s ease-in-out infinite; transform: translateY(calc(var(--scroll, 0) * -0.06px)); }
@keyframes float { 50% { margin-top: -10px } }
html[data-dir="carnival"] .hero .art.photo { animation: float 6s ease-in-out infinite, tilt 6s ease-in-out infinite; }
@keyframes tilt { 50% { rotate: -2.5deg } }
.product .pic img { transition: transform .6s var(--ease); }
.product:hover .pic img { transform: scale(1.06); }
.item.done { animation: tick .35s var(--ease); }
@keyframes tick { 0% { transform: scale(.98); background: color-mix(in srgb, var(--ok) 35%, transparent) } 100% { transform: none } }
.progress i { transition: width .5s cubic-bezier(.3,1.4,.5,1); }
.btn.primary { position: relative; overflow: hidden; }
.btn.primary::after { content: ""; position: absolute; inset: 0; background: linear-gradient(110deg, transparent 30%, rgba(255,255,255,.35) 50%, transparent 70%); transform: translateX(-120%); transition: transform .6s var(--ease); }
.btn.primary:hover::after { transform: translateX(120%); }
.confetti { position: fixed; inset: 0; pointer-events: none; z-index: 70; overflow: hidden; }
.confetti i { position: absolute; top: -20px; width: 10px; height: 16px; border-radius: 2px; animation: fall linear forwards; }
@keyframes fall { to { transform: translateY(110vh) rotate(720deg); opacity: .2 } }
.kpis b, .loadsum b { font-variant-numeric: tabular-nums; }
@media (prefers-reduced-motion: reduce) { .hero .art, .hero .art.photo, .btn.primary::after, .confetti i, .item.done { animation: none !important; transition: none !important; } html[data-mode="staff"] .hero .art { animation: none; }

/* =========================================================== backgrounds */
.bgfx { position: fixed; inset: 0; z-index: -1; pointer-events: none; overflow: hidden; }
.bgfx i { position: absolute; border-radius: 50%; filter: blur(80px); opacity: 0; }
/* Carnival: confetti dots on the cream; waves between sections */
html[data-dir="carnival"] body { background-image: radial-gradient(color-mix(in srgb, var(--accent) 16%, transparent) 1.5px, transparent 1.5px), radial-gradient(color-mix(in srgb, var(--accent-3) 18%, transparent) 1.5px, transparent 1.5px); background-size: 42px 42px, 42px 42px; background-position: 0 0, 21px 21px; }
.wave { display: none; height: 60px; margin-bottom: -1px; }
.wave svg { width: 100%; height: 100%; display: block; }
html[data-dir="carnival"] .wave { display: block; } html[data-dir="carnival"] .wave path { fill: color-mix(in srgb, var(--ink) 80%, #6b3d2a); }
/* Dispatch: a faint engineering grid on the staff pages */
html[data-dir="dispatch"][data-mode="staff"] body { background-image: linear-gradient(color-mix(in srgb, var(--ink) 5%, transparent) 1px, transparent 1px), linear-gradient(90deg, color-mix(in srgb, var(--ink) 5%, transparent) 1px, transparent 1px); background-size: 28px 28px; }
/* Night: slow glow blobs behind everything */
html[data-dir="night"] .bgfx i { opacity: .55; animation: glow 14s ease-in-out infinite alternate; }
html[data-dir="night"] .bgfx .g1 { width: 50vw; height: 50vw; left: -10vw; top: -10vh; background: var(--accent); }
html[data-dir="night"] .bgfx .g2 { width: 40vw; height: 40vw; right: -10vw; bottom: -10vh; background: var(--accent-3); animation-delay: -7s; }
@keyframes glow { to { transform: translate(6vw, 4vh) scale(1.15) } }
/* photo band behind a section, with a gradient so the cards stay readable */
.band { position: relative; isolation: isolate; color: var(--ink); }
.band::before { content: ""; position: absolute; inset: 0; z-index: -2; background: var(--band) center/cover no-repeat; }
.band::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, color-mix(in srgb, var(--bg) 92%, transparent), color-mix(in srgb, var(--bg) 78%, transparent)); }
html[data-dir="carnival"] .band::after { background: linear-gradient(180deg, color-mix(in srgb, var(--ink) 78%, transparent) 0%, color-mix(in srgb, var(--ink) 66%, transparent) 100%); }
html[data-dir="carnival"] .band { color: #fff; } html[data-dir="carnival"] .band .sect-head .eyebrow { color: var(--accent-2); } html[data-dir="carnival"] .band .btn.ghost { color: #fff; border-color: rgba(255,255,255,.4); }
html[data-dir="night"] .band::after { background: linear-gradient(180deg, color-mix(in srgb, var(--bg) 80%, transparent), color-mix(in srgb, var(--bg) 92%, transparent)); }
/* full-width photo hero (about, seasonal) with the copy on a gradient */
.photo-hero { padding: 96px 0 88px; background: var(--hero) center/cover no-repeat; color: #fff; }
.photo-hero::before { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(10,10,14,.82) 0%, rgba(10,10,14,.55) 55%, rgba(10,10,14,.15) 100%); }
.photo-hero .wrap { grid-template-columns: 1fr !important; position: relative; }
.photo-hero .copy { max-width: 620px; }
.photo-hero .muted { color: rgba(255,255,255,.82); }
.photo-hero .btn.ghost { color: #fff; border-color: rgba(255,255,255,.45); }
html[data-dir="carnival"] .photo-hero::before { background: linear-gradient(90deg, color-mix(in srgb, var(--ink) 85%, var(--accent)) 0%, color-mix(in srgb, var(--ink) 50%, transparent) 60%, transparent 100%); }
.photo-hero .wrap { z-index: 1; }
.btn.sent { background: var(--ok); cursor: default; }
#walk { scroll-margin-top: 90px; }

/* ------------------------------------------------------------ demo site */
.demobar { background: var(--ink); color: var(--bg); font-size: 13px; text-align: center; padding: 8px 16px; }
.demobar a { color: var(--accent-2); }
html[data-dir="night"] .demobar { background: var(--accent); color: var(--accent-ink); } html[data-dir="night"] .demobar a { color: var(--accent-ink); }
.demo-note { margin-top: 8px; padding: 10px 12px; border-radius: 10px; background: color-mix(in srgb, var(--warn) 18%, transparent); font-size: 14px; }
.demo-inline { display: inline-block; margin-top: 6px; padding: 2px 8px; border-radius: 6px; background: color-mix(in srgb, var(--warn) 22%, transparent); font-size: 13px; font-weight: 600; }
.loginform { display: grid; gap: 14px; }
.err { color: var(--bad); font-weight: 600; font-size: 14px; }
.topnav { top: 0; }

/* footer legibility on the dark directions and palettes */
footer.sitefoot { color: color-mix(in srgb, var(--ink) 72%, var(--bg)); }
.footgrid a, .footgrid .muted, .footbar, .footbar a { color: color-mix(in srgb, var(--ink) 72%, var(--bg)); }
.footgrid strong, .footgrid .brand { color: var(--ink); }
html[data-dir="night"] footer.sitefoot, html[data-dir="night"] .footgrid a, html[data-dir="night"] .footgrid .muted, html[data-dir="night"] .footbar, html[data-dir="night"] .footbar a { color: color-mix(in srgb, var(--ink) 82%, var(--bg)); }
.footgrid a:hover, .footbar a:hover { color: var(--accent); }
