:root {
  color-scheme: light;
  --sidebar-width: 286px;
  --sidebar-collapsed: 88px;
  --topbar-height: 88px;
  --font: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --page: #f4f2ff;
  --surface: #ffffff;
  --surface-soft: #f9f8ff;
  --line: #e4e1f3;
  --line-strong: #d7d2eb;
  --text: #242137;
  --muted: #838097;
  --purple: #6c5ce7;
  --purple-dark: #5847db;
  --purple-soft: #eeebff;
  --coral: #ff7867;
  --mint: #36bfa0;
  --sidebar: #3e326b;
  --sidebar-deep: #322956;
  --sidebar-text: #f8f7ff;
  --sidebar-muted: #b8afd6;
  --sidebar-hover: rgba(255, 255, 255, 0.08);
  --shadow: 0 12px 34px rgba(65, 49, 131, 0.08);
  --shadow-small: 0 6px 18px rgba(65, 49, 131, 0.08);
}

html[data-theme="dark"] {
  color-scheme: dark;
  --page: #171421;
  --surface: #211d2e;
  --surface-soft: #282338;
  --line: #383149;
  --line-strong: #49405e;
  --text: #f5f2ff;
  --muted: #aaa3bb;
  --purple: #8a78ff;
  --purple-dark: #7563ef;
  --purple-soft: #332b51;
  --sidebar: #261f43;
  --sidebar-deep: #201a38;
  --sidebar-text: #faf8ff;
  --sidebar-muted: #afa6ce;
  --sidebar-hover: rgba(255, 255, 255, 0.075);
  --shadow: 0 16px 38px rgba(0, 0, 0, 0.18);
  --shadow-small: 0 8px 20px rgba(0, 0, 0, 0.18);
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
  margin: 0;
}

body {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  min-width: 320px;
  overflow: hidden;
  background: var(--page);
  color: var(--text);
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  color: inherit;
  font: inherit;
}

button:focus-visible,
a:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--purple) 35%, transparent);
  outline-offset: 2px;
}

.app-shell {
  display: grid;
  height: 100vh;
  height: 100dvh;
  grid-template-columns: var(--sidebar-width) minmax(0, 1fr);
  min-height: 0;
  overflow: hidden;
  transition: grid-template-columns 220ms ease;
}

.sidebar {
  position: relative;
  z-index: 30;
  display: flex;
  min-width: 0;
  height: 100%;
  flex-direction: column;
  overflow: hidden;
  background:
    radial-gradient(circle at 20% -4%, rgba(137, 115, 255, 0.32), transparent 28%),
    linear-gradient(155deg, var(--sidebar) 0%, var(--sidebar-deep) 100%);
  color: var(--sidebar-text);
  box-shadow: 14px 0 36px rgba(38, 25, 80, 0.09);
}

