:root {
  --abyss: #01060d;
  --depth: #041018;
  --mid: #0a2436;
  --teal: #2fd4c8;
  --teal-dim: rgba(47, 212, 200, 0.35);
  --cable: #6a9dff;
  --foam: #d7eef5;
  --mist: rgba(180, 220, 230, 0.72);
  --ink: #e8f4f8;
  --muted: rgba(200, 228, 236, 0.68);
  --line: rgba(47, 212, 200, 0.22);
  --font-display: "Syne", sans-serif;
  --font-body: "Figtree", sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  font-family: var(--font-body);
  font-weight: 400;
  line-height: 1.55;
  background: radial-gradient(120% 80% at 50% -10%, #0c3a4f 0%, var(--depth) 42%, var(--abyss) 100%);
  overflow-x: hidden;
}

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

.haze {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    radial-gradient(ellipse 70% 45% at 50% 0%, rgba(20, 70, 90, 0.45), transparent 70%),
    linear-gradient(180deg, transparent 0%, rgba(1, 6, 13, 0.55) 70%, rgba(1, 6, 13, 0.88) 100%);
}

.top,
main,
.foot {
  position: relative;
  z-index: 2;
}

.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 1.25rem clamp(1.25rem, 4vw, 3rem);
  animation: rise 0.9s ease both;
}

.mark {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 0.02em;
  color: var(--foam);
  text-decoration: none;
}

.top nav {
  display: flex;
  gap: 1.25rem;
  flex-wrap: wrap;
}

.top nav a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
  transition: color 0.2s ease;
}

.top nav a:hover,
.top nav a[aria-current="page"] {
  color: var(--teal);
}

.hero {
  min-height: calc(100vh - 4.5rem);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 2rem clamp(1.25rem, 5vw, 4.5rem) 4rem;
  max-width: 48rem;
  animation: rise 1.1s 0.1s ease both;
}

.brand {
  margin: 0 0 0.75rem;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2.8rem, 9vw, 5.5rem);
  line-height: 0.95;
  letter-spacing: -0.03em;
  color: var(--foam);
  text-shadow: 0 0 40px rgba(47, 212, 200, 0.25);
}

.brand.compact {
  font-size: clamp(1.6rem, 4vw, 2.2rem);
  margin-bottom: 0.5rem;
}

.hero h1 {
  margin: 0 0 1rem;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.35rem, 3.2vw, 2rem);
  line-height: 1.25;
  color: var(--mist);
  max-width: 22ch;
}

.lede,
.section-lede {
  margin: 0 0 1.75rem;
  color: var(--muted);
  font-size: 1.05rem;
  max-width: 38rem;
}

.cta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  margin-bottom: 1.5rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.7rem 1.15rem;
  border-radius: 0.35rem;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

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

.btn.primary {
  background: linear-gradient(135deg, #1fa9a0, #2fd4c8 60%, #7ee7df);
  color: #031018;
}

.btn.ghost {
  border: 1px solid var(--line);
  color: var(--foam);
  background: rgba(4, 20, 30, 0.35);
}

.btn.ghost:hover {
  border-color: var(--teal);
  color: var(--teal);
}

.hint {
  margin: 0;
  font-size: 0.88rem;
  color: rgba(200, 228, 236, 0.45);
  letter-spacing: 0.01em;
}

.panel {
  padding: 4.5rem clamp(1.25rem, 5vw, 4.5rem);
  max-width: 58rem;
  border-top: 1px solid var(--line);
  animation: rise 1s ease both;
}

.panel h2,
.article h1,
.article h2 {
  margin: 0 0 0.85rem;
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--foam);
}

.panel h2 {
  font-size: clamp(1.6rem, 3vw, 2.1rem);
}

.projects {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 1rem;
}

@media (min-width: 720px) {
  .projects {
    grid-template-columns: 1fr 1fr;
  }
}

.projects a {
  display: grid;
  gap: 0.35rem;
  padding: 1.25rem 1.35rem;
  text-decoration: none;
  color: inherit;
  border: 1px solid transparent;
  border-image: linear-gradient(135deg, rgba(47, 212, 200, 0.35), rgba(106, 157, 255, 0.2)) 1;
  background: linear-gradient(160deg, rgba(8, 36, 52, 0.72), rgba(3, 14, 24, 0.55));
  transition: border-color 0.2s ease, transform 0.2s ease, background 0.2s ease;
}

.projects a:hover {
  transform: translateY(-2px);
  background: linear-gradient(160deg, rgba(12, 48, 66, 0.85), rgba(4, 18, 30, 0.7));
}

.projects .tag {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--teal);
  font-weight: 600;
}

.projects strong {
  font-family: var(--font-display);
  font-size: 1.25rem;
  color: var(--foam);
}

.projects a > span:last-child {
  color: var(--muted);
  font-size: 0.95rem;
}

.facts {
  list-style: none;
  margin: 0 0 1.5rem;
  padding: 0;
  display: grid;
  gap: 0.65rem;
}

.facts li {
  display: grid;
  grid-template-columns: 5.5rem 1fr;
  gap: 0.75rem;
  color: var(--muted);
  font-size: 0.98rem;
}

.facts span {
  color: var(--teal);
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-size: 0.75rem;
  padding-top: 0.2rem;
}

.more a {
  color: var(--teal);
  text-decoration: none;
  font-weight: 600;
}

.more a:hover {
  text-decoration: underline;
}

.article {
  max-width: 40rem;
  padding: 3rem clamp(1.25rem, 5vw, 4.5rem) 5rem;
  animation: rise 0.9s ease both;
}

.article p,
.article li {
  color: var(--muted);
}

.article a {
  color: var(--teal);
}

.article h2 {
  margin-top: 2rem;
  font-size: 1.25rem;
}

.contact-line {
  margin: 1.5rem 0 2rem;
}

.foot {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 1.5rem clamp(1.25rem, 4vw, 3rem) 2rem;
  border-top: 1px solid var(--line);
  color: rgba(200, 228, 236, 0.4);
  font-size: 0.88rem;
}

.foot a {
  color: var(--muted);
  text-decoration: none;
}

.foot a:hover {
  color: var(--teal);
}

.subpage .hero {
  min-height: auto;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}
