/* ============================================================
   WIRENOW — Design System
   Direção: industrial premium. Grafite, vermelho WireNow, fotos de chão de fábrica,
   diagonais. Cada módulo tem sua cor (ver --mod-*).
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Montserrat:ital,wght@0,500;0,600;0,700;0,800;0,900;1,800&family=Inter:wght@400;500;600;700&family=IBM+Plex+Mono:wght@400;500;600&display=swap');

:root {
  --ink: #14181d;
  --ink-soft: #4a525c;
  --ink-faint: #7c858f;
  --paper: #f3f4f6;
  --card: #ffffff;
  --steel: #1b2027;
  --steel-2: #2a313a;
  --line: #e0e3e7;
  --line-strong: #c3c8cf;
  --accent: #e3191f;
  --accent-dark: #b81218;
  --accent-soft: #fde5e5;
  --ok: #1d7a4f;
  --ok-soft: #e0f2e8;
  --warn: #a86a00;
  --warn-soft: #fdf0d3;
  --bad: #b3261e;
  --bad-soft: #fbe3e1;
  --info: #1d63c9;
  --info-soft: #e3edfb;
  /* cores dos módulos */
  --mod-marketplace: #e3191f;
  --mod-engenharia: #1f8bf0;
  --mod-academy: #8b3fd9;
  --mod-rh: #f2711c;
  --mod-manutencao: #4cc417;
  --mod-fornecedores: #11a5a5;
  --mono: 'IBM Plex Mono', ui-monospace, monospace;
  --display: 'Montserrat', 'Inter', sans-serif;
  --body: 'Inter', system-ui, sans-serif;
  --radius: 8px;
  --shadow: 0 1px 2px rgba(20,24,29,.06), 0 4px 16px rgba(20,24,29,.06);
  --shadow-lg: 0 10px 40px rgba(20,24,29,.20);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--body);
  font-size: 15.5px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--paper);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
main { flex: 1; width: 100%; max-width: 1180px; margin: 0 auto; padding: 2rem 1.5rem 4rem; }
main.narrow { max-width: 760px; }
main.wide { max-width: 1320px; }

h1, h2, h3 { font-family: var(--display); line-height: 1.1; margin: 0 0 .5em; letter-spacing: -.01em; }
h1 { font-size: 2.3rem; font-weight: 800; text-transform: uppercase; }
h2 { font-size: 1.5rem; font-weight: 800; }
h3 { font-size: 1.1rem; font-weight: 700; }
a { color: var(--info); text-decoration: none; }
a:hover { text-decoration: underline; }
code, .mono { font-family: var(--mono); font-size: .85em; }

.kicker {
  font-family: var(--mono); font-size: .72rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: .14em; color: var(--accent-dark);
  display: flex; align-items: center; gap: .6em; margin-bottom: .6rem;
}
.kicker::before { content: ''; width: 28px; height: 3px; background: var(--accent); border-radius: 2px; }
.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.6rem; border-bottom: 1px solid var(--line); padding-bottom: 1rem; }
.page-head p { margin: .2rem 0 0; color: var(--ink-soft); }

