/*
 * occ-core.css — Open Care Connect Shared Stylesheet
 * Version: 5.0 | Refactored: 2026-04-06
 *
 * STRUCTURE
 * ─────────────────────────────────────────────────────────────────────────
 *  1.  CSS CUSTOM PROPERTIES (Design Tokens)
 *  2.  RESET & BASE STYLES
 *  3.  ACCESSIBILITY HELPERS
 *  4.  LAYOUT — header, footer, sidebar, main content
 *  5.  SIDEBAR NAVIGATION & PROGRESS
 *  6.  PANEL CARDS (shared: title, meta, note, section-heading)
 *  7.  FORM ELEMENTS (grids, groups, inputs, radio/checkbox)
 *  8.  TABLE SYSTEM (base, cl-table, consent-table, comp-table, dyn-table)
 *  9.  BUTTON SYSTEM
 * 10.  CALLOUT COMPONENTS (scenario, alert, source, what-this-means)
 * 11.  PRINT MODAL & OVERLAY
 * 12.  KNOWLEDGE CHECK ACCORDION
 * 13.  BADGE & LABEL SYSTEM
 * 14.  MODULE NAVIGATION & COMPLETION
 * 15.  LANDING PAGE & HOME OVERRIDES
 * 16.  TRAINING HUB (checklists, checklist table, summary)
 * 17.  SUPERVISION / PERFORMANCE FORM (tabs, selector, rating opts)
 * 18.  PARTICIPANT INTAKE WIZARD (steps sidebar, step panels)
 * 19.  SUPPORT WORKER LOG / TIMESHEET
 * 20.  RESPONSIVE, PRINT & REDUCED MOTION
 * ─────────────────────────────────────────────────────────────────────────
 */

/* ═══════════════════════════════════════════════════════════════════════
   1. CSS CUSTOM PROPERTIES (Design Tokens)
   ═══════════════════════════════════════════════════════════════════════ */
:root {
  /* Brand */
  --occ-primary: #5A189A;
  --occ-primary-dk: #240046;
  --occ-accent: #f97316;
  --occ-accent-hover: #ea580c;

  /* Surfaces */
  --occ-surface: #ffffff;
  --occ-bg: #f5f5f5;
  --occ-border: #e0d4f0;
  --occ-muted-bg: #f5f0ff;
  --occ-muted-border: #c4a0e0;

  /* Text */
  --occ-text: #1f2937;
  --occ-text-muted: #666;
  --occ-text-subtle: #999;

  /* Layout */
  --occ-header-h: 68px;
  --occ-shell-max: 1280px;
  --occ-sidebar-w: 280px;

  /* Sidebar */
  --occ-sidebar-bg: #240046;
  --occ-sidebar-active: rgba(249, 115, 22, 0.28);
  --occ-sidebar-hover: rgba(249, 115, 22, 0.16);

  /* Progress / buttons */
  --occ-progress-fill: #f97316;
  --occ-shadow: 0 2px 10px rgba(0, 0, 0, 0.07);
  --occ-shadow-lg: 0 6px 24px rgba(36, 0, 70, 0.14);

  /* Table */
  --occ-table-th-bg: #240046;

  /* Intake wizard token overrides (scope: .intake-page) */
  --int-bg: #F6F3EE;
  --int-surface: #FFFFFF;
  --int-border: #E0DAD2;
  --int-header: #1A2744;
  --int-primary: #C25E3A;
  --int-primary-dk: #9E4121;
  --int-primary-lt: #FAF0EB;
  --int-text: #1A1A2A;
  --int-text-muted: #6B6560;
  --int-text-subtle: #9B948E;
  --int-note-bg: #F5F0E8;
  --int-note-border: #C9A882;
  --int-input-bg: #FDFCFB;
  --int-shadow: 0 2px 10px rgba(26, 39, 68, 0.07), 0 1px 2px rgba(26, 39, 68, 0.04);
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --space-xs: 4px;
  --space-sm: 8px;
  --space-md: 16px;
  --space-lg: 24px;
  --space-xl: 40px;

}


/* ═══════════════════════════════════════════════════════════════════════
   2. RESET & BASE STYLES
   ═══════════════════════════════════════════════════════════════════════ */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Plus Jakarta Sans', 'Segoe UI', system-ui, sans-serif;
  background: var(--occ-bg);
  color: var(--occ-text);
  line-height: 1.6;
  padding-top: var(--occ-header-h);
}


/* ═══════════════════════════════════════════════════════════════════════
   3. ACCESSIBILITY HELPERS
   ═══════════════════════════════════════════════════════════════════════ */
.occ-skip-link {
  position: absolute;
  left: 12px;
  top: -44px;
  background: #111827;
  color: #fff;
  padding: 10px 14px;
  border-radius: 8px;
  z-index: 10000;
  text-decoration: none;
  font-size: 0.9rem;
}

.occ-skip-link:focus {
  top: 12px;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid rgba(249, 115, 22, 0.4);
  outline-offset: 2px;
}

button[disabled],
[aria-disabled="true"] {
  cursor: not-allowed !important;
  opacity: 0.6 !important;
}

input[readonly],
textarea[readonly] {
  background: #f5f5f5;
  color: #888;
  cursor: not-allowed;
}


/* ═══════════════════════════════════════════════════════════════════════
   4. LAYOUT — header, footer, sidebar, main content
   ═══════════════════════════════════════════════════════════════════════ */
/* ── Fixed header (default) ── */
header {
  background: linear-gradient(135deg, var(--occ-primary-dk) 0%, var(--occ-primary) 100%);
  color: #fff;
  padding: 0 36px;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 300;
  height: var(--occ-header-h);
  display: flex;
  align-items: center;
  gap: 16px;
  text-align: center !important;
}

header h1 {
  font-size: 1.45rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

header p {
  font-size: 0.88rem;
  opacity: 0.88;
}

/* Sticky compact header (.site-header variant used in supervision/log pages) */
.site-header {
  background: var(--occ-primary-dk);
  color: #fff;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  height: 64px;
  position: sticky;
  top: 0;
  z-index: 200;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
}

body:has(.site-header) {
  padding-top: 0;
}

.site-header h1 {
  font-family: 'Fraunces', Georgia, serif;
  font-size: 1.08rem;
  font-weight: 400;
  letter-spacing: 0.01em;
  opacity: 0.92;
  flex-shrink: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.header-back-btn,
.back-link {
  color: rgba(255, 255, 255, 0.75);
  font-size: 0.8rem;
  font-weight: 500;
  text-decoration: none;
  border: 1px solid rgba(255, 255, 255, 0.3);
  padding: 4px 12px;
  border-radius: 5px;
  white-space: nowrap;
  flex-shrink: 0;
  transition: color 0.15s, border-color 0.15s, background 0.15s;
}

.header-back-btn:hover,
.back-link:hover {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.55);
  background: rgba(255, 255, 255, 0.1);
}

.doc-badge {
  background: var(--occ-accent);
  color: #fff;
  font-size: 0.78rem;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 20px;
  white-space: nowrap;
  flex-shrink: 0;
}

footer,
.occ-system-footer {
  background: linear-gradient(135deg, var(--occ-primary-dk) 0%, var(--occ-primary) 100%);
  color: rgba(255, 255, 255, 0.75);
  text-align: center;
  font-size: 0.78rem;
  padding: 14px 24px;
}

.occ-system-footer {
  text-align: left;
  margin-top: 40px;
}

.occ-system-footer__inner {
  max-width: var(--occ-shell-max);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 12px 18px;
  justify-content: space-between;
  align-items: center;
}

.occ-system-footer__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 12px;
}

.occ-system-footer__meta span {
  opacity: 0.9;
}

.version-badge {
  font-size: 0.7em;
  color: rgba(255, 255, 255, 0.5);
  margin-left: 10px;
  vertical-align: middle;
}

/* ── Pathway container (sidebar + main) ── */
.pathway-container {
  display: flex;
  min-height: calc(100vh - var(--occ-header-h));
}

.main-content {
  margin-left: var(--occ-sidebar-w);
  padding: 40px 50px;
  background: var(--occ-surface);
  flex: 1;
  min-height: 100vh;
}

.module-page {
  display: none;
}

.module-page.active {
  display: block;
}


/* ═══════════════════════════════════════════════════════════════════════
   5. SIDEBAR NAVIGATION & PROGRESS
   ═══════════════════════════════════════════════════════════════════════ */
.sidebar {
  width: var(--occ-sidebar-w);
  background: var(--occ-sidebar-bg);
  color: #fff;
  padding: 20px;
  overflow-y: auto;
  position: fixed;
  top: var(--occ-header-h);
  left: 0;
  height: calc(100vh - var(--occ-header-h));
  z-index: 200;
  box-shadow: 2px 0 8px rgba(0, 0, 0, 0.12);
  scrollbar-width: thin;
}

.sidebar h3 {
  margin-bottom: 20px;
  font-size: 1em;
  border-bottom: 2px solid rgba(255, 255, 255, 0.2);
  padding-bottom: 10px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.sidebar ul {
  list-style: none;
}

.sidebar li {
  margin-bottom: 4px;
}

.sidebar a {
  color: rgba(255, 255, 255, 0.82);
  text-decoration: none;
  font-size: 0.88rem;
  display: block;
  padding: 8px 10px;
  border-radius: 5px;
  transition: background 0.2s;
}

.sidebar a:hover {
  background: var(--occ-sidebar-hover);
  color: #fff;
}

.sidebar a.active {
  background: var(--occ-sidebar-active);
  font-weight: 600;
  color: #fff;
}

.sidebar-section-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.5);
  margin: 18px 0 6px 2px;
}

.sidebar-tool-link {
  display: block;
  margin: 6px 0 0;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 6px;
  color: rgba(255, 255, 255, 0.88);
  font-size: 0.84rem;
  text-decoration: none;
  border: 1px solid rgba(255, 255, 255, 0.2);
  transition: background 0.2s;
}

.sidebar-tool-link:hover {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
}

.sidebar .back-btn {
  margin-top: 20px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: #fff;
  padding: 8px 16px;
  border-radius: 5px;
  cursor: pointer;
  font-size: 0.88rem;
  width: 100%;
  transition: background 0.2s;
  font-family: inherit;
}

.sidebar .back-btn:hover {
  background: rgba(255, 255, 255, 0.2);
}

.progress-section {
  margin-top: 20px;
  border-top: 2px solid rgba(255, 255, 255, 0.2);
  padding-top: 16px;
}

.progress-bar {
  width: 100%;
  height: 6px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 6px;
  overflow: hidden;
  margin-bottom: 6px;
}

