@font-face {
  font-family: "Jakarta";
  src: url("/vendor/font.woff2") format("woff2");
  font-weight: 200 800;
  font-display: swap;
}

:root {
  --bg: #e6e8f3;
  --shell: #f5f6fb;
  --panel: #ffffff;
  --line: #e4e6f0;
  --line-soft: #eff0f7;
  --text: #14152b;
  --muted: #5f6480;
  --faint: #8e93ad;
  --ink: #14152b;
  --ink-2: #1f2140;
  --ink-3: #2b2d52;
  --accent: #5b4ee6;
  --accent-2: #7468f2;
  --accent-deep: #4338c9;
  --accent-soft: #eceafd;
  --accent-ink: #ffffff;
  --good: #16794a;
  --good-soft: #e3f5ec;
  --warn: #8a5a00;
  --warn-soft: #fff3d1;
  --bad: #c0362c;
  --bad-soft: #fdecea;
  --open: #e0582a;
  --with-agent: #5b4ee6;
  --fixed: #1f9d61;
  --confirmed: #8e93ad;
  --radius: 20px;
  --radius-s: 14px;
  --shadow: 0 1px 2px rgba(20, 21, 43, .04), 0 8px 24px -18px rgba(20, 21, 43, .25);
  color-scheme: light;
}

* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body {
  background: var(--bg);
  color: var(--text);
  font: 14px/1.5 "Jakarta", "Segoe UI Variable Text", "Segoe UI", system-ui, -apple-system, Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
  padding: 12px;
}
[hidden] { display: none !important; }
h1 { margin: 0; font-size: 30px; line-height: 1.15; letter-spacing: -0.03em; font-weight: 700; }
h2 { margin: 32px 0 12px; font-size: 18px; letter-spacing: -0.02em; font-weight: 700; }
h3 { margin: 0 0 14px; font-size: 15px; font-weight: 700; letter-spacing: -0.01em; }
h4 { margin: 18px 0 8px; font-size: 13px; font-weight: 700; }
p { margin: 0 0 10px; }
a { color: var(--accent); }

