/* Demo room: a scripted bidding war on the stage display and a guest's phone.
   Both surfaces are built at a fixed design size and scaled to fit (demo-room.js sets --s). */
.room { position: relative; margin: 0; }
.room-scene { position: relative; padding-bottom: 40%; padding-left: 9%; }
.room-stage-box, .room-phone-box { position: relative; }
.room-stage-box { aspect-ratio: 1200 / 675; border-radius: 14px; overflow: hidden; box-shadow: 0 30px 60px -28px rgba(26, 24, 20, .55), 0 0 0 1px rgba(26, 24, 20, .12); }
.room-phone-box { width: 34%; max-width: 300px; aspect-ratio: 320 / 660; position: absolute; left: 0; bottom: 0; border-radius: 32px;
  box-shadow: 0 28px 50px -18px rgba(26, 24, 20, .6), 0 0 0 1px rgba(26, 24, 20, .25); }
.room-stage, .room-phone { position: absolute; top: 0; left: 0; transform-origin: 0 0; transform: scale(var(--s, 1)); }
.room-foot { display: flex; align-items: center; gap: 14px; margin-top: 16px; font-size: 13px; color: var(--ink-3); }
.room-toggle { display: inline-flex; align-items: center; gap: 8px; min-height: 36px; padding: 0 12px; border: 1px solid var(--line); border-radius: 999px;
  background: var(--card); color: var(--ink); font: 600 13px/1 var(--sans); cursor: pointer; flex: none; }
.room-toggle:hover { background: var(--paper-2); }
.room-toggle:focus-visible { outline: 3px solid var(--marigold); outline-offset: 2px; }
.room-toggle svg { width: 12px; height: 12px; fill: currentColor; }

