:root {
  --background: #f7f7f4;
  --surface: #ffffff;
  --surface-soft: #f2f3ef;

  --text: #151713;
  --text-secondary: #686d65;
  --text-muted: #8a8f87;

  --brand: #315c45;
  --brand-hover: #274c38;
  --brand-soft: #e9f0eb;

  --border: #e3e5df;
  --danger: #b42318;
  --danger-background: #fef3f2;

  --shadow:
    0 20px 45px rgba(18, 24, 20, 0.08);

  --radius-large: 24px;
  --radius-medium: 14px;
  --radius-small: 10px;

  --transition: 160ms ease;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  font-family:
    Inter,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;

  color: var(--text);
  background: var(--background);
  -webkit-font-smoothing: antialiased;
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

/* =========================================
   LOGIN
   ========================================= */

.login-page {
  min-height: 100vh;
}

.login-layout {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(360px, 0.9fr) minmax(500px, 1.1fr);
}

/* =========================================
   BRAND PANEL
   ========================================= */

.login-brand-panel {
  min-height: 100vh;

  display: flex;
  flex-direction: column;
  justify-content: space-between;

  padding: 56px;

  color: #ffffff;

  background:
    radial-gradient(
      circle at 20% 15%,
      rgba(255, 255, 255, 0.09),
      transparent 30%
    ),
    linear-gradient(
      145deg,
      #1f4634 0%,
      #315c45 52%,
      #254a37 100%
    );
}

.brand-content {
  max-width: 560px;
  margin: auto 0;
}

.brand-mark {
  width: 58px;
  height: 58px;

  display: inline-flex;
  align-items: center;
  justify-content: center;

  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 16px;

  background: rgba(255, 255, 255, 0.1);

  font-size: 17px;
  font-weight: 750;
  letter-spacing: -0.03em;

  backdrop-filter: blur(10px);
}

.brand-mark-small {
  width: 42px;
  height: 42px;
  border-radius: 12px;

  color: #ffffff;
  background: var(--brand);
  border: none;

  font-size: 14px;
}

.brand-eyebrow {
  margin: 32px 0 14px;

  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.16em;

  color: rgba(255, 255, 255, 0.7);
}

.brand-content h1 {
  max-width: 600px;

  margin: 0;

  font-size: clamp(38px, 4vw, 62px);
  line-height: 1.02;
  letter-spacing: -0.05em;
  font-weight: 650;
}

.brand-description {
  max-width: 510px;

  margin: 26px 0 0;

  color: rgba(255, 255, 255, 0.73);

  font-size: 17px;
  line-height: 1.7;
}

.brand-footer {
  margin: 0;

  color: rgba(255, 255, 255, 0.55);

  font-size: 13px;
}

/* =========================================
   FORM PANEL
   ========================================= */

.login-form-panel {
  min-height: 100vh;

  display: flex;
  align-items: center;
  justify-content: center;

  padding: 48px;
}

.login-card {
  width: 100%;
  max-width: 440px;
}

.mobile-brand {
  display: none;
}

.login-heading {
  margin-bottom: 34px;
}

.login-eyebrow {
  margin: 0 0 10px;

  color: var(--brand);

  font-size: 12px;
  font-weight: 750;
  letter-spacing: 0.14em;
}

.login-heading h2 {
  margin: 0;

  font-size: 38px;
  line-height: 1.1;
  letter-spacing: -0.04em;
  font-weight: 650;
}

.login-heading > p:last-child {
  margin: 12px 0 0;

  color: var(--text-secondary);

  font-size: 15px;
  line-height: 1.6;
}

/* =========================================
   FORM
   ========================================= */

.form-group {
  margin-bottom: 22px;
}

.form-group label {
  display: block;

  margin-bottom: 9px;

  color: #31352f;

  font-size: 13px;
  font-weight: 650;
}

.password-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.form-group input {
  width: 100%;
  height: 52px;

  padding: 0 15px;

  border: 1px solid var(--border);
  border-radius: var(--radius-small);

  outline: none;

  color: var(--text);
  background: var(--surface);

  transition:
    border-color var(--transition),
    box-shadow var(--transition);
}

.form-group input::placeholder {
  color: #a0a49e;
}

.form-group input:focus {
  border-color: var(--brand);

  box-shadow:
    0 0 0 4px rgba(49, 92, 69, 0.09);
}

.password-field {
  position: relative;
}

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

.password-toggle {
  position: absolute;

  top: 50%;
  right: 14px;

  transform: translateY(-50%);

  padding: 5px;

  border: 0;
  background: transparent;

  color: var(--brand);

  font-size: 12px;
  font-weight: 700;
}

.alert {
  margin: 0 0 18px;
  padding: 13px 14px;

  border-radius: var(--radius-small);

  font-size: 13px;
  line-height: 1.5;
}

.alert-error {
  color: var(--danger);
  background: var(--danger-background);
  border: 1px solid #fecdca;
}

.primary-button {
  width: 100%;
  height: 52px;

  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;

  border: 0;
  border-radius: var(--radius-small);

  color: #ffffff;
  background: var(--brand);

  font-size: 14px;
  font-weight: 700;

  transition:
    background var(--transition),
    transform var(--transition),
    opacity var(--transition);
}

.primary-button:hover:not(:disabled) {
  background: var(--brand-hover);
}

.primary-button:active:not(:disabled) {
  transform: translateY(1px);
}

.primary-button:disabled {
  cursor: not-allowed;
  opacity: 0.7;
}

.button-spinner {
  width: 16px;
  height: 16px;

  border: 2px solid rgba(255, 255, 255, 0.35);
  border-top-color: #ffffff;
  border-radius: 50%;

  animation: spin 0.7s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.security-note {
  display: flex;
  align-items: flex-start;
  gap: 10px;

  margin-top: 26px;
  padding-top: 22px;

  border-top: 1px solid var(--border);

  color: var(--text-muted);
}

.security-note p {
  margin: 0;

  font-size: 12px;
  line-height: 1.6;
}

.security-icon {
  color: var(--brand);
  font-size: 18px;
  line-height: 1;
}

/* =========================================
   RESPONSIVE
   ========================================= */

@media (max-width: 900px) {
  .login-layout {
    display: block;
  }

  .login-brand-panel {
    display: none;
  }

  .login-form-panel {
    min-height: 100vh;
    padding: 32px 22px;
  }

  .login-card {
    max-width: 460px;
  }

  .mobile-brand {
    display: flex;
    align-items: center;
    gap: 12px;

    margin-bottom: 64px;

    font-size: 16px;
    font-weight: 700;
  }
}

@media (max-width: 520px) {
  .login-form-panel {
    align-items: flex-start;
    padding-top: 28px;
  }

  .mobile-brand {
    margin-bottom: 52px;
  }

  .login-heading h2 {
    font-size: 32px;
  }
}

/* =========================================
   ADMIN APPLICATION
   ========================================= */

.admin-page {
  min-height: 100vh;
  background: #f7f8f5;
}

.admin-sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  z-index: 50;

  width: 260px;

  display: flex;
  flex-direction: column;

  padding: 26px 18px 20px;

  background: #173d2c;
  color: #ffffff;
}

.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 12px;

  padding: 0 8px 28px;
}

