.texto-google-sans {
    font-family: "Open Sans", sans-serif;
    /* Sugiro usar Open Sans se não tiver a Google Sans */
    font-family: 'Inter', "Google Sans", sans-serif;
    /* Inter é mais moderna para UI */
    font-optical-sizing: auto;
    font-weight: 400;
    /* 400 é o peso normal */
    font-style: normal;
    font-variation-settings: "GRAD" 0;
}

:root {
    /* Design System */

    /* Cores Principais (Sóbrias) */
    --color-primary: #0f172a;
    /* Texto principal / Títulos (Slate 900) */
    --color-accent: #017DD3;
    /* Ações / Links / Brand */
    --color-success: #10b981;
    --color-warning: #f59e0b;
    --color-danger: #ef4444;
    --color-with: #fff;


    /* Superfícies e Fundos */
    --bg-body: #f9f9f9;
    /* Fundo geral mais limpo (Slate 50) */
    --bg-surface: #ffffff;
    /* Cards e Containers */
    --bg-subtle: #f1f5f9;
    /* Elementos secundários */

    /* Texto e Bordas */
    --text-main: #334155;
    /* Slate 700 */
    --text-muted: #64748b;
    /* Slate 500 */
    --border-color: #ebebeb;
    /* Slate 200 */

    /* Sombras e Raios (Soft UI) */
    --radius-md: 12px;
    --radius-lg: 22px;
    --radius-xl: 50px;
    --shadow-soft: 0 4px 20px rgba(0, 0, 0, 0.03);
    --shadow-hover: 0 10px 25px rgba(0, 0, 0, 0.06);

    /* Bootstrap Overrides (Mapeamento para o Sistema) */
    --bs-primary: var(--color-accent);
    --bg-primary: var(--color-accent);
    --bs-body-color: var(--text-main);
    --bs-body-bg: var(--bg-body);
    --bs-border-color: var(--border-color);
    --bs-link-color: var(--color-accent);

}

.radius-lg {
    border-radius: var(--radius-lg);
}

.border-2px {
    border: 2px solid var(--border-color);
}

