:root {
  --bg: #05070d;
  --bg2: #080c14;
  --surface: rgba(8, 14, 24, 0.88);
  --surface2: rgba(12, 20, 36, 0.7);
  --accent: #00f5d4;
  --accent2: #0094ff;
  --gold: #f0c060;
  --danger: #ff4060;
  --glow-a: rgba(0, 245, 212, 0.18);
  --glow-b: rgba(0, 148, 255, 0.12);
  
  /* READABILITY TWEAK: Lightened text colors for better contrast */
  --text: #ffffff;
  --text-dim: #8da9c4; 
  --text-muted: #5a7b9c; 
  
  --border: rgba(0, 245, 212, 0.12);
  --border-bright: rgba(0, 245, 212, 0.35);
  --discord: #5865F2;
  --f-head: 'Exo 2', sans-serif;
  --f-ui: 'Rajdhani', sans-serif;
  --f-mono: 'Chakra Petch', monospace;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--f-ui);
  background: var(--bg);
  color: var(--text);
  overflow-x: hidden;
  /* READABILITY TWEAK: Increased line height and explicit font weight */
  line-height: 1.6;
  font-weight: 400; 
  letter-spacing: 0.02em;
}

/* ─── CANVAS BACKGROUND ─── */
#bg-canvas {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

/* ─── SCANLINE OVERLAY ─── */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 2px,
    rgba(0, 0, 0, 0.08) 2px,
    rgba(0, 0, 0, 0.08) 4px
  );
  background-size: 100% 4px;
  /* ANIMATION: Added slow scrolling to scanlines */
  animation: scanlineScroll 10s linear infinite;
}

/* ─── NAV ─── */
nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 900;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 2rem;
  height: 56px;
  background: rgba(5, 7, 13, 0.82);
  backdrop-filter: blur(20px) saturate(1.8);
  border-bottom: 1px solid var(--border);
}

.nav-logo {
  font-family: var(--f-head);
  font-weight: 900;
  font-size: 0.85rem;
  letter-spacing: 0.2em;
  color: var(--accent);
  text-decoration: none;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  height: 40px;
}

.nav-logo-image {
  height: 40px;
  width: auto;
  max-width: 150px;
  object-fit: contain;
  filter: drop-shadow(0 0 10px rgba(0, 245, 212, 0.2));
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.nav-logo:hover .nav-logo-image {
  filter: drop-shadow(0 0 25px rgba(0, 245, 212, 0.8));
  transform: scale(1.08);
}

.nav-logo span {
  color: var(--text-dim);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  list-style: none;
}

.nav-links a {
  font-family: var(--f-mono);
  font-size: 0.65rem; /* Slightly larger for readability */
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--text-dim);
  padding: 6px 14px;
  border: 1px solid transparent;
  transition: all 0.3s ease;
  position: relative;
}

.nav-links a:hover {
  color: var(--accent);
  border-color: var(--border);
  background: rgba(0, 245, 212, 0.08);
  text-shadow: 0 0 8px rgba(0, 245, 212, 0.5);
}

.nav-links a.external-link .arrow {
  display: inline-block;
  margin-left: 4px;
  transition: transform 0.3s ease, opacity 0.3s ease;
  opacity: 0.7;
}

.nav-links a.external-link:hover .arrow {
  transform: translateX(2px) translateY(-2px);
  opacity: 1;
}

.nav-links a.discord {
  color: #818cf8;
  border: 1px solid rgba(88, 101, 242, 0.3);
  border-radius: 3px;
}

.nav-links a.discord:hover {
  background: var(--discord);
  color: #fff;
  border-color: var(--discord);
  box-shadow: 0 0 15px rgba(88, 101, 242, 0.5);
}

/* ─── HERO ─── */
#hero {
  position: relative;
  z-index: 2;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 7rem 1rem 4rem;
  overflow: hidden;
  background: linear-gradient(180deg, rgba(0, 60, 80, 0.2) 0%, transparent 100%);
}

