:root {
  --bg: #f5f5f7;
  --surface: #ffffff;
  --card: #fafafa;
  --border: #e6e6e9;

  --text: #111111;
  --muted: #6b6b6f;

  --primary: #1f2937;
  --primary-hover: #111827;

  --radius: 14px;
}

/* ===============================
   Base
================================= */

body {
  margin: 0;
  font-family: Inter, system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
}

/* ===============================
   Topbar
================================= */

.topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;

  height: 56px;
  background: var(--surface);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  border-bottom: 1px solid var(--border);

  z-index: 1000;
}


.brand img {
  display: block;
}

.secure {
  font-size: 13px;
  color: var(--muted);
}

/* ===============================
   Main Content
================================= */

.content {
  padding: 76px 16px 120px; /* 56px header + 20px breathing */
  max-width: 640px;
  margin: 0 auto;
}


h1 {
  font-size: 26px;
  margin: 0 0 8px;
}

.subtitle {
  font-size: 15px;
  color: var(--muted);
  margin-bottom: 24px;
  line-height: 1.6;
}

/* ===============================
   Cards
================================= */

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
}

.plan-card {
  margin-bottom: 28px;
}

.plan-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--muted);
  margin-bottom: 6px;
}

.plan-name {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 12px;
}

.plan-price {
  font-size: 24px;
  font-weight: 700;
}

.plan-validity {
  font-size: 13px;
  color: var(--muted);
  margin-top: 4px;
}

/* ===============================
   Business Details
================================= */

.section-title {
  font-size: 15px;
  font-weight: 600;
  margin: 28px 0 14px;
}

.detail-item {
  margin-bottom: 18px;
}

.detail-label {
  font-size: 11px;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 4px;
}

.detail-value {
  font-size: 15px;
  font-weight: 500;
}

/* ===============================
   Consent Box
================================= */

.consent-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 24px;
  font-size: 14px;
  line-height: 1.6;
}

/* ===============================
   Action Bar
================================= */

.action-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 12px 16px;

  z-index: 1000;
}

.btn-primary {
  width: 100%;
  height: 52px;
  border-radius: 12px;
  border: none;
  background: var(--primary);
  color: white;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: 0.2s ease;
}

.btn-primary:active {
  background: var(--primary-hover);
}

.btn-primary:disabled {
  opacity: 0.7;
  cursor: not-allowed;
}

.security-note {
  font-size: 11px;
  color: var(--muted);
  text-align: center;
  margin-top: 6px;
}

/* ===============================
   Utilities
================================= */

.hidden {
  display: none;
}

.error-message {
  color: #b00020;
  margin: 16px 0;
  font-size: 14px;
}

.spinner {
  width: 24px;
  height: 24px;
  margin: 0 auto 12px;
  border: 3px solid #ddd;
  border-top-color: #999;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

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

/* ===============================
   Success Page
================================= */

.success-content {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - 120px);
}

.success-card {
  text-align: center;
  padding: 36px 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.success-icon {
  width: 80px;
  height: 80px;
  margin: 0 auto 24px;

  border-radius: 50%;
  background: linear-gradient(135deg, #1e7f4f, #34c38f);
  color: white;

  font-size: 34px;
  font-weight: 700;

  display: flex;
  align-items: center;
  justify-content: center;
}

.success-title {
  font-size: 22px;
  margin-bottom: 10px;
}

.success-subtitle {
  font-size: 15px;
  color: var(--muted);
  line-height: 1.6;
  margin-bottom: 24px;
}

.success-divider {
  height: 1px;
  background: var(--border);
  margin: 24px 0;
}

.success-note {
  font-size: 13px;
  color: var(--muted);
}

.success-btn {
  margin-top: 28px;
}

.terms-scroll {
  max-height: 55vh;
  overflow-y: auto;
  padding: 20px;
  margin-top: 16px;
  line-height: 1.6;
}

.btn-spinner {
  width:16px;
  height:16px;
  border:2px solid rgba(255,255,255,0.5);
  border-top:2px solid white;
  border-radius:50%;
  display:inline-block;
  animation:spin 0.8s linear infinite;
  margin-right:8px;
}



/* ===============================
   Terms Page Improvements
================================= */

.terms-page h1{
  font-size:24px;
  margin-bottom:6px;
}

.terms-container{
  background: var(--surface);
  border:1px solid var(--border);
  border-radius: var(--radius);
  padding:24px;
  margin-top:16px;

  max-height:55vh;
  overflow-y:auto;

  line-height:1.65;
  font-size:15px;
}

.terms-container h2{
  font-size:18px;
  font-weight:600;
  margin-top:20px;
}

.terms-container p{
  margin:10px 0;
}

.terms-container ul{
  margin-left:18px;
}

.terms-container li{
  margin-bottom:6px;
}

.btn-primary{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:8px;
}

.terms-scroll{
  scrollbar-width: thin;
}

.terms-scroll::-webkit-scrollbar{
  width:6px;
}

.terms-scroll::-webkit-scrollbar-thumb{
  background:#d1d5db;
  border-radius:6px;
}