*{
    margin:0;
    padding:0;
    box-sizing:border-box;
}

body{
    font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
    background:
        radial-gradient(circle at top left, rgba(0,11,61,0.35), transparent 30%),
        radial-gradient(circle at bottom right, rgba(255,210,0,0.06), transparent 25%),
        #06141d;

    color:#ffffff;

    min-height:100vh;
}

a{
    text-decoration:none;
    color:inherit;
}

.dashboard{
    display:flex;
    min-height:100vh;
}

/* SIDEBAR */

.sidebar{
    width:270px;

    background:
        linear-gradient(
            180deg,
            rgba(0,11,61,0.96) 0%,
            rgba(6,20,29,0.98) 100%
        );

    border-right:1px solid rgba(255,255,255,0.06);

    padding:28px 20px;

    backdrop-filter:blur(12px);

    box-shadow:
        0 0 40px rgba(0,0,0,0.45);

    position:relative;
}

.logo{
    margin-bottom:40px;
}

.logo h2{
    color:#FFFFFF;
    font-size:30px;
    font-weight:800;
    letter-spacing:-1px;
}

.logo p{
    color:#94a3b8;
    font-size:13px;
    margin-top:6px;
    line-height:1.5;
}

.menu{
    display:flex;
    flex-direction:column;
    gap:12px;
}

.menu a{
    background:rgba(255,255,255,0.03);

    border:1px solid rgba(255,255,255,0.04);

    padding:15px 16px;

    border-radius:14px;

    transition:0.25s ease;

    font-size:15px;

    color:#dbe4ee;

    font-weight:500;
}

.menu a:hover{

    background:#FFD200;

    color:#000B3D;

    transform:translateX(4px);

    box-shadow:
        0 0 20px rgba(255,210,0,0.22);

    font-weight:700;
}

/* CONTEÚDO */

.main{
    flex:1;
    padding:30px;
}

/* TOPO */

.topbar{
    display:flex;
    justify-content:space-between;
    align-items:center;
    margin-bottom:30px;
}

.topbar h1{
    font-size:28px;
}

.status-server{
    background:#111827;
    padding:10px 15px;
    border-radius:10px;
    border:1px solid #1f2937;
    color:#22c55e;
    font-size:14px;
}

/* CARDS */

.cards{
    display:grid;
    grid-template-columns:repeat(auto-fit, minmax(220px, 1fr));
    gap:20px;
    margin-bottom:30px;
}

.card{

    background:
        linear-gradient(
            180deg,
            rgba(10,25,40,0.96),
            rgba(7,18,28,0.98)
        );

    border:1px solid rgba(255,255,255,0.05);

    border-radius:20px;

    padding:24px;

    box-shadow:
        0 10px 30px rgba(0,0,0,0.25);

    backdrop-filter:blur(12px);

    transition:0.25s ease;
}

.card:hover{
    transform:translateY(-3px);

    border-color:rgba(255,210,0,0.22);

    box-shadow:
        0 18px 35px rgba(0,0,0,0.35);
}

.card h3{
    color:#9ca3af;
    font-size:15px;
    margin-bottom:12px;
}

.card .numero{
    font-size:38px;
    font-weight:800;

    color:#FFD200;

    letter-spacing:-1px;
}

/* EVENTOS */

.box{
    background:#111827;
    border:1px solid #1f2937;
    border-radius:16px;
    padding:20px;
}

.box h2{
    margin-bottom:20px;
}

.evento{
    padding:14px;
    border-bottom:1px solid #1f2937;
    display:flex;
    justify-content:space-between;
    align-items:center;
}

.evento:last-child{
    border-bottom:none;
}

.evento-info{
    display:flex;
    flex-direction:column;
    gap:4px;
}

.evento small{
    color:#9ca3af;
}

.online{
    color:#22c55e;
    font-weight:bold;
}

.offline{
    color:#ef4444;
    font-weight:bold;
}

.alerta{
    color:#f59e0b;
    font-weight:bold;
}

/* RESPONSIVO */