.sidebar-logo {
  width: 42px;
  height: 42px;

  display: flex;
  align-items: center;
  justify-content: center;

  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 12px;

  background: rgba(255, 255, 255, 0.08);

  font-size: 13px;
  font-weight: 800;
}

.sidebar-brand-name {
  font-size: 15px;
  font-weight: 700;
}

.sidebar-brand-label {
  margin-top: 3px;

  color: rgba(255, 255, 255, 0.52);

  font-size: 11px;
}

.sidebar-nav {
  flex: 1;
}

.sidebar-section-label {
  margin: 14px 12px 9px;

  color: rgba(255, 255, 255, 0.42);

  font-size: 10px;
  font-weight: 750;
  letter-spacing: 0.14em;
}

.sidebar-section-spaced {
  margin-top: 28px;
}

.sidebar-link {
  width: 100%;

  display: flex;
  align-items: center;
  gap: 12px;

  min-height: 46px;

  margin: 3px 0;
  padding: 0 12px;

  border: 0;
  border-radius: 10px;

  color: rgba(255, 255, 255, 0.72);
  background: transparent;

  text-decoration: none;
  text-align: left;

  font-size: 13px;
  font-weight: 550;

  transition:
    background var(--transition),
    color var(--transition);
}

.sidebar-link:hover:not(.sidebar-disabled) {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.07);
}

.sidebar-link.active {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.11);
}

.sidebar-icon {
  width: 20px;

  text-align: center;

  font-size: 16px;
}

