:root {
  color-scheme: light;
  --bg: #eef2f6;
  --bg-2: #f8f4ec;
  --panel: rgba(255, 255, 255, 0.82);
  --panel-solid: #ffffff;
  --text: #16212a;
  --muted: #65717e;
  --line: rgba(22, 33, 42, 0.08);
  --accent: #166c77;
  --accent-2: #c35f2f;
  --accent-soft: rgba(22, 108, 119, 0.12);
  --nav: #0d1f30;
  --nav-2: #183447;
  --germabouw-navy: #0d1f30;
  --germabouw-blue: #183e63;
  --germabouw-steel: #2d587d;
  --germabouw-orange: #c35f2f;
  --germabouw-amber: #d07e2d;
  --shadow: 0 24px 56px rgba(16, 24, 40, 0.1);
  --radius: 24px;
  --radius-sm: 16px;
  font-family: "Inter", "Segoe UI", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  background:
    radial-gradient(circle at 10% 10%, rgba(22, 108, 119, 0.12), transparent 24%),
    radial-gradient(circle at 90% 0%, rgba(195, 95, 47, 0.12), transparent 22%),
    radial-gradient(circle at 50% 100%, rgba(18, 33, 48, 0.07), transparent 18%),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-2) 100%);
  color: var(--text);
}

body {
  position: relative;
  overflow-x: hidden;
  padding: 0;
}

body::before,
body::after {
  content: "";
  position: fixed;
  border-radius: 50%;
  pointer-events: none;
  z-index: -1;
  filter: blur(0.5px);
}

body::before {
  width: 520px;
  height: 520px;
  top: -180px;
  left: -180px;
  background: radial-gradient(circle, rgba(22, 108, 119, 0.16) 0%, rgba(22, 108, 119, 0.03) 55%, transparent 70%);
}

body::after {
  width: 360px;
  height: 360px;
  top: 40px;
  right: -110px;
  background: radial-gradient(circle, rgba(195, 95, 47, 0.16) 0%, rgba(195, 95, 47, 0.04) 55%, transparent 70%);
}

.hidden {
  display: none !important;
}

[hidden] {
  display: none !important;
}

.login-screen {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 20px;
}

.login-login {
  width: min(520px, 100%);
  padding: 34px;
  border-radius: 30px;
  background:
    radial-gradient(circle at 15% 10%, rgba(22, 108, 119, 0.15), transparent 24%),
    radial-gradient(circle at 85% 0%, rgba(195, 95, 47, 0.12), transparent 18%),
    rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(22, 33, 42, 0.08);
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
}

.login-login h1 {
  margin: 10px 0 8px;
  font-size: clamp(2.1rem, 4vw, 3.2rem);
  letter-spacing: -0.05em;
  line-height: 0.96;
}

.login-login-kicker {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(22, 108, 119, 0.12);
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.login-form-simple {
  margin-top: 22px;
}

.login-form-simple .primary {
  min-height: 48px;
}

.login-login .login-hint {
  margin-top: 18px;
}

.login-stage {
  width: min(1160px, 100%);
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(360px, 0.8fr);
  gap: 20px;
  align-items: stretch;
}

.login-right-column {
  display: grid;
  gap: 16px;
}

.login-card {
  width: 100%;
  padding: 30px;
}

.login-intro {
  position: relative;
  overflow: hidden;
  padding: 34px;
  border-radius: 30px;
  background:
    radial-gradient(circle at 14% 10%, rgba(67, 158, 168, 0.38), transparent 26%),
    radial-gradient(circle at 92% 8%, rgba(214, 151, 88, 0.28), transparent 24%),
    radial-gradient(circle at 82% 88%, rgba(15, 33, 51, 0.16), transparent 24%),
    linear-gradient(160deg, rgba(10, 24, 38, 0.98), rgba(18, 43, 60, 0.96) 55%, rgba(27, 64, 86, 0.94));
  color: rgba(255, 255, 255, 0.94);
}

.login-intro::before {
  content: "";
  position: absolute;
  inset: 18px;
  border-radius: 22px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  pointer-events: none;
}

.login-intro .eyebrow,
.login-intro .muted,
.login-intro .label {
  color: rgba(255, 255, 255, 0.7);
}

.login-intro h1 {
  margin: 12px 0 10px;
  max-width: 11ch;
  font-size: clamp(2.6rem, 5.2vw, 4.8rem);
  letter-spacing: -0.06em;
  line-height: 0.95;
}

.login-intro-top {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(240px, 0.55fr);
  gap: 22px;
  align-items: start;
}

.login-status-stack {
  display: grid;
  gap: 10px;
  align-content: start;
  justify-items: start;
}

.login-status-stack .pill {
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.88);
  border-color: rgba(255, 255, 255, 0.08);
}

.login-proof-stack {
  padding: 4px 0 0;
}

.login-hero-copy {
  display: grid;
  gap: 14px;
}

.login-hero-copy .muted {
  max-width: 56ch;
  line-height: 1.6;
}

.login-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin-top: 2px;
}

.login-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  min-height: 44px;
}

.login-benefit-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.login-device {
  position: relative;
  z-index: 1;
  margin-top: 28px;
  border-radius: 24px;
  padding: 18px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.login-feature-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 16px;
}

.login-feature-card {
  display: grid;
  gap: 10px;
  padding: 16px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.1);
  min-height: 132px;
}

.login-feature-card strong {
  color: #fff;
  font-size: 1.05rem;
  letter-spacing: -0.03em;
}

.login-feature-card .muted {
  color: rgba(255, 255, 255, 0.74);
  line-height: 1.5;
}

.login-feature-step {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  border-radius: 999px;
  padding: 5px 9px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: rgba(255, 255, 255, 0.76);
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.login-device-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-bottom: 14px;
}

.login-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.35);
}

.login-device-title {
  margin-left: 8px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.92rem;
}

.login-metric-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.login-metric {
  border-radius: 18px;
  padding: 16px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
  display: grid;
  gap: 8px;
}

.login-metric strong {
  color: #fff;
  font-size: 1rem;
  line-height: 1.35;
}

.login-preview-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.login-preview-strip .pill {
  background: rgba(255, 255, 255, 0.07);
  color: rgba(255, 255, 255, 0.85);
  border-color: rgba(255, 255, 255, 0.08);
}

.login-card {
  display: grid;
  gap: 18px;
  max-width: 480px;
  justify-self: stretch;
  padding: 32px;
  border-radius: 30px;
}

.login-card-header {
  display: grid;
  gap: 6px;
}

.login-card-kicker {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  border-radius: 999px;
  padding: 6px 10px;
  background: rgba(22, 108, 119, 0.12);
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.login-card h1 {
  margin: 10px 0 8px;
  font-size: clamp(2rem, 4vw, 3rem);
  letter-spacing: -0.05em;
}

.login-card h2 {
  margin: 0;
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  letter-spacing: -0.05em;
}

.lead-card {
  max-width: none;
}

.lead-form {
  display: grid;
  gap: 14px;
}

.lead-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.login-form {
  display: grid;
  gap: 14px;
  margin: 24px 0 18px;
}

.login-form label,
.mini-form label,
.lead-form label {
  display: grid;
  gap: 6px;
  font-size: 0.92rem;
  color: var(--muted);
}

.mini-form .checkbox-row {
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 12px;
}

.mini-form .checkbox-row input {
  width: 1rem;
  height: 1rem;
}

.login-form input,
.mini-form input,
.mini-form select,
.lead-form input,
.lead-form select,
.lead-form textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.96);
  color: var(--text);
  padding: 12px 14px;
  font: inherit;
}

.lead-form textarea {
  resize: vertical;
  min-height: 110px;
}

.login-hint {
  display: grid;
  gap: 6px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  color: var(--muted);
}

.lead-form-note {
  margin: 0;
  line-height: 1.5;
}

.portal-card {
  max-width: none;
  padding: 0;
}

.portal-card details {
  display: block;
  padding: 0;
}

.portal-card summary {
  list-style: none;
  cursor: pointer;
}

.portal-card summary::-webkit-details-marker {
  display: none;
}

.portal-summary {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  padding: 18px 0 4px;
}

.portal-summary strong {
  display: block;
  margin-top: 4px;
  font-size: 1rem;
  letter-spacing: -0.03em;
}

.portal-body {
  display: grid;
  gap: 14px;
  padding-top: 16px;
}

@media (max-width: 960px) {
  .login-stage {
    grid-template-columns: 1fr;
  }

  .login-intro,
  .login-card {
    border-radius: 24px;
  }

  .login-metric-grid {
    grid-template-columns: 1fr;
  }

  .login-intro-top,
  .login-feature-grid,
  .lead-form-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .login-screen {
    padding: 14px;
  }

  .login-intro,
  .login-card {
    padding: 22px;
  }

  .login-intro h1 {
    max-width: none;
  }

  .login-hero-actions {
    align-items: stretch;
  }

  .login-cta,
  .login-hero-actions .pill {
    width: 100%;
  }

  .login-benefit-row .pill {
    width: auto;
  }

  .portal-summary {
    align-items: flex-start;
    flex-direction: column;
  }
}

.shell {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 18px;
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 20px;
}

.app-shell {
  align-items: start;
}

.sidebar,
.card {
  background: var(--panel);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.sidebar {
  color: rgba(255, 255, 255, 0.92);
  background:
    radial-gradient(circle at top right, rgba(255, 255, 255, 0.08), transparent 28%),
    linear-gradient(180deg, var(--nav) 0%, var(--nav-2) 100%);
  border-radius: 30px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: sticky;
  top: 20px;
  min-height: calc(100vh - 40px);
}

.brand {
  font-size: 1.7rem;
  font-weight: 800;
  letter-spacing: -0.04em;
  color: #fff;
}

.subtitle,
.muted,
.label,
.eyebrow {
  color: var(--muted);
}

.sidebar .subtitle,
.sidebar .muted,
.sidebar .label,
.sidebar .eyebrow {
  color: rgba(255, 255, 255, 0.68);
}

.subtitle {
  margin-top: 4px;
}

.nav {
  display: grid;
  gap: 8px;
  margin: 24px 0;
}

.nav-item,
button {
  font: inherit;
}

.nav-item {
  border: 1px solid transparent;
  background: rgba(255, 255, 255, 0.03);
  color: rgba(255, 255, 255, 0.88);
  text-align: left;
  padding: 12px 14px;
  border-radius: 14px;
  cursor: pointer;
}

.nav-item:hover,
.nav-item.active {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.14), rgba(255, 255, 255, 0.09));
  border-color: rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.sidebar-card {
  padding: 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.big {
  font-size: 2rem;
  font-weight: 800;
  margin: 10px 0 6px;
}

.main {
  min-width: 0;
  min-height: calc(100vh - 40px);
  position: relative;
}

.main::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 32px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.42), transparent 24%),
    radial-gradient(circle at 20% 0%, rgba(22, 108, 119, 0.08), transparent 32%);
  pointer-events: none;
  z-index: 0;
}

.topbar {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr;
  align-items: flex-start;
  gap: 18px;
  margin-bottom: 20px;
}

.topbar-copy {
  max-width: 58ch;
  margin-top: 12px;
}

.topbar h1 {
  margin: 8px 0 0;
  font-size: clamp(1.9rem, 2.8vw, 3.1rem);
  line-height: 0.98;
  letter-spacing: -0.05em;
  max-width: 14ch;
}

.topbar-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
}

.topbar-actions .status-chip {
  background: rgba(22, 108, 119, 0.12);
  color: var(--accent);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
}

.dashboard-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 16px;
}

.dashboard-actions button {
  flex: 1 1 160px;
}

.workflow-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 18px;
  position: relative;
  padding: 10px 0 6px;
}

.workflow-strip::before {
  content: "";
  position: absolute;
  left: 36px;
  right: 36px;
  top: 38px;
  height: 2px;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(22, 108, 119, 0.1), rgba(22, 108, 119, 0.38), rgba(195, 95, 47, 0.26));
}

.workflow-step {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 12px;
  padding: 18px;
  border-radius: 24px;
  border: 1px solid rgba(22, 33, 42, 0.08);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.99), rgba(241, 246, 248, 0.96));
  box-shadow: 0 16px 32px rgba(16, 24, 40, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.82);
  position: relative;
}

.workflow-step::after {
  content: "";
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 14px;
  height: 4px;
  border-radius: 999px;
  background: rgba(22, 108, 119, 0.08);
}

.workflow-step.complete::after {
  background: linear-gradient(90deg, rgba(22, 108, 119, 0.45), rgba(22, 108, 119, 0.18));
}

.workflow-step.active {
  transform: translateY(-2px);
  border-color: rgba(22, 108, 119, 0.22);
  background:
    radial-gradient(circle at top right, rgba(22, 108, 119, 0.12), transparent 34%),
    linear-gradient(180deg, rgba(255, 255, 255, 1), rgba(236, 244, 246, 0.96));
  box-shadow: 0 24px 44px rgba(16, 24, 40, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.88);
}

.workflow-step.next {
  opacity: 0.86;
}

.workflow-step-top {
  display: flex;
  gap: 8px;
  justify-content: space-between;
  align-items: flex-start;
}

.workflow-step h3 {
  margin: 6px 0 6px;
  font-size: 1.05rem;
  letter-spacing: -0.03em;
}

.workflow-step p {
  margin: 0;
  line-height: 1.45;
}

.workflow-step-index {
  width: 44px;
  height: 44px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  font-weight: 800;
  color: var(--accent);
  background: rgba(22, 108, 119, 0.1);
  position: relative;
  z-index: 1;
}

.workflow-step-body {
  position: relative;
  z-index: 1;
}

.workflow-step {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 12px;
  padding: 16px;
  border-radius: 22px;
  border: 1px solid rgba(22, 33, 42, 0.08);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(244, 239, 232, 0.96));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.82);
}

.workflow-step h3 {
  margin: 4px 0 6px;
  font-size: 1.05rem;
  letter-spacing: -0.03em;
}

.workflow-step p {
  margin: 0;
  line-height: 1.45;
}

.workflow-step-index {
  width: 44px;
  height: 44px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  font-weight: 800;
  color: var(--accent);
  background: rgba(22, 108, 119, 0.1);
}

.dashboard-hero {
  display: grid;
  gap: 18px;
  grid-template-columns: minmax(0, 1.7fr) minmax(260px, 0.8fr);
  align-items: stretch;
  padding: 24px;
  margin-bottom: 16px;
  overflow: hidden;
  position: relative;
  background:
    radial-gradient(circle at top right, rgba(22, 108, 119, 0.12), transparent 30%),
    radial-gradient(circle at bottom left, rgba(195, 95, 47, 0.09), transparent 26%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(247, 243, 236, 0.94));
  border: 1px solid rgba(22, 33, 42, 0.08);
}

.dashboard-hero::after {
  content: "";
  position: absolute;
  inset: -1px;
  background:
    linear-gradient(115deg, transparent 18%, rgba(255, 255, 255, 0.24) 28%, transparent 40%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.2), transparent 18%);
  pointer-events: none;
}

.role-banner {
  margin-bottom: 16px;
  padding: 18px 20px;
  background:
    radial-gradient(circle at top right, rgba(22, 108, 119, 0.1), transparent 28%),
    radial-gradient(circle at bottom left, rgba(195, 95, 47, 0.08), transparent 26%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(247, 243, 236, 0.92));
  border: 1px solid rgba(22, 33, 42, 0.08);
}

.role-banner.partner-mode {
  background:
    radial-gradient(circle at top right, rgba(22, 108, 119, 0.16), transparent 30%),
    radial-gradient(circle at bottom left, rgba(195, 95, 47, 0.12), transparent 28%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(244, 239, 231, 0.96));
  border-color: rgba(22, 108, 119, 0.16);
  box-shadow: 0 24px 40px rgba(15, 23, 34, 0.06);
}

.role-banner.partner-mode .pill.ok {
  background: rgba(22, 108, 119, 0.12);
}

.role-banner.jim-mode {
  border-color: rgba(22, 108, 119, 0.14);
}

.role-banner.finance-mode {
  border-color: rgba(195, 95, 47, 0.16);
}

.role-banner.worker-mode {
  border-color: rgba(22, 33, 42, 0.06);
}

.worker-language-select {
  display: grid;
  gap: 6px;
  padding: 12px 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(22, 33, 42, 0.07);
}

.worker-language-select select {
  width: 100%;
  border: 1px solid rgba(22, 33, 42, 0.1);
  border-radius: 12px;
  padding: 10px 12px;
  font: inherit;
  background: rgba(255, 255, 255, 0.96);
}

.worker-setup-callout {
  display: grid;
  gap: 0.35rem;
  padding: 0.85rem 1rem;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: linear-gradient(135deg, rgba(15, 23, 34, 0.94), rgba(16, 27, 40, 0.88));
  margin-top: 0.9rem;
}

.worker-language-select {
  display: grid;
  gap: 6px;
  padding: 12px 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(22, 33, 42, 0.07);
}

.worker-language-select select {
  width: 100%;
  border: 1px solid rgba(22, 33, 42, 0.1);
  border-radius: 12px;
  padding: 10px 12px;
  font: inherit;
  background: rgba(255, 255, 255, 0.96);
}

.role-banner-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.8fr);
  align-items: start;
}

.role-banner h3 {
  margin: 6px 0 8px;
  font-size: 1.35rem;
  letter-spacing: -0.04em;
}

.role-banner-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.role-banner-note {
  display: grid;
  gap: 8px;
  align-content: start;
}

.dashboard-hero-copy h2 {
  margin: 8px 0 10px;
  font-size: clamp(1.75rem, 3vw, 2.8rem);
  line-height: 0.98;
  letter-spacing: -0.06em;
}

.dashboard-hero-copy p {
  margin: 0;
  max-width: 68ch;
  line-height: 1.55;
}

.dashboard-hero-points {
  display: grid;
  gap: 10px;
  position: relative;
  z-index: 1;
}

.dashboard-hero-point {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  padding: 12px 14px;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(22, 108, 119, 0.08), rgba(255, 255, 255, 0.96));
  border: 1px solid rgba(18, 33, 52, 0.08);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.dashboard-hero-point strong {
  width: 40px;
  height: 40px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: rgba(43, 110, 118, 0.12);
  color: var(--accent);
}

button {
  border: 0;
  border-radius: 13px;
  padding: 11px 14px;
  cursor: pointer;
  transition: transform 0.15s ease, opacity 0.15s ease, background 0.15s ease;
}

button:hover {
  transform: translateY(-1px);
}

.primary {
  background: linear-gradient(180deg, #1c7b85 0%, #115962 100%);
  color: white;
  box-shadow: 0 16px 28px rgba(22, 108, 119, 0.18);
}

.ghost {
  background: rgba(255, 255, 255, 0.86);
  border: 1px solid var(--line);
  color: var(--text);
}

.small {
  padding: 10px 12px;
}

.full {
  width: 100%;
}

.content {
  display: none;
  animation: fade 0.18s ease;
}

.content.active {
  display: block;
  width: 100%;
}

.grid {
  display: grid;
  gap: 16px;
}

.stats {
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  margin-bottom: 16px;
}

.dashboard-grid {
  grid-template-columns: minmax(0, 1.15fr) minmax(340px, 0.85fr);
  margin-bottom: 16px;
}

.two-col {
  grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
}

.agenda-layout {
  position: relative;
  grid-template-columns: minmax(0, 1fr);
  min-height: 680px;
}

.agenda-layout.list-mode {
  grid-template-columns: minmax(0, 1fr);
}

.card {
  border-radius: var(--radius);
  padding: 22px;
  background: rgba(255, 255, 255, 0.9);
}

.overview-card {
  padding-bottom: 16px;
  margin-bottom: 16px;
}

.tab-strip {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  padding: 2px;
  margin-top: 8px;
}

.tab-pill {
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid var(--line);
  color: var(--text);
  padding: 10px 13px;
  border-radius: 999px;
  font-weight: 600;
}

.tab-pill.active {
  background: linear-gradient(180deg, #2f74ba 0%, #245f9c 100%);
  color: white;
  border-color: transparent;
}

.metric strong {
  display: block;
  font-size: 1.8rem;
  margin: 10px 0 6px;
  letter-spacing: -0.04em;
}

.metric {
  min-height: 120px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.panel-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 14px;
}

.panel-head h2 {
  margin: 6px 0 0;
  letter-spacing: -0.03em;
}

.command-center {
  margin-bottom: 16px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(246, 242, 236, 0.94)),
    radial-gradient(circle at top right, rgba(22, 108, 119, 0.08), transparent 26%);
  border: 1px solid rgba(22, 33, 42, 0.08);
  position: relative;
  overflow: hidden;
}

.command-center::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(140deg, transparent 20%, rgba(22, 108, 119, 0.06) 42%, transparent 55%),
    linear-gradient(0deg, rgba(255, 255, 255, 0.18), transparent 16%);
  pointer-events: none;
}

.command-grid {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.command-card {
  min-height: 164px;
  display: grid;
  gap: 10px;
  padding: 16px;
  border-radius: 20px;
  background:
    linear-gradient(135deg, rgba(13, 31, 48, 0.97) 0%, rgba(24, 62, 99, 0.94) 56%, rgba(195, 95, 47, 0.18) 100%);
  border: 1px solid rgba(13, 31, 48, 0.16);
  color: #f4f7fb;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.75);
}

.command-card h3 {
  margin: 4px 0 0;
  font-size: 1.1rem;
  letter-spacing: -0.04em;
  color: #fff;
}

.command-list {
  display: grid;
  gap: 8px;
}

.command-item {
  display: grid;
  gap: 4px;
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.16);
}

.command-item strong {
  font-size: 0.98rem;
  color: #fff;
}

.command-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.dashboard-today-hero {
  display: grid;
  gap: 8px;
}

.dashboard-today-hero .big {
  margin: 4px 0 0;
  font-size: 2.2rem;
}

.office-screens {
  margin-bottom: 16px;
  background:
    radial-gradient(circle at top right, rgba(195, 95, 47, 0.18), transparent 28%),
    radial-gradient(circle at bottom left, rgba(24, 62, 99, 0.18), transparent 24%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(240, 244, 248, 0.94));
  border: 1px solid rgba(13, 31, 48, 0.1);
}

.office-screens-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.office-screen-card {
  border-radius: 20px;
  border: 1px solid rgba(13, 31, 48, 0.1);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(242, 246, 250, 0.95));
  padding: 16px;
  display: grid;
  gap: 10px;
  min-height: 186px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.office-screen-card.wall {
  border-color: rgba(24, 62, 99, 0.24);
  background:
    linear-gradient(180deg, rgba(13, 31, 48, 0.96), rgba(24, 62, 99, 0.9));
  color: #f6f8fb;
}

.office-screen-card.desk {
  border-color: rgba(195, 95, 47, 0.26);
  background:
    linear-gradient(180deg, rgba(255, 250, 245, 0.98), rgba(246, 236, 229, 0.95));
}

.office-screen-head {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: center;
}

.office-screen-card h3 {
  margin: 0;
  font-size: 1.05rem;
  letter-spacing: -0.03em;
}

.office-screen-card.wall h3 {
  color: #fff;
}

.office-screen-card.wall .label,
.office-screen-card.wall .muted,
.office-screen-card.wall .pill {
  color: rgba(255, 255, 255, 0.92);
}

.office-screen-card.wall .pill {
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.16);
}

.office-screen-lines {
  display: grid;
  gap: 8px;
}

.office-screen-lines-scroll {
  max-height: 360px;
  overflow: auto;
  padding-right: 2px;
}

.office-screen-line {
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(13, 31, 48, 0.06);
  border: 1px solid rgba(13, 31, 48, 0.08);
  display: grid;
  gap: 4px;
}

.office-screen-card.wall .office-screen-line {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.14);
}

.office-screen-line-button {
  width: 100%;
  text-align: left;
  cursor: pointer;
  transition: transform 0.16s ease, border-color 0.16s ease, background 0.16s ease;
}

.office-screen-line-button:hover,
.office-screen-line-button:focus-visible,
.office-screen-line-button.active {
  transform: translateY(-1px);
  border-color: rgba(195, 95, 47, 0.34);
  background: rgba(195, 95, 47, 0.1);
  outline: none;
}

.office-screen-card.wall .office-screen-line-button.active {
  background: rgba(255, 255, 255, 0.16);
  border-color: rgba(255, 255, 255, 0.26);
}

.internal-notes-layout {
  display: grid;
  gap: 14px;
  grid-template-columns: minmax(280px, 360px) minmax(0, 1fr);
}

.internal-notes-form,
.internal-notes-group,
.internal-note-card {
  border-radius: 18px;
  border: 1px solid rgba(22, 33, 42, 0.08);
  background: rgba(255, 255, 255, 0.92);
}

.internal-notes-form {
  padding: 16px;
}

.internal-notes-form textarea {
  min-height: 108px;
  resize: vertical;
}

.internal-notes-list {
  display: grid;
  gap: 12px;
}

.internal-notes-group {
  padding: 14px;
  display: grid;
  gap: 12px;
}

.internal-notes-group-head,
.internal-note-top,
.internal-note-meta {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
}

.internal-notes-items {
  display: grid;
  gap: 10px;
}

.internal-note-card {
  padding: 14px;
  display: grid;
  gap: 10px;
  background:
    radial-gradient(circle at top right, rgba(22, 108, 119, 0.08), transparent 28%),
    rgba(255, 255, 255, 0.96);
}

.internal-note-card h3 {
  margin: 4px 0 0;
  font-size: 1rem;
}

.internal-note-card p {
  margin: 0;
  color: var(--text);
  line-height: 1.5;
}

.week-list,
.action-stack,
.invoice-list,
.bank-list,
.checklist,
.agenda-list,
.project-list,
.todo-list,
.todo-summary {
  display: grid;
  gap: 10px;
}

.checklist.compact {
  gap: 8px;
}

.checklist.compact .check-item {
  padding: 11px 12px;
  background: rgba(255, 255, 255, 0.92);
}

.notification-list {
  display: grid;
  gap: 10px;
}

.finance-summary {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.finance-summary-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.finance-summary-card {
  display: grid;
  gap: 8px;
  padding: 14px 15px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.95);
  box-shadow: 0 12px 28px rgba(16, 24, 40, 0.08);
}

.finance-summary-card strong {
  font-size: 1.7rem;
  letter-spacing: -0.04em;
}

.finance-summary-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.spacer {
  height: 14px;
}

.list-title {
  font-size: 0.9rem;
  font-weight: 700;
  margin-bottom: 10px;
  color: var(--muted);
}

.week-row,
.action,
.invoice-row,
.bank-row,
.check-item,
.agenda-row,
.notification-row,
.board,
.project-row,
.relation-card,
.todo-row,
.todo-summary-row {
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 14px 15px;
}

.agenda-row,
.calendar-item {
  appearance: none;
  text-align: left;
  width: 100%;
  cursor: pointer;
}

.week-row,
.invoice-row,
.bank-row {
  display: grid;
  gap: 5px;
}

.agenda-row {
  display: grid;
  gap: 6px;
}

.agenda-row.active,
.calendar-item.active {
  border-color: rgba(17, 108, 119, 0.28);
  box-shadow: 0 14px 28px rgba(17, 108, 119, 0.12);
  background: linear-gradient(180deg, rgba(17, 108, 119, 0.09), rgba(255, 255, 255, 0.98));
}

.agenda-row.danger {
  border-left: 4px solid #d03f3f;
}

.agenda-top {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.agenda-meta {
  display: grid;
  gap: 4px;
}

.agenda-side {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(540px, 44vw);
  display: grid;
  gap: 14px;
  padding: 20px;
  overflow: auto;
  transform: translateX(106%);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition:
    transform 260ms ease,
    opacity 220ms ease,
    visibility 0s linear 260ms;
  z-index: 10;
  box-shadow: -26px 0 64px rgba(0, 0, 0, 0.22);
  backdrop-filter: blur(18px);
}

.agenda-side.is-open {
  transform: translateX(0);
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transition:
    transform 260ms ease,
    opacity 220ms ease,
    visibility 0s;
}

.agenda-detail {
  display: grid;
  gap: 12px;
}

.agenda-detail-card {
  display: grid;
  gap: 14px;
  padding: 18px;
  border-radius: 22px;
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(246, 242, 236, 0.96));
  box-shadow: 0 16px 34px rgba(16, 24, 40, 0.08);
}

.agenda-detail-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.agenda-detail-head h3 {
  margin: 4px 0 4px;
  font-size: 1.25rem;
  letter-spacing: -0.03em;
}

.agenda-detail-grid,
.agenda-detail-finance {
  display: grid;
  gap: 10px;
}

.agenda-detail-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.agenda-detail-block {
  display: grid;
  gap: 5px;
  padding: 12px 13px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid var(--line);
}

.agenda-detail-note {
  background: rgba(17, 108, 119, 0.06);
}

.agenda-detail-job-notes {
  display: grid;
  gap: 10px;
}

.project-note-form {
  display: grid;
  gap: 10px;
}

.project-note-form .mini-grid {
  display: grid;
  gap: 10px;
}

.project-note-form input,
.project-note-form textarea {
  width: 100%;
}

.project-note-list {
  display: grid;
  gap: 10px;
}

.project-note-card {
  display: grid;
  gap: 8px;
  padding: 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(18, 33, 52, 0.08);
  box-shadow: 0 8px 22px rgba(18, 33, 52, 0.06);
}

.project-note-card.compact {
  padding: 12px;
}

.project-note-card p {
  margin: 0;
  color: var(--text);
  line-height: 1.45;
}

.crew-notes-focus {
  grid-column: 1 / -1;
}

.agenda-detail-finance {
  padding-top: 4px;
}

.agenda-detail-finance.locked {
  padding: 14px;
  border-radius: 16px;
  background: rgba(17, 33, 48, 0.06);
  border: 1px dashed rgba(17, 33, 48, 0.12);
}

