/* TransomOne ShiftReport — Premium Theme v3.0 */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

:root {
  /* Brand */
  --primary:        #1851e0;
  --primary-dark:   #1240c0;
  --primary-light:  #eef2ff;
  --primary-glow:   rgba(24,81,224,.15);
  --teal:           #06b6d4;
  --teal-soft:      rgba(6,182,212,.12);

  /* Sidebar */
  --sidebar-bg:     #0f1c2e;
  --sidebar-hover:  rgba(255,255,255,.06);
  --sidebar-active: rgba(24,81,224,.18);
  --sidebar-w:      240px;

  /* Topbar */
  --topbar-bg:      #ffffff;
  --topbar-h:       60px;
  --topbar-border:  #e8edf5;

  /* Surface */
  --bg:             #f4f6fb;
  --bg-card:        #ffffff;
  --bg-card2:       #f8fafd;
  --border:         #e4e9f2;
  --border-soft:    #edf0f7;

  /* Text */
  --text:           #0d1526;
  --text-muted:     #566174;
  --text-light:     #9ba8bc;

  /* Elevation */
  --shadow-xs:      0 1px 2px rgba(13,21,38,.06);
  --shadow-sm:      0 2px 8px rgba(13,21,38,.08);
  --shadow-md:      0 4px 16px rgba(13,21,38,.1);
  --shadow-lg:      0 8px 32px rgba(13,21,38,.12);

  /* Radius */
  --radius:         12px;
  --radius-sm:      8px;
  --radius-xs:      6px;

  /* Status */
  --success:        #059669;
  --success-soft:   #ecfdf5;
  --warning:        #d97706;
  --warning-soft:   #fffbeb;
  --danger:         #dc2626;
  --danger-soft:    #fef2f2;
  --info:           #0284c7;
  --info-soft:      #f0f9ff;
}

/* ── Dark mode ── */
[data-theme="dark"] {
  --sidebar-bg:     #080f1a;
  --topbar-bg:      #0f1c2e;
  --topbar-border:  #1a2d45;
  --bg:             #0a1220;
  --bg-card:        #0f1c2e;
  --bg-card2:       #0c1628;
  --border:         #1a2d45;
  --border-soft:    #162338;
  --text:           #e2eaf8;
  --text-muted:     #7a90b0;
  --text-light:     #3a5472;
  --shadow-xs:      0 1px 2px rgba(0,0,0,.2);
  --shadow-sm:      0 2px 8px rgba(0,0,0,.25);
  --shadow-md:      0 4px 16px rgba(0,0,0,.3);
  --primary-light:  #1a2d4a;
  --success-soft:   rgba(5,150,105,.12);
  --warning-soft:   rgba(217,119,6,.12);
  --danger-soft:    rgba(220,38,38,.12);
  --info-soft:      rgba(2,132,199,.12);
}

/* ── Reset & Base ── */
*, *::before, *::after { box-sizing: border-box; }
html, body { height: 100%; }
body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  font-size: 14px;
  line-height: 1.6;
  background: var(--bg);
  color: var(--text);
  margin: 0;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--primary); text-decoration: none; }
a:hover { color: var(--primary-dark); }

/* ── Topbar ── */
/* =========================================================
   TOPBAR — Light mode: white bg, dark text
            Dark mode:  #0f1c2e bg, white text
   ========================================================= */
.topbar {
  position: fixed; top: 0; left: var(--sidebar-w); right: 0;
  z-index: 1040; height: var(--topbar-h);
  background: #ffffff !important;
  border-bottom: 1.5px solid #e4eaf4 !important;
  display: flex; align-items: center;
  padding: 0 20px 0 24px; gap: 10px;
  box-shadow: 0 1px 6px rgba(0,0,0,.06);
  transition: left .25s;
}
[data-theme="dark"] .topbar {
  background: #0f1c2e !important;
  border-bottom-color: #1e3050 !important;
  box-shadow: 0 1px 6px rgba(0,0,0,.3);
}
.topbar-spacer { flex: 1; }
.topbar-toggle {
  display: none; background: none; border: none;
  color: var(--text-muted); font-size: 1.2rem;
  cursor: pointer; padding: 8px; border-radius: var(--radius-xs);
  transition: background .15s;
}
.topbar-toggle:hover { background: var(--bg-card2); color: var(--text); }
@media(max-width:991px) {
  .topbar { left: 0; }
  .topbar-toggle { display: flex; align-items: center; }
}

