<style>

/* ============================================================
   CIRCUITRY.AI — INTERACTIVE SERVICE DECISION MAP
   ============================================================ */


/* ============================================================
   MAP CONTAINER
   ============================================================ */

.circuitry-decision-map {
  width: 100%;
  max-width: 1536px;
  margin: 0 auto;
}


/*
  The image and hotspot overlay share this container.
  This makes all hotspot percentages relative to the image.
*/

.circuitry-map-stage {
  position: relative;
  width: 100%;
  overflow: visible;
}


/* ============================================================
   BACKGROUND IMAGE
   ============================================================ */

.circuitry-map-image {
  display: block;
  width: 100%;
  height: auto;
  margin: 0;
}


/* ============================================================
   HOTSPOT OVERLAY
   ============================================================ */

.circuitry-hotspot-layer {
  position: absolute;

  inset: 0;

  width: 100%;
  height: 100%;

  z-index: 10;

  /*
    Layer itself ignores mouse events.
    Individual hotspots turn them back on.
  */
  pointer-events: none;

  overflow: visible;
}


/* ============================================================
   INDIVIDUAL HOTSPOT
   ============================================================ */

.circuitry-hotspot {
  --hotspot-color: #22aaff;

  position: absolute;
  display: block;

  box-sizing: border-box;

  pointer-events: auto;

  border: 2px solid transparent;
  border-radius: 12px;

  cursor: pointer;
  text-decoration: none;

  overflow: visible;

  transition:
    border-color 180ms ease,
    background-color 180ms ease,
    box-shadow 180ms ease;
}


/* ============================================================
   HOTSPOT ACCENT COLORS
   ============================================================ */

.circuitry-hotspot--blue {
  --hotspot-color: #22aaff;
}

.circuitry-hotspot--teal {
  --hotspot-color: #18d8da;
}

.circuitry-hotspot--green {
  --hotspot-color: #76e83e;
}

.circuitry-hotspot--purple {
  --hotspot-color: #a85cff;
}

.circuitry-hotspot--orange {
  --hotspot-color: #ffa51f;
}


/* ============================================================
   HOTSPOT HOVER EFFECT
   ============================================================ */

@media (hover: hover) and (pointer: fine) {

  .circuitry-hotspot:hover {

    border-color: var(--hotspot-color);

    background: rgba(255, 255, 255, 0.04);

    box-shadow:
      0 0 8px var(--hotspot-color),
      0 0 20px rgba(34, 170, 255, 0.25);
  }

}


/* ============================================================
   KEYBOARD ACCESSIBILITY
   ============================================================ */

.circuitry-hotspot:focus-visible {

  border-color: var(--hotspot-color);

  outline: 3px solid #ffffff;
  outline-offset: 3px;

}


/* ============================================================
   TOOLTIP — BASE STYLE

   IMPORTANT:
   Do NOT define left/right/top/bottom here.

   Tooltip position is controlled separately by
   .tooltip--right and .tooltip--left.
   ============================================================ */

.circuitry-tooltip {

  position: absolute;

  width: clamp(180px, 18vw, 260px);

  padding: clamp(9px, 1vw, 14px);

  box-sizing: border-box;

  background: rgba(4, 18, 34, 0.97);

  border:
    1px solid
    var(--hotspot-color);

  border-radius: 9px;

  color: #ffffff;

  opacity: 0;
  visibility: hidden;

  pointer-events: none;

  box-shadow:
    0 6px 20px
    rgba(0, 0, 0, 0.35);

  transition:
    opacity 160ms ease,
    visibility 160ms ease,
    transform 160ms ease;

  z-index: 50;
}


/* ============================================================
   TOOLTIP TITLE
   ============================================================ */

.circuitry-tooltip__title {

  display: block;

  margin: 0 0 5px 0;

  color: #ffffff;

  font-size:
    clamp(12px, 1.05vw, 16px);

  font-weight: 700;

  line-height: 1.15;
}


/* ============================================================
   TOOLTIP DESCRIPTION
   ============================================================ */