.agenda-detail-ops {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.agenda-detail-ops-block {
  display: grid;
  gap: 8px;
  padding: 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid var(--line);
}

.agenda-detail-ops-block .chip-row {
  gap: 6px;
}

.internal-note-card .chip-row {
  margin-top: 6px;
}

.notification-row {
  display: grid;
  gap: 6px;
  border-left: 4px solid transparent;
}

.notification-row.ok {
  border-left-color: var(--accent);
}

.notification-row.warn {
  border-left-color: #d07e2d;
}

.invoice-row button {
  justify-self: start;
}

.invoice-card {
  border: 1px solid rgba(18, 33, 52, 0.08);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.98) 0%, rgba(245, 242, 236, 0.95) 100%);
  box-shadow: 0 14px 34px rgba(18, 33, 52, 0.08);
  border-radius: 22px;
  padding: 18px;
  display: grid;
  gap: 14px;
}

.invoice-card-incoming {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.98) 0%, rgba(240, 245, 249, 0.95) 100%);
}

.invoice-card-top {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
}

.invoice-card-top strong {
  display: block;
  margin-top: 6px;
  font-size: 1.25rem;
  letter-spacing: -0.03em;
}

.invoice-card-amount {
  font-size: 1.7rem;
  font-weight: 800;
  letter-spacing: -0.04em;
  color: var(--nav);
  white-space: nowrap;
}

.invoice-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 10px;
}

.invoice-card-field {
  display: grid;
  gap: 6px;
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid var(--line);
}

.invoice-card-field strong {
  font-size: 1rem;
}

.invoice-card-summary {
  display: grid;
  gap: 6px;
  padding-top: 2px;
}

.finance-breakdown {
  display: grid;
  gap: 12px;
}

.finance-breakdown-card {
  display: grid;
  gap: 12px;
  padding: 16px;
  border-radius: 20px;
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(246, 242, 236, 0.96));
  box-shadow: 0 14px 28px rgba(16, 24, 40, 0.08);
}

.finance-breakdown-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.finance-breakdown-head h3 {
  margin: 4px 0 0;
  font-size: 1.12rem;
  letter-spacing: -0.03em;
}

.finance-breakdown-grid {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.finance-breakdown-item {
  display: grid;
  gap: 6px;
  padding: 12px 13px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid var(--line);
}

.finance-breakdown-item strong {
  font-size: 1.2rem;
  letter-spacing: -0.03em;
}

.finance-breakdown-note {
  padding-top: 4px;
}

.finance-breakdown-list {
  display: grid;
  gap: 10px;
}

.finance-breakdown-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  padding: 12px 13px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid var(--line);
}

.finance-breakdown-row strong {
  display: block;
}

.finance-breakdown-values {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.mail-attachments-block {
  display: grid;
  gap: 8px;
}

.mail-attachments {
  display: grid;
  gap: 10px;
}

.mail-attachment {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.84);
  border-radius: 14px;
  padding: 10px 12px;
}

.row-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 2px;
}

.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  border-radius: 999px;
  padding: 6px 10px;
  font-size: 0.82rem;
  background: rgba(22, 33, 42, 0.06);
}

.pill.ok {
  background: var(--accent-soft);
  color: var(--accent);
}

.pill.warn {
  background: rgba(208, 126, 45, 0.12);
  color: #b86916;
}

.board-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 14px;
}

.panel {
  overflow: hidden;
}

.board {
  min-height: 104px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.project-row {
  display: grid;
  gap: 10px;
}

.job-list {
  display: grid;
  gap: 12px;
}

.job-day-group {
  display: grid;
  gap: 12px;
  padding: 16px;
  border-radius: 20px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.03)),
    rgba(8, 15, 24, 0.86);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.job-day-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}

.job-day-head h3 {
  margin: 4px 0 0;
  font-size: 1.12rem;
}

.job-day-list {
  display: grid;
  gap: 12px;
}

.job-card {
  display: grid;
  gap: 14px;
  padding: 16px;
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0.03)),
    rgba(9, 17, 26, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.22);
  overflow: hidden;
}

.job-workflow-panel {
  display: grid;
  gap: 12px;
  padding: 14px;
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.03)),
    rgba(9, 17, 26, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.job-workflow-line {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 8px;
}

.job-workflow-step {
  display: grid;
  justify-items: center;
  gap: 8px;
  text-align: center;
  color: rgba(233, 241, 251, 0.72);
}

.job-workflow-dot {
  width: 12px;
  height: 12px;
  border-radius: 999px;
  background: rgba(233, 241, 251, 0.18);
  box-shadow: 0 0 0 4px rgba(233, 241, 251, 0.06);
}

.job-workflow-step.done {
  color: rgba(255, 255, 255, 0.94);
}

.job-workflow-step.done .job-workflow-dot {
  background: var(--accent);
  box-shadow: 0 0 0 4px rgba(22, 108, 119, 0.14);
}

.job-workflow-step.active {
  color: #bffcf5;
  font-weight: 700;
}

.job-workflow-step.active .job-workflow-dot {
  background: var(--accent-2);
  box-shadow: 0 0 0 4px rgba(195, 95, 47, 0.18);
}

.job-workflow-step.todo {
  opacity: 0.9;
}

.job-workflow-label {
  font-size: 0.82rem;
  letter-spacing: -0.01em;
}

.job-workflow-copy {
  display: grid;
  gap: 4px;
}

.job-card .label,
.job-card .muted,
.job-card .job-workflow-label {
  color: rgba(233, 241, 251, 0.72);
}

.job-card .job-workflow-copy strong,
.job-card .job-panel-head strong,
.job-card .job-meta strong,
.job-card .job-summary-grid .job-meta strong {
  color: rgba(255, 255, 255, 0.96);
}

.job-section-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.job-panel {
  display: grid;
  gap: 10px;
  padding: 14px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.03)),
    rgba(9, 17, 26, 0.88);
}

.job-panel.locked {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.025)),
    rgba(9, 17, 26, 0.82);
}

.job-panel.ready {
  border-color: rgba(84, 215, 202, 0.18);
}

.job-panel-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: flex-start;
}

.job-panel-head strong {
  display: block;
  margin-top: 4px;
  font-size: 1rem;
  letter-spacing: -0.01em;
}

.job-section-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.job-awaiting-approval {
  display: grid;
  gap: 6px;
  padding: 12px;
  border-radius: 16px;
  background: rgba(195, 95, 47, 0.14);
  border: 1px solid rgba(195, 95, 47, 0.18);
}

.job-summary-grid {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
}

.hours-week-flow,
.finance-hours-flow {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.hours-layout .hours-week-flow {
  grid-template-columns: 1fr;
}

.hours-status-stack {
  display: grid;
  gap: 12px;
}

.hours-status-card {
  display: grid;
  gap: 12px;
  padding: 14px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.05);
}

.hours-status-card > summary {
  list-style: none;
  cursor: pointer;
}

.hours-status-card > summary::-webkit-details-marker {
  display: none;
}

.hours-status-body {
  display: grid;
  gap: 12px;
}

.hours-status-card.warn {
  background:
    linear-gradient(180deg, rgba(208, 126, 45, 0.08), rgba(255, 255, 255, 0.05)),
    rgba(255, 255, 255, 0.05);
}

.hours-status-card.accent-warm {
  background:
    linear-gradient(180deg, rgba(195, 95, 47, 0.08), rgba(255, 255, 255, 0.05)),
    rgba(255, 255, 255, 0.05);
}

.hours-status-card.ok {
  background:
    linear-gradient(180deg, rgba(84, 215, 202, 0.08), rgba(255, 255, 255, 0.05)),
    rgba(255, 255, 255, 0.05);
}

.hours-status-head {
  display: flex;
  gap: 12px;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
}

.hours-status-head strong {
  display: block;
  font-size: 1.4rem;
  letter-spacing: -0.04em;
  margin-top: 4px;
}

.hours-status-list {
  display: grid;
  gap: 8px;
}

.hours-status-row {
  width: 100%;
  text-align: left;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 8px 10px;
  background: rgba(255, 255, 255, 0.05);
  display: grid;
  gap: 4px;
  cursor: default;
  color: var(--text);
  appearance: none;
  -webkit-appearance: none;
  font: inherit;
}

.hours-status-row:hover {
  border-color: rgba(84, 215, 202, 0.22);
  background: rgba(255, 255, 255, 0.08);
}

.hours-week-card {
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
  overflow: clip;
}

.hours-week-card > summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  justify-content: flex-start;
  gap: 12px;
  align-items: flex-start;
  padding: 10px 12px;
}

.hours-week-card > summary::-webkit-details-marker {
  display: none;
}

.hours-week-card[open] > summary {
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.hours-week-card-summary-main {
  display: grid;
  gap: 3px;
}

.hours-week-card-summary strong {
  display: block;
  font-size: 0.98rem;
}

.hours-status-row-top {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: flex-start;
  flex-wrap: wrap;
}

.hours-status-row strong {
  font-size: 0.95rem;
}

.hours-status-row .muted {
  font-size: 0.82rem;
}

.hours-status-row-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 4px;
}

.hours-open-worker-grid {
  display: grid;
  gap: 10px;
}

.hours-open-worker-card {
  width: 100%;
  text-align: left;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  padding: 12px 14px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.04));
  display: grid;
  gap: 10px;
  cursor: pointer;
  color: var(--text);
  appearance: none;
  -webkit-appearance: none;
  font: inherit;
}

.hours-entry-card.is-missing,
.worker-day-row.is-missing {
  border-color: rgba(208, 126, 45, 0.38);
  background:
    linear-gradient(180deg, rgba(208, 126, 45, 0.14), rgba(255, 255, 255, 0.05)),
    rgba(255, 255, 255, 0.06);
}

.hours-entry-card.is-missing .pill.warn,
.worker-day-row.is-missing .pill.warn {
  background: rgba(208, 126, 45, 0.18);
  color: #ffd9b0;
}

.hours-open-worker-card:hover {
  border-color: rgba(84, 215, 202, 0.22);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.05));
}

.hours-open-worker-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
  flex-wrap: wrap;
}

.hours-open-worker-head strong {
  display: block;
  margin-top: 3px;
  font-size: 1rem;
  letter-spacing: -0.03em;
}

.hours-open-worker-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.hours-open-worker-meta .muted {
  font-size: 0.82rem;
}

.hours-worker-section {
  display: grid;
  gap: 0;
}

.hours-worker-summary {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
  cursor: pointer;
}

.hours-worker-summary::-webkit-details-marker {
  display: none;
}

.section-focus {
  outline: 2px solid rgba(84, 215, 202, 0.4);
  outline-offset: 3px;
  border-radius: 20px;
}

.hours-week-flow .finance-ledger-card strong,
.finance-hours-flow .finance-ledger-card strong {
  font-size: 1.05rem;
}

.job-flow {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

#view-jobs .invoice-section {
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 22px;
  background: rgba(8, 15, 24, 0.82);
  overflow: hidden;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.24);
}

#view-jobs .invoice-section[open] {
  border-color: rgba(84, 215, 202, 0.2);
}

#view-jobs .invoice-section-summary {
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 20px;
  cursor: pointer;
  user-select: none;
}

#view-jobs .invoice-section-summary::-webkit-details-marker {
  display: none;
}

#view-jobs .invoice-section-summary h2 {
  margin: 4px 0 0;
}

#view-jobs .invoice-section-body {
  padding: 0 18px 18px;
}

.job-card.completed {
  border-style: dashed;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.025)),
    rgba(8, 15, 24, 0.86);
}

.job-card-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.job-card-head strong {
  display: block;
  margin-top: 4px;
  font-size: 1.05rem;
}

.job-card-facts {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
}

.crew-card {
  display: grid;
  gap: 10px;
  padding: 15px;
  border-radius: 18px;
  background: linear-gradient(180deg, #ffffff 0%, #f7fafc 100%);
  border: 1px solid var(--line);
}

.crew-card-loods {
  background:
    linear-gradient(180deg, rgba(13, 31, 48, 0.08), rgba(255, 255, 255, 0.98));
  border-color: rgba(13, 31, 48, 0.14);
}

.crew-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.crew-load-grid {
  display: grid;
  gap: 8px;
}

.crew-load-card {
  display: grid;
  gap: 4px;
  padding: 10px 12px;
  border-radius: 14px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(247, 241, 235, 0.96));
  border: 1px solid rgba(195, 95, 47, 0.16);
}

.job-meta-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 10px;
}

.job-meta {
  display: grid;
  gap: 6px;
  padding: 11px 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.06);
}

.job-meta select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px 12px;
  background: #fff;
  color: var(--text);
}

.job-estimate-row {
  display: flex;
  gap: 8px;
  align-items: center;
}

.job-estimate-input {
  flex: 1;
  min-width: 110px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 10px 12px;
  background: rgba(255, 255, 255, 0.06);
  color: rgba(255, 255, 255, 0.96);
}

.job-estimate-input::placeholder {
  color: rgba(233, 241, 251, 0.52);
}

.crew-quick-pick {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 4px;
}

.crew-quick-pick.compact {
  gap: 8px;
  margin: 4px 0 2px;
}

.crew-pick {
  appearance: none;
  border: 1px solid rgba(12, 20, 32, 0.18);
  background: rgba(255, 255, 255, 0.94);
  color: var(--text);
  border-radius: 999px;
  padding: 9px 14px;
  font-size: 0.84rem;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.16s ease, background 0.16s ease, border-color 0.16s ease, color 0.16s ease;
  min-height: 38px;
}

.crew-pick:hover {
  transform: translateY(-1px);
  border-color: rgba(195, 95, 47, 0.38);
}

.crew-pick.active {
  background: linear-gradient(135deg, rgba(195, 95, 47, 0.2), rgba(12, 20, 32, 0.06));
  border-color: rgba(195, 95, 47, 0.55);
  color: var(--text);
  box-shadow: 0 10px 24px rgba(195, 95, 47, 0.12);
}

.crew-pick:disabled {
  cursor: not-allowed;
  opacity: 0.45;
  transform: none;
  box-shadow: none;
}

.crew-select-fallback {
  width: 100%;
}

.job-actions {
  align-items: center;
}

.job-upload {
  position: relative;
  overflow: hidden;
}

.job-upload input[type="file"] {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.job-photo-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.job-photo-thumb {
  width: 96px;
  height: 72px;
  object-fit: cover;
  border-radius: 12px;
  border: 1px solid var(--line);
  box-shadow: 0 8px 16px rgba(22, 32, 46, 0.08);
}

.project-row .chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}

.project-row .meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  justify-content: space-between;
}

.table-shell {
  overflow: visible;
}

.panel-subhead {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  margin-bottom: 16px;
}

.relation-table {
  display: grid;
  gap: 12px;
}

.relation-card {
  display: grid;
  gap: 14px;
  padding: 16px;
  border-radius: 18px;
  background: linear-gradient(180deg, #ffffff 0%, #f7fafc 100%);
  box-shadow: 0 10px 22px rgba(22, 32, 46, 0.05);
}

.relation-card-head {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: flex-start;
}

.relation-card-head strong {
  display: block;
  font-size: 1.05rem;
}

.relation-meta-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 10px;
}

.relation-field {
  padding: 11px 13px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid var(--line);
}

.relation-field strong {
  display: block;
  margin-top: 6px;
  font-size: 0.97rem;
  line-height: 1.4;
  word-break: break-word;
}

.relation-projects {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.relation-template-line {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
}

.template-list {
  display: grid;
  gap: 10px;
}

.template-card {
  display: grid;
  gap: 12px;
  padding: 15px;
  border-radius: 16px;
  background: #ffffff;
  border: 1px solid var(--line);
}

.template-card-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.template-card-head strong,
.template-preview-head strong {
  display: block;
  font-size: 1rem;
}

.template-preview {
  display: grid;
  gap: 10px;
  padding: 13px;
  border-radius: 14px;
  background: linear-gradient(180deg, rgba(43, 108, 176, 0.08), rgba(43, 108, 176, 0.03));
  border: 1px solid rgba(43, 108, 176, 0.12);
}

.template-preview-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.template-preview-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 8px;
}

.template-preview-grid strong {
  display: block;
  margin-top: 6px;
}

.panel-head.compact {
  margin-top: 6px;
}

.todo-row {
  display: grid;
  gap: 7px;
}

.todo-row.done {
  opacity: 0.68;
}

.todo-row .topline,
.todo-summary-row .topline {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: flex-start;
}

.todo-summary-row {
  background: var(--accent-soft);
  border-color: transparent;
}

.todo-form {
  margin-top: 10px;
}

.relation-form {
  margin-top: 10px;
}

.relation-form input {
  min-width: 0;
}

.mobile-mock {
  background: linear-gradient(180deg, #ffffff, #f7fafc);
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 16px;
  max-width: 420px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.mobile-launchpad {
  display: none;
}

.mobile-launchpad-copy {
  display: grid;
  gap: 6px;
}

.mobile-launchpad-copy h2 {
  margin: 0;
  font-size: clamp(1.3rem, 4vw, 1.9rem);
  letter-spacing: -0.05em;
}

.mobile-launchpad-stats {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
}

.mobile-launchpad-stat {
  border-radius: 18px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.82);
  padding: 14px;
  display: grid;
  gap: 6px;
  min-height: 92px;
}

.mobile-launchpad-stat strong {
  font-size: 1.1rem;
  letter-spacing: -0.03em;
}

.mobile-bottom-nav {
  display: none;
}

.mobile-bottom-nav-item {
  border: 1px solid transparent;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.84);
  padding: 10px 12px;
  cursor: pointer;
}

.mobile-bottom-nav-item.active {
  background: rgba(255, 255, 255, 0.16);
  border-color: rgba(255, 255, 255, 0.14);
  color: #fff;
}

.automation-actions {
  display: grid;
  gap: 8px;
  margin-top: 14px;
}

.automation-actions .primary,
.automation-actions .ghost {
  text-align: center;
}

.dashboard-notifications {
  margin-top: 16px;
}

.overview-card {
  border-left: 4px solid var(--accent);
}

.automation-actions .ghost,
.automation-actions .primary {
  width: 100%;
}

.todo-summary .pill {
  margin-right: 6px;
}

.invoice-stack {
  display: grid;
  gap: 16px;
}

.invoice-actions-bar {
  display: flex;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 14px;
}

.invoice-actions-bar button {
  min-width: 260px;
}

.hours-layout {
  display: grid;
  gap: 16px;
  grid-template-columns: minmax(0, 1fr);
}

.hours-layout > .card {
  min-width: 0;
}

.hours-layout .worker-grid {
  grid-template-columns: 1fr;
  align-content: start;
}

.hours-layout .hours-summary-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.hours-summary-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.hours-summary-card {
  border-radius: 20px;
  padding: 16px;
  display: grid;
  gap: 8px;
  min-height: 128px;
  border: 1px solid rgba(13, 31, 48, 0.12);
  background:
    linear-gradient(180deg, rgba(13, 31, 48, 0.06), rgba(255, 255, 255, 0.94));
  box-shadow: 0 16px 28px rgba(16, 24, 40, 0.06);
}

.hours-summary-card strong {
  font-size: clamp(1.8rem, 4vw, 2.4rem);
  letter-spacing: -0.06em;
  line-height: 1;
}

.hours-summary-card .label {
  font-size: 0.7rem;
}

.hours-summary-card .muted {
  color: var(--text-dim);
}

.hours-layout .hours-summary-card {
  min-height: auto;
  padding: 10px 12px;
  text-align: left;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  font: inherit;
  gap: 4px;
}

.hours-layout .hours-summary-card strong {
  font-size: clamp(1.1rem, 3vw, 1.45rem);
}

.hours-layout .hours-summary-card .pill {
  justify-self: start;
}

.hours-summary-card.accent-dark {
  background:
    linear-gradient(180deg, rgba(13, 31, 48, 0.96), rgba(31, 107, 115, 0.92));
  color: #fff;
  border-color: rgba(255, 255, 255, 0.08);
}

.hours-summary-card.accent-dark .label,
.hours-summary-card.accent-dark .muted {
  color: rgba(235, 243, 252, 0.76) !important;
}

.hours-summary-card.accent-warm {
  background:
    linear-gradient(180deg, rgba(194, 118, 36, 0.12), rgba(255, 255, 255, 0.96));
}

.hours-summary-card.accent-emerald {
  background:
    linear-gradient(180deg, rgba(31, 107, 115, 0.12), rgba(255, 255, 255, 0.96));
}

.hours-summary-card.accent-gold {
  background:
    linear-gradient(180deg, rgba(232, 174, 86, 0.16), rgba(255, 255, 255, 0.96));
}

.workspace-mobile-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.workspace-home-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.workspace-home-card {
  border: 1px solid rgba(13, 31, 48, 0.12);
  border-radius: 18px;
  padding: 14px;
  text-align: left;
  background:
    linear-gradient(180deg, rgba(13, 31, 48, 0.06), rgba(255, 255, 255, 0.96));
  display: grid;
  gap: 6px;
  min-height: 112px;
  cursor: pointer;
  color: inherit;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.workspace-home-card:hover {
  transform: translateY(-1px);
  box-shadow: 0 18px 32px rgba(16, 24, 40, 0.08);
  border-color: rgba(13, 31, 48, 0.2);
}

.workspace-home-card.primary-card {
  background:
    linear-gradient(180deg, rgba(13, 31, 48, 0.92), rgba(48, 99, 175, 0.88));
  color: #fff;
  border-color: rgba(255, 255, 255, 0.12);
}

.workspace-home-card.primary-card .label,
.workspace-home-card.primary-card .muted {
  color: rgba(233, 241, 251, 0.76) !important;
}

.workspace-home-card strong {
  font-size: clamp(1.4rem, 4vw, 2rem);
  letter-spacing: -0.05em;
}

.worker-agenda-section {
  display: grid;
  gap: 12px;
  margin-top: 6px;
}

.worker-agenda-head {
  align-items: center;
}

.worker-agenda-list {
  display: grid;
  gap: 10px;
}

.worker-agenda-card {
  border: 1px solid rgba(13, 31, 48, 0.12);
  border-radius: 20px;
  background:
    linear-gradient(180deg, rgba(13, 31, 48, 0.06), rgba(255, 255, 255, 0.96));
  padding: 14px;
  display: grid;
  gap: 10px;
  text-align: left;
  cursor: pointer;
  color: inherit;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.worker-agenda-card:hover {
  transform: translateY(-1px);
  box-shadow: 0 18px 32px rgba(16, 24, 40, 0.08);
  border-color: rgba(13, 31, 48, 0.2);
}

.worker-agenda-card-top,
.worker-agenda-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: space-between;
  align-items: flex-start;
}

.worker-agenda-card-top strong {
  display: block;
  font-size: 1.05rem;
  letter-spacing: -0.03em;
  margin: 3px 0;
}

.hours-attention-row {
  width: 100%;
  text-align: left;
  border: 1px solid rgba(13, 31, 48, 0.12);
  border-radius: 18px;
  padding: 14px 14px 12px;
  background:
    linear-gradient(180deg, rgba(13, 31, 48, 0.04), rgba(255, 255, 255, 0.95));
  display: grid;
  gap: 8px;
  cursor: pointer;
  box-shadow: 0 12px 22px rgba(16, 24, 40, 0.06);
}

.hours-attention-row:hover {
  border-color: rgba(13, 31, 48, 0.24);
  transform: translateY(-1px);
  box-shadow: 0 14px 28px rgba(16, 24, 40, 0.08);
}

.worker-card-hours {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(245, 242, 236, 0.98));
  border-color: rgba(13, 31, 48, 0.1);
  padding: 16px 16px 16px 20px;
}

.worker-card-hours .worker-card-meta {
  gap: 8px 10px;
}

.worker-card-hours .worker-card-head strong {
  font-size: 1.08rem;
}

.worker-grid {
  display: grid;
  gap: 12px;
}

.worker-card {
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(248, 244, 237, 0.98));
  border: 1px solid rgba(13, 31, 48, 0.08);
  border-radius: 22px;
  padding: 18px 18px 18px 22px;
  display: grid;
  gap: 12px;
  box-shadow: 0 18px 34px rgba(16, 24, 40, 0.08);
}

.worker-card-manager {
  box-shadow: 0 18px 34px rgba(16, 24, 40, 0.08);
}

.worker-card-personal {
  border-color: rgba(31, 107, 115, 0.2);
  box-shadow: 0 24px 48px rgba(16, 24, 40, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.7);
}

.worker-card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 5px;
  background: linear-gradient(180deg, rgba(31, 107, 115, 0.82), rgba(194, 118, 36, 0.84));
}

.worker-card-personal::before {
  background: linear-gradient(180deg, rgba(31, 107, 115, 0.92), rgba(109, 166, 168, 0.82));
}

.worker-card-manager::before {
  background: linear-gradient(180deg, rgba(194, 118, 36, 0.92), rgba(31, 107, 115, 0.76));
}

.workspace-focus-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.workspace-focus-item {
  border: 1px solid rgba(13, 31, 48, 0.12);
  border-radius: 16px;
  background:
    linear-gradient(180deg, rgba(13, 31, 48, 0.08), rgba(255, 255, 255, 0.9));
  padding: 14px;
  display: grid;
  gap: 6px;
}

.workspace-registry {
  grid-column: 1 / -1;
}

.workspace-registry-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 12px;
}

.workspace-registry-card {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.86);
  padding: 14px;
  display: grid;
  gap: 10px;
}

.workspace-registry-head,
.workspace-registry-meta {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: flex-start;
  flex-wrap: wrap;
}

.worker-card-head,
.worker-card-meta {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: flex-start;
  flex-wrap: wrap;
}

.worker-card-note {
  margin-top: -2px;
}

.worker-card-meta .pill {
  margin-bottom: 4px;
}

.worker-week-details {
  border: 1px solid rgba(13, 31, 48, 0.12);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.55);
  overflow: clip;
}

.worker-week-details > summary {
  list-style: none;
  cursor: pointer;
  padding: 14px 16px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.worker-week-details > summary::-webkit-details-marker {
  display: none;
}

.worker-week-details[open] > summary {
  border-bottom: 1px solid rgba(13, 31, 48, 0.08);
}

.worker-week-details > summary strong,
.worker-week-details > summary .muted {
  display: block;
}

.worker-card .worker-language-select {
  padding: 12px;
}

.hours-worker-detail .agenda-detail-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.hours-worker-detail .checklist {
  gap: 10px;
}

.hours-today-drawer {
  position: fixed;
  inset: 24px 24px 24px auto;
  width: min(calc(100vw - 48px), 700px);
  height: min(calc(100vh - 48px), 860px);
  margin: 0;
  padding: 20px;
  border: 1px solid rgba(18, 33, 52, 0.12);
  border-radius: 28px;
  box-shadow: 0 28px 70px rgba(16, 24, 40, 0.28);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.995), rgba(246, 249, 252, 0.99));
  transform: translateX(120%) scale(0.98);
  transition: transform 240ms ease;
  overflow-y: auto;
  visibility: hidden;
  pointer-events: none;
  backdrop-filter: blur(12px);
}

.hours-today-drawer[open] {
  transform: translateX(0) scale(1);
  visibility: visible;
  pointer-events: auto;
}

.hours-today-drawer::backdrop {
  background: rgba(15, 23, 32, 0.38);
  backdrop-filter: blur(2px);
}

.hours-today-drawer .agenda-detail-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.hours-today-drawer .worker-day-list {
  max-height: min(42vh, 420px);
  overflow: auto;
  padding-right: 2px;
}

.hours-today-drawer .worker-day-row {
  background: rgba(13, 31, 48, 0.04);
}

.hours-today-drawer .row-actions .primary {
  min-height: 48px;
}

.worker-day-list {
  display: grid;
  gap: 10px;
}

.worker-day-row {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.8);
  border-radius: 14px;
  padding: 12px;
  display: grid;
  gap: 10px;
}

.agenda-calendar {
  display: grid;
  gap: 12px;
}

.calendar-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: flex-start;
}

.calendar-head > div:first-child {
  display: grid;
  gap: 4px;
}

.calendar-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 10px;
}

.calendar-weekdays span {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  padding-left: 4px;
}

.calendar-cell {
  min-height: 110px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.9);
  padding: 10px;
  display: grid;
  gap: 8px;
}

.calendar-cell.empty {
  background: transparent;
  border-style: dashed;
}

.calendar-cell.today {
  border-color: rgba(22, 108, 119, 0.38);
  box-shadow: 0 16px 28px rgba(22, 108, 119, 0.12);
  background: linear-gradient(180deg, rgba(22, 108, 119, 0.14), rgba(255, 255, 255, 0.96));
}

.calendar-cell.focused {
  border-color: rgba(84, 215, 202, 0.38);
  box-shadow: 0 18px 34px rgba(84, 215, 202, 0.16);
}

.calendar-day {
  font-weight: 700;
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: center;
}

.today-pill {
  font-size: 0.66rem;
  padding: 3px 8px;
}

.calendar-items {
  display: grid;
  gap: 6px;
}

.calendar-item {
  display: block;
  padding: 6px 8px;
  border-radius: 10px;
  background: var(--accent-soft);
  color: var(--text);
  font-size: 0.82rem;
  border: 1px solid transparent;
  text-align: left;
}

.calendar-item .muted {
  display: block;
  margin-top: 2px;
  font-size: 0.72rem;
  line-height: 1.35;
}

.calendar-item.danger {
  background: rgba(208, 63, 63, 0.16);
  color: #9f1f1f;
}

.calendar-item.active {
  border-color: rgba(17, 108, 119, 0.28);
}

.mail-ribbon {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: center;
  margin-bottom: 16px;
  padding: 14px 18px;
  border-radius: 24px;
  border: 1px solid rgba(18, 33, 52, 0.08);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(242, 247, 251, 0.96));
  box-shadow: 0 16px 32px rgba(18, 33, 52, 0.06);
}

.mail-ribbon-tools {
  display: grid;
  gap: 12px;
  justify-items: end;
}

.mail-ribbon-actions {
  flex-wrap: wrap;
  justify-content: flex-end;
}

.mail-search {
  display: grid;
  gap: 6px;
  min-width: min(100%, 320px);
}

.mail-search input {
  width: 100%;
  border: 1px solid rgba(18, 33, 52, 0.12);
  border-radius: 16px;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.92);
  font: inherit;
  color: var(--text);
}

