/* ==========================================================================
   Credit card bill payment page (avhishek.in/pay-credit-card-bill)
   Extends support-page.css: same hero, picker, sticky search and bank cards.
   Adds the safety strip, payment method cards and the BBPS explainer.
   ========================================================================== */

.py {
  --py-fast: #15803d;
  --py-mid: #a16207;
  --py-slow: #c2410c;
  --py-caution-bg: color-mix(in srgb, #fc6e20 9%, var(--surface));
  --py-caution-line: color-mix(in srgb, #fc6e20 40%, var(--line));
  --py-caution-ink: #9a3412;
}
html[data-theme="dark"] .py {
  --py-fast: #4ade80;
  --py-mid: #facc15;
  --py-slow: #ff9a5c;
  --py-caution-ink: #ffb27f;
}

/* ---------- Before you pay ---------- */
.py-safety {
  margin-top: 56px;
  padding-top: 32px;
  border-top: 1px solid var(--line);
}
.py-safety-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 16px; }
.py-safety-head h2,
.py-bbps h2 {
  font-size: clamp(1.375rem, 1.2rem + 0.7vw, 1.75rem);
  font-weight: 650;
  line-height: 1.15;
  letter-spacing: -0.025em;
}
.py-safety-head p { color: var(--muted); font-size: 0.9375rem; line-height: 1.5; }
.py-tips {
  display: grid;
  margin-top: 18px !important;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: var(--surface);
  overflow: hidden;
}
.py-tip {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr);
  gap: 4px 12px;
  align-items: start;
  align-content: start;
  padding: 14px 16px;
}
.py-tip + .py-tip { border-top: 1px solid var(--line); }
.py-tip-icon {
  grid-row: span 2;
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 10px;
  background: var(--surface-muted);
  color: var(--text);
}
.py-tip.is-key .py-tip-icon { background: #fc6e20; color: #1a1206; }
.py-tip > div { display: contents; }
.py-tip h3 { align-self: center; min-height: 32px; display: flex; align-items: center; font-size: 0.9375rem; font-weight: 650; line-height: 1.3; }
.py-tip p { grid-column: 2; color: var(--muted); font-size: 0.875rem; line-height: 1.5; text-wrap: pretty; }
.py-safety > .py-verify { margin-top: 12px !important; padding: 12px 14px; border-radius: 14px; border: 1px solid var(--py-caution-line); background: var(--py-caution-bg); color: var(--text); font-size: 0.875rem; }
.py-safety > .py-verify svg { color: var(--py-caution-ink); }

/* ---------- Notes ---------- */
.sp-bank-body.py-body { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; }
.py-callout,
.py-note,
.py-verify {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 8px;
  align-items: start;
  font-size: 0.875rem;
  line-height: 1.5;
  text-wrap: pretty;
}
.py-callout svg,
.py-note svg,
.py-verify svg { margin-top: 2px; }
.py-callout { padding: 12px 14px; border-radius: 14px; background: var(--surface-muted); }
.py-callout.is-caution { border: 1px solid var(--py-caution-line); background: var(--py-caution-bg); color: var(--text); font-weight: 500; }
.py-callout.is-caution svg { color: var(--py-caution-ink); }
.py-note { color: var(--muted); }
.py-note svg { color: var(--muted); }
.py-verify { color: var(--muted); font-size: 0.8125rem; }
.py-verify svg { color: var(--py-caution-ink); }
.py-older { color: var(--muted); font-size: 0.8125rem; line-height: 1.5; }

/* ---------- Methods with details ---------- */
.py-methods { display: grid; gap: 12px; }
.py-method {
  display: grid;
  gap: 10px;
  align-content: start;
  min-width: 0;
  padding: 14px 16px 16px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: var(--surface-soft);
}
.py-method.is-match,
.py-way.is-match { border-color: color-mix(in srgb, #fc6e20 60%, var(--line)); }
.py-method-head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px; }
.py-method-head .py-time { margin-inline-start: auto; }
.py-kind {
  display: grid;
  place-items: center;
  flex: none;
  width: 30px;
  height: 30px;
  border-radius: 9px;
  background: var(--surface);
  border: 1px solid var(--line);
  color: var(--text);
}
.py-kind-upi .py-kind,
.py-kind-imps .py-kind,
.py-kind-neft .py-kind { background: var(--text); border-color: transparent; color: var(--page); }
.py-method-title { font-size: 1rem; font-weight: 650; line-height: 1.3; letter-spacing: -0.01em; }
.py-how { color: var(--muted); font-size: 0.875rem; line-height: 1.5; text-wrap: pretty; }

.py-fields { display: grid; margin: 0; border-top: 1px solid var(--line); }
.py-field {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 2px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}
.py-field dt { color: var(--muted); font-size: 0.75rem; font-weight: 500; line-height: 1.35; }
.py-field dd { margin: 0; min-width: 0; font-size: 0.9375rem; line-height: 1.45; }
.py-value-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-block: -8px; }
.py-value { font-weight: 650; overflow-wrap: anywhere; }
.py-mono { font-family: var(--site-mono); font-size: 0.9375em; letter-spacing: 0.02em; }
.py-text { font-weight: 500; text-wrap: pretty; }
.py-pattern { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; padding-block: 2px; }
.py-lit { font-family: var(--site-mono); font-size: 0.9375rem; font-weight: 650; }
.py-ph {
  padding: 2px 9px;
  border-radius: 8px;
  border: 1px dashed var(--line-strong);
  background: var(--surface-muted);
  color: var(--muted);
  font-size: 0.8125rem;
  font-weight: 500;
  line-height: 1.5;
  white-space: nowrap;
}
.py-example { display: block; margin-top: 4px; color: var(--muted); font-size: 0.8125rem; line-height: 1.45; overflow-wrap: anywhere; }
.py-example .py-mono { color: var(--text); }
.py-keys { display: grid; gap: 6px; margin-top: 10px !important; padding-top: 10px; border-top: 1px dashed var(--line); }
.py-keys li { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; color: var(--muted); font-size: 0.8125rem; line-height: 1.45; text-wrap: pretty; }
.py-keys .py-ph { flex: none; padding: 0 7px; font-size: 0.75rem; }
.py-method .py-source a { overflow-wrap: anywhere; }

.py-time {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  width: fit-content;
  max-width: 100%;
  padding: 3px 10px 3px 8px;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.8125rem;
  font-weight: 500;
  line-height: 1.4;
}
.py-time svg { flex: none; }
.py-time.is-fast { color: var(--text); }
.py-time.is-fast svg { color: var(--py-fast); }
.py-time.is-mid svg { color: var(--py-mid); }
.py-time.is-slow svg { color: var(--py-slow); }

/* ---------- Other ways to pay: one quiet list ---------- */
.py-ways { border: 1px solid var(--line); border-radius: 18px; background: var(--surface-soft); overflow: hidden; }
.py-way {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr);
  gap: 4px 12px;
  align-items: start;
  padding: 12px 16px;
}
.py-way + .py-way { border-top: 1px solid var(--line); }
.py-way .py-time { grid-column: 2; margin-top: 2px; }
.py-way-main { display: grid; gap: 4px; min-width: 0; }
.py-way-main .py-method-title { font-size: 0.9375rem; }
.py-way-main .py-source a { overflow-wrap: anywhere; }

