:root {
  --bg: #050b1b;
  --bg2: #081830;
  --card: rgba(8, 18, 38, 0.78);
  --line: rgba(66, 198, 255, 0.42);
  --text: #e9f8ff;
  --muted: #9bc9dc;
  --cyan: #2fe0ff;
  --cyan-2: #00b9ff;
  --green: #1ee69a;
  --red: #ff4f6a;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  min-height: 100%;
  font-family: "Exo 2", "Trebuchet MS", sans-serif;
  background: radial-gradient(circle at 10% 10%, #0a2d4f 0%, transparent 36%), radial-gradient(circle at 88% 16%, #073568 0%, transparent 34%), linear-gradient(135deg, var(--bg), var(--bg2));
  color: var(--text);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

.bg-glow {
  position: fixed;
  border-radius: 999px;
  filter: blur(90px);
  pointer-events: none;
  z-index: 0;
  opacity: 0.45;
}

.g1 {
  width: 280px;
  height: 280px;
  background: #23dcff;
  top: -100px;
  left: -80px;
}

.g2 {
  width: 340px;
  height: 340px;
  background: #0ea8ff;
  right: -120px;
  bottom: -120px;
}

.page {
  position: relative;
  z-index: 1;
  width: 100%;
  min-width: 0;
  max-width: 920px;
  margin: 26px auto;
  padding: 0 14px 24px;
  display: grid;
  gap: 14px;
}

.card {
  background: var(--card);
  border-radius: 18px;
  width: 100%;
  max-width: 100%;
  padding: 16px;
  backdrop-filter: blur(4px);
}

.neon-border {
  border: 1px solid var(--line);
  box-shadow: 0 0 0 1px rgba(0, 212, 255, 0.07) inset, 0 0 22px rgba(0, 184, 255, 0.2);
}

.brand { animation: rise .5s ease; }

.brand-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
}

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

.brand-left > div {
  min-width: 0;
}

.logo {
  width: 54px;
  height: 54px;
  object-fit: contain;
  border-radius: 14px;
  border: 1px solid rgba(98, 213, 255, 0.5);
  background: rgba(0, 18, 38, 0.9);
  padding: 6px;
}

h1 {
  margin: 0;
  font-size: 30px;
  letter-spacing: .4px;
  color: #dcf8ff;
  text-shadow: 0 0 16px rgba(36, 214, 255, 0.45);
  overflow-wrap: anywhere;
}

h2, h3, p { margin: 0; }

.muted {
  margin-top: 4px;
  color: var(--muted);
}

#invalidState {
  display: grid;
  gap: 12px;
  justify-items: start;
}

#loadingState {
  overflow: hidden;
}

.loading-mode #brandCard,
.loading-mode #footerCard,
.loading-mode #invalidState,
.loading-mode #validState {
  display: none !important;
}

.loading-mode #loadingState {
  display: grid !important;
  min-height: calc(100vh - 52px);
  place-items: center;
  padding: 0;
  border: none;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
}

.loading-mode .page {
  max-width: 100%;
  min-height: 100vh;
  margin: 0;
  padding: 0;
  display: grid;
  place-items: center;
}

.rocket-wrap {
  min-height: 420px;
  display: grid;
  place-items: center;
  width: min(100vw, 540px);
  background: radial-gradient(circle at 50% 70%, rgba(38, 214, 255, 0.16), transparent 34%);
}

.rocket-column {
  position: relative;
  height: 280px;
  width: 160px;
  display: grid;
  place-items: center;
}

.rocket-trail {
  position: absolute;
  bottom: 18px;
  width: 22px;
  height: 180px;
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0), rgba(47, 224, 255, 0.95), rgba(30, 230, 154, 0.35));
  filter: blur(2px);
  animation: rocketTrail 1.1s linear infinite;
}

.rocket-body {
  position: relative;
  z-index: 1;
  font-size: 112px;
  filter: drop-shadow(0 0 28px rgba(47, 224, 255, 0.5));
  animation: rocketFly 1.3s ease-in-out infinite;
}

#invalidState h2,
#invalidState p {
  width: 100%;
}

#invalidSupport {
  margin-top: 2px;
  white-space: normal;
  max-width: 100%;
}

