/* Paintings on the resident page: the banner behind the department name, and Santa on the heads-up card.
   Only /:slug and /demo get the banner (src/client/track/art.ts adds it); embed, TV, kids and the truck phone never load this. */

.tr-art {
  position: relative; isolation: isolate; overflow: hidden; background: #0f1b2d; color: #fff;
  min-height: 168px; display: flex; align-items: flex-end;
}
.tr-art-pic, .tr-art-pic img { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.tr-art-pic img { object-fit: cover; object-position: 100% 62%; }
/* Navy from the left keeps the name readable; the right stays clear so the engine shows. */
.tr-art::after {
  content: ""; position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background: linear-gradient(90deg, rgba(15, 27, 45, 0.94) 0%, rgba(15, 27, 45, 0.86) 38%, rgba(15, 27, 45, 0.45) 62%, rgba(15, 27, 45, 0) 82%),
    linear-gradient(0deg, rgba(15, 27, 45, 0.55) 0%, rgba(15, 27, 45, 0) 45%);
}
.tr-art-in { position: relative; z-index: 1; width: 100%; }
.tr-art-text { padding-top: 20px; padding-bottom: 16px; }
.tr-art .tr-brand { max-width: 64%; }
.tr-art .tr-name { color: #fff; font-size: clamp(1.3rem, 5.2vw, 2rem); line-height: 1.15; text-shadow: 0 1px 6px rgba(0, 0, 0, 0.6); }
.tr-art .tr-where { margin: 4px 0 0; color: #e6ecf5; text-shadow: 0 1px 4px rgba(0, 0, 0, 0.6); }
.tr-art .tr-logo { box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.35); }
/* The department's accent underline: the banner is dark in day mode too, so use the night shade made for dark backgrounds. */
html:not(.a11y-contrast) [data-br] .tr-art .tr-name { text-decoration-color: var(--br-n-line); }
/* The wrap is 760 wide; the painting sits in the same column on a big screen so the name lines up with the page. */
@media (min-width: 700px) {
  .tr-art { max-width: 1100px; min-height: 240px; margin: 16px auto 0; border-radius: 16px; }
  .tr-art .tr-brand { max-width: 56%; }
  .tr-art-text { padding-bottom: 28px; }
}
@media (min-width: 700px) and (max-width: 1148px) { .tr-art { margin-left: 16px; margin-right: 16px; } }
/* Night mode: the page is already dark, so keep the banner from glowing. */
html[data-theme="night"] .tr-art-pic img { filter: brightness(0.82); }
html[lang="es"] .tr-art .tr-name { overflow-wrap: anywhere; }
@media print { .tr-art-pic { display: none; } .tr-art { background: none; color: inherit; min-height: 0; } .tr-art .tr-name, .tr-art .tr-where { color: #000; text-shadow: none; } }

/* Santa on the heads-up card */
.hu-pic {
  display: block; width: 100%; max-height: 36vh; aspect-ratio: 16 / 9; margin: 0 0 16px; border-radius: 16px;
  object-fit: cover; object-position: 50% 22%; background: #14233a; opacity: 0; transition: opacity 0.25s ease;
}
.hu-pic.is-in { opacity: 1; }
.hu-pic[hidden] { display: none; }
@media (prefers-reduced-motion: reduce) { .hu-pic { transition: none; } }
html.a11y-motion .hu-pic { transition: none; }
/* Short phones: the buttons must stay on screen. */
@media (max-height: 700px) { .hu-pic { max-height: 22vh; margin-bottom: 10px; } }
@media (max-height: 520px) { .hu-pic { display: none; } }
