/* === VOLTEDGE CHECKOUT — LIGHT THEME === */
@import url('https://fonts.googleapis.com/css2?family=Syne:wght@700;800&family=DM+Sans:opsz,wght@9..40,400;9..40,500;9..40,600&display=swap');

:root {
  --primary:        #1e6cff;
  --primary-end:    #4facfe;
  --gradient:       linear-gradient(45deg, var(--primary), var(--primary-end));
  --primary-light:  #4facfe;
  --primary-dim:    rgba(30,108,255,0.08);
  --primary-border: rgba(30,108,255,0.20);
  --primary-glow:   0 4px 28px rgba(30,108,255,0.18);

  --bg:             #eef4ff;
  --surface:        #ffffff;
  --surface-raised: #f5f8ff;
  --surface-hover:  #edf2ff;

  --text:           #0f172a;
  --text-soft:      #334155;
  --text-muted:     #94a3b8;
  --border:         rgba(30,108,255,0.10);
  --border-accent:  rgba(30,108,255,0.22);
  --error:          #ef4444;

  --radius-card:    22px;
  --radius-btn:     14px;
  --radius-input:   12px;
  --font-body:      'DM Sans', sans-serif;
  --font-display:   'Syne', sans-serif;
}

/* ── RESET ── */
*, *::before, *::after { margin:0; padding:0; box-sizing:border-box; }

body {
  font-family: var(--font-body);
  font-size: 14px;
  background: var(--bg);
  color: var(--text);
  min-height: 100dvh;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* light mesh background */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background:
    radial-gradient(ellipse 70% 50% at 10% 0%,   rgba(30,108,255,.10), transparent 60%),
    radial-gradient(ellipse 55% 55% at 90% 100%,  rgba(79,172,254,.08), transparent 60%),
    radial-gradient(ellipse 40% 35% at 50% 50%,   rgba(30,108,255,.04), transparent 70%);
  pointer-events: none;
  z-index: 0;
}

/* subtle grid lines */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(30,108,255,.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(30,108,255,.05) 1px, transparent 1px);
  background-size: 40px 40px;
  pointer-events: none;
  z-index: 0;
}

/* ── LOADING OVERLAY ── */
.loading {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: var(--bg);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2.5rem;
}

.loader-logo {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: 1px;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.loader-logo::before { content: 'VOLTEDGE'; }

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

#ld4 {
  display: flex;
  gap: 7px;
}

#ld4 div {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--primary);
}

#ld4 div:nth-child(1) { animation: dot 1.4s ease-in-out 0s   infinite; }
#ld4 div:nth-child(2) { animation: dot 1.4s ease-in-out .14s infinite; }
#ld4 div:nth-child(3) { animation: dot 1.4s ease-in-out .28s infinite; }
#ld4 div:nth-child(4) { animation: dot 1.4s ease-in-out .42s infinite; }
#ld4 div:nth-child(5) { animation: dot 1.4s ease-in-out .56s infinite; }

@keyframes dot {
  0%,100% { opacity:.2; transform:scale(.65); background: var(--primary); }
  50%      { opacity:1;  transform:scale(1.25); background: var(--primary-end); }
}

