/* Highland Insurance Group — Customer Stories (/stories/ + /es/historias/), built by tools/build_media_blog.py
   (body: tools/stories_page.py). Modeled on the Sakha "Customer Stories" reference, in Highland's brand.
   Loaded after site.css. Colors = site.css variables only (tints via rgba of navy #0A1F44 / gold #C5A059).
   Contrast: gold on cream is 2.3:1, so gold text only sits on navy; on cream the accent line is --gold-dark
   (3.2:1) and only at display sizes (≥ 24px bold). */

.st { overflow-x: clip; }
.st .wrap { max-width: min(var(--wrap), 1640px); }

/* ---------- shared bits ---------- */
.st-eyebrow {
  display: flex; align-items: center; gap: 12px;
  font-family: var(--font-head); font-weight: 700; font-size: clamp(12px, .85vw, 15px); letter-spacing: .16em; text-transform: uppercase;
  color: var(--navy);
}
.st-eyebrow::before { content: ""; flex: none; width: 28px; height: 2px; background: var(--gold); }
.st-textlink {
  display: inline-flex; align-items: center; gap: 9px;
  font-family: var(--font-head); font-weight: 700; font-size: clamp(15px, 1.05vw, 19px); color: var(--navy);
  text-decoration: none; padding: 5px 0; border-bottom: 2px solid rgba(197, 160, 89, .6);
  transition: border-color .2s, gap .2s;
}
.st-textlink:hover { border-color: var(--gold); gap: 13px; }
.st-textlink svg { flex: none; }
.st-textlink-gold { border-color: var(--gold); }
.st-ticks { list-style: none; margin: 18px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 20px; font-size: clamp(14px, .95vw, 17px); color: var(--slate); }
.st-ticks li { display: inline-flex; align-items: center; gap: 6px; }
.st-ticks svg { color: var(--gold-dark); }
.st-stretch::after { content: ""; position: absolute; inset: 0; border-radius: inherit; z-index: 1; }
.st a:focus-visible { outline: 3px solid var(--gold); outline-offset: 4px; }
.st-stretch:focus-visible { outline: none; }
.st-stretch:focus-visible::after { outline: 3px solid var(--gold); outline-offset: 4px; }

/* ---------- 1. hero ---------- */
.st-hero { padding: clamp(36px, 4.4vw, 96px) 0 clamp(52px, 5.6vw, 110px); }
.st-hero-grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: clamp(36px, 5vw, 110px); align-items: center; }
.st-hero-grid > * { min-width: 0; }
.st-crumbs { font-family: var(--font-head); font-size: 13px; font-weight: 600; color: var(--slate); margin-bottom: clamp(18px, 1.6vw, 30px); }
.st-crumbs a { color: var(--slate); text-decoration: none; }
.st-crumbs a:hover { color: var(--navy); text-decoration: underline; }
.st-crumbs [aria-current] { color: var(--navy); }
.st-hero h1 {
  font-size: clamp(44px, 5.4vw, 92px); line-height: .98; letter-spacing: -.035em;
  margin: clamp(18px, 1.8vw, 32px) 0 clamp(20px, 1.9vw, 34px); overflow-wrap: break-word;
}
.st-hero h1 span { display: block; color: var(--gold-dark); }
.st-lead { font-size: var(--fs-lead); line-height: 1.5; color: var(--slate); max-width: 34em; }
.st-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 28px; margin-top: clamp(26px, 2.4vw, 44px); }
.st-proof { display: flex; align-items: center; gap: 14px; margin-top: clamp(24px, 2.4vw, 42px); }
.st-proof img { flex: none; width: 52px; height: 52px; border-radius: 50%; object-fit: cover; border: 2px solid var(--white); box-shadow: 0 0 0 2px var(--gold); }
.st-proof p { font-size: clamp(14px, .95vw, 17px); color: var(--slate); line-height: 1.4; }
.st-proof strong { display: block; color: var(--navy); font-family: var(--font-head); font-size: clamp(15px, 1vw, 18px); }
.st-proof a { display: inline-flex; align-items: center; gap: 6px; color: var(--slate); text-underline-offset: 3px; }
.st-proof a:hover { color: var(--navy); }