.hero-header-image {
  max-width: 90%;
  height: auto;
  max-height: 400px;
  margin-bottom: 2rem;
  opacity: 0;
  /* ANIMATION: Added floatBob for a continuous breathing effect */
  animation: fadeUp 0.8s 0.2s forwards, floatBob 6s ease-in-out 1s infinite;
  filter: drop-shadow(0 0 30px rgba(0, 245, 212, 0.3));
  transition: filter 0.5s ease;
}

.hero-header-image:hover {
  filter: drop-shadow(0 0 50px rgba(0, 245, 212, 0.6));
}

.hero-eyebrow {
  font-family: var(--f-mono);
  font-size: 0.65rem;
  letter-spacing: 0.35em;
  color: var(--accent);
  text-transform: uppercase;
  margin-bottom: 1.8rem;
  opacity: 0;
  animation: fadeUp 0.8s 0.35s forwards;
}

.hero-title {
  font-family: var(--f-head);
  font-weight: 900;
  font-size: clamp(3rem, 12vw, 8rem);
  line-height: 0.88;
  letter-spacing: -0.02em;
  text-transform: uppercase;
  opacity: 0;
  animation: fadeUp 0.8s 0.5s forwards;
}

.hero-title .line1 {
  color: var(--text);
}

.hero-title .line2 {
  color: transparent;
  -webkit-text-stroke: 1.5px var(--accent);
  display: block;
  margin-top: 0.05em;
  /* ANIMATION: subtle breathing stroke glow */
  animation: strokeGlow 3s ease-in-out infinite alternate;
}

.hero-title .line3 {
  color: var(--accent);
  display: block;
  font-size: 0.45em;
  letter-spacing: 0.18em;
  margin-top: 0.4em;
  font-weight: 400; /* Increased weight */
  /* ANIMATION: Text glow pulsing */
  animation: textGlow 2s ease-in-out infinite alternate;
}

.hero-sub {
  font-family: var(--f-ui);
  font-size: 1rem; /* Slightly larger for readability */
  color: var(--text-dim);
  max-width: 540px;
  margin: 2.5rem auto 0;
  font-weight: 400; /* Increased weight */
  line-height: 1.7;
  opacity: 0;
  animation: fadeUp 0.8s 0.7s forwards;
}

.hero-ctas {
  display: flex;
  gap: 1rem;
  margin-top: 3rem;
  flex-wrap: wrap;
  justify-content: center;
  opacity: 0;
  animation: fadeUp 0.8s 0.9s forwards;
}

.btn-primary {
  font-family: var(--f-mono);
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--bg);
  background: var(--accent);
  padding: 14px 32px;
  clip-path: polygon(0 0, 94% 0, 100% 30%, 100% 100%, 6% 100%, 0 70%);
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  font-weight: 700;
  cursor: pointer;
  border: none;
  display: inline-block;
}

.btn-primary:hover {
  background: #fff;
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 10px 25px var(--glow-a);
}

.btn-ghost {
  font-family: var(--f-mono);
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--accent);
  border: 1px solid var(--border-bright);
  padding: 14px 32px;
  clip-path: polygon(0 0, 94% 0, 100% 30%, 100% 100%, 6% 100%, 0 70%);
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  background: transparent;
  cursor: pointer;
  display: inline-block;
}

.btn-ghost:hover {
  background: var(--glow-a);
  border-color: var(--accent);
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 10px 25px rgba(0, 245, 212, 0.1);
}

/* Hero bottom bar */
.hero-data-bar {
  position: absolute;
  bottom: 2rem;
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
  gap: 3rem;
  opacity: 0;
  animation: fadeUp 0.8s 1.1s forwards;
}

.hero-stat {
  text-align: center;
}

.hero-stat-val {
  font-family: var(--f-head);
  font-size: 1.6rem;
  font-weight: 900;
  color: var(--accent);
  line-height: 1;
}

.hero-stat-label {
  font-family: var(--f-mono);
  font-size: 0.6rem;
  letter-spacing: 0.2em;
  color: var(--text-muted);
  text-transform: uppercase;
  margin-top: 4px;
}

