/* Porter app. Same language as the landing page: grey canvas, white cards, sky accents. */
:root {
  --bg: #f4f4f4;
  --card: #fff;
  --sunk: #f7f7f7;
  --ink: #141518;
  --ink-2: #33363b;
  --mute: #6b6e74;
  --faint: #a2a5ab;
  --line: rgba(20, 21, 24, .08);
  --line-2: rgba(20, 21, 24, .13);
  --blue: #3f8fe0;
  --blue-ink: #2b6fb8;
  --blue-tint: #e6f0fa;
  --green: #2f8a4a;
  --green-tint: #e4f3e7;
  --amber: #a8640f;
  --amber-tint: #fbf0dc;
  --violet: #6f4fc0;
  --violet-tint: #eee9fa;
  --red: #c2412d;
  --red-tint: #fbe8e4;
  --hvac: #3f8fe0; --hvac-t: #e6f0fa; --hvac-i: #2b6fb8;
  --plumb: #49a464; --plumb-t: #e4f3e7; --plumb-i: #2f7a44;
  --elec: #dc9a35; --elec-t: #fbf0dc; --elec-i: #94570c;
  --serif: "Source Serif 4", Georgia, serif;
  --sans: Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
  --r: 18px;
  --side: 244px;
  --top: 60px;
  --ease: cubic-bezier(.2, .7, .2, 1);
  --shadow-pop: 0 1px 2px rgba(20,30,50,.06), 0 18px 48px -12px rgba(20,30,50,.28);
}
*, *::before, *::after { box-sizing: border-box; }
html, body { height: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 14px/1.5 var(--sans); -webkit-font-smoothing: antialiased; overflow: hidden; }
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
svg { width: 1em; height: 1em; flex: none; }
[data-ic] { display: inline-flex; align-items: center; justify-content: center; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; border-radius: 8px; }
kbd { font: 500 11px/1 var(--sans); padding: 3px 5px; border-radius: 5px; background: #fff; box-shadow: inset 0 0 0 1px var(--line-2), 0 1px 0 var(--line-2); color: var(--mute); }
.num { font-variant-numeric: tabular-nums; }
.serif { font-family: var(--serif); }

/* layout */
.app { display: grid; grid-template-columns: var(--side) 1fr; height: 100vh; height: 100dvh; }
.side { display: flex; flex-direction: column; padding: 12px 10px 12px; min-height: 0; background: var(--bg); }
.main { display: flex; flex-direction: column; min-width: 0; min-height: 0; }
.top { height: var(--top); flex: none; display: flex; align-items: center; gap: 14px; padding: 0 22px 0 18px; }
.view { flex: 1; min-height: 0; overflow: auto; outline: none; }
.view.flush { overflow: hidden; display: flex; }

/* sidebar */
.side-top { display: flex; align-items: center; gap: 6px; }
.ws { flex: 1; min-width: 0; display: flex; align-items: center; gap: 10px; padding: 6px 8px 6px 6px; border-radius: 12px; text-align: left; transition: background .15s; }
.ws:hover, .ws[aria-expanded="true"] { background: rgba(20,21,24,.05); }
.ws-mark { width: 32px; height: 32px; border-radius: 10px; background: var(--blue); color: #fff; display: grid; place-items: center; flex: none; }
.ws-mark svg { width: 20px; height: 20px; }
.ws-txt { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.ws-txt b { font-weight: 600; font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; letter-spacing: -.01em; }
.ws-txt small { font-size: 12px; color: var(--mute); }
.ws-chev { color: var(--faint); font-size: 15px; }
.icon-btn.side-close { display: none; }
.status { margin: 14px 4px 10px; display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 14px; background: #fff; text-align: left; box-shadow: 0 0 0 1px var(--line); transition: box-shadow .2s; }
.status:hover { box-shadow: 0 0 0 1px var(--line-2), 0 6px 18px -10px rgba(20,30,50,.3); }
.status-dot { width: 8px; height: 8px; border-radius: 50%; background: #39a85a; box-shadow: 0 0 0 3px rgba(57,168,90,.18); flex: none; animation: pulse 2s infinite; }
.status.paused .status-dot { background: #d08a2a; box-shadow: 0 0 0 3px rgba(208,138,42,.2); animation: none; }
@keyframes pulse { 50% { box-shadow: 0 0 0 5px rgba(57,168,90,.06); } }
.status-txt { display: flex; flex-direction: column; min-width: 0; }
.status-txt b { font-size: 13px; font-weight: 500; }
.status-txt small { font-size: 12px; color: var(--mute); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nav { flex: 1; overflow: auto; display: flex; flex-direction: column; gap: 2px; padding: 4px 2px; min-height: 0; }
.nav-label { font-size: 12px; color: var(--faint); padding: 14px 10px 6px; }
.nav a { position: relative; display: flex; align-items: center; gap: 11px; height: 36px; padding: 0 10px; border-radius: 10px; color: var(--ink-2); font-weight: 500; font-size: 13.5px; transition: background .15s, color .15s; }
.nav a:hover { background: rgba(20,21,24,.045); }
.nav a.on { background: #fff; color: var(--ink); box-shadow: 0 0 0 1px var(--line), 0 1px 2px rgba(20,30,50,.04); }
.nav a .ni { font-size: 18px; color: var(--mute); }
.nav a.on .ni { color: var(--ink); }
.nav a .nb { margin-left: auto; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; background: var(--amber-tint); color: var(--amber); font-size: 11.5px; font-weight: 600; display: grid; place-items: center; }
.nav a .nc { margin-left: auto; font-size: 12px; color: var(--faint); font-variant-numeric: tabular-nums; }
.side-foot { padding-top: 8px; border-top: 1px solid var(--line); display: flex; flex-direction: column; gap: 10px; }
.me { display: flex; align-items: center; gap: 10px; padding: 6px; border-radius: 12px; text-align: left; }
.me:hover, .me[aria-expanded="true"] { background: rgba(20,21,24,.05); }
.me img { width: 32px; height: 32px; border-radius: 50%; object-fit: cover; }
.me-txt { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.me-txt b { font-weight: 500; font-size: 13.5px; }
.me-txt small { font-size: 12px; color: var(--mute); }
.me-dots { color: var(--faint); font-size: 16px; }
.ariadne { align-self: flex-start; margin-left: 4px; font: 500 12.5px/1 var(--sans); padding: 7px 11px; border-radius: 999px; background: rgba(20,22,26,.88); color: #fff; letter-spacing: .01em; box-shadow: 0 0 0 1px rgba(255,255,255,.14); opacity: .92; }
.ariadne b { font-weight: 600; color: #ff8a3d; }

/* top bar */
.icon-btn.menu-btn { display: none; }
.crumbs { display: flex; align-items: center; gap: 8px; font-size: 13.5px; color: var(--mute); min-width: 0; white-space: nowrap; overflow: hidden; }
.crumbs a:hover { color: var(--ink); }
.crumbs b { color: var(--ink); font-weight: 500; overflow: hidden; text-overflow: ellipsis; }
.crumbs .sep { color: var(--faint); }
.top-r { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.search { display: flex; align-items: center; gap: 9px; height: 36px; padding: 0 8px 0 12px; border-radius: 10px; background: #fff; box-shadow: 0 0 0 1px var(--line); color: var(--mute); font-size: 13.5px; width: 280px; transition: box-shadow .2s; }
.search:hover { box-shadow: 0 0 0 1px var(--line-2); }
.search kbd { margin-left: auto; }
.icon-btn { width: 36px; height: 36px; border-radius: 10px; display: inline-grid; place-items: center; font-size: 18px; color: var(--ink-2); position: relative; transition: background .15s; flex: none; }
.icon-btn:hover { background: rgba(20,21,24,.06); }
.bell-dot { position: absolute; top: 8px; right: 9px; width: 7px; height: 7px; border-radius: 50%; background: #e0892b; box-shadow: 0 0 0 2px var(--bg); }
.bell-dot.off { display: none; }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; height: 38px; padding: 0 16px; border-radius: 999px; font: 500 13.5px/1 var(--sans); white-space: nowrap; transition: background .15s, box-shadow .15s, transform .15s; letter-spacing: -.005em; }
.btn:active { transform: scale(.98); }
.btn [data-ic], .btn svg { font-size: 16px; }
.btn-sm { height: 34px; padding: 0 13px; font-size: 13px; }
.btn-xs { height: 28px; padding: 0 11px; font-size: 12.5px; }
.btn-dark { background: #121419; color: #fff; }
.btn-dark:hover { background: #2a2d33; }
.btn-soft { background: #fff; box-shadow: inset 0 0 0 1px var(--line-2); color: var(--ink); }
.btn-soft:hover { background: #f8f8f8; }
.btn-grey { background: #efefef; color: var(--ink); }
.btn-grey:hover { background: #e6e6e6; }
.btn-ghost { color: var(--ink-2); }
.btn-ghost:hover { background: rgba(20,21,24,.05); }
.btn-danger { background: var(--red); color: #fff; }
.btn-danger:hover { background: #a93622; }
.btn-blue { background: var(--blue-tint); color: var(--blue-ink); }
.btn-blue:hover { background: #d9e8f7; }
.btn[disabled] { opacity: .45; pointer-events: none; }
.link { color: var(--blue-ink); font-weight: 500; }
.link:hover { text-decoration: underline; text-underline-offset: 3px; }

/* pills, avatars */
.pill { display: inline-flex; align-items: center; gap: 6px; height: 22px; padding: 0 9px; border-radius: 999px; font: 500 12px/1 var(--sans); white-space: nowrap; flex: none; }
.pill i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.p-blue { background: var(--blue-tint); color: var(--blue-ink); }
.p-green { background: var(--green-tint); color: var(--green); }
.p-amber { background: var(--amber-tint); color: var(--amber); }
.p-red { background: var(--red-tint); color: var(--red); }
.p-violet { background: var(--violet-tint); color: var(--violet); }
.p-grey { background: #efefef; color: var(--mute); }
.p-live i { animation: blink 1.2s infinite; }
@keyframes blink { 50% { opacity: .3; } }
.av { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; flex: none; font: 600 11px/1 var(--sans); letter-spacing: .02em; overflow: hidden; }
.av img { width: 100%; height: 100%; object-fit: cover; }
.av-sm { width: 24px; height: 24px; font-size: 9.5px; }
.av-lg { width: 44px; height: 44px; font-size: 14px; }
.av-xl { width: 56px; height: 56px; font-size: 17px; }
.c0 { background: var(--blue-tint); color: var(--blue-ink); }
.c1 { background: var(--violet-tint); color: var(--violet); }
.c2 { background: var(--green-tint); color: var(--green); }
.c3 { background: var(--amber-tint); color: var(--amber); }
.c4 { background: #f1e7e4; color: #9a4a35; }
.c5 { background: #e3eeee; color: #2f6f6f; }
.ch { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-size: 15px; flex: none; }
.ch-call { background: var(--blue-tint); color: var(--blue-ink); }
.ch-email { background: var(--amber-tint); color: var(--amber); }
.ch-form { background: var(--green-tint); color: var(--green); }
.ch-sms { background: var(--violet-tint); color: var(--violet); }
.trade { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--ink-2); }
.trade::before { content: ""; width: 8px; height: 8px; border-radius: 3px; background: var(--c); }
.t-hvac { --c: var(--hvac); } .t-plumb { --c: var(--plumb); } .t-elec { --c: var(--elec); }

/* page */
.page { max-width: 1320px; margin: 0 auto; padding: 8px 28px 48px; }
.ph { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin: 10px 0 22px; flex-wrap: wrap; }
.pt { margin: 0; font: 420 32px/1.12 var(--serif); font-variation-settings: "opsz" 32; letter-spacing: -.018em; }
.ps { margin: 6px 0 0; color: var(--mute); font-size: 14.5px; }
.ps b { color: var(--ink); font-weight: 500; }
.ph-act { display: flex; gap: 8px; flex-wrap: wrap; }
.card { background: var(--card); border-radius: var(--r); box-shadow: 0 0 0 1px rgba(20,21,24,.035); min-width: 0; }
.card-h { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 18px 10px; }
.card-h h2, .card-h h3 { margin: 0; font: 500 14.5px/1.3 var(--sans); letter-spacing: -.01em; }
.card-h small { color: var(--faint); font-size: 12.5px; }
.card-b { padding: 4px 18px 18px; }
.grid { display: grid; gap: 14px; }
.grid > * { min-width: 0; }
.g-2 { grid-template-columns: 1.15fr 1fr; }
.g-2b { grid-template-columns: 1.5fr 1fr; }
.g-3 { grid-template-columns: repeat(3, 1fr); }
.g-4 { grid-template-columns: repeat(4, 1fr); }
.mt { margin-top: 14px; }
.empty { padding: 36px 20px; text-align: center; color: var(--mute); }
.empty b { display: block; color: var(--ink); font: 420 20px/1.3 var(--serif); margin-bottom: 4px; }
.seg { display: inline-flex; gap: 2px; padding: 3px; border-radius: 999px; background: #fff; box-shadow: 0 0 0 1px var(--line); }
.seg button { height: 30px; padding: 0 12px; border-radius: 999px; font-size: 13px; font-weight: 500; color: var(--mute); display: inline-flex; align-items: center; gap: 6px; }
.seg button.on { background: #121419; color: #fff; }
.seg button .cnt { font-size: 11.5px; opacity: .7; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; }
.chip { flex: none; white-space: nowrap; height: 30px; padding: 0 12px; border-radius: 999px; background: #fff; box-shadow: inset 0 0 0 1px var(--line-2); font-size: 13px; font-weight: 500; color: var(--ink-2); display: inline-flex; align-items: center; gap: 7px; }
.chip.on { background: #121419; color: #fff; box-shadow: none; }
.chip .cnt { color: var(--faint); font-size: 12px; }
.chip.on .cnt { color: rgba(255,255,255,.65); }
.toolbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.toolbar .sp { flex: 1; }
.field { position: relative; display: flex; align-items: center; }
.field [data-ic] { position: absolute; left: 11px; color: var(--faint); font-size: 15px; pointer-events: none; }
.input { height: 34px; border-radius: 10px; border: 0; background: #fff; box-shadow: inset 0 0 0 1px var(--line-2); padding: 0 12px; font-size: 13.5px; outline: none; transition: box-shadow .15s; min-width: 0; }
.field .input { padding-left: 33px; }
.input:focus { box-shadow: inset 0 0 0 1.5px var(--blue); }
textarea.input { height: auto; padding: 10px 12px; line-height: 1.55; resize: vertical; width: 100%; }
select.input { padding-right: 28px; appearance: none; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='m7 10 5 5 5-5' fill='none' stroke='%236b6e74' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat right 8px center / 16px; }
.lbl { display: block; font-size: 12.5px; color: var(--mute); margin-bottom: 6px; font-weight: 500; }
.tgl { width: 36px; height: 21px; border-radius: 999px; background: #d6d8dc; position: relative; transition: background .2s; flex: none; }
.tgl::after { content: ""; position: absolute; left: 3px; top: 3px; width: 15px; height: 15px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.2); transition: transform .2s var(--ease); }
.tgl.on { background: var(--ink); }
.tgl.on::after { transform: translateX(15px); }

/* tables */
.tbl-wrap { overflow: auto; }
.tbl { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.tbl th { text-align: left; font-weight: 500; font-size: 12.5px; color: var(--mute); padding: 10px 14px; border-bottom: 1px solid var(--line); white-space: nowrap; position: sticky; top: 0; background: #fff; z-index: 1; }
.tbl th.sort { cursor: pointer; user-select: none; }
.tbl th.sort:hover { color: var(--ink); }
.tbl th .arr { display: inline-block; margin-left: 4px; font-size: 11px; opacity: .45; }
.tbl th.on { color: var(--ink); }
.tbl th.on .arr { opacity: 1; }
.tbl td { padding: 11px 14px; border-bottom: 1px solid var(--line); white-space: nowrap; vertical-align: middle; }
.tbl tbody tr { cursor: pointer; transition: background .12s; }
.tbl tbody tr:hover { background: #fafafa; }
.tbl tbody tr:last-child td { border-bottom: 0; }
.tbl .r { text-align: right; }
.tbl .m { color: var(--mute); }
.cell-who { display: flex; align-items: center; gap: 10px; }
.cell-who b { font-weight: 500; }
.cell-who small { display: block; color: var(--mute); font-size: 12px; }
.pager { display: flex; align-items: center; justify-content: space-between; padding: 12px 16px; border-top: 1px solid var(--line); color: var(--mute); font-size: 13px; }
.pager div { display: flex; gap: 6px; }

/* today */
.live-hero { position: relative; border-radius: 22px; overflow: hidden; padding: 26px 26px 24px; display: grid; grid-template-columns: 1fr 1.15fr; gap: 24px; align-items: center; background: #7fb8ec url(../img/sky.webp) no-repeat 30% 6% / 190% auto; min-height: 210px; }
.lh-copy { color: #fff; text-shadow: 0 1px 12px rgba(16,58,112,.25); }
.lh-copy .pill { background: rgba(255,255,255,.92); color: var(--green); text-shadow: none; }
.lh-copy h2 { margin: 12px 0 6px; font: 420 30px/1.1 var(--serif); font-variation-settings: "opsz" 32; letter-spacing: -.015em; }
.lh-copy p { margin: 0; font-size: 14px; color: rgba(255,255,255,.95); max-width: 340px; }
.lh-cards { display: grid; gap: 10px; }
.lh-card { display: flex; align-items: center; gap: 12px; background: #fff; border-radius: 999px; padding: 10px 10px 10px 12px; box-shadow: 0 10px 30px -18px rgba(14,40,80,.5); text-align: left; width: 100%; }
.lh-card .inq { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.lh-card .inq b { font-weight: 500; font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lh-card .inq small { font-size: 12.5px; color: var(--mute); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lh-card .el { font-size: 12.5px; color: var(--mute); font-variant-numeric: tabular-nums; }
.lh-card .btn { flex: none; }
.lh-paused { color: #fff; font-size: 14px; background: rgba(18,40,70,.28); border-radius: 16px; padding: 16px 18px; }
.kpi { padding: 16px 18px 16px; display: flex; flex-direction: column; gap: 4px; position: relative; overflow: hidden; }
.kpi .k { font-size: 13px; color: var(--mute); display: flex; justify-content: space-between; align-items: center; }
.kpi .v { font: 420 34px/1.1 var(--serif); font-variation-settings: "opsz" 32; letter-spacing: -.02em; margin-top: 4px; font-variant-numeric: tabular-nums; }
.kpi .d { font-size: 12.5px; color: var(--mute); }
.kpi .d .up { color: var(--green); font-weight: 500; }
.kpi .spark { position: absolute; right: 14px; bottom: 16px; width: 92px; height: 34px; }
.spark path.l { fill: none; stroke: var(--blue); stroke-width: 1.6; stroke-linejoin: round; stroke-linecap: round; }
.spark path.a { fill: url(#sparkfill); }
.draw path.l { stroke-dasharray: var(--len); stroke-dashoffset: var(--len); animation: draw 1.1s var(--ease) .15s forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }
.need { display: grid; grid-template-columns: auto 1fr; gap: 12px; padding: 14px 18px; border-top: 1px solid var(--line); }
.need:first-child { border-top: 0; }
.need-ico { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: var(--amber-tint); color: var(--amber); font-size: 16px; }
.need b { font-weight: 500; font-size: 14px; }
.need p { margin: 3px 0 10px; color: var(--mute); font-size: 13px; line-height: 1.5; }
.need .acts { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.need .acts .t { margin-left: auto; color: var(--faint); font-size: 12px; }
.need.done { opacity: .55; }
.need-ok { display: inline-flex; align-items: center; gap: 6px; color: var(--green); font-size: 13px; font-weight: 500; }
.bars { display: flex; align-items: flex-end; gap: 6px; height: 170px; padding: 6px 0 0; }
.bars .bcol { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; height: 100%; justify-content: flex-end; min-width: 0; }
.bars .stack { width: 100%; max-width: 30px; display: flex; flex-direction: column-reverse; border-radius: 6px; overflow: hidden; transform-origin: bottom; }
.bars .stack i { display: block; }
.bars .lbl2 { font-size: 11px; color: var(--faint); font-variant-numeric: tabular-nums; }
.grow .stack, .grow .bar { transform: scaleY(0); animation: grow .8s var(--ease) forwards; animation-delay: calc(var(--i) * 28ms); }
@keyframes grow { to { transform: scaleY(1); } }
.minis { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--line); margin-top: 16px; }
.minis div { padding: 14px 4px 0; }
.minis div + div { padding-left: 16px; border-left: 1px solid var(--line); }
.minis b { display: block; font: 420 22px/1.1 var(--serif); letter-spacing: -.01em; font-variant-numeric: tabular-nums; }
.minis small { color: var(--mute); font-size: 12.5px; }
.legend { display: flex; gap: 14px; font-size: 12.5px; color: var(--mute); }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 9px; height: 9px; border-radius: 3px; }
.lanes { position: relative; }
.lane { display: flex; align-items: center; height: 38px; border-bottom: 1px solid var(--line); }
.lane:last-child { border-bottom: 0; }
.lane-who { width: 108px; display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 500; flex: none; }
.lane-track { position: relative; flex: 1; height: 26px; }
.lane-hours { display: flex; margin-left: 108px; font-size: 11px; color: var(--faint); padding-bottom: 6px; border-bottom: 1px solid var(--line); position: relative; height: 22px; }
.lane-hours span { position: absolute; transform: translateX(-50%); }
.vb { position: absolute; top: 0; bottom: 0; border-radius: 7px; font-size: 11px; font-weight: 500; line-height: 26px; padding: 0 7px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; background: var(--t); color: var(--i); box-shadow: inset 2px 0 0 var(--c); cursor: pointer; }
.vb.hvac { --t: var(--hvac-t); --i: var(--hvac-i); --c: var(--hvac); }
.vb.plumb { --t: var(--plumb-t); --i: var(--plumb-i); --c: var(--plumb); }
.vb.elec { --t: var(--elec-t); --i: var(--elec-i); --c: var(--elec); }
.vb.past { opacity: .55; }
.nowline { position: absolute; top: -4px; bottom: 0; width: 0; border-left: 1.5px solid var(--red); z-index: 2; pointer-events: none; }
.nowline::before { content: ""; position: absolute; top: -3px; left: -4.5px; width: 7.5px; height: 7.5px; border-radius: 50%; background: var(--red); }
.feed { list-style: none; margin: 0; padding: 0 18px 10px; }
.feed li { display: grid; grid-template-columns: 54px 1fr; gap: 10px; padding: 9px 0; border-top: 1px solid var(--line); font-size: 13px; }
.feed li:first-child { border-top: 0; }
.feed .t { color: var(--faint); font-variant-numeric: tabular-nums; font-size: 12.5px; padding-top: 1px; }
.feed b { font-weight: 500; }
.feed a:hover { text-decoration: underline; text-underline-offset: 3px; }

/* inbox */
.inbox { display: grid; grid-template-columns: 372px minmax(0, 1fr); flex: 1; min-height: 0; gap: 0; padding: 0 14px 14px 0; }
.ib-list { display: flex; flex-direction: column; min-height: 0; min-width: 0; padding: 0 12px 0 22px; }
.ib-head { padding: 6px 0 12px; }
.ib-head h1 { margin: 0 0 12px; font: 420 26px/1.15 var(--serif); font-variation-settings: "opsz" 32; letter-spacing: -.015em; display: flex; align-items: baseline; gap: 10px; }
.ib-head h1 small { font: 400 13px/1 var(--sans); color: var(--mute); }
.ib-tabs { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; margin-bottom: 10px; }
.ib-tabs::-webkit-scrollbar { display: none; }
.ib-scroll { flex: 1; overflow: auto; min-height: 0; margin: 0 -6px; padding: 0 6px 20px; }
.ib-day { font-size: 12px; color: var(--faint); padding: 14px 6px 6px; }
.ib-row { display: grid; grid-template-columns: auto 1fr auto; gap: 11px; align-items: start; padding: 11px 12px; border-radius: 14px; cursor: pointer; transition: background .12s; position: relative; }
.ib-row:hover { background: rgba(20,21,24,.04); }
.ib-row.on { background: #fff; box-shadow: 0 0 0 1px var(--line), 0 1px 2px rgba(20,30,50,.04); }
.ib-row .who { display: flex; align-items: center; gap: 6px; min-width: 0; }
.ib-row .who b { font-weight: 500; font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ib-row .sub { font-size: 13px; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 1px; }
.ib-row .snip { font-size: 12.5px; color: var(--mute); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 1px; }
.ib-row .meta { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; }
.ib-row .meta time { font-size: 12px; color: var(--faint); font-variant-numeric: tabular-nums; }
.ib-row.unread::before { content: ""; position: absolute; left: 3px; top: 22px; width: 5px; height: 5px; border-radius: 50%; background: var(--blue); }
.ib-detail { background: #fff; border-radius: 20px; box-shadow: 0 0 0 1px rgba(20,21,24,.035); min-width: 0; min-height: 0; display: flex; flex-direction: column; overflow: hidden; }
.dt-head { display: flex; align-items: center; gap: 12px; padding: 16px 20px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.dt-head .back { display: none; }
.dt-who { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.dt-who b { font-weight: 500; font-size: 15px; display: flex; align-items: center; gap: 8px; }
.dt-who small { color: var(--mute); font-size: 12.5px; }
.dt-acts { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.dt-body { flex: 1; overflow: auto; display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 0; min-height: 0; }
.dt-main { padding: 18px 22px 30px; min-width: 0; }
.dt-side { padding: 18px 18px 30px; border-left: 1px solid var(--line); background: #fcfcfc; }
.dt-subject { margin: 0 0 14px; font: 420 23px/1.2 var(--serif); font-variation-settings: "opsz" 28; letter-spacing: -.012em; }
.banner { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border-radius: 14px; background: var(--amber-tint); color: #6e430c; margin-bottom: 16px; }
.banner [data-ic] { font-size: 18px; margin-top: 1px; }
.banner b { display: block; font-weight: 600; color: #5c370a; margin-bottom: 2px; }
.banner p { margin: 0; font-size: 13px; line-height: 1.5; }
.banner .acts { display: flex; gap: 6px; margin-top: 10px; flex-wrap: wrap; }
.banner.ok { background: var(--green-tint); color: #24683a; }
.banner.ok b { color: #1f5a32; }
.banner.live { background: var(--blue-tint); color: #1f5d9a; }
.banner.live b { color: #194f85; }
.player { display: flex; align-items: center; gap: 12px; padding: 10px 14px 10px 10px; border-radius: 14px; background: var(--sunk); margin-bottom: 14px; }
.play { width: 36px; height: 36px; border-radius: 50%; background: #121419; color: #fff; display: grid; place-items: center; font-size: 14px; flex: none; }
.play:hover { background: #2a2d33; }
.wave { flex: 1; height: 34px; cursor: pointer; }
.wave rect { fill: #cfd2d7; }
.wave rect.on { fill: var(--blue); }
.ptime { font-size: 12.5px; color: var(--mute); font-variant-numeric: tabular-nums; min-width: 74px; text-align: right; }
.speed { height: 26px; padding: 0 8px; border-radius: 8px; background: #fff; box-shadow: inset 0 0 0 1px var(--line-2); font-size: 12px; font-weight: 600; color: var(--ink-2); }
.tr { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.tr li { display: grid; grid-template-columns: 44px 62px 1fr; gap: 8px; padding: 8px 8px; border-radius: 10px; font-size: 14px; line-height: 1.5; cursor: pointer; transition: background .15s; }
.tr li:hover { background: #f8f8f8; }
.tr li.now { background: #f2f7fd; }
.tr li .ts { color: var(--faint); font-size: 12px; padding-top: 2px; font-variant-numeric: tabular-nums; }
.tr li .sp { font-weight: 500; font-size: 12.5px; color: var(--mute); padding-top: 2px; }
.tr li.p .sp { color: var(--blue-ink); }
.tr li p { margin: 0; color: var(--ink-2); }
.tr li.typing p { color: var(--faint); }
.msg { border-radius: 14px; padding: 14px 16px; background: var(--sunk); margin-bottom: 12px; }
.msg-h { display: flex; justify-content: space-between; gap: 10px; font-size: 12.5px; color: var(--mute); margin-bottom: 8px; }
.msg-h b { color: var(--ink); font-weight: 500; }
.msg p { margin: 0; font-size: 14px; line-height: 1.6; white-space: pre-wrap; color: var(--ink-2); }
.msg.porter { background: #f2f7fd; }
.draft { border-radius: 14px; box-shadow: inset 0 0 0 1px var(--line-2); padding: 12px; }
.draft-h { display: flex; justify-content: space-between; align-items: center; font-size: 12.5px; color: var(--mute); margin-bottom: 8px; }
.draft textarea { border: 0; box-shadow: none; padding: 4px; min-height: 190px; font-size: 14px; }
.draft-f { display: flex; justify-content: flex-end; gap: 6px; padding-top: 8px; border-top: 1px solid var(--line); }
.formgrid { display: grid; grid-template-columns: 110px 1fr; border-radius: 14px; box-shadow: inset 0 0 0 1px var(--line); overflow: hidden; margin-bottom: 14px; }
.formgrid div { padding: 10px 14px; border-top: 1px solid var(--line); font-size: 13.5px; }
.formgrid div:nth-child(-n+2) { border-top: 0; }
.formgrid div:nth-child(odd) { color: var(--mute); background: var(--sunk); }
.bubbles { display: flex; flex-direction: column; gap: 6px; }
.bub { max-width: 76%; padding: 9px 13px; border-radius: 18px; font-size: 14px; line-height: 1.45; }
.bub.c { background: #efefef; align-self: flex-start; border-bottom-left-radius: 6px; }
.bub.p { background: var(--blue); color: #fff; align-self: flex-end; border-bottom-right-radius: 6px; }
.side-card { background: #fff; border-radius: 16px; box-shadow: 0 0 0 1px var(--line); padding: 4px 14px; margin-bottom: 12px; }
.side-card h4 { margin: 0; padding: 12px 0 8px; font-size: 13px; font-weight: 500; display: flex; justify-content: space-between; align-items: center; }
.side-card h4 small { font-weight: 400; color: var(--faint); font-size: 12px; }
.kv { display: grid; grid-template-columns: 86px 1fr; gap: 10px; padding: 8px 0; border-top: 1px solid var(--line); font-size: 13px; line-height: 1.4; }
.kv dt { color: var(--mute); }
.kv dd { margin: 0; min-width: 0; }
.editable { cursor: text; border-radius: 6px; padding: 1px 4px; margin: -1px -4px; transition: background .12s; display: inline-block; }
.editable:hover { background: #f3f3f3; }
.editable input { width: 100%; border: 0; outline: none; background: #fff; box-shadow: inset 0 0 0 1.5px var(--blue); border-radius: 6px; padding: 2px 6px; font-size: 13px; }
.mini { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-top: 1px solid var(--line); cursor: pointer; }
.mini:first-of-type { border-top: 0; }
.mini .mi { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.mini .mi b { font-weight: 500; font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mini .mi small { color: var(--mute); font-size: 12px; }
.mini .chev { color: var(--faint); }
.ib-empty { flex: 1; display: grid; place-items: center; background: #7fb8ec url(../img/sky.webp) no-repeat 0 0 / cover; }
.ib-empty .card { padding: 22px 26px; text-align: center; max-width: 320px; }

/* jobs board */
.board { display: grid; grid-template-columns: repeat(5, minmax(240px, 1fr)); gap: 12px; overflow-x: auto; padding-bottom: 6px; align-items: start; }
.col { background: rgba(20,21,24,.035); border-radius: 16px; padding: 8px; min-height: 200px; transition: background .15s, box-shadow .15s; }
.col.over { background: var(--blue-tint); box-shadow: inset 0 0 0 1.5px rgba(63,143,224,.5); }
.col-h { display: flex; align-items: center; gap: 8px; padding: 6px 6px 10px; font-size: 13px; font-weight: 500; }
.col-h .cnt { color: var(--faint); font-weight: 400; }
.col-h .sum { margin-left: auto; color: var(--mute); font-weight: 400; font-size: 12.5px; }
.col-dot { width: 8px; height: 8px; border-radius: 50%; }
.jc { background: #fff; border-radius: 12px; padding: 11px 12px; box-shadow: 0 0 0 1px var(--line), 0 1px 2px rgba(20,30,50,.04); margin-bottom: 8px; cursor: grab; user-select: none; touch-action: pan-y; transition: box-shadow .15s, transform .15s; }
.jc:hover { box-shadow: 0 0 0 1px var(--line-2), 0 6px 16px -10px rgba(20,30,50,.3); }
.jc.drag { opacity: .4; }
.jc.moved { animation: moved 1.6s var(--ease); }
@keyframes moved { 0%, 40% { box-shadow: 0 0 0 2px var(--blue), 0 8px 20px -10px rgba(63,143,224,.5); } }
.jc-ghost { position: fixed; z-index: 90; pointer-events: none; transform: rotate(2deg); box-shadow: var(--shadow-pop); width: 240px; }
.jc-top { display: flex; justify-content: space-between; font-size: 12px; color: var(--faint); font-variant-numeric: tabular-nums; }
.jc-top .val { color: var(--ink-2); font-weight: 500; }
.jc b { display: block; font-weight: 500; font-size: 13.5px; margin: 4px 0 2px; }
.jc .cu { font-size: 12.5px; color: var(--mute); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.jc-foot { display: flex; align-items: center; gap: 8px; margin-top: 10px; font-size: 12px; color: var(--mute); }
.jc-foot .when { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.jc .by { display: inline-flex; align-items: center; gap: 4px; font-size: 11.5px; color: var(--blue-ink); background: var(--blue-tint); padding: 2px 7px; border-radius: 999px; }
.col-more { width: 100%; padding: 8px; border-radius: 10px; font-size: 12.5px; color: var(--mute); }
.col-more:hover { background: rgba(20,21,24,.05); }

/* calendar */
.cal-wrap { overflow: auto; border-radius: var(--r); }
.cal { display: grid; grid-template-columns: 56px repeat(var(--n), minmax(132px, 1fr)); min-width: calc(56px + var(--n) * 132px); position: relative; }
.cal-hd { position: sticky; top: 0; z-index: 3; background: #fff; border-bottom: 1px solid var(--line); padding: 10px 10px; display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 500; }
.cal-hd small { color: var(--faint); font-weight: 400; margin-left: auto; }
.cal-hd.corner { padding: 0; }
.cal-times { position: relative; }
.cal-times span { position: absolute; right: 8px; font-size: 11px; color: var(--faint); transform: translateY(-50%); font-variant-numeric: tabular-nums; }
.cal-col { position: relative; border-left: 1px solid var(--line); background-image: linear-gradient(var(--line) 1px, transparent 1px); background-size: 100% 56px; }
.cal-ev { position: absolute; left: 4px; right: 4px; border-radius: 9px; padding: 6px 8px; overflow: hidden; background: var(--t); color: var(--i); box-shadow: inset 3px 0 0 var(--c); cursor: pointer; transition: box-shadow .15s, transform .15s; text-align: left; }
.cal-ev:hover { box-shadow: inset 3px 0 0 var(--c), 0 6px 16px -8px rgba(20,30,50,.35); }
.cal-ev b { display: block; font-weight: 500; font-size: 12.5px; line-height: 1.25; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cal-ev small { display: block; font-size: 11.5px; opacity: .85; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cal-ev.hvac { --t: var(--hvac-t); --i: var(--hvac-i); --c: var(--hvac); }
.cal-ev.plumb { --t: var(--plumb-t); --i: var(--plumb-i); --c: var(--plumb); }
.cal-ev.elec { --t: var(--elec-t); --i: var(--elec-i); --c: var(--elec); }
.cal-ev.past { opacity: .6; }
.cal-ev .porter { position: absolute; top: 6px; right: 6px; width: 6px; height: 6px; border-radius: 50%; background: currentColor; opacity: .6; }
.cal-now { position: absolute; left: 56px; right: 0; border-top: 1.5px solid var(--red); z-index: 2; pointer-events: none; }
.cal-now span { position: absolute; left: -52px; top: -9px; font-size: 11px; color: #fff; background: var(--red); border-radius: 5px; padding: 1px 5px; font-weight: 600; }
.week { display: grid; grid-template-columns: 150px repeat(6, minmax(130px, 1fr)); min-width: 940px; }
.week > div { border-bottom: 1px solid var(--line); border-left: 1px solid var(--line); padding: 8px; min-height: 92px; }
.week .wh { min-height: 0; font-size: 12.5px; color: var(--mute); font-weight: 500; position: sticky; top: 0; background: #fff; z-index: 1; }
.week .wh.today { color: var(--blue-ink); }
.week .wt { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 500; border-left: 0; }
.week .chipv { display: block; width: 100%; text-align: left; font-size: 11.5px; padding: 4px 7px; border-radius: 7px; margin-bottom: 4px; background: var(--t); color: var(--i); box-shadow: inset 2px 0 0 var(--c); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chipv.hvac { --t: var(--hvac-t); --i: var(--hvac-i); --c: var(--hvac); }
.chipv.plumb { --t: var(--plumb-t); --i: var(--plumb-i); --c: var(--plumb); }
.chipv.elec { --t: var(--elec-t); --i: var(--elec-i); --c: var(--elec); }
.week .today-col { background: #fbfdff; }

/* calls */
.chart { width: 100%; height: 190px; display: block; }
.chart .gl { stroke: var(--line); }
.chart .ax { font-size: 10.5px; fill: var(--faint); font-family: var(--sans); }
.chart .bar { fill: var(--blue); opacity: .85; transform-box: fill-box; transform-origin: bottom; }
.chart .bar.weekend { fill: #9fc8f0; }
.chart .bar.ah { fill: #6f4fc0; opacity: .75; }

.bchart { display: flex; align-items: flex-end; gap: 4px; }
.bc { flex: 1; height: 100%; display: flex; align-items: flex-end; min-width: 0; }
.bc .bar { display: block; width: 100%; border-radius: 4px 4px 2px 2px; background: var(--blue); opacity: .88; transform-origin: bottom; min-height: 2px; }
.bc:hover .bar { opacity: 1; }
.bar.weekend { background: #9fc8f0; }
.bar.ah { background: #8a6fd0; }
.bar.ghost { background: #e4edf7; opacity: 1; }
.bc-ax { position: relative; height: 18px; margin-top: 6px; font-size: 11px; color: var(--faint); font-variant-numeric: tabular-nums; }
.bc-ax span { position: absolute; top: 0; transform: translateX(-50%); white-space: nowrap; }
.bc-ax span.first { transform: none; }
.bc-ax span.last { transform: translateX(-100%); }
.ig-stat { font-size: 12.5px; color: var(--ink-2); font-weight: 500; }
.ig-last { white-space: nowrap; }

/* rules */
.rule { display: grid; grid-template-columns: 1fr auto auto; gap: 14px; align-items: center; padding: 14px 18px; border-top: 1px solid var(--line); }
.rule:first-child { border-top: 0; }
.rule .w { font-weight: 500; font-size: 14px; }
.rule .t { color: var(--mute); font-size: 13px; margin-top: 2px; display: flex; align-items: center; gap: 6px; }
.rule .hits { color: var(--faint); font-size: 12px; white-space: nowrap; }
.rule.off .w, .rule.off .t { opacity: .5; }
.slider { width: 100%; accent-color: var(--ink); }
.hours { display: grid; grid-template-columns: 70px 1fr 1fr auto; gap: 10px; align-items: center; padding: 8px 0; border-top: 1px solid var(--line); font-size: 13.5px; }
.hours:first-child { border-top: 0; }
.voice { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.voice button { text-align: left; padding: 12px; border-radius: 12px; box-shadow: inset 0 0 0 1px var(--line-2); }
.voice button b { display: block; font-weight: 500; font-size: 13.5px; }
.voice button small { color: var(--mute); font-size: 12px; }
.voice button.on { box-shadow: inset 0 0 0 1.5px var(--ink); background: #fafafa; }
.oncall td { padding: 10px 14px; }

/* integrations */
.ig { padding: 16px 18px 16px; display: flex; flex-direction: column; gap: 10px; }
.ig-top { display: flex; align-items: center; gap: 12px; }
.mono { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; font: 600 14px/1 var(--sans); letter-spacing: -.02em; background: #f1f1f1; color: var(--ink-2); box-shadow: inset 0 0 0 1px var(--line); flex: none; }
.mono.core { background: var(--blue); color: #fff; box-shadow: none; }
.ig-top b { display: block; font-weight: 500; font-size: 14.5px; }
.ig-top small { color: var(--mute); font-size: 12.5px; }
.ig p { margin: 0; color: var(--mute); font-size: 13px; line-height: 1.5; flex: 1; }
.ig-foot { display: flex; align-items: center; gap: 8px; padding-top: 10px; border-top: 1px solid var(--line); font-size: 12.5px; color: var(--mute); }
.ig-foot .ok { display: inline-flex; align-items: center; gap: 6px; color: var(--green); font-weight: 500; }
.ig-foot .ok::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.ig-foot .sp { flex: 1; }

/* billing */
.meter { height: 10px; border-radius: 999px; background: #eee; overflow: hidden; }
.meter i { display: block; height: 100%; border-radius: 999px; background: var(--blue); transform-origin: left; }
.grow-x { transform: scaleX(0); animation: growx 1s var(--ease) .1s forwards; }
@keyframes growx { to { transform: scaleX(1); } }
.plan-big { display: flex; align-items: baseline; gap: 8px; }
.plan-big b { font: 420 40px/1 var(--serif); letter-spacing: -.02em; }
.plans-m { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.plan-opt { text-align: left; padding: 14px; border-radius: 14px; box-shadow: inset 0 0 0 1px var(--line-2); display: flex; flex-direction: column; gap: 4px; }
.plan-opt b { font-weight: 600; }
.plan-opt .pr { font: 420 26px/1.1 var(--serif); margin: 6px 0 2px; }
.plan-opt small { color: var(--mute); font-size: 12px; line-height: 1.4; }
.plan-opt.on { box-shadow: inset 0 0 0 1.5px var(--ink); background: #fafafa; }

/* settings */
.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--line); margin-bottom: 18px; }
.tabs button { padding: 10px 14px; font-size: 13.5px; font-weight: 500; color: var(--mute); border-bottom: 2px solid transparent; margin-bottom: -1px; }
.tabs button.on { color: var(--ink); border-bottom-color: var(--ink); }
.form-row { display: grid; grid-template-columns: 220px 1fr; gap: 24px; padding: 18px 0; border-top: 1px solid var(--line); }
.form-row:first-child { border-top: 0; }
.form-row h4 { margin: 0; font-size: 14px; font-weight: 500; }
.form-row p { margin: 4px 0 0; font-size: 12.5px; color: var(--mute); }
.zip { display: inline-flex; align-items: center; gap: 4px; height: 28px; padding: 0 6px 0 10px; border-radius: 999px; background: #f1f1f1; font-size: 12.5px; font-variant-numeric: tabular-nums; }
.zip button { width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center; font-size: 12px; color: var(--mute); }
.zip button:hover { background: #e2e2e2; }

/* layer: menus, popovers, modals, drawers, palette, toasts */
.menu { position: fixed; z-index: 80; min-width: 220px; background: #fff; border-radius: 14px; box-shadow: var(--shadow-pop), 0 0 0 1px var(--line); padding: 6px; animation: pop .14s var(--ease); }
@keyframes pop { from { opacity: 0; transform: translateY(-4px) scale(.98); } }
.menu button, .menu a { display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px 10px; border-radius: 9px; font-size: 13.5px; text-align: left; color: var(--ink-2); }
.menu button:hover, .menu a:hover, .menu .act { background: #f4f4f4; color: var(--ink); }
.menu [data-ic] { font-size: 16px; color: var(--mute); }
.menu kbd { margin-left: auto; }
.menu .sep { height: 1px; background: var(--line); margin: 5px 4px; }
.menu .hint { padding: 6px 10px 4px; font-size: 12px; color: var(--faint); }
.menu .danger { color: var(--red); }
.menu .check { margin-left: auto; color: var(--blue-ink); }
.menu .dis { opacity: .55; }
.pop { position: fixed; z-index: 80; width: 380px; max-width: calc(100vw - 20px); background: #fff; border-radius: 18px; box-shadow: var(--shadow-pop), 0 0 0 1px var(--line); animation: pop .16s var(--ease); overflow: hidden; }
.pop-h { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px 10px; }
.pop-h b { font-weight: 500; }
.notif { display: grid; grid-template-columns: auto 1fr; gap: 12px; padding: 12px 16px; border-top: 1px solid var(--line); cursor: pointer; }
.notif:hover { background: #fafafa; }
.notif .ni { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-size: 15px; }
.notif p { margin: 0; font-size: 13px; line-height: 1.45; }
.notif small { color: var(--faint); font-size: 12px; }
.notif.unread p { font-weight: 500; }
.ovl { position: fixed; inset: 0; z-index: 70; background: rgba(20,24,30,.28); animation: fade .18s; }
@keyframes fade { from { opacity: 0; } }
.modal { position: fixed; z-index: 75; left: 50%; top: 12vh; transform: translateX(-50%); width: min(520px, calc(100vw - 24px)); max-height: 80vh; overflow: auto; background: #fff; border-radius: 20px; box-shadow: var(--shadow-pop); animation: modal .2s var(--ease); }
.modal.wide { width: min(720px, calc(100vw - 24px)); }
@keyframes modal { from { opacity: 0; transform: translate(-50%, 8px) scale(.98); } }
.modal-h { display: flex; align-items: center; justify-content: space-between; padding: 18px 20px 6px; }
.modal-h h3 { margin: 0; font: 420 21px/1.2 var(--serif); font-variation-settings: "opsz" 28; letter-spacing: -.01em; }
.modal-b { padding: 8px 20px 4px; }
.modal-b p { color: var(--mute); margin: 0 0 12px; }
.modal-f { display: flex; justify-content: flex-end; gap: 8px; padding: 16px 20px 18px; }
.fgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 12px; }
.fgrid .full { grid-column: 1 / -1; }
.fgrid .input { width: 100%; }
.drawer { position: fixed; z-index: 75; top: 8px; right: 8px; bottom: 8px; width: min(460px, calc(100vw - 16px)); background: #fff; border-radius: 20px; box-shadow: var(--shadow-pop); display: flex; flex-direction: column; animation: drawer .24s var(--ease); overflow: hidden; }
@keyframes drawer { from { transform: translateX(24px); opacity: 0; } }
.drawer-h { display: flex; align-items: flex-start; gap: 12px; padding: 18px 18px 14px; border-bottom: 1px solid var(--line); }
.drawer-h .tt { flex: 1; min-width: 0; }
.drawer-h .tt small { color: var(--mute); font-size: 12.5px; }
.drawer-h h3 { margin: 2px 0 0; font: 420 22px/1.2 var(--serif); font-variation-settings: "opsz" 28; letter-spacing: -.012em; }
.drawer-b { flex: 1; overflow: auto; padding: 14px 18px 20px; }
.drawer-f { display: flex; gap: 8px; padding: 12px 18px; border-top: 1px solid var(--line); flex-wrap: wrap; }
.dsec { margin-bottom: 18px; }
.dstats { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-bottom: 16px; }
.dsec h4 { margin: 0 0 8px; font-size: 12.5px; font-weight: 500; color: var(--mute); }
.tl { list-style: none; margin: 0; padding: 0; }
.tl li { position: relative; padding: 0 0 14px 20px; font-size: 13px; }
.tl li::before { content: ""; position: absolute; left: 4px; top: 6px; width: 7px; height: 7px; border-radius: 50%; background: var(--blue); }
.tl li::after { content: ""; position: absolute; left: 7px; top: 15px; bottom: 0; width: 1px; background: var(--line-2); }
.tl li:last-child::after { display: none; }
.tl small { display: block; color: var(--faint); font-size: 12px; }
.palette { position: fixed; z-index: 78; left: 50%; top: 14vh; transform: translateX(-50%); width: min(600px, calc(100vw - 24px)); background: #fff; border-radius: 18px; box-shadow: var(--shadow-pop), 0 0 0 1px var(--line); overflow: hidden; animation: modal .18s var(--ease); }
.pal-in { display: flex; align-items: center; gap: 10px; padding: 14px 16px; border-bottom: 1px solid var(--line); }
.pal-in [data-ic] { color: var(--faint); font-size: 18px; }
.pal-in input { flex: 1; border: 0; outline: none; font-size: 15px; background: none; }
.pal-list { max-height: 52vh; overflow: auto; padding: 6px; }
.pal-g { font-size: 12px; color: var(--faint); padding: 10px 10px 4px; }
.pal-i { display: flex; align-items: center; gap: 10px; width: 100%; padding: 9px 10px; border-radius: 10px; font-size: 13.5px; text-align: left; }
.pal-i [data-ic] { color: var(--mute); font-size: 16px; }
.pal-i small { color: var(--faint); margin-left: auto; font-size: 12px; }
.pal-i.act { background: #f2f4f7; }
.pal-f { display: flex; gap: 14px; padding: 10px 16px; border-top: 1px solid var(--line); font-size: 12px; color: var(--faint); }
.toasts { position: fixed; z-index: 95; left: 50%; bottom: 20px; transform: translateX(-50%); display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; }
.toast { pointer-events: auto; display: flex; align-items: center; gap: 12px; background: #17191d; color: #fff; padding: 10px 10px 10px 16px; border-radius: 14px; font-size: 13.5px; box-shadow: 0 16px 40px -14px rgba(0,0,0,.5); animation: toast .24s var(--ease); max-width: calc(100vw - 24px); }
.toast [data-ic] { color: #7fd29a; font-size: 16px; }
.toast button { color: #9cc8f4; font-weight: 600; padding: 4px 8px; border-radius: 8px; }
.toast button:hover { background: rgba(255,255,255,.08); }
.toast.out { opacity: 0; transform: translateY(6px); transition: .2s; }
@keyframes toast { from { opacity: 0; transform: translateY(8px); } }
.tip { position: fixed; z-index: 99; background: #17191d; color: #fff; font-size: 12px; padding: 5px 8px; border-radius: 7px; pointer-events: none; white-space: nowrap; display: flex; gap: 6px; align-items: center; }
.tip kbd { background: rgba(255,255,255,.12); color: #fff; box-shadow: none; }

/* responsive: rail at tablet, drawer on phones */
@media (max-width: 1240px) {
  .dt-body { grid-template-columns: 1fr; }
  .dt-side { border-left: 0; border-top: 1px solid var(--line); }
  .g-4 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 1180px) {
  .inbox { grid-template-columns: 320px minmax(0, 1fr); }
  .search { width: 220px; }
  .g-2, .g-2b { grid-template-columns: 1fr; }
}
@media (min-width: 761px) and (max-width: 1180px) {
  :root { --side: 68px; }
  .side { padding: 12px 8px; align-items: center; }
  .ws { padding: 4px; justify-content: center; flex: none; }
  .ws-txt, .ws-chev, .status-txt, .nav-label, .nav a span:not(.ni), .nav a .nb, .nav a .nc, .me-txt, .me-dots { display: none; }
  .status { width: 44px; height: 36px; padding: 0; justify-content: center; margin: 14px 0 10px; }
  .nav { align-items: center; width: 100%; }
  .nav a { width: 44px; justify-content: center; padding: 0; }
  .nav a .nb-dot { position: absolute; top: 7px; right: 8px; width: 7px; height: 7px; border-radius: 50%; background: #e0892b; }
  .side-foot { align-items: center; width: 100%; }
  .me { padding: 4px; }
  .ariadne { margin: 0; padding: 6px 7px; font-size: 0; }
  .ariadne::before { content: "A"; font-size: 12px; font-weight: 600; color: #ff8a3d; }
  .ariadne b { display: none; }
}
@media (min-width: 1181px), (max-width: 760px) { .nb-dot { display: none; } }
@media (max-width: 900px) {
  .inbox { grid-template-columns: minmax(0, 1fr); padding: 0; }
  .inbox.has-detail .ib-list { display: none; }
  .inbox:not(.has-detail) .ib-detail { display: none; }
  .ib-detail { border-radius: 0; }
  .dt-head .back { display: inline-grid; }
  .live-hero { grid-template-columns: 1fr; }
  .g-3 { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; gap: 10px; }
}
@media (max-width: 760px) {
  .app { grid-template-columns: 1fr; }
  .side { position: fixed; z-index: 60; top: 0; bottom: 0; left: 0; width: 280px; transform: translateX(-105%); transition: transform .28s var(--ease); align-items: stretch; padding: 12px 12px; box-shadow: var(--shadow-pop); }
  .side.open { transform: none; }
  .icon-btn.side-close { display: inline-grid; }
  .scrim { position: fixed; inset: 0; z-index: 55; background: rgba(20,24,30,.3); }
  .icon-btn.menu-btn { display: inline-grid; }
  .top { padding: 0 10px; gap: 6px; }
  .search { width: 36px; padding: 0; justify-content: center; box-shadow: none; background: none; }
  .search-txt, .search kbd { display: none; }
  .new-txt { display: none; }
  .new-btn { width: 34px; padding: 0; }
  .page { padding: 4px 14px 40px; }
  .pt { font-size: 27px; }
  .g-4 { grid-template-columns: 1fr 1fr; gap: 10px; }
  .kpi { padding: 14px; }
  .kpi .v { font-size: 28px; }
  .kpi .spark { display: none; }
  .live-hero { padding: 18px; }
  .lh-card .btn { display: none; }
  .ib-list { padding: 0 12px; }
  .dt-head { padding: 12px 14px; gap: 10px; }
  .dt-head > .av { display: none; }
  .dt-who { flex: 1 1 200px; }
  .dt-acts { width: 100%; }
  .dt-acts .icon-btn { margin-left: auto; }
  .dt-main { padding: 14px 14px 24px; }
  .dt-side { padding: 14px; }
  .tr li { grid-template-columns: 54px 1fr; }
  .tr li .ts { display: none; }
  .player .speed { display: none; }
  .ptime { min-width: 0; }
  .lane-who { width: 74px; font-size: 12px; }
  .lane-who .av { display: none; }
  .lane-hours { margin-left: 74px; }
  .ph { margin: 6px 0 16px; }
  .toolbar .field, .toolbar .field .input { width: 100%; }
  .modal { top: auto; bottom: 8px; transform: translateX(-50%); max-height: 86vh; }
  @keyframes modal { from { opacity: 0; transform: translate(-50%, 16px); } }
  .plans-m, .voice { grid-template-columns: 1fr; }
  .fgrid { grid-template-columns: 1fr; }
  .hours { grid-template-columns: 50px 1fr 1fr auto; }
  .rule { grid-template-columns: 1fr auto; }
  .rule .hits { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .grow .stack, .grow .bar, .grow-x { transform: none !important; }
  .draw path.l { stroke-dashoffset: 0 !important; }
}
