/* Employer dashboard: the admin shell (shell.css) and business components
   (business.css), plus the few pieces only employers see. */

/* Rail: company chip under the brand */
.em-co {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 4px 12px 10px;
  padding: 10px;
  border-radius: 14px;
  background: var(--rail-tile);
  min-width: 0;
}
.em-co .co-logo {
  flex: none;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  color: #fff;
  font-family: var(--display);
  font-weight: 800;
  font-size: 13px;
}
.em-co b {
  display: block;
  font-size: 13.5px;
  color: var(--rail-hi);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.em-co span span {
  font-size: 12px;
  color: var(--rail-ink);
}
html[data-rail="mini"] .em-co {
  justify-content: center;
  padding: 6px;
  margin: 4px 8px 10px;
}
html[data-rail="mini"] .em-co > span:last-child {
  display: none;
}
.nav a .pill {
  margin-left: auto;
  font-size: 10.5px;
  padding: 1px 7px;
}
html[data-rail="mini"] .nav a .pill {
  display: none;
}

/* Linked stat cards */
a.stat {
  color: inherit;
  text-decoration: none;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
a.stat:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(14, 26, 44, 0.06), 0 10px 24px rgba(14, 26, 44, 0.08);
}

/* Programme cards (gradient, like the business site) */
.em-prog {
  position: relative;
  overflow: hidden;
  border-radius: 18px;
  padding: 22px;
  color: #fff;
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-height: 210px;
  box-shadow: var(--shadow);
}
.em-prog.info {
  background: linear-gradient(135deg, #0b5f8a 0%, #1690cf 100%);
}
.em-prog.life {
  background: linear-gradient(135deg, #a3121d 0%, #e3303b 100%);
}
.em-prog::after {
  content: "";
  position: absolute;
  right: -60px;
  top: -60px;
  width: 200px;
  height: 200px;
  border-radius: 50%;
  border: 28px solid rgba(255, 255, 255, 0.09);
  pointer-events: none;
}
.em-prog .eyebrow {
  color: rgba(255, 255, 255, 0.85);
}
.em-prog .big {
  font-family: var(--display);
  font-size: 38px;
  font-weight: 800;
  line-height: 1.05;
}
.em-prog .sm {
  font-size: 13.5px;
  opacity: 0.9;
}
.em-prog .row3 {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 18px;
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.22);
  font-size: 13px;
}
.em-prog .row3 b {
  font-weight: 700;
}
.em-prog .acts {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  position: relative;
  z-index: 1;
}
.btn-white {
  background: #fff;
  color: #0e1a2c;
  border-color: #fff;
}
.btn-white:hover {
  background: #f1f4f8;
}
.btn-glass {
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  border-color: rgba(255, 255, 255, 0.35);
}
.btn-glass:hover {
  background: rgba(255, 255, 255, 0.22);
}
.em-off {
  display: flex;
  flex-direction: column;
  gap: 10px;
  justify-content: center;
  padding: 22px;
  min-height: 210px;
}

/* Employee cell */
.em-who {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.em-who b {
  display: block;
  white-space: nowrap;
}
.em-who small {
  color: var(--muted);
  font-size: 12px;
}
.em-bal {
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-width: 140px;
}
.em-bal .bz-meter i {
  background: var(--red);
}
.em-bal small {
  font-size: 12px;
  color: var(--muted);
}
.em-bal small b {
  color: var(--ink);
}
#main tbody tr[data-emp],
#main tbody tr[data-inv] {
  cursor: pointer;
}
#main tbody tr[data-emp]:hover td,
#main tbody tr[data-inv]:hover td {
  background: var(--surface-2);
}
.em-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}
.em-filters select {
  min-height: 36px;
  border: 1.5px solid var(--line);
  border-radius: 10px;
  padding: 0 30px 0 10px;
  background-color: var(--surface);
  color: var(--ink);
  font: inherit;
  font-size: 13.5px;
}
.em-private {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12.5px;
  color: var(--muted);
}

