/* mi.lohmia.com — light theme, professional */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --primary:     #1a56db;
  --primary-dk:  #1e429f;
  --accent:      #0ea5e9;
  --success:     #16a34a;
  --danger:      #dc2626;
  --bg:          #f8fafc;
  --bg-card:     #ffffff;
  --border:      #e2e8f0;
  --text:        #0f172a;
  --text-muted:  #64748b;
  --shadow:      0 4px 24px rgba(0,0,0,.08);
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ── Header ── */
.site-header {
  background: #fff;
  border-bottom: 1px solid var(--border);
  padding: 16px 24px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.site-logo {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--primary);
  letter-spacing: -.5px;
}
.site-logo span { color: var(--accent); }
.header-badge {
  font-size: .72rem;
  font-weight: 600;
  background: #eff6ff;
  color: var(--primary);
  border: 1px solid #bfdbfe;
  border-radius: 99px;
  padding: 2px 10px;
  letter-spacing: .3px;
}

/* ── Main ── */
.page-main {
  flex: 1;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 48px 16px 64px;
}

/* ── Card ── */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow: var(--shadow);
  padding: 40px;
  width: 100%;
  max-width: 480px;
}

.card-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 6px;
}
.card-subtitle {
  font-size: .95rem;
  color: var(--text-muted);
  margin-bottom: 28px;
  line-height: 1.5;
}

/* ── Plan block ── */
.plan-block {
  background: #f0f9ff;
  border: 1.5px solid #bae6fd;
  border-radius: 12px;
  padding: 20px 24px;
  margin-bottom: 24px;
}
.plan-name {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 4px;
}
.plan-price {
  font-size: 2rem;
  font-weight: 800;
  color: var(--text);
  line-height: 1.1;
}
.plan-price small {
  font-size: .85rem;
  font-weight: 500;
  color: var(--text-muted);
}
.plan-credits {
  margin-top: 12px;
  font-size: .88rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 6px;
}
.plan-credits svg { color: var(--accent); flex-shrink: 0; }

.plan-features {
  list-style: none;
  margin-top: 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.plan-features li {
  font-size: .875rem;
  color: var(--text-muted);
  display: flex;
  align-items: flex-start;
  gap: 8px;
}
.plan-features li::before {
  content: "✓";
  color: var(--success);
  font-weight: 700;
  flex-shrink: 0;
  margin-top: 1px;
}

/* ── User info ── */
.user-info {
  display: flex;
  align-items: center;
  gap: 12px;
  background: #f8fafc;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px 16px;
  margin-bottom: 24px;
}
.user-avatar {
  width: 38px; height: 38px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: .95rem; font-weight: 700;
  flex-shrink: 0;
}
.user-name { font-size: .9rem; font-weight: 600; }
.user-credits { font-size: .8rem; color: var(--text-muted); }

/* ── CTA ── */
.btn-primary {
  display: block;
  width: 100%;
  padding: 14px;
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: 10px;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: background .15s, transform .1s;
  text-align: center;
  text-decoration: none;
}
.btn-primary:hover { background: var(--primary-dk); }
.btn-primary:active { transform: scale(.98); }
.btn-primary:disabled {
  background: #94a3b8;
  cursor: not-allowed;
  transform: none;
}

.btn-secondary {
  display: block;
  width: 100%;
  padding: 12px;
  background: transparent;
  color: var(--text-muted);
  border: 1px solid var(--border);
  border-radius: 10px;
  font-size: .9rem;
  cursor: pointer;
  transition: background .15s;
  text-align: center;
  text-decoration: none;
  margin-top: 10px;
}
.btn-secondary:hover { background: var(--bg); }

/* ── Security note ── */
.secure-note {
  margin-top: 20px;
  font-size: .78rem;
  color: var(--text-muted);
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

/* ── State screens ── */
.state-icon {
  width: 72px; height: 72px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 2rem;
  margin: 0 auto 20px;
}
.state-icon.loading { background: #eff6ff; animation: pulse 1.2s infinite; }
.state-icon.error   { background: #fef2f2; }
.state-icon.expired { background: #fff7ed; }

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: .55; }
}

.spinner {
  width: 40px; height: 40px;
  border: 3px solid #e2e8f0;
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin .8s linear infinite;
  margin: 0 auto 16px;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ── Success / Cancelled pages ── */
.result-card {
  text-align: center;
  max-width: 420px;
}
.result-icon-ok  { background: #f0fdf4; }
.result-icon-err { background: #fff7ed; }

.result-title {
  font-size: 1.6rem;
  font-weight: 800;
  margin-bottom: 10px;
}
.result-body {
  font-size: .95rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 28px;
}

/* ── Footer ── */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 16px 24px;
  text-align: center;
  font-size: .78rem;
  color: var(--text-muted);
}

@media (max-width: 520px) {
  .card { padding: 28px 20px; }
  .plan-price { font-size: 1.7rem; }
}