.nav-badge {
  min-width: 22px;

  margin-left: auto;
  padding: 3px 6px;

  border-radius: 20px;

  color: #173d2c;
  background: #dceadf;

  text-align: center;

  font-size: 10px;
  font-weight: 800;
}

.sidebar-disabled {
  cursor: default;
  opacity: 0.45;
}

.coming-soon {
  margin-left: auto;

  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.sidebar-footer {
  padding-top: 18px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar-logout {
  width: 100%;
  height: 44px;

  display: flex;
  align-items: center;
  gap: 12px;

  padding: 0 12px;

  border: 0;
  border-radius: 10px;

  color: rgba(255, 255, 255, 0.68);
  background: transparent;

  text-align: left;

  font-size: 13px;
}

.sidebar-logout:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.07);
}

/* =========================================
   MAIN AREA
   ========================================= */

.admin-main {
  min-height: 100vh;
  margin-left: 260px;
}

.admin-header {
  height: 86px;

  display: flex;
  align-items: center;
  justify-content: space-between;

  padding: 0 34px;

  border-bottom: 1px solid var(--border);

  background: rgba(255, 255, 255, 0.88);

  backdrop-filter: blur(14px);
}

.header-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

.page-eyebrow {
  margin: 0 0 4px;

  color: var(--text-muted);

  font-size: 9px;
  font-weight: 750;
  letter-spacing: 0.13em;
}

.page-title {
  margin: 0;

  font-size: 21px;
  font-weight: 650;
  letter-spacing: -0.025em;
}

.admin-identity {
  display: flex;
  align-items: center;
  gap: 11px;
}

.admin-avatar {
  width: 38px;
  height: 38px;

  display: flex;
  align-items: center;
  justify-content: center;

  border-radius: 50%;

  color: #ffffff;
  background: var(--brand);

  font-size: 13px;
  font-weight: 750;
}

.admin-identity-text {
  display: flex;
  flex-direction: column;
}

.admin-email {
  max-width: 230px;

  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;

  font-size: 12px;
  font-weight: 650;
}

.admin-role {
  margin-top: 2px;

  color: var(--text-muted);

  font-size: 10px;
}

.mobile-menu-button {
  display: none;

  width: 40px;
  height: 40px;

  border: 1px solid var(--border);
  border-radius: 9px;

  background: var(--surface);
}

.admin-content {
  width: 100%;
  max-width: 1500px;

  margin: 0 auto;
  padding: 36px;
}

/* =========================================
   DASHBOARD
   ========================================= */

.welcome-section {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;

  margin-bottom: 28px;
}

.content-eyebrow,
.panel-eyebrow {
  margin: 0 0 8px;

  color: var(--brand);

  font-size: 10px;
  font-weight: 750;
  letter-spacing: 0.12em;
}

.welcome-section h2 {
  margin: 0;

  font-size: 27px;
  font-weight: 650;
  letter-spacing: -0.035em;
}

.welcome-section > div > p:last-child {
  margin: 9px 0 0;

  color: var(--text-secondary);

  font-size: 13px;
}

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

  margin-bottom: 22px;
}

.metric-card {
  min-height: 154px;

  padding: 20px;

  border: 1px solid var(--border);
  border-radius: 16px;

  background: var(--surface);
}

.metric-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;

  color: var(--text-secondary);

  font-size: 12px;
  font-weight: 600;
}

.metric-icon {
  width: 30px;
  height: 30px;

  display: flex;
  align-items: center;
  justify-content: center;

  border-radius: 9px;

  color: var(--brand);
  background: var(--brand-soft);
}

.metric-value {
  display: block;

  margin-top: 18px;

  font-size: 29px;
  font-weight: 650;
  letter-spacing: -0.04em;
}

.metric-card p {
  margin: 6px 0 0;

  color: var(--text-muted);

  font-size: 11px;
}

.metric-card-muted {
  background: #fafbf9;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(320px, 0.65fr);
  gap: 20px;
}

.dashboard-panel {
  min-height: 300px;

  padding: 22px;

  border: 1px solid var(--border);
  border-radius: 16px;

  background: var(--surface);
}

.panel-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;

  padding-bottom: 18px;

  border-bottom: 1px solid var(--border);
}

.panel-header h3 {
  margin: 0;

  font-size: 17px;
  font-weight: 650;
}

.text-link {
  color: var(--brand);

  font-size: 12px;
  font-weight: 650;

  text-decoration: none;
}

