/* Scroll-through house: one scene, contextual controls, no bottom menu. */
:root {
  --header-height: 100px;
}
body.tour-active {
  overflow: hidden;
}
.header {
  height: var(--header-height);
}
.header nav a,
.header nav #header-plan {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  gap: 7px;
  font-size: 17px;
  font-weight: 800;
  line-height: 1.3;
}
.header nav {
  gap: 28px;
  align-items: center;
}
.header nav #header-home {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-width: 44px;
  min-height: 44px;
  flex-shrink: 0;
}
#header-home svg { flex-shrink: 0; }
@media (max-width: 380px) {
  .header nav #header-plan { gap: 4px; }
  .header nav #header-plan b { margin-left: 0; flex-shrink: 0; }
}
@media (max-width: 600px) {
  #header-home span { display: none; }
  .header nav { gap: 8px; }
}
.header nav a[aria-current="page"] {
  color: var(--orange);
}
.experience,
.experience.focused,
.experience.simple-mode {
  height: calc(100svh - var(--header-height));
  height: calc(100dvh - var(--header-height));
  min-height: 0;
}
body.tour-active footer {
  display: none;
}
#world,
.experience.focused #world {
  inset: 0;
  height: 100%;
  touch-action: pinch-zoom;
}
#world > canvas {
  width: 100%;
  height: 100%;
  touch-action: pinch-zoom;
}
.intro {
  top: 100px;
  left: 4%;
  max-width: 370px;
}
.intro h1 {
  font-size: clamp(40px, 4.1vw, 65px);
  letter-spacing: -3px;
}
.intro p {
  font-size: 15px;
}
.scene-tools {
  position: absolute;
  z-index: 6;
  top: 18px;
  right: 3%;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 6px 14px;
  border: 1px solid #d8dfd3;
  border-radius: 18px;
  background: #fffef9f5;
  box-shadow: 0 5px 25px #243b3710;
  color: var(--ink);
}
.scene-tools .scenario-buttons {
  gap: 3px;
}
.scene-tools .scenario-buttons button {
  min-height: 42px;
  padding: 10px 12px;
  border: 0;
  border-radius: 10px;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}