.progress-fill {
  height: 100%;
  border-radius: 6px;
  background: var(--occ-progress-fill);
  width: 0%;
  transition: width 0.5s ease;
}

.progress-text {
  font-size: 0.76rem;
  color: rgba(255, 255, 255, 0.82);
}


/* ═══════════════════════════════════════════════════════════════════════
   6. PANEL CARDS — title, meta, note, section-heading
   ═══════════════════════════════════════════════════════════════════════ */
.panel-card {
  background: var(--occ-surface);
  border-radius: 12px;
  padding: 28px;
  box-shadow: var(--occ-shadow);
  border: 1px solid var(--occ-border);
  margin-bottom: 20px;
}

/* .panel-title can live in both supervision (OCC purple) and intake (warm navy).
   Base is purple; intake overrides via .intake-page scope in §18. */
.panel-title {
  font-family: 'Fraunces', Georgia, serif;
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--occ-primary-dk);
  margin-bottom: 4px;
  letter-spacing: -0.01em;
  line-height: 1.25;
}

.panel-meta {
  font-size: 0.76rem;
  color: var(--occ-text-subtle);
  margin-bottom: 18px;
  letter-spacing: 0.02em;
}

.panel-note {
  background: var(--occ-muted-bg);
  border-left: 4px solid var(--occ-primary);
  padding: 12px 16px;
  border-radius: 0 8px 8px 0;
  font-size: 0.85rem;
  color: #333;
  margin-bottom: 20px;
  line-height: 1.6;
}

.panel-note.alert-warning {
  border-color: var(--occ-accent);
  background: #fff8f0;
}

/* section-heading — single definition, consistent everywhere */
.section-heading {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--occ-primary);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 14px 0 8px;
  border-top: 2px solid var(--occ-muted-bg);
  margin-top: 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.section-heading:first-of-type {
  border-top: none;
  margin-top: 0;
}

/* Collapsible section heading (supervision toggle) */
.sh-toggle {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: none;
  letter-spacing: 0;
  background: none;
  border: 1.5px solid var(--occ-muted-border);
  color: var(--occ-primary);
  padding: 2px 10px;
  border-radius: 20px;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  transition: background 0.15s;
  font-family: inherit;
}

.sh-toggle:hover {
  background: var(--occ-muted-bg);
}

.section-heading.sh-hidden {
  color: #bbb;
}

.section-heading.sh-hidden .sh-toggle {
  color: #aaa;
  border-color: #ddd;
}

.sh-body.sh-collapsed {
  display: none;
}

.sh-na-note {
  font-size: 0.78rem;
  font-style: italic;
  color: #aaa;
  padding: 4px 0 8px;
  font-weight: 400;
  text-transform: none;
  letter-spacing: 0;
  display: none;
}

.section-heading.sh-hidden+.sh-na-note {
  display: block;
}

/* Module content area (training) */
.module-header {
  margin-bottom: 30px;
  border-bottom: 3px solid var(--occ-primary);
  padding-bottom: 20px;
}

.module-header h2 {
  font-size: 2rem;
  color: var(--occ-primary-dk);
  margin-bottom: 8px;
}

.module-code {
  color: #888;
  font-size: 0.9em;
}

.module-content {
  line-height: 1.85;
  max-width: 860px;
}

.module-content p {
  margin-bottom: 18px;
  color: #444;
}

.module-content h3 {
  color: var(--occ-primary-dk);
  margin: 30px 0 15px;
  font-size: 1.25em;
  border-left: 4px solid var(--occ-primary);
  padding-left: 12px;
}

.module-content strong {
  color: var(--occ-primary-dk);
}


/* ═══════════════════════════════════════════════════════════════════════
   7. FORM ELEMENTS
   ═══════════════════════════════════════════════════════════════════════ */
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.form-grid.three {
  grid-template-columns: 1fr 1fr 1fr;
}

.form-grid.full {
  grid-template-columns: 1fr;
}

/* .sel-grid — same as form-grid, used in supervision selector */
.sel-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 14px;
}

.form-group label {
  display: block;
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--occ-primary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 9px 12px;
  border: 1.5px solid var(--occ-border);
  border-radius: 6px;
  font-size: 0.92rem;
  font-family: inherit;
  color: var(--occ-text);
  background: var(--occ-surface);
  transition: border-color 0.2s, box-shadow 0.2s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--occ-primary);
  box-shadow: 0 0 0 3px rgba(90, 24, 154, 0.1);
}

.form-group textarea {
  resize: vertical;
  min-height: 80px;
}

.radio-group {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 4px;
}

.radio-opt {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.87rem;
  cursor: pointer;
  font-weight: 400;
}

.radio-opt input[type=radio],
.radio-opt input[type=checkbox] {
  accent-color: var(--occ-primary);
  width: 15px;
  height: 15px;
  cursor: pointer;
  flex-shrink: 0;
}

.radio-opt.centered {
  justify-content: center;
}

/* Sig blocks */
.sig-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-top: 10px;
}

.sig-block label {
  display: block;
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--occ-primary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 6px;
}

.sig-block input {
  width: 100%;
  padding: 9px 12px;
  border: none;
  border-bottom: 2px solid var(--occ-primary-dk);
  font-size: 0.9rem;
  font-family: inherit;
  background: transparent;
}

.sig-block input:focus {
  outline: none;
  border-bottom-color: var(--occ-accent);
}

/* Signature pad */
.sig-pad-container {
  margin-top: 8px;
}

.sig-pad-canvas {
  display: block;
  border: 2px solid var(--occ-border);
  border-radius: 6px;
  background: white;
  cursor: crosshair;
  width: 100%;
  height: 120px;
  margin-bottom: 10px;
  box-sizing: border-box;
  touch-action: none;
}

.sig-pad-canvas:focus {
  outline: 2px solid var(--occ-accent);
  outline-offset: 2px;
}

.sig-pad-controls {
  display: flex;
  gap: 8px;
  align-items: center;
}

.sig-btn-clear {
  padding: 8px 14px;
  font-size: 0.8rem;
  font-weight: 600;
  background: var(--occ-muted-bg);
  color: var(--occ-primary-dk);
  border: 1px solid var(--occ-border);
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s;
}

.sig-btn-clear:hover {
  background: var(--occ-primary-dk);
  color: white;
}

.sig-name-input {
  flex: 1;
  padding: 8px 12px;
  border: 1px solid var(--occ-border);
  border-radius: 4px;
  font-size: 0.85rem;
  font-family: inherit;
}

.sig-date-input {
  margin-top: 10px;
  width: 100%;
  padding: 9px 12px;
  border: 1px solid var(--occ-border);
  border-radius: 6px;
  font-size: 0.85rem;
  font-family: inherit;
  background: #fff;
}

.sig-name-input:focus {
  outline: none;
  border-color: var(--occ-accent);
  box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.12);
}

.sig-date-input:focus {
  outline: none;
  border-color: var(--occ-accent);
  box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.12);
}

/* Person-bar (worker log selector) */
.person-bar {
  background: var(--occ-surface);
  border-radius: 12px;
  padding: 20px 24px;
  margin-bottom: 24px;
  box-shadow: var(--occ-shadow);
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.person-bar label {
  font-weight: 700;
  color: var(--occ-primary-dk);
  font-size: 0.95rem;
  white-space: nowrap;
}

.person-bar select {
  flex: 1;
  min-width: 220px;
  padding: 10px 14px;
  border: 2px solid var(--occ-muted-border);
  border-radius: 8px;
  font-size: 0.95rem;
  color: var(--occ-primary-dk);
  background: var(--occ-muted-bg);
  appearance: none;
  cursor: pointer;
  outline: none;
  transition: border-color 0.2s;
  font-family: inherit;
}

.person-bar select:focus {
  border-color: var(--occ-primary);
}

.person-role {
  font-size: 0.83rem;
  color: var(--occ-primary);
  font-weight: 600;
  background: #ede9ff;
  padding: 6px 14px;
  border-radius: 20px;
  white-space: nowrap;
}

/* Resp list (service agreement) */
.resp-list {
  list-style: none;
  padding: 0;
  margin: 6px 0 14px;
}

.resp-list li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid var(--occ-border);
  font-size: 0.87rem;
  line-height: 1.55;
}

.resp-list li:last-child {
  border-bottom: none;
}

.resp-list input[type=checkbox] {
  margin-top: 2px;
  accent-color: var(--occ-primary);
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}


/* ═══════════════════════════════════════════════════════════════════════

/* ── Form section card ── */
.form-section {
  background: var(--occ-surface);
  border-radius: 10px;
  padding: 26px 32px;
  box-shadow: var(--occ-shadow);
  margin-bottom: 20px;
}

.form-section-header {
  display: flex;
  align-items: center;
  gap: 12px;
  border-bottom: 2px solid var(--occ-muted-bg);
  padding-bottom: 12px;
  margin-bottom: 18px;
}

.section-number {
  width: 32px;
  height: 32px;
  background: var(--occ-primary-dk);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85em;
  font-weight: 700;
  flex-shrink: 0;
}

/* ── Section show/hide toggle ── */
.section-hide-btn {
  margin-left: auto;
  background: none;
  border: 1.5px solid var(--occ-muted-border);
  color: var(--occ-primary);
  font-size: 0.78em;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 20px;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.15s, color 0.15s;
  flex-shrink: 0;
}

.section-hide-btn:hover {
  background: var(--occ-muted-bg);
}

.section.section-hidden .section-body {
  display: none;
}

.section.section-hidden {
  opacity: 0.7;
}

.section-na-banner {
  font-size: 0.83em;
  color: var(--occ-text-subtle);
  font-style: italic;
  padding: 6px 0 4px;
  display: none;
}

.section.section-hidden .section-na-banner {
  display: block;
}

.section.section-hidden .section-hide-btn {
  background: var(--occ-muted-bg);
  color: var(--occ-primary);
}

/* ── Utility doc/card helpers ── */
.doc-ref {
  font-size: 0.82em;
  color: var(--occ-text-subtle);
}

.intro-note {
  font-size: 0.92em;
  color: var(--occ-text-muted);
  margin-bottom: 12px;
}

.card-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--occ-muted-bg);
}

.card-panel-header h2 {
  margin: 0;
  border: none;
  padding: 0;
}

/* ── Role badge variants ── */
.role-badge--id {
  background: #f5ede0;
  color: #a04000;
}

.role-badge--type {
  background: #ede9ff;
  color: var(--occ-primary);
  padding: 2px 8px;
  border-radius: 10px;
  font-size: 0.78rem;
  font-weight: 600;
}

