/* ============================================================================
   SUPER-ADMIN Pricing + Settings config UI (light admin theme)
   ============================================================================ */
.admin-config { color: #1f2937; }

/* KPI strip (pricing page) */
.pe-kpis { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; margin-bottom: 1.5rem; }
.pe-kpi { background: #fff; border: 1px solid #e5e7eb; border-radius: 10px; padding: 1rem 1.25rem; display: flex; flex-direction: column; gap: 0.2rem; }
.pe-kpi-val { font-size: 1.6rem; font-weight: 800; color: #0a1628; }
.pe-kpi-lbl { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.05em; color: #6b7280; }

/* Editable plan cards */
.pe-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 1.25rem; margin-bottom: 1.5rem; }
.pe-card { position: relative; background: #fff; border: 1px solid #e5e7eb; border-radius: 12px; padding: 1.25rem; }
.pe-card-feat { border-color: #c8a03c; box-shadow: inset 0 0 0 1px #c8a03c; }
.pe-badge { position: absolute; top: -10px; right: 12px; background: #c8a03c; color: #0a1628; font-size: 0.66rem; font-weight: 700; padding: 3px 8px; border-radius: 6px; text-transform: uppercase; letter-spacing: 0.04em; }
.pe-plankey { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.08em; color: #9ca3af; font-weight: 700; margin-bottom: 0.75rem; }
.pe-field { display: flex; flex-direction: column; gap: 0.3rem; margin-bottom: 0.85rem; font-size: 0.8rem; color: #374151; font-weight: 600; }
.pe-field small { color: #9ca3af; font-weight: 500; }
.pe-input { padding: 0.55rem 0.7rem; border: 1px solid #d1d5db; border-radius: 8px; font-size: 0.95rem; color: #111827; background: #fff; width: 100%; box-sizing: border-box; }
.pe-input:focus { outline: none; border-color: #c8a03c; box-shadow: 0 0 0 3px rgba(200,160,60,0.15); }
.pe-price-wrap { position: relative; display: flex; align-items: center; }
.pe-cur { position: absolute; left: 0.7rem; color: #6b7280; font-weight: 700; pointer-events: none; }
.pe-price { padding-left: 1.55rem; font-weight: 700; }
.pe-derived { border-top: 1px solid #f0f1f3; margin-top: 0.4rem; padding-top: 0.75rem; display: flex; flex-direction: column; gap: 0.4rem; }
.pe-derived > div { display: flex; justify-content: space-between; font-size: 0.82rem; color: #6b7280; font-weight: 500; }
.pe-derived strong { color: #0a1628; }

/* Save actions */
.pe-actions { display: flex; align-items: center; gap: 1rem; margin-top: 0.5rem; }
.pe-msg { font-size: 0.85rem; font-weight: 600; }

/* Settings cards */
.cfg-card { background: #fff; border: 1px solid #e5e7eb; border-radius: 12px; padding: 1.25rem 1.5rem; margin-bottom: 1.25rem; max-width: 680px; }
.cfg-card h3 { margin: 0 0 1rem; font-size: 1.05rem; color: #0a1628; }
.cfg-row { display: flex; justify-content: space-between; padding: 0.4rem 0; border-bottom: 1px solid #f3f4f6; font-size: 0.9rem; }
.cfg-row:last-child { border-bottom: none; }
.cfg-k { color: #6b7280; }
.cfg-v { color: #111827; font-weight: 600; }
.cfg-field { display: flex; flex-direction: column; gap: 0.35rem; margin-bottom: 1rem; font-size: 0.84rem; color: #374151; font-weight: 600; max-width: 460px; }
.cfg-field small { color: #9ca3af; font-weight: 500; }
.cfg-input { padding: 0.6rem 0.75rem; border: 1px solid #d1d5db; border-radius: 8px; font-size: 0.95rem; color: #111827; background: #fff; }
.cfg-input:focus { outline: none; border-color: #c8a03c; box-shadow: 0 0 0 3px rgba(200,160,60,0.15); }
.cfg-input-sm { max-width: 140px; }
.cfg-toggle { display: flex; align-items: center; gap: 0.6rem; margin-bottom: 1rem; font-size: 0.9rem; color: #374151; font-weight: 600; cursor: pointer; }
.cfg-toggle input { width: 18px; height: 18px; accent-color: #c8a03c; }
.cfg-note { color: #6b7280; font-size: 0.85rem; margin: 0 0 1rem; }

/* btn-secondary fallback (in case theme doesn't define it) */
.admin-config .btn-secondary { background: #f3f4f6; color: #1f2937; border: 1px solid #d1d5db; padding: 0.55rem 1rem; border-radius: 8px; font-weight: 600; cursor: pointer; }
.admin-config .btn-secondary:hover { background: #e5e7eb; }

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

/* ============================================================================
   SUBSCRIPTION RENEW / LOCK screen (member-facing) — navy + gold
   ============================================================================ */
.renew-screen { position: fixed; inset: 0; background: #0a1628; display: flex; align-items: center; justify-content: center; padding: 1.5rem; overflow-y: auto; z-index: 5000; }
.renew-card { background: #0f1a2e; border: 1px solid rgba(255,255,255,0.08); border-radius: 18px; max-width: 440px; width: 100%; padding: 2rem 1.75rem; box-shadow: 0 24px 60px rgba(0,0,0,0.5); text-align: center; }
.renew-logo { font-weight: 800; letter-spacing: 2px; color: #c8a03c; margin-bottom: 1.25rem; }
.renew-card h1 { font-size: 1.4rem; color: #fff; margin: 0 0 0.4rem; }
.renew-sub { color: rgba(255,255,255,0.6); font-size: 0.9rem; margin: 0 0 1.5rem; }
.renew-loading { color: rgba(255,255,255,0.5); padding: 1.5rem 0; }
.renew-plans { display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem; margin-bottom: 1.25rem; }
.renew-plan { position: relative; display: flex; flex-direction: column; gap: 0.3rem; align-items: flex-start; text-align: left; border: 1px solid rgba(255,255,255,0.14); border-radius: 12px; padding: 0.85rem 0.9rem; cursor: pointer; transition: .15s; }
.renew-plan input { position: absolute; top: 0.7rem; right: 0.7rem; accent-color: #c8a03c; }
.renew-plan:has(input:checked) { border-color: #c8a03c; background: rgba(200,160,60,0.1); }
.renew-plan-name { font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.05em; color: rgba(255,255,255,0.6); }
.renew-plan-price { font-size: 1.35rem; font-weight: 800; color: #fff; }
.renew-plan-price small { font-size: 0.7rem; font-weight: 500; color: rgba(255,255,255,0.5); }
.renew-bank { text-align: left; background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.08); border-radius: 12px; padding: 1rem; margin-bottom: 1rem; }
.renew-bank-title { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.06em; color: #c8a03c; font-weight: 700; margin-bottom: 0.6rem; }
.renew-bank > div { display: flex; justify-content: space-between; gap: 1rem; padding: 0.25rem 0; font-size: 0.88rem; }
.renew-bank > div span { color: rgba(255,255,255,0.55); }
.renew-bank > div strong { color: #fff; font-variant-numeric: tabular-nums; }
.renew-bank-empty { color: rgba(255,255,255,0.6); font-size: 0.85rem; text-align: center; }
.renew-note { font-size: 0.82rem; color: rgba(255,255,255,0.55); margin: 0 0 0.85rem; }
.renew-ref { width: 100%; box-sizing: border-box; padding: 0.65rem 0.8rem; border: 1px solid rgba(255,255,255,0.15); border-radius: 8px; background: rgba(255,255,255,0.04); color: #fff; margin-bottom: 0.75rem; }
.renew-msg { color: #e07a5f; font-size: 0.82rem; margin-top: 0.6rem; min-height: 1em; }
.renew-signout { background: none; border: none; color: rgba(255,255,255,0.45); font-size: 0.85rem; cursor: pointer; margin-top: 1.25rem; }
.renew-signout:hover { color: rgba(255,255,255,0.8); }
.renew-pending { padding: 1rem 0; }
.renew-pending h2 { color: #c8a03c; margin: 0 0 0.5rem; }
.renew-pending p { color: rgba(255,255,255,0.7); font-size: 0.9rem; }

/* Super-admin pending payments + bank fields */
.pay-claim { display: flex; justify-content: space-between; align-items: center; gap: 1rem; background: #fff; border: 1px solid #e5e7eb; border-radius: 10px; padding: 0.85rem 1rem; margin-bottom: 0.6rem; }
.pay-claim-info { font-size: 0.88rem; color: #1f2937; }
.pay-claim-info small { display: block; color: #6b7280; font-size: 0.78rem; margin-top: 2px; }
.pay-claim-actions { display: flex; gap: 0.5rem; flex-shrink: 0; }
.pay-confirm-btn { background: #15803d; color: #fff; border: none; padding: 0.45rem 0.9rem; border-radius: 8px; font-weight: 600; cursor: pointer; }
.pay-reject-btn { background: #f3f4f6; color: #b91c1c; border: 1px solid #e5e7eb; padding: 0.45rem 0.9rem; border-radius: 8px; font-weight: 600; cursor: pointer; }

/* ============================================================================
   ADMIN PORTALS (org-admin + super-admin) — unify legacy INLINE white cards to
   the navy theme so text is never white-on-white. "Blue cards, white writing."
   Targets inline styles only (attribute selectors), so the class-based Pricing/
   Settings white cards (.pe-card/.cfg-card) are untouched. Images + colour
   pickers keep their own background.
   ============================================================================ */
#org-admin-content [style*="background: white"], #org-admin-content [style*="background:#fff"], #org-admin-content [style*="background: #fff"], #org-admin-content [style*="background:#ffffff"], #org-admin-content [style*="background: rgb(255"], #org-admin-content [style*="background:#f9fafb"], #org-admin-content [style*="background: #f9fafb"], #org-admin-content [style*="background:#f3f4f6"], #org-admin-content [style*="background: #f3f4f6"], #org-admin-content [style*="background:#f0f9ff"], #org-admin-content [style*="background: #f0f9ff"], #org-admin-content [style*="background: #f8"], #org-admin-content [style*="background:#f8"],
#super-admin-content [style*="background: white"], #super-admin-content [style*="background:#fff"], #super-admin-content [style*="background: #fff"], #super-admin-content [style*="background:#ffffff"], #super-admin-content [style*="background: rgb(255"], #super-admin-content [style*="background:#f9fafb"], #super-admin-content [style*="background: #f9fafb"], #super-admin-content [style*="background:#f3f4f6"], #super-admin-content [style*="background: #f3f4f6"], #super-admin-content [style*="background:#f0f9ff"], #super-admin-content [style*="background: #f0f9ff"] {
    background: #16223c !important;
    border-color: rgba(255,255,255,0.10) !important;
}
/* Dark inline text → light so it reads on the navy cards */
#org-admin-content [style*="color: #374151"], #org-admin-content [style*="color:#374151"], #org-admin-content [style*="color: #1f2937"], #org-admin-content [style*="color:#1f2937"], #org-admin-content [style*="color: #111827"], #org-admin-content [style*="color: #6b7280"], #org-admin-content [style*="color:#6b7280"], #org-admin-content [style*="color: #4b5563"], #org-admin-content [style*="color: #374"], #org-admin-content [style*="color: #9ca3af"],
#super-admin-content [style*="color: #374151"], #super-admin-content [style*="color:#374151"], #super-admin-content [style*="color: #1f2937"], #super-admin-content [style*="color: #111827"], #super-admin-content [style*="color: #6b7280"] {
    color: #cfd8e6 !important;
}
/* Tables inside admin content → navy theme, readable */
#org-admin-content .table-container, #org-admin-content table { background: #16223c !important; }
#org-admin-content thead, #org-admin-content thead th { background: rgba(255,255,255,0.04) !important; color: #aeb9c9 !important; }
#org-admin-content tbody td, #org-admin-content tbody th { color: #e8edf4 !important; }
/* Images + colour pickers must keep their real background */
#org-admin-content img, #org-admin-content input[type="color"], #org-admin-content .color-swatch, #super-admin-content img, #super-admin-content input[type="color"] { background: revert !important; }

/* ============================================================================
   Re-theme the super-admin config pages (Pricing/Settings) to the SAME navy as
   the rest of the admin portal — consistency ("both admin pages"). Overrides the
   light-theme defaults above.
   ============================================================================ */
.admin-config { color: #e8edf4 !important; }
.admin-config .pe-kpi,
.admin-config .pe-card,
.admin-config .cfg-card,
.admin-config .pay-claim { background: #16223c !important; border-color: rgba(255,255,255,0.10) !important; }
.admin-config h1, .admin-config h2, .admin-config .pe-kpi-val, .admin-config .pe-derived strong,
.admin-config .cfg-card h3, .admin-config .cfg-v, .admin-config .pay-claim-info { color: #ffffff !important; }
.admin-config .pe-plankey, .admin-config .pe-kpi-lbl, .admin-config .cfg-k, .admin-config .page-subtitle,
.admin-config .pe-field, .admin-config .cfg-field, .admin-config .pe-derived > div,
.admin-config .cfg-note, .admin-config .pe-field small, .admin-config .cfg-field small,
.admin-config .pay-claim-info small { color: #aeb9c9 !important; }
.admin-config .pe-input, .admin-config .cfg-input {
    background: rgba(255,255,255,0.06) !important; color: #ffffff !important; border-color: rgba(255,255,255,0.15) !important;
}
.admin-config .pe-price-wrap .pe-cur, .admin-config .cfg-toggle { color: #aeb9c9 !important; }
.admin-config .btn-secondary { background: rgba(255,255,255,0.08) !important; color: #fff !important; border-color: rgba(255,255,255,0.15) !important; }
.admin-config .cfg-row { border-bottom-color: rgba(255,255,255,0.08) !important; }
.admin-config .pe-derived { border-top-color: rgba(255,255,255,0.08) !important; }

/* Catch-all safety: any element in either portal with a near-white inline bg gets dark text */
#super-admin-content [style*="background: white"], #super-admin-content [style*="background:#fff"], #super-admin-content [style*="background: #fff"], #super-admin-content [style*="background: rgb(255"] { color: #cfd8e6 !important; }

/* Super-admin data tables → navy theme (org-admin already had this) */
#super-admin-content .table-container, #super-admin-content table { background: #16223c !important; }
#super-admin-content thead, #super-admin-content thead th { background: rgba(255,255,255,0.05) !important; color: #aeb9c9 !important; }
#super-admin-content tbody td, #super-admin-content tbody th { color: #e8edf4 !important; }
#super-admin-content tbody tr { border-color: rgba(255,255,255,0.06) !important; }
#super-admin-content tbody tr:hover { background: rgba(255,255,255,0.03) !important; }

/* Pricing page lacks .admin-config — target its cards via the portal wrapper so the
   KPI strip + plan cards are navy too (id specificity beats the base white). */
#super-admin-content .pe-kpi, #super-admin-content .pe-card { background: #16223c !important; border-color: rgba(255,255,255,0.10) !important; }
#super-admin-content .pe-kpi-val, #super-admin-content .pe-derived strong { color: #ffffff !important; }
#super-admin-content .pe-kpi-lbl, #super-admin-content .pe-plankey, #super-admin-content .pe-field, #super-admin-content .pe-derived > div, #super-admin-content .pe-field small { color: #aeb9c9 !important; }
#super-admin-content .pe-input { background: rgba(255,255,255,0.06) !important; color: #ffffff !important; border-color: rgba(255,255,255,0.15) !important; }
#super-admin-content .pe-derived { border-top-color: rgba(255,255,255,0.08) !important; }
