/* =========================
   site.css (Overrides)
   - Carregar DEPOIS do Bootswatch Lux
   - Mant�m identidade Afetiva
   ========================= */

/* Tokens do tema */
:root {
    --af-green: #539778; /* cor principal */
    --af-green-dark: #3f7b66; /* hover */
    --af-bg: #eef3ff; /* fundo claro azulado */
    --af-border: #e7edf5; /* bordas suaves */
    --af-focus: rgba(83,151,120,.35);
    --af-text-muted: #5b6b7a;
    --af-hover: #f6f9ff;
    --af-blue: #2f7dd1; /* profissional, no calendário de aniversariantes */
}

/* Base do template MVC */
html {
    font-size: 14px;
    position: relative;
    min-height: 100%;
}

@media (min-width: 768px) {
    html {
        font-size: 16px;
    }
}

body {
    background: var(--af-bg);
    margin-bottom: 60px; /* mant�m padr�o do template */
}

/* Tipografia (o Lux j� importa Nunito Sans; aqui � s� refor�o opcional) */
/* body{ font-family: "Nunito Sans", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif; } */

/* =========================
   FOCUS / Acessibilidade
   ========================= */
.btn:focus, .btn:active:focus,
.btn-link.nav-link:focus,
.form-control:focus, .form-select:focus,
.form-check-input:focus,
textarea:focus {
    box-shadow: 0 0 0 0.1rem #fff, 0 0 0 0.25rem var(--af-focus);
    border-color: var(--af-green);
}

/* =========================
   Bot�es (pill)
   ========================= */
.btn {
    border-radius: 999px;
}

/* Primary do tema */
.btn-primary {
    background-color: var(--af-green) !important;
    border-color: var(--af-green) !important;
    color: #fff !important;
    padding-left: 1.25rem;
    padding-right: 1.25rem;
}

    .btn-primary:hover,
    .btn-primary:active {
        background-color: var(--af-green-dark) !important;
        border-color: var(--af-green-dark) !important;
        color: #fff !important;
    }

/* Outline Primary (ex.: Voltar) */
.btn-outline-primary {
    color: var(--af-green) !important;
    border-color: var(--af-green) !important;
}

    .btn-outline-primary:hover,
    .btn-outline-primary:active {
        background-color: var(--af-green) !important;
        border-color: var(--af-green) !important;
        color: #fff !important;
    }

/* Links com cara do tema */
a {
    color: var(--af-green);
}

    a:hover {
        color: var(--af-green-dark);
    }

/* =========================
   Cards / pain�is
   ========================= */
.card {
    background: #fff;
    border: 1px solid var(--af-border);
    border-radius: 14px;
    box-shadow: 0 8px 18px rgba(0,0,0,.04);
}

.card-header {
    background: #fff;
    border-bottom: 1px solid var(--af-border);
}

/* =========================
   Form controls
   ========================= */
.form-control, .form-select, textarea {
    border-radius: 10px;
}

    .form-control::placeholder,
    textarea::placeholder {
        color: #9aa7b3;
    }

/* =========================
   Utilit�rios (pra usar nas Views)
   ========================= */
.bg-theme {
    background: var(--af-green) !important;
}

.text-theme {
    color: var(--af-green) !important;
}

.border-theme {
    border-color: var(--af-green) !important;
}

.bg-soft {
    background: #fff !important;
}

.border-soft {
    border-color: var(--af-border) !important;
}

/* =========================
   Layout: Sidebar (padronizado com list-group)
   Use:
   <aside class="af-sidebar"> ... </aside>
   ========================= */
