/*
 * This is a manifest file that'll be compiled into application.css.
 *
 * With Propshaft, assets are served efficiently without preprocessing steps. You can still include
 * application-wide styles in this file, but keep in mind that CSS precedence will follow the standard
 * cascading order, meaning styles declared later in the document or manifest will override earlier ones,
 * depending on specificity.
 *
 * Consider organizing styles into separate files for maintainability.
 */

.list-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 2rem;
  padding: 0 0.75rem;
  border: 1px solid #c4c5d5;
  border-radius: 0.375rem;
  background: #fff;
  color: #1e293b;
  font-size: 0.875rem;
  font-weight: 600;
  font-family: inherit;
  text-decoration: none;
  white-space: nowrap;
}
.list-link:hover { background-color: #f1f3ff; }

/* Shared list entry point: the primary identifier is the detail link. */
.list-primary-link {
  color: #1e293b;
  font-weight: 600;
  text-decoration: none;
  transition: color 150ms ease;
}
.list-primary-link:hover,
.list-primary-link:focus-visible {
  color: #1d4ed8;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.admin-action-primary,
.admin-action-success,
.admin-action-danger,
.admin-action-muted {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2rem;
  padding: 0.35rem 0.65rem;
  border-radius: 0.375rem;
  border: 1px solid transparent;
  font: inherit;
  font-size: 0.75rem;
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
}
.admin-action-primary { background: #1e40af; color: #fff; }
.admin-action-success { background: #16a34a; color: #fff; }
.admin-action-danger { background: #fff1f2; border-color: #fecdd3; color: #be123c; }
.admin-action-muted { background: transparent; color: #64748b; cursor: default; }
.admin-action-primary:hover,
.admin-action-primary:focus-visible { background: #1d4ed8; }
.admin-action-success:hover,
.admin-action-success:focus-visible { background: #15803d; }
.admin-action-danger:hover,
.admin-action-danger:focus-visible { background: #ffe4e6; }
.admin-action-primary:focus-visible,
.admin-action-success:focus-visible,
.admin-action-danger:focus-visible,
.list-primary-link:focus-visible { outline: 2px solid #38bdf8; outline-offset: 2px; }

html[data-theme="dark"] .list-primary-link { color: #e2e8f0; }
html[data-theme="dark"] .list-primary-link:hover,
html[data-theme="dark"] .list-primary-link:focus-visible { color: #93c5fd; }
html[data-theme="dark"] .admin-action-danger {
  background: #3f1d2e;
  border-color: #7f1d3d;
  color: #fda4af;
}
html[data-theme="dark"] .admin-action-danger:hover,
html[data-theme="dark"] .admin-action-danger:focus-visible { background: #4c1d2f; }
html[data-theme="dark"] .admin-action-muted { color: #94a3b8; }

.badge-active,
.badge-closed {
  display: inline-flex;
  align-items: center;
  min-height: 1.5rem;
  padding: 0.15rem 0.55rem;
  border-radius: 9999px;
  font-size: 0.7rem;
  font-weight: 700;
  white-space: nowrap;
}
.badge-active { background: #dcfce7; color: #166534; }
.badge-closed { background: #ffe4e6; color: #be123c; }

.admin-inline-detail-toggle {
  display: inline-flex;
  align-items: baseline;
  gap: 0.25rem;
  max-width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  color: #1e293b;
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.admin-inline-detail-toggle:hover,
.admin-inline-detail-toggle:focus-visible { color: #1d4ed8; }
.admin-inline-detail-toggle:focus-visible { outline: 2px solid #38bdf8; outline-offset: 2px; }
.admin-inline-detail-meta { color: #64748b; font-weight: 500; }
.admin-team-detail-cell { background: #f8fafc !important; }
html[data-theme="dark"] .badge-active { background: #14532d; color: #bbf7d0; }
html[data-theme="dark"] .badge-closed { background: #4c1d2f; color: #fda4af; }
html[data-theme="dark"] .admin-inline-detail-toggle { color: #e2e8f0; }
html[data-theme="dark"] .admin-inline-detail-toggle:hover,
html[data-theme="dark"] .admin-inline-detail-toggle:focus-visible { color: #93c5fd; }
html[data-theme="dark"] .admin-inline-detail-meta { color: #94a3b8; }
html[data-theme="dark"] .admin-team-detail-cell { background: #111827 !important; }

/* Calm dashboard surfaces: fewer cards, flatter hierarchy, one financial surface. */
:root {
  --ds-admin-surface: #ffffff;
  --ds-admin-surface-muted: #f8fafc;
  --ds-admin-border: #e2e8f0;
  --ds-admin-text: #1e293b;
  --ds-admin-muted: #64748b;
  --ds-admin-primary: #2563eb;
  --ds-admin-info: #0891b2;
  --ds-admin-warning: #b45309;
}
html[data-theme="dark"] {
  --ds-admin-surface: #1e293b;
  --ds-admin-surface-muted: #111827;
  --ds-admin-border: #334155;
  --ds-admin-text: #e2e8f0;
  --ds-admin-muted: #94a3b8;
  --ds-admin-primary: #93c5fd;
  --ds-admin-info: #67e8f9;
  --ds-admin-warning: #fbbf24;
}
.admin-dashboard { max-width: 100%; }
.dashboard-header { margin-bottom: 1rem; }
.dashboard-header h2 {
  margin: 0;
  color: var(--ds-admin-text);
  font-size: 1.125rem;
  font-weight: 700;
}
.dashboard-header p {
  margin: 0.25rem 0 0;
  color: var(--ds-admin-muted);
  font-size: 0.75rem;
}
.dashboard-kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.75rem;
}
.dashboard-kpi-card {
  min-width: 0;
  padding: 0.8rem 0.85rem 0.75rem;
  border-top: 2px solid var(--dashboard-accent, var(--ds-admin-primary));
  border-bottom: 1px solid var(--ds-admin-border);
  background: transparent;
}
.dashboard-kpi-card h3 {
  margin: 0;
  color: var(--ds-admin-muted);
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1.4;
}
.dashboard-kpi-value {
  margin: 0.25rem 0 0.45rem;
  color: var(--dashboard-accent, var(--ds-admin-primary));
  font-size: 1.75rem;
  font-weight: 800;
  line-height: 1;
}
.dashboard-kpi-link,
.dashboard-section-link {
  color: var(--dashboard-accent, var(--ds-admin-primary));
  font-size: 0.72rem;
  font-weight: 700;
  text-decoration: none;
}
.dashboard-kpi-link:hover,
.dashboard-kpi-link:focus-visible,
.dashboard-section-link:hover,
.dashboard-section-link:focus-visible { text-decoration: underline; text-underline-offset: 2px; }
.dashboard-kpi-primary { --dashboard-accent: var(--ds-admin-primary); }
.dashboard-kpi-info { --dashboard-accent: var(--ds-admin-info); }
.dashboard-kpi-warning { --dashboard-accent: var(--ds-admin-warning); }
.dashboard-financial {
  margin-top: 1.25rem;
  padding: 1rem 1.1rem;
  border: 1px solid var(--ds-admin-border);
  border-radius: 0.65rem;
  background: var(--ds-admin-surface);
  color: var(--ds-admin-text);
}
.dashboard-section-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
}
.dashboard-section-heading h3 { margin: 0; font-size: 0.9rem; font-weight: 700; }
.dashboard-section-heading p { margin: 0.2rem 0 0; color: var(--ds-admin-muted); font-size: 0.7rem; }
.dashboard-financial-summary,
.dashboard-financial-amounts {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.5rem;
}
.dashboard-financial-summary { margin-top: 0.85rem; }
.dashboard-financial-summary > div,
.dashboard-financial-amounts > div {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem;
  min-width: 0;
  padding: 0.5rem 0.6rem;
  border-radius: 0.35rem;
  background: var(--ds-admin-surface-muted);
}
.dashboard-financial-summary span,
.dashboard-financial-amounts span { color: var(--ds-admin-muted); font-size: 0.7rem; }
.dashboard-financial-summary strong { color: var(--ds-admin-text); font-size: 1rem; }
.dashboard-financial-summary .is-primary strong { color: var(--ds-admin-primary); }
.dashboard-financial-summary .is-warning strong { color: var(--ds-admin-warning); }
.dashboard-financial-details { margin-top: 0.75rem; border-top: 1px solid var(--ds-admin-border); }
.dashboard-financial-details summary {
  padding: 0.65rem 0 0;
  color: var(--ds-admin-muted);
  font-size: 0.72rem;
  font-weight: 700;
  cursor: pointer;
}
.dashboard-financial-details[open] summary { margin-bottom: 0.5rem; color: var(--ds-admin-text); }
.dashboard-financial-amounts strong { color: var(--ds-admin-text); font-size: 0.8rem; }
@media (max-width: 767px) {
  .dashboard-kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.5rem; }
  .dashboard-financial-summary,
  .dashboard-financial-amounts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dashboard-section-heading { flex-direction: column; }
}

/* Sidebar Collapse (Icon-Rail & Peeking) */
.sidebar-spacer {
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  position: relative;
  z-index: 40;
  width: 16rem;
  align-self: stretch;
  min-height: 100vh;
  transition: width 200ms ease;
}
.sidebar-spacer.sidebar-collapsed {
  width: 4.5rem;
}
/* hidden md:block 을 이 규칙의 display:flex 가 이긴다. 좁은 화면은 하단 메뉴만 쓴다. */
@media (max-width: 767px) {
  .sidebar-spacer { display: none; }
}

.sidebar-panel {
  position: fixed;
  top: 0;
  bottom: 0;
  left: 0;
  width: 16rem;
  overflow: hidden;
  min-height: 0;
  transition: width 200ms ease, box-shadow 200ms ease;
  z-index: 40;
  display: flex;
  flex-direction: column;
}
.sidebar-spacer.sidebar-collapsed .sidebar-panel {
  width: 4.5rem;
}
.sidebar-spacer.sidebar-collapsed.sidebar-peeking .sidebar-panel {
  width: 16rem;
  box-shadow: 4px 0 24px rgba(0, 0, 0, 0.2);
}

.sidebar-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  height: 4rem;
  padding: 0 1rem;
  flex-shrink: 0;
}
.sidebar-toggle-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  padding: 0.25rem;
  border-radius: 0.375rem;
  background: transparent;
  border: 0;
  cursor: pointer;
  color: #94a3b8;
  transition: color 150ms ease, background-color 150ms ease;
  flex-shrink: 0;
}
.sidebar-toggle-btn:hover {
  color: #1e293b;
  background-color: #e2e8f0;
}
.sidebar-toggle-btn:focus-visible {
  outline: 2px solid #38bdf8;
  outline-offset: 1px;
}

.sidebar-icon-collapse { display: block; }
.sidebar-icon-expand   { display: none; }
.sidebar-collapsed:not(.sidebar-peeking) .sidebar-icon-collapse { display: none !important; }
.sidebar-collapsed:not(.sidebar-peeking) .sidebar-icon-expand   { display: block !important; }

.sidebar-collapsed:not(.sidebar-peeking) .sidebar-header-full,
.sidebar-collapsed:not(.sidebar-peeking) .sidebar-brand-name,
.sidebar-collapsed:not(.sidebar-peeking) .sidebar-user-info,
.sidebar-collapsed:not(.sidebar-peeking) .sidenav-link span:not(.material-symbols-outlined),
.sidebar-collapsed:not(.sidebar-peeking) .sidebar-link span:not(.material-symbols-outlined),
.sidebar-collapsed:not(.sidebar-peeking) .sidebar-footer-text {
  display: none !important;
}

.sidebar-collapsed:not(.sidebar-peeking) .sidebar-header {
  justify-content: center !important;
  padding-left: 0.5rem !important;
  padding-right: 0.5rem !important;
}
.sidebar-collapsed:not(.sidebar-peeking) .sidenav-link,
.sidebar-collapsed:not(.sidebar-peeking) .sidebar-link {
  justify-content: center !important;
  padding-left: 0.5rem !important;
  padding-right: 0.5rem !important;
  gap: 0 !important;
}
.sidebar-collapsed:not(.sidebar-peeking) .sidebar-footer-btn {
  justify-content: center !important;
  padding-left: 0.5rem !important;
  padding-right: 0.5rem !important;
  gap: 0 !important;
}

/* Sidebar Nav Links Base & Layout (Light Mode / Public Layout) */
.sidenav-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.625rem 0.75rem;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  font-weight: 500;
  text-decoration: none;
  color: #475569;
  background-color: transparent;
  transition: background-color 150ms ease, color 150ms ease;
  cursor: pointer;
  white-space: nowrap;
}
.sidenav-link .material-symbols-outlined {
  color: #64748b;
  transition: color 150ms ease;
}
.sidenav-link:hover {
  background-color: #e2e8f0;
  color: #0f172a;
}
.sidenav-link:hover .material-symbols-outlined {
  color: #0f172a;
}
.sidenav-link:focus-visible {
  outline: 2px solid #2563eb;
  outline-offset: 2px;
  background-color: #e2e8f0;
  color: #0f172a;
}
.sidenav-link:focus-visible .material-symbols-outlined {
  color: #0f172a;
}
.sidenav-link.active {
  background-color: #1e40af !important;
  color: #ffffff !important;
  font-weight: 700;
}
.sidenav-link.active .material-symbols-outlined {
  color: #ffffff !important;
}
.sidenav-link.active:hover {
  background-color: #1d4ed8 !important;
  color: #ffffff !important;
}
.sidenav-link.active:focus-visible {
  outline: 2px solid #60a5fa !important;
  outline-offset: 2px;
}

/* Dark Sidebar Variant (Used in Admin Portal & Mobile Overlay) */
.sidebar-panel-dark .sidenav-link,
aside.sidebar-panel-dark .sidenav-link,
aside[style*="background:#1e293b"] .sidenav-link,
aside[style*="background: #1e293b"] .sidenav-link,
#mobile-sidebar .sidenav-link {
  color: #e2e8f0;
  background-color: transparent;
}
.sidebar-panel-dark .sidenav-link .material-symbols-outlined,
aside.sidebar-panel-dark .sidenav-link .material-symbols-outlined,
aside[style*="background:#1e293b"] .sidenav-link .material-symbols-outlined,
aside[style*="background: #1e293b"] .sidenav-link .material-symbols-outlined,
#mobile-sidebar .sidenav-link .material-symbols-outlined {
  color: #94a3b8;
}
.sidebar-panel-dark .sidenav-link:hover,
aside.sidebar-panel-dark .sidenav-link:hover,
aside[style*="background:#1e293b"] .sidenav-link:hover,
aside[style*="background: #1e293b"] .sidenav-link:hover,
#mobile-sidebar .sidenav-link:hover {
  background-color: #334155 !important;
  color: #ffffff !important;
}
.sidebar-panel-dark .sidenav-link:hover .material-symbols-outlined,
aside.sidebar-panel-dark .sidenav-link:hover .material-symbols-outlined,
aside[style*="background:#1e293b"] .sidenav-link:hover .material-symbols-outlined,
aside[style*="background: #1e293b"] .sidenav-link:hover .material-symbols-outlined,
#mobile-sidebar .sidenav-link:hover .material-symbols-outlined {
  color: #ffffff !important;
}
.sidebar-panel-dark .sidenav-link:focus-visible,
aside.sidebar-panel-dark .sidenav-link:focus-visible,
aside[style*="background:#1e293b"] .sidenav-link:focus-visible,
aside[style*="background: #1e293b"] .sidenav-link:focus-visible,
#mobile-sidebar .sidenav-link:focus-visible {
  outline: 2px solid #38bdf8 !important;
  outline-offset: 2px;
  background-color: #334155 !important;
  color: #ffffff !important;
}
.sidebar-panel-dark .sidenav-link:focus-visible .material-symbols-outlined,
aside.sidebar-panel-dark .sidenav-link:focus-visible .material-symbols-outlined,
aside[style*="background:#1e293b"] .sidenav-link:focus-visible .material-symbols-outlined,
aside[style*="background: #1e293b"] .sidenav-link:focus-visible .material-symbols-outlined,
#mobile-sidebar .sidenav-link:focus-visible .material-symbols-outlined {
  color: #ffffff !important;
}
.sidebar-panel-dark .sidenav-link.active,
aside.sidebar-panel-dark .sidenav-link.active,
aside[style*="background:#1e293b"] .sidenav-link.active,
aside[style*="background: #1e293b"] .sidenav-link.active,
#mobile-sidebar .sidenav-link.active {
  background-color: #2563eb !important;
  color: #ffffff !important;
}
.sidebar-panel-dark .sidenav-link.active .material-symbols-outlined,
aside.sidebar-panel-dark .sidenav-link.active .material-symbols-outlined,
aside[style*="background:#1e293b"] .sidenav-link.active .material-symbols-outlined,
aside[style*="background: #1e293b"] .sidenav-link.active .material-symbols-outlined,
#mobile-sidebar .sidenav-link.active .material-symbols-outlined {
  color: #ffffff !important;
}
.sidebar-panel-dark .sidenav-link.active:hover,
aside.sidebar-panel-dark .sidenav-link.active:hover,
aside[style*="background:#1e293b"] .sidenav-link.active:hover,
aside[style*="background: #1e293b"] .sidenav-link.active:hover,
#mobile-sidebar .sidenav-link.active:hover {
  background-color: #1d4ed8 !important;
  color: #ffffff !important;
}

/* Sidebar Footer Buttons */
.sidebar-footer-btn {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.625rem 0.75rem;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  background: transparent;
  border: none;
  color: #475569;
  font-family: inherit;
  transition: background-color 150ms ease, color 150ms ease;
  width: 100%;
}
.sidebar-footer-btn .material-symbols-outlined {
  color: #64748b;
  transition: color 150ms ease;
}
.sidebar-footer-btn:hover {
  background-color: #e2e8f0;
  color: #0f172a;
}
.sidebar-footer-btn:hover .material-symbols-outlined {
  color: #0f172a;
}
.sidebar-footer-btn:focus-visible {
  outline: 2px solid #2563eb;
  outline-offset: 2px;
  background-color: #e2e8f0;
}
.sidebar-panel-dark .sidebar-footer-btn,
aside.sidebar-panel-dark .sidebar-footer-btn,
aside[style*="background:#1e293b"] .sidebar-footer-btn,
aside[style*="background: #1e293b"] .sidebar-footer-btn,
#mobile-sidebar .sidebar-footer-btn {
  color: #e2e8f0;
}
.sidebar-panel-dark .sidebar-footer-btn .material-symbols-outlined,
aside.sidebar-panel-dark .sidebar-footer-btn .material-symbols-outlined,
aside[style*="background:#1e293b"] .sidebar-footer-btn .material-symbols-outlined,
aside[style*="background: #1e293b"] .sidebar-footer-btn .material-symbols-outlined,
#mobile-sidebar .sidebar-footer-btn .material-symbols-outlined {
  color: #94a3b8;
}
.sidebar-panel-dark .sidebar-footer-btn:hover,
aside.sidebar-panel-dark .sidebar-footer-btn:hover,
aside[style*="background:#1e293b"] .sidebar-footer-btn:hover,
aside[style*="background: #1e293b"] .sidebar-footer-btn:hover,
#mobile-sidebar .sidebar-footer-btn:hover {
  background-color: #334155 !important;
  color: #ffffff !important;
}
.sidebar-panel-dark .sidebar-footer-btn:hover .material-symbols-outlined,
aside.sidebar-panel-dark .sidebar-footer-btn:hover .material-symbols-outlined,
aside[style*="background:#1e293b"] .sidebar-footer-btn:hover .material-symbols-outlined,
aside[style*="background: #1e293b"] .sidebar-footer-btn:hover .material-symbols-outlined,
#mobile-sidebar .sidebar-footer-btn:hover .material-symbols-outlined {
  color: #ffffff !important;
}
.sidebar-panel-dark .sidebar-footer-btn:focus-visible,
aside.sidebar-panel-dark .sidebar-footer-btn:focus-visible,
aside[style*="background:#1e293b"] .sidebar-footer-btn:focus-visible,
aside[style*="background: #1e293b"] .sidebar-footer-btn:focus-visible,
#mobile-sidebar .sidebar-footer-btn:focus-visible {
  outline: 2px solid #38bdf8 !important;
  outline-offset: 2px;
  background-color: #334155 !important;
  color: #ffffff !important;
}

/* Inbound Emails Compact Toolbar & Single-line Stats */
.inbound-imap-section {
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 0.25rem;
  margin-bottom: 0.375rem;
  font-size: 0.75rem;
  color: #374151;
}
.inbound-imap-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.25rem 0.5rem;
  cursor: default;
  user-select: none;
  list-style: none;
  white-space: nowrap;
  overflow: hidden;
}
.inbound-imap-left {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.inbound-filter-bar {
  background: transparent;
  padding: 0;
  border: 0;
  border-radius: 0;
  margin-bottom: 0.5rem;
  width: 100%;
}
.inbound-filter-bar form,
.inbound-filter-form {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.375rem;
  width: 100%;
}
.inbound-filter-search {
  flex: 1 1 8rem;
  min-width: 7rem;
  max-width: 12.5rem;
}
.inbound-filter-bar input,
.inbound-filter-bar select,
.inbound-filter-bar .admin-input,
.inbound-filter-bar .admin-select {
  box-sizing: border-box;
  min-width: 0;
  height: 2rem;
  padding: 0 0.5rem;
  border: 1px solid #cbd5e1;
  border-radius: 0.375rem;
  font-size: 0.75rem;
  line-height: 1;
  background-color: #ffffff;
  color: #1e293b;
}
.inbound-filter-bar select,
.inbound-filter-bar .admin-select {
  padding-right: 1.5rem;
}
.inbound-filter-bar input:focus,
.inbound-filter-bar select:focus {
  border-color: #1e40af;
  outline: none;
  box-shadow: 0 0 0 2px rgba(30, 64, 175, 0.2);
}
.inbound-filter-bar .admin-btn {
  height: 2rem;
  padding: 0 0.625rem;
  border-radius: 0.375rem;
  font-size: 0.75rem;
  white-space: nowrap;
}

/* Inline stats in the same toolbar level */
.inbound-stats-inline,
.inbound-stats-grid {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  flex-wrap: wrap;
  margin-left: auto;
}
.inbound-stat-chip,
.inbound-stat-card {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  height: 2rem;
  padding: 0 0.5rem;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 0.375rem;
  text-decoration: none;
  font-size: 0.75rem;
  line-height: 1;
  white-space: nowrap;
  flex-shrink: 0;
  transition: border-color 0.15s ease, background-color 0.15s ease;
}
.inbound-stat-chip:hover,
.inbound-stat-card:hover {
  background-color: #f8fafc;
  border-color: #cbd5e1;
}
.inbound-stat-label {
  font-size: 0.6875rem;
  font-weight: 500;
  color: #475569;
  white-space: nowrap;
  flex-shrink: 0;
}
.inbound-stat-value {
  font-size: 0.75rem;
  font-weight: 700;
  white-space: nowrap;
  flex-shrink: 0;
}

@media (max-width: 639px) {
  .inbound-filter-bar form {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.375rem;
  }
  .inbound-filter-bar .inbound-filter-search {
    grid-column: span 2;
    min-width: 0;
    max-width: 100%;
  }
  .inbound-filter-bar select {
    width: 100%;
    min-width: 0;
  }
  .inbound-filter-bar .admin-btn {
    width: 100%;
    justify-content: center;
  }
  .inbound-stats-inline,
  .inbound-stats-grid {
    grid-column: span 2;
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
    margin-left: 0;
    margin-top: 0.25rem;
  }
  .inbound-stat-chip,
  .inbound-stat-card {
    flex: 1 1 auto;
    justify-content: center;
    padding: 0 0.375rem;
  }
}

.inbound-table-container {
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

/* Compact list pagination (public inbound mailbox) */
.admin-pagination {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem 1rem;
  padding: 0.5rem 0.75rem;
  border-top: 1px solid #e5e7eb;
  font-size: 0.75rem;
  color: #64748b;
}
.admin-pagination-range {
  margin: 0;
}
.admin-pagination-page-meta {
  color: #94a3b8;
  margin-left: 0.25rem;
}
.admin-pagination-controls {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.25rem;
}
.admin-pagination-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 1.75rem;
  padding: 0.125rem 0.5rem;
  border: 1px solid #e2e8f0;
  border-radius: 0.25rem;
  background: #ffffff;
  color: #334155;
  text-decoration: none;
  font-weight: 500;
  white-space: nowrap;
}
.admin-pagination-link:hover {
  border-color: #7dd3fc;
  background: #f0f9ff;
  color: #0369a1;
}
.admin-pagination-link.is-disabled {
  opacity: 0.45;
  pointer-events: none;
  cursor: default;
}
.admin-pagination-current {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.75rem;
  min-height: 1.75rem;
  padding: 0.125rem 0.5rem;
  border-radius: 0.25rem;
  background: #0ea5e9;
  color: #ffffff;
  font-weight: 700;
}
html[data-theme="dark"] .admin-pagination {
  border-top-color: #334155;
  color: #94a3b8;
}
html[data-theme="dark"] .admin-pagination-link {
  background: #1e293b;
  border-color: #334155;
  color: #e2e8f0;
}
html[data-theme="dark"] .admin-pagination-link:hover {
  background: #334155;
  border-color: #38bdf8;
  color: #7dd3fc;
}
html[data-theme="dark"] .admin-pagination-current {
  background: #0284c7;
}
.inbound-table {
  width: 100%;
  font-size: 0.75rem;
  border-collapse: collapse;
  text-align: left;
}
.inbound-table th {
  background-color: #f8fafc;
  color: #475569;
  font-weight: 600;
  border-bottom: 1px solid #e2e8f0;
  padding: 0.375rem 0.5rem;
  white-space: nowrap;
}
.inbound-table td {
  padding: 0.375rem 0.5rem;
  border-bottom: 1px solid #f1f5f9;
  white-space: nowrap;
  vertical-align: middle;
}
.inbound-table tr:hover {
  background-color: #f1f5f9;
}
.inbound-table tr:last-child td {
  border-bottom: none;
}
.inbound-subject-link {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  max-width: 100%;
  text-decoration: none;
  color: inherit;
  white-space: nowrap;
  overflow: hidden;
}
.inbound-subject-text {
  font-weight: 500;
  color: #0f172a;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* 일괄 처리 바 (받은메일함 적체 소진). 확인은 페이지 안 2단계 — 네이티브 confirm 없음. */
.inbound-bulk-form [hidden] {
  display: none !important;
}
.inbound-bulk-bar {
  border: 1px solid #bae6fd;
  background: #f0f9ff;
  border-radius: 0.5rem;
  padding: 0.375rem 0.5rem;
  margin-bottom: 0.375rem;
}
.inbound-bulk-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.375rem;
}
.inbound-bulk-count {
  font-size: 0.75rem;
  font-weight: 700;
  color: #0c4a6e;
  white-space: nowrap;
}
.inbound-bulk-hint {
  font-size: 0.6875rem;
  color: #64748b;
  margin-right: auto;
}
.inbound-bulk-confirm {
  margin-top: 0.375rem;
  padding-top: 0.375rem;
  border-top: 1px dashed #bae6fd;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 0.5rem;
}
.inbound-bulk-message {
  flex: 1 1 100%;
  font-size: 0.75rem;
  color: #0f172a;
  line-height: 1.45;
  word-break: keep-all;
}
.inbound-bulk-inputs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  flex: 1 1 auto;
}
.inbound-bulk-field {
  display: flex;
  flex-direction: column;
  gap: 0.125rem;
  min-width: 12rem;
}
.inbound-bulk-field-label {
  font-size: 0.6875rem;
  font-weight: 600;
  color: #475569;
}
.inbound-bulk-run {
  display: flex;
  flex-wrap: wrap;
  gap: 0.375rem;
}
.inbound-col-select {
  width: 1.75rem;
  text-align: center;
}
.inbound-col-select input[type="checkbox"] {
  width: 0.875rem;
  height: 0.875rem;
  accent-color: #0284c7;
  cursor: pointer;
}
html[data-theme="dark"] .inbound-bulk-bar {
  background: #0f2937;
  border-color: #155e75;
}
html[data-theme="dark"] .inbound-bulk-count {
  color: #7dd3fc;
}
html[data-theme="dark"] .inbound-bulk-hint,
html[data-theme="dark"] .inbound-bulk-field-label {
  color: #94a3b8;
}
html[data-theme="dark"] .inbound-bulk-message {
  color: #e2e8f0;
}
html[data-theme="dark"] .inbound-bulk-confirm {
  border-top-color: #155e75;
}

@media (max-width: 767px) {
  .inbound-table thead {
    display: none;
  }
  .inbound-table,
  .inbound-table tbody,
  .inbound-table tr {
    display: block;
    width: 100%;
  }
  .inbound-table tr {
    position: relative;
    padding: 0.625rem 0.75rem 0.625rem 2.625rem;
    border-bottom: 1px solid #e2e8f0;
  }
  .inbound-table tr:last-child {
    border-bottom: none;
  }
  .inbound-table td {
    display: block;
    width: 100%;
    padding: 0;
    border-bottom: none;
    white-space: normal;
  }
  .inbound-table td.admin-col-detail {
    position: absolute;
    left: 0.5rem;
    top: 0.625rem;
    width: 1.75rem;
    height: 1.75rem;
  }
  /* 좁은 화면에서는 선택 체크박스를 오른쪽 위에 띄운다(왼쪽은 상세 아이콘 자리). */
  .inbound-table td.inbound-col-select {
    position: absolute;
    right: 0.5rem;
    top: 0.625rem;
    width: 1.5rem;
    text-align: right;
  }
  .inbound-table td.inbound-col-sender {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 0.5rem;
    max-width: 100%;
    font-size: 0.75rem;
    font-weight: 600;
    color: #475569;
    margin-bottom: 0.125rem;
  }
  .inbound-table td.inbound-col-subject {
    max-width: 100%;
    margin-bottom: 0.375rem;
  }
  .inbound-table td.inbound-col-subject .inbound-subject-link {
    display: inline-flex;
    align-items: center;
    max-width: 100%;
  }
  .inbound-table td.inbound-col-subject .inbound-subject-text {
    font-size: 0.8125rem;
    font-weight: 600;
    line-height: 1.35;
    color: #0f172a;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    white-space: normal;
    word-break: break-word;
    overflow-wrap: anywhere;
  }
  .inbound-table td.inbound-col-steps {
    display: block;
    width: 100%;
    margin: 0.25rem 0 0.375rem;
    white-space: normal;
  }
  .inbound-table td.inbound-col-category,
  .inbound-table td.inbound-col-status,
  .inbound-table td.inbound-col-publish,
  .inbound-table td.inbound-col-time {
    display: inline-flex;
    vertical-align: middle;
    width: auto;
    margin-right: 0.25rem;
    margin-bottom: 0.125rem;
  }
  .inbound-table td.inbound-col-time {
    margin-right: 0;
    font-size: 0.6875rem;
    color: #94a3b8;
  }
}

/* Global & Inbound SVG Icon Safety Rules */
svg {
  max-width: 100%;
}
.inbound-icon-svg {
  width: 0.875rem !important;
  height: 0.875rem !important;
  min-width: 0.875rem !important;
  min-height: 0.875rem !important;
  max-width: 0.875rem !important;
  max-height: 0.875rem !important;
  flex-shrink: 0 !important;
  display: inline-block !important;
  vertical-align: middle !important;
}

/* Inbound Email Detail Design System Tokens */
.inbound-detail-container {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
}
.inbound-card {
  background-color: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
}
.inbound-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.5rem 0.75rem;
  border-bottom: 1px solid #f1f5f9;
  background-color: #f8fafc;
  border-top-left-radius: 10px;
  border-top-right-radius: 10px;
}
.inbound-card-body {
  padding: 0.75rem;
}
.inbound-body-container {
  overflow-x: hidden;
  background-color: #ffffff;
  padding: 0.875rem;
  font-size: 0.875rem;
  line-height: 1.6;
  color: #1e293b;
  word-break: break-word;
  overflow-wrap: anywhere;
}
.inbound-body-container img,
.inbound-body-container video,
.inbound-body-container canvas {
  max-width: 100% !important;
  max-height: 480px !important;
  height: auto !important;
  display: block !important;
  object-fit: contain !important;
  margin: 0.5rem 0 !important;
  border-radius: 6px !important;
}
.inbound-body-container svg:not(.inbound-icon-svg) {
  max-width: 100% !important;
  max-height: 480px !important;
  height: auto !important;
}
.inbound-body-container table {
  width: 100% !important;
  max-width: 100% !important;
  display: block !important;
  overflow-x: auto !important;
  border-collapse: collapse !important;
  margin: 0.5rem 0 !important;
}
.inbound-body-container pre,
.inbound-body-container code {
  max-width: 100% !important;
  white-space: pre-wrap !important;
  word-break: break-word !important;
  overflow-wrap: anywhere !important;
}
.inbound-body-container p {
  margin-bottom: 0.5rem;
}
.inbound-body-container p:last-child {
  margin-bottom: 0;
}

/* Attachment row */
.inbound-attachment-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  min-height: 36px;
  padding: 0.375rem 0.625rem;
  border: 1px solid #e2e8f0;
  border-radius: 0.375rem;
  background-color: #f8fafc;
  font-size: 0.75rem;
  transition: background-color 0.15s ease-in-out;
}
.inbound-attachment-row:hover {
  background-color: #f1f5f9;
}

/* Inbound Email Timeline Step Control */
.inbound-timeline-bar {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.375rem;
  padding: 0.375rem;
  background-color: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 0.5rem;
}
.inbound-timeline-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0.375rem 0.25rem;
  border-radius: 0.375rem;
  background-color: #ffffff;
  border: 1px solid #e2e8f0;
  cursor: pointer;
  transition: all 0.15s ease-in-out;
  text-align: center;
}
.inbound-timeline-step:hover {
  background-color: #f1f5f9;
  border-color: #cbd5e1;
}
.inbound-timeline-step:has(input:checked) {
  border-color: #0369a1 !important;
  background-color: #f0f9ff !important;
  box-shadow: 0 1px 2px 0 rgba(3, 105, 161, 0.15);
}
.inbound-timeline-step:has(input:checked) .inbound-timeline-title {
  color: #0369a1 !important;
  font-weight: 700 !important;
}

/* Inbound Email Category Radio Options */
.inbound-radio-grid {
  display: grid;
  grid-template-columns: repeat(1, minmax(0, 1fr));
  gap: 0.375rem;
}
@media (min-width: 640px) {
  .inbound-radio-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
.inbound-radio-label {
  position: static !important;
  display: flex !important;
  align-items: center !important;
  gap: 0.5rem !important;
  min-height: 36px !important;
  padding: 0.375rem 0.625rem !important;
  overflow: hidden !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 0.5rem !important;
  background-color: #ffffff !important;
  cursor: pointer !important;
  transition: all 0.15s ease-in-out !important;
}
.inbound-radio-label:hover {
  background-color: #f8fafc !important;
  border-color: #cbd5e1 !important;
}
.inbound-radio-label:has(input:checked) {
  border-color: #0369a1 !important;
  background-color: #f0f9ff !important;
}
.inbound-radio-input {
  position: static !important;
  width: 16px !important;
  height: 16px !important;
  min-width: 16px !important;
  flex: 0 0 16px !important;
  margin: 0 !important;
  accent-color: #0284c7 !important;
  cursor: pointer !important;
}
.inbound-radio-text {
  flex: 1 1 auto !important;
  min-width: 0 !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
  font-size: 0.75rem !important;
  font-weight: 500 !important;
  color: #1e293b !important;
  line-height: 1.25 !important;
}
.inbound-radio-label:has(input:checked) .inbound-radio-text {
  color: #0369a1 !important;
  font-weight: 600 !important;
}

/* Compact inbound detail controls */
.inbound-detail-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  min-width: 0;
}
.org-support-this-step-title {
  margin: 0;
  color: #0f172a;
  font-size: 0.8125rem;
  font-weight: 700;
}
.org-support-this-step-hint {
  margin: 0.25rem 0 0.625rem;
  color: #64748b;
  font-size: 0.6875rem;
  line-height: 1.4;
}
.org-support-this-step .org-support-steps-track form {
  display: block;
  min-width: 0;
  margin: 0;
}
.org-support-this-step-btn {
  width: 100%;
  cursor: pointer;
  font: inherit;
}
.org-support-steps-track {
  display: grid;
  grid-template-columns: repeat(4, minmax(2.25rem, 1fr));
  gap: 0.2rem;
  list-style: none;
  margin: 0;
  padding: 0;
  min-width: 10rem;
}
.org-support-steps-slot {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 2.125rem;
  padding: 0.2rem 0.1rem;
  border: 1px dashed #cbd5e1;
  border-radius: 0.375rem;
  background: #f8fafc;
  color: #94a3b8;
}
.org-support-steps-slot.is-filled {
  border-style: solid;
  border-color: #0284c7;
  background: #e0f2fe;
  color: #0369a1;
}
.org-support-steps-slot.is-current {
  box-shadow: 0 0 0 2px #0369a1;
}
.org-support-steps-num {
  font-size: 0.6875rem;
  font-weight: 700;
  line-height: 1;
}
.org-support-steps-label {
  font-size: 0.5625rem;
  font-weight: 600;
  line-height: 1.15;
}
.org-support-this-step-btn:hover,
.org-support-this-step-btn:focus-visible {
  border-color: #0284c7;
  color: #0369a1;
  outline: none;
}
.admin-fold {
  overflow: hidden;
  margin: 0;
  border: 1px solid #e2e8f0;
  border-radius: 0.375rem;
  background: #fff;
}
.admin-fold > summary {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.625rem;
  color: #334155;
  cursor: pointer;
  font-size: 0.75rem;
  font-weight: 700;
  list-style: none;
}
.admin-fold > summary::-webkit-details-marker { display: none; }
.admin-fold > summary::after {
  margin-left: auto;
  color: #94a3b8;
  font-weight: 500;
  content: "＋";
}
.admin-fold[open] > summary {
  border-bottom: 1px solid #e2e8f0;
}
.admin-fold[open] > summary::after { content: "－"; }
.admin-fold > summary:hover { background: #f8fafc; }
.admin-fold-panel {
  padding: 0.5rem 0.625rem;
  margin: 0;
}
.admin-fold.is-danger {
  border-color: #fecdd3;
}
.admin-fold.is-danger > summary {
  color: #be123c;
}
.admin-fold.is-danger > summary:hover {
  background: #fff1f2;
}
.inbound-status-summary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  min-width: 0;
  max-width: min(100%, 34rem);
  height: 2rem;
  padding: 0 0.75rem;
  border: 1px solid #cbd5e1;
  border-radius: 0.375rem;
  background: #fff;
  color: #334155;
  cursor: pointer;
  font: 600 0.75rem/1.25rem inherit;
  text-align: left;
}
.inbound-status-summary:hover,
.inbound-status-summary:focus-visible {
  border-color: #7dd3fc;
  background: #f8fafc;
  outline: none;
}
.inbound-status-summary-more {
  flex-shrink: 0;
  color: #64748b;
  font-size: 0.6875rem;
  font-weight: 500;
}
.inbound-compact-alert {
  display: flex;
  align-items: baseline;
  gap: 0.375rem;
  padding: 0.5rem 0.625rem;
  border: 1px solid #fde68a;
  border-radius: 0.375rem;
  background: #fffbeb;
  color: #92400e;
  font-size: 0.75rem;
  line-height: 1.35;
}
.inbound-compact-alert strong { flex-shrink: 0; }
.inbound-status-dialog {
  width: min(28rem, calc(100% - 2rem));
  max-width: 28rem;
  margin: auto;
  border-radius: 0.75rem;
  border: 1px solid #e2e8f0;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
}
.inbound-category-dialog {
  width: min(40rem, calc(100vw - 1.5rem));
  max-width: 40rem;
  margin: auto;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}
.inbound-category-dialog::backdrop,
.inbound-status-dialog::backdrop {
  background: rgba(15, 23, 42, 0.5);
  backdrop-filter: blur(2px);
}
.inbound-step-radio-label,
.inbound-radio-label {
  cursor: pointer;
  user-select: none;
  transition: all 150ms ease;
  white-space: nowrap;
  word-break: keep-all;
}
.inbound-step-radio-label:has(input:checked),
.inbound-radio-label:has(input:checked) {
  border-color: #0284c7 !important;
  background-color: #f0f9ff !important;
  color: #0369a1 !important;
  box-shadow: 0 0 0 2px #0284c7;
}
.inbound-step-radio-label:has(input:checked) .org-support-steps-num,
.inbound-step-radio-label:has(input:checked) .org-support-steps-label,
.inbound-radio-label:has(input:checked) .inbound-radio-text {
  color: #0369a1 !important;
  font-weight: 700;
}
.inbound-radio-text {
  white-space: nowrap;
  word-break: keep-all;
  overflow: visible;
  text-overflow: clip;
}
.inbound-status-dialog-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 1rem;
}
.inbound-status-dialog-head h2 { margin: 0; color: #1e293b; font-size: 1rem; font-weight: 700; }
.inbound-status-dialog-badges { display: flex; flex-wrap: wrap; gap: 0.375rem; }
.inbound-status-dialog-note {
  margin: 0.875rem 0 0;
  padding-top: 0.75rem;
  border-top: 1px solid #e2e8f0;
  color: #64748b;
  font-size: 0.75rem;
}
@media (max-width: 639px) {
  .inbound-detail-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.375rem;
  }
  .inbound-status-summary {
    flex: 1 1 auto;
    min-width: 0;
    max-width: none;
    width: auto;
  }
}

/* Shared light/dark theme */
html { color-scheme: light; }
html[data-theme="dark"] { color-scheme: dark; }
.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: var(--app-theme-toggle-size, 2.25rem);
  height: var(--app-theme-toggle-size, 2.25rem);
  min-width: var(--app-theme-toggle-size, 2.25rem);
  min-height: var(--app-theme-toggle-size, 2.25rem);
  padding: 0;
  border: 0;
  border-radius: 0.5rem;
  background: transparent;
  color: #64748b;
  cursor: pointer;
  flex-shrink: 0;
  overflow: visible;
  line-height: 1;
  transition: color 150ms ease, background-color 150ms ease;
}
.theme-toggle:hover {
  color: #1e293b;
  background: #f1f5f9;
}
.theme-toggle:focus-visible {
  color: #1e293b;
  background: #f1f5f9;
  outline: 2px solid #1e40af;
  outline-offset: 2px;
}
.theme-toggle:active {
  color: #0f172a;
  background: #e2e8f0;
}
.theme-toggle .material-symbols-outlined {
  font-size: 22px !important;
  width: 1.375rem;
  height: 1.375rem;
  line-height: 1.375rem;
  display: block;
  overflow: visible;
  flex-shrink: 0;
}
.theme-toggle-label {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

html[data-theme="dark"] body {
  background: #0f172a !important;
  color: #e2e8f0 !important;
}
html[data-theme="dark"] header[style],
html[data-theme="dark"] nav[style*="background:#f9f9ff"],
html[data-theme="dark"] nav[style*="background: #f9f9ff"] {
  background: #111827 !important;
  border-color: #334155 !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.35) !important;
}
html[data-theme="dark"] aside[data-admin-sidebar-target="sidebar"] {
  background: #111827 !important;
  border-color: #334155 !important;
  color: #e2e8f0 !important;
}
html[data-theme="dark"] aside[data-admin-sidebar-target="sidebar"] [style*="color:#00288e"],
html[data-theme="dark"] aside[data-admin-sidebar-target="sidebar"] [style*="color:#1e293b"] {
  color: #93c5fd !important;
}
html[data-theme="dark"] aside[data-admin-sidebar-target="sidebar"] [style*="color:#585f6c"],
html[data-theme="dark"] aside[data-admin-sidebar-target="sidebar"] [style*="color:#757684"] {
  color: #94a3b8 !important;
}
html[data-theme="dark"] .sidebar-panel {
  background-color: #111827 !important;
  border-color: #334155 !important;
  color: #e2e8f0 !important;
}
html[data-theme="dark"] .sidebar-header {
  border-color: #334155 !important;
}
html[data-theme="dark"] .sidebar-footer {
  border-color: #334155 !important;
}
html[data-theme="dark"] .sidebar-toggle-btn {
  color: #94a3b8 !important;
}
html[data-theme="dark"] .sidebar-toggle-btn:hover,
html[data-theme="dark"] .sidebar-toggle-btn:focus-visible {
  color: #f1f5f9 !important;
  background-color: #334155 !important;
}
html[data-theme="dark"] .sidebar-spacer.sidebar-collapsed.sidebar-peeking .sidebar-panel {
  box-shadow: 4px 0 24px rgba(0, 0, 0, 0.45) !important;
}
html[data-theme="dark"] .theme-toggle {
  background: transparent !important;
  border-color: transparent !important;
  color: #94a3b8 !important;
}
html[data-theme="dark"] .theme-toggle:hover,
html[data-theme="dark"] .theme-toggle:focus-visible {
  background: #334155 !important;
  color: #e2e8f0 !important;
}
html[data-theme="dark"] .theme-toggle:active {
  background: #475569 !important;
}
html[data-theme="dark"] .list-link,
html[data-theme="dark"] .inbound-status-summary {
  background: #1e293b !important;
  border-color: #475569 !important;
  color: #e2e8f0 !important;
}
html[data-theme="dark"] .list-link:hover,
html[data-theme="dark"] .inbound-status-summary:hover {
  background: #334155 !important;
  border-color: #64748b !important;
}
html[data-theme="dark"] .detail-icon-btn {
  color: #94a3b8 !important;
}
html[data-theme="dark"] .detail-icon-btn:hover,
html[data-theme="dark"] .detail-icon-btn:focus-visible {
  color: #93c5fd !important;
  background: #334155 !important;
}
html[data-theme="dark"] .ds-table-card,
html[data-theme="dark"] .stack-table thead {
  background: #1e293b !important;
  border-color: #334155 !important;
}
html[data-theme="dark"] .stack-table tbody tr:hover,
html[data-theme="dark"] .inbound-table tr:hover,
html[data-theme="dark"] tr.hover\:bg-\[\#e8f4ff\]:hover {
  background-color: #334155 !important;
}
html[data-theme="dark"] .admin-input,
html[data-theme="dark"] .admin-select,
html[data-theme="dark"] .inbound-filter-bar input,
html[data-theme="dark"] .inbound-filter-bar select {
  background-color: #1e293b !important;
  border-color: #475569 !important;
  color: #e2e8f0 !important;
}
html[data-theme="dark"] .admin-btn-primary {
  background-color: #2563eb !important;
  color: #ffffff !important;
  border-color: transparent !important;
}
html[data-theme="dark"] .admin-btn-primary:hover,
html[data-theme="dark"] .admin-btn-primary:focus-visible {
  background-color: #1d4ed8 !important;
}
html[data-theme="dark"] .admin-btn-ghost,
html[data-theme="dark"] .admin-btn-delete {
  background-color: #1e293b !important;
  border-color: #475569 !important;
  color: #e2e8f0 !important;
}
html[data-theme="dark"] .admin-btn-ghost:hover,
html[data-theme="dark"] .admin-btn-ghost:focus-visible {
  background-color: #334155 !important;
  border-color: #64748b !important;
  color: #ffffff !important;
}
html[data-theme="dark"] .admin-btn-reject {
  background-color: #dc2626 !important;
  color: #ffffff !important;
  border-color: transparent !important;
}
html[data-theme="dark"] .admin-btn-reject:hover,
html[data-theme="dark"] .admin-btn-reject:focus-visible {
  background-color: #b91c1c !important;
}
html[data-theme="dark"] .bg-white,
html[data-theme="dark"] .card,
html[data-theme="dark"] .booking-card,
html[data-theme="dark"] .form-card,
html[data-theme="dark"] .inbound-card,
html[data-theme="dark"] section.bg-white,
html[data-theme="dark"] details.bg-white {
  background-color: #1e293b !important;
  border-color: #334155 !important;
  color: #e2e8f0 !important;
}
html[data-theme="dark"] .bg-transparent,
html[data-theme="dark"] button.bg-transparent,
html[data-theme="dark"] form.button_to button.bg-transparent {
  background-color: transparent !important;
  background: transparent !important;
}
html[data-theme="dark"] .bg-gray-50,
html[data-theme="dark"] .bg-gray-50\/80,
html[data-theme="dark"] .bg-gray-100,
html[data-theme="dark"] .bg-slate-50,
html[data-theme="dark"] .bg-slate-100,
html[data-theme="dark"] .bg-surface,
html[data-theme="dark"] .bg-background,
html[data-theme="dark"] .inbound-card-header {
  background-color: #111827 !important;
}
html[data-theme="dark"] .bg-gray-200,
html[data-theme="dark"] .bg-gray-300,
html[data-theme="dark"] .bg-slate-200,
html[data-theme="dark"] .bg-slate-300,
html[data-theme="dark"] button:disabled,
html[data-theme="dark"] input[type="submit"]:disabled {
  background-color: #334155 !important;
  color: #64748b !important;
  border-color: #475569 !important;
}
html[data-theme="dark"] .border-gray-50,
html[data-theme="dark"] .border-gray-100,
html[data-theme="dark"] .border-gray-200,
html[data-theme="dark"] .border-gray-300,
html[data-theme="dark"] .border-slate-100,
html[data-theme="dark"] .border-slate-200,
html[data-theme="dark"] .border-slate-300,
html[data-theme="dark"] .border-outline-variant {
  border-color: #334155 !important;
}
html[data-theme="dark"] .text-gray-900,
html[data-theme="dark"] .text-gray-800,
html[data-theme="dark"] .text-gray-700,
html[data-theme="dark"] .text-gray-600,
html[data-theme="dark"] .text-slate-900,
html[data-theme="dark"] .text-slate-800,
html[data-theme="dark"] .text-slate-700,
html[data-theme="dark"] .text-slate-600,
html[data-theme="dark"] .text-on-background,
html[data-theme="dark"] .text-on-surface,
html[data-theme="dark"] .app-topbar-title {
  color: #e2e8f0 !important;
}
html[data-theme="dark"] .text-gray-500,
html[data-theme="dark"] .text-gray-400,
html[data-theme="dark"] .text-slate-500,
html[data-theme="dark"] .text-slate-400 {
  color: #94a3b8 !important;
}
html[data-theme="dark"] .text-gray-300,
html[data-theme="dark"] .text-slate-300 {
  color: #475569 !important;
}
html[data-theme="dark"] input,
html[data-theme="dark"] select,
html[data-theme="dark"] textarea {
  background-color: #1e293b !important;
  border-color: #475569 !important;
  color: #e2e8f0 !important;
}
html[data-theme="dark"] input:focus,
html[data-theme="dark"] select:focus,
html[data-theme="dark"] textarea:focus,
html[data-theme="dark"] .admin-input:focus,
html[data-theme="dark"] .admin-select:focus {
  border-color: #38bdf8 !important;
  box-shadow: 0 0 0 2px rgba(56, 189, 248, 0.25) !important;
  outline: none !important;
}
html[data-theme="dark"] input::placeholder,
html[data-theme="dark"] textarea::placeholder {
  color: #94a3b8 !important;
}
html[data-theme="dark"] .data-table thead,
html[data-theme="dark"] .inbound-table th {
  background-color: #334155 !important;
  color: #cbd5e1 !important;
}
html[data-theme="dark"] .data-table tbody tr:hover {
  background-color: #334155 !important;
}
html[data-theme="dark"] .sidenav-link {
  color: #e2e8f0 !important;
  background-color: transparent !important;
}
html[data-theme="dark"] .sidenav-link .material-symbols-outlined {
  color: #94a3b8 !important;
}
html[data-theme="dark"] .sidenav-link:hover {
  background-color: #334155 !important;
  color: #ffffff !important;
}
html[data-theme="dark"] .sidenav-link:hover .material-symbols-outlined {
  color: #ffffff !important;
}
html[data-theme="dark"] .sidenav-link:focus-visible {
  outline: 2px solid #38bdf8 !important;
  outline-offset: 2px !important;
  background-color: #334155 !important;
  color: #ffffff !important;
}
html[data-theme="dark"] .sidenav-link:focus-visible .material-symbols-outlined {
  color: #ffffff !important;
}
html[data-theme="dark"] .sidenav-link.active {
  background-color: #2563eb !important;
  color: #ffffff !important;
}
html[data-theme="dark"] .sidenav-link.active .material-symbols-outlined {
  color: #ffffff !important;
}
html[data-theme="dark"] .sidenav-link.active:hover {
  background-color: #1d4ed8 !important;
  color: #ffffff !important;
}
html[data-theme="dark"] .sidebar-footer-btn {
  color: #e2e8f0 !important;
}
html[data-theme="dark"] .sidebar-footer-btn .material-symbols-outlined {
  color: #94a3b8 !important;
}
html[data-theme="dark"] .sidebar-footer-btn:hover {
  background-color: #334155 !important;
  color: #ffffff !important;
}
html[data-theme="dark"] .sidebar-footer-btn:hover .material-symbols-outlined {
  color: #ffffff !important;
}
html[data-theme="dark"] .sidebar-footer-btn:focus-visible {
  outline: 2px solid #38bdf8 !important;
  outline-offset: 2px !important;
  background-color: #334155 !important;
  color: #ffffff !important;
}

html[data-theme="dark"] .admin-fold,
html[data-theme="dark"] .inbound-attachment-row,
html[data-theme="dark"] .inbound-category-group,
html[data-theme="dark"] .inbound-timeline-step,
html[data-theme="dark"] .inbound-radio-label,
html[data-theme="dark"] .inbound-stat-card,
html[data-theme="dark"] .inbound-imap-section,
html[data-theme="dark"] .inbound-filter-bar,
html[data-theme="dark"] .inbound-table-container {
  background-color: #1e293b !important;
  border-color: #334155 !important;
  color: #e2e8f0 !important;
}
html[data-theme="dark"] .inbound-stat-card:hover {
  background-color: #334155 !important;
}
html[data-theme="dark"] .inbound-stat-label {
  color: #94a3b8 !important;
}
html[data-theme="dark"] .inbound-subject-text {
  color: #f8fafc !important;
}
html[data-theme="dark"] .inbound-table tr:hover .inbound-subject-text {
  color: #7dd3fc !important;
}
html[data-theme="dark"] .inbound-timeline-bar {
  background-color: #0f172a !important;
  border-color: #334155 !important;
}
html[data-theme="dark"] .inbound-timeline-step:hover,
html[data-theme="dark"] .inbound-radio-label:hover,
html[data-theme="dark"] .admin-fold > summary:hover,
html[data-theme="dark"] summary:hover {
  background-color: #334155 !important;
}
html[data-theme="dark"] .admin-fold > summary {
  color: #e2e8f0;
}
html[data-theme="dark"] .admin-fold[open] > summary {
  border-bottom-color: #334155;
}
html[data-theme="dark"] .admin-fold.is-danger {
  border-color: #9f1239;
}
html[data-theme="dark"] .admin-fold.is-danger > summary {
  color: #fda4af;
}
html[data-theme="dark"] .admin-fold.is-danger > summary:hover {
  background-color: #4c0519 !important;
}
html[data-theme="dark"] .inbound-timeline-step:has(input:checked),
html[data-theme="dark"] .inbound-radio-label:has(input:checked),
html[data-theme="dark"] [class*="has-[:checked]:bg-sky-50"] {
  background-color: #082f49 !important;
  border-color: #38bdf8 !important;
}
html[data-theme="dark"] .inbound-timeline-step:has(input:checked) .inbound-timeline-title,
html[data-theme="dark"] .inbound-radio-label:has(input:checked) .inbound-radio-text {
  color: #7dd3fc !important;
}
html[data-theme="dark"] .inbound-radio-label:has(input:focus-visible),
html[data-theme="dark"] .inbound-timeline-step:has(input:focus-visible) {
  outline: 2px solid #38bdf8 !important;
  outline-offset: 1px !important;
}
html[data-theme="dark"] .inbound-body-container {
  background-color: #1e293b !important;
  color: #e2e8f0 !important;
}
html[data-theme="dark"] .inbound-body-container .prose,
html[data-theme="dark"] .inbound-body-container .prose * {
  color: #e2e8f0 !important;
}
html[data-theme="dark"] .inbound-compact-alert {
  background: #422006 !important;
  border-color: #92400e !important;
  color: #fde68a !important;
}
html[data-theme="dark"] .org-support-steps-slot {
  background: #0f172a;
  border-color: #475569;
  color: #94a3b8;
}
html[data-theme="dark"] .org-support-steps-slot.is-filled {
  background: #082f49;
  border-color: #38bdf8;
  color: #7dd3fc;
}
html[data-theme="dark"] .org-support-this-step-title {
  color: #f8fafc;
}

/* Palette badge overrides for high contrast dark mode */
html[data-theme="dark"] .alert-notice,
html[data-theme="dark"] .bg-emerald-50,
html[data-theme="dark"] .bg-emerald-100 {
  background-color: #064e3b !important;
  color: #a7f3d0 !important;
  border-color: #047857 !important;
}
html[data-theme="dark"] .alert-warning,
html[data-theme="dark"] .bg-rose-50,
html[data-theme="dark"] .bg-rose-100,
html[data-theme="dark"] .bg-red-50,
html[data-theme="dark"] .bg-red-100 {
  background-color: #450a0a !important;
  color: #fecaca !important;
  border-color: #991b1b !important;
}
html[data-theme="dark"] .bg-sky-50,
html[data-theme="dark"] .bg-sky-100 {
  background-color: #082f49 !important;
  color: #bae6fd !important;
  border-color: #0369a1 !important;
}
html[data-theme="dark"] .bg-blue-50,
html[data-theme="dark"] .bg-blue-100 {
  background-color: #172554 !important;
  color: #bfdbfe !important;
  border-color: #1d4ed8 !important;
}
html[data-theme="dark"] .bg-amber-50,
html[data-theme="dark"] .bg-amber-50\/90,
html[data-theme="dark"] .bg-amber-100 {
  background-color: #451a03 !important;
  color: #fde68a !important;
  border-color: #92400e !important;
}
html[data-theme="dark"] .bg-orange-50,
html[data-theme="dark"] .bg-orange-100 {
  background-color: #431407 !important;
  color: #fed7aa !important;
  border-color: #c2410c !important;
}
html[data-theme="dark"] .bg-purple-50,
html[data-theme="dark"] .bg-purple-100 {
  background-color: #3b0764 !important;
  color: #e9d5ff !important;
  border-color: #7e22ce !important;
}
html[data-theme="dark"] .bg-teal-50,
html[data-theme="dark"] .bg-teal-100 {
  background-color: #042f2e !important;
  color: #99f6e4 !important;
  border-color: #0f766e !important;
}
html[data-theme="dark"] .bg-indigo-50,
html[data-theme="dark"] .bg-indigo-100 {
  background-color: #1e1b4b !important;
  color: #c7d2fe !important;
  border-color: #4338ca !important;
}
html[data-theme="dark"] .bg-lime-50,
html[data-theme="dark"] .bg-lime-100 {
  background-color: #1a2e05 !important;
  color: #d9f99d !important;
  border-color: #4d7c0f !important;
}
html[data-theme="dark"] .bg-stone-50,
html[data-theme="dark"] .bg-stone-100,
html[data-theme="dark"] .bg-stone-200 {
  background-color: #1c1917 !important;
  color: #e7e5e4 !important;
  border-color: #44403c !important;
}
html[data-theme="dark"] .bg-neutral-50,
html[data-theme="dark"] .bg-neutral-100 {
  background-color: #171717 !important;
  color: #e5e5e5 !important;
  border-color: #404040 !important;
}

/* Palette text overrides for high contrast dark mode */
html[data-theme="dark"] .text-sky-600,
html[data-theme="dark"] .text-sky-700,
html[data-theme="dark"] .text-sky-800,
html[data-theme="dark"] .text-sky-900 {
  color: #7dd3fc !important;
}
html[data-theme="dark"] .text-blue-600,
html[data-theme="dark"] .text-blue-700,
html[data-theme="dark"] .text-blue-800,
html[data-theme="dark"] .text-blue-900 {
  color: #93c5fd !important;
}
html[data-theme="dark"] .text-amber-600,
html[data-theme="dark"] .text-amber-700,
html[data-theme="dark"] .text-amber-800,
html[data-theme="dark"] .text-amber-900 {
  color: #fcd34d !important;
}
html[data-theme="dark"] .text-orange-600,
html[data-theme="dark"] .text-orange-700,
html[data-theme="dark"] .text-orange-800,
html[data-theme="dark"] .text-orange-900 {
  color: #fdba74 !important;
}
html[data-theme="dark"] .text-emerald-600,
html[data-theme="dark"] .text-emerald-700,
html[data-theme="dark"] .text-emerald-800,
html[data-theme="dark"] .text-emerald-900 {
  color: #a7f3d0 !important;
}
html[data-theme="dark"] .text-rose-600,
html[data-theme="dark"] .text-rose-700,
html[data-theme="dark"] .text-rose-800,
html[data-theme="dark"] .text-rose-900,
html[data-theme="dark"] .text-red-600,
html[data-theme="dark"] .text-red-700,
html[data-theme="dark"] .text-red-800 {
  color: #fda4af !important;
}
html[data-theme="dark"] .text-purple-600,
html[data-theme="dark"] .text-purple-700,
html[data-theme="dark"] .text-purple-800,
html[data-theme="dark"] .text-purple-900 {
  color: #e9d5ff !important;
}
html[data-theme="dark"] .text-teal-600,
html[data-theme="dark"] .text-teal-700,
html[data-theme="dark"] .text-teal-800 {
  color: #99f6e4 !important;
}
html[data-theme="dark"] .text-indigo-600,
html[data-theme="dark"] .text-indigo-700,
html[data-theme="dark"] .text-indigo-800 {
  color: #c7d2fe !important;
}
html[data-theme="dark"] .text-lime-600,
html[data-theme="dark"] .text-lime-700,
html[data-theme="dark"] .text-lime-800 {
  color: #d9f99d !important;
}
html[data-theme="dark"] .text-stone-600,
html[data-theme="dark"] .text-stone-700,
html[data-theme="dark"] .text-stone-800 {
  color: #e7e5e4 !important;
}
html[data-theme="dark"] .text-neutral-600,
html[data-theme="dark"] .text-neutral-700,
html[data-theme="dark"] .text-neutral-800 {
  color: #cbd5e1 !important;
}

/* Palette border overrides */
html[data-theme="dark"] .border-blue-200,
html[data-theme="dark"] .border-blue-300 {
  border-color: #1d4ed8 !important;
}
html[data-theme="dark"] .border-sky-200,
html[data-theme="dark"] .border-sky-300 {
  border-color: #0284c7 !important;
}
html[data-theme="dark"] .border-amber-200,
html[data-theme="dark"] .border-amber-300,
html[data-theme="dark"] .border-amber-200\/60 {
  border-color: #92400e !important;
}
html[data-theme="dark"] .border-emerald-200,
html[data-theme="dark"] .border-emerald-300 {
  border-color: #047857 !important;
}
html[data-theme="dark"] .border-rose-200,
html[data-theme="dark"] .border-rose-300 {
  border-color: #991b1b !important;
}
html[data-theme="dark"] .border-purple-200,
html[data-theme="dark"] .border-purple-300 {
  border-color: #7e22ce !important;
}
html[data-theme="dark"] .border-orange-200,
html[data-theme="dark"] .border-orange-300 {
  border-color: #c2410c !important;
}
html[data-theme="dark"] .border-teal-200,
html[data-theme="dark"] .border-teal-300 {
  border-color: #0f766e !important;
}
html[data-theme="dark"] .border-indigo-200,
html[data-theme="dark"] .border-indigo-300 {
  border-color: #4338ca !important;
}
html[data-theme="dark"] .border-lime-200,
html[data-theme="dark"] .border-lime-300 {
  border-color: #4d7c0f !important;
}
html[data-theme="dark"] .border-stone-200,
html[data-theme="dark"] .border-stone-300,
html[data-theme="dark"] .border-stone-400 {
  border-color: #44403c !important;
}

/* Dialog & Backdrop */
html[data-theme="dark"] .inbound-status-dialog {
  background: #1e293b !important;
  color: #e2e8f0 !important;
  border-color: #475569 !important;
}
html[data-theme="dark"] .inbound-status-dialog-head h2 {
  color: #f8fafc !important;
}
html[data-theme="dark"] .inbound-status-dialog-note {
  color: #94a3b8 !important;
  border-color: #475569 !important;
}
html[data-theme="dark"] dialog::backdrop {
  background: rgba(2, 6, 23, 0.72);
}

/* Comprehensive inline style overrides for dark mode */
html[data-theme="dark"] button[style*="background:#fff"],
html[data-theme="dark"] button[style*="background: #fff"],
html[data-theme="dark"] button[style*="background:#ffffff"],
html[data-theme="dark"] button[style*="background: #ffffff"] {
  background: #1e293b !important;
  border-color: #475569 !important;
  color: #e2e8f0 !important;
}
html[data-theme="dark"] [style*="background:#fff"],
html[data-theme="dark"] [style*="background: #fff"],
html[data-theme="dark"] [style*="background:#ffffff"],
html[data-theme="dark"] [style*="background: #ffffff"] {
  background-color: #1e293b !important;
}
html[data-theme="dark"] [style*="background:#f9f9ff"],
html[data-theme="dark"] [style*="background: #f9f9ff"] {
  background-color: #0f172a !important;
}
html[data-theme="dark"] [style*="color:#00288e"],
html[data-theme="dark"] [style*="color: #00288e"] {
  color: #93c5fd !important;
}
html[data-theme="dark"] [style*="color:#1e293b"],
html[data-theme="dark"] [style*="color: #1e293b"] {
  color: #f8fafc !important;
}
html[data-theme="dark"] [style*="color:#334155"],
html[data-theme="dark"] [style*="color: #334155"] {
  color: #e2e8f0 !important;
}
html[data-theme="dark"] [style*="color:#475569"],
html[data-theme="dark"] [style*="color: #475569"] {
  color: #cbd5e1 !important;
}
html[data-theme="dark"] [style*="color:#585f6c"],
html[data-theme="dark"] [style*="color: #585f6c"] {
  color: #94a3b8 !important;
}
html[data-theme="dark"] [style*="color:#757684"],
html[data-theme="dark"] [style*="color: #757684"] {
  color: #94a3b8 !important;
}
html[data-theme="dark"] [style*="border: 1px solid #c4c5d5"],
html[data-theme="dark"] [style*="border:1px solid #c4c5d5"],
html[data-theme="dark"] [style*="border-color:#c4c5d5"],
html[data-theme="dark"] [style*="border-bottom:1px solid #c4c5d5"],
html[data-theme="dark"] [style*="border-top:1px solid #c4c5d5"] {
  border-color: #334155 !important;
}
html[data-theme="dark"] [style*="border: 1px solid #e2e8f0"],
html[data-theme="dark"] [style*="border:1px solid #e2e8f0"],
html[data-theme="dark"] [style*="border-color:#e2e8f0"],
html[data-theme="dark"] [style*="border-bottom:1px solid #e2e8f0"],
html[data-theme="dark"] [style*="border-top:1px solid #e2e8f0"] {
  border-color: #334155 !important;
}
.inbound-overview {
  display: grid;
  gap: 0.35rem;
  margin-bottom: 0.65rem;
  padding: 0.6rem 0.75rem;
  border: 1px solid var(--ds-admin-border);
  border-radius: 0.65rem;
  background: var(--ds-admin-surface-muted);
  color: var(--ds-admin-text);
}
.inbound-overview .gateway-health-summary,
.inbound-overview .recommendation-performance-section,
.inbound-overview .inbound-imap-section {
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}
.inbound-overview .gateway-health-summary > .flex,
.inbound-overview .inbound-imap-summary,
.inbound-overview-line {
  min-height: 1.75rem;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.45rem 0.7rem;
}
.inbound-overview .gateway-health-summary > .flex {
  justify-content: space-between;
}
.inbound-overview-label {
  color: var(--ds-admin-muted);
  font-size: 0.68rem;
  font-weight: 700;
}
.inbound-overview-metric {
  color: var(--ds-admin-text);
  font-size: 0.72rem;
}
.inbound-overview-metric strong { color: var(--ds-admin-primary); }
.inbound-overview-metric small { color: var(--ds-admin-muted); font-size: 0.65rem; }
.inbound-overview-alert {
  color: #be123c;
  font-size: 0.68rem;
  font-weight: 700;
}
.inbound-overview-link {
  margin-left: auto;
  color: var(--ds-admin-primary);
  font-size: 0.68rem;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}
.inbound-overview-link:hover,
.inbound-overview-link:focus-visible { text-decoration: underline; text-underline-offset: 2px; }
.inbound-performance-details,
.inbound-health-details,
.inbound-lane-details {
  min-width: 0;
  color: var(--ds-admin-muted);
  font-size: 0.68rem;
}
.inbound-performance-details summary,
.inbound-health-details summary,
.inbound-lane-details summary {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  color: var(--ds-admin-muted);
  font-size: 0.68rem;
  font-weight: 700;
  cursor: pointer;
  list-style: none;
}
.inbound-performance-details summary::-webkit-details-marker,
.inbound-health-details summary::-webkit-details-marker,
.inbound-lane-details summary::-webkit-details-marker { display: none; }
.inbound-performance-details summary::before,
.inbound-health-details summary::before,
.inbound-lane-details summary::before {
  content: "›";
  display: inline-block;
  font-size: 0.9rem;
  line-height: 0.7;
  transition: transform 150ms ease;
}
.inbound-performance-details[open] summary::before,
.inbound-health-details[open] summary::before,
.inbound-lane-details[open] summary::before { transform: rotate(90deg); }
.inbound-performance-details > span {
  display: inline-block;
  margin-left: 0.65rem;
  color: var(--ds-admin-muted);
}
.inbound-health-details { margin-top: 0.25rem; border-top: 1px solid var(--ds-admin-border); padding-top: 0.35rem; }
.inbound-health-details summary span { color: var(--ds-admin-warning); }
.inbound-health-details > div > div {
  background: var(--ds-admin-surface-muted) !important;
  border-color: var(--ds-admin-border) !important;
}
.inbound-lane-details { grid-column: 1 / -1; width: 100%; margin-top: 0.15rem; border-top: 1px solid var(--ds-admin-border); padding-top: 0.35rem; }
.inbound-lane-details .inbound-stats-inline { margin-left: 0; }
.inbound-stat-chip,
.inbound-stat-card {
  height: 1.65rem;
  padding: 0 0.35rem;
  border: 0;
  border-bottom: 1px solid transparent;
  border-radius: 0.2rem;
  background: transparent;
}
.inbound-stat-chip:hover,
.inbound-stat-card:hover {
  background: transparent;
  border-bottom-color: var(--ds-admin-primary);
}
.inbound-stat-label { color: var(--ds-admin-muted); }
.inbound-stat-value { color: var(--ds-admin-text); }
html[data-theme="dark"] .inbound-overview-alert { color: #fda4af; }
@media (max-width: 639px) {
  .inbound-overview .gateway-health-summary > .flex,
  .inbound-overview-line { align-items: flex-start; }
  .inbound-overview-link { margin-left: 0; }
}
.admin-section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin: 1rem 0 0.55rem;
}
.admin-section-heading h3 { margin: 0; color: var(--ds-admin-text); font-size: 0.9rem; font-weight: 700; }
.admin-users-add-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(18rem, 1.2fr);
  align-items: end;
  gap: 0.75rem 1rem;
  padding: 0.85rem 1rem;
  border: 1px solid var(--ds-admin-border);
  border-radius: 0.65rem;
  background: var(--ds-admin-surface-muted);
}
.admin-users-add-card h3 { margin: 0; color: var(--ds-admin-text); font-size: 0.85rem; font-weight: 700; }
.admin-users-add-card p { margin: 0.2rem 0 0; color: var(--ds-admin-muted); font-size: 0.7rem; }
.admin-users-add-form { display: flex; align-items: center; gap: 0.45rem; min-width: 0; }
.admin-users-add-form .admin-input { flex: 1 1 auto; min-width: 0; }
.badge-admin {
  display: inline-flex;
  align-items: center;
  min-height: 1.5rem;
  padding: 0.15rem 0.55rem;
  border-radius: 9999px;
  background: #fef3c7;
  color: #92400e;
  font-size: 0.7rem;
  font-weight: 700;
  white-space: nowrap;
}
.admin-empty-cell { padding: 1.5rem !important; color: var(--ds-admin-muted); text-align: center !important; }
html[data-theme="dark"] .badge-admin { background: #422006; color: #fde68a; }
@media (max-width: 639px) {
  .admin-users-add-card { grid-template-columns: 1fr; }
  .admin-users-add-form { flex-wrap: wrap; }
  .admin-users-add-form .admin-input { flex-basis: 100%; }
}
.admin-detail-head { margin-bottom: 1rem; }
.admin-detail-head h2 { margin: 0.45rem 0 0; color: var(--ds-admin-text); font-size: 1.25rem; font-weight: 750; }
.admin-detail-head p { margin: 0.2rem 0 0; color: var(--ds-admin-muted); font-size: 0.75rem; }
.admin-directory-permission-card {
  margin-bottom: 1rem;
  padding: 0.9rem 1rem;
  border: 1px solid var(--ds-admin-border);
  border-radius: 0.65rem;
  background: var(--ds-admin-surface-muted);
}
.admin-grant-form { display: flex; flex-wrap: wrap; align-items: end; gap: 0.6rem; }
.admin-form-label { display: grid; gap: 0.25rem; color: var(--ds-admin-muted); font-size: 0.7rem; font-weight: 650; }
.admin-select { min-width: 7.5rem; padding: 0.45rem 0.55rem; border: 1px solid var(--ds-admin-border); border-radius: 0.4rem; background: var(--ds-admin-surface); color: var(--ds-admin-text); font: inherit; font-size: 0.78rem; }
.admin-select-wide { min-width: 12rem; }
.admin-help-text { margin: 0.65rem 0 0; color: var(--ds-admin-muted); font-size: 0.68rem; line-height: 1.5; }
.admin-grants-card { overflow: hidden; }
.admin-grants-card .admin-section-heading { padding: 0 1rem; }
@media (max-width: 767px) {
  .admin-grant-form > .admin-form-label { flex: 1 1 calc(50% - 0.6rem); min-width: 8.5rem; }
  .admin-grant-form > .admin-form-label.admin-select-wide { min-width: 0; }
  .admin-grant-form > .admin-btn { flex: 0 0 auto; }
}
@media (max-width: 479px) {
  .admin-grant-form > .admin-form-label { flex-basis: 100%; }
  .admin-select, .admin-select-wide { width: 100%; }
}
/* Cross-menu dark-mode correction: evaluation screens still contain legacy inline colors. */
.admin-evaluations-page input:not([type="hidden"]),
.admin-evaluations-page select,
.admin-evaluations-page textarea {
  background: var(--ds-admin-surface) !important;
  color: var(--ds-admin-text) !important;
  border-color: var(--ds-admin-border) !important;
}
html[data-theme="dark"] .admin-evaluations-page [style*="background:white"],
html[data-theme="dark"] .admin-evaluations-page [style*="background:#fff"] { background: var(--ds-admin-surface) !important; }
html[data-theme="dark"] .admin-evaluations-page [style*="background:#f8fafc"],
html[data-theme="dark"] .admin-evaluations-page [style*="background:#f1f5f9"] { background: var(--ds-admin-surface-muted) !important; }
html[data-theme="dark"] .admin-evaluations-page [style*="color:#0f172a"],
html[data-theme="dark"] .admin-evaluations-page [style*="color:#111827"],
html[data-theme="dark"] .admin-evaluations-page [style*="color:#1e293b"],
html[data-theme="dark"] .admin-evaluations-page [style*="color:#334155"],
html[data-theme="dark"] .admin-evaluations-page [style*="color:#475569"],
html[data-theme="dark"] .admin-evaluations-page [style*="color:#64748b"] { color: var(--ds-admin-text) !important; }
html[data-theme="dark"] .admin-evaluations-page [style*="color:#94a3b8"] { color: var(--ds-admin-muted) !important; }
html[data-theme="dark"] .admin-evaluations-page [style*="border-color:#e2e8f0"],
html[data-theme="dark"] .admin-evaluations-page [style*="border:1px solid #e2e8f0"],
html[data-theme="dark"] .admin-evaluations-page [style*="border-bottom:1px solid #e2e8f0"],
html[data-theme="dark"] .admin-evaluations-page [style*="border-bottom:1px solid #eff6ff"],
html[data-theme="dark"] .admin-evaluations-page [style*="border-top:1px solid #f1f5f9"] { border-color: var(--ds-admin-border) !important; }
.admin-sheet-modal-details > div { border-color: var(--ds-admin-border) !important; }
.admin-sheet-modal-details > div > div:first-child { color: var(--ds-admin-muted) !important; }
.admin-sheet-modal-details > div > div:last-child { color: var(--ds-admin-text) !important; }
html[data-theme="dark"] .admin-sheet-modal [style*="background:white"],
html[data-theme="dark"] .admin-sheet-modal [style*="background:#fff"] { background: var(--ds-admin-surface) !important; }
html[data-theme="dark"] .admin-sheet-modal [style*="background:#f8fafc"] { background: var(--ds-admin-surface-muted) !important; }
html[data-theme="dark"] .admin-sheet-modal [style*="color:#1e293b"],
html[data-theme="dark"] .admin-sheet-modal [style*="color:#334155"],
html[data-theme="dark"] .admin-sheet-modal [style*="color:#475569"],
html[data-theme="dark"] .admin-sheet-modal [style*="color:#64748b"] { color: var(--ds-admin-text) !important; }
html[data-theme="dark"] .admin-sheet-modal [style*="border:1px solid #cbd5e1"],
html[data-theme="dark"] .admin-sheet-modal [style*="border-bottom:1px solid #e2e8f0"] { border-color: var(--ds-admin-border) !important; }
.inbound-stats-details { flex: 1 1 100%; margin-top: 0.15rem; }
.inbound-stats-details > summary {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  color: var(--ds-admin-muted);
  font-size: 0.68rem;
  font-weight: 700;
  cursor: pointer;
  list-style: none;
}
.inbound-stats-details > summary::-webkit-details-marker { display: none; }
.inbound-stats-details > summary::before { content: "›"; font-size: 1rem; line-height: 0.7; transition: transform 120ms ease; }
.inbound-stats-details[open] > summary::before { transform: rotate(90deg); }
.inbound-stats-details[open] .inbound-stats-inline { margin-top: 0.35rem; }
.inbound-bulk-hint { color: var(--ds-admin-muted) !important; }
.admin-sheet-modal-detail-item {
  display: grid;
  grid-template-columns: minmax(9rem, 34%) minmax(0, 1fr);
  gap: 0.75rem;
  align-items: start;
  min-width: 0;
  padding: 0.55rem 0;
  border-bottom: 1px solid var(--ds-admin-border);
}
.admin-sheet-modal-detail-label {
  color: var(--ds-admin-muted);
  font-size: 0.72rem;
  font-weight: 800;
  line-height: 1.45;
  white-space: normal;
}
.admin-sheet-modal-detail-value {
  color: var(--ds-admin-text);
  font-size: 0.9rem;
  font-weight: 700;
  line-height: 1.55;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
@media (max-width: 640px) {
  .admin-sheet-modal-detail-item { grid-template-columns: 1fr; gap: 0.2rem; }
}
/* Shared admin dark-theme compatibility for legacy Tailwind utility markup. */
html[data-theme="dark"] main .bg-white,
html[data-theme="dark"] main [style*="background:white"],
html[data-theme="dark"] main [style*="background:#fff"] { background-color: var(--ds-admin-surface) !important; }
html[data-theme="dark"] main .bg-gray-50,
html[data-theme="dark"] main .bg-gray-100,
html[data-theme="dark"] main .bg-slate-50,
html[data-theme="dark"] main [style*="background:#f8fafc"],
html[data-theme="dark"] main [style*="background:#f1f5f9"] { background-color: var(--ds-admin-surface-muted) !important; }
html[data-theme="dark"] main .text-gray-900,
html[data-theme="dark"] main .text-gray-800,
html[data-theme="dark"] main .text-gray-700,
html[data-theme="dark"] main .text-gray-600,
html[data-theme="dark"] main .text-gray-500,
html[data-theme="dark"] main [style*="color:#0f172a"],
html[data-theme="dark"] main [style*="color:#111827"],
html[data-theme="dark"] main [style*="color:#1e293b"],
html[data-theme="dark"] main [style*="color:#334155"],
html[data-theme="dark"] main [style*="color:#475569"],
html[data-theme="dark"] main [style*="color:#64748b"] { color: var(--ds-admin-text) !important; }
html[data-theme="dark"] main .text-gray-400,
html[data-theme="dark"] main .text-gray-300,
html[data-theme="dark"] main [style*="color:#94a3b8"] { color: var(--ds-admin-muted) !important; }
html[data-theme="dark"] main .border-gray-100,
html[data-theme="dark"] main .border-gray-200,
html[data-theme="dark"] main .border-gray-300,
html[data-theme="dark"] main .border-slate-200,
html[data-theme="dark"] main [style*="border:1px solid #e2e8f0"],
html[data-theme="dark"] main [style*="border-bottom:1px solid #e2e8f0"] { border-color: var(--ds-admin-border) !important; }
html[data-theme="dark"] main .hover\:bg-\[\#e8f4ff\]:hover { background-color: #243447 !important; }
html[data-theme="dark"] main [class~="bg-white/80"] { background-color: var(--ds-admin-surface-muted) !important; }
.admin-eval-tabs {
  display: flex;
  gap: 0.25rem;
  align-items: center;
  margin-bottom: 0.35rem;
  border-bottom: 1px solid var(--ds-admin-border);
  overflow-x: auto;
}
.admin-eval-tab {
  padding: 0.38rem 0.65rem;
  border-radius: 0.35rem 0.35rem 0 0;
  color: var(--ds-admin-muted);
  background: var(--ds-admin-surface-muted);
  text-decoration: none;
  font-size: 0.76rem;
  font-weight: 800;
  white-space: nowrap;
}
.admin-eval-tab:hover { color: var(--ds-admin-text); }
.admin-eval-tab-active { color: #fff; background: #334155; }
html[data-theme="dark"] .admin-eval-tab-active { color: #0f172a; background: #cbd5e1; }
.admin-settlement-page { color: var(--ds-admin-text); }
html[data-theme="dark"] .admin-settlement-page [style*="background:white"],
html[data-theme="dark"] .admin-settlement-page [style*="background:#fff"],
html[data-theme="dark"] .admin-settlement-page [style*="background:#ffffff"] { background: var(--ds-admin-surface) !important; }
html[data-theme="dark"] .admin-settlement-page [style*="background:#f8fafc"],
html[data-theme="dark"] .admin-settlement-page [style*="background:#f1f5f9"] { background: var(--ds-admin-surface-muted) !important; }
html[data-theme="dark"] .admin-settlement-page [style*="color:#0f172a"],
html[data-theme="dark"] .admin-settlement-page [style*="color:#111827"],
html[data-theme="dark"] .admin-settlement-page [style*="color:#1e293b"],
html[data-theme="dark"] .admin-settlement-page [style*="color:#334155"],
html[data-theme="dark"] .admin-settlement-page [style*="color:#475569"],
html[data-theme="dark"] .admin-settlement-page [style*="color:#64748b"] { color: var(--ds-admin-text) !important; }
html[data-theme="dark"] .admin-settlement-page [style*="border:1px solid #e2e8f0"],
html[data-theme="dark"] .admin-settlement-page [style*="border-bottom:1px solid #e2e8f0"],
html[data-theme="dark"] .admin-settlement-page [style*="border-bottom:2px solid #e2e8f0"],
html[data-theme="dark"] .admin-settlement-page [style*="border-bottom:1px solid #f1f5f9"] { border-color: var(--ds-admin-border) !important; }
.inbound-overview {
  border: 0;
  border-bottom: 1px solid var(--ds-admin-border);
  border-radius: 0;
  background: transparent;
  padding: 0.35rem 0 0.5rem;
}
.inbound-overview .gateway-health-summary,
.inbound-overview .recommendation-performance-section,
.inbound-overview .inbound-imap-section { min-height: 1.5rem; }
.inbound-sender-filter,
.inbound-sender-label {
  color: var(--ds-admin-text);
  font-size: 0.72rem;
  line-height: 1.3;
  text-decoration: none;
}
.inbound-sender-filter:hover,
.inbound-sender-filter:focus-visible { color: var(--ds-admin-primary); text-decoration: underline; text-underline-offset: 2px; }
.inbound-category-text { color: var(--ds-admin-text); font-size: 0.7rem; }
.inbound-category-suggestion { display: inline; margin-left: 0.2rem; color: var(--ds-admin-muted); font-size: 0.64rem; }
.inbound-table .inbound-status-badge,
.inbound-table .inbound-publish-badge {
  display: inline;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent !important;
  color: var(--ds-admin-muted) !important;
  font-size: 0.68rem;
  font-weight: 600;
  white-space: nowrap;
}
.inbound-table .inbound-status-badge::after { content: ""; }
.inbound-table .inbound-publish-badge { font-weight: 500; }
html[data-theme="dark"] .inbound-table .inbound-status-badge,
html[data-theme="dark"] .inbound-table .inbound-publish-badge { color: var(--ds-admin-muted) !important; }
html[data-theme="dark"] main .inbound-table .inbound-status-badge,
html[data-theme="dark"] main .inbound-table .inbound-publish-badge {
  background: transparent !important;
  border-color: transparent !important;
  color: var(--ds-admin-muted) !important;
}
.inbound-detail-toolbar {
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  padding: 0 !important;
}
.inbound-detail-toolbar .inbound-status-summary {
  border: 0 !important;
  background: transparent !important;
  padding-left: 0.15rem !important;
  padding-right: 0.15rem !important;
}
.inbound-detail-status-line {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.25rem 0.55rem;
  min-height: 2rem;
  padding: 0.35rem 0;
  border-bottom: 1px solid var(--ds-admin-border);
  color: var(--ds-admin-muted);
  font-size: 0.68rem;
}
.inbound-detail-status-label { color: var(--ds-admin-text); font-weight: 700; }
.inbound-detail-status-edit {
  margin-left: auto;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--ds-admin-primary);
  font-size: 0.68rem;
  font-weight: 700;
  cursor: pointer;
}
.inbound-detail-container > .grid section,
.inbound-detail-container > section {
  box-shadow: none !important;
}
.inbound-detail-container .inbound-body-container { background: var(--ds-admin-surface) !important; }
.org-support-step-track {
  border-top: 1px solid var(--ds-admin-border);
  color: var(--ds-admin-text);
}
.org-step-card {
  min-height: 8rem;
  border: 1px solid var(--ds-admin-border);
  background: var(--ds-admin-surface-muted);
  color: var(--ds-admin-text);
}
.org-step-current {
  border: 1px solid var(--ds-admin-primary) !important;
  background: color-mix(in srgb, var(--ds-admin-primary) 10%, var(--ds-admin-surface)) !important;
}
.org-step-filled { background: var(--ds-admin-surface) !important; }
.org-step-empty { background: transparent !important; border-style: dashed !important; color: var(--ds-admin-muted); }
.org-step-card [class*="text-sky"],
.org-step-card [class*="text-gray"],
.org-step-card [class*="text-white"] { color: inherit !important; }
.org-step-card .org-step-state {
  display: inline;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  color: var(--ds-admin-muted) !important;
  font-size: 0.64rem;
  font-weight: 700;
  white-space: nowrap;
}
.org-step-current .org-step-state { color: var(--ds-admin-primary) !important; }
.org-step-card > div:first-child > div:first-child > span:first-child > span:first-child {
  background: var(--ds-admin-border) !important;
  color: var(--ds-admin-text) !important;
}
.org-step-current > div:first-child > div:first-child > span:first-child > span:first-child {
  background: var(--ds-admin-primary) !important;
  color: #fff !important;
}
.org-step-card .border-sky-200,
.org-step-card .border-gray-200 { border-color: var(--ds-admin-border) !important; }
.org-step-card [class*="border-t"] { border-color: var(--ds-admin-border) !important; }
.org-step-card a,
.org-step-card button { color: var(--ds-admin-primary) !important; }
.inbound-mail-nav {
  display: inline-flex;
  align-items: center;
  gap: 0.15rem;
}
.inbound-mail-nav > div { display: none; }
.inbound-mail-nav-link {
  min-height: 1.75rem;
  padding: 0.2rem 0.25rem;
  color: var(--ds-admin-muted) !important;
  background: transparent !important;
  border: 0 !important;
  border-radius: 0.25rem;
  font-size: 0.7rem;
  font-weight: 700;
  text-decoration: none;
}
.inbound-mail-nav-link:hover,
.inbound-mail-nav-link:focus-visible { color: var(--ds-admin-primary) !important; text-decoration: underline; text-underline-offset: 2px; }
.inbound-mail-nav-link.is-disabled { color: var(--ds-admin-border) !important; pointer-events: none; }
.inbound-notice-label {
  flex-shrink: 0;
  color: var(--ds-admin-warning);
  font-size: 0.68rem;
  font-weight: 700;
}
.org-step-heading { display: flex; align-items: center; justify-content: space-between; gap: 0.75rem; border-bottom: 1px solid var(--ds-admin-border); padding-bottom: 0.45rem; }
.org-step-heading-main { display: flex; align-items: baseline; flex-wrap: wrap; gap: 0.45rem; }
.org-step-title { color: var(--ds-admin-text); font-size: 0.76rem; font-weight: 800; }
.org-step-current-summary { color: var(--ds-admin-muted); font-size: 0.68rem; }
.org-step-current-summary strong { color: var(--ds-admin-primary); }
.org-step-type-summary { display: flex; align-items: center; flex-wrap: wrap; justify-content: flex-end; gap: 0.35rem 0.55rem; color: var(--ds-admin-muted); font-size: 0.68rem; }
.org-step-type-summary strong { color: var(--ds-admin-text); }
.org-step-recommendation { color: var(--ds-admin-primary); font-weight: 700; }
.org-step-edit-button,
.org-step-action-button {
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--ds-admin-primary);
  font-size: 0.66rem;
  font-weight: 700;
  cursor: pointer;
}
.org-step-edit-button:hover,
.org-step-action-button:hover { text-decoration: underline; text-underline-offset: 2px; }
.org-step-recommend-button {
  padding: 0.2rem 0.45rem;
  border: 1px solid var(--ds-admin-primary);
  border-radius: 0.25rem;
  background: transparent;
  color: var(--ds-admin-primary);
  font-size: 0.66rem;
  font-weight: 800;
  cursor: pointer;
}
.org-step-recommend-button:hover { background: color-mix(in srgb, var(--ds-admin-primary) 10%, transparent); }
@media (max-width: 767px) {
  .org-step-heading { align-items: flex-start; flex-direction: column; }
  .org-step-type-summary { justify-content: flex-start; }
}
.inbound-detail-type-fallback { display: inline-flex; align-items: center; flex-wrap: wrap; gap: 0.35rem; color: var(--ds-admin-muted); font-size: 0.68rem; }
.inbound-detail-type-link { padding: 0; border: 0; background: transparent; color: var(--ds-admin-muted); font-size: 0.68rem; cursor: pointer; }
.inbound-detail-type-link strong { color: var(--ds-admin-text); }
.inbound-detail-type-link > span:last-child { margin-left: 0.35rem; color: var(--ds-admin-primary); font-weight: 700; }
.inbound-detail-recommendation { margin-left: 0.25rem; color: var(--ds-admin-primary); font-weight: 700; }
.inbound-detail-recommend-button { padding: 0.2rem 0.45rem; border: 1px solid var(--ds-admin-primary); border-radius: 0.25rem; background: transparent; color: var(--ds-admin-primary); font-size: 0.66rem; font-weight: 800; cursor: pointer; }
.inbound-detail-type-fallback { display: flex; align-items: center; flex-wrap: wrap; gap: 0.65rem; margin-left: auto; }
.inbound-detail-type-summary { display: flex; align-items: center; flex-wrap: wrap; gap: 0.35rem 0.55rem; color: var(--ds-admin-muted); font-size: 0.68rem; }
.inbound-detail-type-summary strong { color: var(--ds-admin-text); }
.inbound-detail-type-edit,
.inbound-detail-recommend-button {
  padding: 0.25rem 0.55rem;
  border: 1px solid var(--ds-admin-border);
  border-radius: 0.3rem;
  background: transparent;
  color: var(--ds-admin-primary);
  font-size: 0.68rem;
  font-weight: 800;
  cursor: pointer;
}
.inbound-detail-type-edit:hover,
.inbound-detail-recommend-button:hover { background: color-mix(in srgb, var(--ds-admin-primary) 9%, transparent); }
.org-support-track-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 0.75rem; padding: 0.2rem 0 0.35rem; }
.org-support-track-toolbar-label { color: var(--ds-admin-muted); font-size: 0.68rem; font-weight: 700; }
.org-support-track-toolbar-actions { display: flex; align-items: center; gap: 0.45rem; }
.inbound-review-panel { padding: 0.8rem 0; border-bottom: 1px solid var(--ds-admin-border); }
.inbound-review-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 0.75rem; margin-bottom: 0.55rem; }
.inbound-review-heading h2 { margin: 0; color: var(--ds-admin-text); font-size: 0.76rem; font-weight: 800; }
.inbound-review-heading p { margin: 0.2rem 0 0; color: var(--ds-admin-muted); font-size: 0.67rem; }
.inbound-review-blocked { color: var(--ds-admin-warning); font-size: 0.65rem; font-weight: 700; }
.inbound-review-form { display: flex; flex-direction: column; gap: 0.45rem; }
.inbound-review-note { width: 100%; min-height: 3.2rem; resize: vertical; padding: 0.5rem 0.6rem; border: 1px solid var(--ds-admin-border); border-radius: 0.35rem; background: var(--ds-admin-surface-muted); color: var(--ds-admin-text); font-size: 0.72rem; }
.inbound-review-note::placeholder { color: var(--ds-admin-muted); }
.inbound-review-note:focus { outline: 2px solid color-mix(in srgb, var(--ds-admin-primary) 28%, transparent); outline-offset: 1px; }
.inbound-review-footer { display: flex; align-items: center; justify-content: space-between; gap: 0.6rem; }
.inbound-review-help { color: var(--ds-admin-warning); font-size: 0.65rem; }
.inbound-review-submit { margin-left: auto; padding: 0.35rem 0.7rem; border: 1px solid var(--ds-admin-primary); border-radius: 0.3rem; background: var(--ds-admin-primary); color: var(--ds-admin-surface); font-size: 0.7rem; font-weight: 800; cursor: pointer; }
.inbound-review-submit:hover { filter: brightness(0.94); }
.inbound-review-submit.is-disabled { border-color: var(--ds-admin-border); background: var(--ds-admin-surface-muted); color: var(--ds-admin-muted); cursor: not-allowed; }
.inbound-detail-sheet {
  border: 1px solid var(--ds-admin-border);
  border-radius: 0.4rem;
  background: var(--ds-admin-surface);
  color: var(--ds-admin-text);
}
.inbound-detail-identity {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem 1.25rem;
  flex-wrap: nowrap;
  padding: 0.7rem 0.85rem 0.35rem;
}
.inbound-detail-identity h1 {
  margin: 0;
  min-width: 0;
  flex: 1 1 auto;
  overflow: hidden;
  color: var(--ds-admin-text);
  font-size: 0.92rem;
  font-weight: 800;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.inbound-detail-identity p {
  margin: 0;
  flex: 0 1 auto;
  max-width: 46%;
  overflow: hidden;
  color: var(--ds-admin-muted);
  font-size: 0.72rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.inbound-detail-identity strong { color: var(--ds-admin-text); font-weight: 700; }
.inbound-decision {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem 1rem;
  flex-wrap: nowrap;
  padding: 0.15rem 0.85rem 0.7rem;
  border: 0;
}
.inbound-decision-copy {
  display: flex;
  align-items: baseline;
  gap: 0.45rem 0.7rem;
  min-width: 0;
  flex: 1 1 auto;
  flex-wrap: nowrap;
}
.inbound-decision .inbound-status-summary {
  display: inline-flex;
  height: auto;
  max-width: none;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--ds-admin-text);
  cursor: default;
  font-size: 0.78rem;
  font-weight: 600;
}
.inbound-decision .inbound-status-summary:hover,
.inbound-decision .inbound-status-summary:focus-visible {
  border: 0;
  background: transparent;
}
.inbound-decision-status {
  margin: 0;
  color: var(--ds-admin-muted);
  font-size: 0.72rem;
}
.inbound-decision-actions {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 0.4rem;
  margin-left: auto;
}
.inbound-decision-actions .inbound-review-submit { margin-left: 0; }
.inbound-decision-review {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.4rem;
  padding: 0;
  border: 0;
  background: transparent;
}
.inbound-decision-note-field { display: none; }
.inbound-detail-sheet .inbound-mail-fold {
  margin: 0;
  border: 0;
  border-top: 1px solid var(--ds-admin-border);
  border-radius: 0;
  background: transparent;
}
.inbound-detail-sheet .inbound-mail-fold > summary {
  padding: 0.55rem 0.85rem;
  color: var(--ds-admin-text);
  background: transparent;
  font-size: 0.75rem;
  font-weight: 700;
}
.inbound-detail-sheet .inbound-mail-fold > summary:hover {
  background: color-mix(in srgb, var(--ds-admin-surface-muted) 88%, transparent);
}
.inbound-detail-sheet .inbound-mail-fold[open] > summary {
  border-bottom: 1px solid var(--ds-admin-border);
}
.inbound-detail-sheet .inbound-mail-fold .admin-fold-panel {
  padding: 0.55rem 0.85rem 0.75rem;
  background: transparent;
}
.inbound-detail-sheet .inbound-body-container {
  padding: 0.15rem 0 0.2rem;
  background: transparent;
}
.inbound-recommendation-dialog { width: min(30rem, calc(100vw - 2rem)); max-width: 30rem; margin: auto; padding: 0; border: 1px solid var(--ds-admin-border); border-radius: 0.65rem; background: var(--ds-admin-surface); color: var(--ds-admin-text); box-shadow: 0 20px 45px color-mix(in srgb, var(--ds-admin-text) 20%, transparent); }
.inbound-recommendation-dialog::backdrop { background: color-mix(in srgb, var(--ds-admin-text) 48%, transparent); }
.inbound-recommendation-dialog-panel { padding: 1rem; }
.inbound-recommendation-dialog-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 0.75rem; padding-bottom: 0.75rem; border-bottom: 1px solid var(--ds-admin-border); }
.inbound-recommendation-dialog-heading h2 { margin: 0; font-size: 0.9rem; font-weight: 800; }
.inbound-recommendation-dialog-heading p { margin: 0.25rem 0 0; color: var(--ds-admin-muted); font-size: 0.68rem; }
.inbound-dialog-close, .inbound-dialog-cancel { padding: 0; border: 0; background: transparent; color: var(--ds-admin-muted); font-size: 0.68rem; cursor: pointer; }
.inbound-dialog-close:hover, .inbound-dialog-cancel:hover { color: var(--ds-admin-primary); text-decoration: underline; text-underline-offset: 2px; }
.inbound-recommendation-dialog-summary { display: flex; align-items: baseline; flex-wrap: wrap; gap: 0.4rem 0.6rem; padding: 0.8rem 0; color: var(--ds-admin-muted); font-size: 0.7rem; }
.inbound-recommendation-dialog-summary strong { color: var(--ds-admin-text); font-size: 0.82rem; }
.inbound-recommendation-form { display: flex; flex-direction: column; gap: 0.4rem; }
.inbound-recommendation-label { color: var(--ds-admin-text); font-size: 0.7rem; font-weight: 800; }
.inbound-recommendation-reason { width: 100%; resize: vertical; padding: 0.55rem 0.65rem; border: 1px solid var(--ds-admin-border); border-radius: 0.35rem; background: var(--ds-admin-surface-muted); color: var(--ds-admin-text); font-size: 0.72rem; }
.inbound-recommendation-form-footer { display: flex; align-items: center; justify-content: space-between; gap: 0.75rem; padding-top: 0.55rem; color: var(--ds-admin-muted); font-size: 0.65rem; }
.inbound-recommendation-form-actions { display: flex; align-items: center; gap: 0.7rem; }
.inbound-recommendation-submit { padding: 0.38rem 0.75rem; border: 1px solid var(--ds-admin-primary); border-radius: 0.3rem; background: var(--ds-admin-primary); color: var(--ds-admin-surface); font-size: 0.7rem; font-weight: 800; cursor: pointer; }
.inbound-recommendation-submit:hover { filter: brightness(0.94); }
@media (max-width: 640px) {
  .inbound-detail-type-fallback { margin-left: 0; width: 100%; }
  .inbound-recommendation-form-footer { align-items: flex-start; flex-direction: column; }
  .inbound-recommendation-form-actions { align-self: flex-end; }
}
.inbound-detail-container { gap: 0.5rem !important; }
.inbound-compact-toolbar { min-height: 2.2rem; padding: 0.35rem 0.55rem !important; }
.inbound-compact-toolbar .inbound-mail-nav-link { line-height: 1.1; }
.inbound-compact-notice { display: flex; align-items: center; gap: 0.45rem; min-height: 1.8rem; padding: 0.28rem 0.5rem; border-left: 2px solid var(--ds-admin-warning); color: var(--ds-admin-muted); font-size: 0.67rem; line-height: 1.25; }
.inbound-compact-notice .inbound-notice-label { color: var(--ds-admin-warning); font-weight: 800; }
.org-support-track-toolbar { min-height: 1.75rem; padding: 0.05rem 0 0.15rem; }
.org-support-track-toolbar-label { font-size: 0.66rem; }
.org-support-step-track-compact { padding: 0.55rem 0.7rem !important; }
.org-support-step-track-compact .org-step-heading { gap: 0.5rem; padding-bottom: 0.3rem; }
.org-support-step-track-compact .org-step-title { font-size: 0.7rem; }
.org-support-step-track-compact .org-step-current-summary,
.org-support-step-track-compact .org-step-type-summary { font-size: 0.64rem; }
.org-support-step-track-compact .org-step-heading-main { gap: 0.3rem; }
.org-support-step-track-compact .org-step-card { min-height: 6.35rem; }
.org-support-step-track-compact .org-step-card > div:first-child { gap: 0.35rem; }
.org-support-step-track-compact .org-step-card .space-y-1\.5 > :not([hidden]) ~ :not([hidden]) { margin-top: 0.35rem; }
.org-support-step-track-compact .org-step-card .pt-2 { padding-top: 0.35rem; }
.org-support-step-track-compact .org-step-card .mt-1 { margin-top: 0.35rem; }
.org-support-step-track-compact .org-step-card .text-sm { font-size: 0.78rem; }
.org-support-step-track-compact .org-step-card .sm\:text-base { font-size: 0.82rem; }
.org-support-step-track-compact .org-step-card .w-5 { width: 1.15rem; }
.org-support-step-track-compact .org-step-card .h-5 { height: 1.15rem; }
.org-support-step-track-compact .org-step-card .text-\[11px\] { font-size: 0.64rem; }
.org-support-step-track-compact .org-step-card .text-\[10px\] { font-size: 0.61rem; }
.org-support-step-track-compact .org-step-card { min-height: 5.25rem; padding: 0.55rem !important; }
.org-support-step-track-compact .org-step-card .space-y-1\.5 { row-gap: 0.25rem; }
.org-support-step-track-compact .org-step-card .pt-2 { padding-top: 0.25rem; }
.org-support-step-track-compact .org-step-card .mt-1 { margin-top: 0.25rem; }
.inbound-detail-container > :not([hidden]) ~ :not([hidden]) { margin-top: 0.35rem !important; }
.org-support-step-track-compact > :not([hidden]) ~ :not([hidden]) { margin-top: 0.35rem !important; }
.org-support-step-track-compact .org-step-card { padding: 0.45rem !important; }
.admin-submission-form-cell { min-width: 24rem; }
.admin-submission-form-link { display: block; max-width: 34rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.admin-submission-status { display: inline; font-size: 0.72rem; font-weight: 700; white-space: nowrap; }
.admin-submission-status-pending { color: var(--ds-admin-warning); }
.admin-submission-status-approved { color: #15803d; }
.admin-submission-status-rejected { color: #be123c; }
.admin-submission-status-draft { color: var(--ds-admin-muted); }
html[data-theme="dark"] .admin-submission-status-approved { color: #86efac; }
html[data-theme="dark"] .admin-submission-status-rejected { color: #fda4af; }
@media (max-width: 767px) {
  .admin-submission-form-cell { min-width: 0; }
  .admin-submission-form-link { max-width: 100%; }
}
:root { --ds-admin-success: #15803d; --ds-admin-danger: #be123c; }
html[data-theme="dark"] { --ds-admin-success: #86efac; --ds-admin-danger: #fda4af; }
.admin-submission-status-approved { color: var(--ds-admin-success); }
.admin-submission-status-rejected { color: var(--ds-admin-danger); }
.admin-evaluations-head { display: flex; align-items: center; justify-content: space-between; gap: 0.6rem; margin-bottom: 0.25rem; flex-wrap: wrap; }
.admin-evaluations-title-group { display: flex; align-items: baseline; gap: 0.45rem; min-width: 0; }
.admin-evaluations-title-group h2 { margin: 0; color: var(--ds-admin-text); font-size: 1rem; font-weight: 800; }
.admin-evaluations-counts { color: var(--ds-admin-muted); font-size: 0.66rem; white-space: nowrap; }
.admin-evaluations-actions { display: flex; align-items: center; gap: 0.35rem; flex-wrap: wrap; }
.admin-evaluations-mode-note { margin: 0 0 0.45rem; color: var(--ds-admin-muted); font-size: 0.68rem; }
.admin-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 1.85rem;
  padding: 0.25rem 0.55rem;
  border: 1px solid transparent;
  border-radius: 0.3rem;
  font: inherit;
  font-size: 0.7rem;
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
}
.admin-btn-primary { background: var(--ds-admin-primary); color: var(--ds-admin-surface); }
.admin-btn-primary:hover { filter: brightness(0.93); }
.admin-btn-success { border-color: color-mix(in srgb, var(--ds-admin-success) 35%, var(--ds-admin-border)); background: transparent; color: var(--ds-admin-success); }
.admin-btn-warning { border-color: color-mix(in srgb, var(--ds-admin-warning) 35%, var(--ds-admin-border)); background: transparent; color: var(--ds-admin-warning); }
.admin-btn-danger { border-color: color-mix(in srgb, var(--ds-admin-danger) 35%, var(--ds-admin-border)); background: transparent; color: var(--ds-admin-danger); }
.admin-team-table-wrap { overflow: hidden; border: 1px solid var(--ds-admin-border); border-radius: 0.55rem; background: var(--ds-admin-surface); }
.admin-team-table { width: 100%; border-collapse: collapse; }
.admin-team-table thead { border-bottom: 1px solid var(--ds-admin-border); background: var(--ds-admin-surface-muted); }
.admin-team-table th { padding: 0.65rem 0.7rem; color: var(--ds-admin-muted); font-size: 0.68rem; font-weight: 800; text-align: left; white-space: nowrap; }
.admin-team-table th.is-centered,
.admin-team-table td.is-centered { text-align: center; }
.admin-team-table tbody tr { border-bottom: 1px solid var(--ds-admin-border); }
.admin-team-table tbody tr:last-child { border-bottom: 0; }
.admin-team-table td { padding: 0.65rem 0.7rem; color: var(--ds-admin-text); font-size: 0.74rem; vertical-align: middle; white-space: nowrap; }
.admin-team-table tbody tr:hover { background: color-mix(in srgb, var(--ds-admin-primary) 5%, transparent); }
.admin-team-key,
.admin-team-muted { color: var(--ds-admin-muted) !important; }
.admin-team-meta { margin-top: 0.15rem; color: var(--ds-admin-muted); font-size: 0.66rem; }
.admin-team-status-active,
.admin-team-status-closed { font-weight: 700; }
.admin-team-status-active { color: var(--ds-admin-success); }
.admin-team-status-closed { color: var(--ds-admin-danger); }
.admin-team-actions { white-space: nowrap; }
.admin-team-inline-form { display: inline; }
.admin-team-action-button { min-height: 1.65rem; padding: 0.2rem 0.45rem; font-size: 0.66rem; }
.admin-team-edit-link { color: var(--ds-admin-primary); font-size: 0.7rem; font-weight: 700; text-decoration: none; }
.admin-team-edit-link:hover { text-decoration: underline; text-underline-offset: 2px; }
.admin-team-delete-button { margin-left: 0.55rem; padding: 0; border: 0; background: transparent; color: var(--ds-admin-danger); font-size: 0.7rem; font-weight: 700; cursor: pointer; }
.admin-team-delete-disabled { margin-left: 0.55rem; color: var(--ds-admin-muted); font-size: 0.68rem; }
.admin-eval-filter-form { display: flex; align-items: center; gap: 0.3rem; flex-wrap: wrap; margin-bottom: 0.45rem; }
.admin-eval-response-filter { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 0.1rem; }
.admin-eval-filter-input { min-height: 1.85rem; padding: 0.25rem 0.42rem; border: 1px solid var(--ds-admin-border); border-radius: 0.3rem; background: var(--ds-admin-surface); color: var(--ds-admin-text); font: inherit; font-size: 0.7rem; }
.admin-eval-filter-search { width: 11rem; }
.admin-eval-date { width: 8.5rem; }
.admin-eval-filter-input:focus-visible { outline: 2px solid color-mix(in srgb, var(--ds-admin-primary) 35%, transparent); outline-offset: 1px; }
.admin-eval-filter-link { display: inline-flex; align-items: center; min-height: 1.85rem; padding: 0.25rem 0.48rem; border-radius: 0.3rem; color: var(--ds-admin-muted); font-size: 0.68rem; font-weight: 700; text-decoration: none; white-space: nowrap; }
.admin-eval-filter-link:hover,
.admin-eval-filter-link.is-selected { background: var(--ds-admin-surface-muted); color: var(--ds-admin-text); }
.admin-eval-empty { padding: 1rem 0; border-top: 1px solid var(--ds-admin-border); color: var(--ds-admin-muted); font-size: 0.72rem; text-align: center; }
@media (max-width: 767px) {
  .admin-eval-response-filter { flex-wrap: wrap; overflow: visible; }
  .admin-eval-filter-search { width: min(100%, 14rem); }
}
.admin-settlement-table th,
.admin-settlement-table td { padding-top: 0.45rem !important; padding-bottom: 0.45rem !important; }
.admin-settlement-table th:nth-child(4),
.admin-settlement-table td:nth-child(4) { display: none; }
.admin-settlement-page [data-testid="admin-settlement-table"] { padding: 0.9rem !important; }
.admin-settlement-page [data-testid="admin-settlement-table"] > h3 { margin-bottom: 0.55rem !important; font-size: 0.86rem !important; }
.admin-settlement-page > div:nth-of-type(2) { padding: 0.9rem !important; margin-bottom: 0.8rem !important; }
.admin-settlement-page > div:nth-of-type(2) h3 { margin-bottom: 0.55rem !important; padding-bottom: 0.35rem !important; font-size: 0.86rem !important; }
html[data-theme="dark"] .admin-submission-edit .fin-row,
html[data-theme="dark"] .admin-submission-edit .fin-paper,
html[data-theme="dark"] .admin-submission-edit .admin-fin-main-panel > div { background: var(--ds-admin-surface) !important; border-color: var(--ds-admin-border) !important; color: var(--ds-admin-text) !important; }
html[data-theme="dark"] .admin-submission-edit .fin-row input,
html[data-theme="dark"] .admin-submission-edit .fin-row select,
html[data-theme="dark"] .admin-submission-edit .input-field { background: var(--ds-admin-surface-muted) !important; border-color: var(--ds-admin-border) !important; color: var(--ds-admin-text) !important; }
html[data-theme="dark"] .admin-submission-edit .fin-row input::placeholder,
html[data-theme="dark"] .admin-submission-edit .input-field::placeholder { color: var(--ds-admin-muted) !important; }
.admin-settlement-table { width: 100%; min-width: 600px; border-collapse: collapse; font-size: 0.875rem; }
.admin-settlement-table th { width: auto; padding: 0.45rem 0.6rem !important; border-bottom: 1px solid var(--ds-admin-border); background: var(--ds-admin-surface-muted); color: var(--ds-admin-muted); text-align: left; font-weight: 800; }
.admin-settlement-table th:first-child { width: 3rem; }
.admin-settlement-table th:nth-child(2) { width: 15rem; }
.admin-settlement-table th:nth-child(3) { width: 10rem; text-align: right; }
.admin-settlement-table td { padding: 0.45rem 0.6rem !important; border-bottom: 1px solid var(--ds-admin-border); color: var(--ds-admin-text); }
.admin-settlement-table td:first-child { color: var(--ds-admin-muted); }
.admin-settlement-table td:nth-child(2) { font-weight: 650; }
.admin-settlement-table td:nth-child(3) { text-align: right; font-weight: 700; white-space: nowrap; }
.admin-settlement-table td:nth-child(4) { display: none; }
.admin-settlement-row-secondary { background: var(--ds-admin-surface-muted); }
.admin-settlement-row-warning { background: color-mix(in srgb, var(--ds-admin-warning) 10%, var(--ds-admin-surface)); }
.admin-settlement-row-warning td { color: var(--ds-admin-warning); }
.admin-settlement-row-highlight { background: color-mix(in srgb, var(--ds-admin-primary) 9%, var(--ds-admin-surface)); }
.admin-settlement-row-highlight td { color: var(--ds-admin-primary); }
.admin-settlement-row-final { background: color-mix(in srgb, var(--ds-admin-primary) 12%, var(--ds-admin-surface)); }
.admin-settlement-row-final td { border-bottom: 2px solid var(--ds-admin-border); color: var(--ds-admin-primary); font-weight: 800; }
.admin-settlement-row-final td:nth-child(3) { font-size: 1rem; }
.admin-eval-team-table-wrap { overflow: auto; background: var(--ds-admin-surface); border: 1px solid var(--ds-admin-border); border-radius: 0.5rem; }
.admin-eval-team-table { width: 100%; min-width: 980px; border-collapse: collapse; }
.admin-eval-team-table thead { background: var(--ds-admin-surface-muted); border-bottom: 1px solid var(--ds-admin-border); }
.admin-eval-team-table th { padding: 0.5rem 0.65rem; color: var(--ds-admin-muted); font-size: 0.7rem; font-weight: 900; text-align: left; white-space: nowrap; }
.admin-eval-team-table th:nth-child(6) { text-align: right; }
.admin-eval-team-row { border-bottom: 1px solid var(--ds-admin-border); }
.admin-eval-team-cell { padding: 0.5rem 0.65rem; font-size: 0.78rem; white-space: nowrap; color: var(--ds-admin-text); }
.admin-eval-team-cell:nth-child(2), .admin-eval-team-cell:nth-child(4), .admin-eval-team-cell:nth-child(5) { color: var(--ds-admin-muted); }
.admin-eval-team-count { text-align: right; }
.admin-eval-team-count-link { display: inline-block; padding: 0.2rem 0.5rem; border: 1px solid color-mix(in srgb, var(--ds-admin-primary) 35%, var(--ds-admin-border)); border-radius: 999px; background: color-mix(in srgb, var(--ds-admin-primary) 10%, var(--ds-admin-surface)); color: var(--ds-admin-primary); font-size: 0.78rem; font-weight: 900; text-decoration: none; }
.admin-eval-team-zero, .admin-eval-team-delete-disabled { color: var(--ds-admin-muted); font-size: 0.78rem; font-weight: 900; }
.admin-eval-team-detail-cell { padding: 0; border-bottom: 1px solid var(--ds-admin-border); background: var(--ds-admin-surface-muted); }
.admin-eval-team-detail-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; padding: 0.75rem 0.9rem; }
.admin-eval-team-detail-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0.75rem; flex: 1; }
.admin-eval-team-detail-label { color: var(--ds-admin-muted); font-size: 0.7rem; font-weight: 900; }
.admin-eval-team-detail-value { color: var(--ds-admin-text); font-size: 0.9rem; font-weight: 800; }
.admin-eval-team-actions { display: flex; gap: 0.4rem; align-items: center; white-space: nowrap; }
.admin-eval-team-empty { padding: 1.5rem; color: var(--ds-admin-muted); text-align: center; }
.admin-eval-response-group { margin-bottom: 0.75rem; }
.admin-eval-response-head { display: flex; align-items: center; gap: 0.4rem; margin-bottom: 0.35rem; }
.admin-eval-response-role, .admin-eval-summary-role { padding: 0.14rem 0.5rem; border-radius: 0.3rem; background: var(--ds-admin-primary); color: #fff; font-size: 0.76rem; font-weight: 900; white-space: nowrap; }
.admin-eval-response-count, .admin-eval-summary-metric { color: var(--ds-admin-primary); font-size: 0.74rem; font-weight: 900; white-space: nowrap; }
.admin-eval-response-table-wrap { overflow: auto; background: var(--ds-admin-surface); border: 1px solid color-mix(in srgb, var(--ds-admin-info) 35%, var(--ds-admin-border)); border-radius: 0.5rem; }
.admin-eval-response-table { width: 100%; min-width: max-content; border-collapse: separate; border-spacing: 0; }
.admin-eval-response-th { padding: 0.4rem 0.55rem; border-bottom: 1px solid var(--ds-admin-border); background: var(--ds-admin-surface-muted); color: var(--ds-admin-muted); font-size: 0.68rem; font-weight: 900; white-space: nowrap; }
.admin-eval-response-th-date { position: sticky; left: 0; z-index: 4; width: 8.5rem; min-width: 8.5rem; text-align: left; }
.admin-eval-response-th.is-scale, .admin-eval-response-answer.is-scale { width: 3.4rem; min-width: 3.4rem; text-align: center; }
.admin-eval-response-th.is-text, .admin-eval-response-answer.is-text { max-width: 11rem; overflow: hidden; text-overflow: ellipsis; text-align: left; }
.admin-eval-response-date { position: sticky; left: 0; z-index: 3; width: 8.5rem; min-width: 8.5rem; padding: 0.4rem 0.55rem; border-bottom: 1px solid var(--ds-admin-border); background: var(--ds-admin-surface); color: var(--ds-admin-text); font-size: 0.76rem; font-weight: 900; white-space: nowrap; }
.admin-eval-response-answer { padding: 0.4rem 0.55rem; border-bottom: 1px solid var(--ds-admin-border); color: var(--ds-admin-text); font-size: 0.76rem; white-space: nowrap; }
.admin-eval-summary-card { margin-bottom: 0.75rem; padding: 0.75rem; border: 1px solid var(--ds-admin-border); border-radius: 0.5rem; background: var(--ds-admin-surface); }
.admin-eval-summary-head { display: flex; align-items: center; gap: 0.45rem; margin-bottom: 0.6rem; }
.admin-eval-summary-role { background: var(--ds-admin-text); }
.admin-eval-summary-count { color: var(--ds-admin-muted); font-size: 0.78rem; font-weight: 900; }
.admin-eval-summary-chart { margin-top: 0.6rem; padding-top: 0.6rem; border-top: 1px solid var(--ds-admin-border); }
.admin-eval-summary-chart-head { display: flex; justify-content: space-between; gap: 0.75rem; align-items: flex-start; margin-bottom: 0.4rem; }
.admin-eval-summary-question { color: var(--ds-admin-text); font-size: 0.82rem; font-weight: 900; line-height: 1.45; }
.admin-eval-summary-metrics { display: flex; justify-content: flex-end; gap: 0.35rem; align-items: center; flex-wrap: wrap; }
.admin-eval-summary-na { padding: 0.12rem 0.45rem; border: 1px solid color-mix(in srgb, var(--ds-admin-warning) 40%, var(--ds-admin-border)); border-radius: 999px; background: color-mix(in srgb, var(--ds-admin-warning) 10%, var(--ds-admin-surface)); color: var(--ds-admin-warning); font-size: 0.72rem; font-weight: 900; white-space: nowrap; }
.admin-eval-bar-row { display: grid; grid-template-columns: 5.5rem minmax(0, 1fr) 3rem; gap: 0.45rem; align-items: center; margin: 0.28rem 0; }
.admin-eval-bar-label { overflow: hidden; color: var(--ds-admin-muted); font-size: 0.74rem; font-weight: 900; text-overflow: ellipsis; white-space: nowrap; }
.admin-eval-bar-track { height: 0.72rem; overflow: hidden; border-radius: 999px; background: var(--ds-admin-border); }
.admin-eval-bar-fill { height: 100%; background: var(--ds-admin-primary); }
.admin-eval-bar-count { color: var(--ds-admin-text); font-size: 0.74rem; font-weight: 900; text-align: right; }
.admin-eval-sheet-modal { background: var(--ds-admin-surface-muted); }
.admin-eval-sheet-panel { width: 100%; min-height: 100vh; overflow: hidden; background: var(--ds-admin-surface); }
.admin-eval-sheet-header { position: sticky; top: 0; z-index: 2; display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: 0.75rem 1.5rem; border-bottom: 1px solid var(--ds-admin-border); background: var(--ds-admin-surface); }
.admin-eval-sheet-title { margin: 0; color: var(--ds-admin-text); font-size: 1rem; font-weight: 900; }
.admin-eval-sheet-meta, .admin-eval-sheet-section-meta { margin: 0.2rem 0 0; color: var(--ds-admin-muted); font-size: 0.75rem; }
.admin-eval-sheet-title-block { min-width: 0; }
.admin-eval-sheet-nav, .admin-eval-sheet-actions { display: flex; gap: 0.35rem; align-items: center; justify-content: flex-end; white-space: nowrap; }
.admin-eval-sheet-close { width: 2rem; height: 2rem; padding: 0 !important; font-size: 1rem; line-height: 1; }
.admin-eval-sheet-body { padding: 1rem 1.5rem 1.5rem; }
.admin-eval-sheet-summary-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: 0.7rem; }
.admin-eval-sheet-section-title { color: var(--ds-admin-text); font-size: 0.8125rem; font-weight: 900; }
.admin-eval-sheet-details { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 2rem; row-gap: 0; align-items: start; }
.admin-eval-sheet-confirm { max-width: 520px; margin: 3rem auto 0; padding: 1rem; border: 1px solid var(--ds-admin-danger); border-radius: 0.5rem; background: color-mix(in srgb, var(--ds-admin-danger) 8%, var(--ds-admin-surface)); }
.admin-eval-sheet-confirm-title { margin: 0; color: var(--ds-admin-danger); font-size: 1rem; font-weight: 900; }
.admin-eval-sheet-confirm-text { margin: 0.45rem 0 0; color: var(--ds-admin-danger); font-size: 0.875rem; line-height: 1.5; }
.admin-eval-sheet-confirm-actions { margin-top: 1rem; }
.admin-submission-sealed-note, .admin-dialog-note { margin: 0 0 1rem; color: var(--ds-admin-muted); font-size: 0.8125rem; line-height: 1.5; }
.admin-submission-content-card, .admin-submission-side-card { margin-bottom: 1rem; padding: 1rem; border: 1px solid var(--ds-admin-border); border-radius: 0.65rem; background: var(--ds-admin-surface); }
.admin-submission-content-title { margin: 0 0 0.75rem; padding-bottom: 0.6rem; border-bottom: 1px solid var(--ds-admin-border); color: var(--ds-admin-text); font-size: 1rem; font-weight: 800; }
.admin-submission-form-data { padding: 1rem; border: 1px solid var(--ds-admin-border); border-radius: 0.65rem; background: var(--ds-admin-surface-muted); }
.admin-submission-content-note { color: var(--ds-admin-muted); font-size: 0.875rem; line-height: 1.6; }
.admin-submission-layout:not(.admin-fin-side) { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 1rem; }
.admin-submission-side-card { margin-bottom: 0; }
.admin-submission-audit-entry { padding: 0.45rem 0; border-bottom: 1px solid var(--ds-admin-border); color: var(--ds-admin-text); font-size: 0.8125rem; }
.admin-submission-audit-entry.is-financial { padding: 0.3rem 0; font-size: 0.75rem; }
.admin-submission-muted { color: var(--ds-admin-muted); }
.admin-submission-empty { color: var(--ds-admin-muted); font-size: 0.8125rem; }
.admin-submission-empty.is-financial { margin: 0; font-size: 0.75rem; }
.admin-submission-side-title { margin: 0 0 0.75rem; color: var(--ds-admin-text); font-size: 1rem; font-weight: 800; }
.admin-submission-side-title.is-muted { color: var(--ds-admin-muted); }
.admin-submission-process-log { display: grid; gap: 0.35rem; font-size: 0.75rem; }
.admin-submission-rejection-text, .admin-submission-value.is-danger { color: var(--ds-admin-danger); }
.admin-submission-status-details { display: grid; gap: 0.6rem; font-size: 0.875rem; }
.admin-submission-status-row { display: flex; justify-content: space-between; gap: 0.75rem; }
.admin-submission-value { color: var(--ds-admin-text); }
.admin-submission-value.is-success { color: var(--ds-admin-success); }
.admin-submission-rejection-block { margin-top: 1rem; padding-top: 0.75rem; border-top: 1px solid var(--ds-admin-border); }
.admin-submission-rejection-title { margin: 0 0 0.4rem; color: var(--ds-admin-danger); font-size: 0.875rem; font-weight: 800; }
.admin-dialog-title { margin: 0 0 0.5rem; font-size: 1.125rem; font-weight: 800; }
.admin-dialog-textarea { width: 100%; min-height: 100px; box-sizing: border-box; padding: 0.75rem; border: 1px solid var(--ds-admin-border); border-radius: 0.5rem; background: var(--ds-admin-surface-muted); color: var(--ds-admin-text); font-family: inherit; }
.admin-confirm-dialog-title { margin: 0; color: var(--ds-admin-text); font-size: 1rem; font-weight: 800; }
.admin-confirm-dialog-note { margin: 0.5rem 0 0; color: var(--ds-admin-muted); font-size: 0.8125rem; }
@media (max-width: 800px) { .admin-submission-layout:not(.admin-fin-side) { grid-template-columns: 1fr; } }
.admin-fin-main-tabs-first { margin-top: 0; }
.admin-fin-section-first { margin-top: 0; padding-top: 0; border-top: 0; }
.admin-fin-breakdown { margin-top: 0.75rem; }
.admin-fin-cover-breakdown { grid-template-columns: 1fr; margin: 0; }
.admin-fin-entry-tabs { justify-content: flex-start; margin: 0 0 0.4rem; }
.admin-fin-delivery-head { display: flex; align-items: center; justify-content: space-between; gap: 0.75rem; }
.admin-fin-delivery-note { margin: 0; color: var(--ds-admin-muted); font-size: 0.75rem; }
.admin-fin-delivery-muted { color: var(--ds-admin-muted); font-size: 0.75rem; }
.admin-fin-delivery-table { margin-top: 0.5rem; }
.admin-financial-settlement-summary { margin-top: 1rem; color: var(--ds-admin-text); font-size: 0.875rem; }
.admin-financial-settlement-value { margin: 0; }
.admin-financial-settlement-formula { margin-top: 0.5rem; }
.admin-financial-settlement-formula > summary { cursor: pointer; color: var(--ds-admin-text); font-size: 0.8125rem; font-weight: 700; }
.admin-financial-settlement-formula > ul { margin: 0.5rem 0 0; padding-left: 1.15rem; color: var(--ds-admin-muted); font-size: 0.75rem; line-height: 1.6; }
.admin-hidden-submit-form { display: none; }
html[data-theme="dark"] .admin-submission-show .admin-fin,
html[data-theme="dark"] .admin-submission-show .admin-fin-kpis,
html[data-theme="dark"] .admin-submission-show .admin-fin-kpi,
html[data-theme="dark"] .admin-submission-show .admin-fin-table-wrap,
html[data-theme="dark"] .admin-submission-show .admin-fin-main-tabs,
html[data-theme="dark"] .admin-submission-show .admin-fin-main-panel { background: var(--ds-admin-surface) !important; border-color: var(--ds-admin-border) !important; color: var(--ds-admin-text) !important; }
html[data-theme="dark"] .admin-submission-show .admin-fin-table,
html[data-theme="dark"] .admin-submission-show .admin-fin-table th,
html[data-theme="dark"] .admin-submission-show .admin-fin-table td { background: var(--ds-admin-surface) !important; border-color: var(--ds-admin-border) !important; color: var(--ds-admin-text) !important; }
html[data-theme="dark"] .admin-submission-show .admin-submission-side-card,
html[data-theme="dark"] .admin-submission-show .admin-fin-cover { background: var(--ds-admin-surface) !important; }
html[data-theme="dark"] .admin-submission-show .fin-tab { background: var(--ds-admin-surface-muted) !important; border-color: var(--ds-admin-border) !important; color: var(--ds-admin-muted) !important; }
html[data-theme="dark"] .admin-submission-show .fin-tab.is-on { background: color-mix(in srgb, var(--ds-admin-primary) 18%, var(--ds-admin-surface)) !important; color: var(--ds-admin-primary) !important; }
.admin-settlement-page { margin-bottom: 1rem; }
.admin-settlement-header { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 0.6rem; margin-top: 0.4rem; }
.admin-settlement-title { margin: 0; color: var(--ds-admin-text); font-size: 1.25rem; font-weight: 800; }
.admin-settlement-subtitle { margin: 0.2rem 0 0; color: var(--ds-admin-muted); font-size: 0.8125rem; }
.admin-settlement-actions { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.admin-settlement-card { margin-bottom: 1rem; padding: 1rem; border: 1px solid var(--ds-admin-border); border-radius: 0.65rem; background: var(--ds-admin-surface); }
.admin-settlement-section-title { margin: 0 0 0.75rem; color: var(--ds-admin-text); font-size: 1rem; font-weight: 800; }
.admin-settlement-section-title.is-small { padding-bottom: 0.5rem; border-bottom: 1px solid var(--ds-admin-border); }
.admin-settlement-info-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 0.6rem; color: var(--ds-admin-text); font-size: 0.875rem; }
.admin-settlement-label { color: var(--ds-admin-muted); }
.admin-settlement-table-scroll { overflow-x: auto; }
.admin-settlement-formula-list { margin: 0; padding-left: 1.25rem; color: var(--ds-admin-muted); font-size: 0.8125rem; line-height: 1.65; }
.admin-eval-detail-header { display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; }
.admin-eval-detail-title-block { min-width: 0; }
.admin-eval-detail-title { margin: 0; color: var(--ds-admin-text); font-size: 1.25rem; font-weight: 800; }
.admin-eval-detail-meta { color: var(--ds-admin-muted); font-size: 0.8125rem; }
.admin-eval-detail-layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 1rem; margin-top: 1.5rem; }
.admin-eval-detail-card { padding: 1rem; border: 1px solid var(--ds-admin-border); border-radius: 0.65rem; background: var(--ds-admin-surface); }
.admin-eval-detail-side-card { align-self: start; }
.admin-eval-detail-section-title { margin: 0 0 1rem; padding-bottom: 0.6rem; border-bottom: 1px solid var(--ds-admin-border); color: var(--ds-admin-text); font-size: 1rem; font-weight: 800; }
.admin-eval-detail-answers { display: grid; gap: 0.8rem; }
.admin-eval-detail-answer { padding-bottom: 0.8rem; border-bottom: 1px solid var(--ds-admin-border); }
.admin-eval-detail-question { color: var(--ds-admin-muted); font-size: 0.8125rem; font-weight: 700; line-height: 1.5; }
.admin-eval-detail-answer-text { margin-top: 0.35rem; color: var(--ds-admin-text); font-size: 0.9375rem; line-height: 1.7; white-space: pre-wrap; }
.admin-eval-detail-side-title { margin: 0 0 0.75rem; color: var(--ds-admin-muted); font-size: 1rem; font-weight: 800; }
.admin-eval-detail-meta-grid { display: grid; gap: 0.8rem; color: var(--ds-admin-text); font-size: 0.875rem; }
.admin-eval-detail-label { display: block; color: var(--ds-admin-muted); font-size: 0.75rem; }
.admin-eval-detail-value { font-weight: 700; }
.admin-eval-detail-value.is-danger { color: var(--ds-admin-danger); }
@media (max-width: 800px) { .admin-eval-detail-layout { grid-template-columns: 1fr; } }
.admin-team-form-head { margin-bottom: 1rem; }
.admin-team-form-title { margin: 0; color: var(--ds-admin-text); font-size: 1.25rem; font-weight: 800; }
.admin-team-form-errors { margin-bottom: 1rem; padding: 0.8rem 1rem; border-radius: 0.5rem; background: color-mix(in srgb, var(--ds-admin-danger) 8%, var(--ds-admin-surface)); color: var(--ds-admin-danger); }
.admin-team-form-errors ul { margin: 0; padding-left: 1.25rem; }
.admin-team-form { display: flex; max-width: 760px; flex-direction: column; gap: 1rem; padding: 1rem; border: 1px solid var(--ds-admin-border); border-radius: 0.65rem; background: var(--ds-admin-surface); }
.admin-team-form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 0.8rem; }
.admin-team-form-label { display: block; margin-bottom: 0.35rem; color: var(--ds-admin-muted); font-size: 0.8125rem; font-weight: 700; }
.admin-team-form-input, .admin-team-form textarea { width: 100%; box-sizing: border-box; padding: 0.6rem 0.8rem; border: 1px solid var(--ds-admin-border); border-radius: 0.5rem; background: var(--ds-admin-surface-muted); color: var(--ds-admin-text); }
.admin-team-form textarea { resize: vertical; }
.admin-team-form-check { display: flex; align-items: center; gap: 0.5rem; margin-top: 1.6rem; color: var(--ds-admin-text); font-size: 0.875rem; }
.admin-team-form-checkbox { accent-color: var(--ds-admin-primary); }
.admin-team-form-actions { display: flex; justify-content: flex-end; gap: 0.6rem; padding-top: 0.4rem; }
.admin-eval-answer-fields { display: grid; gap: 0.8rem; }
.admin-eval-answer-card { padding: 0.8rem; border: 1px solid var(--ds-admin-border); border-radius: 0.5rem; background: var(--ds-admin-surface-muted); }
.admin-eval-answer-label { display: block; margin-bottom: 0.6rem; color: var(--ds-admin-text); font-size: 0.8125rem; font-weight: 800; line-height: 1.5; }
.admin-eval-answer-scale { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.admin-eval-answer-option { display: inline-flex; align-items: center; gap: 0.25rem; color: var(--ds-admin-text); font-size: 0.8125rem; }
.admin-eval-answer-option.is-multi { align-items: flex-start; line-height: 1.5; }
.admin-eval-answer-na { display: flex; align-items: center; gap: 0.5rem; margin-top: 0.6rem; padding: 0.6rem 0.7rem; border: 1px solid var(--ds-admin-border); border-radius: 0.45rem; background: var(--ds-admin-surface); color: var(--ds-admin-text); font-size: 0.8125rem; font-weight: 800; }
.admin-eval-answer-options { display: grid; gap: 0.375rem; }
.admin-eval-answer-input, .admin-eval-answer-textarea { width: 100%; box-sizing: border-box; padding: 0.6rem; border: 1px solid var(--ds-admin-border); border-radius: 0.375rem; background: var(--ds-admin-surface); color: var(--ds-admin-text); font-size: 0.875rem; }
.admin-eval-answer-textarea { line-height: 1.6; resize: vertical; }
.admin-submission-edit .admin-fin-main-tabs-first { margin-top: 0; }
.admin-submission-edit .fin-col-amount { text-align: right; }
.admin-submission-edit .fin-col-delete { text-align: center; }
.admin-submission-edit .fin-list-head-admin,
.admin-submission-edit .fin-row-main-admin { grid-template-columns: 8rem 6.5rem 8rem minmax(0, 1fr) 5.5rem 7.5rem 2.5rem; }
.inbound-category-dialog { width: min(40rem, calc(100vw - 1.5rem)); max-width: 40rem; margin: auto; padding: 0; border: 0; background: transparent; }
html[data-theme="dark"] .inbound-category-dialog-panel { background: var(--ds-admin-surface) !important; color: var(--ds-admin-text) !important; border-color: var(--ds-admin-border) !important; box-shadow: 0 1rem 3rem rgba(0, 0, 0, 0.35); }
html[data-theme="dark"] .inbound-category-dialog::backdrop { background: rgba(2, 6, 23, 0.72); }
html[data-theme="dark"] .inbound-category-dialog input,
html[data-theme="dark"] .inbound-category-dialog textarea { background: var(--ds-admin-surface-muted) !important; border-color: var(--ds-admin-border) !important; color: var(--ds-admin-text) !important; }
html[data-theme="dark"] .inbound-category-dialog-panel,
html[data-theme="dark"] .inbound-category-dialog .inbound-category-section,
html[data-theme="dark"] .inbound-category-dialog .inbound-radio-label,
html[data-theme="dark"] .inbound-category-dialog .org-support-steps-slot { border-color: color-mix(in srgb, var(--ds-admin-border) 55%, transparent) !important; }
.inbound-category-dialog-panel {
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: 1.15rem 1.2rem 1.05rem;
  border: 1px solid var(--ds-admin-border, #e2e8f0);
  border-radius: 0.85rem;
  background: var(--ds-admin-surface, #fff);
  color: var(--ds-admin-text, #0f172a);
  box-shadow: 0 1.25rem 2.5rem -0.75rem rgba(15, 23, 42, 0.28);
}
.inbound-category-dialog-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0 0 0.8rem;
  border-bottom: 1px solid var(--ds-admin-border, #e2e8f0);
}
.inbound-category-dialog-head h2 {
  margin: 0;
  color: var(--ds-admin-text, #0f172a);
  font-size: 1rem;
  font-weight: 800;
  line-height: 1.3;
}
.inbound-category-dialog-meta {
  margin: 0.2rem 0 0;
  color: var(--ds-admin-muted, #64748b);
  font-size: 0.75rem;
  line-height: 1.4;
}
.inbound-category-dialog-meta strong { color: var(--ds-admin-text, #0f172a); font-weight: 700; }
.inbound-category-dialog-meta-sep { margin: 0 0.2rem; color: #cbd5e1; }
.inbound-category-dialog-close { flex-shrink: 0; padding: 0.3rem 0.65rem; font-size: 0.75rem; }
.inbound-category-recommend {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.65rem 0.75rem;
  border: 1px solid color-mix(in srgb, #0284c7 28%, #e2e8f0);
  border-radius: 0.6rem;
  background: #f0f9ff;
}
.inbound-category-recommend-kicker {
  display: block;
  margin-bottom: 0.1rem;
  color: #0369a1;
  font-size: 0.65rem;
  font-weight: 700;
}
.inbound-category-recommend-copy p {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.3rem;
  margin: 0;
  color: var(--ds-admin-text, #0f172a);
  font-size: 0.8125rem;
  font-weight: 700;
}
.inbound-category-recommend-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.2rem;
  height: 1.2rem;
  border-radius: 999px;
  background: #0369a1;
  color: #fff;
  font-size: 0.65rem;
  font-weight: 800;
}
.inbound-category-recommend-detail,
.inbound-category-recommend-confidence { color: #0369a1; font-size: 0.7rem; font-weight: 600; }
.inbound-category-recommend-reason {
  margin: 0.15rem 0 0;
  color: #0369a1;
  font-size: 0.68rem;
  font-weight: 500;
  line-height: 1.35;
}
.inbound-category-recommend-action {
  flex-shrink: 0;
  padding: 0.4rem 0.75rem;
  border: 0;
  border-radius: 0.45rem;
  background: #0369a1;
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  cursor: pointer;
}
.inbound-category-dialog-form { display: flex; flex-direction: column; gap: 0.7rem; }
.inbound-category-section {
  padding: 0.8rem 0.85rem 0.85rem;
  border: 1px solid var(--ds-admin-border, #e2e8f0);
  border-radius: 0.65rem;
  background: color-mix(in srgb, var(--ds-admin-surface-muted, #f8fafc) 80%, #fff);
}
.inbound-category-section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.25rem 0.75rem;
  margin-bottom: 0.6rem;
}
.inbound-category-section-title,
.inbound-category-dialog .org-support-this-step-title {
  margin: 0;
  color: var(--ds-admin-text, #0f172a);
  font-size: 0.78rem;
  font-weight: 800;
}
.inbound-category-section-hint,
.inbound-category-dialog .org-support-this-step-hint {
  margin: 0;
  color: var(--ds-admin-muted, #64748b);
  font-size: 0.7rem;
}
.inbound-category-dialog .org-support-this-step .org-support-steps-track {
  display: grid !important;
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  gap: 0.5rem !important;
}
.inbound-category-dialog .org-support-steps-slot {
  display: flex !important;
  flex-direction: column !important;
  align-items: stretch !important;
  justify-content: space-between !important;
  gap: 0.4rem !important;
  min-height: 0;
  padding: 0.6rem 0.55rem 0.5rem !important;
  border: 1px solid var(--ds-admin-border, #e2e8f0) !important;
  border-radius: 0.5rem !important;
  background: var(--ds-admin-surface, #fff) !important;
  box-shadow: none !important;
  color: var(--ds-admin-text, #0f172a);
  cursor: pointer;
}
.inbound-category-dialog .org-support-steps-slot:hover { background: color-mix(in srgb, #0284c7 6%, #fff) !important; border-color: #7dd3fc !important; }
.inbound-category-dialog .org-support-steps-slot:has(input:checked),
.inbound-category-dialog .org-support-steps-slot.is-current {
  background: #f0f9ff !important;
  border-color: #0284c7 !important;
  box-shadow: none !important;
}
.inbound-category-dialog .org-support-steps-main {
  display: flex;
  align-items: flex-start;
  gap: 0.4rem;
  min-width: 0;
}
.inbound-category-dialog .org-support-steps-main input { margin-left: auto; flex-shrink: 0; accent-color: #0284c7; }
.inbound-category-dialog .org-support-steps-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.35rem;
  height: 1.35rem;
  border-radius: 999px;
  background: color-mix(in srgb, #0284c7 12%, #f1f5f9) !important;
  color: #0369a1 !important;
  font-size: 0.68rem;
  font-weight: 800;
}
.inbound-category-dialog .org-support-steps-slot:has(input:checked) .org-support-steps-num,
.inbound-category-dialog .org-support-steps-slot.is-current .org-support-steps-num {
  background: #0284c7 !important;
  color: #fff !important;
}
.inbound-category-dialog .org-support-steps-copy { display: block; min-width: 0; }
.inbound-category-dialog .org-support-steps-label {
  display: block;
  color: var(--ds-admin-text, #0f172a) !important;
  font-size: 0.78rem;
  font-weight: 800;
  line-height: 1.25;
  white-space: nowrap;
}
.inbound-category-dialog .org-support-steps-detail {
  display: block;
  margin-top: 0.12rem;
  color: var(--ds-admin-muted, #64748b);
  font-size: 0.65rem;
  line-height: 1.3;
  white-space: normal;
}
.inbound-category-dialog .org-support-steps-status {
  padding-top: 0.35rem;
  border-top: 1px solid color-mix(in srgb, var(--ds-admin-border, #e2e8f0) 80%, transparent);
  color: var(--ds-admin-muted, #64748b);
  font-size: 0.65rem;
  line-height: 1.2;
}
.inbound-category-dialog .org-support-steps-slot:has(input:checked) .org-support-steps-status,
.inbound-category-dialog .org-support-steps-slot.is-current .org-support-steps-status { color: #0369a1; font-weight: 700; }
.inbound-category-dialog .inbound-category-group { margin-top: 0; }
.inbound-category-dialog .inbound-radio-grid {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 0.45rem !important;
}
.inbound-category-dialog .inbound-radio-label {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  justify-content: flex-start !important;
  gap: 0.45rem !important;
  min-height: 2.35rem;
  padding: 0.45rem 0.65rem !important;
  border: 1px solid var(--ds-admin-border, #e2e8f0) !important;
  border-radius: 0.5rem !important;
  background: var(--ds-admin-surface, #fff) !important;
  text-align: left !important;
  white-space: normal !important;
  box-shadow: none !important;
}
.inbound-category-dialog .inbound-radio-label:hover { border-color: #7dd3fc !important; }
.inbound-category-dialog .inbound-radio-label:has(input:checked),
.inbound-category-dialog .inbound-radio-label.is-checked {
  background: #f0f9ff !important;
  border-color: #0284c7 !important;
  box-shadow: none !important;
}
.inbound-category-dialog .inbound-radio-text {
  min-width: 0;
  color: var(--ds-admin-text, #0f172a) !important;
  font-size: 0.75rem !important;
  font-weight: 600;
  line-height: 1.3;
  white-space: normal !important;
}
.inbound-category-dialog .inbound-radio-input { flex: 0 0 auto; width: 0.9rem !important; height: 0.9rem !important; accent-color: #0284c7; }
.inbound-category-dialog .inbound-radio-recommend {
  margin-left: auto;
  color: #0369a1;
  font-size: 0.65rem;
  font-weight: 800;
}
.inbound-category-custom { margin-top: 0.55rem; padding: 0.6rem 0.65rem; border: 1px solid #bae6fd; border-radius: 0.5rem; background: #f0f9ff; }
.inbound-category-custom label { display: block; margin-bottom: 0.3rem; color: #0c4a6e; font-size: 0.7rem; font-weight: 700; }
.inbound-category-custom input,
.inbound-category-reason {
  width: 100%;
  box-sizing: border-box;
  padding: 0.5rem 0.65rem;
  border: 1px solid var(--ds-admin-border, #cbd5e1);
  border-radius: 0.45rem;
  background: #fff;
  color: var(--ds-admin-text, #0f172a);
  font-size: 0.78rem;
}
.inbound-category-dialog-foot {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  padding-top: 0.15rem;
}
.inbound-category-dialog-actions { display: flex; justify-content: flex-end; align-items: center; gap: 0.45rem; }
.inbound-category-submit {
  padding: 0.45rem 0.95rem;
  border: 0;
  border-radius: 0.45rem;
  background: #0369a1;
  color: #fff;
  font-size: 0.78rem;
  font-weight: 800;
  cursor: pointer;
}
@media (max-width: 640px) {
  .inbound-category-dialog .org-support-this-step .org-support-steps-track,
  .inbound-category-dialog .inbound-radio-grid { grid-template-columns: 1fr 1fr !important; }
}
