/* MN Custom Homes PM Dashboard v3 — Stitch "MN Homes Dashboard Redesign" color scheme
   WCAG 2.2 AA, mobile-first, Manrope + Inter + Space Grotesk typography */

:root {
  /* Surface hierarchy (Material Design 3 — Stitch April 2026) */
  --bg: #11131d;
  --surface-lowest: #0c0e18;
  --surface-low: #191b26;
  --surface: #1d1f2a;
  --surface-high: #282934;
  --surface-highest: #32343f;
  --surface-bright: #373844;

  /* Text */
  --text: #e1e1f0;
  --text-muted: #c4c6cc;
  --text-subtle: #8e9196;

  /* Accent */
  --primary: #82cfff;
  --primary-container: #001d2b;
  --on-primary: #00344b;
  --on-primary-container: #008cc1;
  --ok: #4de082;
  --warn: #fbbf24;
  --err: #ffb4ab;
  --err-container: #93000a;

  /* Secondary */
  --secondary: #bbc6e2;
  --secondary-container: #3e4960;
  --on-secondary-container: #adb8d3;

  /* Structure */
  --border: #44474c;
  --border-subtle: #32343f;
  --radius: 0.125rem;
  --radius-lg: 0.25rem;
  --radius-xl: 0.5rem;
  --radius-full: 0.75rem;

  /* Spacing */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 16px;
  --space-4: 24px;
  --space-5: 32px;
  --space-6: 40px;

  /* Typography */
  --font-headline: 'Manrope', -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-label: 'Space Grotesk', 'Inter', monospace;
}

/* Light theme disabled — dark mode is the primary design.
   To re-enable, uncomment and update colors to match Stitch design. */

/* Material Symbols icon config */
.material-symbols-outlined {
  font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24;
  vertical-align: middle;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }

body {
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.5;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 3px solid var(--primary);
  outline-offset: 2px;
}

/* ================================================================
   HEADER / NAVIGATION — Glassmorphism sticky nav
   ================================================================ */

header {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  padding: 0 var(--space-5);
  background: rgba(15, 20, 25, 0.7);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-subtle);
}

.header-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-3);
  width: 100%;
  height: 64px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  padding: 10px 16px;
  background: var(--primary);
  color: var(--on-primary);
  border-radius: var(--radius);
  font-weight: 700;
}
.skip-link:focus { left: 8px; top: 8px; }

header h1,
header .site-title {
  font-family: var(--font-headline);
  font-size: 1.125rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 0;
}
header h1 a,
header .site-title a { color: var(--text); text-decoration: none; }

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: var(--radius);
  font-size: 0.75rem;
  font-weight: 600;
  background: var(--surface);
  color: var(--text-muted);
  border: 1px solid var(--border-subtle);
}
.badge.ok { color: var(--ok); border-color: color-mix(in srgb, var(--ok) 30%, transparent); }
.badge.warn { color: var(--warn); border-color: color-mix(in srgb, var(--warn) 30%, transparent); }

.insp-status { font-weight: 600; }
.insp-passed { color: #2e9e44; }
.insp-partial, .insp-not_ready, .insp-failed { color: #d9534f; }
.insp-ongoing, .insp-scheduled { color: #b8860b; }
.permit-card { border: 1px solid var(--border, #ddd); border-radius: 8px;
               padding: .5rem .75rem; margin: .5rem 0; }

/* PERMITS tab — inspection table + status filter chips */
.table-scroll { overflow-x: auto; }
.insp-table { width: 100%; border-collapse: collapse; font-size: .92em; }
.insp-table th { text-align: left; padding: 4px 8px; opacity: .7; font-weight: 600;
                 border-bottom: 1px solid var(--border, #ddd); white-space: nowrap; }
.insp-table td { padding: 4px 8px; border-bottom: 1px solid
                 color-mix(in srgb, var(--border, #ddd) 45%, transparent); vertical-align: top; }
.insp-table td:first-child { min-width: 12em; }
.insp-comments td { padding-top: 0; opacity: .75; font-size: .93em; border-bottom-width: 1px; }
.insp-hist td { opacity: .8; font-size: .93em; }
.insp-nr { opacity: .5; }
.insp-nr-btn { font-size: .85em; padding: 2px 8px; }
.pfilter { display: flex; gap: 8px; flex-wrap: wrap; margin: .5rem 0; }
.pfilter-chip { padding: 3px 10px; border: 1px solid var(--border, #ddd); border-radius: 999px;
                text-decoration: none; font-size: .9em; white-space: nowrap; }
.pfilter-chip.on { background: var(--sh-cyan, #29b6d8); color: #04222b; font-weight: 600;
                   border-color: transparent; }

/* Inspection scheduling — schedule form + pending-request cards */
.sched-group { margin: .6rem 0; border: 1px solid var(--border-subtle); border-radius: var(--radius);
               padding: .4rem .6rem; }
.sched-group summary { font-weight: 600; cursor: pointer; }
.sched-row { display: grid; grid-template-columns: 1fr auto auto 1fr; gap: 8px;
             align-items: center; padding: 6px 0; border-bottom: 1px solid
             color-mix(in srgb, var(--border-subtle) 60%, transparent); }
.sched-row:last-child { border-bottom: none; }
.sched-row-label { display: flex; align-items: center; gap: 6px; min-width: 12em; }
.sched-restricted { opacity: .5; }
.sched-restricted-note { grid-column: 1 / -1; margin: 0; font-size: .85em; }
.sched-contact { display: flex; gap: 8px; flex-wrap: wrap; margin: .75rem 0;
                 border: 1px solid var(--border-subtle); border-radius: var(--radius); padding: .5rem; }

.req-cards { display: flex; flex-wrap: wrap; gap: var(--space-3); margin: .5rem 0; }
.req-card { border: 1px solid var(--border-subtle); border-radius: var(--radius-lg);
            padding: var(--space-2) var(--space-3); min-width: 220px; flex: 1 1 260px; }
.req-items { list-style: none; margin: 6px 0; padding: 0; font-size: .9em; }
.req-thumb { max-width: 100%; max-height: 120px; border-radius: var(--radius); display: block;
             margin: 6px 0; }

/* Standalone /inspection-requests/... confirm/cancel page (Telegram link, no session) */
.insp-confirm-wrap { display: flex; justify-content: center; padding: var(--space-4) 0; }
.insp-confirm-card { max-width: 480px; width: 100%; }
.insp-confirm-items { list-style: none; margin: var(--space-2) 0; padding: 0; }
.insp-confirm-items li { padding: var(--space-2) 0; border-bottom: 1px solid var(--border-subtle); }
.insp-confirm-contact { margin: var(--space-2) 0; }
.insp-confirm-preview { max-width: 100%; border-radius: var(--radius-lg); display: block;
                        margin: var(--space-3) 0; }

.status-nav { display: flex; gap: var(--space-2); flex-wrap: wrap; }

.main-nav {
  display: flex;
  gap: var(--space-5);
  width: 100%;
  padding-bottom: var(--space-2);
}
.main-nav a {
  font-family: var(--font-headline);
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.875rem;
  padding: var(--space-1) 0;
  border-bottom: 2px solid transparent;
  transition: color 0.2s, border-color 0.2s;
}
.main-nav a:hover {
  color: var(--text);
  text-decoration: none;
}
.main-nav a.active,
.main-nav a[aria-current="page"] {
  color: var(--primary);
  border-bottom-color: var(--primary);
}

/* ================================================================
   LAYOUT
   ================================================================ */

main {
  max-width: 1440px;
  margin: 0 auto;
  padding: var(--space-5) var(--space-5);
}

section + section { margin-top: var(--space-6); }

h2 {
  font-family: var(--font-headline);
  font-weight: 700;
  font-size: 1.25rem;
  letter-spacing: -0.02em;
  margin-top: 0;
}

.muted { color: var(--text-muted); }

/* ================================================================
   CALLOUT / BREADCRUMB
   ================================================================ */

.callout {
  padding: var(--space-3);
  border-radius: var(--radius);
  border: 1px solid var(--border-subtle);
  margin: var(--space-3) 0;
  background: var(--surface-low);
}
.callout.warn {
  border-color: var(--warn);
  border-left: 4px solid var(--warn);
  background: color-mix(in srgb, var(--warn) 5%, var(--surface-low));
}
.callout code {
  background: var(--surface-high);
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 0.875em;
}

.breadcrumb {
  margin-bottom: var(--space-3);
  font-size: 0.8125rem;
  color: var(--text-subtle);
}
.breadcrumb a { color: var(--primary); }

/* ================================================================
   WORKFLOW LAUNCHERS — Stitch segmented button style
   ================================================================ */

.workflow-grid {
  display: flex;
  gap: 2px;
  margin-top: var(--space-3);
  background: var(--surface-low);
  border-radius: var(--radius-lg);
  padding: 6px;
}

.workflow-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  flex: 1;
  padding: var(--space-3) var(--space-4);
  background: transparent;
  color: var(--text-muted);
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  font: inherit;
  font-weight: 600;
  font-size: 0.9375rem;
  transition: all 0.2s;
  min-height: 56px;
}
.workflow-btn:hover {
  background: var(--surface);
  color: var(--text);
}
.workflow-btn:active { transform: scale(0.98); }
.workflow-btn.morning {
  background: var(--surface);
  color: var(--primary);
}
.workflow-icon { font-size: 1.25rem; }
.workflow-label { font-weight: 700; }
.workflow-hint { font-size: 0.75rem; color: var(--text-subtle); display: none; }

/* ================================================================
   STAT CARDS — Left-border accent from Stitch
   ================================================================ */

.task-summary-row {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: var(--space-3);
  margin-top: var(--space-3);
}

.task-summary-item {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
  background: var(--surface-low);
  border-radius: var(--radius-lg);
  padding: var(--space-4) var(--space-3);
  border-left: 4px solid transparent;
  transition: border-color 0.2s, transform 0.15s;
}
.task-summary-item:first-child { border-left-color: var(--primary); }
.task-summary-item:hover { transform: translateY(-1px); }

.task-summary-count {
  font-family: var(--font-headline);
  font-size: 2rem;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.03em;
  line-height: 1;
}

.task-summary-label {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--text-subtle);
  margin-top: 2px;
}

/* ================================================================
   FORM LAUNCHER GRID — Quick Entry cards
   ================================================================ */

.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: var(--space-3);
  margin-top: var(--space-3);
}
.form-grid form { margin: 0; }

.form-button {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--space-2);
  width: 100%;
  min-height: 88px;
  padding: var(--space-3);
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  cursor: pointer;
  font: inherit;
  text-align: left;
  transition: all 0.2s;
}
.form-button:hover:not(:disabled) {
  border-color: var(--primary);
  background: var(--surface-high);
  transform: translateY(-1px);
}
.form-button:active:not(:disabled) { transform: translateY(0); }
.form-button:disabled { opacity: 0.5; cursor: not-allowed; }
.form-button-title { font-size: 0.9375rem; font-weight: 700; font-family: var(--font-headline); }
.form-button-hint { font-size: 0.75rem; color: var(--text-subtle); }

/* ================================================================
   PROJECT CARDS — Stitch bento style
   ================================================================ */

.project-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: var(--space-3);
  margin-top: var(--space-3);
}

.project-card {
  background: var(--surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: var(--space-4);
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  transition: all 0.25s;
}
.project-card:hover {
  border-color: var(--primary);
  background: var(--surface-high);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.project-card-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: var(--space-2);
}
.project-card-header h3 {
  font-family: var(--font-headline);
  font-weight: 700;
}

.project-sea-id {
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  background: var(--surface-high);
  padding: 2px 8px;
  border-radius: var(--radius);
  color: var(--text-muted);
}

/* ================================================================
   CONVERSATION / CHAT
   ================================================================ */

.conversation-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-4);
}
@media (min-width: 900px) {
  .conversation-layout { grid-template-columns: 1.4fr 1fr; }
}

.chat {
  background: var(--surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: var(--space-3);
  display: flex;
  flex-direction: column;
  min-height: 60vh;
}

.chat-log {
  flex: 1;
  overflow-y: auto;
  padding: var(--space-2);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  max-height: 60vh;
}

.message {
  padding: var(--space-3);
  border-radius: var(--radius-lg);
  max-width: 90%;
}

.message-user {
  align-self: flex-end;
  background: var(--primary-container);
  /* --on-primary (#00344b) on --primary-container (#001d2b) is ~1.3:1 —
     unreadable. Body text on the dark container passes at >12:1. */
  color: var(--text);
}

.message-assistant {
  align-self: flex-start;
  background: var(--surface-high);
  border: 1px solid var(--border-subtle);
}

.message-role {
  font-size: 0.625rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  opacity: 0.6;
  margin-bottom: var(--space-1);
}
.message-body { white-space: pre-wrap; word-break: break-word; }

.chat-input {
  display: flex;
  gap: var(--space-2);
  margin-top: var(--space-3);
}
.chat-input input {
  flex: 1;
  min-height: 44px;
  padding: 0 var(--space-3);
  background: var(--surface-high);
  color: var(--text);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
  font: inherit;
  transition: border-color 0.15s;
}
.chat-input input:focus { border-color: var(--primary); }

.chat-input button,
.preview button {
  min-height: 44px;
  min-width: 88px;
  padding: 0 var(--space-3);
  /* light-cyan primary with dark text (~8:1); the old container/on-primary
     pair was ~1.3:1 — the Send label was near-invisible */
  background: var(--primary);
  color: var(--on-primary);
  border: none;
  border-radius: var(--radius);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
  transition: filter 0.15s, transform 0.1s;
}
.chat-input button:hover,
.preview button:hover { filter: brightness(1.1); }
.chat-input button:active { transform: scale(0.98); }

/* Preview pane */
.preview {
  background: var(--surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: var(--space-3);
  align-self: start;
}
@media (min-width: 900px) {
  .preview { position: sticky; top: 84px; }
}

/* Photo upload section (punch list) */
.photo-section {
  margin-top: var(--space-4);
  padding-top: var(--space-3);
  border-top: 1px solid var(--border-subtle);
}

.photo-section-title {
  font-family: var(--font-headline);
  font-size: 0.9375rem;
  font-weight: 700;
  margin: 0 0 var(--space-2) 0;
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
  gap: var(--space-2);
  margin-bottom: var(--space-2);
}

.photo-thumb {
  position: relative;
  aspect-ratio: 1;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--surface-high);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border-subtle);
}

.photo-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.photo-thumb.uploading {
  color: var(--text-subtle);
  font-size: 0.75rem;
  animation: pulse-upload 1.5s ease-in-out infinite;
}

.photo-thumb.error {
  color: var(--err);
  font-size: 0.6875rem;
  border-color: var(--err);
}

@keyframes pulse-upload {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

.photo-remove {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 20px;
  height: 20px;
  background: rgba(0, 0, 0, 0.7);
  color: #fff;
  border: none;
  border-radius: 50%;
  font-size: 0.75rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.15s;
}

.photo-thumb:hover .photo-remove { opacity: 1; }

.photo-upload-btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-3);
  background: var(--surface-high);
  color: var(--primary);
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  font-size: 0.8125rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
  min-height: 40px;
}

.photo-upload-btn:hover {
  border-color: var(--primary);
  background: color-mix(in srgb, var(--primary) 8%, var(--surface-high));
}

.photo-hint {
  font-size: 0.6875rem;
  margin: var(--space-1) 0 0 0;
}

.preview-list { margin: 0 0 var(--space-3) 0; padding: 0; }
.preview-row {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: var(--space-2);
  padding: var(--space-2) 0;
  border-bottom: 1px solid var(--border-subtle);
}
.preview-row:last-child { border-bottom: none; }
.preview-row dt { font-weight: 600; color: var(--text-subtle); font-size: 0.75rem; margin: 0; }
.preview-row dd { margin: 0; word-break: break-word; }

.submit-result { margin-top: var(--space-3); }

.status {
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius);
  font-size: 0.875rem;
}
.status.ok {
  background: color-mix(in srgb, var(--ok) 10%, var(--surface-low));
  color: var(--ok);
  border: 1px solid color-mix(in srgb, var(--ok) 30%, transparent);
}
.status.err {
  background: color-mix(in srgb, var(--err) 10%, var(--surface-low));
  color: var(--err);
  border: 1px solid color-mix(in srgb, var(--err) 30%, transparent);
}
.status code {
  background: var(--surface-high);
  padding: 1px 4px;
  border-radius: 4px;
  font-size: 0.875em;
}

/* ================================================================
   BUTTONS
   ================================================================ */

.btn-primary {
  min-height: 44px;
  padding: 0 var(--space-4);
  /* was container/on-primary (~1.3:1, unreadable); the later shell-era
     definition (below) already uses primary/on-primary — keep them consistent */
  background: var(--primary);
  color: var(--on-primary);
  border: none;
  border-radius: var(--radius);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
  transition: filter 0.15s, transform 0.1s;
}
.btn-primary:hover { filter: brightness(1.1); }
.btn-primary:active { transform: scale(0.98); }

.btn-sm {
  padding: var(--space-1) var(--space-3);
  background: var(--surface-high);
  color: var(--text);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
  font: inherit;
  font-size: 0.8125rem;
  cursor: pointer;
  transition: all 0.15s;
}
.btn-sm:hover { border-color: var(--primary); background: var(--surface-highest); }
.btn-sm.btn-err { color: var(--err); border-color: color-mix(in srgb, var(--err) 40%, transparent); }
.btn-sm.btn-err:hover { background: color-mix(in srgb, var(--err) 8%, var(--surface-high)); }

.btn-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  /* 44px minimum touch target (WCAG 2.5.5 / field gloves); was 32px */
  width: 44px;
  height: 44px;
  padding: 0;
  background: var(--surface-high);
  color: var(--text-muted);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
  cursor: pointer;
  font-size: 0.875rem;
  transition: all 0.15s;
}
.btn-icon:hover { border-color: var(--primary); color: var(--text); }
.btn-icon.btn-ok { color: var(--ok); }
.btn-icon.btn-ok:hover { border-color: var(--ok); }
.btn-icon.btn-err { color: var(--err); }
.btn-icon.btn-err:hover { border-color: var(--err); }

/* ================================================================
   FORMS
   ================================================================ */

.inline-form {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  align-items: flex-end;
}
.form-field {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}
.form-field label {
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-subtle);
}

.form-field input,
.form-field select,
.form-field textarea {
  min-height: 40px;
  padding: var(--space-2) var(--space-3);
  background: var(--surface-high);
  color: var(--text);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
  font: inherit;
  font-size: 0.875rem;
  transition: border-color 0.15s;
}
.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus { border-color: var(--primary); }
.form-field textarea { min-height: 60px; resize: vertical; }

/* Filter bar */
.filter-bar { margin-bottom: var(--space-3); }
.filter-form {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  align-items: flex-end;
}

/* ================================================================
   TABLES
   ================================================================ */

.responsive-table { overflow-x: auto; }

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}
th, td {
  padding: var(--space-2) var(--space-3);
  text-align: left;
  border-bottom: 1px solid var(--border-subtle);
}
th {
  font-size: 0.6875rem;
  font-weight: 600;
  color: var(--text-subtle);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}
