:root {
  --bg-base: #090d16;
  --bg-card: rgba(18, 24, 38, 0.85);
  --bg-input: #0d1322;
  --border-glass: rgba(255, 255, 255, 0.08);
  --primary: #3b82f6;
  --primary-gradient: linear-gradient(135deg, #3b82f6 0%, #2563eb 50%, #1d4ed8 100%);
  --emerald: #10b981;
  --amber: #f59e0b;
  --rose: #f43f5e;
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --radius-lg: 18px;
  --radius-md: 12px;
  --radius-sm: 8px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: "Prompt", -apple-system, BlinkMacSystemFont, sans-serif;
  -webkit-font-smoothing: antialiased;
}

body {
  background-color: var(--bg-base);
  background-image:
    radial-gradient(circle at 15% 20%, rgba(59, 130, 246, 0.12) 0%, transparent 40%),
    radial-gradient(circle at 85% 80%, rgba(16, 185, 129, 0.08) 0%, transparent 40%);
  color: var(--text-main);
  min-height: 100vh;
  padding: 40px 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.mono { font-family: "JetBrains Mono", monospace; }

.container {
  width: 100%;
  max-width: 980px;
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.container.narrow { max-width: 640px; }

/* Header */
.app-header { text-align: center; }

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(59, 130, 246, 0.12);
  border: 1px solid rgba(59, 130, 246, 0.3);
  color: #60a5fa;
  font-size: 0.8rem;
  padding: 5px 14px;
  border-radius: 9999px;
  margin-bottom: 14px;
  font-weight: 500;
}

.badge .dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--primary);
  box-shadow: 0 0 10px var(--primary);
}

.app-header h1 {
  font-size: 2.2rem;
  font-weight: 700;
  background: linear-gradient(135deg, #ffffff 0%, #cbd5e1 50%, #94a3b8 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.app-header p {
  color: var(--text-muted);
  margin-top: 8px;
}

/* Cards */
.glass-card {
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: 0 0 35px rgba(59, 130, 246, 0.12);
  position: relative;
  overflow: hidden;
}

.glass-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(59, 130, 246, 0.6), transparent);
}

/* Pricing */
.plans {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr));
  gap: 20px;
}

.plan {
  display: flex;
  flex-direction: column;
  gap: 18px;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.plan:hover {
  transform: translateY(-3px);
  border-color: rgba(59, 130, 246, 0.35);
}

.plan.featured {
  border-color: rgba(16, 185, 129, 0.45);
  box-shadow: 0 0 40px rgba(16, 185, 129, 0.15);
}

.plan.featured::before {
  background: linear-gradient(90deg, transparent, rgba(16, 185, 129, 0.8), transparent);
}

.plan-tag {
  position: absolute;
  top: 16px;
  right: 16px;
  font-size: 0.72rem;
  font-weight: 600;
  color: #6ee7b7;
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.4);
  padding: 3px 10px;
  border-radius: 9999px;
}

.plan-name {
  color: var(--text-muted);
  font-size: 0.9rem;
  font-weight: 500;
}

.plan-days {
  font-size: 1.6rem;
  font-weight: 700;
}

.plan-price {
  display: flex;
  align-items: baseline;
  gap: 6px;
}

.plan-price .amount {
  font-size: 2.6rem;
  font-weight: 700;
  line-height: 1;
}

.plan-price .per {
  color: var(--text-muted);
  font-size: 0.85rem;
}

.plan ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
  color: #cbd5e1;
  font-size: 0.9rem;
  flex: 1;
}

.plan li::before {
  content: "✓";
  color: var(--emerald);
  font-weight: 700;
  margin-right: 8px;
}

/* How it works */
.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr));
  gap: 16px;
}

.step {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 16px 18px;
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.02);
}

.step-num {
  flex: none;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: 0.9rem;
  color: #93c5fd;
  background: rgba(59, 130, 246, 0.15);
  border: 1px solid rgba(59, 130, 246, 0.4);
}

.step strong { font-weight: 600; }

.step p {
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-top: 2px;
}

.app-footer { line-height: 1.7; }

/* Buttons */
.btn {
  width: 100%;
  padding: 14px 20px;
  background: var(--primary-gradient);
  color: #fff;
  border: none;
  border-radius: var(--radius-md);
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.25s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  box-shadow: 0 4px 18px rgba(37, 99, 235, 0.3);
  text-decoration: none;
}

.btn:hover { filter: brightness(1.1); transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn:disabled { opacity: 0.55; cursor: wait; transform: none; }
.btn:focus-visible { outline: 2px solid #93c5fd; outline-offset: 3px; }

.btn-ghost {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-glass);
  color: var(--text-muted);
  box-shadow: none;
}

/* Notices */
.notice {
  border-radius: var(--radius-md);
  padding: 12px 16px;
  font-size: 0.9rem;
  border: 1px solid;
}

.notice.warn {
  background: rgba(245, 158, 11, 0.12);
  border-color: rgba(245, 158, 11, 0.4);
  color: #fcd34d;
}

.notice.error {
  background: rgba(244, 63, 94, 0.12);
  border-color: rgba(244, 63, 94, 0.4);
  color: #fda4af;
}

.notice.ok {
  background: rgba(16, 185, 129, 0.12);
  border-color: rgba(16, 185, 129, 0.4);
  color: #6ee7b7;
}

/* Key result */
.key-box {
  background: #060911;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  color: #38bdf8;
  font-size: 0.92rem;
  line-height: 1.6;
  word-break: break-all;
  user-select: all;
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
}

.info-cell {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
}

.info-cell .lbl {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-bottom: 4px;
}

.info-cell .val {
  font-size: 0.95rem;
  font-weight: 600;
}

.stack { display: flex; flex-direction: column; gap: 16px; }

.spinner {
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

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

.app-footer {
  text-align: center;
  font-size: 0.8rem;
  color: #64748b;
}

.app-footer a { color: #94a3b8; }

[hidden] { display: none !important; }