/* ── INVALID OVERLAY ── */
.invalid {
  position: fixed;
  inset: 0;
  z-index: 900;
  background: rgba(238,244,255,.88);
  backdrop-filter: blur(12px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}

.invalid-main {
  background: var(--surface);
  border: 1px solid var(--border-accent);
  border-radius: var(--radius-card);
  padding: 2rem 1.75rem;
  max-width: 320px;
  width: 100%;
  text-align: center;
  box-shadow: var(--primary-glow), 0 0 0 1px rgba(79,172,254,.08);
  animation: scaleIn .2s ease;
}

.invalid-icon-wrap {
  width: 3.5rem;
  height: 3.5rem;
  margin: 0 auto 1.1rem;
}

.invalid-icon-wrap svg {
  width: 100%;
  height: 100%;
  animation: popIn .35s cubic-bezier(.34,1.56,.64,1) both;
}

.invalid-icon-wrap svg circle { fill: url(#btn-grad); }

@keyframes popIn {
  from { opacity:0; transform:scale(.5); }
  to   { opacity:1; transform:scale(1); }
}

.invalid-message {
  color: var(--text-soft);
  font-size: .9rem;
  line-height: 1.65;
}

@keyframes scaleIn {
  from { opacity:0; transform:scale(.94); }
  to   { opacity:1; transform:scale(1); }
}

/* ── PAGE SHELL ── */
.page {
  position: relative;
  z-index: 1;
  min-height: 100dvh;
  max-width: 460px;
  margin: 0 auto;
  padding: 0 1.25rem 2.5rem;
  display: flex;
  flex-direction: column;
}

/* ── SITE HEADER ── */
.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.35rem 0 1rem;
}

.brand {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: .5px;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.secure-badge {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: .68rem;
  font-weight: 500;
  color: var(--text-muted);
  background: rgba(255,255,255,.04);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 4px 10px;
  letter-spacing: .6px;
  text-transform: uppercase;
}

.secure-badge svg { flex-shrink:0; }

/* ── AMOUNT HERO ── */
.amount-hero {
  text-align: center;
  padding: 1.75rem 0 2rem;
  animation: fadeUp .35s ease;
}

.amount-label {
  display: block;
  font-size: .68rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: .65rem;
}

.amount {
  display: block;
  font-family: var(--font-body);
  font-size: 3.2rem;
  font-weight: 700;
  letter-spacing: -1px;
  line-height: 1;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ── PAYMENT CARD ── */
.payment-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  box-shadow:
    0 0 0 1px rgba(30,108,255,.06),
    0 8px 40px rgba(30,108,255,.10),
    inset 0 1px 0 rgba(255,255,255,.80);
  overflow: hidden;
  animation: fadeUp .4s ease;
}

/* ── PAYMENT HEADER ── */
.payment-header {
  padding: 1.25rem 1.5rem .85rem;
  border-bottom: 1px solid var(--border);
  background: var(--surface-raised);
}

.payment-header-label {
  font-size: .68rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin-bottom: .9rem;
}

/* ── TABS ── */
#tabs {
  display: flex;
  gap: 4px;
  background: rgba(30,108,255,.06);
  border-radius: 12px;
  padding: 4px;
  border: 1px solid var(--border);
}

#tabs a {
  flex: 1;
  text-align: center;
  padding: .5rem 0;
  font-size: .8rem;
  font-weight: 500;
  color: var(--text-muted);
  border-radius: 9px;
  cursor: pointer;
  text-decoration: none;
  transition: all .2s ease;
  user-select: none;
}

#tabs a.active {
  background: var(--gradient);
  color: #fff;
  box-shadow: 0 2px 16px rgba(30,108,255,.40);
}

/* ── PAYMENT BODY ── */
.payment-body { padding: 1.35rem 1.5rem 1.5rem; }

.mod        { display: none; }
.mod.active { display: block; }

/* ── CAPTION ── */
.caption {
  font-size: .83rem;
  color: var(--text-soft);
  line-height: 1.6;
  margin-bottom: 1.25rem;
}

.caption b { font-weight: 600; }

.caption .amount {
  display: inline;
  font-family: var(--font-body);
  font-size: inherit;
  font-weight: 600;
  letter-spacing: normal;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ── BANK TRANSFER ROWS ── */
.bank-rows {
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
  margin-bottom: 1.1rem;
  background: var(--surface-raised);
}

.bank-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: .9rem 1.1rem;
  gap: .75rem;
  transition: background .15s;
}

.bank-row + .bank-row {
  border-top: 1px solid var(--border);
}

.bank-row:hover { background: var(--surface-hover); }

.row-left { flex-shrink: 0; }

.row-label {
  font-size: .65rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: .8px;
  display: block;
  white-space: nowrap;
}

.row-right {
  display: flex;
  align-items: center;
  gap: .5rem;
  flex: 1;
  justify-content: flex-end;
}

.row-value {
  font-size: .9rem;
  font-weight: 500;
  color: var(--text);
  text-align: right;
}

/* copy button */
.copy-btn, .copy {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: var(--primary-dim);
  border: 1px solid var(--primary-border);
  border-radius: 8px;
  padding: 4px 9px;
  font-size: .7rem;
  font-weight: 500;
  color: var(--primary-end);
  cursor: pointer;
  flex-shrink: 0;
  font-family: var(--font-body);
  transition: background .15s;
}

.copy-btn svg, .copy svg {
  width: 11px;
  height: 11px;
  flex-shrink: 0;
}

.copy-btn:hover, .copy:hover {
  background: rgba(79,172,254,.22);
}

.transfer-note {
  font-size: .74rem;
  color: var(--text-muted);
  text-align: center;
  line-height: 1.55;
  margin-bottom: 1.1rem;
  padding: .6rem .75rem;
  background: rgba(30,108,255,.05);
  border: 1px solid rgba(30,108,255,.12);
  border-radius: 10px;
}

/* ── CARD FORM ── */
.card-fields {
  display: flex;
  flex-direction: column;
  gap: .75rem;
  margin-bottom: 1.25rem;
}

.field { display: flex; flex-direction: column; gap: 5px; }

.field-label {
  font-size: .68rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: .8px;
}

