/*
 * The site's free tools (SiteToolsController; boards F11-01..04). Loaded after guest.css, landing.css and
 * seo_page.css, only on these pages: a tool page is the SEO hero with the tool's form at its side (the guest page's
 * fields in a card on the landing's mist), the answer first on the result page (on the landing's green band) with the
 * form one tap away, then a short read, the FAQ and the closing panel. The bingo's result is its print page: the A4
 * sheets of the C5 printables on the mist, and only the sheets print. Plain CSS, mobile-first, no :has(), no JS,
 * light and dark through the tokens (the sheets stay paper white).
 */

/* ---------- Tokens ---------- */

:root {
  --tool-band-line: rgba(31, 45, 37, 0.1);
}

@media (prefers-color-scheme: dark) {
  :root {
    --tool-band-line: rgba(243, 239, 231, 0.12);
  }
}

/* ---------- The hero: the copy, the chá's scene and the form at its side ---------- */

.tool-hero {
  overflow: hidden;
  padding: 1rem 0 3rem;
}

.tool-hero__grid {
  display: grid;
  grid-template-areas: "visual" "copy" "card";
  gap: 1.5rem;
  margin-top: 0.5rem;
}

.tool-hero__copy {
  grid-area: copy;
}

.tool-hero__copy .seo-hero__title {
  max-width: 13ch;
}

.tool-hero__copy .seo-hero__lead {
  max-width: 30rem;
}

.tool-hero__visual {
  grid-area: visual;
  align-items: flex-start;
}

.tool-hero__visual .seo-hero__scene {
  height: auto;
}

.tool-hero__side {
  display: grid;
  grid-area: card;
  gap: 1rem;
  align-content: start;
  min-width: 0;
}

/* ---------- The form: the guest page's fields in a card ---------- */

.tool-card {
  padding: 1.25rem 1.25rem 1.5rem;
  border: 1px solid var(--lp-line);
  border-radius: 1.5rem;
  background: var(--lp-mist);
  scroll-margin-top: 1rem;
}

.tool-card__title {
  font-size: 1.25rem;
  font-weight: 600;
  line-height: 1.25;
  letter-spacing: -0.015em;
}

.tool-card .field {
  margin-top: 1.25rem;
}

.tool-card .tool-card__title + .field {
  margin-top: 0.75rem;
}

.tool-card .landing-button {
  width: 100%;
  margin-top: 1.5rem;
}

.tool-card .segments {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: var(--space-2);
}

/* `.field label` makes every label a block: the segment's stays a centered row. */
.tool-card .segment__label {
  display: flex;
  flex-direction: row;
  min-height: 3.25rem;
}

.tool-card .money-input,
.tool-card .choices {
  margin-top: var(--space-2);
}

/* A choice card that is the label itself keeps its grid (`.field label` is a block), its caption regular. */
.tool-card .choice__card {
  display: grid;
  min-height: 3.25rem;
  font-weight: 400;
  padding-top: 0.625rem;
  padding-bottom: 0.625rem;
}

.tool-card .field__row {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
  gap: 0.75rem;
}

.tool-card select.input {
  padding-right: 2.75rem;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235a665e' stroke-width='1.75' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9.5 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.875rem center;
  background-size: 1.25rem;
}

.tool-card__note {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.375rem;
  margin-top: 0.875rem;
  color: var(--lp-ink-2);
  font-size: 0.875rem;
}

.tool-card__note .icon {
  width: 1rem;
  height: 1rem;
  color: var(--lp-matcha);
}

/* ---------- The answer: first on the result page, on the landing's green band ---------- */

.tool-result {
  padding: 1.5rem 1.25rem;
  border-radius: 1.5rem;
  background: var(--lp-band);
  color: var(--lp-on-band);
  scroll-margin-top: 1rem;
}

.tool-result__label {
  color: var(--lp-on-band-2);
  font-size: 1rem;
  font-weight: 500;
  line-height: 1.4;
}

.tool-result__figure {
  margin-top: 0.25rem;
  font-size: clamp(2.5rem, 2rem + 2vw, 3.25rem);
  font-stretch: 92%;
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}

.tool-result__line {
  margin-top: 0.5rem;
  font-size: 1.0625rem;
  line-height: 1.5;
}

.tool-result__line + .tool-result__line {
  margin-top: 0.25rem;
}

.tool-result__line--small {
  color: var(--lp-on-band-2);
  font-size: 0.9375rem;
}

.tool-sizes + .tool-result__line--small {
  margin-top: 0.75rem;
}

