/**
 * HealthN.E.S.S. — HVAC premium sales experience
 * Product-theater layout. Black / charcoal / champagne gold.
 */

.demo-hvac-page {
  overflow-x: clip;
}

/* No mobile sticky discovery bar on this page — reclaim shared work-page clearance */
@media (max-width: 767px) {
  body.demo-hvac-page.work-page {
    padding-bottom: env(safe-area-inset-bottom, 0px);
  }

  body.demo-hvac-page footer {
    padding-bottom: 1.5rem;
  }
}

/* ——— Hero split ——— */
.demo-hvac-hero {
  position: relative;
  overflow-x: clip;
  padding: clamp(6.25rem, 11vw, 8.75rem) var(--space-gutter) clamp(2.75rem, 5vw, 4.25rem);
}

.demo-hvac-hero::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: min(78vh, 42rem);
  pointer-events: none;
  background:
    radial-gradient(ellipse 48% 55% at 12% 18%, rgba(242, 202, 80, 0.07), transparent 68%),
    radial-gradient(ellipse 36% 48% at 78% 22%, rgba(211, 197, 173, 0.05), transparent 70%);
}

.demo-hvac-hero__inner {
  position: relative;
  max-width: var(--width-container-max);
  margin: 0 auto;
  display: grid;
  gap: clamp(1.75rem, 4vw, 3rem);
  align-items: center;
}

@media (min-width: 980px) {
  .demo-hvac-hero__inner {
    grid-template-columns: minmax(0, 0.44fr) minmax(0, 0.56fr);
    gap: clamp(2rem, 3.5vw, 3.25rem);
  }
}

.demo-hvac-hero__copy {
  min-width: 0;
}

.demo-hvac-hero__eyebrow {
  display: block;
  margin-bottom: 1.1rem;
  color: var(--color-primary);
}

.demo-hvac-hero__title {
  margin: 0 0 1.15rem;
  max-width: 18ch;
  font-family: var(--font-display);
  font-size: clamp(1.9rem, 4.6vw, 3.35rem);
  line-height: 1.07;
  letter-spacing: -0.025em;
  font-weight: 700;
  color: var(--color-on-background);
}

.demo-hvac-hero__lede {
  margin: 0 0 1.55rem;
  max-width: 36rem;
  font-family: var(--font-body);
  font-size: clamp(1rem, 1.8vw, 1.12rem);
  line-height: 1.7;
  color: var(--color-on-surface-variant);
}

.demo-hvac-hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1rem;
  align-items: center;
}

.demo-hvac-cta {
  border-radius: 0.45rem;
  transition:
    transform 0.2s ease,
    background-color 0.2s ease,
    border-color 0.2s ease,
    color 0.2s ease,
    box-shadow 0.2s ease;
}

.demo-hvac-hero__actions .proof-action--solid,
.demo-hvac-demo-cta .proof-action--solid,
.demo-hvac-close__actions .proof-action--solid {
  border-bottom-width: 1px;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.28);
}

.demo-hvac-hero__actions .proof-action--btn,
.demo-hvac-close__actions .proof-action--btn {
  border-radius: 0.45rem;
  border-bottom-width: 1px;
}

@media (hover: hover) and (pointer: fine) {
  .demo-hvac-cta:hover {
    transform: translateY(-1px);
  }
}

@media (prefers-reduced-motion: reduce) {
  .demo-hvac-cta {
    transition: none;
  }

  .demo-hvac-cta:hover {
    transform: none;
  }
}

.demo-hvac-hero__stage {
  margin: 0;
  min-width: 0;
}

.demo-hvac-hero__caption {
  margin-top: 0.7rem;
  font-family: var(--font-label);
  font-size: 0.65rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-on-surface-variant);
  opacity: 0.85;
}

.demo-hvac-product-frame {
  position: relative;
  overflow: hidden;
  border-radius: 0.75rem;
  border: 1px solid rgba(153, 144, 124, 0.22);
  background: #161716;
  box-shadow:
    0 1px 0 rgba(242, 202, 80, 0.08),
    0 28px 70px rgba(0, 0, 0, 0.45);
}

.demo-hvac-product-frame--hero {
  animation: demo-hvac-hero-rise 0.7s ease both;
}

@keyframes demo-hvac-hero-rise {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .demo-hvac-product-frame--hero {
    animation: none;
  }
}

.demo-hvac-product-frame img {
  display: block;
  width: 100%;
  height: auto;
}

