/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    background-color: #f5f5f5;
    color: #333;
    line-height: 1.6;
}

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

/* Header */
.header {
    background-color: #2563eb;
    color: white;
    padding: 15px 0;
    margin-bottom: 30px;
}

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

.header h1 {
    font-size: 24px;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

/* Login Box */
.login-box {
    max-width: 400px;
    margin: 100px auto;
    background: white;
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.login-box h1 {
    text-align: center;
    color: #2563eb;
    margin-bottom: 10px;
}

.login-box p {
    text-align: center;
    color: #666;
    margin-bottom: 30px;
}

/* Form Elements */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: #555;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: #2563eb;
}

.form-group small {
    display: block;
    margin-top: 5px;
    color: #666;
    font-size: 12px;
}

.form-box {
    background: white;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

/* Buttons */
.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s;
}

.btn-primary {
    background-color: #2563eb;
    color: white;
    width: 100%;
}

.btn-primary:hover {
    background-color: #1d4ed8;
}

.btn-secondary {
    background-color: #6b7280;
    color: white;
    width: 100%;
    margin-top: 10px;
}

.btn-secondary:hover {
    background-color: #4b5563;
}

.btn-success {
    background-color: #16a34a;
    color: white;
}

.btn-success:hover {
    background-color: #15803d;
}

.btn-small {
    padding: 8px 16px;
    font-size: 13px;
}

/* Messages */
.message {
    padding: 12px;
    border-radius: 4px;
    margin-bottom: 20px;
    text-align: center;
}

.message.success {
    background-color: #d1fae5;
    color: #065f46;
    border: 1px solid #10b981;
}

.message.error {
    background-color: #fee2e2;
    color: #991b1b;
    border: 1px solid #ef4444;
}

.message.hidden {
    display: none;
}

/* Tabs */
.tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    border-bottom: 2px solid #e5e7eb;
}

.tab-btn {
    padding: 12px 24px;
    background: none;
    border: none;
    border-bottom: 3px solid transparent;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    color: #6b7280;
    transition: all 0.3s;
}

.tab-btn:hover {
    color: #2563eb;
}

.tab-btn.active {
    color: #2563eb;
    border-bottom-color: #2563eb;
}

/* Tab Content */
.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

.tab-content h2 {
    margin-bottom: 20px;
    color: #1f2937;
}

/* Tables */
table {
    width: 100%;
    background: white;
    border-collapse: collapse;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

thead {
    background-color: #f3f4f6;
}

th, td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #e5e7eb;
}

th {
    font-weight: 600;
    color: #374151;
}

tbody tr:hover {
    background-color: #f9fafb;
}

.loading {
    text-align: center;
    color: #6b7280;
    padding: 40px !important;
}

/* Status Badges */
.status {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
}

.status-available {
    background-color: #d1fae5;
    color: #065f46;
}

.status-unavailable {
    background-color: #fee2e2;
    color: #991b1b;
}

.status-checked-out {
    background-color: #fef3c7;
    color: #92400e;
}

.status-unavailable {
    background-color: #fee2e2;
    color: #991b1b;
}

/* Utilities */
.hidden {
    display: none !important;
}

/* Responsive */
@media (max-width: 768px) {
    .header .container {
        flex-direction: column;
        gap: 10px;
    }
    
    .tabs {
        flex-direction: column;
    }
    
    table {
        font-size: 14px;
    }
    
    th, td {
        padding: 8px;
    }
}

/* Logout button specific styling */
.user-info .btn-small {
    background-color: #dc2626;
    color: white;
    padding: 8px 16px;
    font-size: 13px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s;
}

.user-info .btn-small:hover {
    background-color: #b91c1c;
}

.user-info .btn-small:active {
    transform: scale(0.95);
}

/* Make user info section more visible */
.user-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.user-info span {
    font-size: 14px;
    font-weight: 500;
}
