/* impact.css: impact.html (js/impact-page.js). Class prefix im-.
   Builds on css/pages.css tokens and css/help-center.css (.help-page tokens, .hc-btn, .hc-h2), light and dark:
   navy #14324F, accent #F2B33D, rounded cards. Phone first: one column under 600px, no horizontal scroll. */

.im-page { --im-line: #14324F; --im-small: #8A97A6; --im-tint: #FFF6E5; --im-tint-border: #F3D9A4; }
[data-theme="dark"] .im-page { --im-line: #F2B33D; --im-small: #7D8EA0; --im-tint: rgba(242,179,61,.10); --im-tint-border: rgba(242,179,61,.38); }
.im-page main { padding-bottom: 32px; }
.im-page main :focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }

.im-hero { background: var(--surface); border-bottom: 1px solid var(--border); padding: 40px 0 28px; margin-bottom: 24px; }
.im-hero h1 { margin: 6px 0 10px; font-size: 2rem; font-weight: 800; color: var(--ink); line-height: 1.15; }
.im-lead { margin: 0; max-width: 760px; color: var(--hc-text-2); font-size: 1.0625rem; line-height: 1.55; }
.im-facts { list-style: none; margin: 18px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 22px; }
.im-facts li { display: flex; align-items: center; gap: 8px; font-size: .9375rem; font-weight: 600; color: var(--ink); }
.im-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--gold); flex: none; }

.im-status { margin: 0 0 18px; color: var(--muted); }
.im-status:empty { display: none; }
.im-status.is-err { padding: 14px 16px; border-radius: 14px; background: var(--warn-bg); border: 1px solid var(--warn-border); color: var(--warn-text); font-weight: 600; }

.im-partner { margin: 0 0 24px; padding: 18px 20px; border-radius: 18px; background: var(--im-tint); border: 1px solid var(--im-tint-border); }
.im-partner[hidden] { display: none; }
.im-partner .hc-h3 { color: var(--ink); font-size: 1.0625rem; }
.im-partner code { font-size: 1rem; overflow-wrap: anywhere; }
.im-partner-msg { margin: 0 0 8px; color: var(--text); overflow-wrap: anywhere; }
.im-partner .hc-note a { display: inline-flex; align-items: center; min-height: 24px; }

.im-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); gap: 16px; margin-bottom: 36px; }
.im-card { min-width: 0; background: var(--surface); border: 1px solid var(--border); border-radius: 20px; padding: 20px; box-shadow: var(--shadow-sm);
  display: flex; flex-direction: column; gap: 10px; }
.im-card-h { margin: 0; font-size: 1.125rem; font-weight: 800; color: var(--ink); }
.im-card-line { margin: 0; font-size: .875rem; line-height: 1.45; color: var(--muted); }
.im-nums { display: flex; gap: 12px; flex-wrap: wrap; }
.im-num { margin: 0; flex: 1 1 120px; min-width: 0; display: flex; flex-direction: column; padding: 10px 12px; border-radius: 14px; background: var(--hc-bg); }
.im-num-v { font-size: 1.75rem; font-weight: 800; color: var(--ink); line-height: 1.1; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.im-num-l { font-size: .8125rem; font-weight: 600; color: var(--muted); }

.im-spark { display: block; width: 100%; height: 64px; }
.im-spark-base { stroke: var(--border); stroke-width: 1; }
.im-spark-line { fill: none; stroke: var(--im-line); stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round; }
.im-spark-small { fill: var(--im-small); }
.im-spark-key { margin: 2px 0 0; display: flex; justify-content: space-between; gap: 8px; font-size: .75rem; color: var(--muted); }
.im-spark-key span { display: inline-flex; align-items: center; gap: 4px; }
.im-key-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--im-small); display: inline-block; }
.im-spark-none { margin: 0; font-size: .8125rem; color: var(--muted); }

.im-items h4 { margin: 4px 0 6px; font-size: .8125rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.im-items ul { list-style: none; margin: 0; padding: 0; }
.im-items li { display: flex; justify-content: space-between; gap: 12px; padding: 6px 0; border-top: 1px solid var(--hc-line); font-size: .875rem; }
.im-items li span { min-width: 0; overflow-wrap: anywhere; }
.im-items li b { font-variant-numeric: tabular-nums; color: var(--ink); }

.im-days summary { display: flex; align-items: center; min-height: 44px; cursor: pointer; font-size: .875rem; font-weight: 700; color: var(--accent); }
.im-days table { width: 100%; border-collapse: collapse; font-size: .875rem; }
.im-days th, .im-days td { padding: 4px 6px; border-top: 1px solid var(--hc-line); text-align: left; }
.im-days td { text-align: right; font-variant-numeric: tabular-nums; }
.im-days thead th:last-child { text-align: right; }

.im-how { background: var(--surface); border: 1px solid var(--border); border-radius: 20px; padding: 24px; margin-bottom: 12px; }
.im-how ul { margin: 0 0 20px; padding-left: 20px; line-height: 1.55; color: var(--text); }
.im-how li { margin-bottom: 6px; }
.im-code { max-width: 560px; }
.im-input { flex: 1; min-width: 0; min-height: 46px; padding: 0 14px; border: 1px solid var(--hc-field); border-radius: 12px; background: var(--surface);
  color: var(--text); font: inherit; font-size: .9375rem; }
.im-code .hc-note { margin-top: 8px; }
.im-code .hc-note a { display: inline-flex; align-items: center; min-height: 24px; }

@media (max-width: 600px) {
  .im-hero { padding: 24px 0 18px; margin-bottom: 16px; }
  .im-hero h1 { font-size: 1.5rem; }
  .im-lead { font-size: 1rem; }
  .im-card, .im-how { padding: 16px; border-radius: 16px; }
  .im-num-v { font-size: 1.5rem; }
}

@media print {
  .im-page { background: #fff; }
  .im-hero { border: 0; padding: 0 0 8pt; }
  .im-card { break-inside: avoid; box-shadow: none; }
  .im-code { display: none; }
}
