/* True Flow Field App — styles
 * Mobile-first. Brand palette from True Flow brand guidelines.
 * Organized: tokens → reset → layout → sync bar → login → app shell → utilities.
 */

/* ── Design tokens ──────────────────────────────────────────────────────── */
:root {
  --tf-ocean:    #1a9fc4;
  --tf-cerulean: #0b4f6c;
  --tf-navy:     #062840;
  --tf-aqua:     #7dd4ea;
  --tf-sand:     #f5ead8;
  --cta-bg:      #c9a96e;
  --cta-text:    #ffffff;
  --bg-page:     #fffdf9;
  --text-primary: #062840;
  --text-muted:   #6b7280;
  --border:       #e5e7eb;
  --danger:       #dc2626;
  --success:      #16a34a;
  --warning:      #d97706;
}

/* ── Reset ──────────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

/* The native [hidden] attribute only sets display:none at user-agent
 * specificity, so any element with its own display rule (e.g. .login-view
 * { display: flex }) stays visible even when hidden=true. The app toggles
 * views via .hidden everywhere, so make the attribute authoritative app-wide.
 * Without this, showApp() hides #login in JS but the login card stays painted
 * on top of the loaded app. */
[hidden] { display: none !important; }

html {
  -webkit-text-size-adjust: 100%;
  font-size: 16px;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--bg-page);
  color: var(--text-primary);
  min-height: 100dvh;
  /* Safe area insets for iOS notch / home indicator */
  padding-top: env(safe-area-inset-top);
  padding-bottom: env(safe-area-inset-bottom);
}

a { color: var(--tf-ocean); text-decoration: none; }
button { cursor: pointer; font-family: inherit; }
input, textarea { font-family: inherit; }

/* ── Sync status bar ────────────────────────────────────────────────────── */
.sync-bar {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 1rem;
  font-size: 0.8rem;
  font-weight: 500;
  background: var(--tf-navy);
  color: #fff;
  min-height: 36px;
}

.sync-bar[hidden] { display: none; }

.sync-icon {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
  background: var(--text-muted);
  transition: background 0.3s;
}
.sync-bar.online  .sync-icon { background: var(--success); }
.sync-bar.offline .sync-icon { background: var(--danger); }
.sync-bar.pending .sync-icon { background: var(--warning); animation: pulse 1.2s infinite; }
.sync-bar.failed  .sync-icon { background: var(--danger); }

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.4; }
}

#sync-text { flex: 1; }

.sync-btn-manual {
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.25);
  border-radius: 4px;
  color: #fff;
  font-size: 0.75rem;
  padding: 0.2rem 0.6rem;
}
.sync-btn-manual[hidden] { display: none; }
.sync-btn-manual:disabled { opacity: 0.5; cursor: not-allowed; }

/* ── Buttons ────────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  border: none;
  border-radius: 8px;
  padding: 0.75rem 1.25rem;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1;
  transition: opacity 0.15s, transform 0.1s;
}
.btn:active { transform: scale(0.97); }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }

.btn-primary {
  background: var(--cta-bg);
  color: var(--cta-text);
}
.btn-primary:hover { opacity: 0.92; }

.btn-secondary {
  background: transparent;
  border: 1.5px solid var(--border);
  color: var(--text-primary);
}

.btn-block { width: 100%; }

.btn-link {
  background: none;
  border: none;
  color: var(--tf-ocean);
  font-size: 0.88rem;
  padding: 0;
  text-decoration: underline;
}

/* ── Login view ─────────────────────────────────────────────────────────── */
.login-view {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100dvh;
  padding: 1.5rem;
  background: var(--tf-navy);
}

.login-card {
  background: #fff;
  border-radius: 16px;
  padding: 2.5rem 1.5rem;
  width: 100%;
  max-width: 400px;
  box-shadow: 0 8px 32px rgba(6,40,64,0.25);
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  margin-bottom: 0.75rem;
}

.brand-wordmark {
  height: 80px;
  width: auto;
  max-width: 220px;
  object-fit: contain;
}
@media (min-width: 600px) {
  .brand-wordmark { height: 100px; max-width: 260px; }
}

.brand-sub {
  font-size: 14px;
  color: var(--text-muted);
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.login-card label {
  font-size: 14px;
  line-height: 1.2;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: -0.5rem;
}

.login-card input {
  width: 100%;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  padding: 0.7rem 0.9rem;
  font-size: 1rem;
  color: var(--text-primary);
  background: #fafafa;
  transition: border-color 0.15s;
}
.login-card input:focus {
  outline: none;
  border-color: var(--tf-ocean);
  background: #fff;
}

.pw-wrap {
  position: relative;
  display: flex;
  align-items: center;
}
.pw-wrap input { padding-right: 2.75rem; }
.pw-eye {
  position: absolute;
  right: 0.6rem;
  background: none;
  border: none;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  padding: 0.25rem;
}
.eye-icon { display: block; }

.login-error {
  font-size: 0.85rem;
  color: var(--danger);
  min-height: 1.2em;
}

.forgot-wrap { text-align: center; }
.forgot-wrap .btn-link { color: var(--cta-bg); }

.forgot-panel {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding-top: 0.5rem;
  border-top: 1px solid var(--border);
}
.forgot-panel[hidden] { display: none; }

.forgot-msg {
  font-size: 0.85rem;
  color: var(--success);
}
.forgot-msg[hidden] { display: none; }

.config-warning {
  font-size: 0.8rem;
  color: var(--warning);
  background: #fffbeb;
  border: 1px solid #fde68a;
  border-radius: 6px;
  padding: 0.6rem 0.8rem;
}
.config-warning[hidden] { display: none; }

/* ── App shell (authenticated views) ────────────────────────────────────── */
#app {
  display: flex;
  flex-direction: column;
  min-height: calc(100dvh - 36px); /* minus sync bar */
}
#app[hidden] { display: none; }

