/* Tarefas de foco (web 15, 15b, 15c, 16, 16b) e a coluna nova da Família e acessos (05c).
   Cada tema tem a sua cor (azul, verde, coral ou sol: Leitura azul, Matemática verde, Esporte coral…). Resultado:
   número (%) OU texto (Resumo), nunca os dois. Errado é coral, nunca vermelho. Só tokens. */

/* ---------------------------------------------------------------- menu e 05c */
.menu-item[href="/app/tarefas"]:not(.ativo) .ic { color: var(--okf-azul); }
.matriz thead th.col-tarefas { color: var(--okf-azul); }
.matriz td.col-tarefas { background: color-mix(in srgb, var(--okf-azul-soft) 60%, transparent); }
.selo-novo.selo-azul { background: var(--okf-azul); color: var(--okf-on-petroleo); }
.nova-area.nova-tarefas { background: var(--okf-azul-soft); }
.nova-area.nova-tarefas .nova-area-titulo .ic { color: var(--okf-azul); }

/* ---------------------------------------------------------------- cores por tipo */
/* tp-<cor> vem do tema (0023); tp-<tipo> fica para o que ainda manda o tipo */
.tp-leitura, .tp-azul { --tp-soft: var(--okf-azul-soft); --tp-texto: var(--okf-azul); --tp-forte: var(--okf-azul); }
.tp-matematica, .tp-verde { --tp-soft: var(--okf-verde-soft); --tp-texto: var(--okf-verde-strong); --tp-forte: var(--okf-verde-strong); }
.tp-esporte, .tp-coral { --tp-soft: var(--okf-coral-soft); --tp-texto: var(--okf-coral-strong); --tp-forte: var(--okf-coral); }
.tp-outro, .tp-sol { --tp-soft: var(--okf-sol-soft); --tp-texto: var(--okf-ink); --tp-forte: var(--okf-sol); }
.tile-tipo { display: grid; place-items: center; flex: none; width: 52px; height: 52px; border-radius: var(--okf-radius-md);
  background: var(--tp-soft); color: var(--tp-texto); }
.tile-tipo .ic { width: 24px; height: 24px; }
.tipo-rotulo { color: var(--tp-texto); font: var(--okf-font-caption); font-size: 13px; }

/* ---------------------------------------------------------------- painel (15) */
.cabeca-tarefas .sobre { margin-bottom: 4px; }
.grade-tarefas { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); gap: var(--okf-space-6); align-items: start; }
.lista-tarefas { display: flex; flex-direction: column; gap: var(--okf-space-3); margin: 0; padding: 0; list-style: none; }
.linha-tarefa { display: flex; align-items: center; gap: var(--okf-space-4); width: 100%; padding: var(--okf-space-4) var(--okf-space-4);
  border: 0; border-radius: var(--okf-radius-md); background: var(--okf-surface-raised); box-shadow: var(--okf-shadow-card);
  color: var(--okf-ink); text-align: left; cursor: pointer; }
.linha-tarefa[aria-current="true"] { box-shadow: inset 0 0 0 2.5px var(--tp-forte), var(--okf-shadow-card); }
.linha-tarefa:focus-visible { outline: 2px solid var(--okf-azul); outline-offset: 2px; }
.linha-tarefa .corpo { flex: 1; min-width: 0; }
.linha-tarefa strong { display: block; font: var(--okf-font-heading); font-size: 18px; }
.linha-tarefa small { display: block; color: var(--okf-ink-muted); font: var(--okf-font-label); font-weight: 600; }
.etiqueta { flex: none; padding: 7px 14px; border-radius: var(--okf-radius-pill); font: var(--okf-font-label); }
.etiqueta-escuro { background: var(--okf-petroleo); color: var(--okf-on-petroleo); font-size: 16px; }
.etiqueta-sol { background: var(--okf-sol-soft); color: var(--okf-ink); }
.etiqueta-neutro { background: var(--okf-surface-sunken); color: var(--okf-ink-muted); }
.lista-vazia { padding: var(--okf-space-6); border-radius: var(--okf-radius-md); background: var(--okf-surface-sunken); text-align: center; }
.coluna-lista { display: flex; flex-direction: column; gap: var(--okf-space-4); }

