/**
 * 4Brand Dashboard CSS — Modern App UI
 */

/* ========================================
   LAYOUT BASE
   ======================================== */
.dash-layout {
    min-height: 100vh;
    background: var(--paper-2);   /* #548 F1-5: mesa de trabalho em papel frio, sem gradiente */
    touch-action: manipulation;   /* #970: sem o zoom de toque duplo o toque vira clique na hora (era ~300 ms no iPhone: menu e barra inferior pareciam travados); pinça continua */
}

/* ========================================
   SIDEBAR
   ======================================== */
.dash-sidebar {
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    /* #204: no iOS Safari, `bottom:0` cai ATRÁS da barra inferior do navegador → o footer
       (botão Sair) fica escondido. 100dvh = viewport dinâmico (encolhe com as barras),
       então a sidebar cabe na área visível e o footer sempre aparece. 100vh = fallback. */
    height: 100vh;
    height: 100dvh;
    width: 260px;
    /* #548 F1-5 (Nova Era): sidebar em azul-noite com luz — área de impacto do app; conteúdo em papel */
    background: var(--night-bg); background-color: #0B1428; /* fallback sólido: se o token --night-bg não chegar (CSS de tokens antigo em cache/PWA, caso Firefox da cliente do Alex 29/09), a superfície continua azul-noite em vez de branco com texto branco */
    color: #fff;
    border-right: 1px solid rgba(255, 255, 255, 0.06);
    display: flex;
    flex-direction: column;
    z-index: 100;
    transition: transform 0.3s var(--ease-smooth);
}

.dash-sidebar-header {
    padding: 24px;
    padding-top: max(24px, env(safe-area-inset-top, 24px));
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.dash-sidebar-logo-link {
    /* #511 (L3): o <a> era inline — caixa de 83×20 (linha de texto) com a imagem de 32px vazando.
       inline-flex envolve a imagem; min-height 44 = alvo de toque; a margem negativa devolve os
       12px pra altura do cabeçalho da sidebar ficar exatamente como era (56px). */
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    margin: -6px 0;
    border-radius: var(--radius-md);
}

.dash-sidebar-logo {
    height: 32px;
    width: auto;   /* #548 F3: markup usa 4Brand_logo_white.png (filtro do F1-5 removido) */
}

.dash-sidebar-nav {
    flex: 1;
    /* #204 CAUSA RAIZ: num flex-column, o filho flex:1 tem min-height:auto e NÃO encolhe
       abaixo do conteúdo → cresce além da tela, empurra o footer (Sair) pra fora e o
       overflow nem age. min-height:0 libera o encolhimento → a nav rola de verdade. */
    min-height: 0;
    padding: 16px 12px;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain; /* #204 (Fabiano): scroll da nav não vaza p/ o body */
}

.dash-nav-section {
    margin-bottom: 8px;
}

.dash-nav-title {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    /* #428 (achado Wesley) — --text-light (#8B8B8B) só dá 3,41:1 sobre branco, falha AA. Passou
       despercebido enquanto isso rotulava só "Conversas recentes" (uso raro); virou rótulo de
       navegação PRINCIPAL ("🎁 Bônus" na sidebar + 2 títulos no hub) — sobe a cor só pra esta
       classe (não mexe no token --text-light global, que é usado em bem mais lugares). */
    color: var(--gold-400);          /* #548 F1-5: rótulo de seção dourado sobre a noite (10:1) */
    letter-spacing: 0.12em;
    padding: 8px 12px 6px;
}

.dash-nav-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 11px 12px;
    /* #511 (L3, achado Bruno #500): 11+11 de padding + linha de 14px dava 44,39px nos itens
       comuns e 42,8px nos de fonte menor (Sair e a seção de bônus) — abaixo do alvo mínimo
       de toque. min-height garante 44px em TODOS os itens sem mexer no espaçamento visual. */
    min-height: 44px;
    color: rgba(255, 255, 255, 0.78);   /* #548 F1-5: sobre a noite (12:1) */
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    border-radius: var(--radius-md);
    transition: all 0.2s var(--ease-smooth);
}