.mail-shell {
  position: relative;
  display: grid;
  grid-template-columns: 340px minmax(0, 1.02fr) minmax(460px, 0.98fr);
  gap: 0;
  align-items: stretch;
  border-radius: 30px;
  overflow: hidden;
  border: 1px solid rgba(18, 33, 52, 0.1);
  background: linear-gradient(180deg, rgba(246, 249, 252, 0.98), rgba(235, 242, 248, 0.98));
  box-shadow: 0 22px 46px rgba(18, 33, 52, 0.08);
  min-height: calc(100vh - 250px);
}

.mail-overview {
  display: grid;
  gap: 14px;
  margin-bottom: 16px;
  padding: 18px;
}

.mail-fallback {
  display: grid;
  gap: 14px;
  margin-bottom: 16px;
  padding: 18px;
  background: linear-gradient(180deg, rgba(255, 252, 246, 0.96), rgba(246, 249, 252, 0.96));
}

.mail-fallback-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
}

.mail-fallback-stat {
  display: grid;
  gap: 6px;
  padding: 14px;
  border-radius: 18px;
  border: 1px solid rgba(18, 33, 52, 0.08);
  background: rgba(255, 255, 255, 0.9);
}

.mail-fallback-stat strong {
  font-size: 1.4rem;
  letter-spacing: -0.03em;
}

.mail-fallback-list {
  display: grid;
  gap: 10px;
}

.mail-fallback-item {
  display: grid;
  gap: 4px;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(18, 33, 52, 0.08);
}

.mail-fallback-item strong {
  display: block;
}

.mail-overview-stats {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
}

.mail-overview-item {
  display: grid;
  gap: 6px;
  padding: 14px;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(43, 110, 118, 0.08), rgba(255, 255, 255, 0.94));
  border: 1px solid rgba(18, 33, 52, 0.08);
}

.mail-overview-item strong {
  font-size: 1.35rem;
  letter-spacing: -0.03em;
}

.mail-overview-item .muted {
  font-size: 0.85rem;
}

.mail-overview-list {
  display: grid;
  gap: 10px;
}

.mail-overview-message {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(18, 33, 52, 0.08);
}

.mail-overview-message strong {
  display: block;
}

.mail-overview-message .muted {
  font-size: 0.84rem;
}

.mail-sidebar,
.mail-center,
.mail-reader {
  min-height: calc(100vh - 250px);
  border: 0;
  box-shadow: none;
  border-radius: 0;
  background: transparent;
  position: relative;
  z-index: 1;
  pointer-events: auto;
}

.mail-sidebar {
  display: grid;
  gap: 12px;
  align-content: start;
  position: sticky;
  top: 20px;
  padding: 18px 12px;
  background:
    linear-gradient(180deg, rgba(20, 34, 49, 0.98), rgba(24, 42, 59, 0.98));
  color: var(--text);
  border-right: 1px solid rgba(255, 255, 255, 0.06);
}

.mail-sidebar .label,
.mail-sidebar .muted {
  color: rgba(255, 255, 255, 0.68);
}

.mail-sidebar .panel-head,
.mail-sidebar .panel-head h2 {
  color: #fff;
}

.sidebar-mail {
  display: grid;
  gap: 12px;
  padding: 12px;
  margin-top: 10px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar-mail-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.sidebar-mail-head strong {
  display: block;
  margin-top: 4px;
  font-size: 1rem;
  color: rgba(255, 255, 255, 0.96);
}

.sidebar-mail-tree {
  display: grid;
  gap: 10px;
}

.mail-sidebar-folders {
  display: grid;
  gap: 6px;
  padding: 10px 10px 12px;
  margin-top: 4px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.mail-folder-accordion {
  display: grid;
  gap: 8px;
}

.mail-folder-accordion-bar {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 18px;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.95);
  cursor: pointer;
  text-align: left;
}

.mail-folder-accordion-bar:hover {
  background: rgba(255, 255, 255, 0.13);
}

.mail-folder-accordion-copy {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.mail-folder-accordion-copy strong {
  font-size: 1rem;
  line-height: 1.2;
}

.mail-folder-accordion-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
}

.mail-folder-accordion-body {
  display: grid;
  gap: 6px;
  padding: 10px 10px 12px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.mail-folder-link {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
  width: 100%;
  border: 1px solid transparent;
  border-radius: 14px;
  padding: 10px 12px;
  background: transparent;
  color: rgba(255, 255, 255, 0.9);
  cursor: pointer;
  text-align: left;
}

.mail-folder-link:hover,
.mail-folder-link.active {
  background: rgba(255, 255, 255, 0.11);
  border-color: rgba(255, 255, 255, 0.12);
}

.sidebar-mail-card {
  width: 100%;
  text-align: left;
  display: grid;
  gap: 10px;
  border-radius: 16px;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.055);
  color: rgba(255, 255, 255, 0.96);
  cursor: pointer;
}

.sidebar-mail-card:hover,
.sidebar-mail-card.active {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.2);
}

.sidebar-mail-card-top {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: flex-start;
}

.sidebar-mail-card-top .muted {
  color: rgba(255, 255, 255, 0.68);
}

.sidebar-mail-card-folders {
  display: grid;
  gap: 6px;
}

.sidebar-mail-card-bar,
.mail-account-bar {
  width: 100%;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  border: 0;
  background: rgba(255, 255, 255, 0.08);
  color: inherit;
  text-align: left;
  padding: 12px 13px;
  border-radius: 16px;
  cursor: pointer;
}

.sidebar-mail-card-bar:hover,
.mail-account-bar:hover {
  background: rgba(255, 255, 255, 0.14);
}

.sidebar-mail-card-bar-copy,
.mail-account-bar-copy {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.sidebar-mail-card-bar-copy strong,
.mail-account-bar-copy strong {
  display: block;
  font-size: 0.98rem;
  line-height: 1.2;
}

.sidebar-mail-card-bar-copy .muted,
.mail-account-bar-copy .muted {
  color: rgba(255, 255, 255, 0.72);
}

.sidebar-mail-card-bar-meta,
.mail-account-bar-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
}

.mail-account-chevron {
  min-width: 1.2rem;
  text-align: center;
  font-size: 1.15rem;
  line-height: 1;
  opacity: 0.85;
}

.mail-accounts {
  display: grid;
  gap: 10px;
  margin-top: 2px;
  min-height: 88px;
}

.mail-center {
  display: grid;
  gap: 14px;
  padding: 18px;
  background:
    linear-gradient(180deg, rgba(250, 252, 255, 0.98) 0%, rgba(241, 246, 251, 0.98) 100%);
  border-right: 1px solid rgba(18, 33, 52, 0.08);
  align-content: start;
  min-width: 0;
}

.mail-resize-handle {
  width: 18px;
  cursor: col-resize;
  position: absolute;
  top: 0;
  bottom: 0;
  transform: translateX(-50%);
  z-index: 2;
  touch-action: none;
  pointer-events: auto;
  user-select: none;
}

.mail-resize-handle::before {
  content: "";
  position: absolute;
  top: 18px;
  bottom: 18px;
  left: 50%;
  width: 6px;
  transform: translateX(-50%);
  border-radius: 999px;
  background:
    linear-gradient(
      180deg,
      rgba(18, 33, 52, 0.08) 0%,
      rgba(18, 33, 52, 0.08) 18%,
      transparent 18%,
      transparent 36%,
      rgba(18, 33, 52, 0.08) 36%,
      rgba(18, 33, 52, 0.08) 54%,
      transparent 54%,
      transparent 72%,
      rgba(18, 33, 52, 0.08) 72%,
      rgba(18, 33, 52, 0.08) 100%
    );
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.5);
  transition: background 120ms ease, opacity 120ms ease, transform 120ms ease;
  opacity: 0.75;
}

.mail-resize-handle:hover::before,
.mail-resizing .mail-resize-handle::before {
  background:
    linear-gradient(
      180deg,
      rgba(43, 110, 118, 0.42) 0%,
      rgba(43, 110, 118, 0.42) 18%,
      transparent 18%,
      transparent 36%,
      rgba(43, 110, 118, 0.42) 36%,
      rgba(43, 110, 118, 0.42) 54%,
      transparent 54%,
      transparent 72%,
      rgba(43, 110, 118, 0.42) 72%,
      rgba(43, 110, 118, 0.42) 100%
    );
  opacity: 1;
  transform: translateX(-50%) scaleX(1.12);
}

.mail-reader {
  display: grid;
  gap: 14px;
  align-content: start;
  padding: 18px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.99) 0%, rgba(248, 245, 240, 0.98) 100%);
}

.mail-account-card {
  width: 100%;
  text-align: left;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.95);
  border-radius: 18px;
  display: grid;
  gap: 10px;
  padding: 0;
  box-shadow: none;
  cursor: pointer;
}

.mail-account-card.expanded,
.sidebar-mail-card.expanded {
  border-color: rgba(255, 255, 255, 0.16);
  box-shadow: none;
  background: rgba(255, 255, 255, 0.12);
}

.mail-account-card.active,
.sidebar-mail-card.active {
  border-color: rgba(255, 255, 255, 0.18);
}

.mail-account-card .muted,
.mail-account-card .mail-account-chevron,
.mail-account-card .pill,
.mail-account-card strong {
  color: rgba(255, 255, 255, 0.95);
}

.mail-account-top {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.mail-account-folders {
  display: grid;
  gap: 6px;
  padding: 0 12px 12px;
}

.mail-account-folder {
  font-size: 0.78rem;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 4px 8px;
}

.mail-account-folder-link {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 9px 10px;
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.9);
  cursor: pointer;
  text-align: left;
  transition: background 140ms ease, border-color 140ms ease, transform 140ms ease;
}

.mail-account-folder-link:hover,
.mail-account-folder-link.active {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.16);
}

.mail-account-folder-link .pill {
  flex: 0 0 auto;
}

.mail-account-card,
.sidebar-mail-card,
.mail-folder-link,
.mail-account-folder-link,
.mail-message {
  cursor: pointer;
}

.mail-folder-tabs {
  display: none;
}

.mail-message-list {
  display: grid;
  gap: 10px;
  align-content: start;
  justify-content: stretch;
  width: 100%;
  min-width: 0;
}

.mail-message {
  width: 100%;
  border: 1px solid rgba(18, 33, 52, 0.08);
  background: rgba(255, 255, 255, 0.92);
  border-radius: 16px;
  padding: 12px 12px 11px;
  text-align: left;
  display: grid;
  gap: 8px;
  cursor: pointer;
  box-shadow: 0 8px 18px rgba(18, 33, 52, 0.04);
  position: relative;
}

.mail-center .mail-message-list > .mail-message {
  width: 100%;
}

.mail-center .mail-reader,
.mail-center .mail-message-list {
  min-width: 0;
}

.mail-message.active {
  border-color: rgba(43, 110, 118, 0.3);
  box-shadow: 0 12px 24px rgba(43, 110, 118, 0.09);
  background: linear-gradient(180deg, rgba(43, 110, 118, 0.08), rgba(255, 255, 255, 0.98));
}

.mail-message.unread::before {
  content: "";
  position: absolute;
  left: 0;
  top: 14px;
  bottom: 14px;
  width: 4px;
  border-radius: 999px;
  background: var(--accent);
}

.mail-message.unread strong {
  color: var(--nav);
}

.mail-message-head {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
}

.mail-message-avatar {
  width: 34px;
  height: 34px;
  border-radius: 11px;
  display: grid;
  place-items: center;
  background: linear-gradient(180deg, rgba(43, 110, 118, 0.92), rgba(27, 82, 92, 0.92));
  color: white;
  font-weight: 800;
  font-size: 0.88rem;
  flex: none;
}

.mail-message-avatar {
  display: none !important;
}

.mail-message-head {
  grid-template-columns: minmax(0, 1fr);
}

.mail-message-copy {
  display: grid;
  gap: 5px;
  min-width: 0;
  flex: 1;
}

.mail-message-topline {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: baseline;
  min-width: 0;
}

.mail-message-topline strong {
  font-size: 0.98rem;
  line-height: 1.2;
}

.mail-message-topline .muted {
  font-size: 0.8rem;
  white-space: nowrap;
}

.mail-message-copy strong {
  margin-bottom: 0;
}

.mail-message-subline {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  font-size: 0.82rem;
  color: var(--muted);
}

.mail-message-subline .dot {
  opacity: 0.8;
}

.mail-message-snippet {
  color: var(--text);
  font-size: 0.9rem;
  line-height: 1.35;
  max-width: 72ch;
}

.mail-message-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.mail-reader-body {
  display: grid;
  gap: 12px;
  align-content: start;
}

.mail-reader-toolbar {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  padding: 12px 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid var(--line);
}

.mail-reader-toolbar .row-actions {
  flex-wrap: wrap;
}

.mail-reader-card {
  border: 1px solid rgba(18, 33, 52, 0.08);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.995) 0%, rgba(246, 242, 236, 0.98) 100%);
  box-shadow: 0 22px 48px rgba(18, 33, 52, 0.1);
  border-radius: 26px;
  padding: 20px;
  display: grid;
  gap: 16px;
}

.mail-reader-card::before {
  content: "Bericht";
  display: inline-flex;
  width: fit-content;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(43, 110, 118, 0.1);
  color: var(--accent);
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.mail-reader-head {
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
}

.mail-avatar {
  width: 56px;
  height: 56px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  background: linear-gradient(180deg, rgba(43, 110, 118, 0.92), rgba(27, 82, 92, 0.92));
  color: white;
  font-weight: 800;
  font-size: 1.2rem;
}

.mail-reader-title {
  display: grid;
  gap: 4px;
}

.mail-reader-title strong {
  font-size: 1.12rem;
}

.mail-reader-date {
  color: var(--muted);
  font-size: 0.9rem;
  white-space: nowrap;
}

.mail-reader-meta {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
}

.mail-reader-meta > div {
  display: grid;
  gap: 4px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.84);
}

.mail-reader-body-text {
  white-space: pre-wrap;
  line-height: 1.6;
  color: var(--text);
}

.mail-thread-stack {
  display: grid;
  gap: 14px;
  align-content: start;
}

.mail-thread-card {
  display: grid;
  gap: 14px;
  padding: 18px;
  border-radius: 24px;
  border: 1px solid rgba(18, 33, 52, 0.08);
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 18px 38px rgba(18, 33, 52, 0.06);
}

.mail-thread-card.latest {
  background: linear-gradient(180deg, rgba(43, 110, 118, 0.08), rgba(255, 255, 255, 0.96));
  border-color: rgba(43, 110, 118, 0.18);
}

.mail-thread-card.previous {
  background: rgba(255, 255, 255, 0.78);
}

.mail-thread-card-head {
  display: grid;
  gap: 10px;
}

.mail-thread-badge {
  display: inline-flex;
  width: fit-content;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(43, 110, 118, 0.1);
  color: var(--accent);
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.mail-thread-meta-line {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: space-between;
  align-items: baseline;
}

.mail-thread-meta-line strong {
  font-size: 1.02rem;
}

.mail-thread-meta {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.mail-thread-body {
  white-space: pre-wrap;
  line-height: 1.6;
  color: var(--text);
  max-width: 74ch;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.mail-reader-actions {
  padding-top: 2px;
}

/* Keep the reader clean: no nested white cards, just readable content. */
.mail-reader {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98) 0%, rgba(248, 245, 240, 0.96) 100%);
}

.mail-reader-card {
  background: transparent;
  border: 0;
  box-shadow: none;
  padding: 0;
  gap: 12px;
}

.mail-reader-card::before {
  display: none;
}

.mail-reader-toolbar {
  padding: 0;
  background: transparent;
  border: 0;
  border-radius: 0;
}

.mail-reader-meta {
  gap: 8px;
}

.mail-reader-meta > div {
  padding: 0;
  border: 0;
  background: transparent;
}

.mail-reader-body-text {
  max-width: 74ch;
  overflow-wrap: anywhere;
  word-break: break-word;
  padding-top: 4px;
}

.mail-reader-attachments {
  padding-top: 2px;
}

.mail-reader-attachments .pill {
  background: transparent;
}

.mail-reader-attachments {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.mail-empty {
  border: 1px dashed var(--line);
  border-radius: 18px;
  padding: 18px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.72);
}

.mail-empty-large {
  min-height: 240px;
  display: grid;
  align-content: center;
  justify-items: start;
  gap: 10px;
  background:
    radial-gradient(circle at top right, rgba(43, 110, 118, 0.08), transparent 34%),
    rgba(255, 255, 255, 0.78);
}

.mail-shell .pill {
  white-space: nowrap;
}

body.mail-resizing {
  cursor: col-resize;
  user-select: none;
}

.mail-empty-large strong {
  font-size: 1.08rem;
  color: var(--text);
}

.mail-empty-large p {
  margin: 0;
  max-width: 42ch;
  line-height: 1.5;
}

#view-jobs .mail-empty {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.03)),
    rgba(9, 17, 26, 0.9);
  border: 1px dashed rgba(255, 255, 255, 0.12);
  color: rgba(233, 241, 251, 0.76);
}

#view-jobs .mail-empty strong {
  color: rgba(255, 255, 255, 0.96);
}

#view-jobs .mail-empty p {
  color: rgba(233, 241, 251, 0.72);
}

#view-jobs .mail-empty-large {
  background:
    radial-gradient(circle at top right, rgba(84, 215, 202, 0.08), transparent 34%),
    rgba(9, 17, 26, 0.9);
}

.mail-reader-card .row-actions .ghost {
  min-width: 112px;
}

.mail-compose-drawer {
  position: fixed;
  inset: 24px 24px 24px auto;
  width: min(52vw, 900px);
  min-width: 520px;
  height: min(calc(100vh - 48px), 820px);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.995), rgba(246, 249, 252, 0.99));
  border: 1px solid rgba(18, 33, 52, 0.12);
  border-radius: 28px;
  box-shadow: 0 28px 70px rgba(16, 24, 40, 0.28);
  padding: 20px 20px 18px;
  transform: translateX(120%) scale(0.98);
  transition: transform 240ms ease;
  z-index: 30;
  overflow-y: auto;
  visibility: hidden;
  pointer-events: none;
  backdrop-filter: blur(12px);
}

.mail-compose-status {
  min-height: 1.2rem;
  font-size: 0.92rem;
}

.mail-compose-drawer.open {
  transform: translateX(0) scale(1);
  visibility: visible;
  pointer-events: auto;
}

.internal-notes-drawer {
  position: fixed;
  inset: 24px 24px 24px auto;
  width: min(calc(100vw - 48px), 660px);
  height: min(calc(100vh - 48px), 840px);
  background:
    radial-gradient(circle at top right, rgba(84, 215, 202, 0.14), transparent 24%),
    radial-gradient(circle at 15% 12%, rgba(195, 95, 47, 0.12), transparent 18%),
    linear-gradient(180deg, rgba(10, 18, 28, 0.98), rgba(14, 25, 39, 0.98));
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 28px;
  box-shadow: 0 28px 70px rgba(16, 24, 40, 0.28);
  padding: 20px 20px 18px;
  transform: translateX(120%) scale(0.98);
  transition: transform 240ms ease;
  z-index: 31;
  overflow-y: auto;
  visibility: hidden;
  pointer-events: none;
  backdrop-filter: blur(12px);
  color: #e9f1fb;
}

.internal-notes-drawer.open {
  transform: translateX(0) scale(1);
  visibility: visible;
  pointer-events: auto;
}

.internal-notes-drawer .mail-compose-head {
  border-bottom-color: rgba(255, 255, 255, 0.08);
}

.internal-notes-drawer .label,
.internal-notes-drawer .muted {
  color: rgba(233, 241, 251, 0.72);
}

.internal-notes-drawer .internal-notes-layout {
  display: grid;
  grid-template-columns: minmax(260px, 0.9fr) minmax(0, 1.1fr);
  gap: 14px;
  min-height: 0;
}

.internal-notes-drawer .internal-notes-form,
.internal-notes-drawer .internal-notes-group,
.internal-notes-drawer .internal-note-card {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.03)),
    rgba(9, 17, 26, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: none;
}

.internal-notes-drawer .internal-notes-list {
  display: grid;
  gap: 12px;
}

.internal-notes-drawer .internal-notes-group-head,
.internal-notes-drawer .internal-note-top {
  align-items: flex-start;
}

.internal-notes-drawer .internal-note-card p {
  color: rgba(233, 241, 251, 0.88);
}

.internal-notes-drawer .pill {
  background: rgba(255, 255, 255, 0.08);
}

.internal-notes-drawer .pill.ok {
  background: rgba(84, 215, 202, 0.14);
}

.internal-notes-drawer .pill.warn {
  background: rgba(208, 126, 45, 0.16);
}

.internal-notes-drawer .mini-form input,
.internal-notes-drawer .mini-form select,
.internal-notes-drawer .mini-form textarea {
  background: rgba(255, 255, 255, 0.06);
  color: #eef5ff;
  border-color: rgba(255, 255, 255, 0.1);
}

.internal-notes-drawer .internal-notes-form::before {
  background: linear-gradient(90deg, rgba(84, 215, 202, 0.4), rgba(195, 95, 47, 0.34), rgba(84, 215, 202, 0.2));
}

@media (max-width: 720px) {
  .internal-notes-drawer {
    inset: 12px;
    width: auto;
    height: auto;
    min-height: calc(100vh - 24px);
    border-radius: 22px;
    padding: 16px;
  }

  .internal-notes-drawer .internal-notes-layout {
    grid-template-columns: 1fr;
  }

  .hours-today-drawer {
    inset: 12px;
    width: auto;
    height: auto;
    min-height: calc(100vh - 24px);
    border-radius: 22px;
    padding: 16px;
  }

  .hours-today-drawer .agenda-detail-grid {
    grid-template-columns: 1fr;
  }
}

.mail-compose-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
  margin-bottom: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}

.mail-attachments-block {
  display: grid;
  gap: 8px;
}

.mail-attachments {
  display: grid;
  gap: 10px;
}

.mail-attachment {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.84);
  border-radius: 14px;
  padding: 10px 12px;
}

dialog.modal {
  border: 0;
  border-radius: 22px;
  padding: 18px;
  width: min(92vw, 560px);
  box-shadow: 0 24px 60px rgba(16, 24, 40, 0.26);
  background: var(--panel-solid);
  z-index: 3000;
}

dialog.modal.invoice-preview-modal {
  width: min(96vw, 980px);
}

dialog.modal::backdrop {
  background: rgba(15, 23, 32, 0.38);
  backdrop-filter: blur(2px);
}

.modal-fallback {
  position: fixed;
  inset: 0;
  z-index: 3000;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(15, 23, 32, 0.38);
  backdrop-filter: blur(2px);
}

.modal-fallback-panel {
  width: min(92vw, 560px);
  max-height: min(88vh, 920px);
  overflow: auto;
  border-radius: 22px;
  padding: 18px;
  background: var(--panel-solid);
  box-shadow: 0 24px 60px rgba(16, 24, 40, 0.26);
}

.modal-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
  margin-bottom: 16px;
}

.mini-form {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.mini-form label {
  display: grid;
  gap: 6px;
  font-size: 0.92rem;
  color: var(--muted);
}

.mini-form input,
.mini-form select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.82);
  color: var(--text);
  padding: 11px 13px;
  font: inherit;
}

.mini-form textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.82);
  color: var(--text);
  padding: 11px 13px;
  font: inherit;
  resize: vertical;
}

.invoice-preview-frame {
  width: 100%;
  height: min(76vh, 860px);
  border: 1px solid var(--line);
  border-radius: 16px;
  background: white;
}

.phone-top,
.time-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.time-row {
  margin: 14px 0;
  padding: 14px 0;
  border-top: 1px solid var(--line);
}

.finance-chart {
  display: grid;
  gap: 18px;
}

.status-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 13px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  font-weight: 600;
  white-space: nowrap;
}

.status-chip.subtle {
  background: rgba(255, 255, 255, 0.82);
  color: var(--text);
  border: 1px solid var(--line);
}

.status-chip::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
}

.bar-group span {
  display: block;
  margin-bottom: 8px;
}

.bar {
  height: 12px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(25, 33, 44, 0.08);
}

.bar i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #2b6e76, #66a4ad);
}

@keyframes fade {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

  .sidebar {
    min-height: auto;
    gap: 20px;
    position: static;
  }
}

@media (max-width: 720px) {
  body {
    padding: 12px;
  }

  .shell {
    gap: 14px;
    padding: 12px;
  }

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

  .topbar-actions {
    width: 100%;
  }

  .topbar-actions button,
  .topbar-actions .status-chip {
    width: 100%;
    justify-content: center;
  }

  .dashboard-actions button {
    width: 100%;
    flex-basis: auto;
  }

  .panel-subhead {
    flex-direction: column;
    align-items: flex-start;
  }

  .stats,
  .dashboard-grid,
  .two-col,
  .board-grid,
  .calendar-grid {
    grid-template-columns: 1fr;
  }

  .worker-card-head,
  .worker-card-meta,
  .calendar-head {
    flex-direction: column;
  }

  .relation-meta-grid {
    grid-template-columns: 1fr;
  }

  .mail-accounts {
    grid-template-columns: 1fr;
  }

  .mail-toolbar {
    flex-direction: column;
    align-items: stretch;
  }

  .mail-shell {
    grid-template-columns: 1fr;
  }

  .mail-ribbon-actions {
    justify-content: stretch;
  }

  .mail-ribbon-actions button {
    flex: 1 1 auto;
  }

  .mail-resize-handle {
    display: none;
  }

  .mail-sidebar,
  .mail-center,
  .mail-reader {
    min-height: auto;
  }

  .mail-compose-drawer {
    inset: 12px;
    width: calc(100vw - 24px);
    height: calc(100vh - 24px);
  }

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

  .login-card {
    padding: 22px;
  }

  .sidebar {
    border-radius: 24px;
  }

  .metric {
    min-height: auto;
  }
}

/* Visual refresh: stronger hierarchy, warmer surfaces, clearer action states */
:root {
  --bg: #ede6db;
  --bg-2: #f8f3ea;
  --panel: rgba(255, 255, 255, 0.94);
  --panel-solid: #ffffff;
  --text: #17212a;
  --muted: #5f6974;
  --line: rgba(23, 33, 42, 0.1);
  --accent: #116c77;
  --accent-soft: rgba(17, 108, 119, 0.12);
  --nav: #0d1c2a;
  --nav-2: #17344a;
  --shadow: 0 18px 42px rgba(16, 24, 40, 0.11);
  --radius: 24px;
  --radius-sm: 16px;
}

html,
body {
  background:
    radial-gradient(circle at 18% 12%, rgba(17, 108, 119, 0.14), transparent 28%),
    radial-gradient(circle at 82% 8%, rgba(214, 142, 61, 0.16), transparent 22%),
    radial-gradient(circle at 50% 100%, rgba(19, 36, 51, 0.08), transparent 34%),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-2) 100%);
}

body::before {
  width: 520px;
  height: 520px;
  top: -180px;
  left: -180px;
  background: radial-gradient(circle, rgba(17, 108, 119, 0.12), rgba(17, 108, 119, 0));
}

body::after {
  width: 420px;
  height: 420px;
  top: -30px;
  right: -120px;
  background: radial-gradient(circle, rgba(214, 142, 61, 0.16), rgba(214, 142, 61, 0));
}

.shell {
  width: 100%;
  max-width: none;
  padding: 24px;
  gap: 20px;
}

.sidebar,
.card {
  backdrop-filter: blur(14px);
}

.sidebar {
  border: 1px solid rgba(255, 255, 255, 0.07);
  box-shadow: 0 24px 60px rgba(11, 19, 28, 0.2);
}

.sidebar::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 120px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.08), transparent);
  pointer-events: none;
}

.brand {
  font-size: 1.95rem;
  line-height: 1;
}

.nav-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 650;
  letter-spacing: 0.01em;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid transparent;
}

.nav-item::after {
  content: "→";
  opacity: 0.5;
  transform: translateX(-3px);
  transition: transform 160ms ease, opacity 160ms ease;
}

.nav-item:hover::after,
.nav-item.active::after {
  transform: translateX(0);
  opacity: 1;
}

.nav-item.active {
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0.09));
  border-color: rgba(255, 255, 255, 0.12);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.02);
}

.sidebar-card {
  background: rgba(255, 255, 255, 0.07);
}

.topbar {
  position: sticky;
  top: 14px;
  z-index: 10;
  padding: 2px 0 10px;
}

.topbar-actions {
  justify-content: flex-end;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.7);
  box-shadow: 0 10px 24px rgba(16, 24, 40, 0.06);
  backdrop-filter: blur(12px);
}

.status-chip {
  background: linear-gradient(180deg, rgba(17, 108, 119, 0.13), rgba(17, 108, 119, 0.08));
  border: 1px solid rgba(17, 108, 119, 0.12);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.5);
}

.status-chip.subtle {
  background: rgba(255, 255, 255, 0.8);
}

button {
  min-height: 42px;
  border-radius: 14px;
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease, border-color 160ms ease;
}

button:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 22px rgba(16, 24, 40, 0.08);
}

button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid rgba(17, 108, 119, 0.22);
  outline-offset: 2px;
}

.primary {
  background: linear-gradient(180deg, #1b7782, #155a63);
  color: #fff;
  border-color: rgba(7, 50, 57, 0.14);
  box-shadow: 0 16px 30px rgba(17, 108, 119, 0.22);
}

.ghost {
  background: rgba(255, 255, 255, 0.84);
  border-color: rgba(23, 33, 42, 0.08);
}

.panel,
.card {
  border-radius: 24px;
  box-shadow: var(--shadow);
}

.panel {
  padding: 20px;
}

.panel-head h2 {
  font-size: 1.28rem;
}

.panel-subhead {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}

.dashboard-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(290px, 0.9fr);
  gap: 20px;
  padding: 24px;
  background:
    linear-gradient(135deg, rgba(13, 28, 42, 0.98), rgba(20, 52, 74, 0.96) 50%, rgba(17, 108, 119, 0.92)),
    radial-gradient(circle at top right, rgba(255, 255, 255, 0.18), transparent 34%);
  color: #fff;
  position: relative;
  overflow: hidden;
}