.scene-tools .scenario-buttons button:hover {
  background: #e9ede2;
}
.scene-tools .scenario-buttons button[aria-pressed="true"] {
  background: var(--ink);
  color: white;
}
.scene-tools #outage[aria-pressed="true"] {
  background: #994329;
}
.scene-tools .time-control {
  border-left: 1px solid var(--line);
  padding-left: 14px;
  gap: 7px;
}
.scene-tools .time-control label {
  font-size: 12px;
  min-width: 61px;
  gap: 5px;
}
.scene-tools input {
  width: 105px;
  min-width: 60px;
  height: 32px;
  margin: 0;
}
.back-house {
  top: 22px;
  left: 3%;
  min-height: 44px;
  font-size: 12px;
}
.roof-return {
  position: absolute;
  top: 84px;
  right: 3%;
  z-index: 5;
  padding: 10px 15px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--white);
  min-height: 44px;
  font-size: 13px;
}
.control-panel,
.experience.focused .control-panel {
  top: 88px;
  left: 3%;
  bottom: auto;
  width: 295px;
  max-height: calc(100% - 192px);
  padding: 22px;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  touch-action: pan-y;
}
.control-panel h2 {
  font-size: 26px;
}
.control-panel p {
  font-size: 13px;
}
.control-panel .panel-action {
  display: block;
  min-height: 44px;
}
.control-panel input[type="range"] {
  height: 32px;
  margin-top: 4px;
}
.control-panel .switch {
  min-height: 36px;
  width: 54px;
  min-width: 54px;
  padding: 7px 6px;
}
.control-panel .switch[aria-checked="true"]:after {
  transform: translateX(20px);
}
.control-panel .control {
  margin: 14px 0;
}
.journey-progress {
  position: absolute;
  left: 3%;
  bottom: 22px;
  z-index: 5;
  display: flex;
  align-items: center;
  gap: 12px;
  width: 295px;
  padding: 9px 10px;
  background: #fffef9f5;
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: 0 5px 25px #243b3710;
  color: var(--ink);
}
.journey-progress button {
  min-width: 42px;
  min-height: 44px;
  border-radius: 10px;
  font-size: 23px;
  background: #e9eee5;
}
.journey-progress button:disabled {
  opacity: 0.3;
}
.journey-progress div {
  flex: 1;
}
.journey-progress span {
  font-size: 9px;
  letter-spacing: 1.8px;
  color: var(--orange);
  display: block;
}
.journey-progress strong {
  display: block;
  font-size: 14px;
  margin: 3px 0;
}
.journey-progress small {
  display: block;
  font-size: 10px;
  color: var(--muted);
}
.energy-chip,
.experience.focused .energy-chip {
  right: 3%;
  bottom: 24px;
  padding: 10px 15px;
  gap: 10px;
}
.energy-chip strong {
  font-size: 20px;
}
.house-caption,
.orientation {
  display: none;
}
.motion-toggle {
  position: absolute;
  z-index: 5;
  right: 3%;
  bottom: 102px;
  min-width: 40px;
  min-height: 40px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 50%;
  font-size: 12px;
}
.hotspot {
  min-height: 40px;
}
.hotspot b {
  min-width: 23px;
}
.solution-shortcuts a {
  font-size: 13px;
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 11px 16px;
}
.product-placeholder {
  aspect-ratio: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 12px;
  padding: 24px;
  margin-bottom: 20px;
  border: 1px dashed #d5ded3;
  border-radius: 8px;
  background: #f4f6ef;
  text-align: center;
  color: var(--muted);
}
.product-placeholder strong {
  color: var(--ink);
  font-size: 20px;
  overflow-wrap: anywhere;
}
.product-placeholder small {
  font-size: 12px;
}
.product-card .card-actions a,
.product-card .card-actions button {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  min-height: 48px;
  height: 100%;
}
.product-card h2 {
  overflow-wrap: anywhere;
}
.contact-person small {
  display: block;
  line-height: 1.5;
}
.contact-person a {
  padding: 5px 0;
}
.scene-night .journey-progress,
.scene-night .scene-tools {
  color: var(--ink);
}
.simple-mode .control-panel {
  transform: none;
}

