/* CSS Estilos - Crystalline Portal Executivo */

:root {
    --bg-primary: #070913;
    --bg-secondary: #0b0e20;
    --bg-sidebar: #05060d;
    --bg-glass: rgba(13, 17, 39, 0.5);
    --bg-glass-hover: rgba(20, 26, 56, 0.7);
    --color-primary: #0ea5e9;
    --color-primary-glow: rgba(14, 165, 233, 0.15);
    --color-cyan: #06b6d4;
    --color-purple: #8b5cf6;
    --color-green: #10b981;
    --color-warning: #f59e0b;
    --color-danger: #ef4444;
    --color-border: rgba(255, 255, 255, 0.05);
    --color-border-glow: rgba(14, 165, 233, 0.15);
    --text-primary: #ffffff;
    --text-secondary: #94a3b8;
    --text-muted: #475569;
    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 20px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', sans-serif;
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,0.1) transparent;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}
::-webkit-scrollbar-track {
    background: transparent;
}
::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.2);
}

body {
    background-color: var(--bg-primary);
    color: var(--text-primary);
    overflow: hidden;
    height: 100vh;
    width: 100vw;
}

/* CONTAINER GERAL */
.dashboard-wrapper {
    display: flex;
    width: 100%;
    height: 100%;
    position: relative;
    background-image: radial-gradient(circle at 80% 20%, rgba(14, 165, 233, 0.05) 0%, transparent 50%),
                      radial-gradient(circle at 20% 80%, rgba(139, 92, 246, 0.03) 0%, transparent 50%);
}

/* SIDEBAR */
.sidebar {
    width: 280px;
    background-color: var(--bg-sidebar);
    border-right: 1px solid var(--color-border);
    display: flex;
    flex-direction: column;
    padding: 20px 20px 14px; /* optimized spacing */
    z-index: 10;
}

.logo-area {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 24px; /* reduced from 40px to fit menus vertically */
    position: relative;
}

.logo-glow {
    position: absolute;
    width: 40px;
    height: 40px;
    background: var(--color-primary);
    filter: blur(15px);
    opacity: 0.3;
    left: 0;
}

.logo-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--color-primary), var(--color-cyan));
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Outfit', sans-serif;
    font-weight: 900;
    font-size: 20px;
    color: #fff;
    box-shadow: 0 4px 12px rgba(14, 165, 233, 0.3);
}

.logo-text h2 {
    font-family: 'Outfit', sans-serif;
    font-size: 15px;
    font-weight: 700;
    letter-spacing: 0.5px;
    color: #fff;
}

.logo-text span {
    font-size: 9px;
    color: var(--text-muted);
    font-weight: 700;
    letter-spacing: 1px;
}

.nav-menu {
    display: flex;
    flex-direction: column;
    gap: 6px; /* slightly smaller gap to fit more items */
    flex: 1;
    overflow-y: auto;
    padding-right: 4px;
}

/* Custom scrollbar for nav-menu */
.nav-menu::-webkit-scrollbar {
    width: 4px;
}
.nav-menu::-webkit-scrollbar-track {
    background: transparent;
}
.nav-menu::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.08);
    border-radius: 2px;
}
.nav-menu::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.18);
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 16px;
    color: var(--text-secondary);
    text-decoration: none;
    border-radius: var(--radius-sm);
    font-size: 13.5px;
    font-weight: 500;
    transition: var(--transition);
    position: relative;
}

.nav-link i {
    width: 18px;
    height: 18px;
    transition: var(--transition);
}

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

.nav-link.active {
    color: #fff;
    background: linear-gradient(90deg, rgba(14, 165, 233, 0.1) 0%, transparent 100%);
    border-left: 3px solid var(--color-primary);
    font-weight: 600;
}

.nav-link.active i {
    color: var(--color-primary);
}

.sidebar-footer {
    border-top: 1px solid var(--color-border);
    padding-top: 20px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.user-profile {
    display: flex;
    align-items: center;
    gap: 12px;
    position: relative;
}

.avatar {
    width: 38px;
    height: 38px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 13px;
    color: #fff;
}

.user-info h4 {
    font-size: 13px;
    font-weight: 600;
    color: #fff;
}

.user-info span {
    font-size: 10px;
    color: var(--text-muted);
}

.logout-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 12px;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.logout-btn:hover {
    background: rgba(255, 255, 255, 0.03);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.1);
}

