/* =============================================================
   NEDU School Portal — portal.css
   Design tokens match the NEDU LMS Instructor Dashboard's look (same
   palette, radius, shadow, and typography) — every rule below already
   referenced these as variables, so retuning this one block is what
   actually does the reskin; no selectors or class names changed, so
   nothing in portal.js needed to change alongside it. Same two-tier
   font system as the other dashboards too: Inter for headers/titles,
   Atkinson Hyperlegible for everything else.
   ============================================================= */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=Atkinson+Hyperlegible:wght@400;700&display=swap');

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

#nsp-root, .nsp-join-wrap {
  --purple-50:#FDF1E9;--purple-100:#FBDAC0;--purple-200:#F5BD8E;--purple-600:#D95907;--purple-800:#B84D06;--purple-900:#7A3404;
  --teal-50:#DCFCE7;--teal-100:#BBF7D0;--teal-600:#0CA678;--teal-800:#087F5B;
  --blue-50:#E0F2FE;--blue-100:#BAE6FD;--blue-600:#0284C7;--blue-800:#075985;
  --green-50:#DCFCE7;--green-100:#BBF7D0;--green-600:#0CA678;
  --amber-50:#FEF3C7;--amber-100:#FDE68A;--amber-600:#D97706;
  --red-50:#FEE2E2;--red-100:#FECACA;--red-600:#DC2626;
  --gray-50:#F1F5F9;--gray-100:#E2E8F0;--gray-200:#CBD5E1;--gray-400:#94A3B8;--gray-600:#475569;
  --bg:#F8FAFC;--surface:#fff;--border:rgba(15,23,42,0.1);
  --text:#0F172A;--text-2:#475569;--text-3:#94A3B8;
  --sidebar-w:220px;--radius:14px;--radius-s:8px;
  --card-shadow: 0 1px 2px rgba(15,23,42,0.04), 0 4px 12px rgba(15,23,42,0.05);
  font-family:'Atkinson Hyperlegible',-apple-system,BlinkMacSystemFont,'Segoe UI',system-ui,Roboto,sans-serif; font-size:14px; color:var(--text);
  -webkit-font-smoothing: antialiased;
}

#nsp-root h1, #nsp-root h2, #nsp-root h3, #nsp-root h4, #nsp-root h5, #nsp-root h6,
.nsp-join-wrap h1, .nsp-join-wrap h2, .nsp-join-wrap h3, .nsp-join-wrap h4, .nsp-join-wrap h5, .nsp-join-wrap h6,
#nsp-root [class*="title"], #nsp-root [class*="heading"],
.nsp-join-wrap [class*="title"], .nsp-join-wrap [class*="heading"] {
  font-family:'Inter',-apple-system,BlinkMacSystemFont,'Segoe UI',system-ui,Roboto,sans-serif;
}

#nsp-root { background:var(--bg); min-height:100vh; display:flex; margin:-20px; }