.panel-state {
  min-height: 190px;

  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;

  color: var(--text-muted);

  font-size: 12px;
}

.state-loader {
  width: 24px;
  height: 24px;

  border: 2px solid var(--border);
  border-top-color: var(--brand);
  border-radius: 50%;

  animation: spin 0.7s linear infinite;
}

.empty-state {
  text-align: center;
}

.empty-state-icon {
  width: 42px;
  height: 42px;

  display: flex;
  align-items: center;
  justify-content: center;

  margin: 0 auto 12px;

  border-radius: 50%;

  color: var(--brand);
  background: var(--brand-soft);
}

.empty-state strong {
  display: block;

  font-size: 13px;
  color: var(--text);
}

.empty-state p {
  margin: 6px 0 0;
}

.review-summary {
  width: 100%;

  display: flex;
  align-items: center;
  justify-content: space-between;
}

.review-summary strong {
  display: block;

  color: var(--text);

  font-size: 34px;
}

.review-summary span {
  display: block;

  margin-top: 4px;
}

.secondary-button {
  padding: 10px 14px;

  border: 1px solid var(--border);
  border-radius: 9px;

  color: var(--text);
  background: var(--surface);

  text-decoration: none;

  font-size: 11px;
  font-weight: 650;
}

.quick-actions {
  padding-top: 8px;
}

.quick-action {
  display: grid;
  grid-template-columns: 38px 1fr auto;
  align-items: center;
  gap: 12px;

  padding: 15px 4px;

  border-bottom: 1px solid var(--border);

  color: var(--text);

  text-decoration: none;
}

.quick-action:last-child {
  border-bottom: 0;
}

.quick-action-icon {
  width: 36px;
  height: 36px;

  display: flex;
  align-items: center;
  justify-content: center;

  border-radius: 10px;

  color: var(--brand);
  background: var(--brand-soft);
}

.quick-action strong {
  display: block;

  font-size: 12px;
  font-weight: 650;
}

.quick-action small {
  display: block;

  margin-top: 4px;

  color: var(--text-muted);

  font-size: 10px;
}

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

.inline-error {
  padding: 12px 14px;

  border: 1px solid #fecdca;
  border-radius: 9px;

  color: var(--danger);
  background: var(--danger-background);
}

.sidebar-overlay {
  display: none;
}

/* =========================================
   RESPONSIVE ADMIN
   ========================================= */

@media (max-width: 1100px) {
  .metric-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .dashboard-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 800px) {
  .admin-sidebar {
    transform: translateX(-100%);
    transition: transform 180ms ease;
  }

  .admin-sidebar.open {
    transform: translateX(0);
  }

  .admin-main {
    margin-left: 0;
  }

  .mobile-menu-button {
    display: block;
  }

  .sidebar-overlay {
    position: fixed;
    inset: 0;
    z-index: 40;

    background: rgba(0, 0, 0, 0.35);
  }

  .sidebar-overlay.visible {
    display: block;
  }

  .admin-header {
    padding: 0 20px;
  }

  .admin-content {
    padding: 24px 20px;
  }
}

@media (max-width: 600px) {
  .metric-grid {
    grid-template-columns: 1fr;
  }

  .admin-identity-text {
    display: none;
  }

  .welcome-section h2 {
    font-size: 23px;
  }
}

/* =========================================
   CONTENT PAGES
   ========================================= */

.page-intro {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;

  margin-bottom: 24px;
}

.page-intro h2 {
  margin: 0;

  font-size: 27px;
  font-weight: 650;
  letter-spacing: -0.035em;
}

.page-intro > div > p:last-child {
  max-width: 680px;

  margin: 9px 0 0;

  color: var(--text-secondary);

  font-size: 13px;
  line-height: 1.6;
}

.secondary-action-button,
.primary-action-button,
.danger-button,
.danger-outline-button {
  min-height: 40px;

  padding: 0 15px;

  border-radius: 9px;

  font-size: 12px;
  font-weight: 650;
}

.secondary-action-button {
  border: 1px solid var(--border);

  color: var(--text);
  background: var(--surface);
}

.primary-action-button {
  border: 1px solid var(--brand);

  color: #ffffff;
  background: var(--brand);
}

.danger-button {
  border: 1px solid var(--danger);

  color: #ffffff;
  background: var(--danger);
}

.danger-outline-button {
  border: 1px solid #f0b9b4;

  color: var(--danger);
  background: #ffffff;
}

