:root {
  --bg: #100b15;
  --bg-2: #15101b;
  --purple: #3C205B;
  --purple-2: #6f39a5;
  --accent: #8b47ff;
  --accent-soft: #b48aff;
  --text: #f7f3fb;
  --muted: #a99fb5;
  --muted-2: #746a80;
  --border: rgba(255,255,255,.085);
  --border-hi: rgba(180,138,255,.30);
  --panel: rgba(255,255,255,.025);
  --green: #72e6a8;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  color: var(--text);
  background:
    radial-gradient(circle at 82% 0%, rgba(60,32,91,.32), transparent 32rem),
    linear-gradient(180deg, var(--bg-2) 0%, var(--bg) 55%, #0c0910 100%);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

.noise {
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: .025;
  z-index: -1;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.7'/%3E%3C/svg%3E");
}

.glow {
  position: fixed;
  border-radius: 999px;
  filter: blur(110px);
  pointer-events: none;
  z-index: -2;
}

.glow-one {
  width: 28rem;
  height: 28rem;
  top: 18rem;
  right: -12rem;
  background: rgba(111,57,165,.16);
}

.glow-two {
  width: 22rem;
  height: 22rem;
  left: -11rem;
  top: 62rem;
  background: rgba(60,32,91,.18);
}

main, footer {
  width: min(1160px, calc(100% - 40px));
  margin-inline: auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  width: 100%;
  height: 78px;
  margin: 0;
  padding-inline: max(20px, calc((100vw - 1160px) / 2));
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(16,11,21,.84);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--border);
}

.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  font-size: .82rem;
  font-weight: 900;
  letter-spacing: .16em;
}

.brand img {
  width: 34px;
  height: 34px;
  border-radius: 9px;
}

nav {
  display: flex;
  gap: 28px;
}

nav a {
  color: var(--muted);
  font-size: .84rem;
  transition: color .15s ease;
}

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

.hero {
  min-height: 650px;
  display: grid;
  grid-template-columns: 1.08fr .92fr;
  align-items: center;
  gap: 70px;
  padding: 92px 0 76px;
  border-bottom: 1px solid var(--border);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: var(--muted);
  font-size: .69rem;
  font-weight: 800;
  letter-spacing: .17em;
}

.pulse {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 0 rgba(114,230,168,.45);
  animation: pulse 2.1s infinite;
}

@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(114,230,168,.38); }
  70% { box-shadow: 0 0 0 9px rgba(114,230,168,0); }
  100% { box-shadow: 0 0 0 0 rgba(114,230,168,0); }
}

.hero h1 {
  margin: 18px 0 0;
  font-size: clamp(5rem, 12vw, 9.6rem);
  line-height: .86;
  letter-spacing: -.078em;
  font-weight: 950;
}

.hero-copy {
  margin: 28px 0 0;
  max-width: 540px;
  color: var(--muted);
  font-size: clamp(1rem, 2vw, 1.2rem);
  line-height: 1.6;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 11px;
  margin-top: 36px;
}

.btn {
  min-height: 46px;
  padding: 0 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  font-size: .85rem;
  font-weight: 800;
  border: 1px solid var(--border);
  transition: transform .15s ease, background .15s ease, border-color .15s ease;
}

.btn:hover { transform: translateY(-1px); }
.btn.primary { background: var(--accent); border-color: transparent; }
.btn.secondary { background: rgba(255,255,255,.025); }

.hero-panel {
  border: 1px solid var(--border);
  background: linear-gradient(145deg, rgba(60,32,91,.22), rgba(255,255,255,.018));
  border-radius: 20px;
  padding: 18px;
  box-shadow: 0 28px 80px rgba(0,0,0,.22);
}

.panel-top {
  display: flex;
  justify-content: space-between;
  padding: 8px 8px 16px;
  color: var(--muted);
  font-size: .68rem;
  font-weight: 800;
  letter-spacing: .14em;
}

.panel-count { color: var(--muted-2); }

.system-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  min-height: 82px;
  padding: 0 14px;
  border-top: 1px solid var(--border);
}

.system-row div {
  display: grid;
  gap: 5px;
}

.system-row strong { font-size: .92rem; }
.system-row span:not(.status) { color: var(--muted); font-size: .75rem; }

.status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: .65rem;
  font-weight: 900;
  letter-spacing: .1em;
}

