/* Covers: shared tokens, type and the plan drawing.
   One metaphor all the way through: the architect's floor plan.
   Poché walls, hairlines, dimension ticks, revision clouds for alerts. */

@font-face { font-family: 'Archivo'; src: url('../../fonts/Archivo-var.woff2') format('woff2'); font-weight: 100 900; font-stretch: 62% 125%; font-display: swap; }
@font-face { font-family: 'Geist'; src: url('../../fonts/Geist-var.woff2') format('woff2'); font-weight: 100 900; font-display: swap; }
@font-face { font-family: 'JetBrains Mono'; src: url('../../fonts/jetbrains-mono-latin-400-normal.woff2') format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'JetBrains Mono'; src: url('../../fonts/jetbrains-mono-latin-500-normal.woff2') format('woff2'); font-weight: 500 700; font-display: swap; }

:root {
  --paper: #f1eee7;
  --paper-2: #e9e5dc;
  --card: #f7f5f0;
  --ink: #171614;
  --ink-2: #4e4a43;
  --ink-3: #8b857a;
  --rule: rgba(23, 22, 20, .17);
  --rule-2: rgba(23, 22, 20, .075);
  --free: #2e7650;
  --free-tint: #d3e3d1;
  --free-ink: #f4f1ea;
  --seated: #bd3f2b;
  --seated-tint: #f2d8ce;
  --seated-ink: #9a301f;
  --clear: #b07f18;
  --clear-tint: #f1e2bd;
  --markup: #c8361f;
  --display: 'Archivo', 'Arial Narrow', 'Helvetica Neue', sans-serif;
  --text: 'Geist', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, 'SFMono-Regular', Consolas, monospace;
  --ease: cubic-bezier(.215, .61, .355, 1);
  --ease-out: cubic-bezier(.165, .84, .44, 1);
  --ease-io: cubic-bezier(.77, 0, .175, 1);
  --ease-back: cubic-bezier(.34, 1.56, .64, 1);
  color-scheme: light;
}

/* service lighting: the host stand at 9pm */
.night, [data-theme='night'] {
  --paper: #121210;
  --paper-2: #1a1916;
  --card: #1d1c19;
  --ink: #ece7dc;
  --ink-2: #b4ad9f;
  --ink-3: #7c766b;
  --rule: rgba(236, 231, 220, .16);
  --rule-2: rgba(236, 231, 220, .07);
  --free: #5fae7f;
  --free-tint: #1d3528;
  --free-ink: #0f1a13;
  --seated: #e0654c;
  --seated-tint: #3d1d16;
  --seated-ink: #f19a86;
  --clear: #ddb04f;
  --clear-tint: #3a2e15;
  --markup: #ff6a4d;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font-family: var(--text); font-size: 16px; line-height: 1.45; font-weight: 400;
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; text-rendering: optimizeLegibility;
}
::selection { background: var(--ink); color: var(--paper); }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; letter-spacing: inherit; }
h1, h2, h3, h4, p, ol, ul, figure, dl, dd { margin: 0; padding: 0; }
ol, ul { list-style: none; }
img, svg { display: block; }
:focus-visible { outline: 2px solid var(--markup); outline-offset: 3px; }

.mono { font-family: var(--mono); font-size: 11px; line-height: 1.3; letter-spacing: .08em; text-transform: uppercase; font-weight: 400; }
.tnum { font-variant-numeric: tabular-nums; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- buttons: squared, ruled, no pills ---------- */
.btn {
  --h: 48px;
  display: inline-flex; align-items: center; justify-content: space-between; gap: 22px;
  height: var(--h); padding: 0 18px; border-radius: 2px;
  font-family: var(--text); font-weight: 500; font-size: 15px; letter-spacing: -.005em; white-space: nowrap;
  transition: background-color .3s var(--ease), color .3s var(--ease), border-color .3s var(--ease);
}
.btn .arr { display: inline-block; font-family: var(--mono); transition: transform .4s var(--ease-out); }
.btn:hover .arr { transform: translateX(4px); }
.btn-ink { background: var(--ink); color: var(--paper); }
.btn-ink:hover { background: var(--seated); color: #fff; }
.btn-line { border: 1px solid var(--ink); }
.btn-line:hover { background: var(--ink); color: var(--paper); }
.btn-sm { --h: 36px; font-size: 13px; padding: 0 14px; gap: 14px; }

.dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--free); vertical-align: 1px; }
.dot.live { animation: live 2.4s var(--ease) infinite; }
@keyframes live { 0%, 100% { opacity: 1; } 50% { opacity: .25; } }