.role-badge--opt {
  background: #f0f0f0;
  color: #555;
  padding: 2px 8px;
  border-radius: 10px;
  font-size: 0.78rem;
  font-weight: 600;
}

/* ── Radio/rating misc ── */
.rating-opt span {
  font-size: 0.83rem;
  color: var(--occ-text-muted);
}

.radio-opt.centered {
  justify-content: center;
}

input.notes-after-radios {
  margin-top: 6px;
}

/* ── Table cell helpers ── */
.cell-row-num {
  width: 30px;
  color: #aaa;
  text-align: center;
}

.rating-input {
  width: 60px;
  padding: 4px 6px;
  border: 1.5px solid var(--occ-muted-border);
  border-radius: 6px;
  font-size: 0.86rem;
  text-align: center;
  font-family: inherit;
}

/* ── Record/recommendation row components ── */
.rec-section {
  margin: 12px 0;
}

.rec-section h4 {
  font-size: 0.88em;
  color: var(--occ-primary-dk);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 6px;
}

.rec-row {
  display: flex;
  gap: 10px;
  padding: 5px 0;
  border-bottom: 1px solid var(--occ-muted-bg);
  font-size: 0.88em;
}

.rec-placeholder {
  color: var(--occ-text-subtle);
  font-style: italic;
}

.rec-note-block {
  margin-top: 8px;
  padding: 8px 12px;
  background: #f9f6ff;
  border-radius: 4px;
  font-size: 0.87em;
  color: #333;
}

/* ── Week badge ── */
.current-week-badge {
  display: none;
  font-size: 0.78rem;
  background: #d4edda;
  color: #155724;
  padding: 4px 10px;
  border-radius: 12px;
  font-weight: 600;
}

.current-week-badge.visible {
  display: inline;
}

/* ── Card collapse helpers ── */
.card-hide-btn {
  background: none;
  border: 1.5px solid var(--occ-muted-border);
  color: var(--occ-primary);
  font-size: 0.75rem;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 20px;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.15s;
}

.card-hide-btn:hover {
  background: var(--occ-muted-bg);
}

.card-body-collapsible.card-collapsed {
  display: none;
}

.card-hidden-note {
  font-size: 0.82rem;
  color: var(--occ-text-subtle);
  font-style: italic;
  padding: 6px 0 2px;
  display: none;
}

.card-hidden-note.visible {
  display: block;
}

/*8. TABLE SYSTEM
   ═══════════════════════════════════════════════════════════════════════ */
.table-wrapper {
  overflow-x: auto;
  margin: 20px 0;
  border-radius: 6px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.07);
}

table {
  width: 100%;
  border-collapse: collapse;
  background: var(--occ-surface);
}

th {
  background: var(--occ-table-th-bg);
  color: #fff;
  padding: 10px 14px;
  text-align: left;
  font-weight: 600;
  font-size: 0.88rem;
}

td {
  padding: 10px 14px;
  border-bottom: 1px solid #e5e7eb;
  vertical-align: top;
  font-size: 0.92rem;
}

tr:last-child td {
  border-bottom: none;
}

tr:hover td {
  background: #f9f7ff;
}

/* Rounded-header shared helper for named tables */
.cl-table,
.consent-table,
.comp-table,
.dyn-table,
.obs-table,
.log-table,
.attend-table,
.action-table,
.checklist-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.86rem;
  margin: 8px 0 14px;
}

.cl-table th,
.consent-table th,
.comp-table th,
.dyn-table th,
.obs-table th,
.log-table th,
.attend-table th,
.action-table th {
  background: var(--occ-table-th-bg);
  color: #fff;
  padding: 9px 12px;
  text-align: left;
  font-size: 0.76rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

/* Rounded corners on first/last header cell */
.cl-table th:first-child,
.consent-table th:first-child,
.comp-table th:first-child,
.dyn-table th:first-child,
.obs-table th:first-child,
.log-table th:first-child {
  border-radius: 8px 0 0 0;
}

.cl-table th:last-child,
.consent-table th:last-child,
.comp-table th:last-child,
.dyn-table th:last-child,
.obs-table th:last-child,
.log-table th:last-child {
  border-radius: 0 8px 0 0;
}

.cl-table td,
.consent-table td,
.comp-table td,
.dyn-table td,
.obs-table td,
.log-table td,
.attend-table td,
.action-table td {
  padding: 8px 10px;
  border-bottom: 1px solid #ede9ff;
  vertical-align: middle;
}

.cl-table tr:last-child td,
.consent-table tr:last-child td,
.comp-table tr:last-child td,
.dyn-table tr:last-child td {
  border-bottom: none;
}

.cl-table tr:hover td,
.consent-table tr:hover td,
.comp-table tr:hover td,
.dyn-table tr:hover td,
.log-table tr:hover td {
  background: #faf8ff;
}

/* Inline inputs inside tables */
.cl-table input[type=text],
.cl-table input[type=date],
.dyn-table input,
.dyn-table select,
.dyn-table textarea,
.action-table input,
.action-table select {
  width: 100%;
  padding: 5px 8px;
  border: 1.5px solid var(--occ-border);
  border-radius: 5px;
  font-size: 0.84rem;
  font-family: inherit;
  background: #faf8ff;
  outline: none;
}

.cl-table input[type=text]:focus,
.cl-table input[type=date]:focus,
.dyn-table input:focus,
.dyn-table select:focus,
.action-table input:focus,
.action-table select:focus {
  border-color: var(--occ-primary);
  background: #fff;
}

.cl-table input[type=checkbox],
.consent-table input[type=radio] {
  accent-color: var(--occ-primary);
  width: 16px;
  height: 16px;
  cursor: pointer;
}

.consent-table .consent-yes,
.consent-table .consent-no {
  text-align: center;
  width: 55px;
}

/* Comp table specifics */
.comp-table .col-competency {
  width: 42%;
  font-weight: 500;
}

.comp-table .col-rating {
  width: 14%;
}

.comp-table .col-rating input[type=number],
.rating-input {
  width: 60px;
  padding: 5px 8px;
  border: 1.5px solid var(--occ-muted-border);
  border-radius: 6px;
  font-size: 0.88rem;
  text-align: center;
  font-family: inherit;
  outline: none;
}


.obs-table td {
  text-align: center;
}

.obs-table td:first-child {
  text-align: left;
}

.obs-table input[type=radio] {
  accent-color: var(--occ-primary);
  width: 16px;
  height: 16px;
  cursor: pointer;
}


.log-table td {
  line-height: 1.4;
}

.log-table .col-day {
  width: 80px;
  white-space: nowrap;
}

.log-table .col-cat {
  width: 160px;
}

.log-table .col-del {
  width: 48px;
  text-align: center;
}

/* Attend table */
.attend-table td {
  border-bottom: 1px solid #f0ebff;
  font-size: 0.9rem;
}

.attend-table tr:hover td {
  background: #f9f6ff;
}

.attend-table .name-cell {
  font-weight: 600;
  color: var(--occ-primary-dk);
}

.attend-table .role-cell {
  color: #666;
  font-size: 0.84rem;
}

.coi-cell input[type=text] {
  width: 100%;
  padding: 6px 10px;
  border: 1.5px solid var(--occ-border);
  border-radius: 4px;
  font-size: 0.83rem;
  font-family: inherit;
}

.coi-cell input:focus {
  outline: none;
  border-color: var(--occ-primary);
}

.coi-cell input:disabled {
  background: #f9f9f9;
  color: #aaa;
  border-color: #eee;
}

/* Action table */
.action-table th {
  background: var(--occ-primary);
}

/* Dynamic row control buttons */
.cell-row-num {
  width: 30px;
  color: #aaa;
  text-align: center;
}

.btn-del-row,
.btn-del,
.del-btn {
  background: none;
  border: none;
  color: #cc2222;
  font-size: 1rem;
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 4px;
  line-height: 1;
  transition: background 0.15s;
}

.btn-del-row:hover,
.btn-del:hover,
.del-btn:hover {
  background: #ffe5e5;
}


/* ═══════════════════════════════════════════════════════════════════════
   9. BUTTON SYSTEM
   ═══════════════════════════════════════════════════════════════════════ */
/* Primary CTA */
.btn-generate,
.gen-btn,
.btn-add,
.start-button {
  background: var(--occ-primary);
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 11px 26px;
  font-size: 0.92rem;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.15s, transform 0.1s;
}

.btn-generate:hover,
.gen-btn:hover,
.btn-add:hover {
  background: var(--occ-primary-dk);
}

.start-button:hover {
  background: var(--occ-primary-dk);
  transform: translateY(-2px);
}

.btn-generate:active,
.btn-add:active {
  transform: scale(0.98);
}

/* Accent CTA (generate/print) */
.btn-generate.review,
.btn-pdf,
.btn-print-now,
.mark-complete-button {
  background: var(--occ-accent);
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 11px 26px;
  font-size: 0.92rem;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.15s, transform 0.1s;
}

.btn-generate.review:hover,
.btn-pdf:hover,
.btn-print-now:hover {
  background: var(--occ-accent-hover);
}

.mark-complete-button:hover,
.back-home-button:hover {
  transform: translateY(-1px);
}

.mark-complete-button.completed {
  background: var(--occ-primary);
  opacity: 0.8;
  cursor: default;
}

.mark-complete-button.completed:hover {
  transform: none;
}

/* Secondary / outline */
.btn-secondary,
.btn-cancel-print,
.btn-clear,
.back-home-button {
  background: var(--occ-surface);
  color: var(--occ-primary);
  border: 2px solid var(--occ-primary);
  border-radius: 8px;
  padding: 10px 20px;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.15s;
}

.btn-secondary:hover {
  background: var(--occ-muted-bg);
}

.btn-cancel-print {
  border-color: #ddd;
  color: #555;
  padding: 11px 20px;
}

.btn-cancel-print:hover {
  background: #e8e8e8;
}

.btn-clear {
  color: #cc2222;
  border-color: #cc2222;
}

.btn-clear:hover {
  background: #fff0f0;
}

.back-home-button {
  background: #6b7280;
  color: #fff;
  border-color: #6b7280;
}

.back-home-button:hover {
  background: #4b5563;
}

/* Add-row */
.btn-add-row {
  background: var(--occ-muted-bg);
  color: var(--occ-primary);
  border: none;
  border-radius: 6px;
  padding: 7px 16px;
  font-size: 0.83rem;
  font-weight: 600;
  cursor: pointer;
  margin-top: 6px;
  font-family: inherit;
  transition: background 0.15s;
}

.btn-add-row:hover {
  background: #d0bfff;
}

/* ── Inline add button (compact variant used in form sections) ── */
.add-btn {
  background: var(--occ-primary);
  color: #fff;
  border: none;
  padding: 9px 20px;
  border-radius: 6px;
  font-size: 0.88em;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: inherit;
}

.add-btn:hover {
  background: var(--occ-primary-dk);
}

/* ── Button row layout helper ── */
.btn-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: flex-end;
}