/* MAIN CONTENT */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow-y: auto;
}

/* TOP HEADER */
.top-header {
    min-height: 80px;
    border-bottom: 1px solid var(--color-border);
    padding: 12px 40px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(7, 9, 19, 0.45);
    backdrop-filter: blur(10px);
    z-index: 5;
}

.header-title-area {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.breadcrumb {
    font-size: 9.5px;
    font-weight: 800;
    color: var(--color-primary);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 4px;
    line-height: 1;
}

.header-main-title {
    font-family: 'Outfit', sans-serif;
    font-size: 18px;
    font-weight: 700;
    color: #fff;
    line-height: 1.25;
}

.header-search {
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--color-border);
    padding: 8px 16px;
    border-radius: 30px;
    width: 320px;
}

.header-search i {
    width: 16px;
    height: 16px;
    color: var(--text-secondary);
}

.header-search input {
    background: transparent;
    border: none;
    outline: none;
    color: #fff;
    font-size: 12.5px;
    width: 100%;
}

.header-search input::placeholder {
    color: var(--text-muted);
}

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

.status-indicator {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 11.5px;
    color: var(--color-green);
    background: rgba(16, 185, 129, 0.06);
    padding: 6px 12px;
    border-radius: 20px;
    border: 1px solid rgba(16, 185, 129, 0.15);
}

.pulse-dot {
    width: 6px;
    height: 6px;
    background-color: var(--color-green);
    border-radius: 50%;
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
    animation: pulse 1.8s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
    }
    70% {
        transform: scale(1);
        box-shadow: 0 0 0 6px rgba(16, 185, 129, 0);
    }
    100% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0);
    }
}

.digital-clock {
    font-family: 'JetBrains Mono', monospace;
    font-size: 14px;
    font-weight: 700;
    color: var(--color-cyan);
    letter-spacing: 0.5px;
    background: rgba(6, 182, 212, 0.05);
    padding: 4px 10px;
    border-radius: 4px;
    border: 1px solid rgba(6, 182, 212, 0.1);
}

.divider {
    width: 1px;
    height: 20px;
    background-color: var(--color-border);
}

.notification-icon {
    position: relative;
    cursor: pointer;
    color: var(--text-secondary);
    transition: var(--transition);
}

.notification-icon:hover {
    color: #fff;
}

.notification-icon i {
    width: 20px;
    height: 20px;
}

.notification-icon .badge {
    position: absolute;
    top: -4px;
    right: -4px;
    width: 14px;
    height: 14px;
    background-color: var(--color-danger);
    color: #fff;
    border-radius: 50%;
    font-size: 9px;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--bg-primary);
}

/* TABS CONTAINER */
.tabs-container {
    padding: 30px 40px;
    flex: 1;
}

.tab-pane {
    display: none;
    flex-direction: column;
    gap: 24px;
    width: 100%;
}

.tab-pane.active {
    display: flex;
}

/* STATS ROW */
.stats-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.stat-card {
    background: var(--bg-glass);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: 20px;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
    transition: var(--transition);
}

