@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;600;700&display=swap');

:root {
    --bg-dark: #0d0d0d;
    --card-bg: rgba(26, 26, 31, 0.7);
    --primary-neon: #00d4ff;
    --secondary-neon: #9d00ff;
    --success-neon: #00ff88;
    --text-main: #ffffff;
    --text-title: #ffffff;
    --text-muted: #cccccc;
    --glass-border: rgba(255, 255, 255, 0.15);
    --input-bg: #1a1a1a;
    --border-muted: #505050;
    --link-neon: #4da6ff;
    --sidebar-width: 260px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-main);
    font-family: 'Outfit', sans-serif;
    overflow-x: hidden;
    min-height: 100vh;
}

/* Scrollbar Moderno */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #050505;
}
::-webkit-scrollbar-thumb {
    background: #222;
    border-radius: 10px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--primary-neon);
}

/* Background Gradients */
.bg-glow {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60vw;
    height: 60vh;
    background: radial-gradient(circle, rgba(0, 212, 255, 0.08) 0%, rgba(157, 0, 255, 0.05) 50%, transparent 100%);
    filter: blur(80px);
    z-index: -1;
    pointer-events: none;
}

/* Navbar & Sidebar - Glassmorphism */
h1, h2, h3, h4, h5, h6 {
    color: var(--text-title);
    font-weight: 700;
}

.navbar {
    background: rgba(13, 13, 13, 0.85) !important;
    backdrop-filter: blur(15px);
    border-bottom: 1px solid var(--border-muted);
    padding: 1rem 2rem;
    z-index: 1000;
}

.navbar-brand {
    font-weight: 700;
    letter-spacing: 1px;
    background: linear-gradient(to right, var(--primary-neon), var(--secondary-neon));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.sidebar {
    background: linear-gradient(rgba(18, 18, 20, 0.95), rgba(18, 18, 20, 0.95)), 
                url("/static/img/sidebar_bg.png") center center / cover no-repeat;
    backdrop-filter: blur(10px);
    border-right: 1px solid var(--border-muted);
    min-height: 100vh;
    padding: 2.5rem 1rem;
    position: relative;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.sidebar a {
    color: var(--text-muted);
    font-weight: 400;
    border-radius: 12px;
    margin-bottom: 8px;
    padding: 12px 18px;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: all 0.3s;
}

.sidebar a i {
    font-size: 1.2rem;
}

.sidebar a:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--primary-neon);
    transform: translateX(5px);
}

a {
    color: var(--link-neon);
    text-decoration: none;
    transition: 0.3s;
}

a:hover {
    color: var(--primary-neon);
    text-decoration: none;
}

.sidebar a.active {
    background: linear-gradient(45deg, rgba(0, 212, 255, 0.1), rgba(157, 0, 255, 0.1));
    color: var(--primary-neon);
    border-left: 3px solid var(--primary-neon);
    box-shadow: -10px 0 20px -5px rgba(0, 212, 255, 0.2);
}

/* Main Content Wrapper */
.main-content {
    padding: 2rem;
    animation: fadeIn 0.6s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Cards Modernos */
.card {
    background: var(--card-bg);
    backdrop-filter: blur(12px);
    border: 1px solid var(--border-muted);
    border-radius: 20px;
    padding: 1.5rem;
    color: var(--text-main);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
    transition: transform 0.3s, box-shadow 0.3s;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.7), 0 0 15px rgba(0, 212, 255, 0.15);
    border-color: var(--primary-neon);
}

.card-header {
    background: transparent !important;
    border-bottom: 1px solid var(--glass-border);
    font-weight: 600;
    font-size: 1.1rem;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    color: var(--primary-neon);
}

