/* Atlas Portal: frosted glass over a blurred room at 92 Jefferson Lane, by day in light mode and at night in dark
   mode (assets/backdrop-*.jpg: the photo tour's living-day and living-night, 1280 wide, already blurred, so nothing
   has to blur them live). Site Atlas orange accent.
   Inter is served by the Portal itself (vendor/, SIL Open Font License). */
@font-face { font-family: Inter; font-style: normal; font-weight: 100 900; font-display: swap; src: url("../vendor/inter-latin-wght-normal.woff2") format("woff2"); }

:root {
  --ink: #221c17;
  --ink-2: #3d352e;
  --ink-3: #4a423b;
  --accent: #e6a756;
  --accent-2: #d98f3c;
  --accent-deep: #7a4410;
  --accent-ink: #2a1806;
  --hot: linear-gradient(155deg, #f3c27f, #dc9342);
  --window: rgba(255, 250, 243, .24);
  --bar: rgba(255, 251, 246, .62);
  --card: rgba(255, 252, 247, .66);
  --card-2: rgba(255, 252, 247, .74);
  --pop: rgba(253, 250, 245, .9);
  --edge: rgba(255, 255, 255, .62);
  --line: rgba(70, 50, 30, .12);
  --track: rgba(70, 50, 30, .12);
  --solid-window: #efe8df;
  --solid-bar: #f6f1ea;
  --r-window: 34px;
  --r-card: 24px;
  --r-tile: 18px;
  --blur: 30px;
  --sat: 150%;
  --shadow-window: 0 30px 80px rgba(52, 34, 18, .22);
  --shadow-card: inset 0 1px 0 rgba(255, 255, 255, .75), 0 1px 2px rgba(64, 42, 20, .05), 0 16px 40px rgba(64, 42, 20, .13);
  --shadow-pill: 0 10px 30px rgba(64, 42, 20, .16);
  --ease: cubic-bezier(.2, .7, .2, 1);
  --rail-w: 60px;
  --win-left: 100px;
  --win-top: 100px;
  --peek: 140px;
  /* chart series (validated: lightness, chroma, colour-blind separation, contrast) */
  --drone: #b9691f;
  --laser: #2a6fc9;
  /* surfaces that flip in night mode */
  --hi: #fff;
  --hi-hover: #fffaf3;
  --w: 255 255 255;
  --wk: 1;
  --ink-rgb: 70 50 30;
  --pop-glass: rgba(255, 251, 246, .82);
  --panel: rgba(252, 248, 242, .9);
  --map-bg: #efe8dd;
  --backdrop: #d8c7b0;
  --on-room: 0 0 16px rgba(255, 249, 240, .9), 0 0 3px rgba(255, 249, 240, .6);
  --btn-strong: #221c17;
  --btn-strong-ink: #fff;
  --good: #23854f;
  --good-ink: #1a6a3e;
  --bad-ink: #9b2f1d;
  --rec-ink: #6a3fae;
  --st-presale: #2f74b5;
  --st-preconstruction: #1f8a8a;
  --st-construction: #b9691f;
  --st-handover: #7c4fc0;
  --st-complete: #23854f;
  --st-hold: #c2412b;
  --chev: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%233d352e' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  color-scheme: light;
}

* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body {
  background: var(--backdrop);
  color: var(--ink);
  font: 16px/1.45 Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
}
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--accent-deep); }
h1, h2, h3, h4 { margin: 0; letter-spacing: -.01em; }
p { margin: 0; }
.ic { width: 20px; height: 20px; flex: none; }
.ic-brand { width: 18px; height: 18px; flex: none; }
.ic-atlas { width: 26px; height: 26px; flex: none; }
.muted { color: var(--ink-3); }
.small { font-size: 14.5px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--accent-deep); outline-offset: 2px; }

/* ---------- Backdrop: the same room by day and at night, so changing the theme changes the time of day ---------- */
.backdrop { position: fixed; inset: 0; z-index: 0; overflow: hidden; background: var(--backdrop); }
.backdrop img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: opacity .7s var(--ease); }
.backdrop .bd-night { opacity: 0; }
html[data-theme=dark] .backdrop .bd-night { opacity: 1; }
.backdrop::after { content: ''; position: absolute; inset: 0; background: linear-gradient(rgba(255, 249, 240, .26), rgba(255, 249, 240, .26)), radial-gradient(120% 95% at 50% 40%, transparent 50%, rgba(58, 40, 24, .26) 100%); }

/* ---------- Glass ---------- */
.glass {
  background: var(--bar);
  -webkit-backdrop-filter: blur(var(--blur)) saturate(var(--sat));
  backdrop-filter: blur(var(--blur)) saturate(var(--sat));
  border: 1px solid var(--edge);
  box-shadow: var(--shadow-pill), inset 0 1px 0 rgb(var(--w) / calc(.7 * var(--wk)));
}
.window {
  position: fixed; z-index: 20;
  top: var(--win-top); left: var(--win-left); right: 32px; bottom: 24px;
  border-radius: var(--r-window); overflow: hidden;
  background: var(--window);
  -webkit-backdrop-filter: blur(var(--blur)) saturate(var(--sat));
  backdrop-filter: blur(var(--blur)) saturate(var(--sat));
  border: 1px solid var(--edge);
  box-shadow: var(--shadow-window), inset 0 1px 0 rgb(var(--w) / calc(.75 * var(--wk)));
}
/* On a computer each card is its own pane of glass over the room. A phone keeps one pane, the window: many blurred
   layers scrolling is too much for it, and the cards inside are tints of that pane. */
@media (min-width: 760px) {
  .window { -webkit-backdrop-filter: none; backdrop-filter: none; }
  .window:not(.is-map) { top: 0; left: calc(var(--win-left) - 20px); right: 0; bottom: 0; border: 0; border-radius: 0; background: none; box-shadow: none; }
  /* Text sitting straight on the room gets a soft glow, so it stays readable over its brightest and darkest parts. */
  .window:not(.is-map) .window-scroll { padding: calc(var(--win-top) + 16px) 32px 60px 20px; text-shadow: var(--on-room); }
  .card, .tile, .pc, .lv-tile, .rq, .fact { -webkit-backdrop-filter: blur(var(--blur)) saturate(var(--sat)); backdrop-filter: blur(var(--blur)) saturate(var(--sat)); text-shadow: none; }
  .window-scroll .btn { text-shadow: none; }
}
@media (max-width: 759px) { .window { background: var(--bar); } }
@supports not ((backdrop-filter: blur(2px)) or (-webkit-backdrop-filter: blur(2px))) {
  .glass { background: var(--solid-bar); }
  .window { background: var(--solid-window); }
}
/* Solid panels: system asks for less transparency, a low-power phone, or the account-menu switch. */
html.solid .glass, html.solid .pin-pop .maplibregl-popup-content { background: var(--solid-bar); -webkit-backdrop-filter: none; backdrop-filter: none; }
html.solid .window { background: var(--solid-window); -webkit-backdrop-filter: none; backdrop-filter: none; }
@media (prefers-reduced-transparency: reduce) {
  .glass, .pin-pop .maplibregl-popup-content, .cap3d-chip { background: var(--solid-bar); -webkit-backdrop-filter: none; backdrop-filter: none; }
  .window { background: var(--solid-window); -webkit-backdrop-filter: none; backdrop-filter: none; }
}

/* ---------- Who can see what (sharing levels) ---------- */
.share-chip { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 10px 0 9px; border-radius: 16px; border: 1px solid rgb(var(--ink-rgb) / .16); background: rgb(var(--w) / calc(.5 * var(--wk))); color: var(--ink-2); font: inherit; font-size: 14px; font-weight: 600; white-space: nowrap; cursor: pointer; max-width: 100%; }
.share-chip span { overflow: hidden; text-overflow: ellipsis; }
.share-chip .ic { width: 14px; height: 14px; flex: none; }
.share-chip .ic:last-child { width: 12px; height: 12px; opacity: .7; }
button.share-chip:hover { background: var(--hi); color: var(--ink); }
span.share-chip { cursor: default; }
.share-chip.lv-me { color: var(--ink); border-color: rgb(var(--ink-rgb) / .35); }
.share-chip.lv-link { color: var(--accent-deep); border-color: color-mix(in srgb, var(--accent-deep) 40%, transparent); }
.f-tags { display: flex; gap: 8px; align-items: center; justify-content: flex-end; flex-wrap: wrap; }
.tour-share { margin-top: 6px; }
.tl-actions { flex-wrap: wrap; align-items: center; justify-content: flex-end; }
.lv-list { display: grid; gap: 8px; }
.lv { display: grid; grid-template-columns: 40px 1fr; gap: 12px; align-items: center; padding: 12px 14px; border-radius: 16px; border: 1px solid rgb(var(--ink-rgb) / .14); background: rgb(var(--w) / calc(.4 * var(--wk))); cursor: pointer; }
.lv input { position: absolute; opacity: 0; pointer-events: none; }
.lv b { display: block; font-size: 16px; }
.lv small { display: block; color: var(--ink-2); font-size: 14.5px; }
.lv:has(input:checked) { border-color: var(--accent-2); background: color-mix(in srgb, var(--accent) 16%, var(--hi)); box-shadow: 0 0 0 2px color-mix(in srgb, var(--accent-2) 35%, transparent); }
.lv:has(input:focus-visible) { outline: 2px solid var(--accent-deep); outline-offset: 2px; }
.lv-ic { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--hi); color: var(--ink); box-shadow: 0 2px 6px rgba(60, 40, 20, .1); flex: none; }
.lv-ic .ic { width: 18px; height: 18px; }
.lv-more { border: 0; padding: 4px 2px 0; margin: 0; display: grid; gap: 9px; min-width: 0; }   /* fieldsets are min-content wide by default */
.lv-more legend { font-size: 14.5px; font-weight: 700; color: var(--ink-2); margin-bottom: 8px; }
.kybos-line { display: flex; gap: 8px; align-items: flex-start; font-size: 14.5px; color: var(--ink-2); padding: 10px 12px; border-radius: 12px; background: rgb(var(--ink-rgb) / .06); }
.kybos-line .ic { width: 15px; height: 15px; margin-top: 2px; flex: none; }
.private-note { display: flex; gap: 10px; align-items: flex-start; padding: 12px 16px; border-radius: 16px; margin-bottom: 14px; font-size: 15px; color: var(--ink-2); background: color-mix(in srgb, var(--accent) 14%, transparent); border: 1px dashed color-mix(in srgb, var(--accent-deep) 45%, transparent); }
.private-note b { color: var(--ink); }
.private-note .ic { color: var(--accent-deep); margin-top: 1px; flex: none; }
.lv-filter { margin-bottom: 14px; }
.lv-filter .ic { width: 14px; height: 14px; }
.share-list { padding: 6px 12px 10px; margin-bottom: 20px; }
.s-group { font-size: 13px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); margin: 16px 0 6px; }
.share-list .s-group:first-child { margin-top: 10px; }
.srow { display: grid; grid-template-columns: 36px 1fr auto; gap: 12px; align-items: center; padding: 9px 4px; border-bottom: 1px solid var(--line); }
.s-ic { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; background: rgb(var(--w) / calc(.6 * var(--wk))); color: var(--ink-2); }
.s-ic .ic { width: 16px; height: 16px; }
.s-caps summary { list-style: none; display: flex; align-items: center; gap: 8px; padding: 11px 4px; font-size: 15px; font-weight: 600; color: var(--ink-2); cursor: pointer; border-bottom: 1px solid var(--line); }
.s-caps summary::-webkit-details-marker { display: none; }
.s-caps summary .ic { width: 15px; height: 15px; transition: transform .2s; }
.s-caps[open] summary .ic { transform: rotate(90deg); }
.s-caps .srow { padding-left: 22px; }
.lv-explain { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 20px; }
.lv-tile { padding: 14px 16px; border-radius: var(--r-tile); background: var(--card); border: 1px solid var(--edge); display: grid; gap: 4px; align-content: start; }
.lv-tile .lv-ic { margin-bottom: 6px; }
.lv-tile b { font-size: 16.5px; }
.lv-tile small { color: var(--ink-2); font-size: 14.5px; }
.priv-grid { display: grid; grid-template-columns: 1.25fr 1fr; gap: 20px; align-items: start; margin-bottom: 20px; }
.support { border: 0; padding: 0; margin: 4px 0 0; display: grid; gap: 10px; }
.support legend { font-size: 15.5px; font-weight: 650; color: var(--ink); margin-bottom: 10px; }
.support[disabled] .segbar { opacity: .6; }
.ticks li span { min-width: 0; }
.ticks li .ic { flex: none; }
.klog { list-style: none; margin: 0; padding: 0; display: grid; }
.klog li { display: flex; justify-content: space-between; gap: 12px; padding: 9px 0; border-bottom: 1px solid var(--line); font-size: 15px; color: var(--ink-2); }
.klog li:last-child { border-bottom: 0; }
.klog small { color: var(--ink-3); white-space: nowrap; font-size: 14px; }

/* ---------- Kybos staff: admin portal and "view as client" ---------- */
.avatar.kb { background: linear-gradient(140deg, #2b3a50, #0d1522); color: #f2c27f; }
.avatar.big-av { width: 82px; height: 82px; font-size: 27px; border-radius: 22px; }
.role-pill { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 12px 0 8px; border-radius: 16px; background: var(--btn-strong); color: var(--btn-strong-ink); font-size: 13.5px; font-weight: 800; letter-spacing: .03em; white-space: nowrap; }
.role-pill .kmark img { height: 18px; }
.viewas-pill { display: inline-flex; align-items: center; gap: 8px; height: 38px; padding: 0 6px 0 12px; border-radius: 19px; border: 0; background: var(--hot); color: var(--accent-ink); font: inherit; font-size: 14px; font-weight: 700; cursor: pointer; white-space: nowrap; box-shadow: var(--shadow-pill); }
.viewas-pill .ic { width: 16px; height: 16px; }
.viewas-pill b { background: rgb(42 24 6 / .14); padding: 4px 10px; border-radius: 13px; }
.viewas-pill:hover b { background: rgb(42 24 6 / .24); }
.window.viewing-as { box-shadow: var(--shadow-window), inset 0 0 0 3px var(--accent-2); }
.staff-line { margin-top: 16px; font-size: 15px; color: var(--ink-2); display: flex; gap: 6px; align-items: center; justify-content: center; flex-wrap: wrap; }
.staff-line .linkish { font-weight: 700; color: var(--accent-deep); display: inline-flex; gap: 4px; align-items: center; }
.staff-line .ic { width: 15px; height: 15px; }
.stats.a-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); margin-bottom: 20px; }
.a-grid { display: grid; grid-template-columns: 1fr 1.25fr; gap: 20px; align-items: start; }
.crow { display: grid; grid-template-columns: 36px 1fr auto; gap: 12px; align-items: center; padding: 11px 6px; border-bottom: 1px solid var(--line); color: inherit; text-decoration: none; border-radius: 12px; }
.crow:last-child { border-bottom: 0; }
.crow:hover { background: rgb(var(--w) / calc(.4 * var(--wk))); }
.crow b { display: block; font-weight: 650; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.crow small { display: block; color: var(--ink-3); font-size: 14px; }
.crow-end { display: inline-flex; gap: 8px; align-items: center; color: var(--ink-3); }
.tbl .pname .avatar.s { width: 32px; height: 32px; font-size: 12.5px; box-shadow: none; }
.tag.live { background: rgba(35, 133, 79, .14); color: var(--good-ink); }
.a-form { display: grid; gap: 12px; }
.a-form h3 { font-size: 18px; font-weight: 650; }
.ph-sub a { color: inherit; font-weight: 600; }
.switch { flex: none; width: 52px; height: 30px; border-radius: 15px; border: 0; padding: 0; background: rgb(var(--ink-rgb) / .22); position: relative; cursor: pointer; transition: background .2s; }
.switch span { position: absolute; top: 4px; left: 4px; width: 22px; height: 22px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .25); transition: transform .2s; }
.switch[aria-checked=true] { background: var(--good); }
.switch[aria-checked=true] span { transform: translateX(22px); }
.switch:focus-visible { outline: 2px solid var(--accent-deep); outline-offset: 2px; }
.role-counts { display: flex; gap: 8px 18px; flex-wrap: wrap; font-size: 15px; color: var(--ink-2); }
.role-counts b { color: var(--ink); }

