/* Homepage amendments approved 2026-07-26.
   This file loads last so the requested layout stays deterministic across
   the homepage's historical responsive and section-specific stylesheets. */

/* Product-page quick navigation, reused on the homepage. */
.homepage-page-nav {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  justify-content: center;
  gap: 6px;
  padding: 11px;
  overflow-x: auto;
  border-bottom: 1px solid rgba(112, 65, 46, .10);
  background: rgba(255, 248, 243, .92);
  box-shadow: 0 10px 30px rgba(14, 17, 19, .04);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  scrollbar-width: none;
}

.homepage-page-nav::-webkit-scrollbar {
  display: none;
}

.homepage-page-nav a {
  flex: 0 0 auto;
  padding: 10px 14px;
  border-radius: 999px;
  color: rgba(14, 17, 19, .68);
  font-size: 13px;
  font-weight: 800;
  line-height: 1.2;
  white-space: nowrap;
  transition: background-color .2s ease, color .2s ease, transform .2s ease;
}

.homepage-page-nav a:hover,
.homepage-page-nav a:focus-visible {
  color: #70412e;
  background: rgba(158, 92, 63, .10);
  transform: translateY(-1px);
}

.homepage-page-nav .page-nav__logo {
  position: absolute;
  left: max(24px, calc((100vw - 1080px) / 2));
  top: 50%;
  width: 104px;
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  padding: 5px 8px;
  border: 0;
  background: transparent;
  transform: translateY(-50%);
}

.homepage-page-nav .page-nav__logo:hover,
.homepage-page-nav .page-nav__logo:focus-visible {
  border: 0;
  background: rgba(158, 92, 63, .08);
  transform: translateY(-50%);
}

.homepage-page-nav .page-nav__logo img {
  width: 100%;
  height: auto;
}

/* Desktop header parity with the current product pages.
   Mobile keeps the locked Wall-Top navigation baseline. */
@media (min-width: 901px) {
  .hero .site-header {
    position: relative;
    z-index: 5;
    width: min(1080px, calc(100% - 72px)) !important;
    margin: 0 auto;
    padding: 30px 0 0 !important;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 28px !important;
  }

  .hero .site-header .brand img {
    width: auto;
    height: 46px;
    filter: drop-shadow(0 10px 24px rgba(14, 17, 19, .12)) !important;
  }

  .hero .site-header .nav-links {
    display: flex;
    align-items: center;
    gap: 6px !important;
    padding: 4px 6px !important;
    border: 1px solid rgba(255, 255, 255, .12) !important;
    border-radius: 999px !important;
    background: rgba(8, 11, 13, .24) !important;
    color: rgba(255, 255, 255, .78);
    font-family: Montserrat, Inter, sans-serif;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: .02em;
    box-shadow: 0 12px 34px rgba(0, 0, 0, .14) !important;
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
  }

  .hero .site-header .nav-links > a {
    padding: 7px 10px !important;
    border-radius: 999px !important;
    background: transparent !important;
    color: rgba(255, 255, 255, .82);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .02em;
    white-space: nowrap;
    transition: color .2s ease, transform .2s ease;
  }

  .hero .site-header .nav-links > a:hover,
  .hero .site-header .nav-links > a[aria-current="page"] {
    color: #fde6d6;
    background: transparent !important;
    transform: translateY(-1px);
  }

  .hero .site-header .nav-dropdown__trigger {
    padding: 10px 14px;
    border-radius: 999px;
  }

  .hero .site-header .nav-dropdown:hover > .nav-dropdown__trigger,
  .hero .site-header .nav-dropdown.is-open > .nav-dropdown__trigger,
  .hero .site-header .nav-dropdown:focus-within > .nav-dropdown__trigger {
    color: #fde6d6;
    background: rgba(255, 255, 255, .10);
  }

  .hero .site-header .nav-dropdown__panel {
    top: calc(100% + 12px);
    box-shadow: 0 24px 70px rgba(0, 0, 0, .24);
  }
}