/* Corner decorations */
.corner-deco {
  position: absolute;
  width: 80px;
  height: 80px;
  opacity: 0.3;
  animation: pulse-glow 4s infinite alternate;
}

.corner-deco.tl {
  top: 5rem;
  left: 1rem;
  border-top: 1px solid var(--accent);
  border-left: 1px solid var(--accent);
}

.corner-deco.tr {
  top: 5rem;
  right: 1rem;
  border-top: 1px solid var(--accent);
  border-right: 1px solid var(--accent);
}

.corner-deco.bl {
  bottom: 1rem;
  left: 1rem;
  border-bottom: 1px solid var(--accent);
  border-left: 1px solid var(--accent);
}

.corner-deco.br {
  bottom: 1rem;
  right: 1rem;
  border-bottom: 1px solid var(--accent);
  border-right: 1px solid var(--accent);
}

/* ─── SECTIONS ─── */
.section-wrapper {
  position: relative;
  z-index: 2;
}

section {
  max-width: 1280px;
  margin: 0 auto;
  padding: 6rem 1.5rem;
}

.section-header {
  display: flex;
  align-items: baseline;
  gap: 1.5rem;
  margin-bottom: 3rem;
  flex-wrap: wrap;
}

.section-tag {
  font-family: var(--f-mono);
  font-size: 0.6rem;
  letter-spacing: 0.3em;
  color: var(--accent);
  text-transform: uppercase;
  border: 1px solid var(--border);
  padding: 4px 10px;
  white-space: nowrap;
  flex-shrink: 0;
}

.section-title {
  font-family: var(--f-head);
  font-size: clamp(2rem, 5vw, 2.2rem);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: -0.01em;
  line-height: 1;
  word-break: break-word;
}

.section-line {
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, var(--border-bright), transparent);
  min-width: 30px;
}

/* ─── BRIEF CARD ─── */
.brief-card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 3rem;
  backdrop-filter: blur(14px);
  overflow: hidden;
  transition: box-shadow 0.4s ease, border-color 0.4s ease;
}

.brief-card:hover {
  border-color: var(--border-bright);
  box-shadow: 0 0 30px rgba(0, 245, 212, 0.05);
}

.brief-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
}

.brief-card::after {
  content: '';
  position: absolute;
  bottom: -60px;
  right: -60px;
  width: 200px;
  height: 200px;
  background: radial-gradient(circle, var(--glow-a), transparent 70%);
  pointer-events: none;
  animation: pulse-glow 6s infinite alternate;
}

.brief-card p {
  font-size: 1.15rem;
  color: rgba(255, 255, 255, 0.95);
  font-weight: 400;
  max-width: 700px;
  line-height: 1.8;
}

.brief-card .classified-stamp {
  position: absolute;
  top: 2rem;
  right: 2rem;
  font-family: var(--f-head);
  font-size: 0.7rem;
  font-weight: 900;
  letter-spacing: 0.3em;
  color: var(--accent);
  border: 2px solid var(--accent);
  padding: 4px 12px;
  opacity: 0.15;
  transform: rotate(-6deg);
  pointer-events: none;
}

@media (max-width: 768px) {
  .brief-card {
    padding: 2rem;
  }

  .brief-card p {
    font-size: 1rem;
    line-height: 1.7;
  }

  .brief-card .classified-stamp {
    top: 1.5rem;
    right: 1.5rem;
    font-size: 0.65rem;
    padding: 3px 10px;
  }
}

@media (max-width: 480px) {
  .brief-card {
    padding: 1.5rem 1rem;
  }

  .brief-card p {
    font-size: 0.95rem;
    line-height: 1.6;
  }

  .brief-card .classified-stamp {
    top: 1rem;
    right: 1rem;
    font-size: 0.6rem;
    padding: 2px 8px;
  }
}

/* ─── SEARCH ─── */
.search-wrap {
  position: relative;
  margin-bottom: 2.5rem;
}