/* featured review card, dotted sand blob behind, gold sticker, handwritten-feel note (Tinos italic) */
.st-visual { position: relative; padding: 18px 0 54px; }
.st-visual::before {
  content: ""; position: absolute; inset: -26px -26px 14px -34px; z-index: 0;
  background-color: var(--sand);
  background-image: radial-gradient(rgba(197, 160, 89, .55) 1.2px, transparent 1.3px); background-size: 17px 17px;
  border-radius: 46% 42% 38% 34%; transform: rotate(-4deg);
}
.st-feature {
  position: relative; z-index: 1; isolation: isolate;
  background: var(--navy); color: var(--cream); border-radius: 30px;
  padding: clamp(28px, 3vw, 58px) clamp(26px, 3vw, 58px) clamp(24px, 2.4vw, 44px);
  min-height: clamp(420px, 36vw, 640px); display: flex; flex-direction: column;
  box-shadow: 0 30px 60px -28px rgba(10, 31, 68, .6);
  transition: transform .35s, box-shadow .35s;
}
.st-feature::before {
  content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; pointer-events: none;
  background: radial-gradient(120% 80% at 100% 0%, rgba(197, 160, 89, .22), transparent 55%), radial-gradient(90% 70% at 0% 100%, rgba(27, 58, 104, .9), transparent 70%);
}
.st-feature:hover { transform: translateY(-4px); box-shadow: 0 40px 70px -30px rgba(10, 31, 68, .7); }
.st-f-tag {
  align-self: flex-start; font-family: var(--font-head); font-weight: 700; font-size: 12px; letter-spacing: .12em; text-transform: uppercase;
  border: 1px solid rgba(249, 248, 246, .35); border-radius: 999px; padding: 6px 12px 5px; color: var(--cream);
}
.st-qmark { color: var(--gold); display: block; }
.st-f-mark { width: clamp(52px, 4.4vw, 84px); height: auto; margin: clamp(22px, 2.2vw, 40px) 0 clamp(14px, 1.2vw, 22px); }
.st-f-quotes { flex: 1; display: flex; flex-direction: column; justify-content: center; gap: clamp(22px, 2vw, 36px); }
.st-f-quote { margin: 0; }
.st-f-quote blockquote { margin: 12px 0 0; font-family: var(--font-body); }
.st-f-quote blockquote p { overflow-wrap: anywhere; }
.st-f-q-l { font-size: clamp(25px, 2.25vw, 44px); line-height: 1.22; }
.st-f-q-m { font-size: clamp(26px, 2.4vw, 46px); line-height: 1.15; font-style: italic; }
.st-f-stars svg { width: clamp(18px, 1.3vw, 24px); height: clamp(18px, 1.3vw, 24px); }
.st-feature .st-by { margin-top: clamp(16px, 1.4vw, 26px); }
.st-feature .st-name { color: var(--white); }
.st-feature .st-src { color: rgba(249, 248, 246, .78); }
.st-feature .rv-g { background: var(--white); border-radius: 50%; padding: 2px; }
.st-f-go {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  margin-top: clamp(22px, 2vw, 36px); padding-top: 16px; border-top: 1px solid rgba(249, 248, 246, .22);
  font-family: var(--font-head); font-weight: 700; font-size: clamp(15px, 1.05vw, 19px); color: var(--gold); text-decoration: none;
}
.st-f-go svg { transition: transform .25s; }
.st-feature:hover .st-f-go svg { transform: translateX(5px); }
.st-sticker {
  position: absolute; z-index: 2; right: -18px; top: -6px; transform: rotate(8deg);
  background: var(--gold); color: var(--navy); border-radius: 18px; padding: 13px 22px 15px; text-align: center; line-height: 1.05;
  box-shadow: 0 10px 22px -8px rgba(10, 31, 68, .45);
  animation: st-wiggle 6s ease-in-out 1.5s infinite;
}
.st-sticker span { display: block; font-family: var(--font-head); font-weight: 700; font-size: 12px; letter-spacing: .12em; text-transform: uppercase; }
.st-sticker strong { display: block; margin-top: 4px; font-family: var(--font-body); font-style: italic; font-weight: 400; font-size: clamp(26px, 2.1vw, 38px); letter-spacing: -.01em; white-space: nowrap; }
@keyframes st-wiggle { 0%, 88%, 100% { transform: rotate(8deg); } 92% { transform: rotate(4deg) scale(1.04); } 96% { transform: rotate(10deg); } }
.st-hand {
  position: absolute; z-index: 2; left: 14px; bottom: 6px; transform: rotate(-4deg);
  font-family: var(--font-body); font-style: italic; font-size: clamp(22px, 1.75vw, 32px); line-height: 1.1; color: var(--navy-2);
}
.st-hand::after { content: ""; display: block; height: 3px; width: 70%; margin-top: 6px; background: var(--gold); border-radius: 3px; transform: rotate(-1deg); }

