/* Content-section responsive ownership: Sec02, 03, 06, 07, 08 and 09. */

/* Sec08 rail is decorative context and never captures interaction. */
.site-home #about .about-nav-rail {
  z-index: 1;
  pointer-events: none;
  opacity: 0.58;
}

.site-home #about .about-rail-item,
.site-home #about .about-rail-item:hover {
  display: block;
  padding: 5px 8px;
  border-radius: 0;
  background: none;
  color: #71849b;
  box-shadow: none;
  transition: none;
}

.site-home #about .about-rail-item.active {
  padding-left: 6px;
  border-left: 2px solid #076dff;
  background: none;
  color: #1d65c9;
  box-shadow: none;
}

/* Sec09 在中型桌面保留 HUD 並收進 1180px 內容軌外；側欄不足時讓 FAQ 取得完整閱讀空間。 */
@media (min-width: 1360px) and (max-width: 1671px) { .site-home #faq .faq-hud-margin { max-width: 70px; font-size: 9px; letter-spacing: 0.08em; line-height: 1.7; overflow-wrap: anywhere; } .site-home #faq :where(.faq-hud-left-top, .faq-hud-left-bottom) { left: 18px; } .site-home #faq :where(.faq-hud-right-top, .faq-hud-right-bottom) { right: 18px; } .site-home #faq .faq-hud-footer-status { right: 18px; max-width: 60px; font-size: 9px; letter-spacing: 0.08em; line-height: 1.5; text-align: right; } }
@media (max-width: 1359px) { .site-home #faq :where(.faq-hud-margin, .faq-hud-footer-status) { display: none; } }

@media (max-width: 1599px) {
  .site-home #about .about-nav-rail { display: none; }
}

@media (min-width: 1440px) and (max-width: 1599px) {
  html[data-about-rail="background"] .site-home #about .about-nav-rail {
    display: flex;
    left: 4px;
    gap: 7px;
    opacity: 0.42;
  }

  html[data-about-rail="background"] .site-home #about .about-rail-item,
  html[data-about-rail="background"] .site-home #about .about-rail-item:hover {
    padding: 4px 0;
    font-size: 9px;
    letter-spacing: 0.02em;
  }

  html[data-about-rail="background"] .site-home #about .about-rail-item.active {
    padding-left: 2px;
    border-left-width: 1px;
  }
}

@media (max-width: 880px) {
  /* Sec03 keeps the summary and route scope readable without duplicating nav. */
  .site-home .services-footer-hint {
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
  }

  .site-home .services-footer-hint__scope {
    align-items: flex-start;
    flex-direction: column;
    gap: 4px;
  }

  .site-home .services-footer-hint .hint-sep {
    display: none;
  }

  /* Sec06 switches to icon-left, content-right cards. */
  .site-home .how-stage-card {
    display: grid;
    grid-template-areas:
      "header header"
      "badge content"
      "badge divider"
      "badge footer";
    grid-template-columns: 72px minmax(0, 1fr);
    column-gap: 16px;
    align-content: start;
    align-items: start;
    min-height: 0;
    justify-content: initial;
  }

  .site-home .how-card-header {
    grid-area: header;
    min-width: 0;
    margin-bottom: 12px;
  }

  .site-home .how-card-badge {
    grid-area: badge;
    width: 72px;
    height: 72px;
    margin: 0;
  }

  .site-home .badge-diamond-box {
    width: 50px;
    height: 50px;
  }

  .site-home .badge-icon-svg { --badge-hover-scale: 1.45; }
  .site-home .badge-poc-svg { --badge-hover-scale: 1.18; }

  .site-home .how-card-content {
    grid-area: content;
    min-width: 0;
    flex: initial;
  }

  .site-home .how-card-divider {
    grid-area: divider;
    margin: 12px 0 8px;
  }

  .site-home .how-card-footer {
    grid-area: footer;
    min-width: 0;
    gap: 8px;
  }

  .site-home .how-stage-out {
    min-width: 0;
    overflow-wrap: anywhere;
  }

  .site-home .how-stage-idx { flex: 0 0 auto; }

  /* Sec07 changes from a horizontal record to reading order. */
  .site-home .insights-glass-card {
    padding: clamp(22px, 4vw, 32px) clamp(18px, 4vw, 32px);
  }

  .site-home .insights-header-row {
    flex-direction: column;
    align-items: stretch;
    gap: 14px;
    margin-bottom: 20px;
  }

  .site-home .insights-header-left,
  .site-home .editorial-content {
    min-width: 0;
  }

  .site-home .insights-header-right {
    align-self: flex-start;
  }

  .site-home .editorial-row {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
    padding: 20px 0;
    cursor: default;
  }

  .site-home .editorial-row:hover { padding-left: 0; }

  .site-home .editorial-meta {
    width: auto;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 12px;
  }

  .site-home .editorial-divider-v { display: none; }
  .site-home .editorial-content { padding: 0; }

  .site-home .editorial-action {
    width: auto;
    align-self: flex-end;
    text-align: right;
  }

  .site-home .editorial-link { min-height: 44px; }
}

@media (max-width: 600px) {
  /* Sec09 gives FAQ copy priority over peripheral HUD. */
  .site-home #faq .faq-relative-container {
    padding-inline: 20px;
  }

  .site-home #faq .faq-glass-card {
    padding-inline: 18px;
  }

  /* Sec08 changes the 2-by-2 fact cards into a full-width list. */
  .site-home .about-nav-rail { display: none; }

  .site-home .about-facts-grid {
    grid-template-columns: minmax(0, 1fr);
    grid-auto-rows: auto;
    gap: 12px;
  }

  .site-home .about-fact-card,
  .site-home .fact-text-content {
    min-width: 0;
  }

  .site-home .how-subhead {
    letter-spacing: 0.04em;
  }

  .site-home #proof .proof-tail {
    min-height: 88px;
  }

  .site-home #proof .proof-tail-left {
    left: 24px;
    bottom: 18px;
    width: calc(100% - 160px);
    min-width: 0;
  }

  .site-home #proof .proof-tail-copy {
    min-width: 0;
  }

  .site-home #proof .proof-tail-right {
    right: 24px;
    bottom: 18px;
    width: 96px;
  }

  html[lang="en"] .site-home #proof .proof-tail-copy span {
    display: block;
    max-width: 185px;
    line-height: 1.25;
    white-space: normal;
  }

  .site-home #proof .proof-stat {
    font-size: 25px;
    white-space: nowrap;
  }

  .site-home #proof .proof-item:last-child .proof-stat {
    white-space: normal;
  }

  .site-home #proof .stat-unit {
    font-size: 18px;
  }

  .site-home #proof .stat-prefix {
    font-size: 12px;
    letter-spacing: 0.02em;
  }
}

@media (max-width: 380px) {
  .site-home #proof .proof-band {
    grid-template-columns: minmax(0, 1fr);
  }

  .site-home #proof .proof-stat {
    font-size: 22px;
  }

  .site-home #proof .stat-prefix {
    font-size: 11px;
  }

  .site-home #proof .stat-unit {
    font-size: 16px;
  }
}
