/* ---------------- General Styles ---------------- */
body {
    margin: 0;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f4f6f8;
    color: #333;
}

/* ---------------- Header ---------------- */
.header {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 10px 20px;
    background-color: #043061;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 80px;
    z-index: 1000;
}
.header .logo-title {
    display: flex;
    gap: 15px;
    align-items: center;
}
.header .logo-title .logoimg {
    width: 75px;
    background-color: white;
    padding: 2px 5px;
    border-radius: 5px;
}
.header .logo-title h2 {
    color: white;
    font-size: 2.6em;
    margin: 0;
}

/* ---------------- Sidebar ---------------- */
.sidebar {
    position: fixed;
    top: 100px; /* below header */
    left: 0;
    width: 220px;
    height: calc(100% - 80px);
    background-color: #0c2036;
    padding-top: 20px;
    border-top: 2px solid white;
    border-radius: 0 10px 10px 0;
    box-shadow: 2px 0 5px rgba(0,0,0,0.1);
    overflow-y: auto;
    z-index: 100;
}
.sidebar a {
    display: block;
    color: #ecf0f1;
    padding: 12px 20px;
    text-decoration: none;
    margin-bottom: 5px;
    border-radius: 4px;
}
.sidebar a:hover {
    background-color: #1b62aa;
    transition:all 0.3s ease-in-out;
}

/* ---------------- Main Content ---------------- */
.main-content {
    margin-top: 100px; /* space for fixed header */
    margin-left: 240px; /* space for sidebar */
    padding: 20px;
}
h2 {
    color: #2c3e50;
}

/* ---------------- Tables ---------------- */
table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
    background-color: #fff;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}
table th, table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #ddd;
}
table th {
    background-color: #043061;
    color: #fff;
}
table tr:not(:first-child):hover{
    background-color: #727e8a;
    color: #fff;    
}

/* ---------------- Buttons ---------------- */
.btn, .edit-btn, .delete-btn {
    padding: 10px 12px;
    margin: 2px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
    font-size: 1em;
}
.btn {
    background-color: #043061;
    color: white;
}
.btn:hover { background-color: #3498db; }
.editbtn {
    background-color: #043061;
    color: white;
    padding: 3px 8px;
    text-decoration: none;
    border-radius: 4px;
}
.editbtn:hover 
{ background-color: #2ecc71;
 }
.deletebtn {
    background-color: #c0392b;
    color: white;
     padding: 3px 8px;
    text-decoration: none;
    border-radius: 4px;
}
.deletebtn:hover { background-color: #e74c3c; }

/* ---------------- Forms ---------------- */
.form-container, .login-container {
    max-width: 500px;
    margin: 20px auto;
    padding: 20px;
    background-color: #fff;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}
.login-container{
    margin-top: 200px;

}

.input-field {
    width: 100%;
    padding: 10px;
    margin: 8px 0;
    box-sizing: border-box;
    border: 1px solid #ccc;
    border-radius: 4px;
}
button.btn {
    width: 100%;
    margin-top: 10px;
}

/* ---------------- Messages ---------------- */
.success { color: #27ae60; margin-bottom: 10px; }
.error { color: #c0392b; margin-bottom: 10px; }

/* ---------------- Footer ---------------- */
.site-footer {
    background-color: #043061;
    color: white;
    padding: 10px 20px;
    text-align: center;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1000;
}

/* ---------------- Responsive ---------------- */
@media screen and (max-width: 768px) {
    .sidebar {
        width: 100%;
        height: auto;
        position: relative;
    }
    .main-content {
        margin-left: 0;
        margin-top: 120px;
    }
    .header {
        flex-direction: column;
        height: auto;
        padding: 15px;
    }
}