/* ---------- 2. trust strip ---------- */
.st-trust {
  list-style: none; margin: 0; padding: clamp(20px, 1.8vw, 32px) 0;
  display: grid; grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid rgba(10, 31, 68, .12); border-bottom: 1px solid rgba(10, 31, 68, .12);
}
.st-trust li { display: flex; align-items: center; justify-content: center; gap: 14px; padding: 4px 16px; min-width: 0; }
.st-trust li + li { border-left: 1px solid rgba(10, 31, 68, .12); }
.st-trust svg { flex: none; color: var(--gold-dark); width: clamp(24px, 1.8vw, 32px); height: clamp(24px, 1.8vw, 32px); }
.st-trust b { display: block; font-family: var(--font-head); font-size: clamp(15px, 1.1vw, 20px); line-height: 1.25; }
.st-trust small { display: block; font-size: clamp(14px, .95vw, 17px); color: var(--slate); margin-top: 2px; }

/* ---------- 3. stories grid ---------- */
.st-stories { padding: clamp(60px, 7vw, 140px) 0 clamp(56px, 5.8vw, 110px); scroll-margin-top: 20px; }
.st-top { display: flex; justify-content: space-between; align-items: flex-end; gap: 40px; margin-bottom: clamp(28px, 2.8vw, 52px); }
.st-top h2 { font-size: clamp(36px, 4.3vw, 82px); line-height: 1.02; letter-spacing: -.03em; margin-top: clamp(14px, 1.3vw, 24px); }
.st-top h2 em { display: block; font-style: normal; color: var(--gold-dark); }
.st-top-side { max-width: clamp(290px, 26vw, 480px); flex: none; }
.st-top-side > p { font-size: var(--fs-body); line-height: 1.5; color: var(--slate); }
.st-score { display: flex; align-items: center; gap: 14px; margin-top: 18px; padding-top: 16px; border-top: 1px solid rgba(10, 31, 68, .12); }
.st-score-big { font-family: var(--font-head); font-weight: 700; font-size: clamp(40px, 3.3vw, 62px); line-height: 1; letter-spacing: -.02em; }
.st-score-side { display: flex; flex-direction: column; gap: 4px; font-size: clamp(14px, .95vw, 17px); color: var(--slate); }
.st-score-side > span:last-child { display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.st-score-side b { color: var(--navy); }

.st-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(16px, 1.6vw, 30px); }
.st-card {
  position: relative; display: flex; flex-direction: column; min-width: 0;
  background: var(--white); border-radius: 24px; padding: clamp(22px, 2vw, 38px);
  border: 1px solid rgba(10, 31, 68, .08);
  box-shadow: 0 1px 2px rgba(10, 31, 68, .05), 0 22px 44px -34px rgba(10, 31, 68, .45);
  transition: transform .3s, box-shadow .3s, border-color .3s;
}
.st-card:hover, .st-card:focus-within { transform: translateY(-5px); border-color: rgba(197, 160, 89, .7); box-shadow: 0 36px 60px -32px rgba(10, 31, 68, .5); }
.st-card-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.st-card .st-qmark { width: clamp(34px, 2.6vw, 48px); height: auto; }
.st-text { margin: 14px 0 0; color: var(--navy); }
.st-text p { overflow-wrap: anywhere; }
.st-google {
  position: relative; z-index: 2; align-self: flex-start; margin-top: 10px;
  font-family: var(--font-head); font-weight: 700; font-size: clamp(14px, .95vw, 17px); color: var(--navy-2);
  text-decoration: underline; text-decoration-color: var(--gold); text-decoration-thickness: 2px; text-underline-offset: 4px;
}
.st-google::after { content: " \2197"; }
.st-google:hover { color: var(--navy); }
.st-by { display: flex; align-items: center; gap: 12px; }
.st-card .st-by { margin-top: auto; padding-top: clamp(20px, 1.8vw, 32px); }
.st-card .st-text, .st-card .st-google { margin-bottom: 0; }
.st-who { display: flex; flex-direction: column; min-width: 0; }
.st-name { font-family: var(--font-head); font-weight: 700; font-size: clamp(16px, 1.1vw, 21px); line-height: 1.2; }
.st-src { display: inline-flex; align-items: center; gap: 6px; font-size: clamp(14px, .9vw, 17px); color: var(--slate); }
.st-card-go {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--stone);
  font-family: var(--font-head); font-weight: 700; font-size: clamp(14px, .95vw, 17px); color: var(--navy); text-decoration: none;
}
.st-card-go svg { flex: none; color: var(--gold-dark); transition: transform .25s; }
.st-card:hover .st-card-go svg { transform: translateX(5px); }
/* short, punchy reviews get the navy card */
.st-card-navy { background: var(--navy); border-color: var(--navy); color: var(--cream); }
.st-card-navy .st-text { color: var(--cream); }
.st-card-navy .st-name { color: var(--white); }
.st-card-navy .st-src { color: rgba(249, 248, 246, .78); }
.st-card-navy .rv-g { background: var(--white); border-radius: 50%; padding: 2px; }
.st-card-navy .rv-chip { background: transparent; color: var(--cream); border-color: rgba(197, 160, 89, .7); }
.st-card-navy .st-card-go { color: var(--gold); border-color: rgba(249, 248, 246, .2); }
.st-card-navy .st-card-go svg { color: var(--gold); }
.st-card-navy .rv-av0, .st-card-navy .rv-av2 { box-shadow: inset 0 0 0 2px var(--gold); }