.stat-card:hover {
    border-color: var(--color-border-glow);
    background: var(--bg-glass-hover);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

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

.stat-header span {
    font-size: 10px;
    font-weight: 700;
    color: var(--text-secondary);
    letter-spacing: 1px;
}

.stat-header i {
    width: 16px;
    height: 16px;
}

.stat-value {
    font-family: 'Outfit', sans-serif;
    font-size: 26px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 4px;
}

.stat-footer {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
}

.trend-up {
    color: var(--color-green);
    font-weight: 700;
}

.trend-neutral {
    color: var(--color-cyan);
    font-weight: 700;
}

.trend-desc {
    color: var(--text-secondary);
}

.sparkline-container {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 40px;
    opacity: 0.15;
    pointer-events: none;
}

.sparkline-container canvas {
    width: 100% !important;
    height: 100% !important;
}

/* LAYOUT GRID (COLUMNS) */
.layout-grid {
    display: grid;
    grid-template-columns: 7fr 3fr;
    gap: 20px;
}

.col-left {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.col-right {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* PANELS */
.panel {
    background: var(--bg-glass);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: 24px;
    backdrop-filter: blur(10px);
}

.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
    padding-bottom: 12px;
}

.panel-header h3 {
    font-family: 'Outfit', sans-serif;
    font-size: 15px;
    font-weight: 700;
    color: #fff;
}

.panel-actions {
    display: flex;
    gap: 16px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    color: var(--text-secondary);
}

.dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
}

.dot.primary { background-color: var(--color-primary); }
.dot.warning { background-color: var(--color-warning); }

.chart-wrapper {
    width: 100%;
    position: relative;
}

.chart-wrapper.pie-chart {
    height: 190px;
}

.panel-row-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

/* DUE INVOICES LIST */
.due-invoices-panel {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.badge {
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
}

.badge.warning {
    background: rgba(245, 158, 11, 0.1);
    color: var(--color-warning);
    border: 1px solid rgba(245, 158, 11, 0.2);
}

.scroll-container {
    max-height: 280px;
    overflow-y: auto;
    padding-right: 4px;
}

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

.invoice-item {
    background: rgba(255, 255, 255, 0.01);
    border: 1px solid rgba(255, 255, 255, 0.03);
    border-radius: var(--radius-sm);
    padding: 12px 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: var(--transition);
    cursor: pointer;
}

.invoice-item:hover {
    background: rgba(255, 255, 255, 0.02);
    border-color: rgba(255, 255, 255, 0.08);
}

.invoice-info h4 {
    font-size: 12px;
    color: #fff;
    font-weight: 600;
    max-width: 170px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.invoice-info p {
    font-size: 10.5px;
    color: var(--text-secondary);
    margin-top: 2px;
}

.invoice-val {
    text-align: right;
}

.invoice-val span {
    font-family: 'JetBrains Mono', monospace;
    font-size: 12px;
    font-weight: 700;
    color: var(--color-cyan);
    display: block;
}

.invoice-val small {
    font-size: 9.5px;
    color: var(--text-secondary);
}

/* EVENTS LIST */
.events-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.event-item {
    display: flex;
    gap: 12px;
    padding: 10px;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.01);
    border: 1px solid rgba(255, 255, 255, 0.02);
}

.event-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.event-item.warning .event-icon {
    background: rgba(245, 158, 11, 0.1);
    color: var(--color-warning);
}
.event-item.info .event-icon {
    background: rgba(14, 165, 233, 0.1);
    color: var(--color-primary);
}
.event-item.success .event-icon {
    background: rgba(16, 185, 129, 0.1);
    color: var(--color-green);
}

.event-icon i {
    width: 14px;
    height: 14px;
}

.event-content p {
    font-size: 11.5px;
    color: var(--text-secondary);
    line-height: 1.4;
}

.event-content span {
    font-size: 9.5px;
    color: var(--text-muted);
    display: block;
    margin-top: 2px;
}

/* TABLES */
.table-wrapper {
    width: 100%;
    overflow-x: auto;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
}

.data-table th {
    text-align: left;
    color: var(--text-secondary);
    padding: 12px 16px;
    font-weight: 700;
    border-bottom: 2px solid var(--color-border);
    text-transform: uppercase;
    font-size: 10px;
    letter-spacing: 0.5px;
}

.data-table td {
    padding: 14px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.02);
    color: var(--text-secondary);
}

.data-table tr:hover td {
    color: #fff;
    background: rgba(255, 255, 255, 0.01);
}

.data-table tr td:first-child {
    font-weight: 700;
    color: #fff;
}

.badge-tag {
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 9.5px;
    font-weight: 700;
}

.badge-tag.fornecedor {
    background: rgba(139, 92, 246, 0.1);
    color: var(--color-purple);
}

.badge-tag.cliente {
    background: rgba(14, 165, 233, 0.1);
    color: var(--color-primary);
}

.status-badge {
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 9.5px;
    font-weight: 700;
}

.status-badge.faturada {
    background: rgba(16, 185, 129, 0.1);
    color: var(--color-green);
}

.status-badge.elaboracao {
    background: rgba(245, 158, 11, 0.1);
    color: var(--color-warning);
}

.status-badge.cancelada {
    background: rgba(239, 68, 68, 0.1);
    color: var(--color-danger);
}

/* OPERATIONAL GRID */
.operational-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

.op-card {
    background: rgba(255, 255, 255, 0.01);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    position: relative;
}

.op-indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    position: absolute;
    top: 16px;
    right: 16px;
}

