/* ==========================================================================
   ZEUSGG — AI Innovation Systems
   ========================================================================== */

@property --border-angle {
  syntax: "<angle>";
  inherits: false;
  initial-value: 0deg;
}

:root {
  --bg: #05050f;
  --bg-2: #0a0a1e;
  --bg-3: #10102b;
  --ink: #f2f4ff;
  --ink-dim: #9aa0c3;
  --ink-faint: #5c6187;
  --blue: #4f7cff;
  --cyan: #3ee7ff;
  --violet: #7c4dff;
  --purple: #b14dff;
  --glow-blue: rgba(79, 124, 255, 0.55);
  --glow-cyan: rgba(62, 231, 255, 0.45);
  --glow-purple: rgba(177, 77, 255, 0.4);
  --glass: rgba(16, 16, 43, 0.55);
  --glass-border: rgba(110, 130, 255, 0.16);
  --font-display: "Orbitron", "Segoe UI", sans-serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --nav-h: 76px;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-h) + 12px);
}

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.7;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

::selection { background: rgba(79, 124, 255, 0.4); color: #fff; }

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }

:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 200;
  padding: 0.6rem 1.2rem;
  background: var(--bg-3);
  border: 1px solid var(--glass-border);
  border-radius: 8px;
  transition: top 0.25s var(--ease-out);
}
.skip-link:focus { top: 1rem; }

/* --------------------------------------------------------------------------
   Loader
   -------------------------------------------------------------------------- */

.loader {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1.4rem;
  background: var(--bg);
  transition: opacity 0.6s ease, visibility 0.6s ease;
}
.loader.done { opacity: 0; visibility: hidden; pointer-events: none; }

.loader-mark {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  overflow: hidden;
  animation: loader-pulse 1.6s ease-in-out infinite;
  filter: drop-shadow(0 0 24px var(--glow-blue));
}
.loader-mark img { width: 100%; height: 100%; object-fit: cover; }

.loader-bar {
  width: 140px;
  height: 2px;
  border-radius: 2px;
  background: rgba(110, 130, 255, 0.15);
  overflow: hidden;
}
.loader-bar::after {
  content: "";
  display: block;
  height: 100%;
  width: 40%;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--blue), var(--cyan));
  animation: loader-sweep 1.1s ease-in-out infinite;
}

.loader-word {
  font-family: var(--font-display);
  font-size: 0.72rem;
  letter-spacing: 0.55em;
  text-indent: 0.55em;
  color: var(--ink-dim);
}

@keyframes loader-pulse {
  0%, 100% { transform: scale(1); filter: drop-shadow(0 0 18px var(--glow-blue)); }
  50% { transform: scale(1.06); filter: drop-shadow(0 0 36px var(--glow-cyan)); }
}
@keyframes loader-sweep {
  0% { transform: translateX(-110%); }
  100% { transform: translateX(360%); }
}

/* --------------------------------------------------------------------------
   Background layers
   -------------------------------------------------------------------------- */

.sky {
  position: fixed;
  inset: 0;
  z-index: -3;
  background:
    radial-gradient(ellipse 90% 60% at 70% -10%, rgba(76, 29, 149, 0.28), transparent 60%),
    radial-gradient(ellipse 70% 55% at 15% 15%, rgba(30, 58, 138, 0.25), transparent 60%),
    radial-gradient(ellipse 80% 60% at 50% 110%, rgba(88, 28, 135, 0.2), transparent 65%),
    linear-gradient(180deg, #06061a 0%, var(--bg) 45%, #070718 100%);
}

#stars {
  position: fixed;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
}