tr:hover td { background: var(--surface-low); }
.col-icon { width: 2rem; }

/* Task-specific */
.task-group { margin-top: var(--space-4); }
.task-group-header { margin: 0 0 var(--space-2) 0; font-size: 1rem; font-family: var(--font-headline); font-weight: 700; }
.task-row.completed { opacity: 0.5; }
.task-title.done { text-decoration: line-through; }
.task-actions { display: flex; gap: var(--space-1); align-items: center; flex-wrap: wrap; }

.inline-reschedule { display: inline-flex; gap: var(--space-1); align-items: center; }
.inline-reschedule input[type="date"] {
  width: 130px;
  min-height: 32px;
  padding: 0 var(--space-1);
  background: var(--surface-high);
  color: var(--text);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
  font-size: 0.75rem;
}

.create-task-details {
  margin-top: var(--space-4);
  background: var(--surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: var(--space-3);
}
.create-task-details summary { cursor: pointer; list-style: revert; }
.create-task-form {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  align-items: flex-end;
  margin-top: var(--space-3);
}
.create-task-form .form-field { min-width: 180px; flex: 1; }

/* ================================================================
   SEARCH
   ================================================================ */

.search-bar {
  background: var(--surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: var(--space-3);
  margin-bottom: var(--space-4);
}
.search-input-wrap { margin-bottom: var(--space-3); }
.search-input-wrap input[type="search"] {
  width: 100%;
  min-height: 48px;
  padding: var(--space-2) var(--space-3);
  background: var(--surface-high);
  color: var(--text);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
  font: inherit;
  font-size: 1rem;
  transition: border-color 0.15s;
}
.search-input-wrap input[type="search"]:focus { border-color: var(--primary); }
.search-filters {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  align-items: flex-end;
}

.search-results { display: flex; flex-direction: column; gap: var(--space-3); }
.search-count { font-size: 0.8125rem; margin: 0 0 var(--space-2) 0; color: var(--text-subtle); }

.search-result-card {
  background: var(--surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: var(--space-3);
  transition: all 0.2s;
}
.search-result-card:hover {
  border-color: var(--primary);
  transform: translateY(-1px);
}
.search-result-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-2);
}
.search-result-title { font-weight: 700; font-family: var(--font-headline); }
.search-result-date { margin-left: auto; font-size: 0.75rem; color: var(--text-subtle); }
.search-result-snippet {
  font-size: 0.875rem;
  line-height: 1.6;
  margin-bottom: var(--space-2);
  word-break: break-word;
}
.search-result-snippet mark {
  background: color-mix(in srgb, var(--warn) 25%, transparent);
  color: var(--text);
  padding: 1px 3px;
  border-radius: 2px;
}
.search-result-meta {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: 0.75rem;
  color: var(--text-subtle);
}
.search-empty { text-align: center; padding: var(--space-5); color: var(--text-subtle); }

/* Source badges */
.source-badge {
  font-size: 0.625rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 2px 8px;
  border-radius: var(--radius);
}
.source-message { color: var(--primary); background: color-mix(in srgb, var(--primary) 10%, transparent); }
.source-task { color: var(--ok); background: color-mix(in srgb, var(--ok) 10%, transparent); }
.source-submission { color: var(--warn); background: color-mix(in srgb, var(--warn) 10%, transparent); }

/* ================================================================
   SESSION CARDS
   ================================================================ */

.session-list { display: flex; flex-direction: column; gap: var(--space-3); }
.session-list h3 { margin: 0 0 var(--space-2) 0; font-family: var(--font-headline); }

.session-card {
  display: block;
  background: var(--surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: var(--space-3);
  text-decoration: none;
  color: var(--text);
  transition: all 0.2s;
}
.session-card:hover { border-color: var(--primary); text-decoration: none; transform: translateY(-1px); }

.session-card-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-2);
}
.session-card-date { margin-left: auto; font-size: 0.75rem; color: var(--text-subtle); }
.session-card-body {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-2);
  font-size: 0.8125rem;
}
.session-card-preview {
  font-size: 0.8125rem;
  line-height: 1.5;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  color: var(--text-muted);
}

