.site-nav,
.site-nav *,
.site-nav *::before,
.site-nav *::after {
  box-sizing: border-box;
}

:root {
  --bg: #f6f7f9;
  --panel: #ffffff;
  --panel-soft: #fbfcfd;
  --text: #18202a;
  --muted: #697382;
  --border: #d9dee7;
  --border-strong: #c2cad6;
  --accent: #1468d8;
  --accent-dark: #0f55b3;
  --ok: #067647;
  --warning: #b54708;
  --issue: #b42318;
  --shadow: 0 12px 30px rgba(22, 34, 51, 0.08);
  --radius-sm: 6px;
  --radius-md: 8px;
  --focus-ring: 0 0 0 3px rgba(20, 104, 216, 0.12);
}

.site-nav {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  border-bottom: 1px solid rgba(194, 202, 214, 0.78);
  background: rgba(255, 255, 255, 0.92);
  padding: 10px 24px;
  backdrop-filter: blur(14px);
}

.site-nav-left {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.site-brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: #18202a;
  font-size: 14px;
  font-weight: 850;
  letter-spacing: 0;
  text-decoration: none;
  white-space: nowrap;
}

.site-brand-mark {
  display: inline-grid;
  width: 24px;
  height: 24px;
  place-items: center;
  border-radius: 7px;
  background: #1468d8;
  color: #fff;
  font-size: 12px;
  font-weight: 900;
}

.nav-clocks {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.nav-clock-pill {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
  border: 1px solid rgba(194, 202, 214, 0.7);
  border-radius: 999px;
  background: rgba(251, 252, 253, 0.86);
  color: #334155;
  padding: 2px 8px;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

.nav-clock-pill strong {
  font-size: 11px;
  font-weight: 800;
}

.site-nav-links {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  flex-wrap: wrap;
}

.site-nav-link {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  border: 1px solid transparent;
  border-radius: 7px;
  color: #465365;
  padding: 6px 10px;
  font-size: 12px;
  font-weight: 750;
  text-decoration: none;
  white-space: nowrap;
}

.site-nav-link:hover {
  border-color: #c2cad6;
  background: #fbfcfd;
  color: #18202a;
}

.site-nav-link.active {
  border-color: rgba(20, 104, 216, 0.18);
  background: #e8f1ff;
  color: #1468d8;
}

.site-nav-link.disabled {
  border-color: rgba(194, 202, 214, 0.45);
  background: #f3f5f8;
  color: #9aa4b2;
  cursor: default;
  pointer-events: none;
}

.site-nav-link:focus-visible,
.site-brand:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
}

:where(.app-shell, .trip-shell, .fc-shell, .home-shell) {
  max-width: none;
  margin-inline: auto;
}

:where(.button, .icon-button, .view-button, .resource-tab, .resource-view-tab, .detail-tab, .map-control-button):disabled,
:where(.button, .icon-button, .view-button, .resource-tab, .resource-view-tab, .detail-tab, .map-control-button).disabled {
  opacity: 0.58;
  cursor: not-allowed;
}

:where(input, select, textarea, button, a):focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
}

:where(.import-status.connected-text, .form-message.success) {
  color: var(--ok);
}

:where(.import-status.error-text, .form-message.error) {
  color: var(--issue);
}

:where(.empty-state, .detail-empty, .empty-row, .timeline-empty, .empty-task) {
  color: var(--muted);
}

:where(th) {
  letter-spacing: 0;
}

:where(td, th, label, .button, .site-nav-link) {
  line-height: 1.25;
}

@media (max-width: 720px) {
  .site-nav {
    align-items: flex-start;
    flex-direction: column;
    padding: 10px 14px;
  }

  .site-nav-left {
    width: 100%;
    flex-wrap: wrap;
  }

  .site-nav-links {
    justify-content: flex-start;
    width: 100%;
    overflow-x: auto;
    padding-bottom: 2px;
  }
}

@media (max-width: 520px) {
  .site-brand {
    width: 100%;
  }

  .site-nav-link {
    min-height: 34px;
  }
}
