/*
 * Design tokens from the Routific Website Figma file (variables on node 7166:92349).
 * Code components render inside Shadow DOM, so tokens are declared on :host as well as :root
 * (:root covers the local preview and Webflow's own page; :host covers the shadow tree).
 */
:host,
:host {
  /* Brand */
  --rt-indigo-100: #374cd2;
  --rt-indigo-200: #667afa;
  --rt-yellow-200: #ffad0a;
  --rt-yellow-border: #b97b01;
  --rt-turquoise: #45c4d7;
  --rt-primary-500: #326bfc;
  --rt-primary-600: #1750e3;
  --rt-hero-blue: #1f36a7;
  --rt-hero-lilac: #eceefb;

  /* Text */
  --rt-text-primary: #282828;
  --rt-text-secondary: #676d7e;
  --rt-text-tertiary: #9da1af;

  /* Route colours */
  --rt-route-violet: #7547bf;
  --rt-route-pink: #ff85a9;
  --rt-route-sky: #269ed1;
  --rt-route-lilac: #a770db;

  /* Type — Proxima Nova is expected to be loaded by the Webflow site (Adobe Fonts);
     Plus Jakarta Sans and Figtree are loaded from Google Fonts by useDocumentFonts(). */
  --rt-font-display: "Plus Jakarta Sans", system-ui, sans-serif;
  --rt-font-heading: "Figtree", system-ui, sans-serif;
  --rt-font-body: "proxima-nova", "Proxima Nova", "Figtree", system-ui, sans-serif;
  --rt-font-ui: "SF Pro Text", -apple-system, "Inter", system-ui, sans-serif;

  /* Radii */
  --rt-radius-md: 8px;
  --rt-radius-lg: 16px;

  /* Vector map (Hero/showcase/MapBase.tsx): Mapbox-light look of the current Routific UI */
  --map-land: #edeff3;
  --map-street: #fcfdfe;
  --map-park: #d3e9d1;
  --map-water: #b3caf3;
  --map-industrial: #f2e4c6;
  --map-highway: #aab3c7;
  --map-highway-edge: #fcfdfe;
}

/*
 * MIT benchmark card (src/lib/MitCard.tsx): blue card, MIT logo + "Read more" link, amber rule, text.
 * On the homepage (Spaghetti Routes) and on its own as the Benchmark Callout component.
 */
.rt-sp-mit {
  display: flex;
  align-items: center;
  width: 100%;
  max-width: 1098px;
  min-height: 220px;
  padding: 25px 24px;
  border-radius: 20px;
  background: var(--rt-indigo-100);
  font-family: var(--rt-font-heading);
  color: #fff;
}

.rt-sp-mit-brand {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 28px;
  flex: none;
  width: 351px;
}

.rt-sp-mit-logo {
  display: block;
  width: 338px;
  max-width: 100%;
  height: auto;
}

.rt-sp-mit-rule {
  flex: none;
  align-self: stretch;
  width: 2px;
  margin: 0 43px 0 0;
  background: #ffa900;
}

.rt-sp-mit-text {
  margin: 0;
  max-width: 574px;
  font-size: clamp(1.125rem, 0.95rem + 0.45vw, 1.5rem);
  line-height: 1.4583;
}

@media (max-width: 991px) {
  .rt-sp-mit {
    flex-direction: column;
    align-items: flex-start;
    gap: 24px;
    padding: 32px 24px;
  }
  .rt-sp-mit-brand {
    width: auto;
    gap: 20px;
  }
  .rt-sp-mit-logo {
    width: 260px;
  }
  .rt-sp-mit-rule {
    align-self: stretch;
    width: auto;
    height: 2px;
    margin: 0;
  }
}

.rt-sp-mit-link {
  margin-left: 14px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-weight: 700;
  font-size: 18px;
  line-height: 24px;
  color: #fff;
  text-decoration: none;
}

.rt-sp-mit-link img {
  display: block;
  overflow: visible;
  transition: transform 200ms ease;
}

.rt-sp-mit-link:hover img {
  transform: translateX(3px);
}

.rt-sp-mit-link:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 4px;
  border-radius: 4px;
}

/* The MIT card on its own: fills its Webflow container, centred, up to the card's 1098px, clear of what's above. */
.rt-bc {
  position: relative;
  isolation: isolate;
  display: flex;
  justify-content: center;
  padding-top: 96px;
  -webkit-font-smoothing: antialiased;
}
.rt-bc *,
.rt-bc *::before,
.rt-bc *::after {
  box-sizing: border-box;
}

/* Between sections: the next section's colour fills behind the card's lower half, edge to edge,
 * so the card hovers over the seam between the two sections. The band is a box-shadow spread
 * (no horizontal scroll), clipped to its own height. */
.rt-bc--between::before {
  content: "";
  position: absolute;
  z-index: -1;
  left: 0;
  right: 0;
  bottom: 0;
  height: calc((100% - var(--rt-bc-pad, 96px)) / 2);
  background: var(--rt-bc-below, #fff);
  box-shadow: 0 0 0 100vmax var(--rt-bc-below, #fff);
  clip-path: inset(0 -100vmax);
}
.rt-bc--between .rt-sp-mit {
  position: relative;
  box-shadow:
    0 30px 60px -24px rgba(31, 54, 167, 0.45),
    0 10px 24px -8px rgba(31, 54, 167, 0.18);
}

@media (max-width: 767px) {
  .rt-bc {
    --rt-bc-pad: 64px;
    padding-top: 64px;
  }
}