body {
    background-color: var(--bs-body-bg);
    font-family: 'Inter', 'Google Sans', sans-serif;
    color: var(--text-main);
    -webkit-font-smoothing: antialiased;
    /* Texto mais nítido */
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.container-fluid {
    flex-grow: 1;
}

footer,
.footer {
    flex-shrink: 0;
    margin-top: auto;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    color: var(--color-primary);
    font-weight: 600;
    letter-spacing: -0.02em;
}

.btn-check:checked+.btn,
.btn.active,
.btn.show,
.btn:first-child:active,
:not(.btn-check)+.btn:active {
    color: var(--bs-btn-active-color);
    background-color: #017dd3;
    border-color: #017dd3;
}

.btn:hover {
    color: var(--color-with);
    background-color: var(--color-accent);
    border-color: var(--bs-btn-hover-border-color);
}


.dropdown-menu {
    border-radius: 15px;
    border: none;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    z-index: 5001;
    background: #ffffff;
}

.dropdown-item:active {
    background-color: var(--primary-color);
}

.fw-500 {
    font-weight: 500;
}



/* Sino de Notificações */
.nav-link i.bi-bell {
    transition: color 0.3s;
}

.nav-link:hover i.bi-bell {
    color: var(--primary-color) !important;
}

/* Ajuste das Migalhas (Breadcrumbs) */
.breadcrumb-item+.breadcrumb-item::before {
    color: #555 !important;
    content: "\F285";
    /* Ícone de seta do Bootstrap Icons */
    font-family: "bootstrap-icons";
    font-size: 1rem;
    vertical-align: middle;
}

.breadcrumb-fontsize {
    font-size: 18px;
    font-weight: 400;
}

/* Estilo das Abas de Navegação Inferiores */
.nav-tabs .nav-link {
    font-size: 14px;
    white-space: nowrap;
    transition: all 0.2s ease;
    font-weight: 500;
}

.nav-tabs .nav-link:hover {
    background: none;
    color: #017dd3 !important;
}

.nav-tabs .nav-link.active {
    border-bottom: 3px solid #017dd3 !important;
}

/* Ajuste fino nos Breadcrumbs */
.breadcrumb-item+.breadcrumb-item::before {
    color: #dee2e6;
}

/* Ajuste para as abas não quebrarem em telas pequenas quando fixas */
.nav-tabs {
    scrollbar-width: none;
    /* Esconde scrollbar no Firefox */
}

.nav-tabs::-webkit-scrollbar {
    display: none;
    /* Esconde scrollbar no Chrome/Safari */
}

.texto-aviso {
    font-size: 11px;
    margin-top: 10px;
    float: left;
    padding: 0;
}

/* Efeito de suavidade e transição */
.transition-all {
    transition: all 0.3s ease;
}

/* Efeito de flutuar ao passar o mouse */
.hover-shadow:hover {
    transform: translateY(-5px);
    box-shadow: 0 1rem 3rem rgba(0, 0, 0, .175) !important;
}

/* Garante que o cabeçalho não quebre em nomes longos */
.text-truncate {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Divisor lateral apenas no computador */
@media (min-width: 768px) {
    .border-end-md {
        border-right: 1px solid #eee !important;
    }

    .text-center-md {
        text-align: center;
    }
}

/* Força o texto a quebrar linha e exibir completo */
/* --- CORREÇÃO: QUEBRA DE LINHA NOS EVENTOS --- */

/* 1. Força o texto a quebrar linha e aparecer completo */
.fc-event-title {
    white-space: normal !important;
    /* Permite quebra de linha */
    overflow: visible !important;
    /* Mostra o texto excedente */
    text-overflow: clip !important;
    /* Remove os '...' */
    line-height: 1.2 !important;
    /* Espaçamento entre linhas mais compacto */
}

/* 2. Ajusta o container do evento para crescer verticalmente */
.fc-daygrid-event {
    white-space: normal !important;
    height: auto !important;
    /* Altura automática baseada no texto */
    align-items: flex-start !important;
    padding-top: 4px !important;
    padding-bottom: 4px !important;
}

/* 3. (Opcional) Ajuste fino na fonte para caber mais texto */
.fc-event {
    font-size: 0.7rem !important;
    /* Fonte um pouquinho menor ajuda */
}

/* --- FULLCALENDAR MOBILE OPTIMIZATION --- */
@media (max-width: 768px) {
    .fc-header-toolbar {
        flex-direction: column;
        gap: 10px;
        align-items: stretch !important;
    }

    .fc-toolbar-chunk {
        display: flex;
        justify-content: center;
        justify-content: space-between;
        width: 100%;
        gap: 8px;
    }

    /* Move o título para o topo e centraliza */
    .fc-toolbar-chunk:nth-child(2) {
        order: -1;
        justify-content: center;
        margin-bottom: 5px;
    }

    .fc .fc-button {
        font-size: 0.8em;
        padding: 0.4em 0.8em;
        font-size: 0.75rem !important;
        padding: 0.6rem 0.5rem !important;
        flex: 1;
        /* Botões expandem para facilitar o toque */
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .fc-button-group {
        width: 100%;
    }

    .fc-toolbar-title {
        font-size: 1.25rem !important;
    }

    /* Ajuste de fonte para eventos no mobile */
    .fc-event {
        font-size: 0.7rem !important;
    }

    /* Melhoria na Visualização de Lista (Mobile) */
    .fc-list-event-title {
        white-space: normal !important;
        /* Permite quebra de linha */
        font-weight: 600 !important;
    }

    .fc-list-day-cushion {
        background-color: #f8f9fa !important;
        /* Fundo suave nos dias */
    }
}

.btn-white {
    background: #fff;
    border: 1px solid #dee2e6;
    color: #6c757d;
}

/* Remove sombras internas ou barras no hover da tabela */
.table-premium tr {
    transition: all 0.2s ease;
    border-left: 5px solid transparent;
    /* Reserva o espaço para a borda lateral */
}

.table-premium tbody tr:hover {
    background-color: rgba(0, 0, 0, 0.01) !important;
    /* Fundo quase imperceptível */
    box-shadow: none !important;
    /* Remove qualquer sombra que pareça uma barra */
}

/* Garante que os cards de resumo sigam o padrão de Produção */
.card-stat-premium {
    border-radius: 20px !important;
    border: none !important;
    background: #ffffff;
    transition: transform 0.3s ease;
}

.card-stat-premium:hover {
    transform: translateY(-5px);
}

.timeline-item.active .timeline-dot {
    background: #017dd3;
    box-shadow: 0 0 0 3px rgba(13, 110, 253, 0.2);
}

/* --- HEADER & NAVIGATION --- */
.main-header {
    position: sticky;
    top: 0;
    z-index: 5000;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

/* Garante que a barra de abas fique abaixo do header para não cobrir o dropdown */
nav.bg-white:not(.main-header) {
    position: relative;
    z-index: 1000;
}

.nav-tabs-custom {
    border-bottom: none;
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.nav-tabs-custom::-webkit-scrollbar {
    display: none;
}

.nav-tabs-custom .nav-link {
    border: none;
    color: #6c757d;
    font-weight: 500;
    font-size: 0.9rem;
    padding: 0.8rem 1rem;
    border-bottom: 3px solid transparent;
    transition: all 0.3s ease;
    white-space: nowrap;
    display: inline-block;
    align-items: center;
}

.nav-tabs-custom .nav-link i {
    font-size: 1.1rem;
    margin-right: 6px !important;
}

.nav-tabs-custom .nav-link:hover {
    color: #017dd3;
    background: rgba(13, 110, 253, 0.05);
}

.nav-tabs-custom .nav-link.active {
    color: #017dd3 !important;
    border-bottom-color: #017dd3;
    background: none;
    font-weight: 700;
}

.badge-notif {
    font-size: 0.6rem;
    padding: 0.35em 0.5em;
    top: 5px !important;
}

.text-pro {
    color: #f59e0b !important;
}

.ios-prompt {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 400px;
    background: white;
    padding: 20px;
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    z-index: 9999;
    border: 1px solid #f0f0f0;
    animation: slideUp 0.5s ease-out;
}

.ios-arrow {
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 20px;
    background: white;
    transform: rotate(45deg);
    border-bottom: 1px solid #f0f0f0;
    border-right: 1px solid #f0f0f0;
}

@keyframes slideUp {
    from {
        bottom: -100px;
        opacity: 0;
    }

    to {
        bottom: 30px;
        opacity: 1;
    }
}


/* --- FOOTER --- */
.social-link {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-radius: 50%;
    transition: 0.3s;
    text-decoration: none;
}

.social-link:hover {
    background: var(--bs-primary);
    color: white;
    transform: translateY(-3px);
}

.hover-white:hover {
    color: white !important;
}

/* --- COMPONENTS --- */
/* Remove bordas coloridas laterais antigas */
.border-l-primary,
.border-l-success,
.border-l-danger,
.border-l-warning,
.border-l-info {
    border-left: none !important;
}

/* --- TABLES --- */
.table-admin td {
    vertical-align: middle;
    padding: 15px;
}

.table>:not(caption)>*>* {
    padding: .5rem .5rem;
    color: var(--bs-table-color-state, var(--bs-table-color-type, var(--bs-table-color)));
    background-color: transparent;
    border-bottom-width: var(--bs-border-width);
}

.table-premium th {
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.5px;
    color: #64748b;
    font-weight: 500;
    border-bottom: 2px solid var(--border-color);
}

.table-premium td {
    padding: 8px;
    vertical-align: middle;
    border-bottom: 2px solid #f1f5f9;
    font-size: 0.85rem;
    color: #64748b;
    font-weight: 500;
}

.table-premium tr:hover td {
    background-color: #f8fafc;
}

.bs-i-studio {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
}

/* Classes padronizadas para o gestaode.studio */
.offcanvas-xl {
    width: 600px;
}

.input-studio {
    border: 2px solid var(--border-color) !important;
}

.icon-circle-studio {
    width: 110px;
    height: 110px;
    border: 2px solid var(--border-color);
    background-color: #ffffff;
    cursor: pointer;
}

/* --- PERFIL & FORMS --- */
.card-basico {
    border: none;
    border-radius: 20px;
    background: #fff;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.02);
}

.upgrade-box {
    background: linear-gradient(135deg, #017dd3 0%, #003da1 100%);
    color: white;
    border-radius: 20px;
    padding: 30px;
}

.card-detalhes {
    border: 0;
    border-radius: 1.2rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.03);
    background: #fff;
}

.img-preview-perfil {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 50%;
    border: 4px solid #fff;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
}

.logo-box {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 15px;
    border: 1px dashed #dee2e6;
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.assinatura-box {
    background: #fff;
    border-radius: 10px;
    padding: 10px;
    border: 1px solid #eef0f2;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.assinatura-box img {
    max-height: 100%;
    max-width: 100%;
    object-fit: contain;
}

.swal2-popup {
    font-family: 'Google Sans', sans-serif !important;
    border-radius: 20px !important;
}

.form-switch .form-check-input {
    margin-left: .1em !important;
    margin-right: .5em;
}

.list-group-item.active {
    background-color: #017dd3;
    border-color: #017dd3;
    color: #fff;
}

.list-group-item {
    color: #495057;
    transition: all 0.2s;
}

.list-group-item:hover {
    background-color: #017dd3;
    color: #fff;
}

/* --- EDITAR CLIENTE --- */
.foto-upload-box {
    background: #fff;
    border-radius: 20px;
    padding: 30px 20px;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

.img-edit-preview {
    width: 140px;
    height: 140px;
    object-fit: cover;
    border-radius: 50%;
    border: 5px solid #f8f9fa;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    margin-bottom: 20px;
}

.avatar-edit-preview {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    border: 5px solid #f8f9fa;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: #fff;
    font-weight: bold;
    margin-left: auto;
    margin-right: auto;
}

.financeiro-extra {
    display: none;
}

/* --- CLIENTES LIST --- */
.avatar-initial {
    width: 55px;
    height: 55px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    border-radius: 50%;
    font-size: 1.3rem;
    color: #fff;
}

.avatar-initial-prod {
    width: 55px;
    height: 55px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    border-radius: 50%;
    font-size: 1.3rem;
    color: #000;
}

.avatar-img {
    width: 55px;
    height: 55px;
    object-fit: cover;
    border-radius: 50%;
}

.foto-upload-container {
    text-align: center;
    background: #f8f9fa;
    padding: 15px;
    border-radius: 10px;
    border: 1px dashed #dee2e6;
}

.img-preview-modal {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #fff;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    margin-bottom: 10px;
}

.avatar-preview-modal {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    border: 3px solid #fff;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    color: #fff;
    font-weight: bold;
    margin-left: auto;
    margin-right: auto;
}

/* --- MARKETING --- */
.post-card {
    border-left: 5px solid #adb5bd;
    transition: all 0.2s;
}

.post-agendado {
    border-left-color: #017dd3 !important;
}

.post-publicado {
    border-left-color: #198754 !important;
    opacity: 0.8;
}

/* --- FORM CLIENTE EXTERNO --- */
.card-form {
    border: none;
    border-radius: 24px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    background: #fff;
}

.logo-topo {
    max-height: 40px;
    margin-bottom: 30px;
}

.profile-img-topo {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 50%;
    border: 4px solid #fff;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    background: #fff;
    margin-top: -40px;
}

.btn-enviar {
    border-radius: 50px;
    padding: 14px;
    font-weight: bold;
    letter-spacing: 0.5px;
    font-size: 1rem;
    text-transform: uppercase;
}

.client-photo-wrapper {
    position: relative;
    width: 120px;
    height: 120px;
    margin: 0 auto 15px;
    cursor: pointer;
}

.client-photo-preview {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
    border: 3px solid #e9ecef;
    transition: all 0.3s;
}

.client-photo-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.4);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    opacity: 0;
    transition: opacity 0.3s;
    font-size: 1.5rem;
}

.client-photo-wrapper:hover .client-photo-overlay {
    opacity: 1;
}

/* --- LOGIN & AUTH --- */
.login-card {
    background: white;
    border-radius: 24px;
    padding: 40px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.05);
    width: 100%;
    max-width: 400px;
}

.btn-login {
    border-radius: 50px;
    padding: 12px;
    font-weight: bold;
    background: #017dd3;
    border: none;
    transition: 0.3s;
}

.btn-login:hover {
    background: #0b5ed7;
    transform: translateY(-2px);
}

.card-2fa {
    background: white;
    border-radius: 24px;
    padding: 40px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.05);
    width: 100%;
    max-width: 400px;
    text-align: center;
}

.btn-verify {
    border-radius: 50px;
    padding: 12px;
    font-weight: bold;
    width: 100%;
    margin-top: 20px;
}

.btn-action {
    width: 32px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: 0.2s;
    cursor: pointer;
}

.btn-action:hover {
    transform: scale(1.1);
}

/* --- PORTAL CLIENTE (ACOMPANHAMENTO) --- */
.card-custom {
    border: 0;
    border-radius: 1.2rem;
    background: #fff;
}

.hero-header {
    background-size: cover;
    background-position: center;
    position: relative;
    padding: 80px 0 40px;
    margin-bottom: -40px;
    border-radius: 0 0 30px 30px;
    overflow: hidden;
}

.hero-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    color: white;
}

.hero-content .text-muted {
    color: rgba(255, 255, 255, 0.7) !important;
}

.hero-content .text-dark {
    color: white !important;
}

.main-container {
    position: relative;
    z-index: 3;
    margin-top: 0;
}

.logo-fotografo {
    max-height: 30px;
    width: auto;
    object-fit: contain;
}

.avatar-cliente-lg {
    width: 90px;
    height: 90px;
    object-fit: cover;
    border-radius: 50%;
    border: 4px solid #fff;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
}

.timeline-v {
    position: relative;
    padding-left: 20px;
}

.timeline-v-item {
    position: relative;
    padding-bottom: 25px;
    border-left: 2px solid #e9ecef;
    padding-left: 20px;
}

.timeline-v-item:last-child {
    border-left: 0;
}

.timeline-v-dot {
    position: absolute;
    left: -9px;
    top: 18px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #dee2e6;
    border: 3px solid #fff;
}

.timeline-v-item.active .timeline-v-dot {
    background: #017dd3;
    box-shadow: 0 0 0 3px rgba(13, 110, 253, 0.2);
}

.timeline-v-item.done .timeline-v-dot {
    background: #198754;
}

.timeline-v-item.done {
    border-left-color: #198754;
}

.gallery-preview {
    column-count: 2;
    column-gap: 15px;
}

@media (min-width: 576px) {
    .gallery-preview {
        column-count: 3;
    }
}

@media (min-width: 992px) {
    .gallery-preview {
        column-count: 4;
    }
}

.photo-item {
    break-inside: avoid;
    margin-bottom: 15px;
    border-radius: 8px;
    position: relative;
    cursor: zoom-in;
    border: 3px solid transparent;
    transition: border-color 0.2s;
    background: #f8f9fa;
    -webkit-touch-callout: none;
}

.photo-item.selected {
    border-color: #198754;
}

.photo-item img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 4px;
    -webkit-user-select: none;
    user-select: none;
}

.photo-item::after {
    content: 'EM SELEÇÃO';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(-45deg);
    font-size: 1.2rem;
    font-weight: 900;
    color: rgba(255, 255, 255, 0.6);
    text-shadow: 0 2px 5px rgba(0, 0, 0, 0.8);
    pointer-events: none;
    z-index: 4;
    letter-spacing: 2px;
    white-space: nowrap;
}

#modalLightbox .modal-body::after {
    content: 'EM SELEÇÃO';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(-45deg);
    font-size: 4vw;
    font-weight: 900;
    color: rgba(255, 255, 255, 0.4);
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.8);
    pointer-events: none;
    z-index: 1045;
    letter-spacing: 5px;
    white-space: nowrap;
}

