:root {
  --bg: #090a0b; --bg2: #0e0f10; --panel: #101112; --line: #232527; --line2: #34373a;
  --ink: #e8e9e9; --ink2: #a6aaac; --ink3: #6c7174;
  --gold: #c9cccd; --gold2: #eceeee; --gold3: #ffffff; --gold-dim: #4a4e52;
  --yellow: #f2c230;
  --danger: #d9826c; --radius: 10px; --font: "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
  --side: 224px;
}
* { box-sizing: border-box; }
html, body { height: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 15px/1.5 var(--font); -webkit-font-smoothing: antialiased; overflow: hidden; }
body.admin { overflow: auto; }
[hidden] { display: none !important; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2px solid var(--gold2); outline-offset: 2px; }
h1, h2, h3, p { margin: 0; }

.spinner { width: 34px; height: 34px; border-radius: 50%; border: 3px solid var(--line2); border-top-color: var(--gold2); animation: spin 0.9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.boot { position: fixed; inset: 0; display: grid; place-content: center; justify-items: center; gap: 14px; background: var(--bg); color: var(--ink2); z-index: 50; }

/* marca */
.brand { display: flex; align-items: center; gap: 10px; }
.brand b { letter-spacing: 0.16em; font-size: 14px; }
.brand small { display: block; color: var(--ink3); letter-spacing: 0.04em; font-size: 12px; }
.brand-mark { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 8px; background: linear-gradient(145deg, #3a3326, #17140c); border: 1px solid var(--gold-dim); color: var(--gold2); font-weight: 800; font-size: 17px; }

/* botões */
.btn { border: 1px solid var(--line2); background: #19191c; color: var(--ink); padding: 10px 16px; border-radius: 10px; font-weight: 600; transition: border-color .15s, background .15s, transform .05s; }
.btn:hover:not(:disabled) { border-color: var(--gold-dim); background: #202024; }
.btn:active:not(:disabled) { transform: translateY(1px); }
.btn:disabled { opacity: 0.45; cursor: not-allowed; }
.btn.primary { background: linear-gradient(180deg, #f0cc64, #c9a032); color: #17140a; border-color: #f6dc8a; box-shadow: 0 6px 24px rgba(212,170,63,.25); }
.btn.primary:hover:not(:disabled) { background: linear-gradient(180deg, #f6d673, #d3aa3a); }
.btn.ghost { background: transparent; }
.btn.small { padding: 6px 12px; font-size: 13px; }
.chip { border: 1px solid var(--line2); background: rgba(20,20,22,.7); color: var(--ink2); padding: 6px 12px; border-radius: 999px; font-size: 13px; }
.chip:hover { border-color: var(--gold-dim); color: var(--ink); }

/* acesso */
.auth { min-height: 100%; display: grid; place-items: center; padding: 24px 16px; background: radial-gradient(900px 500px at 70% -10%, #2a2214, transparent), var(--bg); overflow: auto; position: fixed; inset: 0; }
.auth-card { width: min(440px, 100%); background: var(--panel); border: 1px solid var(--line2); border-radius: 16px; padding: 26px; display: grid; gap: 18px; box-shadow: 0 30px 80px rgba(0,0,0,.6), 0 0 0 1px rgba(212,170,63,.08); }
.tabs { display: grid; grid-template-columns: 1fr 1fr; background: #0c0c0e; border: 1px solid var(--line); border-radius: 10px; padding: 3px; }
.tab { background: none; border: 0; padding: 9px; border-radius: 8px; color: var(--ink3); font-weight: 600; }
.tab.on { background: #1d1d20; color: var(--ink); box-shadow: inset 0 0 0 1px var(--line2); }
form { display: grid; gap: 14px; }
label { display: grid; gap: 6px; font-size: 13px; color: var(--ink2); }
input[type=text], input[type=email], input[type=password], input[type=tel], input[type=number], input[type=url], input[type=search], select, textarea { width: 100%; background: #0c0c0e; border: 1px solid var(--line2); border-radius: 9px; padding: 10px 12px; color: var(--ink); }
textarea { min-height: 76px; resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--gold-dim); outline: none; box-shadow: 0 0 0 3px rgba(212,170,63,.15); }
.err { color: var(--danger); font-size: 13px; }
.err:empty { display: none; }
.hint { color: var(--ink3); font-size: 12.5px; }
.route-pick { border: 1px solid var(--line); border-radius: 10px; padding: 12px; display: grid; gap: 8px; margin: 0; }
.route-pick legend { padding: 0 6px; color: var(--ink2); font-size: 13px; }
.radio, .check { display: flex; gap: 10px; align-items: flex-start; color: var(--ink); }
.radio small { display: block; color: var(--ink3); }
.check span { font-size: 12.5px; color: var(--ink2); line-height: 1.45; }
input[type=radio], input[type=checkbox] { accent-color: var(--gold2); margin-top: 3px; }

/* ── casca do app ── */
.app { position: fixed; inset: 0; display: grid; grid-template-columns: var(--side) minmax(0, 1fr); }
.side { display: flex; flex-direction: column; gap: 6px; padding: 18px 12px 12px; background: linear-gradient(180deg, #121211, #0b0b0c); border-right: 1px solid var(--line); position: relative; z-index: 6; min-height: 0; }
.side::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 30%; background: radial-gradient(120% 90% at 0% 100%, rgba(212,170,63,.14), transparent 70%); pointer-events: none; }
.side-brand { padding: 4px 8px 18px; }
.side-nav { display: grid; gap: 4px; align-content: start; flex: 1; }
.side-group { color: var(--ink2); font-size: 13.5px; padding: 8px 10px; display: flex; gap: 8px; }
.side-nav hr { border: 0; border-top: 1px solid var(--line); margin: 10px 6px; width: auto; }
.side-item { display: flex; align-items: center; gap: 12px; width: 100%; background: none; border: 1px solid transparent; color: var(--ink2); padding: 11px 12px; border-radius: 12px; text-align: left; font-size: 14.5px; }
.side-item:hover:not(:disabled) { background: #19191a; color: var(--ink); }
.side-item.on { background: linear-gradient(180deg, #221d10, #17140c); border-color: var(--gold-dim); color: var(--ink); box-shadow: inset 0 0 0 1px rgba(242,201,76,.12), 0 0 22px rgba(212,170,63,.12); }
.side-item span { flex: 1; }
.side-item em { font-style: normal; font-size: 12px; color: var(--ink2); border: 1px solid var(--line2); border-radius: 999px; padding: 1px 9px; background: #121213; }
.side-item.on em { color: var(--gold2); border-color: var(--gold-dim); }
.side-item.soon { opacity: .5; cursor: not-allowed; }
.side-item.soon em { font-size: 11px; border: 0; background: none; color: var(--ink3); padding: 0; }
.ico { width: 20px; height: 20px; border: 1.6px solid currentColor; border-radius: 5px; flex: none; opacity: .85; position: relative; }
.ico-route { border-radius: 5px; } .ico-route2 { border-radius: 50%; } .ico-check::after { content: ""; position: absolute; left: 6px; top: 1px; width: 5px; height: 10px; border: solid currentColor; border-width: 0 2px 2px 0; transform: rotate(45deg); } .ico-chart { border-radius: 3px; border-width: 0 0 1.6px 1.6px; } .ico-box { border-radius: 3px; transform: rotate(45deg) scale(.8); } .ico-help { border-radius: 50%; }
.side-user { position: relative; z-index: 1; display: flex; gap: 10px; align-items: center; background: #151516; border: 1px solid var(--line); border-radius: 14px; padding: 10px 12px; text-align: left; width: 100%; }
.side-user:hover { border-color: var(--gold-dim); }
.side-user > span:nth-child(2) { flex: 1; min-width: 0; }
.side-user b, .user-chip b { display: block; font-size: 14px; font-weight: 600; max-width: 130px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.side-user small, .user-chip small { color: var(--ink3); font-size: 12px; }
.avatar { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; background: radial-gradient(circle at 30% 25%, #4a4130, #17140c); border: 1.5px solid var(--gold-dim); color: var(--gold2); font-weight: 700; font-size: 14px; flex: none; }

.main { position: relative; min-width: 0; min-height: 0; overflow: hidden; }
.top { position: absolute; left: 0; right: 0; top: 0; z-index: 7; display: flex; align-items: center; justify-content: flex-end; gap: 12px; padding: 14px 22px; pointer-events: none; }
.top > * { pointer-events: auto; }
.search { position: relative; width: min(380px, 40vw); margin-right: auto; margin-left: auto; }
.search input { padding: 11px 70px 11px 16px; border-radius: 12px; background: rgba(14,14,16,.78); backdrop-filter: blur(8px); }
.search kbd { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); font: 11px var(--font); color: var(--ink3); border: 1px solid var(--line2); border-radius: 6px; padding: 2px 6px; pointer-events: none; }
.search-res { position: absolute; left: 0; right: 0; top: calc(100% + 6px); background: #131315; border: 1px solid var(--line2); border-radius: 12px; padding: 6px; display: grid; gap: 2px; box-shadow: 0 24px 60px rgba(0,0,0,.65); max-height: 60vh; overflow: auto; }
.search-res button { text-align: left; background: none; border: 0; border-radius: 8px; padding: 8px 10px; display: grid; gap: 2px; }
.search-res button:hover, .search-res button:focus-visible { background: #1d1d20; }
.search-res b { color: var(--gold2); font-size: 12px; letter-spacing: .06em; text-transform: uppercase; }
.search-res span { font-size: 13.5px; color: var(--ink2); overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.search-res p { padding: 10px; color: var(--ink3); font-size: 13.5px; }
.user-chip { display: flex; align-items: center; gap: 10px; background: rgba(14,14,16,.78); backdrop-filter: blur(8px); border: 1px solid var(--line2); border-radius: 999px; padding: 5px 14px 5px 6px; text-align: left; }
.user-chip:hover { border-color: var(--gold-dim); }
.menu { position: absolute; right: 22px; top: 66px; background: #131315; border: 1px solid var(--line2); border-radius: 12px; min-width: 210px; padding: 6px; box-shadow: 0 20px 50px rgba(0,0,0,.7); display: grid; z-index: 20; }
.menu button { text-align: left; background: none; border: 0; padding: 9px 12px; border-radius: 8px; color: var(--ink); }
.menu button:hover { background: #1f1f22; }
.menu button.on { color: var(--gold2); }
.menu hr { border: 0; border-top: 1px solid var(--line); margin: 4px 0; width: 100%; }
.menu-title { color: var(--ink3); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; padding: 6px 12px 2px; }

/* ── jornada ── */
.view { position: absolute; inset: 0; min-height: 0; }


/* ── painel de execução (cartão dourado flutuante) ── */
.panel { position: absolute; z-index: 4; right: 20px; top: 74px; bottom: 20px; width: clamp(540px, 40vw, 700px); overflow-y: auto; padding: 26px 28px 24px; border-radius: 22px; border: 1px solid transparent;
  background: linear-gradient(180deg, rgba(23,22,20,.94), rgba(11,11,12,.95)) padding-box, linear-gradient(160deg, #e9c45a, #5b4716 38%, #2a2a2e 62%, #c9a032) border-box;
  box-shadow: 0 30px 90px rgba(0,0,0,.65), 0 0 60px rgba(212,170,63,.14); backdrop-filter: blur(10px); scrollbar-width: thin; scrollbar-color: var(--line2) transparent; }
.p-head { display: flex; gap: 16px; justify-content: space-between; align-items: flex-start; }
.p-kicker { color: var(--gold2); font-size: 12.5px; letter-spacing: .16em; text-transform: uppercase; font-weight: 700; }
.p-week { color: var(--ink2); font-size: 12.5px; letter-spacing: .14em; text-transform: uppercase; margin-top: 4px; }
.p-title { font-size: clamp(26px, 2.4vw, 34px); line-height: 1.12; margin-top: 12px; font-weight: 700; }
.p-blurb { color: var(--ink2); margin-top: 8px; max-width: 520px; font-size: 14.5px; }
.swap { display: inline-flex; gap: 8px; align-items: center; white-space: nowrap; background: rgba(255,255,255,.04); border: 1px solid var(--line2); border-radius: 10px; padding: 9px 14px; font-size: 14px; }
.swap:hover { border-color: var(--gold-dim); }
.p-prog { display: flex; justify-content: space-between; align-items: baseline; margin-top: 18px; font-size: 17px; font-weight: 600; }
.p-prog span:last-child { color: var(--ink2); font-size: 15px; font-weight: 500; }
.bar { height: 11px; background: #0b0b0c; border: 1px solid var(--line); border-radius: 99px; overflow: hidden; margin-top: 10px; }
.bar > i { display: block; height: 100%; background: linear-gradient(90deg, #a98524, var(--gold2)); border-radius: 99px; transition: width .5s ease; box-shadow: 0 0 14px rgba(242,201,76,.5); }
.rhythm { margin-top: 10px; font-size: 12.5px; color: var(--ink3); }
.tasks { display: grid; gap: 8px; margin-top: 16px; padding: 0; list-style: none; }

.task { background: rgba(255,255,255,.025); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; display: grid; grid-template-columns: 76px minmax(0, 1fr) auto; gap: 6px 14px; align-items: start; transition: border-color .2s, background .2s; }
.task.done { border-color: #4a3d14; background: rgba(212,170,63,.05); }
.task.today { box-shadow: inset 3px 0 0 var(--gold-dim); }
.task.flash { animation: flash 1.6s ease; }
@keyframes flash { 0%, 60% { border-color: var(--gold2); box-shadow: 0 0 24px rgba(242,201,76,.5); } 100% { } }
.day { color: var(--gold2); font-weight: 700; font-size: 13px; letter-spacing: .1em; text-transform: uppercase; padding-top: 2px; }
.t-body { min-width: 0; display: grid; gap: 6px; }
.task-text { color: var(--ink); font-size: 14.5px; line-height: 1.45; }
.task.done .task-text { color: var(--ink2); }
.today-tag { font-size: 11px; color: var(--ink3); display: block; margin-top: 4px; letter-spacing: 0; text-transform: none; font-weight: 500; }
.ready { color: var(--ink3); font-size: 12.5px; line-height: 1.4; }
.ready b { color: var(--ink2); font-weight: 600; }
.t-side { display: grid; justify-items: end; gap: 10px; align-self: stretch; grid-template-rows: auto 1fr; }
.checkbox { position: relative; width: 32px; height: 32px; }
.checkbox input { position: absolute; inset: 0; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; z-index: 1; }
.checkbox i { position: absolute; inset: 0; border-radius: 9px; border: 2px solid #5d5c61; background: #0c0c0d; transition: all .15s; display: grid; place-items: center; }
.checkbox input:checked + i { background: linear-gradient(180deg, #f6d673, #d3aa3a); border-color: #fff1b8; box-shadow: 0 0 14px rgba(242,201,76,.45); }

.checkbox input:focus-visible + i { outline: 2px solid var(--gold2); outline-offset: 3px; }
.checkbox input:disabled { cursor: not-allowed; }
.checkbox input:disabled + i { opacity: .4; }
.lessons { display: flex; flex-wrap: wrap; gap: 6px; justify-content: flex-end; align-self: end; }
.lesson { border: 1px solid var(--line2); background: rgba(255,255,255,.04); color: var(--ink2); padding: 2px 10px; border-radius: 8px; font-size: 12px; white-space: nowrap; }
.extras > summary { cursor: pointer; color: var(--ink2); font-size: 13px; padding: 2px 0; list-style: none; display: flex; gap: 6px; align-items: center; }
.extras > summary::before { content: "▸"; color: var(--gold); transition: transform .15s; }
.extras[open] > summary::before { transform: rotate(90deg); }
.extras .fields { display: grid; gap: 10px; margin-top: 8px; }
.cond { display: grid; gap: 6px; }
.cond label { font-size: 13px; color: var(--ink); }
.locked-note { background: #17140a; border: 1px solid #4a3d14; color: var(--ink2); border-radius: 12px; padding: 12px 14px; margin-top: 14px; font-size: 14px; }
.nav-btns { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); gap: 12px; margin-top: 18px; }
.nav-btns .btn { padding: 15px 18px; font-size: 15.5px; display: flex; align-items: center; justify-content: center; gap: 10px; border-radius: 12px; }
.nav-btns .btn.next { font-weight: 700; }
.banner { margin-top: 14px; border: 1px solid var(--gold-dim); background: linear-gradient(180deg, #1d190d, #131209); border-radius: 14px; padding: 14px 16px; display: grid; gap: 10px; }
.banner b { color: var(--gold2); }

/* ── páginas internas ── */
.page { overflow-y: auto; padding: 84px clamp(16px, 4vw, 48px) 60px; background: radial-gradient(900px 500px at 80% -10%, #231c0f, transparent), var(--bg); }
.page > * { max-width: 1040px; margin-left: auto; margin-right: auto; }
.page h1 { font-size: 28px; margin-bottom: 4px; }
.page .lead { color: var(--ink2); margin-bottom: 20px; }
.acc { border: 1px solid var(--line); border-radius: 14px; background: var(--panel); margin-bottom: 12px; overflow: hidden; }
.acc > summary { list-style: none; cursor: pointer; padding: 14px 18px; display: flex; gap: 14px; align-items: center; justify-content: space-between; }
.acc > summary::-webkit-details-marker { display: none; }
.acc .acc-body { padding: 4px 16px 16px; }
.badge { font-size: 12px; color: var(--ink3); border: 1px solid var(--line2); border-radius: 999px; padding: 2px 10px; white-space: nowrap; }
.badge.ok { color: var(--gold2); border-color: var(--gold-dim); }
.grid2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 12px; }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 16px; }
.card h3 { font-size: 15px; margin-bottom: 8px; }
.kpi { font-size: 30px; font-weight: 700; color: var(--gold2); }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--line); }
th { color: var(--ink3); font-weight: 600; font-size: 12.5px; }
.note { color: var(--ink3); font-size: 13px; }

/* topbar do painel da equipe */
.topbar { display: flex; align-items: center; gap: 18px; padding: 10px 18px; border-bottom: 1px solid var(--line); background: #0e0e10; position: relative; z-index: 5; pointer-events: auto; }

/* modal / toast */
.modal { position: fixed; inset: 0; background: rgba(5,5,7,.78); display: grid; place-items: center; padding: 16px; z-index: 40; }
.modal-card { width: min(720px, 100%); max-height: 92vh; overflow-y: auto; background: var(--panel); border: 1px solid var(--line2); border-radius: 16px; padding: 22px; }
.modal-card h2 { font-size: 19px; margin-bottom: 4px; }
.g-table { overflow-x: auto; }
.g-table input { min-width: 82px; padding: 7px 8px; }
.row-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 16px; flex-wrap: wrap; }
.toast { position: fixed; left: 50%; bottom: 22px; transform: translateX(-50%); background: #1d1d20; border: 1px solid var(--line2); padding: 10px 16px; border-radius: 10px; z-index: 60; box-shadow: 0 10px 30px rgba(0,0,0,.5); max-width: calc(100% - 32px); }
.toast.error { border-color: var(--danger); }

/* ── responsivo ── */
@media (max-width: 1180px) { .panel { width: clamp(480px, 46vw, 600px); } .hero { max-width: 40%; } }
@media (max-width: 960px) {
  body { overflow: auto; }
  .side::-webkit-scrollbar { display: none; }
  .app { position: static; display: block; min-height: 100%; }
  .side { flex-direction: row; align-items: center; gap: 8px; padding: 8px 10px; overflow-x: auto; scrollbar-width: none; border-right: 0; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 8; }
  .side::after, .side-group, .side-nav hr, .side-user, .side-brand b { display: none; }
  .side-brand { padding: 0 4px; }
  .side-nav { display: flex; gap: 6px; }
  .side-item { width: auto; white-space: nowrap; padding: 8px 10px; font-size: 13.5px; }
  .side-item .ico { display: none; }
  .main { overflow: visible; }
  .top { position: static; padding: 10px 12px; flex-wrap: wrap; background: #0e0e10; }
  .search { width: 100%; margin: 0; order: 3; }
  .view { position: static; }
  .trilha { display: grid; }
  .panel { position: static; width: auto; margin: -22px 10px 16px; border-radius: 20px; padding: 18px 16px 20px; }
  .task { grid-template-columns: 62px minmax(0, 1fr) auto; padding: 12px; gap: 6px 10px; }
  .page { padding-top: 22px; }
  .menu { right: 12px; top: 120px; }
}
@media (prefers-reduced-motion: reduce) { * { animation-duration: .01ms !important; transition-duration: .01ms !important; } }

/* ───── Direção sombria: preto, carvão e cinza; amarelo só para o progresso ───── */
.brand-mark { background: #17181a; border-color: #3a3d40; color: var(--gold2); }
.btn.primary { background: linear-gradient(180deg, #e3e5e6, #b9bcbe); color: #101112; border-color: #f2f3f3; box-shadow: none; }
.btn.primary:hover:not(:disabled) { background: linear-gradient(180deg, #f1f2f3, #c8cbcc); }
.avatar { background: #1a1b1d; border-color: #3a3d40; color: var(--gold2); }
.side { background: linear-gradient(180deg, #0f1011, #080909); }
.side::after { background: none; }
.side-item.on { background: #17181a; border-color: #3a3d40; box-shadow: none; color: var(--ink); }
.side-item.on em { color: var(--ink); border-color: #4a4e52; }
.auth { background: radial-gradient(900px 500px at 70% -10%, #1b1d1f, transparent), var(--bg); }
.auth-card { box-shadow: 0 30px 80px rgba(0,0,0,.7); }
.panel { background: linear-gradient(180deg, rgba(18,19,20,.94), rgba(9,10,10,.96)) padding-box, linear-gradient(160deg, #4a4d50, #202224 40%, #2e3033 70%, #52565a) border-box; box-shadow: 0 30px 90px rgba(0,0,0,.7); }
.p-kicker { color: #c3c6c8; }
.p-week { color: var(--ink3); }
.bar > i { background: linear-gradient(90deg, #b5902a, var(--yellow)); box-shadow: 0 0 10px rgba(242,194,48,.35); }
.day { color: #c3c6c8; }
.task.done { border-color: #3a3524; background: rgba(242,194,48,.04); }
.task.today { box-shadow: inset 3px 0 0 #5a5d60; }
.task.flash { animation: flashY 1.6s ease; }
@keyframes flashY { 0%, 60% { border-color: var(--yellow); box-shadow: 0 0 22px rgba(242,194,48,.35); } 100% { } }
.checkbox input:checked + i { background: var(--yellow); border-color: #ffe08a; box-shadow: 0 0 12px rgba(242,194,48,.4); }
.banner { border-color: #4a4e52; background: linear-gradient(180deg, #17181a, #101112); }
.banner b, .kpi { color: var(--ink); }
.badge.ok { color: var(--yellow); border-color: #5a4a14; }
.locked-note { background: #151617; border-color: #34373a; }
.swap:hover, .side-user:hover, .user-chip:hover, .btn:hover:not(:disabled) { border-color: #5a5e62; }
.menu button.on { color: var(--ink); }
.search-res b { color: #c3c6c8; }



/* ───── Tela principal: lista de etapas + painel de execução (sem 3D) ───── */
.trilha { display: grid; grid-template-columns: minmax(0, 1fr) clamp(540px, 44vw, 720px); gap: 28px; padding: 76px 22px 20px clamp(24px, 4vw, 56px);
  background: radial-gradient(900px 560px at 18% 8%, #1b1d1f, transparent 70%), var(--bg); overflow: hidden; }
.trilha::after { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .5; mix-blend-mode: multiply;
  background: radial-gradient(130% 100% at 40% 40%, transparent 55%, rgba(0,0,0,.5) 100%), url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2'/><feColorMatrix values='0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 .45 0'/></filter><rect width='100%' height='100%' filter='url(%23n)' opacity='.5'/></svg>"); }
.overview { position: relative; z-index: 1; min-height: 0; overflow-y: auto; padding: clamp(8px, 4vh, 40px) 8px 24px 0; scrollbar-width: none; }
.hud-route { color: #c3c6c8; font-size: 12.5px; letter-spacing: .4em; text-transform: uppercase; font-weight: 600; }
.hero-title { font-size: clamp(30px, 3.3vw, 52px); line-height: 1.06; margin-top: 12px; font-weight: 700; letter-spacing: -.01em; max-width: 14em; }
.hero-title em { font-style: normal; color: var(--ink2); }
.hero-sub { color: var(--ink2); margin-top: 14px; font-size: 15px; max-width: 30em; }
.route-prog { margin-top: 28px; max-width: 440px; }
.steps { list-style: none; margin: 30px 0 0; padding: 0; display: grid; gap: 0; max-width: 520px; position: relative; }
.step { position: relative; padding-left: 44px; }
.step::before { content: ""; position: absolute; left: 14px; top: 34px; bottom: -8px; width: 2px; background: var(--line2); }
.step:last-child::before { display: none; }
.step.done::before { background: linear-gradient(180deg, var(--yellow), #5a4a14); }
.step-btn { width: 100%; text-align: left; background: none; border: 1px solid transparent; border-radius: 12px; padding: 12px 14px; display: grid; gap: 2px; color: var(--ink); transition: background .15s, border-color .15s; margin-bottom: 8px; }
.step-btn:hover:not(:disabled) { background: rgba(255,255,255,.04); border-color: var(--line2); }
.step.viewing .step-btn { background: rgba(255,255,255,.05); border-color: #3e4246; }
.step-btn:disabled { cursor: not-allowed; color: var(--ink3); }
.step-dot { position: absolute; left: 0; top: 10px; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: #101112; border: 2px solid #4a4e52; font-size: 12px; font-weight: 700; color: var(--ink2); z-index: 1; }
.step.current .step-dot { border-color: var(--yellow); color: var(--yellow); box-shadow: 0 0 12px rgba(242,194,48,.35); }
.step.done .step-dot { background: var(--yellow); border-color: #ffe08a; color: #14120a; }
.step-title { font-size: 16px; font-weight: 600; }
.step-meta { color: var(--ink3); font-size: 13px; display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.step-meta .bar { height: 5px; width: 110px; margin: 0; }
.panel { position: relative; z-index: 1; right: auto; top: auto; bottom: auto; width: auto; min-height: 0; }
@media (max-width: 1180px) { .trilha { grid-template-columns: minmax(0, 0.8fr) minmax(480px, 1fr); gap: 18px; } }
@media (max-width: 960px) {
  .trilha { display: block; padding: 14px 12px 20px; overflow: visible; }
  .overview { overflow: visible; padding: 4px 0 18px; }
  .hero-title { font-size: 26px; }
  .panel { margin: 0; }
}

/* ───── Cena 3D da etapa 1.1 (atrás da lista de etapas e do painel) ───── */
.stage { position: absolute; inset: 0; z-index: 0; overflow: hidden; background: #2a2024; }
.stage canvas { display: block; width: 100%; height: 100%; }
.stage-pick { position: absolute; left: 0; top: 0; width: 60px; height: 60px; border-radius: 50%; border: 0; background: transparent; cursor: pointer; z-index: 2; }
.stage-pick:focus-visible { outline: 2px solid var(--yellow); outline-offset: 3px; }
.trilha.with-stage { padding-top: 70px; }
.trilha.with-stage::after { display: none; }
.trilha.with-stage .overview { position: relative; z-index: 2; width: min(300px, 100%); padding: 14px 16px; align-self: start; max-height: calc(100% - 20px); border-radius: 18px;
  background: linear-gradient(180deg, rgba(10,10,11,.66), rgba(10,10,11,.5)); backdrop-filter: blur(8px); border: 1px solid rgba(255,255,255,.08); }
.trilha.with-stage .hero-title { font-size: clamp(22px, 2vw, 30px); margin-top: 8px; }
.trilha.with-stage .hero-sub, .trilha.with-stage .step-meta > span:not(:first-child) { display: none; }
.trilha.with-stage .route-prog { margin-top: 14px; }
.trilha.with-stage .steps { margin-top: 14px; }
.trilha.with-stage .step-btn { padding: 8px 12px; margin-bottom: 4px; }
.trilha.with-stage .step-title { font-size: 14.5px; }
.trilha.with-stage .panel { z-index: 3; }
@media (max-width: 960px) {
  .stage { position: relative; height: min(52vh, 420px); border-radius: 16px; margin-bottom: 14px; }
  .trilha.with-stage { padding-top: 14px; }
  .trilha.with-stage .overview { width: auto; }
}
.trilha.with-stage .hero-title { display: none; }
.trilha.with-stage .hud-route { font-size: 11.5px; }

/* ───── fundo: relevo + trilha do checklist (js/bg.js) ───── */
.bgfx { position: absolute; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; background: radial-gradient(900px 600px at 20% 10%, #15171b, transparent 70%), #08090b; }
.bg-topo { position: absolute; inset: 0; width: 100%; height: 100%; }
.bg-vig { position: absolute; inset: 0; background: radial-gradient(120% 90% at 50% 45%, transparent 40%, rgba(0,0,0,.6) 100%); }
.bg-route { position: absolute; left: 0; top: 70px; bottom: 30px; width: calc(100% - clamp(540px, 44vw, 720px) - 30px); height: auto; }
.rt-line { stroke: rgba(255,255,255,.2); stroke-width: 2; stroke-dasharray: 3 9; stroke-linecap: round; }
.rt-done { stroke: var(--yellow); stroke-width: 3; stroke-linecap: round; }
.rt-done-glow { stroke: rgba(242,194,48,.28); stroke-width: 9; stroke-linecap: round; fill: none; }
.rt-dot { fill: #1b1c1f; stroke: #5b5f63; stroke-width: 2; }
.rt-node.major .rt-dot { fill: #121315; stroke: #7a7e82; }
.rt-node.lock { opacity: .4; }
.rt-node.done .rt-dot { fill: var(--yellow); stroke: #ffe9a6; }
.rt-node.done .rt-pulse { display: block; animation: none; fill: rgba(242,194,48,.2); stroke: none; transform: scale(.85); }
.rt-node.next .rt-dot { fill: #2a2209; stroke: var(--yellow); stroke-width: 2.5; }
.rt-pulse { fill: none; stroke: var(--yellow); stroke-width: 2; opacity: .8; transform-box: fill-box; transform-origin: center; animation: rtPulse 2s ease-out infinite; }
@keyframes rtPulse { from { transform: scale(.55); opacity: .9; } to { transform: scale(1.5); opacity: 0; } }
.rt-label { fill: #c3c6c8; font: 600 12px var(--font); letter-spacing: .12em; text-transform: uppercase; }
.rt-node.done .rt-label { fill: var(--yellow); }
body .view.trilha, body .page { background: transparent; }
body .trilha::after { display: none; }

/* ───── movimento, ícones e conquistas ───── */
.icon { vertical-align: -3px; flex: none; }
.brand b { line-height: 1.15; letter-spacing: .05em; font-size: 13px; }
.side-brand b { font-size: 12px; }
.step-dot .icon { vertical-align: 0; }
.checkbox input:checked + i::after { content: ""; width: 9px; height: 16px; border: solid #17140a; border-width: 0 3px 3px 0; transform: rotate(45deg) translate(-1px, -1px); }
.checkbox.just i { animation: boxPop .5s cubic-bezier(.3, 1.5, .5, 1); }
.checkbox.just input:checked + i::after { animation: tick .42s cubic-bezier(.3, 1.4, .5, 1) both; }
@keyframes boxPop { 0% { transform: scale(.82); } 55% { transform: scale(1.18); box-shadow: 0 0 26px rgba(242,194,48,.8); } 100% { transform: scale(1); } }
@keyframes tick { 0% { clip-path: inset(0 100% 100% 0); opacity: 0; } 100% { clip-path: inset(-4px -4px -4px -4px); opacity: 1; } }
.task { transition: border-color .35s, background .35s, transform .2s; }
.task.done .task-text { transition: color .4s; }
.panel.enter .p-head, .panel.enter .p-title, .panel.enter .p-blurb, .panel.enter .p-prog, .panel.enter .bar, .panel.enter .rhythm { animation: rise .5s cubic-bezier(.2, .8, .2, 1) both; }
.panel.enter .task { animation: rise .55s cubic-bezier(.2, .8, .2, 1) both; }
.panel.enter .task:nth-child(2) { animation-delay: .05s; } .panel.enter .task:nth-child(3) { animation-delay: .1s; } .panel.enter .task:nth-child(4) { animation-delay: .15s; } .panel.enter .task:nth-child(5) { animation-delay: .2s; } .panel.enter .task:nth-child(n+6) { animation-delay: .25s; }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.step-btn, .step-dot { transition: background .3s, border-color .3s, color .3s, box-shadow .3s; }

/* trilha do fundo: faísca, pulso e cenário por rota */
.bg-topo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transform: scale(.8); will-change: transform, opacity; transition: opacity 1.1s ease, transform 1.35s cubic-bezier(.65, 0, .2, 1); }
.bgfx[data-route="escala"] .bg-topo.comeco { transform: scale(1.5); }
.bgfx[data-route="comeco"] .bg-topo.escala { transform: scale(.8); }
.bgfx[data-route="comeco"] .bg-topo.comeco, .bgfx[data-route="escala"] .bg-topo.escala { opacity: 1; transform: none; }
.bg-route { transition: opacity .4s ease, transform .5s ease; }
.bg-route.out { opacity: 0; transform: translateY(8px); }
.rt-node:not(.next):not(.done) .rt-pulse { display: none; }
.rt-dot { transition: fill .4s, stroke .4s; transform-box: fill-box; transform-origin: center; }
.rt-node.pop .rt-dot { animation: dotPop .65s cubic-bezier(.3, 1.6, .5, 1); }
@keyframes dotPop { 0% { transform: scale(.6); } 50% { transform: scale(1.9); } 100% { transform: scale(1); } }
.rt-spark { fill: #fff3c0; opacity: 0; }
.rt-spark-glow { fill: rgba(255,208,80,.3); opacity: 0; }
.rt-ring { fill: none; stroke: var(--yellow); stroke-width: 2; transform-box: fill-box; transform-origin: center; }
.rt-spk { fill: var(--yellow); }
.bg-glow { position: absolute; inset: 0; opacity: 0; transition: opacity .8s; background: radial-gradient(520px 420px at 14% 18%, rgba(242,170,48,.34), transparent 70%), radial-gradient(640px 520px at 78% 88%, rgba(70,110,255,.24), transparent 70%), radial-gradient(420px 360px at 55% 40%, rgba(160,90,255,.14), transparent 70%); animation: drift 18s ease-in-out infinite alternate; }
@keyframes drift { to { transform: translate3d(-3%, 2%, 0) scale(1.06); } }

/* aviso de etapa concluída */
.cele { position: fixed; left: 50%; top: 22px; z-index: 60; display: flex; gap: 12px; align-items: center; padding: 11px 20px 11px 12px; border-radius: 999px; background: rgba(16,16,18,.92); border: 1px solid #5a4a14; box-shadow: 0 16px 50px rgba(0,0,0,.6), 0 0 34px rgba(242,194,48,.22); transform: translate(-50%, -140%); opacity: 0; pointer-events: none; transition: transform .6s cubic-bezier(.2, 1.2, .3, 1), opacity .4s; }
.cele.show { transform: translate(-50%, 0); opacity: 1; }
.cele-ico { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: var(--yellow); color: #17140a; }
.cele-txt b { display: block; font-size: 14.5px; } .cele-txt small { color: var(--ink2); font-size: 12.5px; }

/* ───── estilo Glass (alternativa; "Aparência" no menu da conta) ───── */
body[data-style="glass"] { --glass-bg: linear-gradient(155deg, rgba(255,255,255,.13), rgba(255,255,255,.04)); --glass-line: rgba(255,255,255,.2); --glass-hi: inset 0 1px 0 rgba(255,255,255,.34), inset 0 -1px 0 rgba(255,255,255,.05); }
body[data-style="glass"] .bg-glow { opacity: 1; }
body[data-style="glass"] .bgfx { background: #0a0b10; }
body[data-style="glass"] .side { background: rgba(255,255,255,.045); backdrop-filter: blur(30px) saturate(190%); border-right: 1px solid rgba(255,255,255,.12); }
body[data-style="glass"] .side-item.on { background: var(--glass-bg); border-color: var(--glass-line); box-shadow: var(--glass-hi), 0 8px 24px rgba(0,0,0,.25); }
body[data-style="glass"] .panel { background: var(--glass-bg); border: 1px solid var(--glass-line); border-radius: 30px; backdrop-filter: blur(34px) saturate(200%); box-shadow: var(--glass-hi), 0 30px 80px rgba(0,0,0,.45); }
body[data-style="glass"] .task, body[data-style="glass"] .card, body[data-style="glass"] .acc { background: rgba(255,255,255,.055); border: 1px solid rgba(255,255,255,.12); border-radius: 20px; box-shadow: var(--glass-hi);  }
body[data-style="glass"] .task:hover { background: rgba(255,255,255,.085); }
body[data-style="glass"] .task.done { border-color: rgba(242,194,48,.45); background: linear-gradient(155deg, rgba(242,194,48,.14), rgba(255,255,255,.04)); }
body[data-style="glass"] .step.viewing .step-btn, body[data-style="glass"] .step-btn:hover:not(:disabled) { background: var(--glass-bg); border-color: var(--glass-line); box-shadow: var(--glass-hi); border-radius: 18px;  }
body[data-style="glass"] .search input, body[data-style="glass"] .user-chip, body[data-style="glass"] .btn, body[data-style="glass"] .swap { background: var(--glass-bg); border: 1px solid var(--glass-line); box-shadow: var(--glass-hi); backdrop-filter: blur(20px) saturate(180%); border-radius: 999px; }
body[data-style="glass"] .btn.primary { background: linear-gradient(180deg, rgba(255,214,102,.95), rgba(224,172,40,.9)); color: #1c1403; border-color: rgba(255,240,190,.7); }
body[data-style="glass"] .menu, body[data-style="glass"] .search-res, body[data-style="glass"] .modal-card, body[data-style="glass"] .auth-card, body[data-style="glass"] .toast { background: rgba(28,29,34,.62); border: 1px solid var(--glass-line); box-shadow: var(--glass-hi), 0 30px 80px rgba(0,0,0,.55); backdrop-filter: blur(36px) saturate(200%); border-radius: 22px; }
body[data-style="glass"] .cele { background: rgba(28,29,34,.6); backdrop-filter: blur(30px) saturate(200%); border-color: rgba(255,255,255,.25); box-shadow: var(--glass-hi), 0 16px 50px rgba(0,0,0,.5), 0 0 34px rgba(242,194,48,.25); }
body[data-style="glass"] .bar { background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.12); }
body[data-style="glass"] .checkbox i { background: rgba(255,255,255,.07); border-color: rgba(255,255,255,.35); }
.side-item span { white-space: nowrap; }
.cele { top: 70px; }
body[data-style="glass"] .bg-glow { filter: saturate(1.35); }

/* ───── desempenho (60 fps): nada de blur/filtro animado, só transform e opacity ───── */
body:not([data-style="glass"]) .panel { backdrop-filter: none; }
body[data-style="glass"] .panel .btn, body[data-style="glass"] .panel .swap { backdrop-filter: none; }
.bg-glow, .cele, .bg-route { will-change: transform, opacity; }
.bg-route { contain: layout style; }
.panel { overscroll-behavior: contain; }
.trilha.switching .overview { animation: rise .8s cubic-bezier(.2, .8, .2, 1) both; }
.bg-route.intro .rt-node { animation: nodeIn .55s cubic-bezier(.2, .9, .3, 1) both; animation-delay: calc(var(--i) * 24ms); }
.bg-route.intro .rt-line { animation: lineIn .8s ease both; }
@keyframes nodeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes lineIn { from { opacity: 0; } to { opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .bg-glow { animation: none; } .bg-topo { transition-duration: .01ms; } }

/* aulas, anexos e mini-tutorial */
.aulas, .anexos { display: flex; flex-wrap: wrap; gap: 8px; }
.aula-btn, .anexo-btn { display: inline-flex; align-items: center; gap: 7px; padding: 6px 12px; border-radius: 9px; font-size: 13px; font-weight: 600; text-decoration: none; border: 1px solid var(--line2); transition: transform .12s, border-color .12s; }
.aula-btn { background: linear-gradient(180deg, #f6d673, #d3aa3a); color: #1a1405; border-color: #fff1b8; }
.aula-btn .play { font-size: 10px; }
.anexo-btn { background: rgba(255,255,255,.05); color: var(--ink); }
.aula-btn:hover, .anexo-btn:hover { transform: translateY(-1px); border-color: var(--yellow); }
.aula-btn:focus-visible, .anexo-btn:focus-visible { outline: 2px solid var(--gold2); outline-offset: 2px; }
.tut { position: fixed; inset: 0; z-index: 70; }
.tut-ring { position: fixed; border-radius: 16px; border: 2px solid var(--yellow); box-shadow: 0 0 0 9999px rgba(5,5,7,.76), 0 0 24px rgba(242,194,48,.35); transition: all .25s ease; pointer-events: none; }
.tut-card { position: fixed; background: #131315; border: 1px solid var(--line2); border-radius: 14px; padding: 16px 18px; box-shadow: 0 20px 60px rgba(0,0,0,.7); transition: left .25s, top .25s; }
.tut-card h3 { font-size: 16px; margin: 2px 0 6px; }
.tut-card p { color: var(--ink2); font-size: 14px; line-height: 1.45; }
.tut-card .tut-step { font-size: 11px; color: var(--ink3); letter-spacing: .06em; text-transform: uppercase; }
.tut-badge { display: inline-block; background: var(--yellow); color: #1a1405; font-size: 11px; font-weight: 800; letter-spacing: .08em; padding: 3px 9px; border-radius: 99px; margin-bottom: 8px; }
.tut-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 12px; }
@media (prefers-reduced-motion: reduce) { .tut-ring, .tut-card { transition: none; } }
@media (max-width: 960px) { .bg-route { display: none; } }

/* a trilha do checklist só aparece na tela da trilha; nas outras telas ela ficava por baixo dos textos */
body:not([data-view="trilha"]) .bg-route { display: none; }

/* NEXO (aba Materiais) */
.nexo-page { --nx1: #4aa8ff; --nx2: #1f6bff; --nxbg: rgba(7,11,22,.9); display: grid; gap: 18px; padding-bottom: 20px; }
.nexo-crumb { color: var(--ink3); font-size: 12px; letter-spacing: .14em; text-transform: uppercase; }
.nexo-hero { position: relative; overflow: hidden; isolation: isolate; border-radius: 24px; padding: clamp(22px, 4vw, 44px) clamp(18px, 4vw, 40px) 28px; text-align: center; display: grid; justify-items: center; gap: 12px;
  background: radial-gradient(70% 90% at 50% 0%, rgba(40,100,230,.38), transparent 70%), radial-gradient(60% 70% at 90% 100%, rgba(20,60,160,.35), transparent 70%), #050913; border: 1px solid rgba(90,150,255,.28); box-shadow: 0 30px 80px rgba(0,10,40,.6), inset 0 1px 0 rgba(255,255,255,.07); }
.nexo-net { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; opacity: .9; }
.nexo-logo-wrap { position: relative; width: min(560px, 88%); animation: nxIn 1.1s cubic-bezier(.2,.8,.2,1) both; }
.nexo-logo { display: block; width: 100%; height: auto; animation: nxGlow 4.5s ease-in-out 1.2s infinite; }
.nexo-shine { position: absolute; inset: 0; pointer-events: none; background: linear-gradient(105deg, transparent 38%, rgba(255,255,255,.85) 50%, transparent 62%); background-size: 260% 100%; background-position: 130% 0;
  -webkit-mask: url(/materiais/nexo/nexo-logo.webp) center / 100% 100% no-repeat; mask: url(/materiais/nexo/nexo-logo.webp) center / 100% 100% no-repeat; mix-blend-mode: screen; animation: nxShine 5.5s ease-in-out 1.6s infinite; }
.nexo-tag { font-size: clamp(17px, 2.2vw, 22px); font-weight: 700; letter-spacing: .01em; color: #fff; animation: nxUp .8s .5s both; }
.nexo-sub { color: #c4d3ea; max-width: 38em; font-size: 15px; line-height: 1.5; animation: nxUp .8s .65s both; }
.nexo-actions { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-top: 6px; animation: nxUp .8s .8s both; }
.nexo-btn { font-weight: 700; font-size: 14px; padding: 11px 20px; border-radius: 12px; text-decoration: none; display: inline-flex; align-items: center; color: #e8f1ff; background: rgba(255,255,255,.07); border: 1px solid rgba(140,180,255,.35); transition: transform .14s, box-shadow .14s, border-color .14s; }
.nexo-btn:hover { transform: translateY(-2px); border-color: var(--nx1); }
.nexo-btn:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }
.nexo-btn.main { color: #fff; border-color: #8cc4ff; background: linear-gradient(180deg, var(--nx1), var(--nx2)); box-shadow: 0 8px 26px rgba(31,107,255,.5), inset 0 1px 0 rgba(255,255,255,.35); }
.nexo-btn.main:hover { box-shadow: 0 12px 34px rgba(31,107,255,.7), inset 0 1px 0 rgba(255,255,255,.35); }
.nexo-status { min-height: 1.3em; color: #9fe0b0; font-size: 13.5px; }
.nexo-h { font-size: 13px; letter-spacing: .14em; text-transform: uppercase; color: var(--nx1); margin-top: 6px; }
.nexo-steps, .nexo-feats { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.nexo-steps { grid-template-columns: repeat(3, 1fr); }
.nexo-feats { grid-template-columns: repeat(3, 1fr); }
.nexo-steps li, .nexo-feats li { background: var(--nxbg); border: 1px solid rgba(110,160,255,.22); border-radius: 16px; padding: 16px; backdrop-filter: blur(10px); }
.nexo-steps li { display: flex; gap: 14px; align-items: flex-start; }
.nexo-steps .n { flex: none; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; font-size: 16px; color: #fff; background: linear-gradient(180deg, var(--nx1), var(--nx2)); box-shadow: 0 0 18px rgba(74,168,255,.5); }
.nexo-steps strong, .nexo-feats strong { display: block; color: #fff; font-size: 15px; margin-bottom: 3px; }
.nexo-steps p, .nexo-feats p { color: #b8c6dc; font-size: 13.5px; line-height: 1.45; }
.nexo-feats li { transition: transform .15s, border-color .15s; }
.nexo-feats li:hover { transform: translateY(-3px); border-color: rgba(110,180,255,.6); }
.nexo-note { color: #a9b6cb; font-size: 12.5px; line-height: 1.5; border-left: 3px solid var(--nx2); padding: 4px 0 4px 12px; }
@keyframes nxIn { from { opacity: 0; transform: scale(.9); filter: blur(14px); } to { opacity: 1; transform: none; filter: none; } }
@keyframes nxUp { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes nxGlow { 0%, 100% { filter: drop-shadow(0 0 10px rgba(60,140,255,.35)); } 50% { filter: drop-shadow(0 0 26px rgba(80,170,255,.75)); } }
@keyframes nxShine { 0% { background-position: 130% 0; } 38%, 100% { background-position: -40% 0; } }
@media (max-width: 860px) { .nexo-steps, .nexo-feats { grid-template-columns: 1fr; } }
@media (prefers-reduced-motion: reduce) { .nexo-logo-wrap, .nexo-logo, .nexo-shine, .nexo-tag, .nexo-sub, .nexo-actions { animation: none; } .nexo-shine { display: none; } }

/* ───── Celular (até 960px): tudo em coluna, toques grandes, nada cortado ───── */
@media (max-width: 960px) {
  html, body { height: auto; min-height: 100%; }
  body { overflow-x: hidden; overflow-y: auto; }
  .app { min-height: 100dvh; padding-bottom: env(safe-area-inset-bottom); }
  /* as telas ficam acima do fundo (antes o fundo cobria Checklist e Evolução) */
  .main { position: relative; }
  .view { position: relative; z-index: 1; }
  .page { padding: 14px 14px 40px; overflow: visible; }
  /* barra de cima: menu rolável com fade na ponta */
  .side { padding: 8px 10px calc(8px + env(safe-area-inset-top) * 0); gap: 6px; -webkit-overflow-scrolling: touch; scroll-snap-type: x proximity;
    -webkit-mask-image: linear-gradient(90deg, #000 90%, transparent); mask-image: linear-gradient(90deg, #000 90%, transparent); }
  .side-item { min-height: 40px; scroll-snap-align: start; border: 1px solid transparent; }
  .side-item em { display: none; }
  .side-item.soon { display: none; }
  /* busca e usuário na mesma linha */
  .top { display: flex; flex-wrap: nowrap; align-items: center; gap: 8px; padding: 10px 12px; }
  .search { order: 0; flex: 1 1 auto; width: auto; min-width: 0; }
  .search kbd { display: none; }
  .search input { padding-right: 14px; min-height: 44px; }
  .user-chip { order: 1; flex: none; padding: 4px; }
  .user-chip > span:nth-child(2), .user-chip > i { display: none; }
  .search-res { max-height: 60vh; overflow-y: auto; }
  .menu { right: 12px; top: 64px; min-width: min(240px, calc(100vw - 24px)); }
  .menu button { min-height: 44px; }
  /* trilha */
  .trilha { padding: 8px 12px 20px; }
  .overview { padding: 6px 2px 14px; }
  .hero-title { font-size: clamp(26px, 8vw, 34px); }
  .hero-sub { font-size: 14.5px; }
  .route-prog { max-width: none; margin-top: 20px; }
  .steps { margin-top: 22px; max-width: none; }
  .step-btn { min-height: 52px; }
  .panel { margin: 4px 0 0; padding: 18px 14px 20px; }
  .task { grid-template-columns: minmax(0, 1fr) 40px; grid-template-areas: "day box" "body body"; gap: 6px 10px; }
  .task > .day { grid-area: day; align-self: center; }
  .task > .t-body { grid-area: body; }
  .task > .t-side { grid-area: box; align-self: center; }
  .checkbox, .checkbox i { width: 40px; height: 40px; }
  .checkbox i { border-radius: 11px; }
  .aulas, .anexos { gap: 8px; }
  .aula-btn, .anexo-btn { min-height: 44px; padding: 10px 14px; width: 100%; justify-content: center; }
  .lesson { padding: 6px 12px; }
  .btn, .btn.small { min-height: 44px; }
  .acc > summary { min-height: 48px; }
  /* formulários e janelas */
  input, select, textarea { font-size: 16px; min-height: 44px; }
  .auth { padding: 16px 12px; align-items: start; }
  .auth-card { padding: 20px 16px; border-radius: 18px; }
  .modal { padding: 0; align-items: end; }
  .modal-card { width: 100%; max-height: 94dvh; border-radius: 20px 20px 0 0; padding: 18px 14px calc(18px + env(safe-area-inset-bottom)); }
  .toast { bottom: calc(14px + env(safe-area-inset-bottom)); }
  /* NEXO */
  .nexo-hero { border-radius: 20px; padding: 22px 14px 20px; }
  .nexo-actions { width: 100%; }
  .nexo-btn { flex: 1 1 100%; justify-content: center; min-height: 46px; }
  /* tutorial: cartão fixo embaixo, sem cobrir o destaque */
  .tut-card { left: 12px !important; right: 12px; width: auto !important; top: auto !important; bottom: calc(12px + env(safe-area-inset-bottom)); }
}
/* cartões mais opacos no celular: o texto não disputa com as linhas do fundo */
@media (max-width: 960px) {
  body[data-style] .acc, body[data-style] .page .card, body[data-style] .task, body[data-style] .panel { background: rgba(9, 10, 15, .9) !important; backdrop-filter: none; }
  body[data-style] .task { border-color: rgba(255, 255, 255, .14); }
  .ready, .step-meta, .note { color: #9aa0a6; }
  .bg-glow { opacity: .6; }
}
@media (max-width: 380px) {
  .hero-title { font-size: 25px; }
  .nexo-sub { font-size: 14px; }
}