.dashboard-hero::before {
  content: "";
  position: absolute;
  inset: auto -120px -120px auto;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0));
}

.dashboard-hero-copy,
.dashboard-hero-points {
  position: relative;
  z-index: 1;
}

.dashboard-hero .label,
.dashboard-hero .muted {
  color: rgba(255, 255, 255, 0.74);
}

.dashboard-hero h2 {
  color: #fff;
  font-size: clamp(1.8rem, 3vw, 3rem);
  line-height: 1.06;
  letter-spacing: -0.05em;
}

.dashboard-hero-points {
  display: grid;
  gap: 12px;
}

.dashboard-hero-point {
  display: grid;
  gap: 8px;
  padding: 16px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.09);
  backdrop-filter: blur(10px);
}

.dashboard-hero-point strong {
  font-size: 1.6rem;
  line-height: 1;
}

.dashboard-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 18px 0 12px;
}

.dashboard-actions button {
  flex: 1 1 160px;
  justify-content: center;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid var(--line);
  font-weight: 700;
  box-shadow: 0 10px 20px rgba(16, 24, 40, 0.05);
}

.dashboard-actions button:hover {
  background: rgba(255, 255, 255, 0.98);
}

.grid.stats {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.metric {
  padding: 18px;
  border-radius: 24px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(248, 242, 234, 0.98));
  position: relative;
  overflow: hidden;
}

.metric::after {
  content: "";
  position: absolute;
  inset: auto -18px -18px auto;
  width: 130px;
  height: 130px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(17, 108, 119, 0.09), rgba(17, 108, 119, 0));
}

.metric strong {
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  letter-spacing: -0.05em;
}

.dashboard-grid,
.two-col {
  gap: 18px;
}

.payment-flow {
  display: grid;
  gap: 12px;
}

.payment-flow-card {
  border-radius: 22px;
  padding: 16px;
  background:
    radial-gradient(circle at top right, rgba(195, 95, 47, 0.08), transparent 28%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(246, 241, 234, 0.96));
  border: 1px solid rgba(22, 33, 42, 0.08);
}

.payment-flow-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.payment-flow-head h3 {
  margin: 6px 0 0;
}

.payment-flow-list {
  display: grid;
  gap: 10px;
}

.payment-flow-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(22, 33, 42, 0.06);
}

.payment-flow {
  display: grid;
  gap: 12px;
}

.payment-flow-card {
  border-radius: 22px;
  padding: 16px;
  background:
    radial-gradient(circle at top right, rgba(195, 95, 47, 0.08), transparent 28%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(246, 241, 234, 0.96));
  border: 1px solid rgba(22, 33, 42, 0.08);
}

.payment-flow-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.payment-flow-head h3 {
  margin: 6px 0 0;
}

.payment-flow-list {
  display: grid;
  gap: 10px;
}

.payment-flow-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(22, 33, 42, 0.06);
}

.project-row,
.week-row,
.notification-item,
.relation-row,
.invoice-row,
.bank-item,
.todo-row,
.agenda-row {
  padding: 15px 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid var(--line);
  box-shadow: 0 10px 22px rgba(16, 24, 40, 0.05);
}

.project-row,
.week-row,
.relation-row,
.invoice-row,
.bank-item,
.notification-item {
  display: flex;
  justify-content: space-between;
  gap: 14px;
}

.project-row .meta,
.week-row .meta,
.invoice-row .meta {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
}

.chip-row {
  margin-top: 10px;
}

.pill {
  border-color: rgba(23, 33, 42, 0.08);
}

.pill.ok {
  background: rgba(17, 108, 119, 0.14);
  color: #0e5f68;
}

.pill.warn {
  background: rgba(214, 142, 61, 0.16);
  color: #8a5620;
}

.pill.danger {
  background: rgba(183, 71, 56, 0.16);
  color: #7f301d;
}

.job-card,
.agenda-row {
  border-radius: 22px;
}

.job-card {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(248, 243, 236, 0.98));
}

.job-card.active {
  border: 1px solid rgba(84, 215, 202, 0.28);
  box-shadow:
    0 18px 36px rgba(84, 215, 202, 0.12),
    0 0 0 1px rgba(84, 215, 202, 0.08) inset;
}

.crew-focus-card {
  display: grid;
  gap: 16px;
}

.crew-focus-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.crew-focus-item {
  display: grid;
  gap: 6px;
  padding: 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.crew-focus-item select {
  width: 100%;
}

.job-card-head strong,
.invoice-row strong,
.relation-row strong,
.notification-item strong {
  font-size: 1rem;
  letter-spacing: -0.01em;
}

.job-actions,
.row-actions {
  gap: 8px;
}

.job-card .job-actions {
  align-items: center;
}

.job-actions .ghost.small,
.job-actions .primary.small,
.row-actions .ghost.small,
.row-actions .primary.small {
  min-height: 38px;
  border-radius: 12px;
}

.project-list,
.week-list,
.notification-list,
.relation-list,
.invoice-list,
.bank-list,
.todo-list {
  gap: 12px;
}

.mail-ribbon {
  position: sticky;
  top: 82px;
  z-index: 8;
  margin-bottom: 18px;
  padding: 16px 18px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid var(--line);
  box-shadow: 0 14px 30px rgba(16, 24, 40, 0.08);
  backdrop-filter: blur(12px);
}

.mail-ribbon-tools {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
  flex-wrap: wrap;
}

.mail-search {
  min-width: 280px;
  flex: 1 1 280px;
}

.mail-search input {
  min-height: 46px;
  border-radius: 14px;
}

.mail-ribbon-actions button {
  min-height: 42px;
}

.mail-overview,
.mail-fallback {
  border-radius: 24px;
  box-shadow: 0 16px 34px rgba(16, 24, 40, 0.08);
}

.mail-overview {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(247, 242, 235, 0.96));
  border: 1px solid var(--line);
}

.mail-fallback {
  background: linear-gradient(180deg, rgba(255, 251, 245, 0.97), rgba(247, 243, 236, 0.97));
  border: 1px solid rgba(17, 108, 119, 0.08);
}

.mail-overview-item,
.mail-overview-message,
.mail-fallback-item {
  border-radius: 16px;
}

.mail-shell {
  width: 100%;
  grid-template-columns: 312px minmax(0, 1fr) minmax(440px, 1fr);
  gap: 14px;
  border-radius: 30px;
  overflow: hidden;
  border: 1px solid rgba(17, 33, 48, 0.1);
  background: linear-gradient(180deg, rgba(247, 250, 252, 0.98), rgba(239, 244, 248, 0.98));
  box-shadow: 0 24px 60px rgba(16, 24, 40, 0.1);
  min-height: calc(100vh - 250px);
}

.mail-sidebar {
  padding: 18px 14px;
  background: linear-gradient(180deg, #0d1f30, #19384c);
}

.mail-sidebar-folders,
.sidebar-mail {
  background: rgba(255, 255, 255, 0.06);
}

.mail-folder-link.active,
.sidebar-mail-card.active {
  background: rgba(255, 255, 255, 0.14);
}

.mail-folder-tabs {
  display: none !important;
}

.mail-center,
.mail-reader {
  background: linear-gradient(180deg, #0d1f30, #19384c);
  color: rgba(255, 255, 255, 0.95);
}

.mail-center {
  padding: 18px;
}

.mail-message-list,
.mail-reader-body {
  min-height: 320px;
}

.mail-message {
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.95);
  box-shadow: none;
}

.mail-message.active {
  transform: translateY(-1px);
  border-color: rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.12);
}

.mail-reader-card {
  border-radius: 28px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: none;
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.95);
}

.mail-reader-toolbar {
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.08);
}

.mail-center .row-actions .ghost,
.mail-center .row-actions .primary,
.mail-empty .ghost,
.mail-empty .primary {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.95);
  box-shadow: none;
}

.mail-center .row-actions .ghost:hover,
.mail-center .row-actions .primary:hover,
.mail-empty .ghost:hover,
.mail-empty .primary:hover {
  background: rgba(255, 255, 255, 0.14);
}

.mail-compose-drawer {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.99), rgba(247, 243, 236, 0.98));
}

.mail-empty-large {
  background:
    radial-gradient(circle at top right, rgba(255, 255, 255, 0.12), transparent 28%),
    rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.92);
}

.mail-empty-large strong {
  color: rgba(255, 255, 255, 0.96);
}

.mail-empty-large p {
  color: rgba(255, 255, 255, 0.72);
}

.login-card {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(248, 243, 236, 0.96));
}

.shell {
  max-width: none;
  padding: 24px;
}

.card,
.sidebar,
.command-center,
.dashboard-hero,
.role-banner,
.office-screens,
.workflow-step {
  backdrop-filter: blur(18px);
}

.card {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(247, 243, 237, 0.92));
  border: 1px solid rgba(13, 31, 48, 0.08);
  box-shadow:
    0 18px 48px rgba(13, 31, 48, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.8);
  position: relative;
  overflow: hidden;
}

.card::before {
  content: "";
  position: absolute;
  inset: 0 auto auto 0;
  width: 100%;
  height: 4px;
  background: linear-gradient(90deg, var(--germabouw-navy), var(--germabouw-blue), var(--germabouw-orange));
  opacity: 0.9;
  pointer-events: none;
}

.sidebar {
  border-color: rgba(255, 255, 255, 0.06);
  box-shadow: 0 28px 64px rgba(6, 14, 22, 0.24);
}

.nav-item {
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.04);
  transition: transform 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

.nav-item.active {
  background:
    linear-gradient(135deg, rgba(195, 95, 47, 0.28), rgba(24, 62, 99, 0.34)),
    rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 16px 28px rgba(0, 0, 0, 0.18);
}

.dashboard-hero {
  background:
    radial-gradient(circle at 14% 18%, rgba(255, 255, 255, 0.13), transparent 18%),
    radial-gradient(circle at 88% 8%, rgba(195, 95, 47, 0.26), transparent 18%),
    radial-gradient(circle at 78% 88%, rgba(45, 88, 125, 0.34), transparent 22%),
    linear-gradient(135deg, #091521 0%, #10263d 42%, #183e63 100%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 34px 72px rgba(8, 17, 27, 0.24);
}

.dashboard-hero::before {
  content: "";
  position: absolute;
  inset: auto -120px -120px auto;
  width: 360px;
  height: 360px;
  border-radius: 50%;
  background:
    radial-gradient(circle, rgba(195, 95, 47, 0.24), rgba(195, 95, 47, 0) 64%);
}

.dashboard-hero::after {
  background:
    linear-gradient(115deg, transparent 18%, rgba(255, 255, 255, 0.12) 30%, transparent 42%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.08), transparent 18%);
}

.dashboard-hero .label,
.dashboard-hero .muted {
  color: rgba(255, 255, 255, 0.74);
}

.dashboard-hero-copy h2 {
  color: #fff;
  text-wrap: balance;
}

.dashboard-hero-point {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.04)),
    rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.08);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 14px 24px rgba(0, 0, 0, 0.12);
}

.dashboard-hero-point strong {
  background: linear-gradient(135deg, rgba(195, 95, 47, 0.34), rgba(255, 255, 255, 0.14));
  color: #fff;
}

.workflow-strip {
  gap: 12px;
  margin-bottom: 16px;
  padding: 0;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.workflow-strip::before {
  left: 18px;
  right: 18px;
  top: 30px;
  height: 1px;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0), rgba(24, 62, 99, 0.28), rgba(195, 95, 47, 0.18), rgba(255, 255, 255, 0));
}

.workflow-step {
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 10px;
  padding: 14px 14px 12px;
  border-radius: 22px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(246, 241, 234, 0.94));
  border: 1px solid rgba(13, 31, 48, 0.08);
  box-shadow:
    0 16px 32px rgba(8, 17, 27, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.85);
}

.workflow-step.active {
  border-color: rgba(195, 95, 47, 0.26);
  background:
    radial-gradient(circle at top right, rgba(195, 95, 47, 0.14), transparent 34%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(245, 239, 231, 0.96));
  box-shadow:
    0 22px 42px rgba(8, 17, 27, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.88);
}

.workflow-step.complete {
  border-color: rgba(24, 62, 99, 0.16);
}

.workflow-step-index {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(24, 62, 99, 0.12), rgba(195, 95, 47, 0.12));
  color: var(--germabouw-navy);
}

.workflow-step-top {
  align-items: center;
}

.workflow-step-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
  padding: 7px 11px;
  border-radius: 999px;
  background: rgba(24, 62, 99, 0.08);
  color: var(--germabouw-blue);
  font-weight: 700;
  letter-spacing: -0.02em;
}

.workflow-step.active .workflow-step-chip {
  background: rgba(195, 95, 47, 0.13);
  color: var(--germabouw-orange);
}

.workflow-step .pill {
  background: rgba(255, 255, 255, 0.84);
  border: 1px solid rgba(13, 31, 48, 0.08);
}

.workflow-step.active .pill.ok {
  background: rgba(24, 62, 99, 0.1);
}

.dashboard-actions button {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(247, 241, 234, 0.98));
  border: 1px solid rgba(13, 31, 48, 0.08);
  box-shadow: 0 12px 28px rgba(8, 17, 27, 0.06);
}

.command-center {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.97), rgba(242, 237, 230, 0.94)),
    radial-gradient(circle at top right, rgba(24, 62, 99, 0.08), transparent 26%);
  border: 1px solid rgba(13, 31, 48, 0.08);
}

.command-card {
  background:
    linear-gradient(145deg, rgba(13, 31, 48, 0.98), rgba(24, 62, 99, 0.96) 58%, rgba(195, 95, 47, 0.2));
  border-color: rgba(13, 31, 48, 0.2);
}

.command-card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.08), transparent 24%);
  pointer-events: none;
}

.office-screens {
  background:
    radial-gradient(circle at top right, rgba(195, 95, 47, 0.16), transparent 28%),
    radial-gradient(circle at bottom left, rgba(24, 62, 99, 0.16), transparent 24%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(240, 244, 248, 0.94));
}

.office-screen-card {
  border-radius: 24px;
}

.topbar-actions .status-chip {
  background: linear-gradient(135deg, rgba(24, 62, 99, 0.16), rgba(195, 95, 47, 0.12));
  color: var(--germabouw-blue);
  border: 1px solid rgba(24, 62, 99, 0.1);
}

.grid.stats .metric {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.97), rgba(247, 243, 236, 0.94));
  border: 1px solid rgba(13, 31, 48, 0.08);
}

:root {
  color-scheme: dark;
  --bg: #07111b;
  --bg-2: #0b1624;
  --panel: rgba(11, 18, 28, 0.74);
  --panel-solid: #0d1725;
  --text: #e9f1fb;
  --muted: #8e9db1;
  --line: rgba(255, 255, 255, 0.08);
  --accent: #54d7ca;
  --accent-2: #f2a15d;
  --accent-soft: rgba(84, 215, 202, 0.14);
  --nav: #08111b;
  --nav-2: #11263d;
  --germabouw-navy: #091521;
  --germabouw-blue: #183e63;
  --germabouw-steel: #2d587d;
  --germabouw-orange: #c35f2f;
  --germabouw-amber: #d07e2d;
  --shadow: 0 26px 64px rgba(0, 0, 0, 0.34);
}

html,
body {
  background:
    radial-gradient(circle at 12% 0%, rgba(24, 62, 99, 0.28), transparent 22%),
    radial-gradient(circle at 88% 8%, rgba(195, 95, 47, 0.18), transparent 18%),
    radial-gradient(circle at 50% 100%, rgba(84, 215, 202, 0.08), transparent 26%),
    linear-gradient(180deg, #06101a 0%, #0b1624 100%);
  color: var(--text);
}

body::before {
  background: radial-gradient(circle, rgba(24, 62, 99, 0.22) 0%, rgba(24, 62, 99, 0.04) 50%, transparent 70%);
}

body::after {
  background: radial-gradient(circle, rgba(195, 95, 47, 0.18) 0%, rgba(195, 95, 47, 0.04) 55%, transparent 72%);
}

.sidebar,
.card,
.panel,
.metric,
.command-center,
.dashboard-hero,
.workflow-step,
.project-row,
.week-row,
.notification-row,
.relation-card,
.invoice-card,
.bank-row,
.todo-row,
.todo-summary-row,
.agenda-row,
.agenda-detail-card,
.finance-breakdown-card,
.payment-flow-card,
.mail-ribbon,
.mail-overview,
.mail-fallback,
.mail-shell,
.mail-center,
.mail-reader,
.mail-sidebar,
.mail-message,
.mail-reader-card,
.template-card,
.template-preview,
.crew-card,
.crew-load-card,
.job-card,
.job-day-group,
.relation-field,
.job-meta,
.workspace-registry-card,
.internal-notes-form,
.internal-notes-group,
.internal-note-card,
.check-item,
.calendar-cell,
.calendar-item,
dialog.modal,
.modal-fallback-panel,
.mail-attachment,
.dashboard-mini-stat,
.role-banner-mini-card,
.dashboard-hero-mini,
.login-card {
  background: rgba(11, 18, 28, 0.78);
  border-color: rgba(255, 255, 255, 0.08);
  color: var(--text);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.24);
}

.card::before,
.job-card::before,
.work-flow-step::before {
  opacity: 0.9;
}