.thumb-select-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 32px;
    height: 32px;
    background: rgba(255, 255, 255, 0.85);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 5;
    transition: 0.2s;
    border: 1px solid rgba(0, 0, 0, 0.1);
    color: #ccc;
}

.photo-item.selected .thumb-select-btn {
    background: #198754;
    color: white;
    border-color: #198754;
}

.thumb-select-btn:hover {
    transform: scale(1.1);
    background: #fff;
    color: #198754;
}

.photo-item.selected .thumb-select-btn:hover {
    background: #157347;
    color: #fff;
}

.sticky-summary {
    position: sticky;
    top: 20px;
}

.form-label-mini {
    font-size: 0.65rem;
    font-weight: 800;
    color: #adb5bd;
    text-transform: uppercase;
    margin-bottom: 3px;
    display: block;
}

.card-project {
    border: none;
    border-radius: 16px;
    overflow: hidden;
    transition: transform 0.2s;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.card-project:hover {
    transform: translateY(-5px);
}

.chat-widget {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1060;
    font-family: 'Google Sans', sans-serif;
}

.chat-btn {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: #017dd3;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    box-shadow: 0 5px 20px rgba(13, 110, 253, 0.3);
    cursor: pointer;
    transition: transform 0.2s;
    position: relative;
}

.chat-btn:hover {
    transform: scale(1.1);
}

.chat-status-dot {
    position: absolute;
    top: 2px;
    right: 2px;
    width: 14px;
    height: 14px;
    background: #ccc;
    border: 2px solid #fff;
    border-radius: 50%;
}

.chat-status-dot.online {
    background: #198754;
}

.chat-window {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 350px;
    height: 450px;
    background: #fff;
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    display: none;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid #f0f0f0;
}

.chat-header {
    background: #017dd3;
    color: white;
    padding: 15px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.chat-body {
    flex: 1;
    padding: 15px;
    overflow-y: auto;
    background: #f8f9fa;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.chat-footer {
    padding: 10px;
    background: #fff;
    border-top: 1px solid #eee;
    display: flex;
    gap: 5px;
}

.msg-bubble {
    max-width: 80%;
    padding: 10px 15px;
    border-radius: 15px;
    font-size: 0.9rem;
    position: relative;
    word-wrap: break-word;
}

.msg-in {
    align-self: flex-start;
    background: #fff;
    border: 1px solid #eee;
    border-bottom-left-radius: 2px;
}

.msg-out {
    align-self: flex-end;
    background: #017dd3;
    color: white;
    border-bottom-right-radius: 2px;
}

.msg-time {
    font-size: 0.65rem;
    opacity: 0.7;
    display: block;
    text-align: right;
    margin-top: 3px;
}

.hover-primary:hover {
    color: #017dd3 !important;
    transform: translateY(-2px);
    transition: 0.2s;
}

.grayscale {
    filter: grayscale(100%);
    transition: 0.3s;
}

.grayscale:hover {
    filter: grayscale(0%);
}


.scroll-container-premium {
    overflow-x: auto;
    overflow-y: hidden;
    white-space: nowrap;
    padding-bottom: 5px;
    /* Evita cortar a sombra do shadow-sm */

    /* Esconde a barra de rolagem no Chrome, Safari e Opera */
    -webkit-overflow-scrolling: touch;
}

.scroll-container-premium::-webkit-scrollbar {
    display: none;
}

/* Esconde a barra de rolagem no IE, Edge e Firefox */
.scroll-container-premium {
    -ms-overflow-style: none;
    /* IE and Edge */
    scrollbar-width: none;
    /* Firefox */
}




.logo-login {
    max-width: 300px;
    height: auto;
    margin-bottom: 10px;
    width: 100%;
}

.card-login {
    border: none;
    border-radius: 25px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.05);
}

.form-control {
    border-radius: 12px;
    background-color: #f8f9fa;
    border: 1px solid #eee;
}

.main-header .dropdown {
    position: relative;
    z-index: 3001;
}




/* Ajuste para permitir scroll horizontal em tabelas no mobile */
@media (max-width: 991px) {
    .table-responsive {
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch;
    }
}

.justify-content-center {
    justify-content: center !important;
    display: flex;
    align-items: center;
    padding: 0;
}

.justify-content-right {
    justify-content: right !important;
    display: flex;
    align-items: center;
    padding: 0;
}

a.social-link {
    align-items: center;
    color: #ffffff;
    font-size: 1.28em;
    opacity: 0.8;
}

/* --- HEADER PREMIUM (CLIENTES) --- */
.header-premium {
    background: var(--bg-surface);
    border-radius: var(--radius-lg);
    padding: 20px 30px;
    margin-bottom: 30px;
    border: 2px solid var(--border-color);
}

.search-premium {
    background: #f8f9fa;
    border: 1px solid #eef0f2;
    border-radius: 50px;
    padding: 8px 20px;
    transition: all 0.3s ease;
    width: 280px;
    max-width: 100%;
    display: flex;
    align-items: center;
}

.search-premium:focus-within {
    background: #fff;
    border-color: #017dd3;
    box-shadow: 0 5px 15px rgba(13, 110, 253, 0.1);
}

.search-premium input {
    border: none;
    background: transparent;
    font-size: 0.95rem;
    padding-left: 10px;
    width: 100%;
    outline: none;
}

.search-premium i {
    color: #adb5bd;
}

@media (max-width: 992px) {
    .search-premium {
        width: 100%;
    }
}

/* --- INDICADOR DE SCROLL HORIZONTAL PARA TABELAS --- */
@media (max-width: 768px) {
    .table-scroll-indicator {
        position: relative;
    }

    .table-scroll-indicator::after {
        content: '';
        position: absolute;
        top: 0;
        right: 0;
        bottom: 0;
        width: 40px;
        /* Largura da sombra */
        background: linear-gradient(to left, rgba(0, 0, 0, 0.05), transparent);
        /* Sombra suave */
        pointer-events: none;
        /* Permite clicar através da sombra */
        z-index: 5;
    }
}

/* --- AUMENTAR LARGURA DO SISTEMA --- */
@media (min-width: 1200px) {
    .container {
        max-width: 1350px;
        /* Aumenta o espaço útil em telas grandes (Padrão ~1140px) */
    }
}

@media (min-width: 1600px) {
    .container {
        max-width: 1600px;
        /* Aproveita melhor monitores grandes (Padrão ~1320px) */
    }
}

/* Specific style for production list view avatar */
.avatar-initial-prod {
    background-color: #e9ecef;
    /* Default light background */
    color: #6c757d;
    /* Default muted text */
}


/* --- ONBOARDING WIZARD --- */
.wizard-steps {
    display: flex;
    justify-content: space-between;
    margin-bottom: 30px;
    position: relative;
}

.wizard-steps::before {
    content: '';
    position: absolute;
    top: 15px;
    left: 0;
    right: 0;
    height: 2px;
    background: #e9ecef;
    z-index: 1;
}

.step-indicator {
    width: 45px;
    height: 45px;
    background: #fff;
    border: 2px solid #e9ecef;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    color: #adb5bd;
    position: relative;
    z-index: 2;
    transition: all 0.3s;
}

.step-indicator.active {
    border-color: #017dd3;
    color: #017dd3;
    background: #fff;
}

.step-indicator.completed {
    background: #017dd3;
    border-color: #017dd3;
    color: #fff;
}

.step-content {
    display: none;
    animation: fadeIn 0.5s;
}

.step-content.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.bg-studio {
    background-color: #017dd3;
}

.style-studio {
    border-radius: 50%;
    background-color: rgb(141 141 141 / 16%);
    padding: 12px;
    line-height: 0;
    color: #4c4b4e;
}

.avatar-cliente-lg {
    width: 110px;
    height: 110px;
    object-fit: cover;
    border-radius: 50%;
    border: 4px solid #fff;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.list-group-studio:first-child {
    border-top-left-radius: 16px;
    border-top-right-radius: 16px;
}

@media (max-width: 576px) {
    .pb-studio {
        padding-bottom: 10px;
    }

    .feature-section {
        padding: 0 0;
    }

    .logo-studio {
        height: 60px;
        position: absolute;
        left: 0;
        top: 7px;
    }
}

.nav-pills .nav-link {
    border-radius: var(--radius-xl);
    color: #64748b;
    font-size: 0.85rem;
    font-weight: 500;
    background-color: #fff;
}

/* Garante que o nav não quebre linha e mantenha o formato de pílula */
/* --- botoes --- */
.nav-pills {
    display: inline-flex !important;
    --bs-nav-pills-link-active-color: #fff !important;
    --bs-nav-pills-link-active-bg: #017dd3 !important;
    --bs-nav-pills-border-radius: var(--bs-border-radius) !important;
    border: 2px solid var(--border-color);
    background: var(--bg-surface);
    border-radius: var(--radius-xl) !important;
    max-width: 100%;
    /* Garante que respeite a largura da tela */
}

/* --- PADRONIZAÇÃO DE SCROLL HORIZONTAL (MIXIN) --- */
@media (max-width: 991px) {

    .nav-pills,
    .nav-pills-clean,
    .btn-scrollable-mobile,
    .d-flex-scrollable {
        display: flex !important;
        flex-wrap: nowrap !important;
        overflow-x: auto !important;
        padding-bottom: 5px;
        /* Espaço para o scroll não cortar a sombra */
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        /* Esconde barra de rolagem visualmente */
    }

    .nav-pills::-webkit-scrollbar,
    .nav-pills-clean::-webkit-scrollbar,
    .btn-scrollable-mobile::-webkit-scrollbar,
    .d-flex-scrollable::-webkit-scrollbar {
        display: none;
    }

    .nav-pills .nav-item,
    .nav-pills-clean .nav-item,
    .btn-scrollable-mobile>*,
    .d-flex-scrollable>* {
        flex: 0 0 auto;
    }

    /* Ajustes específicos */
    .btn-scrollable-mobile {
        justify-content: flex-start !important;
    }

    .d-flex-scrollable {
        gap: 10px;
    }
}

/* Scrollable Pills */
.nav-pills-scrollable {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
    padding-bottom: 5px;
    background: var(--bg-surface);
    border-radius: var(--radius-xl) !important;
    border: 2px solid var(--border-color);
    -webkit-overflow-scrolling: touch;
}

.nav-pills-scrollable::-webkit-scrollbar {
    display: none;
}

.nav-pills-scrollable .nav-item {
    flex: 0 0 auto;
}

.nav-pills-scrollable .nav-link {
    border-radius: var(--radius-xl);
    font-size: 0.85rem;
    font-weight: 500;
    color: #64748b;
    padding: 8px 16px;
    white-space: nowrap;
}

.nav-pills-scrollable .nav-link.active {
    background-color: var(--color-accent);
    color: #fff;
    font-weight: 500;
}

.nav-pills .nav-link.active,
.nav-pills .show>.nav-link {
    color: var(--bs-nav-pills-link-active-color);
    background-color: var(--bs-nav-pills-link-active-bg);
}

/* Tabs Clean (Estilo Dashboard Admin) */
.nav-pills-clean {
    display: inline-flex;
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: 50px;
    padding: 4px;
}

.nav-pills-clean .nav-link {
    border-radius: 50px;
    font-size: 0.85rem;
    padding: 8px 24px;
    color: #64748b;
    font-weight: 500;
    border: none;
    background: transparent;
    transition: all 0.2s;
}

.nav-pills-clean .nav-link:hover {
    color: var(--color-accent);
    background-color: rgba(1, 125, 211, 0.05);
}

.nav-pills-clean .nav-link.active {
    background-color: var(--color-accent);
    color: #fff;
}

.nav-pills-clean::-webkit-scrollbar {
    display: none;
}

/* --- NOVO ESTILO SAAS (HEADER & UI) --- */

/* Navbar Principal */
.navbar-saas {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    padding: 0.75rem 0;
    transition: all 0.3s ease;
}

.navbar-saas .navbar-brand .brand-icon {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, #017dd3 0%, #0056b3 100%);
    color: white;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    box-shadow: 0 4px 10px rgba(1, 125, 211, 0.2);
}

/* Links de Navegação */
.navbar-saas .nav-link {
    color: #64748b;
    font-weight: 500;
    font-size: 0.9rem;
    padding: 0.6rem 1rem !important;
    border-radius: 8px;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 2px;
}

.navbar-saas .nav-link i {
    font-size: 1.1rem;
    color: #94a3b8;
    transition: color 0.2s;
}

.navbar-saas .nav-link:hover {
    background-color: #f1f5f9;
    color: #0f172a;
}

.navbar-saas .nav-link:hover i {
    color: #017dd3;
}

.navbar-saas .nav-link.active {
    background-color: rgba(1, 125, 211, 0.08);
    color: #017dd3;
    font-weight: 600;
}

.navbar-saas .nav-link.active i {
    color: #017dd3;
}

/* Elementos de UI */
.avatar-sm {
    width: 38px;
    height: 38px;
    object-fit: cover;
}

.btn-icon {
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: 0.2s;
}

.btn-icon:hover {
    background: #e2e8f0;
    color: #017dd3;
}

/* Mobile Offcanvas Tweaks */
.offcanvas {
    border-radius: 0 7px 7px 0;
    border: none;
}

.offcanvas-header {
    padding: 1.5rem;
}

.offcanvas-body {
    padding: 1.5rem;
}

.offcanvas-body {
    padding: 1.5rem;
    overflow-y: auto;
    /* Permite scroll vertical se o conteúdo for maior */
    flex-grow: 1;
    /* Garante que o corpo ocupe o espaço restante */
}

.hide-arrow::after {
    display: none !important;
}

/* --- TRANSIÇÕES SUAVES (GLOBAL) --- */
body,
.card,
.navbar,
.sidebar,
.modal-content,
.form-control,
.dropdown-menu,
.glass-header,
.main-header,
.nav-link,
.btn,
.list-group-item,
.table,
.card-dashboard,
.bg-light,
.bg-white,
.border,
.top-bar {
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

/* UI Components */

/* Barra de Avisos Superior */
.top-bar {
    padding: 0;
    font-size: 0.85rem;
    font-weight: 500;
    position: relative;
    z-index: 1050;
}

.top-bar-urgent {
    background-color: #fee2e2;
    /* Vermelho bem suave */
    color: #991b1b;
    border-bottom: 1px solid #fecaca;
}

.top-bar-info {
    background-color: var(--color-accent);
    color: #ffffff;
}

/* Header Principal (Glassmorphism) */
.main-header-wrapper {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    box-shadow: var(--shadow-soft);
}

/* Cards Padronizados */
.card,
.card-custom,
.card-dashboard {
    background: var(--bg-surface);
    border: 2px solid var(--border-color);
    border-radius: var(--radius-lg);
}

.card:hover {}

.card-studio {
    padding: 10px;
    background: #f3f7fc;
    border-radius: 12px;
}

/* --- NAVEGAÇÃO --- */

/* Sidebar (Desktop) */
.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    width: 260px;
    background: #ffffff;
    border-right: 1px solid #e2e8f0;
    z-index: 1040;
    padding: 20px 0;
    display: none;
    /* Oculto por padrão, visível em telas grandes */
    transition: all 0.3s ease;
    /* Flex layout handled by bootstrap classes in HTML, but we ensure display behavior here */
}

.sidebar-brand {
    padding: 0 24px 14px;
    text-align: center;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    padding: 0 12px;
    gap: 6px;
    overflow-y: auto;
    /* Scroll inside nav only */
    scrollbar-width: none;
    /* Firefox */
    min-height: 0;
    /* Garante scroll correto no Flexbox */
}

/* Esconde scrollbar no Chrome/Safari/Edge */
.sidebar-nav::-webkit-scrollbar {
    display: none;
}

.sidebar-heading {
    font-size: 0.7rem;
    text-transform: uppercase;
    font-weight: 700;
    color: #94a3b8;
    padding: 12px 16px 0;
    letter-spacing: 0.5px;
}

.sidebar-nav .nav-link {
    color: #64748b;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: all 0.2s;
    font-size: 0.9rem;
    text-decoration: none;
    background: transparent !important;
    /* Remove fundo azul antigo */
    box-shadow: none !important;
    border-radius: 55px;
    padding: 3px;
    border: 2px solid #ebebeb00;
}

.sidebar-nav .nav-link:hover {
    color: var(--color-accent);
    background: transparent;
    background-color: #f7f7f7 !important;
    border-radius: 55px;
    padding: 3px;
    border: 2px solid #ebebeb00;
}

/* Icon Wrapper (Círculo do Ícone) */
.nav-icon-wrapper {
    width: 38px;
    height: 38px;
    min-width: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background-color: #f1f5f9;
    color: #64748b;
    transition: all 0.2s ease;
    font-size: 1.25rem;
}

.sidebar-nav .nav-link:hover .nav-icon-wrapper {
    background-color: rgba(1, 125, 211, 0.1);
    color: var(--color-accent);
}

.sidebar-nav .nav-link.active {
    color: var(--color-primary);
    font-weight: 600;
    background-color: #ebebeb66 !important;
    border-radius: 55px;
    padding: 3px;
    border: 2px solid #ebebeb;
}

.sidebar-nav .nav-link.active .nav-icon-wrapper {
    background-color: var(--color-accent);
    color: #ffffff;
    /*box-shadow: 0 4px 10px rgba(1, 125, 211, 0.3);*/
}

/* 2. Bottom Bar (Mobile) */
.bottom-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #ffffff;
    box-shadow: 0 -5px 20px rgba(0, 0, 0, 0.08);
    /* Sombra mais destacada */
    height: auto;
    display: flex;
    justify-content: space-around;
    align-items: center;
    z-index: 1040;
    padding: 10px 15px;
    padding-bottom: calc(10px + env(safe-area-inset-bottom));
    /* Área segura iOS */
    border-top-left-radius: 20px;
    border-top-right-radius: 20px;
}

