/* Freedom Bath Inside Sales Portal. The quote site's look (booking-page/index.html, quote.freedombath.com): a gray header
   band with a dark rule, a light gray page, white boxes with thin rules and small corners, Arial, yellow pill buttons, navy
   for what's picked. One light theme, readable on a laptop or a phone. */
:root {
  --ink: #0F1111;
  --muted: #565959;
  --navy: #0B3A63;
  --blue: #007ECA;      /* logo flag blue */
  --link: #0B5CAD;
  --red: #B12704;
  --green: #0B7A3E;
  --amber: #8A5A00;
  --rule: #D5D9D9;
  --panel: #F0F2F2;     /* header band, notes */
  --headline: #A2A6A6;  /* dark line under the header */
  --page: #F7F7F7;
  --paper: #FFFFFF;
  --tint: #F7F8F8;
  --pick: #EDF3F8;
  --edge: #8D9096;
  --optline: #C4C8C8;
  --track: #D6DBDE;
  --button: #FFD814;
  --button-edge: #FCD200;
  --new-bg: #FCEDEA;
  --ok-bg: #EAF4EC;
  --wait-bg: #FFF8D6;
  --font: Arial, Helvetica, sans-serif;
  color-scheme: light;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--page); color: var(--ink); font-family: var(--font); font-size: 17px; line-height: 1.45;
  padding-bottom: env(safe-area-inset-bottom, 0px); display: flex; flex-direction: column; min-height: 100vh; }
[hidden] { display: none !important; }
button, input, select { font: inherit; color: inherit; }
a { color: var(--link); }
h1 { font-size: 22px; line-height: 1.3; margin: 4px 0 14px; }
h2 { font-size: 18px; line-height: 1.3; margin: 24px 0 10px; }
h3 { font-size: 17px; line-height: 1.3; margin: 22px 0 6px; }
h4 { font-size: 16px; margin: 16px 0 6px; }
p { margin: 0 0 12px; }
ul, ol { padding-left: 22px; margin: 0 0 14px; }
li { margin-bottom: 6px; }

/* header band (as the quote site) */
.top { position: sticky; top: 0; z-index: 5; background: var(--panel); border-bottom: 1px solid var(--headline); padding-top: env(safe-area-inset-top, 0px); }
.top-in { display: flex; align-items: center; gap: 8px; min-height: 64px; max-width: 1040px; margin: 0 auto;
  padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(12px, env(safe-area-inset-right, 0px)); }
.brand { display: flex; align-items: center; gap: 8px; text-decoration: none; }
.logo { height: 36px; width: auto; display: block; }
.spacer { flex: 1; }
nav { display: flex; align-items: center; gap: 4px; }
/* the menu: plain words with a navy line that slides in under the one you point at, and stays under the page you're on */
nav a, nav .link { position: relative; display: inline-flex; align-items: center; min-height: 44px; padding: 0 12px; border-radius: 6px; color: var(--muted); font-weight: 400;
  font-size: 15px; text-decoration: none; white-space: nowrap; transition: color .15s ease; }
nav a::after, nav .link::after { content: ""; position: absolute; left: 12px; right: 12px; bottom: 8px; height: 2px; border-radius: 2px; background: var(--navy);
  transform: scaleX(0); transform-origin: left center; transition: transform .22s cubic-bezier(.2, .8, .2, 1); }
nav a:hover, nav .link:hover { color: var(--ink); background: none; text-decoration: none; }
nav a:hover::after, nav .link:hover::after, nav a[aria-current="page"]::after { transform: scaleX(1); }
nav a[aria-current="page"] { color: var(--navy); }
nav .link { margin-left: 6px; }
@media (prefers-reduced-motion: reduce) { nav a, nav .link, nav a::after, nav .link::after { transition: none; } }

main { flex: 1; width: 100%; max-width: 760px; margin: 0 auto; padding: 16px max(16px, env(safe-area-inset-right, 0px)) 32px max(16px, env(safe-area-inset-left, 0px)); outline: none; }
main.wide { max-width: 1040px; }
.foot { background: var(--panel); border-top: 1px solid var(--rule); font-size: 13px; color: var(--muted); }
.foot-in { max-width: 1040px; margin: 0 auto; padding: 16px max(16px, env(safe-area-inset-right, 0px)) calc(16px + env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px)); }
.lb { display: block; width: 100%; height: 480px; border: 0; }
.locked-lb { max-width: 520px; margin: 24px auto 0; text-align: center; }
.center { text-align: center; }
.muted { color: var(--muted); }
.small { font-size: 14px; }
.eyebrow { font-size: 15px; color: var(--muted); margin-bottom: 4px; }
.back { display: inline-flex; align-items: center; gap: 4px; min-height: 44px; color: var(--link); font-size: 15px; text-decoration: none; margin: -8px 0 4px; }
.back:hover { text-decoration: underline; }