.grid-field {
  position: fixed;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(rgba(90, 110, 255, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(90, 110, 255, 0.05) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: radial-gradient(ellipse 70% 55% at 50% 40%, black 0%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 70% 55% at 50% 40%, black 0%, transparent 75%);
  animation: grid-drift 26s linear infinite;
}
@keyframes grid-drift {
  from { background-position: 0 0, 0 0; }
  to { background-position: 72px 72px, 72px 72px; }
}

.cursor-glow {
  position: fixed;
  z-index: 0;
  width: 560px;
  height: 560px;
  border-radius: 50%;
  pointer-events: none;
  background: radial-gradient(circle, rgba(79, 124, 255, 0.09) 0%, rgba(62, 231, 255, 0.045) 35%, transparent 70%);
  transform: translate(-50%, -50%);
  opacity: 0;
  transition: opacity 0.6s ease;
}

/* --------------------------------------------------------------------------
   Navigation
   -------------------------------------------------------------------------- */

.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  transition: background 0.4s ease, border-color 0.4s ease, backdrop-filter 0.4s ease;
  border-bottom: 1px solid transparent;
}
.nav.scrolled {
  background: rgba(5, 5, 18, 0.72);
  backdrop-filter: blur(18px) saturate(140%);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  border-bottom-color: rgba(110, 130, 255, 0.12);
}

.nav-inner {
  width: min(1200px, 92%);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 0.28em;
}
.brand img {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  filter: drop-shadow(0 0 10px var(--glow-blue));
}
.brand span {
  background: linear-gradient(100deg, #dfe6ff 20%, var(--cyan) 55%, var(--purple) 90%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* Wordmark alone in the nav — the hero emblem carries the symbol there,
   so the type needs a little more weight to hold the corner. */
.brand-nav {
  font-size: 1.2rem;
  letter-spacing: 0.34em;
  text-indent: 0.34em;
}
.brand-nav span { transition: filter 0.4s ease; }
.brand-nav:hover span { filter: drop-shadow(0 0 14px var(--glow-cyan)); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 2.2rem;
  list-style: none;
}
.nav-links a:not(.btn) {
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--ink-dim);
  position: relative;
  padding: 0.4rem 0;
  transition: color 0.3s ease;
}
.nav-links a:not(.btn)::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 1px;
  background: linear-gradient(90deg, var(--cyan), var(--purple));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s var(--ease-out);
}
.nav-links a:not(.btn):hover { color: var(--ink); }
.nav-links a:not(.btn):hover::after { transform: scaleX(1); }

.nav-toggle {
  display: none;
  background: none;
  border: none;
  width: 44px;
  height: 44px;
  position: relative;
  z-index: 110;
}
.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  margin: 5px auto;
  border-radius: 2px;
  background: var(--ink);
  transition: transform 0.35s var(--ease-out), opacity 0.25s ease;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* --------------------------------------------------------------------------
   Buttons
   -------------------------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  padding: 0.85rem 1.9rem;
  border-radius: 10px;
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  white-space: nowrap;
  position: relative;
  transition: transform 0.25s var(--ease-out), box-shadow 0.3s ease;
  will-change: transform;
}

.btn-primary {
  color: #fff;
  background: linear-gradient(120deg, #3557d4, #6a3cf0 55%, #8b3cf0);
  border: 1px solid rgba(140, 160, 255, 0.35);
  box-shadow: 0 0 22px rgba(90, 80, 240, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.15);
}
.btn-primary:hover {
  box-shadow: 0 0 38px rgba(100, 110, 255, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.btn-ghost {
  color: var(--ink);
  background: rgba(110, 130, 255, 0.06);
  border: 1px solid rgba(110, 130, 255, 0.28);
  backdrop-filter: blur(6px);
}
.btn-ghost:hover {
  border-color: rgba(62, 231, 255, 0.5);
  box-shadow: 0 0 24px rgba(62, 231, 255, 0.18);
}

.btn-nav { padding: 0.65rem 1.4rem; font-size: 0.7rem; }

/* --------------------------------------------------------------------------
   Layout primitives
   -------------------------------------------------------------------------- */

.wrap { width: min(1200px, 92%); margin: 0 auto; }

.section { position: relative; padding: clamp(6rem, 12vh, 9rem) 0; }

.label {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  font-family: var(--font-display);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.5em;
  text-transform: uppercase;
  color: var(--cyan);
  margin-bottom: 1.4rem;
}
.label::before {
  content: "";
  width: 28px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--cyan));
}

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: 0.01em;
}

