:root {
  color-scheme: dark;
  --bg: #0a0a0a;
  --surface: #141414;
  --text: #f5f5f5;
  --muted: #8a8a8a;
  --stroke: rgba(255, 255, 255, 0.11);
  --accent-a: #89aacc;
  --accent-b: #4e85bf;
  --font-body: "Inter", ui-sans-serif, system-ui, sans-serif;
  --font-display: "Instrument Serif", Georgia, serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  letter-spacing: 0;
}

body.loading {
  overflow: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

img,
video {
  display: block;
}

.loader {
  position: fixed;
  inset: 0;
  z-index: 999;
  display: grid;
  place-items: center;
  background: var(--bg);
  transition: opacity 420ms ease, visibility 420ms ease;
}

.loader.done {
  opacity: 0;
  visibility: hidden;
}

.loader-label {
  position: absolute;
  top: 28px;
  left: 28px;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.3em;
  text-transform: uppercase;
}

.loader-word {
  font-family: var(--font-display);
  font-size: clamp(3.8rem, 9vw, 8rem);
  font-style: italic;
  color: rgba(255, 255, 255, 0.82);
}

.loader-count {
  position: absolute;
  right: 28px;
  bottom: 28px;
  font-family: var(--font-display);
  font-size: clamp(4.4rem, 11vw, 10rem);
  font-variant-numeric: tabular-nums;
  line-height: 0.8;
}

.loader-bar {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 3px;
  background: rgba(255, 255, 255, 0.08);
  transform-origin: left center;
}

.loader-bar span {
  display: block;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, var(--accent-a), var(--accent-b));
  box-shadow: 0 0 8px rgba(137, 170, 204, 0.35);
  transform: scaleX(0);
  transform-origin: left center;
}

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  display: flex;
  justify-content: center;
  padding: 18px 16px 0;
  pointer-events: none;
}

.nav-pill {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  padding: 8px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 999px;
  background: rgba(20, 20, 20, 0.78);
  backdrop-filter: blur(18px);
  pointer-events: auto;
  transition: box-shadow 180ms ease, background 180ms ease;
}

.site-header.scrolled .nav-pill {
  background: rgba(20, 20, 20, 0.92);
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.35);
}

.brand-mark {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  padding: 2px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--accent-a), var(--accent-b));
  transition: transform 180ms ease;
}

.brand-mark:hover {
  transform: scale(1.08);
}

.brand-mark span {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  border-radius: inherit;
  background: var(--bg);
  font-family: var(--font-display);
  font-size: 0.9rem;
  font-style: italic;
}

.nav-pill > a:not(.brand-mark) {
  position: relative;
  padding: 10px 14px;
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 650;
  transition: color 180ms ease, background 180ms ease;
}

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

.nav-divider {
  width: 1px;
  height: 22px;
  margin: 0 4px;
  background: rgba(255, 255, 255, 0.12);
}

.say-hi span {
  color: var(--text);
}

.hero {
  position: relative;
  min-height: 100vh;
  display: grid;
  place-items: center;
  overflow: hidden;
  padding: 120px 20px 100px;
  text-align: center;
}

.hero-video,
.footer-video {
  position: absolute;
  inset: 50% auto auto 50%;
  min-width: 100%;
  min-height: 100%;
  width: auto;
  height: auto;
  object-fit: cover;
  transform: translate(-50%, -50%);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 50% 42%, rgba(137, 170, 204, 0.14), transparent 30rem),
    rgba(0, 0, 0, 0.58);
}

.hero-fade {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 210px;
  background: linear-gradient(180deg, transparent, var(--bg));
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 820px;
}

.eyebrow {
  margin: 0 0 26px;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.3em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 22px;
  font-family: var(--font-display);
  font-size: clamp(5rem, 15vw, 12rem);
  font-style: italic;
  font-weight: 400;
  line-height: 0.82;
}

h2 {
  margin-bottom: 0;
  font-size: clamp(2.4rem, 5vw, 5rem);
  font-weight: 650;
  line-height: 0.98;
}

em {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 400;
}

.role-line {
  margin-bottom: 16px;
  color: rgba(255, 255, 255, 0.78);
  font-size: clamp(1.15rem, 2vw, 1.45rem);
}

.role-line span {
  font-family: var(--font-display);
  font-size: 1.24em;
  font-style: italic;
  color: var(--text);
}

.hero-text {
  max-width: 560px;
  margin: 0 auto 38px;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.7;
}

