/* ── Promethee IA Polish Layer ──────────────────────────────────── */

/* ── Toast system ──────────────────────────────────────────── */
.toast {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  min-width: 280px;
  max-width: 420px;
  padding: 14px 16px;
  border-radius: 16px;
  background: rgba(36, 52, 79, 0.92);
  backdrop-filter: blur(20px);
  color: #fff;
  font: 500 13px/1.5 "Arial", sans-serif;
  box-shadow: 0 16px 40px rgba(26, 35, 56, 0.32);
  animation: toastSlideIn 0.35s var(--app-transition) both;
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.toast[data-tone="success"] {
  background: rgba(45, 130, 95, 0.94);
  border-color: rgba(255, 255, 255, 0.15);
}

.toast[data-tone="error"] {
  background: rgba(200, 72, 100, 0.94);
  border-color: rgba(255, 255, 255, 0.15);
}

.toast[data-tone="warning"] {
  background: rgba(200, 150, 40, 0.94);
}

.toast-icon {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
}

.toast-body {
  flex: 1;
  min-width: 0;
}

.toast-progress {
  position: absolute;
  bottom: 0;
  left: 0;
  height: 3px;
  background: rgba(255, 255, 255, 0.3);
  border-radius: 0 0 16px 16px;
  animation: toastProgress 4s linear forwards;
}

.toast-stack {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 4000;
  display: flex;
  flex-direction: column-reverse;
  gap: 10px;
  pointer-events: none;
}

/* ── Cards & panels polish ─────────────────────────────────── */
.history-card,
.data-row,
.credit-offer-card,
.notification-item,
.history-inline-card {
  transition: transform var(--app-transition), box-shadow var(--app-transition), border-color var(--app-transition);
}

.history-card:hover,
.data-row:hover,
.history-inline-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(108, 127, 170, 0.14);
  border-color: rgba(112, 130, 223, 0.22);
}

.credit-offer-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 36px rgba(112, 130, 223, 0.18);
}

.credit-offer-card.active {
  background: linear-gradient(180deg, var(--app-primary) 0%, var(--app-primary-strong) 100%);
  color: #fff;
  border-color: transparent;
  box-shadow: 0 14px 32px rgba(112, 130, 223, 0.32);
}

.credit-offer-card.active strong,
.credit-offer-card.active span,
.credit-offer-card.active small {
  color: #fff;
}

/* ── Pill status ───────────────────────────────────────────── */
.pill[data-status="queued"],
.pill[data-status="processing"] {
  background: rgba(112, 130, 223, 0.14);
  color: var(--app-primary);
  animation: processing-pulse 1.6s ease-in-out infinite;
}

.pill[data-status="completed"] {
  background: rgba(61, 155, 120, 0.14);
  color: var(--app-success);
}

.pill[data-status="failed"] {
  background: rgba(211, 95, 122, 0.14);
  color: var(--app-danger);
}

/* ── Form feedback ─────────────────────────────────────────── */
.form-error:not(:empty) {
  animation: fadeInUp 0.3s ease both;
  padding: 12px 16px;
  border-radius: 14px;
  background: rgba(211, 95, 122, 0.1);
  color: var(--app-danger);
  font: 600 13px/1.5 "Arial", sans-serif;
  border: 1px solid rgba(211, 95, 122, 0.18);
}

.form-success:not(:empty) {
  animation: fadeInUp 0.3s ease both;
  padding: 12px 16px;
  border-radius: 14px;
  background: rgba(61, 155, 120, 0.1);
  color: var(--app-success);
  font: 600 13px/1.5 "Arial", sans-serif;
  border: 1px solid rgba(61, 155, 120, 0.18);
}

/* ── Tab polish ────────────────────────────────────────────── */
.tab-button {
  transition: background var(--app-transition), color var(--app-transition), box-shadow var(--app-transition);
}

/* ── Input focus rings ─────────────────────────────────────── */
.field input:focus-visible,
.field textarea:focus-visible,
.field select:focus-visible {
  outline: none;
  border-color: var(--app-primary);
  box-shadow: 0 0 0 3px var(--app-primary-glow);
}

/* ── Skeleton loading ──────────────────────────────────────── */
.skeleton-block {
  animation: fadeIn 0.3s ease both;
}

/* ── History thumb polish ──────────────────────────────────── */
.history-thumb {
  transition: transform var(--app-transition);
}