.btn-row input[type="text"] {
  flex: 1;
}

.btn-row input[type="date"] {
  flex: 0 0 160px;
}

/* Next / Prev (intake wizard) */
.btn-next {
  background: var(--int-header);
  color: #fff;
  border: none;
  border-radius: 7px;
  padding: 11px 26px;
  font-size: 0.87rem;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.15s, transform 0.1s;
}

.btn-next:hover {
  background: #253355;
}

.btn-next:active {
  transform: scale(0.98);
}

.btn-prev {
  background: transparent;
  color: var(--int-text-muted);
  border: 1.5px solid var(--int-border);
  border-radius: 7px;
  padding: 9px 18px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: border-color 0.15s, color 0.15s, background 0.15s;
}

.btn-prev:hover {
  border-color: #999;
  color: var(--int-text);
  background: #FAF8F5;
}

/* Module navigation */
.module-nav-btn {
  display: inline-block;
  margin-top: 28px;
  padding: 10px 22px;
  border-radius: 6px;
  background: var(--occ-primary-dk);
  color: #fff;
  border: none;
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  font-family: inherit;
  transition: opacity 0.2s;
}

.module-nav-btn:hover {
  opacity: 0.88;
}

/* Week nav buttons (worker log) */
.btn-week {
  padding: 8px 16px;
  border: none;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.2s, transform 0.1s;
}

.btn-week:active {
  transform: scale(0.97);
}

.btn-week-prev,
.btn-week-next {
  background: #ede9ff;
  color: var(--occ-primary);
}

.btn-week-prev:hover,
.btn-week-next:hover {
  background: #d8ceff;
}

/* Add-btn variant for timesheet */
.btn-add {
  border-radius: 8px;
  padding: 11px 28px;
  font-size: 0.95rem;
}

.btn-add:hover {
  background: var(--occ-primary-dk);
}

/* Action bar row */
.action-bar {
  display: flex;
  gap: 12px;
  margin-top: 8px;
  flex-wrap: wrap;
}


/* ═══════════════════════════════════════════════════════════════════════
   10. CALLOUT COMPONENTS
   ═══════════════════════════════════════════════════════════════════════ */
.scenario-box {
  background: var(--occ-muted-bg);
  border-left: 5px solid var(--occ-primary);
  padding: 20px 25px;
  margin: 25px 0;
  border-radius: 0 6px 6px 0;
}

.scenario-title {
  font-weight: 700;
  color: var(--occ-primary-dk);
  margin-bottom: 10px;
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.alert-box {
  background: #fffbeb;
  border-left: 5px solid #f59e0b;
  padding: 20px 25px;
  margin: 25px 0;
  border-radius: 0 6px 6px 0;
}

.alert-title {
  font-weight: 700;
  color: #92400e;
  margin-bottom: 10px;
  font-size: 1rem;
}

.authorised-source {
  background: #e8f4f8;
  border-left: 5px solid #0288d1;
  padding: 18px 22px;
  margin: 25px 0;
  border-radius: 0 6px 6px 0;
  font-size: 0.92rem;
}

.authorised-source h4 {
  color: #01579b;
  margin-bottom: 8px;
  font-size: 0.95rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.what-this-means {
  background: linear-gradient(135deg, var(--occ-muted-bg), #ede0ff);
  border: 1px solid var(--occ-muted-border);
  padding: 22px 25px;
  margin: 25px 0;
  border-radius: 8px;
}

.what-this-means h4 {
  color: var(--occ-primary-dk);
  margin-bottom: 15px;
  font-size: 1.05rem;
}

.what-this-means ul {
  list-style: none;
  padding-left: 0;
}

.what-this-means li {
  padding: 6px 0 6px 22px;
  position: relative;
  color: #555;
  border-bottom: 1px solid rgba(0, 0, 0, 0.04);
}

.what-this-means li:last-child {
  border-bottom: none;
}

.what-this-means li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--occ-primary);
  font-weight: 700;
}

.shiftcare-note {
  background: #e8f4f8;
  border-left: 4px solid #0288d1;
  padding: 14px 18px;
  border-radius: 0 6px 6px 0;
  margin: 20px 0;
  font-size: 0.9rem;
  color: #01579b;
}

.occ-env-banner {
  margin-bottom: 18px;
  background: #eef6ff;
  color: #12324f;
  border: 1px solid #b8d6f2;
  border-left: 5px solid #2563eb;
  border-radius: 10px;
  padding: 14px 16px;
  font-size: 0.88rem;
}

.occ-toast {
  position: fixed;
  right: 16px;
  bottom: 16px;
  background: #111827;
  color: #fff;
  padding: 12px 14px;
  border-radius: 10px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18);
  z-index: 5000;
  font-size: 0.85rem;
  max-width: 320px;
}


/* ═══════════════════════════════════════════════════════════════════════
   11. PRINT MODAL & OVERLAY
   ═══════════════════════════════════════════════════════════════════════ */
.print-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(2px);
}

.print-overlay.open {
  display: flex;
  animation: fadeIn 0.2s ease;
}

.print-box {
  background: var(--occ-surface);
  border-radius: 14px;
  width: min(840px, 96vw);
  max-height: 90vh;
  overflow-y: auto;
  padding: 32px 36px;
  position: relative;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.28);
}

.print-close {
  position: absolute;
  top: 14px;
  right: 18px;
  background: #f0ede6;
  border: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  font-size: 1.1rem;
  cursor: pointer;
  color: #555;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s;
}

.print-close:hover {
  background: #ddd;
  color: #000;
}

.print-actions {
  display: flex;
  gap: 12px;
  margin-top: 24px;
  padding-top: 16px;
  border-top: 1px solid #eee;
}

/* print-modal-overlay (training hub variant) */
.print-modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  z-index: 1000;
  align-items: center;
  justify-content: center;
}

.print-modal-overlay.visible {
  display: flex;
}

.print-modal {
  background: var(--occ-surface);
  border-radius: 10px;
  padding: 35px 40px;
  max-width: 720px;
  width: 90%;
  max-height: 80vh;
  overflow-y: auto;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
  position: relative;
}

.print-modal h2 {
  color: var(--occ-primary-dk);
  margin-bottom: 8px;
  font-size: 1.3rem;
}

.print-modal .modal-meta {
  color: #888;
  font-size: 0.88rem;
  margin-bottom: 20px;
}

.modal-close-btn {
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  position: absolute;
  top: 15px;
  right: 20px;
  color: #666;
}

.record-section {
  margin-bottom: 18px;
}

.record-section h4 {
  font-size: 0.9rem;
  color: var(--occ-primary-dk);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border-bottom: 1px solid #ede9f0;
  padding-bottom: 6px;
  margin-bottom: 10px;
}

.record-item {
  font-size: 0.88rem;
  color: #333;
  padding: 5px 0;
  border-bottom: 1px solid #f3f4f6;
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.record-item .tick {
  color: #27ae60;
  font-weight: 700;
  flex-shrink: 0;
}

.record-item .cross {
  color: #bbb;
  flex-shrink: 0;
}

.record-item .ts {
  color: #888;
  font-size: 0.82rem;
  margin-left: auto;
  flex-shrink: 0;
}

.sign-block {
  margin-top: 25px;
  border-top: 2px solid #ede9f0;
  padding-top: 20px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.sign-line {
  border-bottom: 1px solid #333;
  margin-top: 30px;
}

.sign-label {
  font-size: 0.8rem;
  color: #666;
  margin-top: 5px;
}

.modal-actions {
  margin-top: 25px;
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.modal-sign-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 10px;
}

.modal-sign-item {
  padding: 12px 0;
  border-bottom: 1.5px solid var(--occ-primary-dk);
}

.modal-sign-item .sign-label {
  font-size: 0.78rem;
  color: #888;
  margin-top: 4px;
}

/* printContent styles */
#printContent h3 {
  font-size: 1.2rem;
  color: var(--occ-primary-dk);
  margin: 0 0 4px;
}

#printContent .meta {
  color: #555;
  font-size: 0.88rem;
  margin-bottom: 18px;
}

#printContent table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
  margin-top: 12px;
}

#printContent th {
  background: var(--occ-primary-dk);
  color: #fff;
  padding: 8px 12px;
  text-align: left;
  font-size: 0.82rem;
}

#printContent td {
  padding: 8px 12px;
  border-bottom: 1px solid #eee;
  vertical-align: top;
}

#printContent .section-head {
  font-weight: 700;
  color: var(--occ-primary);
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 12px 0 4px;
  border-top: 2px solid var(--occ-muted-bg);
  margin-top: 14px;
}

#printContent .no-entries {
  color: #aaa;
  font-style: italic;
  font-size: 0.88rem;
  padding: 8px 0;
}


/* ═══════════════════════════════════════════════════════════════════════
   12. KNOWLEDGE CHECK ACCORDION
   ═══════════════════════════════════════════════════════════════════════ */
.knowledge-check {
  background: #f9f9f9;
  border: 2px solid var(--occ-primary);
  padding: 25px;
  margin-top: 35px;
  border-radius: 8px;
}

.knowledge-check h3 {
  color: var(--occ-primary-dk);
  margin-bottom: 20px;
  font-size: 1.15rem;
}

.question {
  margin-bottom: 12px;
  background: var(--occ-surface);
  padding: 15px;
  border-radius: 6px;
  cursor: pointer;
  border: 1px solid #ddd;
  transition: border-color 0.2s;
}

.question:hover {
  border-color: var(--occ-primary);
}

.question-title {
  font-weight: 600;
  color: #333;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
}

.question-toggle {
  min-width: 24px;
  height: 24px;
  background: var(--occ-primary);
  color: #fff;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.1rem;
  line-height: 24px;
  text-align: center;
  font-family: inherit;
}

.answer {
  display: none;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid #eee;
  color: #555;
  line-height: 1.7;
}

.answer.open {
  display: block;
}


/* ═══════════════════════════════════════════════════════════════════════
   13. BADGE & LABEL SYSTEM
   ═══════════════════════════════════════════════════════════════════════ */
.phase-badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 12px;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  margin-left: 8px;
  vertical-align: middle;
}

.phase-prehire {
  background: #fef3c7;
  color: #92400e;
}

.phase-day1,
.phase-day1p {
  background: #dbeafe;
  color: #1e40af;
}

.phase-week1 {
  background: #d1fae5;
  color: #065f46;
}