.tool-result__more {
  margin-top: 1.25rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--tool-band-line);
}

.tool-result__more-title {
  font-weight: 600;
}

.tool-result .landing-button {
  width: 100%;
  margin-top: 1.5rem;
}

.tool-result__note {
  margin-top: 0.75rem;
  color: var(--lp-on-band-2);
  font-size: 0.875rem;
  line-height: 1.45;
  text-align: center;
}

/* The gift amount's range, "de R$ 80 a R$ 150": its two words small, each half whole when the line wraps. */
.tool-range__part {
  white-space: nowrap;
}

.tool-range__word {
  color: var(--lp-on-band-2);
  font-size: 0.45em;
  font-stretch: 100%;
  font-weight: 500;
  letter-spacing: 0;
}

/* The simulator's "Com outro valor médio" and the gift amount's "Com outra proximidade". */
.tool-table {
  width: 100%;
  margin-top: 0.5rem;
  border-collapse: collapse;
  font-size: 0.9375rem;
  font-variant-numeric: tabular-nums;
}

.tool-table th {
  padding: 0 0 0.375rem;
  color: var(--lp-on-band-2);
  font-size: 0.8125rem;
  font-weight: 500;
  text-align: right;
}

.tool-table td {
  padding: 0.5rem 0;
  border-top: 1px solid var(--tool-band-line);
  text-align: right;
  white-space: nowrap;
}

.tool-table th:first-child,
.tool-table td:first-child {
  text-align: left;
}

/* Room between the amounts on the narrowest phones (320 px). */
.tool-table th + th,
.tool-table td + td {
  padding-left: 0.5rem;
}

@media (max-width: 23rem) {
  .tool-table {
    font-size: 0.875rem;
  }
}

.tool-table tr.is-current td {
  font-weight: 600;
}

/* The gift amount's rows are named (who the guest is): a row header, set as a cell, that may wrap. */
.tool-table tbody th {
  padding: 0.5rem 0.5rem 0.5rem 0;
  border-top: 1px solid var(--tool-band-line);
  color: inherit;
  font-size: inherit;
  font-weight: 400;
}

.tool-table tr.is-current th {
  font-weight: 600;
}

/* The diapers' four sizes, two per row. */
.tool-sizes {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.5rem;
  margin: 1rem 0 0;
  padding: 0;
  list-style: none;
}

.tool-size {
  display: flex;
  flex-direction: column;
  padding: 0.75rem 0.875rem;
  border-radius: 1rem;
  background: var(--lp-band-tile);
  box-shadow: var(--lp-band-tile-shadow);
}

.tool-size__name {
  font-weight: 600;
}

.tool-size__count {
  margin-top: 0.25rem;
  font-size: 1.75rem;
  font-stretch: 92%;
  font-weight: 600;
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
}

.tool-size__count span {
  margin-left: 0.25rem;
  color: var(--lp-ink-2);
  font-size: 0.9375rem;
  font-stretch: 100%;
  font-weight: 500;
}

.tool-size__weight {
  color: var(--lp-ink-2);
  font-size: 0.8125rem;
}

/* "Uma frase para o convite": a message bubble. */
.tool-quote {
  margin-top: 0.625rem;
  padding: 0.75rem 1rem 0.875rem;
  border-radius: 1.25rem 1.25rem 0.375rem 1.25rem;
  background: var(--lp-band-tile);
  box-shadow: var(--lp-band-tile-shadow);
  line-height: 1.5;
}

.tool-quote__note {
  margin-top: 0.5rem;
  color: var(--lp-on-band-2);
  font-size: 0.875rem;
}

/* The invite's picture. */
.tool-image {
  display: flex;
  justify-content: center;
  margin-top: 1rem;
}

.tool-image img {
  display: block;
  width: 100%;
  max-width: 16rem;
  height: auto;
  border-radius: 0.875rem;
  box-shadow: 0 1px 2px rgba(19, 38, 28, 0.08), 0 12px 32px -12px rgba(19, 38, 28, 0.28);
}

.tool-image--square img {
  max-width: 20rem;
}

.tool-result .landing-button .icon {
  width: 1.25rem;
  height: 1.25rem;
}

/* ---------- The form again, one tap away ---------- */

.tool-redo {
  border: 1px solid var(--lp-line);
  border-radius: 1.5rem;
  background: var(--lp-mist);
}

.tool-redo > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 3.5rem;
  padding: 0 1.25rem;
  font-weight: 600;
  list-style: none;
  cursor: pointer;
}

