/* Build Path — resident layout density & readable width (visual pass) */

.page--resident {
  max-width: 1060px;
}

@media (min-width: 821px) {
  .page--resident .layout {
    grid-template-columns: minmax(0, 1fr) 248px;
    gap: 22px;
  }

  .page--resident .layout.layout--focus {
    grid-template-columns: minmax(0, 1fr);
    gap: 0;
  }

  .page--resident .layout.layout--focus > .side-card--reference {
    order: -1;
    position: static;
    margin: 0 0 16px;
    padding: 12px 16px;
    border-radius: 14px;
    box-shadow: none;
  }

  .page--resident .layout.layout--focus > .side-card--reference .side-panel-more summary {
    padding: 0;
    font-size: 0.92rem;
  }

  .page--resident .layout.layout--focus > section,
  .page--resident .layout.layout--focus > .card {
    max-width: none;
  }
}

.page--resident .hero {
  padding: 34px 32px 30px;
}

.page--resident .hero p {
  max-width: 52rem;
  line-height: 1.58;
}

.page--resident .layout > section .card,
.page--resident .layout > section > .card {
  max-width: none;
}

.page--resident .card {
  padding: 22px 24px;
}

.page--resident .side-card--reference {
  padding: 14px 16px;
}

/* Back to top — long workflow pages */
.back-to-top {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 40;
  width: 42px;
  height: 42px;
  border-radius: 999px;
  border: 1px solid #BBF7D0;
  background: #FFFFFF;
  color: #065F46;
  font-size: 1.1rem;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 4px 16px rgba(17, 24, 39, 0.12);
  transition: opacity 0.15s ease, transform 0.15s ease;
}

.back-to-top:hover {
  transform: translateY(-2px);
}

.back-to-top[hidden] {
  display: none;
}

/* Smaller module tiles on Project File summary */
.support-grid.pf-module-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.support-grid.pf-module-grid .support-card {
  padding: 10px 12px;
  border-radius: 12px;
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.support-grid.pf-module-grid .support-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  font-size: 0.65rem;
}

.support-grid.pf-module-grid .support-card strong {
  font-size: 0.88rem;
}

.support-grid.pf-module-grid .support-card p {
  font-size: 0.82rem;
  margin-top: 4px;
  line-height: 1.4;
}

/* Resident route visuals — more weight on Residents page */
.journey-paths {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin: 16px 0;
}

.journey-path {
  padding: 16px 18px;
  background: var(--soft-green, #ECFDF5);
  border: 1px solid #BBF7D0;
  border-radius: 16px;
}

.journey-path strong {
  display: block;
  font-size: 1rem;
  color: #065F46;
  margin-bottom: 6px;
}

.journey-path .path-chain {
  font-weight: 700;
  color: #064E3B;
  font-size: 0.95rem;
}

@media (max-width: 720px) {
  .journey-paths {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 820px) {
  .page--resident .layout.layout--focus > .side-card--reference {
    margin-bottom: 14px;
  }
}
