:root {
    --bg-color: #1A1A1A;
    --sidebar-bg: #111111;
    --text-main: #FFFFFF;
    --text-muted: #E0E0E0;
    --accent-color: #1E90FF;
    --neon-accent: #00F0FF;
    --success-color: #00D18A;
    --border-color: #2D2D2D;
    --card-bg: #262626;
    --shadow: 0 2px 4px rgba(0,0,0,0.3);
    --transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Roboto', sans-serif;
}

img {
    max-width: 100%;
    height: auto;
}

body {
    background-color: var(--bg-color);
    color: var(--text-main);
}

/* Login Page */
body.login-page,
body.admin-page,
body.report-page {
    min-height: 100vh;
    margin: 0;
    position: relative;
    overflow-x: hidden;
    background:
        radial-gradient(circle at 10% 12%, rgba(0, 240, 255, 0.18), transparent 34%),
        radial-gradient(circle at 92% 88%, rgba(30, 144, 255, 0.16), transparent 38%),
        linear-gradient(135deg, #0b0f17 0%, #111827 48%, #090d16 100%);
}

body.login-page::before,
body.admin-page::before,
body.report-page::before {
    content: '';
    position: fixed;
    inset: 0;
    pointer-events: none;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
    background-size: 34px 34px;
    mask-image: radial-gradient(circle at center, black 40%, transparent 95%);
    opacity: 0.45;
}

body.admin-page .container,
body.report-page .container {
    position: relative;
    z-index: 1;
}

body.login-page .login-container {
    min-height: 100vh;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
}

body.login-page .login-card {
    width: min(440px, 100%);
    background: linear-gradient(160deg, rgba(38, 38, 38, 0.95), rgba(17, 17, 17, 0.92));
    border: 1px solid rgba(255, 255, 255, 0.09);
    border-radius: 18px;
    padding: 2rem 1.75rem;
    box-shadow: 0 24px 65px rgba(0, 0, 0, 0.45);
    backdrop-filter: blur(8px);
    position: relative;
    z-index: 1;
}

body.login-page .login-header {
    text-align: center;
    margin-bottom: 1.8rem;
}

body.login-page .login-header img {
    height: 56px;
    width: auto;
    display: block;
    margin: 0 auto 0.9rem;
}

body.login-page .login-header h2 {
    margin: 0;
    font-family: 'Montserrat', sans-serif;
    font-size: 1.65rem;
    color: #f8fbff;
}

body.login-page .login-subtitle {
    margin: 0.55rem 0 0;
    font-size: 0.92rem;
    color: var(--text-muted);
}

body.login-page .form-group label {
    color: #dbe4f0;
    font-weight: 600;
}

body.login-page .form-group input {
    background: #0d121b;
    border-color: #2a3344;
    color: #f8fbff;
    height: 46px;
}

body.login-page .form-group input:focus {
    border-color: var(--neon-accent);
    box-shadow: 0 0 0 4px rgba(0, 240, 255, 0.14);
}

body.login-page .btn-primary {
    justify-content: center;
    height: 46px;
    font-size: 0.98rem;
}

body.login-page #login-error {
    margin-top: 0.95rem !important;
    font-weight: 500;
}

.login-connection-status {
    margin-top: 0.95rem;
    text-align: center;
    font-size: 0.82rem;
    font-weight: 500;
}

