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

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
  background: #F2F4F8;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding: 32px 16px 64px;
  color: #1A1A1A;
}

/* ─── Page card ─────────────────────────────────── */
.payment-card {
  background: #fff;
  border-radius: 20px;
  padding: 32px 28px;
  width: 100%;
  max-width: 560px;
  box-shadow: 0 2px 16px rgba(0,0,0,.08);
}

h1 {
  font-size: 26px;
  font-weight: 700;
  margin-bottom: 20px;
  letter-spacing: -.3px;
}

/* ─── Product block ──────────────────────────────── */
.product-block {
  border: 1.5px solid #E8ECF0;
  border-radius: 14px;
  padding: 16px 18px;
  margin-bottom: 24px;
}

.product-name {
  font-size: 14px;
  color: #444;
  line-height: 1.5;
  margin-bottom: 10px;
}

.price-badge {
  display: inline-block;
  background: #F0F2F5;
  border-radius: 8px;
  padding: 5px 12px;
  font-size: 14px;
  font-weight: 600;
  color: #1A1A1A;
}

/* ─── Section title ──────────────────────────────── */
.section-title {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 12px;
  color: #1A1A1A;
}

/* ─── Payment methods grid ───────────────────────── */
.methods-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 20px;
}

.method-card {
  background: #fff;
  border: 1.5px solid #E0E4EB;
  border-radius: 14px;
  padding: 14px 12px;
  cursor: pointer;
  text-align: left;
  transition: border-color .18s, background .18s, box-shadow .18s;
  position: relative;
  min-height: 108px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.method-card:hover {
  border-color: #A0B4D0;
  box-shadow: 0 2px 8px rgba(0,82,204,.08);
}

.method-card.active {
  border-color: #0052CC;
  background: #F0F5FF;
  box-shadow: 0 2px 12px rgba(0,82,204,.12);
}

.method-icon {
  width: 28px;
  height: 28px;
  flex-shrink: 0;
}

.method-label {
  font-size: 12.5px;
  color: #444;
  line-height: 1.35;
  flex: 1;
}

.method-price {
  font-size: 13px;
  font-weight: 700;
  color: #1A1A1A;
}

.method-sub {
  font-size: 11.5px;
  color: #0052CC;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 3px;
}

/* ─── Detail panels ──────────────────────────────── */
.detail-panel {
  display: none;
  margin-bottom: 20px;
  animation: fadeIn .2s ease;
}

.detail-panel.visible { display: block; }

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(4px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* installment */
.installment-tagline {
  font-size: 13.5px;
  color: #444;
  margin-bottom: 12px;
  line-height: 1.5;
}

.installment-box {
  background: #F5F7FA;
  border-radius: 12px;
  padding: 16px;
  margin-bottom: 12px;
}

.installment-box-title {
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 10px;
}

.progress-track {
  height: 6px;
  background: #DDE2EA;
  border-radius: 4px;
  margin-bottom: 8px;
  overflow: hidden;
}

.progress-fill {
  width: 6%;
  height: 100%;
  background: #22C55E;
  border-radius: 4px;
}

.installment-labels {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: #6B7280;
}

.installment-labels strong {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: #1A1A1A;
}

/* months selector */
.months-selector {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}

.months-btn {
  border: 1.5px solid #DDE2EA;
  border-radius: 8px;
  padding: 6px 14px;
  font-size: 13px;
  cursor: pointer;
  background: #fff;
  color: #444;
  transition: border-color .15s, background .15s;
}

.months-btn:hover { border-color: #A0B4D0; }

.months-btn.active {
  border-color: #0052CC;
  background: #F0F5FF;
  color: #0052CC;
  font-weight: 600;
}

.terms-note {
  font-size: 12px;
  color: #6B7280;
  line-height: 1.5;
}

.terms-note a { color: #0052CC; text-decoration: none; }
.terms-note a:hover { text-decoration: underline; }

/* dolyame */
.dolyame-steps {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
}

.dolyame-step {
  flex: 1;
  background: #F5F7FA;
  border-radius: 10px;
  padding: 10px 8px;
  text-align: center;
}

.dolyame-step .step-amount {
  font-size: 13px;
  font-weight: 700;
  color: #1A1A1A;
  margin-bottom: 2px;
}

.dolyame-step .step-date {
  font-size: 11px;
  color: #6B7280;
}

.dolyame-note {
  font-size: 12px;
  color: #6B7280;
  line-height: 1.5;
}

/* subscription */
.sub-price {
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 4px;
}

.sub-price span {
  font-size: 14px;
  font-weight: 400;
  color: #6B7280;
}

.sub-features {
  list-style: none;
  margin: 12px 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.sub-features li {
  font-size: 13px;
  color: #444;
  display: flex;
  align-items: center;
  gap: 8px;
}

.sub-features li::before {
  content: "";
  width: 18px;
  height: 18px;
  background: #22C55E;
  border-radius: 50%;
  flex-shrink: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath fill='%23fff' d='M6.5 11.5L3 8l1-1 2.5 2.5 5-5 1 1z'/%3E%3C/svg%3E");
  background-size: cover;
}

/* ─── Consent ────────────────────────────────────── */
.consent-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 18px;
  cursor: pointer;
}

.consent-row input[type="checkbox"] {
  width: 18px;
  height: 18px;
  border: 1.5px solid #C0C8D4;
  border-radius: 4px;
  margin-top: 1px;
  cursor: pointer;
  accent-color: #0052CC;
  flex-shrink: 0;
}

.consent-row label {
  font-size: 13px;
  color: #444;
  line-height: 1.5;
  cursor: pointer;
}

.consent-row label a { color: #0052CC; text-decoration: none; }
.consent-row label a:hover { text-decoration: underline; }

/* ─── CTA button ─────────────────────────────────── */
.cta-button {
  width: 100%;
  padding: 16px;
  background: #0052CC;
  color: #fff;
  border: none;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: background .18s, transform .1s;
  letter-spacing: .1px;
}

.cta-button:hover { background: #0044AA; }
.cta-button:active { transform: scale(.99); }
.cta-button:disabled {
  background: #C0C8D4;
  cursor: not-allowed;
  transform: none;
}

.cta-button.loading::after {
  content: " ·· ";
  animation: dots 1s infinite;
}

@keyframes dots {
  0%   { content: " · "; }
  50%  { content: " ·· "; }
  100% { content: " ··· "; }
}

/* ─── Error message ──────────────────────────────── */
.error-msg {
  display: none;
  background: #FFF0F0;
  border: 1px solid #FFC5C5;
  border-radius: 8px;
  padding: 10px 14px;
  font-size: 13px;
  color: #CC0000;
  margin-bottom: 14px;
}

.error-msg.visible { display: block; }

/* ─── Success / Fail pages ───────────────────────── */
.status-page {
  text-align: center;
  padding: 48px 28px;
}

.status-icon {
  font-size: 56px;
  margin-bottom: 16px;
}

.status-page h2 {
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 8px;
}

.status-page p {
  font-size: 14px;
  color: #6B7280;
  margin-bottom: 24px;
}

.back-link {
  display: inline-block;
  background: #0052CC;
  color: #fff;
  text-decoration: none;
  padding: 12px 28px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 600;
}

/* ─── Responsive ─────────────────────────────────── */
@media (max-width: 500px) {
  body { padding: 16px 12px 48px; }
  .payment-card { padding: 24px 16px; }
  .methods-grid { grid-template-columns: 1fr 1fr; }
  .dolyame-steps { flex-wrap: wrap; }
}

@media (max-width: 360px) {
  .methods-grid { grid-template-columns: 1fr; }
}

/* ─── Footer ─────────────────────────────────────── */
.site-footer {
  text-align: center;
  font-size: 12px;
  color: #6B7280;
  margin-top: 24px;
  width: 100%;
}

.site-footer a {
  color: #0052CC;
  text-decoration: none;
  display: inline-block;
  margin-bottom: 6px;
}

.site-footer a:hover {
  text-decoration: underline;
}

