/* Livro de Memórias — páginas, arquivos e calendário separado */
.book-screen,
.finale-screen,
.shop-screen {
  min-height: calc(100vh - var(--topbar-h));
  padding: 24px 18px 90px;
  overflow-y: auto;
}

.book-back,
.finale-back,
.shop-back {
  position: fixed;
  left: 14px;
  top: calc(var(--topbar-h) + 16px);
  z-index: 50;
  border: 4px solid var(--wood-900);
  background: rgba(58,38,16,.94);
  color: var(--cream-100);
  padding: 8px 12px;
  font: inherit;
  font-size: 22px;
  cursor: pointer;
  box-shadow: 4px 4px 0 rgba(0,0,0,.32);
}

.book-panel,
.finale-panel,
.shop-panel {
  width: min(1120px, calc(100vw - 110px));
  margin: 0 auto;
  padding: 24px;
  border: 6px solid var(--wood-900);
  background:
    radial-gradient(circle at 18% 12%, rgba(240,200,64,.08), transparent 30%),
    rgba(77,49,24,.96);
  box-shadow: 0 0 0 4px rgba(0,0,0,.28), 8px 8px 0 rgba(0,0,0,.35);
}

.book-header,
.finale-header,
.shop-header {
  display: grid;
  grid-template-columns: 76px 1fr;
  gap: 16px;
  align-items: center;
  margin-bottom: 18px;
}

.book-header > img,
.finale-header > img,
.shop-header > img {
  width: 72px;
  height: 72px;
  object-fit: contain;
  filter: drop-shadow(3px 4px 0 rgba(0,0,0,.32));
}

.book-header span,
.finale-header span,
.shop-header span {
  display: block;
  color: var(--green-400);
  font-size: 21px;
}

.book-header h1,
.finale-header h1,
.shop-header h1 {
  margin: 0;
  color: var(--gold-300);
  font-size: clamp(44px, 5vw, 72px);
  line-height: .90;
  text-shadow: 4px 4px 0 var(--shadow-hard);
}

.book-header p,
.finale-header p,
.shop-header p {
  margin: 8px 0 0;
  color: var(--cream-100);
  font-size: clamp(22px, 2.3vw, 31px);
  line-height: 1.15;
}

.book-album-layout {
  display: grid;
  grid-template-columns: 225px minmax(0,1fr);
  gap: 14px;
  align-items: stretch;
}

.book-file-tabs {
  display: grid;
  gap: 8px;
  align-content: start;
  padding: 14px 10px;
  border: 5px solid var(--wood-900);
  background:
    linear-gradient(90deg, rgba(29,14,5,.92), rgba(73,44,19,.92));
  box-shadow: inset 4px 0 0 rgba(240,200,64,.12), 5px 5px 0 rgba(0,0,0,.25);
}

.book-file-tabs__title {
  color: var(--gold-300);
  font-size: 26px;
  text-align: center;
  margin-bottom: 4px;
}

.book-file-tab {
  position: relative;
  min-height: 80px;
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 9px;
  align-items: center;
  text-align: left;
  padding: 9px 10px 9px 14px;
  border: 4px solid var(--wood-900);
  border-left: 11px solid #d8a24a;
  background: #7b5129;
  color: var(--cream-100);
  font: inherit;
  cursor: pointer;
  box-shadow: 3px 3px 0 rgba(0,0,0,.22);
}

.book-file-tab::after {
  content: "";
  position: absolute;
  right: -12px;
  top: 12px;
  width: 16px;
  height: 48px;
  background: inherit;
  border: 4px solid var(--wood-900);
  border-left: 0;
  box-shadow: 3px 3px 0 rgba(0,0,0,.18);
}

.book-file-tab img {
  width: 36px;
  height: 36px;
  object-fit: contain;
}

.book-file-tab span {
  font-size: 21px;
  line-height: 1.05;
}

.book-file-tab.is-active {
  background: #f0c840;
  color: var(--wood-900);
  transform: translateX(10px);
}

.book-spread {
  position: relative;
  min-height: 570px;
  display: grid;
  grid-template-columns: minmax(0,1fr) 78px;
  gap: 0;
  align-items: stretch;
}

.book-page {
  min-height: 570px;
  padding: 22px;
  border: 6px solid var(--wood-900);
  background:
    linear-gradient(90deg, rgba(0,0,0,.18), transparent 5%, transparent 95%, rgba(0,0,0,.12)),
    #e8c98d;
  color: var(--wood-900);
  box-shadow: inset 8px 0 0 rgba(80,45,18,.20), 7px 7px 0 rgba(0,0,0,.30);
}

.book-page-label {
  display: inline-block;
  margin-bottom: 12px;
  padding: 4px 9px;
  border: 3px solid rgba(75,45,19,.60);
  background: rgba(255,245,205,.60);
  color: #5a3519;
  font-size: 18px;
}

