/* Holiday Video Studio entry points for the AINERGY main site (R38).
   The A/B design rules are adapted from the approved R38 prototype.
   Colors: main site ink/paper + Holiday Video Studio gold (docs/design/tokens.css). */
:root {
  --hvs-bar-h: 40px;
  --hvs-bar-bg: #142743;        /* main site --ink */
  --hvs-bar-text: #F3F1EA;      /* studio --on-dark-text   13.0:1 on bar */
  --hvs-gold: #F4C46B;          /* studio --gold-400       9.3:1 on bar  */
  --hvs-link: #9DC7FF;          /* studio primary on dark  8.6:1 on bar  */
  --hvs-gold-ink: #7E5B17;      /* studio --gold-800, 5.5:1 on --hvs-gold-wash */
  --hvs-gold-wash: #FFF1D1;
  --hvs-night: #0A1630;         /* studio --night-1 */
  --hvs-focus-dark: #FFE2A3;    /* studio --gold-soft (focus on dark) */
}

/* Campaign gate: set on <html> by the head script before first paint. */
html.hvs-off [data-hvs],
html.hvs-no-bar [data-hvs="bar"],
html.hvs-no-nav [data-hvs="nav"],
html.hvs-no-card [data-hvs="card"],
html.hvs-no-modal [data-hvs="modal"],
html.hvs-bar-dismissed [data-hvs="bar"] { display: none !important; }

