/* The holiday events (26 Oct 2026; _holiday.html, holiday.js): the tile countdown, the daily gift, the flash sale line
   and box, the gift opening, the auction. Each event sets --hol-accent, --hol-accent2, --hol-paper and --hol-ink. */

.hol-cd { --tile-w: 26px; display: inline-flex; flex-direction: column; align-items: flex-start; gap: 0.3rem; margin: 0.9rem 0 0.2rem;
  padding: 0.55rem 0.8rem 0.6rem; border-radius: 14px; background: var(--hol-paper, #f6f2e8); color: var(--hol-ink, #232019);
  border: 1px solid color-mix(in srgb, var(--hol-accent, #1e5391) 30%, transparent); max-width: 100%; box-sizing: border-box; }
.hol-cd.hol-big { --tile-w: 32px; align-self: center; align-items: center; }
.ph-stack .hol-cd, .ph-stack .hol-gift, .ph-stack .hol-sale-line { align-self: stretch; width: auto; }
.ph-stack .hol-cd { align-items: center; text-align: center; }
.hol-cd-label { margin: 0; font: 700 max(0.95rem, var(--fine-min, 0px))/1.2 var(--display); color: var(--hol-accent, #1e5391); }
.hol-clock { display: flex; flex-wrap: nowrap; align-items: flex-start; gap: 0.6rem; }
.hol-group { display: inline-flex; flex-direction: column; align-items: center; gap: 2px; }
.hol-digits { display: inline-flex; gap: 2px; }
.hol-unit { text-align: center; font-size: max(0.78rem, var(--fine-min, 0px)); line-height: 1.1; color: var(--hol-ink, #232019); opacity: 0.8; }
.hol-tile { display: inline-block; width: var(--tile-w); aspect-ratio: 100 / 140; perspective: 300px; }
.hol-tile img { display: block; width: 100%; height: 100%; filter: drop-shadow(0 2px 0 rgba(60, 45, 25, 0.25)); backface-visibility: hidden; }
.hol-tile.hol-flipping img { animation: hol-flip 520ms ease-in-out; }
@keyframes hol-flip { 0% { transform: rotateX(0); } 50% { transform: rotateX(90deg); } 100% { transform: rotateX(0); } }
.hol-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.hol-cd-message { margin: 0; font: 700 1.05rem/1.3 var(--display); color: var(--hol-ink, #232019); max-width: 34ch; }
.hol-cd.hol-zero .hol-clock, .hol-cd.hol-zero .hol-cd-label { display: none; }
.hol-notify { margin-top: 0.2rem; }
.hol-notify .button { min-height: 40px; padding: 0.35rem 0.9rem; font-size: max(0.95rem, var(--fine-min, 0px)); }
.hol-notify form { display: flex; gap: 0.4rem; flex-wrap: wrap; }
.hol-notify input[type=email] { min-height: 40px; padding: 0 0.6rem; border: 1px solid var(--line, #d9cfb8); border-radius: 10px; font: inherit; font-size: max(0.95rem, var(--fine-min, 0px)); min-width: 0; flex: 1 1 12rem; }
.hol-notify p { margin: 0.2rem 0 0; font-size: max(0.95rem, var(--fine-min, 0px)); }

/* the celebration at zero, once: small tiles fall and fade (none with reduced motion) */
.hol-burst { position: fixed; inset: 0; pointer-events: none; z-index: 60; overflow: hidden; }
.hol-burst span { position: absolute; top: -60px; width: 26px; aspect-ratio: 100 / 140; background: center / contain no-repeat;
  animation: hol-fall 2.6s cubic-bezier(.2, .6, .4, 1) forwards; }
@keyframes hol-fall { to { transform: translateY(110vh) rotate(var(--spin, 200deg)); opacity: 0.2; } }

/* --- the daily gift ----------------------------------------------------------------------------------------------- */
.hol-gift { display: flex; align-items: center; gap: 0.7rem; flex-wrap: wrap; margin: 0.6rem 0; padding: 0.55rem 0.8rem;
  border-radius: 14px; background: var(--hol-paper, #f6f2e8); color: var(--hol-ink, #232019);
  border: 1px solid color-mix(in srgb, var(--hol-accent, #1e5391) 30%, transparent); max-width: 100%; box-sizing: border-box; }
.hol-gift-icon { width: 46px; height: 46px; flex: none; }
.hol-gift-words { display: flex; flex-direction: column; gap: 0.1rem; min-width: 0; flex: 1 1 14rem; }
.hol-gift-words b { font: 700 1rem/1.2 var(--display); color: var(--hol-accent, #1e5391); }
.hol-gift-words span { font-size: max(0.92rem, var(--fine-min, 0px)); }
.hol-gift .button { min-height: 44px; }
.hol-gift .button.hol-open { background: var(--hol-accent, #1e5391); border-color: var(--hol-accent, #1e5391); color: #fff; }
.hol-days { display: inline-flex; gap: 4px; margin-top: 0.15rem; }
.hol-days i { width: 10px; height: 10px; border-radius: 50%; border: 2px solid var(--hol-accent, #1e5391); box-sizing: border-box; }
.hol-days i.on { background: var(--hol-accent, #1e5391); }
.hol-days i.today { box-shadow: 0 0 0 2px var(--hol-accent2, #c9a227); }
.hol-prizes { display: flex; flex-wrap: wrap; gap: 0.3rem; margin-top: 0.2rem; }
.hol-chip { display: inline-flex; align-items: center; gap: 0.3rem; padding: 0.1rem 0.5rem 0.1rem 0.2rem; border-radius: 999px;
  background: #fff; border: 1px solid var(--line, #d9cfb8); font-size: max(0.82rem, var(--fine-min, 0px)); font-weight: 700; color: var(--ink, #232019); }
.hol-coin { width: 16px; height: 16px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, #ffe9a3, #e0a82e 55%, #a8740f); flex: none;
  box-shadow: inset 0 0 0 1.5px rgba(120, 80, 10, 0.5); }
.hol-swatch { width: 18px; height: 18px; border-radius: 5px; flex: none; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.25); }
.hol-swatch.back { width: 14px; height: 19px; border-radius: 3px; }
.hol-gift .account-offer-buttons { display: inline-flex; flex-wrap: wrap; gap: 0.4rem; }

/* --- the gift opening ----------------------------------------------------------------------------------------------- */
.hol-modal { position: fixed; inset: 0; z-index: 70; display: grid; place-items: center; background: rgba(20, 14, 8, 0.55); padding: 16px; }
.hol-modal-box { position: relative; width: min(420px, 100%); box-sizing: border-box; padding: 1.3rem 1.2rem 1.1rem; border-radius: 20px; text-align: center;
  background: var(--hol-paper, #f6f2e8); color: var(--hol-ink, #232019); box-shadow: 0 20px 50px rgba(0, 0, 0, 0.35); }
.hol-modal-box h2 { margin: 0 0 0.6rem; font-size: 1.35rem; color: var(--hol-accent, #1e5391); }
.hol-box { position: relative; width: 132px; height: 120px; margin: 0.4rem auto 0.8rem; }
.hol-box .body { position: absolute; left: 10px; right: 10px; bottom: 0; height: 78px; border-radius: 8px; background: var(--hol-accent, #1e5391);
  box-shadow: inset 0 -10px 0 rgba(0, 0, 0, 0.15); }
.hol-box .lid { position: absolute; left: 2px; right: 2px; top: 22px; height: 26px; border-radius: 7px; background: var(--hol-accent, #1e5391);
  box-shadow: inset 0 -6px 0 rgba(0, 0, 0, 0.18); transform-origin: 20% 100%; }
.hol-box .ribbon { position: absolute; left: 58px; width: 16px; top: 22px; bottom: 0; background: var(--hol-accent2, #c9a227); }
.hol-box .bow { position: absolute; left: 44px; top: 4px; width: 44px; height: 22px; border-radius: 50% 50% 8px 8px; border: 6px solid var(--hol-accent2, #c9a227); box-sizing: border-box; }
.hol-box.shake { animation: hol-shake 640ms ease-in-out; }
.hol-box.open .lid, .hol-box.open .bow, .hol-box.open .ribbon { animation: hol-lid 520ms ease-out forwards; }
@keyframes hol-shake { 0%, 100% { transform: rotate(0); } 20% { transform: rotate(-7deg); } 40% { transform: rotate(6deg); } 60% { transform: rotate(-4deg); } 80% { transform: rotate(3deg); } }
@keyframes hol-lid { to { transform: translate(18px, -60px) rotate(28deg); opacity: 0; } }
.hol-prize { display: flex; flex-direction: column; align-items: center; gap: 0.4rem; animation: hol-pop 420ms cubic-bezier(.2, 1.4, .4, 1); }
.hol-prize .big-coin { width: 64px; height: 64px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, #fff1bf, #e9b23b 55%, #a8740f);
  box-shadow: inset 0 0 0 4px rgba(120, 80, 10, 0.45), 0 6px 14px rgba(0, 0, 0, 0.25); }
.hol-prize .amount { font: 800 2rem/1 var(--display); color: var(--hol-ink, #232019); }
.hol-prize .item-art { width: 120px; height: 80px; border-radius: 12px; box-shadow: inset 0 0 0 2px rgba(0, 0, 0, 0.2), 0 6px 14px rgba(0, 0, 0, 0.25); }
.hol-prize .item-art.back { width: 64px; height: 90px; }
.hol-prize .name { font: 700 1.15rem/1.2 var(--display); }
.hol-prize .trophy-line { font-weight: 700; color: var(--hol-accent, #1e5391); }
.hol-modal-box .actions { display: flex; flex-wrap: wrap; gap: 0.5rem; justify-content: center; margin-top: 0.9rem; }
.hol-modal-box .hol-days { justify-content: center; margin-top: 0.6rem; }
.hol-modal-box .preview-note { font-size: max(0.85rem, var(--fine-min, 0px)); opacity: 0.75; margin: 0.4rem 0 0; }
@keyframes hol-pop { from { transform: scale(0.4); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.hol-fly { position: fixed; z-index: 80; width: 18px; height: 18px; border-radius: 50%; pointer-events: none;
  background: radial-gradient(circle at 35% 30%, #fff1bf, #e9b23b 55%, #a8740f); transition: transform 800ms cubic-bezier(.5, -0.2, .7, 1), opacity 800ms; }

/* --- the flash sale ------------------------------------------------------------------------------------------------ */
.hol-sale-line { display: flex; flex-wrap: wrap; align-items: center; gap: 0.3rem 0.7rem; margin: 0.6rem 0; padding: 0.4rem 0.75rem; border-radius: 12px;
  background: #fff4e0; border: 1px solid #e8c48a; font-size: max(0.95rem, var(--fine-min, 0px)); }
.hol-sale-line a { color: var(--ink, #232019); }
.hol-sale-ends { display: inline-flex; align-items: center; gap: 0.35rem; font-size: max(0.9rem, var(--fine-min, 0px)); color: var(--ink-soft, #5c5445); }
.hol-mini { display: inline-flex; gap: 1px; align-items: flex-end; }
.hol-mini .hol-tile { --tile-w: 20px; }
.hol-mini .sep { font-weight: 700; padding: 0 1px; }
.hol-sale-box { margin: 0.8rem 0; padding: 0.7rem 0.9rem; border-radius: 14px; background: #fff4e0; border: 1px solid #e8c48a; }
.hol-sale-box h2 { margin: 0 0 0.2rem; font-size: 1.2rem; }
.hol-sale-box ul { list-style: none; margin: 0.4rem 0 0; padding: 0; display: grid; gap: 0.2rem; }
.hol-sale-box li { display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: baseline; }
.hol-sale-box s { color: var(--ink-soft, #5c5445); }
.hol-sale-box em { font-style: normal; font-size: max(0.9rem, var(--fine-min, 0px)); color: #9a4a12; }
.shop-card .sale-was { margin: 0; font-size: max(0.85rem, var(--fine-min, 0px)); color: #9a4a12; font-weight: 700; }

/* --- the auction ---------------------------------------------------------------------------------------------------- */
.auction { max-width: 1100px; margin: 0 auto; padding: 1rem 16px 2rem; box-sizing: border-box; }
.auction-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 0.6rem; }
.auction-head p { margin: 0.2rem 0; }
.auction-lots { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 1rem; margin-top: 1rem; }
.lot { margin: 0; max-width: none; display: flex; flex-direction: column; gap: 0.45rem; padding: 0.9rem; border-radius: 16px; background: var(--card, #fffdf8);
  border: 1px solid var(--line, #d9cfb8); box-shadow: var(--shadow-sm); }
.lot.leading { border-color: #2f8a52; box-shadow: 0 0 0 2px #2f8a52 inset; }
.lot .lot-art { height: 110px; border-radius: 12px; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.2); }
.lot h3 { margin: 0; font-size: 1.1rem; }
.lot .top { font: 700 1.3rem/1.1 var(--display); }
.lot .who { font-size: max(0.92rem, var(--fine-min, 0px)); margin: 0; }
.lot .who.mine { color: #1f6b3a; font-weight: 700; }
.lot .clock { font-size: max(0.92rem, var(--fine-min, 0px)); color: var(--ink-soft, #5c5445); display: flex; align-items: center; gap: 0.35rem; flex-wrap: wrap; }
.lot form { display: flex; gap: 0.4rem; flex-wrap: wrap; }
.lot input[type=number] { flex: 1 1 7rem; min-width: 0; min-height: 44px; padding: 0 0.6rem; border: 1px solid var(--line, #d9cfb8); border-radius: 10px; font: inherit; }
.lot .button { min-height: 44px; }
.lot .recent { margin: 0; padding: 0; list-style: none; font-size: max(0.85rem, var(--fine-min, 0px)); color: var(--ink-soft, #5c5445); }
.lot .msg { margin: 0; font-size: max(0.92rem, var(--fine-min, 0px)); color: #9a2a12; }
.auction-toast { position: fixed; left: 50%; bottom: 20px; transform: translateX(-50%); z-index: 70; padding: 0.7rem 1rem; border-radius: 12px;
  background: #232019; color: #fff; max-width: calc(100% - 32px); box-sizing: border-box; }

@media (prefers-reduced-motion: reduce) {
  .hol-tile.hol-flipping img, .hol-box.shake, .hol-box.open .lid, .hol-box.open .bow, .hol-box.open .ribbon, .hol-prize, .hol-burst span { animation: none !important; }
  .hol-fly { transition: none !important; }
}

/* on the phone's first screen (a grid of two columns): each part takes the whole row, in the site's reading font */
.hol-cd, .hol-gift, .hol-sale-line, .hol-sale-box { font-family: var(--font); }
.phone-home .ph-stack > .hol-cd, .phone-home .ph-stack > .hol-gift, .phone-home .ph-stack > .hol-sale-line {
  grid-column: 1 / -1; width: min(420px, 100%); justify-self: center; margin: 0; }
.phone-home .ph-stack > .hol-gift { gap: 0.5rem 0.7rem; }
.phone-home .hol-gift-words b { font-size: max(0.98rem, var(--fine-min, 0px)); }
.phone-home .hol-chip { font-size: max(0.78rem, var(--fine-min, 0px)); }
.phone-home .hol-gift .hol-gift-act { flex: 1 1 100%; display: flex; }
.phone-home .hol-gift .hol-gift-act .button { flex: 1; }
.hol-lobby { max-width: 1100px; margin: 0 auto; padding: 0 16px; box-sizing: border-box; display: flex; flex-wrap: wrap; gap: 0 1rem; align-items: flex-start; }
.hol-mini .hol-group { gap: 0; }
.hol-mini .hol-unit { font-size: max(0.66rem, var(--fine-min, 0px)); }
.hol-mini { gap: 0.35rem; }
/* the shop's page is dark: the sale box keeps its own ink */
.shop .hol-sale-box, .shop .hol-sale-box h2, .shop .hol-sale-box li, .shop .hol-sale-box p { color: #3a2412; text-shadow: none; }
.shop .hol-sale-box ul { display: grid; gap: 0.25rem; }
.shop .hol-sale-box li { display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: baseline; margin: 0; padding: 0; background: none; border: 0; }
.shop .hol-sale-box s { color: #7a6a55; }
/* an event's painted picture (theme.art, e.g. the Thanksgiving set's harvest banner) as a band along the top */
.hol-gift.hol-has-art { position: relative; padding-top: 3.1rem; overflow: hidden; }
.hol-gift.hol-has-art::before, .hol-modal-box.hol-has-art::before { content: ""; position: absolute; left: 0; right: 0; top: 0;
  height: 2.6rem; background: var(--hol-art) center 40% / cover no-repeat; pointer-events: none; }
.hol-modal-box.hol-has-art { overflow: hidden; padding-top: 6.2rem; }
.hol-modal-box.hol-has-art::before { height: 5.4rem; }