/* ---------- Logo ---------- */
.logo { display: inline-flex; flex-direction: column; text-decoration: none; line-height: 1; color: var(--steel); }
.logo:hover { text-decoration: none; }
.logo .word { font-family: var(--display); font-weight: 900; font-size: 1.6rem; letter-spacing: -.02em; display: flex; align-items: center; }
.logo .word b { color: var(--accent); font-weight: 900; font-style: italic; margin-left: .04em; }
.logo .word .slash { display: inline-block; width: .2em; height: 1em; background: var(--accent); transform: skewX(-20deg); margin: 0 .12em 0 .08em; border-radius: 1px; }
.logo .tag { font-family: var(--body); font-weight: 600; font-size: .46rem; letter-spacing: .22em; white-space: nowrap; color: var(--ink-faint); margin-top: .3rem; text-transform: uppercase; }
.logo.inverse { color: #fff; }
.logo.inverse .tag { color: #9aa4ae; }
.logo.lg .word { font-size: 2.6rem; }
.logo.lg .tag { font-size: .66rem; }

/* ---------- Navbar ---------- */
.site-header { background: #fff; color: var(--ink); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 50; }
.navbar { max-width: 1320px; margin: 0 auto; padding: 0 1.5rem; display: flex; align-items: center; gap: 1.6rem; min-height: 68px; }
.nav-links { display: flex; gap: .1rem; margin-right: auto; overflow-x: auto; scrollbar-width: none; }
.nav-links a {
  color: var(--ink-soft); text-decoration: none; font-family: var(--display); font-weight: 700; font-size: .84rem;
  padding: 1.55rem .6rem 1.35rem; white-space: nowrap; border-bottom: 3px solid transparent; position: relative;
}
.nav-links a:hover { color: var(--ink); text-decoration: none; }
.nav-links a.active { color: var(--ink); border-bottom-color: var(--mod-color, var(--accent)); }
.nav-user { display: flex; align-items: center; gap: .7rem; font-size: .85rem; white-space: nowrap; }
.nav-user .who { font-size: .78rem; color: var(--ink-faint); max-width: 180px; overflow: hidden; text-overflow: ellipsis; }
.btn-nav { background: transparent; border: 1px solid var(--line-strong); color: var(--ink); }
.btn-nav:hover { border-color: var(--steel); }
.subnav { background: var(--steel); }
.subnav-inner { max-width: 1320px; margin: 0 auto; padding: 0 1.5rem; display: flex; gap: .2rem; align-items: center; overflow-x: auto; scrollbar-width: none; }
.subnav a { color: #b9c1c9; font-weight: 600; font-size: .82rem; padding: .7rem .85rem; white-space: nowrap; border-bottom: 2px solid transparent; }
.subnav a:hover { color: #fff; text-decoration: none; }
.subnav a.active { color: #fff; border-bottom-color: var(--accent); }
.subnav .spacer { margin-left: auto; }
.subnav .cta { background: var(--accent); color: #fff; border-radius: 4px; padding: .38rem .8rem; margin: .3rem 0; border: 0; }
.subnav .cta:hover { background: var(--accent-dark); }
@media (max-width: 760px) {
  .navbar { flex-wrap: wrap; gap: .4rem 1rem; padding-top: .6rem; }
  .nav-links { order: 3; width: 100%; margin-right: 0; }
  .nav-links a { padding: .6rem .6rem .7rem; }
  .nav-user { margin-left: auto; }
  .nav-user .who { display: none; }
}

/* ---------- Botões ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .45em;
  font-family: var(--body); font-weight: 700; font-size: .9rem;
  padding: .55rem 1.1rem; border-radius: var(--radius); border: 1px solid transparent;
  cursor: pointer; text-decoration: none; transition: all .15s ease; line-height: 1.2;
  letter-spacing: .01em;
}
.btn:hover { text-decoration: none; filter: brightness(1.06); transform: translateY(-1px); }
.btn:disabled { opacity: .5; cursor: not-allowed; transform: none; }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-dark); filter: none; }
.btn-primary:active { transform: translateY(1px); box-shadow: none; }
.btn-dark { background: var(--steel); color: #fff; }
.btn-ghost { background: transparent; border-color: var(--line-strong); color: var(--ink); }
.btn-ghost:hover { border-color: var(--steel); background: #fff; }
.btn-danger { background: var(--bad); color: #fff; }
.btn-sm { padding: .3rem .7rem; font-size: .78rem; }
.btn-block { width: 100%; }
.btn-ok { background: var(--ok); color: #fff; }

/* ---------- Cards / painéis ---------- */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.card-pad { padding: 1.5rem; }
.panel-title { font-family: var(--mono); font-size: .72rem; font-weight: 600; text-transform: uppercase; letter-spacing: .13em; color: var(--ink-faint); border-bottom: 1px solid var(--line); padding-bottom: .5rem; margin: 0 0 1rem; }

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden; color: #fff;
  background:
    linear-gradient(100deg, rgba(20,24,29,.97) 0%, rgba(20,24,29,.88) 48%, rgba(20,24,29,.55) 100%),
    var(--hero-img, none) center/cover no-repeat,
    radial-gradient(ellipse at 75% 40%, #3a434e 0%, #1b2027 70%);
  padding: 4.2rem 1.5rem 4.6rem;
}
.hero::after {
  content: ''; position: absolute; right: 0; top: 0; bottom: 0; width: 34%;
  background: linear-gradient(160deg, var(--accent) 0%, var(--accent-dark) 100%);
  clip-path: polygon(38% 0, 100% 0, 100% 100%, 0 100%); opacity: .92;
}
.hero-inner { max-width: 1320px; margin: 0 auto; position: relative; z-index: 1; display: grid; grid-template-columns: 1.4fr 1fr; gap: 2rem; align-items: center; }
.hero h1 { font-size: clamp(2.2rem, 4.6vw, 3.6rem); font-weight: 900; text-transform: none; margin: 0 0 .35em; }
.hero h1 em { font-style: normal; color: var(--accent); }
.hero p.lead { font-size: 1.1rem; color: #c3cbd3; max-width: 560px; margin: 0 0 1.8rem; }
.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; align-items: center; }
.hero-search { display: flex; background: #fff; border-radius: 6px; overflow: hidden; max-width: 560px; margin-bottom: 1.2rem; box-shadow: var(--shadow-lg); }
.hero-search input { border: 0; border-radius: 0; padding: .9rem 1rem; font-size: 1rem; }
.hero-search input:focus { box-shadow: none; }
.hero-search button { border: 0; background: var(--accent); color: #fff; padding: 0 1.3rem; cursor: pointer; display: grid; place-items: center; }
.hero-search button svg { width: 22px; height: 22px; }
.hero-search button:hover { background: var(--accent-dark); }
.hero-slogan { justify-self: end; font-family: var(--display); font-weight: 800; font-style: italic; text-transform: uppercase; font-size: clamp(1.1rem, 2vw, 1.6rem); line-height: 1.2; transform: rotate(-8deg); text-align: right; text-shadow: 0 2px 12px rgba(0,0,0,.25); }
@media (max-width: 860px) {
  .hero::after { display: none; }
  .hero-inner { grid-template-columns: 1fr; }
  .hero-slogan { display: none; }
}

/* ---------- Grid de cards de anúncio ---------- */
.grid-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(268px, 1fr)); gap: 1.2rem; }
.listing-card { overflow: hidden; display: flex; flex-direction: column; transition: transform .15s ease, box-shadow .15s ease; }
.listing-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.listing-card .thumb { position: relative; aspect-ratio: 4/3; background: linear-gradient(160deg, #e9ecef, #cfd5db); display: grid; place-items: center; color: #8a949e; font-family: var(--mono); font-size: .7rem; letter-spacing: .1em; overflow: hidden; }
.listing-card .thumb .tx { position: absolute; top: .6rem; left: .6rem; background: var(--accent); color: #fff; font-family: var(--display); font-weight: 800; font-size: .62rem; letter-spacing: .08em; padding: .2rem .5rem; border-radius: 3px; text-transform: uppercase; }
.listing-card .thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.listing-card .body { padding: .9rem 1rem 1.1rem; display: flex; flex-direction: column; gap: .35rem; flex: 1; }
.listing-card .title { font-weight: 700; font-size: 1.02rem; color: var(--ink); }
.listing-card .title:hover { color: var(--accent); text-decoration: none; }
.listing-card .meta { font-size: .78rem; color: var(--ink-faint); }
.listing-card .price { font-family: var(--display); font-weight: 800; font-size: 1.45rem; margin-top: auto; padding-top: .4rem; }
.listing-card .price small { font-size: .65em; color: var(--ink-faint); font-weight: 600; }

/* ---------- Badges ---------- */
.badge { display: inline-block; font-family: var(--mono); font-size: .68rem; font-weight: 600; text-transform: uppercase; letter-spacing: .07em; padding: .18rem .55rem; border-radius: 3px; border: 1px solid transparent; }
.badge-ok { background: var(--ok-soft); color: var(--ok); }
.badge-warn { background: var(--warn-soft); color: var(--warn); }
.badge-bad { background: var(--bad-soft); color: var(--bad); }
.badge-info { background: var(--info-soft); color: var(--info); }
.badge-neutral { background: #eceef1; color: var(--ink-soft); }
.badge-accent { background: var(--accent-soft); color: var(--accent-dark); }

/* ---------- Formulários ---------- */
.field { margin-bottom: 1rem; }
.field label { display: block; font-weight: 600; font-size: .84rem; margin-bottom: .3rem; }
.field .req { color: var(--bad); }
.field .hint { font-size: .76rem; color: var(--ink-faint); margin-top: .25rem; font-family: var(--mono); }
input, select, textarea {
  width: 100%; font-family: var(--body); font-size: .95rem; color: var(--ink);
  background: #fff; border: 1px solid var(--line-strong); border-radius: var(--radius);
  padding: .55rem .7rem; transition: border-color .15s, box-shadow .15s;
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(227,25,31,.14); }
textarea { min-height: 90px; resize: vertical; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form-row-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 1rem; }
@media (max-width: 640px) { .form-row, .form-row-3 { grid-template-columns: 1fr; } }
fieldset { border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem 1.2rem; margin: 0 0 1.2rem; }
legend { font-family: var(--mono); font-size: .72rem; font-weight: 600; text-transform: uppercase; letter-spacing: .12em; color: var(--accent-dark); padding: 0 .5em; }
.check { display: flex; align-items: flex-start; gap: .55rem; font-size: .9rem; }
.check input { width: auto; margin-top: .2rem; }

/* ---------- Tabelas ---------- */
.table-wrap { overflow-x: auto; }
table.data { width: 100%; border-collapse: collapse; font-size: .9rem; }
table.data th { font-family: var(--mono); font-size: .7rem; text-transform: uppercase; letter-spacing: .09em; color: var(--ink-faint); text-align: left; padding: .55rem .7rem; border-bottom: 2px solid var(--line-strong); white-space: nowrap; }
table.data td { padding: .6rem .7rem; border-bottom: 1px solid var(--line); vertical-align: middle; }
table.data tr:hover td { background: #f8f9fa; }

/* ---------- Wizard (passos) ---------- */
.steps { display: flex; gap: 0; margin-bottom: 1.8rem; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: #fff; }
.step { flex: 1; padding: .7rem .9rem; font-family: var(--mono); font-size: .72rem; text-transform: uppercase; letter-spacing: .08em; color: var(--ink-faint); border-left: 1px solid var(--line); display: flex; gap: .6em; align-items: center; }
.step:first-child { border-left: 0; }
.step .n { display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; border: 1px solid currentColor; font-weight: 600; }
.step.active { background: var(--steel); color: #fff; }
.step.active .n { background: var(--accent); border-color: var(--accent); }
.step.done { color: var(--ok); }
.step.done .n { background: var(--ok); border-color: var(--ok); color: #fff; }
.wizard-actions { display: flex; justify-content: space-between; gap: 1rem; margin-top: 1.4rem; }

/* ---------- Toast ---------- */
#toast-root { position: fixed; bottom: 1.2rem; right: 1.2rem; display: flex; flex-direction: column; gap: .6rem; z-index: 1000; max-width: 380px; }
.toast { background: var(--steel); color: #fff; padding: .8rem 1.1rem; border-radius: var(--radius); border-left: 4px solid var(--info); box-shadow: var(--shadow-lg); font-size: .9rem; animation: slide-in .25s ease; display: flex; gap: .6rem; align-items: flex-start; }
.toast.success { border-left-color: #2ecc71; }
.toast.error { border-left-color: var(--bad); }
.toast.warn { border-left-color: var(--accent); }
@keyframes slide-in { from { opacity: 0; transform: translateX(20px); } to { opacity: 1; transform: none; } }

/* ---------- Modal ---------- */
.modal-backdrop { position: fixed; inset: 0; background: rgba(20,26,32,.6); z-index: 900; display: grid; place-items: center; padding: 1.2rem; animation: fade .15s ease; }
.modal { background: #fff; border-radius: var(--radius); border-top: 4px solid var(--accent); max-width: 640px; width: 100%; max-height: 90vh; display: flex; flex-direction: column; box-shadow: var(--shadow-lg); animation: pop .18s ease; }
.modal-head { display: flex; justify-content: space-between; align-items: center; padding: 1rem 1.3rem; border-bottom: 1px solid var(--line); }
.modal-head h3 { margin: 0; }
.modal-close { background: none; border: 0; font-size: 1.4rem; cursor: pointer; color: var(--ink-faint); line-height: 1; }
.modal-body { padding: 1.3rem; overflow-y: auto; }
.modal-foot { padding: .9rem 1.3rem; border-top: 1px solid var(--line); display: flex; justify-content: flex-end; gap: .7rem; }
@keyframes fade { from { opacity: 0; } }
@keyframes pop { from { opacity: 0; transform: scale(.96); } }

/* ---------- Filtros / sidebar ---------- */
.market-layout { display: grid; grid-template-columns: 260px 1fr; gap: 1.5rem; align-items: start; }
@media (max-width: 860px) { .market-layout { grid-template-columns: 1fr; } }
.filters { position: sticky; top: 1rem; max-height: calc(100vh - 2rem); overflow-y: auto; }

/* ---------- Detalhe da máquina ---------- */
.gallery-main { aspect-ratio: 4/3; background: linear-gradient(160deg, #e9ecef, #cfd5db); border-radius: var(--radius); overflow: hidden; display: grid; place-items: center; color: #8a949e; font-family: var(--mono); font-size: .75rem; }
.gallery-main img { width: 100%; height: 100%; object-fit: cover; }
.gallery-thumbs { display: flex; gap: .5rem; margin-top: .6rem; flex-wrap: wrap; }
.gallery-thumbs img { width: 72px; height: 54px; object-fit: cover; border-radius: 4px; border: 2px solid transparent; cursor: pointer; }
.gallery-thumbs img.active { border-color: var(--accent); }
.spec-table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.spec-table th { text-align: left; font-weight: 600; color: var(--ink-soft); padding: .45rem .8rem .45rem 0; width: 42%; border-bottom: 1px solid var(--line); }
.spec-table td { padding: .45rem 0; border-bottom: 1px solid var(--line); font-family: var(--mono); font-size: .85rem; }
.detail-layout { display: grid; grid-template-columns: 1.25fr 1fr; gap: 1.8rem; align-items: start; }
@media (max-width: 860px) { .detail-layout { grid-template-columns: 1fr; } }
.price-big { font-family: var(--display); font-weight: 800; font-size: 2.3rem; color: var(--ink); }
.price-big small { font-size: .5em; color: var(--ink-faint); }

/* ---------- Home ---------- */
.cats-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 1.1rem; }
.cat-card { padding: 1.2rem 1.3rem; border-left: 4px solid var(--steel); transition: all .15s; }
.cat-card:hover { border-left-color: var(--accent); transform: translateY(-2px); }
.cat-card h3 { margin-bottom: .4rem; }
.cat-card ul { list-style: none; margin: 0; padding: 0; }
.cat-card li { padding: .18rem 0; font-size: .9rem; }
.cat-card li a { color: var(--ink-soft); }
.cat-card li a:hover { color: var(--accent-dark); }
.flow-duo { display: grid; grid-template-columns: 1fr 1fr; gap: 1.2rem; margin: 2.5rem 0; }
@media (max-width: 760px) { .flow-duo { grid-template-columns: 1fr; } }
.flow-card { padding: 1.6rem; background: var(--steel); color: #fff; border-radius: var(--radius); position: relative; overflow: hidden; }
.flow-card.alt { background: var(--accent); }
.flow-card .num { font-family: var(--display); font-weight: 900; font-size: 4.5rem; opacity: .16; position: absolute; right: .5rem; top: -.8rem; }
.flow-card h3 { font-size: 1.6rem; }
.flow-card p { color: rgba(255,255,255,.75); margin: 0 0 1.2rem; }
.flow-card .btn { background: #fff; color: var(--steel); }
.flow-card.alt .btn { color: var(--accent-dark); }

/* ---------- Matches ---------- */
.match-card { border-left: 4px solid var(--line-strong); margin-bottom: 1rem; }
.match-card.compatible { border-left-color: var(--ok); }
.match-card.partial { border-left-color: var(--warn); }
.crit-grid { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .7rem; }
.crit { font-family: var(--mono); font-size: .68rem; text-transform: uppercase; letter-spacing: .05em; padding: .15rem .5rem; border-radius: 3px; background: #eceef1; color: var(--ink-faint); }
.crit.yes { background: var(--ok-soft); color: var(--ok); }
.crit.no { background: var(--bad-soft); color: var(--bad); }

/* ---------- Tabs ---------- */
.tabs { display: flex; gap: 0; border-bottom: 1px solid var(--line); margin-bottom: 1.5rem; flex-wrap: wrap; }
.tabs button { background: none; border: 0; font-family: var(--body); font-weight: 700; font-size: .9rem; text-transform: uppercase; letter-spacing: .04em; color: var(--ink-faint); padding: .7rem 1.2rem; cursor: pointer; border-bottom: 3px solid transparent; margin-bottom: -2px; }
.tabs button:hover { color: var(--ink); }
.tabs button.active { color: var(--steel); border-bottom-color: var(--accent); }

/* ---------- Misc ---------- */
.empty { text-align: center; padding: 3rem 1rem; color: var(--ink-faint); }
.empty .icon { font-size: 2.2rem; display: block; margin-bottom: .5rem; }
.skeleton { background: linear-gradient(90deg, #eceef1 25%, #f6f7f9 50%, #eceef1 75%); background-size: 200% 100%; animation: shimmer 1.2s infinite; border-radius: 4px; }
@keyframes shimmer { to { background-position: -200% 0; } }
.pagination { display: flex; gap: .4rem; justify-content: center; margin-top: 1.8rem; flex-wrap: wrap; }
.alert { padding: .8rem 1.1rem; border-radius: var(--radius); font-size: .9rem; margin-bottom: 1.2rem; border-left: 4px solid; }
.alert.info { background: var(--info-soft); border-color: var(--info); }
.alert.warn { background: var(--warn-soft); border-color: var(--warn); }
.alert.bad { background: var(--bad-soft); border-color: var(--bad); }
.site-footer { background: var(--steel); color: #8f99a3; font-size: .76rem; padding: 1.6rem 1.5rem; text-align: center; letter-spacing: .02em; border-top: 4px solid var(--accent); }
.site-footer strong { color: #fff; font-family: var(--display); font-weight: 900; letter-spacing: -.01em; }
.site-footer strong b { color: var(--accent); font-style: italic; }
.mt-1 { margin-top: .5rem; } .mt-2 { margin-top: 1rem; } .mt-3 { margin-top: 1.5rem; }
.mb-2 { margin-bottom: 1rem; }
.flex { display: flex; gap: .7rem; align-items: center; flex-wrap: wrap; }
.spread { justify-content: space-between; }
.muted { color: var(--ink-faint); font-size: .85rem; }
.count-note { font-family: var(--mono); font-size: .72rem; color: var(--ink-faint); text-transform: uppercase; letter-spacing: .08em; }

/* ============================================================
   WireNow — home, módulos e login
   ============================================================ */
.section-title { display: flex; justify-content: space-between; align-items: flex-end; gap: 1rem; margin: 2.6rem 0 1.1rem; }
.section-title h2 { margin: 0; }
.section-title a { font-weight: 600; font-size: .88rem; color: var(--accent); }

/* tiles de categoria com ícone */
.cat-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: .9rem; }
.cat-tile { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 1.1rem .8rem 1rem; text-align: center; color: var(--ink); font-weight: 600; font-size: .82rem; line-height: 1.25; display: flex; flex-direction: column; align-items: center; gap: .65rem; transition: all .15s ease; }
.cat-tile:hover { text-decoration: none; border-color: var(--accent); transform: translateY(-2px); box-shadow: var(--shadow); }
.cat-tile .ico { width: 48px; height: 48px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; }
.cat-tile .ico svg { width: 24px; height: 24px; }
.cat-tile small { color: var(--ink-faint); font-weight: 500; font-size: .72rem; }

/* faixa de benefícios */
.benefits { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 0; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); margin-top: 2.6rem; }
.benefit { display: flex; gap: .9rem; align-items: center; padding: 1.2rem 1.4rem; border-left: 1px solid var(--line); }
.benefit:first-child { border-left: 0; }
.benefit svg { width: 34px; height: 34px; flex: none; color: var(--steel); }
.benefit b { display: block; font-size: .92rem; }
.benefit span { color: var(--ink-soft); font-size: .82rem; }

/* CTA anunciar (flow-duo reestilizado) */
.flow-card { border-radius: var(--radius); }
.flow-card.alt { background: linear-gradient(135deg, var(--accent), var(--accent-dark)); }
.flow-card h3 { font-size: 1.4rem; font-weight: 800; }

/* ecossistema de módulos */
.eco-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 1rem; }
.eco-card { --c: var(--accent); position: relative; overflow: hidden; background: var(--steel); color: #fff; border-radius: var(--radius); padding: 1.3rem 1.2rem 1.2rem; display: flex; flex-direction: column; gap: .4rem; min-height: 170px; transition: transform .15s ease; }
.eco-card::before { content: ''; position: absolute; left: 1.2rem; top: 0; width: 36px; height: 4px; background: var(--c); }
.eco-card:hover { text-decoration: none; transform: translateY(-3px); }
.eco-card h3 { color: #fff; text-transform: uppercase; margin: 1.3rem 0 0; font-size: 1rem; }
.eco-card p { margin: 0; color: #aeb7c0; font-size: .82rem; }
.eco-card .go { margin-top: auto; color: var(--c); font-weight: 700; font-size: .78rem; text-transform: uppercase; letter-spacing: .05em; }
.eco-card .pill { position: absolute; right: .9rem; top: .9rem; font-size: .58rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; padding: .15rem .45rem; border-radius: 3px; background: rgba(255,255,255,.1); color: #cfd6dc; }
.eco-card.live .pill { background: var(--c); color: #fff; }

/* página de módulo (em breve) */
.module-hero { --c: var(--accent); position: relative; overflow: hidden; color: #fff; padding: 4rem 1.5rem 4.4rem;
  background: radial-gradient(ellipse at 80% 30%, #39424d 0%, #171b21 70%); }
.module-hero::after { content: ''; position: absolute; right: -4%; bottom: 0; width: 46%; height: 42%; background: linear-gradient(160deg, #fff 0%, #e8ebee 100%); clip-path: polygon(30% 100%, 100% 0, 100% 100%); opacity: .95; }
.module-hero .inner { max-width: 1180px; margin: 0 auto; position: relative; z-index: 1; display: grid; grid-template-columns: 1.1fr 1fr; gap: 2.5rem; align-items: start; }
.module-hero h1 { font-size: clamp(2.4rem, 5vw, 3.8rem); font-weight: 900; margin: 0 0 .1em; }
.module-hero h1::after { content: ''; display: block; width: 64px; height: 5px; background: var(--c); border-radius: 3px; margin-top: .9rem; }
.module-hero .sub { font-family: var(--display); font-weight: 600; font-size: 1.15rem; text-transform: uppercase; color: #dfe4e9; margin: 1.1rem 0 1.6rem; max-width: 460px; }
.module-hero .soon-badge { display: inline-flex; align-items: center; gap: .5rem; background: var(--c); color: #fff; font-weight: 700; font-size: .8rem; text-transform: uppercase; letter-spacing: .06em; padding: .6rem 1.2rem; border-radius: 999px; }
.module-hero .slogan { font-family: var(--display); font-weight: 800; font-style: italic; text-transform: uppercase; color: var(--steel); font-size: 1.1rem; position: absolute; right: 2.5rem; bottom: 2.2rem; z-index: 2; transform: rotate(-12deg); }
.feature-list { list-style: none; margin: 0; padding: 0; display: grid; gap: .9rem; }
.feature-list li { display: flex; gap: .9rem; align-items: center; color: #e4e8ec; font-size: .98rem; }
.feature-list svg { width: 28px; height: 28px; color: var(--c); flex: none; }
@media (max-width: 860px) {
  .module-hero .inner { grid-template-columns: 1fr; }
  .module-hero::after, .module-hero .slogan { display: none; }
}

/* login dividido */
.auth-split { min-height: 100vh; display: grid; grid-template-columns: minmax(380px, 1fr) 1.25fr; background: #fff; }
.auth-form { display: flex; flex-direction: column; justify-content: center; padding: 3rem clamp(1.5rem, 6vw, 5rem); }
.auth-form .box { width: 100%; max-width: 400px; margin: 0 auto; }
.auth-form h1 { font-size: 1.9rem; text-transform: none; margin: 2.4rem 0 .3rem; }
.auth-form .muted { margin: 0 0 1.8rem; }
.auth-form .row-between { display: flex; justify-content: space-between; align-items: center; margin: -.2rem 0 1.3rem; font-size: .85rem; }
.auth-form .row-between a { color: var(--accent); font-weight: 600; }
.auth-form .btn { padding: .8rem 1.1rem; font-size: .95rem; }
.auth-form .foot { margin-top: 2rem; font-size: .88rem; color: var(--ink-soft); }
.auth-form .foot a { color: var(--accent); font-weight: 600; }
.auth-photo { position: relative; overflow: hidden; color: #fff; display: flex; flex-direction: column; justify-content: flex-end; padding: 3rem;
  background:
    linear-gradient(180deg, rgba(20,24,29,.15) 0%, rgba(20,24,29,.85) 100%),
    var(--auth-img, none) center/cover no-repeat,
    radial-gradient(ellipse at 30% 30%, #4a5561 0%, #1b2027 75%); }
.auth-photo::before { content: ""; position: absolute; right: 0; top: 0; width: 45%; height: 34%; background: linear-gradient(160deg, var(--accent), var(--accent-dark)); clip-path: polygon(0 0, 100% 0, 100% 100%); opacity: .9; }
.auth-photo .quote { position: relative; z-index: 1; font-family: var(--display); font-weight: 800; font-size: clamp(1.6rem, 2.6vw, 2.4rem); line-height: 1.15; max-width: 480px; }
.auth-photo .quote em { font-style: normal; color: var(--accent); }
.auth-photo .chips { position: relative; z-index: 1; display: flex; gap: .5rem; flex-wrap: wrap; margin-top: 1.4rem; }
.auth-photo .chips span { font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; padding: .3rem .7rem; border-radius: 999px; background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.2); }
@media (max-width: 860px) {
  .auth-split { grid-template-columns: 1fr; }
  .auth-photo { display: none; }
}

/* ---------- Academy (catálogo e curso, issue #5) ---------- */
.academy-hero { --c: var(--mod-academy); }
.academy-hero .live-badge {
  display: inline-flex; align-items: center; gap: .5rem; background: var(--c); color: #fff;
  font-weight: 700; font-size: .8rem; text-transform: uppercase; letter-spacing: .06em;
  padding: .6rem 1.2rem; border-radius: 999px; margin-bottom: 1.4rem;
}
a.live-badge:hover { text-decoration: none; filter: brightness(1.08); }
button.live-badge { border: 0; cursor: pointer; font-family: var(--body); }
.academy-search { margin-bottom: 0; max-width: 460px; }
.academy-search input { padding: .8rem 1rem; }
.academy-search button { background: var(--mod-academy); }
.academy-search button:hover { filter: brightness(1.1); }

/* submenu: itens de páginas que ainda não existem (#6 e #10) ficam "em breve" */
.subnav.academy a.active { border-bottom-color: var(--mod-academy); }
.subnav .soon {
  color: #66707c; padding: .7rem .85rem; font-weight: 600; font-size: .82rem;
  white-space: nowrap; cursor: default; display: inline-flex; align-items: center; gap: .5em;
}
.subnav .soon::after {
  content: 'em breve'; font-size: .56rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em;
  padding: .1rem .4rem; border-radius: 3px; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.14); color: #8f99a3;
}

/* toolbar do catálogo */
.academy-toolbar { display: flex; gap: 1rem; align-items: flex-end; flex-wrap: wrap; margin-bottom: 1.4rem; }
.academy-toolbar .field { margin: 0; flex: 0 1 210px; }
.academy-toolbar .field.grow { flex: 1 1 260px; }
.academy-toolbar .btn { margin-bottom: 1px; }

/* grid e card do curso */
.course-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(268px, 1fr)); gap: 1.2rem; }
.course-card { overflow: hidden; display: flex; flex-direction: column; transition: transform .15s ease, box-shadow .15s ease; }
.course-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.course-card .thumb {
  position: relative; aspect-ratio: 16/9; display: grid; place-items: center; gap: .4rem;
  background: linear-gradient(160deg, var(--mod-academy) 10%, #4c2383 90%);
  color: rgba(255,255,255,.9); overflow: hidden;
}
.course-card .thumb svg { width: 46px; height: 46px; }
.course-card .thumb .thumb-word { font-family: var(--mono); font-size: .62rem; letter-spacing: .14em; text-transform: uppercase; opacity: .85; }
.course-card .thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.course-card .thumb .seal {
  position: absolute; top: .6rem; left: .6rem; z-index: 1;
  display: inline-flex; align-items: center; gap: .35em;
  background: rgba(20,24,29,.82); color: #fff; font-weight: 700; font-size: .64rem;
  letter-spacing: .04em; padding: .28rem .6rem; border-radius: 999px;
}
.course-card .thumb .seal svg { width: 13px; height: 13px; }
.course-card .body { padding: .9rem 1rem 1.1rem; display: flex; flex-direction: column; gap: .35rem; flex: 1; }
.course-card .cat {
  font-family: var(--mono); font-size: .64rem; font-weight: 600; letter-spacing: .12em;
  text-transform: uppercase; color: var(--mod-academy);
}
.course-card .title { font-weight: 700; font-size: 1.02rem; color: var(--ink); }
.course-card .title:hover { color: var(--mod-academy); text-decoration: none; }
.course-card .sum {
  margin: 0; color: var(--ink-soft); font-size: .84rem;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.course-card .meta { font-size: .78rem; color: var(--ink-faint); }
.course-card .go {
  margin-top: auto; padding-top: .5rem; color: var(--mod-academy);
  font-weight: 700; font-size: .78rem; text-transform: uppercase; letter-spacing: .05em;
}

/* página do curso */
.course-hero .inner { grid-template-columns: 1fr; }
.hero-back { display: inline-block; color: #c3cbd3; font-weight: 600; font-size: .84rem; margin-bottom: 1rem; }
.hero-back:hover { color: #fff; text-decoration: none; }
.course-hero .sub { margin-top: .9rem; }
.hero-facts { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: 1.5rem; }
.hero-facts span {
  background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.18);
  padding: .35rem .8rem; border-radius: 999px; font-size: .78rem; font-weight: 600; color: #e4e8ec;
}
.course-layout { display: grid; grid-template-columns: 1.45fr 1fr; gap: 1.8rem; align-items: start; }
.course-desc { color: var(--ink-soft); font-size: .95rem; white-space: pre-line; }
.course-side { position: sticky; top: 84px; }
.course-side .side-cover { width: 100%; aspect-ratio: 16/9; object-fit: cover; border-radius: var(--radius); margin-bottom: 1rem; }
.course-side .side-title { margin-bottom: .9rem; }
.course-side .side-price { font-size: 1.6rem; }
.receive-list { list-style: none; margin: 0 0 1.1rem; padding: 0; display: grid; gap: .6rem; }
.receive-list li { display: flex; gap: .6rem; align-items: flex-start; font-size: .9rem; color: var(--ink-soft); }
.receive-list li svg { width: 19px; height: 19px; color: var(--mod-academy); flex: none; margin-top: .15rem; }

/* ementa */
.syllabus { display: grid; gap: .9rem; }
.syllabus-module { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.syllabus-module > h3 {
  margin: 0; padding: .85rem 1.1rem; background: #f8f9fa; border-bottom: 1px solid var(--line);
  font-size: .95rem; display: flex; justify-content: space-between; align-items: center; gap: .8rem;
}
.syllabus-module > h3 > span:first-child { display: inline-flex; align-items: center; gap: .55em; min-width: 0; }
.syllabus-module > h3 svg { width: 17px; height: 17px; color: var(--mod-academy); flex: none; }
.syllabus-module ul { list-style: none; margin: 0; padding: 0; }
.syllabus-module li {
  display: flex; align-items: center; gap: .6rem; padding: .5rem 1.1rem;
  font-size: .9rem; border-top: 1px solid var(--line); min-width: 0;
}
.syllabus-module li:first-child { border-top: 0; }
.syllabus-module li .l-ico { display: inline-flex; color: var(--ink-faint); }
.syllabus-module li .l-ico svg { width: 16px; height: 16px; }
.syllabus-module li .dur { margin-left: auto; font-family: var(--mono); font-size: .72rem; color: var(--ink-faint); white-space: nowrap; }

/* ===== player de aulas e Meus cursos (issue #6) ===== */
.learn-page { padding-top: 1.2rem; }
.learn-top {
  display: flex; align-items: center; gap: 1.2rem; margin-bottom: 1.2rem;
  flex-wrap: wrap; background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius); padding: .8rem 1.1rem; box-shadow: var(--shadow);
}
.learn-back { font-size: .88rem; color: var(--mod-academy); font-weight: 600; white-space: nowrap; }
.learn-top .course-name {
  margin-left: auto; font-size: .82rem; color: var(--ink-faint);
  max-width: 32ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.learn-progress { display: flex; align-items: center; gap: .7rem; flex: 1 1 220px; min-width: 180px; }
.progress-track {
  flex: 1; height: 8px; background: var(--line); border-radius: 99px; overflow: hidden; min-width: 90px;
}
.progress-bar { height: 100%; background: var(--mod-academy); border-radius: 99px; transition: width .3s ease; }
.progress-label { font-family: var(--mono); font-size: .74rem; color: var(--ink-soft); white-space: nowrap; }

.learn-layout { display: grid; grid-template-columns: 300px 1fr; gap: 1.4rem; align-items: start; }
.learn-sidebar {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow); overflow: hidden; position: sticky; top: 84px;
}
.nav-module h3 {
  margin: 0; padding: .8rem 1rem .6rem; font-size: .8rem; text-transform: uppercase;
  letter-spacing: .06em; color: var(--ink-faint); background: #f8f9fa;
}
.nav-module + .nav-module h3 { border-top: 1px solid var(--line); }
.nav-module ul { list-style: none; margin: 0; padding: .3rem 0 .5rem; }
.nav-lesson {
  display: flex; align-items: center; gap: .55rem; width: 100%; text-align: left;
  padding: .5rem .9rem; background: none; border: 0; cursor: pointer;
  font: inherit; font-size: .88rem; color: var(--ink); border-radius: 0;
}
.nav-lesson:hover { background: var(--paper); }
.nav-lesson .l-ico { display: inline-flex; color: var(--ink-faint); flex: none; }
.nav-lesson .l-ico svg { width: 15px; height: 15px; }
.nav-lesson.current { background: color-mix(in srgb, var(--mod-academy) 10%, #fff); box-shadow: inset 3px 0 0 var(--mod-academy); }
.nav-lesson.current .l-ico { color: var(--mod-academy); }
.nav-lesson.done .l-ico { color: var(--ok); }
.nav-lesson .check { margin-left: auto; color: var(--ok); font-weight: 700; font-size: .85rem; }
.nav-lesson span:nth-child(2) { min-width: 0; overflow-wrap: anywhere; }

.learn-player {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 1.4rem 1.6rem 1.6rem; min-width: 0;
  overflow-wrap: anywhere; /* nada de dado do usuário alarga a página */
}
.lesson-head .kicker {
  color: var(--mod-academy); font-size: .76rem; text-transform: uppercase;
  letter-spacing: .08em; font-weight: 700; overflow-wrap: anywhere;
}
.lesson-head h2 { margin: .2rem 0 .2rem; font-size: 1.35rem; overflow-wrap: anywhere; }
.lesson-head .muted { margin: 0 0 1rem; font-size: .84rem; }
.video-frame {
  aspect-ratio: 16 / 9; width: 100%; background: var(--steel);
  border-radius: var(--radius); overflow: hidden; margin-bottom: 1.2rem;
}
.video-frame iframe { width: 100%; height: 100%; display: block; border: 0; }
.video-frame .empty { color: #fff; padding: 1.5rem; }

/* texto da aula: markdown renderizado com segurança (js/markdown.js) —
   quebra até sequências longas sem espaço (URL, identificador, hash) para o
   player caber no viewport de 390 px sem rolagem horizontal (revisão da #6) */
.lesson-text {
  color: var(--ink-soft); font-size: .96rem;
  min-width: 0; overflow-wrap: anywhere; word-break: break-word;
}
.lesson-text > * { max-width: 100%; }
.lesson-text h1, .lesson-text h2, .lesson-text h3, .lesson-text h4 { color: var(--ink); margin: 1.2rem 0 .5rem; overflow-wrap: anywhere; }
.lesson-text h1 { font-size: 1.25rem; }
.lesson-text h2 { font-size: 1.12rem; }
.lesson-text h3 { font-size: 1rem; }
.lesson-text h1:first-child, .lesson-text h2:first-child { margin-top: 0; }
.lesson-text p { margin: .6rem 0; }
.lesson-text ul, .lesson-text ol { margin: .6rem 0; padding-left: 1.4rem; }
.lesson-text li { margin: .25rem 0; overflow-wrap: anywhere; }
.lesson-text a { color: var(--mod-academy); overflow-wrap: anywhere; word-break: break-word; }
.lesson-text img { max-width: 100%; height: auto; }
.lesson-text code {
  font-family: var(--mono); font-size: .85em; background: var(--paper);
  border: 1px solid var(--line); border-radius: 4px; padding: .1em .35em;
  overflow-wrap: anywhere;
}
.lesson-text pre {
  background: var(--steel); color: #e8eaee; border-radius: var(--radius);
  padding: .9rem 1rem; overflow-x: auto; font-size: .84rem; max-width: 100%;
}
.lesson-text pre code { background: none; border: 0; color: inherit; padding: 0; white-space: pre; }
/* tabela (markdown futuro): rola dentro do próprio bloco, sem alargar a página */
.lesson-text table { display: block; width: 100%; max-width: 100%; overflow-x: auto; border-collapse: collapse; }

.lesson-materials { margin-top: 1.2rem; border-top: 1px solid var(--line); padding-top: 1rem; }
.lesson-materials h3 { margin: 0 0 .6rem; font-size: .95rem; }
.lesson-materials ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .45rem; }
.lesson-materials li {
  display: flex; align-items: center; gap: .6rem; font-size: .9rem;
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: .55rem .8rem;
}
.lesson-materials li .l-ico { display: inline-flex; color: var(--mod-academy); }
.lesson-materials li .l-ico svg { width: 16px; height: 16px; }
.lesson-materials li span:nth-child(2) { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.lesson-materials li .btn { flex: none; }
.lesson-actions { display: flex; align-items: center; gap: 1rem; margin-top: 1.3rem; flex-wrap: wrap; }
.lesson-actions .hint { margin: 0; }

.learn-gate { max-width: 560px; margin: 3rem auto; text-align: center; display: grid; gap: .9rem; justify-items: center; }
.learn-gate h2 { margin: 0; }

/* ===== avaliação final (issue #7) ===== */
.quiz-root { display: grid; gap: 1.1rem; max-width: 820px; margin: 0 auto; }
.quiz-card { display: grid; gap: .6rem; min-width: 0; overflow-wrap: anywhere; }
.quiz-card h2 { margin: 0; font-size: 1.3rem; overflow-wrap: anywhere; }
.quiz-card h3 { margin: 0; font-size: 1.05rem; }
.quiz-card .badge { justify-self: start; }
.quiz-head .kicker {
  color: var(--mod-academy); font-size: .76rem; text-transform: uppercase;
  letter-spacing: .08em; font-weight: 700;
}
.quiz-head .muted { margin: .2rem 0 0; font-size: .86rem; }
.quiz-attempts {
  margin: 0; font-family: var(--mono); font-size: .74rem; color: var(--ink-faint);
  text-transform: uppercase; letter-spacing: .05em;
}
.quiz-form-body { display: grid; gap: 1rem; }
.quiz-question {
  margin: 0; padding: .9rem 1rem 1rem; border: 1px solid var(--line);
  border-radius: var(--radius); background: var(--paper); min-width: 0;
}
.quiz-question legend {
  display: flex; gap: .5rem; align-items: baseline; padding: 0 .3rem;
  max-width: 100%; font-family: var(--body); font-size: .95rem; font-weight: 600;
  letter-spacing: normal; text-transform: none; color: var(--ink);
  overflow-wrap: anywhere; white-space: normal;
}
.quiz-question .quiz-number { color: var(--mod-academy); font-family: var(--mono); font-size: .82rem; flex: none; }
.quiz-options { display: grid; gap: .45rem; margin-top: .6rem; }
.quiz-option {
  display: flex; gap: .65rem; align-items: flex-start; padding: .6rem .8rem;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  cursor: pointer; font-size: .92rem; color: var(--ink-soft); min-width: 0;
}
.quiz-option:hover { border-color: var(--mod-academy); }
.quiz-option:focus-within { outline: 2px solid color-mix(in srgb, var(--mod-academy) 45%, #fff); outline-offset: 1px; }
/* o input global do design system é 100% de largura: aqui é rádio, tamanho natural */
.quiz-option input[type="radio"] {
  flex: none; width: auto; padding: 0; margin: .2rem 0 0; border: 0;
  background: none; box-shadow: none; accent-color: var(--mod-academy);
}
.quiz-option span { flex: 1 1 auto; min-width: 0; overflow-wrap: anywhere; }
.quiz-option:has(input:checked) {
  border-color: var(--mod-academy); color: var(--ink);
  background: color-mix(in srgb, var(--mod-academy) 7%, #fff);
  box-shadow: inset 3px 0 0 var(--mod-academy);
}
.quiz-actions { display: flex; align-items: center; gap: .8rem; flex-wrap: wrap; margin-top: .4rem; }
.quiz-counter { font-family: var(--mono); font-size: .74rem; color: var(--ink-faint); }
.quiz-counter.ready { color: var(--ok); }
.quiz-score { margin: 0; font-family: var(--display); color: var(--ink); }
.quiz-score strong { font-size: 2.4rem; line-height: 1; }
.quiz-score span { font-size: .85rem; color: var(--ink-faint); }
.quiz-result.approved { border-left: 4px solid var(--ok); }
.quiz-result.failed { border-left: 4px solid var(--bad); }
.quiz-approved { border-left: 4px solid var(--ok); }
.quiz-exhausted { border-left: 4px solid var(--warn); }
.quiz-wrong-list { margin: .4rem 0 0; padding-left: 1.2rem; display: grid; gap: .7rem; }
.quiz-wrong-list li { min-width: 0; }
.quiz-wrong-list .quiz-statement { margin: 0; font-weight: 600; font-size: .93rem; overflow-wrap: anywhere; }
.quiz-chosen { margin: .2rem 0 0; font-size: .84rem; color: var(--bad); overflow-wrap: anywhere; }
.quiz-gate { max-width: 560px; margin: 2rem auto; text-align: center; display: grid; gap: .8rem; justify-items: center; }
.quiz-gate .icon { font-size: 1.6rem; color: var(--mod-academy); }
.quiz-gate .icon svg { width: 30px; height: 30px; }
.quiz-gate .quiz-actions { justify-content: center; }

/* Meus cursos */
.my-course .progress-line { display: flex; align-items: center; gap: .6rem; margin: .4rem 0; }
.my-course .progress-line .progress-track { height: 7px; }
.my-course .progress-line .progress-label { font-size: .7rem; }
.my-course .meta { display: flex; align-items: center; gap: .4rem; font-size: .78rem; color: var(--ink-faint); }
.my-course-actions { margin: .6rem 0 .5rem; }
.my-course .cert {
  display: inline-flex; align-items: center; gap: .45rem; font-size: .78rem; color: var(--ink-faint);
}
.my-course .cert svg { width: 15px; height: 15px; color: var(--mod-academy); }
.my-course .cert.pending { color: var(--warn); }

/* Certificado emitido (issue #8): download do PDF + verificação pública */
.cert-box {
  display: flex; align-items: center; gap: .8rem; flex-wrap: wrap;
  border: 1px solid var(--line); border-left: 4px solid var(--mod-academy);
  border-radius: var(--radius); background: color-mix(in srgb, var(--mod-academy) 5%, #fff);
  padding: .8rem .9rem; margin-top: .8rem; min-width: 0;
}
.cert-box .cert-icon { display: inline-flex; }
.cert-box .cert-icon svg { width: 26px; height: 26px; color: var(--mod-academy); }
.cert-box .cert-text { display: grid; gap: .1rem; min-width: 0; flex: 1 1 11rem; }
.cert-box .cert-text strong { font-family: var(--display); font-size: .93rem; line-height: 1.25; }
.cert-box .cert-code { font-family: var(--mono); font-size: .74rem; color: var(--ink-faint); overflow-wrap: anywhere; }
.cert-box .cert-actions { display: flex; gap: .5rem; flex-wrap: wrap; }
.cert-box .cert-actions .btn { white-space: normal; }
.cert-box.compact { padding: .7rem .8rem; gap: .55rem; margin-top: .6rem; }
.cert-box.compact .cert-text strong { font-size: .86rem; }
.cert-box.compact .cert-actions { width: 100%; }
.cert-box.compact .cert-actions .btn { flex: 1 1 auto; text-align: center; }

/* Verificação pública do certificado (/certificado.html) */
.cert-verify { display: grid; gap: 1rem; }
.cert-verify-card { display: grid; gap: .55rem; }
.cert-verify-head { display: flex; align-items: center; justify-content: space-between; gap: .8rem; flex-wrap: wrap; }
.cert-verify-icon svg { width: 30px; height: 30px; color: var(--mod-academy); }
.cert-verify-title { margin: 0; font-family: var(--display); font-size: 1.35rem; overflow-wrap: anywhere; }
.cert-verify-name { margin: .2rem 0 0; font-family: var(--display); font-weight: 800; font-size: 1.55rem; color: var(--ink); overflow-wrap: anywhere; }
.cert-verify-course { margin: 0; color: var(--ink-soft); overflow-wrap: anywhere; }
.cert-facts { display: grid; grid-template-columns: max-content 1fr; gap: .35rem 1rem; margin: .5rem 0 0; font-size: .88rem; }
.cert-facts dt { font-family: var(--mono); font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-faint); }
.cert-facts dd { margin: 0; color: var(--ink); min-width: 0; overflow-wrap: anywhere; }
.cert-form { display: flex; gap: .6rem; flex-wrap: wrap; margin-top: .5rem; }
.cert-form input { flex: 1 1 12rem; min-width: 0; font-family: var(--mono); text-transform: uppercase; }
.cert-search-again h3 { margin: 0 0 .2rem; font-family: var(--display); font-size: 1rem; }
.cert-loading { display: grid; justify-items: center; gap: .6rem; text-align: center; }

@media (max-width: 860px) {
  .course-layout { grid-template-columns: 1fr; }
  .course-side { position: static; }
  .academy-toolbar .field { flex: 1 1 100%; }
  .academy-hero .live-badge { margin-bottom: 1.2rem; }
  /* player no celular (390×844): sidebar acima do player, sem rolagem horizontal */
  .learn-layout { grid-template-columns: 1fr; }
  .learn-sidebar { position: static; order: 2; }
  .learn-player { padding: 1.1rem 1rem 1.2rem; }
  .learn-top { gap: .7rem; }
  .learn-top .course-name { display: none; }
  /* avaliação final no celular (390 px): cartões ocupam a largura, sem rolagem horizontal */
  .quiz-root { gap: .9rem; }
  .quiz-card { padding: 1.1rem 1rem; }
  .quiz-question { padding: .8rem .8rem .9rem; }
  .quiz-question legend { display: block; }
  .quiz-question .quiz-number { display: block; margin-bottom: .15rem; }
  .quiz-actions .btn { flex: 1 1 100%; text-align: center; }
  /* certificado no celular (390 px): fatos em coluna, botões na largura, sem rolagem horizontal */
  .cert-box { padding: .75rem .8rem; }
  .cert-box .cert-actions { width: 100%; }
  .cert-box .cert-actions .btn { flex: 1 1 100%; text-align: center; }
  .cert-verify { gap: .8rem; }
  .cert-verify-card { padding: 1.1rem 1rem; }
  .cert-verify-name { font-size: 1.3rem; }
  .cert-facts { grid-template-columns: 1fr; gap: .1rem; }
  .cert-facts dd { margin-bottom: .55rem; }
  .cert-form .btn { flex: 1 1 100%; text-align: center; }
}

/* ============================================================
   Minha equipe — painel do gestor da empresa (issue #10)
   ============================================================ */
.team-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.2rem; align-items: start; }
.team-h { margin: 0 0 .3rem; font-family: var(--display); font-size: 1.1rem; font-weight: 800; }
.team-sub { margin: 0 0 1rem; }
.team-hint { margin-top: .8rem; }
.team-panel { margin-top: 1.4rem; }
.team-panel-head { margin-bottom: 1rem; }
.team-actions { display: flex; gap: .6rem; flex-wrap: wrap; align-items: center; }
.team-check-list {
  display: grid; gap: .1rem; max-height: 220px; overflow-y: auto;
  border: 1px solid var(--line-strong); border-radius: var(--radius);
  padding: .55rem .7rem; background: #fff;
}
.team-check-list .check { padding: .2rem 0; }
.team-check-list .check span { min-width: 0; overflow-wrap: anywhere; }
.team-check-list .muted { margin: .2rem 0; }
.team-result:empty { display: none; }
.team-result-box {
  margin-top: 1rem; border: 1px solid var(--line); border-left: 4px solid var(--mod-academy);
  border-radius: var(--radius); background: color-mix(in srgb, var(--mod-academy) 5%, #fff);
  padding: .8rem .9rem;
}
.team-result-title { margin: 0 0 .4rem; font-weight: 600; font-size: .9rem; overflow-wrap: anywhere; }
.team-result-line { margin: .15rem 0 0; font-size: .85rem; color: var(--ink-soft); overflow-wrap: anywhere; }
.team-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(128px, 1fr)); gap: .7rem; margin-bottom: 1.2rem; }
.team-kpi { border: 1px solid var(--line); border-radius: var(--radius); background: #fff; padding: .65rem .8rem; min-width: 0; }
.team-kpi .n { display: block; font-family: var(--display); font-weight: 800; font-size: 1.35rem; line-height: 1.15; }
.team-kpi .l { display: block; font-family: var(--mono); font-size: .66rem; text-transform: uppercase; letter-spacing: .07em; color: var(--ink-faint); }
.team-progress { display: grid; gap: .2rem; min-width: 110px; }
.team-progress .progress-track { height: 7px; }
.team-email { display: block; font-size: .74rem; overflow-wrap: anywhere; }
.team-row-cont td:first-child { border-left: 3px solid transparent; }
.team-pager { display: flex; gap: .6rem; align-items: center; justify-content: flex-end; flex-wrap: wrap; margin-top: 1rem; }
table.data td .badge + .badge { margin-left: .3rem; }

@media (max-width: 900px) {
  .team-grid { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
  /* celular (390 px): o painel rola dentro do próprio quadro, a página não */
  .team-kpi .n { font-size: 1.15rem; }
  .team-kpi { padding: .55rem .65rem; }
  .team-kpis { grid-template-columns: repeat(auto-fit, minmax(104px, 1fr)); }
  .team-actions .btn { flex: 1 1 100%; text-align: center; }
  .team-pager { justify-content: center; }
  .team-pager .btn { flex: 1 1 100%; text-align: center; }
  .team-check-list { max-height: 260px; }
}