.phase-ongoing,
.phase-active {
  background: #f3e8ff;
  color: #6b21a8;
}

.phase-precommence {
  background: #d5f5e3;
  color: #1e8449;
}

.phase-review {
  background: #fdf2f8;
  color: #7b3f6e;
}

.req-mandatory {
  background: #fee2e2;
  color: #991b1b;
  font-size: 0.73rem;
  padding: 2px 7px;
  border-radius: 10px;
  font-weight: 700;
}

.req-conditional {
  background: #fef3c7;
  color: #92400e;
  font-size: 0.73rem;
  padding: 2px 7px;
  border-radius: 10px;
  font-weight: 700;
}

/* Chip badges */
.occ-shell-chipbar {
  max-width: var(--occ-shell-max);
  margin: 20px auto 0;
  padding: 0 20px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.occ-shell-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid rgba(36, 0, 70, 0.12);
  background: var(--occ-surface);
  color: var(--occ-primary-dk);
  border-radius: 999px;
  padding: 8px 12px;
  font-size: 0.8rem;
  box-shadow: 0 1px 4px rgba(16, 24, 40, 0.06);
}

.role-badge {
  font-size: 0.82rem;
  color: var(--occ-primary);
  font-weight: 600;
  background: #ede9ff;
  padding: 5px 12px;
  border-radius: 20px;
  white-space: nowrap;
}

.role-badge--id {
  background: #f5ede0;
  color: #a04000;
}

.role-badge--type {
  background: #ede9ff;
  color: var(--occ-primary);
  padding: 2px 8px;
  border-radius: 10px;
  font-size: 0.78rem;
  font-weight: 600;
}

.role-badge--opt {
  background: #f0f0f0;
  color: #555;
  padding: 2px 8px;
  border-radius: 10px;
  font-size: 0.78rem;
  font-weight: 600;
}

.cat-chip {
  display: inline-block;
  background: #ede9ff;
  color: var(--occ-primary);
  font-size: 0.75rem;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 12px;
  white-space: nowrap;
}

.logo-badge {
  display: inline-block;
  background: var(--occ-accent);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  padding: 3px 10px;
  border-radius: 12px;
  margin-top: 10px;
}

.entry-count {
  background: var(--occ-accent);
  color: #fff;
  font-size: 0.78rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
}

.current-week-badge {
  display: none;
  font-size: 0.78rem;
  background: #d4edda;
  color: #155724;
  padding: 4px 10px;
  border-radius: 12px;
  font-weight: 600;
}

.current-week-badge.visible {
  display: inline;
}


/* ═══════════════════════════════════════════════════════════════════════
   14. MODULE NAVIGATION & COMPLETION
   ═══════════════════════════════════════════════════════════════════════ */
.module-buttons {
  display: flex;
  gap: 15px;
  margin-top: 40px;
  padding-top: 30px;
  border-top: 1px solid #eee;
}


/* ═══════════════════════════════════════════════════════════════════════
   15. LANDING PAGE & HOME OVERRIDES
   ═══════════════════════════════════════════════════════════════════════ */
.landing-page {
  display: flex;
  gap: 30px;
  padding: 30px 30px;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  min-height: calc(100vh - var(--occ-header-h));
}

.landing-page--column {
  flex-direction: column;
  gap: 20px;
}

.audience-card {
  flex: 1;
  max-width: 300px;
  background: var(--occ-surface);
  border-radius: 12px;
  padding: 36px 28px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  text-align: center;
  transition: transform 0.3s, box-shadow 0.3s;
  border-top: 5px solid var(--occ-primary);
}

.audience-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.audience-card h2 {
  font-size: 1.4rem;
  margin-bottom: 12px;
  color: var(--occ-primary-dk);
}

.audience-card .tag {
  display: inline-block;
  background: var(--occ-muted-bg);
  color: var(--occ-primary);
  padding: 4px 12px;
  border-radius: 12px;
  font-size: 0.85rem;
  margin-bottom: 12px;
}

.audience-card p {
  margin-bottom: 12px;
  color: #666;
  line-height: 1.7;
  font-size: 0.93rem;
}


.landing-page-wrap {
  min-height: calc(100vh - var(--occ-header-h));
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: var(--occ-bg);
  padding: 40px 20px;
}

.audience-card.ks {
  border-top-color: var(--occ-primary);
}

.audience-card.ks .tag {
  background: var(--occ-muted-bg);
  color: var(--occ-primary);
}

body.occ-home {
  padding-top: 0;
  background: #f5f0fc;
}

body.occ-home header {
  position: static;
  height: auto;
  padding: 28px 40px 22px;
  text-align: center;
  flex-direction: column;
  gap: 4px;
  box-shadow: 0 3px 12px rgba(36, 0, 70, 0.35);
}

body.occ-home header h1 {
  font-size: 1.75rem;
  margin-bottom: 6px;
}

body.occ-home header p {
  font-size: 0.9rem;
  opacity: 0.82;
}

body.occ-home main {
  flex: 1;
  max-width: 860px;
  width: 100%;
  margin: 40px auto;
  padding: 0 24px 48px;
}

.welcome {
  text-align: center;
  margin-bottom: 36px;
}

.welcome h2 {
  font-size: 1.25rem;
  color: var(--occ-primary-dk);
  font-weight: 700;
  margin-bottom: 8px;
}

.welcome p {
  color: #555;
  font-size: 0.95rem;
  line-height: 1.6;
  max-width: 560px;
  margin: 0 auto;
}

.role-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 20px;
  margin-top: 8px;
}

.role-card {
  background: var(--occ-surface);
  border: 2px solid #e8dff5;
  border-radius: 14px;
  padding: 28px 20px 22px;
  text-align: center;
  text-decoration: none;
  color: inherit;
  transition: border-color 0.18s, box-shadow 0.18s, transform 0.15s;
  cursor: pointer;
  display: block;
}

.role-card:hover {
  border-color: var(--occ-primary);
  box-shadow: 0 6px 24px rgba(90, 24, 154, 0.18);
  transform: translateY(-3px);
}

.role-card .icon {
  font-size: 2.6rem;
  margin-bottom: 14px;
  line-height: 1;
}

.role-card .role-label {
  font-size: 1rem;
  font-weight: 700;
  color: var(--occ-primary-dk);
  margin-bottom: 8px;
}

.role-card .role-desc {
  font-size: 0.82rem;
  color: #777;
  line-height: 1.5;
}

.role-card .go-btn {
  display: inline-block;
  margin-top: 16px;
  background: var(--occ-accent);
  color: #fff;
  font-size: 0.8rem;
  font-weight: 700;
  padding: 6px 18px;
  border-radius: 20px;
  letter-spacing: 0.4px;
  text-transform: uppercase;
}

.role-card:hover .go-btn {
  background: var(--occ-accent-hover);
}

.section-label {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: #9b72d0;
  margin: 36px 0 14px;
  text-align: center;
}

.occ-home-highlights {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  margin-bottom: 28px;
}

.occ-home-highlight-card {
  background: var(--occ-surface);
  border: 1px solid #eadff7;
  border-radius: 14px;
  padding: 18px;
  box-shadow: 0 2px 8px rgba(36, 0, 70, 0.06);
}

.occ-home-highlight-card h3 {
  color: var(--occ-primary-dk);
  font-size: 1rem;
  margin-bottom: 8px;
}

.occ-home-highlight-card p {
  color: #5b5566;
  font-size: 0.9rem;
  line-height: 1.55;
}


/* ═══════════════════════════════════════════════════════════════════════
   16. TRAINING HUB (checklists, summary)
   ═══════════════════════════════════════════════════════════════════════ */
.ph-onboarding-banner {
  background: var(--occ-muted-bg);
  border-bottom: 2px solid var(--occ-muted-border);
  padding: 12px 30px;
  font-size: 0.88rem;
  color: var(--occ-primary-dk);
  text-align: center;
}

.mh-onboarding-banner {
  background: #fdf4f9;
  border-bottom: 2px solid #e0c4d4;
  padding: 12px 30px;
  font-size: 0.88rem;
  color: #5c2d4a;
  text-align: center;
}

.checklist-section {
  margin-bottom: 30px;
}

.checklist-section h3 {
  font-size: 1.05rem;
  color: var(--occ-primary-dk);
  background: var(--occ-muted-bg);
  padding: 10px 15px;
  border-left: 4px solid var(--occ-primary);
  border-radius: 0 4px 4px 0;
  margin: 24px 0 0;
}

.checklist-table td {
  padding: 10px 14px;
  border-bottom: 1px solid #ede9f0;
  vertical-align: top;
  font-size: 0.93rem;
}

.checklist-table tr:last-child td {
  border-bottom: none;
}

.checklist-table tr:hover { 
  background: var(--occ-muted-bg);
}

.checklist-table .item-text {
  width: 75%;
  color: #333;
}

.checklist-table .item-check {
  width: 12%;
  text-align: center;
}

.checklist-table .item-note {
  width: 13%;
  color: #888;
  font-size: 0.85rem;
}

.cl-checkbox {
  width: 22px;
  height: 22px;
  cursor: pointer;
  accent-color: var(--occ-primary);
  transform: scale(1.2);
}

.checklist-table tr.checked-row {
  background: #f5fdf5;
}

.checklist-table tr.checked-row td {
  text-decoration: line-through;
  color: #aaa;
}

.check-list {
  list-style: none;
}

.check-list li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 9px 0;
  border-bottom: 1px solid var(--occ-muted-bg);
  font-size: 0.9rem;
}

.check-list li:last-child {
  border-bottom: none;
}

.check-list input[type=checkbox] {
  margin-top: 3px;
  accent-color: var(--occ-primary);
  transform: scale(1.15);
  flex-shrink: 0;
  cursor: pointer;
}

.check-list .item-label {
  flex: 1;
  color: #333;
  line-height: 1.5;
  cursor: pointer;
}

.timestamp-cell {
  font-size: 0.82rem;
  color: #888;
  white-space: nowrap;
}

.checklist-summary-bar {
  position: sticky;
  bottom: 0;
  background: var(--occ-primary-dk);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 30px;
  font-size: 0.9rem;
  z-index: 100;
  box-shadow: 0 -2px 8px rgba(0, 0, 0, 0.15);
}

.count-text {
  font-weight: 600;
}


/* ═══════════════════════════════════════════════════════════════════════

/* ── Checklist na label ── */
.na-label {
  font-size: 0.8em;
  color: var(--occ-text-subtle);
  font-style: italic;
}