.st-notes { margin-top: 20px; display: grid; gap: 4px; font-size: clamp(14px, .9vw, 16px); color: var(--slate); }
.st-notes a { color: var(--navy); text-decoration-color: var(--gold); text-underline-offset: 3px; font-weight: 700; }

/* ---------- 4. inline CTA ---------- */
.st-inline {
  display: flex; justify-content: space-between; align-items: center; gap: 24px;
  margin-top: clamp(28px, 2.8vw, 52px); padding: clamp(26px, 2.4vw, 46px) clamp(26px, 2.8vw, 52px);
  background: var(--sand); border-radius: 24px; border-left: 6px solid var(--gold);
}
.st-inline-h { font-family: var(--font-head); font-weight: 700; font-size: clamp(22px, 1.9vw, 36px); line-height: 1.15; letter-spacing: -.02em; }
.st-inline p + p { margin-top: 6px; color: var(--slate); font-size: var(--fs-body); }

/* ---------- 5. team ---------- */
.st-team { padding: 0 0 clamp(60px, 7vw, 134px); }
.st-team-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 5vw, 110px); align-items: center; }
.st-team-grid > * { min-width: 0; }
.st-team-img { position: relative; margin: 0; border-radius: 28px; overflow: hidden; aspect-ratio: 4 / 3; background: var(--stone); }
.st-team-img img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 40%; }
.st-team-img figcaption {
  position: absolute; left: 16px; bottom: 16px; background: var(--white); color: var(--navy); border-radius: 14px; padding: 10px 15px;
  font-family: var(--font-head); font-weight: 700; font-size: clamp(13px, .9vw, 16px); box-shadow: 0 8px 20px -10px rgba(10, 31, 68, .4);
}
.st-team-copy h2 { font-size: clamp(34px, 3.6vw, 68px); line-height: 1.04; letter-spacing: -.03em; margin: clamp(14px, 1.3vw, 24px) 0 clamp(18px, 1.6vw, 30px); }
.st-team-copy h2 span { display: block; color: var(--gold-dark); }
.st-team-copy > p:not(.st-eyebrow) { font-size: var(--fs-body); line-height: 1.6; color: var(--slate); max-width: 32em; }
.st-team-copy > p + p:not(.st-eyebrow) { margin-top: 14px; }
.st-team-links { display: flex; flex-wrap: wrap; gap: 14px 30px; margin-top: clamp(22px, 2vw, 36px); }