.headline {
  font-size: clamp(1.7rem, 4.2vw, 2.9rem);
  max-width: 22ch;
  margin-bottom: 1.6rem;
  background: linear-gradient(115deg, #ffffff 30%, #b9c6ff 65%, #9aa8ff 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.lede {
  color: var(--ink-dim);
  max-width: 58ch;
}
.lede + .lede { margin-top: 1.1rem; }

/* Scroll reveal */
.reveal {
  opacity: 0;
  transform: translateY(34px);
  transition: opacity 0.9s var(--ease-out), transform 0.9s var(--ease-out);
  transition-delay: var(--d, 0s);
}
.reveal.in { opacity: 1; transform: none; }

/* --------------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------------- */

.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: calc(var(--nav-h) + 3rem) 0 4.5rem;
  overflow: hidden;
}

#lightning {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.hero-inner {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.hero-emblem {
  position: relative;
  width: clamp(230px, 32vw, 350px);
  aspect-ratio: 1;
  margin-bottom: 1.2rem;
}

.hero-emblem .ring {
  position: absolute;
  inset: -7%;
  border-radius: 50%;
  pointer-events: none;
}
.hero-emblem .ring-a {
  background: conic-gradient(from 0deg, transparent 0%, rgba(62, 231, 255, 0.5) 6%, transparent 14%, transparent 52%, rgba(177, 77, 255, 0.45) 58%, transparent 66%);
  mask: radial-gradient(farthest-side, transparent calc(100% - 2px), black calc(100% - 1px));
  -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 2px), black calc(100% - 1px));
  animation: spin 14s linear infinite;
}
.hero-emblem .ring-b {
  inset: -14%;
  background: conic-gradient(from 180deg, transparent 0%, rgba(79, 124, 255, 0.35) 8%, transparent 18%);
  mask: radial-gradient(farthest-side, transparent calc(100% - 1.5px), black calc(100% - 0.5px));
  -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 1.5px), black calc(100% - 0.5px));
  animation: spin 22s linear infinite reverse;
}
@keyframes spin { to { transform: rotate(360deg); } }

.hero-emblem .halo {
  position: absolute;
  inset: -30%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(96, 90, 255, 0.22) 0%, rgba(62, 231, 255, 0.08) 40%, transparent 70%);
  animation: halo-breathe 6s ease-in-out infinite;
  pointer-events: none;
}
@keyframes halo-breathe {
  0%, 100% { opacity: 0.75; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.07); }
}

.hero-emblem img {
  position: relative;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  mask-image: radial-gradient(circle, black 58%, transparent 74%);
  -webkit-mask-image: radial-gradient(circle, black 58%, transparent 74%);
  animation: emblem-float 8s ease-in-out infinite;
}
@keyframes emblem-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-12px); }
}

.hero-label {
  font-family: var(--font-display);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.6em;
  text-indent: 0.6em;
  text-transform: uppercase;
  color: var(--cyan);
  margin-bottom: 1.5rem;
  text-shadow: 0 0 18px var(--glow-cyan);
}

.hero h1 {
  font-size: clamp(2.1rem, 5.6vw, 4.1rem);
  max-width: 17ch;
  margin: 0 auto 1.5rem;
  background: linear-gradient(115deg, #ffffff 25%, #c9d4ff 55%, #8f9dff 85%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-sub {
  color: var(--ink-dim);
  max-width: 52ch;
  margin: 0 auto 2.4rem;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 1.6rem;
}

.hero-note {
  font-size: 0.78rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-faint);
}

.scroll-hint {
  position: absolute;
  bottom: 2.2rem;
  left: 50%;
  transform: translateX(-50%);
  width: 22px;
  height: 36px;
  border: 1.5px solid rgba(154, 160, 195, 0.4);
  border-radius: 12px;
  z-index: 1;
}
.scroll-hint::after {
  content: "";
  position: absolute;
  top: 7px;
  left: 50%;
  width: 3px;
  height: 7px;
  margin-left: -1.5px;
  border-radius: 2px;
  background: var(--cyan);
  animation: scroll-drop 2.2s ease-in-out infinite;
}
@keyframes scroll-drop {
  0% { opacity: 0; transform: translateY(0); }
  30% { opacity: 1; }
  100% { opacity: 0; transform: translateY(12px); }
}

/* --------------------------------------------------------------------------
   About — energy beam
   -------------------------------------------------------------------------- */

.about { overflow: hidden; }

