/* ============================================================
   remodel.guide — Guide Page Enhancements
   TOC active states, back-to-top, sticky CTA, timeline active
   ============================================================ */

/* ── TOC ACTIVE SECTION ── */
.toc-list li a.toc-active {
  color: var(--brass);
}
.toc-list li a.toc-active::before {
  background: var(--brass);
  opacity: 1;
}

/* ── BACK TO TOP BUTTON ── */
#back-to-top {
  position: fixed;
  bottom: 80px;
  right: 24px;
  width: 40px;
  height: 40px;
  background: var(--deep, #2C2420);
  color: #B5904A;
  border: 1px solid rgba(181, 144, 74, 0.3);
  border-radius: 50%;
  cursor: pointer;
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.25s ease, transform 0.25s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 500;
  pointer-events: none;
}
#back-to-top.visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
#back-to-top:hover {
  background: #1a0f0c;
  border-color: rgba(181, 144, 74, 0.6);
}

/* ── STICKY BOTTOM CTA ── */
#sticky-cta {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--deep, #2C2420);
  border-top: 1px solid rgba(181, 144, 74, 0.2);
  padding: 10px 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  z-index: 400;
  transform: translateY(100%);
  transition: transform 0.3s ease;
}
#sticky-cta.visible {
  transform: translateY(0);
}
#sticky-cta .sticky-label {
  color: rgba(255, 255, 255, 0.55);
  font-size: 13px;
  font-family: 'DM Sans', sans-serif;
  white-space: nowrap;
}
#sticky-cta .sticky-phone {
  color: rgba(255, 255, 255, 0.4);
  font-size: 13px;
  font-family: 'DM Sans', sans-serif;
  text-decoration: none;
  white-space: nowrap;
}
#sticky-cta .sticky-phone:hover {
  color: rgba(255, 255, 255, 0.7);
}
#sticky-cta .btn-primary {
  padding: 8px 20px;
  font-size: 13px;
  white-space: nowrap;
}

/* ── TIMELINE ACTIVE STATE ── */
@keyframes timeline-period-pulse {
  0%   { opacity: 0.6; letter-spacing: 0.04em; }
  50%  { opacity: 1;   letter-spacing: 0.09em; }
  100% { opacity: 1;   letter-spacing: 0.06em; }
}
.timeline-item.timeline-active .timeline-period {
  animation: timeline-period-pulse 0.5s ease-out forwards;
}

/* ── MOBILE ── */
@media (max-width: 640px) {
  #sticky-cta {
    padding: 10px 16px;
    gap: 12px;
  }
  #sticky-cta .sticky-label,
  #sticky-cta .sticky-phone {
    display: none;
  }
  #back-to-top {
    right: 16px;
    bottom: 72px;
  }
}