.history-thumb-frame:hover .history-thumb {
  transform: scale(1.04);
}

/* ── Reference tile polish ─────────────────────────────────── */
.reference-tile {
  transition: transform var(--app-transition), box-shadow var(--app-transition), border-color var(--app-transition);
}

.reference-tile:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(112, 130, 223, 0.14);
  border-color: rgba(112, 130, 223, 0.22);
}

/* ── Choice pill polish ────────────────────────────────────── */
.choice-pill {
  transition: transform var(--app-transition), background var(--app-transition), color var(--app-transition), box-shadow var(--app-transition), border-color var(--app-transition);
}

.choice-pill:hover {
  transform: translateY(-1px);
}

/* ── Generate button ───────────────────────────────────────── */
#generateButton,
#respGenerateButton {
  transition: transform var(--app-transition), box-shadow var(--app-transition), filter var(--app-transition);
}

#generateButton:hover,
#respGenerateButton:hover {
  transform: translateY(-2px) scale(1.01);
  filter: brightness(1.06);
}

#generateButton:active,
#respGenerateButton:active {
  transform: translateY(0) scale(0.99);
  transition: transform 0.08s ease;
}

/* ── Notification items ────────────────────────────────────── */
.notification-item {
  transition: background var(--app-transition), border-color var(--app-transition);
}

.notification-item.unread {
  border-left: 3px solid var(--app-primary);
  background: rgba(112, 130, 223, 0.05);
}

/* ── Admin test button ─────────────────────────────────────── */
.api-test-result {
  margin-top: 10px;
  padding: 12px 16px;
  border-radius: 14px;
  font: 600 12px/1.5 "Arial", sans-serif;
}

.api-test-result.success {
  background: rgba(61, 155, 120, 0.1);
  color: var(--app-success);
  border: 1px solid rgba(61, 155, 120, 0.18);
}

.api-test-result.error {
  background: rgba(211, 95, 122, 0.1);
  color: var(--app-danger);
  border: 1px solid rgba(211, 95, 122, 0.18);
}

.api-test-result.loading {
  background: rgba(112, 130, 223, 0.08);
  color: var(--app-primary);
  border: 1px solid rgba(112, 130, 223, 0.15);
  animation: processing-pulse 1.4s ease-in-out infinite;
}

/* ── Modal animation ───────────────────────────────────────── */
.modal-panel {
  animation: scaleIn 0.3s var(--app-transition) both;
}

.modal-backdrop {
  animation: fadeIn 0.2s ease both;
}

/* ── Brand pill ────────────────────────────────────────────── */
.brand-pill {
  transition: transform var(--app-transition), box-shadow var(--app-transition);
}

.brand-pill:hover {
  transform: scale(1.04);
}

.legacy-brand-mark {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  box-shadow: none;
}

.legacy-brand-mark img {
  width: 172px;
  height: auto;
  display: block;
}

/* ── Responsive ────────────────────────────────────────────── */
@media (max-width: 1180px) {
  .toast-stack {
    left: 12px;
    right: 12px;
    bottom: 12px;
  }

  .toast {
    max-width: 100%;
    min-width: 0;
  }
}

/* ── Compact desktop layout ─────────────────────────────────── */
.page-shell {
  padding: 18px 0 20px;
}

.page-header {
  margin-bottom: 14px;
}

.page-title {
  margin-top: 6px;
  font-size: 28px;
}

.page-subtitle {
  margin-top: 6px;
  font-size: 13px;
}

.stat-grid {
  gap: 12px;
  margin-bottom: 14px;
}

.stat-card {
  padding: 16px;
}

.stat-card-value {
  margin-top: 4px;
  font-size: 22px;
}

.stat-card-copy {
  margin-top: 4px;
  font-size: 12px;
}

.glass-panel {
  padding: 18px;
}

.panel-header-row {
  margin-bottom: 12px;
}

.panel-title {
  font-size: 17px;
}

.panel-copy {
  font-size: 12px;
}

.page-grid.two-columns {
  gap: 12px;
  margin-bottom: 12px;
}

.field {
  gap: 4px;
}

.field label {
  font-size: 12px;
}

.field input,
.field textarea,
.field select {
  min-height: 40px;
  padding: 8px 12px;
  font-size: 13px;
}

.field-inline {
  gap: 10px;
}

.field-note {
  font-size: 11px;
}

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