.beam {
  position: absolute;
  top: 50%;
  left: -10%;
  width: 120%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(79, 124, 255, 0.5), rgba(62, 231, 255, 0.7), rgba(177, 77, 255, 0.5), transparent);
  pointer-events: none;
}
.beam::after {
  content: "";
  position: absolute;
  top: -3px;
  width: 90px;
  height: 7px;
  border-radius: 6px;
  background: radial-gradient(ellipse, rgba(62, 231, 255, 0.9), transparent 70%);
  filter: blur(1px);
  animation: beam-run 7s linear infinite;
}
@keyframes beam-run {
  0% { left: -8%; opacity: 0; }
  8% { opacity: 1; }
  92% { opacity: 1; }
  100% { left: 104%; opacity: 0; }
}

.circuit-decor {
  position: absolute;
  right: -2%;
  top: 12%;
  width: min(420px, 45vw);
  opacity: 0.5;
  pointer-events: none;
}
.circuit-decor path,
.circuit-decor circle { stroke: rgba(90, 120, 255, 0.4); }
.circuit-decor .pulse-line {
  stroke: var(--cyan);
  stroke-dasharray: 24 260;
  animation: circuit-run 5.5s linear infinite;
}
@keyframes circuit-run { to { stroke-dashoffset: -284; } }

/* --------------------------------------------------------------------------
   Capabilities — cards
   -------------------------------------------------------------------------- */

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(255px, 1fr));
  gap: 1.4rem;
  margin-top: 3.2rem;
}

.card {
  position: relative;
  padding: 2.1rem 1.9rem;
  border-radius: 16px;
  background: var(--glass);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  overflow: hidden;
  isolation: isolate;
  transition: transform 0.4s var(--ease-out), box-shadow 0.4s ease;
}
.card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: conic-gradient(from var(--border-angle), rgba(110, 130, 255, 0.12), rgba(62, 231, 255, 0.55), rgba(110, 130, 255, 0.12) 30%, rgba(110, 130, 255, 0.12) 60%, rgba(177, 77, 255, 0.5), rgba(110, 130, 255, 0.12));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  mask-composite: exclude;
  animation: border-spin 7s linear infinite;
  pointer-events: none;
}
@keyframes border-spin { to { --border-angle: 360deg; } }

.card:hover {
  transform: translateY(-7px);
  box-shadow: 0 24px 50px -18px rgba(20, 20, 70, 0.9), 0 0 40px -6px rgba(79, 124, 255, 0.25);
}

.card-circuit {
  position: absolute;
  inset: auto -10px -10px auto;
  width: 150px;
  height: 120px;
  opacity: 0.55;
  z-index: -1;
  pointer-events: none;
}
.card-circuit path { stroke: rgba(90, 120, 255, 0.3); fill: none; }
.card-circuit circle { fill: rgba(90, 120, 255, 0.45); }
.card-circuit .trace {
  stroke: var(--cyan);
  stroke-dasharray: 16 180;
  animation: circuit-run 4.5s linear infinite;
}
.card:nth-child(2) .trace { animation-delay: -1.2s; }
.card:nth-child(3) .trace { animation-delay: -2.4s; }
.card:nth-child(4) .trace { animation-delay: -3.6s; }

.card-icon {
  width: 46px;
  height: 46px;
  margin-bottom: 1.4rem;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(79, 124, 255, 0.16), rgba(177, 77, 255, 0.12));
  border: 1px solid rgba(110, 130, 255, 0.25);
  box-shadow: 0 0 18px rgba(79, 124, 255, 0.18);
}
.card-icon svg { width: 22px; height: 22px; stroke: var(--cyan); fill: none; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }

.card h3 {
  font-size: 1.02rem;
  letter-spacing: 0.08em;
  margin-bottom: 0.8rem;
}
.card p { font-size: 0.94rem; color: var(--ink-dim); }

/* --------------------------------------------------------------------------
   Philosophy
   -------------------------------------------------------------------------- */

.philosophy {
  position: relative;
  padding: clamp(7rem, 16vh, 11rem) 0;
  overflow: hidden;
  border-top: 1px solid rgba(110, 130, 255, 0.08);
  border-bottom: 1px solid rgba(110, 130, 255, 0.08);
  background:
    radial-gradient(ellipse 80% 70% at 50% 50%, rgba(45, 30, 110, 0.35), transparent 75%);
}

