/* ============================================================
   BeneCare RPM — exploration styles
   Tokens + 3 visual directions + shared calculator variants
   ============================================================ */

:root {
  --ink:          #0F1B2D;
  --ink-soft:     #44566b;
  --ink-faint:    #6b7a8c;
  --primary:      #0E7C8A;   /* teal */
  --primary-deep: #103D52;   /* petrol */
  --positive:     #0E8A6B;   /* emerald */
  --sand:         #E6B566;   /* warm accent */
  --bg:           #FFFFFF;
  --surface:      #F4F7F9;
  --surface-2:    #ECF2F4;
  --hairline:     #E2E8EC;
  --neg:          #9aa7b4;
  --font-display: "Schibsted Grotesk", system-ui, sans-serif;
  --font-text:    "Inter", system-ui, sans-serif;
}

/* ---- direction root shells ---- */
.dir {
  font-family: var(--font-text);
  color: var(--ink);
  width: 100%;
  height: 100%;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-size: 17px;
  line-height: 1.5;
}
.dir *,
.dir *::before,
.dir *::after { box-sizing: border-box; }

.dir h1, .dir h2, .dir h3 {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.02em;
  margin: 0;
  text-wrap: balance;
}
.dir p { margin: 0; }

/* ---- shared top bar ---- */
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 56px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 21px;
  letter-spacing: -0.02em;
  color: var(--ink);
}
.brand .mark {
  width: 26px; height: 26px;
  border-radius: 7px;
  background: var(--primary);
  display: grid; place-items: center;
  position: relative;
}
.brand .mark::after {
  content: "";
  width: 11px; height: 11px;
  border: 2px solid #fff;
  border-radius: 50%;
  border-right-color: transparent;
  transform: rotate(-45deg);
}
.cobrand {
  font-size: 12.5px;
  color: var(--ink-faint);
  letter-spacing: 0.01em;
}
.cobrand b { color: var(--ink-soft); font-weight: 600; }

/* ---- shared atoms ---- */
.eyebrow {
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--primary);
}
.btn {
  font-family: var(--font-text);
  font-weight: 600;
  font-size: 16px;
  border-radius: 11px;
  padding: 14px 24px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background .18s, color .18s, border-color .18s, transform .12s;
  white-space: nowrap;
}
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: #0c6b77; }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--hairline); }
.btn-ghost:hover { border-color: var(--primary); color: var(--primary); }

.livepill {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 14.5px;
  color: var(--ink-soft);
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: 999px;
  padding: 8px 16px;
}
.livepill .dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--positive);
  box-shadow: 0 0 0 3px rgba(14,138,107,.16);
}
.livepill b { color: var(--positive); font-weight: 600; font-variant-numeric: tabular-nums; }

.trust {
  display: flex;
  gap: 28px;
  flex-wrap: wrap;
}
.trust .item {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 14.5px;
  color: var(--ink-soft);
}
.trust .item .tick {
  width: 17px; height: 17px; flex: 0 0 auto;
  color: var(--primary);
}

/* image / device placeholder */
.ph {
  position: relative;
  border-radius: 14px;
  border: 1px solid var(--hairline);
  background:
    repeating-linear-gradient(135deg, rgba(14,124,138,.05) 0 11px, rgba(14,124,138,.10) 11px 22px),
    var(--surface);
  display: grid;
  place-items: center;
  overflow: hidden;
}
.ph-label {
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
  font-size: 12px;
  letter-spacing: 0.02em;
  color: var(--ink-faint);
  background: rgba(255,255,255,.82);
  padding: 5px 10px;
  border-radius: 7px;
  border: 1px solid var(--hairline);
}

/* ============================================================
   CALCULATOR  (shared structure, variant skins)
   ============================================================ */
