/* Reset e Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: #ffffff;
    min-height: 100vh;
    color: #333;
}

/* Container Principal */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Cards */
.card {
    background: white;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    padding: 30px;
    margin-bottom: 20px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.card-header {
    border-bottom: 2px solid #f8f9fa;
    padding-bottom: 15px;
    margin-bottom: 25px;
}

.card-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 5px;
}

.card-subtitle {
    color: #6c757d;
    font-size: 0.9rem;
}

/* Formulários */
.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #495057;
}

.form-control {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.form-control:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.form-control.is-invalid {
    border-color: #dc3545;
}

.form-control.is-valid {
    border-color: #28a745;
}

/* Botões */
.btn {
    display: inline-block;
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 500;
    text-decoration: none;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-right: 10px;
    margin-bottom: 10px;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

.btn-success {
    background: linear-gradient(135deg, #56ab2f 0%, #a8e6cf 100%);
    color: white;
}

.btn-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(86, 171, 47, 0.4);
}

.btn-danger {
    background: linear-gradient(135deg, #ff416c 0%, #ff4b2b 100%);
    color: white;
}

.btn-danger:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 65, 108, 0.4);
}

.btn-warning {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: white;
}

.btn-warning:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(240, 147, 251, 0.4);
}

.btn-info {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    color: white;
}

.btn-info:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(79, 172, 254, 0.4);
}

.btn-secondary {
    background: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background: #5a6268;
    transform: translateY(-2px);
}

.btn-sm {
    padding: 8px 16px;
    font-size: 0.875rem;
}

/* Navegação Moderna */
.modern-navbar {
    background: linear-gradient(135deg, rgba(255,255,255,0.95) 0%, rgba(248,249,250,0.95) 100%);
    backdrop-filter: blur(20px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    border-bottom: 1px solid rgba(255,255,255,0.2);
    position: sticky;
    top: 0;
    z-index: 1000;
    margin-bottom: 0;
}

.navbar-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 80px;
}

/* Brand Section */
.navbar-brand-section {
    display: flex;
    align-items: center;
}

.navbar-brand-modern {
    display: flex;
    align-items: center;
    gap: 15px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.navbar-brand-modern:hover {
    transform: translateY(-2px);
}

.brand-icon {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
}

.icon-gradient {
    font-size: 1.8rem;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.2));
}

.brand-text {
    display: flex;
    flex-direction: column;
}

.brand-title {
    font-size: 1.8rem;
    font-weight: 700;
    color: #2c3e50;
    margin: 0;
    line-height: 1;
}

.brand-subtitle {
    font-size: 0.8rem;
    color: #6c757d;
    margin: 2px 0 0 0;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Menu Principal */
.navbar-menu {
    display: flex;
    align-items: center;
}

.navbar-nav-modern {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 5px;
}

.nav-item-modern {
    position: relative;
}

.nav-link-modern {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    text-decoration: none;
    color: #495057;
    font-weight: 500;
    border-radius: 12px;
    position: relative;
    overflow: hidden;
}

.nav-link-modern::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%);
    z-index: -1;
    opacity: 0;
}

.nav-link-modern:hover::before {
    opacity: 1;
}

.nav-link-modern:hover {
    color: #667eea;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.1);
}

.nav-icon {
    font-size: 1.1rem;
    opacity: 0.8;
}

.nav-text {
    font-size: 0.95rem;
}

/* Notification Badge */
.notification-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: linear-gradient(135deg, #ff416c 0%, #ff4b2b 100%);
    color: white;
    font-size: 0.7rem;
    font-weight: 600;
    padding: 3px 6px;
    border-radius: 10px;
    min-width: 18px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(255, 65, 108, 0.4);
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

/* User Section */
.navbar-user-section {
    display: flex;
    align-items: center;
    gap: 15px;
}

/* Notification Center */
.notification-center {
    position: relative;
}

.notification-btn {
    background: rgba(102, 126, 234, 0.1);
    border: none;
    width: 45px;
    height: 45px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    position: relative;
}

.notification-btn:hover {
    background: rgba(102, 126, 234, 0.2);
}

.notification-icon {
    font-size: 1.2rem;
}

.notification-dot {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 8px;
    height: 8px;
    background: #ff416c;
    border-radius: 50%;
    border: 2px solid white;
}

/* Notification Dropdown */
.notification-dropdown {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    width: 320px;
    background: white;
    border-radius: 15px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
    border: 1px solid rgba(0, 0, 0, 0.1);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 1001;
}

.notification-dropdown.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.notification-header {
    padding: 20px;
    border-bottom: 1px solid #e9ecef;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.notification-header h4 {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 600;
    color: #2c3e50;
}

.notification-count {
    background: #667eea;
    color: white;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 500;
}

.notification-list {
    max-height: 300px;
    overflow-y: auto;
}

.notification-item {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    padding: 15px 20px;
    border-bottom: 1px solid #f8f9fa;
    transition: all 0.3s ease;
}

.notification-item:hover {
    background: #f8f9fa;
}

.notification-item:last-child {
    border-bottom: none;
}

.notification-item-icon {
    font-size: 1.2rem;
    margin-top: 2px;
}

.notification-item-content strong {
    display: block;
    color: #2c3e50;
    margin-bottom: 5px;
    font-size: 0.9rem;
}

.notification-item-content p {
    margin: 0;
    color: #6c757d;
    font-size: 0.8rem;
    line-height: 1.4;
}

.notification-empty {
    text-align: center;
    padding: 40px 20px;
    color: #6c757d;
}

.empty-icon {
    font-size: 2rem;
    display: block;
    margin-bottom: 10px;
    opacity: 0.5;
}

/* User Menu */
.user-menu {
    position: relative;
}

.user-menu-btn {
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(102, 126, 234, 0.1);
    border: none;
    padding: 8px 15px;
    border-radius: 15px;
    cursor: pointer;
}

.user-menu-btn:hover {
    background: rgba(102, 126, 234, 0.2);
}

.user-avatar {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.avatar-text {
    color: white;
    font-weight: 600;
    font-size: 0.9rem;
}

.user-info {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.user-name {
    font-weight: 600;
    color: #2c3e50;
    font-size: 0.9rem;
    line-height: 1;
}

.user-role {
    font-size: 0.75rem;
    color: #6c757d;
    margin-top: 2px;
}

.dropdown-arrow {
    font-size: 0.7rem;
    color: #6c757d;
    transition: transform 0.3s ease;
}

.user-menu-btn.active .dropdown-arrow {
    transform: rotate(180deg);
}

/* User Dropdown */
.user-dropdown {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    width: 280px;
    background: white;
    border-radius: 15px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
    border: 1px solid rgba(0, 0, 0, 0.1);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 1001;
}

.user-dropdown.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.user-dropdown-header {
    padding: 20px;
    border-bottom: 1px solid #e9ecef;
    display: flex;
    align-items: center;
    gap: 15px;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.05) 0%, rgba(118, 75, 162, 0.05) 100%);
    border-radius: 15px 15px 0 0;
}

.user-avatar-large {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
}

.avatar-text-large {
    color: white;
    font-weight: 600;
    font-size: 1.1rem;
}

.user-details strong {
    display: block;
    color: #2c3e50;
    font-size: 1rem;
    margin-bottom: 2px;
}

.user-details span {
    color: #6c757d;
    font-size: 0.8rem;
}

.user-dropdown-menu {
    padding: 10px;
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 15px;
    text-decoration: none;
    color: #495057;
    border-radius: 10px;
    transition: all 0.3s ease;
    font-weight: 500;
}

.dropdown-item:hover {
    background: #f8f9fa;
    color: #667eea;
    transform: translateX(5px);
}

.dropdown-item.logout {
    color: #dc3545;
}

.dropdown-item.logout:hover {
    background: rgba(220, 53, 69, 0.1);
    color: #dc3545;
}

.dropdown-icon {
    font-size: 1rem;
    opacity: 0.8;
}

.dropdown-divider {
    height: 1px;
    background: #e9ecef;
    margin: 10px 0;
}

/* Mobile Menu Button */
.mobile-menu-btn {
    display: none;
    flex-direction: column;
    gap: 4px;
    background: rgba(102, 126, 234, 0.1);
    border: none;
    padding: 12px;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.mobile-menu-btn:hover {
    background: rgba(102, 126, 234, 0.2);
}

.hamburger-line {
    width: 20px;
    height: 2px;
    background: #495057;
    border-radius: 2px;
    transition: all 0.3s ease;
}

.mobile-menu-btn.active .hamburger-line:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.mobile-menu-btn.active .hamburger-line:nth-child(2) {
    opacity: 0;
}

.mobile-menu-btn.active .hamburger-line:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

/* Mobile Menu */
.mobile-menu {
    position: fixed;
    top: 80px;
    left: 0;
    right: 0;
    background: white;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transform: translateY(-100%);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 999;
    max-height: calc(100vh - 80px);
    overflow-y: auto;
}

.mobile-menu.show {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
}

.mobile-menu-header {
    padding: 20px;
    border-bottom: 1px solid #e9ecef;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.05) 0%, rgba(118, 75, 162, 0.05) 100%);
}

.mobile-user-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.mobile-avatar {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 1.1rem;
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
}

.mobile-user-details strong {
    display: block;
    color: #2c3e50;
    font-size: 1.1rem;
    margin-bottom: 2px;
}

.mobile-user-details span {
    color: #6c757d;
    font-size: 0.9rem;
}

.mobile-menu-items {
    padding: 20px;
}

.mobile-menu-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px 20px;
    text-decoration: none;
    color: #495057;
    border-radius: 12px;
    font-weight: 500;
    margin-bottom: 5px;
    position: relative;
}

.mobile-menu-item:hover {
    background: #f8f9fa;
    color: #667eea;
}

.mobile-menu-item.logout {
    color: #dc3545;
}

.mobile-menu-item.logout:hover {
    background: rgba(220, 53, 69, 0.1);
    color: #dc3545;
}

.mobile-icon {
    font-size: 1.2rem;
    opacity: 0.8;
    width: 20px;
    text-align: center;
}

.mobile-notification-badge {
    position: absolute;
    right: 20px;
    background: linear-gradient(135deg, #ff416c 0%, #ff4b2b 100%);
    color: white;
    font-size: 0.7rem;
    font-weight: 600;
    padding: 4px 8px;
    border-radius: 12px;
    min-width: 20px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(255, 65, 108, 0.4);
}

.mobile-menu-divider {
    height: 1px;
    background: #e9ecef;
    margin: 15px 0;
}

/* Navegação Antiga (Compatibilidade) */
.navbar {
    background: white;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    padding: 15px 0;
    margin-bottom: 30px;
}

.navbar-brand {
    font-size: 1.5rem;
    font-weight: 700;
    color: #667eea;
    text-decoration: none;
}

.navbar-nav {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    align-items: center;
}

.nav-item {
    margin-left: 20px;
}

.nav-link {
    color: #495057;
    text-decoration: none;
    font-weight: 500;
    padding: 8px 16px;
    border-radius: 6px;
    transition: all 0.3s ease;
}

.nav-link:hover {
    background: #f8f9fa;
    color: #667eea;
}

.nav-link.active {
    background: #667eea;
    color: white;
}

/* Tabelas */
.table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

.table th,
.table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #e9ecef;
}

.table th {
    background: #f8f9fa;
    font-weight: 600;
    color: #495057;
}

.table tbody tr:hover {
    background: #f8f9fa;
}

/* Alertas */
.alert {
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    border: 1px solid transparent;
}

.alert-success {
    background: #d4edda;
    border-color: #c3e6cb;
    color: #155724;
}

.alert-danger {
    background: #f8d7da;
    border-color: #f5c6cb;
    color: #721c24;
}

.alert-warning {
    background: #fff3cd;
    border-color: #ffeaa7;
    color: #856404;
}

.alert-info {
    background: #d1ecf1;
    border-color: #bee5eb;
    color: #0c5460;
}

/* Badge/Status */
.badge {
    display: inline-block;
    padding: 4px 8px;
    font-size: 0.75rem;
    font-weight: 500;
    border-radius: 4px;
    text-transform: uppercase;
}

.badge-success {
    background: #28a745;
    color: white;
}

.badge-danger {
    background: #dc3545;
    color: white;
}

.badge-warning {
    background: #ffc107;
    color: #212529;
}

.badge-info {
    background: #17a2b8;
    color: white;
}

/* Login Page */
.login-container {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 20px;
}

.login-card {
    width: 100%;
    max-width: 400px;
    background: white;
    border-radius: 15px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
    padding: 40px;
}

.login-header {
    text-align: center;
    margin-bottom: 30px;
}

.login-title {
    font-size: 2rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 10px;
}

.login-subtitle {
    color: #6c757d;
    font-size: 1rem;
}

/* Dashboard Stats */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: white;
    border-radius: 15px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    text-align: center;
    transition: transform 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-5px);
}