.detalhe-tarefa { display: flex; flex-direction: column; gap: var(--okf-space-4); padding: var(--okf-space-8); }
.detalhe-tarefa h2 { margin: 0; font: var(--okf-font-title); font-size: 30px; line-height: 1.15; }
.detalhe-tarefa .meta { margin: 0; color: var(--okf-ink-muted); font: var(--okf-font-label); font-weight: 600; }
.caixa-cinza { padding: var(--okf-space-6); border-radius: var(--okf-radius-md); background: var(--okf-surface-sunken); }
.rotulo-caps { display: block; margin: 0 0 6px; color: var(--okf-ink-muted); font: var(--okf-font-caption); letter-spacing: .08em; text-transform: uppercase; }
.caixa-cinza .pergunta-txt { margin: 0; font: var(--okf-font-heading); font-size: 18px; }
.resposta-crianca { margin: var(--okf-space-4) 0 0; padding-top: var(--okf-space-4); border-top: 1px solid var(--okf-line); }
.resposta-crianca blockquote { margin: 0; font: 600 21px/1.4 var(--okf-family-sans); color: var(--okf-ink); }

/* aproveitamento: anel verde proporcional */
.aproveitamento { display: flex; align-items: center; gap: var(--okf-space-8); }
.anel { --p: 0; position: relative; display: grid; place-items: center; flex: none; width: 150px; height: 150px; border-radius: 50%;
  background: conic-gradient(var(--okf-verde) calc(var(--p) * 1%), var(--okf-line) 0); }
.anel::before { content: ""; position: absolute; inset: 16px; border-radius: 50%; background: var(--fundo-anel, var(--okf-surface-sunken)); }
.anel span { position: relative; font: 600 48px/1 var(--okf-family-display); color: var(--okf-ink); }
.aproveitamento strong { display: block; font: var(--okf-font-title); }

.pergunta-mc { display: flex; align-items: center; gap: var(--okf-space-2); flex-wrap: wrap; }
.pergunta-mc > p { flex: 1 1 140px; margin: 0; font: var(--okf-font-heading); font-size: 18px; }
.alt { display: inline-flex; align-items: center; gap: 6px; min-width: 84px; min-height: 56px; padding: 0 var(--okf-space-3);
  border-radius: var(--okf-radius-md); font: 600 24px/1 var(--okf-family-display); box-shadow: inset 0 0 0 1.5px var(--okf-line); }
.alt small { font: var(--okf-font-caption); font-size: 13px; }
.alt .ic { width: 18px; height: 18px; }
.alt-errada { background: var(--okf-coral-soft); color: var(--okf-ink); box-shadow: none; }
.alt-errada .ic, .alt-errada small { color: var(--okf-coral-strong); }
.alt-certa, .alt-certa_crianca { background: var(--okf-verde-soft); color: var(--okf-ink); box-shadow: none; }
.alt-certa .ic, .alt-certa small, .alt-certa_crianca .ic, .alt-certa_crianca small { color: var(--okf-verde-strong); }
.alt-neutra { justify-content: center; color: var(--okf-ink-muted); }

.bloco-resumo { padding: var(--okf-space-6); border-radius: var(--okf-radius-md); background: var(--okf-sol-soft); }
.bloco-resumo h3 { display: flex; align-items: center; gap: var(--okf-space-2); margin: 0 0 var(--okf-space-2); font: var(--okf-font-heading); }
.bloco-resumo p { margin: 0; font: 600 18px/1.4 var(--okf-family-sans); }
.bloco-resumo .nota { margin-top: var(--okf-space-3); font: var(--okf-font-caption); font-size: 13px; color: var(--okf-ink-muted); }
.bloco-resumo.chegando p { color: var(--okf-ink-muted); }
.foto-e-pergunta { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: var(--okf-space-6); align-items: start; }
.foto-tarefa { position: relative; margin: 0; overflow: hidden; border-radius: var(--okf-radius-md); background: var(--okf-surface-sunken); }
.foto-tarefa img { display: block; width: 100%; height: auto; max-height: 480px; object-fit: contain; }
.foto-tarefa figcaption { position: absolute; left: 12px; bottom: 12px; padding: 4px 10px; border-radius: var(--okf-radius-pill);
  background: var(--okf-petroleo); color: var(--okf-on-petroleo); font: var(--okf-font-caption); }
.acoes-foco { display: flex; gap: var(--okf-space-3); flex-wrap: wrap; }
.pendente-lista { margin: 0; padding-left: 1.2em; }
.pendente-lista li { margin: 4px 0; font: var(--okf-font-heading); font-size: 16px; }
.pendente-lista small { display: block; color: var(--okf-ink-muted); font: var(--okf-font-label); font-weight: 600; }

/* ---------------------------------------------------------------- nova tarefa (16) */
.cabeca-editor-tarefa { display: flex; align-items: center; gap: var(--okf-space-4); flex-wrap: wrap; margin-bottom: var(--okf-space-6); }
.cabeca-editor-tarefa .voltar { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 50%; background: var(--okf-surface-raised);
  box-shadow: var(--okf-shadow-card); color: var(--okf-ink); }