.circuitry-tooltip__description {

  display: block;

  margin: 0;

  color: #d7e1ec;

  font-size:
    clamp(11px, 0.9vw, 14px);

  font-weight: 400;

  line-height: 1.35;
}


/* ============================================================
   TOOLTIP CTA
   ============================================================ */

.circuitry-tooltip__cta {

  display: block;

  margin-top: 7px;

  color: var(--hotspot-color);

  font-size:
    clamp(10px, 0.8vw, 12px);

  font-weight: 700;

  line-height: 1.2;

  text-transform: uppercase;

  letter-spacing: 0.03em;
}


/* ============================================================
   TOOLTIP POSITION — RIGHT

   Used for LEFT-SIDE infographic blocks.

   Hotspot:
   [ BLOCK ]  →  [ TOOLTIP ]
   ============================================================ */

.circuitry-hotspot.tooltip--right
.circuitry-tooltip {

  left: calc(100% + 10px);

  right: auto;

  top: 50%;

  bottom: auto;

  transform:
    translateY(-50%)
    translateX(6px);
}


/* ============================================================
   TOOLTIP POSITION — LEFT

   Used for RIGHT-SIDE infographic blocks.

   [ TOOLTIP ]  ←  [ BLOCK ]
   ============================================================ */

.circuitry-hotspot.tooltip--left
.circuitry-tooltip {

  right: calc(100% + 10px);

  left: auto;

  top: 50%;

  bottom: auto;

  transform:
    translateY(-50%)
    translateX(-6px);
}


/* ============================================================
   SHOW TOOLTIP ON HOVER

   Visibility does NOT depend on left/right position.
   Any hotspot containing a tooltip will display it.
   ============================================================ */

@media (hover: hover) and (pointer: fine) {

  .circuitry-hotspot:hover
  .circuitry-tooltip {

    opacity: 1;

    visibility: visible;
  }


  /*
    Remove small horizontal offset
    when tooltip becomes visible.
  */

  .circuitry-hotspot.tooltip--right:hover
  .circuitry-tooltip {

    transform:
      translateY(-50%)
      translateX(0);
  }


  .circuitry-hotspot.tooltip--left:hover
  .circuitry-tooltip {

    transform:
      translateY(-50%)
      translateX(0);
  }

}


/* ============================================================
   KEYBOARD — SHOW TOOLTIP
   ============================================================ */

.circuitry-hotspot:focus-visible
.circuitry-tooltip {

  opacity: 1;

  visibility: visible;
}


.circuitry-hotspot.tooltip--right:focus-visible
.circuitry-tooltip {

  transform:
    translateY(-50%)
    translateX(0);
}


.circuitry-hotspot.tooltip--left:focus-visible
.circuitry-tooltip {

  transform:
    translateY(-50%)
    translateX(0);
}


/* ============================================================
   SMALL DESKTOP / TABLET

   Reduce tooltip size when infographic is displayed smaller.
   ============================================================ */

@media (max-width: 1100px) {

  .circuitry-tooltip {

    width: clamp(170px, 20vw, 220px);

    padding: 10px 12px;
  }


  .circuitry-tooltip__title {

    font-size: 13px;
  }


  .circuitry-tooltip__description {

    font-size: 11px;

    line-height: 1.3;
  }


  .circuitry-tooltip__cta {

    font-size: 10px;

    margin-top: 5px;
  }


  /*
    Reduce distance between block and tooltip
    on smaller screens.
  */

  .circuitry-hotspot.tooltip--right
  .circuitry-tooltip {

    left: calc(100% + 6px);
  }


  .circuitry-hotspot.tooltip--left
  .circuitry-tooltip {

    right: calc(100% + 6px);
  }

}


/* ============================================================
   MOBILE

   No hover tooltip on touch/mobile.
   Hotspot remains directly clickable.
   ============================================================ */

@media (max-width: 767px) {

  .circuitry-tooltip {

    display: none;
  }


  .circuitry-hotspot {

    border-radius: 6px;
  }

}

</style>