/* ==========================================================================
   BN STAR · PORTAL
   Reutiliza variables, botones y formularios de ./style.css (copia local del sitio).
   Móvil (≤640px) 1 columna · Tablet (≥800px) 2 columnas · Escritorio (≥1100px)
   ========================================================================== */

body.portal-body {
  background: var(--bg-page);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ---------- Header alineado al banner de bnstarwellness.com (Builder) ---------- */
.portal-header {
  background: #001649; /* rgb(0, 22, 73) — mismo navy del sitio live */
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 8px 24px rgba(0, 22, 73, 0.25);
  position: sticky;
  top: 0;
  z-index: 50;
}

.portal-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 80px;
  padding-top: 10px;
  padding-bottom: 10px;
  flex-wrap: wrap;
}

.portal-brand {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  color: var(--white);
}

.portal-brand img {
  height: 60px;
  width: auto;
  max-width: 97px;
  object-fit: contain;
  transition: transform 0.25s ease;
}

.portal-brand:hover img {
  transform: scale(1.03);
}

.portal-brand span {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--yellow);
  overflow-wrap: break-word;
  letter-spacing: 0.02em;
}

.portal-tools {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.lang-switch {
  display: inline-flex;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 999px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.08);
}

.lang-switch button {
  min-width: 44px;
  min-height: 36px;
  border: 0;
  background: transparent;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.75);
  cursor: pointer;
  padding: 0 12px;
}

.lang-switch button.active {
  background: var(--yellow);
  color: var(--navy);
}

.btn-sm {
  padding: 10px 16px;
  font-size: 0.88rem;
  min-height: 44px;
}

.portal-header .btn-outline-navy {
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.6);
}

.portal-header .btn-outline-navy:hover {
  background: var(--white);
  color: var(--navy);
  border-color: var(--white);
}

.link-muted {
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.9rem;
  text-decoration: none;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}

.link-muted:hover {
  color: var(--white);
  text-decoration: underline;
}

/* ---------- Layout ---------- */
.portal-main {
  flex: 1;
  padding: 28px 0 56px;
}

.portal-kicker {
  font-family: var(--font-heading);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #a37b00;
  margin: 0 0 8px;
}

.portal-title {
  font-family: var(--font-heading);
  font-size: clamp(1.6rem, 3.5vw, 2.3rem);
  line-height: 1.15;
  color: var(--navy);
  margin: 0 0 10px;
  overflow-wrap: break-word;
}

.portal-lead {
  color: var(--muted);
  font-size: 1.02rem;
  line-height: 1.6;
  margin: 0 0 24px;
  max-width: 62ch;
}

.portal-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  padding: 24px 20px;
}

/* Auth: 1 columna en móvil, 2 en tablet+ */
.auth-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  align-items: start;
}

.auth-side {
  background: var(--navy);
  color: var(--white);
  border-radius: var(--radius-md);
  padding: 28px 24px;
}

.auth-side .portal-kicker {
  color: var(--yellow);
}

.auth-side .portal-title {
  color: var(--white);
}

.auth-side .portal-lead {
  color: rgba(255, 255, 255, 0.82);
}

.auth-side ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 12px;
}

.auth-side li {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  line-height: 1.5;
}

.auth-side li::before {
  content: "";
  flex: 0 0 auto;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background-color: var(--yellow);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23001649' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 14px;
  margin-top: 2px;
}
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
}

.tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  background: #eef2f9;
  padding: 6px;
  border-radius: var(--radius-sm);
  margin-bottom: 22px;
}

.tabs button {
  min-height: 44px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  font-family: var(--font-heading);
  font-weight: 700;
  color: var(--muted);
  cursor: pointer;
}

.tabs button.active {
  background: var(--white);
  color: var(--navy);
  box-shadow: 0 2px 8px rgba(0, 22, 73, 0.1);
}

.form-hint {
  text-align: center;
  color: var(--muted);
  margin: 18px 0 0;
  font-size: 0.95rem;
}

.form-hint a {
  color: var(--navy);
  font-weight: 700;
}

.form-control {
  min-height: 44px;
}

.btn-block {
  width: 100%;
  min-height: 48px;
}