.app-header {
  background: var(--tf-cerulean);
  color: #fff;
  padding: 1rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.app-header h1 {
  font-size: 1.1rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  flex: 1;
}

.app-header .header-actions {
  display: flex;
  gap: 0.5rem;
}

.icon-btn {
  background: rgba(255,255,255,0.12);
  border: none;
  border-radius: 8px;
  color: #fff;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.screen {
  flex: 1;
  padding: 1.25rem;
}
.screen[hidden] { display: none; }

/* ── Loading / spinner ───────────────────────────────────────────────────── */
.loading-overlay {
  display: flex;
  align-items: center;
  justify-content: center;
  height: calc(100dvh - 36px);
  flex-direction: column;
  gap: 1rem;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.spinner {
  width: 32px;
  height: 32px;
  border: 3px solid var(--border);
  border-top-color: var(--tf-ocean);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ── Settings screen (sign out) ─────────────────────────────────────────── */
.settings-section {
  background: #fff;
  border-radius: 12px;
  border: 1px solid var(--border);
  overflow: hidden;
  margin-bottom: 1rem;
}

.settings-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.9rem 1rem;
  border-bottom: 1px solid var(--border);
  font-size: 0.95rem;
}
.settings-row:last-child { border-bottom: none; }

.settings-label { font-weight: 500; }
.settings-value { color: var(--text-muted); font-size: 0.85rem; }

/* Stacked settings row (label + sublabel + control) — P2.4 on-my-way mode */
.settings-row-stack {
  display: block;
}
.settings-sublabel {
  display: block;
  color: var(--text-muted);
  font-size: 0.82rem;
  margin: 0.25rem 0 0.7rem;
  line-height: 1.4;
}
.settings-segmented {
  display: flex;
  gap: 0;
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
}
.seg-btn {
  flex: 1 1 0;
  padding: 0.7rem 0.5rem;
  background: #fff;
  border: none;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
}
.seg-btn + .seg-btn { border-left: 1px solid var(--border); }
.seg-btn[aria-pressed="true"] {
  background: var(--tf-ocean, #1a9fc4);
  color: #fff;
}

/* ── Utilities ───────────────────────────────────────────────────────────── */
.text-muted  { color: var(--text-muted); }
.text-sm     { font-size: 0.875rem; }
.mt-1        { margin-top: 0.5rem; }
.mt-2        { margin-top: 1rem; }

/* ── P1.3 — Schedule screen ─────────────────────────────────────────────── */

/* Stale data warning banner */
.stale-banner {
  background: #fffbeb;
  border: 1px solid #fde68a;
  border-radius: 8px;
  color: #92400e;
  font-size: 0.82rem;
  font-weight: 500;
  padding: 0.6rem 0.9rem;
  margin-bottom: 1rem;
}
.stale-banner[hidden] { display: none; }

/* State views: loading, no-cache, empty */
.schedule-state-view {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 3rem 1.5rem;
  text-align: center;
}
.schedule-state-view[hidden] { display: none; }

.schedule-empty-msg {
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* Last synced timestamp */
.schedule-last-synced {
  font-size: 0.78rem;
  color: var(--text-muted);
  text-align: center;
  padding: 0.75rem 0 0.25rem;
}
.schedule-last-synced[hidden] { display: none; }

/* Appointment card */
.apt-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1rem 1rem 0.85rem;
  margin-bottom: 0.75rem;
  cursor: pointer;
  transition: box-shadow 0.15s, transform 0.1s;
  -webkit-tap-highlight-color: transparent;
}
.apt-card:active {
  transform: scale(0.985);
  box-shadow: 0 1px 4px rgba(6,40,64,0.08);
}

.apt-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.35rem;
}

.apt-block {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--tf-cerulean);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.apt-balance {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--warning);
  background: #fffbeb;
  border: 1px solid #fde68a;
  border-radius: 20px;
  padding: 0.15rem 0.55rem;
}

.apt-customer {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.2rem;
}

.apt-address {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-bottom: 0.2rem;
}

.apt-service {
  font-size: 0.85rem;
  color: var(--tf-ocean);
  font-weight: 500;
  margin-bottom: 0.65rem;
}

.apt-card-actions {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

/* Small button variants for card actions */
.btn-sm {
  padding: 0.45rem 0.9rem;
  font-size: 0.83rem;
  border-radius: 6px;
}

.btn-outline-nav {
  background: transparent;
  border: 1.5px solid var(--tf-ocean);
  color: var(--tf-ocean);
  font-weight: 600;
}
.btn-outline-nav:hover { background: rgba(26,159,196,0.06); }

.btn-ghost {
  background: transparent;
  border: 1.5px solid var(--border);
  color: var(--text-muted);
  font-weight: 500;
}
.btn-ghost:hover { background: var(--tf-sand); }

/* ── P1.3 — Appointment detail screen ──────────────────────────────────── */

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  background: none;
  border: none;
  color: var(--tf-ocean);
  font-size: 0.88rem;
  font-weight: 600;
  padding: 0;
  margin-bottom: 1.25rem;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.detail-hero {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.detail-customer {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1.3;
  flex: 1;
}

.detail-block {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--tf-cerulean);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.detail-section {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 1rem;
}

.detail-section-title {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  padding: 0.65rem 1rem 0;
}

.detail-kv-list { padding-bottom: 0.25rem; }

.detail-kv {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.65rem 1rem;
  border-bottom: 1px solid var(--border);
  font-size: 0.92rem;
}
.detail-kv:last-child { border-bottom: none; }

.detail-key {
  font-weight: 600;
  color: var(--text-primary);
  flex-shrink: 0;
}

.detail-val {
  color: var(--text-muted);
  text-align: right;
  word-break: break-word;
}

.apt-balance-detail {
  color: var(--warning);
  font-weight: 600;
}

.detail-actions {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.btn-outline {
  background: transparent;
  border: 1.5px solid var(--border);
  color: var(--text-muted);
}
.btn-outline:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

/* ── P1.4 — Briefing screen ─────────────────────────────────────────────── */
.briefing-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  padding: 3rem 1rem;
}
.briefing-loading-label {
  color: var(--text-muted);
  font-size: 0.9rem;
}

.briefing-header {
  padding: 1.25rem 1rem 0.75rem;
  border-bottom: 1px solid var(--border);
  margin-bottom: 1rem;
}
.briefing-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--tf-cerulean);
}
.briefing-customer {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-top: 0.2rem;
}
.briefing-ts {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 0.4rem;
}

.briefing-body {
  padding: 0 1rem 1.5rem;
  line-height: 1.65;
  font-size: 1rem;
  color: var(--text-primary);
}
.briefing-body p {
  margin-bottom: 0.9rem;
}
.briefing-body p:last-child {
  margin-bottom: 0;
}

.briefing-regen-btn {
  margin: 0.5rem 1rem 2rem;
  width: calc(100% - 2rem);
  font-size: 0.85rem;
  color: var(--text-muted);
}

.briefing-error {
  padding: 2rem 1rem;
  text-align: center;
}
.briefing-error-msg {
  color: var(--danger);
  font-size: 0.95rem;
  margin-bottom: 1.25rem;
}

/* ── P1.5 — Visit form ───────────────────────────────────────────────────── */
.vf-header {
  margin-bottom: 1.25rem;
}
.vf-title {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--tf-cerulean);
}
.vf-sub {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-top: 0.15rem;
}

#visit-form {
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
}

.vf-field {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.vf-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
}

.vf-input {
  width: 100%;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  padding: 0.7rem 0.9rem;
  font-size: 1rem;
  color: var(--text-primary);
  background: #fff;
}
.vf-input:focus {
  outline: none;
  border-color: var(--tf-ocean);
}
.vf-textarea {
  resize: vertical;
  line-height: 1.5;
}
select.vf-input {
  appearance: none;
  -webkit-appearance: none;
}

/* Chemical readings grid */
.chem-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.6rem;
}
.chem-cell {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}
.chem-cell label {
  font-size: 0.78rem;
  color: var(--text-muted);
  font-weight: 500;
}
.chem-cell input {
  width: 100%;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  padding: 0.6rem 0.7rem;
  font-size: 1rem;
  background: #fff;
}
.chem-cell input:focus { outline: none; border-color: var(--tf-ocean); }

/* Checkbox group */
.vf-check-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.5rem;
}
.vf-check {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 0.7rem;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  font-size: 0.95rem;
  background: #fff;
}
.vf-check input { width: 18px; height: 18px; accent-color: var(--tf-ocean); }

/* Yes/No toggle */
.vf-toggle {
  display: flex;
  gap: 0.5rem;
}
.vf-toggle-btn {
  flex: 1;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  padding: 0.65rem;
  font-size: 0.95rem;
  font-weight: 600;
  background: #fff;
  color: var(--text-muted);
}
.vf-toggle-btn.active {
  background: var(--tf-ocean);
  border-color: var(--tf-ocean);
  color: #fff;
}