/* Banner */
.em-banner {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 14px 16px;
  border-radius: 14px;
  background: var(--sky-soft);
  color: var(--ink);
  font-size: 14px;
}
.em-banner.warn {
  background: var(--warn-soft);
}
.em-banner.red {
  background: var(--red-soft);
}
.em-banner svg {
  flex: none;
  margin-top: 1px;
  color: var(--sky);
}
.em-banner.warn svg {
  color: var(--warn);
}
.em-banner.red svg {
  color: var(--red);
}
.em-banner b {
  display: block;
}

/* Option buttons, chips, swatches */
.em-opt {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  text-align: left;
  padding: 13px 14px;
  border: 1.5px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  color: var(--ink);
  font: inherit;
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease;
}
.em-opt:hover {
  border-color: color-mix(in srgb, var(--sky) 45%, var(--line));
}
.em-opt.sel {
  border-color: var(--sky);
  background: color-mix(in srgb, var(--sky-soft) 60%, var(--surface));
}
.em-opt .oi {
  flex: none;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: var(--surface-2);
  color: var(--muted);
}
.em-opt.sel .oi {
  background: var(--sky);
  color: #fff;
}
.em-opt b {
  display: block;
  font-size: 14.5px;
}
.em-opt .d {
  display: block;
  font-size: 12.5px;
  color: var(--muted);
  margin-top: 2px;
}
.em-opt .end {
  margin-left: auto;
  text-align: right;
  flex: none;
}
.em-opts {
  display: grid;
  gap: 8px;
}
.em-chips {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.em-chip {
  min-height: 36px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1.5px solid var(--line);
  background: var(--surface);
  color: var(--ink);
  font: inherit;
  font-weight: 600;
  font-size: 13.5px;
  cursor: pointer;
}
.em-chip.sel {
  border-color: var(--ink);
  background: var(--ink);
  color: var(--surface);
}
.em-chip:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}
.em-swatches {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.em-swatches button {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 3px solid var(--surface);
  box-shadow: 0 0 0 1.5px var(--line);
  cursor: pointer;
}
.em-swatches button.sel {
  box-shadow: 0 0 0 2.5px var(--ink);
}

/* Code + message boxes */
.em-code {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  border-radius: 14px;
  background: var(--surface-2);
  font-family: var(--display);
  font-size: 26px;
  font-weight: 800;
  letter-spacing: 0.06em;
}
.em-msg {
  white-space: pre-wrap;
  font-size: 13.5px;
  padding: 14px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--surface);
  max-height: 220px;
  overflow: auto;
}
.em-ok {
  width: 58px;
  height: 58px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  margin: 0 auto;
  background: var(--good-soft);
  color: var(--good);
}