#lightning-philosophy {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  opacity: 0.8;
}

.philosophy .wrap { position: relative; text-align: center; }

.statement {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 4vw, 2.7rem);
  font-weight: 700;
  line-height: 1.3;
  max-width: 26ch;
  margin: 0 auto 2rem;
}
.statement em {
  font-style: normal;
  background: linear-gradient(100deg, var(--cyan), var(--blue) 50%, var(--purple));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: none;
}

.philosophy .lede { margin: 0 auto; }

/* --------------------------------------------------------------------------
   Contact
   -------------------------------------------------------------------------- */

.contact { text-align: center; }
.contact .label { justify-content: center; }
.contact .label::after {
  content: "";
  width: 28px;
  height: 1px;
  background: linear-gradient(90deg, var(--cyan), transparent);
}
.contact .headline, .contact .lede { margin-left: auto; margin-right: auto; }

.contact-email {
  display: inline-block;
  position: relative;
  margin: 2.6rem 0 2.2rem;
  font-family: var(--font-display);
  font-size: clamp(1.25rem, 3.6vw, 2.3rem);
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--ink);
  padding: 0.4rem 0.2rem;
  transition: color 0.3s ease, text-shadow 0.3s ease;
}
.contact-email::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -6px;
  height: 2px;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--blue), var(--cyan), var(--purple), var(--blue));
  background-size: 250% 100%;
  animation: pulse-line 4s linear infinite;
  box-shadow: 0 0 16px var(--glow-cyan);
}
@keyframes pulse-line { to { background-position: -250% 0; } }
.contact-email:hover {
  color: var(--cyan);
  text-shadow: 0 0 26px var(--glow-cyan);
}

.contact .btn-primary { position: relative; }
.contact .btn-primary::after {
  content: "";
  position: absolute;
  inset: -5px;
  border-radius: 14px;
  border: 1px solid rgba(62, 231, 255, 0.45);
  animation: electric-ring 2.6s ease-out infinite;
  pointer-events: none;
}
@keyframes electric-ring {
  0% { opacity: 0.8; transform: scale(0.98); }
  70%, 100% { opacity: 0; transform: scale(1.14); }
}

/* --------------------------------------------------------------------------
   Footer
   -------------------------------------------------------------------------- */

.footer {
  border-top: 1px solid rgba(110, 130, 255, 0.1);
  padding: 3.5rem 0 2.5rem;
  background: linear-gradient(180deg, transparent, rgba(8, 8, 26, 0.8));
}

.footer-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 2.5rem;
  margin-bottom: 2.8rem;
}

.footer-brand .brand { margin-bottom: 0.9rem; }
.footer-brand p {
  font-size: 0.9rem;
  color: var(--ink-faint);
  max-width: 34ch;
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  list-style: none;
  text-align: right;
}
.footer-links a {
  font-size: 0.82rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-dim);
  transition: color 0.3s ease;
}
.footer-links a:hover { color: var(--cyan); }
.footer-links .footer-email {
  font-family: var(--font-display);
  text-transform: none;
  letter-spacing: 0.06em;
  color: var(--ink);
}
.footer-links .footer-email:hover { color: var(--cyan); }

.footer-base {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
  padding-top: 1.8rem;
  border-top: 1px solid rgba(110, 130, 255, 0.08);
  font-size: 0.8rem;
  color: var(--ink-faint);
}

/* --------------------------------------------------------------------------
   Toast
   -------------------------------------------------------------------------- */

.toast {
  position: fixed;
  z-index: 320;
  left: 50%;
  top: calc(var(--nav-h) + 1rem);
  transform: translate(-50%, -18px);
  padding: 0.7rem 1.3rem;
  border-radius: 999px;
  font-family: var(--font-display);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  white-space: nowrap;
  color: var(--ink);
  background: rgba(12, 12, 34, 0.9);
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  border: 1px solid rgba(62, 231, 255, 0.4);
  box-shadow: 0 12px 40px -12px rgba(0, 0, 20, 0.9), 0 0 30px -8px var(--glow-cyan);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.35s ease, transform 0.45s var(--ease-out), visibility 0.35s ease;
}
.toast.show {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, 0);
}
@media (max-width: 480px) {
  .toast { font-size: 0.66rem; max-width: calc(100% - 2rem); overflow: hidden; text-overflow: ellipsis; }
}