.form-feedback.warning {
  background-color: #fff6d6;
  color: #6b5300;
  border: 1px solid #f1dd8c;
  display: block;
}

.notice {
  background: #fff6d6;
  border: 1px solid #f1dd8c;
  color: #6b5300;
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  margin-bottom: 18px;
  font-size: 0.95rem;
  line-height: 1.5;
}

/* ---------- Onboarding ---------- */
.ob-header {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  background: #eef2f9;
  color: var(--navy);
  font-size: 0.85rem;
  font-weight: 700;
  font-family: var(--font-heading);
}

.status-badge .dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #e0a800;
}

.status-badge.active .dot {
  background: #1a9e5c;
}

.status-badge.inactive .dot {
  background: #b23a48;
}

.ob-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}

.ob-section {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 22px 20px;
  box-shadow: var(--shadow-sm);
}

.ob-section h2 {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  color: var(--navy);
  margin: 0 0 16px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.ob-section h2 .num {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--yellow);
  color: var(--navy);
  font-size: 0.85rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
}

.ob-section.span-2 {
  grid-column: 1 / -1;
}

.form-group:last-child {
  margin-bottom: 0;
}

.form-grid-2,
.form-grid-3 {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

.form-help {
  color: var(--muted);
  font-size: 0.9rem;
  margin: -4px 0 10px;
  line-height: 1.5;
}

.req {
  color: #b23a48;
  margin-left: 2px;
}

input[readonly].form-control {
  background: #eef2f9;
  color: var(--muted);
}

/* Archivos */
.file-picker input[type="file"] {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  overflow: hidden;
}

.file-picker {
  position: relative;
}

.file-list {
  list-style: none;
  padding: 0;
  margin: 10px 0 0;
  display: grid;
  gap: 6px;
  font-size: 0.92rem;
  color: var(--muted);
}

.file-list li {
  display: flex;
  gap: 8px;
  align-items: center;
  overflow-wrap: break-word;
  word-break: break-word;
}

.file-list li::before {
  content: none;
}

.file-list a {
  color: var(--navy);
}

/* Radios y checkboxes */
.choice-group {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

.choice {
  display: flex;
  align-items: center;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  min-height: 44px;
  cursor: pointer;
  background: #f8fafc;
  font-weight: 600;
  color: var(--ink);
}

.choice:has(input:checked) {
  border-color: var(--navy);
  background: var(--white);
  box-shadow: 0 0 0 2px rgba(0, 22, 73, 0.12);
}

.choice input {
  width: 20px;
  height: 20px;
  accent-color: var(--navy);
}

/* Tallas */
.size-group {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.size-group .choice {
  justify-content: center;
}

.size-group .choice input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
}

.size-group .choice:has(input:checked) {
  background: var(--navy);
  color: var(--white);
}

/* Disponibilidad */
.avail-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 6px;
  table-layout: fixed;
}

.avail-table th {
  font-family: var(--font-heading);
  font-size: 0.8rem;
  color: var(--muted);
  font-weight: 700;
  padding: 4px 0;
}

.avail-table th:first-child {
  text-align: left;
  width: 28%;
}

.avail-table td {
  text-align: center;
}

.avail-table td:first-child {
  text-align: left;
  font-weight: 700;
  color: var(--navy);
  font-size: 0.9rem;
}

.avail-cell {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
  cursor: pointer;
}

.avail-cell input {
  width: 20px;
  height: 20px;
  accent-color: var(--navy);
}

.avail-cell:has(input:checked) {
  background: #e6f7ef;
  border-color: #1a9e5c;
}

/* Consentimiento y acciones */
.consent {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  line-height: 1.5;
  color: var(--ink);
}

.consent input {
  width: 22px;
  height: 22px;
  flex: 0 0 auto;
  margin-top: 2px;
  accent-color: var(--navy);
}

.ob-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 8px;
}

/* Pantalla de confirmación */
.done-card {
  text-align: center;
  padding: 40px 20px;
}

.done-icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: #e6f7ef;
  color: #0f5132;
  font-size: 2rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}

.done-card .portal-lead {
  margin-left: auto;
  margin-right: auto;
}