.search-icon {
  position: absolute;
  left: 1.2rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 0.9rem;
  pointer-events: none;
  transition: color 0.3s;
}

#character-search {
  width: 100%;
  padding: 15px 20px 15px 3rem;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-top: 1px solid var(--border-bright);
  color: var(--accent);
  font-family: var(--f-mono);
  font-size: 0.9rem;
  outline: none;
  letter-spacing: 0.1em;
  transition: border-color 0.3s, box-shadow 0.3s, background 0.3s;
}

#character-search:focus {
  background: rgba(12, 20, 36, 0.9);
  border-color: var(--accent);
  box-shadow: 0 0 0 1px rgba(0, 245, 212, 0.2), inset 0 0 30px rgba(0, 245, 212, 0.05);
}

#character-search:focus + .search-icon {
  color: var(--accent);
}

#character-search::placeholder {
  color: var(--text-muted);
  letter-spacing: 0.15em;
}

/* ─── CHARACTER GRID ─── */
.characters-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  background: var(--border);
}

@media (min-width: 600px) {
  .characters-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (min-width: 900px) {
  .characters-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

@media (min-width: 1200px) {
  .characters-grid {
    grid-template-columns: repeat(5, 1fr);
  }
}

/* ─── CHARACTER CARD ─── */
.character-card {
  position: relative;
  background: var(--bg2);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  cursor: pointer;
  /* ANIMATION: Snappy pop up effect */
  transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.4s ease;
}

.character-card:hover {
  transform: translateY(-8px) scale(1.02);
  z-index: 10;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.6), 0 0 20px var(--glow-a);
}

.character-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 50%, rgba(0, 5, 15, 0.95) 100%);
  z-index: 1;
  pointer-events: none;
}

.character-card .portrait {
  width: 100%;
  aspect-ratio: 3/4;
  background: #060a14;
  overflow: hidden;
}

.character-card .portrait img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.215, 0.610, 0.355, 1.000), filter 0.6s ease;
  filter: saturate(0.85);
}

.character-card:hover .portrait img {
  transform: scale(1.1);
  filter: saturate(1.2);
}

/* Rarity stripe top */
.character-card .rarity-bar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent), var(--accent2));
  z-index: 3;
}

.character-card .info {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 1rem 0.9rem 0.9rem;
  z-index: 2;
  transition: transform 0.3s ease;
}

.character-card h2 {
  font-family: var(--f-head);
  font-size: 1.1rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1;
  margin-bottom: 4px;
}

.character-card .role-tag {
  font-family: var(--f-mono);
  font-size: 0.6rem;
  letter-spacing: 0.2em;
  color: var(--accent);
  text-transform: uppercase;
  display: block;
  margin-bottom: 0.6rem;
}

.card-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
}

.btn-card {
  font-family: var(--f-mono);
  font-size: 0.6rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-dim);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 7px 4px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-card:hover {
  color: var(--accent);
  border-color: var(--accent);
  background: var(--glow-a);
  box-shadow: 0 0 10px rgba(0, 245, 212, 0.2);
}

.btn-card.full {
  grid-column: span 2;
  border-color: rgba(0, 245, 212, 0.2);
  color: var(--accent);
}

.btn-card.full:hover {
  background: rgba(0, 245, 212, 0.15);
}

/* ─── BANNER CARDS ─── */
.banners-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .banners-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 480px) {
  .banners-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
}

.banner-card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  overflow: hidden;
  /* ANIMATION: Lift effect on hover */
  transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), border-color 0.4s ease, box-shadow 0.4s ease;
}

.banner-card:hover {
  border-color: var(--border-bright);
  transform: translateY(-6px);
  box-shadow: 0 15px 30px rgba(0,0,0,0.4), 0 0 20px rgba(0, 245, 212, 0.1);
}

.banner-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(160deg, rgba(0, 245, 212, 0.04) 0%, transparent 60%);
  pointer-events: none;
  z-index: 1;
}

.banner-card .banner-img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  display: block;
  filter: saturate(0.8) brightness(0.9);
  transition: filter 0.5s ease, transform 0.5s ease;
}

