/* ==========================================================================
   NAMS UNEC Portal - theme layer
   Loaded AFTER style.css on every page. Two looks, switched by the admin in
   Admin -> Gear -> Site Theme:  html[data-theme="blue"]  and  [data-theme="white"].
   Everything is driven by CSS variables, so the whole site changes at once.
   ========================================================================== */

:root {
  --font: 'Poppins', 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --radius: 14px;
}

/* ---------- BLUE theme (default) ---------- */
html[data-theme="blue"] {
  --bg: #2563eb;
  --surface: rgba(255,255,255,0.12);
  --surface-solid: #1d4ed8;
  --text: #ffffff;
  --text-muted: rgba(255,255,255,0.78);
  --border: rgba(255,255,255,0.20);
  --primary: #0f172a;
  --primary-dark: #ffffff;
  --primary-light: rgba(255,255,255,0.28);
  --inset: rgba(255,255,255,0.10);
  --chrome: rgba(10,30,100,0.38);
  --chrome-solid: #1e46b8;
  --chrome-text: #ffffff;
  --btn-bg: #0f172a;
  --btn-bg-hover: #1e293b;
  --btn-text: #ffffff;
  --shadow: 0 8px 28px rgba(8,25,90,0.22);
  --page-bg: #2563eb;
  --link: #ffffff;
  --accent-text: #ffffff;
  color-scheme: dark;
}

/* ---------- WHITE theme ---------- */
html[data-theme="white"] {
  --bg: #f1f5f9;
  --surface: #ffffff;
  --surface-solid: #ffffff;
  --text: #1e293b;
  --text-muted: #64748b;
  --border: #e2e8f0;
  --primary: #2563eb;
  --primary-dark: #1d4ed8;
  --primary-light: #60a5fa;
  --inset: #f1f5f9;
  --chrome: #2563eb;
  --chrome-solid: #2563eb;
  --chrome-text: #ffffff;
  --btn-bg: #2563eb;
  --btn-bg-hover: #1d4ed8;
  --btn-text: #ffffff;
  --shadow: 0 2px 10px rgba(15,23,42,0.07);
  --page-bg: #ffffff;
  --link: #1d4ed8;
  --accent-text: #2563eb;
  color-scheme: light;
}

