:root {
  color-scheme: dark;
  --text: #f7f8fb;
  --muted: #a9b0ba;
  --line: rgba(255, 255, 255, 0.16);
  --glass: rgba(255, 255, 255, 0.08);
  --glass-strong: rgba(255, 255, 255, 0.14);
}

* {
  box-sizing: border-box;
}

body {
  min-height: 100vh;
  margin: 0;
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at 50% 0%, rgba(100, 159, 255, 0.14), transparent 36rem),
    #05070a;
  display: grid;
  place-items: center;
}

.launch-gate {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: grid;
  place-items: center;
  padding: 1rem;
  background:
    linear-gradient(180deg, rgba(5, 7, 10, 0.72), rgba(5, 7, 10, 0.96)),
    url("./assets/background.png") center / cover,
    #05070a;
}

.launch-gate.hidden {
  display: none;
}

.gate-card {
  width: min(100%, 22rem);
  padding: 1.2rem;
  border: 1px solid var(--line);
  border-radius: 1.4rem;
  background: rgba(8, 11, 15, 0.74);
  box-shadow: 0 2rem 5rem rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(24px);
}

.gate-card h1 {
  font-size: 2.3rem;
}

.gate-card p:not(.eyebrow) {
  color: var(--muted);
  line-height: 1.45;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

.shell {
  width: min(100%, 28rem);
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: max(1rem, env(safe-area-inset-top)) 1rem max(1rem, env(safe-area-inset-bottom));
}

.phone-frame {
  width: min(100%, 24.5rem);
  min-height: min(50rem, calc(100vh - 2rem));
  padding: 0.8rem;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 2.2rem;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.025));
  box-shadow: 0 2rem 6rem rgba(0, 0, 0, 0.5);
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: 1rem;
}

.status-bar {
  display: flex;
  justify-content: space-between;
  padding: 0.25rem 0.75rem 0;
  font-size: 0.84rem;
  font-weight: 700;
}

.status-icons {
  letter-spacing: 0;
}

.card {
  position: relative;
  min-height: 36rem;
  border-radius: 1.7rem;
  transform-style: preserve-3d;
  transition: transform 520ms cubic-bezier(0.2, 0.8, 0.2, 1);
}

.card.is-private {
  transform: rotateY(180deg);
}

.card-face {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border-radius: inherit;
  padding: 1.35rem;
  backface-visibility: hidden;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.08), rgba(0, 0, 0, 0.62)),
    url("./assets/background.png") center / cover,
    #090b0d;
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.15),
    inset 0 0 3.5rem rgba(255, 255, 255, 0.08),
    0 1.2rem 3rem rgba(0, 0, 0, 0.34);
}

.card-face::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(115deg, transparent 12%, rgba(255, 255, 255, 0.18) 28%, transparent 42%),
    linear-gradient(20deg, transparent, rgba(75, 148, 255, 0.1), transparent);
  mix-blend-mode: screen;
  opacity: 0.58;
}

.back {
  transform: rotateY(180deg);
}

.shine {
  position: absolute;
  inset: 0;
  z-index: 5;
  pointer-events: none;
  border-radius: 1.7rem;
  background: radial-gradient(circle at var(--x, 55%) var(--y, 20%), rgba(255, 255, 255, 0.22), transparent 12rem);
  opacity: 0.8;
  transform: translateZ(1px);
}

.card-top,
.front-footer,
.number-list,
.locked-panel,
.private-panel {
  position: relative;
  z-index: 2;
}

.card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.eyebrow {
  margin: 0 0 0.35rem;
  color: #c7ced8;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h1,
h2,
h3 {
  margin: 0;
  letter-spacing: 0;
}

h1 {
  font-size: clamp(2rem, 12vw, 3.15rem);
  line-height: 0.95;
}

h2 {
  font-size: 2.35rem;
}

.icon-button {
  width: 2.6rem;
  height: 2.6rem;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--text);
  background: var(--glass);
  backdrop-filter: blur(18px);
  font-size: 1.25rem;
}

.number-list {
  display: grid;
  gap: 0.75rem;
  margin-top: 4.5rem;
}

.number-row {
  min-height: 4.6rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem 0.95rem;
  color: inherit;
  text-decoration: none;
  border: 1px solid var(--line);
  border-radius: 1rem;
  background: rgba(11, 14, 18, 0.58);
  backdrop-filter: blur(22px) saturate(1.2);
}

.number-row strong,
.number-row small {
  display: block;
}

.number-row strong {
  font-size: 0.98rem;
}

