/* BuildMyPlace end-cap screen. Designed on a fixed 1920x1080 stage that is
   scaled to whatever the TV browser reports, so every TV looks the same. */
:root {
  --navy: #0a3a63;
  --navy-2: #13507f;
  --navy-ink: #13263a;
  --sky: #5aa8ff;
  --pale: #a9c8e8;
  --white: #ffffff;
  --paper: #f4f7fb;
  --sale: #c8102e;
  --font: "Public Sans", Roboto, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
}

.stage.blackout { background: #000; }
.stage.blackout .band,
.stage.blackout .zone,
.stage.blackout .foot,
.stage.blackout #notice,
.stage.blackout #ticker { visibility: hidden; }

html, body { margin: 0; height: 100%; background: #000; overflow: hidden; cursor: none; }
body { font-family: var(--font); color: var(--navy-ink); -webkit-font-smoothing: antialiased; }

.stage {
  position: absolute; left: 0; top: 0; width: 1920px; height: 1080px;
  transform-origin: 0 0; background: var(--navy); overflow: hidden;
}

/* ---- template: band-left (band 480px on the left, media 1440x1080) ---- */
.t-band-left .band { position: absolute; left: 0; top: 0; width: 480px; height: 1080px; }
.t-band-left .zone { position: absolute; left: 480px; top: 0; width: 1440px; height: 1080px; }

/* ---- template: band-bottom (media 1920x860 on top, band 220px below) ---- */
.t-band-bottom .band { position: absolute; left: 0; bottom: 0; width: 1920px; height: 220px; }
.t-band-bottom .zone { position: absolute; left: 0; top: 0; width: 1920px; height: 860px; }

/* ---- template: portrait (stage 1080x1920: band 300 on top, media 1080x1300, foot 320 below) ---- */
.foot { display: none; }
.t-portrait .band { position: absolute; left: 0; top: 0; width: 1080px; height: 300px; flex-direction: row; align-items: center; padding: 0 56px; gap: 48px; }
.t-portrait .zone { position: absolute; left: 0; top: 300px; width: 1080px; height: 1300px; }
.t-portrait .foot { display: flex; position: absolute; left: 0; bottom: 0; width: 1080px; height: 320px; box-sizing: border-box;
  background: var(--navy); color: var(--white); align-items: center; gap: 40px; padding: 0 56px; z-index: 2; }
.t-portrait .aisle .num { font-size: 200px; }
.t-portrait .aisle .label { font-size: 22px; }
.t-portrait .mid { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 14px; }
.t-portrait .category { font-size: 64px; }
.t-portrait .brand { font-size: 26px; }
.t-portrait .brand small { display: inline; margin: 0 0 0 10px; font-size: 16px; }
.t-portrait .foot .offer { flex: 1; font-size: 44px; padding: 26px 30px; }
.t-portrait .foot .qr { flex-direction: column; gap: 10px; align-items: center; text-align: center; }
.t-portrait .foot .qr .code { width: 170px; height: 170px; }
.t-portrait .foot .qr .text { font-size: 20px; }
.t-portrait .foot .qr .text small { font-size: 17px; margin-top: 2px; }
.t-portrait .slide-product { grid-template-columns: 1fr; grid-template-rows: 680px 1fr; }
.t-portrait .slide-product .info { padding: 40px 56px 40px; }
.t-portrait .slide-product h2 { font-size: 50px; -webkit-line-clamp: 3; }
.t-portrait .price .now { font-size: 120px; }
.t-portrait .slide-grid { padding: 40px; gap: 24px; }
.t-portrait .slide-grid h3 { font-size: 44px; }
.t-portrait .slide-grid .row { grid-template-columns: 1fr; grid-template-rows: repeat(3, 1fr); gap: 24px; }
.t-portrait .card { flex-direction: row; }
.t-portrait .card .img { flex: 0 0 42%; }
.t-portrait .card .body { flex: 1; display: flex; flex-direction: column; justify-content: center; padding: 24px 32px; }
.t-portrait .card .t { font-size: 30px; height: auto; max-height: 3.6em; }

/* ---- template: fullscreen (no band: the mosaic video wall) ---- */
.t-fullscreen .band { display: none; }
.t-fullscreen .zone { position: absolute; inset: 0; }
.slide-media.wall video { width: 300%; max-width: none; object-fit: cover; }

/* store-wide message strip */
.ticker { position: absolute; left: 0; right: 0; bottom: 0; height: 76px; box-sizing: border-box; z-index: 3;
  background: var(--sale); color: var(--white); font: 800 38px/76px var(--font); padding: 0 32px; white-space: nowrap; overflow: hidden; }
.ticker span { display: inline-block; }
.ticker.scroll span { padding-left: 100%; animation: ticker linear infinite; }
@keyframes ticker { from { transform: translateX(0); } to { transform: translateX(-100%); } }
.zone.has-ticker .layer { bottom: 76px; }

/* ---- fixed band ---- */
.band { background: var(--navy); color: var(--white); box-sizing: border-box; display: flex; z-index: 2; }
.t-band-left .band { flex-direction: column; padding: 56px 48px 48px; gap: 0; }
.t-band-bottom .band { flex-direction: row; align-items: center; padding: 0 56px; gap: 56px; }

.brand { font-weight: 800; font-size: 30px; letter-spacing: .01em; color: var(--white); }
.brand small { display: block; font-weight: 600; font-size: 17px; letter-spacing: .14em; text-transform: uppercase; color: var(--pale); margin-top: 6px; }

.aisle { display: flex; flex-direction: column; }
.aisle .label { font-weight: 600; font-size: 26px; letter-spacing: .3em; text-transform: uppercase; color: var(--pale); }
.aisle .num { font-weight: 800; font-size: 230px; line-height: .9; letter-spacing: -.04em; font-variant-numeric: tabular-nums; }
.t-band-left .aisle { margin-top: 64px; }
.t-band-bottom .aisle .num { font-size: 150px; }
.t-band-bottom .aisle .label { font-size: 20px; }

.category { font-weight: 800; font-size: 50px; line-height: 1.05; text-wrap: balance; }
.t-band-left .category { margin-top: 28px; }
.t-band-bottom .mid { flex: 1; display: flex; flex-direction: column; gap: 18px; min-width: 0; }
.t-band-bottom .category { font-size: 56px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.offer {
  background: var(--white); color: var(--navy); border-left: 12px solid var(--sky);
  font-weight: 800; font-size: 36px; line-height: 1.12; padding: 22px 26px; border-radius: 6px; text-wrap: balance;
}
.t-band-left .offer { margin-top: 40px; }
.t-band-bottom .offer { font-size: 34px; padding: 14px 22px; align-self: flex-start; }

.qr { display: flex; align-items: center; gap: 22px; }
.t-band-left .qr { margin-top: auto; }
.qr .code { background: var(--white); padding: 14px; border-radius: 8px; width: 150px; height: 150px; flex: none; }
.t-band-bottom .qr .code { width: 140px; height: 140px; padding: 12px; }
.qr .code svg { width: 100%; height: 100%; display: block; }
.qr .text { font-weight: 700; font-size: 26px; line-height: 1.2; }
.qr .text small { display: block; font-weight: 600; font-size: 21px; color: var(--pale); margin-top: 8px; }

/* ---- rotating zone ---- */
.zone { background: #000; overflow: hidden; }
.layer { position: absolute; inset: 0; opacity: 0; transition: opacity .8s ease; }
.layer.on { opacity: 1; }

.slide-media { position: absolute; inset: 0; }
.slide-media .backdrop { position: absolute; inset: -40px; background-size: cover; background-position: center; filter: blur(36px) brightness(.55); }
.slide-media img, .slide-media video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.slide-media.fill img, .slide-media.fill video { object-fit: cover; }

/* product card */
.slide-product { position: absolute; inset: 0; background: var(--white); display: grid; grid-template-columns: 56% 44%; }
.slide-product .pic { background: var(--white); display: flex; align-items: center; justify-content: center; overflow: hidden; }
.slide-product .pic img { width: 100%; height: 100%; object-fit: contain; }
.slide-product .info { padding: 72px 64px 56px; display: flex; flex-direction: column; box-sizing: border-box; min-width: 0; }
.t-band-bottom .slide-product .info { padding: 48px 64px 40px; }
.eyebrow { font-weight: 700; font-size: 22px; letter-spacing: .14em; text-transform: uppercase; color: var(--navy-2); }
.slide-product h2 { font-weight: 800; font-size: 52px; line-height: 1.1; margin: 18px 0 0; text-wrap: balance; color: var(--navy-ink);
  display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.t-band-bottom .slide-product h2 { font-size: 50px; }
.price { margin-top: auto; display: flex; flex-direction: column; gap: 10px; }
.price .now { white-space: nowrap; font-weight: 800; font-size: 120px; line-height: .95; color: var(--navy); letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.t-band-bottom .price .now { font-size: 104px; }
.price .now .unit { font-size: 34px; font-weight: 700; letter-spacing: 0; color: var(--navy-2); margin-left: 8px; }
.price .now .from { font-size: 34px; font-weight: 700; letter-spacing: 0; color: var(--navy-2); display: block; margin-bottom: 6px; }
.price .was { font-size: 32px; font-weight: 600; color: #5b6b7c; }
.price .was s { margin-right: 14px; }
.badge { display: inline-block; background: var(--sale); color: var(--white); font-weight: 800; font-size: 30px; padding: 8px 16px; border-radius: 6px; letter-spacing: .02em; }
.scan { display: flex; align-items: center; gap: 20px; margin-top: 34px; font-weight: 700; font-size: 26px; color: var(--navy); }
.t-band-bottom .scan { margin-top: 20px; }
.scan .code { width: 116px; height: 116px; flex: none; }
.scan .code svg { width: 100%; height: 100%; display: block; }
.scan small { display: block; font-weight: 600; font-size: 21px; color: #5b6b7c; margin-top: 4px; }

/* three-product grid */
.slide-grid { position: absolute; inset: 0; background: var(--paper); padding: 56px; box-sizing: border-box; display: flex; flex-direction: column; gap: 32px; }
.t-band-bottom .slide-grid { padding: 36px 56px; gap: 22px; }
.slide-grid h3 { margin: 0; font-weight: 800; font-size: 46px; color: var(--navy); }
.slide-grid .row { flex: 1; display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; min-height: 0; }
.card { background: var(--white); border-radius: 10px; overflow: hidden; display: flex; flex-direction: column; box-shadow: 0 2px 0 rgba(10,58,99,.08); min-height: 0; }
.card .img { flex: 1; min-height: 0; background: var(--white); padding: 16px; }
.card .img img { width: 100%; height: 100%; object-fit: contain; display: block; }
.card .body { padding: 22px 26px 26px; }
.card .t { font-weight: 700; font-size: 26px; line-height: 1.2; height: 2.4em; overflow: hidden; color: var(--navy-ink); }
.card .p { display: flex; align-items: baseline; gap: 14px; margin-top: 12px; }
.card .p b { font-weight: 800; font-size: 52px; color: var(--navy); font-variant-numeric: tabular-nums; }
.card .p .unit { font-size: 22px; font-weight: 700; color: var(--navy-2); }
.card .p s { font-size: 24px; color: #5b6b7c; }
.card .badge { font-size: 22px; padding: 5px 10px; margin-left: auto; }

/* offer / service card (no price) */
.slide-card { position: absolute; inset: 0; background: var(--navy); color: var(--white); display: flex; align-items: center; justify-content: space-between; padding: 72px; box-sizing: border-box; gap: 48px; }
.slide-card .copy { min-width: 0; }
.slide-card .eyebrow { color: var(--sky); }
.slide-card h2 { font-weight: 800; font-size: 84px; line-height: 1.02; margin: 14px 0 20px; }
.slide-card p { margin: 0; font-size: 36px; line-height: 1.35; color: var(--pale); max-width: 22em; }
.slide-card .code { background: var(--white); padding: 18px; border-radius: 12px; width: 300px; height: 300px; flex: none; }
.slide-card .code svg { width: 100%; height: 100%; display: block; }
.t-portrait .slide-card { flex-direction: column; justify-content: center; text-align: center; padding: 72px 56px; }
.t-portrait .slide-card h2 { font-size: 72px; }
.t-portrait .slide-card p { font-size: 34px; }
.t-band-bottom .slide-card { padding: 48px 64px; }
.t-band-bottom .slide-card h2 { font-size: 64px; }
.t-band-bottom .slide-card .code { width: 220px; height: 220px; }

/* fallback when nothing can play (first boot with no network) */
.idle { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 20px; background: var(--navy); color: var(--white); text-align: center; }
.idle b { font-size: 72px; font-weight: 800; }
.idle span { font-size: 32px; color: var(--pale); }

.notice { position: absolute; right: 16px; bottom: 12px; z-index: 5; font: 600 16px var(--font); color: rgba(255,255,255,.75); background: rgba(0,0,0,.45); padding: 6px 10px; border-radius: 4px; }