.bottom-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #94a3b8;
    text-decoration: none;
    font-size: 0.65rem;
    font-weight: 600;
    flex: 1;
    transition: all 0.3s ease;
    position: relative;
}

.bottom-nav-item .icon-container {
    font-size: 1.3rem;
    margin-bottom: -5px;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 25px;
    color: #64748b;
}

.bottom-nav-item.active {
    color: var(--color-accent, #017dd3);
}

.bottom-nav-item.active .icon-container {
    background-color: var(--color-accent, #017dd3);
    color: #ffffff;
    transform: translateY(-5px);
}

.bottom-nav-item .label {
    opacity: 0.8;
    transition: opacity 0.3s;
}

.bottom-nav-item.active .label {
    opacity: 1;
    font-weight: 700;
}

/* Offcanvas Mobile */
.offcanvas .sidebar-nav .nav-link {
    font-size: 1rem;
    /* Texto maior para facilitar leitura no mobile */
    padding: 12px 20px;
    /* Área de toque maior */
}

/* 3. Layout Adjustments */
@media (min-width: 992px) {

    /* Mostra Sidebar apenas no Desktop */
    .sidebar {
        display: flex !important;
        flex-direction: column;
        transition: width 0.3s ease;
    }

    /* Esconde Bottom Bar no Desktop */
    .bottom-bar {
        display: none;
    }

    /* Empurra o conteúdo para a direita se estiver logado */
    body.logged-in {
        padding-left: 260px;
        transition: padding-left 0.3s ease;
    }

    /* Esconde logo mobile no header se sidebar estiver ativa */
    body.logged-in .navbar-brand {
        display: none !important;
    }

    /* Estado Recolhido (Collapsed) */
    body.sidebar-collapsed { padding-left: 80px; }
    body.sidebar-collapsed .sidebar { width: 80px; }
    body.sidebar-collapsed .nav-label,
    body.sidebar-collapsed .sidebar-heading,
    body.sidebar-collapsed .sidebar > .mt-auto { display: none !important; }
    body.sidebar-collapsed .sidebar-nav .nav-link { justify-content: center; padding: 7px 0; margin: 3px 0; gap: 0; }
    body.sidebar-collapsed .nav-icon-wrapper { margin: 0; }
    body.sidebar-collapsed .sidebar-brand img { 
        max-width: 50px !important; 
        object-fit: cover; 
        object-position: left; 
    }
}

@media (max-width: 991px) {

    /* Espaço para a Bottom Bar no Mobile */
    body.logged-in {
        padding-bottom: 80px;
    }

    .sidebar {
        display: none !important;
    }

    /* !important é necessário para sobrescrever o d-flex do Bootstrap */
    .bottom-bar {
        display: flex;
    }
}

/* --- ANIMAÇÕES DE ENTRADA (SLIDE IN) --- */
@keyframes slideInUp {
    from {
        transform: translateY(20px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.slide-in-up {
    animation: slideInUp 0.5s ease-out forwards;
}

/* Animação em cascata para filhos diretos (ex: cards em um grid) */
.slide-in-stagger>* {
    opacity: 0;
    animation: slideInUp 0.5s ease-out forwards;
}

.slide-in-stagger>*:nth-child(1) {
    animation-delay: 0.05s;
}

.slide-in-stagger>*:nth-child(2) {
    animation-delay: 0.1s;
}

.slide-in-stagger>*:nth-child(3) {
    animation-delay: 0.15s;
}

.slide-in-stagger>*:nth-child(4) {
    animation-delay: 0.2s;
}

.slide-in-stagger>*:nth-child(5) {
    animation-delay: 0.25s;
}

.slide-in-stagger>*:nth-child(6) {
    animation-delay: 0.3s;
}

.slide-in-stagger>*:nth-child(n+7) {
    animation-delay: 0.35s;
}

/* --- DASHBOARD WIDGETS (USER) --- */
.card-widget {
    background: #fff;
    border-radius: 22px;
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    border: 2px solid var(--border-color);
    transition: all 0.3s ease;
    height: 100%;
}

.card-widget:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.06);
}

/* --- CARDS KPI (ESTILO BEHANCE MINIMALISTA) --- */
.card-kpi-premium {
    background: var(--bg-surface);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    border: 2px solid var(--border-color);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.card-kpi-premium-master {
    background: var(--bg-surface);
    border-radius: var(--radius-lg);
    padding: 1.2rem;
    border: 2px solid var(--border-color);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.kpi-label {
    color: #64748b;
    font-size: 0.85rem;
    font-weight: 500;
    margin-bottom: 8px;
}

.kpi-value {
    font-size: 1.8rem;
    font-weight: 800;
    color: #0f172a;
    line-height: 1;
    margin: 0;
}

.kpi-badge {
    font-size: 0.75rem;
    padding: 4px 8px;
    font-weight: 700;
}

.widget-icon {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.75rem;
    flex-shrink: 0;
    color: var(--color-accent);
}

.widget-content {
    flex-grow: 1;
    overflow: hidden;
}

.widget-label,
.stat-label {
    display: block;
    font-size: 0.75rem;
    text-transform: uppercase;
    font-weight: 700;
    color: #94a3b8;
    margin-bottom: 0.25rem;
    letter-spacing: 0.5px;
}

.widget-value,
.stat-value {
    display: block;
    font-size: 1.5rem;
    font-weight: 800;
    color: #1e293b;
    line-height: 1.2;
    margin-bottom: 0.25rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.widget-desc,
.stat-desc {
    display: block;
    font-size: 0.8rem;
    color: #64748b;
    margin-bottom: 0;
}

/* --- DASHBOARD STATS (ADMIN) --- */
.card-stat {
    background: #fff;
    border-radius: 16px;
    border: 1px solid var(--border-color);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
    transition: all 0.3s ease;
    height: 100%;
    position: relative;
    overflow: hidden;
}

.card-stat:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.06);
}

.card-stat .card-body {
    padding: 1.5rem;
}

.card-stat .icon-box {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

/* --- HEADER IMPROVEMENTS (WhatsApp, Notifications, User Menu) --- */

/* WhatsApp Button */
.btn-whatsapp {
    background-color: #3a986c;
    color: #fff !important;
    border: none;
    font-weight: 600;
    padding: 0.5rem 1.2rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-whatsapp:hover {
    background-color: #128C7E;
    color: #fff !important;
}

/* Notification Icon Button */
.btn-studio {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    border: 1px solid #e2e8f0;
    background: #fff;
    color: #64748b;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    position: relative;
    font-size: 1.2rem;
}

.btn-studio:hover,
.btn-studio[aria-expanded="true"] {
    background-color: #f1f5f9;
    color: var(--color-accent);
    border-color: var(--color-accent);
}

/* Notification Badge Override */
.btn-studio .badge {
    top: 0 !important;
    right: 0 !important;
    left: auto !important;
    transform: translate(25%, -25%) !important;
    border: 2px solid #fff;
    padding: 0.35em 0.5em;
}

.btn-i-studio {
    background: #1a9df7;
    color: white;
    padding: 1px 3px;
    border-radius: 5px;
}

.btn-i-new {
    background: #1a9df7;
    color: white;
    padding: 4px 5px;
    border-radius: 5px;
    font-size: 0.8rem;
}

.btn-i-edit {
    background: #f7d61a;
    color: white;
    padding: 4px 5px;
    border-radius: 5px;
    font-size: 0.8rem;
}

/* User Dropdown Trigger */
.dropdown-studio {
    border: 1px solid #e9e9e9;
    background: #f8f9fa;
    transition: all 0.2s ease;
    padding: 4px 4px 4px 4px !important;
    border-radius: 50px !important;
    gap: 8px;
}

.dropdown-studio:hover,
.dropdown-studio[aria-expanded="true"] {
    background-color: #fff;
    border-color: #e2e8f0;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.dropdown-studio .avatar-header {
    border: 2px solid #fff !important;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    width: 38px;
    height: 38px;
    padding: 0 !important;
    overflow: hidden;
    margin-right: 0 !important;
}

.dropdown-studio .avatar-header img {
    width: 100% !important;
    height: 100% !important;
}

.dropdown-studio i.bi-chevron-down {
    font-size: 0.75rem;
    margin-left: 4px;
    transition: transform 0.2s;
}

.dropdown-studio[aria-expanded="true"] i.bi-chevron-down {
    transform: rotate(180deg);
}

/* --- CARDS DE PRÓXIMAS ENTREGAS (CUSTOMIZADO) --- */
.card-entrega-item {
    position: relative;
    background-color: #ffffff;
    border-radius: 16px;
    /* rounded-4 */
    padding: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.03);
    border: 1px solid #f8fafc;
    z-index: 1;
    /* Garante que o texto fique acima do fundo */
    margin-bottom: 0.8rem;
}

.card-entrega-item:hover {
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.06);
    border-color: #e2e8f0;
}

/* A Mágica da Barra de Progresso no Fundo */
.card-entrega-progress {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    /* Gradiente suave azul com 8% a 4% de opacidade */
    background: linear-gradient(90deg, rgba(1, 125, 211, 0.08) 0%, rgba(1, 125, 211, 0.03) 100%);
    border-right: 2px solid rgba(1, 125, 211, 0.15);
    /* Linha sutil marcando o fim da barra */
    z-index: -1;
    /* Joga a barra para o fundo do card */
    transition: width 1s cubic-bezier(0.4, 0, 0.2, 1);
}

.card-entrega-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #ffffff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    background-color: #f1f5f9;
}

/* =========================================
   AGENDA DE SERVIÇOS (ESTILO BEHANCE UI)
   ========================================= */

/* --- Calendário Semanal do Topo --- */
.calendar-week-container {
    display: flex;
    justify-content: space-between;
    padding-bottom: 15px;
    border-bottom: 1px solid #f8fafc;
    /* Linha base sutil */
    margin-bottom: 15px;
}

.calendar-day-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 52px;
    border-radius: 12px;
    /* Cantos arredondados estilo app */
    color: #475569;
    transition: all 0.2s ease;
}

.calendar-day-box .day-name {
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    margin-bottom: 2px;
}

.calendar-day-box .day-num {
    font-size: 1rem;
    font-weight: 700;
}

/* Dia Ativo */
.calendar-day-box.active {
    background-color: #f472b6;
    color: #ffffff;
    box-shadow: 0 4px 10px rgba(244, 114, 182, 0.3);
}

/* Lista de Eventos */
.agenda-item-premium {
    position: relative;
    padding: 12px 0 12px 18px;
    /* Espaço na esquerda para a barra */
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px dashed #e2e8f0;
}

.agenda-item-premium:last-child {
    border-bottom: none;
}

/* A barrinha vertical colorida fina */
.agenda-indicator {
    position: absolute;
    left: 0;
    top: 20%;
    bottom: 20%;
    width: 3px;
    border-radius: 4px;
}

/* Cores das barrinhas para você alternar no JS */
.bg-indicator-green {
    background-color: #86efac;
}

.bg-indicator-blue {
    background-color: #60a5fa;
}

.bg-indicator-purple {
    background-color: #c084fc;
}

.bg-indicator-orange {
    background-color: #fdba74;
}

/* Textos do Evento */
.agenda-item-premium .agenda-title {
    font-size: 0.9rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 0px;
}

.agenda-item-premium .agenda-time {
    font-size: 0.75rem;
    color: #94a3b8;
    font-weight: 500;
}

.card-header-premium {
    font-size: 1rem;
    font-weight: 700;
    color: #0f172a;
    margin-bottom: 1.5rem;
    display: inline;
    align-items: center;
    justify-content: flex-start;
}


/* =========================================
   RESPONSIVIDADE (MOBILE & TABLET)
   ========================================= */
@media (max-width: 768px) {

    /* 1. Ajuste do Banner de Boas-vindas */
    .welcome-banner-content {
        text-align: center;
        justify-content: center;
    }

    .welcome-banner-content .d-flex {
        flex-direction: column;
        text-align: center;
    }

    /* 2. Redução de Margens e Paddings para ganhar tela */
    .container-fluid {
        padding-left: 12px !important;
        padding-right: 12px !important;
    }

    .card-kpi-premium,
    .card-body {
        padding: 1.5rem 1rem !important;
    }

    .card-kpi-premium-master {
        padding: 0rem;
    }

    /* 3. Ajuste de Fontes dos KPIs */
    .kpi-value {
        font-size: 1.5rem;
    }

    /* 4. Lista de Entregas (Evita quebrar o layout) */
    #lista-entregas .d-flex.align-items-center {
        gap: 0.75rem !important;
    }

    .avatar-html-mobile {
        width: 45px !important;
        height: 45px !important;
    }

    /* 5. Agenda Header (Força o scroll horizontal elegante) */
    #agenda-header {
        justify-content: flex-start !important;
        gap: 8px;
        padding-bottom: 8px;
        -webkit-overflow-scrolling: touch;
    }

    .px-3.1 {
        padding-right: 1rem !important;
        padding-left: 0 !important;
    }

    .badge-studio {
        display: none;
    }
}