.tool-redo > summary::-webkit-details-marker {
  display: none;
}

.tool-redo > summary .icon {
  width: 1.25rem;
  height: 1.25rem;
  color: var(--lp-ink-2);
}

.tool-redo .tool-card {
  padding-top: 0;
  border: 0;
  background: none;
}

/* ---------- The read under the hero: the SEO pages' column, no contents ---------- */

.tool-body {
  padding-bottom: var(--lp-section);
}

.tool-body .seo-fee {
  background: var(--lp-paper);
}

.tool-source {
  max-width: var(--seo-measure);
  margin-top: 1rem;
  color: var(--lp-ink-2);
  font-size: 0.875rem;
}

.tool-source a {
  color: var(--lp-ink-2);
  text-decoration-color: var(--lp-line);
  text-decoration-thickness: 1.5px;
}

/* ---------- The bingo's print page ---------- */

.tool-print {
  padding: 1rem 0 0;
}

.tool-print__bar {
  display: grid;
  gap: 0.75rem;
  margin-top: 0.5rem;
  padding-bottom: 1.5rem;
}

.tool-print__title {
  font-size: clamp(1.75rem, 1.3rem + 1.8vw, 2.5rem);
  font-stretch: 94%;
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.026em;
}

.tool-print__line {
  color: var(--lp-ink-2);
  line-height: 1.5;
}

.tool-print__how {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  max-width: 34rem;
  padding: 0.75rem 1rem;
  border-radius: 1rem;
  background: var(--lp-band);
  color: var(--lp-on-band);
  font-size: 0.9375rem;
  line-height: 1.45;
}

.tool-print__how .icon {
  flex: none;
  width: 1.125rem;
  height: 1.125rem;
  margin-top: 0.1rem;
  color: var(--lp-matcha);
}

.tool-back {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  min-height: 2.75rem;
  color: var(--lp-ink);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-color: var(--lp-line);
  text-decoration-thickness: 1.5px;
  text-underline-offset: 0.2em;
}

.tool-back .icon {
  width: 1.125rem;
  height: 1.125rem;
}

.tool-result .tool-back {
  color: var(--lp-on-band);
}

/* The sheets: Games::Printable's A4 pages (games/printables/show's CSS, for the bingo), paper white in either theme. */
.tool-sheets {
  --surface: #ffffff;
  --surface-muted: #f7f0e6;
  --border: #ebe2d5;
  --border-strong: #d6cabb;
  --text: #1f2d25;
  --text-muted: #5a665e;
  --primary: #3f6b4e;
  --primary-soft: #e6efe5;
  --tint-1: #e3ecdf;
  --font-display: Fraunces, Georgia, serif;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.25rem;
  padding: 1.5rem 0 2.5rem;
  background: var(--lp-mist);
}

.tool-sheets p,
.tool-sheets h1,
.tool-sheets ol {
  margin: 0;
  padding: 0;
}

.tool-sheets ol {
  list-style: none;
}

.tool-sheets .a4 {
  position: relative;
  display: flex;
  flex: none;
  flex-direction: column;
  width: 210mm;
  height: 297mm;
  padding: 12mm 12mm 9mm;
  overflow: hidden;
  border-radius: 4px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06), 0 8px 24px rgba(0, 0, 0, 0.08);
  color: var(--text);
  font-family: "Instrument Sans", "Instrument Sans Fallback", system-ui, sans-serif;
  color-scheme: light;
  -webkit-print-color-adjust: exact;
  print-color-adjust: exact;
}

.tool-sheets .a4__foot {
  display: flex;
  justify-content: space-between;
  gap: 6mm;
  margin-top: auto;
  padding-top: 4mm;
  color: var(--text-muted);
  font-size: 8pt;
}

.tool-sheets .a4__foot b {
  color: var(--primary);
  font-family: var(--font-display);
  font-weight: 600;
}

.tool-sheets .p-title {
  font-size: 24pt;
  font-weight: 600;
  font-stretch: 85%;
  line-height: 1.02;
  letter-spacing: -0.02em;
}

.tool-sheets .p-lead {
  margin-top: 2mm;
  color: var(--text-muted);
  font-size: 10.5pt;
  line-height: 1.4;
}

/* The chá's bingo picture (the view sets --tool-art). */
.tool-sheets .art {
  flex: none;
  background: #fff var(--tool-art) center / contain no-repeat;
}

.tool-sheets .cut {
  position: relative;
  height: 0;
  margin: 0 -12mm;
  border-top: 1.5px dashed var(--border-strong);
}

