:root {
  color-scheme: dark;
  --bg: #050814;
  --panel: rgba(8, 13, 30, 0.82);
  --panel-strong: rgba(11, 18, 39, 0.96);
  --line: rgba(129, 231, 255, 0.18);
  --text: #f5fbff;
  --muted: #9ca9bd;
  --cyan: #15d5ee;
  --cyan-soft: rgba(21, 213, 238, 0.18);
  --violet: #a477ff;
  --orange: #ff9f43;
  --orange-soft: rgba(255, 159, 67, 0.18);
  --green: #56e39f;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.38);
}

* { box-sizing: border-box; }

html {
  min-height: 100%;
  background: var(--bg);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  letter-spacing: 0;
}

body {
  margin: 0;
  min-height: 100%;
  color: var(--text);
  background:
    radial-gradient(circle at 18% 8%, rgba(21, 213, 238, 0.16), transparent 26rem),
    radial-gradient(circle at 86% 22%, rgba(164, 119, 255, 0.14), transparent 27rem),
    linear-gradient(180deg, #070a18 0%, #040713 52%, #050814 100%);
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -1;
  content: "";
  opacity: 0.42;
  background-image:
    linear-gradient(rgba(255,255,255,0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.04) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: linear-gradient(to bottom, black, transparent 78%);
}

a { color: inherit; text-decoration: none; }
img, video { max-width: 100%; display: block; }

.site-header,
.site-footer,
.hero,
.page-hero,
.project-hero,
.section,
.details-band {
  width: min(1180px, calc(100% - 36px));
  margin-inline: auto;
}

.site-header {
  position: sticky;
  top: 12px;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-top: 12px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(5, 8, 20, 0.78);
  backdrop-filter: blur(18px);
  box-shadow: var(--shadow);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  font-weight: 800;
}

.brand img {
  width: 42px;
  height: 42px;
  border-radius: 8px;
}

.brand span {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  line-height: 1;
}

.brand strong { color: var(--cyan); }

nav {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.site-header nav a,
.site-footer nav a {
  border: 1px solid transparent;
  border-radius: 8px;
  padding: 10px 12px;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 700;
}

.site-header nav a:hover,
.site-header nav a.active,
.site-footer nav a:hover {
  border-color: rgba(21, 213, 238, 0.28);
  color: var(--text);
  background: rgba(21, 213, 238, 0.09);
}

.hero,
.project-hero,
.page-hero {
  position: relative;
  display: grid;
  gap: 36px;
  margin-top: 28px;
  padding: clamp(28px, 5vw, 58px);
  border: 1px solid var(--line);
  border-radius: 8px;
  background: linear-gradient(135deg, rgba(7, 12, 31, 0.94), rgba(6, 10, 23, 0.78));
  box-shadow: var(--shadow);
  overflow: hidden;
}

.hero { grid-template-columns: minmax(0, 1.12fr) minmax(280px, 0.88fr); align-items: center; }
.project-hero { grid-template-columns: minmax(320px, 0.9fr) minmax(0, 1.1fr); align-items: center; }
.page-hero { display: block; }
.page-hero.compact { max-width: 900px; text-align: center; }

.kicker {
  margin: 0 0 10px;
  color: var(--cyan);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

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

h1 {
  max-width: 880px;
  margin-bottom: 16px;
  font-size: clamp(2.7rem, 7vw, 6.2rem);
  line-height: 0.92;
}

.project-hero h1,
.page-hero h1 {
  font-size: clamp(2.3rem, 5vw, 4.6rem);
  line-height: 1;
}

.lead,
.page-hero p {
  max-width: 720px;
  color: #c8d5e8;
  font-size: clamp(1.05rem, 2vw, 1.35rem);
  line-height: 1.6;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 26px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  border: 1px solid rgba(255,255,255,0.14);
  border-radius: 8px;
  padding: 12px 18px;
  font-weight: 900;
  color: var(--text);
}

.button.primary {
  border-color: rgba(21, 213, 238, 0.42);
  background: linear-gradient(135deg, #17d3ec, #08b9cf);
  color: #03111a;
}

.button.secondary {
  background: rgba(255,255,255,0.06);
}

.button.muted {
  cursor: default;
  border-color: rgba(86, 227, 159, 0.28);
  background: rgba(86, 227, 159, 0.08);
  color: #b8f7d8;
}

.project-hero .button.muted {
  flex-basis: 100%;
  max-width: 340px;
}

.hero-art {
  display: grid;
  place-items: center;
  min-height: 350px;
}

.mascot {
  width: min(76%, 360px);
  filter: drop-shadow(0 28px 60px rgba(21, 213, 238, 0.2));
}

.mini-stack {
  display: flex;
  gap: 12px;
  margin-top: -34px;
}

.mini-stack img {
  width: 82px;
  height: 82px;
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 16px;
  box-shadow: var(--shadow);
}

.section {
  padding-block: 54px;
}

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

.section-heading h2 {
  max-width: 760px;
  margin: 0;
  font-size: clamp(1.75rem, 3vw, 2.8rem);
  line-height: 1.05;
}

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

.project-card,
.feature-grid article,
.details-band > div,
details {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: 0 14px 40px rgba(0,0,0,0.24);
}

.project-card {
  display: grid;
  gap: 12px;
  min-height: 330px;
  padding: 22px;
  overflow: hidden;
}

.project-card:hover { transform: translateY(-2px); border-color: rgba(21, 213, 238, 0.45); }
.project-card.orange:hover { border-color: rgba(255,159,67,0.55); }

.project-card-icon {
  width: 84px;
  height: 84px;
  border-radius: 18px;
  box-shadow: 0 14px 34px rgba(0,0,0,0.3);
}

.project-card span,
.project-card em,
.details-band span {
  color: var(--muted);
  font-size: 0.78rem;
  font-style: normal;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.project-card strong {
  font-size: clamp(1.6rem, 3vw, 2.4rem);
}

.project-card p {
  color: #c3d0e2;
  line-height: 1.58;
}

.project-card em {
  align-self: end;
  color: var(--cyan);
}
.project-card.orange em { color: var(--orange); }

.project-copy .app-icon {
  width: 94px;
  height: 94px;
  margin-bottom: 18px;
  border-radius: 22px;
  box-shadow: 0 18px 44px rgba(0,0,0,0.35);
}

.project-hero.orange .button.primary {
  border-color: rgba(255,159,67,0.45);
  background: linear-gradient(135deg, #ffb25f, #ff8d2a);
}

.media-strip {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(190px, 250px);
  gap: 16px;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scrollbar-color: rgba(21,213,238,0.7) transparent;
  padding: 4px 4px 18px;
}

.hero-media {
  grid-auto-columns: minmax(178px, 1fr);
  align-items: center;
}

.phone-frame {
  position: relative;
  aspect-ratio: 9 / 16;
  margin: 0;
  border: 1px solid rgba(129,231,255,0.26);
  border-radius: 24px;
  padding: 10px;
  background: linear-gradient(180deg, rgba(2,5,15,1), rgba(8,13,30,0.96));
  box-shadow: 0 22px 50px rgba(0,0,0,0.4), inset 0 0 0 1px rgba(255,255,255,0.04);
}

.phone-frame::before {
  position: absolute;
  top: 10px;
  left: 50%;
  width: 34%;
  height: 14px;
  transform: translateX(-50%);
  border-radius: 0 0 12px 12px;
  content: "";
  background: #020611;
  z-index: 2;
}

.phone-frame img,
.phone-frame video {
  width: 100%;
  height: 100%;
  border-radius: 16px;
  object-fit: contain;
  background: #020611;
}

.phone-frame figcaption {
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 14px;
  border-radius: 8px;
  padding: 7px 8px;
  color: #dbeaff;
  background: rgba(2, 5, 15, 0.68);
  font-size: 0.72rem;
  font-weight: 800;
}

.details-band {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 18px;
}

.details-band > div {
  padding: 16px;
}

.details-band strong {
  display: block;
  margin-top: 6px;
  line-height: 1.4;
}

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

.feature-grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.narrow { max-width: 980px; }

.feature-grid article {
  padding: 20px;
}

.feature-grid h3 {
  margin-bottom: 8px;
  color: #f8fbff;
}

.feature-grid p,
details p {
  color: #bdc9db;
  line-height: 1.62;
}

.gallery {
  grid-auto-columns: minmax(220px, 280px);
}

.faq {
  max-width: 900px;
}

details {
  margin-bottom: 10px;
  padding: 18px 20px;
}

summary {
  cursor: pointer;
  color: var(--text);
  font-weight: 900;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  margin-top: 30px;
  padding: 28px 0 40px;
  color: var(--muted);
}

.site-footer img {
  width: 46px;
  height: 46px;
  border-radius: 8px;
  margin-bottom: 10px;
}

.site-footer p { max-width: 360px; line-height: 1.55; }

@media (max-width: 880px) {
  .site-header {
    position: static;
    align-items: stretch;
    flex-direction: column;
    gap: 8px;
    padding: 9px;
  }

  .site-header nav {
    flex-wrap: nowrap;
    gap: 6px;
    overflow-x: auto;
    padding-bottom: 2px;
    scrollbar-width: none;
  }

  .site-header nav::-webkit-scrollbar { display: none; }

  .site-header nav a {
    flex: 0 0 auto;
    padding: 8px 10px;
    font-size: 0.88rem;
  }

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

  .hero-art { min-height: 220px; }

  h1 { font-size: clamp(2.45rem, 14vw, 4.4rem); }

  .project-grid,
  .details-band,
  .feature-grid,
  .feature-grid.two {
    grid-template-columns: 1fr;
  }

  .section-heading {
    align-items: start;
    flex-direction: column;
  }

  .media-strip {
    grid-auto-columns: minmax(210px, 78vw);
  }

  .site-footer {
    flex-direction: column;
  }
}

@media (max-width: 520px) {
  .site-header,
  .site-footer,
  .hero,
  .page-hero,
  .project-hero,
  .section,
  .details-band {
    width: min(100% - 22px, 1180px);
  }

  .hero,
  .project-hero,
  .page-hero {
    padding: 22px;
  }

  .button {
    width: 100%;
  }
}