/* ── Sidebar ── */
.nsp-sidebar { width:var(--sidebar-w);min-height:100vh;background:var(--surface);border-right:.5px solid var(--border);display:flex;flex-direction:column;position:fixed;top:0;left:0;bottom:0;overflow-y:auto;z-index:50; }
.nsp-sidebar-brand { padding:22px 20px 16px;border-bottom:.5px solid var(--border); }
.nsp-brand-name { font-size:18px;font-weight:700;color:var(--purple-900);letter-spacing:-.5px; }
.nsp-brand-sub { font-size:11px;color:var(--text-3);margin-top:1px; }
.nsp-sidebar-section { padding:18px 12px 6px; }
.nsp-sidebar-section-label { font-size:10px;font-weight:600;color:var(--text-3);letter-spacing:.8px;text-transform:uppercase;padding:0 8px;margin-bottom:6px; }
.nsp-sidebar-nav { list-style:none; }
.nsp-sidebar-nav li a { display:flex;align-items:center;gap:9px;padding:8px 10px;border-radius:7px;color:var(--text-2);text-decoration:none;font-size:13.5px;cursor:pointer;transition:background .15s,color .15s; }
.nsp-sidebar-nav li a:hover { background:var(--gray-50);color:var(--text); }
.nsp-sidebar-nav li a.active { background:var(--purple-50);color:var(--purple-800);font-weight:500; }
.nsp-sidebar-nav li a i { font-size:17px; }
.nsp-sidebar-profile { margin-top:auto;padding:16px;border-top:.5px solid var(--border); }
.nsp-back-to-site {
  display:flex; align-items:center; gap:8px; padding:11px 20px; font-size:13px; font-weight:600;
  color:var(--text-3); text-decoration:none; transition:color .15s, background .15s;
}
.nsp-back-to-site:hover { color:var(--purple-600); background:var(--gray-50); }
.nsp-school-badge { background:var(--purple-50);border-radius:var(--radius);padding:12px; }
.nsp-school-icon { width:36px;height:36px;background:var(--purple-600);border-radius:8px;display:flex;align-items:center;justify-content:center;color:#fff;font-size:18px;margin-bottom:8px; }
.nsp-school-logo-img { object-fit:cover; background:var(--gray-50); }
.nsp-school-name { font-weight:600;font-size:13px;color:var(--purple-900); }
.nsp-school-plan { font-size:12px;color:var(--text-3);margin-top:1px; }
.nsp-school-plan span { color:var(--purple-600);font-weight:500; }
.nsp-school-meta { font-size:11px;color:var(--text-3);margin-top:4px; }
.nsp-seat-row { display:flex;justify-content:space-between;font-size:12px;margin-top:8px;padding-top:8px;border-top:.5px solid var(--border); }
.nsp-seat-label { color:var(--text-2); }
.nsp-seat-val { font-weight:600; }
.nsp-status-dot { display:inline-block;width:7px;height:7px;border-radius:50%;background:var(--teal-600);margin-right:5px; }

/* ── Main ── */
.nsp-main { margin-left:var(--sidebar-w);flex:1;display:flex;flex-direction:column;min-height:100vh; }
.nsp-topbar { height:56px;background:var(--surface);border-bottom:.5px solid var(--border);display:flex;align-items:center;justify-content:space-between;padding:0 28px;position:sticky;top:0;z-index:40; }
.nsp-topbar-title { font-size:18px;font-weight:600;overflow:hidden;text-overflow:ellipsis;white-space:nowrap; }
.nsp-topbar-right { display:flex;align-items:center;gap:16px;flex-shrink:0; }
@media (max-width: 640px) {
  .nsp-topbar { padding:0 14px; }
  .nsp-topbar-right { gap:10px; }
  .nsp-school-chip .nsp-chip-name { max-width:70px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap; }
  .nsp-content { padding:16px !important; }
}
.nsp-notif-btn { position:relative;background:none;border:none;cursor:pointer;color:var(--text-2);font-size:20px;display:flex; }
.nsp-notif-badge { position:absolute;top:-3px;right:-4px;background:var(--red-600);color:#fff;font-size:9px;font-weight:700;border-radius:99px;padding:1px 4px; }
.nsp-notif-dropdown { position:absolute; top:44px; right:0; width:320px; max-height:400px; overflow-y:auto; background:var(--surface); border:.5px solid var(--border); border-radius:var(--radius); box-shadow:0 10px 40px rgba(15,23,42,.15); z-index:60; display:none; }
.nsp-notif-dropdown.open { display:block; }
.nsp-notif-dropdown-head { padding:14px 16px; font-weight:600; font-size:13px; border-bottom:.5px solid var(--border); }
.nsp-notif-dropdown-empty { padding:30px 16px; text-align:center; color:var(--text-3); font-size:13px; }
.nsp-notif-dropdown-item { display:flex; align-items:flex-start; gap:10px; padding:12px 16px; border-bottom:.5px solid var(--border); cursor:pointer; text-decoration:none; color:var(--text); }
.nsp-notif-dropdown-item:hover { background:var(--gray-50); }
.nsp-notif-dropdown-item:last-child { border-bottom:none; }
.nsp-notif-dropdown-icon { font-size:18px; flex-shrink:0; }
.nsp-notif-dropdown-text { font-size:12.5px; line-height:1.4; }
.nsp-notif-dropdown-text strong { display:block; margin-bottom:2px; }
.nsp-school-chip { display:flex;align-items:center;gap:8px;padding:5px 10px;border:.5px solid var(--border);border-radius:7px;cursor:pointer; }
.nsp-chip-avatar { width:28px;height:28px;background:var(--purple-600);border-radius:6px;display:flex;align-items:center;justify-content:center;color:#fff;font-size:14px; }
.nsp-chip-name { font-size:13px;font-weight:500; }
.nsp-content { padding:28px;flex:1; }

/* ── Page header ── */
.nsp-page-header { margin-bottom:22px; }
.nsp-page-header h1 { font-size:20px;font-weight:600; }
.nsp-page-header p { font-size:13px;color:var(--text-3);margin-top:3px; }

/* ── Stat cards ── */
.nsp-stats-grid { display:grid;grid-template-columns:repeat(5,1fr);gap:14px;margin-bottom:22px; }
.nsp-stats-grid.cols-4 { grid-template-columns:repeat(4,1fr); }
.nsp-stats-grid.cols-3 { grid-template-columns:repeat(3,1fr); }
.nsp-stat-card { background:var(--surface);border:.5px solid var(--border);border-radius:var(--radius);padding:14px 16px;display:flex;align-items:center;gap:14px;box-shadow:var(--card-shadow); }
.nsp-stat-icon { width:44px;height:44px;border-radius:10px;display:flex;align-items:center;justify-content:center;font-size:20px;flex-shrink:0; }
.nsp-stat-icon.purple{background:var(--purple-50);color:var(--purple-600);}
.nsp-stat-icon.teal{background:var(--teal-50);color:var(--teal-600);}
.nsp-stat-icon.amber{background:var(--amber-50);color:var(--amber-600);}
.nsp-stat-icon.blue{background:var(--blue-50);color:var(--blue-600);}
.nsp-stat-icon.red{background:var(--red-50);color:var(--red-600);}
.nsp-stat-num { font-size:22px;font-weight:700;line-height:1.1; }
.nsp-stat-label { font-size:12px;font-weight:500;color:var(--text);margin-top:1px; }
.nsp-stat-sub { font-size:11px;color:var(--text-3); }

/* ── Cards ── */
.nsp-card-el { background:var(--surface);border:.5px solid var(--border);border-radius:var(--radius);padding:18px;box-shadow:var(--card-shadow);overflow-x:auto; }
.nsp-card-header { display:flex;justify-content:space-between;align-items:center;margin-bottom:14px; }
.nsp-card-title { font-size:14px;font-weight:600; }
.nsp-view-all { font-size:12px;color:var(--purple-600);text-decoration:none;font-weight:500;cursor:pointer; }

.nsp-mid-grid { display:grid;grid-template-columns:1.1fr 1.3fr .9fr;gap:16px;margin-bottom:20px; }

.nsp-courses-table { width:100%;border-collapse:collapse;font-size:13px;min-width:480px; }
.nsp-courses-table th { text-align:left;color:var(--text-3);font-weight:600;font-size:11px;text-transform:uppercase;letter-spacing:.3px;padding:12px 16px;border-bottom:1px solid var(--border); }
.nsp-courses-table th:not(:first-child) { text-align:right; }
.nsp-courses-table td { padding:14px 16px;border-bottom:.5px solid var(--border);vertical-align:middle; }
.nsp-courses-table td:not(:first-child) { text-align:right; }
.nsp-courses-table tr:last-child td { border-bottom:none; }
.nsp-course-row { display:flex;align-items:center;gap:10px; }
.nsp-course-thumb { width:34px;height:34px;border-radius:7px;display:flex;align-items:center;justify-content:center;font-size:18px;flex-shrink:0;background:#e8f4fd;overflow:hidden; }
.nsp-course-thumb img { width:100%;height:100%;object-fit:cover; }
.nsp-course-name { font-weight:500;font-size:13px; }
.nsp-learner-count { font-size:12px;color:var(--text-3); }
.nsp-progress-bar-wrap { display:flex;align-items:center;gap:8px;justify-content:flex-end; }
.nsp-progress-bar { width:80px;height:5px;background:var(--gray-100);border-radius:99px;overflow:hidden; }
.nsp-progress-fill { height:100%;background:var(--purple-600);border-radius:99px; }
.nsp-pct-label { font-size:12px;font-weight:500;min-width:28px;text-align:right; }

.nsp-donut-wrap { display:flex;flex-direction:column;align-items:center; }
.nsp-donut-legend { width:100%;margin-top:12px; }
.nsp-legend-row { display:flex;align-items:center;justify-content:space-between;font-size:12px;margin:4px 0; }
.nsp-legend-dot { width:9px;height:9px;border-radius:50%;margin-right:6px;display:inline-block; }
.nsp-legend-label { display:flex;align-items:center;color:var(--text-2); }
.nsp-legend-val { font-weight:600;color:var(--text); }

.nsp-bottom-grid { display:grid;grid-template-columns:1.6fr .8fr;gap:16px; }
.nsp-right-stack { display:flex;flex-direction:column;gap:16px; }

.nsp-learner-table { width:100%;border-collapse:collapse;font-size:13px;min-width:640px; }
.nsp-learner-table th { text-align:left;color:var(--text-3);font-weight:600;font-size:11px;text-transform:uppercase;letter-spacing:.3px;padding:12px 16px;border-bottom:1px solid var(--border);white-space:nowrap; }
.nsp-learner-table td { padding:14px 16px;border-bottom:.5px solid var(--border);vertical-align:middle; }
.nsp-learner-table tr:last-child td { border-bottom:none; }
.nsp-learner-table tr:hover td { background:var(--gray-50); }
.nsp-table-scroll-wrap { overflow-x:auto; -webkit-overflow-scrolling:touch; border-radius:var(--radius); }
@media (max-width:900px) {
  .nsp-learner-table th, .nsp-learner-table td { padding:11px 14px; }
}
.nsp-learner-cell { display:flex;align-items:center;gap:9px; }
.nsp-learner-name { font-weight:500; }
.nsp-l-avatar { width:30px;height:30px;border-radius:50%;display:flex;align-items:center;justify-content:center;font-size:11px;font-weight:600;color:var(--purple-800);background:var(--purple-50);flex-shrink:0; }
.nsp-lp-bar { width:72px;height:5px;background:var(--gray-100);border-radius:99px;overflow:hidden; }
.nsp-lp-fill { height:100%;background:var(--purple-600);border-radius:99px; }
.nsp-lp-wrap { display:flex;align-items:center;gap:7px; }
.nsp-status-pill { font-size:11px;font-weight:500;padding:3px 9px;border-radius:99px; }
.nsp-status-pill.active{background:var(--green-50);color:var(--green-600);}
.nsp-status-pill.completed{background:var(--purple-50);color:var(--purple-600);}
.nsp-status-pill.inactive{background:var(--red-50);color:var(--red-600);}
.nsp-status-pill.paid{background:var(--green-50);color:var(--green-600);}
.nsp-status-pill.pending{background:var(--amber-50);color:var(--amber-600);}
.nsp-table-toolbar { display:flex;align-items:center;gap:8px;margin-bottom:14px;flex-wrap:wrap; }
.nsp-search-box { display:flex;align-items:center;gap:6px;border:.5px solid var(--border);border-radius:7px;padding:6px 10px;flex:1;min-width:140px;background:var(--surface); }
.nsp-search-box input { border:none;outline:none;font-size:13px;background:transparent;width:100%;color:var(--text); }
.nsp-tbl-select { font-size:13px;border:.5px solid var(--border);border-radius:7px;padding:6px 10px;background:var(--surface);color:var(--text);cursor:pointer; }
.nsp-export-btn { display:flex;align-items:center;gap:6px;font-size:13px;font-weight:500;color:var(--purple-600);border:.5px solid var(--purple-100);background:var(--purple-50);border-radius:7px;padding:6px 12px;cursor:pointer; }

.nsp-cert-list { list-style:none; }
.nsp-cert-item { display:flex;align-items:center;justify-content:space-between;padding:9px 0;border-bottom:.5px solid var(--border); }
.nsp-cert-item:last-child { border-bottom:none; }
.nsp-cert-avatar { width:32px;height:32px;border-radius:50%;display:flex;align-items:center;justify-content:center;font-size:11px;font-weight:600;color:var(--purple-800);background:var(--purple-50);flex-shrink:0; }
.nsp-cert-info { flex:1;margin-left:9px; }
.nsp-cert-name { font-weight:500;font-size:13px; }
.nsp-cert-course { font-size:11px;color:var(--text-3); }
.nsp-cert-date { font-size:11px;color:var(--text-3);margin-right:8px; }
.nsp-dl-btn { color:var(--text-3);background:none;border:none;cursor:pointer;font-size:17px; }
.nsp-dl-btn:hover { color:var(--purple-600); }

.nsp-notif-list { list-style:none; }
.nsp-notif-item { display:flex;align-items:flex-start;gap:9px;padding:9px 0;border-bottom:.5px solid var(--border); }
.nsp-notif-item:last-child { border-bottom:none; }
.nsp-notif-icon { width:28px;height:28px;border-radius:50%;display:flex;align-items:center;justify-content:center;font-size:14px;flex-shrink:0; }
.nsp-notif-icon.success{background:var(--green-50);color:var(--green-600);}
.nsp-notif-icon.warn{background:var(--amber-50);color:var(--amber-600);}
.nsp-notif-icon.info{background:var(--blue-50);color:var(--blue-600);}
.nsp-notif-icon.alert{background:var(--red-50);color:var(--red-600);}
.nsp-notif-text { flex:1;font-size:12.5px;line-height:1.4; }
.nsp-notif-time { font-size:11px;color:var(--text-3);white-space:nowrap; }

.nsp-actions-grid { display:grid;grid-template-columns:repeat(3,1fr);gap:14px;margin-top:20px; }
.nsp-action-card { background:var(--surface);border:.5px solid var(--border);border-radius:var(--radius);padding:16px;display:flex;flex-direction:column;align-items:flex-start;gap:10px; }
.nsp-action-icon { width:38px;height:38px;border-radius:9px;display:flex;align-items:center;justify-content:center;font-size:19px; }
.nsp-action-icon.purple{background:var(--purple-50);color:var(--purple-600);}
.nsp-action-icon.teal{background:var(--teal-50);color:var(--teal-600);}
.nsp-action-icon.blue{background:var(--blue-50);color:var(--blue-600);}
.nsp-action-icon.amber{background:var(--amber-50);color:var(--amber-600);}
.nsp-action-title { font-weight:600;font-size:13px; }
.nsp-action-desc { font-size:12px;color:var(--text-3); }
.nsp-action-btn { margin-top:6px;font-size:12px;font-weight:500;padding:6px 14px;border-radius:7px;border:.5px solid var(--border);background:var(--gray-50);color:var(--text);cursor:pointer; }
.nsp-action-btn:hover { background:var(--purple-50);border-color:var(--purple-100);color:var(--purple-800); }

.nsp-sub-days { font-size:28px;font-weight:700;color:var(--purple-600); }
.nsp-sub-days-label { font-size:11px;color:var(--text-3); }
.nsp-sub-btn { width:100%;padding:7px 16px;background:var(--purple-600);color:#fff;font-size:13px;font-weight:500;border-radius:7px;border:none;cursor:pointer; }
.nsp-sub-btn:hover { background:var(--purple-800); }

.nsp-breadcrumb { display:flex;align-items:center;gap:6px;font-size:12px;color:var(--text-3);margin-bottom:16px; }
.nsp-breadcrumb span { cursor:pointer; }
.nsp-breadcrumb span:hover { color:var(--purple-600); }
.nsp-breadcrumb .sep { color:var(--gray-200); }
.nsp-breadcrumb .current { color:var(--text-2);font-weight:500; }

.nsp-data-table { width:100%;border-collapse:collapse;font-size:13px;min-width:640px; }
.nsp-data-table th { text-align:left;color:var(--text-3);font-weight:600;font-size:11px;text-transform:uppercase;letter-spacing:.3px;padding:12px 16px;border-bottom:1px solid var(--border);white-space:nowrap; }
.nsp-data-table td { padding:14px 16px;border-bottom:.5px solid var(--border);vertical-align:middle; }
.nsp-data-table tr:last-child td { border-bottom:none; }
.nsp-data-table tbody tr:hover { background:var(--gray-50); }

.nsp-page { animation:nspFadeIn .18s ease; }
@keyframes nspFadeIn { from{opacity:0;transform:translateY(4px)} to{opacity:1;transform:translateY(0)} }

#nsp-toast { position:fixed;bottom:28px;right:28px;background:var(--purple-900);color:#fff;padding:10px 18px;border-radius:9px;font-size:13px;opacity:0;transform:translateY(8px);transition:all .25s;pointer-events:none;z-index:999; }
#nsp-toast.show { opacity:1;transform:translateY(0); }

.nsp-empty-page { display:flex;flex-direction:column;align-items:center;justify-content:center;min-height:300px;gap:12px;color:var(--text-3); }
.nsp-empty-page .nsp-empty-icon { font-size:48px;opacity:.3; }

/* ── Plan picker / checkout ── */
.nsp-plan-reco { background:var(--purple-50);border:1px solid var(--purple-200);border-radius:8px;padding:10px 14px;font-size:12.5px;margin-bottom:14px; }
.nsp-plans-grid { display:grid;grid-template-columns:repeat(auto-fit,minmax(230px,1fr));gap:18px;margin-top:8px;align-items:stretch; }
.nsp-plan-card {
  position:relative; border-radius:22px; cursor:pointer;
  transition:transform .15s, box-shadow .15s; background:var(--surface);
  box-shadow:0 1px 3px rgba(15,23,42,.08); display:flex; flex-direction:column; padding:10px;
  height:100%; /* fills the stretched grid row exactly — the button is never pushed past a card's own bounds by a taller sibling */
}
.nsp-plan-card:hover { transform:translateY(-3px); box-shadow:0 14px 30px rgba(15,23,42,.12); }
.nsp-plan-card.selected { box-shadow:0 0 0 2px var(--purple-600), 0 14px 30px rgba(217,89,7,.18); }

/* Inset gradient panel — badge + price live inside this, not the card edge */
.nsp-plan-top {
  border-radius:16px; padding:20px 18px 18px; position:relative;
  background:linear-gradient(135deg, var(--gray-100), var(--gray-50));
}
.nsp-plan-card.recommended .nsp-plan-top { background:linear-gradient(135deg, var(--purple-100), var(--purple-50)); }
.nsp-plan-badge {
  display:inline-block; background:rgba(15,23,42,.85); color:#fff;
  font-size:11px; font-weight:700; padding:4px 14px; border-radius:20px; letter-spacing:.2px; margin-bottom:16px;
}
.nsp-plan-card.recommended .nsp-plan-badge { background:var(--purple-800); }
.nsp-plan-price { display:flex; align-items:baseline; gap:4px; }
.nsp-plan-price-amt { font-size:34px; font-weight:800; color:var(--text); letter-spacing:-.5px; }
.nsp-plan-price-cycle { font-size:13px; color:var(--text-3); font-weight:600; }
.nsp-plan-summary { font-size:12px; color:var(--text-3); margin-top:6px; line-height:1.4; }

.nsp-plan-body { padding:18px 10px 6px; flex:1; }
.nsp-plan-seats-line { font-size:12px; color:var(--purple-600); font-weight:700; margin-bottom:10px; }
.nsp-plan-features { list-style:none; margin:0; padding:0; }
.nsp-plan-features li { font-size:13px; color:var(--text-2); padding:5px 0 5px 16px; line-height:1.4; position:relative; }
.nsp-plan-features li::before { content:'•'; position:absolute; left:2px; color:var(--text-3); font-weight:700; }

.nsp-plan-cta {
  width:calc(100% - 12px); margin:14px 6px 6px; padding:15px; font-size:14px; font-weight:700;
  color:#fff; cursor:pointer; background:#D95907; border:2px solid #D95907; border-radius:999px;
  transition:background .15s, color .15s, border-color .15s;
}
.nsp-plan-cta:hover, .nsp-plan-cta:active, .nsp-plan-cta:focus-visible {
  background:#fff; color:#D95907; border-color:#D95907;
}

.nsp-currency-toggle { display:flex;gap:8px;justify-content:center;margin:0 0 18px; }
.nsp-currency-btn { padding:7px 20px;border:1px solid var(--border);border-radius:20px;cursor:pointer;font-size:13px;font-weight:600;background:var(--surface); transition:background .15s,color .15s; }
.nsp-currency-btn.active { background:var(--purple-600);color:#fff;border-color:var(--purple-600); }

/* Course-selection step */
.nsp-course-pick-list { display:flex; flex-direction:column; gap:2px; max-height:280px; overflow-y:auto; border:1px solid var(--border); border-radius:10px; padding:6px; }
.nsp-course-pick-row { display:flex; align-items:center; gap:10px; padding:9px 10px; font-size:13.5px; border-radius:8px; cursor:pointer; }
.nsp-course-pick-row:hover { background:var(--gray-50); }

/* ── Modal ── */
.nsp-modal-overlay { position:fixed;inset:0;background:rgba(15,23,42,.6);z-index:9999;display:flex;align-items:center;justify-content:center;padding:20px; }
.nsp-modal-wide { max-width:760px !important; }
@media (max-width:640px) {
  .nsp-modal-wide { max-width:100% !important; }
  .nsp-plans-grid { grid-template-columns:1fr; }
  .nsp-modal-overlay { padding:10px; }
}
.nsp-modal { background:#fff;border-radius:var(--radius);width:100%;max-width:480px;max-height:88vh;overflow-y:auto;box-shadow:0 10px 40px rgba(0,0,0,.25); }
.nsp-modal-head { padding:16px 20px;border-bottom:.5px solid var(--border);display:flex;justify-content:space-between;align-items:center; }
.nsp-modal-close { background:none;border:none;font-size:18px;cursor:pointer;color:var(--text-3); }
.nsp-modal-body { padding:20px; }
.nsp-modal-foot { padding:14px 20px;border-top:.5px solid var(--border);display:flex;justify-content:flex-end;gap:8px; }

/* ── Form helpers (profile, plan admin) ── */
.nsp-field-row { display:flex;align-items:center;gap:12px;padding:10px 0;border-bottom:.5px solid var(--border); }
.nsp-field-icon { width:32px;height:32px;background:var(--purple-50);border-radius:7px;display:flex;align-items:center;justify-content:center;color:var(--purple-600);flex-shrink:0; }
.nsp-field-label { font-size:11px;color:var(--text-3); }
.nsp-field-input { width:100%;border:1px solid var(--border);border-radius:6px;padding:6px 10px;font-size:13px;margin-top:2px; }

.nsp-btn { display:inline-flex;align-items:center;gap:6px;padding:8px 16px;border-radius:7px;font-size:13px;font-weight:500;border:.5px solid var(--border);background:var(--surface);color:var(--text);cursor:pointer;text-decoration:none; }
.nsp-btn-primary { background:var(--purple-600);color:#fff;border-color:var(--purple-600); }
.nsp-btn-primary:hover { background:var(--purple-800); }
.nsp-btn:disabled { opacity:.6;cursor:not-allowed; }

/* ── Login / access notices ── */
.nsp-login-notice { max-width:480px;margin:60px auto;text-align:center;padding:30px;background:var(--purple-50);border-left:4px solid var(--purple-600);border-radius:8px; }

/* ── Join page ── */
.nsp-join-wrap { min-height:60vh;display:flex;align-items:center;justify-content:center;padding:40px 20px; }
.nsp-join-card { background:#fff;border:.5px solid var(--border);border-radius:14px;padding:32px;max-width:380px;width:100%;box-shadow:0 4px 20px rgba(0,0,0,.06); }
.nsp-join-card h2 { font-size:19px;margin-bottom:6px;color:var(--purple-900); }
.nsp-join-card p { font-size:13px;color:var(--text-3);margin-bottom:18px; }
.nsp-form-row { margin-bottom:14px; }
.nsp-form-row label { display:block;font-size:12px;font-weight:600;color:var(--text-2);margin-bottom:5px; }
.nsp-input { width:100%;padding:9px 12px;border:1px solid var(--border);border-radius:7px;font-size:13px;font-family:inherit; }
.nsp-input:focus { outline:none;border-color:var(--purple-600); }

@media (max-width: 900px) {
  .nsp-mid-grid, .nsp-bottom-grid, .nsp-stats-grid { grid-template-columns: 1fr 1fr !important; }
  .nsp-actions-grid { grid-template-columns: 1fr !important; }
  .nsp-sub-grid { grid-template-columns: 1fr !important; }
}
@media (max-width: 1024px) {
  .nsp-sidebar { transform:translateX(-100%); transition: transform .25s ease; box-shadow: 8px 0 24px rgba(15,23,42,0.15); }
  .nsp-sidebar.nsp-mobile-open { transform: translateX(0); }
  .nsp-main { margin-left:0; }
  .nsp-mobile-menu-btn { display: flex !important; }
}
@media (max-width: 640px) {
  .nsp-stats-grid, .nsp-mid-grid, .nsp-bottom-grid { grid-template-columns: 1fr !important; }
}

/* ── Mobile menu toggle (hidden on desktop — there was previously no way
   at all to reopen the sidebar on mobile once it auto-hid) ── */
.nsp-mobile-menu-btn {
  display: none; width: 36px; height: 36px; align-items: center; justify-content: center;
  background: none; border: 1px solid var(--border); border-radius: var(--radius-s);
  cursor: pointer; font-size: 18px; color: var(--text-2); flex-shrink: 0; margin-right: 8px;
}
.nsp-mobile-menu-btn:hover { background: var(--gray-50); }
.nsp-sidebar-backdrop { display: none; }
@media (max-width: 1024px) {
  .nsp-sidebar-backdrop {
    display: none; position: fixed; inset: 0; background: rgba(15,23,42,0.4); z-index: 49;
  }
  .nsp-sidebar-backdrop.nsp-mobile-open { display: block; }
}

/* ══ NEDU Icon Badge standard ═══════════════════════════════════════════════
   Every UI icon is a tile: #D95907 background, #fff glyph. On hover it flips:
   #fff background, #D95907 glyph, with a 1px #D95907 ring so the white tile
   stays visible on white surfaces. Hover is triggered by the icon itself or by
   whatever clickable/card surface it sits in. Icons that already sit on an
   orange surface (orange buttons) stay a bare white glyph — an orange tile on
   orange would vanish — and flip with the button (white button, orange glyph). */
i.ti {
  box-sizing: content-box;
  display: inline-flex; align-items: center; justify-content: center;
  width: 1em; height: 1em; padding: .3em; line-height: 1; vertical-align: middle;
  border-radius: .4em; background: #D95907; color: #fff;
  box-shadow: inset 0 0 0 1px #D95907;
  transition: background-color .15s ease, color .15s ease;
}
i.ti:hover,
a:hover > i.ti, button:hover:not(:disabled) > i.ti, li:hover > a > i.ti,
.nsp-btn:hover i.ti, .nsp-export-btn:hover i.ti, .nsp-search-box:hover i.ti,
.nsp-notif-dropdown-item:hover i.ti, .nsp-school-chip:hover i.ti, .nsp-notif-btn:hover i.ti {
  background: #fff; color: #D95907;
}
/* Tile containers that already carry their own square (stat cards, action
   cards, field rows, school logo, chip avatar): the container IS the tile, so
   the glyph inside is bare and inherits its colour. All the old pastel
   per-colour variants resolve to the one brand tile. */
.nsp-stat-icon[class], .nsp-action-icon[class], .nsp-field-icon[class], .nsp-notif-icon[class],
.nsp-school-icon[class], .nsp-chip-avatar[class] {
  background: #D95907; color: #fff; box-shadow: inset 0 0 0 1px #D95907;
  transition: background-color .15s ease, color .15s ease;
}
.nsp-stat-icon i.ti, .nsp-action-icon i.ti, .nsp-field-icon i.ti, .nsp-notif-icon i.ti,
.nsp-school-icon i.ti, .nsp-chip-avatar i.ti, .nsp-sub-btn i.ti, .nsp-btn-primary i.ti,
.nsp-empty-icon i.ti {
  background: transparent !important; box-shadow: none; padding: 0; border-radius: 0;
  color: inherit !important; width: auto; height: auto;
}
.nsp-stat-card:hover .nsp-stat-icon[class], .nsp-stat-icon[class]:hover,
.nsp-action-card:hover .nsp-action-icon[class], .nsp-action-icon[class]:hover,
.nsp-field-row:hover .nsp-field-icon[class], .nsp-field-icon[class]:hover,
.nsp-school-icon[class]:hover, .nsp-school-badge:hover .nsp-school-icon[class],
.nsp-chip-avatar[class]:hover, .nsp-school-chip:hover .nsp-chip-avatar[class] {
  background: #fff; color: #D95907;
}
/* Empty-state / loading icon: a real tile instead of a faded glyph. */
.nsp-empty-page .nsp-empty-icon {
  opacity: 1; font-size: 28px; width: 64px; height: 64px; border-radius: 16px;
  display: flex; align-items: center; justify-content: center;
  background: #D95907; color: #fff; box-shadow: inset 0 0 0 1px #D95907;
  transition: background-color .15s ease, color .15s ease;
}
.nsp-empty-page:hover .nsp-empty-icon { background: #fff; color: #D95907; }
/* Orange buttons flip with the same rule as the LMS primary buttons. */
.nsp-sub-btn:hover, .nsp-btn-primary:hover { background: #fff; color: #D95907; box-shadow: inset 0 0 0 1px #D95907; }
.nsp-learner-remove-btn i.ti, .nsp-modal-close i.ti { font-size: 14px; }

.nsp-brand-logo{display:block;height:32px;width:auto;max-width:100%;margin-bottom:2px;}