.portal-footer {
  border-top: 1px solid var(--line);
  padding: 18px 0;
  color: var(--muted);
  font-size: 0.85rem;
  text-align: center;
}

[hidden] {
  display: none !important;
}

/* ---------- Teléfono ≤ 640px ---------- */
@media (max-width: 640px) {
  .portal-header {
    position: static; /* no robar media pantalla con dos filas pegajosas */
  }

  .portal-header .container {
    min-height: 72px;
    padding-top: 12px;
    padding-bottom: 12px;
  }

  .portal-brand img {
    height: 53px;
    max-width: 86px;
  }
}

/* ---------- Tablet ≥ 800px: máximo 2 columnas ---------- */
@media (min-width: 800px) {
  .auth-grid {
    grid-template-columns: 1fr 1fr;
  }

  .auth-side {
    padding: 36px 32px;
    position: sticky;
    top: 84px;
  }

  .portal-card {
    padding: 32px 28px;
  }

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

  .form-grid-2 {
    grid-template-columns: 1fr 1fr;
  }

  .form-grid-3 {
    grid-template-columns: 1.4fr 1fr 1fr;
  }

  .choice-group {
    grid-template-columns: repeat(3, 1fr);
  }

  .size-group {
    grid-template-columns: repeat(6, 1fr);
  }

  .ob-actions {
    flex-direction: row;
    justify-content: flex-end;
    align-items: center;
  }
}

/* ---------- Escritorio ≥ 1100px ---------- */
@media (min-width: 1100px) {
  .portal-main {
    padding-top: 40px;
  }

  .auth-grid {
    grid-template-columns: 1.1fr 1fr;
    gap: 36px;
  }
}

/* ---------- Modo Simulación ---------- */
.sim-banner {
  background: #f0fdf4;
  border: 1px solid #86efac;
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

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

.sim-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 700;
  color: #15803d;
  letter-spacing: 0.02em;
}

.sim-badge .dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.25);
}

.sim-desc {
  margin: 0;
  font-size: 0.88rem;
  color: #166534;
  line-height: 1.4;
}

.sim-actions {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}

.btn-sim {
  padding: 6px 12px;
  font-size: 0.82rem;
  font-family: var(--font-heading);
  font-weight: 700;
  border-radius: 6px;
  border: 1px solid #86efac;
  background: var(--white);
  color: #15803d;
  cursor: pointer;
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: all 0.15s ease;
}

.btn-sim:hover {
  background: #dcfce7;
  border-color: #4ade80;
  color: #14532d;
}

.btn-sim-danger {
  border-color: #fecaca;
  color: #b91c1c;
}

.btn-sim-danger:hover {
  background: #fee2e2;
  border-color: #f87171;
  color: #991b1b;
}

.btn-sim-admin {
  background: #eff6ff;
  border-color: #93c5fd;
  color: #1d4ed8;
}

.btn-sim-admin:hover {
  background: #dbeafe;
  border-color: #60a5fa;
  color: #1e40af;
}

/* ==========================================================================
   ADMIN PORTAL DASHBOARD STYLES
   ========================================================================== */

.badge-role {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(254, 221, 89, 0.2);
  color: var(--yellow);
  border: 1px solid rgba(254, 221, 89, 0.4);
  font-family: var(--font-heading);
  font-size: 0.78rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 999px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.admin-container {
  max-width: 1360px;
  margin: 0 auto;
  padding: 24px 20px 48px;
  width: 100%;
}

.admin-header-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.admin-header-titles h1 {
  font-size: 1.85rem;
  color: var(--navy);
  margin: 0 0 6px 0;
  font-family: var(--font-heading);
  font-weight: 800;
}

.admin-header-titles p {
  color: #475569;
  margin: 0;
  font-size: 0.95rem;
}

.admin-header-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}

/* KPI Cards */
.admin-kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.kpi-card {
  background: var(--white);
  border-radius: 12px;
  padding: 18px 20px;
  border: 1px solid #e2e8f0;
  box-shadow: 0 2px 8px rgba(0, 22, 73, 0.04);
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.kpi-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 22, 73, 0.08);
}

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

