:root {
  --bg: #000000;
  --ink: #f5f5f7;
  --mute: #a1a1a6;
  --faint: #6e6e73;
  --glass-bg: rgba(255, 255, 255, 0.08);
  --glass-bg-strong: rgba(255, 255, 255, 0.14);
  --glass-border: rgba(255, 255, 255, 0.15);
  --glass-specular: rgba(255, 255, 255, 0.34);
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  color-scheme: dark;
}

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

html {
  background: var(--bg);
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  scrollbar-width: none;
}

html::-webkit-scrollbar {
  display: none;
}

body {
  background: var(--bg);
  color: var(--ink);
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}

h1,
h2,
h3 {
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1.06;
  text-wrap: balance;
}

a {
  color: inherit;
}

button {
  font: inherit;
  color: inherit;
}

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

:focus-visible {
  outline: 2px solid #9dc2ff;
  outline-offset: 3px;
}

.skip-link {
  position: fixed;
  left: 16px;
  top: -80px;
  z-index: 250;
  padding: 10px 18px;
  border-radius: 999px;
  background: #fff;
  color: #000;
  font-weight: 600;
  text-decoration: none;
}

.skip-link:focus {
  top: 16px;
}

/* Water-Fill Logo Launch Intro */
.splash {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: #000000;
  display: grid;
  place-items: center;
  opacity: 1;
  transition: opacity 0.28s var(--ease);
  will-change: opacity;
}

.splash.done {
  opacity: 0;
  pointer-events: none;
}

.splash[hidden] {
  display: none;
}

.splash-logo-wrap {
  width: 112px;
  height: 112px;
  transform: translate3d(0, 0, 0) scale(1);
  transition: transform 0.2s cubic-bezier(0.3, 1.35, 0.4, 1);
  will-change: transform;
}

.splash-logo-wrap.pop {
  transform: translate3d(0, 0, 0) scale(1.08);
}

.splash-canvas {
  width: 112px;
  height: 112px;
  display: block;
}

.wrap {
  width: min(1120px, calc(100% - 32px));
  margin-inline: auto;
}

main,
footer {
  position: relative;
  z-index: 1;
}

/* Liquid Glass Primitives */
.glass-pill {
  background: var(--glass-bg-strong);
  -webkit-backdrop-filter: blur(22px) saturate(165%);
  backdrop-filter: blur(22px) saturate(165%);
  border: 1px solid var(--glass-border);
  box-shadow:
    inset 0 1px 0 var(--glass-specular),
    0 10px 30px rgba(0, 0, 0, 0.35);
}

.glass-card {
  background: linear-gradient(155deg, rgba(255, 255, 255, 0.085), rgba(255, 255, 255, 0.03));
  -webkit-backdrop-filter: blur(22px) saturate(150%);
  backdrop-filter: blur(22px) saturate(150%);
  border: 1px solid rgba(255, 255, 255, 0.13);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.22),
    0 24px 64px rgba(0, 0, 0, 0.52);
  border-radius: 26px;
}

/* Hero */
.hero {
  position: relative;
  min-height: min(92svh, 820px);
  display: flex;
  align-items: center;
  padding: clamp(40px, 6vh, 64px) 0;
  overflow: clip;
}

.hero-backdrop {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 28%;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.bg-layer {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 22%;
  opacity: 0;
  transform: translate3d(0, 0, 0) scale(1);
  animation: heroDrift 24s ease-in-out infinite alternate;
  transition: opacity 1.1s var(--ease);
  will-change: opacity, transform;
}

.bg-layer.active {
  opacity: 0.92;
}

.hero-backdrop.paused .bg-layer {
  animation-play-state: paused;
}

@keyframes heroDrift {
  from {
    transform: translate3d(0, 0, 0) scale(1);
  }

  to {
    transform: translate3d(0, 0, 0) scale(1.07);
  }
}

.hero-backdrop::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  background:
    linear-gradient(90deg, #000 0%, rgba(0, 0, 0, 0.72) 18%, rgba(0, 0, 0, 0.14) 44%, transparent 68%),
    linear-gradient(180deg, rgba(0, 0, 0, 0.28) 0%, transparent 22%, transparent 66%, #000 100%);
}

.hero-inner {
  position: relative;
  z-index: 2;
}

.hero-brand {
  display: inline-flex;
  align-items: center;
  gap: 16px;
  margin-bottom: clamp(28px, 4.2vw, 44px);
}

.hero-logo-box {
  width: clamp(64px, 8vw, 84px);
  height: clamp(64px, 8vw, 84px);
  padding: clamp(13px, 1.7vw, 17px);
  border-radius: 22px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.hero-mark {
  width: 100%;
  height: 100%;
  background: #ffffff;
  -webkit-mask: url("assets/ak-mask.png") center / contain no-repeat;
  mask: url("assets/ak-mask.png") center / contain no-repeat;
}

.hero-brand-name {
  font-size: clamp(28px, 4.2vw, 44px);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1;
  color: #ffffff;
}

.hero-title {
  font-size: clamp(2.65rem, 6.8vw, 5.25rem);
  max-width: 11ch;
  margin-bottom: 18px;
}

.hero-sub {
  max-width: 48ch;
  font-size: clamp(16px, 2vw, 19px);
  color: rgba(245, 245, 247, 0.78);
  margin-bottom: 28px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

/* Buttons */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 54px;
  padding: 0 30px;
  border-radius: 999px;
  background: #fff;
  color: #000;
  font-size: 15.5px;
  font-weight: 700;
  text-decoration: none;
  box-shadow: 0 12px 32px rgba(255, 255, 255, 0.16);
  transition: transform 0.28s var(--ease);
}

.btn-primary svg,
.btn-glass svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
  flex-shrink: 0;
}

.btn-primary:hover {
  transform: translate3d(0, -1px, 0) scale(1.025);
}

.btn-primary:active {
  transform: scale(0.97);
}

.btn-glass {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 54px;
  padding: 0 24px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.11);
  -webkit-backdrop-filter: blur(18px) saturate(150%);
  backdrop-filter: blur(18px) saturate(150%);
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25);
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
  transition: transform 0.28s var(--ease), background 0.2s;
}