/* ── Save buttons (training hub) ── */
.save-btn {
  background: var(--occ-primary-dk);
  color: #fff;
  border: none;
  padding: 12px 24px;
  border-radius: 6px;
  font-size: 0.95em;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
}

.save-btn:hover {
  background: var(--occ-primary);
}

.save-btn.secondary {
  background: var(--occ-surface);
  color: var(--occ-primary-dk);
  border: 2px solid var(--occ-primary-dk);
}

.save-btn.secondary:hover {
  background: var(--occ-muted-bg);
}

/* ── Participant hub save button ── */
.ph-save-btn {
  background: var(--occ-primary);
  color: #fff;
  border: none;
  padding: 12px 24px;
  border-radius: 6px;
  font-size: 0.95em;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
}

.ph-save-btn:hover {
  background: var(--occ-primary-dk);
}

.ph-save-btn.secondary {
  background: var(--occ-surface);
  color: var(--occ-primary);
  border: 2px solid var(--occ-primary);
}

.ph-save-btn.secondary:hover {
  background: var(--occ-muted-bg);
}

/* ── Participant fields ── */
.pt-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-bottom: 22px;
  background: var(--occ-muted-bg);
  padding: 18px;
  border-radius: 6px;
}

.pt-field label {
  font-size: 0.82em;
  font-weight: 600;
  display: block;
  margin-bottom: 4px;
  color: var(--occ-primary-dk);
}

.pt-field input {
  width: 100%;
  padding: 8px 10px;
  border: 1px solid var(--occ-border);
  border-radius: 4px;
  font-size: 0.93em;
  background: var(--occ-surface);
}

.pt-field input:focus {
  outline: 2px solid var(--occ-primary);
}

/* ── Induction timeline ── */
.induction-timeline {
  display: flex;
  gap: 0;
  margin: 30px 0;
  overflow-x: auto;
}

.timeline-step {
  flex: 1;
  min-width: 150px;
  text-align: center;
  padding: 18px 12px;
  position: relative;
}

.timeline-step:not(:last-child)::after {
  content: '→';
  position: absolute;
  right: -8px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.3em;
  color: #aaa;
}

.timeline-step .step-num {
  width: 36px;
  height: 36px;
  background: var(--occ-primary);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  margin: 0 auto 10px;
  font-size: 0.95em;
}

.timeline-step .step-title {
  font-weight: 700;
  font-size: 0.9em;
  color: var(--occ-primary-dk);
  margin-bottom: 6px;
}

.timeline-step .step-who {
  display: inline-block;
  font-size: 0.75em;
  padding: 2px 8px;
  border-radius: 10px;
  background: var(--occ-muted-bg);
  color: var(--occ-primary);
  margin-bottom: 6px;
}

.timeline-step .step-desc {
  font-size: 0.8em;
  color: var(--occ-text-muted);
  line-height: 1.5;
}

/* ── Training completion block ── */
.training-completion {
  border-radius: 10px;
  padding: 30px 35px;
  margin-top: 40px;
  border: 2px solid var(--occ-primary);
  background: var(--occ-muted-bg);
}

.training-completion h3 {
  margin: 0 0 6px;
  font-size: 1.3em;
  color: var(--occ-primary-dk);
}

.training-completion .sub {
  color: var(--occ-text-muted);
  font-size: 0.9em;
  margin-bottom: 22px;
}

.tc-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-bottom: 22px;
}

.tc-field label {
  font-size: 0.82em;
  font-weight: 600;
  display: block;
  margin-bottom: 4px;
  color: #555;
}

.tc-field input {
  width: 100%;
  padding: 8px 10px;
  border: 1px solid var(--occ-border);
  border-radius: 4px;
  font-size: 0.93em;
  background: var(--occ-surface);
}

.tc-declarations {
  margin-bottom: 22px;
}

.tc-dec-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 10px 14px;
  background: var(--occ-surface);
  border-radius: 6px;
  border: 1px solid #ddd;
  margin-bottom: 8px;
  cursor: pointer;
}

.tc-dec-item:hover {
  border-color: var(--occ-primary);
}

.tc-dec-item input[type=checkbox] {
  margin-top: 3px;
  flex-shrink: 0;
  transform: scale(1.2);
  accent-color: var(--occ-primary);
}

.tc-dec-item label {
  font-size: 0.92em;
  color: var(--occ-text);
  cursor: pointer;
  line-height: 1.5;
}

.tc-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 6px;
}

.tc-btn {
  padding: 12px 22px;
  border-radius: 6px;
  border: none;
  font-size: 0.95em;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
}

.tc-btn.primary {
  background: var(--occ-accent);
  color: #fff;
}

.tc-btn.primary:hover {
  background: var(--occ-accent-hover);
}

.tc-btn.forms {
  background: #0078d4;
  color: #fff;
}

.tc-btn.forms:hover {
  background: #005ea2;
}

.forms-setup-note {
  margin-top: 20px;
  padding: 14px 18px;
  background: var(--occ-surface);
  border-radius: 6px;
  border: 1px solid #ddd;
  font-size: 0.85em;
  color: var(--occ-text-muted);
}

.forms-setup-note strong {
  color: #0078d4;
}

.forms-setup-note ol {
  margin: 8px 0 0 16px;
  line-height: 1.8;
}

/*17. SUPERVISION / PERFORMANCE FORM
   ═══════════════════════════════════════════════════════════════════════ */

/* Selector card */
.selector-card {
  background: var(--occ-surface);
  border-radius: 12px;
  padding: 24px;
  margin-bottom: 22px;
  box-shadow: var(--occ-shadow);
}

.selector-card h2 {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--occ-primary-dk);
  margin-bottom: 16px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--occ-muted-bg);
}

/* Tab nav */
.form-tabs {
  display: flex;
  gap: 6px;
  margin-bottom: 0;
  flex-wrap: wrap;
}

.tab-btn {
  padding: 10px 18px;
  border: none;
  border-radius: 10px 10px 0 0;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  background: #e4dcf7;
  color: var(--occ-primary);
  transition: background 0.15s;
  border-bottom: 3px solid transparent;
  font-family: inherit;
}

.tab-btn.active {
  background: var(--occ-primary-dk);
  color: #fff;
  border-bottom-color: var(--occ-accent);
}

.tab-btn:hover:not(.active) {
  background: #d0bfff;
}

/* Form panels */
.form-panel {
  display: none;
  background: var(--occ-surface);
  border-radius: 0 12px 12px 12px;
  padding: 28px;
  box-shadow: var(--occ-shadow);
  margin-bottom: 22px;
}

.form-panel.active {
  display: block;
}

/* Rating options (performance appraisal) */
.rating-opts,
.outcome-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 8px 0 16px;
}

.rating-opt,
.outcome-opt {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 16px;
  border: 1.5px solid var(--occ-muted-border);
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.15s;
  font-family: inherit;
}

.rating-opt:hover,
.outcome-opt:hover {
  background: #faf8ff;
}

.outcome-opt.danger {
  border-color: #cc2222;
}

.outcome-opt.danger:hover {
  background: #fff5f5;
}

.rating-opt input,
.outcome-opt input {
  margin-top: 2px;
  accent-color: var(--occ-primary);
  width: 16px;
  height: 16px;
}

.rating-opt strong {
  color: var(--occ-primary-dk);
}

.rating-opt span {
  font-size: 0.83rem;
  color: #555;
}

/* Sig section override for supervision */
.sig-section {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 2px solid var(--occ-muted-bg);
}

.sig-section .sig-grid {
  grid-template-columns: 1fr 1fr 1fr;
  margin-top: 12px;
}

.sig-section .sig-block {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.sig-section .sig-block input {
  padding: 8px 10px;
  border: 1.5px solid var(--occ-muted-border);
  border-radius: 6px;
  font-size: 0.88rem;
  background: #faf8ff;
}


/* ═══════════════════════════════════════════════════════════════════════

/* ── Supervision/Board Meeting page layout ── */
.page {
  max-width: 860px;
  margin: 30px auto 60px;
  padding: 0 20px;
}

.meeting-meta {
  background: var(--occ-surface);
  border-radius: 10px;
  padding: 28px 32px;
  box-shadow: var(--occ-shadow);
  margin-bottom: 24px;
  border-top: 4px solid var(--occ-primary-dk);
}

.meeting-meta h2 {
  color: var(--occ-primary-dk);
  font-size: 1.15em;
  margin-bottom: 18px;
  border-bottom: 2px solid var(--occ-muted-bg);
  padding-bottom: 10px;
}

.meta-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.meta-field label {
  display: block;
  font-size: 0.78em;
  font-weight: 700;
  color: var(--occ-primary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 5px;
}

.meta-field input,
.meta-field select {
  width: 100%;
  padding: 9px 12px;
  border: 1.5px solid var(--occ-border);
  border-radius: 6px;
  font-size: 0.93em;
  font-family: inherit;
  color: var(--occ-text);
  background: var(--occ-surface);
  transition: border-color 0.2s;
}

.meta-field input:focus,
.meta-field select:focus {
  outline: none;
  border-color: var(--occ-primary);
}

/* ── Section card ── */
.section {
  background: var(--occ-surface);
  border-radius: 10px;
  padding: 26px 32px;
  box-shadow: var(--occ-shadow);
  margin-bottom: 20px;
}

.section-header {
  display: flex;
  align-items: center;
  gap: 12px;
  border-bottom: 2px solid var(--occ-muted-bg);
  padding-bottom: 12px;
  margin-bottom: 18px;
}

.section h2 {
  color: var(--occ-primary-dk);
  font-size: 1.05em;
}

.section-note {
  font-size: 0.83em;
  color: var(--occ-text-muted);
  margin-top: 3px;
}

/* ── Numeric row (attendance count) ── */
.num-row {
  display: flex;
  gap: 14px;
  align-items: flex-end;
  margin-bottom: 14px;
}

.num-field {
  width: 80px;
}

.num-field input {
  text-align: center;
}

/* ── Generate bar ── */
.generate-bar {
  text-align: center;
  margin: 30px 0 10px;
}

/* ── Modal sign grid ── */
.modal-sign-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 10px;
}

.modal-sign-item {
  padding: 12px 0;
  border-bottom: 1.5px solid var(--occ-primary-dk);
}

.modal-sign-item .sign-label {
  font-size: 0.78em;
  color: var(--occ-text-subtle);
  margin-top: 4px;
}

/* ── Manager Hub staff grid ── */
.mh-staff-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
  margin-bottom: 25px;
  background: #fdf4f9;
  padding: 18px;
  border-radius: 6px;
}

.mh-field-label {
  font-size: 0.85em;
  color: #5c2d4a;
  font-weight: 600;
  display: block;
}