.secondary-action-button:disabled,
.primary-action-button:disabled,
.danger-button:disabled,
.danger-outline-button:disabled {
  cursor: not-allowed;
  opacity: 0.6;
}

.content-card {
  overflow: hidden;

  border: 1px solid var(--border);
  border-radius: 16px;

  background: var(--surface);
}

.table-toolbar {
  min-height: 78px;

  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;

  padding: 18px 20px;

  border-bottom: 1px solid var(--border);
}

.table-toolbar h3 {
  margin: 0;

  font-size: 15px;
  font-weight: 650;
}

.table-toolbar p {
  margin: 5px 0 0;

  color: var(--text-muted);

  font-size: 11px;
}

.status-filter {
  display: inline-flex;
  align-items: center;
  gap: 7px;

  padding: 7px 10px;

  border: 1px solid var(--border);
  border-radius: 20px;

  color: var(--text-secondary);
  background: #fafbf9;

  font-size: 10px;
  font-weight: 650;
}

.status-dot {
  width: 7px;
  height: 7px;

  border-radius: 50%;

  background: #d38a22;
}

.data-state {
  min-height: 350px;

  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;

  color: var(--text-muted);

  font-size: 12px;
}

.table-wrapper {
  overflow-x: auto;
}

.admin-table {
  width: 100%;

  border-collapse: collapse;

  font-size: 12px;
}