/* Issue flag section */
.vf-flag {
  border: 1.5px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
}
.vf-flag.open { border-color: var(--warning); }
.vf-flag-toggle {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.85rem 1rem;
  background: #fff;
  border: none;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--tf-cerulean);
}
.vf-flag-chevron { transition: transform 0.2s; color: var(--text-muted); }
.vf-flag.open .vf-flag-chevron { transform: rotate(180deg); }
.vf-flag-body {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  padding: 0 1rem 1rem;
}

/* Severity toggle */
.vf-sev { display: flex; gap: 0.5rem; }
.vf-sev-btn {
  flex: 1;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  padding: 0.6rem 0.4rem;
  font-size: 0.82rem;
  font-weight: 600;
  text-transform: capitalize;
  background: #fff;
  color: var(--text-muted);
}
.vf-sev-btn.active {
  background: var(--warning);
  border-color: var(--warning);
  color: #fff;
}

/* Photo placeholder (capture deferred) */
.vf-photo-placeholder {
  font-size: 0.82rem;
  color: var(--text-muted);
  font-style: italic;
  padding: 0.7rem;
  border: 1.5px dashed var(--border);
  border-radius: 8px;
  text-align: center;
}
.vf-photo-main { margin: 0.25rem 0; }

/* Toast */
.toast {
  position: fixed;
  left: 50%;
  bottom: calc(1.25rem + env(safe-area-inset-bottom));
  transform: translate(-50%, 1rem);
  z-index: 200;
  max-width: 90%;
  padding: 0.75rem 1.25rem;
  border-radius: 10px;
  background: var(--tf-navy);
  color: #fff;
  font-size: 0.9rem;
  font-weight: 500;
  box-shadow: 0 6px 24px rgba(6,40,64,0.3);
  opacity: 0;
  transition: opacity 0.3s, transform 0.3s;
}
.toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

/* Undo toast (P2.4 on-my-way send) — text + an inline Undo action */
.undo-toast {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding-right: 0.65rem;
}
.undo-toast-btn {
  flex: 0 0 auto;
  background: transparent;
  border: none;
  color: var(--cta-bg, #c9a96e);
  font-weight: 700;
  font-size: 0.9rem;
  padding: 0.35rem 0.6rem;
  border-radius: 8px;
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}
.undo-toast-btn:active { background: rgba(255,255,255,0.12); }

/* On-my-way sent confirmation under the Navigate button (P2.4) */
.ss-omw-status {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin: 0.6rem 0 0;
  font-size: 0.85rem;
  font-weight: 600;
  color: #2e7d52;
}

/* ── P2.1 — Today screen ─────────────────────────────────────────────────── */

/* Avatar button (replaces cog) */
.avatar-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--cta-bg);
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  -webkit-tap-highlight-color: transparent;
}
.avatar-initials {
  font-size: 0.8rem;
  font-weight: 700;
  color: #fff;
  line-height: 1;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  pointer-events: none;
  user-select: none;
}

/* Screen wrapper — no extra padding needed; carousel uses negative margin */
.screen-today { padding-top: 0; }

/* Day carousel */
.day-carousel {
  display: flex;
  align-items: center;
  gap: 0.2rem;
  margin: 0 -1.25rem 1rem;
  background: var(--tf-cerulean);
  padding: 0.6rem 0.25rem;
}
.carousel-chev {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  background: rgba(255,255,255,0.1);
  border: none;
  border-radius: 8px;
  color: rgba(255,255,255,0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.carousel-chev:active { background: rgba(255,255,255,0.22); }
.carousel-strip {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  overflow: hidden;
}
.carousel-day {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.1rem;
  padding: 0.45rem 0.3rem;
  border-radius: 8px;
  cursor: pointer;
  flex: 1;
  min-width: 0;
  -webkit-tap-highlight-color: transparent;
  transition: background 0.15s;
}
.carousel-day-abbr {
  font-size: 0.6rem;
  font-weight: 600;
  color: rgba(255,255,255,0.5);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
}
.carousel-day-num {
  font-size: 1rem;
  font-weight: 600;
  color: rgba(255,255,255,0.65);
  line-height: 1;
}
/* Today pill emphasis */
.carousel-day.today .carousel-day-abbr { color: var(--tf-aqua); font-weight: 700; }
.carousel-day.today .carousel-day-num  { color: #fff; font-weight: 700; font-size: 1.1rem; }
/* Selected state */
.carousel-day.selected { background: rgba(255,255,255,0.16); }
.carousel-day.selected .carousel-day-abbr { color: rgba(255,255,255,0.85); }
.carousel-day.selected .carousel-day-num  { color: #fff; }
.carousel-day.today.selected .carousel-day-abbr { color: var(--tf-aqua); }

/* Morning briefing card */
.briefing-day-card {
  background: var(--tf-cerulean);
  border-radius: 12px;
  padding: 0.9rem 1rem;
  margin-bottom: 1rem;
}
.briefing-day-inner {
  display: flex;
  align-items: center;
  gap: 0.9rem;
}
.briefing-day-text { flex: 1; min-width: 0; }
.briefing-day-tag {
  display: block;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--tf-aqua);
  margin-bottom: 0.3rem;
}
.briefing-day-preview {
  font-size: 0.88rem;
  color: rgba(255,255,255,0.82);
  line-height: 1.45;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.briefing-day-play {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--cta-bg);
  border: none;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: opacity 0.15s, transform 0.1s;
  -webkit-tap-highlight-color: transparent;
}
.briefing-day-play:active { transform: scale(0.9); }
.briefing-day-play.playing { background: var(--tf-ocean); }

/* ── Briefing audio player transport ───────────────────────────────────────── */
.bp-transport-row {
  margin-top: 0.85rem;
  padding-top: 0.75rem;
  border-top: 1px solid rgba(255,255,255,0.12);
}
.bp-progress-bar {
  height: 6px;
  background: rgba(255,255,255,0.18);
  border-radius: 3px;
  overflow: hidden;
  margin-bottom: 0.55rem;
}
.bp-progress-fill {
  height: 100%;
  width: 0%;
  background: var(--cta-bg);
  border-radius: 3px;
  transition: width 0.8s linear;
}
.bp-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.bp-time {
  font-size: 0.72rem;
  font-variant-numeric: tabular-nums;
  color: rgba(255,255,255,0.55);
  letter-spacing: 0.04em;
}
.bp-stop-btn {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  background: rgba(255,255,255,0.12);
  border: none;
  color: rgba(255,255,255,0.75);
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.35rem 0.75rem;
  border-radius: 20px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: background 0.15s;
}
.bp-stop-btn:active { background: rgba(255,255,255,0.22); }

.briefing-future-note {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.5);
  margin-top: 0.65rem;
  font-style: italic;
}

/* Route map thumbnail */
.map-thumb-wrap {
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: 1rem;
  border: 1.5px solid var(--border);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  position: relative;
  transition: opacity 0.15s;
}
.map-thumb-wrap:active { opacity: 0.82; }
.map-thumb-inner { display: block; width: 100%; line-height: 0; }
.map-thumb-inner svg { width: 100%; height: auto; display: block; }
.map-thumb-caption {
  display: block;
  text-align: center;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--tf-cerulean);
  background: rgba(255,255,255,0.92);
  padding: 0.35rem 0.5rem;
}

/* Stop card */
.stop-card {
  background: #fff;
  border: 1.5px solid var(--border);
  border-radius: 14px;
  padding: 1rem 1rem 0.9rem;
  margin-bottom: 0.75rem;
  cursor: pointer;
  transition: box-shadow 0.15s, transform 0.1s;
  -webkit-tap-highlight-color: transparent;
}
.stop-card:active {
  transform: scale(0.985);
  box-shadow: 0 2px 10px rgba(6,40,64,0.1);
}
.stop-card.status-up-next {
  border-color: var(--tf-ocean);
  box-shadow: 0 0 0 1px var(--tf-ocean);
}
.stop-card.status-done,
.stop-card.status-skipped { opacity: 0.55; }

.stop-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.5rem;
  gap: 0.4rem;
}
.stop-customer-row {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex: 1;
  min-width: 0;
}
.stop-customer-name {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--tf-cerulean);
  cursor: pointer;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  -webkit-tap-highlight-color: transparent;
  border-bottom: 1.5px solid transparent;
}
.stop-customer-name:active { opacity: 0.65; }
.stop-contact-icons {
  display: flex;
  gap: 0.3rem;
  flex-shrink: 0;
}
.stop-contact-icon {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1.5px solid var(--border);
  background: #fff;
  color: var(--tf-ocean);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
  flex-shrink: 0;
}
.stop-contact-icon:active { background: var(--tf-sand); }