/* ── Generator page specific ────────────────────────────────── */
.responsive-app {
  margin: 8px auto 16px;
}

.generator-shell {
  gap: 14px;
}

.generator-hero {
  padding: 18px 22px;
}

.generator-hero-grid {
  gap: 18px;
}

.generator-hero-title {
  font-size: 26px;
}

.generator-hero-copy {
  margin-top: 6px;
  font-size: 13px;
}

.generator-hero-tags {
  margin-top: 10px;
  gap: 6px;
}

.hero-silhouette-card {
  min-height: 240px;
}

.hero-silhouette-card img {
  max-height: 190px;
}

.generator-panels {
  gap: 14px;
}

.generator-section-title {
  font-size: 17px;
}

.generator-section-copy {
  margin-top: 4px;
  font-size: 13px;
}

.generator-form-grid {
  gap: 10px;
  margin-top: 12px;
}

.generator-form-grid.two {
  gap: 10px;
}

.reference-grid {
  gap: 8px;
  margin-top: 10px;
}

.reference-tile {
  min-height: 124px;
}

.reference-tile img {
  height: 84px;
}

.choice-pill-group {
  gap: 6px;
}

.generator-actions {
  margin-top: 12px;
  gap: 8px;
}

/* ── Footer ─────────────────────────────────────────────────── */
.site-footer {
  margin: 0 auto 12px;
  padding: 0;
}

.site-footer-shell {
  padding-top: 10px;
}

.site-footer-copy,
.site-footer-meta {
  font-size: 11px;
}

/* ── Dashboard ──────────────────────────────────────────────── */
#creditOfferGrid {
  gap: 8px;
}

.credit-offer-card {
  padding: 12px;
}

.profile-summary {
  margin-bottom: 10px;
}

/* ── Toolbar ────────────────────────────────────────────────── */
body#b .overlay-toolbar {
  position: relative;
  inset: auto;
  display: grid;
  grid-template-columns: 360px minmax(0, 1fr);
  align-items: center;
  gap: 24px;
  width: min(1920px, calc(100vw - 32px));
  min-height: 112px;
  margin: 0 auto;
  padding: 0 30px;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
  pointer-events: none;
}

body#b .toolbar-left {
  align-items: center;
  justify-content: flex-start;
  justify-self: start;
  min-width: 300px;
}

body#b .spatiographe-logo {
  width: 162px;
  height: auto;
}

body#b .brand-caption {
  color: #111827;
  font-size: 13px;
  font-weight: 500;
  text-align: center;
  text-transform: uppercase;
}

body#b .mode-toggle {
  pointer-events: auto;
}

body#b .mode-icon {
  width: 26px;
  height: 26px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: #8997ad;
  line-height: 1;
  transition: color 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

body#b .mode-icon.active {
  color: #6f83dc;
  background: rgba(112, 130, 223, 0.12);
  box-shadow: 0 6px 14px rgba(112, 130, 223, 0.16);
}

body#b .spatio-credit-counter {
  justify-self: auto;
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 42px;
  margin-top: 17px;
  padding: 0 14px 0 16px;
  border: 1px solid rgba(112, 130, 223, 0.2);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.76);
  color: #6f83dc;
  font-size: 15px;
  font-weight: 800;
  line-height: 1.1;
  white-space: nowrap;
  cursor: pointer;
  pointer-events: auto;
  appearance: none;
  font-family: inherit;
  box-shadow: 0 10px 28px rgba(112, 130, 223, 0.16);
  backdrop-filter: blur(14px);
  transition: transform 0.18s ease, color 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

body#b .spatio-credit-counter:hover {
  color: #5f72d4;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 14px 30px rgba(112, 130, 223, 0.24);
  transform: translateY(-1px);
}

body#b .credit-plus {
  width: 18px;
  height: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: #6f83dc;
  color: #ffffff;
  font-size: 16px;
  font-weight: 700;
  line-height: 1;
  box-shadow: 0 7px 18px rgba(112, 130, 223, 0.28);
  transform: translateY(1px);
}

body#b .toolbar-actions {
  justify-self: end;
  display: flex;
  align-items: flex-start;
  justify-content: flex-end;
  gap: 18px;
  min-width: 0;
}

body#b .spatio-nav {
  gap: 22px;
  pointer-events: auto;
}

