/* ============================================================
   SoftPay Fiscal — Reset + Base + Layout + Componentes
   ============================================================ */

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 24px);
  overflow-x: hidden;
  overflow-x: clip;
}

body {
  font-family: var(--font-body);
  font-size: var(--t-base);
  line-height: var(--lh-relaxed);
  color: var(--ink-2);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
  max-width: 100vw;
}

img, svg, video, canvas { display: block; max-width: 100%; height: auto; }
input, button, textarea, select { font: inherit; color: inherit; }
button { background: none; border: 0; cursor: pointer; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; padding: 0; }
:where(p, li) { text-wrap: pretty; }
:where(h1, h2, h3, h4) { text-wrap: balance; }

/* ---------- Tipografia — assinatura SoftPay: fino + bold ----
   h1/h2 nascem finos (300); o <b>/<strong> dentro deles vai a 800.
   O contraste peso é a hierarquia. h3/h4 ficam semibold p/ leitura. */
h1, h2, h3, h4, .display {
  font-family: var(--font-display);
  color: var(--ink);
  line-height: var(--lh-tight);
  letter-spacing: var(--tr-display);
}
h1, h2 { font-weight: 300; line-height: 1.06; }
h1 b, h1 strong, h2 b, h2 strong,
h1 .em, h2 .em { font-weight: 800; color: inherit; }
h1 .em, h2 .em { color: var(--brand); }
h1 { font-size: var(--t-5xl); }
h2 { font-size: var(--t-4xl); }
h3 { font-size: var(--t-2xl); font-weight: 600; line-height: var(--lh-snug); letter-spacing: var(--tr-tight); }
h4 { font-size: var(--t-xl); font-weight: 600; line-height: var(--lh-snug); letter-spacing: var(--tr-tight); }

strong, b { font-weight: 600; color: var(--ink); }

/* Rótulo UPPERCASE (eyebrow) */
.eyebrow {
  font-family: var(--font-display);
  font-size: var(--t-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: var(--tr-label);
  color: var(--brand-700);
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
}
.eyebrow::before {
  content: "";
  width: 20px; height: 2px;
  background: var(--brand);
  border-radius: 2px;
  flex: none;
}
.eyebrow--center::before { display: none; }

.lead {
  font-size: var(--t-lg);
  line-height: var(--lh-relaxed);
  color: var(--ink-3);
}
.mark { color: var(--brand); font-weight: inherit; }

/* ---------- Acessibilidade --------------------------------- */
:focus-visible { outline: none; box-shadow: var(--focus); border-radius: var(--r-xs); }
:focus:not(:focus-visible) { outline: none; }

.skip-link {
  position: absolute; left: var(--s-4); top: var(--s-4);
  z-index: var(--z-toast);
  background: var(--ink); color: var(--bg);
  padding: var(--s-3) var(--s-5); border-radius: var(--r-sm);
  font-weight: 600;
  transform: translateY(-200%);
  transition: transform var(--d-base) var(--e-out);
}
.skip-link:focus { transform: translateY(0); }

.visually-hidden {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip-path: inset(50%); white-space: nowrap; border: 0;
}

/* ---------- Layout ----------------------------------------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.container--narrow { max-width: var(--container-narrow); }

.section { padding-block: var(--section-y); position: relative; }
.section--sunken { background: var(--bg-subtle); }
.section--dark { background: var(--dark); color: var(--dark-ink-2); }
.section--dark h1, .section--dark h2, .section--dark h3, .section--dark h4 { color: var(--dark-ink); }

.section-head {
  display: flex; flex-direction: column; gap: var(--s-4);
  max-width: 60ch; margin-bottom: var(--s-16);
}
@media (max-width: 640px) { .section-head { margin-bottom: var(--s-10); } }
.section-head--center { align-items: center; text-align: center; margin-inline: auto; }
.section-head h2 { max-width: 22ch; }
.section-head--center h2 { margin-inline: auto; }
.section-head .lead { max-width: 56ch; }

.grid { display: grid; gap: var(--s-6); }
.grid--2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); }
.grid--3 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); }
.grid--4 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); }

/* ---------- Botões — pill, marca SoftPay -------------------- */
.btn {
  --btn-bg: var(--ink);
  --btn-fg: #fff;
  position: relative;
  display: inline-flex; align-items: center; justify-content: center;
  gap: var(--s-2);
  padding: 0.875rem 1.6rem;
  font-family: var(--font-display);
  font-size: var(--t-sm);
  font-weight: 600;
  letter-spacing: 0.005em;
  line-height: 1;
  color: var(--btn-fg);
  background: var(--btn-bg);
  border: 1.5px solid transparent;
  border-radius: var(--r-pill);
  white-space: nowrap;
  transition: transform var(--d-fast) var(--e-out),
              box-shadow var(--d-base) var(--e-out),
              background-color var(--d-base) var(--e-out),
              border-color var(--d-base) var(--e-out);
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0) scale(0.985); transition-duration: 60ms; }
@media (hover: none) {
  .btn { min-height: 44px; }
  .btn:hover { transform: none; }
  .btn:active { transform: scale(0.97); filter: brightness(0.96); }
}
a, button, summary, .card, [role="button"] { -webkit-tap-highlight-color: transparent; }

