/* ─── Reset & Base ──────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --primary:        #4f46e5;
  --primary-dark:   #3730a3;
  --phonepe:        #5f259f;
  --phonepe-dark:   #4a1a80;
  --accent:         #f59e0b;
  --green:          #16a34a;
  --text:           #1e293b;
  --muted:          #64748b;
  --border:         #e2e8f0;
  --bg:             #f8fafc;
  --white:          #ffffff;
  --bump-bg:        #fffbeb;
  --bump-border:    #f59e0b;
  --bump-sel-bg:    #fef3c7;
  --radius:         12px;
  --shadow:         0 1px 3px rgba(0,0,0,.07), 0 4px 16px rgba(0,0,0,.06);
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.container {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 20px;
}

/* ─── Header ────────────────────────────────────────────────────────────────── */
.site-header {
  background: var(--white);
  border-bottom: 1px solid var(--border);
  padding: 14px 0;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  height: 38px;
  object-fit: contain;
}

.secure-badge {
  font-size: 13px;
  color: var(--muted);
}

/* ─── Layout ────────────────────────────────────────────────────────────────── */
.checkout-wrapper {
  padding: 36px 0 64px;
}

.checkout-grid {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 28px;
  align-items: start;
}

/* ─── Card ──────────────────────────────────────────────────────────────────── */
.card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow);
  margin-bottom: 22px;
}

/* ─── Product Card ──────────────────────────────────────────────────────────── */
.product-card {
  display: flex;
  gap: 22px;
}

.product-image-wrap {
  flex-shrink: 0;
}

.product-img {
  width: 110px;
  height: 150px;
  object-fit: cover;
  border-radius: 8px;
  display: block;
}

.badge {
  display: inline-block;
  background: var(--accent);
  color: #78350f;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: .5px;
  margin-bottom: 10px;
}

.product-title {
  font-size: 21px;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 8px;
  line-height: 1.3;
}

.product-desc {
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 14px;
}

.feature-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.feature-list li {
  font-size: 14px;
  color: var(--text);
}

/* ─── Form ──────────────────────────────────────────────────────────────────── */
.form-section { margin-bottom: 22px; }

.section-title {
  font-size: 17px;
  font-weight: 700;
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.optional-tag {
  font-size: 12px;
  font-weight: 500;
  background: #ede9fe;
  color: #4338ca;
  padding: 3px 10px;
  border-radius: 12px;
}

.req { color: #ef4444; }

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.form-group { margin-bottom: 14px; }

label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 6px;
}

input[type="text"],
input[type="email"],
input[type="tel"] {
  width: 100%;
  padding: 11px 14px;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  font-size: 15px;
  color: var(--text);
  background: var(--white);
  transition: border-color .2s, box-shadow .2s;
  outline: none;
  appearance: none;
  -webkit-appearance: none;
}

input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(79, 70, 229, .12);
}

/* ─── Bumps ─────────────────────────────────────────────────────────────────── */
.bumps-section { margin-bottom: 0; }

.bump-card {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  background: var(--bump-bg);
  border: 2px dashed var(--bump-border);
  border-radius: var(--radius);
  padding: 18px;
  margin-bottom: 14px;
  cursor: pointer;
  position: relative;
  transition: background .18s, border-color .18s, box-shadow .18s;
  user-select: none;
}

.bump-card:hover {
  box-shadow: 0 4px 18px rgba(245, 158, 11, .18);
}

.bump-card.selected {
  background: var(--bump-sel-bg);
  border-style: solid;
  border-color: #d97706;
  box-shadow: 0 4px 18px rgba(245, 158, 11, .25);
}

/* visually hide the native checkbox */
.bump-checkbox {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
  pointer-events: none;
}

.bump-tick {
  flex-shrink: 0;
  width: 26px;
  height: 26px;
  border: 2.5px solid var(--bump-border);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  color: transparent;
  background: var(--white);
  margin-top: 2px;
  transition: background .18s, border-color .18s, color .18s;
}

.bump-card.selected .bump-tick {
  background: var(--green);
  border-color: var(--green);
  color: var(--white);
}

.bump-body { flex: 1; }

.bump-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 5px;
  gap: 8px;
}

