:root {
  color-scheme: dark;
  --bg: #05070f;
  --bg-surface: rgba(7, 12, 22, 0.96);
  --surface: #0d1324;
  --surface-strong: #121b34;
  --border: rgba(92, 255, 255, 0.12);
  --text: #e8f4ff;
  --muted: #8c9ebd;
  --accent: #5dfffb;
  --accent-2: #a35bff;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.35);
  --radius: 24px;
}

* {
  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;
  color: var(--text);
  background: radial-gradient(circle at top left, rgba(93, 255, 251, 0.12), transparent 25%),
    radial-gradient(circle at bottom right, rgba(163, 91, 255, 0.14), transparent 20%),
    var(--bg);
}

img,
svg {
  display: block;
  max-width: 100%;
}

button,
a {
  font: inherit;
}

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

.page-shell {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  padding: 24px;
  gap: 56px;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(16px);
  background: rgba(7, 11, 21, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 24px;
  padding: 18px 24px;
}

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

.brand-mark {
  display: inline-grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #05070f;
  font-weight: 800;
}

.brand-name {
  font-size: 0.95rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  background: rgba(12, 18, 34, 0.88);
  color: var(--text);
  cursor: pointer;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--text);
  border-radius: 999px;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.nav-toggle span:nth-child(2) {
  margin: 6px 0;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 28px;
  flex-wrap: wrap;
}

.nav-menu a {
  color: var(--muted);
  transition: color 0.2s ease;
}

.nav-menu a:hover,
.nav-menu a:focus-visible {
  color: var(--text);
}

.hero-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 24px;
  min-height: clamp(52vh, 60vh, 72vh);
  padding: 64px 0 40px;
  text-align: center;
}

.hero-copy {
  max-width: 700px;
}

.hero-section > .hero-copy > .eyebrow {
  margin-bottom: 18px;
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  letter-spacing: 0.24em;
}

.hero-copy h1 {
  margin: 0;
  font-size: clamp(2rem, 4vw, 2.8rem);
  line-height: 1.1;
}

.tech-carousel-simple {
  width: min(100%, 800px);
  margin-top: 50px;
}

.tech-list {
  display: flex;
  gap: 24px;
  overflow-x: auto;
  overflow-y: hidden;
  padding: 20px 0;
  scroll-behavior: auto;
  -webkit-overflow-scrolling: touch;
}

/* Hide scrollbar */
.tech-list::-webkit-scrollbar {
  display: none;
}
.tech-list {
  -ms-overflow-style: none;
  scrollbar-width: none;
}

.tech {
  flex: 0 0 auto;
  padding: 12px 22px;
  background: linear-gradient(135deg, rgba(93, 255, 251, 0.15), rgba(163, 91, 255, 0.1));
  border: 1.5px solid rgba(93, 255, 251, 0.4);
  border-radius: 999px;
  color: var(--accent);
  font-weight: 700;
  font-size: 0.85rem;
  white-space: nowrap;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  transition: all 0.3s cubic-bezier(0.2, 0.9, 0.2, 1);
  box-shadow: 0 0 16px rgba(93, 255, 251, 0);
}

.tech:hover {
  background: linear-gradient(135deg, rgba(93, 255, 251, 0.25), rgba(163, 91, 255, 0.2));
  border-color: rgba(93, 255, 251, 0.7);
  box-shadow: 0 0 20px rgba(93, 255, 251, 0.4), inset 0 0 16px rgba(93, 255, 251, 0.1);
  transform: translateY(-2px);
}

.eyebrow {
  margin: 0 0 16px;
  color: var(--accent);
  font-size: 0.9rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  margin-top: 32px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 24px;
  border-radius: 999px;
  border: 1px solid transparent;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.button:hover,
.button:focus-visible {
  transform: translateY(-2px);
}

.button-primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #05070f;
}

.button-secondary {
  border-color: rgba(93, 255, 251, 0.28);
  color: var(--text);
  background: rgba(255, 255, 255, 0.04);
}

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

.glow-card {
  position: relative;
  min-height: 170px;
  border-radius: 28px;
  padding: 28px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.01));
  border: 1px solid rgba(255, 255, 255, 0.07);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.glow-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at top left, rgba(93, 255, 251, 0.35), transparent 35%);
  opacity: 0.85;
  pointer-events: none;
}

.glow-card span {
  position: relative;
  color: var(--accent);
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  font-size: 0.9rem;
}