@media(max-width:900px){

    .dashboard{
        flex-direction:column;
    }

    .sidebar{
        width:100%;
        border-right:none;
        border-bottom:1px solid #1f2937;
    }

    .menu{
        flex-direction:row;
        flex-wrap:wrap;
    }

}

.cliente-item{
    padding:18px 14px;
    border-bottom:1px solid #1f2937;
    display:flex;
    justify-content:space-between;
    align-items:center;
    gap:15px;
}

.cliente-item:last-child{
    border-bottom:none;
}

.cliente-item div:first-child{
    display:flex;
    flex-direction:column;
    gap:5px;
}

.cliente-item small{
    color:#9ca3af;
}

.cliente-acoes{
    display:flex;
    align-items:center;
    gap:15px;
}

.cliente-acoes a{
    background:#22c55e;
    color:#000;
    padding:8px 14px;
    border-radius:8px;
    font-weight:bold;
    font-size:13px;
}

.cliente-acoes a:hover{
    opacity:0.85;
}

@media(max-width:700px){
    .cliente-item{
        flex-direction:column;
        align-items:flex-start;
    }
}

.cliente-info{
    display:flex;
    flex-direction:column;
    gap:5px;
}

.stream-grid{
    display:grid;
    grid-template-columns:repeat(auto-fit, minmax(240px, 1fr));
    gap:18px;
}

.stream-card{
    background:#0b0f14;
    border:1px solid #1f2937;
    border-radius:14px;
    padding:14px;
}

.stream-preview{
    height:140px;
    background:#020617;
    border:1px solid #1f2937;
    border-radius:12px;
    display:flex;
    justify-content:center;
    align-items:center;
    color:#22c55e;
    font-size:38px;
    margin-bottom:12px;
}

.stream-card h3{
    font-size:16px;
    margin-bottom:5px;
}

.stream-card small{
    color:#9ca3af;
}

.stream-footer{
    display:flex;
    justify-content:space-between;
    align-items:center;
    margin-top:14px;
}

.stream-footer a{
    background:#22c55e;
    color:#000;
    padding:8px 14px;
    border-radius:8px;
    font-weight:bold;
    font-size:13px;
}

.offline-preview{
    color:#ef4444;
    font-size:18px;
}

.alerta-preview{
    color:#f59e0b;
    font-size:18px;
}

.timeline{
    display:flex;
    flex-direction:column;
    gap:18px;
}

.timeline-item{
    position:relative;
    display:flex;
    gap:15px;
    background:#0b0f14;
    border:1px solid #1f2937;
    border-radius:14px;
    padding:18px;
}

.timeline-dot{
    width:14px;
    height:14px;
    border-radius:50%;
    margin-top:5px;
    background:#22c55e;
    box-shadow:0 0 12px #22c55e;
    flex-shrink:0;
}

.timeline-content{
    width:100%;
}

.timeline-header{
    display:flex;
    justify-content:space-between;
    align-items:center;
    gap:15px;
    margin-bottom:8px;
}

.timeline-header span{
    font-size:12px;
    font-weight:bold;
    padding:6px 10px;
    border-radius:999px;
    background:#1f2937;
    color:#22c55e;
}

.timeline-content p{
    color:#e5e7eb;
    margin-bottom:8px;
}

.timeline-content small{
    color:#9ca3af;
}

.timeline-item.urgente{
    border-color:#ef4444;
}

.timeline-item.urgente .timeline-dot{
    background:#ef4444;
    box-shadow:0 0 12px #ef4444;
}

.timeline-item.urgente .timeline-header span{
    color:#ef4444;
}

.timeline-item.alerta-evento{
    border-color:#f59e0b;
}

.timeline-item.alerta-evento .timeline-dot{
    background:#f59e0b;
    box-shadow:0 0 12px #f59e0b;
}

.timeline-item.alerta-evento .timeline-header span{
    color:#f59e0b;
}

.timeline-item.resolvido .timeline-header span{
    color:#22c55e;
}

.alerta-lista{
    display:flex;
    flex-direction:column;
    gap:16px;
}

.alerta-card{
    background:#0b0f14;
    border:1px solid #1f2937;
    border-radius:14px;
    padding:18px;
    display:flex;
    justify-content:space-between;
    align-items:center;
    gap:20px;
}