/* The map and cards were separated by competing inherited margins.
   These desktop-only rules make Section 3 visibly shorter without
   changing the approved mobile composition. */
@media (min-width: 1041px) {
  .ecosystem-section {
    padding-top: 52px !important;
    padding-bottom: 64px !important;
  }

  .ecosystem-intro {
    margin-bottom: 0 !important;
  }

  .ag-property-section {
    margin-top: 12px !important;
    margin-bottom: 14px !important;
    padding: 0 !important;
  }

  .ag-canva-map .ag-map-card {
    padding: 10px !important;
  }

  .ag-canva-map .ag-product-tabs {
    min-height: 0;
    margin-top: 10px !important;
    padding: 6px !important;
  }

  .ag-canva-map .ag-product-tabs button {
    min-height: 44px !important;
  }
}

/* Supplied Mini Alarm Hub image for the fourth product card. */
.ecosystem-card__hub-figure {
  overflow: hidden;
  background: #f7f1ea !important;
}

.ecosystem-card figure .ecosystem-card__hub-image {
  width: 100%;
  height: clamp(190px, 15vw, 218px) !important;
  object-fit: cover;
  object-position: center 54%;
}

/* Installer comparison number emphasis. */
.installer-comparison--proof .installer-emphasis {
  display: inline-block;
  margin-right: .12em;
  color: #9e5c3f;
  font-family: Montserrat, Inter, sans-serif;
  font-size: 1.38em;
  font-weight: 900;
  line-height: .8;
  letter-spacing: -.045em;
}

.installer-comparison--proof .installer-emphasis--wide {
  margin-right: .18em;
  font-size: 1.30em;
}

/* Installer section desktop reflow, approved 2026-07-28.
   Lift the timeline and headline as one composition, then reserve enough
   space for the comparison panel so the two elements never overlap.
   Tablet and mobile keep their existing layout unchanged. */
@media (min-width: 1041px) {
  .workflow-diagram {
    margin-top: clamp(-360px, -27vw, -334px) !important;
  }

  .installer-comparison--proof {
    margin-top: clamp(82px, 7.5vw, 112px) !important;
  }
}

