/* Technologies page — core tech explorer */

.tech-core {
  background: linear-gradient(180deg, var(--color-warm-bg) 0%, #fff 28%);
  padding-top: var(--space-xl);
  padding-bottom: var(--space-2xl);
}

.tech-core .section-header {
  max-width: 42rem;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

.tech-explorer {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) minmax(320px, 1.15fr);
  gap: var(--space-lg);
  align-items: stretch;
  margin-top: var(--space-lg);
}

/* Building stack visual */
.tech-stack-wrap {
  position: relative;
  padding: var(--space-md);
  background: linear-gradient(165deg, var(--color-deep) 0%, var(--color-teal) 55%, var(--color-teal-light) 100%);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  min-height: 420px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  overflow: hidden;
}

.tech-stack-wrap::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 80% 60% at 50% 100%, rgba(var(--rgb-gold), 0.2), transparent 70%);
  pointer-events: none;
}

.tech-stack__label {
  position: relative;
  z-index: 2;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(232, 240, 242, 0.65);
  text-align: center;
  margin-bottom: var(--space-sm);
}

.tech-stack {
  position: relative;
  z-index: 2;
  width: min(220px, 72%);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.tech-stack__layer {
  height: 44px;
  border-radius: 6px;
  border: 2px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
  transition:
    background 0.45s cubic-bezier(0.16, 1, 0.3, 1),
    border-color 0.45s cubic-bezier(0.16, 1, 0.3, 1),
    box-shadow 0.45s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.45s cubic-bezier(0.16, 1, 0.3, 1),
    opacity 0.35s ease;
  opacity: 0.45;
}

.tech-stack__layer span {
  display: block;
  font-size: 0.65rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.5);
  padding: 0.35rem 0.5rem;
  line-height: 1.2;
}

.tech-stack.is-active-envelope .tech-stack__layer--envelope,
.tech-stack.is-active-glazing .tech-stack__layer--glazing,
.tech-stack.is-active-structure .tech-stack__layer--structure,
.tech-stack.is-active-air .tech-stack__layer--air,
.tech-stack.is-active-energy .tech-stack__layer--energy,
.tech-stack.is-active-water .tech-stack__layer--water {
  opacity: 1;
  border-color: var(--color-accent);
  background: rgba(var(--rgb-gold), 0.28);
  box-shadow: 0 0 24px rgba(var(--rgb-gold), 0.35);
  transform: scaleX(1.04);
}

.tech-stack__layer--energy {
  height: 36px;
  border-radius: 8px 8px 4px 4px;
}

.tech-stack__layer--envelope {
  height: 52px;
}

.tech-stack__layer--glazing {
  height: 32px;
  margin: 0 12%;
}

.tech-stack__layer--structure {
  height: 56px;
}

.tech-stack__layer--air {
  height: 40px;
}

.tech-stack__layer--water {
  height: 28px;
  border-radius: 4px 4px 8px 8px;
}

.tech-stack__flow {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: center;
  gap: var(--space-xs);
  margin-top: var(--space-md);
  flex-wrap: wrap;
}

.tech-stack__flow span {
  font-size: 0.7rem;
  color: rgba(232, 240, 242, 0.75);
  padding: 0.25rem 0.6rem;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.12);
}

/* Right panel */
.tech-explorer__panel {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.tech-explorer__nav {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-xs);
}