.status::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: currentColor;
}

.status.live { color: var(--green); }
.status.active { color: var(--accent-soft); }

.section {
  padding: 88px 0;
  border-bottom: 1px solid var(--border);
}

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

.kicker {
  margin: 0 0 8px;
  color: var(--accent-soft);
  font-size: .68rem;
  font-weight: 900;
  letter-spacing: .18em;
}

.section h2 {
  margin: 0;
  font-size: clamp(2.1rem, 4vw, 3.2rem);
  letter-spacing: -.045em;
}

.section-note {
  color: var(--muted);
  font-size: .8rem;
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 16px;
}

.project-card {
  min-height: 355px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: var(--panel);
  transition: transform .18s ease, border-color .18s ease, background .18s ease;
}

.project-card.featured {
  grid-column: span 2;
  min-height: 390px;
  background:
    radial-gradient(circle at 85% 10%, rgba(139,71,255,.16), transparent 18rem),
    linear-gradient(145deg, rgba(60,32,91,.38), rgba(255,255,255,.015));
}

.project-card:hover {
  transform: translateY(-3px);
  border-color: var(--border-hi);
  background-color: rgba(255,255,255,.04);
}

.project-meta, .project-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.project-meta > span:first-child {
  color: var(--muted-2);
  font-size: .72rem;
}

.project-main {
  max-width: 690px;
  margin: 54px 0 40px;
}

.project-main h3 {
  margin: 0 0 14px;
  font-size: clamp(1.5rem, 3vw, 2.2rem);
  letter-spacing: -.035em;
}

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

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.tags span {
  padding: 7px 9px;
  border: 1px solid var(--border);
  border-radius: 999px;
  color: #c6bccf;
  font-size: .67rem;
}

.open-arrow {
  color: var(--accent-soft);
  font-size: 1.05rem;
}

.stack-grid {
  display: grid;
  grid-template-columns: repeat(4,1fr);
  border-top: 1px solid var(--border);
  border-left: 1px solid var(--border);
}

.stack-item {
  min-height: 165px;
  padding: 18px;
  display: flex;
  flex-direction: column;
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.stack-item > span {
  color: var(--muted-2);
  font-size: .68rem;
}

.stack-item strong {
  margin-top: auto;
  font-size: 1rem;
}

.stack-item small {
  margin-top: 5px;
  color: var(--muted);
}

.links-section { border-bottom: 0; }
.link-list { border-top: 1px solid var(--border); }

.link-list a {
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border);
  color: var(--muted);
  transition: padding .15s ease, color .15s ease;
}

.link-list a:hover {
  padding-left: 6px;
  color: var(--text);
}

footer {
  min-height: 112px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: .73rem;
}

.reveal {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity .55s ease, transform .55s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

.preview-card {
  padding: 14px;
  border-radius: 18px;
  border: 1px solid var(--border);
  background: rgba(255,255,255,.02);
  box-shadow: 0 18px 48px rgba(0,0,0,.18);
}

.preview-card img {
  width: 100%;
  display: block;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.05);
}

.preview-card small {
  display: block;
  margin-top: 10px;
  color: var(--muted);
  font-size: .76rem;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    scroll-behavior: auto !important;
    animation: none !important;
    transition: none !important;
  }
  .reveal { opacity: 1; transform: none; }
}

@media (max-width: 820px) {
  .hero {
    grid-template-columns: 1fr;
    min-height: 0;
  }
  .hero-panel { max-width: 620px; }
  .project-card.featured { grid-column: span 1; }
  .projects-grid { grid-template-columns: 1fr; }
  .stack-grid { grid-template-columns: repeat(2,1fr); }
}

@media (max-width: 520px) {
  main, footer {
    width: min(100% - 26px, 1160px);
  }

  .site-header {
    padding-inline: 13px;
  }

  .brand span { display: none; }
  nav { gap: 15px; }
  nav a { font-size: .76rem; }

  .hero { padding: 72px 0 64px; gap: 48px; }
  .hero h1 { font-size: clamp(4rem, 22vw, 6.4rem); }

  .section { padding: 68px 0; }
  .section-note { display: none; }
  .project-card, .project-card.featured { min-height: 330px; }
  .stack-grid { grid-template-columns: 1fr; }

  footer {
    min-height: 0;
    padding: 30px 0;
    flex-wrap: wrap;
  }
}