.bump-cta {
  font-size: 12px;
  font-weight: 700;
  color: #92400e;
  text-transform: uppercase;
  letter-spacing: .3px;
}

.bump-price {
  font-size: 15px;
  font-weight: 800;
  color: var(--green);
  white-space: nowrap;
}

.bump-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 5px;
}

.bump-desc {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.5;
}

/* ─── Order Summary ─────────────────────────────────────────────────────────── */
.sticky-card {
  position: sticky;
  top: 24px;
}

.summary-title {
  font-size: 17px;
  font-weight: 700;
  margin-bottom: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border);
}

.summary-item {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 8px;
  padding: 7px 0;
}

.item-name {
  font-size: 14px;
  color: var(--text);
  flex: 1;
  line-height: 1.4;
}

.item-price {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  white-space: nowrap;
}

/* Bump lines in summary */
.bump-summary-line .item-name {
  font-size: 13px;
  color: var(--muted);
}

.bump-summary-line .item-price {
  font-size: 13px;
  color: var(--green);
  font-weight: 600;
}

.summary-divider {
  height: 1px;
  background: var(--border);
  margin: 10px 0;
}

.summary-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 18px;
}

.total-label {
  font-size: 15px;
  font-weight: 700;
}

.total-amount {
  font-size: 26px;
  font-weight: 800;
  color: var(--primary);
  transition: color .2s;
}

/* ─── Guarantee ─────────────────────────────────────────────────────────────── */
.guarantee {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  background: #f0fdf4;
  border: 1px solid #86efac;
  border-radius: 8px;
  padding: 14px;
  margin-bottom: 18px;
}

.guarantee-icon { font-size: 22px; flex-shrink: 0; line-height: 1; margin-top: 2px; }

.guarantee strong {
  display: block;
  font-size: 13px;
  color: #166534;
  margin-bottom: 2px;
}

.guarantee small {
  font-size: 12px;
  color: #15803d;
}

/* ─── Error ─────────────────────────────────────────────────────────────────── */
.error-msg {
  background: #fef2f2;
  border: 1px solid #fca5a5;
  color: #dc2626;
  padding: 11px 14px;
  border-radius: 8px;
  font-size: 13px;
  margin-bottom: 14px;
}

/* ─── Pay Button ────────────────────────────────────────────────────────────── */
.pay-btn {
  width: 100%;
  background: var(--phonepe);
  color: var(--white);
  border: none;
  border-radius: 10px;
  padding: 15px 20px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: background .2s, box-shadow .2s, transform .1s;
  box-shadow: 0 4px 16px rgba(95, 37, 159, .3);
  margin-bottom: 12px;
  letter-spacing: .2px;
}

.pay-btn:hover {
  background: var(--phonepe-dark);
  box-shadow: 0 6px 22px rgba(95, 37, 159, .38);
}

.pay-btn:active { transform: translateY(1px); }

.pay-btn:disabled {
  opacity: .65;
  cursor: not-allowed;
  transform: none;
}

/* ─── Secure info ───────────────────────────────────────────────────────────── */
.secure-info {
  display: flex;
  justify-content: center;
  gap: 16px;
  font-size: 11px;
  color: var(--muted);
}

/* ─── Footer ────────────────────────────────────────────────────────────────── */
.site-footer {
  background: var(--white);
  border-top: 1px solid var(--border);
  padding: 20px 0;
  text-align: center;
}

.site-footer p { font-size: 13px; color: var(--muted); }

.site-footer a {
  color: var(--muted);
  text-decoration: none;
  margin: 0 4px;
}

.site-footer a:hover { color: var(--text); }

/* ─── Responsive ────────────────────────────────────────────────────────────── */
@media (max-width: 800px) {
  .checkout-grid {
    grid-template-columns: 1fr;
  }

  /* Show summary above the form on mobile */
  .checkout-right { order: -1; }

  .sticky-card { position: static; }

  .product-card { flex-direction: column; }

  .product-img { width: 100%; height: 200px; object-fit: cover; }

  .form-row { grid-template-columns: 1fr; }

  .bump-header { flex-direction: column; align-items: flex-start; gap: 4px; }
}
