/* ======================================================
   CRT NEON OVERRIDES — FINAL STABLE VERSION
   ====================================================== */

:root {
  --accent: #00f6ff;
  --accent-alt: #00c0cc;
  --bg: #04070a;
  --panel: #050b10;
  --border: rgba(0,246,255,.35);
  --text-main: #00f6ff;
}

/* =====================
   BASE COLORS
   ===================== */

body {
  background: var(--bg);
  color: var(--text-main);
}

/* Links */
a {
  color: var(--accent);
}

a:hover {
  color: var(--accent);
  text-shadow: 0 0 6px var(--accent);
}

/* Headers */
h1, h2, h3, h4 {
  color: var(--accent);
  text-shadow: 0 0 6px var(--accent);
}

/* Panels / cards */
.card, .panel {
  background: var(--panel);
  border: 1px solid var(--border);
}

/* Notices */
.notices {
  border-left: 3px solid var(--accent);
  background: rgba(0,246,255,.05);
}

/* =====================
   NAVIGATION / HEADER
   ===================== */

/* Remove Grav logo visually */
.navbar-brand {
  display: none;
}

/* Full-width container override (header only) */
.header .container,
.navbar .container {
  max-width: none;
  width: 100%;
  padding-left: 2rem;
  padding-right: 2rem;
}

/* Header base */
.header,
.navbar {
  position: relative;
  overflow: visible; /* REQUIRED for dropdowns */
  background: transparent;
}

/* =====================
   CRT NEON BACKDROP
   ===================== */

/* Horizon glow — HORIZONTAL */
.header::before,
.navbar::before {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 100vw;
  height: 90px;
  transform: translateX(-50%);
  background: linear-gradient(
    to top,
    rgba(0,246,255,.45),
    rgba(255,0,180,.55),
    rgba(255,100,255,.25),
    transparent 75%
  );
  filter: blur(8px);
  pointer-events: none;
}

/* 80s retro grid */
.header::after,
.navbar::after {
  content: "";
  position: absolute;
  bottom: -60px;
  left: 50%;
  width: 100vw;
  height: 160px;
  transform: translateX(-50%) perspective(500px) rotateX(70deg);
  background:
    linear-gradient(rgba(0,246,255,.45) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,246,255,.45) 1px, transparent 1px);
  background-size: 40px 24px;
  opacity: 0.45;
  pointer-events: none;
}

/* Subtle CRT scanlines (header only) */
.header {
  background-image:
    repeating-linear-gradient(
      to bottom,
      rgba(255,255,255,.02),
      rgba(255,255,255,.02) 1px,
      transparent 3px
    );
  box-shadow: 0 8px 40px rgba(255,0,200,.35);
}

/* =====================
   MENU STYLING
   ===================== */

.navbar a,
.menu a {
  color: var(--accent);
  text-shadow:
    0 0 6px rgba(0,246,255,.9),
    0 0 12px rgba(0,246,255,.4);
}

.menu a {
  text-decoration: none;
}

.menu a:hover {
  background: rgba(0,246,255,.15);
  box-shadow: inset 0 0 12px rgba(0,246,255,.35);
}

/* =====================
   DROPDOWNS (FIXED)
   ===================== */

.main-menu li {
  position: relative;
}

.main-menu ul ul {
  position: absolute;
  top: calc(100% - 2px);
  left: 0;
  display: none;
  min-width: 220px;
  background: #04070a;
  border: 1px solid rgba(0,246,255,.6);
  z-index: 1000;
}

/* ✅ THIS LINE WAS THE BUG — NOW FIXED */
.main-menu li.has-children:hover > ul {
  display: block;
}
/* Remove background from the first notice below the header */
main .notices:first-of-type {
  background: transparent;
  border-left-color: var(--accent);
}
/* Neutralize panel styling directly after header */
.header + main .panel:first-child {
  background: transparent;
  border: none;
}
/* Remove excessive top spacing under header */
main {
  margin-top: 0;
}

main > *:first-child {
  margin-top: 1rem;
}
/* Flat CRT notices styling */
.notices {
  background: rgba(0,246,255,.04);
  border-left: 2px solid var(--accent);
  box-shadow: none;
}


/* ==================================================
   PURE ASCII TERMINAL NOTICES — ALIGNED & TIGHT
   ================================================== */

.notices {
  font-family: "Courier New", monospace;
  font-size: 0.95rem;
  line-height: 1.1;
  background: transparent;
  border: none;
  padding: 0;
  margin: 0.8rem 0;
  color: var(--accent);
}

/* REMOVE ALL DEFAULT FLOW SPACING */
.notices p {
  margin: 0;
  padding: 0;
}

/* TOP BORDER */
.notices::before {
  content: "+--------------------------------------------------+";
  display: block;
}

/* CONTENT LINE */
.notices p:first-child::before {
  content: "| [NOTICE] ";
}

/* BLINKING CURSOR — ALWAYS */
.notices p:first-child::after {
  content: " █";
  animation: crt-cursor-blink 1.1s steps(1) infinite;
}

/* BOTTOM BORDER */
.notices::after {
  content: "+--------------------------------------------------+";
  display: block;
}

/* ==========================
   VARIANTS
   ========================== */

.notices.info p:first-child::before {
  content: "| [INFO  ] ";
}

.notices.success {
  color: #00ff9c;
}
.notices.success p:first-child::before {
  content: "| [ OK   ] ";
}

.notices.warning {
  color: #ffb000;
}
.notices.warning p:first-child::before {
  content: "| [ WARN ] ";
}

.notices.error {
  color: #ff4d6d;
}
.notices.error p:first-child::before {
  content: "| [ERROR] ";
}

/* ==========================
   CURSOR ANIMATION
   ========================== */

@keyframes crt-cursor-blink {
  0%, 49% { opacity: 1; }
  50%, 100% { opacity: 0; }
}






/* ==================================================
   PURE ASCII TERMINAL PARAGRAPHS
   ================================================== */

/* Target normal content only */
main p {
  position: relative;
  display: block;
  font-family: "Courier New", monospace;
  font-size: 0.95rem;
  line-height: 1.2;
  padding: 0.2rem 2ch;
  margin: 1rem 0;
  color: var(--accent);
}

/* TOP ASCII BORDER */
main p::before {
  content: "+--------------------------------------------------+";
  display: block;
  padding-bottom: 0.25rem;
}

/* BOTTOM ASCII BORDER */
main p::after {
  content: "+--------------------------------------------------+";
  display: block;
  padding-top: 0.25rem;
}

/* LEFT ASCII PIPE FOR CONTENT LINE */
main p {
  padding-left: 2ch;
}

main p::selection {
  background: rgba(0,246,255,.25);
}

/* VISUAL PIPE (conceptual, not structural) */
main p::marker {
  display: none;
}