.login-connection-status.info { color: #93c5fd; }
.login-connection-status.success { color: #00d18a; }
.login-connection-status.error { color: #ff6b6b; }

.container {
    display: flex;
    min-height: 100vh;
}

/* Sidebar */
.sidebar {
    width: 260px;
    background-color: var(--sidebar-bg);
    border-right: 1px solid var(--border-color);
    padding: 2rem 1rem;
    display: flex;
    flex-direction: column;
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
    position: relative;
    z-index: 100;
    position: sticky;
    top: 0;
    height: 100vh;
    z-index: 1000;
    flex-shrink: 0;
}

.sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 3rem;
}

.btn-sidebar-toggle {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    cursor: pointer;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.btn-sidebar-toggle:hover {
    background: rgba(30, 144, 255, 0.1);
    color: var(--neon-accent);
}

.logo {
    display: flex;
    align-items: center;
    padding-left: 1rem;
}

.logo img {
    max-width: 180px;
    height: auto;
}

.sidebar ul {
    list-style: none;
}

.sidebar li {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 1rem;
    color: var(--text-muted);
    cursor: pointer;
    border-radius: 8px;
    transition: var(--transition);
    margin-bottom: 5px;
    font-weight: 500;
}

.sidebar li:hover, .sidebar li.active {
    background-color: rgba(30, 144, 255, 0.1);
    color: var(--neon-accent);
}

.sidebar li.active i {
    filter: drop-shadow(0 0 5px var(--neon-accent));
}

/* Estado Recolhido */
.sidebar.collapsed {
    width: 80px;
    padding: 2rem 0.5rem;
}

.sidebar.collapsed .logo {
    display: none;
}

.sidebar.collapsed .sidebar-header {
    justify-content: center;
}

.sidebar.collapsed li span {
    display: none;
}

.sidebar.collapsed li {
    justify-content: center;
    padding: 12px;
}

/* Content Area */
.content {
    flex: 1;
    padding: 2rem 3rem;
    position: relative; /* Cria um contexto de empilhamento para o conteúdo */
    z-index: 1;         /* Define que este contexto está em uma camada inferior */
    min-width: 0;       /* Impede que o conteúdo largo force a expansão da página */
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

header h1 {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.75rem;
}

.user-profile {
    display: flex;
    align-items: center;
    gap: 10px;
}

.avatar {
    width: 35px;
    height: 35px;
    background: var(--accent-color);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

/* Dashboard Stats */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
}

.stat-card {
    background: var(--card-bg);
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
    display: flex;
    flex-direction: column;
    gap: 10px;
    border: 1px solid var(--border-color);
}

.stat-card i { color: var(--neon-accent); }
.stat-card h3 { font-size: 0.875rem; color: var(--text-muted); }
.stat-card p { 
    font-size: 1.75rem; 
    font-weight: 700; 
    font-family: 'Roboto Mono', monospace;
}

/* Dashboard Enhancements */
.dashboard-header-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2.5rem;
}

.stat-card.vibrant {
    background: linear-gradient(145deg, var(--card-bg), rgba(255,255,255,0.03));
    border: 1px solid rgba(255,255,255,0.08);
    padding: 1.75rem;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 1.25rem;
}

.stat-card.vibrant::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 4px; height: 100%;
    background: var(--accent-color);
    opacity: 0.5;
}

.stat-card.vibrant.primary::before { background: var(--neon-accent); }
.stat-card.vibrant.success::before { background: var(--success-color); }
.stat-card.vibrant.warning::before { background: #ef4444; }

.stat-card-icon-wrapper {
    width: 54px;
    height: 54px;
    border-radius: 14px;
    background: rgba(255,255,255,0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.stat-card-info h3 {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-muted);
    margin-bottom: 6px;
}

.stat-card-info .stat-value {
    font-size: 1.85rem;
    font-weight: 800;
    color: var(--text-main);
    line-height: 1.1;
    font-family: 'Roboto Mono', monospace;
}

.dashboard-section-title {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 1.5rem;
}

.dashboard-section-title h2 {
    font-size: 1.25rem;
    font-weight: 600;
    font-family: 'Montserrat', sans-serif;
}

/* Tables & Grids */
.action-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    gap: 1rem;
}

.btn-primary {
    background: var(--accent-color);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition);
}

.btn-primary:hover {
    background: #187bcd;
    box-shadow: 0 0 15px rgba(30, 144, 255, 0.3);
}

.btn-secondary {
    background: transparent;
    color: var(--text-main);
    border: 1px solid var(--border-color);
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-secondary:hover { background: rgba(255,255,255,0.05); }

.btn-danger {
    background: #ef4444;
    color: white;
    border: none;
}

.btn-danger:hover { background: #dc2626; }

table {
    width: 100%;
    background: var(--card-bg);
    border-collapse: collapse;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--border-color);
}

th, td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

th { background: rgba(255,255,255,0.03); color: var(--text-muted); font-size: 0.75rem; text-transform: uppercase; letter-spacing: 1px; }

/* Ads Grid */
.ads-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.5rem;
}

.ad-card {
    background: var(--card-bg);
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--border-color);
}

.ad-thumb {
    width: 100%;
    height: 150px;
    background: #111111;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.ad-thumb img, .ad-thumb video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.ad-card:hover .ad-thumb img, 
.ad-card:hover .ad-thumb video {
    transform: scale(1.05);
}

.video-hint {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(15, 23, 42, 0.7);
    color: white;
    padding: 12px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
    z-index: 2;
    transition: var(--transition);
}

.video-hint i, .video-hint svg {
    width: 20px;
    height: 20px;
}

.ad-card:hover .video-hint {
    background: var(--neon-accent);
    transform: translate(-50%, -50%) scale(1.1);
    color: #000;
}

.video-hint .hover-icon { display: none; }
.ad-card:hover .video-hint .play-icon { display: none; }
.ad-card:hover .video-hint .hover-icon { display: block; }

.ad-card-actions {
    z-index: 100;
}

.ad-info { padding: 1rem; }
.status-pill {
    padding: 4px 8px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: bold;
}
.status-active { background: rgba(0, 209, 138, 0.2); color: var(--success-color); }
.status-inactive { background: #fee2e2; color: #991b1b; }

/* Loading State */
.loading-shimmer {
    opacity: 0.6;
    pointer-events: none;
}

/* Actions Styling */
.actions {
    display: flex;
    gap: 8px;
}

.btn-action {
    background: none;
    border: none;
    padding: 6px;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    color: var(--text-muted);
}

.btn-action:hover {
    background: rgba(255,255,255,0.1);
    color: var(--neon-accent);
}

.btn-action.delete:hover {
    color: #ef4444;
    background: #fef2f2;
}

/* Modal */
.modal-overlay {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 3000;
    animation: fadeIn 0.2s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-content {
    background: var(--bg-color);
    border-radius: 16px;
    width: 550px;
    max-width: 95%;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    overflow: hidden;
    border: 1px solid var(--accent-color);
    animation: slideUp 0.3s ease-out;
}

@keyframes slideUp {
    from { transform: translateY(20px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.modal-header {
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(255,255,255,0.02);
}

.modal-header h2 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-main);
}

.close-btn {
    background: rgba(255,255,255,0.05);
    border: none;
    font-size: 1.2rem;
    cursor: pointer;
    color: var(--text-muted);
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.close-btn:hover {
    background: #e2e8f0;
    color: var(--text-main);
}

#modal-body {
    padding: 1.5rem;
}

.form-group { margin-bottom: 1.25rem; }
.form-group label { 
    display: block; 
    margin-bottom: 6px; 
    font-size: 0.85rem; 
    font-weight: 600; 
    color: var(--text-muted);
}

.form-group input, .form-group select {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 0.9rem;
    transition: all 0.2s;
    background-color: #111111;
    color: white;
}

.form-group input:focus, .form-group select:focus {
    outline: none;
    border-color: var(--neon-accent);
    background-color: #000;
    box-shadow: 0 0 0 4px rgba(0, 240, 255, 0.1);
}

.password-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.password-wrapper input {
    padding-right: 44px !important;
}

.password-toggle {
    position: absolute;
    right: 12px;
    background: transparent;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    transition: color 0.2s ease;
}

.password-toggle:hover {
    color: var(--neon-accent);
}

form .btn-primary {
    width: 100%;
    margin-top: 1rem;
    padding: 12px;
    justify-content: center;
}

/* Search Box */
.search-box {
    position: relative;
    flex: 1;
    max-width: 350px;
}

.search-box input {
    width: 100%;
    padding: 10px 15px 10px 40px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 0.9rem;
    background-color: #111111;
    color: white;
    transition: all 0.2s;
}

.search-box input:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.search-box i, .search-box svg {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    width: 16px;
    height: 16px;
    pointer-events: none;
    display: flex;
    align-items: center;
}

/* Ad Card Actions */
.ad-card {
    position: relative;
}

.ad-card-actions {
    position: absolute;
    top: 10px;
    right: 10px;
    display: flex;
    gap: 5px;
    opacity: 0;
    transition: opacity 0.2s;
}

.ad-card:hover .ad-card-actions {
    opacity: 1;
}

.ad-card-actions .btn-action {
    background: var(--card-bg);
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
}

/* Modal Size Variants */
.modal-content.modal-sm {
    width: 400px;
}

.modal-content.modal-lg {
    width: 850px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.modal-content.modal-sm .modal-header {
    display: none; /* Esconde o header padrão em diálogos de confirmação */
}

/* Dialog Specifics */
.dialog-content {
    text-align: center;
    padding: 1rem 0.5rem;
}

.dialog-icon {
    margin: 0 auto 1.5rem auto;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 64px;
    height: 64px;
    border-radius: 14px;
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.dialog-icon:hover {
    transform: scale(1.1) rotate(2deg);
}

.dialog-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-main);
    margin-bottom: 0.75rem;
}

.dialog-message {
    color: var(--text-muted);
    margin-bottom: 2rem;
    font-size: 0.95rem;
    line-height: 1.5;
    padding: 0 0.5rem;
}

.dialog-footer {
    display: flex;
    gap: 12px;
    width: 100%;
}

.dialog-footer button {
    flex: 1;
    justify-content: center;
    height: 44px;
}

/* Custom Searchable Select */
.searchable-select-container {
    position: relative;
    width: 100%;
}

.select-search-input {
    margin-bottom: 5px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='8'%3E%3C/circle%3E%3Cline x1='21' y1='21' x2='16.65' y2='16.65'%3E%3C/line%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: 14px center;
    padding-left: 38px !important;
}

.options-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    max-height: 300px;
    background: #1a1a1a;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    z-index: 1010;
    overflow-y: auto;
    display: none;
}

.options-dropdown.active {
    display: block;
}

.options-dropdown .option-item {
    display: flex;
    align-items: center;
}

.category-header {
    padding: 10px 12px;
    background: #111111;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--accent-color);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-bottom: 1px solid var(--border-color);
    border-top: 1px solid var(--border-color);
}

.option-item {
    padding: 10px 15px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: background 0.2s;
}

.option-item:hover {
    background: rgba(30, 144, 255, 0.1);
    color: var(--accent-color);
}

.options-dropdown .option-item {
    display: flex;
    align-items: center;
}

/* Preview de Mídia em Tela Cheia */
.ad-preview-trigger {
    cursor: pointer;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.preview-overlay {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.95);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 3100;
    cursor: pointer;
    animation: fadeIn 0.2s ease-out;
}

.preview-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: white;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
}

.preview-close:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
}

.fullscreen-media {
    max-width: 95%;
    max-height: 90vh;
    border-radius: 8px;
    box-shadow: 0 0 50px rgba(0,0,0,0.8);
    cursor: default;
}

/* Checkbox List for Multi-select */
.checkbox-list {
    max-height: 160px;
    overflow-y: auto;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 8px 12px;
    background-color: #111111;
}

.checkbox-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    cursor: pointer;
    font-size: 0.9rem;
    color: var(--text-main);
    border-bottom: 1px solid #f1f5f9;
}

.checkbox-item:last-child { border-bottom: none; }

.checkbox-item input[type="checkbox"] {
    width: 18px !important;
    height: 18px !important;
    cursor: pointer;
    margin: 0;
}

.select-display {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 0.9rem;
    background-color: #111111;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: var(--transition);
}

.select-display:hover {
    border-color: var(--accent-color);
}

.select-display::after {
    content: '';
    width: 0;
    height: 0;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 5px solid var(--text-muted);
}

.checkbox-item.dropdown-item {
    padding: 10px 15px;
}

.table-ad-thumb {
    width: 80px !important;
    height: 45px !important;
    border-radius: 6px;
    border: 1px solid var(--border-color);
}

.table-ad-thumb i, .table-ad-thumb svg {
    width: 20px !important;
    height: 20px !important;
}

.table-ad-thumb .video-hint {
    padding: 6px;
}

.table-ad-thumb .video-hint i, .table-ad-thumb .video-hint svg {
    width: 12px !important;
    height: 12px !important;
}

.vibrant-map, #map {
    width: 100%;
    height: 400px;
    border-radius: 12px;
    /* Efeito de borda infinita com gradiente */
    border: 4px solid transparent;
    background: 
        linear-gradient(var(--bg-color), var(--bg-color)) padding-box,
        linear-gradient(90deg, var(--neon-accent), var(--accent-color), var(--success-color), var(--neon-accent)) border-box;
    background-size: 300% 300%;
    animation: border-glow-flow 6s ease infinite;
    box-shadow: 0 10px 40px rgba(0,0,0,0.6), 0 0 20px rgba(0, 240, 255, 0.1);
    z-index: 1;
    overflow: hidden;
}