.sidebar {
  background:
    radial-gradient(circle at top right, rgba(195, 95, 47, 0.18), transparent 28%),
    linear-gradient(180deg, #08111b 0%, #0f2236 100%);
}

.sidebar .subtitle,
.sidebar .muted,
.sidebar .label,
.sidebar .eyebrow,
.muted,
.label,
.eyebrow {
  color: var(--muted);
}

.nav-item {
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(255, 255, 255, 0.04);
}

.nav-item.active {
  background:
    linear-gradient(135deg, rgba(24, 62, 99, 0.44), rgba(195, 95, 47, 0.28)),
    rgba(255, 255, 255, 0.06);
  box-shadow: 0 16px 28px rgba(0, 0, 0, 0.18);
}

.topbar-actions {
  background: rgba(10, 16, 25, 0.72);
  border-color: rgba(255, 255, 255, 0.08);
  box-shadow: 0 18px 36px rgba(0, 0, 0, 0.16);
}

.status-chip {
  background: rgba(84, 215, 202, 0.12);
  color: #86efe4;
}

.status-chip.subtle {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
}

.ghost,
.tab-pill,
.dashboard-actions button {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  border-color: rgba(255, 255, 255, 0.08);
}

.primary {
  background: linear-gradient(180deg, #4b7eff 0%, #274a93 100%);
  box-shadow: 0 18px 30px rgba(36, 75, 157, 0.28);
}

.dashboard-hero {
  background:
    radial-gradient(circle at 8% 18%, rgba(84, 215, 202, 0.16), transparent 18%),
    radial-gradient(circle at 85% 12%, rgba(195, 95, 47, 0.22), transparent 18%),
    linear-gradient(135deg, #091521 0%, #10263d 42%, #183e63 100%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 34px 72px rgba(8, 17, 27, 0.28);
  display: grid;
  gap: 18px;
  grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.8fr);
  align-items: start;
}

.dashboard-hero-copy h2 {
  color: #fff;
  margin-bottom: 8px;
  font-size: clamp(2rem, 3.2vw, 3.2rem);
  line-height: 0.98;
  letter-spacing: -0.06em;
}

.dashboard-hero-copy p {
  margin: 0;
  color: rgba(233, 241, 251, 0.78);
  font-size: 1rem;
}

.dashboard-hero-side {
  display: grid;
  gap: 12px;
}

.hours-layout .card,
.personnel-layout .card,
.invoice-browser .card {
  background: rgba(11, 18, 28, 0.82);
  border-color: rgba(255, 255, 255, 0.08);
}

.hours-summary-card {
  background:
    linear-gradient(180deg, rgba(11, 18, 28, 0.95), rgba(17, 33, 52, 0.95)),
    radial-gradient(circle at top right, rgba(84, 215, 202, 0.1), transparent 28%);
  border-color: rgba(255, 255, 255, 0.08);
}

.hours-summary-card.accent-warm {
  background:
    linear-gradient(180deg, rgba(195, 95, 47, 0.18), rgba(11, 18, 28, 0.96)),
    rgba(11, 18, 28, 0.96);
}

.hours-summary-card.accent-emerald {
  background:
    linear-gradient(180deg, rgba(84, 215, 202, 0.16), rgba(11, 18, 28, 0.96)),
    rgba(11, 18, 28, 0.96);
}

.hours-summary-card.accent-gold {
  background:
    linear-gradient(180deg, rgba(208, 126, 45, 0.2), rgba(11, 18, 28, 0.96)),
    rgba(11, 18, 28, 0.96);
}

.hours-summary-card .label,
.hours-summary-card .muted {
  color: rgba(233, 241, 251, 0.72);
}

.hours-attention-row,
.worker-card,
.worker-card-personal,
.worker-card-manager,
.worker-card-hours,
.personnel-worker-card,
.personnel-crew-card,
.invoice-preview-panel,
.invoice-card,
.invoice-card-incoming,
.invoice-card-field,
.mail-message,
.mail-account-card,
.sidebar-mail-card,
.crew-card,
.crew-load-card,
.job-card,
.relation-card,
.todo-row,
.todo-summary-row {
  background: rgba(9, 17, 26, 0.9);
  border-color: rgba(255, 255, 255, 0.08);
}

.crew-pick,
.crew-select-fallback {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.crew-pick.active {
  background:
    linear-gradient(135deg, rgba(84, 215, 202, 0.18), rgba(195, 95, 47, 0.12)),
    rgba(255, 255, 255, 0.08);
  border-color: rgba(84, 215, 202, 0.24);
}

.personnel-layout {
  display: grid;
  grid-template-columns: minmax(280px, 0.75fr) minmax(0, 1.25fr);
  gap: 16px;
}

.personnel-crew-board,
.personnel-worker-list {
  display: grid;
  gap: 12px;
}

.personnel-crew-card,
.personnel-worker-card,
.invoice-preview-panel {
  padding: 16px;
  border-radius: 22px;
}

.invoice-preview-panel {
  position: sticky;
  top: 92px;
}

.personnel-worker-head,
.invoice-preview-meta-top,
.crew-notes-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.personnel-worker-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.personnel-worker-actions .crew-pick {
  min-height: 36px;
  padding: 8px 12px;
  border-radius: 12px;
}

.invoice-browser {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

.invoice-browser-list {
  display: grid;
  gap: 16px;
  padding-right: clamp(340px, 42vw, 760px);
}

.invoice-card {
  cursor: pointer;
}

.invoice-card.active {
  border-color: rgba(84, 215, 202, 0.3);
  box-shadow: 0 16px 34px rgba(84, 215, 202, 0.12);
}

.invoice-card-amount {
  color: #fff;
}

.invoice-card-field {
  background: rgba(8, 15, 24, 0.76);
}

.invoice-preview-shell {
  display: grid;
  gap: 12px;
}

.invoice-preview-frame {
  width: 100%;
  min-height: 560px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.96);
}

.invoice-preview-meta {
  display: grid;
  gap: 12px;
}

.invoice-preview-meta-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.invoice-preview-meta-grid > div {
  display: grid;
  gap: 6px;
  padding: 12px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.invoice-preview-meta-grid strong {
  letter-spacing: -0.03em;
}

.project-note-form {
  display: grid;
  gap: 10px;
}

.project-note-list {
  display: grid;
  gap: 10px;
}

.project-note-card {
  display: grid;
  gap: 8px;
  padding: 14px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.05);
}

.project-note-card p {
  margin: 0;
}

.dashboard-hero-mini {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.dashboard-mini-stat {
  padding: 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.dashboard-mini-stat strong {
  display: block;
  margin-top: 8px;
  font-size: 1.45rem;
  letter-spacing: -0.04em;
}

.role-banner-mini-grid {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.role-banner-mini-card {
  display: grid;
  gap: 6px;
  padding: 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.role-banner-mini-card strong {
  font-size: 1.45rem;
  letter-spacing: -0.04em;
}

.workflow-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(11, 18, 28, 0.86), rgba(13, 23, 37, 0.92)),
    radial-gradient(circle at top right, rgba(195, 95, 47, 0.1), transparent 18%);
}

.workflow-step {
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(255, 255, 255, 0.08);
  color: var(--text);
}

.workflow-step.active {
  border-color: rgba(84, 215, 202, 0.22);
  background:
    linear-gradient(180deg, rgba(84, 215, 202, 0.14), rgba(255, 255, 255, 0.05)),
    rgba(255, 255, 255, 0.06);
}

.workflow-step-index {
  background: linear-gradient(135deg, rgba(84, 215, 202, 0.18), rgba(195, 95, 47, 0.16));
  color: #fff;
}

.workflow-step .label,
.workflow-step .pill {
  color: var(--text);
}

.workflow-step .pill {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.08);
}

.workflow-step.active .pill.ok {
  background: rgba(84, 215, 202, 0.14);
}

.dashboard-hero-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.dashboard-hero-action {
  display: grid;
  gap: 6px;
  text-align: left;
  min-height: 88px;
  padding: 14px 16px;
  border-radius: 18px;
  color: #fff;
}

.dashboard-hero-action.ghost {
  color: #fff;
}

.dashboard-hero-action strong {
  display: block;
  font-size: 1rem;
  letter-spacing: -0.03em;
}

.dashboard-hero-action span {
  display: block;
  color: inherit;
  opacity: 0.78;
  line-height: 1.35;
}

.dashboard-start-guide {
  margin-bottom: 16px;
}

.dashboard-start-guide .label,
.dashboard-start-guide .muted,
.dashboard-start-guide .dashboard-guide-note,
.dashboard-start-guide h2 {
  color: rgba(233, 241, 251, 0.84);
}

.dashboard-start-guide h2 {
  color: #fff;
}

.dashboard-guide-footer {
  display: grid;
  gap: 12px;
  margin-top: 14px;
}

.dashboard-guide-note {
  margin: 0;
  line-height: 1.5;
}

.dashboard-guide-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.mobile-launchpad-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.grid.stats .metric,
.project-row,
.week-row,
.notification-row,
.relation-card,
.invoice-card,
.bank-row,
.todo-row,
.todo-summary-row,
.agenda-row,
.agenda-detail-card,
.finance-breakdown-card,
.payment-flow-card {
  background: rgba(255, 255, 255, 0.05);
}

.metric::after {
  background: radial-gradient(circle, rgba(84, 215, 202, 0.12), rgba(84, 215, 202, 0));
}

.command-center {
  background:
    linear-gradient(180deg, rgba(11, 18, 28, 0.88), rgba(13, 23, 37, 0.94)),
    radial-gradient(circle at top right, rgba(84, 215, 202, 0.08), transparent 26%);
}

.command-card {
  background:
    linear-gradient(145deg, rgba(7, 17, 27, 0.98), rgba(16, 38, 61, 0.96) 58%, rgba(195, 95, 47, 0.2));
  border-color: rgba(255, 255, 255, 0.08);
}

.command-item {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.08);
}

.office-screens {
  background:
    radial-gradient(circle at top right, rgba(195, 95, 47, 0.14), transparent 28%),
    radial-gradient(circle at bottom left, rgba(24, 62, 99, 0.16), transparent 24%),
    linear-gradient(180deg, rgba(11, 18, 28, 0.86), rgba(13, 23, 37, 0.94));
}

.office-screen-card,
.office-screen-line {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.08);
}

.office-screen-card.wall {
  background:
    radial-gradient(circle at top right, rgba(84, 215, 202, 0.14), transparent 28%),
    linear-gradient(180deg, #091521, #183e63);
}

.office-screen-card.desk {
  background:
    radial-gradient(circle at top right, rgba(195, 95, 47, 0.12), transparent 28%),
    linear-gradient(180deg, rgba(15, 24, 35, 0.92), rgba(20, 32, 46, 0.94));
}

.office-screen-card.wall .office-screen-line-button.active {
  background: rgba(255, 255, 255, 0.12);
}

.mail-ribbon,
.mail-overview,
.mail-fallback,
.mail-shell,
.mail-center,
.mail-reader,
.mail-sidebar,
.mail-reader-card,
.mail-message,
.mail-compose-drawer,
dialog.modal,
.modal-fallback-panel {
  background: rgba(11, 18, 28, 0.82);
  border-color: rgba(255, 255, 255, 0.08);
  color: var(--text);
}

.mail-message.active {
  background: rgba(84, 215, 202, 0.12);
  border-color: rgba(84, 215, 202, 0.18);
}

.mail-search input,
.login-form input,
.mini-form input,
.mini-form select,
.mini-form textarea,
.job-meta select,
.worker-language-select select {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  border-color: rgba(255, 255, 255, 0.08);
}

.agenda-layout.list-mode .agenda-side,
.agenda-detail-card,
.finance-breakdown-card,
.payment-flow-card,
.template-card,
.template-preview,
.workspace-registry-card,
.internal-notes-form,
.internal-notes-group,
.internal-note-card,
.crew-card,
.crew-load-card,
.job-card,
.job-day-group {
  background: rgba(255, 255, 255, 0.05);
}

.agenda-row.active,
.calendar-item.active {
  background: rgba(84, 215, 202, 0.12);
  border-color: rgba(84, 215, 202, 0.18);
}

.agenda-row.danger {
  border-left-color: #f05f5f;
}

.pill {
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.pill.ok {
  background: rgba(84, 215, 202, 0.16);
  color: #8ef5ec;
}

.pill.warn {
  background: rgba(242, 161, 93, 0.16);
  color: #f6ba7d;
}

.pill.danger {
  background: rgba(240, 95, 95, 0.16);
  color: #f89b9b;
}

@media (max-width: 1180px) {
  .dashboard-hero,
  .mail-shell {
    grid-template-columns: 1fr;
  }

  .workflow-strip {
    grid-template-columns: 1fr 1fr;
  }

  .dashboard-hero-actions {
    grid-template-columns: 1fr 1fr;
  }

  .office-screens-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .mail-resize-handle {
    display: none;
  }

  .mail-sidebar,
  .mail-center,
  .mail-reader {
    min-height: auto;
  }

  .agenda-detail-ops,
  .finance-breakdown-grid {
    grid-template-columns: 1fr;
  }

  .command-grid,
  .dashboard-grid {
    grid-template-columns: 1fr;
  }

  .workspace-focus-grid,
  .workspace-registry-list {
    grid-template-columns: 1fr;
  }

  .workspace-home-grid {
    grid-template-columns: 1fr;
  }

  .mobile-launchpad-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .invoice-browser,
  .personnel-layout {
    grid-template-columns: 1fr;
  }

  .worker-agenda-card-top,
  .worker-agenda-card-meta {
    flex-direction: column;
    align-items: stretch;
  }

  .hours-layout .worker-grid {
    grid-template-columns: 1fr;
  }

  .internal-notes-layout {
    grid-template-columns: 1fr;
  }
}

@media (min-width: 1181px) and (max-width: 1460px) {
  .command-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .shell {
    padding: 12px;
  }

  .workflow-strip {
    grid-template-columns: 1fr;
  }

  .office-screens-grid {
    grid-template-columns: 1fr;
  }

  .dashboard-hero {
    padding: 20px;
  }

  .dashboard-hero-points {
    grid-template-columns: 1fr;
  }

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

  .dashboard-actions button {
    width: 100%;
    flex-basis: auto;
  }

  .dashboard-hero-actions,
  .dashboard-guide-actions,
  .mobile-launchpad-actions {
    display: grid;
    grid-template-columns: 1fr;
  }

  .workspace-mobile-actions {
    grid-template-columns: 1fr;
  }

  .workspace-home-grid {
    grid-template-columns: 1fr;
  }

  .personnel-worker-actions .crew-pick {
    width: 100%;
  }

  .hours-layout .worker-grid {
    grid-template-columns: 1fr;
  }

  .worker-card {
    padding: 14px;
    border-radius: 20px;
  }

  .worker-card-head,
  .worker-card-meta,
  .workspace-registry-meta {
    flex-direction: column;
    align-items: stretch;
  }

  .worker-card-meta {
    gap: 8px;
  }

  .hours-summary-grid {
    grid-template-columns: 1fr;
  }

  .worker-language-select {
    gap: 8px;
  }

  .worker-language-select select {
    width: 100%;
  }

  .worker-week-details > summary {
    padding: 12px 14px;
  }

  .worker-day-row {
    padding: 10px 12px;
  }

  .worker-agenda-card {
    padding: 12px;
    border-radius: 18px;
  }

  .mail-ribbon {
    top: 12px;
  }

  .mail-ribbon-tools {
    align-items: stretch;
  }

  .mail-search {
    min-width: 0;
  }

  .agenda-side {
    width: 100%;
  }
}

/* Final dark cockpit override */
:root {
  color-scheme: dark;
}

html,
body {
  background:
    radial-gradient(circle at 12% 0%, rgba(24, 62, 99, 0.28), transparent 22%),
    radial-gradient(circle at 88% 8%, rgba(195, 95, 47, 0.16), transparent 18%),
    linear-gradient(180deg, #06101a 0%, #0b1624 100%);
  color: #e9f1fb;
}

.card,
.panel,
.sidebar,
.metric,
.command-center,
.dashboard-hero,
.workflow-strip,
.workflow-step,
.project-row,
.week-row,
.notification-row,
.relation-card,
.invoice-card,
.bank-row,
.todo-row,
.todo-summary-row,
.agenda-row,
.agenda-detail-card,
.finance-breakdown-card,
.payment-flow-card,
.mail-ribbon,
.mail-overview,
.mail-fallback,
.mail-shell,
.mail-center,
.mail-reader,
.mail-sidebar,
.mail-message,
.mail-reader-card,
.template-card,
.template-preview,
.crew-card,
.crew-load-card,
.job-card,
.job-day-group,
.relation-field,
.job-meta,
.workspace-registry-card,
.internal-notes-form,
.internal-notes-group,
.internal-note-card,
.check-item,
.calendar-cell,
.calendar-item,
dialog.modal,
.modal-fallback-panel,
.mail-attachment,
.dashboard-mini-stat,
.role-banner-mini-card,
.dashboard-hero-mini {
  background: rgba(11, 18, 28, 0.8) !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
  color: #e9f1fb !important;
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.24) !important;
}

.sidebar {
  background:
    radial-gradient(circle at top right, rgba(195, 95, 47, 0.16), transparent 28%),
    linear-gradient(180deg, #08111b 0%, #0f2236 100%) !important;
}

.sidebar .subtitle,
.sidebar .muted,
.sidebar .label,
.sidebar .eyebrow,
.muted,
.label,
.eyebrow {
  color: #8e9db1 !important;
}

.topbar-actions,
.ghost,
.tab-pill,
.dashboard-actions button,
.mail-search input,
.login-form input,
.mini-form input,
.mini-form select,
.mini-form textarea,
.job-meta select,
.worker-language-select select {
  background: rgba(255, 255, 255, 0.06) !important;
  color: #e9f1fb !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
}

.primary {
  background: linear-gradient(180deg, #4b7eff 0%, #274a93 100%) !important;
}

.dashboard-hero {
  background:
    radial-gradient(circle at 8% 18%, rgba(84, 215, 202, 0.16), transparent 18%),
    radial-gradient(circle at 85% 12%, rgba(195, 95, 47, 0.22), transparent 18%),
    linear-gradient(135deg, #091521 0%, #10263d 42%, #183e63 100%) !important;
}

.dashboard-hero-copy h2 {
  color: #fff !important;
}

.dashboard-hero-copy p {
  color: rgba(233, 241, 251, 0.8) !important;
}

.workflow-step.active {
  background:
    linear-gradient(180deg, rgba(84, 215, 202, 0.14), rgba(255, 255, 255, 0.05)),
    rgba(255, 255, 255, 0.06) !important;
}

.workflow-step-index {
  color: #fff !important;
}

.role-banner-mini-card strong,
.dashboard-mini-stat strong,
.metric strong {
  color: #fff !important;
}

.command-card {
  background:
    linear-gradient(145deg, rgba(7, 17, 27, 0.98), rgba(16, 38, 61, 0.96) 58%, rgba(195, 95, 47, 0.2)) !important;
}

.command-item,
.office-screen-line,
.mail-message.active,
.agenda-row.active,
.calendar-item.active,
.newsletter,
.invoice-card,
.relation-card,
.template-card,
.finance-breakdown-card,
.payment-flow-card,
.job-card,
.crew-card,
.crew-load-card {
  background: rgba(255, 255, 255, 0.06) !important;
}

.agenda-item-dialog,
.modal-fallback-panel,
dialog.modal {
  z-index: 3000;
}

/* Premium cockpit refinement */
:root {
  --cockpit-glow: rgba(84, 215, 202, 0.16);
  --cockpit-glow-2: rgba(195, 95, 47, 0.18);
  --cockpit-edge: rgba(255, 255, 255, 0.1);
}

body::before {
  width: 620px;
  height: 620px;
  top: -240px;
  left: -220px;
  background:
    radial-gradient(circle, rgba(84, 215, 202, 0.16) 0%, rgba(84, 215, 202, 0.05) 44%, transparent 74%);
}

body::after {
  width: 420px;
  height: 420px;
  top: 18px;
  right: -150px;
  background:
    radial-gradient(circle, rgba(195, 95, 47, 0.18) 0%, rgba(195, 95, 47, 0.06) 46%, transparent 72%);
}

.shell {
  gap: 22px;
  padding: 22px;
}

.sidebar {
  box-shadow:
    0 30px 80px rgba(0, 0, 0, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.sidebar::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.05), transparent 18%),
    radial-gradient(circle at 100% 0%, rgba(84, 215, 202, 0.12), transparent 26%),
    radial-gradient(circle at 0% 100%, rgba(195, 95, 47, 0.08), transparent 20%);
  pointer-events: none;
}

.card,
.panel,
.command-card,
.dashboard-hero,
.workflow-step,
.role-banner,
.agenda-detail-card,
.agenda-row,
.job-card,
.relation-card,
.invoice-card,
.finance-breakdown-card,
.payment-flow-card,
.workspace-registry-card,
.internal-note-card,
.mail-message,
.mail-reader-card,
.mail-ribbon,
.mail-overview,
.mail-fallback,
.mail-shell,
.mail-center,
.mail-sidebar,
.template-card,
.template-preview,
.crew-card,
.crew-load-card {
  border-radius: 28px;
}

.card,
.panel {
  box-shadow:
    0 26px 70px rgba(4, 10, 20, 0.24),
    inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

.topbar {
  margin-bottom: 24px;
}

.dashboard-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 18px;
}

.dashboard-actions button {
  min-height: 46px;
  padding-inline: 18px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: linear-gradient(180deg, rgba(16, 38, 61, 0.92), rgba(11, 18, 28, 0.96)) !important;
  box-shadow:
    0 18px 30px rgba(0, 0, 0, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
  color: #e9f1fb !important;
}

.dashboard-actions button:hover {
  border-color: rgba(84, 215, 202, 0.22);
  box-shadow:
    0 20px 34px rgba(0, 0, 0, 0.26),
    0 0 0 1px rgba(84, 215, 202, 0.08) inset;
}

.dashboard-hero {
  padding: 28px;
  background:
    radial-gradient(circle at 8% 18%, rgba(84, 215, 202, 0.18), transparent 18%),
    radial-gradient(circle at 86% 12%, rgba(195, 95, 47, 0.24), transparent 18%),
    linear-gradient(145deg, #091521 0%, #10263d 46%, #183e63 100%) !important;
  border: 1px solid rgba(84, 215, 202, 0.16) !important;
  box-shadow:
    0 30px 80px rgba(0, 0, 0, 0.3),
    0 0 0 1px rgba(255, 255, 255, 0.04);
}

.dashboard-hero::before {
  content: "";
  position: absolute;
  top: -80px;
  right: -50px;
  width: 280px;
  height: 280px;
  background: radial-gradient(circle, rgba(84, 215, 202, 0.18), transparent 62%);
  pointer-events: none;
}

.dashboard-hero::after {
  background:
    linear-gradient(115deg, transparent 16%, rgba(255, 255, 255, 0.18) 28%, transparent 40%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.1), transparent 22%);
  opacity: 0.9;
}

.dashboard-hero-copy h2 {
  color: #fff !important;
  text-wrap: balance;
}

.dashboard-hero-copy p {
  color: rgba(233, 241, 251, 0.8) !important;
  max-width: 58ch;
}

.dashboard-hero-mini {
  display: grid;
  gap: 12px;
}

.dashboard-mini-stat {
  padding: 14px 16px;
  border-radius: 20px;
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(145deg, rgba(7, 17, 27, 0.94), rgba(16, 38, 61, 0.94) 62%, rgba(195, 95, 47, 0.16)) !important;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.dashboard-mini-stat::after {
  content: "";
  position: absolute;
  inset: auto -10% -32% 46%;
  height: 90%;
  background: radial-gradient(circle, rgba(84, 215, 202, 0.14), transparent 64%);
  pointer-events: none;
}

.dashboard-mini-stat strong {
  display: block;
  margin-top: 4px;
  font-size: clamp(1.7rem, 4vw, 2.5rem);
  line-height: 1;
  letter-spacing: -0.07em;
  color: #fff !important;
}

.workflow-strip {
  gap: 16px;
}

.workflow-strip::before {
  left: 48px;
  right: 48px;
  top: 42px;
  height: 2px;
  background: linear-gradient(90deg, rgba(84, 215, 202, 0.24), rgba(48, 99, 175, 0.42), rgba(195, 95, 47, 0.44), rgba(212, 126, 45, 0.24));
  box-shadow: 0 0 22px rgba(84, 215, 202, 0.12);
}

.workflow-step {
  padding: 18px 18px 16px;
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  background:
    linear-gradient(180deg, rgba(10, 18, 28, 0.96), rgba(18, 33, 52, 0.96)) !important;
  box-shadow:
    0 20px 42px rgba(0, 0, 0, 0.24),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
  overflow: hidden;
}

.workflow-step::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 6px;
  border-radius: 24px 24px 0 0;
}

.workflow-step:nth-child(1)::before {
  background: linear-gradient(90deg, rgba(84, 215, 202, 0.92), rgba(84, 215, 202, 0.18));
}

.workflow-step:nth-child(2)::before {
  background: linear-gradient(90deg, rgba(48, 99, 175, 0.92), rgba(48, 99, 175, 0.2));
}

.workflow-step:nth-child(3)::before {
  background: linear-gradient(90deg, rgba(195, 95, 47, 0.92), rgba(195, 95, 47, 0.2));
}

.workflow-step:nth-child(4)::before {
  background: linear-gradient(90deg, rgba(212, 126, 45, 0.92), rgba(212, 126, 45, 0.2));
}

.workflow-step.active {
  transform: translateY(-2px);
  border-color: rgba(84, 215, 202, 0.22) !important;
  background:
    radial-gradient(circle at top right, rgba(84, 215, 202, 0.14), transparent 34%),
    linear-gradient(180deg, rgba(15, 27, 42, 0.98), rgba(18, 33, 52, 0.98)) !important;
  box-shadow:
    0 26px 46px rgba(0, 0, 0, 0.28),
    0 0 0 1px rgba(84, 215, 202, 0.16);
}

.workflow-step.active .pill.ok {
  background: rgba(84, 215, 202, 0.18) !important;
  color: #bffcf5 !important;
}

.workflow-step-index {
  background: rgba(84, 215, 202, 0.14) !important;
  color: #fff !important;
}

.workflow-step-chip,
.dashboard-mini-stat .label,
.dashboard-mini-stat .muted {
  color: rgba(233, 241, 251, 0.7) !important;
}

.command-center,
.workspace-registry,
.internal-notes-form {
  border: 1px solid rgba(255, 255, 255, 0.07) !important;
  box-shadow:
    0 26px 60px rgba(0, 0, 0, 0.24),
    inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

.command-center::before,
.workspace-registry::before,
.internal-notes-form::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 5px;
  background: linear-gradient(180deg, rgba(84, 215, 202, 0.84), rgba(48, 99, 175, 0.84), rgba(195, 95, 47, 0.84));
}

.command-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background:
    linear-gradient(145deg, rgba(7, 17, 27, 0.98), rgba(16, 38, 61, 0.96) 56%, rgba(195, 95, 47, 0.16)) !important;
  box-shadow:
    0 18px 38px rgba(0, 0, 0, 0.22),
    inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

.command-card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  background: linear-gradient(180deg, rgba(84, 215, 202, 0.9), rgba(195, 95, 47, 0.9));
}

.command-item {
  position: relative;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.05) !important;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.command-item::after {
  content: "";
  position: absolute;
  inset: auto -8% -40% 68%;
  height: 100%;
  background: radial-gradient(circle, rgba(84, 215, 202, 0.12), transparent 64%);
  pointer-events: none;
}

.command-item strong {
  letter-spacing: -0.03em;
}

.card:hover,
.panel:hover,
.command-card:hover,
.workflow-step:hover,
.agenda-row:hover,
.job-card:hover,
.relation-card:hover {
  transform: translateY(-1px);
}

.dashboard-actions button,
.nav-item,
.ghost,
.primary {
  border-radius: 999px;
}

.dashboard-actions button,
.ghost,
.primary {
  min-height: 44px;
}

.topbar-actions .status-chip {
  background: rgba(84, 215, 202, 0.1);
  color: #bffcf5;
  border: 1px solid rgba(84, 215, 202, 0.18);
}

.topbar-actions .status-chip.subtle {
  background: rgba(255, 255, 255, 0.05);
  color: #a9b7c8;
}

.dashboard-grid .card,
.command-center,
.workspace-registry,
.internal-notes-form {
  overflow: hidden;
}

.dashboard-grid .card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 5px;
  background: linear-gradient(180deg, rgba(84, 215, 202, 0.82), rgba(48, 99, 175, 0.82), rgba(195, 95, 47, 0.82));
}

.panel-head h2,
.dashboard-hero-copy h2,
.command-card h3 {
  letter-spacing: -0.05em;
}

.agenda-row.active,
.calendar-item.active {
  background: linear-gradient(180deg, rgba(84, 215, 202, 0.14), rgba(255, 255, 255, 0.08)) !important;
  border-color: rgba(84, 215, 202, 0.24) !important;
}

.agenda-detail-card {
  box-shadow:
    0 20px 40px rgba(0, 0, 0, 0.22),
    inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

.agenda-day-card {
  display: grid;
  gap: 16px;
}

.agenda-day-summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.agenda-day-list {
  display: grid;
  gap: 10px;
  overflow-y: auto;
  padding-right: 2px;
}

.agenda-day-item {
  display: grid;
  gap: 8px;
  width: 100%;
  text-align: left;
  padding: 14px 15px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0.03)),
    rgba(9, 17, 26, 0.92);
  color: inherit;
}

.agenda-day-item:hover,
.agenda-day-item:focus-visible {
  transform: translateY(-1px);
  border-color: rgba(84, 215, 202, 0.22);
}

.agenda-day-item.active {
  background:
    linear-gradient(180deg, rgba(84, 215, 202, 0.12), rgba(195, 95, 47, 0.05)),
    rgba(9, 17, 26, 0.96);
  border-color: rgba(84, 215, 202, 0.22);
}

.agenda-day-item.danger {
  border-left: 4px solid #d03f3f;
}

.agenda-day-item-top {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.agenda-day-empty {
  display: grid;
  gap: 6px;
  padding: 18px;
  border-radius: 18px;
  border: 1px dashed rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.03);
}

.agenda-day-empty p {
  margin: 0;
}

/* Agenda overlay drawer */
.agenda-layout.detail-open {
  overflow: hidden;
}

.agenda-layout.detail-open::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(6, 16, 26, 0.12) 0%, rgba(6, 16, 26, 0.34) 100%);
  pointer-events: none;
  z-index: 8;
}

.agenda-layout.detail-open .agenda-calendar,
.agenda-layout.detail-open .agenda-list {
  filter: saturate(0.88) brightness(0.88);
}

.agenda-layout.detail-open .agenda-side {
  position: absolute;
  top: 16px;
  right: 16px;
  bottom: 16px;
  left: auto;
  width: clamp(520px, 52vw, 900px);
  max-width: none;
  transform: translateX(104%);
  border-radius: 28px 0 0 28px;
  z-index: 18;
  background:
    radial-gradient(circle at top right, rgba(84, 215, 202, 0.12), transparent 24%),
    linear-gradient(180deg, rgba(9, 21, 33, 0.98), rgba(15, 31, 48, 0.98));
  border-left: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow:
    -34px 0 80px rgba(0, 0, 0, 0.34),
    inset 1px 0 0 rgba(255, 255, 255, 0.04);
}

.agenda-layout.detail-open .agenda-side.is-open {
  transform: translateX(0);
}

.agenda-layout.detail-open .agenda-detail-card {
  background:
    radial-gradient(circle at top right, rgba(84, 215, 202, 0.08), transparent 26%),
    linear-gradient(180deg, rgba(12, 25, 39, 0.98), rgba(18, 33, 52, 0.98));
}

.agenda-layout.detail-open .agenda-detail-block,
.agenda-layout.detail-open .agenda-detail-ops-block,
.agenda-layout.detail-open .agenda-detail-finance.locked {
  background: rgba(255, 255, 255, 0.04);
}

@media (max-width: 1180px) {
  .agenda-layout.detail-open .agenda-side {
    width: min(92vw, 820px);
    top: 12px;
    right: 12px;
    bottom: 12px;
  }

  .agenda-day-summary {
    grid-template-columns: 1fr;
  }
}

.invoice-browser {
  position: relative;
}

.invoice-browser-list {
  padding-right: clamp(340px, 42vw, 760px);
}

.invoice-preview-panel {
  position: sticky;
  top: 92px;
  width: min(760px, 42vw);
  margin-left: auto;
  z-index: 4;
  overflow: auto;
  transform: translateX(16px);
  opacity: 0.98;
  transition:
    transform 220ms ease,
    opacity 220ms ease,
    box-shadow 220ms ease;
  box-shadow: -22px 0 56px rgba(0, 0, 0, 0.26);
}

.invoice-browser.has-selection .invoice-preview-panel,
.invoice-preview-panel.is-open {
  transform: translateX(0);
}

.finance-summary-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.finance-summary-card.accent-blue {
  background:
    radial-gradient(circle at top right, rgba(84, 215, 202, 0.12), transparent 28%),
    linear-gradient(180deg, rgba(8, 19, 31, 0.96), rgba(14, 31, 49, 0.98));
}

.finance-summary-card.accent-gold {
  background:
    radial-gradient(circle at top right, rgba(208, 126, 45, 0.12), transparent 28%),
    linear-gradient(180deg, rgba(8, 19, 31, 0.96), rgba(18, 25, 35, 0.98));
}

.finance-summary-card.accent-emerald {
  background:
    radial-gradient(circle at top right, rgba(84, 215, 202, 0.16), transparent 28%),
    linear-gradient(180deg, rgba(8, 19, 31, 0.96), rgba(13, 28, 40, 0.98));
}

.finance-summary-card.accent-warm {
  background:
    radial-gradient(circle at top right, rgba(195, 95, 47, 0.14), transparent 28%),
    linear-gradient(180deg, rgba(8, 19, 31, 0.96), rgba(24, 25, 31, 0.98));
}

.finance-summary-card.accent-red {
  background:
    radial-gradient(circle at top right, rgba(211, 72, 72, 0.14), transparent 28%),
    linear-gradient(180deg, rgba(8, 19, 31, 0.96), rgba(28, 17, 24, 0.98));
}

.finance-summary-card.accent-steel {
  background:
    radial-gradient(circle at top right, rgba(48, 99, 175, 0.14), transparent 28%),
    linear-gradient(180deg, rgba(8, 19, 31, 0.96), rgba(13, 25, 40, 0.98));
}

.finance-demo-board {
  display: grid;
  gap: 14px;
  margin-bottom: 18px;
  grid-template-columns: 1.35fr 1fr;
}

.finance-demo-card {
  display: grid;
  gap: 16px;
  padding: 18px;
  border-radius: 24px;
  background:
    radial-gradient(circle at top right, rgba(84, 215, 202, 0.12), transparent 26%),
    linear-gradient(180deg, rgba(8, 19, 31, 0.98), rgba(14, 25, 39, 0.98));
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 20px 44px rgba(0, 0, 0, 0.24);
}

.finance-demo-card-wide {
  min-height: 100%;
}

.finance-demo-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.finance-demo-head h3 {
  margin: 4px 0 0;
  font-size: 1.35rem;
  letter-spacing: -0.04em;
}

.finance-demo-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.finance-demo-stat {
  padding: 14px 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.07);
}

.finance-demo-stat strong {
  display: block;
  margin: 4px 0 2px;
  font-size: 1.4rem;
  letter-spacing: -0.04em;
  color: #fff;
}

.finance-demo-trend {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  align-items: end;
  min-height: 220px;
  padding: 14px 10px 4px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.finance-demo-bar {
  display: grid;
  gap: 8px;
  justify-items: center;
  align-items: end;
  height: 100%;
}

.finance-demo-bar span {
  display: block;
  width: 100%;
  max-width: 64px;
  min-height: 42px;
  border-radius: 16px 16px 8px 8px;
  background:
    linear-gradient(180deg, rgba(84, 215, 202, 0.92), rgba(48, 99, 175, 0.9));
  box-shadow: 0 16px 28px rgba(0, 0, 0, 0.2);
}

.finance-demo-bar em {
  font-style: normal;
  font-size: 0.85rem;
  color: #9eb0c5;
}

.finance-demo-bar strong {
  font-size: 0.9rem;
  color: #fff;
}

.finance-demo-bar small {
  color: #8e9db1;
}

.finance-summary-card,
.finance-breakdown-card,
.payment-flow-card,
.invoice-card,
.invoice-card-incoming,
.invoice-card-field,
.finance-breakdown-item,
.finance-breakdown-row,
.payment-flow-row,
.hours-attention-row,
.worker-card-hours,
.worker-card-personal,
.personnel-worker-card,
.personnel-crew-card,
.mail-message,
.mail-account-card,
.sidebar-mail-card,
.crew-card,
.crew-load-card,
.job-card,
.relation-card,
.todo-row,
.todo-summary-row,
.bank-row {
  background: rgba(9, 17, 26, 0.92);
  border-color: rgba(255, 255, 255, 0.08);
}

.finance-breakdown-card,
.payment-flow-card {
  box-shadow:
    0 20px 44px rgba(0, 0, 0, 0.24),
    inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

.finance-breakdown-item,
.finance-breakdown-row,
.payment-flow-row,
.invoice-card-field {
  background: rgba(6, 13, 21, 0.76);
}

.invoice-card {
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.22);
}

.invoice-card-incoming {
  background:
    radial-gradient(circle at top right, rgba(48, 99, 175, 0.14), transparent 28%),
    linear-gradient(180deg, rgba(8, 19, 31, 0.96), rgba(13, 25, 40, 0.98));
}

.invoice-card.active {
  border-color: rgba(84, 215, 202, 0.34);
  box-shadow:
    0 20px 44px rgba(84, 215, 202, 0.12),
    0 18px 42px rgba(0, 0, 0, 0.2);
}

.invoice-card-amount {
  color: #f8fbff;
}

.invoice-preview-panel {
  background:
    radial-gradient(circle at top right, rgba(84, 215, 202, 0.1), transparent 24%),
    linear-gradient(180deg, rgba(8, 17, 27, 0.98), rgba(14, 25, 39, 0.98));
  border-color: rgba(255, 255, 255, 0.08);
}

.invoice-preview-frame {
  background: rgba(5, 10, 16, 0.98);
  border-color: rgba(255, 255, 255, 0.08);
}

.finance-summary-strip .pill {
  background: rgba(255, 255, 255, 0.06);
}

.finance-bank-overview {
  display: grid;
  gap: 12px;
  margin-top: 14px;
}

.finance-bank-overview-grid {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.finance-bank-overview-card {
  display: grid;
  gap: 8px;
  padding: 14px 15px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(9, 17, 26, 0.92);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.18);
}

.finance-bank-overview-card strong {
  font-size: 1.3rem;
  letter-spacing: -0.03em;
}

.finance-bank-overview-card.accent-blue {
  background: linear-gradient(180deg, rgba(8, 19, 31, 0.96), rgba(14, 31, 49, 0.98));
}

.finance-bank-overview-card.accent-gold {
  background: linear-gradient(180deg, rgba(8, 19, 31, 0.96), rgba(18, 25, 35, 0.98));
}

.finance-bank-overview-card.accent-emerald {
  background: linear-gradient(180deg, rgba(8, 19, 31, 0.96), rgba(13, 28, 40, 0.98));
}

.finance-bank-overview-card.accent-red {
  background: linear-gradient(180deg, rgba(8, 19, 31, 0.96), rgba(28, 17, 24, 0.98));
}

.finance-bank-overview-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.finance-ledger {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.finance-ledger-card,
.finance-alert-card {
  display: grid;
  gap: 10px;
  padding: 16px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background:
    radial-gradient(circle at top right, rgba(84, 215, 202, 0.08), transparent 24%),
    linear-gradient(180deg, rgba(8, 19, 31, 0.98), rgba(14, 25, 39, 0.98));
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.2);
}

.finance-ledger-card.accent-blue {
  background:
    radial-gradient(circle at top right, rgba(84, 215, 202, 0.12), transparent 28%),
    linear-gradient(180deg, rgba(8, 19, 31, 0.96), rgba(14, 31, 49, 0.98));
}

.finance-ledger-card.accent-gold {
  background:
    radial-gradient(circle at top right, rgba(208, 126, 45, 0.12), transparent 28%),
    linear-gradient(180deg, rgba(8, 19, 31, 0.96), rgba(18, 25, 35, 0.98));
}

.finance-ledger-card.accent-emerald {
  background:
    radial-gradient(circle at top right, rgba(84, 215, 202, 0.16), transparent 28%),
    linear-gradient(180deg, rgba(8, 19, 31, 0.96), rgba(13, 28, 40, 0.98));
}

.finance-ledger-card.accent-warm {
  background:
    radial-gradient(circle at top right, rgba(195, 95, 47, 0.14), transparent 28%),
    linear-gradient(180deg, rgba(8, 19, 31, 0.96), rgba(24, 25, 31, 0.98));
}

.finance-ledger-card strong,
.finance-alert-card strong {
  font-size: 1.25rem;
  letter-spacing: -0.03em;
}

.finance-ledger-list,
.finance-alerts-list {
  display: grid;
  gap: 8px;
}

.finance-ledger-list.compact {
  gap: 6px;
}

.finance-ledger-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.bank-row {
  color: #e6edf6;
  gap: 8px;
}

.bank-row strong {
  color: #f8fbff;
}

.bank-row .muted {
  color: rgba(226, 232, 240, 0.76);
}

.finance-alert-card .muted {
  color: rgba(226, 232, 240, 0.72);
}

.finance-alert-card {
  background:
    radial-gradient(circle at top right, rgba(84, 215, 202, 0.08), transparent 26%),
    linear-gradient(180deg, rgba(8, 19, 31, 0.98), rgba(14, 25, 39, 0.98));
}

@media (max-width: 1180px) {
  .invoice-browser-list {
    padding-right: 0;
  }

  .invoice-preview-panel {
    position: static;
    width: 100%;
    margin-left: 0;
    transform: none;
    opacity: 1;
  }

  .finance-summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .finance-demo-board {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .finance-summary-grid {
    grid-template-columns: 1fr;
  }

  .finance-ledger {
    grid-template-columns: 1fr;
  }

  .finance-demo-grid {
    grid-template-columns: 1fr;
  }

  .finance-demo-trend {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    min-height: 280px;
  }

  .invoice-browser-list {
    padding-right: 0;
  }
}

/* Invoice drawer */
#view-invoices .invoice-browser {
  position: relative;
  display: block;
}

#view-invoices .invoice-browser-list {
  width: 100%;
  padding-right: 0;
}

#view-invoices .invoice-preview-panel {
  position: fixed;
  top: 22px;
  right: 22px;
  bottom: 22px;
  width: min(1040px, calc(100vw - 44px));
  max-width: none;
  margin-left: 0;
  transform: translateX(106%);
  opacity: 0;
  pointer-events: none;
  z-index: 28;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  background:
    radial-gradient(circle at top right, rgba(84, 215, 202, 0.12), transparent 26%),
    linear-gradient(180deg, rgba(8, 17, 27, 0.99), rgba(14, 25, 39, 0.99));
}