/* ---- The frame of the app and the bar on top ---- */
.shell { height: calc(100vh - 24px); display: flex; flex-direction: column; background: var(--shell); border-radius: 28px; overflow: hidden; box-shadow: 0 20px 50px -30px rgba(20, 21, 43, .35); }
.top { display: flex; align-items: center; gap: 14px; padding: 14px 20px; flex: none; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text); margin-right: 4px; }
.brand-name { font-weight: 800; font-size: 17px; letter-spacing: -0.02em; line-height: 1.1; }
.brand-sub { color: var(--faint); font-size: 10.5px; font-weight: 600; line-height: 1.2; }
.mark { width: 30px; height: 30px; border-radius: 10px 10px 10px 3px; background: linear-gradient(135deg, var(--accent-2), var(--accent-deep)); position: relative; flex: none; }
.mark::after { content: ""; position: absolute; inset: 8px; border-radius: 50% 50% 50% 2px; background: #fff; opacity: .95; }
.client { display: flex; align-items: center; }
.client span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.client select { font: inherit; font-weight: 700; padding: 10px 34px 10px 16px; border: 1px solid var(--line); border-radius: 999px; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' fill='none' stroke='%2314152b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 1.5l5 5 5-5'/%3E%3C/svg%3E") no-repeat right 13px center; color: var(--text); appearance: none; cursor: pointer; max-width: 200px; }
.nav { display: flex; gap: 2px; background: var(--ink); border-radius: 999px; padding: 5px; min-width: 0; overflow-x: auto; scrollbar-width: none; }
.nav::-webkit-scrollbar { display: none; }
.nav a { padding: 8px 16px; border-radius: 999px; color: #d6d8ea; text-decoration: none; font-weight: 600; font-size: 13px; white-space: nowrap; }
.nav a:hover { color: #fff; background: var(--ink-3); }
.nav a[aria-current="page"] { background: linear-gradient(135deg, var(--accent-2), var(--accent)); color: #fff; }
.top-right { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.safe { color: var(--faint); font-size: 11.5px; line-height: 1.3; text-align: right; }
.user { display: flex; align-items: center; gap: 8px; }
.avatar { width: 38px; height: 38px; border-radius: 50%; background: var(--ink); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: 13px; flex: none; }
.user-name { font-weight: 700; font-size: 13px; line-height: 1.2; }
.user form { margin: 0; }
.linklike { font: inherit; font-size: 12px; color: var(--muted); background: none; border: 0; padding: 0; cursor: pointer; text-decoration: underline; }
.linklike:hover { color: var(--accent); }

main { flex: 1; min-width: 0; min-height: 0; }
.view { height: 100%; }
.page { overflow: auto; padding: 14px max(28px, calc((100% - 1240px) / 2)) 64px; }

.page-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 22px; flex-wrap: wrap; }
.sub { color: var(--muted); margin: 6px 0 0; }
.head-links { display: flex; gap: 8px; flex-wrap: wrap; }
.hint { color: var(--muted); font-size: 13px; }
.toolbar { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin-bottom: 16px; }

/* ---- Buttons ---- */
.btn { font: inherit; color: var(--text); background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: 8px 16px; cursor: pointer; text-decoration: none; white-space: nowrap; font-weight: 600; font-size: 13px; display: inline-block; }
.btn:hover { background: var(--line-soft); }
.btn:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, .nav a:focus-visible, .th:focus-visible, .chip:focus-visible, summary:focus-visible, [role="tab"]:focus-visible, .linklike:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.btn[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: #fff; }
.btn.primary { background: linear-gradient(135deg, var(--accent-2), var(--accent)); border-color: transparent; color: var(--accent-ink); padding: 10px 20px; }
.btn.primary:hover { background: var(--accent-deep); }
.btn.primary[aria-pressed="true"] { background: var(--open); border-color: var(--open); color: #fff; }
.btn.small { padding: 5px 12px; font-size: 12.5px; }
.btn.quiet { border-color: transparent; color: var(--muted); background: transparent; }
.btn.quiet:hover { background: var(--line-soft); color: var(--text); }
.btn.light { background: #fff; border-color: #fff; color: var(--ink); }
.btn.light:hover { background: var(--accent-soft); }
.btn:disabled { opacity: .55; cursor: default; }

/* ---- Cards, tiles, grids ---- */
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 22px; box-shadow: var(--shadow); margin-bottom: 16px; min-width: 0; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.card-head h3 { margin: 0; }
.more { display: inline-block; margin-top: 14px; font-size: 13px; font-weight: 600; text-decoration: none; }
.more:hover { text-decoration: underline; }
.grid { display: grid; gap: 16px; margin-bottom: 16px; }
.grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; }
.grid > .card, .grid > div > .card:last-child { margin-bottom: 0; }

.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 14px; margin-bottom: 16px; }
.tiles.small { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.tile { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; box-shadow: var(--shadow); min-width: 0; display: flex; flex-direction: column; }
.card .tile { box-shadow: none; background: var(--shell); border-radius: var(--radius-s); }
.tile.link { text-decoration: none; color: inherit; }
.tile.link:hover { border-color: var(--accent-2); }
.tile-label { color: var(--text); font-size: 13px; font-weight: 600; }
.tile-value { font-size: 30px; font-weight: 700; letter-spacing: -0.03em; line-height: 1.2; margin-top: 8px; font-variant-numeric: tabular-nums; }
.tile-note { color: var(--faint); font-size: 12px; margin-top: 4px; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.tile .spark { margin-top: auto; padding-top: 12px; }
.spark svg { display: block; width: 100%; height: 44px; }
.delta { font-size: 12px; font-weight: 700; letter-spacing: 0; white-space: nowrap; }
.delta.good { color: var(--good); }
.delta.bad { color: var(--bad); }
.delta.flat { color: var(--muted); font-weight: 600; }

.empty { color: var(--muted); padding: 22px 6px; text-align: center; }
.spinner { display: inline-block; width: 14px; height: 14px; border: 2px solid var(--line); border-top-color: var(--accent); border-radius: 50%; margin-right: 8px; vertical-align: -2px; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .spinner { animation: none; } }
.notice { background: var(--warn-soft); border: 1px solid #f0d58a; color: #5c3c00; padding: 12px 16px; border-radius: var(--radius-s); margin-bottom: 16px; font-size: 13.5px; }
.notice.bad { background: var(--bad-soft); border-color: #f3b8b1; color: #7a1a12; }
.error { color: var(--bad); font-size: 13px; }

/* ---- The dark panel (overview): checks on the left, this week on the right ---- */
.deck { background: var(--ink); color: #fff; border-radius: 26px; padding: 22px; display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 20px; margin-bottom: 16px; }
.deck h3 { color: #fff; margin: 0; }
.deck-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.deck .more { color: #c9c4ff; }
.deck .empty { color: #b9bcd6; }
.deck .check { background: var(--ink-2); border: 0; border-radius: 16px; padding: 12px 14px; margin-bottom: 8px; align-items: center; }
.deck .check-a { color: #a9adc9; }
.deck .check .badge { order: 2; min-width: 0; }
.deck .badge { background: var(--ink-3); color: #d6d8ea; }
.deck .badge.pass { background: #173d33; color: #7fe0b0; }
.deck .badge.warn { background: #45380f; color: #ffd66b; }
.deck .badge.fail { background: #4a1f24; color: #ff9d94; }
.deck-side { background: linear-gradient(150deg, #7468f2, #5244d8); border-radius: 22px; padding: 20px 22px; min-width: 0; }
.deck-side h4 { color: #e3e0ff; font-weight: 600; }
.deck-side .tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.deck-side .tile { background: rgba(255, 255, 255, .13); border: 1px solid rgba(255, 255, 255, .16); box-shadow: none; border-radius: 16px; padding: 12px 14px; }
.deck-side .tile-label { color: #e3e0ff; font-size: 12px; }
.deck-side .tile-value { font-size: 22px; margin-top: 4px; }
.deck-side .delta, .deck-side .delta.good, .deck-side .delta.bad, .deck-side .delta.flat { color: #fff; }
.deck-side .sug-why { color: #dedbff; }
.deck-side .more { color: #fff; }
.deck-side .plain, .deck-side .suggestions { color: #fff; }

/* ---- Tabs ---- */
.tabs { display: inline-flex; gap: 2px; background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: 5px; margin-bottom: 20px; max-width: 100%; overflow-x: auto; }
.tabs button { font: inherit; font-size: 13px; font-weight: 600; color: var(--muted); background: none; border: 0; border-radius: 999px; padding: 8px 18px; cursor: pointer; white-space: nowrap; }
.tabs button:hover { color: var(--text); }
.tabs button[aria-selected="true"] { color: #fff; background: linear-gradient(135deg, var(--accent-2), var(--accent)); }
.segmented { display: inline-flex; background: var(--ink); border-radius: 999px; padding: 4px; }
.segmented button { font: inherit; font-size: 12.5px; font-weight: 600; color: #d6d8ea; background: none; border: 0; border-radius: 999px; padding: 5px 14px; cursor: pointer; }
.segmented button[aria-selected="true"] { background: #fff; color: var(--ink); }

/* ---- Tables ---- */
.table-wrap { overflow-x: auto; }
table { border-collapse: collapse; width: 100%; font-size: 13.5px; font-variant-numeric: tabular-nums; }
th, td { padding: 9px 10px; border-bottom: 1px solid var(--line-soft); text-align: right; white-space: nowrap; }
th.left, td.left { text-align: left; }
td.left { white-space: normal; max-width: 340px; overflow-wrap: anywhere; }
thead th { border-bottom: 1px solid var(--line); padding: 4px 4px; }
.th { font: inherit; font-size: 12px; font-weight: 700; color: var(--muted); background: none; border: 0; padding: 4px 6px; border-radius: 6px; cursor: pointer; white-space: nowrap; }
.th:hover { background: var(--line-soft); color: var(--text); }
tbody tr:hover { background: var(--shell); }
tbody tr:last-child td { border-bottom: 0; }
.cell-link { color: var(--text); text-decoration: none; }
.cell-link:hover { color: var(--accent); text-decoration: underline; }
.table-wrap > .btn { margin-top: 8px; }
details.data { margin: 0 0 16px; }
details.data summary { cursor: pointer; color: var(--accent); font-size: 13px; font-weight: 600; padding: 4px 0; width: fit-content; border-radius: 4px; }
details.data[open] { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 16px 14px; }
.card details.data { margin: 10px 0 0; }
.card details.data[open] { border: 0; padding: 0; }
.freshness { color: var(--faint); font-size: 12.5px; margin-top: 20px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }

/* ---- Charts ---- */
.chart { width: 100%; max-width: 660px; height: auto; display: block; overflow: visible; }
.chart .gridline { stroke: var(--line-soft); stroke-width: 1; }
.chart .axis { stroke: var(--line); stroke-width: 1; }
.chart .tick { fill: var(--faint); font-size: 11px; font-family: inherit; }
.chart .cross { stroke: var(--faint); stroke-width: 1; stroke-dasharray: 3 3; }
.chart-tip { position: fixed; z-index: 50; pointer-events: none; background: var(--ink); color: #fff; border-radius: 12px; padding: 8px 12px; font-size: 12.5px; line-height: 1.45; box-shadow: 0 8px 20px rgba(20, 21, 43, .3); font-variant-numeric: tabular-nums; }
.chart-tip .tip-title { color: #b9bcd6; font-size: 11.5px; }
.legend { display: flex; flex-wrap: wrap; gap: 4px 14px; margin-top: 8px; color: var(--muted); font-size: 12.5px; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; }

/* ---- Checks ---- */
.badge { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 700; border-radius: 999px; padding: 4px 12px 4px 4px; white-space: nowrap; flex: none; background: var(--line-soft); color: var(--muted); }
.badge b, .dot { display: inline-grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; font-size: 11px; font-weight: 700; color: #fff; background: var(--faint); flex: none; }
.badge.pass { background: var(--good-soft); color: var(--good); } .badge.pass b, .dot.pass { background: var(--good); }
.badge.warn { background: var(--warn-soft); color: var(--warn); } .badge.warn b, .dot.warn { background: #b87900; }
.badge.fail { background: var(--bad-soft); color: var(--bad); } .badge.fail b, .dot.fail { background: var(--bad); }
.dot.info { background: var(--faint); font-style: italic; font-family: Georgia, serif; }
.check { display: flex; gap: 12px; align-items: flex-start; padding: 12px 0; border-bottom: 1px solid var(--line-soft); }
.check:last-child { border-bottom: 0; }
.check .badge { min-width: 108px; }
.check-text { flex: 1; min-width: 0; }
.check-q { font-weight: 700; }
.check-a { color: var(--muted); font-size: 13px; }
.check.full { display: block; padding: 16px 0; }
.check-top { display: flex; gap: 12px; align-items: flex-start; }
.lines { list-style: none; margin: 10px 0 0 120px; padding: 0; display: grid; gap: 5px; }
.lines li { display: grid; grid-template-columns: 18px 74px minmax(0, 1fr); gap: 8px; align-items: start; font-size: 13.5px; }
.lines li.fail { font-weight: 600; }
.line-site { color: var(--muted); font-size: 12.5px; padding-top: 1px; }
.check-foot { margin: 8px 0 0 120px; color: var(--faint); font-size: 12px; display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.check-foot .dot { width: 14px; height: 14px; font-size: 9px; }

/* ---- Checklist ---- */
.progress-row { display: flex; align-items: center; gap: 12px; margin-bottom: 8px; flex-wrap: wrap; }
.progress { flex: 1; min-width: 160px; height: 10px; background: var(--line-soft); border-radius: 999px; overflow: hidden; }
.progress i { display: block; height: 100%; background: linear-gradient(90deg, var(--accent-2), var(--accent)); border-radius: 999px; }
.check-toggle { margin-left: auto; color: var(--muted); font-size: 13px; }
.phase { border-top: 1px solid var(--line-soft); padding-top: 14px; margin-top: 14px; }
.phase-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.phase-head h4 { margin: 0; font-size: 14px; }
.phase-count { color: var(--faint); font-size: 12.5px; }
.items { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 8px; }
.items li { display: grid; grid-template-columns: 112px minmax(0, 1fr); gap: 12px; align-items: start; }
.item-label { font-weight: 600; }
.item-note { color: var(--muted); font-size: 13px; }
.state-tag { display: inline-block; font-size: 11.5px; font-weight: 700; border-radius: 999px; padding: 3px 10px; background: var(--line-soft); color: var(--muted); white-space: nowrap; text-align: center; height: fit-content; width: fit-content; }
.st-done { background: var(--good-soft); color: var(--good); }
.st-todo, .sev-error { background: var(--bad-soft); color: var(--bad); }
.st-started, .st-later, .sev-warning { background: var(--warn-soft); color: var(--warn); }

/* ---- Reports ---- */
.plain { margin: 0; padding-left: 18px; display: grid; gap: 4px; }
.suggestions { margin: 0; padding-left: 20px; display: grid; gap: 10px; }
.sug-title { font-weight: 700; }
.sug-why { color: var(--muted); font-size: 13px; }
.report .tiles { margin-bottom: 4px; }
.report .tile-value { font-size: 22px; }

/* ---- Client file ---- */
.doc-layout { display: grid; grid-template-columns: 270px minmax(0, 1fr); gap: 16px; align-items: start; }
.doc-list { display: grid; gap: 6px; position: sticky; top: 0; background: var(--ink); border-radius: 22px; padding: 10px; }
.doc-list a { display: block; padding: 12px 14px; border-radius: 16px; text-decoration: none; color: #fff; }
.doc-list a:hover { background: var(--ink-2); }
.doc-list a[aria-current="page"] { background: linear-gradient(135deg, var(--accent-2), var(--accent)); }
.doc-title { font-weight: 700; }
.doc-about { color: #b9bcd6; font-size: 12.5px; line-height: 1.4; }
.doc-list a[aria-current="page"] .doc-about, .doc-list a[aria-current="page"] .doc-date { color: #e3e0ff; }
.doc-date { color: #8e93ad; font-size: 11.5px; margin-top: 3px; }
.doc-pane { padding: 28px 32px; }
.doc { max-width: 78ch; overflow-wrap: anywhere; }
.doc h1 { font-size: 24px; margin: 0 0 14px; }
.doc h2 { font-size: 17px; margin: 26px 0 8px; padding-top: 14px; border-top: 1px solid var(--line-soft); }
.doc h3 { font-size: 15px; margin: 18px 0 6px; }
.doc ul, .doc ol { padding-left: 20px; margin: 0 0 10px; }
.doc li { margin-bottom: 4px; }
.doc code { background: var(--line-soft); padding: 1px 5px; border-radius: 4px; font-size: 12.5px; }
.doc pre { background: var(--shell); padding: 12px; border-radius: 12px; overflow-x: auto; }
.doc pre code { background: none; padding: 0; }
.doc blockquote { margin: 0 0 10px; padding: 2px 14px; border-left: 3px solid var(--accent-soft); color: var(--muted); }
.doc .table-wrap { margin-bottom: 12px; }
.doc td, .doc th { text-align: left; white-space: normal; vertical-align: top; }
.doc th { font-size: 12px; color: var(--muted); border-bottom: 1px solid var(--line); padding: 7px 10px; }

/* ---- Agent ---- */
.thread { display: grid; gap: 10px; max-height: 52vh; overflow: auto; margin-bottom: 14px; }
.msg { background: linear-gradient(135deg, var(--accent-2), var(--accent)); color: #fff; border-radius: 18px 18px 4px 18px; padding: 12px 16px; max-width: 80%; justify-self: end; }
.msg .msg-meta { color: #e3e0ff; }
.msg .btn.quiet { color: #fff; }
.msg.agent { background: var(--line-soft); color: var(--text); border-radius: 18px 18px 18px 4px; justify-self: start; }
.msg.agent .msg-meta { color: var(--muted); }
.msg-text { white-space: pre-wrap; overflow-wrap: anywhere; }
.msg-meta { font-size: 12px; margin-top: 4px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }

/* ---- Live site and pins ---- */
.site-view { display: grid; grid-template-columns: minmax(0, 1fr) 390px; gap: 14px; padding: 0 16px 16px; }
.site { display: flex; flex-direction: column; min-width: 0; min-height: 0; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.bar { display: flex; align-items: center; gap: 8px; padding: 10px 12px; background: var(--panel); border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.address { flex: 1; min-width: 200px; display: flex; align-items: center; border: 1px solid var(--line); border-radius: 999px; background: var(--shell); padding-left: 14px; overflow: hidden; }
.address span { color: var(--muted); white-space: nowrap; }
.address input { flex: 1; min-width: 0; border: 0; font: inherit; padding: 8px 10px 8px 0; color: var(--text); background: transparent; outline: none; }
.address:focus-within { outline: 2px solid var(--accent); outline-offset: 1px; }
.sizes { display: flex; background: var(--ink); border-radius: 999px; padding: 4px; gap: 2px; }
.sizes .btn { border: 0; background: none; color: #d6d8ea; padding: 5px 12px; font-size: 12.5px; }
.sizes .btn[aria-pressed="true"] { background: #fff; color: var(--ink); }
.dims { color: var(--muted); font-size: 12.5px; font-variant-numeric: tabular-nums; min-width: 84px; }
.stage { flex: 1; min-height: 0; position: relative; display: flex; justify-content: center; background: #dfe1ec; overflow: auto; }
.stage iframe { width: 100%; height: 100%; border: 0; background: #fff; }
.stage[data-size="tablet"] iframe { width: 768px; flex: none; box-shadow: 0 0 0 1px var(--line); }
.stage[data-size="phone"] iframe { width: 390px; flex: none; box-shadow: 0 0 0 1px var(--line); }
.frame-note { position: absolute; left: 50%; bottom: 16px; transform: translateX(-50%); background: var(--warn-soft); border: 1px solid #f0d58a; color: #5c3c00; padding: 8px 14px; border-radius: 12px; max-width: 90%; font-size: 13px; }

.pins { display: flex; flex-direction: column; min-height: 0; background: var(--ink); color: #fff; border-radius: 24px; overflow: hidden; }
.pins-head { display: flex; align-items: center; justify-content: space-between; padding: 18px 18px 8px; }
.pins-head h2 { margin: 0; color: #fff; }
.this-page { display: flex; color: #b9bcd6; align-items: center; gap: 6px; font-size: 13px; }
.filters { display: flex; flex-wrap: wrap; gap: 6px; padding: 4px 18px 14px; }
.chip { font: inherit; font-size: 12.5px; font-weight: 600; border: 0; background: var(--ink-2); color: #d6d8ea; border-radius: 999px; padding: 5px 12px; cursor: pointer; }
.chip[aria-pressed="true"] { background: linear-gradient(135deg, var(--accent-2), var(--accent)); color: #fff; }
.chip b { font-weight: 700; margin-left: 4px; font-variant-numeric: tabular-nums; }

.composer { margin: 0 14px 12px; padding: 14px; border: 2px solid var(--open); border-radius: 18px; background: #fff; color: var(--text); }
.composer.plain { margin: 0; padding: 0; border: 0; background: none; }
.composer h3 { margin: 0 0 4px; font-size: 14px; }
.composer textarea { width: 100%; min-height: 84px; resize: vertical; font: inherit; padding: 10px 12px; border: 1px solid var(--line); border-radius: 14px; margin: 8px 0; background: #fff; color: var(--text); }
.composer .row { display: flex; gap: 8px; align-items: center; }
.composer .shot-state { color: var(--muted); font-size: 13px; margin-left: auto; }
.composer .meta { color: var(--muted); font-size: 12.5px; }

.list { flex: 1; min-height: 0; overflow: auto; padding: 0 14px 20px; display: flex; flex-direction: column; gap: 10px; }
.list > .empty { color: #b9bcd6; }
.pin { border-radius: 18px; padding: 14px; background: #fff; color: var(--text); }
.pin.flash { animation: flash 1.4s ease-out; }
@keyframes flash { 0% { background: #e3e0ff; } 100% { background: #fff; } }
.pin-top { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.num { width: 26px; height: 26px; border-radius: 50%; color: #fff; font-weight: 700; font-size: 12px; display: grid; place-items: center; flex: none; }
.state { font-size: 12px; font-weight: 700; border-radius: 999px; padding: 2px 10px; border: 1px solid currentColor; }
.s-open { color: var(--open); } .num.s-open { background: var(--open); }
.s-with-agent { color: var(--with-agent); } .num.s-with-agent { background: var(--with-agent); }
.s-fixed { color: var(--fixed); } .num.s-fixed { background: var(--fixed); }
.s-confirmed { color: var(--confirmed); } .num.s-confirmed { background: var(--confirmed); }
.num[class*="s-"] { color: #fff; }
.when { margin-left: auto; color: var(--muted); font-size: 12px; }
.comment { white-space: pre-wrap; overflow-wrap: anywhere; margin: 0 0 8px; }
.pin-body { display: flex; gap: 10px; }
.pin-body .meta { flex: 1; min-width: 0; }
.pin .meta, .pin .meta dd { color: var(--muted); font-size: 12.5px; }
.pin .meta dl { margin: 0; display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 1px 8px; }
.pin .meta dd { margin: 0; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.thumb { flex: none; width: 96px; height: 64px; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; padding: 0; cursor: zoom-in; background: var(--shell); }
.thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.no-shot { flex: none; width: 96px; height: 64px; border: 1px dashed var(--line); border-radius: 10px; color: var(--muted); font-size: 11.5px; display: grid; place-items: center; text-align: center; }
.actions { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.actions .spacer { flex: 1; }

dialog { border: 0; border-radius: 22px; padding: 14px; max-width: 94vw; max-height: 94vh; }
dialog::backdrop { background: rgba(20, 21, 43, .6); }
dialog form { text-align: right; margin-bottom: 8px; }
dialog img { display: block; max-width: 90vw; max-height: 80vh; border-radius: 12px; }

/* ---- The sign-in page and plain message pages ---- */
.gate { min-height: calc(100vh - 24px); display: grid; place-items: center; background: var(--shell); border-radius: 28px; padding: 24px; }
.gate-card { width: min(420px, 100%); background: var(--ink); color: #fff; border-radius: 28px; padding: 36px 32px; text-align: center; }
.gate-card .mark { margin: 0 auto 18px; width: 44px; height: 44px; border-radius: 14px 14px 14px 4px; }
.gate-card .mark::after { inset: 12px; }
.gate-card h1 { font-size: 26px; margin-bottom: 8px; }
.gate-card p { color: #b9bcd6; margin-bottom: 22px; }
.gate-card .btn.primary { display: block; padding: 13px 20px; font-size: 14px; }
.gate-card small { display: block; margin-top: 16px; color: #8e93ad; }

@media (max-width: 1100px) {
  .safe { display: none; }
  .deck { grid-template-columns: 1fr; }
}
@media (max-width: 1000px) {
  body { padding: 0; }
  .shell { height: 100vh; border-radius: 0; }
  .top { flex-wrap: wrap; padding: 10px 14px; gap: 10px; }
  .nav { order: 5; width: 100%; }
  .user-name { display: none; }
  .page { padding: 12px 16px 48px; }
  h1 { font-size: 24px; }
  .grid.two, .doc-layout { grid-template-columns: 1fr; }
  .doc-list { position: static; }
  .site-view { grid-template-columns: 1fr; grid-template-rows: minmax(0, 3fr) minmax(0, 2fr); padding: 0 10px 10px; }
  .lines, .check-foot { margin-left: 0; }
  .deck-side .tiles { grid-template-columns: 1fr; }
}
