@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600;700;800&family=Plus+Jakarta+Sans:wght@700;800&display=swap');

:root {
  --bg: #080704;
  --surface: rgba(18, 15, 9, 0.86);
  --surface-2: rgba(31, 26, 16, 0.88);
  --surface-3: rgba(48, 39, 22, 0.84);
  --gold: #c79632;
  --gold-2: #f1d589;
  --gold-3: #7c581b;
  --text: #fff7e6;
  --muted: #b9ad95;
  --line: rgba(241, 213, 137, 0.22);
  --line-soft: rgba(241, 213, 137, 0.11);
  --danger: #ff8d8d;
  --ok: #8ee2a2;
  --shadow: 0 28px 70px rgba(0, 0, 0, 0.52);
}

* { box-sizing: border-box; }

html {
  min-height: 100%;
  background: var(--bg);
  overflow-x: hidden;
}

body {
  min-height: 100%;
  margin: 0;
  overflow-x: hidden;
  font-family: "Manrope", sans-serif;
  color: var(--muted);
  background:
    radial-gradient(circle at 18% 0%, rgba(241, 213, 137, 0.14), transparent 34%),
    radial-gradient(circle at 85% 14%, rgba(199, 150, 50, 0.14), transparent 32%),
    linear-gradient(180deg, #110d07 0%, #080704 58%, #050403 100%);
}

.bg {
  position: fixed;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.bg::before,
.bg::after {
  content: "";
  position: absolute;
  inset: auto -18% 8% -18%;
  height: 280px;
  background:
    repeating-linear-gradient(100deg, transparent 0 12px, rgba(241, 213, 137, 0.13) 13px, transparent 14px),
    linear-gradient(90deg, transparent, rgba(199, 150, 50, 0.26), transparent);
  filter: blur(0.2px);
  transform: rotate(-7deg);
  opacity: 0.72;
}

.bg::after {
  inset: 2% -28% auto -28%;
  transform: rotate(9deg);
  opacity: 0.34;
}

.page {
  position: relative;
  width: 100%;
  max-width: 560px;
  min-height: 100vh;
  margin: 0 auto;
  padding: 22px 16px 28px;
}

.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 10px 2px 20px;
}

.brand {
  display: flex;
  align-items: center;
  min-width: 0;
  gap: 14px;
}

.logo {
  width: 50px;
  height: 50px;
  flex: 0 0 auto;
  object-fit: cover;
  border-radius: 16px;
  background: #13100a;
  border: 1px solid var(--line);
  box-shadow: 0 12px 32px rgba(199, 150, 50, 0.18);
}

.title {
  font-family: "Plus Jakarta Sans", "Manrope", sans-serif;
  font-size: 23px;
  line-height: 1.05;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.04em;
}

.sub {
  max-width: 250px;
  margin-top: 6px;
  font-size: 13px;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.toolbar {
  display: flex;
  align-items: center;
}

.lang {
  display: flex;
  align-items: center;
  gap: 8px;
}

.lang-label {
  display: none;
}

.lang-select {
  appearance: none;
  min-width: 92px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 10px 32px 10px 14px;
  font: 700 13px/1 "Manrope", sans-serif;
  color: var(--text);
  background:
    linear-gradient(45deg, transparent 50%, var(--gold-2) 50%) calc(100% - 18px) 50% / 6px 6px no-repeat,
    linear-gradient(135deg, var(--gold-2) 50%, transparent 50%) calc(100% - 13px) 50% / 6px 6px no-repeat,
    rgba(24, 20, 12, 0.92);
  outline: none;
}

.card {
  position: relative;
  padding: 22px;
  border-radius: 28px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.035), transparent 28%),
    var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  overflow: hidden;
  backdrop-filter: blur(18px);
}

.card::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 12% 0%, rgba(241, 213, 137, 0.15), transparent 32%),
    radial-gradient(circle at 88% 0%, rgba(199, 150, 50, 0.13), transparent 28%);
  pointer-events: none;
}

.card > * {
  position: relative;
}

.status {
  margin-bottom: 18px;
  padding: 13px 15px;
  border-radius: 16px;
  border: 1px solid var(--line-soft);
  background: rgba(8, 7, 4, 0.42);
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.status.info {
  color: var(--gold-2);
  border-color: rgba(241, 213, 137, 0.24);
  background: rgba(199, 150, 50, 0.12);
}

.status.ok {
  color: var(--ok);
  border-color: rgba(142, 226, 162, 0.24);
  background: rgba(142, 226, 162, 0.1);
}

.status.err {
  color: var(--danger);
  border-color: rgba(255, 141, 141, 0.28);
  background: rgba(255, 141, 141, 0.1);
}

.info-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  margin: 14px 0 18px;
}