/* Status pills */
.stop-status-pill {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 0.22rem 0.6rem;
  border-radius: 20px;
  white-space: nowrap;
  flex-shrink: 0;
}
.pill-up-next     { background: var(--tf-ocean);  color: #fff; }
.pill-later       { background: var(--tf-sand);   color: var(--tf-cerulean); }
.pill-on-the-way  { background: var(--cta-bg);    color: #fff; }
.pill-in-progress { background: var(--success);   color: #fff; }
.pill-done        { background: var(--border);    color: var(--text-muted); }
.pill-skipped     { background: var(--border);    color: var(--text-muted); }

.stop-address {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 0.25rem;
}
.stop-access {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--tf-cerulean);
  background: rgba(26,159,196,0.09);
  border-radius: 6px;
  padding: 0.2rem 0.5rem;
  margin-bottom: 0.3rem;
}
.stop-service {
  font-size: 0.85rem;
  color: var(--tf-ocean);
  font-weight: 500;
  margin-bottom: 0.1rem;
}
.stop-flag-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--warning);
  background: #fffbeb;
  border: 1px solid #fde68a;
  border-radius: 6px;
  padding: 0.2rem 0.5rem;
  margin-top: 0.35rem;
}
.stop-flags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0.35rem;
}
.stop-flags .stop-flag-badge { margin-top: 0; }

/* Stop-list header + manual reorder */
.today-list-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin: 0.25rem 0 0.6rem;
}
.today-order-label {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--text-muted);
  text-transform: uppercase;
}
.today-order-actions { display: flex; gap: 0.4rem; }
.today-order-btn {
  background: none;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  padding: 0.35rem 0.7rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--tf-ocean);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.today-order-btn.active {
  background: var(--tf-ocean);
  border-color: var(--tf-ocean);
  color: #fff;
}

/* Reorder mode: nudge cards, show up/down controls */
#today-stop-list.reordering .stop-card { padding-right: 3.2rem; position: relative; }
.reorder-controls {
  position: absolute;
  top: 50%;
  right: 0.6rem;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}
.reorder-controls button {
  width: 34px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--tf-sand);
  border: 1px solid var(--border);
  border-radius: 7px;
  color: var(--tf-cerulean);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.reorder-controls button:active { background: var(--tf-aqua); }

/* Done / Skipped collapsible group */
.done-group { margin-bottom: 1.5rem; }
.done-group-toggle {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: none;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0.7rem 1rem;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.done-chev { transition: transform 0.2s; color: var(--text-muted); }
.done-group-toggle[aria-expanded="true"] .done-chev { transform: rotate(180deg); }
.done-group-list { padding-top: 0.5rem; }

/* Contact action sheet */
.contact-sheet {
  position: fixed;
  inset: 0;
  z-index: 300;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}
.contact-sheet-bg {
  position: absolute;
  inset: 0;
  background: rgba(6,40,64,0.5);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  cursor: pointer;
}
.contact-sheet-card {
  position: relative;
  background: #fff;
  border-radius: 20px 20px 0 0;
  padding: 1.25rem 1.25rem calc(1.5rem + env(safe-area-inset-bottom));
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}
.contact-sheet-name {
  font-size: 1rem;
  font-weight: 700;
  color: var(--tf-cerulean);
  text-align: center;
  margin-bottom: 0.1rem;
}
.contact-call-btn,
.contact-text-btn,
.contact-cancel-btn {
  width: 100%;
  border-radius: 12px;
  padding: 0.95rem 1rem;
  font-size: 1rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  text-decoration: none;
  cursor: pointer;
  border: none;
  font-family: inherit;
  -webkit-tap-highlight-color: transparent;
  transition: opacity 0.15s, transform 0.1s;
}
.contact-call-btn:active,
.contact-text-btn:active,
.contact-cancel-btn:active { transform: scale(0.97); }
.contact-call-btn   { background: var(--tf-cerulean); color: #fff; }
.contact-text-btn   { background: var(--tf-sand);    color: var(--tf-cerulean); }
.contact-cancel-btn { background: transparent; border: 1.5px solid var(--border); color: var(--text-muted); }

/* ── P2.7 — Visit summary approve/edit sheet ────────────────────────────── */
.summary-sheet-card { gap: 0.55rem; }
.summary-sheet-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--tf-cerulean);
  text-align: center;
  margin: 0.1rem 0 0;
  font-family: 'Playfair Display', Georgia, serif;
}
.summary-sheet-sub {
  font-size: 0.85rem;
  color: var(--text-muted);
  text-align: center;
  margin: 0 0 0.35rem;
}
.summary-sheet-textarea {
  width: 100%;
  border: 1.5px solid var(--border);
  border-radius: 12px;
  padding: 0.85rem 0.95rem;
  font-size: 1rem;
  line-height: 1.55;
  font-family: inherit;
  color: var(--tf-cerulean);
  background: var(--tf-sand);
  resize: vertical;
  min-height: 7.5rem;
  -webkit-appearance: none;
}
.summary-sheet-textarea:focus {
  outline: none;
  border-color: var(--tf-ocean);
  background: #fff;
}
.summary-sheet-channels {
  font-size: 0.8rem;
  color: var(--text-muted);
  text-align: center;
  margin: 0 0 0.2rem;
  min-height: 1rem;
}
#summary-approve-btn { background: var(--cta-bg, #c9a96e); color: #fff; }
#summary-approve-btn:disabled { opacity: 0.55; }

/* ── P2.1b — Customer view ──────────────────────────────────────────────── */
.customer-view-content {
  padding: 1rem 1rem 3rem;
}

.cv-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  padding: 3rem 1rem;
}