.demo-hvac-product-frame--compact {
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.35);
}

/* ——— Sections ——— */
.demo-hvac-section {
  max-width: var(--width-container-max);
  margin: 0 auto;
  padding: 0 var(--space-gutter) clamp(2.75rem, 6vw, 4.25rem);
}

.demo-hvac-section--demo {
  padding-top: 0.25rem;
}

.demo-hvac-section__eyebrow {
  display: block;
  margin-bottom: 0.65rem;
  color: var(--color-primary);
}

.demo-hvac-section__title {
  margin: 0 0 0.8rem;
  max-width: 24ch;
  font-family: var(--font-heading);
  font-size: clamp(1.55rem, 3vw, 2.25rem);
  line-height: 1.14;
  letter-spacing: -0.015em;
  color: var(--color-on-background);
}

.demo-hvac-section__lede {
  margin: 0 0 1.35rem;
  max-width: 42rem;
  font-family: var(--font-body);
  font-size: 1.05rem;
  line-height: 1.65;
  color: var(--color-on-surface-variant);
}

.demo-hvac-section__lede--tight {
  margin-bottom: 1.35rem;
  max-width: 40rem;
  font-size: 1rem;
}

/* ——— Editorial challenges ——— */
.demo-hvac-editorial {
  list-style: none;
  margin: 0.25rem 0 0;
  padding: 0;
  border-top: 1px solid rgba(153, 144, 124, 0.2);
}

.demo-hvac-editorial__row {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.85rem 1.25rem;
  padding: 1rem 0;
  border-bottom: 1px solid rgba(153, 144, 124, 0.18);
}

.demo-hvac-editorial__num {
  font-family: var(--font-label);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--color-primary);
  line-height: 1.55;
  padding-top: 0.12rem;
}

.demo-hvac-editorial__title {
  margin: 0 0 0.28rem;
  font-family: var(--font-heading);
  font-size: 1.05rem;
  line-height: 1.3;
  color: var(--color-on-background);
}

.demo-hvac-editorial__body {
  margin: 0;
  max-width: 42rem;
  font-family: var(--font-body);
  font-size: 0.95rem;
  line-height: 1.55;
  color: var(--color-on-surface-variant);
}

/* ——— Interactive gallery (segmented control) ——— */
.demo-hvac-gallery {
  margin: 0 0 1.25rem;
}

.demo-hvac-gallery__tabs {
  display: inline-flex;
  flex-wrap: nowrap;
  align-items: stretch;
  gap: 0.2rem;
  max-width: 100%;
  margin: 0 0 1.05rem;
  padding: 0.28rem;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
  border: 1px solid rgba(153, 144, 124, 0.28);
  border-radius: 0.65rem;
  background: #161716;
  box-shadow: inset 0 1px 0 rgba(242, 202, 80, 0.04);
}

.demo-hvac-gallery .demo-hvac-gallery__tab {
  appearance: none;
  -webkit-appearance: none;
  flex: 1 0 auto;
  min-height: 44px;
  margin: 0;
  padding: 0.65rem 1.05rem;
  border: 1px solid transparent;
  border-radius: 0.45rem;
  background: transparent;
  color: var(--color-on-surface-variant);
  font-family: var(--font-label);
  font-size: 0.68rem;
  font-weight: 650;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  line-height: 1.2;
  cursor: pointer;
  white-space: nowrap;
  transition:
    color 0.2s ease,
    border-color 0.2s ease,
    background-color 0.2s ease,
    box-shadow 0.2s ease;
}

.demo-hvac-gallery .demo-hvac-gallery__tab:hover {
  color: var(--color-on-background);
  background: rgba(255, 255, 255, 0.03);
}

.demo-hvac-gallery .demo-hvac-gallery__tab:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
  z-index: 1;
}

