/*
 * 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;
}

/* Testimonial attribution: avatar + name + role (src/lib/QuoteAuthor.tsx). */
.rt-qa {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 0;
  font-family: var(--rt-font-body);
}

.rt-qa-avatar {
  flex: none;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
  box-shadow: 0 0 0 3px #fff, 0 4px 12px rgba(31, 54, 167, 0.18);
}

.rt-qa-initials {
  display: grid;
  place-items: center;
  font-family: var(--rt-font-heading);
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: #fff;
}

.rt-qa-tone-0 { background: linear-gradient(135deg, var(--rt-turquoise), var(--rt-route-sky)); }
.rt-qa-tone-1 { background: linear-gradient(135deg, var(--rt-route-pink), var(--rt-route-violet)); }
.rt-qa-tone-2 { background: linear-gradient(135deg, var(--rt-indigo-200), var(--rt-route-lilac)); }
.rt-qa-tone-3 { background: linear-gradient(135deg, var(--rt-yellow-200), var(--rt-route-pink)); }

.rt-qa-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.rt-qa-name {
  font-weight: 700;
  font-size: 17px;
  line-height: 22px;
  color: #2435a1;
}

.rt-qa-role {
  font-size: 15px;
  line-height: 20px;
  color: var(--rt-text-secondary);
}

/* On blue cards (Reviews) */
.rt-qa--light .rt-qa-avatar {
  width: 44px;
  height: 44px;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.85);
}
.rt-qa--light .rt-qa-initials { font-size: 15px; }
.rt-qa--light .rt-qa-name { font-size: 16px; line-height: 22px; color: #fff; }
.rt-qa--light .rt-qa-role { font-size: 14px; line-height: 19px; color: rgba(255, 255, 255, 0.75); }

@media (max-width: 767px) {
  .rt-qa-avatar { width: 48px; height: 48px; }
  .rt-qa-name { font-size: 17px; line-height: 23px; }
  .rt-qa-role { font-size: 14px; line-height: 19px; }
}

/* ---------------------------------------------------------------------------
 * Industry customer stories (not in Figma: homepage design language, flag for design review)
 * ------------------------------------------------------------------------- */
.rt-cs {
  padding: 128px 24px;
  background: #f4f5fe;
  font-family: var(--rt-font-body);
  color: var(--rt-text-primary);
  -webkit-font-smoothing: antialiased;
}

.rt-cs *,
.rt-cs *::before,
.rt-cs *::after {
  box-sizing: border-box;
}

.rt-cs-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 1180px;
  margin: 0 auto;
}

.rt-cs-header {
  max-width: 820px;
  margin-bottom: 56px;
  text-align: center;
}

.rt-cs-h2 {
  margin: 0;
  font-family: var(--rt-font-display);
  font-weight: 700;
  font-size: clamp(2rem, 1.2rem + 2vw, 3rem);
  line-height: 1.2;
  text-wrap: balance;
}

.rt-cs-sub {
  margin: 16px 0 0;
  font-family: var(--rt-font-heading);
  font-size: clamp(1.0625rem, 0.95rem + 0.3vw, 1.1875rem);
  line-height: 1.65;
  color: var(--rt-text-secondary);
  text-wrap: pretty;
}

.rt-cs-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 28px;
  width: 100%;
  margin: 0;
  padding: 0;
  list-style: none;
}

/* Three stories: one row of three */
.rt-cs-grid.is-three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.rt-cs-grid.is-three .rt-cs-body {
  padding: 24px 26px 28px;
}

.rt-cs-card {
  display: flex;
}

.rt-cs-link {
  display: flex;
  flex-direction: column;
  width: 100%;
  overflow: hidden;
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 1px 0 rgba(31, 54, 167, 0.06), 0 12px 32px rgba(31, 54, 167, 0.08);
  color: inherit;
  text-decoration: none;
  transition: transform 200ms ease, box-shadow 200ms ease;
}
a.rt-cs-link:hover {
  transform: translateY(-3px);
  box-shadow: 0 1px 0 rgba(31, 54, 167, 0.06), 0 20px 44px rgba(31, 54, 167, 0.16);
}
a.rt-cs-link:focus-visible {
  outline: 2px solid var(--rt-primary-500);
  outline-offset: 3px;
}

.rt-cs-photo {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #dfe3f6;
}
.rt-cs-photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 500ms cubic-bezier(0.22, 1, 0.36, 1);
}
a.rt-cs-link:hover .rt-cs-photo img {
  transform: scale(1.03);
}

.rt-cs-customer {
  position: absolute;
  left: 16px;
  bottom: 16px;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.94);
  font-family: var(--rt-font-heading);
  font-weight: 700;
  font-size: 14px;
  line-height: 18px;
  color: #2435a1;
  box-shadow: 0 4px 12px rgba(15, 26, 92, 0.15);
}

.rt-cs-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 28px 32px 32px;
}

/* Headline result (number + unit) with a line of context under it */
.rt-cs-metric {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin: 0 0 14px;
}
.rt-cs-metric strong {
  font-family: var(--rt-font-display);
  font-weight: 700;
  font-size: clamp(1.625rem, 1.3rem + 0.8vw, 2rem);
  line-height: 1.15;
  color: var(--rt-indigo-100);
  text-wrap: balance;
}
.rt-cs-metric span {
  font-family: var(--rt-font-heading);
  font-weight: 600;
  font-size: 15px;
  line-height: 1.4;
  color: var(--rt-text-secondary);
}

.rt-cs-title {
  margin: 0;
  font-family: var(--rt-font-display);
  font-weight: 700;
  font-size: 22px;
  line-height: 1.3;
}

.rt-cs-text {
  margin: 10px 0 0;
  font-size: 17px;
  line-height: 1.6;
  color: #3c4152;
  text-wrap: pretty;
}

.rt-cs-more {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: auto;
  padding-top: 20px;
  font-family: var(--rt-font-heading);
  font-weight: 700;
  font-size: 16px;
  color: var(--rt-indigo-100);
}
.rt-cs-more svg {
  width: 18px;
  height: 18px;
  transition: transform 160ms ease;
}
a.rt-cs-link:hover .rt-cs-more svg {
  transform: translateX(3px);
}

.rt-cs-quote {
  width: 100%;
  max-width: 760px;
  margin: 64px 0 0;
  padding: 36px 36px 32px;
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 16px 48px rgba(31, 54, 167, 0.12);
}
.rt-cs-quote blockquote {
  margin: 0;
  padding-left: 20px;
  border-left: 4px solid var(--rt-yellow-200);
  font-size: clamp(1.125rem, 1rem + 0.4vw, 1.375rem);
  line-height: 1.55;
}
.rt-cs-quote .rt-qa {
  margin-top: 22px;
  padding-left: 24px;
}

@media (max-width: 899px) {
  .rt-cs {
    padding: 96px 16px;
  }
  .rt-cs-grid,
  .rt-cs-grid.is-three {
    grid-template-columns: minmax(0, 1fr);
    gap: 20px;
  }
  .rt-cs-body {
    padding: 22px 22px 26px;
  }
  .rt-cs-text {
    font-size: 16px;
  }
  .rt-cs-quote {
    margin-top: 48px;
    padding: 28px 20px 24px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .rt-cs * {
    transition: none !important;
  }
}

