/* Foundation: tokens, shell, shared components, and global helpers. */

html {
  scroll-padding-top: calc(var(--safe-top) + var(--space-4));
  scrollbar-gutter: stable both-edges;
}

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

body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--color-text);
  background: radial-gradient(circle at top right, #f8fbff, #eef3fa 50%, #eaf0f8 100%);
  line-height: 1.45;
  -webkit-text-size-adjust: 100%;
}

body.shell-nav-open { overflow: hidden; }

body.has-mobile-quicknav {
  --overlay-quicknav-clearance: calc(var(--mobile-quicknav-height) + var(--shell-mobile-utility-offset) + var(--safe-bottom));
}

img, svg, video, canvas { display: block; max-width: 100%; height: auto; }

.skip-link {
  position: fixed;
  top: var(--space-2);
  left: var(--space-2);
  z-index: 1000;
  background: #0f172a;
  color: #fff;
  padding: 0.5rem 0.8rem;
  border-radius: var(--radius-sm);
  border: 1px solid #334155;
  transform: translateY(-160%);
  transition: transform var(--transition-fast);
}

.skip-link:focus-visible {
  transform: translateY(0);
  box-shadow: var(--shadow-focus);
}

a { color: var(--color-primary-strong); transition: color var(--transition-fast); }

a:hover { color: var(--color-primary); }

a:focus-visible { outline: 2px solid var(--color-primary); outline-offset: 2px; border-radius: 0.35rem; }

h1, h2, h3, h4, h5 { margin: 0 0 var(--space-3); line-height: 1.2; }

h1 { font-size: clamp(1.35rem, 1.15rem + 1vw, 2rem); }

h2 { font-size: clamp(1.2rem, 1.05rem + 0.6vw, 1.5rem); }

h3 { font-size: 1.1rem; }

p { margin: 0 0 var(--space-3); }

ul { margin: 0 0 var(--space-4); padding-left: 1.2rem; }

label {
  display: grid;
  gap: var(--space-2);
  margin-block: var(--space-4);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--color-text);
}

input, textarea, select, button {
  font: inherit;
  transition: border-color var(--transition-fast), background var(--transition-fast), box-shadow var(--transition-fast), color var(--transition-fast);
}

button { cursor: pointer; }

input, textarea, select {
  width: 100%;
  min-height: var(--touch-target);
  padding: 0.66rem 0.78rem;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  background: var(--color-surface);
  color: var(--color-text);
}

input::placeholder,
textarea::placeholder { color: #8a97ad; }

textarea { min-height: 6rem; resize: vertical; }

input[type="checkbox"], input[type="radio"] {
  width: auto;
  accent-color: var(--oh-cyan, #00eefc);
}

input[type="file"] {
  padding: 0.4rem;
  border-style: dashed;
  background: #fbfdff;
}

input[type="file"]::file-selector-button {
  border: 1px solid var(--color-border-strong);
  border-radius: var(--radius-sm);
  background: var(--color-surface);
  color: var(--color-text);
  padding: 0.38rem 0.68rem;
  margin-right: var(--space-2);
  cursor: pointer;
}

input:focus-visible, textarea:focus-visible, select:focus-visible, button:focus-visible, .btn:focus-visible {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: var(--shadow-focus);
}

input[aria-invalid="true"],
textarea[aria-invalid="true"],
select[aria-invalid="true"],
input[data-feedback-invalid="true"],
textarea[data-feedback-invalid="true"],
select[data-feedback-invalid="true"],
.is-invalid {
  border-color: #e88080;
  background: #fff8f8;
}

input:disabled, textarea:disabled, select:disabled, button:disabled { opacity: 0.6; cursor: not-allowed; }

table { width: 100%; }

.page-header {
  position: relative;
  display: grid;
  gap: var(--space-3);
  z-index: 15;
}

.page-header .notification-menu {
  z-index: 0;
}

.page-header .notification-menu[open] {
  z-index: 30;
}

.page-header-main,
.page-header-copy {
  display: grid;
  gap: var(--space-2);
  min-width: 0;
}

.breadcrumbs {
  font-size: 0.72rem;
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.09em;
  margin: 0;
}

.notification-menu > summary {
  list-style: none;
  cursor: pointer;
  border: 1px solid var(--color-border-strong);
  border-radius: var(--radius-sm);
  background: var(--color-surface);
  padding: 0.6rem 0.94rem;
  width: 100%;
  min-height: var(--touch-target);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  font-size: 0.92rem;
  font-weight: 600;
  line-height: 1.2;
  text-align: center;
}

.notification-menu > summary::-webkit-details-marker { display: none; }

.notification-menu[open] > summary {
  border-color: var(--color-primary);
  box-shadow: var(--shadow-focus);
}

.page-content,
.section-container {
  width: 100%;
  max-width: 100%;
  display: grid;
  gap: clamp(var(--space-4), 2vw, var(--space-6));
  min-width: 0;
}

.page-content > *,
.section-container > * {
  min-width: 0;
}

.card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: clamp(var(--space-3), 2.8vw, var(--space-4));
  box-shadow: var(--shadow-xs);
  max-width: 100%;
  min-width: 0;
  container-type: inline-size;
  transition: transform var(--transition-base), box-shadow var(--transition-base), border-color var(--transition-base);
}

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

.helper-text, .inline-msg { font-size: 0.8rem; color: var(--color-text-muted); }

.has-trailing-badge {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
}

.notification-count {
  display: inline-flex;
  align-items: center;
  min-width: 0;
}

.notification-badge {
  min-width: 1.6rem;
  min-height: 1.6rem;
  padding: 0.12rem 0.42rem;
  border-radius: var(--radius-pill);
  background: #dc2626;
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  font-weight: 700;
  line-height: 1;
  box-shadow: 0 8px 18px rgb(220 38 38 / 0.24);
}

.notification-badge.is-hidden { display: none; }

.form-shell {
  display: grid;
  gap: var(--space-4);
}

.form-section {
  display: grid;
  gap: var(--space-3);
}

.form-field {
  margin-block: var(--space-2);
}

.field-label {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  font-size: 0.86rem;
  letter-spacing: 0.01em;
}

.required-mark {
  display: inline-flex;
  align-items: center;
  margin: 0;
  color: var(--oh-cyan, #0891b2);
  font-weight: 900;
  line-height: 1;
  letter-spacing: 0;
  text-transform: none;
}

.field-label .required-mark,
.tool-field .required-mark,
.stitch-auth-field .required-mark,
.assistant-form .required-mark {
  display: inline-flex;
  margin: 0 0 0 0.2rem;
  color: var(--oh-cyan, #0891b2);
  font-size: inherit;
  line-height: 1;
}

.field-hint {
  font-size: 0.78rem;
  color: var(--color-text-muted);
  font-weight: 500;
}

.badge {
  display: inline-flex;
  align-items: center;
  border-radius: var(--radius-pill);
  font-size: 0.74rem;
  font-weight: 600;
}

.status-badge {
  --status-badge-color: var(--oh-text-muted);
  --status-badge-border: rgb(68 70 80 / 0.8);
  --status-badge-bg: rgb(50 53 55 / 0.45);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.38rem;
  width: fit-content;
  max-width: 100%;
  min-height: 1.85rem;
  padding: 0.32rem 0.7rem;
  border: 1px solid var(--status-badge-border);
  border-radius: var(--radius-pill);
  color: var(--status-badge-color);
  background: var(--status-badge-bg);
  font-size: 0.78rem;
  font-weight: 900;
  line-height: 1.1;
  overflow-wrap: anywhere;
}

.status-badge-stack {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.45rem;
  min-width: 0;
}

.status-badge-stack.is-vertical {
  flex-direction: column;
  align-items: flex-start;
  gap: 0.35rem;
}

.status-badge-dot {
  flex: 0 0 auto;
  width: 0.45rem;
  height: 0.45rem;
  border-radius: 999px;
  background: currentColor;
}

.status-badge-dot.is-glowing {
  box-shadow: 0 0 10px currentColor;
}

.status-badge-compact {
  min-height: 1.55rem;
  padding: 0.22rem 0.52rem;
  font-size: 0.72rem;
}

.status-badge-wide {
  min-width: 10rem;
  justify-content: flex-start;
  padding: 0.6rem 0.75rem;
  border-radius: 0.75rem;
}

.status-badge-multiline {
  display: inline-grid;
  justify-content: start;
  gap: 0.18rem;
}

.status-badge-success,
.status-badge.is-success,
.status-badge.is-active,
.status-badge.is-paid,
.status-badge.is-live,
.status-badge.is-sent,
.status-badge.is-delivered,
.status-badge.status-approved,
.status-badge.status-active {
  --status-badge-color: #d3fbff;
  --status-badge-border: rgb(0 238 252 / 0.34);
  --status-badge-bg: rgb(0 238 252 / 0.10);
}

.status-badge-warning,
.status-badge.is-warning,
.status-badge.is-pending,
.status-badge.is-submitted,
.status-badge.is-submitted-edits,
.status-badge.is-pending_recalculation,
.status-badge.is-skipped,
.status-badge.status-submitted_for_review,
.status-badge.status-edit_submitted_for_review {
  --status-badge-color: #ffd33b;
  --status-badge-border: rgb(255 211 59 / 0.32);
  --status-badge-bg: rgb(255 211 59 / 0.08);
}

.status-badge-error,
.status-badge.is-error,
.status-badge.is-danger,
.status-badge.is-returned,
.status-badge.is-failed,
.status-badge.is-suspended,
.status-badge.is-unpaid,
.status-badge.is-overdue,
.status-badge.is-validation_failed,
.status-badge.status-returned_for_edits,
.status-badge.status-edit_returned_for_edits,
.status-badge.status-deactivated {
  --status-badge-color: #ffb4ab;
  --status-badge-border: rgb(255 180 171 / 0.34);
  --status-badge-bg: rgb(147 0 10 / 0.18);
}

.status-badge-neutral,
.status-badge.is-neutral,
.status-badge.is-inactive {
  --status-badge-color: var(--oh-text-muted);
  --status-badge-border: rgb(68 70 80 / 0.8);
  --status-badge-bg: rgb(50 53 55 / 0.45);
}

.status-badge-muted,
.status-badge.is-muted,
.status-badge.is-draft,
.status-badge.is-not_calculated,
.status-badge.status-draft,
.status-badge.status-withdrawn {
  --status-badge-color: var(--oh-text-muted);
  --status-badge-border: rgb(197 198 210 / 0.28);
  --status-badge-bg: rgb(197 198 210 / 0.08);
}

.status-badge-info,
.status-badge.is-info,
.status-badge.is-new,
.status-badge.is-not_calculated {
  --status-badge-color: var(--oh-cyan-soft);
  --status-badge-border: rgb(0 238 252 / 0.32);
  --status-badge-bg: rgb(0 238 252 / 0.08);
}

@media (max-width: 48rem) {
  .status-badge-mobile-full {
    width: 100%;
    justify-content: center;
  }
}

.empty-state,
.taxonomy-empty,
.error-state,
.loading-state {
  display: grid;
  justify-items: center;
  gap: 0.65rem;
  max-width: 100%;
  min-width: 0;
  padding: clamp(1rem, 3vw, 2rem);
  border: 1px dashed var(--state-border, var(--color-border-strong));
  border-radius: var(--radius-lg);
  color: var(--state-color, var(--color-text-muted));
  background: var(--state-bg, var(--color-surface-muted));
  text-align: center;
  overflow-wrap: anywhere;
}

.empty-state-compact {
  gap: 0.35rem;
  padding: 0.85rem 1rem;
  border-radius: var(--radius-md);
}

.empty-state h2,
.empty-state h3,
.empty-state h4,
.empty-state p,
.taxonomy-empty h2,
.taxonomy-empty h3,
.taxonomy-empty h4,
.taxonomy-empty p,
.error-state h2,
.error-state h3,
.error-state h4,
.error-state p,
.loading-state p {
  margin: 0;
}

.empty-state .material-symbols-outlined,
.taxonomy-empty .material-symbols-outlined,
.loading-state .material-symbols-outlined {
  color: var(--state-icon-color, currentColor);
}

.error-state,
.error-box {
  --state-color: #991b1b;
  --state-border: #fecaca;
  --state-bg: rgb(254 242 242 / 0.96);
}

.error-box {
  padding: 0.9rem 1rem;
  border: 1px solid var(--state-border);
  border-radius: var(--radius-lg);
  background: var(--state-bg);
  color: var(--state-color);
  font-weight: 800;
  overflow-wrap: anywhere;
  box-shadow: 0 14px 32px rgb(153 27 27 / 0.10);
}

.error-box strong { display: block; margin-bottom: var(--space-2); }

.error-box ul { margin: 0; }

.loading-state {
  --state-color: var(--oh-text-muted);
  --state-border: rgb(132 148 149 / 0.5);
  --state-bg: rgb(16 20 21 / 0.58);
  min-height: 5rem;
  color: var(--state-color);
}

.loading-state::before {
  content: "";
  width: 1rem;
  height: 1rem;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 999px;
  opacity: 0.78;
  animation: state-spinner 0.8s linear infinite;
}

.state-busy-overlay,
.instant-filter-results {
  position: relative;
  isolation: isolate;
  min-width: 0;
}

.state-busy-overlay[aria-busy="true"],
.instant-filter-results[aria-busy="true"] {
  cursor: progress;
}

.state-busy-overlay[aria-busy="true"]::before,
.instant-filter-results[aria-busy="true"]::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 4;
  border-radius: inherit;
  background: linear-gradient(180deg, rgb(16 20 21 / 0.08), rgb(16 20 21 / 0.16));
  pointer-events: none;
}

.state-busy-overlay[aria-busy="true"]::after,
.instant-filter-results[aria-busy="true"]::after {
  content: "Updating";
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  z-index: 5;
  display: inline-flex;
  align-items: center;
  min-height: 1.75rem;
  padding: 0.28rem 0.7rem;
  border: 1px solid rgb(0 238 252 / 0.32);
  border-radius: var(--radius-pill);
  color: var(--oh-cyan-soft);
  background: rgb(16 20 21 / var(--ui-elevated-alpha));
  box-shadow: 0 14px 34px rgb(0 0 0 / 0.26);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  pointer-events: none;
}

@keyframes state-spinner {
  to {
    transform: rotate(360deg);
  }
}

@media (max-width: 48rem) {
  .empty-state,
  .taxonomy-empty,
  .error-state,
  .loading-state {
    padding: 1rem;
  }

  .state-busy-overlay[aria-busy="true"]::after,
  .instant-filter-results[aria-busy="true"]::after {
    right: 0.5rem;
    max-width: calc(100% - 1rem);
  }
}

.actions {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-top: var(--space-5);
  flex-wrap: wrap;
  min-width: 0;
}

.file-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr)); gap: var(--space-3); }

