/* Metabolic Map — tema "Ethereal Slate Glass" (tokens do handover de UX/UI). Só tema escuro. */
:root {
  color-scheme: dark;
  --bg: #10131a; --bg-low: #0b0e15; --surface: rgba(25, 28, 34, .68); --surface-2: rgba(39, 42, 49, .7); --surface-solid: #191c22;
  --ink: #e0e2ec; --ink-2: #bac9cc; --ink-3: #859396; --line: rgba(255, 255, 255, .08); --line-2: rgba(255, 255, 255, .15);
  --brand: #00daf3; --brand-2: #00e5ff; --brand-ink: #00363d; --brand-soft: rgba(0, 218, 243, .12); --ice: #c3f5ff;
  --verde: #00e676; --verde-bg: rgba(0, 230, 118, .12); --amarelo: #ffb300; --amarelo-bg: rgba(255, 179, 0, .12);
  --vermelho: #ff5252; --vermelho-bg: rgba(255, 82, 82, .12); --cinza: #94a3b8; --cinza-bg: rgba(100, 116, 139, .16);
  --radius: 16px; --display: "Space Grotesk", "Plus Jakarta Sans", system-ui, sans-serif; --body: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { background: var(--bg-low); color: var(--ink); font: 15px/1.5 var(--body); -webkit-font-smoothing: antialiased; }
h1, h2, h3, p { margin: 0; }
h1 { font: 700 1.6rem/1.2 var(--display); letter-spacing: -.02em; text-wrap: balance; }
h2 { font: 600 1.1rem/1.3 var(--display); letter-spacing: -.01em; }
h3 { font: 600 .68rem/1.3 var(--body); text-transform: uppercase; letter-spacing: .12em; color: var(--brand); margin: 22px 4px 10px; }
a { color: var(--brand); }
.app { max-width: 460px; margin: 0 auto; min-height: 100%; display: flex; flex-direction: column; position: relative;
  background: radial-gradient(120% 50% at 50% 0%, rgba(0, 218, 243, .07), transparent 60%),
    linear-gradient(rgba(255, 255, 255, .018) 1px, transparent 1px) 0 0 / 28px 28px, linear-gradient(90deg, rgba(255, 255, 255, .018) 1px, transparent 1px) 0 0 / 28px 28px, var(--bg); }
.top { position: sticky; top: 0; z-index: 5; display: flex; align-items: center; gap: 10px; padding: calc(10px + env(safe-area-inset-top)) 14px 10px; min-height: 58px;
  background: rgba(16, 19, 26, .78); -webkit-backdrop-filter: blur(18px); backdrop-filter: blur(18px); border-bottom: 1px solid var(--line); }
.top h2 { flex: 1; font-size: 1.05rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.top .brand { flex: 1; display: flex; align-items: center; gap: 8px; font: 700 1.05rem var(--display); color: var(--brand); text-decoration: none; }
.top .brand svg { width: 20px; height: 20px; }
.icon-btn { width: 40px; height: 40px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); color: var(--ink-2); display: grid; place-items: center; cursor: pointer; text-decoration: none; font-size: 1.3rem; flex: none; }
.icon-btn.round { border-radius: 50%; }
.icon-btn svg { width: 20px; height: 20px; }
.icon-btn:hover { color: var(--brand); border-color: var(--line-2); }
main { flex: 1; padding: 14px 14px 28px; }
.page-title { padding: 16px 16px 0; }
.page-title h1 { font-size: 1.45rem; }
.tabs { position: sticky; bottom: 0; z-index: 5; display: flex; align-items: center; background: rgba(16, 19, 26, .86); -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px); border-top: 1px solid var(--line); padding-bottom: env(safe-area-inset-bottom); }
.tabs a { flex: 1; min-height: 60px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; font-size: .66rem; font-weight: 600; letter-spacing: .02em; color: var(--ink-3); text-decoration: none; }
.tabs a svg { width: 21px; height: 21px; }
.tabs a.on { color: var(--brand); text-shadow: 0 0 12px rgba(0, 218, 243, .5); }
.tabs a.plus span.dot { width: 44px; height: 44px; border-radius: 50%; background: linear-gradient(135deg, #22d3ee, var(--brand-2)); color: var(--brand-ink); display: grid; place-items: center; font-size: 1.6rem; font-weight: 500; line-height: 1; box-shadow: 0 0 18px rgba(0, 229, 255, .45); }
.tabs a.plus > span:last-child { display: none; }
.card, .list, details.card { background: var(--surface); border: 1px solid var(--line); border-top-color: var(--line-2); border-radius: var(--radius); -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); box-shadow: 0 8px 28px rgba(0, 0, 0, .28); margin-bottom: 12px; }
.card { padding: 16px; }
.card.link { display: block; color: inherit; text-decoration: none; }
.card.glow { border-color: rgba(0, 218, 243, .35); box-shadow: 0 0 0 1px rgba(0, 218, 243, .08), 0 8px 28px rgba(0, 0, 0, .28), inset 0 0 40px rgba(0, 218, 243, .04); }
.row { display: flex; align-items: center; gap: 12px; }
.row > .grow { flex: 1; min-width: 0; }
.between { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.muted { color: var(--ink-2); font-size: .86rem; }
.small { font-size: .76rem; }
.eyebrow { font: 600 .66rem var(--body); letter-spacing: .12em; text-transform: uppercase; color: var(--brand); }
.big { font: 700 1.9rem/1.1 var(--display); letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.big .muted, .big span.muted { font: 500 .8rem var(--body); letter-spacing: 0; }
.num { font-variant-numeric: tabular-nums; }
td.num { white-space: nowrap; }
.stack > * + * { margin-top: 12px; }
.center { display: grid; place-items: center; min-height: 50vh; text-align: center; padding: 24px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 50px; padding: 0 20px; border-radius: 14px; border: 1px solid transparent; background: linear-gradient(135deg, #22d3ee, var(--brand-2)); color: var(--brand-ink); font: 700 .95rem var(--body); cursor: pointer; text-decoration: none; width: 100%; box-shadow: 0 0 22px rgba(0, 229, 255, .28); }
.btn:hover { filter: brightness(1.06); }
.btn.ghost { background: var(--surface); color: var(--ink); border-color: var(--line-2); box-shadow: none; font-weight: 600; }
.btn.soft { background: var(--brand-soft); color: var(--brand); border-color: rgba(0, 218, 243, .28); box-shadow: none; }
.btn.danger { background: var(--vermelho); color: #2a0606; box-shadow: 0 0 18px rgba(255, 82, 82, .3); }
.btn.danger-ghost { background: var(--vermelho-bg); color: var(--vermelho); border-color: rgba(255, 82, 82, .35); box-shadow: none; font-weight: 600; }
.btn.sm { min-height: 38px; padding: 0 14px; width: auto; font-size: .82rem; border-radius: 10px; }
.btn.xl { min-height: 62px; font-size: 1.1rem; border-radius: 999px; }
.btn:disabled { opacity: .4; cursor: not-allowed; box-shadow: none; }
.btn:focus-visible, .icon-btn:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, .opt:focus-within, a:focus-visible, .chip:focus-visible, .stepper button:focus-visible { outline: 2px solid var(--ice); outline-offset: 2px; }
.btns { display: flex; gap: 8px; flex-wrap: wrap; }
.btns .btn { flex: 1; }
label.f { display: block; margin-bottom: 14px; }
label.f > span { display: block; font-size: .82rem; font-weight: 600; margin-bottom: 6px; color: var(--ink); }
label.f > small { display: block; color: var(--ink-3); font-size: .74rem; margin-top: 5px; }
input[type=text], input[type=email], input[type=password], input[type=number], input[type=date], input[type=time], input[type=search], select, textarea {
  width: 100%; min-height: 48px; padding: 10px 14px; border-radius: 12px; border: 1px solid var(--line); background: rgba(11, 14, 21, .6); color: var(--ink); font: inherit; }
input::placeholder, textarea::placeholder { color: var(--ink-3); }
input:focus, select:focus, textarea:focus { border-color: rgba(0, 218, 243, .6); box-shadow: 0 0 0 3px rgba(0, 218, 243, .12); outline: none; }
select option { background: #191c22; }
textarea { min-height: 84px; resize: vertical; }
.check { display: flex; gap: 12px; align-items: flex-start; padding: 9px 0; font-size: .88rem; }
.check input, .opt input, input[role=switch] { accent-color: var(--brand-2); }
.check input { width: 20px; height: 20px; margin-top: 1px; flex: none; }
.opt { display: flex; align-items: center; gap: 12px; padding: 14px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); margin-bottom: 8px; cursor: pointer; }
.opt input { width: 18px; height: 18px; flex: none; }
.opt:has(input:checked) { border-color: var(--brand); background: var(--brand-soft); box-shadow: 0 0 16px rgba(0, 218, 243, .12); }
.seg { display: flex; gap: 6px; flex-wrap: wrap; }
.seg label { flex: 1; min-width: 40px; }
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg span { display: grid; place-items: center; min-height: 44px; padding: 0 6px; border: 1px solid var(--line); border-radius: 10px; background: rgba(11, 14, 21, .5); color: var(--ink-2); cursor: pointer; font: 600 .84rem var(--body); text-align: center; }
.seg input:checked + span { background: var(--brand-2); color: var(--brand-ink); border-color: var(--brand-2); box-shadow: 0 0 14px rgba(0, 229, 255, .4); }
.seg input:focus-visible + span { outline: 2px solid var(--ice); outline-offset: 2px; }
.chips { display: flex; gap: 8px; overflow-x: auto; padding: 2px 0 12px; scrollbar-width: none; }
.chip { flex: none; padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--ink-2); font: 600 .8rem var(--body); cursor: pointer; text-decoration: none; }
.chip.on { background: var(--brand-2); color: var(--brand-ink); border-color: var(--brand-2); }
.pill { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 999px; font-size: .7rem; font-weight: 700; white-space: nowrap; border: 1px solid currentColor; }
.pill::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; box-shadow: 0 0 6px currentColor; }
.c-verde { color: var(--verde); background: var(--verde-bg); } .c-amarelo { color: var(--amarelo); background: var(--amarelo-bg); }
.c-vermelho { color: var(--vermelho); background: var(--vermelho-bg); } .c-cinza { color: var(--cinza); background: var(--cinza-bg); }
.pill.c-verde, .pill.c-amarelo, .pill.c-vermelho, .pill.c-cinza { border-color: color-mix(in srgb, currentColor 40%, transparent); }
.list { overflow: hidden; }
.item { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border: 0; border-bottom: 1px solid var(--line); color: inherit; text-decoration: none; min-height: 58px; width: 100%; background: none; font: inherit; text-align: left; cursor: pointer; }
.item:last-child { border-bottom: 0; }
a.item:hover, button.item:hover { background: rgba(255, 255, 255, .03); }
.item .grow { flex: 1; min-width: 0; }
.item .t { font-weight: 600; overflow-wrap: anywhere; }
.item .chev { color: var(--ink-3); }
.bar { height: 6px; border-radius: 999px; background: rgba(255, 255, 255, .08); overflow: hidden; }
.bar > i { display: block; height: 100%; background: linear-gradient(90deg, #22d3ee, var(--brand-2)); border-radius: 999px; box-shadow: 0 0 10px rgba(0, 229, 255, .6); transition: width .3s; }
.note { font-size: .74rem; color: var(--ink-3); padding: 12px 4px; }
.banner { border-radius: 14px; padding: 12px 14px; font-size: .86rem; margin-bottom: 12px; background: var(--surface); border: 1px solid var(--line); }
.banner.warn { background: var(--amarelo-bg); border-color: rgba(255, 179, 0, .35); }
.banner.bad { background: var(--vermelho-bg); border-color: rgba(255, 82, 82, .35); }
.banner.good { background: var(--verde-bg); border-color: rgba(0, 230, 118, .35); }
.err { color: var(--vermelho); font-size: .84rem; margin: 8px 0; min-height: 1.2em; }
.spinner { width: 34px; height: 34px; border-radius: 50%; border: 3px solid var(--line); border-top-color: var(--brand); animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes pulse { 0%, 100% { opacity: .55; transform: scale(1); } 50% { opacity: 1; transform: scale(1.25); } }
@media (prefers-reduced-motion: reduce) { .spinner { animation-duration: 3s; } .bar > i { transition: none; } .pin i { animation: none !important; } }
.toast { position: fixed; left: 50%; bottom: 88px; transform: translate(-50%, 20px); background: #272a31; color: var(--ink); border: 1px solid var(--line-2); padding: 12px 18px; border-radius: 14px; font-size: .86rem; opacity: 0; pointer-events: none; transition: .2s; max-width: 90vw; z-index: 30; box-shadow: 0 10px 30px rgba(0, 0, 0, .5); }
.toast.on { opacity: 1; transform: translate(-50%, 0); }
.sheet-wrap { position: fixed; inset: 0; background: rgba(4, 6, 10, .7); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); display: flex; align-items: flex-end; justify-content: center; z-index: 20; }
.sheet-wrap[hidden] { display: none; }
.sheet { background: #191c22; border: 1px solid var(--line-2); width: 100%; max-width: 460px; border-radius: 22px 22px 0 0; padding: 22px 18px calc(18px + env(safe-area-inset-bottom)); }
/* Boas-vindas */
.hero { padding: 36px 8px 22px; text-align: center; }
.logo { width: 132px; height: 132px; border-radius: 28px; background: radial-gradient(circle at 50% 35%, #12303a, #0b0e15 75%); border: 1px solid rgba(0, 218, 243, .35); color: var(--brand-2); display: grid; place-items: center; margin: 0 auto 26px; box-shadow: 0 0 60px rgba(0, 218, 243, .22), inset 0 0 30px rgba(0, 218, 243, .1); }
.wordmark { font: 700 1.5rem var(--display); letter-spacing: .22em; text-transform: uppercase; }
.wordmark b { color: var(--brand); font-weight: 700; }
.tagline { display: inline-block; margin-top: 12px; padding: 6px 14px; border-radius: 999px; border: 1px solid rgba(0, 218, 243, .35); background: var(--brand-soft); color: var(--brand); font: 700 .64rem var(--body); letter-spacing: .12em; text-transform: uppercase; }
/* Mapa corporal */
.holo-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 10px; }
.side { display: flex; gap: 2px; padding: 2px; border: 1px solid var(--line); border-radius: 10px; background: rgba(11, 14, 21, .6); }
.side input { position: absolute; opacity: 0; pointer-events: none; }
.side span { display: block; padding: 5px 10px; border-radius: 8px; font: 600 .7rem var(--body); color: var(--ink-2); cursor: pointer; }
.side input:checked + span { background: #272a31; color: var(--brand); }
.side input:focus-visible + span { outline: 2px solid var(--ice); }
.stage { position: relative; height: 470px; display: flex; align-items: center; justify-content: center; border-radius: 14px; border: 1px solid rgba(255, 255, 255, .04); overflow: hidden; background: radial-gradient(circle at 50% 25%, #192233 0%, #10131a 75%, #0b0e15 100%); }
.stage::before { content: ""; position: absolute; width: 224px; height: 288px; background: rgba(156, 239, 255, .1); border-radius: 50%; filter: blur(60px); pointer-events: none; }
.stage::after { content: ""; position: absolute; bottom: 40px; width: 176px; height: 176px; background: rgba(166, 244, 181, .1); border-radius: 50%; filter: blur(40px); pointer-events: none; }
.stage .fig { position: relative; height: 430px; aspect-ratio: 210 / 412; overflow: hidden; }
.stage .fig img { position: absolute; top: 0; left: 0; height: 100%; width: 200%; max-width: none; filter: invert(1) sepia(1) saturate(3.2) hue-rotate(140deg) brightness(.95) drop-shadow(0 0 10px rgba(0, 218, 243, .35)); mix-blend-mode: screen; opacity: .85; pointer-events: none; user-select: none; }
.holo:has(.side input[value=d]:checked) .fig img { left: -100%; }
.pin { position: absolute; display: flex; align-items: center; gap: 6px; text-decoration: none; z-index: 2; white-space: nowrap; }
.pin.l { flex-direction: row-reverse; }
.pin i { width: 10px; height: 10px; border-radius: 50%; background: currentColor; border: 1px solid rgba(255, 255, 255, .7); box-shadow: 0 0 10px currentColor; flex: none; animation: pulse 3.5s ease-in-out infinite; }
.pin span { display: inline-flex; align-items: center; gap: 6px; padding: 3px 4px 3px 9px; border-radius: 999px; background: rgba(29, 32, 39, .92); border: 1px solid color-mix(in srgb, currentColor 45%, transparent); font: 700 .68rem var(--body); box-shadow: 0 4px 14px rgba(0, 0, 0, .45); }
.pin b { color: var(--ink); background: color-mix(in srgb, currentColor 22%, transparent); padding: 1px 6px; border-radius: 999px; font: 700 .68rem var(--display); }
.pin.t-verde { color: var(--verde); } .pin.t-amarelo { color: var(--amarelo); } .pin.t-vermelho { color: var(--vermelho); } .pin.t-cinza { color: var(--cinza); }
.pin.whole { left: 50%; bottom: 16px; transform: translateX(-50%); }
.pin.whole span { padding: 6px 6px 6px 12px; }
.legend { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 10px; font-size: .7rem; color: var(--ink-2); }
.legend i { display: inline-block; width: 7px; height: 7px; border-radius: 50%; margin-right: 5px; }
.f-verde { fill: var(--verde); } .f-amarelo { fill: var(--amarelo); } .f-vermelho { fill: var(--vermelho); } .f-cinza { fill: var(--cinza); }
.s-verde { stroke: var(--verde); } .s-amarelo { stroke: var(--amarelo); } .s-vermelho { stroke: var(--vermelho); } .s-cinza { stroke: var(--cinza); }
.b-verde { background: var(--verde); } .b-amarelo { background: var(--amarelo); } .b-vermelho { background: var(--vermelho); } .b-cinza { background: var(--cinza); }
.ring { flex: none; filter: drop-shadow(0 0 8px rgba(0, 218, 243, .18)); }
.ring text { fill: var(--ink); font-family: var(--display); font-weight: 700; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.grid2 .card { margin: 0; }
.timer { text-align: center; font: 700 3.4rem var(--display); font-variant-numeric: tabular-nums; color: var(--brand-2); text-shadow: 0 0 24px rgba(0, 229, 255, .45); }
.dots { display: flex; gap: 5px; flex-wrap: wrap; }
.dots i { width: 9px; height: 9px; border-radius: 50%; background: rgba(255, 255, 255, .12); }
.dots i.on { background: var(--brand-2); box-shadow: 0 0 6px var(--brand-2); } .dots i.pain { background: var(--vermelho); }
.stepper { display: flex; align-items: center; gap: 6px; padding: 8px; border: 1px solid var(--line); border-radius: 14px; background: rgba(11, 14, 21, .5); }
.stepper input { text-align: center; border: 0; background: none; font: 700 1.9rem var(--display); padding: 0; min-height: 44px; -moz-appearance: textfield; }
.stepper input::-webkit-outer-spin-button, .stepper input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.stepper input:focus { box-shadow: none; }
.stepper button { flex: none; width: 44px; height: 44px; border-radius: 10px; border: 1px solid var(--line-2); background: #272a31; color: var(--ink); font-size: 1.4rem; cursor: pointer; }
details.card summary { cursor: pointer; list-style: none; }
details.card summary::-webkit-details-marker { display: none; }
table.t { width: 100%; border-collapse: collapse; font-size: .82rem; }
table.t td, table.t th { padding: 9px 4px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
table.t tr:last-child td { border-bottom: 0; }
table.t th { color: var(--ink-3); font: 600 .64rem var(--body); letter-spacing: .08em; text-transform: uppercase; }
.scroll-x { overflow-x: auto; }
.chart text { fill: var(--ink-3); font-size: 10px; font-family: var(--body); }
.empty { text-align: center; padding: 30px 16px; color: var(--ink-2); }
.empty .btn { margin-top: 14px; }
.stat { text-align: center; flex: 1; padding: 10px 4px; border: 1px solid var(--line); border-radius: 12px; background: rgba(11, 14, 21, .45); }
.stat b { display: block; font: 700 1.25rem var(--display); }