.book-content {
  min-height: 460px;
}

.book-category-card {
  display: grid;
  grid-template-columns: 78px 1fr;
  gap: 15px;
  align-items: center;
  padding: 18px;
  border: 4px solid #6a421f;
  background: rgba(255,242,198,.55);
  box-shadow: 4px 4px 0 rgba(91,55,24,.18);
}

.book-category-card img {
  width: 70px;
  height: 70px;
  object-fit: contain;
}

.book-folder-tag {
  display: inline-block;
  margin-bottom: 6px;
  color: #6f4a20;
  font-size: 18px;
}

.book-category-card h2 {
  margin: 0 0 8px;
  color: #4b2810;
  font-size: 42px;
  line-height: 1;
  text-shadow: 2px 2px 0 rgba(255,255,255,.34);
}

.book-category-card p {
  margin: 0 0 8px;
  color: #3c210e;
  font-size: 25px;
  line-height: 1.16;
}

.book-category-card small {
  color: #71491e;
  font-size: 18px;
}

.book-placeholder-grid {
  margin-top: 14px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0,1fr));
  gap: 10px;
}

.book-placeholder-card {
  min-height: 150px;
  padding: 14px;
  border: 3px dashed rgba(91,55,24,.55);
  background: rgba(255,246,217,.50);
}

.book-placeholder-card span {
  color: #9a5a1d;
  font-size: 27px;
}

.book-placeholder-card strong {
  display: block;
  color: #4b2810;
  font-size: 24px;
}

.book-placeholder-card p {
  color: #71491e;
  font-size: 19px;
}

.book-calendar-tab-wrap {
  display: flex;
  align-items: flex-start;
  padding-top: 42px;
}

.book-calendar-tab {
  width: 76px;
  min-height: 220px;
  writing-mode: vertical-rl;
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: center;
  border: 5px solid var(--wood-900);
  border-left: 0;
  background: #f0c840;
  color: var(--wood-900);
  font: inherit;
  font-size: 22px;
  cursor: pointer;
  box-shadow: 5px 5px 0 rgba(0,0,0,.28);
}

.book-calendar-tab img {
  width: 36px;
  height: 36px;
  object-fit: contain;
}

.book-calendar-tab.is-active {
  filter: brightness(1.12);
  transform: translateX(-3px);
}

.book-calendar-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}

.book-calendar-head strong {
  color: #4b2810;
  font-size: clamp(32px, 3.8vw, 48px);
}

.gold-button--small {
  min-width: 120px !important;
  min-height: 44px !important;
  font-size: 22px !important;
}

.book-calendar-note {
  margin: 0 0 12px;
  color: #3c210e;
  font-size: 23px;
}

.book-weekdays,
.book-calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0,1fr));
  gap: 6px;
}

.book-weekdays span {
  color: #7d4c17;
  text-align: center;
  font-size: 20px;
}

.book-day {
  min-height: 74px;
  border: 3px solid #6a421f;
  background: rgba(255,246,217,.50);
  color: #3c210e;
  font: inherit;
  text-align: left;
  padding: 7px;
  cursor: pointer;
}

.book-day.is-blank {
  visibility: hidden;
}

.book-day.is-marked {
  background: rgba(240,200,64,.50);
  outline: 3px solid rgba(91,55,24,.35);
}

.book-day b {
  display: block;
  color: #9a5a1d;
  font-size: 22px;
}

.book-day em {
  display: block;
  font-style: normal;
  font-size: 16px;
  line-height: 1.05;
}

.book-calendar-detail {
  margin-top: 14px;
  padding: 18px;
  border: 4px solid #6a421f;
  background: rgba(255,242,198,.62);
  color: #3c210e;
}

.book-calendar-detail strong {
  color: #4b2810;
  font-size: 32px;
}

.book-calendar-detail p {
  font-size: 23px;
  line-height: 1.2;
}

.book-photo-placeholder {
  width: min(360px, 100%);
  height: 170px;
  display: grid;
  place-items: center;
  margin: 10px 0;
  border: 3px dashed rgba(91,55,24,.55);
  color: #71491e;
}

.book-footer {
  display: flex;
  justify-content: center;
  margin-top: 16px;
}

@media (max-width: 970px) {
  .book-panel,
  .finale-panel,
  .shop-panel { width: min(1080px, calc(100vw - 42px)); }
  .book-album-layout { grid-template-columns: 1fr; }
  .book-file-tabs { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .book-file-tab::after { display: none; }
  .book-file-tab.is-active { transform: none; }
  .book-spread { grid-template-columns: 1fr; }
  .book-calendar-tab-wrap { padding-top: 10px; }
  .book-calendar-tab {
    width: 100%;
    min-height: 70px;
    writing-mode: horizontal-tb;
    border-left: 5px solid var(--wood-900);
  }
  .book-placeholder-grid { grid-template-columns: 1fr 1fr; }
}
