#present:empty{display:none}
#prize.editorial{width:min(960px,96vw);max-height:90dvh;background:#fffaf0;color:#193e35;overscroll-behavior:contain;scrollbar-color:#8da99d #fffaf0}
.editorial article{padding:clamp(20px,5vw,64px);background:radial-gradient(ellipse at top right,#dfede0,transparent 34rem)}
.editorial #day{display:block;color:#7e4837;text-transform:uppercase;letter-spacing:.14em}
.editorial h2{max-width:18ch;margin:.5em 0 .7em;font-size:clamp(26px,4.3vw,54px);text-wrap:balance}
.editorial #close{position:sticky;top:8px;margin:-12px -8px -38px auto;display:block;right:auto;z-index:5;box-shadow:0 2px 12px #0d312235}
.editorial #present{clear:both}
#present p,#present label{font-size:1rem;line-height:1.78;color:inherit;text-wrap:pretty}
#present>p,#present>h3{max-width:66ch;margin:1.1em auto}
#present h3{font-size:clamp(20px,3vw,30px);line-height:1.2}
.scatter{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,205px),1fr));align-items:start;gap:22px 18px;margin:28px 0}
.scatter>*{min-width:0;transform:rotate(-1.8deg)}
.scatter>:nth-child(3n+2){transform:rotate(2deg) translateY(5px)}
.scatter>:nth-child(3n){transform:rotate(-.65deg)}
.paper,.scatter figure,.shelf{margin:0;padding:12px;background:#fff;border:1px solid #c5d5c8;border-radius:8px;box-shadow:0 4px 10px #1c433316}
.print{display:block;width:100%;height:auto;border-radius:4px}
.paper summary{cursor:pointer}
.paper summary{list-style:none}
.paper summary strong,.paper>a,.scatter figcaption{display:block;margin:10px 2px 4px;font-size:15px;color:#20463d}
.paper summary:after{content:'Докладніше +';display:block;margin-top:8px;color:#397669;font-size:13px}
.paper[open] summary:after{content:'Згорнути −'}
.scatter .paper[open]{grid-column:1/-1;transform:none;padding:clamp(14px,3vw,32px)}
.paper[open] .print{max-width:230px}

.stream,.languages{display:flex;gap:8px;flex-wrap:wrap}.stream a,.languages button{border:0;border-radius:9px;padding:12px;background:#16594e;color:white;text-decoration:none}
.stream a:first-child{background:#a32830}.languages{justify-content:center;margin-top:8px}.languages button{padding:7px 9px;font-size:13px;background:#e1e9e2;color:#53665b}
.jacket{aspect-ratio:3/4;display:flex;flex-direction:column;justify-content:space-between;padding:15%;color:#ffe5ab;background:linear-gradient(90deg,#0003,transparent 7%),var(--ink,#29495a);border:4px double #dfca91;box-shadow:3px 3px #d8c69c}
.jacket strong{font-size:clamp(18px,2vw,27px);line-height:1.2}.jacket span{font-size:3.5rem}.j1,.j4{--ink:#28554b}.j2,.j5{--ink:#854136}.j3{--ink:#654360}
.shelf{background:#ebf3e9;text-align:center;padding:22px;align-self:center;grid-column:2;grid-row:2}.shelf small{display:block;margin-top:12px}
.activity{border:0;width:100%;height:67dvh;border-radius:12px}.paper iframe{width:100%;height:330px;border:0}
[data-date="8"] #present>.print{height:clamp(200px,32vw,320px);object-fit:cover;margin:30px 0}
.editorial:is([data-date="1"],[data-date="14"]) article{background:linear-gradient(7deg,#e8dfc8,#fffaf0 32%,#fffaf0 84%,#d7e4d4);border-top:8px solid #a84337}
.editorial:is([data-date="24"],[data-date="25"]) article{color:#fff7e1;background:linear-gradient(130deg,#0f3530f2,#153e37fa 65%,#663d29ef),url(room-4.webp) center/cover;border:5px double #d8b774}
.editorial:is([data-date="24"],[data-date="25"]) #day{color:#f3d8a2}
.editorial[data-date="25"] h2:before{content:"";display:block;width:100%;height:clamp(140px,25vh,240px);margin:16px 0;background:linear-gradient(0deg,#12392d12,transparent),url(room-4.webp) center 45%/cover;border-radius:9px}
@media(max-width:620px){.editorial article{padding:22px 16px}.scatter{grid-template-columns:repeat(2,minmax(0,1fr));gap:16px 9px}.paper,.scatter figure{padding:7px}.shelf{grid-column:1/-1}.jacket{padding:10%}.jacket strong{font-size:16px}.jacket small{font-size:10px}.languages button{font-size:11px;padding:6px}.scatter .paper:has(iframe){grid-column:1/-1}.editorial #giftTitle{padding-right:16px}.activity{height:68dvh}}

.book-cover{display:block;width:100%;height:clamp(160px,24vw,290px);object-fit:contain}.paper>a>.print{margin-bottom:10px}
.book-links{display:flex;flex-wrap:wrap;justify-content:center;gap:6px;margin-top:10px}
.book-links a{display:grid;place-content:center;text-align:center;min-height:44px;padding:7px 12px;border-radius:9px;background:#16594e;color:white;text-decoration:none;font-size:12px;line-height:1.4}
.book-links a:hover{background:#0c483e}
.book-links small{color:#e2f5ed;font-size:10px}
.stream svg{width:23px;height:23px;vertical-align:middle}.stream a{display:inline-flex;align-items:center;gap:8px}
/* The final cards own their frame, including the four scrollport corners. */
#prize.editorial:is([data-date="24"],[data-date="25"]){border:5px double #d8b774;background:#153e37}
#prize.editorial:is([data-date="24"],[data-date="25"]) article{border:0}
.editorial:not([data-date="24"],[data-date="25"]) article::before{
  content:"";position:absolute;inset:0 0 auto;height:clamp(12px,2vw,22px);pointer-events:none;
  background:url(powder-bank.webp) center 92% / 55% 155% repeat-x;
  transform:rotate(180deg);opacity:.78;
}
#prize.editorial{scrollbar-width:thin}#prize.editorial #close{color:#16483d}#prize.editorial:is([data-date="24"],[data-date="25"]){scrollbar-color:#b7aa7b #153e37}

html{overscroll-behavior-y:none}
html.reading-gift{overflow:hidden}
.reading-gift body{position:fixed;inset:var(--trail-offset) 0 auto;width:100%}
@media (max-width:700px), (pointer:coarse) and (max-height:540px){
  #action{
    width:min(32rem,calc(100% - env(safe-area-inset-left) - env(safe-area-inset-right) - 24px));
    min-height:70px;padding:16px 12px;font-size:clamp(17px,4.9vw,23px);line-height:1.22;
    bottom:calc(env(safe-area-inset-bottom) + 14px);
  }
  #prize[open]{
    display:flex;flex-direction:column;overflow:hidden;overscroll-behavior:none;
    max-height:calc(100dvh - env(safe-area-inset-top) - env(safe-area-inset-bottom) - 24px);
  }
  #prize>article{min-height:0;overflow-x:hidden;overflow-y:auto;overscroll-behavior:none}
  #prize::backdrop{touch-action:none}
  #prize:has(.activity) article{padding:16px 10px}

  #prize .activity{display:block}

}
@media (pointer:coarse) and (orientation:landscape) and (max-height:540px){
  #action{min-height:56px;padding:10px 16px;bottom:calc(env(safe-area-inset-bottom) + 8px)}
}

/* Keep the full family portrait and the entire letter in the same reading surface. */
#prize.editorial[data-date="25"][open]{display:flex;flex-direction:column;overflow:hidden}
#prize.editorial[data-date="25"] article{min-height:0;overflow-y:auto;overscroll-behavior:none}
.editorial[data-date="25"] h2:before{content:none}
.editorial[data-date="25"] #present{display:flow-root}
.editorial[data-date="25"] #present>p{max-width:none}
.family-portrait{
  display:block;float:right;width:43%;height:auto;margin:0 0 20px 24px;
  border:1px solid #c3a36a;border-radius:12px;
}
@media(max-width:620px){
  .family-portrait{float:none;width:min(100%,340px);margin:0 auto 20px}
}

/* The stationary shell clips the frame. Only the inset reading surface moves. */
#prize[open]{display:flex;flex-direction:column;overflow:hidden;padding:6px}
#prize[open]>article{
  min-height:0;overflow:auto;overscroll-behavior:none;
  scrollbar-width:thin;scrollbar-color:#899d90 transparent;
  border-radius:inherit;
}
#prize[open]:is([data-date="24"],[data-date="25"])>article{scrollbar-color:#ae9f72 transparent}
#prize[open]>article::-webkit-scrollbar{width:6px;background:transparent}
#prize[open]>article::-webkit-scrollbar-thumb{background:#899d90;border-radius:6px}
@media(pointer:coarse){
  #prize[open]>article{scrollbar-width:none}
  #prize[open]>article::-webkit-scrollbar{display:none}
}
.dream{display:grid;grid-template-columns:minmax(130px,31%) 1fr;align-items:start;gap:clamp(18px,3vw,36px);padding:24px 0;border-top:1px solid #c9cdc1}
.dream img{display:block;width:100%;height:auto;border-radius:6px;mix-blend-mode:multiply}
#present .dream h3{margin:0;font-size:clamp(18px,2.4vw,27px);line-height:1.25}
.dream ul{margin:14px 0;padding-left:1.1em}
.dream li{margin:.5em 0;font-size:1rem;line-height:1.55}
.dream li::marker{color:#8a6f42}
#present .dream-book{margin:12px 0 0;color:#53685b;font-size:.875rem;line-height:1.55}
@media(max-width:580px){
  .dream{display:flow-root;padding:22px 0}
  .dream img{float:right;width:30%;margin:0 0 12px 12px}
  .dream ul{clear:both;padding-top:4px}
}
