:root {
  --bg: #ffffff;
  --sidebar: #1d2a4a;
  --card: #ffffff;
  --text-dark: #1b2430;
  --text-light: #6b7280;
  --accent: #3c7dff;
  --accent-soft: #e6efff;
  --border: #e1e7ef;
  --radius-lg: 18px;
  --radius-md: 12px;
  --surface-border: rgba(15, 23, 42, 0.12);
  font-family: 'Manrope', 'PingFang SC', -apple-system, BlinkMacSystemFont, sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text-dark);
  min-height: 100vh;
  overflow-y: auto;
}

.app {
  display: grid;
  grid-template-columns: 260px 1fr;
  min-height: 100vh;
  align-items: start;
}

.sidebar {
  background: #ffffff;
  color: var(--text-dark);
  padding: 32px 20px;
  display: flex;
  flex-direction: column;
  gap: 32px;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
}

.logo {
  padding: 22px 18px;
  border-radius: 26px;
  background: #ffffff;
  box-shadow: none;
  border: 1px solid rgba(15, 23, 42, 0.08);
  display: flex;
  flex-direction: column;
  gap: 14px;
  color: var(--text-dark);
}

.logo-title {
  text-align: center;
  font-size: 22px;
  letter-spacing: 1px;
  color: var(--text-dark);
}

.logo-compact {
  background: transparent;
  border: none;
  border-radius: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
  cursor: default;
}