/* boxes (the quote site's .box) */
.card { background: var(--paper); border: 1px solid var(--rule); border-radius: 4px; padding: 20px; margin-bottom: 16px; }
.card > h2:first-child, .card-head h2 { margin-top: 0; }
.card-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 8px; }
.card-head h2 { margin-bottom: 4px; }
.card-head p { margin: 0; }
.stack { display: grid; gap: 14px; }
.hero { padding: 4px 0 16px; }
@media (max-width: 480px) { .card { padding: 16px; } }

/* sign-in */
.signin { max-width: 440px; margin: 16px auto 0; background: var(--paper); border: 1px solid var(--rule); border-radius: 4px; padding: 24px 20px; }
.signin .mark { width: 64px; height: 64px; display: block; margin: 0 auto 8px; }
.signin h1, .signin .sub { text-align: center; }
.sub { color: var(--muted); margin: 0 0 16px; }
.field { display: grid; gap: 6px; }
.field label { font-weight: 700; font-size: 16px; }
.field input { width: 100%; min-height: 50px; border: 1px solid var(--edge); border-radius: 8px; padding: 11px 12px; font-size: 17px; background: var(--paper);
  box-shadow: inset 0 1px 2px rgba(15, 17, 17, 0.12); }
.field input:focus { outline: none; border-color: var(--navy); box-shadow: 0 0 0 3px rgba(11, 58, 99, 0.25); }
.field input.code { letter-spacing: .4em; text-align: center; font-size: 24px; font-variant-numeric: tabular-nums; }
.err { color: var(--red); margin: 0; font-size: 15px; }
.err:empty { display: none; }

/* buttons: the main one is the quote site's yellow pill; the others white pills */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; border-radius: 999px; padding: 9px 20px; font-weight: 400; font-size: 16px;
  text-decoration: none; cursor: pointer; background: var(--paper); color: var(--ink); border: 1px solid var(--optline); box-shadow: 0 2px 5px rgba(213, 217, 217, 0.5); }