#view-invoices .invoice-browser.has-selection .invoice-preview-panel,
#view-invoices .invoice-preview-panel.is-open {
  transform: translateX(0);
  opacity: 1;
  pointer-events: auto;
}

#view-invoices .invoice-browser.has-selection::before {
  content: "";
  position: fixed;
  inset: 0;
  background: linear-gradient(90deg, rgba(6, 16, 26, 0.08), rgba(6, 16, 26, 0.28));
  pointer-events: none;
  z-index: 24;
}

#view-invoices .invoice-preview-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
  min-height: 0;
  flex: 1;
  overflow: hidden;
}

#view-invoices .invoice-preview-meta {
  display: grid;
  gap: 12px;
  padding: 0 2px 4px;
}

#view-invoices .invoice-preview-meta-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

#view-invoices .invoice-preview-meta-top h3 {
  margin: 4px 0 2px;
  font-size: 1.45rem;
  letter-spacing: -0.04em;
}

#view-invoices .invoice-preview-meta-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

#view-invoices .invoice-preview-meta-grid > div {
  padding: 14px 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

#view-invoices .invoice-preview-meta-grid strong {
  display: block;
  margin-top: 4px;
  color: #fff;
  font-size: 1rem;
}

#view-invoices .invoice-preview-frame {
  display: block;
  width: 100%;
  min-height: 0;
  flex: 1;
  overflow: auto;
  padding: 24px;
  border-radius: 28px;
  background: linear-gradient(180deg, rgba(7, 13, 20, 0.9), rgba(10, 17, 26, 0.98));
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.invoice-preview-empty {
  min-height: 240px;
  display: grid;
  place-items: center;
  gap: 8px;
  text-align: center;
  padding: 24px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.05);
  color: rgba(233, 241, 251, 0.8);
}

.invoice-sheet {
  display: grid;
  gap: 18px;
  padding: 0;
  color: #eaf1fb;
}

.invoice-sheet-hero {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 22px;
  border-radius: 24px;
  background:
    radial-gradient(circle at top right, rgba(84, 215, 202, 0.12), transparent 28%),
    linear-gradient(145deg, rgba(12, 22, 34, 0.96), rgba(20, 38, 61, 0.98));
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.invoice-sheet-hero h3 {
  margin: 4px 0 6px;
  font-size: clamp(1.6rem, 2.4vw, 2.4rem);
  letter-spacing: -0.05em;
}

.invoice-number-box {
  min-width: 180px;
  padding: 14px 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
  text-align: right;
}

.invoice-number-box strong {
  display: block;
  font-size: 1.35rem;
  margin: 4px 0;
}

.invoice-sheet-meta {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.invoice-meta-card {
  padding: 18px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(255, 255, 255, 0.07);
}

.invoice-meta-card strong {
  display: block;
  margin: 4px 0 2px;
  font-size: 1.08rem;
  color: #fff;
}

.invoice-sheet-table-wrap {
  overflow: auto;
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
}

.invoice-sheet-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 640px;
}

.invoice-sheet-table th,
.invoice-sheet-table td {
  padding: 14px 16px;
  text-align: left;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}

.invoice-sheet-table th {
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: rgba(233, 241, 251, 0.62);
  background: rgba(255, 255, 255, 0.02);
}

.invoice-sheet-totals {
  display: grid;
  gap: 10px;
  padding: 18px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(255, 255, 255, 0.07);
}

.invoice-total-row {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  font-size: 1rem;
}

.invoice-total-row.grand {
  padding-top: 10px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 1.15rem;
}

.invoice-sheet-footer {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  padding-bottom: 6px;
}

.invoice-sheet-footer > div {
  padding: 16px 18px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(255, 255, 255, 0.07);
}

.invoice-sheet-footer p {
  margin: 6px 0 0;
  color: rgba(233, 241, 251, 0.8);
  line-height: 1.55;
}

@media (max-width: 1180px) {
  #view-invoices .invoice-preview-panel {
    top: 12px;
    right: 12px;
    bottom: 12px;
    width: min(96vw, 980px);
  }

  #view-invoices .invoice-preview-meta-grid,
  #view-invoices .invoice-sheet-meta,
  .invoice-sheet-footer {
    grid-template-columns: 1fr;
  }

  .invoice-sheet-hero {
    flex-direction: column;
  }

  .invoice-number-box {
    text-align: left;
    min-width: 0;
  }
}

@media (max-width: 720px) {
  #view-invoices .invoice-preview-panel {
    inset: 10px;
    width: auto;
  }

  #view-invoices .invoice-preview-frame {
    padding: 14px;
  }

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

  .job-workflow-line {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* Invoice page override: accordions + right drawer */
#view-invoices .invoice-browser {
  position: relative;
  display: grid;
  gap: 18px;
}

#view-invoices .invoice-browser-list {
  padding-right: 0;
  display: grid;
  gap: 14px;
}

#view-invoices .invoice-section {
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 22px;
  background: rgba(8, 15, 24, 0.82);
  overflow: hidden;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.24);
}

#view-invoices .invoice-section[open] {
  border-color: rgba(84, 215, 202, 0.2);
}

#view-invoices .invoice-section-summary {
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 20px;
  cursor: pointer;
  user-select: none;
}

#view-invoices .invoice-section-summary::-webkit-details-marker {
  display: none;
}

#view-invoices .invoice-section-summary h2 {
  margin: 4px 0 0;
}

#view-invoices .invoice-section-body {
  padding: 0 18px 18px;
}

#view-invoices .invoice-list {
  display: grid;
  gap: 12px;
}

#view-invoices .invoice-preview-panel {
  position: fixed;
  top: 116px;
  right: 22px;
  bottom: 22px;
  width: min(48vw, 760px);
  min-width: 420px;
  z-index: 40;
  transform: translateX(112%);
  opacity: 0;
  pointer-events: none;
  transition: transform 260ms ease, opacity 260ms ease;
  display: grid;
  gap: 12px;
  background: rgba(7, 12, 20, 0.96);
  backdrop-filter: blur(18px);
}

#view-invoices .invoice-browser.has-selection .invoice-preview-panel,
#view-invoices .invoice-preview-panel.is-open {
  transform: translateX(0);
  opacity: 1;
  pointer-events: auto;
}

#view-invoices .invoice-browser.has-selection::before {
  content: "";
  position: fixed;
  inset: 0;
  background: rgba(1, 4, 9, 0.22);
  backdrop-filter: blur(2px);
  z-index: 35;
}

#view-invoices .invoice-preview-shell {
  display: grid;
  gap: 12px;
  overflow: auto;
  min-height: 0;
}

@media (max-width: 1180px) {
  #view-invoices .invoice-preview-panel {
    width: min(58vw, 620px);
    min-width: 320px;
  }
}

@media (max-width: 980px) {
  #view-invoices .invoice-preview-panel {
    top: 92px;
    right: 14px;
    left: 14px;
    width: auto;
    min-width: 0;
    max-height: calc(100vh - 112px);
  }

  #view-invoices .invoice-browser.has-selection::before {
    inset: 0;
  }
}

@media (max-width: 760px) {
  #view-invoices .invoice-section-summary {
    padding: 16px;
  }

  #view-invoices .invoice-section-body {
    padding: 0 14px 14px;
  }

  #view-invoices .invoice-preview-frame {
    min-height: 480px;
  }
}

@media (max-width: 720px) {
  body {
    padding: 8px;
  }

  .shell {
    grid-template-columns: 1fr;
    gap: 10px;
    padding: 0;
  }

  .sidebar {
    display: none;
  }

  .main {
    min-height: auto;
    padding-bottom: 92px;
  }

  .main::before {
    border-radius: 0;
  }

  .mobile-launchpad {
    display: grid;
    gap: 14px;
    margin-bottom: 14px;
    padding: 18px;
  }

  .mobile-launchpad-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .mobile-bottom-nav {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 8px;
    position: fixed;
    left: 8px;
    right: 8px;
    bottom: 8px;
    z-index: 60;
    padding: 8px;
    border-radius: 22px;
    background: rgba(13, 31, 48, 0.94);
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 20px 40px rgba(16, 24, 40, 0.18);
  }

  .mobile-bottom-nav-item {
    display: grid;
    place-items: center;
    min-height: 52px;
    font-size: 0.8rem;
    line-height: 1.1;
  }

  .sidebar-mail {
    display: none !important;
  }

  #logout-button {
    width: 100%;
  }

  .topbar {
    position: sticky;
    top: 8px;
    z-index: 35;
    padding: 10px 12px;
    border-radius: 18px;
    background: var(--panel);
    backdrop-filter: blur(18px);
  }

  .topbar-actions {
    gap: 8px;
    flex-wrap: wrap;
  }

  .topbar-actions .status-chip,
  .topbar-actions button {
    width: auto;
  }

  .content {
    padding-bottom: 4px;
  }

  .content:last-of-type {
    padding-bottom: 88px;
  }

  .card,
  .panel {
    border-radius: 18px;
  }

  .panel {
    padding: 16px;
  }

  .dashboard-hero {
    padding: 16px;
  }

  .dashboard-actions {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    gap: 8px;
    padding-bottom: 4px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .dashboard-actions::-webkit-scrollbar {
    display: none;
  }

  .dashboard-actions button {
    flex: 0 0 auto;
    width: auto;
    min-width: max-content;
  }

  .panel-head {
    gap: 8px;
  }

  .panel-head h2 {
    font-size: 1.15rem;
  }

  .dashboard-grid,
  .two-col,
  .board-grid,
  .calendar-grid,
  .stats,
  .workspace-home-grid,
  .workspace-mobile-actions,
  .workspace-focus-grid,
  .workspace-registry-list,
  .invoice-browser,
  .personnel-layout,
  .mail-shell {
    grid-template-columns: 1fr !important;
  }

  .mail-resize-handle {
    display: none;
  }

  .mail-sidebar,
  .mail-center,
  .mail-reader {
    min-height: auto;
  }

  .mail-compose-drawer,
  .internal-notes-drawer,
  .hours-today-drawer,
  dialog.modal,
  .modal-fallback-panel,
  #view-invoices .invoice-preview-panel {
    inset: 8px !important;
    width: auto !important;
    height: auto !important;
    min-height: calc(100vh - 16px);
    max-height: calc(100vh - 16px);
    border-radius: 20px;
  }

  .mail-compose-drawer,
  .internal-notes-drawer,
  .hours-today-drawer,
  #view-invoices .invoice-preview-panel {
    padding: 16px;
  }

  .invoice-preview-frame {
    min-height: 420px;
  }

  .login-card {
    width: 100%;
    padding: 20px;
  }

  .login-hint {
    font-size: 0.94rem;
  }
}

/* Final mail-reader override: keep the reader visually identical to the center column. */
body .mail-reader {
  background:
    linear-gradient(180deg, #0d1f30 0%, #19384c 100%) !important;
  color: rgba(255, 255, 255, 0.95) !important;
  padding: 18px !important;
}

body .mail-reader-card {
  padding: 12px 12px 11px;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
  background: rgba(255, 255, 255, 0.08) !important;
  box-shadow: none;
  gap: 12px;
  color: rgba(255, 255, 255, 0.95) !important;
  border-radius: 18px;
}

body .mail-reader-card::before {
  display: none;
}

body .mail-reader-toolbar {
  padding: 12px 14px;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
  background: rgba(255, 255, 255, 0.08) !important;
  border-radius: 18px;
}

body .mail-reader-meta {
  gap: 8px;
}

body .mail-reader-meta > div,
body .mail-thread-meta > div {
  padding: 10px 12px !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
  background: rgba(255, 255, 255, 0.08) !important;
  color: rgba(255, 255, 255, 0.95) !important;
}

body .mail-thread-card {
  display: grid;
  gap: 8px;
  padding: 12px 12px 11px;
  background: rgba(255, 255, 255, 0.08) !important;
  border-color: rgba(255, 255, 255, 0.1) !important;
  box-shadow: none !important;
  color: rgba(255, 255, 255, 0.95) !important;
  border-radius: 18px;
}

body .mail-thread-card.latest {
  background: rgba(255, 255, 255, 0.08) !important;
  border-color: rgba(255, 255, 255, 0.1) !important;
}

body .mail-thread-card.previous {
  background: rgba(255, 255, 255, 0.08) !important;
}

body .mail-reader-body-text {
  max-width: 74ch;
  overflow-wrap: anywhere;
  word-break: break-word;
  padding-top: 4px;
  color: rgba(255, 255, 255, 0.95) !important;
}

body .mail-reader-attachments {
  padding-top: 2px;
}

body .mail-reader-attachments .pill {
  background: rgba(255, 255, 255, 0.08) !important;
  color: rgba(255, 255, 255, 0.95) !important;
}

:root {
  color-scheme: dark;
  --bg: #05070d;
  --bg-2: #0a111c;
  --panel: rgba(10, 15, 24, 0.78);
  --panel-solid: #0d1422;
  --text: #eef4ff;
  --muted: #94a3b8;
  --line: rgba(148, 163, 184, 0.14);
  --accent: #67e8d4;
  --accent-2: #7ea5ff;
  --accent-soft: rgba(103, 232, 212, 0.14);
  --nav: #040911;
  --nav-2: #0b1424;
  --shadow: 0 30px 70px rgba(2, 6, 23, 0.42);
}

body {
  background:
    radial-gradient(circle at 12% 12%, rgba(103, 232, 212, 0.14), transparent 24%),
    radial-gradient(circle at 88% 8%, rgba(126, 165, 255, 0.12), transparent 22%),
    radial-gradient(circle at 50% 100%, rgba(14, 165, 233, 0.08), transparent 18%),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-2) 100%);
  color: var(--text);
}

body::before {
  background: radial-gradient(circle, rgba(103, 232, 212, 0.16) 0%, rgba(103, 232, 212, 0.04) 55%, transparent 70%);
}

body::after {
  background: radial-gradient(circle, rgba(126, 165, 255, 0.14) 0%, rgba(126, 165, 255, 0.04) 55%, transparent 70%);
}

.shell .card,
.login-screen .card,
.sidebar {
  background: rgba(10, 15, 24, 0.82);
  border-color: rgba(148, 163, 184, 0.14);
  box-shadow: 0 24px 60px rgba(2, 6, 23, 0.38);
}

.sidebar {
  background:
    radial-gradient(circle at top right, rgba(103, 232, 212, 0.1), transparent 30%),
    linear-gradient(180deg, rgba(5, 10, 18, 0.98), rgba(10, 18, 31, 0.96));
}

.sidebar .subtitle,
.sidebar .muted,
.sidebar .label,
.sidebar .eyebrow,
.muted,
.subtitle,
.label,
.eyebrow {
  color: var(--muted);
}

.main::before {
  background:
    radial-gradient(circle at 20% 0%, rgba(103, 232, 212, 0.08), transparent 28%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.04), transparent 22%);
}

.nav-item {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(148, 163, 184, 0.08);
  color: rgba(238, 244, 255, 0.92);
}

.nav-item:hover,
.nav-item.active {
  background:
    linear-gradient(180deg, rgba(103, 232, 212, 0.16), rgba(126, 165, 255, 0.12));
  border-color: rgba(103, 232, 212, 0.22);
  box-shadow: 0 12px 26px rgba(2, 6, 23, 0.24);
}

.card {
  background:
    radial-gradient(circle at top right, rgba(103, 232, 212, 0.06), transparent 24%),
    rgba(10, 15, 24, 0.84);
}

button {
  border-radius: 16px;
}

.primary {
  background: linear-gradient(135deg, #7cf0e1 0%, #7ea5ff 100%);
  color: #061019;
  box-shadow: 0 16px 34px rgba(103, 232, 212, 0.22);
}

.ghost {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(148, 163, 184, 0.14);
  color: var(--text);
}

.pill,
.status-chip,
.tab-pill {
  background: rgba(255, 255, 255, 0.04);
  color: rgba(238, 244, 255, 0.9);
  border-color: rgba(148, 163, 184, 0.12);
}

.pill.ok,
.status-chip.ok {
  background: rgba(103, 232, 212, 0.12);
  color: #8ef4e6;
  border-color: rgba(103, 232, 212, 0.16);
}

input,
select,
textarea {
  background: rgba(6, 10, 18, 0.88);
  color: var(--text);
  border-color: rgba(148, 163, 184, 0.18);
}

.login-screen {
  padding: 24px;
}

.login-stage {
  grid-template-columns: minmax(0, 1.35fr) minmax(340px, 0.78fr);
}

.login-intro {
  background:
    radial-gradient(circle at 12% 16%, rgba(103, 232, 212, 0.24), transparent 24%),
    radial-gradient(circle at 88% 10%, rgba(126, 165, 255, 0.18), transparent 20%),
    linear-gradient(160deg, rgba(5, 10, 18, 0.98), rgba(10, 20, 34, 0.96) 54%, rgba(12, 34, 42, 0.94));
  color: var(--text);
}

.login-intro::before {
  border-color: rgba(255, 255, 255, 0.08);
}

.login-card,
.login-feature-card,
.login-metric,
.login-device {
  background: rgba(8, 12, 20, 0.76);
  border-color: rgba(148, 163, 184, 0.14);
}

.login-feature-card strong,
.login-metric strong,
.login-device-title,
.login-card h1,
.login-intro h1 {
  color: var(--text);
}

.login-feature-card .muted,
.login-metric .muted,
.login-intro .muted,
.login-card .muted {
  color: rgba(148, 163, 184, 0.94);
}

.login-hero-actions {
  gap: 8px;
}

.login-cta {
  min-height: 44px;
}

.dashboard-actions {
  padding: 10px;
  margin-bottom: 18px;
  border-radius: 22px;
  background: rgba(8, 12, 20, 0.7);
  border: 1px solid rgba(148, 163, 184, 0.12);
}

.dashboard-actions button {
  min-height: 48px;
}

.dashboard-hero,
.command-center,
.mobile-launchpad {
  background:
    radial-gradient(circle at top right, rgba(103, 232, 212, 0.1), transparent 24%),
    radial-gradient(circle at bottom left, rgba(126, 165, 255, 0.08), transparent 26%),
    rgba(8, 12, 20, 0.82);
  border-color: rgba(148, 163, 184, 0.14);
}

.dashboard-hero::after,
.command-center::before {
  background:
    linear-gradient(140deg, transparent 18%, rgba(255, 255, 255, 0.05) 32%, transparent 48%),
    linear-gradient(0deg, rgba(255, 255, 255, 0.04), transparent 18%);
}

.dashboard-hero-copy h2,
.dashboard-start-guide h2,
.panel-head h2 {
  color: var(--text);
}

.dashboard-hero-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.dashboard-hero-action {
  min-height: 96px;
  text-align: left;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(148, 163, 184, 0.14);
}

.dashboard-hero-action.primary {
  background: linear-gradient(135deg, rgba(103, 232, 212, 0.18), rgba(126, 165, 255, 0.18));
  color: var(--text);
}

.workflow-step {
  background:
    radial-gradient(circle at top right, rgba(103, 232, 212, 0.08), transparent 28%),
    rgba(8, 12, 20, 0.84);
  border-color: rgba(148, 163, 184, 0.14);
  box-shadow: 0 18px 32px rgba(2, 6, 23, 0.28);
}

.workflow-step.active {
  border-color: rgba(103, 232, 212, 0.22);
  transform: translateY(-2px);
}

.workflow-step::after {
  background: rgba(148, 163, 184, 0.12);
}

.workflow-step.complete::after {
  background: linear-gradient(90deg, rgba(103, 232, 212, 0.5), rgba(126, 165, 255, 0.24));
}

.workflow-step-index {
  background: rgba(103, 232, 212, 0.12);
  color: #8ef4e6;
}

.dashboard-grid .card,
.dashboard-grid .command-center,
.dashboard-grid .workflow-step {
  backdrop-filter: blur(20px);
}

.mobile-launchpad {
  border-radius: 28px;
}

.mobile-launchpad-stat {
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(148, 163, 184, 0.12);
}

.mobile-bottom-nav {
  background: rgba(5, 9, 16, 0.86);
  border-color: rgba(148, 163, 184, 0.14);
  box-shadow: 0 20px 40px rgba(2, 6, 23, 0.36);
}

.mobile-bottom-nav-item {
  color: var(--muted);
}

.mobile-bottom-nav-item.active {
  background: rgba(103, 232, 212, 0.12);
  color: var(--text);
}

@media (max-width: 960px) {
  .login-stage {
    grid-template-columns: 1fr;
  }

  .dashboard-hero-actions {
    grid-template-columns: 1fr;
  }

  .workflow-strip {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .login-screen {
    padding: 14px;
  }

  .login-intro,
  .login-card {
    padding: 22px;
  }

  .dashboard-actions {
    padding: 8px;
  }
}

/* ==========================================================
   JD STEIGERS - KLUSSEN WORKFLOW V1
   ========================================================== */

#view-jobs .job-flow {
  gap: 18px;
}

#view-jobs .jobs-stage {
  background: transparent;
  box-shadow: none;
}

#view-jobs .jobs-stage-copy {
  margin: 7px 0 0;
  max-width: 720px;
  line-height: 1.5;
}

#view-jobs .jobs-stage-plan .invoice-section {
  border-color: rgba(208, 126, 45, 0.22);
}

#view-jobs .jobs-stage-plan .invoice-section[open] {
  border-color: rgba(208, 126, 45, 0.36);
}

#view-jobs .jobs-stage-running .invoice-section {
  border-color: rgba(84, 215, 202, 0.18);
}

#view-jobs .jobs-stage-running .invoice-section[open] {
  border-color: rgba(84, 215, 202, 0.34);
}

#view-jobs .jobs-stage-completed .invoice-section {
  opacity: 0.94;
}

#view-jobs .jobs-stage-empty {
  min-height: 110px;
  display: grid;
  align-content: center;
  gap: 6px;
  padding: 22px;
  border: 1px dashed rgba(255, 255, 255, 0.1);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.025);
}

#view-jobs .jobs-stage-empty p {
  margin: 0;
}

#view-jobs .job-card {
  transition:
    border-color 0.16s ease,
    transform 0.16s ease,
    background 0.16s ease;
}

#view-jobs .job-card:hover {
  transform: translateY(-1px);
  border-color: rgba(84, 215, 202, 0.24);
}

@media (max-width: 760px) {
  #view-jobs .invoice-section-summary {
    align-items: flex-start;
    flex-direction: column;
  }

  #view-jobs .invoice-section-summary .row-actions {
    width: 100%;
  }

  #view-jobs .job-section-grid {
    grid-template-columns: 1fr;
  }
}


/* =========================================================
   JD STEIGERS - KLUS INTERACTIE V2 FIXED
   ========================================================= */

#view-jobs .job-card-head-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 8px;
}

#view-jobs .job-card.collapsed > *:not(.job-card-head) {
  display: none;
}

#view-jobs .job-card.collapsed {
  gap: 0;
  padding: 14px 16px;
}

#view-jobs .job-card.expanded {
  gap: 14px;
}

#view-jobs .job-toggle-button {
  min-width: 108px;
}

#view-jobs .job-card.collapsed .job-card-head {
  align-items: center;
}

#view-jobs .job-estimate-input:focus {
  outline: none;
  border-color: rgba(84, 215, 202, 0.68);
  box-shadow: 0 0 0 3px rgba(84, 215, 202, 0.12);
}

#view-jobs .jobs-stage-running .job-card {
  border-color: rgba(84, 215, 202, 0.16);
}

@media (max-width: 760px) {
  #view-jobs .job-card-head-actions {
    width: 100%;
    justify-content: flex-start;
  }
}


/* =========================================================
   JD STEIGERS - SIMPLE LOGIN
   ========================================================= */

.login-screen {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
}

.login-stage {
  width: min(460px, 100%);
  display: block;
}

.login-stage .login-card {
  width: 100%;
  max-width: none;
  margin: 0 auto;
  justify-self: auto;
  padding: 32px;
}

.login-card-header h1 {
  margin: 4px 0 2px;
}

.login-form-simple {
  width: 100%;
}

@media (max-width: 600px) {
  .login-screen {
    padding: 16px;
  }

  .login-stage {
    width: 100%;
  }

  .login-stage .login-card {
    padding: 24px;
    border-radius: 24px;
  }
}


/* =========================================================
   JD STEIGERS - RUSTIG OVERZICHT V1
   ========================================================= */

#view-dashboard {
  max-width: 1500px;
}

.jd-overview-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 18px;
}

.jd-overview-head h1 {
  margin: 5px 0 5px;
  font-size: clamp(2rem, 3vw, 3rem);
  letter-spacing: -0.055em;
  line-height: 1;
}

.jd-overview-head p {
  margin: 0;
}

.jd-overview-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 360px);
  gap: 18px;
  align-items: start;
}

.jd-today-panel {
  min-width: 0;
}

.jd-overview-side {
  display: grid;
  gap: 18px;
}

.jd-today-jobs {
  display: grid;
  gap: 10px;
}

.jd-today-job {
  overflow: hidden;
  border-radius: 18px;
  border: 1px solid rgba(22, 33, 42, 0.08);
  background: rgba(255, 255, 255, 0.96);
}

.jd-today-job[open] {
  border-color: rgba(22, 108, 119, 0.22);
  box-shadow: 0 14px 30px rgba(16, 24, 40, 0.07);
}

.jd-today-job-summary {
  list-style: none;
  cursor: pointer;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(190px, 0.38fr);
  gap: 18px;
  align-items: center;
  padding: 15px 17px;
}

.jd-today-job-summary::-webkit-details-marker {
  display: none;
}

.jd-today-job-summary::after {
  content: "Open";
  justify-self: end;
  grid-column: 1 / -1;
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--accent);
}

.jd-today-job[open] > .jd-today-job-summary::after {
  content: "Sluiten";
}

.jd-today-job-main,
.jd-today-job-crew {
  display: grid;
  gap: 4px;
}

.jd-today-job-main strong {
  font-size: 1.08rem;
}

.jd-today-job-crew {
  justify-items: start;
}

.jd-today-job-detail {
  display: grid;
  gap: 14px;
  padding: 0 17px 17px;
  border-top: 1px solid rgba(22, 33, 42, 0.06);
  padding-top: 15px;
}

.jd-job-detail-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(145px, 1fr));
  gap: 10px;
}

.jd-job-detail-item {
  display: grid;
  gap: 5px;
  padding: 11px 12px;
  border-radius: 14px;
  background: rgba(22, 108, 119, 0.045);
  border: 1px solid rgba(22, 108, 119, 0.07);
}

.jd-job-description {
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(195, 95, 47, 0.06);
}

.jd-job-description p {
  margin: 6px 0 0;
  line-height: 1.5;
}

.jd-job-detail-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.jd-overview-empty {
  display: grid;
  gap: 6px;
  min-height: 130px;
  place-content: center;
  text-align: center;
  border-radius: 18px;
  border: 1px dashed rgba(22, 33, 42, 0.12);
  background: rgba(255, 255, 255, 0.55);
}

.jd-week-hours-card {
  position: sticky;
  top: 20px;
}

.jd-week-hours {
  display: grid;
  gap: 16px;
}

.jd-hours-primary {
  display: grid;
  gap: 5px;
  padding: 16px;
  border-radius: 18px;
  background:
    linear-gradient(
      180deg,
      rgba(22, 108, 119, 0.1),
      rgba(22, 108, 119, 0.04)
    );
}

.jd-hours-primary strong {
  font-size: 2rem;
  letter-spacing: -0.05em;
}

.jd-hours-progress {
  display: grid;
  gap: 8px;
}

.jd-hours-progress-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.jd-hours-progress-track {
  height: 9px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(22, 33, 42, 0.08);
}

.jd-hours-progress-track i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background:
    linear-gradient(
      90deg,
      var(--accent),
      rgba(22, 108, 119, 0.58)
    );
}

.jd-hours-small-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
}

.jd-hours-small-grid > div {
  display: grid;
  gap: 5px;
  padding: 12px;
  border-radius: 14px;
  border: 1px solid rgba(22, 33, 42, 0.07);
  background: rgba(255, 255, 255, 0.7);
}

.jd-planning-alert {
  max-width: 650px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 11px;
  align-items: center;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(195, 95, 47, 0.1);
  border: 1px solid rgba(195, 95, 47, 0.2);
}

.jd-planning-alert > div {
  display: grid;
  gap: 3px;
}

.jd-planning-alert > div > span {
  font-size: 0.85rem;
  color: var(--muted);
}

.jd-alert-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #c35f2f;
  box-shadow: 0 0 0 5px rgba(195, 95, 47, 0.1);
}

@media (max-width: 900px) {
  .jd-overview-layout {
    grid-template-columns: 1fr;
  }

  .jd-week-hours-card {
    position: static;
  }

  .jd-overview-head {
    flex-direction: column;
  }

  .jd-planning-alert {
    width: 100%;
    max-width: none;
  }
}

@media (max-width: 620px) {
  .jd-today-job-summary {
    grid-template-columns: 1fr;
  }

  .jd-hours-small-grid {
    grid-template-columns: 1fr 1fr;
  }

  .jd-planning-alert {
    grid-template-columns: auto 1fr;
  }

  .jd-planning-alert button {
    grid-column: 1 / -1;
    width: 100%;
  }
}


/* =========================================================
   JD STEIGERS - VANDAAG COMMAND CENTER V2
   ========================================================= */

.jd-command-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 16px;
}