.cv-offline-msg {
  padding: 2rem 0;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.95rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

/* Hero */
.cv-hero {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 1.1rem;
}
.cv-hero-main { flex: 1; min-width: 0; }
.cv-customer-name {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--tf-cerulean);
  line-height: 1.15;
  margin-bottom: 0.2rem;
}
.cv-owner-label {
  font-size: 0.82rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* Review state badge */
.cv-review-badge {
  flex-shrink: 0;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 0.22rem 0.65rem;
  border-radius: 20px;
  white-space: nowrap;
  margin-top: 0.35rem;
}
.cv-review-reviewed  { background: #dcfce7; color: #15803d; }
.cv-review-opted-out { background: #f3f4f6; color: var(--text-muted); }

/* Contact row */
.cv-contact-row {
  display: flex;
  gap: 0.65rem;
  margin-bottom: 1.25rem;
}
.cv-contact-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  padding: 0.85rem 1rem;
  border-radius: 12px;
  font-size: 1rem;
  font-weight: 600;
  font-family: inherit;
  text-decoration: none;
  cursor: pointer;
  border: none;
  -webkit-tap-highlight-color: transparent;
  transition: opacity 0.15s, transform 0.1s;
}
.cv-contact-btn:active { transform: scale(0.96); opacity: 0.85; }
.cv-call { background: var(--tf-cerulean); color: #fff; }
.cv-text { background: var(--tf-sand);    color: var(--tf-cerulean); }

/* Sections */
.cv-section {
  background: #fff;
  border: 1.5px solid var(--border);
  border-radius: 14px;
  padding: 1rem;
  margin-bottom: 0.85rem;
}
.cv-section-title {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.65rem;
}

.cv-address-link {
  display: block;
  font-size: 0.95rem;
  color: var(--tf-ocean);
  text-decoration: underline;
  font-weight: 500;
  margin-bottom: 0.4rem;
}
.cv-access-note {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--tf-cerulean);
  background: rgba(26,159,196,0.09);
  border-radius: 6px;
  padding: 0.2rem 0.5rem;
  margin-top: 0.2rem;
}

.cv-equip-row {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  padding: 0.55rem 0;
  border-bottom: 1px solid var(--border);
}
.cv-equip-row:last-child { border-bottom: none; padding-bottom: 0; }
.cv-equip-row:first-child { padding-top: 0; }
.cv-equip-name {
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--tf-cerulean);
}
.cv-equip-meta {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.cv-history-row {
  padding: 0.55rem 0;
  border-bottom: 1px solid var(--border);
}
.cv-history-row:last-child { border-bottom: none; padding-bottom: 0; }
.cv-history-row:first-child { padding-top: 0; }
.cv-history-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.15rem;
}
.cv-history-date {
  font-size: 0.8rem;
  color: var(--text-muted);
  white-space: nowrap;
}
.cv-history-slug {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--tf-ocean);
  text-align: right;
  text-transform: capitalize;
}
.cv-history-note {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.4;
}

.cv-balance {
  font-size: 1rem;
  font-weight: 700;
  color: var(--warning, #d97706);
}

.cv-empty-note {
  font-size: 0.88rem;
  color: var(--text-muted);
  font-style: italic;
}

/* "View profile" link on stop cards */
.stop-view-profile {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--tf-ocean);
  text-decoration: none;
  margin-top: 0.45rem;
  padding: 0.2rem 0;
  -webkit-tap-highlight-color: transparent;
}
.stop-view-profile:active { opacity: 0.6; }

/* ═══════════════════════════════════════════════════════════════════════════
   Stop screen (P2.3) — everything for one pool, one visit
   ═══════════════════════════════════════════════════════════════════════════ */

.screen-stop {
  display: flex;
  flex-direction: column;
  height: 100%;
  overflow: hidden;
  padding-bottom: 0; /* action bar handles its own padding */
}

.stop-screen-content {
  display: flex;
  flex-direction: column;
  height: 100%;
}

/* Scroll area — everything except the pinned action bar */
.ss-scroll-area {
  flex: 1;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 0 0 1rem;
  /* Leave room for pinned action bar + safe area */
  padding-bottom: calc(5rem + env(safe-area-inset-bottom));
}

/* Loading skeleton inside stop screen */
.ss-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 3rem 1rem;
}

/* ── Sections ─────────────────────────────────────────────────────────── */
.ss-section {
  margin: 0 0.9rem 0.6rem;
  background: #fff;
  border-radius: 12px;
  border: 1px solid var(--border);
  overflow: hidden;
}

.ss-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1rem 0.6rem;
  border-bottom: 1px solid var(--border);
}

.ss-section-title {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.ss-collapse-btn {
  background: none;
  border: none;
  padding: 0.25rem;
  cursor: pointer;
  color: var(--text-muted);
  line-height: 0;
  -webkit-tap-highlight-color: transparent;
  transition: transform 0.2s ease;
}
.ss-collapse-btn[aria-expanded="true"] svg {
  transform: rotate(0deg);
}
.ss-collapse-btn[aria-expanded="false"] svg {
  transform: rotate(180deg);
}
.ss-collapse-btn:active { opacity: 0.55; }

/* ── Section A — Heading + access ────────────────────────────────────── */
.ss-section-a {
  margin-top: 0.6rem;
  padding: 1rem 1rem 0.9rem;
  border-radius: 12px;
}

.ss-customer-row {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  margin-bottom: 0.5rem;
}

.ss-customer-name {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: none;
  border: none;
  padding: 0;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--tf-cerulean);
  cursor: pointer;
  text-align: left;
  line-height: 1.25;
  -webkit-tap-highlight-color: transparent;
}
.ss-customer-name:active { opacity: 0.65; }
.ss-contact-chevron {
  color: var(--tf-ocean);
  flex-shrink: 0;
}

.ss-owner-label {
  font-size: 0.82rem;
  color: var(--text-muted);
}

.ss-address {
  display: flex;
  align-items: flex-start;
  gap: 0.35rem;
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.4;
  margin-bottom: 0.45rem;
}
.ss-address svg { flex-shrink: 0; margin-top: 0.18rem; }

.ss-access-note {
  display: flex;
  align-items: flex-start;
  gap: 0.4rem;
  background: #fef3c7;
  border: 1px solid #fde68a;
  border-radius: 8px;
  padding: 0.55rem 0.75rem;
  font-size: 0.88rem;
  font-weight: 600;
  color: #92400e;
  line-height: 1.4;
  margin-bottom: 0.5rem;
}
.ss-access-note svg { flex-shrink: 0; margin-top: 0.15rem; color: #b45309; }

.ss-service-tag {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 600;
  background: var(--tf-aqua);
  color: var(--tf-cerulean);
  border-radius: 20px;
  padding: 0.2rem 0.7rem;
}

/* ── Section B — Briefing ─────────────────────────────────────────────── */
.ss-briefing-body {
  padding: 0.75rem 1rem 0.9rem;
}

.ss-briefing-player-wrap {
  margin-bottom: 0.75rem;
}

.ss-briefing-play {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--tf-ocean);
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 0.55rem 1rem;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.ss-briefing-play:active { opacity: 0.82; }
.ss-briefing-play svg { flex-shrink: 0; }

.ss-risk-flags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 0.7rem;
}