@media (min-width: 901px) and (max-height: 700px) {
  .intro {
    top: 87px;
  }
  .intro h1 {
    font-size: 43px;
  }
  .intro p {
    font-size: 13px;
  }
  .intro-note {
    display: none;
  }
  .control-panel,
  .experience.focused .control-panel {
    top: 80px;
    max-height: calc(100% - 176px);
  }
}
@media (min-width: 901px) and (max-width: 1150px) {
  .brand-logo {
    width: 225px;
  }
  .header {
    gap: 22px;
  }
  .header nav a,
  .header nav #header-plan {
    font-size: 15px;
  }
  .scene-tools {
    gap: 8px;
    padding: 5px 8px;
  }
  .scene-tools .scenario-buttons button {
    padding: 8px;
    font-size: 11px;
  }
  .scene-tools .time-control {
    padding-left: 8px;
  }
  .scene-tools input {
    width: 85px;
  }
  .intro {
    max-width: 270px;
  }
}
@media (max-width: 900px) {
  :root {
    --header-height: 112px;
  }
  .header {
    display: grid;
    grid-template-columns: 1fr auto;
    grid-template-rows: 62px 50px;
    gap: 0 12px;
    margin: 0 4%;
  }
  .brand {
    padding: 0;
    width: max-content;
  }
  .brand-logo {
    width: 180px;
    height: 58px;
  }
  .header nav {
    grid-row: 2;
    grid-column: 1 / -1;
    margin: 0;
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: center;
    padding-bottom: 5px;
  }
  .header nav a,
  .header nav #header-plan,
  .header nav > a:first-child {
    font-size: 15px;
    font-weight: 800;
    max-width: none;
  }
  .contact-link {
    grid-row: 1;
    grid-column: 2;
    font-size: 12px;
    min-height: 40px;
    padding: 11px 14px;
    margin: 0;
  }
  .contact-link span {
    display: none;
  }
  .scene-tools {
    top: 8px;
    left: 12px;
    right: 12px;
    gap: 0;
    padding: 4px 8px;
    display: grid;
    border-radius: 14px;
  }
  .scene-tools .scenario-buttons {
    justify-content: space-between;
    gap: 0;
  }
  .scene-tools .scenario-buttons button {
    min-height: 36px;
    padding: 8px 9px;
    font-size: 11px;
  }
  .scene-tools .time-control {
    border-left: 0;
    border-top: 1px solid var(--line);
    padding: 1px 6px 0;
    height: 32px;
    gap: 10px;
  }
  .scene-tools .time-control label {
    font-size: 11px;
    min-width: 60px;
  }
  .scene-tools input {
    flex: 1;
    width: 100%;
    height: 28px;
  }
  .intro {
    top: 94px;
    left: 5%;
    max-width: 90%;
    pointer-events: auto;
    touch-action: pinch-zoom;
  }
  .intro .eyebrow {
    display: none;
  }
  .intro h1 {
    font-size: 31px;
    letter-spacing: -1.5px;
    margin: 0;
    line-height: 1.1;
  }
  .intro h1 br {
    display: none;
  }
  .intro h1 em {
    display: block;
  }
  .intro p,
  .intro .primary {
    display: none;
  }
  .intro-note {
    display: block;
    font-size: 10px;
    margin-top: 8px;
  }
  #world {
    inset: 185px 0 100px;
    height: auto;
  }
  .experience.focused #world {
    inset: 86px 0 calc(min(34dvh, 280px) + 82px);
    height: auto;
  }
  .control-panel,
  .experience.focused .control-panel,
  .simple-mode .control-panel {
    top: auto !important;
    left: 12px !important;
    bottom: 78px;
    width: calc(100% - 24px);
    max-height: min(34dvh, 280px) !important;
    padding: 14px 18px;
    border-radius: 15px;
    transform: none;
    background: #fffef9fa;
  }
  .control-panel .eyebrow {
    display: none;
  }
  .control-panel h2 {
    font-size: 21px;
    margin: 0 0 6px;
    letter-spacing: -0.5px;
  }
  .control-panel p {
    font-size: 12px;
    line-height: 1.5;
    margin: 6px 0 12px;
  }
  .control-panel .panel-note {
    font-size: 10px !important;
  }
  .control-panel .control {
    margin: 12px 0;
  }
  .control-panel label,
  .toggle-row {
    font-size: 13px;
  }
  .toggle-row {
    margin: 10px 0;
  }
  .camera-feed {
    max-width: 260px;
    margin: 10px auto;
  }
  .journey-progress {
    left: 12px;
    bottom: 10px;
    width: calc(100% - 78px);
    height: 60px;
    gap: 8px;
    padding: 5px 7px;
    border-radius: 14px;
  }
  .journey-progress strong {
    font-size: 12px;
    margin: 1px 0;
  }
  .journey-progress small {
    font-size: 9px;
  }
  .journey-progress span {
    font-size: 8px;
  }
  .journey-progress button {
    min-width: 38px;
    min-height: 44px;
  }
  .motion-toggle {
    right: 14px;
    bottom: 19px;
  }
  .toast {
    bottom: calc(min(34dvh, 280px) + 96px);
    font-size: 12px;
    padding: 10px 15px;
    max-width: 80vw;
  }
  .energy-chip,
  .experience.focused .energy-chip {
    right: 12px;
    left: auto;
    bottom: 81px;
    padding: 7px 11px;
    gap: 7px;
    border-radius: 10px;
  }
  .energy-chip strong {
    font-size: 15px;
  }
  .energy-chip small {
    font-size: 7px;
    margin-bottom: 3px;
  }
  .energy-chip .energy-icon {
    font-size: 20px;
  }
  .experience.focused .energy-chip {
    display: none;
  }
  .back-house {
    left: 12px;
    top: 92px;
    font-size: 10px;
    padding: 8px 11px;
    min-height: 36px;
  }
  .roof-return {
    top: 92px;
    right: 12px;
    min-height: 36px;
    font-size: 11px;
    padding: 8px 11px;
  }
  .hotspot {
    font-size: 9px;
    padding: 5px 7px 5px 5px;
    gap: 4px;
    min-height: 32px;
  }
  .hotspot b {
    width: 18px;
    min-width: 18px;
    height: 18px;
  }
  /* The small-screen roof stays touchable; discovery happens through the journey. */
  #hotspots {
    display: none;
  }
  .product-placeholder {
    padding: 12px;
    margin-bottom: 20px;
  }
  .product-placeholder strong {
    font-size: 15px;
  }
  .product-placeholder small {
    font-size: 10px;
  }
  .simple-mode #controls {
    top: 90px !important;
    bottom: 78px;
    max-height: none !important;
  }
}
@media (max-width: 900px) and (max-height: 520px) and (orientation: landscape) {
  :root {
    --header-height: 62px;
  }
  .header {
    display: flex;
    gap: 18px;
  }
  .brand-logo {
    width: 155px;
    height: 55px;
  }
  .header nav {
    flex: 1;
    gap: 15px;
    justify-content: flex-end;
    padding: 0;
  }
  .header nav a,
  .header nav #header-plan,
  .header nav > a:first-child {
    font-size: 12px;
  }
  .scene-tools {
    left: auto;
    right: 12px;
    width: calc(100% - 290px);
    display: flex;
    flex-wrap: wrap;
    padding: 3px;
  }
  .scene-tools .scenario-buttons {
    width: 100%;
  }
  .scene-tools .time-control {
    width: 100%;
  }
  #world,
  .experience.focused #world {
    inset: 0;
  }
  .control-panel,
  .experience.focused .control-panel {
    top: 52px !important;
    bottom: 72px;
    width: 255px;
    max-height: none !important;
  }
  .back-house {
    top: 6px;
  }
  .journey-progress {
    width: 255px;
  }
  .intro {
    top: 25px;
    max-width: 260px;
  }
  .intro h1 {
    font-size: 29px;
  }
  .motion-toggle {
    right: 12px;
    bottom: 12px;
  }
  .roof-return {
    top: 90px;
  }
}
.products-page {
  max-width: none;
  padding-inline: clamp(16px, 3vw, 64px);
}
.products-page .catalogue-grid {
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr));
  gap: 18px;
}
.products-page .product-card { padding: 16px; min-width: 0; }
.products-page .product-card img { margin-bottom: 12px; }
.products-page .product-card h2 { font-size: 18px; margin: 8px 0 5px; min-height: 0; }
.products-page .product-model { min-height: 0; }
.products-page .product-card > p { margin: 8px 0 14px; font-size: 13px; line-height: 1.5; }
.product-purchase {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: auto;
  padding-top: 8px;
}
.product-purchase .product-price { margin: 0; padding: 0; font-size: 21px; min-width: 0; }
.product-purchase .product-price small { margin-top: 4px; line-height: 1.35; }
.product-card .product-purchase .card-actions { display: flex; margin: 0; flex-shrink: 0; }
.product-card .product-purchase .card-actions button { height: auto; min-height: 44px; padding: 10px 12px; white-space: nowrap; font-size: 12px; }

/* One typography rule for every primary navigation destination. */
.header { --navigation-font-size: 17px; }
.header nav > a,
.header nav > a:first-child,
.header nav #header-home,
.header nav #header-plan,
.header > .contact-link {
  font-family: var(--font);
  font-size: var(--navigation-font-size);
  font-weight: 800;
  line-height: 1.3;
  letter-spacing: normal;
  display: inline-flex;
  align-items: center;
}
@media (max-width: 1150px) {
  .header { --navigation-font-size: 15px; }
}
@media (max-width: 900px) and (max-height: 520px) and (orientation: landscape) {
  .header { --navigation-font-size: 12px; }
}