.admin-table th {
  padding: 13px 18px;

  border-bottom: 1px solid var(--border);

  color: var(--text-muted);
  background: #fafbf9;

  text-align: left;

  font-size: 9px;
  font-weight: 750;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.admin-table td {
  padding: 17px 18px;

  border-bottom: 1px solid var(--border);

  color: var(--text-secondary);

  vertical-align: middle;
}

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

.admin-table tbody tr:hover {
  background: #fafbf9;
}

.table-primary {
  color: var(--text);

  font-size: 12px;
  font-weight: 600;
}

.table-secondary {
  margin-top: 4px;

  color: var(--text-muted);

  font-size: 10px;
}

.table-action-heading,
.table-action-cell {
  text-align: right !important;
}

.table-action-button {
  padding: 7px 11px;

  border: 1px solid var(--border);
  border-radius: 8px;

  color: var(--brand);
  background: var(--surface);

  font-size: 10px;
  font-weight: 700;
}

.table-action-button:hover {
  border-color: #c9d4cc;
  background: var(--brand-soft);
}

.status-badge {
  display: inline-flex;
  align-items: center;

  padding: 5px 8px;

  border-radius: 20px;

  font-size: 9px;
  font-weight: 750;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.status-pending {
  color: #875b14;
  background: #fff5df;
}

.large-empty-state,
.large-error-state {
  max-width: 420px;

  text-align: center;
}

.large-empty-state strong,
.large-error-state strong {
  display: block;

  color: var(--text);

  font-size: 14px;
}

.large-empty-state p,
.large-error-state p {
  margin: 7px 0 16px;

  line-height: 1.6;
}

/* =========================================
   REVIEW DRAWER
   ========================================= */

.drawer-overlay {
  position: fixed;
  inset: 0;
  z-index: 80;

  visibility: hidden;
  opacity: 0;

  background: rgba(15, 22, 18, 0.32);

  transition:
    opacity 180ms ease,
    visibility 180ms ease;
}

.drawer-overlay.visible {
  visibility: visible;
  opacity: 1;
}

.review-drawer {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 90;

  width: min(520px, 100%);
  height: 100vh;

  overflow-y: auto;

  transform: translateX(100%);

  background: var(--surface);

  box-shadow:
    -20px 0 50px rgba(18, 24, 20, 0.12);

  transition: transform 200ms ease;
}

.review-drawer.open {
  transform: translateX(0);
}

.drawer-header {
  position: sticky;
  top: 0;
  z-index: 2;

  min-height: 84px;

  display: flex;
  align-items: center;
  justify-content: space-between;

  padding: 20px 24px;

  border-bottom: 1px solid var(--border);

  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(12px);
}

.drawer-header h2,
.modal-header h2 {
  margin: 0;

  font-size: 19px;
  font-weight: 650;
  letter-spacing: -0.025em;
}

.icon-button {
  width: 36px;
  height: 36px;

  display: flex;
  align-items: center;
  justify-content: center;

  border: 1px solid var(--border);
  border-radius: 9px;

  color: var(--text-secondary);
  background: var(--surface);

  font-size: 21px;
}

.drawer-content {
  padding: 0 24px 32px;
}

.review-section {
  padding: 24px 0;

  border-bottom: 1px solid var(--border);
}

.review-section:last-child {
  border-bottom: 0;
}

.review-label {
  margin: 0 0 14px;

  color: var(--text-muted);

  font-size: 9px;
  font-weight: 750;
  letter-spacing: 0.1em;
}

.review-provider {
  display: flex;
  align-items: center;
  gap: 12px;
}

.review-avatar {
  width: 42px;
  height: 42px;

  display: flex;
  align-items: center;
  justify-content: center;

  border-radius: 50%;

  color: #ffffff;
  background: var(--brand);

  font-size: 13px;
  font-weight: 750;
}

.review-provider strong,
.review-provider span {
  display: block;
}

.review-provider strong {
  font-size: 13px;
}

.review-provider span {
  margin-top: 4px;

  color: var(--text-muted);

  font-size: 10px;
}

.detail-list {
  margin: 0;
}

.detail-list > div {
  display: grid;
  grid-template-columns: 145px 1fr;
  gap: 20px;

  padding: 11px 0;

  border-bottom: 1px solid #eff0ec;
}

.detail-list > div:last-child {
  border-bottom: 0;
}

.detail-list dt {
  color: var(--text-muted);

  font-size: 11px;
}

.detail-list dd {
  margin: 0;

  color: var(--text);

  font-size: 11px;
  font-weight: 600;
}

.document-card {
  display: grid;
  grid-template-columns: 48px 1fr auto;
  align-items: center;
  gap: 12px;

  padding: 14px;

  border: 1px solid var(--border);
  border-radius: 12px;

  background: #fafbf9;
}

.document-icon {
  width: 46px;
  height: 46px;

  display: flex;
  align-items: center;
  justify-content: center;

  border-radius: 10px;

  color: var(--brand);
  background: var(--brand-soft);

  font-size: 9px;
  font-weight: 800;
}

.document-info strong,
.document-info span {
  display: block;
}

.document-info strong {
  font-size: 11px;
}

.document-info span {
  margin-top: 4px;

  color: var(--text-muted);

  font-size: 9px;
}

.document-open-button {
  padding: 8px 11px;

  border: 1px solid var(--border);
  border-radius: 8px;

  color: var(--brand);
  background: var(--surface);

  text-decoration: none;

  font-size: 10px;
  font-weight: 700;
}

.document-missing {
  padding: 14px;

  border: 1px dashed var(--border);
  border-radius: 10px;

  color: var(--text-muted);

  font-size: 11px;
}

.review-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

/* =========================================
   MODALS
   ========================================= */

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 120;

  display: flex;
  align-items: center;
  justify-content: center;

  padding: 24px;

  background: rgba(15, 22, 18, 0.45);
}

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

.admin-modal {
  width: min(520px, 100%);

  padding: 24px;

  border-radius: 16px;

  background: var(--surface);

  box-shadow:
    0 30px 70px rgba(18, 24, 20, 0.2);
}

.admin-modal-small {
  width: min(460px, 100%);
}

.modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
}

.modal-description {
  margin: 18px 0 22px;

  color: var(--text-secondary);

  font-size: 12px;
  line-height: 1.6;
}

.form-group textarea {
  width: 100%;

  padding: 13px 14px;

  resize: vertical;

  border: 1px solid var(--border);
  border-radius: var(--radius-small);

  outline: none;

  color: var(--text);
  background: var(--surface);

  line-height: 1.5;
}

.form-group textarea:focus {
  border-color: var(--brand);

  box-shadow:
    0 0 0 4px rgba(49, 92, 69, 0.09);
}

.field-help {
  display: flex;
  justify-content: space-between;

  margin-top: 6px;

  color: var(--text-muted);

  font-size: 9px;
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 9px;

  margin-top: 22px;
}

/* =========================================
   TOAST
   ========================================= */

.admin-toast {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 160;

  max-width: 380px;

  padding: 13px 16px;

  transform: translateY(20px);

  visibility: hidden;
  opacity: 0;

  border-radius: 10px;

  color: #ffffff;
  background: #173d2c;

  box-shadow:
    0 16px 40px rgba(18, 24, 20, 0.18);

  font-size: 11px;
  font-weight: 600;

  transition:
    opacity 160ms ease,
    transform 160ms ease,
    visibility 160ms ease;
}

