*{
    box-sizing:border-box;
    margin:0;
    padding:0;
    font-family:system-ui,-apple-system,Segoe UI,Roboto,Ubuntu,sans-serif;
}

body.site-body{
    display: flex;
    flex-direction: column;
    min-height: 100vh; /* sticky footer */
    background:#f5f7fb;
    color:#222;
    line-height:1.5;
}

/* HEADER */

.site-header{
    background:#0c4a8a;
    padding:16px 0;
}

.logo{
    display:flex;
    align-items:center;
    max-width:1200px;
    margin:auto;
    padding:0 20px;
}

.logo img{
    height:40px;
    margin-right:12px;
}

.logo-text a{
    color:white;
    font-size:22px;
    font-weight:600;
    text-decoration:none;
}

/* NAV */

.site-nav{
    background:#1565c0;
}

.nav-container{
    max-width:1200px;
    margin:auto;
    padding:10px 20px;
    display:flex;
    align-items:center;
}

.nav-links{
    display:flex;
    gap:18px;
    align-items:center;
}

.nav-links a{
    color:white;
    text-decoration:none;
    font-size:14px;
}

.nav-links a:hover{
    opacity:0.8;
}

.button{
    background:#0d47a1;
    padding:6px 12px;
    border-radius:4px;
}

/* MAIN CONTENT */

.site-main{
    flex: 1 0 auto; /* sticky footer fix */
    max-width:1200px;
    margin:auto;
    padding:30px 20px;
    min-height:70vh;
}

/* DASHBOARD GRID */

.dashboard-grid{
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(220px,1fr));
    gap:20px;
    margin-top:20px;
}

/* Make cards stretch evenly to fill rows */
.dashboard-grid .card{
    display:flex;
    flex-direction:column;
    justify-content:space-between;
    background:white;
    border-radius:8px;
    padding:20px;
    box-shadow:0 2px 6px rgba(0,0,0,0.08);
}

.card h3{
    margin-bottom:10px;
}

/* ENTITY LIST */

.entity-grid{
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(250px,1fr));
    gap:20px;
    margin-top:20px;
}

.entity-card{
    background:white;
    padding:20px;
    border-radius:8px;
    box-shadow:0 2px 6px rgba(0,0,0,0.08);
}

.entity-actions{
    margin-top:15px;
    display:flex;
    gap:10px;
}

.btn{
    padding:6px 12px;
    background:#1565c0;
    color:white;
    text-decoration:none;
    border-radius:4px;
    font-size:14px;
}

.btn-danger{
    background:#c62828;
}

/* FORMS */

.form-box{
    max-width:600px;
    background:white;
    padding:25px;
    border-radius:8px;
    box-shadow:0 2px 6px rgba(0,0,0,0.08);
}

.form-box input,
.form-box select{
    width:100%;
    padding:8px;
    margin-top:6px;
    margin-bottom:15px;
    border:1px solid #ccc;
    border-radius:4px;
}

/* FOOTER */

.site-footer{
    background:#0c4a8a;
    color:white;
    text-align:center;
    padding:15px;
    flex-shrink:0; /* sticky footer */
}

/* MOBILE NAV */
.nav-links {
    flex-direction: row;
}

.nav-toggle {
    display: none;
    background: #0d47a1;
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 18px;
    cursor: pointer;
}

/* Responsive for small screens */
@media (max-width:768px) {
    .nav-container {
        flex-wrap: wrap;
    }

    .nav-toggle {
        display: block;
        margin-left: auto;
    }

    .nav-links {
        display: none;
        width: 100%;
        flex-direction: column;
        gap: 10px;
        margin-top: 10px;
    }

    .nav-links.active {
        display: flex;
    }

    .nav-links a {
        padding: 10px;
        background: #1565c0;
        border-radius: 4px;
        text-align: center;
    }
}