/* --- FULLCALENDAR CUSTOMIZATION (Padronizado) --- */
.fc-toolbar-title {
    font-size: 1.5rem !important;
    font-weight: 700 !important;
    color: var(--color-primary);
    text-transform: capitalize;
}

.fc-button {
    border-radius: 50px !important;
    text-transform: capitalize !important;
    font-weight: 600 !important;
    font-size: 0.85rem !important;
    padding: 8px 16px !important;
    box-shadow: none !important;
    transition: all 0.2s ease;
}

.fc-button-primary {
    background-color: transparent !important;
    border: 1px solid var(--border-color) !important;
    color: var(--text-muted) !important;
}

.fc-button-primary:hover {
    background-color: var(--bg-subtle) !important;
    color: var(--color-primary) !important;
}

.fc-button-active {
    background-color: var(--color-accent) !important;
    border-color: var(--color-accent) !important;
    color: #fff !important;
}

.fc-scrollgrid {
    border: none !important;
}

.fc td,
.fc th {
    border-color: var(--border-color) !important;
}

.fc-col-header-cell-cushion {
    padding: 15px 0 !important;
    font-size: 0.75rem;
    text-transform: uppercase;
    color: var(--text-muted);
    font-weight: 700;
    letter-spacing: 0.5px;
    text-decoration: none !important;
}