.jd-command-stat {
  display: grid;
  gap: 3px;
  min-height: 105px;
  padding: 15px 16px;
  border-radius: 18px;
  border: 1px solid rgba(22, 33, 42, 0.08);
  background:
    linear-gradient(
      180deg,
      rgba(255, 255, 255, 0.96),
      rgba(255, 255, 255, 0.86)
    );
}

.jd-command-stat strong {
  margin-top: 5px;
  font-size: 1.65rem;
  letter-spacing: -0.05em;
}

.jd-command-stat > span:last-child {
  font-size: 0.8rem;
  color: var(--muted);
}

.jd-command-planning.ok {
  border-color: rgba(22, 108, 119, 0.18);
  background:
    linear-gradient(
      180deg,
      rgba(22, 108, 119, 0.1),
      rgba(22, 108, 119, 0.035)
    );
}

.jd-command-planning.attention {
  border-color: rgba(195, 95, 47, 0.25);
  background:
    linear-gradient(
      180deg,
      rgba(195, 95, 47, 0.12),
      rgba(195, 95, 47, 0.04)
    );
}

.jd-attention-card {
  padding-bottom: 18px;
}

#jd-attention-list {
  display: grid;
  gap: 8px;
}

.jd-attention-item,
.jd-attention-ok {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  padding: 11px 12px;
  border-radius: 14px;
}

.jd-attention-item {
  border: 1px solid rgba(195, 95, 47, 0.14);
  background: rgba(195, 95, 47, 0.055);
}

.jd-attention-item > div,
.jd-attention-ok > div {
  display: grid;
  gap: 3px;
}

.jd-attention-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #c35f2f;
}

.jd-attention-ok {
  border: 1px solid rgba(22, 108, 119, 0.12);
  background: rgba(22, 108, 119, 0.05);
}

.jd-attention-check {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: rgba(22, 108, 119, 0.12);
  color: var(--accent);
  font-weight: 800;
}

@media (max-width: 1100px) {
  .jd-command-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 620px) {
  .jd-command-strip {
    grid-template-columns: 1fr 1fr;
  }

  .jd-command-stat {
    min-height: 96px;
    padding: 13px;
  }
}


/* =========================================================
   JD STEIGERS - OVERZICHT DONKERE COMMAND CENTER STIJL
   ========================================================= */

/* Hoofd KPI blokken */
#view-dashboard .jd-command-stat {
  color: rgba(255,255,255,.94);
  border: 1px solid rgba(255,255,255,.08);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.045),
    0 10px 28px rgba(0,0,0,.12);
}

#view-dashboard .jd-command-stat .label,
#view-dashboard .jd-command-stat > span:last-child {
  color: rgba(215,228,241,.68);
}

/* Vandaag */
#view-dashboard .jd-command-stat:nth-child(1) {
  background:
    radial-gradient(circle at 10% 10%, rgba(25,206,185,.18), transparent 45%),
    linear-gradient(145deg, rgba(14,68,71,.96), rgba(10,43,54,.96));
  border-color: rgba(41,216,197,.25);
}

/* Bezetting */
#view-dashboard .jd-command-stat:nth-child(2) {
  background:
    radial-gradient(circle at 10% 10%, rgba(67,135,255,.18), transparent 45%),
    linear-gradient(145deg, rgba(20,52,93,.97), rgba(15,37,67,.96));
  border-color: rgba(83,144,255,.25);
}

/* Deze week */
#view-dashboard .jd-command-stat:nth-child(3) {
  background:
    radial-gradient(circle at 10% 10%, rgba(154,102,255,.18), transparent 45%),
    linear-gradient(145deg, rgba(52,37,91,.97), rgba(35,27,70,.96));
  border-color: rgba(160,116,255,.26);
}

/* Volgende week */
#view-dashboard .jd-command-stat:nth-child(4) {
  background:
    radial-gradient(circle at 10% 10%, rgba(50,194,113,.18), transparent 45%),
    linear-gradient(145deg, rgba(18,69,52,.97), rgba(14,49,43,.96));
  border-color: rgba(57,199,118,.25);
}

#view-dashboard .jd-command-stat strong {
  color: #fff;
}


/* =========================================================
   KLUSSEN VANDAAG
   ========================================================= */

#view-dashboard .jd-today-job {
  background:
    linear-gradient(
      145deg,
      rgba(16,36,53,.98),
      rgba(12,29,44,.98)
    );
  border: 1px solid rgba(68,157,181,.15);
  color: rgba(244,249,255,.94);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.035),
    0 10px 28px rgba(0,0,0,.1);
}

#view-dashboard .jd-today-job:hover {
  border-color: rgba(47,207,188,.32);
  background:
    linear-gradient(
      145deg,
      rgba(18,43,61,.99),
      rgba(13,33,48,.99)
    );
}

#view-dashboard .jd-today-job[open] {
  border-color: rgba(47,207,188,.36);
  box-shadow:
    inset 3px 0 0 rgba(47,207,188,.7),
    0 14px 32px rgba(0,0,0,.16);
}

#view-dashboard .jd-today-job-summary {
  background: transparent;
}

#view-dashboard .jd-today-job-main strong,
#view-dashboard .jd-today-job-crew strong {
  color: rgba(250,253,255,.98);
}

#view-dashboard .jd-today-job .muted {
  color: rgba(190,208,223,.7);
}

#view-dashboard .jd-today-job .label {
  color: rgba(140,176,201,.78);
}

/* subtiele scheiding tussen klus en ploeg */
#view-dashboard .jd-today-job-crew {
  border-left: 1px solid rgba(255,255,255,.07);
  padding-left: 18px;
}

/* Open link */
#view-dashboard .jd-today-job-summary::after {
  color: #43dbc8;
}


/* =========================================================
   UITGEKLAPTE DETAILS
   ========================================================= */

#view-dashboard .jd-today-job-detail {
  border-top: 1px solid rgba(255,255,255,.07);
  background: rgba(5,18,29,.27);
}

#view-dashboard .jd-job-detail-item {
  background: rgba(255,255,255,.035);
  border: 1px solid rgba(255,255,255,.065);
  color: rgba(248,252,255,.93);
}

#view-dashboard .jd-job-description {
  background: rgba(213,116,58,.07);
  border: 1px solid rgba(213,116,58,.13);
}


/* =========================================================
   COMMAND CENTER / AANDACHT
   ========================================================= */

#view-dashboard .jd-attention-card,
#view-dashboard .jd-week-hours-card,
#view-dashboard .jd-today-panel {
  background:
    linear-gradient(
      160deg,
      rgba(10,25,39,.98),
      rgba(8,20,33,.98)
    );
  border-color: rgba(255,255,255,.07);
  color: rgba(245,249,255,.94);
}

#view-dashboard .jd-attention-card h2,
#view-dashboard .jd-week-hours-card h2,
#view-dashboard .jd-today-panel h2 {
  color: #fff;
}

#view-dashboard .jd-attention-ok {
  background: rgba(20,117,91,.12);
  border-color: rgba(46,209,168,.16);
}

#view-dashboard .jd-attention-ok strong {
  color: rgba(242,255,250,.96);
}


/* =========================================================
   WEEKUREN
   ========================================================= */

#view-dashboard .jd-hours-primary {
  background:
    radial-gradient(circle at 10% 0%, rgba(32,201,180,.1), transparent 50%),
    rgba(14,41,55,.72);
  border: 1px solid rgba(38,190,174,.09);
}

#view-dashboard .jd-hours-primary strong {
  color: #fff;
}

#view-dashboard .jd-hours-small-grid > div {
  background: rgba(255,255,255,.04);
  border-color: rgba(255,255,255,.07);
  color: #fff;
}

#view-dashboard .jd-hours-progress-track {
  background: rgba(255,255,255,.08);
}


/* =========================================================
   GEEN WITTE VLAKKEN MEER
   ========================================================= */

#view-dashboard .jd-overview-empty {
  background: rgba(255,255,255,.025);
  border-color: rgba(255,255,255,.08);
  color: rgba(240,247,252,.9);
}


/* mobiel */
@media (max-width: 720px) {
  #view-dashboard .jd-today-job-crew {
    border-left: 0;
    padding-left: 0;
    padding-top: 8px;
    border-top: 1px solid rgba(255,255,255,.06);
  }
}


/* =========================================================
   JD STEIGERS - AGENDA V2
   ========================================================= */

#view-agenda {
  max-width: 1600px;
}

.agenda-v2-shell {
  position: relative;
}

.agenda-v2-main {
  min-height: 720px;
  background:
    radial-gradient(
      circle at 0% 0%,
      rgba(42, 181, 172, 0.08),
      transparent 28%
    ),
    linear-gradient(
      160deg,
      rgba(9, 24, 37, 0.99),
      rgba(7, 18, 30, 0.99)
    );
  border: 1px solid rgba(255,255,255,.07);
  color: rgba(244,249,255,.95);
}

.agenda-v2-head {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: flex-start;
  margin-bottom: 18px;
}

.agenda-v2-head h1 {
  margin: 5px 0;
  color: #fff;
  font-size: clamp(2rem, 3vw, 3rem);
  letter-spacing: -.05em;
}

.agenda-v2-head p {
  margin: 0;
}

.agenda-v2-actions,
.agenda-v2-nav,
.agenda-v2-modes {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.agenda-v2-toolbar {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
  padding: 10px;
  margin-bottom: 12px;
  border-radius: 16px;
  background: rgba(255,255,255,.035);
  border: 1px solid rgba(255,255,255,.06);
}

.agenda-v2-modes .active {
  background: rgba(55, 208, 190, .16);
  border-color: rgba(55, 208, 190, .28);
  color: #bffcf5;
}

.agenda-v2-period {
  margin-bottom: 16px;
  font-size: 1.05rem;
  font-weight: 700;
  color: rgba(245,250,255,.92);
  text-transform: capitalize;
}


/* DAG */

.agenda-v2-day-grid {
  display: grid;
}

.agenda-v2-hour {
  display: grid;
  grid-template-columns: 66px minmax(0, 1fr);
  min-height: 68px;
}

.agenda-v2-hour-label {
  padding-top: 8px;
  color: rgba(179,199,218,.55);
  font-size: .76rem;
}

.agenda-v2-hour-content {
  display: grid;
  align-content: start;
  gap: 7px;
  min-width: 0;
  padding: 5px 0 8px 14px;
  border-top: 1px solid rgba(255,255,255,.055);
  border-left: 1px solid rgba(255,255,255,.055);
}

.agenda-v2-event {
  width: 100%;
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 11px 13px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.08);
  text-align: left;
  cursor: pointer;
  color: rgba(245,250,255,.95);
}

.agenda-v2-event:hover,
.agenda-v2-event.active {
  transform: translateY(-1px);
  border-color: rgba(255,255,255,.2);
}

.agenda-v2-event-time {
  font-size: .78rem;
  font-weight: 750;
  color: rgba(235,244,252,.84);
}

.agenda-v2-event-copy {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.agenda-v2-event-copy strong {
  color: #fff;
}

.agenda-v2-event-copy span {
  color: rgba(196,213,228,.68);
  font-size: .78rem;
}

.agenda-v2-event-status {
  font-size: .7rem;
  white-space: nowrap;
  opacity: .8;
}


/* STATUSKLEUREN */

.agenda-v2-event.scheduled,
.agenda-v2-month-item.scheduled,
.jd-dashboard-agenda-item.scheduled {
  background: rgba(25, 119, 119, .22);
  border-color: rgba(51, 207, 190, .22);
}

.agenda-v2-event.running,
.agenda-v2-month-item.running,
.jd-dashboard-agenda-item.running {
  background: rgba(39, 105, 185, .22);
  border-color: rgba(77, 145, 225, .26);
}

.agenda-v2-event.planning,
.agenda-v2-month-item.planning,
.jd-dashboard-agenda-item.planning {
  background: rgba(199, 118, 41, .19);
  border-color: rgba(223, 143, 60, .28);
}

.agenda-v2-event.done,
.agenda-v2-month-item.done,
.jd-dashboard-agenda-item.done {
  background: rgba(40, 151, 91, .18);
  border-color: rgba(56, 196, 118, .24);
}

.agenda-v2-event.urgent,
.agenda-v2-month-item.urgent,
.jd-dashboard-agenda-item.urgent {
  background: rgba(184, 61, 61, .18);
  border-color: rgba(219, 83, 83, .28);
}

.agenda-v2-event.warehouse,
.agenda-v2-month-item.warehouse,
.jd-dashboard-agenda-item.warehouse {
  background: rgba(120, 79, 181, .2);
  border-color: rgba(159, 112, 223, .27);
}


/* WEEK */

.agenda-v2-week {
  display: grid;
  grid-template-columns: repeat(7, minmax(150px, 1fr));
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 4px;
}

.agenda-v2-week-day {
  min-width: 150px;
  min-height: 500px;
  padding: 9px;
  border-radius: 16px;
  border: 1px solid rgba(255,255,255,.06);
  background: rgba(255,255,255,.025);
}

.agenda-v2-week-day.today {
  border-color: rgba(55,208,190,.25);
  background: rgba(55,208,190,.045);
}

.agenda-v2-week-head {
  width: 100%;
  display: grid;
  gap: 4px;
  padding: 8px;
  margin-bottom: 8px;
  border: 0;
  background: transparent;
  color: #fff;
  text-align: left;
  cursor: pointer;
}

.agenda-v2-week-events {
  display: grid;
  gap: 7px;
}

.agenda-v2-week .agenda-v2-event {
  grid-template-columns: 1fr;
  gap: 5px;
}

.agenda-v2-week .agenda-v2-event-status {
  white-space: normal;
}

.agenda-v2-week-empty {
  padding: 10px;
}


/* MAAND */

.agenda-v2-month-weekdays,
.agenda-v2-month-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 7px;
}

.agenda-v2-month-weekdays {
  margin-bottom: 7px;
}

.agenda-v2-month-weekdays span {
  padding: 5px 8px;
  color: rgba(184,204,221,.58);
  font-size: .72rem;
  text-transform: uppercase;
}

.agenda-v2-month-cell {
  min-height: 122px;
  display: grid;
  align-content: start;
  gap: 7px;
  padding: 9px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.06);
  background: rgba(255,255,255,.025);
  color: rgba(245,250,255,.92);
  text-align: left;
  cursor: pointer;
}

.agenda-v2-month-cell:hover {
  background: rgba(255,255,255,.045);
}

.agenda-v2-month-cell.today {
  border-color: rgba(55,208,190,.3);
  box-shadow: inset 0 0 0 1px rgba(55,208,190,.08);
}

.agenda-v2-month-cell.empty {
  opacity: .35;
  pointer-events: none;
}

.agenda-v2-month-day {
  display: flex;
  justify-content: space-between;
  gap: 6px;
}

.agenda-v2-month-day span {
  color: #55d8c8;
  font-size: .66rem;
}

.agenda-v2-month-items {
  display: grid;
  gap: 4px;
}

.agenda-v2-month-item {
  display: block;
  overflow: hidden;
  padding: 4px 6px;
  border-radius: 7px;
  font-size: .66rem;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.agenda-v2-more {
  font-size: .66rem;
  color: rgba(190,210,226,.64);
}


/* EMPTY */

.agenda-v2-empty {
  padding: 20px;
  margin-top: 8px;
  border-radius: 16px;
  border: 1px dashed rgba(255,255,255,.08);
  background: rgba(255,255,255,.02);
  text-align: center;
}


/* DETAIL DRAWER DONKER */

#view-agenda .agenda-side {
  background:
    linear-gradient(
      160deg,
      rgba(12,29,44,.99),
      rgba(7,18,30,.99)
    );
  border-color: rgba(255,255,255,.08);
  color: rgba(244,249,255,.94);
}

#view-agenda .agenda-detail-card,
#view-agenda .agenda-detail-block,
#view-agenda .agenda-detail-ops-block,
#view-agenda .project-note-card {
  background: rgba(255,255,255,.045);
  border-color: rgba(255,255,255,.07);
  color: rgba(244,249,255,.94);
}

#view-agenda .agenda-detail-card strong,
#view-agenda .agenda-detail-block strong {
  color: #fff;
}

.agenda-layout-compat {
  display: none !important;
}


/* =========================================================
   OVERZICHT - DAGPLANNING
   ========================================================= */

.jd-dashboard-agenda-card {
  margin-top: 14px;
  background:
    linear-gradient(
      160deg,
      rgba(10,25,39,.98),
      rgba(8,20,33,.98)
    );
  border-color: rgba(255,255,255,.07);
  color: rgba(245,249,255,.94);
}

.jd-dashboard-agenda-card h2 {
  color: #fff;
}

.jd-dashboard-agenda {
  display: grid;
  gap: 7px;
}

.jd-dashboard-agenda-item {
  width: 100%;
  display: grid;
  grid-template-columns: 70px minmax(0, 1fr) auto;
  align-items: center;
  gap: 11px;
  padding: 10px 12px;
  border-radius: 13px;
  border: 1px solid rgba(255,255,255,.07);
  color: rgba(245,250,255,.94);
  cursor: pointer;
  text-align: left;
}

.jd-dashboard-agenda-item:hover {
  border-color: rgba(55,208,190,.28);
}

.jd-dashboard-agenda-time {
  display: grid;
  gap: 2px;
}

.jd-dashboard-agenda-time strong {
  color: #fff;
}

.jd-dashboard-agenda-time span {
  font-size: .7rem;
  color: rgba(189,208,224,.58);
}

.jd-dashboard-agenda-copy {
  display: grid;
  gap: 3px;
}

.jd-dashboard-agenda-copy strong {
  color: #fff;
}

.jd-dashboard-agenda-status {
  font-size: .68rem;
  color: rgba(204,219,232,.7);
}

.jd-dashboard-agenda-empty {
  display: grid;
  gap: 4px;
  padding: 16px;
  border-radius: 14px;
  border: 1px dashed rgba(255,255,255,.08);
  text-align: center;
}


/* RESPONSIVE */

@media (max-width: 900px) {
  .agenda-v2-head,
  .agenda-v2-toolbar {
    flex-direction: column;
    align-items: stretch;
  }

  .agenda-v2-week {
    grid-template-columns: repeat(7, 170px);
  }
}

@media (max-width: 620px) {
  .agenda-v2-event {
    grid-template-columns: 70px minmax(0,1fr);
  }

  .agenda-v2-event-status {
    grid-column: 2;
  }

  .agenda-v2-month-grid,
  .agenda-v2-month-weekdays {
    min-width: 700px;
  }

  .agenda-v2-month {
    overflow-x: auto;
  }

  .jd-dashboard-agenda-item {
    grid-template-columns: 60px minmax(0,1fr);
  }

  .jd-dashboard-agenda-status {
    grid-column: 2;
  }
}


/* =========================================================
   JD STEIGERS — UI POLISH V4
   Overzicht + Agenda
   Alleen layout/styling, geen functionaliteit
   ========================================================= */


/* ---------------------------------------------------------
   ALGEMENE CONTENTBREEDTE
   --------------------------------------------------------- */

.main {
  min-width: 0;
}

#view-dashboard,
#view-agenda {
  width: 100%;
  max-width: none;
}

#view-dashboard {
  padding-bottom: 36px;
}


/* =========================================================
   OVERZICHT — COMMAND CENTER
   ========================================================= */

/* titel compacter */
#view-dashboard .jd-overview-head {
  margin-bottom: 14px;
  align-items: end;
}

#view-dashboard .jd-overview-head h1 {
  margin: 3px 0 3px;
  font-size: clamp(2rem, 2.7vw, 2.8rem);
}

#view-dashboard .jd-overview-head .muted {
  font-size: .82rem;
}


/* ---------------------------------------------------------
   KPI RIJ
   --------------------------------------------------------- */

#view-dashboard .jd-command-strip {
  grid-template-columns: repeat(4, minmax(150px, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

#view-dashboard .jd-command-stat {
  min-height: 82px;
  padding: 12px 14px;
  border-radius: 14px;
  align-content: center;
}

#view-dashboard .jd-command-stat strong {
  margin-top: 1px;
  font-size: 1.45rem;
  line-height: 1;
}

#view-dashboard .jd-command-stat .label {
  font-size: .68rem;
}

#view-dashboard .jd-command-stat > span:last-child {
  margin-top: 2px;
  font-size: .68rem;
}


/* ---------------------------------------------------------
   HOOFDLAYOUT

   links:
   - klussen
   - planning

   rechts:
   - aandacht
   - uren
   --------------------------------------------------------- */

#view-dashboard .jd-overview-layout {
  display: grid;
  grid-template-columns:
    minmax(520px, 1.65fr)
    minmax(290px, .62fr);
  grid-template-rows: auto auto;
  gap: 12px 14px;
  align-items: start;
}

/* Klussen links boven */
#view-dashboard .jd-today-panel {
  grid-column: 1;
  grid-row: 1;
  min-width: 0;
}

/* Dagplanning links direct eronder */
#view-dashboard .jd-dashboard-agenda-card {
  grid-column: 1;
  grid-row: 2;
  margin-top: 0;
  min-width: 0;
}

/* rechter kolom altijd naast het hoofdgedeelte */
#view-dashboard .jd-overview-side {
  grid-column: 2;
  grid-row: 1 / span 2;

  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;

  align-self: start;
}


/* ---------------------------------------------------------
   PANELS
   --------------------------------------------------------- */

#view-dashboard .jd-today-panel,
#view-dashboard .jd-dashboard-agenda-card,
#view-dashboard .jd-attention-card,
#view-dashboard .jd-week-hours-card {
  padding: 14px;
  border-radius: 18px;

  background:
    linear-gradient(
      155deg,
      rgba(12, 29, 43, .98),
      rgba(8, 20, 32, .99)
    );

  border: 1px solid rgba(122, 160, 184, .09);

  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.025),
    0 14px 34px rgba(0,0,0,.08);
}

/* subtiele gekleurde bovenrand */
#view-dashboard .jd-today-panel::before,
#view-dashboard .jd-dashboard-agenda-card::before,
#view-dashboard .jd-attention-card::before,
#view-dashboard .jd-week-hours-card::before {
  content: "";
  display: block;
  height: 2px;
  margin: -14px -14px 12px;
  border-radius: 18px 18px 0 0;

  background:
    linear-gradient(
      90deg,
      rgba(39,201,185,.22),
      rgba(52,124,214,.2),
      rgba(213,101,51,.55)
    );
}

#view-dashboard .panel-head {
  margin-bottom: 10px;
}

#view-dashboard .panel-head h2 {
  margin-top: 2px;
  font-size: 1.05rem;
  letter-spacing: -.025em;
}


/* ---------------------------------------------------------
   KLUSKAARTEN
   --------------------------------------------------------- */

#view-dashboard .jd-today-jobs {
  gap: 8px;
}

#view-dashboard .jd-today-job {
  border-radius: 14px;

  background:
    radial-gradient(
      circle at 0 0,
      rgba(31, 125, 160, .095),
      transparent 42%
    ),
    linear-gradient(
      145deg,
      rgba(15, 41, 60, .98),
      rgba(11, 31, 48, .98)
    );

  border: 1px solid rgba(73, 148, 177, .13);

  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.02);
}

#view-dashboard .jd-today-job:hover {
  border-color: rgba(57, 213, 194, .3);
  transform: translateY(-1px);
}

#view-dashboard .jd-today-job-summary {
  grid-template-columns: minmax(0,1fr) 185px;
  padding: 13px 14px;
  gap: 15px;
}

#view-dashboard .jd-today-job-main strong {
  font-size: .91rem;
  line-height: 1.3;
}

#view-dashboard .jd-today-job .label {
  font-size: .64rem;
}

#view-dashboard .jd-today-job .muted {
  font-size: .72rem;
}

#view-dashboard .jd-today-job-crew {
  gap: 3px;
  padding-left: 14px;
}

#view-dashboard .jd-today-job-summary::after {
  margin-top: -4px;
  font-size: .66rem;
}


/* ---------------------------------------------------------
   DAGPLANNING OP OVERZICHT
   --------------------------------------------------------- */

#view-dashboard .jd-dashboard-agenda {
  gap: 6px;
}

#view-dashboard .jd-dashboard-agenda-item {
  grid-template-columns: 66px minmax(0,1fr) auto;
  gap: 10px;

  padding: 10px 11px;
  border-radius: 12px;

  background: rgba(255,255,255,.028);

  transition:
    border-color .15s ease,
    background .15s ease,
    transform .15s ease;
}

#view-dashboard .jd-dashboard-agenda-item:hover {
  transform: translateY(-1px);
  background: rgba(255,255,255,.045);
}

#view-dashboard .jd-dashboard-agenda-time strong {
  font-size: .85rem;
}

#view-dashboard .jd-dashboard-agenda-copy > strong {
  font-size: .82rem;
}

#view-dashboard .jd-dashboard-agenda-copy .muted {
  font-size: .69rem;
}


/* ---------------------------------------------------------
   AANDACHT
   --------------------------------------------------------- */

#view-dashboard #jd-attention-list {
  gap: 6px;
}

#view-dashboard .jd-attention-ok,
#view-dashboard .jd-attention-item {
  padding: 10px;
  border-radius: 12px;
}

#view-dashboard .jd-attention-ok strong,
#view-dashboard .jd-attention-item strong {
  font-size: .79rem;
}

#view-dashboard .jd-attention-ok .muted,
#view-dashboard .jd-attention-item .muted {
  font-size: .68rem;
}


/* ---------------------------------------------------------
   WEEKUREN COMPACTER
   --------------------------------------------------------- */

#view-dashboard .jd-week-hours {
  gap: 12px;
}

#view-dashboard .jd-hours-primary {
  padding: 13px;
  border-radius: 13px;
}

#view-dashboard .jd-hours-primary strong {
  font-size: 1.65rem;
}

#view-dashboard .jd-hours-primary .muted {
  font-size: .69rem;
}

#view-dashboard .jd-hours-small-grid {
  gap: 6px;
}

#view-dashboard .jd-hours-small-grid > div {
  padding: 9px 10px;
  border-radius: 11px;
}

#view-dashboard .jd-hours-small-grid strong {
  font-size: .79rem;
}


/* =========================================================
   AGENDA V2 — POLISH
   ========================================================= */

#view-agenda .agenda-v2-main {
  min-height: calc(100vh - 125px);
  padding: 16px;

  border-radius: 20px;

  background:
    radial-gradient(
      circle at 0 0,
      rgba(31, 132, 139, .08),
      transparent 30%
    ),
    linear-gradient(
      155deg,
      rgba(10, 25, 38, .995),
      rgba(7, 18, 29, .995)
    );
}


/* header minder groot */
#view-agenda .agenda-v2-head {
  margin-bottom: 12px;
}

#view-agenda .agenda-v2-head h1 {
  margin: 2px 0 2px;
  font-size: clamp(2rem, 2.8vw, 2.75rem);
}

#view-agenda .agenda-v2-head p {
  font-size: .76rem;
}


/* ---------------------------------------------------------
   TOOLBAR
   --------------------------------------------------------- */

#view-agenda .agenda-v2-toolbar {
  min-height: 46px;
  padding: 6px 8px;
  margin-bottom: 10px;

  border-radius: 13px;

  background:
    rgba(255,255,255,.028);

  border-color:
    rgba(255,255,255,.055);
}

#view-agenda .agenda-v2-toolbar button {
  min-height: 32px;
  border-radius: 10px;
}

#view-agenda .agenda-v2-modes {
  gap: 5px;
}

#view-agenda .agenda-v2-modes button.active {
  background:
    linear-gradient(
      135deg,
      rgba(37, 135, 143, .42),
      rgba(31, 94, 126, .33)
    );

  border-color: rgba(67, 205, 191, .25);

  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.06);
}

#view-agenda .agenda-v2-period {
  margin: 2px 0 10px;
  font-size: .84rem;
}


/* =========================================================
   DAGWEERGAVE
   ========================================================= */

#view-agenda .agenda-v2-day {
  border-top:
    1px solid rgba(255,255,255,.04);
}

#view-agenda .agenda-v2-hour {
  grid-template-columns: 54px minmax(0, 1fr);
  min-height: 56px;
}

#view-agenda .agenda-v2-hour-label {
  padding-top: 7px;
  font-size: .65rem;
  color: rgba(177,199,216,.52);
}

#view-agenda .agenda-v2-hour-content {
  min-height: 56px;
  padding:
    5px 0 7px 12px;

  border-top:
    1px solid rgba(255,255,255,.045);

  border-left:
    1px solid rgba(255,255,255,.04);
}


/* events verfijnd */
#view-agenda .agenda-v2-event {
  grid-template-columns:
    78px
    minmax(0,1fr)
    auto;

  padding: 9px 11px;

  border-radius: 11px;

  box-shadow:
    inset 3px 0 0 rgba(255,255,255,.09),
    0 5px 15px rgba(0,0,0,.08);
}

#view-agenda .agenda-v2-event-time {
  font-size: .68rem;
}

#view-agenda .agenda-v2-event-copy strong {
  font-size: .79rem;
}

#view-agenda .agenda-v2-event-copy span,
#view-agenda .agenda-v2-event-status {
  font-size: .65rem;
}


/* =========================================================
   WEEKWEERGAVE
   ========================================================= */

#view-agenda .agenda-v2-week {
  gap: 6px;
}

#view-agenda .agenda-v2-week-day {
  min-height: 445px;

  padding: 7px;

  border-radius: 13px;

  background:
    linear-gradient(
      180deg,
      rgba(255,255,255,.026),
      rgba(255,255,255,.014)
    );
}

#view-agenda .agenda-v2-week-day.today {
  background:
    linear-gradient(
      180deg,
      rgba(35, 135, 139, .105),
      rgba(35, 135, 139, .035)
    );
}

#view-agenda .agenda-v2-week-head {
  padding: 6px;
  margin-bottom: 7px;
}

#view-agenda .agenda-v2-week-head strong {
  font-size: .84rem;
}


/* =========================================================
   MAANDWEERGAVE
   ========================================================= */

#view-agenda .agenda-v2-month-weekdays,
#view-agenda .agenda-v2-month-grid {
  gap: 5px;
}

#view-agenda .agenda-v2-month-cell {
  min-height: 103px;

  padding: 7px;

  border-radius: 11px;

  background:
    linear-gradient(
      180deg,
      rgba(255,255,255,.026),
      rgba(255,255,255,.015)
    );
}