.btn-glass:hover {
  background: rgba(255, 255, 255, 0.18);
  transform: translate3d(0, -1px, 0);
}

/* Hero Quick Strip */
.quick-strip {
  margin-top: 28px;
  max-width: 740px;
  padding: 16px 20px;
  border-radius: 22px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  align-items: center;
}

.quick-item {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

.quick-label {
  font-size: 11.5px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--mute);
}

.quick-item strong {
  font-size: 14.5px;
  font-weight: 600;
  color: #fff;
}

.apk-size {
  color: var(--mute);
  font-weight: 500;
  font-size: 13px;
}

.code-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  text-align: left;
}

.code-chip strong {
  font-variant-numeric: tabular-nums;
  font-size: 15px;
  letter-spacing: 0.03em;
}

.code-chip span {
  font-size: 11px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #fff;
}

/* Sections */
.section {
  padding: clamp(56px, 8vw, 96px) 0;
}

.section-head {
  max-width: 620px;
  margin-bottom: 30px;
}

.eyebrow {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(245, 245, 247, 0.56);
  margin-bottom: 8px;
}

.section-head h2 {
  font-size: clamp(1.9rem, 4.2vw, 3.1rem);
}

/* Screenshots Grid / Mobile Carousel (static on hover — no scale or lift) */
.shots-track {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.shot-card {
  padding: 12px;
  border-radius: 22px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  cursor: pointer;
  border: 1px solid rgba(255, 255, 255, 0.13);
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.025));
  transition: border-color 0.2s var(--ease);
  text-align: left;
}

.shot-card:hover {
  border-color: rgba(255, 255, 255, 0.28);
}

.shot-media {
  position: relative;
  border-radius: 14px;
  overflow: hidden;
  background: #0a0a0d;
  aspect-ratio: 16 / 9;
}

.shot-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.shot-caption {
  padding: 2px 4px 4px;
}

.shot-caption strong {
  display: block;
  font-size: 14.5px;
  font-weight: 600;
}

.shot-caption span {
  display: block;
  font-size: 12.5px;
  color: var(--mute);
  margin-top: 2px;
}

/* Centered Download Box + Optional Right-Space Character (only when space exists) */
.download-stage {
  position: relative;
  width: min(1320px, calc(100% - 32px));
  margin-inline: auto;
}

.download-shell {
  padding: clamp(24px, 4.5vw, 44px);
  max-width: 760px;
  width: 100%;
  margin-inline: auto;
}

.dl-header {
  text-align: center;
  margin-bottom: 26px;
}

.dl-mark {
  margin: 0 auto 14px;
  border-radius: 16px;
  box-shadow: 0 12px 32px rgba(255, 255, 255, 0.12);
}

.dl-header h2 {
  font-size: clamp(1.9rem, 4.2vw, 2.8rem);
}

.dl-ver {
  margin-top: 8px;
  font-size: 14px;
  color: var(--mute);
  font-weight: 500;
}

.dl-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 22px;
  border-radius: 20px;
  text-decoration: none;
  background: linear-gradient(125deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.06));
  border: 1px solid rgba(255, 255, 255, 0.34);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.3);
  transition: transform 0.25s var(--ease), background 0.2s;
}

.dl-card:hover {
  transform: translate3d(0, -2px, 0);
  background: linear-gradient(125deg, rgba(255, 255, 255, 0.22), rgba(255, 255, 255, 0.08));
}

