body { background-image: radial-gradient(circle at 12% 18%, #b89b5520 1px, transparent 2px), radial-gradient(circle at 75% 64%, #b89b5520 1px, transparent 2px); background-size: 85px 85px, 120px 120px; }
.winter-branches { position: absolute; top: 95px; left: 0; width: 130px; height: 150px; color: var(--gold); font-size: 32px; text-align: center; z-index: -1; background: url('branches.svg') center / contain no-repeat; }
.intro { position: relative; }
.intro .progress { font-size: .85rem; margin: 12px auto; }
.motion-choice { font-size: .8rem; color: var(--muted); cursor: pointer; }
.motion-choice input { accent-color: var(--green); }
.door { position: relative; overflow: hidden; perspective: 800px; box-shadow: 0 8px 20px #213f3508; }
.door-panel { width: 100%; border: 1px solid #a5814630; border-radius: 90px 90px 8px 8px; padding: 14px 0 6px; background: #faf7f0; transform-origin: left center; transition: transform .65s ease, opacity .65s ease; backface-visibility: hidden; }
.door.opening .door-panel { transform: rotateY(-105deg); opacity: .2; }
.door-star { color: var(--gold); }
.seen { font-size: .7rem; color: #526e3b; margin-bottom: 8px; }
.seen[hidden] { display: none; }
.today { outline: 2px solid var(--gold); outline-offset: 3px; }
.today-label { background: #a58146; color: white; padding: 3px 14px; border-radius: 20px; font-size: .7rem; margin-bottom: 10px; }
.open-door { margin-top: auto; padding-top: 12px; }
.open-door button { font-size: .8rem; }
button:disabled { opacity: .6; cursor: wait; }
.preview { width: 100%; height: 100px; object-fit: cover; border-radius: 6px; margin-bottom: 12px; }
.calendar .christmas { grid-column: span 2; background: var(--green); color: #fff6df; border: 2px solid var(--gold); }
.christmas .door-panel { max-width: 240px; background: #ffffff08; border-color: #bd9a5c80; }
.christmas .number, .christmas .seen, .christmas .locked, .christmas p { color: #f3e5c7; }
.christmas .open { background: #e1c38c; color: #213f35; }
.christmas-label { color: #e1c38c; font-family: Georgia, serif; font-size: 1.2rem; margin-top: 8px; }
dialog { position: fixed; width: min(820px, calc(100% - 28px)); max-height: 90dvh; padding: 28px; border: 1px solid var(--gold); border-radius: 18px; color: var(--green); background: var(--paper); box-shadow: 0 20px 100px #0005; overflow-y: auto; }
dialog::backdrop { background: #10271ed4; backdrop-filter: blur(5px); }
body:has(dialog[open]) { overflow: hidden; }
.dialog-close { display: flex; justify-content: flex-end; position: sticky; top: 0; z-index: 2; }
.dialog-close button { padding: 8px 14px; border-radius: 50%; }
.surprise { text-align: center; overflow-wrap: anywhere; }
.surprise h1 { font-size: clamp(1.8rem, 5vw, 3rem); }
.personal-message { max-width: 580px; margin: 24px auto; font-family: Georgia, serif; font-size: 1.2rem; line-height: 1.8; }
.surprise-image, .surprise video { display: block; max-width: 100%; max-height: 65vh; margin: 24px auto; border-radius: 10px; }
.download-link { display: inline-block; margin: 20px 0; font-size: .9rem; text-underline-offset: 4px; }
.audio-card { padding: 30px 16px; border-radius: 12px; background: #e7eddf; }
.audio-card > span { font-size: 3rem; color: var(--gold); }
audio { width: 100%; max-width: 480px; }
.coupon { padding: 30px; border: 2px dashed var(--gold); border-radius: 16px; background: #f3ead7; }
.puzzle { text-align: left; padding: 20px; border: 1px solid #b7c2ad; border-radius: 10px; margin: 20px auto; }
.puzzle summary { cursor: pointer; font-weight: 600; }
.gallery { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; margin-top: 24px; }
.gallery figure { margin: 0; background: white; padding: 10px; box-shadow: 0 3px 12px #213f3510; }
.gallery img { display: block; width: 100%; height: auto; border-radius: 4px; }
.gallery figcaption { padding: 12px 0 4px; font-family: Georgia, serif; }
.christmas-greeting { color: #8b682c; font-family: Georgia, serif; font-size: 1.4rem; }
.christmas-surprise { border: 1px solid #b89b5570; border-radius: 10px; padding: 20px; background: radial-gradient(ellipse at top, #e6c88c30, transparent 65%); }
.detail-page { max-width: 900px; padding: 40px 24px; margin: auto; }
#calendar-error { text-align: center; color: #9b2727; padding: 20px; }
.star-shower { position: absolute; inset: 0; pointer-events: none; overflow: hidden; z-index: 3; }
.star-shower span { position: absolute; top: -40px; color: #b99643; font-size: 22px; animation: star-fall 1.6s ease-in both; }
@keyframes star-fall { from { transform: translateY(0) rotate(0); opacity: 0; } 15% { opacity: 1; } to { transform: translateY(600px) rotate(180deg); opacity: 0; } }
@media(max-width:680px) { dialog { padding: 16px; } .winter-branches { opacity: .4; width: 80px; } .gallery { grid-template-columns: 1fr; } .christmas-surprise { padding: 12px; } }
@media(max-width:360px) { .calendar .christmas { grid-column: auto; } }
@media(prefers-reduced-motion:reduce) { *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; } }
