/* Loss Analysis page */

#rx-loss-analysis {
  --rx-la-paper: #FFFFFF;
  --rx-la-ink: #0D1D2D;
  --rx-la-body: #323639;
  --rx-la-muted: #4A5560;
  --rx-la-muted-2: #3D4A57;
  --rx-la-blue: #357FC2;
  --rx-la-blue-soft: #6FA8D4;
  --rx-la-blue-pale: #9FB6CC;
  --rx-la-accent: #D26317;
  --rx-la-accent-soft: #F0955C;
  --rx-la-accent-dark: #bb5512;
  --rx-la-tint: #FBFDFF;
  --rx-la-gray: #C7CDD2;
  --rx-la-gray-2: #8C99A4;
  --rx-la-rule: rgba(13, 29, 45, 0.1);
  --rx-la-rule-soft: rgba(13, 29, 45, 0.08);
  --rx-la-wrap: 1200px;
  --rx-la-pad: clamp(22px, 5vw, 40px);
  background: var(--rx-la-paper);
  color: var(--rx-la-body);
  font-family: 'IBM Plex Sans', ui-sans-serif, system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

#rx-loss-analysis a:focus-visible {
  outline: 2px solid var(--rx-la-accent);
  outline-offset: 4px;
}

.rx-la-wrap {
  max-width: var(--rx-la-wrap);
  margin: 0 auto;
  padding-left: var(--rx-la-pad);
  padding-right: var(--rx-la-pad);
}

.rx-la-em {
  font-style: italic;
  color: var(--rx-la-accent);
}

.rx-la-num {
  font-family: 'IBM Plex Serif', Georgia, 'Times New Roman', serif;
  font-style: italic;
  font-size: 15px;
  color: var(--rx-la-blue);
  padding-top: 4px;
}

.rx-la-num--muted {
  color: var(--rx-la-gray);
}

.rx-la-eyebrow {
  display: block;
  font-family: 'IBM Plex Serif', Georgia, 'Times New Roman', serif;
  font-style: italic;
  font-size: 16px;
  color: var(--rx-la-blue);
}

.rx-la-heading {
  font-family: 'IBM Plex Serif', Georgia, 'Times New Roman', serif;
  font-weight: 400;
  font-size: clamp(28px, 3.5vw, 34px);
  line-height: 1.25;
  letter-spacing: -0.01em;
  margin: 14px 0 0;
  color: var(--rx-la-ink);
  max-width: 760px;
  text-wrap: balance;
}

.rx-la-heading--lg {
  font-size: clamp(28px, 3.8vw, 36px);
  line-height: 1.2;
}

.rx-la-fade {
  opacity: 1;
  transform: none;
}

.rx-la-fade.rx-la-armed {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.rx-la-fade.rx-la-armed.rx-la-in {
  opacity: 1;
  transform: translateY(0);
}

/* Hero */
.rx-la-hero {
  position: relative;
  background: linear-gradient(180deg, #EBF2F9 0%, #FBFDFF 82%);
}

.rx-la-hero__top {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 40px;
  align-items: end;
  padding: 140px 0 64px;
}

.rx-la-hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--rx-la-blue);
  font-weight: 600;
  margin-bottom: 28px;
}

.rx-la-hero__eyebrow-line {
  width: 24px;
  height: 1.5px;
  background: var(--rx-la-accent);
}

.rx-la-hero__title {
  font-family: 'IBM Plex Serif', Georgia, 'Times New Roman', serif;
  font-weight: 400;
  font-size: clamp(48px, 8vw, 76px);
  line-height: 0.98;
  letter-spacing: -0.03em;
  margin: 0;
  color: var(--rx-la-ink);
}

.rx-la-hero__desc {
  font-size: 17px;
  line-height: 1.65;
  color: var(--rx-la-muted);
  margin: 0;
  padding-bottom: 6px;
}

/* Capacity diagram */
.rx-la-cap {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 48px;
  align-items: center;
  border-top: 1px solid rgba(13, 29, 45, 0.12);
  padding: 56px 0 64px;
}