#view-agenda .agenda-v2-month-cell.today {
  background:
    linear-gradient(
      180deg,
      rgba(31, 132, 139, .12),
      rgba(31, 132, 139, .035)
    );
}

#view-agenda .agenda-v2-month-day strong {
  font-size: .76rem;
}

#view-agenda .agenda-v2-month-item {
  padding: 3px 5px;
  font-size: .6rem;
}


/* =========================================================
   AGENDA STATUSKLEUREN IETS MOOIER
   ========================================================= */

#view-agenda .agenda-v2-event.scheduled,
#view-dashboard .jd-dashboard-agenda-item.scheduled {
  background:
    linear-gradient(
      135deg,
      rgba(21, 107, 111, .34),
      rgba(15, 72, 92, .26)
    );
}

#view-agenda .agenda-v2-event.running,
#view-dashboard .jd-dashboard-agenda-item.running {
  background:
    linear-gradient(
      135deg,
      rgba(43, 105, 180, .34),
      rgba(28, 69, 128, .26)
    );
}

#view-agenda .agenda-v2-event.planning,
#view-dashboard .jd-dashboard-agenda-item.planning {
  background:
    linear-gradient(
      135deg,
      rgba(181, 105, 40, .32),
      rgba(113, 67, 29, .25)
    );
}

#view-agenda .agenda-v2-event.done,
#view-dashboard .jd-dashboard-agenda-item.done {
  background:
    linear-gradient(
      135deg,
      rgba(34, 137, 83, .3),
      rgba(24, 86, 62, .24)
    );
}

#view-agenda .agenda-v2-event.warehouse,
#view-dashboard .jd-dashboard-agenda-item.warehouse {
  background:
    linear-gradient(
      135deg,
      rgba(116, 78, 170, .3),
      rgba(75, 52, 119, .24)
    );
}


/* =========================================================
   RESPONSIVE
   ========================================================= */

@media (max-width: 1120px) {

  #view-dashboard .jd-overview-layout {
    grid-template-columns:
      minmax(0,1fr)
      285px;
  }

  #view-dashboard .jd-command-strip {
    grid-template-columns:
      repeat(2, minmax(0,1fr));
  }
}


@media (max-width: 850px) {

  #view-dashboard .jd-overview-layout {
    grid-template-columns: 1fr;
    grid-template-rows: auto;
  }

  #view-dashboard .jd-today-panel,
  #view-dashboard .jd-dashboard-agenda-card,
  #view-dashboard .jd-overview-side {
    grid-column: 1;
    grid-row: auto;
  }

  #view-dashboard .jd-overview-side {
    grid-template-columns:
      repeat(2, minmax(0,1fr));
  }
}


@media (max-width: 620px) {

  #view-dashboard .jd-command-strip {
    grid-template-columns:
      repeat(2, minmax(0,1fr));
  }

  #view-dashboard .jd-overview-side {
    grid-template-columns: 1fr;
  }

  #view-dashboard .jd-today-job-summary {
    grid-template-columns: 1fr;
  }

  #view-dashboard .jd-today-job-crew {
    padding-left: 0;
  }

  #view-agenda .agenda-v2-main {
    padding: 12px;
  }
}


/* =========================================================
   JD STEIGERS - KLUS PLANNING EDITOR
   ========================================================= */

#view-jobs .job-schedule-editor {
  display: grid;
  grid-template-columns:
    minmax(150px, 1.35fr)
    minmax(100px, .75fr)
    minmax(100px, .75fr)
    auto;

  gap: 8px;
  align-items: end;

  margin-top: 12px;
  padding-top: 12px;

  border-top:
    1px solid rgba(255,255,255,.06);
}

#view-jobs .job-schedule-editor label {
  display: grid;
  gap: 5px;
}

#view-jobs .job-schedule-editor input {
  width: 100%;
  min-height: 38px;

  padding: 7px 9px;

  border-radius: 10px;

  border:
    1px solid rgba(255,255,255,.09);

  background:
    rgba(255,255,255,.045);

  color:
    rgba(245,250,255,.95);
}

#view-jobs .job-schedule-editor input:focus {
  outline: none;

  border-color:
    rgba(57,211,193,.4);

  box-shadow:
    0 0 0 3px rgba(57,211,193,.08);
}

@media (max-width: 760px) {
  #view-jobs .job-schedule-editor {
    grid-template-columns: 1fr 1fr;
  }

  #view-jobs .job-schedule-editor label:first-child,
  #view-jobs .job-schedule-editor button {
    grid-column: 1 / -1;
  }
}


/* =========================================================
   KLUSSEN - PLANNING FLOW
   ========================================================= */

#view-jobs .job-schedule-editor {
  margin-top: 14px;
  padding: 13px;

  border: 1px solid rgba(59, 192, 180, .11);
  border-radius: 13px;

  background:
    linear-gradient(
      135deg,
      rgba(24, 91, 99, .09),
      rgba(255,255,255,.018)
    );
}

#view-jobs .job-schedule-editor::before {
  content: "Uitvoering plannen";

  grid-column: 1 / -1;

  margin-bottom: 1px;

  color: rgba(105, 219, 206, .82);

  font-size: .68rem;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}

#view-jobs .job-awaiting-approval {
  margin-top: 9px;
  padding: 10px 11px;

  border-radius: 11px;

  border:
    1px solid rgba(215, 135, 60, .14);

  background:
    rgba(190, 105, 39, .07);
}

#view-jobs .job-awaiting-approval strong {
  color: rgba(247, 190, 129, .95);
}


/* =========================================================
   GEPLANDE KLUSSEN - BEWERKBARE PLANNING ALTIJD ZICHTBAAR
   ========================================================= */

#view-jobs .jobs-stage-running .job-card.expanded {
  overflow: visible;
}

#view-jobs .jobs-stage-running .job-schedule-editor {
  display: grid !important;

  grid-template-columns:
    minmax(160px, 1.2fr)
    minmax(110px, .7fr)
    minmax(110px, .7fr)
    auto;

  gap: 9px;

  margin-top: 14px;
  padding: 14px;

  border-radius: 14px;

  border:
    1px solid rgba(61, 207, 190, .18);

  background:
    linear-gradient(
      135deg,
      rgba(27, 104, 110, .13),
      rgba(14, 42, 57, .18)
    );
}

#view-jobs .jobs-stage-running .job-schedule-editor::before {
  content: "Planning aanpassen";

  grid-column: 1 / -1;

  color: rgba(105, 225, 212, .9);

  font-size: .68rem;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}

#view-jobs .jobs-stage-running .job-schedule-editor input {
  cursor: text;
}

#view-jobs .jobs-stage-running
.job-schedule-editor input[type="date"],
#view-jobs .jobs-stage-running
.job-schedule-editor input[type="time"] {
  color-scheme: dark;
}

@media (max-width: 760px) {
  #view-jobs .jobs-stage-running .job-schedule-editor {
    grid-template-columns: 1fr 1fr;
  }

  #view-jobs .jobs-stage-running
  .job-schedule-editor label:first-of-type,
  #view-jobs .jobs-stage-running
  .job-schedule-editor button {
    grid-column: 1 / -1;
  }
}


/* =========================================================
   JD EDITABLE PLANNING V3
   ========================================================= */

/* planningvelden moeten echte interactieve controls zijn */
#view-jobs [data-job-plan-date],
#view-jobs [data-job-plan-start],
#view-jobs [data-job-plan-end] {
  position: relative;
  z-index: 5;

  pointer-events: auto !important;
  user-select: auto !important;

  cursor: text !important;
}

/* macOS date/time controls */
#view-jobs input[type="date"],
#view-jobs input[type="time"],
#view-agenda input[type="date"],
#view-agenda input[type="time"] {
  appearance: auto;
  -webkit-appearance: auto;
  color-scheme: dark;
}


/* Agenda editor */

#view-agenda .jd-agenda-edit-panel {
  margin-top: 14px;

  border:
    1px solid rgba(54, 207, 190, .18);

  background:
    linear-gradient(
      145deg,
      rgba(22, 78, 88, .14),
      rgba(255,255,255,.025)
    );
}

#view-agenda .jd-agenda-edit-grid {
  display: grid;

  grid-template-columns:
    minmax(160px, 1.25fr)
    minmax(110px, .8fr)
    minmax(110px, .8fr);

  gap: 9px;

  margin-top: 12px;
}

#view-agenda .jd-agenda-edit-grid label {
  display: grid;
  gap: 5px;
}

#view-agenda .jd-agenda-edit-grid input {
  width: 100%;

  min-height: 40px;

  padding: 8px 10px;

  border-radius: 10px;

  border:
    1px solid rgba(255,255,255,.1);

  background:
    rgba(255,255,255,.045);

  color:
    rgba(247,251,255,.96);
}

#view-agenda .jd-agenda-edit-grid input:focus {
  outline: none;

  border-color:
    rgba(61, 215, 197, .44);

  box-shadow:
    0 0 0 3px
    rgba(61, 215, 197, .08);
}

#view-agenda .jd-agenda-edit-actions {
  margin-top: 12px;
}

@media (max-width: 700px) {
  #view-agenda .jd-agenda-edit-grid {
    grid-template-columns: 1fr;
  }
}


/* =========================================================
   JD AGENDA EDIT + DELETE V4
   ========================================================= */

#view-agenda .jd-agenda-editor-v4 {
  margin-top: 14px;

  border:
    1px solid rgba(55, 208, 190, .2);

  background:
    linear-gradient(
      145deg,
      rgba(22, 82, 91, .17),
      rgba(11, 30, 44, .48)
    );
}

#view-agenda .jd-agenda-editor-v4 h3 {
  color: #fff;
}

#view-agenda .jd-agenda-editor-grid {
  display: grid;

  grid-template-columns:
    minmax(170px, 1.25fr)
    minmax(110px, .8fr)
    minmax(110px, .8fr);

  gap: 9px;

  margin-top: 13px;
}

#view-agenda .jd-agenda-editor-grid label {
  display: grid;
  gap: 5px;
}

#view-agenda .jd-agenda-editor-grid input {
  width: 100%;
  min-height: 42px;

  padding: 8px 10px;

  border-radius: 10px;

  border:
    1px solid rgba(255,255,255,.11);

  background:
    rgba(255,255,255,.05);

  color:
    rgba(247,251,255,.97);

  color-scheme: dark;

  pointer-events: auto !important;
  user-select: auto !important;

  position: relative;
  z-index: 4;
}

#view-agenda .jd-agenda-editor-grid input:focus {
  outline: none;

  border-color:
    rgba(61, 216, 198, .52);

  box-shadow:
    0 0 0 3px
    rgba(61,216,198,.09);
}

#view-agenda .jd-agenda-editor-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;

  margin-top: 14px;
}

#view-agenda .jd-agenda-delete-button {
  border-color:
    rgba(222, 82, 82, .2);

  color:
    rgba(255, 173, 173, .95);

  background:
    rgba(173, 48, 48, .08);
}

#view-agenda .jd-agenda-delete-button:hover {
  border-color:
    rgba(231, 86, 86, .4);

  background:
    rgba(183, 51, 51, .15);
}

@media (max-width: 700px) {
  #view-agenda .jd-agenda-editor-grid {
    grid-template-columns: 1fr;
  }
}


/* =========================================================
   JD AGENDA INLINE EXPAND EDITOR V6
   ========================================================= */

/*
 * Oude zijpaneel-editors niet meer tonen.
 * De inline editor neemt deze functie over.
 */
#view-agenda .jd-agenda-editor-v4,
#view-agenda .jd-agenda-edit-panel {
  display: none !important;
}


/*
 * Aangeklikte klus duidelijk actief maken.
 */
#view-agenda [data-agenda-item] {
  cursor: pointer !important;
  transition:
    border-color .15s ease,
    background .15s ease;
}

#view-agenda [data-agenda-item].jd-agenda-event-open {
  border-color:
    rgba(77, 218, 201, .58) !important;

  box-shadow:
    0 0 0 1px
    rgba(77, 218, 201, .1);
}


/*
 * Dit staat DIRECT onder de aangeklikte klus.
 */
#view-agenda .jd-agenda-inline-editor {
  display: grid;
  gap: 14px;

  width: 100%;

  margin:
    5px 0 10px;

  padding:
    16px;

  border-radius:
    14px;

  border:
    1px solid rgba(61, 207, 191, .28);

  background:
    linear-gradient(
      145deg,
      rgba(16, 47, 61, .98),
      rgba(11, 28, 42, .98)
    );

  box-shadow:
    0 12px 28px
    rgba(0,0,0,.22);

  position: relative;
  z-index: 30;
}


#view-agenda .jd-agenda-inline-head {
  display: flex;

  justify-content:
    space-between;

  align-items:
    flex-start;

  gap:
    16px;
}


#view-agenda .jd-agenda-inline-title {
  display: grid;
  gap: 3px;

  min-width: 0;
}


#view-agenda .jd-agenda-inline-title strong {
  color:
    rgba(248,252,255,.98);

  font-size:
    .95rem;
}


#view-agenda .jd-agenda-inline-fields {
  display: grid;

  grid-template-columns:
    minmax(150px, 1.15fr)
    minmax(105px, .7fr)
    minmax(105px, .7fr)
    minmax(140px, 1fr);

  gap:
    9px;
}


#view-agenda .jd-agenda-inline-fields label {
  display: grid;

  gap:
    5px;

  min-width:
    0;
}


#view-agenda .jd-agenda-inline-fields input,
#view-agenda .jd-agenda-inline-fields select {
  width:
    100%;

  min-height:
    40px;

  padding:
    7px 9px;

  border-radius:
    9px;

  border:
    1px solid rgba(255,255,255,.11);

  background:
    rgba(255,255,255,.055);

  color:
    rgba(248,252,255,.97);

  color-scheme:
    dark;

  pointer-events:
    auto !important;
}


#view-agenda .jd-agenda-inline-fields input:focus,
#view-agenda .jd-agenda-inline-fields select:focus {
  outline:
    none;

  border-color:
    rgba(65, 219, 201, .58);

  box-shadow:
    0 0 0 3px
    rgba(65,219,201,.09);
}


#view-agenda .jd-agenda-inline-actions {
  display:
    flex;

  flex-wrap:
    wrap;

  gap:
    8px;
}


#view-agenda .jd-inline-back-planning,
#view-agenda .jd-inline-delete {
  border-color:
    rgba(218, 140, 64, .24);

  color:
    rgba(250, 194, 133, .96);

  background:
    rgba(175, 99, 34, .08);
}


/*
 * Het oude detailpaneel mag niet ineens de pagina
 * extreem breed maken wanneer de inline editor actief is.
 */
#view-agenda:has(.jd-agenda-inline-editor)
.agenda-side {
  display:
    none !important;
}


@media (max-width: 760px) {

  #view-agenda .jd-agenda-inline-fields {
    grid-template-columns:
      1fr 1fr;
  }

}


@media (max-width: 520px) {

  #view-agenda .jd-agenda-inline-fields {
    grid-template-columns:
      1fr;
  }

  #view-agenda .jd-agenda-inline-head {
    display:
      grid;
  }

}



/* ==========================================================
   JD HOURS V2
   ========================================================== */

#view-hours {
  background:transparent;
}

.jd-hours-v2 {
  display:grid;
  gap:14px;
}

.jd-hours-v2-head {
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:20px;
  padding:18px 20px;
  border:1px solid rgba(255,255,255,.08);
  border-radius:18px;
  background:
    linear-gradient(
      145deg,
      rgba(255,255,255,.055),
      rgba(255,255,255,.018)
    );
}

.jd-hours-v2-head h2 {
  margin:3px 0 4px;
  font-size:24px;
}

.jd-hours-v2-head p {
  margin:0;
  opacity:.65;
}

.jd-hours-summary {
  display:grid;
  grid-template-columns:repeat(3,minmax(105px,1fr));
  gap:8px;
}

.jd-hours-summary > div {
  min-width:105px;
  padding:10px 12px;
  border-radius:13px;
  background:rgba(255,255,255,.045);
  border:1px solid rgba(255,255,255,.065);
}

.jd-hours-summary span {
  display:block;
  margin-bottom:4px;
  font-size:11px;
  opacity:.58;
}

.jd-hours-summary strong {
  display:block;
  font-size:18px;
}

.jd-hours-section {
  overflow:hidden;
  border-radius:18px;
  border:1px solid rgba(255,255,255,.075);
  background:rgba(255,255,255,.025);
}

.jd-hours-section-head {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:14px;
  padding:13px 16px;
  border-bottom:1px solid rgba(255,255,255,.06);
}

.jd-hours-section-title {
  font-size:15px;
  font-weight:750;
}

.jd-hours-section-subtitle {
  margin-top:2px;
  font-size:12px;
  opacity:.55;
}

.jd-hours-count {
  display:grid;
  place-items:center;
  min-width:30px;
  height:30px;
  padding:0 8px;
  border-radius:10px;
  background:rgba(255,255,255,.06);
  font-size:13px;
  font-weight:750;
}

.jd-hours-list {
  display:grid;
}

.jd-hours-card {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  padding:13px 16px;
  border-bottom:1px solid rgba(255,255,255,.055);
}

.jd-hours-card:last-child {
  border-bottom:0;
}

.jd-hours-card:hover {
  background:rgba(255,255,255,.025);
}

.jd-hours-card-main {
  display:flex;
  align-items:center;
  min-width:0;
  gap:12px;
}

.jd-hours-avatar {
  display:grid;
  place-items:center;
  flex:0 0 38px;
  width:38px;
  height:38px;
  border-radius:12px;
  background:rgba(255,255,255,.07);
  font-size:14px;
  font-weight:800;
}

.jd-hours-card-copy {
  min-width:0;
}

.jd-hours-worker {
  font-size:14px;
  font-weight:750;
}

.jd-hours-project {
  margin-top:2px;
  max-width:560px;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
  font-size:12px;
  opacity:.68;
}

.jd-hours-meta {
  display:flex;
  align-items:center;
  gap:7px;
  margin-top:5px;
  font-size:11px;
  opacity:.58;
}

.jd-hours-meta strong {
  opacity:1;
}

.jd-hours-dot {
  opacity:.35;
}

.jd-hours-card-actions {
  display:flex;
  align-items:center;
  justify-content:flex-end;
  flex-wrap:wrap;
  gap:7px;
}

.jd-hours-status {
  display:inline-flex;
  align-items:center;
  min-height:29px;
  padding:0 10px;
  border-radius:999px;
  border:1px solid rgba(255,255,255,.08);
  font-size:11px;
  font-weight:700;
}

.jd-hours-status.is-pending {
  background:rgba(255,180,70,.10);
}

.jd-hours-status.is-approved {
  background:rgba(80,210,145,.10);
}

.jd-hours-status.is-open {
  background:rgba(100,160,255,.08);
}

.jd-hours-section.pending {
  border-color:rgba(255,180,70,.14);
}

.jd-hours-section.approved {
  border-color:rgba(80,210,145,.12);
}

.jd-hours-empty {
  padding:22px 16px;
  text-align:center;
  font-size:12px;
  opacity:.48;
}

.jd-hours-card .button {
  min-height:30px;
  padding:0 10px;
  border-radius:9px;
  font-size:11px;
}

@media (max-width:900px) {
  .jd-hours-v2-head {
    flex-direction:column;
  }

  .jd-hours-summary {
    width:100%;
  }
}

@media (max-width:680px) {
  .jd-hours-summary {
    grid-template-columns:1fr;
  }

  .jd-hours-card {
    align-items:flex-start;
    flex-direction:column;
  }

  .jd-hours-card-actions {
    width:100%;
    justify-content:flex-start;
  }

  .jd-hours-project {
    white-space:normal;
  }
}


/* ==========================================================
   JD HOURS V3 WEEKMATRIX
   ========================================================== */

.jd-hours-v3 {
  display:grid;
  gap:14px;
}

.jd-hours-v3-top {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:18px;
  padding:16px 18px;
  border:1px solid rgba(255,255,255,.07);
  border-radius:18px;
  background:rgba(255,255,255,.025);
}

.jd-hours-v3-top h2 {
  margin:2px 0;
  font-size:23px;
}

.jd-hours-v3-top p {
  margin:0;
  font-size:12px;
  opacity:.55;
}

.jd-hours-week-nav {
  display:flex;
  gap:6px;
}

.jd-hours-week-nav button {
  min-height:34px;
  padding:0 12px;
  border:1px solid rgba(255,255,255,.09);
  border-radius:10px;
  background:rgba(255,255,255,.045);
  color:inherit;
  cursor:pointer;
}

.jd-hours-kpis {
  display:grid;
  grid-template-columns:repeat(4,1fr);
  gap:8px;
}

.jd-hours-kpis > div {
  padding:12px 14px;
  border:1px solid rgba(255,255,255,.07);
  border-radius:14px;
  background:rgba(255,255,255,.03);
}

.jd-hours-kpis span {
  display:block;
  margin-bottom:4px;
  font-size:11px;
  opacity:.55;
}

.jd-hours-kpis strong {
  font-size:19px;
}

.jd-hours-matrix-shell {
  overflow:auto;
  border:1px solid rgba(255,255,255,.075);
  border-radius:17px;
  background:rgba(255,255,255,.018);
}

.jd-hours-matrix-head,
.jd-hours-matrix-row {
  display:grid;
  grid-template-columns:
    minmax(175px,1.35fr)
    repeat(7,minmax(105px,1fr))
    minmax(75px,.65fr);
  min-width:1050px;
}

.jd-hours-matrix-head {
  position:sticky;
  top:0;
  z-index:2;
  background:#101923;
  border-bottom:1px solid rgba(255,255,255,.075);
}

.jd-hours-matrix-head > div {
  padding:10px;
  border-right:1px solid rgba(255,255,255,.05);
  font-size:11px;
  font-weight:700;
  opacity:.68;
}

.jd-hours-day-head {
  text-align:center;
}

.jd-hours-day-head span {
  display:block;
  text-transform:capitalize;
  font-size:10px;
  opacity:.6;
}

.jd-hours-day-head strong {
  display:block;
  margin-top:2px;
  font-size:14px;
}

.jd-hours-matrix-row {
  border-bottom:1px solid rgba(255,255,255,.055);
}

.jd-hours-matrix-row:last-child {
  border-bottom:0;
}

.jd-hours-worker-cell {
  display:flex;
  align-items:center;
  gap:9px;
  padding:9px 10px;
  border-right:1px solid rgba(255,255,255,.05);
}

.jd-hours-worker-cell strong {
  display:block;
  font-size:12px;
}

.jd-hours-worker-cell span {
  display:block;
  margin-top:2px;
  font-size:10px;
  opacity:.48;
}

.jd-hours-day-cell {
  position:relative;
  min-height:65px;
  padding:7px;
  border:0;
  border-right:1px solid rgba(255,255,255,.05);
  background:transparent;
  color:inherit;
  text-align:left;
  cursor:pointer;
}

.jd-hours-day-cell:hover {
  background:rgba(255,255,255,.045);
}

.jd-hours-day-cell.is-approved {
  background:rgba(61,190,120,.075);
}

.jd-hours-day-cell.is-pending {
  background:rgba(255,178,54,.085);
}

.jd-hours-day-cell.is-open.has-planning {
  background:rgba(69,132,255,.065);
}

.jd-hours-cell-main {
  display:block;
  font-size:13px;
  font-weight:800;
}

.jd-hours-cell-project {
  display:block;
  margin-top:4px;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
  font-size:9px;
  opacity:.55;
}

.jd-hours-cell-mark {
  position:absolute;
  top:6px;
  right:7px;
  font-size:10px;
  font-weight:900;
}

.jd-hours-week-total {
  display:flex;
  align-items:center;
  justify-content:center;
  padding:8px;
}

.jd-hours-week-total strong {
  font-size:13px;
}

.jd-hours-legend {
  display:flex;
  align-items:center;
  flex-wrap:wrap;
  gap:15px;
  padding:0 4px;
  font-size:10px;
  opacity:.62;
}

.jd-hours-legend span {
  display:flex;
  align-items:center;
  gap:6px;
}

.jd-hours-legend i {
  width:8px;
  height:8px;
  border-radius:50%;
  background:rgba(255,255,255,.2);
}

.jd-hours-legend i.approved {
  background:rgba(61,190,120,.8);
}

.jd-hours-legend i.pending {
  background:rgba(255,178,54,.9);
}

.jd-hours-legend i.open {
  background:rgba(69,132,255,.8);
}

.jd-hours-day-dialog {
  width:min(650px,calc(100vw - 28px));
  max-height:85vh;
  padding:0;
  border:1px solid rgba(255,255,255,.11);
  border-radius:18px;
  background:#101923;
  color:inherit;
}

.jd-hours-day-dialog::backdrop {
  background:rgba(0,0,0,.64);
}

.jd-hours-dialog-shell {
  padding:18px;
}

.jd-hours-dialog-head {
  display:flex;
  justify-content:space-between;
  gap:20px;
  padding-bottom:14px;
  border-bottom:1px solid rgba(255,255,255,.07);
}

.jd-hours-dialog-head > div > span {
  font-size:9px;
  font-weight:800;
  letter-spacing:.08em;
  opacity:.45;
}

.jd-hours-dialog-head h3 {
  margin:3px 0;
  font-size:21px;
}

.jd-hours-dialog-head p {
  margin:0;
  font-size:11px;
  opacity:.55;
}

.jd-hours-dialog-close {
  width:34px;
  height:34px;
  border:1px solid rgba(255,255,255,.08);
  border-radius:10px;
  background:rgba(255,255,255,.04);
  color:inherit;
  font-size:20px;
  cursor:pointer;
}

.jd-hours-dialog-block {
  padding-top:15px;
}

.jd-hours-dialog-block h4 {
  margin:0 0 8px;
  font-size:12px;
}

.jd-hours-planned-job,
.jd-hours-detail-row {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:14px;
  padding:11px 12px;
  border:1px solid rgba(255,255,255,.07);
  border-radius:12px;
  background:rgba(255,255,255,.025);
}

.jd-hours-planned-job span,
.jd-hours-planned-job small,
.jd-hours-detail-row small {
  display:block;
  font-size:10px;
  opacity:.5;
}

.jd-hours-detail-row + .jd-hours-detail-row {
  margin-top:7px;
}

.jd-hours-detail-row > div:first-child > span {
  display:block;
  margin-top:3px;
  font-size:12px;
}

.jd-hours-detail-actions {
  display:flex;
  align-items:center;
  flex-wrap:wrap;
  justify-content:flex-end;
  gap:6px;
}

.jd-hours-detail-empty {
  padding:15px;
  border:1px dashed rgba(255,255,255,.08);
  border-radius:12px;
  text-align:center;
  font-size:11px;
  opacity:.5;
}

@media (max-width:800px) {
  .jd-hours-kpis {
    grid-template-columns:repeat(2,1fr);
  }

  .jd-hours-v3-top {
    align-items:flex-start;
    flex-direction:column;
  }
}


/* ==========================================================
   JD FACTUREN V2
   ========================================================== */

#view-invoices {
  gap:14px;
}

#view-invoices.active {
  display:grid;
}

#view-invoices:not(.active) {
  display:none !important;
}

.invoice-v2-head {
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:18px;
  padding:17px 18px;
  border:1px solid rgba(255,255,255,.07);
  border-radius:18px;
  background:
    linear-gradient(
      145deg,
      rgba(255,255,255,.045),
      rgba(255,255,255,.018)
    );
}

.invoice-v2-head h2 {
  margin:3px 0 4px;
  font-size:24px;
}

.invoice-v2-head p {
  margin:0;
}

.invoice-v2-kpis {
  display:grid;
  grid-template-columns:
    repeat(4,minmax(110px,1fr));
  gap:8px;
}

.invoice-v2-kpi {
  min-width:115px;
  padding:10px 12px;
  border:1px solid rgba(255,255,255,.065);
  border-radius:13px;
  background:rgba(255,255,255,.035);
}

.invoice-v2-kpi span {
  display:block;
  margin-bottom:4px;
  font-size:10px;
  opacity:.55;
}

.invoice-v2-kpi strong {
  display:block;
  font-size:17px;
}

.invoice-v2-card {
  position:relative;
}

.invoice-v2-status {
  display:inline-flex;
  align-items:center;
  min-height:27px;
  padding:0 9px;
  border:1px solid rgba(255,255,255,.08);
  border-radius:999px;
  font-size:10px;
  font-weight:750;
  white-space:nowrap;
}

.invoice-status-paid {
  border-color:rgba(66,210,145,.18);
  background:rgba(66,210,145,.09);
}

.invoice-status-open,
.invoice-status-ready,
.invoice-status-sent {
  border-color:rgba(72,155,245,.16);
  background:rgba(72,155,245,.075);
}

.invoice-status-overdue,
.invoice-status-reminder {
  border-color:rgba(240,121,75,.22);
  background:rgba(240,121,75,.10);
}

.invoice-status-draft {
  border-color:rgba(255,255,255,.09);
  background:rgba(255,255,255,.035);
}

.invoice-status-archived {
  opacity:.55;
}

.invoice-v2-card.invoice-status-overdue {
  border-color:rgba(240,121,75,.18);
}

.invoice-v2-card.invoice-status-paid {
  border-color:rgba(66,210,145,.12);
}

.invoice-v2-archive {
  opacity:.88;
}

.invoice-v2-archive-card {
  padding:13px;
}

.invoice-v2-archive-card + .invoice-v2-archive-card {
  margin-top:8px;
}

.ghost.danger {
  border-color:rgba(240,90,90,.14);
  color:rgba(255,175,175,.86);
}

.ghost.danger:hover {
  background:rgba(240,90,90,.08);
}

@media (max-width:1050px) {
  .invoice-v2-head {
    flex-direction:column;
  }

  .invoice-v2-kpis {
    width:100%;
    grid-template-columns:repeat(2,1fr);
  }
}

@media (max-width:600px) {
  .invoice-v2-kpis {
    grid-template-columns:1fr;
  }
}
