/* ═══ STUDIOHAUS PORTAL — Component Styles ═══ */

    /* ─── Modal ─── */
    .modal-overlay {
      position: fixed;
      inset: 0;
      background: rgba(0,0,0,0.6);
      backdrop-filter: blur(8px);
      -webkit-backdrop-filter: blur(8px);
      z-index: 500;
      display: flex;
      align-items: center;
      justify-content: center;
      padding: 40px;
      animation: modalOverlayIn 0.25s ease;
    }
    @keyframes modalOverlayIn {
      from { opacity: 0; }
      to { opacity: 1; }
    }

    .modal {
      background: rgba(17, 17, 17, 0.85);
      border: 1px solid rgba(255,255,255,0.06);
      width: 100%;
      max-width: 640px;
      max-height: 85vh;
      overflow-y: auto;
      padding: 36px;
      border-radius: var(--radius-lg);
      box-shadow: 0 24px 80px rgba(0,0,0,0.4), inset 0 1px 0 rgba(255,255,255,0.05);
      animation: modalSlideIn 0.3s cubic-bezier(0.16, 1, 0.3, 1);
      backdrop-filter: blur(20px);
      -webkit-backdrop-filter: blur(20px);
    }
    .modal--sm { max-width: 460px; }
    .modal--lg { max-width: 760px; }
    @keyframes modalSlideIn {
      from { opacity: 0; transform: scale(0.95) translateY(10px); }
      to { opacity: 1; transform: scale(1) translateY(0); }
    }

    .modal h3 {
      font-size: 18px;
      font-weight: 500;
      margin-bottom: 24px;
    }

    /* ─── Forms ─── */
    .form-group {
      margin-bottom: 16px;
    }
    .form-label {
      display: block;
      font-size: 11px;
      font-weight: 600;
      text-transform: uppercase;
      letter-spacing: 1.5px;
      color: var(--text-40);
      margin-bottom: 6px;
    }

    .page-header {
      margin-bottom: 48px;
    }

    .page-label {
      font-size: 11px;
      letter-spacing: 3px;
      text-transform: uppercase;
      color: var(--text-40);
      margin-bottom: 12px;
    }

    .page-title {
      font-size: var(--fs-2xl);
      font-weight: var(--fw-medium);
      letter-spacing: -0.5px;
      max-width: 100%;
      overflow-wrap: break-word;
      word-break: break-word;
    }

    .page-title strong { font-weight: var(--fw-semi); }

    /* ─── PROJECT CARDS ─── */
    .projects-grid {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
      gap: 12px;
    }

    .project-card {
      background: var(--bg-card);
      border: 1px solid var(--border);
      padding: 0;
      cursor: pointer;
      display: flex;
      flex-direction: column;
      gap: 0;
      border-radius: var(--radius);
      transition: all 0.3s ease;
      overflow: hidden;
    }
    .project-card > .project-card-body {
      padding: var(--s-6);
      display: flex;
      flex-direction: column;
      gap: var(--s-5);
    }

    /* ─── Project peek — expanded row in WM table ────────────────
       Replaces the old "Description / Links / Files" panel layout
       with a workflow-aware status drawer. Compact, action-oriented. */
    .project-peek {
      padding: 20px 24px 22px;
      background: var(--bg-card);
      border-bottom: 1px solid var(--border);
      display: flex;
      flex-direction: column;
      gap: 18px;
    }

    /* Workflow pipeline — horizontal stage track */
    .peek-pipeline {
      display: flex;
      align-items: center;
      gap: 0;
      padding: 8px 4px;
      overflow-x: auto;
    }
    .peek-stage {
      display: flex;
      flex-direction: column;
      align-items: center;
      gap: 6px;
      flex-shrink: 0;
      min-width: 76px;
      cursor: default;
    }
    .peek-stage-dot {
      width: 14px;
      height: 14px;
      border-radius: 50%;
      background: var(--text-10);
      border: 2px solid var(--border);
      transition: all 0.2s;
    }
    .peek-stage-label {
      font-size: 11px;
      color: var(--text-40);
      font-weight: var(--fw-medium);
      letter-spacing: 0.02em;
      white-space: nowrap;
    }
    .peek-stage.is-past .peek-stage-dot {
      background: var(--text-40);
      border-color: var(--text-40);
    }
    .peek-stage.is-current .peek-stage-dot {
      background: var(--brand-accent);
      border-color: var(--brand-accent);
      box-shadow: 0 0 0 4px rgba(var(--brand-accent-rgb), 0.18);
    }
    .peek-stage.is-current .peek-stage-label {
      color: var(--text);
      font-weight: var(--fw-semi);
    }
    .peek-stage-line {
      flex: 1;
      height: 2px;
      background: var(--text-10);
      min-width: 16px;
      margin: 0 -4px;
      align-self: center;
      margin-bottom: 22px; /* visually align with dots, not labels */
    }

    /* Summary row — Due / Progress / Tasks counts */
    .peek-summary {
      display: grid;
      grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
      gap: 12px 24px;
      padding: 14px 16px;
      background: var(--bg-elevated);
      border: 1px solid var(--border);
      border-radius: var(--radius-sm);
    }
    .peek-summary-item { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
    .peek-summary-label {
      font-size: 10px;
      letter-spacing: 0.12em;
      text-transform: uppercase;
      color: var(--text-40);
      font-weight: var(--fw-medium);
    }
    .peek-summary-value {
      font-size: var(--fs-sm);
      color: var(--text);
      font-weight: var(--fw-medium);
    }
    .peek-summary-sub {
      font-size: var(--fs-xs);
      color: var(--text-45);
    }
    .peek-progress-row { display: flex; align-items: center; gap: 8px; }
    .peek-progress-pct {
      font-size: var(--fs-sm);
      font-weight: var(--fw-medium);
      color: var(--text);
      min-width: 36px;
      text-align: right;
    }

    /* Next upcoming booking */
    .peek-booking {
      display: flex;
      align-items: center;
      gap: 12px;
      padding: 12px 14px;
      background: var(--bg-elevated);
      border: 1px solid var(--border);
      border-radius: var(--radius-sm);
    }
    .peek-booking-icon {
      width: 32px;
      height: 32px;
      flex-shrink: 0;
      display: flex;
      align-items: center;
      justify-content: center;
      background: var(--bg-card);
      border-radius: var(--radius-sm);
      color: var(--brand-accent);
    }
    .peek-booking-meta { flex: 1; min-width: 0; }
    .peek-booking-title { font-size: var(--fs-sm); color: var(--text); font-weight: var(--fw-medium); }
    .peek-booking-detail { font-size: var(--fs-xs); color: var(--text-45); margin-top: 2px; }

    /* Next-steps tasks */
    .peek-tasks { display: flex; flex-direction: column; gap: 4px; }
    .peek-section-header {
      display: flex;
      align-items: center;
      justify-content: space-between;
      padding: 4px 0;
    }
    .peek-section-title {
      font-size: 10px;
      letter-spacing: 0.12em;
      text-transform: uppercase;
      color: var(--text-40);
      font-weight: var(--fw-medium);
    }
    .peek-section-empty { font-size: var(--fs-xs); color: var(--text-40); font-style: italic; }
    .peek-task {
      display: flex;
      align-items: center;
      gap: 10px;
      padding: 6px 8px;
      border-radius: var(--radius-sm);
      transition: background 0.15s;
    }
    .peek-task:hover { background: var(--bg-elevated); }
    .peek-task.is-done .peek-task-title { color: var(--text-40); text-decoration: line-through; }
    .peek-task-title {
      flex: 1;
      font-size: var(--fs-sm);
      color: var(--text);
      min-width: 0;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
    }
    .peek-task-due { font-size: var(--fs-xs); color: var(--text-45); flex-shrink: 0; }
    .peek-task-more {
      font-size: var(--fs-xs);
      color: var(--text-45);
      padding: 4px 8px;
      font-style: italic;
    }

    /* Actions row */
    .peek-actions {
      display: flex;
      gap: 8px;
      flex-wrap: wrap;
      padding-top: 4px;
    }

    /* ─── Project Detail — rich header & overview panels ────────── */
    .pd-header {
      display: flex;
      flex-direction: column;
      gap: 24px;
      margin-bottom: 32px;
    }
    .pd-header-main { display: flex; flex-direction: column; gap: 8px; }

    .pd-meta-strip {
      display: grid;
      grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
      gap: 14px 28px;
      padding: 18px 22px;
      background: var(--bg-card);
      border: 1px solid var(--border);
      border-radius: var(--radius);
      width: 100%;
    }
    .pd-meta-item {
      display: flex;
      flex-direction: column;
      gap: 4px;
      min-width: 0;
    }
    .pd-meta-label {
      font-size: 10px;
      letter-spacing: 0.12em;
      text-transform: uppercase;
      color: var(--text-40);
      font-weight: var(--fw-medium);
    }
    .pd-meta-value {
      font-size: var(--fs-sm);
      color: var(--text);
      font-weight: var(--fw-medium);
      display: inline-flex;
      align-items: center;
      gap: 6px;
      flex-wrap: wrap;
    }
    .pd-meta-sub {
      font-size: var(--fs-xs);
      color: var(--text-45);
      margin-top: 2px;
    }
    .pd-meta-muted { font-size: var(--fs-sm); color: var(--text-40); font-style: italic; }
    .pd-meta-empty {
      background: transparent;
      border: 1px dashed var(--border-hover);
      color: var(--text-45);
      font-size: var(--fs-xs);
      padding: 4px 10px;
      border-radius: var(--radius-sm);
      cursor: pointer;
      font-family: var(--font);
      transition: all 0.15s;
    }
    .pd-meta-empty:hover { color: var(--text); border-color: var(--brand-accent); }

    /* Larger pill variants for the meta strip — match meta-strip type sizing */
    .mon-status-lg, .mon-priority-lg {
      font-size: 11px;
      padding: 4px 12px;
    }

    .pd-assignee-row {
      display: inline-flex;
      align-items: center;
      gap: -4px;
      margin-top: 2px;
    }
    .pd-assignee-chip {
      width: 28px;
      height: 28px;
      border-radius: 50%;
      background: var(--bg-elevated);
      border: 2px solid var(--bg-card);
      display: inline-flex;
      align-items: center;
      justify-content: center;
      font-size: 10px;
      font-weight: var(--fw-semi);
      color: var(--text);
      margin-left: -6px;
    }
    .pd-assignee-chip:first-child { margin-left: 0; }
    .pd-assignee-extra { background: var(--text-10); color: var(--text-60); font-size: 9px; }
    .pd-assignee-add {
      width: 28px; height: 28px; border-radius: 50%;
      background: transparent;
      border: 1px dashed var(--border-hover);
      color: var(--text-45);
      cursor: pointer;
      margin-left: 4px;
      font-size: 14px;
      line-height: 1;
      font-family: var(--font);
      transition: all 0.15s;
    }
    .pd-assignee-add:hover { border-color: var(--brand-accent); color: var(--brand-accent); }

    /* Progress is its own column like the others; the bar+pct row inside
       handles its own internal layout. Used to span 2 columns but that
       fought auto-fit and made the strip render half-width. */
    .pd-progress-row { display: flex; align-items: center; gap: 10px; margin-top: 2px; }
    .pd-progress-bar {
      flex: 1;
      height: 5px;
      background: var(--text-10);
      border-radius: 3px;
      overflow: hidden;
    }
    .pd-progress-fill {
      height: 100%;
      background: var(--brand-accent);
      transition: width 0.6s cubic-bezier(0.16, 1, 0.3, 1);
    }
    .pd-progress-pct {
      font-size: var(--fs-sm);
      font-weight: var(--fw-medium);
      color: var(--text);
      min-width: 40px;
      text-align: right;
    }

    /* Workflow pipeline on the full project detail page */
    .pd-pipeline {
      display: flex;
      align-items: center;
      gap: 0;
      padding: 16px 22px;
      background: var(--bg-card);
      border: 1px solid var(--border);
      border-radius: var(--radius);
      overflow-x: auto;
    }
    .peek-stage[data-action] { transition: transform 0.15s ease; }
    .peek-stage[data-action]:hover .peek-stage-dot {
      box-shadow: 0 0 0 4px rgba(var(--brand-accent-rgb), 0.18);
      border-color: var(--brand-accent);
    }
    .peek-stage[data-action]:hover .peek-stage-label { color: var(--text); }
    .peek-stage-next {
      margin-left: auto;
      flex-shrink: 0;
      align-self: center;
      margin-bottom: 22px;
    }

    /* ─── Project Detail panels (Tasks / Bookings / Milestones) ──── */
    .pd-panel {
      background: var(--bg-card);
      border: 1px solid var(--border);
      border-radius: var(--radius);
      padding: 22px;
      margin-bottom: 20px;
    }
    .pd-panel-header {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 12px;
      margin-bottom: 16px;
    }
    .pd-panel-count {
      font-size: var(--fs-xs);
      color: var(--text-45);
      letter-spacing: 0.04em;
    }

    /* Tasks — quick add + list */
    .pd-quick-add { margin-bottom: 12px; }
    .pd-quick-add-input {
      width: 100%;
      padding: 10px 14px;
      background: var(--bg-input);
      border: 1px solid var(--border);
      color: var(--text);
      font-family: var(--font);
      font-size: var(--fs-base);
      border-radius: var(--radius-sm);
      outline: none;
      transition: all 0.15s;
    }
    .pd-quick-add-input::placeholder { color: var(--text-40); }
    .pd-quick-add-input:focus {
      border-color: rgba(var(--brand-accent-rgb), 0.4);
      background: var(--bg-card-hover);
    }
    .pd-task-list { display: flex; flex-direction: column; }
    .pd-task-row {
      display: flex;
      align-items: center;
      gap: 12px;
      padding: 8px 0;
      border-bottom: 1px solid var(--border);
    }
    .pd-task-row:last-child { border-bottom: none; }
    .pd-task-row.is-done .pd-task-title {
      color: var(--text-40);
      text-decoration: line-through;
    }
    .pd-task-check {
      width: 16px;
      height: 16px;
      cursor: pointer;
      accent-color: var(--brand-accent);
      flex-shrink: 0;
    }
    .pd-task-title {
      flex: 1;
      font-size: var(--fs-base);
      color: var(--text);
      min-width: 0;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
    }
    .pd-task-tag {
      font-size: 10px;
      text-transform: uppercase;
      letter-spacing: 0.05em;
      color: var(--info);
      background: rgba(var(--info-rgb), 0.1);
      padding: 2px 8px;
      border-radius: 100px;
      flex-shrink: 0;
    }
    .pd-task-due {
      font-size: var(--fs-xs);
      color: var(--text-45);
      flex-shrink: 0;
    }
    .pd-task-del {
      background: none;
      border: none;
      color: var(--text-20);
      cursor: pointer;
      font-size: 18px;
      line-height: 1;
      padding: 4px 8px;
      border-radius: var(--radius-sm);
      flex-shrink: 0;
      opacity: 0;
      transition: opacity 0.15s, color 0.15s;
    }
    .pd-task-row:hover .pd-task-del { opacity: 1; }
    .pd-task-del:hover { color: var(--error); background: rgba(var(--error-rgb), 0.08); }

    .pd-tasks-done { margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--border); }
    .pd-tasks-done summary {
      font-size: var(--fs-xs);
      color: var(--text-45);
      cursor: pointer;
      padding: 6px 0;
      list-style: none;
    }
    .pd-tasks-done summary::before { content: '▸ '; color: var(--text-40); }
    .pd-tasks-done[open] summary::before { content: '▾ '; }

    /* Bookings panel */
    .pd-booking-list { display: flex; flex-direction: column; gap: 8px; }
    .pd-booking-row {
      display: flex;
      align-items: center;
      gap: 14px;
      padding: 12px 14px;
      background: var(--bg-elevated);
      border: 1px solid var(--border);
      border-radius: var(--radius-sm);
      transition: all 0.15s;
    }
    .pd-booking-row:hover { border-color: var(--border-hover); transform: translateY(-1px); }
    .pd-booking-date {
      width: 48px;
      flex-shrink: 0;
      text-align: center;
      padding: 4px 0;
      background: var(--bg-card);
      border-radius: var(--radius-sm);
      border: 1px solid var(--border);
    }
    .pd-booking-day {
      font-size: 18px;
      font-weight: var(--fw-semi);
      color: var(--text);
      line-height: 1.1;
    }
    .pd-booking-month {
      font-size: 9px;
      letter-spacing: 0.1em;
      color: var(--brand-accent);
      font-weight: var(--fw-semi);
    }
    .pd-booking-meta { flex: 1; min-width: 0; }
    .pd-booking-title {
      font-size: var(--fs-base);
      color: var(--text);
      font-weight: var(--fw-medium);
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
    }
    .pd-booking-detail {
      font-size: var(--fs-xs);
      color: var(--text-45);
      margin-top: 2px;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
    }
    .pd-booking-status {
      font-size: 10px;
      text-transform: uppercase;
      letter-spacing: 0.08em;
      padding: 3px 10px;
      border-radius: 100px;
      flex-shrink: 0;
      font-weight: var(--fw-semi);
      color: var(--text-60);
      background: var(--bg-card);
      border: 1px solid var(--border);
    }
    .pd-booking-status.status-confirmed { color: var(--success); border-color: rgba(var(--success-rgb), 0.3); background: rgba(var(--success-rgb), 0.08); }
    .pd-booking-status.status-completed { color: var(--success); border-color: rgba(var(--success-rgb), 0.3); background: rgba(var(--success-rgb), 0.08); }
    .pd-booking-status.status-cancelled { color: var(--priority-urgent); border-color: rgba(var(--priority-urgent-rgb), 0.3); background: rgba(var(--priority-urgent-rgb), 0.08); }

    .pd-bookings-past { margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--border); }
    .pd-bookings-past summary {
      font-size: var(--fs-xs);
      color: var(--text-45);
      cursor: pointer;
      padding: 6px 0;
      list-style: none;
    }
    .pd-bookings-past summary::before { content: '▸ '; color: var(--text-40); }
    .pd-bookings-past[open] summary::before { content: '▾ '; }

    /* Finance card on project detail */
    .pd-finance-grid {
      display: grid;
      grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
      gap: 10px;
    }
    .pd-finance-tile {
      padding: 14px 16px;
      background: var(--bg-elevated);
      border: 1px solid var(--border);
      border-radius: var(--radius-sm);
      display: flex;
      flex-direction: column;
      gap: 4px;
      cursor: pointer;
      transition: all 0.15s;
    }
    .pd-finance-tile:hover { border-color: var(--border-hover); transform: translateY(-1px); }
    .pd-finance-tile-paid { border-color: rgba(var(--success-rgb), 0.3); }
    .pd-finance-tile-paid .pd-finance-value { color: var(--success); }
    .pd-finance-tile-warn { border-color: rgba(var(--priority-urgent-rgb), 0.35); }
    .pd-finance-tile-warn .pd-finance-value { color: var(--priority-urgent); }
    .pd-finance-label {
      font-size: 10px;
      letter-spacing: 0.12em;
      text-transform: uppercase;
      color: var(--text-40);
      font-weight: var(--fw-medium);
    }
    .pd-finance-value {
      font-size: 22px;
      font-weight: var(--fw-medium);
      color: var(--text);
      letter-spacing: -0.01em;
      line-height: 1.2;
    }

    /* Project-specific activity timeline */
    .pd-activity-list { display: flex; flex-direction: column; }
    .pd-activity-row {
      display: flex;
      align-items: center;
      gap: 12px;
      padding: 10px 0;
      border-bottom: 1px solid var(--border);
    }
    .pd-activity-row:last-child { border-bottom: none; }
    .pd-activity-icon {
      width: 32px;
      height: 32px;
      flex-shrink: 0;
      display: flex;
      align-items: center;
      justify-content: center;
      background: var(--bg-elevated);
      border-radius: var(--radius-sm);
      font-size: 14px;
    }
    .pd-activity-meta { flex: 1; min-width: 0; }
    .pd-activity-text {
      font-size: var(--fs-sm);
      color: var(--text);
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
    }
    .pd-activity-detail {
      font-size: var(--fs-xs);
      color: var(--text-45);
      margin-top: 2px;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
    }
    .pd-activity-time {
      font-size: var(--fs-xs);
      color: var(--text-45);
      flex-shrink: 0;
      white-space: nowrap;
    }
    .pd-activity-more {
      font-size: var(--fs-xs);
      color: var(--text-45);
      padding: 8px 0 0;
      font-style: italic;
      text-align: center;
    }

    /* ─── Project cover image — used on cards, hero, thumbnails ─── */
    .project-cover {
      width: 100%;
      background-size: cover;
      background-position: center;
      background-color: var(--bg-elevated);
      position: relative;
      overflow: hidden;
    }
    /* Subtle vignette so overlaid titles stay legible regardless of photo */
    .project-cover::after {
      content: '';
      position: absolute;
      inset: 0;
      background: linear-gradient(180deg, transparent 50%, rgba(0,0,0,0.35) 100%);
      pointer-events: none;
    }
    /* Typographic fallback — used when a project has no images yet.
       The hue is seeded per-project via --seed-hue so each card has its own
       identity, but always with the brand red as the warm tint. */
    .project-cover--fallback {
      background:
        radial-gradient(ellipse at 30% 20%, rgba(var(--brand-accent-rgb), 0.18), transparent 60%),
        linear-gradient(135deg, hsl(var(--seed-hue, 14), 14%, 14%) 0%, hsl(var(--seed-hue, 14), 16%, 9%) 100%);
      display: flex;
      align-items: center;
      justify-content: center;
    }
    .project-cover--fallback::after { display: none; }
    .project-cover-initial {
      font-size: clamp(48px, 12vw, 96px);
      font-weight: 200;
      letter-spacing: -0.04em;
      color: rgba(255,255,255,0.18);
      line-height: 1;
      user-select: none;
    }
    /* Small variant for activity feed thumbnails, sidebar lists, etc. */
    .project-cover--thumb {
      width: 40px;
      height: 40px;
      border-radius: var(--radius-sm);
      flex-shrink: 0;
      aspect-ratio: 1/1 !important;
    }
    .project-cover--thumb .project-cover-initial { font-size: 16px; font-weight: 500; color: rgba(255,255,255,0.55); }
    .project-cover--thumb::after { display: none; }
    /* Hero variant for project detail page */
    .project-cover--hero {
      width: 100%;
      max-height: 320px;
      border-radius: var(--radius-lg);
      margin-bottom: 32px;
    }
    .project-cover--hero .project-cover-initial { font-size: clamp(72px, 20vw, 180px); }

    .project-card:hover {
      background: var(--bg-card-hover);
      border-color: var(--border-hover);
      transform: translateY(-1px);
    }

    .project-card-header {
      display: flex;
      justify-content: space-between;
      align-items: flex-start;
    }

    .project-card h3 {
      font-size: 18px;
      font-weight: 500;
      letter-spacing: -0.2px;
    }

    .project-status {
      font-size: 10px;
      font-weight: 600;
      letter-spacing: 1.5px;
      text-transform: uppercase;
      padding: 4px 12px;
      border: 1px solid;
      white-space: nowrap;
      border-radius: 100px;
      display: inline-block;
    }

    .status-active { color: var(--success); border-color: rgba(var(--success-rgb), 0.3); background: rgba(var(--success-rgb), 0.08); }
    .status-review { color: var(--warning); border-color: rgba(var(--warning-rgb), 0.3); background: rgba(var(--warning-rgb), 0.08); }
    .status-complete { color: var(--text-45); border-color: var(--border); }
    .status-upcoming { color: var(--text-40); border-color: var(--border); }

    .project-card-desc {
      font-size: 14px;
      color: var(--text-45);
      font-weight: 400;
      line-height: 1.5;
    }

    .project-card-meta {
      display: flex;
      justify-content: space-between;
      align-items: center;
      padding-top: 14px;
      border-top: 1px solid var(--border);
    }

    .project-card-meta span {
      font-size: 12px;
      color: var(--text-40);
      letter-spacing: 0.5px;
    }

    .progress-bar {
      flex: 1;
      max-width: 180px;
      min-width: 80px;
      height: 4px;
      background: var(--text-10);
      overflow: hidden;
      border-radius: 4px;
    }

    .progress-fill {
      height: 100%;
      background: var(--text);
      transition: width 0.6s ease;
      border-radius: 4px;
    }

    /* ─── PROJECT DETAIL ─── */
    .back-link {
      display: inline-flex;
      align-items: center;
      gap: 8px;
      font-size: 12px;
      letter-spacing: 1.5px;
      text-transform: uppercase;
      color: var(--text-40);
      text-decoration: none;
      cursor: pointer;
      margin-bottom: 32px;
      transition: color 0.2s;
      background: none;
      border: none;
      font-family: var(--font);
    }

    .back-link:hover { color: var(--text-60); }

    .project-detail-header {
      display: flex;
      justify-content: space-between;
      align-items: flex-start;
      margin-bottom: 56px;
    }

    .project-detail-title {
      font-size: var(--fs-3xl);
      font-weight: var(--fw-medium);
      letter-spacing: -0.5px;
      margin-bottom: 8px;
      max-width: 100%;
      overflow-wrap: break-word;
      word-break: break-word;
    }

    .project-detail-title strong { font-weight: var(--fw-semi); }

    .project-detail-desc {
      font-size: 15px;
      color: var(--text-45);
      font-weight: 400;
      max-width: 600px;
    }

    /* ─── MILESTONES ─── */
    .section-heading {
      font-size: 11px;
      letter-spacing: 3px;
      text-transform: uppercase;
      color: var(--text-40);
      margin-bottom: 24px;
      padding-bottom: 12px;
      border-bottom: 1px solid var(--border);
    }

    .milestones {
      margin-bottom: 56px;
    }

    .milestone {
      display: flex;
      align-items: flex-start;
      gap: 20px;
      padding: 20px 0;
      border-bottom: 1px solid var(--border);
    }

    .milestone:last-child { border-bottom: none; }

    .milestone-indicator {
      width: 10px;
      height: 10px;
      border-radius: 50%;
      margin-top: 5px;
      flex-shrink: 0;
    }

    .milestone-indicator.complete { background: var(--success); }
    .milestone-indicator.active { background: var(--text); box-shadow: 0 0 0 3px rgba(255,255,255,0.15); }
    .milestone-indicator.pending { background: var(--text-20); }

    .milestone-content { flex: 1; }

    .milestone-name {
      font-size: 15px;
      font-weight: 400;
      margin-bottom: 4px;
    }

    .milestone-date {
      font-size: 12px;
      color: var(--text-40);
    }

    .milestone-status-text {
      font-size: 11px;
      letter-spacing: 1px;
      text-transform: uppercase;
      margin-top: 4px;
    }

    /* ─── FILES ─── */
    .files-grid {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
      gap: 10px;
    }

    .file-card {
      background: var(--bg-card);
      border: 1px solid var(--border);
      padding: 20px 24px;
      display: flex;
      align-items: center;
      gap: 16px;
      text-decoration: none;
      color: var(--text);
      transition: all 0.2s;
      border-radius: var(--radius);
    }

    .file-card:hover { background: var(--bg-card-hover); border-color: var(--border-hover); }

    .file-icon {
      width: 40px;
      height: 40px;
      display: flex;
      align-items: center;
      justify-content: center;
      border: 1px solid var(--border);
      font-size: 11px;
      letter-spacing: 1px;
      text-transform: uppercase;
      color: var(--text-45);
      flex-shrink: 0;
      border-radius: var(--radius-sm);
      background: var(--bg-glass);
    }

    .file-info { flex: 1; min-width: 0; }

    .file-name {
      font-size: 14px;
      font-weight: 400;
      white-space: nowrap;
      overflow: hidden;
      text-overflow: ellipsis;
    }

    .file-meta {
      font-size: 12px;
      color: var(--text-40);
      margin-top: 2px;
    }

    .file-arrow {
      color: var(--text-20);
      font-size: 16px;
      transition: color 0.2s;
    }

    .file-card:hover .file-arrow { color: var(--text-45); }

    /* ─── REFERENCE FILES (property outlines) ─── */
    .ref-files-section { margin-top: 2rem; }
    .ref-files-list { margin-bottom: 12px; }
    .ref-file-item {
      display: flex; align-items: center; gap: 10px;
      padding: 10px 14px; background: var(--bg-input);
      border: 1px solid var(--border); border-radius: 8px; margin-bottom: 8px;
    }
    .ref-file-ext {
      font-size: 10px; text-transform: uppercase; font-weight: 600;
      color: var(--accent); background: rgba(255,255,255,0.04);
      padding: 4px 8px; border-radius: 4px; min-width: 36px; text-align: center;
    }
    .ref-file-name { flex: 1; font-size: 13px; color: var(--text-60); }
    .ref-file-name a { color: var(--text-60); text-decoration: none; }
    .ref-file-name a:hover { color: var(--text-80); }
    .ref-file-size { font-size: 11px; color: var(--text-30); }
    .ref-file-del {
      cursor: pointer; color: var(--text-30); font-size: 16px;
      padding: 2px 6px; border-radius: 4px; transition: color 0.2s;
    }
    .ref-file-del:hover { color: #e55; }
    .ref-drop-zone {
      border: 2px dashed var(--border); border-radius: 8px;
      padding: 1.5rem; text-align: center; cursor: pointer;
      transition: border-color 0.2s, background 0.2s;
      color: var(--text-30); font-size: 13px;
    }
    .ref-drop-zone:hover, .ref-drop-zone.dragover {
      border-color: var(--accent); background: rgba(255,255,255,0.02);
      color: var(--text-45);
    }
    .ref-drop-zone svg { margin-bottom: 6px; opacity: 0.4; }
    .ref-upload-progress {
      margin-top: 8px; font-size: 12px; color: var(--accent);
    }

    /* Sidebar styles, light-mode sidebar overrides, and mobile sidebar
       media query all live in sidebar.css (single source of truth).
       Removed duplicates from components.css. */

    /* Light-mode overrides for non-sidebar surfaces — these aren't in sidebar.css */
    [data-theme="light"] .wm-filter-bar { background: rgba(255,255,255,0.7); }
    [data-theme="light"] .wm-filter-select { background: #fff; color: #333; }
    [data-theme="light"] .wm-group-header:hover { background: rgba(0,0,0,0.03); }
    [data-theme="light"] .wm-timeline { background: rgba(0,0,0,0.06); }
    [data-theme="light"] .wm-status-click:hover, [data-theme="light"] .wm-priority-click:hover {
      box-shadow: 0 0 0 2px rgba(0,0,0,0.08);
    }

    /* Legacy tab styles kept for compat */
    .admin-tabs { display: none; }
    .admin-tab { display: none; }

    /* ─── Work Management — view switcher ──────────────────────── */
    .wm-view-switcher {
      display: inline-flex;
      align-items: center;
      gap: 2px;
      padding: 2px;
      background: var(--bg-card);
      border: 1px solid var(--border);
      border-radius: var(--radius-sm);
      margin-bottom: 16px;
    }
    .wm-view-btn {
      display: inline-flex;
      align-items: center;
      gap: 6px;
      padding: 6px 12px;
      background: transparent;
      border: none;
      color: var(--text-60);
      font-size: var(--fs-sm);
      font-weight: var(--fw-medium);
      font-family: var(--font);
      cursor: pointer;
      border-radius: 6px;
      transition: all 0.15s ease;
    }
    .wm-view-btn:hover { color: var(--text); background: var(--bg-card-hover); }
    .wm-view-btn.active {
      background: var(--bg-elevated);
      color: var(--text);
      box-shadow: 0 1px 3px rgba(0,0,0,0.2);
    }
    .wm-view-btn.active svg { color: var(--brand-accent); }

    /* ─── Search ───────────────────────────────────────────────── */
    .wm-search {
      position: relative;
      flex: 1;
      max-width: 320px;
      min-width: 180px;
    }
    .wm-search-input {
      width: 100%;
      padding: 7px 12px 7px 32px;
      background: var(--bg-input);
      border: 1px solid var(--border);
      color: var(--text);
      font-family: var(--font);
      font-size: var(--fs-sm);
      border-radius: var(--radius-sm);
      outline: none;
      transition: all 0.15s;
    }
    .wm-search-input::placeholder { color: var(--text-40); }
    .wm-search-input:focus { border-color: rgba(var(--brand-accent-rgb), 0.4); background: var(--bg-card-hover); }
    .wm-search-icon {
      position: absolute;
      left: 10px;
      top: 50%;
      transform: translateY(-50%);
      color: var(--text-40);
      pointer-events: none;
    }

    /* ─── Bulk select + bulk action bar ────────────────────────── */
    .wm-checkbox {
      width: 16px;
      height: 16px;
      cursor: pointer;
      accent-color: var(--brand-accent);
      margin: 0;
    }
    .mon-cell-check {
      width: 32px;
      flex: 0 0 32px;
      display: flex;
      align-items: center;
      justify-content: center;
      padding: 0 8px;
    }
    .mon-row-selected {
      background: rgba(var(--brand-accent-rgb), 0.06) !important;
      box-shadow: inset 3px 0 0 var(--brand-accent);
    }
    .wm-bulk-bar {
      position: fixed;
      bottom: 24px;
      left: 50%;
      transform: translateX(-50%);
      background: var(--bg-elevated);
      border: 1px solid var(--border-hover);
      border-radius: var(--radius-lg);
      padding: 12px 16px;
      display: flex;
      align-items: center;
      gap: 16px;
      box-shadow: 0 12px 32px rgba(0,0,0,0.5);
      z-index: 200;
      animation: bulkBarIn 0.25s cubic-bezier(0.16, 1, 0.3, 1);
      max-width: calc(100vw - 48px);
      flex-wrap: wrap;
    }
    @keyframes bulkBarIn {
      from { opacity: 0; transform: translate(-50%, 12px); }
      to   { opacity: 1; transform: translate(-50%, 0); }
    }
    .wm-bulk-bar-count {
      font-size: var(--fs-sm);
      font-weight: var(--fw-medium);
      color: var(--text);
      padding-right: 14px;
      border-right: 1px solid var(--border);
    }
    .wm-bulk-bar-actions {
      display: flex;
      gap: 8px;
      align-items: center;
      flex-wrap: wrap;
    }
    .wm-bulk-select {
      padding: 6px 10px;
      background: var(--bg-card);
      border: 1px solid var(--border);
      color: var(--text);
      font-family: var(--font);
      font-size: var(--fs-sm);
      border-radius: var(--radius-sm);
      cursor: pointer;
    }

    /* ─── Kanban board ─────────────────────────────────────────── */
    .kanban-board {
      display: flex;
      gap: 16px;
      overflow-x: auto;
      padding-bottom: 24px;
      align-items: flex-start;
    }
    .kanban-column {
      flex: 0 0 300px;
      min-height: 200px;
      background: var(--bg-card);
      border: 1px solid var(--border);
      border-radius: var(--radius);
      display: flex;
      flex-direction: column;
      max-height: calc(100vh - 280px);
    }
    .kanban-column-header {
      display: flex;
      align-items: center;
      gap: 8px;
      padding: 14px 16px;
      border-bottom: 1px solid var(--border);
      flex-shrink: 0;
    }
    .kanban-column-dot {
      width: 8px;
      height: 8px;
      border-radius: 50%;
      flex-shrink: 0;
    }
    .kanban-column-title {
      font-size: var(--fs-sm);
      font-weight: var(--fw-semi);
      color: var(--text);
      letter-spacing: -0.01em;
    }
    .kanban-column-count {
      font-size: var(--fs-xs);
      color: var(--text-40);
      margin-left: auto;
      background: var(--bg-elevated);
      padding: 2px 8px;
      border-radius: 100px;
    }
    .kanban-column-body {
      padding: 8px;
      display: flex;
      flex-direction: column;
      gap: 8px;
      overflow-y: auto;
      flex: 1;
    }
    .kanban-column-empty {
      padding: 24px 12px;
      text-align: center;
      color: var(--text-40);
      font-size: var(--fs-xs);
      border: 1px dashed var(--border);
      border-radius: var(--radius-sm);
    }
    .kanban-card {
      background: var(--bg-elevated);
      border: 1px solid var(--border);
      border-radius: var(--radius-sm);
      cursor: pointer;
      overflow: hidden;
      transition: all 0.15s ease;
    }
    .kanban-card:hover {
      border-color: var(--border-hover);
      transform: translateY(-1px);
      box-shadow: 0 4px 12px rgba(0,0,0,0.2);
    }
    .kanban-card-selected {
      border-color: var(--brand-accent);
      box-shadow: 0 0 0 1px var(--brand-accent);
    }
    .kanban-card-cover {
      width: 100%;
      aspect-ratio: 16/9 !important;
    }
    .kanban-card-body { padding: 10px 12px; display: flex; flex-direction: column; gap: 8px; }
    .kanban-card-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
    .kanban-card-check { flex-shrink: 0; }
    .kanban-card-title {
      font-size: var(--fs-sm);
      font-weight: var(--fw-medium);
      color: var(--text);
      line-height: 1.3;
      overflow: hidden;
      text-overflow: ellipsis;
      display: -webkit-box;
      -webkit-line-clamp: 2;
      -webkit-box-orient: vertical;
    }
    .kanban-card-client {
      display: inline-block;
      align-self: flex-start;
      font-size: 10px;
      font-weight: var(--fw-medium);
      color: #fff;
      padding: 2px 8px;
      border-radius: 100px;
      letter-spacing: 0.02em;
      max-width: 100%;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
    }
    .kanban-card-meta {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 6px;
      margin-top: 2px;
    }
    .kanban-card-due {
      font-size: var(--fs-xs);
      color: var(--text-45);
    }
    .kanban-card-due.overdue { color: var(--priority-urgent); font-weight: var(--fw-medium); }
    .kanban-card-due.soon { color: var(--warning); }
    .kanban-card-person {
      width: 24px;
      height: 24px;
      border-radius: 50%;
      background: var(--bg-card);
      border: 1px solid var(--border);
      display: inline-flex;
      align-items: center;
      justify-content: center;
      font-size: 10px;
      font-weight: var(--fw-semi);
      color: var(--text-60);
      position: relative;
      flex-shrink: 0;
    }
    .kanban-card-person-extra {
      position: absolute;
      top: -4px;
      right: -6px;
      background: var(--text-40);
      color: var(--bg);
      font-size: 8px;
      border-radius: 50%;
      width: 14px;
      height: 14px;
      display: flex;
      align-items: center;
      justify-content: center;
    }
    .kanban-card-progress {
      height: 3px;
      background: var(--text-10);
      border-radius: 2px;
      overflow: hidden;
    }
    .kanban-card-progress-bar {
      height: 100%;
      background: var(--brand-accent);
      transition: width 0.4s ease;
    }

    /* ─── Timeline (Gantt-ish) view ─────────────────────────────── */
    .timeline-view {
      background: var(--bg-card);
      border: 1px solid var(--border);
      border-radius: var(--radius);
      overflow: hidden;
      margin-bottom: 24px;
    }
    .timeline-scroll {
      overflow-x: auto;
      overflow-y: hidden;
      max-width: 100%;
    }
    .timeline-axis {
      position: relative;
      height: 36px;
      border-bottom: 1px solid var(--border);
      flex-shrink: 0;
      background: var(--bg-elevated);
    }
    .timeline-tick {
      position: absolute;
      top: 0;
      bottom: 0;
      border-left: 1px solid var(--border);
    }
    .timeline-tick.is-month {
      border-left-color: var(--border-hover);
    }
    .timeline-tick-label {
      position: absolute;
      top: 9px;
      left: 6px;
      font-size: var(--fs-xs);
      color: var(--text-60);
      font-weight: var(--fw-medium);
      letter-spacing: 0.02em;
      white-space: nowrap;
    }
    .timeline-today-line {
      position: absolute;
      top: 0;
      bottom: 0;
      width: 1px;
      background: var(--brand-accent);
      opacity: 0.7;
      pointer-events: none;
      z-index: 2;
    }
    .timeline-today-line::before {
      content: '';
      position: absolute;
      top: 0;
      left: -3px;
      width: 7px;
      height: 7px;
      background: var(--brand-accent);
      border-radius: 50%;
    }
    .timeline-today-line-content { opacity: 0.25; }
    .timeline-content { position: relative; }
    .timeline-group {
      border-bottom: 1px solid var(--border);
    }
    .timeline-group:last-child { border-bottom: none; }
    .timeline-group-header {
      position: sticky;
      left: 0;
      padding: 8px 16px;
      font-size: var(--fs-xs);
      text-transform: uppercase;
      letter-spacing: 0.08em;
      color: var(--text-60);
      background: var(--bg-card);
      border-bottom: 1px solid var(--border);
      display: flex;
      align-items: center;
      gap: 8px;
      z-index: 1;
    }
    .timeline-group-dot {
      width: 8px;
      height: 8px;
      border-radius: 50%;
    }
    .timeline-rows { position: relative; padding: 6px 0; }
    .timeline-row {
      position: relative;
      height: 36px;
      display: flex;
      align-items: center;
    }
    .timeline-bar {
      position: absolute;
      top: 8px;
      height: 22px;
      background: rgba(var(--text-rgb, 240,240,240), 0.04);
      border: 1px solid rgba(255,255,255,0.06);
      border-left: 3px solid var(--bar-color, var(--text-40));
      border-radius: var(--radius-sm);
      cursor: pointer;
      display: flex;
      align-items: center;
      padding: 0 10px;
      transition: all 0.15s ease;
      overflow: hidden;
    }
    .timeline-bar:hover {
      background: var(--bg-card-hover);
      transform: translateY(-1px);
      z-index: 3;
    }
    .timeline-bar-overdue { border-color: var(--priority-urgent); }
    .timeline-bar-fill {
      position: absolute;
      top: 0;
      bottom: 0;
      left: 0;
      background: var(--bar-color);
      opacity: 0.18;
      pointer-events: none;
    }
    .timeline-bar-label {
      position: relative;
      font-size: var(--fs-xs);
      font-weight: var(--fw-medium);
      color: var(--text);
      white-space: nowrap;
      overflow: hidden;
      text-overflow: ellipsis;
      z-index: 1;
    }

    /* ─── TRAINING PORTAL STYLES ─── */
    .training-grid {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
      gap: 20px;
    }
    .training-card {
      background: var(--bg-card);
      border: 1px solid var(--border);
      border-radius: var(--radius);
      padding: 16px;
      transition: border-color 0.2s;
    }
    .training-card:hover { border-color: var(--border-hover); }
    .training-video-wrap {
      position: relative;
      padding-bottom: 56.25%;
      height: 0;
      overflow: hidden;
      border-radius: var(--radius-sm);
      margin-bottom: 12px;
      background: rgba(0,0,0,0.3);
    }
    .training-card-title {
      font-size: 0.9rem;
      font-weight: 600;
      color: var(--text);
      margin-bottom: 4px;
    }
    .training-card-desc {
      font-size: 0.8rem;
      color: var(--text-60);
      line-height: 1.5;
    }
    .training-list {
      display: flex;
      flex-direction: column;
      gap: 2px;
    }
    .training-doc-row {
      display: flex;
      align-items: center;
      gap: 12px;
      padding: 12px 16px;
      background: var(--bg-card);
      border: 1px solid var(--border);
      border-radius: var(--radius-sm);
      text-decoration: none;
      color: var(--text);
      transition: border-color 0.2s, background 0.2s;
    }
    .training-doc-row:hover {
      border-color: var(--border-hover);
      background: var(--bg-card-hover);
    }
    .training-sop-grid {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
      gap: 20px;
    }
    .sop-card {
      position: relative;
      border-radius: var(--radius);
      overflow: hidden;
      cursor: grab;
      aspect-ratio: 1/1;
      background: var(--bg-card);
      border: 1px solid var(--border);
      transition: transform 0.2s, border-color 0.2s, box-shadow 0.2s;
    }
    .sop-card:hover {
      transform: translateY(-4px);
      border-color: var(--border-hover);
      box-shadow: 0 12px 40px rgba(0,0,0,0.15);
    }
    .sop-card.dragging {
      opacity: 0.4;
      transform: scale(0.95);
    }
    .sop-card.drag-over {
      border-color: #5a9a6e;
      box-shadow: 0 0 0 2px rgba(90,154,110,0.4);
    }
    .sop-card-image {
      position: absolute;
      top: 0;
      left: 0;
      width: 100%;
      height: 100%;
      object-fit: cover;
      opacity: 0.85;
      transition: opacity 0.3s;
    }
    .sop-card:hover .sop-card-image { opacity: 1; }
    .sop-card-placeholder {
      position: absolute;
      top: 0;
      left: 0;
      width: 100%;
      height: 100%;
      background: linear-gradient(135deg, var(--bg-elevated) 0%, var(--bg-card) 100%);
      display: flex;
      align-items: center;
      justify-content: center;
    }
    .sop-card-placeholder svg {
      width: 48px;
      height: 48px;
      color: var(--text-20);
    }
    .sop-card-overlay {
      position: absolute;
      bottom: 0;
      left: 0;
      right: 0;
      padding: 24px 20px 20px;
      background: linear-gradient(to top, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.4) 60%, transparent 100%);
      z-index: 1;
    }
    .sop-card-title {
      font-size: 1rem;
      font-weight: 600;
      color: #fff;
      line-height: 1.3;
      margin-bottom: 4px;
    }
    .sop-card-desc {
      font-size: 0.75rem;
      color: rgba(255,255,255,0.6);
      line-height: 1.4;
      display: -webkit-box;
      -webkit-line-clamp: 2;
      -webkit-box-orient: vertical;
      overflow: hidden;
    }
    .sop-card-btn {
      position: absolute;
      top: 12px;
      right: 12px;
      width: 32px;
      height: 32px;
      border-radius: 50%;
      background: #5a9a6e;
      border: none;
      display: flex;
      align-items: center;
      justify-content: center;
      cursor: pointer;
      z-index: 2;
      transition: transform 0.2s;
    }
    .sop-card:hover .sop-card-btn { transform: scale(1.1); }
    .sop-card-btn svg {
      width: 16px;
      height: 16px;
      color: #000;
    }

    /* SOP Modal */
    .sop-modal-overlay {
      position: fixed;
      top: 0;
      left: 0;
      right: 0;
      bottom: 0;
      background: rgba(0,0,0,0.7);
      backdrop-filter: blur(8px);
      z-index: 1000;
      display: flex;
      align-items: center;
      justify-content: center;
      padding: 40px;
    }
    .sop-modal {
      background: var(--bg-elevated);
      border: 1px solid var(--border);
      border-radius: var(--radius-lg);
      max-width: 720px;
      width: 100%;
      max-height: 80vh;
      overflow-y: auto;
      position: relative;
    }
    .sop-modal-header {
      position: relative;
      overflow: hidden;
      border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    }
    .sop-modal-header-img {
      width: 100%;
      height: 200px;
      object-fit: cover;
      display: block;
    }
    .sop-modal-header-placeholder {
      width: 100%;
      height: 200px;
      background: linear-gradient(135deg, var(--bg-card) 0%, var(--bg-elevated) 100%);
    }
    .sop-modal-header-overlay {
      position: absolute;
      bottom: 0;
      left: 0;
      right: 0;
      padding: 20px 24px;
      background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    }
    .sop-modal-title {
      font-size: 1.3rem;
      font-weight: 600;
      color: #fff;
    }
    .sop-modal-close {
      position: absolute;
      top: 12px;
      right: 12px;
      width: 36px;
      height: 36px;
      border-radius: 50%;
      background: rgba(0,0,0,0.5);
      border: none;
      color: #fff;
      font-size: 20px;
      cursor: pointer;
      display: flex;
      align-items: center;
      justify-content: center;
      z-index: 2;
      transition: background 0.2s;
    }
    .sop-modal-close:hover { background: rgba(0,0,0,0.7); }
    .sop-modal-body {
      padding: 24px;
    }
    .sop-modal-desc {
      color: var(--text-60);
      font-size: 0.9rem;
      margin-bottom: 16px;
      line-height: 1.6;
    }
    .sop-modal-content {
      font-size: 0.85rem;
      line-height: 1.7;
      color: var(--text-80);
    }
    .sop-modal-content h3 { font-size: 1rem; margin: 28px 0 12px; color: var(--text); padding-top: 20px; border-top: 1px solid var(--border); }
    .sop-modal-content h3:first-child { margin-top: 0; padding-top: 0; border-top: none; }
    .sop-modal-content h4 { font-size: 0.9rem; margin: 20px 0 8px; color: var(--text); }
    .sop-modal-content ul, .sop-modal-content ol { padding-left: 20px; margin: 12px 0; }
    .sop-modal-content li { margin-bottom: 6px; line-height: 1.7; }
    .sop-modal-content p { margin: 12px 0; }
    .sop-modal-content div { margin: 12px 0; }
    .sop-modal-content strong { color: var(--text); }

    .admin-form {
      max-width: 500px;
      display: flex;
      flex-direction: column;
      gap: 20px;
    }

    .form-group label {
      display: block;
      font-size: 11px;
      letter-spacing: 2px;
      text-transform: uppercase;
      color: var(--text-40);
      margin-bottom: 8px;
    }

    .form-group input,
    .form-group textarea,
    .form-group select {
      width: 100%;
      background: var(--bg-input);
      border: 1px solid var(--border);
      color: var(--text);
      font-family: var(--font);
      font-size: 14px;
      font-weight: 400;
      padding: 12px 16px;
      outline: none;
      transition: all 0.2s;
      border-radius: var(--radius-sm);
    }

    .form-group input:focus,
    .form-group textarea:focus,
    .form-group select:focus {
      border-color: var(--border-hover);
      background: var(--bg-card-hover);
    }

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

    .form-group select {
      appearance: none;
      cursor: pointer;
    }

    .form-actions {
      display: flex;
      gap: 12px;
      margin-top: 8px;
    }

    /* Action buttons — sentence-case, comfortable size, less branding-loud.
       Use .btn-uppercase for the rare CTA (login submit, hero CTAs) where
       categorical / branded uppercase reads as deliberate. */
    .btn-primary {
      background: var(--text);
      color: var(--bg);
      border: none;
      padding: 9px 18px;
      font-size: var(--fs-base);
      letter-spacing: -0.01em;
      font-family: var(--font);
      cursor: pointer;
      transition: all 0.2s ease;
      border-radius: var(--radius-sm);
      font-weight: var(--fw-medium);
    }
    .btn-primary:hover { opacity: 0.88; transform: translateY(-1px); box-shadow: 0 4px 12px rgba(0,0,0,0.15); }
    .btn-primary:active { transform: translateY(0) scale(0.98); opacity: 0.95; transition-duration: 0.1s; }

    .btn-secondary {
      background: var(--bg-card);
      border: 1px solid var(--border);
      color: var(--text);
      padding: 9px 18px;
      font-size: var(--fs-base);
      letter-spacing: -0.01em;
      font-family: var(--font);
      cursor: pointer;
      transition: all 0.2s;
      border-radius: var(--radius-sm);
      font-weight: var(--fw-medium);
    }
    .btn-secondary:hover { border-color: var(--border-hover); color: var(--text); background: var(--bg-card-hover); }
    .btn-secondary:active { transform: scale(0.98); transition-duration: 0.1s; }

    .btn-danger {
      background: rgba(var(--error-rgb),0.08);
      border: 1px solid rgba(var(--error-rgb),0.25);
      color: var(--error);
      padding: 9px 18px;
      font-size: var(--fs-base);
      letter-spacing: -0.01em;
      font-family: var(--font);
      cursor: pointer;
      transition: all 0.2s;
      border-radius: var(--radius-sm);
      font-weight: var(--fw-medium);
    }
    .btn-danger:hover { border-color: rgba(var(--error-rgb),0.45); background: rgba(var(--error-rgb),0.12); }

    /* Modifiers */
    .btn-uppercase {
      text-transform: uppercase;
      letter-spacing: 1.5px;
      font-size: 12px;
      border-radius: 100px;
    }
    .btn-sm { padding: 6px 12px; font-size: var(--fs-sm); }
    .btn-lg { padding: 12px 24px; font-size: var(--fs-md); }

    .btn-danger-text { color: rgba(var(--error-rgb),0.85) !important; }
    .btn-danger-text:hover { color: var(--error) !important; background: rgba(var(--error-rgb),0.08) !important; }

    /* Admin tables — column rhythm is locked across all tabs:
         · First column (identifier — Name / Project / Title): 280px
         · Last column (Actions): 140px, right-aligned
         · Middle columns share the leftover space evenly via table-layout: fixed
       Result: NAME always starts at the same x-position and ACTIONS always
       ends at the right edge. Tab-to-tab feels stable instead of jittery. */
    .admin-table {
      width: 100%;
      border-collapse: collapse;
      table-layout: fixed;
    }

    .admin-table th:first-child,
    .admin-table td:first-child {
      width: 280px;
    }
    .admin-table th:last-child,
    .admin-table td:last-child,
    .admin-table .actions {
      width: 64px;
      text-align: right;
    }

    .admin-table th {
      text-align: left;
      font-size: 11px;
      letter-spacing: 2px;
      text-transform: uppercase;
      color: var(--text-40);
      padding: 12px 16px;
      border-bottom: none;
      box-shadow: inset 0 -1px 0 var(--border);
      font-weight: 400;
    }
    .admin-table th:last-child { text-align: right; }

    .admin-table td {
      padding: 14px 16px;
      border-bottom: none;
      box-shadow: inset 0 -1px 0 var(--border);
      font-size: 13px;
      font-weight: 400;
      vertical-align: middle;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
    }
    /* Allow specific cells (e.g. with progress bars + labels) to wrap */
    .admin-table td.wrap { white-space: normal; }
    .admin-table tbody tr:last-child td {
      box-shadow: none;
    }

    .admin-table tbody tr {
      animation: tableRowIn 0.35s ease both;
    }
    .admin-table tbody tr:nth-child(1) { animation-delay: 0s; }
    .admin-table tbody tr:nth-child(2) { animation-delay: 0.03s; }
    .admin-table tbody tr:nth-child(3) { animation-delay: 0.06s; }
    .admin-table tbody tr:nth-child(4) { animation-delay: 0.09s; }
    .admin-table tbody tr:nth-child(5) { animation-delay: 0.12s; }
    .admin-table tbody tr:nth-child(6) { animation-delay: 0.15s; }
    .admin-table tbody tr:nth-child(7) { animation-delay: 0.18s; }
    .admin-table tbody tr:nth-child(8) { animation-delay: 0.21s; }
    .admin-table tbody tr:nth-child(9) { animation-delay: 0.24s; }
    .admin-table tbody tr:nth-child(10) { animation-delay: 0.27s; }
    @keyframes tableRowIn {
      from { opacity: 0; }
      to { opacity: 1; }
    }
    .admin-table tr:hover td { background: var(--bg-card); transition: background 0.2s ease; }

    .admin-table .actions {
      white-space: nowrap;
      overflow: visible; /* let the kebab popover escape the cell */
    }

    /* ─── Row action menu (⋯ kebab + popover) ──────────────────
       Used in every admin table for a consistent Actions cell.
       One trigger button per row, dropdown reveals row-specific actions. */
    .action-menu {
      position: relative;
      display: inline-flex;
      justify-content: flex-end;
    }
    .action-menu-trigger {
      width: 30px;
      height: 30px;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      background: transparent;
      border: 1px solid transparent;
      border-radius: var(--radius-sm);
      color: var(--text-45);
      cursor: pointer;
      padding: 0;
      font-family: var(--font);
      transition: all 0.15s;
    }
    .action-menu-trigger:hover { color: var(--text); background: var(--bg-card-hover); border-color: var(--border-hover); }
    .action-menu.is-open .action-menu-trigger { color: var(--text); background: var(--bg-card-hover); border-color: var(--border-hover); }
    .action-menu-popover {
      position: absolute;
      top: calc(100% + 4px);
      right: 0;
      min-width: 160px;
      background: var(--bg-elevated);
      border: 1px solid var(--border-hover);
      border-radius: var(--radius-sm);
      box-shadow: 0 12px 32px rgba(0,0,0,0.45);
      z-index: 80;
      padding: 4px;
      display: flex;
      flex-direction: column;
      animation: actionMenuIn 0.15s cubic-bezier(0.16, 1, 0.3, 1);
    }
    @keyframes actionMenuIn {
      from { opacity: 0; transform: translateY(-4px); }
      to   { opacity: 1; transform: translateY(0); }
    }
    .action-menu-item {
      background: transparent;
      border: none;
      color: var(--text);
      padding: 8px 12px;
      font-family: var(--font);
      font-size: var(--fs-sm);
      text-align: left;
      cursor: pointer;
      border-radius: 4px;
      transition: background 0.1s;
      white-space: nowrap;
    }
    .action-menu-item:hover { background: var(--bg-card-hover); }
    .action-menu-item:disabled { color: var(--text-40); cursor: not-allowed; }
    .action-menu-item:disabled:hover { background: transparent; }
    .action-menu-item.is-danger { color: var(--error); }
    .action-menu-item.is-danger:hover { background: rgba(var(--error-rgb), 0.08); }
    [data-theme="light"] .action-menu-popover { box-shadow: 0 12px 32px rgba(0,0,0,0.18); }

    .admin-table .action-btn {
      background: none;
      border: 1px solid transparent;
      color: var(--text-40);
      cursor: pointer;
      padding: 4px 12px;
      font-size: 10px;
      font-family: var(--font);
      letter-spacing: 1.5px;
      text-transform: uppercase;
      transition: all 0.2s ease;
      border-radius: 100px;
      font-weight: 500;
      white-space: nowrap;
      display: inline-block;
      margin-right: 2px;
    }

    .admin-table .action-btn:hover { color: var(--text); background: rgba(255,255,255,0.06); border-color: var(--border-hover); }
    .admin-table .action-btn:active { transform: scale(0.97); }
    .admin-table .action-btn.delete { color: rgba(255,80,80,0.5); }
    .admin-table .action-btn.delete:hover { color: var(--error); border-color: rgba(255,80,80,0.3); background: rgba(255,80,80,0.06); }

    .project-cell-name { font-weight: 400; }
    .progress-bar-sm { width: 60px; height: 4px; background: var(--border); display: inline-block; vertical-align: middle; margin-right: 8px; border-radius: 4px; overflow: hidden; }
    .progress-fill-sm { height: 100%; background: linear-gradient(90deg, var(--accent), #34d399); transition: width 0.6s cubic-bezier(0.16, 1, 0.3, 1); border-radius: 4px; position: relative; }
    .progress-fill-sm::after { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent); animation: shimmerBar 2s infinite; }
    @keyframes shimmerBar { from { transform: translateX(-100%); } to { transform: translateX(100%); } }
    .progress-label { font-size: 12px; color: var(--text-40); }
    .date-cell { white-space: nowrap; font-size: 13px; color: var(--text-40); }
    .status-completed { color: #4ade80; border-color: rgba(74,222,128,0.2); background: rgba(74,222,128,0.06); }
    .status-paused { color: #facc15; border-color: rgba(250,204,21,0.2); background: rgba(250,204,21,0.06); }
    .status-archived { color: var(--text-40); }

    .modal-actions { display: flex; gap: 12px; justify-content: flex-end; margin-top: 24px; }

    /* ─── MONDAY-STYLE OVERVIEW ─── */
    .mon-summary {
      display: flex;
      gap: 24px;
      margin-bottom: 24px;
      padding: 14px 20px;
      background: var(--bg-card);
      border: 1px solid var(--border);
      border-radius: var(--radius);
    }
    .mon-summary-item {
      display: flex;
      align-items: center;
      gap: 6px;
    }
    .mon-summary-count {
      font-size: 1.05rem;
      font-weight: 700;
      color: var(--text);
    }
    .mon-summary-label {
      font-size: 0.78rem;
      color: var(--text-60);
    }
    .mon-summary-dot {
      width: 8px; height: 8px;
      border-radius: 50%;
      flex-shrink: 0;
    }
    .mon-dot-todo { background: #c4c4c4; }
    .mon-dot-working { background: var(--info); }
    .mon-dot-done    { background: var(--success); }

    .mon-group {
      margin-bottom: 20px;
      border-radius: var(--radius);
      overflow: hidden;
      border: 1px solid var(--border);
      background: var(--bg-elevated);
    }
    .mon-group-header {
      display: flex;
      align-items: center;
      gap: 10px;
      padding: 12px 16px;
      background: rgba(255,255,255,0.02);
      border-bottom: 1px solid var(--border);
    }
    .mon-group-color {
      width: 4px;
      height: 20px;
      border-radius: 2px;
      background: #5a9a6e;
      flex-shrink: 0;
    }
    .mon-group-name {
      font-weight: 600;
      font-size: 0.9rem;
      color: var(--text);
    }
    .mon-group-count {
      font-size: 0.7rem;
      color: var(--text-40);
      background: rgba(255,255,255,0.05);
      padding: 2px 8px;
      border-radius: 10px;
    }
    .mon-group-progress {
      flex: 1;
      max-width: 100px;
      height: 3px;
      background: rgba(255,255,255,0.06);
      border-radius: 2px;
      overflow: hidden;
      margin-left: auto;
    }
    .mon-group-progress-bar {
      height: 100%;
      background: #5a9a6e;
      border-radius: 2px;
      transition: width 0.3s;
    }
    .mon-group-pct {
      font-size: 0.7rem;
      color: var(--text-40);
      min-width: 28px;
      text-align: right;
    }

    .mon-table { width: 100%; }
    .mon-row {
      display: grid;
      grid-template-columns: 1fr 80px 130px 100px 90px;
      align-items: center;
      border-bottom: none;
      box-shadow: 0 1px 0 var(--border);
      transition: background 0.1s;
    }
    .mon-row.mon-row-projects {
      grid-template-columns: 200px 70px 110px 90px 120px 1fr;
    }
    /* Work Management extended grid — leading checkbox + 7 data columns.
       Most columns are fixed-width so the rhythm stays predictable;
       Project and Progress share any extra space via flex. */
    .mon-row.mon-row-wm {
      grid-template-columns: 32px minmax(180px,1fr) 80px 110px 100px 140px 130px minmax(120px,1fr);
    }
    .mon-row:last-child { box-shadow: none; }
    .mon-row:not(.mon-row-header):hover { background: rgba(255,255,255,0.02); }
    .mon-row-header {
      background: rgba(255,255,255,0.02);
    }
    .mon-row-header .mon-cell {
      font-size: 0.65rem;
      font-weight: 600;
      text-transform: uppercase;
      letter-spacing: 0.06em;
      color: var(--text-40);
      padding: 10px 14px;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
      min-width: 0;
    }
    .mon-cell {
      padding: 12px 14px;
      font-size: 0.84rem;
      color: var(--text);
      display: flex;
      align-items: center;
    }
    .mon-cell-task, .mon-cell-project {
      font-weight: 500;
    }
    .mon-cell-person, .mon-cell-editor {
      justify-content: center;
    }

    .mon-project-name {
      cursor: pointer;
      transition: color 0.15s;
    }
    .mon-project-name:hover {
      color: #5a9a6e;
    }
    .mon-client-label {
      display: inline-block;
      padding: 4px 12px;
      border-radius: 100px;
      font-size: 10px;
      font-weight: 600;
      letter-spacing: 1.5px;
      color: #fff;
      white-space: nowrap;
      max-width: 110px;
      overflow: hidden;
      text-overflow: ellipsis;
    }
    .mon-cell-progress-wrap {
      display: flex;
      align-items: center;
      gap: 8px;
    }

    /* Status pills */
    .mon-status {
      display: inline-block;
      padding: 4px 12px;
      border-radius: 100px;
      font-size: 10px;
      font-weight: 600;
      text-align: center;
      letter-spacing: 1.5px;
      text-transform: uppercase;
      border: 1px solid;
    }
    .mon-status-todo { color: #a0a0a0; border-color: #a0a0a050; background: #a0a0a010; }
    /* Status pills — driven by tokens.
       Active = info-blue (currently in progress, healthy)
       Completed = success-green (delivered, paid)
       On Hold = neutral grey (paused, recoverable)
       Archived = darker neutral (closed, out of mind) */
    .mon-status-working  { color: var(--info);    border-color: rgba(var(--info-rgb), 0.32);    background: rgba(var(--info-rgb), 0.08); }
    .mon-status-done     { color: var(--success); border-color: rgba(var(--success-rgb), 0.32); background: rgba(var(--success-rgb), 0.08); }
    .mon-status-hold     { color: var(--text-60); border-color: var(--border-hover);            background: var(--bg-card); }
    .mon-status-archived { color: var(--text-40); border-color: var(--border);                  background: var(--bg-card); }

    /* Priority pills */
    .mon-priority {
      display: inline-block;
      padding: 4px 12px;
      border-radius: 100px;
      font-size: 10px;
      font-weight: 600;
      letter-spacing: 1.5px;
      text-transform: uppercase;
      text-align: center;
      border: 1px solid;
    }
    .mon-pri-urgent { color: #e2445c; border-color: #e2445c50; background: #e2445c10; }
    .mon-pri-high { color: #fdab3d; border-color: #fdab3d50; background: #fdab3d10; }
    .mon-pri-medium { color: #579bfc; border-color: #579bfc50; background: #579bfc10; }
    .mon-pri-low { color: #a0a0a0; border-color: #a0a0a050; background: #a0a0a010; }

    /* Person bubble */
    .mon-person {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      width: 32px; height: 32px;
      border-radius: 50%;
      background: linear-gradient(135deg, #579bfc, #a25ddc);
      color: #fff;
      font-size: 0.62rem;
      font-weight: 700;
      letter-spacing: 0.02em;
      position: relative;
    }
    .mon-person-empty {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      width: 32px; height: 32px;
      border-radius: 50%;
      border: 2px dashed rgba(255,255,255,0.12);
      cursor: pointer;
      transition: border-color 0.15s;
      color: transparent;
    }
    .mon-person-empty:hover {
      border-color: rgba(255,255,255,0.3);
    }
    .mon-person-empty::after {
      content: '+';
      color: rgba(255,255,255,0.2);
      font-size: 14px;
      font-weight: 400;
    }
    .mon-person-empty:hover::after { color: rgba(255,255,255,0.5); }

    /* Date badges */
    .mon-date {
      font-size: 0.78rem;
      color: var(--text-60);
    }
    .mon-date-overdue {
      color: #e2445c;
      font-weight: 600;
    }
    .mon-date-soon {
      color: #fdab3d;
      font-weight: 600;
    }
    .mon-date-empty {
      color: var(--text-60);
      font-size: 0.8rem;
    }

    /* ── Work Management: Animations & Flair ── */

    /* Row entrance: staggered fade-in slide-up */
    .wm-group .mon-table .mon-row {
      animation: wmRowIn 0.3s ease both;
    }
    .wm-group .mon-table .mon-row:nth-child(1) { animation-delay: 0s; }
    .wm-group .mon-table .mon-row:nth-child(2) { animation-delay: 0.04s; }
    .wm-group .mon-table .mon-row:nth-child(3) { animation-delay: 0.08s; }
    .wm-group .mon-table .mon-row:nth-child(4) { animation-delay: 0.12s; }
    .wm-group .mon-table .mon-row:nth-child(5) { animation-delay: 0.16s; }
    .wm-group .mon-table .mon-row:nth-child(6) { animation-delay: 0.20s; }
    .wm-group .mon-table .mon-row:nth-child(7) { animation-delay: 0.24s; }
    .wm-group .mon-table .mon-row:nth-child(8) { animation-delay: 0.28s; }
    .wm-group .mon-table .mon-row:nth-child(n+9) { animation-delay: 0.32s; }
    @keyframes wmRowIn {
      from { opacity: 0; }
      to   { opacity: 1; }
    }

    /* Hover accent stripe — colored left border like Monday.com */
    .mon-row.mon-row-wm:not(.mon-row-header) {
      border-left: 3px solid transparent;
      transition: background 0.15s, border-color 0.15s;
    }
    .mon-row.mon-row-wm:not(.mon-row-header):hover {
      border-left-color: var(--group-color, var(--accent, #579bfc));
      background: rgba(87, 155, 252, 0.04);
    }

    /* Pill click flash — brief glow on cycle */
    @keyframes wmPillFlash {
      0%   { box-shadow: 0 0 0 0 currentColor; }
      50%  { box-shadow: 0 0 8px 2px currentColor; }
      100% { box-shadow: 0 0 0 0 transparent; }
    }
    .wm-status-click:active, .wm-priority-click:active {
      animation: wmPillFlash 0.35s ease;
    }

    /* Expand detail slide-down */
    .project-expand-detail {
      animation: wmExpandIn 0.25s ease;
      overflow: hidden;
    }
    @keyframes wmExpandIn {
      from { opacity: 0; max-height: 0; padding-top: 0; padding-bottom: 0; }
      to   { opacity: 1; max-height: 500px; }
    }

    /* Group header collapse/expand chevron rotation */
    .wm-group-chevron {
      display: inline-block;
      transition: transform 0.2s ease;
    }

    /* Timeline bar shimmer */
    .wm-timeline-bar {
      position: relative;
      overflow: hidden;
    }
    .wm-timeline-bar::after {
      content: '';
      position: absolute;
      inset: 0;
      background: linear-gradient(90deg, transparent, rgba(255,255,255,0.25), transparent);
      animation: wmTimelineShimmer 3s infinite;
    }
    @keyframes wmTimelineShimmer {
      from { transform: translateX(-100%); }
      to   { transform: translateX(200%); }
    }

    /* Summary counter pulse — scoped to WM summary bar only */
    .mon-summary .mon-summary-count {
      animation: wmCountPop 0.4s ease both;
    }
    @keyframes wmCountPop {
      0%   { opacity: 0; transform: scale(0.8); }
      60%  { transform: scale(1.05); }
      100% { opacity: 1; transform: scale(1); }
    }

    /* Filter bar slide-in */
    .wm-filter-bar {
      animation: wmSlideIn 0.3s ease;
    }
    @keyframes wmSlideIn {
      from { opacity: 0; transform: translateY(-6px); }
      to   { opacity: 1; transform: translateY(0); }
    }

    /* ── Work Management: Filter Bar ── */
    .wm-filter-bar {
      display: flex;
      align-items: center;
      gap: 16px;
      margin-bottom: 16px;
      padding: 10px 16px;
      background: var(--bg-card);
      border: 1px solid var(--border);
      border-radius: var(--radius);
    }
    .wm-filter-group {
      display: flex;
      align-items: center;
      gap: 6px;
    }
    .wm-filter-label {
      font-size: 0.68rem;
      font-weight: 600;
      text-transform: uppercase;
      letter-spacing: 0.06em;
      color: var(--text-40);
    }
    .wm-filter-select {
      background: var(--bg-input);
      color: var(--text);
      border: 1px solid var(--border);
      border-radius: var(--radius-sm);
      padding: 5px 10px;
      font-size: 0.78rem;
      cursor: pointer;
      outline: none;
      transition: border-color 0.15s;
    }
    .wm-filter-select:focus { border-color: var(--accent); }
    .wm-filter-clear {
      background: none;
      border: 1px solid rgba(226,68,92,0.3);
      color: #e2445c;
      padding: 4px 10px;
      border-radius: var(--radius-sm);
      font-size: 0.72rem;
      cursor: pointer;
      margin-left: auto;
      transition: background 0.15s;
    }
    .wm-filter-clear:hover { background: rgba(226,68,92,0.1); }

    /* ── Work Management: Sortable Column Headers ── */
    .wm-col-headers {
      position: sticky;
      top: 0;
      z-index: 2;
      background: var(--bg);
    }
    .wm-sortable {
      cursor: pointer;
      user-select: none;
      transition: color 0.15s;
    }
    .wm-sortable:hover { color: var(--text); }
    .wm-sort-icon {
      font-size: 0.6rem;
      margin-left: 4px;
      color: var(--text-20);
    }
    .wm-sort-icon.wm-sort-active { color: var(--accent); }

    /* ── Work Management: Collapsible Group Headers ── */
    .wm-group { margin-bottom: 8px; }
    .wm-group-header {
      cursor: pointer;
      user-select: none;
      transition: background 0.15s;
    }
    .wm-group-header:hover { background: rgba(255,255,255,0.04); }
    .wm-group-chevron {
      font-size: 0.7rem;
      color: var(--text-40);
      margin-right: 4px;
      transition: transform 0.15s;
    }

    /* ── Work Management: Clickable Status/Priority pills ── */
    .wm-status-click, .wm-priority-click {
      cursor: pointer;
      transition: transform 0.1s, box-shadow 0.15s;
    }
    .wm-status-click:hover, .wm-priority-click:hover {
      transform: scale(1.08);
      box-shadow: 0 0 0 2px rgba(255,255,255,0.08);
    }

    /* ── Work Management: Due Date clickable ── */
    .wm-duedate-click {
      cursor: pointer;
      transition: color 0.15s;
    }
    .wm-duedate-click:hover { color: var(--accent); }
    .mon-cell-due {
      flex-direction: column;
      align-items: flex-start;
      gap: 4px;
    }

    /* ── Work Management: Timeline Bar ── */
    .wm-timeline {
      width: 100%;
      height: 4px;
      background: rgba(255,255,255,0.06);
      border-radius: 2px;
      overflow: hidden;
    }
    .wm-timeline-bar {
      height: 100%;
      border-radius: 2px;
      transition: width 0.3s ease;
    }

    /* ── Work Management: Priority column ── */
    .mon-cell-priority {
      justify-content: center;
    }

    @media (max-width: 768px) {
      .mon-row { grid-template-columns: 1fr 60px 100px 80px 70px; }
      .mon-row.mon-row-wm { grid-template-columns: 28px minmax(120px,1fr) 56px 80px 80px 100px 90px minmax(80px,0.8fr); }
      .mon-status, .mon-priority { min-width: auto; padding: 3px 8px; font-size: 0.65rem; }
      .mon-summary { flex-wrap: wrap; gap: 12px; }
      .wm-filter-bar { flex-wrap: wrap; gap: 8px; }
    }

    /* ═══ MISSING COMPONENT STYLES — From Monolith ═══ */

    /* Activity Feed Styles */
    .activity-content {
      flex: 1;
      padding-top: 2px;
    }

    .activity-detail {
      font-size: 0.8125rem;
      color: var(--text-60);
      font-weight: 400;
    }

    .activity-dot {
      width: 16px;
      height: 16px;
      border-radius: 50%;
      border: 1px solid var(--border);
      background: var(--bg-card);
      position: relative;
      top: 6px;
      flex-shrink: 0;
    }

    .activity-feed {
      position: relative;
    }

    .activity-item {
      display: flex;
      gap: 1.5rem;
      margin-bottom: 1.5rem;
      position: relative;
      padding-left: 1px;
    }

    .activity-text {
      font-size: 0.875rem;
      font-weight: 400;
      color: var(--text);
      line-height: 1.5;
      margin-bottom: 0.25rem;
    }

    .activity-time {
      font-size: 0.75rem;
      color: var(--text-45);
      margin-bottom: 0.5rem;
    }

    /* Animation Utilities */
    @keyframes fadeSlideUp {
      from { opacity: 0; transform: translateY(12px); }
      to { opacity: 1; transform: translateY(0); }
    }
    @keyframes fadeIn {
      from { opacity: 0; }
      to { opacity: 1; }
    }

    .anim-fade-in {
      animation: fadeIn 0.3s ease-out forwards;
    }

    .anim-stagger > * {
      opacity: 0;
      animation: fadeSlideUp 0.4s ease-out forwards;
    }
    .anim-stagger > *:nth-child(1) { animation-delay: 0.03s; }
    .anim-stagger > *:nth-child(2) { animation-delay: 0.06s; }
    .anim-stagger > *:nth-child(3) { animation-delay: 0.09s; }
    .anim-stagger > *:nth-child(4) { animation-delay: 0.12s; }
    .anim-stagger > *:nth-child(5) { animation-delay: 0.15s; }
    .anim-stagger > *:nth-child(6) { animation-delay: 0.18s; }
    .anim-stagger > *:nth-child(7) { animation-delay: 0.21s; }
    .anim-stagger > *:nth-child(8) { animation-delay: 0.24s; }
    .anim-stagger > *:nth-child(9) { animation-delay: 0.27s; }
    .anim-stagger > *:nth-child(10) { animation-delay: 0.30s; }
    .anim-stagger > *:nth-child(n+11) { animation-delay: 0.33s; }

    /* Brand Assets */
    .asset-actions {
      display: flex;
      gap: 0.5rem;
    }

    .asset-card {
      border: 1px solid var(--border);
      background: var(--bg-card);
      padding: 1rem;
      transition: all 0.2s;
    }

    .asset-download-btn {
      flex: 1;
      padding: 0.5rem;
      border: 1px solid var(--border);
      background: transparent;
      color: var(--text-60);
      font-size: 0.7rem;
      font-weight: 400;
      text-transform: uppercase;
      cursor: pointer;
      transition: all 0.2s;
      display: flex;
      align-items: center;
      justify-content: center;
      gap: 0.5rem;
    }

    .asset-hex {
      font-size: 0.75rem;
      color: var(--text-60);
      font-family: 'Courier New', monospace;
      word-break: break-all;
    }

    .asset-name {
      font-size: 0.875rem;
      font-weight: 400;
      color: var(--text);
      margin-bottom: 0.5rem;
    }

    .asset-preview {
      width: 100%;
      height: 160px;
      margin-bottom: 1rem;
      display: flex;
      align-items: center;
      justify-content: center;
      background: var(--bg-elevated);
      border: 1px solid var(--border);
      font-size: 0.75rem;
      color: var(--text-45);
    }

    .asset-swatch {
      width: 100%;
      height: 100px;
      margin-bottom: 0.75rem;
      border: 1px solid var(--border);
      cursor: pointer;
      position: relative;
      transition: all 0.2s;
    }

    .asset-type {
      font-size: 0.7rem;
      color: var(--text-45);
      text-transform: uppercase;
      letter-spacing: 0.05em;
      margin-bottom: 0.75rem;
    }

    .brand-assets-grid {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
      gap: 1.5rem;
      margin-bottom: 2rem;
    }

    .brand-vault-filters {
      display: flex;
      gap: 0.75rem;
      margin-bottom: 2rem;
      flex-wrap: wrap;
    }

    /* Briefings */
    .briefing-card {
      padding: 1rem;
      border: 1px solid var(--border);
      background: var(--bg-card);
      display: flex;
      justify-content: space-between;
      align-items: center;
    }

    .briefing-date {
      font-size: 0.75rem;
      color: var(--text-45);
    }

    .briefing-form-wrapper {
      border: 1px solid var(--border);
      background: var(--bg-card);
      padding: 2rem;
    }

    .briefing-info {
      flex: 1;
    }

    .briefing-list {
      display: flex;
      flex-direction: column;
      gap: 1rem;
    }

    .briefing-name {
      font-size: 0.875rem;
      font-weight: 400;
      color: var(--text);
      margin-bottom: 0.25rem;
    }

    .briefing-status {
      display: flex;
      align-items: center;
      gap: 0.75rem;
    }

    /* Comments */
    .comment {
      display: flex;
      gap: 1rem;
    }

    .comment-author {
      font-size: 0.875rem;
      font-weight: 400;
      color: var(--text);
    }

    .comment-avatar {
      width: 40px;
      height: 40px;
      border-radius: 50%;
      background: var(--bg-card);
      border: 1px solid var(--border);
      display: flex;
      align-items: center;
      justify-content: center;
      font-size: 0.75rem;
      font-weight: 500;
      text-transform: uppercase;
      color: var(--text-60);
      flex-shrink: 0;
      background: linear-gradient(135deg, var(--bg-card-hover), var(--bg-card));
    }

    .comment-body {
      font-size: 0.875rem;
      font-weight: 400;
      line-height: 1.5;
      color: var(--text);
    }

    .comment-content {
      flex: 1;
    }

    .comment-header {
      display: flex;
      align-items: baseline;
      gap: 0.75rem;
      margin-bottom: 0.5rem;
    }

    .comment-submit {
      align-self: flex-end;
      padding: 0.75rem 1.5rem;
      background: var(--text);
      color: var(--bg);
      border: none;
      font-size: 0.75rem;
      font-weight: 500;
      letter-spacing: 0.05em;
      text-transform: uppercase;
      cursor: pointer;
      transition: all 0.2s;
      border-radius: var(--radius-sm);
    }

    .comment-textarea {
      width: 100%;
      min-height: 100px;
      padding: 1rem;
      border: 1px solid var(--border);
      background: var(--bg-input);
      color: var(--text);
      font-family: var(--font);
      font-size: 0.875rem;
      font-weight: 400;
      line-height: 1.5;
      resize: vertical;
      border-radius: var(--radius);
    }

    .comment-timestamp {
      font-size: 0.75rem;
      color: var(--text-45);
    }

    .comments-header {
      font-size: 0.875rem;
      font-weight: 400;
      letter-spacing: 0.05em;
      text-transform: uppercase;
      color: var(--text-60);
      margin-bottom: 1.5rem;
    }

    .comments-input-group {
      display: flex;
      flex-direction: column;
      gap: 1rem;
      margin-top: 2rem;
      padding-top: 1.5rem;
      border-top: 1px solid var(--border);
    }

    .comments-list {
      display: flex;
      flex-direction: column;
      gap: 1.5rem;
      margin-bottom: 2rem;
    }

    .comments-section {
      margin: 2rem 0;
    }

    /* Contracts */
    .contract-actions {
      display: flex;
      gap: 0.75rem;
      align-items: center;
    }

    .contract-card {
      padding: 1.25rem;
      border: 1px solid var(--border);
      background: var(--bg-card);
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 1.5rem;
      transition: all 0.2s;
    }

    .contract-details {
      display: flex;
      gap: 1.5rem;
      font-size: 0.75rem;
      color: var(--text-45);
    }

    .contract-download-btn {
      padding: 0.5rem 1rem;
      border: 1px solid var(--border);
      background: transparent;
      color: var(--text-60);
      font-size: 0.7rem;
      font-weight: 400;
      letter-spacing: 0.05em;
      text-transform: uppercase;
      cursor: pointer;
      transition: all 0.2s;
      display: flex;
      align-items: center;
      gap: 0.5rem;
    }

    .contract-expiry {
      font-size: 0.8125rem;
      text-align: right;
    }

    .contract-expiry-date {
      color: var(--text);
    }

    .contract-expiry-label {
      font-size: 0.7rem;
      color: var(--text-45);
      text-transform: uppercase;
      letter-spacing: 0.05em;
      display: block;
      margin-bottom: 0.25rem;
    }

    .contract-icon {
      width: 40px;
      height: 40px;
      border: 1px solid var(--border);
      background: var(--bg-elevated);
      display: flex;
      align-items: center;
      justify-content: center;
      font-size: 1rem;
      color: var(--text-60);
      flex-shrink: 0;
    }

    .contract-info {
      flex: 1;
    }

    .contract-name {
      font-size: 0.875rem;
      font-weight: 400;
      color: var(--text);
      margin-bottom: 0.5rem;
    }

    .contract-type {
      display: inline-block;
      padding: 0.375rem 0.75rem;
      border: 1px solid var(--border);
      background: var(--bg-elevated);
      font-size: 0.7rem;
      font-weight: 400;
      letter-spacing: 0.05em;
      text-transform: uppercase;
      color: var(--text-60);
    }

    .contracts-list {
      display: flex;
      flex-direction: column;
      gap: 1rem;
    }

    /* Drag & Drop */
    .drop-target {
      height: 4px;
      background: var(--text);
      margin: 0.5rem 0;
      opacity: 0;
      transition: opacity 0.2s;
    }

    /* Empty States */
    /* ─── Empty state — used when a list has zero items.
       Structure:  .empty-state > .empty-state-icon? > .empty-state-title >
                   .empty-state-body? > .empty-state-cta? */
    .empty-state {
      text-align: center;
      padding: 64px 32px;
      color: var(--text-60);
      max-width: 420px;
      margin: 0 auto;
      display: flex;
      flex-direction: column;
      align-items: center;
      gap: 12px;
    }
    .empty-state.empty-state-compact { padding: 32px 24px; gap: 8px; }
    .empty-state.empty-state-inline   { padding: 24px; gap: 6px; }
    .empty-state-icon {
      width: 44px;
      height: 44px;
      display: flex;
      align-items: center;
      justify-content: center;
      border-radius: 50%;
      background: var(--bg-card);
      border: 1px solid var(--border);
      color: var(--text-45);
      margin-bottom: 4px;
    }
    .empty-state-icon svg { width: 20px; height: 20px; stroke: currentColor; fill: none; stroke-width: 1.75; }
    .empty-state-title {
      font-size: var(--fs-md);
      font-weight: var(--fw-medium);
      color: var(--text);
      margin: 0;
    }
    .empty-state-body {
      font-size: var(--fs-sm);
      color: var(--text-45);
      line-height: 1.5;
      margin: 0;
    }
    .empty-state-cta { margin-top: 8px; }

    /* File Preview */
    .file-preview {
      position: relative;
      border: 1px solid var(--border);
      background: var(--bg-card);
      padding: 0.75rem;
      text-align: center;
    }

    .file-preview-grid {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
      gap: 1rem;
      margin-top: 1.5rem;
    }

    .file-preview-image {
      width: 100%;
      height: 80px;
      object-fit: cover;
      margin-bottom: 0.5rem;
      background: var(--bg-elevated);
      display: flex;
      align-items: center;
      justify-content: center;
    }

    .file-preview-name {
      font-size: 0.7rem;
      color: var(--text-60);
      word-break: break-word;
      white-space: normal;
    }

    .file-remove-btn {
      position: absolute;
      top: 0.25rem;
      right: 0.25rem;
      width: 20px;
      height: 20px;
      padding: 0;
      border: 1px solid var(--border);
      background: var(--bg);
      color: var(--error);
      font-size: 0.7rem;
      cursor: pointer;
      display: flex;
      align-items: center;
      justify-content: center;
      opacity: 0;
      transition: opacity 0.2s;
    }

    /* Filters */
    .filter-button {
      padding: 0.5rem 1rem;
      border: 1px solid var(--border);
      background: transparent;
      color: var(--text-60);
      font-size: 0.75rem;
      font-weight: 400;
      letter-spacing: 0.05em;
      text-transform: uppercase;
      cursor: pointer;
      transition: all 0.2s;
    }

    /* Forms */
    .form-cancel-btn {
      padding: 0.75rem 1.5rem;
      border: 1px solid var(--text);
      background: transparent;
      color: var(--text);
      font-size: 0.75rem;
      font-weight: 400;
      letter-spacing: 0.05em;
      text-transform: uppercase;
      cursor: pointer;
      transition: all 0.2s;
    }

    .form-input,
    .form-textarea,
    .form-select {
      width: 100%;
      padding: 0.75rem;
      border: 1px solid rgba(255,255,255,0.08);
      background: rgba(255,255,255,0.04);
      backdrop-filter: blur(12px);
      -webkit-backdrop-filter: blur(12px);
      color: var(--text);
      font-family: var(--font);
      font-size: 0.875rem;
      font-weight: 400;
      border-radius: var(--radius-sm);
      transition: all 0.25s ease;
    }

    .form-row {
      display: grid;
      grid-template-columns: repeat(2, 1fr);
      gap: 1.5rem;
    }

    .form-select {
      width: 100%;
      padding: 0.75rem;
      border: 1px solid rgba(255,255,255,0.08);
      background: rgba(255,255,255,0.04);
      backdrop-filter: blur(12px);
      -webkit-backdrop-filter: blur(12px);
      color: var(--text);
      font-family: var(--font);
      font-size: 0.875rem;
      font-weight: 400;
      border-radius: var(--radius-sm);
      transition: all 0.25s ease;
    }

    .form-status-badge {
      display: inline-block;
      padding: 4px 12px;
      border: 1px solid;
      border-radius: 100px;
      font-size: 10px;
      font-weight: 600;
      letter-spacing: 1.5px;
      text-transform: uppercase;
      margin-bottom: 1rem;
    }

    .form-submit-btn,
    .form-cancel-btn {
      padding: 0.75rem 1.5rem;
      border: 1px solid var(--text);
      background: transparent;
      color: var(--text);
      font-size: 0.75rem;
      font-weight: 400;
      letter-spacing: 0.05em;
      text-transform: uppercase;
      cursor: pointer;
      transition: all 0.2s;
    }

    .form-textarea,
    .form-select {
      width: 100%;
      padding: 0.75rem;
      border: 1px solid rgba(255,255,255,0.08);
      background: rgba(255,255,255,0.04);
      backdrop-filter: blur(12px);
      -webkit-backdrop-filter: blur(12px);
      color: var(--text);
      font-family: var(--font);
      font-size: 0.875rem;
      font-weight: 400;
      border-radius: var(--radius-sm);
      transition: all 0.25s ease;
    }

    /* Invoices */
    .invoice-amount {
      font-size: 1.125rem;
      font-weight: 400;
      color: var(--text);
    }

    .invoice-card {
      padding: 1.25rem;
      border: 1px solid var(--border);
      background: var(--bg-card);
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 1.5rem;
      transition: all 0.2s;
    }

    .invoice-col {
      flex: 1;
    }

    .invoice-date {
      font-size: 0.8125rem;
      color: var(--text-60);
    }

    .invoice-label {
      font-size: 0.7rem;
      color: var(--text-45);
      text-transform: uppercase;
      letter-spacing: 0.05em;
      margin-bottom: 0.25rem;
    }

    .invoice-number {
      font-size: 0.875rem;
      font-weight: 400;
      color: var(--text);
    }

    .invoice-pay-btn {
      padding: 0.5rem 1rem;
      border: 1px solid var(--text);
      background: transparent;
      color: var(--text);
      font-size: 0.7rem;
      font-weight: 400;
      letter-spacing: 0.05em;
      text-transform: uppercase;
      cursor: pointer;
      transition: all 0.2s;
    }

    .invoice-status {
      display: inline-block;
      padding: 0.375rem 0.75rem;
      border: 1px solid var(--border);
      font-size: 0.7rem;
      font-weight: 400;
      letter-spacing: 0.05em;
      text-transform: uppercase;
    }

    .invoice-table {
      width: 100%;
      border-collapse: collapse;
    }

    .invoices-layout {
      display: flex;
      flex-direction: column;
      gap: 1.5rem;
    }

    /* Loading States */
    .loading {
      display: flex;
      align-items: center;
      justify-content: center;
      min-height: 200px;
      color: var(--text-40);
      font-size: 14px;
      font-weight: 400;
    }

    /* Milestones */
    .milestone-action-btn {
      width: 32px;
      height: 32px;
      border: 1px solid var(--border);
      border-radius: 100px;
      background: transparent;
      color: var(--text-60);
      cursor: pointer;
      display: flex;
      align-items: center;
      justify-content: center;
      transition: all 0.2s;
    }

    .milestone-actions {
      display: flex;
      gap: 0.5rem;
      flex-shrink: 0;
    }

    .milestone-grip {
      display: flex;
      align-items: center;
      gap: 0.25rem;
      color: var(--text-20);
      cursor: grab;
      flex-shrink: 0;
    }

    .milestone-grip-dot {
      width: 3px;
      height: 3px;
      background: currentColor;
      border-radius: 50%;
    }

    .milestone-item {
      display: flex;
      align-items: center;
      gap: 1rem;
      padding: 1rem;
      border: 1px solid var(--border);
      background: var(--bg-card);
      transition: all 0.2s;
      cursor: grab;
    }

    .milestone-marker {
      width: 16px;
      height: 16px;
      border: 1px solid var(--border);
      background: var(--bg-elevated);
      border-radius: 2px;
      flex-shrink: 0;
    }

    .milestone-status {
      font-size: 0.7rem;
      color: var(--text-60);
      text-transform: uppercase;
      letter-spacing: 0.05em;
    }

    .milestone-title {
      font-size: 0.875rem;
      font-weight: 400;
      color: var(--text);
      margin-bottom: 0.25rem;
    }

    .milestones-container {
      display: flex;
      flex-direction: column;
      gap: 1rem;
    }

    /* Notes */
    .note-card {
      background: var(--bg-card);
      border: 1px solid var(--border);
      border-radius: var(--radius-sm);
      padding: 16px;
      transition: border-color 0.15s;
    }

    .note-content {
      font-size: 0.9rem;
      color: var(--text);
      line-height: 1.5;
      white-space: pre-wrap;
      margin-bottom: 10px;
    }

    .note-footer {
      display: flex;
      justify-content: space-between;
      align-items: center;
    }

    .note-meta {
      font-size: 0.75rem;
      color: var(--text-60);
    }

    .notes-list {
      display: flex;
      flex-direction: column;
      gap: 12px;
    }

    /* Section Navigation */
    .section-nav {
      display: flex;
      gap: 0;
      border-bottom: 1px solid var(--border);
      margin-bottom: 2rem;
      overflow-x: auto;
      -webkit-overflow-scrolling: touch;
    }

    .section-nav-item {
      padding: 1rem 1.5rem;
      font-size: 0.875rem;
      font-weight: 400;
      letter-spacing: 0.05em;
      text-transform: uppercase;
      color: var(--text-60);
      border: none;
      background: transparent;
      cursor: pointer;
      position: relative;
      white-space: nowrap;
      transition: color 0.2s;
    }

    /* Skeleton Loading */
    .skeleton {
      background: linear-gradient(90deg, var(--bg-card) 25%, var(--bg-card-hover) 50%, var(--bg-card) 75%);
      background-size: 200% 100%;
      animation: shimmer 1.5s ease-in-out infinite;
      border-radius: var(--radius-sm);
    }

    .skeleton-card {
      aspect-ratio: 1/1;
      border-radius: var(--radius);
    }

    .skeleton-row {
      height: 48px;
      margin-bottom: 4px;
    }

    .skeleton-text {
      height: 14px;
      width: 60%;
      margin-bottom: 8px;
    }

    .skeleton-text-short {
      height: 14px;
      width: 35%;
      margin-bottom: 8px;
    }

    /* Stats — actionable tiles. Optional `--info` / `--warn` tones
       for tiles that should pull the eye when there's something to do. */
    .stat-card {
      padding: 20px 22px;
      border: 1px solid var(--border);
      background: var(--bg-card);
      display: flex;
      flex-direction: column;
      gap: 6px;
      min-height: 120px;
      border-radius: var(--radius);
      transition: all 0.2s ease;
    }
    .stat-card[data-action]:hover { border-color: var(--border-hover); background: var(--bg-card-hover); transform: translateY(-1px); }
    .stat-card--info { border-color: rgba(var(--info-rgb), 0.3); }
    .stat-card--warn { border-color: rgba(var(--priority-urgent-rgb), 0.3); }
    .stat-card--warn .stat-value { color: var(--priority-urgent); }

    .stat-change {
      font-size: var(--fs-xs);
      margin-top: 4px;
      font-weight: 400;
    }

    .stat-label {
      font-size: var(--fs-xs);
      font-weight: var(--fw-medium);
      letter-spacing: 0.08em;
      text-transform: uppercase;
      color: var(--text-60);
    }

    .stat-sub {
      font-size: var(--fs-xs);
      color: var(--text-45);
      margin-top: 2px;
    }

    .stat-value {
      font-size: 32px;
      font-weight: var(--fw-medium);
      color: var(--text);
      line-height: 1.1;
      margin-bottom: 2px;
      letter-spacing: -0.02em;
    }

    .stats-grid {
      display: grid;
      grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
      gap: 1.5rem;
      margin-bottom: 2.5rem;
    }

    /* Service Checkbox */
    .svc-checkbox {
      display: flex;
      align-items: center;
      gap: 10px;
      cursor: pointer;
      padding: 10px 14px;
      border-radius: var(--radius-sm);
      border: 1px solid var(--border);
      background: var(--bg-input, var(--bg));
      transition: all 0.2s ease;
      font-size: 0.9rem;
      color: var(--text);
      user-select: none;
    }

    /* Task Management */
    .task-actions {
      display: flex;
      gap: 4px;
      flex-wrap: wrap;
    }

    .task-assignee, .task-due {
      font-size: 0.75rem;
      color: var(--text-60);
    }

    .task-board {
      display: grid;
      grid-template-columns: repeat(3, 1fr);
      gap: 16px;
    }

    .task-card {
      background: var(--bg-elevated);
      border: 1px solid var(--border);
      border-radius: var(--radius-sm);
      padding: 12px;
      transition: border-color 0.15s;
    }

    .task-card-bottom {
      display: flex;
      justify-content: space-between;
      align-items: center;
      flex-wrap: wrap;
      gap: 6px;
    }

    .task-card-top {
      display: flex;
      justify-content: space-between;
      align-items: flex-start;
      gap: 8px;
      margin-bottom: 6px;
    }

    .task-column {
      background: var(--bg-card);
      border: 1px solid var(--border);
      border-radius: var(--radius);
      min-height: 200px;
      display: flex;
      flex-direction: column;
    }

    .task-column-body {
      padding: 12px;
      display: flex;
      flex-direction: column;
      gap: 10px;
      flex: 1;
    }

    .task-column-count {
      background: var(--bg-input);
      color: var(--text-60);
      font-size: 0.75rem;
      font-weight: 600;
      padding: 2px 8px;
      border-radius: 10px;
    }

    .task-column-header {
      display: flex;
      justify-content: space-between;
      align-items: center;
      padding: 12px 16px;
      border-bottom: 1px solid var(--border);
    }

    .task-column-title {
      font-weight: 600;
      font-size: 0.85rem;
      text-transform: uppercase;
      letter-spacing: 0.05em;
      color: var(--text-60);
    }

    .task-desc {
      font-size: 0.8rem;
      color: var(--text-60);
      margin: 0 0 8px 0;
      line-height: 1.4;
    }

    .task-due::before { content: '📅 '; }

    .task-empty {
      color: var(--text-60);
      font-size: 0.85rem;
      text-align: center;
      padding: 20px 0;
      margin: 0;
    }

    .task-meta {
      display: flex;
      gap: 10px;
      align-items: center;
    }

    .task-priority {
      font-size: 10px;
      font-weight: 600;
      text-transform: uppercase;
      letter-spacing: 1.5px;
      padding: 4px 12px;
      border-radius: 100px;
      border: 1px solid;
      white-space: nowrap;
    }
    .task-priority.priority-urgent { color: var(--priority-urgent); border-color: rgba(var(--priority-urgent-rgb), 0.3); background: rgba(var(--priority-urgent-rgb), 0.08); }
    .task-priority.priority-high   { color: var(--priority-high);   border-color: rgba(var(--priority-high-rgb),   0.3); background: rgba(var(--priority-high-rgb),   0.08); }
    .task-priority.priority-medium { color: var(--priority-medium); border-color: rgba(var(--priority-medium-rgb), 0.3); background: rgba(var(--priority-medium-rgb), 0.08); }
    .task-priority.priority-low    { color: var(--priority-low);    border-color: rgba(var(--priority-low-rgb),    0.3); background: rgba(var(--priority-low-rgb),    0.08); }

    .task-title {
      font-weight: 500;
      font-size: 0.9rem;
      color: var(--text);
      line-height: 1.3;
    }

    /* Toast Notifications */
    .toast {
      position: fixed;
      bottom: 24px;
      right: 24px;
      background: var(--bg-elevated);
      color: var(--text);
      padding: 14px 20px;
      border-radius: var(--radius);
      font-size: 0.85rem;
      z-index: 9999;
      border: 1px solid var(--border);
      box-shadow: 0 8px 32px rgba(0,0,0,0.3);
      transform: translateX(calc(100% + 48px));
      transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
      max-width: 360px;
      overflow: hidden;
      visibility: hidden;
    }

    /* File Upload */
    .upload-browse-btn {
      padding: 0.75rem 1.5rem;
      border: 1px solid var(--border);
      background: transparent;
      color: var(--text-60);
      font-size: 0.75rem;
      font-weight: 400;
      letter-spacing: 0.05em;
      text-transform: uppercase;
      cursor: pointer;
      transition: all 0.2s;
    }

    .upload-hint {
      font-size: 0.75rem;
      color: var(--text-45);
      margin-bottom: 1.5rem;
    }

    .upload-icon {
      font-size: 2rem;
      color: var(--text-60);
      margin-bottom: 1rem;
    }

    .upload-input {
      display: none;
    }

    .upload-progress-bar {
      width: 100%;
      height: 2px;
      background: var(--border);
      margin: 1.5rem 0;
      overflow: hidden;
    }

    .upload-progress-fill {
      height: 100%;
      background: var(--text);
      width: 0%;
      transition: width 0.3s;
    }

    .upload-text {
      font-size: 0.875rem;
      font-weight: 400;
      color: var(--text);
      margin-bottom: 0.25rem;
    }

    .upload-zone {
      border: 1px dashed var(--border);
      padding: 3rem 1.5rem;
      text-align: center;
      cursor: pointer;
      transition: all 0.2s;
      background: var(--bg-elevated);
    }

    /* ─── Remaining modifier/state classes ─── */
    .svc-checkbox .check-box {
      width: 20px; height: 20px; min-width: 20px; border-radius: 5px;
      border: 2px solid var(--border); background: var(--bg); transition: all 0.2s;
      display: flex; align-items: center; justify-content: center;
    }
    .svc-checkbox .svc-info { display: flex; flex-direction: column; gap: 1px; }
    .svc-checkbox .svc-name { font-size: 0.9rem; color: var(--text); font-weight: 400; }
    .svc-checkbox .svc-price { font-size: 0.75rem; color: var(--text-40); }
    .milestone-marker.completed { background: var(--success); border-color: var(--success); }
    .milestone-marker.in-progress { background: rgba(100,150,255,0.5); border-color: rgba(100,150,255,0.9); }
    .activity-dot.success { border-color: var(--success); background: var(--success); }
    .activity-dot.warning { border-color: var(--warning); background: var(--warning); }
    .activity-dot.error { border-color: var(--error); background: var(--error); }
    .activity-dot.highlight { border-color: var(--text); background: var(--text); }
    .form-status-badge.submitted { background: rgba(100,150,255,0.1); color: rgba(100,150,255,0.9); border-color: rgba(100,150,255,0.3); }
    .form-status-badge.reviewed { background: rgba(74,222,128,0.1); color: var(--success); border-color: rgba(74,222,128,0.3); }
    .invoice-col.invoice-actions { flex: 0.6; text-align: right; }
    .form-textarea { resize: vertical; min-height: 100px; font-family: var(--font); }
    .toast.show { transform: translateX(0); visibility: visible; }
    .toast::after { content: ''; position: absolute; bottom: 0; left: 0; height: 3px; background: var(--text-40); animation: toastProgress 3s linear forwards; }
    .toast.toast-success { border-color: rgba(var(--success-rgb), 0.4); }
    .toast.toast-success::after { background: var(--success); }
    .toast.toast-error   { border-color: rgba(var(--error-rgb), 0.4); }
    .toast.toast-error::after   { background: var(--error); }
    .toast.toast-info    { border-color: rgba(var(--info-rgb), 0.4); }
    .toast.toast-info::after    { background: var(--info); }
    @keyframes toastProgress { from { width: 100%; } to { width: 0%; } }

