/* ==========================================================================
   Pinke – Orbitale Informatik
   Pure CSS, mobile-first, no external dependencies
   ========================================================================== */

:root {
  --bg-0: #05060f;
  --bg-1: #0b0e1f;
  --bg-2: #11152b;
  --line: rgba(140, 160, 255, 0.14);
  --neon-blue: #3ad6ff;
  --neon-violet: #8b5cf6;
  --grad: linear-gradient(135deg, var(--neon-blue), var(--neon-violet));
  --text: #e6e9f5;
  --text-dim: #8b93b5;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow-glow: 0 0 0 1px rgba(58, 214, 255, 0.25), 0 10px 40px -10px rgba(139, 92, 246, 0.45);
  --font-sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-mono: ui-monospace, "SFMono-Regular", "JetBrains Mono", Menlo, Consolas, monospace;
  --container: 1200px;
  --header-h: 72px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: var(--header-h); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: clamp(1rem, 0.95rem + 0.2vw, 1.0625rem);
  line-height: 1.65;
  color: var(--text);
  background: var(--bg-0);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img, svg, picture, canvas { display: block; max-width: 100%; }
img { height: auto; }
a { color: var(--neon-blue); text-decoration: none; }
a:hover { color: #fff; }
h1, h2, h3 { line-height: 1.15; margin: 0 0 0.6em; font-weight: 700; letter-spacing: -0.01em; }
p { margin: 0 0 1em; }
ul { padding: 0; margin: 0; list-style: none; }
:focus-visible { outline: 2px solid var(--neon-blue); outline-offset: 3px; border-radius: 4px; }

.container { width: min(100% - 2.5rem, var(--container)); margin-inline: auto; }

.skip-link {
  position: absolute; left: 1rem; top: -100px; z-index: 100;
  padding: 0.6rem 1rem; background: var(--neon-blue); color: var(--bg-0); border-radius: 8px; font-weight: 600;
}
.skip-link:focus { top: 1rem; }

.gradient-text {
  background: var(--grad);
  -webkit-background-clip: text; background-clip: text;
  color: transparent;
}

/* ---------- Buttons ---------- */
.btn {
  --pad-y: 0.85rem; --pad-x: 1.6rem;
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  min-height: 48px;
  padding: var(--pad-y) var(--pad-x);
  border-radius: 999px;
  font: 600 0.98rem/1 var(--font-sans);
  letter-spacing: 0.02em;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease), background 0.3s, color 0.3s;
}
.btn--primary { background: var(--grad); color: #fff; box-shadow: 0 8px 30px -8px rgba(139, 92, 246, 0.7); }
.btn--primary:hover { color: #fff; transform: translateY(-2px); box-shadow: 0 12px 36px -6px rgba(58, 214, 255, 0.6); }
.btn--ghost { border-color: rgba(230, 233, 245, 0.3); color: var(--text); background: rgba(255,255,255,0.03); backdrop-filter: blur(6px); }
.btn--ghost:hover { border-color: var(--neon-blue); color: #fff; transform: translateY(-2px); }
.btn--small { --pad-y: 0.55rem; --pad-x: 1.2rem; min-height: 40px; font-size: 0.9rem; }
.btn--block { width: 100%; }

/* ---------- Header / Nav ---------- */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  height: var(--header-h);
  transition: background 0.4s, backdrop-filter 0.4s, border-color 0.4s, height 0.3s;
  border-bottom: 1px solid transparent;
}
.site-header.is-scrolled {
  background: rgba(5, 6, 15, 0.72);
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  border-color: var(--line);
  --header-h: 62px;
}
.nav { height: 100%; display: flex; align-items: center; justify-content: space-between; }
.nav__brand img { width: clamp(120px, 30vw, 150px); height: auto; }

.nav__toggle {
  display: inline-flex; flex-direction: column; justify-content: center; gap: 5px;
  width: 44px; height: 44px; padding: 10px;
  background: transparent; border: 1px solid var(--line); border-radius: 12px; cursor: pointer;
  position: relative; z-index: 60;
}
.nav__toggle span { display: block; height: 2px; background: var(--text); border-radius: 2px; transition: transform 0.3s var(--ease), opacity 0.3s; }
.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); }

.nav__menu {
  position: fixed; inset: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1.75rem;
  background: rgba(5, 6, 15, 0.96);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  font-size: 1.35rem;
  opacity: 0; visibility: hidden;
  transition: opacity 0.35s var(--ease), visibility 0.35s;
}
.nav__menu.is-open { opacity: 1; visibility: visible; }
.nav__menu a:not(.btn) { color: var(--text); position: relative; padding: 0.25rem 0; }
.nav__menu a:not(.btn)::after {
  content: ""; position: absolute; left: 0; bottom: -2px; height: 2px; width: 100%;
  background: var(--grad); transform: scaleX(0); transform-origin: left; transition: transform 0.35s var(--ease);
}
.nav__menu a:not(.btn):hover::after, .nav__menu a.is-active::after { transform: scaleX(1); }
.nav__menu a.is-active { color: #fff; }
body.menu-open { overflow: hidden; }

@media (min-width: 860px) {
  .nav__toggle { display: none; }
  .nav__menu {
    position: static; flex-direction: row; gap: 2.2rem;
    background: none; backdrop-filter: none; -webkit-backdrop-filter: none;
    font-size: 0.95rem; opacity: 1; visibility: visible;
  }
  .nav__menu a:not(.btn) { color: var(--text-dim); }
  .nav__menu a:not(.btn):hover { color: #fff; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative; isolation: isolate;
  min-height: 100vh; min-height: 100svh;
  display: flex; align-items: center;
  padding: calc(var(--header-h) + 3rem) 0 6rem;
  overflow: hidden;
}
.hero__bg, .hero__stars, .hero__overlay { position: absolute; inset: 0; z-index: -1; }
.hero__bg img {
  width: 100%; height: 110%; object-fit: cover; object-position: 60% 70%;
  will-change: transform;
}
.hero__stars { width: 100%; height: 100%; mix-blend-mode: screen; }
.hero__overlay {
  background:
    linear-gradient(90deg, rgba(5, 6, 15, 0.75) 0%, rgba(5, 6, 15, 0.35) 45%, rgba(5, 6, 15, 0) 75%),
    linear-gradient(180deg, rgba(5, 6, 15, 0.4) 0%, rgba(5, 6, 15, 0) 30%, rgba(5, 6, 15, 0) 70%, var(--bg-0) 100%);
}
@media (max-width: 720px) {
  .hero__overlay { background: linear-gradient(180deg, rgba(5, 6, 15, 0.55) 0%, rgba(5, 6, 15, 0.45) 50%, var(--bg-0) 100%); }
  .eyebrow__coords { display: none; }
}
.hero__content { max-width: var(--container); }
.eyebrow {
  display: inline-flex; align-items: center; gap: 0.6rem;
  font: 500 clamp(0.7rem, 0.65rem + 0.25vw, 0.82rem)/1.4 var(--font-mono);
  letter-spacing: 0.12em; text-transform: uppercase; color: var(--neon-blue);
  padding: 0.45rem 0.9rem; border: 1px solid rgba(58, 214, 255, 0.3); border-radius: 999px;
  background: rgba(58, 214, 255, 0.06); backdrop-filter: blur(6px);
  margin-bottom: 1.5rem;
}
.pulse { width: 8px; height: 8px; border-radius: 50%; background: var(--neon-blue); box-shadow: 0 0 0 0 rgba(58, 214, 255, 0.7); animation: pulse 2s infinite; flex: none; }
@keyframes pulse { 70% { box-shadow: 0 0 0 10px rgba(58, 214, 255, 0); } 100% { box-shadow: 0 0 0 0 rgba(58, 214, 255, 0); } }

.hero__title { font-size: clamp(2.2rem, 1.2rem + 5vw, 4.8rem); max-width: 16ch; font-weight: 800; letter-spacing: -0.025em; }
.hero__title .gradient-text { display: inline; }
.hero__lead { font-size: clamp(1.02rem, 0.95rem + 0.45vw, 1.25rem); color: #c3c9e4; max-width: 58ch; margin-bottom: 2.2rem; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 0.9rem; }

.hero__scroll {
  position: absolute; left: 50%; bottom: 2rem; transform: translateX(-50%);
  width: 28px; height: 46px; border: 2px solid rgba(230, 233, 245, 0.35); border-radius: 20px;
}
.hero__scroll span { position: absolute; left: 50%; top: 8px; width: 4px; height: 8px; margin-left: -2px; border-radius: 2px; background: var(--neon-blue); animation: scroll 1.8s infinite; }
@keyframes scroll { 0% { opacity: 0; transform: translateY(0); } 30% { opacity: 1; } 100% { opacity: 0; transform: translateY(16px); } }
@media (max-height: 640px) { .hero__scroll { display: none; } }

/* ---------- Sections ---------- */
.section { position: relative; padding: clamp(4.5rem, 3rem + 7vw, 8.5rem) 0; }
.section__label { font: 500 0.82rem/1 var(--font-mono); letter-spacing: 0.14em; text-transform: uppercase; color: var(--neon-blue); margin-bottom: 1rem; }
.section__title { font-size: clamp(1.8rem, 1.2rem + 2.6vw, 3rem); max-width: 22ch; }
.section__head { text-align: center; margin-bottom: clamp(2.5rem, 2rem + 2vw, 4rem); }
.section__head .section__title { margin-inline: auto; }
.section__intro { color: var(--text-dim); max-width: 60ch; margin-inline: auto; font-size: 1.08rem; }

/* subtle grid backdrop */
.services::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background-image:
    linear-gradient(var(--line) 1px, transparent 1px),
    linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse at center, #000 10%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse at center, #000 10%, transparent 70%);
  opacity: 0.5;
}
.services { isolation: isolate; }

/* ---------- About ---------- */
.about__grid { display: grid; gap: clamp(2.5rem, 2rem + 3vw, 5rem); align-items: center; }
.about__text > p { color: #bfc5e0; }
.stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1rem; margin-top: 2rem; }
.stat {
  padding: 1.2rem; border-radius: var(--radius-sm);
  background: linear-gradient(180deg, rgba(255,255,255,0.04), rgba(255,255,255,0.01));
  border: 1px solid var(--line);
}
.stat__value { display: block; font-size: clamp(1.6rem, 1.2rem + 1.5vw, 2.2rem); font-weight: 800; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; font-variant-numeric: tabular-nums; }
.stat__label { display: block; font-size: 0.85rem; color: var(--text-dim); line-height: 1.4; margin-top: 0.25rem; }

.about__media { position: relative; margin: 0; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-glow); }
.about__media img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.about__media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 55%, rgba(5,6,15,0.7)); pointer-events: none; }
.hud-tag {
  position: absolute; left: 1rem; bottom: 1rem; z-index: 1;
  font: 500 0.75rem/1 var(--font-mono); letter-spacing: 0.1em; text-transform: uppercase;
  padding: 0.5rem 0.75rem; border-radius: 6px; color: var(--neon-blue);
  background: rgba(5, 6, 15, 0.65); border: 1px solid rgba(58, 214, 255, 0.3); backdrop-filter: blur(6px);
}

