* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    overflow-x: hidden;
    max-width: 100vw;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background: #f8f9fa;
    min-height: 100vh;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.navbar {
    background: #1a1a1a;
    padding: 1rem 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    position: sticky;
    top: 0;
    z-index: 1000;
    width: 100%;
    max-width: 100vw;
}

.navbar .container {
    max-width: 1600px;
}

.nav-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-brand {
    font-size: 1.5rem;
    font-weight: bold;
    color: #af2924;
    text-decoration: none;
}

.nav-links {
    display: flex;
    gap: 2rem;
    list-style: none;
    align-items: center;
}

.nav-links a {
    text-decoration: none;
    color: #ffffff;
    font-weight: 500;
    transition: color 0.3s ease;
}

.nav-links a:hover {
    color: #af2924;
}

.main-content {
    padding: 2rem 0;
    min-height: calc(100vh - 80px);
    padding-bottom: 4rem; /* Add space for footer */
}

/* Footer Styles */
.footer {
    background: #1a1a1a;
    color: #ffffff;
    padding: 3rem 0 1.5rem;
    margin-top: 4rem;
    border-top: 2px solid #af2924;
}

.footer .container {
    max-width: 1600px;
}

.footer-content {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 2rem;
}

.footer-section {
    display: flex;
    flex-direction: column;
}

.footer-logo {
    align-items: flex-start;
}

.footer-logo-img {
    height: 50px;
    width: auto;
    filter: brightness(0) invert(1);
}

.footer-heading {
    font-size: 1.1rem;
    font-weight: 600;
    color: #af2924;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.footer-link-list,
.footer-contact-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-link-list li,
.footer-contact-list li {
    margin-bottom: 0.75rem;
}

.footer-link-list a,
.footer-contact-list a {
    color: #ffffff;
    text-decoration: none;
    transition: color 0.3s ease;
    font-size: 0.95rem;
}

.footer-link-list a:hover,
.footer-contact-list a:hover {
    color: #af2924;
}

.footer-contact-list li {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.footer-contact-list i {
    color: #af2924;
    width: 20px;
    text-align: center;
    font-size: 1rem;
}

.footer-bottom {
    border-top: 1px solid #333;
    padding-top: 1.5rem;
    text-align: center;
}

.footer-copyright {
    color: #999;
    font-size: 0.9rem;
    margin: 0;
}

/* Footer Responsive Styles */
@media (max-width: 768px) {
    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .footer-logo {
        align-items: center;
    }
    
    .footer-section {
        text-align: center;
    }
    
    .footer-link-list,
    .footer-contact-list {
        align-items: center;
    }
    
    .footer-contact-list li {
        justify-content: center;
    }
    
    .footer {
        padding: 2rem 0 1rem;
    }
}

.card {
    background: #ffffff;
    border-radius: 15px;
    padding: 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    margin: 2rem auto;
    max-width: 1000px;
    overflow: hidden;
}

.card-header {
    background: #af2924;
    color: #ffffff;
    padding: 1.5rem 2rem;
    margin: 0;
    font-size: 1.5rem;
    font-weight: 600;
}

.card-body {
    padding: 2rem;
}

.btn {
    display: inline-block;
    padding: 12px 24px;
    background: #af2924;
    color: white;
    text-decoration: none;
    border-radius: 25px;
    font-weight: 500;
    transition: transform 0.3s ease, box-shadow 0.3s ease, background-color 0.3s ease;
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(175, 41, 36, 0.4);
    background: #8f1f1a;
}

.btn-secondary {
    background: #6c757d;
}

.btn-secondary:hover {
    background: #5a6268;
    box-shadow: 0 5px 15px rgba(108, 117, 125, 0.4);
}

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

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #333;
}

.form-group input {
    width: 100%;
    padding: 12px;
    border: 2px solid #e1e5e9;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.form-group input:focus {
    outline: none;
    border-color: #af2924;
}

.messages {
    position: fixed;
    top: 70px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 9999;
    width: 100%;
    max-width: 600px;
    padding: 0 20px;
    pointer-events: none;
}

.message {
    padding: 1rem 1.5rem;
    border-radius: 8px;
    margin-bottom: 0.75rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    pointer-events: auto;
    animation: slideDown 0.3s ease-out;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
}

.message-close {
    background: none;
    border: none;
    color: inherit;
    font-size: 1.2rem;
    cursor: pointer;
    padding: 0;
    margin-left: 1rem;
    opacity: 0.7;
    transition: opacity 0.2s ease;
    line-height: 1;
}

.message-close:hover {
    opacity: 1;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.message.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.message.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.message.warning {
    background: #fff3cd;
    color: #856404;
    border: 1px solid #ffeaa7;
}

.message.info {
    background: #d1ecf1;
    color: #0c5460;
    border: 1px solid #bee5eb;
}

.welcome-section {
    text-align: center;
    margin-bottom: 2rem;
}

.welcome-section h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: #af2924;
    text-shadow: none;
}

.welcome-section p {
    font-size: 1.2rem;
    color: #666;
    margin-bottom: 2rem;
}

.errorlist {
    color: #dc3545;
    font-size: 0.9rem;
    margin-top: 0.5rem;
    list-style: none;
}

/* Profile Dropdown Styles */
.profile-dropdown {
    position: relative;
}

.profile-icon {
    width: 40px;
    height: 40px;
    background: #af2924;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 1.1rem;
    cursor: pointer;
    transition: background 0.3s ease, transform 0.2s ease;
    user-select: none;
}

.profile-icon:hover {
    background: #8f1f1a;
    transform: scale(1.05);
}

.dropdown-menu {
    position: absolute;
    top: 50px;
    right: 0;
    background: #1a1a1a;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    min-width: 200px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s;
    z-index: 1001;
}

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

.dropdown-menu::before {
    content: '';
    position: absolute;
    top: -8px;
    right: 15px;
    width: 0;
    height: 0;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-bottom: 8px solid #1a1a1a;
}

.dropdown-item {
    display: block;
    padding: 12px 20px;
    color: #ffffff;
    text-decoration: none;
    transition: background 0.2s ease, color 0.2s ease;
    border-bottom: 1px solid #333;
}

.dropdown-item:first-child {
    border-radius: 8px 8px 0 0;
}

.dropdown-item:last-child {
    border-bottom: none;
    border-radius: 0 0 8px 8px;
}

.dropdown-item:hover {
    background: #2d2d2d;
    color: #af2924;
}

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

/* Login Button Styles */
.login-btn {
    display: inline-block;
    padding: 10px 24px;
    background: #af2924;
    color: white !important;
    text-decoration: none;
    border-radius: 25px;
    font-weight: 600;
    transition: transform 0.3s ease, box-shadow 0.3s ease, background-color 0.3s ease;
    border: none;
    cursor: pointer;
}

.login-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(175, 41, 36, 0.4);
    background: #8f1f1a;
    color: white !important;
}