.btn:hover { background: var(--tint); }
.btn.primary { background: var(--button); border-color: var(--button-edge); color: var(--ink); }
.btn.primary:hover { background: #F7CA00; }
.btn:disabled { background: var(--panel); border-color: var(--rule); color: #8D9096; box-shadow: none; cursor: not-allowed; }
.btn.big { display: flex; width: 100%; min-height: 50px; font-size: 17px; }
.btn.small { min-height: 36px; padding: 6px 14px; font-size: 14px; }
.link { background: none; border: 0; padding: 2px 0; font: inherit; font-size: 15px; color: var(--link); cursor: pointer; }
.link:hover { text-decoration: underline; }
.actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin: 4px 0 16px; }
.btn:focus-visible, a:focus-visible, .opt:focus-within, .link:focus-visible, .tab:focus-visible, select:focus-visible, summary:focus-visible { outline: 3px solid var(--navy); outline-offset: 2px; }

.alert { padding: 12px 16px; border-radius: 8px; background: var(--wait-bg); color: var(--amber); border: 1px solid #F0DE8C; margin: 12px 0; }
.alert.bad { background: var(--new-bg); color: var(--red); border-color: #E8B4AA; }
.alert.good { background: var(--ok-bg); color: var(--green); border-color: #9ED3B4; }

.progress { height: 10px; background: var(--track); border-radius: 99px; overflow: hidden; margin: 16px 0 6px; }
.progress span { display: block; height: 100%; background: var(--navy); border-radius: 99px; transition: width .3s; }

/* Module 1: one box per section, like the quote site's choices */
.sections { list-style: none; padding: 0; margin: 8px 0 14px; }
.sec { margin: 0 0 10px; }
.sec .row { display: flex; align-items: center; gap: 14px; padding: 13px 14px; min-height: 56px; background: var(--paper); border: 1px solid var(--optline); border-radius: 6px; color: inherit; text-decoration: none; }
.sec a.row:hover { background: var(--tint); }
.sec.open .row { border-color: var(--navy); background: var(--pick); }
.sec.locked .row { background: var(--tint); color: #8D9096; border-color: #E3E6E6; }
.num { flex: none; display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; border: 1.5px solid var(--edge); background: var(--paper); color: var(--muted); font-weight: 700; font-size: 14px; }
.sec.open .num { background: var(--navy); border-color: var(--navy); color: #fff; }
.sec.passed .num { background: var(--green); border-color: var(--green); color: #fff; }
.body { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.title { font-weight: 700; font-size: 16px; }
.body .sub { font-size: 14px; margin: 0; }

/* chips */
.badge { flex: none; display: inline-flex; align-items: center; font-size: 13px; padding: 2px 10px; border-radius: 999px; white-space: nowrap; margin-right: 4px;
  background: var(--panel); color: var(--muted); border: 1px solid var(--rule); }
.badge.ok { background: var(--ok-bg); color: var(--green); border-color: #9ED3B4; }
.badge.go { background: var(--pick); color: var(--navy); border-color: #B9CDE0; }
.badge.wait { background: var(--wait-bg); color: var(--amber); border-color: #F0DE8C; }
.badge.bad { background: var(--new-bg); color: var(--red); border-color: #E8B4AA; }

/* lessons */
.lesson h1 { margin-bottom: 14px; }
.say { margin: 12px 0 16px; padding: 14px 16px 14px 18px; border-left: 4px solid var(--navy); background: var(--pick); border-radius: 0 8px 8px 0; font-style: italic; }
.note { margin: 12px 0 16px; padding: 14px 16px; border-radius: 8px; background: var(--panel); }
.note.tip { background: var(--ok-bg); }
.note.warn { background: var(--new-bg); }
.tag { display: inline-block; font-style: normal; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; margin-right: 8px; color: var(--muted); }
.say .tag { color: var(--navy); }
.note.warn .tag { color: var(--red); }
.note.tip .tag { color: var(--green); }
.qa { border: 1px solid var(--rule); border-radius: 6px; margin: 10px 0; overflow: hidden; }
.qa .q { padding: 10px 14px; background: var(--panel); font-weight: 700; }
.qa .a { padding: 10px 14px; }
.steps li { margin-bottom: 10px; }
.table-wrap { overflow-x: auto; margin: 10px 0 12px; }
table { border-collapse: collapse; width: 100%; font-size: 15px; }
th, td { text-align: left; vertical-align: top; padding: 9px 10px; border-bottom: 1px solid var(--rule); }
th { background: var(--panel); font-weight: 700; font-size: 13px; color: var(--muted); }

.examples { margin-top: 18px; }
.example { display: flex; gap: 14px; justify-content: space-between; align-items: center; flex-wrap: wrap; padding: 14px 0; border-top: 1px solid var(--rule); }
.example p { margin: 4px 0 0; }
audio { width: 280px; max-width: 100%; }

/* pictures in lessons */
.shot { margin: 14px 0 18px; }
.shot img { display: block; width: auto; max-width: 100%; height: auto; max-height: 560px; margin: 0 auto; object-fit: contain; background: var(--tint); border: 1px solid var(--rule); border-radius: 4px; }
.shot figcaption { color: var(--muted); font-size: 15px; margin-top: 6px; }
.qa .listen { padding-top: 0; }
.qa .listen .btn { min-height: 36px; font-size: 15px; padding: 6px 14px; }

/* quizzes: the quote site's choices */
.quiz fieldset { border: 0; border-top: 1px solid var(--rule); padding: 18px 0 8px; margin: 0; }
.quiz legend { font-weight: 700; padding: 0; margin-bottom: 10px; }
.qn { color: var(--navy); margin-right: 4px; }
.opt { display: flex; gap: 12px; align-items: flex-start; font-weight: 400; padding: 13px 14px; border: 1px solid var(--optline); border-radius: 6px; margin: 0 0 8px; cursor: pointer; background: var(--paper); }
.opt:hover { background: var(--tint); }
.opt input { margin-top: 4px; flex: none; accent-color: var(--navy); width: 18px; height: 18px; }
.opt:has(input:checked) { border-color: var(--navy); background: var(--pick); }

.result { text-align: center; }
.result.pass { border-top: 4px solid var(--green); }
.result.fail { border-top: 4px solid var(--amber); }
.result .actions { justify-content: center; }
.score { font-size: 48px; font-weight: 700; margin: 6px 0 0; line-height: 1.1; }
.result.pass .score { color: var(--green); }
.result.fail .score { color: var(--amber); }
.review { padding-left: 22px; }
.review li { background: var(--paper); border: 1px solid var(--rule); border-radius: 4px; padding: 12px 16px; margin-bottom: 10px; }
.review li.right { border-left: 4px solid var(--green); }
.review li.wrong { border-left: 4px solid var(--red); }
.review .q { font-weight: 700; }
.review .yours { color: var(--red); }
.review .why { color: var(--muted); font-size: 15px; margin: 0; }

/* resources */
.cards { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px; }
.link-card { display: flex; flex-direction: column; gap: 4px; text-decoration: none; color: var(--ink); height: 100%; margin: 0; }
.link-card b { color: var(--ink); }
.link-card:hover { background: var(--tint); }

@media (max-width: 560px) {
  .top-in { flex-wrap: wrap; row-gap: 0; padding-top: 8px; min-height: 0; }
  nav { width: 100%; margin: 0 0 4px -10px; overflow-x: auto; }
  body { font-size: 16px; }
  h1 { font-size: 20px; }
  .logo { height: 30px; }
  nav a, nav .link { padding: 0 8px; font-size: 14px; }
  .sec .row { gap: 10px; padding: 12px; }
  .badge { font-size: 12px; padding: 2px 8px; }
  .actions .btn { width: 100%; }
}

/* Performance: goals (Today, This pay period and This month as tabs; the picked one's row of meters below) */
#goals-card .card-head { align-items: center; }
.btn.sqr { border-radius: 4px; }
/* bookmark tabs: a row of tabs on a line; the picked one is open onto the gauges below it */
.btabs { display: flex; align-items: flex-end; gap: 4px; margin: 4px 0 12px; padding: 0 4px; border-bottom: 1px solid var(--rule); }
.btab { position: relative; bottom: -1px; border: 1px solid var(--rule); border-radius: 6px 6px 0 0; background: var(--panel); color: var(--muted);
  padding: 8px 18px; font: inherit; font-size: 15px; white-space: nowrap; cursor: pointer; }
.btab:hover { background: var(--tint); color: var(--ink); }
.btab.on { background: var(--paper); color: var(--ink); font-weight: 700; border-bottom-color: var(--paper); cursor: default; }
.btab:focus-visible { outline: 3px solid var(--navy); outline-offset: 2px; z-index: 1; }
.frame-sub { margin: 0 0 10px; }
.gauges { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 10px; }
@media (max-width: 760px) { .gauges { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.gauge { text-align: center; border: 1px solid var(--rule); border-radius: 6px; padding: 10px 8px 12px; background: var(--paper); }
.gauge svg { display: block; width: 100%; max-width: 170px; margin: 4px auto 0; }
.gauge path { fill: none; stroke-width: 14; }
.z-red { stroke: #E05252; } .z-yellow { stroke: #F2C94C; } .z-green { stroke: #34A464; }
.needle { stroke: var(--ink); stroke-width: 3; stroke-linecap: round; } .hub { fill: var(--ink); }
.goal-tick { stroke: var(--ink); stroke-width: 1.5; stroke-dasharray: 2 2; opacity: .55; }
.g-scale { display: flex; justify-content: space-between; max-width: 170px; margin: -2px auto 2px; padding: 0 2px; font-size: 11px; color: var(--muted); font-variant-numeric: tabular-nums; }
.g-label { font-weight: 700; font-size: 15px; }
.g-num { font-size: 24px; font-weight: 700; font-variant-numeric: tabular-nums; line-height: 1.1; }
.gauge.red .g-num { color: var(--red); } .gauge.yellow .g-num { color: var(--amber); } .gauge.green .g-num { color: var(--green); }
.g-goal { font-size: 13px; color: var(--muted); }

/* Performance: pay (Overview, then Hourly and Commission as dropdowns). The head: the title with the dates shown next to
   it, then the status and the square arrows to page through the pay periods or months; under it the two bookmark tabs. */
.pay-head { align-items: center; margin-bottom: 8px; }
#pay .btabs { margin-bottom: 0; }
.ph-title { display: flex; align-items: baseline; gap: 4px 12px; flex-wrap: wrap; }
.ph-title h2 { margin: 0; }
.ph-side { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.back-week { margin: 10px 0 0; text-align: center; }
.sq { flex: none; width: 40px; height: 40px; display: grid; place-items: center; border: 1px solid var(--optline); border-radius: 4px; background: var(--paper); color: var(--ink);
  font-size: 22px; line-height: 1; cursor: pointer; padding: 0 0 3px; box-shadow: 0 2px 5px rgba(213, 217, 217, 0.5); }
.sq:hover { background: var(--tint); border-color: var(--edge); }
.sq:disabled { background: var(--panel); border-color: var(--rule); color: #B4B8B8; box-shadow: none; cursor: default; }
.sq:focus-visible { outline: 3px solid var(--navy); outline-offset: 2px; }
#pay.loading { opacity: .6; pointer-events: none; }
.pay-part { padding: 14px 0 4px; border-bottom: 1px solid var(--rule); }
details.pay-part:last-of-type { border-bottom: 0; }
.pay-part h3 { margin: 0 0 8px; }
.drop { padding: 0; }
.drop > summary { list-style: none; cursor: pointer; display: flex; align-items: baseline; gap: 6px 14px; flex-wrap: wrap; padding: 14px 34px 14px 0; position: relative; }
.drop > summary::-webkit-details-marker { display: none; }
.drop > summary:hover .d-title { color: var(--navy); }
.d-title { font-size: 17px; font-weight: 700; min-width: 108px; }
.d-sum { font-size: 16px; font-variant-numeric: tabular-nums; margin-left: auto; text-align: right; }
.chev { position: absolute; right: 4px; top: 16px; width: 20px; height: 20px; color: var(--muted); transition: transform .18s ease; }
.drop[open] > summary .chev { transform: rotate(180deg); }
.d-body { padding: 0 0 8px; }
.d-body h4:first-child { margin-top: 4px; }
@media (prefers-reduced-motion: reduce) { .chev { transition: none; } }
.ov-total { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.ov-total .big { font-size: 28px; font-weight: 700; font-variant-numeric: tabular-nums; }
.paybar { display: flex; height: 30px; border-radius: 6px; overflow: hidden; background: var(--track); }
.paybar .seg { display: flex; align-items: center; justify-content: center; color: #fff; font-size: 13px; font-weight: 700; min-width: 2px; }
.paybar .seg.none { flex: 1; background: var(--track); }
.seg.hourly, .sw.hourly { background: var(--navy); }
.seg.commission, .sw.commission { background: var(--blue); }
.seg.bonus, .sw.bonus { background: #B7791F; }
.seg.other, .sw.other { background: #6B7A85; }
.legend { list-style: none; padding: 0; margin: 10px 0 8px; display: grid; gap: 6px; max-width: 440px; font-size: 15px; }
.legend li { display: grid; grid-template-columns: 14px 1fr auto 52px; gap: 10px; align-items: center; margin: 0; }
.lg-name { display: inline-flex; align-items: center; gap: 6px; }
.sw { width: 14px; height: 14px; border-radius: 3px; display: inline-block; }
.lg-val { font-variant-numeric: tabular-nums; text-align: right; } .lg-pct { text-align: right; font-weight: 700; font-variant-numeric: tabular-nums; }
/* the i in a circle next to Volume Bonus, and the window it opens */
.i-btn { display: inline-grid; place-items: center; width: 28px; height: 28px; margin: -4px 0; padding: 0; border: 0; border-radius: 50%; background: none; color: var(--link); cursor: pointer; }
.i-btn:hover { background: var(--pick); } .i-btn:focus-visible { outline: 3px solid var(--navy); outline-offset: 1px; }
.i-icon { width: 18px; height: 18px; display: block; }
.modal { width: min(420px, calc(100vw - 32px)); border: 1px solid var(--rule); border-radius: 8px; padding: 20px; color: var(--ink); background: var(--paper); box-shadow: 0 12px 40px rgba(15, 17, 17, 0.25); }
.modal::backdrop { background: rgba(15, 17, 17, 0.45); }
.modal h3 { margin: 0 0 10px; } .modal .actions { justify-content: flex-end; margin: 14px 0 0; }
.crown { width: 18px; height: 18px; color: #B7791F; vertical-align: -3px; }
.won { display: flex; align-items: center; gap: 8px; margin: 4px 0 8px; font-size: 15px; font-weight: 700; color: var(--amber); }
ul.plain { list-style: none; padding: 0; margin: 0 0 12px; }
ul.plain li { display: flex; justify-content: space-between; gap: 12px; padding: 6px 0; border-bottom: 1px solid var(--rule); margin: 0; font-size: 15px; }
table.sales td, table.sales th { white-space: nowrap; }
table.sales td:first-child { white-space: normal; min-width: 140px; }
.amt { text-align: right; font-variant-numeric: tabular-nums; }
th.amt { text-align: right; }
/* Yes / Sale, No / No Sale, Upcoming: a green, red or gray circle with the word */
.res { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; }
.res svg { width: 18px; height: 18px; flex: none; }
.res.sale { color: var(--green); } .res.sale circle { fill: #0B7A3E; }
.res.nosale { color: var(--red); } .res.nosale circle { fill: #C62F12; }
.res.upcoming { color: var(--muted); } .res.upcoming circle { fill: #8D9096; }
.paid-on { display: block; font-weight: 400; font-size: 12px; line-height: 1.3; color: var(--muted); }
/* nine columns: the headings wrap so the table fits the box; the last three (the commission) are shaded */
table.appts .cm { background: var(--tint); } table.appts th.cm { background: #E3E7E7; }
.res[role="img"] { gap: 0; } .res[role="img"] svg { width: 20px; height: 20px; }
table.appts th { white-space: normal; vertical-align: bottom; }
table.appts th, table.appts td { padding-left: 8px; padding-right: 8px; }
table.appts td:first-child { min-width: 120px; }
/* the total under a table as a gold row, like first place on the leaderboard: this pay period's commission, and the
   billable hours (in the same columns as the rows above it) */
table.appts, table.states { border-collapse: separate; border-spacing: 0; }
table.appts tfoot::before { content: ""; display: table-row; height: 10px; }
table.appts tfoot td { font-weight: 700; border-bottom: 0; }
table tfoot tr.gold td { background: var(--wait-bg); border-top: 1px solid #F0DE8C; border-bottom: 1px solid #F0DE8C; padding-top: 10px; padding-bottom: 10px; }
table tfoot tr.gold td:first-child { border-left: 1px solid #F0DE8C; border-radius: 6px 0 0 6px; color: var(--amber); }
table tfoot tr.gold td:last-child { border-right: 1px solid #F0DE8C; border-radius: 0 6px 6px 0; }
table tfoot tr.gap td { height: 8px; padding: 0; border: 0; }
/* time by agent state */
table.states td, table.states th { white-space: nowrap; }
table.states tfoot td { font-weight: 700; border-bottom: 0; }
.sharebar { display: inline-block; width: 72px; height: 8px; margin-right: 8px; border-radius: 99px; background: var(--track); overflow: hidden; vertical-align: 1px; }
.sharebar span { display: block; height: 100%; border-radius: 99px; } .sharebar .yes { background: var(--navy); } .sharebar .no { background: #9AA3A8; }

/* Statistics and Leads: a page in bookmark tabs (the tabs, then one white panel the picked tab opens onto) */
.tabs { display: flex; flex-wrap: wrap; gap: 8px; margin: 6px 0 14px; }
.tab { border: 1px solid var(--optline); background: var(--paper); color: var(--ink); border-radius: 999px; padding: 7px 16px; font: inherit; font-size: 15px; cursor: pointer; }
.tab:hover { background: var(--tint); }
.tab.on { border-color: var(--navy); background: var(--pick); color: var(--navy); font-weight: 700; }
.btabs.page { margin: 6px 0 0; padding: 0 8px; }
.tab-panel { background: var(--paper); border: 1px solid var(--rule); border-top: 0; border-radius: 0 0 4px 4px; padding: 20px; margin-bottom: 16px; }
.tab-panel > section + section { border-top: 1px solid var(--rule); margin-top: 22px; padding-top: 20px; }
.tab-panel h2 { margin: 0 0 4px; }
.panel-top { display: flex; justify-content: flex-end; margin-bottom: 14px; }
.sec-head { display: flex; align-items: center; justify-content: space-between; gap: 10px 16px; flex-wrap: wrap; margin-bottom: 12px; }
.sec-head p { margin: 0; }
.sec-tools { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.pick { display: flex; align-items: center; gap: 8px; font-size: 15px; font-weight: 700; }
.pick select { font-size: 15px; font-weight: 400; border: 1px solid var(--optline); border-radius: 4px; padding: 7px 10px; background: var(--paper); min-height: 40px; }
/* a choice of one: 30 or 90 days, T1 to T12 */
.opts { display: inline-flex; border: 1px solid var(--optline); border-radius: 4px; overflow: hidden; background: var(--paper); }
.optb { border: 0; border-left: 1px solid var(--optline); background: var(--paper); color: var(--ink); font: inherit; font-size: 14px; padding: 6px 13px; min-height: 36px; cursor: pointer; white-space: nowrap; }
.optb:first-child { border-left: 0; }
.optb:hover { background: var(--tint); }
.optb.on { background: var(--navy); color: #fff; font-weight: 700; cursor: default; }
.optb:focus-visible { outline: 3px solid var(--navy); outline-offset: -3px; }
.optb.on:focus-visible { outline-color: #fff; }
/* dark charts: a line per day with its 90-day and 360-day moving averages */
.charts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin: 4px 0 12px; }
.charts.four { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin: 0; }
.chart { position: relative; min-width: 0; background: #14181C; border: 1px solid #0B0E11; border-radius: 6px; padding: 12px 12px 10px; color: #F2F5F7; text-align: left; white-space: normal; font-weight: 400; font-variant-numeric: tabular-nums; }
.ch-title { font-size: 12px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; color: #9AA5AF; }
.ch-main { display: flex; align-items: baseline; flex-wrap: wrap; gap: 2px 8px; }
.ch-now { font-size: 30px; font-weight: 700; line-height: 1.2; }
.ch-when { font-size: 13px; color: #9AA5AF; }
.ch-d { font-size: 13px; font-weight: 700; white-space: nowrap; } .ch-d.up { color: #4ADE80; } .ch-d.down { color: #FF8078; } .ch-d.flat { color: #9AA5AF; }
.ch-week { font-size: 13px; color: #C3CBD3; margin: 0 0 8px; }
.ch-week b { color: #F2F5F7; }
.chart svg { display: block; width: 100%; height: auto; overflow: visible; touch-action: pan-y; cursor: crosshair; }
.chart svg text { font-family: var(--font); font-size: 11px; fill: #9AA5AF; }
.chart svg text.ch-tag { fill: #0B0E11; font-weight: 700; }
.ch-legend { display: flex; flex-wrap: wrap; gap: 2px 14px; margin-top: 6px; font-size: 12px; color: #C3CBD3; }
.ch-legend b { color: #F2F5F7; }
.ch-legend i { display: inline-block; width: 18px; height: 0; margin-right: 6px; vertical-align: middle; }
.ch-tip { position: absolute; display: grid; gap: 1px; background: #0B0E11; border: 1px solid #323A42; border-radius: 4px; padding: 6px 9px; font-size: 12px; line-height: 1.45; color: #C3CBD3; pointer-events: none; }
.ch-tip[hidden] { display: none; }
.ch-tip b { color: #F2F5F7; }
.chart.small { padding: 10px 10px 8px; }
.chart.small .ch-now { font-size: 22px; }
.chart.small .ch-when, .chart.small .ch-d, .chart.small .ch-week { font-size: 12px; }
.chart.small .ch-legend { font-size: 11px; gap: 1px 10px; }
.chart.small .ch-d { display: block; flex-basis: 100%; }
@media (max-width: 760px) { .charts { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 980px) { .charts.four { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .charts.four { grid-template-columns: minmax(0, 1fr); } }
/* the by-campaign and lead-source tables */
.rank-table td, .rank-table th { white-space: nowrap; } .rank-table td:nth-child(2) { white-space: normal; min-width: 180px; }
table.camp-table { border-collapse: separate; border-spacing: 0; }
table.camp-table th, table.camp-table td { white-space: nowrap; vertical-align: middle; padding: 9px 8px; }
table.camp-table th { white-space: normal; vertical-align: bottom; line-height: 1.25; }
table.camp-table td:first-child { white-space: normal; min-width: 150px; }
table.camp-table td:first-child { font-weight: 700; }
table.camp-table tfoot td { background: var(--tint); font-weight: 700; border-top: 1px solid var(--rule); }
tr.crow { cursor: pointer; }
tr.crow:hover td { background: var(--tint); }
tr.crow.on td { background: var(--pick); border-bottom-color: var(--pick); }
tr.crow:focus-visible { outline: 3px solid var(--navy); outline-offset: -3px; }
.tw { display: inline-block; width: 18px; color: var(--muted); }
tr.cdetail > td { background: var(--pick); padding: 2px 10px 12px; }
/* on a narrow screen the table scrolls sideways: the open campaign's charts stay the width of the screen */
tr.cdetail .charts { position: sticky; left: 10px; width: min(100%, calc(100vw - 78px)); }
table.lead-table tr.none td { color: #8D9096; font-weight: 400; }
/* Reports: the list of reports (a card each: name, what it is, Open report) */
.rep-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; margin: 8px 0 20px; }
a.rep-card { display: flex; flex-direction: column; gap: 6px; background: var(--paper); border: 1px solid var(--rule); border-radius: 4px; padding: 18px 20px; color: var(--ink); text-decoration: none; }
a.rep-card:hover { border-color: var(--navy); box-shadow: 0 2px 8px rgba(15, 17, 17, 0.08); }
a.rep-card:focus-visible { outline: 3px solid var(--navy); outline-offset: 2px; }
.rep-name { font-size: 18px; font-weight: 700; color: var(--navy); }
.rep-text { font-size: 15px; line-height: 1.45; color: var(--muted); }
.rep-open { margin-top: 6px; font-size: 14px; font-weight: 700; color: var(--navy); }
/* Reports: a panel on its own, the date range, and a count with its share underneath */
.tab-panel.solo { border-top: 1px solid var(--rule); border-radius: 4px; }
.rep-range { display: flex; align-items: center; flex-wrap: wrap; gap: 10px 16px; margin: 0 0 14px; }
.rep-range input[type="date"] { font: inherit; font-size: 15px; font-weight: 400; border: 1px solid var(--optline); border-radius: 4px; padding: 6px 10px; min-height: 36px; background: var(--paper); color: var(--ink); }
.rep-range input[type="date"]:focus-visible { outline: 3px solid var(--navy); outline-offset: 1px; }
.sub { display: block; font-size: 12px; line-height: 1.3; color: var(--muted); font-weight: 400; }
table.rep-table tfoot .sub { color: var(--ink); }
.info { display: inline-grid; place-items: center; width: 18px; height: 18px; margin-left: 2px; padding: 0; border: 1px solid var(--edge); border-radius: 50%; background: var(--paper); color: var(--muted);
  font: italic 700 12px/1 Georgia, 'Times New Roman', serif; cursor: pointer; vertical-align: 1px; position: relative; }
.info::after { content: ""; position: absolute; inset: -8px; }
.info:hover { border-color: var(--navy); color: var(--navy); }
.info:focus-visible { outline: 3px solid var(--navy); outline-offset: 2px; }
.tip { position: fixed; z-index: 20; width: max-content; max-width: min(340px, calc(100vw - 16px)); background: var(--ink); color: #fff; font-size: 13px; line-height: 1.45; padding: 10px 12px; border-radius: 6px; box-shadow: 0 8px 28px rgba(15, 17, 17, 0.3); }

@media (max-width: 560px) {
  .ph-side { margin-left: 0; }
  .btabs { padding: 0; gap: 3px; } .btab { padding: 8px 10px; font-size: 14px; }
  .d-title { min-width: 0; flex-basis: 100%; } .d-sum { font-size: 15px; margin-left: 0; text-align: left; }
  .sharebar { display: none; }
  /* the sales as stacked rows on a phone */
  table.sales thead { display: none; }
  table.sales, table.sales tbody, table.sales tr, table.sales td { display: block; width: 100%; }
  table.sales tr { padding: 10px 0; border-bottom: 1px solid var(--rule); }
  table.sales td, table.sales td.amt { border: 0; padding: 2px 0; white-space: normal; text-align: left; }
  table.sales td:first-child { font-weight: 700; }
  table.sales td[data-l]::before { content: attr(data-l) ": "; color: var(--muted); }
  table.sales td:empty { display: none; }
  .paid-on { display: inline; margin-left: 6px; }
  /* the two totals under the appointments: the words on the left, the amount on the right */
  table.appts tfoot { display: block; } table.appts tfoot::before { display: block; }
  table.appts tfoot tr { display: flex; justify-content: space-between; gap: 12px; padding: 8px 12px; border-bottom: 0; }
  table.appts tfoot td { width: auto; }
  table.appts td.cm { background: none; }
  table.appts tfoot tr.gold { background: var(--wait-bg); border: 1px solid #F0DE8C; border-radius: 6px; }
  table.appts tfoot tr.gold td, table.appts tfoot tr.gold td:first-child, table.appts tfoot tr.gold td:last-child { background: none; border: 0; border-radius: 0; padding: 0; }
  .tab-panel { padding: 16px 12px; } .btabs.page { padding: 0 4px; }
  .sec-tools { width: 100%; }
}
