#game .lawn-play[data-phase=result] { background:#142a2370; }
#game .keepsake-receipt {
  inset:auto max(12px,env(safe-area-inset-right)) max(12px,env(safe-area-inset-bottom)) max(12px,env(safe-area-inset-left));
  max-width:510px; max-height:calc(100% - 24px); margin:auto; padding:clamp(14px,3vw,24px);
  grid-template-columns:clamp(108px,31vw,165px) minmax(0,1fr); gap:12px clamp(12px,3vw,22px);
  border:0; border-radius:18px; background:#fcf6e9; color:#1d302a;
  box-shadow:0 12px 48px #102a2470; scrollbar-gutter:auto;
}
#game .keepsake-print { padding:0; background:none; border:0; border-radius:6px; box-shadow:none; transform:none; }
#game .keepsake-print img { display:block; width:100%; height:auto; border-radius:3px; object-fit:contain; }
#game .keepsake-receipt .lawn-receipt-copy { padding:16px 4px 0 0; }
#game .keepsake-receipt small { color:#715735; font:650 .83rem/1.5 system-ui,sans-serif; }
#game .keepsake-receipt h2 { font:700 clamp(22px,5.2vw,33px)/1.28 var(--guide-serif,serif); margin:3px 0 7px; color:#193f34; }
#game .keepsake-receipt .lawn-prize { display:inline-block; font:650 .93rem/1.5 system-ui,sans-serif; color:#774626; margin:0; }
#game .keepsake-story { grid-column:1/-1; color:#38493b; margin:0; font:500 16px/1.65 system-ui,sans-serif; }
#game .keepsake-receipt .lawn-close { right:3px; top:3px; color:#294b3c; min-width:44px; min-height:44px; }
#game .keepsake-receipt .lawn-receipt-actions { display:grid; grid-template-columns:1fr 1fr; gap:7px; align-items:stretch; }
#game .keepsake-receipt .lawn-receipt-actions button {
  min-width:0; padding:8px; min-height:44px; font:650 .95rem/1.45 system-ui,sans-serif;
  border:0!important; background:#e8ecde!important; color:#253d31; border-radius:8px;
}
#game .keepsake-receipt .lawn-receipt-actions button:first-child { grid-column:1/-1; background:#235546!important; color:#fffaf0; border-color:#235546!important; }
#game .keepsake-receipt .lawn-receipt-actions button:last-child:nth-child(2) { grid-column:1/-1; }
@media (min-width:620px) and (min-height:480px) {
  #game .keepsake-receipt { inset:50% auto auto 50%; width:min(88%,510px); transform:translate(-50%,-50%); }
}
@media (orientation:landscape) and (max-height:479px) {
  #game .keepsake-receipt { inset:6px max(8px,env(safe-area-inset-right)) 6px max(8px,env(safe-area-inset-left)); width:auto; max-width:700px; max-height:calc(100% - 12px); height:fit-content; margin:auto; grid-template-columns:clamp(100px,25vh,140px) 1fr; gap:6px 16px; padding:12px 18px; }
  #game .keepsake-print { grid-column:1;grid-row:1/3;align-self:center; }
  #game .keepsake-receipt .lawn-receipt-copy { grid-column:2; padding:0 32px 0 0; }
  #game .keepsake-receipt h2 { margin:1px 0;display:inline-block;padding-right:8px; }
  #game .keepsake-receipt small { display:block; }
  #game .keepsake-story { grid-column:2; font-size:15px;line-height:1.48; }
  #game .keepsake-receipt .lawn-receipt-actions { grid-template-columns:repeat(3,1fr); }
  #game .keepsake-receipt .lawn-receipt-actions button:first-child,#game .keepsake-receipt .lawn-receipt-actions button:last-child:nth-child(2) { grid-column:auto; }
}