.dl-card-title {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.apk-name {
  font-size: 15.5px;
  font-weight: 700;
  color: #fff;
}

.tag {
  padding: 2px 8px;
  border-radius: 999px;
  background: #fff;
  color: #000;
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.dl-card-main p {
  font-size: 13px;
  color: var(--mute);
  margin-top: 4px;
}

.dl-card-side {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.dl-size {
  font-variant-numeric: tabular-nums;
  font-size: 13px;
  font-weight: 500;
  color: rgba(245, 245, 247, 0.8);
}

.dl-arrow {
  font-size: 18px;
  font-weight: 700;
}

.dl-links-row {
  margin-top: 14px;
  text-align: center;
}

.text-link {
  font-size: 13px;
  color: var(--mute);
  text-decoration: none;
  border-bottom: 1px solid rgba(255, 255, 255, 0.24);
}

.text-link:hover {
  color: #fff;
  border-bottom-color: #fff;
}

/* Install Box */
.install-box {
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.install-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
}

.install-head h3 {
  font-size: 18px;
}

.downloader-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 12px 7px 14px;
  border-radius: 999px;
  font-size: 13px;
  cursor: pointer;
}

.downloader-pill strong {
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.03em;
}

.copy-tag {
  padding: 2px 8px;
  border-radius: 999px;
  background: #fff;
  color: #000;
  font-size: 11px;
  font-weight: 700;
}

.steps-list {
  list-style: none;
  padding: 0;
  counter-reset: step;
  display: grid;
  gap: 12px;
}

.steps-list li {
  counter-increment: step;
  display: flex;
  align-items: flex-start;
  gap: 13px;
  font-size: 14.5px;
  color: rgba(245, 245, 247, 0.88);
}

.steps-list li::before {
  content: counter(step);
  flex-shrink: 0;
  width: 25px;
  height: 25px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.22);
  font-size: 12px;
  font-weight: 700;
}

.character-stage {
  display: none;
  pointer-events: none;
  user-select: none;
}

.char-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 28px 50px rgba(0, 0, 0, 0.65));
}

@media (min-width: 1140px) {
  .character-stage {
    display: block;
    position: absolute;
    left: calc(50% + 394px);
    right: 0;
    top: 24%;
    height: clamp(400px, 38vw, 540px);
    transform: translate3d(0, -50%, 0);
  }
}

/* Footer */
.footer {
  padding: 20px 0 52px;
  text-align: center;
  color: var(--faint);
  font-size: 13px;
}

.footer-links {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
  margin-bottom: 14px;
}

.footer-icon-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--mute);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s;
}

.footer-icon-link svg {
  width: 17px;
  height: 17px;
  fill: currentColor;
}

.footer-icon-link:hover {
  color: #fff;
}

.footer-note {
  max-width: 620px;
  margin: 0 auto;
}

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgba(0, 0, 0, 0.88);
  -webkit-backdrop-filter: blur(20px);
  backdrop-filter: blur(20px);
  display: grid;
  place-items: center;
  padding: 24px;
  opacity: 0;
  transition: opacity 0.24s var(--ease);
}

.lightbox.open {
  opacity: 1;
}

.lightbox[hidden] {
  display: none;
}

.lb-frame {
  max-width: min(92vw, 960px);
  max-height: 86svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.lb-frame img {
  max-height: 76svh;
  width: auto;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.7);
}

.lb-frame figcaption {
  color: var(--mute);
  font-size: 14px;
  text-align: center;
}

.lb-close,
.lb-nav {
  position: fixed;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  cursor: pointer;
  font-size: 20px;
}

.lb-close {
  top: 20px;
  right: 20px;
  font-size: 16px;
}

.lb-prev {
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
}

.lb-next {
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
}

/* 60fps Scroll Reveal (transform + opacity only) */
.reveal {
  opacity: 0;
  transform: translate3d(0, 20px, 0);
  transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
}

.reveal.in {
  opacity: 1;
  transform: translate3d(0, 0, 0);
}

/* Responsive */
@media (max-width: 920px) {
  .shots-track {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

@media (max-width: 680px) {
  .hero {
    padding-top: 40px;
    padding-bottom: 34px;
  }

  .hero-backdrop {
    left: 0;
    height: 52svh;
    bottom: auto;
  }

  .hero-backdrop::after {
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.25) 0%, rgba(0, 0, 0, 0.08) 40%, #000 96%);
  }

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

  .shots-track {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    gap: 14px;
    padding-bottom: 6px;
    scrollbar-width: none;
  }

  .shots-track::-webkit-scrollbar {
    display: none;
  }

  .shot-card {
    flex: 0 0 86%;
    scroll-snap-align: center;
  }

  .dl-card {
    flex-direction: column;
    align-items: flex-start;
  }

  .dl-card-side {
    width: 100%;
    justify-content: space-between;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .bg-layer {
    animation: none;
  }

  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }

  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
  }
}