.stat-card.icon {
    position: relative;
    overflow: hidden;
}

.stat-icon {
    font-size: 2.5rem;
    margin-bottom: 10px;
    opacity: 0.8;
    text-align: center;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.stat-label {
    color: #6c757d;
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Barra de Progresso */
.progress-wrap {
    margin: 25px 0;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 10px;
    border-left: 4px solid #667eea;
}

.progress-label {
    font-weight: 600;
    color: #495057;
    margin-bottom: 10px;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.progress {
    background: #e9ecef;
    border-radius: 10px;
    height: 25px;
    overflow: hidden;
    position: relative;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.1);
}

.progress-bar {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    height: 100%;
    border-radius: 10px;
    transition: width 0.6s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 0.875rem;
    text-shadow: 0 1px 2px rgba(0,0,0,0.2);
    position: relative;
    overflow: hidden;
}

.progress-bar::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% { left: -100%; }
    100% { left: 100%; }
}

/* Melhorias nos Cards */
.card {
    position: relative;
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.card-header {
    position: relative;
}

.card-title {
    position: relative;
    display: inline-block;
}

.card-title::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 50px;
    height: 3px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 2px;
}

/* Hover effects para tabelas */
.table tbody tr {
    transition: all 0.3s ease;
}

.table tbody tr:hover {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    transform: translateX(5px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

/* Badges melhorados */
.badge {
    font-size: 0.75rem;
    padding: 6px 12px;
    border-radius: 20px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.badge-success {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
}

.badge-warning {
    background: linear-gradient(135deg, #ffc107 0%, #fd7e14 100%);
    color: #212529;
}

.badge-danger {
    background: linear-gradient(135deg, #dc3545 0%, #e83e8c 100%);
    color: white;
}

.badge-info {
    background: linear-gradient(135deg, #17a2b8 0%, #6f42c1 100%);
    color: white;
}

/* Stats cards com gradientes sutis */
.stat-card:nth-child(1) {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.08) 0%, rgba(118, 75, 162, 0.08) 100%);
}

.stat-card:nth-child(2) {
    background: linear-gradient(135deg, rgba(255, 193, 7, 0.08) 0%, rgba(253, 126, 20, 0.08) 100%);
}

.stat-card:nth-child(3) {
    background: linear-gradient(135deg, rgba(40, 167, 69, 0.08) 0%, rgba(32, 201, 151, 0.08) 100%);
}

.stat-card:nth-child(4) {
    background: linear-gradient(135deg, rgba(220, 53, 69, 0.08) 0%, rgba(232, 62, 140, 0.08) 100%);
}

/* Responsive - Header Moderno */
@media (max-width: 1024px) {
    .navbar-container {
        padding: 0 15px;
    }
    
    .brand-title {
        font-size: 1.6rem;
    }
    
    .nav-link-modern {
        padding: 10px 15px;
    }
    
    .nav-text {
        font-size: 0.9rem;
    }
}

@media (max-width: 768px) {
    .modern-navbar {
        height: 70px;
    }
    
    .navbar-container {
        height: 70px;
        padding: 0 15px;
    }
    
    /* Esconder menu desktop */
    .navbar-menu {
        display: none;
    }
    
    .navbar-user-section {
        display: none;
    }
    
    /* Mostrar botão mobile */
    .mobile-menu-btn {
        display: flex;
    }
    
    /* Ajustar brand para mobile */
    .brand-icon {
        width: 40px;
        height: 40px;
    }
    
    .icon-gradient {
        font-size: 1.4rem;
    }
    
    .brand-title {
        font-size: 1.4rem;
    }
    
    .brand-subtitle {
        font-size: 0.7rem;
    }
    
    /* Mobile menu ajustes */
    .mobile-menu {
        top: 70px;
        max-height: calc(100vh - 70px);
    }
    
    /* Dashboard container adjustment */
    .dashboard-container {
        padding: 15px;
        min-height: calc(100vh - 70px);
    }
    
    /* Dropdowns mobile-friendly */
    .notification-dropdown,
    .user-dropdown {
        width: calc(100vw - 40px);
        left: 20px;
        right: 20px;
        max-width: 350px;
    }
}

@media (max-width: 480px) {
    .navbar-container {
        padding: 0 10px;
    }
    
    .brand-text {
        display: none;
    }
    
    .brand-icon {
        width: 35px;
        height: 35px;
    }
    
    .icon-gradient {
        font-size: 1.2rem;
    }
    
    .mobile-menu-header {
        padding: 15px;
    }
    
    .mobile-menu-items {
        padding: 15px;
    }
    
    .mobile-menu-item {
        padding: 12px 15px;
    }
    
    .dashboard-container {
        padding: 10px;
    }
}

/* Responsive - Geral */
@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    .card {
        padding: 20px;
    }
    
    .stat-icon {
        font-size: 2rem;
    }
    
    .stat-number {
        font-size: 2rem;
    }
    
    .progress-wrap {
        padding: 15px;
    }
    
    .navbar-nav {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .nav-item {
        margin-left: 0;
        margin-top: 10px;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .btn {
        width: 100%;
        margin-right: 0;
    }
    
    /* KPI Grid responsivo */
    .kpi-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .kpi-card {
        padding: 20px;
    }
    
    .kpi-icon {
        font-size: 2.5rem;
    }
    
    .kpi-value {
        font-size: 2rem;
    }
    
    /* Widgets responsivo */
    .widgets-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .widget-content {
        padding: 20px;
    }
    
    /* Dashboard header responsivo */
    .dashboard-header {
        padding: 20px;
    }
    
    .header-content {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    
    .dashboard-title {
        font-size: 2rem;
    }
    
    .dashboard-subtitle {
        font-size: 1rem;
    }
    
    .header-meta {
        flex-wrap: wrap;
        gap: 10px;
    }
    
    .meta-item {
        font-size: 0.8rem;
        padding: 6px 12px;
    }
    
    .btn-cta {
        padding: 12px 25px;
        font-size: 0.9rem;
    }
}

/* Dashboard Executivo */
.dashboard-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
    background: #f8f9fa;
    min-height: calc(100vh - 80px);
}

.dashboard-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 20px;
    padding: 30px;
    margin-bottom: 30px;
    color: white;
    box-shadow: 0 10px 30px rgba(102, 126, 234, 0.3);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.dashboard-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin: 0 0 10px 0;
    text-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.dashboard-subtitle {
    font-size: 1.2rem;
    opacity: 0.9;
    margin: 0 0 15px 0;
}

.header-meta {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.meta-item {
    background: rgba(255,255,255,0.2);
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.9rem;
    backdrop-filter: blur(10px);
}

.status-ok { background: rgba(40, 167, 69, 0.3); }
.status-warning { background: rgba(255, 193, 7, 0.3); }

.btn-cta {
    background: white;
    color: #667eea;
    padding: 15px 30px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    transition: all 0.3s ease;
}

.btn-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.3);
    color: #667eea;
}

.btn-icon {
    font-size: 1.2rem;
}

/* Alert Banner */
.alert-banner {
    background: linear-gradient(135deg, #fff3cd 0%, #ffeaa7 100%);
    border: 1px solid #ffc107;
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 30px;
    box-shadow: 0 5px 15px rgba(255, 193, 7, 0.2);
}

.alert-content {
    display: flex;
    align-items: center;
    gap: 15px;
}

.alert-icon {
    font-size: 1.5rem;
}

.alert-text h4 {
    margin: 0 0 5px 0;
    color: #856404;
}

.alert-text p {
    margin: 0;
    color: #856404;
    opacity: 0.8;
}

/* KPI Grid */
.kpi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}

.kpi-card {
    background: white;
    border-radius: 20px;
    padding: 30px;
    display: flex;
    align-items: center;
    gap: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.kpi-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
}

.kpi-card.primary::before { background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); }
.kpi-card.success::before { background: linear-gradient(135deg, #28a745 0%, #20c997 100%); }
.kpi-card.info::before { background: linear-gradient(135deg, #17a2b8 0%, #6f42c1 100%); }
.kpi-card.warning::before { background: linear-gradient(135deg, #ffc107 0%, #fd7e14 100%); }

.kpi-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.15);
}

.kpi-icon {
    font-size: 3rem;
    opacity: 0.8;
}

.kpi-value {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 5px;
    color: #2c3e50;
}

.kpi-label {
    font-size: 1rem;
    color: #6c757d;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.kpi-trend {
    font-size: 0.85rem;
    font-weight: 500;
    padding: 4px 8px;
    border-radius: 12px;
}

.kpi-trend.positive { background: #d4edda; color: #155724; }
.kpi-trend.neutral { background: #e2e3e5; color: #383d41; }
.kpi-trend.negative { background: #f8d7da; color: #721c24; }

/* Widgets Grid */
.widgets-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 25px;
}

.widget {
    background: white;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
    overflow: hidden;
    transition: all 0.3s ease;
}

.widget:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.12);
}

.widget-header {
    padding: 25px 25px 0 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.widget-title {
    font-size: 1.3rem;
    font-weight: 600;
    color: #2c3e50;
    margin: 0;
}

/* Header Pro: breadcrumb + ações + chips */
.header-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 14px;
}

.breadcrumb {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--ds-text-muted);
    font-size: 0.95rem;
}
.breadcrumb a {
    color: var(--ds-text);
    text-decoration: none;
    font-weight: 500;
}
.breadcrumb a:hover { color: var(--ds-primary); }

.header-actions-pro {
    display: flex;
    align-items: center;
    gap: 10px;
}

.btn-soft {
    background: var(--ds-soft);
    border: 1px solid var(--ds-border);
    color: var(--ds-text);
    padding: 8px 12px;
    border-radius: 8px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}
.btn-soft:hover { filter: brightness(0.98); }

.btn-outline {
    background: #fff;
    border: 1px dashed var(--ds-primary);
    color: var(--ds-primary);
    padding: 8px 12px;
    border-radius: 8px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}
.btn-outline:hover { background: #f9fcff; }

.header-main-pro {
    background: var(--ds-surface);
    border: 1px solid var(--ds-border);
    border-radius: 12px;
    padding: 16px 18px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: var(--ds-shadow);
}

.filter-chips { display: flex; gap: 8px; flex-wrap: wrap; }

.chip {
    background: var(--ds-soft);
    color: var(--ds-text);
    border: 1px solid var(--ds-border);
    padding: 8px 12px;
    border-radius: 999px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
}
.chip.active {
    background: var(--ds-primary);
    border-color: var(--ds-primary);
    color: #fff;
    box-shadow: 0 2px 10px rgba(52,152,219,0.25);
}

@media (max-width: 768px) {
    .header-main-pro {
        flex-direction: column;
        gap: 12px;
        align-items: flex-start;
    }
}

/* Estilos para formulários da dashboard */
.action-card-financial-form {
    background: var(--ds-surface);
    border: 1px solid var(--ds-border);
    border-radius: 12px;
    padding: 16px 20px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    box-shadow: var(--ds-shadow);
}

.action-icon-form {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.action-icon-form.green-bg { background: linear-gradient(135deg, #27ae60, #2ecc71); }
.action-icon-form.blue-bg { background: linear-gradient(135deg, #3498db, #5dade2); }
.action-icon-form.orange-bg { background: linear-gradient(135deg, #e67e22, #f39c12); }

.action-content-form h3 {
    margin: 0 0 4px 0;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--ds-text);
}

.action-content-form p {
    margin: 0;
    font-size: 0.9rem;
    color: var(--ds-text-muted);
}

/* Autocomplete de contatos */
.suggestions-dropdown {
    background: var(--ds-surface);
    border: 1px solid var(--ds-border);
    border-radius: 10px;
    box-shadow: var(--ds-shadow);
    max-height: 260px;
    overflow-y: auto;
}

.suggestion-item {
    padding: 10px 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    border-bottom: 1px solid var(--ds-border);
}
.suggestion-item:last-child { border-bottom: 0; }
.suggestion-item:hover, .suggestion-item.active { background: var(--ds-soft); }
.sugg-name { font-weight: 600; color: var(--ds-text); }
.sugg-phone { font-size: 0.85rem; color: var(--ds-text-muted); margin-left: 12px; }

/* Estado de erro no input */
.input-error {
    border-color: #e74c3c !important;
    box-shadow: 0 0 0 3px rgba(231, 76, 60, 0.12) !important;
}

/* Seletor de contatos */
.select-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 12px;
    background: var(--ds-soft);
    border-radius: 6px;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--ds-text);
    margin-bottom: 4px;
    border-bottom: 1px solid var(--ds-border);
}

.contact-item {
    padding: 10px 12px;
    cursor: pointer;
    border-bottom: 1px solid var(--ds-border);
    transition: background-color 0.2s ease;
}

.contact-item:last-child {
    border-bottom: none;
}

.contact-item:hover,
.contact-item.active {
    background: var(--ds-soft);
}

.contact-name {
    font-weight: 600;
    color: var(--ds-text);
    font-size: 0.95rem;
}

.contact-phone {
    font-size: 0.85rem;
    color: var(--ds-text-muted);
    margin-top: 2px;
}

.no-contacts-message {
    padding: 16px;
    text-align: center;
    color: var(--ds-text-muted);
    font-size: 0.9rem;
}

.no-contacts-message i {
    color: var(--ds-primary);
    margin-right: 8px;
}

.no-contacts-message a {
    color: var(--ds-primary);
    text-decoration: none;
    font-weight: 600;
}

.no-contacts-message a:hover {
    text-decoration: underline;
}

/* Mensagem de nenhum resultado */
.no-results-message {
    padding: 16px;
    text-align: center;
    color: var(--ds-text-muted);
    font-size: 0.9rem;
}

.no-results-message i {
    color: var(--ds-text-muted);
    margin-right: 8px;
}

/* Destaque do texto pesquisado */
.contact-name mark,
.contact-phone mark {
    background: rgba(52, 152, 219, 0.2);
    color: var(--ds-primary);
    padding: 1px 2px;
    border-radius: 3px;
    font-weight: 700;
}

/* Wrapper do input de contato com botão limpar */
.contact-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.contact-input-wrapper .form-control {
    padding-right: 35px; /* Espaço para o botão circular */
}

.clear-contact-btn {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: linear-gradient(135deg, #e74c3c, #c0392b);
    border: none;
    color: white;
    cursor: pointer;
    padding: 0;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    font-size: 10px;
    box-shadow: 0 2px 6px rgba(231, 76, 60, 0.25);
    transition: all 0.2s ease;
    z-index: 10;
}

.clear-contact-btn:hover {
    background: linear-gradient(135deg, #c0392b, #a93226);
    transform: translateY(-50%) scale(1.1);
    box-shadow: 0 3px 10px rgba(231, 76, 60, 0.4);
}

.clear-contact-btn:active {
    transform: translateY(-50%) scale(0.95);
}

/* Animação de entrada do botão */
@keyframes slideInScale {
    0% {
        opacity: 0;
        transform: translateY(-50%) scale(0);
    }
    50% {
        opacity: 1;
        transform: translateY(-50%) scale(1.2);
    }
    100% {
        opacity: 1;
        transform: translateY(-50%) scale(1);
    }
}

.clear-contact-btn {
    animation: slideInScale 0.3s ease-out;
}

/* Estado do input quando contato está selecionado */
.form-control.contact-selected {
    background: rgba(39, 174, 96, 0.05);
    border-color: #27ae60;
    color: var(--ds-text);
    font-weight: 600;
}

.form-control.contact-selected:focus {
    box-shadow: 0 0 0 3px rgba(39, 174, 96, 0.12);
    border-color: #27ae60;
}

/* Paginação */
.pagination-wrapper {
    margin-top: 30px;
    padding: 20px 0;
    border-top: 1px solid var(--ds-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
}

.pagination-info {
    color: var(--ds-text-muted);
    font-size: 0.9rem;
}

.pagination {
    display: flex;
    align-items: center;
    gap: 8px;
}

.pagination-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    background: var(--ds-surface);
    border: 1px solid var(--ds-border);
    border-radius: 8px;
    color: var(--ds-text);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.2s ease;
}

.pagination-btn:hover {
    background: var(--ds-soft);
    border-color: var(--ds-primary);
    color: var(--ds-primary);
}

.pagination-number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: var(--ds-surface);
    border: 1px solid var(--ds-border);
    border-radius: 8px;
    color: var(--ds-text);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.2s ease;
}

.pagination-number:hover {
    background: var(--ds-soft);
    border-color: var(--ds-primary);
    color: var(--ds-primary);
}

.pagination-number.active {
    background: var(--ds-primary);
    border-color: var(--ds-primary);
    color: white;
}

.pagination-dots {
    padding: 0 4px;
    color: var(--ds-text-muted);
    font-weight: bold;
}

/* Responsividade da paginação */
@media (max-width: 768px) {
    .pagination-wrapper {
        flex-direction: column;
        text-align: center;
    }
    
    .pagination {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .pagination-btn {
        font-size: 0.8rem;
        padding: 6px 10px;
    }
    
    .pagination-number {
        width: 32px;
        height: 32px;
        font-size: 0.8rem;
    }
}

/* Badge de configuração */
.config-badge {
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    margin-left: auto;
}

.config-badge.configured {
    background: rgba(39, 174, 96, 0.1);
    color: #27ae60;
    border: 1px solid rgba(39, 174, 96, 0.2);
}

.config-badge.not-configured {
    background: rgba(230, 126, 34, 0.1);
    color: #e67e22;
    border: 1px solid rgba(230, 126, 34, 0.2);
}

/* Botão de logout no header */
.logout-section {
    margin-left: 16px;
}

.logout-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: rgba(231, 76, 60, 0.1);
    border: 1px solid rgba(231, 76, 60, 0.2);
    border-radius: 8px;
    color: #e74c3c;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.2s ease;
}

.logout-btn:hover {
    background: rgba(231, 76, 60, 0.15);
    border-color: rgba(231, 76, 60, 0.3);
    color: #c0392b;
    transform: translateY(-1px);
}

.logout-icon {
    font-size: 1rem;
}

.logout-text {
    font-weight: 600;
}

@media (max-width: 768px) {
    .logout-section {
        margin-left: 8px;
    }
    
    .logout-btn {
        padding: 6px 12px;
        font-size: 0.8rem;
    }
    
    .logout-text {
        display: none;
    }
}

/* Layout da página de configurações */
.settings-main {
    display: flex;
    flex-direction: column;
    gap: 24px;
    width: 100%;
}

.settings-main .settings-card {
    width: 100%;
    max-width: none;
    flex: 1;
}

.settings-main .main-config,
.settings-main .password-config {
    width: 100%;
    box-sizing: border-box;
}

.settings-main .card-header {
    padding: 20px 24px 0;
    border-bottom: 1px solid #e9ecef;
    margin-bottom: 24px;
}

.settings-main .card-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #2c3e50;
    margin: 0 0 8px 0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.settings-main .card-title i {
    color: #3498db;
}

.settings-main .card-description {
    color: #6c757d;
    margin: 0;
    font-size: 0.9rem;
}

/* Login Page Modern Design */
.login-body {
    margin: 0;
    padding: 0;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    overflow-x: hidden;
}

.login-container-modern {
    display: flex;
    min-height: 100vh;
    position: relative;
    flex-direction: row-reverse;
}

/* Background decorativo */
.login-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: 1;
}

.bg-shape {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
}

.shape-1 {
    width: 300px;
    height: 300px;
    top: -150px;
    right: -150px;
    animation: float 6s ease-in-out infinite;
}

.shape-2 {
    width: 200px;
    height: 200px;
    bottom: -100px;
    left: -100px;
    animation: float 8s ease-in-out infinite reverse;
}

.shape-3 {
    width: 150px;
    height: 150px;
    top: 50%;
    left: 10%;
    animation: float 10s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
}

/* Card principal */
.login-card-modern {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border-radius: 0;
    padding: 48px 64px;
    width: 50%;
    min-height: 100vh;
    box-shadow: -10px 0 30px rgba(0, 0, 0, 0.1);
    position: relative;
    z-index: 10;
    border: none;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    border-left: 1px solid rgba(255, 255, 255, 0.2);
}

/* Container do conteúdo principal */
.login-main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Header com logo */
.login-header-modern {
    text-align: center;
    margin-bottom: 40px;
}

.login-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
}

.logo-icon {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 28px;
    box-shadow: 0 8px 24px rgba(102, 126, 234, 0.3);
}

.logo-text {
    font-size: 28px;
    font-weight: 700;
    color: #2c3e50;
    margin: 0 0 24px 0;
    background: linear-gradient(135deg, #667eea, #764ba2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-align: center;
}


.login-description {
    font-size: 16px;
    color: #6c757d;
    margin: 0;
}

/* Alertas modernos */
.alert-modern {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
    border-radius: 12px;
    margin-bottom: 24px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.alert-error {
    background: rgba(231, 76, 60, 0.1);
    border: 1px solid rgba(231, 76, 60, 0.2);
    color: #e74c3c;
}

.alert-success {
    background: rgba(39, 174, 96, 0.1);
    border: 1px solid rgba(39, 174, 96, 0.2);
    color: #27ae60;
}

/* Formulário moderno */
.login-form-modern {
    margin-bottom: 32px;
}

.input-group-modern {
    position: relative;
    margin-bottom: 24px;
}

.input-icon {
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    color: #6c757d;
    font-size: 18px;
    z-index: 2;
    transition: all 0.3s ease;
}

.input-modern {
    width: 100%;
    padding: 20px 20px 20px 56px;
    border: 2px solid #e9ecef;
    border-radius: 16px;
    font-size: 16px;
    background: rgba(255, 255, 255, 0.8);
    transition: all 0.3s ease;
    outline: none;
    box-sizing: border-box;
}

.input-modern:focus {
    border-color: #667eea;
    background: rgba(255, 255, 255, 0.95);
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
}

.input-label {
    position: absolute;
    top: -8px;
    left: 16px;
    font-size: 12px;
    color: #667eea;
    background: rgba(255, 255, 255, 0.9);
    padding: 0 8px;
    pointer-events: none;
    transition: all 0.3s ease;
    font-weight: 500;
}

.input-group-modern.focused .input-icon,
.input-modern:focus ~ .input-icon {
    color: #667eea;
}

.password-toggle {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #6c757d;
    font-size: 18px;
    cursor: pointer;
    padding: 8px;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.password-toggle:hover {
    color: #667eea;
    background: rgba(102, 126, 234, 0.1);
}

/* Botão moderno */
.btn-login-modern {
    width: 100%;
    padding: 20px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    border: none;
    border-radius: 16px;
    color: white;
    font-size: 18px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    box-shadow: 0 8px 24px rgba(102, 126, 234, 0.3);
}

.btn-login-modern:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 32px rgba(102, 126, 234, 0.4);
}

.btn-login-modern:active {
    transform: translateY(0);
}

.btn-login-modern.loading {
    opacity: 0.8;
    cursor: not-allowed;
}

.btn-icon {
    transition: transform 0.3s ease;
}

.btn-login-modern:hover .btn-icon {
    transform: translateX(4px);
}

/* Seção de Suporte WhatsApp */
.support-section {
    margin-top: 24px;
    padding-top: 0;
}

.support-divider {
    text-align: center;
    margin-bottom: 20px;
    position: relative;
}

.support-divider span {
    background: rgba(255, 255, 255, 0.95);
    padding: 0 16px;
    color: #6c757d;
    font-size: 14px;
    font-weight: 500;
}

.support-divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: rgba(0, 0, 0, 0.1);
}

.whatsapp-support-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    width: 100%;
    padding: 16px 20px;
    background: linear-gradient(135deg, #25d366, #128c7e);
    border: none;
    border-radius: 16px;
    color: white;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.3);
}

.whatsapp-support-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(37, 211, 102, 0.4);
    text-decoration: none;
    color: white;
}

.whatsapp-support-btn:active {
    transform: translateY(0);
}

.whatsapp-support-btn i {
    font-size: 20px;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
    100% {
        transform: scale(1);
    }
}

/* Footer moderno */
.login-footer-modern {
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    padding-top: 24px;
}

.divider {
    text-align: center;
    margin-bottom: 20px;
    position: relative;
}

.divider span {
    background: rgba(255, 255, 255, 0.95);
    padding: 0 16px;
    color: #6c757d;
    font-size: 14px;
    font-weight: 500;
}

.divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: rgba(0, 0, 0, 0.1);
}

.test-credentials {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.credential-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: rgba(102, 126, 234, 0.05);
    border-radius: 12px;
    font-size: 14px;
}

.credential-item i {
    color: #667eea;
    width: 16px;
}

.credential-note {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: rgba(52, 152, 219, 0.05);
    border-radius: 12px;
    font-size: 14px;
    color: #3498db;
}

.credential-note i {
    color: #3498db;
    width: 16px;
}

/* Painel lateral */
.login-info-panel {
    width: 50%;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    padding: 48px 64px;
    position: relative;
    z-index: 5;
    min-height: 100vh;
}

.info-content {
    max-width: 400px;
    color: white;
    text-align: left;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Créditos do desenvolvedor */
.developer-credits {
    text-align: center;
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
    margin-top: auto;
}

/* Créditos do desenvolvedor - Área Admin */
body:not(.login-body) .developer-credits {
    background: #ffffff;
    padding: 20px;
    margin-top: 40px;
    color: #6c757d;
}

body:not(.login-body) .developer-credits strong {
    color: #495057;
}

body:not(.login-body) .version-info {
    color: #6c757d !important;
    font-size: 12px !important;
}


.developer-credits p {
    margin: 0;
    font-weight: 400;
}

.developer-credits strong {
    color: rgba(255, 255, 255, 0.9);
    font-weight: 600;
}

.version-info {
    font-size: 12px !important;
    color: rgba(255, 255, 255, 0.5) !important;
    margin-top: 4px !important;
    font-weight: 400 !important;
}

.info-content h2 {
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 16px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.info-content p {
    font-size: 18px;
    margin-bottom: 32px;
    opacity: 0.9;
    line-height: 1.6;
}

.features-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
    text-align: left;
}

.feature-item {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    font-size: 16px;
    opacity: 0.9;
    margin-bottom: 24px;
}

.feature-item > div {
    flex: 1;
}

.feature-item span {
    display: block;
    margin-bottom: 4px;
    font-weight: 500;
}

.feature-item small {
    display: block;
    font-size: 13px;
    font-weight: 400;
    opacity: 0.8;
    line-height: 1.4;
}

.feature-item i {
    color: #4ade80;
    font-size: 18px;
    width: 20px;
    margin-top: 2px;
    flex-shrink: 0;
}

/* Estatísticas do painel lateral */
.info-stats {
    display: flex;
    justify-content: space-between;
    margin-top: 40px;
    padding-top: 32px;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
}

.stat-item {
    text-align: center;
    flex: 1;
}

.stat-number {
    font-size: 24px;
    font-weight: 700;
    color: #4ade80;
    margin-bottom: 4px;
}

.stat-label {
    font-size: 12px;
    opacity: 0.8;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Responsividade */
@media (max-width: 1024px) {
    .login-body {
        background: #ffffff;
    }
    
    .login-container-modern {
        flex-direction: column;
        min-height: 100vh;
    }
    
    .login-background {
        display: none;
    }
    
    .login-info-panel {
        display: none;
    }
    
    .login-card-modern {
        width: 100%;
        min-height: 100vh;
        order: 1;
        border-left: none;
        box-shadow: none;
        background: #ffffff;
        backdrop-filter: none;
    }
}

@media (max-width: 768px) {
    .login-card-modern {
        padding: 32px 24px;
        min-height: 100vh;
        background: #ffffff;
        justify-content: flex-start;
        align-items: center;
        padding-top: 10vh;
        padding-bottom: 10vh;
    }
    
    .login-main-content {
        width: 100%;
        max-width: 400px;
        margin: 0 auto;
        flex: none;
    }
    
    .login-header-modern {
        text-align: center;
    }
    
    .logo-text {
        font-size: 24px;
    }
    
    .input-modern {
        padding: 16px 16px 16px 48px;
    }
    
    .input-icon {
        left: 16px;
        font-size: 16px;
    }
    
    .input-label {
        left: 48px;
    }
    
    .btn-login-modern {
        padding: 16px;
        font-size: 16px;
    }
    
    .whatsapp-support-btn {
        padding: 14px 16px;
        font-size: 15px;
    }
    
    .whatsapp-support-btn i {
        font-size: 18px;
    }
    
    .support-section {
        margin-top: 48px;
        padding-top: 0;
        text-align: center;
    }
    
    .whatsapp-support-btn {
        width: 100%;
        margin: 0;
    }
}

.widget-badge {
    background: #667eea;
    color: white;
    padding: 4px 12px;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 600;
}

.widget-content {
    padding: 25px;
}

/* Timeline */
.timeline {
    position: relative;
}

.timeline-item {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid #e9ecef;
}

.timeline-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.timeline-time {
    background: #667eea;
    color: white;
    padding: 8px 12px;
    border-radius: 15px;
    font-size: 0.85rem;
    font-weight: 600;
    min-width: 60px;
    text-align: center;
}

.timeline-content strong {
    color: #2c3e50;
    display: block;
    margin-bottom: 5px;
}

.timeline-content p {
    color: #6c757d;
    margin: 0;
    font-size: 0.9rem;
}

/* Ranking List */
.ranking-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.ranking-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 12px;
    transition: all 0.3s ease;
}

.ranking-item:hover {
    background: #e9ecef;
    transform: translateX(5px);
}

.ranking-position {
    background: #667eea;
    color: white;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.9rem;
}

.ranking-info {
    flex: 1;
}

.ranking-info strong {
    display: block;
    color: #2c3e50;
    margin-bottom: 2px;
}

.ranking-info small {
    color: #6c757d;
    font-size: 0.8rem;
}

.ranking-value {
    background: #28a745;
    color: white;
    padding: 6px 12px;
    border-radius: 15px;
    font-weight: 600;
    font-size: 0.9rem;
}

/* Quick Actions */
.quick-actions {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
}

.quick-action {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 15px;
    text-decoration: none;
    color: #2c3e50;
    transition: all 0.3s ease;
}

.quick-action:hover {
    background: #667eea;
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.3);
}

.action-icon {
    font-size: 2rem;
}

.action-label {
    font-weight: 600;
    font-size: 0.9rem;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: #6c757d;
}

.empty-icon {
    font-size: 3rem;
    display: block;
    margin-bottom: 15px;
    opacity: 0.5;
}

.empty-state p {
    margin: 0;
    font-size: 1rem;
}

/* Chart Widget */
.chart-widget .widget-content {
    height: 300px;
    position: relative;
}

.btn-icon {
    background: none;
    border: none;
    font-size: 1.2rem;
    cursor: pointer;
    padding: 5px;
    border-radius: 5px;
    transition: all 0.3s ease;
}

.btn-icon:hover {
    background: #f8f9fa;
}

/* Utilities */
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-left { text-align: left; }
.mt-3 { margin-top: 1rem; }
.mb-3 { margin-bottom: 1rem; }
.ml-3 { margin-left: 1rem; }
.mr-3 { margin-right: 1rem; }
.p-3 { padding: 1rem; }
.d-flex { display: flex; }
.justify-content-between { justify-content: space-between; }
.align-items-center { align-items: center; }
.w-100 { width: 100%; }

/* Loading */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255,255,255,.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 1s ease-in-out infinite;
}

/* ===== PÁGINA DE MENSAGENS ===== */

/* Container Principal */
.messages-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    background: #f8f9fa;
    min-height: calc(100vh - 80px);
}

/* Header da Página */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 30px;
    gap: 30px;
}

.header-info {
    flex: 1;
}

.page-title {
    font-size: 2.2rem;
    font-weight: 700;
    color: #2c3e50;
    margin: 0 0 8px 0;
    display: flex;
    align-items: center;
    gap: 15px;
}

.page-title i {
    color: #667eea;
    font-size: 2rem;
}

.page-subtitle {
    color: #6c757d;
    font-size: 1.1rem;
    margin: 0;
}

.header-stats {
    display: flex;
    gap: 15px;
}

.stat-card {
    background: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
    display: flex;
    align-items: center;
    gap: 15px;
    min-width: 120px;
}

.stat-icon {
    width: 50px;
    height: 50px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: white;
}

.stat-card.pendentes .stat-icon {
    background: linear-gradient(135deg, #ffc107 0%, #ff8c00 100%);
}

.stat-card.enviadas .stat-icon {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
}

.stat-card.erros .stat-icon {
    background: linear-gradient(135deg, #dc3545 0%, #e83e8c 100%);
}

.stat-info {
    display: flex;
    flex-direction: column;
}

.stat-number {
    font-size: 1.8rem;
    font-weight: 700;
    color: #2c3e50;
    line-height: 1;
}

.stat-label {
    font-size: 0.9rem;
    color: #6c757d;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 2px;
}

/* Formulário de Mensagem */
.message-form-container {
    background: white;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    margin-bottom: 30px;
    overflow: hidden;
}

.form-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 25px 30px;
}

.form-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin: 0 0 5px 0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.form-subtitle {
    margin: 0;
    opacity: 0.9;
    font-size: 0.95rem;
}

.message-form {
    padding: 30px;
}

.form-row {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
}

.form-row .form-group {
    flex: 1;
}

.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 8px;
    font-weight: 600;
    color: #495057;
    font-size: 0.95rem;
}

.form-label i {
    color: #667eea;
    width: 16px;
}

.char-counter {
    font-size: 0.8rem;
    color: #6c757d;
    font-weight: normal;
}

.form-control {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 1rem;
    background: #f8f9fa;
}

.form-control:focus {
    outline: none;
    border-color: #667eea;
    background: white;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.form-control textarea {
    resize: vertical;
    min-height: 100px;
}

.form-actions {
    display: flex;
    gap: 15px;
    justify-content: flex-end;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #e9ecef;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

.btn-secondary {
    background: #6c757d;
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}

.btn-secondary:hover {
    background: #5a6268;
    color: white;
}

/* Lista de Mensagens */
.messages-list-container {
    background: white;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    overflow: hidden;
}

.list-header {
    background: #f8f9fa;
    padding: 25px 30px;
    border-bottom: 1px solid #e9ecef;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

.list-title {
    font-size: 1.4rem;
    font-weight: 600;
    color: #2c3e50;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.list-title i {
    color: #667eea;
}

.list-actions {
    display: flex;
    gap: 15px;
    align-items: center;
}

.search-box {
    position: relative;
    display: flex;
    align-items: center;
}

.search-box i {
    position: absolute;
    left: 12px;
    color: #6c757d;
    z-index: 1;
}

.search-box input {
    padding: 10px 15px 10px 35px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 0.9rem;
    background: white;
    min-width: 250px;
}

.search-box input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.filter-select {
    padding: 10px 15px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    background: white;
    font-size: 0.9rem;
    cursor: pointer;
}

.filter-select:focus {
    outline: none;
    border-color: #667eea;
}

/* Lista de Mensagens em Tabela */
.messages-table-container {
    padding: 0;
}

.messages-table-header {
    display: flex;
    background: #f8f9fa;
    border-bottom: 2px solid #e9ecef;
    font-weight: 600;
    color: #495057;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.header-col {
    padding: 15px 20px;
    display: flex;
    align-items: center;
}

.header-col.contact {
    flex: 2.5;
    min-width: 200px;
}

.header-col.message {
    flex: 3;
    min-width: 250px;
}

.header-col.schedule {
    flex: 1.5;
    min-width: 120px;
}

.header-col.status {
    flex: 1.2;
    min-width: 100px;
}

.header-col.actions {
    flex: 1;
    min-width: 120px;
    justify-content: center;
}

.message-row {
    display: flex;
    border-bottom: 1px solid #f1f3f4;
    align-items: center;
    background: white;
}

.message-row:hover {
    background: #f8f9fa;
}

.message-row:last-child {
    border-bottom: none;
}

.row-col {
    padding: 15px 20px;
    display: flex;
    align-items: center;
}

.row-col.contact {
    flex: 2.5;
    min-width: 200px;
}

.row-col.message {
    flex: 3;
    min-width: 250px;
}

.row-col.schedule {
    flex: 1.5;
    min-width: 120px;
}

.row-col.status {
    flex: 1.2;
    min-width: 100px;
}

.row-col.actions {
    flex: 1;
    min-width: 120px;
    justify-content: center;
}

.contact-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.contact-avatar {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.contact-details {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.contact-name {
    font-size: 0.95rem;
    font-weight: 600;
    color: #2c3e50;
}

.contact-phone {
    font-size: 0.8rem;
    color: #6c757d;
}

.message-preview {
    color: #495057;
    line-height: 1.4;
    cursor: pointer;
    word-wrap: break-word;
}

.message-preview:hover {
    color: #667eea;
    text-decoration: underline;
}

.schedule-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.schedule-date {
    font-size: 0.9rem;
    font-weight: 600;
    color: #2c3e50;
}

.schedule-time {
    font-size: 0.8rem;
    color: #6c757d;
}

.status-badge {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.status-pending {
    background: #fff3cd;
    color: #856404;
    border: 1px solid #ffeaa7;
}

.status-sent {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.status-error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.error-tooltip {
    margin-top: 5px;
    color: #dc3545;
    cursor: help;
    font-size: 0.8rem;
}

.message-actions {
    display: flex;
    gap: 6px;
    justify-content: center;
}

.action-btn {
    width: 32px;
    height: 32px;
    border: none;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 0.85rem;
    color: white;
}

.action-btn.edit {
    background: #17a2b8;
}

.action-btn.edit:hover {
    background: #138496;
}

.action-btn.delete {
    background: #dc3545;
}

.action-btn.delete:hover {
    background: #c82333;
}

.action-btn.view {
    background: #6c757d;
}

.action-btn.view:hover {
    background: #5a6268;
}

.action-btn.info {
    background: #ffc107;
    color: #212529;
}

.action-btn.info:hover {
    background: #e0a800;
}

.error-info {
    padding: 15px 20px;
    background: #f8d7da;
    border-top: 1px solid #f5c6cb;
    color: #721c24;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.error-info i {
    color: #dc3545;
}

/* Estado Vazio */
.empty-state {
    text-align: center;
    padding: 60px 30px;
    color: #6c757d;
}

.empty-icon {
    font-size: 4rem;
    opacity: 0.3;
    margin-bottom: 20px;
}

.empty-state h3 {
    font-size: 1.4rem;
    color: #495057;
    margin-bottom: 10px;
}

.empty-state p {
    font-size: 1rem;
    margin: 0;
}

/* Modal */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    backdrop-filter: blur(5px);
}

.modal-content {
    background: white;
    border-radius: 15px;
    width: 90%;
    max-width: 500px;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
}

.modal-header {
    padding: 20px 25px;
    border-bottom: 1px solid #e9ecef;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f8f9fa;
}

.modal-title {
    font-size: 1.3rem;
    font-weight: 600;
    color: #2c3e50;
    margin: 0;
}

.modal-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: #6c757d;
    cursor: pointer;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover {
    background: #e9ecef;
    color: #495057;
}

.modal-body {
    padding: 25px;
}

.modal-contact {
    margin-bottom: 15px;
    font-size: 1rem;
    color: #495057;
}

.modal-message {
    color: #2c3e50;
    line-height: 1.6;
}

.error-message {
    color: #721c24;
    background: #f8d7da;
    padding: 15px;
    border-radius: 8px;
    border: 1px solid #f5c6cb;
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Responsividade - Mensagens */
@media (max-width: 768px) {
    .messages-container {
        padding: 15px;
    }
    
    .page-header {
        flex-direction: column;
        gap: 20px;
        align-items: stretch;
    }
    
    .header-stats {
        justify-content: center;
        flex-wrap: wrap;
    }
    
    .stat-card {
        min-width: 100px;
        padding: 15px;
    }
    
    .stat-icon {
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
    }
    
    .stat-number {
        font-size: 1.5rem;
    }
    
    .form-header {
        padding: 20px;
    }
    
    .message-form {
        padding: 20px;
    }
    
    .form-row {
        flex-direction: column;
        gap: 0;
    }
    
    .form-actions {
        flex-direction: column;
    }
    
    .btn-primary,
    .btn-secondary {
        width: 100%;
        justify-content: center;
    }
    
    .list-header {
        flex-direction: column;
        gap: 15px;
        align-items: stretch;
        padding: 20px;
    }
    
    .list-actions {
        flex-direction: column;
        gap: 10px;
    }
    
    .search-box input {
        min-width: auto;
        width: 100%;
    }
    
    .messages-table-header {
        display: none;
    }
    
    .message-row {
        flex-direction: column;
        align-items: stretch;
        padding: 15px;
        gap: 12px;
        border-radius: 8px;
        margin-bottom: 10px;
        box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    }
    
    .row-col {
        padding: 0;
        flex-direction: column;
        align-items: stretch;
    }
    
    .row-col.contact {
        order: 1;
    }
    
    .row-col.message {
        order: 2;
    }
    
    .row-col.schedule {
        order: 3;
    }
    
    .row-col.status {
        order: 4;
    }
    
    .row-col.actions {
        order: 5;
        margin-top: 10px;
        padding-top: 10px;
        border-top: 1px solid #e9ecef;
    }
    
    .contact-info {
        justify-content: flex-start;
    }
    
    .schedule-info {
        flex-direction: row;
        gap: 15px;
        justify-content: flex-start;
    }
    
    .message-actions {
        justify-content: flex-start;
    }
}

@media (max-width: 480px) {
    .page-title {
        font-size: 1.8rem;
    }
    
    .header-stats {
        grid-template-columns: 1fr;
    }
    
    .stat-card {
        padding: 12px;
    }
    
    .contact-avatar {
        width: 35px;
        height: 35px;
        font-size: 0.9rem;
    }
    
    .contact-name {
        font-size: 0.95rem;
    }
    
    .action-btn {
        width: 28px;
        height: 28px;
        font-size: 0.75rem;
    }
    
    .modal-content {
        width: 95%;
        margin: 20px;
    }
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ===== PÁGINA DE CONFIGURAÇÕES ===== */

/* Container Principal */
.settings-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    background: #f8f9fa;
    min-height: calc(100vh - 80px);
}

/* Header da Página */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding: 25px 30px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 15px;
    color: white;
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
}

.header-info {
    flex: 1;
}

.page-title {
    font-size: 2rem;
    font-weight: 700;
    margin: 0 0 8px 0;
    display: flex;
    align-items: center;
    gap: 15px;
}

.page-title i {
    font-size: 1.8rem;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.2));
}

.page-subtitle {
    font-size: 1.1rem;
    opacity: 0.9;
    margin: 0;
}

.header-status {
    display: flex;
    align-items: center;
}

.connection-status {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(255,255,255,0.2);
    padding: 12px 20px;
    border-radius: 25px;
    backdrop-filter: blur(10px);
    font-weight: 500;
}

.status-icon {
    font-size: 0.8rem;
}

.status-connected {
    color: #28a745;
}

.status-disconnected {
    color: #dc3545;
}

.status-unknown {
    color: #ffc107;
}

/* Grid de Configurações */
.settings-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 30px;
    margin-top: 30px;
}

/* Cards de Configuração */
.settings-card {
    background: white;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    overflow: hidden;
}

.settings-card .card-header {
    padding: 25px 30px 20px;
    border-bottom: 1px solid #e9ecef;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.header-content {
    flex: 1;
}

.settings-card .card-title {
    font-size: 1.3rem;
    font-weight: 600;
    color: #2c3e50;
    margin: 0 0 8px 0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.settings-card .card-title i {
    color: #667eea;
    font-size: 1.2rem;
}

.card-description {
    color: #6c757d;
    font-size: 0.95rem;
    margin: 0;
}

.config-status {
    flex-shrink: 0;
}

.config-badge {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.config-badge.configured {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.config-badge.not-configured {
    background: #fff3cd;
    color: #856404;
    border: 1px solid #ffeaa7;
}

/* Formulário Principal */
.main-config {
    grid-column: 1;
}

.config-form {
    padding: 30px;
}

.form-section {
    margin-bottom: 30px;
}

.form-group {
    margin-bottom: 25px;
}

.form-label {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    font-weight: 600;
    color: #495057;
    font-size: 0.95rem;
}

.form-label i {
    color: #667eea;
    width: 16px;
}

.required {
    color: #dc3545;
    font-weight: 700;
}

.input-group {
    display: flex;
    position: relative;
}

.form-control {
    flex: 1;
    padding: 12px 15px;
    border: 2px solid #e9ecef;
    border-radius: 8px 0 0 8px;
    font-size: 1rem;
    background: #f8f9fa;
}

.form-control:focus {
    outline: none;
    border-color: #667eea;
    background: white;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.form-control.error {
    border-color: #dc3545;
    background: #fff5f5;
}

.form-control.valid {
    border-color: #28a745;
    background: #f8fff8;
}

.input-btn {
    background: #667eea;
    color: white;
    border: none;
    padding: 12px 15px;
    border-radius: 0 8px 8px 0;
    cursor: pointer;
    border-left: 1px solid #5a6fd8;
}

.input-btn:hover {
    background: #5a6fd8;
}

.form-help {
    color: #6c757d;
    font-size: 0.85rem;
    margin-top: 5px;
    display: block;
}

.form-actions {
    display: flex;
    gap: 15px;
    justify-content: flex-end;
    padding-top: 20px;
    border-top: 1px solid #e9ecef;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

.btn-secondary {
    background: #6c757d;
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-secondary:hover {
    background: #5a6268;
}

/* Sidebar de Informações */
.settings-sidebar {
    grid-column: 2;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* Card de Estatísticas */
.stats-card .stats-grid {
    padding: 20px 30px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.stats-grid .stat-item {
    display: flex;
    align-items: center;
    gap: 12px;
}

.stat-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: white;
    flex-shrink: 0;
}

.stat-icon.messages {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.stat-icon.uptime {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
}

.stat-info {
    display: flex;
    flex-direction: column;
}

.stat-number {
    font-size: 1.4rem;
    font-weight: 700;
    color: #2c3e50;
    line-height: 1;
}

.stat-label {
    font-size: 0.8rem;
    color: #6c757d;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 2px;
}

/* Card de Status */
.status-card .status-info {
    padding: 20px 30px;
}

.status-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #f1f3f4;
}

.status-item:last-child {
    border-bottom: none;
}

.status-label {
    font-weight: 500;
    color: #495057;
}

.status-value {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
    color: #6c757d;
}

.btn-test {
    background: #17a2b8;
    color: white;
    border: none;
    padding: 12px 20px;
    margin: 20px 30px 30px;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-test:hover {
    background: #138496;
}

/* Card de Ajuda */
.help-card .help-content {
    padding: 20px 30px;
}

.help-step {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
}

.help-step:last-child {
    margin-bottom: 0;
}

.step-number {
    width: 30px;
    height: 30px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.step-content h4 {
    font-size: 1rem;
    font-weight: 600;
    color: #2c3e50;
    margin: 0 0 5px 0;
}

.step-content p {
    font-size: 0.9rem;
    color: #6c757d;
    margin: 0;
    line-height: 1.4;
}

.help-link {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 15px 30px;
    background: #f8f9fa;
    color: #667eea;
    text-decoration: none;
    font-weight: 500;
    border-top: 1px solid #e9ecef;
}

.help-link:hover {
    background: #e9ecef;
    color: #5a6fd8;
}

/* Card de Logs */
.logs-card .logs-content {
    padding: 20px 30px;
}

.log-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid #f1f3f4;
}

.log-item:last-child {
    border-bottom: none;
}

.log-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.log-item.success .log-icon {
    background: #d4edda;
    color: #155724;
}

.log-item.info .log-icon {
    background: #d1ecf1;
    color: #0c5460;
}

.log-item.warning .log-icon {
    background: #fff3cd;
    color: #856404;
}

.log-details {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.log-message {
    font-size: 0.9rem;
    font-weight: 500;
    color: #2c3e50;
}

.log-time {
    font-size: 0.8rem;
    color: #6c757d;
}

.btn-logs {
    background: #6c757d;
    color: white;
    border: none;
    padding: 12px 20px;
    margin: 20px 30px 30px;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 0.9rem;
}

.btn-logs:hover {
    background: #5a6268;
}

/* Card de Segurança */
.security-card .security-info {
    padding: 20px 30px;
}

.security-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 0;
    color: #495057;
    font-size: 0.9rem;
}

.security-item i {
    color: #28a745;
    width: 16px;
}

/* Modal de Teste */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    backdrop-filter: blur(5px);
}

.modal-content {
    background: white;
    border-radius: 15px;
    width: 90%;
    max-width: 500px;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
}

.modal-header {
    padding: 20px 25px;
    border-bottom: 1px solid #e9ecef;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f8f9fa;
}

.modal-title {
    font-size: 1.3rem;
    font-weight: 600;
    color: #2c3e50;
    margin: 0;
}

.modal-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: #6c757d;
    cursor: pointer;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover {
    background: #e9ecef;
    color: #495057;
}

.modal-body {
    padding: 25px;
}

.test-progress {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.test-step {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    font-weight: 500;
    color: #495057;
}

.test-step i {
    color: #667eea;
    width: 20px;
}

.test-result {
    text-align: center;
    padding: 30px 20px;
}

.test-result.success {
    color: #28a745;
}

.test-result i {
    font-size: 3rem;
    margin-bottom: 15px;
}

.test-result h4 {
    font-size: 1.3rem;
    margin-bottom: 10px;
}

.test-result p {
    color: #6c757d;
    margin: 0;
}

.text-success {
    color: #28a745 !important;
}

/* Responsividade - Configurações */
@media (max-width: 768px) {
    .settings-container {
        padding: 15px;
    }
    
    .page-header {
        flex-direction: column;
        gap: 15px;
        align-items: stretch;
        text-align: center;
        padding: 20px;
    }
    
    .header-status {
        justify-content: center;
    }
    
    .settings-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .settings-sidebar {
        order: -1;
    }
    
    .config-form {
        padding: 20px;
    }
    
    .settings-card .card-header {
        padding: 20px;
        flex-direction: column;
        gap: 15px;
        align-items: stretch;
    }
    
    .config-badge {
        align-self: flex-start;
    }
    
    .stats-grid {
        grid-template-columns: 1fr !important;
        gap: 15px !important;
    }
    
    .form-actions {
        flex-direction: column;
    }
    
    .btn-primary,
    .btn-secondary {
        width: 100%;
        justify-content: center;
    }
    
    .input-group {
        flex-direction: column;
    }
    
    .form-control {
        border-radius: 8px 8px 0 0;
    }
    
    .input-btn {
        border-radius: 0 0 8px 8px;
        border-left: none;
        border-top: 1px solid #5a6fd8;
    }
    
    .help-step {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .modal-content {
        width: 95%;
        margin: 20px;
    }
}

@media (max-width: 480px) {
    .page-title {
        font-size: 1.6rem;
    }
    
    .settings-card .card-title {
        font-size: 1.1rem;
    }
    
    .connection-status {
        padding: 10px 15px;
        font-size: 0.9rem;
    }
    
    .config-form {
        padding: 15px;
    }
    
    .settings-card .card-header {
        padding: 15px;
    }
    
    .status-info,
    .help-content,
    .security-info,
    .logs-content {
        padding: 15px 20px;
    }
    
    .btn-test,
    .btn-logs {
        margin: 15px 20px 20px;
    }
    
    .stats-grid {
        padding: 15px 20px !important;
    }
}

/* Melhorias de acessibilidade e UX */
.modern-navbar {
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

/* ===== DASHBOARD FINANCEIRO ===== */

/* Container Principal */
.financial-dashboard {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px 20px;
    background: #ffffff;
    min-height: calc(100vh - 80px);
    margin-top: 20px;
}

/* Design tokens da dashboard */
:root {
    --ds-bg: #ffffff;
    --ds-surface: #ffffff;
    --ds-text: #2c3e50;
    --ds-text-muted: #7f8c8d;
    --ds-border: #eaecef;
    --ds-primary: #3498db;
    --ds-primary-600: #2980b9;
    --ds-soft: #f2f6fb;
    --ds-shadow: 0 4px 16px rgba(0,0,0,0.08);
}

/* Header */
.dashboard-header-financial {
    margin-bottom: 24px;
}

.dashboard-title-financial {
    font-size: 2rem;
    font-weight: 600;
    color: #2c3e50;
    margin: 0 0 5px 0;
}

.dashboard-subtitle-financial {
    color: #7f8c8d;
    font-size: 1rem;
    margin: 0;
}

/* Cards de Métricas */
.metrics-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 30px;
}

.metric-card-financial {
    background: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    border-left: 4px solid;
}

.metric-card-financial.red {
    border-left-color: #e74c3c;
}

.metric-card-financial.green {
    border-left-color: #27ae60;
}

.metric-card-financial.blue {
    border-left-color: #3498db;
}

.metric-card-financial.purple {
    border-left-color: #9b59b6;
}

.metric-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.metric-label {
    font-size: 0.8rem;
    font-weight: 600;
    color: #7f8c8d;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.metric-icon {
    font-size: 1.2rem;
    opacity: 0.7;
}

.metric-card-financial.red .metric-icon {
    color: #e74c3c;
}

.metric-card-financial.green .metric-icon {
    color: #27ae60;
}

.metric-card-financial.blue .metric-icon {
    color: #3498db;
}

.metric-card-financial.purple .metric-icon {
    color: #9b59b6;
}

.metric-value-financial {
    font-size: 2rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 5px;
}

.metric-subtitle {
    font-size: 0.9rem;
    color: #95a5a6;
}

/* Cards Principais */
.main-cards-row {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    margin-bottom: 30px;
}

.main-card {
    border-radius: 12px;
    padding: 25px;
    color: white;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.main-card.blue-card {
    background: linear-gradient(135deg, #4285f4 0%, #3367d6 100%);
}

.main-card.orange-card {
    background: linear-gradient(135deg, #ff6b35 0%, #f7931e 100%);
}
.main-card.teal-card {
    background: linear-gradient(135deg, #1dd1a1 0%, #10ac84 100%);
}

.main-card-h {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.main-card-content {
    position: relative;
}

.card-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(255,255,255,0.2);
}

.section-label {
    font-size: 0.9rem;
    opacity: 0.9;
}

.section-value {
    font-weight: 600;
    font-size: 1rem;
}

.main-value {
    font-size: 2.5rem;
    font-weight: 700;
    text-align: right;
    margin-top: 15px;
}

.card-subtitle {
    font-size: 0.9rem;
    opacity: 0.8;
    text-align: center;
    margin-top: 10px;
}

.status-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.status-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
}

.status-label {
    font-size: 0.9rem;
    opacity: 0.9;
}

.status-value {
    font-weight: 600;
    font-size: 1.1rem;
}

/* Ações Rápidas */
.quick-actions-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 30px;
}

.action-card-financial {
    background: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    display: flex;
    align-items: center;
    gap: 15px;
    position: relative;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    cursor: pointer;
}

.action-card-financial:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.15);
}

.action-icon {
    width: 50px;
    height: 50px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.action-icon.red-bg {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
}

.action-icon.green-bg {
    background: linear-gradient(135deg, #27ae60 0%, #229954 100%);
}

.action-icon.blue-bg {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
}

.action-icon.purple-bg {
    background: linear-gradient(135deg, #9b59b6 0%, #8e44ad 100%);
}

.action-content h3 {
    font-size: 1rem;
    font-weight: 600;
    color: #2c3e50;
    margin: 0 0 5px 0;
}

.action-content p {
    font-size: 0.9rem;
    color: #7f8c8d;
    margin: 0;
}

.action-link {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    text-decoration: none;
}

/* Gráficos */
.charts-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 30px;
}

.chart-card {
    background: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.chart-header {
    margin-bottom: 20px;
    border-bottom: 1px solid #f0f0f0;
    padding-bottom: 15px;
}

.chart-header h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: #2c3e50;
    margin: 0 0 5px 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.chart-header i {
    color: #7f8c8d;
}

.chart-subtitle {
    font-size: 0.8rem;
    color: #95a5a6;
}

.chart-content {
    height: 250px;
    position: relative;
}

/* Responsividade - Dashboard Financeiro */
@media (max-width: 1024px) {
    .metrics-row {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .main-cards-row {
        grid-template-columns: 1fr;
    }
    
    .quick-actions-row {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .financial-dashboard {
        padding: 30px 15px 15px;
        margin-top: 15px;
    }
    
    .metrics-row {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .main-cards-row {
        gap: 15px;
    }
    
    .quick-actions-row {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .charts-row {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .main-card {
        padding: 20px;
    }
    
    .main-value {
        font-size: 2rem;
        text-align: center;
    }
    
    .card-section {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
    }
    
    .action-card-financial {
        padding: 15px;
    }
    
    .action-icon {
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
    }
}

@media (max-width: 480px) {
    .dashboard-title-financial {
        font-size: 1.5rem;
    }
    
    .metric-card-financial {
        padding: 15px;
    }
    
    .metric-value-financial {
        font-size: 1.5rem;
    }
    
    .main-card {
        padding: 15px;
    }
    
    .main-value {
        font-size: 1.8rem;
    }
    
    .chart-content {
        height: 200px;
    }
}

/* Header Minimalista */
.clean-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
    padding-bottom: 20px;
    border-bottom: 1px solid #e5e5e5;
}

.header-main {
    flex: 1;
}

.clean-title {
    font-size: 2.5rem;
    font-weight: 300;
    color: #2c3e50;
    margin: 0 0 5px 0;
    letter-spacing: -0.02em;
}

.clean-subtitle {
    font-size: 1.1rem;
    color: #7f8c8d;
    margin: 0;
    font-weight: 400;
}

.header-status {
    display: flex;
    align-items: center;
}

.status-indicator {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
}

.status-indicator.connected {
    background: #d4edda;
    color: #155724;
}

.status-indicator.warning {
    background: #fff3cd;
    color: #856404;
}

.status-indicator i {
    font-size: 0.7rem;
}

/* Alerta Limpo */
.clean-alert {
    background: white;
    border: 1px solid #f0f0f0;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 30px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

.clean-alert .alert-content {
    display: flex;
    align-items: center;
    gap: 15px;
}

.clean-alert i {
    color: #f39c12;
    font-size: 1.2rem;
}

.alert-text span {
    color: #2c3e50;
    font-weight: 500;
}

.alert-action {
    background: #3498db;
    color: white;
    padding: 8px 16px;
    border-radius: 6px;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    margin-left: auto;
}

.alert-action:hover {
    background: #2980b9;
}

/* Grid de Métricas */
.metrics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.metric-card {
    background: white;
    padding: 30px 25px;
    border-radius: 12px;
    text-align: center;
    border: 1px solid #f0f0f0;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.metric-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.08);
}

.metric-value {
    font-size: 2.5rem;
    font-weight: 300;
    color: #2c3e50;
    margin-bottom: 8px;
    line-height: 1;
}

.metric-label {
    font-size: 0.9rem;
    color: #7f8c8d;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 500;
}

/* Conteúdo Principal */
.main-content {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 30px;
}

/* Seções de Conteúdo */
.content-section {
    background: white;
    border-radius: 12px;
    border: 1px solid #f0f0f0;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
    overflow: hidden;
}

.section-header {
    padding: 25px 30px 20px;
    border-bottom: 1px solid #f8f9fa;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.section-title {
    font-size: 1.2rem;
    font-weight: 500;
    color: #2c3e50;
    margin: 0;
}

.section-count {
    background: #ecf0f1;
    color: #2c3e50;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 600;
}

.section-content {
    padding: 0;
}

/* Lista de Mensagens */
.message-list {
    padding: 0;
}

.message-item {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 20px 30px;
    border-bottom: 1px solid #f8f9fa;
    transition: background-color 0.2s ease;
}

.message-item:hover {
    background: #fafbfc;
}

.message-item:last-child {
    border-bottom: none;
}

.message-time {
    font-size: 0.9rem;
    color: #7f8c8d;
    font-weight: 500;
    min-width: 50px;
}

.message-details {
    flex: 1;
}

.message-contact {
    font-weight: 500;
    color: #2c3e50;
    margin-bottom: 4px;
}

.message-preview {
    font-size: 0.9rem;
    color: #7f8c8d;
    line-height: 1.4;
}

/* Estados Vazios */
.empty-state {
    padding: 60px 30px;
    text-align: center;
    color: #95a5a6;
}

.empty-state i {
    font-size: 3rem;
    margin-bottom: 15px;
    opacity: 0.5;
}

.empty-state p {
    margin: 0;
    font-size: 1rem;
}

/* Footer da Seção */
.section-footer {
    padding: 20px 30px;
    border-top: 1px solid #f8f9fa;
    text-align: center;
}

.view-all {
    color: #3498db;
    text-decoration: none;
    font-weight: 500;
    font-size: 0.9rem;
}

.view-all:hover {
    color: #2980b9;
}

/* Grid de Ações */
.action-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    padding: 25px;
}

.action-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 25px 20px;
    background: #f8f9fa;
    border-radius: 8px;
    text-decoration: none;
    color: #2c3e50;
    transition: all 0.2s ease;
    border: 1px solid transparent;
}

.action-card:hover {
    background: #ecf0f1;
    transform: translateY(-2px);
}

.action-card.primary {
    background: #3498db;
    color: white;
}

.action-card.primary:hover {
    background: #2980b9;
}

.action-card i {
    font-size: 1.5rem;
}

.action-card span {
    font-size: 0.9rem;
    font-weight: 500;
}

/* Responsividade */
@media (max-width: 768px) {
    .clean-dashboard {
        padding: 20px 15px;
    }
    
    .clean-header {
        flex-direction: column;
        gap: 20px;
        align-items: flex-start;
        text-align: left;
    }
    
    .clean-title {
        font-size: 2rem;
    }
    
    .metrics-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    
    .main-content {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .message-item {
        padding: 15px 20px;
        gap: 15px;
    }
    
    .action-grid {
        grid-template-columns: 1fr;
        padding: 20px;
    }
    
    .section-header {
        padding: 20px;
    }
    
    .empty-state {
        padding: 40px 20px;
    }
}

@media (max-width: 480px) {
    .metrics-grid {
        grid-template-columns: 1fr;
    }
    
    .metric-card {
        padding: 25px 20px;
    }
    
    .metric-value {
        font-size: 2rem;
    }
    
    .clean-alert .alert-content {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    
    .alert-action {
        margin-left: 0;
        align-self: stretch;
        text-align: center;
    }
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Focus states para acessibilidade */
.nav-link-modern:focus,
.notification-btn:focus,
.user-menu-btn:focus,
.mobile-menu-btn:focus {
    outline: 2px solid #667eea;
    outline-offset: 2px;
}

/* Prefers reduced motion */
@media (prefers-reduced-motion: reduce) {
    .modern-navbar,
    .nav-link-modern,
    .notification-btn,
    .user-menu-btn,
    .mobile-menu-btn,
    .notification-dropdown,
    .user-dropdown,
    .mobile-menu {
        transition: none;
    }
    
    .notification-badge,
    .notification-dot {
        animation: none;
    }
}

/* Dark mode support (preparação futura) */
@media (prefers-color-scheme: dark) {
    .modern-navbar {
        background: linear-gradient(135deg, rgba(30,30,30,0.95) 0%, rgba(20,20,20,0.95) 100%);
        border-bottom: 1px solid rgba(255,255,255,0.1);
    }
    
    .brand-title {
        color: #ffffff;
    }
    
    .brand-subtitle {
        color: #a0a0a0;
    }
    
    .nav-link-modern {
        color: #e0e0e0;
    }
    
    .nav-link-modern:hover {
        color: #667eea;
    }
}


/* Print styles */
@media print {
    .modern-navbar,
    .mobile-menu {
        display: none;
    }
}


/* ===== PÁGINA DE CONTATOS ===== */

/* Container Principal */
.contacts-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    background: #f8f9fa;
    min-height: calc(100vh - 80px);
}

/* Header da Página */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    padding: 0 5px;
}

.page-title {
    font-size: 2rem;
    font-weight: 600;
    color: #2c3e50;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.page-title i {
    color: #667eea;
    font-size: 1.8rem;
}

.btn-new-contact {
    display: flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 10px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.btn-new-contact:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

/* Alertas Melhorados */
.alert {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 15px 20px;
    border-radius: 12px;
    margin-bottom: 20px;
    font-weight: 500;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.alert i {
    font-size: 1.2rem;
}

.alert.alert-success {
    background: linear-gradient(135deg, #d4edda 0%, #c3e6cb 100%);
    border: 1px solid #c3e6cb;
    color: #155724;
}

.alert.alert-danger {
    background: linear-gradient(135deg, #f8d7da 0%, #f5c6cb 100%);
    border: 1px solid #f5c6cb;
    color: #721c24;
}

/* Campo de Busca */
.search-container {
    background: white;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 25px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

.search-box {
    flex: 1;
    position: relative;
    max-width: 400px;
}

.search-icon {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #6c757d;
    z-index: 1;
}

.search-input {
    width: 100%;
    padding: 12px 45px 12px 45px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 1rem;
    background: #f8f9fa;
}

.search-input:focus {
    outline: none;
    border-color: #667eea;
    background: white;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.clear-search {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: #6c757d;
    color: white;
    border: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 0.8rem;
}

.clear-search:hover {
    background: #495057;
}

.search-stats {
    color: #6c757d;
    font-size: 0.9rem;
    font-weight: 500;
}

/* Lista de Contatos */
.contacts-list {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
    overflow: hidden;
}

.contacts-table {
    width: 100%;
}

.table-header {
    display: flex;
    background: #f8f9fa;
    border-bottom: 2px solid #e9ecef;
    font-weight: 600;
    color: #495057;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.header-cell {
    padding: 15px 20px;
    display: flex;
    align-items: center;
}

.header-cell.name {
    flex: 2;
    min-width: 200px;
}

.header-cell.phone {
    flex: 1.5;
    min-width: 150px;
}

.header-cell.email {
    flex: 2;
    min-width: 200px;
}

.header-cell.actions {
    flex: 0.8;
    min-width: 100px;
    justify-content: center;
}

.contact-row {
    display: flex;
    border-bottom: 1px solid #f1f3f4;
    align-items: center;
}

.contact-row:hover {
    background: #f8f9fa;
}

.contact-row:last-child {
    border-bottom: none;
}

.cell {
    padding: 15px 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.cell.name {
    flex: 2;
    min-width: 200px;
}

.cell.phone {
    flex: 1.5;
    min-width: 150px;
    color: #6c757d;
    font-size: 0.95rem;
}

.cell.email {
    flex: 2;
    min-width: 200px;
    color: #6c757d;
    font-size: 0.95rem;
}

.cell.actions {
    flex: 0.8;
    min-width: 100px;
    justify-content: center;
    gap: 8px;
}

.contact-avatar {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.contact-name {
    font-weight: 600;
    color: #2c3e50;
    font-size: 1rem;
}

.no-email {
    color: #adb5bd;
    font-style: italic;
}

.btn-action {
    width: 32px;
    height: 32px;
    border: none;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 0.85rem;
    color: white;
}

.btn-action.edit {
    background: #17a2b8;
}

.btn-action.edit:hover {
    background: #138496;
    transform: translateY(-1px);
}

.btn-action.delete {
    background: #dc3545;
}

.btn-action.delete:hover {
    background: #c82333;
    transform: translateY(-1px);
}

/* Estado Vazio */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #6c757d;
}

.empty-icon {
    font-size: 3rem;
    opacity: 0.5;
    margin-bottom: 20px;
}

.empty-state h3 {
    font-size: 1.3rem;
    color: #495057;
    margin-bottom: 10px;
}

.empty-state p {
    margin-bottom: 25px;
    font-size: 1rem;
}

.btn-add-first {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.btn-add-first:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

/* Mensagem de nenhum resultado */
.no-results {
    text-align: center;
    padding: 40px 20px;
    color: #6c757d;
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
}

.no-results i {
    font-size: 2.5rem;
    opacity: 0.5;
    margin-bottom: 15px;
}

.no-results h3 {
    color: #495057;
    margin-bottom: 8px;
    font-size: 1.2rem;
}

.no-results p {
    margin: 0;
    font-size: 0.95rem;
}


/* Modal */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    backdrop-filter: blur(5px);
}

.modal-content {
    background: white;
    border-radius: 20px;
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-50px) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.modal-header {
    padding: 25px 30px 20px;
    border-bottom: 1px solid #e9ecef;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.05) 0%, rgba(118, 75, 162, 0.05) 100%);
    border-radius: 20px 20px 0 0;
}

.modal-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: #2c3e50;
    margin: 0;
}

.modal-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: #6c757d;
    cursor: pointer;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover {
    background: #f8f9fa;
    color: #495057;
}

.contact-form {
    padding: 30px;
}

.form-row {
    margin-bottom: 20px;
}

.form-group {
    margin-bottom: 0;
}

.form-label {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    font-weight: 600;
    color: #495057;
    font-size: 0.95rem;
}

.form-label i {
    color: #667eea;
    width: 16px;
}

.form-control {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e9ecef;
    border-radius: 10px;
    font-size: 1rem;
    background: #f8f9fa;
}

.form-control:focus {
    outline: none;
    border-color: #667eea;
    background: white;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.form-actions {
    display: flex;
    gap: 15px;
    justify-content: flex-end;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #e9ecef;
}

.btn-secondary {
    padding: 12px 25px;
    background: #6c757d;
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
}

.btn-secondary:hover {
    background: #5a6268;
}

.btn-primary {
    padding: 12px 25px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

/* Responsividade - Contatos */
@media (max-width: 768px) {
    .contacts-container {
        padding: 15px;
    }
    
    .page-header {
        flex-direction: column;
        gap: 15px;
        align-items: stretch;
    }
    
    .page-title {
        font-size: 1.8rem;
        justify-content: center;
    }
    
    .btn-new-contact {
        justify-content: center;
    }
    
    .search-container {
        flex-direction: column;
        gap: 15px;
        align-items: stretch;
    }
    
    .search-box {
        max-width: none;
    }
    
    .search-stats {
        text-align: center;
    }
    
    .table-header {
        display: none;
    }
    
    .contact-row {
        flex-direction: column;
        align-items: stretch;
        padding: 15px;
        gap: 10px;
    }
    
    .cell {
        padding: 5px 0;
        justify-content: flex-start;
    }
    
    .cell.name {
        order: 1;
        font-size: 1.1rem;
    }
    
    .cell.phone {
        order: 2;
    }
    
    .cell.email {
        order: 3;
    }
    
    .cell.actions {
        order: 4;
        justify-content: flex-start;
        margin-top: 10px;
        padding-top: 10px;
        border-top: 1px solid #f1f3f4;
    }
    
    .modal-content {
        width: 95%;
        margin: 20px;
    }
    
    .contact-form {
        padding: 20px;
    }
    
    .form-actions {
        flex-direction: column;
    }
    
    .btn-primary,
    .btn-secondary {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .contacts-container {
        padding: 10px;
    }
    
    .page-title {
        font-size: 1.5rem;
    }
    
    .contact-row {
        padding: 12px;
    }
    
    .contact-avatar {
        width: 35px;
        height: 35px;
        font-size: 0.8rem;
    }
    
    .contact-name {
        font-size: 1rem;
    }
    
    .btn-action {
        width: 28px;
        height: 28px;
        font-size: 0.75rem;
    }
    
    .modal-header {
        padding: 20px;
    }
    
    .modal-title {
        font-size: 1.3rem;
    }
}