.mh-staff-grid input {
  width: 100%;
  margin-top: 5px;
  padding: 7px;
  border: 1px solid var(--occ-border);
  border-radius: 4px;
  font-size: 0.93em;
  font-family: inherit;
}

.manager-hub-sidebar~.main-content .module-content h3 {
  color: #5c2d4a;
  border-left-color: #7b3f6e;
}

@media (max-width: 700px) {

  .meta-grid,
  .modal-sign-grid {
    grid-template-columns: 1fr;
  }

  .attend-table {
    font-size: 0.82em;
  }
}

/*
   18. PARTICIPANT INTAKE WIZARD
   ═══════════════════════════════════════════════════════════════════════ */
@keyframes fadeSlideUp {
  from {
    opacity: 0;
    transform: translateY(8px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

.intake-page {
  font-family: 'Plus Jakarta Sans', 'Segoe UI', system-ui, sans-serif;
  background: var(--int-bg);
  color: var(--int-text);
  min-height: 100vh;
  font-size: 14px;
  line-height: 1.5;
}

.intake-page .site-header {
  background: var(--int-header);
  padding: 0 28px;
  height: 62px;
  gap: 16px;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.05), 0 3px 14px rgba(0, 0, 0, 0.22);
}

.intake-page .site-header h1 {
  font-family: 'Fraunces', Georgia, serif;
  font-size: 1.05rem;
  font-weight: 400;
}

.step-indicator {
  font-size: 0.73rem;
  font-weight: 700;
  background: var(--int-primary);
  color: #fff;
  padding: 4px 14px;
  border-radius: 20px;
  white-space: nowrap;
  flex-shrink: 0;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

/* App shell */
.app-shell {
  display: flex;
  max-width: 1100px;
  margin: 28px auto;
  padding: 0 20px 80px;
  gap: 24px;
  align-items: flex-start;
}

/* Steps sidebar */
.steps-sidebar {
  width: 220px;
  flex-shrink: 0;
  position: sticky;
  top: 82px;
  background: var(--int-surface);
  border-radius: 12px;
  padding: 16px 0 18px;
  box-shadow: var(--int-shadow);
  border: 1px solid var(--int-border);
}

.step-item {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  padding: 10px 16px;
  cursor: pointer;
  transition: background 0.15s;
  border-left: 3px solid transparent;
}

.step-item:hover {
  background: #FAF8F5;
}

.step-item.active {
  background: var(--int-primary-lt);
  border-left-color: var(--int-primary);
}

.step-item.completed .step-num {
  background: var(--int-header);
  color: #fff;
}

.step-num {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #EDE8E0;
  color: var(--int-text-muted);
  font-size: 0.75rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 1px;
  transition: background 0.2s, color 0.2s;
}

.step-item.active .step-num {
  background: var(--int-primary);
  color: #fff;
}

.step-label {
  font-size: 0.81rem;
  font-weight: 600;
  color: var(--int-text);
  line-height: 1.35;
}

.step-doc {
  font-size: 0.71rem;
  color: var(--int-text-subtle);
  margin-top: 2px;
}

.step-item.active .step-label {
  color: var(--int-primary);
}

.steps-progress {
  padding: 16px 16px 0;
}

.steps-progress-bar {
  height: 5px;
  background: #EDE8E0;
  border-radius: 3px;
  overflow: hidden;
}

.steps-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--int-primary), #D97040);
  border-radius: 3px;
  transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.steps-progress-label {
  font-size: 0.71rem;
  color: var(--int-text-subtle);
  margin-top: 6px;
}

/* Step content */
.step-content {
  flex: 1;
  min-width: 0;
}

.step-panel {
  display: none;
}

.step-panel.active {
  display: block;
  animation: fadeSlideUp 0.22s ease;
}

/* Intake overrides for panel-card, panel-title, section-heading */
.intake-page .panel-card {
  border-color: var(--int-border);
  box-shadow: var(--int-shadow);
}

.intake-page .panel-title {
  color: var(--int-header);
}

.intake-page .panel-meta {
  color: var(--int-text-subtle);
}

.intake-page .panel-note {
  background: var(--int-note-bg);
  border-color: var(--int-note-border);
  color: #4A3F35;
}

.intake-page .section-heading {
  color: var(--int-primary);
  border-top-color: var(--int-border);
  font-size: 0.72rem;
  letter-spacing: 0.07em;
}

.intake-page .section-heading:first-of-type {
  border-top: none;
}

/* Intake form inputs */
.intake-page .form-group label {
  font-size: 0.72rem;
  color: var(--int-header);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  opacity: 0.82;
}

.intake-page .form-group input,
.intake-page .form-group select,
.intake-page .form-group textarea {
  border-color: var(--int-border);
  border-radius: 7px;
  font-size: 0.88rem;
  color: var(--int-text);
  background: var(--int-input-bg);
}

.intake-page .form-group input:focus,
.intake-page .form-group select:focus,
.intake-page .form-group textarea:focus {
  border-color: var(--int-primary);
  box-shadow: 0 0 0 3px rgba(194, 94, 58, 0.1);
}

.intake-page .radio-opt input {
  accent-color: var(--int-primary);
}

/* Intake tables */
.intake-page .cl-table th,
.intake-page .consent-table th {
  background: var(--int-header);
}

.intake-page .cl-table tr:hover td,
.intake-page .consent-table tr:hover td {
  background: #FAF8F5;
}

.intake-page .cl-table input[type=checkbox],
.intake-page .consent-table input[type=radio] {
  accent-color: var(--int-primary);
}

.intake-page .cl-table input[type=text],
.intake-page .cl-table input[type=date] {
  border-color: var(--int-border);
  background: var(--int-input-bg);
}

.intake-page .resp-list li {
  border-color: var(--int-border);
}

.intake-page .resp-list input {
  accent-color: var(--int-primary);
}

/* Step nav row */
.step-nav {
  display: flex;
  gap: 10px;
  margin-top: 8px;
  align-items: center;
}

.step-nav-info {
  font-size: 0.78rem;
  color: var(--int-text-subtle);
  margin-left: auto;
}

/* Intake generate button */
.intake-page .btn-generate {
  background: var(--int-primary);
  border-radius: 7px;
  font-size: 0.87rem;
}

.intake-page .btn-generate:hover {
  background: var(--int-primary-dk);
}

/* Intake add-row variant */
.btn-add-row--intake {
  background: transparent;
  color: var(--int-header);
  border: 1.5px dashed #C8C2B8;
  border-radius: 6px;
  padding: 6px 16px;
  font-size: 0.81rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  margin-top: 6px;
  transition: background 0.15s, border-color 0.15s;
}

.btn-add-row--intake:hover {
  background: #F6F3EE;
  border-color: var(--int-header);
}

/* Intake print overlay overrides */
.intake-page .print-overlay {
  background: rgba(10, 15, 30, 0.55);
}

.intake-page .print-box {
  width: min(840px, 96vw);
}

.intake-page .print-close {
  background: #F0EDE6;
}

.intake-page .print-close:hover {
  background: var(--int-border);
}

.intake-page .btn-cancel-print {
  background: #F0EDE6;
  color: #555;
}

.intake-page .btn-cancel-print:hover {
  background: var(--int-border);
}


/* ═══════════════════════════════════════════════════════════════════════
   19. SUPPORT WORKER LOG / TIMESHEET
   ═══════════════════════════════════════════════════════════════════════ */
.app-body {
  max-width: 1100px;
  margin: 32px auto;
  padding: 0 16px 60px;
}

.week-nav {
  background: var(--occ-surface);
  border-radius: 12px;
  padding: 16px 24px;
  margin-bottom: 24px;
  box-shadow: var(--occ-shadow);
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.week-nav label {
  font-weight: 600;
  color: var(--occ-primary-dk);
  font-size: 0.9rem;
}

.week-nav input[type=date] {
  padding: 8px 12px;
  border: 2px solid var(--occ-muted-border);
  border-radius: 8px;
  font-size: 0.9rem;
  color: var(--occ-primary-dk);
  outline: none;
  font-family: inherit;
}

.week-nav input[type=date]:focus {
  border-color: var(--occ-primary);
}

.week-nav .week-range {
  font-size: 0.85rem;
  color: #555;
  margin-left: auto;
}

.entry-card,
.log-card,
.summary-card {
  background: var(--occ-surface);
  border-radius: 12px;
  padding: 24px;
  margin-bottom: 24px;
  box-shadow: var(--occ-shadow);
}

.entry-card h2,
.log-card-header h2,
.summary-card h2 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--occ-primary-dk);
}

.log-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  flex-wrap: wrap;
  gap: 10px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 14px;
}

.form-row.full {
  grid-template-columns: 1fr;
}

.empty-log {
  text-align: center;
  color: #aaa;
  padding: 28px 0;
  font-style: italic;
}

.summary-stats {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 18px;
}

.stat-box {
  flex: 1;
  min-width: 110px;
  background: #f4f0fa;
  border-radius: 10px;
  padding: 14px 16px;
  text-align: center;
}

.stat-box .stat-num {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--occ-primary-dk);
  line-height: 1;
}

.stat-box .stat-label {
  font-size: 0.75rem;
  color: #666;
  margin-top: 4px;
  font-weight: 600;
}


/* ═══════════════════════════════════════════════════════════════════════
   20. RESPONSIVE, PRINT & REDUCED MOTION
   ═══════════════════════════════════════════════════════════════════════ */
@media (max-width: 900px) {
  .landing-page {
    flex-direction: column;
    padding: 30px 15px;
  }

  .pathway-container {
    flex-direction: column;
  }

  .sidebar {
    position: static;
    width: 100%;
    height: auto;
    max-height: none;
    box-shadow: none;
    padding: 18px 15px;
  }

  .main-content {
    margin-left: 0;
    padding: 24px 18px;
  }

  .module-header h2 {
    font-size: 1.5rem;
  }

  .form-grid,
  .form-grid.three {
    grid-template-columns: 1fr;
  }

  .sel-grid {
    grid-template-columns: 1fr;
  }

  .sig-grid {
    grid-template-columns: 1fr;
  }

  .sign-block {
    grid-template-columns: 1fr;
  }

  .sig-section .sig-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .app-shell {
    flex-direction: column;
  }

  .steps-sidebar {
    width: 100%;
    position: static;
  }
}

