/* Archive Page Specific Styles */

/* Archive Hero Section */
.archive-hero {
    background: linear-gradient(135deg, #87CEEB 0%, #4682B4 100%);
    background-size: cover;
    background-position: center;
    color: white;
    padding: 150px 0 80px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.archive-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

.archive-hero-content {
    position: relative;
    z-index: 1;
}

.archive-hero-content h1 {
    font-size: 3.5rem;
    margin-bottom: 20px;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.archive-hero-content h1 .highlight {
    background: linear-gradient(135deg, #ffffff 0%, #e3f2fd 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    font-weight: 700;
}

.archive-hero-content p {
    font-size: 1.3rem;
    max-width: 700px;
    margin: 0 auto 40px;
    opacity: 0.9;
    line-height: 1.6;
}

.archive-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    margin-top: 50px;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.archive-stat {
    text-align: center;
    padding: 20px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
}

.archive-stat:hover {
    transform: translateY(-5px);
    background: rgba(255, 255, 255, 0.15);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.archive-stat .stat-number {
    font-size: 3rem;
    font-weight: 700;
    display: block;
    margin-bottom: 10px;
    text-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
    background: linear-gradient(135deg, #ffffff 0%, #e3f2fd 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.archive-stat .stat-text {
    font-size: 1rem;
    opacity: 0.9;
    font-weight: 500;
}

/* Archive Controls */
.archive-controls {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    padding: 25px 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    position: sticky;
    top: 80px;
    z-index: 100;
    border-bottom: 1px solid #e9ecef;
    backdrop-filter: blur(10px);
}

@media (min-width: 1025px) {
    .archive-controls {
        padding: 20px 0;
    }
}

.controls-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 25px;
    flex-wrap: wrap;
    padding: 0 20px;
}

@media (min-width: 1025px) {
    .controls-container {
        gap: 20px;
        padding: 0 15px;
    }
}

.search-box {
    display: flex;
    flex: 1;
    max-width: 450px;
    position: relative;
    background: white;
    border-radius: 12px;
    border: 2px solid #dee2e6;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    overflow: hidden;
}

@media (min-width: 1025px) {
    .search-box {
        max-width: 400px;
        border-radius: 10px;
    }
}

.search-box:focus-within {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(15, 117, 188, 0.1), 0 4px 15px rgba(15, 117, 188, 0.15);
    transform: translateY(-1px);
}

.search-box input {
    flex: 1;
    padding: 14px 20px 14px 18px;
    border: none;
    background: transparent;
    font-size: 1rem;
    transition: all 0.3s ease;
    font-family: 'Poppins', sans-serif;
    color: var(--dark);
    outline: none;
}

@media (min-width: 1025px) {
    .search-box input {
        padding: 12px 18px 12px 16px;
        font-size: 0.95rem;
    }
}

.search-box input::placeholder {
    color: #adb5bd;
    font-weight: 400;
}

.search-box button {
    position: absolute;
    right: 4px;
    top: 50%;
    transform: translateY(-50%);
    background: linear-gradient(135deg, var(--primary) 0%, #0d5aa7 100%);
    color: white;
    border: none;
    padding: 12px 16px;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    box-shadow: 0 3px 12px rgba(15, 117, 188, 0.25);
    border: 2px solid transparent;
    overflow: hidden;
    min-width: 48px;
    height: 40px;
}

@media (min-width: 1025px) {
    .search-box button {
        padding: 10px 14px;
        font-size: 0.85rem;
        min-width: 44px;
        height: 36px;
    }
}

.search-box button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.5s ease;
}

.search-box button:hover::before {
    left: 100%;
}

.search-box button:hover {
    background: linear-gradient(135deg, #0d5aa7 0%, #0a4785 100%);
    transform: translateY(-50%) scale(1.05);
    box-shadow: 0 6px 20px rgba(15, 117, 188, 0.4);
    border-color: rgba(255, 255, 255, 0.2);
}

.search-box button:active {
    transform: translateY(-50%) scale(0.98);
    box-shadow: 0 3px 10px rgba(15, 117, 188, 0.3);
}

.search-box button i {
    font-size: 1rem;
    transition: transform 0.3s ease;
}

@media (min-width: 1025px) {
    .search-box button i {
        font-size: 0.9rem;
    }
}

.search-box button:hover i {
    transform: scale(1.1);
}

.search-box button:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(255, 152, 0, 0.2), 0 3px 12px rgba(15, 117, 188, 0.25);
}

.filter-controls {
    display: flex;
    gap: 20px;
    align-items: center;
    flex-wrap: wrap;
    padding: 20px;
    background: rgba(248, 249, 250, 0.8);
    border-radius: 12px;
    border: 1px solid #e9ecef;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

@media (min-width: 1025px) {
    .filter-controls {
        padding: 15px 20px;
        gap: 15px;
    }
}

.filter-controls select {
    padding: 12px 16px;
    border: 2px solid #dee2e6;
    border-radius: 10px;
    font-size: 0.9rem;
    background: white;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Poppins', sans-serif;
    min-width: 160px;
    color: var(--dark);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    position: relative;
}

.filter-controls select:hover {
    border-color: var(--primary);
    box-shadow: 0 3px 8px rgba(15, 117, 188, 0.15);
    transform: translateY(-1px);
}

.filter-controls select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(15, 117, 188, 0.1), 0 2px 4px rgba(0, 0, 0, 0.05);
    background: #fafbfc;
}

.filter-controls select option {
    padding: 8px;
    background: white;
    color: var(--dark);
}

.btn-secondary {
    background: white;
    border: 2px solid var(--primary);
    color: var(--primary);
    padding: 12px 18px;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Poppins', sans-serif;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
    box-shadow: 0 2px 8px rgba(15, 117, 188, 0.1);
    position: relative;
    overflow: hidden;
}

.btn-secondary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.5s ease;
}

.btn-secondary:hover::before {
    left: 100%;
}

.btn-secondary:hover {
    background: var(--primary);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(15, 117, 188, 0.3);
    border-color: var(--primary);
}

.btn-secondary:active {
    transform: translateY(0);
    box-shadow: 0 3px 10px rgba(15, 117, 188, 0.2);
}

/* Document Counter */
.document-counter {
    margin-bottom: 20px;
    padding: 15px;
    background: var(--light);
    border-radius: 8px;
    text-align: center;
    font-weight: 500;
    color: var(--text-dark);
    border: 1px solid #e9ecef;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.document-counter i {
    margin-right: 8px;
    color: var(--primary);
    font-size: 1.1rem;
}

.document-counter:hover {
    background: white;
    border-color: var(--primary);
    box-shadow: 0 4px 15px rgba(15, 117, 188, 0.1);
}

.document-counter.highlight-warning {
    background: #fff3e0;
    border-color: #f57c00;
    color: #e65100;
}

.document-counter.highlight-error {
    background: #ffebee;
    border-color: #d32f2f;
    color: #b71c1c;
}

/* Archive Content */
.archive-content {
    padding: 80px 0;
    background: linear-gradient(135deg, #f8fafc 0%, #ffffff 100%);
    min-height: 60vh;
}

.archive-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(420px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
}

.document-card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    border: 1px solid #f1f3f4;
    min-height: 320px;
    display: flex;
    flex-direction: column;
}

@media (min-width: 1025px) {
    .document-card {
        min-height: 350px;
        padding-bottom: 10px;
    }
    
    .document-body {
        flex: 1;
        display: flex;
        flex-direction: column;
        justify-content: space-between;
    }
    
    .document-actions {
        margin-top: auto;
    }
}

.document-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.document-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: var(--gradient);
    z-index: 2;
}
.document-header {
    padding: 18px 20px 12px;
    border-bottom: 1px solid #f1f3f4;
}

@media (min-width: 1025px) {
    .document-header {
        padding: 15px 18px 10px;
    }
}

.document-body {
    padding: 15px 20px 20px;
}

@media (min-width: 1025px) {
    .document-body {
        padding: 12px 18px 18px;
    }
}

.document-title {
    font-size: 1.2rem;
    color: var(--dark);
    margin-bottom: 8px;
    line-height: 1.3;
    font-weight: 600;
}

@media (min-width: 1025px) {
    .document-title {
        font-size: 1.1rem;
        margin-bottom: 6px;
    }
}

.document-description {
    color: var(--text-light);
    margin-bottom: 12px;
    line-height: 1.4;
    font-size: 0.85rem;
}

@media (min-width: 1025px) {
    .document-description {
        margin-bottom: 10px;
        font-size: 0.8rem;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }
}

.document-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 12px;
}

@media (min-width: 1025px) {
    .document-tags {
        gap: 4px;
        margin-bottom: 10px;
    }
    
    .document-tag {
        padding: 3px 8px;
        border-radius: 10px;
        font-size: 0.7rem;
    }
}

/* Enhanced document card styling */
.document-card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    border: 1px solid #f1f3f4;
}

.document-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: var(--gradient);
    z-index: 2;
}

