.reference-radar-section {
    position: relative;
    overflow: hidden;
    /* Extra bottom padding gives the first featured-case section room to
       breathe instead of following right on the radar's heels. */
    padding-block: clamp(64px, 9vw, 120px) clamp(96px, 13vw, 168px);
    color: var(--pm-color-paper);
    background:
        linear-gradient(rgba(10, 12, 15, 0.82), rgba(10, 12, 15, 0.94)),
        var(--pm-wallpaper-image) center / cover;
}

/*
 * A faint echo of the footer's wave graphic along the bottom edge, so the
 * motif bookends the page (hero at top, footer at bottom) instead of only
 * ever appearing twice back-to-back at the very end of the page (which is
 * what the CTA band's own wave variant used to do, right above the real
 * footer - dropped there in favour of this single top-of-page nod).
 */
.reference-radar-section::after {
    content: "";
    position: absolute;
    inset: auto 0 0 0;
    height: clamp(140px, 20vw, 280px);
    background: url("../../../Images/Footer/footer-bg-2560w.jpg") right bottom / cover no-repeat;
    opacity: 0.32;
    -webkit-mask-image: linear-gradient(to bottom, transparent, black 75%);
    mask-image: linear-gradient(to bottom, transparent, black 75%);
    pointer-events: none;
    z-index: 0;
}

@supports (background-image: image-set(url("data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBTAA7") type("image/gif") 1x)) {
    .reference-radar-section::after {
        background: image-set(
            url("../../../Images/Footer/footer-bg-1280w.webp") type("image/webp") 1x,
            url("../../../Images/Footer/footer-bg-2560w.webp") type("image/webp") 2x
        ) right bottom / cover no-repeat;
    }
}

.reference-radar {
    position: relative;
    z-index: 1;
    width: min(100% - 40px, var(--pm-container-wide));
    margin-inline: auto;
    padding-inline: clamp(22px, 4.4vw, 64px);
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(320px, 0.72fr);
    gap: clamp(32px, 6vw, 72px);
    align-items: center;
}

.reference-radar-copy .kicker {
    margin: 0 0 14px;
    color: var(--pm-color-orange);
    font-size: 13px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.reference-radar-copy h1 {
    margin: 0 0 20px;
    font-size: clamp(38px, 5.4vw, 68px);
    font-weight: 900;
    line-height: 1.05;
}

.reference-radar-copy h1 .headline-outline {
    display: block;
    color: transparent;
    -webkit-text-stroke: 1.2px rgba(255, 253, 248, 0.4);
}

.reference-radar-lead {
    margin: 0 0 28px;
    max-width: 540px;
    color: rgba(255, 253, 248, 0.78);
    font-size: 18px;
    line-height: 1.6;
}

.reference-radar-copy .button-row {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.reference-radar-copy .btn-outline-light {
    color: var(--pm-color-paper);
    border-color: rgba(255, 253, 248, 0.4);
}

.reference-radar-copy .btn-outline-light:hover,
.reference-radar-copy .btn-outline-light:focus-visible {
    color: var(--pm-color-ink);
    background: var(--pm-color-paper);
}

/* ---------------------------------------------------------------------- */
/* Case Radar                                                              */
/* ---------------------------------------------------------------------- */

.radar {
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 1;
    max-width: 560px;
    margin-inline: auto;
}

.radar-ring {
    position: absolute;
    left: 50%;
    top: 50%;
    border: 1px solid rgba(245, 158, 1, 0.22);
    border-radius: 50%;
    transform: translate(-50%, -50%);
}

.radar-ring-1 {
    width: 100%;
    height: 100%;
}

.radar-ring-2 {
    width: 74%;
    height: 74%;
    border-color: rgba(255, 253, 248, 0.14);
}

.radar-ring-3 {
    width: 46%;
    height: 46%;
    border-color: rgba(245, 158, 1, 0.16);
}

.radar-line {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 50%;
    height: 1px;
    background: linear-gradient(90deg, rgba(245, 158, 1, 0.5), transparent);
    transform-origin: left center;
}

.radar-line-1 {
    transform: rotate(18deg);
}

.radar-line-2 {
    transform: rotate(146deg);
}

.radar-line-3 {
    transform: rotate(255deg);
}

.radar-core {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 108px;
    height: 108px;
    display: flex;
    align-items: center;
    justify-content: center;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    background: radial-gradient(circle at 35% 30%, #1c242f, var(--pm-color-ink) 70%);
    box-shadow: 0 0 0 1px rgba(245, 158, 1, 0.35), 0 0 46px rgba(245, 158, 1, 0.28);
    color: var(--pm-color-paper);
    font-size: 26px;
    font-weight: 900;
    letter-spacing: 0.04em;
}

/* Node motion itself lives entirely in reference-radar.js (Mission
   Control's own left/top-percentage orbit technique, no scroll-tie).
   Overlap between nodes is accepted by design here - there is no
   scroll-linked narrative to protect like Mission Control's. */
.radar-nodes {
    position: absolute;
    inset: 0;
}

.radar-node {
    position: absolute;
    transform: translate(-50%, -50%);
    pointer-events: auto;
    display: grid;
    gap: 2px;
    min-width: 148px;
    padding: 10px 14px;
    border-radius: var(--pm-radius);
    border: 1px solid var(--pm-color-line-dark);
    background: rgba(17, 24, 32, 0.88);
    backdrop-filter: blur(6px);
    transition: transform 0.2s linear;
}

/*
 * Static resting position per node (left/top in %, matching each node's
 * own t=0 angle in reference-radar.js's presets array) - this is both the
 * no-JS/reduced-motion/mobile fallback AND the position JS starts from, so
 * there is no jump when the ticker in reference-radar.js takes over. Real
 * motion (elliptical, per-node speed) only ever comes from that JS - see
 * the "why offset-path failed" note in the project plan history: CSS shape
 * percentages resolve against the animated element's own box, not this
 * container, which is why a pure-CSS attempt at this looked broken.
 */
.radar-node:nth-of-type(1) { left: 92%; top: 50%; }
.radar-node:nth-of-type(2) { left: 65%; top: 83%; }
.radar-node:nth-of-type(3) { left: 27%; top: 66%; }
.radar-node:nth-of-type(4) { left: 24%; top: 50%; }
.radar-node:nth-of-type(5) { left: 30%; top: 28%; }
.radar-node:nth-of-type(6) { left: 67%; top: 24%; }

.radar-node strong {
    color: var(--pm-color-orange);
    font-size: 13px;
    font-weight: 900;
}

.radar-node span {
    color: rgba(255, 253, 248, 0.72);
    font-size: 12px;
    line-height: 1.3;
}

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

    .radar {
        margin-top: 24px;
    }
}

@media (max-width: 620px) {
    .radar {
        max-width: 380px;
    }

    .radar-node:nth-of-type(5),
    .radar-node:nth-of-type(6) {
        display: none;
    }

    .radar-node {
        min-width: 120px;
        padding: 8px 10px;
    }
}