.admin-toast.visible {
  visibility: visible;
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 700px) {
  .page-intro {
    align-items: flex-start;
    flex-direction: column;
  }

  .table-toolbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .detail-list > div {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .review-actions {
    grid-template-columns: 1fr;
  }
}

/* =========================================
   USER MANAGEMENT
   ========================================= */

.user-stat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;

  margin-bottom: 20px;
}

.compact-stat-card {
  padding: 17px 18px;

  border: 1px solid var(--border);
  border-radius: 13px;

  background: var(--surface);
}

.compact-stat-card span {
  display: block;

  color: var(--text-muted);

  font-size: 10px;
  font-weight: 600;
}

.compact-stat-card strong {
  display: block;

  margin-top: 8px;

  color: var(--text);

  font-size: 24px;
  font-weight: 650;
  letter-spacing: -0.035em;
}

.users-toolbar {
  min-height: 76px;

  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;

  padding: 15px 18px;

  border-bottom: 1px solid var(--border);
}

.users-search {
  width: min(360px, 100%);
}

.users-search input {
  width: 100%;
  height: 40px;

  padding: 0 13px;

  border: 1px solid var(--border);
  border-radius: 9px;

  outline: none;

  color: var(--text);
  background: var(--surface);

  font-size: 11px;
}

.users-search input:focus {
  border-color: var(--brand);

  box-shadow:
    0 0 0 3px rgba(49, 92, 69, 0.08);
}

.role-filter-group {
  display: flex;
  align-items: center;
  gap: 5px;

  padding: 4px;

  border: 1px solid var(--border);
  border-radius: 10px;

  background: #fafbf9;
}

.role-filter {
  height: 31px;

  padding: 0 10px;

  border: 0;
  border-radius: 7px;

  color: var(--text-muted);
  background: transparent;

  font-size: 9px;
  font-weight: 700;
}

.role-filter.active {
  color: var(--brand);
  background: var(--surface);

  box-shadow:
    0 1px 3px rgba(18, 24, 20, 0.08);
}

.user-table-profile {
  display: flex;
  align-items: center;
  gap: 11px;
}

.table-avatar {
  width: 34px;
  height: 34px;

  flex: 0 0 auto;

  display: flex;
  align-items: center;
  justify-content: center;

  border-radius: 50%;

  color: var(--brand);
  background: var(--brand-soft);

  font-size: 11px;
  font-weight: 750;
}

.role-badge {
  display: inline-flex;
  align-items: center;

  padding: 5px 8px;

  border-radius: 20px;

  font-size: 9px;
  font-weight: 750;
  letter-spacing: 0.03em;
}

.role-admin {
  color: #523b8b;
  background: #f0ecfa;
}

.role-provider {
  color: #245b3e;
  background: #e8f2eb;
}

.role-customer {
  color: #315f88;
  background: #eaf2f8;
}

.role-default {
  color: #5d625b;
  background: #f0f1ee;
}

.status-approved {
  color: #245b3e;
  background: #e8f2eb;
}

.user-detail-role {
  margin-top: 16px;
}

.drawer-loading {
  min-height: 300px;

  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;

  color: var(--text-muted);

  font-size: 11px;
}

.drawer-message {
  margin-top: 60px;
}

.admin-action-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;

  padding: 16px;

  border: 1px solid var(--border);
  border-radius: 12px;

  background: #fafbf9;
}

.admin-action-card strong {
  display: block;

  font-size: 12px;
}

.admin-action-card p {
  max-width: 270px;

  margin: 5px 0 0;

  color: var(--text-muted);

  font-size: 10px;
  line-height: 1.5;
}

.safety-notice {
  margin-top: 12px;
  padding: 12px 13px;

  border: 1px solid #eadfc3;
  border-radius: 10px;

  color: #715820;
  background: #fffaf0;

  font-size: 10px;
  line-height: 1.55;
}

.sr-only {
  position: absolute;

  width: 1px;
  height: 1px;

  padding: 0;
  margin: -1px;

  overflow: hidden;

  clip: rect(0, 0, 0, 0);

  white-space: nowrap;

  border: 0;
}

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

  .users-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .users-search {
    width: 100%;
  }

  .role-filter-group {
    overflow-x: auto;
  }
}

@media (max-width: 520px) {
  .user-stat-grid {
    grid-template-columns: 1fr 1fr;
  }

  .admin-action-card {
    align-items: stretch;
    flex-direction: column;
  }
}