/* Enhanced document header with better spacing */
.document-header {
    padding: 25px 25px 15px;
    border-bottom: 1px solid #f1f3f4;
    position: relative;
}

/* Better category section organization */
.document-category-section {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
    flex-wrap: wrap;
}

/* Enhanced title styling */
.document-title {
    font-size: 1.3rem;
    color: var(--dark);
    margin-bottom: 12px;
    line-height: 1.4;
    font-weight: 600;
    letter-spacing: -0.02em;
}

.document-category-section {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
    flex-wrap: wrap;
}

.document-category {
    display: inline-block;
    background: var(--gradient);
    color: white;
    padding: 6px 15px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.importance-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.importance-badge.high {
    background: #e74c3c;
    color: white;
}

.importance-badge.medium {
    background: #f39c12;
    color: white;
}

.importance-badge.low {
    background: #95a5a6;
    color: white;
}

.document-title {
    font-size: 1.3rem;
    color: var(--dark);
    margin-bottom: 12px;
    line-height: 1.4;
    font-weight: 600;
}

.document-meta {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 10px;
    color: var(--text-light);
    font-size: 0.8rem;
    margin: 12px 0;
}

@media (min-width: 1025px) {
    .document-meta {
        grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
        gap: 6px;
        font-size: 0.7rem;
        margin: 10px 0;
    }
    
    .document-meta span {
        padding: 6px 8px;
        border-radius: 6px;
        font-size: 0.7rem;
        min-height: auto;
        white-space: nowrap;
    }
    
    .document-meta span i {
        font-size: 0.7rem;
        width: 12px;
    }
}

.document-meta span {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 12px;
    background: var(--light);
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.3s ease;
    border: 1px solid rgba(0, 0, 0, 0.05);
    min-height: 42px;
}

.document-meta span:hover {
    background: #e9ecef;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    border-color: var(--primary);
}

.document-meta span i {
    color: var(--primary);
    font-size: 0.9rem;
    width: 16px;
    text-align: center;
    flex-shrink: 0;
}

/* Enhanced meta layout for better organization */
.document-meta-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 15px 0;
    padding: 0;
}

