/* Shaped after the Apprtur client's window, in Kestr's indigo. */
:root {
  --bar: 62px; --shade: 0 2px 4px rgb(0 0 0 / .1), 0 6px 20px rgb(0 0 0 / .14);
  --series-1: #4f46e5;
  /* the brand's second colour, gold, kept for what needs attention: recommended actions, medians and trends */
  --gold: #d9a521; --gold-fill: #f1c95b; --gold-ink: #85610a; --on-gold: #17151f;
  /* soft green for below the market, soft red for above it */
  --good: #2f8a60; --gap: #c25a5a;
  --pie-from: #3730a3; --pie-to: #e2e2e7;
  /* buttons are lit from above: a hairline of light on the top rim and a soft shade inside it */
  --lit: inset 0 1px 0 rgb(255 255 255 / .85), inset 0 12px 14px -10px rgb(0 0 0 / .1);
  color-scheme: light;
  --page: #f3f3f3; --card: #fbfbfb; --line: #e3e3e3; --ink: #1a1a1a; --ink-2: #5c5c5c; --control: #ffffff; --hover: #ececec;
  --sheen: rgb(255 255 255 / .75); --bone: #e6e6e8; --brand: #4f46e5; --brand-hover: #6366f1; --accent-text: #3730a3; --wash: #ebeafd;
  --error: #a4262c; --error-wash: #fde7e9;
}
:root[data-theme="dark"] {
  color-scheme: dark; --sheen: rgb(255 255 255 / .07); --bone: #353535; --shade: 0 2px 4px rgb(0 0 0 / .45), 0 6px 22px rgb(0 0 0 / .55); --series-1: #6366f1;
  --gold: #f1c95b; --gold-ink: #f1c95b; --good: #6fcb9a; --gap: #e98f8f; --pie-from: #4f46e5; --pie-to: #ececf1;
  --lit: inset 0 1px 0 rgb(255 255 255 / .2), inset 0 14px 16px -10px rgb(0 0 0 / .34);
  --page: #202020; --card: #2b2b2b; --line: #393939; --ink: #f5f5f5; --ink-2: #bdbdbd; --control: #333333; --hover: #333333;
  --accent-text: #b4b1fb; --wash: #34325a; --error: #ff99a4; --error-wash: #442726;
}
@media (prefers-color-scheme: dark) {
  :root[data-theme="system"] {
    color-scheme: dark; --sheen: rgb(255 255 255 / .07); --bone: #353535; --shade: 0 2px 4px rgb(0 0 0 / .45), 0 6px 22px rgb(0 0 0 / .55); --series-1: #6366f1;
    --gold: #f1c95b; --gold-ink: #f1c95b; --good: #6fcb9a; --gap: #e98f8f; --pie-from: #4f46e5; --pie-to: #ececf1;
    --lit: inset 0 1px 0 rgb(255 255 255 / .2), inset 0 14px 16px -10px rgb(0 0 0 / .34);
    --page: #202020; --card: #2b2b2b; --line: #393939; --ink: #f5f5f5; --ink-2: #bdbdbd; --control: #333333; --hover: #333333;
    --accent-text: #b4b1fb; --wash: #34325a; --error: #ff99a4; --error-wash: #442726;
  }
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; min-height: 100vh; display: grid; grid-template: "title title" var(--bar) "side page" 1fr / 224px minmax(0, 1fr); background: var(--page); color: var(--ink); font: 14px/1.5 "Segoe UI Variable Text", "Segoe UI", system-ui, -apple-system, sans-serif; }
body.collapsed { grid-template-columns: 60px minmax(0, 1fr); }
h1, h2, h3, p, dl, dd, ul { margin: 0; padding: 0; }
h1 { font-size: 28px; line-height: 1.3; font-weight: 600; }
h2 { font-size: 20px; font-weight: 600; }
h3 { font-size: 16px; font-weight: 600; }
ul { list-style: none; }
small { font-size: 12px; color: var(--ink-2); }
button, select, input, textarea { font: inherit; color: var(--ink); background: var(--control); border: 1px solid var(--line); border-radius: 5px; padding: 6px 12px; }
button { cursor: pointer; }
button:hover:not(:disabled) { background: var(--hover); }
button:disabled { cursor: default; opacity: .55; }
:where(button, a.button, select) { box-shadow: var(--lit); }
.primary { box-shadow: inset 0 1px 0 rgb(255 255 255 / .34), inset 0 14px 16px -10px rgb(0 0 0 / .3); }
.nav:not(.primary), .tile, button.score, .slot, .bar-row, .todo button, .link, .row, .board h3 button:not(.today), .type-menu .link, .maplibregl-ctrl button { box-shadow: none; }
a.button.primary { background: var(--brand); border-color: var(--brand); color: #fff; font-weight: 600; }
a.button.primary:hover { background: var(--brand-hover); }
a.button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; text-decoration: none; color: var(--ink); background: var(--control); border: 1px solid var(--line); border-radius: 5px; padding: 6px 12px; }
a.button:hover { background: var(--hover); }
mark { background: var(--wash); color: var(--accent-text); border-radius: 5px; padding: 1px 8px; font-size: 11px; font-weight: 600; }
h4 { margin: 18px 0 4px; font-size: 14px; font-weight: 600; }
button { transition: background-color .15s, border-color .15s, transform .08s; }
button:active:not(:disabled) { transform: scale(.98); }
:focus-visible { outline: 2px solid var(--brand-hover); outline-offset: 2px; }
.primary, .primary:hover:not(:disabled) { background: var(--brand); border-color: var(--brand); color: #fff; font-weight: 600; }
.primary:hover:not(:disabled) { background: var(--brand-hover); }
.link { background: none; border: 0; color: var(--accent-text); padding: 4px 0; justify-self: start; }
.ico { width: 16px; height: 16px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; vertical-align: -3px; }
.with-icon { display: inline-flex; align-items: center; gap: 8px; }
.icon { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-width: 34px; height: 34px; padding: 0 8px; }
.danger { color: var(--error); margin-left: auto; }

/* shell */
/* the banner stands over the rest of the window and shades it */
.titlebar { grid-area: title; position: sticky; top: 0; z-index: 15; display: flex; align-items: center; gap: 12px; padding: 0 16px; background: var(--card); box-shadow: var(--shade); }
.titlebar span { font: 800 22px/1 'Inter', 'Segoe UI', system-ui, sans-serif; letter-spacing: -.02em; }
.titlebar b { margin-left: auto; background: var(--wash); color: var(--accent-text); border-radius: 4px; padding: 1px 10px; font-size: 12px; }
#sidebar { grid-area: side; display: flex; flex-direction: column; gap: 4px; padding: 8px 8px 14px; position: sticky; top: var(--bar); align-self: start; height: calc(100vh - var(--bar)); }
.nav { display: flex; align-items: center; gap: 14px; width: 100%; min-height: 40px; padding: 9px 13px; border: 0; border-radius: 5px; background: transparent; color: var(--ink); text-decoration: none; position: relative; text-align: left; white-space: nowrap; }
a.nav:hover, button.nav:hover:not(:disabled) { background: var(--hover); }
.nav[aria-current="page"] { background: var(--wash); }
.nav[aria-current="page"]::before { content: ""; position: absolute; left: 0; top: 11px; bottom: 11px; width: 3px; border-radius: 2px; background: var(--brand); }
.nav.primary { background: var(--brand); color: #fff; }
.toggle { width: 42px; }
.foot { margin-top: auto; display: grid; gap: 8px; }
.account { position: relative; }
.account summary { display: flex; align-items: center; gap: 10px; padding: 4px 6px; border-radius: 5px; cursor: pointer; list-style: none; }
.account summary::-webkit-details-marker { display: none; }
.account summary:hover { background: var(--hover); }
.account summary i { width: 32px; height: 32px; border-radius: 50%; background: var(--brand); color: #fff; display: grid; place-items: center; font-style: normal; font-weight: 600; flex: none; }
.account summary span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.menu-pop { position: absolute; bottom: calc(100% + 6px); left: 0; width: 208px; background: var(--card); border: 1px solid var(--line); border-radius: 8px; padding: 4px; box-shadow: 0 8px 24px rgb(0 0 0 / .25); z-index: 5; }
body.collapsed .nav span, body.collapsed .account summary span { display: none; }
body.collapsed .menu-pop .nav span { display: inline; }
#page { grid-area: page; padding: 16px 24px 40px; min-width: 0; width: 100%; }

/* page */
.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 14px; }
.page-head p { color: var(--ink-2); }
.page-title { display: flex; align-items: center; gap: 8px; min-width: 0; }
.page-title h1 { min-width: 0; overflow-wrap: anywhere; }
.back { display: grid; place-items: center; width: 40px; height: 40px; flex: none; margin-left: -8px; border-radius: 6px; color: var(--ink); }
.back:hover { background: var(--hover); }
.back .ico { width: 20px; height: 20px; }
.toolbar { display: flex; gap: 12px; align-items: flex-end; flex-wrap: wrap; }
.pivot { display: flex; gap: 26px; margin-bottom: 18px; }
.pivot a { color: var(--ink-2); text-decoration: none; font-size: 20px; padding: 4px 0 7px; border-bottom: 3px solid transparent; }
.pivot a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--brand); }
.pivot a span { font-size: 13px; color: var(--ink-2); }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 8px; padding: 18px 20px; margin-top: 14px; min-width: 0; }
.narrow { max-width: 560px; }
.center { text-align: center; }
.meta { color: var(--ink-2); margin-top: 4px; overflow-wrap: anywhere; }
.chip { border-radius: 20px; padding: 1px 10px; font-size: 12px; }
.chip { display: inline-flex; align-items: center; gap: 5px; background: var(--wash); color: var(--accent-text); }
.chip .ico { width: 13px; height: 13px; }