#map {
    height: 600px;
}

@keyframes border-glow-flow {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.leaflet-control-attribution {
    display: none !important;
}

.link-copy-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(0, 0, 0, 0.2);
    padding: 4px 8px;
    border-radius: 6px;
    border: 1px solid var(--border-color);
    width: fit-content;
    max-width: 220px;
}

.track-link {
    color: var(--neon-accent);
    font-size: 0.75rem;
    font-family: 'Roboto Mono', monospace;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex: 1;
}

/* Estilos para Marcadores de Veículo no Mapa */
.leaflet-vehicle-icon {
    background: transparent;
    border: none;
}

.custom-vehicle-marker {
    width: 44px;
    height: 44px;
    background: var(--card-bg);
    border: 2px solid var(--neon-accent);
    border-radius: 50%;
    padding: 2px;
    box-shadow: 0 0 15px rgba(0, 240, 255, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.custom-vehicle-marker:hover {
    transform: scale(1.15);
    z-index: 1000 !important;
    border-color: #fff;
    box-shadow: 0 0 20px rgba(0, 240, 255, 0.7);
}

.custom-vehicle-marker img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.custom-vehicle-marker .fallback-icon {
    font-size: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ============================================================
   ===== LANDING PAGE MOBISCREEN (EXCLUSIVO INDEX.HTML) ===== 
   ============================================================ */

:root {
    --lp-bg: #0b0f1a;
    --lp-card: #121826;
    --lp-accent: #00f0ff;
    --lp-accent-alt: #1e90ff;
    --lp-text: #ffffff;
    --lp-text-muted: #9aa4b2;
    --lp-border: rgba(255,255,255,0.08);
    --lp-shadow: 0 20px 50px rgba(0,0,0,0.5);
}

.lp-body {
    background-color: var(--lp-bg);
    color: var(--lp-text);
    scroll-behavior: smooth;
    overflow-x: hidden; /* Evita scroll lateral indesejado */
}

/* Navbar */
.lp-navbar {
    position: fixed;
    top: 0; width: 100%;
    z-index: 1000;
    backdrop-filter: blur(12px);
    background: rgba(11, 15, 26, 0.8);
    border-bottom: 1px solid var(--lp-border);
    padding: 1rem 0;
}

.lp-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
    width: 100%;
}

.lp-navbar .lp-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.lp-nav-links {
    display: flex;
    gap: 2rem;
}

.lp-nav-links a {
    color: var(--lp-text-muted);
    text-decoration: none;
    font-size: 0.95rem;
    transition: var(--transition);
}

.lp-nav-links a:hover { color: var(--lp-accent); }

/* Hero Section */
.lp-hero {
    padding: 10rem 0 6rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 500px), 1fr));
    gap: 4rem;
    align-items: center;
}