@media (min-width: 960px) {
  .about__grid { grid-template-columns: 1.05fr 1fr; }
  .stats { grid-template-columns: repeat(2, 1fr); }
}

/* ---------- Service cards ---------- */
.cards { display: grid; gap: 1.25rem; grid-template-columns: 1fr; }
@media (min-width: 640px) { .cards { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .cards { grid-template-columns: repeat(3, 1fr); gap: 1.5rem; } }

.card {
  position: relative; padding: 2rem 1.75rem;
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(17, 21, 43, 0.85), rgba(11, 14, 31, 0.85));
  border: 1px solid var(--line);
  backdrop-filter: blur(10px);
  transition: transform 0.4s var(--ease), border-color 0.4s, box-shadow 0.4s;
  overflow: hidden;
}
.card::before {
  content: ""; position: absolute; inset: -1px; border-radius: inherit; padding: 1px;
  background: var(--grad);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  opacity: 0; transition: opacity 0.4s;
}
.card:hover { transform: translateY(-6px); box-shadow: 0 20px 50px -20px rgba(139, 92, 246, 0.55); }
.card:hover::before { opacity: 1; }
.card h3 { font-size: 1.2rem; }
.card p { color: var(--text-dim); margin: 0; font-size: 0.97rem; }
.card__icon {
  width: 56px; height: 56px; display: grid; place-items: center; margin-bottom: 1.4rem;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(58, 214, 255, 0.14), rgba(139, 92, 246, 0.14));
  border: 1px solid rgba(58, 214, 255, 0.25);
}
.card__icon svg { width: 30px; height: 30px; fill: none; stroke: var(--neon-blue); stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- Missions ---------- */
.missions__grid { display: grid; gap: 1.5rem; grid-template-columns: 1fr; }
@media (min-width: 720px) { .missions__grid { grid-template-columns: repeat(2, 1fr); } }

.mission {
  display: flex; flex-direction: column;
  border-radius: var(--radius); overflow: hidden;
  background: var(--bg-1); border: 1px solid var(--line);
  transition: transform 0.4s var(--ease), box-shadow 0.4s, border-color 0.4s;
}
.mission:hover { transform: translateY(-6px); border-color: rgba(58, 214, 255, 0.35); box-shadow: 0 24px 60px -24px rgba(58, 214, 255, 0.4); }
.mission__media { overflow: hidden; aspect-ratio: 16 / 10; }
.mission__media img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.8s var(--ease); }
.mission:hover .mission__media img { transform: scale(1.06); }
.mission__body { position: relative; padding: 1.6rem 1.6rem 1.9rem; }
.mission__body h3 { font-size: clamp(1.15rem, 1.05rem + 0.4vw, 1.35rem); }
.mission__body p:last-child { color: var(--text-dim); margin: 0; }
.mission__code { font: 600 0.8rem/1 var(--font-mono); letter-spacing: 0.16em; color: var(--neon-violet); margin: 0.9rem 0 0.6rem; }

