/* Roof Repair: its parts placed and sized with the tokens of system.css (the shared parts are in components.css). */

/* ---------- 1. the header: the stain (mirrored), a ring round its wettest spot, a trace up to the roof ---------- */
.svc-hero__pic img.flip { transform: scaleX(-1); }
.svc-hero .trace { position: absolute; inset: 0; width: 100%; height: 100%; max-width: none; z-index: 1; pointer-events: none; overflow: visible; }
.trace__ring { fill: none; stroke: var(--c-accent); stroke-width: 5; stroke-linecap: round; stroke-dasharray: 1; stroke-dashoffset: 1; filter: drop-shadow(0 0 2px rgba(0, 0, 0, 0.5)); animation: trace-ring 8s var(--ease-out) 1.2s infinite; }
.trace__line { fill: none; stroke: var(--c-accent); stroke-width: 5; stroke-linecap: round; stroke-dasharray: 1; stroke-dashoffset: 1; filter: drop-shadow(0 0 2px rgba(0, 0, 0, 0.5)); animation: trace-up 8s var(--ease-in-out) 1.2s infinite; }
.trace__head { fill: none; stroke: var(--c-accent); stroke-width: 6; stroke-linecap: round; stroke-linejoin: round; opacity: 0; animation: trace-head 8s var(--ease-out) 1.2s infinite; }
@keyframes trace-ring { 0% { stroke-dashoffset: 1; opacity: 1; } 14% { stroke-dashoffset: 0; } 82% { stroke-dashoffset: 0; opacity: 1; } 92%, 100% { stroke-dashoffset: 0; opacity: 0; } }
@keyframes trace-up { 0%, 14% { stroke-dashoffset: 1; opacity: 1; } 36% { stroke-dashoffset: 0; } 82% { stroke-dashoffset: 0; opacity: 1; } 92%, 100% { stroke-dashoffset: 0; opacity: 0; } }
@keyframes trace-head { 0%, 34% { opacity: 0; transform: translateY(8px); } 40% { opacity: 1; transform: none; } 82% { opacity: 1; } 92%, 100% { opacity: 0; } }
.svc-hero[data-held] .trace * { animation-play-state: paused; }

@media (prefers-reduced-motion: reduce) {
  .trace__ring, .trace__line, .trace__head { animation: none; }
  .trace__ring, .trace__line { stroke-dashoffset: 0; }
  .trace__head { opacity: 1; }
}