.document-meta-row-left,
.document-meta-row-right {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    flex: 1;
}

.document-meta-row-right {
    justify-content: flex-end;
}

/* Special styling for file type and size */
.document-meta .file-type,
.document-meta .file-size {
    background: linear-gradient(135deg, rgba(15, 117, 188, 0.1) 0%, rgba(38, 170, 225, 0.1) 100%);
    border-color: rgba(15, 117, 188, 0.2);
    font-weight: 600;
}

.document-meta .file-type:hover,
.document-meta .file-size:hover {
    background: linear-gradient(135deg, rgba(15, 117, 188, 0.15) 0%, rgba(38, 170, 225, 0.15) 100%);
}

.document-body {
    padding: 20px 25px;
}

.document-description {
    color: var(--text-light);
    margin-bottom: 20px;
    line-height: 1.6;
    font-size: 0.95rem;
}

.document-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
}

.document-tag {
    background: rgba(15, 117, 188, 0.1);
    color: var(--primary);
    padding: 5px 12px;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 500;
    border: 1px solid rgba(15, 117, 188, 0.2);
    transition: all 0.3s ease;
}

.document-tag:hover {
    background: var(--primary);
    color: white;
    transform: translateY(-1px);
}

.document-actions {
    display: flex;
    gap: 8px;
}

@media (min-width: 1025px) {
    .document-actions {
        gap: 6px;
        padding-top: 8px;
    }
    
    .document-btn {
        padding: 8px 10px;
        font-size: 0.8rem;
        gap: 4px;
    }
    
    .document-btn i {
        font-size: 0.75rem;
    }
}

.document-btn {
    flex: 1;
    padding: 12px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-family: 'Poppins', sans-serif;
    font-weight: 500;
    position: relative;
    overflow: hidden;
}

.document-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.2);
    transition: left 0.3s ease;
}

.document-btn:hover::before {
    left: 100%;
}

.document-btn.preview {
    background: var(--light);
    color: var(--primary);
    border: 2px solid transparent;
}

.document-btn.preview:hover {
    background: var(--primary);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(15, 117, 188, 0.3);
}

