/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f4f4f4;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    flex: 1;
}

/* Header */
header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    text-align: center;
    padding: 40px 20px;
    margin-bottom: 30px;
    border-radius: 0 0 15px 15px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

header h1 {
    font-size: 2.5em;
    margin-bottom: 10px;
}

header h2 {
    font-size: 1.5em;
    font-weight: normal;
    opacity: 0.9;
}

header p {
    font-size: 1.1em;
    opacity: 0.8;
}

/* Navigation */
.navbar {
    background: #2c3e50;
    color: white;
    padding: 0;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
}

.nav-brand {
    color: white;
    text-decoration: none;
    font-size: 1.5em;
    font-weight: bold;
    padding: 15px 0;
}

.nav-menu {
    display: flex;
    gap: 20px;
    align-items: center;
}

.nav-link {
    color: white;
    text-decoration: none;
    padding: 15px 20px;
    display: inline-block;
    transition: background-color 0.3s;
}

.nav-link:hover, .nav-link.active {
    background-color: #34495e;
}

.nav-text {
    color: #ecf0f1;
    padding: 15px 10px;
}

/* Main Content Layout */
.main-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-top: 30px;
}

.welcome-section, .auth-section {
    background: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

/* Forms */
.form-container {
    background: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin-top: 20px;
}

.auth-box {
    background: white;
    padding: 30px;
    border-radius: 10px;
}

.form-group {
    margin-bottom: 20px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: #555;
}

.form-control {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 14px;
    transition: border-color 0.3s;
}

.form-control:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

textarea.form-control {
    resize: vertical;
    min-height: 100px;
}

select.form-control {
    cursor: pointer;
}

.form-group small {
    display: block;
    margin-top: 5px;
    color: #666;
    font-size: 12px;
}

.checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-weight: normal !important;
    cursor: pointer;
}

.checkbox-label input[type="checkbox"] {
    margin-top: 3px;
    cursor: pointer;
}

/* Buttons */
.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 5px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s;
    text-align: center;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.btn-secondary {
    background: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background: #5a6268;
}

.btn-block {
    display: block;
    width: 100%;
    margin-top: 10px;
}

/* Alerts */
.alert {
    padding: 15px 20px;
    border-radius: 5px;
    margin-bottom: 20px;
}

.alert ul {
    margin: 10px 0 0 20px;
}

.alert-success {
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
}

.alert-danger {
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}

.alert-warning {
    background-color: #fff3cd;
    border: 1px solid #ffeaa7;
    color: #856404;
}

.alert-info {
    background-color: #d1ecf1;
    border: 1px solid #bee5eb;
    color: #0c5460;
}

/* Info Boxes */
.info-box {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 5px;
    margin: 20px 0;
    border-left: 4px solid #667eea;
}

.info-box h4 {
    margin-bottom: 10px;
    color: #667eea;
}

.info-box ul {
    margin-left: 20px;
}

/* Search */
.search-container {
    background: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin-bottom: 30px;
}

.search-form {
    margin-bottom: 20px;
}

.search-box {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
}

.search-input {
    flex: 1;
    padding: 15px;
    border: 2px solid #ddd;
    border-radius: 5px;
    font-size: 16px;
}

.search-input:focus {
    outline: none;
    border-color: #667eea;
}

.search-type {
    padding: 15px;
    border: 2px solid #ddd;
    border-radius: 5px;
    font-size: 14px;
    background: white;
    cursor: pointer;
}

.search-tips {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 5px;
    font-size: 14px;
}

.search-tips ul {
    margin-left: 20px;
    margin-top: 10px;
}

/* Search Results */
.search-results {
    margin-top: 30px;
}

.results-count {
    color: #666;
    margin-bottom: 20px;
    font-size: 14px;
}

.documents-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 20px;
}

.document-card {
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    padding: 20px;
    transition: all 0.3s;
}

.document-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    transform: translateY(-2px);
}

.document-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
    flex-wrap: wrap;
    gap: 10px;
}