.ss-risk-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  background: #fef3c7;
  border: 1px solid #fde68a;
  border-radius: 20px;
  padding: 0.22rem 0.65rem;
  font-size: 0.78rem;
  font-weight: 600;
  color: #92400e;
}
.ss-risk-badge svg { color: #b45309; flex-shrink: 0; }

.ss-briefing-text {
  font-size: 0.9rem;
  line-height: 1.6;
  color: var(--text-primary);
  white-space: pre-wrap;
}

.ss-briefing-empty {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-style: italic;
}

/* ── Section C — Navigate ─────────────────────────────────────────────── */
.ss-section-c {
  padding: 0.9rem 1rem;
  border-radius: 12px;
}

.ss-navigate-btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background: var(--tf-cerulean);
  color: #fff;
  border: none;
  border-radius: 10px;
  padding: 0.85rem;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.ss-navigate-btn:active { opacity: 0.84; }

/* ── Section D — Work area ────────────────────────────────────────────── */
.ss-section-d {
  border-radius: 12px;
}
.ss-section-d .ss-section-header {
  border-bottom: none;
}

.ss-start-visit-btn {
  display: block;
  width: calc(100% - 2rem);
  margin: 0 1rem 0.5rem;
  padding: 1rem;
  font-size: 1.05rem;
  font-weight: 700;
  background: var(--cta-bg);
  color: var(--cta-text);
  border: none;
  border-radius: 10px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.ss-start-visit-btn:active { opacity: 0.84; }

.ss-guided-hint {
  font-size: 0.82rem;
  color: var(--text-muted);
  text-align: center;
  padding: 0 1rem 0.9rem;
}

.ss-guided-active {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--success);
  padding: 0.5rem 1rem 0;
}

.ss-guided-hook-note {
  font-size: 0.82rem;
  color: var(--text-muted);
  font-style: italic;
  padding: 0.4rem 1rem 1rem;
}

#ss-guided-container { padding-bottom: 0.25rem; }

.ss-chem-placeholder {
  margin: 0.5rem 1rem 0.9rem;
  background: var(--tf-sand);
  border-radius: 10px;
  padding: 0.8rem 1rem;
  border: 1px dashed var(--border);
}
.ss-placeholder-label {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin-bottom: 0.2rem;
}
.ss-placeholder-hint {
  font-size: 0.83rem;
  color: var(--text-muted);
  font-style: italic;
}

/* ── Section E — Equipment issue ──────────────────────────────────────── */
.ss-issue-body {
  padding: 0.75rem 1rem 1rem;
}

.ss-issue-form {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.ss-field-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-primary);
  display: block;
}

.ss-textarea {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.65rem 0.75rem;
  font-size: 0.95rem;
  font-family: inherit;
  color: var(--text-primary);
  background: #fff;
  resize: none;
  -webkit-appearance: none;
}
.ss-textarea:focus {
  outline: none;
  border-color: var(--tf-ocean);
  box-shadow: 0 0 0 3px rgba(26,159,196,0.15);
}

.ss-severity-row {
  display: flex;
  gap: 0.5rem;
}

.ss-severity-btn {
  flex: 1;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  background: #fff;
  padding: 0.6rem 0.4rem;
  font-size: 0.83rem;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: all 0.12s ease;
}
.ss-severity-btn.active[data-severity="fyi"]      { background: #dbeafe; border-color: #93c5fd; color: #1d4ed8; }
.ss-severity-btn.active[data-severity="watch_it"] { background: #fef3c7; border-color: #fde68a; color: #92400e; }
.ss-severity-btn.active[data-severity="urgent"]   { background: #fee2e2; border-color: #fca5a5; color: #991b1b; }

.ss-photo-row {
  display: flex;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.ss-photo-add {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.3rem;
  width: 80px;
  height: 80px;
  border: 1.5px dashed var(--border);
  border-radius: 10px;
  cursor: pointer;
  color: var(--text-muted);
  font-size: 0.7rem;
  font-weight: 600;
  background: var(--tf-sand);
  -webkit-tap-highlight-color: transparent;
}
.ss-photo-add:active { opacity: 0.7; }

.ss-flag-btn {
  width: 100%;
  background: var(--tf-cerulean);
  color: #fff;
  border: none;
  border-radius: 10px;
  padding: 0.75rem;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.ss-flag-btn:disabled {
  background: var(--border);
  color: var(--text-muted);
  cursor: default;
}
.ss-flag-btn:not(:disabled):active { opacity: 0.82; }

/* ── Section F — Notes & photos ───────────────────────────────────────── */
.ss-notes-body {
  padding: 0.75rem 1rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

/* ── Section G — Pinned action bar ───────────────────────────────────── */
.ss-action-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: #fff;
  border-top: 1px solid var(--border);
  padding: 0.65rem 0.9rem;
  padding-bottom: calc(0.65rem + env(safe-area-inset-bottom));
  z-index: 200;
}

.ss-action-bar-inner {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  max-width: 480px;
  margin: 0 auto;
}

.ss-back-btn {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  background: none;
  border: 1.5px solid var(--border);
  border-radius: 10px;
  padding: 0.7rem 0.9rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-primary);
  cursor: pointer;
  flex-shrink: 0;
  -webkit-tap-highlight-color: transparent;
}
.ss-back-btn:active { background: var(--tf-sand); }

.ss-complete-btn {
  flex: 1;
  background: var(--border);
  color: var(--text-muted);
  border: none;
  border-radius: 10px;
  padding: 0.85rem;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
  -webkit-tap-highlight-color: transparent;
}
.ss-complete-btn.active {
  background: var(--cta-bg);
  color: var(--cta-text);
}
.ss-complete-btn.active:active { opacity: 0.84; }

.ss-overflow-wrap {
  position: relative;
  flex-shrink: 0;
}

.ss-overflow-btn {
  background: none;
  border: 1.5px solid var(--border);
  border-radius: 10px;
  padding: 0.7rem 0.65rem;
  cursor: pointer;
  color: var(--text-muted);
  line-height: 0;
  -webkit-tap-highlight-color: transparent;
}
.ss-overflow-btn:active { background: var(--tf-sand); }

.ss-overflow-menu {
  position: absolute;
  bottom: calc(100% + 0.5rem);
  right: 0;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 10px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.12);
  min-width: 160px;
  overflow: hidden;
  z-index: 300;
}

.ss-overflow-item {
  display: block;
  width: 100%;
  background: none;
  border: none;
  padding: 0.85rem 1.1rem;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-primary);
  text-align: left;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.ss-overflow-item:not(:last-child) { border-bottom: 1px solid var(--border); }
.ss-overflow-item:active { background: var(--tf-sand); }

/* ── P2.3b — Guided Visit engine ─────────────────────────────────────── */
.gv-wrap {
  padding: 0 0 1rem;
}

.gv-trail {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 1.1rem;
}

.gv-trail-pill {
  background: #e8f6f0;
  color: #0b4f6c;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.2rem 0.6rem;
  border-radius: 20px;
  letter-spacing: 0.01em;
}
.gv-trail-pill::before {
  content: "✓ ";
  color: #1a9fc4;
}

.gv-progress-row {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  margin-bottom: 0.45rem;
}

.gv-phase-label {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--tf-cerulean);
}

.gv-divider {
  color: var(--text-muted);
  font-size: 0.78rem;
}

.gv-step-count {
  font-size: 0.78rem;
  color: var(--text-muted);
}

.gv-progress-bar {
  height: 3px;
  background: #e5eef2;
  border-radius: 2px;
  margin-bottom: 1.6rem;
  overflow: hidden;
}

.gv-progress-fill {
  height: 100%;
  background: var(--tf-ocean);
  border-radius: 2px;
  transition: width 0.35s ease;
}

.gv-step-card {
  background: #fff;
  border: 1.5px solid var(--border);
  border-radius: 16px;
  padding: 1.75rem 1.4rem 1.5rem;
  text-align: center;
  box-shadow: 0 2px 12px rgba(0,0,0,0.06);
}

.gv-step-icon {
  color: var(--tf-ocean);
  margin-bottom: 1rem;
  line-height: 0;
}

.gv-step-label {
  font-family: 'Playfair Display', 'Libre Baskerville', Georgia, serif;
  font-size: 1.55rem;
  font-weight: 700;
  color: var(--tf-cerulean);
  margin: 0 0 0.6rem;
  line-height: 1.2;
}

.gv-step-guidance {
  font-size: 0.97rem;
  color: var(--text-muted);
  margin: 0 0 0.5rem;
  line-height: 1.5;
}

.gv-action-hint {
  font-size: 0.85rem;
  color: var(--tf-ocean);
  font-weight: 600;
  margin: 0.4rem 0 0.7rem;
}

.gv-review-link {
  color: var(--tf-ocean);
  text-decoration: underline;
  font-weight: 700;
}
.gv-review-link:active { opacity: 0.7; }

.gv-done-btn {
  width: 100%;
  margin-top: 1.2rem;
  font-size: 1.05rem;
  padding: 0.9rem 1.5rem;
}

/* Finish state */
.gv-finish {
  text-align: center;
  padding: 2rem 0;
}

.gv-finish-icon {
  color: #16a34a;
  margin-bottom: 1rem;
  line-height: 0;
}

.gv-finish-label {
  font-family: 'Playfair Display', 'Libre Baskerville', Georgia, serif;
  font-size: 1.45rem;
  font-weight: 700;
  color: var(--tf-cerulean);
  margin: 0 0 0.5rem;
}

.gv-finish-hint {
  font-size: 0.95rem;
  color: var(--text-muted);
  margin: 0;
}
.ss-overflow-danger { color: var(--danger); }

/* ════════════════════════════════════════════════════════════════════════
   P2.X — On-site QR review request step
   Extends the existing .gv-step-card with review-specific components.
   Uses existing tokens only — no new palette values.
   ════════════════════════════════════════════════════════════════════════ */

/* Five gold stars replacing the normal SVG icon */
.gv-review-stars {
  display: flex;
  justify-content: center;
  gap: 3px;
  margin-bottom: 0.9rem;
  font-size: 1.3rem;
  color: var(--cta-bg);
  line-height: 1;
}

/* Teal context badge — explains why this platform was chosen */
.gv-review-ctx {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  background: rgba(26,159,196,0.08);
  border-left: 3px solid var(--tf-ocean);
  border-radius: 0 6px 6px 0;
  padding: 0.4rem 0.65rem;
  margin: 0 0 1rem;
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--tf-cerulean);
  text-align: left;
}

/* QR code box */
.gv-qr-box {
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 1.1rem;
}

.gv-qr-header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.5rem 0.75rem;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-align: center;
}