@media (max-width: 640px) {
  .sel-grid {
    grid-template-columns: 1fr;
  }

  .sig-section .sig-grid {
    grid-template-columns: 1fr;
  }

  .modal-sign-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 600px) {
  header {
    padding: 18px 16px;
  }

  .main-content {
    padding: 16px;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .summary-stats {
    flex-direction: column;
  }

  .log-table .col-cat {
    display: none;
  }

  .radio-group {
    flex-direction: column;
    gap: 6px;
  }
}

@media print {

  .sidebar,
  header,
  .site-header,
  .checklist-summary-bar,
  .print-modal-overlay,
  .module-nav-btn,
  .module-buttons,
  .btn-generate,
  .btn-add,
  .gen-btn,
  .add-btn,
  .back-home-button,
  .mark-complete-button,
  .generate-bar,
  .modal-actions,
  .sh-toggle,
  .print-actions,
  .print-close,
  .step-nav,
  .steps-sidebar,
  .action-bar,
  .tab-btn,
  .form-tabs {
    display: none !important;
  }

  .main-content {
    margin-left: 0 !important;
    padding: 20px !important;
  }

  .module-page {
    display: block !important;
  }

  body {
    background: #fff !important;
  }

  body>*:not(.print-overlay) {
    display: none !important;
  }

  .print-overlay {
    display: block !important;
    position: static !important;
    background: none !important;
  }

  .print-box {
    box-shadow: none !important;
    border-radius: 0 !important;
    max-height: none !important;
    padding: 0 !important;
    width: 100% !important;
  }
}

@media (prefers-reduced-motion: reduce) {

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}


/* ═══════════════════════════════════════════════════════════════════════
   P2 INLINE STYLE EXTRACTIONS
   Replaces all inline style="" attributes across HTML and JS templates
   ═══════════════════════════════════════════════════════════════════════ */

/* ── Board Meeting: table column widths ─────────────────────────────── */
.attend-table th:nth-child(1) {
  width: 24%;
}

.attend-table th:nth-child(2) {
  width: 22%;
}

.attend-table th:nth-child(3) {
  width: 32%;
}

.attend-table th:nth-child(4) {
  width: 22%;
}

#prevTable th:nth-child(1) {
  width: 50%;
}

#prevTable th:nth-child(2) {
  width: 25%;
}

#prevTable th:nth-child(3) {
  width: 18%;
}

#prevTable th:nth-child(4) {
  width: 7%;
}

#newTable th:nth-child(1) {
  width: 52%;
}

#newTable th:nth-child(2) {
  width: 28%;
}

#newTable th:nth-child(3) {
  width: 13%;
}

#newTable th:nth-child(4) {
  width: 7%;
}

/* ── Board Meeting: narrative block spacing ──────────────────────────── */
.narrative.mt {
  margin-top: 18px;
}

/* ── KPI Tracker: label hint text ───────────────────────────────────── */
.label-hint {
  font-weight: 400;
  text-transform: none;
  color: #888;
}

.text-note {
  font-size: .85rem;
  color: #666;
  margin-bottom: 16px;
}

.log-card-header .card-hide-btn {
  margin-left: 8px;
}

/* ── KPI Tracker: log table day/date cell ───────────────────────────── */
.col-day-date {
  font-size: .78rem;
  color: #888;
  display: block;
}

/* ── KPI Tracker: PDF print layout ──────────────────────────────────── */
.pdf-header {
  border-bottom: 3px solid #240046;
  padding-bottom: 14px;
  margin-bottom: 18px;
}

.pdf-footer {
  margin-top: 28px;
  padding-top: 14px;
  border-top: 1px solid #eee;
  font-size: .82rem;
  color: #666;
}

.col-day-print {
  width: 110px;
  white-space: nowrap;
}

/* ── Training Hub: completion record components ──────────────────────── */
.tc-confirm-prompt {
  font-weight: 600;
  font-size: 0.95em;
  margin-bottom: 12px;
  color: #333;
}

.tc-supervisor-wrap {
  margin-bottom: 18px;
}

.tc-supervisor-label {
  font-size: 0.85em;
  font-weight: 600;
  color: #555;
  display: block;
  margin-bottom: 6px;
}

.obs-item-text {
  text-align: left;
  font-size: 0.87rem;
  line-height: 1.5;
}

.tc-notes-input {
  width: 100%;
  padding: 8px;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 0.9em;
  resize: vertical;
}

.link-plain {
  text-decoration: none;
}

/* ── Participant Hub: phase section heading ──────────────────────────── */
.phase-section-heading {
  color: var(--occ-primary-dk, #240046);
  border-left: 4px solid var(--occ-primary, #5A189A);
  padding-left: 12px;
  margin: 24px 0 12px;
}

/* ── Print/modal: document components ───────────────────────────────── */
.warning-note {
  background: #fffbeb;
  border-left: 4px solid #f59e0b;
  padding: 12px 16px;
  margin: 15px 0;
  border-radius: 0 4px 4px 0;
  font-size: 0.9em;
  color: #92400e;
}

.print-notes-box {
  min-height: 40px;
  padding: 8px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 0.88em;
  color: #333;
}

.doc-footer {
  margin-top: 30px;
  padding-top: 14px;
  border-top: 1px solid #ddd;
  font-size: 0.78em;
  color: #999;
}

.rec-na {
  color: #888;
  font-style: italic;
}

.rec-coi {
  color: #5A189A;
  font-size: 0.88em;
  margin-left: 8px;
}

.rec-narrative {
  margin-top: 8px;
  padding: 8px 12px;
  background: #f9f6ff;
  border-radius: 4px;
  font-size: 0.87em;
  color: #333;
}

.modal-sign-full {
  grid-column: 1 / -1;
}

.sign-next-meeting {
  font-size: 0.9em;
  color: #240046;
  font-weight: 600;
}

/* ── Staff Supervision: alert/warning components ─────────────────────── */
.text-alert {
  color: #cc2222;
}

.alert-list {
  margin-top: 6px;
  padding-left: 16px;
  font-size: .84rem;
}

.panel-note--alert {
  border-color: #cc2222 !important;
  background: #fff5f5 !important;
}

/* ── Info/instruction box ────────────────────────────────────────────── */
.info-box {
  margin-top: 8px;
  margin-bottom: 18px;
  padding: 12px 16px;
  background: #f5f0ff;
  border-left: 4px solid var(--occ-primary, #5A189A);
  border-radius: 0 8px 8px 0;
  font-size: .84rem;
  color: #333;
}

/* ── Participant Hub: step-table column widths ───────────────────────── */
.step-table th:nth-child(1) {
  width: 44px;
}

.step-table th:nth-child(3) {
  width: 130px;
}

.step-table th:nth-child(4) {
  width: 140px;
}

.step-table th:nth-child(5) {
  width: 50px;
}

/* ── Participant Hub: specific component overrides ───────────────────── */
.checklist-summary-bar {
  border-color: #5A189A;
  /* background: #f5f0ff; */
  margin-top: 30px;
}

.pt-fields {
  margin-top: -10px;
}

/* ── Staff Supervision: table column widths ──────────────────────────── */
#epaPrevGoalTable th:nth-child(2) {
  width: 160px;
}

#epaNextGoalTable th:nth-child(4) {
  width: 120px;
}

#epaTrainingTable th:nth-child(2) {
  width: 130px;
}

#epaTrainingTable th:nth-child(4) {
  width: 110px;
}

#epaTrainingTable th:nth-child(5) {
  width: 120px;
}

#paGoalTable th:nth-child(1) {
  width: 30px;
}

#paGoalTable th:nth-child(4) {
  width: 120px;
}

#paGoalTable th:nth-child(5) {
  width: 75px;
}

#paDevTable th:nth-child(4) {
  width: 120px;
}

#paDevTable th:nth-child(5) {
  width: 120px;
}

#obsActionTable th:nth-child(3) {
  width: 130px;
}

#obsActionTable th:nth-child(4) {
  width: 80px;
}

/* ── Staff Supervision: misc layout ─────────────────────────────────── */
.comp-table {
  font-size: .86rem;
}

.flex-badge-row {
  display: flex;
  gap: 8px;
  align-items: center;
  margin-top: 4px;
}

/* ── Participant Intake: worker match table ──────────────────────────── */
#matchingBody~* th:nth-child(1),
table:has(#matchingBody) th:nth-child(1) {
  width: 25%;
}

table:has(#matchingBody) th:nth-child(2) {
  width: 20%;
}

table:has(#matchingBody) th:nth-child(3) {
  width: 18%;
}

table:has(#matchingBody) th:nth-child(4) {
  width: 18%;
}

table:has(#matchingBody) th:nth-child(5) {
  width: 12%;
  text-align: center;
}

table:has(#matchingBody) td:last-child {
  text-align: center;
}

table:has(#matchingBody) {
  font-size: .86rem;
}

/* ── Participant Intake: intake checklist columns ─────────────────────── */
.intake-checklist th:nth-child(1) {
  width: 55%;
}

.intake-checklist th:nth-child(2) {
  width: 70px;
  text-align: center;
}

.intake-checklist th:nth-child(3) {
  width: 110px;
}

.intake-checklist th:nth-child(4) {
  width: 70px;
}

.intake-checklist td:nth-child(1) {
  font-size: .85rem;
}

.intake-checklist td:nth-child(2) {
  text-align: center;
}

.intake-checklist input[placeholder="Init."] {
  width: 50px;
}

/* ── Print modal: document layout ───────────────────────────────── */
.print-doc-header {
  border-bottom: 3px solid #240046;
  padding-bottom: 12px;
  margin-bottom: 18px;
}

.print-doc-title {
  color: #240046;
  font-size: 1.15rem;
  margin: 0 0 4px;
}

.print-doc-meta {
  color: #555;
  font-size: .85rem;
  margin-top: 4px;
}

.print-doc-table {
  width: 100%;
  font-size: .88rem;
  border-collapse: collapse;
  margin-bottom: 16px;
}

.print-doc-label {
  padding: 5px 10px;
  background: #f4f0fa;
  font-weight: 600;
  width: 35%;
  font-size: .86rem;
}

.print-doc-value {
  padding: 5px 10px;
  font-size: .86rem;
}

.print-doc-section-heading {
  font-weight: 700;
  color: #5A189A;
  font-size: .8rem;
  text-transform: uppercase;
  letter-spacing: .05em;
  margin: 14px 0 8px;
  padding-top: 12px;
  border-top: 2px solid #ede9ff;
}

.print-doc-th-dark {
  background: #240046;
  color: #fff;
  padding: 7px 10px;
  text-align: left;
}

.print-doc-td {
  padding: 6px 10px;
  border-bottom: 1px solid #eee;
}

.print-doc-p {
  font-size: .85rem;
  margin-bottom: 6px;
}

.print-doc-label-flex {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: .82rem;
}

.print-doc-checkbox {
  width: 20px;
  height: 20px;
  accent-color: #5A189A;
}