.cabeca-editor-tarefa > div { flex: 1; min-width: 220px; }
.cabeca-editor-tarefa h1 { margin: 0; font: var(--okf-font-display); }
.grade-nova { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--okf-space-6); align-items: start; }
.form-tarefa { display: flex; flex-direction: column; gap: var(--okf-space-4); }
.form-tarefa h2 { margin: 0; font: var(--okf-font-heading); font-size: 20px; }
.tipos { display: grid; grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); gap: var(--okf-space-2); }
.tipos label, .tipos .tema-novo { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 6px; min-height: 84px; padding: 6px; border-radius: var(--okf-radius-md); background: var(--tp-soft); cursor: pointer;
  font: var(--okf-font-label); text-align: center; overflow-wrap: anywhere; }
.tipos .tema-novo { border: 2px dashed var(--okf-line); background: transparent; color: var(--okf-ink-muted); }
.tipos .tema-novo .ic { color: var(--okf-ink-muted); }
.temas-familia-link { align-self: flex-start; margin-top: calc(-1 * var(--okf-space-2)); }
.abas-tarefa { margin-top: var(--okf-space-2); }
.grade-temas { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--okf-space-6); align-items: start; }
.lista-temas .selo-base { font: var(--okf-font-caption); color: var(--okf-ink-muted); }
.sugerir-linha { display: flex; flex-wrap: wrap; align-items: center; gap: var(--okf-space-2) var(--okf-space-3); }
.sugerir-linha small { flex: 1; min-width: 180px; }
/* modal do tema: ícones e cores */
.tema-form { display: flex; flex-direction: column; gap: var(--okf-space-4); }
.icones-tema { display: grid; grid-template-columns: repeat(auto-fill, minmax(44px, 1fr)); gap: 6px; }
.icones-tema label { position: relative; display: grid; place-items: center; height: 44px; border-radius: var(--okf-radius-sm);
  background: var(--okf-surface-sunken); color: var(--okf-ink); cursor: pointer; }
.icones-tema input, .cores-tema input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.icones-tema label:has(input:checked) { background: var(--tp-soft); color: var(--tp-texto); box-shadow: inset 0 0 0 2px var(--tp-forte); }
.icones-tema label:has(input:focus-visible), .cores-tema label:has(input:focus-visible) { outline: 2px solid var(--okf-azul); outline-offset: 2px; }
.cores-tema { display: flex; flex-wrap: wrap; gap: var(--okf-space-2); }
.cores-tema label { position: relative; display: flex; flex-direction: row; align-items: center; gap: 8px; min-height: 44px; padding: 0 14px 0 8px;
  border-radius: var(--okf-radius-pill); background: var(--tp-soft); color: var(--tp-texto); font: var(--okf-font-label); cursor: pointer; }
.cores-tema label::before { content: ""; width: 24px; height: 24px; border-radius: 50%; background: var(--tp-forte); }
.cores-tema label:has(input:checked) { box-shadow: inset 0 0 0 2px var(--tp-forte); }
.previa-tema { display: flex; align-items: center; gap: var(--okf-space-3); padding: var(--okf-space-3); border-radius: var(--okf-radius-md);
  background: var(--okf-surface-sunken); }
.lista-temas { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: var(--okf-space-2); }
.lista-temas li { display: flex; align-items: center; gap: var(--okf-space-3); }
.lista-temas li > strong { flex: 1; min-width: 0; }
.lista-temas .tile-tipo { width: 40px; height: 40px; border-radius: var(--okf-radius-sm); }
.tipos label .ic { width: 28px; height: 28px; color: var(--tp-texto); }
.tipos input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.tipos label:has(input:checked) { box-shadow: inset 0 0 0 2.5px var(--tp-forte); }
.tipos label:has(input:focus-visible) { outline: 2px solid var(--okf-azul); outline-offset: 2px; }
.linha-dupla { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--okf-space-4); }
.passo-min { display: flex; align-items: center; justify-content: space-between; min-height: 52px; padding: 0 6px;
  border-radius: var(--okf-radius-md); background: var(--okf-surface-sunken); font: var(--okf-font-heading); }
.passo-min button { display: grid; place-items: center; width: 40px; height: 40px; border: 0; border-radius: 50%;
  background: var(--okf-surface-raised); color: var(--okf-ink); cursor: pointer; }
.modos { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--okf-space-3); }
.modos label { position: relative; display: block; padding: var(--okf-space-4); border-radius: var(--okf-radius-md); cursor: pointer;
  box-shadow: inset 0 0 0 1.5px var(--okf-line); font: var(--okf-font-heading); }