.session-type-badge {
  font-size: 0.625rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 2px 8px;
  border-radius: var(--radius);
}
.session-type-morning_brief { color: var(--warn); background: color-mix(in srgb, var(--warn) 10%, transparent); }
.session-type-check_in { color: var(--ok); background: color-mix(in srgb, var(--ok) 10%, transparent); }
.session-type-eod_debrief { color: var(--primary); background: color-mix(in srgb, var(--primary) 10%, transparent); }

/* ================================================================
   RESPONSIVE
   ================================================================ */

@media (max-width: 600px) {
  header { padding: 0 var(--space-3); }
  main { padding: var(--space-3); }
  .inline-form,
  .filter-form,
  .create-task-form {
    flex-direction: column;
    align-items: stretch;
  }
  .task-actions { flex-direction: column; align-items: flex-start; }
  .project-cards { grid-template-columns: 1fr; }
  .workflow-grid { flex-direction: column; }
  .task-summary-row { grid-template-columns: repeat(2, 1fr); }
  .search-filters { flex-direction: column; }
  .search-result-header { flex-direction: column; align-items: flex-start; }
  .search-result-date { margin-left: 0; }
  .session-card-header { flex-direction: column; align-items: flex-start; }
  .session-card-date { margin-left: 0; }
}

/* ================================================================
   ACCESSIBILITY
   ================================================================ */

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

/* ================================================================
   STATUS GRID (project memory, system status)
   ================================================================ */

.status-grid { display: grid; gap: var(--space-2); margin-top: var(--space-3); }
.status-row {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: var(--space-3);
  padding: var(--space-2) 0;
  border-bottom: 1px solid var(--border-subtle);
}
.status-row dt { font-weight: 600; color: var(--text-subtle); font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.05em; margin: 0; }
.status-row dd { margin: 0; }
@media (max-width: 600px) {
  .status-row { grid-template-columns: 1fr; }
}

/* ================================================================
   BRAIN DUMP + TRIAGE (daily task capture)
   ================================================================ */

.pwa-enable-row {
  display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2);
  margin: 0 0 var(--space-3); font-size: 0.85rem;
}

.brain-dump-input {
  width: 100%;
  box-sizing: border-box;
  background: var(--surface-low);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-3);
  font-family: var(--font-body);
  font-size: 0.95rem;
  resize: vertical;
}
.brain-dump-input:focus { outline: none; border-color: var(--primary); }
.brain-dump-actions { display: flex; align-items: center; gap: var(--space-3); margin-top: var(--space-2); }

.btn-primary {
  background: var(--primary);
  color: var(--on-primary);
  border: none;
  border-radius: var(--radius-lg);
  padding: var(--space-2) var(--space-4);
  font-family: var(--font-label);
  font-weight: 600;
  cursor: pointer;
}
.btn-primary:hover { background: var(--on-primary-container); color: #fff; }

.capture-table { width: 100%; border-collapse: collapse; margin: var(--space-3) 0; font-size: 0.9rem; }
.capture-table th {
  text-align: left; color: var(--text-subtle); font-family: var(--font-label);
  font-weight: 500; padding: var(--space-1) var(--space-2); border-bottom: 1px solid var(--border-subtle);
}
.capture-table td { padding: var(--space-2); border-bottom: 1px solid var(--border-subtle); vertical-align: middle; }
.capture-table input[type="text"], .capture-table select {
  background: var(--surface-low); color: var(--text); border: 1px solid var(--border);
  border-radius: var(--radius); padding: var(--space-1) var(--space-2);
  font-family: var(--font-body); font-size: 0.85rem;
}
.capture-title { width: 100%; box-sizing: border-box; }
.capture-row.needs-project select[name="project_code"] { border-color: var(--warn); }
.capture-row.prio-urgent td:first-child { box-shadow: inset 3px 0 0 var(--err); }
.capture-row.prio-high td:first-child { box-shadow: inset 3px 0 0 var(--warn); }

/* Brain-dump review cards (task on its own line, fields beneath) */
.capture-list { display: flex; flex-direction: column; gap: var(--space-3); margin: var(--space-3) 0; }
.capture-card {
  background: var(--surface); border: 1px solid var(--border-subtle);
  border-left: 3px solid var(--border); border-radius: var(--radius-lg);
  padding: var(--space-3);
}
.capture-card.prio-urgent { border-left-color: var(--err); }
.capture-card.prio-high { border-left-color: var(--warn); }
.capture-card.prio-normal { border-left-color: var(--primary); }
.capture-card.prio-low { border-left-color: var(--text-subtle); }

.capture-card-head { display: flex; align-items: flex-start; gap: var(--space-3); }
.capture-keep { margin-top: 6px; flex: 0 0 auto; width: 18px; height: 18px; cursor: pointer; }
.capture-card-item { flex: 1; min-width: 0; }
.capture-title-full {
  width: 100%; box-sizing: border-box; background: var(--surface-low); color: var(--text);
  border: 1px solid var(--border); border-radius: var(--radius);
  padding: var(--space-2) var(--space-3); font-family: var(--font-body); font-size: 1rem;
}
.capture-title-full:focus { outline: none; border-color: var(--primary); }
.capture-desc { margin: var(--space-1) 0 0; font-size: 0.82rem; line-height: 1.4; }

.capture-card-fields { display: flex; flex-wrap: wrap; gap: var(--space-3); margin-top: var(--space-3); padding-left: calc(18px + var(--space-3)); }
.capture-field {
  display: flex; flex-direction: column; gap: 4px; flex: 1 1 160px; min-width: 140px;
  font-family: var(--font-label); font-size: 0.7rem; text-transform: uppercase;
  letter-spacing: 0.05em; color: var(--text-subtle);
}
.capture-field select {
  background: var(--surface-low); color: var(--text); border: 1px solid var(--border);
  border-radius: var(--radius); padding: var(--space-1) var(--space-2);
  font-family: var(--font-body); font-size: 0.85rem; text-transform: none; letter-spacing: 0;
}
.capture-card.needs-project select[name="project_code"] { border-color: var(--warn); }

.triage-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: var(--space-3); }
.triage-bucket { background: var(--surface); border: 1px solid var(--border-subtle); border-radius: var(--radius-lg); padding: var(--space-3); }
.triage-bucket-title {
  margin: 0 0 var(--space-2); font-family: var(--font-label); font-size: 0.85rem;
  color: var(--text-muted); display: flex; align-items: center; gap: var(--space-2);
}
.triage-list { list-style: none; margin: 0; padding: 0; }
.triage-item { display: flex; align-items: center; gap: var(--space-2); padding: var(--space-1) 0; border-bottom: 1px solid var(--border-subtle); }
.triage-item:last-child { border-bottom: none; }
.triage-title { flex: 1; }

.prio-dot { width: 8px; height: 8px; border-radius: 50%; flex: 0 0 auto; background: var(--text-subtle); }
.prio-dot.prio-urgent { background: var(--err); }
.prio-dot.prio-high { background: var(--warn); }
.prio-dot.prio-normal { background: var(--primary); }
.prio-dot.prio-low { background: var(--text-subtle); }

/* ================================================================
   CONTACTS DIRECTORY
   ================================================================ */

.contacts-filters, .add-contact-form, .assign-form {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  align-items: center;
}
.contacts-filters { margin-bottom: var(--space-3); }
.add-contact-form { margin-top: var(--space-2); }
.contacts-filters input, .contacts-filters select,
.add-contact-form input, .add-contact-form select,
.assign-form input, .assign-form select {
  background: var(--surface-low); color: var(--text); border: 1px solid var(--border);
  border-radius: var(--radius); padding: var(--space-1) var(--space-2);
  font-family: var(--font-body); font-size: 0.85rem;
}

.contact-group-title {
  margin: var(--space-4) 0 var(--space-1); font-family: var(--font-label);
  font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.05em;
  color: var(--text-subtle); display: flex; align-items: center; gap: var(--space-2);
}
.contact-group-title:first-of-type { margin-top: var(--space-2); }
.contacts-table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.contacts-table th {
  text-align: left; color: var(--text-subtle); font-family: var(--font-label);
  font-weight: 500; padding: var(--space-1) var(--space-2); border-bottom: 1px solid var(--border-subtle);
}
.contacts-table td { padding: var(--space-2); border-bottom: 1px solid var(--border-subtle); vertical-align: top; }
.assign-form { margin-top: var(--space-2); }

.badge-x {
  background: none; border: none; color: inherit; cursor: pointer;
  font-size: 0.85rem; line-height: 1; padding: 0 0 0 4px; opacity: 0.7;
}
.badge-x:hover { opacity: 1; }

/* ================================================================
   PROJECT DETAIL — specs panel + facts
   ================================================================ */

.doc-list { list-style: none; margin: 0 0 var(--space-3); padding: 0; }
.doc-item {
  display: flex; justify-content: space-between; gap: var(--space-3);
  padding: var(--space-1) 0; border-bottom: 1px solid var(--border-subtle);
}
.doc-name { font-family: var(--font-label); }

.doc-upload {
  display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2);
  margin: var(--space-2) 0 var(--space-1);
}
.doc-upload input[type="file"] {
  color: var(--text-muted); font-size: 0.85rem; max-width: 100%;
}
.doc-upload input[type="file"]::file-selector-button {
  background: var(--surface-high); color: var(--text); border: 1px solid var(--border);
  border-radius: var(--radius); padding: var(--space-1) var(--space-2); margin-right: var(--space-2); cursor: pointer;
}
.doc-upload-hint { margin: 0 0 var(--space-3); font-size: 0.78rem; }

.spec-search-label { display: block; color: var(--text-subtle); font-size: 0.8rem; margin-bottom: var(--space-1); }
.spec-search-input {
  width: 100%; box-sizing: border-box; background: var(--surface-low); color: var(--text);
  border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: var(--space-2) var(--space-3); font-family: var(--font-body); font-size: 0.95rem;
}
.spec-search-input:focus { outline: none; border-color: var(--primary); }

.spec-results-list { list-style: none; margin: var(--space-2) 0 0; padding: 0; }
.spec-result { padding: var(--space-2) 0; border-bottom: 1px solid var(--border-subtle); }
.spec-result-link { font-family: var(--font-label); }
.spec-snippet { margin-top: var(--space-1); font-size: 0.85rem; }

.project-facts {
  background: var(--surface-low); border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg); padding: var(--space-3);
  font-family: var(--font-body); font-size: 0.85rem; color: var(--text-muted);
  white-space: pre-wrap; overflow-x: auto;
}

/* Ask-the-documents (RAG) */
.doc-ask-form { margin-top: var(--space-3); }
.doc-ask-actions { display: flex; align-items: center; gap: var(--space-3); margin-top: var(--space-2); }
.doc-answer { margin-top: var(--space-3); }
.doc-answer-text {
  background: var(--primary-container); color: var(--text);
  border: 1px solid var(--border-subtle); border-left: 3px solid var(--primary);
  border-radius: var(--radius-lg); padding: var(--space-3);
  white-space: pre-wrap; font-size: 0.9rem; line-height: 1.5;
}
.doc-answer-sources { margin-top: var(--space-2); display: flex; flex-wrap: wrap; gap: var(--space-2); align-items: center; font-size: 0.8rem; }
.doc-source-link { font-family: var(--font-label); }