body#b .spatio-nav-item {
  width: 88px;
  min-height: 82px;
  border-radius: 12px;
  color: #8090aa;
  font-size: 11px;
  line-height: 1.1;
  overflow-wrap: anywhere;
  pointer-events: auto;
}

body#b .spatio-nav-item.active {
  color: #fff;
  background: #7082df;
  box-shadow: 0 14px 26px rgba(112, 130, 223, 0.42);
}

body#b .spatio-nav-icon {
  width: 31px;
  height: 31px;
}

.brand-pill {
  min-height: 34px;
  padding: 0 12px;
  font-size: 13px;
}

.toolbar-credits,
.toolbar-user,
.toolbar-link,
.toolbar-button,
.toolbar-select {
  min-height: 34px;
  padding: 0 12px;
  font-size: 12px;
}

.toolbar-select {
  min-height: 34px;
}

#appChrome {
  position: absolute;
  inset: 0 0 auto 0;
  z-index: 40;
  padding-top: 8px;
}

.legacy-shell .ps4.s4 {
  visibility: hidden;
}

.legacy-shell #creditsDisplay {
  visibility: hidden;
}

@media (max-width: 1599px), (max-height: 760px) {
  #appChrome {
    position: relative;
  }

  .legacy-shell {
    display: none;
  }

  .responsive-app {
    display: block;
    width: min(1200px, calc(100vw - 24px));
    margin: 16px auto 32px;
  }

  body#b .site-footer {
    margin: 0 auto 18px;
  }
}

@media (max-width: 1180px) {
  #appChrome {
    position: relative;
  }

  .legacy-shell .ps4.s4 {
    visibility: visible;
  }

  .legacy-shell #creditsDisplay {
    visibility: visible;
  }

  body#b .overlay-toolbar {
    grid-template-columns: minmax(0, 1fr);
    justify-items: start;
    width: calc(100vw - 16px);
    min-height: 0;
    padding: 12px 14px;
    border-radius: 24px;
    background: rgba(246, 249, 253, 0.9);
    box-shadow: 0 14px 34px rgba(108, 127, 170, 0.18);
    gap: 10px;
  }

  body#b .toolbar-left {
    min-width: 0;
    width: 100%;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 8px 12px;
  }

  body#b .mode-toggle {
    order: 2;
  }

  body#b .spatiographe-logo {
    width: 136px;
  }

  body#b .brand-caption {
    display: none;
  }

  body#b .spatio-credit-counter {
    justify-self: start;
    min-height: 36px;
    margin-top: 0;
    padding: 0 12px;
    font-size: 14px;
  }

  body#b .credit-plus {
    width: 16px;
    height: 16px;
    font-size: 14px;
  }

  body#b .toolbar-actions {
    width: 100%;
    justify-content: flex-start;
  }

  body#b .spatio-nav {
    width: 100%;
    justify-content: flex-start;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 2px;
  }

  body#b .spatio-nav-item {
    flex: 0 0 auto;
    width: auto;
    min-width: 78px;
    min-height: 42px;
    padding: 7px 10px;
    flex-direction: row;
    gap: 6px;
    border-radius: 14px;
    font-size: 10px;
    white-space: nowrap;
  }

  body#b .spatio-nav-icon {
    width: 20px;
    height: 20px;
  }
}

/* ── History ────────────────────────────────────────────────── */
.history-card {
  padding: 12px;
  gap: 10px;
}

.history-card .item-title {
  font-size: 13px;
}

.history-card .item-meta,
.history-card .item-copy {
  font-size: 12px;
}

.history-actions {
  margin-top: 8px;
  gap: 6px;
}

.history-actions .app-button {
  min-height: 34px;
  padding: 0 10px;
  font-size: 12px;
}

.data-row {
  padding: 10px 12px;
}

.data-row strong,
.data-row span {
  font-size: 12px;
}

.notification-item {
  padding: 12px;
}

/* ── Modal ──────────────────────────────────────────────────── */
.modal-panel {
  padding: 20px;
}

.modal-title {
  font-size: 22px;
}

.modal-header {
  margin-bottom: 14px;
}

.checkout-layout {
  gap: 14px;
}

/* ── Desktop ≥1440px ────────────────────────────────────────── */
@media (min-width: 1440px) {
  .generator-hero {
    padding: 20px 28px;
  }

  .generator-hero-grid {
    gap: 24px;
  }

  .hero-silhouette-card {
    min-height: 270px;
  }

  .hero-silhouette-card img {
    max-height: 220px;
  }
}