.banner-card:hover .banner-img {
  filter: saturate(1.1) brightness(1.1);
  transform: scale(1.03);
}

.banner-body {
  padding: 1.4rem 1.5rem 1.5rem;
  position: relative;
  z-index: 2;
}

.banner-label {
  font-family: var(--f-mono);
  font-size: 0.6rem;
  letter-spacing: 0.3em;
  color: var(--gold);
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}

.banner-card h3 {
  font-family: var(--f-head);
  font-size: 1.4rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text);
  margin-bottom: 0.5rem;
}

.banner-card p {
  font-size: 0.95rem; /* Readability bump */
  color: var(--text-dim);
  line-height: 1.7;
}

/* ─── SPECS ─── */
.specs-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  background: var(--border);
}

@media (max-width: 768px) {
  .specs-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .specs-grid {
    gap: 0.5px;
  }
}

.spec-box {
  background: var(--bg2);
  padding: 2rem;
  position: relative;
  overflow: hidden;
  transition: background 0.3s ease;
}

.spec-box:hover {
  background: rgba(12, 20, 36, 0.9);
}

@media (max-width: 768px) {
  .spec-box {
    padding: 1.5rem;
  }
}

@media (max-width: 480px) {
  .spec-box {
    padding: 1.2rem;
  }
}

.spec-box::after {
  content: '';
  position: absolute;
  bottom: -30px;
  right: -30px;
  width: 100px;
  height: 100px;
  background: radial-gradient(circle, var(--glow-a), transparent 70%);
  animation: pulse-glow 5s infinite alternate;
}

.spec-label {
  font-family: var(--f-mono);
  font-size: 0.65rem;
  letter-spacing: 0.25em;
  color: var(--accent);
  text-transform: uppercase;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.spec-label::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}

.spec-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.6rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  font-size: 0.85rem;
}

.spec-row:last-child {
  border-bottom: none;
}

.spec-row span:first-child {
  color: var(--text-dim); /* Brighter for readability */
  font-size: 0.8rem;
}

.spec-row span:last-child {
  color: var(--text);
  font-weight: 600;
}

/* ─── FOOTER ─── */
footer {
  position: relative;
  z-index: 2;
  border-top: 1px solid var(--border);
  text-align: center;
  padding: 4rem 1rem;
  background: linear-gradient(0deg, rgba(0, 245, 212, 0.02) 0%, transparent 100%);
}

.footer-nav {
  margin-bottom: 2rem;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: center;
  font-family: var(--f-mono);
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.footer-nav a {
  text-decoration: none;
  color: var(--text-dim);
  transition: all 0.3s ease;
  padding: 4px 8px;
}

@media (max-width: 768px) {
  footer {
    padding: 3rem 1rem;
  }

  .footer-nav {
    margin-bottom: 1.5rem;
    gap: 0.75rem;
    font-size: 0.65rem;
  }

  .footer-nav a {
    padding: 3px 6px;
  }
}

@media (max-width: 480px) {
  footer {
    padding: 2rem 0.75rem;
  }

  .footer-nav {
    margin-bottom: 1rem;
    gap: 0.5rem;
    font-size: 0.6rem;
  }

  .footer-nav a {
    padding: 2px 4px;
  }
}

.footer-nav a:hover {
  color: var(--accent);
  text-shadow: 0 0 10px var(--glow-a);
}

.footer-nav .separator {
  color: var(--border-bright);
  opacity: 0.5;
  user-select: none;
}

footer hr {
  border: none;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border), transparent);
  max-width: 600px;
  margin: 0 auto 2rem;
}

.footer-logo {
  font-family: var(--f-head);
  font-size: 1.4rem;
  font-weight: 900;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
  transition: color 0.3s;
}

.footer-logo:hover {
  color: var(--accent);
  text-shadow: 0 0 10px var(--glow-a);
}