.tech-nav-btn {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  text-align: left;
  padding: 0.75rem 0.85rem;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  cursor: pointer;
  font-family: inherit;
  color: var(--color-text);
  transition:
    border-color 0.35s cubic-bezier(0.16, 1, 0.3, 1),
    background 0.35s cubic-bezier(0.16, 1, 0.3, 1),
    box-shadow 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.tech-nav-btn:hover {
  border-color: var(--color-teal-light);
  background: var(--color-warm-bg);
}

.tech-nav-btn[aria-selected="true"] {
  border-color: var(--color-accent);
  background: rgba(var(--rgb-gold), 0.08);
  box-shadow: 0 4px 20px rgba(var(--rgb-gold), 0.15);
}

.tech-nav-btn__icon {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(var(--rgb-teal), 0.08);
  border-radius: var(--radius);
  color: var(--color-teal);
}

.tech-nav-btn[aria-selected="true"] .tech-nav-btn__icon {
  background: var(--color-teal);
  color: #fff;
}

.tech-nav-btn__icon svg {
  width: 20px;
  height: 20px;
}

.tech-nav-btn__text strong {
  display: block;
  font-size: 0.8125rem;
  font-weight: 600;
  line-height: 1.3;
}

.tech-nav-btn__text em {
  display: block;
  font-size: 0.6875rem;
  font-style: normal;
  color: var(--color-text-muted);
  margin-top: 0.15rem;
}

.tech-detail {
  flex: 1;
  padding: var(--space-lg);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}

.tech-detail::before {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 140px;
  height: 140px;
  background: radial-gradient(circle, rgba(var(--rgb-gold), 0.12), transparent 70%);
  pointer-events: none;
}

.tech-detail__badge {
  display: inline-block;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-teal);
  background: rgba(var(--rgb-gold), 0.12);
  padding: 0.3rem 0.65rem;
  border-radius: 999px;
  margin-bottom: var(--space-sm);
}

.tech-detail h3 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  margin: 0 0 var(--space-sm);
  color: var(--color-deep);
}

.tech-detail p {
  margin: 0 0 var(--space-md);
  color: var(--color-text-muted);
  max-width: 36rem;
}

.tech-detail__facts {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
  margin: 0;
  padding: 0;
  list-style: none;
}

.tech-detail__facts li {
  flex: 1 1 8rem;
  padding: var(--space-sm);
  background: var(--color-warm-bg);
  border-radius: var(--radius);
  border: 1px solid var(--color-border);
}

.tech-detail__facts strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.125rem;
  color: var(--color-accent);
  margin-bottom: 0.2rem;
}

.tech-detail__facts span {
  font-size: 0.75rem;
  color: var(--color-text-muted);
}

.tech-detail.is-changing {
  opacity: 0.6;
  transform: translateY(6px);
  transition:
    opacity 0.2s ease,
    transform 0.2s ease;
}

/* Connector line animation between nav and detail */
.tech-core__hint {
  text-align: center;
  font-size: 0.875rem;
  color: var(--color-text-muted);
  margin-top: var(--space-md);
}

@media (max-width: 900px) {
  .tech-explorer {
    grid-template-columns: 1fr;
  }

  .tech-stack-wrap {
    min-height: 320px;
  }

  .tech-explorer__nav {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 600px) {
  .tech-explorer__nav {
    grid-template-columns: repeat(2, 1fr);
  }

  .tech-nav-btn {
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 0.65rem 0.5rem;
  }

  .tech-nav-btn__text em {
    display: none;
  }
}

/* Envelope & openings redesign */
.tech-envelope .section-header {
  max-width: 44rem;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

.tech-envelope-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-lg);
  margin-top: var(--space-lg);
}

.tech-envelope-panel {
  display: flex;
  flex-direction: column;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.tech-envelope-panel__visual {
  padding: var(--space-md);
  background: linear-gradient(165deg, #e8f0f2 0%, var(--color-warm-bg) 100%);
  border-bottom: 1px solid var(--color-border);
}

.tech-envelope-panel__visual--openings {
  background: linear-gradient(165deg, rgba(var(--rgb-gold), 0.08) 0%, var(--color-warm-bg) 100%);
}

.tech-envelope-panel__visual-label {
  margin: 0 0 var(--space-sm);
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-teal);
  text-align: center;
}

.tech-envelope-diagram__svg {
  display: block;
  width: 100%;
  max-width: 220px;
  margin: 0 auto;
}

.tech-env-layer {
  opacity: 0.25;
  transition: opacity 0.45s cubic-bezier(0.16, 1, 0.3, 1);
}

.tech-env-layer.is-active {
  opacity: 1;
}

.tech-envelope-diagram__tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  justify-content: center;
  margin-top: var(--space-sm);
}