.fc-daygrid-day-number {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-muted);
    padding: 8px 12px !important;
    text-decoration: none !important;
}

.fc-day-today {
    background-color: rgba(1, 125, 211, 0.05) !important;
    border: 2px solid var(--color-accent) !important;
}

.fc-day-today .fc-daygrid-day-number {
    color: var(--color-accent) !important;
    font-weight: 800 !important;
    font-size: 1.1rem !important;
}

.fc-event {
    border: none !important;
    border-radius: 6px !important;
    padding: 4px 6px !important;
    margin-bottom: 3px !important;
    font-size: 0.75rem !important;
    font-weight: 600 !important;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    transition: transform 0.1s;
}

.fc-event:hover {
    transform: scale(1.02);
}

.fc-daygrid-event-dot {
    display: none;
}

.fc-event-time {
    font-weight: 800;
    margin-right: 4px;
}

/* Cores de Eventos */
.evt-lead {
    background-color: #6f42c1 !important;
    border-color: #6f42c1 !important;
    color: #fff !important;
}

.evt-proposta {
    background-color: #fd7e14 !important;
    border-color: #fd7e14 !important;
    color: #fff !important;
}

.evt-ativo {
    background-color: #198754 !important;
    border-color: #198754 !important;
    color: #fff !important;
}