.logo-mini-row {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.logo-phone {
  font-size: 13px;
  letter-spacing: 0.3px;
  color: var(--text-dark);
  font-weight: 600;
}

.logo-expire-text {
  font-size: 10px;
  color: rgba(15, 23, 42, 0.6);
  display: block;
}

.logo-exit-btn {
  align-self: flex-start;
  min-width: 64px;
  border-radius: 22px;
  border: 1px solid rgba(220, 53, 69, 0.45);
  background: rgba(220, 53, 69, 0.1);
  color: #b91c1c;
  font-size: 10px;
  padding: 3px 10px;
  cursor: pointer;
  transition: none;
}

.menu {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.menu-button {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  border-radius: 16px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: #ffffff;
  color: var(--text-dark);
  font-size: 15px;
  text-align: left;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
  width: 100%;
  box-shadow: none;
}

.menu-button svg {
  width: 20px;
  height: 20px;
  color: inherit;
}

.menu-button:hover {
  background: #ffffff;
  color: var(--text-dark);
}

.menu-button.active {
  background: #0f0f0f;
  color: #ffffff;
  border-color: #0f0f0f;
}

.content {
  padding: 28px 24px 48px;
  background: #ffffff;
}

.content-inner {
  max-width: 1400px;
  margin: 0;
  width: 100%;
}

.content-inner :is([class$='card'], [class$='panel'], [class$='section']) {
  background: #ffffff;
  border: 1px solid var(--surface-border);
  box-shadow: none !important;
  transition: none !important;
}

.content-inner :is([class$='card'], [class$='panel'], [class$='section']):hover {
  transform: none !important;
}

.session-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 24px;
  border-radius: 20px;
  background: #fff;
  border: 1px solid var(--surface-border);
  box-shadow: none;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.session-info {
  display: flex;
  align-items: center;
  gap: 16px;
  flex: 1 1 320px;
}

.session-avatar {
  width: 48px;
  height: 48px;
  border-radius: 16px;
  background: linear-gradient(140deg, #6366f1, #3b82f6);
  color: #fff;
  font-weight: 700;
  font-size: 18px;
  display: grid;
  place-items: center;
}

.session-meta {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.session-meta strong {
  font-size: 16px;
}

.session-status {
  font-size: 13px;
  color: var(--text-light);
  display: flex;
  align-items: center;
  gap: 6px;
}

.logo .session-status {
  color: rgba(255, 255, 255, 0.85);
  justify-content: center;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 0 4px rgba(34, 197, 94, 0.2);
  display: inline-flex;
}

.session-meta-detail {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 13px;
  color: var(--text-light);
}

.session-meta-detail span b {
  font-weight: 600;
  color: var(--text-dark);
}

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

.session-actions button {
  min-width: 120px;
}

.page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 32px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}

.page-header-info {
  min-width: 260px;
  flex: 0 0 auto;
}

.page-header h1 {
  margin: 0;
  font-size: 28px;
}

.page-header p {
  margin: 4px 0 0;
  color: var(--text-light);
}

.page-header.alerts-toolbar-inline {
  align-items: center;
}

.page-header.alerts-toolbar-inline .alerts-toolbar {
  margin: 0;
  flex: 1;
  display: flex;
  justify-content: flex-end;
}

.filters {
  display: flex;
  align-items: flex-end;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: flex-end;
  flex: 1 1 600px;
  min-width: 520px;
}

@media (max-width: 960px) {
  .filters {
    flex-wrap: wrap;
    justify-content: flex-start;
  }
}

.filters label {
  display: flex;
  flex-direction: column;
  font-size: 13px;
  color: var(--text-light);
  gap: 6px;
  line-height: 1;
}

.filters .global-filters-group {
  display: flex;
  gap: 16px;
  align-items: flex-end;
  flex-wrap: wrap;
  width: 100%;
}

.filters .report-filters-group {
  display: none;
  width: auto;
  flex-shrink: 0;
}

body.report-page-active .filters {
  justify-content: flex-end;
}

body.report-page-active .filters .global-filters-group {
  display: none;
}

body.report-page-active .filters .report-filters-group {
  display: inline-flex;
  justify-content: flex-end;
  align-items: center;
  gap: 12px;
}

.report-header-filters {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: flex-end;
  justify-content: flex-end;
}

.report-header-filters .report-filter.match-select {
  min-width: 160px;
  flex: 0 0 auto;
}

.report-header-filters .compact-select {
  flex: 0 0 100px;
  width: 100px;
}

.report-header-filters .compact-select .match-select-toggle {
  padding: 10px 14px;
}

.report-header-filters .segment {
  margin-left: 0;
  padding: 4px;
  gap: 4px;
}

.report-period-segment {
  flex-shrink: 0;
}

.report-filter {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 12px;
  color: var(--text-light);
}

.report-filter.match-select {
  min-width: 200px;
}

.report-date-filter.match-select {
  min-width: 300px;
  flex: 1 1 360px;
}

.report-header-filters .match-select-toggle {
  min-width: 0;
  padding: 10px 18px;
  white-space: nowrap;
  font-weight: 500;
}

.report-header-filters .match-select-toggle span {
  font-weight: 500;
}

.report-header-filters .report-date-toggle span {
  font-size: 15px;
  font-weight: 500;
}

.report-header-filters .segment-btn {
  padding: 6px 16px;
}

.report-header-filters .segment-btn.active {
  padding: 6px 16px;
}

.report-date-menu {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.report-calendar-panels {
  display: flex;
  gap: 16px;
}

.report-calendar-panels .calendar-panel {
  flex: 1;
}

.report-calendar-panels .calendar-panel input {
  width: 100%;
}


.date-range-single .date-range-wrap {
  position: relative;
  width: 300px;
  display: inline-flex;
}

.date-range-wrap .select-toggle {
  width: 100%;
}

.date-range-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  width: 720px;
  max-width: calc(100vw - 40px);
  border-radius: 18px;
  border: 1px solid var(--border);
  box-shadow: 0 20px 45px rgba(15, 23, 42, 0.2);
  background: #fff;
  padding: 18px 20px 22px;
  display: none;
  z-index: 25;
}

.date-range-wrap.open .date-range-dropdown {
  display: block;
}

.calendar-columns {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 18px;
}

.calendar-panel h4 {
  margin: 0 0 10px;
  font-size: 13px;
  color: var(--text-light);
}

.calendar-panel .flatpickr-calendar.inline {
  width: 320px;
  border: none;
  box-shadow: none;
  padding-bottom: 8px;
}
.calendar-panel .flatpickr-months {
  justify-content: space-between;
  align-items: center;
  padding: 0 20px;
}
.calendar-panel .flatpickr-months .flatpickr-prev-month,
.calendar-panel .flatpickr-months .flatpickr-next-month {
  position: relative;
  top: 0;
  margin: 0 6px;
}
.calendar-panel .flatpickr-current-month {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
  justify-content: center;
}

.flatpickr-months .flatpickr-month,
.flatpickr-current-month {
  width: auto;
}

.flatpickr-current-month {
  display: flex;
  align-items: center;
  gap: 10px;
  position: relative;
}

.flatpickr-current-month span.cur-month {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  min-width: 130px;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 4px 28px 4px 12px;
  background-color: #fff;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' fill='none' stroke='%236b7280' stroke-width='1.4' stroke-linecap='round'%3E%3Cpath d='M1 1.5 5 4.5 9 1.5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  background-size: 10px 6px;
  font-size: 13px;
  color: var(--text-dark) !important;
  font-weight: 600;
  cursor: pointer;
  position: relative;
}

.calendar-panel .flatpickr-monthDropdown-months {
  position: absolute;
  left: 0;
  top: 0;
  width: 130px;
  height: 34px;
  opacity: 0;
  cursor: pointer;
}


.calendar-panel .custom-year-select {
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #fff;
  padding: 4px 18px 4px 12px;
  font-size: 13px;
  color: var(--text-dark);
}

.flatpickr-current-month input.cur-year {
  width: 80px;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 4px 8px;
}

.calendar-panel .flatpickr-weekdays {
  margin-top: 6px;
}

.range-sep {
  color: var(--text-light);
  font-size: 13px;
}

.filters .select-wrapper {
  display: inline-flex;
  flex: 0 0 auto;
}

.filters .select-wrapper:not(.custom-select)::after {
  content: '';
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  width: 0;
  height: 0;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 6px solid var(--text-light);
  pointer-events: none;
}

.filters .select-wrapper select {
  width: auto;
  min-width: 140px;
  padding-right: 34px;
}

.custom-select {
  flex: 0 0 auto;
}

.select-toggle {
  width: auto;
  min-width: 140px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: #fff;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.08);
  font-size: 14px;
  color: var(--text-dark);
  cursor: pointer;
}

.select-label {
  flex: 1;
  text-align: left;
}

.select-toggle .chevron {
  width: 12px;
  height: 12px;
  color: var(--text-light);
  transition: transform 0.2s ease;
}

.custom-select.open .chevron {
  transform: rotate(180deg);
}

.select-dropdown {
  display: none;
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  min-width: 100%;
  width: fit-content;
  max-width: 260px;
  max-height: 320px;
  overflow-y: auto;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: 0 15px 30px rgba(15, 23, 42, 0.15);
  z-index: 10;
}

.custom-select.open .select-dropdown {
  display: block;
}

.select-dropdown button {
  width: 100%;
  padding: 10px 16px;
  background: transparent;
  border: none;
  text-align: left;
  font-size: 14px;
  color: var(--text-dark);
  cursor: pointer;
}

.select-dropdown button:hover,
.select-dropdown button.active {
  background: var(--accent-soft);
  color: var(--accent);
}

.month-dropdown {
  min-width: 140px;
}

.filters input,
.filters select,
.filters .select-wrapper select,
.select-toggle {
  padding: 10px 14px;
  border-radius: 12px;
  border: 1px solid var(--border);
  font-size: 14px;
  height: 46px;
  line-height: 1;
  background: #fff;
  appearance: none;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.08);
}

.filters.hidden {
  display: none;
}

.filters input[type='date'] {
  padding-right: 34px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' stroke='%236b7280' stroke-width='1.6' stroke-linecap='round'%3E%3Cpath d='M4 6l4 4 4-4'/%3E%3Cpath d='M12 10l-4 4-4-4'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 14px;
}

.filters input[type='date']::-webkit-calendar-picker-indicator {
  opacity: 0;
  cursor: pointer;
}

.calendar-panel .flatpickr-monthDropdown-months {
  min-width: 120px;
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 4px 28px 4px 12px;
  background-color: #fff;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' fill='none' stroke='%236b7280' stroke-width='1.4' stroke-linecap='round'%3E%3Cpath d='M1 1.5 5 4.5 9 1.5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  background-size: 10px 6px;
  color: var(--text-dark);
  font-weight: 600;
  font-size: 13px;
  line-height: 1.2;
  text-indent: 0;
  appearance: none;
  opacity: 1 !important;
  visibility: visible !important;
  position: static !important;
  cursor: pointer;
}

.calendar-panel .flatpickr-monthDropdown-months,
.calendar-panel .flatpickr-monthDropdown-months option {
  color: var(--text-dark) !important;
}

.calendar-panel .flatpickr-monthDropdown-months::-ms-expand {
  display: none;
}

.segment {
  display: inline-flex;
  background: var(--card);
  border-radius: 999px;
  padding: 4px;
  border: 1px solid var(--border);
  flex-shrink: 0;
}

.flatpickr-calendar {
  font-family: 'Manrope', 'PingFang SC', -apple-system, BlinkMacSystemFont, sans-serif;
  border-radius: 18px;
  box-shadow: 0 20px 35px rgba(15, 23, 42, 0.25);
  border: 1px solid var(--border);
}

.flatpickr-weekday {
  color: var(--text-light) !important;
  font-weight: 500;
}

.flatpickr-day.selected,
.flatpickr-day.startRange,
.flatpickr-day.endRange,
.flatpickr-day.selected:hover {
  background: var(--accent) !important;
  border-color: var(--accent) !important;
  color: #fff;
}

.flatpickr-day.today {
  border-color: var(--accent);
}

.segment-btn {
  border: none;
  background: transparent;
  padding: 6px 16px;
  border-radius: 999px;
  cursor: pointer;
  font-size: 13px;
  color: var(--text-light);
  transition: background 0.2s ease, color 0.2s ease;
}

.segment-btn.active {
  background: var(--accent);
  color: #fff;
}

section {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 18px;
}

.card {
  background: var(--card);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: 0 15px 40px rgba(15, 23, 42, 0.08);
  border: 1px solid rgba(226, 232, 240, 0.6);
}

.card[data-metric] {
  cursor: pointer;
}

.card.metric-active {
  border-color: #0f0f0f !important;
  background: #f5f5f5 !important;
}

.card.highlight-card {
  border-color: var(--surface-border);
  cursor: default;
  transition: none;
}

.geo-layout {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.geo-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  justify-content: flex-start;
}

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

.geo-picker-group {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.geo-filters-actions {
  display: flex;
  gap: 10px;
  margin-left: auto;
}

.geo-top-grid,
.geo-bottom-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 18px;
}

@media (max-width: 1024px) {
  .geo-top-grid,
  .geo-bottom-grid {
    grid-template-columns: 1fr;
  }
}

.geo-map-panel .geo-map-placeholder {
  border: 1px dashed #cbd5f5;
  border-radius: 18px;
  min-height: 240px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-light);
  font-size: 14px;
  margin-top: 12px;
}

.geo-map-footnote {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: var(--text-light);
  margin-top: 10px;
  gap: 12px;
}

.geo-insight-bar {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
  padding: 14px 16px;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  background: linear-gradient(90deg, #f8fafc 0%, #f1f5f9 100%);
}

.geo-insight-bar div {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.geo-insight-bar small {
  color: #94a3b8;
}

.geo-insight-bar strong {
  font-size: 20px;
  color: #0f172a;
}

.geo-insight-bar span {
  color: #94a3b8;
  font-size: 12px;
}

.geo-toggle-chips {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.geo-toggle-chips .chip {
  border: 1px solid #dbeafe;
  border-radius: 999px;
  padding: 4px 12px;
  font-size: 12px;
  background: #f8fafc;
  color: #475569;
}

.geo-toggle-chips .chip.active {
  background: #0ea5e9;
  border-color: #0ea5e9;
  color: #fff;
}

.geo-ranking {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 18px;
}

.geo-ranking h3 {
  margin: 0 0 8px;
  font-size: 14px;
}

.geo-ranking ol {
  margin: 0;
  padding-left: 16px;
  color: var(--text-dark);
  font-size: 13px;
}

.geo-distribution-panel .badge {
  margin-left: 8px;
}

.geo-distribution-top {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 14px;
}

@media (max-width: 1024px) {
  .geo-distribution-top {
    grid-template-columns: 1fr;
  }
}

.geo-toplist {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.geo-toplist-item {
  padding: 10px 12px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #f8fafc;
}

.geo-toplist-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}

.geo-toplist-meta .rank {
  width: 22px;
  height: 22px;
  border-radius: 8px;
  background: #0ea5e9;
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
}

.geo-toplist-meta strong {
  display: block;
}

.geo-toplist-meta small {
  color: #94a3b8;
}

.geo-toplist-bar {
  width: 100%;
  height: 8px;
  background: #e2e8f0;
  border-radius: 10px;
  overflow: hidden;
}

.geo-toplist-bar span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #38bdf8, #0ea5e9);
}

.geo-distribution-note {
  padding: 12px;
  border: 1px dashed #cbd5f5;
  border-radius: 12px;
  background: #f8fafc;
  color: #475569;
  font-size: 13px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.geo-distribution-note ul {
  margin: 0;
  padding-left: 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.geo-table-wrapper {
  margin-top: 14px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  overflow: hidden;
}

.geo-distribution-head {
  display: grid;
  grid-template-columns: 1.2fr 1fr 0.8fr;
  background: #f8fafc;
  color: #475569;
}

.geo-distribution-row {
  display: grid;
  grid-template-columns: 1.2fr 1fr 0.8fr;
}

.geo-distribution-row span:last-child {
  text-align: right;
}

.geo-distribution-row span:nth-child(5) {
  font-weight: 600;
}

.geo-city-panel .geo-city-metrics {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
  margin-bottom: 16px;
}

.geo-city-panel .geo-city-metrics div {
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 12px;
}

.geo-city-panel .geo-city-metrics span {
  font-size: 12px;
  color: var(--text-light);
}

.geo-city-panel .geo-city-metrics strong {
  display: block;
  margin-top: 6px;
  font-size: 18px;
}

.geo-mini-charts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
}

.geo-mini-charts .placeholder {
  min-height: 80px;
  border: 1px dashed #dbeafe;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-light);
}

.geo-merchant-table {
  margin-top: 16px;
}

.geo-name-cell {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.geo-name-cell strong {
  font-size: 14px;
  color: var(--text-dark);
}

.geo-name-cell small {
  font-size: 12px;
  color: var(--text-light);
}

.geo-gap-panel .geo-gap-note {
  margin: 6px 0 12px;
  color: var(--text-light);
  font-size: 13px;
}

.geo-gap-list,
.geo-forecast-list {
  margin: 0 0 12px;
  padding-left: 16px;
  font-size: 13px;
}

.geo-forecast-list li {
  margin-bottom: 6px;
}

.geo-forecast-list span {
  display: block;
  color: var(--text-light);
  font-size: 12px;
}

.geo-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.geo-actions button {
  flex: 1;
  min-width: 180px;
}
.card small {
  color: var(--text-light);
}

.card h3 {
  margin: 10px 0 6px;
  font-size: 24px;
}

.card .delta {
  font-size: 13px;
}

.delta.positive {
  color: #0aa56f;
}

.delta.negative {
  color: #f43f5e;
}

.delta.neutral {
  color: var(--text-light);
}

.inline-status {
  padding: 12px 16px;
  border-radius: 14px;
  background: #f1f5f9;
  font-size: 14px;
  color: var(--text-dark);
  margin-bottom: 16px;
}

.inline-status.error {
  background: #fef2f2;
  color: #b91c1c;
}

.inline-status.info {
  background: #eef2ff;
  color: #3730a3;
}

.ghost-btn,
.primary-btn {
  border-radius: 999px;
  padding: 8px 18px;
  font-size: 14px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.ghost-btn {
  border-color: var(--border);
  background: #fff;
  color: var(--text-dark);
}

.ghost-btn.danger {
  color: #b91c1c;
  border-color: rgba(185, 28, 28, 0.2);
}

.ghost-btn.xs {
  padding: 4px 10px;
  font-size: 12px;
  border-radius: 10px;
}

.primary-btn {
  background: #10b981;
  color: #fff;
}

.secondary-btn {
  border: 1px solid #cbd5f5;
  background: #e0e7ff;
  color: #1d4ed8;
  border-radius: 999px;
  padding: 12px 28px;
  font-size: 14px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.ghost-btn:hover,
.primary-btn:hover,
.secondary-btn:hover {
  transform: scale(1.03);
  box-shadow: 0 10px 18px rgba(15, 23, 42, 0.15);
}

.ghost-btn:active,
.primary-btn:active,
.secondary-btn:active {
  transform: scale(0.96);
}

.ghost-btn:disabled,
.primary-btn:disabled,
.secondary-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.pill-btn {
  border-radius: 999px;
  border: 1px solid var(--border);
  background: #f1f5f9;
  color: var(--text-dark);
  padding: 8px 18px;
  font-size: 14px;
  cursor: pointer;
}

.pill-btn.active {
  background: #1e3a8a;
  color: #fff;
  border-color: #1e3a8a;
}

.work-heading {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
  flex-wrap: wrap;
}

.work-filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

.filter-button {
  border: none;
  border-radius: 16px;
  padding: 10px 20px;
  font-size: 14px;
  color: #fff;
  background: linear-gradient(135deg, #1e3a8a, #1f2d72);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.25), 0 4px 10px rgba(15, 23, 42, 0.25);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
}

.filter-button svg {
  width: 12px;
  height: 12px;
  transition: transform 0.2s ease;
}

.work-filter-select.open .filter-button svg {
  transform: rotate(180deg);
}

.work-filter-select {
  position: relative;
}

.filter-dropdown {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  min-width: 170px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: 0 18px 35px rgba(15, 23, 42, 0.2);
  padding: 8px 0;
  display: none;
  z-index: 20;
}

.work-filter-select.open .filter-dropdown {
  display: block;
}

.filter-dropdown button {
  width: 100%;
  padding: 10px 18px;
  border: none;
  background: transparent;
  text-align: left;
  font-size: 14px;
  color: var(--text-dark);
  cursor: pointer;
}

.filter-dropdown button:hover {
  background: #f8fafc;
}

.filter-dropdown button.active {
  background: #e0e7ff;
  color: #1e3a8a;
  font-weight: 600;
}

.work-review-actions {
  display: inline-flex;
  gap: 10px;
}

.work-search-wrap {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  border-radius: 16px;
  border: 1px solid #e2e8f0;
  background: #fff;
  min-width: 260px;
}

.work-search {
  flex: 1;
  border: none;
  outline: none;
  font-size: 14px;
  background: transparent;
  color: var(--text-dark);
}

.work-search:disabled {
  cursor: not-allowed;
}

.search-icon {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.work-review {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.review-detail {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.review-detail-header {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 16px;
}

.review-detail-header h2 {
  margin: 0;
  text-align: center;
  justify-self: start;
  margin-left: 300px;
}

.back-link {
  border: none;
  background: transparent;
  color: #1d4ed8;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  justify-self: start;
}

.review-actions {
  display: inline-flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-self: end;
}

.action-btn {
  border: none;
  border-radius: 20px;
  padding: 12px 20px;
  color: #fff;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  font-weight: 600;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.action-btn:hover {
  transform: scale(1.03);
  box-shadow: 0 10px 20px rgba(15, 23, 42, 0.15);
}

.action-btn:active {
  transform: scale(0.96);
}

.action-btn.pass {
  background: #22c55e;
}

.action-btn.hold {
  background: #f59e0b;
}

.action-btn.reject {
  background: #ef4444;
}

.review-summary {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
  padding: 20px;
  background: var(--card);
  border-radius: var(--radius-lg);
}

.review-summary div {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.review-summary span {
  color: var(--text-light);
  font-size: 13px;
}

.review-summary strong {
  font-size: 18px;
  color: var(--text-dark);
}

.info-panel {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 18px;
  background: transparent;
  padding: 0;
  border: none;
}

.review-info-card {
  background: var(--card);
  border-radius: var(--radius-lg);
  border: 1px solid #e2e8f0;
  padding: 20px 22px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.review-info-card--full {
  grid-column: 1 / -1;
}

.info-section-header h3 {
  margin: 0;
  font-size: 16px;
  color: var(--text-dark);
}

.review-pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}

.review-pricing-block {
  background: #f8fbff;
  border-radius: 18px;
  border: 1px solid #e1e8f5;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.review-pricing-head span {
  font-weight: 600;
  color: #0f172a;
}

.review-slot-list,
.review-pill-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.review-slot-item,
.review-pill-item {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-radius: 16px;
  background: #ffffff;
  box-shadow: inset 0 0 0 1px #e3ebf5;
}

.review-pill-item {
  background: #f8fafc;
}

.review-slot-index {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: #dbeafe;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #1d4ed8;
  font-weight: 700;
  font-size: 14px;
}

.review-slot-meta,
.review-pill-meta {
  display: flex;
  flex-direction: column;
  line-height: 1.25;
}

.review-slot-meta strong,
.review-pill-meta strong {
  font-size: 14px;
  color: #0f172a;
}

.review-slot-meta small,
.review-pill-meta small {
  font-size: 12px;
  color: var(--text-light);
}

.slot-index {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #dbeafe;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #1d4ed8;
  font-weight: 600;
  font-size: 13px;
}

.slot-meta--inline .slot-title {
  flex: 1;
}

.slot-title {
  font-weight: 600;
}

.slot-price {
  min-width: 90px;
  text-align: right;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: #0f172a;
}

.chip {
  padding: 4px 10px;
  border-radius: 999px;
  background: #dcfce7;
  color: #15803d;
  font-size: 12px;
  font-weight: 600;
}

.facility-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.facility-chip {
  padding: 6px 14px;
  border-radius: 999px;
  background: #eff6ff;
  color: #1d4ed8;
  font-size: 13px;
  font-weight: 600;
}

.status-chip {
  display: inline-flex;
  align-items: center;
  color: #f59e0b;
  font-weight: 700;
  background: transparent !important;
  padding: 0;
}

.status-chip.status-review-pass {
  color: #16a34a;
}

.status-chip.status-review-reject {
  color: #ef4444;
}

.status-chip.status-review-hold {
  color: #f59e0b;
}

.status-chip.status-status-pending,
.status-chip.status-pending {
  color: #1d4ed8;
}

.review-section {
  background: var(--card);
  border-radius: var(--radius-lg);
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.doc-group + .doc-group {
  margin-top: 24px;
}

.review-section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.doc-group h3 {
  margin: 0 0 10px;
  font-size: 16px;
  color: var(--text-dark);
}

.review-section-header h3 {
  margin: 0;
}

.link-btn {
  border: none;
  background: transparent;
  color: #1d4ed8;
  cursor: pointer;
}

.doc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}

.doc-card {
  border: 1px dashed var(--border);
  border-radius: 16px;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 180px;
}

.doc-card.doc-item--updated {
  border-color: rgba(34, 197, 94, 0.8);
  box-shadow: 0 0 0 1px rgba(34, 197, 94, 0.25);
}

.doc-card span {
  font-weight: 600;
  text-align: center;
}

.doc-preview {
  flex: 1;
  background: #f1f5f9;
  border-radius: 12px;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
}

.doc-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 12px;
}

.doc-actions {
  display: flex;
  justify-content: space-between;
  gap: 8px;
}

.doc-actions button {
  flex: 1;
  border: none;
  border-radius: 999px;
  padding: 6px;
  background: #e2e8f0;
  color: #0f172a;
  cursor: pointer;
}

.ghost-btn.small {
  padding: 6px 12px;
  font-size: 12px;
}

.primary-btn.small {
  padding: 6px 12px;
  font-size: 12px;
}

.review-columns {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 18px;
}

.review-card {
  background: var(--card);
  border-radius: var(--radius-lg);
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.review-card h3 {
  margin: 0;
}

.review-card textarea {
  width: 100%;
  border-radius: 12px;
  border: 1px solid var(--border);
  padding: 10px;
  font-family: inherit;
}

.review-card ul {
  margin: 0;
  padding-left: 18px;
  color: var(--text-light);
}

.review-card li {
  margin-bottom: 6px;
}

.review-opinion label {
  font-size: 13px;
  color: var(--text-light);
}

.opinion-tabs {
  display: inline-flex;
  border: 1px solid var(--border);
  border-radius: 999px;
  overflow: hidden;
}

.opinion-tabs .tab {
  border: none;
  background: transparent;
  padding: 6px 16px;
  cursor: pointer;
  font-size: 13px;
}

.opinion-tabs .tab.active {
  background: #22c55e;
  color: #fff;
}

.submit-btn {
  margin-top: 8px;
}

.history-card ul {
  color: var(--text-dark);
}

.empty-copy {
  color: var(--text-light);
  font-size: 14px;
  margin: 0;
}

.review-select {
  position: relative;
}

.review-select-toggle {
  width: 100%;
  border-radius: 12px;
  border: 1px solid var(--border);
  padding: 10px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  background: #fff;
  cursor: pointer;
  font-size: 14px;
}

.review-select-toggle svg {
  width: 14px;
  height: 14px;
}

.select-icon {
  font-size: 18px;
  margin-right: 6px;
}

.review-select-dropdown {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  min-width: 100%;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: 0 15px 30px rgba(15, 23, 42, 0.15);
  display: none;
  z-index: 30;
}

.review-select-dropdown button {
  width: 100%;
  border: none;
  background: transparent;
  padding: 10px 14px;
  text-align: left;
  font-size: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
}

.review-select-dropdown button.active {
  background: rgba(37, 99, 235, 0.1);
}

.review-select.open .review-select-dropdown {
  display: block;
}

.image-modal {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.6);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.image-modal.open {
  display: flex;
}

.image-modal-content {
  background: #fff;
  padding: 14px;
  border-radius: 20px;
  max-width: 80vw;
  max-height: 80vh;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.image-modal-content img {
  max-width: 70vw;
  max-height: 70vh;
  object-fit: contain;
}

.image-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.image-modal-header p {
  margin: 0;
  font-weight: 600;
  color: #0f172a;
}

.image-modal-header .close-preview {
  align-self: center;
}

.image-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.image-modal-actions .ghost-btn {
  min-width: 90px;
}

.login-overlay {
  position: fixed;
  inset: 0;
  background: rgba(5, 7, 28, 0.6);
  backdrop-filter: blur(12px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1400;
  transition: opacity 0.2s ease;
}

.login-overlay.hidden {
  opacity: 0;
  pointer-events: none;
}

.login-card {
  width: 360px;
  max-width: 92vw;
  background: #ffffff;
  border-radius: 28px;
  padding: 36px 34px;
  box-shadow: 0 55px 120px -60px rgba(15, 23, 42, 0.45);
  display: flex;
  flex-direction: column;
  gap: 18px;
  color: #111;
}

.login-card h2 {
  margin: 0;
  font-size: 24px;
  font-weight: 600;
  color: #111;
  letter-spacing: 0.4px;
}

.login-input {
  width: 100%;
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px solid #e5e7eb;
  background: #f8f8f8;
  color: #111;
  font-size: 15px;
  transition: border 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.login-input::placeholder {
  color: #9ca3af;
}

.login-input:focus {
  outline: none;
  border-color: #0f172a;
  background: #ffffff;
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.08);
}

.login-card .code-row {
  display: flex;
  gap: 12px;
}

.login-card .code-row input {
  flex: 1;
}

.login-card .code-row button {
  width: 130px;
  border-radius: 14px;
  border: 1px solid #d4d4d8;
  background: #f3f3f4;
  color: #111;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s ease, border 0.2s ease, box-shadow 0.2s ease;
}

.login-card .code-row button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.login-ghost:hover:not(:disabled) {
  background: #ffffff;
  border-color: #c4c4cc;
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.08);
}

.login-card button.login-submit {
  border: none;
  border-radius: 20px;
  padding: 16px 0;
  margin-top: 16px;
  background: linear-gradient(135deg, #0d0d0d, #1c1c1c);
  color: #fff;
  font-weight: 600;
  font-size: 15px;
  letter-spacing: 0.5px;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  box-shadow: 0 30px 60px -32px rgba(15, 23, 42, 0.3);
}

.login-card button.login-submit:hover {
  transform: translateY(-1px);
  box-shadow: 0 40px 80px -40px rgba(0, 0, 0, 0.95);
}

.login-card button.login-submit:active {
  transform: translateY(0);
}

.login-card .login-message {
  min-height: 18px;
  font-size: 13px;
  color: #ff6b6b;
  text-align: right;
}

.close-preview {
  border: none;
  background: transparent;
  font-size: 20px;
  align-self: flex-end;
  cursor: pointer;
}

.drawer-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
  display: none;
  align-items: center;
  justify-content: flex-end;
  z-index: 1200;
}

.drawer-overlay.open {
  display: flex;
}

.drawer-overlay.match-detail-overlay {
  justify-content: flex-end;
  align-items: stretch;
  padding: 0;
}

.match-detail-drawer {
  width: min(440px, 92vw);
  height: 100vh;
  background: #fff;
  border-top-left-radius: 28px;
  border-bottom-left-radius: 28px;
  padding: 32px 30px 40px;
  box-shadow: -20px 0 45px rgba(15, 23, 42, 0.28);
  overflow-y: auto;
  animation: matchDetailSlideIn 0.28s ease forwards;
  transform: translateX(100%);
}

@keyframes matchDetailSlideIn {
  from {
    transform: translateX(100%);
  }
  to {
    transform: translateX(0);
  }
}

.match-detail-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 12px;
}

.match-detail-header h2 {
  margin: 0;
  font-size: 20px;
}

.match-detail-subtitle {
  margin: 0 0 4px;
  color: var(--text-light);
  font-size: 13px;
}

.match-detail-close {
  border: none;
  background: transparent;
  color: var(--text-light);
  font-size: 14px;
  cursor: pointer;
}

.match-detail-card {
  border-radius: 22px;
  border: 1px solid #e2e8f0;
  padding: 20px 22px;
  background: #fff;
  box-shadow: inset 0 1px 0 rgba(148, 163, 184, 0.15);
}

.match-detail-info {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.match-detail-info-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
}

.match-detail-info-row span {
  color: var(--text-light);
  min-width: 74px;
  flex-shrink: 0;
}

.match-detail-info-row strong {
  font-size: 14px;
}

.match-detail-info-row.status-row strong {
  font-weight: 600;
}

.match-detail-section {
  margin-top: 18px;
}

.match-detail-info + .match-detail-section,
.match-detail-section + .match-detail-section {
  border-top: 1px solid #f1f5f9;
  padding-top: 18px;
}

.match-detail-section h4 {
  margin: 0 0 12px;
  font-size: 15px;
}

.match-detail-timeline {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.match-detail-timeline li {
  display: flex;
  gap: 12px;
  font-size: 13px;
  color: var(--text-dark);
}

.match-detail-timeline .timeline-time {
  width: 74px;
  font-variant-numeric: tabular-nums;
  color: var(--text-light);
}

.match-detail-timeline .timeline-text {
  margin: 0;
  flex: 1;
  line-height: 1.5;
}

.match-detail-timeline li.tone-success .timeline-text {
  color: #0f9a6f;
}

.match-detail-timeline li.tone-warning .timeline-text {
  color: #b45309;
}

.match-detail-timeline li.tone-danger .timeline-text {
  color: #dc2626;
}

.match-detail-timeline li.tone-neutral .timeline-text {
  color: #475569;
}

.match-detail-teams {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 18px;
}

.match-detail-team ul {
  list-style: none;
  padding: 0;
  margin: 12px 0 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.match-detail-team li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
  color: var(--text-dark);
}

.match-queue-member-list {
  list-style: none;
  padding: 0;
  margin: 12px 0 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.match-queue-member-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
  color: var(--text-dark);
}

.match-queue-member-grid {
  list-style: none;
  padding: 0;
  margin: 12px 0 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  gap: 8px;
}

.match-queue-member-grid li {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 8px 10px;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #f8fafc;
}

.match-queue-member-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #e2e8f0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  color: #475569;
  font-weight: 600;
}

.match-queue-member-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.match-queue-member-avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.match-queue-member-avatar-fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
}

.match-queue-member-body {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.match-queue-member-name {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  margin: 0;
  color: var(--text-dark);
}

.match-queue-member-name strong {
  font-weight: 600;
}

.match-queue-member-rank {
  font-size: 12px;
  color: var(--text-light);
}

.match-queue-member-meta,
.match-queue-member-region {
  margin: 0;
  font-size: 12px;
  color: var(--text-light);
  line-height: 1.3;
}

.match-queue-member-avatar .user-avatar {
  width: 36px;
  height: 36px;
}

.match-queue-member-gender {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 2px 6px;
  font-size: 11px;
  border-radius: 10px;
  background: #eef2ff;
  color: #4338ca;
}

.match-queue-member-gender.gender-male {
  background: #e0f2fe;
  color: #0369a1;
}

.match-queue-member-gender.gender-female {
  background: #fef2f2;
  color: #b91c1c;
}

.match-queue-member-role {
  display: inline-flex;
  align-items: center;
  padding: 2px 6px;
  background: #f1f5f9;
  border-radius: 10px;
  font-size: 11px;
  color: #475569;
}

.match-detail-team-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 14px;
}

.match-detail-delta {
  font-weight: 600;
}

.match-detail-delta.positive {
  color: #059669;
}

.match-detail-delta.negative {
  color: #dc2626;
}

.match-detail-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.match-detail-actions h4 {
  margin-bottom: 6px;
}

.match-detail-action-btn {
  width: 100%;
  border-radius: 999px;
  border: none;
  padding: 12px 0;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.match-detail-action-btn:active {
  transform: scale(0.98);
}

.match-detail-action-btn.action-success {
  background: #10b981;
  color: #fff;
}

.match-detail-action-btn.action-warning {
  background: #fcd34d;
  color: #1f2937;
}

.match-detail-action-btn.action-danger {
  background: #ef4444;
  color: #fff;
}

.room-detail-card {
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: 24px 26px;
}

.room-detail-overview {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

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

@media (max-width: 900px) {
  .room-detail-meta-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 600px) {
  .room-detail-meta-grid {
    grid-template-columns: repeat(1, minmax(0, 1fr));
  }
}

.room-detail-meta-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 13px;
}

.room-detail-meta-item span {
  color: var(--text-light);
  font-size: 12px;
}

.room-detail-meta-item strong {
  font-size: 15px;
  color: var(--text-dark);
}

.room-detail-meta-item.status-item .status-pill {
  font-size: 12px;
}

.room-location-block {
  border: 1px dashed #e2e8f0;
  border-radius: 18px;
  padding: 16px 20px;
  background: #f8fafc;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.room-location-name {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
  color: var(--text-dark);
}

.room-location-row {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 12px;
  color: var(--text-light);
}

.room-location-row strong {
  font-size: 15px;
  color: var(--text-dark);
}

.room-location-row p {
  margin: 0;
  color: var(--text-dark);
  line-height: 1.4;
}

.room-detail-section {
  padding-top: 4px;
}

.room-detail-section + .room-detail-section {
  border-top: 1px solid #f1f5f9;
  padding-top: 20px;
}

.room-section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.room-section-head h4 {
  margin: 0;
  font-size: 15px;
}

.room-section-note {
  font-size: 12px;
  color: var(--text-light);
}

.room-player-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}

.room-player-card {
  border: 1px solid #e2e8f0;
  border-radius: 18px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  background: #fff;
  box-shadow: inset 0 1px 0 rgba(148, 163, 184, 0.12);
}

.room-player-head {
  display: flex;
  gap: 12px;
}

.room-player-name {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  font-size: 15px;
}

.room-player-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.room-player-tag {
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(59, 130, 246, 0.12);
  color: #2563eb;
}

.room-player-account,
.room-player-region,
.room-player-time {
  margin: 0;
  font-size: 12px;
  color: var(--text-light);
}

.room-player-region {
  color: #475569;
}

.room-player-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.room-player-stats div {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.room-player-stats span {
  font-size: 11px;
  color: var(--text-light);
}

.room-player-stats strong {
  font-size: 15px;
}

.room-player-login {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  color: var(--text-light);
}

.room-player-login strong {
  font-size: 13px;
  color: var(--text-dark);
}

.room-player-checkin {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  color: var(--text-light);
}

.room-player-checkin-pill {
  border-radius: 999px;
  padding: 2px 10px;
  font-size: 12px;
  font-weight: 600;
}

.room-player-checkin-pill.checkin-yes {
  background: rgba(34, 197, 94, 0.18);
  color: #15803d;
}

.room-player-checkin-pill.checkin-no {
  background: rgba(248, 113, 113, 0.18);
  color: #b91c1c;
}

.room-player-checkin-pill.checkin-unknown {
  background: rgba(148, 163, 184, 0.2);
  color: #475569;
}

.room-player-time {
  font-size: 12px;
  color: #475569;
}

.room-record-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.room-record-card {
  border: 1px solid #e2e8f0;
  border-radius: 18px;
  padding: 16px;
  background: #fff;
  box-shadow: inset 0 1px 0 rgba(148, 163, 184, 0.12);
}

.room-record-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.room-record-round {
  font-weight: 600;
  font-size: 14px;
  color: var(--text-dark);
}

.room-record-time {
  display: block;
  font-size: 12px;
  color: var(--text-light);
}

.room-record-status {
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
}

.room-record-status-success {
  background: rgba(16, 185, 129, 0.18);
  color: #047857;
}

.room-record-status-pending {
  background: rgba(251, 191, 36, 0.25);
  color: #92400e;
}

.room-record-status-danger {
  background: rgba(248, 113, 113, 0.23);
  color: #b91c1c;
}

.room-record-status-neutral {
  background: rgba(148, 163, 184, 0.2);
  color: #475569;
}

.room-record-score {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}

.room-record-team-label {
  margin: 0 0 4px;
  font-size: 12px;
  color: var(--text-light);
}

.room-record-team-names {
  margin: 0;
  font-size: 13px;
  color: var(--text-dark);
  line-height: 1.4;
}

.room-record-score-value {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 26px;
  font-weight: 700;
  color: var(--text-dark);
}

.room-record-score-sep {
  font-size: 20px;
  color: var(--text-light);
}

.room-record-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-size: 12px;
  color: var(--text-light);
}

.room-record-result {
  font-weight: 600;
  font-size: 13px;
}

.room-record-result.result-win {
  color: #059669;
}

.room-record-result.result-lose {
  color: #dc2626;
}

.room-record-result.result-crush {
  color: #2563eb;
}

.room-record-result.result-miserable {
  color: #b91c1c;
}

.room-record-result.result-dispute {
  color: #f97316;
}

.room-record-result.result-pending,
.room-record-result.result-neutral {
  color: #475569;
}

.room-record-submit {
  font-size: 12px;
  color: var(--text-light);
}

.match-dialog-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1305;
  padding: 16px;
}

.match-dialog-overlay.open {
  display: flex;
}

.match-dialog {
  width: min(420px, 90vw);
  background: #fff;
  border-radius: 24px;
  padding: 22px 24px 26px;
  box-shadow: 0 35px 60px rgba(15, 23, 42, 0.3);
}

.match-dialog-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 12px;
}

.match-dialog-header h3 {
  margin: 0;
  font-size: 18px;
}

.match-dialog-subtitle {
  margin: 0 0 4px;
  color: var(--text-light);
  font-size: 13px;
}

.match-dialog-close {
  border: none;
  background: transparent;
  font-size: 20px;
  color: var(--text-light);
  cursor: pointer;
}

.match-dialog-copy {
  margin: 0 0 16px;
  color: var(--text-dark);
  line-height: 1.5;
  font-size: 14px;
}

.match-dialog-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 14px;
  font-size: 13px;
  color: var(--text-light);
}

.match-dialog-field input,
.match-dialog-field textarea {
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 10px 12px;
  font-size: 14px;
  font-family: inherit;
  color: var(--text-dark);
  background: #fff;
}

.match-dialog-field textarea {
  resize: vertical;
  min-height: 80px;
}

.match-dialog-field .match-select {
  min-width: 0;
  width: 100%;
}

.match-dialog-field .match-select .match-select-toggle {
  width: 100%;
}

.match-dialog-field .match-select .match-select-options {
  width: 100%;
}

.match-dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  margin-top: 18px;
}

.match-dialog-actions button {
  min-width: 110px;
  border-radius: 999px;
  border: none;
  padding: 10px 18px;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
}

.match-dialog-actions button.primary {
  background: #10b981;
  color: #fff;
}

.match-dialog-actions button.warning {
  background: #fcd34d;
  color: #1f2937;
}

.match-dialog-actions button.danger {
  background: #ef4444;
  color: #fff;
}

.match-dialog-actions button.ghost {
  background: #f8fafc;
  color: #475569;
  border: 1px solid #e2e8f0;
}
.refund-drawer {
  width: min(480px, 90vw);
  height: 100vh;
  background: #fff;
  padding: 24px;
  box-shadow: -8px 0 30px rgba(15, 23, 42, 0.2);
  overflow-y: auto;
}

.drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
}

.drawer-header h3 {
  margin: 0 0 6px;
}

.icon-btn {
  border: none;
  background: transparent;
  font-size: 24px;
  cursor: pointer;
}

.drawer-body {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.drawer-summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  padding: 16px;
  border: 1px solid #e5e7eb;
  border-radius: 16px;
  background: #f8fafc;
}

.drawer-summary span {
  color: var(--text-light);
  font-size: 12px;
}

.drawer-summary strong {
  display: block;
  font-size: 15px;
}

.drawer-section textarea {
  width: 100%;
  border: 1px solid #e5e7eb;
  border-radius: 16px;
  padding: 12px;
  background: #f8fafc;
  font-family: inherit;
  resize: vertical;
}

.drawer-section h4 {
  margin: 0 0 6px;
}

.system-extra {
  border: 1px solid #e5e7eb;
  border-radius: 16px;
  padding: 16px;
  background: #fff;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.drawer-copy {
  margin: 0;
  color: var(--text-light);
  line-height: 1.5;
}

.system-metric-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 10px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.system-metric-list li {
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 10px 12px;
  background: #f8fafc;
}

.system-metric-list span {
  display: block;
  font-size: 12px;
  color: var(--text-light);
}

.system-metric-list strong {
  display: block;
  font-size: 16px;
  margin-top: 6px;
  color: var(--text-dark);
}

.system-actions {
  border: 1px dashed #cbd5f5;
  border-radius: 12px;
  padding: 12px 16px;
  background: #f8fafc;
}

.system-actions span {
  font-size: 13px;
  color: var(--text-light);
}

.system-actions ol {
  margin: 8px 0 0 18px;
  color: var(--text-dark);
}

.system-actions li + li {
  margin-top: 4px;
}

.order-finance {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.order-metric-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
}

.order-metric-card {
  background: var(--card);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: 0 15px 40px rgba(15, 23, 42, 0.08);
  border: 1px solid rgba(226, 232, 240, 0.6);
}

.order-metric-card small {
  color: var(--text-light);
}

.order-metric-card h3 {
  margin: 10px 0 6px;
  font-size: 24px;
}

.order-metric-card .delta {
  margin: 0;
  font-size: 13px;
}

.order-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

.order-search {
  flex: 1;
  min-width: 220px;
  border: 1px solid #dbeafe;
  border-radius: 999px;
  padding: 14px 24px;
  display: flex;
  align-items: center;
  gap: 12px;
  background: #fff;
  min-height: 54px;
}

.order-search input {
  border: none;
  outline: none;
  flex: 1;
  font-size: 16px;
}

.order-search .order-search-icon {
  width: 20px;
  height: 20px;
  color: #64748b;
}

.order-filter-select {
  position: relative;
}

.order-filter-btn {
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  padding: 8px 16px;
  background: #fff;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.order-filter-btn:hover {
  transform: scale(1.03);
  box-shadow: 0 10px 18px rgba(15, 23, 42, 0.15);
}

.order-filter-btn:active {
  transform: scale(0.96);
}

.order-filter-dropdown {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  min-width: 140px;
  background: #fff;
  border-radius: 16px;
  border: 1px solid rgba(148, 163, 184, 0.4);
  box-shadow: 0 15px 35px rgba(15, 23, 42, 0.18);
  padding: 6px;
  display: none;
  z-index: 5;
}

.order-filter-select.open .order-filter-dropdown {
  display: block;
}

.order-filter-dropdown button {
  width: 100%;
  text-align: left;
  padding: 8px 12px;
  border-radius: 12px;
  border: none;
  background: transparent;
  cursor: pointer;
  font-size: 13px;
}

.order-filter-dropdown button:hover {
  background: #f1f5f9;
}

.order-filter-dropdown button.active {
  background: #e0f2fe;
  color: #0369a1;
  font-weight: 600;
}

.order-panel {
  padding: 0;
}

.order-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  min-width: 960px;
}

.order-table th,
.order-table td {
  padding: 14px 18px;
  border-bottom: 1px solid #edf2f7;
  text-align: left;
  white-space: nowrap;
}

.order-table th {
  color: var(--text-light);
  font-weight: 500;
  background: #f8fafc;
}

.order-table tbody tr:hover {
  background: #f1f5f9;
}

.order-status {
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
}

.order-status-paid {
  background: #dcfce7;
  color: #15803d;
}

.order-status-refunding {
  background: #fef3c7;
  color: #b45309;
}

.order-status-pending {
  background: #fee2e2;
  color: #b91c1c;
}

.order-status-refunded {
  background: #e0e7ff;
  color: #4338ca;
}

.order-status-cancelled {
  background: #f1f5f9;
  color: #475569;
}

.order-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
}

.order-footer .pagination {
  display: flex;
  align-items: center;
  gap: 8px;
}

.order-footer .pill-btn {
  border-radius: 999px;
  border: 1px solid #dbeafe;
  background: #fff;
  padding: 6px 14px;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.order-footer .pill-btn:hover {
  transform: scale(1.05);
  box-shadow: 0 6px 12px rgba(15, 23, 42, 0.15);
}

.order-footer .pill-btn.active {
  background: #2563eb;
  color: #fff;
  border-color: #2563eb;
}

.table-preview-bar {
  padding: 4px 20px 12px;
}

.table-preview-bar.hidden {
  display: none;
}

.table-preview-bar input[type='range'] {
  width: 100%;
  accent-color: #2563eb;
}

.user-list-panel .panel-header {
  align-items: center;
  gap: 16px;
}

.user-list-panel {
  min-height: 520px;
}

.user-search-bar {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  padding: 8px 16px;
  background: #fff;
}

.user-search-bar svg {
  width: 18px;
  height: 18px;
  color: #94a3b8;
  flex-shrink: 0;
}

.user-search-bar input {
  border: none;
  outline: none;
  font-size: 14px;
  width: 240px;
  line-height: 20px;
  background: transparent;
}

.user-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.user-status-filter {
  position: relative;
}

.user-status-btn {
  min-width: 140px;
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
}

.user-status-filter svg {
  width: 10px;
  height: 6px;
  margin-left: 6px;
}

.user-status-dropdown {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  background: #fff;
  border: 1px solid rgba(148, 163, 184, 0.4);
  border-radius: 12px;
  box-shadow: 0 15px 30px rgba(15, 23, 42, 0.15);
  padding: 6px;
  display: none;
  min-width: 140px;
  z-index: 10;
}

.user-status-filter.open .user-status-dropdown {
  display: block;
}

.user-status-dropdown button {
  width: 100%;
  padding: 8px 12px;
  border-radius: 10px;
  border: none;
  background: transparent;
  text-align: left;
  font-size: 13px;
  cursor: pointer;
}

.user-status-dropdown button.active,
.user-status-dropdown button:hover {
  background: #e0f2fe;
  color: #0369a1;
  font-weight: 600;
}

.user-table .table-row span:nth-child(10) {
  font-weight: 600;
}

.user-table .table-row {
  display: grid;
  grid-template-columns: 1.5fr 1fr 0.9fr 0.9fr 1.1fr 0.9fr 0.8fr 0.6fr 0.7fr 0.8fr;
  gap: 10px;
  align-items: center;
}

.user-table {
  min-width: 1100px;
}

.user-table-scroll {
  overflow-x: auto;
  padding-bottom: 6px;
}

.user-table .table-row span {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.user-table .table-row span.user-cell,
.user-cell.user-info {
  overflow: visible;
}

.user-table .table-row {
  overflow: visible;
}

.user-table .table-row span:nth-child(5) {
  white-space: normal;
  overflow: visible;
}

.user-table .table-row span strong {
  display: block;
  font-size: 14px;
}

.user-table .table-row span small {
  display: block;
  font-size: 11px;
  color: var(--text-light);
}

.user-cell.user-info {
  display: flex;
  align-items: center;
  gap: 12px;
  justify-content: flex-start;
}

.user-info .user-meta {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
  align-items: flex-start;
  min-width: 0;
  gap: 2px;
}

.user-info .user-meta strong,
.user-info .user-meta small {
  display: block;
  text-align: left;
  width: 100%;
}

.user-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: #e2e8f0;
  color: #475569;
  font-weight: 600;
  flex-shrink: 0;
  overflow: visible;
  position: relative;
}

.user-avatar.user-avatar-with-gender {
  overflow: visible;
}

.user-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: 50%;
  position: relative;
  z-index: 1;
}

.user-avatar-sm {
  width: 36px;
  height: 36px;
  font-size: 14px;
}

.user-avatar-md {
  width: 44px;
  height: 44px;
  font-size: 16px;
}

.user-avatar-lg {
  width: 56px;
  height: 56px;
  font-size: 18px;
}

.user-avatar-fallback {
  background: #e2e8f0;
}

.user-avatar-clickable {
  cursor: zoom-in;
  border: none;
}

.user-avatar-clickable:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.user-avatar-gender {
  position: absolute;
  right: 0;
  bottom: 0;
  transform: translate(35%, 35%);
  width: 16px;
  height: 16px;
  border-radius: 50%;
  font-size: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  box-shadow: 0 8px 16px rgba(15, 23, 42, 0.35);
  border: 2px solid #fff;
  pointer-events: none;
  z-index: 2;
}

.user-avatar-sm .user-avatar-gender {
  width: 14px;
  height: 14px;
  font-size: 8px;
}

.user-avatar-md .user-avatar-gender {
  width: 17px;
  height: 17px;
  font-size: 9px;
}

.user-avatar-lg .user-avatar-gender {
  width: 20px;
  height: 20px;
  font-size: 11px;
}

.user-avatar-gender-male {
  background: #3b82f6;
}

.user-avatar-gender-female {
  background: #ec4899;
}

.avatar-preview-layer {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 2000;
}

.avatar-preview-layer.visible {
  display: flex;
}

.avatar-preview-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.6);
}

.avatar-preview-content {
  position: relative;
  background: #fff;
  border-radius: 18px;
  padding: 24px;
  box-shadow: 0 20px 60px rgba(15, 23, 42, 0.35);
  display: flex;
  flex-direction: column;
  gap: 16px;
  align-items: center;
  max-width: 90vw;
  max-height: 90vh;
  z-index: 1;
}

.avatar-preview-content img {
  max-width: 70vw;
  max-height: 70vh;
  border-radius: 16px;
  object-fit: cover;
}

.avatar-preview-close {
  align-self: flex-end;
}

.user-table .table-row.table-header {
  font-weight: 600;
  color: var(--text-light);
}

.user-table .user-row {
  cursor: pointer;
}

.user-table .table-row span:last-child {
  justify-self: end;
}

.align-right {
  text-align: right;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
}

.status-pill.status-approved {
  background: rgba(37, 99, 235, 0.14);
  color: #1d4ed8;
}

.status-pill.status-review {
  background: rgba(249, 115, 22, 0.18);
  color: #b45309;
}

.status-pill.status-rejected {
  background: rgba(244, 63, 94, 0.2);
  color: #be123c;
}

.status-pill.status-banned {
  background: rgba(239, 68, 68, 0.2);
  color: #b91c1c;
}

.status-pill.status-open {
  background: rgba(34, 197, 94, 0.18);
  color: #15803d;
}

.status-pill.status-rest {
  background: rgba(239, 68, 68, 0.18);
  color: #b91c1c;
}

.status-open-text {
  color: #15803d;
  font-weight: 600;
}

.status-rest-text {
  color: #b91c1c;
  font-weight: 600;
}

.status-pill.status-normal {
  background: rgba(59, 130, 246, 0.15);
  color: #1d4ed8;
}

.status-pill.status-success {
  background: rgba(16, 185, 129, 0.18);
  color: #047857;
}

.status-pill.status-warning {
  background: rgba(251, 191, 36, 0.2);
  color: #92400e;
}

.status-pill.status-danger {
  background: rgba(239, 68, 68, 0.2);
  color: #b91c1c;
}

.status-pill.status-observe {
  background: rgba(248, 250, 252, 1);
  border: 1px dashed #94a3b8;
  color: #475569;
}

.status-pill.status-risk {
  background: rgba(249, 115, 22, 0.15);
  color: #b45309;
}

.status-pill.status-blocked {
  background: rgba(239, 68, 68, 0.18);
  color: #b91c1c;
}

.status-pill.status-neutral {
  background: rgba(226, 232, 240, 0.8);
  color: #475569;
}

.status-pill.status-live {
  background: rgba(16, 185, 129, 0.18);
  color: #047857;
}

.status-pill.status-pending {
  background: rgba(251, 191, 36, 0.2);
  color: #b45309;
}


.user-table-footer {
  margin-top: 12px;
  font-size: 13px;
  color: var(--text-light);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.user-table-footer .pagination {
  display: flex;
  gap: 6px;
  align-items: center;
}

.user-table-footer .pagination .ghost-btn,
.user-table-footer .pagination .pill-btn {
  min-width: 60px;
}

.user-drawer {
  width: min(420px, 90vw);
  height: 100vh;
  background: #fff;
  padding: 26px;
  box-shadow: -8px 0 30px rgba(15, 23, 42, 0.2);
  overflow-y: auto;
}

.user-drawer-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  padding-right: 8px;
  padding-top: 8px;
  margin-bottom: 12px;
}

.user-header-text small {
  color: var(--text-light);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.user-header-text h2 {
  margin: 4px 0 4px;
  font-size: 24px;
}

.user-header-text p {
  margin: 0 0 12px;
  color: var(--text-light);
  font-size: 13px;
}

.drawer-section-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}

.drawer-card {
  border: 1px solid #e5e7eb;
  border-radius: 18px;
  padding: 16px;
  background: #f8fafc;
}

.drawer-card h3 {
  margin: 0 0 12px;
  font-size: 15px;
}

.drawer-highlight {
  background: #fff;
  border: 1px solid #dbeafe;
  box-shadow: inset 0 0 0 1px rgba(59, 130, 246, 0.08);
}

.drawer-stat-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 12px;
}

.drawer-stat {
  background: #f1f5f9;
  border-radius: 12px;
  padding: 10px 12px;
}

.drawer-stat span {
  display: block;
  color: var(--text-light);
  font-size: 12px;
}

.drawer-stat strong {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
  font-size: 18px;
  color: #0f172a;
}

.drawer-stat strong small {
  font-size: 12px;
  color: var(--text-light);
}

.merchant-drawer {
  width: min(420px, 90vw);
  height: 100vh;
  background: #fff;
  padding: 26px;
  box-shadow: -8px 0 30px rgba(15, 23, 42, 0.2);
  overflow-y: auto;
}

.merchant-drawer-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 16px;
}