.ping-box {
  border: 1px solid rgba(122, 214, 255, 0.42);
  border-radius: 999px;
  background: rgba(11, 44, 77, 0.62);
  color: #bceeff;
  padding: 8px 14px;
  font-size: 13px;
  white-space: nowrap;
}

.ping-box strong {
  color: #e8fdff;
  margin-left: 4px;
}

.stats-card {
  display: grid;
  gap: 10px;
  min-width: 0;
}

.stat-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 14px;
  color: var(--muted);
  min-width: 0;
}

.stat-row span,
.stat-row strong {
  min-width: 0;
  overflow-wrap: anywhere;
}

.stat-row strong {
  color: #f1fdff;
  font-size: 15px;
  white-space: normal;
}

.sub-test {
  color: #ffd34d !important;
}

.sub-active {
  color: #66f0ad !important;
}

.sub-expired {
  color: #ff6f81 !important;
}

.traffic-row { flex-wrap: wrap; }

.btn-mini {
  border: 1px solid rgba(92, 204, 255, 0.7);
  background: rgba(8, 47, 82, 0.64);
  color: #c8ecff;
  border-radius: 999px;
  padding: 3px 10px;
  font-size: 12px;
  cursor: pointer;
}

.tiny-line {
  font-size: 12px;
  color: #86b6ca;
  overflow-wrap: anywhere;
}