.alerta-card strong{
    font-size:16px;
}

.alerta-card p{
    color:#e5e7eb;
    margin-top:6px;
    margin-bottom:6px;
}

.alerta-card small{
    color:#9ca3af;
}

.alerta-card.critico{
    border-color:#ef4444;
}

.alerta-card.medio{
    border-color:#f59e0b;
}

.alerta-card.baixo{
    border-color:#22c55e;
}

.alerta-acoes{
    display:flex;
    gap:10px;
    flex-wrap:wrap;
}

.alerta-acoes button{
    background:#22c55e;
    color:#000;
    border:none;
    padding:10px 14px;
    border-radius:8px;
    font-weight:bold;
    cursor:pointer;
}

.alerta-acoes button.secundario{
    background:#1f2937;
    color:#fff;
}

.alerta-acoes button:hover{
    opacity:0.85;
}

@media(max-width:800px){
    .alerta-card{
        flex-direction:column;
        align-items:flex-start;
    }
}

.sistema-grid{
    display:grid;
    grid-template-columns:repeat(auto-fit, minmax(260px, 1fr));
    gap:16px;
}

.sistema-item{
    background:#0b0f14;
    border:1px solid #1f2937;
    border-radius:14px;
    padding:18px;
    display:flex;
    justify-content:space-between;
    align-items:center;
    gap:15px;
}

.sistema-item span{
    color:#cbd5e1;
}

.sistema-item strong{
    color:#ffffff;
}

.box-header{
    display:flex;
    justify-content:space-between;
    align-items:center;
    gap:20px;
    margin-bottom:20px;
}

.box-header p{
    color:#9ca3af;
    margin-top:5px;
}

.btn-principal{
    background:#22c55e;
    color:#000;
    padding:11px 16px;
    border-radius:9px;
    font-weight:bold;
    font-size:14px;
    white-space:nowrap;
}

.vpn-lista{
    display:flex;
    flex-direction:column;
}

.vpn-item{
    padding:18px 14px;
    border-bottom:1px solid #1f2937;
    display:flex;
    justify-content:space-between;
    align-items:center;
    gap:15px;
}

.vpn-item:last-child{
    border-bottom:none;
}

.vpn-item div:first-child{
    display:flex;
    flex-direction:column;
    gap:5px;
}

.vpn-item small{
    color:#9ca3af;
}

.vpn-acoes{
    display:flex;
    align-items:center;
    gap:15px;
}

.vpn-acoes a{
    background:#1f2937;
    color:#fff;
    padding:8px 14px;
    border-radius:8px;
    font-weight:bold;
    font-size:13px;
}

.vpn-acoes a:hover,
.btn-principal:hover{
    opacity:0.85;
}

@media(max-width:800px){
    .box-header,
    .vpn-item{
        flex-direction:column;
        align-items:flex-start;
    }
}

.login-page{
    min-height:100vh;
    display:flex;
    justify-content:center;
    align-items:center;
    background:
        radial-gradient(circle at top left, rgba(255,210,0,0.10), transparent 28%),
        radial-gradient(circle at bottom right, rgba(0,11,61,0.75), transparent 35%),
        #06141d;
    padding:24px;
}

.login-box{
    width:420px;
    background:rgba(7,18,28,0.92);
    border:1px solid rgba(255,255,255,0.08);
    border-radius:26px;
    padding:34px;
    box-shadow:0 30px 80px rgba(0,0,0,0.45);
    backdrop-filter:blur(14px);
}

.login-box::before{
    content:"";
    display:block;
    width:90px;
    height:90px;
    margin:0 auto 18px auto;
    background:url("../img/escudo.png") center/contain no-repeat;
    filter:drop-shadow(0 12px 24px rgba(0,0,0,0.35));
}

.login-box h1{
    color:#ffffff;
    text-align:center;
    font-size:30px;
    font-weight:900;
    letter-spacing:-1px;
    margin-bottom:6px;
}

.login-box p{
    color:#cbd5e1;
    text-align:center;
    margin-bottom:28px;
}

