/* ======================== GLOBALNI STILOVI ======================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #3498db;
    --secondary-color: #2c3e50;
    --success-color: #27ae60;
    --danger-color: #e74c3c;
    --warning-color: #f39c12;
    --light-bg: #ecf0f1;
    --border-color: #bdc3c7;
    --text-color: #2c3e50;
    --sidebar-width: 250px;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--light-bg);
    color: var(--text-color);
    line-height: 1.6;
}

/* ======================== LAYOUT ======================== */
.app-container {
    display: flex;
    min-height: 100vh;
}

.sidebar {
    width: var(--sidebar-width);
    background: linear-gradient(135deg, var(--secondary-color) 0%, #34495e 100%);
    color: white;
    padding: 20px;
    position: fixed;
    height: 100vh;
    overflow-y: auto;
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
}

.sidebar h2 {
    margin-bottom: 30px;
    font-size: 1.5em;
    border-bottom: 2px solid var(--primary-color);
    padding-bottom: 10px;
}

.main-content {
    margin-left: var(--sidebar-width);
    flex: 1;
    display: flex;
    flex-direction: column;
}

.navbar {
    background: white;
    padding: 15px 30px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.navbar-title {
    font-weight: bold;
    color: var(--secondary-color);
}

.navbar-user-name {
    color: var(--text-color);
}

.content {
    padding: 30px;
    flex: 1;
}

/* ======================== SIDEBAR ======================== */
.user-info {
    background: rgba(255, 255, 255, 0.1);
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    text-align: center;
}

.user-info strong {
    display: block;
    margin-bottom: 5px;
}

.user-info span {
    font-size: 0.9em;
    opacity: 0.8;
}

.nav-menu {
    list-style: none;
    margin-bottom: 30px;
}

.nav-item {
    margin-bottom: 10px;
}

.nav-link {
    color: white;
    text-decoration: none;
    padding: 12px 15px;
    display: block;
    border-radius: 5px;
    transition: all 0.3s ease;
}

.nav-link:hover {
    background-color: var(--primary-color);
    transform: translateX(5px);
}

.sidebar-footer {
    position: absolute;
    bottom: 20px;
    width: calc(100% - 40px);
}

.logout-btn {
    width: 100%;
    padding: 12px;
    background-color: var(--danger-color);
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1em;
    transition: all 0.3s ease;
}

.logout-btn:hover {
    background-color: #c0392b;
    transform: scale(1.05);
}

/* ======================== HEADER ======================== */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.header h1 {
    color: var(--secondary-color);
}

/* ======================== CARDS ======================== */
.card {
    background: white;
    padding: 25px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    margin-bottom: 25px;
}

.card h2 {
    color: var(--secondary-color);
    margin-bottom: 20px;
    border-bottom: 2px solid var(--light-bg);
    padding-bottom: 10px;
}

/* ======================== TABELE ======================== */
table {
    width: 100%;
    border-collapse: collapse;
    background: white;
}

thead {
    background-color: var(--secondary-color);
    color: white;
}

th {
    padding: 15px;
    text-align: left;
    font-weight: 600;
}

td {
    padding: 12px 15px;
    border-bottom: 1px solid var(--light-bg);
}

tbody tr {
    transition: background-color 0.3s ease;
}

tbody tr:hover {
    background-color: #f8f9fa;
}

/* ======================== BUTTONS ======================== */
.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1em;
    transition: all 0.3s ease;
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background-color: #2980b9;
    transform: scale(1.05);
}

.btn-success {
    background-color: var(--success-color);
    color: white;
}

.btn-success:hover {
    background-color: #229954;
}

.btn-danger {
    background-color: var(--danger-color);
    color: white;
}

.btn-danger:hover {
    background-color: #c0392b;
}

.btn-secondary {
    background-color: var(--border-color);
    color: var(--text-color);
}

.btn-secondary:hover {
    background-color: #95a5a6;
}

.btn-small {
    padding: 8px 15px;
    font-size: 0.9em;
}

/* ======================== MODAL ======================== */
.modal {
    display: none;
    position: fixed;
    z-index: 1;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
}

.modal.show {
    display: flex;
    justify-content: center;
    align-items: center;
}

.modal-content {
    background-color: white;
    padding: 30px;
    border-radius: 8px;
    width: 500px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    position: relative;
}

:root {
    --primary: #2563eb;
    --secondary: #1e293b;
    --bg: #f8fafc;
    --card: #ffffff;
    --text: #334155;
    --radius: 12px;
    --shadow: 0 4px 6px -1px rgba(0,0,0,0.1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: 'Segoe UI', system-ui, sans-serif; background: var(--bg); color: var(--text); }

.app-container { display: flex; min-height: 100vh; }

.sidebar { width: 260px; background: var(--secondary); color: white; padding: 20px; position: fixed; height: 100vh; }
.sidebar h2 { font-size: 1.2rem; margin-bottom: 2rem; padding: 10px; border-left: 4px solid var(--primary); }

.main-content { margin-left: 260px; flex: 1; display: flex; flex-direction: column; }
.navbar { background: white; padding: 15px 30px; box-shadow: var(--shadow); display: flex; justify-content: space-between; }

.content { padding: 30px; }

/* Filteri za datum */
.filters-container { display: flex; gap: 20px; margin-bottom: 20px; background: white; padding: 20px; border-radius: var(--radius); box-shadow: var(--shadow); }
.filter-group { display: flex; flex-direction: column; gap: 5px; }
.filter-group input { padding: 8px; border: 1px solid #e2e8f0; border-radius: 6px; }

.btn { padding: 10px 20px; border-radius: 8px; border: none; cursor: pointer; font-weight: 600; transition: 0.3s; }
.btn-primary { background: var(--primary); color: white; }
.btn-primary:hover { opacity: 0.9; }

.modal-close {
    position: absolute;
    top: 10px;
    right: 15px;
    background: none;
    border: none;
}

/* --- STILOVI ZA SIDEBAR DUGMIĆE --- */
.sidebar-dugme {
    display: block;
    padding: 12px 15px;
    margin: 10px 15px;
    background-color: #34495e;
    color: #ffffff;
    text-decoration: none;
    border-radius: 6px;
    font-weight: bold;
    font-family: sans-serif;
    transition: background-color 0.3s ease, transform 0.1s ease;
    box-sizing: border-box;
    text-align: center;
}

.sidebar-dugme:hover {
    background-color: #2c3e50;
    cursor: pointer;
    transform: translateX(5px);
}

/* Poseban crveni stil za Odjavu da se razlikuje od ostalih */
.sidebar-dugme.dugme-odjava {
    background-color: #e74c3c !important;
}

.sidebar-dugme.dugme-odjava:hover {
    background-color: #c0392b !important;
    transform: none; /* Ne mora da se pomera udesno na hover */
}

/* Bojenje aktivnih izveštaja u tabelama */
tr.aktivni-izvestaj {
    background-color: #ffeaa7 !important; /* Prijatna svetlo narandžasta/žuta boja */
}

tr.aktivni-izvestaj:hover {
    background-color: #ffd859 !important; /* Malo tamnija nijansa kada se pređe mišem */
}

/* Uklanjanje pozadine i stila bedževa za statuse */
.badge {
    background-color: transparent !important;
    color: #2c3e50 !important; /* Ili #000000 ako želiš baš crnu */
    padding: 0 !important;
    border-radius: 0 !important;
    font-weight: normal !important;
    display: inline !important;
    box-shadow: none !important;
    border: none !important;
}

/* Opciono: ako želiš da ukloniš i ikone ako ih imaš u badge-ovima */
.badge::before {
    display: none !important;
}