.info-item {
  padding: 16px;
  border-radius: 18px;
  border: 1px solid var(--line-soft);
  background: rgba(8, 7, 4, 0.38);
}

.label,
.payment-label {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.value {
  margin-top: 7px;
  color: var(--text);
  font-size: 15px;
  font-weight: 800;
  word-break: break-all;
}

.supported {
  margin: 10px 0 4px;
}

.supported-head {
  margin-bottom: 13px;
}

.supported-title {
  color: var(--text);
  font: 800 16px/1.1 "Plus Jakarta Sans", "Manrope", sans-serif;
}

.supported-sub {
  margin-top: 6px;
  font-size: 12px;
  line-height: 1.45;
}

.supported-cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 9px;
}

.brand-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 54px;
  max-width: 100%;
  height: 34px;
  padding: 7px 10px;
  border: 1px solid var(--line-soft);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.045);
}

.brand-icon,
.brand-icon img {
  display: block;
  width: 34px;
  height: 21px;
  object-fit: contain;
}

.divider {
  height: 1px;
  margin: 22px 0;
  background: linear-gradient(90deg, transparent, var(--line), transparent);
}

.awx-grid {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.payment-label {
  margin: 0 0 8px 3px;
}

.payment-item,
.card-element {
  min-height: 54px;
  padding: 15px;
  border-radius: 16px;
  border: 1px solid rgba(241, 213, 137, 0.16);
  background: rgba(8, 7, 4, 0.58);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.pay-progress,
.pay-success {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 16px;
  padding: 15px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: rgba(199, 150, 50, 0.12);
}

.pay-success {
  border-color: rgba(142, 226, 162, 0.24);
  background: rgba(142, 226, 162, 0.1);
}

.spinner {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 3px solid rgba(241, 213, 137, 0.18);
  border-top-color: var(--gold-2);
  animation: spin 0.9s linear infinite;
  flex: 0 0 auto;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.pay-progress-title,
.pay-success-title {
  color: var(--text);
  font-weight: 800;
  font-size: 14px;
}

.pay-progress-desc,
.pay-success-desc {
  margin-top: 3px;
  font-size: 12px;
  line-height: 1.4;
}

.pay-success-icon {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  flex: 0 0 auto;
  border-radius: 50%;
  color: #102014;
  background: var(--ok);
}

.btn {
  width: 100%;
  margin-top: 22px;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--text);
  background: rgba(255, 255, 255, 0.045);
  font: 800 16px/1 "Manrope", sans-serif;
  cursor: pointer;
  transition: transform 0.12s ease, opacity 0.18s ease, border-color 0.18s ease;
}

.btn.primary {
  color: #120d04;
  border-color: rgba(241, 213, 137, 0.55);
  background: var(--gold);
  box-shadow: 0 16px 34px rgba(199, 150, 50, 0.24);
}

.btn:active {
  transform: scale(0.985);
}

.btn:disabled {
  opacity: 0.48;
  cursor: not-allowed;
  transform: none;
}

.hint {
  margin-top: 22px;
  padding: 16px;
  border-radius: 18px;
  border: 1px solid var(--line-soft);
  background: rgba(8, 7, 4, 0.32);
  font-size: 12px;
  line-height: 1.6;
}

.hint-title {
  margin-bottom: 8px;
  color: var(--text);
  font-weight: 800;
}

.hint ul {
  margin: 0;
  padding-left: 18px;
}

.footer {
  padding: 16px 2px 0;
}

.fineprint {
  color: rgba(185, 173, 149, 0.72);
  font-size: 11px;
  line-height: 1.55;
  text-align: center;
}

.debug {
  margin-top: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(8, 7, 4, 0.66);
  color: var(--gold-2);
  font-size: 11px;
  line-height: 1.5;
  white-space: pre-wrap;
  word-break: break-all;
}

@media (max-width: 980px) {
  .page {
    max-width: 430px;
  }
  .supported-cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .field-row {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 420px) {
  .page { padding: 18px 14px 24px; }
  .card { padding: 18px; border-radius: 24px; }
  .title { font-size: 20px; }
  .sub { max-width: 210px; }
  .logo { width: 46px; height: 46px; border-radius: 14px; }
  .lang-select {
    min-width: 0;
    width: 72px;
    padding-left: 10px;
    padding-right: 26px;
  }
}