.resolution-badge, .date-badge {
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.resolution-badge {
    background: #e3f2fd;
    color: #1976d2;
}

.date-badge {
    background: #f3e5f5;
    color: #7b1fa2;
}

.document-title {
    font-size: 1.1em;
    margin-bottom: 10px;
    color: #2c3e50;
    line-height: 1.4;
}

.document-description {
    color: #666;
    font-size: 14px;
    margin-bottom: 15px;
    line-height: 1.5;
}

.document-keywords {
    margin: 15px 0;
}

.keyword-tag {
    display: inline-block;
    background: #f0f0f0;
    padding: 4px 10px;
    border-radius: 15px;
    font-size: 12px;
    margin: 2px;
    color: #555;
}

.document-category {
    color: #666;
    font-size: 14px;
    margin-bottom: 15px;
}

.document-actions {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #e0e0e0;
}

/* Document Detail */
.document-detail-box {
    background: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin-bottom: 30px;
}

.document-detail-box h2 {
    color: #667eea;
    margin-bottom: 20px;
}

.document-detail-box p {
    margin-bottom: 15px;
    line-height: 1.6;
}

/* Requests */
.status-summary {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 15px;
    margin-bottom: 30px;
}

.status-card {
    background: white;
    padding: 20px;
    border-radius: 10px;
    text-align: center;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.status-card.status-ready {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.status-count {
    font-size: 2.5em;
    font-weight: bold;
    margin-bottom: 5px;
}

.status-label {
    font-size: 14px;
    opacity: 0.8;
}

.requests-section {
    margin-bottom: 40px;
}

.requests-section h2 {
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #667eea;
}

.highlight-section {
    background: linear-gradient(to right, #f8f9fa, white);
    padding: 20px;
    border-radius: 10px;
    border: 2px solid #667eea;
}

.request-card {
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 15px;
    transition: all 0.3s;
}

.request-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.request-ready {
    border-left: 5px solid #4caf50;
}

.request-completed {
    opacity: 0.7;
}

.request-cancelled {
    opacity: 0.6;
    border-left: 5px solid #f44336;
}

.request-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    flex-wrap: wrap;
    gap: 10px;
}

.request-number {
    font-weight: bold;
    color: #667eea;
    font-size: 1.1em;
}

.request-date {
    color: #666;
    font-size: 14px;
}

.request-body {
    color: #555;
    line-height: 1.6;
}

.request-body p {
    margin-bottom: 10px;
}

/* Badges */
.badge {
    display: inline-block;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.badge-warning {
    background: #fff3cd;
    color: #856404;
}

.badge-info {
    background: #d1ecf1;
    color: #0c5460;
}

.badge-success {
    background: #d4edda;
    color: #155724;
}

.badge-secondary {
    background: #e2e3e5;
    color: #383d41;
}

.badge-danger {
    background: #f8d7da;
    color: #721c24;
}

/* Pickup Code Display */
.pickup-code-display {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 15px 20px;
    border-radius: 10px;
    text-align: center;
}

.pickup-code-label {
    display: block;
    font-size: 12px;
    opacity: 0.9;
    margin-bottom: 5px;
}

.pickup-code {
    font-size: 24px;
    font-weight: bold;
    letter-spacing: 3px;
}

.pickup-info-box {
    background: #e8f5e9;
    border: 2px solid #4caf50;
    border-radius: 10px;
    padding: 20px;
    margin-top: 15px;
}

.pickup-info-box h4 {
    color: #2e7d32;
    margin-bottom: 15px;
}

.pickup-info-box ul {
    margin-left: 20px;
}

.staff-notes {
    background: #fff3cd;
    border-left: 4px solid #ffc107;
    padding: 15px;
    margin: 15px 0;
    border-radius: 5px;
}

/* Success Container */
.success-container {
    max-width: 800px;
    margin: 0 auto;
}

.request-details-box {
    background: white;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin: 20px 0;
}

/* Page Header */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    flex-wrap: wrap;
    gap: 15px;
}

.page-header h1 {
    color: #2c3e50;
}

/* Utilities */
.text-center {
    text-align: center;
}

.text-muted {
    color: #6c757d;
}

.text-info {
    color: #0c5460;
}

.text-success {
    color: #155724;
}

.text-danger {
    color: #721c24;
}

.mt-3 {
    margin-top: 1rem;
}

.mt-4 {
    margin-top: 1.5rem;
}

/* Footer */
footer {
    background: #2c3e50;
    color: white;
    text-align: center;
    padding: 20px;
    margin-top: 50px;
}

/* Responsive */
@media (max-width: 768px) {
    .main-content {
        grid-template-columns: 1fr;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .search-box {
        flex-direction: column;
    }
    
    .documents-grid {
        grid-template-columns: 1fr;
    }
    
    .status-summary {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .nav-menu {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .page-header {
        flex-direction: column;
        align-items: flex-start;
    }
}

@media print {
    .navbar, .btn, footer {
        display: none;
    }
    
    .request-card {
        page-break-inside: avoid;
    }
}