:root {
  color-scheme: light;
  --navy-900: #0b132b;
  --navy-800: #101c38;
  --navy-700: #16254a;
  --navy-600: #25365a;
  --gray-900: #0c0f16;
  --gray-700: #3a465b;
  --gray-500: #5a6a84;
  --gray-300: #c8d0db;
  --gray-200: #e3e7ee;
  --gray-100: #f3f5f7;
  --white: #ffffff;
  --accent: #5e7aa5;
  --accent-soft: #a9b7d0;
  --radius-l: 24px;
  --radius-m: 16px;
  --shadow-soft: 0 18px 50px rgba(5, 10, 25, 0.25);
  --shadow-card: 0 20px 40px rgba(7, 14, 32, 0.22);
}

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

body {
  margin: 0;
  font-family: "Sora", "Space Grotesk", sans-serif;
  color: var(--gray-100);
  background: radial-gradient(circle at top, rgba(96, 120, 163, 0.25), transparent 55%),
    linear-gradient(150deg, var(--navy-900), #0a0f1f 55%, #111827 100%);
  min-height: 100vh;
  line-height: 1.6;
  position: relative;
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
  background-size: 120px 120px;
  opacity: 0.35;
  pointer-events: none;
  mix-blend-mode: screen;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  background: radial-gradient(circle at 20% 20%, rgba(12, 20, 40, 0.6), transparent 55%),
    radial-gradient(circle at 80% 30%, rgba(90, 115, 160, 0.25), transparent 50%);
  pointer-events: none;
}

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

.page {
  max-width: 1200px;
  margin: 0 auto;
  padding: 32px 24px 48px;
  position: relative;
  z-index: 1;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 12px 0 32px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.brand-mark {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  object-fit: cover;
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 10px 24px rgba(6, 12, 30, 0.35);
}

.brand-title {
  margin: 0;
  font-family: "Space Grotesk", "Sora", sans-serif;
  font-weight: 600;
  font-size: 20px;
}

.brand-subtitle {
  margin: 0;
  font-size: 12px;
  color: var(--gray-300);
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.site-nav {
  display: flex;
  gap: 18px;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--gray-300);
}

.site-nav a {
  position: relative;
  padding-bottom: 6px;
}

.site-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0;
  height: 2px;
  background: var(--accent-soft);
  transition: width 0.3s ease;
}

.site-nav a:hover::after {
  width: 100%;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 22px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.02em;
  border: 1px solid transparent;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.button-primary {
  background: var(--gray-100);
  color: var(--navy-900);
  box-shadow: var(--shadow-soft);
}

.button-primary:hover {
  transform: translateY(-2px);
}

.button-outline {
  border-color: rgba(255, 255, 255, 0.3);
  color: var(--gray-100);
}

.button-outline:hover {
  border-color: var(--gray-100);
}

.button-ghost {
  border-color: rgba(255, 255, 255, 0.2);
  color: var(--gray-200);
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr);
  gap: 40px;
  padding: 32px 0 64px;
  align-items: center;
}

.hero h1 {
  margin: 12px 0 20px;
  font-family: "Space Grotesk", sans-serif;
  font-size: clamp(32px, 4vw, 52px);
  line-height: 1.1;
}

.lead {
  font-size: 18px;
  color: var(--gray-200);
  max-width: 600px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin: 24px 0 32px;
}

.hero-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
}

.hero-card {
  background: rgba(15, 25, 48, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 18px;
  border-radius: var(--radius-m);
  box-shadow: var(--shadow-card);
}

.hero-card-title {
  margin: 0 0 8px;
  font-family: "Space Grotesk", sans-serif;
  font-weight: 600;
}

.hero-card-body {
  margin: 0;
  font-size: 14px;
  color: var(--gray-300);
}

.hero-slideshow {
  position: relative;
  min-height: 380px;
  border-radius: var(--radius-l);
  background: linear-gradient(155deg, rgba(18, 30, 56, 0.95), rgba(10, 15, 30, 0.95));
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  box-shadow: var(--shadow-card);
  overflow: hidden;
}

.slideshow-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.slideshow-controls {
  display: flex;
  gap: 8px;
}

.slide-button {
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: transparent;
  color: var(--gray-200);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  padding: 8px 12px;
  border-radius: 999px;
  cursor: pointer;
}

.slide-button:hover {
  border-color: rgba(255, 255, 255, 0.5);
}

.slides {
  position: relative;
  flex: 1;
  min-height: 240px;
}

.slide {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.slide.is-active {
  opacity: 1;
  transform: translateY(0);
  position: relative;
}

.slide h3 {
  margin: 0;
  font-family: "Space Grotesk", sans-serif;
  font-size: 28px;
}

.slide p {
  margin: 0;
  color: var(--gray-300);
}

.slide-tag {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--accent-soft);
}

.slide-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  font-size: 12px;
  color: var(--gray-300);
}

.slide-chip {
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 10px;
}

.slide-meta a {
  color: var(--gray-100);
}

.slide-dots {
  display: flex;
  gap: 8px;
  justify-content: center;
  align-items: center;
}

