.shell {
  min-height: 100%;
  display: grid;
  place-items: center;
  padding: 16px;
}

.shell__phone {
  width: min(100%, var(--phone-max));
  min-height: min(100dvh - 32px, 860px);
  height: min(100dvh - 32px, 860px);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.35), transparent 28%),
    var(--bg);
  border: 1px solid var(--line-strong);
  border-radius: 28px;
  box-shadow: var(--shadow-soft);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  position: relative;
}

.shell__phone::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(rgba(26, 46, 36, 0.03) 0.6px, transparent 0.6px);
  background-size: 3px 3px;
  pointer-events: none;
  opacity: 0.45;
}

.shell__top {
  position: relative;
  z-index: 1;
  padding: calc(14px + var(--safe-top)) 20px 8px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.shell__nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 28px;
}

.shell__back {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--ink-soft);
  padding: 4px 0;
}

.shell__back:disabled {
  opacity: 0;
  pointer-events: none;
}

.shell__body {
  position: relative;
  z-index: 1;
  flex: 1;
  min-height: 0;
  overflow: auto;
  padding: 8px 20px 0;
  display: flex;
  flex-direction: column;
}

.shell__body > .shell__footer {
  margin-top: auto;
  flex-shrink: 0;
}

.shell__footer {
  position: relative;
  z-index: 1;
  padding: 16px 20px calc(18px + var(--safe-bottom));
  display: flex;
  flex-direction: column;
  gap: 10px;
  background: linear-gradient(180deg, transparent, rgba(243, 239, 230, 0.95) 28%);
}

@media (max-width: 480px) {
  .shell {
    padding: 0;
  }

  .shell__phone {
    width: 100%;
    min-height: 100dvh;
    height: 100dvh;
    border: none;
    border-radius: 0;
    box-shadow: none;
  }
}
