/* ============================================================
   screens.css — Per-screen layout styles
============================================================ */

/* ── Splash ──────────────────────────────────────────────── */

.screen--splash {
  justify-content: flex-start;
  padding: 52px 28px 36px;
}

.splash__title {
  font-size: 60px;
  font-weight: 900;
  letter-spacing: -2px;
  line-height: 1;
  color: var(--txt);
  margin-bottom: 6px;
}

.splash__sub {
  font-size: 22px;
  font-weight: 600;
  color: var(--txt-2);
  letter-spacing: 0.3px;
}

.splash__sticker-wrap {
  flex: 1;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.splash__glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 320px;
  height: 320px;
  background: radial-gradient(ellipse at center,
    rgba(255, 210, 80,  0.38) 0%,
    rgba(255, 145, 193, 0.22) 45%,
    transparent 72%
  );
  filter: blur(28px);
  border-radius: 50%;
  pointer-events: none;
}

.splash__sticker {
  width: 85%;
  max-width: 290px;
  filter: drop-shadow(0 24px 36px rgba(0, 0, 0, 0.10));
  animation: floatY 3.5s ease-in-out infinite;
  position: relative;
  z-index: 1;
}

.splash__loader-wrap {
  width: 100%;
  margin-top: 8px;
}

.splash__loader-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--txt-2);
  text-align: center;
  margin-bottom: 8px;
}

/* ── Main ────────────────────────────────────────────────── */

.screen--main {
  padding-top: 0;
}

.main-scroll {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 8px 16px 20px;
}

/* Space between ring and input */
.ring-wrap {
  margin-bottom: 10px;
}

/* Space between input and chips */
.prompt-input {
  margin-bottom: 8px;
}

/* ── Loading ─────────────────────────────────────────────── */

.screen--loading {
  justify-content: center;
  align-items: center;
  gap: 28px;
}

.loading__text-wrap {
  text-align: center;
}

.loading__title {
  font-weight: 700;
  font-size: 18px;
  color: var(--txt);
}

.loading__sub {
  font-size: 14px;
  color: var(--txt-2);
  margin-top: 6px;
}

/* ── Result ──────────────────────────────────────────────── */

.screen--result {
  padding-top: 0;
}

.result-scroll {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 10px 16px 24px;
}

.result__badge {
  display: inline-block;
  background: linear-gradient(135deg, var(--color-purple), var(--color-pink));
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  padding: 6px 18px;
  border-radius: var(--radius-full);
  margin-bottom: 16px;
}

.result__card {
  width: 100%;
  border-radius: var(--radius-xl);
  background: var(--card);
  border: 2px solid var(--border);
  box-shadow: var(--shadow);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  margin-bottom: 18px;
  position: relative;
  overflow: hidden;
}

.result__glow {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at center,
    rgba(255, 200, 80, 0.15) 0%,
    transparent 70%
  );
  pointer-events: none;
}

.result__img {
  width: 72%;
  max-width: 220px;
  filter: drop-shadow(0 18px 32px rgba(0, 0, 0, 0.12));
  animation: floatY 3.5s ease-in-out infinite;
}

.result-scroll .btn--primary {
  margin-bottom: 12px;
}

/* ── Empty State ─────────────────────────────────────────── */

.screen--empty {
  justify-content: center;
  align-items: center;
  padding: 40px 28px;
  gap: 0;
}

.empty__emoji {
  font-size: 64px;
  display: block;
  margin-bottom: 20px;
  animation: floatY 3s ease-in-out infinite;
}

.empty__title {
  font-size: 26px;
  font-weight: 900;
  text-align: center;
  margin-bottom: 10px;
  letter-spacing: -0.4px;
}

.empty__sub {
  font-size: 15px;
  color: var(--txt-2);
  text-align: center;
  margin-bottom: 36px;
  font-weight: 500;
  line-height: 1.55;
}

/* ── Paywall ─────────────────────────────────────────────── */

.screen--paywall {
  padding-top: 0;
}

.pay-scroll {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 8px 22px 30px;
}

.pay__title {
  font-size: 26px;
  font-weight: 900;
  letter-spacing: -0.5px;
  margin-bottom: 4px;
}

.pay__sub {
  font-size: 15px;
  color: var(--txt-2);
  font-weight: 500;
  margin-bottom: 18px;
}

.balance-card {
  width: 100%;
  background: var(--card);
  border: 2px solid var(--border);
  border-radius: var(--radius-md);
  padding: 14px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
  box-shadow: var(--shadow);
}

.balance-card__left {
  display: flex;
  flex-direction: column;
}

.balance-card__num {
  font-size: 30px;
  font-weight: 900;
  color: var(--txt);
  line-height: 1;
}

.balance-card__lbl {
  font-size: 13px;
  color: var(--txt-2);
  font-weight: 500;
  margin-top: 3px;
}

/* ── Settings ────────────────────────────────────────────── */

.screen--settings {
  padding-top: 0;
}

.settings-scroll {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 10px 22px 30px;
}

/* ── History ─────────────────────────────────────────────── */

.screen--history {
  padding-top: 0;
}

.history-scroll {
  padding: 10px 18px 30px;
}

.history-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.history-card {
  border-radius: var(--radius-md);
  background: var(--card);
  border: 2px solid var(--border);
  box-shadow: var(--shadow);
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.18s;
}

.history-card:hover {
  transform: scale(1.02);
}

.history-card__img-wrap {
  width: 100%;
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.history-card__img {
  width: 100%;
  filter: drop-shadow(0 8px 14px rgba(0, 0, 0, 0.10));
}

.history-card__footer {
  padding: 8px 12px 12px;
}

.history-subtitle {
  font-size: 12px;
  color: var(--txt-3);
  font-weight: 500;
  text-align: center;
  margin-bottom: 14px;
  margin-top: 2px;
}

.history-card__prompt {
  font-size: 12px;
  font-weight: 600;
  color: var(--txt-2);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.history-card__add {
  margin-top: 6px;
  width: 100%;
  padding: 6px 12px;
  background: linear-gradient(135deg, var(--color-yellow), var(--color-pink));
  border: none;
  border-radius: 10px;
  font-weight: 700;
  font-size: 12px;
  color: #3D2B00;
  cursor: pointer;
  transition: opacity 0.18s;
}

.history-card__add:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

/* ── My Pack ─────────────────────────────────────────────── */

.screen--mypack {
  padding-top: 0;
}

.mypack__body {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 20px 28px 40px;
  width: 100%;
}

.mypack__emoji {
  font-size: 56px;
  display: block;
  margin-bottom: 20px;
  animation: floatY 3s ease-in-out infinite;
}

.mypack__title {
  font-size: 26px;
  font-weight: 900;
  text-align: center;
  margin-bottom: 8px;
}

.mypack__sub {
  font-size: 15px;
  color: var(--txt-2);
  text-align: center;
  margin-bottom: 36px;
  line-height: 1.6;
  font-weight: 500;
}

.mypack__body .btn--telegram {
  width: 100%;
}

/* ── Desktop / Mac Telegram compact mode ────────────────── */

@media (max-height: 700px) {
  .ring-wrap {
    --ring-size: clamp(140px, 36vw, 170px) !important;
    margin-bottom: 8px;
  }

  .main-scroll {
    padding-top: 6px;
    padding-bottom: 16px;
  }

  .prompt-input {
    margin-bottom: 6px;
  }
}

@media (min-width: 420px) {
  .ring-wrap {
    --ring-size: 200px !important;
  }
}
