/* ═══════════════════════════════════════════════════════════════
   RJICT ACADEMY — Public Navigation (public-nav.css)
   Used by: index.php, courses.php, about.php, login.php, register.php
   Portal pages (student/tutor/admin) use nav.css instead.
   ═══════════════════════════════════════════════════════════════ */

/* ── TOPBAR ─────────────────────────────────────────────────────
   Fixed glass bar, full width, 66px tall.
   Dark: semi-transparent dark with backdrop blur.
   Light: warm parchment with soft shadow.
   ─────────────────────────────────────────────────────────────── */
nav#pubNav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 960;
  height: 66px;
  background: rgba(10, 12, 26, .88);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-bottom: 1px solid var(--line, rgba(255,255,255,.11));
  transition: background .3s;
}
[data-theme="light"] nav#pubNav {
  background: rgba(240, 236, 229, .94);
  box-shadow: 0 1px 8px rgba(0,0,0,.08);
}

/* ── INNER CONTAINER ──────────────────────────────────────────── */
.pnav-inner {
  max-width: 1300px;
  margin: 0 auto;
  padding: 0 44px;
  height: 100%;
  display: flex;
  align-items: center;
  gap: 32px;
  position: relative;
}
@media (max-width: 900px) {
  .pnav-inner { padding: 0 16px 0 20px; }
}

/* ── LOGO ─────────────────────────────────────────────────────── */
.pnav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex-shrink: 0;
}
.pnav-logo img {
  height: 44px;
  width: auto;
  object-fit: contain;
}
.pnav-name {
  font-family: var(--fd, 'Georgia', serif);
  font-size: 1rem;
  color: var(--text, #fff);
  white-space: nowrap;
}
.pnav-name em {
  font-style: normal;
  color: var(--gold, #d4920a);
}

/* ── DESKTOP CENTRED NAV LINKS ────────────────────────────────── */
.pnav-links {
  display: flex;
  gap: 32px;
  list-style: none;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}
@media (max-width: 900px) {
  .pnav-links { display: none; }
}
.pnav-links a {
  font-size: .78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.8px;
  color: var(--muted, rgba(210,218,245,.88));
  text-decoration: none;
  position: relative;
  padding-bottom: 3px;
  transition: color .2s;
}
.pnav-links a::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0;
  width: 0; height: 1.5px;
  background: var(--pink, #e8186d);
  transition: width .3s;
}
.pnav-links a:hover,
.pnav-links a.active { color: var(--pink, #e8186d); }
.pnav-links a:hover::after,
.pnav-links a.active::after { width: 100%; }

/* ── RIGHT-SIDE ACTIONS ──────────────────────────────────────── */
.pnav-end {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-left: auto;
}

/* Hide desktop CTA buttons on mobile */
@media (max-width: 900px) {
  .pnav-btn-desk { display: none !important; }
}

/* ── THEME TOGGLE PILL ────────────────────────────────────────── */
.pnav-toggle {
  display: flex;
  align-items: center;
  width: 44px; height: 24px;
  border-radius: 12px;
  border: 1.5px solid var(--line, rgba(255,255,255,.11));
  background: rgba(255,255,255,.05);
  cursor: pointer;
  position: relative;
  transition: background .3s, border-color .3s;
  flex-shrink: 0;
}
[data-theme="light"] .pnav-toggle {
  background: rgba(0,0,0,.06);
  border-color: rgba(0,0,0,.15);
}
.pnav-knob {
  position: absolute;
  left: 3px;
  width: 16px; height: 16px;
  border-radius: 50%;
  background: var(--muted, rgba(210,218,245,.88));
  transition: transform .3s, background .3s;
  display: flex;
  align-items: center;
  justify-content: center;
}
[data-theme="light"] .pnav-knob {
  transform: translateX(20px);
  background: var(--gold, #d4920a);
}
.pnav-knob .ico-sun { display: none; }
[data-theme="light"] .pnav-knob .ico-moon { display: none; }
[data-theme="light"] .pnav-knob .ico-sun  { display: block; }

/* ── HAMBURGER BUTTON ─────────────────────────────────────────── */
.pnav-ham {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: transparent;
  border: none;
  padding: 6px;
  cursor: pointer;
  flex-shrink: 0;
}
@media (max-width: 900px) {
  .pnav-ham { display: flex; }
}
.pnav-ham span {
  display: block;
  width: 22px; height: 2px;
  background: var(--text, #fff);
  border-radius: 2px;
  transition: transform .3s, opacity .2s;
}
.pnav-ham.open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
  background: var(--pink, #e8186d);
}
.pnav-ham.open span:nth-child(2) { opacity: 0; }
.pnav-ham.open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
  background: var(--pink, #e8186d);
}

/* ── FULLSCREEN MOBILE MENU OVERLAY ──────────────────────────── */
.pub-mob-nav {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 950;
  padding-top: 66px;
  background: rgba(10, 12, 26, .99);
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 28px;
}
[data-theme="light"] .pub-mob-nav {
  background: rgba(240, 236, 229, .99);
}
.pub-mob-nav.open { display: flex; }
.pub-mob-nav a {
  font-family: var(--fd, 'Georgia', serif);
  font-size: 1.5rem;
  color: var(--text, #fff);
  text-decoration: none;
  transition: color .2s;
}
.pub-mob-nav a:hover { color: var(--pink, #e8186d); }
.pub-mob-close {
  position: absolute;
  top: 20px; right: 22px;
  background: transparent;
  border: none;
  font-size: 1.4rem;
  color: var(--muted);
  cursor: pointer;
}

/* ── PAGE BODY OFFSET ─────────────────────────────────────────
   Pushes page content below the fixed 66px topbar.
   Applied to the outermost content wrapper on each public page.
   ─────────────────────────────────────────────────────────────── */
.pub-page-body {
  padding-top: 66px;
}