.dash-nav-link:hover {
    background: rgba(255, 255, 255, 0.06);
    color: #fff;
}

.dash-nav-link.active {
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
    font-weight: 600;
    box-shadow: inset 3px 0 0 var(--brand-gold);   /* barra dourada = item ativo (manifesto) */
}

.dash-nav-link i {
    width: 20px;
    text-align: center;
    font-size: 16px;
}

/* #124: "Convide e ganhe" — ícone dourado (destaque) + badge de convidados */
.dash-nav-invite i { color: var(--brand-gold, #D4A84B); }
.dash-nav-badge {
    margin-left: auto;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--brand-gold, #D4A84B);
    color: var(--night-900);        /* #548: texto noite sobre dourado (9,7:1) */
    font-size: 11px;
    font-weight: 700;
    border-radius: 999px;
    line-height: 1;
}

.dash-sidebar-footer {
    padding: 16px;
    /* #204: no iPhone (PWA/notch) o home-indicator cobre a base — garante que o Sair fique
       acima dele. flex-shrink:0 impede o footer de ser espremido quando a nav é longa. */
    padding-bottom: max(16px, env(safe-area-inset-bottom, 16px));
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    flex-shrink: 0;
}

.dash-logout-link {
    margin-top: 8px;
    color: rgba(255, 255, 255, 0.6) !important;
    font-size: 13px !important;
}

.dash-logout-link:hover {
    color: #fff !important;
    background: rgba(180, 35, 24, 0.35);
}

.dash-user-info {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border-radius: var(--radius-md);
    transition: background 0.2s var(--ease-smooth);
}

.dash-user-info:hover {
    background: rgba(255, 255, 255, 0.06);
}

.dash-user-avatar {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-md);
    background: var(--brand-gold);          /* #548: avatar = ponto de luz da sidebar */
    color: var(--night-900);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 20px;
}

.dash-user-details {
    flex: 1;
    min-width: 0;
}

.dash-user-name {
    font-size: 14px;
    font-weight: 600;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.dash-user-email {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.6);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ========================================
   MAIN CONTENT
   ======================================== */
.dash-main {
    margin-left: 260px;
    min-height: 100vh;
}

.dash-header {
    position: sticky;
    top: 0;
    background: #ffffff;                 /* #296: mesmo tratamento do bottom-nav — sem backdrop-filter (drift no iOS) */
    border-bottom: 1px solid var(--line);
    padding: 18px 32px;
    padding-top: max(18px, env(safe-area-inset-top, 18px));
    display: flex;
    align-items: center;
    justify-content: space-between;
    z-index: 50;
}

.dash-header-left {
    display: flex;
    align-items: center;
    gap: 16px;
}

.dash-mobile-toggle {
    display: none;
    width: 44px;
    height: 44px;
    border: none;
    background: none;
    cursor: pointer;
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    font-size: 20px;
    transition: all 0.2s var(--ease-smooth);
}

.dash-mobile-toggle:hover {
    background: rgba(45, 74, 124, 0.06);
    color: var(--brand-blue);
}

.dash-page-title {
    font-family: 'Poppins', 'Poppins Fallback', sans-serif;
    font-size: 20px;
    font-weight: 700;
    color: var(--text-primary);
}

.dash-header-right {
    display: flex;
    align-items: center;
    gap: 8px;
}

.dash-header-btn {
    width: 44px;
    height: 44px;
    border: none;
    background: none;
    cursor: pointer;
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    font-size: 18px;
    position: relative;
    transition: all 0.2s var(--ease-smooth);
}

.dash-header-btn:hover {
    background: rgba(45, 74, 124, 0.06);
    color: var(--brand-blue);
}

.dash-content {
    padding: 28px 32px;
}

/* ========================================
   WELCOME BANNER
   ======================================== */
.dash-welcome {
    background: var(--night-bg);          /* #548 F1-5: hero do app = azul-noite com luz (manifesto) */ background-color: #0B1428; /* fallback sólido: se o token --night-bg não chegar (CSS de tokens antigo em cache/PWA, caso Firefox da cliente do Alex 29/09), a superfície continua azul-noite em vez de branco com texto branco */
    border-radius: var(--radius-xl);
    padding: 36px;
    margin-bottom: 28px;
    color: white;
    position: relative;
    overflow: hidden;
    box-shadow: 0 20px 50px rgba(7, 14, 29, 0.18);
}

.dash-welcome::before {
    content: '';
    position: absolute;
    top: -60%;
    right: -15%;
    width: 380px;
    height: 380px;
    background: radial-gradient(circle, rgba(232, 195, 106, 0.12) 0%, transparent 70%);   /* luz sutil: acima de ~.15 vira mancha oliva sobre a noite */
    border-radius: 50%;
}

.dash-welcome::after {
    content: '';
    position: absolute;
    bottom: -40%;
    left: -10%;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.05) 0%, transparent 70%);
    border-radius: 50%;
}