.tool-sheets .cut svg {
  position: absolute;
  top: -7px;
  left: 8mm;
  width: 14px;
  height: 14px;
  padding: 0 1px;
  background: #fff;
  color: var(--text-muted);
}

.tool-sheets .bingo {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 2mm 0 6mm;
}

.tool-sheets .bingo + .cut + .bingo {
  padding-top: 8mm;
}

.tool-sheets .bingo__head {
  display: flex;
  align-items: center;
  gap: 4mm;
  padding: 3.5mm 4mm;
  border-radius: 14px;
  background: var(--tint-1);
}

.tool-sheets .bingo__art {
  width: 16mm;
  height: 16mm;
  border-radius: 10px;
  background-size: auto 86%;
}

.tool-sheets .bingo__title {
  flex: 1;
  min-width: 0;
}

.tool-sheets .bingo__title .p-title {
  font-size: 22pt;
}

.tool-sheets .bingo__title p {
  margin-top: 0.5mm;
  color: var(--text-muted);
  font-size: 9.5pt;
}

.tool-sheets .bingo__no {
  display: flex;
  flex: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 17mm;
  height: 17mm;
  border-radius: 50%;
  background: #fff;
  color: var(--primary);
  font-size: 7pt;
  font-weight: 600;
  line-height: 1;
}

.tool-sheets .bingo__no b {
  margin-top: 0.5mm;
  font-size: 16pt;
  font-stretch: 85%;
}

.tool-sheets .bingo__grid {
  display: grid;
  flex: 1;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: 1fr;
  gap: 2.5mm;
  margin-top: 4mm;
}

.tool-sheets .bingo__grid li {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  padding: 2mm;
  border: 1px solid var(--border-strong);
  border-radius: 12px;
  font-size: 12.5pt;
  font-weight: 600;
  line-height: 1.2;
  text-align: center;
  overflow-wrap: anywhere;
}

.tool-sheets .bingo__rule {
  margin-top: 3mm;
  color: var(--text-muted);
  font-size: 9pt;
  text-align: center;
}

.tool-sheets .draw {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  margin-top: 7mm;
  border-top: 1.5px dashed var(--border-strong);
  border-left: 1.5px dashed var(--border-strong);
}

.tool-sheets .draw li {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 24mm;
  padding: 2mm;
  border-right: 1.5px dashed var(--border-strong);
  border-bottom: 1.5px dashed var(--border-strong);
  font-size: 12pt;
  font-weight: 600;
  text-align: center;
  overflow-wrap: anywhere;
}

/* A phone sees the whole sheet, scaled down; paper gets it at size. */
@media screen and (max-width: 52rem) {
  .tool-sheets .a4 {
    zoom: 0.44;
  }
}

@media screen and (max-width: 23rem) {
  .tool-sheets .a4 {
    zoom: 0.36;
  }
}

/* Only the sheets print, one per page (the view sets the page to A4 with no margins). */
@media print {
  body {
    background: #fff;
  }

  .skip-link,
  .landing-header,
  .tool-print,
  .landing-cta,
  .landing-footer {
    display: none;
  }

  .tool-sheets {
    display: block;
    padding: 0;
    background: none;
  }

  .tool-sheets .a4 {
    border-radius: 0;
    box-shadow: none;
    break-after: page;
  }

  .tool-sheets .a4:last-child {
    break-after: auto;
  }
}

/* ---------- Wider screens ---------- */

@media (min-width: 40rem) {
  .tool-print__bar {
    grid-template-columns: 1fr auto;
    align-items: end;
  }

  .tool-print__how {
    grid-column: 1 / -1;
  }
}

@media (min-width: 60rem) {
  .tool-hero {
    padding: 2rem 0 5rem;
  }

  .tool-hero__grid {
    grid-template-areas: "copy card" "visual card";
    grid-template-columns: minmax(0, 1fr) 28rem;
    grid-template-rows: auto 1fr;
    column-gap: 5rem;
    row-gap: 0;
    margin-top: 1.5rem;
  }

  .tool-hero__visual {
    justify-content: flex-start;
    margin-top: 2.5rem;
  }

  .tool-hero__visual::before {
    left: 9.5rem;
    width: 24rem;
    height: 24rem;
  }

  .tool-hero__visual .seo-hero__scene {
    width: 16rem;
  }

  .tool-card {
    padding: 1.75rem 1.75rem 2rem;
  }

  .tool-redo .tool-card {
    padding-top: 0;
  }

  .tool-result {
    padding: 1.75rem;
  }
}