.merchant-drawer-header small {
  color: var(--text-light);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.merchant-drawer-header h2 {
  margin: 4px 0 4px;
}

.merchant-metric-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 12px;
}

.merchant-metric-grid span {
  display: block;
  font-size: 12px;
  color: var(--text-light);
}

.merchant-metric-grid strong {
  font-size: 18px;
  color: #0f172a;
}

.merchant-metric-grid strong small {
  font-size: 11px;
  color: var(--text-light);
}

.mini-chart {
  margin-top: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.mini-chart canvas {
  width: 100% !important;
  height: 180px !important;
}

.merchant-slot-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.slot-item {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
}

.merchant-docs {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin: 10px 0;
}

.merchant-docs span {
  padding: 6px 14px;
  border-radius: 12px;
  background: #e2e8f0;
  font-size: 13px;
}

.merchant-risk-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.merchant-detail-page {
  display: flex;
  flex-direction: column;
  gap: 20px;
  background: #f5f5f8;
  padding: 20px;
  border-radius: 24px;
}

.merchant-detail-page.merchant-detail-compact {
  gap: 24px;
}

.merchant-detail-loading .merchant-header-info h1 {
  margin: 0;
  font-size: 24px;
}

.merchant-detail-loading .merchant-header-info p {
  margin: 0;
  color: #475569;
  font-size: 14px;
}

.merchant-detail-loading .merchant-detail-layout {
  opacity: 0.95;
}

.merchant-skeleton {
  position: relative;
  display: block;
  width: 100%;
  height: 14px;
  border-radius: 999px;
  background: #e2e8f0;
  overflow: hidden;
}

.merchant-skeleton::after {
  content: '';
  position: absolute;
  inset: 0;
  width: 45%;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.9) 50%, rgba(255, 255, 255, 0) 100%);
  transform: translateX(-100%);
  animation: merchantSkeletonShimmer 1.2s linear infinite;
}