/* Phone preview */
.em-phone {
  width: min(290px, 100%);
  margin: 0 auto;
  border-radius: 34px;
  padding: 10px;
  background: #0e1a2c;
  box-shadow: 0 18px 40px rgba(14, 26, 44, 0.25);
}
.em-phone .scr {
  border-radius: 26px;
  overflow: hidden;
  background: #f3f5f9;
  color: #0e1a2c;
  min-height: 460px;
}
.em-phone .pb {
  padding: 22px 18px 20px;
  color: #fff;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.em-phone .pb .t {
  font-family: var(--display);
  font-size: 24px;
  font-weight: 800;
}
.em-phone .pl {
  display: flex;
  gap: 8px;
  align-items: center;
  font-size: 12px;
  font-weight: 700;
  opacity: 0.92;
}
.em-phone .pl i {
  width: 26px;
  height: 26px;
  border-radius: 8px;
  background: #fff;
  display: grid;
  place-items: center;
  font-style: normal;
  font-size: 11px;
}
.em-phone .pc {
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.em-phone .pcard {
  background: #fff;
  border-radius: 16px;
  padding: 12px 14px;
  font-size: 12.5px;
  color: #5a6880;
  box-shadow: 0 1px 2px rgba(14, 26, 44, 0.06);
}
.em-phone .pcard b {
  display: block;
  color: #0e1a2c;
  font-size: 13px;
  margin-bottom: 2px;
}
.em-phone .split {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

/* Invoice document */
.em-invoice {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  background: var(--surface);
}
.em-invoice .ih {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.em-invoice .ih > div:last-child {
  text-align: right;
}

/* Sign-in / sign-up */
.em-auth .card {
  width: min(420px, 100%);
}
.em-auth .links {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 13.5px;
}
.em-auth .links a,
.em-link {
  color: var(--sky);
  font-weight: 600;
  text-decoration: none;
  background: none;
  border: 0;
  padding: 0;
  font: inherit;
  cursor: pointer;
}
.em-auth .links a:hover,
.em-link:hover {
  text-decoration: underline;
}
.em-err {
  margin: 0;
  color: var(--red);
  font-size: 13.5px;
  font-weight: 600;
}
.em-su {
  width: min(980px, 100%);
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.3fr);
  border-radius: 22px;
  overflow: hidden;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.25);
  background: var(--surface);
}
.em-su-art {
  position: relative;
  overflow: hidden;
  padding: 32px;
  background: #0e1a2c;
  color: #fff;
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.em-su-art::after {
  content: "";
  position: absolute;
  right: -90px;
  bottom: -90px;
  width: 280px;
  height: 280px;
  border-radius: 50%;
  border: 40px solid rgba(227, 48, 59, 0.22);
}
.em-su-art h1 {
  font-family: var(--display);
  font-size: 30px;
  line-height: 1.1;
  margin: 0;
}
.em-su-art .wm {
  color: #fff;
}
.em-steps {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 6px;
  position: relative;
  z-index: 1;
}
.em-steps div {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  opacity: 0.55;
}
.em-steps div.on,
.em-steps div.done {
  opacity: 1;
}
.em-steps .d {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  border: 1.5px solid rgba(255, 255, 255, 0.4);
  font-size: 13px;
}
.em-steps .on .d {
  background: var(--red);
  border-color: var(--red);
}
.em-steps .done .d {
  background: #fff;
  color: #0e1a2c;
  border-color: #fff;
}
.em-su-form {
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.em-su-form .form {
  gap: 14px;
}
.em-su-nav {
  display: flex;
  gap: 10px;
  margin-top: auto;
}
.em-su-nav .btn-primary {
  flex: 1;
}

/* Dialog extras */
#dlg dialog {
  max-width: min(600px, 94vw);
  width: 100%;
}
#dlg dialog.narrow {
  max-width: min(480px, 94vw);
}
#dlg dialog.wide {
  max-width: min(760px, 94vw);
}
.em-sum {
  display: grid;
  gap: 6px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 12px;
  font-size: 14px;
}
.em-sum div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}
.em-sum div span {
  color: var(--muted);
}
.em-sum .tot {
  border-top: 1px solid var(--line);
  padding-top: 8px;
  margin-top: 2px;
  font-weight: 800;
  font-size: 16px;
}
.em-sum .tot span {
  color: var(--ink);
}
.em-steps-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 10px;
  counter-reset: s;
  font-size: 14px;
}
.em-steps-list li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  counter-increment: s;
}
.em-steps-list li::before {
  content: counter(s);
  flex: none;
  width: 22px;
  height: 22px;
  border-radius: 7px;
  display: grid;
  place-items: center;
  background: var(--red-soft);
  color: var(--red);
  font-size: 12px;
  font-weight: 800;
}
.em-check {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
  font-size: 14px;
}
.em-check li {
  display: flex;
  gap: 8px;
}
.em-check li::before {
  content: "✓";
  color: var(--good);
  font-weight: 800;
}
.em-col {
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-width: 0;
}
.em-mini2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

@media (max-width: 900px) {
  .em-su {
    grid-template-columns: minmax(0, 1fr);
  }
  .em-su-art {
    padding: 24px;
  }
  .em-su-art h1 {
    font-size: 24px;
  }
  .em-steps {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 8px 14px;
  }
  .em-steps div span:last-child {
    font-size: 13px;
  }
}
@media (max-width: 760px) {
  .g-main,
  .g2 {
    grid-template-columns: minmax(0, 1fr);
  }
  .em-su-form {
    padding: 22px;
  }
}