.op-card.ok .op-indicator {
    background-color: var(--color-green);
    box-shadow: 0 0 8px var(--color-green);
}

.op-card.warning .op-indicator {
    background-color: var(--color-warning);
    box-shadow: 0 0 8px var(--color-warning);
}

.op-card h4 {
    font-size: 13.5px;
    font-weight: 700;
    color: #fff;
}

.op-card p {
    font-size: 11.5px;
    color: var(--text-secondary);
}

.op-card span {
    font-size: 10px;
    color: var(--text-muted);
    font-weight: 700;
}

/* MODAL */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    z-index: 100;
    display: none;
    align-items: center;
    justify-content: center;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: var(--bg-secondary);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-lg);
    width: 600px;
    max-width: 90vw;
    overflow: hidden;
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
    animation: zoomIn 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes zoomIn {
    from {
        transform: scale(0.95);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

.modal-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--color-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    font-family: 'Outfit', sans-serif;
    color: #fff;
    font-size: 16px;
}

.modal-header button {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-size: 24px;
    cursor: pointer;
    line-height: 1;
}

.modal-header button:hover {
    color: #fff;
}

.modal-body {
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    max-height: 70vh;
    overflow-y: auto;
}

.modal-text-row {
    display: flex;
    justify-content: space-between;
    font-size: 12.5px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(255,255,255,0.02);
}

.modal-label {
    color: var(--text-secondary);
}

.modal-val {
    color: #fff;
    font-weight: 700;
}

.modal-section-title {
    font-size: 11px;
    font-weight: 700;
    color: var(--color-primary);
    text-transform: uppercase;
    margin-top: 10px;
}

.modal-desc-box {
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--color-border);
    padding: 16px;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    font-size: 12px;
    line-height: 1.5;
}

/* BUSCA CLIENTES */
#client-search-desktop {
    background: rgba(255,255,255,0.02);
    border: 1px solid var(--color-border);
    padding: 6px 14px;
    border-radius: 20px;
    color: #fff;
    font-size: 11.5px;
    outline: none;
    width: 240px;
}

#client-search-desktop:focus {
    border-color: var(--color-primary);
}

/* KPI CARD PROGRESS BARS */
.stat-progress-bar-wrapper {
    width: 100%;
    height: 4px;
    background: rgba(255, 255, 255, 0.04);
    border-radius: 2px;
    margin-top: 12px;
    overflow: hidden;
    position: relative;
    z-index: 2;
}

.stat-progress-bar {
    height: 100%;
    border-radius: 2px;
    background: var(--color-primary);
    box-shadow: 0 0 8px var(--color-primary);
    transition: width 0.8s ease-in-out;
}

/* Colors for specific progress bars */
.stat-card:nth-child(2) .stat-progress-bar { background: var(--color-cyan); box-shadow: 0 0 8px var(--color-cyan); }
.stat-card:nth-child(3) .stat-progress-bar { background: var(--color-green); box-shadow: 0 0 8px var(--color-green); }
.stat-card:nth-child(4) .stat-progress-bar { background: var(--color-purple); box-shadow: 0 0 8px var(--color-purple); }

/* HEADER CONTROLS */
.filter-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--color-border);
    padding: 6px 14px;
    border-radius: 20px;
    position: relative;
}

.filter-icon {
    width: 14px;
    height: 14px;
    color: var(--color-primary);
}

.period-select {
    background: transparent;
    border: none;
    outline: none;
    color: #fff;
    font-size: 11.5px;
    font-weight: 600;
    cursor: pointer;
    padding-right: 12px;
}

.period-select option {
    background: var(--bg-secondary);
    color: #fff;
}

.sync-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--color-primary-glow);
    border: 1px solid var(--color-primary);
    color: var(--color-primary);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 11.5px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.sync-btn:hover {
    background: var(--color-primary);
    color: #fff;
    box-shadow: 0 0 10px rgba(14, 165, 233, 0.4);
}

.sync-btn i {
    width: 14px;
    height: 14px;
    transition: transform 0.8s ease;
}

.sync-btn.loading i {
    animation: spin 1.2s linear infinite;
}

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