.login-box input{
    width:100%;
    padding:15px;
    border-radius:14px;
    border:1px solid rgba(255,255,255,0.08);
    background:rgba(0,0,0,0.28);
    color:#fff;
    margin-bottom:14px;
    outline:none;
}

.login-box input:focus{
    border-color:#FFD200;
    box-shadow:0 0 0 3px rgba(255,210,0,0.12);
}

.login-box button{
    width:100%;
    padding:15px;
    border:none;
    border-radius:14px;
    background:#FFD200;
    color:#000B3D;
    font-weight:900;
    cursor:pointer;
    transition:0.25s ease;
}

.login-box button:hover{
    transform:translateY(-2px);
    box-shadow:0 14px 30px rgba(255,210,0,0.22);
}

.login-erro{
    background:rgba(239,68,68,0.12);
    color:#fecaca;
    border:1px solid rgba(239,68,68,0.35);
    padding:12px;
    border-radius:12px;
    margin-bottom:16px;
    font-size:14px;
    text-align:center;
}

.form-painel{
    display:flex;
    flex-direction:column;
    gap:18px;
}

.form-grid{
    display:grid;
    grid-template-columns:repeat(auto-fit, minmax(240px, 1fr));
    gap:18px;
}

.form-painel label{
    display:block;
    margin-bottom:8px;
    color:#cbd5e1;
    font-size:14px;
}

.form-painel input,
.form-painel select{
    width:100%;
    padding:13px;
    border-radius:10px;
    border:1px solid #1f2937;
    background:#0b0f14;
    color:#fff;
}

.btn-form{
    background:#22c55e;
    color:#000;
    border:none;
    padding:13px 18px;
    border-radius:10px;
    font-weight:bold;
    cursor:pointer;
    width:fit-content;
}

.btn-form:hover{
    opacity:0.85;
}

.msg-sucesso{
    background:#052e16;
    color:#86efac;
    border:1px solid #14532d;
    padding:12px;
    border-radius:10px;
    margin-bottom:18px;
}

.msg-erro{
    background:#7f1d1d;
    color:#fecaca;
    border:1px solid #991b1b;
    padding:12px;
    border-radius:10px;
    margin-bottom:18px;
}

.player-box{
    background:#0b0f14;
    border:1px solid #1f2937;
    border-radius:16px;
    padding:18px;
}

.player-placeholder{
    min-height:360px;
    background:#020617;
    border:1px solid #1f2937;
    border-radius:14px;
    display:flex;
    flex-direction:column;
    justify-content:center;
    align-items:center;
    gap:12px;
    color:#22c55e;
    font-size:48px;
}

.player-placeholder span{
    color:#fff;
    font-size:18px;
    font-weight:bold;
}

.player-placeholder small{
    color:#9ca3af;
    font-size:14px;
}

.btn-alerta{
    background:#22c55e;
    color:#000;
    padding:10px 14px;
    border-radius:8px;
    font-weight:bold;
    font-size:13px;
    display:inline-block;
}

.btn-alerta.secundario{
    background:#1f2937;
    color:#fff;
}

.btn-alerta:hover{
    opacity:0.85;
}

.logo-painel{
    text-align:left;
    margin-bottom:34px;
}

.logo-painel img{
    width:185px;
    max-width:100%;
    display:block;
    margin-bottom:14px;
    filter:drop-shadow(0 0 18px rgba(255,210,0,0.08));
}

.logo-painel p{
    border-top:1px solid rgba(255,255,255,0.08);
    padding-top:12px;
}

.logo-painel small{
    color:#FFD200;
    font-weight:800;
    letter-spacing:1px;
}

.logo-painel{
    margin-bottom:34px;
    text-align:center;
}

.logo-icon-box{
    width:96px;
    height:96px;
    margin:0 auto 18px auto;
    display:flex;
    align-items:center;
    justify-content:center;
}

.logo-icon-box img{
    width:88px;
    height:auto;
    display:block;
    filter:drop-shadow(0 10px 24px rgba(0,0,0,0.35));
}