.badge {
  display: inline-flex; align-items: center; gap: 0.4rem;
  font: 600 0.72rem/1 var(--font-mono); letter-spacing: 0.08em; text-transform: uppercase;
  padding: 0.4rem 0.7rem; border-radius: 999px; border: 1px solid;
}
.badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge--active { color: #4ef0b0; border-color: rgba(78, 240, 176, 0.35); background: rgba(78, 240, 176, 0.08); }
.badge--done { color: var(--neon-blue); border-color: rgba(58, 214, 255, 0.35); background: rgba(58, 214, 255, 0.08); }
.badge--planned { color: #c4a6ff; border-color: rgba(139, 92, 246, 0.45); background: rgba(139, 92, 246, 0.1); }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--line); padding: 2.5rem 0; background: linear-gradient(180deg, var(--bg-0), #03040a); }
.footer__inner { display: flex; flex-direction: column; align-items: center; gap: 1.5rem; text-align: center; }
.footer__brand img { width: 130px; }
.footer__links { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.5rem 1.6rem; }
.footer__links a { color: var(--text-dim); font-size: 0.92rem; }
.footer__links a:hover { color: #fff; }
.footer__copy { margin: 0; color: #5c6385; font-size: 0.85rem; font-family: var(--font-mono); }
@media (min-width: 860px) {
  .footer__inner { flex-direction: row; justify-content: space-between; text-align: left; }
}

/* ---------- Reveal animation ---------- */
.js .reveal { opacity: 0; transform: translateY(28px); transition: opacity 0.9s var(--ease), transform 0.9s var(--ease); }
.js .reveal.is-visible { opacity: 1; transform: none; }

/* ---------- Large screens ---------- */
@media (min-width: 1800px) {
  :root { --container: 1400px; }
  html { font-size: 112.5%; }
}

/* ---------- 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; }
  .js .reveal { opacity: 1; transform: none; }
  .hero__stars { display: none; }
}