.lp-hero-content h1 {
    font-family: 'Montserrat', sans-serif;
    font-size: clamp(2.5rem, 5vw, 4rem);
    line-height: 1.1;
    margin-bottom: 1.5rem;
    background: linear-gradient(to right, #fff, var(--lp-accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.lp-hero-content p {
    color: var(--lp-text-muted);
    font-size: 1.2rem;
    margin-bottom: 2.5rem;
    line-height: 1.6;
    max-width: 600px;
}

.lp-hero-content {
    max-width: 600px;
    width: 100%;
}

/* Mockup Dashboard */
.lp-mockup {
    background: var(--lp-card);
    border: 1px solid var(--lp-border);
    border-radius: 20px;
    padding: 1.5rem;
    box-shadow: var(--lp-shadow);
    position: relative;
    overflow: hidden;
}

.lp-mockup-header {
    display: flex;
    gap: 8px;
    margin-bottom: 1.5rem;
}

.lp-dot { width: 10px; height: 10px; border-radius: 50%; background: #ff5f56; }
.lp-dot:nth-child(2) { background: #ffbd2e; }
.lp-dot:nth-child(3) { background: #27c93f; }

.lp-mockup-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.lp-mockup-item {
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--lp-border);
    padding: 1rem;
    border-radius: 12px;
}

.lp-mockup-item small { color: var(--lp-text-muted); font-size: 0.7rem; text-transform: uppercase; }
.lp-mockup-item h4 { font-family: 'Roboto Mono', monospace; color: var(--lp-accent); margin-top: 5px; }

/* Stats Section */
.lp-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 2rem;
    margin: 4rem 0;
}

.lp-stat-card {
    background: var(--lp-card);
    padding: 2.5rem;
    border-radius: 16px;
    border: 1px solid var(--lp-border);
    text-align: center;
    transition: var(--transition);
}

.lp-stat-card:hover {
    border-color: var(--lp-accent);
    transform: translateY(-10px);
    box-shadow: 0 10px 30px rgba(0, 240, 255, 0.1);
}

.lp-stat-card h2 {
    font-size: 2.5rem;
    color: var(--lp-accent);
    margin-bottom: 0.5rem;
}

.lp-stat-card p { color: var(--lp-text-muted); font-weight: 500; }

/* Steps Section */
.lp-section-title {
    text-align: center;
    margin-bottom: 4rem;
}

.lp-section-title h2 {
    font-family: 'Montserrat', sans-serif;
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.lp-steps-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.lp-step-card {
    padding: 2rem;
    background: rgba(255,255,255,0.02);
    border-radius: 16px;
    border: 1px solid var(--lp-border);
}

.lp-step-icon {
    width: 50px; height: 50px;
    background: rgba(30, 144, 255, 0.1);
    color: var(--lp-accent-alt);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.lp-steps-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

/* Grid de Benefícios Responsivo */
.lp-benefits-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    padding: 3rem !important;
}

@media (max-width: 768px) {
    .lp-benefits-grid {
        padding: 1.5rem !important;
    }
}

/* Responsive */
@media (max-width: 992px) {
    .lp-hero-section {
        padding-top: 8rem;
    }
    .lp-hero {
        grid-template-columns: 1fr;
        text-align: center;
    }
    .lp-hero-content p { margin: 0 auto 2.5rem; }
    .lp-steps-container { grid-template-columns: 1fr; }
    .lp-nav-links { display: none; }
}

.lp-btn-glow {
    position: relative;
    overflow: hidden;
}

.lp-btn-glow::after {
    content: '';
    position: absolute;
    top: -50%; left: -50%; width: 200%; height: 200%;
    background: radial-gradient(circle, rgba(0,240,255,0.2) 0%, transparent 70%);
    opacity: 0; transition: opacity 0.3s;
}

.lp-btn-glow:hover::after { opacity: 1; }

/* Animações de Revelação (Scroll Reveal) */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease-out;
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Grid de Destaque com Imagem */
.lp-feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 450px), 1fr));
    gap: 4rem;
    align-items: center;
}

@media (max-width: 992px) {
    .lp-feature-grid {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 2rem;
    }
}

/* Partner CTA button */
.lp-partner-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 2rem;
    color: var(--lp-text);
    border-color: rgba(255,255,255,0.3);
    text-decoration: none;
    font-weight: 600;
}

/* Hero badges row */
.lp-hero-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-top: 2rem;
    color: var(--lp-text-muted);
}

.lp-hero-badge {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    white-space: nowrap;
}

/* Hero CTA */
.lp-hero-cta {
    display: flex;
    gap: 1rem;
}

/* Contact buttons */
.lp-contact-btns {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.lp-contact-btn {
    padding: 1rem 3rem;
}

/* Benefit items */
.lp-benefit-item {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
}

.lp-benefit-item i,
.lp-benefit-item svg {
    flex-shrink: 0;
    color: var(--lp-accent);
    width: 20px;
    height: 20px;
    margin-top: 2px;
}

.lp-benefit-item h4 {
    margin-bottom: 0.3rem;
}

.lp-benefit-item p {
    color: var(--lp-text-muted);
    font-size: 0.9rem;
    margin: 0;
    line-height: 1.5;
}

/* Benefits columns */
.lp-benefits-column {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

/* Driver section */
.lp-driver-section {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 400px), 1fr));
    gap: 3rem;
    align-items: center;
}