/* ---------- Stage (1200 x 675) ---------- */
.room-stage { width: 1200px; height: 675px; color: #F5F0E6; font-family: var(--sans);
  background: radial-gradient(120% 90% at 55% 40%, #2a251c 0%, #16140F 62%); }
.st-top { position: absolute; left: 40px; right: 40px; top: 22px; height: 30px; display: flex; align-items: center; gap: 16px; }
.st-brand { font: 700 24px/1 var(--serif); letter-spacing: -.02em; }
.st-brand i { font-style: normal; color: var(--marigold); }
.st-event { padding-left: 16px; border-left: 1px solid #4a443a; font-size: 16px; font-weight: 500; letter-spacing: .14em; text-transform: uppercase; color: #d9d1bf; }
.st-live { margin-left: auto; padding: 6px 14px; border-radius: 999px; background: #2e2a22; font-size: 13px; font-weight: 700; letter-spacing: .12em; }
.st-live.closed { background: #4a443a; color: #d9d1bf; }
.st-photo { position: absolute; left: 38px; top: 68px; width: 382px; height: 445px; border-radius: 20px; overflow: hidden; background: #3a3428; }
.st-photo img { width: 100%; height: 100%; object-fit: cover; }
.st-tag { position: absolute; left: 0; top: 20px; padding: 7px 14px; border-radius: 0 12px 12px 0; background: #F5F0E6; color: #1A1814; font: 600 17px/1.2 var(--serif); }
.st-main { position: absolute; left: 456px; top: 108px; width: 390px; }
.st-cat { display: inline-block; padding: 5px 12px; border-radius: 999px; background: #3a352c; font-size: 13px; font-weight: 700; letter-spacing: .12em; }
.st-title { margin-top: 14px; font: 600 46px/1.08 var(--serif); letter-spacing: -.02em; }
.st-prov { margin-top: 10px; font-size: 16px; color: #b3aa96; }
.st-label { margin-top: 18px; font-size: 13px; font-weight: 700; letter-spacing: .12em; color: #d9d1bf; }
.st-price { font: 700 104px/1 var(--sans); letter-spacing: -.045em; color: var(--marigold); font-variant-numeric: tabular-nums; transform-origin: 0 60%; }
.st-price.bump { animation: bump .7s cubic-bezier(.2, .9, .3, 1.3); }
@keyframes bump { 0% { transform: scale(1); } 30% { transform: scale(1.09); color: #fff3cf; } 100% { transform: scale(1); } }
.st-lead { margin-top: 14px; font-size: 20px; color: #e8e0cf; }
.st-lead b { font-weight: 700; color: #fff; }
.st-close { margin-top: 10px; font-size: 18px; color: #b3aa96; }
.st-close b { color: #fff; font-variant-numeric: tabular-nums; }
.st-close.hot b { color: #ff9b80; }
.st-qr { position: absolute; right: 38px; top: 110px; width: 288px; height: 360px; border-radius: 22px; background: #F5F0E6; color: #1A1814; text-align: center; padding-top: 26px; }
.st-qr-k { font-size: 12px; font-weight: 700; letter-spacing: .14em; }
.st-qr-code { width: 204px; height: 204px; margin: 14px auto 0; padding: 14px; border-radius: 10px; background: #fff; }
.st-qr-code svg { width: 100%; height: 100%; display: block; }
.st-qr-url { margin-top: 14px; font-size: 13px; color: #5A5448; }
.st-qr-url b { color: #1A1814; }
.st-qr-cd { margin-top: 2px; font: 700 40px/1.1 var(--sans); letter-spacing: .12em; }
.st-stats { position: absolute; left: 38px; right: 38px; top: 528px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.st-stat { height: 74px; padding: 12px 20px; border-radius: 14px; background: #2a261f; }
.st-stat span { display: block; font-size: 11px; font-weight: 700; letter-spacing: .12em; color: #b3aa96; }
.st-stat b { display: block; margin-top: 4px; font-size: 30px; font-weight: 700; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.st-ticker { position: absolute; left: 38px; right: 38px; top: 614px; height: 44px; border-radius: 12px; background: #1f1c16; display: flex; align-items: center; overflow: hidden; }
.st-ticker-k { flex: none; margin: 0 18px 0 16px; padding: 4px 10px; border-radius: 6px; background: var(--marigold); color: #1A1814; font-size: 11px; font-weight: 800; letter-spacing: .12em; }
.st-ticker-row { display: flex; gap: 30px; white-space: nowrap; font-size: 16px; color: #d9d1bf; }
.st-ticker-row span { transition: opacity .4s; }
.st-ticker-row b { color: #fff; }
.st-ticker-row em { font-style: normal; font-weight: 700; color: var(--marigold); }
.st-ticker-row .new { animation: tickIn .6s ease-out; }
@keyframes tickIn { from { opacity: 0; transform: translateX(-24px); } to { opacity: 1; transform: none; } }
.st-sold { position: absolute; left: 456px; top: 108px; width: 390px; opacity: 0; pointer-events: none; transition: opacity .5s; }
.room-stage.is-closed .st-main { opacity: 0; transition: opacity .4s; }
.room-stage.is-closed .st-sold { opacity: 1; }
.st-sold .st-title { margin-top: 0; }
.st-sold-k { display: inline-block; padding: 6px 14px; border-radius: 999px; background: var(--marigold); color: #1A1814; font-size: 13px; font-weight: 800; letter-spacing: .14em; margin-bottom: 18px; }
.st-sold-p { margin-top: 18px; font: 700 96px/1 var(--sans); letter-spacing: -.045em; color: var(--marigold); }
.st-sold-w { margin-top: 14px; font-size: 22px; color: #e8e0cf; }
.st-sold-w b { color: #fff; }

/* ---------- Phone (320 x 660) ---------- */
.room-phone { width: 320px; height: 660px; border-radius: 32px; overflow: hidden; background: #F5F0E6; color: #1A1814; font-family: var(--sans);
  border: 7px solid #1A1814; }
.ph-status { height: 30px; display: flex; align-items: center; justify-content: space-between; padding: 6px 20px 0; font-size: 12px; font-weight: 700; }
.ph-status i { width: 22px; height: 10px; border: 1.5px solid #1A1814; border-radius: 3px; position: relative; }
.ph-status i::after { content: ""; position: absolute; inset: 1.5px 5px 1.5px 1.5px; background: #1A1814; border-radius: 1px; }
.ph-head { height: 40px; display: flex; align-items: center; gap: 8px; padding: 0 12px; }
.ph-back { font-size: 13px; font-weight: 600; }
.ph-ev { flex: 1; text-align: center; font: 600 14px/1 var(--serif); }
.ph-av { width: 28px; height: 28px; border-radius: 50%; background: var(--marigold); display: grid; place-items: center; font-size: 10px; font-weight: 700; border: 1.5px solid #1A1814; }
.ph-photo { height: 150px; position: relative; overflow: hidden; }
.ph-photo img { width: 100%; height: 100%; object-fit: cover; }
.ph-photo .tag { position: absolute; left: 0; top: 12px; padding: 4px 10px; border-radius: 0 8px 8px 0; background: #F5F0E6; font: 600 13px/1.1 var(--serif); }
.ph-body { padding: 12px 14px 0; }
.ph-prov { font-size: 11px; color: #5A5448; }
.ph-prov b { color: #1A1814; }
.ph-title { margin-top: 4px; font: 600 23px/1.08 var(--serif); letter-spacing: -.02em; }
.ph-banner { margin-top: 12px; min-height: 56px; display: flex; gap: 10px; align-items: center; padding: 10px 12px; border-radius: 12px; border-left: 4px solid; transition: background-color .35s, border-color .35s, color .35s; }
.ph-banner .dot { flex: none; width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; color: #fff; font-size: 14px; font-weight: 800; transition: background-color .35s; }
.ph-banner b { display: block; font-size: 14px; }
.ph-banner span { display: block; font-size: 11.5px; line-height: 1.35; color: #5A5448; }
.ph-banner.lead { background: #DCEEE3; border-color: #12724A; } .ph-banner.lead .dot { background: #12724A; }
.ph-banner.out { background: #F8DDD4; border-color: #C93A1B; } .ph-banner.out .dot { background: #C93A1B; } .ph-banner.out b { color: #9e2c12; }
.ph-banner.won { background: #FCEFC9; border-color: #F2B632; } .ph-banner.won .dot { background: #1A1814; color: var(--marigold); }
.ph-banner.shake { animation: shake .5s; }
@keyframes shake { 20%, 60% { transform: translateX(-5px); } 40%, 80% { transform: translateX(5px); } }
.ph-card { margin-top: 10px; display: grid; grid-template-columns: 1fr auto; border-radius: 14px; background: #FFFCF5; box-shadow: 0 1px 0 #D9D0BE, 0 6px 16px -10px rgba(26,24,20,.4); }
.ph-card > div { padding: 10px 12px; }
.ph-card > div + div { border-left: 1.5px dashed #D9D0BE; }
.ph-k { font-size: 9.5px; font-weight: 700; letter-spacing: .1em; color: #5A5448; }
.ph-amt { font-size: 32px; font-weight: 700; letter-spacing: -.035em; font-variant-numeric: tabular-nums; line-height: 1.1; }
.ph-who { font-size: 11px; color: #5A5448; } .ph-who b { color: #1A1814; }
.ph-time { font-size: 17px; font-weight: 700; font-variant-numeric: tabular-nums; }
.ph-time.hot { color: #C93A1B; }
.ph-k-gap { margin-top: 6px; }
.ph-step { font-weight: 700; }
.ph-cta { position: absolute; left: 14px; right: 14px; bottom: 16px; }
.ph-btn { width: 100%; height: 46px; border: 0; border-radius: 12px; background: #2338C7; color: #fff; font: 700 15px/1 var(--sans); transition: transform .12s, background-color .2s, opacity .3s; }
.ph-btn.press { transform: scale(.96); background: #1A2BA3; }
.ph-btn[hidden] { display: none; }
.ph-sheet { position: absolute; left: 0; right: 0; bottom: 0; padding: 14px 16px 18px; border-radius: 20px 20px 0 0; background: #FFFCF5;
  box-shadow: 0 -12px 30px -10px rgba(26,24,20,.45); transform: translateY(105%); transition: transform .38s cubic-bezier(.2,.8,.2,1); }
.ph-sheet.open { transform: none; }
.ph-scrim { position: absolute; inset: 0; background: rgba(26,24,20,.35); opacity: 0; transition: opacity .3s; pointer-events: none; }
.ph-scrim.open { opacity: 1; }
.ph-grab { width: 36px; height: 4px; border-radius: 2px; background: #D9D0BE; margin: 0 auto 12px; }
.ph-sheet h4 { margin: 0; font: 600 17px/1.2 var(--serif); }
.ph-sheet p { margin: 4px 0 12px; font-size: 11.5px; color: #5A5448; }
.ph-sheet .amt { display: flex; align-items: center; justify-content: space-between; height: 54px; padding: 0 14px; border: 1.5px solid #2338C7; border-radius: 12px; margin-bottom: 12px; }
.ph-sheet .amt b { font-size: 26px; letter-spacing: -.03em; }
.ph-sheet .amt span { font-size: 11px; color: #5A5448; }
.ph-send { display: inline-flex; align-items: center; gap: 8px; }
.ph-spin { width: 14px; height: 14px; border-radius: 50%; border: 2px solid rgba(255,255,255,.4); border-top-color: #fff; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.ph-toast { position: absolute; left: 12px; right: 12px; top: 34px; padding: 10px 12px; border-radius: 12px; background: #1A1814; color: #F5F0E6; font-size: 12px; line-height: 1.35;
  display: flex; gap: 8px; align-items: center; transform: translateY(-260%); transition: transform .35s cubic-bezier(.2,.8,.2,1); }
.ph-toast.show { transform: none; }
.ph-toast b { color: #ff9b80; }

/* ---------- Phone width: the guest's phone leads, the screen sits behind it ---------- */
@media (max-width: 759px) {
  .room-scene { padding: 0; }
  .room-stage-box { border-radius: 10px; width: 100%; }
  .room-phone-box { position: relative; right: auto; bottom: auto; width: min(72%, 280px); margin: -8% auto 0; border-radius: 30px; }
  .room-foot { justify-content: center; text-align: center; flex-wrap: wrap; }
}

@media (prefers-reduced-motion: reduce) {
  .room *, .room *::before, .room *::after { animation: none !important; transition: none !important; }
}