/* topbar-search removed */

/* topbar-brand legacy - replaced by topbar-logo */

/* ── Logo image styles ── */
.sidebar-logo-img {
  height: 60px; width: auto;
  object-fit: contain;
  filter: none;
  transition: opacity .2s;
  /* Transparent logo works directly on dark sidebar */
}
.sidebar-logo-img:hover { opacity: .9; transform: scale(1.02); }

.topbar-logo-img {
  height: 36px; width: auto;
  object-fit: contain;
  /* Full color on white topbar */
  filter: none;
  transition: opacity .2s;
}
.topbar-logo-img:hover { opacity: .85; }
/* Dark mode: slight brightness boost */
[data-theme="dark"] .topbar-logo-img {
  filter: brightness(0) invert(1);
}

/* Sidebar brand container - center the logo */
.sidebar-brand {
  display: flex; align-items: center; justify-content: center;
  padding: 16px 20px 14px;
  border-bottom: 1px solid rgba(255,255,255,.08);
  text-decoration: none;
}

/* Topbar logo link */
.topbar-logo {
  display: flex; align-items: center;
  text-decoration: none; flex-shrink: 0;
  margin-right: 4px;
}



/* Topbar meta info */
.topbar-meta {
  display: flex; align-items: center; gap: 6px;
  padding: 5px 12px; background: #f1f5f9;
  border: 1px solid #e2e8f0; border-radius: 20px;
  font-size: .75rem; color: #566174;
}
.topbar-meta strong { color: #0d1526; font-weight: 600; }
[data-theme="dark"] .topbar-meta { background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.12); color: rgba(255,255,255,.6); }
[data-theme="dark"] .topbar-meta strong { color: #ffffff; }
@media(max-width:767px) { .topbar-meta { display: none; } }

/* Operational status badge */
.status-badge {
  display: flex; align-items: center; gap: 6px;
  padding: 5px 11px; border-radius: 20px;
  font-size: .72rem; font-weight: 600;
  background: rgba(5,150,105,.12); color: #059669;
  border: 1px solid rgba(5,150,105,.25);
}
[data-theme="dark"] .status-badge { background: rgba(5,150,105,.15); color: #34d399; border-color: rgba(52,211,153,.25); }
.status-dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--success);
  animation: pulse-dot 2s ease-in-out infinite;
}
@keyframes pulse-dot {
  0%,100% { opacity: 1; }
  50% { opacity: .4; }
}
@media(max-width:1024px) { .status-badge { display: none; } }

/* Icon buttons in topbar */
/* ── Topbar icon buttons — both modes ── */
.topbar-icon-btn {
  position: relative; width: 36px; height: 36px;
  background: transparent; border: none; cursor: pointer;
  border-radius: 8px; display: flex; align-items: center;
  justify-content: center; font-size: 1rem; transition: all .15s;
  /* LIGHT MODE: dark icon on white topbar */
  color: #374151;
}
.topbar-icon-btn:hover {
  background: #f3f4f6;
  color: #111827;
}
/* DARK MODE: light icon on dark topbar */
[data-theme="dark"] .topbar-icon-btn { color: #94a3b8; }
[data-theme="dark"] .topbar-icon-btn:hover { background: rgba(255,255,255,.06); color: #f1f5f9; }

/* Avatar */
.topbar-avatar {
  width: 34px; height: 34px; border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--teal));
  color: #fff; display: flex; align-items: center;
  justify-content: center; font-size: .72rem; font-weight: 700;
  cursor: pointer; flex-shrink: 0;
  border: 2px solid var(--border);
  transition: border-color .15s;
}
.topbar-avatar:hover { border-color: var(--primary); }

/* ── Sidebar ── */
.sidebar {
  position: fixed; top: 0; left: 0; bottom: 0;
  width: var(--sidebar-w); background: var(--sidebar-bg);
  overflow-y: auto; z-index: 1030;
  display: flex; flex-direction: column;
  transition: transform .25s;
  scrollbar-width: thin; scrollbar-color: rgba(255,255,255,.06) transparent;
}
@media(max-width:991px) {
  .sidebar { transform: translateX(-100%); }
  .sidebar.open { transform: translateX(0); box-shadow: 8px 0 32px rgba(0,0,0,.4); }
}