.lp-section-h2 {
    font-family: 'Montserrat', sans-serif;
    font-size: 2rem;
    margin-bottom: 1.5rem;
}

.lp-driver-benefits {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    margin-bottom: 2rem;
}

.lp-driver-benefit-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.lp-driver-benefit-item i,
.lp-driver-benefit-item svg {
    flex-shrink: 0;
    color: var(--lp-accent);
    width: 22px;
    height: 22px;
}

.lp-driver-benefit-item p {
    color: var(--lp-text-muted);
    font-size: 1rem;
    margin: 0;
    line-height: 1.4;
}

/* ============================================================
   ============================================================ */

@media (max-width: 768px) {

    /* --- Container padding --- */
    .lp-container {
        padding: 0 1.25rem;
    }

    /* --- Hero section --- */
    .lp-hero {
        padding: 8rem 0 3rem;
        gap: 2rem;
    }

    .lp-hero-content {
        max-width: 100%;
        width: 100%;
    }

    .lp-hero-content h1 {
        font-size: clamp(1.8rem, 8vw, 2.8rem);
        line-height: 1.15;
        margin-bottom: 1rem;
    }

    .lp-hero-content p {
        font-size: 1rem;
        margin-bottom: 1.5rem;
        max-width: 100%;
    }

    /* --- Feature badges row below hero button --- */
    .lp-hero-content > div[style*="gap: 1.5rem"] {
        flex-wrap: wrap;
        justify-content: center;
        gap: 0.75rem !important;
    }

    /* --- Buttons --- */
    .btn-primary,
    .btn-secondary {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        text-align: center;
        white-space: normal;
        word-break: keep-all;
        padding: 0.75rem 1.5rem;
        font-size: 0.95rem;
        line-height: 1.3;
        width: auto;
        min-width: 0;
        max-width: 100%;
    }

    /* Hero CTA button — full width on mobile */
    .lp-hero-content > div[style*="display: flex"] .btn-primary {
        width: 100%;
        justify-content: center;
    }

    /* --- Mockup card in hero --- */
    .lp-mockup {
        max-width: 100%;
        margin: 0 auto;
    }

    /* --- Section padding --- */
    section[id="tecnologia"],
    #como-funciona,
    #plataforma,
    #contato {
        padding: 3.5rem 0 !important;
    }

    .form-row {
        grid-template-columns: 1fr;
        gap: 0;
    }

    /* --- "Onde sua marca ganha vida" feature grid --- */
    .lp-feature-grid {
        gap: 1.5rem;
        text-align: left;
    }

    /* Feature items (icon + text rows) */
    .lp-feature-grid > .lp-hero-content > div[style*="display: grid"] {
        gap: 1.25rem;
    }

    .lp-feature-grid > .lp-hero-content h2[style] {
        font-size: 1.8rem !important;
        text-align: left;
    }

    /* --- Section titles --- */
    .lp-section-title h2 {
        font-size: 1.75rem;
        line-height: 1.2;
    }

    .lp-section-title p {
        font-size: 0.95rem;
    }

    /* --- Steps cards --- */
    .lp-steps-container {
        grid-template-columns: 1fr;
        gap: 1.25rem;
        margin-top: 1.5rem;
    }

    .lp-step-card {
        padding: 1.5rem;
    }

    .lp-step-card h3 {
        font-size: 1rem;
        margin-bottom: 0.5rem;
    }

    .lp-step-card p {
        font-size: 0.9rem;
        line-height: 1.5;
    }

    /* --- Benefits / "Resultados" section --- */
    .lp-benefits-grid {
        grid-template-columns: 1fr !important;
        padding: 1.5rem !important;
        gap: 0 !important;
    }

    .lp-benefits-column {
        display: flex;
        flex-direction: column;
        gap: 1.25rem;
    }

    .lp-benefits-column + .lp-benefits-column {
        margin-top: 1.25rem;
    }

    /* Benefit items — icon alignment & text overflow */
    .lp-benefit-item {
        display: flex;
        align-items: flex-start;
        gap: 0.75rem;
        overflow: visible;
    }

    .lp-benefit-item i,
    .lp-benefit-item svg {
        flex-shrink: 0;
        width: 20px;
        height: 20px;
        margin-top: 2px;
    }

    .lp-benefit-item h4 {
        font-size: 0.95rem;
        margin-bottom: 0.25rem;
        white-space: normal;
    }

    .lp-benefit-item p {
        font-size: 0.875rem;
        line-height: 1.5;
        color: var(--lp-text-muted);
        margin: 0;
        white-space: normal;
    }

    /* --- Driver section --- */
    .lp-driver-section {
        grid-template-columns: 1fr !important;
        padding-top: 0 !important;
        gap: 2rem !important;
    }

    .lp-driver-content {
        padding: 0 !important;
        max-width: 100%;
        text-align: left;
    }

    .lp-section-h2 {
        font-size: 1.75rem;
        margin-bottom: 1.25rem;
    }

    .lp-driver-benefits {
        gap: 1.25rem;
        margin-bottom: 1.5rem;
    }

    /* Driver benefit items — icon + text alignment */
    .lp-driver-benefit-item {
        display: flex;
        align-items: center;
        gap: 0.75rem;
    }

    .lp-driver-benefit-item i,
    .lp-driver-benefit-item svg {
        flex-shrink: 0;
        width: 22px;
        height: 22px;
        color: var(--lp-accent);
    }

    .lp-driver-benefit-item p {
        font-size: 0.95rem;
        color: var(--lp-text-muted);
        line-height: 1.4;
        margin: 0;
    }

    /* "Quero ser parceiro" button */
    .lp-driver-content > a.btn-secondary {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        padding: 0.75rem 1.75rem;
        font-size: 0.95rem;
        border-color: var(--lp-text);
        color: var(--lp-text);
        text-decoration: none;
        border-radius: 8px;
    }

    /* --- Stats grid --- */
    .lp-stats-grid {
        grid-template-columns: 1fr 1fr;
        gap: 1rem;
        margin: 2rem 0;
    }

    .lp-stat-card {
        padding: 1.5rem 1rem;
    }

    .lp-stat-card h2 {
        font-size: 1.75rem;
    }

    /* --- Contact section --- */
    #contato .lp-mockup {
        padding: 2rem 1.25rem !important;
        margin: 0 0 !important;
        max-width: 100% !important;
    }

    #contato h2[style] {
        font-size: 1.6rem !important;
        line-height: 1.2;
    }

    #contato > div > div[style*="display: flex"] {
        flex-direction: column;
        align-items: stretch;
        gap: 0.75rem !important;
    }

    #contato .btn-primary,
    #contato .btn-secondary {
        width: 100%;
        justify-content: center;
        padding: 0.875rem 1.5rem !important;
    }

    /* --- Footer --- */
    footer > .lp-container {
        grid-template-columns: 1fr !important;
        gap: 2rem !important;
    }

    /* --- Navbar "Entrar em Contato" button text fix --- */
    .lp-nav-mobile-contact {
        padding: 0.75rem 1rem;
        justify-content: center;
        font-size: 0.95rem;
    }
}