.tech-env-tab {
  font-family: inherit;
  font-size: 0.6875rem;
  font-weight: 600;
  padding: 0.35rem 0.65rem;
  border-radius: 999px;
  border: 1px solid var(--color-border);
  background: var(--color-surface);
  color: var(--color-text-muted);
  cursor: pointer;
  transition: border-color 0.3s ease, background 0.3s ease, color 0.3s ease;
}

.tech-env-tab:hover {
  border-color: var(--color-teal-light);
}

.tech-env-tab[aria-selected="true"] {
  border-color: var(--color-accent);
  background: rgba(var(--rgb-gold), 0.12);
  color: var(--color-deep);
}

.tech-openings-svg {
  display: block;
  width: 100%;
  max-width: 280px;
  margin: 0 auto;
}

.tech-openings-stats {
  display: flex;
  justify-content: center;
  gap: var(--space-sm);
  margin-top: var(--space-sm);
  flex-wrap: wrap;
}

.tech-openings-stats div {
  text-align: center;
  padding: 0.4rem 0.65rem;
  background: var(--color-surface);
  border-radius: var(--radius);
  border: 1px solid var(--color-border);
  min-width: 4.5rem;
}

.tech-openings-stats strong {
  display: block;
  font-family: var(--font-display);
  font-size: 0.95rem;
  color: var(--color-accent);
}

.tech-openings-stats span {
  font-size: 0.625rem;
  color: var(--color-text-muted);
}

.tech-envelope-panel__body {
  padding: var(--space-lg);
  flex: 1;
  display: flex;
  flex-direction: column;
}

.tech-envelope-panel__body h3 {
  margin: 0 0 var(--space-sm);
  font-family: var(--font-display);
  font-size: 1.35rem;
}

.tech-envelope-detail h4 {
  margin: 0 0 0.35rem;
  font-size: 1rem;
  color: var(--color-teal);
}

.tech-envelope-detail p {
  margin: 0 0 var(--space-sm);
  font-size: 0.9375rem;
  color: var(--color-text-muted);
}

.tech-envelope-bullets {
  margin: 0;
  padding-left: 1.15rem;
  color: var(--color-text-muted);
  font-size: 0.9375rem;
}

.tech-envelope-bullets li {
  margin-bottom: 0.4rem;
}

.tech-envelope-panel .spec-chips {
  margin-top: auto;
}

@media (max-width: 900px) {
  .tech-envelope-grid {
    grid-template-columns: 1fr;
  }
}

/* Mechanical integration feature rows with SVG */
.tech-mech {
  background: linear-gradient(180deg, #fff 0%, var(--color-warm-bg) 100%);
}

.tech-mech-features {
  max-width: 52rem;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.tech-mech .feature-row--svg {
  grid-template-columns: 5.5rem 1fr;
  align-items: center;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow);
}

.tech-mech .feature-row--svg:hover {
  border-color: rgba(var(--rgb-gold), 0.35);
  background: var(--color-surface);
}

.tech-mech .feature-row__icon {
  width: 72px;
  height: 72px;
  border-radius: var(--radius-lg);
  background: linear-gradient(145deg, rgba(var(--rgb-gold), 0.18) 0%, rgba(var(--rgb-deep), 0.06) 100%);
  border: 1px solid rgba(var(--rgb-gold), 0.2);
  color: var(--color-teal);
  font-size: 0;
}

.tech-mech .feature-row__icon svg {
  width: 44px;
  height: 44px;
  display: block;
}

.tech-mech .feature-row__step {
  display: inline-block;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-accent);
  margin-bottom: 0.25rem;
}

.tech-mech .feature-row h3 {
  margin: 0 0 0.35rem;
}

.tech-mech .feature-row p {
  margin: 0;
  color: var(--color-text-muted);
}

@media (max-width: 560px) {
  .tech-mech .feature-row--svg {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .tech-mech .feature-row__icon {
    margin: 0 auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  .tech-stack__layer,
  .tech-detail {
    transition: none;
  }
}