.user-box{
    background:rgba(255,255,255,0.04);
    border:1px solid rgba(255,255,255,0.08);
    border-radius:16px;
    padding:13px 14px;
    text-align:left;
}

.user-box strong{
    display:block;
    color:#ffffff;
    font-size:15px;
    font-weight:800;
}

.user-box span{
    display:inline-block;
    margin-top:5px;
    color:#FFD200;
    font-size:12px;
    font-weight:900;
    letter-spacing:1px;
}

/* GRID DE CÂMERAS DO CLIENTE */

.camera-grid{
    display:flex;
    flex-wrap:wrap;
    gap:18px;
    align-items:flex-start;
}

.camera-card{
    width:240px;

    background:#0b1628;

    border:1px solid rgba(255,255,255,0.08);

    border-radius:16px;

    padding:14px;

    transition:0.25s ease;
}

.camera-card:hover{
    transform:translateY(-3px);

    border-color:rgba(255,210,0,0.25);

    box-shadow:
        0 10px 25px rgba(0,0,0,0.25);
}

.camera-thumb{
    width:100%;
    height:140px;

    border-radius:12px;

    overflow:hidden;

    background:#020617;

    margin-bottom:12px;

    border:1px solid rgba(255,255,255,0.08);
}

.camera-thumb img{
    width:100%;
    height:100%;
    object-fit:cover;
    display:block;
}

.camera-title{
    display:block;
    color:#ffffff;
    font-size:16px;
    margin-bottom:6px;
}

.camera-btn{
    display:block;

    margin-top:14px;

    text-align:center;

    background:#22c55e;

    color:#000;

    padding:10px;

    border-radius:10px;

    font-weight:bold;

    transition:0.2s ease;
}

.camera-btn:hover{
    opacity:0.85;
}

@media(max-width:700px){

    .camera-grid{
        justify-content:center;
    }

    .camera-card{
        width:100%;
    }

}

.camera-grid{
    display:grid;
    grid-template-columns:repeat(auto-fill, minmax(220px, 220px));
    gap:18px;
    margin-top:20px;
}

.camera-card{
    width:220px;
    background:#0b1628;
    border:1px solid rgba(255,255,255,0.08);
    border-radius:16px;
    padding:14px;
}

.camera-thumb{
    width:100%;
    height:120px;
    background:#020617;
    border-radius:12px;
    overflow:hidden;
    margin-bottom:12px;
}

.camera-thumb img{
    width:100%;
    height:100%;
    object-fit:cover;
    display:block;
}

.camera-title{
    display:block;
    color:#fff;
    font-size:16px;
    margin-bottom:6px;
}

.camera-btn{
    display:block;
    margin-top:14px;
    background:#22c55e;
    color:#000;
    padding:10px;
    border-radius:10px;
    text-align:center;
    font-weight:bold;
}

.camera-live iframe{
    width:100%;
    height:100%;
    border:0;
    display:block;
    background:#000;
}

.stream-grid{
    display:grid;
    grid-template-columns:repeat(auto-fill, minmax(220px, 1fr));
    gap:16px;
}

.stream-card{
    background:#08111f;
    border:1px solid #1e293b;
    border-radius:14px;
    padding:12px;
    overflow:hidden;
    transition:.2s;
}

.stream-card:hover{
    transform:translateY(-3px);
    border-color:#22c55e;
}

.stream-preview{
    width:100%;
    aspect-ratio:16/9;
    background:#000;
    border-radius:10px;
    overflow:hidden;
    margin-bottom:10px;
}

.stream-preview iframe{
    width:100%;
    height:100%;
    border:none;
}

.stream-footer{
    display:grid;
    grid-template-columns:1fr 1fr 1fr;
    gap:8px;
    margin-top:12px;
}

.stream-footer span{
    grid-column:1 / -1;
}

.stream-footer a{
    width:100%;
    text-align:center;
    padding:8px 10px;
    border-radius:8px;
    text-decoration:none;
    font-weight:700;
    font-size:13px;
}

.stream-footer a{
    padding:8px 12px;
    border-radius:8px;
    text-decoration:none;
    font-weight:700;
    font-size:13px;
}