.slide-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  border: none;
  background: rgba(255, 255, 255, 0.25);
  cursor: pointer;
  transition: width 0.2s ease, background 0.2s ease;
}

.slide-dot.is-active {
  width: 26px;
  background: var(--gray-100);
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.2em;
  font-size: 12px;
  color: var(--accent-soft);
  margin: 0;
}

.section-head {
  max-width: 680px;
  margin-bottom: 32px;
}

.section-head h2 {
  font-family: "Space Grotesk", sans-serif;
  font-size: clamp(26px, 3vw, 36px);
  margin: 12px 0 12px;
}

.ecosystem {
  padding: 24px 0 64px;
}

.ecosystem-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 18px;
}

.ecosystem-panel {
  background: linear-gradient(160deg, rgba(243, 245, 247, 0.92), rgba(214, 220, 231, 0.92));
  border-radius: var(--radius-m);
  border: 1px solid rgba(255, 255, 255, 0.35);
  padding: 22px;
  box-shadow: var(--shadow-card);
  color: var(--navy-900);
}

.ecosystem-panel h3 {
  margin-top: 0;
  font-family: "Space Grotesk", sans-serif;
}

.ecosystem-panel ul {
  padding-left: 16px;
  margin-bottom: 0;
  color: var(--gray-700);
}

.projects {
  padding: 24px 0 80px;
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
}

.project-card {
  background: rgba(10, 18, 35, 0.8);
  border-radius: var(--radius-m);
  padding: 22px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 220px;
  box-shadow: var(--shadow-card);
  position: relative;
  --visual-stroke: rgba(219, 228, 244, 0.85);
  --visual-fill: rgba(110, 134, 185, 0.25);
  --visual-accent: rgba(168, 196, 230, 0.9);
}

.project-card.featured {
  grid-column: span 2;
  background: linear-gradient(145deg, rgba(28, 40, 74, 0.95), rgba(8, 14, 30, 0.95));
}

.project-example-trigger {
  position: absolute;
  top: 18px;
  right: 18px;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(12, 18, 34, 0.75);
  color: var(--gray-100);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.project-example-trigger svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.project-example-trigger:hover {
  transform: translateY(-1px);
  border-color: rgba(255, 255, 255, 0.3);
  box-shadow: 0 8px 18px rgba(6, 12, 30, 0.35);
}

.project-example-trigger:focus-visible {
  outline: 2px solid rgba(168, 196, 230, 0.6);
  outline-offset: 2px;
}

.project-card--div {
  --visual-accent: #b7c8ff;
  --visual-fill: rgba(102, 128, 200, 0.3);
}

.project-card--ways {
  --visual-accent: #b6d0f5;
  --visual-fill: rgba(94, 124, 180, 0.24);
}

.project-card--matrix {
  --visual-accent: #a9c2e8;
  --visual-fill: rgba(88, 112, 168, 0.24);
}

.project-card--pyvault {
  --visual-accent: #b7c9e8;
  --visual-fill: rgba(96, 122, 176, 0.26);
}

.project-card--laze {
  --visual-accent: #c2cbdc;
  --visual-fill: rgba(98, 110, 145, 0.24);
}

.project-card--enum {
  --visual-accent: #b7c0e2;
  --visual-fill: rgba(88, 108, 162, 0.24);
}

.project-card--ajaxmap {
  --visual-accent: #b0c6e8;
  --visual-fill: rgba(92, 118, 175, 0.24);
}

.project-card--nodes {
  --visual-accent: #a8bee0;
  --visual-fill: rgba(86, 112, 168, 0.24);
}

.project-card--orm {
  --visual-accent: #b5c7e2;
  --visual-fill: rgba(94, 118, 170, 0.24);
}

.project-visual {
  width: 100%;
  height: 70px;
  border-radius: 14px;
  background: linear-gradient(140deg, rgba(255, 255, 255, 0.06), rgba(8, 14, 30, 0.8));
  border: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px 12px;
  position: relative;
  overflow: hidden;
  color: var(--visual-stroke);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.project-card.featured .project-visual {
  height: 86px;
}

.project-visual::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 20% 20%, rgba(255, 255, 255, 0.12), transparent 50%);
  opacity: 0.6;
  pointer-events: none;
}

.project-visual svg {
  width: 100%;
  height: 100%;
}

.project-visual .stroke {
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.project-visual .fill {
  fill: var(--visual-fill);
}

.project-visual .accent {
  fill: none;
  stroke: var(--visual-accent);
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.project-visual .accent-fill {
  fill: var(--visual-accent);
}

.project-card:hover .project-visual {
  transform: translateY(-2px);
  box-shadow: 0 12px 24px rgba(5, 10, 25, 0.35);
}

.project-tag {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--accent-soft);
}

.project-card h3 {
  margin: 0;
  font-family: "Space Grotesk", sans-serif;
  font-size: 22px;
}

.project-card p {
  margin: 0;
  color: var(--gray-300);
  font-size: 14px;
}

.project-card a {
  margin-top: auto;
  font-weight: 500;
  color: var(--gray-100);
  display: inline-flex;
  gap: 8px;
  align-items: center;
}

.project-card a::after {
  content: "->";
  font-family: "Space Grotesk", sans-serif;
  transition: transform 0.2s ease;
}

.project-card a:hover::after {
  transform: translateX(4px);
}

.example-modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
  z-index: 40;
}