.demo-hvac-gallery .demo-hvac-gallery__tab[aria-selected="true"] {
  color: #121413;
  border-color: rgba(242, 202, 80, 0.55);
  background: linear-gradient(180deg, #f5d56a 0%, var(--color-primary) 100%);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.28);
}

.demo-hvac-gallery__stage {
  min-width: 0;
}

.demo-hvac-gallery__panel[hidden] {
  display: none;
}

.demo-hvac-gallery__figure {
  margin: 0;
}

.demo-hvac-gallery__figure figcaption {
  display: grid;
  gap: 0.28rem;
  margin-top: 0.9rem;
  padding: 0 0.1rem;
}

.demo-hvac-gallery__figure figcaption strong {
  font-family: var(--font-heading);
  font-size: 1.05rem;
  color: var(--color-on-background);
}

.demo-hvac-gallery__figure figcaption span {
  font-family: var(--font-body);
  font-size: 0.95rem;
  line-height: 1.5;
  color: var(--color-on-surface-variant);
  max-width: 42rem;
}

.demo-hvac-gallery__fallback {
  margin: 0.75rem 0 0;
  padding-left: 1.1rem;
  font-family: var(--font-body);
  font-size: 0.92rem;
  color: var(--color-on-surface-variant);
}

.demo-hvac-gallery__fallback a {
  color: var(--color-primary);
}

.demo-hvac-demo-cta {
  margin: 0 0 1rem;
}

.demo-hvac-note {
  margin: 0;
  max-width: 46rem;
  padding: 0.8rem 0 0;
  border: 0;
  background: transparent;
  font-family: var(--font-body);
  font-size: 0.88rem;
  line-height: 1.55;
  color: var(--color-on-surface-variant);
  opacity: 0.92;
}

/* ——— Cinematic development timeline ——— */
.demo-hvac-timeline {
  --timeline-progress: 0.12;
  --timeline-rail-x: 0.7rem;
  list-style: none;
  position: relative;
  margin: 0 0 1.5rem;
  padding: 0.15rem 0 0.35rem;
}

.demo-hvac-timeline::before {
  content: "";
  position: absolute;
  top: 0.55rem;
  bottom: 0.55rem;
  left: var(--timeline-rail-x);
  width: 1px;
  background: rgba(153, 144, 124, 0.28);
  transform: translateX(-50%);
  pointer-events: none;
}

.demo-hvac-timeline::after {
  content: "";
  position: absolute;
  top: 0.55rem;
  left: var(--timeline-rail-x);
  width: 2px;
  height: calc((100% - 1.1rem) * var(--timeline-progress, 0.12));
  background: linear-gradient(
    180deg,
    rgba(242, 202, 80, 0.95),
    rgba(242, 202, 80, 0.35)
  );
  transform: translateX(-50%);
  border-radius: 999px;
  box-shadow: 0 0 18px rgba(242, 202, 80, 0.18);
  pointer-events: none;
  transition: height 0.45s ease;
}

.demo-hvac-timeline__stage {
  position: relative;
  display: grid;
  grid-template-columns: 1.4rem minmax(0, 1fr);
  gap: 0 1.15rem;
  margin: 0;
  padding: 0 0 1.65rem;
}

.demo-hvac-timeline__stage:last-child {
  padding-bottom: 0.35rem;
}

.demo-hvac-timeline__rail {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: center;
  padding-top: 0.35rem;
}

.demo-hvac-timeline__node {
  display: block;
  width: 0.85rem;
  height: 0.85rem;
  border-radius: 999px;
  border: 1px solid rgba(153, 144, 124, 0.45);
  background: #161716;
  box-shadow: 0 0 0 4px #121413;
  transition:
    border-color 0.35s ease,
    background-color 0.35s ease,
    box-shadow 0.35s ease,
    transform 0.35s ease;
}

.demo-hvac-timeline__body {
  min-width: 0;
  padding: 0.15rem 0 0;
  transition:
    opacity 0.35s ease,
    transform 0.35s ease;
}

.demo-hvac-timeline__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.45rem 1rem;
  margin-bottom: 0.4rem;
}

.demo-hvac-timeline__num {
  font-family: var(--font-label);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--color-primary);
}

.demo-hvac-timeline__price {
  font-family: var(--font-heading);
  font-size: clamp(1.05rem, 2vw, 1.2rem);
  font-weight: 700;
  color: var(--color-on-background);
  white-space: nowrap;
}

.demo-hvac-timeline__title {
  margin: 0 0 0.45rem;
  font-family: var(--font-heading);
  font-size: clamp(1.12rem, 2.2vw, 1.35rem);
  line-height: 1.25;
  color: var(--color-on-background);
}

.demo-hvac-timeline__what {
  margin: 0 0 0.55rem;
  max-width: 40rem;
  font-family: var(--font-body);
  font-size: 0.98rem;
  line-height: 1.6;
  color: var(--color-on-surface-variant);
}

.demo-hvac-timeline__outcome {
  margin: 0;
  max-width: 40rem;
  font-family: var(--font-body);
  font-size: 0.92rem;
  line-height: 1.55;
  color: var(--color-on-surface-variant);
}