/* Print: only the open invoice. */
@media print {
  body > *:not(#dlg) {
    display: none !important;
  }
  #dlg dialog {
    position: static;
    box-shadow: none;
    border: 0;
    max-width: none;
  }
  #dlg dialog::backdrop {
    display: none;
  }
  #dlg .dh .btn,
  #dlg .no-print {
    display: none !important;
  }
}

/* Three packages side by side whenever there's room. */
.em-col .bz-plans {
  grid-template-columns: repeat(auto-fit, minmax(min(185px, 100%), 1fr));
}
.em-col .bz-plan .price small {
  line-height: 1.35;
}

/* Employee list: stacked cards on narrow screens, so no column hides off-screen. */
@media (max-width: 760px) {
  .emp-tbl table,
  .emp-tbl tbody,
  .emp-tbl tr,
  .emp-tbl td {
    display: block;
    width: 100%;
  }
  .emp-tbl thead {
    display: none;
  }
  .emp-tbl tr {
    padding: 14px 16px;
    border-bottom: 1px solid var(--line);
  }
  .emp-tbl td {
    padding: 0;
    border: 0;
    background: none !important;
  }
  .emp-tbl td[data-l] {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 8px;
    font-size: 14px;
  }
  .emp-tbl td[data-l]::before {
    content: attr(data-l);
    color: var(--muted);
    font-size: 13px;
    font-weight: 600;
  }
  .emp-tbl td[data-l] > * {
    text-align: right;
  }
}

/* ---------------------------------------------------------------- plans: start card */
.em-start {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 22px;
}
.es-head {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}
.es-head .tic2 {
  flex: none;
}
.es-head b {
  display: block;
  font-family: var(--display);
  font-size: 17px;
  margin-bottom: 3px;
}
.es-head span span {
  display: block;
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.45;
}
.es-plans {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 10px;
}
.es-plan {
  display: flex;
  flex-direction: column;
  gap: 6px;
  text-align: left;
  padding: 16px;
  border-radius: 14px;
  border: 1.5px solid var(--line);
  background: var(--surface-2);
  transition: border-color 0.15s ease, transform 0.15s ease;
}
.es-plan:hover {
  border-color: var(--sky);
  transform: translateY(-1px);
}
.es-plan.prem:hover {
  border-color: var(--gold);
}
.es-name {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-weight: 800;
  font-size: 15px;
}
.es-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  background: var(--gold-soft);
  color: var(--gold);
}
.es-price {
  font-family: var(--display);
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.1;
}
.es-price small {
  display: block;
  font-family: var(--body);
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  letter-spacing: 0;
}
.es-d {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.4;
  flex: 1;
}
.es-go {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 13px;
  font-weight: 700;
  color: var(--sky);
  margin-top: 4px;
}
.es-plan.prem .es-go {
  color: var(--gold);
}
.es-foot {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

/* ---------------------------------------------------------------- plans: None / Essential / Premium switch */
.plan-seg {
  display: inline-flex;
  padding: 3px;
  gap: 2px;
  border-radius: 11px;
  background: var(--surface-2);
  border: 1px solid var(--line);
}
.plan-seg button {
  min-height: 30px;
  padding: 0 12px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 700;
  color: var(--muted);
  white-space: nowrap;
  transition: background 0.15s ease, color 0.15s ease;
}
.plan-seg button:hover:not(:disabled):not(.on) {
  color: var(--ink);
}
.plan-seg button.on {
  background: var(--surface);
  color: var(--ink);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.18);
}
.plan-seg button.on.p-essential {
  background: var(--sky);
  color: #fff;
}
.plan-seg button.on.p-premium {
  background: var(--gold);
  color: #fff;
}
.plan-seg button:disabled {
  opacity: 0.38;
  cursor: not-allowed;
}
.plan-seg.busy {
  opacity: 0.6;
  pointer-events: none;
}
.bz-toggle .plan-seg {
  flex: none;
}