.dash-welcome-content {
    position: relative;
    z-index: 1;
}

.dash-welcome h2 {
    font-family: var(--font-display);     /* #548: título display condensado, estilo capa */
    font-size: clamp(32px, 4vw, 48px);
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: -0.01em;
    line-height: 0.95;
    margin-bottom: 10px;
}

.dash-welcome p {
    font-size: 16px;
    color: rgba(255, 255, 255, 0.82);
    max-width: 520px;
}

/* ========================================
   AGENTS GRID
   ======================================== */
.agents-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
}

.agent-card {
    background: var(--paper);
    border: 1px solid var(--line);          /* #548 F1-4: papel + linha fria + sombra noite no hover */
    border-radius: var(--radius-lg);
    padding: var(--card-pad, 20px);
    cursor: pointer;
    transition: all 0.3s var(--ease-smooth);
    position: relative;
    overflow: hidden;
    /* #97: card virou <a href> (acessível por teclado) — preserva cores internas + tira sublinhado */
    display: block;
    text-decoration: none;
    color: inherit;
}
.agent-card:focus-visible { outline: 2px solid var(--brand-blue); outline-offset: 2px; }

/* #97: botão "Adm 4Brand" (era style inline na view) */
.dash-adm-btn { position: absolute; top: 16px; right: 24px; padding: 8px 18px; min-height: 44px; /* #514: era 37px (top 20→16 compensa os 7px a mais, centro visual igual) */ background: transparent; color: #fff; border: 2px solid rgba(255,255,255,.7); border-radius: var(--radius-pill); font-size: 13px; font-weight: 600; text-decoration: none; display: inline-flex; align-items: center; gap: 8px; z-index: 2; transition: background .18s, color .18s; } /* #548: secundário sobre escuro (o dourado fica pro CTA principal) */
.dash-adm-btn:hover { background: #fff; color: var(--brand-blue); }

.agent-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 6px;
    background: linear-gradient(90deg, var(--agent-color, var(--brand-blue)), var(--brand-gold));
    clip-path: polygon(0 0, 100% 0, 100% 100%, 0 60%);   /* #548: corte no ângulo da seta */
    opacity: 0;
    transition: opacity 0.3s var(--ease-smooth);
}

.agent-card:hover {
    border-color: var(--blue-300);
    box-shadow: var(--shadow-night);
    transform: translateY(-3px);
}

.agent-card:hover::before {
    opacity: 1;
}

.agent-card:active {
    transform: translateY(-1px);
    transition-duration: 0.1s;
}

.agent-header {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    margin-bottom: 14px;
}

.agent-icon {
    width: 46px;
    height: 46px;
    border-radius: var(--radius-md);
    background: var(--agent-bg, rgba(45, 74, 124, 0.08));
    color: var(--agent-color, var(--brand-blue));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 19px;
    flex-shrink: 0;
    transition: transform 0.3s var(--ease-bounce);
}

.agent-card:hover .agent-icon {
    transform: scale(1.08);
}

.agent-info {
    flex: 1;
    min-width: 0;
}

.agent-name {
    font-family: 'Poppins', 'Poppins Fallback', sans-serif;
    font-size: 15px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 2px;
}

.agent-category {
    font-size: 12px;
    color: var(--text-light);
}

.agent-description {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.55;
    margin-bottom: 16px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.agent-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.agent-status {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: var(--text-light);
}

.agent-status-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--brand-green-soft);   /* #548 F1-7: verde da casa */
    box-shadow: 0 0 6px rgba(15, 157, 107, 0.4);
}