.demo-hvac-timeline__outcome-label {
  font-family: var(--font-label);
  font-size: 0.62rem;
  font-weight: 650;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-primary);
  margin-right: 0.35rem;
}

/* Inactive stages remain readable; active gains weight */
.demo-hvac-timeline__stage:not(.is-active) .demo-hvac-timeline__body {
  opacity: 0.62;
}

.demo-hvac-timeline__stage.is-active .demo-hvac-timeline__node {
  border-color: rgba(242, 202, 80, 0.9);
  background: var(--color-primary);
  box-shadow:
    0 0 0 4px #121413,
    0 0 0 7px rgba(242, 202, 80, 0.18),
    0 0 22px rgba(242, 202, 80, 0.28);
  transform: scale(1.08);
}

.demo-hvac-timeline__stage.is-active .demo-hvac-timeline__body {
  opacity: 1;
}

.demo-hvac-timeline__stage.is-active .demo-hvac-timeline__title {
  letter-spacing: -0.01em;
}

.demo-hvac-timeline--static .demo-hvac-timeline__stage .demo-hvac-timeline__body,
.demo-hvac-timeline--static .demo-hvac-timeline__stage:not(.is-active) .demo-hvac-timeline__body {
  opacity: 1;
}

@media (prefers-reduced-motion: reduce) {
  .demo-hvac-timeline::after,
  .demo-hvac-timeline__node,
  .demo-hvac-timeline__body {
    transition: none;
  }

  .demo-hvac-timeline__stage.is-active .demo-hvac-timeline__node {
    transform: none;
  }

  .demo-hvac-timeline__stage:not(.is-active) .demo-hvac-timeline__body {
    opacity: 0.88;
  }
}

.demo-pricing-summary {
  margin: 0 0 1.15rem;
  padding: 1.25rem 1.3rem;
  border-radius: 0.65rem;
  border: 1px solid rgba(242, 202, 80, 0.2);
  background:
    linear-gradient(180deg, rgba(242, 202, 80, 0.06), transparent 55%),
    #161716;
}

.demo-pricing-summary--coda {
  margin-top: 0.25rem;
  position: relative;
}

.demo-pricing-summary--coda::before {
  content: "";
  display: block;
  width: 2.5rem;
  height: 1px;
  margin: 0 0 1rem;
  background: linear-gradient(90deg, rgba(242, 202, 80, 0.7), transparent);
}

.demo-pricing-summary__label {
  margin: 0 0 0.35rem !important;
  font-family: var(--font-label) !important;
  font-size: 0.625rem !important;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-primary) !important;
}

.demo-pricing-summary__total {
  margin: 0 0 0.75rem !important;
}

.demo-pricing-summary__total strong {
  font-family: var(--font-heading);
  font-size: clamp(1.35rem, 2.6vw, 1.75rem);
  font-weight: 700;
  color: var(--color-on-background);
}

.demo-pricing-summary p {
  margin: 0 0 0.7rem;
  font-family: var(--font-body);
  font-size: 0.94rem;
  line-height: 1.55;
  color: var(--color-on-surface-variant);
}

.demo-pricing-summary p:last-child {
  margin-bottom: 0;
}

.demo-pricing-care {
  margin: 0 0 1rem;
  padding: 1.1rem 1.2rem;
  border-radius: 0.65rem;
  border: 1px solid rgba(153, 144, 124, 0.22);
  background: #161716;
}

.demo-pricing-care__eyebrow {
  margin: 0 0 0.35rem;
  font-family: var(--font-label);
  font-size: 0.625rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-primary);
}

.demo-pricing-care h3 {
  margin: 0 0 0.3rem;
  font-family: var(--font-heading);
  font-size: 1.1rem;
  color: var(--color-on-background);
}

.demo-pricing-care__price {
  margin: 0 0 0.7rem;
  font-family: var(--font-heading);
  font-size: clamp(1.25rem, 2.4vw, 1.55rem);
  font-weight: 700;
  color: var(--color-primary);
}

.demo-pricing-care p {
  margin: 0 0 0.55rem;
  font-family: var(--font-body);
  font-size: 0.92rem;
  line-height: 1.55;
  color: var(--color-on-surface-variant);
}

.demo-pricing-care p:last-child {
  margin-bottom: 0;
}

