/* ═══════════════════════════════════════════════════════════════
   Lending Platform — Dark Neon Theme Styles
   Extends the gn-* design system for lending-specific components.
   ═══════════════════════════════════════════════════════════════ */

/* ── Labels & values ── */
.lending-label {
  font-size: .75em;
  color: var(--gn-muted, #6b7280);
  text-transform: uppercase;
  letter-spacing: .05em;
  margin-bottom: 2px;
}

.lending-value {
  font-size: 1.05em;
  font-weight: 700;
  color: #fff;
  font-family: var(--gn-mono, 'Fira Code', monospace);
}

.lending-mono {
  font-family: var(--gn-mono, 'Fira Code', monospace);
}

/* ── Progress bar ── */
.lending-progress-track {
  height: 4px;
  background: rgba(255, 255, 255, .06);
  border-radius: 2px;
  overflow: hidden;
}

.lending-progress-bar {
  height: 100%;
  border-radius: 2px;
  transition: width .6s ease;
}

/* ── Filter bar ── */
.lending-filters {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: rgba(255, 255, 255, .02);
  border: 1px solid rgba(255, 255, 255, .06);
  border-radius: 12px;
}

.lending-filter-group {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.vault-filter.active,
.lending-filters .active {
  background: rgba(34, 211, 238, .12) !important;
  color: var(--gn-cyan, #22d3ee) !important;
  border-color: rgba(34, 211, 238, .3) !important;
}

/* ── Table ── */
.lending-table {
  width: 100%;
  border-collapse: collapse;
  font-size: .9em;
}

.lending-table thead tr {
  border-bottom: 1px solid rgba(255, 255, 255, .08);
}

.lending-table th {
  padding: 10px 12px;
  color: var(--gn-muted, #6b7280);
  font-weight: 600;
  font-size: .8em;
  text-transform: uppercase;
  letter-spacing: .04em;
}

.lending-table tbody tr {
  border-bottom: 1px solid rgba(255, 255, 255, .04);
  transition: background .2s;
}

.lending-table tbody tr:hover {
  background: rgba(255, 255, 255, .03);
}

/* ── Position row ── */
.lending-position-row td {
  vertical-align: middle;
}

/* ── Modal ── */
.lending-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(0, 0, 0, .7);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  animation: lendingFadeIn .2s ease;
}

.lending-modal {
  background: #12122a;
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 16px;
  padding: 28px;
  width: 100%;
  max-width: 420px;
  box-shadow: 0 24px 48px rgba(0, 0, 0, .4);
}

@keyframes lendingFadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* ── Forms ── */
.lending-form-group {
  margin-bottom: 16px;
}

.lending-form-label {
  display: block;
  font-size: .85em;
  font-weight: 600;
  color: #fff;
  margin-bottom: 6px;
}

.lending-form-input {
  width: 100%;
  padding: 10px 14px;
  background: rgba(255, 255, 255, .04);
  border: 1px solid rgba(255, 255, 255, .1);
  border-radius: 10px;
  color: #fff;
  font-size: .95em;
  font-family: var(--gn-mono, monospace);
  transition: border-color .2s;
  outline: none;
}

.lending-form-input:focus {
  border-color: var(--gn-cyan, #22d3ee);
  box-shadow: 0 0 0 3px rgba(34, 211, 238, .1);
}

.lending-form-input::placeholder {
  color: rgba(255, 255, 255, .2);
}

select.lending-form-input {
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%236b7280' viewBox='0 0 16 16'%3E%3Cpath d='m7.247 11.14 2.328-2.327a.5.5 0 0 0-.708-.708L8 8.972 7.133 8.105a.5.5 0 1 0-.708.708l2.328 2.327z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 36px;
}

.lending-form-hint {
  font-size: .75em;
  color: var(--gn-muted, #6b7280);
  margin-top: 4px;
}

/* ── Toggle switch ── */
.lending-toggle-label {
  display: flex !important;
  align-items: center;
  gap: 12px;
  cursor: pointer;
}

.lending-toggle-label input[type="checkbox"] {
  display: none;
}

.lending-toggle-switch {
  position: relative;
  width: 44px;
  height: 24px;
  background: rgba(255, 255, 255, .1);
  border-radius: 12px;
  transition: background .2s;
  flex-shrink: 0;
}

.lending-toggle-switch::after {
  content: '';
  position: absolute;
  top: 3px;
  left: 3px;
  width: 18px;
  height: 18px;
  background: #fff;
  border-radius: 50%;
  transition: transform .2s;
}

.lending-toggle-label input:checked + .lending-toggle-switch {
  background: var(--gn-green, #22d39a);
}

.lending-toggle-label input:checked + .lending-toggle-switch::after {
  transform: translateX(20px);
}

/* ── Shares preview ── */
.lending-shares-preview {
  background: rgba(34, 211, 238, .06);
  border: 1px solid rgba(34, 211, 238, .15);
  border-radius: 10px;
  padding: 12px 16px;
  margin-top: 12px;
}

/* ── Chart container ── */
#yieldChart {
  width: 100% !important;
}

/* ── Responsive ── */
@media (max-width: 768px) {
  #portfolioKpis {
    grid-template-columns: 1fr 1fr !important;
  }
  .lending-filters {
    flex-direction: column;
    align-items: flex-start;
  }
  .lending-modal {
    margin: 16px;
  }
}

@media (max-width: 480px) {
  #portfolioKpis {
    grid-template-columns: 1fr !important;
  }
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   Borrower Portal (Iteration 4.5)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

/* ── Eligibility Banner ── */
.borrow-eligibility {
  padding: 20px 24px;
}
.borrow-eligibility--pending {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--gn-muted, #6b7280);
}
.borrow-eligibility__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}
.borrow-eligibility__score {
  display: flex;
  align-items: center;
  gap: 12px;
}
.borrow-eligibility__label {
  font-size: .8em;
  color: var(--gn-muted, #6b7280);
  text-transform: uppercase;
  letter-spacing: .04em;
}
.borrow-eligibility__value {
  font-size: 2em;
  font-weight: 700;
  font-family: 'Fira Code', monospace;
}
.score--excellent { color: #22d39a; }
.score--good { color: #22d3ee; }
.score--fair { color: #fbbf24; }
.score--poor { color: #f87171; }

.borrow-eligibility__limits {
  display: flex;
  gap: 24px;
}
.borrow-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.borrow-stat__label {
  font-size: .75em;
  color: var(--gn-muted, #6b7280);
  text-transform: uppercase;
  letter-spacing: .04em;
}
.borrow-stat__value {
  font-size: 1.2em;
  font-weight: 600;
  color: var(--gn-text, #e5e7eb);
}

/* ── Calculator ── */
.borrow-calculator__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
}
.borrow-field {
  margin-bottom: 20px;
}
.borrow-field__label {
  display: block;
  font-size: .85em;
  color: var(--gn-muted, #6b7280);
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: .04em;
}
.borrow-slider {
  -webkit-appearance: none;
  width: 100%;
  height: 6px;
  border-radius: 3px;
  background: rgba(255,255,255,.08);
  outline: none;
  margin-bottom: 12px;
}
.borrow-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #22d3ee;
  cursor: pointer;
  box-shadow: 0 0 8px rgba(34,211,238,.4);
}
.borrow-slider::-moz-range-thumb {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #22d3ee;
  cursor: pointer;
  border: none;
}
.borrow-field__row {
  display: flex;
  align-items: center;
  gap: 8px;
}
.borrow-field__number {
  width: 120px;
  text-align: right;
}
.borrow-field__unit {
  font-size: .85em;
  color: var(--gn-muted, #6b7280);
}

/* Calculator results */
.borrow-calculator__results {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.calc-result {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid rgba(255,255,255,.06);
}
.calc-result__label {
  font-size: .85em;
  color: var(--gn-muted, #6b7280);
}
.calc-result__value {
  font-family: 'Fira Code', monospace;
  font-weight: 600;
  color: var(--gn-text, #e5e7eb);
}
.calc-result__value--big {
  font-size: 1.3em;
  color: #22d3ee;
}
.calc-eligibility {
  padding: 8px 12px;
  border-radius: 6px;
  font-size: .85em;
}
.calc-eligibility--warning {
  background: rgba(251,191,36,.1);
  color: #fbbf24;
}
.calc-eligibility--danger {
  background: rgba(248,113,113,.1);
  color: #f87171;
}

.borrow-calculator__action {
  text-align: center;
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid rgba(255,255,255,.06);
}

/* Social proof */
.borrow-social {
  text-align: center;
  padding: 16px;
}
.borrow-social__stat {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: var(--gn-muted, #6b7280);
}
.borrow-social__stat i {
  color: #22d39a;
}

/* Quick links row */
.borrow-links {
  display: flex;
  gap: 12px;
  justify-content: center;
  margin: 24px 0;
}

/* ── Application Form ── */
.apply-credit-bar {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 12px 20px;
}
.apply-credit-bar__score,
.apply-credit-bar__max {
  font-size: .9em;
  color: var(--gn-muted, #6b7280);
}
.apply-form-card {
  padding: 24px;
}
.apply-step {
  margin-bottom: 28px;
}
.apply-step__title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.05em;
  color: #22d3ee;
  margin-bottom: 16px;
}
.apply-step__num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(34,211,238,.15);
  color: #22d3ee;
  font-size: .85em;
  font-weight: 700;
}
.apply-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.apply-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.apply-field label {
  font-size: .85em;
  color: var(--gn-muted, #6b7280);
  text-transform: uppercase;
  letter-spacing: .04em;
}
.field-error {
  color: #f87171;
  font-size: .8em;
}
.apply-review {
  background: rgba(255,255,255,.03);
  border-radius: 8px;
  padding: 16px;
}
.apply-review__row {
  display: flex;
  justify-content: space-between;
  padding: 6px 0;
  border-bottom: 1px solid rgba(255,255,255,.04);
}
.apply-review__label {
  color: var(--gn-muted, #6b7280);
  font-size: .85em;
}
.apply-review__value {
  font-weight: 600;
  font-family: 'Fira Code', monospace;
}
.apply-disclaimer {
  font-size: .8em;
  color: var(--gn-muted, #6b7280);
  margin-top: 12px;
}
.apply-actions {
  text-align: center;
  padding-top: 16px;
}

/* ── Loans Dashboard ── */
.loans-section-title {
  font-size: 1.15em;
  color: #22d3ee;
  margin: 28px 0 12px;
}
.loans-section-title--settled { color: #22d39a; }
.loans-section-title--other { color: var(--gn-muted, #6b7280); }

.loans-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 16px;
}

/* Loan card */
.loan-card {
  background: var(--gn-card, #12122a);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 12px;
  overflow: hidden;
}
.loan-card__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid rgba(255,255,255,.06);
}
.loan-card__id {
  font-weight: 600;
  font-family: 'Fira Code', monospace;
}
.loan-card__body {
  padding: 16px;
}
.loan-card__row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 4px 0;
}
.loan-card__label {
  font-size: .85em;
  color: var(--gn-muted, #6b7280);
}
.loan-card__value {
  font-weight: 600;
  font-family: 'Fira Code', monospace;
}
.loan-card__row--due {
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid rgba(255,255,255,.04);
}
.loan-card__due {
  color: #fbbf24;
}
.due-overdue {
  color: #f87171;
  font-weight: 700;
}

/* Progress bar */
.loan-card__progress {
  margin: 12px 0;
}
.loan-card__progress-bar {
  height: 8px;
  background: rgba(255,255,255,.06);
  border-radius: 4px;
  overflow: hidden;
}
.loan-card__progress-fill {
  height: 100%;
  border-radius: 4px;
  background: linear-gradient(90deg, #22d39a, #22d3ee);
  transition: width 0.4s ease;
}
.loan-card__progress-info {
  display: flex;
  justify-content: space-between;
  font-size: .78em;
  color: var(--gn-muted, #6b7280);
  margin-top: 4px;
}

/* Loan card actions */
.loan-card__actions {
  display: flex;
  gap: 8px;
  padding: 12px 16px;
  border-top: 1px solid rgba(255,255,255,.06);
}
.loan-card__settled-badge {
  color: #22d39a;
  font-size: .85em;
}

/* Status pill colors */
.gn-pill--active { background: rgba(34,211,238,.15); color: #22d3ee; }
.gn-pill--repaying { background: rgba(251,191,36,.15); color: #fbbf24; }
.gn-pill--settled { background: rgba(34,211,154,.15); color: #22d39a; }
.gn-pill--defaulted { background: rgba(248,113,113,.15); color: #f87171; }
.gn-pill--impaired { background: rgba(248,113,113,.1); color: #f87171; }
.gn-pill--created { background: rgba(167,139,250,.15); color: #a78bfa; }
.gn-pill--pending { background: rgba(251,191,36,.1); color: #fbbf24; }
.gn-pill--approved { background: rgba(34,211,154,.1); color: #22d39a; }
.gn-pill--matched { background: rgba(34,211,238,.1); color: #22d3ee; }
.gn-pill--funded { background: rgba(34,211,154,.15); color: #22d39a; }
.gn-pill--rejected { background: rgba(248,113,113,.1); color: #f87171; }
.gn-pill--expired { background: rgba(107,114,128,.15); color: #6b7280; }

/* Upcoming payments */
.loans-upcoming__list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 12px;
}
.upcoming-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 12px;
  background: rgba(255,255,255,.02);
  border-radius: 6px;
}
.upcoming-item__id {
  font-family: 'Fira Code', monospace;
  font-size: .85em;
  margin-right: 12px;
}
.upcoming-item__amount {
  font-weight: 600;
}
.upcoming-item__due {
  font-size: .85em;
  color: #fbbf24;
}

/* Loans empty state */
.loans-empty {
  text-align: center;
  padding: 48px 24px;
}
.loans-empty h3 {
  margin: 12px 0 8px;
  color: var(--gn-text, #e5e7eb);
}
.loans-empty p {
  color: var(--gn-muted, #6b7280);
  margin-bottom: 20px;
}

/* ── Repay Modal ── */
.repay-modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1050;
}
.repay-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,.65);
  backdrop-filter: blur(4px);
}
.repay-modal__dialog {
  position: relative;
  background: var(--gn-card, #12122a);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 14px;
  width: 90%;
  max-width: 440px;
  box-shadow: 0 24px 48px rgba(0,0,0,.5);
}
.repay-modal__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px;
  border-bottom: 1px solid rgba(255,255,255,.06);
}
.repay-modal__header h3 {
  font-size: 1.05em;
  color: #22d3ee;
}
.repay-modal__close {
  background: none;
  border: none;
  color: var(--gn-muted, #6b7280);
  font-size: 1.5em;
  cursor: pointer;
}
.repay-modal__body {
  padding: 20px;
}
.repay-modal__info {
  margin-bottom: 16px;
  font-size: .9em;
  color: var(--gn-muted, #6b7280);
}
.repay-modal__field {
  margin-bottom: 16px;
}
.repay-modal__field label {
  display: block;
  font-size: .85em;
  color: var(--gn-muted, #6b7280);
  margin-bottom: 6px;
}
.repay-modal__actions {
  text-align: center;
}
.repay-modal__footer {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  padding: 12px 20px;
  border-top: 1px solid rgba(255,255,255,.06);
}

/* ── Application Status ── */
.app-status-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px 24px;
}
.app-status__icon {
  font-size: 2em;
}
.app-status-card--pending .app-status__icon { color: #fbbf24; }
.app-status-card--approved .app-status__icon { color: #22d39a; }
.app-status-card--matched .app-status__icon { color: #22d3ee; }
.app-status-card--funded .app-status__icon { color: #22d39a; }
.app-status-card--rejected .app-status__icon { color: #f87171; }
.app-status-card--expired .app-status__icon { color: #6b7280; }

.app-status__label {
  font-size: .8em;
  color: var(--gn-muted, #6b7280);
  text-transform: uppercase;
  letter-spacing: .04em;
}
.app-status__value {
  font-size: 1.3em;
  font-weight: 700;
}

.app-details__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 16px;
}
.app-detail {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.app-detail--wide {
  grid-column: 1 / -1;
}
.app-detail__label {
  font-size: .8em;
  color: var(--gn-muted, #6b7280);
  text-transform: uppercase;
  letter-spacing: .04em;
}
.app-detail__value {
  font-weight: 600;
}

.app-result-loan {
  border-left: 4px solid #22d39a;
}
.app-result-loan p {
  margin: 8px 0 16px;
  color: var(--gn-muted, #6b7280);
}

/* ── Responsive ── */
@media (max-width: 768px) {
  .borrow-calculator__grid {
    grid-template-columns: 1fr;
  }
  .borrow-eligibility__row {
    flex-direction: column;
    align-items: flex-start;
  }
  .apply-fields {
    grid-template-columns: 1fr;
  }
  .app-details__grid {
    grid-template-columns: 1fr;
  }
  .loans-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .borrow-eligibility__limits {
    flex-direction: column;
    gap: 12px;
  }
  .borrow-links {
    flex-direction: column;
    align-items: stretch;
  }
}


/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   ADMIN COCKPIT — Iteration 4.6
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

/* ── KPI Grid ── */
.admin-kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
  margin-bottom: 28px;
}
.admin-kpi {
  background: linear-gradient(135deg, rgba(255,255,255,0.04) 0%, rgba(255,255,255,0.01) 100%);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 14px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.admin-kpi__label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #9ca3af;
}
.admin-kpi__value {
  font-size: 1.5rem;
  font-weight: 700;
  font-family: 'Poppins', sans-serif;
}
.admin-kpi__value--cyan   { color: #00e5ff; }
.admin-kpi__value--purple { color: #a855f7; }
.admin-kpi__value--green  { color: #22d39a; }
.admin-kpi__value--red    { color: #f87171; }
.admin-kpi__value--yellow { color: #fbbf24; }
.admin-kpi__sub {
  font-size: 0.8rem;
  color: #6b7280;
}
.admin-kpi__link {
  font-size: 0.8rem;
  color: #00e5ff;
  text-decoration: none;
  margin-top: 4px;
}
.admin-kpi__link:hover { text-decoration: underline; }

/* ── 2-col grid ── */
.admin-grid-2col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 28px;
}
@media (max-width: 768px) {
  .admin-grid-2col { grid-template-columns: 1fr; }
}

/* ── Activity Feed ── */
.admin-activity {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: 280px;
  overflow-y: auto;
}
.admin-activity__item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.85rem;
  color: #d1d5db;
  padding: 8px 0;
  border-bottom: 1px solid rgba(255,255,255,0.04);
}
.admin-activity__item:last-child { border-bottom: none; }
.activity-icon--deposit { color: #22d39a; }
.activity-icon--loan    { color: #a855f7; }
.activity-icon--app     { color: #fbbf24; }
.admin-activity__empty {
  text-align: center;
  color: #6b7280;
  padding: 24px 0;
}

/* ── Quick Nav ── */
.admin-nav {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 8px;
  margin-bottom: 28px;
}
.admin-nav--back { margin-top: 24px; }

/* ── Filters Bar ── */
.admin-filters {
  margin-bottom: 20px;
}
.admin-filter-form {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}
.admin-filter-group {
  display: flex;
  align-items: center;
  gap: 8px;
}
.admin-filter-label {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #9ca3af;
  white-space: nowrap;
}
.admin-filter-count {
  margin-left: auto;
  font-size: 0.82rem;
  color: #6b7280;
}
.gn-select {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 8px;
  color: #e5e7eb;
  padding: 6px 12px;
  font-size: 0.85rem;
  appearance: auto;
}
.gn-input--sm {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 8px;
  color: #e5e7eb;
  padding: 6px 12px;
  font-size: 0.85rem;
  width: 180px;
}
.gn-input--sm::placeholder { color: #6b7280; }

/* ── Admin Table ── */
.admin-table-card { overflow: hidden; }
.admin-table-wrap { overflow-x: auto; }
.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
}
.admin-table thead th {
  text-align: left;
  padding: 12px 14px;
  font-weight: 600;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #9ca3af;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  white-space: nowrap;
}
.admin-table tbody td {
  padding: 10px 14px;
  color: #d1d5db;
  border-bottom: 1px solid rgba(255,255,255,0.04);
  vertical-align: middle;
}
.admin-table__id {
  font-weight: 700;
  color: #00e5ff;
  font-family: 'Poppins', monospace;
}
.admin-table__num {
  font-variant-numeric: tabular-nums;
  text-align: right;
  white-space: nowrap;
}
.admin-table__muted { color: #4b5563; }
.admin-table__row--hover {
  background: rgba(255,255,255,0.03);
}
.admin-table--compact td,
.admin-table--compact th {
  padding: 6px 10px;
  font-size: 0.8rem;
}

/* ── Utilization / Progress Bar (admin) ── */
.admin-util-bar {
  position: relative;
  height: 20px;
  background: rgba(255,255,255,0.06);
  border-radius: 10px;
  min-width: 80px;
  overflow: hidden;
}
.admin-util-bar__fill {
  height: 100%;
  border-radius: 10px;
  transition: width 0.5s ease;
}
.admin-util-bar__fill--ok     { background: linear-gradient(90deg, #22d39a, #00e5ff); }
.admin-util-bar__fill--warn   { background: linear-gradient(90deg, #fbbf24, #f59e0b); }
.admin-util-bar__fill--danger { background: linear-gradient(90deg, #f87171, #ef4444); }
.admin-util-bar__text {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 700;
  color: #fff;
  text-shadow: 0 1px 2px rgba(0,0,0,0.5);
}

/* ── Admin inline form (impair button etc.) ── */
.admin-inline-form {
  display: inline;
}

/* ── Admin Empty State ── */
.admin-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 48px 20px;
  text-align: center;
  color: #6b7280;
}

/* ── Application Cards ── */
.admin-app-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 18px;
  margin-bottom: 28px;
}
.admin-app-card {
  display: flex;
  flex-direction: column;
}
.admin-app-card__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
}
.admin-app-card__id {
  font-size: 1rem;
  font-weight: 700;
  color: #00e5ff;
  font-family: 'Poppins', monospace;
}
.admin-app-card__body {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px 16px;
  margin-bottom: 16px;
}
.admin-app-detail {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.admin-app-detail--full { grid-column: 1 / -1; }
.admin-app-detail__label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #6b7280;
}
.admin-app-detail__value {
  font-size: 0.88rem;
  color: #e5e7eb;
}
.admin-app-card__actions {
  display: flex;
  gap: 10px;
  align-items: flex-end;
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid rgba(255,255,255,0.06);
}
.admin-app-action-form {
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}
.admin-app-btn-row {
  display: flex;
  gap: 8px;
}
.gn-textarea--sm {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 8px;
  color: #e5e7eb;
  padding: 8px 10px;
  font-size: 0.82rem;
  resize: vertical;
  width: 100%;
  font-family: inherit;
  transition: height 0.2s ease;
}
.gn-textarea--sm::placeholder { color: #4b5563; }

/* ── Tier pills ── */
.gn-pill--tier-conservative { background: rgba(34,211,154,0.15); color: #22d39a; }
.gn-pill--tier-moderate     { background: rgba(251,191,36,0.15); color: #fbbf24; }
.gn-pill--tier-aggressive   { background: rgba(248,113,113,0.15); color: #f87171; }
.gn-pill--tier-unknown      { background: rgba(107,114,128,0.15); color: #6b7280; }

/* ── Status pills (admin context) ── */
.gn-pill--impaired  { background: rgba(248,113,113,0.15); color: #f87171; }
.gn-pill--frozen    { background: rgba(96,165,250,0.15); color: #60a5fa; }
.gn-pill--closed    { background: rgba(107,114,128,0.15); color: #6b7280; }

/* ── Button variants ── */
.gn-btn--sm {
  padding: 5px 12px;
  font-size: 0.8rem;
  border-radius: 8px;
}
.gn-btn--success {
  background: linear-gradient(135deg, #22d39a 0%, #10b981 100%);
  color: #fff;
  border: none;
  cursor: pointer;
}
.gn-btn--success:hover { filter: brightness(1.1); }
.gn-btn--danger {
  background: linear-gradient(135deg, #f87171 0%, #ef4444 100%);
  color: #fff;
  border: none;
  cursor: pointer;
}
.gn-btn--danger:hover { filter: brightness(1.1); }

/* ── Responsive ── */
@media (max-width: 640px) {
  .admin-kpi-grid {
    grid-template-columns: 1fr 1fr;
  }
  .admin-app-grid {
    grid-template-columns: 1fr;
  }
  .admin-app-card__body {
    grid-template-columns: 1fr;
  }
  .admin-filter-form {
    flex-direction: column;
    align-items: stretch;
  }
  .admin-filter-count { margin-left: 0; }
}