.example-modal.is-open {
  opacity: 1;
  pointer-events: auto;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(6, 10, 20, 0.75);
  backdrop-filter: blur(6px);
}

.modal-panel {
  position: relative;
  z-index: 1;
  width: min(760px, 92vw);
  max-height: 82vh;
  overflow: hidden;
  background: linear-gradient(160deg, rgba(20, 30, 58, 0.95), rgba(8, 12, 24, 0.98));
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 20px;
  box-shadow: 0 30px 60px rgba(4, 8, 18, 0.45);
  display: flex;
  flex-direction: column;
}

.modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 22px 24px 10px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.modal-header h3 {
  margin: 6px 0 0;
  font-size: 22px;
  font-family: "Space Grotesk", sans-serif;
}

.modal-close {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(12, 18, 34, 0.8);
  color: var(--gray-100);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.modal-close svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
}

.modal-close:hover {
  transform: translateY(-1px);
  border-color: rgba(255, 255, 255, 0.4);
}

.modal-body {
  padding: 18px 24px 28px;
  overflow-y: auto;
  display: grid;
  gap: 16px;
}

.example-lead {
  margin: 0;
  color: var(--gray-300);
  font-size: 14px;
}

.example-block {
  display: grid;
  gap: 16px;
}

.example-label {
  margin: 0 0 6px;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--accent-soft);
}

.example-code pre,
.example-result pre {
  margin: 0;
  padding: 16px;
  border-radius: 14px;
  background: rgba(7, 12, 24, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--gray-100);
  font-family: "JetBrains Mono", "Fira Code", "SFMono-Regular", monospace;
  font-size: 13px;
  line-height: 1.5;
  overflow-x: auto;
}

.example-code pre + pre {
  margin-top: 12px;
}

.example-code pre code,
.example-result pre code,
code.hljs {
  background: transparent;
  padding: 0;
  display: block;
}

.example-result {
  background: rgba(16, 24, 46, 0.7);
  border-radius: 14px;
  padding: 14px 16px;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.example-result h4 {
  margin: 0 0 8px;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent-soft);
}

.example-result p {
  margin: 0;
  color: var(--gray-200);
  font-size: 14px;
}

body.modal-open {
  overflow: hidden;
}

.studio {
  padding: 24px 0 80px;
}

.studio-inner {
  border-radius: var(--radius-l);
  background: linear-gradient(120deg, rgba(255, 255, 255, 0.08), rgba(10, 18, 35, 0.9));
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 36px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  box-shadow: var(--shadow-soft);
}

.mentor {
  padding: 12px 0 80px;
}

.mentor-card {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 28px;
  align-items: center;
  border-radius: var(--radius-l);
  background: rgba(12, 18, 34, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 32px;
  box-shadow: var(--shadow-card);
}

.mentor-media img {
  width: 160px;
  height: 160px;
  border-radius: 32px;
  object-fit: cover;
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 18px 40px rgba(4, 10, 25, 0.45);
}

.mentor-body h2 {
  margin: 12px 0 12px;
  font-family: "Space Grotesk", sans-serif;
  font-size: 30px;
}

.mentor-body p {
  margin: 0 0 18px;
  color: var(--gray-300);
}

.mentor-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.mentor-links {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 18px;
  margin-top: 20px;
}

.link-group {
  background: rgba(14, 21, 38, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 14px 16px;
}

.link-title {
  margin: 0 0 10px;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--accent-soft);
}

.link-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.link-list a {
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  font-size: 12px;
  color: var(--gray-200);
  transition: border-color 0.2s ease, color 0.2s ease;
}

.link-list a:hover {
  border-color: rgba(255, 255, 255, 0.5);
  color: var(--gray-100);
}

.studio-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.studio-note {
  margin-top: 16px;
  color: var(--gray-300);
}

.site-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 24px;
  color: var(--gray-300);
  font-size: 13px;
}

.footer-links {
  display: flex;
  gap: 16px;
}

[data-reveal] {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.6s ease, transform 0.6s ease;
  transition-delay: var(--delay, 0s);
}

[data-reveal].is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 980px) {
  .hero {
    grid-template-columns: 1fr;
  }

  .hero-slideshow {
    min-height: 260px;
    order: -1;
  }

  .project-card.featured {
    grid-column: span 1;
  }

  .studio-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .mentor-card {
    grid-template-columns: 1fr;
    text-align: left;
  }

  .mentor-media img {
    width: 140px;
    height: 140px;
  }
}

@media (max-width: 720px) {
  .site-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .site-nav {
    flex-wrap: wrap;
  }

  .site-footer {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;
    transition: none !important;
  }
}
