*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --bg: #050505;
  --card: #121212;
  --card-border: #1f1f1f;
  --text: #f5f5f5;
  --text-muted: #8a8a8a;
  --youtube: #ff0033;
  --twitch: #9146ff;
  --telegram: #2aabee;
  --success: #22c55e;
  --radius-card: 28px;
  --radius-btn: 14px;
  --font: "Inter", system-ui, -apple-system, sans-serif;
}

html {
  font-size: 16px;
}

body {
  min-height: 100dvh;
  font-family: var(--font);
  background: #020202;
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

.starfield {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

.page {
  position: relative;
  z-index: 1;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
}

.card {
  width: 100%;
  max-width: 420px;
  background: rgba(18, 18, 18, 0.88);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--card-border);
  border-radius: var(--radius-card);
  padding: 32px 24px 24px;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.55);
}

.card__header {
  text-align: center;
  margin-bottom: 24px;
}

.avatar {
  width: 88px;
  height: 88px;
  margin: 0 auto 16px;
  border-radius: 50%;
  background: linear-gradient(145deg, #2a2a2a, #0d0d0d);
  border: 2px solid #2a2a2a;
  display: grid;
  place-items: center;
  overflow: hidden;
}

.avatar__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.avatar__letter {
  font-size: 2rem;
  font-weight: 800;
  color: #fff;
  letter-spacing: -0.02em;
}

.card__title {
  font-size: 1.75rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 8px;
}

.card__subtitle {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.45;
  max-width: 280px;
  margin: 0 auto 16px;
}

.card__cta {
  font-size: 0.85rem;
  font-weight: 600;
  line-height: 1.45;
  color: #f0f0f0;
  max-width: 300px;
  margin: 0 auto;
  padding: 10px 14px;
  border-radius: 12px;
  border: 1px solid rgba(255, 0, 51, 0.35);
  background: linear-gradient(135deg, rgba(255, 0, 51, 0.12), rgba(145, 70, 255, 0.08));
  box-shadow: 0 0 24px rgba(255, 0, 51, 0.08);
}

.progress {
  margin-bottom: 20px;
}

.progress__bar {
  height: 6px;
  background: #1e1e1e;
  border-radius: 999px;
  overflow: hidden;
  margin-bottom: 10px;
}

.progress__fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--youtube), var(--twitch), var(--telegram));
  border-radius: 999px;
  transition: width 0.35s ease;
}

.progress__text {
  font-size: 0.8rem;
  color: var(--text-muted);
  text-align: center;
}

.conditions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 16px;
}

.condition {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.btn {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 14px 16px;
  border-radius: var(--radius-btn);
  background: #0e0e0e;
  border: 1.5px solid #333;
  color: var(--text);
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s, transform 0.15s;
}

.btn:hover {
  background: #161616;
  transform: translateY(-1px);
}

.btn:active {
  transform: translateY(0);
}

.btn--youtube { border-color: var(--youtube); }
.btn--twitch { border-color: var(--twitch); }
.btn--telegram { border-color: var(--telegram); }

.btn--done {
  border-color: var(--success);
  opacity: 0.85;
}

.btn__icon {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
}

.btn__icon svg {
  width: 22px;
  height: 22px;
}

.btn--youtube .btn__icon { color: var(--youtube); }
.btn--twitch .btn__icon { color: var(--twitch); }
.btn--telegram .btn__icon { color: var(--telegram); }

.btn__text {
  flex: 1;
  text-align: left;
}

.btn__arrow {
  color: #666;
  font-size: 1.1rem;
}

.btn__check {
  color: var(--success);
  font-size: 1.1rem;
  display: none;
}

.btn--done .btn__arrow { display: none; }
.btn--done .btn__check { display: block; }

.confirm {
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 12px;
  background: #0a0a0a;
  border: 1px solid #252525;
  border-radius: 10px;
  animation: fadeIn 0.25s ease;
}

.confirm--visible {
  display: flex;
}

.confirm__hint {
  font-size: 0.78rem;
  color: var(--text-muted);
  line-height: 1.35;
  flex: 1;
}

.confirm__btn {
  flex-shrink: 0;
  padding: 8px 14px;
  border: none;
  border-radius: 8px;
  background: #fff;
  color: #000;
  font-family: inherit;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.2s;
}

.confirm__btn:hover {
  opacity: 0.9;
}

.confirm__btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: translateY(0); }
}

.download {
  margin-bottom: 20px;
}

.download.hidden {
  display: none;
}

.download__unlocked {
  text-align: center;
  padding: 8px 0 4px;
  animation: fadeIn 0.4s ease;
}

.download__label {
  font-size: 0.85rem;
  color: var(--success);
  margin-bottom: 12px;
  font-weight: 500;
}

.btn--download {
  border-color: var(--success);
  background: linear-gradient(180deg, #0f1a12, #0a0f0c);
}

.btn--download .btn__icon {
  color: var(--success);
}

.btn--download .btn__icon svg {
  width: 20px;
  height: 20px;
}

.card__footer {
  margin-top: 8px;
  padding-top: 20px;
  border-top: 1px solid #1c1c1c;
  text-align: center;
}

.social-mini {
  display: flex;
  justify-content: center;
  gap: 18px;
  margin-bottom: 14px;
}

.social-mini__link {
  color: #555;
  transition: color 0.2s;
}

.social-mini__link:hover {
  color: #aaa;
}

.social-mini__link svg {
  width: 20px;
  height: 20px;
}

.copyright {
  font-size: 0.72rem;
  color: #555;
  line-height: 1.4;
}

.copyright__brand {
  color: var(--youtube);
  font-weight: 600;
}

.condition__hint {
  font-size: 0.74rem;
  color: var(--text-muted);
  line-height: 1.35;
  padding: 0 4px;
}

.telegram-box {
  display: flex;
  justify-content: center;
  padding: 4px 0 2px;
}

.telegram-box--hidden {
  display: none;
}

.flash {
  display: none;
  margin-bottom: 16px;
  padding: 10px 14px;
  border-radius: 10px;
  font-size: 0.82rem;
  line-height: 1.4;
  text-align: center;
}

.flash--visible {
  display: block;
  animation: fadeIn 0.3s ease;
}

.flash--success {
  background: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.35);
  color: #86efac;
}

.flash--error {
  background: rgba(255, 0, 51, 0.1);
  border: 1px solid rgba(255, 0, 51, 0.35);
  color: #fca5a5;
}

.btn[aria-disabled="true"] {
  pointer-events: none;
}
