/* MCPL Work — design system
   Palette: deep river blue for structure, the company's #336699 for action,
   turmeric for "waiting on someone", leaf for done, brick for problems.
   Type: Hind Madurai — one family that sets both Tamil and English. */
:root {
  --ink: #17283A;
  --ink-2: #4A5B6D;
  --ink-3: #7A8897;
  --line: #DCE3EA;
  --line-2: #EAEFF3;
  --canvas: #EEF2F5;
  --surface: #FFFFFF;
  --brand: #336699;
  --brand-ink: #24496E;
  --brand-soft: #E3ECF5;
  --deep: #1B3550;
  --deep-2: #24476A;
  --turmeric: #C98F12;
  --turmeric-soft: #FBF1D9;
  --leaf: #2E7D5B;
  --leaf-soft: #E1F1E9;
  --brick: #B24A35;
  --brick-soft: #F8E4DF;
  --radius: 12px;
  --radius-s: 8px;
  --side: 264px;
  --top: 60px;
  --focus: 0 0 0 3px rgba(51, 102, 153, .35);
  font-family: 'Hind Madurai', 'Noto Sans Tamil', system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-size: 16px;
  color: var(--ink);
  -webkit-text-size-adjust: 100%;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { background: var(--canvas); line-height: 1.45; font-variant-numeric: tabular-nums; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: none; box-shadow: var(--focus); border-radius: 6px; }
h1, h2, h3, h4 { margin: 0; line-height: 1.2; font-weight: 600; }
h1 { font-size: 1.5rem; }
h2 { font-size: 1.15rem; }
h3 { font-size: 1rem; }
p { margin: 0 0 .6em; }
small, .muted { color: var(--ink-3); }
.hidden { display: none !important; }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }

/* ---------- Shell ---------- */
.shell { display: grid; grid-template-columns: var(--side) 1fr; min-height: 100vh; }
.side {
  background: var(--deep); color: #D7E2EE; position: sticky; top: 0; height: 100vh; overflow-y: auto;
  display: flex; flex-direction: column; padding: 18px 14px 24px; scrollbar-width: thin; scrollbar-color: #36577A transparent;
}
.brandmark { display: flex; align-items: center; gap: 10px; padding: 2px 8px 18px; color: #fff; }
.brandmark img { height: 30px; }
.brandmark b { font-weight: 600; font-size: 1.02rem; letter-spacing: .2px; }
.brandmark span { display: block; font-size: .75rem; color: #9DB3C9; margin-top: -2px; }
.navgroup { margin-top: 18px; }
.navgroup > .gh { font-size: .78rem; color: #8FA7BF; padding: 0 10px 6px; }
.navlink {
  display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 9px; color: #D7E2EE; text-decoration: none;
  font-size: .95rem; position: relative;
}
.navlink:hover { background: var(--deep-2); text-decoration: none; color: #fff; }
.navlink.active { background: #fff; color: var(--deep); font-weight: 600; }
.navlink .ic { width: 20px; height: 20px; flex: none; opacity: .9; }
.navlink .count { margin-left: auto; font-size: .78rem; min-width: 22px; text-align: center; padding: 1px 7px; border-radius: 99px; background: #2D5279; color: #fff; font-weight: 600; }
.navlink.active .count { background: var(--brand); }
.navlink .count.warn { background: var(--turmeric); color: #1d1500; }

/* The journey rail: the customer's path drawn as a line through the stages. */
.rail { position: relative; padding-left: 4px; }
.rail .navlink { padding-left: 34px; }
.rail .navlink::before {
  content: ''; position: absolute; left: 15px; top: 50%; width: 11px; height: 11px; margin-top: -5.5px; border-radius: 50%;
  border: 2px solid #6F8DAD; background: var(--deep); z-index: 1;
}
.rail .navlink.has::before { background: #A9C2DB; border-color: #A9C2DB; }
.rail .navlink.active::before { background: var(--brand); border-color: var(--brand); }
.rail::before { content: ''; position: absolute; left: 24.5px; top: 18px; bottom: 18px; width: 2px; background: #3B5D80; }
.side .foot { margin-top: auto; padding: 18px 10px 0; font-size: .8rem; color: #8FA7BF; }

.main { min-width: 0; display: flex; flex-direction: column; }
.topbar {
  height: var(--top); display: flex; align-items: center; gap: 12px; padding: 0 28px; background: var(--canvas);
  position: sticky; top: 0; z-index: 20; border-bottom: 1px solid transparent;
}
.topbar.scrolled { border-bottom-color: var(--line); background: rgba(238, 242, 245, .94); backdrop-filter: blur(6px); }
.topbar .title { font-size: 1.2rem; font-weight: 600; flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.topbar .back { display: none; }
.iconbtn { width: 40px; height: 40px; border-radius: 10px; border: 0; background: transparent; display: inline-flex; align-items: center; justify-content: center; cursor: pointer; position: relative; color: var(--ink-2); }
.iconbtn:hover { background: var(--line-2); }
.iconbtn .dot { position: absolute; top: 7px; right: 7px; min-width: 16px; height: 16px; border-radius: 9px; background: var(--brick); color: #fff; font-size: .68rem; display: flex; align-items: center; justify-content: center; padding: 0 4px; font-weight: 700; }
.userchip { display: flex; align-items: center; gap: 8px; padding: 4px 10px 4px 4px; border-radius: 99px; border: 1px solid var(--line); background: var(--surface); cursor: pointer; }
.avatar { width: 30px; height: 30px; border-radius: 50%; background: var(--brand); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 600; font-size: .85rem; }
.userchip .who { line-height: 1.1; font-size: .85rem; }
.userchip .who small { display: block; font-size: .72rem; }
.content { padding: 8px 28px 48px; max-width: 1240px; width: 100%; }
.content.wide { max-width: none; }

.bottomnav, .mtop { display: none; }

@media (max-width: 900px) {
  .shell { grid-template-columns: 1fr; }
  .side { position: fixed; inset: 0 auto 0 0; width: min(84vw, 320px); z-index: 60; transform: translateX(-102%); transition: transform .22s ease; height: 100%; }
  body.nav-open .side { transform: none; box-shadow: 0 0 0 100vmax rgba(10, 20, 30, .45); }
  .topbar { padding: 0 8px 0 4px; height: 56px; background: var(--surface); border-bottom-color: var(--line); }
  .topbar .back { display: inline-flex; }
  .topbar .title { font-size: 1.05rem; }
  .userchip .who { display: none; }
  .userchip { padding: 2px; border: 0; }
  .content { padding: 12px 14px 96px; }
  .bottomnav {
    display: grid; grid-template-columns: repeat(5, 1fr); position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; background: var(--surface);
    border-top: 1px solid var(--line); padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
  }
  .bottomnav a { display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: .72rem; color: var(--ink-3); text-decoration: none; padding: 4px 0; position: relative; }
  .bottomnav a.active { color: var(--brand); font-weight: 600; }
  .bottomnav a .ic { width: 24px; height: 24px; }
  .bottomnav a .count { position: absolute; top: 0; left: 55%; background: var(--brick); color: #fff; border-radius: 9px; font-size: .65rem; padding: 0 5px; font-weight: 700; }
  .bottomnav .plus { align-self: center; }
  .bottomnav .plus span.p { width: 48px; height: 48px; border-radius: 16px; background: var(--brand); color: #fff; display: flex; align-items: center; justify-content: center; margin-top: -18px; box-shadow: 0 4px 14px rgba(51, 102, 153, .4); }
}

/* ---------- Building blocks ---------- */
.pagehead { display: flex; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin: 6px 0 18px; }
.pagehead .lead { color: var(--ink-2); max-width: 70ch; margin: 4px 0 0; }
.pagehead .grow { flex: 1; min-width: 220px; }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); margin-bottom: 18px; }
.panel > .ph { display: flex; align-items: center; gap: 10px; padding: 14px 18px; border-bottom: 1px solid var(--line-2); }
.panel > .ph h2, .panel > .ph h3 { flex: 1; }
.panel > .pb { padding: 16px 18px; }
.panel.flat { border: 0; background: transparent; }
.grid { display: grid; gap: 18px; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.split { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(300px, 1fr); gap: 18px; align-items: start; }
@media (max-width: 1100px) { .split { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 720px) { .g2, .g3 { grid-template-columns: minmax(0, 1fr); } }

/* Figures strip: numbers that matter on a dashboard, set in a row, not cards. */
.figures { display: flex; flex-wrap: wrap; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); margin-bottom: 18px; }
.figure { flex: 1 1 150px; padding: 14px 18px; border-right: 1px solid var(--line-2); text-decoration: none; color: inherit; }
.figure:last-child { border-right: 0; }
a.figure:hover { background: #F7FAFC; text-decoration: none; }
.figure .n { font-size: 1.7rem; font-weight: 600; line-height: 1.1; }
.figure .l { color: var(--ink-2); font-size: .9rem; }
.figure.attn .n { color: var(--turmeric); }
.figure.bad .n { color: var(--brick); }

/* Rows: the main way lists are shown. */
.rows { list-style: none; margin: 0; padding: 0; }
.rowi { display: flex; align-items: center; gap: 14px; padding: 12px 18px; border-bottom: 1px solid var(--line-2); color: inherit; text-decoration: none; }
.rowi:last-child { border-bottom: 0; }
a.rowi:hover, button.rowi:hover { background: #F7FAFC; text-decoration: none; }
button.rowi { width: 100%; text-align: left; border: 0; background: transparent; cursor: pointer; }
.rowi .main1 { flex: 1; min-width: 0; }
.rowi .t { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rowi .s { color: var(--ink-2); font-size: .88rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rowi .r { text-align: right; flex: none; font-size: .9rem; }
.rowi .chev { color: var(--ink-3); flex: none; }
.empty { padding: 34px 18px; text-align: center; color: var(--ink-2); }
.empty h3 { margin-bottom: 6px; color: var(--ink); }

.tag { display: inline-flex; align-items: center; gap: 4px; padding: 1px 9px; border-radius: 99px; font-size: .78rem; font-weight: 600; background: var(--line-2); color: var(--ink-2); white-space: nowrap; }
.tag.blue { background: var(--brand-soft); color: var(--brand-ink); }
.tag.wait { background: var(--turmeric-soft); color: #7A5400; }
.tag.ok { background: var(--leaf-soft); color: var(--leaf); }
.tag.bad { background: var(--brick-soft); color: var(--brick); }

table.t { width: 100%; border-collapse: collapse; font-size: .93rem; }
table.t th { text-align: left; font-weight: 600; color: var(--ink-2); font-size: .84rem; padding: 10px 12px; border-bottom: 1px solid var(--line); background: #F8FAFC; white-space: nowrap; }
table.t td { padding: 10px 12px; border-bottom: 1px solid var(--line-2); vertical-align: top; }
table.t tr:last-child td { border-bottom: 0; }
table.t td.num, table.t th.num { text-align: right; }
table.t tr.idle td { background: #FDF5F3; }
.tablewrap { overflow-x: auto; }

/* Definition list for record details */
.dl { display: grid; grid-template-columns: minmax(130px, 34%) 1fr; gap: 8px 16px; margin: 0; }
.dl dt { color: var(--ink-2); font-size: .9rem; }
.dl dd { margin: 0; font-weight: 500; overflow-wrap: anywhere; }

/* ---------- Buttons & forms ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 42px; padding: 0 18px; border-radius: 10px;
  border: 1px solid var(--line); background: var(--surface); color: var(--ink); font-weight: 600; cursor: pointer; text-decoration: none; white-space: nowrap;
}
.btn:hover { background: #F4F7FA; text-decoration: none; }
.btn.primary { background: var(--brand); border-color: var(--brand); color: #fff; }
.btn.primary:hover { background: var(--brand-ink); }
.btn.good { background: var(--leaf); border-color: var(--leaf); color: #fff; }
.btn.danger { color: var(--brick); border-color: #E8C2B9; }
.btn.danger.solid { background: var(--brick); color: #fff; border-color: var(--brick); }
.btn.ghost { border-color: transparent; background: transparent; color: var(--brand); }
.btn.small { min-height: 34px; padding: 0 12px; font-size: .9rem; border-radius: 8px; }
.btn.block { width: 100%; }
.btn[disabled] { opacity: .55; cursor: not-allowed; }
.btns { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.btns.end { justify-content: flex-end; }

.field { display: flex; flex-direction: column; gap: 5px; margin-bottom: 14px; min-width: 0; }
.field > label { font-size: .9rem; font-weight: 600; color: var(--ink); }
.field > label .opt { font-weight: 400; color: var(--ink-3); }
.field .hint { font-size: .82rem; color: var(--ink-3); }
.field .err { font-size: .84rem; color: var(--brick); font-weight: 600; }
.input, select.input, textarea.input {
  width: 100%; min-height: 46px; padding: 10px 12px; border: 1px solid #C9D3DD; border-radius: 10px; background: #fff; font-size: 1rem;
}
textarea.input { min-height: 84px; resize: vertical; }
.input:focus { border-color: var(--brand); box-shadow: var(--focus); outline: none; }
.field.invalid .input { border-color: var(--brick); }
.formgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 18px; }
.formgrid .full { grid-column: 1 / -1; }
@media (max-width: 720px) { .formgrid { grid-template-columns: 1fr; } }
.choices { display: flex; flex-wrap: wrap; gap: 8px; }
.choice { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 14px; border: 1px solid #C9D3DD; border-radius: 10px; background: #fff; cursor: pointer; user-select: none; }
.choice input { width: 18px; height: 18px; accent-color: var(--brand); margin: 0; }
.choice:has(input:checked) { border-color: var(--brand); background: var(--brand-soft); color: var(--brand-ink); font-weight: 600; }
.seg { display: inline-flex; background: var(--line-2); border-radius: 10px; padding: 3px; gap: 2px; flex-wrap: wrap; }
.seg button { border: 0; background: transparent; padding: 7px 14px; border-radius: 8px; cursor: pointer; font-weight: 600; color: var(--ink-2); }
.seg button.on { background: #fff; color: var(--ink); box-shadow: 0 1px 2px rgba(0, 0, 0, .08); }
.searchbox { position: relative; }
.searchbox .input { padding-left: 38px; }
.searchbox svg { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--ink-3); }
.toolbar { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 14px; }
.toolbar .grow { flex: 1; min-width: 200px; }

/* Notices */
.note { display: flex; gap: 10px; padding: 12px 14px; border-radius: 10px; background: var(--brand-soft); color: var(--brand-ink); margin-bottom: 14px; font-size: .95rem; }
.note.wait { background: var(--turmeric-soft); color: #6B4A00; }
.note.bad { background: var(--brick-soft); color: #8A3424; }
.note.ok { background: var(--leaf-soft); color: #22603F; }
.note b { font-weight: 600; }

/* The customer's journey drawn across the top of their record. */
.journey { display: flex; gap: 0; overflow-x: auto; padding: 4px 2px 10px; margin-bottom: 8px; scrollbar-width: thin; }
.journey .st { flex: 1 0 104px; position: relative; text-align: center; font-size: .8rem; color: var(--ink-3); padding-top: 22px; }
.journey .st::before { content: ''; position: absolute; top: 7px; left: 50%; width: 14px; height: 14px; margin-left: -7px; border-radius: 50%; border: 2px solid #B6C4D2; background: var(--canvas); z-index: 1; }
.journey .st::after { content: ''; position: absolute; top: 13px; left: 50%; width: 100%; height: 2px; background: #C9D4DF; }
.journey .st:last-child::after { display: none; }
.journey .st.done { color: var(--ink-2); }
.journey .st.done::before { background: var(--brand); border-color: var(--brand); }
.journey .st.done::after { background: var(--brand); }
.journey .st.now { color: var(--ink); font-weight: 600; }
.journey .st.now::before { background: #fff; border-color: var(--turmeric); box-shadow: 0 0 0 4px var(--turmeric-soft); }
.journey .st.stop::before { background: var(--brick); border-color: var(--brick); }

/* Checklist */
.checklist { list-style: none; margin: 0; padding: 0; }
.checklist li { display: flex; align-items: center; gap: 10px; padding: 9px 0; border-bottom: 1px solid var(--line-2); }
.checklist li:last-child { border-bottom: 0; }
.tick { width: 22px; height: 22px; border-radius: 50%; border: 2px solid #C1CDD8; flex: none; display: flex; align-items: center; justify-content: center; color: #fff; }
.tick.on { background: var(--leaf); border-color: var(--leaf); }
.checklist li .grow { flex: 1; }

/* Photos */
.photos { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 10px; }
.photo { position: relative; border-radius: 10px; overflow: hidden; background: #DDE5EC; aspect-ratio: 4 / 3; }
.photo img { width: 100%; height: 100%; object-fit: cover; display: block; cursor: zoom-in; }
.photo .cap { position: absolute; left: 0; right: 0; bottom: 0; padding: 4px 8px; font-size: .74rem; color: #fff; background: linear-gradient(transparent, rgba(0, 0, 0, .65)); }
.photo .x { position: absolute; top: 6px; right: 6px; width: 28px; height: 28px; border-radius: 50%; border: 0; background: rgba(0, 0, 0, .55); color: #fff; cursor: pointer; }
.addphoto { border: 2px dashed #B8C6D3; border-radius: 10px; aspect-ratio: 4 / 3; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; color: var(--brand); font-weight: 600; cursor: pointer; background: #fff; font-size: .9rem; text-align: center; padding: 6px; }
.compare { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; }
.compare .col h4 { margin: 0 0 8px; font-size: .92rem; }

/* Timeline */
.timeline { list-style: none; margin: 0; padding: 0 0 0 18px; border-left: 2px solid var(--line); }
.timeline li { position: relative; padding: 0 0 14px 14px; font-size: .92rem; }
.timeline li::before { content: ''; position: absolute; left: -25px; top: 6px; width: 10px; height: 10px; border-radius: 50%; background: var(--brand); border: 2px solid #fff; }
.timeline li .when { color: var(--ink-3); font-size: .8rem; }

/* Sheets, modals and toasts */
.scrim { position: fixed; inset: 0; background: rgba(15, 28, 42, .5); z-index: 100; display: flex; align-items: center; justify-content: center; padding: 20px; animation: fade .15s ease; }
.modal { background: var(--surface); border-radius: 16px; width: min(640px, 100%); max-height: calc(100vh - 40px); display: flex; flex-direction: column; animation: rise .18s ease; }
.modal.wide { width: min(960px, 100%); }
.modal .mh { display: flex; align-items: center; gap: 10px; padding: 16px 20px; border-bottom: 1px solid var(--line-2); }
.modal .mh h2 { flex: 1; }
.modal .mb { padding: 18px 20px; overflow-y: auto; }
.modal .mf { padding: 14px 20px; border-top: 1px solid var(--line-2); display: flex; gap: 10px; justify-content: flex-end; flex-wrap: wrap; }
@media (max-width: 720px) {
  .scrim { align-items: flex-end; padding: 0; }
  .modal, .modal.wide { width: 100%; border-radius: 18px 18px 0 0; max-height: 92vh; }
  .modal .mf { padding-bottom: calc(14px + env(safe-area-inset-bottom)); }
  .modal .mf .btn { flex: 1; }
}
@keyframes fade { from { opacity: 0; } }
@keyframes rise { from { transform: translateY(16px); opacity: 0; } }
.toasts { position: fixed; z-index: 200; left: 50%; bottom: 24px; transform: translateX(-50%); display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; }
@media (max-width: 900px) { .toasts { bottom: 86px; } }
.toast { background: var(--ink); color: #fff; padding: 11px 18px; border-radius: 10px; font-weight: 500; box-shadow: 0 6px 20px rgba(0, 0, 0, .25); max-width: 90vw; animation: rise .18s ease; }
.toast.bad { background: var(--brick); }
.toast.ok { background: var(--leaf); }

.quick { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.quick a { display: flex; flex-direction: column; gap: 6px; padding: 16px; border: 1px solid var(--line); border-radius: 12px; color: var(--ink); text-decoration: none; font-weight: 600; }
.quick a:hover { border-color: var(--brand); background: var(--brand-soft); text-decoration: none; }
.quick a .ic { color: var(--brand); width: 26px; height: 26px; }
.quick a small { font-weight: 400; }

/* Wizard steps (KYC on the phone) */
.steps { display: flex; gap: 6px; margin-bottom: 14px; overflow-x: auto; scrollbar-width: none; }
.steps button { flex: none; border: 1px solid var(--line); background: #fff; border-radius: 99px; padding: 6px 12px; font-size: .84rem; cursor: pointer; color: var(--ink-2); }
.steps button.on { background: var(--deep); color: #fff; border-color: var(--deep); }
.steps button.ok { border-color: var(--leaf); color: var(--leaf); }
.sticky-actions { position: sticky; bottom: 0; background: linear-gradient(transparent, var(--canvas) 30%); padding: 18px 0 6px; display: flex; gap: 10px; }
@media (max-width: 900px) { .sticky-actions { bottom: 70px; } }
.sigpad { border: 1px dashed #9FB0C1; border-radius: 10px; background: #fff; width: 100%; height: 180px; touch-action: none; display: block; }
.partner { border: 1px solid var(--line); border-radius: 10px; padding: 12px; margin-bottom: 10px; }

/* Seat map */
.seats { display: grid; grid-template-columns: repeat(auto-fill, minmax(64px, 1fr)); gap: 8px; }
.seat { border: 1px solid var(--line); border-radius: 9px; padding: 6px; font-size: .74rem; text-align: center; background: #fff; }
.seat .q { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2px; margin-top: 4px; height: 10px; }
.seat .q i { background: #E7EDF2; border-radius: 2px; }
.seat .q i.active { background: var(--brand); }
.seat .q i.reserved { background: var(--turmeric); }
.seat .q i.company_held { background: #8D9AA8; }
.legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: .82rem; color: var(--ink-2); margin-top: 10px; }
.legend i { display: inline-block; width: 12px; height: 12px; border-radius: 3px; margin-right: 5px; vertical-align: -1px; }

.bar { height: 8px; background: var(--line-2); border-radius: 99px; overflow: hidden; }
.bar span { display: block; height: 100%; background: var(--brand); border-radius: 99px; }
.bar.warn span { background: var(--turmeric); }
.bar.ok span { background: var(--leaf); }

.map { height: 520px; border-radius: var(--radius); border: 1px solid var(--line); z-index: 0; }
.map.small { height: 260px; }
.pin { background: var(--brand); color: #fff; border-radius: 50% 50% 50% 0; transform: rotate(-45deg); width: 28px; height: 28px; display: flex; align-items: center; justify-content: center; border: 2px solid #fff; box-shadow: 0 1px 4px rgba(0, 0, 0, .35); }
.pin b { transform: rotate(45deg); font-size: .75rem; }

/* Login */
.login { min-height: 100vh; display: grid; grid-template-columns: 1.1fr 1fr; }
.login .art { background: var(--deep); color: #fff; padding: 48px; display: flex; flex-direction: column; justify-content: space-between; position: relative; overflow: hidden; }
.login .art img { height: 46px; align-self: flex-start; }
.login .art h1 { font-size: 2.3rem; line-height: 1.15; max-width: 14ch; font-weight: 600; }
.login .art p { color: #B8CADC; max-width: 40ch; }
.login .art .path { position: absolute; right: -40px; top: 18%; opacity: .5; }
.login .form { display: flex; align-items: center; justify-content: center; padding: 28px; background: var(--surface); }
.login .form > div { width: min(380px, 100%); }
.pinrow { display: flex; gap: 10px; }
.pinrow input { width: 56px; height: 60px; text-align: center; font-size: 1.5rem; font-weight: 600; }
@media (max-width: 860px) {
  .login { grid-template-columns: 1fr; }
  .login .art { padding: 28px 22px 26px; min-height: auto; }
  .login .art h1 { font-size: 1.7rem; margin-top: 26px; }
  .login .art .path { display: none; }
}
.lang { display: inline-flex; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.lang button { border: 0; background: #fff; padding: 5px 10px; cursor: pointer; font-size: .85rem; }
.lang button.on { background: var(--deep); color: #fff; }
.spinner { width: 22px; height: 22px; border-radius: 50%; border: 3px solid var(--line); border-top-color: var(--brand); animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.loading { display: flex; justify-content: center; padding: 50px; }
audio { width: 100%; max-width: 320px; height: 36px; }
.rec { display: flex; align-items: center; gap: 10px; }
.rec .dotr { width: 10px; height: 10px; border-radius: 50%; background: var(--brick); animation: blink 1s infinite; }
@keyframes blink { 50% { opacity: .2; } }
.kv { display: flex; justify-content: space-between; gap: 10px; padding: 7px 0; border-bottom: 1px solid var(--line-2); font-size: .94rem; }
.kv:last-child { border-bottom: 0; }
.kv span:first-child { color: var(--ink-2); }
.diff { font-size: .92rem; white-space: pre-wrap; background: #F8FAFC; border: 1px solid var(--line-2); border-radius: 8px; padding: 10px 12px; }
.stagehead { display: flex; align-items: baseline; gap: 10px; margin-bottom: 10px; }
.lightbox { position: fixed; inset: 0; background: rgba(0, 0, 0, .9); z-index: 300; display: flex; align-items: center; justify-content: center; padding: 20px; }
.lightbox img { max-width: 100%; max-height: 100%; border-radius: 6px; }
.rail .navlink .ic { display: none; }