.gv-qr-inner {
  background: #f9f9f9;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.gv-qr-inner canvas,
.gv-qr-inner img {
  border-radius: 6px;
  display: block;
}

.gv-qr-link {
  font-size: 0.72rem;
  color: var(--tf-ocean);
  margin-top: 0.55rem;
  word-break: break-all;
  text-align: center;
}

/* "They reviewed" is the full-width primary — reuses .btn.btn-primary.gv-done-btn */
/* Skip lives as a secondary below */
.gv-review-skip-btn {
  width: 100%;
  margin-top: 0.55rem;
  padding: 0.75rem 1rem;
  font-size: 0.95rem;
  background: transparent;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  color: var(--text-muted);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
}
.gv-review-skip-btn:active { opacity: 0.7; }

/* Platform switcher — tertiary, below the CTAs */
.gv-review-platform-wrap {
  margin-top: 1rem;
  padding-top: 0.9rem;
  border-top: 1px solid var(--border);
  text-align: left;
}

.gv-review-platform-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
}

.gv-review-platform-chips {
  display: flex;
  gap: 0.4rem;
  flex-wrap: nowrap;
}

.gv-review-pchip {
  padding: 0.3rem 0.8rem;
  border-radius: 20px;
  border: 1.5px solid var(--border);
  background: #fff;
  font-size: 0.8rem;
  color: var(--text-muted);
  white-space: nowrap;
  transition: all 0.15s;
}

.gv-review-pchip.active {
  color: #fff;
  border-color: transparent;
}

/* Skip form (replaces action buttons) */
.gv-review-skip-form {
  text-align: left;
}

.gv-review-mic-hint {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(26,159,196,0.07);
  border-radius: 6px;
  padding: 0.45rem 0.7rem;
  margin-bottom: 0.7rem;
}

.gv-review-mic-icon {
  width: 22px;
  height: 22px;
  background: var(--tf-ocean);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: #fff;
}

.gv-review-mic-text {
  font-size: 0.78rem;
  color: var(--tf-cerulean);
  line-height: 1.3;
}

.gv-review-skip-textarea {
  width: 100%;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  padding: 0.7rem 0.85rem;
  font-size: 0.97rem;
  color: var(--text-primary);
  resize: none;
  height: 80px;
  outline: none;
  line-height: 1.5;
  background: #fff;
}
.gv-review-skip-textarea:focus { border-color: var(--tf-ocean); }

.gv-review-char-count {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin: 0.3rem 0 0.7rem;
  text-align: right;
}
.gv-review-char-count.ok { color: var(--success); }

.gv-review-skip-confirm {
  width: 100%;
  margin-bottom: 0.35rem;
  font-size: 1rem;
  padding: 0.85rem 1rem;
  background: var(--tf-cerulean);
  color: #fff;
  border: none;
  border-radius: 8px;
}
.gv-review-skip-confirm:disabled { opacity: 0.35; cursor: not-allowed; }

.gv-review-skip-back {
  width: 100%;
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 0.85rem;
  padding: 0.5rem;
  text-align: center;
}

/* Inline confirmation (briefly replaces card content) */
.gv-review-confirm {
  text-align: center;
  padding: 1.5rem 0;
}

.gv-review-confirm-icon {
  font-size: 2.2rem;
  margin-bottom: 0.75rem;
  line-height: 1;
}

.gv-review-confirm-title {
  font-family: 'Playfair Display', 'Libre Baskerville', Georgia, serif;
  font-size: 1.45rem;
  font-weight: 700;
  color: var(--tf-cerulean);
  margin: 0 0 0.4rem;
}

.gv-review-confirm-sub {
  font-size: 0.92rem;
  color: var(--text-muted);
}

/* ════════════════════════════════════════════════════════════════════════
   P2.5 — Chemistry voice/tap entry + deterministic dosing
   Thumb-first targets (≥48px), high-contrast for outside readability.
   ════════════════════════════════════════════════════════════════════════ */
.chem-entry {
  margin: 0.5rem 1rem 0.9rem;
  background: var(--tf-sand);
  border-radius: 12px;
  padding: 0.9rem 1rem 1.1rem;
}
.chem-hint {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin: 0.1rem 0 0.8rem;
  line-height: 1.4;
}
.chem-mic-btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 52px;
  margin-bottom: 1rem;
  background: #fff;
  border: 1.5px solid var(--tf-ocean);
  color: var(--tf-ocean);
  font-weight: 700;
  border-radius: 10px;
}
.chem-mic-btn.recording {
  background: var(--tf-ocean);
  color: #fff;
  animation: chem-pulse 1.2s ease-in-out infinite;
}
@keyframes chem-pulse { 50% { opacity: 0.72; } }