.warn { color: #ff9ab0; }

.admin-notice {
  background:
    radial-gradient(circle at 15% 18%, rgba(255, 92, 119, 0.18), transparent 34%),
    linear-gradient(135deg, rgba(61, 18, 38, 0.86), rgba(91, 23, 44, 0.82));
  border-color: rgba(255, 125, 145, 0.5);
  box-shadow: 0 0 0 1px rgba(255, 125, 145, 0.08) inset, 0 0 24px rgba(255, 90, 123, 0.18);
}

.admin-notice h3 {
  margin-bottom: 8px;
  font-size: 18px;
  font-weight: 800;
  color: #fff0f3;
}

.admin-notice p {
  margin: 0;
  white-space: pre-line;
  line-height: 1.6;
  font-weight: 700;
  color: #ffe3e9;
}

.step-card { overflow: hidden; }
.steps-shell {
  overflow: hidden;
  width: 100%;
  min-width: 0;
}

.steps-track {
  width: 100%;
  display: block;
  min-width: 0;
}

.steps-track.step-1,
.steps-track.step-2,
.steps-track.step-3 {
  transform: none;
}

.step {
  display: none;
  width: 100%;
  min-width: 0;
}

.step.is-active {
  display: block;
  animation: stepFadeIn .28s ease;
}

.accent {
  font-size: 24px;
  letter-spacing: 1px;
  color: #e6fcff;
  text-shadow: 0 0 18px rgba(47, 226, 255, 0.55);
  margin-bottom: 10px;
}

.box {
  border: 1px solid rgba(74, 202, 255, 0.4);
  border-radius: 16px;
  padding: 14px;
  background: rgba(7, 26, 52, 0.74);
  display: grid;
  gap: 12px;
}

.step-two-box {
  background: radial-gradient(circle at 20% 15%, rgba(31, 212, 255, 0.12), transparent 42%), rgba(7, 26, 52, 0.8);
}

.step-title {
  font-size: 18px;
  color: #dbf8ff;
}

.small-text {
  font-size: 13px;
}

.box-large { min-height: 360px; }

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

.btn {
  border: none;
  text-decoration: none;
  text-align: center;
  border-radius: 12px;
  padding: 10px 12px;
  font-weight: 700;
  letter-spacing: .2px;
  cursor: pointer;
  max-width: 100%;
  white-space: normal;
  overflow-wrap: anywhere;
}

.btn-primary {
  color: #07142a;
  background: linear-gradient(130deg, var(--cyan), var(--cyan-2));
  box-shadow: 0 0 18px rgba(42, 215, 255, 0.42);
}

.btn-green {
  color: #07142a;
  background: linear-gradient(130deg, #34f6b1, var(--green));
  box-shadow: 0 0 20px rgba(30, 230, 154, 0.4);
}

.btn-red {
  color: #fff;
  background: linear-gradient(130deg, #ff6f82, var(--red));
  box-shadow: 0 0 16px rgba(255, 79, 106, 0.36);
}

.btn-ghost {
  color: #c2ecff;
  background: rgba(9, 40, 73, 0.66);
  border: 1px solid rgba(74, 202, 255, 0.36);
}

.store-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  min-width: 0;
}

.store-btn span {
  flex: 1 1 auto;
  min-width: 0;
  overflow-wrap: anywhere;
}

.store-icon {
  width: 18px;
  display: inline-flex;
  justify-content: center;
  font-size: 15px;
}

.disabled {
  opacity: 0.5;
  pointer-events: none;
}

button:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.step-nav {
  margin-top: 10px;
  display: flex;
  justify-content: center;
  gap: 8px;
}

.btn-arrow {
  min-height: 34px;
  border-radius: 999px;
  border: 1px solid rgba(74, 202, 255, 0.45);
  background: rgba(8, 38, 70, 0.72);
  color: #bde8ff;
  cursor: pointer;
  padding: 6px 14px;
  font-size: 13px;
  max-width: 100%;
  white-space: normal;
}

.btn-arrow:disabled {
  opacity: 0.35;
  cursor: default;
}

.btn-prev-stage {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.video-toggle {
  border-top: 1px dashed rgba(75, 187, 232, 0.42);
  padding-top: 10px;
}

.video-toggle summary {
  cursor: pointer;
  color: #bfe8ff;
}

.gif {
  margin-top: 10px;
  width: 100%;
  max-height: 260px;
  object-fit: contain;
  border-radius: 10px;
  border: 1px solid rgba(74, 202, 255, 0.4);
  background: rgba(4, 21, 40, 0.9);
}

.footer-card {
  display: grid;
  gap: 10px;
}

.back-bot {
  width: 100%;
}

.row-links {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.copyright {
  margin: 0;
  color: #86b9cd;
  font-size: 13px;
}

.copyright a { color: #8fe7ff; }

ol {
  margin: 0;
  padding-left: 18px;
  color: #b9e8f8;
  display: grid;
  gap: 4px;
}

.faq-list {
  display: grid;
  gap: 10px;
}

.faq-item {
  border: 1px solid rgba(85, 201, 255, 0.34);
  border-radius: 12px;
  background: rgba(7, 31, 58, 0.64);
  padding: 10px 12px;
}

.faq-item summary {
  list-style: none;
  cursor: pointer;
  font-weight: 650;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-arrow {
  color: #9fe4ff;
  font-size: 12px;
  transition: transform .2s ease;
}

.faq-item[open] .faq-arrow {
  transform: rotate(180deg);
}

.faq-answer {
  margin-top: 10px;
  color: #c5ecff;
  line-height: 1.5;
}

.faq-pagination {
  margin-top: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
}

.faq-answer a {
  color: #90e8ff;
}

.hidden { display: none !important; }

.human-modal {
  position: fixed;
  inset: 0;
  z-index: 40;
  background: rgba(4, 10, 20, 0.76);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 14px;
}

.human-card {
  width: 100%;
  max-width: 460px;
  border-radius: 16px;
  background: rgba(6, 20, 41, 0.95);
  padding: 16px;
  display: grid;
  gap: 10px;
}

.human-prompt {
  font-size: 14px;
  color: #ccefff;
}

.human-image {
  width: 100%;
  max-height: 170px;
  object-fit: contain;
  border-radius: 10px;
  border: 1px solid rgba(80, 200, 255, 0.45);
  background: rgba(8, 26, 50, 0.92);
  user-select: none;
  -webkit-user-select: none;
}

.human-input {
  width: 100%;
  min-width: 0;
  font-size: 16px;
  border: 1px solid rgba(80, 198, 255, 0.45);
  border-radius: 10px;
  background: rgba(5, 22, 43, 0.9);
  color: #e7fbff;
  padding: 10px 12px;
  outline: none;
}

.human-error {
  min-height: 18px;
  font-size: 13px;
  color: #ff95ab;
}

@keyframes rise {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes rocketFly {
  0% { transform: translateY(14px); }
  50% { transform: translateY(-18px); }
  100% { transform: translateY(14px); }
}

@keyframes rocketTrail {
  0% { opacity: 0.25; transform: scaleY(0.7); }
  50% { opacity: 1; transform: scaleY(1); }
  100% { opacity: 0.25; transform: scaleY(0.72); }
}

@media (max-width: 980px) {
  .page { max-width: 760px; }
  h1 { font-size: 26px; }
  .box-large { min-height: 320px; }
}

@media (max-width: 680px) {
  .sub-page {
    width: 100%;
    max-width: 100%;
    margin: 0;
    overflow-x: visible;
  }

  .sub-page #appRoot {
    width: 100%;
    max-width: 100%;
    margin-left: 0;
    margin-right: 0;
    padding-left: 8px;
    padding-right: 8px;
  }

  .page {
    margin-top: 14px;
    padding-left: 10px;
    padding-right: 10px;
  }

  .sub-page .page {
    max-width: 100%;
    margin-left: 0;
    margin-right: 0;
    padding-left: 8px;
    padding-right: 8px;
  }

  .sub-page .card,
  .sub-page .box,
  .sub-page .steps-shell,
  .sub-page .steps-track,
  .sub-page .step,
  .sub-page .stats-card,
  .sub-page .stat-row {
    max-width: 100%;
    min-width: 0;
  }

  .sub-page .stats-card .stat-row {
    display: block;
    width: 100%;
  }

  .sub-page .stats-card .stat-row > span,
  .sub-page .stats-card .stat-row > strong {
    display: block;
    width: 100%;
  }

  .sub-page .stats-card .stat-row > strong {
    margin-top: 6px;
  }

  .sub-page .stats-card .traffic-row {
    display: block;
    width: 100%;
  }

  .sub-page .stats-card .traffic-row > span {
    display: block;
    width: 100%;
  }

  .sub-page .stats-card .traffic-row > strong {
    display: block;
    width: 100%;
    margin-top: 0;
  }

  .sub-page .stats-card .traffic-row > .btn-mini {
    display: inline-flex;
    margin-top: 8px;
    white-space: nowrap;
    max-width: 100%;
  }

  .card {
    padding: 14px;
  }

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

  .brand-left {
    align-items: flex-start;
    min-width: 0;
  }

  h1 {
    font-size: 22px;
    line-height: 1.25;
  }
  .accent { font-size: 18px; }
  .step { padding-right: 0; }
  .box { padding: 12px; }
  .box-large { min-height: 0; }

  .ping-box {
    justify-self: start;
    max-width: 100%;
    white-space: normal;
  }

  .stat-row {
    align-items: flex-start;
  }

  .traffic-row strong {
    overflow-wrap: anywhere;
  }

  .step-nav {
    width: 100%;
  }

  .btn-arrow {
    width: 100%;
    justify-content: center;
  }

  .faq-pagination {
    display: grid;
    grid-template-columns: 1fr;
    justify-items: stretch;
  }

  .btn {
    width: 100%;
  }

  .row-links {
    display: grid;
    grid-template-columns: 1fr;
  }

  #invalidSupport {
    width: 100%;
  }

  .rocket-wrap {
    min-height: 320px;
    width: min(100vw, 380px);
  }

  .rocket-column {
    width: 120px;
    height: 220px;
  }

  .rocket-trail {
    height: 140px;
    width: 18px;
  }

  .rocket-body {
    font-size: 84px;
  }
}

/* Runtime guard for iOS cases when scroll width still expands after dynamic content render */
.sub-page.mobile-tight .page {
  padding-left: 8px;
  padding-right: 8px;
}

.sub-page.mobile-tight .brand-grid {
  grid-template-columns: 1fr;
}

.sub-page.mobile-tight .stats-card .stat-row {
  display: block;
  width: 100%;
}

.sub-page.mobile-tight .stats-card .stat-row > span,
.sub-page.mobile-tight .stats-card .stat-row > strong {
  display: block;
  width: 100%;
}

.sub-page.mobile-tight .stats-card .traffic-row > .btn-mini {
  display: inline-flex;
  margin-top: 8px;
  max-width: 100%;
}

.sub-page.mobile-tight .download-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.sub-page.mobile-tight .store-btn {
  padding: 10px 8px;
}

.sub-page.mobile-tight .store-btn span {
  font-size: 15px;
}

@media (max-width: 390px) {
  .sub-page.mobile-tight .download-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .download-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .store-btn { padding: 10px 8px; }
  .store-btn span { font-size: 15px; }
}

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

  .logo {
    width: 46px;
    height: 46px;
  }
}

@keyframes stepFadeIn {
  from { opacity: 0; transform: translateX(12px); }
  to { opacity: 1; transform: translateX(0); }
}