.brand-row {
  display: flex;
  min-height: var(--topbar-height);
  align-items: center;
  justify-content: space-between;
  padding: 0 22px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.brand {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 13px;
  color: inherit;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 43px;
  height: 43px;
  flex: 0 0 43px;
  place-items: center;
  border-radius: 15px;
  background: linear-gradient(145deg, #8274ff, #6855e4);
  box-shadow: 0 10px 24px rgba(24, 12, 68, 0.28), inset 0 1px rgba(255, 255, 255, 0.22);
}

.brand-mark svg {
  width: 29px;
  height: 29px;
}

.brand-copy {
  display: flex;
  min-width: 0;
  flex-direction: column;
  line-height: 1.05;
}

.brand-name {
  font-size: 22px;
  font-weight: 780;
  letter-spacing: -0.04em;
}

.brand-domain {
  margin-top: 6px;
  color: var(--sidebar-muted);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.icon-button {
  position: relative;
  display: inline-grid;
  width: 44px;
  height: 44px;
  flex: 0 0 44px;
  cursor: pointer;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  transition: background 160ms ease, border-color 160ms ease, transform 160ms ease;
}

.icon-button:hover {
  border-color: var(--line-strong);
  background: var(--surface-soft);
}

.icon-button:active {
  transform: translateY(1px);
}

.icon-button svg {
  width: 21px;
  height: 21px;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.sidebar-collapse {
  width: 34px;
  height: 34px;
  flex-basis: 34px;
  border-color: rgba(255, 255, 255, 0.13);
  background: rgba(255, 255, 255, 0.06);
  color: var(--sidebar-muted);
}

.sidebar-collapse:hover {
  border-color: rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.11);
}

.sidebar-collapse svg {
  width: 18px;
  height: 18px;
  transition: transform 220ms ease;
}

.navigation {
  min-height: 0;
  flex: 1;
  overflow-x: hidden;
  overflow-y: auto;
  padding: 10px 14px 24px;
  scrollbar-color: rgba(255, 255, 255, 0.17) transparent;
  scrollbar-width: thin;
}

.nav-label {
  margin: 14px 13px 9px;
  color: var(--sidebar-muted);
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.14em;
  line-height: 1.5;
  text-transform: uppercase;
  white-space: nowrap;
}

.nav-label--second {
  margin-top: 26px;
}

.nav-item {
  position: relative;
  display: flex;
  min-height: 48px;
  margin: 4px 0;
  align-items: center;
  gap: 13px;
  overflow: hidden;
  padding: 0 14px;
  border-radius: 14px;
  color: var(--sidebar-muted);
  font-size: 14px;
  font-weight: 660;
  text-decoration: none;
  white-space: nowrap;
  transition: background 160ms ease, color 160ms ease;
}

.nav-item::before {
  position: absolute;
  top: 11px;
  bottom: 11px;
  left: 0;
  width: 3px;
  border-radius: 3px;
  background: transparent;
  content: "";
}

.nav-item:hover {
  background: var(--sidebar-hover);
  color: var(--sidebar-text);
}

.nav-item.is-active {
  background: rgba(255, 255, 255, 0.12);
  color: var(--sidebar-text);
}

.nav-item.is-active::before {
  background: #8f80ff;
  box-shadow: 0 0 12px rgba(143, 128, 255, 0.65);
}

.nav-item svg {
  width: 21px;
  height: 21px;
  flex: 0 0 21px;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.nav-badge {
  display: inline-grid;
  min-width: 24px;
  height: 24px;
  margin-left: auto;
  place-items: center;
  border-radius: 8px;
  background: rgba(54, 191, 160, 0.19);
  color: #71e1c7;
  font-size: 15px;
  font-weight: 800;
}

.nav-badge--coral {
  background: rgba(255, 120, 103, 0.17);
  color: #ff9b8e;
}

.sidebar-footer {
  padding: 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.workspace-mini {
  display: flex;
  min-height: 58px;
  align-items: center;
  gap: 11px;
  padding: 8px 10px;
  border-radius: 15px;
  background: rgba(255, 255, 255, 0.07);
}

.workspace-avatar {
  display: grid;
  width: 37px;
  height: 37px;
  flex: 0 0 37px;
  place-items: center;
  border-radius: 12px;
  background: var(--coral);
  color: #fff;
  font-size: 16px;
  font-weight: 800;
}

.workspace-copy {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
}

.workspace-copy strong {
  overflow: hidden;
  font-size: 16px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.workspace-copy small {
  margin-top: 4px;
  overflow: hidden;
  color: var(--sidebar-muted);
  font-size: 14px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.workspace-mini > svg {
  width: 17px;
  height: 17px;
  flex: 0 0 17px;
  stroke: var(--sidebar-muted);
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.page-column {
  display: flex;
  min-width: 0;
  height: 100%;
  min-height: 0;
  flex-direction: column;
}

.topbar {
  position: relative;
  z-index: 20;
  display: flex;
  min-height: var(--topbar-height);
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 0 28px;
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--surface) 94%, transparent);
  box-shadow: 0 8px 28px rgba(55, 44, 98, 0.03);
  backdrop-filter: blur(18px);
}

.topbar-left,
.topbar-actions {
  display: flex;
  min-width: 0;
  align-items: center;
}

.topbar-left {
  gap: 12px;
}

.topbar-actions {
  justify-content: flex-end;
  gap: 10px;
}

.call-daily-usage {
  display: flex;
  height: 52px;
  align-items: center;
  gap: 9px;
  padding: 0 12px;
  border: 1px solid color-mix(in srgb, var(--purple) 22%, var(--line));
  border-radius: 16px;
  background: linear-gradient(135deg, color-mix(in srgb, var(--purple) 8%, var(--surface-soft)), var(--surface-soft));
}

.call-daily-usage-icon { display: grid; width: 31px; height: 31px; flex: 0 0 31px; place-items: center; border-radius: 10px; background: var(--purple-soft); color: var(--purple); }
.call-daily-usage-icon svg { width: 16px; height: 16px; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.8; }
.call-daily-usage > span:not(.call-daily-usage-icon) { display: flex; min-width: 45px; flex-direction: column; line-height: 1; }
.call-daily-usage small { color: var(--muted); font-size: 12px; white-space: nowrap; }
.call-daily-usage strong { margin-top: 5px; color: var(--text); font-size: 16px; font-weight: 800; }
.call-daily-usage > span:nth-of-type(2) strong { color: var(--purple); }
.call-daily-usage > i { width: 1px; height: 27px; background: var(--line); }

.mobile-menu {
  display: none;
}

.page-heading {
  min-width: 0;
}

.eyebrow {
  display: block;
  margin-bottom: 4px;
  color: var(--purple);
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.page-heading h1 {
  margin: 0;
  overflow: hidden;
  font-size: clamp(19px, 1.5vw, 24px);
  font-weight: 760;
  letter-spacing: -0.035em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.city-switcher-wrap {
  position: relative;
}

.city-switcher {
  display: flex;
  height: 52px;
  min-width: 190px;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface-soft);
  transition: border-color 160ms ease, background 160ms ease;
}

.city-switcher-wrap.is-enabled .city-switcher:hover,
.city-switcher-wrap.is-open .city-switcher {
  border-color: var(--line-strong);
  background: var(--surface);
}

.city-switcher:disabled {
  cursor: default;
  opacity: 1;
}

.city-switcher-wrap.is-open .city-switcher .chevron {
  transform: rotate(180deg);
}

.city-icon {
  display: grid;
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  place-items: center;
  border-radius: 11px;
  background: var(--purple-soft);
  color: var(--purple);
}

.city-icon svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.city-copy {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
  align-items: flex-start;
  line-height: 1.1;
}

.city-copy small {
  color: var(--muted);
  font-size: 14px;
}

.city-copy strong {
  margin-top: 5px;
  font-size: 16px;
  font-weight: 740;
}

.chevron {
  width: 17px;
  height: 17px;
  flex: 0 0 17px;
  stroke: var(--muted);
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform 160ms ease;
}

.workspace-menu {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 80;
  width: min(340px, calc(100vw - 32px));
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--surface);
  box-shadow: 0 22px 60px rgba(39, 28, 82, 0.2);
}

.workspace-menu[hidden] {
  display: none;
}

.workspace-menu > header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 17px 18px 13px;
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--purple) 4%, var(--surface));
}

.workspace-menu > header span {
  display: flex;
  flex-direction: column;
}

.workspace-menu > header small,
.workspace-options-label {
  color: var(--muted);
  font-size: 13px;
  font-weight: 760;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.workspace-menu > header strong {
  margin-top: 4px;
  font-size: 14px;
  font-weight: 780;
}

.workspace-menu > header b {
  display: grid;
  min-width: 30px;
  height: 30px;
  place-items: center;
  border-radius: 10px;
  background: var(--purple-soft);
  color: var(--purple);
  font-size: 15px;
}

.workspace-menu form {
  margin: 0;
  padding: 9px;
}

.workspace-options-label {
  display: block;
  padding: 12px 9px 7px;
}

.workspace-options-list {
  max-height: min(350px, calc(100vh - 260px));
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
}

.workspace-option {
  display: grid;
  width: 100%;
  min-height: 58px;
  grid-template-columns: 38px minmax(0, 1fr) 22px;
  align-items: center;
  gap: 11px;
  cursor: pointer;
  padding: 8px 10px;
  border: 1px solid transparent;
  border-radius: 14px;
  background: transparent;
  text-align: left;
  transition: border-color 150ms ease, background 150ms ease;
}

.workspace-option:hover {
  border-color: var(--line);
  background: var(--surface-soft);
}

.workspace-option.is-selected {
  border-color: color-mix(in srgb, var(--purple) 24%, var(--line));
  background: color-mix(in srgb, var(--purple) 7%, var(--surface));
}

.workspace-option-icon,
.workspace-option-letter {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border-radius: 12px;
  background: linear-gradient(145deg, var(--purple), var(--purple-dark));
  color: #fff;
  font-size: 16px;
  font-weight: 820;
}

.workspace-option-icon--all {
  background: var(--purple-soft);
  color: var(--purple);
}

.workspace-option-icon svg {
  width: 19px;
  height: 19px;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.workspace-option > span:nth-child(2) {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.workspace-option > span:nth-child(2) strong,
.workspace-option > span:nth-child(2) small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.workspace-option > span:nth-child(2) strong {
  font-size: 16px;
  font-weight: 760;
}

.workspace-option > span:nth-child(2) small {
  margin-top: 5px;
  color: var(--muted);
  font-size: 13px;
}

.workspace-check {
  width: 19px;
  height: 19px;
  opacity: 0;
  stroke: var(--mint);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.workspace-option.is-selected .workspace-check {
  opacity: 1;
}

.regional-status {
  display: flex;
  height: 52px;
  min-width: 176px;
  align-items: center;
  gap: 9px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: color-mix(in srgb, var(--mint) 5%, var(--surface));
}

.regional-status-icon {
  display: grid;
  width: 32px;
  height: 32px;
  flex: 0 0 32px;
  place-items: center;
  border-radius: 10px;
  background: color-mix(in srgb, var(--mint) 11%, var(--surface));
  color: var(--mint);
}

.regional-status-icon svg {
  width: 17px;
  height: 17px;
  stroke: currentColor;
  stroke-width: 1.65;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.regional-status-copy {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
  line-height: 1.1;
}

.regional-status-copy small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
  letter-spacing: 0.04em;
}

.regional-status-copy small b {
  color: var(--mint);
  font: inherit;
}

.regional-status-copy strong {
  max-width: 105px;
  margin-top: 5px;
  overflow: hidden;
  font-size: 13px;
  font-weight: 730;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.regional-format {
  padding: 4px 5px;
  border-radius: 6px;
  background: var(--surface-soft);
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
  line-height: 1.45;
  text-align: center;
  text-transform: uppercase;
}

.theme-toggle .moon-icon,
html[data-theme="dark"] .theme-toggle .sun-icon {
  display: none;
}

html[data-theme="dark"] .theme-toggle .moon-icon {
  display: block;
}

.notification-button .status-dot {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 8px;
  height: 8px;
  border: 2px solid var(--surface);
  border-radius: 50%;
  background: var(--coral);
}

.crm-notifications { position: relative; }
.notification-button .notification-count { position: absolute; top: -5px; right: -6px; display: grid; min-width: 17px; height: 17px; place-items: center; padding: 0 4px; border: 2px solid var(--surface); border-radius: 9px; background: var(--coral); color: #fff; font-size: 11px; line-height: 1; }
.notification-button .status-dot + .notification-count { display: grid; }
.crm-notification-menu { position: absolute; z-index: 80; top: calc(100% + 12px); right: 0; width: min(390px, calc(100vw - 24px)); overflow: hidden; border: 1px solid var(--line); border-radius: 20px; background: var(--surface); box-shadow: 0 24px 70px color-mix(in srgb, var(--text) 18%, transparent); }
.crm-notification-menu > header { display: flex; min-height: 68px; align-items: center; justify-content: space-between; padding: 14px 17px; border-bottom: 1px solid var(--line); background: color-mix(in srgb, var(--purple) 5%, var(--surface)); }
.crm-notification-menu > header span { display: flex; flex-direction: column; gap: 3px; }
.crm-notification-menu > header small { color: var(--purple); font-size: 11px; font-weight: 850; letter-spacing: .12em; text-transform: uppercase; }
.crm-notification-menu > header strong { font-size: 16px; }
.crm-notification-menu > header > b { display: grid; min-width: 32px; height: 32px; place-items: center; border-radius: 11px; background: color-mix(in srgb, var(--purple) 12%, var(--surface)); color: var(--purple); font-size: 16px; }
.crm-notification-list { max-height: 470px; overflow: auto; }
.crm-notification-item { display: flex; gap: 11px; padding: 15px 16px; border-bottom: 1px solid var(--line); }
.crm-notification-item:last-child { border-bottom: 0; }
.crm-notification-avatar { display: grid; width: 38px; height: 38px; flex: 0 0 38px; place-items: center; border-radius: 13px; background: color-mix(in srgb, #2aabee 13%, var(--surface)); color: #168ac0; font-size: 16px; font-weight: 850; }
.crm-notification-copy { display: flex; min-width: 0; flex: 1; flex-direction: column; }
.crm-notification-copy > small { color: #168ac0; font-size: 11px; font-weight: 800; }
.crm-notification-copy > strong { margin-top: 4px; font-size: 15px; }
.crm-notification-copy > em { margin-top: 3px; overflow: hidden; color: var(--muted); font-size: 12px; font-style: normal; text-overflow: ellipsis; white-space: nowrap; }
.crm-notification-actions { display: flex; gap: 7px; margin-top: 10px; }
.crm-notification-actions form { margin: 0; }
.crm-notification-actions button { min-height: 30px; padding: 0 11px; border: 1px solid var(--line); border-radius: 9px; background: var(--surface); font: inherit; font-size: 12px; font-weight: 800; }
.crm-notification-actions .is-approve { border-color: color-mix(in srgb, var(--mint) 38%, var(--line)); background: color-mix(in srgb, var(--mint) 10%, var(--surface)); color: #15977f; }
.crm-notification-actions .is-deny { border-color: color-mix(in srgb, var(--coral) 34%, var(--line)); color: var(--coral); }
.crm-notification-empty { display: flex; min-height: 180px; align-items: center; justify-content: center; flex-direction: column; padding: 30px; text-align: center; }
.crm-notification-empty span { display: grid; width: 42px; height: 42px; place-items: center; border-radius: 14px; background: color-mix(in srgb, var(--mint) 12%, var(--surface)); color: var(--mint); font-size: 18px; }
.crm-notification-empty strong { margin-top: 12px; font-size: 15px; }
.crm-notification-empty small { margin-top: 4px; color: var(--muted); font-size: 12px; }

.profile-summary {
  display: flex;
  min-width: 205px;
  align-items: center;
  gap: 10px;
  padding: 0 8px;
}

.profile-avatar {
  display: grid;
  width: 41px;
  height: 41px;
  flex: 0 0 41px;
  place-items: center;
  border-radius: 14px;
  background: linear-gradient(145deg, var(--mint), #249b84);
  color: #fff;
  font-size: 16px;
  font-weight: 800;
  box-shadow: 0 7px 16px rgba(38, 163, 135, 0.18);
}

.profile-copy {
  display: flex;
  min-width: 0;
  flex-direction: column;
  line-height: 1.1;
}

.profile-copy strong {
  overflow: hidden;
  font-size: 16px;
  font-weight: 740;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.profile-copy small {
  margin-top: 5px;
  overflow: hidden;
  color: var(--muted);
  font-size: 14px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.topbar-actions > form {
  display: flex;
  margin: 0;
}

.logout-button {
  display: flex;
  height: 44px;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  padding: 0 15px;
  border: 1px solid color-mix(in srgb, var(--coral) 26%, var(--line));
  border-radius: 14px;
  background: color-mix(in srgb, var(--coral) 7%, var(--surface));
  color: var(--coral);
  font-size: 16px;
  font-weight: 750;
  transition: border-color 160ms ease, background 160ms ease, transform 160ms ease;
}

.logout-button:hover {
  border-color: color-mix(in srgb, var(--coral) 48%, var(--line));
  background: color-mix(in srgb, var(--coral) 12%, var(--surface));
}

.logout-button:active {
  transform: translateY(1px);
}

.logout-button svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.main-content {
  min-width: 0;
  min-height: 0;
  flex: 1;
  overflow: auto;
  padding: 24px 28px 28px;
  background:
    radial-gradient(circle at 88% 8%, color-mix(in srgb, var(--coral) 7%, transparent), transparent 22%),
    radial-gradient(circle at 10% 92%, color-mix(in srgb, var(--purple) 8%, transparent), transparent 26%),
    var(--page);
}

.workspace-canvas {
  position: relative;
  width: 100%;
  min-height: calc(100vh - var(--topbar-height) - 52px);
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 26px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.workspace-canvas::before {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(90deg, color-mix(in srgb, var(--purple) 2.2%, transparent) 1px, transparent 1px),
    linear-gradient(color-mix(in srgb, var(--purple) 2.2%, transparent) 1px, transparent 1px);
  background-size: 28px 28px;
  content: "";
  mask-image: linear-gradient(to bottom right, #000, transparent 70%);
}

.toast {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 60;
  display: flex;
  max-width: min(390px, calc(100vw - 32px));
  align-items: center;
  gap: 11px;
  padding: 13px 16px;
  border: 1px solid var(--line);
  border-radius: 15px;
  background: var(--surface);
  color: var(--text);
  font-size: 16px;
  font-weight: 620;
  box-shadow: 0 16px 40px rgba(35, 25, 76, 0.18);
  opacity: 0;
  pointer-events: none;
  transform: translateY(16px);
  transition: opacity 180ms ease, transform 180ms ease;
}

.toast.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.toast-icon {
  display: grid;
  width: 31px;
  height: 31px;
  flex: 0 0 31px;
  place-items: center;
  border-radius: 10px;
  background: var(--purple-soft);
  color: var(--purple);
}

.toast-icon svg {
  width: 17px;
  height: 17px;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.sidebar-scrim {
  display: none;
}

.app-shell.is-collapsed {
  grid-template-columns: var(--sidebar-collapsed) minmax(0, 1fr);
}

.app-shell.is-collapsed .brand-row {
  justify-content: center;
  padding-inline: 12px;
}

.app-shell.is-collapsed .brand-copy,
.app-shell.is-collapsed .nav-label,
.app-shell.is-collapsed .nav-item > span:not(.nav-badge),
.app-shell.is-collapsed .workspace-copy,
.app-shell.is-collapsed .workspace-mini > svg {
  display: none;
}

.app-shell.is-collapsed .sidebar-collapse {
  position: absolute;
  top: 7px;
  right: 7px;
  display: inline-grid;
  width: 25px;
  height: 25px;
  border-color: rgba(255, 255, 255, 0.18);
  background: color-mix(in srgb, var(--sidebar) 78%, #ffffff 22%);
  color: var(--sidebar-text);
}

.app-shell.is-collapsed .sidebar-collapse svg {
  width: 15px;
  height: 15px;
  transform: rotate(180deg);
}

.app-shell.is-collapsed .navigation {
  padding-inline: 12px;
  padding-top: 18px;
}

.app-shell.is-collapsed .nav-item {
  justify-content: center;
  padding: 0;
}

.app-shell.is-collapsed .nav-item::before {
  top: 13px;
  bottom: 13px;
}

.app-shell.is-collapsed .nav-badge {
  position: absolute;
  top: 5px;
  right: 5px;
  display: grid;
  min-width: 17px;
  height: 17px;
  padding: 0 4px;
  border-radius: 6px;
  font-size: 12px;
}

.app-shell.is-collapsed .sidebar-footer {
  padding-inline: 12px;
}

.app-shell.is-collapsed .workspace-mini {
  justify-content: center;
  padding-inline: 0;
}

@media (max-width: 1180px) {
  .profile-copy,
  .logout-button span,
  .city-copy small,
  .regional-status {
    display: none;
  }

  .profile-summary {
    min-width: auto;
    padding-inline: 2px;
  }

  .logout-button {
    width: 44px;
    justify-content: center;
    padding: 0;
  }

  .city-switcher {
    min-width: 154px;
  }

  .call-daily-usage { gap: 7px; padding-inline: 9px; }
  .call-daily-usage-icon { display: none; }

}

@media (max-width: 860px) {
  body {
    position: static;
    width: auto;
    height: auto;
    overflow: auto;
  }

  .app-shell,
  .app-shell.is-collapsed {
    display: block;
    height: auto;
    min-height: 100vh;
    overflow: visible;
  }

  .sidebar {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    width: min(var(--sidebar-width), calc(100vw - 52px));
    height: 100dvh;
    transform: translateX(-104%);
    transition: transform 220ms ease;
  }

  .app-shell.is-mobile-open .sidebar {
    transform: translateX(0);
  }

  .app-shell.is-collapsed .brand-row {
    justify-content: space-between;
    padding: 0 22px;
  }

  .app-shell.is-collapsed .brand-copy,
  .app-shell.is-collapsed .nav-label,
  .app-shell.is-collapsed .nav-item > span:not(.nav-badge),
  .app-shell.is-collapsed .workspace-copy,
  .app-shell.is-collapsed .workspace-mini > svg {
    display: initial;
  }

  .app-shell.is-collapsed .sidebar-collapse {
    display: inline-grid;
  }

  .app-shell.is-collapsed .navigation {
    padding: 10px 14px 24px;
  }

  .app-shell.is-collapsed .nav-item {
    justify-content: flex-start;
    padding: 0 14px;
  }

  .app-shell.is-collapsed .nav-badge {
    position: static;
    display: inline-grid;
    min-width: 24px;
    height: 24px;
    margin-left: auto;
    padding: 0;
    border-radius: 8px;
    font-size: 15px;
  }

  .app-shell.is-collapsed .sidebar-footer {
    padding-inline: 14px;
  }

  .app-shell.is-collapsed .workspace-mini {
    justify-content: flex-start;
    padding: 8px 10px;
  }

  .sidebar-scrim {
    position: fixed;
    inset: 0;
    z-index: 25;
    display: block;
    cursor: pointer;
    border: 0;
    background: rgba(21, 16, 38, 0.5);
    opacity: 0;
    pointer-events: none;
    transition: opacity 220ms ease;
    backdrop-filter: blur(3px);
  }

  .app-shell.is-mobile-open .sidebar-scrim {
    opacity: 1;
    pointer-events: auto;
  }

  .page-column {
    min-height: 100vh;
    height: auto;
  }

  .topbar {
    min-height: 76px;
    padding-inline: 18px;
  }

  .mobile-menu {
    display: inline-grid;
  }

  .city-switcher {
    min-width: auto;
  }

  .city-copy,
  .city-switcher .chevron,
  .profile-summary {
    display: none;
  }

  .call-daily-usage { display: none; }

  .main-content {
    min-height: calc(100vh - 76px);
    padding: 18px;
  }

  .workspace-canvas {
    min-height: calc(100vh - 112px);
    border-radius: 22px;
  }
}

@media (max-width: 560px) {
  .topbar {
    gap: 10px;
    padding-inline: 14px;
  }

  .topbar-actions {
    gap: 7px;
  }

  .city-switcher {
    width: 40px;
    height: 40px;
    min-width: 40px;
    justify-content: center;
    padding: 0;
    border-radius: 13px;
  }

  .city-switcher .city-icon {
    width: 30px;
    height: 30px;
    flex-basis: 30px;
  }

  .workspace-menu {
    position: fixed;
    top: 68px;
    right: 10px;
    left: 10px;
    width: auto;
  }

  .icon-button,
  .logout-button {
    width: 40px;
    height: 40px;
    flex-basis: 40px;
    border-radius: 13px;
  }

  .notification-button {
    display: none;
  }

  .eyebrow {
    display: none;
  }

  .page-heading h1 {
    font-size: 17px;
  }

  .main-content {
    padding: 12px;
  }

  .workspace-canvas {
    min-height: calc(100vh - 100px);
    border-radius: 18px;
  }

  .toast {
    right: 16px;
    bottom: 16px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
