/* F-Team App
   Layout: celular primeiro (barra inferior) · no computador vira menu lateral + conteúdo.
   Identidade: mesma do site de vendas, preto profundo + ciano F-Team, Poppins nos títulos e Inter no texto. */
:root {
  --bg: #050708;
  --surface: #0b1114;
  --surface-2: #10181c;
  --surface-3: #172227;
  --line: rgba(255, 255, 255, .07);
  --line-strong: rgba(255, 255, 255, .14);
  --text: #eef4f6;
  --muted: #8b9aa2;
  --faint: #5b6a72;
  --accent: #00d4ff;
  --accent-hover: #4ae2ff;
  --accent-ink: #00161c;
  --accent-deep: #00a9cc;
  --accent-soft: rgba(0, 212, 255, .11);
  --accent-line: rgba(0, 212, 255, .35);
  --ok: #34d399;
  --ok-soft: rgba(52, 211, 153, .12);
  --warn: #fbbf24;
  --warn-soft: rgba(251, 191, 36, .12);
  --danger: #f87171;
  --danger-soft: rgba(248, 113, 113, .12);
  --wa: #25d366;

  --font-display: 'Poppins', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-body: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;

  --r-sm: 10px;
  --r: 14px;
  --r-lg: 20px;
  --tabbar-h: 64px;
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);
  --gutter-l: max(16px, env(safe-area-inset-left, 0px));
  --gutter-r: max(16px, env(safe-area-inset-right, 0px));
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  background-image: radial-gradient(120% 60% at 50% -10%, rgba(0, 212, 255, .08), transparent 60%);
  background-attachment: fixed;
  color: var(--text);
  font: 400 15px/1.55 var(--font-body);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  min-height: 100vh;
}
body.no-scroll { overflow: hidden; }
h1, h2, h3 { font-family: var(--font-display); line-height: 1.2; margin: 0; text-wrap: balance; letter-spacing: -.01em; }
h1 { font-size: clamp(1.5rem, 1.2rem + 1.2vw, 2rem); font-weight: 700; }
h2 { font-size: 1.05rem; font-weight: 600; }
h3 { font-size: 1rem; font-weight: 600; }
p { margin: 0; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
img { max-width: 100%; display: block; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.ti { font-size: 1.15em; line-height: 1; vertical-align: -0.15em; }
.muted { color: var(--muted); }
.small { font-size: .82rem; }
.grow { flex: 1; min-width: 0; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 6px;
  font: 600 .7rem/1.2 var(--font-body); letter-spacing: .12em; text-transform: uppercase; color: var(--accent);
}
.section-title { font-size: 1rem; margin: 8px 0 12px; }
.spinner { width: 18px; height: 18px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; display: inline-block; animation: spin .7s linear infinite; }
.spinner.big { width: 32px; height: 32px; border-width: 3px; color: var(--accent); }
@keyframes spin { to { transform: rotate(360deg); } }
.loading { display: grid; place-items: center; min-height: 50vh; }

/* ---------- Marca ---------- */
.brand { display: flex; align-items: center; gap: 10px; }
.logo-mark {
  width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center;
  background: var(--accent); color: var(--accent-ink); font-size: 18px; flex: none;
  box-shadow: 0 0 18px rgba(0, 212, 255, .35);
}
.logo-mark.xl { width: 84px; height: 84px; border-radius: 50%; font-size: 40px; box-shadow: 0 0 48px rgba(0, 212, 255, .45); }
.brand-name { font: italic 800 1.25rem/1 var(--font-display); letter-spacing: -.02em; }
.brand-name span, .auth-title span { color: var(--accent); }

/* ---------- Estrutura ---------- */
.shell { min-height: 100vh; }
.topbar {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; gap: 10px;
  padding: calc(var(--safe-t) + 10px) var(--gutter-r) 10px var(--gutter-l);
  background: rgba(5, 7, 8, .82); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.topbar .brand { flex: 1; }
.demo-pill { font-size: .7rem; font-weight: 600; color: var(--warn); background: var(--warn-soft); padding: 4px 10px; border-radius: 99px; }
#view { padding-bottom: calc(var(--tabbar-h) + var(--safe-b) + 24px); }
.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 20;
  display: flex; justify-content: space-around;
  padding: 6px var(--gutter-r) calc(6px + var(--safe-b)) var(--gutter-l);
  background: rgba(8, 12, 14, .92); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  border-top: 1px solid var(--line);
}
.tabbar .nav-link {
  flex: 1; display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 6px 2px;
  font-size: .68rem; font-weight: 500; color: var(--faint); position: relative; border-radius: var(--r-sm);
}
.tabbar .nav-link .ti { font-size: 1.45rem; }
.tabbar .nav-link.active { color: var(--accent); }
.nav-link.has-dot::after {
  content: ''; position: absolute; top: 4px; left: calc(50% + 10px); width: 8px; height: 8px; border-radius: 50%;
  background: var(--warn); box-shadow: 0 0 0 2px var(--bg);
}
.sidenav { display: none; }

body.focus-mode .tabbar, body.focus-mode .topbar { display: none; }
body.focus-mode #view { padding-bottom: 0; }

@media (min-width: 960px) {
  .shell { display: grid; grid-template-columns: 248px minmax(0, 1fr); }
  .topbar, .tabbar { display: none; }
  #view { padding-bottom: 48px; }
  .sidenav {
    display: flex; flex-direction: column; gap: 28px; position: sticky; top: 0; height: 100vh;
    padding: 28px 16px 20px; border-right: 1px solid var(--line); background: rgba(8, 12, 14, .6);
  }
  .sidenav .brand { padding: 0 10px; }
  .side-links { display: flex; flex-direction: column; gap: 4px; flex: 1; }
  .sidenav .nav-link {
    display: flex; align-items: center; gap: 12px; padding: 11px 12px; border-radius: var(--r-sm);
    color: var(--muted); font-weight: 500; position: relative;
  }
  .sidenav .nav-link:hover { background: var(--surface-2); color: var(--text); }
  .sidenav .nav-link.active { background: var(--accent-soft); color: var(--accent); }
  .sidenav .nav-link.has-dot::after { top: 50%; left: auto; right: 12px; transform: translateY(-50%); }
  .side-user {
    display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: var(--r);
    background: var(--surface); border: 1px solid var(--line); text-align: left;
  }
  .side-user span:nth-child(2) { flex: 1; display: flex; flex-direction: column; min-width: 0; }
  .side-user small { color: var(--muted); }
  body.focus-mode .shell { grid-template-columns: minmax(0, 1fr); }
  body.focus-mode .sidenav { display: none; }
}

/* ---------- Página ---------- */
.page {
  max-width: 1080px; margin: 0 auto;
  padding: 20px var(--gutter-r) 0 var(--gutter-l);
  display: flex; flex-direction: column; gap: 18px;
}
.page.narrow { max-width: 640px; }
.page.with-bar { padding-bottom: 90px; }
@media (min-width: 960px) { .page { padding-top: 36px; gap: 22px; } }
.page-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.page-head p { margin-top: 4px; max-width: 60ch; }
.page-head .eyebrow { margin-bottom: 6px; }
.avatar.has-photo { padding: 0; overflow: hidden; background: var(--bg); }
.avatar.has-photo img { width: 100%; height: 100%; object-fit: cover; display: block; border-radius: inherit; }
.avatar-edit { position: relative; background: none; border: 0; padding: 0; cursor: pointer; flex: none; }
.avatar-edit i { position: absolute; right: -2px; bottom: -2px; display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: var(--accent); color: #001018; font-size: 14px; }
.rest-txt.as-btn { background: none; border: 0; color: inherit; text-align: left; padding: 0; font: inherit; cursor: pointer; }
.back-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.viewas-bar { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 8px; padding: 8px 14px; background: var(--accent); color: #001018; font-size: .9rem; }
.viewas-bar span { flex: 1; }
.viewas-bar .btn { background: #001018; color: #fff; border-color: transparent; }
.back { display: inline-flex; align-items: center; gap: 4px; color: var(--muted); font-size: .9rem; font-weight: 500; align-self: flex-start; }
.back:hover { color: var(--text); }
@media (max-width: 520px) { .hide-sm { display: none; } }

/* ---------- Botões ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 0 18px; border-radius: 12px;
  background: var(--surface-2); border: 1px solid var(--line-strong);
  font-weight: 600; font-size: .92rem; white-space: nowrap; transition: background .15s, transform .1s, border-color .15s;
}
.btn:hover { background: var(--surface-3); }
.btn:active { transform: scale(.98); }
.btn.primary { background: var(--accent); color: var(--accent-ink); border-color: transparent; box-shadow: 0 6px 20px -8px rgba(0, 212, 255, .6); }
.btn.primary:hover { background: var(--accent-hover); }
.btn.dark { background: var(--accent-ink); color: var(--accent); border-color: transparent; }
.btn.dark:hover { background: #002630; }
.btn.ghost { background: transparent; }
.btn.ghost-dark { background: transparent; color: var(--accent-ink); border-color: rgba(0, 22, 28, .3); }
.btn.ghost-dark:hover { background: rgba(0, 22, 28, .08); }
.btn.danger { background: var(--danger); color: #1a0505; border-color: transparent; }
.btn.danger-ghost { background: transparent; color: var(--danger); border-color: rgba(248, 113, 113, .3); }
.btn.wa { background: var(--wa); color: #04210f; border-color: transparent; }
.btn.sm { min-height: 36px; padding: 0 12px; font-size: .84rem; border-radius: 10px; }
.btn.block { width: 100%; }
.btn.dashed { background: transparent; border-style: dashed; color: var(--muted); }
.btn.dashed:hover { color: var(--accent); border-color: var(--accent-line); }
.btn[disabled] { opacity: .45; pointer-events: none; }
.icon-btn {
  width: 40px; height: 40px; flex: none; display: inline-grid; place-items: center; border-radius: 12px;
  background: transparent; border: 0; color: var(--muted);
}
.icon-btn:hover { background: var(--surface-2); color: var(--text); }
.icon-btn[disabled] { opacity: .3; pointer-events: none; }
.link-btn { background: none; border: 0; color: var(--accent); font-weight: 500; padding: 8px 0; display: inline-flex; align-items: center; gap: 4px; }
.link { color: var(--accent); font-size: .85rem; font-weight: 500; }
.row-actions { display: flex; gap: 10px; justify-content: flex-end; flex-wrap: wrap; }
.row-actions.start { justify-content: flex-start; }
.row-actions .btn { flex: 1 1 auto; }
.row-actions.start .btn { flex: 0 1 auto; }

/* ---------- Avatar e selos ---------- */
.avatar {
  width: 40px; height: 40px; border-radius: 50%; flex: none; display: inline-grid; place-items: center;
  background: var(--surface-3); color: var(--accent); font: 600 .85rem var(--font-display); border: 1px solid var(--line-strong);
}
.avatar.sm { width: 32px; height: 32px; font-size: .72rem; }
.avatar.lg { width: 52px; height: 52px; font-size: 1rem; }
.avatar.xl { width: 68px; height: 68px; font-size: 1.3rem; }
.avatar.coach { background: var(--accent-soft); border-color: var(--accent-line); }
.pill {
  display: inline-flex; align-items: center; gap: 4px; white-space: nowrap;
  font-size: .72rem; font-weight: 600; padding: 4px 10px; border-radius: 99px;
  background: var(--surface-3); color: var(--muted); border: 0;
}
.pill.accent { background: var(--accent-soft); color: var(--accent); }
.pill.ok { background: var(--ok-soft); color: var(--ok); }
.pill.warn { background: var(--warn-soft); color: var(--warn); }
.pill.danger { background: var(--danger-soft); color: var(--danger); }
.pill.as-btn { cursor: pointer; }
.pills { display: flex; flex-wrap: wrap; gap: 6px; }

/* ---------- Painéis e listas ---------- */
.panel {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg);
  padding: 18px; display: flex; flex-direction: column; gap: 14px; min-width: 0;
}
.panel.flush { padding: 4px 0; }
.panel-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.panel-head .count { font: 600 .8rem var(--font-display); color: var(--muted); background: var(--surface-3); border-radius: 99px; padding: 2px 10px; }
.cols { display: grid; gap: 18px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 900px) { .cols { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: start; } }

.list { display: flex; flex-direction: column; }
.list.gap { gap: 12px; }
.panel .list { margin: 0 -18px; }
.panel.flush .list { margin: 0; }
.row-item {
  display: flex; align-items: center; gap: 12px; padding: 12px 18px; width: 100%;
  background: none; border: 0; border-top: 1px solid var(--line); text-align: left; transition: background .15s;
}
.list > .row-item:first-child, .list > details.row-item:first-child { border-top: 0; }
a.row-item:hover, button.row-item:hover { background: rgba(255, 255, 255, .025); }
.ri-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.ri-main strong { font-weight: 600; font-size: .95rem; }
.ri-main .small { overflow: hidden; text-overflow: ellipsis; }
.ri-side { display: flex; align-items: center; gap: 10px; }
.week-count { font: 600 .85rem var(--font-display); color: var(--muted); font-variant-numeric: tabular-nums; min-width: 2.4em; text-align: right; }

details.row-item { display: block; padding: 0; }
details.row-item > summary { display: flex; align-items: center; gap: 12px; padding: 12px 18px; list-style: none; cursor: pointer; }
details.row-item > summary::-webkit-details-marker { display: none; }
details.row-item .chev { color: var(--faint); transition: transform .2s; }
details.row-item[open] .chev { transform: rotate(180deg); }
.list.gap details.row-item, .page > .list details.row-item { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); }
.session-detail { padding: 0 18px 14px 66px; display: flex; flex-direction: column; gap: 6px; }
.sd-row { display: flex; justify-content: space-between; gap: 12px; font-size: .84rem; border-bottom: 1px dashed var(--line); padding-bottom: 6px; }
.sd-name { color: var(--muted); min-width: 0; }
.sd-sets { font-variant-numeric: tabular-nums; text-align: right; white-space: pre-wrap; }
.quote { color: var(--text); font-size: .9rem; background: var(--surface-2); border-radius: var(--r-sm); padding: 10px 12px; border-left: 2px solid var(--accent-line); border-radius: 0 var(--r-sm) var(--r-sm) 0; }

.empty { text-align: center; padding: 36px 16px; display: flex; flex-direction: column; align-items: center; gap: 10px; }
.empty.small { padding: 22px 16px; }
.empty p { max-width: 42ch; }
.empty-icon { font-size: 2.2rem; color: var(--accent); background: var(--accent-soft); width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; }
.empty-icon.ok { color: var(--ok); background: var(--ok-soft); }
.empty.small .empty-icon { width: 48px; height: 48px; font-size: 1.6rem; }

/* ---------- Números do painel ---------- */
.stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
@media (min-width: 900px) { .stats { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.stats.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.stat {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg);
  padding: 14px 16px; display: flex; flex-direction: column; gap: 4px; min-width: 0;
}
.stat > span { font-size: .76rem; color: var(--muted); line-height: 1.3; }
.stat b { font: 700 1.9rem/1.1 var(--font-display); font-variant-numeric: tabular-nums; display: flex; align-items: baseline; gap: 4px; }
.stat b em { font-style: normal; font-size: 1rem; color: var(--faint); font-weight: 600; }
.stat b .ti { font-size: 1.1rem; color: var(--warn); }
.stat small { font-size: .76rem; color: var(--faint); }
.stat.warn b { color: var(--warn); }
.stat.accent b { color: var(--accent); }
.stats.three .stat b { font-size: 1.5rem; }

/* ---------- Busca e filtros ---------- */
.toolbar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.search {
  flex: 1 1 240px; display: flex; align-items: center; gap: 8px; padding: 0 14px; min-height: 44px;
  background: var(--surface); border: 1px solid var(--line); border-radius: 12px; color: var(--muted);
}
.search input { flex: 1; background: none; border: 0; outline: none; min-width: 0; height: 42px; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; }
.chips.scroll { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
.chip {
  padding: 8px 14px; border-radius: 99px; background: var(--surface); border: 1px solid var(--line);
  font-size: .84rem; font-weight: 500; color: var(--muted); white-space: nowrap;
}
.chip.on { background: var(--accent-soft); border-color: var(--accent-line); color: var(--accent); }

/* ---------- Ficha do aluno ---------- */
.profile-head { display: flex; align-items: center; gap: 14px; }
.ph-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
@media (max-width: 420px) { .profile-head .avatar.xl { width: 52px; height: 52px; font-size: 1rem; } .profile-head h1 { font-size: 1.35rem; } }
.ph-stat { text-align: right; display: flex; flex-direction: column; }
.ph-stat b { font: 700 2rem/1 var(--font-display); color: var(--accent); }
.ph-stat b em { font-style: normal; font-size: 1rem; color: var(--faint); }
.ph-stat span { font-size: .75rem; color: var(--muted); }
.note-card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 14px 16px;
  display: flex; flex-direction: column; gap: 8px;
}
.note-card label { font-size: .85rem; font-weight: 600; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.note-card label .ti { color: var(--accent); }
.note-row { display: flex; gap: 10px; align-items: flex-end; }
.note-row textarea { flex: 1; resize: none; min-height: 40px; }
.tabs {
  display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none;
  border-bottom: 1px solid var(--line); margin: 0 calc(-1 * var(--gutter-r)) 0 calc(-1 * var(--gutter-l)); padding: 0 var(--gutter-r) 0 var(--gutter-l);
}
.tab {
  display: flex; align-items: center; gap: 6px; padding: 12px 12px; white-space: nowrap; font-weight: 500; font-size: .9rem;
  color: var(--muted); border-bottom: 2px solid transparent; margin-bottom: -1px;
}
.tab.on { color: var(--accent); border-bottom-color: var(--accent); }
.tab .dot { font-style: normal; font-size: .68rem; font-weight: 700; background: var(--warn); color: #241800; border-radius: 99px; padding: 1px 7px; }
#tabBody { display: flex; flex-direction: column; gap: 16px; }
.tab-actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.tab-actions p { flex: 1; min-width: 200px; }
.kv { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 10px 20px; margin: 0; font-size: .92rem; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; overflow-wrap: anywhere; }
.danger-zone { border-color: rgba(248, 113, 113, .18); }

/* ---------- Cartões de treino ---------- */
.wk-list { display: grid; gap: 12px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 900px) { .page:not(.narrow) .wk-list { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.wk-card {
  display: flex; align-items: center; gap: 14px; padding: 14px 14px 14px 16px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); min-width: 0;
}
.wk-card.link-card:hover { border-color: var(--line-strong); }
.wk-card.is-next { border-color: var(--accent-line); }
.wk-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; align-items: flex-start; }
.wk-main strong { font: 600 1rem var(--font-display); }
.wk-ex { font-size: .8rem; color: var(--faint); overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.wk-tools { display: flex; flex-direction: column; }
@media (min-width: 600px) { .wk-tools { flex-direction: row; } }
.wk-letter {
  width: 52px; height: 52px; flex: none; border-radius: 14px; display: grid; place-items: center;
  font: 800 1.6rem/1 var(--font-display); color: var(--accent); background: var(--accent-soft); border: 1px solid var(--accent-line);
}
.wk-letter.sm { width: 38px; height: 38px; font-size: 1.1rem; border-radius: 11px; }
.wk-letter.lg { width: 64px; height: 64px; font-size: 2rem; border-radius: 18px; }
.wk-head { display: flex; align-items: center; gap: 16px; }
.wk-head p { margin-top: 4px; }

/* ---------- Editor ---------- */
.ed-head { display: flex; gap: 12px; }
.label-field { width: 90px; flex: none; }
.ed-summary { display: flex; gap: 8px; flex-wrap: wrap; }
.ed-summary span { font-size: .8rem; color: var(--muted); background: var(--surface); border: 1px solid var(--line); padding: 5px 12px; border-radius: 99px; font-variant-numeric: tabular-nums; }
.ed-items { display: flex; flex-direction: column; gap: 12px; }
.ed-item { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 10px; }
.ed-item-head { display: flex; align-items: center; gap: 10px; }
.ed-item-head .grow { display: flex; flex-direction: column; }
.ed-n {
  width: 28px; height: 28px; flex: none; border-radius: 50%; display: grid; place-items: center;
  font: 700 .8rem var(--font-display); background: var(--surface-3); color: var(--muted);
}
.ed-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
@media (min-width: 640px) { .ed-grid { grid-template-columns: 80px 1fr 1fr 1fr; } }
.save-bar {
  position: sticky; bottom: calc(var(--tabbar-h) + var(--safe-b) + 8px); z-index: 5;
  padding: 10px 0; background: linear-gradient(transparent, var(--bg) 35%);
}
@media (min-width: 960px) { .save-bar { bottom: 12px; } }
.page.with-bar .save-bar { position: fixed; left: 0; right: 0; padding: 12px var(--gutter-r) 12px var(--gutter-l); }
@media (min-width: 960px) { .page.with-bar .save-bar { left: 248px; } .page.with-bar .save-bar .btn { max-width: 608px; margin: 0 auto; display: flex; } }

/* ---------- Formulários ---------- */
.form { display: flex; flex-direction: column; gap: 14px; }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field > span { font-size: .8rem; font-weight: 500; color: var(--muted); }
.field > span em { font-style: normal; color: var(--faint); font-weight: 400; }
input:not([type=checkbox]):not([type=radio]):not([type=file]), select, textarea {
  width: 100%; min-height: 44px; padding: 10px 12px; border-radius: 12px;
  background: var(--surface-2); border: 1px solid var(--line-strong); outline: none;
  font-size: 16px; transition: border-color .15s, box-shadow .15s;
}
textarea { resize: vertical; line-height: 1.45; }
input:focus, select:focus, textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
input::placeholder, textarea::placeholder { color: var(--faint); }
input[readonly] { color: var(--muted); }
select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%); background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 32px; }
.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.form-error { color: var(--danger); font-size: .86rem; background: var(--danger-soft); padding: 8px 12px; border-radius: var(--r-sm); }
.seg { display: flex; background: var(--surface-2); border: 1px solid var(--line); border-radius: 12px; padding: 4px; gap: 4px; }
.seg > button, .seg > label { flex: 1; }
.seg > button, .seg > label > span {
  display: block; text-align: center; padding: 9px 8px; border-radius: 9px; border: 0; background: none;
  font-weight: 600; font-size: .88rem; color: var(--muted); cursor: pointer;
}
.seg > label > input { position: absolute; opacity: 0; pointer-events: none; }
.seg > button.on, .seg > label > input:checked + span { background: var(--surface-3); color: var(--text); }
.seg > label > input:focus-visible + span { outline: 2px solid var(--accent); }
.check-list { display: flex; flex-direction: column; gap: 8px; }
.check-row {
  display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: var(--r);
  background: var(--surface-2); border: 1px solid var(--line); cursor: pointer;
}
.check-row:has(input:checked) { border-color: var(--accent-line); background: var(--accent-soft); }
.check-row.plain { background: none; border: 0; padding: 4px 0; }
.check-row span { display: flex; flex-direction: column; min-width: 0; }
.check-row input { width: 20px; height: 20px; accent-color: var(--accent); flex: none; }
.scale { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; }
.scale-opt input, .rpe input { position: absolute; opacity: 0; pointer-events: none; }
.scale-opt span, .rpe span {
  display: grid; place-items: center; height: 46px; border-radius: 12px; cursor: pointer;
  background: var(--surface-2); border: 1px solid var(--line-strong); font: 600 1rem var(--font-display); color: var(--muted);
  transition: all .12s;
}
.scale-opt input:checked + span, .rpe input:checked + span { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.scale-opt input:focus-visible + span, .rpe input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
.scale-legend { display: flex; justify-content: space-between; font-size: .74rem; color: var(--faint); }
.rpe { display: grid; grid-template-columns: repeat(11, 1fr); gap: 4px; }
.rpe span { height: 40px; font-size: .88rem; border-radius: 9px; }

/* ---------- Folha (modal) ---------- */
.sheet-backdrop {
  position: fixed; inset: 0; z-index: 50; background: rgba(0, 0, 0, .62);
  display: flex; align-items: flex-end; justify-content: center; opacity: 0; transition: opacity .2s;
}
.sheet-backdrop.open { opacity: 1; }
.sheet {
  position: relative; width: 100%; max-width: 560px; max-height: 92vh; overflow-y: auto;
  background: var(--surface); border: 1px solid var(--line-strong); border-bottom: 0;
  border-radius: 24px 24px 0 0; padding: 22px var(--gutter-r) calc(22px + var(--safe-b)) var(--gutter-l);
  display: flex; flex-direction: column; gap: 14px;
  transform: translateY(24px); transition: transform .22s cubic-bezier(.2, .8, .2, 1);
}
.sheet.wide { max-width: 640px; }
.sheet-backdrop.open .sheet { transform: none; }
.sheet::before { content: ''; width: 40px; height: 4px; border-radius: 4px; background: var(--line-strong); align-self: center; margin: -10px 0 2px; }
.sheet-close { position: absolute; top: 10px; right: 10px; }
.sheet-title { font-size: 1.2rem; padding-right: 40px; }
.sheet-foot { display: flex; gap: 10px; position: sticky; bottom: calc(-22px - var(--safe-b)); background: var(--surface); padding: 10px 0 0; }
@media (min-width: 640px) {
  .sheet-backdrop { align-items: center; padding: 24px; }
  .sheet { border-radius: 24px; border-bottom: 1px solid var(--line-strong); padding: 26px; }
  .sheet::before { display: none; }
  .sheet-foot { bottom: -26px; padding-bottom: 4px; }
}
.pick-list { display: flex; flex-direction: column; gap: 6px; max-height: 46vh; overflow-y: auto; }
.pad { padding: 12px; }
.menu-head { display: flex; align-items: center; gap: 14px; }
.menu-list { display: flex; flex-direction: column; }
.menu-item { display: flex; align-items: center; gap: 12px; padding: 14px 4px; background: none; border: 0; border-top: 1px solid var(--line); text-align: left; font-weight: 500; }
.menu-item .ti { color: var(--muted); font-size: 1.3rem; }
.menu-item.danger, .menu-item.danger .ti { color: var(--danger); }
.steps { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 10px; }
.steps .ti { color: var(--accent); }
.invite {
  white-space: pre-wrap; font: .88rem/1.5 var(--font-body); background: var(--surface-2); border: 1px solid var(--line);
  border-radius: var(--r); padding: 14px; margin: 0; overflow-wrap: anywhere; user-select: all;
}

/* ---------- Toast ---------- */
.toast {
  position: fixed; left: 50%; bottom: calc(var(--tabbar-h) + var(--safe-b) + 18px); z-index: 60;
  transform: translate(-50%, 20px); opacity: 0; pointer-events: none;
  display: flex; align-items: center; gap: 10px; max-width: min(92vw, 420px);
  padding: 12px 16px; border-radius: 14px; background: var(--surface-3); border: 1px solid var(--line-strong);
  font-weight: 500; font-size: .9rem; box-shadow: 0 12px 30px rgba(0, 0, 0, .5); transition: all .22s;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast .ti { color: var(--ok); font-size: 1.3rem; }
.toast.error .ti { color: var(--danger); }
body.focus-mode .toast { bottom: calc(150px + var(--safe-b)); }

/* ---------- Login ---------- */
.auth {
  min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 28px;
  padding: calc(var(--safe-t) + 32px) var(--gutter-r) calc(var(--safe-b) + 24px) var(--gutter-l);
}
.auth-hero { text-align: center; display: flex; flex-direction: column; align-items: center; gap: 14px; }
.auth-title { font: italic 800 2.6rem/1 var(--font-display); letter-spacing: -.03em; }
.auth-tag { color: var(--muted); font-size: 1rem; }
.auth-tag strong { color: var(--text); font-weight: 600; }
.auth-card {
  width: 100%; max-width: 400px; background: var(--surface); border: 1px solid var(--line);
  border-radius: 24px; padding: 22px; display: flex; flex-direction: column; gap: 18px;
}
.demo-box { display: flex; flex-direction: column; gap: 12px; }
.demo-box p { color: var(--muted); font-size: .9rem; }
.auth-foot { font-size: .75rem; color: var(--faint); }

/* ---------- Aluno: início ---------- */
.hello h1 { font-size: 1.7rem; }
.hello .eyebrow { margin-bottom: 4px; }
.hero-card {
  position: relative; overflow: hidden; border-radius: 26px; padding: 22px 22px 20px;
  background: var(--accent); color: var(--accent-ink);
  box-shadow: 0 24px 50px -24px rgba(0, 212, 255, .55);
}
.hero-letter {
  position: absolute; right: -14px; bottom: -48px; pointer-events: none;
  font: 800 13rem/1 var(--font-display); letter-spacing: -.06em; color: var(--accent-deep); opacity: .55;
}
.hero-body { position: relative; display: flex; flex-direction: column; gap: 4px; max-width: 75%; }
.eyebrow.on-accent { color: var(--accent-ink); opacity: .7; }
.hero-card h2 { font: 800 2.1rem/1.05 var(--font-display); letter-spacing: -.03em; margin-top: 4px; }
.hero-title { font-weight: 600; font-size: 1rem; }
.hero-meta { font-size: .85rem; font-weight: 500; opacity: .75; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-top: 2px; }
.hero-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 16px; }
@media (max-width: 380px) { .hero-body { max-width: 100%; } .hero-letter { font-size: 10rem; } }

.goal { font-size: .85rem; color: var(--muted); }
.goal b { font: 700 1.05rem var(--font-display); color: var(--text); }
.goal.hit b { color: var(--accent); }
.week { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.wday { display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: .72rem; color: var(--faint); font-weight: 600; }
.wday b {
  width: 100%; max-width: 44px; aspect-ratio: 1; border-radius: 12px; display: grid; place-items: center;
  background: var(--surface-2); border: 1px solid var(--line); color: var(--muted); font: 600 .86rem var(--font-display);
}
.wday.done b { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.wday.today b { border-color: var(--accent); color: var(--accent); }
.wday.today span { color: var(--accent); }
.wday.future b { opacity: .5; }
.progress { height: 6px; border-radius: 6px; background: var(--surface-3); overflow: hidden; }
.progress span { display: block; height: 100%; background: var(--accent); border-radius: 6px; transition: width .4s; }

.coach-note {
  display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border-radius: var(--r-lg);
  background: var(--accent-soft); border: 1px solid var(--accent-line);
}
.coach-note p { margin-top: 2px; }
.coach-note.slim { padding: 10px 14px; align-items: center; font-size: .9rem; }
.coach-note.slim > .ti { color: var(--accent); font-size: 1.2rem; }
.task-card {
  display: flex; align-items: center; gap: 14px; padding: 14px 16px; border-radius: var(--r-lg);
  background: var(--surface); border: 1px solid var(--line);
}
.task-card > div { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.task-card span { font-size: .84rem; color: var(--muted); }
.task-card > .ti:last-child { color: var(--faint); }
.tc-icon { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; flex: none; font-size: 1.3rem; background: var(--warn-soft); color: var(--warn); }
.task-card.accent { border-color: var(--accent-line); }
.task-card.accent .tc-icon { background: var(--accent-soft); color: var(--accent); }
.task-card.ok .tc-icon { background: var(--ok-soft); color: var(--ok); }
.install-card {
  display: flex; align-items: center; gap: 12px; padding: 12px 8px 12px 14px; border-radius: var(--r-lg);
  border: 1px dashed var(--line-strong); flex-wrap: wrap;
}
.install-card > div { flex: 1 1 160px; display: flex; flex-direction: column; }
.install-card span { font-size: .82rem; color: var(--muted); }
.install-card .tc-icon { background: var(--surface-3); color: var(--text); }
/* aviso flutuante acima da barra de abas */
.install-card.float {
  position: fixed; z-index: 40; left: 12px; right: 12px; bottom: calc(76px + env(safe-area-inset-bottom, 0px));
  bottom: calc(var(--tabbar-h) + var(--safe-b) + 12px);
  max-width: 520px; margin: 0 auto; padding: 14px; gap: 12px; align-items: flex-start;
  background: var(--surface-2); border: 1px solid var(--accent-line); border-style: solid;
  box-shadow: 0 12px 40px rgba(0, 0, 0, .55); animation: ic-up .35s ease both;
}
.install-card.float .tc-icon { background: var(--accent-soft); color: var(--accent); width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; flex: none; font-size: 1.3rem; }
.install-card.float > div:not(.ic-actions) { flex: 1 1 180px; }
.install-card .ic-actions { flex: 1 1 100%; display: flex; align-items: center; gap: 14px; }
.install-card .ic-actions .btn { flex: 1; }
@media (min-width: 960px) { .install-card.float { bottom: 20px; left: 268px; } }
@keyframes ic-up { from { opacity: 0; transform: translateY(16px); } }
.page.narrow:has(.install-card.float) { padding-bottom: 190px; }
.copy-link { display: flex; gap: 8px; align-items: center; background: var(--surface-2); border: 1px solid var(--line); border-radius: 12px; padding: 8px 8px 8px 12px; }
.copy-link code { flex: 1; min-width: 0; overflow-wrap: anywhere; font-size: .84rem; }
.ios-arrow { display: flex; flex-direction: column; align-items: center; gap: 4px; color: var(--accent); font-size: .82rem; animation: ios-bob 1.2s ease-in-out infinite; }
.ios-arrow .ti { font-size: 1.8rem; }
@keyframes ios-bob { 50% { transform: translateY(6px); } }

.ex-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.ex-row { display: flex; gap: 12px; padding: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); }
.ex-row > div { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.presc { font: 600 .86rem var(--font-display); color: var(--accent); font-variant-numeric: tabular-nums; }
.note { font-size: .86rem; color: var(--text); display: flex; gap: 6px; align-items: flex-start; }
.note .ti { color: var(--accent); margin-top: 2px; }
.video-link {
  color: var(--accent); font: inherit; font-size: .84rem; font-weight: 600; display: inline-flex; align-items: center; gap: 6px;
  background: var(--accent-soft); border: 1px solid var(--accent-line); border-radius: 99px; padding: 6px 12px; cursor: pointer;
  align-self: flex-start; width: fit-content; margin-top: 4px;
}
.run-ex > .video-link { margin: 0 0 10px; }
.video-frame { position: relative; width: 100%; aspect-ratio: 16 / 9; border-radius: 14px; overflow: hidden; background: #000; }
.video-frame.vertical { aspect-ratio: 9 / 16; max-height: 70vh; width: auto; margin: 0 auto; }
.video-frame iframe, .video-frame video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video-help { display: flex; gap: 10px; align-items: flex-start; }
.video-help .btn { flex: none; }
.video-help p { margin: 0; }
.lib-add { display: flex; gap: 12px; align-items: center; justify-content: space-between; flex-wrap: wrap; border-color: var(--accent-line); }
.lib-add p { margin: 2px 0 0; }

/* ---------- Aluno: execução do treino ---------- */
.run { max-width: 640px; margin: 0 auto; padding: 0 var(--gutter-r) calc(160px + var(--safe-b)) var(--gutter-l); display: flex; flex-direction: column; gap: 14px; }
.run-head {
  position: sticky; top: 0; z-index: 10; display: flex; align-items: center; gap: 10px;
  padding: calc(var(--safe-t) + 10px) 0 12px; background: rgba(5, 7, 8, .9); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  margin: 0 calc(-1 * var(--gutter-r)) 0 calc(-1 * var(--gutter-l)); padding-left: var(--gutter-l); padding-right: var(--gutter-r);
}
.run-title { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.run-title strong { font: 700 1.05rem var(--font-display); }
.run-title span { font-size: .8rem; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.run-clock { font: 600 .95rem var(--font-display); font-variant-numeric: tabular-nums; color: var(--accent); display: flex; align-items: center; gap: 6px; background: var(--accent-soft); padding: 6px 12px; border-radius: 99px; }
.run-progress { position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: var(--surface-3); }
.run-progress span { display: block; height: 100%; width: 0; background: var(--accent); transition: width .3s; box-shadow: 0 0 10px var(--accent); }
.run-list { display: flex; flex-direction: column; gap: 14px; }
.run-ex {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 16px;
  display: flex; flex-direction: column; gap: 10px; scroll-margin-top: 90px; transition: border-color .2s;
}
.run-ex.complete { border-color: rgba(52, 211, 153, .35); }
.run-ex.complete .ed-n { background: var(--ok); color: #04241a; }
.run-ex header { display: flex; align-items: center; gap: 12px; }
.run-ex h3 { font-size: 1.05rem; }
.last { font-size: .8rem; color: var(--muted); font-variant-numeric: tabular-nums; }
.sets { display: flex; flex-direction: column; gap: 6px; }
.set-row { display: grid; grid-template-columns: 44px 1fr 1fr 52px; gap: 8px; align-items: center; }
.set-row.head { font-size: .7rem; color: var(--faint); font-weight: 600; text-transform: uppercase; letter-spacing: .08em; }
.set-row.head span:not(:first-child) { text-align: center; }
.set-n { font: 700 .95rem var(--font-display); color: var(--muted); text-align: center; }
.set-row input { text-align: center; font: 600 1.05rem var(--font-display) !important; font-variant-numeric: tabular-nums; padding: 8px 4px !important; height: 48px; }
.set-check {
  height: 48px; border-radius: 12px; border: 1px solid var(--line-strong); background: var(--surface-2);
  color: var(--faint); font-size: 1.3rem; display: grid; place-items: center; transition: all .15s;
}
.set-row.done .set-check { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.set-row.done input { border-color: transparent; background: var(--accent-soft); color: var(--accent); }
.set-row.done .set-n { color: var(--accent); }
.add-set { font-size: .84rem; align-self: flex-start; padding: 4px 0; }
.run-foot {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 15; display: flex; flex-direction: column; gap: 10px;
  padding: 12px var(--gutter-r) calc(12px + var(--safe-b)) var(--gutter-l);
  background: linear-gradient(transparent, var(--bg) 22%);
}
.run-foot > * { max-width: 608px; width: 100%; margin: 0 auto; }
.rest {
  display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 18px;
  background: var(--surface-3); border: 1px solid var(--accent-line); box-shadow: 0 10px 30px rgba(0, 0, 0, .5);
}
.rest.over { border-color: var(--ok); }
.rest.over .rest-txt b { color: var(--ok); }
.rest-ring { width: 44px; height: 44px; flex: none; }
.rest-ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.rr-bg { fill: none; stroke: var(--surface); stroke-width: 4; }
.rr-fg { fill: none; stroke: var(--accent); stroke-width: 4; stroke-linecap: round; transition: stroke-dashoffset .5s linear; }
.rest-txt { flex: 1; display: flex; flex-direction: column; line-height: 1.1; }
.rest-txt span { font-size: .72rem; color: var(--muted); text-transform: uppercase; letter-spacing: .08em; font-weight: 600; }
.rest-txt b { font: 700 1.5rem var(--font-display); font-variant-numeric: tabular-nums; color: var(--accent); }
.rest .btn { padding: 0 10px; }
.sum-row { display: flex; gap: 16px; color: var(--muted); }
.sum-row b { color: var(--text); font: 700 1.2rem var(--font-display); }

.done-screen { align-items: center; text-align: center; padding-top: 48px; }
.done-mark {
  width: 96px; height: 96px; border-radius: 50%; display: grid; place-items: center; font-size: 3rem;
  background: var(--accent); color: var(--accent-ink); box-shadow: 0 0 60px rgba(0, 212, 255, .45);
  animation: pop .5s cubic-bezier(.2, 1.4, .4, 1);
}
@keyframes pop { from { transform: scale(.5); } to { transform: scale(1); } }
.done-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; width: 100%; }
.done-stats div { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 14px 8px; display: flex; flex-direction: column; }
.done-stats b { font: 700 1.6rem var(--font-display); font-variant-numeric: tabular-nums; }
.done-stats span { font-size: .78rem; color: var(--muted); }
.prs { width: 100%; text-align: left; background: var(--surface); border: 1px solid var(--accent-line); border-radius: var(--r-lg); padding: 14px 16px; display: flex; flex-direction: column; gap: 8px; }
.pr-row { display: flex; justify-content: space-between; gap: 10px; font-size: .92rem; }
.pr-row b { color: var(--accent); font-family: var(--font-display); }

/* ---------- Gráficos ---------- */
.chart { width: 100%; max-width: 720px; height: auto; display: block; overflow: visible; margin: 0 auto; }
.chart .grid { stroke: var(--line); stroke-width: 1; }
.chart .axis { fill: var(--faint); font-size: 12px; font-family: var(--font-body); }
.chart .line { fill: none; stroke: var(--accent); stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round; }
.chart .dot { fill: var(--accent); }
.chart .dot-last { fill: var(--bg); stroke: var(--accent); stroke-width: 3; }
.chart .value { fill: var(--text); font: 600 13px var(--font-display); }
.chart-empty { color: var(--muted); font-size: .88rem; padding: 20px 0; text-align: center; }
.chart .line.thin { stroke-width: 1.5; stroke-opacity: .55; }
.chart .trend { fill: none; stroke: var(--ok); stroke-width: 2.5; stroke-dasharray: 6 4; stroke-linecap: round; }
.evo-gate { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; padding: 10px 12px; border-radius: 12px; background: var(--accent-soft, rgba(0,212,255,.08)); }
.evo-gate p { margin: 0; display: flex; align-items: center; gap: 6px; }
.evo-locked { display: flex; gap: 12px; align-items: flex-start; }
.evo-locked > .ti { font-size: 1.5rem; color: var(--muted); }
.evo-locked h2 { margin: 0 0 4px; }
.evo-ctrl { display: flex; flex-wrap: wrap; gap: 8px; justify-content: space-between; }
.evo-legend { display: flex; gap: 14px; font-size: .78rem; color: var(--muted); }
.evo-legend i { display: inline-block; width: 16px; height: 0; border-top: 2.5px solid var(--accent); vertical-align: middle; margin-right: 5px; }
.evo-legend i.t { border-top: 2.5px dashed var(--ok); }
.evo-deltas { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.evo-deltas div { background: var(--surface-2, rgba(255,255,255,.04)); border-radius: 12px; padding: 10px; text-align: center; }
.evo-deltas b { display: block; font: 600 1.1rem var(--font-display); font-variant-numeric: tabular-nums; }
.evo-deltas b.up { color: var(--ok); } .evo-deltas b.down { color: var(--danger, #f66); }
.evo-deltas span { font-size: .72rem; color: var(--muted); }
.pr-table { width: 100%; border-collapse: collapse; font-size: .9rem; font-variant-numeric: tabular-nums; }
.pr-table th { text-align: left; font-size: .7rem; text-transform: uppercase; letter-spacing: .08em; color: var(--faint); font-weight: 600; padding: 6px 4px; }
.pr-table td { padding: 8px 4px; border-top: 1px solid var(--line, rgba(255,255,255,.08)); }
.pr-table td:nth-child(2) { font-weight: 600; }
.pr-new { font-size: .68rem; font-weight: 700; color: var(--accent-ink, #001018); background: var(--accent); border-radius: 99px; padding: 2px 7px; margin-left: 6px; }
.chart-note { font-size: .84rem; color: var(--ok); display: flex; align-items: center; gap: 6px; }
.bars { display: grid; grid-template-columns: repeat(8, 1fr); gap: 8px; height: 130px; align-items: end; }
.bar { height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 4px; position: relative; }
.bar b { width: 100%; max-width: 32px; min-height: 3px; background: var(--accent); border-radius: 6px 6px 2px 2px; opacity: .85; }
.bar:last-child b { opacity: 1; box-shadow: 0 0 14px rgba(0, 212, 255, .4); }
.bar-v { font: 600 .75rem var(--font-display); color: var(--muted); order: -1; }
.bar small { font-size: .66rem; color: var(--faint); white-space: nowrap; }

/* ---------- Check-in e avaliação ---------- */
.ci-card, .as-card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 16px;
  display: flex; flex-direction: column; gap: 12px;
}
.ci-card.pending { border-color: rgba(251, 191, 36, .3); }
.ci-card header, .as-card header { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.as-card header > div { display: flex; flex-direction: column; gap: 2px; }
.metrics { display: flex; flex-wrap: wrap; gap: 6px; }
.metric { font-size: .78rem; color: var(--muted); background: var(--surface-2); border: 1px solid var(--line); border-radius: 99px; padding: 4px 10px; }
.metric b { color: var(--text); font-weight: 600; margin-left: 2px; }
.metric.good b { color: var(--ok); }
.metric.bad b { color: var(--danger); }
.reply { display: flex; gap: 10px; align-items: flex-end; }
.reply textarea { flex: 1; }
@media (max-width: 520px) { .reply { flex-direction: column; align-items: stretch; } }
.reply-view { background: var(--accent-soft); border-radius: var(--r); padding: 10px 14px; display: flex; flex-direction: column; gap: 4px; }
.measures { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 6px 16px; }
.mrow { display: flex; align-items: baseline; gap: 8px; font-size: .88rem; padding: 6px 0; border-bottom: 1px dashed var(--line); }
.mrow span { flex: 1; color: var(--muted); }
.mrow b { font-variant-numeric: tabular-nums; font-weight: 600; }
.delta { font-size: .74rem; font-weight: 600; font-variant-numeric: tabular-nums; }
.delta.down { color: var(--accent); }
.delta.up { color: var(--warn); }
.photo-grid, .photo-slots { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; max-width: 480px; }
.photo { position: relative; aspect-ratio: 3/4; border-radius: var(--r); overflow: hidden; background: var(--surface-2); max-width: 100%; }
.photo img { width: 100%; height: 100%; object-fit: cover; }
.photo span { position: absolute; left: 8px; bottom: 8px; font-size: .72rem; font-weight: 600; background: rgba(0, 0, 0, .65); padding: 2px 8px; border-radius: 99px; }
.slot { display: flex; flex-direction: column; gap: 6px; align-items: center; font-size: .82rem; color: var(--muted); cursor: pointer; }
.slot-img {
  width: 100%; aspect-ratio: 3/4; max-width: 100%; border-radius: var(--r); display: grid; place-items: center; overflow: hidden;
  border: 1px dashed var(--line-strong); background: var(--surface-2); font-size: 1.8rem; color: var(--faint);
}
.slot-img img { width: 100%; height: 100%; object-fit: cover; }
.slot.filled .slot-img { border-style: solid; border-color: var(--accent-line); }
.slot:hover .slot-img { border-color: var(--accent); color: var(--accent); }
.as-request { background: var(--accent-soft); border: 1px solid var(--accent-line); border-radius: var(--r); padding: 12px 14px; display: flex; flex-direction: column; gap: 6px; }
.ex-group { display: flex; flex-direction: column; gap: 8px; }
.ex-group h3 { color: var(--muted); }
.ex-group h3 span { color: var(--faint); }
#exList { display: flex; flex-direction: column; gap: 18px; }

/* ---------- v2: feedbacks, engajamento, anamnese, presencial ---------- */
.t-danger { color: var(--danger); font-weight: 600; }
.t-warn { color: var(--warn); font-weight: 600; }
.plan-line { color: var(--muted); display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.plan-line .ti { color: var(--accent); }
.ph-stat small { font-size: .7rem; color: var(--faint); }
.form-sub { font-size: .9rem; margin-top: 6px; color: var(--accent); }
.hint { display: flex; align-items: center; gap: 6px; }
.hint .ti { color: var(--accent); }
.ed-summary .mus { color: var(--text); border-color: var(--accent-line); background: var(--accent-soft); }
.ed-summary .mus b { color: var(--accent); font-weight: 600; }
.icon-btn.play { color: var(--accent); }
.icon-btn.play:hover { background: var(--accent-soft); color: var(--accent); }
.fb-form { padding: 0 18px 14px 66px; }
.fb-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
@media (max-width: 520px) { .fb-form, .session-detail { padding-left: 18px; } }
.list.gap details.row-item .fb-form, .page > .list details.row-item .fb-form { padding-left: 18px; }
.an-sec { display: flex; flex-direction: column; gap: 2px; }
.an-sec + .an-sec { margin-top: 10px; }
.an-sec h3 { margin-bottom: 4px; }
.an-row { display: flex; justify-content: space-between; gap: 16px; padding: 8px 0; border-bottom: 1px dashed var(--line); font-size: .9rem; }
.an-row span { color: var(--muted); min-width: 0; flex: 1 1 55%; }
.an-row b { font-weight: 500; text-align: right; flex: 0 1 auto; max-width: 45%; overflow-wrap: break-word; }
.an-row.flag b { color: var(--warn); }
.an-row.flag span::before { content: '● '; color: var(--warn); }
.chip-check input { position: absolute; opacity: 0; pointer-events: none; }
.chip-check span { display: inline-block; padding: 8px 14px; border-radius: 99px; background: var(--surface-2); border: 1px solid var(--line-strong); font-size: .86rem; color: var(--muted); cursor: pointer; }
.chip-check input:checked + span { background: var(--accent-soft); border-color: var(--accent-line); color: var(--accent); }
.chip-check input:focus-visible + span { outline: 2px solid var(--accent); }
.field.yn .seg { max-width: 220px; }
#anForm .panel h2 { font-size: 1rem; }
.task-card.strong { background: var(--accent-soft); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* ===== Relatório técnico (PDF) ===== */
#print-root { display: none; }
body.printing #print-root { display: block; position: fixed; inset: 0; z-index: 9999; overflow: auto; background: #050708; }
.rp-bar { position: sticky; top: 0; z-index: 2; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 10px max(12px, env(safe-area-inset-left)); padding-top: max(10px, env(safe-area-inset-top)); background: rgba(5,7,8,.92); backdrop-filter: blur(8px); border-bottom: 1px solid rgba(255,255,255,.08); }
.rp-status { flex: 1; display: inline-flex; align-items: center; gap: 8px; font-size: .88rem; color: var(--muted); min-width: 120px; }
.rp-preview { display: flex; flex-direction: column; align-items: center; gap: 14px; padding: 14px; }
.rp-preview img { width: 100%; max-width: 794px; border-radius: 6px; box-shadow: 0 6px 30px rgba(0,0,0,.6); }

.report { --c: #00d4ff; --bg: #050708; --card: #0c1316; --line: rgba(255,255,255,.09); --dim: rgba(255,255,255,.58); color: #f2f6f7; font-family: var(--font-body); }
.report .dim { color: var(--dim); }
.rp-page { position: relative; overflow: hidden; width: 794px; min-height: 1123px; margin: 0 auto 16px; padding: 48px 52px 64px; box-sizing: border-box; display: flex; flex-direction: column; gap: 22px;
  background: radial-gradient(90% 45% at 100% 0%, rgba(0,212,255,.10), transparent 60%), radial-gradient(70% 40% at 0% 100%, rgba(0,212,255,.06), transparent 60%), var(--bg); }
.rp-page > *:not(.rp-waves) { position: relative; z-index: 1; }
.rp-waves { position: absolute; width: 340px; height: 520px; fill: none; stroke: var(--c); stroke-width: .8; opacity: .55; z-index: 0; }
.rp-waves.tl { top: -60px; left: -110px; }
.rp-waves.br { bottom: -70px; right: -120px; transform: rotate(180deg); }
.rp-waves.soft { opacity: .22; }
.rp-top { display: flex; align-items: center; justify-content: space-between; }
.rp-brand { display: flex; align-items: center; gap: 10px; }
.rp-brand b { display: block; font: italic 800 21px/1 var(--font-display); }
.rp-brand b i { color: var(--c); font-style: inherit; }
.rp-brand small { display: block; font: 600 8.5px var(--font-body); letter-spacing: .22em; color: var(--dim); margin-top: 3px; }
.rp-mark { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; background: var(--c); font-size: 21px; box-shadow: 0 0 20px rgba(0,212,255,.45); }
.rp-mark .ti { color: #00161c !important; }
.rp-pill { display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px; border-radius: 99px; border: 1px solid var(--line); background: rgba(255,255,255,.04); font: 600 9.5px var(--font-body); letter-spacing: .16em; color: var(--c); }
.rp-pill i { width: 7px; height: 7px; border-radius: 50%; background: var(--c); box-shadow: 0 0 8px var(--c); }
.rp-eyebrow { font: 600 11px var(--font-body); letter-spacing: .16em; color: var(--dim); text-transform: uppercase; margin: 0; }
.rp-h2 { font: 900 26px/1.1 var(--font-display); margin: 0; letter-spacing: -.01em; }
.rp-h2 span, .rp-cover h1 span, .rp-tagline span { color: var(--c); }
.rp-text { font-size: 13.5px; line-height: 1.7; color: rgba(255,255,255,.82); margin: 0; }
.rp-pfoot { position: absolute !important; left: 52px; right: 52px; bottom: 26px; display: flex; justify-content: space-between; font-size: 9.5px; color: var(--dim); border-top: 1px solid var(--line); padding-top: 10px; }

/* capa */
.rp-cover { justify-content: space-between; }
.rp-cover-main { margin: auto 0; display: flex; flex-direction: column; gap: 14px; }
.rp-cover h1 { font: 900 78px/.95 var(--font-display); letter-spacing: -.03em; margin: 6px 0 0; }
.rp-sub { font-size: 16px; color: var(--dim); margin: 0; }
.rp-namecard { margin-top: 26px; align-self: flex-start; min-width: 60%; padding: 18px 22px; border-radius: 16px; background: linear-gradient(135deg, rgba(0,212,255,.16), rgba(0,212,255,.03)); border: 1px solid rgba(0,212,255,.35); }
.rp-namecard small { font: 600 9px var(--font-body); letter-spacing: .2em; color: var(--c); }
.rp-namecard b { display: block; font: 800 30px/1.15 var(--font-display); margin: 4px 0; }
.rp-namecard span { font-size: 13px; color: var(--dim); }
.rp-cover-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.rp-cover-stats div, .rp-kpis div { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 16px 10px; text-align: center; }
.rp-cover-stats b, .rp-kpis b { display: block; font: 800 28px var(--font-display); color: var(--c); }
.rp-kpis b small { font-size: 15px; color: var(--dim); }
.rp-cover-stats span, .rp-kpis span { font: 600 8.5px var(--font-body); letter-spacing: .16em; color: var(--dim); }
.rp-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }

/* resumo */
.rp-facts { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.rp-facts div { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 14px 16px; }
.rp-facts small, .rp-obs small, .rp-analysis small, .rp-method small { font: 600 8.5px var(--font-body); letter-spacing: .18em; color: var(--c); }
.rp-facts b { display: block; font: 700 17px var(--font-display); margin-top: 5px; }
.rp-obs { border-left: 3px solid var(--c); background: rgba(0,212,255,.06); border-radius: 0 14px 14px 0; padding: 16px 20px; }
.rp-obs ul { margin: 8px 0 0; padding-left: 18px; font-size: 13.5px; line-height: 1.75; }
.rp-obs li::marker { color: var(--c); }

/* treino */
.rp-wk { display: flex; align-items: center; gap: 14px; }
.rp-wk > div:nth-child(2) { flex: 1; }
.rp-wk p { margin: 3px 0 0; font-size: 12.5px; }
.rp-wk-badge { width: 52px; height: 52px; border-radius: 14px; display: grid; place-items: center; background: var(--c); color: #00161c; font: 900 26px var(--font-display); box-shadow: 0 0 22px rgba(0,212,255,.4); }
.rp-wk-avg { text-align: right; }
.rp-wk-avg b { display: block; font: 900 30px/1 var(--font-display); color: #34d399; }
.rp-wk-avg span { font-size: 10px; letter-spacing: .14em; text-transform: uppercase; color: var(--dim); }
.rp-table { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 12px; background: var(--card); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; }
.rp-table th { background: rgba(0,212,255,.12); color: var(--c); font: 700 8.5px var(--font-body); letter-spacing: .14em; text-transform: uppercase; text-align: center; padding: 10px 8px; }
.rp-table th:first-child, .rp-table td.name { text-align: left; padding-left: 14px; }
.rp-table td { padding: 8px; text-align: center; border-top: 1px solid var(--line); font-variant-numeric: tabular-nums; }
.rp-table td.name { font-weight: 600; }
.rp-table td.strong { font-weight: 800; color: #fff; }
.rp-table tr:nth-child(even) td { background: rgba(255,255,255,.02); }
.rp-tag { display: inline-block; padding: 3px 9px; border-radius: 99px; font-size: 10.5px; font-weight: 700; background: rgba(255,255,255,.07); color: var(--dim); }
.rp-tag.up { background: rgba(52,211,153,.14); color: #34d399; }
.rp-tag.down { background: rgba(248,113,113,.14); color: #f87171; }
.rp-bars { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 14px 16px; display: flex; flex-direction: column; gap: 9px; }
.rp-bars-legend { display: flex; gap: 16px; justify-content: flex-end; font-size: 10px; color: var(--dim); }
.rp-bars-legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 5px; vertical-align: -1px; }
.rp-bars-legend i.s, .rp-bar.s { background: rgba(0,212,255,.28); }
.rp-bars-legend i.e, .rp-bar.e { background: var(--c); }
.rp-bar-row { display: grid; grid-template-columns: 170px 1fr; gap: 12px; align-items: center; }
.rp-bar-name { font-size: 11px; color: rgba(255,255,255,.85); line-height: 1.25; }
.rp-bar-track { display: flex; flex-direction: column; gap: 3px; }
.rp-bar { height: 13px; border-radius: 0 6px 6px 0; position: relative; min-width: 4px; }
.rp-bar b { position: absolute; left: calc(100% + 6px); top: 50%; transform: translateY(-50%); font-size: 10px; white-space: nowrap; color: var(--dim); }
.rp-bar.e b { color: #fff; font-weight: 700; }
.rp-analysis { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 16px 20px; font-size: 12.5px; line-height: 1.65; }
.rp-analysis p { margin: 6px 0 0; }
.rp-hl { margin: 8px 0 0; padding-left: 18px; }
.rp-hl li::marker { color: var(--c); }

/* fechamento */
.rp-note { background: linear-gradient(135deg, rgba(0,212,255,.14), rgba(0,212,255,.02)); border: 1px solid rgba(0,212,255,.3); border-radius: 18px; padding: 26px 28px; }
.rp-note p { font-size: 16px; line-height: 1.7; margin: 0; white-space: pre-line; }
.rp-sign { margin-top: 18px; display: flex; flex-direction: column; }
.rp-sign b { font: italic 800 20px var(--font-display); color: var(--c); }
.rp-sign span { font-size: 11px; color: var(--dim); letter-spacing: .12em; text-transform: uppercase; }
.rp-method { border-top: 1px solid var(--line); padding-top: 16px; }
.rp-method p { font-size: 11px; line-height: 1.6; color: var(--dim); margin: 6px 0 0; }
.rp-tagline { margin-top: auto; margin-bottom: 20px; text-align: center; font: 900 34px var(--font-display); letter-spacing: -.01em; }.rp-wk-badge { display: block; text-align: center; line-height: 52px; }
.rp-mark { display: block; text-align: center; line-height: 36px; }
.rp-tag { line-height: 16px; padding: 2px 9px 4px; }
.rp-pill { line-height: 14px; padding: 5px 14px 7px; }
.rp-waves { opacity: .9; stroke-width: 1.1; }
.rp-waves.soft { opacity: .35; }
.rp-cover h1 { line-height: 1.02; }
.rp-sub { margin-top: 8px; }
.rp-mark { display: flex; align-items: center; justify-content: center; line-height: 0; }
.rp-mark svg { display: block; }
.rp-wk-badge { width: 52px; height: 52px; flex: none; display: block; background: none; border-radius: 14px; filter: drop-shadow(0 0 12px rgba(0,212,255,.45)); }
.rp-note { background: linear-gradient(135deg, rgba(0,212,255,.16), rgba(0,212,255,.03)), #0c1316; }
.rp-obs, .rp-analysis, .rp-facts div, .rp-kpis div, .rp-cover-stats div, .rp-namecard, .rp-table, .rp-bars { background-color: #0c1316; }
.rp-obs { background: linear-gradient(rgba(0,212,255,.06), rgba(0,212,255,.06)), #0c1316; }
.rp-namecard { background: linear-gradient(135deg, rgba(0,212,255,.16), rgba(0,212,255,.03)), #0c1316; }
.rp-tagline { margin: auto 0 40px; display: flex; flex-direction: column; align-items: center; gap: 14px; font: 900 44px/1.08 var(--font-display); letter-spacing: -.02em; }
.rp-tagline small { font: 600 10px var(--font-body); letter-spacing: .3em; color: var(--dim); }
