body {
    background:#0d1117;
    color:#c9d1d9;
    font-family: monospace;
}

a {
    color:#58a6ff;
    text-decoration:none;
}

.container {
    max-width:1000px;
    margin:40px auto;
}

.card {
    background:#161b22;
    padding:20px;
    border-radius:8px;
    margin-bottom:20px;
}

h1, h2, h3 {
    color:#58a6ff;
}

input, textarea, select, button {
    width:100%;
    padding:8px;
    margin-bottom:10px;
    background:#0d1117;
    border:1px solid #30363d;
    color:#c9d1d9;
}

button {
    cursor:pointer;
}

.btn {
    padding:15px;
    text-align:center;
    border-radius:6px;
    color:#fff;
    display:inline-block;
}

.btn-add { background:#238636; }
.btn-edit { background:#1f6feb; }
.btn-del { background:#da3633; }

.btn:hover { opacity:0.85; }

table {
    width:100%;
    border-collapse:collapse;
}

th, td {
    padding:10px;
    border-bottom:1px solid #30363d;
}

th { color:#58a6ff; }

.flash-success {
    background:#238636;
    color:#fff;
    padding:12px;
    border-radius:6px;
    margin-bottom:15px;
}

.status-on { color:#2ea043; }
.status-off { color:#f85149; }

.top {
    display:flex;
    justify-content:space-between;
    align-items:center;
}
.status-on { color:#2ea043; }
.status-off { color:#f85149; }

#scanStatus div {
    margin-top:5px;
}
.dvr-card.offline {
    background: linear-gradient(135deg, #3a0d0d, #6b1111);
    border: 1px solid #f85149;
    cursor: pointer;
}

.dvr-card.offline:hover {
    box-shadow: 0 0 15px rgba(248,81,73,0.6);
}

.dvr-card.offline h3,
.dvr-card.offline p {
    color: #fff;
}
/* ===== DVR GRID ===== */
.dvr-grid {
    display:grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap:20px;
}

.dvr-card {
    background:#161b22;
    padding:20px;
    border-radius:10px;
    position:relative;
    transition: all 0.2s ease;
}

.dvr-card h3 {
    margin-top:0;
}

/* ===== LED ===== */
.led {
    width:14px;
    height:14px;
    border-radius:50%;
    position:absolute;
    top:15px;
    right:15px;
}

.green { background:#2ea043; }
.orange { background:#d29922; }
.red { background:#f85149; }

/* ===== OFFLINE CARD ===== */
.dvr-card.offline {
    background: linear-gradient(135deg, #3a0d0d, #6b1111);
    border:1px solid #f85149;
    cursor:pointer;
}

.dvr-card.offline:hover {
    box-shadow:0 0 15px rgba(248,81,73,0.6);
}

.dvr-card.offline h3,
.dvr-card.offline p {
    color:#fff;
}

/* ===== STATUS TEXT ===== */
.status-on { color:#2ea043; }
.status-off { color:#f85149; }

.small {
    font-size:13px;
    opacity:0.85;
}

#scanStatus div {
    margin-top:5px;
}
/* ===== TOP BAR ===== */
.topbar {
    background:#161b22;
    padding:15px 25px;
    display:flex;
    justify-content:space-between;
    align-items:center;
    border-bottom:1px solid #30363d;
}

.topbar-title {
    color:#58a6ff;
    font-size:18px;
    font-weight:bold;
}

.topbar-buttons a {
    margin-right:10px;
}

/* ===== BUTTONS ===== */
.btn {
    padding:10px 14px;
    border-radius:6px;
    text-decoration:none;
    color:#fff;
    font-size:14px;
}

.btn-add { background:#238636; }
.btn-edit { background:#1f6feb; }
.btn-del { background:#da3633; }
.btn-user { background:#8b5cf6; }
.btn-logout { background:#444; }

/* ===== DVR OFFLINE – ROȘU SERIOS ===== */
.dvr-card.offline {
    background: linear-gradient(135deg, #5a0d0d, #8b0000);
    border:2px solid #ff4d4d;
    box-shadow: 0 0 20px rgba(255,0,0,0.6);
    cursor:pointer;
}

.dvr-card.offline h3,
.dvr-card.offline p {
    color:#fff;
}
/* ===== LOGIN PAGE ===== */
.login-page {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-wrapper {
    width: 100%;
    display: flex;
    justify-content: center;
}

.login-card {
    background: #161b22;
    padding: 30px 35px;
    border-radius: 12px;
    width: 100%;
    max-width: 420px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.6);
}

.login-card h2 {
    margin-top: 0;
    margin-bottom: 20px;
    text-align: center;
    color: #58a6ff;
}

.login-card input {
    margin-bottom: 15px;
    font-size: 15px;
}

.login-btn {
    margin-top: 10px;
    font-size: 15px;
    padding: 12px;
}

.login-error {
    background: #5a0d0d;
    border: 1px solid #ff4d4d;
    color: #fff;
    padding: 10px;
    border-radius: 6px;
    margin-bottom: 15px;
    text-align: center;
}