/* ---------------------------------------------------------------- plans: add employees dialog */
.sp {
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.sp-plans {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.sp-plan {
  display: flex;
  flex-direction: column;
  gap: 8px;
  text-align: left;
  padding: 14px;
  border-radius: 14px;
  border: 1.5px solid var(--line);
  background: var(--surface);
  transition: border-color 0.15s ease, background 0.15s ease;
}
.sp-plan:hover {
  border-color: color-mix(in srgb, var(--sky) 50%, var(--line));
}
.sp-plan.sel {
  border-color: var(--sky);
  background: color-mix(in srgb, var(--sky-soft) 55%, var(--surface));
}
.sp-plan.prem.sel {
  border-color: var(--gold);
  background: color-mix(in srgb, var(--gold-soft) 55%, var(--surface));
}
.sp-top {
  display: flex;
  align-items: center;
  gap: 8px;
}
.sp-top b {
  font-size: 15px;
}
.sp-dot {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2px solid var(--line);
  flex: none;
  display: grid;
  place-items: center;
}
.sp-plan.sel .sp-dot {
  border-color: var(--sky);
}
.sp-plan.prem.sel .sp-dot {
  border-color: var(--gold);
}
.sp-plan.sel .sp-dot::after {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--sky);
}
.sp-plan.prem.sel .sp-dot::after {
  background: var(--gold);
}
.sp-have {
  margin-left: auto;
  font-size: 11px;
  font-weight: 700;
  color: var(--muted);
}
.sp-price {
  font-family: var(--display);
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.1;
}
.sp-price small {
  display: block;
  font-family: var(--body);
  font-size: 11.5px;
  font-weight: 600;
  color: var(--muted);
  letter-spacing: 0;
}
.sp-pts {
  display: grid;
  gap: 4px;
  font-size: 12.5px;
  color: var(--muted);
  line-height: 1.35;
}
.sp-pts span {
  display: flex;
  gap: 6px;
  align-items: flex-start;
}
.sp-pts svg {
  flex: none;
  margin-top: 2px;
  color: var(--good);
}
.sp-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  align-items: start;
}
.sp-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
}
.sp-lab {
  font-size: 13px;
  font-weight: 700;
}
.sp-step {
  display: flex;
  align-items: stretch;
  height: 44px;
  border: 1.5px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
  overflow: hidden;
}
.sp-step:focus-within {
  border-color: var(--sky);
}
.sp-step button {
  width: 44px;
  flex: none;
  display: grid;
  place-items: center;
  color: var(--ink);
  background: var(--surface-2);
}
.sp-step button:hover {
  background: color-mix(in srgb, var(--sky-soft) 60%, var(--surface-2));
}
.sp-step input {
  flex: 1;
  min-width: 0;
  border: 0;
  background: transparent;
  text-align: center;
  font-size: 17px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  color: var(--ink);
  outline: none;
}
.sp-hint {
  font-size: 12.5px;
  color: var(--muted);
  line-height: 1.45;
}
.sp-hint .em-link {
  font-size: 12.5px;
}
.sp-seg {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  height: 44px;
  padding: 3px;
  gap: 3px;
  border-radius: 12px;
  border: 1.5px solid var(--line);
  background: var(--surface-2);
}
.sp-seg button {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border-radius: 9px;
  font-weight: 800;
  font-size: 14px;
  line-height: 1;
  color: var(--muted);
}
.sp-seg button small {
  font-size: 9.5px;
  font-weight: 600;
  margin-top: 2px;
}
.sp-seg button.on {
  background: var(--surface);
  color: var(--ink);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}
.sp-go {
  width: 100%;
  min-height: 46px;
  justify-content: center;
}
.sp-note {
  display: flex;
  gap: 6px;
  align-items: flex-start;
  justify-content: center;
  text-align: center;
  margin: -6px 0 0;
  font-size: 12.5px;
  color: var(--muted);
  line-height: 1.45;
}
.sp-note svg {
  flex: none;
  margin-top: 2px;
}
@media (max-width: 520px) {
  .sp-row {
    grid-template-columns: 1fr;
  }
  .sp-plans {
    grid-template-columns: 1fr;
  }
  .plan-seg button {
    padding: 0 9px;
  }
}
.es-go svg {
  transform: scaleX(-1);
}