/* ── Provider sections ──────────────────────────────────────── */
.provider-section {
  border: 1px solid var(--app-border);
  border-radius: var(--app-radius);
  padding: 18px;
  margin: 0;
  background: rgba(112, 130, 223, 0.03);
}

.provider-section legend {
  padding: 0 8px;
}

/* ── Fix: select text overflowing arrow ─────────────────────── */
select {
  overflow: hidden !important;
  white-space: nowrap !important;
  text-overflow: ellipsis !important;
  padding-right: 32px !important;
}

/* ── Select overflow fix ─────────────────────────────────── */
body select {
  overflow: hidden !important;
  white-space: nowrap !important;
  text-overflow: ellipsis !important;
  padding-right: 32px !important;
}

body select option {
  overflow: visible;
  white-space: normal;
}

/* ── Section title overflow ─────────────────────────────── */
.s44,
.s9,
.s12,
.s25,
.s26,
.s30,
.s34,
.s52,
.s62,
.s63,
.s64,
.s69,
.s70,
.s71,
.s72,
.s76 {
  overflow: visible !important;
  white-space: normal !important;
}

/* ── Section title headings no overflow ─────────────────── */
body h3.f5 {
  max-width: 100%;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 13px !important;
  line-height: 1.22 !important;
}

/* ── Legacy generator readability repair ─────────────────── */
body#b .legacy-shell h3,
body#b .legacy-shell p,
body#b .legacy-shell label,
body#b .legacy-shell span {
  letter-spacing: 0 !important;
}

body#b .legacy-shell .f1,
body#b .legacy-shell .f2,
body#b .legacy-shell .f3 {
  font-size: 14px !important;
  line-height: 1.22 !important;
}

body#b .legacy-shell .f4,
body#b .legacy-shell .f9 {
  font-size: 13px !important;
  line-height: 1.22 !important;
}

body#b .legacy-shell .f5 {
  font-size: 13px !important;
  line-height: 1.22 !important;
  overflow: visible !important;
  text-overflow: clip !important;
  white-space: normal !important;
}

body#b .legacy-shell .f6 {
  font-size: 13px !important;
  line-height: 1.2 !important;
}

body#b .legacy-shell .f13 {
  font-size: 16px !important;
  line-height: 1.2 !important;
}

body#b .legacy-shell .choice-button.choice-selected {
  background: linear-gradient(180deg, #7b8fe4 0%, #6f83dc 100%) !important;
  box-shadow: 0 12px 24px rgba(112, 130, 223, 0.28) !important;
  opacity: 1 !important;
}

body#b .legacy-shell .choice-button.choice-selected p {
  color: #fff !important;
}

body#b .legacy-shell .choice-button:not(.choice-selected) p {
  color: #8b99ae !important;
}

body#b .legacy-shell select[id^="frm"],
body#b .legacy-shell input[type="text"][id^="frm"],
body#b .legacy-shell textarea[id^="frm"] {
  font-size: 13px !important;
  line-height: 1.24 !important;
}

body#b .legacy-shell textarea[id^="frm"]::placeholder,
body#b .legacy-shell input[id^="frm"]::placeholder {
  font-size: 13px !important;
  line-height: 1.24 !important;
}

body#b .legacy-shell .s25,
body#b .legacy-shell .s26,
body#b .legacy-shell .s30,
body#b .legacy-shell .s34,
body#b .legacy-shell .s44,
body#b .legacy-shell .s69,
body#b .legacy-shell .s70,
body#b .legacy-shell .s71,
body#b .legacy-shell .s72,
body#b .legacy-shell .s76 {
  min-height: 18px !important;
}

/* ── Functional dark mode ─────────────────────────────────── */
body#b.theme-dark {
  --app-bg: #0c1322;
  --app-surface: rgba(19, 27, 44, 0.86);
  --app-surface-strong: rgba(22, 31, 50, 0.96);
  --app-border: rgba(150, 165, 205, 0.24);
  --app-shadow: 0 24px 68px rgba(0, 0, 0, 0.38);
  --app-text: #eef4ff;
  --app-muted: #a9b7d0;
  background:
    radial-gradient(circle at 53% 72%, rgba(75, 91, 142, 0.35) 0 7%, transparent 30%),
    radial-gradient(circle at 53% 16%, rgba(90, 106, 165, 0.28) 0 6%, transparent 26%),
    radial-gradient(circle at 80% 56%, rgba(112, 130, 223, 0.18), transparent 34%),
    linear-gradient(180deg, #0d1423 0%, #121b2c 100%) !important;
  color: var(--app-text);
}

