:root {
  color-scheme: dark;
  --bg: #06070a;
  --bg-2: #0b1020;
  --panel: rgba(255, 255, 255, 0.075);
  --panel-strong: rgba(255, 255, 255, 0.12);
  --text: #f5f7fb;
  --muted: #aab3c5;
  --line: rgba(255, 255, 255, 0.15);
  --accent: #82f7c6;
  --accent-2: #8ab4ff;
  --warning: #ffd166;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.42);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--text);
  overflow-x: hidden;
}

body::before,
body::after {
  content: "";
  position: fixed;
  inset: -20%;
  pointer-events: none;
  z-index: -2;
}

body::before {
  background:
    radial-gradient(circle at 20% 20%, rgba(130, 247, 198, 0.26), transparent 28%),
    radial-gradient(circle at 80% 12%, rgba(138, 180, 255, 0.22), transparent 28%),
    radial-gradient(circle at 60% 84%, rgba(255, 209, 102, 0.14), transparent 26%),
    linear-gradient(145deg, #05060a, #0a1020 54%, #07120f);
  animation: drift 18s ease-in-out infinite alternate;
}

body::after {
  z-index: -1;
  opacity: 0.2;
  background-image:
    url("/assets/homelab-pattern.svg"),
    linear-gradient(rgba(255,255,255,0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.05) 1px, transparent 1px);
  background-size: 240px 240px, 44px 44px, 44px 44px;
  background-position: 0 0, 0 0, 0 0;
  mask-image: radial-gradient(circle at center, black 0, transparent 72%);
  animation: gridShift 30s linear infinite;
}

@keyframes drift {
  from { transform: translate3d(-2%, -1%, 0) scale(1); filter: hue-rotate(0deg); }
  to { transform: translate3d(2%, 1%, 0) scale(1.05); filter: hue-rotate(12deg); }
}

@keyframes gridShift {
  from { background-position: 0 0, 0 0, 0 0; }
  to { background-position: 240px 120px, 88px 44px, 88px 44px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
  }
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 20;
  padding: 0.75rem 1rem;
  border-radius: 999px;
  background: var(--text);
  color: var(--bg);
  transition: top 0.2s ease;
}

.skip-link:focus { top: 1rem; }

.wrap {
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  backdrop-filter: blur(18px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(6, 7, 10, 0.72);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--text);
  text-decoration: none;
  font-weight: 700;
  letter-spacing: -0.03em;
}

.brand-logo {
  width: 36px;
  height: 36px;
  border-radius: 14px;
  box-shadow: 0 0 40px rgba(130, 247, 198, 0.24);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.nav-links a,
.lang-toggle button {
  color: var(--muted);
  text-decoration: none;
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 0.55rem 0.75rem;
  font: inherit;
  background: transparent;
  cursor: pointer;
}

.nav-links a:hover,
.lang-toggle button:hover,
.lang-toggle button[aria-pressed="true"] {
  color: var(--text);
  border-color: rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.06);
}

.lang-toggle {
  display: inline-flex;
  gap: 0.2rem;
  padding: 0.2rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.2);
}

.hero {
  min-height: calc(100vh - 72px);
  display: grid;
  align-items: center;
  padding: 7rem 0 5rem;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(280px, 0.9fr);
  gap: clamp(2rem, 6vw, 5rem);
  align-items: center;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  width: fit-content;
  margin: 0 0 1.4rem;
  padding: 0.55rem 0.8rem;
  border: 1px solid rgba(130, 247, 198, 0.22);
  border-radius: 999px;
  background: rgba(130, 247, 198, 0.08);
  color: #c8ffe8;
  font-size: 0.95rem;
}

.pulse {
  width: 0.6rem;
  height: 0.6rem;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 7px rgba(130, 247, 198, 0.12);
}

h1 {
  margin: 0;
  max-width: 850px;
  font-size: clamp(3rem, 8vw, 6.5rem);
  line-height: 0.94;
  letter-spacing: -0.075em;
}

.lead {
  max-width: 690px;
  margin: 1.6rem 0 0;
  color: var(--muted);
  font-size: clamp(1.12rem, 2vw, 1.4rem);
  line-height: 1.6;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-top: 2rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  min-height: 46px;
  padding: 0.8rem 1rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--text);
  text-decoration: none;
  background: rgba(255, 255, 255, 0.06);
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.22);
}

.btn.primary {
  color: #04100b;
  border-color: transparent;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  font-weight: 700;
}

.btn:hover { transform: translateY(-1px); }

.orbit-card {
  position: relative;
  min-height: 420px;
  border: 1px solid var(--line);
  border-radius: 32px;
  background: linear-gradient(180deg, rgba(255,255,255,0.12), rgba(255,255,255,0.045));
  box-shadow: var(--shadow);
  overflow: hidden;
}