footer p {
  font-family: var(--f-mono);
  font-size: 0.65rem;
  letter-spacing: 0.2em;
  color: var(--text-muted);
  margin-top: 0.3rem;
}

footer p strong {
  color: var(--accent);
  letter-spacing: 0.3em;
}

/* ─── TOASTER ─── */
#toaster {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 2000;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.toast {
  background: rgba(5, 7, 13, 0.96);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  color: var(--accent);
  padding: 0.9rem 1.4rem;
  font-family: var(--f-mono);
  font-size: 0.75rem;
  letter-spacing: 0.05em;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(0, 245, 212, 0.05);
  animation: slideIn 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  max-width: 320px;
}

/* ─── DIVIDER ─── */
.section-divider {
  position: relative;
  z-index: 2;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border-bright) 30%, var(--border-bright) 70%, transparent);
  margin: 0 2rem;
}

/* ─── ANIMATIONS ─── */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateX(40px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes pulse-glow {
  0% { opacity: 0.3; transform: scale(0.95); }
  100% { opacity: 0.7; transform: scale(1.05); }
}

@keyframes scanlineScroll {
  from { background-position: 0 0; }
  to { background-position: 0 -400px; }
}

@keyframes floatBob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-12px); }
}

@keyframes textGlow {
  from { text-shadow: 0 0 4px var(--glow-a); }
  to { text-shadow: 0 0 15px var(--accent), 0 0 25px var(--glow-b); }
}

@keyframes strokeGlow {
  from { filter: drop-shadow(0 0 2px rgba(0, 245, 212, 0)); }
  to { filter: drop-shadow(0 0 8px rgba(0, 245, 212, 0.6)); }
}

/* Scroll reveal */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s cubic-bezier(0.165, 0.84, 0.44, 1), transform 0.8s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ─── HERO RESPONSIVE ─── */
@media (max-width: 1024px) {
  .hero-title {
    font-size: clamp(2.2rem, 8vw, 5rem);
  }

  .hero-sub {
    font-size: 0.95rem;
    max-width: 480px;
  }

  .hero-stat-val {
    font-size: 1.3rem;
  }

  .hero-data-bar {
    gap: 2rem;
  }
}

@media (max-width: 768px) {
  #hero {
    padding: 6rem 1rem 3rem;
  }

  .hero-header-image {
    max-width: 80%;
    max-height: 280px;
  }

  .hero-title {
    font-size: clamp(2rem, 7vw, 3.5rem);
    margin-bottom: 1rem;
  }

  .hero-eyebrow {
    font-size: 0.6rem;
  }

  .hero-sub {
    font-size: 0.9rem;
    max-width: 100%;
    margin: 1.5rem auto 0;
    padding: 0 0.5rem;
  }

  .hero-data-bar {
    gap: 1.5rem;
    bottom: 1.5rem;
  }

  .hero-stat-val {
    font-size: 1.2rem;
  }

  .hero-stat-label {
    font-size: 0.55rem;
  }

  .hero-ctas {
    gap: 0.75rem;
    margin-top: 2rem;
  }

  .btn-primary,
  .btn-ghost {
    padding: 12px 24px;
    font-size: 0.65rem;
  }
}