/* #385 (achado Paulo, 18/08): FREE via "Disponível" e caía no paywall ao clicar — inconsistente
   com o cadeado elegante já usado em vídeo/música (planAllowsMedia). Mesma linguagem visual aqui:
   card nunca some, badge de cadeado dourado no lugar de "Disponível" pra quem não é Pro. */
.agent-status.locked {
    color: var(--brand-gold-ink, #8a6a1f);
    font-weight: 600;
}

.agent-status.locked .agent-status-dot {
    display: none;
}

.agent-action {
    font-size: 13px;
    font-weight: 600;
    color: var(--brand-blue);
    display: flex;
    align-items: center;
    gap: 6px;
    opacity: 0;
    transform: translateX(-8px);
    transition: all 0.3s var(--ease-smooth);
}

.agent-card:hover .agent-action {
    opacity: 1;
    transform: translateX(0);
}

/* ========================================
   BOTTOM NAV (Mobile App Feel)
   ======================================== */
.dash-bottom-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #ffffff;                 /* #296: opaco elimina o bug do backdrop-filter no iOS (barra flutuava no meio) */
    -webkit-transform: translateZ(0);    /* promove a barra a uma layer estável (reforço anti-drift no iOS) */
    transform: translateZ(0);
    /* backdrop-filter removido de propósito (#296) — combo fixed+blur trava a barra num offset antigo no iOS Safari/PWA */
    border-top: 1px solid var(--border-color);
    z-index: 200;
    padding: 6px 0;
    padding-bottom: max(6px, env(safe-area-inset-bottom));
}

.dash-bottom-nav-inner {
    display: flex;
    justify-content: space-around;
    max-width: 400px;
    margin: 0 auto;
}

.dash-bottom-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    padding: 6px 16px;
    text-decoration: none;
    color: var(--text-light);
    font-size: 10px;
    font-weight: 500;
    border-radius: var(--radius-md);
    transition: color 0.2s;
}

.dash-bottom-link i {
    font-size: 20px;
}

.dash-bottom-link.active {
    color: var(--brand-blue);
    font-weight: 600;
}
.dash-bottom-link.active i { color: var(--brand-gold); }   /* #548: ícone ativo dourado (energia) */

.dash-bottom-link:active {
    background: rgba(45, 74, 124, 0.06);
}

/* ========================================
   MOBILE RESPONSIVE
   ======================================== */
@media (max-width: 1024px) {
    .dash-sidebar {
        transform: translateX(-100%);
        z-index: 210;   /* #842: menu aberto fica acima da barra inferior (200) — antes ela cobria o rodapé e o "Sair" */
    }

    .dash-sidebar.open {
        transform: translateX(0);
    }

    .dash-main {
        margin-left: 0;
    }

    .dash-mobile-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .dash-overlay {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(7, 14, 29, 0.55);   /* #548: véu noite */
        backdrop-filter: blur(2px);
        z-index: 205;   /* #842: o véu cobre também a barra inferior; tocar nela fecha o menu */
    }

    /* #970: com o menu aberto, ele e o véu ficam acima da barra de cookies (1050), abaixo dos alertas (SweetAlert 1060) */
    .dash-sidebar.open { z-index: 1052; }
    .dash-overlay.show { z-index: 1051; }

    .dash-overlay.show {
        display: block;
    }

    /* Show bottom nav on tablet/mobile */
    .dash-bottom-nav {
        display: block;
    }

    .dash-main {
        /* #224: reserva a altura da barra fixa + a safe-area do iPhone (home indicator),
           senão o último conteúdo fica atrás da barra em telas com notch. Base 80px (folga
           extra p/ variação de rótulo/idioma na barra). */
        padding-bottom: calc(80px + env(safe-area-inset-bottom, 0px));
    }
}