/* ---------------------------------------------------------------- training */
#dlg dialog.wide:has(.tb) {
  max-width: min(940px, 96vw);
}
.tr-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
}
.tr-stat {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 18px;
}
.tr-stat .tic2 {
  margin-bottom: 4px;
}
.tr-stat .lab {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--muted);
}
.tr-stat .v {
  font-family: var(--display);
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.1;
}
.tr-stat .v small {
  font-size: 15px;
  color: var(--muted);
  font-weight: 700;
}
.tr-stat .v.tr-next {
  font-size: 20px;
}
.tr-stat .d {
  font-size: 12.5px;
  color: var(--muted);
}
.tr-list {
  display: flex;
  flex-direction: column;
}
.tr-row {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 16px 20px;
  border-top: 1px solid var(--line);
}
.tr-row:first-child {
  border-top: 0;
}
.tr-row.cancelled {
  opacity: 0.6;
}
.tr-day {
  flex: none;
  width: 52px;
  height: 56px;
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: var(--surface-2);
  color: var(--muted);
  border: 1.5px dashed var(--line);
}
.tr-day.set {
  border: 0;
  background: var(--good-soft);
  color: var(--good);
}
.tr-day small {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.tr-day b {
  font-family: var(--display);
  font-size: 21px;
  line-height: 1;
  color: var(--ink);
}
.tr-main {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 7px;
}
.tr-main > b {
  font-size: 15px;
}
.tr-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.tr-tag {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--surface-2);
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
}
.tr-sub,
.tr-note {
  display: flex;
  gap: 6px;
  align-items: flex-start;
  font-size: 12.5px;
  color: var(--muted);
  line-height: 1.4;
}
.tr-sub svg,
.tr-note svg {
  flex: none;
  margin-top: 2px;
}
.tr-note {
  padding: 8px 10px;
  border-radius: 10px;
  background: var(--sky-soft);
  color: var(--ink);
}
.tr-end {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
  flex: none;
}
.tr-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 8px;
  padding: 36px 24px;
}
.tr-empty .muted {
  max-width: 30em;
  font-size: 13.5px;
}
.tr-empty .btn {
  margin-top: 6px;
}
.tr-topics {
  display: grid;
  gap: 6px;
}
.tr-topic {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 11px 12px;
  border-radius: 11px;
  border: 1px solid var(--line);
  background: var(--surface);
  text-align: left;
  font-size: 13.5px;
  font-weight: 600;
  transition: border-color 0.15s ease, background 0.15s ease;
}
.tr-topic svg {
  color: var(--muted);
  flex: none;
}
.tr-topic:hover {
  border-color: var(--sky);
  background: color-mix(in srgb, var(--sky-soft) 40%, var(--surface));
}
.tr-topic:hover svg {
  color: var(--sky);
}
/* upsell */
.tr-up {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 28px;
  padding: 32px;
  align-items: center;
}
.tr-up-copy {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.tr-up-copy .eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.tr-up-copy p {
  margin: 0;
  line-height: 1.55;
}
.tr-up-list {
  display: grid;
  gap: 10px;
}
.tr-up-list > div {
  display: flex;
  gap: 12px;
  align-items: center;
  padding: 12px 14px;
  border-radius: 12px;
  background: var(--surface-2);
}
.tr-up-list b {
  display: block;
  font-size: 14px;
}
.tr-up-list small {
  color: var(--muted);
  font-size: 12.5px;
}
/* booking dialog */
.tb-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 290px;
  gap: 24px;
  align-items: start;
}
.tb-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.tb-step {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.tb-h {
  display: flex;
  align-items: center;
  gap: 10px;
}
.tb-h b {
  font-size: 14.5px;
}
.tb-n {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 12px;
  font-weight: 800;
  background: var(--ink);
  color: var(--surface);
  flex: none;
}
.tb-in {
  width: 100%;
  min-height: 44px;
  border: 1.5px solid var(--line);
  border-radius: 12px;
  padding: 0 12px;
  background: var(--surface);
  color: var(--ink);
  font: inherit;
  font-size: 14px;
  outline: none;
}
textarea.tb-in {
  padding: 10px 12px;
  resize: vertical;
}
.tb-in:focus {
  border-color: var(--sky);
}
input[type="date"].tb-in {
  color-scheme: light dark;
}
.tb-lab {
  font-size: 12.5px;
  font-weight: 700;
  margin-bottom: -4px;
}
.tb-hint {
  font-size: 12px;
  color: var(--muted);
  margin-top: -4px;
}
.tr-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.tr-chip {
  padding: 6px 11px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface);
  font-size: 12.5px;
  font-weight: 600;
  color: var(--muted);
  transition: all 0.15s ease;
}
.tr-chip:hover {
  color: var(--ink);
  border-color: color-mix(in srgb, var(--ink) 30%, var(--line));
}
.tr-chip.on {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--surface);
}
.tb-fmt {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.tb-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  padding: 14px;
  border-radius: 14px;
  border: 1.5px solid var(--line);
  background: var(--surface);
  text-align: left;
  transition: border-color 0.15s ease, background 0.15s ease;
}
.tb-card .tic2 {
  margin-bottom: 6px;
}
.tb-card b {
  font-size: 14.5px;
}
.tb-card small {
  font-size: 12.5px;
  color: var(--muted);
}
.tb-card:hover:not(:disabled) {
  border-color: color-mix(in srgb, var(--sky) 50%, var(--line));
}
.tb-card.on {
  border-color: var(--sky);
  background: color-mix(in srgb, var(--sky-soft) 55%, var(--surface));
}
.tb-card.on .tic2 {
  background: var(--sky);
  color: #fff;
}
.tb-card:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
.tb-dots {
  display: flex;
  gap: 4px;
  margin-top: 6px;
}
.tb-dots i {
  width: 18px;
  height: 5px;
  border-radius: 3px;
  background: var(--gold);
}
.tb-dots i.used {
  background: var(--line);
}
.tb-two {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.tr-seg {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 1fr;
  min-height: 44px;
  padding: 3px;
  gap: 3px;
  border-radius: 12px;
  border: 1.5px solid var(--line);
  background: var(--surface-2);
}
.tr-seg button {
  border-radius: 9px;
  font-size: 13px;
  font-weight: 700;
  color: var(--muted);
  white-space: nowrap;
  padding: 0 6px;
}
.tr-seg button.on {
  background: var(--surface);
  color: var(--ink);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.18);
}
.tb-num {
  height: 44px;
}
.tb-side {
  position: sticky;
  top: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.tb-sum {
  border-radius: 16px;
  padding: 16px;
  background: var(--surface-2);
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.ts-line {
  display: flex;
  gap: 10px;
  align-items: flex-start;
}
.ts-ic {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: var(--surface);
  color: var(--muted);
  flex: none;
}
.ts-line small {
  display: block;
  font-size: 11.5px;
  color: var(--muted);
  font-weight: 600;
}
.ts-line b {
  display: block;
  font-size: 13.5px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}
.ts-sub {
  display: block;
  font-weight: 500;
  color: var(--muted);
  font-size: 12.5px;
}
.ts-inc {
  display: flex;
  justify-content: space-between;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  font-size: 13.5px;
  font-weight: 700;
}
.ts-inc b {
  color: var(--good);
}
.ts-left {
  display: flex;
  gap: 6px;
  align-items: center;
  font-size: 12px;
  color: var(--gold);
  font-weight: 600;
}
.tb-go {
  width: 100%;
  min-height: 46px;
  justify-content: center;
}
.tb-fine {
  margin: 0;
  font-size: 12px;
  color: var(--muted);
  text-align: center;
  line-height: 1.45;
}
@media (max-width: 820px) {
  .tb-grid,
  .tr-up {
    grid-template-columns: 1fr;
  }
  .tb-side {
    position: static;
  }
  .tr-up {
    padding: 22px;
  }
}
@media (max-width: 520px) {
  .tb-fmt,
  .tb-two {
    grid-template-columns: 1fr;
  }
  .tr-row {
    flex-wrap: wrap;
  }
  .tr-end {
    flex-direction: row;
    width: 100%;
    justify-content: space-between;
    align-items: center;
  }
}
