/* Hero refinement: retain V4 colours, type, content and original photograph. */
.rrom-hero-shell { padding-block-end: 76px !important; }
.rrom-hero-cover { min-height: 540px !important; }
.rrom-hero-cover > img.wp-image-318 { object-position: 52% center; }
.rrom-hero-photo::before,
.rrom-hero-photo::after { pointer-events: none; }

.rrom-hero-motion-control {
  position: absolute;
  inset-inline-end: 0;
  inset-block-end: -52px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 44px;
  padding: 4px 0 4px 8px;
  border: 0;
  background: transparent;
  color: var(--rrom-muted, #52616a);
  font: inherit;
  font-size: 12px;
  line-height: 1.4;
  cursor: pointer;
  text-underline-offset: 4px;
}
.rrom-hero-motion-control[hidden] { display: none; }
.rrom-hero-motion-control:is(:hover, :focus-visible) {
  color: var(--rrom-green, #0b691c);
  text-decoration: underline;
}
.rrom-hero-motion-control:focus-visible {
  outline: 3px solid var(--rrom-blue, #004aad);
  outline-offset: 3px;
}
.rrom-hero-motion-control svg { flex: 0 0 auto; }

@media (max-width: 950px) and (min-width: 782px) {
  .rrom-hero-cover { min-height: 480px !important; }
}
@media (max-width: 781px) {
  .rrom-hero-shell { padding-block-end: 78px !important; }
  .rrom-hero-cover {
    min-height: 0 !important;
    height: auto !important;
    aspect-ratio: 3 / 2 !important;
  }
  .rrom-hero-cover > .wp-block-cover__inner-container { min-height: 0 !important; }
  .rrom-hero-photo { padding-block-end: 18px; }
  .rrom-note-position { bottom: -18px; left: -7px; }
  .rrom-photo-note { max-width: 190px; padding: 12px 16px !important; }
  .rrom-photo-note h3 { font-size: 20px !important; line-height: 1.16 !important; }
  .rrom-note-arrow { margin-block-start: 5px; }
  .rrom-hero-photo::before { bottom: -4px; }
}
@media (max-width: 760px) {
  .rrom-hero-intro { font-size: 14px !important; line-height: 1.8; }
  .rrom-actions .rrom-button a {
    min-height: 50px;
    padding: 13px 18px !important;
    font-size: 14px !important;
    line-height: 1.5;
  }
}
@media (max-width: 480px) {
  .rrom-actions { flex-direction: column; align-items: stretch !important; gap: 10px !important; }
  .rrom-actions > .wp-block-button { width: 100%; }
  .rrom-actions .rrom-button a { box-sizing: border-box; width: 100%; }
  .rrom-photo-note { max-width: 180px; padding: 11px 14px !important; }
  .rrom-hero-motion-control { font-size: 12px; }
}

/* Text and cover enter once. The two background shapes have independent,
   slow paths; pausing preserves their exact current position. */
@media (prefers-reduced-motion: no-preference) {
  .rrom-hero-content[data-rrom-hero-enter="entering"] {
    animation: rrom-hero-text-enter 420ms cubic-bezier(.2,.65,.3,1) both;
  }
  .rrom-hero-cover[data-rrom-hero-enter="entering"] {
    animation: rrom-hero-photo-enter 520ms cubic-bezier(.2,.65,.3,1) both;
  }
  .rrom-hero-shell[data-rrom-floating-ready] .rrom-hero-photo::before {
    animation: rrom-float-green 7.4s ease-in-out infinite;
    animation-play-state: paused;
  }
  .rrom-hero-shell[data-rrom-floating-ready] .rrom-hero-photo::after {
    animation: rrom-float-blue 6.8s ease-in-out infinite;
    animation-play-state: paused;
  }
  .rrom-hero-shell[data-rrom-float-state="running"] .rrom-hero-photo::before,
  .rrom-hero-shell[data-rrom-float-state="running"] .rrom-hero-photo::after {
    animation-play-state: running;
  }
}
@keyframes rrom-hero-text-enter {
  from { opacity: .92; transform: translateY(6px); }
  to { opacity: 1; transform: none; }
}
@keyframes rrom-hero-photo-enter {
  from { opacity: .88; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}
@keyframes rrom-float-green {
  0%, 100% { transform: translate3d(0, 0, 0); }
  50% { transform: translate3d(2px, -5px, 0); }
}
@keyframes rrom-float-blue {
  0%, 100% { transform: translate3d(0, 0, 0); }
  50% { transform: translate3d(-3px, 4px, 0); }
}
.rrom-hero-content:focus-within { animation: none !important; }
@media (prefers-reduced-motion: reduce), print {
  [data-rrom-hero-enter],
  .rrom-hero-photo::before,
  .rrom-hero-photo::after { animation: none !important; transform: none !important; }
  .rrom-hero-motion-control { display: none; }
}