.modos label small { display: block; margin-top: 4px; }
.modos input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.modos label:has(input[value="multipla_escolha"]:checked) { background: var(--okf-verde-soft); box-shadow: inset 0 0 0 2.5px var(--okf-verde-strong); }
.modos label:has(input[value="aberta"]:checked) { background: var(--okf-azul-soft); box-shadow: inset 0 0 0 2.5px var(--okf-azul); }
.modos label:has(input:focus-visible) { outline: 2px solid var(--okf-azul); outline-offset: 2px; }
.pergunta-form { display: flex; flex-direction: column; gap: var(--okf-space-3); padding: var(--okf-space-4); border-radius: var(--okf-radius-md);
  background: var(--okf-surface-sunken); }
.pergunta-topo { display: flex; align-items: center; gap: var(--okf-space-3); }
.pergunta-topo input { flex: 1; }
.numero { display: grid; place-items: center; flex: none; width: 30px; height: 30px; border-radius: 50%; background: var(--okf-petroleo);
  color: var(--okf-on-petroleo); font: var(--okf-font-label); }
.tirar-pergunta { flex: none; display: grid; place-items: center; width: 40px; height: 40px; border: 0; border-radius: 50%;
  background: none; color: var(--okf-ink-muted); cursor: pointer; }
.alts-form { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--okf-space-2); padding-left: 42px; }
.alt-form { display: flex; align-items: center; gap: 6px; padding: 6px; border-radius: var(--okf-radius-md); background: var(--okf-surface-raised);
  box-shadow: inset 0 0 0 1.5px var(--okf-line); }
.alt-form:has(.certa-radio:checked) { box-shadow: inset 0 0 0 2px var(--okf-verde-strong); }
.alt-form input[type="text"] { min-width: 0; border: 0; box-shadow: none; padding: 6px 4px; background: transparent; }
.certa-radio { appearance: none; flex: none; width: 30px; height: 30px; margin: 0; border-radius: 50%; border: 2px solid var(--okf-line);
  background: var(--okf-surface-raised); cursor: pointer; display: grid; place-items: center; }
.certa-radio:checked { border-color: var(--okf-verde-strong); background: var(--okf-verde-strong); }
.certa-radio:checked::after { content: ""; width: 10px; height: 6px; margin-top: -3px; border-left: 2.5px solid var(--okf-on-verde);
  border-bottom: 2.5px solid var(--okf-on-verde); transform: rotate(-45deg); }
.certa-radio:focus-visible { outline: 2px solid var(--okf-azul); outline-offset: 2px; }
.dica-alt { margin: 0; padding-left: 42px; }
.foto-toggle { display: flex; align-items: center; gap: var(--okf-space-3); padding: var(--okf-space-3); border-radius: var(--okf-radius-md);
  background: var(--okf-surface-raised); }
.foto-toggle > span:first-child { flex: 1; display: flex; flex-direction: column; font: var(--okf-font-label); }
.btn-adicionar { width: 100%; min-height: 52px; box-shadow: inset 0 0 0 1.5px var(--okf-line); }
.btn-adicionar small { color: var(--okf-ink-muted); font: inherit; font-weight: 600; }
.erro-form { margin: 0; color: var(--okf-coral-strong); font: var(--okf-font-label); }

@media (max-width: 1100px) {
  .grade-tarefas, .grade-nova { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  .tipos { grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); }
  .grade-temas { grid-template-columns: minmax(0, 1fr); }
  .alts-form { grid-template-columns: minmax(0, 1fr); padding-left: 0; }
  .dica-alt { padding-left: 0; }
  .foto-e-pergunta, .linha-dupla, .modos { grid-template-columns: minmax(0, 1fr); }
  .aproveitamento { gap: var(--okf-space-4); }
  .anel { width: 110px; height: 110px; }
  .anel span { font-size: 36px; }
  .detalhe-tarefa { padding: var(--okf-space-6); }
}
.rotulo-campo { display: block; margin-bottom: 6px; font: var(--okf-font-label); color: var(--okf-ink); }
.foto-e-pergunta .pergunta-txt { margin: 0; font: var(--okf-font-heading); font-size: 18px; }
.andamento { margin-top: var(--okf-space-3); }
/* labels do formulário em linha (o label global é coluna) */
.alt-form, .foto-toggle { flex-direction: row; }
.certa-radio { min-width: 30px; max-width: 30px; padding: 0; box-shadow: none; }
.certa-radio:focus { box-shadow: none; }