/* --------------------------------------------------------------------------
   Cookie banner
   -------------------------------------------------------------------------- */

.cookie-banner {
  position: fixed;
  z-index: 300;
  left: 50%;
  bottom: 1.4rem;
  transform: translate(-50%, 130%);
  width: min(640px, calc(100% - 2rem));
  padding: 1.3rem 1.5rem;
  border-radius: 16px;
  background: rgba(10, 10, 30, 0.82);
  backdrop-filter: blur(18px) saturate(140%);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  border: 1px solid rgba(110, 130, 255, 0.22);
  box-shadow: 0 24px 60px -20px rgba(0, 0, 20, 0.9), 0 0 40px -10px rgba(79, 124, 255, 0.2);
  transition: transform 0.6s var(--ease-out), opacity 0.4s ease;
  opacity: 0;
  visibility: hidden;
}
.cookie-banner.show { transform: translate(-50%, 0); opacity: 1; visibility: visible; }

.cookie-banner p {
  font-size: 0.88rem;
  color: var(--ink-dim);
  margin-bottom: 1rem;
}

.cookie-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.7rem;
}
.cookie-actions .btn { padding: 0.55rem 1.15rem; font-size: 0.66rem; }
.cookie-actions .cookie-more {
  margin-left: auto;
  font-size: 0.78rem;
  color: var(--ink-faint);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.cookie-actions .cookie-more:hover { color: var(--cyan); }

/* --------------------------------------------------------------------------
   Legal pages & 404
   -------------------------------------------------------------------------- */

.page {
  padding: calc(var(--nav-h) + 4rem) 0 6rem;
  min-height: 70vh;
}
.page .headline { margin-bottom: 0.6rem; }
.page-updated {
  font-size: 0.8rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-bottom: 3rem;
}
.legal-body { max-width: 68ch; }
.legal-body h2 {
  font-size: 1.05rem;
  letter-spacing: 0.1em;
  margin: 2.6rem 0 0.9rem;
  color: var(--ink);
}
.legal-body p, .legal-body li { color: var(--ink-dim); font-size: 0.98rem; }
.legal-body ul { padding-left: 1.3rem; margin: 0.6rem 0 1rem; }
.legal-body li { margin-bottom: 0.35rem; }
.legal-body a {
  color: var(--cyan);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.notfound {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 6rem 1rem;
}
.notfound-code {
  font-family: var(--font-display);
  font-size: clamp(5rem, 18vw, 10rem);
  font-weight: 900;
  line-height: 1;
  background: linear-gradient(115deg, var(--blue), var(--cyan) 50%, var(--purple));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 0 30px rgba(79, 124, 255, 0.35));
  margin-bottom: 1rem;
}
.notfound h1 { font-size: clamp(1.2rem, 3vw, 1.7rem); margin-bottom: 1rem; }
.notfound p { color: var(--ink-dim); margin-bottom: 2.2rem; max-width: 44ch; }

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */

@media (max-width: 860px) {
  .nav-toggle { display: block; }
  .nav-links {
    position: fixed;
    inset: 0;
    z-index: 105;
    flex-direction: column;
    justify-content: center;
    gap: 2.4rem;
    background: rgba(4, 4, 15, 0.96);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s ease, visibility 0.4s ease;
  }
  .nav-links.open { opacity: 1; visibility: visible; }
  .nav-links a:not(.btn) { font-size: 1rem; }
  .circuit-decor { display: none; }
  .footer-links { text-align: left; }
  .footer-grid { flex-direction: column; }
}

@media (max-width: 480px) {
  .hero-cta .btn { width: 100%; }
  .cookie-actions .cookie-more { margin-left: 0; }
}

/* --------------------------------------------------------------------------
   Reduced motion
   -------------------------------------------------------------------------- */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .reveal { opacity: 1; transform: none; }
  .cursor-glow, .scroll-hint { display: none; }
  .cookie-banner { transition: none; }
  .cookie-banner.show { transform: translate(-50%, 0); }
}