.calc {
  font-family: var(--font-text);
  font-variant-numeric: tabular-nums;
}
.calc-controls { }
.calc-sliderhead {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 16px;
}
.calc-sliderhead label {
  font-size: 15.5px;
  font-weight: 600;
  color: var(--ink);
}
.calc-pcount {
  font-family: var(--font-display);
  font-size: 30px;
  font-weight: 600;
  color: var(--primary-deep);
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}
.calc-pcount small {
  font-family: var(--font-text);
  font-size: 14px;
  font-weight: 500;
  color: var(--ink-faint);
  margin-left: 4px;
  letter-spacing: 0;
}

/* range input */
.calc input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 8px;
  border-radius: 999px;
  background: linear-gradient(to right,
      var(--primary) 0 var(--pct, 14%),
      var(--surface-2) var(--pct, 14%) 100%);
  outline: none;
  cursor: pointer;
  margin: 4px 0;
}
.calc input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 26px; height: 26px;
  border-radius: 50%;
  background: #fff;
  border: 2px solid var(--primary);
  box-shadow: 0 2px 7px rgba(15,27,45,.18);
  transition: transform .12s, box-shadow .12s;
}
.calc input[type="range"]::-webkit-slider-thumb:hover { transform: scale(1.07); }
.calc input[type="range"]:focus-visible::-webkit-slider-thumb {
  box-shadow: 0 0 0 5px rgba(14,124,138,.22);
}
.calc input[type="range"]::-moz-range-thumb {
  width: 26px; height: 26px;
  border-radius: 50%;
  background: #fff;
  border: 2px solid var(--primary);
  box-shadow: 0 2px 7px rgba(15,27,45,.18);
}
.calc-scale {
  display: flex;
  justify-content: space-between;
  font-size: 12.5px;
  color: var(--ink-faint);
  margin-top: 7px;
}

/* CCM share slider block */
.calc-ccm {
  display: block;
  margin-top: 24px;
  padding-top: 22px;
  border-top: 1px solid var(--hairline);
}
.calc-toggle {
  position: relative;
  width: 46px; height: 27px;
  border-radius: 999px;
  border: none;
  background: #cdd8df;
  cursor: pointer;
  flex: 0 0 auto;
  transition: background .2s;
  padding: 0;
}
.calc-toggle[aria-checked="true"] { background: var(--primary); }
.calc-knob {
  position: absolute;
  top: 3px; left: 3px;
  width: 21px; height: 21px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0,0,0,.25);
  transition: transform .2s;
}
.calc-toggle[aria-checked="true"] .calc-knob { transform: translateX(19px); }
.calc-ccm-label { font-size: 15px; color: var(--ink); font-weight: 500; }
.calc-ccm-label span { display: block; font-size: 12.5px; color: var(--ink-faint); font-weight: 400; }

/* readout */
.calc-readout { margin-top: 28px; }
.calc-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  padding: 9px 0;
}
.calc-row .label { font-size: 15px; color: var(--ink-soft); flex: 1 1 auto; }
.calc-row .val {
  font-size: 17px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  flex: 0 0 auto;
}
.calc-row .val.plus { color: var(--ink); }
.calc-row .val.minus { color: var(--neg); }
.calc-row .val small { font-weight: 500; color: var(--ink-faint); font-size: 13px; margin-left: 2px; }
.rdash { color: var(--neg); font-weight: 500; padding: 0 1px; }
.calc-rule { height: 1px; background: var(--hairline); margin: 8px 0 4px; }

