html, body {
    /* Trava o deslize lateral: a tela só rola na vertical, sem "escorregar" pros lados */
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
    overscroll-behavior-x: none;
}

body {
    margin: 0;
    padding: 0;
    background: #f5f5f5;
    font-family: Arial, sans-serif;
    position: relative;
}

.topo {
    background: linear-gradient(135deg, rgb(4,75,70) 0%, rgb(6,107,99) 60%, rgb(7,125,115) 100%);
    padding: 14px 18px 18px;
    width: 100%;
    box-sizing: border-box;
    position: relative;
    overflow: visible;
}

.topo-conteudo {
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
    z-index: 1;
}

.topo-esquerda {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-circulo {
  width: 65px;
  height: 65px;
  border-radius: 10%;
  overflow: hidden;

  display: flex;
  align-items: center;
  justify-content: center;
}

.logo-circulo img {
  width: 110%;
  height: 110%;
  object-fit: contain;
}

.topo-divisor {
    width: 1px;
    height: 42px;
    background: rgba(255,255,255,0.28);
    flex-shrink: 0;
}

.topo-texto h1 {
    font-size: 17px;
    font-weight: 800;
    color: white;
    margin: 0;
    letter-spacing: 0.4px;
    text-align: left;
}

.topo-texto p {
    font-size: 11px;
    color: rgba(185,235,228,0.9);
    margin: 3px 0 0;
    font-weight: 400;
}

.topo-direita {
    display: flex;
    align-items: center;
    gap: 8px;
}

.topo-icone {
    border-radius: 50%;
    background: rgba(255,255,255,0.12);
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    position: relative;
    padding: 8px;
}

.topo-svg {
    width: 20px;
    height: 20px;
    stroke: white;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.topo-chevron {
    width: 13px;
    height: 13px;
}

/* Setinha de voltar no topo (iPhone em modo app) */
.topo-voltar {
    width: 34px !important;
    height: 34px;
    min-width: 34px;
    padding: 0 !important;
    margin: 0 !important;
    background: rgba(255,255,255,0.16) !important;
    border-radius: 50% !important;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.topo-voltar .topo-svg { width: 18px; height: 18px; stroke-width: 2.4; }
.topo-voltar:active { background: rgba(255,255,255,0.28) !important; }

.topo-usuario-wrap {
    position: relative;
}

.topo-usuario-btn {
    border-radius: 22px;
    padding: 8px 12px 8px 10px;
    gap: 4px;
}

.dropdown-usuario {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    background: white;
    border-radius: 12px;
    box-shadow: 0 6px 24px rgba(0,0,0,0.15);
    padding: 6px;
    min-width: 160px;
    display: none;
    z-index: 1000;
}

.dropdown-usuario.aberto {
    display: block;
}

.dropdown-item {
    width: 100%;
    padding: 12px 16px;
    background: none;
    border: none;
    text-align: left;
    font-size: 14px;
    font-weight: 600;
    color: #ef4444;
    cursor: pointer;
    border-radius: 8px;
}

.dropdown-item:hover {
    background: #fef2f2;
}

.card {
    background: white;
    width: 90%;
    max-width: 380px;
    margin: 30px auto;
    padding: 20px;
    border-radius: 14px;
    box-shadow: 0 2px 6px rgba(33, 32, 32, 0.15);
}

.card h2 {
    text-align: center;
    color: rgb(6, 107, 99);
    margin-top: 0;
}

input,
select {
    width: 100%;
    padding: 10px;
    margin-bottom: 15px;
    box-sizing: border-box;
    font-size: 16px;
}

.input-unidade {
    display: flex;
    align-items: center;
    width: 100%;
    margin-bottom: 15px;
    border: 1px solid #999;
    box-sizing: border-box;
    background: white;
}

.input-unidade input {
    flex: 1;
    border: none;
    margin-bottom: 0;
    padding: 10px;
    box-sizing: border-box;
    outline: none;
    font-size: 16px;
}

.input-unidade span {
    background: #f2f2f2;
    width: 50px;
    text-align: center;
    padding: 10px 0;
    color: #555;
    border-left: 1px solid #999;
    box-sizing: border-box;
}

button {
    width: 100%;
    padding: 12px;
    background: rgb(6, 107, 99);
    color: white;
    border: none;
    border-radius: 10px;
    cursor: pointer;
}

.limpar {
    background: transparent;
    color: gray;
    border: none;
    margin-top: 10px;
    cursor: pointer;
    display: block;
}

.resultado {
    margin-top: 25px;
    color: rgb(6, 107, 99);
}

.resultado-box {
    background: #f5f5f5;
    border: 1px solid #ddd;
    border-radius: 10px;
    padding: 12px 14px;
    width: 260px;
    margin: 0 auto 12px auto;
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

.resultado-box p {
    font-size: 18px;
    font-weight: bold;
    color: #333;
    margin: 0 0 8px 0;
}

.resultado-box h3 {
    font-size: 20px;
    color: rgb(6, 107, 99);
    margin: 0;
}

.resultado-box span {
    display: block;
    font-size: 14px;
    color: #666;
    margin: 8px 0 0 0;
}

.resultado-box.destaque {
    background: rgb(6, 107, 99);
    border: none;
}

.resultado-box.destaque p,
.resultado-box.destaque h3,
.resultado-box.destaque span {
    color: white;
}

.sobrevivencia-texto {
    text-align: center;
    color: #555;
    font-size: 16px;
    margin-top: 10px;
}

.botoes-gestao {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-top: 15px;
    align-items: stretch;
}

.botao-gestao {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: rgb(6, 107, 99);
    color: white;
    border: none;
    border-radius: 14px;
    padding: 18px 10px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    width: 100%;
    text-align: center;
    min-height: 80px;
}

.botao-gestao:active {
    background: rgb(4, 85, 79);
}

.btn-svg {
    width: 30px;
    height: 30px;
    flex-shrink: 0;
    stroke: white;
    fill: none;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.viveiro-card {
    background: white;
    border-radius: 20px;
    padding: 20px;
    margin-top: 18px;
    border: 1px solid #e8e8e8;
    box-shadow: 0 2px 12px rgba(0,0,0,0.07);
}

/* Topo do card */
.vc-topo {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.vc-icone-box {
    background: #e6f4f1;
    border-radius: 14px;
    width: 52px;
    height: 52px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    flex-shrink: 0;
}

.vc-titulo-area {
    flex: 1;
}

.vc-titulo-area h3 {
    margin: 0 0 4px 0;
    color: #111827;
    font-size: 20px;
    font-weight: 800;
}

.vc-badge-cultivo {
    background: #dcfce7;
    color: #16a34a;
    font-size: 12px;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: 20px;
    display: inline-block;
}

.vc-badge-vazio {
    background: #fee2e2;
    color: #dc2626;
    font-size: 12px;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: 20px;
    display: inline-block;
}

.vc-pls-badge {
    background: #e6f4f1;
    color: rgb(6,107,99);
    font-size: 12px;
    font-weight: 700;
    padding: 8px 12px;
    border-radius: 14px;
    text-align: center;
    flex-shrink: 0;
    white-space: nowrap;
}

/* Separador */
.vc-separador {
    border: none;
    border-top: 1px solid #f3f4f6;
    margin: 0 0 16px 0;
}

/* Itens de info */
.vc-info-lista {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 18px;
}

.vc-info-item {
    display: flex;
    align-items: center;
    gap: 14px;
}

.vc-info-icone {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    flex-shrink: 0;
}

.vc-info-icone.verde { background: #e6f4f1; }
.vc-info-icone.azul  { background: #dbeafe; }
.vc-info-icone.roxo  { background: #ede9fe; }

.vc-info-item strong {
    display: block;
    font-size: 14px;
    font-weight: 700;
    color: #111827;
}

.vc-info-item p {
    margin: 2px 0 0 0;
    font-size: 13px;
    color: #6b7280;
}

.botao-abrir {
    width: 100%;
    background: rgb(6, 107, 99);
    color: white;
    border: none;
    border-radius: 14px;
    padding: 14px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    letter-spacing: 0.3px;
}

.painel-viveiro {
    background: white;
    border-radius: 18px;
    padding: 20px;
    margin-top: 20px;
    border: 1px solid #ececec;
    box-shadow: 0 2px 10px rgba(0,0,0,0.06);
}

/* ─── VIVEIRO HEADER ─────────────────────────────────────────────────────── */

.viveiro-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 18px;
}

.viveiro-titulo {
    margin: 0;
    font-size: 20px;
    font-weight: 900;
    color: #1f2937;
    letter-spacing: 0.3px;
}

.viveiro-pls {
    display: flex;
    flex-direction: column;
    align-items: center;
    background: rgba(6,107,99,0.08);
    border-radius: 12px;
    padding: 10px 16px;
}

.pls-numero {
    font-size: 16px;
    font-weight: 800;
    color: rgb(6,107,99);
    line-height: 1.1;
}

.pls-label {
    font-size: 11px;
    color: #6b7280;
    font-weight: 600;
}

/* ─── INFO BOXES ─────────────────────────────────────────────────────────── */

.painel-info {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 18px;
}

.info-box {
    background: #f8fafc;
    border-radius: 14px;
    padding: 12px 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 4px;
}

.info-box-icone {
    width: 32px;
    height: 32px;
    background: rgba(6,107,99,0.10);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 4px;
}

.info-box-icone svg {
    width: 17px;
    height: 17px;
    stroke: rgb(6,107,99);
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.info-box small {
    display: block;
    color: #6b7280;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.info-box strong {
    color: #1f2937;
    font-size: 15px;
    font-weight: 700;
}

/* KPI em destaque, largura total */
.info-box-kpi {
    grid-column: 1 / -1;
    background: #f0fdf4;
    border: 1.5px solid #d1fae5;
}
.info-box-kpi strong {
    color: rgb(6,107,99);
    font-size: 18px;
}
body.tema-escuro .info-box-kpi {
    background: #052e2b;
    border-color: #0f4d47;
}
body.tema-escuro .info-box-kpi strong { color: #34d399; }

/* ─── BOTÕES DO PAINEL ───────────────────────────────────────────────────── */

.painel-acoes {
    display: grid;
    gap: 10px;
}

.botao-painel {
    background: rgb(6,107,99);
    color: white;
    border: none;
    border-radius: 12px;
    padding: 15px 16px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    width: 100%;
    text-align: center;
}

.botao-painel svg:first-child {
    width: 20px;
    height: 20px;
    stroke: white;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    flex-shrink: 0;
}

.seta-btn {
    width: 16px !important;
    height: 16px !important;
    margin-left: auto;
    opacity: 0.7;
}

.botao-reiniciar {
    background: #6b7280 !important;
}

.tabela-historico {
    margin-top: 15px;
}

.linha-historico {
    display: grid;
    grid-template-columns: 0.6fr 1.2fr 1fr;
    gap: 10px;
    padding: 10px 4px;
    border-bottom: 1px solid #e5e7eb;
    font-size: 14px;
    align-items: center;
}

.linha-historico.cabecalho {
    font-weight: bold;
    color: rgb(6,107,99);
    border-bottom: 2px solid rgb(6,107,99);
}

.historico-lista {
    margin-top: 20px;
}

.historico-cabecalho,
.historico-item {
    display: grid;
    grid-template-columns: 1fr 1fr;
    padding: 10px 4px;
    border-bottom: 1px solid #e5e7eb;
    font-size: 14px;
}

.historico-cabecalho {
    font-weight: bold;
    color: rgb(6,107,99);
}

/* ─── OPÇÕES DE HISTÓRICO ────────────────────────────────────────────────── */

.historico-opcoes-grid {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 12px;
}

.botao-historico-opcao {
    display: flex;
    align-items: center;
    gap: 14px;
    background: white;
    border: 1.5px solid #e5e7eb;
    border-radius: 14px;
    padding: 14px 16px;
    font-size: 15px;
    font-weight: 700;
    color: #1f2937;
    cursor: pointer;
    width: 100%;
    text-align: left;
    transition: border-color 0.18s, background 0.18s;
}

.botao-historico-opcao:active {
    background: #f0fdf4;
    border-color: rgb(6,107,99);
}

.botao-historico-opcao svg {
    width: 20px;
    height: 20px;
    stroke: rgb(6,107,99);
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    flex-shrink: 0;
}

.botao-historico {
    background: rgb(6,107,99);
    color: white;
    border: none;
    border-radius: 10px;
    padding: 10px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}

.linha-historico-racao {
    display: grid;
    grid-template-columns: 0.5fr 1fr 0.9fr 0.7fr;
    gap: 6px;
    padding: 10px 4px;
    border-bottom: 1px solid #e5e7eb;
    font-size: 14px;
    align-items: center;
}

.linha-historico-racao.cabecalho {
    font-weight: bold;
    color: rgb(6,107,99);
    border-bottom: 2px solid rgb(6,107,99);
    font-size: 12px;
    letter-spacing: 0.5px;
}

.linha-historico-acoes {
    display: grid;
    grid-template-columns: 0.9fr 0.9fr 0.8fr 0.7fr;
    gap: 6px;
    padding: 10px 4px;
    border-bottom: 1px solid #e5e7eb;
    font-size: 14px;
    align-items: center;
}

.linha-historico-acoes.cabecalho {
    font-weight: bold;
    color: rgb(6,107,99);
    border-bottom: 2px solid rgb(6,107,99);
    font-size: 12px;
    letter-spacing: 0.5px;
}

.col-centro {
    text-align: center;
}

.col-acoes {
    display: flex;
    gap: 2px;
    justify-content: flex-end;
    align-items: center;
}

.botao-excluir {
    color: #dc2626;
}

.titulo-secao-historico {
    text-align: center;
    text-transform: uppercase;
    font-size: 14px;
    font-weight: 800;
    color: rgb(6,107,99);
    letter-spacing: 1px;
    margin: 0 0 10px 0;
}

.caption-edicao {
    text-align: center;
    color: #6b7280;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin: 0 0 4px 0;
}

.titulo-edicao {
    text-align: center;
    text-transform: uppercase;
    font-size: 20px;
    color: #1f2937;
    font-weight: 900;
    margin: 0 0 22px 0;
}

.input-senha {
    display: flex;
    align-items: center;
    border: 1px solid #ccc;
    border-radius: 6px;
    margin-bottom: 15px;
    background: white;
    overflow: hidden;
}

.input-senha input {
    flex: 1;
    border: none;
    padding: 10px;
    font-size: 16px;
    outline: none;
    margin-bottom: 0;
    width: auto;
}

.botao-olho {
    background: none;
    border: none;
    padding: 0 12px;
    cursor: pointer;
    width: auto;
    min-width: unset;
    height: 100%;
    color: #9ca3af;
    display: flex;
    align-items: center;
}

.botao-editar {
    background: none;
    border: none;
    padding: 0;
    margin: 0;
    font-size: 15px;
    cursor: pointer;
    width: auto;
    min-width: unset;
    height: auto;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.botao-form {
    width: 220px;
    display: block;
    margin: 12px auto 0 auto;
}

.botao-voltar {
    display: block;
    width: auto;
    margin: 10px auto 0 auto;
    padding: 6px 10px;
    background: transparent;
    color: #6b7280;
    border: none;
    font-size: 14px;
    cursor: pointer;
}

.botao-alerta {
    background: #f59e0b;
}

.botao-alerta:hover {
    background: #d97706;
}

.botao-perigo {
    background: #dc2626;
}

.botao-perigo:hover {
    background: #b91c1c;
}

.botao-perigo-outline {
    background: transparent;
    color: #dc2626;
    border: 1.5px solid #dc2626;
}

.botao-perigo-outline:hover {
    background: #fef2f2;
}

/* ─── RELATÓRIO REDESIGN ─────────────────────────────────────────────────── */

.relatorio-final {
    background: white;
    width: 100%;
    max-width: 850px;
    margin: 8px auto 20px;
    padding: 24px 20px 20px;
    box-sizing: border-box;
    border-radius: 20px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.07);
}

/* Header: centralizado */
.rel-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    margin-bottom: 14px;
    text-align: center;
}

.rel-titulo-principal {
    font-size: 22px;
    font-weight: 900;
    color: #1f2937;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.rel-marca-nome {
    font-size: 13px;
    font-weight: 700;
    color: #0f766e;
    letter-spacing: 1.5px;
    text-transform: uppercase;
}

.rel-viveiro-badge {
    display: block;
    text-align: center;
    background: #e6f4f1;
    color: #0f766e;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 800;
    margin-bottom: 14px;
    border: 1.5px solid rgba(15,118,110,0.18);
    width: fit-content;
    margin-left: auto;
    margin-right: auto;
}

.rel-divider {
    height: 1px;
    background: #e5e7eb;
    margin-bottom: 16px;
}

/* Período */
.rel-periodo {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #f8fafc;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 10px 14px;
    margin-bottom: 4px;
}

.rel-periodo-datas {
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: 14px;
    font-weight: 600;
    color: #374151;
}

.rel-periodo-datas svg {
    width: 15px;
    height: 15px;
    stroke: #6b7280;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    flex-shrink: 0;
}

.rel-seta {
    color: #9ca3af;
    font-size: 13px;
}

.rel-periodo-dias {
    background: #0f766e;
    color: white;
    font-size: 12px;
    font-weight: 800;
    padding: 4px 10px;
    border-radius: 20px;
    white-space: nowrap;
}

/* Seções */
.relatorio-secao {
    margin-top: 20px;
}

.relatorio-secao h3 {
    color: #0f766e;
    margin: 0 0 12px;
    font-size: 14px;
    font-weight: 800;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 1.2px;
}

/* Linhas de info compactas */
.rel-info-lista {
    background: #f8fafc;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    overflow: hidden;
}

.rel-info-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 14px;
    border-bottom: 1px solid #f0f1f3;
}

.rel-info-row:last-child {
    border-bottom: none;
}

.rel-info-esq {
    display: flex;
    align-items: center;
    gap: 9px;
    font-size: 14px;
    color: #6b7280;
    font-weight: 500;
}

.rel-info-esq svg {
    width: 15px;
    height: 15px;
    stroke: #9ca3af;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    flex-shrink: 0;
}

.rel-info-row strong {
    font-size: 14px;
    font-weight: 800;
    color: #1f2937;
}

/* Métricas de resultado produtivo */
.rel-metricas-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 10px;
}

.rel-metrica-card {
    background: #f8fafc;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 10px 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    border-top: 3px solid #0f766e;
}

.rel-metrica-valor {
    font-size: 18px;
    font-weight: 900;
    color: #0f766e;
    letter-spacing: -0.3px;
    line-height: 1;
}

.rel-metrica-unidade {
    font-size: 12px;
    font-weight: 700;
    color: #6b7280;
    margin-top: 2px;
}

.rel-metrica-nome {
    font-size: 10px;
    font-weight: 600;
    color: #9ca3af;
    margin-top: 5px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Sobrevivência: linha full-width */
.rel-sobrevivencia {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #f0fdf4;
    border: 1.5px solid #bbf7d0;
    border-radius: 14px;
    padding: 13px 16px;
}

.rel-sobrev-esq {
    display: flex;
    align-items: center;
    gap: 9px;
    font-size: 14px;
    font-weight: 600;
    color: #166534;
}

.rel-sobrev-esq svg {
    width: 16px;
    height: 16px;
    stroke: #16a34a;
    fill: none;
    stroke-width: 2.5;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.rel-sobrev-valor {
    font-size: 22px;
    font-weight: 900;
    color: #16a34a;
    letter-spacing: -0.5px;
}

/* Produção final — linha de fechamento compacta */
.rel-producao-hero {
    margin-top: 16px;
    background: #0f766e;
    border-radius: 12px;
    padding: 11px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.rel-producao-hero svg {
    display: none;
}

.rel-hero-label {
    font-size: 11px;
    font-weight: 700;
    color: rgba(255,255,255,0.75);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.rel-hero-valor {
    font-size: 18px;
    font-weight: 900;
    color: white;
    letter-spacing: -0.2px;
}

.acoes-relatorio {
    margin-top: 18px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

#menuGestao {
    display: none;
}

/* ─── BOAS VINDAS ────────────────────────────────────────────────────────── */

.boas-vindas {
    text-align: center;
    padding: 30px 0;
    color: #9ca3af;
    font-size: 15px;
}

/* ─── LOGIN / CADASTRO ───────────────────────────────────────────────────── */

/* ─── LOGIN ───────────────────────────────────────────────────────────────── */

.card.modo-login {
    background: linear-gradient(160deg, #ddf2ee 0%, #edfaf7 45%, #e2f5f0 100%);
    box-shadow: none;
    padding: 0;
    overflow: hidden;
}

.login-wrapper {
    position: relative;
    padding: 28px 20px 24px;
    overflow: hidden;
}

.login-wrapper::after {
    content: "🦐";
    position: absolute;
    right: -14px;
    top: 42%;
    font-size: 110px;
    opacity: 0.06;
    pointer-events: none;
    transform: scaleX(-1);
}

.login-topo {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 22px;
}

.login-logo {
    width: 76px !important;
    height: 76px !important;
    border: 2.5px solid rgba(6,107,99,0.45) !important;
    background: white !important;
    margin-bottom: 14px;
    box-shadow: 0 4px 18px rgba(6,107,99,0.14);
}

.login-logo .logo-wa {
    color: rgb(6,107,99) !important;
    font-size: 19px;
}

.login-logo .logo-camarao {
    font-size: 21px;
}

.login-logo { overflow: hidden; padding: 0 !important; }
.login-logo-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #fff;
    border-radius: 50%;
    display: block;
}

.titulo-login {
    text-align: center;
    font-size: 30px;
    font-weight: 900;
    color: rgb(6, 107, 99);
    letter-spacing: -0.5px;
    margin: 0 0 4px 0;
}

.titulo-menor {
    font-size: 22px;
}

/* ─── CAMPOS DE FORMULÁRIO COM ÍCONE ────────────────────────────────────────── */

.campo-form {
    margin-bottom: 14px;
}

.campo-label {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
}

.campo-label label {
    font-weight: 700;
    font-size: 14px;
    color: #1f2937;
    margin: 0;
}

.campo-icone {
    width: 22px;
    height: 22px;
    stroke: rgb(6, 107, 99);
    fill: none;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
    flex-shrink: 0;
}

.botao-salvar {
    width: 100%;
    padding: 13px 16px;
    background: rgb(6, 107, 99);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 4px;
}

.botao-salvar:active {
    background: rgb(4, 85, 79);
}

.botao-salvar:disabled { cursor: default; }
.botao-salvar.btn-carregando { opacity: 0.9; }
.btn-spinner {
    display: inline-block;
    width: 15px;
    height: 15px;
    border: 2px solid rgba(255, 255, 255, 0.4);
    border-top-color: #fff;
    border-radius: 50%;
    animation: btnspin 0.6s linear infinite;
    will-change: transform;
}
@keyframes btnspin { to { transform: rotate(360deg); } }
.spin-svg { animation: btnspin 0.8s linear infinite; transform-origin: center; will-change: transform; }

/* Feedback de toque nos botões: afunda + brilho na hora do clique */
button { transition: transform .12s ease, filter .12s ease, box-shadow .12s ease; }
button:active:not(:disabled) {
    transform: scale(0.96);
    filter: brightness(1.12);
}
/* Onda de brilho (ripple) que sai do ponto tocado */
.btn-ripple {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    transform: scale(0);
    opacity: 0.7;
    pointer-events: none;
    animation: btnRipple .5s ease-out forwards;
    z-index: 0;
}
@keyframes btnRipple { to { transform: scale(2.4); opacity: 0; } }

.botao-voltar-form {
    display: block;
    width: 100%;
    padding: 12px;
    margin-top: 10px;
    background: transparent;
    color: rgb(6, 107, 99);
    border: 2px solid rgb(6, 107, 99);
    border-radius: 12px;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    text-align: center;
}

.login-subtitulo {
    font-size: 14px;
    color: #4b8a85;
    margin: 0;
    text-align: center;
    font-weight: 500;
}

.login-form-card {
    background: white;
    border-radius: 18px;
    padding: 22px 18px 18px;
    box-shadow: 0 4px 22px rgba(0,0,0,0.08);
}

.input-com-icone {
    display: flex;
    align-items: center;
    gap: 7px;
    border: 1.5px solid #d1d5db;
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 2px;
    background: white;
    transition: border-color 0.2s;
    padding-left: 14px;
}

.input-com-icone:focus-within {
    border-color: rgb(6,107,99);
}

.input-com-icone input {
    flex: 1;
    border: none;
    padding: 13px 10px 13px 0;
    font-size: 14px;
    background: transparent;
    outline: none;
}

.input-svg {
    width: 18px;
    height: 18px;
    stroke: #9ca3af;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    margin-left: 0;
    flex-shrink: 0;
}

/* ─── NAVEGAÇÃO ENTRE VIVEIROS ───────────────────────────────────────────── */

.titulo-secao {
    text-align: center;
    color: rgb(6,107,99);
    text-transform: uppercase;
    font-size: 18px;
    font-weight: 900;
    margin: 0 0 20px 0;
    letter-spacing: 0.3px;
}

.nav-viveiros {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 14px;
    padding: 0 4px;
}

.botao-nav-viveiro {
    background: transparent;
    color: rgb(6,107,99);
    border: none;
    padding: 8px 4px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    width: auto;
}

/* ─── ANIMAÇÃO DE TRANSIÇÃO ENTRE VIVEIROS ───────────────────────────────── */

@keyframes slideEntradaDireita {
    from { transform: translateX(60px); opacity: 0; }
    to   { transform: translateX(0);    opacity: 1; }
}

@keyframes slideEntradaEsquerda {
    from { transform: translateX(-60px); opacity: 0; }
    to   { transform: translateX(0);     opacity: 1; }
}

.slide-in-direita {
    animation: slideEntradaDireita 0.28s ease-out;
}

.slide-in-esquerda {
    animation: slideEntradaEsquerda 0.28s ease-out;
}

.nav-viveiros-contador {
    font-size: 13px;
    color: #9ca3af;
    font-weight: 600;
}

.botao-sair {
    background: transparent;
    color: #dc2626;
    border: none;
    grid-column: 1 / -1;
    font-size: 13px;
    font-weight: 600;
    padding: 8px;
    min-height: unset;
}

.emoji-verde {
    display: inline-block;
    filter: sepia(1) saturate(4) hue-rotate(100deg);
}

.botao-entrar {
    width: 100%;
    padding: 14px;
    background: rgb(6, 107, 99);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 6px;
}

.botao-entrar:hover {
    background: rgb(4, 85, 79);
}

.link-esqueci {
    display: block;
    text-align: center;
    margin-top: 10px;
    font-size: 13px;
    color: rgb(6, 107, 99);
    background: none;
    border: none;
    cursor: pointer;
    width: 100%;
    padding: 4px;
    text-decoration: underline;
    text-decoration-style: dashed;
    text-underline-offset: 3px;
}

.link-esqueci:hover {
    color: rgb(4, 85, 79);
}

.separador-login {
    display: flex;
    align-items: center;
    margin: 16px 0 12px 0;
    gap: 10px;
}

.separador-login::before,
.separador-login::after {
    content: "";
    flex: 1;
    height: 1px;
    background: #e5e7eb;
}

.separador-login span {
    color: #9ca3af;
    font-size: 13px;
    white-space: nowrap;
}

.botao-criar-conta {
    width: 100%;
    padding: 12px;
    background: transparent;
    color: rgb(6, 107, 99);
    border: 2px solid rgb(6, 107, 99);
    border-radius: 12px;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.botao-criar-conta:hover {
    background: rgba(6, 107, 99, 0.06);
}

.botao-cadastrar {
    width: 100%;
    padding: 8px;
    background: rgb(6, 107, 99);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 14px;
    font-weight: bold;
    cursor: pointer;
}

.botao-cadastrar:hover {
    background: rgb(4, 85, 79);
}

/* ─── CHIP DE TOTAL ──────────────────────────────────────────────────────────── */

.total-chip {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f0fdf4;
    border: 1.5px solid #86efac;
    border-radius: 12px;
    padding: 12px 16px;
    margin: 14px 0 4px;
}

.total-chip-label {
    font-size: 12px;
    font-weight: 700;
    color: #16a34a;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.total-chip-valor {
    font-size: 16px;
    font-weight: 800;
    color: #15803d;
}

/* ─── CARD DE CICLO ENCERRADO ────────────────────────────────────────────────── */

.ciclo-card {
    background: white;
    border-radius: 14px;
    border: 1px solid #e5e7eb;
    padding: 14px 16px;
    margin-bottom: 10px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.05);
}

.ciclo-card-topo {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.ciclo-card-nome {
    font-size: 15px;
    font-weight: 800;
    color: #1f2937;
}

.ciclo-card-producao {
    font-size: 14px;
    font-weight: 700;
    color: rgb(6,107,99);
    background: rgba(6,107,99,0.08);
    padding: 4px 10px;
    border-radius: 20px;
}

.ciclo-card-infos {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 8px;
}

.ciclo-info-item {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.ciclo-info-label {
    font-size: 10px;
    font-weight: 700;
    color: #9ca3af;
    text-transform: uppercase;
    letter-spacing: 0.4px;
}

.ciclo-info-valor {
    font-size: 12px;
    font-weight: 600;
    color: #374151;
}

.ciclo-card-acoes {
    display: flex;
    gap: 8px;
    margin-top: 12px;
    padding-top: 10px;
    border-top: 1px solid #f3f4f6;
}

.ciclo-btn-relatorio,
.ciclo-btn-excluir,
.ciclo-btn-relatorio {
    flex: 1;
    padding: 7px 10px;
    border-radius: 9px;
    font-size: 12.5px;
    font-weight: 700;
    border: none;
    cursor: pointer;
    width: auto;
    transition: background 0.12s;
}

.ciclo-btn-relatorio {
    background: #f3f4f6;
    color: #374151;
    border: 1px solid #e5e7eb;
}
.ciclo-btn-relatorio:active { background: #e5e7eb; }

.ciclo-btn-excluir {
    background: #dc2626;
    color: #fff;
}
.ciclo-btn-excluir:active { background: #b91c1c; }
body.tema-escuro .ciclo-btn-relatorio { background: #374151; color: #e5e7eb; border-color: #4b5563; }

/* ─── FORMULÁRIO DE LANÇAMENTO ──────────────────────────────────────────────── */

.form-lancamento {
    margin-top: 8px;
}

.form-topo {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 18px;
    padding-top: 4px;
}

.form-icone-circulo {
    width: 76px;
    height: 76px;
    border-radius: 50%;
    background: rgba(6,107,99,0.09);
    border: 2px solid rgba(6,107,99,0.18);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 34px;
    margin-bottom: 12px;
    box-shadow: 0 4px 16px rgba(6,107,99,0.10);
}

.form-icone-circulo svg {
    width: 36px;
    height: 36px;
    stroke: rgb(6,107,99);
    fill: none;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.form-caption {
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 1.8px;
    color: #9ca3af;
    text-transform: uppercase;
    margin: 0 0 4px 0;
    display: block;
}

.form-titulo {
    font-size: 20px;
    font-weight: 900;
    color: #1f2937;
    letter-spacing: 0.3px;
    margin: 0;
    text-align: center;
}

.form-corpo {
    background: #eef2f0;
    border-radius: 16px;
    padding: 16px;
    border: 1.5px solid #d1e4df;
    overflow: hidden;
}

.campo-form input[type="text"],
.campo-form input[type="number"],
.campo-form input[type="date"],
.campo-form select {
    width: 100%;
    padding: 12px 14px;
    border: 1.5px solid #d1d5db;
    border-radius: 10px;
    font-size: 15px;
    color: #1f2937;
    background: white;
    box-sizing: border-box;
    margin-bottom: 0;
    outline: none;
    font-family: Arial, sans-serif;
    transition: border-color 0.2s;
}

.campo-form input[type="date"] {
    -webkit-appearance: none;
    appearance: none;
    cursor: pointer;
    text-align: left;
    height: 46px;
    line-height: 1;
}

.campo-form input:focus,
.campo-form select:focus {
    border-color: rgb(6,107,99);
}

.campo-input-unidade {
    display: flex;
    align-items: stretch;
    border: 1.5px solid #d1d5db;
    border-radius: 10px;
    overflow: hidden;
    background: white;
    transition: border-color 0.2s;
}

.campo-input-unidade:focus-within {
    border-color: rgb(6,107,99);
}

.campo-input-unidade input {
    flex: 1 !important;
    border: none !important;
    padding: 12px 14px !important;
    font-size: 15px !important;
    color: #1f2937;
    background: transparent;
    outline: none;
    margin-bottom: 0 !important;
    width: 0 !important;
    min-width: 0 !important;
    border-radius: 0 !important;
    font-family: Arial, sans-serif;
    transition: none !important;
}

.campo-unidade {
    padding: 0 14px;
    background: #f3f4f6;
    color: #6b7280;
    font-size: 14px;
    font-weight: 700;
    border-left: 1.5px solid #d1d5db;
    display: flex;
    align-items: center;
    white-space: nowrap;
    flex-shrink: 0;
}

.unidade-toggle {
    display: flex;
    gap: 2px;
    background: #e5e7eb;
    border-radius: 8px;
    padding: 2px;
    margin-left: auto;
}

.unidade-btn {
    background: transparent;
    border: none;
    border-radius: 6px;
    padding: 2px 10px;
    font-size: 12px;
    font-weight: 700;
    color: #6b7280;
    cursor: pointer;
    font-family: Arial, sans-serif;
}

.unidade-btn.ativo {
    background: white;
    color: rgb(6,107,99);
    box-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

.separador-ou {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 12px 0;
    color: #9ca3af;
    font-size: 13px;
    font-weight: 600;
}

.separador-ou::before,
.separador-ou::after {
    content: "";
    flex: 1;
    height: 1px;
    background: #e5e7eb;
}

.msg-sucesso-lancamento {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #f0fdf4;
    border: 1.5px solid #86efac;
    border-radius: 10px;
    padding: 12px 16px;
    margin-bottom: 12px;
}

.msg-sucesso-lancamento .msg-emoji {
    font-size: 20px;
    flex-shrink: 0;
    line-height: 1;
}

.msg-sucesso-lancamento .msg-texto {
    font-size: 14px;
    font-weight: 700;
    color: #16a34a;
}

.toast-sucesso {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #f0fdf4;
    border: 1.5px solid #86efac;
    border-radius: 12px;
    padding: 12px 16px;
    margin-bottom: 12px;
    font-size: 14px;
    font-weight: 700;
    color: #16a34a;
    animation: slideEntradaDireita 0.25s ease-out;
}

.toast-sucesso svg {
    width: 18px;
    height: 18px;
    stroke: #16a34a;
    fill: none;
    stroke-width: 2.5;
    stroke-linecap: round;
    stroke-linejoin: round;
    flex-shrink: 0;
}

.viveiro-sem-ciclo-msg {
    display: flex;
    align-items: flex-start;
    gap: 9px;
    background: #f0f9ff;
    border: 1.5px solid #bae6fd;
    border-radius: 12px;
    padding: 12px 14px;
    margin-bottom: 16px;
    font-size: 13px;
    color: #0369a1;
    font-weight: 600;
    line-height: 1.45;
}

.viveiro-sem-ciclo-msg svg {
    width: 16px;
    height: 16px;
    stroke: #0284c7;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    flex-shrink: 0;
    margin-top: 1px;
}

.aviso-reinicio {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    background: #fffbeb;
    border: 1.5px solid #fde68a;
    border-radius: 10px;
    padding: 11px 14px;
    margin-bottom: 12px;
    font-size: 13px;
    color: #92400e;
    line-height: 1.45;
}

/* ─── IMPRESSÃO ──────────────────────────────────────────────────────────────── */

@media print {
    @page {
        margin: 0.6cm 0.8cm;
        size: A4 portrait;
    }

    html, body {
        background: white !important;
        margin: 0 !important;
        padding: 0 !important;
        height: auto !important;
        overflow: visible !important;
    }

    /* Esconde tudo exceto o relatório */
    .topo,
    .botoes-gestao,
    .acoes-relatorio,
    button,
    .limpar,
    #menuGestao,
    .toast-sucesso {
        display: none !important;
    }

    /* Remove o margin-top do container pai */
    .resultado {
        margin-top: 0 !important;
    }

    /* Relatório ocupa a página inteira */
    .relatorio-final {
        box-shadow: none !important;
        max-width: 100% !important;
        margin: 0 !important;
        padding: 0 !important;
        border-radius: 0 !important;
        border: none !important;
    }

    /* Seções mais compactas para caber em 1 página */
    .relatorio-secao {
        margin-top: 10px !important;
    }

    .rel-header {
        margin-bottom: 8px !important;
    }

    .rel-divider {
        margin-bottom: 8px !important;
    }

    .rel-periodo {
        margin-bottom: 0 !important;
    }

    .rel-info-row {
        padding: 8px 10px !important;
    }

    .rel-metricas-grid {
        gap: 6px !important;
    }

    .rel-metrica-card {
        padding: 8px !important;
    }

    .rel-sobrevivencia {
        padding: 8px 12px !important;
    }

    .rel-producao-hero {
        margin-top: 10px !important;
        padding: 9px 14px !important;
        background: #0f766e !important;
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }

    .rel-sobrevivencia {
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }
}


/* ─── MENU USUÁRIO REDESIGN ─────────────────────────────────────────────────── */

.avatar-topo-circle {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255,255,255,0.18);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
}

.avatar-topo-circle img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.avatar-topo-iniciais {
    font-size: 13px;
    font-weight: 700;
    color: white;
    line-height: 1;
}

.dropdown-usuario {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    background: white;
    border-radius: 18px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.18);
    width: 300px;
    display: none;
    z-index: 2000;
    overflow: hidden;
    padding-bottom: 6px;
}

.dropdown-usuario.aberto {
    display: block;
}

.menu-user-header {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 18px 16px 14px;
}

.menu-avatar-wrap {
    position: relative;
    cursor: pointer;
    flex-shrink: 0;
}

.menu-avatar-circle {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: rgb(6,107,99);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.menu-avatar-circle img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.menu-avatar-iniciais {
    font-size: 20px;
    font-weight: 700;
    color: white;
}

.menu-avatar-edit {
    position: absolute;
    bottom: -2px;
    right: -2px;
    background: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.2);
}

.menu-user-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.menu-user-nome {
    font-size: 15px;
    font-weight: 700;
    color: #1f2937;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.menu-user-email {
    font-size: 12px;
    color: #6b7280;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.menu-online-badge {
    font-size: 11px;
    font-weight: 600;
    color: #16a34a;
    margin-top: 2px;
}

.menu-foto-opcoes {
    display: flex;
    gap: 8px;
    padding: 0 16px 12px;
}

.menu-foto-btn {
    flex: 1;
    padding: 7px 6px;
    background: #f3f4f6;
    border: none;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 600;
    color: #374151;
    cursor: pointer;
    text-align: center;
    display: block;
    width: 100%;
}

.menu-foto-excluir {
    color: #dc2626;
    background: #fef2f2;
}

.menu-divider {
    height: 1px;
    background: #f3f4f6;
    margin: 4px 0;
}

.menu-item {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 11px 16px;
    background: none;
    border: none;
    cursor: pointer;
    text-align: left;
}

.menu-item:hover {
    background: #f9fafb;
}

.menu-item-inativo {
    opacity: 0.45;
    cursor: default;
}

.menu-item-inativo:hover {
    background: none;
}

.menu-item-icone {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: #f3f4f6;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.menu-item-icone svg {
    width: 17px;
    height: 17px;
    stroke: #374151;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.menu-item-icone-sair {
    background: #fef2f2;
}

.menu-item-icone-sair svg {
    stroke: #dc2626;
}

.menu-item-texto {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 1px;
}

.menu-item-texto span {
    font-size: 14px;
    font-weight: 600;
    color: #1f2937;
}

.menu-item-texto small {
    font-size: 11px;
    color: #9ca3af;
}

.menu-item-sair .menu-item-texto span {
    color: #dc2626;
}

.menu-item-sair .menu-item-texto small {
    color: #fca5a5;
}

.menu-item-chevron {
    font-size: 18px;
    color: #d1d5db;
    line-height: 1;
}

/* Toggle do tema */
.menu-tema-toggle {
    width: 40px;
    height: 22px;
    background: #d1d5db;
    border-radius: 11px;
    position: relative;
    transition: background 0.2s;
    flex-shrink: 0;
}

.menu-tema-bolinha {
    position: absolute;
    top: 3px;
    left: 3px;
    width: 16px;
    height: 16px;
    background: white;
    border-radius: 50%;
    transition: left 0.2s;
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

.tema-escuro .menu-tema-toggle {
    background: rgb(6,107,99);
}

.tema-escuro .menu-tema-bolinha {
    left: 21px;
}

/* ─── DARK MODE ──────────────────────────────────────────────────────────────── */

body.tema-escuro {
    background: #111827;
    color: #f3f4f6;
}

body.tema-escuro .card {
    background: #1f2937;
}

body.tema-escuro .botao-gestao {
    background: #065f46;
}

body.tema-escuro .viveiro-card,
body.tema-escuro .ciclo-card,
body.tema-escuro .resultado-box,
body.tema-escuro .form-lancamento,
body.tema-escuro .painel-viveiro,
body.tema-escuro .relatorio-final {
    background: #1f2937;
    border-color: #374151;
    color: #f3f4f6;
}

body.tema-escuro .titulo-secao,
body.tema-escuro .form-titulo,
body.tema-escuro h1, body.tema-escuro h2, body.tema-escuro h3 {
    color: #f3f4f6;
}

body.tema-escuro input,
body.tema-escuro select,
body.tema-escuro textarea {
    background: #374151;
    color: #f3f4f6;
    border-color: #4b5563;
}

body.tema-escuro .dropdown-usuario {
    background: #1f2937;
    box-shadow: 0 8px 32px rgba(0,0,0,0.5);
}

body.tema-escuro .menu-user-nome,
body.tema-escuro .menu-item-texto span {
    color: #f3f4f6;
}

body.tema-escuro .menu-item:hover {
    background: #374151;
}

body.tema-escuro .menu-divider {
    background: #374151;
}

body.tema-escuro .menu-item-icone {
    background: #374151;
}

body.tema-escuro .menu-item-icone svg {
    stroke: #d1d5db;
}

body.tema-escuro .menu-foto-btn {
    background: #374151;
    color: #d1d5db;
}

body.tema-escuro .tabela-historico,
body.tema-escuro .linha-historico-racao,
body.tema-escuro .linha-historico-acoes {
    background: #1f2937;
    border-color: #374151;
    color: #f3f4f6;
}

body.tema-escuro .total-chip {
    background: #065f46;
}

body.tema-escuro .campo-form label,
body.tema-escuro .campo-label label {
    color: #d1d5db;
}

body.tema-escuro .vc-info-lista,
body.tema-escuro .vc-info-item,
body.tema-escuro .viveiro-header {
    background: #1f2937;
    color: #f3f4f6;
}

body.tema-escuro .nav-viveiros {
    background: #1f2937;
}

/* ─── CUSTOS E INSUMOS ───────────────────────────────────────────────────────── */

.lista-produtos {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 8px;
}

.produto-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    background: #f8fafc;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    padding: 10px 12px;
}

.produto-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
    flex: 1;
    min-width: 0;
}

.produto-nome {
    font-size: 14px;
    font-weight: 700;
    color: #1f2937;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.produto-detalhe {
    font-size: 12px;
    color: #6b7280;
}

.custo-por-grama-preview {
    background: #ecfdf5;
    border: 1px solid #6ee7b7;
    border-radius: 8px;
    padding: 8px 12px;
    font-size: 13px;
    color: #065f46;
    margin-bottom: 14px;
}

.botao-imprimir-custos {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 5px 12px;
    background: #f0fdf4;
    color: rgb(6,107,99);
    border: 1px solid rgb(6,107,99);
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
}

body.tema-escuro .botao-imprimir-custos {
    background: #1f2937;
    color: #34d399;
    border-color: #34d399;
}

.linha-hist-custo-geral {
    display: grid;
    grid-template-columns: 0.7fr 0.6fr 1.4fr 0.8fr;
    gap: 4px;
    padding: 10px 4px;
    border-bottom: 1px solid #e5e7eb;
    font-size: 14px;
    align-items: center;
}

.linha-hist-custo-geral.cabecalho {
    font-weight: bold;
    color: rgb(6,107,99);
    border-bottom: 2px solid rgb(6,107,99);
    font-size: 11px;
    letter-spacing: 0.5px;
}

.linha-hist-custo-3col {
    display: grid;
    grid-template-columns: 0.8fr 1.6fr 1fr;
    gap: 4px;
    padding: 10px 4px;
    border-bottom: 1px solid #e5e7eb;
    font-size: 14px;
    align-items: center;
}

.linha-hist-custo-3col.cabecalho {
    font-weight: bold;
    color: rgb(6,107,99);
    border-bottom: 2px solid rgb(6,107,99);
    font-size: 11px;
    letter-spacing: 0.5px;
}

.confirmar-exclusao-custo {
    padding: 10px 12px;
    background: #fef2f2;
    border-radius: 8px;
    border: 1px solid #fecaca;
    font-size: 13px;
    color: #dc2626;
    width: 100%;
}

/* Toggle Detalhado / Por tipo */
.financeiro-toggle {
    display: flex;
    gap: 6px;
    background: #f3f4f6;
    border-radius: 10px;
    padding: 4px;
    margin-bottom: 12px;
}

.financeiro-toggle-btn {
    flex: 1;
    padding: 8px 10px;
    background: transparent;
    border: none;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    color: #6b7280;
    cursor: pointer;
}

.financeiro-toggle-btn.ativo {
    background: white;
    color: rgb(6,107,99);
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.linha-hist-resumo {
    display: grid;
    grid-template-columns: 1.6fr 0.5fr 0.9fr;
    gap: 4px;
    padding: 10px 4px;
    border-bottom: 1px solid #e5e7eb;
    font-size: 14px;
    align-items: center;
}

.linha-hist-resumo.cabecalho {
    font-weight: bold;
    color: rgb(6,107,99);
    border-bottom: 2px solid rgb(6,107,99);
    font-size: 11px;
    letter-spacing: 0.5px;
}

.col-direita {
    text-align: right;
}

/* Dark mode – custos */
body.tema-escuro .produto-item {
    background: #374151;
    border-color: #4b5563;
}

body.tema-escuro .produto-nome {
    color: #f3f4f6;
}

body.tema-escuro .produto-detalhe {
    color: #9ca3af;
}

body.tema-escuro .custo-por-grama-preview {
    background: #064e3b;
    border-color: #065f46;
    color: #6ee7b7;
}

body.tema-escuro .linha-hist-custo-geral,
body.tema-escuro .linha-hist-custo-3col,
body.tema-escuro .linha-hist-resumo {
    background: #1f2937;
    border-color: #374151;
    color: #f3f4f6;
}

body.tema-escuro .financeiro-toggle {
    background: #374151;
}
body.tema-escuro .financeiro-toggle-btn {
    color: #9ca3af;
}
body.tema-escuro .financeiro-toggle-btn.ativo {
    background: #1f2937;
    color: #34d399;
}

body.tema-escuro .confirmar-exclusao-custo {
    background: #450a0a;
    border-color: #dc2626;
    color: #fca5a5;
}

/* ─── BOLETOS A VENCER ───────────────────────────────────────────────────────── */

.boleto-banner {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #fef3c7;
    border: 1.5px solid #f59e0b;
    border-radius: 14px;
    padding: 12px 14px;
    margin-bottom: 12px;
    cursor: pointer;
}

.boleto-banner-icone {
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    background: #fde68a;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #b45309;
}

.boleto-banner-icone svg {
    width: 20px;
    height: 20px;
    stroke: #b45309;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.boleto-banner-texto {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.boleto-banner-texto strong {
    font-size: 13px;
    color: #92400e;
    font-weight: 700;
}

.boleto-banner-texto span {
    font-size: 12px;
    color: #b45309;
}

.boleto-banner-seta {
    font-size: 20px;
    color: #b45309;
    font-weight: 700;
}

.botao-submenu-financeiro {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 16px 18px;
    background: #f0fdf4;
    color: rgb(6, 107, 99);
    border: 1.5px solid #d1fae5;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    text-align: left;
    margin-bottom: 10px;
}

.botao-submenu-financeiro svg {
    width: 22px;
    height: 22px;
    stroke: rgb(6, 107, 99);
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    flex-shrink: 0;
}

.botao-submenu-financeiro:active {
    background: #dcfce7;
}

.botao-submenu-boleto {
    background: #fffbeb;
    color: #92400e;
    border-color: #fde68a;
}

.botao-submenu-boleto svg {
    stroke: #b45309;
}

.botao-submenu-boleto:active {
    background: #fef3c7;
}

.botao-submenu-cadastro-boleto {
    background: #eff6ff;
    color: #1e40af;
    border-color: #bfdbfe;
}

.botao-submenu-cadastro-boleto svg {
    stroke: #1d4ed8;
}

.botao-submenu-cadastro-boleto:active {
    background: #dbeafe;
}

.boleto-lista {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 4px;
}

.boleto-resumo-bar {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 10px;
}

.boleto-resumo-chip {
    font-size: 12px;
    color: rgb(6, 107, 99);
    background: #f0fdf4;
    border: 1px solid #d1fae5;
    border-radius: 20px;
    padding: 4px 12px;
    white-space: nowrap;
}

.boleto-resumo-chip strong {
    font-weight: 700;
}

.boleto-resumo-chip.vencido {
    background: #fef2f2;
    border-color: #fecaca;
    color: #dc2626;
}

.boleto-item {
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    padding: 8px 10px;
    display: flex;
    flex-direction: column;
    gap: 0;
}

.boleto-item-linha {
    display: flex;
    align-items: center;
    width: 100%;
}

.boleto-item-nome {
    flex: 1;
    font-size: 13px;
    font-weight: 600;
    color: #1f2937;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    min-width: 0;
    text-align: left;
}

.boleto-valor-slim {
    flex: 1;
    font-size: 13px;
    font-weight: 700;
    color: rgb(6, 107, 99);
    white-space: nowrap;
    text-align: center;
}

.boleto-item-btns {
    display: flex;
    gap: 2px;
    flex-shrink: 0;
}

.boleto-dias-text {
    flex: 1;
    font-size: 11px;
    font-weight: 600;
    white-space: nowrap;
    text-align: right;
}

.boleto-dias-ok { color: rgb(6, 107, 99); }
.boleto-dias-proximo { color: #92400e; }
.boleto-dias-hoje { color: #c2410c; }
.boleto-dias-vencido { color: #dc2626; }
.boleto-dias-pago { color: #16a34a; }

.boleto-valor {
    font-size: 14px;
    font-weight: 700;
    color: rgb(6, 107, 99);
}

.boleto-item-acoes {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 6px;
    flex-shrink: 0;
}

.boleto-item-dir {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.boleto-badge {
    font-size: 11px;
    font-weight: 700;
    padding: 3px 9px;
    border-radius: 20px;
    flex-shrink: 0;
}

.boleto-badge-ok {
    background: #f0fdf4;
    color: rgb(6, 107, 99);
    border: 1px solid #d1fae5;
}

.boleto-badge-proximo {
    background: #fef3c7;
    color: #92400e;
    border: 1px solid #fde68a;
}

.boleto-badge-hoje {
    background: #fff7ed;
    color: #c2410c;
    border: 1px solid #fed7aa;
}

.boleto-badge-vencido {
    background: #fef2f2;
    color: #dc2626;
    border: 1px solid #fecaca;
}

.boleto-badge-pago {
    background: #f0fdf4;
    color: #16a34a;
    border: 1px solid #86efac;
}

.boleto-item-pago {
    opacity: 0.6;
    background: #f9fafb;
}

.boleto-item-pago .boleto-item-nome {
    text-decoration: line-through;
    text-decoration-color: #9ca3af;
}

.botao-icone-acao {
    background: none;
    border: none;
    font-size: 16px;
    cursor: pointer;
    padding: 2px 4px;
    border-radius: 6px;
    line-height: 1;
}

.botao-icone-acao:active {
    background: #f3f4f6;
}

.painel-confirmar-boleto {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid #f3f4f6;
}

.confirmar-boleto-pergunta {
    margin: 0 0 10px;
    font-size: 13px;
    font-weight: 600;
    color: #374151;
    text-align: center;
}

.confirmar-boleto-botoes {
    display: flex;
    gap: 8px;
}

.confirmar-boleto-btn-cancelar,
.confirmar-boleto-btn-excluir {
    flex: 1;
    padding: 10px;
    border: none;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    font-family: Arial, sans-serif;
}

.confirmar-boleto-btn-cancelar {
    background: #f3f4f6;
    color: #374151;
}

.confirmar-boleto-btn-excluir {
    background: #ef4444;
    color: white;
}

/* boleto detalhe */
.boleto-detalhe-status {
    display: flex;
    justify-content: center;
    margin-bottom: 16px;
}

.boleto-detalhe-grid {
    background: #f9fafb;
    border-radius: 12px;
    overflow: hidden;
    border: 1.5px solid #e5e7eb;
}

.boleto-detalhe-linha {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    border-bottom: 1px solid #e5e7eb;
}

.boleto-detalhe-linha:last-child {
    border-bottom: none;
}

.boleto-detalhe-destaque {
    background: #f0fdf4;
}

.boleto-detalhe-label {
    font-size: 13px;
    color: #6b7280;
    font-weight: 500;
}

.boleto-detalhe-valor {
    font-size: 14px;
    color: #1f2937;
    font-weight: 600;
    text-align: right;
}

body.tema-escuro .boleto-detalhe-grid {
    background: #1f2937;
    border-color: #374151;
}
body.tema-escuro .boleto-detalhe-linha {
    border-bottom-color: #374151;
}
body.tema-escuro .boleto-detalhe-destaque {
    background: #064e3b;
}
body.tema-escuro .boleto-detalhe-label { color: #9ca3af; }
body.tema-escuro .boleto-detalhe-valor { color: #f9fafb; }

/* dark mode */
body.tema-escuro .boleto-banner {
    background: #422006;
    border-color: #92400e;
}
body.tema-escuro .boleto-banner-icone {
    background: #78350f;
}
body.tema-escuro .boleto-banner-texto strong { color: #fde68a; }
body.tema-escuro .boleto-banner-texto span { color: #fcd34d; }
body.tema-escuro .boleto-banner-seta { color: #fcd34d; }

body.tema-escuro .botao-submenu-financeiro {
    background: #1f2937;
    color: #34d399;
    border-color: #065f46;
}
body.tema-escuro .botao-submenu-financeiro svg { stroke: #34d399; }
body.tema-escuro .botao-submenu-boleto {
    background: #1c1a10;
    color: #fcd34d;
    border-color: #78350f;
}
body.tema-escuro .botao-submenu-boleto svg { stroke: #fcd34d; }

body.tema-escuro .boleto-item {
    background: #1f2937;
    border-color: #374151;
}
body.tema-escuro .boleto-item-nome { color: #f9fafb; }
body.tema-escuro .boleto-valor-slim { color: #34d399; }
body.tema-escuro .boleto-valor { color: #34d399; }
body.tema-escuro .painel-confirmar-boleto { border-top-color: #374151; color: #d1d5db; }
body.tema-escuro .boleto-item-pago { background: #111827; }
body.tema-escuro .boleto-resumo-chip { background: #052e2b; border-color: #0f4d47; color: #34d399; }
body.tema-escuro .boleto-resumo-chip.vencido { background: #2a1414; border-color: #5b2020; color: #f87171; }
body.tema-escuro .botao-submenu-cadastro-boleto { background: #1e3a5f; color: #93c5fd; border-color: #1e40af; }
body.tema-escuro .botao-submenu-cadastro-boleto svg { stroke: #93c5fd; }

/* ─── BOLETOS TABELA ─────────────────────────────────────────────────────────── */

.bt-form .form-topo { padding-bottom: 0; }

.bt-corpo {
    display: flex;
    flex-direction: column;
}

.bt-chips {
    display: flex;
    gap: 8px;
    padding: 12px 16px 0;
}

.bt-chip {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    background: #f0fdf4;
    border: 1px solid #d1fae5;
    border-radius: 12px;
    padding: 10px 6px;
    color: rgb(6, 107, 99);
    min-width: 0;
    text-align: center;
}

.bt-chip svg { opacity: 0.7; }

.bt-chip-val {
    font-size: 16px;
    font-weight: 800;
    line-height: 1;
    color: inherit;
}

.bt-chip-lbl {
    font-size: 10px;
    font-weight: 500;
    color: #6b7280;
    line-height: 1;
    white-space: nowrap;
}

.bt-chip-warn {
    background: #fffbeb;
    border-color: #fde68a;
    color: #92400e;
}

.bt-chip-danger {
    background: #fef2f2;
    border-color: #fecaca;
    color: #dc2626;
}

.bt-abas {
    display: flex;
    gap: 0;
    padding: 6px 10px 0;
    border-bottom: 1px solid #e5e7eb;
}

.bt-aba {
    flex: 1;
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    padding: 6px 3px;
    font-size: 11.5px;
    font-weight: 600;
    color: #9ca3af;
    cursor: pointer;
    text-align: center;
    margin-bottom: -1px;
}

.bt-aba.ativa {
    color: rgb(6, 107, 99);
    border-bottom-color: rgb(6, 107, 99);
}

.bt-lista {
    display: flex;
    flex-direction: column;
}

.bt-row {
    display: flex;
    align-items: center;
    border-bottom: 1px solid #f3f4f6;
    position: relative;
    flex-wrap: wrap;
}

.bt-row-main {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 0 12px 16px;
    cursor: pointer;
    min-width: 0;
}

.bt-row-main:active { background: #f9fafb; }

.bt-row-pago { opacity: 0.55; }

.bt-nome {
    flex: 1;
    font-size: 13px;
    font-weight: 600;
    color: #1f2937;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    min-width: 0;
}

.bt-valor-row {
    font-size: 13px;
    font-weight: 700;
    color: rgb(6, 107, 99);
    white-space: nowrap;
    flex-shrink: 0;
}

.bt-badge {
    display: inline-block;
    font-size: 10px;
    font-weight: 700;
    padding: 2px 7px;
    border-radius: 20px;
    white-space: nowrap;
}

.bt-badge-ok      { background: #f0fdf4; color: rgb(6,107,99); border: 1px solid #d1fae5; }
.bt-badge-proximo { background: #fef3c7; color: #92400e; border: 1px solid #fde68a; }
.bt-badge-hoje    { background: #fff7ed; color: #c2410c; border: 1px solid #fed7aa; }
.bt-badge-vencido { background: #fef2f2; color: #dc2626; border: 1px solid #fecaca; }
.bt-badge-pago    { background: #f0fdf4; color: #16a34a; border: 1px solid #86efac; }

.bt-menu-wrap { position: relative; padding: 0 8px; flex-shrink: 0; }

.bt-menu-btn {
    background: none;
    border: none;
    font-size: 18px;
    cursor: pointer;
    padding: 4px 6px;
    border-radius: 6px;
    color: #9ca3af;
    line-height: 1;
}

.bt-menu-btn:hover { background: #f3f4f6; color: #374151; }

.bt-menu-drop {
    position: absolute;
    right: 8px;
    top: 100%;
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.12);
    z-index: 50;
    min-width: 170px;
    overflow: hidden;
}

.bt-menu-drop button {
    display: block;
    width: 100%;
    background: none;
    border: none;
    padding: 11px 14px;
    text-align: left;
    font-size: 13px;
    font-weight: 500;
    color: #374151;
    cursor: pointer;
    border-bottom: 1px solid #f3f4f6;
}

.bt-menu-drop button:last-child { border-bottom: none; }
.bt-menu-drop button:hover { background: #f9fafb; }
.bt-menu-excluir { color: #ef4444 !important; }

.bt-confirmar-inline {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #fef2f2;
    padding: 8px 16px;
    font-size: 13px;
    color: #7f1d1d;
    width: 100%;
    box-sizing: border-box;
}

.bt-confirmar-inline span { flex: 1; font-weight: 500; }

.bt-empty {
    text-align: center;
    padding: 32px 16px !important;
    color: #9ca3af;
    font-size: 14px;
}

/* dark mode */
body.tema-escuro .bt-chip { background: #052e2b; border-color: #0f4d47; color: #34d399; }
body.tema-escuro .bt-chip-lbl { color: #6b7280; }
body.tema-escuro .bt-chip-warn { background: #2d1f00; border-color: #78350f; color: #fcd34d; }
body.tema-escuro .bt-chip-danger { background: #2a1414; border-color: #5b2020; color: #f87171; }
body.tema-escuro .bt-aba { color: #6b7280; }
body.tema-escuro .bt-aba.ativa { color: #34d399; border-bottom-color: #34d399; }
body.tema-escuro .bt-abas { border-bottom-color: #374151; }
body.tema-escuro .bt-tabela thead th { color: #6b7280; border-bottom-color: #374151; }
body.tema-escuro .bt-row { border-bottom-color: #1f2937; }
body.tema-escuro .bt-row:hover { background: #1f2937; }
body.tema-escuro .bt-tabela td { color: #f9fafb; }
body.tema-escuro .bt-nome { color: #f9fafb; }
body.tema-escuro .bt-td-valor { color: #34d399; }
body.tema-escuro .bt-td-data { color: #9ca3af; }
body.tema-escuro .bt-menu-btn { color: #6b7280; }
body.tema-escuro .bt-menu-btn:hover { background: #374151; color: #f9fafb; }
body.tema-escuro .bt-menu-drop { background: #1f2937; border-color: #374151; }
body.tema-escuro .bt-menu-drop button { color: #f9fafb; border-bottom-color: #374151; }
body.tema-escuro .bt-menu-drop button:hover { background: #374151; }
body.tema-escuro .bt-icone-ok { background: #052e2b; }
body.tema-escuro .bt-icone-pago { background: #052e2b; }

/* ─── CURVA DE CRESCIMENTO ───────────────────────────────────────────────────── */

.botao-curva-crescimento {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    padding: 12px 16px;
    background: linear-gradient(135deg, #f0fdf4, #e6f4f1);
    color: rgb(6,107,99);
    border: 1.5px solid #a7f3d0;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    margin-top: 12px;
    font-family: Arial, sans-serif;
    justify-content: center;
}

.botao-curva-crescimento:active {
    background: #dcfce7;
}

.grafico-container {
    background: white;
    border: 1.5px solid #e5e7eb;
    border-radius: 14px;
    padding: 14px 12px 12px;
    margin-bottom: 14px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
}

.grafico-titulo {
    font-size: 15px;
    font-weight: 800;
    color: #1f2937;
    margin: 0 2px 8px;
    text-align: center;
}

.grafico-legenda {
    display: flex;
    justify-content: center;
    gap: 18px;
    margin-bottom: 6px;
    flex-wrap: wrap;
}

.grafico-leg-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 11.5px;
    font-weight: 600;
    color: #6b7280;
}

.grafico-leg-dot {
    width: 16px;
    height: 3px;
    border-radius: 99px;
    flex-shrink: 0;
}

.grafico-leg-dot.leg-verde { background: rgb(6,107,99); }
.grafico-leg-dot.leg-laranja {
    background: repeating-linear-gradient(90deg, #f59e0b 0 4px, transparent 4px 7px);
    height: 2px;
}

.grafico-canvas-wrap {
    position: relative;
    height: 300px;
}

/* histórico de biometrias compacto */
.bio-hist-titulo {
    font-size: 14px;
    font-weight: 800;
    color: #1f2937;
    margin: 16px 2px 8px;
}

.bio-historico {
    display: flex;
    flex-direction: column;
    gap: 5px;
    margin-bottom: 4px;
}

.bio-hist-linha {
    display: grid;
    grid-template-columns: 56px 1fr auto;
    align-items: center;
    gap: 10px;
    padding: 9px 14px;
    background: #f9fafb;
    border-radius: 9px;
    border: 1px solid #eef0f2;
}

.bio-hist-dia {
    font-size: 13px;
    font-weight: 800;
    color: rgb(6,107,99);
}

.bio-hist-peso {
    font-size: 14px;
    color: #1f2937;
    font-weight: 700;
}

.bio-hist-ganho {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    font-size: 12.5px;
    font-weight: 700;
    justify-self: end;
}

.bio-hist-ganho.pos { color: #16a34a; }
.bio-hist-ganho.neg { color: #dc2626; }
.bio-hist-ganho.neutro { color: #9ca3af; }

.bio-hist-seta {
    width: 13px;
    height: 13px;
    stroke: currentColor;
    fill: none;
    stroke-width: 2.5;
    stroke-linecap: round;
    stroke-linejoin: round;
    flex-shrink: 0;
}

body.tema-escuro .grafico-container {
    background: #1f2937;
    border-color: #374151;
}
body.tema-escuro .grafico-titulo { color: #f3f4f6; }
body.tema-escuro .bio-hist-titulo { color: #f3f4f6; }
body.tema-escuro .bio-hist-linha {
    background: #374151;
    border-color: #4b5563;
}
body.tema-escuro .bio-hist-peso { color: #f9fafb; }
body.tema-escuro .bio-hist-dia { color: #34d399; }
body.tema-escuro .botao-curva-crescimento {
    background: #064e3b;
    color: #34d399;
    border-color: #065f46;
}

/* 3 cards de indicadores no topo */
.cresc-cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin-bottom: 14px;
}

.cresc-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    background: white;
    border: 1.5px solid #e5e7eb;
    border-radius: 12px;
    padding: 12px 6px 11px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

.cresc-card-ico {
    width: 18px;
    height: 18px;
    stroke: rgb(6,107,99);
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    opacity: 0.85;
}

.cresc-card-lbl {
    font-size: 10px;
    color: #9ca3af;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    text-align: center;
}

.cresc-card-val {
    font-size: 16px;
    font-weight: 800;
    color: rgb(6, 107, 99);
    text-align: center;
}

body.tema-escuro .cresc-card { background: #1f2937; border-color: #374151; }
body.tema-escuro .cresc-card-lbl { color: #9ca3af; }
body.tema-escuro .cresc-card-val { color: #34d399; }
body.tema-escuro .cresc-card-ico { stroke: #34d399; }

/* card de progresso (barra) */
.proj-progresso-card {
    background: white;
    border: 1.5px solid #e5e7eb;
    border-radius: 12px;
    padding: 13px 16px 12px;
    margin-bottom: 10px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

.proj-prog-pct-row {
    text-align: center;
    margin-bottom: 8px;
}

.proj-prog-pct {
    font-size: 20px;
    font-weight: 900;
    color: rgb(6,107,99);
}

.proj-prog-pct-lbl {
    font-size: 12px;
    font-weight: 600;
    color: #9ca3af;
    margin-left: 4px;
}

.proj-barra-fundo {
    height: 9px;
    background: #eef0f2;
    border-radius: 99px;
    overflow: hidden;
    position: relative;
}

.proj-barra-preench {
    height: 100%;
    background: linear-gradient(90deg, rgb(6,107,99), #34d399);
    border-radius: 99px;
    transition: width 0.4s ease;
}

.proj-progresso-base {
    display: flex;
    justify-content: space-between;
    margin-top: 6px;
    font-size: 12px;
    font-weight: 700;
    color: #374151;
}

/* resumo executivo da projeção */
.proj-resumo {
    background: #f0fdf4;
    border: 1.5px solid #d1fae5;
    border-radius: 12px;
    padding: 6px 14px;
    margin-bottom: 8px;
}

.proj-resumo-linha {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 0;
    border-bottom: 1px solid rgba(6,107,99,0.08);
}

.proj-resumo-linha:last-child { border-bottom: none; }

.proj-resumo-ico {
    width: 17px;
    height: 17px;
    stroke: rgb(6,107,99);
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    flex-shrink: 0;
    opacity: 0.7;
}

.proj-resumo-lbl {
    font-size: 13px;
    color: #374151;
    font-weight: 500;
    flex: 1;
}

.proj-resumo-val {
    font-size: 15px;
    font-weight: 800;
    color: rgb(4, 75, 70);
}

body.tema-escuro .proj-progresso-card { background: #1f2937; border-color: #374151; }
body.tema-escuro .proj-prog-pct { color: #34d399; }
body.tema-escuro .proj-barra-fundo { background: #374151; }
body.tema-escuro .proj-progresso-base { color: #d1d5db; }
body.tema-escuro .proj-resumo { background: #052e2b; border-color: #0f4d47; }
body.tema-escuro .proj-resumo-linha { border-bottom-color: rgba(52,211,153,0.12); }
body.tema-escuro .proj-resumo-lbl { color: #d1d5db; }
body.tema-escuro .proj-resumo-val { color: #34d399; }
body.tema-escuro .proj-resumo-ico { stroke: #34d399; }

/* projeção de despesca */
.proj-controle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    background: #fffbeb;
    border: 1.5px solid #fde68a;
    border-radius: 12px;
    padding: 10px 14px;
    margin-bottom: 10px;
}

.proj-controle label {
    font-size: 13px;
    font-weight: 700;
    color: #92400e;
}

.proj-alvo-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
}

.proj-alvo-lbl {
    font-size: 14px;
    font-weight: 700;
    color: #374151;
}

.proj-alvo-ctrl {
    display: flex;
    align-items: center;
    gap: 0;
    border: 1.5px solid #d1d5db;
    border-radius: 10px;
    overflow: hidden;
    background: white;
}

.proj-alvo-btn {
    width: 32px;
    height: 40px;
    background: #f3f4f6;
    border: none;
    font-size: 17px;
    font-weight: 500;
    color: #6b7280;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: background 0.15s;
}

.proj-alvo-btn:active { background: #e5e7eb; }

.proj-alvo-val-wrap {
    display: flex;
    align-items: center;
    gap: 3px;
    padding: 0 12px;
    border-left: 1.5px solid #e5e7eb;
    border-right: 1.5px solid #e5e7eb;
    min-width: 78px;
    justify-content: center;
    height: 40px;
}

.proj-alvo-val-wrap input {
    width: 56px;
    border: none;
    outline: none;
    font-size: 20px;
    font-weight: 800;
    color: #111827;
    text-align: right;
    background: transparent;
    padding: 0;
    line-height: 1;
    -webkit-appearance: none;
    -moz-appearance: textfield;
    appearance: textfield;
}
.proj-alvo-val-wrap input::-webkit-inner-spin-button,
.proj-alvo-val-wrap input::-webkit-outer-spin-button {
    -webkit-appearance: none;
    appearance: none;
    display: none;
    margin: 0;
}

.proj-alvo-val-wrap span {
    font-size: 13px;
    font-weight: 600;
    color: #6b7280;
    line-height: 1;
    flex-shrink: 0;
}

.proj-input-wrap {
    display: flex;
    align-items: center;
    gap: 4px;
    background: white;
    border: 1.5px solid #fde68a;
    border-radius: 8px;
    padding: 4px 10px;
}

.proj-input-wrap input {
    width: 56px;
    border: none;
    outline: none;
    font-size: 15px;
    font-weight: 700;
    color: #92400e;
    text-align: right;
    background: transparent;
    padding: 0;
}

.proj-input-wrap span {
    font-size: 13px;
    font-weight: 600;
    color: #92400e;
}

.proj-card {
    background: #f0fdf4;
    border: 1.5px solid #d1fae5;
    border-radius: 12px;
    padding: 12px 14px;
    margin-bottom: 6px;
    display: flex;
    flex-direction: column;
    gap: 7px;
}

.proj-card-linha {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    color: #374151;
}

.proj-card-linha strong {
    font-size: 15px;
    font-weight: 800;
    color: rgb(6, 107, 99);
}

.proj-obs {
    font-size: 11px;
    color: #9ca3af;
    margin: 0 2px 12px;
    line-height: 1.4;
}

body.tema-escuro .proj-controle { background: #2d1f00; border-color: #78350f; }
body.tema-escuro .proj-controle label { color: #fcd34d; }
body.tema-escuro .proj-alvo-lbl { color: #d1d5db; }
body.tema-escuro .proj-alvo-ctrl { background: #1f2937; border-color: #374151; }
body.tema-escuro .proj-alvo-btn { background: #374151; color: #d1d5db; }
body.tema-escuro .proj-alvo-btn:active { background: #4b5563; }
body.tema-escuro .proj-alvo-val-wrap { border-color: #374151; }
body.tema-escuro .proj-alvo-val-wrap input { color: #f9fafb; }
body.tema-escuro .proj-alvo-val-wrap span { color: #9ca3af; }
body.tema-escuro .proj-input-wrap { background: #1f2937; border-color: #78350f; }
body.tema-escuro .proj-input-wrap input,
body.tema-escuro .proj-input-wrap span { color: #fcd34d; }
body.tema-escuro .proj-card { background: #052e2b; border-color: #0f4d47; }
body.tema-escuro .proj-card-linha { color: #d1d5db; }
body.tema-escuro .proj-card-linha strong { color: #34d399; }

/* ─── LAYOUT DESKTOP (≥ 900px) ───────────────────────────────────────────── */
@media (min-width: 900px) {

  /* Fundo = mesma cor do topo/sidebar → tudo vira um bloco verde contínuo */
  body {
    background: rgb(4,75,70);
    display: flex;
    flex-direction: column;
    height: 100vh;
    overflow: hidden;
  }

  /* Topo fica colado ao topo sem borda visível */
  .topo {
    flex-shrink: 0;
    z-index: 100;
  }

  /* Título centralizado */
  .topo-conteudo {
    position: relative;
  }

  .topo-esquerda {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
  }

  .topo-direita {
    margin-left: auto;
  }

  /* Card preenche o resto da altura sem margens externas */
  #card-gestao {
    display: flex !important;
    flex-direction: row !important;
    flex: 1 !important;
    min-height: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    background: transparent !important;
    align-items: stretch !important;
    overflow: hidden !important;
  }

  /* Sidebar: funde visualmente com o fundo verde */
  #menuGestao {
    display: flex !important;
    flex-direction: column !important;
    width: 220px !important;
    min-width: 220px !important;
    flex-shrink: 0 !important;
    background: rgba(0,0,0,0.15) !important;
    padding: 20px 10px !important;
    gap: 3px !important;
    margin-top: 0 !important;
    border-radius: 0 !important;
    overflow-y: auto !important;
  }

  #menuGestao::before {
    content: "Menu principal";
    display: block;
    color: rgba(255,255,255,0.72);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1.3px;
    text-transform: uppercase;
    padding: 0 8px 12px;
    border-bottom: 1px solid rgba(255,255,255,0.18);
    margin-bottom: 10px;
    flex-shrink: 0;
  }

  /* Botões da sidebar: horizontais */
  #menuGestao .botao-gestao {
    flex-direction: row !important;
    justify-content: flex-start !important;
    gap: 10px !important;
    padding: 10px 12px !important;
    font-size: 13px !important;
    min-height: unset !important;
    border-radius: 9px !important;
    background: transparent !important;
    color: rgba(255,255,255,0.82) !important;
    text-align: left !important;
    width: 100% !important;
    box-sizing: border-box !important;
    transition: background 0.15s, color 0.15s !important;
  }

  #menuGestao .botao-gestao:hover {
    background: rgba(255,255,255,0.13) !important;
    color: white !important;
  }

  #menuGestao .botao-gestao:active {
    background: rgba(255,255,255,0.22) !important;
  }

  #menuGestao .btn-svg {
    width: 17px !important;
    height: 17px !important;
    stroke: rgba(255,255,255,0.72) !important;
    flex-shrink: 0 !important;
  }

  #menuGestao .botao-gestao:hover .btn-svg {
    stroke: white !important;
  }

  /* Área de conteúdo: painel flutuante com margem mostrando o verde ao redor */
  #area-gestao {
    flex: 1 !important;
    margin: 16px 16px 16px 0 !important;
    padding: 28px 32px !important;
    background: #f4f9f7 !important;
    border-radius: 14px !important;
    box-shadow: 0 4px 24px rgba(0,0,0,0.22) !important;
    overflow-y: auto !important;
    color: #1a1a1a !important;
    box-sizing: border-box !important;
    min-height: 0 !important;
  }

  #area-gestao.resultado:empty::before {
    content: "← Selecione uma opção no menu lateral";
    display: block;
    text-align: center;
    color: #b0c4be;
    font-size: 14px;
    margin-top: 100px;
    font-weight: 500;
  }
}

/* ─── DARK MODE no desktop ────────────────────────────────────────────────── */
@media (min-width: 900px) {
  body.tema-escuro {
    background: #021a18;
  }

  body.tema-escuro #menuGestao {
    background: rgba(0,0,0,0.3) !important;
  }

  body.tema-escuro #area-gestao {
    background: #111827 !important;
    color: #f3f4f6 !important;
    box-shadow: 0 4px 24px rgba(0,0,0,0.5) !important;
  }

  body.tema-escuro #area-gestao.resultado:empty::before {
    color: #374151;
  }
}

/* ═══════════════════════════════════════════════════════════════════════════
   CONFIGURAÇÕES
   ═══════════════════════════════════════════════════════════════════════════ */

.cfg-wrap {
    max-width: 600px;
    margin: 0 auto;
}

/* Cabeçalho com avatar + nome + e-mail */
.cfg-header {
    display: flex;
    align-items: center;
    gap: 14px;
    background: #f0fdf4;
    border: 1.5px solid #d1fae5;
    border-radius: 14px;
    padding: 14px 16px;
    margin-bottom: 16px;
}

.cfg-header-avatar {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: rgb(6,107,99);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
    color: white;
    font-size: 20px;
    font-weight: 700;
}

.cfg-header-avatar img { width: 100%; height: 100%; object-fit: cover; }

.cfg-header-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.cfg-header-nome {
    font-size: 16px;
    font-weight: 800;
    color: #1f2937;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.cfg-header-email {
    font-size: 12.5px;
    color: #6b7280;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.cfg-header-online {
    font-size: 11.5px;
    font-weight: 700;
    color: #16a34a;
    margin-top: 2px;
}

/* Lista de cards de opções */
.cfg-lista {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 10px;
}

.cfg-item {
    display: flex;
    align-items: center;
    gap: 14px;
    width: 100%;
    background: white;
    border: 1.5px solid #e5e7eb;
    border-radius: 14px;
    padding: 14px 16px;
    cursor: pointer;
    text-align: left;
    text-decoration: none;
    transition: background 0.15s, border-color 0.15s;
    box-sizing: border-box;
}

.cfg-item:hover { background: #f9fafb; border-color: #d1d5db; }
.cfg-item:active { background: #f3f4f6; }

.cfg-item-ico {
    width: 40px;
    height: 40px;
    border-radius: 11px;
    background: #f0fdf4;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.cfg-item-ico svg {
    width: 20px;
    height: 20px;
    stroke: rgb(6,107,99);
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.cfg-item-texto {
    display: flex;
    flex-direction: column;
    gap: 2px;
    flex: 1;
    min-width: 0;
}

.cfg-item-titulo {
    font-size: 14.5px;
    font-weight: 700;
    color: #1f2937;
}

.cfg-item-sub {
    font-size: 12px;
    color: #9ca3af;
    font-weight: 500;
}

.cfg-item-chevron {
    width: 18px;
    height: 18px;
    stroke: #c0c7cf;
    fill: none;
    stroke-width: 2.5;
    stroke-linecap: round;
    stroke-linejoin: round;
    flex-shrink: 0;
}

/* Sair da conta (vermelho) */
.cfg-item-sair {
    border-color: #fecaca;
    background: #fff5f5;
    margin-top: 4px;
}

.cfg-item-sair:hover { background: #fef2f2; border-color: #fca5a5; }
.cfg-item-sair .cfg-item-ico { background: #fee2e2; }
.cfg-item-sair .cfg-item-ico svg { stroke: #dc2626; }
.cfg-item-sair .cfg-item-titulo { color: #dc2626; }
.cfg-item-sair .cfg-item-sub { color: #f0a3a3; }

.cfg-sair-confirm {
    background: #fff5f5;
    border: 1.5px solid #fecaca;
    border-radius: 14px;
    padding: 14px 16px;
    margin-top: 8px;
}

.cfg-sair-confirm p {
    margin: 0 0 12px;
    font-size: 13.5px;
    font-weight: 600;
    color: #991b1b;
    text-align: center;
}

.cfg-sair-botoes { display: flex; gap: 10px; }

.cfg-sair-cancelar, .cfg-sair-confirmar {
    flex: 1;
    padding: 11px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    border: none;
}

.cfg-sair-cancelar { background: white; border: 1.5px solid #d1d5db; color: #374151; }
.cfg-sair-confirmar { background: #dc2626; color: white; }
.cfg-sair-confirmar:active { background: #b91c1c; }

/* Hero de seção (Segurança / Suporte) */
.cfg-hero {
    text-align: center;
    margin-bottom: 18px;
}

.cfg-hero-ico {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: #f0fdf4;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 12px;
}

.cfg-hero-ico svg {
    width: 28px;
    height: 28px;
    stroke: rgb(6,107,99);
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.cfg-hero h4 {
    margin: 0 0 4px;
    font-size: 17px;
    font-weight: 800;
    color: #1f2937;
}

.cfg-hero p {
    margin: 0;
    font-size: 13px;
    color: #6b7280;
}

.cfg-secao-desc {
    font-size: 13px;
    color: #6b7280;
    margin: 0 2px 14px;
    text-align: center;
}

/* Fazenda — foto */
.fazenda-foto-wrap {
    position: relative;
    width: 110px;
    height: 110px;
    margin: 4px auto 0;
}

.fazenda-foto {
    width: 110px;
    height: 110px;
    border-radius: 50%;
    background: rgb(6,107,99);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    color: white;
    font-size: 34px;
    font-weight: 700;
    border: 3px solid white;
    box-shadow: 0 4px 18px rgba(6,107,99,0.18);
}

.fazenda-foto img { width: 100%; height: 100%; object-fit: cover; }

.fazenda-foto-edit {
    position: absolute;
    bottom: 2px;
    right: 2px;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgb(6,107,99);
    border: 2.5px solid white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0,0,0,0.18);
}

.fazenda-foto-edit svg {
    width: 16px;
    height: 16px;
    stroke: white;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.fazenda-remover-foto {
    display: block;
    margin: 12px auto 18px;
    background: none;
    border: none;
    color: #dc2626;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
}

.fazenda-foto-dica {
    text-align: center;
    font-size: 12px;
    color: #9ca3af;
    margin: 10px 0 18px;
}

/* Aparência */
.aparencia-opcoes {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.aparencia-card {
    position: relative;
    background: white;
    border: 2px solid #e5e7eb;
    border-radius: 14px;
    padding: 14px 12px 12px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    transition: border-color 0.15s;
}

.aparencia-card.ativo { border-color: rgb(6,107,99); }

.aparencia-preview {
    width: 100%;
    height: 70px;
    border-radius: 10px;
    padding: 10px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    gap: 6px;
    justify-content: center;
}

.preview-claro { background: #f4f9f7; border: 1px solid #e5e7eb; }
.preview-escuro { background: #111827; border: 1px solid #374151; }

.aparencia-preview .ap-barra {
    height: 12px;
    border-radius: 4px;
    width: 60%;
}
.aparencia-preview .ap-linha {
    height: 7px;
    border-radius: 4px;
    width: 100%;
}
.aparencia-preview .ap-linha.curta { width: 70%; }

.preview-claro .ap-barra { background: rgb(6,107,99); }
.preview-claro .ap-linha { background: #d1d5db; }
.preview-escuro .ap-barra { background: #34d399; }
.preview-escuro .ap-linha { background: #4b5563; }

.aparencia-nome {
    font-size: 14px;
    font-weight: 700;
    color: #1f2937;
}

.aparencia-check {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 22px;
    height: 22px;
    padding: 3px;
    box-sizing: border-box;
    background: rgb(6,107,99);
    border-radius: 50%;
    stroke: white;
    fill: none;
    stroke-width: 3;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* Minha conta */
.conta-plano {
    display: flex;
    align-items: center;
    gap: 12px;
    background: linear-gradient(135deg, #fffbeb 0%, #fef9e7 100%);
    border: 1.5px solid #fde68a;
    border-radius: 14px;
    padding: 16px;
    margin-bottom: 12px;
}

.conta-plano-ico {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.conta-plano-ico svg {
    width: 26px;
    height: 26px;
    stroke: #d97706;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.conta-plano-nome {
    flex: 1;
    font-size: 16px;
    font-weight: 800;
    color: #92400e;
}

.conta-plano-badge {
    background: #16a34a;
    color: white;
    font-size: 11px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 99px;
}

.conta-info {
    background: white;
    border: 1.5px solid #e5e7eb;
    border-radius: 14px;
    padding: 4px 16px;
    margin-bottom: 12px;
}

.conta-info-linha {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #f0f1f3;
    font-size: 13.5px;
    color: #6b7280;
}

.conta-info-linha:last-child { border-bottom: none; }
.conta-info-linha strong { font-size: 14px; font-weight: 800; color: #1f2937; }

.conta-aviso {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #f0fdf4;
    border: 1.5px solid #d1fae5;
    border-radius: 12px;
    padding: 12px 14px;
    margin-top: 12px;
    font-size: 12.5px;
    color: #15803d;
    line-height: 1.4;
}

.conta-aviso svg {
    width: 22px;
    height: 22px;
    stroke: rgb(6,107,99);
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    flex-shrink: 0;
}

/* FAQ */
.faq-busca {
    display: flex;
    align-items: center;
    gap: 8px;
    background: white;
    border: 1.5px solid #d1d5db;
    border-radius: 12px;
    padding: 0 14px;
    margin-bottom: 14px;
}

.faq-busca svg {
    width: 17px;
    height: 17px;
    stroke: #9ca3af;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    flex-shrink: 0;
}

.faq-busca input {
    flex: 1;
    border: none;
    outline: none;
    padding: 12px 0;
    font-size: 14px;
    background: transparent;
}

.faq-lista {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.faq-item {
    background: white;
    border: 1.5px solid #e5e7eb;
    border-radius: 12px;
    overflow: hidden;
}

.faq-pergunta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    width: 100%;
    background: none;
    border: none;
    padding: 14px 16px;
    cursor: pointer;
    text-align: left;
    font-size: 14px;
    font-weight: 700;
    color: #1f2937;
}

.faq-seta {
    width: 17px;
    height: 17px;
    stroke: rgb(6,107,99);
    fill: none;
    stroke-width: 2.5;
    stroke-linecap: round;
    stroke-linejoin: round;
    flex-shrink: 0;
    transition: transform 0.25s;
}

.faq-seta.rot { transform: rotate(90deg); }

.faq-resposta {
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows 0.25s ease;
}

.faq-resposta.aberto { grid-template-rows: 1fr; }

.faq-resposta-inner { overflow: hidden; }

.faq-resposta-inner p {
    margin: 0;
    padding: 0 16px 14px;
    font-size: 13px;
    color: #4b5563;
    line-height: 1.5;
}

.faq-vazio {
    text-align: center;
    font-size: 13px;
    color: #9ca3af;
    padding: 16px;
    margin: 0;
}

.cfg-item-ico-alerta { background: #fffbeb !important; }
.cfg-item-ico-alerta svg { stroke: #d97706 !important; }

/* ─── DARK MODE — Configurações ──────────────────────────────────────────── */
body.tema-escuro .cfg-header { background: #052e2b; border-color: #0f4d47; }
body.tema-escuro .cfg-header-nome { color: #f3f4f6; }
body.tema-escuro .cfg-header-email { color: #9ca3af; }
body.tema-escuro .cfg-item { background: #1f2937; border-color: #374151; }
body.tema-escuro .cfg-item:hover { background: #283446; border-color: #4b5563; }
body.tema-escuro .cfg-item-ico { background: #052e2b; }
body.tema-escuro .cfg-item-ico svg { stroke: #34d399; }
body.tema-escuro .cfg-item-titulo { color: #f3f4f6; }
body.tema-escuro .cfg-item-sub { color: #9ca3af; }
body.tema-escuro .cfg-item-chevron { stroke: #6b7280; }
body.tema-escuro .cfg-item-sair { background: #2a1414; border-color: #7f1d1d; }
body.tema-escuro .cfg-item-sair .cfg-item-ico { background: #450a0a; }
body.tema-escuro .cfg-sair-confirm { background: #2a1414; border-color: #7f1d1d; }
body.tema-escuro .cfg-sair-confirm p { color: #fca5a5; }
body.tema-escuro .cfg-sair-cancelar { background: #1f2937; border-color: #4b5563; color: #d1d5db; }
body.tema-escuro .cfg-hero-ico { background: #052e2b; }
body.tema-escuro .cfg-hero-ico svg { stroke: #34d399; }
body.tema-escuro .cfg-hero h4 { color: #f3f4f6; }
body.tema-escuro .cfg-hero p, body.tema-escuro .cfg-secao-desc { color: #9ca3af; }
body.tema-escuro .fazenda-foto { border-color: #1f2937; }
body.tema-escuro .aparencia-card { background: #1f2937; border-color: #374151; }
body.tema-escuro .aparencia-card.ativo { border-color: #34d399; }
body.tema-escuro .aparencia-nome { color: #f3f4f6; }
body.tema-escuro .conta-info { background: #1f2937; border-color: #374151; }
body.tema-escuro .conta-info-linha { border-bottom-color: #374151; color: #9ca3af; }
body.tema-escuro .conta-info-linha strong { color: #f3f4f6; }
body.tema-escuro .conta-aviso { background: #052e2b; border-color: #0f4d47; color: #6ee7b7; }
body.tema-escuro .conta-aviso svg { stroke: #34d399; }
body.tema-escuro .faq-busca { background: #1f2937; border-color: #374151; }
body.tema-escuro .faq-busca input { color: #f3f4f6; }
body.tema-escuro .faq-item { background: #1f2937; border-color: #374151; }
body.tema-escuro .faq-pergunta { color: #f3f4f6; }
body.tema-escuro .faq-seta { stroke: #34d399; }
body.tema-escuro .faq-resposta-inner p { color: #d1d5db; }

/* ═══════════════════════════════════════════════════════════════════════════
   MÓDULO FINANCEIRO — reorganização
   ═══════════════════════════════════════════════════════════════════════════ */

/* Ícones coloridos do hub */
.cfg-item-ico-amber { background: #fffbeb !important; }
.cfg-item-ico-amber svg { stroke: #d97706 !important; }
.cfg-item-ico-roxo { background: #f5f3ff !important; }
.cfg-item-ico-roxo svg { stroke: #7c3aed !important; }
.cfg-item-ico-verde { background: #ecfdf5 !important; }
.cfg-item-ico-verde svg { stroke: #059669 !important; }

/* ── Custos fixos mensais ── */
.cf-explica {
    display: flex; gap: 10px; align-items: flex-start;
    background: #f0fdfa; border: 1px solid #99f6e4;
    border-radius: 12px; padding: 12px 14px; margin-bottom: 14px;
    font-size: 12.5px; color: #0f766e; line-height: 1.45;
}
.cf-explica svg { width: 18px; height: 18px; flex-shrink: 0; stroke: #0d9488; fill: none; stroke-width: 2; margin-top: 1px; }
.cf-explica strong { color: #0f766e; }

.cf-resumo { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 14px; }
.cf-resumo-card {
    background: #fff; border: 1px solid #e5e7eb; border-radius: 12px;
    padding: 12px 10px; text-align: center;
}
.cf-resumo-card small { display: block; font-size: 10.5px; color: #9ca3af; margin-bottom: 4px; }
.cf-resumo-card strong { font-size: 15px; color: #111827; font-weight: 700; }

.cf-lista { display: flex; flex-direction: column; gap: 10px; }
.cf-card {
    display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
    background: #fff; border: 1px solid #e5e7eb; border-radius: 14px;
    padding: 12px 14px;
}
.cf-card-off { opacity: 0.55; }
.cf-card-ico {
    width: 40px; height: 40px; flex-shrink: 0; border-radius: 10px;
    background: #ecfdf5; display: flex; align-items: center; justify-content: center;
}
.cf-card-ico svg { width: 20px; height: 20px; stroke: #059669; fill: none; stroke-width: 2; }
.cf-card-info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.cf-card-nome { font-size: 14px; font-weight: 600; color: #111827; }
.cf-card-cat { font-size: 11.5px; color: #9ca3af; }
.cf-card-valor { font-size: 15px; font-weight: 700; color: #059669; white-space: nowrap; }
.cf-card-valor small { font-size: 10.5px; font-weight: 500; color: #9ca3af; }
.cf-card-acoes { display: flex; gap: 6px; }
.cf-btn-acao {
    width: 32px; height: 32px; border-radius: 8px; border: 1px solid #e5e7eb;
    background: #f9fafb; display: flex; align-items: center; justify-content: center;
    cursor: pointer; padding: 0;
}
.cf-btn-acao svg { width: 16px; height: 16px; stroke: #6b7280; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.cf-btn-acao:hover { background: #f3f4f6; }
.cf-btn-excluir svg { stroke: #dc2626; }
.cf-confirmar {
    flex-basis: 100%; display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
    margin-top: 8px; padding-top: 10px; border-top: 1px dashed #e5e7eb;
    font-size: 13px; color: #374151;
}
.cf-confirmar span { flex: 1; }

/* Topo com ação à direita */
.fin-topo-acoes {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 14px;
}

.fin-novo-btn {
    background: rgb(6,107,99);
    color: white;
    border: none;
    border-radius: 10px;
    padding: 8px 14px;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    white-space: nowrap;
}
.fin-novo-btn:active { background: rgb(4,85,79); }

.bt-topo-btns { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.fin-novo-btn-sec {
    background: #fff;
    color: rgb(6,107,99);
    border: 1.5px solid rgb(6,107,99);
}
.fin-novo-btn-sec:active { background: #eef7f6; }

/* Seletor de fornecedor (filtro opcional) */
.bt-forn-filtro {
    display: flex; align-items: center; gap: 8px;
    margin-top: 8px; padding: 4px 10px;
    background: #fff; border: 1px solid #e5e7eb; border-radius: 10px;
}
.bt-forn-filtro svg { width: 15px; height: 15px; flex-shrink: 0; stroke: #6b7280; fill: none; stroke-width: 2; }
.bt-forn-filtro select {
    flex: 1; border: none; background: transparent; font-size: 13px;
    color: #374151; padding: 6px 0; outline: none; cursor: pointer;
    -webkit-appearance: none; appearance: none;
}
body.tema-escuro .bt-forn-filtro { background: #1f2937; border-color: #374151; }
body.tema-escuro .bt-forn-filtro svg { stroke: #9ca3af; }
body.tema-escuro .bt-forn-filtro select { color: #e5e7eb; }

/* Barra de total dos boletos (conforme o filtro) */
.bt-total-bar {
    display: flex; align-items: center; justify-content: space-between;
    margin-top: 10px; padding: 12px 16px;
    background: #f0fdfa; border: 1.5px solid #99f6e4; border-radius: 12px;
}
.bt-total-bar span { font-size: 13px; color: #0f766e; font-weight: 600; text-transform: capitalize; }
.bt-total-bar span small { color: #5e6b6a; font-weight: 500; text-transform: none; }
.bt-total-bar strong { font-size: 17px; color: #0f766e; font-weight: 800; }
body.tema-escuro .fin-novo-btn-sec { background: #1f2937; color: #34d399; border-color: #34d399; }
body.tema-escuro .bt-total-bar { background: #052e2b; border-color: #0f4d47; }
body.tema-escuro .bt-total-bar span { color: #5eead4; }
body.tema-escuro .bt-total-bar span small { color: #94a3a1; }
body.tema-escuro .bt-total-bar strong { color: #5eead4; }

/* Período */
.fin-periodo-row {
    display: flex;
    align-items: center;
    gap: 8px;
}
.fin-periodo-row input {
    flex: 1;
    min-width: 0;
}
.fin-periodo-row span { font-size: 12px; color: #9ca3af; flex-shrink: 0; }

.fin-limpar-filtros {
    display: block;
    margin: 0 0 12px auto;
    background: none;
    border: none;
    color: rgb(6,107,99);
    font-size: 12.5px;
    font-weight: 600;
    cursor: pointer;
    padding: 2px 4px;
}

/* Toggle Detalhado / Por tipo */
.fin-modo-toggle {
    display: flex;
    background: #eef0f2;
    border-radius: 11px;
    padding: 3px;
    margin-bottom: 14px;
}
.fin-modo-btn {
    flex: 1;
    border: none;
    background: transparent;
    padding: 9px;
    border-radius: 9px;
    font-size: 13px;
    font-weight: 700;
    color: #6b7280;
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
}
.fin-modo-btn.ativo { background: white; color: rgb(6,107,99); box-shadow: 0 1px 3px rgba(0,0,0,0.1); }

/* 4 cards de indicadores */
.fin-cards {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 16px;
}
.fin-card {
    background: white;
    border: 1.5px solid #e5e7eb;
    border-radius: 14px;
    padding: 12px 14px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}
.fin-card-top {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 6px;
}
.fin-card-top svg {
    width: 15px;
    height: 15px;
    stroke: rgb(6,107,99);
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    flex-shrink: 0;
}
.fin-card-top span {
    font-size: 11px;
    color: #6b7280;
    font-weight: 600;
}
.fin-card strong {
    display: block;
    font-size: 17px;
    font-weight: 800;
    color: rgb(6,107,99);
}
.fin-card small {
    display: block;
    font-size: 10.5px;
    color: #9ca3af;
    margin-top: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Lista de lançamentos */
.fin-lista-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
}
.fin-lista-head span {
    font-size: 14px;
    font-weight: 800;
    color: #1f2937;
}
.fin-ordenar {
    width: auto !important;
    padding: 6px 28px 6px 10px !important;
    font-size: 12.5px !important;
    font-weight: 600;
    border-radius: 9px !important;
}
.fin-lista {
    display: flex;
    flex-direction: column;
    gap: 5px;
    margin-bottom: 12px;
}
.fin-linha {
    display: grid;
    grid-template-columns: auto 44px 1fr auto;
    align-items: center;
    gap: 8px;
    padding: 10px 12px;
    background: #f9fafb;
    border: 1px solid #eef0f2;
    border-radius: 9px;
}
.fin-linha-virtual { background: #f0fdfa; border-color: #99f6e4; border-left: 3px solid #14b8a6; }
body.tema-escuro .fin-linha-virtual { background: #052e2b; border-color: #0f4d47; border-left-color: #14b8a6; }
.fin-linha-data { font-size: 11.5px; color: #6b7280; font-weight: 600; }
.fin-linha-viveiro { font-size: 11.5px; font-weight: 800; color: rgb(6,107,99); }
.fin-linha-desc {
    font-size: 13px;
    font-weight: 600;
    color: #1f2937;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.fin-linha-desc small {
    display: block;
    font-size: 10px;
    color: #9ca3af;
    font-weight: 500;
}
.fin-linha-valor { font-size: 13px; font-weight: 700; color: #1f2937; justify-self: end; }

/* Linha consolidada por categoria (Todos os viveiros) */
.fin-linha-cat {
    grid-template-columns: 1fr auto;
    padding: 12px;
}
.fin-linha-cat .fin-linha-desc {
    font-size: 14px;
    font-weight: 800;
    white-space: normal;
}
.fin-linha-cat .fin-linha-valor { font-size: 14.5px; }
.fin-lista-hint { font-size: 11px; color: #9ca3af; font-weight: 600; }
body.tema-escuro .fin-lista-hint { color: #9ca3af; }

/* Paginação */
.fin-paginacao {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}
.fin-paginacao button {
    background: white;
    border: 1.5px solid #d1d5db;
    border-radius: 9px;
    padding: 7px 12px;
    font-size: 12.5px;
    font-weight: 700;
    color: rgb(6,107,99);
    cursor: pointer;
}
.fin-paginacao button:disabled { opacity: 0.4; cursor: default; }
.fin-paginacao span { font-size: 12px; color: #9ca3af; font-weight: 600; }

/* Total geral */
.fin-total-geral {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #f0fdf4;
    border: 1.5px solid #d1fae5;
    border-radius: 14px;
    padding: 14px 16px;
}
.fin-total-geral-ico {
    width: 40px;
    height: 40px;
    border-radius: 11px;
    background: rgb(6,107,99);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.fin-total-geral-ico svg { width: 20px; height: 20px; stroke: white; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.fin-total-geral-txt { display: flex; flex-direction: column; }
.fin-total-geral-txt span { font-size: 12px; color: #15803d; font-weight: 600; }
.fin-total-geral-txt strong { font-size: 20px; font-weight: 900; color: rgb(6,107,99); }

/* Por tipo — pizza + ranking */
.fin-secao-titulo {
    font-size: 11px;
    font-weight: 800;
    color: #9ca3af;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 10px;
}
.fin-pizza-wrap {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 18px;
}
.fin-pizza-canvas {
    position: relative;
    width: 150px;
    height: 150px;
    flex-shrink: 0;
    margin: 0 auto;
}
.fin-pizza-centro {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    pointer-events: none;
}
.fin-pizza-centro span { display: block; font-size: 10px; color: #9ca3af; font-weight: 600; }
.fin-pizza-centro strong { display: block; font-size: 12px; font-weight: 800; color: #1f2937; }
.fin-pizza-legenda {
    flex: 1;
    min-width: 180px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.fin-leg-item { display: flex; align-items: center; gap: 8px; }
.fin-leg-dot { width: 11px; height: 11px; border-radius: 3px; flex-shrink: 0; }
.fin-leg-nome { flex: 1; font-size: 13px; font-weight: 600; color: #374151; }
.fin-leg-val { font-size: 12.5px; font-weight: 700; color: #1f2937; }
.fin-leg-val small { font-size: 11px; color: #9ca3af; font-weight: 600; }

.fin-ranking { margin-bottom: 4px; }
.fin-rank-linha {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    background: #f9fafb;
    border: 1px solid #eef0f2;
    border-radius: 9px;
    margin-bottom: 6px;
}
.fin-rank-pos {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: rgb(6,107,99);
    color: white;
    font-size: 12px;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.fin-rank-nome { flex: 1; font-size: 13px; font-weight: 600; color: #1f2937; }
.fin-rank-val { font-size: 13px; font-weight: 700; color: rgb(6,107,99); }

/* Formulário de boleto — vencimento auto */
.fin-venc-box {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #f0fdf4;
    border: 1.5px solid #d1fae5;
    border-radius: 12px;
    padding: 12px 14px;
    margin-top: 4px;
}
.fin-venc-label { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 700; color: #15803d; }
.fin-venc-label svg { width: 17px; height: 17px; stroke: rgb(6,107,99); fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.fin-venc-valor { font-size: 15px; font-weight: 800; color: rgb(6,107,99); }
.fin-venc-dica { font-size: 11px; color: #9ca3af; margin: 6px 2px 10px; }

/* Boletos — busca + cards */
.bt-busca {
    display: flex;
    align-items: center;
    gap: 8px;
    background: white;
    border: 1.5px solid #d1d5db;
    border-radius: 12px;
    padding: 0 14px;
    margin-bottom: 12px;
}
.bt-busca svg { width: 17px; height: 17px; stroke: #9ca3af; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.bt-busca input { flex: 1; border: none; outline: none; padding: 11px 0; font-size: 14px; background: transparent; }

.bt-chip-sub { font-size: 10px; color: #6b7280; font-weight: 700; margin-top: 2px; }
.bt-chip-ok { color: #16a34a; }

.bt-card {
    position: relative;
    display: flex;
    align-items: stretch;
    flex-wrap: wrap;
    background: white;
    border: 1.5px solid #e5e7eb;
    border-radius: 11px;
    margin-bottom: 6px;
    overflow: visible;
}
.bt-card .bt-confirmar-inline {
    flex-basis: 100%;
    border-top: 1px solid #fecaca;
    border-radius: 0 0 10px 10px;
}
.bt-card-pago { opacity: 0.72; }
.bt-card-main { flex: 1; padding: 8px 12px; cursor: pointer; min-width: 0; }
.bt-card-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 2px; }
.bt-card-nome { font-size: 13px; font-weight: 800; color: #1f2937; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bt-card-sub { font-size: 11px; color: #6b7280; margin-bottom: 2px; }
.bt-card-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.bt-card-venc { font-size: 11px; color: #6b7280; font-weight: 500; }
.bt-card-valor { font-size: 13px; font-weight: 800; color: rgb(6,107,99); }

/* Detalhe do boleto */
.bt-det-topo {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}
.bt-det-ico {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: #f0fdf4;
    display: flex;
    align-items: center;
    justify-content: center;
}
.bt-det-ico svg { width: 28px; height: 28px; stroke: rgb(6,107,99); fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.bt-det-info {
    background: white;
    border: 1.5px solid #e5e7eb;
    border-radius: 14px;
    padding: 4px 16px;
}
.bt-det-linha {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px solid #f0f1f3;
    font-size: 13.5px;
    color: #6b7280;
}
.bt-det-linha:last-child { border-bottom: none; }
.bt-det-linha strong { font-size: 14px; font-weight: 700; color: #1f2937; }
.bt-det-valor strong { font-size: 18px; color: rgb(6,107,99); }

.bt-det-historico {
    background: #f9fafb;
    border: 1.5px solid #eef0f2;
    border-radius: 14px;
    padding: 12px 16px;
    margin-top: 14px;
}
.bt-det-historico h4 { margin: 0 0 8px; font-size: 13px; font-weight: 800; color: #1f2937; }
.bt-hist-linha { display: flex; gap: 12px; padding: 5px 0; font-size: 12.5px; }
.bt-hist-data { color: #9ca3af; font-weight: 600; flex-shrink: 0; }
.bt-hist-txt { color: #4b5563; }

/* DARK MODE — financeiro */
body.tema-escuro .fin-modo-toggle { background: #374151; }
body.tema-escuro .fin-modo-btn.ativo { background: #1f2937; color: #34d399; }
body.tema-escuro .fin-card { background: #1f2937; border-color: #374151; }
body.tema-escuro .fin-card strong { color: #34d399; }
body.tema-escuro .cf-explica { background: #052e2b; border-color: #0f4d47; color: #5eead4; }
body.tema-escuro .cf-explica strong { color: #5eead4; }
body.tema-escuro .cf-resumo-card { background: #1f2937; border-color: #374151; }
body.tema-escuro .cf-resumo-card strong { color: #f3f4f6; }
body.tema-escuro .cf-card { background: #1f2937; border-color: #374151; }
body.tema-escuro .cf-card-ico { background: #052e2b; }
body.tema-escuro .cf-card-ico svg { stroke: #34d399; }
body.tema-escuro .cf-card-nome { color: #f3f4f6; }
body.tema-escuro .cf-card-valor { color: #34d399; }
body.tema-escuro .cf-btn-acao { background: #374151; border-color: #4b5563; }
body.tema-escuro .cf-btn-acao svg { stroke: #d1d5db; }
body.tema-escuro .fin-card-top span { color: #9ca3af; }
body.tema-escuro .fin-card-top svg { stroke: #34d399; }
body.tema-escuro .fin-lista-head span { color: #f3f4f6; }
body.tema-escuro .fin-linha { background: #374151; border-color: #4b5563; }
body.tema-escuro .fin-linha-desc { color: #f3f4f6; }
body.tema-escuro .fin-linha-valor { color: #f3f4f6; }
body.tema-escuro .fin-linha-viveiro { color: #34d399; }
body.tema-escuro .fin-total-geral { background: #052e2b; border-color: #0f4d47; }
body.tema-escuro .fin-total-geral-txt strong { color: #34d399; }
body.tema-escuro .fin-paginacao button { background: #1f2937; border-color: #4b5563; color: #34d399; }
body.tema-escuro .fin-rank-linha { background: #374151; border-color: #4b5563; }
body.tema-escuro .fin-rank-nome { color: #f3f4f6; }
body.tema-escuro .fin-rank-val { color: #34d399; }
body.tema-escuro .fin-leg-nome { color: #d1d5db; }
body.tema-escuro .fin-leg-val { color: #f3f4f6; }
body.tema-escuro .fin-pizza-centro strong { color: #f3f4f6; }
body.tema-escuro .fin-venc-box { background: #052e2b; border-color: #0f4d47; }
body.tema-escuro .fin-venc-valor, body.tema-escuro .fin-venc-label { color: #34d399; }
body.tema-escuro .fin-venc-label svg { stroke: #34d399; }
body.tema-escuro .bt-busca { background: #1f2937; border-color: #374151; }
body.tema-escuro .bt-busca input { color: #f3f4f6; }
body.tema-escuro .bt-card { background: #1f2937; border-color: #374151; }
body.tema-escuro .bt-card-nome { color: #f3f4f6; }
body.tema-escuro .bt-card-valor { color: #34d399; }
body.tema-escuro .bt-det-info { background: #1f2937; border-color: #374151; }
body.tema-escuro .bt-det-linha { border-bottom-color: #374151; color: #9ca3af; }
body.tema-escuro .bt-det-linha strong { color: #f3f4f6; }
body.tema-escuro .bt-det-valor strong { color: #34d399; }
body.tema-escuro .bt-det-ico { background: #052e2b; }
body.tema-escuro .bt-det-ico svg { stroke: #34d399; }
body.tema-escuro .bt-det-historico { background: #374151; border-color: #4b5563; }
body.tema-escuro .bt-det-historico h4 { color: #f3f4f6; }
body.tema-escuro .bt-hist-txt { color: #d1d5db; }

/* Ajuste de espaçamento de chips/abas no novo layout do Financeiro */
.cfg-wrap .bt-chips { padding: 0; margin-bottom: 12px; }
.cfg-wrap .bt-abas { padding: 0; margin-bottom: 14px; }
.cfg-wrap .bt-lista { margin-bottom: 4px; }
.cfg-wrap .bt-empty { padding: 24px 8px; text-align: center; color: #9ca3af; font-size: 13px; }

/* ═══════════════════════════════════════════════════════════════════════════
   TELA DO VIVEIRO — cabeçalho e ações agrupadas
   ═══════════════════════════════════════════════════════════════════════════ */

.vv-header {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 16px;
}
.vv-header-ico {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    background: #eef4f3;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.vv-header-ico svg {
    width: 28px;
    height: 28px;
    stroke: rgb(6,107,99);
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}
.vv-header-info { flex: 1; min-width: 0; }
.vv-titulo {
    margin: 0;
    font-size: 22px;
    font-weight: 900;
    color: rgb(6,107,99);
    letter-spacing: -0.5px;
}
.vv-sub {
    margin: 2px 0 0;
    font-size: 13px;
    color: #6b7280;
    font-weight: 500;
}
.vv-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    margin-top: 6px;
    font-size: 11.5px;
    font-weight: 700;
    color: #16a34a;
}
.vv-badge-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #16a34a;
}
.vv-pls {
    background: #eef4f3;
    color: rgb(6,107,99);
    font-size: 14px;
    font-weight: 800;
    padding: 10px 14px;
    border-radius: 12px;
    flex-shrink: 0;
    white-space: nowrap;
}

/* Card de indicador em destaque (Custo parcial) */
.info-box-destaque {
    background: #f0fdf4;
    border: 1.5px solid #d1fae5;
}
.info-box-destaque strong { color: rgb(6,107,99); }

/* Rótulos de seção de ações */
.vv-secao-lbl {
    font-size: 11px;
    font-weight: 800;
    color: #9ca3af;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin: 18px 2px 10px;
}

/* Alerta de sobrevivência inconsistente (>100%) */
.vv-alerta-inconsistencia {
    display: flex; align-items: flex-start; gap: 9px;
    background: #fffbeb; border: 1px solid #fde68a; border-radius: 12px;
    padding: 11px 14px; margin: 4px 2px 0;
}
.vv-alerta-inconsistencia svg { width: 18px; height: 18px; flex-shrink: 0; stroke: #d97706; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; margin-top: 1px; }
.vv-alerta-inconsistencia span { font-size: 12.5px; color: #92400e; line-height: 1.45; }
body.tema-escuro .vv-alerta-inconsistencia { background: #2a2000; border-color: #78530f; }
body.tema-escuro .vv-alerta-inconsistencia span { color: #fcd34d; }

/* Ações de manejo — 4 botões compactos */
.vv-manejo-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
}
.vv-manejo-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 7px;
    background: rgb(6,107,99);
    border: none;
    border-radius: 13px;
    padding: 14px 4px;
    cursor: pointer;
    color: white;
    transition: background 0.15s;
}
.vv-manejo-btn:active { background: rgb(4,85,79); }
.vv-manejo-btn svg {
    width: 22px;
    height: 22px;
    stroke: white;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}
.vv-manejo-btn span {
    font-size: 11px;
    font-weight: 700;
    line-height: 1.2;
    text-align: center;
}

/* Consultas — botão Histórico */
.vv-consulta-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    background: white;
    border: 1.5px solid #d1d5db;
    border-radius: 13px;
    padding: 14px;
    font-size: 15px;
    font-weight: 700;
    color: rgb(6,107,99);
    cursor: pointer;
}
.vv-consulta-btn:active { background: #f3f4f6; }
.vv-consulta-btn svg {
    width: 19px;
    height: 19px;
    stroke: rgb(6,107,99);
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* Ações de administração — 3 botões coloridos */
.vv-admin-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
}
.vv-admin-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 7px;
    border: none;
    border-radius: 13px;
    padding: 14px 4px;
    cursor: pointer;
    color: white;
}
.vv-admin-btn svg {
    width: 21px;
    height: 21px;
    stroke: white;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}
.vv-admin-btn span {
    font-size: 11px;
    font-weight: 700;
    line-height: 1.2;
    text-align: center;
}
.vv-admin-amber { background: #f59e0b; }
.vv-admin-amber:active { background: #d97706; }
.vv-admin-cinza { background: #6b7280; }
.vv-admin-cinza:active { background: #4b5563; }
.vv-admin-vermelho { background: #ef4444; }
.vv-admin-vermelho:active { background: #dc2626; }

/* Dark mode */
body.tema-escuro .vv-header-ico { background: #052e2b; }
body.tema-escuro .vv-header-ico svg { stroke: #34d399; }
body.tema-escuro .vv-titulo { color: #34d399; }
body.tema-escuro .vv-sub { color: #9ca3af; }
body.tema-escuro .vv-pls { background: #052e2b; color: #34d399; }
body.tema-escuro .info-box-destaque { background: #052e2b; border-color: #0f4d47; }
body.tema-escuro .info-box-destaque strong { color: #34d399; }
body.tema-escuro .vv-consulta-btn { background: #1f2937; border-color: #4b5563; color: #34d399; }
body.tema-escuro .vv-consulta-btn svg { stroke: #34d399; }

/* ═══════════════════════════════════════════════════════════════════════════
   RELATÓRIO DE CICLO — versão do app
   ═══════════════════════════════════════════════════════════════════════════ */

.rc-report { max-width: 600px; margin: 0 auto; }

/* Cabeçalho */
.rc-header { text-align: center; margin-bottom: 18px; }
.rc-header-ico {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    background: rgb(6,107,99);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 12px;
}
.rc-header-ico svg { width: 28px; height: 28px; stroke: white; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.rc-titulo {
    margin: 0;
    font-size: 26px;
    font-weight: 900;
    color: rgb(6,107,99);
    letter-spacing: -0.5px;
}
.rc-marca {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin: 6px 0 12px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.08em;
    color: #6b7280;
}
.rc-marca-traco { width: 28px; height: 1px; background: #d1d5db; }
.rc-viveiro-pill {
    display: inline-block;
    border: 1.5px solid rgb(6,107,99);
    color: rgb(6,107,99);
    font-size: 14px;
    font-weight: 800;
    padding: 7px 22px;
    border-radius: 99px;
}

/* Período */
.rc-periodo {
    display: flex;
    align-items: stretch;
    flex-wrap: wrap;
    gap: 8px;
    background: #f8fafc;
    border: 1.5px solid #eef0f2;
    border-radius: 14px;
    padding: 12px 12px;
    margin-bottom: 16px;
}
.rc-periodo-item {
    flex: 1 1 108px;
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
}
.rc-periodo-item svg { width: 19px; height: 19px; stroke: rgb(6,107,99); fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.rc-periodo-txt { display: flex; flex-direction: column; min-width: 0; }
.rc-periodo-txt small { font-size: 9px; color: #9ca3af; font-weight: 700; text-transform: uppercase; letter-spacing: 0.02em; line-height: 1.2; }
.rc-periodo-txt strong { font-size: 13px; font-weight: 800; color: #1f2937; white-space: nowrap; }
.rc-periodo-seta { align-self: center; color: #9ca3af; font-size: 15px; flex-shrink: 0; }
.rc-periodo-destaque {
    background: rgb(6,107,99);
    border-radius: 11px;
    padding: 10px 14px;
    flex: 1 1 132px;
}
.rc-periodo-destaque svg { stroke: white; }
.rc-periodo-destaque .rc-periodo-txt small { color: rgba(255,255,255,0.75); }
.rc-periodo-destaque .rc-periodo-txt strong { color: white; }

/* Seções */
.rc-secao {
    background: #fbfcfd;
    border: 1.5px solid #eef0f2;
    border-radius: 16px;
    padding: 14px;
    margin-bottom: 14px;
}
.rc-secao-titulo {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    font-weight: 800;
    color: rgb(6,107,99);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 12px;
}
.rc-secao-titulo svg { width: 16px; height: 16px; stroke: rgb(6,107,99); fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }

/* Informações — 4 cards */
.rc-info-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}
.rc-info-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 4px;
    background: white;
    border: 1px solid #eef0f2;
    border-radius: 12px;
    padding: 12px 8px;
    min-width: 0;
}
.rc-info-card svg { width: 20px; height: 20px; stroke: rgb(6,107,99); fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; margin-bottom: 2px; }
.rc-info-card small { font-size: 10px; color: #9ca3af; font-weight: 700; text-transform: uppercase; letter-spacing: 0.02em; line-height: 1.2; }
.rc-info-card strong { font-size: 14px; font-weight: 800; color: #1f2937; }

/* Resultado produtivo — 3 cards */
.rc-result-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
}
.rc-result-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 2px;
    background: #f0fdf4;
    border: 1.5px solid #d1fae5;
    border-radius: 14px;
    padding: 12px 6px 11px;
}
.rc-result-ico {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #d8f3e3;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 6px;
}
.rc-result-ico svg { width: 17px; height: 17px; stroke: rgb(6,107,99); fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.rc-result-card strong { font-size: 19px; font-weight: 900; color: rgb(6,107,99); line-height: 1.05; }
.rc-result-un { font-size: 11px; font-weight: 700; color: rgb(6,107,99); }
.rc-result-card small { font-size: 9.5px; color: #6b7280; font-weight: 700; text-transform: uppercase; letter-spacing: 0.01em; margin-top: 4px; line-height: 1.2; }

/* Duo (Alimentação / Despesca) */
.rc-duo {
    display: flex;
    align-items: center;
    background: white;
    border: 1px solid #eef0f2;
    border-radius: 12px;
    padding: 12px 14px;
}
.rc-duo-item { flex: 1; display: flex; align-items: center; gap: 10px; min-width: 0; }
.rc-duo-item svg { width: 22px; height: 22px; stroke: rgb(6,107,99); fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.rc-duo-txt { display: flex; flex-direction: column; }
.rc-duo-txt small { font-size: 10px; color: #9ca3af; font-weight: 700; text-transform: uppercase; letter-spacing: 0.02em; }
.rc-duo-txt strong { font-size: 16px; font-weight: 800; color: #1f2937; }
.rc-duo-sep { width: 1px; align-self: stretch; background: #eef0f2; margin: 0 8px; }

/* Lista (custos) */
.rc-lista { background: white; border: 1px solid #eef0f2; border-radius: 12px; padding: 4px 14px; }
.rc-lista-row { display: flex; justify-content: space-between; align-items: center; padding: 10px 0; border-bottom: 1px solid #f0f1f3; font-size: 13.5px; color: #4b5563; }
.rc-lista-row:last-child { border-bottom: none; }
.rc-lista-row strong { font-size: 14px; font-weight: 800; color: #1f2937; }
.rc-lista-total { font-weight: 800; }
.rc-lista-total span { font-weight: 800; color: #1f2937; }
.rc-lista-total strong { color: rgb(6,107,99); }

/* Hero — produção final */
.rc-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    background: rgb(6,107,99);
    border-radius: 16px;
    padding: 18px 20px;
    margin: 4px 0 16px;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
}
.rc-hero-esq { display: flex; align-items: center; gap: 12px; }
.rc-hero-ico {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    border: 2px solid rgba(255,255,255,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.rc-hero-ico svg { width: 22px; height: 22px; stroke: white; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.rc-hero-label { font-size: 13px; font-weight: 700; color: white; text-transform: uppercase; letter-spacing: 0.03em; }
.rc-hero-valor { font-size: 24px; font-weight: 900; color: white; white-space: nowrap; }

/* Dark mode */
body.tema-escuro .rc-titulo { color: #34d399; }
body.tema-escuro .rc-viveiro-pill { border-color: #34d399; color: #34d399; }
body.tema-escuro .rc-periodo { background: #1f2937; border-color: #374151; }
body.tema-escuro .rc-periodo-txt strong { color: #f3f4f6; }
body.tema-escuro .rc-periodo-item svg { stroke: #34d399; }
body.tema-escuro .rc-secao { background: #1a2230; border-color: #374151; }
body.tema-escuro .rc-secao-titulo, body.tema-escuro .rc-secao-titulo svg { color: #34d399; stroke: #34d399; }
body.tema-escuro .rc-info-card { background: #1f2937; border-color: #374151; }
body.tema-escuro .rc-info-card strong { color: #f3f4f6; }
body.tema-escuro .rc-info-card svg { stroke: #34d399; }
body.tema-escuro .rc-result-card { background: #052e2b; border-color: #0f4d47; }
body.tema-escuro .rc-result-ico { background: #0f4d47; }
body.tema-escuro .rc-result-ico svg { stroke: #34d399; }
body.tema-escuro .rc-result-card strong, body.tema-escuro .rc-result-un { color: #34d399; }
body.tema-escuro .rc-duo { background: #1f2937; border-color: #374151; }
body.tema-escuro .rc-duo-txt strong { color: #f3f4f6; }
body.tema-escuro .rc-duo-item svg { stroke: #34d399; }
body.tema-escuro .rc-duo-sep { background: #374151; }
body.tema-escuro .rc-lista { background: #1f2937; border-color: #374151; }
body.tema-escuro .rc-lista-row { border-bottom-color: #374151; color: #9ca3af; }
body.tema-escuro .rc-lista-row strong { color: #f3f4f6; }
body.tema-escuro .rc-lista-total strong { color: #34d399; }

/* Caixa do relatório técnico (impressão) na tela do app */
.rc-print-box {
    background: #f0fdf4;
    border: 1.5px solid #d1fae5;
    border-radius: 14px;
    padding: 14px;
    margin-top: 4px;
}
.rc-print-box-titulo { font-size: 12px; font-weight: 800; color: rgb(6,107,99); text-transform: uppercase; letter-spacing: 0.04em; margin-bottom: 10px; }
.rc-print-dica { font-size: 11px; color: #6b7280; margin: 0 0 10px; }
body.tema-escuro .rc-print-box { background: #052e2b; border-color: #0f4d47; }
body.tema-escuro .rc-print-box-titulo { color: #34d399; }
body.tema-escuro .rc-print-dica { color: #9ca3af; }

/* ═══════════════════════════════════════════════════════════════════════════
   MANEJO AUTOMÁTICO
   ═══════════════════════════════════════════════════════════════════════════ */

/* Grade de consultas no viveiro (Histórico + Manejo automático) */
.vv-consulta-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.vv-consulta-grid .vv-consulta-btn { font-size: 13.5px; padding: 13px 8px; }

.ma-lista { display: flex; flex-direction: column; gap: 8px; }
.ma-vazio { text-align: center; color: #9ca3af; font-size: 13px; padding: 18px 8px; margin: 0; }

.ma-item {
    display: flex;
    align-items: center;
    gap: 10px;
    background: white;
    border: 1.5px solid #e5e7eb;
    border-radius: 13px;
    padding: 12px 14px;
}
.ma-item.ma-inativo { opacity: 0.55; }
.ma-item-info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.ma-item-nome { font-size: 14.5px; font-weight: 800; color: #1f2937; }
.ma-item-regra { font-size: 12px; color: #6b7280; }
.ma-item-acoes { display: flex; align-items: center; gap: 6px; flex-shrink: 0; }
.ma-btn-ic { background: none; border: none; font-size: 15px; cursor: pointer; padding: 4px; }

/* Toggle ativar/pausar */
.ma-toggle {
    width: 40px; height: 23px; border-radius: 99px; background: #d1d5db;
    border: none; position: relative; cursor: pointer; flex-shrink: 0; transition: background 0.2s;
}
.ma-toggle span {
    position: absolute; top: 3px; left: 3px; width: 17px; height: 17px;
    background: white; border-radius: 50%; transition: left 0.2s; box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}
.ma-toggle.on { background: rgb(6,107,99); }
.ma-toggle.on span { left: 20px; }

/* Dias da semana (chips) */
.ma-dias { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 6px; }
.ma-dia {
    flex: 1; min-width: 40px; padding: 9px 0; border-radius: 9px;
    border: 1.5px solid #d1d5db; background: white; color: #6b7280;
    font-size: 12px; font-weight: 700; cursor: pointer; transition: all 0.15s;
}
.ma-dia.sel { background: rgb(6,107,99); border-color: rgb(6,107,99); color: white; }

body.tema-escuro .ma-item { background: #1f2937; border-color: #374151; }
body.tema-escuro .ma-item-nome { color: #f3f4f6; }
body.tema-escuro .ma-toggle { background: #4b5563; }
body.tema-escuro .ma-toggle.on { background: #34d399; }
body.tema-escuro .ma-dia { background: #1f2937; border-color: #4b5563; color: #d1d5db; }
body.tema-escuro .ma-dia.sel { background: #34d399; border-color: #34d399; color: #052e2b; }

.ma-check {
    display: flex;
    align-items: center;
    gap: 9px;
    margin-top: 4px;
    font-size: 13.5px;
    font-weight: 600;
    color: #374151;
    cursor: pointer;
}
.ma-check input { width: 18px; height: 18px; accent-color: rgb(6,107,99); flex-shrink: 0; }
body.tema-escuro .ma-check { color: #d1d5db; }

/* Custos agrupados por produto */
.custo-grupo-lista { display: flex; flex-direction: column; gap: 6px; margin-bottom: 4px; }
.custo-grupo {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #f9fafb;
    border: 1px solid #eef0f2;
    border-radius: 10px;
    padding: 11px 14px;
}
.custo-grupo-info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.custo-grupo-nome { font-size: 14px; font-weight: 700; color: #1f2937; }
.custo-grupo-qtd { font-size: 12px; color: #6b7280; font-weight: 600; }
.custo-grupo-valor { font-size: 14px; font-weight: 800; color: rgb(6,107,99); white-space: nowrap; }
.custo-grupo .botao-editar { background: none; border: none; cursor: pointer; font-size: 15px; padding: 2px; flex-shrink: 0; }
.custo-grupo-conf { width: 100%; }
.custo-grupo-conf > span { font-size: 13px; font-weight: 600; color: #991b1b; }
.custo-grupo-conf-btns { display: flex; gap: 8px; margin-top: 8px; }
.custo-grupo-conf-btns button { flex: 1; padding: 9px; border-radius: 8px; border: none; font-size: 13px; font-weight: 700; cursor: pointer; }

body.tema-escuro .custo-grupo { background: #1f2937; border-color: #374151; }
body.tema-escuro .custo-grupo-nome { color: #f3f4f6; }
body.tema-escuro .custo-grupo-valor { color: #34d399; }

/* Área de custos — visual em cards */
.custo-titulo { margin: 0 0 10px; font-size: 20px; font-weight: 900; color: rgb(6,107,99); text-align: center; }
.custo-imprimir {
    display: flex; align-items: center; justify-content: center; gap: 6px;
    width: 100%; box-sizing: border-box; margin-bottom: 14px;
    background: white; border: 1.5px solid #d1d5db; border-radius: 10px;
    padding: 10px 14px; font-size: 14px; font-weight: 700; color: rgb(6,107,99); cursor: pointer;
}
.custo-imprimir svg { width: 16px; height: 16px; stroke: rgb(6,107,99); fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

.custo-card {
    display: flex; align-items: center; gap: 12px;
    background: white; border: 1.5px solid #eef0f2; border-radius: 14px;
    padding: 12px 14px; box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}
.custo-card-ico {
    width: 44px; height: 44px; border-radius: 50%; background: #eaf6f1;
    display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.custo-card-ico svg { width: 22px; height: 22px; stroke: rgb(6,107,99); fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.custo-card-info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 5px; }
.custo-card-nome { font-size: 15px; font-weight: 800; color: #1f2937; }
.custo-card-qtd {
    align-self: flex-start; font-size: 11.5px; font-weight: 700; color: #15803d;
    background: #eaf6f1; padding: 2px 9px; border-radius: 99px;
}
.custo-card-valor { font-size: 15px; font-weight: 800; color: rgb(6,107,99); white-space: nowrap; }
.custo-card-acoes { display: flex; align-items: center; gap: 2px; border-left: 1px solid #eef0f2; padding-left: 8px; flex-shrink: 0; }
.custo-card-rateio { background: #f0fdfa; border-color: #99f6e4; border-left: 3px solid #14b8a6; }
.custo-card-rateio .custo-card-ico { background: #ccfbf1; }
.custo-card-rateio .custo-card-ico svg { stroke: #0d9488; }
.custo-card-rateio .custo-card-qtd { color: #0f766e; background: #ccfbf1; }
body.tema-escuro .custo-card-rateio { background: #052e2b; border-color: #0f4d47; border-left-color: #14b8a6; }
.custo-card-acoes .botao-editar { background: none; border: none; cursor: pointer; font-size: 15px; padding: 4px; }

.custo-total {
    display: flex; align-items: center; gap: 12px;
    background: #f0fdf4; border: 1.5px solid #bbf7d0; border-radius: 14px;
    padding: 16px; margin-top: 12px;
}
.custo-total-ico {
    width: 42px; height: 42px; border-radius: 11px; background: rgb(6,107,99);
    display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.custo-total-ico svg { width: 22px; height: 22px; stroke: white; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.custo-total-lbl { flex: 1; font-size: 14px; font-weight: 800; color: #166534; text-transform: uppercase; letter-spacing: 0.02em; }
.custo-total-val { font-size: 22px; font-weight: 900; color: rgb(6,107,99); white-space: nowrap; }

body.tema-escuro .custo-titulo { color: #34d399; }
body.tema-escuro .custo-imprimir { background: #1f2937; border-color: #4b5563; color: #34d399; }
body.tema-escuro .custo-imprimir svg { stroke: #34d399; }
body.tema-escuro .custo-card { background: #1f2937; border-color: #374151; }
body.tema-escuro .custo-card-ico { background: #052e2b; }
body.tema-escuro .custo-card-ico svg { stroke: #34d399; }
body.tema-escuro .custo-card-nome { color: #f3f4f6; }
body.tema-escuro .custo-card-qtd { background: #052e2b; color: #6ee7b7; }
body.tema-escuro .custo-card-valor { color: #34d399; }
body.tema-escuro .custo-card-acoes { border-left-color: #374151; }
body.tema-escuro .custo-total { background: #052e2b; border-color: #0f4d47; }
body.tema-escuro .custo-total-lbl { color: #6ee7b7; }
body.tema-escuro .custo-total-val { color: #34d399; }

/* Gráficos na visualização do relatório de ciclo (2 gráficos: lado a lado no
   desktop, uma coluna no mobile) */
.rc-graficos { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
@media (max-width: 560px) { .rc-graficos { grid-template-columns: 1fr; } }
.rc-graf-box { background: white; border: 1px solid #eef0f2; border-radius: 12px; padding: 10px 8px 8px; }
.rc-graf-box h5 { margin: 0 0 6px; font-size: 11px; font-weight: 700; color: #374151; text-align: center; }
.rc-graf-canvas { position: relative; height: 120px; }
.rc-graf-nota { margin: 8px 2px 0; font-size: 11px; color: #9ca3af; line-height: 1.4; }
body.tema-escuro .rc-graf-nota { color: #6b7280; }

/* ═══ Relatório de ciclo — redesign limpo/compacto ═══ */
.rc2-report { background: #fff; padding: 14px 12px 18px; }
.rc2-head { text-align: center; padding-bottom: 12px; border-bottom: 1px solid #eef0f2; }
.rc2-titulo { font-size: 11.5px; font-weight: 800; letter-spacing: 1.6px; color: rgb(6,107,99); margin: 0 0 3px; }
.rc2-viveiro { font-size: 20px; font-weight: 800; color: #111827; }
.rc2-periodo { font-size: 12.5px; color: #6b7280; margin-top: 3px; }
.rc2-sec-tit { font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .5px; color: rgb(6,107,99); margin: 18px 0 8px; text-align: center; }
.rc2-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: #eef0f2; border: 1px solid #eef0f2; border-radius: 10px; overflow: hidden; }
.rc2-cell { background: #fff; padding: 9px 12px; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 2px; }
.rc2-cell small { font-size: 10.5px; color: #9ca3af; }
.rc2-cell b { font-size: 14px; color: #111827; font-weight: 700; }
.rc2-band { display: flex; border: 1px solid #eef0f2; border-radius: 10px; overflow: hidden; }
.rc2-band > div { flex: 1; min-width: 0; padding: 10px 5px; text-align: center; border-left: 1px solid #eef0f2; display: flex; flex-direction: column; justify-content: center; gap: 1px; }
.rc2-band > div:first-child { border-left: none; }
.rc2-band b { font-size: 15px; font-weight: 800; color: #111827; }
.rc2-band small { font-size: 9.5px; color: #9ca3af; }
.rc2-band span { font-size: 10px; color: #6b7280; margin-top: 2px; }
.rc2-lines { display: flex; flex-direction: column; }
.rc2-line { display: flex; justify-content: space-between; align-items: baseline; padding: 8px 2px; border-bottom: 1px dashed #eef0f2; font-size: 13px; }
.rc2-line span { color: #6b7280; }
.rc2-line b { color: #111827; font-weight: 700; }
.rc2-line-total { border-bottom: none; border-top: 1.5px solid rgb(6,107,99); margin-top: 2px; padding-top: 9px; }
.rc2-line-total span, .rc2-line-total b { color: rgb(6,107,99); font-weight: 800; font-size: 14px; }
.rc2-prodfinal { display: flex; justify-content: space-between; align-items: center; background: rgb(6,107,99); color: #fff; border-radius: 10px; padding: 11px 14px; margin-bottom: 10px; }
.rc2-prodfinal span { font-size: 12.5px; font-weight: 600; opacity: .92; }
.rc2-prodfinal b { font-size: 18px; font-weight: 800; }
.rc2-fin { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.rc2-fin > div { background: #f9fafb; border: 1px solid #eef0f2; border-radius: 10px; padding: 9px 11px; display: flex; flex-direction: column; gap: 2px; }
.rc2-fin small { font-size: 10.5px; color: #9ca3af; }
.rc2-fin b { font-size: 15px; font-weight: 800; color: #111827; }
.rc2-pos { color: #16a34a !important; }
.rc2-neg { color: #dc2626 !important; }
.rc2-fin-nota { font-size: 11px; color: #9ca3af; margin: 8px 2px 0; line-height: 1.4; }
.rc2-acoes { display: flex; gap: 10px; margin-top: 18px; }
body.tema-escuro .rc2-report { background: #111827; }
body.tema-escuro .rc2-head { border-bottom-color: #374151; }
body.tema-escuro .rc2-viveiro,
body.tema-escuro .rc2-cell b,
body.tema-escuro .rc2-band b,
body.tema-escuro .rc2-line b,
body.tema-escuro .rc2-fin b { color: #f3f4f6; }
body.tema-escuro .rc2-grid, body.tema-escuro .rc2-band { background: #374151; border-color: #374151; }
body.tema-escuro .rc2-cell, body.tema-escuro .rc2-fin > div { background: #1f2937; border-color: #374151; }
body.tema-escuro .rc2-band > div { background: #1f2937; border-left-color: #374151; }
body.tema-escuro .rc2-line { border-bottom-color: #374151; }
body.tema-escuro .rc-graf-box { background: #1f2937; border-color: #374151; }
body.tema-escuro .rc-graf-box h5 { color: #d1d5db; }
@media (max-width: 480px) {
  .rc-graficos { grid-template-columns: 1fr; }
}

/* Toggle do cadastro: Em preparação / Cultivo iniciado */
.cad-modo-toggle { display: flex; background: #eef0f2; border-radius: 11px; padding: 3px; margin-bottom: 14px; }
.cad-modo-btn { flex: 1; border: none; background: transparent; padding: 10px; border-radius: 9px; font-size: 13px; font-weight: 700; color: #6b7280; cursor: pointer; }
.cad-modo-btn.ativo { background: white; color: rgb(6,107,99); box-shadow: 0 1px 3px rgba(0,0,0,0.1); }
body.tema-escuro .cad-modo-toggle { background: #374151; }
body.tema-escuro .cad-modo-btn.ativo { background: #1f2937; color: #34d399; }

/* Status "Em preparação" no viveiro */
.prep-status {
    display: flex; align-items: center; gap: 14px;
    background: #fffbeb; border: 1.5px solid #fde68a; border-radius: 14px;
    padding: 16px; margin-bottom: 14px;
}
.prep-status-ico { width: 46px; height: 46px; border-radius: 12px; background: #fef3c7; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.prep-status-ico svg { width: 24px; height: 24px; stroke: #b45309; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.prep-status-txt { display: flex; flex-direction: column; }
.prep-status-lbl { font-size: 12px; font-weight: 700; color: #92400e; text-transform: uppercase; letter-spacing: 0.03em; }
.prep-status-dias { font-size: 20px; font-weight: 900; color: #b45309; }
.prep-status-txt small { font-size: 11.5px; color: #a16207; }
body.tema-escuro .prep-status { background: #2d1f00; border-color: #78350f; }
body.tema-escuro .prep-status-ico { background: #422006; }