.hero-actions {
  display: inline-flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
}

.button,
.text-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 24px;
  border: 1px solid var(--stroke);
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 750;
  transition: transform 180ms ease, color 180ms ease, background 180ms ease, border-color 180ms ease;
}

.button:hover,
.text-link:hover {
  transform: translateY(-2px);
  border-color: rgba(137, 170, 204, 0.8);
}

.button.primary {
  border-color: transparent;
  background: var(--text);
  color: var(--bg);
}

.button.ghost {
  background: rgba(10, 10, 10, 0.62);
  color: var(--text);
}

.scroll-cue {
  position: absolute;
  left: 50%;
  bottom: 28px;
  z-index: 3;
  transform: translateX(-50%);
  display: grid;
  justify-items: center;
  gap: 10px;
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.scroll-cue i {
  position: relative;
  width: 1px;
  height: 42px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.16);
}

.scroll-cue i::after {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  width: 1px;
  height: 18px;
  background: var(--text);
  animation: scroll-down 1.5s ease-in-out infinite;
}

main {
  overflow: hidden;
}

.section {
  width: min(1200px, calc(100% - 40px));
  margin: 0 auto;
  padding: 86px 0;
}

.intro {
  border-top: 1px solid var(--stroke);
  border-bottom: 1px solid var(--stroke);
}

.intro p {
  max-width: 900px;
  margin: 0;
  color: rgba(255, 255, 255, 0.76);
  font-size: clamp(1.35rem, 3vw, 2.6rem);
  line-height: 1.18;
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 28px;
  margin-bottom: 30px;
}

.section-head.compact {
  display: block;
  max-width: 460px;
  margin-bottom: 0;
}

.bento-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 18px;
}

.project-card {
  position: relative;
  min-height: 420px;
  grid-column: span 5;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  padding: 28px;
  border: 1px solid var(--stroke);
  border-radius: 8px;
  background: var(--surface);
}

.project-card.wide {
  grid-column: span 7;
}

.project-card img,
.project-visual,
.card-shade,
.platform-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.project-card img,
.project-visual {
  object-fit: cover;
  transition: transform 520ms ease;
}

.project-card:hover img,
.project-card:hover .project-visual {
  transform: scale(1.06);
}

.project-card::after {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.16;
  background-image: radial-gradient(circle, #000 1px, transparent 1px);
  background-size: 4px 4px;
  pointer-events: none;
}

.card-shade {
  background: linear-gradient(180deg, transparent 20%, rgba(0, 0, 0, 0.82));
}

.platform-card {
  isolation: isolate;
}

.platform-card.modrinth {
  background:
    radial-gradient(circle at 78% 18%, rgba(248, 249, 250, 0.2), transparent 14rem),
    linear-gradient(135deg, rgba(27, 217, 106, 0.18), rgba(27, 217, 106, 0.03)),
    #070907;
  border-color: rgba(27, 217, 106, 0.42);
}

.platform-card.curseforge {
  background:
    radial-gradient(circle at 82% 18%, rgba(255, 255, 255, 0.16), transparent 14rem),
    linear-gradient(135deg, rgba(60, 148, 196, 0.28), rgba(154, 122, 74, 0.12)),
    #07090a;
  border-color: rgba(60, 148, 196, 0.46);
}

.platform-bg {
  overflow: hidden;
  z-index: 0;
}

.platform-bg::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 34px 34px;
  mask-image: linear-gradient(120deg, transparent, #000 20%, #000 70%, transparent);
}

.platform-logo {
  position: absolute;
  right: 26px;
  top: 22px;
  width: clamp(128px, 20vw, 220px);
  height: clamp(128px, 20vw, 220px);
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 34px;
  color: rgba(255, 255, 255, 0.9);
  font-family: var(--font-display);
  font-size: clamp(5rem, 12vw, 10rem);
  font-style: italic;
  line-height: 1;
  transform: rotate(-8deg);
  box-shadow: inset 0 0 42px rgba(255, 255, 255, 0.08);
}

.modrinth .platform-logo {
  background: linear-gradient(135deg, #1bd96a, #0b7f42);
  color: #06140c;
}

.curseforge .platform-logo {
  background: linear-gradient(135deg, #3c94c4, #9a7a4a);
}

.platform-rings {
  position: absolute;
  right: -72px;
  bottom: -92px;
  width: 290px;
  height: 290px;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 999px;
}

.platform-rings::before,
.platform-rings::after {
  content: "";
  position: absolute;
  inset: 42px;
  border: inherit;
  border-radius: inherit;
}

.platform-rings::after {
  inset: 88px;
}

.card-copy {
  position: relative;
  z-index: 2;
  max-width: 520px;
}

.card-copy span,
.capability-list span {
  display: block;
  margin-bottom: 10px;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.card-copy h3 {
  margin-bottom: 12px;
  font-size: clamp(1.55rem, 3vw, 3rem);
  line-height: 1;
}

.card-copy p {
  max-width: 420px;
  margin: 0;
  color: rgba(255, 255, 255, 0.74);
  line-height: 1.58;
}

.card-copy strong {
  font-family: var(--font-display);
  font-size: 1.45em;
  font-weight: 400;
}

.project-card b {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 4;
  padding: 11px 16px;
  border-radius: 999px;
  background: var(--text);
  color: var(--bg);
  font-size: 0.88rem;
  opacity: 0;
  transform: translate(-50%, -40%);
  transition: opacity 180ms ease, transform 180ms ease;
}

.project-card:hover b {
  opacity: 1;
  transform: translate(-50%, -50%);
}

.project-visual.hardware {
  background:
    linear-gradient(135deg, rgba(137, 170, 204, 0.35), transparent),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.12) 0 1px, transparent 1px 28px),
    repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.08) 0 1px, transparent 1px 28px),
    #111;
}