.chem-fields { display: flex; flex-direction: column; gap: 0.85rem; }
.chem-field-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 0.35rem;
}
.chem-label {
  font-size: 1rem;
  font-weight: 700;
  color: var(--tf-cerulean);
}
.chem-unit { font-weight: 500; color: var(--text-muted); font-size: 0.85rem; }
.chem-last {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--tf-ocean);
  background: rgba(26,159,196,0.1);
  padding: 0.15rem 0.5rem;
  border-radius: 99px;
}
.chem-stepper { display: flex; align-items: stretch; gap: 0.5rem; }
.chem-step-btn {
  flex: 0 0 56px;
  min-height: 56px;
  font-size: 1.6rem;
  font-weight: 700;
  line-height: 1;
  background: #fff;
  border: 1.5px solid var(--tf-ocean);
  color: var(--tf-ocean);
  border-radius: 10px;
}
.chem-step-btn:active { background: var(--tf-aqua); }
.chem-input {
  flex: 1 1 auto;
  min-height: 56px;
  text-align: center;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--tf-navy);
  background: #fff;
  border: 1.5px solid var(--border);
  border-radius: 10px;
}
.chem-input:focus { outline: none; border-color: var(--tf-ocean); }

.chem-calc-btn {
  width: 100%;
  min-height: 56px;
  margin-top: 1.1rem;
  font-size: 1.05rem;
  font-weight: 700;
  background: var(--cta-bg);
  color: #fff;
  border: none;
  border-radius: 10px;
}

/* ── Dose answer card ── */
.chem-dose-result {
  margin-top: 1rem;
  background: #fff;
  border: 1.5px solid var(--cta-bg);
  border-radius: 12px;
  padding: 0.9rem 1rem 1rem;
}
.chem-dose-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 0.7rem;
}
.chem-dose-title {
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--cta-bg);
}
.chem-dose-vol { font-size: 0.82rem; font-weight: 600; color: var(--text-muted); }
.chem-dose-empty, .chem-dose-ok {
  font-size: 0.95rem;
  color: var(--tf-cerulean);
  margin: 0;
}
.chem-dose-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 0.8rem; }
.chem-dose-item {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border);
}
.chem-dose-item:last-child { border-bottom: none; padding-bottom: 0; }
.chem-dose-amt {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--tf-navy);
}
.chem-dose-chem { font-size: 1rem; font-weight: 600; color: var(--tf-cerulean); }
.chem-dose-reason { font-size: 0.82rem; color: var(--text-muted); }
.chem-dose-note { font-size: 0.82rem; color: var(--text-muted); font-style: italic; }
.chem-dose-retest {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--cta-bg);
}
.chem-advisory-list { list-style: none; padding: 0; margin: 0.6rem 0 0; display: flex; flex-direction: column; gap: 0.5rem; }
.chem-advisory-item {
  font-size: 0.9rem;
  line-height: 1.45;
  color: var(--tf-cerulean);
  background: var(--tf-sand);
  border-radius: 8px;
  padding: 0.55rem 0.7rem;
}
.chem-dose-foot {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin: 0.8rem 0 0.4rem;
}
.chem-speak-btn { width: 100%; min-height: 48px; }

/* ── Volume prompt-and-save ── */
.chem-volume-prompt { display: flex; flex-direction: column; gap: 0.3rem; }
.chem-volume-label { font-size: 1rem; font-weight: 700; color: var(--tf-cerulean); margin: 0; }
.chem-volume-hint { font-size: 0.85rem; color: var(--text-muted); margin: 0 0 0.5rem; }
.chem-volume-row { display: flex; align-items: center; gap: 0.5rem; }
.chem-volume-row .chem-input { flex: 1 1 auto; }
.chem-volume-row .btn { flex: 0 0 auto; min-height: 56px; }

/* ════════════════════════════════════════════════════════════════════════
   Proactive day flow — next-stop / arrival card + day-briefing nudge
   (foreground-only; see briefs/proactive-day-flow-brief.md)
   ════════════════════════════════════════════════════════════════════════ */

/* Day-briefing nudge — slim banner on first open of the day */
.day-nudge { margin: 0.75rem 1rem 0; }
.day-nudge-inner {
  display: flex; align-items: center; gap: 0.6rem; width: 100%;
  padding: 0.7rem 0.9rem; border: none; border-radius: 12px; cursor: pointer;
  background: var(--tf-aqua); color: var(--tf-navy); text-align: left;
}
.day-nudge-play {
  display: inline-flex; align-items: center; justify-content: center;
  width: 28px; height: 28px; border-radius: 50%;
  background: var(--tf-navy); color: #fff; flex: 0 0 auto;
}
.day-nudge-text { font-size: 0.95rem; font-weight: 600; }

/* Next-stop / arrival hero card */
.proactive-card { margin: 0.75rem 1rem 0; }
.pro-next, .pro-arrival, .pro-done {
  border-radius: 16px; padding: 1.1rem 1.15rem;
  background: var(--tf-cerulean); color: #fff;
  box-shadow: 0 6px 18px rgba(6, 40, 64, 0.18);
}
.pro-arrival { background: var(--tf-ocean); }
.pro-tag {
  display: inline-block; font-size: 0.72rem; font-weight: 700;
  letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--tf-aqua); margin-bottom: 0.3rem;
}
.pro-tag-arrival { color: #fff; opacity: 0.92; }
.pro-name {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.5rem; font-weight: 700; margin: 0 0 0.15rem; color: #fff;
}
.pro-service { font-size: 0.95rem; margin: 0 0 0.1rem; color: rgba(255,255,255,0.92); }
.pro-address { font-size: 0.9rem; margin: 0 0 0.85rem; color: rgba(255,255,255,0.78); }

.pro-navigate-btn, .pro-start-btn {
  width: 100%; background: var(--cta-bg); color: var(--cta-text);
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  font-size: 1.05rem; font-weight: 700; min-height: 56px; border: none;
}
.pro-start-btn { font-size: 1.15rem; }

.pro-sub-actions {
  display: flex; align-items: center; justify-content: space-between;
  gap: 0.75rem; margin-top: 0.8rem; flex-wrap: wrap;
}
.pro-briefing-btn {
  display: inline-flex; align-items: center; gap: 0.4rem;
  background: rgba(255,255,255,0.14); color: #fff; border: none;
  border-radius: 999px; padding: 0.45rem 0.8rem; font-size: 0.85rem;
  font-weight: 600; cursor: pointer;
}
.pro-briefing-btn.is-heard { background: rgba(255,255,255,0.10); color: rgba(255,255,255,0.85); }
.pro-heard-check {
  display: inline-flex; align-items: center; justify-content: center;
  width: 18px; height: 18px; border-radius: 50%;
  background: var(--tf-aqua); color: var(--tf-navy); margin-left: 0.15rem;
}
.pro-open-link {
  font-size: 0.85rem; font-weight: 600; color: #fff;
  text-decoration: underline; text-underline-offset: 2px;
}

.pro-done {
  display: flex; align-items: center; gap: 0.7rem;
  background: var(--tf-sand); color: var(--tf-cerulean);
}
.pro-done-check {
  display: inline-flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; border-radius: 50%;
  background: var(--tf-ocean); color: #fff; flex: 0 0 auto;
}
.pro-done-title { margin: 0; font-size: 1.05rem; font-weight: 700; }