.evt-tarefa {
    background-color: #6c757d !important;
    border-color: #6c757d !important;
    color: #fff !important;
}

.evt-tarefa-concluida {
    background-color: #adb5bd !important;
    border-color: #adb5bd !important;
    color: #fff !important;
    text-decoration: line-through !important;
    opacity: 0.7;
}

.evt-padrao {
    background-color: var(--color-accent) !important;
    border-color: var(--color-accent) !important;
    color: #fff !important;
}

.evt-aniversario {
    background-color: #E91E63 !important;
    border-color: #E91E63 !important;
    color: #fff !important;
}

.legend-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    display: inline-block;
    margin-right: 5px;
}

/* --- SIDEBAR TAREFAS --- */
.task-input-group {
    background: var(--bg-subtle);
    border-radius: 15px;
    padding: 5px;
    border: 1px solid var(--border-color);
}

.task-item {
    background: var(--bg-surface);
    border-bottom: 1px solid var(--border-color);
    transition: all 0.2s;
    padding: 12px 0;
}

.task-item:hover {
    background-color: var(--bg-subtle);
}

.task-item:last-child {
    border-bottom: none;
}

.form-check-input {
    cursor: pointer;
    width: 1.2em;
    height: 1.2em;
    border: 2px solid var(--text-muted);
}