.merchant-skeleton.skeleton-title {
  height: 28px;
  max-width: 280px;
}

.merchant-skeleton.skeleton-subtitle {
  height: 16px;
  max-width: 220px;
  margin-top: 8px;
}

.merchant-detail-loading .skeleton-card {
  min-height: 120px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.merchant-skeleton.skeleton-line-1 {
  max-width: 70%;
}

.merchant-skeleton.skeleton-line-2 {
  max-width: 55%;
}

.merchant-skeleton.skeleton-chart-bar {
  height: 110px;
  border-radius: 18px;
}

.merchant-skeleton.skeleton-chart-bar.short {
  height: 70px;
  width: 70%;
}

@keyframes merchantSkeletonShimmer {
  0% {
    transform: translateX(-100%);
  }
  100% {
    transform: translateX(100%);
  }
}

.merchant-detail-header {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.merchant-title-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.merchant-header-info h1 {
  margin: 0;
  font-size: 26px;
}

.merchant-header-info p {
  margin: 0;
  color: var(--text-light);
  font-size: 14px;
}

.merchant-enterprise {
  margin: 2px 0 10px;
  color: #64748b;
}

.merchant-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 12px;
  color: #64748b;
}

.merchant-back-btn {
  align-self: flex-start;
}

.merchant-back-btn.primary {
  color: #2563eb;
  border-radius: 999px;
  padding: 6px 16px;
  border: 1px solid rgba(37, 99, 235, 0.2);
  font-weight: 500;
}

.merchant-detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(280px, 1fr);
  gap: 16px;
}