.project-visual.sensors {
  background:
    radial-gradient(circle at 28% 26%, rgba(27, 217, 106, 0.28), transparent 12rem),
    radial-gradient(circle at 76% 72%, rgba(137, 170, 204, 0.32), transparent 14rem),
    linear-gradient(45deg, transparent 0 46%, rgba(255, 255, 255, 0.08) 46% 54%, transparent 54%),
    repeating-linear-gradient(135deg, rgba(255, 255, 255, 0.09) 0 1px, transparent 1px 18px),
    #101211;
}

.project-visual.discord {
  background:
    radial-gradient(circle at 70% 30%, rgba(88, 101, 242, 0.65), transparent 18rem),
    radial-gradient(circle at 20% 80%, rgba(137, 170, 204, 0.42), transparent 20rem),
    linear-gradient(135deg, #111, #080808);
}

.stack-section {
  border-top: 1px solid var(--stroke);
}

.stack-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 16px;
}

.stack-group {
  grid-column: span 6;
  min-height: 190px;
  padding: 22px;
  border: 1px solid var(--stroke);
  border-radius: 8px;
  background:
    radial-gradient(circle at 92% 10%, rgba(137, 170, 204, 0.1), transparent 13rem),
    rgba(255, 255, 255, 0.035);
}

.stack-group.tall {
  grid-column: span 12;
}

.stack-group h3 {
  margin: 0 0 18px;
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.95rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.stack-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.stack-cloud span {
  --ink: #fff;
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 50px;
  padding: 7px 16px 7px 8px;
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--brand) 70%, #fff 12%);
  border-radius: 999px;
  background:
    radial-gradient(circle at 24px 50%, color-mix(in srgb, var(--brand) 42%, transparent), transparent 3.2rem),
    linear-gradient(135deg, color-mix(in srgb, var(--brand) 78%, #000 22%), color-mix(in srgb, var(--brand) 45%, #000 55%));
  color: var(--ink);
  font-size: 0.86rem;
  font-weight: 850;
  box-shadow:
    inset 0 -18px 24px rgba(0, 0, 0, 0.2),
    0 10px 24px color-mix(in srgb, var(--brand) 22%, transparent);
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

.stack-cloud span:hover {
  transform: translateY(-2px);
  border-color: color-mix(in srgb, var(--brand) 82%, #fff 18%);
  box-shadow:
    inset 0 -18px 24px rgba(0, 0, 0, 0.16),
    0 16px 34px color-mix(in srgb, var(--brand) 34%, transparent);
}

.stack-cloud img,
.stack-logo {
  width: 34px;
  height: 34px;
  flex: 0 0 auto;
  padding: 7px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.25);
  object-fit: contain;
}

.stack-logo {
  display: inline-grid;
  place-items: center;
  font-style: normal;
  font-weight: 900;
  letter-spacing: 0;
  line-height: 1;
}

.text-logo {
  font-size: 0.86rem;
}

.oracle-mark {
  border-color: rgba(255, 255, 255, 0.24);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.18), transparent),
    rgba(0, 0, 0, 0.2);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 950;
}

.stack-cloud span::after {
  content: "";
  position: absolute;
  inset: 1px;
  border-radius: inherit;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.16), transparent 48%);
  pointer-events: none;
}