/* Sidebar brand */
/* sidebar-brand moved to logo section below */
/* sidebar-brand-icon replaced by sidebar-logo-img */
.sidebar-brand-text { line-height: 1.2; }
.sidebar-brand-name {
  font-size: .95rem; font-weight: 800; letter-spacing: -.03em;
  color: rgba(255,255,255,.95);
}
.sidebar-brand-name span { color: #22d3ee; }
.sidebar-brand-sub {
  font-size: .62rem; color: rgba(255,255,255,.4);
  text-transform: uppercase; letter-spacing: .8px;
}

/* Shift badge */
.shift-badge {
  margin: 12px 12px 8px;
  padding: 10px 12px;
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: var(--radius-sm);
}
.shift-badge strong { display: block; color: #fff; font-size: .82rem; font-weight: 600; }
.shift-time { font-size: .69rem; color: rgba(255,255,255,.45); margin-top: 2px; display: block; }

/* Station */
.sidebar-station { padding: 0 12px 8px; }
.sidebar-station select {
  width: 100%; background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.1);
  color: rgba(255,255,255,.85); border-radius: var(--radius-xs);
  padding: 6px 10px; font-size: .76rem; cursor: pointer; outline: none;
  font-family: inherit;
}
.sidebar-station select option { background: #1a2d45; color: #e2eaf8; }
.sidebar-single-station {
  padding: 0 14px 8px; font-size: .72rem;
  color: rgba(255,255,255,.4); display: flex; align-items: center; gap: 6px;
}

/* Nav sections */
.sidebar-inner { flex: 1; padding: 4px 0 16px; }
.sidebar-section {
  padding: 14px 16px 4px;
  font-size: .59rem; font-weight: 700; letter-spacing: 1.2px;
  text-transform: uppercase; color: rgba(255,255,255,.28);
}

/* Nav links */
.sidebar-link {
  display: flex; align-items: center; gap: 9px;
  padding: 8px 10px; margin: 1px 8px;
  border-radius: var(--radius-xs);
  color: rgba(255,255,255,.62); font-size: .82rem; font-weight: 500;
  transition: background .12s, color .12s; text-decoration: none;
}
.sidebar-link i { font-size: .88rem; width: 17px; text-align: center; flex-shrink: 0; opacity: .8; }
.sidebar-link:hover { background: var(--sidebar-hover); color: rgba(255,255,255,.9); }
.sidebar-link:hover i { opacity: 1; }
.sidebar-link.active {
  background: var(--sidebar-active);
  color: #fff; font-weight: 600;
  border-left: 2px solid var(--primary);
  padding-left: 8px;
}
.sidebar-link.active i { opacity: 1; color: #93c5fd; }

/* Sidebar footer */
.sidebar-footer {
  padding: 10px 8px;
  border-top: 1px solid rgba(255,255,255,.07);
}
.sidebar-help {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px; border-radius: var(--radius-xs);
  background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.07);
  cursor: pointer; transition: background .15s;
}
.sidebar-help:hover { background: rgba(255,255,255,.07); }
.sidebar-help-icon {
  width: 28px; height: 28px; border-radius: 50%;
  background: rgba(255,255,255,.1);
  display: flex; align-items: center; justify-content: center;
  font-size: .8rem; color: rgba(255,255,255,.6); flex-shrink: 0;
}
.sidebar-help-text div:first-child { font-size: .78rem; font-weight: 600; color: rgba(255,255,255,.75); }
.sidebar-help-text div:last-child { font-size: .67rem; color: rgba(255,255,255,.35); }

/* Backdrop */
.sidebar-backdrop {
  display: none; position: fixed; inset: 0;
  background: rgba(0,0,0,.5); z-index: 1025;
  backdrop-filter: blur(2px);
}
.sidebar-backdrop.open { display: block; }

/* ── Layout ── */
.main-wrap { margin-left: var(--sidebar-w); transition: margin .25s; }
.main-content {
  padding: calc(var(--topbar-h) + 24px) 24px 48px;
  min-height: 100vh; max-width: 1400px;
}
@media(max-width:991px) {
  .main-wrap { margin-left: 0; }
  .main-content { padding: calc(var(--topbar-h) + 16px) 16px 48px; }
}

/* ── Cards ── */
.card {
  background: var(--bg-card);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}
.card-header {
  padding: 14px 18px;
  background: var(--bg-card);
  border-bottom: 1px solid var(--border-soft);
  font-size: .82rem; font-weight: 600; color: var(--text);
  border-radius: var(--radius) var(--radius) 0 0;
  display: flex; align-items: center; gap: 8px;
}
.card-header i { color: var(--primary); }
.card-body { padding: 18px; }
.card-footer {
  padding: 12px 18px;
  background: var(--bg-card2);
  border-top: 1px solid var(--border-soft);
  border-radius: 0 0 var(--radius) var(--radius);
}
[data-theme="dark"] .card { background: var(--bg-card); border-color: var(--border); }
[data-theme="dark"] .card-header { background: var(--bg-card); border-color: var(--border); }

/* ── Stat cards ── */
.stat-card {
  border-radius: var(--radius);
  padding: 20px 20px 16px;
  position: relative; overflow: hidden;
  /* Ensure text is always white on gradient backgrounds */
  min-height: 100px; transition: transform .2s, box-shadow .2s;
}
.stat-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
a:hover > .stat-card { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.stat-card-inner { position: relative; z-index: 1; }
.stat-icon-wrap {
  width: 42px; height: 42px; border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem; margin-bottom: 12px;
  background: rgba(255,255,255,.15);
}
.stat-val {
  font-size: 1.8rem; font-weight: 800; line-height: 1; color: #fff;
  letter-spacing: -.02em; margin-bottom: 4px;
}
.stat-lbl {
  font-size: .7rem; font-weight: 600; color: rgba(255,255,255,.75);
  text-transform: uppercase; letter-spacing: .5px;
}
.stat-change {
  font-size: .7rem; color: rgba(255,255,255,.6); margin-top: 6px;
}
.stat-bg {
  position: absolute; right: -12px; bottom: -12px;
  font-size: 4rem; opacity: .1; line-height: 1;
}
.stat-blue    { background: linear-gradient(135deg, #1851e0 0%, #1240c0 100%); }
.stat-teal    { background: linear-gradient(135deg, #0694a2 0%, #0e7490 100%); }
.stat-indigo  { background: linear-gradient(135deg, #4f46e5 0%, #3730a3 100%); }
.stat-green   { background: linear-gradient(135deg, #059669 0%, #047857 100%); }
.stat-amber   { background: linear-gradient(135deg, #d97706 0%, #b45309 100%); }
.stat-orange  { background: linear-gradient(135deg, #ea580c 0%, #c2410c 100%); }
.stat-red     { background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%); }
.stat-purple  { background: linear-gradient(135deg, #7c3aed 0%, #6d28d9 100%); }
.stat-slate   { background: linear-gradient(135deg, #334155 0%, #1e293b 100%); }

/* ── Additional stat card colors ── */
.stat-navy   { background: linear-gradient(135deg, #1e3a5f 0%, #0f2040 100%); }
.stat-purple-dark { background: linear-gradient(135deg, #5b21b6 0%, #4c1d95 100%); }

/* ── Stat icon (shift_performance / occ pages) ── */
.stat-icon {
  position: absolute; right: 10px; bottom: 10px;
  font-size: 2rem; opacity: .15; line-height: 1;
  color: #fff; pointer-events: none;
}



/* Light stat cards */
.stat-card-light {
  border-radius: var(--radius);
  padding: 18px 20px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-xs);
  transition: box-shadow .2s, transform .2s;
}
.stat-card-light:hover { box-shadow: var(--shadow-md); transform: translateY(-1px); }
.stat-card-light .stat-light-icon {
  width: 40px; height: 40px; border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem; margin-bottom: 10px;
}
.stat-card-light .stat-light-val {
  font-size: 1.6rem; font-weight: 800; letter-spacing: -.02em;
  color: var(--text); line-height: 1;
}
.stat-card-light .stat-light-lbl {
  font-size: .72rem; color: var(--text-muted); font-weight: 500;
  margin-top: 3px;
}
.stat-card-light .stat-light-change {
  font-size: .7rem; margin-top: 6px; display: flex; align-items: center; gap: 3px;
}

/* ── Tables ── */
.table { width: 100%; border-collapse: collapse; }
.table th {
  padding: 10px 14px; background: var(--bg-card2);
  color: var(--text-muted); font-weight: 600; font-size: .72rem;
  text-transform: uppercase; letter-spacing: .5px;
  border-bottom: 2px solid var(--border);
}
.table td {
  padding: 10px 14px; border-bottom: 1px solid var(--border-soft);
  vertical-align: middle; color: var(--text); background: var(--bg-card);
  font-size: .83rem;
}
.table-hover tbody tr:hover td { background: var(--primary-light); }
[data-theme="dark"] .table th { background: var(--bg-card2); border-color: var(--border); }
[data-theme="dark"] .table td { background: var(--bg-card); border-color: var(--border); }
[data-theme="dark"] .table-hover tbody tr:hover td { background: rgba(24,81,224,.1); }

/* ── Forms ── */
.form-control, .form-select {
  border-radius: var(--radius-xs); border: 1.5px solid var(--border);
  font-size: .85rem; background: var(--bg-card); color: var(--text);
  padding: 8px 12px; font-family: inherit;
  transition: border-color .15s, box-shadow .15s;
}
.form-control:focus, .form-select:focus {
  border-color: var(--primary); outline: none;
  box-shadow: 0 0 0 3px var(--primary-glow);
  background: var(--bg-card);
}
[data-theme="dark"] .form-control, [data-theme="dark"] .form-select {
  background: var(--bg-card2); border-color: var(--border); color: var(--text);
}
.form-label {
  font-size: .75rem; font-weight: 600; color: var(--text-muted);
  margin-bottom: 5px; display: block; text-transform: uppercase; letter-spacing: .3px;
}
.form-text { font-size: .72rem; color: var(--text-light); margin-top: 4px; }
.input-group-text {
  background: var(--bg-card2); border-color: var(--border);
  color: var(--text-muted); font-size: .83rem;
}
[data-theme="dark"] .input-group-text { background: var(--bg-card2); border-color: var(--border); }

/* ── Buttons ── */
.btn { border-radius: var(--radius-xs); font-weight: 500; font-size: .83rem; font-family: inherit; }
.btn-primary {
  background: var(--primary); border-color: var(--primary);
  color: #fff; font-weight: 600;
}
.btn-primary:hover, .btn-primary:focus {
  background: var(--primary-dark); border-color: var(--primary-dark);
  color: #fff; box-shadow: 0 4px 12px var(--primary-glow);
}
.btn-outline-primary { color: var(--primary); border-color: var(--primary); border-width: 1.5px; }
.btn-outline-primary:hover { background: var(--primary); color: #fff; }
.btn-outline-secondary {
  color: var(--text-muted); border-color: var(--border); border-width: 1.5px;
}
.btn-outline-secondary:hover { background: var(--bg-card2); color: var(--text); border-color: var(--border); }
[data-theme="dark"] .btn-outline-secondary { border-color: var(--border); color: var(--text-muted); }
[data-theme="dark"] .btn-outline-secondary:hover { background: rgba(255,255,255,.05); color: var(--text); }
.btn-xs { padding: 3px 9px; font-size: .72rem; border-radius: 5px; }

/* ── Badges & Status ── */
.section-status {
  font-size: .69rem; padding: 3px 9px; border-radius: 20px;
  font-weight: 700; border: 1px solid transparent; white-space: nowrap;
}
.section-status.submitted {
  background: var(--success-soft); color: var(--success);
  border-color: rgba(5,150,105,.2);
}
.section-status.draft {
  background: var(--warning-soft); color: var(--warning);
  border-color: rgba(217,119,6,.2);
}
.section-status.not_started, .section-status.pending {
  background: var(--bg-card2); color: var(--text-light);
  border-color: var(--border);
}

/* Progress indicator */
.progress-ring { position: relative; display: inline-flex; }
.gauge-bar {
  height: 6px; background: var(--border); border-radius: 20px; overflow: hidden;
}
.gauge-fill { height: 100%; border-radius: 20px; transition: width .5s; }

/* ── Flash messages ── */
.flash-success {
  background: var(--success-soft); border: 1px solid rgba(5,150,105,.25);
  color: #065f46; padding: 12px 16px; border-radius: var(--radius-sm);
  margin-bottom: 14px; font-size: .83rem; display: flex; align-items: center; gap: 8px;
}
.flash-error {
  background: var(--danger-soft); border: 1px solid rgba(220,38,38,.25);
  color: #991b1b; padding: 12px 16px; border-radius: var(--radius-sm);
  margin-bottom: 14px; font-size: .83rem; display: flex; align-items: center; gap: 8px;
}
.flash-info {
  background: var(--info-soft); border: 1px solid rgba(2,132,199,.25);
  color: #075985; padding: 12px 16px; border-radius: var(--radius-sm);
  margin-bottom: 14px; font-size: .83rem; display: flex; align-items: center; gap: 8px;
}
.flash-warning {
  background: var(--warning-soft); border: 1px solid rgba(217,119,6,.25);
  color: #92400e; padding: 12px 16px; border-radius: var(--radius-sm);
  margin-bottom: 14px; font-size: .83rem; display: flex; align-items: center; gap: 8px;
}
[data-theme="dark"] .flash-success { background: var(--success-soft); color: #6ee7b7; border-color: rgba(5,150,105,.25); }
[data-theme="dark"] .flash-error   { background: var(--danger-soft);  color: #fca5a5; border-color: rgba(220,38,38,.25); }
[data-theme="dark"] .flash-info    { background: var(--info-soft);    color: #7dd3fc; border-color: rgba(2,132,199,.25); }
[data-theme="dark"] .flash-warning { background: var(--warning-soft); color: #fcd34d; border-color: rgba(217,119,6,.25); }

/* ── Page header ── */
.page-title {
  font-size: 1.2rem; font-weight: 800; color: var(--text);
  letter-spacing: -.03em; margin-bottom: 2px;
}
.page-breadcrumb {
  font-size: .75rem; color: var(--text-light); margin-bottom: 18px;
}
.page-breadcrumb a { color: var(--primary); }
.page-breadcrumb .sep { margin: 0 5px; }

/* ── Accordion ── */
.acc-header {
  width: 100%; display: flex; align-items: center;
  justify-content: space-between; padding: 13px 18px;
  background: var(--bg-card2); border: none;
  border-bottom: 1px solid var(--border-soft);
  cursor: pointer; font-size: .83rem; font-weight: 600;
  color: var(--text); text-align: left; transition: background .15s;
}
.acc-header:hover { background: var(--primary-light); }
[data-theme="dark"] .acc-header { background: var(--bg-card2); color: var(--text); }
[data-theme="dark"] .acc-header:hover { background: rgba(24,81,224,.12); }
.acc-body { padding: 18px; background: var(--bg-card); }
[data-theme="dark"] .acc-body { background: var(--bg-card); }

/* ── Sticky actions ── */
.sticky-actions {
  position: fixed; bottom: 0; left: var(--sidebar-w); right: 0;
  z-index: 900; background: rgba(255,255,255,.97);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-top: 1px solid var(--border);
  padding: 12px 24px; display: flex; align-items: center;
  gap: 10px; box-shadow: 0 -4px 16px rgba(0,0,0,.06);
}
[data-theme="dark"] .sticky-actions {
  background: rgba(15,28,46,.97); border-color: var(--border);
}
@media(max-width:991px) { .sticky-actions { left: 0; padding: 10px 16px; } }

/* ── Dropdowns (dark) ── */
[data-theme="dark"] .dropdown-menu {
  background: var(--bg-card2); border-color: var(--border); color: var(--text);
}
[data-theme="dark"] .dropdown-item { color: var(--text); }
[data-theme="dark"] .dropdown-item:hover { background: rgba(24,81,224,.12); color: var(--text); }
[data-theme="dark"] .dropdown-divider { border-color: var(--border); }

/* ── Modals (dark) ── */
[data-theme="dark"] .modal-content { background: var(--bg-card); border-color: var(--border); }
[data-theme="dark"] .modal-header { background: var(--bg-card2); border-color: var(--border); }
[data-theme="dark"] .modal-footer { background: var(--bg-card2); border-color: var(--border); }

/* ── Misc overrides ── */
[data-theme="dark"] .bg-light { background: var(--bg-card2) !important; }
[data-theme="dark"] .bg-white { background: var(--bg-card) !important; }
[data-theme="dark"] .text-dark { color: var(--text) !important; }
[data-theme="dark"] .border { border-color: var(--border) !important; }
[data-theme="dark"] .badge.bg-light { background: var(--bg-card2) !important; color: var(--text) !important; }
code {
  background: var(--primary-light); color: var(--primary);
  padding: 2px 6px; border-radius: 4px; font-size: .8em;
}
[data-theme="dark"] code { background: rgba(24,81,224,.18); }
hr { border-color: var(--border-soft); }
.fw-600 { font-weight: 600; }
.fw-700 { font-weight: 700; }
.fw-800 { font-weight: 800; }
.text-muted { color: var(--text-muted) !important; }
.text-teal { color: var(--teal) !important; }

/* ── Shift name badge ── */
.shift-name-badge {
  display: inline-flex; align-items: center; justify-content: center;
  width: 26px; height: 26px; border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--teal));
  color: #fff; font-weight: 700; font-size: .75rem;
}

/* ── Alert items (operational alerts) ── */
.alert-item {
  display: flex; align-items: flex-start; gap: 10px;
  padding: 10px 14px; border-radius: var(--radius-sm);
  border: 1px solid var(--border-soft); background: var(--bg-card2);
  transition: box-shadow .15s;
}
.alert-item:hover { box-shadow: var(--shadow-sm); }
.alert-dot {
  width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; margin-top: 5px;
}

/* ── Notification bell pulse ── */
@keyframes bell-shake {
  0%,100% { transform: rotate(0); }
  15% { transform: rotate(8deg); }
  30% { transform: rotate(-6deg); }
  45% { transform: rotate(5deg); }
  60% { transform: rotate(-3deg); }
}
.bell-animate { animation: bell-shake .5s ease; }



/* topbar-logo replaced - see logo image styles section */

/* ── Topbar clock — two separate pill blocks ── */
.topbar-clock-block {
  display: flex !important;
  flex-direction: row;
  align-items: center;
  gap: 6px;
  background: none;
  border: none;
  padding: 0;
  min-width: auto;
}
[data-theme="dark"] .topbar-clock-block { background: none; border: none; }

.topbar-clock-pill {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 5px 13px;
  border-radius: 8px;
  min-width: 72px;
  line-height: 1;
}
.topbar-clock-pill.local {
  background: #f1f5f9;
  border: 1px solid #dde3ef;
}
.topbar-clock-pill.utc {
  background: #eef2ff;
  border: 1px solid #c7d2fe;
}
[data-theme="dark"] .topbar-clock-pill.local {
  background: rgba(255,255,255,.07);
  border-color: rgba(255,255,255,.1);
}
[data-theme="dark"] .topbar-clock-pill.utc {
  background: rgba(99,102,241,.15);
  border-color: rgba(99,102,241,.3);
}

.topbar-clock-val {
  font-size: .88rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  letter-spacing: .04em;
  color: #0f172a;
  margin-bottom: 2px;
}
[data-theme="dark"] .topbar-clock-val { color: #ffffff; }

.topbar-clock-lbl {
  font-size: .55rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: #94a3b8;
}
[data-theme="dark"] .topbar-clock-lbl { color: rgba(255,255,255,.45); }
.topbar-clock-pill.utc .topbar-clock-lbl { color: #818cf8; }
[data-theme="dark"] .topbar-clock-pill.utc .topbar-clock-lbl { color: #a5b4fc; }

/* ── Topbar divider ── */
.topbar-divider {
  width: 1px; height: 30px;
  background: #dde3ef; margin: 0 6px;
  flex-shrink: 0;
}
[data-theme="dark"] .topbar-divider { background: rgba(255,255,255,.1); }

/* ── Topbar station name ── */
.topbar-station {
  font-size: .82rem; font-weight: 700;
  color: #0f172a; white-space: nowrap;
}
[data-theme="dark"] .topbar-station { color: #ffffff; }


/* ── Topbar weather widget ── */
.topbar-weather {
  align-items: center; gap: 7px;
  padding: 5px 12px;
  background: #f8faff;
  border: 1px solid #dde3ef;
  border-radius: 10px;
  cursor: default;
  transition: box-shadow .15s;
}
.topbar-weather:hover { box-shadow: 0 2px 8px rgba(0,0,0,.08); }
[data-theme="dark"] .topbar-weather {
  background: rgba(255,255,255,.06);
  border-color: rgba(255,255,255,.1);
}
.weather-temp {
  font-size: .92rem; font-weight: 800;
  color: #0f172a; letter-spacing: -.02em;
  font-variant-numeric: tabular-nums;
}
[data-theme="dark"] .weather-temp { color: #f1f5f9; }
.weather-detail {
  display: flex; flex-direction: column; gap: 1px;
  font-size: .65rem; font-weight: 600;
  color: #475569; line-height: 1.2;
}
[data-theme="dark"] .weather-detail { color: #7a90b0; }

/* ── Responsive ── */
@media(max-width:767px) {
  .page-title { font-size: 1rem; }
  .card-body, .acc-body { padding: 14px; }
  .stat-val { font-size: 1.5rem; }
  .sticky-actions { flex-wrap: wrap; }
  .main-content { padding-top: calc(var(--topbar-h) + 12px); }
}