.merchant-detail-main,
.merchant-detail-aside {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.merchant-detail-aside {
  position: sticky;
  top: 24px;
  align-self: flex-start;
}
.merchant-meta span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.merchant-quick-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 12px;
  margin-top: 12px;
}

.merchant-range-tabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin: 4px 0 10px;
}

.merchant-range-btn {
  border: 1px solid #e2e8f0;
  background: #fff;
  border-radius: 999px;
  padding: 4px 12px;
  font-size: 12px;
  color: #475569;
  cursor: pointer;
  transition: all 0.2s ease;
}

.merchant-range-btn.active {
  background: #1d4ed8;
  border-color: #1d4ed8;
  color: #fff;
}

.merchant-range-btn:hover {
  border-color: #94a3b8;
}

.quick-stat {
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  background: #f8fafc;
}

.quick-stat-label {
  font-size: 12px;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.quick-stat-value {
  font-size: 22px;
  color: #0f172a;
  line-height: 1.2;
}

.quick-stat small {
  color: #94a3b8;
  font-size: 12px;
}

.mini-chart-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: #94a3b8;
}

.compact-chart canvas {
  height: 206px !important;
}

.merchant-card {
  border: 1px solid #e2e8f0;
  border-radius: 18px;
  padding: 18px;
  background: #fff;
}

.merchant-card h3 {
  margin: 2px 0 8px;
}

.merchant-card h4 {
  margin: 0 0 6px;
}

.highlight-card.merchant-card {
  background: #fff;
  border-color: #dbeafe;
  box-shadow: 0 20px 45px rgba(15, 23, 42, 0.05);
}

.doc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 16px;
  margin-top: 12px;
}

.doc-item {
  border-radius: 12px;
  padding: 10px;
  color: #1f2937;
  display: flex;
  flex-direction: column;
  gap: 8px;
  background: #f1f5f9;
  cursor: pointer;
  transition: box-shadow 0.25s ease;
}

.doc-item--updated {
  box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.35);
}

.doc-item img[data-doc-preview] {
  cursor: zoom-in;
}

.doc-item img {
  width: 100%;
  aspect-ratio: 5 / 4;
  object-fit: cover;
  border-radius: 10px;
  display: block;
}

.doc-title {
  font-weight: 600;
  font-size: 14px;
}

.doc-actions {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.empty-hint {
  border: 1px dashed #e2e8f0;
  border-radius: 12px;
  padding: 20px;
  text-align: center;
  font-size: 13px;
  color: #94a3b8;
  background: #fff;
}

.empty-text {
  color: #94a3b8;
}

.photo-card {
  background: #fff;
}

.merchant-orders-card .merchant-orders-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.orders-subtitle {
  margin: 4px 0 0;
  color: #94a3b8;
  font-size: 12px;
}

.orders-meta {
  display: flex;
  align-items: center;
  gap: 8px;
}

.orders-loading {
  font-size: 12px;
  color: #64748b;
}

.merchant-order-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.merchant-order-card {
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 16px 20px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.05);
}

