/* «Dos dados à…» (fatores): separadores como os de um caderno. O separador escolhido liga-se à página em baixo;
   os outros ficam esbatidos, cada um com o seu tom suave. Carrega por último e vence as folhas sóbrias. */

html body:not(#s1):not(#s2):not(#s3):not(#s4) #main .agri-report.fatores { gap: 0 !important; }
html body:not(#s1):not(#s2):not(#s3):not(#s4) #main .agri-report.fatores .sec-head { margin-bottom: 1.6rem; }
html body:not(#s1):not(#s2):not(#s3):not(#s4) #main .agri-report.fatores .ft-nota { margin-top: 1.6rem; }

/* A fila de separadores */
html body:not(#s1):not(#s2):not(#s3):not(#s4) #main .agri-report.fatores .ft-tabs {
    display: flex !important; gap: .35rem !important; align-items: stretch; margin: 0; padding: 0 .2rem;
    border: 0 !important; border-bottom: 1px solid #d9dfd9 !important;
}
html body:not(#s1):not(#s2):not(#s3):not(#s4) #main .agri-report.fatores .ft-tab {
    flex: 1 1 0; min-width: 0; display: grid; align-content: start; gap: .2rem; margin: 0 0 0 !important; padding: .8rem 1rem .7rem !important;
    border: 1px solid transparent !important; border-top: 3px solid color-mix(in srgb, var(--cap) 45%, #fff) !important; border-bottom: 0 !important; border-radius: 10px 10px 0 0 !important;
    background: color-mix(in srgb, var(--cap) 7%, #f7f6f1) !important; box-shadow: none !important; text-align: left !important;
    color: var(--r-suave, #56635b) !important; transform: none !important; transition: background .18s ease, border-color .18s ease;
}
html body:not(#s1):not(#s2):not(#s3):not(#s4) #main .agri-report.fatores .ft-tab:hover { background: color-mix(in srgb, var(--cap) 13%, #f7f6f1) !important; border-top-color: color-mix(in srgb, var(--cap) 75%, #fff) !important; }
html body:not(#s1):not(#s2):not(#s3):not(#s4) #main .agri-report.fatores .ft-tab * { color: inherit !important; -webkit-text-fill-color: currentColor !important; text-shadow: none !important; }
html body:not(#s1):not(#s2):not(#s3):not(#s4) #main .agri-report.fatores .ft-tab .ft-n { color: color-mix(in srgb, var(--cap) 80%, #1c2a21) !important; font-size: .68rem !important; letter-spacing: .12em; font-weight: 800; }
html body:not(#s1):not(#s2):not(#s3):not(#s4) #main .agri-report.fatores .ft-tab .ft-v { color: #4d5a52 !important; font-family: Georgia, "Times New Roman", serif !important; font-size: 1.35rem !important; font-weight: 600 !important; line-height: 1.15; }
html body:not(#s1):not(#s2):not(#s3):not(#s4) #main .agri-report.fatores .ft-tab .ft-k { color: #7a867f !important; font-size: .78rem !important; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* O separador ativo: sobe, ganha a cor cheia no topo e funde-se com a página */
html body:not(#s1):not(#s2):not(#s3):not(#s4) #main .agri-report.fatores .ft-tab[aria-selected="true"] {
    position: relative; z-index: 2; margin-bottom: -1px !important;
    background: #fff !important; border-color: #d9dfd9 !important; border-top: 3px solid color-mix(in srgb, var(--cap) 85%, #1c2a21) !important; border-bottom: 1px solid #fff !important;
}
html body:not(#s1):not(#s2):not(#s3):not(#s4) #main .agri-report.fatores .ft-tab[aria-selected="true"] .ft-v { color: color-mix(in srgb, var(--cap) 55%, #1c2a21) !important; }
html body:not(#s1):not(#s2):not(#s3):not(#s4) #main .agri-report.fatores .ft-tab[aria-selected="true"] .ft-k { color: #56635b !important; }

/* A página do separador */
html body:not(#s1):not(#s2):not(#s3):not(#s4) #main .agri-report.fatores .ft-painel {
    padding: 1.8rem 1.8rem 2rem !important; border: 1px solid #d9dfd9 !important; border-top: 0 !important; border-radius: 0 0 14px 14px !important;
    background: #fff !important; box-shadow: none !important;
}
html body:not(#s1):not(#s2):not(#s3):not(#s4) #main .agri-report.fatores .ft-titulo { color: #1c2a21 !important; font-family: Georgia, "Times New Roman", serif !important; }
html body:not(#s1):not(#s2):not(#s3):not(#s4) #main .agri-report.fatores .ft-rotulo { color: color-mix(in srgb, var(--cap) 80%, #1c2a21) !important; }

/* Sem vazios à direita: as práticas acompanham a leitura dos gráficos */
@media (min-width: 861px) {
    html body:not(#s1):not(#s2):not(#s3):not(#s4) #main .agri-report.fatores .ft-pratica { position: sticky; top: 6.5rem; align-self: start; }
}

/* Telemóvel: os separadores deslizam na horizontal */
@media (max-width: 860px) {
    html body:not(#s1):not(#s2):not(#s3):not(#s4) #main .agri-report.fatores .ft-tabs { overflow-x: auto; scrollbar-width: none; padding: 0; }
    html body:not(#s1):not(#s2):not(#s3):not(#s4) #main .agri-report.fatores .ft-tabs::-webkit-scrollbar { display: none; }
    html body:not(#s1):not(#s2):not(#s3):not(#s4) #main .agri-report.fatores .ft-tab { flex: 0 0 9.5rem; }
    html body:not(#s1):not(#s2):not(#s3):not(#s4) #main .agri-report.fatores .ft-painel { padding: 1.2rem 1rem 1.4rem !important; }
}