@media (max-width: 768px) {
    .dash-content {
        padding: 20px;
    }

    .dash-header {
        padding: 14px 20px;
        /* #173: o shorthand acima zera o padding-top do safe-area — reaplica p/ o botão não
           ficar sob o relógio/notch no PWA iOS (status bar black-translucent). */
        padding-top: max(14px, env(safe-area-inset-top, 14px));
    }

    .dash-welcome {
        padding: 24px;
        border-radius: var(--radius-lg);
    }

    .dash-welcome h2 {
        font-size: 30px;   /* #548: display condensado (era 20 em Poppins) */
    }

    /* #148: sem override de 1 coluna aqui — o auto-fill minmax(280px,1fr) do
       .agents-grid base já dá 2 colunas no tablet (~561-900px) e 1 abaixo de ~576px. */

    .dash-sidebar {
        width: 240px;
    }
}

@media (max-width: 480px) {
    .dash-page-title {
        font-size: 17px;
    }

    .dash-content {
        padding: 16px;
    }

    .dash-welcome {
        padding: 20px;
    }

    .dash-welcome h2 {
        font-size: 28px;   /* #548: display condensado (era 18 em Poppins) */
    }

    .agents-grid {
        gap: 12px;
    }

    .agent-card {
        padding: 20px;
    }
}

/* ===== First-run de ativação (chamado #67) — 0 marcas ===== */
/* #548 F1-4: 1ª tela do usuário novo = impacto (azul-noite com luz, título display, CTA dourado) */
.firstrun {
    max-width: 560px;
    margin: 8px auto 0;
    text-align: center;
    background: var(--night-bg); background-color: #0B1428; /* fallback sólido: se o token --night-bg não chegar (CSS de tokens antigo em cache/PWA, caso Firefox da cliente do Alex 29/09), a superfície continua azul-noite em vez de branco com texto branco */
    color: #fff;
    border: 0;
    border-radius: var(--radius-xl);
    padding: 48px 32px;
    box-shadow: 0 20px 50px rgba(7, 14, 29, 0.25);
    animation: firstrunIn 0.5s var(--ease-smooth);
    position: relative;
    overflow: hidden;
}
@keyframes firstrunIn {
    from { opacity: 0; transform: translateY(12px); }
    to   { opacity: 1; transform: none; }
}
.firstrun-icon {
    width: 76px;
    height: 76px;
    margin: 0 auto 20px;
    border-radius: 50%;
    background: var(--brand-gold);
    color: var(--night-900);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    box-shadow: var(--glow-gold);
}
.firstrun-title {
    font-family: var(--font-display);
    font-size: clamp(30px, 5vw, 44px);
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: -0.01em;
    color: #fff;
    margin-bottom: 10px;
    line-height: 0.95;
}
.firstrun-sub {
    font-size: 15px;
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.55;
    max-width: 420px;
    margin: 0 auto 26px;
}
.firstrun .firstrun-btn-secondary { color: #fff; border-color: rgba(255, 255, 255, 0.7); }
.firstrun .firstrun-btn-secondary:hover { background: #fff; color: var(--brand-blue); }
.firstrun-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-width: 340px;
    margin: 0 auto;
}
/* #548 F1: mesma linguagem do .btn-4b (pill, dourado primário, contorno azul secundário) */
.firstrun-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    padding: 12px 22px;
    min-height: 48px;
    border: 2px solid transparent;
    border-radius: var(--radius-pill);
    font-weight: 700;
    font-size: 15px;
    text-decoration: none;
    transition: transform 0.18s var(--ease-out), box-shadow 0.18s var(--ease-out), background 0.18s, color 0.18s;
}
.firstrun-btn-primary {
    background: var(--brand-gold);
    color: var(--night-900);
    box-shadow: var(--glow-gold);
}
.firstrun-btn-primary:hover {
    background: var(--gold-400);
    transform: translateY(-2px);
    box-shadow: 0 12px 32px rgba(212, 168, 75, 0.45);
}
.firstrun-btn-secondary {
    background: transparent;
    color: var(--brand-blue);
    border-color: var(--brand-blue);
}
.firstrun-btn-secondary:hover {
    background: var(--brand-blue);
    color: #fff;
}
.firstrun-hint {
    font-size: 12.5px;
    color: rgba(255, 255, 255, 0.6);
    margin-top: 18px;
}