.order-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.order-card-id {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.order-card-id span {
  font-size: 12px;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.order-card-id strong {
  font-size: 16px;
  color: #0f172a;
}

.order-card-id small {
  color: #94a3b8;
  font-size: 12px;
}

.order-card-head .order-status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.order-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
  margin-top: 16px;
}

.order-card-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.order-card-label {
  font-size: 12px;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.order-card-value {
  font-size: 15px;
  font-weight: 600;
  color: #0f172a;
}

.order-card-item small {
  font-size: 12px;
  color: #94a3b8;
}

.order-card-amount {
  text-align: right;
  align-items: flex-end;
}

.order-card-primary {
  font-size: 20px;
  color: #0f172a;
}

.merchant-order-empty-card {
  border: 1px dashed #cbd5f5;
  border-radius: 12px;
  padding: 24px 12px;
  text-align: center;
  color: #94a3b8;
  background: #f8fafc;
}

.merchant-order-empty-card span {
  font-size: 14px;
}

.merchant-order-empty-card.error {
  border-color: #fecaca;
  color: #dc2626;
  background: #fff5f5;
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
}

.pricing-group {
  background: #f8fafc;
  border-radius: 14px;
  padding: 12px 14px;
  height: 100%;
}

.pricing-group h4 {
  margin: 0;
  font-size: 14px;
}

.pricing-group ul {
  list-style: none;
  padding: 0;
  margin: 10px 0 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.pricing-group li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 12px;
  padding: 8px 10px;
  border-radius: 10px;
  background: #fff;
  box-shadow: inset 0 0 0 1px #e2e8f0;
}

.pricing-group li span:nth-child(2) {
  flex: 1;
}

.pricing-group li strong {
  min-width: 64px;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.pricing-group li .chip {
  align-self: center;
}

.pricing-group .slot-index {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #e2e8f0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 600;
  color: #475569;
}

.merchant-detail-split {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
}

.info-list {
  list-style: none;
  padding: 0;
  margin: 10px 0 0;
}

.info-list.compact {
  margin-top: 6px;
}

.info-list.compact li {
  padding: 4px 0;
  margin-bottom: 2px;
}

.info-list li {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  margin-bottom: 6px;
  padding: 6px 0;
  border-bottom: 1px solid #e2e8f0;
}

.info-list li:last-child {
  border-bottom: none;
}

.info-list li span:first-child {
  flex: 1;
}

.info-list li strong {
  min-width: 120px;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  text-align: right;
  gap: 4px;
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
}

.info-list li strong .chip {
  align-self: flex-end;
  white-space: nowrap;
}

.info-list .empty-text {
  display: block;
  color: #94a3b8;
  font-weight: 400;
  padding: 6px 0;
}

.divider-row {
  display: flex;
  justify-content: space-between;
  padding: 6px 0;
  border-bottom: 1px solid #e2e8f0;
  font-size: 14px;
}

.divider-row:last-child {
  border-bottom: none;
}

.divider-row strong {
  font-weight: 600;
  color: #0f172a;
  font-size: 16px;
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
  margin: 12px 0 0;
}

.info-grid-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.info-grid-item dt {
  margin: 0;
  font-size: 12px;
  color: #94a3b8;
}

.info-grid-item dd {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  color: #0f172a;
}

.admin-list h4 {
  margin: 16px 0 8px;
  font-size: 13px;
  color: #475569;
}

.merchant-review-card {
  border-color: #bfdbfe;
  background: #f8fbff;
}

.merchant-review-tip {
  margin: 8px 0 16px;
  font-size: 13px;
  color: #475569;
}

.merchant-review-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.merchant-action-btn {
  border-radius: 12px;
  padding: 10px 14px;
  font-size: 14px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.merchant-action-btn.block {
  width: 100%;
}

.merchant-action-btn.primary {
  background: #2563eb;
  color: #fff;
}

.merchant-action-btn.ghost {
  background: #f8fafc;
  border-color: #e2e8f0;
  color: #0f172a;
}

.merchant-action-btn.outline {
  background: transparent;
  border-color: #bfdbfe;
  color: #2563eb;
}

.merchant-action-btn.danger {
  background: #fee2e2;
  border-color: #fecaca;
  color: #b91c1c;
}

.merchant-action-btn[disabled],
.merchant-action-btn[data-locked-disabled='true'] {
  background: #e5e7eb;
  border-color: transparent;
  color: #9ca3af;
  cursor: not-allowed;
  box-shadow: none;
}

.merchant-action-btn.primary[disabled],
.merchant-action-btn.primary[data-locked-disabled='true'],
.merchant-action-btn.danger[disabled],
.merchant-action-btn.danger[data-locked-disabled='true'] {
  background: #d1d5db;
  color: #9ca3af;
}

.merchant-action-btn.ghost[disabled],
.merchant-action-btn.ghost[data-locked-disabled='true'],
.merchant-action-btn.outline[disabled],
.merchant-action-btn.outline[data-locked-disabled='true'] {
  background: #f5f5f5;
  border-color: #e5e7eb;
  color: #9ca3af;
}

.merchant-action-btn:hover {
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
}

.merchant-action-btn:active {
  transform: translateY(1px);
}

@media (max-width: 1100px) {
  .merchant-detail-layout {
    grid-template-columns: 1fr;
  }
  .merchant-detail-aside {
    position: static;
  }
  .merchant-status-panel {
    align-items: flex-start;
  }
}

.detail-actions {
  justify-content: flex-end;
  gap: 12px;
}
.ghost-icon-btn {
  border: none;
  background: transparent;
  font-size: 22px;
  cursor: pointer;
  color: #94a3b8;
}

.ghost-icon-btn:hover {
  color: #475569;
}

.ghost-btn.small {
  padding: 4px 10px;
  font-size: 12px;
}

.merchant-detail-header .status-pill {
  font-size: 16px;
  padding: 6px 20px;
}

.merchant-risk-actions .risk-btn {
  padding: 12px 26px;
  font-size: 15px;
}

.risk-card {
  border: 1px solid #fee2e2;
  background: #fff7ed;
}

.risk-list {
  list-style: none;
  padding: 0;
  margin: 0 0 12px;
  font-size: 13px;
  color: #312e81;
}

.risk-list li {
  margin-bottom: 6px;
}

.risk-list strong {
  display: inline-block;
  min-width: 90px;
}

.risk-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.risk-danger-zone {
  border-top: 1px dashed #fecaca;
  margin-top: 14px;
  padding-top: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.risk-delete-note {
  margin: 0;
  font-size: 12px;
  color: #991b1b;
  line-height: 1.4;
}

.risk-btn {
  border: none;
  border-radius: 999px;
  padding: 8px 16px;
  color: #fff;
  cursor: pointer;
  font-size: 13px;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.risk-btn.danger {
  background: #dc2626;
}

.risk-btn.warn {
  background: #f59e0b;
  color: #1f2937;
}

.risk-btn.success {
  background: #10b981;
}

.risk-btn:hover {
  transform: scale(1.03);
  box-shadow: 0 8px 14px rgba(15, 23, 42, 0.15);
}

.risk-btn:active {
  transform: scale(0.96);
}
.drawer-field {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
  margin-bottom: 8px;
}

.drawer-field span {
  color: var(--text-light);
}

.drawer-actions {
  margin-top: 20px;
  display: flex;
  justify-content: flex-end;
}

.user-nickname {
  font-size: 18px;
  color: var(--text-dark);
}

.user-status-filter {
  position: relative;
  margin-left: 12px;
}

.user-status-filter .ghost-btn {
  min-width: 120px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.user-status-filter .ghost-btn svg {
  width: 10px;
  height: 6px;
  margin-left: 6px;
}

.user-status-dropdown {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  background: #fff;
  border: 1px solid rgba(148, 163, 184, 0.4);
  border-radius: 12px;
  box-shadow: 0 15px 30px rgba(15, 23, 42, 0.15);
  padding: 6px;
  display: none;
  z-index: 10;
}

.user-status-filter.open .user-status-dropdown {
  display: block;
}

.user-status-dropdown button {
  width: 100%;
  padding: 8px 14px;
  border-radius: 10px;
  border: none;
  background: transparent;
  text-align: left;
  font-size: 13px;
  cursor: pointer;
}

.user-status-dropdown button.active,
.user-status-dropdown button:hover {
  background: #e0f2fe;
  color: #0369a1;
  font-weight: 600;
}

.merchant-list-panel .panel-header {
  gap: 12px;
  flex-wrap: wrap;
}

.merchant-search-bar {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  padding: 6px 14px;
  background: #fff;
  flex: 1;
  min-width: 220px;
}

.merchant-search-bar input {
  border: none;
  outline: none;
  font-size: 14px;
  flex: 1;
}

.merchant-filter {
  position: relative;
}

.merchant-filter .ghost-btn {
  min-width: 120px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.merchant-filter .ghost-btn svg {
  width: 10px;
  height: 6px;
  margin-left: 6px;
}

.merchant-dropdown {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  background: #fff;
  border: 1px solid rgba(148, 163, 184, 0.4);
  border-radius: 12px;
  box-shadow: 0 15px 30px rgba(15, 23, 42, 0.15);
  padding: 6px;
  display: none;
  z-index: 10;
}

.merchant-filter.open .merchant-dropdown {
  display: block;
}

.merchant-dropdown button {
  width: 100%;
  padding: 8px 14px;
  border-radius: 10px;
  border: none;
  background: transparent;
  text-align: left;
  font-size: 13px;
  cursor: pointer;
}

.merchant-dropdown button.active,
.merchant-dropdown button:hover {
  background: #e0f2fe;
  color: #0369a1;
  font-weight: 600;
}

.merchant-table .table-row {
  display: grid;
  grid-template-columns: 1.4fr 1fr 0.9fr 0.6fr 0.9fr 0.7fr 0.8fr 0.7fr 0.6fr;
  gap: 10px;
  align-items: center;
}

.merchant-table .merchant-row {
  cursor: pointer;
  transition: background 0.2s ease, box-shadow 0.2s ease;
  position: relative;
}

.merchant-table .merchant-row:hover {
  background: #eef2ff;
  box-shadow: 0 8px 24px rgba(37, 99, 235, 0.08);
}

.merchant-table .merchant-row:focus-visible {
  outline: 2px solid #2563eb;
  outline-offset: 2px;
}

.merchant-table .table-row span:last-child {
  justify-self: end;
}

.merchant-table {
  min-width: 1100px;
}

.merchant-activity-table .table-row {
  grid-template-columns: 1.2fr 1fr 1fr 1fr 1fr 1fr 0.8fr;
}

.merchant-table-scroll {
  overflow-x: auto;
  padding-bottom: 6px;
}

.merchant-list-panel {
  min-height: 520px;
}

.merchant-footer {
  margin-top: 12px;
  font-size: 13px;
  color: var(--text-light);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.merchant-footer .pagination {
  display: flex;
  align-items: center;
  gap: 6px;
}

.merchant-footer .pagination .ghost-btn,
.merchant-footer .pagination .pill-btn {
  min-width: 60px;
}

.order-detail-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
  display: none;
  align-items: center;
  justify-content: flex-end;
  z-index: 1500;
}

.order-detail-overlay.open {
  display: flex;
}

.order-detail-drawer {
  width: min(420px, 90vw);
  height: 100vh;
  background: #fff;
  padding: 28px 28px 32px;
  box-shadow: -8px 0 30px rgba(15, 23, 42, 0.2);
  overflow-y: auto;
  border-top-left-radius: 24px;
  border-bottom-left-radius: 24px;
}

.user-drawer .order-detail-actions {
  flex-direction: column;
}

.order-detail-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.order-detail-header h3 {
  margin: 0 0 6px;
  font-size: 20px;
}

.order-detail-header p {
  margin: 0;
  color: var(--text-light);
  font-size: 13px;
}

.order-detail-section {
  border: 1px solid #e5e7eb;
  border-radius: 18px;
  padding: 16px 18px;
  margin-bottom: 16px;
  background: #f8fafc;
}

.order-detail-section h4 {
  margin: 0 0 12px;
  font-size: 15px;
}

.order-detail-section .section-divider {
  margin: 12px 0;
  border-top: 1px dashed #d1d5db;
}

.order-field {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  font-size: 13px;
  margin-bottom: 8px;
}

.order-field span {
  color: var(--text-light);
}

.order-field strong {
  color: var(--text-dark);
}

.platform-income {
  padding: 8px 12px;
  border-radius: 12px;
  background: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.35);
}

.platform-income span {
  color: #15803d;
  font-weight: 600;
}

.platform-income strong {
  color: #15803d;
  font-weight: 700;
}

.order-detail-actions {
  display: flex;
  gap: 12px;
}

.order-action-btn {
  flex: 1;
  border: none;
  border-radius: 999px;
  padding: 12px 0;
  color: #fff;
  font-size: 14px;
  cursor: pointer;
  text-align: center;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.danger-btn {
  background: #dc2626;
}

.warning-btn {
  background: #f59e0b;
  color: #1f2937;
}

.success-btn {
  background: #16a34a;
}

.danger-btn:hover,
.warning-btn:hover,
.success-btn:hover {
  transform: scale(1.03);
  box-shadow: 0 10px 18px rgba(15, 23, 42, 0.15);
}

.danger-btn:active,
.warning-btn:active,
.success-btn:active {
  transform: scale(0.96);
}

.text-success {
  color: #16a34a;
}

.text-negative {
  color: #dc2626;
}

.text-warning {
  color: #f59e0b;
}

.text-muted {
  color: var(--text-light);
}

.log-box {
  min-height: 120px;
  border: 1px solid #e5e7eb;
  border-radius: 16px;
  padding: 12px;
  background: #f8fafc;
}

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

.drawer-footer {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.drawer-footer .drawer-action {
  width: 100%;
  justify-content: center;
}

.drawer-actions .primary-btn,
.drawer-actions .ghost-btn,
.drawer-footer .ghost-btn {
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.drawer-actions .primary-btn:hover,
.drawer-actions .ghost-btn:hover,
.drawer-footer .ghost-btn:hover {
  transform: scale(1.03);
}

.drawer-actions .primary-btn:active,
.drawer-actions .ghost-btn:active,
.drawer-footer .ghost-btn:active {
  transform: scale(0.96);
}

.work-panel {
  padding: 0;
  overflow: hidden;
}

.work-panel .panel-header {
  margin-bottom: 0;
}

.table-scroll {
  overflow-x: auto;
  padding: 4px 0;
}

.ticket-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 720px;
}

.ticket-table th {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-light);
  padding: 16px;
  text-align: left;
}

.ticket-table td {
  padding: 16px;
  border-top: 1px solid #f1f5f9;
  font-size: 15px;
}

.ticket-table tbody tr:hover {
  background: #f8fafc;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
}

.status-processing {
  background: rgba(250, 204, 21, 0.15);
  color: #b45309;
}

.status-success {
  background: rgba(16, 185, 129, 0.15);
  color: #047857;
}

.status-closed {
  background: rgba(148, 163, 184, 0.2);
  color: #475569;
}

.status-pending {
  background: rgba(59, 130, 246, 0.15);
  color: #1d4ed8;
}

.status-review-pass {
  background: rgba(16, 185, 129, 0.15);
  color: #047857;
}

.status-review-reject {
  background: rgba(239, 68, 68, 0.15);
  color: #b91c1c;
}

.status-review-hold {
  background: rgba(245, 158, 11, 0.12);
  color: #b45309;
}

.sla-indicator {
  font-weight: 600;
}

.sla-danger {
  color: #dc2626;
}

.sla-warning {
  color: #ea580c;
}

.sla-safe {
  color: #16a34a;
}

.table-link {
  color: #0ea5e9;
  text-decoration: none;
  font-weight: 600;
}

.section-note {
  margin: 0 0 16px;
  font-size: 14px;
  color: var(--text-light);
}

.panel .user-actions .ghost-btn {
  border-radius: 999px;
  padding: 8px 16px;
  border: 1px solid #e2e8f0;
  color: #0f172a;
  font-weight: 600;
}

.panel-subtitle {
  margin: 4px 0 0;
  color: var(--text-light);
  font-size: 13px;
}

.match-competition {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.match-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.match-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.match-tab {
  border: none;
  background: #e2e8f0;
  color: #475569;
  padding: 8px 18px;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 600;
  font-size: 14px;
}

.match-tab.active {
  background: #1d4ed8;
  color: #fff;
  box-shadow: 0 10px 25px rgba(29, 78, 216, 0.25);
}

.match-toolbar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.match-refresh-btn {
  padding: 10px 20px;
  border-color: #dbeafe;
  font-weight: 600;
  color: #1d4ed8;
  background: #eef2ff;
}

.match-refresh-btn:hover {
  box-shadow: 0 12px 24px rgba(99, 102, 241, 0.25);
}

.match-refresh-tip {
  font-size: 13px;
  color: var(--text-light);
}

.match-inline-toast {
  padding: 12px 18px;
  border-radius: 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 14px;
}

.match-inline-toast.success {
  background: rgba(187, 247, 208, 0.6);
  color: #166534;
}

.match-inline-toast.warning {
  background: rgba(254, 243, 199, 0.7);
  color: #b45309;
}

.match-inline-toast.info {
  background: rgba(191, 219, 254, 0.7);
  color: #1d4ed8;
}

.match-toast-close {
  border: none;
  background: transparent;
  font-size: 16px;
  cursor: pointer;
  color: inherit;
}

.match-card-grid {
  margin-top: -4px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

@media (max-width: 900px) {
  .match-card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .match-card-grid {
    grid-template-columns: 1fr;
  }
}

.match-card-note {
  margin: 6px 0 0;
  font-size: 13px;
  color: var(--text-light);
}

.match-card-note.text-warning {
  color: #f97316;
}

.match-card-note.text-success {
  color: #16a34a;
}

.match-panel-header .match-autorefresh {
  font-size: 13px;
  color: var(--text-light);
}

.match-filter-row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 12px;
  margin-bottom: 16px;
}

.match-search {
  flex: 1 1 260px;
  min-width: 240px;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  padding: 10px 16px;
  display: flex;
  align-items: center;
  gap: 8px;
  background: #f8fafc;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.06);
}

.match-search svg {
  width: 18px;
  height: 18px;
  color: #94a3b8;
}

.match-search input {
  border: none;
  background: transparent;
  flex: 1;
  font-size: 14px;
  font-family: inherit;
  outline: none;
}

.match-select {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 12px;
  color: var(--text-light);
  min-width: 180px;
  flex: 0 0 auto;
}

.match-select {
  position: relative;
}

.match-select-toggle {
  width: 100%;
  border-radius: 999px;
  border: 1px solid #dbeafe;
  padding: 10px 38px 10px 16px;
  font-size: 14px;
  background: #fff;
  font-weight: 600;
  color: var(--text-dark);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  cursor: pointer;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.08);
}

.match-select-toggle svg {
  width: 14px;
  height: 14px;
  color: #94a3b8;
}

.match-select-options {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  width: max(210px, 100%);
  max-height: 260px;
  border: 1px solid #dbeafe;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 15px 30px rgba(15, 23, 42, 0.12);
  padding: 8px 0;
  display: none;
  overflow-y: auto;
  z-index: 35;
}

.match-select-options button {
  width: 100%;
  border: none;
  background: transparent;
  text-align: left;
  padding: 10px 20px;
  font-size: 14px;
  color: var(--text-dark);
  cursor: pointer;
}

.match-select-options button:hover,
.match-select-options button.active {
  background: rgba(59, 130, 246, 0.08);
  color: #1d4ed8;
  font-weight: 600;
}

.match-select.open .match-select-options {
  display: block;
}

.match-select.open .match-select-toggle {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.18);
}

.report-date-filter.match-select .match-select-options {
  width: min(520px, calc(100vw - 120px));
  padding: 12px 16px 16px;
  max-height: none;
}

.match-table {
  border: 1px solid #e2e8f0;
  border-radius: 18px;
  overflow: hidden;
}

.match-table-scroll {
  width: 100%;
  overflow-x: auto;
  padding-bottom: 8px;
}

.match-table .table-row {
  display: grid;
  grid-template-columns: 1.8fr 1fr 0.55fr 0.6fr 0.9fr 0.9fr 0.8fr 0.8fr 0.8fr;
  padding: 14px 18px;
  align-items: center;
}

.match-table-wide .table-row {
  grid-template-columns: 0.9fr 0.6fr 1fr 0.8fr 1fr 0.6fr 0.9fr 0.7fr 0.6fr;
}

.match-list-table {
  min-width: 840px;
}

.match-room-table {
  min-width: 1080px;
}

.match-list-table .table-row {
  grid-template-columns: repeat(7, minmax(120px, 1fr));
}

.match-room-table .table-row {
  grid-template-columns: repeat(8, minmax(120px, 1fr));
}

.match-table .match-table-head {
  background: #f8fafc;
  color: var(--text-light);
  font-weight: 600;
}

.match-table-row {
  border-top: 1px solid #f1f5f9;
}

.match-table-row[data-queue-id],
.match-table-row[data-room-id] {
  cursor: pointer;
}

.match-player-cell {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.match-player-cell strong {
  font-size: 15px;
}

.match-player-meta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--text-light);
}

.match-player-meta em {
  font-style: normal;
}

.match-players-cell {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: flex-start;
}

.queue-player {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.queue-player-avatar .user-avatar {
  box-shadow: 0 8px 16px rgba(15, 23, 42, 0.12);
}

.queue-player-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  align-items: flex-start;
}

.queue-player-info strong {
  font-size: 14px;
  color: #0f172a;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-align: left;
}

.queue-player-info small {
  color: var(--text-light);
  font-size: 12px;
  white-space: nowrap;
  text-align: left;
}

.match-region-cell {
  text-align: left;
  color: #0f172a;
}

.queue-player-extra {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #e2e8f0;
  color: #475569;
  padding: 6px 8px;
  border-radius: 10px;
  font-size: 12px;
  font-weight: 600;
}

.queue-player.empty {
  color: var(--text-light);
}

.match-tier {
  border-radius: 999px;
  padding: 2px 10px;
  font-size: 11px;
  font-weight: 600;
}

.tier-gold {
  background: rgba(251, 191, 36, 0.2);
  color: #b45309;
}

.tier-silver {
  background: rgba(148, 163, 184, 0.2);
  color: #475569;
}

.tier-platinum {
  background: rgba(167, 139, 250, 0.2);
  color: #6d28d9;
}

.match-table-row:nth-child(odd) {
  background: #fff;
}

.match-table-row:hover {
  background: #f8fafc;
}

.match-hour-distribution {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 12px 0 8px;
  padding: 10px 12px;
  background: #f8fafc;
  border-radius: 12px;
}

.match-hour-distribution .dist-label {
  font-weight: 600;
  color: #0f172a;
  white-space: nowrap;
}

.match-hour-distribution .dist-bars {
  flex: 1;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 8px 12px;
}

.match-hour-distribution .dist-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  border-radius: 10px;
  background: #e2e8f0;
  font-size: 12px;
  color: #475569;
}

.match-hour-distribution .dist-time {
  font-weight: 600;
  color: #0f172a;
}

.match-hour-distribution small {
  color: #334155;
}

.match-hour-distribution {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 12px 0 8px;
  padding: 10px 12px;
  background: #f8fafc;
  border-radius: 12px;
}

.match-hour-distribution .dist-label {
  font-weight: 600;
  color: #0f172a;
  white-space: nowrap;
}

.match-hour-distribution .dist-bars {
  flex: 1;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 8px 12px;
}

.match-hour-distribution .dist-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  border-radius: 10px;
  background: #e2e8f0;
  font-size: 12px;
  color: #475569;
}

.match-hour-distribution .dist-time {
  font-weight: 600;
  color: #0f172a;
}

.match-hour-distribution small {
  color: #334155;
}

.match-table .status-pill {
  min-width: 84px;
  text-align: center;
  white-space: nowrap;
}

.match-timeline-note {
  color: var(--text-dark);
  font-weight: 600;
}

.match-panel-header {
  align-items: flex-start;
}

.match-panel-header .panel-subtitle {
  margin-top: 4px;
}

.match-table-footer {
  margin-top: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
  color: var(--text-light);
}

.match-pagination {
  display: flex;
  align-items: center;
  gap: 8px;
}

.match-action-link {
  border: none;
  background: transparent;
  color: #0ea5e9;
  cursor: pointer;
  font-weight: 600;
  font-size: 13px;
  padding: 0;
}

.match-action-link.ghost {
  border: 1px dashed #cbd5f5;
  border-radius: 999px;
  padding: 4px 12px;
  color: #475569;
  margin-left: 8px;
}

.match-strategy-grid {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) 2fr;
  gap: 18px;
}

.strategy-summary dl {
  margin: 0 0 18px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
}

.strategy-summary {
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.08), rgba(16, 185, 129, 0.08));
  border: 1px solid rgba(148, 163, 184, 0.3);
  border-radius: 28px;
  padding: 22px 24px 26px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

.strategy-summary-live {
  border: 2px solid #34d399;
}

.strategy-summary-title {
  display: flex;
  align-items: center;
  gap: 8px;
}

.strategy-live-pill {
  padding: 2px 10px;
  border-radius: 999px;
  background: #d1fae5;
  color: #047857;
  font-size: 12px;
  font-weight: 600;
}

.strategy-summary dl div {
  display: flex;
  justify-content: space-between;
  font-size: 14px;
  color: var(--text-dark);
}

.strategy-summary dt {
  font-weight: 500;
  color: var(--text-light);
}

.strategy-summary dd {
  margin: 0;
  font-weight: 600;
}

.strategy-summary-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.strategy-rollback-btn {
  width: 100%;
  margin-top: 12px;
  background: #10b981;
  border: none;
  color: #fff;
  font-weight: 600;
  border-radius: 999px;
  padding: 12px 0;
  box-shadow: 0 10px 18px rgba(16, 185, 129, 0.35);
}

.strategy-rollback-btn:hover {
  background: #0ea672;
}

.strategy-rollback-btn:active {
  transform: translateY(1px);
}

.strategy-form-panel textarea {
  width: 100%;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  padding: 10px 12px;
  min-height: 80px;
  font-family: inherit;
}

.strategy-gender-select {
  min-width: 220px;
}

.strategy-gender-select .match-select {
  min-width: 0;
}

.strategy-gender-select .match-select-toggle {
  background: #fff;
}

.strategy-fieldset {
  border: 1px solid #e2e8f0;
  border-radius: 18px;
  padding: 16px;
  margin-bottom: 16px;
  background: #f8fafc;
}

.strategy-fieldset h4 {
  margin: 0 0 12px;
  font-size: 15px;
}

.strategy-field-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
  margin-bottom: 12px;
}

.strategy-fieldset > label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 13px;
  color: var(--text-light);
}

