/* ============================================================
   IILM Room Finder — contemporary, confident, no chrome-soup
   ============================================================ */

:root{
  --ink: #0b0c10;
  --ink-soft: #0b0c10;
  --ink-faint: #0b0c10;

  --paper: #ffffff;
  --paper-raised: #ffffff;
  --panel: #f5f5f7;
  --panel-deep: #ebebef;
  --line: #e3e3e8;
  --line-soft: #edEDf1;

  --accent: #9a4f74;
  --accent-ink: #ffffff;
  --accent-soft: #f6e9f0;
  --accent-tint: #faf1f6;
  --accent-tint-line: #ecd6e3;

  --deep: #33203c;
  --deep-wash: linear-gradient(142deg, #221a3c 0%, #3a1f3e 52%, #4d2438 100%);
  --deep-alt: #1b3348;
  --deep-alt-wash: linear-gradient(142deg, #10333f 0%, #1a3352 52%, #2c2f5e 100%);
  --tint-alt: #e9f3f1;
  --tint-alt-line: #c9e0db;
  --deep-line: rgba(255,255,255,0.17);
  --deep-soft: rgba(255,255,255,0.10);
  --deep-ink: #ffffff;

  --free: #0a7d54;
  --free-tint: #e8f4ec;
  --free-line: #c4e0ce;

  /* The block that reads your own schedule sits in warm ochre, so it is not
     mistaken for one more free room in the green grid below it. */
  --pick: #8a6512;
  --pick-tint: #f9f1de;
  --pick-line: #e6d3a4;

  /* Confessions get their own colour too — periwinkle, so the box you type
     into does not read as one more inactive field. */
  --say: #4a3fa0;
  --say-tint: #eeecfa;
  --say-line: #d3cdf0;
  --occupied-bg: #14151c;
  --occupied: #ffffff;
  --occupied-dot: #e14a3a;

  --radius-sm: 5px;
  --radius: 5px;
  --radius-lg: 5px;

  --shadow-sm: 0 1px 2px rgba(11,12,16,0.06);
  --shadow-md: 0 8px 24px -8px rgba(11,12,16,0.18);

  --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-display: "Newsreader", Georgia, "Times New Roman", serif;
  --font-mono: var(--font-body);
}

/* Always light — no system dark-mode auto-switch. */

*, *::before, *::after{ box-sizing: border-box; }
html{
  -webkit-text-size-adjust: 100%;
  /* No pull-to-refresh. The spinner at the top of a drag is the browser
     announcing itself, which is exactly what an app should not do — and the
     data reloads on its own anyway. */
  overscroll-behavior-y: contain;
}
body{
  margin: 0;
  overscroll-behavior-y: contain;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  min-height: 100vh;
}
svg{ display: block; }
[hidden]{ display: none !important; }

/* ---------- app shell ---------- */
.app{
  max-width: 860px;
  margin: 0 auto;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  /* Measured from the bar itself at runtime, so nothing can end up underneath
     it when the bar's height changes. The fallback covers the first paint. */
  padding-bottom: calc(var(--tabbar-space, 78px) + 14px);
}

.topbar{
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 18px 10px;
}
.brand-logo{ height: 40px; width: auto; display: block; flex-shrink: 0; }
/* Both header buttons sit together in the right corner, so whichever of them
   is showing, the pair stays put rather than one drifting into the middle. */
.topbar-actions{ display:flex; align-items:center; gap: 2px; margin-left: auto; }
.profile-btn{
  flex-shrink: 0;
  width: 40px; height: 40px; display:grid; place-items:center;
  border: none; background: none; color: var(--ink); cursor: pointer; padding: 0;
}
.profile-btn svg{ width: 31px; height: 31px; }
.profile-btn:active{ opacity: .6; }
.greeting{
  margin: 0;
  /* Set to the crest's height so the two read as one mark, in Inter's display
     cut. The weight already closes the counters, so the tracking stays open
     rather than negative — tight tracking on heavy type just fills the gaps. */
  font-family: var(--font-body); font-size: 29px; line-height: 40px; font-weight: 800;
  font-variation-settings: "opsz" 32;
  letter-spacing: 0.005em; color: var(--ink);
}
.greeting span{
  display: inline-block; margin-left: 4px;
  font-size: 24px; vertical-align: 2px;
}
.now-line{
  display:flex; flex-direction: column; gap: 5px;
  font-variant-numeric: tabular-nums;
  font-size: 13px;
  color: var(--ink);
  margin: 16px 0 4px;
}
.now-date{ font-weight: 500; }
.now-time{ font-family: var(--font-display); font-size: 19px; }

main{ flex: 1; padding: 14px 10px; display: flex; flex-direction: column; }

.view{ display: none; }
.view.active{ display: block; }

/* ---------- section heading ---------- */
.page-title{
  font-family: var(--font-display);
  font-size: 21px; font-weight: 500; letter-spacing: -0.01em;
  margin: 2px 0 12px; color: var(--ink);
}
.eyebrow{
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.01em;
  color: var(--accent);
  font-weight: 500;
}
.section-head h2{
  font-family: var(--font-display);
  font-size: 25px;
  margin: 3px 0 0;
  font-weight: 600;
  letter-spacing: -0.02em;
}

/* ---------- My Batch tab ---------- */

/* the profile card: title, current batch, live status, batch picker */
.profile-card{
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 14px; margin-bottom: 12px;
  background: var(--paper);
}
.profile-inner{
  border: 1px solid var(--deep); border-radius: var(--radius);
  background: var(--deep-wash);
  color: var(--deep-ink);
  padding: 16px 14px;
}
.profile-inner .profile-card-name,
.profile-inner .now-line{ color: var(--deep-ink); }
.profile-inner .picker-trigger{
  background: var(--deep-soft); border-color: var(--deep-line); color: var(--deep-ink);
}
.profile-inner .picker-trigger:hover{ background: rgba(255,255,255,0.17); }
/* The three shortcuts stay white on the coloured panel, black type and icons. */
.profile-inner .quick-actions button{
  background: var(--paper); border-color: var(--paper); color: var(--ink);
}
.profile-inner .quick-actions button:hover{ background: var(--panel); }

/* The Timetable tab is a lookup, not an identity — no panel, no clock. The
   type switch sits on the page itself and the name reads as a heading. */
.type-switch{ display:flex; gap: 4px; margin-bottom: 14px; }
.type-switch button{
  flex: 1; min-width: 0;
  display:flex; flex-direction: column; align-items:center; gap: 8px;
  font-family: var(--font-body); font-size: 12px; font-weight: 500;
  padding: 11px 6px; border-radius: var(--radius); border: 1px solid var(--line);
  background: var(--paper); color: var(--ink); cursor: pointer;
}
.type-switch button svg{ width: 18px; height: 18px; flex-shrink: 0; }
.type-switch button span{ overflow:hidden; text-overflow: ellipsis; white-space: nowrap; }
.type-switch button:hover{ background: var(--panel); }
.type-switch button.on{ background: var(--deep-alt); border-color: var(--deep-alt); color: var(--deep-ink); }

.lookup-head{
  display:flex; align-items:center; justify-content: space-between; gap: 10px;
  padding: 14px; margin-bottom: 12px;
  border: 1px solid var(--tint-alt-line); border-radius: var(--radius);
  background: var(--tint-alt);
}
.lookup-head h2{
  font-family: var(--font-display); font-size: 25px; font-weight: 500;
  letter-spacing: -0.02em; color: var(--ink); margin: 0;
  overflow:hidden; text-overflow: ellipsis;
}
.lookup-head .icon-btn-swap{ color: var(--deep-alt); }
.batch-head{ display:flex; align-items:center; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.batch-head .profile-card-title{ margin-bottom: 0; }
.batch-actions{ display:flex; align-items:center; gap: 8px; }
.icon-btn{
  width: 36px; height: 36px; flex-shrink: 0;
  display:grid; place-items:center;
  border-radius: 50%; border: none; cursor: pointer;
}
.icon-btn svg{ width: 18px; height: 18px; }
.icon-btn-remove{ background: none; color: #d92d20; }
.icon-btn-remove svg{ width: 21px; height: 21px; }
.icon-btn-swap{ background: none; color: var(--accent); }
.icon-btn-swap svg{ width: 22px; height: 22px; }
.icon-btn-add{ background: #1d4ed8; color: #fff; }
.profile-card-title{
  font-family: var(--font-display); font-size: 24px; letter-spacing: -0.01em;
  color: var(--ink); font-weight: 500; margin-bottom: 10px;
}
.profile-card-name{ font-family: var(--font-display); font-size: 25px; font-weight: 500; color: var(--ink); letter-spacing: -0.02em; }
.batch-name-row{ display:flex; align-items:center; justify-content: space-between; gap: 10px; }
.notify-btn{
  flex-shrink: 0;
  font-family: var(--font-body); font-size: 12px; font-weight: 500;
  padding: 8px 12px; border-radius: var(--radius);
  border: 1px solid var(--deep-line); background: var(--deep-soft); color: var(--deep-ink); cursor: pointer;
}
.notify-btn.on{
  width: 38px; height: 38px; padding: 0;
  display:grid; place-items:center; border-radius: 50%;
  background: var(--deep-ink); border-color: var(--deep-ink); color: var(--deep);
}
.notify-btn.on svg{
  width: 21px; height: 21px;
  transform-origin: 50% 16%;
  animation: bell-ring 4.5s ease-in-out infinite;
}
@keyframes bell-ring{
  0%, 86%, 100%{ transform: rotate(0deg); }
  89%{ transform: rotate(12deg); }
  92%{ transform: rotate(-10deg); }
  95%{ transform: rotate(6deg); }
  98%{ transform: rotate(-3deg); }
}
@media (prefers-reduced-motion: reduce){ .notify-btn.on svg{ animation: none; } }

.picker-row{ display:flex; gap: 8px; }
.picker-trigger{
  width: 100%;
  display:flex; align-items:center; justify-content: space-between; gap: 8px;
  font-family: var(--font-body); font-size: 13.5px; font-weight: 500; text-align: left;
  padding: 11px 12px; border-radius: var(--radius); border: 1px solid var(--accent-tint-line);
  background: var(--paper); color: var(--ink); cursor: pointer;
}
.picker-trigger span{ overflow:hidden; text-overflow: ellipsis; white-space: nowrap; }
.picker-caret{ width: 12px; height: 12px; flex-shrink: 0; transition: transform .18s ease; }
.picker-trigger[aria-expanded="true"] .picker-caret{ transform: rotate(180deg); }
.btn-subscribe{
  flex-shrink: 0; font-family: var(--font-body); font-size: 13px; font-weight: 600;
  padding: 10px 18px; border-radius: var(--radius); border: none;
  background: var(--ink); color: var(--paper); cursor: pointer;
}
.btn-subscribe:disabled{ opacity: .35; cursor: default; }
.picker-footer{ padding: 10px 12px; border-top: 1px solid var(--line); }
.picker-footer .btn-subscribe{ width: 100%; }

.quick-actions{ display:grid; grid-template-columns: repeat(3, 1fr); gap: 7px; margin-top: 16px; }
.quick-actions button{
  display:flex; flex-direction: column; align-items: center; gap: 7px;
  font-family: var(--font-body); font-size: 11.5px; font-weight: 500; line-height: 1.25; text-align: center;
  padding: 12px 6px; border-radius: var(--radius); border: 1px solid var(--accent-tint-line);
  background: var(--paper); color: var(--ink); cursor: pointer;
}
.quick-actions button svg{ width: 20px; height: 20px; }
.quick-actions button:hover{ background: var(--panel); }
.profile-inner .quick-actions button.on{
  background: var(--deep-ink); border-color: var(--deep-ink); color: var(--ink);
}

/* the bar that comes down with the batches listed */
.picker-panel{
  margin-top: 8px; border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--paper); overflow: hidden;
  animation: slidedown .18s ease both;
}
@keyframes slidedown{ from{ opacity: 0; transform: translateY(-6px); } to{ opacity:1; transform:none; } }
.picker-search{
  width: 100%; font-family: var(--font-body); font-size: 13.5px;
  padding: 10px 12px; border: none; border-bottom: 1px solid var(--line);
  background: var(--paper); color: var(--ink);
}
.picker-search:focus{ outline: none; background: var(--panel); }
.picker-list{ max-height: 240px; overflow-y: auto; }
.picker-list button{
  display:flex; align-items:center; justify-content: space-between; gap: 10px;
  width: 100%; text-align:left; padding: 11px 12px;
  border: none; border-bottom: 1px solid var(--line-soft);
  background: none; font-family: var(--font-body); font-size: 13.5px; color: var(--ink); cursor: pointer;
}
.picker-list button:last-child{ border-bottom: none; }
.picker-list button:hover:not([disabled]){ background: var(--panel); }
.picker-list button.selected{ background: var(--ink); color: var(--paper); }
.picker-list button[disabled]{ cursor: default; }

.sheet-search{
  border: 1px solid var(--line) !important; border-radius: var(--radius); margin-bottom: 8px;
}
.sheet-list{
  max-height: 46vh; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden auto;
}
.picker-list .empty{ padding: 12px; font-size: 12.5px; color: var(--ink-faint); }


.batch-dots{ display:flex; justify-content:center; gap: 5px; margin-top: 10px; }
.batch-dots span{
  width: 6px; height: 6px; border-radius: 999px; background: var(--accent-tint-line);
  cursor: pointer; transition: width .2s ease, background .2s ease;
}
.batch-dots span.on{ width: 18px; background: var(--accent); }


.day-select-row{ display:flex; align-items:center; gap: 4px; margin-bottom: 12px; }
.pair-row{ display:flex; gap: 6px; margin-bottom: 14px; }
.pair-row .day-trigger{ flex: 1; min-width: 0; }
.day-trigger{
  flex: 1; min-width: 0;
  display:flex; align-items:center; justify-content: space-between; gap: 8px;
  font-family: var(--font-body); font-size: 13.5px; font-weight: 500; text-align: left;
  padding: 11px 14px; border-radius: var(--radius); border: 1px solid var(--line);
  background: var(--paper-raised); color: var(--ink); cursor: pointer;
}
.day-trigger span{ overflow:hidden; text-overflow: ellipsis; white-space: nowrap; }
.filter-btn{
  flex-shrink: 0; width: 40px; height: 40px;
  display:grid; place-items:center;
  border: none; background: none; color: var(--ink); cursor: pointer;
}
.filter-btn svg{ width: 22px; height: 22px; }

.week-nav{
  display:flex; align-items:center; justify-content: space-between; gap: 8px;
  margin-bottom: 12px; font-size: 13.5px; font-weight: 500; color: var(--ink);
}
.week-step{
  width: 34px; height: 34px; flex-shrink: 0;
  display:grid; place-items:center;
  border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--paper); color: var(--ink); cursor: pointer;
}
.week-step svg{ width: 17px; height: 17px; }
.week-step[disabled]{ opacity: .25; cursor: default; }

.cal-grid{ display:grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.cal-head{ margin-bottom: 6px; }
.cal-head span{ text-align:center; font-size: 11px; font-weight: 500; color: var(--ink); padding: 4px 0; }
.cal-cell{
  aspect-ratio: 1; display:grid; place-items:center;
  font-family: var(--font-body); font-size: 13.5px; font-weight: 500;
  font-variant-numeric: tabular-nums;
  border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--paper); color: var(--ink); cursor: pointer; padding: 0;
}
.cal-cell.cal-blank{ border: none; background: none; }
.cal-cell.cal-off{ border-color: transparent; background: none; opacity: .3; cursor: default; }
.cal-cell.cal-today{ border-color: var(--accent); }
.cal-cell.on{ background: var(--deep); border-color: var(--deep); color: var(--deep-ink); }

.teacher-now{
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 13px 15px; margin-bottom: 14px; font-size: 14px; line-height: 1.45;
}
.teacher-now span{ color: var(--ink-soft); font-size: 12.5px; }
.teacher-now-head{
  display: flex; align-items: center; gap: 7px; margin: 0 0 5px;
  font-size: 12.5px; font-weight: 600; color: var(--free);
}
.teacher-now-head i{ width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.teacher-now.busy .teacher-now-head{ color: var(--occupied); }
.teacher-now-sub{ margin: 0 0 3px; font-size: 12.5px; color: var(--ink-soft); }
.tt-slot.is-now{ border-color: var(--ink); border-width: 1.5px; }
/* The hour you are actually in, said plainly. The dot breathes so it reads as
   happening now rather than as one more label. */
.live-now{
  display:inline-flex; align-items:center; gap: 6px;
  font-family: var(--font-body); font-size: 12px; font-weight: 600;
  color: var(--free); margin-bottom: 7px;
}
.live-now i{
  width: 7px; height: 7px; border-radius: 50%; background: var(--free);
  animation: live-pulse 1.8s ease-in-out infinite;
}
@keyframes live-pulse{ 0%, 100%{ opacity: 1; } 50%{ opacity: .3; } }
@media (prefers-reduced-motion: reduce){ .live-now i{ animation: none; } }

/* ---------- status pill (room detail sheet) ---------- */
.status-pill{
  font-family: var(--font-mono);
  font-size: 10.5px;
  font-weight: 500;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: var(--panel);
  color: var(--ink-soft);
}

/* ---------- room chips / grids ---------- */
.block-group{ margin-bottom: 18px; }
.block-title{
  display:flex; align-items:baseline; gap: 8px; margin-bottom: 8px;
}
.block-title h3{
  font-family: var(--font-display); font-size: 18px; font-weight: 500; letter-spacing: -0.01em; margin: 0;
}

/* Only free rooms are listed, so every chip means the same thing — no dots, no
   wall of black boxes, and the tab's own green carries the meaning. */
.room-grid{
  display:grid;
  grid-template-columns: repeat(auto-fill, minmax(88px, 1fr));
  gap: 6px;
}
.room-chip{
  font-family: var(--font-body);
  font-size: 13.5px;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
  text-align: left;
  /* Most of these are a number. The science labs are a whole name, and it has
     to wrap inside the chip rather than run out the side of it. */
  line-height: 1.25;
  overflow-wrap: anywhere;
  padding: 12px 11px;
  border-radius: var(--radius);
  border: 1px solid var(--free-line);
  background: var(--free-tint);
  color: var(--ink);
  cursor: pointer;
}
.room-chip:hover{ border-color: var(--free); }
.room-chip:active{ opacity: .7; }

.vacant-none{ font-size: 13.5px; color: var(--ink); margin: 2px 0; }

/* The one room to walk to, before the full list of everything free. */
.vacant-prompt{
  padding: 14px; margin-bottom: 16px;
  border: 1px solid var(--pick-line); border-radius: var(--radius);
  background: var(--pick-tint);
}
.vacant-prompt p{ font-size: 13.5px; line-height: 1.45; color: var(--ink); margin: 0 0 12px; }
.vacant-prompt button{
  display: block; width: 100%;
  font-family: var(--font-body); font-size: 13px; font-weight: 600;
  padding: 12px 14px; border-radius: var(--radius);
  border: none; background: var(--ink); color: var(--paper); cursor: pointer;
}

/* Light, so it sits with the pale chips underneath instead of competing with
   the dark panels the other tabs use. */
.vacant-pick{
  padding: 14px; margin-bottom: 16px;
  border: 1px solid var(--pick-line); border-radius: var(--radius);
  background: var(--pick-tint);
  color: var(--ink);
}
.vacant-pick-top{ display:flex; align-items:center; justify-content: flex-end; margin-bottom: 10px; }
.vacant-pick-batch{
  flex-shrink: 0;
  display:flex; align-items:center; gap: 6px;
  font-family: var(--font-body); font-size: 12px; font-weight: 500;
  padding: 5px 9px 5px 10px; border-radius: var(--radius);
  border: 1px solid var(--pick-line); background: var(--paper);
  color: var(--ink); cursor: pointer;
}
.vacant-pick-batch svg{ width: 13px; height: 13px; color: var(--pick); }
.vacant-pick-rows:not(:empty){ margin-bottom: 10px; }
.vacant-pick-row{ font-size: 13.5px; line-height: 1.45; color: var(--ink); margin: 0 0 4px; }
.vacant-pick-row span{ font-weight: 600; margin-right: 6px; }
.vacant-pick-row span::after{ content: ":"; }
.vacant-pick-label{
  display: block;
  font-size: 13.5px; font-weight: 600; color: var(--ink);
}
.vacant-pick-label::after{ content: ":"; }
.vacant-pick-room{
  display:block; width: 100%; text-align: left; margin-top: 2px; padding: 0;
  border: none; background: none; color: var(--ink); cursor: pointer;
  font-family: var(--font-display); font-size: 26px; font-weight: 500;
  letter-spacing: -0.02em; line-height: 1.2;
}
.vacant-pick-room:active{ opacity: .7; }
.vacant-pick-timebar{
  display:flex; justify-content: space-between; align-items:center;
  margin-top: 14px; padding: 11px 13px; border-radius: var(--radius);
  font-variant-numeric: tabular-nums; font-size: 12.5px; font-weight: 600; color: var(--ink);
  background: var(--pick-line);
}

/* ---------- weekly timetable ---------- */
.tt-agenda{ display:flex; flex-direction: column; gap: 8px; }
.tt-slot{
  --subject-colour: #dcdce4;
  padding: 16px; border: 1px solid color-mix(in srgb, var(--subject-colour) 45%, white);
  border-radius: var(--radius); overflow: hidden;
  background: color-mix(in srgb, var(--subject-colour) 14%, white);
}
.tt-row{ font-size: 13.5px; line-height: 1.45; color: var(--ink); margin: 9px 0 0; }
.tt-label{ font-weight: 600; }
.tt-timebar{
  display:flex; justify-content: space-between; align-items:center;
  margin-top: 16px; padding: 11px 13px; border-radius: var(--radius);
  font-variant-numeric: tabular-nums; font-size: 12.5px; font-weight: 600; color: var(--ink);
  background: color-mix(in srgb, var(--subject-colour) 45%, white);
}
.tt-slot.is-empty{ --subject-colour: #dcdce4; }
.tt-time{ font-variant-numeric: tabular-nums; font-size: 10.5px; color: var(--ink-faint); line-height: 1.4; }
.tt-time b{ display:block; font-size: 14px; color: var(--ink); font-weight: 500; }
.tt-slot .subject{ font-family: var(--font-display); font-weight: 500; font-size: 20px; margin: 0; line-height: 1.25; }
.tt-main .meta{ font-family: var(--font-mono); font-size: 10.5px; color: var(--ink-soft); }
.free-note{ font-size: 13.5px; line-height: 1.45; color: var(--ink); margin: 9px 0 13px; }
.find-room-btn{
  display: block; width: 100%;
  font-family: var(--font-body); font-size: 13px; font-weight: 600;
  padding: 12px 14px; border-radius: var(--radius);
  border: none; background: var(--deep); color: var(--deep-ink); cursor: pointer;
}
.tt-main .meta span{ display:inline-block; margin-right: 10px; }

/* desktop grid table */
.tt-table-wrap{ display:none; overflow-x:auto; border:1px solid var(--line); border-radius: var(--radius); }
table.tt-table{ border-collapse: collapse; width: 100%; min-width: 720px; }
table.tt-table th, table.tt-table td{
  border: 1px solid var(--line-soft); padding: 8px; vertical-align: top; font-size: 12px;
}
table.tt-table thead th{
  background: var(--panel); font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.01em; font-weight: 500;
  position: sticky; top:0;
}
table.tt-table tbody th{ font-family: var(--font-mono); background: var(--panel); white-space: nowrap; font-weight: 500; }
table.tt-table td .subject{ font-weight: 500; display:block; margin-bottom: 2px; }
table.tt-table td .meta{ font-family: var(--font-mono); color: var(--ink-faint); font-size: 10px; }

/* ---------- confessions ---------- */
/* The one place people write something of their own, so it is given the
   weight of a sheet of paper rather than a form field: a serif hand, a ruled
   top edge in the tab's colour, and the counter only speaking up near the end. */
.compose{
  position: relative; overflow: hidden;
  border: 1px solid var(--say-line); border-radius: var(--radius);
  background: var(--paper); padding: 16px 14px 12px; margin-bottom: 16px;
  transition: border-color .18s ease, box-shadow .18s ease;
}
.compose::before{
  content: ""; position: absolute; inset: 0 0 auto 0; height: 3px;
  background: linear-gradient(90deg, var(--say) 0%, #7b5ea7 55%, var(--pick) 100%);
}
.compose:focus-within{
  border-color: var(--say);
  box-shadow: 0 0 0 3px var(--say-tint);
}
.compose textarea::placeholder{
  font-family: var(--font-body); font-style: normal; font-weight: 400;
  color: var(--say); opacity: .55;
}
/* The same face, size and rhythm the post will be set in, so what is typed
   looks like what appears. */
.compose textarea{
  width: 100%; resize: vertical; min-height: 76px;
  font-family: var(--font-body); font-size: 15.5px; line-height: 1.55;
  font-weight: 450; letter-spacing: -0.005em; color: var(--ink);
  border: none; background: none; padding: 0;
}
.compose textarea:focus{ outline: none; }
.compose-foot{ display:flex; align-items:center; justify-content: space-between; gap: 10px; margin-top: 10px; }
.compose-foot span{
  font-size: 12.5px; font-weight: 500; font-variant-numeric: tabular-nums;
  color: var(--ink); opacity: .45; transition: opacity .18s ease, color .18s ease;
}
.compose:focus-within .compose-foot span{ opacity: 1; }
.compose-foot span.low{ color: #a4160c; opacity: 1; font-weight: 600; }
/* Named rather than "every button in here": the camera beside it is a button
   too, and was being served the Post button's purple as a solid block. */
.compose-foot #confess-post, .compose-foot #talk-post{
  font-family: var(--font-body); font-size: 13px; font-weight: 600;
  padding: 10px 20px; border-radius: var(--radius);
  border: none; background: var(--say); color: var(--paper); cursor: pointer;
}
.compose-foot #confess-post:disabled, .compose-foot #talk-post:disabled{ opacity: .4; cursor: default; }
/* The tools sit together on the left of the row, Post alone on the right. */
/* The camera holds the left. Poll and link sit against Post, because those two
   change what you are posting rather than what is attached to it. */
#talk-compose .compose-foot{ gap: 4px; }
#talk-compose #talk-poll-btn{ margin-left: auto; }
#talk-compose #talk-post{ margin-left: 6px; }

.react-row{ display:flex; gap: 6px; margin-top: 14px; flex-wrap: wrap; }
.react{
  display:flex; align-items:center; gap: 5px;
  font-family: var(--font-body); font-size: 14px; line-height: 1;
  padding: 8px 11px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--paper); color: var(--ink); cursor: pointer;
}
.react b{ font-weight: 600; font-size: 12px; font-variant-numeric: tabular-nums; }
.react.mine{ border-color: var(--say); background: var(--say-tint); }
/* Reactions on a reply are the same set, drawn smaller so a thread still reads
   as a thread rather than five more buttons a line. */
.react-row.small{ gap: 4px; margin-top: 7px; }
.react-row.small .react{ font-size: 12px; padding: 5px 8px; gap: 4px; }
.react-row.small .react b{ font-size: 11px; }

.reply-toggle{
  padding: 0;
  display:flex; align-items:center; gap: 5px;
  font-family: var(--font-body); font-size: 12.5px; font-weight: 600;
  font-variant-numeric: tabular-nums;
  border: none; background: none; color: var(--say); cursor: pointer;
}
.reply-toggle svg{ width: 16px; height: 16px; }
.reply-thread{ margin-top: 10px; border-top: 1px solid var(--line); padding-top: 10px; }
.reply{ margin-bottom: 10px; }
.reply-body{
  font-family: var(--font-body); font-size: 14px; line-height: 1.5; color: var(--ink);
  margin: 0; overflow-wrap: anywhere; white-space: pre-wrap;
}
.reply-meta{
  display:flex; align-items:center; gap: 10px;
  font-size: 11.5px; font-weight: 500; color: var(--say); margin: 3px 0 0;
}
/* Everyone on the board is Anonymous, so the word is set quietly — it is a
   placeholder for a name, not a name. Admin is the one thing worth reading. */
.reply-who{ font-weight: 500; }
.reply-admin{ font-weight: 700; color: #a4160c; }
/* Only you ever see this, on your own replies. */
.reply-mine{ font-weight: 700; color: var(--say); }
/* And only an administrator ever sees a real name, here or on a confession. */
.reply-named{ font-weight: 700; color: var(--ink); }
.confess-author{ font-weight: 700; color: var(--ink); }
.reply-to{
  margin-left: auto; padding: 0;
  font-family: var(--font-body); font-size: 11.5px; font-weight: 600;
  border: none; background: none; color: var(--say); cursor: pointer;
}
/* A thread steps right exactly once, whatever it hangs off. */
.reply-kids{ margin: 0 0 10px 6px; padding-left: 12px; border-left: 2px solid var(--say-line); }
.reply-kids .reply:last-child{ margin-bottom: 0; }

.reply-compose{ display:block; }
.reply-compose-row{ display:flex; gap: 6px; }
.reply-target{
  display:flex; align-items:center; gap: 6px; margin: 0 0 6px;
  font-size: 11.5px; font-weight: 600; color: var(--say);
}
.reply-target-clear{
  font-family: var(--font-body); font-size: 15px; line-height: 1;
  padding: 0 2px; border: none; background: none; color: var(--say); cursor: pointer;
}
.reply-compose input{
  flex: 1; min-width: 0;
  font-family: var(--font-body); font-size: 13.5px; color: var(--ink);
  padding: 10px 11px; border-radius: var(--radius); border: 1px solid var(--line); background: var(--paper);
}
.reply-compose input:focus{ outline: none; border-color: var(--say); }
.reply-send, .talk-send{
  flex-shrink: 0;
  font-family: var(--font-body); font-size: 12.5px; font-weight: 600;
  padding: 10px 14px; border-radius: var(--radius);
  border: none; background: var(--say); color: var(--paper); cursor: pointer;
}
.profile-btn.signed-in{ color: var(--say); }

/* The way in for a browser that will not open Google's dialog. Small print
   under the button, because it is the second answer and not the first. */
.signin-plain{
  display: block; margin: 10px auto 0; padding: 4px;
  font-family: var(--font-body); font-size: 12px; font-weight: 500;
  border: none; background: none; color: var(--ink); opacity: .55;
  text-decoration: underline; text-underline-offset: 3px; cursor: pointer;
}
.signin-plain:hover{ opacity: 1; color: var(--say); }
.signin-plain:disabled{ opacity: .35; cursor: default; }

/* Said before the rooms, not after: it changes how the list underneath should
   be read. Quiet, because it is a caveat and not an alarm. */
.vacant-caveat{
  margin: 0 0 14px; padding: 2px 0 2px 11px;
  font-size: 12.5px; line-height: 1.5; font-weight: 500;
  color: var(--ink); opacity: .75;
  border-left: 2px solid var(--occupied-dot);
}

.signin-bar{
  position: fixed; top: 0; left: 0; right: 0; z-index: 60;
  display:flex; align-items:center; gap: 10px;
  padding: 14px 14px calc(14px + env(safe-area-inset-top));
  background: var(--say); color: #fff;
  animation: bar-down .22s ease both;
}
@keyframes bar-down{ from{ transform: translateY(-100%); } to{ transform: none; } }
.signin-bar p{ margin: 0; flex: 1; min-width: 0; font-size: 13.5px; font-weight: 500; }
.signin-bar #signin-btn{
  flex-shrink: 0;
  font-family: var(--font-body); font-size: 12.5px; font-weight: 600;
  padding: 9px 13px; border-radius: var(--radius);
  border: none; background: #fff; color: var(--say); cursor: pointer;
}
.signin-close{
  flex-shrink: 0; width: 26px; height: 26px; display:grid; place-items:center;
  border: none; background: none; color: #fff; cursor: pointer; padding: 0;
}
.signin-close svg{ width: 14px; height: 14px; }

.confess{
  border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--paper); padding: 16px; margin-bottom: 8px;
}
/* Inter, not the serif. These are messages people type, not headings, and the
   serif made every one of them read as a pronouncement. Set a little smaller
   and a little looser, because a sans face at 19px on a phone is a wall. */
.confess-body{
  font-family: var(--font-body); font-size: 15.5px; line-height: 1.55;
  font-weight: 450; letter-spacing: -0.005em; color: var(--ink);
  margin: 0; overflow-wrap: anywhere; white-space: pre-wrap;
}
/* Time and Report sit together on the left, Reply holds the right corner. */
/* Two lines, not one crowded row: when it was said, and then what can be done
   about it. Four things competing for one line left nothing room to be read. */
.confess-foot{ margin-top: 13px; }
.confess-when{
  margin: 0; font-size: 12px; font-weight: 500; color: var(--ink); opacity: .55;
  font-variant-numeric: tabular-nums;
}
.confess-acts{
  display:flex; align-items:center; justify-content: space-between; gap: 14px;
  margin-top: 9px; padding-top: 10px; border-top: 1px solid var(--line-soft);
}
.confess-report{
  margin-left: auto;
  font-family: var(--font-body); font-size: 12px; font-weight: 500;
  border: none; background: none; color: #a4160c; cursor: pointer; padding: 0;
  opacity: .8;
}
.confess-report:disabled{ color: var(--ink); cursor: default; }
/* One filled line under the box, answering the question somebody has while
   deciding whether to type at all. It claims only what is true: no name is
   attached to a post or a reply. */
.compose-promise{
  margin: 8px 0 16px; padding: 7px 12px;
  border-radius: 8px; background: var(--say-tint); color: var(--say);
  font-size: 11.5px; font-weight: 600; letter-spacing: .01em; text-align: center;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

/* The cup sits behind, softened, with the heart lifted off it by a gap in the
   block's own colour rather than a second fill. */
.icon-tea{ overflow: visible; }

/* Inter, like everything else people write and read here. */
.confess-empty{
  font-family: var(--font-body); font-size: 15px; font-weight: 500;
  color: var(--ink); opacity: .6; text-align: center; margin: 14px 0 0;
}
.confess-empty-art{ display:block; margin: 28px auto 0; height: 170px; width: auto; }
.confess-more{
  display:block; width: 100%; margin-top: 8px;
  font-family: var(--font-body); font-size: 13px; font-weight: 500;
  padding: 12px; border-radius: var(--radius);
  border: 1px solid var(--line); background: var(--paper); color: var(--ink); cursor: pointer;
}

/* ---------- tab bar (mobile) ---------- */
/* Five of them now, so each gets a little less room on a phone. */
@media (max-width: 719px){
  .tab-btn{ font-size: 10px; padding-left: 2px; padding-right: 2px; }
  .tab-btn svg{ width: 19px; height: 19px; }
}
.tabbar{
  position: fixed; bottom: 0; left: 0; right: 0;
  display:flex; justify-content:center;
  background: var(--paper);
  border-top: 1px solid var(--line);
  padding: 12px max(6px, env(safe-area-inset-bottom)) calc(14px + env(safe-area-inset-bottom));
  z-index: 30;
}
.tabbar-inner{ display:flex; gap: 2px; width:100%; max-width: 420px; }
.tab-btn{
  flex:1; display:flex; flex-direction:column; align-items:center; gap: 7px;
  background:none; border:none; padding: 4px; border-radius: var(--radius-sm); cursor:pointer;
  color: var(--ink-faint); font-size: 11px; font-weight: 500;
}
.tab-btn svg{ width: 23px; height: 23px; }
.tab-btn.active{ color: var(--ink); }
.tab-btn.active svg{ color: var(--accent); }

.skeleton{
  height: 12px; border-radius: var(--radius-sm); background: var(--panel-deep);
}

.toast{
  position: fixed; left:50%; bottom: calc(var(--tabbar-space, 78px) + 14px); transform: translateX(-50%);
  background: var(--ink); color: var(--paper); font-size: 12px; font-weight: 500;
  padding: 9px 16px; border-radius: var(--radius); opacity:0; pointer-events:none; transition: opacity .2s ease;
  z-index: 50; max-width: 88%; text-align:center; box-shadow: var(--shadow-md);
}
.toast.show{ opacity: 1; }

/* ---------- room detail sheet ---------- */
.sheet-backdrop{
  position: fixed; inset: 0; background: rgba(11,12,16,.5); z-index: 40;
  display:none; align-items:flex-end; justify-content:center;
}
.sheet-backdrop.open{ display:flex; }
.sheet{
  background: var(--paper); width: 100%; max-width: 520px; border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  padding: 18px 18px calc(18px + env(safe-area-inset-bottom));
  max-height: 78vh; overflow-y: auto;
  box-shadow: 0 -12px 32px -12px rgba(11,12,16,.25);
  animation: slideup .22s ease both;
}
@keyframes slideup{ from{ transform: translateY(20px); opacity: 0; } to{ transform:none; opacity: 1; } }
.sheet-option{
  display:flex; align-items:center; justify-content: space-between; gap: 10px;
  width: 100%; text-align:left;
  font-family: var(--font-body); font-size: 14px; font-weight: 500;
  padding: 13px 14px; margin-bottom: 8px;
  border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--paper); color: var(--ink); cursor: pointer;
}
.sheet-option.on{ background: var(--ink); color: var(--paper); border-color: var(--ink); }
.sheet-option-danger{ color: #d92d20; border-color: #f2cdc9; }
.sheet-foot{ font-size: 13px; color: var(--ink); margin: 12px 0 0; }
/* Google draws its own button; these only give it somewhere to sit. */
.sheet-gsi{ display:flex; justify-content:center; margin-top: 14px; min-height: 44px; }
#signin-gsi{ flex-shrink: 0; display:flex; align-items:center; }
#sheet-moderate{ margin-top: 16px; }
#sheet-signout{ margin-top: 16px; }
.opt-tag{ flex-shrink: 0; font-size: 14px; font-weight: 500; color: var(--accent); }
.sheet-option.on .opt-tag{ color: var(--accent-soft); }
@media (min-width: 640px){
  .sheet-backdrop{ align-items:center; }
  .sheet{ border-radius: var(--radius-lg); max-height: 80vh; box-shadow: var(--shadow-md); }
}
.sheet-head{ margin-bottom: 14px; }
.sheet-head h3{ font-family: var(--font-display); font-size: 20px; margin:0; font-weight: 500; }

/* ---------- responsive ---------- */
/* The word beside an icon: only where a sidebar has room for it. */
.wide-label{ display: none; }

/* A tablet: the bar comes off the bottom of the screen and becomes a row of
   chips under the name, but the page is still one column. */
@media (min-width: 720px){
  .app{ padding-bottom: 24px; }
  .topbar{ order: 0; }
  .tabbar{ order: 1; position: static; border-top:none; background:none; padding: 0; margin: 14px 18px 0; }
  main{ order: 2; padding: 20px 18px; }
  .tabbar-inner{ max-width: none; justify-content: flex-start; gap: 6px; }
  .tab-btn{ flex-direction: row; flex: 0 0 auto; padding: 9px 16px; border: 1px solid var(--line); border-radius: var(--radius); }
  .tab-btn.active{ background: var(--ink); border-color: var(--ink); color: var(--paper); }
  .tab-btn.active svg{ color: var(--paper); }
  .room-grid{ grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); }
  #tt-agenda{ display:none; }
  .tt-table-wrap{ display:block; }
}

/* A desktop: the chips become a sidebar, and the page stops being a phone
   stranded in the middle of a monitor. Everything that was hidden behind an
   icon in the corner -- signing in, installing -- is written out down the side
   where it can be found. */
@media (min-width: 1000px){
  .app{
    max-width: 1280px;
    display: grid;
    grid-template-columns: 236px minmax(0, 1fr);
    grid-template-areas: "brand main" "nav main";
    grid-template-rows: auto 1fr;
    column-gap: 26px;
    align-items: start;
    padding: 0 24px 32px;
  }
  .topbar{ grid-area: brand; flex-wrap: wrap; padding: 22px 0 12px; }
  .topbar-actions{ width: 100%; margin: 10px 0 0; flex-direction: column; gap: 4px; }
  main{ grid-area: main; padding: 22px 0; min-width: 0; }

  .tabbar{
    grid-area: nav; position: sticky; top: 20px;
    border-top: none; background: none; padding: 0; margin: 0;
  }
  .tabbar-inner{ flex-direction: column; align-items: stretch; gap: 3px; max-width: none; }
  .tab-btn{
    justify-content: flex-start; gap: 11px;
    padding: 11px 13px; border: none; border-radius: 10px;
    font-size: 14px;
  }
  .tab-btn:hover{ background: var(--panel); }

  /* Signing in and installing read as what they are, not as two small glyphs.
     The icon button is a fixed 40px square everywhere else, which is why both
     have to be undone here rather than only widened. */
  .topbar-actions .profile-btn{
    width: 100%; height: auto;
    display: flex; align-items: center; justify-content: flex-start; gap: 11px;
    padding: 9px 13px; border-radius: 10px;
    font-family: var(--font-body); font-size: 13.5px; font-weight: 500;
    color: var(--ink);
  }
  .topbar-actions .profile-btn svg{ width: 21px; height: 21px; flex-shrink: 0; }
  .topbar-actions .profile-btn .profile-face{ width: 22px; height: 22px; }
  .topbar-actions .profile-btn:hover{ background: var(--panel); }
  .wide-label{ display: inline; }

  /* The reading column stays a reading column; the room grid takes the rest. */
  .confess, .compose, #confess-list, .gate-card{ max-width: 720px; }
  .room-grid{ grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); }
}

/* ---------- the signed-in account ---------- */
.profile-face{ width: 31px; height: 31px; border-radius: 50%; object-fit: cover; }
/* The account sits apart from the batches above it, and the admin tools sit
   apart from the account — three separate things, not one run-on list. */
.sheet-account{
  display:flex; align-items:center; gap: 11px;
  margin-top: 18px; padding-top: 16px;
  border-top: 1px solid var(--line);
}
.sheet-account img{ width: 38px; height: 38px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.sheet-account-name{ margin: 0; font-size: 14.5px; font-weight: 600; color: var(--ink); }
.sheet-account-mail{ margin: 1px 0 0; font-size: 12.5px; color: var(--ink); }

.steps{ margin: 10px 0 0; padding-left: 20px; }
.steps li{ font-size: 13.5px; line-height: 1.5; color: var(--ink); margin-bottom: 6px; }

/* ---------- install strip ---------- */
/* Deliberately slim: it sits between things people came for, so it reads as a
   line of promotion rather than a block competing with them. */
.install-strip{
  display:flex; align-items:center; justify-content: space-between; gap: 12px;
  padding: 11px 12px; margin-bottom: 12px;
  border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--panel);
}
.install-strip p{ margin: 0; font-size: 13px; font-weight: 600; color: var(--ink); }
.install-strip span{ display:block; margin-top: 1px; font-size: 11.5px; color: var(--ink); }
.install-strip-btn{
  flex-shrink: 0;
  font-family: var(--font-body); font-size: 12.5px; font-weight: 600;
  padding: 9px 16px; border-radius: var(--radius);
  border: none; background: var(--ink); color: var(--paper); cursor: pointer;
}

/* The same strip, offering the other thing worth having — set apart by colour
   so the two never read as one repeated advertisement. */
.notify-strip{ border-color: var(--say-line); background: var(--say-tint); }
.notify-strip p{ color: var(--say); }
.notify-strip-btn{
  flex-shrink: 0;
  font-family: var(--font-body); font-size: 12.5px; font-weight: 600;
  padding: 9px 16px; border-radius: var(--radius);
  border: none; background: var(--say); color: var(--paper); cursor: pointer;
}
.notify-strip-btn:active{ opacity: .85; }

/* ---------- moderation ---------- */
.mod-row{ border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; margin-bottom: 8px; }
.mod-body{ font-family: var(--font-body); font-size: 14.5px; line-height: 1.5; margin: 0; overflow-wrap: anywhere; }
.mod-meta{ font-size: 12px; color: var(--ink); margin: 6px 0 0; }
/* Who objected. Only an administrator ever sees this, and only here. */
.mod-reporters{ font-size: 11.5px; line-height: 1.5; color: var(--ink); margin: 5px 0 0; }
.mod-reporters b{ font-weight: 600; }
.mod-reporters span{ opacity: .6; }
.mod-actions{ display:flex; gap: 6px; margin-top: 10px; }
.mod-actions button{
  flex: 1; font-family: var(--font-body); font-size: 12.5px; font-weight: 600;
  padding: 9px; border-radius: var(--radius);
  border: 1px solid var(--line); background: var(--paper); color: var(--ink); cursor: pointer;
}
.mod-actions .mod-delete{ color: #a4160c; border-color: #f2cdc9; }

/* ---------- a full page, for lists too long to sit in a sheet ---------- */
.page{
  position: fixed; inset: 0; z-index: 50;
  background: var(--paper); display: flex; flex-direction: column;
  animation: page-in .2s ease both;
}
@keyframes page-in{ from{ transform: translateX(16px); opacity: 0; } to{ transform: none; opacity: 1; } }
.page-head{
  display:flex; align-items:center; gap: 6px;
  padding: calc(14px + env(safe-area-inset-top)) 14px 14px;
  border-bottom: 1px solid var(--line);
}
.page-head h2{
  font-family: var(--font-display); font-size: 21px; font-weight: 500;
  letter-spacing: -0.01em; margin: 0; color: var(--ink);
}
.page-back{
  width: 34px; height: 34px; flex-shrink: 0; display:grid; place-items:center;
  border: none; background: none; color: var(--ink); cursor: pointer; padding: 0;
}
.page-back svg{ width: 20px; height: 20px; }
.page-body{
  flex: 1; overflow-y: auto;
  padding: 14px 14px calc(24px + env(safe-area-inset-bottom));
}

/* One person per row, with room for a long address rather than on top of it. */
.person{ border: 1px solid var(--line); border-radius: var(--radius); padding: 13px; margin-bottom: 8px; }
.person-name{ font-size: 14.5px; font-weight: 600; color: var(--ink); margin: 0; overflow-wrap: anywhere; }
.person-admin{
  margin-left: 7px; padding: 2px 6px; border-radius: 5px;
  font-size: 10.5px; font-weight: 700; letter-spacing: .02em;
  background: var(--say-tint); color: var(--say); vertical-align: 1px;
}
.person-mail{ font-size: 12.5px; color: var(--ink); margin: 3px 0 0; overflow-wrap: anywhere; }
.person-batches{ font-size: 12.5px; color: var(--say); font-weight: 500; margin: 7px 0 0; }
.person-since{ font-size: 12px; color: var(--ink); opacity: .6; margin: 3px 0 0; }
.person-time{
  margin: 6px 0 0; font-size: 12.5px; font-weight: 600;
  color: var(--say); font-variant-numeric: tabular-nums;
}
.person-time span{ font-weight: 500; color: var(--ink); opacity: .55; }

/* One account: the face, then who it is. The id is set small and monospaced --
   it is there to be copied into a query, not read. */
.person-row{ display:flex; gap: 12px; align-items: flex-start; }
.person-of{ min-width: 0; flex: 1; }
.person-face{ width: 40px; height: 40px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.person-face-blank{
  display:flex; align-items:center; justify-content:center;
  font-family: var(--font-display); font-size: 17px;
  background: var(--say-tint); color: var(--say);
}
.person-id{
  margin: 5px 0 0; font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 10.5px; color: var(--ink); opacity: .5; overflow-wrap: anywhere;
}

/* A line of text on the way down — the gesture kept, the browser's spinner not. */
.pull-hint{
  position: fixed; top: 0; left: 0; right: 0; z-index: 45;
  margin: 0; padding: 10px 0 8px;
  text-align: center; font-size: 12.5px; font-weight: 600; color: var(--say);
  background: var(--paper);
  transition: transform .12s ease;
}
.person-orphan{ background: var(--panel); }
.person-orphan .person-mail{ color: #a4160c; }


/* ---------- reading a little, then signing in ---------- */
/* What is past the wall keeps its shape and goes soft. It is not hidden: the
   point is to show there is more of the same underneath, not to end the page. */
.gate-soft{
  filter: blur(4px);
  opacity: .5;
  pointer-events: none;
  user-select: none;
}
.gate-card{
  display: flex; flex-direction: column; align-items: center; gap: 12px;
  margin: 4px 0 14px; padding: 18px 16px;
  border: 1px solid var(--say-line); border-radius: var(--radius);
  background: var(--say-tint);
}
.gate-line{
  margin: 0; max-width: 30ch; text-align: center;
  font-size: 13.5px; line-height: 1.45; font-weight: 500; color: var(--ink);
}
.gate-gsi{ min-height: 40px; display: flex; justify-content: center; }


/* ---------- pictures ---------- */
/* One fills the width; two sit side by side; three or four make a square
   block. Every cell is square so a row cannot go ragged whatever was taken. */
.shots{ display: grid; gap: 3px; margin: 10px 0 0; border-radius: 12px; overflow: hidden; }
.shots-1{ grid-template-columns: 1fr; }
.shots-2, .shots-4{ grid-template-columns: 1fr 1fr; }
.shots-3{ grid-template-columns: repeat(3, 1fr); }
.shot{
  padding: 0; border: none; background: var(--panel); cursor: zoom-in;
  aspect-ratio: 1; overflow: hidden;
}
.shots-1 .shot{ aspect-ratio: 4 / 3; }
.shot img{ width: 100%; height: 100%; object-fit: cover; display: block; }
.shots-reply{ margin-top: 7px; max-width: 220px; border-radius: 9px; }

.shot-veil{
  position: fixed; inset: 0; z-index: 120;
  display: flex; align-items: center; justify-content: center;
  padding: 20px; background: rgba(10, 9, 16, .92); cursor: zoom-out;
  animation: shot-in .16s ease both;
}
@keyframes shot-in{ from{ opacity: 0; } }
.shot-veil img{ max-width: 100%; max-height: 100%; border-radius: 10px; }

/* What has been picked but not sent yet. */
.shot-strip{ display: flex; flex-wrap: wrap; gap: 6px; margin-top: 9px; }
.shot-pick{ position: relative; width: 58px; height: 58px; }
.shot-pick img{ width: 100%; height: 100%; object-fit: cover; border-radius: 8px; display: block; }
.shot-pick button{
  position: absolute; top: -6px; right: -6px;
  width: 20px; height: 20px; border-radius: 50%; line-height: 1;
  border: none; background: var(--ink); color: var(--paper);
  font-size: 13px; cursor: pointer;
}
.shot-add, .compose-foot .shot-add, .reply-compose-row .shot-add{
  flex-shrink: 0; display: flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; padding: 0; border-radius: 9px;
  border: 1px solid var(--line); background: var(--paper); color: var(--ink);
  cursor: pointer;
}
.shot-add:active{ background: var(--panel); }
.shot-add svg{ width: 18px; height: 18px; }
.compose-foot .shot-add{ margin-right: auto; }
.compose-foot{ gap: 8px; }
.reply-compose-row .shot-add{ width: 32px; height: 32px; }


/* With no limit, a long confession is folded to about a screenful until it is
   asked for, so one person's essay cannot bury the board. */
.confess-long{
  display: -webkit-box; -webkit-line-clamp: 9; -webkit-box-orient: vertical;
  overflow: hidden;
}
.confess-more-btn{
  margin-top: 6px; padding: 0;
  font-family: var(--font-body); font-size: 12.5px; font-weight: 600;
  border: none; background: none; color: var(--say); cursor: pointer;
}
#confess-text{ resize: none; overflow-y: auto; }


/* Held for a moment when arriving from a notification, so it is obvious which
   one of them was meant. */
.confess-landed{ animation: landed 2.2s ease both; }
@keyframes landed{
  0%, 60%{ box-shadow: 0 0 0 2px var(--say); }
  100%{ box-shadow: 0 0 0 2px transparent; }
}


/* ---------- the one thing asked for after signing in ---------- */
/* The page behind is blurred rather than merely darkened: this is a question,
   and the answer should be the only thing in focus. */
.ask{
  position: fixed; inset: 0; z-index: 130;
  display: flex; align-items: center; justify-content: center; padding: 24px;
  background: rgba(12, 10, 20, .34);
  backdrop-filter: blur(7px); -webkit-backdrop-filter: blur(7px);
  opacity: 0; transition: opacity .18s ease;
}
.ask.open{ opacity: 1; }
.ask-card{
  width: min(340px, 100%);
  background: var(--paper); border-radius: 20px; padding: 24px 22px 18px;
  box-shadow: 0 24px 60px rgba(12,10,20,.3);
  text-align: center;
  transform: scale(.96); transition: transform .2s cubic-bezier(.32,.72,0,1);
}
.ask.open .ask-card{ transform: none; }
.ask-title{
  margin: 0 0 8px; font-family: var(--font-body); font-size: 18px;
  font-weight: 700; letter-spacing: -0.01em; color: var(--ink);
}
.ask-line{
  margin: 0 0 20px; font-size: 13.5px; line-height: 1.5;
  color: var(--ink); opacity: .7;
}
.ask-yes{
  display: block; width: 100%;
  font-family: var(--font-body); font-size: 14.5px; font-weight: 600;
  padding: 13px; border-radius: 12px;
  border: none; background: #d0332a; color: #fff; cursor: pointer;
}
.ask-yes:active{ background: #b62b23; }
/* Not a button: the way out should be quieter than the way on. */
.ask-no{
  display: block; width: 100%; margin-top: 4px;
  font-family: var(--font-body); font-size: 13.5px; font-weight: 500;
  padding: 12px; border: none; background: none; color: var(--ink); cursor: pointer;
}


/* ---------- the discussion board ---------- */
/* A discussion is signed, so the name leads and the time follows it. */
.talk-head{
  display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap;
  margin: 0 0 7px; font-size: 12.5px;
}
.talk-who{ font-size: 13.5px; font-weight: 650; color: var(--ink); }
.talk-admin{ color: #a4160c; }
.talk-you{
  font-size: 10.5px; font-weight: 600; padding: 1px 6px; border-radius: 5px;
  background: var(--say-tint); color: var(--say);
}
.talk-when{ color: var(--ink); opacity: .5; font-variant-numeric: tabular-nums; }
/* Who it really was, beside the word Anonymous. Only an administrator is ever
   sent this, and it is set quietly so the post still reads as anonymous. */
.talk-really{
  font-size: 11.5px; font-weight: 600; font-style: italic;
  padding: 1px 6px; border-radius: 5px;
  background: rgba(164, 22, 12, .08); color: #a4160c;
}

/* The tick that takes the name off one post. A line of small print under the
   box, not a control with a border: it is an exception to the board, and it
   should read like one. */
.anon-tick{
  display: flex; align-items: center; gap: 7px;
  margin-top: 10px; font-size: 12px; font-weight: 500;
  color: var(--ink); opacity: .55; cursor: pointer;
}
.anon-tick:has(input:checked){ opacity: 1; color: var(--say); font-weight: 600; }
.anon-tick input{ accent-color: var(--say); margin: 0; }
.reply-compose .anon-tick{ margin: 8px 0 0 40px; font-size: 11.5px; }

/* Plain icons, not three boxed buttons in a row: the boxes read as a block of
   controls sitting under the box you are typing in, which is more furniture
   than three optional extras deserve. */
.talk-tool{
  flex-shrink: 0; display: flex; align-items: center; justify-content: center;
  width: 32px; height: 32px; padding: 0; border-radius: 8px;
  border: none; background: none; color: var(--ink); opacity: .55; cursor: pointer;
}
.talk-tool svg{ width: 19px; height: 19px; }
.talk-tool:hover{ opacity: 1; }
.talk-tool.on{ background: none; color: var(--say); opacity: 1; }

/* The camera beside them loses its box for the same reason. */
#talk-compose .shot-add{
  width: 32px; height: 32px; border: none; background: none; opacity: .55;
}
#talk-compose .shot-add:hover{ opacity: 1; }
#talk-compose .shot-add svg{ width: 19px; height: 19px; }

.talk-poll{ display: flex; flex-direction: column; gap: 6px; margin-top: 10px; }
.talk-poll input, #talk-video{
  width: 100%; font-family: var(--font-body); font-size: 13.5px; color: var(--ink);
  padding: 10px 11px; border-radius: 10px; border: 1px solid var(--line); background: var(--paper);
}
#talk-video{ margin-top: 10px; }
.talk-poll input:focus, #talk-video:focus{ outline: none; border-color: var(--say); }

/* A result read as type, not as a chart. Each answer is a line with its share
   at the end and a hairline underneath carrying the proportion -- the app draws
   time and days the same way, and a stack of filled slabs belongs to a
   dashboard rather than to a page somebody is reading. */
.poll{ margin: 12px 0 6px; }
.poll-q{ margin: 0 0 12px; font-size: 15px; font-weight: 600; color: var(--ink); }

/* Before anybody has voted, the answers are a list to choose from rather than a
   stack of boxes. Ruled apart like the result they turn into, with a mark to
   press rather than a rectangle -- the shape of the thing does not change when
   the vote is cast, only what it says. */
.poll-pick{
  display: flex; align-items: center; gap: 11px;
  width: 100%; text-align: left; padding: 12px 2px;
  font-family: var(--font-body); font-size: 14px; font-weight: 450;
  border: none; border-bottom: 1px solid var(--line-soft);
  background: none; color: var(--ink); cursor: pointer;
}
.poll-pick:last-of-type{ border-bottom: none; }
.poll-mark{
  flex-shrink: 0; width: 15px; height: 15px; border-radius: 50%;
  border: 1.5px solid var(--line); background: none;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.poll-pick:hover .poll-mark,
.poll-pick:active .poll-mark{
  border-color: var(--say); box-shadow: inset 0 0 0 3.5px var(--say);
}
.poll-pick:hover{ color: var(--say); }

.poll-row{ margin-bottom: 13px; cursor: pointer; }
.poll-line{ display: flex; align-items: baseline; gap: 10px; }
.poll-label{
  font-size: 14px; font-weight: 450; color: var(--ink);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.poll-count{
  margin-left: auto; font-size: 13px; font-weight: 600; color: var(--ink);
  opacity: .45; font-variant-numeric: tabular-nums;
}
.poll-track{
  position: relative; height: 2px; margin-top: 6px; border-radius: 2px;
  background: var(--line);
}
.poll-track i{
  position: absolute; inset: 0 auto 0 0; display: block;
  border-radius: 2px; background: var(--ink); opacity: .22;
  transition: width .4s cubic-bezier(.32,.72,0,1);
}
/* Yours is the one in colour and in weight. Nothing else needs to shout. */
.poll-row.chosen .poll-label{ font-weight: 650; color: var(--say); }
.poll-row.chosen .poll-count{ color: var(--say); opacity: 1; }
.poll-row.chosen .poll-track i{ background: var(--say); opacity: 1; }

.poll-voters{ margin: 5px 0 0; font-size: 11px; line-height: 1.45; color: var(--ink); opacity: .5; }
.poll-voters i{ font-style: normal; opacity: .8; }

.poll-foot{
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
  margin-top: 12px; font-size: 11.5px; color: var(--ink); opacity: .65;
}
.poll-hide{ display: flex; align-items: center; gap: 6px; cursor: pointer; }
.poll-hide input{ accent-color: var(--say); }
.poll-change{
  margin-left: auto; font-family: var(--font-body); font-size: 11.5px; font-weight: 600;
  border: none; background: none; color: var(--say); cursor: pointer; padding: 0;
}

.talk-video{
  margin-top: 10px; border-radius: 12px; overflow: hidden;
  aspect-ratio: 16 / 9; background: var(--panel);
}
.talk-video iframe{ width: 100%; height: 100%; border: 0; display: block; }

.talk-share{
  display: flex; align-items: center; gap: 6px;
  font-family: var(--font-body); font-size: 12.5px; font-weight: 600;
  border: none; background: none; color: var(--say); cursor: pointer; padding: 0;
}
.talk-share svg{ width: 15px; height: 15px; }
.talk .confess-acts{ gap: 16px; }


/* ---------- an hour the batch splits across ---------- */
/* Two labs at once, different subjects, different buildings. Each half gets its
   own block inside the one hour, ruled apart, so nobody reads the first room
   and stops. */
.tt-split{
  margin: 0 0 10px; font-size: 11px; font-weight: 600; letter-spacing: .02em;
  text-transform: uppercase; color: var(--say); opacity: .8;
}
.tt-part + .tt-part{
  margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line-soft);
}
.cell-divide{
  display: block; height: 1px; margin: 7px 0; background: var(--line);
}


/* ---------- video on the board ---------- */
/* A clip sits the way a picture does -- inside the post, edge to edge, its own
   height. preload is off, so a thread full of them costs one poster frame each
   until somebody actually presses play. */
.clip{
  margin-top: 10px; border-radius: var(--radius); overflow: hidden;
  background: #14060f; line-height: 0;
}
.clip video{ width: 100%; max-height: 60vh; display: block; }

/* What is about to be sent: the name and the weight of it, because a video is
   the one thing here big enough that the size is worth knowing before it goes. */
.clip-strip{ display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.clip-pick{
  display: inline-flex; align-items: center; gap: 7px;
  padding: 7px 9px; border-radius: var(--radius);
  background: var(--panel); font-size: 12px; color: var(--ink);
}
.clip-pick svg{ width: 15px; height: 15px; opacity: .6; flex-shrink: 0; }
.clip-pick b{ font-weight: 600; max-width: 150px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.clip-pick i{ font-style: normal; opacity: .55; font-variant-numeric: tabular-nums; }
.clip-pick button{
  border: none; background: none; cursor: pointer; padding: 0 2px;
  font-size: 15px; line-height: 1; color: var(--ink); opacity: .5;
}

/* Taking something down is not the same kind of act as replying to it, so it
   does not get the same colour. */
.talk-delete, .reply-drop{
  font-family: var(--font-body); font-size: 12.5px; font-weight: 600;
  border: none; background: none; color: #a4160c; cursor: pointer; padding: 0;
}
.reply-acts{ display: inline-flex; align-items: center; gap: 12px; }
.reply-flag, .reply-drop{ font-size: 11.5px; }
.reply-flag{
  font-family: var(--font-body); font-weight: 600;
  border: none; background: none; color: var(--ink); opacity: .45; cursor: pointer; padding: 0;
}
.reply-flag:disabled, .reply-drop:disabled{ opacity: .4; cursor: default; }


/* ---------- sharing a cab (and the Campus screens) ---------- */
/* Set the way an iPhone app is set, in the owner's SPOT language: black and
   white ink, one soft surface (#F2F2F7), two weights (400 and 600), buttons
   rounded 6px, cards 12px, sheets 16px, a 16px gutter. Colour only for status:
   green in, orange waiting, red out. Everything that can be pressed answers
   the press, screens push in from the right and forms rise from the bottom on
   Apple's sheet curve, and none of it moves with reduce-motion on.
   Scoped to the Cabs and Campus views and to pages they open (.page.uber);
   nothing here reaches the other tabs. */
/* .ub-ask: the small sheets, which sit on the page body when no page is open */
#view-cab, #view-campus, .page.uber, .ub-ask{
  --ub-ink: #000;
  --ub-ink2: #3c3c43;
  --ub-ink3: #8e8e93;
  --ub-page: #fff;
  --ub-soft: #f2f2f7;
  --ub-soft2: #e5e5ea;
  --ub-sep: rgba(60,60,67,.13);
  --ub-live: #34c759;
  --ub-live-ink: #248a3d;
  --ub-wait: #ff9500;
  --ub-wait-ink: #c93400;
  --ub-alert: #ff3b30;
  --ub-alert-ink: #d70015;
  --ub-ease: cubic-bezier(.32,.72,0,1);
  --ub-spring: cubic-bezier(.34,1.56,.64,1);
  --ub-out: cubic-bezier(.2,1,.3,1);
  --ub-font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display", "Inter", system-ui, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-family: var(--ub-font);
  color: var(--ub-ink);
  letter-spacing: -.01em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
:is(#view-cab, #view-campus, .page.uber, .ub-ask) :is(input, select, textarea, button){ font-family: var(--ub-font); letter-spacing: inherit; }

/* Every press answers: a quick dim and a small give, a springy return. */
:is(#view-cab, #view-campus, .page.uber, .ub-ask) :is(button, a, summary, label.cp-photo-add, label.ub-btn, label.cp-eposter-add):not(.leaflet-container *){
  -webkit-tap-highlight-color: transparent; touch-action: manipulation; cursor: pointer;
  transition: opacity .35s cubic-bezier(.2,.8,.2,1), transform .45s cubic-bezier(.2,1.4,.4,1), background-color .2s ease, color .2s ease;
}
:is(#view-cab, #view-campus, .page.uber, .ub-ask) :is(button, a, summary, label.cp-photo-add, label.ub-btn, label.cp-eposter-add):not(.leaflet-container *):not(:disabled):active{
  opacity: .6; transform: scale(var(--ub-press, .97)); transition-duration: .08s, .12s, .1s, .1s;
}
:is(#view-cab, #view-campus, .page.uber, .ub-ask) button:disabled{ cursor: default; }
:is(#view-cab, #view-campus, .page.uber, .ub-ask) input::-webkit-search-cancel-button{ display: none; }

#view-cab.active, #view-campus.active{ animation: ub-fade .32s ease both; }
#view-cab.active{ padding: 0; }
@keyframes ub-fade{ from{ opacity: 0; } }
.tab-btn{ position: relative; }
.cab-tab-dot{
  position: absolute; top: 2px; left: calc(50% + 6px);
  width: 9px; height: 9px; border-radius: 50%; background: #ff3b30; border: 2px solid var(--paper);
}

/* signed out: the shared sign-in card, then soft rows */
.cab-signin{ padding: 12px 6px; }

/* ---------- type ---------- */
.ub-title{ margin: 4px 0 0; font-size: 32px; font-weight: 600; line-height: 1.15; letter-spacing: -.02em; color: var(--ub-ink); overflow-wrap: anywhere; }
.ub-title.sm{ font-size: 24px; line-height: 1.2; }
.ub-sub{ margin: 6px 0 0; font-size: 15px; line-height: 1.4; color: var(--ub-ink2); }
.ub-body{ margin: 16px 0 0; font-size: 16px; line-height: 1.5; overflow-wrap: anywhere; }
.ub-h{ display: flex; align-items: center; gap: 8px; margin: 32px 0 8px; font-size: 13px; font-weight: 600; letter-spacing: .01em; color: var(--ub-ink2); }
.ub-muted{ margin: 8px 0; font-size: 15px; color: var(--ub-ink3); }
.ub-err{ margin: 16px 0 0; font-size: 15px; line-height: 1.4; color: var(--ub-alert-ink); }
.ub-count{ min-width: 20px; height: 20px; padding: 0 6px; border-radius: 10px; display: inline-grid; place-items: center; background: var(--ub-wait); color: #000; font-size: 12px; font-weight: 600; letter-spacing: 0; }

/* status: a dot and a word */
.ub-st{ display: inline-flex; align-items: center; gap: 6px; margin-top: 4px; font-size: 13px; font-weight: 600; color: var(--ub-ink); white-space: nowrap; }
.ub-st::before{ content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--ub-ink); flex: none; }
.ub-st.ok::before{ background: var(--ub-live); }
.ub-st.wait::before{ background: var(--ub-wait); }
.ub-st.no::before{ background: var(--ub-alert); }
.ub-st.plain{ font-weight: 400; color: var(--ub-ink2); }
.ub-st.plain::before{ display: none; }
.ub-side .ub-st, .ub-row > .ub-st{ margin-top: 0; }
.ub-pill{ display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 10px; margin-bottom: 8px; border-radius: 6px; background: var(--ub-soft); font-size: 13px; font-weight: 600; }
.ub-pill::before{ content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--ub-ink); }
.ub-pill.ok::before{ background: var(--ub-live); }
.ub-pill.wait::before{ background: var(--ub-wait); }
.ub-pill.no::before{ background: var(--ub-alert); }
.ub-tag{ display: inline-block; margin-left: 8px; padding: 2px 6px; border-radius: 4px; background: var(--ub-ink); color: #fff; font-size: 11px; font-weight: 600; letter-spacing: 0; vertical-align: 2px; }

/* ---------- the map and the sheet over it (Cabs tab) ---------- */
.ub-mapwrap{ position: relative; margin: -14px -10px 0; }
.ub-map{ height: 40vh; min-height: 260px; background: var(--ub-soft); z-index: 0; }
.ub-map.ub-map-off{ display: grid; place-items: center; }
.ub-fab{
  position: absolute; top: calc(12px + env(safe-area-inset-top)); z-index: 500;
  width: 44px; height: 44px; border: none; border-radius: 50%; padding: 0;
  display: grid; place-items: center;
  background: #fff; color: #3c4043; box-shadow: 0 1px 2px rgba(60,64,67,.3), 0 2px 6px 2px rgba(60,64,67,.15);
}
/* The locate button turns blue while the map is following you. */
.ub-fab.on{ color: #1a73e8; }
.ub-fab.left{ left: 16px; }
.ub-fab.right{ right: 16px; }
.ub-fab svg{ width: 20px; height: 20px; }
.cab-badge{
  position: absolute; top: -5px; right: -5px; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 10px;
  background: var(--ub-alert); color: #fff; font-size: 12px; font-weight: 600; line-height: 20px; text-align: center;
  box-shadow: 0 0 0 2px #fff;
}

.ub-sheet{
  position: relative; z-index: 1; margin-top: -16px; padding: 8px 16px 136px;
  background: var(--ub-page); border-radius: 16px 16px 0 0;
  box-shadow: 0 -1px 0 rgba(0,0,0,.04), 0 -10px 30px rgba(0,0,0,.08);
  animation: ub-rise .5s var(--ub-ease) both;
}
#view-cab > #cab-body > .ub-sheet{ margin-left: -10px; margin-right: -10px; padding-left: 26px; padding-right: 26px; }
@keyframes ub-rise{ from{ transform: translateY(32px); opacity: 0; } }
.ub-handle{ display: block; width: 36px; height: 5px; margin: 0 auto 12px; border-radius: 3px; background: var(--ub-soft2); }

/* search */
.ub-where{
  display: flex; align-items: center; gap: 8px; height: 52px; padding: 0 4px 0 14px;
  background: var(--ub-soft); border-radius: 12px; transition: box-shadow .2s ease, background .2s ease;
}
.ub-where:focus-within{ background: #fff; box-shadow: inset 0 0 0 2px #000; }
/* "From", above "Where to?": smaller, since most people leave it alone. */
.cab-from-box{ height: 44px; margin-bottom: 8px; padding-left: 20px; gap: 14px; }
.cab-from-box input{ font-size: 15px; }
.cab-from-dot{ flex: none; width: 8px; height: 8px; border-radius: 50%; background: #000; }
.cab-pin.from{ background: #000; }
.cab-me-mini{ display: block; width: 14px; height: 14px; border-radius: 50%; background: #1a73e8; border: 3px solid #fff; box-shadow: 0 0 0 1px rgba(26,115,232,.35); box-sizing: content-box; }
.ub-where > svg{ width: 20px; height: 20px; flex: none; color: var(--ub-ink3); }
.ub-where input{ flex: 1; min-width: 0; height: 100%; padding: 0; border: none; outline: none; background: none; font-size: 17px; color: #000; }
.ub-where input::placeholder{ color: var(--ub-ink3); }
.ub-where.sm{ height: 44px; margin-top: 16px; padding-right: 12px; }
.ub-go{
  display: grid; place-items: center; flex: none; width: 44px; height: 44px; border: none; border-radius: 8px; padding: 0;
  background: #000; color: #fff;
}
.ub-go.soft{ background: transparent; color: var(--ub-ink2); }
.ub-go svg{ width: 20px; height: 20px; }
.ub-where .ub-go{ width: 44px; height: 44px; }
.ub-where .ub-go:not(.soft){ border-radius: 8px; }
#cab-hits:not(:empty){ margin-top: 8px; }

/* ---------- rows ---------- */
.ub-rows, .ub-list{ position: relative; }
.ub-row{
  --ub-press: .985;
  position: relative; display: flex; align-items: center; gap: 12px; width: 100%; min-height: 68px; padding: 12px 0; margin: 0;
  text-align: left; font: inherit; color: var(--ub-ink); background: none; border: none; text-decoration: none;
}
.ub-rows > .ub-row::after, .ub-rows > * > .ub-row::after{
  content: ""; position: absolute; left: 56px; right: 0; bottom: 0; height: 1px; background: var(--ub-sep);
}
.ub-rows > :last-child.ub-row::after, .ub-rows > :last-child > .ub-row::after{ display: none; }
.ub-row.static{ cursor: default; }
.ub-av, .ub-ico{
  flex: none; width: 44px; height: 44px; border-radius: 8px; display: grid; place-items: center;
  background: var(--ub-soft); color: var(--ub-ink); font-size: 17px; font-weight: 600; letter-spacing: 0;
}
.ub-ico svg{ width: 20px; height: 20px; }
.ub-main{ flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: flex-start; gap: 2px; }
.ub-main > *{ max-width: 100%; }
.ub-main b{ font-size: 16px; font-weight: 600; line-height: 1.3; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ub-main i{ font-style: normal; font-size: 14px; line-height: 1.35; color: var(--ub-ink2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ub-main em{ font-style: normal; font-size: 13px; line-height: 1.35; color: var(--ub-ink3); }
.ub-main .wrap{ white-space: normal; overflow-wrap: anywhere; }
.ub-main a{ color: inherit; text-decoration: none; }
.ub-side{ display: flex; flex-direction: column; align-items: flex-end; gap: 2px; flex: none; align-self: flex-start; padding-top: 2px; }
.ub-side b{ font-size: 15px; font-weight: 600; line-height: 1.3; white-space: nowrap; font-variant-numeric: tabular-nums; }
.ub-side i{ font-style: normal; font-size: 13px; color: var(--ub-ink2); }
.ub-chev{ flex: none; width: 16px; height: 16px; color: var(--ub-ink3); }
.ub-chev svg{ width: 16px; height: 16px; }
.ub-chev{ transition: transform .35s var(--ub-ease); }
.ub-row[aria-expanded="true"] .ub-chev{ transform: rotate(90deg); }

/* a grouped list on the soft surface (iPhone inset-grouped) */
.ub-list{ margin-top: 16px; padding: 0 16px; background: var(--ub-soft); border-radius: 12px; }
.ub-list .ub-av, .ub-list .ub-ico, .ub-card .ub-av, .ub-card .ub-ico{ background: var(--ub-page); }
.ub-list > *{ box-shadow: 0 1px 0 var(--ub-page); }
.ub-list > :last-child{ box-shadow: none; }
.ub-h + .ub-list{ margin-top: 0; }
.ub-round{
  flex: none; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 8px; border: none; padding: 0;
  background: var(--ub-page); color: var(--ub-ink);
}
.ub-round svg{ width: 20px; height: 20px; }
.ub-round.on{ background: var(--ub-ink); color: #fff; }

.ub-card{ margin-top: 16px; padding: 16px; background: var(--ub-soft); border-radius: 12px; }
.ub-note{ display: flex; align-items: center; gap: 12px; margin-top: 16px; padding: 14px 16px; background: var(--ub-soft); border-radius: 12px; font-size: 15px; line-height: 1.4; }
.ub-note svg{ width: 20px; height: 20px; flex: none; color: var(--ub-ink2); }

.ub-empty{ display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 48px 24px; text-align: center; }
.ub-empty.small{ padding: 24px 16px 8px; }
.ub-empty b{ font-size: 17px; font-weight: 600; }
.ub-empty p{ margin: 0; max-width: 32ch; font-size: 15px; line-height: 1.45; color: var(--ub-ink2); }
.ub-empty .ub-btn{ margin-top: 12px; }
.ub-empty-ico{ display: grid; place-items: center; width: 56px; height: 56px; margin-bottom: 8px; border-radius: 12px; background: var(--ub-soft); color: var(--ub-ink2); }
.ub-empty-ico svg{ width: 26px; height: 26px; }
.ub-loading{ display: grid; place-items: center; padding: 20px 0; }
.ub-spin{ display: block; width: 22px; height: 22px; border-radius: 50%; border: 2.5px solid var(--ub-soft2); border-top-color: var(--ub-ink); animation: ub-spin .8s linear infinite; }
@keyframes ub-spin{ to{ transform: rotate(360deg); } }

/* folds: there when wanted, out of the way when not */
.ub-fold{ margin-top: 16px; }
.ub-fold summary{
  --ub-press: .985;
  display: flex; align-items: center; gap: 12px; min-height: 52px; padding: 0 16px; list-style: none;
  font-size: 16px; font-weight: 600; background: var(--ub-soft); border-radius: 12px;
}
.ub-fold summary::-webkit-details-marker{ display: none; }
.ub-fold summary > svg{ width: 20px; height: 20px; flex: none; color: var(--ub-ink2); }
.ub-fold summary::after{
  content: ""; margin-left: auto; width: 8px; height: 8px; border-right: 2px solid var(--ub-ink3); border-bottom: 2px solid var(--ub-ink3);
  transform: rotate(45deg) translateY(-2px); transition: transform .35s var(--ub-ease);
}
.ub-fold[open] summary::after{ transform: rotate(-135deg) translate(-2px, 0); }
.ub-fold-v{ margin-left: auto; font-weight: 400; color: var(--ub-ink2); }
.ub-fold-v + *{ margin-left: 0; }
.ub-fold summary:has(.ub-fold-v)::after{ margin-left: 8px; }
.ub-fold[open] > :not(summary){ animation: ub-in .35s var(--ub-out) both; }
.ub-fold[open] > .ub-group, .ub-fold[open] > .ub-cta, .ub-fold[open] > .ub-rows{ margin-top: 12px; }
.cab-other{ margin-top: 24px; }
@keyframes ub-in{ from{ opacity: 0; transform: translateY(8px); } }

/* waiting for data: grey shapes where the rows will be */
.ub-skel{ display: flex; align-items: center; gap: 12px; min-height: 68px; padding: 12px 0; }
.ub-skel i{ width: 44px; height: 44px; border-radius: 8px; background: var(--ub-soft); flex: none; }
.ub-skel span{ flex: 1; display: flex; flex-direction: column; gap: 8px; }
.ub-skel b{ height: 12px; width: 70%; border-radius: 6px; background: var(--ub-soft); }
.ub-skel b + b{ width: 42%; }
.ub-skel i, .ub-skel b, .ub-ridemap.skel, .cp-item.skel > *{ animation: ub-breathe 1.6s ease-in-out infinite; }
@keyframes ub-breathe{ 50%{ opacity: .45; } }

/* ---------- buttons ---------- */
.ub-cta{
  display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; height: 52px; border: none; border-radius: 6px;
  font-size: 17px; font-weight: 600; color: #fff; background: #000;
}
.ub-cta:disabled{ background: var(--ub-soft2); color: var(--ub-ink3); }
.ub-btn{
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 44px; padding: 0 16px;
  border: none; border-radius: 6px; font-size: 15px; font-weight: 600; color: var(--ub-ink); background: var(--ub-soft);
  text-decoration: none; white-space: nowrap;
}
.ub-btn svg{ width: 18px; height: 18px; flex: none; }
.ub-btn.ink{ background: #000; color: #fff; }
.ub-btn.white{ background: var(--ub-page); }
.ub-btn.danger{ color: var(--ub-alert-ink); }
.ub-btn.sm{ height: 36px; padding: 0 14px; }
.ub-btn.icon{ width: 44px; padding: 0; }
.ub-btn:disabled{ opacity: .4; }
.ub-btn.on{ background: #000; color: #fff; }
.ub-quiet{
  --ub-press: .985;
  display: flex; align-items: center; justify-content: center; width: 100%; min-height: 52px; margin-top: 32px; padding: 0 16px;
  border: none; border-radius: 12px; background: var(--ub-soft); font-size: 17px; font-weight: 400; color: var(--ub-ink);
}
.ub-quiet.danger{ color: var(--ub-alert-ink); }
.ub-quiet.armed{ background: var(--ub-alert); color: #fff; font-weight: 600; }
.ub-link{ flex: none; min-height: 44px; padding: 0 0 0 12px; border: none; background: none; font-size: 15px; font-weight: 600; color: var(--ub-ink); }

/* the primary action, kept at the bottom of the screen */
.ub-bar{
  position: sticky; bottom: 0; z-index: 5; margin: auto -16px 0; padding: 16px 16px calc(12px + env(safe-area-inset-bottom));
  background: linear-gradient(to top, #fff 78%, rgba(255,255,255,0));
}
.ub-bar.fixed{
  position: fixed; left: 0; right: 0; bottom: var(--tabbar-space, 78px); margin: 0 auto; max-width: 860px;
  padding: 16px 16px 12px; pointer-events: none;
}
.ub-bar.fixed .ub-cta{ pointer-events: auto; box-shadow: 0 1px 2px rgba(0,0,0,.1), 0 8px 24px rgba(0,0,0,.18); }

/* ---------- forms: inset-grouped rows ---------- */
.ub-group{ margin-top: 16px; padding: 0 16px; background: var(--ub-soft); border-radius: 12px; }
.ub-fld{ display: flex; align-items: center; gap: 12px; min-height: 52px; font-size: 17px; box-shadow: 0 1px 0 var(--ub-page); }
.ub-fld:last-child{ box-shadow: none; }
.ub-fld > svg{ width: 20px; height: 20px; flex: none; color: var(--ub-ink2); }
.ub-k{ flex: none; font-size: 17px; }
.ub-v{ flex: 1; min-width: 0; font-size: 17px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ub-fld input, .ub-fld select{
  flex: 1; min-width: 0; height: 52px; padding: 0; border: none; outline: none; background: none;
  font-size: 17px; color: var(--ub-ink); -webkit-appearance: none; appearance: none;
}
.ub-fld input::placeholder{ color: var(--ub-ink3); }
.ub-k + input, .ub-k + select{ text-align: right; color: var(--ub-ink2); }
.ub-k + select{ direction: rtl; }
.ub-fld select{
  padding-right: 20px; background: no-repeat right center / 14px
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%238e8e93' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m7 9.5 5-5 5 5M7 14.5l5 5 5-5'/%3E%3C/svg%3E");
}
.ub-fld input[type="datetime-local"]{ min-width: 0; }
.ub-fld .ub-btn{ flex: none; }
.ub-dot, .ub-sq{ display: inline-block; flex: none; width: 10px; height: 10px; margin: 0 5px; }
.ub-dot{ border-radius: 50%; background: #000; }
.ub-sq{ background: #000; }
.ub-step{ display: inline-flex; align-items: center; margin-left: auto; border-radius: 8px; background: var(--ub-page); }
.ub-step button{ width: 44px; height: 44px; border: none; background: none; padding: 0; font-size: 22px; line-height: 1; color: #000; }
.ub-step b{ min-width: 24px; text-align: center; font-size: 17px; font-weight: 600; font-variant-numeric: tabular-nums; }
.cab-form > .ub-title + .ub-group{ margin-top: 24px; }
.cab-form .ub-seg, .cab-form .ub-chips{ margin-top: 24px; }

/* the segmented control */
.ub-seg{
  position: relative; display: grid; grid-template-columns: repeat(var(--n, 3), 1fr); margin-top: 16px; padding: 3px;
  border-radius: 9px; background: var(--ub-soft);
}
.ub-seg-thumb{
  position: absolute; top: 3px; bottom: 3px; left: 3px; width: calc((100% - 6px) / var(--n, 3)); border-radius: 7px;
  background: #fff; box-shadow: 0 3px 8px rgba(0,0,0,.12), 0 3px 1px rgba(0,0,0,.04);
  transition: transform .4s var(--ub-ease);
}
:is(#view-cab, #view-campus, .page.uber, .ub-ask) .ub-seg button{
  --ub-press: 1; position: relative; z-index: 1; min-width: 0; height: 44px; padding: 0 4px; border: none; background: none;
  font-size: 14px; font-weight: 400; color: var(--ub-ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.ub-seg button.on{ font-weight: 600; }

/* chips */
.ub-chips{ display: flex; gap: 8px; margin: 16px -16px 0; padding: 0 16px; overflow-x: auto; scrollbar-width: none; }
.ub-chips::-webkit-scrollbar{ display: none; }
.ub-chip{ flex: none; height: 44px; padding: 0 16px; border: none; border-radius: 6px; background: var(--ub-soft); font-size: 15px; font-weight: 400; color: var(--ub-ink); }
.ub-chip.on{ background: #000; color: #fff; font-weight: 600; }

/* ---------- the place picker and its map ---------- */
.cab-pick-slot:not(:empty){ margin-top: 16px; }
.cab-pick-results:not(:empty){ margin-top: 4px; }
.cab-pick-map, .ub-ridemap{ background: var(--ub-soft); z-index: 0; }
.cab-pick-map{ height: 200px; margin-top: 12px; border-radius: 12px; overflow: hidden; }
.cab-pick .ub-group{ margin-top: 8px; }
.cab-pin{ display: block; width: 18px; height: 18px; border-radius: 50%; border: 3px solid #fff; box-shadow: 0 1px 6px rgba(0,0,0,.4); background: #000; }
.cab-pin.campus{ background: #000; border-radius: 4px; }
.cab-pin.ride, .cab-pin.pick{ background: var(--ub-alert, #ff3b30); }
.cab-pin.ride.ok{ background: var(--ub-live, #34c759); }
.cab-pin.want{ background: #007aff; }
/* Yourself: the blue dot, with a beam for the way the phone faces. */
.cab-me{ position: relative; display: block; width: 22px; height: 22px; }
.cab-me::before{ content: ""; position: absolute; inset: -9px; border-radius: 50%; background: rgba(26,115,232,.18); }
.cab-me::after{ content: ""; position: absolute; inset: 0; box-sizing: border-box; border-radius: 50%; background: #1a73e8; border: 3px solid #fff; box-shadow: 0 1px 5px rgba(0,0,0,.35); }
.cab-me b{ display: none; position: absolute; left: 50%; top: 50%; width: 96px; height: 96px; margin: -48px 0 0 -48px; border-radius: 50%; pointer-events: none;
  background: conic-gradient(from -32deg, rgba(26,115,232,.55) 0deg 64deg, transparent 64deg);
  -webkit-mask: radial-gradient(circle, #000 12%, transparent 70%); mask: radial-gradient(circle, #000 12%, transparent 70%);
  transform: rotate(var(--h, 0deg)); }
.cab-me.dir b{ display: block; }
.cab-me.dir::before{ display: none; }
/* A person: green once accepted, red while waiting, blue for yourself. */
.cab-pin.person{ position: relative; display: grid; place-items: center; width: 30px; height: 30px; font: 600 13px/1 inherit; font-style: normal; color: #fff; opacity: .7; }
.cab-pin.person.live{ opacity: 1; }
.cab-pin.person.ok{ background: var(--ub-live, #34c759); }
.cab-pin.person.wait{ background: var(--ub-alert, #ff3b30); }
.cab-pin.person.me{ background: #007aff; }
.cab-pin.person.live::after{ content: ""; position: absolute; inset: -6px; border-radius: 50%; border: 2px solid #007aff; opacity: 0; animation: cab-live 2s ease-out infinite; }
.cab-pin.person.ok.live::after{ border-color: var(--ub-live, #34c759); }
.cab-pin.person.wait.live::after{ border-color: var(--ub-alert, #ff3b30); }
@keyframes cab-live{ 0%{ transform: scale(.8); opacity: .7; } 100%{ transform: scale(1.5); opacity: 0; } }
@media (prefers-reduced-motion: reduce){ .cab-pin.person.live::after{ animation: none; } }
.cab-live-chip{ position: absolute; left: 12px; bottom: 28px; z-index: 600; display: flex; align-items: center; gap: 8px; min-height: 36px; padding: 0 6px 0 12px; border-radius: 18px; background: #fff; box-shadow: 0 2px 10px rgba(0,0,0,.18); font-size: 13px; font-weight: 500; color: #000; }
.cab-live-chip[hidden]{ display: none; }
.cab-live-chip i{ width: 8px; height: 8px; border-radius: 50%; background: var(--ub-live, #34c759); }
.cab-live-chip button{ min-height: 28px; padding: 0 10px; border: none; border-radius: 14px; background: var(--ub-soft); font: inherit; font-weight: 600; color: #000; }
.cab-live-chip button:only-child{ margin-left: -6px; background: none; }
.leaflet-container{ font-family: inherit; }
.leaflet-container .leaflet-control-attribution{ font-size: 10px; background: rgba(255,255,255,.7); }

/* ---------- the full page: a screen stack ---------- */
.page.uber{ background: #fff; box-shadow: -16px 0 40px rgba(0,0,0,.12); }
.page.uber.ub-in{ animation: ub-push .5s var(--ub-ease) both; }
.page.uber.ub-in-up{ animation: ub-up .5s var(--ub-ease) both; box-shadow: 0 -10px 40px rgba(0,0,0,.14); }
.page.uber.leaving{ animation: ub-push-out .3s var(--ub-ease) forwards; pointer-events: none; }
.page.uber.ub-in-up.leaving{ animation-name: ub-down; }
@keyframes ub-push{ from{ transform: translateX(100%); } }
@keyframes ub-up{ from{ transform: translateY(100%); } }
@keyframes ub-push-out{ to{ transform: translateX(100%); } }
@keyframes ub-down{ to{ transform: translateY(100%); } }

/* the navigation bar: clear at the top, frosted with a title once scrolled */
.page.uber .page-head{
  position: absolute; top: 0; left: 0; right: 0; z-index: 800; height: calc(44px + env(safe-area-inset-top));
  padding: env(safe-area-inset-top) 8px 0; gap: 0; border: none; background: transparent; pointer-events: none;
  transition: background-color .25s ease, box-shadow .25s ease;
}
.page.uber.scrolled .page-head{
  background: rgba(255,255,255,.86); -webkit-backdrop-filter: saturate(180%) blur(20px); backdrop-filter: saturate(180%) blur(20px);
  box-shadow: 0 .5px 0 rgba(0,0,0,.18); pointer-events: auto;
}
.page.uber .page-head h2{
  position: absolute; left: 64px; right: 64px; bottom: 0; height: 44px; line-height: 44px; margin: 0;
  font-family: var(--ub-font); font-size: 17px; font-weight: 600; letter-spacing: -.02em; text-align: center; color: #000;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; opacity: 0; transform: translateY(6px);
  transition: opacity .2s ease, transform .3s var(--ub-ease); pointer-events: none;
}
.page.uber.scrolled .page-head h2{ opacity: 1; transform: none; }
.page.uber .page-back{
  pointer-events: auto; width: 44px; height: 44px; border-radius: 12px; color: #000; background: transparent;
  transition: background-color .25s ease, box-shadow .25s ease, opacity .35s, transform .45s cubic-bezier(.2,1.4,.4,1);
}
.page.uber .page-back svg{ width: 22px; height: 22px; }
.page.uber.onmap:not(.scrolled) .page-back{ margin-left: 8px; margin-top: 8px; background: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.08), 0 4px 16px rgba(0,0,0,.14); }
.page.uber.modal .page-back{ width: auto; padding: 0 8px; }
.page.uber.modal .page-back svg{ display: none; }
.page.uber.modal .page-back::after{ content: "Cancel"; font-family: var(--ub-font); font-size: 17px; font-weight: 400; letter-spacing: -.02em; }
.page.uber .page-body{ position: relative; padding: 0; overflow-y: auto; overflow-x: hidden; -webkit-overflow-scrolling: touch; overscroll-behavior: contain; }

/* one screen: content, then its primary action pinned at the bottom */
.ub-screen{
  display: flex; flex-direction: column; min-height: 100%;
  padding: calc(52px + env(safe-area-inset-top)) 16px calc(24px + env(safe-area-inset-bottom));
}
.ub-screen:has(> .ub-bar), .ub-screen:has(> .cp-root > .ub-bar){ padding-bottom: 0; }
.ub-screen > *{ flex: none; }
.ub-screen > .ub-pill{ align-self: flex-start; }
.cp-root{ display: contents; }
#cab-mine-list, #cp-food-list, #cp-rlist{ margin-top: 12px; }
.ub-enter-push{ animation: ub-enter-push .5s var(--ub-ease) both; }
.ub-enter-pop{ animation: ub-enter-pop .5s var(--ub-ease) both; }
.ub-enter-up{ animation: ub-enter-up .5s var(--ub-ease) both; }
/* Push and pop the iOS way: the new screen comes in from the edge over the old
   one, which drifts a third of the way and dims (its copy is .ub-ghost, made by
   ubGhost in cab.js); going back, the old one slides off to the right. */
@keyframes ub-enter-push{ from{ transform: translateX(100%); box-shadow: -12px 0 32px rgba(0,0,0,.10); } to{ box-shadow: -12px 0 32px rgba(0,0,0,0); } }
@keyframes ub-enter-pop{ from{ transform: translateX(-30%); filter: brightness(.94); } }
.ub-screen{ background: var(--ub-screen-bg, var(--ub-page)); }
.page.uber .page-body{ z-index: 1; }
.page.uber.ub-moving-push .page-body, .page.uber.ub-moving-pop .page-body{ background: transparent; }
.ub-ghost{ position: absolute; left: 0; right: 0; overflow: hidden; pointer-events: none; background: var(--ub-page); }
.ub-ghost > *{ min-height: 100%; }
.ub-ghost.push{ z-index: 0; animation: ub-ghost-left .5s var(--ub-ease) both; }
.ub-ghost.pop{ z-index: 2; box-shadow: -12px 0 32px rgba(0,0,0,.10); animation: ub-ghost-right .5s var(--ub-ease) both; }
@keyframes ub-ghost-left{ to{ transform: translateX(-30%); filter: brightness(.94); } }
@keyframes ub-ghost-right{ to{ transform: translateX(100%); } }
@media (prefers-reduced-motion: reduce){ .ub-ghost{ display: none; } }
@keyframes ub-enter-up{ from{ opacity: 0; transform: translateY(8%); } }

/* ---------- a ride ---------- */
.ub-screen.cab-ride{ padding: 0; }
.cab-ride .ub-ridemap{ flex: none; height: 40vh; min-height: 240px; }
.cab-ride .ub-sheet{ flex: 1 0 auto; padding-bottom: 32px; animation: none; box-shadow: 0 -1px 0 rgba(0,0,0,.04), 0 -8px 24px rgba(0,0,0,.08); }
.cab-ride .ub-bar{ margin: 0; }
.ub-ridemap.ub-map-off{ display: none; }
.ub-ridemap.ub-map-off + .ub-sheet{ margin-top: 0; padding-top: calc(52px + env(safe-area-inset-top)); border-radius: 0; box-shadow: none; }
.ub-ridemap.ub-map-off + .ub-sheet .ub-handle{ display: none; }
.cab-route-sum{ white-space: nowrap; }
.cab-route-sum::before{ content: " · "; }
.cab-ride .ub-sheet > .ub-list:first-of-type{ margin-top: 16px; }

/* three facts side by side instead of three lines of text */
.ub-tiles{ display: grid; grid-template-columns: 1fr 1fr 1.15fr; gap: 8px; margin-top: 16px; }
.ub-tiles div{ display: flex; flex-direction: column; gap: 4px; min-width: 0; padding: 12px; background: var(--ub-soft); border-radius: 12px; }
.ub-tiles i{ font-style: normal; font-size: 13px; color: var(--ub-ink2); }
.ub-tiles b{ font-size: 17px; font-weight: 600; line-height: 1.2; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.ub-tiles b span{ font-size: 13px; font-weight: 400; color: var(--ub-ink2); letter-spacing: 0; }
.ub-tiles b.small{ font-size: 15px; letter-spacing: -.01em; overflow-wrap: anywhere; }

.cab-meet{ display: flex; align-items: center; gap: 12px; }
.cab-meet .ub-main i{ font-size: 13px; }
.cab-meet .ub-main b{ font-size: 17px; }
.cab-req{ padding: 0 16px 16px; }
.cab-req .ub-row{ min-height: 64px; }
.cab-req .ub-main b{ white-space: normal; }
.cab-req-acts{ display: flex; flex-wrap: wrap; gap: 8px; }
.cab-req-acts .ub-btn.ink{ flex: 1; }
.cab-req .cab-chat-slot:not([hidden]), .cp-chat-slot:not([hidden]){ display: block; margin-top: 12px; }
.cab-ask-note{ margin-top: 24px; }

/* ---------- chat, set as messages are on an iPhone ---------- */
.cab-chat{ border-radius: 12px; overflow: hidden; background: var(--ub-soft); }
.ub-card .cab-chat, .ub-list .cab-chat{ background: var(--ub-page); }
.cp-chat-slot{ padding-bottom: 12px; }
.cab-msgs{ display: flex; flex-direction: column; gap: 4px; max-height: 300px; min-height: 96px; overflow-y: auto; padding: 12px; overscroll-behavior: contain; }
.cab-chat-empty{ margin: auto; font-size: 15px; color: var(--ub-ink3); }
.cab-msg{
  max-width: 78%; padding: 10px 14px; font-size: 16px; line-height: 1.35; border-radius: 12px 12px 12px 4px;
  background: #fff; color: #000; align-self: flex-start; overflow-wrap: anywhere;
  animation: ub-msg .35s var(--ub-out) both;
}
.ub-card .cab-msg:not(.mine), .ub-list .cab-msg:not(.mine){ background: var(--ub-soft); }
.cab-msg.mine{ align-self: flex-end; background: #000; color: #fff; border-radius: 12px 12px 4px 12px; }
.cab-msg.mine + .cab-msg:not(.mine), .cab-msg:not(.mine) + .cab-msg.mine{ margin-top: 8px; }
.cab-msg.pending{ opacity: .5; }
@keyframes ub-msg{ from{ opacity: 0; transform: translateY(8px); } }
.cab-send{ display: flex; align-items: center; gap: 8px; padding: 8px; border-top: 1px solid var(--ub-page); }
.ub-card .cab-send, .ub-list .cab-send{ border-top-color: var(--ub-soft); }
.cab-send input{ flex: 1; min-width: 0; height: 44px; padding: 0 16px; font-size: 17px; color: #000; background: #fff; border: none; border-radius: 22px; outline: none; }
.ub-card .cab-send input, .ub-list .cab-send input{ background: var(--ub-soft); }
.cab-send input::placeholder{ color: var(--ub-ink3); }
.ub-send{ display: grid; place-items: center; flex: none; width: 44px; height: 44px; padding: 0; border: none; border-radius: 50%; background: #000; color: #fff; }
.ub-send svg{ width: 20px; height: 20px; }

/* ---------- the toast, while these screens are showing ---------- */
body:has(#view-cab.active, #view-campus.active, #page.uber:not([hidden])) .toast{
  left: 16px; right: 16px; max-width: 480px; margin: 0 auto; transform: translateY(16px);
  padding: 14px 16px; border-radius: 12px; background: #000; color: #fff; text-align: left; box-shadow: 0 8px 30px rgba(0,0,0,.2);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Inter", system-ui, sans-serif; font-size: 15px; font-weight: 400; line-height: 1.4; letter-spacing: -.01em;
  transition: opacity .3s ease, transform .45s cubic-bezier(.32,.72,0,1);
}
body:has(#view-cab.active, #view-campus.active, #page.uber:not([hidden])) .toast.show{ transform: none; }
body:has(#page.uber:not([hidden])) .toast{ bottom: calc(84px + env(safe-area-inset-bottom)); }

/* ---------- ride types: the drawings, the filter, the picker ---------- */
.ub-sr{ position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
/* The ride pictures sit straight on the page, plain, exactly as supplied:
   no tile, no shadow. Each is fitted inside a fixed box, so a wide car and a
   tall walker take the same room and nothing moves while they load. */
.ub-veh{ flex: none; display: block; width: 56px; height: 44px; }
.ub-veh img{ display: block; width: 100%; height: 100%; object-fit: contain; }
/* The walker fills the box's height; a touch smaller sits level with the rest. */
.ub-veh[data-v="walk"] img{ height: 96%; }
.ub-veh.xs{ width: 30px; height: 24px; }
.ub-veh.pick{ width: 76px; height: 56px; margin-bottom: 6px; }
.ub-veh.lg{ width: 104px; height: 80px; }
.ub-rows > .ub-row:has(> .ub-veh)::after{ left: 68px; }

.cab-types{ margin-top: 12px; }
.cab-types .ub-chip{ display: inline-flex; align-items: center; gap: 6px; padding: 0 14px 0 10px; }
.cab-types .ub-chip[data-v="all"]{ padding: 0 18px; }
/* Chosen, the chip keeps its drawing readable: a white card with an ink ring
   rather than the solid ink chip used elsewhere. */
.cab-types .ub-chip.on{ background: var(--ub-soft); color: #000; font-weight: 600; box-shadow: inset 0 0 0 2px #000; }

.cab-vpick{
  display: flex; gap: 8px; margin: 24px -16px 0; padding: 2px 16px 4px; overflow-x: auto;
  scroll-snap-type: x proximity; scroll-padding: 0 16px; scrollbar-width: none;
}
.cab-vpick::-webkit-scrollbar{ display: none; }
.cab-vcard{
  --ub-press: .95;
  position: relative; flex: none; display: flex; flex-direction: column; align-items: center; gap: 2px; width: 92px;
  padding: 8px 4px 14px; border: none; background: none; color: var(--ub-ink); scroll-snap-align: start;
}
.cab-vcard .ub-veh{ transition: transform .45s var(--ub-spring); }
.cab-vcard::after{
  content: ""; position: absolute; left: 30%; right: 30%; bottom: 2px; height: 3px; border-radius: 2px;
  background: #000; transform: scaleX(0); transition: transform .35s var(--ub-ease);
}
.cab-vcard b{ font-size: 15px; font-weight: 400; }
.cab-vcard i{ font-style: normal; font-size: 13px; color: var(--ub-ink2); }
.cab-vcard.on b{ font-weight: 600; }
.cab-vcard.on .ub-veh{ transform: translateY(-2px) scale(1.08); }
.cab-vcard.on::after{ transform: none; }
.ub-step button:disabled{ opacity: .25; }

.cab-ride-head{ display: flex; align-items: flex-end; gap: 12px; }
.cab-ride-tx{ flex: 1; min-width: 0; }
.cab-ride-veh{ flex: none; margin: 0 -4px 0 0; }
.ub-tiles.two{ grid-template-columns: 1fr 1fr; }
.ub-empty > .ub-veh{ margin-bottom: 4px; }

/* ---------- seats, sizes, gender ---------- */
.cab-sizes .ub-seg{ margin-top: 8px; }
.ub-cta svg{ width: 18px; height: 18px; }

/* a status and the ride's preference, side by side */
.ub-flags{ display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; margin-top: 4px; }
.ub-flags .ub-st{ margin-top: 0; }
.ub-flags.top{ margin: 0 0 8px; }
.ub-flags.top .ub-pill{ margin: 0; }
.ub-pref{
  display: inline-flex; align-items: center; gap: 4px; height: 22px; padding: 0 8px; border-radius: 6px;
  background: var(--ub-soft); color: var(--ub-ink); font-size: 12px; font-weight: 600; white-space: nowrap;
}
.ub-flags.top .ub-pref{ height: 28px; padding: 0 10px; font-size: 13px; }
.ub-pref svg{ width: 12px; height: 12px; }
.ub-pref.shut{ background: var(--ub-ink); color: #fff; }
/* "Female only" is pink wherever it shows: a soft pink with deep pink text
   (6.3:1), and filled deeper pink with white (6.4:1) when it shuts you out. */
.ub-pref.female{ background: #fde4ef; color: #a3134f; }
.ub-pref.female.shut{ background: #b8165a; color: #fff; }
/* "Free": the poster only wants company. A friendly soft green (5.6:1). */
.ub-pref.free{ background: #e2f5e7; color: #1b6e34; }
.cab-free-tile b{ color: #1b6e34; }
.cab-free-tile em{ font-style: normal; font-size: 13px; color: var(--ub-ink2); }
/* ...and in the "Who can join" control, once chosen. */
#cab-pref:has(button[data-v="female"].on) .ub-seg-thumb{ background: #fde4ef; }
#cab-pref button[data-v="female"].on{ color: #a3134f; }
/* a ride the preference shuts you out of: still listed and openable, faded */
.cab-card.shut .ub-main > b, .cab-card.shut .ub-main > i, .cab-card.shut .ub-side{ opacity: .42; }
.cab-card.shut .ub-veh img{ opacity: .55; }

.ub-g{ display: inline-grid; place-items: center; width: 16px; height: 16px; margin-left: 4px; vertical-align: -3px; color: var(--ub-ink2); }
.ub-g svg{ width: 14px; height: 14px; }
.ub-main b .ub-g{ vertical-align: -2px; }

/* a segmented control inside a form row */
.ub-fld .ub-seg{ flex: 1 1 auto; margin: 0 0 0 auto; background: #e3e3e8; }
.cab-me-row .ub-seg{ flex: 0 1 200px; }
.cab-wide-seg .ub-seg{ margin: 0 -8px; }
.ub-h + .ub-seg{ margin-top: 0; }
.cab-form .ub-h{ margin-top: 24px; }

/* asking for your gender: one tap, in a small sheet */
.ub-ask{ position: fixed; inset: 0; z-index: 900; }
.ub-ask-scrim{ position: absolute; inset: 0; background: #000; opacity: 0; transition: opacity .4s ease; }
.ub-ask.on .ub-ask-scrim{ opacity: .4; }
.ub-ask-sheet{
  position: absolute; left: 0; right: 0; bottom: 0; max-width: 520px; margin: 0 auto;
  padding: 8px 16px calc(16px + env(safe-area-inset-bottom)); background: #fff; border-radius: 16px 16px 0 0;
  transform: translateY(105%); transition: transform .5s var(--ub-ease);
}
.ub-ask.on .ub-ask-sheet{ transform: none; }
.ub-ask-sheet h2{ margin: 8px 0 0; font-size: 20px; font-weight: 600; letter-spacing: -.015em; }
.ub-ask-sheet > p{ margin: 4px 0 0; font-size: 15px; color: var(--ub-ink2); }
.ub-ask-opts{ display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 20px; }
.ub-ask-opts .ub-btn{ height: 56px; font-size: 17px; }
.ub-ask-opts .ub-g{ margin: 0; color: inherit; }
.ub-ask-opts .ub-g svg{ width: 18px; height: 18px; }
.ub-ask-x{ display: block; width: 100%; min-height: 44px; margin-top: 8px; border: none; background: none; font-size: 17px; color: var(--ub-ink2); }

/* ---------- gender, told once ---------- */
.ub-ask-sheet > p.ub-lockline{ margin-top: 8px; font-size: 15px; font-weight: 600; color: var(--ub-alert-ink); }
.ub-ask-opts .ub-btn.on{ background: #000; color: #fff; }
.ub-ask-opts .ub-btn.on .ub-g{ color: #fff; }
.ub-ask-sheet .ub-ask-ok{ margin-top: 16px; }
.cab-me-row .ub-v{ flex: 1; }
.ub-textlink{
  flex: none; min-height: 44px; padding: 0; border: none; background: none;
  font-size: 15px; font-weight: 600; color: var(--ub-ink); text-decoration: underline; text-underline-offset: 3px;
}
.ub-textlink:disabled{ color: var(--ub-ink3); text-decoration: none; opacity: 1; }

/* ---------- reporting a person ---------- */
/* a quiet 44px control beside a person or in a chat's header */
.ub-quietbtn{
  flex: none; display: grid; place-items: center; width: 44px; height: 44px; margin-right: -10px;
  border: none; background: none; padding: 0; color: var(--ub-ink3);
}
.ub-quietbtn svg{ width: 18px; height: 18px; }
.ub-ask-sheet{ max-height: 92vh; overflow-y: auto; overscroll-behavior: contain; }
.ub-ask-sheet .ub-group{ margin-top: 12px; }
.ub-ask-sheet .ub-cta{ margin-top: 16px; }
.ub-opts{ margin-top: 16px; border-radius: 12px; background: var(--ub-soft); padding: 0 16px; }
.ub-opt{
  --ub-press: .985;
  display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; min-height: 52px;
  border: none; background: none; padding: 0; text-align: left; font-size: 17px; color: var(--ub-ink);
  box-shadow: 0 1px 0 var(--ub-page);
}
.ub-opt:last-child{ box-shadow: none; }
.ub-opt svg{ width: 18px; height: 18px; flex: none; opacity: 0; transform: scale(.6); transition: opacity .2s, transform .35s var(--ub-spring); }
.ub-opt.on{ font-weight: 600; }
.ub-opt.on svg{ opacity: 1; transform: none; }

.cab-chat-head{
  display: flex; align-items: center; justify-content: space-between; min-height: 44px; padding: 0 16px;
  border-bottom: 1px solid var(--ub-page); font-size: 13px; font-weight: 600; color: var(--ub-ink2);
}
.ub-card .cab-chat-head, .ub-list .cab-chat-head{ border-bottom-color: var(--ub-soft); }
.cab-chat-head .ub-quietbtn{ margin-right: -12px; }
.ub-btn.armed{ background: var(--ub-alert); color: #fff; }
.cab-blocked{ margin: 0 0 12px; }
.cab-blocked[hidden]{ display: none; }

/* ---------- cab reports (administrators) ---------- */
.cab-rep{ margin-top: 12px; }
.cab-rep-top{ display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.cab-rep-top time{ font-size: 13px; color: var(--ub-ink2); white-space: nowrap; }
.cab-rep-top .ub-pref{ background: var(--ub-page); height: 26px; font-size: 13px; }
.cab-rep-who{ display: flex; gap: 12px; margin-top: 12px; }
.cab-rep-k{ flex: none; width: 64px; padding-top: 2px; font-size: 13px; font-weight: 600; color: var(--ub-ink2); }
.cab-rep-who .ub-main b{ white-space: normal; }
.cab-rep-who .ub-main i{ user-select: text; }
.cab-rep-ride{ display: flex; align-items: center; gap: 8px; margin-top: 12px; font-size: 14px; color: var(--ub-ink2); }
.cab-rep-note{ margin: 12px 0 0; font-size: 15px; line-height: 1.45; overflow-wrap: anywhere; }
.cab-rep-chat{ margin-top: 12px; }
.cab-rep-chat summary{ background: var(--ub-page); }
.cab-rep-msgs{ max-height: 260px; overflow-y: auto; padding: 4px 4px 0; }
.cab-rep-msgs p{ margin: 8px 0 0; font-size: 14px; line-height: 1.4; overflow-wrap: anywhere; }
.cab-rep-msgs p b{ margin-right: 6px; }
.cab-rep-msgs p.them b{ color: var(--ub-alert-ink); }
.cab-rep-msgs time{ display: block; font-size: 12px; color: var(--ub-ink3); }
.cab-rep-acts{ display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 8px; margin-top: 16px; }
.cab-rep-acts .ub-st{ margin-right: auto; }

/* ---------- wider screens ---------- */
@media (min-width: 720px){
  .ub-mapwrap{ margin: 0; }
  .ub-map{ border-radius: 12px; overflow: hidden; }
  #view-cab > #cab-body > .ub-sheet{ margin: 16px 0 0; border-radius: 12px; box-shadow: none; padding-left: 0; padding-right: 0; }
  #view-cab .ub-handle{ display: none; }
  .ub-bar.fixed{ position: sticky; bottom: 24px; max-width: 400px; margin: -96px auto 0; padding: 0; background: none; }
  .page.uber .page-body > .ub-screen{ max-width: 640px; margin: 0 auto; }
  .page.uber .page-body > .ub-screen.cab-ride{ max-width: none; }
  .cab-ride .ub-sheet{ width: 100%; max-width: 640px; margin-left: auto; margin-right: auto; }
  .cab-ride > .ub-bar{ width: 100%; max-width: 640px; margin: 0 auto; }
}

@media (prefers-reduced-motion: reduce){
  #view-cab, #view-cab *, #view-campus, #view-campus *, .page.uber, .page.uber *{
    animation: none !important; transition: none !important;
  }
}

/* ---------- rows answer a press the iOS way ----------
   A row in a list fills with the system pressed grey the instant it is touched
   and fades back on release; no dimming, no shrinking. */
.ub-rows > .ub-row, .ub-rows > * > .ub-row{ isolation: isolate; }
.ub-rows > .ub-row::before, .ub-rows > * > .ub-row::before{
  content: ""; position: absolute; top: 2px; bottom: 2px; left: -8px; right: -8px; z-index: -1; border-radius: 12px;
  background: #e5e5ea; opacity: 0; transition: opacity .3s ease;
}
:is(#view-cab, #view-campus, .page.uber) .ub-rows .ub-row:not(:disabled):active{ opacity: 1; transform: none; }
.ub-rows > .ub-row:active::before, .ub-rows > * > .ub-row:active::before{ opacity: 1; transition: none; }
@media (prefers-reduced-motion: reduce){ .ub-rows > .ub-row::before, .ub-rows > * > .ub-row::before{ transition: none; } }

/* ---------- search, the iOS way ---------- */
.ub-search{ display: flex; align-items: center; margin-top: 16px; }
.ub-search .ub-where.sm{ flex: 1; min-width: 0; margin: 0; height: 36px; padding: 0 4px 0 8px; gap: 6px; border-radius: 10px; background: rgba(118,118,128,.12); }
.ub-search .ub-where.sm:focus-within{ background: rgba(118,118,128,.12); box-shadow: none; }
.ub-search .ub-where > svg{ width: 18px; height: 18px; color: rgba(60,60,67,.6); }
.ub-search .ub-where input{ font-size: 17px; }
.ub-search .ub-where input::placeholder{ color: rgba(60,60,67,.6); }
.ub-search-x{ flex: none; display: grid; place-items: center; width: 36px; height: 36px; margin: 0 -4px 0 0; padding: 0; border: none; background: none; color: rgba(60,60,67,.3); }
.ub-search-x svg{ width: 17px; height: 17px; }
.ub-search-x[hidden]{ display: none; }
.ub-search-cancel{
  flex: none; max-width: 0; min-height: 44px; margin-left: 0; padding: 0; overflow: hidden; border: none; background: none;
  font-size: 17px; color: var(--ub-ink); white-space: nowrap; opacity: 0;
  transition: max-width .3s var(--ub-ease), margin-left .3s var(--ub-ease), opacity .2s ease;
}
.ub-search.on .ub-search-cancel{ max-width: 80px; margin-left: 12px; opacity: 1; }
.ub-search .ub-where:has(input:focus-visible){ box-shadow: inset 0 0 0 2px var(--ub-ink); }
@media (prefers-reduced-motion: reduce){ .ub-search-cancel{ transition: none; } }

/* ---------- skeletons shaped like the rows they stand for ---------- */
.ub-skel.plain{ min-height: 44px; padding: 0; }
.ub-skel.plain b{ height: 14px; width: 55%; }
.ub-skel.item i{ width: 28px; height: 28px; border-radius: 6px; }
.ub-skel.plain span b, .ub-skel.item span b{ animation: ub-breathe 1.6s ease-in-out infinite; }

/* ---------- grouped lists, the iOS Settings look ----------
   A screen marked .ub-grouped sits on the grouped grey; its lists are white
   rounded sections with hairlines inset to the text and none after the last
   row. Used by Resources. */
.page.uber:has(.ub-grouped){ background: #f2f2f7; }
.page.uber:has(.ub-grouped).scrolled .page-head{ background: rgba(242,242,247,.86); }
.ub-grouped{ --ub-screen-bg: #f2f2f7; }
.ub-ghost:has(> .ub-grouped){ background: #f2f2f7; }
.ub-grouped .ub-rows{ margin-top: 8px; padding: 0; background: #fff; border-radius: 10px; overflow: hidden; }
.ub-grouped .ub-rows > .ub-row::before, .ub-grouped .ub-rows > * > .ub-row::before{ top: 0; bottom: 0; left: 0; right: 0; border-radius: 0; }

.ub-grouped .ub-row.cp-plain{ min-height: 44px; padding: 11px 16px; gap: 8px; }
.ub-grouped .ub-row.cp-plain .ub-main b{ font-size: 17px; line-height: 22px; }
.ub-grouped .ub-chev{ width: 14px; height: 14px; color: rgba(60,60,67,.3); }
.ub-grouped .ub-chev svg{ width: 14px; height: 14px; stroke-width: 2.6; }
.ub-grouped .cp-count{ font-size: 17px; color: rgba(60,60,67,.6); }
.ub-grouped .ub-h{ margin: 24px 16px 6px; font-size: 13px; font-weight: 400; letter-spacing: .01em; text-transform: uppercase; color: rgba(60,60,67,.6); }
.ub-grouped .ub-skel-rows{ background: #fff; }
.ub-grouped .ub-skel.plain, .ub-grouped .ub-skel.item{ padding: 0 16px; }
.ub-grouped .ub-skel.item{ min-height: 60px; }
.ub-grouped .ub-skel i, .ub-grouped .ub-skel b{ background: #ececf0; }
.ub-grouped .ub-seg{ background: rgba(118,118,128,.12); }
.ub-grouped .ub-empty{ padding: 56px 24px 24px; }
.ub-grouped .ub-empty b{ color: rgba(60,60,67,.6); font-weight: 400; }
.ub-grouped .ub-empty-ico{ color: rgba(60,60,67,.3); }
.ub-grouped .ub-empty .ub-btn{ background: #fff; }
.ub-grouped .ub-group{ background: #fff; border-radius: 10px; }
.ub-grouped .ub-title.sm{ margin-top: 4px; }
.ub-grouped .ub-sub{ color: rgba(60,60,67,.6); }
.ub-grouped .ub-bar{ background: linear-gradient(to top, #f2f2f7 78%, rgba(242,242,247,0)); }
/* Fields in a grouped form: hairlines between them, as in iOS Settings. */
.ub-grouped .ub-group .ub-fld{ box-shadow: none; }
.ub-search:not(.on) .ub-search-cancel{ visibility: hidden; transition: max-width .3s var(--ub-ease), margin-left .3s var(--ub-ease), opacity .2s ease, visibility 0s .3s; }

/* No cut-off names: a ride's destination and the "from" place wrap to two
   lines instead of ending in an ellipsis. */
.cab-card .ub-main b{ white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.cab-form #cab-from-text{ white-space: normal; overflow-wrap: anywhere; line-height: 1.3; padding: 12px 0; }
.cab-card .ub-main > i{ white-space: normal; overflow: visible; text-overflow: clip; line-height: 1.35; }

/* ---------- no separator lines ----------
   Rows in a list are set apart by spacing alone, and answer a press with a
   rounded fill; no hairlines between them anywhere in Cabs or Campus. */
.ub-rows > .ub-row::after, .ub-rows > * > .ub-row::after{ display: none; }
.ub-rows > .ub-row + .ub-row, .ub-rows > * + *{ margin-top: 2px; }
.ub-nowrap{ white-space: nowrap; }

/* Pictures for empty and problem screens (assets/art-*.webp). */
.ub-art{ display: block; width: 120px; height: 120px; margin-bottom: 4px; object-fit: contain; }
.ub-empty.small .ub-art{ width: 88px; height: 88px; }
.ub-ask-sheet > .ub-art{ width: 104px; height: 104px; margin: 4px auto 0; }
.cab-blocked .ub-art{ flex: none; width: 36px; height: 36px; margin: 0; }
.gate-art{ display: block; width: 96px; height: 96px; object-fit: contain; }

/* Place suggestions: a panel that drops from the search box and floats over
   what is below it, instead of pushing the list down. */
.cab-search{ position: relative; }
.cab-drop:empty{ display: none; }
.cab-drop{ position: absolute; left: 0; right: 0; top: calc(100% + 6px); z-index: 40; max-height: min(52vh, 380px); overflow-y: auto; overscroll-behavior: contain;
  padding: 6px; background: #fff; border-radius: 14px; box-shadow: 0 12px 32px rgba(0,0,0,.18), 0 0 0 1px rgba(0,0,0,.06); animation: cab-drop .16s var(--ub-out, ease-out) both; }
/* Typing in "From": the panel hangs from that box, over "Where to?". */
.cab-drop[data-for="from"]{ top: 50px; }
@keyframes cab-drop{ from{ opacity: 0; transform: translateY(-4px); } }
@media (prefers-reduced-motion: reduce){ .cab-drop{ animation: none; } }
.cab-drop .ub-rows{ display: block; margin: 0; background: none; border-radius: 0; }
.cab-drop{ overflow-x: hidden; }
.cab-drop .ub-row{ box-sizing: border-box; width: 100%; min-height: 56px; margin: 0; padding: 8px 10px; gap: 12px; background: none; border-radius: 10px; box-shadow: none; }
.cab-drop .ub-row:hover, .cab-drop .ub-row:active{ background: var(--ub-soft); }
.cab-drop .ub-ico{ flex: none; width: 36px; height: 36px; border-radius: 50%; background: var(--ub-soft); color: #000; }
.cab-drop .ub-ico svg{ width: 18px; height: 18px; }
.cab-drop .ub-main b{ font-size: 16px; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cab-drop .ub-main i{ font-size: 13px; color: var(--ub-ink2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cab-drop .ub-muted{ margin: 0; padding: 14px 12px; }
.cab-drop .ub-loading{ padding: 18px 0; }

/* Tabs held back for administrators (see syncLabs in app.js). */
.tab-btn[hidden]{ display: none !important; }

/* How far a suggested place is, at the right of its row. */
.cab-hit-km{ flex: none; margin-left: 8px; font-size: 13px; font-variant-numeric: tabular-nums; color: var(--ub-ink2); white-space: nowrap; }

/* Offer a ride: both ends above one map. */
.cab-duo .ub-where{ height: 48px; }
.cab-duo .cab-from-box{ margin-bottom: 8px; padding-left: 20px; gap: 14px; }
.cab-duo .cab-to-box{ padding-left: 20px; gap: 14px; }
.cab-duo .cab-from-box input{ font-size: 17px; }
.cab-to-dot{ flex: none; width: 8px; height: 8px; background: var(--ub-alert, #ff3b30); }
.cab-duo .cab-drop[data-for="from"]{ top: 54px; }
.cab-duo .cab-pick-map{ height: 240px; }
.cab-duo-tip{ margin: 8px 2px 0; font-size: 13px; }

/* the locate buttons light up while they are following you */
#cab-gps.on{ color: #1a73e8; }
.cab-follow{
  position: absolute; right: 12px; bottom: 12px; z-index: 500; width: 40px; height: 40px; padding: 0;
  display: grid; place-items: center; border: none; border-radius: 50%; cursor: pointer;
  background: #fff; color: #000; box-shadow: 0 2px 10px rgba(0,0,0,.25); font-size: 20px;
  transition: transform .15s ease;
}
.cab-follow:active{ transform: scale(.92); }
.cab-follow.on{ color: #1a73e8; }
.cab-follow svg{ width: 21px; height: 21px; }

.cab-share{ width: 100%; margin-top: 12px; }

/* The teardrop pin for a place to go to, as on any maps app: red, green once
   you are in that ride. Its tip sits on the spot. */
.cab-drop-pin{ display: block; width: 100%; height: 100%; filter: drop-shadow(0 2px 3px rgba(0,0,0,.35)); }
.cab-drop-pin svg{ display: block; width: 100%; height: 100%; overflow: visible; }
.cab-drop-pin .body{ fill: #ea4335; stroke: #b31412; stroke-width: 1; }
.cab-drop-pin .hole{ fill: #b31412; }
.cab-drop-pin.ok .body{ fill: #34a853; stroke: #1e8e3e; }
.cab-drop-pin.ok .hole{ fill: #1e8e3e; }

/* How far it is by road, over the Cabs map once a destination is chosen. */
.cab-route-chip{ position: absolute; left: 50%; bottom: 34px; z-index: 500; transform: translateX(-50%); padding: 7px 14px; border-radius: 18px; background: #fff; box-shadow: 0 1px 2px rgba(60,64,67,.3), 0 2px 6px 2px rgba(60,64,67,.15); font-size: 13px; font-weight: 600; color: #1558d6; white-space: nowrap; pointer-events: none; }
.cab-route-chip[hidden]{ display: none; }

/* Home is the My Batch page; Timetable and Discussion open from its blocks.
   Their old buttons stay in the bar out of sight (the app still looks them up). */
.tab-btn.in-home{ display: none !important; }
/* The card's blocks in two rows of two: what is inside Home, then elsewhere. */
.quick-actions.rows{ grid-template-columns: repeat(2, 1fr); }

/* Home's buttons to the rest of the app: Share Cab, Market, Resources. */
/* Its title, in Reddit Sans (loaded with the other fonts in index.html). */
.home-cta-title{ margin: 18px 2px 0; font-family: "Reddit Sans", var(--font-ui, system-ui), sans-serif; font-size: 20px; font-weight: 600; letter-spacing: -0.01em; color: var(--ink); }
.home-cta{ display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; margin: 10px 0 12px; }
/* No box: just the picture and its name. */
.home-cta button{ display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 8px 4px; border: none; border-radius: 12px; background: none; font: inherit; color: var(--ink, #111); cursor: pointer; }
.home-cta button:active{ background: var(--panel, #f4f4f6); }
.home-cta img{ display: block; width: 56px; height: 56px; object-fit: contain; }
.home-cta b{ font-size: 12.5px; font-weight: 600; text-align: center; line-height: 1.2; }

/* "New", the way a shop marks a new product: a small tilted tag beside each of
   Home's three pictures and on the two new tabs. Take the is-new
   class off in index.html when they are no longer new. */
.home-cta.is-new button{ position: relative; }
.home-cta.is-new button::before{
  content: "NEW"; position: absolute; top: 2px; left: 50%; margin-left: 12px; padding: 1px 5px; border-radius: 4px;
  transform: rotate(12deg); background: #e53935; color: #fff;
  font-size: 9px; font-weight: 800; letter-spacing: .06em; line-height: 1.5; pointer-events: none;
}
.tab-btn.is-new{ position: relative; }
.tab-btn.is-new::after{
  content: "NEW"; position: absolute; top: -7px; left: 50%; margin-left: 6px; padding: 1px 4px; border-radius: 4px;
  transform: rotate(12deg); background: #e53935; color: #fff;
  font-size: 7.5px; font-weight: 800; letter-spacing: .06em; line-height: 1.4; pointer-events: none;
}

/* "Student-led" at the very bottom of the profile sheet: small and grey. */
.sheet-led{ font-size: 10.5px; color: #9a9aa2; text-align: center; margin: 16px 0 2px; letter-spacing: .01em; }