.af-sidebar {
    background: #fff;
    border-right: 1px solid var(--af-border);
}

    /* Itens do menu usando list-group-item */
    .af-sidebar .list-group {
        --bs-list-group-bg: transparent;
        --bs-list-group-border-color: transparent;
    }

    .af-sidebar .list-group-item {
        padding: .85rem 1rem;
        color: var(--af-text-muted);
        border: 0;
        border-radius: 10px;
        margin: 2px 8px;
        background: transparent;
    }

        .af-sidebar .list-group-item:hover {
            background: var(--af-hover);
        }

        .af-sidebar .list-group-item.active {
            background: transparent;
            color: var(--af-green);
            font-weight: 600;
        }

    /* Se voc� preferir usar nav-link em vez de list-group-item, isso d� suporte tamb�m */
    .af-sidebar .nav-link {
        color: var(--af-text-muted);
        border-radius: 10px;
        margin: 2px 8px;
    }

        .af-sidebar .nav-link:hover {
            background: var(--af-hover);
        }

        .af-sidebar .nav-link.active {
            color: var(--af-green);
            font-weight: 600;
        }

/* =========================
   Tabelas (visual limpo)
   ========================= */
.table {
    background: #fff;
}

    .table thead th {
        border-bottom: 1px solid var(--af-border);
    }

    .table td, .table th {
        vertical-align: middle;
    }

/* =========================
   Toast (sucesso com verde forte)
   (caso voc� use Bootstrap Toast)
   ========================= */
.toast.bg-success {
    background-color: var(--af-green-dark) !important;
}


/* ===== User Pill (sempre com borda verde) ===== */

.af-user-pill {
    /* for�a visual mesmo com Lux */
    background-color: #fff !important;
    border: 1px solid var(--af-green) !important;
    border-radius: 999px !important;
    padding: 10px 14px !important;
    box-shadow: none !important;
}

    /* hover suave */
    .af-user-pill:hover {
        background-color: #f6f9ff !important;
    }

    /* foco (clicar) com glow verde */
    .af-user-pill:focus,
    .af-user-pill:active,
    .af-user-pill.show {
        border-color: var(--af-green) !important;
        box-shadow: 0 0 0 0.12rem #fff, 0 0 0 0.28rem var(--af-focus) !important;
    }

/* �cone do usu�rio */
.af-user-icon {
    font-size: 22px;
    color: #334155;
    opacity: .9;
}

/* nome e email mais �secos� como no original */
.af-user-name {
    font-weight: 600;
    letter-spacing: .02em;
    color: #1f2937;
    line-height: 1.05;
}

.af-user-email {
    font-size: .85rem;
    color: #6b7280;
    line-height: 1.05;
}

/* seta da direita */
.af-user-caret {
    color: #374151;
    opacity: .85;
}

/* dropdown do menu */
.dropdown-menu {
    border-radius: 12px;
    border: 1px solid var(--af-border);
    padding: .35rem;
}

.dropdown-item {
    border-radius: 10px;
}

/* User pill - tuning fino (igual ao print) */
.af-user-name {
    font-size: 18px;
    text-transform: uppercase;
    line-height: 1.1;
}

.af-user-email {
    font-size: 14px;
    text-transform: uppercase;
    line-height: 1.1;
    max-width: 140px; /* for�a o "..." parecido */
}

/* Badge de contador no menu (ex.: total de atendimentos do dia) */
.af-badge-contador {
    background-color: var(--af-bg) !important;
    color: var(--af-text-muted) !important;
    font-weight: 600;
    padding: .4em .75em;
}

/* =========================
   Calendário de Aniversariantes
   ========================= */
.af-calendario-aniversariantes td {
    vertical-align: top;
    height: 110px;
    width: 14.28%;
    padding: 6px;
}

.af-dia-fora-mes {
    background: #f1f3f5;
}

.af-dia-hoje {
    background: #fff8e1;
}

.af-dia-numero {
    font-size: .8rem;
    color: var(--af-text-muted);
    text-align: right;
    margin-bottom: 4px;
}

.af-aniversariante-badge {
    font-size: .75rem;
    color: #fff;
    padding: 2px 6px;
    border-radius: 4px;
    margin-bottom: 3px;
    overflow-wrap: break-word;
}

.af-badge-paciente {
    background: var(--af-green);
}

.af-badge-profissional {
    background: var(--af-blue);
}

#tblLancamentos td.text-truncate-col {
    max-width: 1px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
/* Selo "Em andamento" em Meus Documentos: bg-secondary do tema sai quase branco e some no fundo. */
.badge-em-andamento {
    background-color: var(--af-blue) !important;
    color: #fff !important;
}