.btn-studio-menu {
    color: #444;
    background-color: #fff !important;
}
.btn-studio-menu:hover {
    color: #444;
    background-color: #fff !important;
}
.btn-studio-menu:active {
    color: #444 !important;
    background-color: #fff !important;
    border: none;
}
.form-check-input:checked {
    background-color: var(--color-danger);
    border-color: var(--color-danger);
}

/* Custom Scrollbar */
.custom-scroll {
    scrollbar-width: thin;
    scrollbar-color: #e9ecef transparent;
}

.custom-scroll::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

.custom-scroll::-webkit-scrollbar-track {
    background: transparent;
}

.custom-scroll::-webkit-scrollbar-thumb {
    background: #e9ecef;
    border-radius: 10px;
}

.custom-scroll::-webkit-scrollbar-thumb:hover {
    background: #ced4da;
}

@media (max-width: 1199px) {

    /* Em tablets, os cards de KPI podem ficar espremidos.
       Reduzimos a fonte e tiramos o limite de largura. */
    .kpi-value.text-truncate {
        max-width: 100% !important;
    }

    .kpi-label {
        font-size: 0.75rem;
    }
}

/* --- RESPONSIVIDADE BANNER BOAS-VINDAS --- */
@media (max-width: 768px) {
    .welcome-banner-content {
        text-align: center;
        justify-content: center;
    }

    .welcome-banner-content .d-flex {
        flex-direction: column;
        text-align: center;
    }

    .offcanvas {
        width: 100% !important;
    }

    /* Offcanvas full width no mobile */
}

/* Offcanvas Desktop Width */
@media (min-width: 769px) {
    .offcanvas-md-custom {
        width: 600px !important;
    }
}

/* --- OFFCANVAS MODERNIZATION (CLIENTES) --- */

/* Sidebar-like Tabs */
.nav-pills-custom {
    background: #fff;
    padding: 5px;
    border-radius: 16px;
    border: 1px solid #f1f5f9;
    display: flex;
    gap: 5px;
}

.nav-pills-custom .nav-link {
    color: #64748b;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.2s;
    font-size: 0.85rem;
    background: transparent;
    border-radius: 50px;
    padding: 10px 15px;
    width: 100%;
    border: 1px solid transparent;
}

.nav-pills-custom .nav-link:hover {
    background-color: #f8fafc;
    color: var(--color-accent);
}

.nav-pills-custom .nav-link.active {
    background-color: rgba(1, 125, 211, 0.08);
    color: var(--color-accent);
    font-weight: 600;
    border-color: rgba(1, 125, 211, 0.1);
}

.nav-pills-custom .nav-link i {
    font-size: 1.1rem;
}

/* Modern Form Inputs */
.form-control-modern,
.form-select-modern {
    border-radius: 12px;
    padding: 12px 15px;
    border: 1px solid #e2e8f0;
    background-color: #f8fafc;
    font-size: 0.95rem;
    color: #1e293b;
    transition: all 0.2s;
}

.form-control-modern:focus,
.form-select-modern:focus {
    background-color: #fff;
    border-color: var(--color-accent);
    box-shadow: 0 0 0 4px rgba(1, 125, 211, 0.1);
}

.form-label-modern {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    color: #94a3b8;
    margin-bottom: 6px;
    letter-spacing: 0.5px;
}

.avatar-uploader {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background-color: #f1f5f9;
    border: 2px dashed #cbd5e1;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    cursor: pointer;
    transition: all 0.2s;
    margin: 0 auto;
    overflow: hidden;
}

.avatar-uploader:hover {
    border-color: var(--color-accent);
    background-color: rgba(1, 125, 211, 0.05);
}

.avatar-uploader img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: none;
}

.avatar-uploader i {
    font-size: 2rem;
    color: #94a3b8;
    transition: color 0.2s;
}

.avatar-uploader:hover i {
    color: var(--color-accent);
}

.avatar-uploader-label {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: rgba(15, 23, 42, 0.6);
    color: white;
    font-size: 0.65rem;
    text-align: center;
    padding: 4px 0;
    opacity: 0;
    transition: opacity 0.2s;
}

.avatar-uploader:hover .avatar-uploader-label {
    opacity: 1;
}

.offcanvas-title {
    margin-bottom: 0;
    line-height: var(--bs-offcanvas-title-line-height);
    font-weight: 500;
}

.form-control {
    display: block;
    width: 100%;
    padding: .375rem .75rem;
    font-size: .85rem;
    font-weight: 500;
    line-height: 1.5;
    color: var(--bs-body-color);
    background-color: var(--bs-body-bg);
    background-clip: padding-box;
    border: var(--bs-border-width) solid var(--bs-border-color);
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    border-radius: var(--bs-border-radius);
    transition: border-color .15s ease-in-out, box-shadow .15s ease-in-out;
}

.form-select {
    --bs-form-select-bg-img: url(data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23343a40' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e);
    display: block;
    width: 100%;
    padding: .375rem 2.25rem .375rem .75rem;
    font-size: 0.85rem;
    font-weight: 500;
    line-height: 1.5;
    color: var(--bs-body-color);
    background-color: var(--bs-body-bg);
    background-image: var(--bs-form-select-bg-img), var(--bs-form-select-bg-icon, none);
    background-repeat: no-repeat;
    background-position: right .75rem center;
    background-size: 16px 12px;
    border: var(--bs-border-width) solid var(--bs-border-color);
    border-radius: var(--bs-border-radius);
    transition: border-color .15s ease-in-out, box-shadow .15s ease-in-out;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

/* ==========================================
   VISUALIZAÇÃO MOBILE (Telas menores que 992px)
   ========================================== */
@media (max-width: 991.98px) {

    /* Esconde a Sidebar lateral do Desktop */
    .sidebar {
        display: none !important;
    }

    /* Libera espaço no final da página para a barra não cobrir conteúdo */
    body {
        padding-bottom: 110px !important;
        /* Aumentado para compensar o menu flutuante */
        padding-left: 0 !important;
        /* Remove o padding da sidebar do desktop, se houver */
    }

    /* Estiliza a Bottom Bar (Floating Island Design) */
    .bottom-bar {
        display: flex;
        position: fixed;
        bottom: 0px;
        left: 0px;
        right: 0px;
        width: auto;
        background-color: rgba(255, 255, 255, 0.92);
        backdrop-filter: blur(12px);
        -webkit-backdrop-filter: blur(12px);
        border-radius: 0px;
        border: 1px solid rgba(255, 255, 255, 0.5);
        box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
        z-index: 1040;
        justify-content: space-around;
        padding: 9px 9px 19px 9px;
        margin-bottom: env(safe-area-inset-bottom, 0px);
    }

    .bottom-nav-item {
        display: flex;
        flex-direction: column;
        align-items: center;
        text-decoration: none;
        color: #64748b;
        font-size: 0.7rem;
        font-weight: 500;
        transition: all 0.2s ease;
    }

    .bottom-nav-item i {
        font-size: 1.45rem;
        /*margin-bottom: 2px;*/
    }

    .bottom-nav-item.active {
        color: var(--color-accent, #017dd3);
        /* Cor primária do sistema */
    }
}

/* ==========================================
   VISUALIZAÇÃO DESKTOP (Telas maiores que 992px)
   ========================================== */
@media (min-width: 992px) {

    /* Esconde a Bottom Bar e o Menu Lateral Mobile no computador */
    .bottom-bar {
        display: none !important;
    }
}

/* Animação de Piscar para Notificações */
@keyframes blink-opacity {
    0% {
        opacity: 1;
    }

    50% {
        opacity: 0.4;
    }

    100% {
        opacity: 1;
    }
}

.blink-animation {
    animation: blink-opacity 1.5s infinite ease-in-out;
}