/* ---------- plan ---------- */
.plan { display: block; width: 100%; height: auto; overflow: hidden; user-select: none; -webkit-user-select: none; }
.plan text { font-family: var(--mono); fill: var(--ink-3); }
.plan .grid path { fill: none; stroke: var(--rule); stroke-width: 1; stroke-dasharray: 16 5 2 5; vector-effect: non-scaling-stroke; }
.plan .bub circle { fill: var(--paper); stroke: var(--ink-2); stroke-width: 1; vector-effect: non-scaling-stroke; }
.plan .bub text { font-size: 13px; font-weight: 500; text-anchor: middle; fill: var(--ink); }
.plan .deck path { stroke: var(--rule-2); stroke-width: 1; vector-effect: non-scaling-stroke; }
.plan .tree .canopy { fill: var(--paper); fill-opacity: .55; stroke: var(--ink-3); stroke-width: 1; vector-effect: non-scaling-stroke; }
.plan .tree .branches { fill: none; stroke: var(--ink-3); stroke-width: 1; vector-effect: non-scaling-stroke; stroke-dasharray: 2 3; }
.plan .tree .trunk { fill: var(--ink-3); }
.plan .fov path { fill: var(--ink); fill-opacity: .03; stroke: var(--ink); stroke-opacity: .16; stroke-width: 1; stroke-dasharray: 3 4; vector-effect: non-scaling-stroke; }
.plan .kitchen { fill: var(--khatch); }
.plan .khl { stroke: var(--rule); stroke-width: 1; }
.plan .fx rect, .plan .fx circle, .plan .fx path { fill: var(--paper); stroke: var(--ink-2); stroke-width: 1; vector-effect: non-scaling-stroke; }
.plan .fx .thin { fill: none; stroke: var(--rule); }
.plan .shrubs circle { fill: none; stroke: var(--ink-3); stroke-width: 1; vector-effect: non-scaling-stroke; stroke-dasharray: 2 2; }
.plan .wall rect { fill: var(--ink); }
.plan .glaze path { fill: none; stroke: var(--ink-2); stroke-width: 1; vector-effect: non-scaling-stroke; }
.plan .door path { fill: none; stroke: var(--ink-2); stroke-width: 1; vector-effect: non-scaling-stroke; }
.plan .door .swing { stroke-dasharray: 3 3; stroke: var(--ink-3); }
.plan .rail path { fill: none; stroke: var(--ink-2); stroke-width: 1; vector-effect: non-scaling-stroke; }
.plan .lbl .room { font-size: 13px; letter-spacing: .22em; text-anchor: middle; fill: var(--ink-2); font-weight: 500; }
.plan .lbl .sub { font-size: 10.5px; letter-spacing: .04em; text-anchor: middle; fill: var(--ink-3); }
.plan .lbl .tiny { font-size: 10px; letter-spacing: .16em; text-anchor: middle; fill: var(--ink-3); }
.plan .bench circle { fill: var(--ink); }
.plan .bench text { font-size: 11px; fill: var(--ink-2); }
.plan .dim path { fill: none; stroke: var(--ink-2); stroke-width: 1; vector-effect: non-scaling-stroke; }
.plan .dim .ext { stroke: var(--rule); }
.plan .dim text { font-size: 12px; text-anchor: middle; fill: var(--ink-2); letter-spacing: .04em; }
.plan .north circle { fill: none; stroke: var(--ink-2); stroke-width: 1; vector-effect: non-scaling-stroke; }
.plan .north path { fill: var(--ink); }
.plan .north text { font-size: 12px; text-anchor: middle; fill: var(--ink); font-weight: 500; }
.plan .cam rect, .plan .cam path { fill: var(--ink); }
.plan .cam text { font-size: 11px; fill: var(--ink-2); font-weight: 500; }