/* Badge "Comece por aqui" no card de Posicionamento (>=1 marca) */
.agent-card-start {
    border-color: var(--brand-gold);
    box-shadow: 0 8px 22px rgba(212, 168, 75, 0.18);
}
.start-here-badge {
    /* #224: era position:absolute → sobrepunha o título do agente (nome longo alcança o canto).
       Agora fica no fluxo, como um rótulo acima do card — nunca sobrepõe, em qualquer largura. */
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin: 0 0 12px 0;
    background: var(--brand-gold);
    color: var(--night-900);          /* #548 F1-7: texto noite sobre dourado (branco não passava AA) */
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .04em;
    text-transform: uppercase;
    height: 24px;
    padding: 0 10px;
    border-radius: 7px;
    box-shadow: 0 3px 10px rgba(212, 168, 75, 0.35);
}
.start-here-badge i { font-size: 10px; }

@media (max-width: 480px) {
    /* #511 (L3, item 3): no celular o CTA "Criar minha marca" caía atrás do banner de cookies no
       1º paint (y 697–749 contra banner a partir de 628 em 390×844). Card mais compacto SÓ aqui
       (ícone 56, respiros menores) pra ação principal ficar acima do banner sem rolar — em
       390×844 e também no 375×667. Nada muda no desktop. */
    .dash-welcome { margin-bottom: 20px; }   /* mesmo respiro do padding 16 do .dash-content nesta faixa */
    .firstrun { padding: 28px 20px; }
    .firstrun-icon { width: 56px; height: 56px; font-size: 24px; margin-bottom: 14px; }
    .firstrun-title { font-size: 28px; }   /* #548: display condensado precisa de corpo maior que o Poppins de antes (19) */
    .firstrun-sub { margin-bottom: 20px; }
    .firstrun-actions { gap: 10px; }
}

/* #154: entrada em stagger dos cards de agente (momento "uau" ao logar).
   fill-mode 'backwards' (não 'both'): aplica o estado inicial durante o delay,
   mas reverte ao normal depois — assim o transform do :hover volta a funcionar
   (com 'both' o transform:none retido venceria o hover). */
@keyframes agentCardIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.agent-card { animation: agentCardIn .35s cubic-bezier(.22,.61,.36,1) backwards; }
.agents-grid .agent-card:nth-child(1) { animation-delay: .03s; }
.agents-grid .agent-card:nth-child(2) { animation-delay: .06s; }
.agents-grid .agent-card:nth-child(3) { animation-delay: .09s; }
.agents-grid .agent-card:nth-child(4) { animation-delay: .12s; }
.agents-grid .agent-card:nth-child(5) { animation-delay: .15s; }
.agents-grid .agent-card:nth-child(6) { animation-delay: .18s; }
.agents-grid .agent-card:nth-child(n+7) { animation-delay: .21s; }
@media (prefers-reduced-motion: reduce) { .agent-card { animation: none; } }

/* #1065: saldo de créditos no topo (components/credits_chip.php) */
.crc{display:inline-flex;align-items:center;gap:6px;min-height:44px;min-width:44px;box-sizing:border-box;padding:0 12px;border-radius:999px;background:#F1F4FA;color:var(--brand-blue,#2D4A7C);font:700 14px/1 var(--font-body,Inter,sans-serif);font-variant-numeric:tabular-nums;text-decoration:none;position:relative;white-space:nowrap}
.crc i{font-size:13px;color:#B8892B}
.crc:hover{background:#E6EBF5;color:var(--brand-blue,#2D4A7C)}
.crc:focus-visible{outline:2px solid var(--brand-blue,#2D4A7C);outline-offset:2px}
.crc-warn::after{content:"";position:absolute;top:8px;right:6px;width:8px;height:8px;border-radius:50%;background:#D4A84B;box-shadow:0 0 0 2px #fff}
@media (max-width:360px){.crc{padding:0 8px;gap:4px;font-size:13px}.crc i{font-size:12px}}