.infobar { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; border-radius: 6px; border: 1px solid var(--line); background: var(--wash); padding: 10px 14px; margin: 10px 0; }
.infobar.error { background: var(--error-wash); color: var(--error); }
.empty { display: grid; justify-items: center; gap: 12px; text-align: center; padding: 80px 16px; }
.empty p { color: var(--ink-2); max-width: 460px; }
.spinner { width: 28px; height: 28px; border-radius: 50%; border: 3px solid var(--line); border-top-color: var(--brand); animation: spin .8s linear infinite; }
.spinner.small { display: inline-block; width: 12px; height: 12px; border-width: 2px; margin-right: 8px; vertical-align: -1px; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .spinner { animation-duration: 3s; } }
.segmented { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.toolbar .segmented { margin: 0; }
.segmented button[aria-pressed="true"], .chips button[aria-pressed="true"] { background: var(--brand); border-color: var(--brand); color: #fff; }

/* week */
.week-nav { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; }
.week-nav > div { display: flex; gap: 6px; flex-wrap: wrap; }
.week-nav .segmented { margin: 0 14px 0 0; flex-wrap: nowrap; gap: 0; }
.week-nav .segmented button { min-width: 64px; border-radius: 0; }
.week-nav .segmented button:first-child { border-radius: 5px 0 0 5px; }
.week-nav .segmented button:last-child { border-radius: 0 5px 5px 0; border-left-width: 0; }
.board { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 8px; margin-top: 12px; }
.board section { background: var(--card); border: 1px solid var(--line); border-radius: 8px; padding: 8px; min-height: 180px; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.board h3 { font-size: 12px; text-align: center; }
.board h3 button { width: 100%; padding: 3px 4px; border: 0; background: transparent; color: var(--ink-2); font-weight: 600; }
.board h3 button.today { background: var(--brand); color: #fff; }
.board h3 button.today:hover { background: var(--brand-hover); }
.tile { position: relative; display: grid; justify-items: start; align-content: start; text-align: left; gap: 1px; padding: 6px 8px 9px; border: 0; border-radius: 6px; overflow-wrap: anywhere; }
/* the name shares the top of the tile with the pencil */
.tile > span:first-child { display: flex; align-items: center; min-height: 28px; padding-right: 32px; }
.tile, .tile:hover:not(:disabled) { background: var(--wash); color: var(--ink); }
.tile:hover { outline: 1px solid var(--brand); }
.tile span { font-weight: 600; font-size: 13px; line-height: 1.3; }
.tile small { color: inherit; opacity: .85; }
.tile .edit { position: absolute; top: 6px; right: 6px; display: grid; place-items: center; width: 28px; height: 28px; background: var(--control); border: 1px solid var(--line); border-radius: 5px; color: var(--ink); }
/* the pencil shows under the pointer, or on the tile the keyboard is at */
.tile .edit { opacity: 0; transition: opacity .12s; }
.tile:hover .edit, .tile:focus-visible .edit { opacity: 1; }
.none { color: var(--ink-2); font-size: 12px; text-align: center; padding: 8px 0; }
.performance { margin-top: 24px; }
/* the page's main actions: a round button that flies in from below and fans its choices out above it */
#fab { position: fixed; right: 44px; bottom: 44px; z-index: 12; display: grid; justify-items: end; gap: 12px; pointer-events: none; opacity: 0; visibility: hidden; transform: translateY(120px); transition: transform .26s cubic-bezier(.4, 0, .2, 1), opacity .26s cubic-bezier(.4, 0, .2, 1), visibility 0s .26s; }
#fab.shown { opacity: 1; visibility: visible; transform: none; transition: transform .26s cubic-bezier(.4, 0, .2, 1) .18s, opacity .26s cubic-bezier(.4, 0, .2, 1) .18s, visibility 0s .18s; }
.fab-main { display: grid; place-items: center; width: 48px; height: 48px; padding: 0; border: 0; border-radius: 50%; background: var(--brand); color: #fff; pointer-events: auto; box-shadow: inset 0 1px 0 rgb(255 255 255 / .34), inset 0 18px 20px -12px rgb(0 0 0 / .34), 0 6px 20px rgb(0 0 0 / .35); }
.fab-main:hover:not(:disabled) { background: var(--brand-hover); }
.fab-main:disabled { opacity: 1; }
.fab-main .spinner { width: 20px; height: 20px; border-color: rgb(255 255 255 / .35); border-top-color: #fff; }
.fab-main .ico { width: 20px; height: 20px; transition: transform .26s cubic-bezier(.4, 0, .2, 1); }
#fab.open .fab-main .ico { transform: rotate(45deg); }
.fab-menu { display: grid; justify-items: end; gap: 12px; }
/* each choice grows out of the button, the nearest first, and gathers back the other way round */
.fab-menu li { opacity: 0; visibility: hidden; transform-origin: bottom right; transform: translateY(50%) scale(.4);
  transition: transform .34s cubic-bezier(.6, 0, .66, -.4) calc((var(--m) - var(--d)) * 55ms), opacity .18s calc((var(--m) - var(--d)) * 55ms), visibility 0s calc((var(--m) - var(--d)) * 55ms + .34s); }
#fab.open .fab-menu li { opacity: 1; visibility: visible; transform: none; pointer-events: auto;
  transition: transform .34s cubic-bezier(.34, 1.4, .4, 1) calc(var(--d) * 55ms), opacity .18s calc(var(--d) * 55ms), visibility 0s; }
.fab-item { display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 16px 0 14px; border-radius: 20px; font-size: 13px; font-weight: 600; box-shadow: var(--lit), 0 6px 18px rgb(0 0 0 / .3); }
.fab-item.primary { box-shadow: inset 0 1px 0 rgb(255 255 255 / .34), inset 0 16px 18px -12px rgb(0 0 0 / .32), 0 6px 18px rgb(0 0 0 / .3); }
.fab-item .ico { width: 17px; height: 17px; }
.has-fab #page { padding-bottom: 116px; }
.day-view, .cards { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 12px; }
.day-view > .card, .cards > .card { flex: 1 1 min(480px, 100%); margin-top: 0; }
.day-view > .none { text-align: left; }
.card-title { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.card-title .end { margin-left: auto; }
.menu { margin-top: 10px; max-width: 460px; }
.menu li { display: flex; justify-content: space-between; gap: 16px; border-top: 1px solid var(--line); padding: 5px 0; }
.stats { display: flex; flex-wrap: wrap; gap: 4px 18px; align-items: center; margin-top: 10px; color: var(--ink-2); font-size: 13px; }
.stats span { display: inline-flex; align-items: center; gap: 5px; }
.stats b { color: var(--ink); }
.center .stats { justify-content: center; }
.rows li { border-top: 1px solid var(--line); }
.rows li:first-child { margin-top: 10px; }
.row { display: flex; align-items: center; gap: 12px; width: 100%; background: none; border: 0; border-radius: 0; text-align: left; padding: 9px 4px; }
.row small { margin-left: auto; }

/* special performance: two figures that open what is behind them, then the analysis and the actions */
/* equal columns, so a card alone on its row is no wider than the rest */
.performance .cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(460px, 100%), 1fr)); align-items: start; }
.performance .cards > .card { min-width: 0; }
.perf .card-title { flex-wrap: nowrap; }
.perf h3 { min-width: 0; overflow-wrap: anywhere; }
.kind { display: grid; place-items: center; flex: none; color: var(--accent-text); }
.kind .ico { width: 18px; height: 18px; }
.definitions h4 { margin-top: 12px; }
.row > .ico:first-child { color: var(--accent-text); }
.scores { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 8px; margin: 12px 0 10px; }
.score { display: flex; align-items: center; gap: 12px; min-width: 0; padding: 7px 12px 7px 8px; background: var(--page); border: 1px solid transparent; border-radius: 10px; text-align: left; font-size: 13px; font-weight: 600; }
button.score:hover:not(:disabled) { background: var(--page); border-color: var(--brand); }
.ring { width: 44px; height: 44px; flex: none; }
.ring circle { fill: none; stroke: var(--line); stroke-width: 3.6; }
.ring .filled { stroke: var(--series-1); stroke-linecap: round; }
.ring text { fill: var(--ink); font-size: 11px; font-weight: 700; text-anchor: middle; }
.sk.ring { border-radius: 50%; }
.fold { border-top: 1px solid var(--line); }
.fold > summary, .none-due { display: flex; align-items: center; gap: 12px; min-height: 50px; padding: 0 6px; font-weight: 600; list-style: none; }
.fold > summary { cursor: pointer; border-radius: 6px; }
.fold > summary::-webkit-details-marker { display: none; }
.fold > summary:hover { background: var(--hover); }
.fold > summary > .ico { margin-left: auto; color: var(--ink-2); transition: transform .15s; }
.fold[open] > summary > .ico { transform: rotate(90deg); }
.mark { display: grid; place-items: center; width: 28px; height: 28px; flex: none; border-radius: 50%; background: var(--wash); color: var(--accent-text); font-size: 13px; font-weight: 700; }
.mark .ico { width: 16px; height: 16px; }
.fold-actions > summary .mark { background: var(--gold-fill); color: var(--on-gold); }
.todo { padding-left: 34px; }
.todo li { border-top: 1px solid var(--line); }
.todo button { display: flex; align-items: center; gap: 12px; width: 100%; padding: 10px 12px; border: 0; border-radius: 6px; background: none; text-align: left; transition: background-color .3s, box-shadow .3s; }
.todo button span { flex: 1; min-width: 0; }
.todo button .ico:first-child { color: var(--accent-text); width: 18px; height: 18px; }
.todo button .ico:last-child { color: var(--ink-2); opacity: .5; }
.todo button:hover .ico:last-child, .todo button:focus-visible .ico:last-child { color: var(--accent-text); opacity: 1; }
.todo li.flash button { background: var(--wash); box-shadow: inset 0 0 0 2px var(--brand); }
.prices { padding-bottom: 8px; }
.prices li { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) 98px; gap: 14px; align-items: center; padding: 6px 6px 6px 46px; }
.prices li span { overflow-wrap: anywhere; }
.prices li b { text-align: right; font-weight: 600; font-size: 13px; font-variant-numeric: tabular-nums; }
.gauge { display: block; position: relative; height: 8px; border-radius: 4px; background: var(--page); }
.gauge::after { content: ""; position: absolute; left: 50%; top: -3px; bottom: -3px; border-left: 2px solid var(--ink-2); }
.gauge i { position: absolute; top: 0; bottom: 0; background: var(--series-1); }
.prices li b .arrow { display: inline-block; width: 0; height: 0; margin-right: 5px; vertical-align: 1px; border-left: 4px solid transparent; border-right: 4px solid transparent; }
.prices li b .arrow.up { border-bottom: 6px solid var(--gap); }
.prices li b .arrow.down { border-top: 6px solid var(--good); }
.gauge i:not([style*="width:0%"]) { min-width: 3px; }
.nearby { padding-bottom: 8px; }
.nearby li { display: flex; justify-content: space-between; align-items: baseline; gap: 14px; padding: 5px 6px 5px 46px; }
.nearby b { font-weight: 600; font-size: 13px; white-space: nowrap; font-variant-numeric: tabular-nums; }
@media (max-width: 560px) {
  .perf.card { padding: 14px 12px; }
  .todo { padding-left: 0; }
  .prices li { padding-left: 6px; gap: 8px; }
  .nearby li { padding-left: 6px; }
  #fab { right: 20px; bottom: 20px; }
  .tile > span:first-child { padding-right: 0; }
}

/* the venue list: a heading row, then a line for each venue with its tile running the full height on the left */
.venue-heads, .venue-cells { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 2fr) minmax(0, 1fr); gap: 16px; }
.venue-heads { padding: 0 17px 6px 81px; font-size: 12px; color: var(--ink-2); }
.venue-list { display: grid; gap: 4px; }
.venue-row { display: flex; align-items: stretch; min-height: 64px; background: var(--control); border: 1px solid var(--line); border-radius: 9px; color: var(--ink); text-decoration: none; box-shadow: var(--lit); transition: background-color .15s, transform .08s; }
.venue-row:hover { background: var(--hover); }
.venue-row:active { transform: scale(.998); }
.venue-cells { flex: 1; min-width: 0; align-items: center; padding: 8px 16px; }
.venue-cells > * { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.venue-cells b { font-weight: 600; }
.venue-cells span { color: var(--ink-2); }
/* the photo, or the venue's letter on the brand colour, under the same glaze: a soft veil, a diagonal shine and a hairline */
.venue-icon { position: relative; display: grid; place-items: center; width: 64px; flex: none; align-self: stretch; border-radius: 8px 0 0 8px; background: var(--brand); color: #fff; font-size: 26px; font-weight: 600; }
.venue-icon img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; border-radius: inherit; }
.venue-icon::after { content: ""; position: absolute; inset: 0; border-radius: inherit; box-shadow: inset 0 0 0 1px rgb(255 255 255 / .19);
  background: linear-gradient(140deg, rgb(255 255 255 / .44) 0, rgb(255 255 255 / .11) 48%, rgb(255 255 255 / 0) 50%, rgb(0 0 0 / .19) 100%), rgb(255 255 255 / .1); }
@media (max-width: 760px) {
  .venue-heads { display: none; }
  .venue-cells { grid-template-columns: minmax(0, 1fr); gap: 0; }
}

/* tabs swiping, side by side with a little between them */
.tab-stage { position: relative; }
.tab-stage.swiping { overflow-x: clip; }
.tab-pane.leaving { position: absolute; top: 0; left: 0; width: 100%; pointer-events: none; }
.swiping > .tab-pane { animation-duration: .32s; animation-timing-function: cubic-bezier(.4, 0, .2, 1); animation-fill-mode: both; }
.swipe-forward > .entering { animation-name: from-right; }
.swipe-forward > .leaving { animation-name: to-left; }
.swipe-back > .entering { animation-name: from-left; }
.swipe-back > .leaving { animation-name: to-right; }
@keyframes from-right { from { opacity: 0; transform: translateX(calc(100% + 24px)); } to { opacity: 1; transform: none; } }
@keyframes from-left { from { opacity: 0; transform: translateX(calc(-100% - 24px)); } to { opacity: 1; transform: none; } }
@keyframes to-left { from { opacity: 1; transform: none; } to { opacity: 0; transform: translateX(calc(-100% - 24px)); } }
@keyframes to-right { from { opacity: 1; transform: none; } to { opacity: 0; transform: translateX(calc(100% + 24px)); } }

/* venue details */
.details { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-areas: "media reach" "hours reach"; grid-template-rows: auto 1fr; gap: 0 14px; align-items: start; color: var(--ink); }
.details > div { min-width: 0; }
.d-media { grid-area: media; } .d-hours { grid-area: hours; } .d-reach { grid-area: reach; }
.detail header { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 10px; }
.show-on { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--ink-2); }
.detail textarea, .detail > select { width: 100%; }
.fields { display: grid; gap: 10px; }
.fields label { display: grid; gap: 3px; font-size: 12px; color: var(--ink-2); }
.fields input { font-size: 14px; width: 100%; }
.fields small { display: block; overflow-wrap: anywhere; }
.fields small:empty { display: none; }
.photos { display: flex; flex-wrap: wrap; gap: 10px; }
.photos li { position: relative; width: 108px; height: 108px; }
.photos img, .photos .sk { width: 100%; height: 100%; object-fit: cover; border-radius: 10px; background-color: var(--bone); }
.photos li > button:not(.add-photo) { position: absolute; top: 5px; right: 5px; width: 28px; height: 28px; padding: 0; display: grid; place-items: center; border: 0; border-radius: 50%; background: rgb(0 0 0 / .6); color: #fff; }
.photos mark { position: absolute; left: 5px; bottom: 5px; background: var(--brand); color: #fff; }
.add-photo { width: 100%; height: 100%; display: grid; place-content: center; justify-items: center; gap: 6px; border-style: dashed; border-radius: 10px; color: var(--accent-text); font-size: 12px; }
.hours li { display: grid; grid-template-columns: 90px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 6px 0; border-top: 1px solid var(--line); }
.times { display: flex; align-items: center; justify-content: center; gap: 8px; min-width: 0; min-height: 36px; }
.times input { min-width: 0; padding: 5px 8px; }
.times i { font-style: normal; color: var(--ink-2); font-size: 12px; }
.times.closed { color: var(--ink-2); }
.links-list li { display: grid; grid-template-columns: 170px minmax(0, 1fr) 34px; gap: 6px; margin-bottom: 6px; }

/* analytics and insights figures: the name with its icon, the measure large, the rest quiet */
.tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.tiles > div, .facts > div { background: var(--card); border: 1px solid var(--line); border-radius: 8px; padding: 12px 14px; min-width: 0; }
.tiles span, .facts span { display: flex; align-items: center; gap: 8px; color: var(--ink-2); font-size: 12.5px; }
.tiles .ico, .facts .ico { width: 15px; height: 15px; color: var(--accent-text); }
.tiles b, .facts b { display: block; margin: 4px 0 2px; font-size: 28px; font-weight: 600; line-height: 1.3; }
.tiles small, .facts small { display: block; min-height: 18px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.panels { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 0 14px; align-items: start; }
.big { display: block; font-size: 28px; margin-top: 8px; }
.columns { display: flex; gap: 4px; margin-top: 12px; }
.col { flex: 1; min-width: 0; display: flex; flex-direction: column; text-align: center; }
.stem { height: var(--stem, 150px); display: flex; flex-direction: column; justify-content: flex-end; border-bottom: 1px solid var(--line); padding: 0 14%; }
.stem i { display: block; width: 100%; max-width: 30px; margin: 0 auto; border-radius: 4px 4px 0 0; background: var(--brand-hover); }
/* the trend lies over the stems: half a gap wider on each side, so its columns centre on theirs, and above the names */
.columns { position: relative; }
.trend { position: absolute; left: -2px; bottom: 23px; width: calc(100% + 4px); height: var(--stem, 150px); overflow: visible; pointer-events: none; }
.trend path { fill: none; stroke: var(--gold); stroke-width: 2.5; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.dense .trend { left: -.5px; width: calc(100% + 1px); }
.legend.key i { height: 3px; width: 18px; vertical-align: 3px; border-radius: 2px; background: var(--gold); }
.legend { display: flex; flex-wrap: wrap; gap: 16px; font-size: 12px; color: var(--ink-2); margin-top: 8px; }
.legend i { display: inline-block; width: 12px; height: 12px; border-radius: 3px; background: var(--brand-hover); margin-right: 5px; vertical-align: -1px; }

/* line charts */
.plot { --plot: 260px; display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: 10px; margin: 6px 0 0; }
.plot .legend { grid-column: 1 / -1; margin: 4px 0 6px; }
.plot .legend i { height: 3px; width: 18px; vertical-align: 3px; border-radius: 2px; }
.plot i.s1 { background: var(--series-1); }
.scale { grid-column: 1; position: relative; min-width: 3ch; height: var(--plot); margin-top: 26px; }
.scale span { position: absolute; right: 0; transform: translateY(-50%); font-size: 11px; color: var(--ink-2); font-variant-numeric: tabular-nums; }
.scale::after { content: "0000"; visibility: hidden; font-size: 11px; }
.field { grid-column: 2; position: relative; height: var(--plot); margin-top: 26px; }
.field svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.field path { fill: none; vector-effect: non-scaling-stroke; }
.field .grid { stroke: var(--line); stroke-width: 1; }
.field .wash { fill: var(--series-1); opacity: .1; }
.field .line { stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round; }
.field .line.s1 { stroke: var(--series-1); }
.slots { position: absolute; inset: 0; display: flex; }
.slot { position: relative; flex: 1; min-width: 0; padding: 0; border: 0; border-radius: 6px; background: transparent; }
.slot:hover:not(:disabled), .slot:focus-visible { background: color-mix(in srgb, var(--series-1) 9%, transparent); }
button.slot:active:not(:disabled) { transform: none; }
.slot[aria-pressed="true"] { background: color-mix(in srgb, var(--series-1) 16%, transparent); box-shadow: inset 0 -3px 0 var(--series-1); }
.slot::before { content: ""; position: absolute; top: 0; bottom: 0; left: 50%; border-left: 1px solid var(--ink-2); opacity: 0; }
.slot:hover::before, .slot:focus-visible::before { opacity: .45; }
.slot .dot { position: absolute; left: 50%; width: 10px; height: 10px; margin: -5px 0 0 -5px; border-radius: 50%; box-shadow: 0 0 0 2px var(--card); }
.slot > b { position: absolute; left: 50%; transform: translate(-50%, calc(-100% - 8px)); font-size: 12px; opacity: 0; }
.slot.marked > b { opacity: 1; }
.slot:hover > b, .slot:focus-visible > b { opacity: 0; }
.readout { position: absolute; z-index: 4; left: 50%; bottom: calc(100% + 4px); transform: translateX(-50%); display: none; gap: 2px; width: max-content; max-width: 260px; padding: 8px 10px; text-align: left; background: var(--control); border: 1px solid var(--line); border-radius: 8px; box-shadow: 0 8px 24px rgb(0 0 0 / .22); font-size: 12px; pointer-events: none; }
.slot:first-child .readout { left: 0; transform: none; } .slot:last-child .readout { left: auto; right: 0; transform: none; }
.slot:hover .readout, .slot:focus-visible .readout { display: grid; }
.readout span { color: var(--ink-2); } .readout span b { color: var(--ink); }
.readout i { display: inline-block; width: 12px; height: 3px; border-radius: 2px; margin-right: 6px; vertical-align: 3px; }
.names { grid-column: 2; display: flex; margin-top: 6px; }
.names span { flex: 1; min-width: 0; text-align: center; font-size: 12px; color: var(--ink-2); line-height: 1.3; }
/* the edges of the spans on a number or time axis */
.ticks { grid-column: 2; position: relative; height: 26px; margin: 0 0 2px; }
.ticks span { position: absolute; top: 8px; transform: translateX(-50%); font-size: 12px; color: var(--ink-2); white-space: nowrap; font-variant-numeric: tabular-nums; }
.ticks span::before { content: ""; position: absolute; left: 50%; top: -8px; height: 5px; border-left: 1px solid var(--ink-2); opacity: .6; }
.ticks span:first-child { transform: none; } .ticks span:first-child::before { left: 0; }
.ticks span:last-child { transform: translateX(-100%); } .ticks span:last-child::before { left: 100%; }
.view { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(560px, 100%), 1fr)); gap: 14px; align-items: stretch; margin-top: 14px; }
.view > .card { margin-top: 0; }
.view-venues { grid-template-columns: minmax(0, 1fr); }
/* line charts are indigo, with the median in gold */
.marker { position: absolute; top: 0; bottom: 0; border-left: 2px solid var(--gold); pointer-events: none; }
.marker span { position: absolute; left: -1px; bottom: calc(100% + 5px); transform: translateX(-50%); color: var(--gold-ink); font-size: 12px; font-weight: 700; white-space: nowrap; }

/* a card's title names it; the line under it says what the figures show, and stays quieter than the chart */
.insight h3 { font-size: 18px; font-weight: 700; letter-spacing: -.01em; }
.summary { color: var(--ink-2); font-size: 13px; line-height: 1.5; margin: 2px 0 14px; max-width: 900px; }
.hint { color: var(--ink-2); font-size: 12px; margin-top: 12px; opacity: .85; }
.insight .actions { margin-top: 0; }
.insight .plot { margin-top: 0; }
.insight .bar-list { margin-top: 0; }

/* venue types */
.type-split { display: grid; grid-template-columns: minmax(220px, 340px) minmax(0, 1fr); gap: 40px; align-items: center; }
.pie { width: 100%; max-width: 340px; justify-self: center; }
.pie .slice { stroke: var(--card); stroke-width: .026; stroke-linejoin: round; }
.pie .slice:hover { opacity: .85; }
.pie text { fill: #fff; font-size: .11px; font-weight: 700; text-anchor: middle; dominant-baseline: central; pointer-events: none; paint-order: stroke; stroke: rgb(0 0 0 / .45); stroke-width: .02; }
.pie .slice, .swatch { --colour: color-mix(in oklab, var(--pie-from), var(--pie-to) calc(var(--step, 0) * 100%)); fill: var(--colour); background: var(--colour); }
.swatch { display: inline-block; width: 12px; height: 12px; flex: none; border-radius: 3px; }
.pie text.pale { fill: #1a1a1a; stroke: none; }
.types-table .check { display: flex; align-items: center; gap: 10px; cursor: pointer; }
.types-table tr.off td, .types-table tr.off th { color: var(--ink-2); }
.types-table tr.off .swatch { opacity: .3; }
.types-table td, .discount-table td { font-variant-numeric: tabular-nums; }

/* discounts */
.discount-table th[scope="row"] { min-width: 130px; }
.discount-table td { white-space: nowrap; }
.discount-table td small { display: block; }
.discount-table .track { display: block; margin-top: 5px; }
.discount-table .track i { height: 6px; background: var(--series-1); }
.mix { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line); font-size: 13px; color: var(--ink-2); }
.bar-list { margin-top: 8px; }
.bar-row { display: grid; grid-template-columns: minmax(96px, 26%) minmax(0, 1fr) minmax(90px, auto); gap: 10px; align-items: center; width: 100%; text-align: left; background: none; border: 0; border-top: 1px solid var(--line); border-radius: 0; padding: 9px 4px; }
button.bar-row:hover:not(:disabled), .bar-row.on { background: var(--wash); }
.bar-row .value { text-align: right; font-weight: 600; } .bar-row .value small { display: block; font-weight: 400; }
.name { height: 18px; margin-top: 5px; font-size: 11px; color: var(--ink-2); white-space: nowrap; display: flex; justify-content: center; }
.columns.dense { gap: 1px; } .dense b { display: none; } .dense .stem { padding: 0 8%; }
.bars { margin-top: 8px; }
.bars li { display: grid; grid-template-columns: 70px minmax(0, 1fr) 44px; gap: 10px; align-items: center; padding: 7px 0; border-top: 1px solid var(--line); }
.bars b { text-align: right; }
.track i { display: block; height: 10px; border-radius: 3px; background: var(--brand-hover); }
.table { overflow-x: auto; margin-top: 10px; }
table { width: 100%; border-collapse: collapse; }
th, td { padding: 8px 10px; border-top: 1px solid var(--line); text-align: center; }
thead th { font-size: 12px; font-weight: 600; color: var(--ink-2); border-top: 0; }
th:first-child { text-align: left; }
tbody th { font-weight: 600; }

/* filters: a row of pick lists on the page, each saying what it holds */
.filters { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.filters select, .chooser { height: 34px; max-width: 200px; }
.filters #q-area { max-width: 240px; }
.filters #q-category { width: 180px; }
.filters + .results > .tiles, .filters + .skeleton { margin-top: 14px; }
.filters .clear { height: 34px; white-space: nowrap; }
.filters + .results { margin-top: 0; }
/* a filter that is narrowing the search */
.filters select.applied, .chooser.applied { background: var(--wash); border-color: var(--brand); }
.filters select.applied :is(option, optgroup) { background: var(--control); color: var(--ink); }
.type-filter { position: relative; min-width: 0; }
.chooser { display: flex; justify-content: space-between; align-items: center; gap: 8px; text-align: left; font-size: 14px; color: var(--ink); overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.chooser::after { content: ""; width: 7px; height: 7px; flex: none; border: solid var(--ink-2); border-width: 0 1.5px 1.5px 0; transform: translateY(-2px) rotate(45deg); }
.type-menu { position: absolute; z-index: 12; top: calc(100% + 4px); left: 0; min-width: max(100%, 250px); display: grid; gap: 2px; padding: 8px; background: var(--card); border: 1px solid var(--line); border-radius: 8px; box-shadow: 0 12px 30px rgb(0 0 0 / .3); }
.type-menu > div { display: flex; align-items: center; gap: 14px; }
.type-menu .check { display: flex; flex-direction: row; flex: 1; align-items: center; gap: 8px; padding: 4px 2px; font-size: 14px; color: var(--ink); cursor: pointer; }
.type-menu .check small { margin-left: auto; }
.type-menu .link { font-size: 12px; }
.type-menu > .link { justify-self: start; border-top: 1px solid var(--line); border-radius: 0; width: 100%; text-align: left; padding: 8px 2px 2px; }
.results { transition: opacity .2s; }
.results.refreshing { opacity: .55; }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(200px, 100%), 1fr)); gap: 12px; margin-top: 14px; }
.facts.inside > div { border: 0; border-top: 1px solid var(--line); border-radius: 0; background: none; padding-left: 0; }
.segmented.views { margin-top: 20px; }
.definitions { margin-top: 24px; }
.definitions summary { cursor: pointer; color: var(--accent-text); }
.definitions ul { list-style: disc; padding-left: 20px; margin-top: 8px; color: var(--ink-2); }

/* account and settings: one column, a small label over each rounded group of rows */
.column { max-width: 820px; display: grid; gap: 8px; }
.section-label { margin: 14px 4px 0; font-size: 14px; font-weight: 600; color: var(--ink-2); }
.group { background: var(--card); border: 1px solid var(--line); border-radius: 8px; min-width: 0; }
.set-row { position: relative; display: grid; grid-template-columns: 28px minmax(0, 1fr) auto; gap: 16px; align-items: center; min-height: 58px; padding: 10px 16px; color: var(--ink); text-decoration: none; }
.set-row + .set-row::before { content: ""; position: absolute; top: 0; left: 60px; right: 0; border-top: 1px solid var(--line); }
a.set-row:hover { background: var(--hover); }
.set-row > .ico { width: 18px; height: 18px; justify-self: center; color: var(--ink-2); }
a.set-row > .ico:last-child { width: 14px; height: 14px; }
.set-row > div { display: grid; min-width: 0; }
.set-row b { font-weight: 400; overflow-wrap: anywhere; }
.set-value { color: var(--ink-2); text-align: right; }
.note { margin: 2px 4px 0; font-size: 12px; color: var(--ink-2); }
.identity { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 16px; align-items: start; padding: 16px; }
.identity h2 { overflow-wrap: anywhere; }
.identity .meta { margin: 0 0 6px; }
.account-status { display: flex; flex-wrap: wrap; gap: 8px; }
.account-status span { color: var(--ink-2); }
.avatar { width: 56px; height: 56px; flex: none; border-radius: 50%; background: var(--brand); color: #fff; display: grid; place-items: center; font-size: 24px; font-weight: 600; }
.plan-card { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 16px; padding: 14px 16px; }
.plan-card .button { min-width: 160px; }
.tier { padding: 14px 16px; border-width: 2px; }
.tier.current { border-color: var(--brand); }
.tier header { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.tier .price { margin-left: auto; color: var(--ink-2); }
.tier ul { margin-top: 10px; display: grid; gap: 4px; }
.tier li { display: flex; gap: 8px; align-items: flex-start; }
.tier li .ico { margin-top: 3px; color: var(--accent-text); }
.tier { display: block; }
.tier.choose { cursor: pointer; }
.tier.choose:hover { background: var(--hover); }
.tier.choose:has(input:checked) { border-color: var(--accent-text); }
.tier input { width: auto; margin: 0; accent-color: var(--brand); }
.confirm-plan { display: flex; justify-content: flex-end; }
.confirm-plan button { min-width: 160px; }
.link-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.switch { width: 44px; height: 24px; flex: none; border-radius: 12px; padding: 2px; background: var(--bone); }
.switch span { display: block; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgb(0 0 0 / .35); transition: transform .18s; }
.switch[aria-checked="true"], .switch[aria-checked="true"]:hover:not(:disabled) { background: var(--brand); border-color: var(--brand); }
.switch[aria-checked="true"] span { transform: translateX(20px); }
.explainer { display: flex; gap: 12px; margin-top: 12px; background: var(--wash); border-radius: 8px; padding: 12px 14px; font-size: 13px; }
.explainer b { display: block; }
.danger-button, .danger-button:hover:not(:disabled) { background: var(--error-wash); color: var(--error); border-color: var(--error); font-weight: 600; }
@media (max-width: 560px) {
  .set-row { grid-template-columns: 24px minmax(0, 1fr); }
  .set-row > button, .set-row > a.button, .set-row > select, .set-row > .set-value, .set-row > .segmented { grid-column: 2; justify-self: start; text-align: left; }
  .set-row > .switch { grid-column: 2; }
  a.set-row { grid-template-columns: 24px minmax(0, 1fr) auto; }
}

/* shared by settings, venues and cards */
dl { margin: 10px 0 14px; }
dl > div { display: grid; grid-template-columns: 160px minmax(0, 1fr); gap: 12px; padding: 7px 0; border-top: 1px solid var(--line); }
dt { color: var(--ink-2); }
dd { overflow-wrap: anywhere; }

/* sign in */
body.guest .titlebar { position: fixed; z-index: 20; right: 0; top: 0; height: var(--bar); background: none; box-shadow: none; }
body.guest .titlebar img, body.guest .titlebar span { display: none; }
#signin { grid-column: 1 / -1; grid-row: 1 / -1; display: grid; place-items: center; padding: 32px 16px; background: radial-gradient(900px 500px at 50% -10%, var(--wash), transparent 70%), var(--page); font-family: 'Inter', 'Segoe UI', system-ui, sans-serif; }
.signin-wrap { width: min(420px, 100%); animation: rise .45s ease both; }
.signin-wrap header { display: grid; justify-items: center; text-align: center; gap: 4px; margin-bottom: 20px; }
.signin-wrap header h1 { font-size: 30px; font-weight: 800; letter-spacing: -.02em; }
.signin-wrap header p { color: var(--ink-2); }
.signin-card { background: var(--card); border: 1px solid var(--line); border-radius: 18px; padding: 24px; box-shadow: 0 10px 40px rgb(15 15 26 / .12); transition: opacity .2s; }
.signin-card.working { opacity: .6; pointer-events: none; }
.signin-card form { display: grid; gap: 12px; }
.signin-card label { display: grid; gap: 4px; font-size: 13px; color: var(--ink-2); }
.signin-card input { border-radius: 10px; padding: 10px 12px; }
.signin-card label.check { display: flex; align-items: center; gap: 8px; color: var(--ink); }
.signin-card form > .primary { border-radius: 24px; padding: 11px; }
.signin-card h2 { margin-bottom: 14px; }
.social { display: grid; gap: 10px; justify-items: center; }
.google { width: 100%; min-height: 40px; display: grid; justify-items: center; }
/* Google's button is a frame of its own. A frame whose colour scheme differs from the page's is painted on an opaque
   white sheet, which shows around the rounded corners on the dark theme, so the frame keeps the light scheme */
.google iframe { color-scheme: light; }
.sk-button { width: 100%; height: 40px; border-radius: 20px; }
.apple { width: 100%; max-width: 400px; height: 40px; display: flex; align-items: center; justify-content: center; gap: 8px; border-radius: 20px; background: #000; color: #fff; border-color: #000; font-weight: 600; }
.apple:hover:not(:disabled) { background: #222; }
.apple svg { width: 18px; height: 18px; }
.or { display: flex; align-items: center; gap: 12px; color: var(--ink-2); font-size: 12px; margin: 14px 0; }
.or::before, .or::after { content: ''; flex: 1; border-top: 1px solid var(--line); }
.links { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.signin-wrap footer { display: flex; justify-content: center; flex-wrap: wrap; gap: 18px; margin-top: 18px; }
.signin-wrap footer a { color: var(--ink-2); font-size: 13px; text-decoration: none; }

/* skeletons: placeholders in the shape of what is coming */
.sk { display: block; background: linear-gradient(100deg, transparent 20%, var(--sheen) 45%, transparent 70%) var(--bone); background-size: 220% 100%; border-radius: 6px; }
/* placeholders shimmer on arriving at a page and where something is being fetched for the first time on the map or sent
   from this page; elsewhere they hold still, and stay unseen unless the wait is long enough to need them */
.arriving .sk, .strip .sk, .photos .sk { animation: shimmer 1.3s linear infinite; }
#page:not(.arriving) .skeleton { animation: fade 0s .25s both; }
.sk-line { height: 12px; margin: 8px 0; max-width: 100%; }
.sk-figure { height: 26px; width: 45%; margin: 6px 0; }
.sk-block { height: 64px; margin-top: 10px; border-radius: 10px; }
.sk-row { display: flex; justify-content: space-between; gap: 12px; border-top: 1px solid var(--line); padding: 4px 0; }
.sk-row .sk-line:first-child { flex: 0 1 auto; } .sk-row .sk-line { min-width: 60px; }
.sk-title { width: 180px; height: 22px; }
.sk-nav { width: 280px; max-width: 100%; height: 34px; }
.sk-tile { height: 62px; }
.sk-columns { display: flex; gap: 8px; align-items: flex-end; height: 150px; margin-top: 12px; }
.sk-columns span { flex: 1; }
.sk-ph { width: 64px; height: 64px; flex: none; border-radius: 14px; }
.sk-fill { flex: 1; }

/* motion: what is new rises into place; charts grow */
#page.enter > * { animation: rise .38s ease both; }
#page.enter > :nth-child(2) { animation-delay: .04s; }
#page.enter > :nth-child(3) { animation-delay: .08s; }
#page.enter > :nth-child(n+4) { animation-delay: .12s; }
#page.enter .tiles > div, #page.enter .board > section, #page.enter .facts > div { animation: rise .4s ease both; }
#page.enter .tiles > :nth-child(2n), #page.enter .board > :nth-child(2n), #page.enter .facts > :nth-child(2) { animation-delay: .07s; }
#page.enter .tiles > :nth-child(3n), #page.enter .board > :nth-child(3n), #page.enter .facts > :nth-child(3) { animation-delay: .12s; }
/* charts draw themselves when a page is reached, and again each time their figures are refreshed */
#page.enter .stem i, .results.fresh .stem i { transform-origin: bottom; animation: grow .55s cubic-bezier(.2, .7, .3, 1) both .12s; }
#page.enter :is(.curves, .trend), .results.fresh :is(.curves, .trend) { animation: wipe .7s cubic-bezier(.3, .6, .3, 1) both .12s; }
#page.enter .track i, .results.fresh .track i { transform-origin: left; animation: stretch .55s cubic-bezier(.2, .7, .3, 1) both .12s; }
/* a pie sweeps round from the top; points, their figures and the median follow the line */
#page.enter .pie, .results.fresh .pie { mask-image: conic-gradient(#000 var(--sweep), transparent 0); animation: sweep .7s cubic-bezier(.3, .6, .3, 1) both .12s; }
#page.enter :is(.marker, .slot .dot, .slot.marked > b), .results.fresh :is(.marker, .slot .dot, .slot.marked > b) { animation: fade .3s .6s backwards; }
@property --sweep { syntax: '<angle>'; inherits: false; initial-value: 360deg; }
@keyframes sweep { from { --sweep: 0deg; } to { --sweep: 360deg; } }
dialog[open] { animation: pop .22s ease both; }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes pop { from { opacity: 0; transform: scale(.97); } to { opacity: 1; transform: none; } }
@keyframes grow { from { transform: scaleY(0); } to { transform: scaleY(1); } }
@keyframes wipe { from { clip-path: inset(-10% 100% -10% 0); } to { clip-path: inset(-10% 0 -10% 0); } }
@keyframes stretch { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@keyframes shimmer { from { background-position: 180% 0; } to { background-position: -60% 0; } }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-delay: 0s !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
}

/* dialogs */
dialog { width: min(520px, calc(100vw - 24px)); max-height: calc(100vh - 24px); border: 1px solid var(--line); border-radius: 10px; background: var(--card); color: var(--ink); padding: 22px 24px; }
dialog::backdrop { background: rgb(0 0 0 / .5); }
dialog form { display: grid; gap: 12px; }
dialog label, fieldset { display: grid; gap: 4px; font-size: 13px; color: var(--ink-2); min-width: 0; }
fieldset { border: 0; padding: 0; margin: 0; }
legend { padding: 0; margin-bottom: 4px; }
dialog label > input, dialog label > select, dialog label > textarea { width: 100%; font-size: 14px; }
textarea { resize: vertical; }
dialog label.check { display: flex; align-items: center; gap: 8px; color: var(--ink); }
.check input { width: auto; accent-color: var(--brand); }
.pair { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chips button { padding: 4px 10px; font-size: 13px; }
.chips button[aria-pressed="true"]:disabled { opacity: .75; }
.item { display: grid; grid-template-columns: minmax(0, 1fr) 110px 34px; gap: 6px; margin-bottom: 6px; }
[data-add-item] { justify-self: start; }
.actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
dialog [data-error]:empty { display: none; }
dialog .infobar { margin: 0; }

@media (max-width: 1100px) {
  .board { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 980px) {
  .type-split { grid-template-columns: minmax(0, 1fr); }
  .details { grid-template-columns: minmax(0, 1fr); grid-template-areas: "media" "hours" "reach"; grid-template-rows: none; }
}
@media (max-width: 760px) {
  .panels { grid-template-columns: minmax(0, 1fr); }
  .tiles { grid-template-columns: 1fr 1fr; }
  #page { padding: 4px 12px 32px; }
}
@media (max-width: 560px) {
  .board { grid-template-columns: 1fr 1fr; }
  .board section { min-height: 0; }
  dl > div { grid-template-columns: 1fr; gap: 0; }
    .type-split { grid-template-columns: minmax(0, 1fr); }
  /* the venue type list opens in the right hand column, so it hangs from that side */
  .type-menu { left: auto; right: 0; }
  .discount-table th, .discount-table td { padding-left: 4px; padding-right: 4px; font-size: 13px; }
  .discount-table th[scope="row"] { min-width: 0; }
  .bar-row { grid-template-columns: minmax(84px, 34%) minmax(0, 1fr) minmax(70px, auto); gap: 6px; }
  .hours li { grid-template-columns: minmax(0, 1fr) auto; }
  .hours .times { grid-row: 2; grid-column: 1 / -1; justify-content: flex-start; }
  .links-list li { grid-template-columns: minmax(0, 1fr) 34px; }
  .links-list select { grid-column: 1 / -1; }
}

/* wide screens, 1920 by 1080 being the usual one */
@media (min-width: 1500px) {
  :root { --bar: 66px; }
  body { grid-template-columns: 248px minmax(0, 1fr); font-size: 15.5px; }
  small { font-size: 13px; }
  h1 { font-size: 32px; } h2 { font-size: 23px; } h3 { font-size: 18px; }
  .insight h3 { font-size: 21px; }
  .summary { font-size: 14px; }
  #page { padding: 22px 36px 48px; }
  .nav { min-height: 46px; font-size: 15.5px; }
  .nav .ico { width: 19px; height: 19px; }
  .card { padding: 22px 26px; }
  .pivot a { font-size: 22px; }
  .tiles b, .facts b { font-size: 32px; }
  .tiles span, .facts span { font-size: 13.5px; }
  .panels { grid-template-columns: minmax(0, 3fr) minmax(0, 1fr); }
  .columns { --stem: 300px; }
  .name { font-size: 12.5px; }
  .board { gap: 12px; }
  .board section { min-height: 360px; padding: 12px; gap: 8px; }
  .board h3 { font-size: 14px; }
  .tile { padding: 12px 8px; }
  .tile span { font-size: 15px; }
  .plot { --plot: 340px; }
  .scale span, .names span, .ticks span, .slot > b, .readout { font-size: 13px; }
  .view-price { grid-template-columns: minmax(0, 2.6fr) minmax(0, 1fr); }
  .details { grid-template-columns: repeat(3, minmax(0, 1fr)); grid-template-areas: "media hours reach"; grid-template-rows: auto; }
}