/* tables */
.plan .tb { outline: none; transition: opacity .45s var(--ease); }
.plan .tb .hit { fill: transparent; }
.plan .tb .seat { fill: var(--paper); stroke: var(--ink-2); stroke-width: 1; vector-effect: non-scaling-stroke; }
.plan .tb .pp { fill: var(--ink); transform: scale(0); transform-box: fill-box; transform-origin: center; transition: transform .55s var(--ease-back); }
.plan .tb .ch.on .pp { transform: scale(1); }
.plan .tb .ch:nth-child(3) .pp { transition-delay: .05s; } .plan .tb .ch:nth-child(4) .pp { transition-delay: .1s; }
.plan .tb .ch:nth-child(5) .pp { transition-delay: .15s; } .plan .tb .ch:nth-child(6) .pp { transition-delay: .2s; }
.plan .tb .top { stroke-width: 1.4; vector-effect: non-scaling-stroke; transition: fill .7s var(--ease), stroke .7s var(--ease); }
.plan .tb[data-s='free'] .top { fill: var(--free); stroke: var(--free); }
.plan .tb[data-s='seated'] .top { fill: var(--seated-tint); stroke: var(--seated); }
.plan .tb[data-s='clear'] .top { fill: var(--hatch); stroke: var(--clear); stroke-dasharray: 4 3; }
.plan .hb { fill: var(--clear-tint); }
.plan .hl { stroke: var(--clear); stroke-width: 1.5; }
.plan .tb text { text-anchor: middle; font-weight: 500; letter-spacing: 0; transition: fill .5s var(--ease); }
.plan .tb .num { fill: var(--ink-2); }
.plan .tb[data-s='free'] .num { fill: var(--free-ink); transform: translateY(4px); font-weight: 500; }
.plan .tb[data-s='seated'] .num { fill: var(--seated-ink); opacity: .7; }
.plan .tb .tm { fill: var(--seated-ink); }
.plan .tb[data-s='clear'] .num, .plan .tb[data-s='clear'] .tm { fill: var(--ink); paint-order: stroke; stroke: var(--clear-tint); stroke-width: 3px; stroke-linejoin: round; }
.plan .pl { opacity: 0; transition: opacity .5s var(--ease); }
.plan .pl.on { opacity: 1; }
.plan .pl circle { fill: var(--card); stroke: var(--ink-2); stroke-width: 1; vector-effect: non-scaling-stroke; }
.plan .pl circle:nth-child(2) { fill: none; stroke: var(--ink-3); }
.plan .pl .gl { fill: none; stroke: var(--ink-3); }
/* revision clouds only exist while a table is in alert: nothing hidden to paint, and the cloud draws itself in each time */
.plan .cloud { pointer-events: none; display: none; }
.plan .tb.alert .cloud { display: inline; }
.plan .cloud > path { fill: none; stroke: var(--markup); stroke-width: 2.2; stroke-linejoin: round; stroke-dasharray: 1; animation: cloud-draw 1.2s var(--ease-out) both; }
.plan .delta { transform-box: fill-box; transform-origin: center; animation: delta-pop .5s var(--ease-back) .7s both; }
@keyframes cloud-draw { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }
@keyframes delta-pop { from { opacity: 0; transform: scale(.4); } }
.plan .delta path { fill: var(--markup); }
.plan .delta text { fill: #fff !important; font-weight: 500; }
.plan .selring { fill: none; stroke: var(--ink); stroke-width: 2.5; opacity: 0; transition: opacity .3s var(--ease); }
.plan .tb.sel .selring { opacity: 1; }
.plan.is-dim .tb { opacity: .14; }
.plan[data-hl='free'] .tb[data-s='free'], .plan[data-hl='seated'] .tb[data-s='seated'], .plan[data-hl='clear'] .tb[data-s='clear'], .plan[data-hl='alert'] .tb.alert { opacity: 1; }
.plan[data-zone='indoor'] .tb:not([data-zone='indoor']), .plan[data-zone='bar'] .tb:not([data-zone='bar']), .plan[data-zone='terrace'] .tb:not([data-zone='terrace']) { opacity: .16; }
.plan.is-click .tb { cursor: pointer; }
.plan .tb:focus-visible .selring { opacity: 1; stroke: var(--markup); }
@media (hover: hover) { .plan.is-click .tb:hover .top { stroke-width: 2.6; } }

/* swatches used in legends and schedules */
.sw { display: inline-block; width: 14px; height: 14px; border: 1.4px solid; flex: none; }
.sw-free { background: var(--free); border-color: var(--free); }
.sw-seated { background: var(--seated-tint); border-color: var(--seated); }
.sw-clear { border-color: var(--clear); border-style: dashed; background: repeating-linear-gradient(-45deg, var(--clear) 0 1.5px, var(--clear-tint) 1.5px 5px); }
.sw-alert { width: 16px; height: 14px; border: 0; background: var(--markup); clip-path: polygon(50% 0, 100% 100%, 0 100%); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001s !important; animation-iteration-count: 1 !important; transition-duration: .001s !important; transition-delay: 0s !important; scroll-behavior: auto !important; }
}