.strategy-field-grid label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 13px;
  color: var(--text-light);
}

.strategy-field-grid input,
.strategy-field-grid select {
  border-radius: 10px;
  border: 1px solid #e2e8f0;
  padding: 8px 10px;
  font-size: 14px;
  font-family: inherit;
}

.strategy-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.match-strategy-toast {
  padding: 10px 14px;
  border-radius: 12px;
  background: rgba(16, 185, 129, 0.18);
  color: #047857;
  font-size: 13px;
  margin-bottom: 12px;
}

.match-strategy-toast.info {
  background: rgba(59, 130, 246, 0.15);
  color: #1d4ed8;
}

.match-strategy-toast.warning {
  background: rgba(251, 191, 36, 0.2);
  color: #92400e;
}

.match-history-panel {
  margin-top: 8px;
}

.match-history-columns {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  margin-bottom: 14px;
}

.match-history-card {
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 16px;
  background: #f8fafc;
}

.match-history-card h3 {
  margin: 0 0 10px;
  font-size: 16px;
}

.strategy-version-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.strategy-status-pill {
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
}

.strategy-status-pill.status-published {
  background: #d1fae5;
  color: #047857;
}

.strategy-status-pill.status-draft {
  background: #e0ecff;
  color: #2563eb;
}

.match-history-card.empty-card {
  justify-content: center;
  align-items: center;
  min-height: 120px;
  text-align: center;
  color: var(--text-light);
}

.match-history-card ul {
  margin: 0;
  padding-left: 16px;
  color: var(--text-dark);
}

.match-history-notes ul {
  margin: 8px 0 0;
  padding-left: 18px;
  color: var(--text-dark);
}

.strategy-sim-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  padding: 20px;
}

.strategy-sim-modal {
  width: min(980px, 100%);
  background: #fff;
  border-radius: 24px;
  box-shadow: 0 35px 80px rgba(15, 23, 42, 0.25);
  display: flex;
  flex-direction: column;
  max-height: 95vh;
}

.strategy-sim-header {
  padding: 20px 28px 0;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.strategy-sim-header h3 {
  margin: 0;
  font-size: 20px;
}

.strategy-sim-close {
  font-size: 24px;
  line-height: 1;
}

.strategy-sim-body {
  padding: 0 28px 18px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.strategy-sim-user-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
}

.strategy-sim-user-card {
  background: #f5f9ff;
  border-radius: 20px;
  padding: 16px;
  border: 1px solid #dde7fb;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.strategy-sim-user-card h4 {
  margin: 0 0 4px;
  font-size: 15px;
}

.strategy-sim-user-card label {
  font-size: 13px;
  color: var(--text-light);
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.strategy-sim-user-card input,
.strategy-sim-user-card select {
  border-radius: 10px;
  border: 1px solid #d1d9e6;
  padding: 6px 8px;
  font-size: 14px;
  font-family: inherit;
}

.strategy-sim-metrics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
}

.strategy-sim-metric-card {
  border-radius: 20px;
  border: 1px solid #e2e8f0;
  padding: 18px;
  background: #f8fafc;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.strategy-sim-metric-card h4 {
  margin: 0;
}

.strategy-sim-metric-card ul {
  margin: 0;
  padding-left: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 14px;
}

.strategy-sim-rate {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.strategy-sim-rate strong {
  font-size: 36px;
  color: #059669;
}

.strategy-sim-metric-card textarea {
  border-radius: 14px;
  border: 1px dashed #cbd5f5;
  padding: 10px 12px;
  resize: vertical;
  min-height: 70px;
  font-family: inherit;
  background: #fff;
}

.strategy-sim-note {
  margin: 0;
  font-size: 12px;
  color: var(--text-light);
}

.strategy-sim-footer {
  padding: 14px 28px 24px;
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  border-top: 1px solid #e2e8f0;
}

.match-history-notes li {
  margin-bottom: 4px;
}

@media (max-width: 900px) {
  .match-table .table-row,
  .match-table-wide .table-row {
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  }

  .match-strategy-grid {
    grid-template-columns: 1fr;
  }
}

.work-panel-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px;
  border-top: 1px solid #f1f5f9;
  flex-wrap: wrap;
  gap: 12px;
}

.work-panel-footer span {
  color: var(--text-light);
}

.pagination {
  display: inline-flex;
  gap: 8px;
  align-items: center;
}

.panel {
  background: var(--card);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.06);
  width: 100%;
  box-sizing: border-box;
}

.panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 18px;
}

.panel-header h2 {
  margin: 0;
  font-size: 20px;
}

.badge {
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  background: var(--accent-soft);
  color: var(--accent);
}