/* ================================================================
   CONSTRUCTION SCHEDULE (TaskRay)
   ================================================================ */

.sched-filters { display: flex; flex-wrap: wrap; gap: var(--space-1); margin-bottom: var(--space-2); }
.chip {
  display: inline-block; padding: 2px var(--space-2); border-radius: var(--radius-full);
  background: var(--surface-high); color: var(--text-muted); border: 1px solid var(--border-subtle);
  font-family: var(--font-label); font-size: 0.75rem; text-decoration: none;
}
.chip:hover { color: var(--text); }
.chip.active { background: var(--primary); color: var(--on-primary); border-color: var(--primary); }

.sched-scroll { max-height: 480px; overflow: auto; border: 1px solid var(--border-subtle); border-radius: var(--radius-lg); }
.sched-table { width: 100%; border-collapse: collapse; font-size: 0.82rem; }
.sched-table thead th {
  position: sticky; top: 0; background: var(--surface-high); color: var(--text-subtle);
  text-align: left; font-family: var(--font-label); font-weight: 500;
  padding: var(--space-2); border-bottom: 1px solid var(--border);
}
.sched-table td { padding: var(--space-1) var(--space-2); border-bottom: 1px solid var(--border-subtle); vertical-align: top; }
.sched-table tbody tr:hover { background: var(--surface-low); }

.sched-status {
  display: inline-block; padding: 1px var(--space-2); border-radius: var(--radius);
  font-size: 0.72rem; font-family: var(--font-label); background: var(--surface-bright); color: var(--text-muted);
}
.sched-status.sched-finished, .sched-status.sched-vendor-completed { background: #0f2a17; color: var(--ok); }
.sched-status.sched-holding { background: #2b2410; color: var(--warn); }
.sched-status.sched-critical-path { background: var(--err-container); color: var(--err); }
.sched-status.sched-inspection { background: var(--primary-container); color: var(--primary); }
.sched-status.sched-confirmed { background: #10241f; color: var(--ok); }

/* --- Look-ahead calendar (dashboard) --- */
.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 6px;
}
.cal-cell {
  min-height: 96px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 4px 5px;
  background: var(--surface);
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.cal-cell.cal-weekend { background: transparent; }
.cal-cell.cal-empty { opacity: 0.55; }
.cal-cell.cal-today { border-color: var(--primary); box-shadow: inset 0 0 0 1px var(--primary); }
.cal-date { display: flex; align-items: baseline; gap: 4px; font-size: 0.72rem; color: var(--text-muted); }
.cal-today .cal-date { color: var(--primary); font-weight: 700; }
.cal-num { font-size: 0.95rem; font-weight: 700; color: var(--text); }
.cal-item {
  font-size: 0.68rem;
  line-height: 1.2;
  padding: 2px 4px;
  border-radius: 4px;
  background: var(--bg);
  border-left: 3px solid var(--text-muted);
  white-space: normal;
  overflow-wrap: anywhere;
  text-align: left;
  width: 100%;
}
.cal-item .project-sea-id { font-size: 0.62rem; display: block; margin-bottom: 1px; }
.cal-item.cal-task { border-left-color: var(--primary); }
.cal-item.cal-task.prio-urgent { border-left-color: var(--err); }
.cal-item.cal-task.prio-high { border-left-color: #d98324; }
.cal-item.cal-schedule { border-left-color: var(--ok); }
@media (max-width: 720px) {
  .cal-grid { grid-template-columns: repeat(7, 1fr); gap: 3px; }
  .cal-cell { min-height: 88px; padding: 3px; }
  .cal-item { font-size: 0.62rem; }
}

/* --- Morning brief --- */
.brief-head { display: flex; align-items: center; justify-content: space-between; gap: var(--space-3); flex-wrap: wrap; }

/* Lookahead rows stack (date+project / task / confirm) so nothing wraps into
   a one-word-per-line column on a phone. */
.triage-item.la-stack { display: flex; flex-direction: column; align-items: flex-start; gap: 3px; }
.la-meta { display: inline-flex; gap: 8px; align-items: baseline; }

/* workflow-btn is now an <a> link */
a.workflow-btn { text-decoration: none; flex-direction: column; text-align: center; }

/* --- Email compose quick actions (email tasks) --- */
.email-actions { display: flex; gap: 6px; margin-top: 5px; flex-wrap: wrap; }
.btn-xs {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  /* compact look, field-usable hit area (min 36px tall; alerts get tapped
     from a moving truck) */
  min-height: 36px;
  padding: 2px 12px;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text);
  text-decoration: none;
}
.btn-xs:hover { background: var(--primary-container); color: var(--primary); }

/* --- Brain-dump mic + camera --- */
.bd-tools { display: flex; gap: 8px; align-items: center; margin-top: 6px; }
.bd-mic.listening { color: var(--err); animation: pulse 1.2s infinite; }
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.4; } }

/* --- Jobsite photos --- */
.photo-upload { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-bottom: var(--space-3); }
.photo-caption { flex: 1; min-width: 140px; padding: 6px 8px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); color: var(--text); }
.photo-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 8px; }
.photo-thumb { position: relative; display: block; aspect-ratio: 1; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--border); }
.photo-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.photo-cap { position: absolute; left: 0; right: 0; bottom: 0; font-size: 0.65rem; padding: 2px 4px; background: rgba(0,0,0,0.6); color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* --- Ask anything panel (project page) --- */
.ask-anything {
  background: var(--surface);
  border: 1px solid var(--primary);
  border-radius: var(--radius);
  padding: var(--space-3) var(--space-4);
  margin-bottom: var(--space-4);
}
.ask-anything h3 { margin-top: 0; }

/* --- Jobsite location form --- */
.loc-form { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.loc-form input[name="lat"], .loc-form input[name="lng"] { width: 90px; padding: 6px 8px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); color: var(--text); }

/* --- Reminders / nudges --- */
.nudge-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 8px; }
.nudge-item { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap;
  padding: 8px 12px; border: 1px solid var(--border); border-left: 4px solid var(--primary); border-radius: var(--radius); background: var(--surface); }
.nudge-item.nudge-overdue { border-left-color: var(--err); }
.nudge-item.nudge-schedule { border-left-color: var(--ok); }
.nudge-main { flex: 1; min-width: 180px; }
.nudge-act { display: flex; gap: 6px; align-items: center; }

/* --- Look-ahead view toggle --- */
.la-head { display: flex; align-items: center; justify-content: space-between; gap: var(--space-3); flex-wrap: wrap; }
.la-toggle { display: inline-flex; border: 1px solid var(--border); border-radius: 999px; overflow: hidden; }
.la-tab { font: inherit; font-size: 0.8rem; padding: 4px 14px; background: transparent; color: var(--text-muted); border: none; cursor: pointer; }
.la-tab.is-active { background: var(--primary); color: #fff; }

/* --- Schedule action modal (tap a scheduled task) --- */
.cal-item.cal-schedule { cursor: pointer; text-align: left; width: 100%; font: inherit; }
.cal-item.cal-schedule:hover { filter: brightness(1.25); }
.row-clickable { cursor: pointer; }
.row-clickable:hover { background: var(--surface); }
.sched-modal { border: 1px solid var(--border); border-radius: var(--radius); background: var(--bg); color: var(--text); max-width: 520px; width: 92%; padding: var(--space-4); }
.sched-modal::backdrop { background: rgba(0,0,0,0.5); }
.sched-modal-title { margin-top: 0; }
.sched-actions { display: flex; gap: 8px; flex-wrap: wrap; margin: var(--space-3) 0; }
.sched-actions-note { font-size: 0.75rem; }
.sched-modal-close { text-align: right; margin-top: var(--space-2); }
.vendor-cands { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.vendor-cands form { margin: 0; }
.vendor-search-label { display: block; margin-top: var(--space-3); color: var(--text-muted); font-size: 0.85rem; }
.vendor-search-label input { display: block; width: 100%; margin-top: 4px; padding: 6px 8px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); color: var(--text); }

/* --- Settings form --- */
.settings-form { max-width: 460px; display: flex; flex-direction: column; gap: 10px; }
.settings-form label { display: flex; flex-direction: column; gap: 3px; font-size: 0.85rem; color: var(--text-muted); }
.settings-form input { padding: 8px 10px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); color: var(--text); font-size: 0.95rem; }
.settings-form h3 { margin-bottom: 0; }

/* --- Vendor confirmation status --- */
.confirm-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-top: var(--space-2); }
.conf-badge { font-size: 0.7rem; padding: 2px 8px; border-radius: 999px; text-transform: capitalize; background: var(--surface); border: 1px solid var(--border); }
.conf-badge.conf-confirmed { background: #10241f; color: var(--ok); border-color: var(--ok); }
.conf-badge.conf-declined { background: var(--err-container); color: var(--err); border-color: var(--err); }
.conf-badge.conf-requested { background: var(--primary-container); color: var(--primary); }
.conf-dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; margin-right: 3px; background: var(--text-muted); vertical-align: middle; }
.conf-dot.conf-confirmed { background: var(--ok); }
.conf-dot.conf-declined { background: var(--err); }
.conf-dot.conf-requested { background: #d98324; }
.conf-dot.conf-none { background: var(--text-muted); }

/* --- Day-route planner --- */
.plan-daypick { margin-bottom: var(--space-2); }
.plan-origin { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin: var(--space-2) 0; }
.plan-origin input[type=text] { padding: 6px 8px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); color: var(--text); }
.plan-stops { padding-left: 18px; }
.plan-summary { margin: var(--space-2) 0; }
.plan-route { padding-left: 20px; display: flex; flex-direction: column; gap: 6px; margin: var(--space-2) 0; }
.plan-route li { padding: 2px 0; }
.plan-stop-items { font-size: 0.78rem; }

/* --- Schedule conflict flags --- */
.cal-conflict { color: var(--err); font-size: 0.8rem; float: right; cursor: help; }
.brief-conflicts { border-left: 3px solid var(--err); padding-left: var(--space-3); }

/* --- Weekly batched plan --- */
.weekplan { background: var(--surface); border: 1px solid var(--border); border-left: 4px solid var(--primary); border-radius: var(--radius); padding: var(--space-3) var(--space-4); }
.weekplan-list { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 6px; }
.weekplan-list li { line-height: 1.4; }

/* --- Jarvis voice assistant --- */
.jarvis-wrap { max-width: 640px; }
.jarvis-controls { display: flex; align-items: center; gap: var(--space-3); margin: var(--space-4) 0; }
.jarvis-orb { width: 88px; height: 88px; border-radius: 50%; border: none; cursor: pointer;
  background: radial-gradient(circle at 35% 30%, var(--primary), #1c5e44); color: #fff; font-size: 2rem;
  box-shadow: 0 6px 24px rgba(46,125,91,0.4); transition: transform 0.15s; }
.jarvis-orb:active { transform: scale(0.94); }
.jarvis-status { font-size: 0.95rem; }
.jarvis-convo { display: flex; flex-direction: column; gap: 8px; margin-top: var(--space-3); }
.jline { padding: 8px 12px; border-radius: 12px; line-height: 1.4; max-width: 90%; }
.jline-pm { background: var(--surface); align-self: flex-end; }
.jline-jarvis { background: var(--primary-container); color: var(--text); align-self: flex-start; }

/* --- Decisions log --- */
.decision-add { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-bottom: var(--space-3); }
.decision-add input[type=text], .decision-add select, .decision-add input[type=date] {
  padding: 6px 8px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); color: var(--text); }
