:root {
  --accent: #6dbc44;
  --accent2: #5aa938;
}

.theme-toggle { border:1px solid #496065; border-radius:999px; width:34px; height:34px; padding:0; background:transparent; color:white; cursor:pointer; font-size:18px; line-height:1; }
.theme-toggle:hover,.theme-toggle:focus-visible { border-color:var(--accent); outline:none; }
.devmail-switch { border-top:1px solid var(--line); }
.email-mode-warning { margin:0 24px 20px; color:var(--amber); font-weight:700; }

html[data-theme="dark"] { --ink:#e7eeee; --muted:#9eadaf; --line:#35484b; --paper:#1b2b2e; --bg:#101a1c; --nav:#091214; --shadow:0 8px 30px rgba(0,0,0,.28); color-scheme:dark; }
html[data-theme="dark"] body,html[data-theme="dark"] input,html[data-theme="dark"] select,html[data-theme="dark"] textarea { color:var(--ink); }
html[data-theme="dark"] input,html[data-theme="dark"] select,html[data-theme="dark"] textarea,html[data-theme="dark"] .btn.ghost { background:#223438; border-color:var(--line); }
html[data-theme="dark"] .metric,html[data-theme="dark"] th { background:#203135; }
html[data-theme="dark"] td { border-bottom-color:#2b3d40; }
html[data-theme="dark"] .clickable:hover,html[data-theme="dark"] .schedule-board-item:hover,html[data-theme="dark"] .sortable-header:hover,html[data-theme="dark"] .sortable-header:focus-visible { background:#263b36; }
html[data-theme="dark"] .notification-item.is-unread,html[data-theme="dark"] .daily-shift-card.is-current>header { background:#243b31; }
html[data-theme="dark"] .issue-hero { border:1px solid var(--line); }
html[data-theme="dark"] .gallery a { background:#213236; }
html[data-theme="dark"] .timeline article>i { border-color:var(--paper); }
html[data-theme="dark"] .feedback-dialog,html[data-theme="dark"] .motd-dialog,html[data-theme="dark"] .demo-notice { background:var(--paper); color:var(--ink); }

/* A four-armed Maltese cross; clipping keeps the area around it transparent. */
.brand-mark {
  border-radius: 0;
  background: var(--accent);
  color: transparent;
  font-size: 0;
  transform: rotate(45deg);
  clip-path: polygon(
    50% 38%, 30% 8%, 8% 30%, 38% 50%,
    8% 70%, 30% 92%, 50% 62%, 70% 92%,
    92% 70%, 62% 50%, 92% 30%, 70% 8%
  );
}

.btn.primary {
  color: #10270b;
  box-shadow: 0 6px 16px rgba(109, 188, 68, .24);
}

input:focus,
select:focus,
textarea:focus {
  box-shadow: 0 0 0 3px rgba(109, 188, 68, .16);
}

.clickable:hover { background: #f4faef; }
.drop-zone.drag-over { background: #f2faee; }
.version-mark { margin-left: 7px; color: #8fd271; font: 700 10px 'DM Sans',sans-serif; font-style: normal; letter-spacing: .04em; vertical-align: top; }
.login-version { display: inline-block; margin-top: 4px; color: #8fd271; font-weight: 700; letter-spacing: .08em; }
.asset-list-card .section-head { background: linear-gradient(90deg, rgba(109,188,68,.08), transparent); }
.asset-table td { padding-top: 14px; padding-bottom: 14px; }
.asset-name-link:hover { color: var(--accent); }
.case-count { display: inline-grid; place-items: center; min-width: 30px; height: 30px; padding: 0 8px; border-radius: 999px; font-weight: 800; }
.case-count.has-open { color: #9b3d16; background: #ffebdf; }
.case-count.clear { color: #377722; background: #e8f5e2; }
.pill.asset-disabled { color: #7b858d; opacity: .7; text-decoration: line-through; }
.efs-safety-card { display: grid; grid-template-columns:minmax(260px,1fr) minmax(380px,1.4fr) auto; align-items:center; gap:24px; padding:18px 22px; margin-bottom:22px; border-left:5px solid var(--accent); transition:transform .15s,box-shadow .15s; }
.efs-safety-card:hover { transform:translateY(-1px); box-shadow:0 12px 34px rgba(18,38,42,.12); }
.efs-safety-card.is-alert { border-left-color:var(--red); }
.efs-safety-title { display:flex;align-items:center;gap:14px; }
.efs-safety-title h2 { margin-top:3px;font-size:21px; }
.efs-forklift-icon { display:block;width:48px;height:48px;object-fit:contain; }
.efs-safety-card.is-alert .efs-forklift-icon { filter:drop-shadow(0 0 4px rgba(189,40,30,.3)); }
.efs-safety-metrics { display:grid;grid-template-columns:repeat(3,1fr);gap:10px; }
.efs-safety-metrics div { border-left:1px solid var(--line);padding-left:16px; }
.efs-safety-metrics small,.efs-safety-metrics strong { display:block; }
.efs-safety-metrics small { color:var(--muted);font-size:11px; }
.efs-safety-metrics strong { font-size:17px;margin-top:2px; }
.efs-safety-state { text-align:right; }
.efs-safety-state span,.efs-safety-state small { display:block; }
.efs-safety-state span { color:#326d1c;font-weight:800;font-size:16px; }
.efs-safety-card.is-alert .efs-safety-state span { color:var(--red); }
.efs-safety-state small { color:var(--muted);margin-top:3px; }
.daily-shift-card.is-current { border-color:#8ac96a;box-shadow:0 8px 30px rgba(109,188,68,.14); }
.daily-shift-card.is-current>header { background:#f2faee; }
.daily-shift-card>header h3 small { display:inline-flex;margin-left:9px;padding:3px 7px;border-radius:999px;background:#dff3d6;color:#2c6816;font:800 10px 'DM Sans';text-transform:uppercase; }
.daily-task.is-not-done { background:#fff5f3; }
.daily-recorded-by { display:block;color:var(--muted);font-size:11px;margin-top:5px; }
.daily-outcome-actions,.weekly-outcome-actions { display:flex;gap:6px;justify-content:flex-end; }
.daily-outcome-actions form,.weekly-outcome-actions form { margin:0; }
.daily-done-btn { background:#e7f6ef;color:#14704e; }
.daily-not-done-btn { background:#fee7e4;color:#bd281e; }
.daily-done-btn.selected { background:var(--green);color:white; }
.daily-not-done-btn.selected { background:var(--red);color:white; }
.weekly-outcome { width:28px;height:28px;padding:0;border:0;border-radius:7px;cursor:pointer;font-weight:900;background:#edf1f2;color:#7b858d; }
.weekly-outcome.done:hover,.weekly-outcome.done.selected { background:#dff3d6;color:#2c6816; }
.weekly-outcome.not-done:hover,.weekly-outcome.not-done.selected { background:#fee7e4;color:#bd281e; }
.weekly-status-label { display:block;margin-top:3px;color:var(--muted);font-size:9px; }
.weekly-status-picker { position:relative; }
.weekly-status-picker summary { list-style:none;cursor:pointer; }
.weekly-status-picker summary::-webkit-details-marker { display:none; }
.weekly-status-summary { display:flex;min-height:54px;flex-direction:column;align-items:center;justify-content:center;border-radius:9px;padding:5px;font-weight:900; }
.weekly-status-summary b { font:900 28px/1 'Space Grotesk'; }
.weekly-status-summary small { display:block;max-width:78px;margin-top:3px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:9px; }
.weekly-status-summary.status-done { background:#dff3d6;color:#2c6816; }
.weekly-status-summary.status-not-done { background:#fee7e4;color:#bd281e; }
.weekly-status-summary.status-due { background:#fff0db;color:#925300; }
.weekly-status-summary.status-due b { font-size:14px; }
.weekly-status-menu { display:grid;gap:5px;margin-top:5px; }
.weekly-status-menu form { margin:0; }
.weekly-choice { width:100%;border:0;border-radius:6px;padding:6px 4px;cursor:pointer;font:800 10px 'DM Sans'; }
.weekly-choice.done { background:#e7f6ef;color:#14704e; }
.weekly-choice.not-done { background:#fee7e4;color:#bd281e; }
.demo-notice { width:min(460px,calc(100% - 32px));border:0;border-top:6px solid var(--amber);border-radius:16px;padding:28px;box-shadow:0 24px 70px rgba(18,38,42,.3); }
.demo-notice::backdrop { background:rgba(15,31,34,.62); }
.demo-notice-head h2 { margin:4px 0 14px;font-size:28px; }
.demo-notice p { margin:0 0 24px;font-size:18px;font-weight:700; }
.dashboard-head-actions { display:flex;gap:10px;align-items:center; }
.dashboard-head-actions form { margin:0; }
.gas-fill-btn { background:var(--red);color:white;box-shadow:0 6px 16px rgba(214,61,61,.24); }
.gas-fill-btn:hover { background:#bd2828; }
.notification-link { position:relative;font-size:18px;color:#8fd271!important; }
.notification-link b { position:absolute;left:10px;top:-8px;display:grid;place-items:center;min-width:18px;height:18px;padding:0 4px;border-radius:999px;background:var(--red);color:white;font-size:9px; }
.notification-list { overflow:hidden; }
.notification-item { display:flex;align-items:center;justify-content:space-between;gap:24px;padding:20px 24px;border-bottom:1px solid var(--line); }
.notification-item:last-child { border-bottom:0; }
.notification-item.is-unread { background:#f4faef;border-left:4px solid var(--accent); }
.notification-item h2 { margin:3px 0 5px;font-size:18px; }
.notification-item p { margin:0;color:var(--muted); }
.notification-item small { display:block;color:var(--muted);margin-top:7px; }
.notification-kind { color:var(--accent2);font-size:10px;font-weight:800;letter-spacing:.08em; }
.coregas-alert { position:fixed;left:22px;bottom:22px;z-index:20;display:flex;align-items:center;gap:10px;padding:15px 18px;border-radius:12px;background:#a91f1f;color:white;box-shadow:0 12px 35px rgba(70,10,10,.3); }
.coregas-alert strong { font-size:12px;letter-spacing:.06em; }
.coregas-alert time { font:800 19px 'Space Grotesk'; }
@media(max-width:700px){.dashboard-head-actions{width:100%;display:grid;grid-template-columns:1fr 1fr}.dashboard-head-actions form,.dashboard-head-actions .btn{width:100%}.coregas-alert{left:14px;right:14px;bottom:14px;justify-content:center}}
.dashboard-schedule { margin-top: 22px; overflow: hidden; }
.schedule-board { border-top: 1px solid var(--line); }
.schedule-board-item { display: grid; grid-template-columns: 92px 125px minmax(220px,1fr) auto; gap: 16px; align-items: center; padding: 15px 22px; border-bottom: 1px solid var(--line); transition: background .15s; }
.schedule-board-item:last-child { border-bottom: 0; }
.schedule-board-item:hover { background: #f4faef; }
.schedule-kind { color: #326d1c; background: #e8f5e2; border-radius: 999px; padding: 5px 8px; text-align: center; font-size: 10px; font-weight: 800; letter-spacing: .05em; }
.schedule-board-item time strong,.schedule-board-item time b,.schedule-machine strong,.schedule-machine small,.schedule-machine em { display: block; }
.schedule-board-item time b { color: var(--accent2); font-size: 18px; }
.schedule-machine small { color: var(--muted); }
.schedule-machine em { color: var(--muted); font-size: 12px; margin-top: 2px; }
.schedule-state { color: var(--muted); font-size: 12px; font-weight: 800; }
.schedule-board-item.is-overdue { background: #fff8f3; }
.schedule-board-item.is-overdue .schedule-kind { color: #9b3d16; background: #ffebdf; }
.schedule-board-item.is-overdue .schedule-state { color: #b23f19; }
@media(max-width:700px){.schedule-board-item{grid-template-columns:80px 1fr;gap:8px 12px}.schedule-machine{grid-column:1/-1}.schedule-state{position:absolute;right:26px}.dashboard-schedule{position:relative}}
@media(max-width:1000px){.efs-safety-card{grid-template-columns:1fr}.efs-safety-state{text-align:left}.efs-safety-metrics div:first-child{border-left:0;padding-left:0}}
@media(max-width:700px){.efs-safety-metrics{grid-template-columns:1fr 1fr}.efs-safety-metrics div{border-left:0;padding-left:0}.efs-safety-metrics div:last-child{grid-column:1/-1}}
.sortable-header { cursor: pointer; user-select: none; transition: background .15s, color .15s; }
.sortable-header:hover, .sortable-header:focus-visible { background: #edf7e8; color: #315e20; outline: none; }
.sort-marker { display: inline-block; min-width: 13px; margin-left: 6px; color: var(--accent2); font-size: 12px; }
