:root {
    --primary-teal: #008B8B;
    --light-teal: #20B2AA;
    --sea-green: #2E8B57;
    --mint-green: #3CB371;
    --light-bg: #E0F2F1;
    --very-light-teal: #B2DFDB;
    --dark-teal: #00695C;
    --hover-teal: #26A69A;
    --danger-red: #D32F2F;
    --warning-amber: #FFA726;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 0;
    background-color: var(--light-bg);
}

/* Flash Messages */
.flash-messages-container {
    position: fixed;
    top: 80px;
    right: 24px;
    z-index: 9999;
    max-width: 400px;
}

.flash-alert {
    background: #E8F5E9;
    color: #2E7D32;
    padding: 16px 20px;
    border-radius: 10px;
    border-left: 4px solid #2E8B57;
    margin-bottom: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        transform: translateX(400px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

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

th {
    background-color: var(--primary-teal);
    color: white;
    padding: 12px;
    text-align: left;
    font-weight: 600;
}

thead {
    height: 20px;
    line-height: 20px;
}

td {
    border-bottom: 1px solid var(--very-light-teal);
    padding: 10px 12px;
}

tr:hover {
    background-color: var(--light-bg);
}

/* Modern Navbar */
.modern-navbar {
    background: white;
    border-bottom: 1px solid #E2E8F0;
    padding: 0;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.navbar-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 70px;
}

.navbar-left {
    display: flex;
    align-items: center;
    gap: 32px;
}

.navbar-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    transition: opacity 0.2s ease;
}

.navbar-brand:hover {
    opacity: 0.8;
}

.brand-logo {
    width: 48px;
    height: 48px;
    flex-shrink: 0;
}

.brand-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.brand-text {
    display: flex;
    flex-direction: column;
}

.brand-name {
    font-size: 18px;
    font-weight: 700;
    color: #1A202C;
    line-height: 1.2;
}

.brand-tagline {
    font-size: 12px;
    color: #718096;
    font-weight: 500;
}

.navbar-links {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    border-radius: 8px;
    text-decoration: none;
    color: #4A5568;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.2s ease;
}

.nav-link:hover {
    background: #F7FAFC;
    color: var(--primary-teal);
}

.nav-link svg {
    flex-shrink: 0;
}

.navbar-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.navbar-impilo-logo {
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4px;
    background: linear-gradient(135deg, rgba(0, 139, 139, 0.08) 0%, rgba(255, 183, 77, 0.05) 100%);
    border-radius: 12px;
    border: 1.5px solid rgba(0, 139, 139, 0.15);
    transition: all 0.3s ease;
}

.navbar-impilo-logo:hover {
    background: linear-gradient(135deg, rgba(0, 139, 139, 0.12) 0%, rgba(255, 183, 77, 0.08) 100%);
    border-color: rgba(0, 139, 139, 0.3);
    transform: scale(1.05);
}

.navbar-impilo-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 2px 4px rgba(0, 139, 139, 0.2));
}

.navbar-user-menu {
    position: relative;
}

.user-menu-button {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 12px;
    background: white;
    border: 1px solid #E2E8F0;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.user-menu-button:hover {
    border-color: var(--primary-teal);
    background: #F7FAFC;
}

.user-avatar {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    background: linear-gradient(135deg, var(--primary-teal) 0%, var(--dark-teal) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 700;
    font-size: 14px;
}

.user-info {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.user-name {
    font-size: 14px;
    font-weight: 600;
    color: #1A202C;
    line-height: 1.2;
}

.user-role {
    font-size: 12px;
    color: #718096;
    font-weight: 500;
}

.chevron-icon {
    transition: transform 0.2s ease;
    color: #A0AEC0;
}

.user-menu-button:hover .chevron-icon {
    color: var(--primary-teal);
}

.user-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    min-width: 220px;
    background: white;
    border: 1px solid #E2E8F0;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.2s ease;
    overflow: hidden;
}

.user-dropdown.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    text-decoration: none;
    color: #4A5568;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.dropdown-item:hover {
    background: #F7FAFC;
    color: var(--primary-teal);
}

.dropdown-item.logout {
    color: var(--danger-red);
}

.dropdown-item.logout:hover {
    background: #FFF5F5;
}

.dropdown-divider {
    height: 1px;
    background: #E2E8F0;
    margin: 4px 0;
}

@media (max-width: 768px) {
    .navbar-container {
        padding: 0 16px;
        height: 64px;
    }

    .navbar-left {
        gap: 16px;
    }

    .brand-text {
        display: none;
    }

    .navbar-links {
        display: none;
    }

    .navbar-flag {
        width: 40px;
        height: 40px;
    }

    .user-info {
        display: none;
    }
}

.container {
    width: 1500px;
    height: 1300px;
    margin: 0 auto;
    padding: 2rem;
    padding-top: 5rem; /* Add padding to the top to account for the fixed navbar */
    position: relative; /* Add this to create a new stacking context */
    z-index: 1; /* Lower than navbar */
}

.card {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 4px 6px rgba(0, 139, 139, 0.1);
    border-top: 4px solid var(--primary-teal);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0, 139, 139, 0.15);
}

.form-group {
    margin-bottom: 1rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--dark-teal);
    font-weight: 600;
}

.form-control {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid var(--very-light-teal);
    border-radius: 8px;
    margin-bottom: 1rem;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-teal);
    box-shadow: 0 0 0 3px rgba(0, 139, 139, 0.1);
}

.btn {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.btn-primary {
    background-color: var(--primary-teal);
    color: white;
}

.btn-primary:hover {
    background-color: var(--dark-teal);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 139, 139, 0.3);
}

.btn-primary-edit {
    background-color: var(--warning-amber);
    color: white;
}

.btn-primary-edit:hover {
    background-color: #FF8A00;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(255, 167, 38, 0.3);
}

.btn-danger {
    background-color: var(--danger-red);
    color: white;
}

.btn-danger:hover {
    background-color: #B71C1C;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(211, 47, 47, 0.3);
}

.alert {
    padding: 1rem 1.25rem;
    margin-bottom: 1rem;
    border-radius: 8px;
    border-left: 4px solid;
}

.alert-danger {
    background-color: #FFEBEE;
    color: #C62828;
    border-left-color: var(--danger-red);
}

.alert-success {
    background-color: #E8F5E9;
    color: #2E7D32;
    border-left-color: var(--sea-green);
}

.alert-info {
    background-color: var(--light-bg);
    color: var(--dark-teal);
    border-left-color: var(--primary-teal);
}

/* Admin panel specific fixes */
.admin-header {
    margin-top: 10px; /* Add some space at the top */
}