/* ---------- 1. Announcement bar (above the sticky header, in normal flow) ---------- */
.hvs-bar {
  position: relative;
  z-index: 31;                      /* above .site-header (30) only while both are at the top */
  height: var(--hvs-bar-h);
  background: var(--hvs-bar-bg);
  color: var(--hvs-bar-text);
  font: 13px/1 var(--sans, Arial, Helvetica, sans-serif);
}
.hvs-bar__inner {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
.hvs-bar__link {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  height: 100%;
  padding: 0 48px;                  /* keeps text clear of the close button */
  color: var(--hvs-bar-text);
  text-decoration: none;
  white-space: nowrap;
}
.hvs-bar__new {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--hvs-gold);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1.2px;
  text-transform: uppercase;
}
.hvs-bulb {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--hvs-gold);
  box-shadow: 0 0 0 2px rgba(244, 196, 107, .16), 0 0 8px 1px rgba(244, 196, 107, .7);
  flex: 0 0 auto;
}
.hvs-bar__name { font-weight: 700; }
.hvs-bar__desc { color: #DCE3EE; }                 /* studio --on-dark-muted 11.6:1 */
.hvs-bar__cta {
  color: var(--hvs-link);
  font-weight: 700;
  margin-left: 4px;
}
.hvs-bar__cta span { display: inline-block; transition: transform .16s; }
.hvs-bar__link:hover .hvs-bar__cta { text-decoration: underline; text-underline-offset: 3px; }
.hvs-bar__link:hover .hvs-bar__cta span { transform: translateX(2px); }
.hvs-bar__close {
  position: absolute;
  right: -10px;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #DCE3EE;
  cursor: pointer;
}
.hvs-bar__close:hover { color: #fff; background: rgba(255, 255, 255, .08); }
.hvs-bar a:focus-visible,
.hvs-bar button:focus-visible {
  outline: 2px solid var(--hvs-focus-dark);
  outline-offset: -4px;
  border-radius: 6px;
}

/* Desktop: the hero keeps fitting the first screen while the bar is visible. */
@media (min-width: 1101px) {
  html:not(.hvs-off):not(.hvs-no-bar):not(.hvs-bar-dismissed) .hvs-bar ~ main .hero { min-height: calc(100vh - 82px - var(--hvs-bar-h)); }
}
@media (max-width: 960px) {
  .hvs-bar__desc { display: none; }
}
@media (max-width: 540px) {
  :root { --hvs-bar-h: 44px; }
  .hvs-bar { font-size: 12px; }
  .hvs-bar__inner { justify-content: flex-start; }
  .hvs-bar__link { padding: 0 44px 0 0; gap: 8px; }
  .hvs-bar__new { font-size: 11px; letter-spacing: 1px; gap: 6px; }
  .hvs-bar__cta { margin-left: 2px; }
  .hvs-bar__close { right: -12px; width: 44px; height: 44px; }
}
@media (max-width: 374px) {
  /* Very narrow phones: the bulb carries "new"; the word stays for screen readers. */
  .hvs-bar__new-text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
}

/* ---------- 2. Top navigation item with "New" pill ---------- */
.nav-links a.nav-hvs {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}
.nav-new {
  display: inline-block;
  padding: 3px 7px 2px;
  border-radius: 999px;
  background: var(--hvs-gold-wash);
  border: 1px solid #EBCB8B;
  color: var(--hvs-gold-ink);              /* 5.5:1 on the wash */
  font-size: 10px;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: .6px;
  text-transform: uppercase;
}
@media (max-width: 1240px) and (min-width: 821px) {
  .nav-links { gap: 18px; }
}
@media (max-width: 960px) and (min-width: 821px) {
  .nav-links { gap: 14px; }
}

/* ---------- 3. Homepage feature (below the hero) ---------- */
.hvs-feature { padding: 64px 0 8px; }
.hvs-feature__panel {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: 48px;
  align-items: center;
  padding: 48px;
  border-radius: 20px;
  background: var(--hvs-night);
  color: #DCE3EE;
}
.hvs-feature .eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--hvs-gold);
  font-size: 12px;
  letter-spacing: 1.4px;
  margin-bottom: 16px;
}
.hvs-feature h2 {
  color: #F3F1EA;
  font-size: clamp(32px, 3.2vw, 44px);
  letter-spacing: -1px;
}
.hvs-feature h2 em { font-style: italic; color: #FFE2A3; }
.hvs-feature__copy > p:not(.eyebrow) { margin-top: 16px; font-size: 15px; line-height: 1.7; max-width: 440px; color: #DCE3EE; } /* site sets p{color:var(--body)} */
.hvs-feature__meta { color: #DCE3EE; font-size: 13px !important; }
.hvs-feature__meta span + span::before { content: "·"; margin: 0 8px; color: var(--hvs-gold); }
.hvs-feature .button {
  margin-top: 24px;
  background: var(--hvs-link);
  color: var(--hvs-night);
}
.hvs-feature .button:hover { background: #C4DDFF; }
.hvs-feature .button:focus-visible { outline: 2px solid var(--hvs-focus-dark); outline-offset: 3px; }
.hvs-feature__media {
  margin: 0;
  border-radius: 14px;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .14), 0 0 24px rgba(169, 216, 255, .12);
}
.hvs-feature__media img { display: block; width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 820px) {
  .hvs-feature { padding-top: 40px; }
  .hvs-feature__panel { grid-template-columns: 1fr; gap: 24px; padding: 24px; }
  .hvs-feature__media { order: -1; }
}

/* First-visit home dialog. Native showModal provides the backdrop and focus scope. */
.hvs-modal {
  width: min(560px, calc(100% - 32px));
  max-height: calc(100dvh - 32px);
  padding: 0;
  border: 0;
  border-radius: 20px;
  background: var(--hvs-night);
  color: #DCE3EE;
  box-shadow: 0 24px 64px rgba(5, 10, 24, .32);
  overflow: auto;
}
.hvs-modal::backdrop { background: rgba(10, 22, 48, .55); }
.hvs-modal__media { margin: 0; aspect-ratio: 16 / 9; overflow: hidden; }
.hvs-modal__media img { display: block; width: 100%; height: 100%; object-fit: cover; }
.hvs-modal__body { padding: 24px 32px 32px; }
.hvs-modal .eyebrow { display: inline-flex; align-items: center; gap: 8px; color: var(--hvs-gold); font-size: 12px; letter-spacing: 1.4px; margin-bottom: 12px; }
.hvs-modal h2 { color: #F3F1EA; font-size: 32px; letter-spacing: -.8px; }
.hvs-modal__body > p:not(.eyebrow) { margin-top: 12px; font-size: 15px; line-height: 1.65; color: #DCE3EE; }
.hvs-modal__actions { display: flex; align-items: center; gap: 24px; margin-top: 24px; flex-wrap: wrap; }
.hvs-modal .button { background: var(--hvs-link); color: var(--hvs-night); }
.hvs-modal .text-link { color: #DCE3EE; cursor: pointer; }
.hvs-modal__x { position: absolute; top: 12px; right: 12px; width: 40px; height: 40px; display: grid; place-items: center; border: 0; border-radius: 50%; background: rgba(10, 22, 48, .72); color: #F3F1EA; cursor: pointer; }
.hvs-modal a:focus-visible, .hvs-modal button:focus-visible { outline: 2px solid var(--hvs-focus-dark); outline-offset: 3px; }
@media (max-width: 540px) {
  .hvs-modal__body { padding: 20px 22px 28px; }
  .hvs-modal h2 { font-size: 28px; }
  .hvs-modal__actions { gap: 16px; }
}