.decide-form { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.decide-form input { padding: 4px 7px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); color: var(--text); font-size: 0.8rem; }

/* --- Document page image lightbox --- */
.lb-overlay { position: fixed; inset: 0; z-index: 1000; background: rgba(0,0,0,0.93); display: flex; flex-direction: column; }
.lb-overlay[hidden] { display: none; }
.lb-close { position: fixed; top: 12px; right: 12px; z-index: 1001; width: 46px; height: 46px; border-radius: 50%; border: none; background: rgba(255,255,255,0.16); color: #fff; font-size: 1.6rem; line-height: 1; cursor: pointer; }
.lb-close:hover { background: rgba(255,255,255,0.32); }
.lb-stage { flex: 1; overflow: auto; display: flex; align-items: center; justify-content: center; -webkit-overflow-scrolling: touch; padding: 8px; }
.lb-img { display: block; }
.lb-img.fit { max-width: 96vw; max-height: 86vh; object-fit: contain; cursor: zoom-in; margin: auto; }
.lb-img.zoom { max-width: none; max-height: none; width: auto; cursor: zoom-out; }
.lb-caption { color: #ddd; text-align: center; padding: 10px; font-size: 0.85rem; }

/* --- Collapsible dashboard sections --- */
.dash-section { margin-top: var(--space-6); }
.dash-section > summary {
  font-family: var(--font-headline); font-weight: 700; font-size: 1.25rem;
  letter-spacing: -0.02em; cursor: pointer; list-style: none;
  display: flex; align-items: center; gap: 8px; padding: 4px 0; user-select: none;
}
.dash-section > summary::-webkit-details-marker { display: none; }
.dash-section > summary::before {
  content: "\25B8"; color: var(--text-muted); font-size: 0.85em; transition: transform 0.15s;
}
.dash-section[open] > summary::before { transform: rotate(90deg); }

/* --- Wider, horizontally-scrollable look-ahead calendar columns --- */
.cal-grid { grid-template-columns: repeat(7, minmax(200px, 1fr)); overflow-x: auto; padding-bottom: 8px; }
@media (max-width: 720px) {
  .cal-grid { grid-template-columns: repeat(7, 200px); gap: 6px; }
  .cal-cell { min-height: 96px; }
  .cal-item { font-size: 0.72rem; }
}

/* --- Upload modal --- */
.upload-form { display: flex; flex-direction: column; gap: 10px; }
.upload-form label { display: flex; flex-direction: column; gap: 3px; font-size: 0.85rem; color: var(--text-muted); }
.upload-form select, .upload-form input[type=file] { padding: 7px 8px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); color: var(--text); }
.upload-note { font-size: 0.78rem; }
.upload-preview-list { padding-left: 18px; display: flex; flex-direction: column; gap: 4px; }

/* --- Inline link-style button (e.g. vendor name in the brief) --- */
.link-like { background: none; border: none; padding: 0; margin: 0; font: inherit; color: var(--primary); cursor: pointer; text-decoration: underline; text-underline-offset: 2px; }
.link-like:hover { color: var(--text); }

/* --- Contact card popup --- */
.contact-card-actions { display: flex; flex-direction: column; gap: 8px; margin: var(--space-3) 0; }
.contact-card-actions .btn-primary { text-align: center; }
.contact-card-email { font-size: 0.8rem; word-break: break-all; }

/* ---- Gantt (schedule intelligence) ---- */
.gantt{position:relative;overflow-x:auto;border:1px solid #2a3142;border-radius:8px;margin-top:10px}
/* --gantt-min is sized server-side to the schedule length (px/day by zoom) so a
   14-month schedule scrolls horizontally instead of compressing to slivers. */
/* The axis lives OFFSET by the label rail so tick/today percentages line up
   with bar percentages (bars are %-of-track, not %-of-full-row). */
.gantt-axis{position:relative;height:22px;border-bottom:1px solid #2a3142;
  margin-left:220px;min-width:calc(var(--gantt-min,600px) - 220px)}
.gantt-tick{position:absolute;font-size:10px;color:#8a93a6;border-left:1px solid #1c2230;padding-left:3px;top:0;height:9999px}
.gantt-today{position:absolute;top:0;height:9999px;width:2px;background:#0DD7F2;z-index:6}
.gantt-rows{position:relative;min-width:var(--gantt-min,600px)}
.gantt-row{display:grid;grid-template-columns:220px 1fr;height:26px;align-items:center;border-bottom:1px solid #1c2230}
.gantt-row.summary{font-weight:700;background:#11151f}
.gantt-label{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:12px;padding-right:6px;
  position:sticky;left:0;z-index:4;background:var(--sh-bg,#0B0F1A);height:100%;display:flex;align-items:center}
.gantt-row.summary .gantt-label{background:#11151f}
@media (max-width:600px){
  .gantt-row{grid-template-columns:132px 1fr}
  .gantt-label{font-size:11px}
  .gantt-axis{margin-left:132px;min-width:calc(var(--gantt-min,600px) - 132px)}
}
.gantt-track{position:relative;height:100%}
.gantt-bar{position:absolute;top:5px;height:16px;border-radius:4px;font-size:10px;cursor:pointer;overflow:hidden;z-index:2}
.gantt-bar.normal{background:#3b82f6}
.gantt-bar.crit{background:#ef4444}
.gantt-bar.ghost{background:transparent;border:1px dashed #5a6376;cursor:default;z-index:1}
.gantt-bar.proj{background:repeating-linear-gradient(45deg,#f59e0b,#f59e0b 5px,#c97f08 5px,#c97f08 10px)}
.gantt-bar .fill{position:absolute;left:0;top:0;bottom:0;background:rgba(255,255,255,.28)}
.gantt-bar .vlabel{position:relative;padding:0 4px;color:#eaf2ff;line-height:16px}
.gantt-bar .wx{position:absolute;right:1px;top:-1px}
.gantt-arrows{position:absolute;inset:0;width:100%;height:100%;pointer-events:none;overflow:visible;z-index:3}
.gantt-link{fill:none;stroke:#8a93a6;stroke-width:1.3;stroke-dasharray:3 2}
.gantt-zoom .btn-sm.on{background:#0DD7F2;color:#041018}

/* ---- Offline / network status (PWA) ---- */
.net-status{display:inline-flex;align-items:center;gap:5px;font-size:12px;color:#8a93a6;vertical-align:middle}
.net-status .dot{width:8px;height:8px;border-radius:50%;background:#10B981;display:inline-block}
.net-status.offline .dot{background:#f59e0b}
.net-status.offline .net-label{color:#f59e0b}
.net-pending{background:#f59e0b;color:#1a1206;border-radius:999px;padding:1px 7px;font-size:11px}
.net-toast{position:fixed;bottom:16px;left:50%;transform:translateX(-50%);background:#161a26;border:1px solid #2a3142;color:#eaf2ff;padding:8px 14px;border-radius:8px;z-index:9999;font-size:13px}
.net-toast-err{background:#2a1215;border-color:#93000a;color:#ffdad6}

/* ================================================================
   DIRECTION C SHELL (2026-07 redesign) — app bar, drawer, daily loop,
   hero, alert cards, jump tiles. All on the --sh-* night-shift tokens.
   ================================================================ */

/* App bar: menu · title · net dot · avatar */
header.appbar{flex-direction:row;align-items:center;gap:10px;height:56px;
  padding:0 12px;background:rgba(11,15,26,.86);backdrop-filter:blur(8px)}
.ab-menu{width:42px;height:42px;min-width:42px;border-radius:12px;border:0;background:transparent;
  color:var(--sh-ink);display:flex;align-items:center;justify-content:center;cursor:pointer}
.ab-title{flex:1;margin:0;font-family:Manrope,sans-serif;font-size:18px;font-weight:700;
  color:var(--sh-ink);letter-spacing:-.01em}
.ab-avatar{width:42px;height:42px;min-width:42px;border-radius:50%;border:1px solid var(--sh-line);
  background:linear-gradient(150deg,#1d2740,#121728);color:var(--sh-cyan);
  font-family:Manrope,sans-serif;font-weight:700;font-size:15px;
  display:flex;align-items:center;justify-content:center;text-decoration:none}

/* Section eyebrow (Space Grotesk "machine" microcopy) */
.td-eyebrow{font-family:'Space Grotesk',monospace;font-size:11px;letter-spacing:.14em;
  text-transform:uppercase;color:var(--sh-dim);margin:0 0 6px}

/* The daily loop stepper */
.loop-row{display:flex;align-items:stretch;gap:6px}
.loop-step{flex:1;display:flex;flex-direction:column;align-items:center;justify-content:center;
  gap:6px;padding:11px 2px;border-radius:12px;border:1px solid var(--sh-line);
  background:transparent;color:var(--sh-dim);font-size:10.5px;font-weight:600;
  font-family:inherit;white-space:nowrap;text-decoration:none;cursor:pointer;min-height:64px}
.loop-step .material-symbols-outlined{font-size:20px}
.loop-step.on{border-color:var(--sh-cyan);background:rgba(13,215,242,.08);color:var(--sh-cyan)}
.loop-sep{align-self:center;color:var(--sh-line);font-size:16px}

/* Hero greeting card */
.hero-card{border-radius:18px;border:1px solid var(--sh-line);
  background:linear-gradient(160deg,#161B2A,#1B2336);padding:18px}
.hero-card h1{font-family:Manrope,sans-serif;font-size:23px;font-weight:700;
  letter-spacing:-.01em;margin:4px 0 10px}
.hero-stats{display:flex;gap:16px;margin-bottom:14px;font-size:13px;font-weight:600}
.hero-stats .hs{text-decoration:none}
.hs.red{color:var(--sh-red)} .hs.cyan{color:var(--sh-cyan)} .hs.amber{color:var(--sh-amber)}
.hs.zero{color:var(--sh-dim)}
.hero-cta{width:100%;min-height:48px;border-radius:12px;border:0;background:var(--sh-cyan);
  color:#041018;font-weight:700;font-size:14px;display:flex;align-items:center;
  justify-content:center;gap:7px;cursor:pointer}
.hero-cta .material-symbols-outlined{font-size:20px}

/* Up next row */
.upnext-row{display:flex;align-items:center;gap:12px;border-radius:12px;
  border:1px solid var(--sh-line);background:var(--sh-card);padding:13px 14px;
  min-height:64px;color:var(--sh-ink)}
.un-link{display:flex;align-items:center;gap:12px;flex:1;min-width:0;text-decoration:none;color:inherit}
.un-ic{width:38px;height:38px;min-width:38px;border-radius:10px;background:rgba(13,215,242,.12);
  color:var(--sh-cyan);display:flex;align-items:center;justify-content:center}
.un-ic .material-symbols-outlined{font-size:21px}
.un-bd{flex:1;display:flex;flex-direction:column;gap:2px;min-width:0}
.un-bd b{font-size:14.5px;font-weight:600}
.un-sub{font-family:'Space Grotesk',monospace;font-size:12px;color:var(--sh-dim)}
.un-go{color:var(--sh-dim)}
/* Check-in pin — small tap target next to the up-next project (replaces old full-width button) */
.un-pin-form{flex:none;margin:0;line-height:0}
.un-pin{width:34px;height:34px;border-radius:9px;border:1px solid var(--sh-line);
  background:rgba(13,215,242,.12);color:var(--sh-cyan);cursor:pointer;
  display:flex;align-items:center;justify-content:center}
.un-pin .material-symbols-outlined{font-size:19px}
.un-pin:active{background:rgba(13,215,242,.22)}

/* Project-detail vitals row (only trustworthy tiles: timeline, target, counts) */
.pj-vitals{display:flex;flex-wrap:wrap;gap:9px;margin-top:12px}
.pjv{flex:1;min-width:84px;background:var(--sh-card);border:1px solid var(--sh-line);
  border-radius:12px;padding:9px 11px;display:flex;flex-direction:column;gap:2px}
.pjv-val{font-family:Manrope,sans-serif;font-size:16.5px;font-weight:800;color:var(--sh-ink);line-height:1.15}
.pjv-lbl{font-family:'Space Grotesk',monospace;font-size:9.5px;letter-spacing:.05em;
  text-transform:uppercase;color:var(--sh-dim)}
.pjv-bar{height:4px;border-radius:99px;background:rgba(255,255,255,.08);overflow:hidden;margin-top:5px}
.pjv-bar>span{display:block;height:100%;background:var(--sh-cyan);border-radius:99px}

/* Project-detail "Needs you" attention card (attention-first overview) */
.pj-attn{display:flex;align-items:flex-start;gap:10px;border-radius:14px;padding:13px 15px;
  margin:2px 0 4px;font-size:13.5px;line-height:1.4}
.pj-attn .material-symbols-outlined{font-size:20px;flex:none;margin-top:1px}
.pj-attn b{display:block;font-size:14.5px;font-weight:700;margin-bottom:2px;color:var(--sh-ink)}
.pj-attn.red{background:rgba(239,68,68,.10);border:1px solid rgba(239,68,68,.32);color:#fca5a5}
.pj-attn.red .material-symbols-outlined{color:var(--sh-red)}
.pj-attn.amber{background:rgba(245,158,11,.10);border:1px solid rgba(245,158,11,.32);color:#ffd9a0}
.pj-attn.amber .material-symbols-outlined{color:var(--sh-amber)}
.pj-attn.cyan{background:rgba(13,215,242,.09);border:1px solid rgba(13,215,242,.28);color:#9be9f7}
.pj-attn.cyan .material-symbols-outlined{color:var(--sh-cyan)}
/* Collapsible Project Facts (declutters the overview) */
.facts-fold>summary{cursor:pointer;list-style:none;display:flex;align-items:center;gap:6px}
.facts-fold>summary::-webkit-details-marker{display:none}
.facts-fold>summary h3{display:inline;margin:0}
.facts-fold>summary h3::after{content:"▸";color:var(--sh-dim);font-weight:400;margin-left:6px}
.facts-fold[open]>summary h3::after{content:"▾"}
/* Task list: priority heat + overdue cue (reuses .prio-dot colors) */
.task-title .prio-dot{margin-right:6px;vertical-align:middle}
.task-overdue{color:var(--sh-red)}
.overdue-tag{display:inline-block;margin-left:6px;font-size:.68rem;font-weight:700;color:var(--sh-red);
  background:rgba(239,68,68,.12);border-radius:999px;padding:1px 7px;vertical-align:middle}
/* Editable task row: left checkbox completes · inline description · on-change due date */
.task-table .col-check{width:36px;text-align:center}
.task-check{width:19px;height:19px;cursor:pointer;accent-color:var(--sh-cyan,#0DD7F2);vertical-align:middle}
.task-table .col-icon{width:38px;white-space:nowrap}
.col-title .task-title-edit{width:100%;min-width:120px;background:transparent;border:1px solid transparent;
  border-radius:7px;color:inherit;font:inherit;padding:6px 8px;cursor:text}
.col-title .task-title-edit:hover{border-color:var(--sh-line,#2D3548)}
.col-title .task-title-edit:focus{outline:none;border-color:var(--sh-cyan,#0DD7F2);background:rgba(13,215,242,.06)}
.task-date-edit{background:var(--sh-card,#161B2A);border:1px solid var(--sh-line,#2D3548);border-radius:7px;
  color:inherit;font:inherit;padding:5px 7px;cursor:pointer;color-scheme:dark}
.task-date-edit:focus{outline:none;border-color:var(--sh-cyan,#0DD7F2)}
.task-table .col-actions{white-space:nowrap;text-align:right}
.task-row.completed .task-title.done{opacity:.6;text-decoration:line-through}
/* Priority dropdown (right of due date) — coloured by current priority */
.task-table .col-prio{white-space:nowrap}
.task-prio-edit{background:var(--sh-card,#161B2A);border:1px solid var(--sh-line,#2D3548);border-radius:7px;
  color:inherit;font:inherit;padding:5px 6px;cursor:pointer;color-scheme:dark;text-transform:capitalize}
.task-prio-edit:focus{outline:none;border-color:var(--sh-cyan,#0DD7F2)}
.task-prio-edit.prio-sel-urgent{color:#fca5a5;border-color:rgba(239,68,68,.5)}
.task-prio-edit.prio-sel-high{color:#ffd9a0;border-color:rgba(245,158,11,.5)}
.task-prio-edit.prio-sel-normal{color:var(--sh-dim,#8A93A6)}
.task-prio-edit.prio-sel-low{color:var(--sh-dim,#8A93A6);opacity:.85}

/* Guided morning brief — per-task voice/tap stepper */
#gb-root{max-width:560px;margin:0 auto;padding:4px 2px 100px}
.gb-top{display:flex;align-items:center;gap:12px;padding:6px 2px}
.gb-back{color:var(--sh-dim,#8A93A6);text-decoration:none;font-size:22px;line-height:1}
.gb-phase{font-family:'Space Grotesk',monospace;font-size:12px;letter-spacing:.14em;text-transform:uppercase;color:var(--sh-dim,#8A93A6);flex:1}
.gb-progress-num{font-family:'Space Grotesk',monospace;font-size:12px;color:var(--sh-dim,#8A93A6)}
.gb-bar{height:4px;border-radius:99px;background:rgba(255,255,255,.08);overflow:hidden;margin:4px 2px 18px}
#gb-bar-fill{display:block;height:100%;width:0;background:var(--sh-cyan,#0DD7F2);border-radius:99px;transition:width .3s ease}
.gb-card{background:var(--sh-card,#161B2A);border:1px solid var(--sh-line,#2D3548);border-radius:18px;padding:22px 20px}
.gb-eyebrow{font-family:'Space Grotesk',monospace;font-size:11px;letter-spacing:.06em;text-transform:uppercase;color:var(--sh-dim,#8A93A6);margin:0 0 8px}
.gb-title{font-family:Manrope,sans-serif;font-size:23px;font-weight:800;line-height:1.22;letter-spacing:-.01em;margin:0 0 10px;color:var(--sh-ink,#ECF1F8)}
.gb-meta{margin:0 0 18px;font-size:13.5px}
.gb-overdue{color:#fca5a5;font-weight:600}
.gb-duetoday{color:var(--sh-cyan,#0DD7F2);font-weight:600}
.gb-actions{display:flex;flex-wrap:wrap;gap:10px}
.gb-act{flex:1 1 46%;min-height:52px;border-radius:12px;border:1px solid var(--sh-line,#2D3548);background:rgba(255,255,255,.03);
  color:var(--sh-ink,#ECF1F8);font-size:15px;font-weight:600;cursor:pointer;display:flex;align-items:center;justify-content:center;gap:7px}
.gb-act:active{transform:translateY(1px)}
.gb-act.gb-done{background:var(--sh-cyan,#0DD7F2);color:#04222a;border-color:transparent}
.gb-act.gb-skip{flex-basis:100%;background:transparent;color:var(--sh-dim,#8A93A6)}
.gb-resched{margin-top:14px;font-size:13px;color:var(--sh-dim,#8A93A6)}
.gb-resched input{margin-left:8px;background:var(--sh-bg,#0B0F1A);border:1px solid var(--sh-line,#2D3548);border-radius:8px;color:inherit;padding:6px 8px;color-scheme:dark}
.gb-capture{display:flex;gap:10px;flex-wrap:wrap;margin:6px 0 18px}
.gb-cap{flex:1;min-width:96px;display:flex;flex-direction:column;align-items:center;gap:5px;padding:14px 8px;border-radius:12px;
  border:1px solid var(--sh-line,#2D3548);background:rgba(255,255,255,.03);color:var(--sh-ink,#ECF1F8);text-decoration:none;font-size:12.5px}
.gb-cap .material-symbols-outlined{font-size:22px;color:var(--sh-cyan,#0DD7F2)}
.gb-start{display:flex;align-items:center;justify-content:center;min-height:52px;border-radius:12px;background:var(--sh-cyan,#0DD7F2);color:#04222a;font-weight:800;font-size:16px;text-decoration:none}
.gb-dock{display:flex;align-items:center;gap:12px;margin:18px auto 0;max-width:560px}
.gb-status{flex:1;font-size:13px;color:var(--sh-dim,#8A93A6)}
.gb-mic{width:52px;height:52px;min-width:52px;border-radius:50%;border:none;background:var(--sh-cyan,#0DD7F2);color:#04222a;font-size:22px;cursor:pointer}

/* Warning alert cards */
.alert-card{border-radius:14px;border:1px solid rgba(245,158,11,.4);
  background:rgba(245,158,11,.08);padding:14px;margin-bottom:10px}
.ac-head{display:flex;gap:11px;margin-bottom:12px}
.ac-ic{color:var(--sh-amber);font-size:21px}
.ac-bd{display:flex;flex-direction:column;gap:3px}
.ac-bd b{font-size:14px;font-weight:600}
.ac-sub{font-size:12.5px;color:var(--sh-dim);line-height:1.4}
.ac-acts{display:flex;gap:8px}
.ac-ghost,.ac-primary{flex:1;min-height:44px;border-radius:10px;font-size:13px;font-weight:600;
  display:flex;align-items:center;justify-content:center;cursor:pointer;text-decoration:none}
.ac-ghost{border:1px solid var(--sh-line);background:transparent;color:var(--sh-ink)}
.ac-primary{border:0;background:var(--sh-cyan);color:#041018;font-weight:700}

/* Jump-to tiles */
.jump-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:8px}
.jump-tile{display:flex;flex-direction:column;align-items:center;gap:6px;padding:12px 4px;
  border-radius:12px;border:1px solid var(--sh-line);background:var(--sh-card);
  color:var(--sh-dim);font-size:11px;font-weight:600;text-decoration:none;min-height:64px;
  justify-content:center}
.jump-tile .material-symbols-outlined{font-size:21px;color:var(--sh-cyan)}

/* Drawer */
#drawer-mount .drawer-scrim{position:fixed;inset:0;background:rgba(4,6,12,.62);z-index:80}
#drawer-mount .drawer-panel{position:fixed;left:0;top:0;bottom:0;width:min(316px,86vw);
  background:#0E1320;border-right:1px solid var(--sh-line);z-index:81;
  display:flex;flex-direction:column}
.drawer-head{display:flex;align-items:center;gap:11px;padding:18px 16px 14px;
  border-bottom:1px solid var(--sh-line)}
.dw-avatar{width:42px;height:42px;border-radius:50%;border:1px solid var(--sh-line);
  background:linear-gradient(150deg,#1d2740,#121728);color:var(--sh-cyan);
  font-family:Manrope,sans-serif;font-weight:700;display:flex;align-items:center;
  justify-content:center}
.dw-id{flex:1;display:flex;flex-direction:column;gap:1px}
.dw-id b{font-size:14px}
.dw-org{font-size:11.5px;color:var(--sh-dim)}
.dw-live{font-size:10.5px;font-weight:600}
.dw-live.ok{color:var(--sh-green)} .dw-live.warn{color:var(--sh-amber)}
.drawer-body{flex:1;overflow-y:auto;padding:14px 12px}
.dw-group{font-family:'Space Grotesk',monospace;font-size:10px;letter-spacing:.16em;
  text-transform:uppercase;color:#5d6473;margin:12px 8px 5px}
.dw-item{display:flex;align-items:center;gap:13px;padding:9px 8px;border-radius:9px;
  color:var(--sh-ink);text-decoration:none;min-height:44px}
.dw-item .material-symbols-outlined{font-size:21px;color:var(--sh-dim)}
.dw-item.on{background:rgba(13,215,242,.10)}
.dw-item.on,.dw-item.on .material-symbols-outlined{color:var(--sh-cyan)}
.dw-label{flex:1;font-size:13.5px;font-weight:500}
.dw-count{font-family:'Space Grotesk',monospace;font-size:11px;font-weight:700}
.dw-count.red{color:var(--sh-red)} .dw-count.amber{color:var(--sh-amber)}
.dw-foot{border-top:1px solid var(--sh-line);padding:14px 20px;border-radius:0}

/* The Menu tab is a <button> — strip UA chrome so it matches the anchor tabs */
button.shell-tab{background:transparent;border:0;font-family:inherit;cursor:pointer;padding:0}

/* HTMX request-in-flight indicators: define explicitly so the "Sorting…" /
   "Asking…" spinners never depend on the library's injected default styles. */
.htmx-indicator{opacity:0;transition:opacity 200ms ease-in}
.htmx-request .htmx-indicator,
.htmx-request.htmx-indicator{opacity:1}

/* ---- Public client digest (/u/{token}) ---- */
.public-digest{background:#0b0e16}
.cd{max-width:560px;margin:20px auto;border:1px solid #2a3142;border-radius:14px;overflow:hidden;background:#0f1320}
.cd-hd{background:linear-gradient(135deg,#11151f,#1a2233);padding:20px}
.cd-hd .builder{font-size:12px;letter-spacing:.08em;text-transform:uppercase;color:#0DD7F2}
.cd-hd h1{margin:4px 0 2px;font-size:22px}
.cd-hd .wk{font-size:12px;opacity:.6}
.cd-body{padding:20px}
.cd-intro{font-style:italic;border-left:3px solid #0DD7F2;padding-left:12px;opacity:.9}
.cd-body h3{font-size:13px;text-transform:uppercase;letter-spacing:.05em;color:#8a93a6;margin:18px 0 8px}
.cd-photos{display:grid;grid-template-columns:1fr 1fr 1fr;gap:8px}
.cd-photos figure{margin:0}
.cd-photos img{width:100%;aspect-ratio:1;object-fit:cover;border-radius:6px}
.cd-photos figcaption{font-size:10px;opacity:.7}
.cd-decisions .by{color:#f59e0b;font-size:12px}
.cd-ft{border-top:1px solid #2a3142;padding:16px 20px;font-size:13px;background:#0c0f17}
.cd-ft .nm{font-weight:600}

/* ================= AI-first shell (P2) ================= */
:root{
  --sh-bg:#0B0F1A; --sh-card:#161B2A; --sh-line:#2D3548; --sh-cyan:#0DD7F2;
  --sh-amber:#F59E0B; --sh-red:#EF4444; --sh-green:#10B981;
  --sh-ink:#ECF1F8; --sh-dim:#8A93A6; --sh-tap:48px;
}
/* 150px clears the tab bar (76px) plus the floating mic button that hovers
   above it — the last content row (e.g. Client update) stays tappable. */
body.shell{background:var(--sh-bg);color:var(--sh-ink);padding-bottom:150px}
.shell-tabs{position:fixed;bottom:0;left:0;right:0;z-index:60;height:76px;
  display:flex;align-items:stretch;justify-content:space-around;padding:0 6px calc(env(safe-area-inset-bottom,0px));
  background:rgba(16,20,32,.95);backdrop-filter:blur(12px);border-top:1px solid var(--sh-line)}
.shell-tab{flex:1;min-width:var(--sh-tap);display:flex;flex-direction:column;align-items:center;justify-content:center;
  gap:3px;color:var(--sh-dim);text-decoration:none;font-size:11px;font-weight:600;letter-spacing:.04em;position:relative}
.shell-tab .ico{font-size:20px;line-height:1}
.shell-tab.on{color:var(--sh-cyan)}
.shell-tab:focus-visible{outline:2px solid var(--sh-cyan);outline-offset:-2px;border-radius:8px}
.shell-tab .bdg{position:absolute;top:10px;right:24%;background:var(--sh-red);color:#fff;font-size:10px;
  min-width:17px;height:17px;border-radius:9px;display:grid;place-items:center}
.shell-plus{width:58px;height:58px;align-self:center;margin:0 4px;border-radius:50%;border:none;cursor:pointer;
  background:var(--sh-cyan);color:#04222a;font-size:28px;font-weight:900;
  box-shadow:0 6px 22px rgba(13,215,242,.35);flex:none}
.shell-plus:focus-visible{outline:3px solid #fff}
@media(min-width:900px){
  body.shell{padding-bottom:0;padding-left:96px}
  .shell-tabs{top:0;bottom:0;left:0;right:auto;width:96px;height:auto;flex-direction:column;
    justify-content:center;gap:14px;border-top:none;border-right:1px solid var(--sh-line);padding:0}
  .shell-tab{flex:none;width:100%;min-height:64px}
  .shell-plus{margin:8px auto}
}
/* capture sheet */
.cap-sheet{position:fixed;inset:0;z-index:70;background:rgba(5,8,14,.6);display:flex;align-items:flex-end;justify-content:center}
.cap-body{background:var(--sh-card);border:1px solid var(--sh-line);border-radius:18px 18px 0 0;width:100%;max-width:520px;padding:18px 16px 26px}
.cap-grid{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-top:12px}
.cap-act{min-height:76px;background:var(--sh-bg);border:1px solid var(--sh-line);border-radius:14px;
  display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;color:var(--sh-ink);
  text-decoration:none;font-weight:600;font-size:13px}
/* today page */
.td-sect{margin:0 16px 16px;max-width:760px}
@media(min-width:900px){.td-sect{margin-left:auto;margin-right:auto}}
.td-status{display:flex;justify-content:space-between;align-items:center;padding:16px 16px 8px;font-size:13px;color:var(--sh-dim);max-width:760px;margin:0 auto}
.td-status .bell{position:relative;text-decoration:none;font-size:18px}
.td-status .bell .bdg{position:absolute;top:-6px;right:-8px;background:var(--sh-red);color:#fff;font-size:10px;min-width:16px;height:16px;border-radius:8px;display:grid;place-items:center}
.brief-hero{background:linear-gradient(160deg,var(--sh-card),#1B2336);border:1px solid var(--sh-line);border-radius:18px;padding:18px}
.brief-hero h1{font-size:24px;margin-bottom:10px}
.brief-row{display:flex;align-items:center;gap:16px}
.brief-play{width:64px;height:64px;border-radius:50%;border:none;background:var(--sh-cyan);color:#04222a;cursor:pointer;
  display:grid;place-items:center;font-size:26px;box-shadow:0 0 24px rgba(13,215,242,.3);flex:none}
.brief-chips{display:flex;flex-wrap:wrap;gap:7px}
.bchip{padding:6px 12px;border-radius:99px;font-size:12.5px;font-weight:600;border:1px solid}
.bchip.red{color:#FFB4AB;border-color:#7a2e28;background:rgba(239,68,68,.12)}
.bchip.cyan{color:var(--sh-cyan);border-color:#15566b;background:rgba(13,215,242,.1)}
.bchip.amber{color:#FFD9A0;border-color:#6b5500;background:rgba(245,158,11,.12)}
.brief-plan{margin-top:14px;border-top:1px solid var(--sh-line);padding-top:12px}
.brief-plan .lbl{font-size:11px;letter-spacing:.14em;color:var(--sh-amber);font-weight:700}
.brief-plan ol{margin:8px 0 0 18px;font-size:14px;display:grid;gap:5px}
.risk-strip{background:#241c07;border:1px solid #6b5500;border-left:5px solid var(--sh-amber);border-radius:14px;
  padding:13px 15px;display:flex;align-items:center;gap:12px;color:var(--sh-ink);text-decoration:none}
.risk-strip p{font-size:13.5px;line-height:1.4;flex:1}
.risk-strip strong{color:var(--sh-amber)}
.up-next{background:var(--sh-card);border:1px solid var(--sh-line);border-radius:18px;overflow:hidden}
.up-next .bd{padding:14px 16px 16px}
.up-next h3{font-size:18px;margin-bottom:6px}
.up-next .meta{display:flex;gap:14px;color:var(--sh-dim);font-size:13px;margin-bottom:12px;flex-wrap:wrap}
.td-h{font-size:12px;letter-spacing:.16em;color:var(--sh-dim);font-weight:700;margin:0 0 9px 2px;text-transform:uppercase}
.route-rail{display:flex;gap:10px;overflow-x:auto;padding-bottom:4px;scrollbar-width:none}
.route-stop{min-width:150px;background:var(--sh-card);border:1px solid var(--sh-line);border-radius:14px;padding:12px;flex:none}
.route-stop .n{font-weight:900;color:#04222a;background:var(--sh-cyan);width:24px;height:24px;border-radius:7px;display:grid;place-items:center;font-size:13px;margin-bottom:8px}
.route-stop h4{font-size:14px}
.route-stop p{font-size:12px;color:var(--sh-dim);margin-top:3px}
.qa-grid{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.qa-act{min-height:82px;background:var(--sh-card);border:1px solid var(--sh-line);border-radius:14px;
  display:flex;flex-direction:column;align-items:center;justify-content:center;gap:7px;color:var(--sh-ink);
  text-decoration:none;font-weight:600;font-size:13.5px}
.qa-act .ic{font-size:22px}
.inbox-item{background:var(--sh-card);border:1px solid var(--sh-line);border-radius:12px;padding:12px 14px;margin-bottom:8px;font-size:13.5px}
.inbox-item .t{font-weight:700}
.inbox-item .b{color:var(--sh-dim);margin-top:2px}
.inbox-item a.t{color:var(--sh-ink);text-decoration:none;display:block;min-height:28px}
.inbox-item a.t .go{color:var(--sh-dim)}
.inbox-item .acts{margin-top:8px;display:flex;gap:8px;align-items:center}
.inbox-cal{font-size:18px;line-height:1;vertical-align:-4px;color:var(--sh-dim);font-variation-settings:'wght' 500}
#look-ahead,#brain-dump,#upload{scroll-margin-top:64px}  /* land cleanly below sticky header when deep-linked */
.usage-cards{display:grid;grid-template-columns:1fr 1fr;gap:10px;max-width:760px;margin-top:10px}
.ucard{background:var(--sh-card);border:1px solid var(--sh-line);border-radius:14px;padding:14px}
.ucard .un{font-size:24px;font-weight:800;color:var(--sh-ink)}
.ucard .ul{font-size:12px;color:var(--sh-dim);margin-top:3px;line-height:1.3}
.brief-chips a.bchip{text-decoration:none}
.alerts-fold summary{display:flex;align-items:center;gap:8px;cursor:pointer;list-style:none;
  margin-bottom:8px;min-height:var(--sh-tap)}
.alerts-fold summary::-webkit-details-marker{display:none}
.alerts-fold summary::after{content:"▾";color:var(--sh-dim);margin-left:auto;font-size:15px;
  transition:transform .15s}
.alerts-fold:not([open]) summary::after{transform:rotate(-90deg)}
.alerts-fold .bdg{background:var(--sh-red);color:#fff;font-size:11px;font-weight:700;min-width:18px;
  height:18px;border-radius:9px;display:grid;place-items:center;padding:0 5px}
.wrapup{background:linear-gradient(150deg,#1d1426,#241a30);border:1px solid #483561;border-radius:16px;padding:16px;
  display:flex;align-items:center;gap:14px;color:var(--sh-ink);text-decoration:none}
.wrapup .moon{font-size:28px}
.wrapup h3{font-size:16px}
.wrapup p{font-size:12.5px;color:var(--sh-dim);margin-top:2px}
.more-list{max-width:760px;margin:14px auto;padding:0 16px;display:grid;gap:9px}
.more-item{background:var(--sh-card);border:1px solid var(--sh-line);border-radius:12px;padding:15px 16px;
  color:var(--sh-ink);text-decoration:none;display:flex;align-items:center;gap:12px;font-weight:600;min-height:var(--sh-tap)}
.more-item .ic{font-size:19px}
.more-item .sub{font-weight:400;font-size:12px;color:var(--sh-dim);margin-top:1px}

/* projects grid (P3) */
.proj-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(250px,1fr));gap:12px}
.proj-card{background:var(--sh-card);border:1px solid var(--sh-line);border-radius:16px;padding:16px;
  color:var(--sh-ink);text-decoration:none;display:block;transition:transform .12s ease}
.proj-card:hover{transform:translateY(-2px);border-color:#3b465e}
.pc-head{display:flex;justify-content:space-between;align-items:center;margin-bottom:7px}
.pc-head code{color:var(--sh-cyan);font-weight:700}
.pc-flag{font-size:11px;color:var(--sh-amber);font-weight:700}
.proj-card h3{font-size:15px;margin-bottom:9px;line-height:1.35}
/* per-card "needs you" attention line */
.pc-attn{display:flex;align-items:center;gap:7px;margin:0 0 10px;font-size:12.5px;font-weight:500;line-height:1.35}
.pc-attn .material-symbols-outlined{font-size:17px;flex:none}
.pc-attn.red{color:#fca5a5}
.pc-attn.red .material-symbols-outlined{color:var(--sh-red)}
.pc-attn.amber{color:#ffd9a0}
.pc-attn.amber .material-symbols-outlined{color:var(--sh-amber)}
.pc-attn.cyan{color:#9be9f7}
.pc-attn.cyan .material-symbols-outlined{color:var(--sh-cyan)}
.pc-chips{display:flex;gap:6px;flex-wrap:wrap}
.pc-chip{font-size:11.5px;font-weight:600;color:var(--sh-dim);border:1px solid var(--sh-line);
  border-radius:99px;padding:4px 10px}
.pc-chip.warn{color:#FFD9A0;border-color:#6b5500;background:rgba(245,158,11,.1)}
/* workspace tabs (P3) */
.ws-tabs{display:flex;gap:4px;margin:0 16px 14px;max-width:760px;overflow-x:auto;scrollbar-width:none}
@media(min-width:900px){.ws-tabs{margin-left:auto;margin-right:auto}}
.ws-tab{flex:1;min-width:70px;min-height:44px;text-align:center;font-size:12.5px;font-weight:700;
  letter-spacing:.04em;color:var(--sh-dim);text-decoration:none;border:1px solid var(--sh-line);
  border-radius:10px;display:flex;align-items:center;justify-content:center;background:var(--sh-card)}
.ws-tab.on{color:#04222a;background:var(--sh-cyan);border-color:var(--sh-cyan)}
.ws-head{padding:14px 16px 8px;max-width:760px;margin:0 auto}
.ws-head h1{font-size:22px}
.ws-head .sub{font-size:13px;color:var(--sh-dim);margin-top:2px}
/* docked project ask bar (P3/P4) */
/* right padding clears the floating voice-mic FAB (bottom-right, ~58px + 1rem),
   which otherwise sits exactly on the ask button */
.askbar{position:fixed;bottom:84px;left:0;right:0;z-index:55;display:flex;justify-content:center;padding:0 88px 0 14px}
@media(min-width:900px){.askbar{left:96px;bottom:18px}}
.askbar-inner{display:flex;gap:9px;width:100%;max-width:680px;background:rgba(16,20,32,.94);
  backdrop-filter:blur(10px);border:1px solid var(--sh-line);border-radius:18px;padding:9px}
.askbar input{flex:1;min-height:44px;background:var(--sh-card);border:1px solid var(--sh-line);
  border-radius:12px;color:var(--sh-ink);padding:0 14px;font-size:14px}
.askbar button{min-width:46px;min-height:46px;border-radius:12px;border:none;background:var(--sh-cyan);
  color:#04222a;font-size:18px;cursor:pointer;font-weight:800}

/* Jarvis feed (P4) */
.jfeed{max-width:760px;margin:0 auto;padding:4px 16px 230px;display:flex;flex-direction:column;gap:12px}
.jrow{display:flex;flex-direction:column;gap:8px}
.jrow.user{align-items:flex-end}
.jrow.assistant{align-items:flex-start}
.jbubble{max-width:86%;padding:11px 15px;border-radius:16px;font-size:14.5px;line-height:1.5}
.jbubble.user{background:#1E2A45;border:1px solid #2c3b5e;border-bottom-right-radius:4px}
.jbubble.assistant{background:var(--sh-card);border:1px solid var(--sh-line);border-bottom-left-radius:4px}
.jbubble p{margin:0 0 6px}.jbubble p:last-child{margin:0}
.jbubble ul{margin:4px 0 6px 18px}
.jbubble code{background:#0d1322;border-radius:4px;padding:1px 5px;font-size:13px}
.jcard{max-width:86%;border-radius:14px;border:1px solid var(--sh-line);background:var(--sh-card);
  padding:13px 15px;font-size:13.5px}
.jcard.amber{border-left:4px solid var(--sh-amber)}
.jcard.cyan{border-left:4px solid var(--sh-cyan)}
.jcard.green{border-left:4px solid var(--sh-green)}
.jc-head{font-size:10.5px;letter-spacing:.14em;color:var(--sh-dim);font-weight:700;margin-bottom:5px}
.jc-title{font-weight:700;font-size:14.5px}
.jc-detail{color:var(--sh-dim);margin-top:4px;line-height:1.45}
.jc-plan{margin:8px 0 0 18px;display:grid;gap:4px}
.jc-acts{display:flex;gap:8px;margin-top:10px;flex-wrap:wrap}
.jc-btn{min-height:38px;padding:7px 14px;border-radius:10px;border:1px solid var(--sh-line);
  background:var(--sh-bg);color:var(--sh-ink);text-decoration:none;font-weight:600;font-size:12.5px;
  display:inline-flex;align-items:center;gap:5px}
.jc-btn.jc-approve{border-color:var(--sh-green);color:var(--sh-green)}
.jc-btn.jc-reject{border-color:var(--sh-amber);color:var(--sh-amber)}
.jc-btn:disabled{opacity:.5;pointer-events:none}
.jc-detail-err{color:var(--sh-amber);margin-top:4px;font-size:12.5px}
.jc-detail-err:empty{display:none}
.jdock-wrap{position:fixed;bottom:76px;left:0;right:0;z-index:55;
  background:linear-gradient(180deg,transparent,var(--sh-bg) 35%);padding:18px 14px 12px}
@media(min-width:900px){.jdock-wrap{left:96px;bottom:0}}
.jchips{display:flex;gap:8px;overflow-x:auto;max-width:680px;margin:0 auto 9px;scrollbar-width:none}
.jchip{flex:none;min-height:40px;padding:0 15px;border-radius:99px;border:1px solid var(--sh-line);
  background:var(--sh-card);color:var(--sh-ink);font-weight:600;font-size:12.5px;cursor:pointer}
.jmodel{flex:none;display:flex;align-items:center;gap:5px;min-height:40px;padding:0 10px 0 12px;
  border-radius:99px;border:1px solid var(--sh-line);background:var(--sh-card);font-size:12.5px}
.jmodel select{background:transparent;border:none;color:var(--sh-ink);font-weight:600;font-size:12.5px;
  cursor:pointer;outline:none;min-height:38px}
.jdock{display:flex;gap:9px;max-width:680px;margin:0 auto;align-items:center}
.jdock #jarvis-send,.jdock .jarvis-orb{flex:none}
.jdock input{flex:1;min-height:50px;background:var(--sh-card);border:1px solid var(--sh-line);
  border-radius:16px;color:var(--sh-ink);padding:0 16px;font-size:14.5px}
.jdock #jarvis-send{min-width:50px;min-height:50px;border-radius:14px;border:none;background:var(--sh-cyan);
  color:#04222a;font-size:18px;cursor:pointer;font-weight:800}
.jarvis-orb{width:58px;height:58px;border-radius:50%;border:none;background:radial-gradient(circle at 35% 30%, #7ee9fb, var(--sh-cyan) 65%);
  font-size:22px;cursor:pointer;box-shadow:0 0 24px rgba(13,215,242,.35);flex:none}
.jarvis-orb[aria-pressed="true"]{box-shadow:0 0 0 4px rgba(13,215,242,.18),0 0 30px rgba(13,215,242,.55)}
.jarvis-orb:disabled{cursor:not-allowed;filter:grayscale(.8);opacity:.48;box-shadow:none}
.jarvis-audio-resume{display:block;max-width:680px;margin:8px auto 0}
.jarvis-audio-resume[hidden]{display:none}
.jarvis-voice-disclosure{max-width:680px;margin:7px auto 0;color:var(--sh-dim);font-size:10.5px;line-height:1.35}
.jstatus{font-size:12.5px;color:var(--sh-dim);padding:4px 2px;animation:jpulse 1.6s ease-in-out infinite}
@keyframes jpulse{0%,100%{opacity:.55}50%{opacity:1}}
@media (prefers-reduced-motion:reduce){.jstatus{animation:none}}

.draft-banner{color:var(--sh-amber)}
.sel-room{font-size:12px;letter-spacing:.12em;text-transform:uppercase;color:var(--sh-dim);margin:14px 0 6px}
.sel-list{list-style:none;margin:0;padding:0}
.sel-row{display:flex;justify-content:space-between;gap:12px;padding:8px 0;border-bottom:1px solid var(--sh-line)}
.sel-row.is-draft{opacity:.85}
.sel-item{display:block;font-weight:600}
.sel-value{display:block;color:var(--sh-ink)}
.sel-spec{display:block;font-size:12px}
.sel-meta{display:flex;align-items:center;gap:8px;flex:none}

.del-status{font-size:12px;letter-spacing:.12em;text-transform:uppercase;color:var(--sh-dim);margin:14px 0 6px}
.del-list{list-style:none;margin:0;padding:0}
.del-row{display:flex;justify-content:space-between;gap:12px;padding:8px 0;border-bottom:1px solid var(--sh-line)}
.del-row.is-risk{border-left:3px solid var(--sh-amber);padding-left:8px}
.del-item{font-weight:600}
.del-vendor,.del-eta{margin-left:10px;font-size:13px}
.del-badge.warn{margin-left:10px;color:var(--sh-amber);font-weight:600;font-size:12px}
.del-add{display:flex;gap:8px;flex-wrap:wrap;margin-top:12px}
.del-add input{background:var(--sh-card);border:1px solid var(--sh-line);border-radius:8px;padding:8px;color:var(--sh-ink)}