#game .keepsake-receipt .lawn-receipt-actions .keepsake-offer {
  grid-column:1/-1;display:flex;align-items:center;justify-content:space-between;gap:10px;text-align:left;
  padding:8px 12px;background:#edf2e5!important;border-color:#a9b9a1!important;
}
#game .keepsake-offer>span {display:grid;gap:2px}
#game .keepsake-offer small {font-size:12px;line-height:1.3;color:#53694e}
#game .keepsake-offer b {font-size:16px;color:#214b37}
#game .keepsake-offer span span {font-size:14px;font-weight:500;color:#435144}
#game .keepsake-offer i {font:700 22px/1 system-ui;color:#3f684e}
#game .keepsake-selection {display:block;overflow-y:auto;overscroll-behavior:contain}
#game .keepsake-selection .keepsake-back {min-height:44px;padding:6px;background:transparent!important;border:0!important;color:#285540;text-align:left;font:700 15px/1.4 system-ui}
#game .keepsake-selection .selection-heading {display:flex;align-items:center;gap:14px;margin:5px 0 12px}
#game .keepsake-selection .selection-heading img {width:64px;height:64px;object-fit:cover;border:2px solid #f7e9ca;border-radius:6px}
#game .keepsake-selection .selection-heading h2 {margin:2px 0 0}
#game .keepsake-selection .journey-partner p {font:500 16px/1.6 system-ui;color:#354c3f}
#game .keepsake-selection .journey-partner .partner-disclosure {margin:9px 0 12px;padding-left:9px;border-left:2px solid #9cae8e;font-size:14px}
#game .keepsake-selection :is(a,button,summary):focus-visible,#game .keepsake-receipt button:focus-visible {outline:3px solid #0d6856;outline-offset:2px}
#game .keepsake-selection .journey-partner {background:none;border:0;padding:0}
#game .keepsake-selection .selection-heading {gap:15px;align-items:center;margin-block:5px 14px}
#game .keepsake-selection .selection-heading img {width:84px;height:84px;border:0;border-radius:5px}
#game .keepsake-selection .partner-disclosure {color:#39483b;background:#e9ecdf;border:0;padding:10px 12px}
#game .keepsake-selection .partner-backup {background:none;border:0}
#game .keepsake-selection .partner-backup summary,#game .keepsake-selection .partner-catalog,
#game .keepsake-selection .partner-backup a {min-height:44px;box-sizing:border-box;align-content:center;color:#284c3a}
@media(max-width:600px) and (min-height:481px){
  #game .keepsake-receipt {inset:auto 0 0;width:100%;max-width:none;max-height:calc(100% - 12px);box-sizing:border-box;
    padding:clamp(16px,4.8vw,24px);padding-bottom:max(16px,env(safe-area-inset-bottom));border-radius:18px 18px 0 0}
}
@media (orientation:landscape) and (max-height:479px) {
  #game .keepsake-receipt:has(.keepsake-offer) .lawn-receipt-actions {grid-template-columns:repeat(2,minmax(0,1fr))}
  #game .keepsake-receipt .lawn-receipt-actions .keepsake-offer {grid-column:auto}
}