.rx-la-cap__intro {
  font-size: 15px;
  line-height: 1.7;
  color: var(--rx-la-muted);
  margin: 0 0 28px;
  max-width: 520px;
}

.rx-la-cap__bars {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.rx-la-cap-bar__meta {
  display: flex;
  justify-content: space-between;
  margin-bottom: 8px;
  gap: 12px;
}

.rx-la-cap-bar__label {
  font-size: 13px;
  font-weight: 600;
  color: var(--rx-la-ink);
}

.rx-la-cap-bar__label--second {
  color: var(--rx-la-accent);
}

.rx-la-cap-bar__value {
  font-size: 12.5px;
  color: var(--rx-la-gray-2);
}

.rx-la-cap-bar__value--second {
  color: var(--rx-la-accent);
  font-weight: 600;
}

.rx-la-cap-bar__track {
  height: 34px;
  background: rgba(13, 29, 45, 0.06);
  border-radius: 4px;
  overflow: hidden;
  position: relative;
}

.rx-la-cap-bar__track--second {
  background: rgba(210, 99, 23, 0.08);
  border: 1px dashed rgba(210, 99, 23, 0.4);
}

.rx-la-bar-fill {
  height: 100%;
  width: 0%;
  border-radius: 4px;
  transition: width 1.1s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.rx-la-bar-fill--installed {
  background: linear-gradient(90deg, #0D1D2D, #023E66);
}

.rx-la-bar-fill--shipped {
  background: linear-gradient(90deg, #357FC2, #6FA8D4);
}

.rx-la-bar-fill--second {
  background: repeating-linear-gradient(
    135deg,
    rgba(210, 99, 23, 0.35) 0 8px,
    rgba(210, 99, 23, 0.18) 8px 16px
  );
}

/* Snapshot card */
.rx-la-snapshot {
  background: #fff;
  border: 1px solid var(--rx-la-rule);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 40px 70px -40px rgba(2, 48, 79, 0.35);
}

.rx-la-snapshot__head {
  padding: 24px 26px 20px;
  border-bottom: 1px solid var(--rx-la-rule-soft);
}

.rx-la-snapshot__eyebrow {
  font-size: 10.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--rx-la-gray-2);
  font-weight: 600;
  margin-bottom: 14px;
}

.rx-la-snapshot__stat {
  display: flex;
  align-items: baseline;
  gap: 10px;
}

.rx-la-snapshot__pct {
  font-family: 'IBM Plex Serif', Georgia, 'Times New Roman', serif;
  font-weight: 400;
  font-size: 44px;
  color: var(--rx-la-accent);
  letter-spacing: -0.02em;
  line-height: 1;
}

.rx-la-snapshot__caption {
  font-size: 13px;
  color: var(--rx-la-muted);
  line-height: 1.4;
}

.rx-la-snapshot__rows {
  padding: 22px 26px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.rx-la-snapshot__row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.rx-la-snapshot__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex: none;
}

.rx-la-snapshot__label {
  font-size: 13.5px;
  color: var(--rx-la-ink);
  flex: 1;
  min-width: 0;
}

.rx-la-snapshot__track {
  width: 110px;
  height: 6px;
  background: rgba(13, 29, 45, 0.07);
  border-radius: 3px;
  overflow: hidden;
  flex: none;
}

.rx-la-snapshot__fill {
  height: 100%;
  border-radius: 3px;
}

.rx-la-snapshot__level {
  font-size: 11px;
  font-weight: 600;
  width: 34px;
  text-align: right;
  flex: none;
}

.rx-la-snapshot__footer {
  background: var(--rx-la-ink);
  padding: 16px 26px;
  font-size: 12.5px;
  color: #C2D3E1;
  line-height: 1.5;
}

/* Body */
.rx-la-body {
  padding: 96px 0 0;
}

.rx-la-body__grid {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 24px;
}

.rx-la-body__copy {
  border-left: 2px solid var(--rx-la-accent);
  padding-left: 44px;
}

.rx-la-body__lead {
  font-family: 'IBM Plex Serif', Georgia, 'Times New Roman', serif;
  font-weight: 400;
  font-size: clamp(24px, 3vw, 32px);
  line-height: 1.38;
  letter-spacing: -0.01em;
  color: var(--rx-la-ink);
  margin: 0 0 28px;
  max-width: 900px;
  text-wrap: balance;
}

.rx-la-body__text {
  font-size: 17px;
  line-height: 1.85;
  color: var(--rx-la-muted-2);
  margin: 0;
  max-width: 780px;
}

/* 7 Big Losses */
.rx-la-losses {
  padding: 96px 0 0;
}

.rx-la-losses__head {
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: 24px;
  border-top: 1px solid var(--rx-la-rule);
  padding-top: 56px;
}

.rx-la-losses__desc {
  font-size: 15.5px;
  line-height: 1.75;
  color: var(--rx-la-muted);
  margin: 12px 0 44px;
  max-width: 660px;
}

.rx-la-chart {
  border: 1px solid var(--rx-la-rule);
  border-radius: 8px;
  padding: 36px 32px 20px;
  background: var(--rx-la-tint);
}

.rx-la-chart__legend {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
  gap: 16px;
  flex-wrap: wrap;
}

.rx-la-chart__legend-label,
.rx-la-chart__legend-cum {
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--rx-la-gray-2);
  font-weight: 600;
}

.rx-la-chart__legend-cum {
  display: flex;
  align-items: center;
  gap: 8px;
  letter-spacing: 0;
  text-transform: none;
  font-weight: 400;
}

.rx-la-chart__dash {
  width: 16px;
  height: 0;
  border-top: 2px dashed var(--rx-la-ink);
  display: inline-block;
}

.rx-la-chart__svg {
  width: 100%;
  height: auto;
  display: block;
  overflow: visible;
}

.rx-la-chart__labels {
  display: grid;
  gap: 8px;
  margin-top: 14px;
  padding-top: 16px;
  border-top: 1px solid var(--rx-la-rule-soft);
}

.rx-la-chart__label {
  text-align: center;
}

.rx-la-chart__label-title {
  font-size: 12px;
  color: var(--rx-la-ink);
  font-weight: 500;
  margin-bottom: 3px;
}

.rx-la-chart__label-title.is-strong {
  font-weight: 600;
}

.rx-la-chart__label-note {
  font-size: 11px;
  color: var(--rx-la-gray-2);
}

.rx-la-chart__label-note.is-accent {
  color: var(--rx-la-accent);
}

/* Output / decision set */
.rx-la-output {
  margin-top: 112px;
  position: relative;
  overflow: hidden;
  background: linear-gradient(180deg, #EBF2F9 0%, #FBFDFF 82%);
}

.rx-la-output__glow {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
}

.rx-la-output__glow--left {
  left: 12%;
  top: -120px;
  width: 420px;
  height: 420px;
  /* background: radial-gradient(circle, rgba(53, 127, 194, 0.22), rgba(53, 127, 194, 0) 70%); */
}

.rx-la-output__glow--right {
  right: 8%;
  bottom: -140px;
  width: 380px;
  height: 380px;
  /* background: radial-gradient(circle, rgba(240, 149, 92, 0.16), rgba(240, 149, 92, 0) 70%); */
}

.rx-la-output__inner {
  position: relative;
  padding: 88px 0;
}

.rx-la-output__intro {
  max-width: 680px;
  margin-bottom: 56px;
}

.rx-la-output__eyebrow {
  display: block;
  font-family: 'IBM Plex Serif', Georgia, 'Times New Roman', serif;
  font-style: italic;
  font-size: 16px;
  color: var(--rx-la-blue);
}

.rx-la-output__title {
  font-family: 'IBM Plex Serif', Georgia, 'Times New Roman', serif;
  font-weight: 400;
  font-size: clamp(26px, 3.5vw, 34px);
  line-height: 1.3;
  color: var(--rx-la-ink);
  margin: 16px 0 0;
  letter-spacing: -0.01em;
}

.rx-la-output__title-em {
  color: #D26317;
  font-style: italic;
}

.rx-la-output__desc {
  font-size: 15.5px;
  color: var(--rx-la-muted-2);
  line-height: 1.7;
  margin: 20px 0 0;
  max-width: 520px;
}

.rx-la-output__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  background: transparent;
  border-radius: 8px;
  overflow: hidden;
}

.rx-la-output__card {
  background: var(--rx-la-ink);
  padding: 32px 28px;
  border-right: 1px solid rgba(255, 255, 255, 0.1);
}

.rx-la-output__card:last-child {
  border-right: none;
}

.rx-la-output__num {
  font-family: 'IBM Plex Serif', Georgia, 'Times New Roman', serif;
  font-style: italic;
  font-size: 13px;
  color: var(--rx-la-blue-soft);
  margin-bottom: 16px;
}

.rx-la-output__num--orange {
  color: var(--rx-la-accent-soft);
}

.rx-la-output__card-title {
  font-family: 'IBM Plex Serif', Georgia, 'Times New Roman', serif;
  font-size: 18px;
  color: #fff;
  margin-bottom: 10px;
}

.rx-la-output__card-desc {
  font-size: 14.5px;
  color: var(--rx-la-blue-pale);
  line-height: 1.6;
}

/* Results */
.rx-la-results {
  padding: 112px 0 0;
}

.rx-la-results__head {
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: 24px;
  margin-bottom: 48px;
}

.rx-la-results__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: rgba(13, 29, 45, 0.08);
  border-top: 1px solid var(--rx-la-rule-soft);
  border-bottom: 1px solid var(--rx-la-rule-soft);
}

.rx-la-results__card {
  background: #fff;
  padding: 32px 26px;
}

.rx-la-results__grid.rx-la-armed .rx-la-results__card {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.rx-la-results__grid.rx-la-armed.rx-la-in .rx-la-results__card {
  opacity: 1;
  transform: translateY(0);
}

.rx-la-results__grid.rx-la-armed.rx-la-in .rx-la-results__card:nth-child(1) { transition-delay: 0.05s; }
.rx-la-results__grid.rx-la-armed.rx-la-in .rx-la-results__card:nth-child(2) { transition-delay: 0.12s; }
.rx-la-results__grid.rx-la-armed.rx-la-in .rx-la-results__card:nth-child(3) { transition-delay: 0.19s; }
.rx-la-results__grid.rx-la-armed.rx-la-in .rx-la-results__card:nth-child(4) { transition-delay: 0.26s; }

.rx-la-results__num {
  font-family: 'IBM Plex Serif', Georgia, 'Times New Roman', serif;
  font-style: italic;
  font-size: 13px;
  color: var(--rx-la-blue);
  margin-bottom: 16px;
}

.rx-la-results__num--orange {
  color: var(--rx-la-accent);
}

.rx-la-results__title {
  font-family: 'IBM Plex Serif', Georgia, 'Times New Roman', serif;
  font-size: 17px;
  color: var(--rx-la-ink);
  line-height: 1.4;
}

/* CTA */
.rx-la-cta {
  padding: 112px 0 96px;
}

.rx-la-cta__card {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #0D1D2D 0%, #023E66 100%);
  border-radius: 14px;
  padding: 100px 40px;
  text-align: center;
}

.rx-la-cta__glow {
  position: absolute;
  left: 50%;
  top: -160px;
  transform: translateX(-50%);
  width: 520px;
  height: 520px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(53, 127, 194, 0.35), rgba(53, 127, 194, 0) 70%);
  pointer-events: none;
}

.rx-la-cta__text {
  position: relative;
  z-index: 1;
  font-family: 'IBM Plex Serif', Georgia, 'Times New Roman', serif;
  font-weight: 400;
  font-size: clamp(24px, 3vw, 34px);
  line-height: 1.4;
  color: #fff;
  margin: 0 auto 40px;
  max-width: 740px;
  letter-spacing: -0.01em;
}

.rx-la-btn {
  position: relative;
  z-index: 1;
  display: inline-block;
  text-decoration: none;
  background: var(--rx-la-accent);
  color: #fff;
  font-weight: 600;
  font-size: 15px;
  padding: 16px 36px;
  border-radius: 999px;
  transition: transform 0.2s ease, background 0.2s ease;
}

.rx-la-btn:hover {
  background: var(--rx-la-accent-dark);
  color: #fff;
  transform: translateY(-2px);
}

/* Parent theme font overrides */
body.rx-design.rx-loss-analysis-page #rx-loss-analysis .rx-la-hero__title,
body.rx-design.rx-loss-analysis-page #rx-loss-analysis .rx-la-body__lead,
body.rx-design.rx-loss-analysis-page #rx-loss-analysis .rx-la-heading,
body.rx-design.rx-loss-analysis-page #rx-loss-analysis .rx-la-eyebrow,
body.rx-design.rx-loss-analysis-page #rx-loss-analysis .rx-la-num,
body.rx-design.rx-loss-analysis-page #rx-loss-analysis .rx-la-snapshot__pct,
body.rx-design.rx-loss-analysis-page #rx-loss-analysis .rx-la-output__eyebrow,
body.rx-design.rx-loss-analysis-page #rx-loss-analysis .rx-la-output__title,
body.rx-design.rx-loss-analysis-page #rx-loss-analysis .rx-la-output__card-title,
body.rx-design.rx-loss-analysis-page #rx-loss-analysis .rx-la-output__num,
body.rx-design.rx-loss-analysis-page #rx-loss-analysis .rx-la-results__num,
body.rx-design.rx-loss-analysis-page #rx-loss-analysis .rx-la-results__title,
body.rx-design.rx-loss-analysis-page #rx-loss-analysis .rx-la-cta__text {
  font-family: 'IBM Plex Serif', Georgia, 'Times New Roman', serif !important;
}