/* ---------- Base ---------- */
html[data-theme] body {
  font-family: var(--font);
  background: var(--page-bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
}
html[data-theme="blue"] body {
  background: radial-gradient(1200px 600px at 85% -10%, #3b82f6 0%, rgba(59,130,246,0) 60%), #2563eb;
  background-attachment: fixed;
}
/* zero-specificity default, so button classes (text-white, .btn ...) always win */
:where(html[data-theme] a) { color: var(--link); }
html[data-theme] h1, html[data-theme] h2, html[data-theme] h3, html[data-theme] h4 { font-family: var(--font); letter-spacing: -0.01em; }
html[data-theme="white"] .page-header h1,
html[data-theme="white"] .card h2,
html[data-theme="white"] .card h3 { color: var(--accent-text); }
html[data-theme] .page-header h1 { font-weight: 700; }
html[data-theme] .hint { color: var(--text-muted); }

/* ---------- Top bar (phones) & brand ---------- */
html[data-theme] .navbar {
  background: var(--chrome);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  box-shadow: none;
  border-bottom: 1px solid rgba(255,255,255,0.12);
}
html[data-theme] .navbar-brand { color: #fff; font-weight: 700; }
html[data-theme] .navbar-brand img,
html[data-theme] .brand-logo-img,
html[data-theme] .mobile-menu-header img {
  background: #fff;
  border-radius: 50% !important;
  object-fit: contain !important;
  padding: 3px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.18);
}
html[data-theme] .navbar-toggle { background: rgba(255,255,255,0.16); border-radius: 12px; }

/* ---------- Sidebar (tablet/desktop) ---------- */
html[data-theme="blue"] .sidebar {
  background: linear-gradient(180deg, #1d4ed8 0%, #1e3fa8 100%);
  border-right: 1px solid rgba(255,255,255,0.12);
}
html[data-theme="white"] .sidebar {
  background: #ffffff;
  border-right: 1px solid var(--border);
}
html[data-theme] .brand-name { color: var(--text); font-weight: 700; }
html[data-theme] .brand-tagline { color: var(--text-muted); }
html[data-theme] .nav-label { color: var(--text-muted); letter-spacing: .08em; }
html[data-theme] .nav-item { color: var(--text); border-radius: 12px; font-weight: 500; }
html[data-theme="blue"] .nav-item:hover,
html[data-theme="blue"] .mobile-menu-link:hover { background: rgba(255,255,255,0.14); }
html[data-theme="blue"] .nav-item.active,
html[data-theme="blue"] .mobile-menu-link.active { background: rgba(255,255,255,0.24); color: #fff; box-shadow: none; }
html[data-theme="white"] .nav-item:hover,
html[data-theme="white"] .mobile-menu-link:hover { background: #eff6ff; }
html[data-theme="white"] .nav-item.active,
html[data-theme="white"] .mobile-menu-link.active { background: #2563eb; color: #fff; box-shadow: 0 4px 12px rgba(37,99,235,0.28); }
html[data-theme] .sidebar-user { background: var(--inset); }
html[data-theme] .sidebar-avatar { background: #fff; color: #2563eb; }
html[data-theme="white"] .sidebar-avatar { background: #dbeafe; }
html[data-theme] .nav-badge, html[data-theme] .navbar-toggle-badge { background: #ef4444; color: #fff; }

/* ---------- Mobile slide-in menu (needs a solid panel) ---------- */
html[data-theme="blue"] .mobile-menu { background: #1e46b8; color: #fff; }
html[data-theme="white"] .mobile-menu { background: #ffffff; color: var(--text); }
html[data-theme] .mobile-menu-link { color: var(--text); border-radius: 12px; }
html[data-theme] .mobile-menu-link-primary { background: var(--inset); color: var(--text); }
html[data-theme="blue"] .mobile-menu-header { background: rgba(255,255,255,0.08); }
html[data-theme] .mobile-menu-user { color: var(--text); }

/* ---------- Cards ---------- */
html[data-theme] .card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  color: var(--text);
}
html[data-theme="blue"] .card { -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
html[data-theme] .directory-card,
html[data-theme] .material-card,
html[data-theme] .level-group-box,
html[data-theme] .cgpa-box,
html[data-theme] .official-photo,
html[data-theme] .thread-preview { background: var(--inset); border-color: var(--border); color: var(--text); }
html[data-theme] .profile-hero { background: var(--surface); border: 1px solid var(--border); }
html[data-theme] .stat-box { background: var(--inset); border: 1px solid var(--border); border-radius: 14px; }
html[data-theme] .stat-box .num { color: var(--text); font-weight: 700; }
html[data-theme="white"] .stat-box .num { color: #2563eb; }

/* ---------- Buttons ---------- */
html[data-theme] .btn {
  background: var(--btn-bg);
  color: var(--btn-text);
  border-radius: 12px;
  font-family: var(--font);
  font-weight: 600;
  box-shadow: 0 4px 14px rgba(15,23,42,0.18);
}
html[data-theme] .btn:hover { background: var(--btn-bg-hover); color: var(--btn-text); }
html[data-theme] .btn-outline {
  background: transparent;
  color: var(--text);
  border: 1.5px solid var(--border);
  box-shadow: none;
}
html[data-theme="blue"] .btn-outline { border-color: rgba(255,255,255,0.55); color: #fff; }
html[data-theme="blue"] .btn-outline:hover { background: rgba(255,255,255,0.16); color: #fff; }
html[data-theme="white"] .btn-outline { border-color: #2563eb; color: #2563eb; }
html[data-theme="white"] .btn-outline:hover { background: #2563eb; color: #fff; }
html[data-theme] .btn-danger { background: #dc2626; color: #fff; }

/* ---------- Forms ---------- */
html[data-theme] label { color: var(--text); font-weight: 500; }
html[data-theme] input[type=text], html[data-theme] input[type=email], html[data-theme] input[type=password],
html[data-theme] input[type=number], html[data-theme] input[type=date], html[data-theme] input[type=tel],
html[data-theme] input[type=search], html[data-theme] input[type=url], html[data-theme] input[type=time],
html[data-theme] select, html[data-theme] textarea {
  font-family: var(--font);
  border-radius: 12px;
  color: var(--text);
}
html[data-theme="blue"] input[type=text], html[data-theme="blue"] input[type=email], html[data-theme="blue"] input[type=password],
html[data-theme="blue"] input[type=number], html[data-theme="blue"] input[type=date], html[data-theme="blue"] input[type=tel],
html[data-theme="blue"] input[type=search], html[data-theme="blue"] input[type=url], html[data-theme="blue"] input[type=time],
html[data-theme="blue"] select, html[data-theme="blue"] textarea {
  background: rgba(255,255,255,0.10);
  border: 1px solid rgba(255,255,255,0.35);
  color: #fff;
}
html[data-theme="blue"] ::placeholder { color: rgba(255,255,255,0.55); }
html[data-theme="blue"] select option { color: #0f172a; background: #fff; }
html[data-theme="blue"] input:focus, html[data-theme="blue"] select:focus, html[data-theme="blue"] textarea:focus {
  outline: none; border-color: #fff; box-shadow: 0 0 0 3px rgba(255,255,255,0.22);
}
html[data-theme="white"] input:focus, html[data-theme="white"] select:focus, html[data-theme="white"] textarea:focus {
  outline: none; border-color: #2563eb; box-shadow: 0 0 0 3px rgba(37,99,235,0.15);
}
html[data-theme] .pwd-toggle { color: var(--text-muted); }

/* ---------- Tables ---------- */
html[data-theme] th { color: var(--text-muted); }
html[data-theme] th, html[data-theme] td { border-bottom-color: var(--border); }
html[data-theme="blue"] tr:hover td { background: rgba(255,255,255,0.06); }

/* ---------- Badges & alerts ---------- */
html[data-theme] .badge { border-radius: 999px; font-weight: 600; }
html[data-theme="blue"] .badge-admin { background: #0f172a; color: #fff; }
html[data-theme="blue"] .badge-muted, html[data-theme="blue"] .class-badge-muted { background: rgba(255,255,255,0.16); color: #fff; }
html[data-theme] .alert { border-radius: 12px; }

/* ---------- Footer ---------- */
html[data-theme] .site-footer { background: transparent; color: var(--text-muted); border-top: 1px solid var(--border); }

/* ==========================================================================
   Login / Register / Forgot password
   ========================================================================== */
html[data-theme] body.auth-page {
  min-height: 100vh; margin: 0; padding: 24px 16px;
  display: flex; align-items: center; justify-content: center;
}
html[data-theme="white"] body.auth-page { background: linear-gradient(180deg, #eff6ff 0%, #ffffff 60%); }
html[data-theme] .auth-card {
  width: 100%; max-width: 420px;
  border-radius: 24px; padding: 34px 28px 26px;
  position: relative;
}
html[data-theme="blue"] .auth-card {
  background: #2f7df0; border: 1px solid rgba(255,255,255,0.22);
  box-shadow: 0 18px 50px rgba(6,24,90,0.35); color: #fff;
}
html[data-theme="white"] .auth-card {
  background: #fff; border: 1px solid #e2e8f0;
  box-shadow: 0 18px 50px rgba(37,99,235,0.12);
}
.auth-logo {
  width: 92px; height: 92px; margin: 0 auto 14px;
  background: #fff; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 6px 20px rgba(0,0,0,0.18);
}
.auth-logo img { width: 78px; height: 78px; object-fit: contain; display: block; }
html[data-theme] .auth-card h1 { text-align: center; font-size: 1.55rem; font-weight: 700; margin: 0 0 6px; }
html[data-theme="white"] .auth-card h1 { color: #1d4ed8; }
html[data-theme] .auth-sub { text-align: center; color: var(--text-muted); font-size: .85rem; margin: 0 0 22px; }
/* underlined inputs, like the sample sign-in screen */
html[data-theme="blue"] .auth-card input[type=text], html[data-theme="blue"] .auth-card input[type=email],
html[data-theme="blue"] .auth-card input[type=password], html[data-theme="blue"] .auth-card input[type=date],
html[data-theme="blue"] .auth-card select {
  background: transparent; border: none; border-bottom: 1.5px solid rgba(255,255,255,0.6);
  border-radius: 0; padding-left: 2px; padding-right: 2px;
}
html[data-theme="blue"] .auth-card input:focus, html[data-theme="blue"] .auth-card select:focus { box-shadow: none; border-bottom-color: #fff; }
html[data-theme="white"] .auth-card input[type=text], html[data-theme="white"] .auth-card input[type=email],
html[data-theme="white"] .auth-card input[type=password], html[data-theme="white"] .auth-card input[type=date],
html[data-theme="white"] .auth-card select {
  background: #f8fafc; border: 1.5px solid #e2e8f0;
}
html[data-theme] .auth-card a { font-weight: 500; }
html[data-theme="blue"] .auth-card a { color: #fff; text-decoration: underline; }
html[data-theme="blue"] .auth-card .btn { background: #fff; color: #1d4ed8; box-shadow: 0 6px 18px rgba(6,24,90,0.28); }
html[data-theme="blue"] .auth-card .btn:hover { background: #eaf2ff; color: #1d4ed8; }
html[data-theme="blue"] .auth-card .alert-danger { background: #fee2e2; color: #b91c1c; }
html[data-theme] .auth-footer-note { border-top: 1px solid var(--border); color: var(--text-muted); }

/* ==========================================================================
   Dashboard header (matches the sample dashboards)
   ========================================================================== */
.profile-header { text-align: center; margin: 6px 0 22px; }
.profile-header .avatar-lg {
  width: 84px; height: 84px; border-radius: 50%; margin: 0 auto 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.8rem; font-weight: 700; overflow: hidden;
}
html[data-theme="blue"] .profile-header .avatar-lg { background: #fff; color: #2563eb; }
html[data-theme="white"] .profile-header .avatar-lg { background: #dbeafe; color: #2563eb; }
.profile-header .avatar-lg img { width: 100%; height: 100%; object-fit: cover; }
.profile-header .name { font-size: 1.7rem; font-weight: 700; margin: 0; line-height: 1.2; }
html[data-theme="white"] .profile-header .name { color: #2563eb; }
.profile-header .reg-number { color: var(--text-muted); margin: 4px 0 10px; font-size: .95rem; }
.profile-header .role-badge {
  display: inline-block; padding: 4px 16px; border-radius: 999px; font-size: .8rem; font-weight: 600;
}
html[data-theme="blue"] .profile-header .role-badge { background: rgba(255,255,255,0.22); color: #fff; }
html[data-theme="white"] .profile-header .role-badge { background: #2563eb; color: #fff; }

/* ==========================================================================
   Home page (public) - sample "New UI" look
   ========================================================================== */
html[data-theme] body.home-body { background: var(--page-bg); }
html[data-theme="blue"] body.home-body { background: #1e6fd9; }
.home-header {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 14px 20px;
  background: var(--chrome); color: #fff;
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
}
html[data-theme="white"] .home-header { box-shadow: 0 2px 12px rgba(37,99,235,0.25); }
.home-brand { display: flex; align-items: center; gap: 12px; color: #fff !important; text-decoration: none !important; font-weight: 700; font-size: 1.05rem; }
.home-brand .logo-circle { width: 44px; height: 44px; border-radius: 50%; background: #fff; display: flex; align-items: center; justify-content: center; flex-shrink: 0; box-shadow: 0 2px 10px rgba(0,0,0,.2); }
.home-brand .logo-circle img { width: 36px; height: 36px; object-fit: contain; }
.home-actions { display: flex; align-items: center; gap: 8px; }
.home-actions a.pill {
  padding: 8px 16px; border-radius: 999px; font-size: .85rem; font-weight: 600; text-decoration: none !important;
  color: #fff !important; border: 1.5px solid rgba(255,255,255,.7);
}
.home-actions a.pill.solid { background: #fff; color: #1d4ed8 !important; border-color: #fff; }
.home-menu-btn { background: rgba(255,255,255,.18); border: none; color: #fff; width: 42px; height: 42px; border-radius: 12px; cursor: pointer; font-size: 1.2rem; }
.home-hero { text-align: center; padding: 56px 22px 46px; }
html[data-theme="blue"] .home-hero { color: #fff; }
html[data-theme="white"] .home-hero { color: #1e293b; }
.home-hero .hero-logo { width: 132px; height: 132px; margin: 0 auto 22px; border-radius: 50%; background: #fff; display: flex; align-items: center; justify-content: center; box-shadow: 0 14px 40px rgba(6,24,90,.3); }
.home-hero .hero-logo img { width: 112px; height: 112px; object-fit: contain; }
.home-hero h1 { font-size: clamp(1.9rem, 6vw, 3rem); font-weight: 700; margin: 0 0 12px; line-height: 1.15; }
html[data-theme="white"] .home-hero h1 { color: #2563eb; }
.home-hero p.lead { max-width: 560px; margin: 0 auto 26px; font-size: 1.02rem; opacity: .92; }
.home-hero .cta { display: inline-flex; gap: 12px; flex-wrap: wrap; justify-content: center; }
.home-hero .cta a { padding: 13px 28px; border-radius: 999px; font-weight: 600; text-decoration: none !important; font-size: .98rem; }
html[data-theme="blue"] .home-hero .cta a.primary { background: #fff; color: #1d4ed8 !important; box-shadow: 0 8px 22px rgba(6,24,90,.3); }
html[data-theme="blue"] .home-hero .cta a.ghost { border: 1.5px solid rgba(255,255,255,.8); color: #fff !important; }
html[data-theme="white"] .home-hero .cta a.primary { background: #2563eb; color: #fff !important; box-shadow: 0 8px 22px rgba(37,99,235,.3); }
html[data-theme="white"] .home-hero .cta a.ghost { border: 1.5px solid #2563eb; color: #2563eb !important; }
.home-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; max-width: 760px; margin: 38px auto 0; }
.home-stats .stat { border-radius: 18px; padding: 18px 10px; }
html[data-theme="blue"] .home-stats .stat { background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.22); }
html[data-theme="white"] .home-stats .stat { background: #eff6ff; border: 1px solid #dbeafe; }
.home-stats .stat .num { font-size: 1.8rem; font-weight: 700; }
html[data-theme="white"] .home-stats .stat .num { color: #2563eb; }
.home-stats .stat .lbl { font-size: .8rem; opacity: .85; }

/* ==========================================================================
   Official receipt (matches the NAMS paper receipt)
   ========================================================================== */
.receipt-sheet {
  position: relative; background: #fff; color: #0b3b8f;
  max-width: 794px; margin: 0 auto; padding: 34px 40px 30px;
  border: 3px solid #0b4ea2; border-radius: 6px;
  font-family: 'Poppins', Arial, sans-serif;
  overflow: hidden;
}
.receipt-sheet .wm {
  position: absolute; left: 50%; top: 52%; width: 440px; height: 440px;
  transform: translate(-50%, -50%); opacity: .07; pointer-events: none;
  background: url('../img/nams-logo.png') center/contain no-repeat;
}
.receipt-sheet > *:not(.wm) { position: relative; }
.rc-head { display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.rc-head img { height: 96px; width: auto; display: block; }
.rc-head .nams-l { width: 96px; height: 96px; object-fit: contain; }
.rc-title { text-align: center; flex: 1; }
.rc-title h2 { margin: 0 0 8px; font-size: 1.22rem; font-weight: 700; line-height: 1.25; color: #0b4ea2; letter-spacing: .01em; }
.rc-address { display: inline-block; border: 1.5px solid #0b4ea2; border-radius: 14px; padding: 8px 18px; font-size: .68rem; font-weight: 700; line-height: 1.5; color: #0b4ea2; }
.rc-meta { display: flex; justify-content: space-between; align-items: flex-end; margin-top: 22px; flex-wrap: wrap; gap: 10px; }
.rc-tag { background: #0b4ea2; color: #fff; font-weight: 700; font-size: .78rem; letter-spacing: .12em; padding: 8px 16px; border-radius: 4px; }
.rc-no { text-align: right; font-weight: 700; color: #0b4ea2; font-size: 1.02rem; }
.rc-no .n { font-family: 'Courier New', monospace; font-size: 1.3rem; letter-spacing: .06em; }
.rc-date { margin-top: 6px; font-weight: 700; color: #0b4ea2; }
.rc-date span { display: inline-block; min-width: 118px; text-align: center; background: #dbeafe; border-bottom: 2px solid #0b4ea2; padding: 3px 10px; }
.rc-line { display: flex; align-items: flex-end; gap: 10px; margin-top: 20px; font-weight: 700; color: #0b4ea2; }
.rc-line .k { white-space: nowrap; font-size: .92rem; }
.rc-line .v { flex: 1; border-bottom: 1.5px solid #0b4ea2; padding: 0 6px 3px; font-size: 1.02rem; color: #0a2f6b; }
.rc-sub { display: flex; justify-content: flex-end; gap: 0; font-weight: 700; color: #0b4ea2; font-size: .9rem; margin-top: 2px; }
.rc-sub .nb { border-bottom: 1.5px solid #0b4ea2; flex: 1; text-align: right; padding-right: 10px; }
.rc-sub .kb { border-bottom: 1.5px solid #0b4ea2; width: 120px; text-align: center; margin-left: 22px; }
.rc-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 26px; margin-top: 18px; align-items: start; }
.rc-left .rc-line { margin-top: 12px; }
.rc-amount { margin-top: 18px; display: flex; align-items: center; gap: 12px; border: 1.5px solid #0b4ea2; background: #dbeafe; border-radius: 8px; padding: 10px 14px; font-weight: 700; color: #0b4ea2; }
.rc-amount .big { font-size: 1.25rem; flex: 1; text-align: center; letter-spacing: .02em; }
.rc-levels { width: 100%; border-collapse: collapse; font-size: .86rem; }
.rc-levels th { background: #0b4ea2; color: #fff; padding: 8px; letter-spacing: .08em; font-size: .78rem; text-transform: none; border: 1px solid #0b4ea2; }
.rc-levels td { border: 1.5px solid #0b4ea2; padding: 7px 10px; font-weight: 700; color: #0b4ea2; height: 32px; }
.rc-levels td:last-child { text-align: center; font-size: 1.05rem; }
.rc-levels tr.on td { background: #e6f0ff; }
.rc-levels tr.total td { background: #dbeafe; }
.rc-sign { display: flex; justify-content: space-around; gap: 24px; margin-top: 44px; text-align: center; }
.rc-sign .s { width: 42%; }
.rc-sign .s img { height: 62px; width: auto; max-width: 100%; display: block; margin: 0 auto -6px; }
.rc-sign .s .ln { border-top: 2px dotted #0b4ea2; padding-top: 6px; font-style: italic; font-weight: 700; color: #0b4ea2; font-size: .92rem; }
.rc-foot { margin-top: 22px; padding-top: 10px; border-top: 1px solid #c7dbf5; display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; font-size: .66rem; color: #5b7fb5; }
.rc-status { display: inline-block; font-weight: 700; color: #15803d; }

@media (max-width: 640px) {
  .receipt-sheet { padding: 20px 14px; }
  .rc-head img, .rc-head .nams-l { height: 54px; width: 54px; }
  .rc-title h2 { font-size: .8rem; }
  .rc-address { font-size: .5rem; padding: 6px 8px; }
  .rc-grid { grid-template-columns: 1fr; }
  .rc-line .k { font-size: .76rem; } .rc-line .v { font-size: .88rem; }
  .rc-sub .kb { width: 70px; margin-left: 10px; }
  .rc-sign .s img { height: 48px; }
  .home-stats { grid-template-columns: 1fr; }
}

@media print {
  @page { size: A4; margin: 10mm; }
  html[data-theme] body { background: #fff !important; color: #000 !important; }
  .receipt-sheet { max-width: none; width: 100%; margin: 0; box-shadow: none; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .rc-grid { grid-template-columns: 1fr 1fr !important; }
  .rc-levels th, .rc-tag, .rc-amount, .rc-date span, .rc-levels tr.on td, .rc-levels tr.total td { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}

/* ---------- extras ---------- */
.auth-footer-note { text-align: center; margin-top: 24px; font-size: .78rem; padding-top: 16px; }
.home-nav-links { display: none; align-items: center; gap: 4px; }
.home-nav-links a { color: #fff !important; text-decoration: none !important; font-size: .85rem; font-weight: 500; padding: 8px 12px; border-radius: 10px; }
.home-nav-links a:hover { background: rgba(255,255,255,.16); }
@media (min-width: 1024px) { .home-nav-links { display: flex; } #mobile-toggle { display: none !important; } }
@media (max-width: 520px) { .home-actions a.pill.hide-sm { display: none; } .home-brand span.t { font-size: .95rem; } }
/* home page sections below the hero stay light, even in the blue theme */
body.home-body section[class*="bg-slate-50"] { background-color: #f8fafc !important; }

/* receipt table must ignore the site-wide table theming */
.receipt-sheet .rc-levels th, .receipt-sheet .rc-levels td { border: 1.5px solid #0b4ea2 !important; }
.receipt-sheet .rc-levels tr:hover td { background: inherit; }
.receipt-sheet .rc-levels tr.on td { background: #e6f0ff !important; }
.receipt-sheet .rc-levels tr.total td { background: #dbeafe !important; }
.receipt-sheet .rc-levels td { color: #0b4ea2 !important; }
html[data-theme] .auth-card input + .hint { margin: 2px 0 14px !important; }

/* ---------- Print page + compact receipt (always one A4 page) ---------- */
body.receipt-print-page { margin: 0; background: #fff; font-family: 'Poppins', Arial, sans-serif; }
.rp-bar { display: flex; align-items: center; gap: 14px; padding: 10px 20px; background: #0b4ea2; color: #fff; font-size: 14px; }
.rp-bar button { background: #fff; color: #0b4ea2; border: 0; border-radius: 8px; padding: 8px 16px; font-weight: 600; font-family: inherit; cursor: pointer; }
.rp-bar a { color: #fff; }
.receipt-print-page .receipt-sheet { margin: 14px auto; }
.receipt-sheet.compact { padding: 22px 30px 16px; max-width: 760px; }
.receipt-sheet.compact .wm { width: 330px; height: 330px; }
.receipt-sheet.compact .rc-head img { height: 74px; }
.receipt-sheet.compact .rc-head .nams-l { width: 74px; height: 74px; }
.receipt-sheet.compact .rc-title h2 { font-size: 1.02rem; margin-bottom: 6px; }
.receipt-sheet.compact .rc-address { font-size: .6rem; padding: 6px 14px; }
.receipt-sheet.compact .rc-meta { margin-top: 12px; }
.receipt-sheet.compact .rc-tag { font-size: .68rem; padding: 6px 12px; }
.receipt-sheet.compact .rc-no { font-size: .9rem; }
.receipt-sheet.compact .rc-no .n { font-size: 1.1rem; }
.receipt-sheet.compact .rc-date span { padding: 2px 8px; }
.receipt-sheet.compact .rc-line { margin-top: 12px; }
.receipt-sheet.compact .rc-line:first-of-type { margin-top: 26px; }
.receipt-sheet.compact .rc-line .k { font-size: .82rem; }
.receipt-sheet.compact .rc-line .v { font-size: .9rem; padding-bottom: 2px; }
.receipt-sheet.compact .rc-sub { font-size: .8rem; }
.receipt-sheet.compact .rc-grid { margin-top: 12px; gap: 20px; }
.receipt-sheet.compact .rc-amount { margin-top: 12px; padding: 6px 12px; }
.receipt-sheet.compact .rc-amount .big { font-size: 1.1rem; }
.receipt-sheet.compact .rc-levels { font-size: .76rem; }
.receipt-sheet.compact .rc-levels th { padding: 5px 8px; font-size: .7rem; }
.receipt-sheet.compact .rc-levels td { padding: 3px 8px; height: 24px; }
.receipt-sheet.compact .rc-sign { margin-top: 22px; }
.receipt-sheet.compact .rc-sign .s img { height: 50px; }
.receipt-sheet.compact .rc-sign .s .ln { font-size: .8rem; padding-top: 4px; }
.receipt-sheet.compact .rc-foot { margin-top: 12px; padding-top: 8px; font-size: .58rem; }
@media print {
  .rp-bar { display: none !important; }
  body.receipt-print-page { background: #fff; }
  .receipt-print-page .receipt-sheet { margin: 0 auto; page-break-inside: avoid; break-inside: avoid; }
  html, body { height: auto !important; }
  .alert { display: none !important; }
}
@media print {
  .receipt-sheet, .receipt-sheet.compact { max-width: 100% !important; width: 100% !important; box-sizing: border-box; }
}
.receipt-sheet .rc-levels th { color: #fff !important; background: #0b4ea2 !important; }

/* CGPA: Poppins Black (900) */
html[data-theme] .cgpa-value,
html[data-theme] .cgpa-num { font-family: 'Poppins', sans-serif; font-weight: 900; letter-spacing: -0.02em; }
html[data-theme] .stat-box .num.cgpa-value { font-size: 2.6rem; line-height: 1.1; }
html[data-theme] .cgpa-num { font-size: 1.9rem; }

/* chat send button: always a white arrow on a solid button (both themes, every phone) */
html[data-theme] .chat-send-btn { color: #fff; }
html[data-theme="blue"] .chat-send-btn { background: #0f172a; }
html[data-theme="white"] .chat-send-btn { background: #2563eb; }
html[data-theme] .chat-send-btn:hover { background: var(--btn-bg-hover); }
.chat-send-btn svg { width: 20px; height: 20px; display: block; margin-left: 2px; }
.chat-send-btn svg path { fill: #fff; }