/* Hamburger Menu Styles */
.hamburger-menu {
    display: none;
    flex-direction: column;
    justify-content: space-around;
    width: 30px;
    height: 30px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 1001;
}

.hamburger-menu span {
    width: 100%;
    height: 3px;
    background: #ffffff;
    border-radius: 3px;
    transition: all 0.3s ease;
    transform-origin: center;
}

.hamburger-menu.active span:nth-child(1) {
    transform: rotate(45deg) translate(8px, 8px);
}

.hamburger-menu.active span:nth-child(2) {
    opacity: 0;
}

.hamburger-menu.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}

/* Mobile Responsive Styles */
@media (max-width: 768px) {
    .hamburger-menu {
        display: flex;
    }
    
    .nav-links {
        position: fixed;
        top: 60px;
        left: 0;
        width: 100%;
        max-width: 100vw;
        background: #1a1a1a;
        flex-direction: column;
        gap: 0;
        padding: 1rem 0;
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
        transform: translateX(-100%);
        transition: transform 0.3s ease;
        z-index: 1000;
        max-height: calc(100vh - 60px);
        overflow-y: auto;
        overflow-x: hidden;
        box-sizing: border-box;
    }
    
    .nav-links.active {
        transform: translateX(0);
    }
    
    .nav-links li {
        width: 100%;
        max-width: 100%;
        border-bottom: 1px solid #333;
        box-sizing: border-box;
    }
    
    .nav-links a {
        display: block;
        padding: 1rem 2rem;
        width: 100%;
        box-sizing: border-box;
    }
    
    .nav-links .login-btn {
        display: block;
        width: fit-content;
        margin: 0.5rem auto;
        padding: 10px 24px;
        text-align: center;
        border-radius: 8px;
    }
    
    .profile-dropdown {
        width: 100%;
    }
    
    .profile-icon {
        margin: 0 auto;
    }
    
    .dropdown-menu {
        position: static;
        width: 100%;
        margin-top: 0;
        transform: none;
        opacity: 1;
        visibility: visible;
        box-shadow: none;
        border-radius: 0;
        border-top: 1px solid #333;
    }
    
    .dropdown-menu::before {
        display: none;
    }
    
    .container {
        padding: 0 15px;
    }
    
    .card {
        margin: 1rem auto;
        border-radius: 10px;
    }
    
    .card-header {
        padding: 1rem 1.5rem;
        font-size: 1.25rem;
    }
    
    .card-body {
        padding: 1.5rem;
    }
    
    .main-content {
        padding: 1rem 0;
    }
    
    .messages {
        top: 60px;
        padding: 0 15px;
        max-width: 100%;
    }
    
    .message {
        padding: 0.75rem 1rem;
        font-size: 0.9rem;
    }
    
    .welcome-section h1 {
        font-size: 2rem;
    }
    
    .welcome-section p {
        font-size: 1rem;
    }
    
    .btn {
        padding: 10px 20px;
        font-size: 0.9rem;
    }
    
    .form-group input {
        padding: 10px;
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .nav-brand img {
        height: 25px;
    }
    
    .card-header {
        padding: 0.75rem 1rem;
        font-size: 1.1rem;
    }
    
    .card-body {
        padding: 1rem;
    }
    
    .welcome-section h1 {
        font-size: 1.75rem;
    }
    
    .container {
        padding: 0 10px;
    }
}

/* Mobile-friendly table styles */
@media (max-width: 768px) {
    table {
        font-size: 0.9rem;
    }
    
    table th,
    table td {
        padding: 8px 6px;
    }
    
    /* Make tables scrollable on mobile */
    .table-container {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
}

@media (max-width: 480px) {
    table {
        font-size: 0.85rem;
    }
    
    table th,
    table td {
        padding: 6px 4px;
    }
}