.document-btn.download {
    background: var(--gradient);
    color: white;
    border: 2px solid transparent;
}

.document-btn.download:hover {
    background: var(--primary);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(15, 117, 188, 0.3);
}

/* Loading State */
.loading-state {
    text-align: center;
    padding: 80px 0;
}

.loading-spinner {
    width: 60px;
    height: 60px;
    border: 4px solid var(--light);
    border-top: 4px solid var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 25px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loading-state p {
    color: var(--text-light);
    font-size: 1.1rem;
    font-weight: 500;
}

/* No Results State */
.no-results {
    text-align: center;
    padding: 80px 0;
    color: var(--text-light);
}

.no-results i {
    font-size: 4rem;
    margin-bottom: 20px;
    opacity: 0.5;
    color: var(--primary);
}

.no-results h3 {
    margin-bottom: 15px;
    color: var(--dark);
    font-size: 1.5rem;
}

.no-results p {
    margin-bottom: 25px;
    font-size: 1.1rem;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
    margin-top: 50px;
    flex-wrap: wrap;
}

.pagination-btn {
    padding: 12px 18px;
    border: 2px solid var(--light);
    background: white;
    color: var(--text);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
    font-family: 'Poppins', sans-serif;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 45px;
    justify-content: center;
}

.pagination-btn:hover:not(.disabled):not(.active) {
    border-color: var(--primary);
    color: var(--primary);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.pagination-btn.active {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
    box-shadow: 0 5px 15px rgba(15, 117, 188, 0.3);
}

.pagination-btn.disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.pagination-pages {
    display: flex;
    gap: 8px;
}

/* Quick Access Section */
.quick-access {
    padding: 80px 0;
    background: white;
}

.quick-access h2 {
    text-align: center;
    margin-bottom: 15px;
    color: var(--dark);
    font-size: 2.5rem;
}

.quick-access h2 .highlight {
    background: var(--gradient);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.quick-access-subtitle {
    text-align: center;
    color: var(--text-light);
    font-size: 1.1rem;
    margin-bottom: 50px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.quick-access-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
    margin-bottom: 50px;
}

.quick-access-card {
    background: white;
    padding: 35px 30px;
    border-radius: 15px;
    text-align: center;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 2px solid transparent;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.quick-access-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: var(--gradient);
}

.quick-access-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
    border-color: var(--primary);
}

.quick-access-icon {
    width: 80px;
    height: 80px;
    background: var(--gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 25px;
    color: white;
    font-size: 2rem;
    box-shadow: 0 8px 25px rgba(15, 117, 188, 0.3);
    transition: all 0.3s ease;
}

.quick-access-card:hover .quick-access-icon {
    transform: scale(1.1) rotate(5deg);
}

.quick-access-card h3 {
    margin-bottom: 15px;
    color: var(--dark);
    font-size: 1.4rem;
    font-weight: 600;
}

.quick-access-card .document-count {
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 15px;
    font-size: 1.1rem;
}

.quick-access-card p {
    color: var(--text-light);
    line-height: 1.6;
    margin-bottom: 20px;
    font-size: 0.95rem;
}

.quick-access-card .document-types {
    display: flex;
    gap: 8px;
    justify-content: center;
}

.doc-type {
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.doc-type.pdf {
    background: #e74c3c;
    color: white;
}

.doc-type.image {
    background: #3498db;
    color: white;
}

/* PDF Viewer Specific Styles */
.pdf-nav-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.pdf-nav-btn:disabled:hover {
    transform: none;
    box-shadow: none;
}

.pdf-page-info {
    font-weight: 600;
    color: var(--dark);
    background: white !important;
    border: 1px solid #dee2e6;
}

.pdf-loading {
    text-align: center;
    color: var(--text-light);
}

.pdf-loading .loading-spinner {
    width: 40px;
    height: 40px;
    border-width: 3px;
    margin: 0 auto 15px;
}

#pdfCanvas {
    display: block;
    margin: 20px auto;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    border-radius: 8px;
    background: white;
    max-width: 100%;
    height: auto;
}

.pdf-viewer-content {
    position: relative;
    min-height: 300px;
}

.pdf-viewer-content::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

.pdf-viewer-content::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.pdf-viewer-content::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

.pdf-viewer-content::-webkit-scrollbar-thumb:hover {
    background: #a1a1a1;
}

/* Enhanced Document Preview Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    padding: 20px;
    backdrop-filter: blur(5px);
}

.modal-content {
    background: white;
    border-radius: 15px;
    max-width: 900px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.3);
    position: relative;
    animation: modalAppear 0.3s ease-out;
}

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

.modal-header {
    padding: 25px 30px;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    background: white;
    z-index: 1;
    border-radius: 15px 15px 0 0;
}

.modal-header h3 {
    color: var(--dark);
    font-size: 1.5rem;
    font-weight: 600;
    margin: 0;
}

.close-modal {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--text-light);
    cursor: pointer;
    transition: all 0.3s;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.close-modal:hover {
    color: var(--accent);
    background: #f8f9fa;
}

.modal-body {
    padding: 30px;
}

.document-preview {
    margin-bottom: 30px;
}

.preview-header-enhanced {
    margin-bottom: 30px;
}

.document-preview-header {
    display: flex;
    align-items: center;
    gap: 25px;
    margin-bottom: 25px;
}

.preview-icon {
    width: 90px;
    height: 90px;
    background: var(--gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 2.2rem;
    flex-shrink: 0;
    box-shadow: 0 8px 25px rgba(15, 117, 188, 0.3);
}

.preview-title h3 {
    margin-bottom: 10px;
    color: var(--dark);
    font-size: 1.6rem;
    font-weight: 600;
}

.preview-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.preview-stat-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 20px;
    background: var(--light);
    border-radius: 10px;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.preview-stat-item:hover {
    background: white;
    border-color: var(--primary);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.stat-icon {
    width: 45px;
    height: 45px;
    background: var(--gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.1rem;
    flex-shrink: 0;
}

.stat-content {
    flex: 1;
}

.stat-label {
    display: block;
    font-size: 0.85rem;
    color: var(--text-light);
    margin-bottom: 4px;
    font-weight: 500;
}

.stat-value {
    display: block;
    font-weight: 600;
    color: var(--dark);
    font-size: 1rem;
}

.importance-text.high {
    color: #e74c3c;
    font-weight: 600;
}

.importance-text.medium {
    color: #f39c12;
    font-weight: 600;
}

.importance-text.low {
    color: #95a5a6;
    font-weight: 600;
}

.preview-content-enhanced {
    background: white;
    border-radius: 10px;
    padding: 25px;
    border: 1px solid #e9ecef;
}

.description-section,
.tags-section {
    margin-bottom: 25px;
}

.description-section h4,
.tags-section h4 {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
    color: var(--dark);
    font-size: 1.1rem;
    font-weight: 600;
}

.description-section i,
.tags-section i {
    color: var(--primary);
}

.preview-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.document-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
    padding-top: 25px;
    border-top: 1px solid #e9ecef;
}

/* Notification Styles */
.notification-container {
    position: fixed;
    top: 100px;
    right: 20px;
    z-index: 3000;
    max-width: 350px;
}

.notification {
    background: white;
    padding: 15px 20px;
    border-radius: 8px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 12px;
    border-left: 4px solid var(--primary);
    animation: slideInRight 0.3s ease-out;
}

.notification.success {
    border-left-color: var(--success);
}

.notification.error {
    border-left-color: var(--accent);
}

.notification i {
    font-size: 1.2rem;
}

.notification.success i {
    color: var(--success);
}

.notification.error i {
    color: var(--accent);
}

.notification span {
    flex: 1;
    font-weight: 500;
}

.notification-close {
    background: none;
    border: none;
    color: var(--text-light);
    cursor: pointer;
    padding: 5px;
    border-radius: 4px;
    transition: all 0.3s;
}

.notification-close:hover {
    background: #f8f9fa;
    color: var(--accent);
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Archive Info in Footer */
.archive-info {
    margin-top: 20px;
}

.archive-info p {
    margin-bottom: 8px;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.8);
}

/* Active state for archive link */
nav ul li a.active {
    color: var(--primary);
    font-weight: 600;
    position: relative;
}

nav ul li a.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: #0f75bc;
}

/* Archive page mobile menu fixes */
@media (max-width: 768px) {
    .archive-controls {
        top: 70px;
    }
    
    .archive-hero {
        padding-top: 120px;
    }
    
    /* Mobile navigation for archive page - ensure it doesn't show under other elements */
    nav ul {
        display: none !important;
        background: var(--footer-bg, #0f75bc) !important; /* Same as footer background */
        backdrop-filter: blur(10px);
        border: none;
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        width: 100% !important;
        height: 100vh !important;
        flex-direction: column !important;
        justify-content: center !important;
        align-items: center !important;
        z-index: 9999999 !important;
        margin: 0 !important;
        padding: 0 !important;
        box-shadow: none !important;
    }
    
    nav ul li {
        margin: 15px 0;
        text-align: center;
        width: 100%;
    }
    
    nav ul li a {
        color: white; /* White text for dark footer background */
        text-decoration: none;
        display: block;
        padding: 15px 25px;
        transition: all 0.3s ease;
        font-size: 1.3rem;
        padding: 15px 20px;
        display: block;
        border-radius: 8px;
        transition: all 0.3s ease;
        width: 80%;
        margin: 0 auto;
        text-decoration: none;
    }
    
    nav ul li a:hover {
        background: rgba(255, 255, 255, 0.15); /* Light hover background */
        transform: translateY(-2px);
        box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    }
    
    /* Force menu visibility when .show class is added */
    nav ul.show {
        display: flex !important;
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        width: 100% !important;
        height: 100vh !important;
        background: var(--footer-bg, #0f75bc) !important; /* Same as footer background */
        flex-direction: column !important;
        justify-content: center !important;
        align-items: center !important;
        z-index: 9999999 !important;
        animation: slideIn 0.3s ease-out;
    }
    
    body.menu-open {
        overflow: hidden !important;
        position: fixed !important;
        width: 100% !important;
    }
    
    /* Fix archive controls z-index to not interfere with menu */
    .archive-controls {
        position: sticky !important;
        top: 70px !important;
        z-index: 100 !important;
        background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    }
}

/* Responsive Design */
@media (min-width: 1025px) {
    /* Desktop specific layout for horizontal document display */
    .archive-grid {
        grid-template-columns: repeat(auto-fit, minmax(450px, 1fr));
        gap: 35px;
        max-width: 1400px;
        margin: 0 auto 40px;
    }
    
    .document-card {
        min-height: 280px;
    }
    
    .document-meta {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
        gap: 10px;
    }
}

@media (max-width: 1024px) {
    .archive-grid {
        grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
        gap: 30px;
    }
    
    .quick-access-grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    }
}

@media (max-width: 768px) {
    .archive-hero-content h1 {
        font-size: 2.5rem;
    }
    
    .archive-stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
    
    .archive-stat .stat-number {
        font-size: 2.5rem;
    }
    
    .controls-container {
        flex-direction: column;
        align-items: stretch;
        gap: 15px;
    }
    
    .search-box {
        max-width: none;
    }
    
    .filter-controls {
        justify-content: center;
        flex-wrap: wrap;
    }
    
    .filter-controls select {
        min-width: 120px;
        flex: 1;
    }
    
    .archive-grid {
        grid-template-columns: 1fr;
    }
    
    .document-meta {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    
    .document-actions {
        flex-direction: column;
    }
    
    .quick-access-grid {
        grid-template-columns: 1fr;
    }
    
    .modal-content {
        margin: 10px;
    }
    
    .document-preview-header {
        flex-direction: column;
        text-align: center;
        gap: 15px;
    }
    
    .preview-stats-grid {
        grid-template-columns: 1fr;
    }
    
    .pagination {
        flex-direction: column;
        gap: 15px;
    }
    
    .pagination-pages {
        order: -1;
        width: 100%;
        justify-content: center;
        margin-bottom: 10px;
    }
}

@media (max-width: 576px) {
    .archive-hero {
        padding: 120px 0 60px;
    }
    
    .archive-hero-content h1 {
        font-size: 2rem;
    }
    
    .archive-hero-content p {
        font-size: 1.1rem;
    }
    
    .archive-stats {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .filter-controls {
        flex-direction: column;
        align-items: stretch;
    }
    
    .filter-controls select {
        min-width: auto;
    }
    
    .modal-body {
        padding: 20px;
    }
    
    .modal-header {
        padding: 20px;
    }
    
    .quick-access h2 {
        font-size: 2rem;
    }
}

/* Animation for archive stats */
@keyframes countUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.archive-stat .stat-number.animated {
    animation: countUp 1s ease-out;
}

/* Print Styles */
@media print {
    .archive-controls,
    .quick-access,
    footer,
    .modal-header .close-modal,
    .document-actions {
        display: none !important;
    }
    
    .modal {
        position: static;
        background: white;
        display: block !important;
    }
    
    .modal-content {
        box-shadow: none;
        max-width: none;
        max-height: none;
    }
}