/* RESPONSIVIDADE & AJUSTES DE TELA */
@media (max-width: 1200px) {
    .stats-row {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }
    .layout-grid {
        grid-template-columns: 1fr;
    }
    .panel-row-2 {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .dashboard-wrapper {
        flex-direction: column;
        overflow-y: auto;
        height: auto;
    }
    .sidebar {
        width: 100%;
        height: auto;
        padding: 16px;
        border-right: none;
        border-bottom: 1px solid var(--color-border);
    }
    .logo-area {
        margin-bottom: 20px;
    }
    .nav-menu {
        flex-direction: row;
        overflow-x: auto;
        padding-bottom: 10px;
        gap: 12px;
    }
    .nav-link {
        white-space: nowrap;
        padding: 8px 12px;
        border-left: none !important;
        border-bottom: 2px solid transparent;
    }
    .nav-link.active {
        border-bottom: 2px solid var(--color-primary);
        background: transparent;
    }
    .main-content {
        height: auto;
        overflow-y: visible;
    }
    .top-header {
        padding: 16px 20px;
        flex-direction: column;
        gap: 16px;
        align-items: flex-start;
        min-height: auto;
    }
    .header-actions {
        width: 100%;
        flex-wrap: wrap;
        gap: 12px;
        justify-content: flex-start;
    }
    .tabs-container {
        padding: 20px;
    }
    .stats-row {
        grid-template-columns: 1fr;
    }
}

/* PREMIUM AUDIT LOCK OVERLAY */
.tab-auditoria-container {
    position: relative;
    width: 100%;
    min-height: 580px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.blurred-bg {
    filter: blur(8px);
    pointer-events: none;
    user-select: none;
    opacity: 0.18;
    transition: filter 0.3s ease;
}

.lock-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 100;
    padding: 20px;
}

.lock-card {
    background: rgba(10, 15, 30, 0.75);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(244, 63, 94, 0.3);
    border-radius: var(--radius-lg);
    padding: 40px;
    max-width: 650px;
    width: 100%;
    text-align: center;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.8), 0 0 40px rgba(244, 63, 94, 0.15);
    animation: fadeInScale 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.lock-icon-wrapper {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background: rgba(244, 63, 94, 0.15);
    border: 1px solid rgba(244, 63, 94, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px auto;
    color: #f43f5e;
    box-shadow: 0 0 25px rgba(244, 63, 94, 0.25);
}

.lock-icon-wrapper i {
    width: 32px;
    height: 32px;
}

.lock-card h2 {
    font-size: 22px;
    font-weight: 800;
    margin-bottom: 12px;
    color: #fff;
    background: linear-gradient(135deg, #fff, #f43f5e);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.lock-card p {
    color: var(--text-secondary);
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 24px;
}

.audit-summary-teaser {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-bottom: 24px;
}

.teaser-item {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: var(--radius-md);
    padding: 16px 12px;
    transition: background 0.3s ease;
}

.teaser-item:hover {
    background: rgba(255, 255, 255, 0.04);
}

.teaser-val {
    display: block;
    font-size: 24px;
    font-weight: 800;
    font-family: 'JetBrains Mono', monospace;
    color: #f43f5e;
    margin-bottom: 6px;
}

.teaser-label {
    display: block;
    font-size: 9px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-secondary);
}

.teaser-desc {
    font-size: 13.5px !important;
    margin-bottom: 30px !important;
}

.btn-upgrade {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: linear-gradient(135deg, #e11d48, #be123c);
    color: #fff;
    border: none;
    padding: 14px 28px;
    font-size: 14px;
    font-weight: 700;
    border-radius: var(--radius-md);
    cursor: pointer;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 10px 20px -10px rgba(225, 29, 72, 0.5);
    width: 100%;
}

.btn-upgrade:hover {
    background: linear-gradient(135deg, #f43f5e, #e11d48);
    transform: translateY(-2px);
    box-shadow: 0 15px 25px -10px rgba(225, 29, 72, 0.6);
}

.badge-premium {
    background: linear-gradient(135deg, #e11d48, #be123c);
    color: #fff !important;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 9px !important;
    font-weight: 800;
    text-transform: uppercase;
    margin-left: auto;
    letter-spacing: 0.5px;
    box-shadow: 0 0 8px rgba(225, 29, 72, 0.4);
}