.number-row small {
  margin-top: 0.24rem;
  color: var(--muted);
  font-size: 0.9rem;
}

.number-actions {
  display: flex;
  align-items: center;
  flex: 0 0 auto;
  gap: 0.45rem;
}

.call-link,
.qr-mini {
  flex: 0 0 auto;
  min-width: 3rem;
  padding: 0.48rem 0.68rem;
  border: 0;
  border-radius: 999px;
  color: #fff;
  background: #0a84ff;
  font-size: 0.78rem;
  font-weight: 800;
  text-align: center;
  text-decoration: none;
}

.qr-mini {
  color: #0a84ff;
  background: rgba(10, 132, 255, 0.14);
  border: 1px solid rgba(10, 132, 255, 0.4);
}

.front-footer {
  display: flex;
  gap: 0.7rem;
  margin-top: 1rem;
}

.pill-button,
.unlock-button,
.setup-button,
.dock button {
  min-height: 2.85rem;
  border: 0;
  border-radius: 999px;
  color: #071019;
  background: #f7f8fb;
  font-weight: 800;
}

.pill-button {
  flex: 1;
}

.ghost,
.setup-button {
  color: var(--text);
  background: var(--glass-strong);
  border: 1px solid var(--line);
}

.locked-panel,
.private-panel {
  margin-top: 5rem;
  padding: 1.2rem;
  border: 1px solid var(--line);
  border-radius: 1.2rem;
  background: rgba(7, 10, 14, 0.68);
  backdrop-filter: blur(24px);
}

.lock-mark {
  width: 3rem;
  height: 3rem;
  display: grid;
  place-items: center;
  margin-bottom: 1rem;
  border: 1px solid var(--line);
  border-radius: 50%;
  font-size: 1.65rem;
}

.locked-panel p {
  color: var(--muted);
  line-height: 1.45;
}

.unlock-button,
.setup-button {
  width: 100%;
  margin-top: 0.75rem;
}

.fine-print {
  margin-bottom: 0;
  font-size: 0.78rem;
}

.private-panel {
  display: grid;
  gap: 0.85rem;
}

.private-panel.hidden,
.locked-panel.hidden {
  display: none;
}

.private-row {
  padding: 0.95rem;
  border: 1px solid var(--line);
  border-radius: 0.9rem;
  background: rgba(255, 255, 255, 0.07);
}

.private-row span,
.private-row strong,
.private-row a {
  display: block;
}

.private-row span {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 700;
  text-transform: uppercase;
}

.private-row strong,
.private-row a {
  margin-top: 0.3rem;
  color: var(--text);
  overflow-wrap: anywhere;
  font-size: 1.08rem;
  text-decoration: none;
}

.private-row.muted strong {
  color: #cfd5dd;
  font-size: 0.95rem;
}

.dock {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.55rem;
}

.dock button {
  min-height: 2.5rem;
  color: var(--text);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.08);
  font-size: 0.82rem;
}

dialog {
  width: min(22rem, calc(100vw - 2rem));
  border: 1px solid var(--line);
  border-radius: 1.4rem;
  color: var(--text);
  background: rgba(11, 14, 18, 0.94);
  box-shadow: 0 2rem 5rem rgba(0, 0, 0, 0.55);
}

dialog::backdrop {
  background: rgba(0, 0, 0, 0.62);
  backdrop-filter: blur(10px);
}

.qr-sheet {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 1rem;
  padding: 1rem 0.4rem 0.4rem;
  text-align: center;
}

.qr-sheet p {
  margin: 0;
  color: var(--muted);
}

.close-button {
  position: absolute;
  top: -0.4rem;
  right: -0.2rem;
  width: 2.3rem;
  height: 2.3rem;
  border: 0;
  border-radius: 50%;
  color: var(--text);
  background: rgba(255, 255, 255, 0.12);
  font-size: 1.5rem;
}

#qrCanvas {
  width: 15rem;
  height: 15rem;
  padding: 0.75rem;
  border-radius: 1rem;
  background: #fff;
}

@media (max-width: 390px) {
  .shell {
    padding-inline: 0.65rem;
  }

  .phone-frame {
    padding: 0.65rem;
    border-radius: 1.8rem;
  }

  .card {
    min-height: 34rem;
  }

  .card-face {
    padding: 1rem;
  }

  .number-list {
    margin-top: 3.1rem;
    gap: 0.55rem;
  }

  .number-row {
    min-height: 4.25rem;
  }

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

  .call-link,
  .qr-mini {
    min-width: 2.8rem;
    padding: 0.38rem 0.55rem;
  }
}