.kpi-title {
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #64748b;
  margin: 0;
  font-family: var(--font-heading);
}

.kpi-icon {
  font-size: 1.25rem;
}

.kpi-value {
  font-size: 1.95rem;
  font-weight: 800;
  color: var(--navy);
  font-family: var(--font-heading);
  line-height: 1.1;
  margin-bottom: 4px;
}

.kpi-sub {
  font-size: 0.78rem;
  color: #64748b;
}

/* Filter Controls Box */
.admin-filters-card {
  background: var(--white);
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 18px 20px;
  margin-bottom: 20px;
  box-shadow: 0 2px 8px rgba(0, 22, 73, 0.03);
}

.filter-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
  gap: 12px;
  align-items: center;
}

.search-wrap {
  position: relative;
}

.search-input {
  width: 100%;
  height: 42px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  padding: 0 14px 0 38px;
  font-size: 0.92rem;
  font-family: inherit;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.search-input:focus {
  outline: none;
  border-color: #002b80;
  box-shadow: 0 0 0 3px rgba(0, 43, 128, 0.12);
}

.search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: #94a3b8;
  pointer-events: none;
}

.filter-select {
  height: 42px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  padding: 0 10px;
  font-size: 0.88rem;
  font-family: inherit;
  background-color: var(--white);
  color: #1e293b;
  cursor: pointer;
  transition: border-color 0.15s ease;
}

.filter-select:focus {
  outline: none;
  border-color: #002b80;
}

.filter-meta-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid #f1f5f9;
  font-size: 0.85rem;
  color: #64748b;
  flex-wrap: wrap;
  gap: 10px;
}

.btn-clear-filters {
  background: transparent;
  border: none;
  color: #002b80;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 4px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.btn-clear-filters:hover {
  background: #f1f5f9;
  text-decoration: underline;
}

/* Data Table */
.admin-table-card {
  background: var(--white);
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  box-shadow: 0 4px 14px rgba(0, 22, 73, 0.04);
  overflow: hidden;
}

.table-responsive {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.9rem;
}

.admin-table th {
  background: #f8fafc;
  color: #475569;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 14px 16px;
  border-bottom: 2px solid #e2e8f0;
  white-space: nowrap;
}

.admin-table td {
  padding: 14px 16px;
  border-bottom: 1px solid #f1f5f9;
  vertical-align: middle;
  color: #1e293b;
}

.admin-table tr:hover td {
  background-color: #f8fafc;
}

.pro-cell {
  display: flex;
  align-items: center;
  gap: 12px;
}

.pro-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: #001649;
  color: #fedd59;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-family: var(--font-heading);
  font-size: 0.9rem;
  flex-shrink: 0;
}

.pro-info {
  display: flex;
  flex-direction: column;
}

.pro-name {
  font-weight: 700;
  color: var(--navy);
  font-size: 0.95rem;
}

.pro-meta {
  font-size: 0.8rem;
  color: #64748b;
}

.badge-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 700;
  font-family: var(--font-heading);
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.badge-status.active {
  background: #dcfce7;
  color: #15803d;
  border: 1px solid #86efac;
}

.badge-status.inactive {
  background: #f1f5f9;
  color: #64748b;
  border: 1px solid #cbd5e1;
}

.badge-status.submitted {
  background: #fef3c7;
  color: #b45309;
  border: 1px solid #fcd34d;
}

.badge-status .dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
}

.rate-tag {
  font-family: var(--font-heading);
  font-weight: 800;
  color: var(--navy);
  font-size: 1rem;
}

