/* --- Global Styles & Resets --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    height: 100%;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}
body {
    flex: 1 0 auto;
}
html {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background-color: #f5f7fa; /* Default background for dashboard/content pages */
    margin: 0;
}

body.centered-layout {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
}

h1 {
    color: #333;
    margin-bottom: 30px;
    text-align: center;
}

/* --- Navbar Styles (Unchanged) --- */
.navbar {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
    width: 100%; /* Ensures the navbar spans the full width */
}
.navbar-container { max-width: 1200px; margin: 0 auto; padding: 0 20px; display: flex; justify-content: space-between; align-items: center; height: 60px; }
.navbar-logo { color: white; font-size: 24px; font-weight: bold; text-decoration: none; display: inline-flex; align-items: center; gap: 10px; }
.navbar-logo-img { height: 50px; width: auto; display: inline-block; }
.navbar-menu { display: flex; gap: 30px; }
.nav-link { color: white; text-decoration: none; font-size: 14px; padding: 8px 12px; border-radius: 4px; transition: background 0.3s; cursor: pointer; }
.nav-link:hover { background: rgba(255,255,255,0.2); }
.nav-dropdown {
    position: relative;
    user-select: none;
}
.nav-dropdown::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    height: 10px; /* The size of the margin-top on dropdown-menu */
    background-color: transparent;
}
.nav-dropdown > .dropdown-menu {
    display: none;
    position: absolute;
    left: 0;
    top: 100%;
    min-width: 180px;
    background: white;
    color: #1a2b4e;
    box-shadow: 0 8px 24px rgba(0,0,0,0.10);
    border-radius: 8px;
    padding: 8px 0;
    z-index: 2000;
    margin-top: 10px; /* This creates the visual gap */
}
.nav-dropdown:hover > .dropdown-menu,
.nav-dropdown:focus-within > .dropdown-menu {
    display: block;
}
.dropdown-item {
    display: block;
    padding: 10px 24px;
    color: #1a2b4e;
    text-decoration: none;
    font-size: 15px;
    border: none;
    background: none;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
    border-radius: 0;
}
.dropdown-item:hover, .dropdown-item:focus {
    background: #f3f6ff;
    color: #667eea;
}
.nav-dropdown > .dropdown-menu a:last-child {
    border-bottom: none;
}
.navbar-right { display: flex; gap: 15px; align-items: center; }
.btn-nav { padding: 8px 16px; border: none; border-radius: 4px; cursor: pointer; font-size: 14px; text-decoration: none; display: inline-block; transition: all 0.3s; background: none; }
.btn-register { background: white; color: #667eea; }
.btn-register:hover { background: rgba(255,255,255,0.9); }
.btn-logout { background: #ff6b6b; color: white; }
.btn-logout:hover { background: #ff5252; }

/* --- Site Footer --- */
.site-footer {
    background: #0f1724; /* dark slate */
    color: #e6eef9;
    padding: 18px 20px;
    margin-top: auto;
}
.site-footer .footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    gap: 20px;
    align-items: center;
    flex-wrap: wrap;
}
.site-footer .footer-left { display:flex; align-items:center; gap:12px; }
.site-footer .footer-left a { color: #e6eef9; text-decoration: none; font-weight: 700; }

.site-footer .footer-left .footer-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
}
.site-footer .footer-left .footer-logo img {
    height: 50px;
    display: block;
}
.site-footer .footer-links { display:flex; gap:16px; flex-wrap:wrap; }
.site-footer .footer-link { color: #cfe3ff; text-decoration: none; font-size: 14px; }
.site-footer .footer-link:hover { text-decoration: underline; color: #ffffff; }

