* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  font-family: var(--font-stack);
  background:
    radial-gradient(circle at top, rgba(255, 122, 47, 0.14), transparent 28%),
    linear-gradient(180deg, #fff7f1 0%, #f3f5f9 42%, #edf1f5 100%);
  color: var(--font-primary);
}

body {
  min-width: 320px;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
textarea {
  font: inherit;
}

button {
  border: 0;
  background: none;
  padding: 0;
  color: inherit;
  cursor: pointer;
}

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

[hidden] {
  display: none !important;
}

.page-backdrop {
  min-height: 100vh;
  padding: 32px 20px 56px;
}

.phone-shell {
  position: relative;
  width: min(100%, var(--screen-width));
  min-height: var(--screen-height);
  margin: 0 auto;
  overflow: hidden;
  border-radius: 36px;
  background: var(--bg-gray);
  box-shadow: 0 36px 80px rgba(26, 26, 46, 0.18);
}

.phone-shell.is-flat {
  border-radius: 0;
  min-height: 100vh;
  box-shadow: none;
}

.status-bar {
  display: none;
}

.status-bar.status-bar--orange {
  color: var(--font-white);
  background: var(--primary);
}

.status-icons {
  display: flex;
  align-items: center;
  gap: 6px;
}

.status-chip {
  width: 17px;
  height: 10px;
  border: 1.8px solid currentColor;
  border-radius: 3px;
  position: relative;
  opacity: 0.72;
}

.status-chip::after {
  content: "";
  position: absolute;
  right: -4px;
  top: 2px;
  width: 2px;
  height: 4px;
  border-radius: 1px;
  background: currentColor;
}

.signal-bars,
.wifi-mark {
  display: inline-flex;
  align-items: flex-end;
  gap: 1px;
}

.signal-bars span {
  display: block;
  width: 2px;
  border-radius: 2px;
  background: currentColor;
}

.signal-bars span:nth-child(1) {
  height: 4px;
  opacity: 0.45;
}

.signal-bars span:nth-child(2) {
  height: 6px;
  opacity: 0.6;
}

.signal-bars span:nth-child(3) {
  height: 8px;
  opacity: 0.75;
}

.signal-bars span:nth-child(4) {
  height: 10px;
}

.wifi-mark {
  width: 12px;
  height: 10px;
  position: relative;
}

.wifi-mark::before,
.wifi-mark::after {
  content: "";
  position: absolute;
  inset: auto;
  left: 50%;
  transform: translateX(-50%);
  border: 1.6px solid currentColor;
  border-top-color: transparent;
  border-left-color: transparent;
  border-right-color: transparent;
  border-radius: 50%;
}

.wifi-mark::before {
  bottom: 2px;
  width: 12px;
  height: 8px;
}

.wifi-mark::after {
  bottom: 0;
  width: 5px;
  height: 4px;
}

.app-header {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 48px;
  padding: 0 16px;
}

.app-header--orange {
  color: var(--font-white);
  background: var(--primary);
}

.app-header--center {
  justify-content: center;
}

.app-header--between {
  justify-content: space-between;
}

.app-header__title {
  font-size: 17px;
  font-weight: 600;
}

.app-header__stretch {
  flex: 1;
  text-align: center;
}

.app-header__side {
  display: flex;
  align-items: center;
  gap: 14px;
}

.app-content {
  display: flex;
  flex-direction: column;
  min-height: calc(var(--screen-height) - var(--safe-top));
}

.preview-shell {
  max-width: 1220px;
  margin: 0 auto;
}

.preview-hero {
  display: grid;
  gap: 18px;
  margin-bottom: 24px;
  padding: 28px;
  border-radius: 28px;
  background:
    radial-gradient(circle at top right, rgba(255, 171, 115, 0.4), transparent 26%),
    linear-gradient(135deg, #fff7f1 0%, #ffffff 100%);
  box-shadow: var(--shadow-card);
}

.preview-hero h1 {
  margin: 0;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.05;
}

.preview-hero p {
  margin: 0;
  max-width: 760px;
  color: var(--font-secondary);
  font-size: 15px;
  line-height: 1.7;
}

.preview-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 18px;
}

.preview-card {
  display: grid;
  gap: 12px;
  padding: 18px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.84);
  border: 1px solid rgba(255, 255, 255, 0.6);
  box-shadow: var(--shadow-card);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.preview-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 45px rgba(26, 26, 46, 0.1);
}

.preview-card__badge {
  justify-self: start;
  padding: 6px 10px;
  border-radius: 999px;
  background: var(--primary-light);
  color: var(--primary-dark);
  font-size: 12px;
  font-weight: 600;
}

.preview-card h2 {
  margin: 0;
  font-size: 18px;
}

.preview-card p {
  margin: 0;
  color: var(--font-secondary);
  font-size: 14px;
  line-height: 1.6;
}

.preview-card__link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--primary-dark);
  font-size: 14px;
  font-weight: 600;
}

.icon {
  display: inline-flex;
  width: 20px;
  height: 20px;
  color: currentColor;
  flex: 0 0 auto;
}

.icon svg {
  width: 100%;
  height: 100%;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.icon--filled svg {
  fill: currentColor;
  stroke: none;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.toast-root {
  position: fixed;
  left: 50%;
  bottom: 30px;
  z-index: 20;
  transform: translateX(-50%);
  display: grid;
  gap: 10px;
}

.toast {
  padding: 12px 16px;
  border-radius: 999px;
  background: rgba(26, 26, 46, 0.92);
  color: #fff;
  font-size: 13px;
  box-shadow: 0 12px 28px rgba(26, 26, 46, 0.25);
  animation: toast-in 0.2s ease;
}

@keyframes toast-in {
  from {
    opacity: 0;
    transform: translateY(8px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 640px) {
  .page-backdrop {
    padding: 0;
  }

  .phone-shell {
    width: 100%;
    min-height: 100vh;
    border-radius: 0;
    box-shadow: none;
  }
}