/* Mini Alarm Hub local-response section. */
.alarm-response-section {
  position: relative;
  overflow: hidden;
  padding: clamp(76px, 7.5vw, 112px) 0;
  color: #0e1113;
  background:
    radial-gradient(circle at 10% 14%, rgba(253, 230, 214, .84), transparent 28%),
    linear-gradient(180deg, #fffaf6 0%, #f7f1ea 100%);
}

.alarm-response-section::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(112, 65, 46, .035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(112, 65, 46, .03) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: linear-gradient(180deg, transparent, #000 14%, #000 86%, transparent);
  pointer-events: none;
}

.alarm-response-shell {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(320px, .74fr) minmax(520px, 1.16fr);
  gap: clamp(44px, 6vw, 86px);
  align-items: center;
}

.alarm-response-copy {
  max-width: 520px;
}

.alarm-response-copy h2 {
  margin: 0;
  color: #0e1113;
  font-family: Montserrat, Inter, sans-serif;
  font-size: clamp(38px, 4.6vw, 60px);
  font-weight: 700;
  line-height: .95;
  letter-spacing: -.055em;
}

.alarm-response-copy > p:last-of-type {
  margin: 24px 0 0;
  color: rgba(42, 46, 49, .74);
  font-size: clamp(16px, 1.1vw, 18px);
  line-height: 1.66;
  letter-spacing: -.012em;
}

.alarm-response-learn-more {
  width: fit-content;
  margin-top: 28px;
}

.alarm-response-learn-more:focus-visible {
  outline: 3px solid rgba(112, 65, 46, .32);
  outline-offset: 4px;
}

.alarm-response-visual {
  position: relative;
  margin: 0;
  min-height: clamp(430px, 44vw, 620px);
  overflow: hidden;
  border: 1px solid rgba(112, 65, 46, .10);
  border-radius: 10px;
  background: #18130f;
  box-shadow: 0 30px 86px rgba(72, 46, 29, .16);
}

.alarm-response-visual img {
  width: 100%;
  height: 100% !important;
  min-height: clamp(430px, 44vw, 620px) !important;
  aspect-ratio: auto;
  object-fit: cover;
  object-position: center center;
}

/* Mobile Control typography aligned with the shared section scale. */
.mobile-app-copy h2 {
  font-size: clamp(38px, 4.6vw, 60px) !important;
}

.mobile-app-visual figcaption span {
  font-size: 10.5px !important;
}

.mobile-app-visual figcaption strong {
  font-size: clamp(17px, 1.35vw, 20px) !important;
}

@media (max-width: 1180px) {
  .homepage-page-nav .page-nav__logo {
    left: 14px;
    width: 88px;
  }

  .homepage-page-nav {
    padding-left: 112px;
  }
}

@media (max-width: 1040px) {
  .alarm-response-shell {
    grid-template-columns: 1fr;
  }

  .alarm-response-copy {
    max-width: none;
  }
}

@media (max-width: 900px) {
  .homepage-page-nav {
    justify-content: flex-start;
    padding-left: 10px;
  }

  .homepage-page-nav .page-nav__logo {
    position: sticky;
    left: 0;
    z-index: 2;
    flex: 0 0 82px;
    width: 82px;
    background: rgba(255, 250, 246, .96);
  }
}

@media (max-width: 700px) {
  .homepage-page-nav {
    padding-top: 8px;
    padding-bottom: 8px;
  }

  .homepage-page-nav a {
    padding: 9px 12px;
    font-size: 12px;
  }

  .alarm-response-section {
    padding: 64px 0;
  }

  .alarm-response-shell {
    width: min(100% - 40px, var(--hero-max));
    gap: 30px;
  }

  .alarm-response-copy h2 {
    font-size: clamp(34px, 10vw, 46px);
  }

  .alarm-response-copy > p:last-of-type {
    margin-top: 18px;
    font-size: 15.5px;
    line-height: 1.58;
  }

  .alarm-response-learn-more {
    width: fit-content;
    margin-top: 24px;
  }

  .alarm-response-visual,
  .alarm-response-visual img {
    min-height: 360px !important;
  }

  .mobile-app-copy h2 {
    font-size: clamp(34px, 10vw, 46px) !important;
  }

  .mobile-app-visual figcaption strong {
    font-size: 17px !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  .homepage-page-nav a {
    transition: none;
  }
}

/* 2026-07-26 mobile ecosystem QA fixes.
   This file loads last, so these rules intentionally resolve older
   responsive layers without changing the approved desktop composition. */
.ag-product-tabs-help {
  display: none;
}

@media (max-width: 760px) {
  /* Section heading: collapse the desktop split before sizing the type. */
  .ecosystem-section .ecosystem-intro {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 16px !important;
    align-items: start !important;
    margin-bottom: 24px !important;
  }

  .ecosystem-section .ecosystem-intro > div,
  .ecosystem-section .ecosystem-intro h2,
  .ecosystem-section .ecosystem-lead {
    width: 100% !important;
    min-width: 0 !important;
    max-width: none !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
  }

  .ecosystem-section .ecosystem-intro h2 {
    font-size: clamp(32px, 10vw, 43px) !important;
    line-height: 1.01 !important;
    letter-spacing: -.05em !important;
  }

  .ecosystem-section .ecosystem-lead {
    margin-top: 14px !important;
    font-size: 15px !important;
    line-height: 1.55 !important;
  }

  /* Four map shortcuts: two columns with clear touch feedback. */
  .ag-canva-map .ag-product-tabs {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 6px !important;
  }

  .ag-canva-map .ag-product-tabs button {
    min-width: 0 !important;
    min-height: 42px !important;
    padding: 7px 8px !important;
    font-size: 12px !important;
    line-height: 1.15 !important;
    touch-action: manipulation;
    -webkit-user-select: none;
    user-select: none;
  }

  .ag-canva-map .ag-product-tabs button:active {
    transform: scale(.98);
  }

  .ag-product-tabs-help {
    display: block;
    margin: 7px 4px 0;
    color: rgba(42, 46, 49, .62);
    font-size: 10px;
    font-weight: 650;
    letter-spacing: .01em;
    text-align: center;
  }

  /* Keep every modal edge and the close control inside the dynamic viewport. */
  .ag-product-modal {
    box-sizing: border-box !important;
    place-items: center !important;
    padding:
      max(8px, env(safe-area-inset-top))
      max(8px, env(safe-area-inset-right))
      max(8px, env(safe-area-inset-bottom))
      max(8px, env(safe-area-inset-left)) !important;
    overflow: hidden !important;
  }

  .ag-product-panel {
    box-sizing: border-box !important;
    width: min(400px, calc(100vw - 16px)) !important;
    max-height: calc(100dvh - 16px) !important;
    padding: 14px !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    overscroll-behavior: contain;
    border-radius: 18px !important;
  }

  .ag-modal-close {
    position: sticky !important;
    z-index: 3 !important;
    top: 0 !important;
    right: auto !important;
    float: right;
    min-height: 32px !important;
    margin: 0 0 -26px 8px !important;
    padding: 0 10px !important;
    font-size: 11px !important;
  }

  .ag-panel-kicker {
    padding-top: 2px !important;
  }

  .ag-product-panel h3 {
    padding-right: 64px !important;
    font-size: clamp(22px, 6.6vw, 29px) !important;
  }

  .ag-panel-copy {
    margin: 8px 0 9px !important;
    font-size: 12.5px !important;
    line-height: 1.38 !important;
  }

  .ag-panel-media {
    min-height: 96px !important;
    margin-bottom: 8px !important;
  }

  .ag-panel-media img {
    max-height: 104px !important;
  }

  .ag-panel-media--use-cases {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 6px !important;
    padding: 6px !important;
  }

  .ag-use-case-card img {
    height: 86px !important;
  }

  .ag-use-case-card figcaption {
    padding: 7px 5px !important;
    font-size: 10px !important;
  }

  .ag-spec-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 6px !important;
  }

  .ag-spec-grid div {
    min-height: 48px !important;
    padding: 7px 8px !important;
  }

  .ag-spec-grid span {
    font-size: 9px !important;
  }

  .ag-spec-grid strong {
    font-size: 11.5px !important;
  }

  .ag-event-card {
    grid-template-columns: minmax(0, 1fr) auto !important;
    gap: 8px !important;
    margin-top: 8px !important;
    padding: 9px !important;
  }

  .ag-event-card strong {
    font-size: 12.5px !important;
  }

  .ag-event-learn-more {
    width: auto !important;
    min-height: 34px !important;
    padding: 0 11px !important;
    font-size: 11px !important;
  }

  /* Four linked products: compact 2-by-2 mobile catalogue. */
  .ecosystem-section .ecosystem-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 10px !important;
  }

  .ecosystem-section .ecosystem-card {
    min-width: 0 !important;
    border-radius: 18px !important;
  }

  .ecosystem-section .ecosystem-card figure,
  .ecosystem-section .ecosystem-card figure img,
  .ecosystem-section .ecosystem-card .ecosystem-card__hub-image {
    height: clamp(88px, 25vw, 106px) !important;
  }

  .ecosystem-section .ecosystem-card__body {
    padding: 11px !important;
  }

  .ecosystem-section .ecosystem-card .card-index {
    margin-bottom: 5px !important;
    font-size: 8px !important;
    letter-spacing: .08em !important;
  }

  .ecosystem-section .ecosystem-card h3 {
    margin: 0 !important;
    font-size: clamp(14px, 4.1vw, 17px) !important;
    line-height: 1.08 !important;
    letter-spacing: -.025em !important;
  }

  .ecosystem-section .ecosystem-card p:not(.card-index) {
    display: none !important;
  }
}