/* ============================================================
   ===== COMERCIAL & KANBAN CRM ===== 
   ============================================================ */

.kanban-board {
    display: flex;
    flex-direction: row; /* Garante layout horizontal */
    flex-wrap: nowrap; /* Impede quebra de linha */
    gap: 1.25rem;
    overflow-x: auto;
    padding-bottom: 1.5rem;
    height: calc(100vh - 180px); /* Altura fixa para scroll */
    align-items: stretch; /* Colunas esticadas */
    justify-content: center; /* Centraliza os blocos na tela */
}

/* Scrollbar para o Kanban */
.kanban-board::-webkit-scrollbar { height: 12px; }
.kanban-board::-webkit-scrollbar-track { background: rgba(0,0,0,0.2); border-radius: 5px; }
.kanban-board::-webkit-scrollbar-thumb { background: #404040; border-radius: 5px; }
.kanban-board::-webkit-scrollbar-thumb:hover { background: var(--accent-color); }

.kanban-column {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    min-width: 300px; /* Largura fixa */
    width: 300px;
    flex: 0 0 300px; /* Fixar tamanho */
    display: flex;
    flex-direction: column;
    transition: background 0.2s;
    height: 100%; /* Ocupar altura total do board */
}

.kanban-header {
    padding: 1.25rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.kanban-header h3 {
    font-size: 0.85rem;
    text-transform: uppercase;
    font-weight: 700;
    color: var(--neon-accent);
    margin: 0;
}

.kanban-cards {
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    flex: 1;
    overflow-y: auto; /* Scroll vertical nos cards */
    padding-right: 5px;
}

.lead-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    padding: 1.25rem;
    border-radius: 10px;
    cursor: pointer;
    transition: var(--transition);
    position: relative;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.lead-card.dragging {
    opacity: 0.5;
    border: 2px dashed var(--neon-accent);
    background: rgba(0, 240, 255, 0.05);
}

.lead-card:hover {
    border-color: var(--neon-accent);
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.3);
}

.lead-priority {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    display: inline-block;
    margin-right: 6px;
}

.lead-value {
    font-family: 'Roboto Mono', monospace;
    font-size: 0.85rem;
    color: var(--success-color);
    font-weight: 600;
}

.priority-alta { background: #ef4444; box-shadow: 0 0 8px #ef4444; }
.priority-media { background: #f59e0b; }
.priority-baixa { background: #10b981; }

/* Cores por Etapa do Kanban */
/* 1. Lead Capturado (Amarelo) */
.kanban-column.lead-capturado { border-top: 4px solid #facc15; background: rgba(250, 204, 21, 0.02); }
.kanban-column.lead-capturado h3 { color: #facc15; }
.lead-capturado .lead-card { border-left: 4px solid #facc15; }

/* 2. Primeiro Contato (Azul) */
.kanban-column.primeiro-contato { border-top: 4px solid #3b82f6; background: rgba(59, 130, 246, 0.02); }
.kanban-column.primeiro-contato h3 { color: #3b82f6; }
.primeiro-contato .lead-card { border-left: 4px solid #3b82f6; }

/* 3. Em Negociação (Laranja) */
.kanban-column.em-negociacao { border-top: 4px solid #f97316; background: rgba(249, 115, 22, 0.02); }
.kanban-column.em-negociacao h3 { color: #f97316; }
.em-negociacao .lead-card { border-left: 4px solid #f97316; }

/* 4. Proposta Enviada (Roxo) */
.kanban-column.proposta-enviada { border-top: 4px solid #a855f7; background: rgba(168, 85, 247, 0.02); }
.kanban-column.proposta-enviada h3 { color: #a855f7; }
.proposta-enviada .lead-card { border-left: 4px solid #a855f7; }

/* 5. Fechado (Verde) */
.kanban-column.fechado { border-top: 4px solid #22c55e; background: rgba(34, 197, 94, 0.02); }
.kanban-column.fechado h3 { color: #22c55e; }
.fechado .lead-card { border-left: 4px solid #22c55e; }

/* 6. Perdido (Vermelho) */
.kanban-column.perdido { border-top: 4px solid #ef4444; background: rgba(239, 68, 68, 0.02); }
.kanban-column.perdido h3 { color: #ef4444; }
.perdido .lead-card { border-left: 4px solid #ef4444; }

/* Drag Over Effect */
.kanban-column.drag-over {
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--neon-accent);
}

/* Seletor de Etapas em Blocos (Modal) */
.stage-selector {
    display: flex;
    gap: 5px;
    background: #111;
    padding: 5px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    overflow-x: auto;
    margin-top: 5px;
}
.stage-option {
    flex: 1;
    text-align: center;
    padding: 10px 5px;
    font-size: 0.75rem;
    cursor: pointer;
    border-radius: 6px;
    background: rgba(255,255,255,0.05);
    color: var(--text-muted);
    transition: all 0.2s;
    white-space: nowrap;
    border: 1px solid transparent;
}
.stage-option:hover { background: rgba(255,255,255,0.1); }
.stage-option.active {
    background: rgba(0, 240, 255, 0.15);
    color: var(--neon-accent);
    border-color: var(--neon-accent);
    font-weight: 600;
}

/* ============================================================
   ===== LAYOUT NAVBAR SUPERIOR (CRM) ===== 
   ============================================================ */

body.crm-page {
    overflow: hidden;
}

body.crm-page .container {
    display: flex;
    flex-direction: column;
    padding-top: 100px; /* Espaço ajustado para navbar */
    height: 100vh;
    overflow: hidden;
}

body.crm-page .content {
    padding: 1rem 2rem;
    width: 100%;
    max-width: 100%;
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

body.crm-page .tab-content {
    display: flex;
    flex-direction: column;
    flex: 1;
    height: 100%;
    overflow: hidden;
}

body.crm-page .kanban-board {
    height: auto !important;
    flex: 1;
    margin-bottom: 0;
    padding-bottom: 10px;
}

.crm-navbar .navbar-left { display: flex; align-items: center; gap: 1rem; }
.crm-navbar .logo img { height: 40px; width: auto; }

.crm-navbar .navbar-menu { display: flex; list-style: none; gap: 1rem; margin: 0; padding: 0; }
.crm-navbar .navbar-menu li {
    display: flex; align-items: center; gap: 8px;
    padding: 8px 16px;
    color: var(--text-muted);
    cursor: pointer;
    border-radius: 6px;
    transition: all 0.2s;
    font-weight: 500;
    font-size: 0.9rem;
}
.crm-navbar .navbar-menu li:hover, .crm-navbar .navbar-menu li.active { background: rgba(30, 144, 255, 0.1); color: var(--neon-accent); }
.crm-navbar .navbar-menu li.active i { filter: drop-shadow(0 0 5px var(--neon-accent)); }

/* ============================================================
   ===== NAVBAR ESTILO PILL (IGUAL PAGE.HTML) ===== 
   ============================================================ */

.lp-navbar {
    top: 1rem;
    left: 50%;
    transform: translateX(-50%);
    width: fit-content;
    max-width: 95%;
    padding: 0.7rem 1.75rem;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 20px;
    background: linear-gradient(120deg, rgba(7, 11, 18, 0.92), rgba(14, 20, 32, 0.82));
    backdrop-filter: blur(14px);
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.35);
    transition: top 0.28s ease, width 0.28s ease, padding 0.28s ease, box-shadow 0.28s ease, background 0.28s ease;
    position: fixed;
    white-space: nowrap;
    z-index: 2000;
}

.lp-navbar .lp-container {
    max-width: none;
    width: 100%;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: nowrap;
    gap: 1.75rem;
}

.lp-navbar .lp-brand {
    display: flex;
    align-items: center;
    margin-right: 0.9rem;
    flex-shrink: 0;
}

.lp-navbar .lp-brand img {
    height: 40px;
    width: auto;
    display: block;
    transition: height 0.28s ease;
}

/* Estado Scrolled (quando rola a página) */
.lp-navbar.lp-navbar-scrolled {
    top: 0.55rem;
    width: fit-content;
    max-width: calc(100% - 1.5rem);
    padding: 0.5rem 1.5rem;
    background: rgba(9, 13, 22, 0.94);
    box-shadow: 0 16px 34px rgba(0, 0, 0, 0.42);
}

.lp-navbar.lp-navbar-scrolled .lp-container {
    padding: 0 0.7rem;
    gap: 0.9rem;
}

/* ============================================================
   ===== HEADER E BUSCA EXPANSIVA (CRM) ===== 
   ============================================================ */

body.crm-page header {
    justify-content: flex-start; /* Alinha tudo à esquerda */
    gap: 1.5rem; /* Espaço entre Título e Busca */
}

.header-left-group {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.search-expandable-container {
    position: relative;
    height: 40px;
    display: flex;
    flex-shrink: 0;
    align-items: center;
}

/* Custom Nav Dropdown */
.custom-nav-dropdown {
    position: relative;
    user-select: none;
    flex-shrink: 0;
}

.nav-dropdown-trigger {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 7px 14px;
    cursor: pointer;
    transition: var(--transition);
    color: #fff;
    white-space: nowrap;
    font-weight: 600;
    font-size: 0.85rem;
    letter-spacing: 0.5px;
}

.nav-dropdown-trigger:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--neon-accent);
    box-shadow: 0 0 15px rgba(0, 240, 255, 0.1);
}

.nav-dropdown-menu {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    width: 200px;
    background: rgba(15, 20, 30, 0.95);
    backdrop-filter: blur(12px);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.6);
    display: none;
    flex-direction: column;
    padding: 6px;
    z-index: 2100;
    animation: fadeInDown 0.2s ease-out;
}

.nav-dropdown-menu.active { display: flex; }

.search-icon-visual {
    position: absolute;
    left: 8px;
    color: var(--neon-accent);
    width: 20px;
    height: 20px;
    z-index: 10;
    pointer-events: none; /* Permite clicar no input através do ícone */
    filter: drop-shadow(0 0 5px rgba(0, 240, 255, 0.6)); /* Efeito de brilho/destaque */
}

.search-input-animated {
    width: 200px;
    height: 40px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding-left: 38px;
    padding-right: 15px;
    color: var(--text-main);
    cursor: text;
    transition: all 0.2s ease;
}

.search-input-animated:focus {
    background: #000;
    border-color: var(--neon-accent);
    box-shadow: 0 0 15px rgba(0, 240, 255, 0.15);
}

/* Ajuste para o placeholder não aparecer quando fechado */
.search-input-animated::placeholder {
    color: var(--text-muted);
}

/* Ajustes para Desktop Menor e Tablets (Evitar quebra e overflow) */
@media (max-width: 1366px) {
    .lp-navbar .lp-container {
        gap: 1rem !important;
    }
    .lp-nav-links {
        gap: 0.75rem !important;
        flex-shrink: 1 !important;
    }
    .search-input-animated {
        width: 150px;
    }
    .lp-navbar .lp-brand {
        margin-right: 0.5rem;
    }
}

@media (max-width: 1100px) {
    .lp-nav-links span {
        display: none !important;
    }
    .lp-navbar .lp-brand img {
        height: 32px;
    }
}

@media (max-width: 768px) {
    /* 1 - Navbar flutuante na parte inferior */
    .lp-navbar, 
    .lp-navbar.lp-navbar-scrolled {
        top: auto;
        bottom: 1.5rem;
        left: 50%;
        transform: translateX(-50%);
        width: 95%;
        max-width: 420px; /* Ajustado para melhor visualização */
        padding: 10px; /* Padding uniforme para os itens */
        border-radius: 50px; /* Formato de pílula */
        background: rgba(15, 20, 32, 0.85); /* Fundo com mais transparência */
        backdrop-filter: blur(25px); /* Efeito de vidro mais intenso */
        box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.6);
        border: 1px solid rgba(255, 255, 255, 0.15);
    }

    .lp-navbar .lp-brand {
        display: none; /* Oculta logo no mobile */
    }

    .lp-navbar .lp-container {
        gap: 10px; /* Espaçamento entre os ícones */
        justify-content: space-evenly; /* Distribui os itens uniformemente */
        width: 100%;
    }

    .lp-nav-links {
        display: contents; /* Permite que os filhos sejam itens flex diretos */
    }

    /* Mostrar apenas ícones no mobile */
    .lp-nav-links span,
    #nav-current-label,
    .nav-dropdown-trigger i[data-lucide="chevron-down"] {
        display: none !important;
    }

    .custom-nav-dropdown {
        position: static; /* Permite centralização absoluta do menu em relação à navbar */
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .nav-dropdown-trigger, 
    .user-profile .avatar, 
    .lp-nav-links button {
        padding: 0;
        background: rgba(255, 255, 255, 0.08); /* Fundo dos botões */
        border: 1px solid rgba(255, 255, 255, 0.12); /* Borda dos botões */
        width: 48px; /* Tamanho padrão para todos os botões/ícones */
        height: 48px;
        border-radius: 50% !important; /* Formato circular */
        display: flex;
        align-items: center;
        justify-content: center;
        flex-shrink: 0;
        margin: 0; /* Remove margens externas */
        gap: 0; /* Remove espaçamento interno */
    }

    .nav-dropdown-trigger i, 
    .user-profile .avatar i, 
    .lp-nav-links button i {
        width: 20px !important; /* Tamanho padrão dos ícones */
        height: 20px !important;
    }

    .user-profile {
        display: flex;
        align-items: center;
        justify-content: center;
        position: static !important;
    }

    .nav-dropdown-menu,
    #profile-dropdown {
        position: absolute;
        bottom: calc(100% + 15px) !important; /* Abre acima da navbar */
        top: auto !important;
        left: 50% !important;
        right: auto !important;
        transform: translateX(-50%) !important; /* Centraliza horizontalmente */
        width: 180px;
        background: rgba(20, 25, 35, 0.98);
        backdrop-filter: blur(20px);
        border: 1px solid rgba(255, 255, 255, 0.15);
        border-radius: 12px;
        box-shadow: 0 -10px 30px rgba(0, 0, 0, 0.5);
        display: none;
        flex-direction: column;
        padding: 8px;
        z-index: 3000;
        margin-top: 0 !important;
        animation: fadeInUpMobile 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    }

    .nav-dropdown-menu.active,
    #profile-dropdown.active {
        display: flex !important;
    }

    /* Remover completamente a barra de pesquisa no mobile */
    .search-expandable-container {
        display: none !important;
    }

    body.crm-page .container {
        padding-top: 20px;
        padding-bottom: 100px; /* Espaço para a navbar inferior */
    }

    /* 2 - Modal de cliente responsivo (Bottom Sheet) */
    .modal-content {
        width: 98% !important;
        max-height: 92vh;
        margin: 0;
        display: flex;
        flex-direction: column;
        border-radius: 20px 20px 0 0; /* Bordas arredondadas apenas no topo */
    }

    #modal-body {
        flex: 1;
        overflow-y: auto; /* Scroll interno para o conteúdo do modal */
        padding: 1.25rem;
        -webkit-overflow-scrolling: touch; /* Scroll suave no iOS */
    }

    .form-row {
        grid-template-columns: 1fr; /* Campos empilhados verticalmente */
        gap: 0;
    }

    .kanban-board {
        justify-content: flex-start;
        padding: 1rem;
        scroll-snap-type: x mandatory; /* Efeito de snap nas colunas */
        height: calc(100vh - 120px) !important; /* Altura ajustada para o Kanban */
    }

    .kanban-column {
        min-width: 85vw; /* Colunas ocupam 85% da tela */
        flex: 0 0 85vw;
        scroll-snap-align: center; /* Centraliza a coluna ao rolar */
    }

    .dashboard-header-stats {
        grid-template-columns: 1fr !important; /* Stats empilhados */
    }

    .toast-container {
        bottom: 100px; /* Posição acima da navbar inferior */
        right: 10px;
        left: 10px;
    }

    /* Ajustes específicos para a aba de Metas no Mobile */
    #tab-metas {
        overflow-y: auto !important;
        height: 100%;
        padding-bottom: 120px !important; /* Espaço extra para a navbar inferior */
    }

    .meta-card-mobile {
        background: var(--card-bg);
        border: 1px solid var(--border-color);
        border-left: 4px solid var(--success-color);
        border-radius: 12px;
        padding: 1.25rem;
        margin-bottom: 1rem;
        display: flex;
        flex-direction: column;
        gap: 8px;
        box-shadow: var(--shadow);
    }

    .meta-card-mobile .meta-row {
        display: flex;
        justify-content: space-between;
        align-items: center;
    }

    .meta-card-mobile .meta-label { font-size: 0.75rem; color: var(--text-muted); text-transform: uppercase; }
    .meta-card-mobile .meta-value { font-weight: 600; font-size: 0.9rem; }
}

@keyframes fadeInUpMobile {
    from { opacity: 0; transform: translate(-50%, 10px); }
    to { opacity: 1; transform: translate(-50%, 0); }
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    bottom: 24px;
    right: 24px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    z-index: 9999;
    pointer-events: none;
}

.toast {
    background: rgba(26, 26, 26, 0.95);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 14px 20px;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 320px;
    max-width: 420px;
    backdrop-filter: blur(12px);
    pointer-events: auto;
    animation: toast-in 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), toast-out 0.4s ease-in 3.5s forwards;
}

@keyframes toast-in {
    from { transform: translateX(100%) scale(0.9); opacity: 0; }
    to { transform: translateX(0) scale(1); opacity: 1; }
}

@keyframes toast-out {
    from { transform: translateX(0) scale(1); opacity: 1; }
    to { transform: translateX(100%) scale(0.9); opacity: 0; }
}

.toast-icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.toast-title { font-weight: 700; font-size: 0.9rem; color: #fff; margin-bottom: 2px; }
.toast-message { font-size: 0.8rem; color: var(--text-muted); line-height: 1.4; }
