/* ============================================================
   APP MENINAS V2 — VERSÃO IMPRESSA DOS PRÊMIOS
   Conteúdo impresso: data e três imagens em boxes.
   ============================================================ */

:root {
  --paper: #ffffff;
  --ink: #30343a;
  --line: #4b4f56;
  --screen: #e8e8eb;
  --font-playful: "Sour Gummy", system-ui, sans-serif;
  --font-sans: "Roboto Condensed", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
  margin: 0;
  padding: 0;
}

body {
  color: var(--ink);
  background: var(--screen);
  font-family: var(--font-sans);
}

img {
  display: block;
  max-width: 100%;
}

.print-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: min(210mm, calc(100% - 24px));
  margin: 12px auto;
  padding: 10px 12px;
  border: 1px solid #ccccd2;
  border-radius: 12px;
  background: #ffffff;
  box-shadow: 0 5px 18px rgba(0, 0, 0, .09);
}

.print-toolbar__periods {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.print-toolbar__button,
.print-toolbar__period {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 7px 14px;
  border: 2px solid #6a2caf;
  border-radius: 7px;
  color: #ffffff;
  background: linear-gradient(180deg, #8b63df, #6541ba);
  font-family: var(--font-playful);
  font-size: 14px;
  font-weight: 700;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
}

.print-toolbar__button--light,
.print-toolbar__period {
  border-color: #b5b5bd;
  color: #484851;
  background: #ffffff;
}

.print-toolbar__period.is-active {
  border-color: #a52272;
  color: #ffffff;
  background: linear-gradient(180deg, #ef52a4, #ce247f);
}

.print-sheet {
  width: 210mm;
  min-height: 297mm;
  margin: 0 auto 18px;
  padding: 8mm;
  background: var(--paper);
  box-shadow: 0 12px 32px rgba(0, 0, 0, .13);
}

.print-sheet__date {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 13mm;
  margin-bottom: 5mm;
  border: 2px solid var(--line);
  font-family: var(--font-playful);
  font-size: 22px;
  font-weight: 800;
  letter-spacing: .04em;
}

.print-reward-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 4mm;
}

.print-reward-box {
  display: grid;
  place-items: center;
  height: 78mm;
  margin: 0;
  padding: 5mm;
  overflow: hidden;
  border: 2px solid var(--line);
  background: #ffffff;
  break-inside: avoid;
  page-break-inside: avoid;
}

.print-reward-box img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.print-sheet__error {
  margin: 30mm auto 0;
  padding: 12mm;
  border: 2px solid var(--line);
  font-family: var(--font-playful);
  font-size: 18px;
  text-align: center;
}

@page {
  size: A4 portrait;
  margin: 0;
}

@media print {
  html,
  body {
    width: 210mm;
    min-height: 297mm;
    background: #ffffff;
  }

  .no-print {
    display: none !important;
  }

  .print-sheet {
    width: 210mm;
    min-height: 297mm;
    margin: 0;
    box-shadow: none;
  }
}

@media screen and (max-width: 850px) {
  .print-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .print-toolbar__periods {
    flex-wrap: wrap;
  }

  .print-sheet {
    width: calc(100% - 20px);
    min-height: auto;
  }
}