.tag-profession {
  display: inline-block;
  background: #f1f5f9;
  color: #334155;
  padding: 3px 8px;
  border-radius: 4px;
  font-size: 0.8rem;
  font-weight: 600;
  border: 1px solid #e2e8f0;
  max-width: 220px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.tag-verif {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
  margin-right: 4px;
}

.tag-verif.ok {
  background: #dcfce7;
  color: #15803d;
}

.tag-verif.pending {
  background: #fef3c7;
  color: #b45309;
}

.btn-action-view {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  color: #1d4ed8;
  font-family: var(--font-heading);
  font-size: 0.82rem;
  font-weight: 700;
  padding: 6px 12px;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.15s ease;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.btn-action-view:hover {
  background: #1d4ed8;
  color: #ffffff;
  border-color: #1d4ed8;
}

/* Slide-over Drawer for Admin Editing */
.drawer-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 16, 52, 0.55);
  backdrop-filter: blur(4px);
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.drawer-backdrop.open {
  opacity: 1;
  visibility: visible;
}

.admin-drawer {
  position: fixed;
  top: 0;
  right: 0;
  width: 100%;
  max-width: 620px;
  height: 100vh;
  background: var(--white);
  box-shadow: -8px 0 32px rgba(0, 22, 73, 0.2);
  z-index: 1001;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

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

.drawer-header {
  padding: 20px 24px;
  background: var(--navy);
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.drawer-header h2 {
  font-size: 1.25rem;
  margin: 0 0 4px 0;
  color: var(--white);
  font-family: var(--font-heading);
}

.drawer-header p {
  margin: 0;
  font-size: 0.85rem;
  color: var(--yellow);
}

.drawer-close {
  background: transparent;
  border: none;
  color: var(--white);
  font-size: 1.5rem;
  cursor: pointer;
  line-height: 1;
  padding: 4px 8px;
  border-radius: 4px;
}

.drawer-close:hover {
  background: rgba(255, 255, 255, 0.15);
}

.drawer-body {
  padding: 24px;
  overflow-y: auto;
  flex: 1;
}

.drawer-section {
  margin-bottom: 24px;
  padding-bottom: 20px;
  border-bottom: 1px solid #e2e8f0;
}

.drawer-section:last-child {
  border-bottom: none;
  margin-bottom: 0;
}

.drawer-section-title {
  font-size: 0.95rem;
  font-family: var(--font-heading);
  font-weight: 800;
  color: var(--navy);
  margin: 0 0 14px 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.drawer-section-title .badge-scope {
  font-size: 0.68rem;
  background: #f1f5f9;
  color: #475569;
  padding: 2px 6px;
  border-radius: 4px;
  text-transform: uppercase;
  font-weight: 700;
}

.drawer-section-title .badge-scope.admin-scope {
  background: #fef3c7;
  color: #92400e;
  border: 1px solid #fde68a;
}

.drawer-footer {
  padding: 16px 24px;
  border-top: 1px solid #e2e8f0;
  background: #f8fafc;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}

.admin-field-group {
  margin-bottom: 14px;
}

.admin-field-label {
  display: block;
  font-size: 0.82rem;
  font-weight: 700;
  color: #334155;
  margin-bottom: 5px;
  font-family: var(--font-heading);
}

.admin-field-input {
  width: 100%;
  height: 38px;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  padding: 0 10px;
  font-size: 0.88rem;
  font-family: inherit;
}

.admin-field-input:focus {
  outline: none;
  border-color: #002b80;
  box-shadow: 0 0 0 3px rgba(0, 43, 128, 0.1);
}

.admin-field-textarea {
  width: 100%;
  min-height: 80px;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  padding: 8px 10px;
  font-size: 0.88rem;
  font-family: inherit;
  resize: vertical;
}

.admin-field-textarea:focus {
  outline: none;
  border-color: #002b80;
}

.read-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  background: #f8fafc;
  padding: 14px;
  border-radius: 8px;
  border: 1px solid #e2e8f0;
}

.read-item {
  display: flex;
  flex-direction: column;
}

.read-label {
  font-size: 0.75rem;
  font-weight: 700;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.read-value {
  font-size: 0.88rem;
  color: #1e293b;
  font-weight: 500;
  word-break: break-word;
}

/* Toast */
.admin-toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: #0f172a;
  color: #ffffff;
  padding: 12px 20px;
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 600;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
  z-index: 2000;
  display: flex;
  align-items: center;
  gap: 8px;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.2s ease, transform 0.2s ease;
  pointer-events: none;
}

.admin-toast.show {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

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

@media (max-width: 600px) {
  .filter-grid {
    grid-template-columns: 1fr;
  }
  .read-grid {
    grid-template-columns: 1fr;
  }
  .admin-header-row {
    flex-direction: column;
  }
}