/* ---------- 6. closing navy section ---------- */
.st-last {
  position: relative; overflow: hidden; isolation: isolate;
  background: var(--navy); color: var(--cream); border-radius: 36px;
  margin: 0 clamp(10px, 1.5vw, 28px) clamp(40px, 4vw, 76px);
}
.st-last::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background-image: radial-gradient(rgba(197, 160, 89, .28) 1px, transparent 1.2px); background-size: 20px 20px;
  -webkit-mask-image: linear-gradient(90deg, #000, transparent 30%, transparent 70%, #000); mask-image: linear-gradient(90deg, #000, transparent 30%, transparent 70%, #000);
}
.st-last-inner { padding: clamp(52px, 5.5vw, 110px) var(--gutter); text-align: center; }
.st-last-kicker { display: inline-block; transform: rotate(-3deg); font-family: var(--font-body); font-style: italic; font-size: clamp(24px, 2vw, 36px); color: var(--gold); margin-bottom: 16px; }
.st-last h2 { font-size: clamp(40px, 5.4vw, 104px); line-height: 1.01; letter-spacing: -.035em; max-width: 14em; margin: 0 auto; }
.st-last h2 span { display: block; color: var(--gold); }
.st-last-p { font-size: var(--fs-lead); line-height: 1.5; max-width: 30em; margin: clamp(20px, 2vw, 36px) auto clamp(26px, 2.4vw, 44px); color: rgba(249, 248, 246, .85); }
.st-last-ctas { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px 18px; }
.st-last .btn-outline { font-size: clamp(16px, 1.15vw, 21px); }
.st-last .st-ticks { justify-content: center; color: rgba(249, 248, 246, .85); margin-top: 22px; }
.st-last .st-ticks svg { color: var(--gold); }

/* ---------- responsive ---------- */
@media (max-width: 1100px) {
  .st-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .st-sticker { right: -6px; }
}
@media (max-width: 860px) {
  .st-hero-grid, .st-team-grid { grid-template-columns: 1fr; }
  .st-visual { max-width: 620px; width: 100%; margin: 0 auto; }
  .st-visual::before { inset: 0 -8px 26px -10px; border-radius: 36px; }
  .st-feature { min-height: 0; }
  .st-top { display: block; }
  .st-top-side { max-width: 36em; margin-top: 18px; }
  .st-inline { flex-direction: column; align-items: flex-start; }
  .st-trust li { flex-direction: column; text-align: center; gap: 8px; padding: 4px 8px; }
  .st-trust small { display: none; }
}
@media (max-width: 600px) {
  .st-grid { grid-template-columns: 1fr; }
  .st-hero h1 { font-size: clamp(40px, 11.5vw, 58px); }
  .st-actions .btn { width: 100%; }
  .st-sticker { right: 4px; top: -10px; padding: 10px 16px 12px; }
  .st-sticker span { font-size: 10px; }
  .st-hand { left: 8px; }
  .st-feature { border-radius: 24px; }
  .st-trust b { font-size: 13px; }
  .st-inline .btn { width: 100%; }
  .st-last { border-radius: 26px; }
  .st-last-ctas .btn { width: 100%; }
  .st-last .btn-outline { flex-direction: column; gap: 5px; font-size: 16px; padding: 12px 26px; }
  .st-last .btn-outline .dot { display: none; }
  .st-team-img figcaption { left: 10px; bottom: 10px; font-size: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  .st-sticker { animation: none; }
  .st-card, .st-feature, .st-textlink, .st-card-go svg, .st-f-go svg { transition: none; }
}
