:root {
  --bg-sidebar: #061826;
  --bg-main: #102C3F;
  --bg-workspace: #1B4D6B;
  --bg-card: #173E55;
  --bg-panel: #121821;
  --bg-page: #08121A;
  --bg-canvas: #DCEAF0;
  --bg-canvas-soft: #EEF6F8;
  --text-primary: #EAF4F8;
  --text-secondary: #A9C1CC;
  --text-soft: #C8D8DF;
  --accent: #4FD1C5;
  --accent-hover: #2C9FA5;
  --state-success: #22c55e;
  --state-warning: #f59e0b;
  --state-danger: #ef4444;
  --ink: var(--text-primary);
  --muted: var(--text-secondary);
  --page: var(--bg-page);
  --panel: var(--bg-panel);
  --panel-2: #1a2330;
  --line: rgba(230, 237, 243, 0.14);
  --action: var(--accent);
  --action-dark: var(--accent-hover);
  --aqua: var(--accent);
  --text: var(--text-primary);
  --textSecondary: var(--text-secondary);
  --navy: var(--accent);
  --navy-soft: rgba(94, 234, 212, 0.15);
  --coral: var(--state-warning);
  --coral-soft: rgba(245, 158, 11, 0.14);
  --violet-soft: rgba(124, 58, 237, 0.16);
  --gold-soft: rgba(245, 158, 11, 0.16);
  --teal-soft: rgba(94, 234, 212, 0.15);
  --danger: var(--state-danger);
  --danger-soft: rgba(239, 68, 68, 0.16);
  --success: var(--state-success);
  --success-soft: rgba(34, 197, 94, 0.16);
  --secondary: #7c3aed;
  --secondary-soft: rgba(124, 58, 237, 0.18);
  --low: rgba(34, 197, 94, 0.16);
  --mid: rgba(94, 234, 212, 0.15);
  --high: rgba(245, 158, 11, 0.16);
  --low-ink: #86efac;
  --mid-ink: var(--accent);
  --high-ink: #fbbf24;
  --shadow: 0 18px 42px rgba(0, 0, 0, 0.28);
  --dark-panel: #1a2330;
  --dark-panel-2: var(--bg-panel);
  --control-radius: 8px;
  --control-height: 44px;
  --control-compact-height: 40px;
  --control-padding-x: 14px;
  --control-compact-padding-x: 10px;
}

html[data-theme="light"] {
  color-scheme: light;
  --bg-sidebar: #e7f3f6;
  --bg-main: #f4fafb;
  --bg-workspace: #e8f4f7;
  --bg-card: #f8fcfd;
  --bg-panel: #f7fbfc;
  --bg-page: #dcecf2;
  --bg-canvas: #dcecf2;
  --bg-canvas-soft: #f4fafb;
  --text-primary: #082535;
  --text-secondary: #456779;
  --text-soft: #31586b;
  --accent: #0f8e91;
  --accent-hover: #0b6f73;
  --ink: var(--text-primary);
  --muted: var(--text-secondary);
  --page: var(--bg-page);
  --panel: var(--bg-panel);
  --panel-2: #e5f1f4;
  --line: rgba(8, 37, 53, 0.16);
  --action: var(--accent);
  --action-dark: var(--accent-hover);
  --aqua: var(--accent);
  --text: var(--text-primary);
  --textSecondary: var(--text-secondary);
  --navy: var(--accent);
  --navy-soft: rgba(15, 142, 145, 0.12);
  --teal-soft: rgba(15, 142, 145, 0.12);
  --low-ink: #087f5b;
  --mid-ink: var(--accent);
  --high-ink: #a16207;
  --shadow: 0 18px 42px rgba(31, 74, 92, 0.16);
  --dark-panel: #f7fbfc;
  --dark-panel-2: #eef6f8;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

body {
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at top left, rgba(94, 234, 212, 0.16), transparent 34%),
    linear-gradient(180deg, var(--bg-page) 0%, var(--bg-panel) 44%, var(--bg-page) 100%),
    var(--page);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

html[data-theme="light"] body {
  background:
    radial-gradient(circle at top left, rgba(79, 209, 197, 0.22), transparent 34%),
    linear-gradient(180deg, #f6fbfc 0%, #dcecf2 44%, #f6fbfc 100%),
    var(--page);
}

button,
select,
input {
  font: inherit;
}

button,
select,
input {
  border-radius: 8px;
}

button {
  min-height: var(--control-height);
  padding: 10px 14px;
  border: 1px solid var(--line);
  background: var(--panel);
  color: var(--ink);
  cursor: pointer;
  font-weight: 850;
  transition: border-color 160ms ease, background 160ms ease, color 160ms ease, box-shadow 160ms ease;
}

button:hover,
a:hover {
  border-color: var(--action);
}

button:focus-visible,
a:focus-visible {
  outline: 2px solid rgba(94, 234, 212, 0.72);
  outline-offset: 2px;
}

button:hover {
  box-shadow: 0 0 0 1px rgba(94, 234, 212, 0.18);
}

button:focus-visible,
a:focus-visible,
select:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: none;
  border-color: var(--action);
  box-shadow: 0 0 0 3px rgba(79, 209, 197, 0.2);
}

select,
input,
textarea {
  width: 100%;
  min-height: 44px;
  padding: 9px 11px;
  border: 1px solid var(--line);
  background: #0f151d;
  color: var(--ink);
  resize: vertical;
}

html[data-theme="light"] select,
html[data-theme="light"] input,
html[data-theme="light"] textarea {
  background: #f9fcfd;
  color: var(--ink);
  border-color: rgba(8, 37, 53, 0.18);
}

input[type="date"],
input[type="time"] {
  color-scheme: dark;
  cursor: pointer;
}

html[data-theme="light"] input[type="date"],
html[data-theme="light"] input[type="time"] {
  color-scheme: light;
}

input[type="date"]::-webkit-calendar-picker-indicator,
input[type="time"]::-webkit-calendar-picker-indicator {
  cursor: pointer;
  filter: invert(1);
  opacity: 0.72;
}

html[data-theme="light"] input[type="date"]::-webkit-calendar-picker-indicator,
html[data-theme="light"] input[type="time"]::-webkit-calendar-picker-indicator {
  filter: none;
  opacity: 0.72;
}

input[type="date"]:hover::-webkit-calendar-picker-indicator,
input[type="time"]:hover::-webkit-calendar-picker-indicator,
input[type="date"]:focus::-webkit-calendar-picker-indicator,
input[type="time"]:focus::-webkit-calendar-picker-indicator {
  opacity: 0.95;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  text-wrap: balance;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 760px;
  margin-bottom: 10px;
  font-size: 4rem;
  line-height: 1;
}

h2 {
  margin-bottom: 8px;
  font-size: 2rem;
  line-height: 1.12;
}

h3 {
  margin-bottom: 12px;
  font-size: 1.05rem;
}

.app-shell {
  min-height: 100vh;
  padding-bottom: 26px;
}

body.auth-locked {
  background:
    radial-gradient(circle at 50% 10%, rgba(94, 234, 212, 0.12), transparent 32%),
    linear-gradient(180deg, #12384f 0%, #0f2f44 48%, #0b2638 100%);
}

html[data-theme="light"] body.auth-locked {
  background:
    radial-gradient(circle at 50% 8%, rgba(79, 209, 197, 0.16), transparent 30%),
    linear-gradient(180deg, #eef8fa 0%, #dcecf2 52%, #f7fbfc 100%);
}

.auth-gate {
  display: none;
  min-height: 100vh;
  place-items: center;
  padding: 24px;
}

.auth-card {
  display: grid;
  gap: 16px;
  width: min(720px, 100%);
  padding: 28px;
  border: 1px solid rgba(94, 234, 212, 0.24);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(18, 24, 33, 0.98), rgba(26, 35, 48, 0.98)),
    var(--panel);
  box-shadow: var(--shadow);
}

html[data-theme="light"] .auth-card {
  border-color: rgba(8, 37, 53, 0.16);
  background: linear-gradient(180deg, #ffffff, #f7fbfc);
  box-shadow: 0 20px 52px rgba(31, 74, 92, 0.16);
}

.app-logo-lockup {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.auth-logo-lockup {
  justify-self: center;
  flex-wrap: wrap;
  text-align: center;
}

.auth-logo-lockup strong {
  color: var(--ink);
  font-size: 1.08rem;
  font-weight: 800;
  letter-spacing: 0;
}

.auth-logo {
  justify-self: center;
  width: 62px;
  max-height: 54px;
  object-fit: contain;
}

.auth-card h1 {
  margin: 4px 0 10px;
  font-size: 2.4rem;
  font-weight: 800;
  text-align: center;
}

html[data-theme="light"] .auth-card h1,
html[data-theme="light"] .auth-form label,
html[data-theme="light"] .auth-logo-lockup strong {
  color: #082535;
}

html[data-theme="light"] .auth-legal-links a,
html[data-theme="light"] .link-button {
  color: #0b7f83;
}

.auth-card > .lead {
  text-align: center;
}

input[type="checkbox"] {
  width: 16px;
  height: 16px;
  min-width: 16px;
  accent-color: var(--action);
}

.auth-switch {
  display: none;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

body.invite-activation-ready .auth-switch {
  display: grid;
}

.invite-only-tab[hidden] {
  display: none !important;
}

.auth-switch-button {
  background: rgba(255, 255, 255, 0.05);
  color: var(--muted);
}

.auth-switch-button.active {
  border-color: rgba(94, 234, 212, 0.58);
  background: rgba(94, 234, 212, 0.16);
  color: var(--action);
}

.auth-panel {
  display: none;
  gap: 12px;
}

.auth-panel.active {
  display: grid;
}

.auth-form,
.admin-login-form {
  display: grid;
  gap: 12px;
}

.link-button {
  border-color: transparent;
  background: transparent;
  color: var(--action);
}

body.auth-locked .hero,
body.auth-locked .mode-tabs,
body.auth-locked .mode-panel,
body.auth-locked .top-workbar,
body.auth-locked .mobile-quick-nav {
  display: none !important;
}

body.auth-locked #authGate {
  display: grid;
}

body:not(.auth-locked):not(.admin-route) .hero {
  display: none;
}

body.admin-route #authGate,
body.admin-route .hero,
body.admin-route .top-workbar,
body.admin-route .mode-tabs,
body.admin-route .mobile-quick-nav,
body.admin-route .facilitator-sidebar,
body.admin-route .mode-panel:not(#adminMode) {
  display: none !important;
}

body.admin-route #adminMode {
  display: block;
  max-width: none;
  padding: 16px 18px 32px;
}

body.admin-route .admin-board {
  max-width: 1480px;
  margin: 0 auto;
  padding: 18px;
  border: 1px solid rgba(94, 234, 212, 0.14);
  border-radius: 24px;
  background: linear-gradient(180deg, rgba(27, 77, 107, 0.96), rgba(19, 52, 71, 0.96));
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.28);
}

.hero {
  position: relative;
  min-height: 310px;
  display: grid;
  align-items: end;
  overflow: hidden;
  background: #081821;
}

.hero img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.52;
}

.hero-overlay {
  position: relative;
  z-index: 1;
  max-width: 1180px;
  width: 100%;
  margin: 0 auto;
  padding: 44px 22px 30px;
  color: #fff;
}

.hero-copy {
  max-width: 650px;
  margin-bottom: 0;
  color: rgba(255, 255, 255, 0.88);
  font-size: 1.1rem;
  line-height: 1.45;
}

.eyebrow {
  margin-bottom: 7px;
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.hero .eyebrow {
  color: rgba(255, 255, 255, 0.76);
}

.mode-tabs {
  position: static;
  z-index: 5;
  display: flex;
  align-items: center;
  gap: 10px;
  max-width: 1180px;
  margin: 0 auto;
  padding: 14px 22px;
  background: rgba(15, 36, 48, 0.94);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.16);
}

.top-workbar {
  position: sticky;
  top: 0;
  z-index: 12;
  display: grid;
  grid-template-columns: auto minmax(220px, auto) minmax(0, 1fr) auto auto;
  gap: 10px;
  align-items: center;
  max-width: 1180px;
  margin: 0 auto;
  padding: 10px 22px;
  border-bottom: 1px solid rgba(94, 234, 212, 0.18);
  background: rgba(11, 15, 20, 0.94);
  backdrop-filter: blur(12px);
}

body.facilitator-shell .top-workbar {
  position: sticky;
  top: 14px;
  z-index: 18;
  align-items: start;
  grid-template-columns: auto minmax(0, 1fr) auto;
  grid-template-rows: auto auto;
  max-width: none;
  margin: 18px 22px 0 0;
  padding: 12px 20px 12px 24px;
  border: 1px solid rgba(94, 234, 212, 0.14);
  border-bottom: 0;
  border-radius: 30px 30px 0 0;
  background: linear-gradient(180deg, rgba(19, 52, 71, 0.98), rgba(19, 52, 71, 0.94));
  box-shadow: 0 26px 56px rgba(2, 12, 19, 0.24);
  overflow: visible;
}

body.facilitator-shell:not(.playlist-editing) .top-workbar {
  position: sticky;
  top: 0;
}

body.client-shell .top-workbar {
  position: sticky;
  top: 14px;
  z-index: 18;
  align-items: start;
  grid-template-columns: auto minmax(0, 1fr) auto;
  grid-template-rows: auto auto;
  max-width: none;
  margin: 18px 22px 0 0;
  padding: 12px 20px 12px 24px;
  border: 1px solid rgba(94, 234, 212, 0.14);
  border-bottom: 0;
  border-radius: 30px 30px 0 0;
  background: linear-gradient(180deg, rgba(19, 52, 71, 0.98), rgba(19, 52, 71, 0.94));
  box-shadow: 0 26px 56px rgba(2, 12, 19, 0.24);
  overflow: visible;
}

html[data-theme="light"] body.facilitator-shell .top-workbar,
html[data-theme="light"] body.client-shell .top-workbar {
  border-color: rgba(8, 37, 53, 0.12);
  background: linear-gradient(180deg, rgba(248, 252, 253, 0.96), rgba(231, 243, 246, 0.94));
  box-shadow: 0 24px 54px rgba(31, 74, 92, 0.14);
}

body.client-shell:not(.playlist-editing) .top-workbar {
  position: sticky;
  top: 0;
}

body.client-shell.client-sessions-route .top-workbar {
  position: relative;
  top: 0;
  box-shadow: none;
}

html[data-theme="light"] body.client-shell.client-sessions-route .top-workbar {
  box-shadow: none;
}

body.facilitator-shell .top-workbar::before {
  content: "";
  position: absolute;
  left: -30px;
  top: 0;
  bottom: 0;
  width: 72px;
  border-top-left-radius: 26px;
  background: linear-gradient(180deg, rgba(19, 52, 71, 0.98), rgba(19, 52, 71, 0.94));
  border-top: 1px solid rgba(94, 234, 212, 0.14);
  border-left: 1px solid rgba(94, 234, 212, 0.14);
  pointer-events: none;
}

body.client-shell .top-workbar::before {
  content: "";
  position: absolute;
  left: -30px;
  top: 0;
  bottom: 0;
  width: 72px;
  border-top-left-radius: 26px;
  background: linear-gradient(180deg, rgba(19, 52, 71, 0.98), rgba(19, 52, 71, 0.94));
  border-top: 1px solid rgba(94, 234, 212, 0.14);
  border-left: 1px solid rgba(94, 234, 212, 0.14);
  pointer-events: none;
}

html[data-theme="light"] body.facilitator-shell .top-workbar::before,
html[data-theme="light"] body.client-shell .top-workbar::before {
  background: linear-gradient(180deg, rgba(248, 252, 253, 0.96), rgba(231, 243, 246, 0.94));
  border-color: rgba(8, 37, 53, 0.12);
}

body.facilitator-shell .top-workbar::after {
  content: "";
  position: absolute;
  left: -30px;
  top: 0;
  width: 38px;
  height: 38px;
  background: transparent;
  border-top-left-radius: 26px;
  box-shadow: -18px -18px 0 0 rgba(6, 24, 38, 1);
  pointer-events: none;
}

body.client-shell .top-workbar::after {
  content: "";
  position: absolute;
  left: -30px;
  top: 0;
  width: 38px;
  height: 38px;
  background: transparent;
  border-top-left-radius: 26px;
  box-shadow: -18px -18px 0 0 rgba(6, 24, 38, 1);
  pointer-events: none;
}

html[data-theme="light"] body.facilitator-shell .top-workbar::after,
html[data-theme="light"] body.client-shell .top-workbar::after {
  box-shadow: -18px -18px 0 0 #e7f3f6;
}

.top-workbar > * {
  position: relative;
  z-index: 1;
}

body.facilitator-shell .top-therapist-identity,
body.client-shell .top-therapist-identity {
  grid-column: 1;
  grid-row: 1;
  align-self: start;
}

body.facilitator-shell .active-journey-bar,
body.client-shell .active-journey-bar {
  grid-column: 2 / 4;
  grid-row: 1;
  align-self: start;
}

body.facilitator-shell .workspace-quick-nav,
body.client-shell .workspace-quick-nav {
  grid-column: 3;
  grid-row: 2;
  align-self: start;
}

body.facilitator-shell .impersonation-topbar,
body.client-shell .impersonation-topbar {
  grid-column: 2 / 4;
  grid-row: 2;
}

.mobile-menu-toggle {
  display: none;
  background: var(--bg-card);
  color: var(--action);
  border-color: rgba(94, 234, 212, 0.38);
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.18);
}

.mobile-playlist-menu {
  display: none;
}

.mobile-playlist-menu[hidden] {
  display: none !important;
}

.mobile-playlist-menu summary {
  list-style: none;
}

.mobile-playlist-menu summary::-webkit-details-marker {
  display: none;
}

.top-therapist-identity {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  min-width: 0;
  width: fit-content;
  max-width: min(480px, 38vw);
  padding: 7px 10px;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(6, 24, 38, 0.52);
}

.top-therapist-identity[hidden] {
  display: none !important;
}

.top-therapist-media {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  overflow: hidden;
  border: 1px solid rgba(94, 234, 212, 0.2);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
}

.top-therapist-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.top-therapist-media span {
  color: #a7fff3;
  font-size: 0.82rem;
  font-weight: 950;
}

.top-therapist-copy {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.top-therapist-copy strong {
  overflow: hidden;
  color: var(--ink);
  font-size: 0.92rem;
  font-weight: 950;
  line-height: 1.1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.top-therapist-copy span {
  overflow: hidden;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 850;
  text-overflow: ellipsis;
  text-transform: uppercase;
  white-space: nowrap;
}

.active-journey-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
  align-self: start;
  min-width: 0;
  cursor: pointer;
}

.active-journey-bar:not(.has-copy) {
  display: flex;
  justify-content: flex-end;
}

.active-journey-bar:not(.has-copy) .active-journey-tools {
  align-items: flex-start;
}

.active-journey-bar:not(.has-copy) .active-journey-copy {
  display: none;
}

.active-journey-copy {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.active-journey-empty {
  min-height: 14px;
}

.active-journey-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  justify-content: flex-end;
}

.sr-only {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

.header-system-tools {
  align-items: flex-start;
}

.header-system-tools .secondary-button.compact-button,
.header-system-tools .autosave-pill {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

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

.workspace-quick-nav[hidden] {
  display: none !important;
}

.impersonation-topbar[hidden] {
  display: none !important;
}

.workspace-quick-nav button {
  min-height: 34px;
  padding: 7px 10px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
  color: var(--ink);
  font-size: 0.82rem;
  font-weight: 800;
  transition: border-color 160ms ease, background 160ms ease, color 160ms ease;
}

.active-journey-tools .secondary-button.compact-button,
.active-journey-inline-shortcut,
.active-journey-status select,
.active-journey-tools .autosave-pill {
  min-height: 34px;
  padding: 7px 10px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
  color: var(--ink);
  font-size: 0.82rem;
  font-weight: 800;
  text-transform: none;
  transition: border-color 160ms ease, background 160ms ease, color 160ms ease;
}

.active-journey-tools .secondary-button.compact-button:hover,
.active-journey-inline-shortcut:hover,
.active-journey-status select:hover {
  border-color: rgba(94, 234, 212, 0.34);
  background: rgba(94, 234, 212, 0.1);
}

.workspace-quick-nav button:hover {
  border-color: rgba(94, 234, 212, 0.34);
  background: rgba(94, 234, 212, 0.1);
}

.workspace-quick-nav button.active {
  border-color: var(--action);
  background: rgba(94, 234, 212, 0.14);
  color: #99f6e4;
}

.tab-language-switcher {
  display: none !important;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
}

.active-journey-copy span {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: none;
}

.active-journey-bar strong {
  overflow: hidden;
  color: var(--action);
  font-size: 0.92rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.active-journey-status {
  display: flex;
  align-items: center;
  min-width: 0;
}

.active-journey-status span {
  display: none;
}

.active-journey-status select {
  min-height: 34px;
  min-width: 132px;
}

body.facilitator-shell:not(.playlist-editing) .close-playlist-button,
body.facilitator-shell:not(.playlist-editing) .active-journey-status,
body.client-shell:not(.playlist-editing) .close-playlist-button,
body.client-shell:not(.playlist-editing) .active-journey-status {
  display: none !important;
}

.autosave-pill {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 7px 10px;
  border: 1px solid rgba(94, 234, 212, 0.24);
  border-radius: 8px;
  font-size: 0.82rem;
  font-weight: 900;
  text-transform: uppercase;
  cursor: pointer;
}

.autosave-pill.saved {
  border-color: rgba(34, 197, 94, 0.34);
  background: rgba(34, 197, 94, 0.12);
  color: #bbf7d0;
}

.autosave-pill.saving {
  border-color: rgba(94, 234, 212, 0.34);
  background: rgba(94, 234, 212, 0.14);
  color: #99f6e4;
}

.autosave-pill.error {
  border-color: rgba(239, 68, 68, 0.4);
  background: rgba(239, 68, 68, 0.14);
  color: #fecaca;
}

.sync-status-wrap {
  position: relative;
  display: inline-flex;
  align-items: flex-start;
}

.sync-status-popover {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 20;
  display: grid;
  gap: 5px;
  width: min(280px, 70vw);
  max-height: 260px;
  overflow: auto;
  padding: 12px 14px;
  border: 1px solid rgba(94, 234, 212, 0.2);
  border-radius: 8px;
  background: var(--bg-workspace);
  box-shadow: 0 18px 38px rgba(0, 0, 0, 0.32);
}

html[data-theme="light"] .sync-status-popover {
  border-color: rgba(15, 142, 145, 0.22);
  background: #f8fcfd;
  box-shadow: 0 18px 38px rgba(31, 74, 92, 0.16);
}

.sync-status-popover[hidden] {
  display: none;
}

.sync-status-popover strong {
  overflow: visible;
  color: var(--ink);
  font-size: 0.9rem;
  line-height: 1.35;
  white-space: normal;
  text-overflow: clip;
}

html[data-theme="light"] .sync-status-popover strong {
  color: #082535;
}

.sync-status-popover small {
  color: var(--muted);
  line-height: 1.35;
}

html[data-theme="light"] .sync-status-popover small {
  color: #31586b;
}

.notifications-popover {
  width: min(360px, 82vw);
  text-align: left;
}

.header-button-icon {
  display: none;
}

.notification-popover-list {
  display: grid;
  gap: 8px;
  max-height: 214px;
  overflow-y: auto;
  padding-right: 4px;
}

.notification-popover-item {
  display: grid;
  gap: 4px;
  align-items: start;
  align-content: start;
  grid-template-rows: none;
  height: auto;
  width: 100%;
  min-height: 0;
  min-width: 0;
  padding: 9px 10px;
  border: 1px solid rgba(94, 234, 212, 0.22);
  border-radius: 8px;
  background: rgba(19, 52, 71, 0.95);
  color: inherit;
  cursor: pointer;
  text-align: left;
}

html[data-theme="light"] .notification-popover-item {
  border-color: rgba(15, 142, 145, 0.16);
  background: #eef6f8;
  color: #082535;
}

.notification-popover-item:hover,
.notification-popover-item:focus-visible {
  border-color: rgba(94, 234, 212, 0.55);
  background: rgba(28, 79, 104, 0.98);
  outline: none;
}

html[data-theme="light"] .notification-popover-item:hover,
html[data-theme="light"] .notification-popover-item:focus-visible {
  border-color: rgba(15, 142, 145, 0.34);
  background: #e2f2f4;
}

.notification-popover-item strong {
  display: -webkit-box;
  max-width: 100%;
  overflow: hidden;
  color: var(--ink);
  font-size: 0.84rem;
  line-height: 1.45;
  padding-top: 1px;
  white-space: normal;
  text-overflow: ellipsis;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.notification-popover-item small {
  display: -webkit-box;
  max-width: 100%;
  min-width: 0;
  overflow: hidden;
  line-height: 1.42;
  overflow-wrap: anywhere;
  text-overflow: ellipsis;
  white-space: normal;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.notification-popover-more {
  display: block;
  padding: 4px 2px 0;
  color: var(--muted);
  font-size: 0.78rem;
}

html[data-theme="light"] .notification-popover-item strong {
  color: #082535;
}

.notification-popover-item small,
.notification-popover-empty {
  color: #cbd5e1;
  line-height: 1.35;
}

html[data-theme="light"] .notification-popover-item small,
html[data-theme="light"] .notification-popover-empty {
  color: #31586b;
}

.client-message-header-button,
.facilitator-message-header-button {
  display: inline-grid;
  place-items: center;
  width: 48px;
  height: 48px;
  min-width: 48px;
  min-height: 48px;
  padding: 0;
  border-radius: 999px;
  position: relative;
}

.client-message-header-button .header-button-icon,
.facilitator-message-header-button .header-button-icon {
  display: inline-grid;
  place-items: center;
  color: currentColor;
}

.message-envelope-icon {
  display: block;
  width: 21px;
  height: 21px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.theme-toggle-glyph,
.theme-toggle-icon {
  position: relative;
  display: inline-grid;
  width: 24px;
  height: 24px;
  place-items: center;
}

.header-theme-switch {
  display: none !important;
}

.theme-toggle-icon .theme-icon {
  grid-area: 1 / 1;
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

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

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

.theme-toggle-glyph::before {
  content: "";
  width: 15px;
  height: 15px;
  border: 2px solid currentColor;
  border-radius: 50%;
  box-shadow: none;
  transform: none;
}

.header-theme-button[data-theme-choice="dark"] .theme-toggle-glyph::before {
  width: 17px;
  height: 17px;
  box-shadow: inset -5px 0 0 0 currentColor;
  transform: rotate(-18deg);
}

.header-theme-button[data-theme-choice="light"] .theme-toggle-glyph::after {
  content: "";
  position: absolute;
  inset: 2px;
  border-radius: 50%;
  box-shadow:
    0 -9px 0 -6px currentColor,
    0 9px 0 -6px currentColor,
    9px 0 0 -6px currentColor,
    -9px 0 0 -6px currentColor,
    6px 6px 0 -6px currentColor,
    -6px -6px 0 -6px currentColor,
    6px -6px 0 -6px currentColor,
    -6px 6px 0 -6px currentColor;
}

.blog-post-preview {
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  gap: 0;
  overflow: hidden;
}

html[data-theme="light"] .blog-post-preview {
  background: #ffffff;
}

.blog-post-preview-hero {
  align-items: center;
  background:
    linear-gradient(135deg, rgba(79, 209, 197, 0.22), rgba(255, 255, 255, 0.03)),
    var(--navy-soft);
  color: var(--text-primary);
  display: flex;
  min-height: 160px;
  padding: 20px;
}

html[data-theme="light"] .blog-post-preview-hero {
  background:
    linear-gradient(135deg, rgba(79, 209, 197, 0.2), rgba(255, 255, 255, 0.78)),
    #eff7f8;
}

.blog-post-preview-hero span {
  background: rgba(255, 255, 255, 0.09);
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text-secondary);
  font-size: 0.82rem;
  font-weight: 850;
  max-width: 100%;
  overflow: hidden;
  padding: 8px 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.blog-post-preview-hero img {
  display: block;
  height: 220px;
  margin: -20px;
  object-fit: cover;
  width: calc(100% + 40px);
}

.blog-post-preview-body {
  display: grid;
  gap: 10px;
  padding: 16px;
}

.blog-post-preview-body h4 {
  color: var(--text-primary);
  font-size: clamp(1.25rem, 2.8vw, 2rem);
  line-height: 1.08;
  margin: 0;
}

.blog-post-preview-body p {
  color: var(--text-secondary);
  margin: 0;
  white-space: pre-wrap;
}

.blog-post-preview-body small {
  color: var(--text-primary);
  font-weight: 850;
}

.message-unread-dot,
.message-unread-badge {
  position: absolute;
  top: 8px;
  right: 8px;
  border: 1px solid var(--bg-workspace);
  border-radius: 999px;
  background: #ef4444;
  box-shadow: 0 0 0 2px rgba(239, 68, 68, 0.16);
}

.message-unread-dot {
  width: 7px;
  height: 7px;
}

.message-unread-badge {
  align-items: center;
  color: #ffffff;
  display: inline-flex;
  font-size: 0.62rem;
  font-weight: 950;
  height: 17px;
  justify-content: center;
  min-width: 17px;
  padding: 0 4px;
  right: -7px;
  top: -8px;
}

html[data-theme="light"] .message-unread-dot,
html[data-theme="light"] .message-unread-badge {
  border-color: #f8fcfd;
}

.client-therapist-header-photo {
  width: 100%;
  max-height: 150px;
  object-fit: cover;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
}

.client-therapist-avatar {
  width: 58px;
  height: 58px;
  object-fit: cover;
  border: 1px solid rgba(94, 234, 212, 0.28);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
}

.blog-post-image {
  width: 100%;
  max-height: 180px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid rgba(94, 234, 212, 0.14);
}

.creator-tab {
  order: 0;
}

.active-journey-copy:hover strong,
.workspace-priority-pill:hover strong {
  color: #99f6e4;
}

html[data-theme="light"] .active-journey-copy:hover strong,
html[data-theme="light"] .workspace-priority-pill:hover strong {
  color: #0f8e91;
}

html[data-theme="light"] .active-journey-tools [data-open-notifications]:hover {
  color: #082535;
}

.tab-language-switcher {
  display: none !important;
  grid-template-columns: auto 112px;
  gap: 8px;
  align-items: center;
  margin-left: auto;
}

.tab-language-switcher select {
  min-height: 38px;
  padding: 6px 8px;
}

.tab-button {
  border-color: rgba(255, 255, 255, 0.22);
  background: rgba(255, 255, 255, 0.08);
  color: #f4fbfb;
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease, box-shadow 160ms ease;
}

.tab-button.active {
  border-color: var(--action);
  background: var(--action);
  color: var(--bg-page);
  box-shadow: 0 0 0 1px rgba(94, 234, 212, 0.18), 0 10px 24px rgba(94, 234, 212, 0.16);
}

.tab-button.locked-tab {
  border-color: rgba(245, 158, 11, 0.35);
  background: rgba(245, 158, 11, 0.12);
  color: #fde68a;
}

.tab-button[aria-disabled="true"] {
  cursor: not-allowed;
}

.creator-tab.active {
  border-color: #7af3e0;
  background: var(--accent);
  color: var(--bg-page);
}

.new-playlist-tab {
  order: 9;
  border-color: rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.035);
  color: var(--muted);
}

.new-playlist-tab:hover {
  border-color: rgba(94, 234, 212, 0.28);
  background: rgba(94, 234, 212, 0.08);
  color: var(--ink);
}

.mode-panel {
  display: none;
  max-width: 1180px;
  margin: 0 auto;
  padding: 18px 22px 38px;
}

.mode-panel.active {
  display: block;
}

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

body.facilitator-shell .hero,
body.facilitator-shell .mode-tabs,
body.facilitator-shell .mobile-quick-nav {
  display: none !important;
}

body.facilitator-shell #adminMode,
body.facilitator-shell #adminLogin,
body.facilitator-shell #adminWorkspace {
  display: none !important;
}

body.facilitator-shell .mode-panel.active {
  display: block !important;
}

body.facilitator-shell .top-workbar,
body.client-shell .top-workbar {
  display: grid !important;
}

body.facilitator-shell .workspace-quick-nav {
  display: flex;
}

body.facilitator-shell .app-shell {
  padding-left: 286px;
  background:
    radial-gradient(circle at 8% 0%, rgba(79, 209, 197, 0.14), transparent 30%),
    linear-gradient(180deg, var(--bg-canvas-soft) 0%, var(--bg-canvas) 44%, #c9dce4 100%);
}

body.client-shell .app-shell {
  padding-left: 286px;
  background:
    radial-gradient(circle at 8% 0%, rgba(79, 209, 197, 0.14), transparent 30%),
    linear-gradient(180deg, var(--bg-canvas-soft) 0%, var(--bg-canvas) 44%, #c9dce4 100%);
}

html[data-theme="light"] body.facilitator-shell .app-shell,
html[data-theme="light"] body.client-shell .app-shell {
  background:
    radial-gradient(circle at 8% 0%, rgba(79, 209, 197, 0.2), transparent 30%),
    linear-gradient(180deg, #f6fbfc 0%, var(--bg-canvas) 48%, #d1e5ed 100%);
}

body.facilitator-sidebar-collapsed.facilitator-shell .app-shell,
body.facilitator-sidebar-collapsed.client-shell .app-shell {
  padding-left: 86px;
}

body.facilitator-shell .mode-panel.active,
body.client-shell .mode-panel.active {
  max-width: none;
  margin: 0 22px 24px 0;
  padding: 20px 26px 34px 34px;
  border: 1px solid rgba(94, 234, 212, 0.14);
  border-top: 0;
  border-radius: 0 0 30px 30px;
  background: var(--bg-workspace);
  box-shadow: 0 26px 56px rgba(2, 12, 19, 0.24);
}

body.client-shell.client-sessions-route .mode-panel.active {
  box-shadow: none;
  contain: layout paint;
}

html[data-theme="light"] body.facilitator-shell .mode-panel.active,
html[data-theme="light"] body.client-shell .mode-panel.active {
  border-color: rgba(8, 37, 53, 0.12);
  background: var(--bg-workspace);
  box-shadow: 0 26px 56px rgba(31, 74, 92, 0.14);
}

html[data-theme="light"] body.client-shell.client-sessions-route .mode-panel.active {
  box-shadow: none;
}

body.facilitator-shell .profile-card,
body.facilitator-shell .history-entry,
body.facilitator-shell .workspace-context-box,
body.facilitator-shell .diary-board,
body.facilitator-shell .timeline-summary,
body.facilitator-shell .service-item {
  background: var(--bg-card);
}

body.client-shell .profile-card,
body.client-shell .history-entry,
body.client-shell .workspace-context-box,
body.client-shell .diary-board,
body.client-shell .timeline-summary,
body.client-shell .service-item {
  background: var(--bg-card);
}

html[data-theme="light"] body.facilitator-shell .profile-card,
html[data-theme="light"] body.client-shell .profile-card,
html[data-theme="light"] body.facilitator-shell .history-entry,
html[data-theme="light"] body.client-shell .history-entry,
html[data-theme="light"] body.facilitator-shell .workspace-context-box,
html[data-theme="light"] body.client-shell .workspace-context-box,
html[data-theme="light"] body.facilitator-shell .diary-board,
html[data-theme="light"] body.client-shell .diary-board,
html[data-theme="light"] body.facilitator-shell .timeline-summary,
html[data-theme="light"] body.client-shell .timeline-summary,
html[data-theme="light"] body.facilitator-shell .service-item,
html[data-theme="light"] body.client-shell .service-item {
  border-color: rgba(8, 37, 53, 0.12);
  background: rgba(248, 252, 253, 0.84);
}

body.client-shell .hero,
body.client-shell .mobile-quick-nav,
body.client-shell .mode-tabs {
  display: none !important;
}

.facilitator-sidebar {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  z-index: 24;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  gap: 12px;
  width: 270px;
  min-height: 0;
  padding: 18px 14px 16px;
  border-right: 1px solid rgba(94, 234, 212, 0.24);
  background:
    linear-gradient(180deg, rgba(6, 24, 38, 0.98), rgba(4, 17, 29, 0.98)),
    var(--bg-sidebar);
  box-shadow: 16px 0 44px rgba(0, 0, 0, 0.34);
  overflow: hidden;
}

html[data-theme="light"] .facilitator-sidebar {
  background:
    linear-gradient(180deg, rgba(231, 243, 246, 0.98), rgba(213, 230, 237, 0.98)),
    var(--bg-sidebar);
  box-shadow: 16px 0 44px rgba(31, 74, 92, 0.14);
}

body.facilitator-sidebar-collapsed .facilitator-sidebar {
  width: 72px;
  padding: 12px 8px;
}

.facilitator-sidebar-head {
  position: relative;
  z-index: 4;
  display: grid;
  gap: 12px;
}

.facilitator-sidebar-toggle {
  position: relative;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  border: 1px solid rgba(94, 234, 212, 0.22);
  background: rgba(18, 44, 63, 0.96);
  color: var(--action);
}

html[data-theme="light"] .facilitator-sidebar-toggle {
  background: rgba(247, 252, 253, 0.92);
}

.nav-icon {
  display: inline-grid;
  place-items: center;
  flex: 0 0 24px;
  min-width: 24px;
  min-height: 24px;
  font-size: 1rem;
  line-height: 1;
}

.nav-icon svg {
  display: block;
  width: 21px;
  height: 21px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

.nav-label {
  min-width: 0;
  flex: 1 1 auto;
  overflow: visible;
  text-overflow: clip;
  white-space: normal;
}

.sidebar-brand {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  width: 100%;
  min-height: 92px;
  padding: 14px 16px;
  text-align: left;
  border: 1px solid rgba(94, 234, 212, 0.24);
  border-radius: 20px;
  background: linear-gradient(180deg, rgba(17, 47, 68, 0.98), rgba(10, 31, 46, 0.98));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

html[data-theme="light"] .sidebar-brand {
  background: linear-gradient(180deg, rgba(248, 252, 253, 0.96), rgba(232, 244, 247, 0.96));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
}

body.facilitator-sidebar-collapsed .sidebar-brand {
  grid-template-columns: 1fr;
  min-height: 54px;
  padding: 7px;
}

body.facilitator-sidebar-collapsed .sidebar-brand-copy,
body.facilitator-sidebar-collapsed .nav-label,
body.facilitator-sidebar-collapsed .sidebar-group summary::after {
  display: none;
}

body.facilitator-sidebar-collapsed .sidebar-brand-media {
  width: 42px;
  height: 42px;
}

.sidebar-brand-copy {
  display: grid;
  min-width: 0;
  gap: 2px;
}

.sidebar-brand-copy strong,
.sidebar-brand-copy span {
  overflow: visible;
  text-overflow: clip;
  white-space: normal;
  line-height: 1.16;
}

.sidebar-brand-copy strong {
  color: var(--ink);
  font-size: 1.02rem;
  line-height: 1.12;
}

.sidebar-brand-copy span {
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.2;
}

.sidebar-brand-media {
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  border-radius: 8px;
  background: radial-gradient(circle at 38% 42%, rgba(94, 234, 212, 0.22), rgba(255, 255, 255, 0.05) 62%);
  overflow: hidden;
}

.sidebar-brand-media img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.sidebar-logo-fallback {
  font-size: 1.4rem;
}

.sidebar-impersonation {
  display: grid;
  gap: 6px;
  padding: 10px;
  border: 1px solid rgba(245, 158, 11, 0.35);
  border-radius: 8px;
  background: rgba(245, 158, 11, 0.12);
}

.sidebar-impersonation strong {
  color: #fde68a;
}

.sidebar-impersonation span {
  color: #fcd34d;
  font-size: 0.82rem;
}

.facilitator-sidebar-groups,
.facilitator-sidebar-footer {
  display: grid;
  gap: 10px;
}

.facilitator-sidebar-groups {
  min-height: 0;
  max-height: none;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  align-content: start;
  padding: 0 4px 16px 0;
  scrollbar-gutter: stable;
  scrollbar-width: thin;
  scrollbar-color: rgba(94, 234, 212, 0.46) rgba(255, 255, 255, 0.04);
}

.sidebar-group {
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 16px;
  background: rgba(16, 44, 63, 0.94);
  overflow: visible;
}

html[data-theme="light"] .sidebar-group {
  background: rgba(248, 252, 253, 0.82);
  border-color: rgba(8, 37, 53, 0.12);
}

.sidebar-group summary {
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-width: 0;
  min-height: 44px;
  padding: 11px 14px;
  cursor: pointer;
  color: var(--ink);
  font-weight: 900;
}

body.facilitator-sidebar-collapsed .sidebar-group summary,
body.facilitator-sidebar-collapsed .sidebar-group button,
body.facilitator-sidebar-collapsed .facilitator-sidebar-footer button {
  justify-content: center;
  padding: 11px 8px;
}

body.facilitator-sidebar-collapsed .facilitator-sidebar-groups {
  justify-items: center;
  padding: 0 0 16px;
  scrollbar-gutter: auto;
}

body.facilitator-sidebar-collapsed .sidebar-group[open] button {
  display: none;
}

.sidebar-group summary::after {
  content: "+";
  flex: 0 0 auto;
  font-size: 0.9rem;
  color: var(--action);
}

.sidebar-group[open] summary::after {
  content: "−";
}

.sidebar-group summary::-webkit-details-marker {
  display: none;
}

.sidebar-group button,
.facilitator-sidebar-footer button {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  min-height: 44px;
  padding: 10px 14px;
  border: 0;
  border-top: 1px solid rgba(94, 234, 212, 0.08);
  border-radius: 0;
  background: rgba(6, 24, 38, 0.18);
  color: var(--muted);
  text-align: left;
  line-height: 1.25;
  white-space: normal;
  overflow: visible;
}

html[data-theme="light"] .sidebar-group button,
html[data-theme="light"] .facilitator-sidebar-footer button {
  background: rgba(248, 252, 253, 0.54);
  color: var(--muted);
}

.sidebar-group[data-sidebar-group="music"] button {
  min-height: 44px;
  padding: 9px 12px;
  font-size: 0.86rem;
  line-height: 1.2;
  overflow-wrap: normal;
}

.sidebar-group[data-sidebar-group="clients"] button {
  min-height: 44px;
  padding: 9px 12px;
  font-size: 0.86rem;
  line-height: 1.2;
  overflow-wrap: normal;
}

.sidebar-group button:last-child {
  padding-bottom: 12px;
}

body.facilitator-shell .section-heading,
body.client-shell .section-heading {
  margin-bottom: 12px;
}

body.facilitator-shell .section-heading h1,
body.facilitator-shell .section-heading h2,
body.client-shell .section-heading h1,
body.client-shell .section-heading h2 {
  max-width: none;
  font-size: clamp(2rem, 3vw, 2.7rem);
  line-height: 1.05;
}

body.facilitator-shell .section-heading .lead,
body.client-shell .section-heading .lead {
  max-width: 860px;
  color: rgba(230, 237, 243, 0.82);
}

body.facilitator-shell .profile-card,
body.client-shell .profile-card,
body.facilitator-shell .history-entry,
body.client-shell .history-entry,
body.facilitator-shell .workspace-context-box,
body.client-shell .workspace-context-box {
  border-radius: 18px;
  border-color: rgba(94, 234, 212, 0.12);
}

.workspace-summary-card {
  align-content: start;
  min-height: 150px;
  padding: 20px;
  border: 1px solid rgba(94, 234, 212, 0.12);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.04);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.025);
}

.workspace-summary-card strong {
  font-size: clamp(2rem, 4vw, 3.1rem);
  line-height: 1;
  color: var(--ink);
}

.workspace-summary-card span {
  color: var(--ink);
  font-size: 0.98rem;
  font-weight: 800;
}

.workspace-summary-card small {
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.45;
}

#workspaceOverviewCards {
  display: block;
}

.workspace-ops-dashboard {
  display: grid;
  gap: 14px;
}

.workspace-today-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  align-items: end;
  padding: 16px;
  border: 1px solid rgba(94, 234, 212, 0.16);
  border-radius: 8px;
  background: linear-gradient(135deg, rgba(94, 234, 212, 0.12), rgba(255, 255, 255, 0.035));
}

.workspace-today-main {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.workspace-today-main h2 {
  margin: 0;
  color: var(--ink);
  font-size: clamp(1.35rem, 2.6vw, 2.05rem);
  line-height: 1.04;
}

.workspace-today-main p {
  max-width: 780px;
  margin: 0;
  color: var(--muted);
  line-height: 1.4;
}

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

.workspace-today-meta span,
.workspace-health-warning span {
  display: inline-flex;
  align-items: center;
  min-height: 25px;
  padding: 4px 8px;
  border: 1px solid rgba(94, 234, 212, 0.16);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.045);
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 850;
}

.workspace-today-actions,
.workspace-quick-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
  align-items: center;
}

.workspace-today-actions {
  align-content: end;
  min-width: 180px;
}

.workspace-action-chip {
  min-height: var(--control-compact-height);
  padding-inline: var(--control-compact-padding-x);
  font-size: 0.82rem;
}

.workspace-today-actions .secondary-button,
.workspace-quick-actions .secondary-button,
.workspace-panel-head .ghost-button {
  border-color: rgba(94, 234, 212, 0.18);
  background: rgba(255, 255, 255, 0.055);
  color: var(--ink);
  box-shadow: none;
}

.workspace-today-actions .secondary-button:hover,
.workspace-quick-actions .secondary-button:hover,
.workspace-panel-head .ghost-button:hover {
  border-color: rgba(94, 234, 212, 0.34);
  background: rgba(94, 234, 212, 0.1);
  color: var(--action);
}

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

.workspace-metric-card {
  display: grid;
  gap: 3px;
  min-width: 0;
  padding: 12px;
  border: 1px solid rgba(94, 234, 212, 0.12);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.workspace-metric-card strong {
  color: var(--ink);
  font-size: 1.35rem;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}

.workspace-metric-card span {
  color: var(--ink);
  font-size: 0.78rem;
  font-weight: 900;
}

.workspace-metric-card small {
  color: var(--muted);
  font-size: 0.72rem;
}

.workspace-ops-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1.05fr) minmax(260px, 0.7fr);
  gap: 12px;
  align-items: start;
}

.workspace-ops-panel {
  display: grid;
  gap: 10px;
  min-width: 0;
  padding: 14px;
  border: 1px solid rgba(94, 234, 212, 0.12);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

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

.workspace-panel-head h3 {
  margin: 0;
  color: var(--ink);
  font-size: 0.95rem;
}

.workspace-panel-head > span {
  padding: 3px 7px;
  border-radius: 999px;
  background: rgba(94, 234, 212, 0.12);
  color: var(--action);
  font-size: 0.72rem;
  font-weight: 900;
}

.workspace-dashboard-list,
.workspace-health-list {
  display: grid;
  gap: 8px;
}

.workspace-dashboard-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  width: 100%;
  min-width: 0;
  padding: 9px 10px;
  border: 1px solid rgba(94, 234, 212, 0.1);
  border-radius: 8px;
  background: rgba(7, 22, 33, 0.22);
  color: inherit;
  text-align: left;
  cursor: pointer;
}

.workspace-dashboard-row.passive {
  cursor: default;
}

.workspace-dashboard-row:hover {
  border-color: rgba(94, 234, 212, 0.26);
  background: rgba(94, 234, 212, 0.08);
}

.workspace-dashboard-row span {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.workspace-dashboard-row strong {
  overflow: hidden;
  color: var(--ink);
  font-size: 0.82rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.workspace-dashboard-row small {
  overflow: hidden;
  color: var(--muted);
  font-size: 0.72rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.workspace-dashboard-row em {
  color: var(--action);
  font-size: 0.7rem;
  font-style: normal;
  font-weight: 900;
  white-space: nowrap;
}

.workspace-health-list div {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid rgba(94, 234, 212, 0.1);
}

.workspace-health-list span {
  color: var(--muted);
  font-size: 0.78rem;
}

.workspace-health-list strong {
  color: var(--ink);
  font-size: 0.82rem;
  font-variant-numeric: tabular-nums;
}

.workspace-health-list small,
.workspace-empty-compact {
  color: var(--muted);
  font-size: 0.8rem;
}

.workspace-health-warning {
  display: flex !important;
  flex-wrap: wrap;
  gap: 6px;
  padding: 0 !important;
  border-bottom: 0 !important;
}

.sidebar-group button:hover,
.facilitator-sidebar-footer button:hover,
.sidebar-group button.active,
.facilitator-sidebar-footer button.active {
  background: #1c4f68;
  color: var(--action);
}

html[data-theme="light"] .sidebar-group button:hover,
html[data-theme="light"] .facilitator-sidebar-footer button:hover,
html[data-theme="light"] .sidebar-group button.active,
html[data-theme="light"] .facilitator-sidebar-footer button.active {
  background: rgba(15, 142, 145, 0.12);
  color: var(--action);
}

.sidebar-group button[disabled],
.facilitator-sidebar-footer button[disabled] {
  cursor: not-allowed;
  color: rgba(139, 148, 158, 0.6);
}

.facilitator-board {
  display: grid;
  gap: 16px;
}

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

.facilitator-view {
  display: none;
}

.facilitator-view.active {
  display: grid;
}

.client-view {
  display: none;
}

.client-view.active {
  display: grid;
}

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

.facilitator-split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.88fr);
  gap: 16px;
  align-items: start;
}

.facilitator-card,
.facilitator-subcard {
  align-content: start;
}

.facilitator-column-list,
.compact-list,
.facilitator-detail-columns {
  display: grid;
  gap: 12px;
}

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

body.client-shell.client-sessions-route .profile-card.client-view.active,
body.client-shell.client-sessions-route .history-entry,
body.client-shell.client-sessions-route .workspace-context-box,
body.client-shell.client-sessions-route .session-public-details {
  contain: layout paint;
}

.compact-heading {
  margin-bottom: 6px;
}

.filter-grid {
  align-items: end;
}

.filter-actions {
  display: flex;
  gap: 8px;
}

.history-entry {
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  text-align: left;
}

.compact-history {
  padding: 10px;
}

.history-entry > div {
  min-width: 0;
}

.history-entry strong,
.history-entry span,
.history-entry small {
  display: block;
}

.history-entry span,
.history-entry small {
  color: var(--muted);
}

.manual-invite-link-box {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid rgba(94, 234, 212, 0.44);
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.10);
}

.manual-invite-link-box strong,
.manual-invite-link-box span {
  display: block;
}

.manual-invite-link-box span {
  color: var(--muted);
}

.manual-invite-link-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
}

.manual-invite-link-row input {
  width: 100%;
  min-width: 0;
}

.inline-help-card {
  padding: 12px;
  border: 1px solid rgba(94, 234, 212, 0.34);
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.08);
}

.inline-help-card summary {
  cursor: pointer;
  color: var(--action);
  font-weight: 900;
}

.inline-help-card p {
  margin: 8px 0 0;
  color: var(--text-soft);
}

.client-entry.selected {
  border-color: rgba(94, 234, 212, 0.42);
  background: rgba(94, 234, 212, 0.12);
}

.client-management-list {
  gap: 10px;
}

.client-record {
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: var(--bg-card);
  overflow: hidden;
}

.client-record.selected {
  border-color: rgba(94, 234, 212, 0.42);
}

.client-record summary {
  list-style: none;
  cursor: pointer;
  padding: 12px 14px;
}

.client-record summary::-webkit-details-marker {
  display: none;
}

.client-record-summary {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 12px;
  align-items: start;
  position: relative;
}

.client-record-summary strong,
.client-record-summary span,
.client-record-summary small {
  display: block;
}

.client-record-summary span,
.client-record-summary small {
  color: var(--muted);
}

.client-record-body {
  display: grid;
  gap: 12px;
  padding: 0 14px 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

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

.client-record-summary-main,
.client-record-summary-side,
.client-record-sections,
.client-profile-edit-grid,
.client-profile-secondary-list,
.client-session-summary-block {
  display: grid;
  gap: 10px;
}

.client-record-summary-main {
  gap: 4px;
}

.client-record-summary-side {
  justify-items: end;
  text-align: right;
}

.client-record-sections,
.client-profile-primary-grid {
  margin-top: 2px;
}

.client-info-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.client-info-row {
  display: grid;
  gap: 2px;
  padding: 8px 10px;
  border: 1px solid rgba(94, 234, 212, 0.12);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.client-info-row span {
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 800;
}

.client-info-row strong {
  font-size: 0.88rem;
  line-height: 1.35;
}

.client-profile-section {
  display: grid;
  gap: 10px;
}

.client-secondary-section {
  padding: 10px;
  border: 1px solid rgba(94, 234, 212, 0.28);
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.075);
  transition: border-color 0.16s ease, background 0.16s ease;
}

.client-secondary-section summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  cursor: pointer;
  font-weight: 900;
}

.client-secondary-section summary::after {
  content: "+";
  width: 26px;
  height: 26px;
  display: inline-grid;
  place-items: center;
  border: 1px solid rgba(94, 234, 212, 0.28);
  border-radius: 999px;
  color: var(--accent);
  background: rgba(255, 255, 255, 0.06);
}

.client-secondary-section[open] {
  border-color: rgba(94, 234, 212, 0.46);
  background: rgba(94, 234, 212, 0.12);
}

.client-secondary-section[open] summary::after {
  content: "-";
}

.client-secondary-section:hover,
.client-secondary-section:focus-within {
  border-color: rgba(94, 234, 212, 0.5);
}

.client-secondary-section .compact-list {
  margin-top: 10px;
}

.client-profile-edit-grid {
  grid-template-columns: 1fr;
}

.client-actions-menu {
  position: relative;
  justify-self: end;
}

.client-actions-menu-button {
  width: 34px;
  height: 34px;
  min-width: 34px;
  padding: 0;
  line-height: 1;
}

.client-actions-menu-panel {
  position: absolute;
  z-index: 50;
  top: calc(100% + 6px);
  right: 0;
  min-width: 220px;
  display: grid;
  gap: 4px;
  padding: 8px;
  border: 1px solid rgba(94, 234, 212, 0.28);
  border-radius: 8px;
  background: var(--bg-card);
  box-shadow: 0 18px 42px rgba(2, 12, 20, 0.28);
}

.client-actions-menu-panel[hidden] {
  display: none;
}

.client-actions-menu-panel button {
  width: 100%;
  padding: 8px 10px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--text);
  text-align: left;
  font-weight: 850;
  cursor: pointer;
}

.client-actions-menu-panel button:hover,
.client-actions-menu-panel button:focus-visible {
  background: rgba(94, 234, 212, 0.12);
  outline: none;
}

.client-actions-menu-panel .danger-menu-item {
  color: var(--danger);
}

.empty-state-card {
  min-height: 180px;
  place-items: center;
  text-align: center;
}

.facilitator-client-detail {
  display: grid;
  gap: 14px;
}

.client-full-profile-heading {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.client-full-profile-heading > div:last-child {
  min-width: 0;
}

.client-full-profile-photo {
  display: inline-grid;
  flex: 0 0 auto;
  place-items: center;
  width: 72px;
  height: 72px;
  border: 1px solid rgba(94, 234, 212, 0.28);
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.08);
  color: var(--action);
  object-fit: cover;
  font-size: 1rem;
  font-weight: 950;
}

html[data-theme="light"] .client-full-profile-photo {
  border-color: rgba(15, 142, 145, 0.22);
  background: rgba(15, 142, 145, 0.08);
  color: #075e61;
}

.playlist-manage-card {
  gap: 12px;
}

.library-playlist-card {
  padding: 0;
}

.library-playlist-card[open] {
  padding-bottom: 16px;
}

.library-playlist-summary {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  min-height: 62px;
  padding: 14px 16px;
  cursor: pointer;
  list-style: none;
}

.library-playlist-summary::-webkit-details-marker {
  display: none;
}

.library-playlist-summary::after {
  content: "+";
  display: inline-grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border: 1px solid rgba(94, 234, 212, 0.22);
  border-radius: 8px;
  color: #a7fff3;
  font-weight: 950;
}

.library-playlist-card[open] .library-playlist-summary::after {
  content: "−";
}

.library-playlist-card > .workspace-badges,
.library-playlist-card > .playlist-manage-actions,
.library-playlist-card > .library-edit-form {
  margin-right: 16px;
  margin-left: 16px;
}

.playlist-manage-head,
.playlist-manage-actions,
.playlist-access-form,
.brand-preview-row {
  display: grid;
  gap: 10px;
}

.playlist-manage-head {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
}

.playlist-manage-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
}

.playlist-manage-actions > button,
.playlist-manage-actions > a {
  flex: 0 1 auto;
  min-width: 0;
}

.playlist-access-form {
  grid-template-columns: repeat(4, minmax(0, 1fr)) auto;
  align-items: end;
}

.followup-form-grid {
  display: grid;
  grid-template-columns: minmax(180px, 0.7fr) minmax(0, 1.3fr);
  gap: 12px;
  align-items: end;
}

.followup-clients-field {
  align-self: stretch;
}

.followup-time-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(120px, 1fr));
  gap: 10px;
  align-items: end;
  padding: 10px;
  border: 1px solid rgba(94, 234, 212, 0.12);
  border-radius: 8px;
  background: rgba(3, 10, 16, 0.18);
}

.followup-access-window {
  display: grid;
  gap: 8px;
}

.form-subsection-label {
  display: grid;
  gap: 2px;
  color: var(--ink);
}

.form-subsection-label strong {
  font-size: 0.9rem;
  font-weight: 950;
}

.form-subsection-label small {
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.35;
}

.followup-time-row label {
  min-width: 0;
}

.followup-time-row input {
  min-height: 42px;
}

.followup-client-picker {
  position: relative;
  display: grid;
  gap: 6px;
}

.followup-client-toggle {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 44px;
  border: 1px solid rgba(94, 234, 212, 0.22);
  background: rgba(255, 255, 255, 0.04);
  color: var(--ink);
}

.followup-selected-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  min-height: 0;
}

.followup-selected-chip {
  padding: 4px 8px;
  border: 1px solid rgba(94, 234, 212, 0.24);
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.08);
  color: #d9fffa;
  font-size: 0.76rem;
  font-weight: 850;
}

.followup-client-dropdown {
  position: absolute;
  top: calc(100% + 2px);
  left: 0;
  right: 0;
  z-index: 18;
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(6, 24, 38, 0.97);
  box-shadow: 0 20px 36px rgba(0, 0, 0, 0.28);
}

.followup-client-search {
  display: grid;
  gap: 6px;
}

.followup-client-options {
  display: grid;
  gap: 6px;
  max-height: 184px;
  overflow: auto;
}

.followup-client-option {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  min-height: 38px;
  padding: 4px 10px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.03);
}

.followup-client-option span {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

html[data-theme="light"] .followup-time-row {
  border-color: rgba(15, 142, 145, 0.16);
  background: rgba(255, 255, 255, 0.58);
}

html[data-theme="light"] .form-subsection-label {
  color: #082535;
}

html[data-theme="light"] .followup-client-toggle {
  border-color: rgba(15, 142, 145, 0.24);
  background: rgba(255, 255, 255, 0.94);
  color: #082535;
}

html[data-theme="light"] .followup-client-toggle:hover,
html[data-theme="light"] .followup-client-picker.open .followup-client-toggle {
  border-color: rgba(15, 142, 145, 0.44);
  background: rgba(15, 142, 145, 0.08);
}

html[data-theme="light"] .followup-selected-chip {
  border-color: rgba(15, 142, 145, 0.22);
  background: rgba(15, 142, 145, 0.08);
  color: #075e61;
}

html[data-theme="light"] .followup-client-dropdown {
  border-color: rgba(15, 142, 145, 0.22);
  background: rgba(248, 252, 253, 0.98);
  box-shadow: 0 20px 36px rgba(31, 74, 92, 0.18);
}

html[data-theme="light"] .followup-client-option {
  border-color: rgba(8, 37, 53, 0.12);
  background: rgba(255, 255, 255, 0.82);
  color: #082535;
}

html[data-theme="light"] .followup-client-option:hover,
html[data-theme="light"] .followup-client-option:focus-within {
  border-color: rgba(15, 142, 145, 0.32);
  background: rgba(15, 142, 145, 0.08);
}

html[data-theme="light"] .followup-client-option small {
  color: #456779;
}

.followup-client-option strong,
.followup-client-option small {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.followup-client-option strong {
  color: var(--ink);
  font-size: 0.79rem;
}

.followup-client-option small {
  color: var(--muted);
  font-size: 0.71rem;
}

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

.followup-form-grid .wide-field,
.followup-submit-row {
  grid-column: 1 / -1;
}

.therapist-review-create-card {
  margin-bottom: 16px;
}

.review-create-launcher,
.review-create-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.review-create-launcher {
  margin-bottom: 16px;
  padding: 14px;
  border: 1px solid rgba(94, 234, 212, 0.22);
  border-radius: 8px;
  background: rgba(8, 20, 32, 0.42);
}

html[data-theme="light"] .review-create-launcher {
  border-color: rgba(15, 142, 145, 0.18);
  background: linear-gradient(180deg, rgba(248, 252, 253, 0.96), rgba(228, 243, 247, 0.88));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72), 0 12px 26px rgba(31, 74, 92, 0.1);
}

.review-create-launcher strong,
.review-create-launcher span,
.review-create-header strong,
.review-create-header span {
  display: block;
}

.review-create-launcher span,
.review-create-header span {
  margin-top: 3px;
  color: var(--text-secondary);
  font-size: 0.86rem;
}

.therapist-review-create-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 14px;
}

.therapist-review-create-grid .wide-field {
  grid-column: 1 / -1;
}

.review-import-checkbox {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 48px;
  padding: 10px 12px;
  border: 1px solid rgba(79, 209, 197, 0.32);
  border-radius: 8px;
  background: rgba(18, 24, 33, 0.6);
  color: var(--text-soft);
  font-weight: 800;
}

html[data-theme="light"] .review-import-checkbox {
  border-color: rgba(15, 142, 145, 0.2);
  background: rgba(15, 142, 145, 0.07);
  color: #31586b;
}

.review-import-checkbox input {
  width: 18px;
  height: 18px;
}

.review-media-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 10px 0 12px;
  padding: 10px 12px;
  border: 1px solid rgba(79, 209, 197, 0.28);
  border-radius: 8px;
  background: rgba(18, 24, 33, 0.56);
}

html[data-theme="light"] .review-media-actions {
  border-color: rgba(15, 142, 145, 0.18);
  background: linear-gradient(180deg, rgba(235, 247, 249, 0.94), rgba(214, 235, 241, 0.86));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.68);
}

.review-media-status {
  color: var(--text-secondary);
  font-size: 0.84rem;
  font-weight: 900;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.review-media-status.ready {
  color: #bbf7d0;
}

html[data-theme="light"] .review-media-status.ready {
  color: #087f5b;
}

.review-media-status.warning {
  color: #fde68a;
}

html[data-theme="light"] .review-media-status.warning {
  color: #a16207;
}

.review-media-status.external {
  color: var(--accent);
}

.form-hint {
  align-self: center;
  color: var(--text-secondary);
  font-size: 0.86rem;
  font-weight: 800;
}

.followup-form-grid select[multiple] {
  min-height: 118px;
}

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

.followup-assignment-card {
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
  overflow: hidden;
}

.followup-assignment-summary {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 14px;
  cursor: pointer;
  list-style: none;
}

.followup-assignment-summary::-webkit-details-marker {
  display: none;
}

.followup-assignment-summary strong {
  display: block;
  color: var(--ink);
}

.followup-assignment-summary span {
  color: var(--muted);
  font-size: 0.88rem;
}

.followup-assignment-summary small {
  color: #a7fff3;
  font-weight: 850;
  text-align: right;
}

.followup-assignment-body {
  display: grid;
  gap: 12px;
  padding: 0 14px 14px;
}

.playlist-report-sheet {
  display: grid;
  gap: 18px;
}

.playlist-report-brand {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
}

.playlist-report-kicker {
  color: #8bd9ff;
  font-size: 0.76rem;
  font-weight: 950;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.playlist-report-brand h3 {
  margin: 6px 0 4px;
}

.playlist-report-brand p,
.playlist-report-meta span,
.playlist-report-empty {
  color: var(--muted);
}

.playlist-report-meta {
  display: grid;
  gap: 4px;
  justify-items: end;
  text-align: right;
}

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

.playlist-report-stat {
  display: grid;
  gap: 4px;
  padding: 16px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
}

.playlist-report-stat strong {
  font-size: 1.8rem;
  color: var(--ink);
}

.playlist-report-stat span {
  color: var(--muted);
}

.inline-label-card {
  display: grid;
  gap: 10px;
}

.inline-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.label-plain {
  display: block;
  color: var(--ink);
  font-size: 0.9rem;
  font-weight: 800;
}

.session-quick-client-panel {
  display: grid;
  gap: 12px;
  padding: 12px;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(6, 24, 38, 0.42);
}

.session-editor-grid,
.session-editor-block,
.session-site-editor,
.session-detail-stack {
  display: grid;
  gap: 14px;
}

.session-editor-block,
.session-site-editor {
  padding: 14px;
  border: 1px solid rgba(94, 234, 212, 0.16);
  border-radius: 8px;
  background: rgba(6, 24, 38, 0.32);
}

.session-editor-block h4,
.session-site-editor h4 {
  margin: 0;
  color: var(--action);
  font-size: 0.9rem;
  font-weight: 900;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.session-create-stack {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.session-create-section {
  display: block;
  min-width: 0;
  padding: 14px;
  border: 1px solid rgba(94, 234, 212, 0.16);
  border-radius: 8px;
  background: rgba(6, 24, 38, 0.32);
}

[data-facilitator-view="sessions-create"].active {
  border-color: rgba(94, 234, 212, 0.22);
  background: linear-gradient(180deg, rgba(16, 44, 63, 0.96), rgba(12, 34, 49, 0.92));
}

.session-create-section h4 {
  margin: 0 0 12px;
  color: var(--action);
  font-size: 0.9rem;
  font-weight: 900;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.session-create-fields {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: flex-start;
}

.session-create-fields > label,
.session-create-fields > .session-site-summary {
  flex: 1 1 260px;
  min-width: 0;
}

.session-create-fields > .wide-field,
.session-create-wide-field {
  flex-basis: 100%;
  width: 100%;
  min-width: 0;
}

.session-create-wide-field {
  display: block;
}

.session-create-wide-field textarea {
  width: 100%;
  box-sizing: border-box;
}

.training-program-builder {
  margin-bottom: 14px;
}

.training-basics-layout {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(220px, 0.9fr) minmax(220px, 0.9fr);
  gap: 12px;
  align-items: stretch;
}

.training-name-field,
.training-date-group {
  min-width: 0;
}

.training-date-group {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  padding: 10px;
  border: 1px solid rgba(94, 234, 212, 0.14);
  border-radius: 8px;
  background: rgba(3, 10, 16, 0.18);
}

.training-date-group .training-group-label {
  grid-column: 1 / -1;
  width: fit-content;
  padding: 4px 8px;
  border: 1px solid rgba(94, 234, 212, 0.22);
  border-radius: 999px;
  background: rgba(94, 234, 212, 0.08);
  color: #99f6e4;
  font-size: 0.68rem;
  font-weight: 950;
  text-transform: uppercase;
}

.training-basics-layout > .wide-field {
  grid-column: 1 / -1;
}

.training-format-field {
  flex: 0 1 220px;
  max-width: 260px;
}

.training-conditional-block {
  margin-top: 12px;
}

.training-conditional-block[hidden] {
  display: none;
}

.training-program-manage-card {
  border-color: rgba(94, 234, 212, 0.24);
}

.training-filter-panel {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px;
  align-items: end;
  margin-bottom: 12px;
  padding: 12px;
  border: 1px solid rgba(94, 234, 212, 0.14);
  border-radius: 8px;
  background: rgba(3, 10, 16, 0.18);
}

.training-filter-panel [data-clear-training-program-filters] {
  justify-self: start;
  align-self: end;
}

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

.training-event-editor {
  display: grid;
  gap: 12px;
  min-width: 0;
}

.training-event-card {
  align-items: flex-start;
}

.training-program-media {
  display: grid;
  gap: 12px;
  margin: 12px 0;
}

.training-cover-card {
  position: relative;
  min-height: 172px;
  margin: 0;
  overflow: hidden;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(3, 10, 16, 0.2);
}

.training-cover-card img {
  display: block;
  width: 100%;
  height: 220px;
  object-fit: cover;
}

.training-cover-card figcaption {
  position: absolute;
  left: 14px;
  bottom: 12px;
  max-width: calc(100% - 28px);
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(3, 10, 16, 0.72);
  color: #f8fafc;
  font-weight: 900;
}

.training-album-strip {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 2px;
}

.training-album-thumb {
  flex: 0 0 82px;
  width: 82px;
  height: 64px;
  padding: 0;
  overflow: hidden;
  border: 1px solid rgba(94, 234, 212, 0.22);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
}

.training-album-thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.training-meeting-shortcuts {
  margin-bottom: 10px;
}

.training-album-modal {
  display: grid;
  gap: 12px;
}

.training-album-modal > img {
  display: block;
  width: 100%;
  max-height: min(62vh, 620px);
  object-fit: contain;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(3, 10, 16, 0.22);
}

.training-album-modal-strip {
  display: flex;
  gap: 8px;
  overflow-x: auto;
}

.training-album-modal-strip button {
  flex: 0 0 74px;
  width: 74px;
  height: 56px;
  padding: 0;
  overflow: hidden;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
}

.training-album-modal-strip button.active {
  border-color: var(--action);
}

.training-album-modal-strip img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.session-site-summary,
.session-site-mini-card,
.session-public-details {
  display: grid;
  gap: 4px;
}

.session-site-mini-card,
.session-public-details {
  padding: 10px 12px;
  border: 1px solid rgba(94, 234, 212, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
}

.session-site-mini-card strong,
.session-public-details strong {
  color: var(--ink);
}

.session-site-mini-card span,
.session-public-details span,
.session-site-mini-card small,
.session-public-details small {
  color: var(--muted);
}

.session-player-prototype {
  gap: 12px;
}

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

.session-player-head > div:not(.session-player-time) {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.session-player-head .session-player-time {
  display: inline-flex;
  flex: 0 0 auto;
  gap: 5px;
  align-items: baseline;
  color: #99f6e4;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.session-player-time span:nth-child(2),
.session-player-time [data-session-player-duration] {
  color: rgba(224, 242, 254, 0.62);
  font-size: 0.82rem;
}

.session-player-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.session-player-transport,
.session-player-secondary-controls {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.session-player-transport {
  padding: 4px;
  border: 1px solid rgba(94, 234, 212, 0.14);
  border-radius: 8px;
  background: rgba(3, 10, 16, 0.18);
}

.session-player-icon-button {
  min-width: 38px;
  height: 34px;
  padding: 0 10px;
  justify-content: center;
  font-size: 0.78rem;
  font-weight: 900;
  line-height: 1;
}

.session-player-icon-button.primary-button {
  width: auto;
  min-width: 38px;
}

.session-player-state-button.is-active,
.session-player-icon-button.is-active,
.session-player-monitor.is-active {
  border-color: rgba(94, 234, 212, 0.7);
  background: linear-gradient(180deg, rgba(94, 234, 212, 0.24), rgba(20, 184, 166, 0.16));
  color: #ecfeff;
  box-shadow: 0 0 0 1px rgba(94, 234, 212, 0.12), 0 0 18px rgba(94, 234, 212, 0.18);
}

.session-player-state-button[data-session-player-control-state="preparing"] {
  border-color: rgba(251, 191, 36, 0.48);
  color: #fde68a;
}

.session-player-state-button[data-session-player-control-state="error"] {
  border-color: rgba(248, 113, 113, 0.52);
  color: #fecaca;
}

.session-player-waveform {
  position: relative;
  min-height: 64px;
  padding: 10px 0;
  cursor: pointer;
  overflow: hidden;
  border: 1px solid rgba(94, 234, 212, 0.16);
  border-radius: 8px;
  background: rgba(3, 10, 16, 0.24);
}

.session-player-waveform .waveform-bars {
  box-sizing: border-box;
  height: 44px;
  padding: 0 12px;
}

.session-player-monitor,
.session-player-volume {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  min-height: 34px;
  padding: 7px 10px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.2);
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
}

.session-player-volume {
  min-width: 250px;
  justify-content: space-between;
}

.session-player-volume input {
  width: min(145px, 34vw);
  accent-color: #5eead4;
}

.session-player-volume strong {
  min-width: 40px;
  color: #ccfbf1;
  font-size: 0.76rem;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.session-player-warning {
  color: #fbbf24 !important;
}

html[data-theme="light"] [data-facilitator-view="sessions-create"].active {
  border-color: rgba(15, 142, 145, 0.18);
  background: linear-gradient(180deg, rgba(248, 252, 253, 0.96), rgba(232, 244, 247, 0.9));
}

html[data-theme="light"] .session-create-section,
html[data-theme="light"] .session-quick-client-panel,
html[data-theme="light"] .training-date-group {
  border-color: rgba(15, 142, 145, 0.18);
  background: rgba(255, 255, 255, 0.68);
}

html[data-theme="light"] .session-create-section h4,
html[data-theme="light"] .session-site-editor h4 {
  color: #0b6f73;
}

html[data-theme="light"] .training-date-group .training-group-label {
  border-color: rgba(15, 142, 145, 0.22);
  background: rgba(15, 142, 145, 0.1);
  color: #0b6f73;
}

html[data-theme="light"] .session-site-mini-card,
html[data-theme="light"] .session-public-details {
  border-color: rgba(15, 142, 145, 0.16);
  background: rgba(255, 255, 255, 0.72);
}

html[data-theme="light"] .session-player-time {
  color: #0b6f73;
}

html[data-theme="light"] .session-player-time span:nth-child(2),
html[data-theme="light"] .session-player-time [data-session-player-duration] {
  color: rgba(15, 111, 115, 0.62);
}

html[data-theme="light"] .session-player-waveform {
  border-color: rgba(15, 142, 145, 0.16);
  background: rgba(255, 255, 255, 0.62);
}

html[data-theme="light"] .session-player-transport,
html[data-theme="light"] .session-player-monitor,
html[data-theme="light"] .session-player-volume {
  border-color: rgba(15, 142, 145, 0.16);
  background: rgba(255, 255, 255, 0.62);
}

html[data-theme="light"] .session-player-state-button.is-active,
html[data-theme="light"] .session-player-icon-button.is-active,
html[data-theme="light"] .session-player-monitor.is-active {
  border-color: rgba(15, 142, 145, 0.55);
  background: linear-gradient(180deg, rgba(15, 142, 145, 0.18), rgba(94, 234, 212, 0.14));
  color: #07575b;
}

html[data-theme="light"] .session-player-volume strong {
  color: #0b6f73;
}

.library-toolbar {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(160px, 220px) auto;
  gap: 10px;
  align-items: end;
  margin-bottom: 12px;
  padding: 12px;
  border: 1px solid rgba(94, 234, 212, 0.14);
  border-radius: 8px;
  background: rgba(3, 10, 16, 0.18);
}

.library-search-field,
.library-filter-field {
  min-width: 0;
}

.library-add-details {
  border-style: dashed;
}

.custom-file-upload {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  min-height: 52px;
  padding: 8px;
  border: 1px solid rgba(94, 234, 212, 0.2);
  border-radius: 8px;
  background: rgba(3, 10, 16, 0.22);
}

.custom-file-upload input[type="file"] {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.custom-file-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  padding: 0 14px;
  border: 1px solid rgba(94, 234, 212, 0.28);
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.1);
  color: var(--ink);
  font-size: 0.82rem;
  font-weight: 900;
  cursor: pointer;
}

.custom-file-upload:focus-within .custom-file-button,
.custom-file-upload:hover .custom-file-button {
  border-color: rgba(94, 234, 212, 0.52);
  background: rgba(94, 234, 212, 0.16);
}

.custom-file-name {
  min-width: 0;
  overflow: hidden;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.library-upload-status {
  --upload-progress: 0%;
  display: flex;
  gap: 12px;
  align-items: center;
  padding: 12px;
  border: 1px solid rgba(94, 234, 212, 0.22);
  border-radius: 8px;
  background: rgba(3, 10, 16, 0.28);
}

.library-upload-status[hidden] {
  display: none;
}

.library-upload-orb {
  width: 34px;
  height: 34px;
  flex: 0 0 auto;
  border-radius: 999px;
  background:
    conic-gradient(from 0deg, #5eead4 var(--upload-progress), rgba(94, 234, 212, 0.12) 0),
    radial-gradient(circle at center, rgba(6, 24, 38, 0.95) 0 54%, transparent 56%);
  box-shadow: 0 0 18px rgba(94, 234, 212, 0.34);
  animation: buttonSpinner 900ms linear infinite;
}

.library-upload-status strong,
.library-upload-status span {
  display: block;
}

.library-upload-status span {
  color: var(--muted);
  font-size: 0.8rem;
}

html[data-theme="light"] .library-upload-status {
  border-color: rgba(15, 142, 145, 0.2);
  background: rgba(255, 255, 255, 0.72);
}

html[data-theme="light"] .library-toolbar,
html[data-theme="light"] .custom-file-upload {
  border-color: rgba(15, 142, 145, 0.16);
  background: rgba(255, 255, 255, 0.72);
}

html[data-theme="light"] .custom-file-button {
  border-color: rgba(15, 142, 145, 0.24);
  background: rgba(15, 142, 145, 0.08);
  color: #075e61;
}

html[data-theme="light"] .custom-file-upload:focus-within .custom-file-button,
html[data-theme="light"] .custom-file-upload:hover .custom-file-button {
  border-color: rgba(15, 142, 145, 0.44);
  background: rgba(15, 142, 145, 0.12);
}

.session-site-layout {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 14px;
}

.session-site-search-details {
  border: 1px solid rgba(94, 234, 212, 0.16);
  border-radius: 8px;
  background: rgba(6, 24, 38, 0.2);
}

.session-site-search-details > summary {
  align-items: center;
  cursor: pointer;
  display: flex;
  gap: 10px;
  justify-content: space-between;
  list-style: none;
  min-height: 42px;
  padding: 7px 12px;
  color: var(--text-primary);
  font-weight: 900;
}

.session-site-search-details > summary::-webkit-details-marker {
  display: none;
}

.session-site-search-details > summary::after {
  content: "+";
  color: var(--accent);
  font-size: 1.2rem;
  font-weight: 900;
}

.session-site-search-details[open] > summary::after {
  content: "-";
}

.session-site-search-details .session-site-filter-panel {
  border-left: 0;
  border-right: 0;
  border-bottom: 0;
  border-radius: 0 0 8px 8px;
  margin: 8px 0 0;
}

.session-site-filter-panel {
  display: grid;
  grid-template-columns: repeat(4, minmax(150px, 1fr));
  align-items: end;
  gap: 8px 10px;
  margin-bottom: 14px;
  padding: 10px;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(6, 24, 38, 0.34);
}

.session-site-filter-panel label,
.site-price-range {
  min-width: 0;
  display: grid;
  align-content: end;
  gap: 4px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 900;
}

.session-site-filter-panel input,
.session-site-filter-panel select {
  min-height: 42px;
  padding: 9px 12px;
  font-size: 0.95rem;
}

.site-price-range {
  grid-column: span 2;
}

.site-price-range span {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 900;
}

.site-price-range input[type="range"] {
  width: 100%;
  min-height: 32px;
  padding: 0;
}

html[data-theme="light"] .session-site-filter-panel {
  border-color: rgba(15, 142, 145, 0.18);
  background: rgba(255, 255, 255, 0.76);
  box-shadow: 0 12px 26px rgba(31, 74, 92, 0.08);
}

html[data-theme="light"] .session-site-search-details {
  background: rgba(255, 255, 255, 0.64);
  border-color: rgba(15, 142, 145, 0.14);
}

html[data-theme="light"] .session-site-filter-panel label,
html[data-theme="light"] .site-price-range,
html[data-theme="light"] .site-price-range span {
  color: #365c70;
}

html[data-theme="light"] .session-site-filter-panel input,
html[data-theme="light"] .session-site-filter-panel select {
  border-color: rgba(15, 142, 145, 0.22);
  background: rgba(255, 255, 255, 0.98);
  color: #082535;
}

html[data-theme="light"] .session-site-filter-panel input:hover,
html[data-theme="light"] .session-site-filter-panel select:hover,
html[data-theme="light"] .session-site-filter-panel input:focus,
html[data-theme="light"] .session-site-filter-panel select:focus {
  border-color: rgba(15, 142, 145, 0.44);
  background: #ffffff;
}

.session-site-list {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 10px;
}

.session-site-card {
  cursor: pointer;
}

.session-site-card:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

.session-site-detail-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(23, 62, 85, 0.2);
}

.session-site-detail-header p {
  margin: 0;
  color: var(--muted);
}

.status-pill {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: 6px 10px;
  border: 1px solid rgba(94, 234, 212, 0.35);
  border-radius: 999px;
  background: rgba(94, 234, 212, 0.08);
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.status-pill.is-muted {
  border-color: rgba(148, 163, 184, 0.32);
  color: var(--muted);
}

.session-site-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.session-site-detail-row {
  display: grid;
  gap: 4px;
  min-width: 0;
  padding: 10px 12px;
  border: 1px solid rgba(94, 234, 212, 0.14);
  border-radius: 8px;
  background: rgba(23, 62, 85, 0.16);
}

.session-site-detail-row span {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.session-site-detail-row strong {
  color: var(--ink);
  overflow-wrap: anywhere;
}

html[data-theme="light"] .session-site-detail-header {
  border-color: rgba(15, 142, 145, 0.16);
  background: rgba(248, 252, 253, 0.9);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.7);
}

html[data-theme="light"] .session-site-detail-row {
  border-color: rgba(15, 142, 145, 0.14);
  background: rgba(255, 255, 255, 0.78);
}

html[data-theme="light"] .session-site-detail-row span {
  color: #477184;
}

html[data-theme="light"] .session-site-detail-row strong {
  color: #082535;
}

.session-site-fields {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 12px;
  margin-top: 12px;
}

.session-site-fields > label,
.session-site-fields > .session-site-summary {
  grid-column: span 2;
  min-width: 0;
}

.session-site-fields > .wide-field,
.session-site-fields > .form-section-title,
.session-site-fields > .session-create-wide-field {
  grid-column: 1 / -1;
  width: 100%;
}

.session-site-fields .address-field-postal,
.session-site-fields .address-field-timezone {
  grid-column: span 2;
}

@media (max-width: 1024px) and (min-width: 761px) {
  .session-site-fields {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .session-site-fields > label,
  .session-site-fields .address-field-postal,
  .session-site-fields .address-field-timezone {
    grid-column: span 1;
  }

  .session-site-fields > .wide-field,
  .session-site-fields > .form-section-title,
  .session-site-fields > .session-create-wide-field {
    grid-column: 1 / -1;
  }
}

.session-site-gallery-preview,
.session-public-gallery {
  display: grid;
  gap: 8px;
}

.session-site-gallery-preview {
  grid-template-columns: repeat(auto-fit, minmax(128px, 1fr));
}

.session-site-gallery-item {
  display: grid;
  gap: 8px;
  padding: 8px;
  border: 1px solid rgba(94, 234, 212, 0.16);
  border-radius: 8px;
  background: rgba(6, 24, 38, 0.42);
}

.session-site-gallery-item img,
.session-public-gallery img {
  width: 100%;
  aspect-ratio: 16 / 10;
  border-radius: 8px;
  object-fit: cover;
  background: rgba(255, 255, 255, 0.06);
  contain: paint;
}

.session-site-gallery-item span {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 900;
}

.session-public-gallery {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.session-music-input-card,
.client-session-music-input {
  border-color: rgba(79, 209, 197, 0.24);
  background: rgba(79, 209, 197, 0.08);
}

.client-session-music-input {
  display: grid;
  gap: 12px;
  padding: 12px;
  border: 1px solid rgba(79, 209, 197, 0.22);
  border-radius: 8px;
}

.client-session-music-input summary {
  color: var(--action);
  cursor: pointer;
  font-weight: 900;
}

.client-session-card-v1 {
  gap: 7px;
  align-content: start;
  min-height: 0;
  padding: 10px 12px;
}

.client-session-card-v1[data-client-session-card] {
  cursor: pointer;
}

.client-session-card-v1[data-client-session-card]:focus-visible {
  outline: 3px solid rgba(79, 209, 197, 0.34);
  outline-offset: 2px;
}

.client-sessions-layout {
  grid-template-columns: minmax(0, 1fr);
  align-items: start;
}

.client-sessions-layout > .history-entry {
  align-content: start;
}

#clientUpcomingSessions,
#clientPastSessions,
#clientCancelledSessions {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 8px;
}

.client-session-tabs {
  display: flex;
  flex-wrap: nowrap;
  gap: 8px;
  max-width: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  padding: 0 0 6px;
  scrollbar-width: none;
  scroll-snap-type: x proximity;
  -webkit-overflow-scrolling: touch;
}

.client-session-tabs::-webkit-scrollbar {
  display: none;
}

.client-session-tabs button {
  flex: 0 0 auto;
  min-height: 34px;
  padding: 0 13px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font: inherit;
  font-size: 0.86rem;
  font-weight: 950;
  scroll-snap-align: start;
  white-space: nowrap;
}

.client-session-tabs button.active {
  border-color: rgba(94, 234, 212, 0.28);
  background: rgba(94, 234, 212, 0.12);
  color: var(--action);
}

.client-session-tab-panel {
  gap: 8px;
  padding: 0;
  border: 0;
  background: transparent;
  display: none;
}

.client-session-tab-panel.active {
  display: grid;
}

.client-session-card-top,
.client-session-title-row,
.client-session-access-row,
.client-session-action-row {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.client-session-card-top,
.client-session-title-row,
.client-session-access-row {
  justify-content: space-between;
}

.client-session-card-top {
  flex-wrap: wrap;
}

.client-session-inline-head > strong {
  flex: 999 1 220px;
  overflow: hidden;
  color: var(--ink);
  font-size: 0.98rem;
  line-height: 1.15;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.client-session-time {
  color: var(--ink);
  flex: 1 1 190px;
  font-size: 0.84rem;
  font-weight: 950;
  text-align: right;
  white-space: nowrap;
}

.client-session-title-block {
  display: grid;
  gap: 4px;
  width: 100%;
  min-width: 0;
}

.client-session-title-block > strong {
  overflow: hidden;
  font-size: 1.02rem;
  line-height: 1.15;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.client-session-meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 800;
}

.client-session-meta-row span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.client-session-meta-row span + span::before {
  content: "";
  width: 4px;
  height: 4px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.58);
}

.client-session-access-row {
  flex-wrap: wrap;
  min-height: 0;
  padding: 8px 10px;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
}

.client-session-access-row > div {
  flex: 1 1 260px;
  display: grid;
  gap: 2px;
  min-width: 0;
}

.client-session-access-row strong,
.client-session-access-row small {
  display: block;
}

.client-session-access-row small {
  color: var(--muted);
  line-height: 1.25;
}

.client-session-access-row .compact-button {
  flex: 0 0 auto;
  min-height: 32px;
  max-width: 100%;
  min-width: max-content;
}

.client-session-access-row.online {
  border-color: rgba(79, 209, 197, 0.28);
  background: rgba(79, 209, 197, 0.1);
}

.client-session-access-row.pending {
  border-color: rgba(148, 163, 184, 0.22);
  background: rgba(148, 163, 184, 0.08);
}

.client-session-access-row.cancelled {
  border-color: rgba(248, 113, 113, 0.24);
  background: rgba(248, 113, 113, 0.08);
}

.client-session-action-row {
  flex-wrap: wrap;
  gap: 6px;
  padding-top: 0;
}

.client-session-action-row .compact-button {
  min-height: 32px;
  padding-inline: 11px;
}

.client-session-secondary-details {
  border: 1px solid rgba(94, 234, 212, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.03);
}

.client-session-secondary-details summary {
  padding: 9px 10px;
  color: var(--muted);
  cursor: pointer;
  font-size: 0.84rem;
  font-weight: 900;
}

.client-session-secondary-details .form-hint {
  padding: 0 10px 8px;
}

.client-session-past-card {
  gap: 7px;
}

.client-session-cancelled-card {
  gap: 7px;
}

.client-session-feedback-details {
  border: 1px solid rgba(94, 234, 212, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.03);
}

.client-session-feedback-details summary {
  padding: 9px 10px;
  color: var(--action);
  cursor: pointer;
  font-size: 0.84rem;
  font-weight: 950;
}

.client-session-feedback-form {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 0;
  padding: 10px;
}

@media (max-width: 640px) {
  .practitioner-session-card {
    display: grid;
    grid-template-rows: auto;
    align-content: start;
  }

  .practitioner-session-head,
  .practitioner-session-actions {
    justify-content: flex-start;
    align-items: stretch;
  }

  .practitioner-session-head > strong,
  .practitioner-session-head > span:not(.session-status-badge) {
    flex-basis: 100%;
    white-space: normal;
  }

  .practitioner-session-actions .compact-button {
    min-height: 44px;
  }

  .client-session-tabs button,
  .client-session-action-row .compact-button,
  .client-session-feedback-details summary {
    min-height: 44px;
  }

  .client-session-card-v1 {
    display: grid;
    grid-template-rows: auto;
    align-content: start;
    height: auto;
  }

  .client-session-card-top,
  .client-session-title-row,
  .client-session-access-row {
    justify-content: flex-start;
    align-items: stretch;
    flex-direction: column;
  }

  .client-session-access-row > div {
    align-content: start;
  }

  .client-session-time {
    flex: 0 1 auto;
    text-align: left;
    white-space: normal;
  }

  .client-session-inline-head > strong {
    flex: 0 1 auto;
    white-space: normal;
  }

  .client-session-access-row .compact-button {
    min-width: 0;
    width: 100%;
  }

  .client-session-feedback-form {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 900px) {
  .client-session-tabs button,
  .client-session-action-row .compact-button,
  .client-session-feedback-details summary {
    min-height: 44px;
  }

  .client-session-card-v1 {
    display: grid;
    grid-template-rows: auto;
    align-content: start;
    height: auto;
  }

  .client-session-card-top,
  .client-session-title-row,
  .client-session-access-row {
    justify-content: flex-start;
    align-items: stretch;
    flex-direction: column;
  }

  .client-session-access-row > div {
    align-content: start;
  }

  .client-session-time {
    flex: 0 1 auto;
    text-align: left;
    white-space: normal;
  }

  .client-session-inline-head > strong {
    flex: 0 1 auto;
    white-space: normal;
  }

  .client-session-access-row .compact-button {
    min-width: 0;
    width: 100%;
  }

  .client-session-feedback-form {
    grid-template-columns: minmax(0, 1fr);
  }
}

.compact-button-row {
  gap: 6px;
}

.integration-status-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px;
  border: 1px solid rgba(94, 234, 212, 0.2);
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.08);
}

.integration-status-card strong,
.integration-status-card span {
  display: block;
}

.integration-status-card strong {
  color: var(--ink);
  font-size: 0.98rem;
}

.integration-status-card span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 0.84rem;
  line-height: 1.35;
}

.integration-status-card .button-row {
  flex: 0 0 auto;
}

@media (max-width: 760px) {
  .integration-status-card {
    align-items: stretch;
    flex-direction: column;
  }

  .integration-status-card .button-row,
  .integration-status-card .button-row .compact-button {
    width: 100%;
  }
}

.session-calendar-shell {
  display: grid;
  gap: 10px;
  margin-bottom: 14px;
  padding: 12px;
  border: 1px solid rgba(94, 234, 212, 0.14);
  border-radius: 8px;
  background: rgba(6, 24, 38, 0.28);
}

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

.session-calendar-head {
  grid-template-columns: 1fr auto;
  align-items: center;
}

.session-calendar-head strong {
  color: var(--ink);
}

.session-calendar-head span,
.session-calendar-weekdays span {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
}

.session-calendar-cell {
  min-height: 70px;
  display: grid;
  align-content: start;
  gap: 4px;
  padding: 8px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.025);
  color: var(--muted);
  text-align: left;
}

.session-calendar-cell.has-session {
  border-color: rgba(94, 234, 212, 0.28);
  background: rgba(79, 209, 197, 0.12);
  color: var(--ink);
  cursor: pointer;
}

.session-calendar-cell.has-session:hover {
  background: rgba(79, 209, 197, 0.18);
}

.session-calendar-cell small {
  overflow: hidden;
  color: var(--action);
  font-size: 0.68rem;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.session-calendar-cell.muted {
  pointer-events: none;
  opacity: 0.35;
}

.compact-form-grid {
  gap: 10px;
}

.followup-assignment-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.followup-assignment-meta {
  display: grid;
  gap: 6px;
  justify-items: end;
}

.followup-status-badge {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border: 1px solid rgba(94, 234, 212, 0.22);
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.followup-status-badge.waiting {
  border-color: rgba(245, 158, 11, 0.36);
  background: rgba(245, 158, 11, 0.12);
  color: #fcd34d;
}

.followup-status-badge.feedback {
  border-color: rgba(34, 197, 94, 0.34);
  background: rgba(34, 197, 94, 0.14);
  color: #bbf7d0;
}

.followup-status-badge.ended {
  border-color: rgba(239, 68, 68, 0.4);
  background: rgba(239, 68, 68, 0.14);
  color: #fecaca;
}

.playlist-report-section {
  display: grid;
  gap: 12px;
}

.playlist-report-bar {
  display: grid;
  gap: 6px;
}

.playlist-report-bar-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--ink);
  font-size: 0.92rem;
  font-weight: 850;
}

.playlist-report-meter {
  height: 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.playlist-report-meter-fill {
  height: 100%;
  background: var(--accent);
}

.external-link-button {
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.library-edit-form,
.followup-edit-form {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid rgba(94, 234, 212, 0.12);
}

.followup-edit-form {
  grid-template-columns: minmax(120px, 0.5fr) minmax(0, 2fr) minmax(110px, 0.5fr);
  align-items: end;
}

.followup-time-row-edit {
  padding: 0;
  border: 0;
  background: transparent;
}

.compact-report-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.session-rating-card summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  cursor: pointer;
}

.session-rating-body {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid rgba(94, 234, 212, 0.12);
}

.session-rating-body select {
  margin-top: 6px;
}

.brand-preview-row {
  grid-template-columns: 72px 1fr;
  align-items: center;
}

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

.professional-preview-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.brand-preview-row img,
.empty-brand-logo {
  width: 72px;
  height: 72px;
  border: 1px solid rgba(94, 234, 212, 0.22);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
}

.brand-preview-row img {
  object-fit: cover;
}

.brand-preview-row .header-photo-preview {
  width: min(220px, 100%);
  height: 72px;
}

.brand-preview-row .profile-photo-preview {
  border-radius: 50%;
}

.empty-brand-logo {
  display: grid;
  place-items: center;
  color: var(--muted);
  font-weight: 850;
}

.password-field {
  position: relative;
  display: block;
}

.password-field input {
  padding-right: 48px;
}

input::placeholder,
textarea::placeholder {
  color: rgba(226, 232, 240, 0.18);
  opacity: 1;
}

html[data-theme="light"] input::placeholder,
html[data-theme="light"] textarea::placeholder {
  color: rgba(10, 34, 50, 0.18);
}

.facilitator-sidebar-footer {
  align-content: end;
  position: static;
  min-height: 0;
  padding-top: 8px;
  background: var(--bg-sidebar);
}

.sidebar-language-picker {
  display: none !important;
  grid-template-columns: minmax(0, 1fr);
  align-items: center;
  gap: 0;
  padding: 4px 8px;
  border: 1px solid rgba(94, 234, 212, 0.14);
  border-radius: 8px;
  background: rgba(19, 52, 71, 0.9);
  max-width: none;
}

.sidebar-language-picker span {
  color: var(--muted);
  font-size: 0.72rem;
  white-space: nowrap;
}

.sidebar-language-picker select {
  width: 100%;
  min-width: 0;
  min-height: 30px;
  padding: 3px 8px;
  font-size: 0.8rem;
}

.active-journey-bar {
  min-height: 42px;
}

.active-journey-copy {
  margin-right: 0;
}

.active-journey-tools {
  gap: 10px;
}

.workspace-priority-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  max-width: min(620px, 54vw);
  padding: 8px 12px;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--ink);
  font-size: 0.82rem;
  line-height: 1.3;
  text-align: left;
}

button.workspace-priority-pill {
  cursor: pointer;
  font: inherit;
}

button.workspace-priority-pill:disabled {
  cursor: default;
  opacity: 0.72;
}

.workspace-priority-pill strong {
  color: var(--action);
  white-space: nowrap;
}

.workspace-priority-pill span {
  min-width: 0;
}

.client-header-tools {
  flex-wrap: wrap;
}

.client-priority-wrap {
  min-width: 0;
}

.client-priority-wrap .client-priority-pill {
  width: 100%;
}

.client-header-identity .client-header-practitioner-line {
  color: var(--text-soft);
}

.client-practitioner-pill {
  cursor: pointer;
}

.client-practitioner-pill:hover,
.client-practitioner-pill:focus-visible {
  border-color: rgba(94, 234, 212, 0.36);
  background: rgba(94, 234, 212, 0.1);
  outline: none;
}

html[data-theme="light"] .client-practitioner-pill:hover,
html[data-theme="light"] .client-practitioner-pill:focus-visible {
  border-color: rgba(15, 142, 145, 0.3);
  background: rgba(15, 142, 145, 0.08);
}

.client-sidebar-status-card,
.facilitator-sidebar-status-card {
  display: grid;
  gap: 4px;
  margin: 4px 4px 0;
  padding: 10px 12px;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
}

.client-sidebar-status-card span,
.facilitator-sidebar-status-card span {
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 950;
  text-transform: uppercase;
}

.client-sidebar-status-card strong,
.facilitator-sidebar-status-card strong {
  color: var(--action);
  font-size: 0.84rem;
}

html[data-theme="light"] .client-sidebar-status-card,
html[data-theme="light"] .facilitator-sidebar-status-card {
  border-color: rgba(15, 142, 145, 0.16);
  background: rgba(15, 142, 145, 0.07);
}

.facilitator-sidebar-status-card.saving strong {
  color: #f5d76e;
}

.facilitator-sidebar-status-card.error strong {
  color: #ff9b9b;
}

body.facilitator-shell .facilitator-sidebar-status-card {
  display: none;
}

.upcoming-session-card {
  cursor: pointer;
  transition: border-color 160ms ease, background 160ms ease, transform 160ms ease;
}

.upcoming-session-card:hover {
  border-color: rgba(94, 234, 212, 0.3);
  background: rgba(255, 255, 255, 0.06);
  transform: translateY(-1px);
}

.upcoming-session-card .playlist-manage-actions {
  margin-top: 8px;
}

.practitioner-session-card {
  gap: 7px;
  align-content: start;
  max-width: 760px;
  padding: 10px 11px;
}

.practitioner-session-head,
.practitioner-session-meta,
.practitioner-session-actions {
  display: flex;
  align-items: center;
  min-width: 0;
}

.practitioner-session-head {
  gap: 8px;
  flex-wrap: wrap;
}

.practitioner-session-head > strong {
  flex: 0 1 auto;
  max-width: 260px;
  overflow: hidden;
  color: var(--ink);
  font-size: 1rem;
  line-height: 1.18;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.practitioner-session-head > span:not(.session-status-badge) {
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 950;
  white-space: nowrap;
}

.practitioner-session-meta,
.practitioner-session-actions {
  flex-wrap: wrap;
  gap: 6px;
}

.practitioner-session-meta {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 850;
}

.practitioner-session-meta span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.practitioner-session-meta span + span::before {
  content: "";
  width: 4px;
  height: 4px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.58);
}

.practitioner-session-access {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  width: fit-content;
  max-width: 100%;
  min-width: 0;
  padding: 5px 8px;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
}

.practitioner-session-access.cancelled {
  display: grid;
  gap: 2px;
  width: 100%;
  padding: 8px 10px;
}

.practitioner-session-access.cancelled strong,
.practitioner-session-access.cancelled span {
  display: block;
}

.practitioner-session-access span {
  color: var(--muted);
  font-size: 0.84rem;
  line-height: 1.25;
}

.practitioner-session-access.online {
  border-color: rgba(79, 209, 197, 0.28);
  background: rgba(79, 209, 197, 0.1);
}

.practitioner-session-online-icon {
  flex: 0 0 auto;
  font-size: 0.95rem;
  line-height: 1;
}

.practitioner-session-access.place {
  border-color: rgba(251, 191, 36, 0.24);
  background: rgba(251, 191, 36, 0.08);
}

.practitioner-session-access.cancelled {
  border-color: rgba(248, 113, 113, 0.24);
  background: rgba(248, 113, 113, 0.08);
}

.practitioner-session-actions .compact-button {
  min-height: 32px;
  padding-inline: 10px;
}

.practitioner-session-open-button {
  min-width: 64px;
}

.practitioner-session-cancel-button {
  border-color: rgba(248, 113, 113, 0.28);
  background: rgba(248, 113, 113, 0.1);
  color: #fecaca;
}

.practitioner-session-delete-placeholder {
  opacity: 0.7;
}

.session-cancel-confirm-checkbox {
  margin-bottom: 8px;
}

.practitioner-session-feedback {
  max-width: 760px;
}

.session-status-card {
  border-left: 6px solid rgba(94, 234, 212, 0.74);
}

.session-status-card.planned {
  border-left-color: rgba(94, 234, 212, 0.82);
}

.session-status-card.completed {
  border-left-color: rgba(34, 197, 94, 0.82);
}

.session-status-card.cancelled {
  border-color: rgba(239, 68, 68, 0.42);
  border-left-color: rgba(239, 68, 68, 0.95);
  background: linear-gradient(180deg, rgba(127, 29, 29, 0.16), rgba(6, 24, 38, 0.38));
}

.session-card-main,
.session-detail-status-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  min-width: 0;
}

.session-card-main > div {
  min-width: 0;
}

.session-status-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  width: fit-content;
  min-height: 28px;
  padding: 5px 9px;
  border: 1px solid rgba(94, 234, 212, 0.34);
  border-radius: 999px;
  background: rgba(94, 234, 212, 0.1);
  color: #99f6e4;
  font-size: 0.72rem;
  font-weight: 950;
  text-transform: uppercase;
  white-space: nowrap;
}

.session-status-badge > span {
  display: inline-grid;
  place-items: center;
  width: 17px;
  height: 17px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: inherit;
  font-size: 0.7rem;
  line-height: 1;
}

.session-status-badge.completed {
  border-color: rgba(34, 197, 94, 0.42);
  background: rgba(34, 197, 94, 0.12);
  color: #86efac;
}

.session-status-badge.cancelled {
  border-color: rgba(239, 68, 68, 0.58);
  background: rgba(239, 68, 68, 0.16);
  color: #fecaca;
}

.session-cancelled-flag,
.session-cancelled-note {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  width: fit-content;
  padding: 7px 9px;
  border: 1px solid rgba(239, 68, 68, 0.42);
  border-radius: 8px;
  background: rgba(239, 68, 68, 0.12);
  color: #fecaca;
  font-size: 0.82rem;
  font-weight: 950;
}

html[data-theme="light"] .upcoming-session-card:hover {
  border-color: rgba(15, 142, 145, 0.26);
  background: rgba(255, 255, 255, 0.82);
}

html[data-theme="light"] .practitioner-session-access {
  border-color: rgba(8, 37, 53, 0.12);
  background: rgba(255, 255, 255, 0.82);
}

html[data-theme="light"] .practitioner-session-access.online {
  border-color: rgba(15, 142, 145, 0.24);
  background: rgba(226, 247, 246, 0.92);
}

html[data-theme="light"] .practitioner-session-access.place {
  border-color: rgba(148, 100, 17, 0.2);
  background: rgba(255, 243, 214, 0.82);
}

html[data-theme="light"] .practitioner-session-access.cancelled {
  border-color: rgba(155, 75, 67, 0.2);
  background: rgba(248, 238, 238, 0.94);
}

html[data-theme="light"] .practitioner-session-cancel-button {
  border-color: rgba(155, 75, 67, 0.24);
  background: rgba(248, 238, 238, 0.9);
  color: #9b4b43;
}

html[data-theme="light"] .session-status-card.cancelled {
  border-color: rgba(185, 28, 28, 0.32);
  border-left-color: #dc2626;
  background: linear-gradient(180deg, rgba(254, 242, 242, 0.98), rgba(255, 255, 255, 0.86));
}

html[data-theme="light"] .session-status-badge {
  border-color: rgba(15, 142, 145, 0.28);
  background: rgba(15, 142, 145, 0.1);
  color: #0b6f73;
}

html[data-theme="light"] .session-status-badge.completed {
  border-color: rgba(22, 163, 74, 0.34);
  background: rgba(22, 163, 74, 0.1);
  color: #15803d;
}

html[data-theme="light"] .session-status-badge.cancelled,
html[data-theme="light"] .session-cancelled-flag,
html[data-theme="light"] .session-cancelled-note {
  border-color: rgba(220, 38, 38, 0.34);
  background: rgba(254, 226, 226, 0.9);
  color: #b91c1c;
}

html[data-theme="light"] .client-session-card-v1.session-status-card.cancelled {
  border-color: rgba(155, 75, 67, 0.24);
  border-left-color: #c66f66;
  background: linear-gradient(180deg, rgba(248, 238, 238, 0.98), rgba(255, 255, 255, 0.9));
}

html[data-theme="light"] .client-session-card-v1 .session-status-badge.cancelled {
  border-color: rgba(155, 75, 67, 0.28);
  background: rgba(248, 238, 238, 0.94);
  color: #9b4b43;
}

html[data-theme="light"] .client-session-access-row {
  border-color: rgba(8, 37, 53, 0.12);
  background: rgba(255, 255, 255, 0.82);
}

html[data-theme="light"] .client-session-access-row.online {
  border-color: rgba(15, 142, 145, 0.24);
  background: rgba(226, 247, 246, 0.92);
}

html[data-theme="light"] .client-session-access-row.pending {
  border-color: rgba(8, 37, 53, 0.12);
  background: rgba(244, 248, 249, 0.9);
}

html[data-theme="light"] .client-session-access-row.cancelled {
  border-color: rgba(155, 75, 67, 0.2);
  background: rgba(248, 238, 238, 0.94);
}

html[data-theme="light"] .client-session-secondary-details {
  border-color: rgba(8, 37, 53, 0.12);
  background: rgba(255, 255, 255, 0.6);
}

html[data-theme="light"] .client-session-tabs button.active {
  border-color: rgba(15, 142, 145, 0.24);
  background: rgba(226, 247, 246, 0.9);
  color: #0b6f73;
}

.client-record-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.impersonation-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid rgba(245, 158, 11, 0.35);
  border-radius: 8px;
  background: rgba(245, 158, 11, 0.12);
  color: #fde68a;
}

.password-field button {
  position: absolute;
  right: 6px;
  top: 50%;
  display: grid;
  place-items: center;
  width: 32px;
  min-width: 32px;
  height: 32px;
  min-height: 32px;
  padding: 0;
  border-color: rgba(148, 163, 184, 0.18);
  border-radius: 8px;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.02);
  color: rgba(226, 232, 240, 0.58);
  font-size: 0;
}

.password-field button:hover,
.password-field button:focus-visible {
  border-color: rgba(94, 234, 212, 0.36);
  background: rgba(94, 234, 212, 0.08);
  color: var(--accent);
}

.password-visibility-icon {
  position: relative;
  width: 18px;
  height: 12px;
  border: 1.6px solid currentColor;
  border-radius: 999px;
  opacity: 0.72;
}

.password-visibility-icon::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 3.5px;
  height: 3.5px;
  border-radius: 50%;
  background: currentColor;
  transform: translate(-50%, -50%);
}

.password-field button.is-visible .password-visibility-icon::before {
  content: "";
  position: absolute;
  left: -2px;
  top: 4px;
  width: 21px;
  height: 1.8px;
  border-radius: 999px;
  background: currentColor;
  transform: rotate(-34deg);
}

html[data-theme="light"] .password-field button {
  border-color: rgba(10, 34, 50, 0.16);
  background: rgba(10, 34, 50, 0.03);
  color: rgba(10, 34, 50, 0.56);
}

.bot-field {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.phone-row {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 8px;
}

.wizard,
.register-gate,
.journey-output,
.recipe-card,
.state-card,
.search-panel,
.library-list,
.admin-board {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.register-gate {
  display: grid;
  gap: 18px;
  padding: 22px;
  margin-bottom: 16px;
  border-color: rgba(255, 255, 255, 0.2);
  background: linear-gradient(135deg, var(--bg-panel), #1a2330);
  color: #f7fbfa;
}

.register-gate .eyebrow,
.register-gate .lead,
.register-gate label {
  color: rgba(247, 251, 250, 0.84);
}

.register-gate h2 {
  color: #fff;
}

.register-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.terms-field {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 10px;
  align-items: start;
  padding: 12px;
  border: 1px solid rgba(94, 234, 212, 0.22);
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.08);
}

.terms-field input {
  width: auto;
  min-height: 0;
  margin-top: 4px;
}

.admin-tab[hidden] {
  display: none;
}

.register-gate,
.creatorMode-placeholder {
  display: none;
}

#creatorMode.needs-register .register-gate {
  display: grid;
}

#creatorMode.needs-register .wizard,
#creatorMode.needs-register .creator-playlist-tabs,
#creatorMode.needs-register .journey-output,
#creatorMode.brief-only .journey-output,
#creatorMode.journey-created .wizard,
#creatorMode.journey-created .register-gate {
  display: none;
}

#creatorMode.brief-only .wizard,
#creatorMode.journey-created .journey-output {
  display: grid;
}

.wizard {
  display: grid;
  gap: 18px;
  padding: 20px;
  margin-bottom: 16px;
  border-color: rgba(255, 255, 255, 0.18);
  background: linear-gradient(135deg, rgba(18, 24, 33, 0.98), rgba(26, 35, 48, 0.98));
  color: #f7fbfa;
}

.wizard .eyebrow,
.wizard label,
.wizard .source-policy {
  color: rgba(247, 251, 250, 0.84);
}

.wizard h2 {
  color: #fff;
}

.wizard .source-policy {
  border-color: rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.08);
}

html[data-theme="light"] .wizard {
  border-color: rgba(15, 142, 145, 0.18);
  background: linear-gradient(180deg, rgba(248, 252, 253, 0.96), rgba(232, 245, 248, 0.94));
  color: #0d2536;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.74), 0 14px 32px rgba(31, 74, 92, 0.11);
}

html[data-theme="light"] .wizard .eyebrow,
html[data-theme="light"] .wizard label,
html[data-theme="light"] .wizard .source-policy {
  color: #365c70;
}

html[data-theme="light"] .wizard h2 {
  color: #082535;
}

.creator-playlist-tabs {
  margin: 0 0 14px;
}

html[data-theme="light"] .wizard .source-policy {
  border-color: rgba(15, 142, 145, 0.18);
  background: rgba(15, 142, 145, 0.07);
}

.wizard-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  align-items: end;
}

.wizard-grid label {
  display: grid;
  gap: 6px;
  padding: 10px;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(3, 10, 16, 0.28);
}

.wizard-grid label select,
.wizard-grid label input {
  border-color: rgba(94, 234, 212, 0.34);
  background: rgba(3, 10, 16, 0.82);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.025);
}

.wizard-grid label:focus-within {
  border-color: rgba(79, 209, 197, 0.62);
  background: rgba(79, 209, 197, 0.08);
}

html[data-theme="light"] .wizard-grid label {
  border-color: rgba(15, 142, 145, 0.16);
  background: rgba(255, 255, 255, 0.64);
}

html[data-theme="light"] .wizard-grid label select,
html[data-theme="light"] .wizard-grid label input {
  border-color: rgba(15, 142, 145, 0.24);
  background: rgba(255, 255, 255, 0.96);
  color: #0d2536;
  box-shadow: inset 0 0 0 1px rgba(31, 74, 92, 0.03);
}

html[data-theme="light"] .wizard-grid label:focus-within {
  border-color: rgba(15, 142, 145, 0.52);
  background: rgba(15, 142, 145, 0.08);
}

.wizard-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.wizard-text-links {
  align-items: center;
  gap: 14px;
  margin-top: 8px;
}

.wizard-text-links .link-button {
  background: transparent;
  border: 0;
  color: var(--accent);
  min-height: auto;
  padding: 0;
  text-decoration: underline;
}

.wide-field {
  grid-column: 1 / -1;
}

.profile-guidance {
  display: grid;
  gap: 6px;
  padding: 13px 14px;
  border: 1px solid rgba(94, 234, 212, 0.28);
  border-radius: 8px;
  background: var(--navy-soft);
  color: var(--action);
  line-height: 1.4;
}

.profile-guidance strong {
  color: var(--ink);
}

.profile-label {
  display: inline-flex;
  margin-right: 8px;
  padding: 4px 8px;
  border-radius: 8px;
  background: var(--action);
  color: var(--bg-page);
  font-size: 0.78rem;
  font-weight: 950;
  text-transform: uppercase;
}

.source-policy {
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
  color: var(--muted);
  line-height: 1.45;
}

.guide-steps {
  display: grid;
  gap: 10px;
  margin: 0;
  padding-left: 20px;
  color: var(--ink);
  line-height: 1.5;
}

.guide-steps strong {
  color: var(--action);
}

label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 850;
}

.field-hint {
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 700;
  line-height: 1.35;
}

.compatibility-hidden {
  display: none !important;
}

.compatibility-hidden * {
  display: none !important;
}

.primary-button,
.secondary-button,
.ghost-button,
.danger-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  width: fit-content;
  max-width: 100%;
  min-width: 0;
  min-height: var(--control-height);
  padding: 9px var(--control-padding-x);
  border-radius: var(--control-radius);
  box-sizing: border-box;
  font-size: 0.9rem;
  font-weight: 900;
  line-height: 1.12;
  letter-spacing: 0;
  text-align: center;
  text-decoration: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  vertical-align: middle;
}

.primary-button {
  border-color: var(--navy);
  background: var(--navy);
  color: var(--bg-page);
}

.primary-button:hover {
  border-color: rgba(167, 255, 243, 0.72);
  background: var(--action-dark);
  box-shadow: 0 0 0 2px rgba(94, 234, 212, 0.2);
}

.secondary-button {
  border-color: rgba(94, 234, 212, 0.18);
  background: rgba(255, 255, 255, 0.055);
  color: var(--ink);
  box-shadow: none;
}

.secondary-button:hover {
  border-color: rgba(94, 234, 212, 0.44);
  background: rgba(94, 234, 212, 0.1);
  box-shadow: 0 0 0 2px rgba(94, 234, 212, 0.16);
}

.ghost-button {
  border: 1px solid rgba(148, 163, 184, 0.2);
  background: rgba(255, 255, 255, 0.025);
  color: var(--muted);
  cursor: pointer;
}

.ghost-button:hover {
  border-color: rgba(94, 234, 212, 0.42);
  color: var(--text);
  background: rgba(94, 234, 212, 0.07);
}

html[data-theme="light"] .secondary-button {
  background: #f8fcfd;
  color: var(--ink);
  border-color: rgba(8, 37, 53, 0.18);
}

html[data-theme="light"] .primary-button:hover {
  border-color: #0b777a;
  background: #0b777a;
  box-shadow: 0 0 0 3px rgba(15, 142, 145, 0.16);
}

html[data-theme="light"] .secondary-button:hover {
  border-color: rgba(15, 142, 145, 0.42);
  background: rgba(15, 142, 145, 0.1);
  box-shadow: 0 0 0 3px rgba(15, 142, 145, 0.12);
}

html[data-theme="light"] .ghost-button {
  background: rgba(255, 255, 255, 0.78);
  color: #315064;
  border-color: rgba(9, 78, 99, 0.15);
}

html[data-theme="light"] .ghost-button:hover {
  color: var(--text);
  border-color: rgba(15, 142, 145, 0.34);
  background: #ffffff;
}

.journey-output {
  padding: 18px;
  border-color: var(--line);
  background: rgba(18, 24, 33, 0.96);
}

html[data-theme="light"] .journey-output {
  background: rgba(248, 252, 253, 0.88);
}

.section-heading,
.state-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
}

.section-heading > div,
.state-header > div {
  min-width: 0;
}

.button-row,
.quick-actions,
.tags,
.phrase-grid,
.source-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.button-row > button,
.button-row > a,
.quick-actions > button,
.quick-actions > a {
  flex: 0 1 auto;
  min-width: 0;
}

.timeline-summary {
  margin-bottom: 14px;
  padding: 13px 14px;
  border: 1px solid rgba(94, 234, 212, 0.28);
  border-radius: 8px;
  background: var(--navy-soft);
  color: var(--navy);
  font-weight: 850;
  line-height: 1.45;
}

.journey-progress {
  display: grid;
  gap: 7px;
  max-width: 560px;
  margin-top: 10px;
  padding: 10px;
  border: 1px solid rgba(94, 234, 212, 0.24);
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.08);
}

.workspace-guide {
  display: grid;
  gap: 14px;
  margin-bottom: 16px;
}

.workspace-guide-panel {
  border: 1px solid rgba(94, 234, 212, 0.24);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(23, 62, 85, 0.96), rgba(27, 77, 107, 0.92));
  box-shadow: 0 10px 24px rgba(2, 12, 19, 0.16);
  overflow: hidden;
}

.workspace-guide-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px;
  cursor: pointer;
  list-style: none;
}

.workspace-guide-summary::-webkit-details-marker {
  display: none;
}

.workspace-guide-summary strong {
  color: #f3fbfd;
  font-size: 0.96rem;
}

.workspace-guide-summary span {
  color: #d6eaf0;
  font-size: 0.82rem;
  line-height: 1.4;
  text-align: right;
}

html[data-theme="light"] .workspace-guide-panel {
  border-color: rgba(15, 142, 145, 0.22);
  background: linear-gradient(180deg, #eef8f9 0%, #dceff3 100%);
  box-shadow: 0 10px 22px rgba(31, 74, 92, 0.1);
}

html[data-theme="light"] .workspace-guide-summary strong {
  color: #082535;
}

html[data-theme="light"] .workspace-guide-summary span {
  color: #31586b;
}

.workspace-guide-inner {
  display: grid;
  gap: 14px;
  padding: 0 14px 14px;
}

.workspace-guide-top {
  display: grid;
  gap: 4px;
}

.workspace-guide-top strong {
  color: var(--ink);
  font-size: 1rem;
}

.workspace-guide-top span {
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.45;
}

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

.workspace-guide-card {
  display: grid;
  gap: 6px;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.03);
}

.workspace-guide-card strong {
  color: var(--ink);
  font-size: 0.88rem;
}

.workspace-guide-card span,
.workspace-guide-card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.4;
}

.journey-progress-top {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  color: var(--ink);
  font-weight: 950;
}

.journey-progress-track {
  height: 9px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
}

.journey-progress-track span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--action), var(--success));
}

.journey-progress-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.progress-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 900;
}

.progress-pill.completed {
  border-color: rgba(34, 197, 94, 0.4);
  background: rgba(34, 197, 94, 0.12);
  color: #86efac;
}

.progress-pill.progress {
  border-color: rgba(245, 158, 11, 0.42);
  background: rgba(245, 158, 11, 0.11);
  color: #fbbf24;
}

.progress-pill.pending {
  border-color: rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.035);
  color: var(--muted);
}

#timelineTitle {
  width: fit-content;
  cursor: pointer;
}

.editable-journey-title:hover {
  color: var(--action);
}

.journey-meta {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 800;
}

.journey-status-row {
  margin-top: 10px;
}

.journey-status-label {
  width: fit-content;
  display: grid;
  gap: 6px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.journey-status-label select {
  min-width: 190px;
}

.journey-status-label.building {
  border-color: rgba(94, 234, 212, 0.28);
  background: rgba(94, 234, 212, 0.08);
}

.journey-status-label.review {
  border-color: rgba(245, 158, 11, 0.34);
  background: rgba(245, 158, 11, 0.09);
}

.journey-status-label.done {
  border-color: rgba(139, 148, 158, 0.28);
  background: rgba(139, 148, 158, 0.08);
}

.playlist-status-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  width: fit-content;
  padding: 5px 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 950;
  text-transform: uppercase;
}

.playlist-status-pill.building {
  border-color: rgba(94, 234, 212, 0.34);
  background: rgba(94, 234, 212, 0.12);
  color: #99f6e4;
}

.playlist-status-pill.review {
  border-color: rgba(245, 158, 11, 0.42);
  background: rgba(245, 158, 11, 0.14);
  color: #fbbf24;
}

.playlist-status-pill.done {
  border-color: rgba(139, 148, 158, 0.34);
  background: rgba(139, 148, 158, 0.12);
  color: #d1d5db;
}

.timeline {
  display: grid;
  gap: 12px;
}

.timeline-item {
  display: block;
  padding: 0;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-left-width: 8px;
  border-left-color: rgba(94, 234, 212, 0.78);
  border-radius: 8px;
  background: linear-gradient(180deg, #102432 0%, #0f1f2b 100%);
  overflow: hidden;
  content-visibility: auto;
  contain-intrinsic-size: 320px;
}

.timeline-item[open] {
  border-color: rgba(94, 234, 212, 0.58);
  border-left-color: rgba(94, 234, 212, 1);
  background: linear-gradient(180deg, var(--bg-card) 0%, #112d3e 100%);
  box-shadow: 0 0 0 1px rgba(94, 234, 212, 0.14), 0 18px 38px rgba(0, 0, 0, 0.22);
}

.timeline-item.return-highlight {
  outline: 3px solid rgba(94, 234, 212, 0.6);
  box-shadow: 0 0 0 8px rgba(94, 234, 212, 0.15), var(--shadow);
}

.timeline-item.energy-low,
.timeline-item.energy-mid,
.timeline-item.energy-high {
  border-left-color: rgba(94, 234, 212, 0.78);
}

.timeline-item.workflow-pending {
  border-left-color: rgba(94, 234, 212, 0.66);
}

.timeline-item.workflow-in-progress {
  border-left-color: rgba(94, 234, 212, 0.9);
}

.timeline-item.workflow-completed {
  border-left-color: rgba(94, 234, 212, 1);
}

.timeline-item-summary {
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
  padding: 12px;
  cursor: pointer;
  list-style: none;
}

.timeline-item-summary::-webkit-details-marker {
  display: none;
}

.timeline-heading-block {
  min-width: 0;
}

.timeline-summary-actions {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.timeline-content {
  display: grid;
  gap: 10px;
  padding: 0 14px 14px 14px;
}

.time-block {
  display: grid;
  gap: 3px;
  align-content: center;
  min-height: 48px;
  padding: 7px 8px;
  border-radius: 8px;
  border: 1px solid rgba(94, 234, 212, 0.28);
  background: rgba(94, 234, 212, 0.15);
  color: #a7fff3;
  font-size: 0.78rem;
  font-weight: 950;
  text-align: center;
}

.timeline-kicker {
  margin-bottom: 0;
  color: #8bd9ff;
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.timeline-purpose {
  margin: 6px 0 0;
  color: var(--ink);
  font-size: 0.92rem;
  line-height: 1.45;
}

.timeline-next-step {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 10px;
  align-items: center;
  margin: 7px 0 0;
  padding: 7px 10px;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.07);
}

.timeline-next-step strong {
  color: #a7fff3;
  font-size: 0.76rem;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.timeline-next-step span {
  color: var(--ink);
  font-weight: 850;
}

.timeline-next-step small {
  flex-basis: 100%;
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.4;
}

.timeline-title {
  margin-bottom: 0;
  font-size: 1.04rem;
  font-weight: 950;
}

.state-title-chip {
  display: inline-flex;
  width: fit-content;
  min-height: auto;
  margin-top: 0;
  margin-bottom: 4px;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.12);
  color: var(--ink);
  font-size: 1rem;
  line-height: 1.2;
  text-align: left;
}

.state-title-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 8px;
}

.diary-shortcut-button {
  min-width: auto;
  padding: 7px 10px;
  border-color: rgba(94, 234, 212, 0.26);
  background: rgba(94, 234, 212, 0.08);
  color: var(--ink);
  font-size: 0.82rem;
  font-weight: 900;
}

.diary-shortcut-button:hover {
  border-color: rgba(94, 234, 212, 0.45);
  background: rgba(94, 234, 212, 0.16);
}

.timeline-status-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 32px;
  padding: 6px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 950;
  text-transform: uppercase;
}

.timeline-status-badge.pending {
  border-color: rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
}

.timeline-status-badge.progress {
  border-color: rgba(245, 158, 11, 0.45);
  background: rgba(245, 158, 11, 0.12);
  color: #fbbf24;
}

.timeline-status-badge.completed {
  border-color: rgba(34, 197, 94, 0.42);
  background: rgba(34, 197, 94, 0.12);
  color: #86efac;
}

.timeline-action-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.timeline-action-copy {
  display: grid;
  gap: 4px;
}

.timeline-action-copy strong {
  color: #a7fff3;
  font-size: 0.76rem;
  font-weight: 950;
  text-transform: uppercase;
}

.timeline-action-copy span {
  color: var(--ink);
  font-weight: 900;
}

.timeline-action-copy small {
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.4;
}

.timeline-action-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.player-strip {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  margin-bottom: 10px;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: transparent;
}

.player-strip .preview-trigger {
  min-height: 46px;
  border-color: transparent;
  color: var(--bg-page);
}

.player-panel {
  display: grid;
  gap: 8px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.player-panel.music-panel {
  border-color: rgba(94, 234, 212, 0.28);
  background: rgba(94, 234, 212, 0.08);
}

.player-panel.sound-panel {
  border-color: rgba(124, 58, 237, 0.34);
  background: rgba(124, 58, 237, 0.12);
}

.player-panel.manual-panel {
  border-color: rgba(245, 158, 11, 0.34);
  background: rgba(245, 158, 11, 0.09);
}

.player-panel-label {
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 950;
  text-transform: uppercase;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.goal-marker {
  display: inline-grid;
  place-items: center;
  width: 18px;
  height: 18px;
  border: 1px solid rgba(148, 163, 184, 0.32);
  border-radius: 50%;
  font-size: 0.68rem;
  font-weight: 950;
  line-height: 1;
}

.goal-marker.ok {
  border-color: rgba(34, 197, 94, 0.62);
  background: rgba(34, 197, 94, 0.14);
  color: #bbf7d0;
}

.goal-marker.warning {
  border-color: rgba(250, 204, 21, 0.62);
  background: rgba(250, 204, 21, 0.14);
  color: #fef08a;
}

.goal-marker.pending {
  color: var(--muted);
}

.player-panel.music-panel .preview-trigger {
  background: var(--action);
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.player-panel.sound-panel .preview-trigger {
  background: #a78bfa;
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.player-panel.music-panel .preview-trigger:hover {
  background: #99f6e4;
  box-shadow: 0 10px 24px rgba(94, 234, 212, 0.22);
  transform: translateY(-1px);
}

.player-panel.sound-panel .preview-trigger:hover {
  background: #c4b5fd;
  box-shadow: 0 10px 24px rgba(124, 58, 237, 0.24);
  transform: translateY(-1px);
}

.manual-panel small {
  color: var(--muted);
  font-size: 0.82rem;
}

.sound-select {
  display: grid;
  gap: 4px;
  margin: 0;
  color: rgba(247, 251, 250, 0.82);
  font-size: 0.76rem;
  font-weight: 900;
  text-transform: uppercase;
}

.sound-select select {
  min-height: 40px;
  border-color: rgba(255, 255, 255, 0.28);
  background: #0f151d;
  color: var(--ink);
}

.state-sequence {
  margin: 10px 0 0;
  padding: 9px 10px;
  border: 1px solid #b7c9d2;
  border-radius: 8px;
  background: var(--navy-soft);
  color: var(--navy);
  font-size: 0.86rem;
  font-weight: 850;
  line-height: 1.35;
}

.timeline-summary-actions .state-sequence {
  width: auto;
  margin: 0;
  padding: 7px 9px;
  font-size: 0.76rem;
  white-space: nowrap;
}

.timeline-summary-actions .state-sequence:not(.empty) {
  max-width: 320px;
  overflow: hidden;
  text-overflow: ellipsis;
}

.state-sequence.empty {
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
}

.state-sequence.ok {
  border-color: rgba(34, 197, 94, 0.45);
  background: var(--success-soft);
  color: #86efac;
}

.state-sequence.warning {
  border-color: rgba(245, 158, 11, 0.45);
  background: var(--gold-soft);
  color: #fbbf24;
}

.state-sequence.error {
  border-color: rgba(239, 68, 68, 0.5);
  background: var(--danger-soft);
  color: var(--danger);
}

.timeline-notes {
  margin-bottom: 12px;
  color: var(--muted);
  line-height: 1.5;
}

.state-brief-list {
  display: grid;
  gap: 7px;
  margin-bottom: 12px;
}

.state-brief-row {
  display: grid;
  grid-template-columns: 28px minmax(82px, 116px) minmax(0, 1fr);
  gap: 8px;
  align-items: start;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
}

.history-link-box {
  display: grid;
  gap: 10px;
  margin-bottom: 14px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.history-link-box audio {
  width: 100%;
}

.library-state-modal-card {
  max-width: 880px;
}

.state-brief-row strong {
  color: var(--navy);
}

.state-brief-row em {
  color: var(--muted);
  font-style: normal;
  line-height: 1.35;
}

.timeline-item .rule-grid {
  max-height: 70px;
  overflow: hidden;
}

.rule-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-bottom: 12px;
}

.rule-chip {
  display: inline-flex;
  gap: 4px;
  max-width: 100%;
  padding: 6px 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1.35;
}

.daw-guide {
  display: grid;
  gap: 7px;
  margin-top: 10px;
}

.daw-step {
  display: grid;
  gap: 3px;
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-left-width: 5px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
}

.daw-step.main {
  border-left-color: var(--navy);
}

.daw-step.ambient {
  border-left-color: var(--success);
}

.daw-step.bridge {
  border-left-color: var(--coral);
}

.daw-step strong {
  color: var(--ink);
}

.daw-step span {
  color: var(--navy);
  font-size: 0.82rem;
  font-weight: 850;
}

.daw-step em {
  color: var(--muted);
  font-size: 0.82rem;
  font-style: normal;
}

.quick-actions a,
.quick-actions button,
.tag,
.phrase,
.source-link {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
  color: var(--ink);
  font-size: 0.88rem;
  font-weight: 850;
  text-decoration: none;
}

.quick-actions a,
.quick-actions button {
  background: var(--navy-soft);
  color: var(--navy);
}

.quick-actions a.free,
.quick-actions button.free,
.source-link.free,
.free-source {
  border-color: rgba(34, 197, 94, 0.45);
  background: var(--success-soft);
  color: #86efac;
}

.quick-actions a.commercial-source,
.quick-actions button.commercial-source,
.source-link.commercial-source {
  border-color: rgba(94, 234, 212, 0.28);
  background: var(--navy-soft);
  color: var(--navy);
}

.quick-actions a.mixed-source,
.quick-actions button.mixed-source,
.source-link.mixed-source {
  border-color: rgba(124, 58, 237, 0.42);
  background: var(--secondary-soft);
  color: #c4b5fd;
}

.preview-trigger {
  min-height: 34px;
  padding: 7px 10px;
  font-size: 0.88rem;
}

.mini-details,
.source-dock {
  margin-bottom: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.mini-details summary,
.source-dock summary {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
  min-height: 42px;
  padding: 10px 12px;
  color: var(--navy);
  cursor: pointer;
  font-weight: 950;
  list-style: none;
}

.mini-details summary::-webkit-details-marker,
.source-dock summary::-webkit-details-marker {
  display: none;
}

.mini-details summary::after,
.source-dock summary::after {
  content: "+";
  color: var(--coral);
  font-weight: 950;
}

.mini-details[open] summary::after,
.source-dock[open] summary::after {
  content: "-";
}

.source-dock summary span {
  margin-left: auto;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 850;
}

.mini-details .daw-guide {
  padding: 0 10px 10px;
}

.basic-advice .state-brief-list {
  padding: 0 10px 10px;
}

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

.inline-source-dock {
  margin: 0;
}

.source-groups.compact {
  grid-template-columns: 1fr;
  padding: 0 8px 8px;
}

.source-groups.compact .source-group {
  padding: 8px;
}

.source-group {
  min-width: 0;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
}

.source-group.priority {
  border-color: rgba(124, 58, 237, 0.42);
  background: var(--secondary-soft);
}

.source-group.listen-source {
  border-color: rgba(124, 58, 237, 0.42);
  background: var(--violet-soft);
}

.source-group.download-source {
  border-color: rgba(34, 197, 94, 0.45);
  background: var(--success-soft);
}

.source-group.license-source {
  border-color: #91a9b7;
  background: #e9f1f5;
}

.source-group.ambient-source {
  border-color: #8cc8b1;
  background: #f2fbf5;
}

.source-group-title {
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 900;
  text-transform: uppercase;
}

.source-hint {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 0.84rem;
  line-height: 1.4;
}

.audition-panel {
  display: none;
  position: fixed;
  right: 18px;
  top: max(18px, env(safe-area-inset-top));
  bottom: max(18px, env(safe-area-inset-bottom));
  left: 18px;
  z-index: 55;
  max-width: 1180px;
  margin: 0 auto;
  padding: 14px;
  border: 1px solid rgba(94, 234, 212, 0.65);
  border-left: 8px solid rgba(94, 234, 212, 1);
  border-radius: 8px;
  background: var(--bg-workspace);
  box-shadow: 0 0 0 1px rgba(94, 234, 212, 0.15), 0 18px 44px rgba(21, 23, 24, 0.28);
  overflow: auto;
  overscroll-behavior: contain;
}

.audition-sticky {
  position: sticky;
  top: -14px;
  z-index: 4;
  margin: -14px -14px 10px;
  padding: 8px 14px 7px;
  border-bottom: 1px solid rgba(94, 234, 212, 0.18);
  background: color-mix(in srgb, var(--bg-workspace) 94%, #000 6%);
  backdrop-filter: blur(12px);
}

.audition-panel.active {
  display: block;
}

.audition-panel.panel-front {
  z-index: 72;
}

.satellite-audition-panel {
  border-color: rgba(34, 197, 94, 0.68);
  border-left-color: rgba(34, 197, 94, 0.96);
  box-shadow: 0 0 0 1px rgba(34, 197, 94, 0.18), 0 18px 48px rgba(0, 0, 0, 0.38);
}

.audition-panel.split-left {
  left: 18px;
  right: auto;
  width: calc(64vw - 26px);
  max-width: none;
}

.satellite-audition-panel.split-right {
  left: auto;
  right: 18px;
  top: max(18px, env(safe-area-inset-top));
  bottom: max(18px, env(safe-area-inset-bottom));
  width: calc(36vw - 26px);
  max-width: none;
  margin: 0;
  z-index: 68;
}

.audition-panel.split-left.panel-front,
.satellite-audition-panel.split-right.panel-front {
  z-index: 72;
}

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

.sound-layer-toggle {
  border-color: rgba(34, 197, 94, 0.45) !important;
  background: rgba(34, 197, 94, 0.14) !important;
  color: #bbf7d0 !important;
}

.audition-header {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
  padding-right: 50px;
}

.audition-header h3 {
  margin-bottom: 0;
  font-size: 1rem;
  line-height: 1.18;
}

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

.audition-header a,
.preview-actions a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 0.86rem;
  font-weight: 850;
  text-decoration: none;
}

.audition-header a,
.preview-actions a {
  border-color: rgba(94, 234, 212, 0.35);
  background: var(--navy-soft);
  color: #a7fff3;
}

.audition-actions button {
  min-height: 34px;
  padding: 7px 10px;
  font-size: 0.86rem;
}

.audition-close {
  position: absolute;
  top: 10px;
  right: 10px;
  display: grid;
  place-items: center;
  width: 38px;
  min-width: 38px;
  height: 38px;
  padding: 0;
  border-color: #ef9a90;
  background: var(--danger-soft);
  color: var(--danger);
  font-weight: 950;
  line-height: 1;
}

.audition-header a.commercial-source {
  border-color: #91a9b7;
  background: var(--navy-soft);
  color: var(--navy);
}

.audition-header a.mixed-source {
  border-color: rgba(124, 58, 237, 0.42);
  background: var(--secondary-soft);
  color: #c4b5fd;
}

.external-search-picker {
  display: flex;
  align-items: end;
  gap: 8px;
  max-width: 100%;
  min-width: min(360px, 100%);
}

.external-search-picker label {
  display: grid;
  gap: 4px;
  flex: 1 1 190px;
  min-width: 0;
}

.external-search-picker label span {
  color: var(--text-secondary);
  font-size: 0.68rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.external-search-picker select {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  min-height: 38px;
  border-radius: 8px;
}

.external-search-picker a {
  flex: 0 0 auto;
  min-height: 38px;
  white-space: nowrap;
}

.audition-actions .external-search-picker {
  max-width: 430px;
}

.audition-help,
.preview-empty {
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 0.84rem;
  line-height: 1.45;
}

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

.preview-card {
  display: grid;
  grid-template-columns: 58px 1fr;
  gap: 10px;
  min-width: 0;
  padding: 9px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
  content-visibility: auto;
  contain-intrinsic-size: 180px;
}

.preview-card.is-playing {
  border-color: rgba(250, 204, 21, 0.92) !important;
  box-shadow: inset 6px 0 0 rgba(250, 204, 21, 0.96) !important;
}

.preview-card.fresh-option,
.preview-card.usage-fresh {
  border-color: rgba(34, 197, 94, 0.42);
  box-shadow: inset 4px 0 0 rgba(34, 197, 94, 0.55);
}

.preview-card.used-before,
.preview-card.usage-other {
  border-color: rgba(245, 158, 11, 0.62);
  box-shadow: inset 4px 0 0 rgba(245, 158, 11, 0.72);
}

.preview-card.usage-same {
  border-color: rgba(239, 68, 68, 0.68);
  box-shadow: inset 4px 0 0 rgba(239, 68, 68, 0.8);
}

.preview-fit-rating {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 5px;
  margin-top: 7px;
  padding-top: 7px;
  border-top: 1px solid rgba(148, 163, 184, 0.18);
}

.preview-fit-rating span {
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.preview-fit-rating button {
  min-height: 28px;
  padding: 4px 8px;
  border: 1px solid rgba(94, 234, 212, 0.35);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
  color: var(--text-soft);
  font-size: 0.74rem;
  font-weight: 900;
}

.preview-fit-rating button:hover,
.preview-fit-rating button.active {
  border-color: var(--accent);
  background: var(--accent);
  color: #061826;
}

.used-before-note {
  width: fit-content;
  padding: 3px 7px;
  border-radius: 8px;
  background: var(--gold-soft);
  color: #fbbf24 !important;
  font-weight: 950;
}

.used-before-note.same {
  background: var(--danger-soft);
  color: #fca5a5 !important;
}

.used-before-note.other {
  background: var(--gold-soft);
  color: #fbbf24 !important;
}

.preview-cover {
  width: 58px;
  height: 58px;
  border-radius: 8px;
  object-fit: cover;
  background: var(--navy-soft);
}

.preview-cover.placeholder {
  border: 1px solid var(--line);
}

.preview-body {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.preview-topline {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: start;
}

.preview-body strong,
.preview-body span,
.preview-body em,
.preview-body small {
  overflow-wrap: anywhere;
}

.preview-title {
  min-width: 0;
  max-width: 100%;
  display: block;
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  word-break: break-word;
  line-height: 1.3;
}

.preview-artist,
.preview-album,
.preview-meta {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.preview-filetype,
.preview-duration {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 850;
  text-transform: lowercase;
}

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

.access-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  width: fit-content;
  min-height: 24px;
  padding: 2px 6px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 0.58rem;
  font-weight: 950;
  letter-spacing: 0;
  text-transform: uppercase;
  pointer-events: none;
}

.access-badge.download {
  border-color: rgba(34, 197, 94, 0.48);
  background: rgba(34, 197, 94, 0.14);
  color: #86efac;
}

.access-badge.purchase {
  border-color: rgba(94, 234, 212, 0.42);
  background: rgba(94, 234, 212, 0.12);
  color: var(--action);
}

.access-badge.subscription {
  border-color: rgba(245, 158, 11, 0.42);
  background: rgba(245, 158, 11, 0.14);
  color: #fbbf24;
}

.access-badge.license,
.access-badge.reference {
  border-color: rgba(124, 58, 237, 0.42);
  background: rgba(124, 58, 237, 0.14);
  color: #c4b5fd;
}

.access-badge.listen-only {
  border-color: rgba(148, 163, 184, 0.42);
  background: rgba(148, 163, 184, 0.14);
  color: #d9e7ef;
}

.preview-body span,
.preview-body em,
.preview-body small {
  color: var(--muted);
  font-size: 0.82rem;
  font-style: normal;
}

.preview-audio-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 34px;
  gap: 8px;
  align-items: stretch;
}

.preview-audio-shell audio {
  display: none;
}

.preview-transport {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  min-width: 0;
}

.preview-play-toggle {
  min-width: 58px;
  min-height: 34px;
  padding: 6px 8px;
  border: 1px solid rgba(94, 234, 212, 0.36);
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.1);
  color: #a7fff3;
  font-size: 0.74rem;
  font-weight: 950;
}

.preview-seek-control {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 6px;
  align-items: center;
  min-width: 0;
}

.preview-time {
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 850;
  text-align: center;
}

.preview-time-row {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  width: 100%;
}

.preview-seek-control input[type="range"] {
  width: 100%;
  min-width: 0;
  padding: 0;
  margin: 0;
  -webkit-appearance: none;
  appearance: none;
  background: transparent;
}

.preview-seek-control input[type="range"]::-webkit-slider-runnable-track {
  height: 4px;
  border-radius: 999px;
  background: rgba(94, 234, 212, 0.22);
}

.preview-seek-control input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 12px;
  height: 12px;
  margin-top: -4px;
  border: 0;
  border-radius: 50%;
  background: var(--action);
}

.preview-seek-control input[type="range"]::-moz-range-track {
  height: 4px;
  border: 0;
  border-radius: 999px;
  background: rgba(94, 234, 212, 0.22);
}

.preview-seek-control input[type="range"]::-moz-range-thumb {
  width: 12px;
  height: 12px;
  border: 0;
  border-radius: 50%;
  background: var(--action);
}

.preview-volume-control {
  display: grid;
  justify-items: center;
  gap: 4px;
  min-width: 34px;
  padding: 6px 5px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
}

.preview-volume-control span {
  color: var(--muted);
  font-size: 0.56rem;
  font-weight: 900;
  text-transform: uppercase;
  line-height: 1;
  white-space: nowrap;
}

.preview-volume-slider {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  min-height: 88px;
  overflow: hidden;
}

.preview-volume-fader {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  min-width: 18px;
  height: 88px;
  min-height: 88px;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  cursor: ns-resize;
  overflow: hidden;
}

.preview-volume-fader:hover,
.preview-volume-fader:focus-visible {
  border: 0;
  background: transparent;
  box-shadow: none;
  outline: none;
}

.preview-volume-track {
  position: relative;
  display: block;
  width: 4px;
  height: 100%;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  overflow: visible;
}

.preview-volume-fill {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 85%;
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(45, 212, 191, 0.92), rgba(94, 234, 212, 0.68));
  box-shadow: 0 0 0 1px rgba(94, 234, 212, 0.14);
}

.preview-volume-thumb {
  position: absolute;
  left: 50%;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--action);
  box-shadow: 0 0 0 3px rgba(94, 234, 212, 0.18);
  transform: translateX(-50%);
  pointer-events: none;
}

.preview-actions {
  display: grid;
  gap: 7px;
}

.preview-mixer-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.track-toggle {
  min-height: 28px;
  padding: 4px 8px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 900;
}

.track-toggle.active {
  border-color: rgba(94, 234, 212, 0.42);
  background: rgba(94, 234, 212, 0.14);
  color: #c6fff7;
}

.track-toggle.active.danger {
  border-color: rgba(239, 68, 68, 0.55);
  background: rgba(239, 68, 68, 0.16);
  color: #fecaca;
}

.track-toggle.active.action {
  border-color: rgba(34, 197, 94, 0.55);
  background: rgba(34, 197, 94, 0.16);
  color: #bbf7d0;
}

.preview-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  min-width: 0;
}

.preview-tags span {
  width: fit-content;
  max-width: 100%;
  padding: 2px 6px;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.07);
  color: #c6fff7;
  font-size: 0.66rem;
  font-weight: 850;
  line-height: 1.25;
}

.preview-card-sound .preview-cover {
  background: rgba(34, 197, 94, 0.08);
}

.preview-card-sound .preview-tags span {
  border-color: rgba(34, 197, 94, 0.22);
  background: rgba(34, 197, 94, 0.08);
  color: #bbf7d0;
}

.satellite-filter-row {
  margin: 0;
}

.satellite-filter-row,
.preview-access-filter,
.preview-format-filter,
.preview-duration-filter,
.preview-filter-strip label {
  display: grid;
  gap: 6px;
  min-width: 0;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 850;
}

.satellite-filter-row span,
.preview-access-filter span,
.preview-format-filter span,
.preview-duration-filter span,
.preview-filter-strip label span {
  font-size: 0.76rem;
  font-weight: 900;
  text-transform: uppercase;
}

.satellite-filter-row select,
.preview-access-filter select,
.preview-format-filter select,
.preview-duration-filter input,
.preview-filter-strip input,
.preview-filter-strip select {
  min-height: 38px;
  border: 1px solid rgba(94, 234, 212, 0.28);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  color: #d8fff2;
  padding: 0 10px;
}

.preview-filter-strip {
  display: grid;
  gap: 10px;
  margin-top: 8px;
  padding: 10px;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(18, 24, 33, 0.72);
  align-items: end;
  min-width: 0;
  width: 100%;
  overflow: hidden;
}

.preview-filter-strip.track-search {
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
}

.preview-filter-strip.has-satellite {
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
}

.preview-filter-strip .preview-query-filter {
  grid-column: auto;
}

.preview-filter-strip .preview-search-submit {
  min-height: 38px;
  align-self: end;
  justify-self: stretch;
  white-space: nowrap;
  order: 20;
}

.preview-clear-button {
  min-height: 38px;
  align-self: end;
  justify-self: stretch;
  white-space: nowrap;
  order: 19;
}

.preview-duration-filter {
  width: auto;
}

.preview-format-filter,
.preview-access-filter,
.satellite-filter-row {
  width: 100%;
}

.preview-panel-toolbar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(210px, 280px);
  gap: 24px;
  align-items: start;
  margin: 0 0 8px;
}

.preview-mobile-tools {
  min-width: 0;
  width: 100%;
}

.preview-mobile-tools summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 34px;
  padding: 7px 10px;
  border: 1px solid rgba(94, 234, 212, 0.26);
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.1);
  color: var(--action);
  font-size: 0.82rem;
  font-weight: 950;
  text-transform: uppercase;
  cursor: pointer;
  list-style: none;
}

.preview-mobile-tools summary::-webkit-details-marker {
  display: none;
}

.preview-mobile-tools summary::after {
  content: "+";
  font-weight: 950;
}

.preview-mobile-tools[open] summary::after {
  content: "-";
}

.preview-filter-strip > * {
  min-width: 0;
}

.preview-mixer-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin: 0 0 12px;
  padding: 10px 12px;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.preview-mixer-bar.compact-mixer {
  width: 100%;
  min-width: 250px;
  margin: 0;
  padding: 7px 10px;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  justify-content: stretch;
  gap: 8px;
}

.preview-mixer-bar strong {
  display: block;
  margin-bottom: 2px;
}

.preview-mixer-bar span {
  color: var(--muted);
  font-size: 0.78rem;
}

.preview-master-control {
  display: grid;
  grid-template-columns: auto minmax(120px, 1fr);
  align-items: center;
  gap: 8px;
  min-width: 0;
  width: min(100%, 300px);
}

.stop-all-play-button {
  width: 100%;
  justify-content: center;
  text-transform: uppercase;
}

.preview-master-control span {
  font-size: 0.74rem;
  font-weight: 900;
  text-transform: uppercase;
}

.preview-master-control input[type="range"] {
  width: 100%;
  margin: 0;
}

.preview-source-button {
  display: grid;
  gap: 2px;
  width: fit-content;
  max-width: 100%;
  padding: 6px 8px;
  border: 1px solid rgba(94, 234, 212, 0.28);
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.06);
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.14);
  color: inherit;
  text-decoration: none;
  transition: border-color 160ms ease, background 160ms ease, box-shadow 160ms ease;
}

.preview-source-button:hover,
.preview-source-button:focus-visible {
  border-color: rgba(94, 234, 212, 0.52);
  background: rgba(94, 234, 212, 0.14);
  box-shadow: 0 8px 18px rgba(94, 234, 212, 0.14);
  outline: none;
}

.preview-quality-badge {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 3px 7px;
  border: 1px solid rgba(148, 163, 184, 0.28);
  border-radius: 8px;
  background: rgba(148, 163, 184, 0.08);
  color: #cbd5e1;
  font-size: 0.68rem;
  font-weight: 950;
  text-transform: uppercase;
}

.preview-quality-badge.quality-high {
  border-color: rgba(34, 197, 94, 0.46);
  background: rgba(34, 197, 94, 0.12);
  color: #bbf7d0;
}

.preview-quality-badge.quality-mid {
  border-color: rgba(250, 204, 21, 0.5);
  background: rgba(250, 204, 21, 0.12);
  color: #fef08a;
}

.preview-quality-badge.quality-low {
  border-color: rgba(239, 68, 68, 0.5);
  background: rgba(239, 68, 68, 0.12);
  color: #fecaca;
}

.client-listening-card {
  border-color: rgba(94, 234, 212, 0.22);
  background: linear-gradient(180deg, rgba(19, 52, 71, 0.64), rgba(6, 24, 38, 0.42));
}

.client-listening-card strong {
  color: var(--text-primary);
}

.client-listening-card .workspace-badges span {
  color: var(--text-soft);
}

html[data-theme="light"] .timeline-item {
  border-color: rgba(15, 142, 145, 0.18);
  border-left-color: rgba(15, 142, 145, 0.72);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(232, 244, 247, 0.76));
  box-shadow: 0 12px 26px rgba(31, 74, 92, 0.08);
}

html[data-theme="light"] .timeline-item[open] {
  border-color: rgba(15, 142, 145, 0.42);
  border-left-color: #0f8e91;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.99), rgba(244, 250, 251, 0.94));
  box-shadow: 0 16px 36px rgba(31, 74, 92, 0.14);
}

html[data-theme="light"] .time-block {
  border-color: rgba(15, 142, 145, 0.24);
  background: rgba(15, 142, 145, 0.1);
  color: #075e61;
}

html[data-theme="light"] .timeline-kicker,
html[data-theme="light"] .timeline-action-copy strong,
html[data-theme="light"] .timeline-next-step strong,
html[data-theme="light"] .player-panel-label {
  color: #0b6f73;
}

html[data-theme="light"] .timeline-purpose,
html[data-theme="light"] .timeline-next-step span,
html[data-theme="light"] .timeline-title,
html[data-theme="light"] .state-title-chip {
  color: #082535;
}

html[data-theme="light"] .timeline-next-step,
html[data-theme="light"] .timeline-action-bar,
html[data-theme="light"] .player-panel {
  border-color: rgba(8, 37, 53, 0.12);
  background: rgba(255, 255, 255, 0.72);
}

html[data-theme="light"] .player-panel.music-panel {
  border-color: rgba(15, 142, 145, 0.22);
  background: rgba(15, 142, 145, 0.08);
}

html[data-theme="light"] .player-panel.sound-panel {
  border-color: rgba(109, 40, 217, 0.22);
  background: rgba(109, 40, 217, 0.07);
}

html[data-theme="light"] .player-panel .preview-trigger {
  color: #ffffff;
}

html[data-theme="light"] .player-panel.music-panel .preview-trigger {
  background: #0f8e91;
}

html[data-theme="light"] .player-panel.music-panel .preview-trigger:hover {
  background: #0b777a;
  box-shadow: 0 10px 24px rgba(15, 142, 145, 0.18);
}

html[data-theme="light"] .player-panel.sound-panel .preview-trigger {
  background: #6d28d9;
}

html[data-theme="light"] .player-panel.sound-panel .preview-trigger:hover {
  background: #5b21b6;
  box-shadow: 0 10px 24px rgba(109, 40, 217, 0.16);
}

html[data-theme="light"] .sound-select,
html[data-theme="light"] .sound-select select {
  color: #365c70;
}

html[data-theme="light"] .sound-select select {
  border-color: rgba(15, 142, 145, 0.22);
  background: rgba(255, 255, 255, 0.96);
}

html[data-theme="light"] .audition-panel {
  border-color: rgba(15, 142, 145, 0.42);
  border-left-color: #0f8e91;
  background: #eef6f8;
  box-shadow: 0 22px 54px rgba(31, 74, 92, 0.22);
}

html[data-theme="light"] .satellite-audition-panel {
  border-color: rgba(22, 163, 74, 0.34);
  border-left-color: #16a34a;
}

html[data-theme="light"] .audition-sticky {
  border-bottom-color: rgba(15, 142, 145, 0.16);
  background: rgba(238, 246, 248, 0.94);
}

html[data-theme="light"] .audition-header h3,
html[data-theme="light"] .preview-title,
html[data-theme="light"] .preview-body strong {
  color: #082535;
}

html[data-theme="light"] .audition-help,
html[data-theme="light"] .preview-empty,
html[data-theme="light"] .preview-body span,
html[data-theme="light"] .preview-body em,
html[data-theme="light"] .preview-body small,
html[data-theme="light"] .preview-filetype,
html[data-theme="light"] .preview-duration,
html[data-theme="light"] .preview-time {
  color: #456779;
}

html[data-theme="light"] .audition-header a,
html[data-theme="light"] .preview-actions a {
  border-color: rgba(15, 142, 145, 0.24);
  background: rgba(15, 142, 145, 0.1);
  color: #075e61;
}

html[data-theme="light"] .audition-header a.commercial-source {
  border-color: rgba(8, 37, 53, 0.16);
  background: rgba(255, 255, 255, 0.82);
  color: #082535;
}

html[data-theme="light"] .audition-header a.mixed-source {
  border-color: rgba(109, 40, 217, 0.22);
  background: rgba(109, 40, 217, 0.08);
  color: #5b21b6;
}

html[data-theme="light"] .sound-layer-toggle {
  border-color: rgba(22, 163, 74, 0.3) !important;
  background: rgba(22, 163, 74, 0.1) !important;
  color: #15803d !important;
}

html[data-theme="light"] .preview-card {
  border-color: rgba(8, 37, 53, 0.12);
  background: rgba(255, 255, 255, 0.88);
}

html[data-theme="light"] .preview-card.is-playing {
  border-color: rgba(202, 138, 4, 0.72) !important;
  box-shadow: inset 6px 0 0 rgba(202, 138, 4, 0.78) !important;
}

html[data-theme="light"] .preview-filter-strip,
html[data-theme="light"] .preview-mixer-bar,
html[data-theme="light"] .preview-volume-control {
  border-color: rgba(15, 142, 145, 0.16);
  background: rgba(255, 255, 255, 0.72);
}

html[data-theme="light"] .satellite-filter-row,
html[data-theme="light"] .preview-access-filter,
html[data-theme="light"] .preview-format-filter,
html[data-theme="light"] .preview-duration-filter,
html[data-theme="light"] .preview-filter-strip label {
  color: #365c70;
}

html[data-theme="light"] .satellite-filter-row select,
html[data-theme="light"] .preview-access-filter select,
html[data-theme="light"] .preview-format-filter select,
html[data-theme="light"] .preview-duration-filter input,
html[data-theme="light"] .preview-filter-strip input,
html[data-theme="light"] .preview-filter-strip select {
  border-color: rgba(15, 142, 145, 0.24);
  background: rgba(255, 255, 255, 0.98);
  color: #082535;
}

html[data-theme="light"] .preview-play-toggle {
  border-color: rgba(15, 142, 145, 0.28);
  background: rgba(15, 142, 145, 0.1);
  color: #075e61;
}

html[data-theme="light"] .track-toggle {
  border-color: rgba(8, 37, 53, 0.14);
  background: rgba(255, 255, 255, 0.76);
  color: #456779;
}

html[data-theme="light"] .track-toggle.active,
html[data-theme="light"] .preview-tags span {
  border-color: rgba(15, 142, 145, 0.24);
  background: rgba(15, 142, 145, 0.09);
  color: #075e61;
}

html[data-theme="light"] .preview-card-sound .preview-tags span {
  border-color: rgba(22, 163, 74, 0.24);
  background: rgba(22, 163, 74, 0.09);
  color: #15803d;
}

html[data-theme="light"] .access-badge.listen-only {
  border-color: rgba(69, 103, 121, 0.22);
  background: rgba(69, 103, 121, 0.08);
  color: #365c70;
}

html[data-theme="light"] .client-listening-card {
  border-color: rgba(15, 142, 145, 0.18);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(232, 244, 247, 0.72));
}

html[data-theme="light"] .client-listening-card .workspace-badges span {
  border-color: rgba(15, 142, 145, 0.16);
  background: rgba(15, 142, 145, 0.08);
  color: #365c70;
}

.preview-access-badge-link {
  text-decoration: none;
}

.satellite-audition-panel .preview-panel-toolbar {
  grid-template-columns: minmax(0, 1fr) minmax(210px, 280px);
  align-items: start;
}

.satellite-audition-panel.split-right .preview-panel-toolbar {
  grid-template-columns: 1fr;
  gap: 12px;
}

.satellite-audition-panel .preview-filter-strip {
  gap: 10px;
  align-items: end;
}

.satellite-audition-panel .preview-mixer-bar.compact-mixer {
  min-width: 220px;
}

.inbox-message-card.unread {
  border-color: rgba(94, 234, 212, 0.28);
}

.inbox-compose-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
  align-items: start;
}

.inbox-compose-tabs {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.inbox-compose-tabs .workspace-tab {
  font-size: 0.9rem;
  min-height: 36px;
  padding: 8px 12px;
}

.inbox-compose-card {
  min-height: 100%;
  align-content: start;
  border-color: rgba(94, 234, 212, 0.18);
}

.inbox-compose-card .compact-form-grid {
  grid-template-columns: 1fr;
  gap: 10px;
}

.playlist-history-topline {
  align-items: start;
  display: grid;
  gap: 12px;
  grid-template-columns: minmax(0, 1fr) auto;
  margin-bottom: 14px;
}

.playlist-history-topline .lead {
  margin: 0;
}

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

.inbox-group-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.inbox-group-pill {
  width: auto;
  min-height: 34px;
  padding: 7px 10px;
  border-color: rgba(94, 234, 212, 0.2);
  background: rgba(94, 234, 212, 0.08);
  color: var(--text-primary);
  text-align: left;
}

.inbox-group-pill span {
  display: block;
  color: var(--text-secondary);
  font-size: 0.74rem;
}

.inbox-thread-stack {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.inbox-thread-card {
  gap: 14px;
}

.inbox-conversation-card {
  overflow: hidden;
  border: 1px solid rgba(154, 184, 203, 0.16);
  border-radius: 8px;
  background: rgba(8, 18, 26, 0.34);
  box-shadow: 0 16px 34px rgba(0, 0, 0, 0.13);
  transition: border-color 160ms ease, background 160ms ease, box-shadow 160ms ease;
}

html[data-theme="light"] .inbox-conversation-card {
  border-color: rgba(15, 71, 94, 0.14);
  background: #f7fbfc;
  box-shadow: 0 16px 34px rgba(31, 74, 92, 0.12);
}

.inbox-conversation-card.is-open {
  border-color: rgba(94, 234, 212, 0.26);
  background: rgba(10, 24, 34, 0.48);
}

html[data-theme="light"] .inbox-conversation-card.is-open {
  border-color: rgba(15, 142, 145, 0.24);
  background: #f8fcfd;
}

.inbox-conversation-card.is-unread {
  border-color: rgba(94, 234, 212, 0.32);
  box-shadow: inset 3px 0 0 rgba(94, 234, 212, 0.48), 0 16px 34px rgba(0, 0, 0, 0.13);
}

html[data-theme="light"] .inbox-conversation-card.is-unread {
  border-color: rgba(15, 142, 145, 0.3);
  box-shadow: inset 3px 0 0 rgba(15, 142, 145, 0.42), 0 16px 34px rgba(31, 74, 92, 0.12);
}

.inbox-conversation-summary {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 78px;
  padding: 14px 16px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--text-primary);
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.inbox-conversation-summary:hover,
.inbox-conversation-summary:focus-visible {
  background: rgba(255, 255, 255, 0.035);
  outline: none;
}

html[data-theme="light"] .inbox-conversation-summary:hover,
html[data-theme="light"] .inbox-conversation-summary:focus-visible {
  background: rgba(15, 142, 145, 0.055);
}

.inbox-conversation-avatar {
  display: inline-grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border: 1px solid rgba(154, 184, 203, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.055);
  color: var(--text-primary);
  font-weight: 800;
  letter-spacing: 0;
}

html[data-theme="light"] .inbox-conversation-avatar {
  border-color: rgba(15, 71, 94, 0.14);
  background: #e8f4f7;
  color: #082535;
}

.inbox-conversation-main {
  display: grid;
  min-width: 0;
  gap: 3px;
}

.inbox-conversation-topline {
  display: flex;
  min-width: 0;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.inbox-conversation-topline strong {
  min-width: 0;
  overflow: hidden;
  color: var(--text-primary);
  font-size: 0.98rem;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.inbox-conversation-card.is-unread .inbox-conversation-topline strong {
  font-weight: 850;
}

.inbox-conversation-topline span {
  flex: 0 0 auto;
  color: var(--text-secondary);
  font-size: 0.78rem;
}

.inbox-conversation-subject,
.inbox-conversation-preview {
  display: -webkit-box;
  min-width: 0;
  overflow: hidden;
  -webkit-box-orient: vertical;
  overflow-wrap: anywhere;
}

.inbox-conversation-subject {
  -webkit-line-clamp: 1;
  color: var(--text-soft);
  font-size: 0.86rem;
  font-weight: 700;
}

.inbox-conversation-preview {
  -webkit-line-clamp: 2;
  color: var(--text-secondary);
  font-size: 0.82rem;
  line-height: 1.35;
}

.inbox-conversation-side {
  display: grid;
  min-width: 84px;
  justify-items: end;
  gap: 5px;
  color: var(--text-secondary);
  font-size: 0.76rem;
}

.inbox-unread-badge {
  min-width: 24px;
  padding: 3px 8px;
  border-radius: 999px;
  background: rgba(94, 234, 212, 0.18);
  color: var(--text-primary);
  font-size: 0.72rem;
  font-weight: 800;
  text-align: center;
}

.inbox-message-count,
.inbox-thread-chevron {
  white-space: nowrap;
}

.inbox-thread-chevron {
  color: var(--text-soft);
  font-weight: 700;
}

.inbox-conversation-panel {
  display: grid;
  gap: 12px;
  padding: 0 16px 16px;
  border-top: 1px solid rgba(154, 184, 203, 0.13);
}

html[data-theme="light"] .inbox-conversation-panel {
  border-top-color: rgba(15, 71, 94, 0.12);
}

.inbox-thread-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--text-secondary);
  font-size: 0.86rem;
}

.inbox-thread-meta span {
  padding: 6px 10px;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

html[data-theme="light"] .inbox-thread-meta span {
  border-color: rgba(15, 142, 145, 0.18);
  background: #eef6f8;
}

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

.inbox-conversation-messages {
  max-height: min(68vh, 760px);
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 12px;
  border: 1px solid rgba(154, 184, 203, 0.12);
  border-radius: 8px;
  background: rgba(1, 7, 12, 0.2);
  scrollbar-gutter: stable;
}

html[data-theme="light"] .inbox-conversation-messages {
  border-color: rgba(15, 71, 94, 0.12);
  background: #eef6f8;
}

.inbox-chat-bubble {
  display: grid;
  gap: 6px;
  width: min(74%, 680px);
  padding: 12px;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
  overflow-wrap: anywhere;
}

html[data-theme="light"] .inbox-chat-bubble {
  border-color: rgba(15, 71, 94, 0.14);
  background: #ffffff;
  color: #082535;
}

.inbox-chat-bubble.client {
  justify-self: start;
  border-color: rgba(154, 184, 203, 0.18);
  background: rgba(27, 77, 107, 0.56);
}

html[data-theme="light"] .inbox-chat-bubble.client {
  border-color: rgba(15, 71, 94, 0.14);
  background: #ffffff;
}

.inbox-chat-bubble.therapist {
  justify-self: end;
  border-color: rgba(94, 234, 212, 0.3);
  background: rgba(94, 234, 212, 0.11);
}

html[data-theme="light"] .inbox-chat-bubble.therapist {
  border-color: rgba(15, 142, 145, 0.28);
  background: #dff4f3;
}

.inbox-chat-bubble.admin {
  justify-self: end;
  border-color: rgba(245, 158, 11, 0.36);
  background: rgba(245, 158, 11, 0.11);
}

.client-conversation-card {
  margin-top: 10px;
  background: rgba(8, 18, 26, 0.28);
}

.client-inbox-context-box {
  display: grid;
  gap: 12px;
}

.inbox-chat-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  color: var(--text-soft);
  font-size: 0.78rem;
}

.inbox-chat-meta strong {
  color: var(--text-primary);
}

.inbox-message-read-indicator {
  display: inline-flex;
  margin-left: 7px;
  color: var(--text-secondary);
  font-size: 0.78rem;
  font-weight: 850;
  letter-spacing: 0;
  vertical-align: baseline;
}

.inbox-message-read-indicator.read {
  color: var(--accent);
}

html[data-theme="light"] .inbox-message-read-indicator {
  color: #456779;
}

html[data-theme="light"] .inbox-message-read-indicator.read {
  color: #0f8e91;
}

.inbox-chat-bubble p {
  margin: 0;
  color: var(--text-soft);
  white-space: pre-wrap;
}

.inbox-message-delete {
  align-self: flex-end;
  background: transparent;
  border: 0;
  color: var(--text-muted);
  cursor: pointer;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 800;
  padding: 2px 0 0;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.inbox-message-delete:hover,
.inbox-message-delete:focus-visible {
  color: var(--danger);
}

html[data-theme="light"] .inbox-chat-bubble p,
html[data-theme="light"] .inbox-chat-meta,
html[data-theme="light"] .inbox-conversation-preview,
html[data-theme="light"] .inbox-conversation-subject,
html[data-theme="light"] .inbox-conversation-topline span,
html[data-theme="light"] .inbox-message-count,
html[data-theme="light"] .inbox-thread-chevron {
  color: #31586b;
}

html[data-theme="light"] .inbox-chat-meta strong,
html[data-theme="light"] .inbox-conversation-topline strong {
  color: #082535;
}

.inbox-reply-field {
  margin-top: 2px;
}

.inbox-thread-actions {
  justify-content: flex-end;
}

.attention-pulse {
  animation: attentionPulse 1.5s ease;
}

.mobile-followup-safe-route {
  display: grid;
  width: 100%;
  min-width: 0;
  gap: 14px;
}

.mobile-followup-safe-route[hidden] {
  display: none !important;
}

@media (min-width: 1081px) {
  .mobile-followup-safe-route {
    display: none !important;
  }
}

@media (max-width: 1080px) {
  .mobile-followup-safe-route {
    overflow-x: clip;
  }

  .mobile-followup-safe-route .history-list,
  .mobile-followup-safe-route .history-entry,
  .mobile-followup-safe-route .playlist-manage-card,
  .mobile-followup-safe-route .followup-assignment-list,
  .mobile-followup-safe-route .followup-assignment-card {
    min-width: 0;
    max-width: 100%;
  }
}

@keyframes attentionPulse {
  0% {
    border-color: rgba(94, 234, 212, 0.24);
    box-shadow: none;
  }
  28% {
    border-color: rgba(94, 234, 212, 0.86);
    box-shadow: 0 0 0 3px rgba(94, 234, 212, 0.18), 0 0 28px rgba(94, 234, 212, 0.18);
  }
  100% {
    border-color: rgba(94, 234, 212, 0.24);
    box-shadow: none;
  }
}

@media (max-width: 1080px) {
  .inbox-compose-panel {
    grid-template-columns: 1fr;
  }

  .playlist-history-topline {
    grid-template-columns: 1fr;
  }

  .playlist-history-topline .primary-button {
    width: 100%;
  }

  .preview-panel-toolbar {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .preview-mixer-bar.compact-mixer {
    width: 100%;
    min-width: 0;
  }

  .preview-filter-strip,
  .satellite-audition-panel .preview-filter-strip {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  }
}

.satellite-audition-panel .preview-card {
  grid-template-columns: 42px 1fr;
  gap: 8px;
  padding: 8px;
}

.satellite-audition-panel .preview-cover {
  width: 42px;
  height: 42px;
}

.satellite-audition-panel .preview-body {
  gap: 4px;
}

.preview-actions button,
.preview-actions a {
  min-height: 34px;
  padding: 7px 10px;
  font-size: 0.82rem;
}

.preview-save-button {
  width: 100%;
  border-color: var(--action) !important;
  background: var(--action) !important;
  color: var(--bg-page) !important;
  font-weight: 950;
  box-shadow: 0 8px 18px rgba(94, 234, 212, 0.18);
}

.preview-save-button:disabled {
  border-color: rgba(139, 148, 158, 0.22) !important;
  background: rgba(139, 148, 158, 0.16) !important;
  color: var(--muted) !important;
  box-shadow: none;
}

.preview-external-link {
  justify-self: start;
  border: 1px solid rgba(94, 234, 212, 0.34) !important;
  background: rgba(94, 234, 212, 0.08) !important;
  color: #f8ffff !important;
  font-weight: 800;
  font-size: 0.76rem !important;
  text-decoration: none;
}

.preview-external-link.download-action {
  min-height: 24px;
  padding: 3px 7px;
  border-color: rgba(34, 197, 94, 0.48) !important;
  background: rgba(34, 197, 94, 0.14) !important;
  color: #86efac !important;
  font-size: 0.68rem !important;
  font-weight: 950;
  text-transform: uppercase;
}

.preview-source-action-button,
.preview-source-action-button.download-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  justify-self: stretch;
  width: 100%;
  min-height: 34px;
  padding: 7px 10px;
  border-color: rgba(94, 234, 212, 0.34) !important;
  background: rgba(94, 234, 212, 0.08) !important;
  color: #f8ffff !important;
  font-size: 0.82rem !important;
  font-weight: 900;
  text-align: center;
  text-transform: none;
}

.preview-external-link:hover,
.preview-external-link:focus-visible,
a.preview-external-link.free-source:hover,
a.preview-external-link.mixed-source:hover,
a.preview-external-link.commercial-source:hover {
  background: var(--accent) !important;
  color: var(--bg-page) !important;
  border-color: rgba(94, 234, 212, 0.62) !important;
  outline: none;
}

.preview-license-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 24px;
  padding: 3px 7px;
  border: 1px solid rgba(169, 193, 204, 0.42);
  border-radius: 8px;
  color: var(--text-soft);
  background: rgba(18, 24, 33, 0.42);
  font-size: 0.68rem;
  font-weight: 850;
  text-decoration: none;
}

.preview-license-link:hover,
.preview-license-link:focus-visible {
  border-color: var(--accent);
  color: var(--bg-page);
  background: var(--accent);
  outline: none;
}

.load-more-button {
  width: 100%;
  margin-top: 12px;
  border-color: rgba(94, 234, 212, 0.35);
  background: var(--navy-soft);
  color: #a7fff3;
}

.load-more-button:hover {
  background: rgba(94, 234, 212, 0.24);
}

.no-preview-note {
  display: block;
  padding: 9px 10px;
  border: 1px dashed rgba(94, 234, 212, 0.32);
  border-radius: 8px;
  color: var(--muted);
}

.admin-board {
  padding: 22px;
}

.admin-login,
.admin-workspace {
  display: grid;
  gap: 16px;
}

.admin-login {
  max-width: 520px;
}

.two-factor-panel {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid rgba(94, 234, 212, 0.26);
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.08);
}

.two-factor-setup {
  margin: 0;
  padding: 9px 10px;
  border: 1px dashed rgba(245, 158, 11, 0.42);
  border-radius: 8px;
  color: #fbbf24;
  overflow-wrap: anywhere;
}

.admin-workspace {
  grid-template-columns: minmax(210px, 260px) minmax(0, 1fr);
  grid-template-rows: auto 1fr;
  align-items: start;
  gap: 18px;
}

.admin-menu-toggle {
  grid-column: 1;
  grid-row: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
}

body.admin-sidebar-collapsed .admin-workspace {
  grid-template-columns: 72px minmax(0, 1fr);
}

.admin-side-nav {
  grid-column: 1;
  grid-row: 2;
  position: sticky;
  top: 14px;
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid rgba(94, 234, 212, 0.14);
  border-radius: 8px;
  background: var(--bg-sidebar);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.22);
}

.admin-content {
  grid-column: 2;
  grid-row: 1 / span 2;
  min-width: 0;
}

body.admin-sidebar-collapsed .admin-side-nav {
  padding: 8px;
}

body.admin-sidebar-collapsed .admin-side-nav .nav-label {
  display: none;
}

body.admin-sidebar-collapsed .admin-menu-toggle .nav-label {
  display: none;
}

.admin-nav-button {
  justify-content: flex-start;
  width: 100%;
  min-height: 44px;
  text-align: left;
  background: transparent;
  color: var(--muted);
}

body.admin-sidebar-collapsed .admin-nav-button {
  justify-content: center;
  padding-inline: 8px;
}

.admin-nav-button.active {
  border-color: rgba(94, 234, 212, 0.45);
  background: #1c4f68;
  color: var(--action);
}

.admin-content {
  min-width: 0;
}

.admin-content .admin-card {
  background: var(--bg-card);
}

.admin-nav-button.danger-nav {
  border-color: rgba(239, 68, 68, 0.35);
  color: #fca5a5;
}

.admin-nav-kicker {
  padding: 0 4px 4px;
  color: var(--text-secondary);
  font-size: 0.72rem;
  font-weight: 950;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.admin-nav-group {
  border: 1px solid rgba(94, 234, 212, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
  overflow: hidden;
}

.admin-nav-group summary {
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 38px;
  padding: 9px 10px;
  color: var(--text-soft);
  font-size: 0.76rem;
  font-weight: 950;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  list-style: none;
}

.admin-nav-group summary::-webkit-details-marker {
  display: none;
}

.admin-nav-group summary::after {
  content: "+";
  margin-left: auto;
  color: var(--accent);
  font-weight: 950;
}

.admin-nav-group[open] summary::after {
  content: "-";
}

.admin-nav-group:has(.admin-nav-button.active) {
  border-color: rgba(94, 234, 212, 0.36);
  background: rgba(94, 234, 212, 0.055);
}

.admin-nav-group .admin-nav-button {
  min-height: 40px;
  border: 0;
  border-top: 1px solid rgba(94, 234, 212, 0.1);
  border-radius: 0;
  background: transparent;
}

.admin-nav-group .admin-nav-button.active {
  border-left: 3px solid var(--accent);
  background: rgba(94, 234, 212, 0.13);
  color: var(--accent);
}

.admin-nav-footer {
  padding-top: 4px;
}

body.admin-sidebar-collapsed .admin-nav-kicker,
body.admin-sidebar-collapsed .admin-nav-group summary .nav-label,
body.admin-sidebar-collapsed .admin-nav-group summary::after {
  display: none;
}

body.admin-sidebar-collapsed .admin-nav-group {
  display: grid;
  gap: 6px;
  border-color: transparent;
  background: transparent;
  overflow: visible;
}

body.admin-sidebar-collapsed .admin-nav-group summary {
  justify-content: center;
  min-height: 0;
  padding: 0;
}

body.admin-sidebar-collapsed .admin-nav-group .admin-nav-button {
  justify-content: center;
  min-height: 42px;
  padding-inline: 8px;
  border: 1px solid rgba(94, 234, 212, 0.14);
  border-radius: 8px;
}

.notification-preference-list,
.email-template-list,
.support-ticket-list {
  display: grid;
  gap: 14px;
}

.notification-preference-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 13px 14px;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(19, 52, 71, 0.62), rgba(6, 24, 38, 0.42));
}

.notification-preference-group {
  display: grid;
  gap: 8px;
}

.notification-preference-group-heading {
  display: grid;
  gap: 3px;
  padding: 0 2px;
}

.notification-preference-group-heading strong {
  color: var(--text-primary);
  font-size: 0.98rem;
}

.notification-preference-group-heading span {
  color: var(--text-secondary);
  font-size: 0.84rem;
  font-weight: 750;
}

.notification-preference-card.is-paused {
  border-color: rgba(148, 163, 184, 0.2);
  background: rgba(6, 24, 38, 0.24);
}

.notification-preference-card.is-required {
  border-color: rgba(148, 163, 184, 0.24);
  background: rgba(15, 23, 42, 0.22);
}

.notification-preference-copy {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.notification-preference-copy span {
  width: fit-content;
  padding: 4px 8px;
  border: 1px solid rgba(94, 234, 212, 0.22);
  border-radius: 999px;
  background: rgba(94, 234, 212, 0.1);
  color: #99f6e4;
  font-size: 0.68rem;
  font-weight: 950;
  letter-spacing: 0.1em;
}

.notification-preference-copy strong {
  color: var(--text-primary);
  font-size: 0.96rem;
}

.notification-preference-copy p,
.notification-preference-copy small {
  margin: 0;
  color: var(--text-secondary);
  line-height: 1.35;
}

.notification-preference-copy small {
  font-size: 0.78rem;
  font-weight: 750;
}

.notification-preference-toggle {
  display: inline-grid;
  grid-template-columns: auto auto;
  gap: 10px;
  align-items: center;
  min-width: 132px;
  justify-content: end;
  cursor: pointer;
}

.notification-preference-toggle input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.notification-preference-toggle span {
  position: relative;
  width: 48px;
  height: 28px;
  border: 1px solid rgba(148, 163, 184, 0.34);
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.18);
  transition: background 0.18s ease, border-color 0.18s ease;
}

.notification-preference-toggle span::after {
  content: "";
  position: absolute;
  top: 4px;
  left: 4px;
  width: 18px;
  height: 18px;
  border-radius: 999px;
  background: #f8fafc;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.24);
  transition: transform 0.18s ease;
}

.notification-preference-toggle input:checked + span {
  border-color: rgba(94, 234, 212, 0.52);
  background: rgba(79, 209, 197, 0.72);
}

.notification-preference-toggle input:checked + span::after {
  transform: translateX(20px);
}

.notification-preference-toggle input:focus-visible + span {
  outline: 3px solid rgba(94, 234, 212, 0.32);
  outline-offset: 2px;
}

.notification-preference-toggle em {
  color: var(--text-primary);
  font-size: 0.84rem;
  font-style: normal;
  font-weight: 900;
}

.notification-required-pill {
  width: fit-content;
  padding: 7px 10px;
  border: 1px solid rgba(148, 163, 184, 0.26);
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.12);
  color: var(--text-secondary);
  font-size: 0.78rem;
  font-weight: 950;
}

.notification-system-note {
  margin: 2px 0 0;
  padding: 9px 10px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 8px;
  background: rgba(6, 24, 38, 0.18);
  color: var(--text-secondary);
  font-size: 0.82rem;
  font-weight: 750;
}

html[data-theme="light"] .notification-preference-card {
  border-color: rgba(15, 142, 145, 0.2);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(232, 244, 247, 0.7));
}

html[data-theme="light"] .notification-preference-card.is-paused {
  border-color: rgba(69, 103, 121, 0.18);
  background: rgba(255, 255, 255, 0.72);
}

html[data-theme="light"] .notification-preference-card.is-required {
  border-color: rgba(69, 103, 121, 0.18);
  background: rgba(248, 250, 252, 0.82);
}

html[data-theme="light"] .notification-preference-copy span {
  border-color: rgba(15, 142, 145, 0.22);
  background: rgba(15, 142, 145, 0.1);
  color: #0b6f73;
}

html[data-theme="light"] .notification-preference-toggle span::after {
  background: #ffffff;
}

html[data-theme="light"] .notification-required-pill {
  border-color: rgba(69, 103, 121, 0.18);
  background: rgba(226, 232, 240, 0.74);
  color: #456779;
}

html[data-theme="light"] .notification-system-note {
  border-color: rgba(69, 103, 121, 0.16);
  background: rgba(255, 255, 255, 0.62);
  color: #456779;
}

html[data-theme="light"] .email-template-card {
  border-color: rgba(15, 142, 145, 0.18);
  background: rgba(255, 255, 255, 0.84);
}

html[data-theme="light"] .email-template-card summary {
  background: rgba(232, 244, 247, 0.64);
  color: #082535;
}

html[data-theme="light"] .email-template-editor-shell {
  border-color: rgba(15, 142, 145, 0.18);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(239, 248, 250, 0.86));
}

html[data-theme="light"] .email-template-pill {
  border-color: rgba(15, 142, 145, 0.2);
  background: rgba(15, 142, 145, 0.1);
  color: #0b6f73;
}

html[data-theme="light"] .email-template-context-grid,
html[data-theme="light"] .email-editor-advanced {
  border-color: rgba(15, 142, 145, 0.14);
  background: rgba(255, 255, 255, 0.7);
}

html[data-theme="light"] .email-template-variable-group code {
  border-color: rgba(15, 142, 145, 0.18);
  background: rgba(15, 142, 145, 0.08);
  color: #0b6f73;
}

html[data-theme="light"] .email-mode-toggle {
  border-color: rgba(15, 142, 145, 0.18);
  background: rgba(255, 255, 255, 0.82);
}

html[data-theme="light"] .email-mode-toggle button {
  color: #31586b;
}

html[data-theme="light"] .email-mode-toggle button.active {
  background: rgba(15, 142, 145, 0.12);
  color: #075e61;
}

html[data-theme="light"] .email-editor-toolbar {
  border-color: rgba(15, 142, 145, 0.16);
  background: rgba(232, 244, 247, 0.64);
}

html[data-theme="light"] .email-editor-toolbar button,
html[data-theme="light"] .email-editor-toolbar select,
html[data-theme="light"] .email-color-control {
  border-color: rgba(8, 37, 53, 0.14);
  background: rgba(255, 255, 255, 0.9);
  color: #0f3346;
}

html[data-theme="light"] .email-editor-surface,
html[data-theme="light"] .email-editor-html {
  border-color: rgba(15, 142, 145, 0.18);
  background: #ffffff;
  color: #082535;
}

html[data-theme="light"] .email-editor-footer {
  border-color: rgba(15, 142, 145, 0.14);
  background: rgba(232, 244, 247, 0.72);
  color: #456779;
}

.email-template-card,
.support-ticket-row {
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(6, 24, 38, 0.32);
  overflow: hidden;
}

.email-template-card summary,
.support-ticket-row summary,
.support-ticket-head {
  display: grid;
  grid-template-columns: 1.1fr 1.8fr 0.8fr 0.8fr 1fr 0.7fr;
  gap: 10px;
  align-items: center;
  padding: 10px 12px;
}

.email-template-card summary {
  grid-template-columns: 1fr auto;
  cursor: pointer;
}

.email-template-editor-shell {
  display: grid;
  gap: 16px;
  margin: 12px;
  padding: 18px;
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(19, 52, 71, 0.74), rgba(6, 24, 38, 0.72));
}

.email-template-pill {
  justify-self: start;
  padding: 9px 18px;
  border: 1px solid rgba(94, 234, 212, 0.22);
  border-radius: 999px;
  background: rgba(94, 234, 212, 0.12);
  color: #99f6e4;
  font-size: 0.78rem;
  font-weight: 950;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.email-template-subject {
  display: grid;
  gap: 10px;
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 950;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.email-template-subject input {
  min-height: 58px;
  padding: 14px 18px;
  border-radius: 8px;
  font-size: 1.05rem;
  letter-spacing: 0;
  text-transform: none;
}

.email-template-context-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  padding: 12px;
  border: 1px solid rgba(94, 234, 212, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
}

.email-template-context-grid div {
  display: grid;
  gap: 5px;
}

.email-template-context-grid strong,
.email-template-variable-group span {
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 950;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.email-template-context-grid span {
  line-height: 1.35;
}

.email-template-mode-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 950;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.email-mode-toggle {
  display: inline-flex;
  overflow: hidden;
  border: 1px solid rgba(94, 234, 212, 0.22);
  border-radius: 8px;
  background: rgba(8, 16, 28, 0.72);
}

.email-mode-toggle button {
  min-width: 86px;
  min-height: 42px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--muted);
  font-weight: 950;
}

.email-mode-toggle button.active {
  background: rgba(94, 234, 212, 0.18);
  color: #dffefa;
}

.email-editor-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  padding: 12px;
  border: 1px solid rgba(94, 234, 212, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.email-editor-advanced {
  display: grid;
  gap: 10px;
  padding: 10px;
  border: 1px solid rgba(94, 234, 212, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.email-editor-advanced summary {
  cursor: pointer;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 950;
}

.email-editor-toolbar-advanced {
  border: 0;
  padding: 0;
  background: transparent;
}

.email-editor-toolbar button,
.email-editor-toolbar select,
.email-color-control {
  min-height: 40px;
  padding: 7px 10px;
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: 8px;
  background: rgba(8, 16, 28, 0.74);
  color: #dbeafe;
  font-weight: 900;
}

.email-editor-toolbar button,
.email-editor-toolbar select {
  white-space: nowrap;
}

.email-color-control {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.78rem;
}

.email-color-control input[type="color"] {
  width: 32px;
  height: 26px;
  padding: 0;
  border: 0;
  border-radius: 6px;
  background: transparent;
}

.email-editor-surface,
.email-editor-html {
  width: 100%;
  min-height: 240px;
  padding: 20px;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(3, 10, 18, 0.82);
  color: var(--ink);
  font-size: 1rem;
  line-height: 1.65;
  overflow: auto;
}

.email-editor-html {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  resize: vertical;
}

.email-editor-surface table {
  width: 100%;
  border-collapse: collapse;
}

.email-editor-surface td {
  border: 1px solid rgba(94, 234, 212, 0.22);
  padding: 6px;
}

.email-editor-footer {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-top: -16px;
  padding: 11px 16px;
  border: 1px solid rgba(94, 234, 212, 0.14);
  border-top: 0;
  border-radius: 0 0 8px 8px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
  font-weight: 900;
}

.email-template-variables {
  display: grid;
  gap: 10px;
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1.45;
}

.email-template-variable-groups {
  display: grid;
  gap: 10px;
}

.email-template-variable-group {
  display: grid;
  gap: 6px;
}

.email-template-variable-group div {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.email-template-variable-group code {
  padding: 5px 8px;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 999px;
  background: rgba(94, 234, 212, 0.08);
  color: #99f6e4;
  font-family: inherit;
  font-size: 0.78rem;
  font-weight: 850;
}

.email-template-save-button {
  justify-self: start;
}

@media (max-width: 1024px) {
  .email-template-context-grid {
    grid-template-columns: 1fr;
  }

  .email-template-editor-shell {
    gap: 12px;
    margin: 10px;
    padding: 14px;
  }

  .email-template-mode-row {
    align-items: stretch;
    flex-direction: column;
  }

  .email-mode-toggle {
    width: 100%;
  }

  .email-mode-toggle button {
    flex: 1 1 50%;
    min-width: 0;
  }

  .email-editor-toolbar {
    align-items: stretch;
  }

  .email-editor-toolbar button,
  .email-editor-toolbar select,
  .email-color-control {
    flex: 1 1 140px;
  }

  .email-editor-surface,
  .email-editor-html {
    min-height: 220px;
    padding: 16px;
  }
}

.support-ticket-table {
  display: grid;
  gap: 8px;
}

.support-ticket-head {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 900;
  text-transform: uppercase;
}

.support-ticket-row summary {
  cursor: pointer;
}

.support-ticket-messages {
  display: grid;
  gap: 10px;
  padding: 0 12px 12px;
}

.support-ticket-messages > article {
  padding: 10px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
}

.support-ticket-chat-list {
  padding-top: 2px;
}

.support-ticket-bubble {
  width: min(86%, 760px);
}

.beta-feedback-button {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 120;
  min-height: 42px;
  padding: 0 16px;
  border-color: rgba(94, 234, 212, 0.36);
  background: var(--accent);
  color: #ffffff;
  box-shadow: 0 14px 34px rgba(31, 74, 92, 0.24);
}

.beta-feedback-card {
  width: min(620px, 100%);
}

.privacy-warning {
  padding: 10px 12px;
  border: 1px solid rgba(245, 158, 11, 0.26);
  border-radius: 8px;
  color: var(--text-secondary);
  background: rgba(245, 158, 11, 0.08);
}

.beta-feedback-admin-list,
.beta-feedback-detail {
  display: grid;
  gap: 10px;
}

.beta-feedback-row {
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
}

.beta-feedback-row summary {
  display: grid;
  grid-template-columns: auto minmax(180px, 1fr) repeat(5, auto);
  gap: 10px;
  align-items: center;
  padding: 12px;
  cursor: pointer;
}

.beta-feedback-detail {
  padding: 0 12px 12px;
}

.beta-feedback-meta {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 8px;
  color: var(--text-secondary);
}

.beta-feedback-meta span {
  display: grid;
  gap: 2px;
  min-width: 0;
  overflow-wrap: anywhere;
}

.beta-feedback-screenshot-wrap {
  display: grid;
  gap: 8px;
}

.beta-feedback-screenshot {
  max-width: min(420px, 100%);
  max-height: 260px;
  border: 1px solid var(--border);
  border-radius: 8px;
  object-fit: contain;
}

@media (max-width: 760px) {
  .beta-feedback-button {
    right: 12px;
    bottom: 12px;
  }

  .beta-feedback-row summary {
    grid-template-columns: 1fr;
    align-items: start;
  }
}

.admin-content {
  min-width: 0;
}

.admin-section {
  display: none;
}

.admin-section.active {
  display: block;
}

.admin-stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.admin-stat {
  padding: 12px;
  border: 1px solid rgba(94, 234, 212, 0.22);
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.08);
}

.admin-stat strong {
  display: block;
  font-size: 1.8rem;
  line-height: 1;
  color: var(--action);
}

.admin-stat span {
  display: block;
  margin-top: 6px;
  color: var(--muted);
}

.admin-stat.privacy-ok {
  border-color: rgba(74, 222, 128, 0.42);
  background: rgba(74, 222, 128, 0.1);
}

.admin-stat.privacy-warning {
  border-color: rgba(251, 191, 36, 0.6);
  background: rgba(251, 191, 36, 0.12);
}

.admin-stat.privacy-warning strong {
  color: #fbbf24;
}

.admin-overview-note {
  display: grid;
  gap: 7px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
}

.admin-health-panel {
  display: grid;
  gap: 14px;
}

.admin-health-overall {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px;
  border: 1px solid rgba(94, 234, 212, 0.2);
  border-radius: 8px;
  background: linear-gradient(135deg, rgba(6, 24, 38, 0.64), rgba(9, 78, 99, 0.18));
}

.admin-health-overall.ok {
  border-color: rgba(74, 222, 128, 0.32);
}

.admin-health-overall.warning {
  border-color: rgba(251, 191, 36, 0.42);
}

.admin-health-overall.error {
  border-color: rgba(248, 113, 113, 0.5);
}

.admin-health-overall > div:first-child {
  display: grid;
  gap: 3px;
}

.admin-health-overall span,
.admin-health-overall small {
  color: var(--muted);
}

.admin-health-overall span {
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.admin-health-overall strong {
  color: var(--text);
  font-size: clamp(1.35rem, 2vw, 1.9rem);
  line-height: 1.05;
}

.admin-health-overall-chips {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}

.admin-health-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 10px;
}

.admin-health-card,
.admin-audit-panel {
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(6, 24, 38, 0.24);
}

.admin-health-card {
  display: grid;
  align-content: start;
  gap: 8px;
  padding: 12px;
}

.admin-health-card.ok {
  border-color: rgba(74, 222, 128, 0.34);
}

.admin-health-card.warning {
  border-color: rgba(251, 191, 36, 0.42);
}

.admin-health-card.error {
  border-color: rgba(248, 113, 113, 0.52);
}

.admin-health-card-head,
.admin-audit-head,
.admin-audit-event {
  display: flex;
  gap: 10px;
}

.admin-health-card-head,
.admin-audit-head {
  align-items: flex-start;
  justify-content: space-between;
  flex-wrap: wrap;
}

.admin-health-card h4,
.admin-audit-head h4 {
  margin: 0;
  color: var(--text);
}

.admin-health-card p,
.admin-audit-head p {
  margin: 0;
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.35;
}

.admin-health-badge {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  max-width: 100%;
  padding: 4px 7px;
  border: 1px solid rgba(148, 163, 184, 0.38);
  border-radius: 8px;
  color: var(--text-soft);
  font-size: 0.72rem;
  font-weight: 950;
  white-space: normal;
}

.admin-health-badge.ok {
  border-color: rgba(74, 222, 128, 0.42);
  background: rgba(74, 222, 128, 0.1);
  color: #bbf7d0;
}

.admin-health-badge.warning {
  border-color: rgba(251, 191, 36, 0.52);
  background: rgba(251, 191, 36, 0.12);
  color: #fde68a;
}

.admin-health-badge.error {
  border-color: rgba(248, 113, 113, 0.56);
  background: rgba(248, 113, 113, 0.13);
  color: #fecaca;
}

.admin-health-badge.info {
  border-color: rgba(94, 234, 212, 0.28);
  background: rgba(94, 234, 212, 0.1);
  color: var(--accent);
}

.admin-health-rows {
  display: grid;
  gap: 5px;
}

.admin-health-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 0.86rem;
}

.admin-health-row strong {
  color: var(--text);
  text-align: right;
}

.admin-health-details {
  border-top: 1px solid rgba(94, 234, 212, 0.12);
  padding-top: 8px;
}

.admin-health-details summary {
  cursor: pointer;
  color: var(--accent);
  font-size: 0.82rem;
  font-weight: 900;
}

.admin-health-detail-list {
  display: grid;
  gap: 6px;
  padding-top: 8px;
}

.admin-health-detail-item {
  display: grid;
  gap: 2px;
  padding: 8px;
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.admin-health-detail-item strong {
  color: var(--text);
}

.admin-health-detail-item span,
.admin-health-detail-item small {
  color: var(--muted);
}

.admin-audit-panel {
  padding: 12px;
}

.admin-audit-head {
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(94, 234, 212, 0.14);
}

.admin-audit-list {
  display: grid;
  gap: 8px;
  padding-top: 10px;
}

.admin-audit-summary .admin-audit-list {
  max-height: 360px;
  overflow: auto;
  padding-right: 3px;
}

.admin-audit-explorer {
  display: grid;
  gap: 12px;
}

.admin-audit-filters {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 8px;
  padding: 10px 0 2px;
}

.admin-audit-filter {
  display: grid;
  gap: 5px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 850;
}

.admin-audit-filter select,
.admin-audit-filter input {
  width: 100%;
  min-width: 0;
  min-height: 40px;
  border: 1px solid rgba(94, 234, 212, 0.22);
  border-radius: 8px;
  background: rgba(3, 12, 22, 0.45);
  color: var(--text);
  font: inherit;
}

.admin-audit-filter-search {
  grid-column: span 2;
}

.admin-audit-filter-limit {
  max-width: 120px;
}

.admin-audit-filters .compact-button {
  align-self: end;
  min-height: 40px;
  white-space: nowrap;
}

.admin-audit-event {
  align-items: flex-start;
  justify-content: space-between;
  flex-wrap: wrap;
  padding: 10px;
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.admin-audit-main,
.admin-audit-side {
  display: grid;
  gap: 3px;
}

.admin-audit-main strong {
  color: var(--text);
}

.admin-audit-main span,
.admin-audit-side,
.admin-audit-side small {
  color: var(--muted);
}

.admin-audit-side {
  text-align: right;
  font-size: 0.82rem;
}

.admin-audit-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  width: 100%;
  padding-top: 4px;
}

.admin-audit-meta span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  max-width: 100%;
  padding: 2px 6px;
  border: 1px solid rgba(94, 234, 212, 0.14);
  border-radius: 8px;
  color: var(--muted);
  font-size: 0.72rem;
}

.admin-audit-meta strong {
  color: var(--text-soft);
  font-size: 0.68rem;
}

html[data-theme="light"] .admin-health-card,
html[data-theme="light"] .admin-audit-panel {
  background: rgba(255, 255, 255, 0.78);
  border-color: rgba(9, 78, 99, 0.16);
}

html[data-theme="light"] .admin-health-overall {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.92), rgba(218, 247, 246, 0.72));
  border-color: rgba(9, 78, 99, 0.18);
}

html[data-theme="light"] .admin-audit-event {
  background: rgba(248, 252, 253, 0.88);
  border-color: rgba(9, 78, 99, 0.12);
}

html[data-theme="light"] .admin-health-detail-item {
  background: rgba(248, 252, 253, 0.88);
  border-color: rgba(9, 78, 99, 0.12);
}

html[data-theme="light"] .admin-audit-filter select,
html[data-theme="light"] .admin-audit-filter input {
  background: rgba(255, 255, 255, 0.94);
  border-color: rgba(9, 78, 99, 0.18);
  color: #0f2b3a;
}

html[data-theme="light"] .admin-health-badge.ok {
  color: #166534;
}

html[data-theme="light"] .admin-health-badge.warning {
  color: #92400e;
}

html[data-theme="light"] .admin-health-badge.error {
  color: #991b1b;
}

.admin-control-map {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 10px;
  margin: 0 0 14px;
}

.admin-control-shortcut {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  min-height: 84px;
  padding: 12px;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(6, 24, 38, 0.24);
  color: var(--text-primary);
  text-align: left;
}

.admin-control-shortcut:hover,
.admin-control-shortcut:focus-visible {
  border-color: rgba(94, 234, 212, 0.5);
  background: rgba(94, 234, 212, 0.11);
  color: var(--text-primary);
}

.admin-control-shortcut .nav-icon {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid rgba(94, 234, 212, 0.2);
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.08);
  color: var(--accent);
}

.admin-control-shortcut strong {
  display: block;
  color: var(--text-primary);
}

.admin-control-shortcut span:not(.nav-icon),
.admin-control-shortcut small {
  display: block;
  margin-top: 3px;
  color: var(--text-secondary);
}

.workspace-context-box {
  display: grid;
  gap: 8px;
  margin: 10px 0 14px;
  padding: 12px;
  border: 1px solid rgba(94, 234, 212, 0.2);
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.06);
}

.workspace-context-box strong {
  color: var(--ink);
}

.workspace-context-box span,
.workspace-context-box small {
  color: var(--muted);
}

.header-theme-switch {
  display: inline-flex;
  align-items: center;
  width: 48px;
  height: 48px;
  min-height: 48px;
  padding: 0;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.045);
}

.single-theme-switch {
  width: 48px;
  justify-content: center;
}

.header-theme-button {
  display: inline-grid;
  place-items: center;
  width: 48px;
  min-width: 48px;
  height: 48px;
  min-height: 48px;
  padding: 0;
  border: 1px solid transparent;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1;
}

.header-theme-button:hover {
  border-color: rgba(94, 234, 212, 0.34);
  background: rgba(94, 234, 212, 0.1);
  color: var(--action);
}

.header-theme-button.active {
  border-color: var(--action);
  background: rgba(94, 234, 212, 0.18);
  color: #a7fff3;
  box-shadow: 0 0 0 1px rgba(94, 234, 212, 0.16);
}

.header-theme-toggle {
  border-color: rgba(94, 234, 212, 0.2);
  background: rgba(94, 234, 212, 0.1);
  color: var(--action);
}

html[data-theme="light"] .header-theme-switch {
  border-color: rgba(8, 37, 53, 0.16);
  background: rgba(248, 252, 253, 0.74);
}

html[data-theme="light"] .header-theme-button {
  color: #365c70;
}

html[data-theme="light"] .header-theme-button:hover {
  border-color: rgba(15, 142, 145, 0.38);
  background: rgba(15, 142, 145, 0.1);
  color: #075e61;
}

html[data-theme="light"] .header-theme-button.active {
  border-color: #0f8e91;
  background: #0f8e91;
  color: #ffffff;
  box-shadow: 0 8px 18px rgba(15, 142, 145, 0.18);
}

html[data-theme="light"] .header-theme-toggle {
  border-color: rgba(15, 142, 145, 0.22);
  background: rgba(15, 142, 145, 0.1);
  color: #075e61;
}

.active-journey-tools .header-theme-switch {
  flex: 0 0 auto;
}

html[data-theme="light"] .lead,
html[data-theme="light"] .field-hint,
html[data-theme="light"] .profile-card > p,
html[data-theme="light"] .facilitator-card > p,
html[data-theme="light"] .workspace-context-box span,
html[data-theme="light"] .workspace-context-box small,
html[data-theme="light"] .workspace-summary-card small,
html[data-theme="light"] .history-entry small,
html[data-theme="light"] .service-item small {
  color: #3b6174;
}

html[data-theme="light"] body.facilitator-shell .section-heading .lead,
html[data-theme="light"] body.client-shell .section-heading .lead {
  color: #496d7e;
}

html[data-theme="light"] .eyebrow,
html[data-theme="light"] label,
html[data-theme="light"] .workspace-summary-card span,
html[data-theme="light"] .top-therapist-copy span,
html[data-theme="light"] .active-journey-copy span {
  color: #365c70;
}

html[data-theme="light"] .workspace-today-card,
html[data-theme="light"] .workspace-metric-card,
html[data-theme="light"] .workspace-ops-panel {
  border-color: rgba(15, 142, 145, 0.14);
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 12px 26px rgba(31, 74, 92, 0.08);
}

html[data-theme="light"] .workspace-today-card {
  background: linear-gradient(135deg, rgba(15, 142, 145, 0.1), rgba(255, 255, 255, 0.9));
}

html[data-theme="light"] .workspace-today-main p,
html[data-theme="light"] .workspace-today-meta span,
html[data-theme="light"] .workspace-metric-card small,
html[data-theme="light"] .workspace-dashboard-row small,
html[data-theme="light"] .workspace-health-list span,
html[data-theme="light"] .workspace-health-list small,
html[data-theme="light"] .workspace-empty-compact {
  color: #3b6174;
}

html[data-theme="light"] .workspace-today-meta span,
html[data-theme="light"] .workspace-health-warning span {
  border-color: rgba(15, 142, 145, 0.14);
  background: rgba(15, 142, 145, 0.08);
}

html[data-theme="light"] .workspace-dashboard-row {
  border-color: rgba(15, 142, 145, 0.12);
  background: rgba(238, 246, 248, 0.82);
}

html[data-theme="light"] .workspace-dashboard-row:hover {
  border-color: rgba(15, 142, 145, 0.28);
  background: #e2f2f4;
}

html[data-theme="light"] .workspace-today-actions .secondary-button,
html[data-theme="light"] .workspace-quick-actions .secondary-button,
html[data-theme="light"] .workspace-panel-head .ghost-button {
  border-color: rgba(15, 142, 145, 0.18);
  background: rgba(255, 255, 255, 0.72);
  color: #082535;
}

html[data-theme="light"] .top-therapist-identity {
  border-color: rgba(15, 142, 145, 0.26);
  background: linear-gradient(180deg, rgba(222, 239, 244, 0.96), rgba(202, 223, 232, 0.96));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72), 0 10px 24px rgba(31, 74, 92, 0.12);
}

html[data-theme="light"] .top-therapist-copy strong {
  color: #061d2d;
}

html[data-theme="light"] .top-therapist-media {
  border-color: rgba(15, 142, 145, 0.28);
  background: rgba(15, 142, 145, 0.14);
}

html[data-theme="light"] .top-therapist-media span {
  color: #08777b;
}

html[data-theme="light"] .autosave-pill.saved {
  border-color: rgba(22, 101, 52, 0.28);
  background: rgba(22, 163, 74, 0.1);
  color: #166534;
}

html[data-theme="light"] .autosave-pill.saving {
  border-color: rgba(15, 142, 145, 0.3);
  background: rgba(15, 142, 145, 0.1);
  color: #075e61;
}

html[data-theme="light"] .autosave-pill.error {
  border-color: rgba(185, 28, 28, 0.26);
  background: rgba(239, 68, 68, 0.1);
  color: #991b1b;
}

html[data-theme="light"] .workspace-quick-nav button,
html[data-theme="light"] .active-journey-tools .secondary-button.compact-button,
html[data-theme="light"] .active-journey-inline-shortcut,
html[data-theme="light"] .active-journey-status select,
html[data-theme="light"] .active-journey-tools .autosave-pill {
  border-color: rgba(8, 37, 53, 0.18);
  background: rgba(248, 252, 253, 0.72);
  color: #082535;
}

html[data-theme="light"] .workspace-quick-nav button:hover,
html[data-theme="light"] .active-journey-tools .secondary-button.compact-button:hover,
html[data-theme="light"] .active-journey-inline-shortcut:hover,
html[data-theme="light"] .active-journey-status select:hover {
  border-color: rgba(15, 142, 145, 0.34);
  background: rgba(15, 142, 145, 0.1);
}

.privacy-consent-box.pending {
  border-color: rgba(245, 158, 11, 0.58);
  background: rgba(245, 158, 11, 0.1);
}

.privacy-consent-box.accepted {
  border-color: rgba(94, 234, 212, 0.44);
}

.privacy-consent-status {
  font-weight: 800;
  text-transform: uppercase;
}

.workspace-badges,
.saas-plan-list,
.saas-tenant-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.workspace-badges span,
.saas-plan-pill,
.saas-tenant-pill {
  display: inline-flex;
  align-items: center;
  padding: 6px 9px;
  border: 1px solid rgba(94, 234, 212, 0.2);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--ink);
  font-size: 0.82rem;
  font-weight: 850;
}

.saas-plan-pill {
  gap: 5px;
  padding: 4px 7px;
  font-size: 0.72rem;
}

.saas-plan-pill strong {
  color: var(--text);
  font-size: 0.72rem;
  text-transform: uppercase;
}

.saas-plan-pill small {
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 750;
}

.legal-source-badges {
  margin-top: 8px;
}

.workspace-badges .legal-source-badge,
.legal-source-badge {
  border-color: rgba(94, 234, 212, 0.34);
  background: rgba(94, 234, 212, 0.08);
  color: #cffff8;
}

.legal-policy-check {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  padding: 10px;
  border: 1px solid rgba(94, 234, 212, 0.28);
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.055);
  color: var(--ink);
  font-weight: 800;
}

.legal-policy-check input {
  width: 18px;
  height: 18px;
  margin-top: 2px;
}

.legal-policy-note {
  margin: 0;
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.45;
}

.legal-policy-panel p {
  margin: 0;
  color: var(--muted);
}

.copyright-report-list {
  display: grid;
  gap: 10px;
  max-height: 420px;
  overflow: auto;
}

.copyright-report-card p {
  margin: 6px 0 0;
  color: var(--ink);
}

.legal-page {
  min-height: 100vh;
  padding: 32px;
  background: var(--bg-main);
  color: var(--ink);
}

.legal-shell {
  width: min(980px, 100%);
  margin: 0 auto;
  display: grid;
  gap: 18px;
}

.legal-header,
.legal-card {
  padding: 22px;
  border: 1px solid rgba(94, 234, 212, 0.22);
  border-radius: 8px;
  background: var(--bg-panel);
  box-shadow: 0 18px 38px rgba(0, 0, 0, 0.22);
}

.legal-header h1,
.legal-card h2,
.legal-card h3 {
  margin: 0 0 10px;
}

.legal-header p,
.legal-card p,
.legal-card li {
  color: var(--muted);
  line-height: 1.55;
}

.legal-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.legal-nav a,
.legal-card a {
  color: var(--accent);
}

.auth-legal-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px 16px;
  margin-top: 14px;
  font-size: 0.82rem;
  font-weight: 800;
}

.auth-legal-links a,
.terms-field a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.auth-legal-links .auth-legal-primary {
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.legal-form {
  display: grid;
  gap: 12px;
}

.legal-form label {
  display: grid;
  gap: 6px;
  color: var(--ink);
  font-weight: 850;
}

.legal-form input,
.legal-form select,
.legal-form textarea {
  width: 100%;
  border: 1px solid rgba(94, 234, 212, 0.22);
  border-radius: 8px;
  background: var(--bg-page);
  color: var(--ink);
  padding: 12px;
}

.legal-form textarea {
  min-height: 150px;
  resize: vertical;
}

.legal-status {
  min-height: 22px;
  color: var(--accent);
  font-weight: 850;
}

.admin-card {
  border-color: rgba(94, 234, 212, 0.2);
}

.admin-saas-overview {
  display: grid;
  gap: 12px;
}

.saas-section {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.saas-section h4 {
  margin: 0;
}

.saas-control-hero,
.saas-plans-strip {
  grid-template-columns: minmax(220px, 0.9fr) minmax(0, 1.4fr);
  align-items: center;
}

.saas-control-hero h4 {
  margin: 2px 0 6px;
  color: var(--text);
  font-size: 1.08rem;
}

.saas-control-hero span,
.saas-plans-strip > div:first-child span {
  color: var(--muted);
  line-height: 1.35;
}

.saas-stat-grid {
  grid-template-columns: repeat(4, minmax(110px, 1fr));
  gap: 8px;
  margin: 0;
}

.saas-stat-grid .admin-stat {
  min-height: 72px;
  padding: 10px;
}

.saas-stat-grid .admin-stat strong {
  font-size: 1.45rem;
}

.saas-stat-grid .admin-stat span {
  margin-top: 4px;
  font-size: 0.78rem;
}

.saas-plans-strip {
  gap: 10px;
  padding-block: 10px;
}

.saas-plans-strip h4 {
  color: var(--text);
}

.saas-tenant-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 10px;
}

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

.saas-tenant-card {
  display: grid;
  gap: 6px;
  padding: 12px;
  border: 1px solid rgba(124, 58, 237, 0.24);
  border-radius: 8px;
  background: rgba(124, 58, 237, 0.08);
}

.saas-tenant-card strong {
  color: var(--ink);
}

.saas-tenant-card span,
.saas-tenant-card small {
  color: var(--muted);
}

.saas-therapist-card {
  border: 1px solid rgba(94, 234, 212, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
  overflow: hidden;
}

.saas-therapist-card summary {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 9px 11px;
  cursor: pointer;
  list-style: none;
}

.saas-therapist-card[open] summary {
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
  background: rgba(94, 234, 212, 0.045);
}

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

.saas-therapist-summary {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.saas-therapist-summary strong {
  color: var(--ink);
  font-size: 0.98rem;
}

.saas-therapist-summary span,
.saas-therapist-summary small {
  color: var(--muted);
  overflow-wrap: anywhere;
}

.saas-summary-badges {
  justify-content: flex-end;
  gap: 5px;
}

.saas-summary-badges span {
  padding: 4px 7px;
  font-size: 0.7rem;
}

.saas-therapist-body {
  display: grid;
  gap: 8px;
  padding: 10px;
}

.saas-workspace-layout {
  display: grid;
  grid-template-columns: minmax(260px, 0.9fr) minmax(320px, 1.1fr);
  gap: 8px;
  align-items: start;
}

.saas-workspace-panel {
  display: grid;
  gap: 8px;
  align-content: start;
  padding: 9px;
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 8px;
  background: rgba(8, 13, 18, 0.16);
  min-width: 0;
}

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

.saas-panel-head h5 {
  margin: 0;
  color: var(--text);
  font-size: 0.88rem;
}

.saas-panel-head span {
  color: var(--muted);
  font-size: 0.7rem;
  line-height: 1.25;
  text-align: right;
}

.saas-field-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.saas-compact-field {
  display: grid;
  gap: 4px;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 850;
}

.saas-compact-field select {
  min-height: 31px;
  padding: 5px 8px;
  border-radius: 8px;
  font-size: 0.82rem;
}

.saas-meta-line {
  display: flex;
  flex-wrap: wrap;
  gap: 5px 10px;
  align-items: center;
  color: var(--muted);
  font-size: 0.7rem;
  line-height: 1.25;
}

.saas-meta-line span {
  overflow-wrap: anywhere;
}

.saas-meta-line strong {
  color: var(--text-soft);
  font-weight: 850;
}

.saas-meta-line .compact-button {
  min-height: 26px;
  padding: 4px 7px;
  font-size: 0.68rem;
}

.saas-profile-note {
  padding: 7px;
  border-radius: 8px;
}

.saas-limit-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.saas-limit-grid .tenant-override-option {
  gap: 4px;
  padding: 7px;
  border: 1px solid rgba(94, 234, 212, 0.12);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.03);
}

.saas-limit-grid input {
  min-height: 31px;
  padding: 5px 8px;
  border-radius: 8px;
  font-size: 0.82rem;
}

.saas-feature-panel {
  grid-column: 1 / -1;
  gap: 8px;
}

.saas-feature-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
}

.saas-feature-row {
  position: relative;
  display: grid;
  grid-template-columns: minmax(110px, 1fr) auto;
  gap: 6px;
  align-items: center;
  min-width: 0;
  padding: 6px 7px;
  border: 1px solid rgba(148, 163, 184, 0.12);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.028);
}

.tenant-feature-select-native {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.saas-feature-copy {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.saas-feature-copy strong {
  color: var(--text);
  font-size: 0.76rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.saas-feature-copy span {
  color: var(--muted);
  font-size: 0.66rem;
}

.saas-toggle-pills {
  display: inline-grid;
  grid-template-columns: repeat(3, auto);
  gap: 3px;
  padding: 3px;
  border: 1px solid rgba(94, 234, 212, 0.14);
  border-radius: 8px;
  background: rgba(3, 7, 18, 0.24);
}

.saas-toggle-pills label {
  cursor: pointer;
}

.saas-toggle-pills input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.saas-toggle-pills span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 31px;
  min-height: 22px;
  padding: 2px 6px;
  border-radius: 6px;
  color: var(--muted);
  font-size: 0.64rem;
  font-weight: 900;
}

.saas-toggle-pills input:checked + span {
  background: rgba(94, 234, 212, 0.16);
  color: #cffff8;
  box-shadow: inset 0 0 0 1px rgba(94, 234, 212, 0.34);
}

.saas-therapist-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
  align-items: center;
  padding-top: 2px;
}

.saas-therapist-actions .compact-button {
  min-height: var(--control-compact-height);
  min-width: 0;
}

.saas-action-utility {
  color: var(--muted);
  background: transparent;
  border-color: rgba(148, 163, 184, 0.22);
}

.saas-therapist-actions .primary-button {
  min-width: min(150px, 100%);
}

.saas-therapist-actions .secondary-button {
  min-width: min(124px, 100%);
}

html[data-theme="light"] .saas-section,
html[data-theme="light"] .saas-therapist-card,
html[data-theme="light"] .saas-workspace-panel {
  background: rgba(255, 255, 255, 0.78);
  border-color: rgba(9, 78, 99, 0.13);
}

html[data-theme="light"] .saas-therapist-card[open] summary {
  background: rgba(229, 246, 248, 0.72);
  border-color: rgba(9, 78, 99, 0.12);
}

html[data-theme="light"] .saas-feature-row,
html[data-theme="light"] .saas-limit-grid .tenant-override-option {
  background: rgba(248, 252, 253, 0.9);
  border-color: rgba(9, 78, 99, 0.12);
}

html[data-theme="light"] .saas-toggle-pills {
  background: rgba(226, 244, 246, 0.78);
  border-color: rgba(9, 78, 99, 0.13);
}

html[data-theme="light"] .saas-toggle-pills input:checked + span {
  background: rgba(15, 142, 145, 0.13);
  color: #0b5f66;
  box-shadow: inset 0 0 0 1px rgba(15, 142, 145, 0.28);
}

@media (max-width: 1180px) {
  .saas-control-hero,
  .saas-plans-strip,
  .saas-workspace-layout {
    grid-template-columns: 1fr;
  }

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

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

@media (max-width: 1040px) {
  .saas-feature-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .saas-therapist-card summary {
    grid-template-columns: 1fr;
  }

  .saas-summary-badges,
  .saas-therapist-actions {
    justify-content: flex-start;
  }

  .saas-therapist-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .saas-field-grid,
  .saas-limit-grid,
  .saas-feature-grid {
    grid-template-columns: 1fr;
  }

  .saas-feature-row {
    grid-template-columns: 1fr;
  }

  .saas-toggle-pills {
    width: 100%;
    grid-template-columns: repeat(3, 1fr);
  }

  .saas-therapist-actions .compact-button {
    width: 100%;
    min-width: 0;
    padding-inline: 8px;
    font-size: 0.78rem;
  }

  .saas-therapist-actions .primary-button {
    grid-column: 1 / -1;
  }

  .saas-panel-head {
    display: grid;
  }

  .saas-panel-head span {
    text-align: left;
  }
}

.workspace-360-modal-card {
  width: min(1180px, 100%);
}

.workspace-360-body {
  display: grid;
  gap: 14px;
}

.workspace-360-header,
.workspace-360-section {
  display: grid;
  gap: 12px;
  padding: 12px;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(6, 24, 38, 0.24);
}

.workspace-360-header {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
}

.workspace-360-header p {
  margin: 8px 0 0;
  color: var(--muted);
}

.workspace-360-title-row {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.workspace-360-title-row strong {
  display: block;
  color: var(--text);
  font-size: 1.05rem;
}

.workspace-360-title-row span {
  display: block;
  color: var(--muted);
  font-size: 0.84rem;
}

.workspace-360-logo {
  width: 46px;
  height: 46px;
  border: 1px solid rgba(94, 234, 212, 0.22);
  border-radius: 8px;
  object-fit: cover;
  background: rgba(255, 255, 255, 0.05);
}

.workspace-360-badges,
.workspace-360-section-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
}

.workspace-360-badges {
  justify-content: flex-end;
}

.workspace-360-health-summary {
  display: grid;
  gap: 2px;
  min-width: 190px;
  padding: 8px 10px;
  border: 1px solid rgba(94, 234, 212, 0.22);
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.08);
}

.workspace-360-health-summary span {
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
}

.workspace-360-health-summary strong {
  color: var(--text);
  font-size: 0.95rem;
}

.workspace-360-health-summary small {
  color: var(--muted);
  line-height: 1.25;
}

.workspace-360-health-summary.warning {
  border-color: rgba(251, 191, 36, 0.34);
  background: rgba(251, 191, 36, 0.08);
}

.workspace-360-health-summary.error {
  border-color: rgba(248, 113, 113, 0.36);
  background: rgba(248, 113, 113, 0.08);
}

.workspace-360-section-head h4 {
  margin: 0;
  color: var(--text);
}

.workspace-360-section-head span {
  color: var(--muted);
  font-size: 0.82rem;
}

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

.workspace-360-metric,
.workspace-360-usage {
  display: grid;
  gap: 7px;
  padding: 10px;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
  min-width: 0;
}

.workspace-360-metric.ok,
.workspace-360-usage.ok {
  border-color: rgba(74, 222, 128, 0.24);
}

.workspace-360-metric.warning,
.workspace-360-usage.warning {
  border-color: rgba(251, 191, 36, 0.32);
}

.workspace-360-metric.error,
.workspace-360-usage.error {
  border-color: rgba(248, 113, 113, 0.34);
}

.workspace-360-metric span,
.workspace-360-usage-head span {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 850;
}

.workspace-360-metric strong,
.workspace-360-usage-head strong {
  color: var(--text);
  overflow-wrap: anywhere;
}

.workspace-360-metric small,
.workspace-360-usage small {
  color: var(--muted);
  line-height: 1.35;
}

.workspace-360-usage-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.workspace-360-bar {
  width: 100%;
  height: 7px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.18);
}

.workspace-360-bar span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, rgba(94, 234, 212, 0.9), rgba(74, 222, 128, 0.84));
}

.workspace-360-usage.warning .workspace-360-bar span {
  background: linear-gradient(90deg, rgba(251, 191, 36, 0.9), rgba(245, 158, 11, 0.82));
}

.workspace-360-usage.error .workspace-360-bar span {
  background: linear-gradient(90deg, rgba(248, 113, 113, 0.92), rgba(239, 68, 68, 0.86));
}

.workspace-360-status-pills {
  align-items: center;
}

.workspace-360-status-pills strong {
  color: var(--text);
}

.workspace-360-billing-section {
  border-color: rgba(251, 191, 36, 0.22);
}

.workspace-360-billing-actions,
.workspace-360-warning-list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.workspace-360-billing-actions {
  padding-top: 2px;
}

.workspace-360-billing-actions span {
  color: var(--muted);
  font-size: 0.82rem;
}

.workspace-360-billing-actions.is-muted {
  opacity: 0.72;
}

.workspace-360-warning-row {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 5px 9px;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  color: var(--text-soft);
  background: rgba(255, 255, 255, 0.035);
  font-size: 0.8rem;
  font-weight: 850;
}

.workspace-360-warning-row.ok {
  border-color: rgba(74, 222, 128, 0.25);
  color: #bbf7d0;
}

.workspace-360-warning-row.warning {
  border-color: rgba(251, 191, 36, 0.36);
  color: #fde68a;
}

.workspace-360-warning-row.error {
  border-color: rgba(248, 113, 113, 0.42);
  color: #fecaca;
}

.workspace-360-audit-event {
  background: rgba(255, 255, 255, 0.03);
  gap: 8px;
}

.workspace-360-audit-meta {
  gap: 5px;
}

.workspace-360-audit-meta span {
  max-width: 220px;
  padding: 3px 7px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.72rem;
}

.workspace-360-operational-warnings {
  padding-top: 2px;
}

html[data-theme="light"] .workspace-360-header,
html[data-theme="light"] .workspace-360-section {
  background: rgba(255, 255, 255, 0.82);
  border-color: rgba(9, 78, 99, 0.14);
}

html[data-theme="light"] .workspace-360-metric,
html[data-theme="light"] .workspace-360-usage,
html[data-theme="light"] .workspace-360-health-summary {
  background: rgba(248, 252, 253, 0.9);
  border-color: rgba(9, 78, 99, 0.12);
}

html[data-theme="light"] .workspace-360-health-summary.warning {
  background: rgba(255, 251, 235, 0.95);
  border-color: rgba(146, 64, 14, 0.22);
}

html[data-theme="light"] .workspace-360-health-summary.error {
  background: rgba(254, 242, 242, 0.95);
  border-color: rgba(153, 27, 27, 0.22);
}

html[data-theme="light"] .workspace-360-bar {
  background: rgba(9, 78, 99, 0.12);
}

html[data-theme="light"] .workspace-360-warning-row {
  background: rgba(248, 252, 253, 0.92);
  border-color: rgba(9, 78, 99, 0.14);
  color: #315064;
}

html[data-theme="light"] .workspace-360-warning-row.ok {
  color: #166534;
}

html[data-theme="light"] .workspace-360-warning-row.warning {
  color: #92400e;
}

html[data-theme="light"] .workspace-360-warning-row.error {
  color: #991b1b;
}

.tenant-override-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.tenant-override-option {
  display: grid;
  gap: 6px;
}

.tenant-override-option span {
  color: var(--textSecondary);
  font-size: 0.82rem;
}

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

.admin-form-grid .wide-field {
  grid-column: 1 / -1;
}

.form-section-title {
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  margin: 2px 0 -2px;
  text-transform: uppercase;
}

.address-form-grid {
  align-items: start;
}

.practitioner-address-grid {
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
}

.address-form-grid .address-field-postal {
  max-width: 220px;
}

.address-form-grid .address-field-timezone {
  min-width: 0;
}

.admin-settings {
  display: grid;
  gap: 10px;
  margin-bottom: 12px;
}

.admin-settings label {
  display: grid;
  gap: 8px;
}

.admin-settings label:has(input[type="checkbox"]) {
  grid-template-columns: auto 1fr;
  align-items: center;
}

.admin-inline-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.knowledge-admin-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 14px;
  margin-top: 14px;
}

.knowledge-admin-card,
.knowledge-card {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.03);
}

.knowledge-card-list,
.knowledge-mini-list,
.admin-knowledge-overview {
  display: grid;
  gap: 12px;
}

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

.knowledge-card-head span,
.knowledge-card p,
.knowledge-rule-item span,
.knowledge-rule-item small {
  color: var(--muted);
}

.knowledge-rule-item {
  display: grid;
  gap: 8px;
  padding: 12px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.025);
}

.knowledge-rule-item.info {
  border-color: rgba(94, 234, 212, 0.22);
}

.knowledge-rule-item.medium {
  border-color: rgba(245, 158, 11, 0.35);
}

.knowledge-rule-item.high {
  border-color: rgba(239, 68, 68, 0.35);
}

.upgrade-hint-card {
  display: grid;
  gap: 4px;
  margin-top: 10px;
  padding: 10px 12px;
  border: 1px solid rgba(245, 158, 11, 0.28);
  border-radius: 8px;
  background: rgba(245, 158, 11, 0.08);
}

.upgrade-hint-card strong {
  color: var(--ink);
  font-size: 0.9rem;
}

.upgrade-hint-card span {
  color: var(--muted);
  font-size: 0.84rem;
}

.admin-settings input[type="checkbox"] {
  width: 16px;
  height: 16px;
  min-height: 0;
  margin: 0;
  accent-color: var(--accent);
}

.plan-matrix {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid rgba(94, 234, 212, 0.22);
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.06);
}

.plan-matrix > strong {
  color: var(--action);
}

.plan-matrix-grid {
  display: grid;
  grid-template-columns: minmax(190px, 1fr) repeat(3, 56px);
  gap: 0;
  align-items: center;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.plan-matrix-grid > span {
  color: var(--ink);
  font-size: 0.86rem;
  font-weight: 850;
}

.plan-matrix-grid > span,
.plan-matrix-grid label {
  min-height: 34px;
  padding: 6px 8px;
  border-right: 1px solid rgba(148, 163, 184, 0.12);
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
  border-radius: 0;
  background: rgba(255, 255, 255, 0.028);
}

.plan-matrix-grid > :nth-child(4n) {
  border-right: 0;
}

.plan-matrix-grid > :nth-child(-n + 4) {
  min-height: 30px;
  background: rgba(94, 234, 212, 0.12);
  color: var(--action);
  text-transform: uppercase;
  letter-spacing: 0;
  font-size: 0.78rem;
}

.plan-matrix-grid > :nth-child(8n + 5),
.plan-matrix-grid > :nth-child(8n + 6),
.plan-matrix-grid > :nth-child(8n + 7),
.plan-matrix-grid > :nth-child(8n + 8) {
  background: rgba(255, 255, 255, 0.04);
}

.plan-matrix-grid > :nth-child(8n + 9),
.plan-matrix-grid > :nth-child(8n + 10),
.plan-matrix-grid > :nth-child(8n + 11),
.plan-matrix-grid > :nth-child(8n + 12) {
  background: rgba(94, 234, 212, 0.045);
}

.plan-matrix-grid label {
  display: grid;
  place-items: center;
  cursor: pointer;
}

.plan-matrix-grid label:hover,
.plan-matrix-grid > span:hover {
  background: rgba(94, 234, 212, 0.09);
}

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

.admin-user-columns {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.admin-user-column {
  display: grid;
  align-content: start;
  gap: 10px;
}

.admin-user-column h4 {
  margin: 0;
  color: var(--text);
}

.admin-client-profile-list {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.admin-client-profile-list h5 {
  margin: 0;
  color: var(--muted);
  font-size: 0.82rem;
  text-transform: uppercase;
}

.admin-client-management {
  margin-top: 14px;
}

.admin-client-management h5 {
  margin: 0;
  color: var(--muted);
  font-size: 0.82rem;
  text-transform: uppercase;
}

.admin-user-search {
  display: grid;
  gap: 6px;
  margin-bottom: 12px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.admin-user-search input {
  min-height: 38px;
  font-size: 0.92rem;
  text-transform: none;
}

.admin-create-user-panel {
  display: grid;
  gap: 10px;
  margin-bottom: 14px;
  padding: 12px;
  border: 1px solid rgba(94, 234, 212, 0.22);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.admin-create-user-panel h4,
.admin-create-user-panel p {
  margin: 0;
}

.admin-create-user-panel p {
  color: var(--textSecondary);
}

.admin-search-note {
  margin: 0 0 10px;
  color: var(--action);
  font-weight: 800;
}

.admin-user-card {
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  overflow: hidden;
}

.admin-user-card[open] {
  border-color: rgba(94, 234, 212, 0.42);
}

.admin-user-card.summary-deleted,
.admin-user-card.summary-suspended {
  border-color: rgba(239, 68, 68, 0.35);
}

.admin-user-card summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  cursor: pointer;
}

.admin-user-summary {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.admin-user-summary strong,
.admin-user-summary span,
.admin-user-summary small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-user-summary span,
.admin-user-summary small {
  color: var(--muted);
}

.admin-user-body {
  display: grid;
  gap: 12px;
  padding: 0 12px 12px;
}

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

.account-status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 4px 8px;
  border: 1px solid rgba(94, 234, 212, 0.22);
  border-radius: 8px;
  color: var(--aqua);
  background: rgba(94, 234, 212, 0.08);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

.account-status-pill.suspended,
.account-status-pill.deleted,
.account-status-pill.inactive,
.account-status-pill.archived {
  border-color: rgba(239, 68, 68, 0.32);
  color: #fecaca;
  background: var(--danger-soft);
}

.admin-list-item {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
}

.admin-list-item span,
.admin-list-item small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
}

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

.admin-item-actions a,
.admin-item-actions button {
  min-height: 34px;
  padding: 7px 10px;
  font-size: 0.82rem;
}

.error-report {
  border-color: rgba(239, 68, 68, 0.32);
}

.layer-search {
  display: grid;
  grid-template-columns: minmax(180px, 260px) auto;
  gap: 10px;
  align-items: end;
  margin-bottom: 12px;
}

.layer-search label {
  margin: 0;
}

.free-source {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 9px 12px;
  border: 1px solid #8cc8b1;
  border-radius: 8px;
  font-weight: 850;
  text-decoration: none;
}

.track-box {
  display: grid;
  gap: 7px;
  grid-column: 2;
  align-content: start;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
}

.compact-button {
  min-height: var(--control-compact-height);
  padding: 7px var(--control-compact-padding-x);
  font-size: 0.82rem;
  line-height: 1.1;
}

.diary-board,
.profile-board {
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

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

.empty-diary {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
  color: var(--muted);
  font-weight: 850;
}

.sound-select.is-disabled,
.player-panel button:disabled,
.service-item button:disabled {
  opacity: 0.6;
}

.diary-state {
  padding: 14px;
  border: 1px solid var(--line);
  border-left: 8px solid var(--navy);
  border-radius: 8px;
  background: var(--bg-panel);
  content-visibility: auto;
  contain-intrinsic-size: 260px;
}

.diary-state header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.diary-state h3 {
  margin-bottom: 0;
}

.diary-state-return {
  min-height: auto;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--ink);
  font-size: 1.05rem;
  font-weight: 950;
  text-align: left;
}

.diary-state-return:hover {
  color: var(--action-dark);
  text-decoration: underline;
}

.diary-state header > span {
  padding: 7px 9px;
  border-radius: 8px;
  background: var(--navy-soft);
  color: var(--navy);
  font-size: 0.82rem;
  font-weight: 950;
}

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

.diary-duration-summary,
.manual-diary-box {
  margin-bottom: 10px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 850;
  line-height: 1.4;
}

.diary-duration-summary.ok {
  border-color: rgba(34, 197, 94, 0.45);
  background: var(--success-soft);
  color: #86efac;
}

.diary-duration-summary.error {
  border-color: rgba(239, 68, 68, 0.5);
  background: var(--danger-soft);
  color: #fca5a5;
}

.diary-duration-summary.warning {
  border-color: rgba(245, 158, 11, 0.5);
  background: var(--gold-soft);
  color: #fbbf24;
}

.manual-diary-box {
  display: grid;
  gap: 8px;
  margin: 12px 0 0;
  border-color: rgba(245, 158, 11, 0.4);
  background: rgba(245, 158, 11, 0.1);
}

.manual-diary-box > strong {
  color: #fbbf24;
}

.diary-entry {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
}

.diary-entry.ok {
  border-color: rgba(34, 197, 94, 0.45);
  background: var(--success-soft);
}

.diary-entry.warning,
.diary-entry.unknown {
  border-color: #e3bd5b;
  background: var(--gold-soft);
}

.diary-entry.error {
  border-color: rgba(239, 68, 68, 0.5);
  background: var(--danger-soft);
}

.diary-entry-main {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.diary-entry-main strong,
.diary-entry-main span,
.diary-entry-main small,
.diary-entry-main em {
  overflow-wrap: anywhere;
}

.diary-entry-main span,
.diary-entry-main small,
.diary-entry-main em {
  color: var(--muted);
  font-size: 0.82rem;
  font-style: normal;
}

.diary-entry-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  justify-content: flex-end;
}

.diary-entry-actions a,
.diary-entry-actions button {
  min-height: 34px;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #0f151d;
  color: var(--ink);
  font-size: 0.82rem;
  font-weight: 850;
  text-decoration: none;
}

.profile-grid {
  display: grid;
  grid-template-columns: minmax(260px, 0.9fr) minmax(320px, 1.4fr);
  gap: 14px;
  align-items: start;
}

.profile-shell {
  display: grid;
  grid-template-columns: minmax(190px, 230px) minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

body:not(.profile-workspace-route) #profileMode .profile-shell {
  grid-template-columns: minmax(0, 1fr);
}

body:not(.profile-workspace-route) #profileMode .profile-side-nav {
  display: none;
}

.profile-side-nav {
  position: sticky;
  top: 92px;
  display: grid;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

html[data-theme="light"] .profile-side-nav {
  background: #ffffff;
}

.profile-side-nav-section {
  border-bottom: 1px solid var(--line);
  display: grid;
  gap: 4px;
  padding-bottom: 10px;
}

.profile-side-nav-section:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.profile-side-nav-section > span {
  color: var(--accent);
  font-size: 0.7rem;
  font-weight: 950;
  letter-spacing: 0.11em;
  opacity: 0.86;
  padding: 4px 8px 6px;
  text-transform: uppercase;
}

.profile-nav-button {
  align-items: center;
  border: 1px solid transparent;
  border-radius: 8px;
  display: flex;
  font-size: 0.9rem;
  font-weight: 850;
  gap: 9px;
  justify-content: flex-start;
  width: 100%;
  min-height: 36px;
  padding: 8px 10px;
  text-align: left;
  background: transparent;
  color: var(--text-secondary);
}

.profile-nav-button.active {
  border-color: rgba(79, 209, 197, 0.28);
  background: rgba(79, 209, 197, 0.12);
  color: var(--accent);
}

.profile-nav-icon {
  align-items: center;
  color: currentColor;
  display: inline-flex;
  flex: 0 0 22px;
  font-size: 0.95rem;
  justify-content: center;
  opacity: 0.82;
}

.account-status {
  margin: 0;
  padding: 9px 10px;
  border: 1px solid rgba(245, 158, 11, 0.42);
  border-radius: 8px;
  background: rgba(245, 158, 11, 0.1);
  color: #fbbf24;
  font-size: 0.86rem;
  font-weight: 850;
}

.compact-email-status {
  align-items: center;
  align-self: stretch;
  display: inline-flex;
  font-size: 0.78rem;
  justify-content: center;
  margin: 0;
  min-height: 0;
  padding: 0 10px;
  white-space: nowrap;
}

.account-status.verified {
  border-color: rgba(34, 197, 94, 0.42);
  background: rgba(34, 197, 94, 0.1);
  color: #86efac;
}

.profile-content {
  min-width: 0;
}

.profile-content-wide {
  display: grid;
  gap: 16px;
}

.profile-save-row {
  border-top: 1px solid var(--line);
  margin-top: 4px;
  padding-top: 14px;
}

.profile-save-row .primary-button {
  width: min(100%, 240px);
}

.profile-card {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
}

.profile-card.facilitator-view {
  display: none;
}

.profile-card.facilitator-view.active {
  display: grid;
}

.profile-card.client-view {
  display: none;
}

.profile-card.client-view.active {
  display: grid;
}

.profile-card.profile-section,
.profile-card.admin-section {
  display: none;
}

.profile-card.profile-section.active,
.profile-card.admin-section.active {
  display: grid;
}

.service-card,
.history-card {
  grid-row: span 2;
}

.service-list,
.history-list {
  display: grid;
  gap: 10px;
}

.history-section-title {
  margin-top: 6px;
  color: var(--navy);
  font-size: 0.78rem;
  font-weight: 950;
  text-transform: uppercase;
}

.service-item {
  display: grid;
  grid-template-columns: 46px 1fr;
  gap: 10px;
  padding: 12px;
  border: 1px solid rgba(94, 234, 212, 0.2);
  border-radius: 8px;
  background: linear-gradient(135deg, rgba(26, 35, 48, 0.95), rgba(18, 24, 33, 0.98));
}

.service-icon {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.13);
  color: var(--action);
  font-size: 1.3rem;
}

.service-item strong,
.service-item span,
.service-item button {
  display: block;
}

.service-item span {
  margin: 4px 0;
  color: var(--action);
  font-weight: 950;
}

.service-item p {
  margin-bottom: 8px;
  color: var(--muted);
  line-height: 1.42;
}

.service-item button {
  width: fit-content;
  min-height: 34px;
  padding: 7px 10px;
  border: 1px solid rgba(94, 234, 212, 0.45);
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.16);
  color: var(--bg-page);
  color: var(--action);
  font-size: 0.84rem;
  font-weight: 850;
}

.admin-review-editor {
  display: grid;
  gap: 10px;
  min-width: 0;
  width: 100%;
}

.admin-marker-form {
  display: grid;
  grid-template-columns: minmax(110px, 0.55fr) minmax(180px, 1fr) minmax(220px, 0.7fr);
  gap: 8px;
}

.marker-edit-context {
  grid-column: 1 / -1;
  width: fit-content;
  margin: 0;
  padding: 6px 9px;
  border: 1px solid rgba(245, 158, 11, 0.44);
  border-radius: 8px;
  background: rgba(245, 158, 11, 0.12);
  color: #fde68a;
  font-size: 0.78rem;
  font-weight: 950;
  letter-spacing: 0;
  text-transform: uppercase;
}

.marker-edit-context[hidden] {
  display: none !important;
}

.admin-marker-form select[data-marker-color] {
  min-width: 220px;
  padding-right: 34px;
  border-color: rgba(245, 158, 11, 0.34);
  background:
    linear-gradient(180deg, rgba(245, 158, 11, 0.12), rgba(15, 21, 29, 0.98)),
    #0f151d;
  color: var(--text-primary);
  font-weight: 850;
}

html[data-theme="light"] .review-admin-card {
  border-color: rgba(15, 142, 145, 0.2);
  background:
    linear-gradient(180deg, rgba(248, 252, 253, 0.98), rgba(231, 243, 246, 0.94)),
    #f8fcfd;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.76),
    0 16px 40px rgba(31, 74, 92, 0.08);
}

html[data-theme="light"] .review-admin-card.is-review-locked {
  border-color: rgba(15, 142, 145, 0.22);
  background:
    linear-gradient(180deg, rgba(243, 250, 251, 0.98), rgba(222, 238, 243, 0.94)),
    #eef7f9;
}

html[data-theme="light"] .review-admin-card.is-review-locked .review-lock-note {
  border-color: rgba(15, 142, 145, 0.24);
  background: rgba(15, 142, 145, 0.08);
  color: #31586b;
}

html[data-theme="light"] .review-admin-card select:disabled,
html[data-theme="light"] .review-admin-card input:disabled,
html[data-theme="light"] .review-admin-card textarea:disabled {
  border-color: rgba(8, 37, 53, 0.16);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(240, 247, 249, 0.92)),
    #ffffff;
  color: #082535;
  opacity: 1;
  -webkit-text-fill-color: #082535;
}

html[data-theme="light"] .review-admin-card button:disabled {
  border-color: rgba(15, 142, 145, 0.18);
  background: rgba(15, 142, 145, 0.07);
  color: #456779;
  opacity: 1;
  -webkit-text-fill-color: #456779;
}

html[data-theme="light"] .admin-marker-form select[data-marker-color] {
  border-color: rgba(162, 101, 7, 0.34);
  background:
    linear-gradient(180deg, rgba(255, 251, 235, 0.96), rgba(255, 247, 224, 0.92)),
    #fffbeb;
  color: #432818;
  box-shadow: inset 0 0 0 1px rgba(162, 101, 7, 0.04);
}

html[data-theme="light"] .marker-edit-context {
  border-color: rgba(162, 101, 7, 0.32);
  background: rgba(245, 158, 11, 0.11);
  color: #8a4b05;
}

.admin-marker-form .marker-note-input,
.admin-marker-form button {
  grid-column: 1 / -1;
}

.review-admin-card {
  display: grid;
  gap: 14px;
  padding: 14px;
  border: 1px solid rgba(94, 234, 212, 0.2);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
}

.review-admin-card.is-review-locked {
  border-color: rgba(148, 163, 184, 0.34);
  background: rgba(15, 23, 42, 0.34);
}

.review-lock-note {
  width: fit-content;
  margin: 0;
  padding: 8px 10px;
  border: 1px solid rgba(148, 163, 184, 0.34);
  border-radius: 8px;
  background: rgba(148, 163, 184, 0.12);
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 900;
}

.review-admin-summary {
  display: grid;
  grid-template-columns: minmax(140px, 1fr) minmax(180px, 1.4fr) auto auto 20px;
  gap: 10px;
  align-items: center;
  cursor: pointer;
  list-style: none;
}

.review-admin-summary::-webkit-details-marker {
  display: none;
}

.review-admin-summary::after {
  content: "+";
  color: var(--action);
  font-weight: 950;
}

.review-admin-card[open] .review-admin-summary::after {
  content: "-";
}

.review-admin-header,
.review-status-row,
.review-admin-actions,
.review-audio-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
}

.review-status-row label {
  min-width: 180px;
  flex: 1;
}

.review-status-row.review-status-row-compact {
  display: grid;
  grid-template-columns: minmax(140px, 190px) minmax(110px, 130px) minmax(90px, 110px);
  justify-content: start;
  align-items: end;
}

.review-status-row.review-status-row-compact label {
  min-width: 0;
  flex: none;
}

.review-status-row.review-status-row-compact select,
.review-status-row.review-status-row-compact input {
  min-height: 42px;
  padding-top: 8px;
  padding-bottom: 8px;
}

.review-audio-workspace {
  display: grid;
  gap: 10px;
  min-width: 0;
}

.review-landscape-hint {
  display: none;
  margin: 0;
  padding: 8px 10px;
  border: 1px solid rgba(79, 209, 197, 0.28);
  border-radius: 8px;
  background: rgba(79, 209, 197, 0.1);
  color: var(--text-soft);
  font-size: 0.82rem;
  font-weight: 850;
  line-height: 1.35;
}

.review-audio {
  width: 100%;
}

.native-review-audio {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0.01;
  pointer-events: none;
}

.review-audio-hint,
.review-audio-error {
  display: block;
  color: var(--text-secondary);
  font-size: 0.86rem;
  line-height: 1.45;
}

.review-audio-error {
  color: #fecaca;
  border: 1px solid rgba(239, 68, 68, 0.42);
  border-radius: 8px;
  padding: 9px 10px;
  background: rgba(239, 68, 68, 0.12);
}

html[data-theme="light"] .review-audio-hint {
  color: #456779;
}

html[data-theme="light"] .review-audio-error {
  border-color: rgba(185, 28, 28, 0.34);
  background: #fff1f2;
  color: #991b1b;
}

.review-create-status {
  grid-column: 1 / -1;
  padding: 10px 12px;
  border: 1px solid rgba(79, 209, 197, 0.26);
  border-radius: 8px;
  background: rgba(79, 209, 197, 0.1);
  color: var(--text-soft);
  font-size: 0.9rem;
  font-weight: 800;
}

.review-create-status.error {
  border-color: rgba(239, 68, 68, 0.42);
  background: rgba(239, 68, 68, 0.14);
  color: #fecaca;
}

html[data-theme="light"] .review-create-status {
  border-color: rgba(15, 142, 145, 0.18);
  background: rgba(15, 142, 145, 0.07);
  color: #31586b;
}

html[data-theme="light"] .review-create-status.error {
  border-color: rgba(185, 28, 28, 0.34);
  background: #fff1f2;
  color: #991b1b;
}

button.is-loading {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: wait;
  opacity: 0.88;
}

.button-spinner {
  width: 16px;
  height: 16px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 999px;
  animation: buttonSpinner 720ms linear infinite;
}

@keyframes buttonSpinner {
  to {
    transform: rotate(360deg);
  }
}

.expanding-textarea {
  min-height: 190px;
  overflow: hidden;
}

.marker-note-input {
  min-height: 120px;
}

.admin-marker-inspector {
  display: grid;
  gap: 8px;
  padding: 10px;
  border: 1px solid rgba(94, 234, 212, 0.22);
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.06);
}

html[data-theme="light"] .admin-marker-inspector {
  border-color: rgba(15, 142, 145, 0.16);
  background: rgba(220, 244, 245, 0.64);
  color: #082535;
}

.admin-marker-detail-list {
  display: grid;
  gap: 8px;
}

.admin-marker-detail {
  display: grid;
  gap: 4px;
  width: 100%;
  min-height: 0;
  padding: 10px;
  text-align: left;
  border-left-width: 4px;
  background: rgba(255, 255, 255, 0.045);
}

html[data-theme="light"] .admin-marker-detail,
html[data-theme="light"] .review-marker-list article,
html[data-theme="light"] .review-marker-list .marker-text {
  border-color: rgba(8, 37, 53, 0.13);
  background: rgba(255, 255, 255, 0.76);
  color: #082535;
}

.admin-marker-detail.green {
  border-left-color: var(--success);
}

.admin-marker-detail.orange {
  border-left-color: var(--coral);
}

.admin-marker-detail.red {
  border-left-color: var(--danger);
}

.admin-marker-detail small {
  color: var(--muted);
  line-height: 1.35;
}

.admin-marker-detail.selected {
  border-color: var(--action);
  box-shadow: inset 4px 0 0 var(--action);
}

html[data-theme="light"] .admin-marker-detail.selected,
html[data-theme="light"] .marker-text.selected {
  border-color: rgba(15, 142, 145, 0.45);
  background: rgba(15, 142, 145, 0.08);
  box-shadow: inset 4px 0 0 #0f8e91;
}

.marker-edit-menu {
  position: fixed;
  z-index: 90;
  display: grid;
  gap: 6px;
  padding: 6px;
  border: 1px solid rgba(94, 234, 212, 0.34);
  border-radius: 8px;
  background: var(--bg-panel);
  box-shadow: var(--shadow);
}

html[data-theme="light"] .marker-edit-menu,
html[data-theme="light"] .marker-cluster-menu {
  border-color: rgba(15, 142, 145, 0.24);
  background: rgba(248, 252, 253, 0.98);
  box-shadow: 0 18px 44px rgba(31, 74, 92, 0.18);
}

.marker-edit-menu strong {
  padding: 2px 4px;
  color: var(--text-primary);
  font-size: 0.74rem;
  letter-spacing: 0;
}

.marker-edit-menu button {
  min-height: 34px;
  padding: 7px 10px;
  background: rgba(94, 234, 212, 0.14);
  color: var(--action);
}

.marker-edit-menu .danger-button {
  border-color: rgba(239, 68, 68, 0.5);
  background: rgba(239, 68, 68, 0.14);
  color: #fecaca;
}

html[data-theme="light"] .marker-edit-menu .danger-button {
  border-color: rgba(185, 28, 28, 0.34);
  background: #fee2e2;
  color: #991b1b;
}

.timeline-marker.marker-editing {
  outline: 3px solid rgba(94, 234, 212, 0.65);
  cursor: grabbing;
}

.clarification-admin-box,
.clarification-marker-list {
  display: grid;
  gap: 8px;
  padding: 10px;
  border: 1px solid rgba(245, 158, 11, 0.26);
  border-radius: 8px;
  background: rgba(245, 158, 11, 0.08);
}

.clarification-admin-box article {
  display: grid;
  gap: 8px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
}

.clarification-admin-box p {
  margin: 6px 0 0;
}

.clarification-answer {
  padding: 8px;
  border-left: 4px solid var(--success);
  border-radius: 8px;
  background: rgba(34, 197, 94, 0.1);
}

.clarification-answer-input {
  min-height: 90px;
}

.clarification-marker-option {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 8px;
  align-items: center;
}

.help-board {
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 140;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(0, 0, 0, 0.72);
}

.modal-card {
  position: relative;
  display: grid;
  gap: 12px;
  width: min(760px, 100%);
  max-height: min(860px, calc(100vh - 36px));
  overflow: auto;
  padding: 22px;
  border: 1px solid rgba(94, 234, 212, 0.26);
  border-radius: 8px;
  background: var(--bg-workspace);
  box-shadow: var(--shadow);
}

.review-modal-card {
  width: min(1180px, 100%);
}

.app-confirm-overlay {
  z-index: 150;
}

.app-confirm-card {
  width: min(560px, 100%);
  border-color: rgba(245, 158, 11, 0.42);
  background:
    linear-gradient(135deg, rgba(23, 62, 85, 0.96), rgba(18, 24, 33, 0.98));
}

.app-confirm-card p {
  color: var(--text-soft);
}

html[data-theme="light"] .app-confirm-card {
  border-color: rgba(245, 158, 11, 0.42);
  background:
    linear-gradient(135deg, #ffffff, #e8f4f7);
  box-shadow: 0 24px 60px rgba(31, 74, 92, 0.18);
}

html[data-theme="light"] .app-confirm-card h1,
html[data-theme="light"] .app-confirm-card h2,
html[data-theme="light"] .app-confirm-card h3 {
  color: var(--text-primary);
}

html[data-theme="light"] .app-confirm-card p {
  color: var(--text-secondary);
}

.app-confirm-actions {
  align-items: center;
  justify-content: flex-end;
  padding-top: 4px;
}

.app-confirm-actions button {
  min-width: 150px;
}

.plan-modal-card {
  width: min(1080px, 100%);
}

.modal-close {
  position: absolute;
  top: 10px;
  right: 10px;
  display: grid;
  place-items: center;
  width: 38px;
  min-width: 38px;
  height: 38px;
  padding: 0;
}

.review-request-list,
.review-timeline,
.review-marker-list {
  display: grid;
  gap: 10px;
}

.review-waveform-player {
  display: grid;
  grid-template-columns: auto minmax(70px, auto) auto minmax(150px, 1fr);
  gap: 8px;
  align-items: center;
  padding: 8px;
  border: 1px solid rgba(79, 209, 197, 0.24);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(19, 52, 71, 0.72), rgba(8, 18, 26, 0.5)),
    rgba(8, 18, 26, 0.48);
}

html[data-theme="light"] .review-waveform-player {
  border-color: rgba(15, 142, 145, 0.2);
  background:
    linear-gradient(180deg, rgba(230, 245, 248, 0.98), rgba(204, 229, 236, 0.92)),
    #e8f4f7;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.68);
}

.review-waveform-play {
  min-height: 38px;
  padding: 8px 12px;
  border-color: rgba(79, 209, 197, 0.62);
  background: rgba(79, 209, 197, 0.14);
  color: var(--text-primary);
}

html[data-theme="light"] .review-waveform-play {
  border-color: rgba(15, 142, 145, 0.42);
  background: rgba(15, 142, 145, 0.12);
  color: #082535;
}

html[data-theme="light"] .review-waveform-play:hover,
html[data-theme="light"] .review-waveform-play:focus-visible {
  border-color: rgba(15, 142, 145, 0.68);
  background: rgba(15, 142, 145, 0.16);
}

.review-waveform-marker-button {
  min-height: 38px;
  padding: 8px 12px;
  border-color: rgba(245, 158, 11, 0.58);
  background: rgba(245, 158, 11, 0.12);
  color: var(--text-primary);
}

html[data-theme="light"] .review-waveform-marker-button {
  border-color: rgba(162, 101, 7, 0.38);
  background: rgba(245, 158, 11, 0.12);
  color: #432818;
}

.review-waveform-marker-button:hover,
.review-waveform-marker-button:focus-visible {
  background: rgba(245, 158, 11, 0.22);
  color: var(--text-primary);
}

.review-waveform-play.is-playing {
  border-color: rgba(245, 158, 11, 0.72);
  background: rgba(245, 158, 11, 0.16);
}

html[data-theme="light"] .review-waveform-play.is-playing {
  border-color: rgba(162, 101, 7, 0.5);
  background: rgba(245, 158, 11, 0.15);
}

.review-waveform-play-icon {
  display: inline-grid;
  place-items: center;
  width: 18px;
  margin-right: 6px;
  color: var(--accent);
}

.review-waveform-clock {
  min-width: 74px;
  padding: 7px 10px;
  border: 1px solid rgba(79, 209, 197, 0.38);
  border-radius: 8px;
  background: rgba(8, 18, 26, 0.7);
  color: var(--text-primary);
  font-weight: 900;
  text-align: center;
  font-variant-numeric: tabular-nums;
}

html[data-theme="light"] .review-waveform-clock {
  border-color: rgba(15, 142, 145, 0.2);
  background: rgba(255, 255, 255, 0.92);
  color: #082535;
}

.review-waveform-duration {
  justify-self: end;
  padding: 7px 9px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
  color: var(--text-secondary);
  font-size: 0.82rem;
  font-weight: 850;
  font-variant-numeric: tabular-nums;
}

html[data-theme="light"] .review-waveform-duration {
  border-color: rgba(15, 142, 145, 0.16);
  background: rgba(255, 255, 255, 0.82);
  color: #31586b;
}

.review-card {
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid rgba(94, 234, 212, 0.2);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
}

.review-status {
  width: fit-content;
  padding: 4px 8px;
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.12);
  color: var(--action);
  font-size: 0.82rem;
  font-weight: 950;
}

html[data-theme="light"] .review-status {
  background: rgba(15, 142, 145, 0.09);
  color: #0b6f73;
}

.timeline-rail {
  position: relative;
  min-height: 58px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: linear-gradient(90deg, rgba(94, 234, 212, 0.16), rgba(124, 58, 237, 0.16), rgba(245, 158, 11, 0.16));
}

html[data-theme="light"] .timeline-rail {
  border-color: rgba(15, 142, 145, 0.24);
  background:
    linear-gradient(90deg, rgba(15, 142, 145, 0.18), rgba(124, 58, 237, 0.16), rgba(245, 158, 11, 0.16)),
    rgba(248, 252, 253, 0.86);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.66),
    inset 0 0 0 1px rgba(255, 255, 255, 0.36);
}

.waveform-rail {
  display: flex;
  align-items: center;
  min-height: 142px;
  padding: 12px;
  overflow: visible;
  cursor: ew-resize;
  user-select: none;
  touch-action: none;
}

.waveform-rail.is-dragging {
  border-color: rgba(245, 158, 11, 0.72);
  box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.18);
}

.waveform-rail.is-marker-target {
  border-color: rgba(79, 209, 197, 0.82);
  box-shadow: 0 0 0 3px rgba(79, 209, 197, 0.2);
}

.waveform-bars {
  display: flex;
  align-items: center;
  gap: 3px;
  width: 100%;
  height: 70px;
  pointer-events: none;
}

.waveform-bars span {
  flex: 1;
  min-width: 2px;
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.45);
}

html[data-theme="light"] .waveform-bars span {
  background: rgba(20, 184, 166, 0.36);
  box-shadow: 0 0 0 1px rgba(20, 184, 166, 0.04);
}

.timeline-cursor {
  position: absolute;
  top: 8px;
  bottom: 8px;
  width: 2px;
  background: #e6edf3;
  box-shadow: 0 0 0 3px rgba(230, 237, 243, 0.16);
  pointer-events: none;
}

html[data-theme="light"] .timeline-cursor {
  background: #082535;
  box-shadow: 0 0 0 3px rgba(8, 37, 53, 0.1);
}

.timeline-marker {
  position: absolute;
  top: calc(12px + (var(--marker-lane, 0) * 13px));
  width: 9px;
  height: 48px;
  border: 2px solid var(--bg-page);
  border-radius: 8px;
  background: var(--coral);
  transform: translateX(-50%);
  cursor: pointer;
  transition: top 140ms ease, transform 140ms ease, box-shadow 140ms ease;
}

html[data-theme="light"] .timeline-marker {
  border-color: #f8fcfd;
  box-shadow: 0 6px 14px rgba(31, 74, 92, 0.14);
}

.timeline-marker::before {
  content: "";
  position: absolute;
  inset: -8px -9px;
}

.timeline-marker.green {
  background: var(--success);
}

.timeline-marker.orange {
  background: var(--coral);
}

.timeline-marker.red {
  background: var(--danger);
}

.timeline-marker-number {
  position: absolute;
  top: -9px;
  left: 50%;
  display: inline-grid;
  place-items: center;
  min-width: 18px;
  height: 18px;
  padding: 0 4px;
  border: 1px solid rgba(230, 237, 243, 0.56);
  border-radius: 999px;
  background: var(--bg-page);
  color: var(--text-primary);
  font-size: 0.62rem;
  font-weight: 950;
  line-height: 1;
  transform: translateX(-50%);
  pointer-events: none;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.32);
}

html[data-theme="light"] .timeline-marker-number {
  border-color: rgba(8, 37, 53, 0.14);
  background: #f8fcfd;
  color: #082535;
  box-shadow: 0 5px 12px rgba(31, 74, 92, 0.16);
}

.admin-marker-form.marker-form-editing {
  border-color: rgba(245, 158, 11, 0.58);
  box-shadow: inset 4px 0 0 rgba(245, 158, 11, 0.62);
}

.timeline-marker span {
  position: absolute;
  top: -32px;
  left: 50%;
  max-width: 118px;
  padding: 3px 6px;
  border-radius: 8px;
  background: rgba(11, 15, 20, 0.92);
  color: var(--ink);
  font-size: 0.66rem;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  transform: translateX(-50%);
  opacity: 0;
  z-index: 4;
}

html[data-theme="light"] .timeline-marker span {
  background: rgba(248, 252, 253, 0.96);
  color: #082535;
  border: 1px solid rgba(8, 37, 53, 0.12);
  box-shadow: 0 8px 18px rgba(31, 74, 92, 0.14);
}

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

.history-card .lead {
  margin-bottom: 14px;
}

.history-groups,
.plan-groups {
  display: grid;
  gap: 12px;
}

.history-group,
.plan-group {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid rgba(94, 234, 212, 0.16);
  border-left-width: 5px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.03);
}

.plan-group.plan-phase-1 {
  border-color: rgba(94, 234, 212, 0.34);
  background: rgba(94, 234, 212, 0.055);
}

.plan-group.plan-phase-2 {
  border-color: rgba(125, 211, 252, 0.34);
  background: rgba(125, 211, 252, 0.055);
}

.plan-group.plan-phase-3 {
  border-color: rgba(167, 139, 250, 0.34);
  background: rgba(167, 139, 250, 0.055);
}

.plan-group.plan-phase-4 {
  border-color: rgba(250, 204, 21, 0.34);
  background: rgba(250, 204, 21, 0.052);
}

.plan-group.plan-phase-5 {
  border-color: rgba(45, 212, 191, 0.34);
  background: rgba(45, 212, 191, 0.052);
}

.plan-group.plan-phase-6 {
  border-color: rgba(248, 113, 113, 0.3);
  background: rgba(248, 113, 113, 0.045);
}

.history-group-header,
.plan-group-header {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px 12px;
}

.history-group-meta,
.plan-group-meta {
  color: var(--muted);
  font-size: 0.82rem;
}

.history-group-list,
.plan-step-list {
  display: grid;
  gap: 8px;
}

.danger-button {
  margin-inline-start: auto;
  border-color: rgba(239, 68, 68, 0.5);
  background: var(--danger-soft);
  color: #fecaca;
}

.danger-zone {
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid rgba(239, 68, 68, 0.3);
  border-radius: 8px;
  background: rgba(239, 68, 68, 0.09);
}

.danger-zone strong {
  color: #fecaca;
}

.danger-zone span {
  color: var(--muted);
}

html[data-theme="light"] .danger-zone {
  border-color: rgba(185, 28, 28, 0.28);
  background: #fff1f2;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
}

html[data-theme="light"] .danger-zone strong {
  color: #991b1b;
}

html[data-theme="light"] .danger-zone span {
  color: #5f2a31;
}

html[data-theme="light"] .danger-button {
  border-color: rgba(185, 28, 28, 0.46);
  background: #fee2e2;
  color: #991b1b;
}

html[data-theme="light"] .danger-button:hover {
  border-color: #b91c1c;
  background: #fecaca;
  color: #7f1d1d;
}

.checkbox-line {
  display: flex;
  align-items: center;
  gap: 8px;
}

@media (max-width: 900px) {
  .admin-user-columns,
  .admin-user-controls {
    grid-template-columns: 1fr;
  }
}

.timeline-marker:hover span,
.timeline-marker:focus span,
.timeline-marker.selected span {
  opacity: 1;
}

.timeline-marker:hover,
.timeline-marker:focus,
.timeline-marker.selected {
  transform: translateX(-50%) scale(1.08);
  z-index: 80 !important;
}

.marker-cluster-menu {
  position: fixed;
  z-index: 180;
  display: grid;
  gap: 5px;
  min-width: 0;
  max-width: min(190px, calc(100vw - 20px));
  padding: 6px;
  border: 1px solid rgba(94, 234, 212, 0.42);
  border-radius: 8px;
  background: rgba(11, 15, 20, 0.96);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.4);
}

.marker-cluster-menu strong {
  color: var(--text-primary);
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0;
}

.marker-cluster-menu div {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.marker-cluster-menu button {
  min-width: 32px;
  min-height: 30px;
  padding: 5px 7px;
  border: 1px solid rgba(94, 234, 212, 0.48);
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.12);
  color: var(--text-primary);
  font-size: 0.76rem;
  font-weight: 900;
}

.marker-cluster-menu button:hover,
.marker-cluster-menu button:focus-visible {
  background: var(--accent);
  color: var(--bg-page);
  outline: none;
}

html[data-theme="light"] .marker-cluster-menu button {
  border-color: rgba(15, 142, 145, 0.28);
  background: rgba(15, 142, 145, 0.08);
  color: #082535;
}

html[data-theme="light"] .marker-cluster-menu button:hover,
html[data-theme="light"] .marker-cluster-menu button:focus-visible {
  background: #0f8e91;
  color: #ffffff;
}

.review-marker-list article {
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
}

.review-marker-list .marker-text {
  cursor: pointer;
}

.client-review-clarification-box {
  margin-top: 12px;
}

.marker-text.selected {
  border-color: var(--success);
  box-shadow: inset 4px 0 0 var(--success);
}

.marker-text.green {
  border-left: 4px solid var(--success);
}

.marker-text.orange {
  border-left: 4px solid var(--coral);
}

.marker-text.red {
  border-left: 4px solid var(--danger);
}

.completed-review-button {
  border-color: rgba(34, 197, 94, 0.5);
  background: rgba(34, 197, 94, 0.16);
  color: #86efac;
}

.completed-review-button:disabled {
  border-color: rgba(139, 148, 158, 0.35);
  background: rgba(139, 148, 158, 0.12);
  color: var(--muted);
  cursor: not-allowed;
}

.review-card button:disabled {
  border-color: rgba(139, 148, 158, 0.35);
  background: rgba(139, 148, 158, 0.12);
  color: var(--muted);
  cursor: not-allowed;
}

.history-journey-block {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  content-visibility: auto;
  contain-intrinsic-size: 240px;
}

.history-journey-block summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  cursor: pointer;
  list-style: none;
}

.history-journey-block summary::-webkit-details-marker {
  display: none;
}

.history-journey-block summary::after {
  content: "+";
  color: var(--action);
  font-weight: 950;
}

.history-journey-block[open] summary::after {
  content: "-";
}

.history-journey-block summary span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 0.84rem;
}

.history-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px 10px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
}

.history-item-copy {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.history-item span {
  color: var(--muted);
  font-size: 0.82rem;
}

.history-item-link {
  justify-self: end;
  min-height: 34px;
  padding: 7px 10px;
  border: 1px solid rgba(94, 234, 212, 0.34);
  border-radius: 8px;
  background: rgba(94, 234, 212, 0.08);
  color: #f8ffff;
  font-size: 0.78rem;
  font-weight: 850;
  text-decoration: none;
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease, box-shadow 160ms ease;
}

.history-item-link:hover,
.history-item-link:focus-visible,
a.history-item-link.free-source:hover,
a.history-item-link.mixed-source:hover,
a.history-item-link.commercial-source:hover {
  border-color: rgba(94, 234, 212, 0.62) !important;
  background: var(--accent) !important;
  color: var(--bg-page);
  box-shadow: 0 8px 18px rgba(94, 234, 212, 0.14);
  outline: none;
}

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

.modal-actions .primary-button,
.modal-actions .secondary-button {
  min-height: var(--control-height);
  border-radius: 8px;
}

#licenseNoticeModal .modal-card {
  border-color: rgba(94, 234, 212, 0.42);
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.46);
}

#licenseNoticeProceed.primary-button {
  background: var(--accent);
  color: var(--bg-page);
}

.plan-overview {
  display: grid;
  gap: 12px;
}

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

.plan-summary-grid article {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
}

.plan-step {
  display: grid;
  gap: 6px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
}

.plan-step small,
.plan-step span,
.plan-step em {
  color: var(--muted);
}

.plan-source-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  min-height: 30px;
  padding: 6px 10px;
  border: 1px solid rgba(79, 209, 197, 0.42);
  border-radius: 8px;
  background: rgba(79, 209, 197, 0.12);
  color: var(--action);
  font-size: 0.82rem;
  font-weight: 900;
  text-decoration: none;
}

.plan-source-action.locked {
  border-color: rgba(148, 163, 184, 0.34);
  background: rgba(148, 163, 184, 0.1);
  color: var(--muted);
}

.plan-step.main {
  border-color: rgba(94, 234, 212, 0.48);
  background: rgba(94, 234, 212, 0.08);
}

.plan-step.ambient {
  border-color: rgba(167, 139, 250, 0.46);
  background: rgba(167, 139, 250, 0.08);
}

.plan-step.bridge {
  border-color: rgba(245, 158, 11, 0.46);
  background: rgba(245, 158, 11, 0.08);
}

.journey-history {
  border-color: rgba(94, 234, 212, 0.28);
  background: var(--navy-soft);
}

.notice-toast {
  display: none;
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 9000;
  max-width: min(460px, calc(100vw - 36px));
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-left: 8px solid var(--success);
  border-radius: 8px;
  background: var(--bg-panel);
  box-shadow: 0 18px 44px rgba(21, 23, 24, 0.22);
  color: var(--ink);
  font-weight: 850;
  line-height: 1.35;
  cursor: pointer;
}

.notice-toast.success {
  border-left-color: var(--success);
}

.notice-toast.error {
  border-left-color: var(--danger);
}

.notice-toast.active {
  display: block;
}

@media (min-width: 781px) {
  .notice-toast:not(.important) {
    top: 50%;
    right: 22px;
    bottom: auto;
    transform: translateY(-50%);
  }
}

.notice-toast.important {
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  display: grid;
  place-items: center;
  max-width: none;
  padding: 18px;
  border: 0;
  border-radius: 0;
  background: rgba(15, 28, 35, 0.42);
  box-shadow: none;
  cursor: default;
}

.notice-dialog {
  width: min(460px, 100%);
  padding: 18px;
  border: 1px solid var(--line);
  border-left: 8px solid var(--danger);
  border-radius: 8px;
  background: var(--bg-workspace);
  box-shadow: 0 18px 44px rgba(21, 23, 24, 0.22);
}

.notice-toast.important.success .notice-dialog {
  border-left-color: var(--success);
}

.notice-toast.important.success .notice-dialog strong {
  color: var(--low-ink);
}

.notice-toast.important.success .notice-dialog button {
  border-color: var(--accent);
  background: var(--accent);
  color: #061826;
}

.notice-dialog strong {
  display: block;
  margin-bottom: 8px;
  color: var(--danger);
  font-size: 1.06rem;
}

.notice-dialog p {
  margin-bottom: 14px;
  color: var(--muted);
  line-height: 1.45;
}

.notice-dialog button {
  width: 100%;
  border-color: var(--danger);
  background: var(--danger);
  color: #fff;
}

.track-box span {
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 850;
}

.track-box small {
  color: var(--muted);
  font-size: 0.72rem;
  line-height: 1.3;
}

.evaluation {
  display: none;
  margin-top: 14px;
  padding: 14px;
  border-radius: 8px;
  background: #e4f3ed;
  line-height: 1.55;
}

.evaluation.active {
  display: block;
}

.mix-plan {
  display: grid;
  gap: 10px;
}

.mix-segment {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 12px;
  padding: 13px;
  border: 1px solid var(--line);
  border-left-width: 8px;
  border-radius: 8px;
  background: var(--bg-panel);
}

.mix-segment.main {
  border-left-color: var(--navy);
}

.mix-segment.ambient {
  border-left-color: var(--success);
}

.mix-segment.bridge {
  border-left-color: var(--coral);
}

.mix-time {
  display: grid;
  place-items: center;
  min-height: 68px;
  padding: 8px;
  border-radius: 8px;
  background: var(--navy-soft);
  color: var(--navy);
  font-weight: 950;
  text-align: center;
}

.mix-note {
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
}

.library-layout {
  display: grid;
  grid-template-columns: 330px 1fr;
  gap: 16px;
  align-items: start;
}

.library-list {
  position: sticky;
  top: 84px;
  padding: 16px;
  border: 1px solid rgba(94, 234, 212, 0.14);
}

.state-list {
  display: grid;
  gap: 8px;
  max-height: calc(100vh - 190px);
  overflow: auto;
  padding-right: 4px;
}

.state-button {
  display: grid;
  grid-template-columns: 36px 1fr auto;
  gap: 10px;
  align-items: center;
  min-height: 58px;
  padding: 9px;
  text-align: left;
}

.state-button.active {
  border-color: rgba(94, 234, 212, 0.4);
  background: var(--navy-soft);
  box-shadow: inset 4px 0 0 rgba(94, 234, 212, 0.95);
}

.state-number {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 8px;
  background: var(--action);
  color: var(--page);
  font-weight: 950;
}

.state-name {
  display: block;
  font-weight: 950;
}

.state-emotion {
  display: block;
  color: var(--muted);
  font-size: 0.82rem;
}

.mini-energy,
.score-pill {
  padding: 7px 9px;
  border-radius: 8px;
  background: var(--navy-soft);
  color: var(--navy);
  font-size: 0.82rem;
  font-weight: 950;
  white-space: nowrap;
}

.recipe-card,
.search-panel {
  padding: 16px;
}

.recipe-card {
  margin-bottom: 14px;
}

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

.highlight-card {
  min-height: 76px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--navy-soft);
}

.accordion-stack .accordion {
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(12, 24, 34, 0.9);
  overflow: hidden;
}

.accordion-stack .accordion[open] {
  box-shadow: inset 4px 0 0 rgba(94, 234, 212, 0.95);
  border-color: rgba(94, 234, 212, 0.34);
}

.accordion-stack .accordion summary {
  color: #eaf4f8;
}

.accordion-stack .accordion summary::after {
  color: #5eead4;
}

.accordion-stack .accordion-body {
  background: rgba(8, 20, 30, 0.92);
  color: #d7e8f0;
}

.accordion-stack .accordion.warning summary {
  background: rgba(12, 24, 34, 0.9);
  color: #fff7ed;
}

.accordion-stack .accordion.warning .accordion-body {
  background: rgba(8, 20, 30, 0.92);
  color: #d7e8f0;
}

.search-panel {
  border: 1px solid rgba(94, 234, 212, 0.18);
  background: rgba(7, 22, 32, 0.92);
}

.search-panel .eyebrow,
.search-panel h3 {
  color: var(--ink);
}

.phrase-grid .phrase {
  border: 1px solid rgba(94, 234, 212, 0.18);
  background: rgba(10, 24, 36, 0.92);
  color: #dcecf2;
}

.wave-group-card {
  margin-bottom: 14px;
  border: 1px solid rgba(94, 234, 212, 0.24);
  border-radius: 8px;
  background: #203f50;
  box-shadow: 0 14px 30px rgba(2, 12, 19, 0.18);
  overflow: hidden;
}

.wave-group-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 14px;
  cursor: pointer;
  list-style: none;
  font-weight: 900;
  color: #f3fbfd;
}

.wave-group-summary::-webkit-details-marker {
  display: none;
}

.wave-group-summary span {
  color: #d6eaf0;
  font-size: 0.78rem;
  font-weight: 700;
}

.wave-group-body {
  display: grid;
  gap: 12px;
  padding: 0 10px 10px;
}

.wave-group-card.wave-aqua {
  border-color: rgba(94, 234, 212, 0.32);
  box-shadow: inset 4px 0 0 rgba(94, 234, 212, 0.95);
}

.wave-group-card.wave-cyan {
  border-color: rgba(103, 232, 249, 0.32);
  box-shadow: inset 4px 0 0 rgba(103, 232, 249, 0.95);
}

.wave-group-card.wave-emerald {
  border-color: rgba(52, 211, 153, 0.32);
  box-shadow: inset 4px 0 0 rgba(52, 211, 153, 0.95);
}

.wave-group-card.wave-sky {
  border-color: rgba(56, 189, 248, 0.32);
  box-shadow: inset 4px 0 0 rgba(56, 189, 248, 0.95);
}

.wave-group-card.wave-teal {
  border-color: rgba(45, 212, 191, 0.32);
  box-shadow: inset 4px 0 0 rgba(45, 212, 191, 0.95);
}

.wave-group-card.wave-mint {
  border-color: rgba(110, 231, 183, 0.32);
  box-shadow: inset 4px 0 0 rgba(110, 231, 183, 0.95);
}

.search-panel p,
.phrase-grid .phrase strong,
.phrase-grid .phrase span,
.phrase-grid .phrase small {
  color: #dcecf2;
}

.highlight-card span {
  display: block;
  margin-bottom: 7px;
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 900;
  text-transform: uppercase;
}

.highlight-card strong {
  color: var(--navy);
  line-height: 1.25;
}

.accordion-stack {
  display: grid;
  gap: 10px;
  margin-bottom: 14px;
}

.accordion {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg-panel);
  box-shadow: 0 8px 18px rgba(21, 23, 24, 0.05);
  content-visibility: auto;
  contain-intrinsic-size: 220px;
}

.accordion.warning {
  border-color: rgba(245, 158, 11, 0.36);
  background:
    linear-gradient(180deg, rgba(245, 158, 11, 0.08), rgba(245, 158, 11, 0.035)),
    var(--bg-panel);
}

.accordion summary {
  min-height: 48px;
  padding: 13px 14px;
  color: var(--ink);
  cursor: pointer;
  font-weight: 950;
  list-style: none;
}

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

.accordion summary::after {
  content: "+";
  float: right;
  color: var(--action);
  font-weight: 950;
}

.accordion[open] summary::after {
  content: "-";
}

.accordion-body {
  display: grid;
  gap: 8px;
  padding: 0 14px 14px;
}

.accordion-body p {
  margin: 0;
  padding: 10px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
  color: #cfd8e3;
  line-height: 1.45;
}

.accordion.warning .accordion-body p {
  border: 1px solid rgba(245, 158, 11, 0.28);
  background: rgba(245, 158, 11, 0.11);
  color: var(--text-soft);
}

html[data-theme="light"] .accordion.warning {
  border-color: rgba(180, 83, 9, 0.32);
  background:
    linear-gradient(180deg, rgba(255, 247, 237, 0.96), rgba(255, 251, 235, 0.86)),
    var(--bg-panel);
}

html[data-theme="light"] .accordion.warning summary {
  color: var(--ink);
}

html[data-theme="light"] .accordion.warning .accordion-body p {
  border-color: rgba(180, 83, 9, 0.24);
  background: #fff7ed;
  color: #432818;
}

.state-detail .accordion-stack .accordion,
html[data-theme="dark"] .state-detail .accordion-stack .accordion {
  border-color: rgba(94, 234, 212, 0.24);
  background: rgba(11, 43, 40, 0.94);
}

.state-detail .accordion-stack .accordion[open],
html[data-theme="dark"] .state-detail .accordion-stack .accordion[open] {
  border-color: rgba(94, 234, 212, 0.48);
  box-shadow: inset 4px 0 0 rgba(94, 234, 212, 0.95), 0 14px 28px rgba(8, 24, 34, 0.12);
}

.state-detail .accordion-stack .accordion > summary,
html[data-theme="dark"] .state-detail .accordion-stack .accordion > summary {
  background: rgba(19, 68, 62, 0.96);
  color: #e9fff9;
}

.state-detail .accordion-stack .accordion > summary::after,
html[data-theme="light"] .state-detail .accordion-stack .accordion > summary::after {
  color: #5eead4;
}

.state-detail .accordion-stack .accordion .accordion-body,
html[data-theme="dark"] .state-detail .accordion-stack .accordion .accordion-body {
  background: rgba(7, 31, 30, 0.94);
  color: #d8f7f0;
}

.state-detail .accordion-stack .accordion .accordion-body p,
html[data-theme="dark"] .state-detail .accordion-stack .accordion .accordion-body p {
  border: 1px solid rgba(94, 234, 212, 0.14);
  background: rgba(181, 245, 236, 0.075);
  color: #d8f7f0;
}

.state-detail .accordion-stack .accordion.warning,
html[data-theme="dark"] .state-detail .accordion-stack .accordion.warning {
  border-color: rgba(245, 158, 11, 0.48);
  background:
    linear-gradient(180deg, rgba(245, 158, 11, 0.1), rgba(8, 38, 34, 0.94)),
    rgba(12, 45, 39, 0.96);
}

.state-detail .accordion-stack .accordion.warning > summary,
html[data-theme="dark"] .state-detail .accordion-stack .accordion.warning > summary {
  background: rgba(45, 42, 23, 0.96);
  color: #fff7ed;
}

.state-detail .accordion-stack .accordion.warning .accordion-body p,
html[data-theme="light"] .state-detail .accordion-stack .accordion.warning .accordion-body p {
  border-color: rgba(245, 158, 11, 0.3);
  background: rgba(245, 158, 11, 0.13);
  color: #ffe8b0;
}

html[data-theme="light"] .state-detail .accordion-stack .accordion {
  border-color: rgba(15, 142, 145, 0.28);
  background: #e8f6f2;
  box-shadow: 0 12px 24px rgba(15, 83, 86, 0.08);
}

html[data-theme="light"] .state-detail .accordion-stack .accordion[open] {
  border-color: rgba(15, 142, 145, 0.46);
  box-shadow: inset 4px 0 0 rgba(15, 142, 145, 0.78), 0 14px 28px rgba(15, 83, 86, 0.12);
}

html[data-theme="light"] .state-detail .accordion-stack .accordion > summary {
  background: #d7eee8;
  color: #0d3c3f;
}

html[data-theme="light"] .state-detail .accordion-stack .accordion > summary::after {
  color: #0f8e91;
}

html[data-theme="light"] .state-detail .accordion-stack .accordion .accordion-body {
  background: #edf8f5;
  color: #164d50;
}

html[data-theme="light"] .state-detail .accordion-stack .accordion .accordion-body p {
  border-color: rgba(15, 142, 145, 0.18);
  background: #f6fcfa;
  color: #123f42;
}

html[data-theme="light"] .state-detail .accordion-stack .accordion.warning {
  border-color: rgba(180, 83, 9, 0.3);
  background:
    linear-gradient(180deg, rgba(255, 247, 237, 0.92), rgba(232, 246, 242, 0.96)),
    #e8f6f2;
}

html[data-theme="light"] .state-detail .accordion-stack .accordion.warning > summary {
  background: #fff3df;
  color: #65320a;
}

html[data-theme="light"] .state-detail .accordion-stack .accordion.warning .accordion-body p {
  border-color: rgba(180, 83, 9, 0.22);
  background: #fffaf0;
  color: #56320d;
}

html[data-theme="dark"] .state-detail .accordion-stack .accordion.warning .accordion-body p {
  border-color: rgba(245, 158, 11, 0.3);
  background: rgba(245, 158, 11, 0.13);
  color: #ffe8b0;
}

.lead {
  color: var(--muted);
  line-height: 1.55;
  overflow-wrap: anywhere;
}

.meta-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px;
  margin-bottom: 12px;
}

.meta-item {
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
}

.meta-label {
  display: block;
  margin-bottom: 4px;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
}

.meta-value {
  font-weight: 850;
  line-height: 1.35;
}

.detail-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-bottom: 14px;
}

.clean-list {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.clean-list li {
  padding: 10px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
  line-height: 1.42;
}

.warning-list li {
  background: var(--danger-soft);
  color: var(--high-ink);
}

.search-panel .section-heading {
  margin-bottom: 12px;
}

.phrase-grid {
  margin-bottom: 12px;
}

.phrase {
  background: var(--low);
  color: var(--low-ink);
}

.phrase.music-query {
  background: #ffe9e2;
  color: var(--high-ink);
}

.phrase.sound-query {
  background: var(--low);
  color: var(--low-ink);
}

.source-link {
  background: var(--mid);
  color: var(--mid-ink);
}

.training-layer-builder {
  display: grid;
  gap: 14px;
  margin: 16px 0;
}

.training-layer-card {
  border: 1px solid rgba(102, 239, 224, 0.28);
  border-radius: 8px;
  background: rgba(6, 24, 38, 0.38);
  padding: 14px;
}

.training-layer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.training-task-card,
.client-training-task-card {
  border-color: rgba(102, 239, 224, 0.26);
}

.training-status-badge {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  min-height: 26px;
  padding: 3px 9px;
  border-radius: 999px;
  border: 1px solid rgba(102, 239, 224, 0.34);
  background: rgba(102, 239, 224, 0.12);
  color: var(--text-primary);
  font-size: 0.78rem;
  font-weight: 800;
  line-height: 1;
}

.training-status-badge.in-progress {
  border-color: rgba(245, 194, 66, 0.42);
  background: rgba(245, 194, 66, 0.14);
}

.training-status-badge.submitted {
  border-color: rgba(132, 176, 255, 0.46);
  background: rgba(132, 176, 255, 0.14);
}

.training-status-badge.reviewed {
  border-color: rgba(77, 214, 154, 0.44);
  background: rgba(77, 214, 154, 0.14);
}

.training-status-badge.archived {
  border-color: rgba(148, 163, 184, 0.35);
  background: rgba(148, 163, 184, 0.12);
  color: var(--text-muted);
}

.training-task-body,
.training-submission-list,
.training-client-layer-list {
  display: grid;
  gap: 12px;
}

.training-client-layer,
.training-submission-card {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid rgba(102, 239, 224, 0.18);
  border-radius: 8px;
  background: rgba(6, 24, 38, 0.28);
}

.training-client-layer > div,
.training-resource-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.training-client-layer strong {
  color: var(--text-primary);
}

.training-client-layer span,
.training-client-layer small,
.training-submission-card small {
  color: var(--text-muted);
}

.training-resource-row {
  margin: 2px 0 4px;
}

html[data-theme="light"] .training-layer-card,
html[data-theme="light"] .training-client-layer,
html[data-theme="light"] .training-submission-card {
  background: rgba(255, 255, 255, 0.82);
  border-color: rgba(17, 94, 89, 0.18);
}

html[data-theme="light"] .training-status-badge {
  color: #12343d;
}

.compact-form-grid {
  gap: 10px;
}

@media (max-width: 1080px) {
  body.facilitator-shell .app-shell {
    padding-left: 0;
  }

  body.client-shell .app-shell {
    padding-left: 0;
  }

  body.facilitator-sidebar-collapsed.facilitator-shell .app-shell,
  body.facilitator-sidebar-collapsed.client-shell .app-shell {
    padding-left: 0;
  }

  .satellite-audition-panel {
    left: 18px;
    right: 18px;
    top: max(26px, env(safe-area-inset-top));
    width: auto;
    max-width: none;
  }

  .audition-panel.split-left,
  .satellite-audition-panel.split-right {
    left: 18px;
    right: 18px;
    width: auto;
    max-width: none;
  }

  .facilitator-sidebar {
    left: 0;
    width: min(88vw, 320px);
    transform: translateX(-100%);
    transition: transform 180ms ease;
  }

  body.facilitator-sidebar-collapsed .facilitator-sidebar {
    width: min(88vw, 320px);
    padding: 18px 14px 16px;
  }

  body.facilitator-sidebar-collapsed .sidebar-brand-copy,
  body.facilitator-sidebar-collapsed .nav-label {
    display: grid;
  }

  body.facilitator-sidebar-collapsed .sidebar-group summary::after {
    display: inline;
  }

  .facilitator-sidebar.open {
    transform: translateX(0);
  }

  .facilitator-sidebar.open ~ .top-workbar .mobile-menu-toggle {
    visibility: hidden;
  }

  .facilitator-sidebar.open .sidebar-brand {
    cursor: pointer;
  }

  body.facilitator-shell .top-workbar::before,
  body.facilitator-shell .top-workbar::after,
  body.client-shell .top-workbar::before,
  body.client-shell .top-workbar::after {
    display: none;
  }

  body.facilitator-shell .top-workbar,
  body.client-shell .top-workbar {
    position: sticky;
    top: 0;
    width: 100%;
    max-width: 100vw;
    box-sizing: border-box;
    grid-template-columns: auto minmax(220px, max-content) minmax(260px, 1fr);
    grid-template-rows: auto;
    align-items: center;
    margin: 0;
    padding: 12px 16px 10px;
    border-left: 0;
    border-right: 0;
    border-radius: 0;
    box-shadow: none;
  }

  body.facilitator-shell:not(.playlist-editing) .top-workbar {
    position: sticky;
    top: 0;
  }

  body.facilitator-shell .mobile-menu-toggle,
  body.client-shell .mobile-menu-toggle {
    position: relative;
    z-index: 90;
    display: inline-flex;
    grid-column: 1;
    grid-row: 1;
    align-items: center;
    justify-content: center;
    min-width: 62px;
    min-height: 42px;
    padding: 0 10px;
    font-size: 0.88rem;
    background: var(--bg-card);
    color: var(--action);
  }

  body.facilitator-shell .top-therapist-identity,
  body.client-shell .top-therapist-identity {
    grid-column: 2;
    grid-row: 1;
    max-width: min(440px, 48vw);
  }

  body.facilitator-shell .active-journey-bar,
  body.client-shell .active-journey-bar {
    grid-column: 3 / -1;
    grid-row: 1;
    align-self: center;
  }

  body.facilitator-shell .workspace-quick-nav,
  body.client-shell .workspace-quick-nav {
    grid-column: 3;
    grid-row: 1;
    justify-content: flex-end;
  }

  body.facilitator-shell .mode-panel.active,
  body.client-shell .mode-panel.active {
    width: 100%;
    max-width: 100vw;
    box-sizing: border-box;
    margin: 0;
    padding: 14px 16px 24px;
    border-left: 0;
    border-right: 0;
    border-bottom: 0;
    border-radius: 0;
    box-shadow: none;
  }

  body.facilitator-shell .app-shell,
  body.client-shell .app-shell {
    width: 100%;
    max-width: 100vw;
    overflow-x: hidden;
  }

  .facilitator-sidebar-toggle {
    display: inline-flex;
    justify-content: center;
    background: rgba(94, 234, 212, 0.14);
    color: var(--action);
  }

  .sidebar-brand {
    min-height: 76px;
    padding: 10px 12px;
    grid-template-columns: 52px minmax(0, 1fr);
  }

  .sidebar-brand-media {
    width: 52px;
    height: 52px;
  }

  .wizard-grid,
  .register-grid,
  .library-layout,
  .timeline-item,
  .layer-search,
  .mix-segment,
  .source-groups,
  .profile-grid,
  .diary-entry,
  .service-item {
    grid-template-columns: 1fr;
  }

  .facilitator-grid,
  .facilitator-split,
  .facilitator-detail-columns,
  .client-record-columns,
  .client-record-summary,
  .client-info-grid,
  .playlist-access-form,
  .brand-preview-row,
  .profile-media-grid,
  .followup-form-grid,
  .therapist-review-create-grid,
  .followup-assignment-summary,
  .session-rating-body {
    grid-template-columns: 1fr;
  }

  .client-record-summary-side {
    justify-items: start;
    text-align: left;
  }

  .followup-assignment-summary {
    display: grid;
  }

  .followup-time-row,
  .followup-time-row-edit {
    grid-template-columns: 1fr;
  }

  .training-filter-panel {
    grid-template-columns: 1fr;
  }

  .library-toolbar {
    grid-template-columns: 1fr;
  }

  .custom-file-upload {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .review-media-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .review-media-actions .button-row {
    width: 100%;
  }

  .review-media-actions .button-row button {
    flex: 1 1 auto;
  }

  .followup-assignment-meta {
    justify-items: start;
  }

  .wide-field {
    grid-column: auto;
  }

  .track-box {
    grid-column: auto;
  }

  .library-list {
    position: static;
  }

  .state-list {
    max-height: none;
  }

  .workspace-today-card,
  .workspace-ops-grid {
    grid-template-columns: 1fr;
  }

  .workspace-today-actions,
  .workspace-quick-actions {
    justify-content: flex-start;
  }

  .workspace-metric-strip {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  body.facilitator-shell .top-workbar,
  body.client-shell .top-workbar {
    grid-template-columns: 44px minmax(0, 1fr);
    grid-template-rows: auto auto;
    gap: 8px;
    align-items: stretch;
  }

  body.facilitator-shell .mobile-menu-toggle,
  body.client-shell .mobile-menu-toggle {
    min-width: 44px;
    min-height: 40px;
    width: 44px;
    padding: 0;
    font-size: 0;
  }

  body.facilitator-shell .mobile-menu-toggle::before,
  body.client-shell .mobile-menu-toggle::before {
    content: "☰";
    font-size: 1rem;
    line-height: 1;
  }

  body.facilitator-shell .top-therapist-identity,
  body.client-shell .top-therapist-identity {
    display: none !important;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-bar,
  body.client-shell .active-journey-bar {
    grid-column: 2 / -1;
    grid-row: 1;
    align-self: stretch;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-copy,
  body.facilitator-shell:not(.playlist-editing) .live-status-wrap {
    display: none !important;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-tools {
    display: grid;
    grid-template-columns: 42px 38px;
    align-items: stretch;
    gap: 5px;
    height: 100%;
    justify-content: end;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-tools .notifications-status-wrap {
    order: 1;
    width: 100%;
    min-width: 0;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-tools .header-theme-switch {
    order: 2;
    width: 38px;
    min-height: 40px;
    justify-content: center;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-tools .workspace-priority-pill {
    order: 3;
    min-width: 0;
    max-width: none;
    width: 100%;
    min-height: 40px;
    padding: 5px 7px;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-tools .workspace-priority-pill strong {
    display: none;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-tools .workspace-priority-pill span {
    overflow: hidden;
    font-size: 0.72rem;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-tools [data-open-notifications],
  body.facilitator-shell:not(.playlist-editing) .active-journey-tools .header-notification-button {
    display: inline-grid;
    place-items: center;
    width: 100%;
    min-width: 0;
    min-height: 40px;
    padding: 0;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-tools .header-button-label {
    display: none;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-tools .header-button-icon {
    display: inline-grid;
    place-items: center;
  }

  body.client-shell .active-journey-bar {
    display: grid;
    grid-template-columns: 1fr;
    grid-template-rows: auto auto;
    gap: 6px;
    min-height: 0;
  }

  body.client-shell .active-journey-copy {
    grid-row: 2;
  }

  body.client-shell .active-journey-tools.client-header-tools {
    display: grid;
    grid-row: 1;
    grid-template-columns: minmax(0, 1fr) 42px 38px;
    gap: 5px;
    align-items: stretch;
    width: 100%;
  }

  body.client-shell .client-practitioner-header-pill {
    display: none !important;
  }

  body.client-shell .client-priority-pill {
    min-height: 44px;
    padding: 6px 7px;
  }

  body.client-shell .client-priority-pill strong {
    display: none;
  }

  body.client-shell .client-header-tools .notifications-status-wrap,
  body.client-shell .client-header-tools .header-theme-switch {
    width: 100%;
    min-width: 0;
  }

  body.client-shell .client-header-tools [data-open-notifications] {
    display: inline-grid;
    place-items: center;
    width: 100%;
    min-width: 0;
    min-height: 44px;
    padding: 0;
  }

  body.client-shell .client-header-tools .header-button-label {
    display: none;
  }

  body.client-shell .client-header-tools .header-button-icon {
    display: inline-grid;
    place-items: center;
  }
}

@media (max-width: 680px) {
  body.auth-locked {
    overflow-x: hidden;
  }

  .auth-gate {
    align-items: start;
    justify-items: center;
    width: 100%;
    padding: 16px 12px;
    box-sizing: border-box;
  }

  .auth-card {
    width: min(100%, calc(100vw - 24px));
    max-width: calc(100vw - 24px);
    padding: 20px 16px;
    overflow: hidden;
    box-sizing: border-box;
  }

  .auth-card *,
  .password-field,
  .password-field input {
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
  }

  .auth-card h1 {
    font-size: clamp(1.75rem, 9vw, 2.2rem);
    line-height: 1.02;
    overflow-wrap: anywhere;
  }

  .auth-card > .lead {
    font-size: 0.95rem;
    line-height: 1.45;
  }

  .auth-legal-links {
    display: flex;
    justify-content: flex-start;
    gap: 6px 14px;
    font-size: 0.78rem;
  }

  .auth-legal-links .auth-legal-primary {
    display: inline;
    width: auto;
    box-sizing: border-box;
  }

  h1 {
    font-size: 1.9rem;
  }

  h2 {
    font-size: 1.45rem;
  }

  .hero {
    min-height: 260px;
  }

  .mode-tabs,
  .mode-panel,
  .top-workbar,
  .hero-overlay {
    padding-left: 14px;
    padding-right: 14px;
  }

  body.facilitator-shell .top-workbar,
  body.facilitator-shell .mode-panel {
    padding-left: 14px;
    padding-right: 14px;
  }

  body.facilitator-shell .section-heading h1,
  body.facilitator-shell .section-heading h2,
  body.client-shell .section-heading h1,
  body.client-shell .section-heading h2 {
    font-size: clamp(1.55rem, 7.5vw, 1.95rem);
    line-height: 1.04;
  }

  body.facilitator-shell .section-heading .lead,
  body.client-shell .section-heading .lead {
    font-size: 0.98rem;
    line-height: 1.45;
  }

  body.facilitator-shell .profile-card,
  body.client-shell .profile-card,
  body.facilitator-shell .history-entry,
  body.client-shell .history-entry,
  body.facilitator-shell .workspace-context-box,
  body.client-shell .workspace-context-box {
    border-radius: 8px;
  }

  .notification-preference-card {
    grid-template-columns: 1fr;
  }

  .notification-preference-toggle {
    justify-content: space-between;
    width: 100%;
  }

  .session-card-main,
  .session-detail-status-row {
    flex-direction: column;
    align-items: flex-start;
  }

  .training-basics-layout {
    grid-template-columns: 1fr;
  }

  .training-date-group {
    grid-template-columns: 1fr;
  }

  .training-format-field {
    max-width: none;
    flex-basis: 100%;
  }

  .workspace-summary-card {
    min-height: 132px;
    padding: 16px;
  }

  .workspace-summary-card strong {
    font-size: 2.15rem;
  }

  .workspace-summary-card small {
    line-height: 1.35;
  }

  .workspace-ops-dashboard {
    gap: 10px;
  }

  .workspace-today-card,
  .workspace-ops-panel {
    padding: 12px;
  }

  .workspace-today-actions,
  .workspace-quick-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .workspace-today-actions button,
  .workspace-today-actions a,
  .workspace-quick-actions button,
  .workspace-quick-actions a,
  .playlist-manage-actions button,
  .playlist-manage-actions a,
  .modal-actions button,
  .modal-actions a,
  .button-row button,
  .button-row a {
    width: 100%;
    min-width: 0;
  }

  .playlist-manage-actions,
  .button-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: stretch;
  }

  .training-program-manage-card .library-playlist-summary {
    align-items: stretch;
    grid-template-columns: minmax(0, 1fr);
  }

  .training-program-manage-card .playlist-manage-actions {
    grid-template-columns: minmax(0, 1fr);
    width: 100%;
  }

  .training-program-manage-card .training-card-action-select,
  .training-program-manage-card .playlist-manage-actions button {
    min-width: 0;
    width: 100%;
  }

  .training-program-manage-card .library-playlist-summary::after {
    justify-self: start;
  }

  .training-event-card .playlist-manage-actions {
    grid-template-columns: minmax(0, 1fr);
  }

  .social-prefix-field {
    grid-template-columns: minmax(0, 1fr);
  }

  .social-prefix-field > span {
    border-bottom: 1px solid var(--line);
    border-right: 0;
    min-height: 34px;
  }

  .modal-actions {
    display: grid;
    grid-template-columns: 1fr;
    justify-content: stretch;
  }

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

  .workspace-dashboard-row {
    grid-template-columns: minmax(0, 1fr);
  }

  .workspace-dashboard-row em {
    justify-self: start;
  }

  body.admin-route .admin-board {
    width: calc(100vw - 24px);
    max-width: calc(100vw - 24px);
    padding: 14px;
    overflow: hidden;
  }

  body.admin-route #adminMode {
    padding: 12px;
  }

  body.admin-route .admin-workspace {
    gap: 12px;
  }

  body.admin-route .admin-login {
    width: min(100%, calc(100vw - 52px));
    max-width: 100%;
  }

  body.admin-route #adminTitle {
    font-size: clamp(2rem, 12vw, 2.45rem);
    line-height: 0.98;
  }

  body.admin-route .section-heading {
    gap: 8px;
    margin-bottom: 12px;
  }

  body.admin-route .section-heading .lead {
    font-size: 1rem;
    line-height: 1.35;
    overflow-wrap: anywhere;
  }

  .workspace-guide-summary {
    flex-direction: row;
    align-items: center;
    min-height: 34px;
    padding: 7px 10px;
    border: 1px solid rgba(94, 234, 212, 0.26);
    border-radius: 8px;
    background: rgba(94, 234, 212, 0.08);
  }

  .workspace-guide-summary span {
    display: none;
  }

  .workspace-guide-summary strong {
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0;
  }

  body.facilitator-shell .top-workbar,
  body.client-shell .top-workbar,
  .top-workbar {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-template-rows: auto auto auto auto auto;
    gap: 8px;
    padding-top: 8px;
    padding-bottom: 8px;
  }

  body.facilitator-shell:not(.playlist-editing) .top-workbar {
    grid-template-columns: 44px minmax(0, 1fr);
    grid-template-rows: auto auto;
    align-items: stretch;
  }

  body.facilitator-shell .mobile-menu-toggle,
  body.client-shell .mobile-menu-toggle,
  .mobile-menu-toggle {
    grid-column: 1;
    grid-row: 1;
  }

  body.facilitator-shell:not(.playlist-editing) .mobile-menu-toggle {
    grid-column: 1;
    grid-row: 1;
  }

  body.facilitator-shell .top-therapist-identity,
  body.client-shell .top-therapist-identity,
  .top-therapist-identity {
    display: none !important;
  }

  body.facilitator-shell .workspace-quick-nav,
  body.client-shell .workspace-quick-nav,
  .workspace-quick-nav {
    grid-column: 1 / -1;
    grid-row: 5;
    order: 5;
    justify-content: flex-start;
  }

  .workspace-quick-nav button {
    width: 100%;
  }

  .impersonation-topbar {
    grid-column: 1 / -1;
    grid-row: 4;
    order: 4;
    align-items: flex-start;
    flex-direction: column;
  }

  .mobile-menu-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    min-height: 40px;
    background: rgba(94, 234, 212, 0.16);
    color: var(--action);
    width: 100%;
    padding: 0;
    font-size: 0;
  }

  .mobile-menu-toggle::before {
    content: "☰";
    font-size: 1rem;
    line-height: 1;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-bar {
    grid-column: 2 / -1;
    grid-row: 1;
    order: 0;
    align-self: stretch;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-copy,
  body.facilitator-shell:not(.playlist-editing) .live-status-wrap {
    display: none !important;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-tools {
    display: grid;
    grid-template-columns: 42px 38px;
    align-items: stretch;
    height: 100%;
    gap: 5px;
    justify-content: end;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-tools .sync-status-wrap {
    width: 100%;
    min-width: 0;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-tools .notifications-status-wrap {
    order: 1;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-tools .header-theme-switch {
    order: 2;
    width: 38px;
    min-height: 40px;
    justify-content: center;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-tools .workspace-priority-pill {
    order: 3;
    display: inline-flex !important;
    min-width: 0;
    max-width: none;
    min-height: 40px;
    padding: 5px 7px;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-tools .workspace-priority-pill strong {
    display: none;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-tools .workspace-priority-pill span {
    overflow: hidden;
    font-size: 0.72rem;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-tools [data-open-notifications] {
    display: inline-grid;
    place-items: center;
    width: 100%;
    min-height: 40px;
    padding: 0;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-tools .header-button-label {
    display: none;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-tools .header-button-icon {
    display: inline-grid;
    place-items: center;
    font-size: 0.88rem;
  }

  body.facilitator-shell .facilitator-sidebar-status-card {
    display: grid;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-tools .sync-status-popover,
  body.facilitator-shell:not(.playlist-editing) .active-journey-tools .notifications-popover {
    left: auto;
    right: 0;
  }

  .mobile-playlist-menu:not([hidden]) {
    display: block;
    grid-column: 3;
    grid-row: 1;
    justify-self: end;
    align-self: stretch;
    min-width: 0;
    position: relative;
    z-index: 80;
    width: 100%;
  }

  .mobile-playlist-menu summary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0 16px;
    border: 1px solid rgba(94, 234, 212, 0.38);
    border-radius: 8px;
    background: rgba(94, 234, 212, 0.16);
    color: var(--action);
    font-weight: 950;
    cursor: pointer;
    width: 100%;
  }

  .mobile-playlist-menu-body {
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    z-index: 42;
    display: grid;
    width: min(268px, calc(100vw - 36px));
    gap: 8px;
    padding: 10px;
    border: 1px solid rgba(94, 234, 212, 0.3);
    border-radius: 8px;
    background: #121821;
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.34);
  }

  .mobile-playlist-menu-body button,
  .mobile-playlist-menu-body select {
    width: 100%;
  }

  .mobile-playlist-menu-body .secondary-button,
  .mobile-playlist-menu-body .autosave-pill,
  .mobile-playlist-menu-body select {
    border-color: rgba(94, 234, 212, 0.34);
    background: #0f151d;
    color: var(--text-primary);
  }

  .mobile-playlist-status {
    display: grid;
    gap: 5px;
  }

  .mobile-playlist-status span {
    color: var(--text-secondary);
    font-size: 0.72rem;
    font-weight: 950;
    text-transform: uppercase;
  }

  .active-journey-bar strong {
    font-size: 0.82rem;
  }

  body.facilitator-shell .active-journey-bar,
  body.client-shell .active-journey-bar,
  .active-journey-bar {
    grid-template-columns: 1fr;
    order: 3;
    grid-column: 1 / -1;
    grid-row: 3;
  }

  .active-journey-tools {
    justify-content: flex-start;
  }

  body.client-shell .top-workbar {
    grid-template-columns: 44px minmax(0, 1fr);
    grid-template-rows: auto auto;
    align-items: stretch;
  }

  body.client-shell .mobile-menu-toggle {
    grid-column: 1;
    grid-row: 1;
  }

  body.client-shell .active-journey-bar {
    display: grid;
    grid-column: 2 / -1;
    grid-row: 1 / span 2;
    grid-template-columns: 1fr;
    grid-template-rows: auto auto;
    gap: 6px;
    align-self: stretch;
    min-height: 0;
  }

  body.client-shell .active-journey-copy {
    display: grid;
    grid-row: 2;
    gap: 1px;
    min-width: 0;
  }

  body.client-shell .active-journey-copy strong,
  body.client-shell .active-journey-copy span {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  body.client-shell .active-journey-tools.client-header-tools {
    display: grid;
    grid-row: 1;
    grid-template-columns: minmax(0, 1fr) 42px 38px;
    gap: 5px;
    align-items: stretch;
    width: 100%;
  }

  body.client-shell .client-practitioner-header-pill {
    display: none !important;
  }

  body.client-shell .client-priority-pill {
    min-height: 44px;
    padding: 6px 7px;
  }

  body.client-shell .client-priority-pill strong {
    display: none;
  }

  body.client-shell .client-priority-pill span {
    font-size: 0.76rem;
  }

  body.client-shell .client-header-tools .notifications-status-wrap,
  body.client-shell .client-header-tools .header-theme-switch {
    width: 100%;
    min-width: 0;
    min-height: 44px;
  }

  body.client-shell .client-header-tools [data-open-notifications] {
    display: inline-grid;
    place-items: center;
    width: 100%;
    min-width: 0;
    min-height: 44px;
    padding: 0;
  }

  body.client-shell .client-header-tools .header-button-label {
    display: none;
  }

  body.client-shell .client-header-tools .header-button-icon {
    display: inline;
    font-size: 0.9rem;
  }

  body.playlist-editing .active-journey-bar {
    grid-column: 2;
    grid-row: 1;
    align-self: stretch;
    order: 0;
  }

  body.playlist-editing .top-workbar {
    grid-template-columns: 54px minmax(0, 1fr) 54px;
    grid-template-rows: auto auto;
    align-items: stretch;
  }

  body.playlist-editing .active-journey-copy {
    display: none;
  }

  body.playlist-editing .active-journey-tools {
    display: grid;
    grid-template-columns: 40px 44px;
    justify-content: start;
    align-items: stretch;
    gap: 6px;
    height: 100%;
  }

  body.playlist-editing .active-journey-tools .header-theme-switch {
    width: 40px;
    min-height: 40px;
  }

  body.playlist-editing .active-journey-tools .notifications-status-wrap {
    width: 44px;
    height: 100%;
  }

  body.playlist-editing .active-journey-tools [data-open-notifications] {
    display: inline-grid;
    place-items: center;
    width: 100%;
    min-height: 40px;
    padding: 0;
    border: 1px solid rgba(94, 234, 212, 0.38);
    border-radius: 8px;
    background: rgba(94, 234, 212, 0.16);
    color: var(--action);
    box-shadow: none;
  }

  body.playlist-editing .active-journey-tools .header-button-label {
    display: none;
  }

  body.playlist-editing .active-journey-tools .header-button-icon {
    display: inline;
    font-size: 0.88rem;
  }

  body.playlist-editing .mobile-playlist-menu summary {
    min-height: 40px;
    padding: 0 8px;
    font-size: 0;
  }

  body.playlist-editing .mobile-playlist-menu summary::before {
    content: "♫";
    font-size: 0.95rem;
  }

  body.playlist-editing .mobile-playlist-menu summary::after {
    font-size: 0.9rem;
  }

  .workspace-priority-pill {
    display: inline-grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    gap: 8px;
    max-width: 100%;
    width: 100%;
    min-height: 34px;
    padding: 7px 10px;
  }

  .workspace-priority-pill strong,
  .workspace-priority-pill span {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .notifications-popover,
  .sync-status-popover {
    left: 0;
    right: auto;
    width: min(300px, calc(100vw - 40px));
    max-height: min(340px, calc(100dvh - 180px));
    overflow: hidden;
    background: var(--bg-panel);
    isolation: isolate;
  }

  .active-journey-tools .notifications-popover {
    position: fixed;
    left: 12px;
    right: 12px;
    top: calc(env(safe-area-inset-top, 0px) + 78px);
    z-index: 240;
    width: auto;
    max-width: none;
    max-height: min(52dvh, 360px);
    overflow-y: auto;
    box-sizing: border-box;
    transform: none;
  }

  .notification-popover-list {
    display: grid;
    gap: 8px;
    max-height: 230px;
    overflow-y: auto;
    padding-right: 2px;
    isolation: isolate;
  }

  .notification-popover-item {
    position: relative;
    display: grid;
    gap: 4px;
    width: 100%;
    height: auto;
    min-width: 0;
    padding: 10px;
    overflow: hidden;
    text-align: left;
    background: var(--bg-card);
    opacity: 1;
  }

  .notification-popover-item strong,
  .notification-popover-item small {
    position: relative;
    z-index: 1;
    min-width: 0;
    overflow: hidden;
    overflow-wrap: anywhere;
  }

  .mode-tabs {
    display: none;
    overflow-x: visible;
    border-bottom: 1px solid rgba(94, 234, 212, 0.16);
  }

  .mode-tabs.open {
    display: grid;
    grid-template-columns: 1fr;
  }

  .tab-language-switcher {
    display: none !important;
    grid-template-columns: 1fr;
    margin-left: 0;
  }

  .audition-panel {
    right: 10px;
    top: max(10px, env(safe-area-inset-top));
    bottom: max(10px, env(safe-area-inset-bottom));
    left: 10px;
    height: calc(100dvh - 20px - env(safe-area-inset-top) - env(safe-area-inset-bottom));
    max-height: none;
    padding-bottom: 20px;
    overflow-x: hidden;
  }

  .audition-sticky {
    position: static;
    top: auto;
    margin: -12px -12px 10px;
    padding: 8px 12px 7px;
  }

  .load-more-button {
    margin-bottom: 28px;
  }

  .mobile-quick-nav {
    display: none !important;
  }

  .mode-tabs,
  .section-heading,
  .audition-header,
  .diary-state header,
  .state-header {
    align-items: stretch;
    flex-direction: column;
  }

  .audition-panel {
    right: 10px;
    top: max(10px, env(safe-area-inset-top));
    bottom: max(10px, env(safe-area-inset-bottom));
    left: 10px;
    height: calc(100dvh - 20px - env(safe-area-inset-top) - env(safe-area-inset-bottom));
    max-height: none;
    padding: 12px;
    padding-bottom: 20px;
    overflow-x: hidden;
  }

  .workspace-guide-grid {
    grid-template-columns: 1fr;
  }

  .audition-actions {
    display: grid;
    grid-template-columns: 1fr;
    justify-content: stretch;
    position: sticky;
    bottom: 76px;
    z-index: 9;
    padding: 8px;
    border: 1px solid rgba(94, 234, 212, 0.22);
    border-radius: 8px;
    background: var(--bg-panel);
    box-shadow: 0 -12px 24px rgba(0, 0, 0, 0.24);
  }

  .audition-actions a,
  .audition-actions button,
  .audition-actions .external-search-picker,
  .audition-actions .external-search-picker label,
  .diary-entry-actions a,
  .diary-entry-actions button {
    width: 100%;
  }

  .audition-actions .external-search-picker {
    display: grid;
    grid-template-columns: minmax(0, 1fr) max-content;
    align-items: end;
    max-width: none;
  }

  .audition-actions .external-search-picker label {
    min-width: 0;
  }

  .audition-actions .external-search-picker a {
    width: auto;
    min-width: 58px;
    max-width: 100%;
    padding-inline: 10px;
  }

  .audition-actions .audition-close {
    position: fixed;
    top: max(18px, env(safe-area-inset-top));
    right: 18px;
    z-index: 12;
    width: 44px;
    min-width: 44px;
    min-height: 44px;
  }

  .primary-button {
    width: 100%;
  }

  .state-title-row {
    align-items: stretch;
    flex-direction: column;
  }

  .timeline-summary-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .timeline-item-summary {
    grid-template-columns: 64px minmax(0, 1fr);
    gap: 10px;
    padding: 10px;
  }

  .player-strip {
    grid-template-columns: 1fr;
  }

  .state-title-chip,
  .player-strip .preview-trigger {
    width: 100%;
  }

  .time-block {
    min-height: 46px;
    padding: 6px;
    font-size: 0.72rem;
  }

  .timeline-title {
    font-size: 0.92rem;
  }

  .timeline-kicker {
    font-size: 0.72rem;
    line-height: 1.3;
  }

  .timeline-content {
    padding: 0 10px 10px 10px;
  }

  .timeline-action-bar {
    grid-template-columns: 1fr;
  }

  #creatorMode.journey-created .journey-output {
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
  }

  #creatorMode.journey-created .journey-output > .section-heading,
  #creatorMode.journey-created .journey-output .journey-progress {
    display: none;
  }

  .timeline-phase-group,
  .timeline-item,
  .timeline-content,
  .timeline-action-bar,
  .timeline-action-copy,
  .timeline-action-buttons,
  .player-strip,
  .state-title-row,
  .timeline-summary-actions {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    overflow-x: hidden;
  }

  .timeline-content *,
  .timeline-action-bar *,
  .player-strip * {
    max-width: 100%;
    min-width: 0;
    overflow-wrap: anywhere;
  }

  .timeline-action-buttons,
  .state-title-row,
  .timeline-summary-actions {
    display: grid;
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .timeline-status-badge,
  .diary-shortcut-button,
  .used-before-note {
    width: 100%;
  }

  .timeline-action-buttons .primary-button {
    width: 100%;
  }

  .state-brief-row {
    grid-template-columns: 28px 1fr;
  }

  .state-brief-row em {
    grid-column: 2;
  }

  .meta-grid,
  .detail-grid,
  .highlight-grid,
  .profile-shell,
  .admin-workspace,
  .admin-stat-grid,
  .admin-marker-form,
  .admin-form-grid,
  .preview-card {
    grid-template-columns: 1fr;
  }

  .preview-grid,
  .preview-card,
  .preview-body,
  .preview-topline,
  .preview-meta-row,
  .preview-source-button {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    overflow-wrap: anywhere;
  }

  .preview-card {
    overflow: hidden;
    padding: 8px;
  }

  .preview-cover {
    max-width: 100%;
  }

  .preview-panel-toolbar {
    position: sticky;
    bottom: 0;
    z-index: 8;
    grid-template-columns: 1fr;
    gap: 14px;
    padding: 8px;
    border: 1px solid rgba(94, 234, 212, 0.2);
    border-radius: 8px;
    background: var(--bg-panel);
    box-shadow: 0 -14px 30px rgba(0, 0, 0, 0.28);
  }

  .preview-mobile-tools {
    width: 100%;
  }

  .preview-mobile-tools summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 40px;
    padding: 8px 10px;
    border: 1px solid rgba(94, 234, 212, 0.26);
    border-radius: 8px;
    background: rgba(94, 234, 212, 0.12);
    color: var(--action);
    font-weight: 950;
    cursor: pointer;
  }

  .preview-mobile-tools summary::after {
    content: "+";
    font-weight: 950;
  }

  .preview-mobile-tools[open] summary::after {
    content: "-";
  }

  .preview-filter-strip {
    display: grid;
    grid-template-columns: 1fr;
    gap: 8px;
    margin-top: 8px;
    padding: 8px;
    border-radius: 8px;
    overflow: hidden;
  }

  .preview-format-filter,
  .preview-access-filter,
  .satellite-filter-row,
  .preview-duration-filter,
  .preview-search-submit {
    width: 100%;
  }

  .preview-mixer-bar.compact-mixer {
    width: 100%;
    min-width: 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    align-items: center;
    gap: 8px;
  }

  .preview-mixer-bar.compact-mixer > div {
    display: none;
  }

  .preview-mixer-bar.compact-mixer strong {
    margin-bottom: 0;
    font-size: 0.84rem;
  }

  .preview-mixer-bar.compact-mixer [data-preview-mixer-summary] {
    display: none;
  }

  .preview-master-control {
    min-width: 0;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
  }

  .preview-master-control span {
    font-size: 0;
  }

  .preview-master-control span::after {
    content: "VOL";
    color: var(--text-secondary);
    font-size: 0.74rem;
    font-weight: 950;
  }

  .preview-audio-shell {
    grid-template-columns: minmax(0, 1fr) 38px;
  }

  body.playlist-editing .active-journey-tools .close-playlist-button,
  body.playlist-editing .active-journey-tools .active-journey-status,
  body.playlist-editing .active-journey-tools .active-journey-inline-shortcut,
  body.playlist-editing .active-journey-tools [data-open-sync-status],
  body.playlist-editing .workspace-quick-nav {
    display: none !important;
  }

  body.playlist-editing .active-journey-tools .notifications-status-wrap {
    width: 100%;
  }

  body.playlist-editing .active-journey-tools .live-status-wrap {
    display: none;
  }

  .facilitator-sidebar .sidebar-brand {
    display: grid;
    order: 0;
    margin-top: 8px;
    min-height: 72px;
    grid-template-columns: 52px minmax(0, 1fr);
    border-radius: 8px;
  }

  .facilitator-sidebar .facilitator-sidebar-toggle {
    display: none;
  }

  .facilitator-sidebar {
    overflow-x: hidden;
  }

  body.facilitator-shell .mode-panel,
  body.client-shell .mode-panel {
    padding-left: 8px;
    padding-right: 8px;
  }

  body.facilitator-shell .profile-board.facilitator-board,
  body.client-shell .profile-board.facilitator-board,
  .facilitator-workview-stack,
  .facilitator-card,
  .profile-card,
  .history-entry,
  .playlist-manage-card,
  .followup-assignment-card,
  .followup-assignment-body,
  .followup-assignment-summary {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    overflow-x: hidden;
  }

  .followup-assignment-body *,
  .followup-assignment-summary *,
  .facilitator-card * {
    max-width: 100%;
    min-width: 0;
    overflow-wrap: anywhere;
  }

  .profile-card:not(.profile-section) * {
    max-width: 100%;
    min-width: 0;
    overflow-wrap: anywhere;
  }

  .followup-assignment-body input,
  .followup-assignment-body textarea,
  .followup-assignment-body select,
  .followup-assignment-body button,
  .facilitator-card textarea,
  .facilitator-card input,
  .facilitator-card button {
    width: 100%;
  }

  .followup-assignment-summary {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .followup-assignment-summary small {
    text-align: left;
  }

  .preview-volume-slider {
    min-height: 88px;
  }

  .preview-volume-fader {
    width: 18px;
    height: 88px;
  }

  .profile-side-nav {
    position: static;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .facilitator-sidebar-footer,
  .facilitator-sidebar-groups {
    gap: 8px;
  }

  .admin-menu-toggle {
    display: flex;
    justify-content: center;
  }

  .admin-workspace {
    grid-template-columns: 1fr;
    grid-template-rows: auto;
  }

  .admin-menu-toggle,
  .admin-side-nav,
  .admin-content {
    grid-column: auto;
    grid-row: auto;
  }

  .email-template-editor-shell {
    padding: 14px;
  }

  .email-template-mode-row {
    align-items: stretch;
    flex-direction: column;
  }

  .email-mode-toggle {
    width: 100%;
  }

  .email-mode-toggle button {
    flex: 1 1 50%;
  }

  .email-editor-toolbar {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .email-editor-toolbar button,
  .email-editor-toolbar select,
  .email-color-control {
    width: 100%;
  }

  .email-editor-surface,
  .email-editor-html {
    min-height: 240px;
    padding: 16px;
  }

  .admin-side-nav {
    display: none;
    position: static;
    grid-template-columns: 1fr;
  }

  .admin-side-nav.open {
    display: grid;
  }

  .review-admin-summary {
    grid-template-columns: 1fr;
  }

  .review-waveform-player {
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }

  .review-waveform-duration {
    justify-self: stretch;
    grid-column: 1 / -1;
    text-align: center;
  }

  .timeline-marker {
    width: 9px;
    height: 48px;
  }

  .timeline-marker span {
    top: -24px;
    max-width: 96px;
    font-size: 0.62rem;
  }

  .review-admin-header,
  .review-admin-summary,
  .review-status-row,
  .review-admin-actions,
  .history-journey-block summary {
    align-items: stretch;
    flex-direction: column;
  }

  .review-status-row.review-status-row-compact,
  .followup-edit-form {
    grid-template-columns: 1fr;
  }

  .admin-list-item {
    align-items: stretch;
    flex-direction: column;
  }

  .workspace-360-modal-card {
    width: 100%;
    max-height: calc(100vh - 24px);
    padding: 16px;
  }

  .workspace-360-header,
  .workspace-360-grid,
  .workspace-360-usage-grid {
    grid-template-columns: 1fr;
  }

  .workspace-360-badges,
  .workspace-360-section-head,
  .workspace-360-usage-head {
    align-items: stretch;
    flex-direction: column;
  }

  .workspace-360-badges .admin-health-badge {
    width: 100%;
    justify-content: center;
  }

  .workspace-360-health-summary {
    width: 100%;
    min-width: 0;
  }

  .workspace-360-audit-meta span {
    max-width: 100%;
  }

  .preview-cover {
    width: 100%;
    height: 120px;
  }
}

@media (max-width: 780px) and (orientation: portrait) {
  .review-landscape-hint {
    display: block;
  }
}

/* Workspace surface trial: remove the extra dark container shell. */
body.facilitator-shell .mode-panel.active,
body.client-shell .mode-panel.active {
  background: var(--bg-workspace) !important;
}

body.facilitator-shell .profile-board,
body.client-shell .profile-board,
body.facilitator-shell .diary-board,
body.client-shell .diary-board,
body.facilitator-shell .profile-board.facilitator-board,
body.client-shell .profile-board.facilitator-board {
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

@media (max-width: 640px) {
  .session-player-head {
    align-items: stretch;
    flex-direction: column;
  }

  .session-player-time {
    align-self: flex-start;
  }

  .session-player-actions,
  .session-player-transport,
  .session-player-secondary-controls {
    width: 100%;
  }

  .session-player-transport {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

  .session-player-icon-button {
    width: 100%;
    min-width: 0;
  }

  .session-player-state-button {
    width: 100%;
    justify-content: center;
  }

  .session-player-monitor,
  .session-player-volume {
    width: 100%;
  }

  .session-player-volume {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
  }

  .session-player-volume input {
    width: 100%;
  }

  .session-player-waveform .waveform-bars {
    gap: 1px;
    padding: 0 8px;
  }

  .session-player-waveform .waveform-bars span {
    min-width: 1px;
  }

  .inbox-conversation-summary {
    grid-template-columns: auto minmax(0, 1fr);
    align-items: start;
    padding: 13px;
  }

  .inbox-conversation-side {
    grid-column: 2;
    grid-template-columns: auto auto auto;
    justify-content: start;
    justify-items: start;
    min-width: 0;
  }

  .inbox-conversation-topline {
    display: grid;
    gap: 2px;
  }

  .inbox-conversation-topline span {
    font-size: 0.74rem;
  }

  .inbox-conversation-panel {
    padding: 0 12px 14px;
  }

  .inbox-conversation-messages {
    max-height: 66vh;
    padding: 10px;
  }

  .inbox-chat-bubble {
    width: min(88%, 100%);
  }

  .inbox-chat-bubble.therapist {
    justify-self: end;
  }

  .inbox-chat-bubble.client {
    justify-self: start;
  }

  .app-confirm-card {
    width: 100%;
    padding: 18px;
  }

  .app-confirm-actions {
    flex-direction: column-reverse;
    align-items: stretch;
  }

  .app-confirm-actions button {
    width: 100%;
  }
}

.admin-action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.demo-access-list {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}

.demo-access-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 14px;
  border: 1px solid rgba(79, 209, 197, 0.28);
  border-radius: 8px;
  background: rgba(18, 62, 82, 0.72);
}

.demo-access-card.expired {
  border-color: rgba(245, 158, 11, 0.45);
}

.demo-access-card strong,
.demo-access-card span,
.demo-access-card small {
  display: block;
}

.demo-access-card small {
  color: var(--text-secondary);
}

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

.demo-source-locked-note,
.preview-source-action-button.is-demo-source-locked {
  display: inline-flex;
  align-items: center;
  max-width: 100%;
  padding: 8px 10px;
  border: 1px solid rgba(79, 209, 197, 0.28);
  border-radius: 8px;
  background: rgba(3, 10, 16, 0.72);
  color: var(--text-soft);
  font-size: 0.82rem;
  line-height: 1.35;
}

.preview-source-button.is-demo-source-locked {
  cursor: default;
}

.demo-locked-external {
  border: 1px solid rgba(79, 209, 197, 0.34);
  border-radius: 8px;
  background: rgba(18, 62, 82, 0.78);
  color: var(--accent);
  font: inherit;
  font-weight: 800;
  padding: 10px 14px;
}

@media (max-width: 760px) {
  .session-create-fields {
    display: block;
  }

  .session-create-fields > label,
  .session-create-fields > .session-site-summary {
    display: block;
    margin-bottom: 12px;
  }

  .form-section-title {
    margin: 4px 0 8px;
  }

  .address-form-grid .address-field-postal {
    max-width: none;
  }

  .session-site-filter-panel,
  .session-site-detail-grid {
    grid-template-columns: 1fr;
  }

  .site-price-range {
    grid-column: 1;
  }

  .session-site-detail-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .session-calendar-shell {
    overflow-x: hidden;
  }

  .session-calendar-weekdays,
  .session-calendar-grid {
    min-width: 0;
    gap: 4px;
  }

  .session-calendar-cell {
    min-height: 46px;
    padding: 5px;
  }

  .session-calendar-cell small {
    display: none;
  }

  .session-site-gallery-preview,
  .session-public-gallery {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .demo-access-card {
    grid-template-columns: 1fr;
  }

  .demo-access-actions {
    justify-content: stretch;
  }

  .demo-access-actions button {
    flex: 1 1 140px;
  }

  .admin-audit-filters {
    grid-template-columns: 1fr;
  }

  .admin-health-overall {
    align-items: flex-start;
    flex-direction: column;
  }

  .admin-health-overall-chips {
    justify-content: flex-start;
  }

  .admin-audit-filter-search,
  .admin-audit-filter-limit {
    grid-column: auto;
    max-width: none;
  }

  .admin-audit-event {
    display: grid;
  }

  .admin-audit-side {
    width: 100%;
    text-align: left;
  }
}

@media (max-width: 900px) {
  body.facilitator-shell:not(.playlist-editing) .top-workbar,
  body.client-shell .top-workbar {
    overflow: visible;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-bar,
  body.facilitator-shell:not(.playlist-editing) .active-journey-tools,
  body.facilitator-shell:not(.playlist-editing) .notifications-status-wrap,
  body.client-shell .active-journey-bar,
  body.client-shell .active-journey-tools,
  body.client-shell .notifications-status-wrap {
    position: static;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-tools .notifications-popover,
  body.client-shell .active-journey-tools .notifications-popover {
    position: fixed;
    top: calc(env(safe-area-inset-top, 0px) + 62px);
    left: max(12px, env(safe-area-inset-left, 0px));
    right: max(12px, env(safe-area-inset-right, 0px));
    z-index: 240;
    width: auto;
    max-width: none;
    max-height: min(52vh, 360px);
    max-height: min(52svh, 360px);
    overflow-x: hidden;
    overflow-y: auto;
    box-sizing: border-box;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-tools .header-notification-button,
  body.client-shell .active-journey-tools .header-notification-button {
    inline-size: 42px;
    min-inline-size: 42px;
    max-inline-size: 42px;
    block-size: 40px;
    min-block-size: 40px;
    flex: 0 0 42px;
  }

  body.client-shell .active-journey-tools .header-notification-button {
    block-size: 44px;
    min-block-size: 44px;
  }
}

@media (max-width: 900px) {
  body.client-shell .top-workbar {
    align-items: center;
    display: flex;
    justify-content: space-between;
  }

  body.client-shell .mobile-menu-toggle {
    flex: 0 0 44px;
  }

  body.client-shell .active-journey-bar {
    display: flex;
    flex: 1 1 auto;
    justify-content: flex-end;
    margin-left: auto;
    min-width: 0;
  }

  body.client-shell .active-journey-tools.client-header-tools {
    align-items: center;
    display: flex;
    flex: 0 0 auto;
    gap: 6px;
    justify-content: flex-end;
    margin-left: auto;
    width: auto;
  }

  body.client-shell .client-header-account-wrap {
    order: 1;
  }

  body.client-shell .client-messages-wrap {
    order: 2;
  }

  body.client-shell .client-header-tools .header-theme-switch,
  body.client-shell .client-header-tools .client-priority-wrap,
  body.client-shell .client-header-tools .client-practitioner-header-pill {
    display: none !important;
  }
}

@media (max-width: 420px) {
  .audition-actions .external-search-picker {
    grid-template-columns: minmax(0, 1fr) max-content;
  }

  .playlist-manage-actions,
  .button-row {
    grid-template-columns: 1fr;
  }

  .workspace-today-actions,
  .workspace-quick-actions,
  .saas-therapist-actions {
    grid-template-columns: 1fr;
  }

  .primary-button,
  .secondary-button,
  .ghost-button,
  .danger-button {
    padding-inline: 11px;
    font-size: 0.84rem;
  }

  .compact-button {
    padding-inline: 9px;
    font-size: 0.78rem;
  }

  .session-player-icon-button.primary-button,
  .session-player-icon-button.secondary-button,
  .header-system-tools .compact-button,
  .active-journey-tools .compact-button {
    width: auto;
  }
}

@media (max-width: 340px) {
  .audition-actions .external-search-picker {
    grid-template-columns: 1fr;
  }

  .audition-actions .external-search-picker a {
    width: 100%;
  }
}

label:has(input[required]) .field-label-text::after,
label:has(select[required]) .field-label-text::after,
label:has(textarea[required]) .field-label-text::after {
  content: " *";
  color: var(--state-danger);
  font-weight: 700;
}

/* Mailchimp-style practitioner shell: flat navigation, compact workspaces, account menu */
body.facilitator-shell {
  background: #08131c;
}

body.client-shell {
  background: #08131c;
}

html[data-theme="light"] body.facilitator-shell {
  background: #f6f8f9;
}

html[data-theme="light"] body.client-shell {
  background: #f6f8f9;
}

body.facilitator-shell:not(.playlist-editing) .app-shell {
  padding-left: 270px;
  background: #0f1b27;
}

body.client-shell .app-shell {
  padding-left: 270px;
  background: #0f1b27;
}

body.facilitator-sidebar-collapsed.facilitator-shell:not(.playlist-editing) .app-shell,
body.facilitator-sidebar-collapsed.client-shell .app-shell {
  padding-left: 72px;
}

@media (max-width: 900px) {
  body.facilitator-shell:not(.playlist-editing) .app-shell,
  body.client-shell .app-shell,
  body.facilitator-sidebar-collapsed.facilitator-shell:not(.playlist-editing) .app-shell,
  body.facilitator-sidebar-collapsed.client-shell .app-shell {
    padding-left: 0;
  }
}

html[data-theme="light"] body.facilitator-shell:not(.playlist-editing) .app-shell {
  background: #f6f8f9;
}

html[data-theme="light"] body.client-shell .app-shell {
  background: #f6f8f9;
}

body.facilitator-shell:not(.playlist-editing) .app-shell::before,
body.facilitator-shell:not(.playlist-editing) .app-shell::after,
body.client-shell .app-shell::before,
body.client-shell .app-shell::after {
  display: none;
}

body.facilitator-shell:not(.playlist-editing) .facilitator-sidebar,
body.client-shell .facilitator-sidebar {
  background: #0b121c;
  border-right: 0;
  box-shadow: none;
}

html[data-theme="light"] body.facilitator-shell:not(.playlist-editing) .facilitator-sidebar,
html[data-theme="light"] body.client-shell .facilitator-sidebar {
  background: #e6f1f5;
  border-right: 1px solid #d0e1e8;
}

body.facilitator-shell:not(.playlist-editing) .facilitator-sidebar-head,
body.facilitator-shell:not(.playlist-editing) .facilitator-sidebar-footer,
body.client-shell .facilitator-sidebar-head,
body.client-shell .facilitator-sidebar-footer {
  border-color: rgba(226, 232, 240, 0.1);
}

html[data-theme="light"] body.facilitator-shell:not(.playlist-editing) .facilitator-sidebar-head,
html[data-theme="light"] body.facilitator-shell:not(.playlist-editing) .facilitator-sidebar-footer,
html[data-theme="light"] body.client-shell .facilitator-sidebar-head,
html[data-theme="light"] body.client-shell .facilitator-sidebar-footer {
  border-color: rgba(15, 23, 42, 0.1);
}

body.facilitator-shell:not(.playlist-editing) .sidebar-brand,
body.facilitator-shell:not(.playlist-editing) .facilitator-sidebar-toggle,
body.client-shell .sidebar-brand,
body.client-shell .facilitator-sidebar-toggle {
  background: transparent;
  border-color: transparent;
  box-shadow: none;
}

body.facilitator-shell:not(.playlist-editing) .sidebar-brand,
body.client-shell .sidebar-brand {
  border-radius: 8px;
}

body.facilitator-shell:not(.playlist-editing) .sidebar-brand:hover,
body.facilitator-shell:not(.playlist-editing) .facilitator-sidebar-toggle:hover,
body.client-shell .sidebar-brand:hover,
body.client-shell .facilitator-sidebar-toggle:hover {
  background: rgba(79, 209, 197, 0.1);
  border-color: rgba(79, 209, 197, 0.18);
}

body.client-shell .facilitator-sidebar-toggle {
  display: none;
}

@media (min-width: 901px) {
  body.facilitator-shell:not(.playlist-editing) .facilitator-sidebar-toggle {
    display: none;
  }

  body.facilitator-sidebar-collapsed.facilitator-shell:not(.playlist-editing) .facilitator-sidebar:not(.facilitator-sidebar-hover-suppressed):hover,
  body.facilitator-sidebar-collapsed.client-shell .facilitator-sidebar:not(.facilitator-sidebar-hover-suppressed):hover {
    width: 270px;
    padding: 18px 14px 16px;
  }

  body.facilitator-sidebar-collapsed.facilitator-shell:not(.playlist-editing) .facilitator-sidebar:not(.facilitator-sidebar-hover-suppressed):hover .sidebar-brand,
  body.facilitator-sidebar-collapsed.client-shell .facilitator-sidebar:not(.facilitator-sidebar-hover-suppressed):hover .sidebar-brand {
    grid-template-columns: 64px minmax(0, 1fr);
    min-height: 92px;
    padding: 14px 16px;
  }

  body.facilitator-sidebar-collapsed.facilitator-shell:not(.playlist-editing) .facilitator-sidebar:not(.facilitator-sidebar-hover-suppressed):hover .sidebar-brand-copy,
  body.facilitator-sidebar-collapsed.facilitator-shell:not(.playlist-editing) .facilitator-sidebar:not(.facilitator-sidebar-hover-suppressed):hover .nav-label,
  body.facilitator-sidebar-collapsed.client-shell .facilitator-sidebar:not(.facilitator-sidebar-hover-suppressed):hover .sidebar-brand-copy,
  body.facilitator-sidebar-collapsed.client-shell .facilitator-sidebar:not(.facilitator-sidebar-hover-suppressed):hover .nav-label {
    display: block;
  }

  body.facilitator-sidebar-collapsed.facilitator-shell:not(.playlist-editing) .facilitator-sidebar:not(.facilitator-sidebar-hover-suppressed):hover .sidebar-brand-media,
  body.facilitator-sidebar-collapsed.client-shell .facilitator-sidebar:not(.facilitator-sidebar-hover-suppressed):hover .sidebar-brand-media {
    height: 64px;
    width: 64px;
  }
}

.sidebar-section-label {
  display: none;
}

.facilitator-sidebar-groups .sidebar-main-link {
  align-items: center;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 8px;
  color: var(--text-soft);
  display: grid;
  font-weight: 760;
  gap: 11px;
  grid-template-columns: 28px minmax(0, 1fr);
  justify-items: start;
  min-height: 42px;
  padding: 9px 12px;
  text-align: left;
  width: 100%;
}

html[data-theme="light"] .facilitator-sidebar-groups .sidebar-main-link {
  color: #365d70;
}

html[data-theme="light"] .sidebar-brand-copy strong {
  color: #082535;
  font-weight: 800;
}

html[data-theme="light"] .sidebar-brand-copy span,
html[data-theme="light"] .sidebar-section-label {
  color: #637f8d;
}

.facilitator-sidebar-groups .sidebar-main-link:hover {
  background: rgba(79, 209, 197, 0.09);
  color: var(--text-primary);
}

.facilitator-sidebar-groups .sidebar-main-link.active {
  background: rgba(79, 209, 197, 0.14);
  border-color: rgba(79, 209, 197, 0.22);
  color: var(--accent);
}

.sidebar-collapse-button {
  align-items: center;
  background: rgba(79, 209, 197, 0.08);
  border: 1px solid rgba(79, 209, 197, 0.22);
  border-radius: 8px;
  color: var(--accent);
  display: grid;
  gap: 8px;
  height: 38px;
  grid-template-columns: 22px minmax(0, 1fr);
  justify-content: start;
  justify-self: stretch;
  min-height: 38px;
  padding: 0 12px;
  width: 100%;
}

.sidebar-collapse-button .nav-icon {
  display: inline-grid;
  height: 22px;
  place-items: center;
  width: 22px;
}

.sidebar-collapse-button .nav-label {
  justify-self: start;
  line-height: 1;
  text-align: left;
}

.sidebar-collapse-button .nav-icon svg {
  fill: none;
  height: 22px;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
  width: 22px;
}

.sidebar-collapse-button:hover {
  background: rgba(79, 209, 197, 0.16);
  border-color: rgba(79, 209, 197, 0.34);
}

body.facilitator-sidebar-collapsed .sidebar-collapse-button .nav-icon {
  transform: rotate(180deg);
}

body.facilitator-sidebar-collapsed .sidebar-collapse-button {
  grid-template-columns: 1fr;
  justify-self: center;
  padding: 0;
  width: 38px;
}

body.facilitator-sidebar-collapsed .sidebar-collapse-button .nav-label {
  display: none;
}

body.facilitator-sidebar-collapsed .facilitator-sidebar-groups .sidebar-main-link {
  align-items: center;
  grid-template-columns: 1fr;
  justify-items: center;
  min-height: 48px;
  padding: 0;
  width: 48px;
}

body.facilitator-sidebar-collapsed.client-shell .facilitator-sidebar-groups .sidebar-main-link,
body.facilitator-sidebar-collapsed.client-shell .facilitator-sidebar-groups {
  justify-self: center;
}

body.facilitator-sidebar-collapsed.client-shell .client-sidebar-status-card {
  display: none;
}

body.facilitator-sidebar-collapsed .facilitator-sidebar-groups .sidebar-main-link .nav-icon {
  margin: 0;
  justify-self: center;
}

body.facilitator-sidebar-collapsed .facilitator-sidebar-groups .sidebar-main-link .nav-icon svg {
  width: 23px;
  height: 23px;
}

body.facilitator-sidebar-collapsed .facilitator-sidebar:not(.facilitator-sidebar-hover-suppressed):hover .facilitator-sidebar-groups .sidebar-main-link {
  grid-template-columns: 28px minmax(0, 1fr);
  justify-items: start;
  min-height: 42px;
  padding: 9px 12px;
  width: 100%;
}

body.facilitator-sidebar-collapsed.facilitator-shell:not(.playlist-editing) .facilitator-sidebar:not(.facilitator-sidebar-hover-suppressed):hover .sidebar-collapse-button,
body.facilitator-sidebar-collapsed.client-shell .facilitator-sidebar:not(.facilitator-sidebar-hover-suppressed):hover .sidebar-collapse-button {
  grid-template-columns: 1fr;
  justify-self: center;
  padding: 0;
  width: 38px;
}

body.facilitator-sidebar-collapsed.facilitator-shell:not(.playlist-editing) .facilitator-sidebar:not(.facilitator-sidebar-hover-suppressed):hover .sidebar-collapse-button .nav-label,
body.facilitator-sidebar-collapsed.client-shell .facilitator-sidebar:not(.facilitator-sidebar-hover-suppressed):hover .sidebar-collapse-button .nav-label {
  display: none;
}

body.facilitator-shell:not(.playlist-editing) .top-workbar,
body.client-shell .top-workbar {
  background: #08131c;
  border-bottom: 1px solid rgba(226, 232, 240, 0.1);
  box-shadow: none;
}

html[data-theme="light"] body.facilitator-shell:not(.playlist-editing) .top-workbar,
html[data-theme="light"] body.client-shell .top-workbar {
  background: #ffffff;
  border-bottom-color: rgba(15, 23, 42, 0.12);
}

body.facilitator-shell:not(.playlist-editing) .mode-panel.active,
body.client-shell .mode-panel.active {
  background: #0f1b27;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

html[data-theme="light"] body.facilitator-shell:not(.playlist-editing) .mode-panel.active,
html[data-theme="light"] body.client-shell .mode-panel.active {
  background: #f6f8f9;
}

body.facilitator-shell:not(.playlist-editing) .top-workbar,
body.client-shell .top-workbar {
  background: #08131c;
  border: 0;
  border-bottom: 1px solid rgba(226, 232, 240, 0.1);
  border-radius: 0;
  box-shadow: none !important;
  margin: 0;
  padding: 20px 34px;
}

body.facilitator-shell:not(.playlist-editing) .top-workbar::before,
body.facilitator-shell:not(.playlist-editing) .top-workbar::after,
body.client-shell .top-workbar::before,
body.client-shell .top-workbar::after {
  content: none !important;
  display: none !important;
}

html[data-theme="light"] body.facilitator-shell:not(.playlist-editing) .top-workbar,
html[data-theme="light"] body.client-shell .top-workbar {
  background: #ffffff;
}

body.facilitator-shell:not(.playlist-editing) .mode-panel.active,
body.client-shell .mode-panel.active {
  border: 0;
  border-radius: 0;
  margin: 0;
  padding: 34px;
  box-shadow: none !important;
}

html[data-theme="light"] body.facilitator-shell:not(.playlist-editing) .mode-panel.active,
html[data-theme="light"] body.client-shell .mode-panel.active {
  border: 0;
  box-shadow: none !important;
}

body.facilitator-shell:not(.playlist-editing) .profile-card,
body.facilitator-shell:not(.playlist-editing) .workspace-context-box,
body.facilitator-shell:not(.playlist-editing) .workspace-overview-card,
body.facilitator-shell:not(.playlist-editing) .clients-overview-panel,
body.facilitator-shell:not(.playlist-editing) .clients-overview-metric,
body.client-shell .profile-card,
body.client-shell .workspace-context-box,
body.client-shell .history-entry {
  box-shadow: none;
}

.workspace-page-heading {
  align-items: flex-start;
  border-bottom: 1px solid var(--line);
  margin-bottom: 14px;
  padding-bottom: 16px;
}

.workspace-page-heading > div > .eyebrow {
  display: none;
}

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

.workspace-page-actions [data-facilitator-route="music-create"] {
  inline-size: 132px;
  justify-content: center;
}

.workspace-tabs {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 16px;
}

.workspace-breadcrumbs {
  align-items: center;
  color: var(--text-secondary);
  display: flex;
  flex-wrap: wrap;
  font-size: 0.78rem;
  font-weight: 750;
  gap: 6px;
  letter-spacing: 0;
  margin: 0 0 8px;
  opacity: 0.82;
}

.profile-workspace-tabs {
  display: none;
}

body.profile-workspace-route .profile-workspace-tabs {
  display: flex;
}

.workspace-tab-group-label {
  color: var(--text-secondary);
  font-size: 0.68rem;
  font-weight: 950;
  letter-spacing: 0.12em;
  margin: 0 2px 0 10px;
  opacity: 0.72;
  text-transform: uppercase;
}

.workspace-tab-group-label:first-child {
  margin-left: 0;
}

.workspace-tab {
  background: transparent;
  border: 1px solid transparent;
  border-radius: 8px;
  color: var(--text-secondary);
  font: inherit;
  font-weight: 800;
  min-height: 38px;
  padding: 8px 12px;
}

.workspace-tab:hover {
  background: rgba(79, 209, 197, 0.1);
  color: var(--text-primary);
}

.workspace-tab.active {
  background: rgba(79, 209, 197, 0.14);
  border-color: rgba(79, 209, 197, 0.28);
  color: var(--accent);
}

.hostinger-profile-section {
  background: transparent;
  border: 0;
  padding: 12px 0 0;
}

.hostinger-profile-section > h3 {
  margin: 0 0 14px;
  padding-inline: 2px;
}

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

.hostinger-settings-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  gap: 14px;
  padding: 16px;
}

html[data-theme="light"] .hostinger-settings-card {
  background: #ffffff;
}

.hostinger-settings-card.wide-field,
.brand-image-card {
  grid-column: 1 / -1;
}

.hostinger-card-head {
  align-items: center;
  display: grid;
  gap: 12px;
  grid-template-columns: 42px minmax(0, 1fr);
}

.hostinger-card-head h4 {
  color: var(--text-primary);
  font-size: 1rem;
  margin: 0;
}

.hostinger-card-head p {
  color: var(--text-secondary);
  font-size: 0.84rem;
  line-height: 1.4;
  margin: 2px 0 0;
}

.hostinger-card-icon {
  align-items: center;
  background: rgba(79, 209, 197, 0.1);
  border: 1px solid rgba(79, 209, 197, 0.2);
  border-radius: 8px;
  color: var(--accent);
  display: inline-flex;
  font-size: 1rem;
  font-weight: 900;
  height: 42px;
  justify-content: center;
  width: 42px;
}

.image-upload-field {
  display: grid;
  gap: 8px;
}

.image-upload-field > span {
  color: var(--text-secondary);
  font-size: 0.88rem;
  font-weight: 850;
}

.image-upload-row {
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  gap: 8px;
  grid-template-columns: minmax(0, 1fr) auto;
  min-height: 48px;
  padding: 6px;
}

.image-upload-row input[type="file"] {
  border: 0;
  min-height: 34px;
  padding: 4px;
}

.image-upload-row .compact-button {
  min-height: 34px;
  padding-inline: 12px;
}

.professional-preview-row {
  align-items: end;
  background:
    linear-gradient(180deg, rgba(79, 209, 197, 0.12), rgba(79, 209, 197, 0.03)),
    var(--bg-panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  min-height: 180px;
  overflow: hidden;
  position: relative;
}

html[data-theme="light"] .professional-preview-row {
  background:
    linear-gradient(180deg, rgba(15, 142, 145, 0.12), rgba(255, 255, 255, 0.72)),
    #ffffff;
}

.professional-preview-row .header-photo-preview {
  border: 0;
  border-radius: 0;
  height: 132px;
  inset: 0 0 auto;
  object-fit: cover;
  position: absolute;
  width: 100%;
}

.professional-preview-row .profile-photo-preview {
  border: 3px solid var(--bg-card);
  border-radius: 8px;
  height: 86px;
  margin: 86px 0 18px 18px;
  object-fit: cover;
  position: relative;
  width: 86px;
  z-index: 1;
}

.professional-preview-row #facilitatorLogoPreview {
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: 8px;
  bottom: 18px;
  height: 54px;
  object-fit: contain;
  padding: 8px;
  position: absolute;
  right: 18px;
  width: 112px;
  z-index: 1;
}

.professional-preview-row .empty-brand-logo {
  margin: 86px 0 18px 18px;
  position: relative;
  z-index: 1;
}

.social-prefix-field {
  align-items: stretch;
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  min-height: var(--control-height);
  overflow: hidden;
}

.social-prefix-field > span {
  align-items: center;
  background: rgba(79, 209, 197, 0.08);
  border-right: 1px solid var(--line);
  color: var(--text-secondary);
  display: inline-flex;
  font-size: 0.82rem;
  font-weight: 850;
  padding: 0 10px;
  white-space: nowrap;
}

.social-prefix-field input {
  border: 0;
  border-radius: 0;
  min-height: 100%;
}

.email-field-row {
  align-items: stretch;
  display: grid;
  gap: 8px;
  grid-template-columns: minmax(0, 1fr) auto;
}

.phone-row {
  grid-template-columns: minmax(92px, 0.34fr) minmax(0, 1fr);
}

.session-sites-tabs {
  display: none;
}

.spaces-page-actions {
  display: none;
}

body.session-sites-route .sessions-calendar-tabs {
  display: none;
}

body.session-sites-route .sessions-page-actions {
  display: none;
}

body.session-sites-route .session-sites-tabs {
  display: flex;
}

body.session-sites-route .spaces-page-actions {
  display: flex;
}

.therapist-review-client-actions,
.therapist-review-client-tabs {
  display: none;
}

body.clients-review-route .therapist-review-playlist-actions,
body.clients-review-route .therapist-review-playlist-tabs {
  display: none;
}

body.clients-review-route .therapist-review-client-actions,
body.clients-review-route .therapist-review-client-tabs {
  display: flex;
}

.clients-overview-grid {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  margin-bottom: 14px;
}

.clients-overview-metric {
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid var(--line);
  border-radius: 8px;
  min-width: 0;
  padding: 14px;
}

html[data-theme="light"] .clients-overview-metric {
  background: #ffffff;
}

.clients-overview-metric strong {
  color: var(--text-primary);
  display: block;
  font-size: 1.35rem;
  line-height: 1;
}

.clients-overview-metric span,
.clients-overview-metric small {
  display: block;
}

.clients-overview-metric span {
  color: var(--text-primary);
  font-weight: 850;
  margin-top: 8px;
}

.clients-overview-metric small {
  color: var(--text-secondary);
  font-size: 0.78rem;
  margin-top: 4px;
}

.clients-overview-body {
  display: grid;
  gap: 14px;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

.clients-overview-panel {
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
}

html[data-theme="light"] .clients-overview-panel {
  background: #ffffff;
}

.clients-overview-row {
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text-primary);
  display: block;
  min-height: 0;
  padding: 11px 12px;
  text-align: left;
  width: 100%;
}

.clients-overview-row + .clients-overview-row {
  margin-top: 8px;
}

.clients-overview-row:hover {
  background: rgba(79, 209, 197, 0.1);
  border-color: rgba(79, 209, 197, 0.26);
}

.clients-overview-row strong,
.clients-overview-row span {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.clients-overview-row span {
  color: var(--text-secondary);
  font-size: 0.86rem;
  margin-top: 3px;
}

.header-account-wrap {
  position: relative;
}

.header-account-button {
  align-items: center;
  background: rgba(79, 209, 197, 0.09);
  border: 1px solid rgba(79, 209, 197, 0.22);
  border-radius: 999px;
  color: var(--text-primary);
  display: inline-flex;
  height: 48px;
  justify-content: center;
  min-height: 48px;
  padding: 0;
  width: 48px;
}

.header-account-button img,
.header-account-button > span,
.header-account-summary img,
.header-account-avatar {
  align-items: center;
  border-radius: 6px;
  display: inline-flex;
  height: 32px;
  justify-content: center;
  object-fit: cover;
  width: 32px;
}

.header-account-button > span,
.header-account-avatar {
  background: rgba(79, 209, 197, 0.16);
  color: var(--accent);
  font-weight: 900;
}

.header-account-popover {
  background: #101923;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text-primary);
  display: grid;
  gap: 8px;
  min-width: 300px;
  padding: 16px;
  position: absolute;
  right: 0;
  top: calc(100% + 10px);
  z-index: 245;
}

html[data-theme="light"] .header-account-popover {
  background: #ffffff;
}

.header-account-summary {
  align-items: center;
  border-bottom: 1px solid var(--line);
  display: grid;
  gap: 10px;
  grid-template-columns: 40px minmax(0, 1fr);
  margin-bottom: 4px;
  padding: 4px 4px 10px;
}

.header-account-summary strong,
.header-account-summary small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.header-account-summary small {
  color: var(--text-secondary);
  margin-top: 2px;
}

.header-account-popover button,
.header-account-language {
  align-items: center;
  background: transparent;
  border: 0;
  border-radius: 8px;
  color: var(--text-secondary);
  display: grid;
  font: inherit;
  font-size: 1rem;
  font-weight: 760;
  gap: 14px;
  grid-template-columns: 28px minmax(0, 1fr) max-content;
  min-height: 44px;
  padding: 10px 14px;
  text-align: left;
}

.header-account-popover button span:not(.account-menu-icon) {
  min-width: 0;
}

.account-menu-icon {
  color: var(--text-secondary);
  display: inline-grid;
  height: 28px;
  place-items: center;
  width: 28px;
}

.account-menu-icon svg {
  fill: none;
  height: 24px;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
  width: 24px;
}

.header-account-section {
  border-top: 1px solid var(--line);
  color: var(--accent);
  font-size: 0.7rem;
  font-weight: 950;
  letter-spacing: 0.12em;
  margin-top: 4px;
  padding: 12px 10px 3px;
  text-transform: uppercase;
}

.header-account-summary + .header-account-section {
  border-top: 0;
  margin-top: 0;
  padding-top: 4px;
}

.desktop-account-menu-group,
.mobile-account-menu-group {
  display: grid;
  gap: 4px;
}

.mobile-account-menu-group {
  display: none;
}

.header-account-popover button:hover,
.header-account-language:hover {
  background: rgba(79, 209, 197, 0.1);
  color: var(--text-primary);
}

.header-account-popover button:hover .account-menu-icon {
  color: var(--accent);
}

.header-account-language select {
  max-width: 76px;
  min-height: 30px;
  padding: 4px 8px;
}

@media (max-width: 1100px) {
  .clients-overview-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .workspace-page-heading {
    display: grid;
    gap: 12px;
  }

  .workspace-page-actions {
    justify-content: stretch;
  }

  .workspace-page-actions .compact-button {
    flex: 1 1 130px;
  }

  .clients-overview-grid,
  .clients-overview-body {
    grid-template-columns: 1fr;
  }

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

  .profile-side-nav {
    display: none;
  }

  .hostinger-profile-grid,
  .admin-form-grid,
  .profile-media-grid {
    grid-template-columns: 1fr;
  }

  .hostinger-settings-card {
    padding: 18px;
  }

  .profile-card.profile-section.active .hostinger-settings-card,
  .support-ticket-row {
    content-visibility: auto;
    contain-intrinsic-size: 260px;
  }

  .hostinger-card-head {
    align-items: flex-start;
  }

  .hostinger-card-head p {
    max-width: 36rem;
  }

  .email-field-row,
  .image-upload-row {
    grid-template-columns: 1fr;
  }

  .compact-email-status {
    justify-content: flex-start;
    min-height: 34px;
  }

  .header-account-popover {
    max-height: min(78vh, 620px);
    overflow-y: auto;
    overscroll-behavior: contain;
    position: fixed;
    right: max(12px, env(safe-area-inset-right, 0px));
    top: calc(env(safe-area-inset-top, 0px) + 62px);
    width: min(320px, calc(100vw - 24px));
  }

  .desktop-account-menu-group {
    display: none;
  }

  .mobile-account-menu-group {
    display: grid;
  }
}

@media (max-width: 900px) {
  body.facilitator-shell:not(.playlist-editing) .top-workbar,
  body.client-shell .top-workbar {
    align-items: center;
    display: grid;
    gap: 8px;
    grid-template-columns: 46px minmax(0, 1fr);
    grid-template-rows: 46px;
    min-height: 66px;
    padding: 10px 12px;
  }

  body.facilitator-shell:not(.playlist-editing) .mobile-menu-toggle,
  body.client-shell .mobile-menu-toggle,
  body.facilitator-shell:not(.playlist-editing) .facilitator-sidebar-toggle {
    align-items: center;
    border-radius: 8px;
    display: inline-grid;
    font-size: 0;
    grid-column: 1;
    grid-row: 1;
    height: 46px;
    justify-content: center;
    min-height: 46px;
    min-width: 46px;
    padding: 0;
    place-items: center;
    position: relative;
    width: 46px;
  }

  body.facilitator-shell:not(.playlist-editing) .mobile-menu-toggle::before,
  body.client-shell .mobile-menu-toggle::before {
    background:
      linear-gradient(currentColor, currentColor) center top / 27px 2.75px no-repeat,
      linear-gradient(currentColor, currentColor) center center / 27px 2.75px no-repeat,
      linear-gradient(currentColor, currentColor) center bottom / 27px 2.75px no-repeat;
    content: "";
    display: block;
    height: 19px;
    left: 50%;
    line-height: 1;
    margin: 0;
    position: absolute;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 27px;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-bar,
  body.client-shell .active-journey-bar {
    align-self: center;
    display: block;
    grid-column: 2;
    grid-row: 1;
    min-height: 46px;
    order: 0;
    width: 100%;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-tools,
  body.client-shell .active-journey-tools,
  body.client-shell .client-header-tools {
    align-items: center;
    display: flex;
    flex-wrap: nowrap;
    gap: 7px;
    height: 46px;
    justify-content: flex-end;
    min-width: 0;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-copy,
  body.client-shell .active-journey-copy,
  body.facilitator-shell:not(.playlist-editing) .live-status-wrap,
  body.client-shell .client-practitioner-header-pill,
  body.client-shell .client-priority-wrap {
    display: none !important;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-tools .sync-status-wrap,
  body.facilitator-shell:not(.playlist-editing) .active-journey-tools .notifications-status-wrap,
  body.client-shell .active-journey-tools .sync-status-wrap,
  body.client-shell .client-header-tools .notifications-status-wrap,
  body.facilitator-shell:not(.playlist-editing) .active-journey-tools .header-theme-switch,
  body.client-shell .active-journey-tools .header-theme-switch,
  body.facilitator-shell:not(.playlist-editing) .header-account-wrap,
  body.client-shell .header-account-wrap {
    flex: 0 0 48px;
    height: 48px;
    min-height: 48px;
    min-width: 48px;
    width: 48px;
  }

  body.facilitator-shell:not(.playlist-editing) .header-account-button,
  body.client-shell .header-account-button,
  body.facilitator-shell:not(.playlist-editing) .active-journey-tools [data-open-notifications],
  body.client-shell .client-header-tools [data-open-notifications],
  body.facilitator-shell:not(.playlist-editing) .active-journey-tools .header-notification-button,
  body.client-shell .client-header-tools .header-notification-button,
  body.facilitator-shell:not(.playlist-editing) .header-theme-button,
  body.client-shell .header-theme-button {
    align-items: center;
    border-radius: 999px;
    display: inline-grid;
    grid-template-columns: 1fr;
    height: 48px;
    justify-items: center;
    line-height: 1;
    min-height: 48px;
    min-width: 48px;
    padding: 0;
    place-items: center;
    width: 48px;
  }

  body.facilitator-shell:not(.playlist-editing) .header-account-button > span,
  body.facilitator-shell:not(.playlist-editing) .header-account-button img,
  body.client-shell .header-account-button > span,
  body.client-shell .header-account-button img {
    align-items: center;
    border-radius: 6px;
    display: inline-grid;
    height: 34px;
    justify-content: center;
    line-height: 1;
    place-items: center;
    width: 34px;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-tools .header-button-label,
  body.client-shell .client-header-tools .header-button-label {
    display: none;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-tools .header-button-icon,
  body.client-shell .client-header-tools .header-button-icon {
    display: inline-grid;
    line-height: 1;
    min-height: 28px;
    min-width: 28px;
    place-items: center;
  }

  body.facilitator-shell:not(.playlist-editing) .message-envelope-icon,
  body.client-shell .message-envelope-icon {
    height: 26px;
    width: 26px;
    stroke-width: 1.75;
  }

  body.facilitator-shell:not(.playlist-editing) .header-theme-button,
  body.client-shell .header-theme-button {
    line-height: 1;
  }

  body.facilitator-shell:not(.playlist-editing) .theme-toggle-glyph,
  body.facilitator-shell:not(.playlist-editing) .theme-toggle-icon,
  body.client-shell .theme-toggle-glyph {
    height: 28px;
    width: 28px;
  }

  body.client-shell .theme-toggle-icon {
    height: 28px;
    width: 28px;
  }

  body.facilitator-shell:not(.playlist-editing) .theme-toggle-glyph::before,
  body.client-shell .theme-toggle-glyph::before {
    height: 18px;
    width: 18px;
  }

  body.facilitator-shell:not(.playlist-editing) .active-journey-tools .notifications-popover,
  body.client-shell .client-header-tools .notifications-popover {
    left: auto;
    right: 0;
    top: calc(100% + 8px);
    width: min(320px, calc(100vw - 24px));
  }

  .workspace-tabs {
    flex-wrap: nowrap;
    gap: 6px;
    margin: 0 0 14px;
    max-width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 0 0 6px;
    scrollbar-width: none;
    scroll-snap-type: x proximity;
    -webkit-overflow-scrolling: touch;
  }

  .workspace-tabs::-webkit-scrollbar {
    display: none;
  }

  .workspace-tab {
    flex: 0 0 auto;
    font-size: 0.88rem;
    min-height: 36px;
    padding: 7px 11px;
    scroll-snap-align: start;
    white-space: nowrap;
  }
}

body.admin-route {
  background: #08131c;
}

html[data-theme="light"] body.admin-route {
  background: #f6f8f9;
}

body.admin-route #adminMode {
  max-width: none;
  padding: 0;
}

body.admin-route .admin-board {
  background: #0f1b27;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  margin: 0;
  max-width: none;
  min-height: 100vh;
  padding: 0;
  width: 100%;
}

html[data-theme="light"] body.admin-route .admin-board {
  background: #f6f8f9;
}

body.admin-route .admin-board > .section-heading {
  background: #08131c;
  border-bottom: 1px solid rgba(226, 232, 240, 0.1);
  margin: 0;
  padding: 28px 34px;
}

html[data-theme="light"] body.admin-route .admin-board > .section-heading {
  background: #ffffff;
  border-bottom-color: rgba(15, 23, 42, 0.12);
}

body.admin-route .admin-workspace {
  align-items: start;
  gap: 0;
  grid-template-columns: 270px minmax(0, 1fr);
  grid-template-rows: auto 1fr;
  min-height: calc(100vh - 150px);
}

body.admin-sidebar-collapsed.admin-route .admin-workspace {
  grid-template-columns: 72px minmax(0, 1fr);
}

body.admin-route .admin-menu-toggle {
  align-items: center;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 8px;
  box-shadow: none;
  color: var(--action);
  display: inline-grid;
  gap: 8px;
  grid-column: 1;
  grid-row: 1;
  grid-template-columns: 28px minmax(0, 1fr);
  justify-items: start;
  margin: 18px 14px 0;
  min-height: 42px;
  padding: 9px 12px;
  position: relative;
  text-align: left;
  z-index: 3;
}

@media (min-width: 901px) {
  body.admin-route .admin-menu-toggle {
    display: none;
  }
}

body.admin-route .admin-menu-toggle:hover {
  background: rgba(79, 209, 197, 0.1);
  border-color: rgba(79, 209, 197, 0.18);
}

body.admin-sidebar-collapsed.admin-route .admin-menu-toggle {
  grid-template-columns: 1fr;
  justify-items: center;
  margin-inline: 12px;
  min-height: 48px;
  padding: 0;
  width: 48px;
}

body.admin-route .admin-side-nav {
  align-content: start;
  align-items: stretch;
  align-self: start;
  background: #0b121c;
  border: 0;
  border-right: 1px solid rgba(226, 232, 240, 0.1);
  border-radius: 0;
  box-shadow: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
  grid-auto-rows: max-content;
  grid-column: 1;
  grid-row: 1 / span 2;
  height: 100vh;
  justify-content: flex-start;
  max-height: 100vh;
  min-height: 0;
  overflow: auto;
  padding: 18px 14px;
  position: sticky;
  top: 0;
}

html[data-theme="light"] body.admin-route .admin-side-nav {
  background: #ffffff;
  border-right-color: rgba(15, 23, 42, 0.12);
}

body.admin-route .admin-nav-brand {
  align-items: center;
  align-self: start;
  background: transparent;
  border: 1px solid rgba(94, 234, 212, 0.22);
  border-radius: 8px;
  color: inherit;
  cursor: pointer;
  display: grid;
  gap: 12px;
  grid-template-columns: 52px minmax(0, 1fr);
  min-height: 78px;
  padding: 12px;
  text-align: left;
  width: 100%;
}

body.admin-route .admin-nav-brand,
body.admin-route .admin-nav-kicker,
body.admin-route .admin-nav-group,
body.admin-route .admin-nav-footer {
  flex: 0 0 auto;
}

body.admin-route .admin-nav-brand:hover {
  background: rgba(79, 209, 197, 0.08);
  border-color: rgba(79, 209, 197, 0.28);
}

body.admin-route .admin-nav-brand-media {
  align-items: center;
  background: rgba(79, 209, 197, 0.09);
  border-radius: 8px;
  display: inline-grid;
  height: 52px;
  justify-content: center;
  width: 52px;
}

body.admin-route .admin-nav-brand-media img {
  display: block;
  height: 32px;
  object-fit: contain;
  width: 32px;
}

body.admin-route .admin-nav-brand-copy {
  display: grid;
  gap: 2px;
  min-width: 0;
}

body.admin-route .admin-nav-brand-copy strong {
  color: var(--ink);
  font-size: 1.05rem;
  line-height: 1.05;
}

body.admin-route .admin-nav-brand-copy small {
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

body.admin-route .admin-nav-kicker {
  margin-top: 8px;
  padding: 0 4px;
}

body.admin-route .admin-nav-group {
  align-content: start;
  align-self: stretch;
  background: transparent;
  border: 0;
  border-radius: 0;
  display: grid;
  gap: 0;
  grid-auto-rows: max-content;
  overflow: visible;
}

body.admin-route .admin-nav-group summary,
body.admin-route .admin-nav-button {
  border-radius: 8px;
  color: var(--text-soft);
}

body.admin-route .admin-nav-group summary {
  align-items: center;
  border: 1px solid transparent;
  cursor: pointer;
  display: grid;
  gap: 10px;
  grid-template-columns: 28px minmax(0, 1fr);
  min-height: 42px;
  padding: 9px 10px;
}

body.admin-route .admin-nav-group summary:hover,
body.admin-route .admin-nav-group.active summary {
  background: rgba(79, 209, 197, 0.1);
  border-color: rgba(79, 209, 197, 0.18);
  color: var(--accent);
}

body.admin-route .admin-nav-group summary::after,
body.admin-route .admin-nav-group[open] summary::after {
  content: none;
  display: none;
}

body.admin-route .admin-nav-group:has(.admin-nav-button.active) {
  background: transparent;
  border-color: transparent;
}

body.admin-route .admin-nav-group .admin-nav-button {
  display: none;
}

body.admin-route .admin-nav-button {
  align-items: center;
  border: 1px solid transparent;
  display: flex;
  gap: 10px;
  min-height: 42px;
  padding: 9px 10px;
}

body.admin-route .admin-nav-group .admin-nav-button.active,
body.admin-route .admin-nav-button.active {
  background: rgba(79, 209, 197, 0.14);
  border: 1px solid rgba(79, 209, 197, 0.24);
  color: var(--accent);
}

body.admin-route .admin-content {
  align-self: start;
  grid-column: 2;
  grid-row: 2;
  padding: 0 34px 34px;
}

body.admin-route .admin-content .admin-card {
  background: var(--bg-card);
  box-shadow: none;
}

body.admin-route .admin-workspace-tabs {
  align-items: center;
  border-bottom: 1px solid rgba(226, 232, 240, 0.1);
  display: flex;
  grid-column: 2;
  grid-row: 1;
  gap: 8px;
  margin: 0;
  overflow-x: auto;
  padding: 22px 34px 16px;
  scrollbar-width: none;
}

html[data-theme="light"] body.admin-route .admin-workspace-tabs {
  border-bottom-color: rgba(15, 23, 42, 0.1);
}

body.admin-route .admin-workspace-tabs::-webkit-scrollbar {
  display: none;
}

body.admin-route .admin-workspace-tab {
  flex: 0 0 auto;
  white-space: nowrap;
}

body.admin-sidebar-collapsed.admin-route .admin-side-nav {
  align-items: center;
  padding: 18px 8px 14px;
}

body.admin-sidebar-collapsed.admin-route .admin-nav-brand {
  border-color: transparent;
  grid-template-columns: 1fr;
  justify-items: center;
  min-height: 54px;
  padding: 7px;
}

body.admin-sidebar-collapsed.admin-route .admin-nav-brand-media {
  height: 42px;
  width: 42px;
}

body.admin-sidebar-collapsed.admin-route .admin-nav-brand-copy,
body.admin-sidebar-collapsed.admin-route .admin-nav-kicker,
body.admin-sidebar-collapsed.admin-route .admin-nav-group summary .nav-label,
body.admin-sidebar-collapsed.admin-route .admin-nav-group summary::after,
body.admin-sidebar-collapsed.admin-route .admin-menu-toggle .nav-label {
  display: none;
}

body.admin-sidebar-collapsed.admin-route .admin-nav-group summary,
body.admin-sidebar-collapsed.admin-route .admin-nav-button,
body.admin-sidebar-collapsed.admin-route .admin-nav-group .admin-nav-button {
  grid-template-columns: 1fr;
  justify-content: center;
  justify-items: center;
  min-height: 48px;
  padding: 0;
  width: 48px;
}

@media (max-width: 900px) {
  body.admin-route .admin-board > .section-heading {
    padding: 22px;
  }

  body.admin-route .admin-workspace,
  body.admin-sidebar-collapsed.admin-route .admin-workspace {
    display: block;
    min-height: 0;
  }

  body.admin-route .admin-menu-toggle {
    display: inline-grid;
    height: 46px;
    margin: 12px;
    min-height: 46px;
    padding: 0;
    place-items: center;
    width: 46px;
  }

  body.admin-route .admin-menu-toggle .nav-label {
    display: none;
  }

  body.admin-route .admin-side-nav {
    border-right: 0;
    bottom: 0;
    box-shadow: none;
    left: 0;
    max-width: min(320px, calc(100vw - 28px));
    min-height: 100vh;
    padding: 18px 14px;
    position: fixed;
    top: 0;
    transform: translateX(-104%);
    transition: transform 0.18s ease;
    width: min(320px, calc(100vw - 28px));
    z-index: 70;
  }

  body.admin-route .admin-side-nav.open {
    transform: translateX(0);
  }

  body.admin-route .admin-content {
    padding: 0 22px 22px;
  }

  body.admin-route .admin-workspace-tabs {
    margin: 0;
    padding: 18px 22px 12px;
  }
}

@media (max-width: 900px) {
  body.client-shell .top-workbar {
    align-items: center;
    display: flex;
    justify-content: space-between;
  }

  body.client-shell .active-journey-bar {
    align-items: center;
    display: flex;
    justify-content: flex-end;
    margin-left: auto;
    width: auto;
  }

  body.client-shell .active-journey-tools.client-header-tools {
    align-items: center;
    display: flex;
    gap: 6px;
    justify-content: flex-end;
    margin-left: auto;
    width: auto;
  }
}

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