body#b.theme-dark::before {
  opacity: 0.2;
  filter: saturate(0.8) brightness(0.62);
}

body#b.theme-dark .brand-caption,
body#b.theme-dark .legacy-shell .f1,
body#b.theme-dark .legacy-shell .p1,
body#b.theme-dark .legacy-shell .p2 {
  color: #edf3ff !important;
}

body#b.theme-dark .spatiographe-logo {
  filter: invert(1) brightness(1.28) contrast(0.92);
}

body#b.theme-dark .mode-toggle,
body#b.theme-dark .spatio-nav-item {
  color: #9ba9c6;
}

body#b.theme-dark .mode-icon.active {
  color: #eef3ff;
  background: rgba(112, 130, 223, 0.26);
}

body#b.theme-dark .spatio-credit-counter {
  color: #9fb0ff;
  border-color: rgba(143, 160, 244, 0.24);
  background: rgba(21, 30, 52, 0.78);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.22);
}

body#b.theme-dark .credit-plus {
  background: #8fa0f4;
  color: #10182e;
}

body#b.theme-dark .legacy-shell .c6,
body#b.theme-dark .legacy-shell .c7,
body#b.theme-dark .legacy-shell .c13,
body#b.theme-dark .legacy-shell .c23,
body#b.theme-dark .legacy-shell .c25,
body#b.theme-dark .legacy-shell .c27,
body#b.theme-dark .legacy-shell .c30,
body#b.theme-dark .legacy-shell .c32,
body#b.theme-dark .legacy-shell .c34,
body#b.theme-dark .legacy-shell .c36,
body#b.theme-dark .legacy-shell .c38,
body#b.theme-dark .legacy-shell .c40 {
  background-color: #131c2e !important;
  opacity: 0.82 !important;
}

body#b.theme-dark .legacy-shell .c5,
body#b.theme-dark .legacy-shell .c9,
body#b.theme-dark .legacy-shell .c11,
body#b.theme-dark .legacy-shell .c15,
body#b.theme-dark .legacy-shell .c20,
body#b.theme-dark .legacy-shell .bd {
  box-shadow: 0 0 24px rgba(0, 0, 0, 0.42) !important;
}

body#b.theme-dark .legacy-shell h3,
body#b.theme-dark .legacy-shell p,
body#b.theme-dark .legacy-shell label,
body#b.theme-dark .legacy-shell span {
  color: #dce6f7 !important;
}

body#b.theme-dark .legacy-shell .f2,
body#b.theme-dark .legacy-shell .f3,
body#b.theme-dark .legacy-shell .f4,
body#b.theme-dark .legacy-shell .f9 {
  color: #aab8d1 !important;
}

body#b.theme-dark .legacy-shell .f5 {
  color: #9fb0ff !important;
}

body#b.theme-dark .legacy-shell select[id^="frm"],
body#b.theme-dark .legacy-shell input[type="text"][id^="frm"],
body#b.theme-dark .legacy-shell textarea[id^="frm"],
body#b.theme-dark .field input,
body#b.theme-dark .field textarea,
body#b.theme-dark .field select {
  background-color: rgba(9, 14, 24, 0.82) !important;
  border-color: rgba(166, 182, 220, 0.34) !important;
  color: #eef4ff !important;
}

body#b.theme-dark .legacy-shell textarea[id^="frm"]::placeholder,
body#b.theme-dark .legacy-shell input[id^="frm"]::placeholder {
  color: #7d8ba3 !important;
}

body#b.theme-dark .glass-panel,
body#b.theme-dark .modal-panel,
body#b.theme-dark .site-footer-shell,
body#b.theme-dark .history-card,
body#b.theme-dark .history-inline-card > div,
body#b.theme-dark .responsive-app {
  background: rgba(16, 24, 39, 0.82);
  border-color: rgba(150, 165, 205, 0.22);
  color: #eef4ff;
  box-shadow: 0 22px 58px rgba(0, 0, 0, 0.34);
}

@media (max-width: 1180px) {
  body#b.theme-dark .overlay-toolbar {
    background: rgba(15, 23, 42, 0.92);
  }
}