.btn--primary { --btn-bg: var(--brand); --btn-fg: #fff; box-shadow: var(--sh-brand); }
.btn--primary:hover { --btn-bg: var(--brand-600); box-shadow: var(--sh-brand-hover); }

.btn--dark { --btn-bg: var(--ink); --btn-fg: #fff; }
.btn--dark:hover { --btn-bg: #000; }

.btn--ghost { --btn-bg: transparent; --btn-fg: var(--ink); border-color: var(--line-2); }
.btn--ghost:hover { --btn-bg: var(--bg-sunken); border-color: var(--ink-4); }

.btn--light { --btn-bg: #fff; --btn-fg: var(--ink); box-shadow: var(--sh-sm); }
.btn--light:hover { --btn-bg: #fff; box-shadow: var(--sh-md); }

.btn--wpp { --btn-bg: var(--ok); --btn-fg: #fff; }
.btn--wpp:hover { --btn-bg: #0c6a34; }

.btn--lg { padding: 1.05rem 2rem; font-size: var(--t-base); }
.btn--sm { padding: 0.6rem 1.1rem; font-size: var(--t-sm); }
.btn--block { width: 100%; }

.btn__arrow { transition: transform var(--d-base) var(--e-spring); }
.btn:hover .btn__arrow { transform: translateX(4px); }

/* ---------- Cards ------------------------------------------- */
.card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: var(--s-8);
  transition: border-color var(--d-base) var(--e-out),
              box-shadow var(--d-base) var(--e-out),
              transform var(--d-base) var(--e-out);
}
.card--hover:hover { border-color: var(--brand-100); box-shadow: var(--sh-lg); transform: translateY(-4px); }

.badge {
  display: inline-flex; align-items: center; gap: var(--s-2);
  padding: var(--s-1) var(--s-3);
  font-size: var(--t-xs); font-weight: 600;
  border-radius: var(--r-pill);
  background: var(--brand-50); color: var(--brand-700);
  border: 1px solid var(--brand-100);
  white-space: nowrap;
}

.icon-box {
  display: grid; place-items: center;
  width: 46px; height: 46px;
  border-radius: var(--r-md);
  background: var(--brand-50); color: var(--brand);
  border: 1px solid var(--brand-100);
  flex: none;
}
.icon-box svg { width: 22px; height: 22px; }

/* ---------- Utilitários ------------------------------------- */
.text-center { text-align: center; }
.flow > * + * { margin-top: var(--flow, var(--s-4)); }
@media (max-width: 767px) { .hide-mobile { display: none !important; } }
@media (min-width: 768px) { .only-mobile { display: none !important; } }

.rule { height: 1px; border: 0; background: linear-gradient(90deg, transparent, var(--line), transparent); }

/* ---------- Wordmark "SoftPay" -----------------------------
   Uso: <span class="sp">Soft<i>Pay</i></span> — "Pay" no azul da marca.
   Em fundo escuro, "Pay" vai pro sky. */
.sp { font-weight: 700; color: var(--ink); }
.sp i { font-style: normal; color: var(--brand); }
.section--dark .sp, .cta .sp, .footer .sp { color: var(--dark-ink); }
.section--dark .sp i, .cta .sp i, .footer .sp i { color: var(--brand-on-dark); }