.demo-pricing-details {
  display: grid;
  gap: 0.45rem;
  margin: 0 0 0.25rem;
}

.demo-pricing-details__item {
  border: 1px solid rgba(153, 144, 124, 0.18);
  border-radius: 0.5rem;
  background: rgba(22, 23, 22, 0.55);
}

.demo-pricing-details__item > summary {
  cursor: pointer;
  list-style: none;
  padding: 0.85rem 1rem;
  font-family: var(--font-heading);
  font-size: 0.98rem;
  color: var(--color-on-background);
}

.demo-pricing-details__item > summary::-webkit-details-marker {
  display: none;
}

.demo-pricing-details__item > summary::after {
  content: "+";
  float: right;
  color: var(--color-primary);
  font-weight: 700;
}

.demo-pricing-details__item[open] > summary::after {
  content: "–";
}

.demo-pricing-details__item > summary:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

.demo-pricing-details__item > *:not(summary) {
  padding: 0 1rem 1rem;
}

.demo-pricing-details__item p {
  margin: 0 0 0.65rem;
  font-family: var(--font-body);
  font-size: 0.9rem;
  line-height: 1.55;
  color: var(--color-on-surface-variant);
}

.demo-pricing-details__item p:last-child {
  margin-bottom: 0;
}

.demo-pricing-details__list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.85rem;
}

.demo-pricing-details__list strong {
  display: block;
  margin-bottom: 0.25rem;
  font-family: var(--font-heading);
  font-size: 0.95rem;
  color: var(--color-on-background);
}

.demo-pricing-details__list p {
  margin: 0;
}

/* ——— Closing band ——— */
.demo-hvac-close {
  margin: 0 0 clamp(2.75rem, 7vw, 4.5rem);
  padding: 0;
}

.demo-hvac-close__band {
  border-top: 1px solid rgba(242, 202, 80, 0.14);
  background:
    radial-gradient(ellipse 70% 80% at 50% 0%, rgba(242, 202, 80, 0.07), transparent 60%),
    #161716;
}

.demo-hvac-close__inner {
  max-width: var(--width-container-max);
  margin: 0 auto;
  padding: clamp(2.35rem, 5.5vw, 3.5rem) var(--space-gutter);
}

.demo-hvac-close__title {
  margin: 0 0 0.75rem;
  max-width: 18ch;
  font-family: var(--font-heading);
  font-size: clamp(1.55rem, 3vw, 2.15rem);
  line-height: 1.12;
  letter-spacing: -0.015em;
  color: var(--color-on-background);
}

.demo-hvac-close__lede {
  margin: 0 0 1.25rem;
  max-width: 36rem;
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.65;
  color: var(--color-on-surface-variant);
}

.demo-hvac-close__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1rem;
  align-items: center;
}

.demo-hvac-related {
  margin-top: 1.15rem;
  font-family: var(--font-body);
  font-size: 0.92rem;
  line-height: 1.6;
  color: var(--color-on-surface-variant);
}

.demo-hvac-related a {
  color: var(--color-primary);
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

.demo-hvac-related a:hover,
.demo-hvac-related a:focus-visible {
  color: var(--color-champagne-gold);
}

/* ——— Reveal (only when JS arms motion; never hide content by default) ——— */
.demo-hvac-reveal {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: no-preference) {
  html.demo-hvac-motion-ready .demo-hvac-reveal:not(.is-visible) {
    opacity: 0;
    transform: translateY(14px);
  }

  html.demo-hvac-motion-ready .demo-hvac-reveal {
    transition: opacity 0.55s ease, transform 0.55s ease;
  }

  html.demo-hvac-motion-ready .demo-hvac-reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ——— Narrow mobile ——— */
@media (max-width: 389px) {
  .demo-hvac-hero__title {
    font-size: clamp(1.65rem, 8vw, 1.95rem);
    max-width: none;
  }

  .demo-hvac-hero__actions {
    flex-direction: column;
    align-items: stretch;
  }

  .demo-hvac-hero__actions .demo-hvac-cta {
    justify-content: center;
    text-align: center;
  }

  .demo-hvac-timeline {
    --timeline-rail-x: 0.55rem;
  }

  .demo-hvac-timeline__stage {
    gap: 0 0.85rem;
    padding-bottom: 1.4rem;
  }

  .demo-hvac-timeline__meta {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.25rem;
  }

  .demo-hvac-gallery .demo-hvac-gallery__tab {
    padding: 0.65rem 0.85rem;
  }
}