.glow-card p {
  position: relative;
  margin: 20px 0 0;
  max-width: 12rem;
  color: var(--text);
  font-size: 1.05rem;
  line-height: 1.6;
}

.card-2::before {
  background: radial-gradient(circle at top right, rgba(163, 91, 255, 0.24), transparent 40%);
}

.card-3::before {
  background: radial-gradient(circle at bottom left, rgba(93, 255, 251, 0.22), transparent 40%);
}

.section-block {
  padding: 48px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.section-header {
  display: grid;
  gap: 14px;
  margin-bottom: 32px;
}

.section-alt {
  background: rgba(7, 11, 21, 0.72);
  border-radius: 32px;
  padding: 32px 28px;
}

.section-header {
  display: grid;
  gap: 14px;
  margin-bottom: 24px;
}

.section-header h2 {
  margin: 0;
  font-size: clamp(2rem, 2.5vw, 3rem);
}

.cards-grid {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.project-card {
  padding: 28px;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.25);
  cursor: pointer;
  transition: border-color 0.45s cubic-bezier(.2,.9,.2,1), transform 0.45s cubic-bezier(.2,.9,.2,1), background 0.45s cubic-bezier(.2,.9,.2,1);
}

.project-card:hover {
  border-color: rgba(93, 255, 251, 0.6);
}

.project-card.active {
  background: rgba(93, 255, 251, 0.12);
  border-color: var(--accent);
  transform: translateY(-6px) scale(1.02);
  grid-column: span 2;
  z-index: 8;
}

.project-card.active .project-details {
  max-height: 420px;
  opacity: 1;
  margin-top: 22px;
}

.project-card.active .project-summary {
  color: var(--text);
}

.project-details {
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  transition: max-height 0.55s cubic-bezier(.2,.9,.2,1), opacity 0.4s ease 0.05s;
}

.project-details p {
  margin: 0;
  color: var(--text);
  line-height: 1.8;
}

.project-meta {
  margin-top: 18px;
  color: var(--muted);
  font-size: 0.95rem;
  letter-spacing: 0.01em;
}

.project-demo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 18px;
  padding: 0.9rem 1.3rem;
  border-radius: 999px;
  border: 1px solid rgba(93, 255, 251, 0.28);
  background: rgba(93, 255, 251, 0.12);
  color: var(--accent);
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease;
}

.project-demo:hover,
.project-demo:focus-visible {
  background: rgba(93, 255, 251, 0.2);
  transform: translateY(-1px);
}

.card-badge {
  display: inline-flex;
  padding: 10px 16px;
  border-radius: 999px;
  background: rgba(93, 255, 251, 0.12);
  color: var(--accent);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
}

.project-card h3 {
  margin: 20px 0 0;
  font-size: 1.35rem;
}

.project-card p {
  margin: 14px 0 0;
  color: var(--muted);
  line-height: 1.75;
}

.about-grid,
.contact-panel {
  display: grid;
  gap: 24px;
}

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

.support-list {
  display: grid;
  gap: 16px;
}

.support-item {
  padding: 20px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.contact-block {
  padding-bottom: 36px;
}

.contact-panel {
  padding: 28px;
  border-radius: 32px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.contact-links {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  margin-top: 20px;
}

.contact-links a {
  color: var(--accent);
  border-bottom: 1px solid transparent;
}

.contact-links a:hover,
.contact-links a:focus-visible {
  border-color: var(--accent);
}

.site-footer {
  text-align: center;
  padding: 24px 0 8px;
  color: var(--muted);
}

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

  .cards-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

@media (max-width: 720px) {
  .page-shell {
    padding: 18px;
    gap: 28px;
  }

  .site-header {
    flex-wrap: wrap;
    justify-content: space-between;
    padding: 18px;
  }

  .nav-toggle {
    display: inline-flex;
  }

  .nav-menu {
    width: 100%;
    display: none;
    flex-direction: column;
    gap: 16px;
    margin-top: 16px;
    padding: 18px;
    border-radius: 24px;
    background: rgba(7, 11, 21, 0.94);
    border: 1px solid rgba(255, 255, 255, 0.06);
  }

  .nav-menu.open {
    display: flex;
  }

  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

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

  .hero-visual {
    grid-template-columns: 1fr;
  }

  .project-card,
  .support-item,
  .contact-panel {
    padding: 22px;
  }

  .section-alt {
    padding: 24px;
  }
}
