/* ========== POLÍTICA DE REEMBOLSO E GARANTIA ==========
   Página de leitura: coluna única de ~760px. Usa as variáveis, o header e o rodapé de style.css.
   As âncoras do índice param abaixo do header pelo scroll-margin de section[id] (style.css). */

.policy {
  padding: 40px 20px 88px;
  background: var(--section-white);
}

.policy__inner {
  max-width: 760px;
  margin: 0 auto;
  font-size: 1rem;
  line-height: 1.7;
  color: var(--text);
}

.policy__title {
  font-family: var(--font-display);
  font-size: clamp(1.9rem, 5vw, 2.6rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--blue);
}

/* ---------- índice ---------- */
.policy__toc {
  margin-top: 28px;
  padding: 20px 22px;
  background: var(--section-mist);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.policy__toc-title {
  margin-bottom: 8px;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
}

.policy__toc ol {
  list-style: none;
  display: grid;
  gap: 2px 24px;
}

.policy__toc a {
  display: inline-block;
  padding: 3px 0;
  font-size: 0.94rem;
  font-weight: 600;
  color: var(--blue);
  text-decoration: none;
}

.policy__toc a:hover {
  text-decoration: underline;
}

@media (min-width: 640px) {
  .policy__toc ol {
    grid-template-columns: 1fr 1fr;
  }
}

/* ---------- seções (.policy__text: o resumo e as seções numeradas) ---------- */
.policy__text {
  margin-top: 40px;
}

.policy__text h2 {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 800;
  line-height: 1.3;
  color: var(--blue-dark);
  margin-bottom: 12px;
}

.policy__text p + p,
.policy__text p + ul,
.policy__text p + ol,
.policy__text ul + p,
.policy__text ol + p,
.policy__text p + table {
  margin-top: 12px;
}

.policy__text ul,
.policy__text ol {
  padding-left: 22px;
}

.policy__text ul {
  list-style: disc;
}

.policy__text ol {
  list-style: decimal;
}

.policy__text li + li,
.policy__text li ul {
  margin-top: 6px;
}

.policy__text li::marker {
  color: var(--blue);
  font-weight: 700;
}

.policy__text strong {
  color: var(--blue-dark);
}

.policy__text a {
  color: var(--blue);
  font-weight: 600;
  overflow-wrap: anywhere;
}

/* ---------- resumo em destaque ---------- */
.policy__summary {
  padding: 24px 22px;
  background: var(--yellow-soft);
  border: 1px solid var(--yellow-dark);
  border-radius: var(--radius);
}

.policy__summary .policy__table {
  background: var(--surface);
}

/* ---------- tabelas ---------- */
.policy__table {
  width: 100%;
  border-collapse: collapse;
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  font-size: 0.92rem;
  line-height: 1.5;
  background: var(--surface);
}

.policy__table th,
.policy__table td {
  padding: 12px 14px;
  text-align: left;
  vertical-align: top;
  border-top: 1px solid var(--border);
}

.policy__table thead th {
  border-top: 0;
  background: var(--blue);
  color: #fff;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.policy__table tbody th {
  font-weight: 700;
  color: var(--blue-dark);
}

/* coluna "Dia" curta: "5 a 7" não quebra */
.policy__table--dias tbody th {
  white-space: nowrap;
}

/* Celular: cada linha vira um cartão; o rótulo da coluna vem de data-label */
@media screen and (max-width: 639px) {
  .policy__table,
  .policy__table tbody,
  .policy__table tr,
  .policy__table th,
  .policy__table td {
    display: block;
  }

  .policy__table {
    border: 0;
    border-radius: 0;
    overflow: visible;
    background: transparent;
  }

  .policy__summary .policy__table {
    background: transparent;
  }

  .policy__table thead {
    display: none;
  }

  .policy__table tr {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
  }

  .policy__table tr + tr {
    margin-top: 12px;
  }

  .policy__table th,
  .policy__table td {
    padding: 10px 14px;
  }

  .policy__table tbody th {
    border-top: 0;
    background: var(--blue-soft);
  }

  .policy__table th::before,
  .policy__table td::before {
    content: attr(data-label);
    display: block;
    margin-bottom: 2px;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
  }
}

@media (min-width: 640px) {
  .policy {
    padding: 56px 24px 112px;
  }

  .policy__summary {
    padding: 28px 30px;
  }
}

/* ---------- impressão ---------- */
@media print {
  .header,
  .footer,
  .policy__toc {
    display: none;
  }

  .policy {
    padding: 0;
  }

  .policy__inner {
    max-width: none;
    font-size: 11pt;
    line-height: 1.5;
    color: #000;
  }

  .policy__title,
  .policy__text h2,
  .policy__text strong,
  .policy__text a,
  .policy__table tbody th {
    color: #000;
  }

  .policy__text h2 {
    break-after: avoid;
  }

  .policy__summary {
    padding: 0;
    background: none;
    border: 0;
  }

  .policy__table {
    border-radius: 0;
  }

  .policy__table thead th {
    background: none;
    color: #000;
    border-bottom: 1px solid #000;
  }

  .policy__table tr {
    break-inside: avoid;
  }

  .policy__text a {
    text-decoration: none;
  }
}