/* Botões Neon 3D */
.btn {
    border-radius: 12px;
    padding: 10px 24px;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: linear-gradient(45deg, var(--primary-neon), #00a3cc);
    color: #000;
}

.btn-primary:hover {
    transform: scale(1.05);
    box-shadow: 0 0 20px rgba(0, 212, 255, 0.5);
    background: linear-gradient(45deg, #00e5ff, var(--primary-neon));
}

.btn-outline-primary {
    background: transparent;
    border: 1px solid var(--primary-neon);
    color: var(--primary-neon);
}

.btn-outline-primary:hover {
    background: var(--primary-neon);
    color: #000;
    box-shadow: 0 0 15px var(--primary-neon);
}

/* Forms & Inputs */
.form-control, .form-select {
    background: var(--input-bg);
    border: 1px solid var(--border-muted);
    border-radius: 12px;
    color: var(--text-main);
    padding: 12px 16px;
    transition: all 0.3s;
}

.form-control::placeholder {
    color: var(--text-muted);
    opacity: 1;
}

.form-control:focus {
    background: #222;
    border-color: var(--primary-neon);
    box-shadow: 0 0 10px rgba(0, 212, 255, 0.15);
    color: #fff;
}

.form-label {
    color: var(--text-main);
    font-size: 1rem;
    margin-bottom: 8px;
    font-weight: 600;
}

.text-muted {
    color: var(--text-muted) !important;
}

small {
    font-size: 0.9rem !important;
}

/* Tabelas Neumorfistas */
.table {
    color: var(--text-main);
    border-collapse: separate;
    border-spacing: 0 8px;
}

.table thead th {
    background: rgba(255, 255, 255, 0.08);
    border: none;
    color: var(--text-title);
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 1.5px;
    padding: 18px 15px;
}

.table tbody tr {
    background: rgba(255, 255, 255, 0.03);
    transition: all 0.2s;
}

.table tbody tr td {
    padding: 15px;
    border: none;
    vertical-align: middle;
    color: var(--text-main);
}

.table tbody tr:hover {
    background: rgba(255, 255, 255, 0.06);
    transform: scale(1.002);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.table tbody tr td:first-child { border-radius: 12px 0 0 12px; }
.table tbody tr td:last-child { border-radius: 0 12px 12px 0; }

/* Status Badges Cyberpunk */
.status-badge {
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.status-aberto { background: rgba(0, 212, 255, 0.1); color: var(--primary-neon); border: 1px solid var(--primary-neon); }
.status-finalizado { background: rgba(0, 255, 136, 0.1); color: var(--success-neon); border: 1px solid var(--success-neon); }
.status-sem-retorno { background: rgba(255, 50, 50, 0.1); color: #ff3232; border: 1px solid #ff3232; }

.stat-card {
    background: linear-gradient(135deg, rgba(20, 20, 25, 0.9), rgba(26, 26, 31, 0.7));
    border: 1px solid var(--border-muted);
    position: relative;
    overflow: hidden;
}

.card-tech-bg {
    position: absolute;
    top: 0;
    right: 0;
    width: 60%;
    height: 100%;
    opacity: 0.25;
    background-size: cover;
    background-position: center;
    mask-image: linear-gradient(to right, transparent, black);
    -webkit-mask-image: linear-gradient(to right, transparent, black);
    pointer-events: none;
}

.card-status-bg {
    background-image: url("/static/img/card_status_bg.png");
}

.card-empresa-bg {
    background-image: url("/static/img/card_empresa_bg.png");
}

.stat-card .number {
    position: relative;
    z-index: 1;
    color: var(--text-title);
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
}

/* Efeito Glow para Texto Importante */
.glow-text {
    text-shadow: 0 0 10px rgba(0, 212, 255, 0.5);
}

/* Sidebar Overlay para Mobile */
.sidebar-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    z-index: 1050;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.sidebar-overlay.show {
    display: block;
    opacity: 1;
}

/* Responsividade Customizada */
@media (max-width: 768px) {
    .sidebar {
        position: fixed;
        left: -280px;
        top: 0;
        bottom: 0;
        width: 260px !important;
        z-index: 1100;
        min-height: 100vh;
        height: 100vh;
        overflow-y: auto;
        padding: 4rem 1.5rem 2rem 1.5rem;
        transition: left 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        box-shadow: 20px 0 50px rgba(0,0,0,0.5);
    }
    
    .sidebar.show {
        left: 0;
    }
    
    .main-content {
        padding: 1.5rem 1rem;
        width: 100% !important;
    }
    
    .navbar {
        padding: 0.8rem 1rem;
    }
}