/* ---------- Admin: deliver a capture or record ---------- */
.steps { list-style: none; margin: 0 0 4px; padding: 0; display: flex; gap: 6px; flex-wrap: wrap; }
.steps li { display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 14px 0 6px; border-radius: 18px; font-size: 14.5px; font-weight: 600; color: var(--ink-3); background: rgb(var(--ink-rgb) / .06); }
.steps li span { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font-size: 13px; font-weight: 800; background: rgb(var(--ink-rgb) / .1); color: var(--ink-2); }
.steps li span .ic { width: 13px; height: 13px; }
.steps li.on { color: var(--ink); background: color-mix(in srgb, var(--accent) 18%, var(--hi)); }
.steps li.on span { background: var(--accent); color: var(--accent-ink); }
.steps li.done { color: var(--ink-2); }
.steps li.done span { background: var(--good); color: #fff; }
.dk-list { grid-template-columns: 1fr 1fr; }
.dfiles { display: grid; border-radius: 16px; border: 1px solid var(--line); overflow: hidden; }
.dfile { display: grid; grid-template-columns: 22px 40px 1fr; gap: 12px; align-items: center; padding: 10px 14px; border-bottom: 1px solid var(--line); cursor: pointer; }
.dfile:last-child { border-bottom: 0; }
.dfile input { width: 18px; height: 18px; accent-color: var(--accent-2); }
.seal { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: 14px; font-size: 15px; color: var(--ink-2); background: color-mix(in srgb, var(--st-handover) 12%, transparent); border: 1px solid color-mix(in srgb, var(--st-handover) 35%, transparent); }
.seal b { color: var(--ink); }
.seal .ic { color: var(--st-handover); flex: none; margin-top: 2px; }
.d-notify { display: grid; grid-template-columns: 1fr 1.1fr; gap: 18px; align-items: start; }
.d-who { display: grid; gap: 10px; align-content: start; }
.d-who .s-group { margin-top: 0; }
.check.off { opacity: .6; }
/* The email preview keeps an email's own light look in both themes. */
.mail { background: #fff; color: #1f1a15; border-radius: 16px; overflow: hidden; border: 1px solid rgba(0, 0, 0, .1); box-shadow: 0 10px 30px rgba(0, 0, 0, .18); font-size: 15px; line-height: 1.5; }
.mail-meta { background: #f3efe9; padding: 10px 16px; display: grid; gap: 2px; font-size: 13.5px; color: #4a433c; }
.mail-meta b { color: #1f1a15; margin-right: 4px; }
.mail-body { padding: 20px 22px 18px; display: grid; gap: 12px; }
.mail-logo { height: 26px; width: auto; }
.mail-hi { font-weight: 700; font-size: 17px; }
.mail-note { border-left: 3px solid #d98f3c; padding: 6px 12px; background: #fbf6ef; color: #3d352e; font-style: italic; }
.mail-note small { font-style: normal; color: #5c534a; }
.mail-btn { justify-self: start; background: #221c17; color: #fff; padding: 10px 18px; border-radius: 10px; font-weight: 700; font-size: 15px; }
.mail-small { font-size: 13.5px; color: #5c534a; }
.mail-foot { padding: 12px 22px; font-size: 12.5px; color: #5c534a; border-top: 1px solid #ece5db; background: #faf8f5; }

/* ---------- Admin: capture requests ---------- */
.rail-badge { position: absolute; top: 2px; right: 0; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--accent-2); color: var(--accent-ink); font-size: 11.5px; font-weight: 800; display: grid; place-items: center; box-shadow: 0 0 0 2px var(--bar); }
.rq-board { display: grid; grid-template-columns: repeat(var(--cols, 4), minmax(0, 1fr)); gap: 14px; align-items: start; margin-bottom: 20px; }
.rq-col { display: grid; gap: 10px; padding: 12px; border-radius: var(--r-card); background: rgb(var(--w) / calc(.25 * var(--wk))); border: 1px solid var(--edge); }
.rq-col h3 { display: flex; align-items: center; gap: 8px; font-size: 16px; font-weight: 700; padding: 2px 4px 4px; }
.rq-col h3 .dot { width: 9px; height: 9px; border-radius: 50%; background: var(--c); }
.rq-col h3 .n { color: var(--ink-3); font-weight: 600; }
.rq { display: grid; gap: 6px; padding: 12px 14px; border-radius: var(--r-tile); background: var(--card); border: 1px solid var(--edge); color: var(--ink); text-decoration: none; box-shadow: var(--shadow-card); }
.rq:hover { background: var(--card-2); }
.rq-top { display: flex; justify-content: space-between; gap: 8px; font-size: 13.5px; color: var(--ink-3); }
.rq-id { font-weight: 700; color: var(--ink-2); font-variant-numeric: tabular-nums; }
.rq b { font-size: 16px; font-weight: 650; }
.rq-proj { display: flex; gap: 10px; align-items: center; font-size: 14.5px; font-weight: 600; min-width: 0; }
.rq-proj img { width: 44px; height: 30px; border-radius: 7px; object-fit: cover; flex: none; }
.rq-proj small { display: block; font-weight: 500; color: var(--ink-3); font-size: 13.5px; }
.rq-foot { display: flex; gap: 6px; align-items: center; font-size: 13.5px; color: var(--ink-2); }
.rq-foot .ic { width: 14px; height: 14px; flex: none; }
.rq-empty { font-size: 14.5px; color: var(--ink-3); text-align: center; padding: 14px 6px; }
.cal-wrap { overflow-x: auto; margin: 0 -4px; padding: 0 4px 4px; }
.cal { display: grid; min-width: 1050px; border-radius: 14px; overflow: hidden; border: 1px solid var(--line); }
.cal > span { min-height: 54px; border-bottom: 1px solid var(--line); border-right: 1px solid var(--line); }
.cal-h { display: flex; align-items: center; padding: 0 12px; font-size: 14px; font-weight: 600; color: var(--ink-3); min-height: 46px !important; }
.cal-d { display: grid; place-items: center; align-content: center; min-height: 46px !important; font-size: 12.5px; color: var(--ink-3); }
.cal-d b { font-size: 15px; color: var(--ink); }
.cal-p { display: grid; align-content: center; padding: 6px 12px; }
.cal-p b { font-size: 14.5px; }
.cal-p small { font-size: 12.5px; color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cal-c { padding: 4px 3px; display: grid; align-items: center; }
.cal .we { background: rgb(var(--ink-rgb) / .05); }
.cal-b { display: grid; justify-items: center; gap: 2px; padding: 5px 2px; border-radius: 9px; background: color-mix(in srgb, var(--accent) 28%, transparent); color: var(--ink); text-decoration: none; font-size: 11.5px; font-weight: 700; overflow: hidden; }
.cal-b span { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cal-b .ic { width: 14px; height: 14px; }
.cal-b:hover { background: var(--accent); color: var(--accent-ink); }
.rq-steps { margin: 18px 0; }
.rq-panel { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; align-content: start; }
.rq-panel .card-head { margin-bottom: 0; }
.rq-dl { display: grid; grid-template-columns: 150px 1fr; gap: 10px 14px; margin: 12px 0 0; font-size: 15.5px; }
.rq-dl dt { color: var(--ink-3); font-weight: 600; }
.rq-dl dd { margin: 0; min-width: 0; }
.rq-dl dd small { display: block; color: var(--ink-3); font-size: 14px; }
.opt.off { opacity: .55; cursor: not-allowed; }
.opt .price.ok { color: var(--good-ink); }
.warn-line { background: rgba(194, 65, 43, .1); color: var(--bad-ink); }
.rq-line { display: flex; align-items: center; gap: 8px; padding: 9px 12px; margin-top: 8px; border-radius: 12px; background: rgb(var(--w) / calc(.45 * var(--wk))); color: var(--ink-2); text-decoration: none; font-size: 14.5px; }
.rq-line:hover { background: var(--hi); color: var(--ink); }
.rq-line b { color: var(--ink); }
.rq-line .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--c); flex: none; }
.rq-line .ic { width: 14px; height: 14px; margin-left: auto; }
.tl.rq-tl.hot .tl-card { border-style: solid; border-color: var(--accent-2); background: var(--card); box-shadow: 0 0 0 1px var(--accent-2); }
.tl.rq-tl.hot .tl-node { color: var(--accent-deep); box-shadow: 0 0 0 3px rgba(217, 143, 60, .45); background: var(--hi); }

/* ---------- Admin: billing ---------- */
.chart.money { grid-template-columns: 44px 1fr; }
#a-plans .tbl, #a-invoices .tbl, #a-storage .tbl { min-width: 780px; }   /* phones scroll these sideways instead of squeezing them */
#a-invoices td:first-child { white-space: nowrap; }
.a-meter { display: grid; gap: 5px; min-width: 130px; }
.a-meter .progress { height: 8px; }
.a-meter small { font-size: 13.5px; color: var(--ink-2); white-space: nowrap; }
.att { display: grid; grid-template-columns: 36px 1fr auto; gap: 12px; align-items: center; padding: 11px 4px; border-bottom: 1px solid var(--line); }
.att:last-child { border-bottom: 0; }
.att b { display: block; font-weight: 650; }
.att small { display: block; color: var(--ink-2); font-size: 14px; }
.att-ic { width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center; background: color-mix(in srgb, var(--accent) 20%, transparent); color: var(--accent-deep); }
.att-ic.bad { background: rgba(194, 65, 43, .14); color: var(--bad-ink); }
.att-ic .ic { width: 17px; height: 17px; }
button.tile { font: inherit; width: 100%; }
.inv-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; }

/* The shared copy links out to tours instead of playing them inside the page. */
/* The viewer frame is dark in both themes, so the text here stays light. */
.viewer.embed .no-embed { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 10px; padding: 24px; text-align: center; color: #d9d2c8; }
.no-embed > .ic { width: 34px; height: 34px; color: #f2b96e; }
.no-embed b { font-size: 19px; color: #fff; }
.no-embed span { max-width: 44ch; }

/* ---------- Kybos logo (black by day, white at night) ---------- */
.kmark, .klogo { display: inline-flex; align-items: center; flex: none; }
.kmark img { height: 24px; width: auto; display: block; }
.klogo img { height: 34px; width: auto; display: block; }
html[data-theme=dark] .for-light, html:not([data-theme=dark]) .for-dark { display: none !important; }
.brand-tb { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); padding: 0 8px 0 10px; flex: none; }
.brand-tb .kmark { display: none; }
.brand-tb .product { font-size: 13px; font-weight: 700; line-height: 1.25; color: var(--ink-2); border-left: 1px solid var(--line); padding-left: 12px; white-space: nowrap; }
.si-brand { display: flex; align-items: center; gap: 14px; }
.si-brand .klogo img { height: 46px; }
.si-brand .product { font-size: 14.5px; font-weight: 700; color: var(--ink-2); border-left: 1px solid var(--line); padding-left: 14px; }

/* ---------- Top bar ---------- */
.topbar {
  position: fixed; z-index: 30; top: 18px; left: var(--win-left); right: 32px; height: 66px;
  display: flex; align-items: center; gap: 14px; padding: 0 10px 0 10px; border-radius: 33px;
}
.hello { display: flex; align-items: center; gap: 12px; border: 0; background: none; padding: 0 10px 0 0; cursor: pointer; border-radius: 26px; text-align: left; }
.hello:hover { background: rgb(var(--w) / calc(.35 * var(--wk))); }
.hello b { font-size: 18.5px; font-weight: 600; white-space: nowrap; }
.hello small { display: block; font-size: 13px; color: var(--ink-3); white-space: nowrap; }
.avatar {
  width: 44px; height: 44px; border-radius: 50%; flex: none; display: grid; place-items: center;
  background: linear-gradient(140deg, #f6d3a0, #c8863a); color: var(--accent-ink); font-weight: 800; font-size: 16px;
  box-shadow: 0 0 0 3px rgb(var(--w) / calc(.85 * var(--wk)));
}
.avatar.s { width: 36px; height: 36px; font-size: 14px; box-shadow: 0 0 0 2px rgb(var(--w) / calc(.85 * var(--wk))); }
.avatar.b2 { background: linear-gradient(140deg, #bcd7f2, #4a7fb0); color: #0e2338; }
.avatar.b3 { background: linear-gradient(140deg, #cdeccf, #4f9c6d); color: #0d2a19; }
.ask { position: relative; flex: 1; max-width: 640px; margin: 0 auto; }
.ask-field {
  display: flex; align-items: center; gap: 10px; height: 50px; padding: 0 8px;
  border-radius: 25px; background: rgb(var(--w) / calc(.42 * var(--wk))); border: 1px solid rgb(var(--w) / calc(.75 * var(--wk)));
}
.ask-field:focus-within { background: rgb(var(--w) / calc(.7 * var(--wk))); box-shadow: 0 0 0 3px rgba(217, 143, 60, .25); }
.orb {
  width: 30px; height: 30px; border-radius: 50%; flex: none;
  background: radial-gradient(circle at 35% 30%, #fff 0, #ffe3b8 22%, #e6a756 52%, #9a6bd6 100%);
  box-shadow: 0 0 14px rgba(230, 167, 86, .55), inset 0 0 6px rgb(var(--w) / calc(.6 * var(--wk)));
}
.ask-field input { flex: 1; min-width: 0; height: 100%; border: 0; outline: 0; background: none; color: var(--ink); font-size: 16px; }
.ask-field input::placeholder { color: var(--ink-3); }
.ask-field input::-webkit-search-cancel-button { display: none; }
.kbd { font: 600 13px/1 ui-monospace, Menlo, monospace; color: var(--ink-2); border: 1px solid rgb(var(--ink-rgb) / .2); border-radius: 6px; padding: 4px 6px; background: rgb(var(--w) / calc(.5 * var(--wk))); }
.ask .search-back { display: none; }
.sample-pill { font-size: 13px; font-weight: 700; color: var(--accent-deep); border: 1px dashed color-mix(in srgb, var(--accent-deep) 50%, transparent); padding: 5px 11px; border-radius: 999px; white-space: nowrap; background: rgb(var(--w) / calc(.35 * var(--wk))); }
.tb-actions { display: flex; align-items: center; gap: 8px; position: relative; }
.round {
  position: relative; width: 44px; height: 44px; border-radius: 50%; border: 0; display: inline-grid; place-items: center;
  background: var(--hi); color: var(--ink); cursor: pointer; box-shadow: 0 4px 12px rgba(60, 40, 20, .14);
}
.round:hover { background: var(--hi-hover); }
.round .badge {
  position: absolute; top: -2px; right: -2px; min-width: 19px; height: 19px; padding: 0 5px; border-radius: 10px;
  background: var(--accent-2); color: var(--accent-ink); font-size: 13px; font-weight: 800; line-height: 19px; text-align: center;
  box-shadow: 0 0 0 2px var(--hi);
}
.only-phone { display: none !important; }

.search-pop, .menu, .news-pop {
  position: absolute; top: calc(100% + 12px); z-index: 40;
  background: var(--pop); border: 1px solid rgb(var(--w) / calc(.9 * var(--wk))); border-radius: 20px;
  box-shadow: 0 24px 60px rgba(52, 34, 18, .25);
}
.search-pop { left: 0; right: 0; max-height: min(560px, 72vh); overflow: auto; padding: 8px; }
.sr-group { font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); padding: 10px 10px 4px; }
.sr-item { display: grid; grid-template-columns: 34px 1fr auto; gap: 10px; align-items: center; padding: 8px 10px; border-radius: 12px; cursor: pointer; }
.sr-ic { width: 34px; height: 34px; border-radius: 11px; display: grid; place-items: center; background: rgb(var(--ink-rgb) / .07); color: var(--ink-2); }
.sr-ic .ic { width: 16px; height: 16px; }
.sr-item b { display: block; font-weight: 600; font-size: 15.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sr-item small { display: block; color: var(--ink-3); font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sr-item mark { background: rgba(230, 167, 86, .35); color: var(--ink); border-radius: 3px; }
.sr-item .go { opacity: 0; color: var(--ink-3); }
.sr-item[aria-selected=true] { background: rgba(230, 167, 86, .18); }
.sr-item[aria-selected=true] .go { opacity: 1; }
.sr-item.ask-row .sr-ic { background: none; }
.sr-empty { padding: 14px 12px 6px; color: var(--ink-2); font-size: 15px; }
.sr-try { display: flex; flex-wrap: wrap; gap: 6px; padding: 6px 10px 10px; }
.sr-foot { display: flex; gap: 14px; padding: 8px 10px 4px; border-top: 1px solid var(--line); margin-top: 6px; font-size: 13px; color: var(--ink-3); }
.sr-foot .kbd { padding: 2px 5px; }
.menu { right: 0; width: 300px; padding: 6px; }
.menu.left { left: 0; right: auto; }
.menu-head { padding: 10px 10px 12px; border-bottom: 1px solid var(--line); margin-bottom: 6px; }
.menu-head b { display: block; }
.menu-head small { color: var(--ink-3); }
.menu-item { display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px; border: 0; border-radius: 12px; background: none; color: var(--ink); text-decoration: none; cursor: pointer; text-align: left; font-size: 15.5px; }
.menu-item:hover, .menu-item:focus-visible { background: rgb(var(--ink-rgb) / .07); }
.menu-item .ic { color: var(--ink-2); }
.menu-item .sw { margin-left: auto; width: 36px; height: 21px; border-radius: 11px; background: rgb(var(--ink-rgb) / .2); position: relative; transition: background .2s; }
.menu-item .sw::after { content: ''; position: absolute; top: 3px; left: 3px; width: 15px; height: 15px; border-radius: 50%; background: #fff; transition: transform .2s; box-shadow: 0 1px 3px rgba(0, 0, 0, .2); }
.menu-item[aria-checked=true] .sw { background: var(--accent-2); }
.menu-item[aria-checked=true] .sw::after { transform: translateX(15px); }
.menu-sep { height: 1px; background: var(--line); margin: 6px 4px; }
.menu-label { font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); padding: 8px 10px 2px; }
.news-pop { right: 0; width: 380px; padding: 10px; max-height: 70vh; overflow: auto; }

/* ---------- Icon rail ---------- */
.rail {
  position: fixed; z-index: 30; left: 22px; top: 50%; transform: translateY(-50%);
  width: var(--rail-w); padding: 10px 0; border-radius: 30px;
  display: flex; flex-direction: column; align-items: center; gap: 6px;
}
.rail a, .rail button {
  position: relative; width: 44px; height: 44px; border-radius: 50%; border: 0; background: none;
  display: grid; place-items: center; color: var(--ink-2); cursor: pointer; text-decoration: none;
}
.rail a:hover, .rail button:hover { background: rgb(var(--w) / calc(.5 * var(--wk))); color: var(--ink); }
.rail a[aria-current=page] { background: var(--hi); color: var(--ink); box-shadow: 0 4px 12px rgba(60, 40, 20, .16); }
.rail .sep { width: 24px; height: 1px; background: var(--line); margin: 4px 0; }
.rail [data-tip]::after {
  content: attr(data-tip); position: absolute; left: 54px; top: 50%; transform: translateY(-50%) translateX(-4px);
  padding: 5px 10px; border-radius: 9px; background: rgb(var(--w) / calc(.95 * var(--wk))); color: var(--ink);
  font-size: 14px; font-weight: 600; white-space: nowrap; box-shadow: 0 4px 14px rgba(60, 40, 20, .18);
  opacity: 0; pointer-events: none; transition: opacity .15s, transform .15s;
}
.rail [data-tip]:hover::after, .rail [data-tip]:focus-visible::after { opacity: 1; transform: translateY(-50%); }

/* ---------- Window content ---------- */
.window-scroll { position: absolute; inset: 0; overflow: auto; overscroll-behavior: contain; padding: 32px 34px 120px; scrollbar-width: thin; scrollbar-color: rgb(var(--ink-rgb) / .25) transparent; }
/* Moves only: fading would switch off the blur of every card on the page while it plays. */
.view-in { animation: settle .35s var(--ease) both; }
@media (max-width: 480px) { .si-wrap { --cut: 32px; } .signin-card { padding: 30px 22px 18px; } }
@keyframes settle { from { transform: translateY(10px); } to { transform: none; } }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 22px; }
.page-head h1 { font-size: 39px; font-weight: 650; letter-spacing: -.025em; line-height: 1.1; }
.page-head p { color: var(--ink-3); margin-top: 6px; font-size: 16.5px; }
.back { display: inline-flex; align-items: center; gap: 6px; color: var(--ink-2); text-decoration: none; font-size: 15px; font-weight: 600; padding: 6px 10px 6px 6px; border-radius: 10px; margin-bottom: 8px; }
.back:hover { background: rgb(var(--w) / calc(.45 * var(--wk))); }
.back .ic { width: 16px; height: 16px; }

.card { background: var(--card); border: 1px solid var(--edge); border-radius: var(--r-card); padding: 18px 20px; box-shadow: var(--shadow-card); min-width: 0; }
.card-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; margin-bottom: 12px; }
.card-head h3 { font-size: 18px; font-weight: 650; }
.card-head p { font-size: 14.5px; color: var(--ink-3); margin-top: 2px; }
.label { font-size: 15px; color: var(--ink-2); font-weight: 500; }
.big { font-size: 41px; font-weight: 650; letter-spacing: -.025em; line-height: 1.1; }
.delta { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; font-weight: 700; padding: 2px 7px; border-radius: 7px; background: rgba(35, 133, 79, .14); color: var(--good-ink); }
.delta.warn { background: rgba(194, 65, 43, .12); color: var(--bad-ink); }
.delta.info { background: rgb(var(--w) / calc(.6 * var(--wk))); color: var(--ink-2); }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 48px; padding: 0 22px;
  border-radius: 24px; border: 1px solid rgb(var(--w) / calc(.9 * var(--wk))); background: rgb(var(--w) / calc(.78 * var(--wk)));
  color: var(--ink); font-weight: 600; font-size: 16px; line-height: 1; cursor: pointer; text-decoration: none; white-space: nowrap;
  box-shadow: 0 2px 8px rgba(60, 40, 20, .08); transition: background .2s, transform .1s;
}
.btn:hover { background: var(--hi); }
.btn:active { transform: translateY(1px); }
.btn.dark { background: var(--btn-strong); border-color: var(--btn-strong); color: var(--btn-strong-ink); }
.btn.dark:hover { background: color-mix(in srgb, var(--btn-strong) 88%, var(--accent-2)); }
.btn.hot { background: var(--hot); border-color: transparent; color: var(--accent-ink); }
.btn.ghost { background: transparent; border-color: rgb(var(--ink-rgb) / .18); box-shadow: none; }
.btn.ghost:hover { background: rgb(var(--w) / calc(.5 * var(--wk))); }
.btn.sm { height: 38px; padding: 0 16px; font-size: 14.5px; border-radius: 19px; }
.btn.sm .ic { width: 15px; height: 15px; }
.btn.block { width: 100%; }
.btn[disabled] { opacity: .55; cursor: not-allowed; }
.price-tag { font-weight: 700; padding: 4px 8px; border-radius: 10px; background: rgb(var(--w) / calc(.18 * var(--wk))); }
.btn:not(.dark) .price-tag { background: rgb(var(--ink-rgb) / .08); }
.icon-btn { position: relative; display: inline-grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; border: 0; background: transparent; color: var(--ink-2); cursor: pointer; }
.icon-btn:hover { background: rgb(var(--w) / calc(.6 * var(--wk))); color: var(--ink); }

.status {
  --c: var(--accent-2);
  display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 11px; border-radius: 999px;
  font-size: 14px; font-weight: 600; color: var(--ink); background: rgb(var(--w) / calc(.82 * var(--wk))); white-space: nowrap;
}
.status i { width: 7px; height: 7px; border-radius: 50%; background: var(--c); }
.progress { --c: var(--accent-2); height: 6px; border-radius: 6px; background: var(--track); overflow: hidden; }
.progress > span { display: block; height: 100%; border-radius: inherit; background: var(--c); }
.progress.hatch > span { background: repeating-linear-gradient(135deg, var(--c) 0 6px, color-mix(in srgb, var(--c) 70%, #fff) 6px 10px); }
.suggest { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 600; color: var(--accent-deep); background: rgb(var(--w) / calc(.6 * var(--wk))); border: 1px solid color-mix(in srgb, var(--accent-deep) 30%, transparent); padding: 4px 10px; border-radius: 999px; white-space: nowrap; }
.suggest .ic { width: 14px; height: 14px; }
.chip { text-decoration: none; display: inline-flex; align-items: center; gap: 7px; height: 36px; padding: 0 15px; border-radius: 18px; border: 1px solid rgb(var(--w) / calc(.8 * var(--wk))); background: rgb(var(--w) / calc(.45 * var(--wk))); color: var(--ink-2); font-size: 14.5px; font-weight: 600; white-space: nowrap; cursor: pointer; }
.chip:hover { background: rgb(var(--w) / calc(.75 * var(--wk))); color: var(--ink); }
.chip[aria-pressed=true], .chip[aria-current=page] { background: var(--hi); color: var(--ink); box-shadow: 0 3px 10px rgba(60, 40, 20, .12); }
.chip .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--c); }
.chip .n { color: var(--ink-3); font-variant-numeric: tabular-nums; font-weight: 500; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; }
.select {
  appearance: none; -webkit-appearance: none; height: 42px; min-width: 0; padding: 0 34px 0 15px; border-radius: 21px;
  border: 1px solid rgb(var(--w) / calc(.85 * var(--wk))); color: var(--ink); font-size: 15px; font-weight: 500; cursor: pointer;
  background: rgb(var(--w) / calc(.55 * var(--wk))) var(--chev) no-repeat right 11px center / 14px;
}
.input { height: 50px; width: 100%; padding: 0 16px; border-radius: 16px; border: 1px solid rgb(var(--w) / calc(.9 * var(--wk))); background: rgb(var(--w) / calc(.65 * var(--wk))); color: var(--ink); outline: none; }
.input::placeholder, textarea::placeholder { color: var(--ink-3); }
.input:focus, textarea:focus { border-color: rgba(217, 143, 60, .8); box-shadow: 0 0 0 3px rgba(217, 143, 60, .22); }
textarea.input { height: 84px; padding: 10px 16px; resize: vertical; }
label.field { display: grid; gap: 6px; font-size: 14.5px; color: var(--ink-2); font-weight: 600; }

/* ---------- Overview ---------- */
.row1 { display: grid; grid-template-columns: 1fr 1.2fr 1.1fr; gap: 20px; }
.row2 { display: grid; grid-template-columns: 1fr 2.15fr; gap: 20px; margin-top: 20px; align-items: start; }
.col { display: grid; gap: 20px; min-width: 0; }
.portfolio .btn-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 16px 0 14px; }
.portfolio .btn { padding: 0 12px; }
.sub-card { background: var(--card-2); border-radius: var(--r-tile); padding: 12px; border: 1px solid rgb(var(--w) / calc(.8 * var(--wk))); }
.sub-card .label { font-size: 14.5px; display: flex; gap: 6px; }
.sub-card .label span { color: var(--ink-3); }
.cities { display: grid; gap: 6px; margin-top: 10px; }
.city { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 2px 10px; text-align: left; border: 0; cursor: pointer; padding: 9px 12px; border-radius: 14px; background: rgb(var(--w) / calc(.7 * var(--wk))); color: var(--ink); min-width: 0; }
.city:hover { background: var(--hi); }
.city[aria-pressed=true] { box-shadow: inset 0 0 0 2px var(--accent-2); background: var(--hi); }
.city b { font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.city .n { grid-row: 1 / span 2; grid-column: 2; font-size: 14.5px; font-weight: 700; color: var(--ink-2); white-space: nowrap; }
.city small { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--ink-3); white-space: nowrap; overflow: hidden; }
.city .dots { display: inline-flex; gap: 3px; }
.city .dots i { width: 7px; height: 7px; border-radius: 50%; background: var(--c); }
.stats { padding: 12px; display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.tile { position: relative; background: var(--card-2); border: 1px solid rgb(var(--w) / calc(.85 * var(--wk))); border-radius: var(--r-tile); padding: 14px 16px; min-height: 150px; display: flex; flex-direction: column; justify-content: space-between; cursor: pointer; text-align: left; color: var(--ink); text-decoration: none; }
.tile:hover { background: rgb(var(--w) / calc(.82 * var(--wk))); }
.tile.hot { background: var(--hot); border-color: rgb(var(--w) / calc(.5 * var(--wk))); color: var(--accent-ink); }
.tile .t-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; font-size: 15px; font-weight: 600; }
.tile .t-ic { width: 30px; height: 30px; border-radius: 50%; background: var(--hi); color: var(--ink); display: grid; place-items: center; flex: none; box-shadow: 0 2px 6px rgba(60, 40, 20, .1); }
.tile .t-ic .ic { width: 15px; height: 15px; }
.tile .v { font-size: 32px; font-weight: 700; letter-spacing: -.02em; line-height: 1.1; }
.tile .v.sm { font-size: 25.5px; }
.tile .t-foot { display: flex; align-items: center; gap: 6px; font-size: 14px; color: inherit; }
.tile.hot .delta { background: rgb(var(--w) / calc(.4 * var(--wk))); color: var(--accent-ink); }
.map-card { padding: 14px; display: flex; flex-direction: column; }
.map-card .card-head { padding: 4px 6px 0; margin-bottom: 10px; }
.map-slot { position: relative; flex: 1; min-height: 300px; border-radius: 18px; overflow: hidden; background: var(--map-bg); border: 1px solid rgb(var(--w) / calc(.85 * var(--wk))); }
.map-slot #map { position: absolute; inset: 0; }
#map-park { position: fixed; left: -10000px; top: 0; width: 900px; height: 600px; visibility: hidden; }
#map-park #map { position: absolute; inset: 0; }
.usage .progress { height: 14px; border-radius: 8px; margin: 14px 0 8px; }
.usage-foot { display: flex; justify-content: space-between; font-size: 14.5px; color: var(--ink-3); }
.usage-foot b { color: var(--ink); }

/* Bar chart (captures per month) */
.legend-row { display: flex; gap: 14px; font-size: 14px; color: var(--ink-2); }
.legend-row span { display: inline-flex; align-items: center; gap: 6px; }
.legend-row i { width: 10px; height: 10px; border-radius: 3px; background: var(--c); }
.chart { position: relative; display: grid; grid-template-columns: 26px 1fr; gap: 6px; margin-top: 14px; height: 170px; }
.chart .y { display: flex; flex-direction: column; justify-content: space-between; font-size: 13px; color: var(--ink-3); text-align: right; padding-bottom: 20px; }
.chart .plot { position: relative; display: flex; align-items: flex-end; justify-content: space-around; gap: 6px; padding-bottom: 20px; border-bottom: 1px solid var(--line); }
.chart .grid-line { position: absolute; left: 0; right: 0; height: 1px; background: var(--line); }
.chart .col-bar { position: relative; flex: 1; max-width: 26px; height: 100%; display: flex; flex-direction: column-reverse; gap: 2px; justify-content: flex-start; }
.chart .seg { display: block; width: 100%; padding: 0; border: 0; border-radius: 0; background: var(--c); }   /* not the .seg toggle further down */
.chart .seg.top { border-radius: 4px 4px 0 0; }
.chart .m { position: absolute; bottom: -20px; left: 50%; transform: translateX(-50%); font-size: 13px; color: var(--ink-3); }
.chart .hit { position: absolute; inset: 0 -4px -20px; cursor: default; }
.chart-tip { position: absolute; z-index: 5; pointer-events: none; padding: 7px 10px; border-radius: 10px; background: rgb(var(--w) / calc(.97 * var(--wk))); box-shadow: 0 6px 18px rgba(60, 40, 20, .18); font-size: 14px; white-space: nowrap; transform: translate(-50%, -100%); }
.chart-tip b { display: block; margin-bottom: 2px; }
.chart-tip span { display: flex; align-items: center; gap: 6px; color: var(--ink-2); }
.chart-tip i { width: 8px; height: 8px; border-radius: 2px; background: var(--c); }

/* Activity table */
.tbl-tools { display: flex; gap: 8px; align-items: center; }
.mini-search { display: flex; align-items: center; gap: 8px; height: 42px; padding: 0 16px; border-radius: 21px; background: rgb(var(--w) / calc(.55 * var(--wk))); border: 1px solid rgb(var(--w) / calc(.85 * var(--wk))); color: var(--ink-3); }
.mini-search input { border: 0; outline: 0; background: none; width: 150px; font-size: 15px; color: var(--ink); }
.mini-search input::placeholder { color: var(--ink-3); }
.tbl-wrap { overflow-x: auto; margin: 0 -4px; padding: 0 4px; }
.tbl { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 15px; min-width: 560px; }
.tbl th { text-align: left; color: var(--ink-3); font-weight: 600; font-size: 14px; padding: 11px 12px; background: rgb(var(--w) / calc(.6 * var(--wk))); white-space: nowrap; }
.tbl th:first-child { border-radius: 14px 0 0 14px; }
.tbl th:last-child { border-radius: 0 14px 14px 0; }
.tbl td { padding: 13px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.tbl tr:last-child td { border-bottom: 0; }
.tbl tbody tr.link { cursor: pointer; }
.tbl tbody tr.link:hover td { background: rgb(var(--w) / calc(.4 * var(--wk))); }
.tbl .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.tbl .ref { font-variant-numeric: tabular-nums; color: var(--ink-2); white-space: nowrap; font-size: 14.5px; }
.tbl .what { display: flex; align-items: center; gap: 10px; font-weight: 600; }
.tbl .what .k { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; background: color-mix(in srgb, var(--k) 16%, var(--hi)); color: var(--k); flex: none; }
.tbl .what .k .ic { width: 15px; height: 15px; }
.tbl .pname { display: flex; gap: 10px; align-items: center; font-weight: 600; color: inherit; text-decoration: none; }
.tbl .pname img { width: 48px; height: 32px; border-radius: 8px; object-fit: cover; }
.unread-dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--accent-2); margin-right: 6px; }
.pill-s { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; font-size: 14.5px; white-space: nowrap; }
.pill-s i { width: 7px; height: 7px; border-radius: 50%; background: var(--c); }
.k-capture { --k: var(--st-construction); } .k-defect { --k: var(--good); } .k-record { --k: var(--st-handover); } .k-invoice { --k: var(--st-hold); } .k-team, .k-upload { --k: var(--st-presale); }

/* ---------- Floating bottom bar ---------- */
.tabbar {
  position: fixed; z-index: 35; bottom: 42px; left: calc(var(--win-left) + (100vw - var(--win-left) - 32px) / 2);
  transform: translateX(-50%); display: flex; align-items: center; gap: 6px; padding: 6px; border-radius: 30px; max-width: calc(100vw - var(--win-left) - 80px);
}
.tabbar .items { display: flex; gap: 2px; overflow-x: auto; scrollbar-width: none; }
.tabbar .items::-webkit-scrollbar { display: none; }
.tabbar a, .tabbar button.tb {
  display: inline-flex; align-items: center; gap: 7px; height: 48px; padding: 0 22px; border-radius: 24px; border: 0;
  background: none; color: var(--ink-2); font-weight: 600; font-size: 16px; text-decoration: none; white-space: nowrap; cursor: pointer;
}
.tabbar a:hover, .tabbar button.tb:hover { color: var(--ink); background: rgb(var(--w) / calc(.45 * var(--wk))); }
.tabbar [aria-current=page], .tabbar [aria-pressed=true] { background: var(--hi); color: var(--ink); box-shadow: 0 4px 12px rgba(60, 40, 20, .14); }
.tabbar .ic { width: 16px; height: 16px; }
.tabbar .plus { margin-left: 4px; }
.subnav-inline { display: none; }

/* ---------- Projects ---------- */
.toolbar { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-bottom: 18px; }
.toolbar .grow { flex: 1; }
.seg { display: inline-flex; padding: 3px; gap: 2px; border-radius: 19px; background: rgb(var(--w) / calc(.45 * var(--wk))); border: 1px solid rgb(var(--w) / calc(.8 * var(--wk))); }
.seg button { width: 42px; height: 34px; border-radius: 17px; border: 0; background: none; display: grid; place-items: center; color: var(--ink-3); cursor: pointer; }
.seg button[aria-pressed=true] { background: var(--hi); color: var(--ink); box-shadow: 0 2px 6px rgba(60, 40, 20, .12); }
.seg .ic { width: 16px; height: 16px; }
.pgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 16px; }
.pgrid[data-mode=list] { grid-template-columns: 1fr; gap: 10px; }
.pcard { position: relative; background: var(--card); border: 1px solid var(--edge); border-radius: 22px; overflow: hidden; box-shadow: var(--shadow-card); transition: transform .2s var(--ease), background .2s; }
.pcard:hover { background: rgb(var(--w) / calc(.62 * var(--wk))); transform: translateY(-2px); }
.pc-hit { position: absolute; inset: 0; z-index: 1; border: 0; background: none; cursor: pointer; border-radius: inherit; }
.pc-hit:focus-visible { outline: 2px solid var(--accent-deep); outline-offset: -3px; }
.pc-thumb { position: relative; aspect-ratio: 16 / 10; background: #cdbca6; }
.pc-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
.pc-thumb .status { position: absolute; left: 10px; top: 10px; background: rgb(20 16 12 / .66); color: #fff; }
.pc-body { padding: 12px 14px 14px; }
.pc-body h3 { font-size: 17px; font-weight: 650; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pc-meta { font-size: 14.5px; color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pc-body .status { display: none; }
.pc-body .progress { margin: 11px 0 8px; }
.pc-foot { display: flex; justify-content: space-between; align-items: center; gap: 6px; font-size: 14px; color: var(--ink-2); }
.pc-foot span { display: inline-flex; align-items: center; gap: 4px; }
.pc-foot .ic { width: 13px; height: 13px; }
.pc-map { position: absolute; z-index: 2; right: 10px; top: 10px; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; background: rgb(var(--w) / calc(.9 * var(--wk))); color: var(--ink); text-decoration: none; box-shadow: 0 2px 8px rgba(60, 40, 20, .15); opacity: 0; transition: opacity .2s; }
.pc-map .ic { width: 16px; height: 16px; }
.pcard:hover .pc-map, .pcard:focus-within .pc-map { opacity: 1; }
@media (hover: none) { .pc-map { opacity: 1; } }
.pgrid[data-mode=list] .pcard { display: grid; grid-template-columns: 120px 1fr; }
.pgrid[data-mode=list] .pc-thumb { aspect-ratio: auto; height: 100%; min-height: 86px; }
.pgrid[data-mode=list] .pc-thumb .status { display: none; }
.pgrid[data-mode=list] .pc-body { display: grid; grid-template-columns: minmax(0, 1.4fr) auto minmax(120px, 1fr) auto; gap: 16px; align-items: center; padding: 12px 56px 12px 16px; }
.pgrid[data-mode=list] .pc-body .status { display: inline-flex; }
.pgrid[data-mode=list] .pc-body .progress { margin: 0; }
.pgrid[data-mode=list] .pc-map { top: 50%; transform: translateY(-50%); opacity: 1; }
.empty { grid-column: 1 / -1; text-align: center; padding: 34px 10px; color: var(--ink-2); }

/* ---------- Map view ---------- */
.window.is-map .window-scroll { padding: 0; overflow: hidden; }
.mapview { position: absolute; inset: 0; }
.mapview .map-slot { position: absolute; inset: 0; border-radius: 0; border: 0; min-height: 0; }
.map-list {
  position: absolute; z-index: 5; top: 18px; left: 18px; bottom: 110px; width: 340px;
  display: flex; flex-direction: column; overflow: hidden; border-radius: 24px;
  background: var(--panel); border: 1px solid rgb(var(--w) / calc(.9 * var(--wk))); box-shadow: 0 16px 40px rgba(52, 34, 18, .18);
}
.sheet-grab { display: none; }
.map-list .ml-head { padding: 16px 16px 10px; }
.map-list .ml-head h2 { font-size: 18.5px; font-weight: 650; display: flex; gap: 8px; align-items: center; }
.count { font-size: 14px; font-weight: 800; color: var(--accent-ink); background: var(--accent); border-radius: 999px; padding: 1px 8px; }
.map-list .ml-head p { font-size: 14.5px; color: var(--ink-3); margin-top: 2px; }
.map-list .chips { flex-wrap: nowrap; overflow-x: auto; padding: 0 16px 12px; scrollbar-width: none; }
.map-list .chips::-webkit-scrollbar { display: none; }
.mlist { flex: 1; overflow: auto; overscroll-behavior: contain; padding: 6px 10px 12px; border-top: 1px solid var(--line); }
.mrow { position: relative; display: grid; grid-template-columns: 64px 1fr auto; gap: 12px; align-items: center; padding: 10px 8px; border-radius: 14px; }
.mrow:hover, .mrow.is-hot { background: rgb(var(--w) / calc(.8 * var(--wk))); }
.mrow.is-selected { background: var(--hi); box-shadow: inset 0 0 0 2px var(--accent-2); }
.mrow img { width: 64px; height: 44px; border-radius: 10px; object-fit: cover; }
.mrow b { display: block; font-size: 15.5px; font-weight: 650; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mrow small { display: flex; align-items: center; gap: 6px; font-size: 14px; color: var(--ink-3); white-space: nowrap; overflow: hidden; }
.mrow small i { width: 7px; height: 7px; border-radius: 50%; background: var(--c); flex: none; }
.mrow .progress { height: 4px; margin-top: 6px; }
.mrow .mr-open { position: relative; z-index: 2; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; color: var(--ink-2); text-decoration: none; }
.mrow .mr-open:hover { background: rgb(var(--ink-rgb) / .08); color: var(--ink); }
.mrow .mr-open .ic { width: 16px; height: 16px; }
.mrow .pc-hit { border-radius: 14px; }
.map-ctrls { position: absolute; z-index: 5; right: 18px; top: 18px; display: grid; border-radius: 18px; overflow: hidden; background: rgb(var(--w) / calc(.9 * var(--wk))); box-shadow: 0 6px 18px rgba(60, 40, 20, .16); }
.map-ctrls button { width: 46px; height: 46px; display: grid; place-items: center; border: 0; background: none; color: var(--ink); cursor: pointer; }
.map-ctrls button + button { border-top: 1px solid var(--line); }
.map-ctrls button:hover { background: rgb(var(--ink-rgb) / .06); }
.map-ctrls .t3d { font: 800 15px/1 inherit; letter-spacing: .02em; }
.map-ctrls .t3d[aria-pressed=true] { background: var(--accent); color: var(--accent-ink); }
/* The real 3D capture (js/map3d.js): a see-through canvas between the map tiles and the pins. */
.splat-layer { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; opacity: 0; transition: opacity .6s ease; }
.splat-layer.on { opacity: 1; }
html[data-theme=dark] .splat-layer { filter: brightness(.86); }
.cap3d-chip { position: absolute; z-index: 4; top: 18px; right: 80px; display: flex; align-items: center; gap: 12px; max-width: calc(100% - 100px); padding: 8px 8px 8px 14px; border-radius: 18px; background: var(--pop-glass); -webkit-backdrop-filter: blur(18px) saturate(1.4); backdrop-filter: blur(18px) saturate(1.4); box-shadow: 0 6px 18px rgba(0, 0, 0, .22); color: var(--ink); }
/* Over the capture the pin-colour legend is noise and hard to read; the chip says what you see instead. */
body.in-3d .mapview .legend { display: none; }
.cap3d-dot { flex: none; width: 10px; height: 10px; border-radius: 50%; background: var(--good); box-shadow: 0 0 0 4px rgb(var(--ink-rgb) / .06); }
.cap3d-dot.busy { background: var(--accent); animation: cap3d-pulse 1s ease-in-out infinite alternate; }
@keyframes cap3d-pulse { to { opacity: .35; } }
.cap3d-text { display: grid; gap: 2px; min-width: 0; }
.cap3d-text b { font-size: 15px; }
.cap3d-text small { font-size: 13px; color: var(--ink-2); }
.cap3d-dates { display: flex; gap: 4px; padding: 3px; border-radius: 12px; background: rgb(var(--ink-rgb) / .07); }
.cap3d-dates button { border: 0; border-radius: 9px; padding: 7px 10px; font: 600 14px/1 inherit; color: var(--ink-2); background: none; cursor: pointer; white-space: nowrap; }
.cap3d-dates button[aria-pressed=true] { background: var(--accent); color: var(--accent-ink); }
.legend { position: absolute; z-index: 5; left: 374px; bottom: 112px; display: flex; gap: 12px; flex-wrap: wrap; padding: 7px 14px; border-radius: 999px; background: rgb(var(--w) / calc(.88 * var(--wk))); font-size: 14px; color: var(--ink-2); box-shadow: 0 4px 12px rgba(60, 40, 20, .12); }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 8px; height: 8px; border-radius: 50%; background: var(--c); }
.maplibregl-map { font: inherit; }
/* The map credits stay small and quiet, whatever size the rest of the text is. */
.maplibregl-ctrl-attrib { font-size: 10.5px; line-height: 1.35; letter-spacing: .01em; }
/* Map credits: a round (i) the size of its button; opened, one small line of credits beside it. */
.maplibregl-ctrl-attrib.maplibregl-compact { min-height: 24px; padding: 0 24px 0 0; border-radius: 12px; }
.maplibregl-ctrl-attrib.maplibregl-compact-show { max-width: min(300px, calc(100vw - 120px)); min-height: 14px; padding: 5px 28px 5px 10px; font-size: 9.5px; line-height: 1.4; }
.maplibregl-ctrl-attrib .maplibregl-ctrl-attrib-inner { padding: 0; }
.maplibregl-ctrl-attrib-button { width: 24px; height: 24px; background-size: 18px; background-position: center; background-color: transparent; }
.maplibregl-ctrl-attrib.maplibregl-compact-show .maplibregl-ctrl-attrib-button { top: auto; bottom: 0; background-color: transparent; }
.maplibregl-ctrl-attrib.maplibregl-compact { background: rgb(var(--w) / calc(.8 * var(--wk))); color: var(--ink-3); }
.maplibregl-ctrl-attrib a { color: var(--ink-2); }
.mapview .maplibregl-ctrl-bottom-right { bottom: 100px; right: 12px; }
.map-note { position: absolute; z-index: 6; left: 50%; top: 14px; transform: translateX(-50%); font-size: 14px; color: var(--ink-2); background: rgb(var(--w) / calc(.9 * var(--wk))); padding: 6px 12px; border-radius: 999px; }

/* Pins and the map card */
.pin { width: 30px; height: 30px; padding: 0; border: 0; background: none; cursor: pointer; }
.pin-dot { position: absolute; inset: 0; border-radius: 50%; background: var(--hi); border: 3px solid var(--c); box-shadow: 0 4px 12px rgba(40, 25, 10, .3); transition: transform .2s var(--ease), box-shadow .2s; }
.pin-dot::after { content: ''; position: absolute; inset: 5px; border-radius: 50%; background: var(--c); }
.pin:hover .pin-dot, .pin.is-hot .pin-dot, .pin:focus-visible .pin-dot { transform: scale(1.18); }
.pin:focus-visible { outline: none; }
.pin.is-selected { z-index: 3; }
.pin.is-selected .pin-dot { transform: scale(1.3); box-shadow: 0 0 0 6px color-mix(in srgb, var(--c) 28%, transparent), 0 6px 16px rgba(40, 25, 10, .35); }
.pin.is-selected::before { content: ''; position: absolute; inset: -6px; border-radius: 50%; border: 2px solid var(--c); opacity: 0; animation: pulse 2.2s var(--ease) infinite; }
@keyframes pulse { 0% { transform: scale(.7); opacity: .8; } 100% { transform: scale(1.9); opacity: 0; } }
.pin-label { position: absolute; left: 38px; top: 50%; transform: translateY(-50%); white-space: nowrap; font-size: 14px; font-weight: 650; color: var(--ink); background: rgb(var(--w) / calc(.92 * var(--wk))); padding: 3px 9px; border-radius: 9px; box-shadow: 0 2px 8px rgba(40, 25, 10, .15); pointer-events: none; opacity: 0; transition: opacity .2s; }
#map.z-labels .pin-label, .pin.is-selected .pin-label, .pin:hover .pin-label { opacity: 1; }
.cluster { width: 50px; height: 50px; padding: 0; border: 0; background: none; cursor: pointer; }
.cluster-ring { position: absolute; inset: 0; border-radius: 50%; box-shadow: 0 6px 18px rgba(40, 25, 10, .3); transition: transform .2s var(--ease); }
.cluster-core { position: absolute; inset: 5px; border-radius: 50%; display: grid; place-items: center; background: var(--hi); font-weight: 800; font-size: 17px; color: var(--ink); }
.cluster:hover .cluster-ring { transform: scale(1.08); }
.lot-pin { width: 22px; height: 22px; border-radius: 7px; background: var(--accent-2); border: 3px solid #fff; box-shadow: 0 6px 14px rgba(40, 25, 10, .35); }
.pin-pop { z-index: 8; }
.pin-pop .maplibregl-popup-content {
  padding: 0; color: var(--ink); overflow: hidden; border-radius: 20px;
  background: var(--pop-glass);
  -webkit-backdrop-filter: blur(var(--blur)) saturate(var(--sat)); backdrop-filter: blur(var(--blur)) saturate(var(--sat));
  border: 1px solid rgb(var(--w) / calc(.9 * var(--wk))); box-shadow: 0 18px 44px rgba(52, 34, 18, .28);
}
.pin-pop .maplibregl-popup-tip { display: none; }
.pop-card { width: 272px; }
.pop-thumb { display: block; width: 100%; height: 112px; object-fit: cover; }
.pop-body { padding: 12px 14px 14px; display: grid; gap: 6px; }
.pop-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 14px; }
.pop-body h3 { font-size: 18.5px; font-weight: 650; }
.pop-meta { font-size: 14.5px; color: var(--ink-2); display: flex; align-items: center; gap: 6px; }
.pop-meta .ic { width: 14px; height: 14px; }
.pop-extra { display: flex; align-items: center; gap: 8px; font-size: 14.5px; color: var(--ink); text-decoration: none; padding: 8px 10px; border-radius: 12px; background: rgba(230, 167, 86, .18); }
.pop-extra span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pop-extra .ic { width: 15px; height: 15px; color: var(--accent-deep); }
.lot-tag { font-weight: 800; color: var(--accent-ink); background: var(--accent); padding: 2px 8px; border-radius: 7px; }
.pin-pop .status { background: rgb(var(--ink-rgb) / .07); }

/* ---------- Files ---------- */
.verify-note { display: flex; gap: 10px; align-items: flex-start; padding: 12px 16px; border-radius: 16px; background: rgb(var(--w) / calc(.55 * var(--wk))); font-size: 15px; color: var(--ink-2); margin-bottom: 14px; }
.verify-note .ic { color: var(--good); margin-top: 1px; }
.verify-note b { color: var(--ink); }
.frow { display: grid; grid-template-columns: 40px 1fr auto auto; gap: 12px; align-items: center; padding: 11px 12px; border-bottom: 1px solid var(--line); border-radius: 12px; transition: background .4s; }
.frow:hover { background: rgb(var(--w) / calc(.4 * var(--wk))); }
.frow.hl { background: rgba(230, 167, 86, .22); box-shadow: inset 3px 0 0 var(--accent-2); }
.f-ic { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: rgb(var(--w) / calc(.7 * var(--wk))); color: var(--ink-2); position: relative; }
.f-ic.rec { background: rgba(124, 79, 192, .13); color: var(--rec-ink); }
.f-ic .ext { position: absolute; bottom: -4px; right: -6px; font-size: 10.5px; font-weight: 800; text-transform: uppercase; background: var(--hi); border-radius: 4px; padding: 1px 3px; color: var(--ink-2); box-shadow: 0 1px 3px rgba(0, 0, 0, .12); }
.f-name { min-width: 0; }
.f-name b { display: block; font-weight: 600; font-size: 15.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.f-name a { color: inherit; text-decoration: none; }
.f-name a:hover { text-decoration: underline; }
.f-name small { display: block; color: var(--ink-3); font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.verified { display: inline-flex; gap: 5px; align-items: center; font-size: 14px; font-weight: 700; color: var(--good-ink); background: rgba(35, 133, 79, .13); padding: 4px 10px 4px 8px; border-radius: 999px; white-space: nowrap; cursor: help; }
.verified .ic { width: 14px; height: 14px; }

/* ---------- Project page ---------- */
.ph { display: grid; grid-template-columns: auto 1fr auto; gap: 20px; align-items: center; }
.ph-thumb { width: 124px; height: 82px; border-radius: 16px; object-fit: cover; box-shadow: 0 0 0 3px rgb(var(--w) / calc(.85 * var(--wk))); display: block; }
.ph-title { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.ph h1 { font-size: 35px; font-weight: 650; letter-spacing: -.025em; }
.ph-sub { color: var(--ink-2); margin-top: 4px; font-size: 16px; }
.ph-sub .ic { width: 15px; height: 15px; color: var(--ink-3); vertical-align: -3px; }
.ph-actions { display: flex; gap: 10px; flex-wrap: wrap; justify-content: flex-end; }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; margin: 22px 0 20px; }
.fact { padding: 14px 16px; border-radius: var(--r-tile); background: var(--card); border: 1px solid var(--edge); min-width: 0; }
.fact .k { font-size: 14.5px; font-weight: 600; color: var(--ink-3); }
.fact .v { font-size: 23px; font-weight: 700; margin-top: 4px; letter-spacing: -.01em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fact .s { font-size: 14px; color: var(--ink-2); margin-top: 1px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fact .progress { margin-top: 10px; }
.tab-panel { animation: fade .25s var(--ease) both; }
.row-between { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.row-between h3 { font-size: 19.5px; font-weight: 650; }

.viewer { position: relative; aspect-ratio: 16 / 7.2; border-radius: 22px; overflow: hidden; background: radial-gradient(120% 90% at 50% 0%, #1c3046, #0a1220 72%); box-shadow: 0 0 0 3px rgb(var(--w) / calc(.8 * var(--wk))), 0 16px 40px rgba(40, 25, 10, .2); }
.viewer canvas { position: absolute; inset: 0; width: 100%; height: 100%; cursor: grab; touch-action: none; }
.viewer canvas:active { cursor: grabbing; }
.v-top { position: absolute; top: 14px; left: 14px; right: 14px; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; pointer-events: none; }
.v-top > * { pointer-events: auto; }
.v-top .grow { flex: 1; }
.v-badge { display: inline-flex; align-items: center; gap: 8px; height: 34px; padding: 0 12px 0 8px; border-radius: 17px; background: rgb(var(--w) / calc(.9 * var(--wk))); font-size: 14.5px; font-weight: 650; }
.v-badge .kmark img { height: 18px; }
.v-top .select { height: 34px; background-color: rgb(var(--w) / calc(.9 * var(--wk))); }
.v-note { position: absolute; left: 14px; bottom: 14px; max-width: 470px; font-size: 14.5px; color: #e9eef2; background: rgba(8, 14, 24, .72); padding: 8px 12px; border-radius: 12px; }
.v-note b { color: #f6cf91; }
.v-hint { position: absolute; right: 14px; bottom: 14px; font-size: 14px; color: #c9d3db; background: rgba(8, 14, 24, .6); padding: 6px 10px; border-radius: 10px; }
.viewer:fullscreen { border-radius: 0; aspect-ratio: auto; }
.viewer.fake-full { position: fixed; inset: 0; z-index: 90; border-radius: 0; aspect-ratio: auto; }
.v-under { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 14px; font-size: 15px; color: var(--ink-2); }
.v-under span { display: inline-flex; align-items: center; gap: 6px; }
.v-under .ic { width: 15px; height: 15px; }

.timeline { list-style: none; margin: 0; padding: 0; position: relative; }
.timeline::before { content: ''; position: absolute; left: 19px; top: 20px; bottom: 20px; width: 2px; background: linear-gradient(var(--accent-2), rgba(217, 143, 60, .1)); }
.tl { display: grid; grid-template-columns: 40px 1fr; gap: 14px; margin-bottom: 12px; position: relative; }
.tl-node { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: var(--hi); color: var(--accent-deep); box-shadow: 0 0 0 3px rgba(217, 143, 60, .35); position: relative; }
.tl-node .ic { width: 17px; height: 17px; }
.tl.next .tl-node { background: rgb(var(--w) / calc(.5 * var(--wk))); color: var(--ink-3); box-shadow: 0 0 0 2px rgb(var(--ink-rgb) / .25); }
.tl-card { padding: 14px 16px; border-radius: var(--r-tile); background: var(--card); border: 1px solid var(--edge); display: grid; grid-template-columns: 1fr auto; gap: 4px 14px; align-items: center; }
.tl.next .tl-card { background: rgb(var(--w) / calc(.25 * var(--wk))); border-style: dashed; border-color: rgb(var(--ink-rgb) / .25); }
.tl-date { font-size: 14.5px; color: var(--ink-3); font-weight: 600; display: flex; gap: 8px; align-items: center; }
.tl-card h4 { font-size: 17px; font-weight: 650; }
.tl-stat { font-size: 15px; color: var(--ink-2); }
.tl-actions { grid-column: 2; grid-row: 1 / span 4; display: flex; gap: 6px; }
/* Staff: a project's stages, one row each. */
/* Kybos staff: finding a project's address, or dropping its pin. */
.loc { display: grid; gap: 8px; }
.loc > span { font-size: 14.5px; color: var(--ink-2); font-weight: 600; }
.loc-find { display: flex; gap: 8px; }
.loc-find .input { flex: 1; min-width: 0; }
.loc-find .btn { flex: none; height: 50px; }
@media (max-width: 759px) { .loc-find .btn { padding: 0; width: 50px; } .loc-find .btn span { display: none; } }
.loc-hits { display: grid; gap: 4px; color: var(--ink-2); }
.loc-hit { display: block; width: 100%; text-align: left; padding: 10px 14px; border-radius: 14px; border: 1px solid var(--edge); background: rgb(var(--w) / calc(.6 * var(--wk))); color: var(--ink); font: inherit; cursor: pointer; }
.loc-hit:hover { background: var(--hi); }
.loc-hit b { display: block; font-size: 15px; font-weight: 600; }
.loc-hit small { display: block; color: var(--ink-3); font-size: 14px; }
.loc-map { height: 260px; border-radius: 16px; overflow: hidden; background: rgb(var(--ink-rgb) / .06); }
.loc-map.no-map { display: none; }
.loc-state { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; justify-content: space-between; color: var(--ink-2); }
.level-chips { margin-bottom: 14px; }
.level-chips .chip[aria-pressed=true] { background: var(--hot); color: var(--accent-ink); }
.pic-row { display: flex; flex-wrap: wrap; gap: 12px 16px; align-items: center; }
.pic-row > div { flex: 1; min-width: 180px; display: grid; gap: 10px; }
.pic-now { width: 168px; aspect-ratio: 16 / 10; border-radius: 14px; object-fit: cover; display: block; }
.level-note { color: var(--ink-2); margin: 2px 0 10px; }
.level-head { display: flex; flex-wrap: wrap; gap: 6px 8px; align-items: center; padding: 4px 0 10px; }
.level-head > div { flex: 1; min-width: 150px; }
.level-head b { display: block; font-size: 17px; font-weight: 650; }
.level-head small { color: var(--ink-3); font-size: 14px; }
.level-lines { height: auto; padding: 12px 16px; resize: vertical; line-height: 1.5; }
.st-row { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; padding: 10px 0; border-top: 1px solid var(--edge); }
.st-row > div { flex: 1; min-width: 160px; }
.st-row b { display: block; font-size: 15.5px; font-weight: 650; }
.st-row small { color: var(--ink-3); font-size: 14px; }
.st-add { margin-top: 12px; }
.new { font-size: 12px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--accent-ink); background: var(--accent); padding: 2px 6px; border-radius: 6px; }

.invite { display: grid; gap: 10px; }
.invite-row { display: grid; grid-template-columns: 1fr 170px auto; gap: 8px; }
.invite-row .select { height: 46px; border-radius: 16px; font-size: 15.5px; }
.invite-row .btn { height: 46px; }
.roles { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 10px; margin: 14px 0 20px; }
.role { padding: 13px 15px; border-radius: 16px; background: rgb(var(--w) / calc(.4 * var(--wk))); border: 1px solid rgb(var(--w) / calc(.7 * var(--wk))); font-size: 14.5px; color: var(--ink-2); }
.role b { display: block; color: var(--ink); font-size: 16px; margin-bottom: 3px; }
.role.on { background: var(--hi); box-shadow: inset 0 0 0 2px var(--accent-2); }
.member { display: grid; grid-template-columns: 40px 1fr 150px 140px; gap: 12px; align-items: center; padding: 11px 6px; border-bottom: 1px solid var(--line); }
.member b { font-weight: 650; }
.member small { display: block; color: var(--ink-3); font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.member .select { height: 34px; }
.you { font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; color: var(--accent-ink); background: var(--accent); padding: 1px 6px; border-radius: 5px; margin-left: 6px; }
.pill { display: inline-flex; align-items: center; gap: 6px; font-size: 14.5px; color: var(--ink-2); }
.pill.pending { color: var(--accent-deep); font-weight: 600; }
.pill .ic { width: 14px; height: 14px; }

.share-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; align-items: start; }
.share-form { display: grid; gap: 13px; }
.segbar { display: flex; gap: 6px; flex-wrap: wrap; }
.segbar label { cursor: pointer; }
.segbar input { position: absolute; opacity: 0; pointer-events: none; }
.segbar span { display: inline-flex; align-items: center; height: 40px; padding: 0 18px; border-radius: 20px; background: rgb(var(--w) / calc(.45 * var(--wk))); border: 1px solid rgb(var(--w) / calc(.8 * var(--wk))); font-size: 15px; font-weight: 600; color: var(--ink-2); }
.segbar input:checked + span { background: var(--hi); color: var(--ink); box-shadow: 0 3px 10px rgba(60, 40, 20, .12); }
.segbar input:focus-visible + span { outline: 2px solid var(--accent-deep); outline-offset: 2px; }
.check { display: flex; gap: 10px; align-items: center; font-size: 15.5px; color: var(--ink-2); cursor: pointer; }
.check input { width: 18px; height: 18px; accent-color: var(--accent-2); }
.share-out { padding: 13px; border-radius: 16px; background: rgba(230, 167, 86, .16); border: 1px solid rgba(217, 143, 60, .4); display: grid; gap: 8px; }
.link-row { display: flex; gap: 8px; align-items: center; }
.link-row code { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font: 600 15px ui-monospace, Menlo, monospace; color: var(--ink); background: rgb(var(--w) / calc(.8 * var(--wk))); padding: 10px 12px; border-radius: 12px; }
.slink { padding: 12px 0; border-bottom: 1px solid var(--line); display: grid; grid-template-columns: 1fr auto; gap: 4px 10px; }
.slink:last-child { border-bottom: 0; }
.slink b { font-weight: 650; }
.slink small { color: var(--ink-3); font-size: 14.5px; }
.slink .acts { grid-row: 1 / span 2; grid-column: 2; display: flex; gap: 6px; align-items: center; }
.slink.revoked b, .slink.revoked small { text-decoration: line-through; opacity: .6; }
.exp { color: var(--accent-deep); font-weight: 650; }

/* ---------- Billing ---------- */
.bill-grid { display: grid; grid-template-columns: 1.05fr 1fr; gap: 20px; margin-bottom: 20px; }
.plan-now .price { font-size: 43px; font-weight: 700; letter-spacing: -.025em; margin: 6px 0 2px; }
.plan-now .price small, .plan .price small { font-size: 15px; font-weight: 500; color: var(--ink-2); letter-spacing: 0; }
.eyebrow { font-size: 14px; font-weight: 700; color: var(--ink-3); }
.ticks { list-style: none; margin: 12px 0 16px; padding: 0; display: grid; gap: 7px; font-size: 15.5px; color: var(--ink-2); }
.ticks li { display: flex; gap: 8px; align-items: flex-start; }
.ticks .ic { width: 16px; height: 16px; color: var(--good); margin-top: 1px; }
.btn-row { display: flex; gap: 8px; flex-wrap: wrap; }
.meter { margin-top: 14px; }
.meter-top { display: flex; justify-content: space-between; font-size: 15px; color: var(--ink-2); margin-bottom: 7px; }
.meter-top b { color: var(--ink); font-weight: 650; }
.meter .progress { height: 9px; }
.warn { display: flex; gap: 8px; align-items: flex-start; margin-top: 16px; font-size: 15px; color: var(--bad-ink); background: rgba(194, 65, 43, .1); padding: 10px 12px; border-radius: 12px; }
.warn .ic { width: 16px; height: 16px; margin-top: 1px; }
.section { margin-bottom: 20px; }
.inv { font-size: 14px; font-weight: 700; padding: 3px 9px; border-radius: 999px; white-space: nowrap; display: inline-flex; align-items: center; gap: 6px; }
.inv::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.inv.Due { color: var(--bad-ink); background: rgba(194, 65, 43, .12); }
.inv.Open { color: var(--accent-deep); background: rgba(217, 143, 60, .15); }
.inv.Paid { color: var(--good-ink); background: rgba(35, 133, 79, .12); }
.plans { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 12px; }
.plan { padding: 20px; border-radius: var(--r-card); background: var(--card); border: 1px solid var(--edge); display: flex; flex-direction: column; box-shadow: var(--shadow-card); }
.plan.reco { background: rgb(var(--w) / calc(.7 * var(--wk))); box-shadow: inset 0 0 0 2px var(--accent-2), var(--shadow-card); }
.plan h4 { font-size: 19.5px; font-weight: 700; display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.plan .price { font-size: 30px; font-weight: 750; margin-top: 8px; }
.plan .ticks { flex: 1; }
.tag { font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; padding: 3px 8px; border-radius: 7px; background: rgb(var(--ink-rgb) / .1); color: var(--ink-2); }
.tag.hot { background: var(--accent); color: var(--accent-ink); }
.addons { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px; margin-top: 10px; }
.addon { padding: 14px 16px; border-radius: 16px; background: rgb(var(--w) / calc(.45 * var(--wk))); font-size: 15px; color: var(--ink-2); }
.addon b { display: block; color: var(--ink); font-size: 16px; }
.addon .p { color: var(--accent-deep); font-weight: 700; margin-top: 4px; display: block; }

/* ---------- Sign-in ---------- */
.signin { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; padding: 20px; overflow: auto; }
body:not([data-view=signin]) .signin { display: none; }
body[data-view=signin] .topbar, body[data-view=signin] .rail, body[data-view=signin] .window, body[data-view=signin] .tabbar { display: none; }
/* The card has two corners cut away, with a small pane of glass sitting in each gap. */
.si-wrap { position: relative; width: min(460px, 100%); margin: auto; --cut: 42px; animation: rise .5s var(--ease) both; }
.signin-card { position: relative; padding: 34px 32px 22px; border-radius: 30px; clip-path: polygon(var(--cut) 0, 100% 0, 100% calc(100% - var(--cut)), calc(100% - var(--cut)) 100%, 0 100%, 0 var(--cut)); }
.si-notch { position: absolute; width: calc(var(--cut) - 8px); height: calc(var(--cut) - 8px); background: var(--bar); border: 1px solid var(--edge); -webkit-backdrop-filter: blur(var(--blur)) saturate(var(--sat)); backdrop-filter: blur(var(--blur)) saturate(var(--sat)); box-shadow: var(--shadow-pill); }
.si-notch.a { top: 0; left: 0; border-radius: 12px 4px 26px 4px; clip-path: polygon(0 0, 100% 0, 0 100%); }
.si-notch.b { bottom: 0; right: 0; border-radius: 26px 4px 12px 4px; clip-path: polygon(100% 0, 100% 100%, 0 100%); }
#si-step { display: grid; }
.signin-card h1 em { font-style: normal; color: var(--accent-2); }
html[data-theme=dark] .signin-card h1 em { color: var(--accent); }
.signin-form { display: grid; gap: 12px; }
.si-input { position: relative; display: block; }
.si-input > .ic { position: absolute; left: 15px; top: 15px; width: 19px; height: 19px; color: var(--ink-3); pointer-events: none; }
.signin .si-input .input[name=password], .signin .si-input .input[name=again] { padding-right: 48px; }
.si-eye { position: absolute; right: 6px; top: 6px; width: 38px; height: 38px; display: grid; place-items: center; border: 0; border-radius: 12px; background: none; color: var(--ink-3); cursor: pointer; }
.si-eye:hover, .si-eye[aria-pressed=true] { color: var(--ink); background: rgb(var(--ink-rgb) / .08); }
.si-eye .ic { width: 19px; height: 19px; }
.si-row { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.si-link { display: inline-flex; align-items: center; gap: 5px; padding: 2px 0; border: 0; background: none; font: inherit; font-size: 14.5px; font-weight: 600; color: var(--accent-deep); cursor: pointer; text-decoration: none; }
.si-link:hover { text-decoration: underline; }
.si-link .ic { width: 15px; height: 15px; }
#si-step > .si-link { justify-self: center; margin-top: 16px; }
.si-go { width: 100%; justify-content: center; gap: 8px; margin-top: 4px; box-shadow: 0 10px 26px rgba(217, 143, 60, .34); }
.si-go:disabled { opacity: .65; cursor: progress; }
.si-go .ic { width: 18px; height: 18px; }
.si-err { padding: 10px 12px; border-radius: 12px; font-size: 14.5px; color: var(--bad-ink); background: color-mix(in srgb, var(--bad-ink) 11%, transparent); }
.si-rule { font-size: 14px; color: var(--ink-3); margin-top: -4px; }
.signin-card .brand { display: flex; align-items: center; gap: 10px; font-size: 18.5px; }
.signin-card .brand b { font-weight: 700; }
.signin-card .sep { color: var(--accent-2); margin: 0 6px; font-weight: 800; }
.signin-card h1 { font-size: 30px; font-weight: 700; letter-spacing: -.025em; margin: 22px 0 6px; }
.signin-card .lede { color: var(--ink-2); margin-bottom: 22px; }
.btn.big { height: 50px; font-size: 17px; border-radius: 25px; }
.divider { display: flex; align-items: center; gap: 12px; color: var(--ink-3); font-size: 14.5px; margin: 16px 0; }
.divider::before, .divider::after { content: ''; flex: 1; height: 1px; background: var(--line); }
.oauth { display: grid; gap: 10px; }
.fineprint { margin-top: 18px; font-size: 14.5px; color: var(--ink-3); text-align: center; line-height: 1.5; }
.signin-sent { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: 16px; background: rgba(35, 133, 79, .12); color: var(--ink); font-size: 15px; }
.signin-sent .ic { color: var(--good); margin-top: 1px; }
.signin-foot { margin-top: 16px; display: flex; justify-content: space-between; font-size: 14.5px; color: var(--ink-3); }
.signin .input { height: 50px; border-radius: 25px; padding: 0 20px 0 44px; }

/* ---------- Modal and toast ---------- */
#modal-root { position: fixed; inset: 0; z-index: 60; display: grid; place-items: center; padding: 20px; }
.modal-back { position: absolute; inset: 0; background: rgba(48, 32, 18, .38); animation: fade .2s both; }
.modal { position: relative; width: min(640px, 100%); max-height: calc(100vh - 40px); display: flex; flex-direction: column; background: var(--pop); border: 1px solid var(--edge); border-radius: 30px; box-shadow: 0 30px 80px rgba(52, 34, 18, .35); animation: rise .3s var(--ease) both; }
.modal header { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; padding: 22px 22px 6px; }
.modal header h2 { font-size: 24px; font-weight: 700; }
.modal header p { color: var(--ink-2); font-size: 15px; margin-top: 3px; }
.m-body { padding: 8px 22px 16px; overflow: auto; display: grid; grid-auto-rows: max-content; gap: 12px; }
.modal footer { padding: 14px 22px; border-top: 1px solid var(--line); display: flex; gap: 10px; justify-content: flex-end; align-items: center; flex-wrap: wrap; }
.modal footer .grow { flex: 1; font-size: 14.5px; color: var(--ink-3); }
.opts { display: grid; gap: 8px; }
.opt { display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: center; padding: 13px 15px; border-radius: 16px; background: rgb(var(--w) / calc(.6 * var(--wk))); border: 1px solid rgb(var(--ink-rgb) / .1); cursor: pointer; }
.opt:hover { background: var(--hi); }
.opt:has(input:checked) { background: var(--hi); box-shadow: inset 0 0 0 2px var(--accent-2); border-color: transparent; }
.opt input { width: 18px; height: 18px; accent-color: var(--accent-2); margin: 0; }
.opt b { display: flex; gap: 8px; align-items: center; font-weight: 650; }
.opt small { display: block; color: var(--ink-3); font-size: 14px; }
.opt .price { text-align: right; font-weight: 700; white-space: nowrap; }
.opt .price small { font-weight: 500; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.modal .select { height: 46px; border-radius: 16px; font-size: 15.5px; }
.sum { padding: 13px 15px; border-radius: 16px; background: rgb(var(--w) / calc(.7 * var(--wk))); display: grid; gap: 4px; }
.sum-row { display: flex; justify-content: space-between; gap: 10px; font-size: 15px; color: var(--ink-2); }
.sum-row.total { font-size: 19.5px; color: var(--ink); font-weight: 700; padding-top: 6px; margin-top: 4px; border-top: 1px solid var(--line); }
.done { text-align: center; padding: 16px 6px 6px; display: grid; gap: 8px; justify-items: center; }
.done .big-ic { width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; background: rgba(35, 133, 79, .14); color: var(--good); }
.done .big-ic .ic { width: 26px; height: 26px; }
.invite-text { width: 100%; margin: 6px 0 0; padding: 12px 14px; border-radius: 14px; background: rgb(var(--ink-rgb) / .07); color: var(--ink); font: 14.5px/1.5 Inter, system-ui, sans-serif; text-align: left; white-space: pre-wrap; overflow-wrap: anywhere; user-select: all; }
.done h3 { font-size: 22px; }
.done p { color: var(--ink-2); max-width: 420px; }
#toast-root { position: fixed; z-index: 70; left: 50%; bottom: 112px; transform: translateX(-50%); display: grid; gap: 8px; justify-items: center; pointer-events: none; }
.toast { display: flex; gap: 8px; align-items: center; padding: 11px 16px; border-radius: 16px; background: rgba(34, 28, 23, .94); color: #fff; box-shadow: 0 12px 30px rgba(40, 25, 10, .3); font-size: 15px; animation: rise .25s var(--ease) both; max-width: min(92vw, 480px); }
.toast .ic { color: var(--accent); }

/* ---------- 3D tab: frame bar, live sites, tours ---------- */
.vbar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; }
.vbar .grow { flex: 1; }
.vbar .select { height: 38px; }
.v-title { font-size: 16.5px; font-weight: 650; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.viewer.embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; background: #0a1220; }
.viewer.poster { background-size: cover; background-position: center; }
.poster-cta { position: absolute; right: 16px; top: 50%; transform: translateY(-50%); width: min(420px, calc(100% - 32px)); display: grid; gap: 6px; padding: 16px 18px; border-radius: 18px; background: rgba(6, 12, 22, .78); color: #f1ece5; }
.poster-cta b { font-size: 19.5px; }
.poster-cta span { font-size: 14.5px; color: #d6cec4; }
.poster-cta .btn-row { margin-top: 6px; }
.poster-cta .btn:not(.hot) { background: rgba(255, 255, 255, .12); border-color: rgba(255, 255, 255, .2); color: #f1ece5; }
body.fake-full .vbar { position: fixed; z-index: 92; top: env(safe-area-inset-top, 0px); left: 0; right: 0; margin: 0; padding: 10px max(12px, env(safe-area-inset-right, 0px)) 10px max(12px, env(safe-area-inset-left, 0px)); background: rgba(6, 12, 22, .85); color: #f1ece5; }
.tours { margin-top: 22px; }
.tour-filter { margin: -4px 0 12px; }
.tour-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(440px, 1fr)); gap: 10px; }
.tour { display: grid; grid-template-columns: 44px 1fr auto; gap: 12px; align-items: center; padding: 12px 14px; border-radius: var(--r-tile); background: var(--card); border: 1px solid var(--edge); color: var(--ink); text-decoration: none; }
.tour.on { box-shadow: inset 0 0 0 2px var(--accent-2); }
.tour.site:hover { background: var(--card-2); }
.tour-ic { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: rgb(var(--ink-rgb) / .07); color: var(--accent-deep); }
.tour b { display: block; font-size: 16px; font-weight: 650; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tour small { display: block; font-size: 14px; color: var(--ink-3); }
.tour .prov { font-weight: 700; color: var(--ink-2); }
.tour-acts { display: flex; gap: 6px; align-items: center; color: var(--ink-3); }
.ex-tag { display: inline-flex; align-items: center; height: 22px; padding: 0 8px; margin-left: 6px; border-radius: 7px; font-size: 12px; font-weight: 800; letter-spacing: .02em; vertical-align: middle; color: var(--accent-ink); background: var(--accent); }
.ex-note { display: flex; gap: 8px; align-items: flex-start; margin-top: 8px; font-size: 14.5px; color: var(--ink-2); max-width: 70ch; }
.ex-note .ic { width: 17px; height: 17px; flex: none; margin-top: 2px; color: var(--accent-deep); }
.field-err { font-size: 14.5px; color: var(--bad-ink); margin-top: -4px; }

/* ---------- Uploads ---------- */
.drop { display: grid; justify-items: center; gap: 8px; text-align: center; padding: 22px 16px; border-radius: 20px; border: 2px dashed color-mix(in srgb, var(--accent-deep) 35%, transparent); background: rgb(var(--w) / calc(.5 * var(--wk))); transition: background .2s, border-color .2s; }
.drop.over { background: rgba(230, 167, 86, .16); border-color: var(--accent-2); }
.drop.busy { opacity: .55; pointer-events: none; }
.drop b { font-size: 17px; }
.drop p { max-width: 430px; }
.drop-ic { width: 48px; height: 48px; border-radius: 50%; display: grid; place-items: center; background: var(--hi); color: var(--accent-deep); box-shadow: 0 4px 12px rgba(60, 40, 20, .14); }
.only-touch { display: none !important; }
@media (pointer: coarse) { .only-touch { display: inline-flex !important; } }
.upl-list { display: grid; gap: 6px; max-height: 280px; overflow: auto; }
.upl-list:empty { display: none; }
.upl-row { display: grid; grid-template-columns: 46px 1fr 132px 36px; gap: 10px; align-items: center; padding: 8px; border-radius: 16px; background: rgb(var(--w) / calc(.7 * var(--wk))); }
.upl-thumb { width: 46px; height: 46px; border-radius: 12px; object-fit: cover; display: grid; place-items: center; align-content: center; gap: 1px; background: rgb(var(--ink-rgb) / .07); color: var(--ink-2); overflow: hidden; }
.upl-thumb .ic { width: 16px; height: 16px; }
.upl-thumb i { font-style: normal; font-size: 10.5px; font-weight: 800; text-transform: uppercase; }
.upl-row b { display: block; font-size: 15px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.upl-row small { display: flex; align-items: center; gap: 4px; font-size: 14px; color: var(--ink-3); }
.upl-row small .ic { width: 13px; height: 13px; }
.upl-row.done .upl-state { color: var(--good-ink); font-weight: 650; display: inline-flex; align-items: center; gap: 3px; }
.upl-row .progress { margin-top: 6px; height: 4px; }
.upl-row .select { height: 34px; width: 100%; font-size: 14.5px; }
.proto-note { display: flex; gap: 8px; align-items: flex-start; font-size: 14.5px; color: var(--ink-2); background: rgb(var(--ink-rgb) / .06); padding: 10px 12px; border-radius: 12px; }
.proto-note .ic { width: 15px; height: 15px; margin-top: 1px; flex: none; }
/* Under a window's Client box: who will see the project with the client picked (no client yet: only Kybos). */
.client-note { display: flex; gap: 8px; align-items: flex-start; margin: -4px 0 0; font-size: 14px; color: var(--ink-2); }
.client-note .ic { width: 15px; height: 15px; margin-top: 2px; flex: none; }
.upl { display: inline-flex; gap: 5px; align-items: center; font-size: 14px; font-weight: 700; color: var(--ink-2); background: rgb(var(--ink-rgb) / .08); padding: 4px 10px 4px 8px; border-radius: 999px; white-space: nowrap; }
.upl.mine { color: var(--accent-deep); background: rgba(230, 167, 86, .18); }
.upl .ic { width: 14px; height: 14px; }
.f-ic.photo { padding: 0; border: 0; cursor: zoom-in; overflow: hidden; }
.f-ic.photo img { width: 100%; height: 100%; object-fit: cover; }
.linkish { border: 0; background: none; padding: 0; font: inherit; color: inherit; cursor: pointer; text-align: left; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.linkish:hover { text-decoration: underline; }
.drop-overlay { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; background: rgba(48, 32, 18, .28); pointer-events: none; }
.drop-card { display: grid; justify-items: center; gap: 8px; padding: 34px 48px; border-radius: 32px; border: 2px dashed var(--accent-2); text-align: center; }
.drop-card b { font-size: 23px; }
.drop-card span:last-child { color: var(--ink-2); }
.modal.wide { width: min(880px, 100%); }
.preview { display: grid; gap: 10px; }
.preview img { width: 100%; max-height: 62vh; object-fit: contain; border-radius: 16px; background: #0b1220; }
.preview iframe { width: 100%; height: 62vh; border: 0; border-radius: 14px; background: #fff; }
.no-preview { display: grid; justify-items: center; gap: 6px; padding: 40px 10px; border-radius: 16px; background: rgb(var(--ink-rgb) / .05); }
.no-preview .ic { width: 34px; height: 34px; color: var(--ink-3); }
.plus-wrap { position: relative; margin-left: 4px; }
.menu.up { top: auto; bottom: calc(100% + 12px); right: 0; width: 240px; }

/* ---------- Appearance switch ---------- */
.theme-seg { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; padding: 4px; margin: 4px 6px 6px; border-radius: 14px; background: rgb(var(--ink-rgb) / .07); }
.theme-seg button { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 34px; border: 0; border-radius: 10px; background: none; color: var(--ink-2); font-size: 14.5px; font-weight: 600; cursor: pointer; }
.theme-seg button .ic { width: 15px; height: 15px; }
.theme-seg button[aria-pressed=true] { background: var(--hi); color: var(--ink); box-shadow: 0 2px 8px rgba(0, 0, 0, .12); }

/* ---------- Night mode: same layout, navy glass, Site Atlas orange ---------- */
html[data-theme=dark] {
  --ink: #f6f0e8;
  --ink-2: #ded5ca;
  --ink-3: #c8bdb1;
  --accent-deep: #f2b96e;
  --window: rgba(13, 10, 8, .3);
  --bar: rgba(24, 19, 15, .6);
  --card: rgba(26, 21, 17, .62);
  --card-2: rgba(44, 36, 29, .6);
  --pop: rgba(26, 21, 17, .9);
  --pop-glass: rgba(26, 21, 17, .82);
  --panel: rgba(24, 19, 15, .92);
  --edge: rgba(255, 240, 222, .14);
  --line: rgba(255, 240, 222, .12);
  --track: rgba(255, 240, 222, .14);
  --solid-window: #15110d;
  --solid-bar: #1c1712;
  --shadow-window: 0 30px 80px rgba(0, 0, 0, .5);
  --shadow-card: inset 0 1px 0 rgba(255, 240, 222, .1), 0 1px 2px rgba(0, 0, 0, .2), 0 18px 44px rgba(0, 0, 0, .34);
  --shadow-pill: 0 10px 30px rgba(0, 0, 0, .4);
  --hi: #322920;
  --hi-hover: #3d3228;
  --wk: .14;
  --ink-rgb: 240 228 214;
  --map-bg: #120e0b;
  --backdrop: #0e0b09;
  --on-room: 0 0 16px rgba(12, 9, 7, .9), 0 0 3px rgba(12, 9, 7, .6);
  --btn-strong: #f6f0e8;
  --btn-strong-ink: #1b150f;
  --good: #6fe39a;
  --good-ink: #9af2bc;
  --bad-ink: #ffb4a6;
  --rec-ink: #d8bdff;
  --st-presale: #8cc8ff;
  --st-preconstruction: #7fdcd2;
  --st-construction: #f0b46a;
  --st-handover: #c9a2ff;
  --st-complete: #6fe39a;
  --st-hold: #ff8f7a;
  --drone: #cc8031;
  --laser: #4b88dd;
  --chev: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23d6cec4' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  color-scheme: dark;
}
html[data-theme=dark] .backdrop::after { background: linear-gradient(rgba(12, 9, 7, .36), rgba(12, 9, 7, .36)), radial-gradient(120% 95% at 50% 40%, transparent 45%, rgba(8, 6, 4, .55) 100%); }
html[data-theme=dark] .tile.hot, html[data-theme=dark] .btn.hot { color: var(--accent-ink); }
html[data-theme=dark] .round .badge { box-shadow: 0 0 0 2px var(--hi); }
html[data-theme=dark] .modal-back { background: rgba(2, 6, 12, .55); }
html[data-theme=dark] .drop-overlay { background: rgba(2, 6, 12, .45); }
html[data-theme=dark] .pin-dot { box-shadow: 0 4px 12px rgba(0, 0, 0, .55); }
html[data-theme=dark] .maplibregl-ctrl-attrib-button { filter: invert(.85); }

/* ---------- Medium screens ---------- */
@media (max-width: 1240px) {
  .row1 { grid-template-columns: 1fr 1fr; }
  .row1 .map-card { grid-column: 1 / -1; }
  .row1 .map-card .map-slot { min-height: 320px; }
  .row2 { grid-template-columns: 1fr; }
  .row2 .col { grid-template-columns: 1fr 1fr; }
  .plans { grid-template-columns: 1fr; }
  .hello small { display: none; }
  .brand-tb .product { display: none; }
}
@media (max-width: 1000px) {
  .sample-pill { display: none; }
  .tl-card { grid-template-columns: 1fr; }
  .tl-actions { grid-column: 1; grid-row: auto; margin-top: 6px; }
  .bill-grid, .share-grid, .priv-grid, .a-grid, .d-notify { grid-template-columns: 1fr; }
  .rq-board { grid-template-columns: 1fr 1fr; }
  .ph { grid-template-columns: auto 1fr; }
  .ph-actions { grid-column: 1 / -1; justify-content: flex-start; }
  .pgrid[data-mode=list] .pc-body { grid-template-columns: 1fr; gap: 6px; }
}

/* ---------- Phones: compact bar, sections at the bottom, list as a sheet ---------- */
@media (max-width: 759px) {
  :root { --win-left: 8px; --win-top: 74px; --r-window: 26px; --r-card: 20px; }
  .topbar { top: 8px; left: 8px; right: 8px; height: 58px; padding: 0 6px; gap: 6px; border-radius: 28px; }
  .brand-tb { padding: 0 2px 0 6px; }
  .brand-tb .klogo { display: none; }
  .brand-tb .kmark { display: inline-flex; }
  .brand-tb .kmark img { height: 30px; }
  .hello { padding: 0; }
  .hello .avatar { width: 40px; height: 40px; }
  .hello-text { display: none; }
  .only-phone { display: inline-grid !important; }
  .tb-actions { margin-left: auto; }
  .round { width: 42px; height: 42px; }
  .ask { display: none; position: absolute; inset: 6px 6px auto 6px; max-width: none; margin: 0; }
  body.searching .ask { display: flex; gap: 4px; align-items: center; }
  body.searching .ask-field { flex: 1; }
  body.searching .ask .search-back { display: inline-grid; }
  body.searching .hello, body.searching .tb-actions { visibility: hidden; }
  .search-pop { left: -6px; right: -6px; top: calc(100% + 12px); max-height: 66vh; }
  .kbd, .sr-foot { display: none; }
  .menu, .news-pop { position: fixed; top: 72px; left: 8px; right: 8px; width: auto; }
  .rail { display: none; }
  .window { right: 8px; bottom: 8px; }
  .window-scroll { padding: 20px 14px 116px; }
  .page-head h1 { font-size: 29px; }
  .row1, .row2, .row2 .col { grid-template-columns: 1fr; }
  .row1 .map-card .map-slot { min-height: 280px; }
  .big { font-size: 35px; }
  .stats { gap: 10px; }
  .tile { min-height: 128px; padding: 12px 14px; }
  .tile .v { font-size: 28px; }
  .tabbar { left: 14px; right: 14px; bottom: 16px; transform: none; max-width: none; justify-content: center; padding: 5px; }
  .tabbar .items { width: 100%; justify-content: space-between; }
  .tabbar a { flex-direction: column; gap: 2px; height: 56px; padding: 0 6px; font-size: 12px; border-radius: 18px; flex: 1; justify-content: center; }
  .tabbar .ic { width: 19px; height: 19px; }
  .tabbar .plus { display: none; }
  .subnav-inline { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin: -4px -14px 16px; padding: 4px 14px; }
  .subnav-inline::-webkit-scrollbar { display: none; }
  .subnav-inline .chip { flex: none; }
  .toolbar .grow { display: none; }
  .pgrid { grid-template-columns: 1fr; gap: 12px; }
  .portfolio .btn-row { grid-template-columns: 1fr; }
  .tile .v.sm { font-size: 21px; }
  .tile .t-foot { flex-wrap: wrap; }
  .pgrid[data-mode=list] .pcard { grid-template-columns: 96px 1fr; }
  .pc-body { padding: 10px 11px 12px; }
  .pc-body h3 { font-size: 15.5px; }

  .map-list {
    top: auto; left: 0; right: 0; bottom: 0; width: auto; height: calc(100% - 70px);
    border-radius: 24px 24px 0 0; padding-bottom: 86px;
    transform: translateY(var(--sheet-y, calc(100% - var(--peek) - 86px)));
    transition: transform .38s var(--ease);
  }
  .map-list.dragging { transition: none; }
  .sheet-grab { display: grid; place-items: center; height: 22px; flex: none; cursor: grab; touch-action: none; }
  .sheet-grab span { width: 42px; height: 5px; border-radius: 3px; background: rgb(var(--ink-rgb) / .3); }
  .map-list .ml-head { padding: 2px 16px 10px; touch-action: none; }
  .legend { display: none; }
  .map-ctrls { top: 12px; right: 12px; }
  .cap3d-chip { top: 12px; left: 12px; right: 70px; max-width: none; flex-wrap: wrap; gap: 8px; }
  .mapview .maplibregl-ctrl-bottom-right { bottom: calc(var(--peek) + 92px); }

  .ph { grid-template-columns: 72px 1fr; gap: 12px; }
  .ph-thumb { width: 72px; height: 56px; border-radius: 12px; }
  .ph h1 { font-size: 25.5px; }
  .ph-actions { display: grid; grid-template-columns: 1fr; }
  .ph-actions .btn { width: 100%; }
  .facts { grid-template-columns: 1fr 1fr; gap: 10px; margin: 16px 0; }
  .fact .v { font-size: 19px; }
  .fact .s { white-space: normal; }
  .viewer { aspect-ratio: 1 / 1.08; }
  .v-badge { display: none; }
  .v-top .select { max-width: calc(100% - 52px); }
  #fs-btn span { display: none; }
  #fs-btn { width: 34px; padding: 0; }
  .v-note { right: 14px; max-width: none; font-size: 13px; padding: 6px 10px; }
  .v-hint { display: none; }
  .frow { grid-template-columns: 36px 1fr auto; }
  .frow .f-tags { grid-column: 2; grid-row: 2; justify-content: flex-start; }
  .srow { grid-template-columns: 36px 1fr; }
  .srow .share-chip { grid-column: 2; justify-self: start; }
  .lv-explain { grid-template-columns: 1fr 1fr; }
  .stats.a-stats { grid-template-columns: 1fr 1fr; }
  .role-pill { display: none; }
  .viewas-pill span { display: none; }
  .avatar.big-av { width: 60px; height: 60px; font-size: 21px; border-radius: 16px; }
  .klog li { flex-direction: column; gap: 2px; }
  .frow .icon-btn { grid-column: 3; grid-row: 1 / span 2; }
  .f-ic { width: 36px; height: 36px; }
  .invite-row { grid-template-columns: 1fr 1fr; }
  .invite-row .input { grid-column: 1 / -1; }
  .member { grid-template-columns: 40px 1fr; }
  .member .select, .member .pill { grid-column: 2; }
  .two { grid-template-columns: 1fr; }
  .dk-list { grid-template-columns: 1fr; }
  .rq-board { grid-template-columns: 1fr; }
  .rq-dl { grid-template-columns: 1fr; gap: 2px; }
  .att { grid-template-columns: 36px 1fr; }
  .att .btn { grid-column: 2; justify-self: start; }
  .rq-panel .opt { grid-template-columns: auto 1fr; }
  .rq-panel .opt .price { grid-column: 2; text-align: left; white-space: normal; }
  .rq-dl dd { margin-bottom: 10px; }
  .steps li { padding: 0 10px 0 6px; font-size: 13.5px; }
  .upl-row { grid-template-columns: 42px 1fr 36px; }
  .tour-grid { grid-template-columns: 1fr; }
  .tour { grid-template-columns: 40px 1fr; }
  .tour-acts { grid-column: 2; }
  .poster-cta { left: 10px; right: 10px; top: auto; bottom: 10px; transform: none; width: auto; padding: 12px 14px; }
  .vbar .v-title { flex-basis: 100%; order: 3; }
  .upl-row label { grid-column: 2; }
  .upl-row .icon-btn { grid-column: 3; grid-row: 1; }
  .upl-row .upl-thumb { width: 42px; height: 42px; }
  #modal-root { place-items: end center; padding: 0; }
  .modal { width: 100%; max-height: 92vh; border-radius: 26px 26px 0 0; }
  .modal footer .grow { flex-basis: 100%; }
  #toast-root { bottom: 92px; }
}

/* ---------- Reduced motion: system setting, or the switch in the account menu ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
html.still *, html.still *::before, html.still *::after { animation: none !important; transition: none !important; }

/* ---------- The Portal as a Home Screen app ---------- */
.install-tip { display: flex; align-items: center; gap: 4px; padding: 8px 6px 8px 8px; margin: 0 0 16px; }
.install-tip .it-open { flex: 1; min-width: 0; display: flex; align-items: center; gap: 10px; padding: 0; border: 0; background: none; color: var(--ink); font: inherit; text-align: left; cursor: pointer; }
.install-tip img { width: 36px; height: 36px; border-radius: 9px; flex: none; display: block; box-shadow: 0 2px 6px rgba(60, 40, 20, .16); }
.install-tip .it-open span { min-width: 0; }
.install-tip b { display: block; font-size: 14.5px; line-height: 1.25; }
.install-tip small { display: block; color: var(--ink-2); font-size: 13px; margin-top: 1px; }
.install-tip .icon-btn { flex: none; }
.install-steps { margin: 0 0 12px; padding: 0; list-style: none; counter-reset: st; display: grid; gap: 12px; }
.install-steps li { counter-increment: st; display: grid; grid-template-columns: 30px 1fr; gap: 10px; align-items: start; line-height: 1.45; }
.install-steps li::before { content: counter(st); width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: 14px; background: var(--accent); color: var(--accent-ink); }
.install-steps .ic { width: 16px; height: 16px; vertical-align: -3px; }
/* Phones and tablets zoom the whole page in when a text box's text is under 16px (the labels around the boxes are
   14.5px, and the boxes take their size from them). 16px on touch screens keeps the page still while typing. */
@media (pointer: coarse) {
  input:not([type=checkbox]):not([type=radio]):not([type=range]), select, textarea { font-size: max(16px, 1em); }
}
/* Opened from the Home Screen: the bottom bar stays clear of the iPhone's home bar. */
@media (display-mode: standalone) and (max-width: 759px) {
  .tabbar { bottom: max(16px, calc(env(safe-area-inset-bottom, 0px) + 6px)); }
  .window-scroll { padding-bottom: calc(116px + env(safe-area-inset-bottom, 0px)); }
}

/* ---------- Staff lists: ticking clients (archive, bring back, delete) and filtering projects ---------- */
.a-list-tools { display: flex; gap: 12px; align-items: center; justify-content: space-between; flex-wrap: wrap; margin: 0 0 12px; min-height: 36px; }
.a-list-tools .o-chips { display: flex; gap: 8px; flex-wrap: wrap; }
.a-selbar { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; font-size: 14px; }
.a-selbar:empty { display: none; }
.a-selbar b { margin-right: 4px; }
.tbl .sel-cell { width: 44px; padding-right: 0; }
.tbl .sel-cell input { width: 18px; height: 18px; accent-color: var(--accent-2); cursor: pointer; vertical-align: middle; }
.tbl tr.picked td { background: rgb(var(--w) / calc(.5 * var(--wk))); }
.btn.danger { background: #b5402a; border-color: #b5402a; color: #fff; }
.btn.danger:hover { background: #9b2f1d; border-color: #9b2f1d; }
.a-kept { margin: 0; padding-left: 18px; display: grid; gap: 6px; }
.ap-filters { display: flex; flex-wrap: wrap; gap: 10px 12px; align-items: flex-end; padding: 14px 16px; margin-bottom: 14px; }
.ap-filters .ap-q { flex: 1 1 240px; height: 38px; }
.ap-f { display: grid; gap: 4px; font-size: 12px; font-weight: 600; color: var(--ink-3); }
.ap-f .select { height: 38px; min-width: 130px; max-width: 220px; font-size: 14px; }
.ap-clear { align-self: center; }
@media (max-width: 640px) { .ap-f { flex: 1 1 calc(50% - 6px); } .ap-f .select { max-width: none; width: 100%; } }

/* ---------- Deeper glass and motion (chosen 07-11-2026) ----------
   Frostier panes with a light sheen at the top and a bright top edge, small cards floating on a soft shadow, a gentle
   lift under the pointer, and pages that arrive with a soft blur (js/app.js pageEnter: only when going to another page,
   never when a list is redrawn). Each pane fades on its own: fading a container would switch off the blur of every pane
   inside it while it plays. Reduce motion (or the system setting) keeps everything still. */
:root {
  --blur: 36px; --sat: 165%;
  --sheen: linear-gradient(180deg, rgb(255 255 255 / .3), rgb(255 255 255 / .06) 42%, rgb(255 255 255 / 0) 70%);
  --edge-hi: rgba(255, 255, 255, .95);
  --float: inset 0 1px 0 var(--edge-hi), 0 1px 2px rgba(64, 42, 20, .05), 0 10px 26px rgba(64, 42, 20, .09);
  --lift: inset 0 1px 0 var(--edge-hi), 0 2px 6px rgba(64, 42, 20, .07), 0 24px 54px rgba(64, 42, 20, .19);
}
html[data-theme=dark] {
  --sheen: linear-gradient(180deg, rgb(255 240 222 / .08), rgb(255 240 222 / .015) 42%, rgb(255 240 222 / 0) 70%);
  --edge-hi: rgba(255, 240, 222, .2);
  --float: inset 0 1px 0 var(--edge-hi), 0 10px 26px rgba(0, 0, 0, .32);
  --lift: inset 0 1px 0 var(--edge-hi), 0 24px 54px rgba(0, 0, 0, .55);
}
.card, .fact, .tile, .pcard, .lv-tile { background-image: var(--sheen); }
.card { box-shadow: inset 0 1px 0 var(--edge-hi), 0 1px 2px rgba(64, 42, 20, .05), 0 18px 44px rgba(64, 42, 20, .14); }
html[data-theme=dark] .card { box-shadow: inset 0 1px 0 var(--edge-hi), 0 18px 44px rgba(0, 0, 0, .45); }
.fact, .tile, .lv-tile { box-shadow: var(--float); }
@media (hover: hover) and (prefers-reduced-motion: no-preference) {
  .fact, .tile, .lv-tile, .pcard { transition: transform .3s var(--ease), box-shadow .3s var(--ease), background-color .2s; }
  .fact:hover, .tile:hover, .lv-tile:hover, .pcard:hover { transform: translateY(-4px); box-shadow: var(--lift); }
}
@media (prefers-reduced-motion: no-preference) {
  body.page-enter .view-in :is(.page-head, .card, .fact, .pcard, .tile) { animation: glass-in .55s var(--ease) both; }
  body.page-enter .view-in :is(.card, .fact, .pcard, .tile) :is(.card, .fact, .pcard, .tile) { animation: none; }
}
@keyframes glass-in { from { opacity: 0; filter: blur(10px); transform: translateY(12px) scale(.985); } to { opacity: 1; filter: none; transform: none; } }

/* ---------- The sidebar (chosen 07-11-2026) ----------
   One tall pane of glass from top to bottom: the Kybos mark, round buttons that glow softly under the pointer, a white
   disc for the current page, dark name labels, small amber badges, and the look and sign-out buttons at the foot. */
.rail { top: 18px; bottom: 24px; transform: none; padding: 12px 0 14px; border-radius: 34px; gap: 8px; justify-content: flex-start; }
.rail .rail-fill { flex: 1 1 auto; min-height: 8px; }
.rail a, .rail button { background: rgb(var(--w) / calc(.2 * var(--wk))); box-shadow: inset 0 0 0 1px rgb(var(--w) / calc(.35 * var(--wk)));
  transition: background .2s, box-shadow .25s, color .2s, transform .2s var(--ease); }
.rail a:hover, .rail button:hover { background: rgb(var(--w) / calc(.62 * var(--wk))); color: var(--ink);
  box-shadow: inset 0 0 0 1px rgb(var(--w) / calc(.9 * var(--wk))), 0 0 0 4px rgb(var(--w) / calc(.18 * var(--wk))), 0 6px 20px rgb(214 150 80 / .28); }
.rail a[aria-current=page] { background: #fff; color: #231b14; box-shadow: 0 0 0 4px rgb(255 255 255 / .2), 0 6px 18px rgb(60 40 20 / .22); }
.rail a.rail-mark, html[data-theme=dark] .rail a.rail-mark { width: 44px; height: 44px; border-radius: 14px; margin-bottom: 6px; color: #fff;
  background: linear-gradient(160deg, #eab06c, #c27a34); box-shadow: inset 0 1px 0 rgb(255 255 255 / .5), 0 6px 16px rgb(194 122 52 / .35); }
.rail a.rail-mark:hover, html[data-theme=dark] .rail a.rail-mark:hover { background: linear-gradient(160deg, #f1bd7c, #cc853d); box-shadow: inset 0 1px 0 rgb(255 255 255 / .6), 0 8px 22px rgb(194 122 52 / .5); }
.rail .rail-mark .ic { width: 24px; height: 24px; }
.rail [data-tip]::after { left: 56px; padding: 6px 11px; border-radius: 10px; background: rgb(30 23 18 / .9); color: #fff; font-size: 13.5px;
  box-shadow: 0 6px 18px rgb(0 0 0 / .25); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
.rail .rail-badge { top: -3px; right: -3px; min-width: 19px; height: 19px; border-radius: 10px; background: linear-gradient(160deg, #f0a85a, #d9782c); color: #fff;
  font-size: 11px; font-weight: 750; display: grid; place-items: center; box-shadow: 0 0 0 2px rgb(var(--w) / calc(.9 * var(--wk))), 0 3px 8px rgb(200 110 40 / .4); }
html[data-theme=dark] .rail a, html[data-theme=dark] .rail button { background: rgb(255 240 222 / .05); box-shadow: inset 0 0 0 1px rgb(255 240 222 / .08); }
html[data-theme=dark] .rail a:hover, html[data-theme=dark] .rail button:hover { background: rgb(255 240 222 / .14); box-shadow: inset 0 0 0 1px rgb(255 240 222 / .2), 0 0 18px rgb(230 150 70 / .3); }
html[data-theme=dark] .rail a[aria-current=page] { background: #fff; color: #1d1611; }
html[data-theme=dark] .rail .rail-badge { box-shadow: 0 0 0 2px rgb(24 19 15 / .9), 0 3px 8px rgb(0 0 0 / .4); }
@media (max-height: 640px) { .rail { gap: 4px; } .rail .rail-mark { display: none; } }

/* ---------- The floating tab bar stands apart from the page (07-11-2026) ----------
   It floats over cards of the same glass, so it gets its own tone, a brighter edge and a deeper shadow; at night a
   lighter, warmer smoke with a white pill for the current page (as in the sidebar). */
.tabbar { background: rgb(255 251 246 / .8); border-color: rgb(255 255 255 / .9);
  box-shadow: inset 0 1px 0 rgb(255 255 255 / .95), 0 0 0 1px rgb(120 84 48 / .1), 0 18px 44px rgb(64 42 20 / .26); }
.tabbar [aria-current=page], .tabbar [aria-pressed=true] { background: #2a211a; color: #fff; box-shadow: 0 6px 16px rgb(42 33 26 / .3); }
.tabbar [aria-current=page] .ic, .tabbar [aria-pressed=true] .ic { color: #fff; }
html[data-theme=dark] .tabbar { background: rgb(72 58 46 / .82); border-color: rgb(255 240 222 / .26);
  box-shadow: inset 0 1px 0 rgb(255 240 222 / .24), 0 0 0 1px rgb(0 0 0 / .4), 0 20px 48px rgb(0 0 0 / .62); }
html[data-theme=dark] .tabbar a, html[data-theme=dark] .tabbar button.tb { color: rgb(255 244 232 / .82); }
html[data-theme=dark] .tabbar a:hover, html[data-theme=dark] .tabbar button.tb:hover { background: rgb(255 240 222 / .12); color: #fff; }
html[data-theme=dark] .tabbar [aria-current=page], html[data-theme=dark] .tabbar [aria-pressed=true] { background: #fff; color: #1d1611; box-shadow: 0 6px 18px rgb(0 0 0 / .4); }
html[data-theme=dark] .tabbar [aria-current=page] .ic, html[data-theme=dark] .tabbar [aria-pressed=true] .ic { color: #1d1611; }
.a-form .a-delete-project { margin-left: auto; color: var(--bad-ink); }