.py-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 4px 20px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}
.py-source { color: var(--muted); font-size: 0.8125rem; line-height: 1.6; }
.py-source a,
.py-help,
.py-bbps a,
.py-fine a {
  color: var(--text);
  font-weight: 500;
  text-decoration: underline;
  text-decoration-color: #fc6e20;
  text-decoration-thickness: 1.5px;
  text-underline-offset: 3px;
}
.py-source a { display: inline-flex; align-items: center; gap: 2px; margin-inline-end: 10px; }
.py-help { display: inline-flex; align-items: center; min-height: 40px; font-size: 0.875rem; }

/* ---------- Bank row: meta, BBPS chip, search preview ---------- */
.sp-bank-name .py-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; }
.sp-bank-name .py-live {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 1px 9px 1px 7px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface-soft);
  color: var(--text);
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1.5;
}
.sp-bank-name .py-live::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #16a34a; }
html[data-theme="dark"] .sp-bank-name .py-live::before { background: #4ade80; }
.sp-bank-name .py-preview {
  font-family: var(--site-mono);
  font-size: 0.8125rem;
  color: var(--text);
  line-height: 1.45;
  overflow-wrap: anywhere;
}

/* ---------- Live on BBPS (inside a bank) ---------- */
.py-live-row { display: grid; gap: 8px; padding: 12px 14px; border-radius: 14px; background: var(--surface-muted); }
.py-live-title { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 8px; font-size: 0.875rem; line-height: 1.4; }
.py-live-title strong { font-weight: 650; }
.py-live-title > span:last-child { color: var(--muted); }
.py-live-icon { display: grid; place-items: center; width: 22px; height: 22px; border-radius: 7px; background: #fc6e20; color: #1a1206; }
.py-live-icon svg { width: 14px; height: 14px; }
.py-billers { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; list-style: none; }
.py-biller {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 2px 8px;
  max-width: 100%;
  padding: 4px 11px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--surface);
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.4;
}
.py-biller small { color: var(--muted); font-size: 0.75rem; font-weight: 500; }

/* ---------- Method filter chips ---------- */
.py-filters { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 12px 0 18px; }
.py-filters-label { color: var(--muted); font-size: 0.875rem; margin-inline-end: 4px; }
.py-fchip {
  min-height: 36px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: var(--surface);
  color: var(--text);
  font: inherit;
  font-size: 0.8125rem;
  font-weight: 600;
  line-height: 1.2;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: background 160ms var(--ease), border-color 160ms var(--ease), color 160ms var(--ease);
}
.py-fchip:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.py-fchip[aria-pressed="true"] { background: var(--text); border-color: var(--text); color: var(--page); }
@media (hover: hover) { .py-fchip:not([aria-pressed="true"]):hover { background: var(--surface-soft); } }

/* ---------- Sources (page bottom) ---------- */
.py-sources { max-width: 72ch; margin-top: 40px; border: 1px solid var(--line); border-radius: 18px; background: var(--surface); }
.py-sources summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 52px; padding: 12px 16px; font-size: 0.9375rem; font-weight: 650; cursor: pointer; list-style: none; -webkit-tap-highlight-color: transparent; }
.py-sources summary::-webkit-details-marker { display: none; }
.py-sources summary:focus-visible { outline: 2px solid var(--focus); outline-offset: -2px; border-radius: 18px; }
.py-sources summary span { color: var(--muted); font-size: 0.8125rem; font-weight: 500; }
.py-sources .sp-chevron { flex: none; transition: rotate 200ms var(--ease); }
.py-sources[open] .sp-chevron { rotate: 180deg; }
.py-sources ul { margin: 0; padding: 0 16px 6px; list-style: none; border-top: 1px solid var(--line); }
.py-sources li { display: grid; gap: 4px 16px; padding: 12px 0; font-size: 0.875rem; line-height: 1.5; }
.py-sources li + li { border-top: 1px solid var(--line); }
.py-sources li > span { display: flex; flex-wrap: wrap; gap: 2px 14px; }
.py-sources a { display: inline-flex; align-items: center; gap: 2px; color: var(--muted); text-decoration: underline; text-decoration-color: #fc6e20; text-decoration-thickness: 1.5px; text-underline-offset: 3px; overflow-wrap: anywhere; }
@media (hover: hover) { .py-sources a:hover { color: var(--text); } }
@media (min-width: 720px) { .py-sources li { grid-template-columns: 12em minmax(0, 1fr); } }

/* ---------- BBPS section ---------- */
.py-bbps { display: grid; gap: 12px; max-width: 72ch; margin-top: 56px; }
.py-bbps p { color: var(--muted); font-size: 0.9375rem; line-height: 1.6; text-wrap: pretty; }
.py-bbps strong { color: var(--text); font-weight: 600; }
.py-bbps h3 { margin-top: 8px; font-size: 0.9375rem; font-weight: 650; }
.py-fine { max-width: 70ch; margin-top: 32px !important; color: var(--muted); font-size: 0.8125rem; line-height: 1.6; }
/* Separate the safety disclaimer from the channel follow panel. */
.py .py-fine + .py-follow { margin-block-start: 32px; }

/* ---------- Layout ---------- */
@media (min-width: 720px) {
  .py-tips { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .py-tip + .py-tip { border-top: 0; }
  .py-tip:nth-child(n + 3) { border-top: 1px solid var(--line); }
  .py-tip:nth-child(even) { border-inline-start: 1px solid var(--line); }
  .py-field { grid-template-columns: 8.5em minmax(0, 1fr); align-items: center; gap: 12px; }
  .py-way { grid-template-columns: 30px minmax(0, 1fr) auto; align-items: center; }
  .py-way .py-time { grid-column: 3; margin-top: 0; }
}
@media (min-width: 900px) {
  .py-methods { grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; }
  .sp-bank-body.py-body { padding: 20px 22px 18px; }
}
@media (min-width: 1100px) {
  .py-tips { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .py-tip { grid-template-columns: minmax(0, 1fr); }
  .py-tip:nth-child(n) { border-top: 0; border-inline-start: 1px solid var(--line); }
  .py-tip:first-child { border-inline-start: 0; }
  .py-tip-icon { grid-row: auto; }
  .py-tip > div { display: block; }
  .py-tip h3 { min-height: 0; margin-top: 4px; }
  .py-tip p { margin-top: 4px; }
}
@media (max-width: 640px) {
  .py-safety { margin-top: 40px; padding-top: 28px; }
  .py-method { padding: 12px 12px 14px; }
  .py-way { padding: 12px; }
  .py-bbps { margin-top: 48px; }
  .py-filters-label { flex-basis: 100%; }
}
@media print {
  .py-copy, .py-help, .py-filters { display: none; }
}

/* Hero button: the UPI ID generator (glass-buttons.js adds the glass layers) */
.py-hero-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  margin-top: 20px;
  padding-inline: 20px;
  border-radius: 999px;
  background: var(--text);
  color: var(--page);
  font-size: 15px;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
}
.py-hero-btn svg { flex: none; }
