/* =========================================
   Seção de Clientes — Carrossel com Abas
   ========================================= */

.clientes {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    padding: 6rem 0 5rem;
}

/* ── Cabeçalho ── */
.clientes-conteudo {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3rem;
}

.clientes-cabecalho {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    text-align: center;
    max-width: 700px;
}

.clientes-cabecalho .titulo span {
    color: var(--cor-secundaria);
}

/* ── Navegação de Abas ── */
.clientes-nav {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: #f4f5f9;
    border-radius: 50px;
    padding: 0.375rem;
}

.clientes-aba {
    cursor: pointer;
    border: none;
    background: transparent;
    font-family: var(--fonte-principal);
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--cor-texto);
    padding: 0.6rem 1.5rem;
    border-radius: 50px;
    transition: background 0.3s ease, color 0.3s ease, box-shadow 0.3s ease;
    white-space: nowrap;
}

.clientes-aba:hover {
    background: rgba(1, 6, 71, 0.07);
}

.clientes-aba.ativa {
    background: var(--cor-primaria);
    color: #fff;
    box-shadow: 0 4px 14px rgba(1, 6, 71, 0.3);
}

/* ── Painéis ── */
.clientes-paineis {
    width: 100%;
    position: relative;
}

.clientes-painel {
    display: none;
    flex-direction: column;
    gap: 2rem;
    animation: fadeInPanel 0.4s ease;
}

.clientes-painel.ativo {
    display: flex;
}

@keyframes fadeInPanel {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ── Carrossel ── */

/* Máscara de fade nas bordas */
.carrossel-linha {
    width: 100%;
    overflow: hidden;
    -webkit-mask-image: linear-gradient(
        to right,
        transparent 0%,
        black 8%,
        black 92%,
        transparent 100%
    );
    mask-image: linear-gradient(
        to right,
        transparent 0%,
        black 8%,
        black 92%,
        transparent 100%
    );
}

/* Faixa que contém todos os itens — usa CSS animation de translate */
.carrossel-faixa {
    display: flex;
    gap: 1.25rem;
    width: max-content;       /* Sem quebra de linha */
    will-change: transform;
}

/* Direção: esquerda (padrão) */
.carrossel-linha[data-direcao="esquerda"] .carrossel-faixa {
    animation: scrollEsquerda 35s linear infinite;
}

/* Direção: direita */
.carrossel-linha[data-direcao="direita"] .carrossel-faixa {
    animation: scrollDireita 38s linear infinite;
}

/* Pause ao hover na linha */
.carrossel-linha:hover .carrossel-faixa {
    animation-play-state: paused;
}

@keyframes scrollEsquerda {
    0%   { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

@keyframes scrollDireita {
    0%   { transform: translateX(-50%); }
    100% { transform: translateX(0); }
}

/* ── Item individual ── */
.carrossel-item {
    flex-shrink: 0;
    width: 180px;
    height: 100px;
    border-radius: 12px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ── Placeholder de logo ── */
/* Padrão: dessaturado (filtro grayscale) — hover restaura saturação */
.logo-placeholder {
    width: 100%;
    height: 100%;
    filter: grayscale(100%) opacity(0.45);
    transition: filter 0.35s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Quando real (img dentro de .carrossel-item) */
.carrossel-item img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: grayscale(100%) opacity(0.5);
    transition: filter 0.35s ease;
}

.carrossel-item:hover .logo-placeholder,
.carrossel-item:hover img {
    filter: grayscale(0%) opacity(1);
}