@media (max-width: 56rem) {
  .row-actions { justify-content: flex-start; }
}

.account-list { list-style: none; padding: 0; margin: 0; display: grid; gap: var(--space-2); }

.account-list li {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  padding: var(--space-3);
  background: var(--color-surface-muted);
}

.account-list-detailed li {
  background: rgb(16 20 21 / 0.62);
}

.account-list-meta {
  margin: 0;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.35rem;
  color: var(--color-text-muted);
  font-size: 0.84rem;
  font-weight: 750;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.account-inline-links {
  display: grid;
  gap: var(--space-2);
}

.account-inline-links a {
  color: var(--color-primary-strong);
  font-weight: 600;
  text-decoration: none;
}

.account-inline-links a:hover {
  text-decoration: underline;
}

.status-draft { background: #f1f5f9; }

.status-submitted_for_review { background: var(--color-warning-soft); }

.status-returned_for_edits { background: #dbeafe; }

.status-edit_submitted_for_review { background: var(--color-warning-soft); }

.status-edit_returned_for_edits { background: #dbeafe; }

.status-approved { background: var(--color-success-soft); }

.status-deactivated { background: #e2e8f0; }

.status-withdrawn { background: #e2e8f0; }

.searchable-dropdown {
  position: relative;
  display: grid;
  gap: var(--space-2);
}

.searchable-dropdown-trigger {
  width: 100%;
  min-height: 3rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  padding: 0.75rem 0.85rem;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background: var(--color-surface);
  color: var(--color-text);
  text-align: left;
  box-shadow: none;
}

.searchable-dropdown-trigger.is-empty .searchable-dropdown-selected { color: #8a97ad; }

.searchable-dropdown-selected {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.searchable-dropdown-caret::before {
  content: '\25BE';
  color: var(--color-text-muted);
  font-size: 0.9rem;
}

.searchable-dropdown.is-open .searchable-dropdown-trigger {
  border-color: var(--color-primary);
  box-shadow: var(--shadow-focus);
}

.searchable-dropdown.is-invalid .searchable-dropdown-trigger {
  border-color: #e88080;
  background: #fff8f8;
}

.searchable-dropdown-panel {
  position: absolute;
  top: calc(100% + var(--space-2));
  left: 0;
  right: 0;
  z-index: 40;
  display: grid;
  gap: var(--space-2);
  padding: var(--space-2);
  border: 1px solid var(--color-border-strong);
  border-radius: var(--radius-md);
  background: var(--color-surface);
  box-shadow: var(--shadow-sm);
}

.searchable-dropdown-panel[hidden] { display: none; }

.searchable-dropdown-options {
  display: grid;
  gap: var(--space-1);
  max-height: 14rem;
  overflow: auto;
  padding-right: var(--space-1);
}

.searchable-dropdown-option {
  width: 100%;
  padding: 0.65rem 0.72rem;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--color-text);
  text-align: left;
  box-shadow: none;
}

.searchable-dropdown-option:hover,
.searchable-dropdown-option:focus-visible {
  background: var(--color-surface-muted);
  border-color: var(--color-border);
}

.searchable-dropdown-option.is-selected {
  border-color: rgb(0 238 252 / 0.28);
  background: var(--color-primary-soft);
  color: var(--color-primary-strong);
}

.searchable-dropdown-option[hidden] { display: none; }

.searchable-dropdown-empty {
  margin: 0;
  padding: 0.1rem var(--space-1);
}

.hidden { display: none; }

.chip { display: inline-flex; align-items: center; gap: var(--space-2); border: 1px solid var(--color-border-strong); border-radius: var(--radius-pill); padding: 0.18rem 0.56rem; background: var(--color-surface); margin-right: var(--space-2); margin-bottom: var(--space-2); }

.row-actions form { margin: 0; }

.tool-field span { display: block; font-size: 12px; color: var(--color-text-muted); margin-bottom: var(--space-1); font-weight: 600; }

.search-input-wrap { display: flex; align-items: center; border: 1px solid var(--color-border-strong); border-radius: var(--radius-sm); background: var(--color-surface); padding: 0 var(--space-2); gap: var(--space-2); min-width: 0; }

.search-input-wrap:focus-within { border-color: var(--color-primary); box-shadow: var(--shadow-focus); }

.search-input-wrap input { border: 0; outline: none; box-shadow: none; padding: 0.58rem 0; background: transparent; min-width: 0; }

.search-icon { font-size: 14px; opacity: 0.7; }

.status-active { background: var(--color-success-soft); color: #166534; border-color: #bbf7d0; }

.status-inactive { background: #f1f5f9; color: #334155; }

.row-actions { display: flex; gap: var(--space-2); align-items: center; justify-content: flex-end; flex-wrap: wrap; }

.taxonomy-empty h4 { margin: 0 0 var(--space-2); }

.taxonomy-empty p { margin: 0 0 var(--space-3); color: var(--color-text-muted); }

.project-search-field {
  grid-column: 1 / -1;
}

.project-search-field span {
  display: block;
  font-size: 12px;
  color: var(--color-text-muted);
  margin-bottom: var(--space-1);
  font-weight: 600;
}

@keyframes shimmer {
  from { background-position: 200% 0; }
  to { background-position: -200% 0; }
}

@keyframes toast-enter {
  from { opacity: 0; transform: translate3d(0.75rem, 0.5rem, 0) scale(0.96); }
  to { opacity: 1; transform: translate3d(0, 0, 0) scale(1); }
}

.toast-region {
  position: fixed;
  right: max(1rem, calc(1rem + var(--safe-right)));
  bottom: max(1rem, calc(1rem + var(--safe-bottom)));
  display: grid;
  gap: 0.75rem;
  width: min(24rem, calc(100dvw - var(--safe-left) - var(--safe-right) - 2rem));
  justify-items: end;
  z-index: 120;
  pointer-events: none;
}

.toast {
  width: 100%;
  color: var(--oh-text);
  background: rgb(29 32 34 / var(--ui-panel-alpha));
  padding: var(--space-3) var(--space-4);
  border: 1px solid rgb(0 238 252 / 0.28);
  border-radius: var(--radius-lg);
  opacity: 1;
  transform: translate3d(0, 0, 0) scale(1);
  transition: opacity 0.2s ease, transform 0.2s ease, background var(--transition-fast), border-color var(--transition-fast);
  box-shadow: 0 24px 80px rgb(0 0 0 / 0.34), 0 0 26px rgb(0 238 252 / 0.12);
  backdrop-filter: blur(16px);
  overflow-wrap: anywhere;
  pointer-events: auto;
  animation: toast-enter 0.22s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.toast.is-leaving {
  opacity: 0;
  transform: translate3d(0.75rem, 0.35rem, 0) scale(0.98);
}

.toast.is-success {
  border-color: rgb(34 197 94 / 0.42);
  box-shadow: 0 24px 80px rgb(0 0 0 / 0.34), 0 0 24px rgb(34 197 94 / 0.16);
}

.toast.is-info {
  background: #101415;
  border-color: rgb(0 238 252 / 0.34);
}

.toast.is-error {
  border-color: rgb(248 113 113 / 0.5);
  background: rgb(69 10 10 / 0.92);
  box-shadow: 0 24px 80px rgb(0 0 0 / 0.34), 0 0 24px rgb(248 113 113 / 0.16);
}

.toast.is-warning {
  color: #fff7ed;
  border-color: rgb(251 191 36 / 0.5);
  background: rgb(69 46 5 / 0.92);
  box-shadow: 0 24px 80px rgb(0 0 0 / 0.34), 0 0 24px rgb(251 191 36 / 0.16);
}

.website-field-error {
  margin-top: 0.38rem;
  color: #fecaca;
  font-size: 0.78rem;
  font-weight: 800;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.has-field-error .website-field-error {
  display: block;
}

.has-field-error > .field-label,
.has-field-error > span:first-child {
  color: #ffdad6;
}

.website-confirm-open {
  overflow: hidden;
}

.website-confirm-backdrop {
  position: fixed;
  inset: 0;
  z-index: 140;
  display: grid;
  place-items: center;
  padding: var(--overlay-safe-block-start) var(--overlay-safe-inline-end) var(--overlay-safe-block-end) var(--overlay-safe-inline-start);
  background: rgb(0 0 0 / 0.62);
  backdrop-filter: blur(14px);
}

.website-confirm-backdrop[hidden] {
  display: none;
}

.website-confirm-backdrop .website-confirm-dialog {
  width: min(28rem, 100%);
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 0.95rem;
  padding: 1rem;
  border: 1px solid rgb(0 238 252 / 0.24);
  border-radius: var(--radius-lg);
  color: var(--oh-text);
  background:
    linear-gradient(180deg, rgb(29 32 34 / var(--ui-elevated-alpha)), rgb(16 20 21 / var(--ui-panel-alpha))),
    var(--oh-surface);
  box-shadow: 0 30px 90px rgb(0 0 0 / 0.56), 0 0 30px rgb(0 238 252 / 0.1);
}

.website-confirm-backdrop .website-confirm-icon {
  width: 2.4rem;
  height: 2.4rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgb(0 238 252 / 0.32);
  border-radius: var(--radius-sm);
  color: var(--oh-cyan);
  background: rgb(0 238 252 / 0.08);
}

.website-confirm-dialog .website-confirm-copy {
  min-width: 0;
}

.website-confirm-dialog .website-confirm-copy h2 {
  margin: 0 0 0.35rem;
  color: var(--oh-text);
  font-size: 1.05rem;
  letter-spacing: 0;
}

.website-confirm-dialog .website-confirm-copy p {
  margin: 0;
  color: var(--oh-text-muted);
  font-size: 0.92rem;
  font-weight: 700;
  overflow-wrap: anywhere;
}

.website-confirm-dialog .website-confirm-actions {
  grid-column: 1 / -1;
  display: flex;
  justify-content: flex-end;
  gap: 0.65rem;
  flex-wrap: wrap;
}

.website-confirm-dialog .website-confirm-button {
  min-width: 6.75rem;
  min-height: 2.55rem;
  padding: 0.65rem 0.95rem;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  font-weight: 900;
  box-shadow: none;
}

.website-confirm-dialog .website-confirm-button:hover,
.website-confirm-dialog .website-confirm-button:focus-visible {
  transform: translateY(-1px);
  box-shadow: 0 12px 30px rgb(0 0 0 / 0.22);
}

.website-confirm-dialog .website-confirm-cancel {
  color: var(--oh-text);
  border-color: rgb(132 148 149 / 0.3);
  background: rgb(39 42 44 / var(--ui-control-alpha));
}

.website-confirm-dialog .website-confirm-cancel:hover,
.website-confirm-dialog .website-confirm-cancel:focus-visible {
  color: var(--oh-text);
  border-color: rgb(0 238 252 / 0.3);
  background: rgb(50 53 55 / var(--ui-control-alpha));
}

.website-confirm-dialog .website-confirm-primary {
  color: var(--oh-navy-text);
  border-color: var(--oh-cyan);
  background: var(--oh-cyan);
}

.website-confirm-dialog .website-confirm-primary:hover,
.website-confirm-dialog .website-confirm-primary:focus-visible {
  color: var(--oh-navy-text);
  border-color: var(--oh-cyan-soft);
  background: var(--oh-cyan-soft);
}

.website-confirm-dialog .website-confirm-danger {
  color: #ffdad6;
  border-color: rgb(255 180 171 / 0.42);
  background: rgb(147 0 10 / 0.34);
}

.website-confirm-dialog .website-confirm-danger:hover,
.website-confirm-dialog .website-confirm-danger:focus-visible {
  color: #ffdad6;
  border-color: rgb(255 180 171 / 0.62);
  background: rgb(147 0 10 / 0.46);
}

@media (max-width: 34rem) {
  .website-confirm-backdrop .website-confirm-dialog,
  .website-confirm-dialog .website-confirm-actions {
    grid-template-columns: 1fr;
  }

  .website-confirm-dialog .website-confirm-actions {
    display: grid;
  }
}

@media (hover: hover) and (pointer: fine) {
  .card:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 24px rgb(15 23 42 / 0.08);
    border-color: #c9d5e8;
  }
}

@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;
  }
}

@media (min-width: 48rem) {
  .page-header {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: flex-start;
  }
}

:root {
  color-scheme: dark;
  --font-sans: "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-display: "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

  --oh-midnight: #080c14;
  --oh-night: #0a0f1d;
  --oh-surface: #101415;
  --oh-surface-low: #191c1e;
  --oh-surface-card: #1d2022;
  --oh-surface-high: #272a2c;
  --oh-surface-highest: #323537;
  --oh-alabaster: #ffffff;
  --oh-alabaster-soft: #f8faff;
  --oh-border-light: #e2e8f0;
  --oh-border-dark: #1e293b;
  --oh-outline: #444650;
  --oh-text: #e0e3e5;
  --oh-text-muted: #c5c6d2;
  --oh-navy-text: #0f172a;
  --oh-navy-muted: #596884;
  --oh-cyan: #00eefc;
  --oh-cyan-soft: #d3fbff;
  --oh-emerald: #059669;
  --oh-emerald-soft: #dcfce7;
  --oh-amber: #d97706;
  --oh-amber-soft: #fef3c7;
  --oh-crimson: #dc2626;
  --oh-crimson-soft: #fef2f2;

  --color-bg: var(--oh-midnight);
  --color-surface: var(--oh-alabaster);
  --color-surface-muted: var(--oh-alabaster-soft);
  --color-border: var(--oh-border-light);
  --color-border-strong: #cbd5e1;
  --color-text: var(--oh-navy-text);
  --color-text-muted: var(--oh-navy-muted);
  --color-primary: var(--oh-cyan);
  --color-primary-strong: #00363a;
  --color-primary-soft: var(--oh-cyan-soft);
  --color-danger-soft: var(--oh-crimson-soft);
  --color-success-soft: var(--oh-emerald-soft);
  --color-warning-soft: var(--oh-amber-soft);

  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;

  --radius-sm: 0.5rem;
  --radius-md: 0.75rem;
  --radius-lg: 1rem;
  --radius-xl: 1.5rem;
  --radius-pill: 999px;
  --shadow-xs: 0 1px 2px rgb(15 23 42 / 0.06);
  --shadow-sm: 0 10px 24px rgb(15 23 42 / 0.08);
  --ui-surface-alpha: 0.81;
  --ui-panel-alpha: 0.85;
  --ui-elevated-alpha: 0.88;
  --ui-control-alpha: 0.82;
  --ui-sidebar-alpha: 0.90;
  --site-background-overlay-alpha: 0.78;
  --stitch-shadow: 0 20px 60px rgb(0 0 0 / 0.28);
  --stitch-card-shadow: 0 18px 42px rgb(0 0 0 / 0.24);
  --shadow-focus: 0 0 0 3px rgb(0 238 252 / 0.24);
  --transition-fast: 0.16s ease;
  --transition-base: 0.24s cubic-bezier(0.2, 0.8, 0.2, 1);

  --container-narrow: 72rem;
  --container-comfortable: 108rem;
  --container-wide: 118rem;
  --container-full: none;
  --shell-pad-inline: clamp(1rem, 2.4vw, 2rem);
  --shell-pad-block: clamp(1rem, 2.4vw, 2rem);
  --shell-page-pad-inline-start: max(var(--shell-pad-inline), var(--safe-left));
  --shell-page-pad-inline-end: max(var(--shell-pad-inline), var(--safe-right));
  --shell-fixed-utility-clearance: calc(var(--touch-target) + var(--shell-mobile-utility-offset) + var(--space-3));
  --overlay-edge-gap: 1rem;
  --overlay-safe-inline-start: max(var(--overlay-edge-gap), var(--safe-left));
  --overlay-safe-inline-end: max(var(--overlay-edge-gap), var(--safe-right));
  --overlay-safe-block-start: max(var(--overlay-edge-gap), var(--safe-top));
  --overlay-quicknav-clearance: 0px;
  --overlay-safe-block-end: max(var(--overlay-edge-gap), var(--safe-bottom), var(--overlay-quicknav-clearance));
  --shell-utility-offset: 0.9rem;
  --shell-mobile-utility-offset: 0.75rem;
  --shell-breakpoint-compact: 44rem;
  --shell-breakpoint-desktop: 64rem;
  --sidebar-width: 18rem;
  --touch-target: 2.75rem;
  --mobile-quicknav-height: 4.9rem;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-right: env(safe-area-inset-right, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --safe-left: env(safe-area-inset-left, 0px);
}

::-webkit-scrollbar {
  width: 0.55rem;
  height: 0.55rem;
}

::-webkit-scrollbar-track { background: var(--oh-midnight); }

::-webkit-scrollbar-thumb {
  background: var(--oh-surface-highest);
  border-radius: var(--radius-pill);
}

::-webkit-scrollbar-thumb:hover { background: #444650; }

@font-face {
  font-family: "Material Symbols Outlined";
  font-style: normal;
  font-weight: 400;
  font-display: block;
  src: url("/static/fonts/material-symbols-outlined-400.ttf") format("truetype");
}

.material-symbols-outlined {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: "Material Symbols Outlined";
  font-weight: normal;
  font-style: normal;
  font-size: 1.25rem;
  line-height: 1;
  letter-spacing: normal;
  text-transform: none;
  white-space: nowrap;
  direction: ltr;
  -webkit-font-feature-settings: "liga";
  font-feature-settings: "liga";
  -webkit-font-smoothing: antialiased;
  font-variation-settings: "FILL" 0, "wght" 400, "GRAD" 0, "opsz" 24;
}

.icon-fill { font-variation-settings: "FILL" 1, "wght" 500, "GRAD" 0, "opsz" 24; }

html {
  background: var(--oh-midnight);
}

body.stitch-shell-body {
  min-height: 100vh;
  margin: 0;
  font-family: var(--font-sans);
  color: var(--oh-text);
  background:
    radial-gradient(circle at 20% -10%, rgb(0 238 252 / 0.12), transparent 28rem),
    radial-gradient(circle at 105% 12%, rgb(68 70 80 / 0.16), transparent 30rem),
    linear-gradient(135deg, var(--oh-midnight), #111213 48%, #101415);
  line-height: 1.5;
}

body.stitch-shell-body.has-site-background {
  background:
    linear-gradient(135deg, rgb(8 12 20 / var(--site-background-overlay-alpha)), rgb(16 20 21 / var(--site-background-overlay-alpha)) 52%, rgb(16 20 21 / var(--site-background-overlay-alpha))),
    var(--site-background-image),
    radial-gradient(circle at 20% -10%, rgb(0 238 252 / 0.12), transparent 28rem),
    radial-gradient(circle at 105% 12%, rgb(68 70 80 / 0.16), transparent 30rem),
    linear-gradient(135deg, var(--oh-midnight), #111213 48%, #101415);
  background-attachment: fixed, fixed, scroll, scroll, scroll;
  background-position: center, center, 20% -10%, 105% 12%, center;
  background-repeat: no-repeat, no-repeat, no-repeat, no-repeat, no-repeat;
  background-size: cover, cover, auto, auto, cover;
}

.skip-link {
  background: var(--oh-cyan);
  color: #002022;
  border: 0;
  box-shadow: 0 10px 30px rgb(0 238 252 / 0.26);
}

/* Shared shell and mobile foundation. */
.app-shell,
.stitch-shell {
  --shell-nav-mode: overlay;
  --sidebar-track-size: 0rem;
  min-height: 100vh;
  min-height: 100dvh;
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: start;
  background: transparent;
}

.app-shell.has-sidebar,
.stitch-shell.has-sidebar {
  grid-template-columns: minmax(0, 1fr);
}

.main-shell,
.stitch-main-shell {
  min-width: 0;
  min-height: 100vh;
  padding: 0;
}

.sidebar-shell {
  display: contents;
  min-width: 0;
}

.sidebar,
.stitch-sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  z-index: 60;
  width: min(var(--sidebar-width), calc(100dvw - var(--touch-target) - var(--safe-right)));
  height: 100vh;
  height: 100dvh;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  padding: calc(var(--space-4) + var(--safe-top)) var(--space-4) calc(var(--space-4) + var(--safe-bottom)) max(var(--space-4), var(--safe-left));
  color: var(--oh-text);
  background:
    linear-gradient(180deg, rgb(10 15 29 / var(--ui-sidebar-alpha)), rgb(8 12 20 / var(--ui-sidebar-alpha)));
  border-right: 1px solid rgb(68 70 80 / 0.72);
  box-shadow: 0 24px 70px rgb(0 0 0 / 0.52);
  backdrop-filter: blur(18px);
  transform: translateX(calc(-100% - var(--space-4)));
  opacity: 0;
  pointer-events: none;
  transition: transform var(--transition-base), opacity var(--transition-base);
  overflow-y: auto;
  overscroll-behavior: contain;
}

.app-shell.sidebar-open .sidebar,
.app-shell.sidebar-open .stitch-sidebar,
.stitch-shell.sidebar-open .sidebar,
.stitch-shell.sidebar-open .stitch-sidebar {
  transform: translateX(0);
  opacity: 1;
  pointer-events: auto;
}

.shell-backdrop {
  position: fixed;
  inset: 0;
  z-index: 55;
  border: 0;
  background: rgb(3 7 18 / 0.68);
  opacity: 0;
  pointer-events: none;
  backdrop-filter: blur(6px);
  transition: opacity var(--transition-base);
}

.app-shell.sidebar-open .shell-backdrop,
.stitch-shell.sidebar-open .shell-backdrop {
  opacity: 1;
  pointer-events: auto;
}

.shell-sidebar-utility,
.shell-notification-anchor {
  position: fixed;
  top: calc(var(--safe-top) + var(--shell-utility-offset));
  z-index: 90;
}

.shell-sidebar-utility {
  left: calc(var(--safe-left) + var(--shell-utility-offset));
  box-shadow: 0 16px 38px rgb(0 0 0 / 0.28);
  transition: opacity var(--transition-fast), visibility 0s linear, transform var(--transition-fast);
}

.app-shell.sidebar-open .shell-sidebar-utility,
.stitch-shell.sidebar-open .shell-sidebar-utility {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.shell-notification-anchor {
  right: calc(var(--safe-right) + var(--shell-utility-offset));
}

.shell-notification-anchor .notification-menu {
  width: auto;
}

.shell-notification-anchor .notification-menu-summary {
  position: relative;
  width: var(--touch-target);
  min-width: var(--touch-target);
  padding: 0;
}

.shell-notification-anchor .notification-bell-label > span {
  display: none;
}

.shell-notification-anchor .notification-count {
  position: absolute;
  top: -0.35rem;
  right: -0.35rem;
  margin-left: 0;
}

.shell-notification-anchor .notification-menu-panel {
  position: absolute;
  right: 0;
  top: calc(100% + 0.7rem);
  width: min(24rem, calc(100dvw - var(--overlay-safe-inline-start) - var(--overlay-safe-inline-end)));
  max-height: min(28rem, calc(100dvh - var(--safe-top) - var(--shell-utility-offset) - var(--touch-target) - var(--space-3) - var(--overlay-safe-block-end)));
}

.page-container {
  --page-container-max: var(--container-comfortable);
  width: 100%;
  max-width: var(--page-container-max);
  margin-inline: auto;
  display: grid;
  gap: clamp(var(--space-3), 2.6vw, var(--space-4));
  align-content: start;
  min-width: 0;
  padding-block: calc(var(--shell-pad-block) + var(--safe-top)) calc(var(--shell-pad-block) + var(--safe-bottom));
  padding-inline: var(--shell-page-pad-inline-start) var(--shell-page-pad-inline-end);
}

.app-shell.has-sidebar .page-container,
.stitch-shell.has-sidebar .page-container {
  padding-block-start: calc(var(--safe-top) + var(--shell-fixed-utility-clearance));
}

.app-shell.has-mobile-quicknav .page-container,
.stitch-shell.has-mobile-quicknav .page-container {
  padding-bottom: calc(var(--mobile-quicknav-height) + var(--shell-pad-block) + var(--safe-bottom));
}

.container-narrow,
.container-comfortable,
.container-wide,
.container-full {
  width: 100%;
  min-width: 0;
}

.container-narrow { --page-container-max: var(--container-narrow); }

.container-comfortable { --page-container-max: var(--container-comfortable); }

.container-wide { --page-container-max: var(--container-wide); }

.container-full {
  --page-container-max: var(--container-full);
}

.mobile-quicknav {
  position: fixed;
  left: max(var(--shell-mobile-utility-offset), var(--safe-left));
  right: max(var(--shell-mobile-utility-offset), var(--safe-right));
  bottom: max(var(--shell-mobile-utility-offset), var(--safe-bottom));
  z-index: 50;
  display: flex;
  gap: 0.55rem;
  padding: 0.5rem;
  border: 1px solid rgb(68 70 80 / 0.6);
  border-radius: var(--radius-lg);
  background: rgb(10 15 29 / var(--ui-panel-alpha));
  box-shadow: 0 24px 70px rgb(0 0 0 / 0.34);
  backdrop-filter: blur(16px);
}

.mobile-quicknav[hidden] { display: none; }

.mobile-quicknav-track {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(0, 1fr);
  flex: 1;
  gap: 0.35rem;
  min-width: 0;
}

.mobile-quicknav-link {
  display: flex;
  min-width: 0;
  min-height: max(3rem, var(--touch-target));
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  padding: 0.5rem;
  border: 0;
  border-radius: var(--radius-md);
  color: var(--oh-text-muted);
  background: transparent;
  text-align: center;
  text-decoration: none;
  font-size: 0.75rem;
  font-weight: 800;
  box-shadow: none;
}

.mobile-quicknav-link:hover,
.mobile-quicknav-link:focus-visible {
  color: var(--oh-cyan);
  background: rgb(0 238 252 / 0.08);
}

.mobile-quicknav-link.is-active,
.mobile-quicknav-link[aria-current="page"] {
  color: var(--oh-cyan);
  background: rgb(0 238 252 / 0.10);
}

.mobile-quicknav-more {
  flex: 0 0 max(4.5rem, 20%);
}

.mobile-quicknav-label {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (min-width: 64rem) {
  .app-shell,
  .stitch-shell {
    --shell-nav-mode: inline;
  }

  .mobile-quicknav {
    display: none !important;
  }

  .shell-backdrop {
    display: none;
  }

  .app-shell.has-mobile-quicknav .page-container,
  .stitch-shell.has-mobile-quicknav .page-container {
    padding-bottom: calc(var(--shell-pad-block) + var(--safe-bottom));
  }

  .app-shell.has-sidebar,
  .stitch-shell.has-sidebar {
    --sidebar-track-size: var(--sidebar-width);
    grid-template-columns: var(--sidebar-track-size) minmax(0, 1fr);
  }

  :root[data-shell-sidebar="collapsed"] .app-shell.has-sidebar,
  :root[data-shell-sidebar="collapsed"] .stitch-shell.has-sidebar {
    --sidebar-track-size: 0rem;
  }

  .sidebar-shell {
    display: block;
    inline-size: var(--sidebar-track-size);
    min-width: 0;
    min-height: 100vh;
    min-height: 100dvh;
    overflow: hidden;
    transition: inline-size var(--transition-base);
  }

  .sidebar,
  .stitch-sidebar {
    position: fixed;
    inset: 0 auto auto 0;
    width: var(--sidebar-width);
    max-width: var(--sidebar-width);
    height: 100vh;
    height: 100dvh;
    min-height: 0;
    padding: calc(var(--space-5) + var(--safe-top)) var(--space-4) calc(var(--space-4) + var(--safe-bottom));
    box-shadow: none;
    transform: none;
    opacity: 1;
    pointer-events: auto;
    z-index: 50;
  }

  :root[data-shell-sidebar="collapsed"] .app-shell.has-sidebar .sidebar,
  :root[data-shell-sidebar="collapsed"] .app-shell.has-sidebar .stitch-sidebar,
  :root[data-shell-sidebar="collapsed"] .stitch-shell.has-sidebar .sidebar,
  :root[data-shell-sidebar="collapsed"] .stitch-shell.has-sidebar .stitch-sidebar {
    transform: translateX(calc(-100% - var(--space-3)));
    opacity: 0;
    pointer-events: none;
  }

  .app-shell.has-sidebar .sidebar-toggle-open,
  .stitch-shell.has-sidebar .sidebar-toggle-open {
    display: inline-flex;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transition: opacity var(--transition-fast), visibility 0s linear;
  }

  :root[data-shell-sidebar="expanded"] .app-shell.has-sidebar .sidebar-toggle-open,
  :root[data-shell-sidebar="expanded"] .stitch-shell.has-sidebar .sidebar-toggle-open {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
  }

}

.sidebar-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.25rem 0.25rem 1.25rem;
  border-bottom: 1px solid rgb(68 70 80 / 0.5);
}

.brand-block {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
  color: var(--oh-text);
  text-decoration: none;
}

.brand-block:hover {
  color: var(--oh-text);
}

.brand-mark {
  flex: 0 0 auto;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 0.75rem;
  color: #00363a;
  background: var(--oh-cyan);
  box-shadow: 0 0 24px rgb(0 238 252 / 0.22);
}

.brand-copy {
  display: grid;
  min-width: 0;
}

.brand {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 800;
  line-height: 1.1;
  color: var(--oh-text);
  letter-spacing: 0;
}

.sidebar-nav-heading,
.breadcrumbs {
  font-size: 0.7rem;
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.sidebar-toggle {
  width: var(--touch-target);
  height: var(--touch-target);
  min-width: var(--touch-target);
  min-height: var(--touch-target);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border-radius: 0.75rem;
  border: 1px solid rgb(197 198 210 / 0.16);
  background: rgb(39 42 44 / 0.74);
  color: var(--oh-text);
  cursor: pointer;
}

.sidebar-toggle:hover {
  color: var(--oh-cyan);
  border-color: rgb(0 238 252 / 0.42);
  background: rgb(39 42 44 / var(--ui-control-alpha));
}

.sidebar-nav {
  display: grid;
  gap: 1.25rem;
}

.sidebar-nav-group {
  display: grid;
  gap: 0.35rem;
}

.sidebar-nav-heading {
  margin: 0 0 0.4rem;
  padding-inline: 0.75rem;
  color: rgb(197 198 210 / 0.74);
}

.sidebar-nav-link {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-height: max(3rem, var(--touch-target));
  padding: 0.75rem 0.9rem;
  border-radius: 0.75rem;
  border-left: 2px solid transparent;
  color: var(--oh-text-muted);
  font-weight: 700;
  text-decoration: none;
  transition: background var(--transition-fast), color var(--transition-fast), border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.sidebar-nav-link::before {
  content: "radio_button_unchecked";
  flex: 0 0 auto;
  font-family: "Material Symbols Outlined";
  font-size: 1.25rem;
  line-height: 1;
  font-weight: 400;
  color: currentColor;
  font-variation-settings: "FILL" 0, "wght" 400, "GRAD" 0, "opsz" 24;
}

.sidebar-nav-link[href*="/admin/users"]::before { content: "group"; }

.sidebar-nav-link[href*="/admin/accounts"]::before { content: "account_balance_wallet"; }

.sidebar-nav-link[href*="/admin/projects"]::before { content: "domain"; }

.sidebar-nav-link[href*="/admin/calculate-ranges"]::before { content: "functions"; }

.sidebar-nav-link[href*="/admin/broadcast"]::before { content: "campaign"; }

.sidebar-nav-link[href*="/admin/review"]::before { content: "fact_check"; }

.sidebar-nav-link[href*="/admin/clarification-videos"]::before { content: "video_library"; }

.sidebar-nav-link[href*="/admin/assistant"]::before { content: "smart_toy"; }

.sidebar-nav-link[href*="/admin/backgrounds"]::before { content: "wallpaper"; }

.sidebar-nav-link[href*="/projects/wizard"]::before { content: "add"; }

.sidebar-nav-link[href*="/account/projects"]::before { content: "folder_open"; }

.sidebar-nav-link[href="/account"]::before { content: "person"; }

.sidebar-nav-link:hover {
  color: var(--oh-cyan);
  background: rgb(39 42 44 / 0.72);
}

.sidebar-nav-link.is-active {
  color: var(--oh-cyan);
  background: rgb(0 238 252 / 0.08);
  border-left-color: var(--oh-cyan);
  box-shadow: inset 0 0 0 1px rgb(0 238 252 / 0.08), 0 0 22px rgb(0 238 252 / 0.08);
}

.has-trailing-badge {
  gap: 0.65rem;
}

.notification-count {
  display: inline-flex;
  align-items: center;
  margin-left: auto;
}

.notification-badge {
  min-width: 1.25rem;
  height: 1.25rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding-inline: 0.35rem;
  border-radius: var(--radius-pill);
  background: var(--oh-cyan);
  color: #00363a;
  font-size: 0.7rem;
  font-weight: 900;
  box-shadow: 0 0 16px rgb(0 238 252 / 0.32);
}

.notification-badge.is-hidden {
  display: none;
}

.stitch-page-header {
  position: relative;
  overflow: hidden;
  display: grid;
  gap: 1.25rem;
  min-width: 0;
  max-width: 100%;
  margin-bottom: clamp(1.25rem, 2vw, 2rem);
  padding: clamp(1.25rem, 3vw, 2.4rem);
  border: 1px solid rgb(68 70 80 / 0.58);
  border-radius: var(--radius-xl);
  background:
    linear-gradient(135deg, rgb(29 32 34 / var(--ui-surface-alpha)), rgb(0 238 252 / 0.08)),
    rgb(29 32 34 / var(--ui-surface-alpha));
  color: var(--oh-text);
  box-shadow: var(--stitch-shadow);
  backdrop-filter: blur(16px);
}

.stitch-page-header::after {
  content: "";
  position: absolute;
  inset: auto -8rem -8rem auto;
  width: 24rem;
  height: 24rem;
  border-radius: 999px;
  background: radial-gradient(circle, rgb(0 238 252 / 0.18), transparent 65%);
  pointer-events: none;
}

.page-header-main,
.page-header-copy {
  position: relative;
  z-index: 1;
  min-width: 0;
}

.page-header-copy {
  max-width: 64rem;
}

.stitch-page-header .breadcrumbs:empty {
  display: none;
}

.stitch-page-header h1 {
  margin: 0;
  color: var(--oh-text);
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 2.8vw, 2.75rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: 0;
}

.stitch-page-header .helper-text,
.stitch-page-header p {
  max-width: 46rem;
  color: var(--oh-text-muted);
}

.card,
.taxonomy-empty {
  border-radius: var(--radius-lg);
}

.card {
  color: var(--oh-navy-text);
  background: rgb(255 255 255 / var(--ui-panel-alpha));
  border: 1px solid var(--oh-border-light);
  box-shadow: var(--stitch-card-shadow);
  max-width: 100%;
  min-width: 0;
}

.card,
.taxonomy-empty {
  padding: clamp(1rem, 2vw, 1.5rem);
}

.card h2,
.card h3,
.card h4,
.card h5,
.taxonomy-empty h4 {
  color: var(--oh-navy-text);
  font-family: var(--font-display);
  font-weight: 800;
  letter-spacing: 0;
}

.helper-text,
.field-hint,
.inline-msg,
.account-list-meta,
.card small {
  color: var(--oh-navy-muted);
}

.card .helper-text,
.card .inline-msg,
.card .field-hint {
  color: var(--oh-navy-muted);
}

.metric-card {
  display: grid;
  gap: 0.25rem;
  min-width: 0;
  padding: 1rem;
  border: 1px solid var(--oh-border-light);
  border-radius: var(--radius-md);
  background: linear-gradient(180deg, rgb(255 255 255 / var(--ui-panel-alpha)), rgb(248 250 255 / var(--ui-panel-alpha)));
}

.metric-card span {
  color: var(--oh-navy-muted);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.metric-card strong {
  color: var(--oh-navy-text);
  font-family: var(--font-display);
  font-size: clamp(1.1rem, 1.4vw, 1.75rem);
  line-height: 1.15;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.admin-command-shell {
  display: grid;
  gap: clamp(1rem, 2vw, 1.5rem);
  min-width: 0;
  color: var(--oh-text, var(--color-text));
}

.admin-metric-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, var(--admin-metric-min, 14rem)), 1fr));
  gap: var(--admin-metric-gap, 1rem);
  min-width: 0;
}

.admin-metric-card {
  position: relative;
  overflow: hidden;
  min-width: 0;
  min-height: var(--admin-metric-min-height, 8.5rem);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: var(--admin-metric-card-gap, 1rem);
  padding: var(--admin-metric-card-padding, 1.25rem);
  overflow-wrap: anywhere;
}

.admin-metric-card > span,
.admin-metric-card p,
.admin-metric-card small,
.admin-metric-card strong {
  min-width: 0;
  max-width: 100%;
  overflow-wrap: anywhere;
}

.admin-tab-list {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.35rem;
  max-width: 100%;
  min-width: 0;
}

.admin-tab-list a {
  min-width: 0;
  min-height: 2.65rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  text-align: center;
  overflow-wrap: anywhere;
}

.admin-panel-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  min-width: 0;
}

.admin-panel-head > * {
  min-width: 0;
}

.admin-panel-head h1,
.admin-panel-head h2,
.admin-panel-head h3,
.admin-panel-head p {
  overflow-wrap: anywhere;
}

.admin-panel-meta {
  display: flex;
  align-items: flex-start;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 0.5rem;
  min-width: 0;
}

.admin-count-card {
  flex: 0 0 auto;
  display: grid;
  justify-items: end;
  gap: 0.1rem;
  min-width: 0;
}

@media (max-width: 58rem) {
  .admin-command-shell {
    gap: 1rem;
  }

  .admin-metric-grid {
    --admin-metric-min: 12rem;
  }

  .admin-panel-head {
    flex-direction: column;
    align-items: stretch;
  }

  .admin-panel-meta,
  .admin-count-card {
    width: 100%;
    justify-content: flex-start;
    justify-items: start;
  }

  .admin-tab-list {
    width: 100%;
  }

  .admin-tab-list a {
    flex: 1 1 12rem;
  }
}

@media (max-width: 36rem) {
  .admin-metric-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .admin-metric-card {
    min-height: auto;
    padding: var(--admin-metric-card-phone-padding, 1rem);
  }
}

.account-section-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  min-width: 0;
}

.account-list-head {
  display: grid;
  gap: 0.25rem;
  min-width: 0;
}

.mobile-card-list {
  display: grid;
  gap: 0.75rem;
  min-width: 0;
  margin: 0;
  padding: 0;
  list-style: none;
}

.mobile-card-list > * {
  min-width: 0;
}

.mobile-card {
  min-width: 0;
  overflow-wrap: anywhere;
}

.mobile-card-surface {
  display: grid;
  gap: var(--space-3);
  padding: clamp(1rem, 2vw, 1.35rem);
  color: var(--oh-navy-text);
  background: rgb(255 255 255 / var(--ui-panel-alpha));
  border: 1px solid var(--oh-border-light);
  border-radius: var(--radius-lg);
  box-shadow: var(--stitch-card-shadow);
}

.mobile-card-row,
.mobile-card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  min-width: 0;
}

.mobile-card-row > *,
.mobile-card-header > * {
  min-width: 0;
}

.mobile-card-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 0.5rem;
  min-width: 0;
}

.mobile-card-primary {
  display: grid;
  gap: 0.25rem;
  min-width: 0;
}

.mobile-card-primary > strong {
  color: var(--mobile-card-title-color, inherit);
  font-weight: var(--mobile-card-title-weight, 900);
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.mobile-card-primary > span {
  color: var(--mobile-card-subtitle-color, var(--mobile-meta-color, var(--oh-navy-muted)));
  font-size: 0.84rem;
  overflow-wrap: anywhere;
}

.mobile-card-surface .mobile-card-primary > strong {
  color: var(--oh-navy-text);
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 800;
}

.mobile-field-list {
  display: grid;
  gap: 0.55rem;
  min-width: 0;
}

.mobile-field {
  display: grid;
  grid-template-columns: minmax(6.5rem, 0.42fr) minmax(0, 1fr);
  align-items: start;
  gap: 0.35rem 0.75rem;
  min-width: 0;
}

.mobile-field-label {
  color: var(--mobile-field-label-color, var(--oh-navy-muted));
  font-size: 0.72rem;
  font-weight: 900;
  line-height: 1.25;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.mobile-field-value {
  min-width: 0;
  color: var(--mobile-field-value-color, inherit);
  font-weight: 800;
  overflow-wrap: anywhere;
}

.mobile-meta-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.35rem;
  min-width: 0;
  margin: 0;
  color: var(--mobile-meta-color, var(--oh-navy-muted));
  font-size: 0.84rem;
}

.desktop-only {
  display: inline-flex !important;
}

.mobile-only {
  display: none !important;
}

@media (max-width: 48rem) {
  .mobile-card-row,
  .mobile-card-header {
    flex-direction: column;
    align-items: stretch;
  }

  .mobile-card-actions {
    justify-content: flex-start;
  }

  .mobile-card-actions .btn {
    width: 100%;
  }

  .mobile-field {
    grid-template-columns: 1fr;
  }

  .desktop-only {
    display: none !important;
  }

  .mobile-only {
    display: inline-flex !important;
  }
}

.table-card-list {
  display: grid;
  gap: 0.75rem;
  min-width: 0;
  margin: 0;
  padding: 0;
  list-style: none;
}

.table-card {
  --table-card-color: var(--oh-text, var(--color-text));
  --table-card-muted: var(--oh-text-muted, var(--color-text-muted));
  --table-card-border: rgb(68 70 80 / 0.62);
  --table-card-bg: rgb(14 14 14 / 0.36);
  --table-card-field-bg: rgb(16 20 21 / 0.32);
  display: grid;
  gap: 0.75rem;
  min-width: 0;
  padding: 0.85rem;
  border: 1px solid var(--table-card-border);
  border-radius: var(--radius-sm);
  color: var(--table-card-color);
  background: var(--table-card-bg);
  overflow-wrap: anywhere;
}

.table-card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
  min-width: 0;
}

.table-card-primary {
  display: grid;
  gap: 0.22rem;
  min-width: 0;
}

.table-card-primary > strong {
  color: var(--table-card-title-color, var(--table-card-color));
  font-weight: 900;
  line-height: 1.2;
}

.table-card-primary > span,
.table-card-label {
  color: var(--table-card-muted);
  font-size: 0.72rem;
  font-weight: 850;
  line-height: 1.25;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.table-card-fields,
.table-card-metrics {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(7rem, 1fr));
  gap: 0.55rem;
  min-width: 0;
}

.table-card-field,
.table-card-metric {
  display: grid;
  align-content: start;
  gap: 0.22rem;
  min-width: 0;
  padding: 0.55rem;
  border: 1px solid var(--table-card-field-border, rgb(68 70 80 / 0.52));
  border-radius: var(--radius-sm);
  background: var(--table-card-field-bg);
}

.table-card-field-wide {
  grid-column: 1 / -1;
}

.table-card-value {
  min-width: 0;
  color: var(--table-card-value-color, var(--table-card-color));
  font-weight: 850;
  overflow-wrap: anywhere;
}

.table-card-metric .table-card-value {
  color: var(--table-card-metric-color, var(--oh-cyan, var(--color-primary)));
  font-family: "JetBrains Mono", Consolas, monospace;
  font-weight: 900;
}

.table-card-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 0.5rem;
  min-width: 0;
}

.table-card-hierarchy {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  min-width: 0;
  color: var(--table-card-muted);
  font-size: 0.74rem;
  font-weight: 850;
}

.table-card.is-child,
.table-card-child {
  margin-left: clamp(0.75rem, 4vw, 1.25rem);
  border-left: 3px solid var(--table-card-hierarchy-accent, var(--oh-cyan, var(--color-primary)));
}

.responsive-table-desktop {
  display: block;
  min-width: 0;
}

.responsive-table-mobile {
  display: none;
  min-width: 0;
}

@media (max-width: 48rem) {
  .responsive-table-desktop {
    display: none;
  }

  .responsive-table-mobile {
    display: grid;
  }

  .table-card-header,
  .table-card-actions {
    justify-content: flex-start;
  }

  .table-card-fields,
  .table-card-metrics {
    grid-template-columns: minmax(0, 1fr);
  }

  .table-card-actions .btn {
    width: 100%;
  }
}

.toolbar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.action-row {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 0.5rem;
  min-width: 0;
}

.icon-action-row {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 0.35rem;
  min-width: 0;
}

.card-action-area {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  min-width: 0;
}

.toolbar-action-area {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 0.65rem;
  min-width: 0;
}

.pagination-row {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  min-width: 0;
  padding: 1rem 1.25rem;
}

.action-row > form,
.icon-action-row > form,
.card-action-area > form,
.toolbar-action-area > form {
  margin: 0;
}

.chip,
.media-state-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 1.75rem;
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-pill);
  border: 1px solid #cbd5e1;
  background: #f8faff;
  color: var(--oh-navy-text);
  font-size: 0.72rem;
  font-weight: 900;
  line-height: 1;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.status-active,
.is-uploaded {
  border-color: #86efac;
  background: var(--oh-emerald-soft);
  color: #166534;
}

.status-inactive,
.status-returned,
.is-missing {
  border-color: #fecaca;
  background: var(--oh-crimson-soft);
  color: #991b1b;
}

.status-submitted,
.is-info {
  border-color: #fde68a;
  background: var(--oh-amber-soft);
  color: #92400e;
}

.btn,
button.btn,
a.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  min-height: var(--touch-target);
  width: auto;
  max-width: 100%;
  min-width: 0;
  padding: 0.62rem 0.95rem;
  border-radius: 0.65rem;
  border: 1px solid #cbd5e1;
  background: #ffffff;
  color: var(--oh-navy-text);
  font-weight: 800;
  line-height: 1.1;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 1px 0 rgb(15 23 42 / 0.04);
  transition: background var(--transition-fast), border-color var(--transition-fast), color var(--transition-fast), box-shadow var(--transition-fast), opacity var(--transition-fast);
}

.btn:hover,
button.btn:hover,
a.btn:hover {
  color: var(--oh-cyan);
  border-color: rgb(0 238 252 / 0.38);
  background: rgb(42 42 42 / 0.92);
}

.btn-primary,
a.btn-primary,
button.btn-primary {
  color: #002022;
  border-color: var(--oh-cyan);
  background: var(--oh-cyan);
  box-shadow: 0 10px 28px rgb(0 238 252 / 0.20);
}

.btn-primary:hover,
a.btn-primary:hover,
button.btn-primary:hover {
  color: #002022;
  border-color: var(--oh-cyan-soft);
  background: var(--oh-cyan-soft);
  box-shadow: 0 4px 0 rgb(0 238 252 / 0.72), 0 14px 30px rgb(0 238 252 / 0.18);
}

.btn-danger,
button.btn-danger,
a.btn-danger {
  color: #991b1b;
  border-color: #fecaca;
  background: #fff1f2;
}

.btn-danger:hover,
button.btn-danger:hover,
a.btn-danger:hover {
  color: #7f1d1d;
  border-color: #fca5a5;
  background: #fee2e2;
}

.btn-small {
  min-height: 2.35rem;
  padding: 0.46rem 0.72rem;
  border-radius: 0.55rem;
  font-size: 0.84rem;
}

.btn.disabled,
.btn:disabled,
button.btn:disabled,
a.btn[aria-disabled="true"] {
  opacity: 0.55;
  cursor: not-allowed;
  pointer-events: none;
}

.action-group {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.65rem;
  min-width: 0;
}

.action-group > form {
  margin: 0;
}

.action-group > .btn,
.action-group > form > .btn {
  min-width: 0;
}

input,
textarea,
select {
  min-height: 2.75rem;
  color: var(--oh-navy-text);
  background: var(--oh-alabaster-soft);
  border: 1px solid #cbd5e1;
  border-radius: 0.65rem;
}

textarea {
  min-height: 7rem;
}

input::placeholder,
textarea::placeholder {
  color: #94a3b8;
}

input:focus-visible,
textarea:focus-visible,
select:focus-visible,
button:focus-visible,
.btn:focus-visible,
summary:focus-visible {
  outline: none;
  border-color: var(--oh-cyan);
  box-shadow: var(--shadow-focus);
}

label,
.form-field,
.tool-field,
.project-search-field {
  color: var(--oh-navy-text);
  font-weight: 800;
}

.field-label,
.tool-field > span,
.project-search-field > span,
.form-field > span:first-child {
  color: var(--oh-navy-muted);
  font-size: 0.74rem;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.form-shell {
  display: grid;
  gap: 1rem;
}

.stitch-auth-card {
  display: grid;
  gap: clamp(1rem, 2vw, 1.35rem);
  width: min(100%, 35rem);
  padding: clamp(1.15rem, 2.5vw, 1.65rem);
  border: 1px solid rgb(0 238 252 / 0.28);
  border-radius: var(--radius-lg);
  background:
    linear-gradient(180deg, rgb(32 31 31 / var(--ui-panel-alpha)), rgb(16 18 20 / var(--ui-elevated-alpha))),
    rgb(14 14 14 / 0.82);
  box-shadow: var(--stitch-shadow), 0 0 0 1px rgb(0 238 252 / 0.08) inset;
  color: var(--oh-text);
}

.stitch-auth-form {
  display: grid;
  gap: 1rem;
}

.stitch-auth-form p {
  margin: 0;
  color: var(--oh-text-muted);
}

.stitch-auth-form h2 {
  margin: 0;
  color: var(--oh-text);
  font-size: clamp(1.35rem, 3vw, 1.8rem);
  letter-spacing: 0;
}

.stitch-auth-form strong {
  color: var(--oh-text);
}

.stitch-auth-field {
  display: grid;
  gap: 0.45rem;
  color: var(--oh-text);
  font-weight: 800;
}

.stitch-auth-field > span:first-child {
  color: var(--oh-text-muted);
  font-size: 0.74rem;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.stitch-auth-field .field-hint {
  color: var(--oh-text-muted);
  font-size: 0.86rem;
  font-weight: 600;
}

.stitch-auth-field input {
  width: 100%;
  min-height: 2.9rem;
  color: var(--oh-text);
  background: rgb(29 32 34 / var(--ui-control-alpha));
  border: 1px solid rgb(132 148 149 / 0.42);
  border-radius: var(--radius-md);
  box-shadow: inset 0 1px 0 rgb(255 255 255 / 0.03);
}

.stitch-auth-field input::placeholder {
  color: rgb(181 190 190 / 0.62);
}

.stitch-auth-field input:read-only {
  color: var(--oh-text-muted);
  background: rgb(14 14 14 / 0.62);
  border-color: rgb(132 148 149 / 0.3);
}

.stitch-auth-field input:focus-visible {
  border-color: var(--oh-cyan);
  box-shadow: 0 0 0 3px rgb(0 238 252 / 0.18), inset 0 1px 0 rgb(255 255 255 / 0.04);
}

.stitch-auth-actions {
  display: flex;
  justify-content: flex-end;
}

.stitch-auth-actions .btn-primary {
  color: #002022;
  border-color: var(--oh-cyan);
  background: var(--oh-cyan);
  box-shadow: 0 10px 28px rgb(0 238 252 / 0.20);
}

.stitch-auth-actions .btn-primary:hover,
.stitch-auth-actions .btn-primary:focus-visible {
  color: #002022;
  border-color: var(--oh-cyan-soft);
  background: var(--oh-cyan-soft);
  box-shadow: 0 4px 0 rgb(0 238 252 / 0.72), 0 14px 30px rgb(0 238 252 / 0.18);
}

.stitch-auth-card .error-box {
  border-color: rgb(248 113 113 / 0.45);
  background: rgb(127 29 29 / 0.3);
  color: #fecaca;
}

.stitch-auth-card .info-box {
  padding: 0.9rem 1rem;
  border: 1px solid rgb(0 238 252 / 0.34);
  border-radius: var(--radius-lg);
  background: rgb(0 238 252 / 0.11);
  color: var(--oh-text);
  font-weight: 800;
}

@media (max-width: 40rem) {
  .stitch-auth-card {
    padding: 1rem;
  }
}

.search-input-wrap {
  position: relative;
}

.search-icon {
  position: absolute;
  left: 0.85rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--oh-navy-muted);
  pointer-events: none;
}

.search-input-wrap input {
  padding-left: 2.5rem;
}

table {
  border-collapse: separate;
  border-spacing: 0;
  color: var(--oh-navy-text);
}

table th,
table td {
  padding: 0.95rem 1rem;
  border-bottom: 1px solid #e5e7eb;
  text-align: left;
  vertical-align: top;
}

table th {
  color: var(--oh-navy-muted);
  background: #f8faff;
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

table tr:last-child td {
  border-bottom: 0;
}

.tree-inspector-disclosure,
.notification-menu {
  position: relative;
}

details > summary {
  cursor: pointer;
}

.notification-menu {
  width: 100%;
}

.notification-menu > .notification-menu-summary {
  min-width: 2.75rem;
  color: var(--oh-cyan-soft);
  border-color: rgb(0 238 252 / 0.26);
  background: rgb(19 24 26 / var(--ui-control-alpha));
  box-shadow: 0 14px 34px rgb(0 0 0 / 0.26);
  transition: border-color var(--transition-fast), background var(--transition-fast), color var(--transition-fast), box-shadow var(--transition-fast);
}

.notification-menu > .notification-menu-summary:hover,
.notification-menu[open] > .notification-menu-summary {
  color: var(--oh-cyan);
  border-color: rgb(0 238 252 / 0.46);
  background: rgb(29 32 34 / 0.92);
  box-shadow: 0 0 0 1px rgb(0 238 252 / 0.18), 0 18px 44px rgb(0 0 0 / 0.34);
}

.notification-menu > .notification-menu-summary:focus-visible {
  color: var(--oh-cyan);
  border-color: var(--oh-cyan);
  box-shadow: 0 0 0 3px rgb(0 238 252 / 0.22), 0 18px 44px rgb(0 0 0 / 0.34);
}

.shell-notification-anchor .notification-menu-summary {
  color: var(--oh-cyan-soft);
  border-color: rgb(0 238 252 / 0.30);
  background: rgb(16 20 21 / var(--ui-control-alpha));
}

.shell-notification-anchor .notification-menu-summary:hover,
.shell-notification-anchor .notification-menu[open] > .notification-menu-summary {
  color: var(--oh-cyan);
  background: rgb(26 34 36 / 0.94);
}

.notification-bell-label {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.notification-bell-icon {
  width: 1.25rem;
  height: 1.25rem;
  fill: currentColor;
}

.shell-notification-anchor .notification-bell-icon {
  color: var(--oh-cyan);
}

.notification-menu-panel {
  position: absolute;
  right: 0;
  top: calc(100% + 0.7rem);
  z-index: 80;
  width: min(24rem, calc(100dvw - var(--overlay-safe-inline-start) - var(--overlay-safe-inline-end)));
  max-width: calc(100dvw - var(--overlay-safe-inline-start) - var(--overlay-safe-inline-end));
  max-height: min(28rem, calc(100dvh - var(--overlay-safe-block-start) - var(--overlay-safe-block-end) - var(--touch-target) - var(--space-3)));
  padding: 1rem;
  display: grid;
  grid-template-rows: auto minmax(0, auto) auto auto;
  gap: 1rem;
  overflow: auto;
  overflow-x: hidden;
  overscroll-behavior: contain;
  color: var(--oh-text);
  border: 1px solid rgb(68 70 80 / 0.76);
  border-radius: var(--radius-lg);
  background:
    linear-gradient(180deg, rgb(28 27 27 / var(--ui-panel-alpha)), rgb(16 20 21 / var(--ui-panel-alpha)));
  box-shadow: 0 24px 80px rgb(0 0 0 / 0.42);
  backdrop-filter: blur(16px);
}

.notification-menu-panel a {
  color: var(--oh-cyan-soft);
}

.notification-menu-panel * {
  min-width: 0;
}

.notification-menu-panel a:hover {
  color: var(--oh-cyan);
}

.notification-menu-head,
.notification-menu-footer,
.account-list-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.notification-menu-head,
.notification-menu-footer,
.notification-center-head {
  min-width: 0;
}

.notification-menu-footer {
  align-items: center;
  position: sticky;
  bottom: 0;
  padding-top: 0.25rem;
  background: linear-gradient(180deg, rgb(16 20 21 / 0), rgb(16 20 21 / var(--ui-panel-alpha)) 35%);
}

.notification-menu-head .helper-text {
  margin: 0;
}

.notification-preview-list,
.notification-center-list {
  list-style: none;
  display: grid;
  gap: 0.65rem;
  margin: 0;
  padding: 0;
}

.notification-preview-list {
  max-height: min(12rem, 34vh);
  min-height: 0;
  overflow: auto;
  overscroll-behavior: contain;
}

.notification-preview-list > .notification-entry,
.notification-center-list > .notification-entry {
  --notification-severity-accent: rgb(0 238 252 / 0.48);
  position: relative;
  overflow: hidden;
  padding: 0.85rem;
  color: var(--oh-text);
  border: 1px solid rgb(68 70 80 / 0.72);
  border-radius: var(--radius-md);
  background:
    linear-gradient(180deg, rgb(28 27 27 / 0.74), rgb(16 20 21 / 0.76));
  box-shadow: inset 0 1px 0 var(--notification-severity-accent);
}

.notification-preview-list > .notification-entry .account-list-row {
  min-width: 0;
}

.notification-preview-list > .notification-entry .account-list-head {
  min-width: 0;
}

.notification-preview-list > .notification-entry strong,
.notification-preview-list > .notification-entry .helper-text,
.notification-preview-list > .notification-entry .account-list-meta {
  overflow-wrap: anywhere;
}

.notification-preview-list > .notification-entry strong,
.notification-preview-list > .notification-entry .helper-text {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
}

.notification-preview-list > .notification-entry strong {
  -webkit-line-clamp: 2;
}

.notification-preview-list > .notification-entry .helper-text {
  -webkit-line-clamp: 3;
}

.notification-preview-list > .notification-entry::before,
.notification-center-list > .notification-entry::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 3px;
  background: rgb(197 198 210 / 0.22);
}

.notification-entry-info {
  --notification-severity-accent: rgb(0 238 252 / 0.50);
}

.notification-entry-success {
  --notification-severity-accent: rgb(5 150 105 / 0.52);
}

.notification-entry-warning {
  --notification-severity-accent: rgb(255 211 59 / 0.56);
}

.notification-preview-list > .notification-entry-unread,
.notification-center-list > .notification-entry-unread {
  border-color: rgb(0 238 252 / 0.46);
  background:
    linear-gradient(180deg, rgb(0 238 252 / 0.12), rgb(16 20 21 / 0.86));
  box-shadow: inset 0 1px 0 var(--notification-severity-accent), 0 0 28px rgb(0 238 252 / 0.08);
}

.notification-preview-list > .notification-entry-unread::before,
.notification-center-list > .notification-entry-unread::before {
  background: var(--oh-cyan);
  box-shadow: 0 0 18px rgb(0 238 252 / 0.38);
}

.notification-preview-list > .notification-entry-read,
.notification-center-list > .notification-entry-read {
  border-color: rgb(68 70 80 / 0.60);
  background:
    linear-gradient(180deg, rgb(28 27 27 / 0.62), rgb(16 20 21 / 0.66));
}

.notification-preview-list > .notification-entry-read::before,
.notification-center-list > .notification-entry-read::before {
  background: rgb(197 198 210 / 0.18);
}

.notification-entry strong,
.notification-center-card h3,
.notification-center-card h4,
.notification-menu-panel strong {
  color: var(--oh-text);
}

.notification-entry .helper-text,
.notification-entry .account-list-meta,
.notification-center-card .helper-text,
.notification-menu-panel .helper-text,
.notification-menu-panel .account-list-meta {
  color: var(--oh-text-muted);
}

.taxonomy-empty {
  text-align: center;
  color: var(--oh-navy-text);
  background:
    linear-gradient(180deg, rgb(255 255 255 / var(--ui-panel-alpha)), rgb(248 250 255 / var(--ui-panel-alpha)));
  border: 1px dashed #cbd5e1;
  box-shadow: var(--stitch-card-shadow);
}

.taxonomy-empty p {
  color: var(--oh-navy-muted);
}

.notification-center-card {
  display: grid;
  gap: 1rem;
  min-width: 0;
  color: var(--oh-text);
  border: 1px solid rgb(68 70 80 / 0.72);
  background:
    linear-gradient(180deg, rgb(28 27 27 / var(--ui-panel-alpha)), rgb(16 20 21 / var(--ui-panel-alpha)));
  box-shadow: 0 22px 60px rgb(0 0 0 / 0.24);
}

.notification-center-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.notification-center-toolbar {
  flex: 1 1 22rem;
  justify-content: flex-end;
}

.notification-center-toolbar > form {
  display: flex;
  min-width: 0;
}

.notification-center-toolbar .helper-text {
  min-height: 2.65rem;
  margin: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 0.75rem;
  border: 1px solid rgb(68 70 80 / 0.64);
  border-radius: var(--radius-md);
  color: var(--oh-text-muted);
  background: rgb(16 20 21 / 0.5);
  font-weight: 800;
  white-space: nowrap;
}

.notification-center-card .btn,
.notification-menu-panel .btn {
  color: var(--oh-text);
  border-color: rgb(68 70 80 / 0.84);
  background: rgb(29 32 34 / 0.74);
}

.notification-center-card .btn:hover,
.notification-menu-panel .btn:hover {
  color: var(--oh-cyan);
  border-color: rgb(0 238 252 / 0.38);
  background: rgb(42 42 42 / 0.92);
}

.notification-center-card .btn-primary,
.notification-menu-panel .btn-primary {
  color: #00363a;
  border-color: var(--oh-cyan);
  background: var(--oh-cyan);
  box-shadow: 0 0 20px rgb(0 238 252 / 0.18);
}

.notification-center-card .btn-primary:hover,
.notification-menu-panel .btn-primary:hover {
  color: #002022;
  border-color: #d3fbff;
  background: #d3fbff;
}

.notification-center-card .mobile-card-actions {
  min-width: 0;
}

.notification-center-card .mobile-card-actions > form {
  display: flex;
  min-width: 0;
}

.notification-center-card .mobile-card-actions .btn,
.notification-center-toolbar .btn {
  white-space: normal;
}

.notification-center-empty,
.notification-preview-empty {
  margin: 0;
  padding: 1rem;
  color: var(--oh-text);
  border-color: rgb(68 70 80 / 0.72);
  background: rgb(16 20 21 / 0.62);
  box-shadow: none;
}

.notification-center-empty h4,
.notification-preview-empty h4 {
  color: var(--oh-text);
}

.notification-center-empty p,
.notification-preview-empty p {
  color: var(--oh-text-muted);
}

.select-tile,
.unit-chip-toggle {
  transition: border-color var(--transition-fast), background var(--transition-fast), color var(--transition-fast), box-shadow var(--transition-fast), transform var(--transition-fast);
}

.select-tile,
.unit-chip-toggle {
  border: 1px solid #cbd5e1;
  border-radius: var(--radius-md);
  background: #ffffff;
}

.select-tile.is-selected,
.unit-chip-toggle.is-selected {
  border-color: var(--oh-cyan);
  background: var(--oh-cyan-soft);
  color: #00363a;
  box-shadow: 0 0 0 3px rgb(0 238 252 / 0.16);
}

.drawer,
.modal,
[role="dialog"]:not(.tree-asset-modal):not(.website-confirm-dialog):not(.file-preview-modal) {
  max-width: 100%;
  min-width: 0;
  color: var(--oh-navy-text);
  background: rgb(255 255 255 / var(--ui-panel-alpha));
  border: 1px solid #e2e8f0;
  border-radius: var(--radius-xl);
  box-shadow: 0 30px 90px rgb(15 23 42 / 0.28);
  backdrop-filter: blur(18px);
}

@media (max-width: 44rem) {
  .action-row.action-row-mobile-stack,
  .action-group.action-group-mobile-stack {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    align-items: stretch;
    justify-items: stretch;
  }

  .action-row.action-row-mobile-stack > .btn,
  .action-row.action-row-mobile-stack > form,
  .action-row.action-row-mobile-stack > form > .btn,
  .action-row.action-row-mobile-stack > label.btn,
  .action-group.action-group-mobile-stack > .btn,
  .action-group.action-group-mobile-stack > form,
  .action-group.action-group-mobile-stack > form > .btn,
  .action-group.action-group-mobile-stack > label.btn {
    width: 100%;
  }

  .action-row.action-row-mobile-stack > form,
  .action-group.action-group-mobile-stack > form {
    display: grid;
    gap: 0.65rem;
  }

  .shell-sidebar-utility,
  .shell-notification-anchor {
    top: calc(var(--safe-top) + var(--shell-mobile-utility-offset));
  }

  .shell-sidebar-utility {
    left: calc(var(--safe-left) + var(--shell-mobile-utility-offset));
  }

  .shell-notification-anchor {
    right: calc(var(--safe-right) + var(--shell-mobile-utility-offset));
  }

  .shell-notification-anchor .notification-menu-panel {
    right: calc(var(--overlay-safe-inline-end) - var(--safe-right) - var(--shell-mobile-utility-offset));
    max-height: calc(100dvh - var(--safe-top) - var(--shell-mobile-utility-offset) - var(--touch-target) - var(--space-3) - var(--overlay-safe-block-end));
  }

  .notification-menu-footer {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    align-items: stretch;
  }

  .notification-menu-footer .btn {
    width: 100%;
  }

  .drawer,
  .modal,
  [role="dialog"]:not(.tree-asset-modal):not(.website-confirm-dialog):not(.file-preview-modal) {
    max-width: calc(100dvw - var(--overlay-safe-inline-start) - var(--overlay-safe-inline-end));
    max-height: calc(100dvh - var(--overlay-safe-block-start) - var(--overlay-safe-block-end));
    overflow: auto;
    overscroll-behavior: contain;
  }

  .stitch-page-header {
    padding: 1.15rem;
    border-radius: var(--radius-lg);
  }

  .account-section-head,
  .notification-menu-head,
  .notification-center-head,
  .account-list-row {
    flex-direction: column;
    align-items: stretch;
  }

  .notification-center-toolbar {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    justify-content: stretch;
    width: 100%;
  }

  .notification-center-toolbar > form,
  .notification-center-toolbar > form > .btn,
  .notification-center-toolbar > .btn,
  .notification-center-toolbar .helper-text {
    width: 100%;
  }

  .notification-center-toolbar > form {
    display: grid;
  }

  .notification-center-toolbar .helper-text {
    grid-column: 1 / -1;
    min-height: 2.4rem;
    white-space: normal;
  }

  .notification-center-card .mobile-card-actions {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    align-items: stretch;
  }

  .notification-center-card .mobile-card-actions > form,
  .notification-center-card .mobile-card-actions .btn {
    width: 100%;
  }
}

.filter-bar,
.stitch-integrated-filter-row {
  display: grid;
  grid-template-columns: var(--filter-bar-columns, var(--stitch-integrated-filter-columns, minmax(16rem, 1fr) auto));
  align-items: end;
  gap: 0.75rem;
  min-width: 0;
}

.filter-bar .filter-search-field,
.filter-bar .filter-select-field,
.stitch-integrated-filter-row .filter-search-field,
.stitch-integrated-filter-row .filter-select-field,
.stitch-integrated-filter-row .project-search-field,
.stitch-integrated-filter-row .stitch-portfolio-search-field {
  grid-column: auto;
  min-width: 0;
}

.filter-bar label,
.filter-bar .tool-field,
.filter-bar .filter-search-field,
.filter-bar .filter-select-field,
.filter-bar .searchable-dropdown,
.stitch-integrated-filter-row label,
.stitch-integrated-filter-row .tool-field,
.stitch-integrated-filter-row .project-search-field,
.stitch-integrated-filter-row .stitch-portfolio-search-field,
.stitch-integrated-filter-row .stitch-filter-combobox,
.stitch-integrated-filter-row .searchable-dropdown {
  margin-block: 0;
}

.filter-clear-action,
.stitch-integrated-filter-row .btn {
  align-self: end;
  justify-self: end;
}

.filter-panel-row,
.stitch-table-filter-row {
  padding: 1.25rem;
  border-bottom: 1px solid rgb(68 70 80 / 0.64);
  background: rgb(16 20 21 / 0.26);
}

.stitch-instant-results-summary {
  margin: 0;
  padding: 0.85rem 1.25rem;
  border-bottom: 1px solid rgb(68 70 80 / 0.5);
  color: var(--oh-text-muted);
  font-size: 0.9rem;
  font-weight: 800;
}

.filter-search-field,
.filter-select-field,
.stitch-filter-combobox {
  color: var(--oh-text);
  min-width: 0;
}

.filter-search-field > span,
.filter-select-field > span {
  color: var(--oh-text-muted);
}

.filter-search-field {
  position: relative;
  display: grid;
}

.filter-search-field .search-input-wrap {
  width: 100%;
  min-width: 0;
}

.filter-search-field input,
.filter-select-field select {
  width: 100%;
  min-width: 0;
  color: var(--oh-text);
  background: rgb(16 20 21 / var(--ui-control-alpha));
  border-color: rgb(68 70 80 / 0.8);
}

.filter-search-field input::placeholder {
  color: rgb(197 198 210 / 0.58);
}

.filter-search-field > .material-symbols-outlined {
  position: absolute;
  left: 0.85rem;
  top: 50%;
  z-index: 1;
  transform: translateY(-50%);
  color: var(--oh-text-muted);
  pointer-events: none;
}

.filter-search-field > .material-symbols-outlined + input {
  padding-left: 2.6rem;
}

.filter-select-field select {
  min-height: 2.75rem;
  padding: 0.75rem 2.5rem 0.75rem 0.9rem;
  border: 1px solid rgb(68 70 80 / 0.78);
  border-radius: var(--radius-lg);
  color-scheme: dark;
  background:
    linear-gradient(180deg, rgb(28 27 27 / var(--ui-control-alpha)), rgb(18 19 20 / var(--ui-control-alpha)));
  box-shadow: inset 0 1px 0 rgb(255 255 255 / 0.04);
}

.filter-select-field select option {
  color: var(--oh-text);
  background-color: rgb(18 19 20);
}

.filter-select-field select:focus {
  outline: none;
  border-color: rgb(0 238 252 / 0.62);
  box-shadow: 0 0 0 3px rgb(0 238 252 / 0.14);
}

.filter-select-field .searchable-dropdown,
.stitch-filter-combobox .searchable-dropdown {
  min-width: 0;
}

.filter-select-field .searchable-dropdown-trigger,
.filter-select-field .searchable-dropdown-search,
.stitch-filter-combobox .searchable-dropdown-trigger,
.stitch-filter-combobox .searchable-dropdown-search {
  width: 100%;
  min-height: 2.75rem;
  border-color: rgb(68 70 80 / 0.8);
  border-radius: var(--radius-md);
  background: rgb(16 20 21 / var(--ui-control-alpha));
  color: var(--oh-text);
}

.filter-select-field .searchable-dropdown-trigger,
.stitch-filter-combobox .searchable-dropdown-trigger {
  padding: 0.72rem 0.85rem;
}

.filter-select-field .searchable-dropdown-trigger.is-empty .searchable-dropdown-selected,
.stitch-filter-combobox .searchable-dropdown-trigger.is-empty .searchable-dropdown-selected {
  color: rgb(197 198 210 / 0.62);
}

.filter-select-field .searchable-dropdown-search::placeholder,
.stitch-filter-combobox .searchable-dropdown-search::placeholder {
  color: rgb(197 198 210 / 0.58);
}

.filter-select-field .searchable-dropdown-panel,
.stitch-filter-combobox .searchable-dropdown-panel {
  border-color: rgb(68 70 80 / 0.88);
  background: rgb(16 20 21 / var(--ui-elevated-alpha));
  box-shadow: 0 24px 50px rgb(0 0 0 / 0.34);
}

.filter-select-field .searchable-dropdown-option,
.stitch-filter-combobox .searchable-dropdown-option {
  color: var(--oh-text-muted);
}

.filter-select-field .searchable-dropdown-option:hover,
.filter-select-field .searchable-dropdown-option:focus-visible,
.filter-select-field .searchable-dropdown-option.is-selected,
.stitch-filter-combobox .searchable-dropdown-option:hover,
.stitch-filter-combobox .searchable-dropdown-option:focus-visible,
.stitch-filter-combobox .searchable-dropdown-option.is-selected {
  border-color: rgb(0 238 252 / 0.26);
  background: rgb(0 238 252 / 0.1);
  color: var(--oh-text);
}

@media (max-width: 48rem) {
  .filter-bar,
  .stitch-integrated-filter-row {
    grid-template-columns: minmax(0, 1fr);
    width: 100%;
  }

  .filter-bar .filter-search-field,
  .filter-bar .filter-select-field,
  .filter-bar .searchable-dropdown,
  .filter-bar .search-input-wrap,
  .filter-bar input:not([type="hidden"]),
  .filter-bar select,
  .stitch-integrated-filter-row .filter-search-field,
  .stitch-integrated-filter-row .filter-select-field,
  .stitch-integrated-filter-row .searchable-dropdown,
  .stitch-integrated-filter-row .search-input-wrap,
  .stitch-integrated-filter-row input:not([type="hidden"]),
  .stitch-integrated-filter-row select {
    width: 100%;
    min-width: 0;
  }

  .filter-clear-action,
  .filter-bar > .btn,
  .stitch-integrated-filter-row > .btn {
    width: 100%;
    justify-content: center;
    justify-self: stretch;
  }
}

.action-menu {
  position: relative;
  display: inline-flex;
  justify-content: flex-end;
}

.action-menu-trigger,
.action-menu > summary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  list-style: none;
  cursor: pointer;
}

.action-menu-trigger::-webkit-details-marker,
.action-menu > summary::-webkit-details-marker {
  display: none;
}

.action-menu-panel {
  position: absolute;
  right: 0;
  top: calc(100% + 0.65rem);
  z-index: 90;
  width: min(var(--action-menu-panel-width, 30rem), calc(100dvw - var(--overlay-safe-inline-start) - var(--overlay-safe-inline-end)));
  max-width: calc(100dvw - var(--overlay-safe-inline-start) - var(--overlay-safe-inline-end));
  max-height: calc(100dvh - var(--overlay-safe-block-start) - var(--overlay-safe-block-end));
  display: grid;
  gap: 1rem;
  padding: 1rem;
  border: 1px solid rgb(68 70 80 / 0.84);
  border-radius: var(--radius-lg);
  color: var(--oh-text);
  background: var(--action-menu-panel-bg, rgb(29 32 34 / var(--ui-panel-alpha)));
  box-shadow: 0 28px 90px rgb(0 0 0 / 0.44);
  backdrop-filter: blur(18px);
  text-align: left;
  overflow: auto;
  overflow-x: hidden;
  overscroll-behavior: contain;
}

.action-menu-panel h3 {
  margin: 0 0 0.25rem;
  color: var(--oh-text);
  font-family: var(--font-display);
}

.action-menu-panel p {
  margin: 0;
}

.stitch-floating-details-panel {
  position: fixed !important;
  right: auto !important;
  bottom: auto !important;
  z-index: 1200 !important;
  max-width: calc(100dvw - var(--overlay-safe-inline-start) - var(--overlay-safe-inline-end));
  overflow: auto;
  overflow-x: hidden;
  overscroll-behavior: contain;
}

.stitch-action-panel input:not([type="checkbox"]):not([type="radio"]):not([type="range"]),
.stitch-action-panel select,
.stitch-action-panel textarea,
.stitch-panel-form input:not([type="checkbox"]):not([type="radio"]):not([type="range"]),
.stitch-panel-form select,
.stitch-panel-form textarea {
  color: var(--oh-text);
  background: rgb(12 15 16 / 0.92);
  border-color: rgb(68 70 80 / 0.84);
}

.stitch-action-panel input::placeholder,
.stitch-action-panel textarea::placeholder,
.stitch-panel-form input::placeholder,
.stitch-panel-form textarea::placeholder {
  color: rgb(197 198 210 / 0.58);
}

.stitch-action-panel select option,
.stitch-panel-form select option {
  color: var(--oh-text);
  background: rgb(16 20 21);
}

.stitch-action-panel input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):focus,
.stitch-action-panel select:focus,
.stitch-action-panel textarea:focus,
.stitch-panel-form input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):focus,
.stitch-panel-form select:focus,
.stitch-panel-form textarea:focus {
  border-color: rgb(0 238 252 / 0.72);
  outline: 3px solid rgb(0 238 252 / 0.12);
  box-shadow: none;
}

.stitch-action-panel input:disabled,
.stitch-action-panel select:disabled,
.stitch-action-panel textarea:disabled,
.stitch-panel-form input:disabled,
.stitch-panel-form select:disabled,
.stitch-panel-form textarea:disabled {
  color: rgb(197 198 210 / 0.48);
  background: rgb(29 32 34 / 0.44);
  border-color: rgb(68 70 80 / 0.46);
}

.stitch-action-panel input[aria-invalid="true"],
.stitch-action-panel select[aria-invalid="true"],
.stitch-action-panel textarea[aria-invalid="true"],
.stitch-action-panel input.is-invalid,
.stitch-action-panel select.is-invalid,
.stitch-action-panel textarea.is-invalid,
.stitch-panel-form input[aria-invalid="true"],
.stitch-panel-form select[aria-invalid="true"],
.stitch-panel-form textarea[aria-invalid="true"],
.stitch-panel-form input.is-invalid,
.stitch-panel-form select.is-invalid,
.stitch-panel-form textarea.is-invalid {
  border-color: rgb(255 86 86 / 0.72);
  box-shadow: 0 0 0 3px rgb(255 86 86 / 0.14);
}

@media (max-width: 48rem) {
  .action-menu-panel {
    position: fixed;
    left: max(1rem, var(--overlay-safe-inline-start));
    right: max(1rem, var(--overlay-safe-inline-end));
    top: calc(var(--overlay-safe-block-start) + 4.5rem);
    width: auto;
    max-height: calc(100dvh - var(--overlay-safe-block-start) - var(--overlay-safe-block-end) - 5.5rem);
    overflow: auto;
  }
}

.assistant-widget {
  position: fixed;
  right: calc(var(--space-5) + var(--safe-right));
  bottom: calc(var(--space-5) + var(--safe-bottom));
  z-index: 80;
  --assistant-cyan: var(--oh-cyan, #00eefc);
  --assistant-cyan-soft: var(--oh-cyan-soft, #d3fbff);
  --assistant-surface: rgb(29 32 34 / var(--ui-control-alpha));
  --assistant-surface-strong: rgb(39 42 44 / var(--ui-panel-alpha));
  --assistant-border: rgb(132 148 149 / 0.22);
  --assistant-text: var(--oh-text, #e0e3e5);
  --assistant-muted: var(--oh-text-muted, #c5c6d2);
  --assistant-dark-text: var(--oh-navy-text, #0f172a);
  display: flex;
  flex-direction: column-reverse;
  align-items: flex-end;
  gap: 0.85rem;
  pointer-events: none;
}

.assistant-widget > * {
  pointer-events: auto;
}

.assistant-widget.is-open {
  gap: 0;
}

.assistant-widget.is-open .assistant-widget-button {
  display: none;
}

.app-shell.has-mobile-quicknav .assistant-widget,
.stitch-shell.has-mobile-quicknav .assistant-widget {
  bottom: calc(var(--mobile-quicknav-height) + var(--space-4) + var(--safe-bottom));
}

.assistant-widget-button,
.assistant-icon-button,
.assistant-send-button,
.assistant-feedback-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  border: 1px solid var(--assistant-border);
  color: var(--assistant-text);
  background: rgb(16 20 21 / var(--ui-control-alpha));
  box-shadow: 0 16px 34px rgb(0 0 0 / 0.32), inset 0 1px 0 rgb(255 255 255 / 0.05);
  transition: border-color var(--transition-fast), background var(--transition-fast), color var(--transition-fast), box-shadow var(--transition-fast), transform var(--transition-fast);
}

.assistant-widget-button {
  position: relative;
  width: 4.5rem;
  height: 4.5rem;
  border-radius: 50%;
  color: var(--assistant-cyan);
  border-color: rgb(0 238 252 / 0.38);
  background:
    radial-gradient(circle at 32% 24%, rgb(0 238 252 / 0.2), transparent 38%),
    rgb(16 20 21 / var(--ui-control-alpha));
  backdrop-filter: blur(16px);
  box-shadow:
    0 22px 44px rgb(0 0 0 / 0.42),
    0 0 18px rgb(0 219 232 / 0.18),
    inset 0 1px 0 rgb(255 255 255 / 0.08);
}

.assistant-widget-button .material-symbols-outlined {
  font-size: 2.2rem;
  transition: transform var(--transition-fast);
}

.assistant-widget-status-dot,
.assistant-online-dot {
  display: inline-block;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 9px rgb(34 197 94 / 0.72);
}

.assistant-widget-status-dot {
  position: absolute;
  top: 0.48rem;
  right: 0.48rem;
  width: 0.72rem;
  height: 0.72rem;
  border: 2px solid rgb(16 20 21 / 0.95);
}

.assistant-widget-button:hover,
.assistant-icon-button:hover,
.assistant-send-button:hover,
.assistant-feedback-button:hover {
  border-color: rgb(0 238 252 / 0.56);
  color: var(--assistant-cyan);
  background: var(--assistant-surface-strong);
}

.assistant-widget-button:hover {
  transform: translateY(-1px);
  box-shadow:
    0 24px 48px rgb(0 0 0 / 0.48),
    0 0 24px rgb(0 219 232 / 0.28),
    inset 0 1px 0 rgb(255 255 255 / 0.1);
}

.assistant-widget-button:hover .material-symbols-outlined {
  transform: scale(1.08);
}

.assistant-widget-button[aria-expanded="true"] {
  color: var(--assistant-dark-text);
  border-color: var(--assistant-cyan);
  background: var(--assistant-cyan);
}

.assistant-panel {
  width: min(32rem, calc(100dvw - var(--overlay-safe-inline-start) - var(--overlay-safe-inline-end)));
  max-width: calc(100dvw - var(--overlay-safe-inline-start) - var(--overlay-safe-inline-end));
  min-width: 0;
  height: min(46rem, calc(100dvh - 4rem));
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto auto auto;
  overflow: hidden;
  border: 1px solid rgb(0 238 252 / 0.2);
  border-radius: var(--radius-lg);
  background:
    radial-gradient(circle at 18% 0%, rgb(0 238 252 / 0.09), transparent 15rem),
    linear-gradient(180deg, rgb(16 20 21 / var(--ui-elevated-alpha)), rgb(8 12 20 / var(--ui-panel-alpha)));
  box-shadow:
    0 30px 68px rgb(0 0 0 / 0.56),
    0 0 28px rgb(0 219 232 / 0.1),
    inset 0 1px 0 rgb(255 255 255 / 0.06);
  backdrop-filter: blur(22px);
}

.assistant-panel[hidden] {
  display: none;
}

.assistant-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.85rem;
  padding: 1rem;
  border-bottom: 1px solid rgb(132 148 149 / 0.16);
  background: rgb(16 20 21 / 0.5);
}

.assistant-panel-identity {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
}

.assistant-title-block {
  display: grid;
  gap: 0.2rem;
  min-width: 0;
}

.assistant-panel-head h2 {
  margin: 0;
  color: var(--assistant-text);
  font-size: 1.05rem;
  line-height: 1.2;
  font-weight: 800;
}

.assistant-role-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  min-width: 0;
  color: var(--assistant-cyan-soft);
  font-size: 0.74rem;
  font-weight: 800;
  line-height: 1.2;
}

.assistant-role-badge .material-symbols-outlined {
  color: var(--assistant-cyan);
  font-size: 0.85rem;
}

.assistant-panel-actions {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.assistant-mode-selector {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  padding: 0.75rem 1rem 0;
}

.assistant-mode-option {
  min-height: 2rem;
  padding: 0.38rem 0.7rem;
  border: 1px solid var(--assistant-border);
  border-radius: var(--radius-pill);
  color: var(--assistant-muted);
  background: rgb(39 42 44 / 0.62);
  font: inherit;
  font-size: 0.76rem;
  font-weight: 800;
  line-height: 1.2;
  transition: border-color var(--transition-fast), background var(--transition-fast), color var(--transition-fast);
}

.assistant-mode-option:hover,
.assistant-mode-option:focus-visible {
  color: var(--assistant-text);
  border-color: rgb(0 238 252 / 0.46);
  background: rgb(0 238 252 / 0.08);
}

.assistant-mode-option.is-active {
  color: var(--assistant-dark-text);
  border-color: var(--assistant-cyan);
  background: var(--assistant-cyan);
}

.assistant-icon-button,
.assistant-send-button,
.assistant-feedback-button {
  width: 2.1rem;
  height: 2.1rem;
  padding: 0;
  border-radius: 50%;
  box-shadow: none;
}

.assistant-icon-button .material-symbols-outlined {
  font-size: 1.15rem;
}

.assistant-avatar {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 2rem;
  height: 2rem;
  border: 1px solid rgb(0 238 252 / 0.28);
  border-radius: 50%;
  color: var(--assistant-cyan);
  background: rgb(0 238 252 / 0.08);
}

.assistant-avatar-large {
  width: 2.5rem;
  height: 2.5rem;
  border-color: rgb(0 238 252 / 0.42);
  background: rgb(0 238 252 / 0.12);
}

.assistant-avatar .material-symbols-outlined {
  font-size: 1rem;
}

.assistant-avatar-large .material-symbols-outlined {
  font-size: 1.25rem;
}

.assistant-online-dot {
  position: absolute;
  right: 0.05rem;
  bottom: 0.05rem;
  width: 0.62rem;
  height: 0.62rem;
  border: 2px solid rgb(16 20 21 / 0.95);
}

.assistant-messages {
  display: grid;
  align-content: start;
  gap: 0.95rem;
  min-height: 0;
  padding: 1rem;
  overflow-y: auto;
  scrollbar-color: rgb(132 148 149 / 0.32) transparent;
  scrollbar-width: thin;
}

.assistant-messages::-webkit-scrollbar {
  width: 0.28rem;
}

.assistant-messages::-webkit-scrollbar-track {
  background: transparent;
}

.assistant-messages::-webkit-scrollbar-thumb {
  border-radius: var(--radius-pill);
  background: rgb(132 148 149 / 0.32);
}

.assistant-message {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  max-width: 95%;
  min-width: 0;
}

.assistant-message.is-user {
  justify-self: end;
  max-width: 88%;
}

.assistant-message.is-assistant,
.assistant-message.is-error {
  justify-self: start;
}

.assistant-message-stack {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  min-width: 0;
}

.assistant-message.is-user .assistant-message-stack {
  align-items: flex-end;
}

.assistant-message-body {
  padding: 0.78rem 0.9rem;
  border: 1px solid rgb(132 148 149 / 0.16);
  border-radius: 1rem 1rem 1rem 0.25rem;
  color: var(--assistant-text);
  background: var(--assistant-surface);
  font-size: 0.9rem;
  line-height: 1.45;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
  box-shadow: inset 0 1px 0 rgb(255 255 255 / 0.04);
}

.assistant-message.is-user .assistant-message-body {
  color: var(--assistant-dark-text);
  border-color: rgb(0 238 252 / 0.7);
  border-radius: 1rem 1rem 0.25rem 1rem;
  background: var(--assistant-cyan);
  box-shadow: 0 10px 22px rgb(0 238 252 / 0.16);
}

.assistant-message.is-error .assistant-message-body {
  border-color: rgb(220 38 38 / 0.42);
  background: rgb(127 29 29 / 0.42);
}

.assistant-quick-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding-left: 2.65rem;
}

.assistant-quick-chip {
  min-height: 2rem;
  max-width: 100%;
  padding: 0.38rem 0.72rem;
  border: 1px solid rgb(0 238 252 / 0.28);
  border-radius: var(--radius-pill);
  color: var(--assistant-cyan-soft);
  background: rgb(0 238 252 / 0.05);
  font: inherit;
  font-size: 0.78rem;
  font-weight: 800;
  line-height: 1.25;
  text-align: left;
  overflow-wrap: anywhere;
  transition: border-color var(--transition-fast), background var(--transition-fast), color var(--transition-fast);
}

.assistant-quick-chip:nth-child(n + 2) {
  color: var(--assistant-muted);
  border-color: var(--assistant-border);
  background: rgb(39 42 44 / 0.62);
}

.assistant-quick-chip:hover,
.assistant-quick-chip:focus-visible {
  color: var(--assistant-text);
  border-color: rgb(0 238 252 / 0.52);
  background: rgb(0 238 252 / 0.1);
}

.assistant-message-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.5rem;
}

.assistant-related,
.assistant-feedback {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.assistant-related-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  max-width: 100%;
  padding: 0.28rem 0.5rem;
  border: 1px solid rgb(132 148 149 / 0.2);
  border-radius: 0.45rem;
  color: var(--assistant-muted);
  background: rgb(39 42 44 / 0.7);
  font-size: 0.68rem;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.assistant-related-pill .material-symbols-outlined {
  color: var(--assistant-cyan);
  font-size: 0.88rem;
}

.assistant-feedback-button {
  width: 1.8rem;
  height: 1.8rem;
  color: var(--assistant-muted);
  border-color: transparent;
  background: transparent;
  box-shadow: none;
}

.assistant-feedback-button .material-symbols-outlined {
  font-size: 1rem;
}

.assistant-feedback-button.is-selected {
  color: var(--assistant-dark-text);
  border-color: var(--assistant-cyan);
  background: var(--assistant-cyan);
}

.assistant-typing-bubble {
  display: inline-flex;
  align-items: center;
  gap: 0.28rem;
  width: fit-content;
  padding: 0.86rem 1rem;
  border: 1px solid rgb(132 148 149 / 0.16);
  border-radius: 1rem 1rem 1rem 0.25rem;
  background: var(--assistant-surface);
}

.assistant-typing-dot {
  width: 0.46rem;
  height: 0.46rem;
  border-radius: 50%;
  background: rgb(0 238 252 / 0.52);
  animation: assistantTyping 1s infinite ease-in-out;
}

.assistant-typing-dot:nth-child(2) {
  animation-delay: 0.14s;
}

.assistant-typing-dot:nth-child(3) {
  animation-delay: 0.28s;
}

@keyframes assistantTyping {
  0%,
  80%,
  100% {
    transform: translateY(0);
    opacity: 0.42;
  }

  40% {
    transform: translateY(-0.2rem);
    opacity: 1;
  }
}

.assistant-status {
  margin: 0 1rem 0.75rem;
  padding: 0.55rem 0.7rem;
  border: 1px solid rgb(132 148 149 / 0.22);
  border-radius: var(--radius-sm);
  color: var(--assistant-muted);
  background: rgb(14 14 14 / 0.42);
  font-size: 0.82rem;
  font-weight: 800;
}

.assistant-status[data-state="error"] {
  color: #fecaca;
  border-color: rgb(220 38 38 / 0.42);
  background: rgb(127 29 29 / 0.34);
}

.assistant-status[data-state="success"] {
  color: #bbf7d0;
  border-color: rgb(5 150 105 / 0.36);
  background: rgb(20 83 45 / 0.34);
}

.assistant-privacy-note {
  margin: 0;
  padding: 0 1rem 0.85rem;
  color: rgb(197 198 210 / 0.66);
  font-size: 0.68rem;
  line-height: 1.35;
  text-align: center;
}

.assistant-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: end;
  gap: 0.6rem;
  padding: 0.9rem 1rem 0.6rem;
  border-top: 1px solid rgb(132 148 149 / 0.16);
  background: rgb(16 20 21 / 0.6);
  backdrop-filter: blur(12px);
}

.assistant-required-mark {
  align-self: center;
  justify-self: center;
}

.assistant-form textarea {
  min-height: 2.9rem;
  max-height: 8rem;
  resize: vertical;
  color: var(--assistant-text);
  border: 1px solid rgb(132 148 149 / 0.24);
  border-radius: 0.72rem;
  background: rgb(39 42 44 / 0.72);
  box-shadow: inset 0 1px 0 rgb(255 255 255 / 0.04);
}

.assistant-form textarea::placeholder {
  color: rgb(197 198 210 / 0.66);
}

.assistant-form textarea:focus {
  border-color: rgb(0 238 252 / 0.58);
  box-shadow: 0 0 0 3px rgb(0 238 252 / 0.1);
}

.assistant-send-button {
  width: 2.9rem;
  height: 2.9rem;
  color: var(--assistant-dark-text);
  border-color: var(--assistant-cyan);
  border-radius: 0.72rem;
  background: var(--assistant-cyan);
  box-shadow: 0 0 18px rgb(0 238 252 / 0.14);
}

.assistant-send-button:hover {
  color: var(--assistant-dark-text);
  background: var(--assistant-cyan-soft);
}

@media (max-width: 48rem) {
  .assistant-widget {
    right: var(--safe-right);
    left: var(--safe-left);
    align-items: flex-end;
  }

  .assistant-widget-button {
    margin-right: var(--space-3);
  }

  .assistant-panel {
    width: 100%;
    max-width: calc(100dvw - var(--safe-left) - var(--safe-right));
    height: min(44rem, calc(100dvh - var(--overlay-safe-block-start) - var(--overlay-safe-block-end)));
    border-right: 0;
    border-bottom: 0;
    border-left: 0;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  }

  .assistant-quick-chips {
    padding-left: 0;
  }
}