@media (max-width: 640px) {
  #hero {
    padding: 5rem 0.75rem 2.5rem;
    min-height: 80svh;
  }

  .hero-header-image {
    max-width: 90%;
    max-height: 200px;
    margin-bottom: 1.5rem;
  }

  .hero-eyebrow {
    font-size: 0.55rem;
    margin-bottom: 1rem;
  }

  .hero-title {
    font-size: clamp(1.8rem, 6vw, 2.5rem);
    line-height: 1;
  }

  .hero-title .line2 {
    -webkit-text-stroke: 1px var(--accent);
    font-size: 0.95em;
  }

  .hero-title .line3 {
    font-size: 0.35em;
    margin-top: 0.3em;
  }

  .hero-sub {
    font-size: 0.85rem;
    line-height: 1.6;
    margin-top: 1rem;
  }

  .hero-data-bar {
    flex-wrap: wrap;
    gap: 1rem;
    bottom: 1rem;
    padding: 0 0.75rem;
  }

  .hero-stat {
    flex: 1;
    min-width: 80px;
  }

  .hero-stat-val {
    font-size: 1rem;
  }

  .hero-stat-label {
    font-size: 0.5rem;
    margin-top: 2px;
  }

  .hero-ctas {
    gap: 0.5rem;
    margin-top: 1.5rem;
    flex-wrap: wrap;
  }

  .btn-primary,
  .btn-ghost {
    padding: 10px 20px;
    font-size: 0.6rem;
    flex: 1;
    min-width: 100px;
  }

  section {
    padding: 3rem 0.75rem;
  }

  .section-header {
    flex-direction: column;
    gap: 1rem;
    align-items: flex-start;
  }

  .section-title {
    font-size: 1.8rem;
  }

  .section-tag {
    font-size: 0.55rem;
  }

  .section-line {
    display: none;
  }

  .brief-card {
    padding: 2rem 1rem;
  }

  .brief-card p {
    font-size: 1rem;
    line-height: 1.7;
  }

  .brief-card .classified-stamp {
    right: 1rem;
    top: 1rem;
    font-size: 0.6rem;
    padding: 3px 8px;
  }
}

@media (max-width: 480px) {
  #hero {
    padding: 4.5rem 0.5rem 2rem;
    min-height: 75svh;
  }

  .hero-header-image {
    max-width: 100%;
    max-height: 150px;
    margin-bottom: 1rem;
  }

  .hero-eyebrow {
    font-size: 0.5rem;
    margin-bottom: 0.8rem;
  }

  .hero-title {
    font-size: clamp(1.5rem, 5vw, 2rem);
  }

  .hero-title .line2 {
    -webkit-text-stroke: 0.8px var(--accent);
    font-size: 0.9em;
  }

  .hero-title .line3 {
    font-size: 0.3em;
    letter-spacing: 0.1em;
  }

  .hero-sub {
    font-size: 0.8rem;
    line-height: 1.5;
    margin-top: 0.8rem;
  }

  .hero-data-bar {
    gap: 0.75rem;
    bottom: 0.75rem;
    padding: 0 0.5rem;
  }

  .hero-stat {
    min-width: 60px;
  }

  .hero-stat-val {
    font-size: 0.9rem;
  }

  .hero-stat-label {
    font-size: 0.45rem;
  }

  .hero-ctas {
    gap: 0.4rem;
    margin-top: 1.2rem;
  }

  .btn-primary,
  .btn-ghost {
    padding: 8px 16px;
    font-size: 0.55rem;
    min-width: 85px;
    clip-path: polygon(0 0, 90% 0, 100% 25%, 100% 100%, 10% 100%, 0 75%);
  }

  section {
    padding: 2.5rem 0.5rem;
  }

  .section-title {
    font-size: 1.5rem;
  }

  .brief-card {
    padding: 1.5rem 0.8rem;
  }

  .brief-card p {
    font-size: 0.95rem;
  }
}

/* ─── MOBILE NAV ─── */
@media (max-width: 640px) {
  nav {
    padding: 0 0.75rem;
    gap: 0;
    height: 52px;
  }

  .nav-logo {
    font-size: 0.7rem;
  }

  .nav-logo-image {
    max-width: 120px;
    height: 35px;
  }

  .nav-links {
    gap: 0;
    flex-wrap: wrap;
  }

  .nav-links a {
    font-size: 0.5rem;
    padding: 5px 6px;
    letter-spacing: 0.08em;
  }

  .nav-links a.external-link .arrow {
    margin-left: 2px;
    font-size: 0.85em;
  }
}

@media (max-width: 480px) {
  nav {
    padding: 0 0.5rem;
    height: 48px;
  }

  .nav-logo {
    font-size: 0.65rem;
  }

  .nav-logo-image {
    max-width: 100px;
    height: 30px;
  }

  .nav-links a {
    font-size: 0.45rem;
    padding: 4px 5px;
  }
}