.field-input {
  display: flex;
  align-items: center;
  gap: .5rem;
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-input);
  padding: .75rem 1rem;
  transition: border-color .2s, background .2s;
}

.field-input:focus-within {
  border-color: var(--primary);
  background: rgba(30,108,255,.04);
  box-shadow: 0 0 0 3px rgba(30,108,255,.10);
}

.field-input input {
  flex: 1;
  background: none;
  border: none;
  outline: none;
  color: var(--text);
  font-family: var(--font-body);
  font-size: .95rem;
  min-width: 0;
}

.field-input input::placeholder { color: var(--text-muted); }

.field-sep { color: var(--text-muted); font-size: .9rem; }

.field-row { display: flex; gap: .75rem; }
.field-row .field { flex: 1; }

.card-icons { display: flex; gap: 4px; flex-shrink: 0; }

/* icon sprites */
.icon {
  display: block;
  width: 18px;
  height: 18px;
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
}

.icon-master { background-image: url(../img/icon-master.png); }
.icon-visa   { background-image: url(../img/icon-visa.png); }
.icon-verve  { background-image: url(../img/icon-verve.png); }
.icon-card   { background-image: url(../img/icon-card.png); opacity:.4; }
.icon-right  { background-image: url(../img/icon-right.webp); width:18px; height:18px; flex-shrink:0; filter: brightness(0) invert(1); }

/* ── BUTTONS ── */
.btn, .bottom_tips {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: .95rem 1rem;
  border: none;
  border-radius: var(--radius-btn);
  font-family: var(--font-body);
  font-size: .92rem;
  font-weight: 600;
  cursor: pointer;
  transition: all .2s ease;
  background: var(--gradient);
  color: #fff;
  box-shadow: var(--primary-glow);
  letter-spacing: .1px;
  position: relative;
  overflow: hidden;
}

.btn::after, .bottom_tips::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0);
  transition: background .2s;
}

.btn:not(:disabled):hover::after,
.bottom_tips:not(:disabled):hover::after {
  background: rgba(255,255,255,.10);
}

.btn:not(:disabled):hover,
.bottom_tips:not(:disabled):hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 32px rgba(30,108,255,.50);
}

.btn:not(:disabled):active,
.bottom_tips:not(:disabled):active {
  transform: translateY(0);
}

.btn:disabled,
.bottom_tips:disabled {
  background: rgba(30,108,255,.10);
  color: rgba(30,108,255,.35);
  cursor: not-allowed;
  box-shadow: none;
}

.btn.loading {
  background: rgba(255,255,255,.05);
  color: var(--text-soft);
  box-shadow: none;
}

.bottom_tips_text { flex:1; text-align:center; }

/* ── USSD ── */
.ussd-placeholder {
  text-align: center;
  padding: 3rem 0 2rem;
  color: var(--text-muted);
  font-size: .85rem;
}

/* ── RESULT / SUCCESS ── */
.result {
  padding: 2.5rem 1.5rem 1.5rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.result-icon {
  width: 5rem;
  height: 5rem;
  border-radius: 50%;
  background: var(--primary-dim);
  border: 1px solid var(--primary-border);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
  box-shadow: 0 0 30px rgba(30,108,255,.20);
}

.result-icon img { width: 2.6rem; }

.result-title {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: .5rem;
  color: var(--text);
}

.result-caption {
  font-size: .83rem;
  color: var(--text-soft);
  line-height: 1.65;
  margin-bottom: 1.75rem;
  max-width: 280px;
}

#success .btn {
  max-width: 240px;
}

/* ── SITE FOOTER ── */
.site-footer {
  margin-top: auto;
  padding-top: 1.75rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .45rem;
}

.secured {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: .73rem;
  color: var(--text-muted);
}

.secured strong {
  font-weight: 600;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.version-tag {
  font-size: .62rem;
  color: var(--text-muted);
  background: rgba(30,108,255,.05);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 2px 9px;
  letter-spacing: .4px;
}

.html_version, .css_version { display: none; }
.html_version.version-tag, .css_version.version-tag { display: inline-block; }

/* ── COPY TIP ── */
#tip {
  position: fixed;
  top: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  background: var(--gradient);
  color: #fff;
  font-size: .75rem;
  font-weight: 500;
  padding: 6px 16px;
  border-radius: 8px;
  white-space: nowrap;
  opacity: 0;
  transition: opacity .3s ease;
  z-index: 9999;
  pointer-events: none;
  font-family: var(--font-body);
  box-shadow: 0 4px 16px rgba(30,108,255,.35);
}

#tip.show { opacity: 1; }

/* ── ANIMATIONS ── */
@keyframes fadeUp {
  from { opacity:0; transform:translateY(16px); }
  to   { opacity:1; transform:translateY(0); }
}