.alert-list,
.todo-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.alert-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  font-size: 15px;
}

.alert-item strong {
  color: var(--text-dark);
}

.alert-item span {
  color: var(--text-light);
}

.alert-level {
  margin-left: 24px;
  text-align: right;
  font-weight: 600;
  white-space: nowrap;
}

.todo-item {
  display: flex;
  justify-content: space-between;
  color: var(--text-dark);
}

.todo-item em {
  color: var(--accent);
  font-style: normal;
}

@media (max-width: 1200px) {
  .match-list-table .table-row,
  .match-room-table .table-row {
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  }
  .panel {
    padding: 20px;
  }
}

.chart-wrapper {
  position: relative;
  height: 320px;
}

.trend-panel .chart-wrapper {
  height: 360px;
  margin: 0 -16px;
  padding: 0 16px;
}

.trend-panel .chart-wrapper canvas {
  width: 100% !important;
}

.chart-message {
  position: absolute;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 0 16px;
  font-size: 14px;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.85);
}

.dashboard-status {
  margin: 12px 0;
}

.dashboard-status .inline-status {
  margin: 0;
}

.panel-legend,
.mini-chart-legend {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 16px;
  flex-wrap: wrap;
}

.mini-chart-legend {
  justify-content: center;
  margin-top: 10px;
}

.legend-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--text-dark);
  font-weight: 600;
}

.legend-item::before {
  content: '';
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: #94a3b8;
  display: inline-block;
}

.legend-item.legend-blue::before {
  background: #2563eb;
}

.legend-swatch {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  position: relative;
  width: 30px;
  height: 12px;
  color: inherit;
}

.legend-line {
  width: 100%;
  height: 2px;
  border-radius: 999px;
  background: currentColor;
}

.legend-node {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 2px solid currentColor;
  background: #fff;
  transform: translate(-50%, -50%);
}

.placeholder {
  padding: 40px;
  text-align: center;
  color: var(--text-light);
}

@media (max-width: 960px) {
  .app {
    grid-template-columns: 1fr;
  }

  .sidebar {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
  }

  .menu {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
  }

  .menu-button {
    width: auto;
  }

  .content {
    padding: 24px;
  }

  .page-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .filters {
    flex-wrap: wrap;
  }
}

@media (max-width: 620px) {
  .filters {
    flex-direction: column;
    align-items: stretch;
  }

  .segment {
    width: 100%;
    justify-content: space-between;
  }
}
.select-wrapper {
  position: relative;
}
.review-select[data-value='pass'] .review-select-toggle {
  border-color: #16a34a;
  background: rgba(22, 163, 74, 0.1);
  color: #166534;
}

.review-select[data-value='hold'] .review-select-toggle {
  border-color: #f59e0b;
  background: rgba(245, 158, 11, 0.12);
  color: #b45309;
}

.review-select[data-value='reject'] .review-select-toggle {
  border-color: #ef4444;
  background: rgba(239, 68, 68, 0.12);
  color: #b91c1c;
}

.chip-group {
  display: inline-flex;
  gap: 8px;
  align-items: center;
}

.chip {
  border: 1px solid #d0d8e8;
  border-radius: 999px;
  padding: 6px 14px;
  background: #fff;
  color: #475569;
  font-size: 13px;
  cursor: pointer;
}

.chip.active {
  background: #1d4ed8;
  color: #fff;
  border-color: #1d4ed8;
}

.chip-group.ghost .chip {
  background: #eef2ff;
  border-color: transparent;
}

.chip-group.ghost .chip.active {
  background: #312e81;
}

.analytics-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  margin-top: 20px;
}

.alerts-center .analytics-card-grid {
  margin-top: 0;
}

.analytics-card {
  border-radius: 28px;
  border: none;
  padding: 22px 24px;
  background: #fff;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.08);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.analytics-card span {
  font-size: 13px;
  color: #94a3b8;
  letter-spacing: 0.02em;
}

.analytics-card strong {
  font-size: 26px;
  font-weight: 600;
  color: #0f172a;
}

.analytics-card p {
  margin: 0;
  font-size: 14px;
}

.delta-note {
  font-size: 13px;
  font-weight: 500;
}

.text-neutral {
  color: #475569;
}

.report-center {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.report-toast {
  padding: 10px 14px;
  border-radius: 12px;
  background: rgba(59, 130, 246, 0.15);
  color: #1d4ed8;
  font-size: 13px;
}

.report-toast.success {
  background: rgba(16, 185, 129, 0.18);
  color: #047857;
}

.report-actions-bar {
  display: flex;
  justify-content: flex-end;
  align-items: center;
}

.report-toolbar-actions {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
}

.report-main-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

.report-chart-panel .placeholder.large,
.report-table-panel .placeholder.large {
  min-height: 240px;
}

.chart-note {
  font-size: 12px;
  color: var(--text-light);
  margin-top: 8px;
}

.report-subgrid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}

.report-footer {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.report-detail-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.report-detail-grid {
  display: grid;
  grid-template-columns: repeat(8, minmax(90px, 1fr));
  gap: 12px;
  padding: 14px 16px;
  border-radius: 18px;
  background: #f8fafc;
  font-size: 14px;
  color: #0f172a;
}

.report-detail-grid.report-detail-head {
  background: transparent;
  padding: 0 4px 12px;
  border-radius: 0;
  font-size: 13px;
  color: #94a3b8;
  border-bottom: 1px solid #e2e8f0;
}

.report-detail-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 12px;
}

.report-table-panel.collapsed .report-detail-grid:not(.report-detail-head),
.report-table-panel.collapsed .report-detail-list,
.report-table-panel.collapsed .report-detail-head,
.report-table-panel.collapsed .report-detail-pagination {
  display: none;
}

.report-detail-pagination {
  margin-top: 16px;
  display: flex;
  align-items: center;
  gap: 10px;
  justify-content: flex-end;
  font-size: 13px;
  color: #475569;
}

.report-detail-pagination > button {
  border: 1px solid #dbeafe;
  background: #fff;
  color: #94a3b8;
  padding: 12px 32px;
  border-radius: 999px;
  font-size: 14px;
}

.report-detail-pagination > button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.report-page-list {
  display: flex;
  gap: 8px;
}

.report-page-btn {
  border: 1px solid #dbeafe;
  background: #fff;
  color: #475569;
  border-radius: 999px;
  min-width: 36px;
  padding: 12px 14px;
  font-size: 12px;
}

.report-page-btn.active {
  background: #1f3fbf;
  color: #fff;
  border-color: #1f3fbf;
}

.alerts-center {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.alerts-toolbar {
  display: flex;
  justify-content: flex-end;
  align-self: flex-end;
  width: 100%;
  margin-top: -24px;
  margin-bottom: 8px;
}

.alert-filter-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.alert-select.match-select {
  min-width: 180px;
}

.alert-select.match-select .match-select-options {
  width: max(200px, 100%);
}

@media (max-width: 960px) {
  .alerts-toolbar {
    align-self: stretch;
    margin-top: 0;
    justify-content: flex-start;
  }
  .alert-filter-row {
    justify-content: flex-start;
  }
  .log-retention-row,
  .compliance-settings-header .button-group,
  .log-retention {
    flex-wrap: wrap;
  }
  .log-retention {
    margin-top: 8px;
  }
}

.compliance-center {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.role-panel,
.compliance-settings {
  border-radius: 28px;
  background: #fff;
  padding: 20px 24px;
  box-shadow: 0 18px 30px rgba(15, 23, 42, 0.08);
}

.role-panel .table-row {
  align-items: center;
}

.compliance-settings-header {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
}

.log-retention-row {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: nowrap;
}

.compliance-settings-header .button-group {
  display: flex;
  gap: 10px;
  flex-direction: row;
  align-items: center;
  flex-wrap: nowrap;
}

.log-retention {
  display: flex;
  gap: 6px;
  align-items: center;
  margin-top: 0;
  flex-wrap: nowrap;
}

.log-retention-select.match-select {
  min-width: 110px;
  flex: 0 0 auto;
}

.log-retention-select .match-select-toggle {
  padding: 8px 16px;
}

.compliance-settings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  margin: 20px 0;
}

.compliance-card ul {
  list-style: none;
  padding: 0;
  margin: 12px 0 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.compliance-card li {
  display: flex;
  gap: 10px;
  align-items: center;
  font-size: 14px;
  color: #475569;
}

.circle-toggle {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2px solid #cbd5f5;
  background: transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.circle-toggle.on {
  background: #22c55e;
  border-color: #22c55e;
}

.circle-toggle.on::after {
  content: '✓';
  font-size: 10px;
  color: #fff;
  transform: translateY(-1px);
}

.audit-log ul {
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
  color: #475569;
  font-size: 13px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-height: 120px;
  overflow-y: auto;
}

.compliance-modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.compliance-modal .modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.4);
}

.compliance-modal .modal-content {
  position: relative;
  background: #fff;
  border-radius: 18px;
  padding: 24px;
  width: min(420px, 90vw);
  z-index: 1001;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.compliance-modal form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.compliance-modal label {
  font-size: 13px;
  color: #475569;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.compliance-modal input {
  border-radius: 10px;
  border: 1px solid #dbeafe;
  padding: 10px 12px;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-status-group {
  display: flex;
  align-items: center;
  gap: 12px;
}

.status-buttons {
  display: flex;
  gap: 8px;
}

.status-buttons .ghost-btn.small.active {
  background: #1f3fbf;
  color: #fff;
  border-color: #1f3fbf;
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 4px;
}

.alerts-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 16px;
}

.alerts-feed {
  min-height: 360px;
}

.alerts-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.alerts-list li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid #edf2f7;
  padding-bottom: 10px;
}

.alerts-list li:last-child {
  border-bottom: none;
}

.alerts-list .empty {
  justify-content: center;
  color: #94a3b8;
  font-size: 14px;
}

.alerts-list-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
}

.severity {
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
}

.severity-critical {
  background: #fee2e2;
  color: #b91c1c;
}

.severity-high {
  background: #fef3c7;
  color: #b45309;
}

.severity-warning {
  background: #fff7ed;
  color: #c05621;
}

.service-health {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.service-health li {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  border-bottom: 1px solid #edf2f7;
  padding-bottom: 8px;
}

.service-health li:last-child {
  border-bottom: none;
}

.health-ok {
  color: #059669;
}

.health-degraded {
  color: #d97706;
}

.rules-list,
.activity-log {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.alerts-side .panel-section + .panel-section {
  margin-top: 20px;
}

.link-btn {
  background: none;
  border: none;
  color: #2563eb;
  font-size: 13px;
  cursor: pointer;
}

.compliance-center {
  display: grid;
  grid-template-columns: 1.8fr 1.2fr;
  gap: 18px;
}

.role-table .table-row {
  grid-template-columns: 1.2fr 1.5fr 1.2fr 0.7fr 0.5fr;
}

.compliance-settings {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.compliance-settings-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.compliance-settings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}

.compliance-card {
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 14px;
  background: #f8fafc;
}

.compliance-card h3 {
  margin: 0 0 10px;
}

.compliance-card ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.toggle {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  display: inline-flex;
  margin-right: 8px;
}

.toggle.on {
  background: #16a34a;
}

.toggle.off {
  background: #cbd5f5;
}

.audit-log ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 13px;
  color: #475569;
}

.quality-center {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.quality-main-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 16px;
}

.trend-controls {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.quality-period-select {
  min-width: 130px;
  flex: 0 0 auto;
}

.quality-period-select .match-select-toggle {
  padding: 8px 16px;
}

.quality-period-select .match-select-options {
  width: 140px;
}

.governance-panel .governance-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}

.governance-list article {
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 12px;
  background: #f8fafc;
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-height: 140px;
  align-items: center;
  text-align: center;
  justify-content: center;
}

.governance-list article p {
  flex: 1;
  margin: 0;
  text-align: center;
}

.governance-list article .link-btn {
  align-self: center;
}

.placeholder.large {
  min-height: 220px;
  border: 1px dashed #dbeafe;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-light);
}

.chat-rooms-page {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.chat-card-grid .card h3 {
  margin: 8px 0 4px;
}

.chat-panels {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 16px;
  align-items: start;
}

@media (max-width: 1100px) {
  .chat-panels {
    grid-template-columns: 1fr;
  }
}

.chat-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

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

.chat-room-table .chat-room-row {
  cursor: pointer;
  border-left: 4px solid transparent;
  grid-template-columns: 1.1fr 0.7fr 0.7fr 1fr 1fr 1.2fr;
}

.chat-room-table .chat-room-row.active {
  border-color: #38bdf8;
  background: #f0f9ff;
}

.chat-room-table .chat-room-head {
  grid-template-columns: 1.1fr 0.7fr 0.7fr 1fr 1fr 1.2fr;
}

@media (max-width: 960px) {
  .chat-room-table .table-row {
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  }
}

.chat-room-code {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.chat-room-code small {
  color: #94a3b8;
  font-size: 12px;
}

.chat-room-preview {
  color: #475569;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.chat-room-head span:last-child {
  text-align: left;
}

.chat-pagination {
  gap: 8px;
}

.chat-message-panel {
  min-height: 360px;
}

.chat-message-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: 520px;
  overflow-y: auto;
}

.chat-message {
  padding: 10px 12px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #f8fafc;
}

.chat-message-body {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 10px;
}

.chat-message-avatar .user-avatar {
  margin-top: 2px;
}

.chat-message-content {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.chat-message-meta {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  font-size: 13px;
  color: #64748b;
  align-items: center;
}

.chat-message-user {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.chat-message-user small {
  color: #94a3b8;
  font-size: 12px;
}

.chat-message-time {
  white-space: nowrap;
}

.chat-message-text {
  margin: 6px 0 0;
  color: #0f172a;
  word-break: break-word;
}


.chat-tip {
  padding: 10px 12px;
  background: #ecfeff;
  border: 1px dashed #22d3ee;
  border-radius: 10px;
  color: #0f172a;
  margin-bottom: 10px;
  font-size: 13px;
}