/* ---- headline net (first screen) ---- */
.calc-net {
  display: block;
  padding: 4px 0 2px;
}
.calc-netlabel { font-size: 15px; color: var(--ink-soft); margin-bottom: 8px; display: flex; align-items: center; gap: 6px; }
.calc-netnum {
  font-family: var(--font-display);
  font-size: clamp(38px, 5vw, 52px);
  font-weight: 600;
  line-height: 1.0;
  color: var(--positive);
  letter-spacing: -0.025em;
  font-variant-numeric: tabular-nums;
}
.calc-netline { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.calc-netline .u { font-family: var(--font-text); font-size: 20px; font-weight: 500; color: var(--ink-faint); letter-spacing: 0; }
.upto {
  font-family: var(--font-text); font-size: 14px; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.08em; color: var(--positive);
  opacity: .72; align-self: center;
}
.upto-sm { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.07em; color: var(--ink-faint); }
.upto-tiny { font-size: 10.5px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.06em; color: var(--ink-faint); margin-right: 1px; }
.calc-annual { display: flex; align-items: baseline; gap: 8px; margin-top: 14px; text-align: left; }
.calc-annual .a-label { font-size: 13px; color: var(--ink-faint); }
.calc-annual .a-num {
  font-family: var(--font-display);
  font-size: 18px; font-weight: 600;
  color: var(--primary-deep);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.calc-annual .a-num .u { font-size: 12.5px; color: var(--ink-faint); font-weight: 500; margin-left: 2px; }

/* ---- CCM (secondary, compact) ---- */
.calc-ccm-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 9px; }
.calc-ccm-head label { font-size: 14px; font-weight: 600; color: var(--ink-soft); display: inline-flex; align-items: center; gap: 6px; }
.calc-ccmval { font-family: var(--font-display); font-size: 17px; font-weight: 600; color: var(--primary-deep); font-variant-numeric: tabular-nums; }

/* ---- tooltip ---- */
.tip { position: relative; display: inline-flex; vertical-align: middle; }
.tip-btn {
  width: 16px; height: 16px; border-radius: 50%; padding: 0;
  border: 1px solid var(--hairline); background: var(--surface);
  color: var(--ink-faint); font-size: 10.5px; font-weight: 700; line-height: 1;
  font-family: var(--font-text); cursor: help; display: grid; place-items: center;
  transition: border-color .15s, color .15s;
}
.tip-btn:hover, .tip-btn:focus-visible { border-color: var(--primary); color: var(--primary); outline: none; }
.tip-pop {
  position: absolute; bottom: calc(100% + 9px); left: 50%; transform: translateX(-50%) translateY(4px);
  width: max-content; max-width: 250px;
  background: var(--ink); color: #fff; font-family: var(--font-text);
  font-size: 12.5px; font-weight: 400; line-height: 1.45; letter-spacing: 0;
  text-transform: none; padding: 10px 13px; border-radius: 10px;
  box-shadow: 0 10px 28px rgba(15,27,45,.26);
  opacity: 0; visibility: hidden; transition: opacity .16s, transform .16s; z-index: 20;
  pointer-events: none; text-align: left; white-space: normal;
}
.tip-pop::after {
  content: ""; position: absolute; top: 100%; left: 50%; transform: translateX(-50%);
  border: 6px solid transparent; border-top-color: var(--ink);
}
.tip:hover .tip-pop, .tip:focus-within .tip-pop { opacity: 1; visibility: visible; transform: translateX(-50%) translateY(0); }

/* ---- in-card CTA under the result ---- */
.calc-cta-wrap { margin-top: 20px; padding-top: 18px; border-top: 1px solid var(--hairline); }
.calc-cta-lead { font-size: 14px; color: var(--ink-soft); margin-bottom: 6px; }
.calc-cta {
  display: inline-flex; align-items: center; gap: 6px;
  font-family: var(--font-text); font-size: 15px; font-weight: 600;
  color: var(--primary); cursor: pointer;
  padding: 11px 18px; border: 1.5px solid var(--primary); border-radius: 10px;
  transition: background .15s, color .15s, border-color .15s;
}
.calc-cta:hover { background: var(--primary); color: #fff; }

/* ---- progressive disclosure (breakdown) ---- */
.calc-disclosure {
  display: inline-flex; align-items: center; gap: 6px; white-space: nowrap;
  margin-top: 18px; padding: 0; border: none; background: none; cursor: pointer;
  font-family: var(--font-text); font-size: 13.5px; font-weight: 600; color: var(--ink-soft);
  transition: color .15s;
}
.calc-disclosure:hover { color: var(--primary); }
.calc-disclosure .d-chev { transition: transform .25s; font-size: 12px; line-height: 1; }
.calc-disclosure.open .d-chev { transform: rotate(180deg); }
.calc-breakdown { overflow: hidden; height: 0; transition: height .28s ease; }
.calc-breakdown .bd-inner { padding-top: 14px; }
.calc-row.total .label { font-weight: 600; color: var(--ink); }
.calc-row.total .val.net { color: var(--positive); }

.calc-foot { font-size: 13px; color: var(--ink-faint); margin-top: 16px; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }

/* ---- service fee + staffing reality (first screen) ---- */
.calc-facts {
  margin-top: 20px; padding-top: 18px;
  border-top: 1px solid var(--hairline);
}
.calc-fact {
  display: flex; align-items: baseline; justify-content: space-between; gap: 14px;
}
.calc-fact .cf-label { font-size: 15px; color: var(--ink-soft); }
.calc-fact .cf-val {
  font-family: var(--font-display); font-size: 18px; font-weight: 600;
  color: var(--ink); font-variant-numeric: tabular-nums; white-space: nowrap;
}
.calc-fact .cf-val small { font-family: var(--font-text); font-size: 13px; font-weight: 500; color: var(--ink-faint); margin-left: 1px; }
.calc-fact .cf-val em { font-style: normal; font-family: var(--font-text); font-size: 13.5px; font-weight: 500; color: var(--ink-faint); }
.calc-team {
  margin-top: 12px; font-size: 13.5px; line-height: 1.5; color: var(--ink-soft);
  background: var(--surface); border: 1px solid var(--hairline); border-radius: 11px;
  padding: 13px 15px; text-wrap: pretty;
}
.calc-disc {
  font-size: 11.5px;
  line-height: 1.55;
  color: #9aa6b2;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--hairline);
}

/* ============================================================
   DIRECTION A — Clinical Calm  (white · centered · airy)
   ============================================================ */
.dirA { background: #fff; }
.dirA .hero {
  text-align: center;
  padding: 40px 56px 56px;
  max-width: 900px;
  margin: 0 auto;
}
.dirA .hero .eyebrow { display: block; margin-bottom: 20px; }
.dirA .hero h1 {
  font-size: 56px;
  line-height: 1.04;
  max-width: 16ch;
  margin: 0 auto 24px;
}
.dirA .hero .sub {
  font-size: 19px;
  color: var(--ink-soft);
  max-width: 60ch;
  margin: 0 auto 30px;
  line-height: 1.55;
  text-wrap: pretty;
}
.dirA .cta-row {
  display: flex;
  gap: 14px;
  justify-content: center;
  margin-bottom: 22px;
}
.dirA .hero .livepill { margin-bottom: 38px; }
.dirA .trust { justify-content: center; }
.dirA .calc-section {
  background: var(--surface);
  border-top: 1px solid var(--hairline);
  padding: 56px;
}
.dirA .calc-section .head {
  text-align: center;
  margin-bottom: 32px;
}
.dirA .calc-section h2 { font-size: 34px; margin-bottom: 10px; }
.dirA .calc-section .head p { color: var(--ink-soft); font-size: 17px; }
.dirA .calc--A {
  max-width: 720px;
  margin: 0 auto;
  background: #fff;
  border: 1px solid var(--hairline);
  border-radius: 18px;
  box-shadow: 0 1px 2px rgba(15,27,45,.04), 0 18px 44px rgba(15,27,45,.07);
  padding: 36px 40px;
}

/* ============================================================
   DIRECTION B — Editorial Warm  (cool surface · 2-col · sand)
   ============================================================ */
.dirB { background: var(--surface); }
.dirB .hero {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 56px;
  align-items: center;
  padding: 36px 56px 64px;
}
.dirB .hero .eyebrow { display: block; margin-bottom: 22px; }
.dirB .hero h1 {
  font-size: 64px;
  line-height: 1.0;
  letter-spacing: -0.03em;
  margin-bottom: 26px;
}
.dirB .hero h1 .uline {
  background-image: linear-gradient(transparent 62%, rgba(230,181,102,.55) 62%);
  padding: 0 2px;
}
.dirB .hero .sub {
  font-size: 18px;
  color: var(--ink-soft);
  max-width: 46ch;
  margin-bottom: 30px;
  line-height: 1.55;
  text-wrap: pretty;
}
.dirB .cta-row { display: flex; gap: 14px; margin-bottom: 30px; }
.dirB .trust { flex-direction: column; gap: 13px; }
.dirB .calc-card-wrap { position: relative; }
.dirB .calc-card-wrap .kicker {
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--primary);
  margin-bottom: 14px;
  display: block;
}
.dirB .calc--B {
  background: #fff;
  border-radius: 20px;
  border: 1px solid var(--hairline);
  box-shadow: 0 2px 4px rgba(15,27,45,.05), 0 26px 60px rgba(15,27,45,.12);
  padding: 34px 36px;
}
.dirB .calc--B .calc-netnum { font-size: clamp(30px, 3.4vw, 40px); }

/* ============================================================
   DIRECTION C — Product / Device-forward (petrol band · renders)
   ============================================================ */
.dirC { background: #fff; }
.dirC .band {
  background:
    radial-gradient(120% 130% at 88% 8%, rgba(14,124,138,.42) 0%, rgba(16,61,82,0) 52%),
    linear-gradient(168deg, #103D52 0%, #0c2f40 100%);
  color: #fff;
  padding: 22px 56px 60px;
}
.dirC .band .topbar { padding: 0 0 44px; }
.dirC .band .brand { color: #fff; }
.dirC .band .brand .mark { background: rgba(255,255,255,.16); }
.dirC .band .cobrand { color: rgba(255,255,255,.62); }
.dirC .band .cobrand b { color: rgba(255,255,255,.85); }
.dirC .hero {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 48px;
  align-items: center;
}
.dirC .hero .eyebrow { color: #6fd0d8; display: block; margin-bottom: 20px; }
.dirC .hero h1 {
  font-size: 54px;
  line-height: 1.03;
  color: #fff;
  margin-bottom: 22px;
  max-width: 15ch;
}
.dirC .hero .sub {
  font-size: 18px;
  color: rgba(255,255,255,.78);
  max-width: 48ch;
  margin-bottom: 30px;
  line-height: 1.55;
  text-wrap: pretty;
}
.dirC .cta-row { display: flex; gap: 14px; margin-bottom: 28px; }
.dirC .band .btn-ghost { color: #fff; border-color: rgba(255,255,255,.32); }
.dirC .band .btn-ghost:hover { border-color: #fff; color: #fff; background: rgba(255,255,255,.08); }
.dirC .band .trust .item { color: rgba(255,255,255,.72); }
.dirC .band .trust .item .tick { color: #6fd0d8; }
.dirC .devices {
  display: grid;
  grid-template-rows: 1fr 1fr;
  gap: 18px;
  height: 100%;
}
.dirC .devices .ph {
  border-color: rgba(255,255,255,.16);
  background:
    repeating-linear-gradient(135deg, rgba(255,255,255,.05) 0 11px, rgba(255,255,255,.09) 11px 22px),
    rgba(255,255,255,.05);
  min-height: 150px;
}
.dirC .devices .ph-label {
  background: rgba(16,61,82,.62);
  border-color: rgba(255,255,255,.2);
  color: rgba(255,255,255,.85);
}
.dirC .calc-section { padding: 56px; }
.dirC .calc-section .head { text-align: center; margin-bottom: 34px; }
.dirC .calc-section h2 { font-size: 34px; margin-bottom: 10px; }
.dirC .calc-section .head p { color: var(--ink-soft); font-size: 17px; }
.dirC .calc--C {
  max-width: 860px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1px 1.15fr;
  gap: 36px;
  background: #fff;
  border: 1px solid var(--hairline);
  border-radius: 18px;
  box-shadow: 0 1px 2px rgba(15,27,45,.04), 0 18px 44px rgba(15,27,45,.07);
  padding: 36px 40px;
}
.dirC .calc--C .calc-divider { background: var(--hairline); }
.dirC .calc--C .calc-readout { margin-top: 0; }