.orbit-card::before {
  content: "";
  position: absolute;
  inset: 12%;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 50%;
  animation: spin 18s linear infinite;
}

.orbit-card::after {
  content: "";
  position: absolute;
  width: 42%;
  aspect-ratio: 1;
  left: 29%;
  top: 29%;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(130, 247, 198, 0.2), rgba(138, 180, 255, 0.12) 55%, transparent 68%);
  box-shadow: 0 0 90px rgba(130, 247, 198, 0.22);
}

.hero-mark {
  position: absolute;
  width: min(46%, 190px);
  height: auto;
  left: 50%;
  top: 47%;
  transform: translate(-50%, -50%);
  filter: drop-shadow(0 0 42px rgba(130, 247, 198, 0.24));
  z-index: 1;
}

@keyframes spin { to { transform: rotate(360deg); } }

.status-list {
  position: absolute;
  inset: auto 1rem 1rem 1rem;
  display: grid;
  gap: 0.65rem;
  z-index: 2;
}

.status-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.8rem 0.9rem;
  border: 1px solid rgba(255,255,255,0.13);
  border-radius: 18px;
  background: rgba(3, 6, 12, 0.58);
  color: var(--muted);
}

.status-row strong { color: var(--text); font-size: 0.95rem; }
.code-pill {
  color: #bafbdd;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.82rem;
}

section {
  padding: 5rem 0;
}

.section-grid {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: clamp(1.5rem, 5vw, 4rem);
  align-items: start;
}

h2 {
  margin: 0;
  font-size: clamp(2rem, 4vw, 3.4rem);
  line-height: 1.02;
  letter-spacing: -0.055em;
}

.section-copy {
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1.75;
}

.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-top: 2rem;
}

.card {
  min-height: 190px;
  padding: 1.25rem;
  border: 1px solid var(--line);
  border-radius: 26px;
  background: var(--panel);
  box-shadow: 0 18px 60px rgba(0,0,0,0.18);
}

.card h3 {
  margin: 0 0 0.75rem;
  font-size: 1.05rem;
  letter-spacing: -0.02em;
}

.card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
}

.notice {
  margin-top: 2rem;
  padding: 1.25rem;
  border: 1px solid rgba(255, 209, 102, 0.25);
  border-radius: 24px;
  background: rgba(255, 209, 102, 0.08);
  color: #ffe6a3;
  line-height: 1.65;
}

.legal-page {
  padding: 5rem 0;
}

.legal-layout {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: clamp(1.5rem, 4vw, 4rem);
  align-items: start;
}

.legal-nav {
  position: sticky;
  top: 96px;
  display: grid;
  gap: 0.55rem;
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(255,255,255,0.055);
}

.legal-nav a {
  color: var(--muted);
  text-decoration: none;
  padding: 0.5rem 0.65rem;
  border-radius: 12px;
}

.legal-nav a:hover { color: var(--text); background: rgba(255,255,255,0.07); }

.legal-content {
  padding: clamp(1.2rem, 3vw, 2rem);
  border: 1px solid var(--line);
  border-radius: 30px;
  background: rgba(255,255,255,0.065);
  box-shadow: var(--shadow);
}

.legal-content h1 {
  font-size: clamp(2.4rem, 5vw, 4rem);
  line-height: 1;
}

.legal-content h2 {
  margin-top: 2.6rem;
  font-size: clamp(1.5rem, 3vw, 2.2rem);
}

.legal-content p,
.legal-content li {
  color: var(--muted);
  line-height: 1.75;
}

.legal-content a,
.section-copy a,
.footer a { color: #bafbdd; }

address { font-style: normal; color: var(--muted); line-height: 1.7; }

.footer {
  padding: 2rem 0 3rem;
  color: var(--muted);
  border-top: 1px solid rgba(255,255,255,0.08);
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

[hidden] { display: none !important; }

@media (max-width: 860px) {
  .hero { padding-top: 4rem; }
  .hero-grid,
  .section-grid,
  .legal-layout { grid-template-columns: 1fr; }
  .orbit-card { min-height: 320px; }
  .cards { grid-template-columns: 1fr; }
  .legal-nav { position: static; }
}

@media (max-width: 620px) {
  .wrap { width: min(100% - 28px, 1120px); }
  .nav { align-items: flex-start; }
  .brand span:last-child { display: none; }
  .nav-links { font-size: 0.92rem; }
  h1 { font-size: clamp(2.75rem, 16vw, 4.5rem); }
  .orbit-card { display: none; }
}