.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.stats div {
  min-height: 190px;
  padding: 26px;
  border: 1px solid var(--stroke);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.stats strong {
  display: block;
  margin-bottom: 18px;
  font-family: var(--font-display);
  font-size: clamp(3.4rem, 8vw, 7rem);
  font-weight: 400;
  line-height: 0.85;
}

.stats span {
  color: var(--muted);
  font-weight: 700;
}

.contact {
  position: relative;
  width: 100%;
  min-height: 560px;
  display: grid;
  place-items: center;
  overflow: hidden;
  padding: 110px 20px;
  text-align: center;
}

.footer-video {
  opacity: 0.34;
  transform: translate(-50%, -50%) scaleY(-1);
}

.contact::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: rgba(0, 0, 0, 0.62);
}

.marquee {
  position: absolute;
  left: 0;
  right: 0;
  top: 42px;
  z-index: 2;
  overflow: hidden;
  color: transparent;
  -webkit-text-stroke: 1px rgba(255, 255, 255, 0.2);
  font-family: var(--font-display);
  font-size: clamp(4rem, 12vw, 12rem);
  white-space: nowrap;
  pointer-events: none;
}

.marquee span {
  display: inline-block;
  min-width: 200%;
  animation: marquee 38s linear infinite;
}

.contact-inner {
  position: relative;
  z-index: 3;
}

.contact h2 {
  margin-bottom: 28px;
}

.socials {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
  margin-top: 34px;
  color: var(--muted);
  font-weight: 700;
}

.socials a:hover {
  color: var(--text);
}

.site-footer {
  width: min(1200px, calc(100% - 40px));
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 30px 0 42px;
  color: var(--muted);
  font-size: 0.9rem;
}

.reveal,
.name-reveal {
  opacity: 0;
  transform: translateY(26px);
  filter: blur(8px);
  animation: reveal 900ms cubic-bezier(0.25, 0.1, 0.25, 1) forwards;
}

.name-reveal {
  animation-delay: 120ms;
}

.reveal:nth-child(1) {
  animation-delay: 260ms;
}

.reveal:nth-child(3) {
  animation-delay: 360ms;
}

.reveal:nth-child(4) {
  animation-delay: 460ms;
}

.reveal:nth-child(5) {
  animation-delay: 560ms;
}

@keyframes reveal {
  to {
    opacity: 1;
    transform: translateY(0);
    filter: blur(0);
  }
}

@keyframes scroll-down {
  from {
    transform: translateY(-100%);
  }
  to {
    transform: translateY(220%);
  }
}

@keyframes marquee {
  to {
    transform: translateX(-50%);
  }
}

@media (max-width: 880px) {
  .nav-divider {
    display: none;
  }

  .section-head,
  .split {
    grid-template-columns: 1fr;
    display: grid;
    align-items: start;
  }

  .bento-grid {
    grid-template-columns: 1fr;
  }

  .project-card,
  .project-card.wide {
    grid-column: auto;
  }

  .capability-list article {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .stats {
    grid-template-columns: 1fr;
  }

  .stack-grid {
    grid-template-columns: 1fr;
  }

  .stack-group,
  .stack-group.tall {
    grid-column: auto;
  }
}

@media (max-width: 620px) {
  .site-header {
    padding-top: 10px;
  }

  .nav-pill {
    max-width: calc(100vw - 20px);
    overflow-x: auto;
  }

  .nav-pill > a:not(.brand-mark) {
    padding: 10px 11px;
    white-space: nowrap;
  }

  .hero {
    padding-inline: 14px;
  }

  .hero-actions,
  .button {
    width: 100%;
  }

  .section {
    width: min(100% - 24px, 1200px);
    padding: 64px 0;
  }

  .project-card {
    min-height: 360px;
    padding: 22px;
  }

  .platform-logo {
    right: 18px;
    top: 18px;
    width: 118px;
    height: 118px;
    border-radius: 24px;
  }

  .stack-group {
    padding: 18px;
  }

  .stack-cloud span {
    min-height: 44px;
    padding-right: 12px;
    font-size: 0.8rem;
  }

  .stack-cloud img,
  .stack-logo {
    width: 30px;
    height: 30px;
    padding: 6px;
  }

  .site-footer {
    width: min(100% - 24px, 1200px);
    gap: 18px;
    flex-wrap: wrap;
  }
}