/* The new keepsake is framed as a detachable postcard with its actual painted charm. */
#game .keepsake-letter {
 display:block;isolation:isolate;padding:12px 14px 16px;
 background:#fbf4e2;border-radius:6px 17px 7px 16px;
}
#game .keepsake-letter .keepsake-print {
 position:relative;isolation:isolate;display:block;overflow:visible;width:100%;
 height:clamp(90px,17vh,145px);padding:0;margin:0 0 9px;
 border-radius:10px 12px 6px 4px;background:#42694c;
}
#game .keepsake-letter .keepsake-print .keepsake-painting {
 display:block;width:100%;height:100%;object-fit:cover;object-position:50% 41%;border-radius:inherit;
}
#game .keepsake-letter .keepsake-token {
 position:absolute;right:13px;bottom:-5px;display:grid;place-items:center;
 width:clamp(54px,17vw,87px);aspect-ratio:1;transform:rotate(7deg);
 background:radial-gradient(ellipse at 48% 45%,#fff9e6 35%,#ead7a0 95%);
 border-radius:50%;box-shadow:inset 0 0 0 2px #fff7d8,inset 0 0 0 4px #9c784c,0 3px 6px #1c2c284f;
}
#game .keepsake-token img {width:78%;height:78%;object-fit:contain;border-radius:0}
#game .keepsake-letter .lawn-close {
 z-index:2;right:16px;top:14px;color:#fff8df;background:transparent!important;
 text-shadow:0 1px 3px #142d1d;
}
#game .keepsake-letter .lawn-close::before {content:"";position:absolute;z-index:-1;inset:7px;border-radius:50%;background:#244638}
#game .keepsake-letter .lawn-receipt-copy {display:grid;grid-template-columns:1fr auto;align-items:center;gap:0 7px;margin:0;padding:0}
#game .keepsake-letter .lawn-receipt-copy small {grid-column:1/-1;color:#745735}
#game .keepsake-letter .lawn-receipt-copy h2 {margin:1px 0 3px}
#game .keepsake-letter .lawn-prize {display:flex;align-items:center;gap:3px;color:#704122}
#game .keepsake-letter .lawn-prize img {width:24px;height:24px;object-fit:contain}
#game .keepsake-letter .keepsake-story {font-size:15px;line-height:1.57;margin:3px 0 9px}
#game .keepsake-letter .lawn-receipt-actions {gap:4px 8px}
#game .keepsake-letter .lawn-receipt-actions [data-open-postbook] {
 position:relative;justify-content:flex-start;gap:9px;padding:4px 12px;
 border-radius:3px 16px 4px 13px;background:#264f40!important;color:#fff8e4;
}
#game .keepsake-letter [data-open-postbook] img {width:39px;height:39px;object-fit:contain}
#game .keepsake-letter .lawn-receipt-actions [data-lawn-offer] {
 display:grid;grid-template-columns:45px minmax(0,1fr) auto;align-items:center;gap:7px;
 background:#f0e6cd!important;color:#344c3c;text-align:left;padding:6px 8px;border-radius:5px 12px;
}
#game .keepsake-letter .keepsake-gift {width:43px;height:43px;object-fit:contain}
#game .keepsake-letter .lawn-receipt-actions :is([data-lawn-switch],[data-lawn-again],[data-lawn-chapter],[data-lawn-continue]) {
 justify-content:flex-start;gap:4px;padding:3px 5px;background:none!important;color:#2d513f;
 text-decoration:underline;text-underline-offset:3px;text-decoration-color:#b2a27c;
}
#game .keepsake-letter .lawn-receipt-actions :is([data-lawn-switch],[data-lawn-again]) img {width:29px;height:29px;object-fit:contain}
#game .keepsake-selection .selection-heading img {object-fit:contain;border-radius:0;filter:drop-shadow(0 2px 2px #6f58354d)}
@media (max-width:600px) and (min-height:481px) {
 #game .keepsake-letter {inset:auto 5px max(5px,env(safe-area-inset-bottom));width:calc(100% - 10px);max-height:calc(100% - 10px)}
}
@media (orientation:landscape) and (max-height:479px) {
 #game .keepsake-letter {display:grid;grid-template-columns:minmax(100px,.42fr) minmax(0,1fr);gap:4px 12px;align-items:start;padding:10px 13px}
 #game .keepsake-letter .keepsake-print {grid-column:1;grid-row:1/4;height:clamp(98px,44vh,158px);margin:0}
 #game .keepsake-letter .lawn-receipt-copy,#game .keepsake-letter .keepsake-story {grid-column:2}
 #game .keepsake-letter .lawn-receipt-copy {padding-right:34px}
 #game .keepsake-letter .lawn-receipt-actions {grid-column:1/-1}
 #game .keepsake-letter .lawn-close {right:6px;top:5px}
 #game .keepsake-letter .lawn-receipt-actions [data-open-postbook] {grid-column:auto}
}
@media(prefers-reduced-motion:no-preference) {
 #game:not([data-reduce-motion=true]) .keepsake-letter .keepsake-token {animation:keepsake-seal .45s cubic-bezier(.2,.8,.3,1) both}
 @keyframes keepsake-seal {from{transform:translate(4px,-14px) rotate(-8deg) scale(1.08);opacity:.35}70%{transform:translateY(2px) rotate(9deg) scale(.96)}to{transform:rotate(7deg)}}
}