/* Responsive */
@media (max-width: 900px) {
  .rx-la-hero__top,
  .rx-la-cap,
  .rx-la-body__grid,
  .rx-la-losses__head,
  .rx-la-results__head,
  .rx-la-output__grid,
  .rx-la-results__grid {
    grid-template-columns: 1fr !important;
  }

  .rx-la-output__card {
    border-right: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

  .rx-la-output__card:last-child {
    border-bottom: none;
  }

  .rx-la-hero__top {
    padding: 96px 0 48px;
    gap: 24px;
  }

  .rx-la-cap {
    gap: 36px;
    padding: 40px 0 48px;
  }

  .rx-la-num-col {
    display: none !important;
  }

  .rx-la-body__copy {
    border-left: none;
    padding-left: 0;
  }

  .rx-la-body {
    padding-top: 72px;
  }

  .rx-la-losses {
    padding-top: 72px;
  }

  .rx-la-losses__head {
    padding-top: 40px;
  }

  .rx-la-losses__desc {
    margin-bottom: 32px;
  }

  .rx-la-chart {
    padding: 28px 18px 16px;
  }

  .rx-la-chart__labels {
    grid-template-columns: 1fr 1fr !important;
    gap: 14px 8px;
  }

  .rx-la-output {
    margin-top: 80px;
  }

  .rx-la-output__inner {
    padding: 64px 0;
  }

  .rx-la-output__intro {
    margin-bottom: 36px;
  }

  .rx-la-results {
    padding-top: 80px;
  }

  .rx-la-results__head {
    margin-bottom: 32px;
  }

  .rx-la-cta {
    padding: 80px 0 72px;
  }

  .rx-la-cta__card {
    padding: 64px 28px;
  }

  .rx-la-snapshot__track {
    width: 80px;
  }
}

@media (max-width: 560px) {
  .rx-la-snapshot__row {
    flex-wrap: wrap;
  }

  .rx-la-snapshot__track {
    width: 100%;
    order: 4;
    margin-left: 20px;
  }

  .rx-la-snapshot__level {
    margin-left: auto;
  }
}
