/* Filter Section */

.filter-section {
    margin-bottom: 20px;
}

.filter-container {
    display: flex;
    align-items: center;
    gap: 20px;
    background: white;
    padding: 24px 32px;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.filter-label {
    font-weight: 600;
    color: #374151;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.filter-form {
    flex: 1;
    max-width: 300px;
}

.select-wrapper {
    position: relative;
}

.select-wrapper select {
    width: 100%;
    font-size: 1rem;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    background: white;
    color: #374151;
    font-weight: 500;
    appearance: none;
    cursor: pointer;
    transition: all 0.2s ease;
}

.select-wrapper select:focus {
    outline: none;
    border-color: #002145;
    box-shadow: 0 0 0 3px rgba(0, 33, 69, 0.1);
}

.select-arrow {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
    color: #6b7280;
    transition: transform 0.2s ease;
}

.select-wrapper:hover .select-arrow {
    transform: translateY(-50%) rotate(180deg);
}


/* Articles Grid */

.articles-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
    margin-bottom: 48px;
}

.article-card {
    background: white;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
}

.article-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
}

.card-header {
    padding: 24px 24px 0;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
}

.article-badge {
    /* Link resets */
    text-decoration: none;
    color: inherit;
    /* Badge styles */
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    flex-shrink: 0;
    display: inline-block;
    transition: all 0.2s ease;
    cursor: pointer;
    border: 2px solid;
    background: transparent;
}


/* Ensure link styles don't interfere on various states */

.article-badge:link,
.article-badge:visited,
.article-badge:active,
.article-badge:focus {
    text-decoration: none;
    outline: none;
}

.badge-journal:focus {
    color: #10b981;
    border-color: #10b981;
}

.badge-conference:focus {
    color: #3b82f6;
    border-color: #3b82f6;
}

.badge-library:focus {
    color: #f59e0b;
    border-color: #f59e0b;
}

.badge-default:focus {
    color: #6b7280;
    border-color: #6b7280;
}

.article-badge:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 2px;
}

.article-badge:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    text-decoration: none;
}

.badge-journal {
    border-color: #10b981;
    color: #10b981;
}

.badge-journal:hover {
    background: linear-gradient(135deg, #10b981, #059669);
    border-color: #10b981;
    color: white;
}

.badge-conference {
    border-color: #3b82f6;
    color: #3b82f6;
}

.badge-conference:hover {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    border-color: #3b82f6;
    color: white;
}

.badge-library {
    border-color: #f59e0b;
    color: #f59e0b;
}

.badge-library:hover {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    border-color: #f59e0b;
    color: white;
}

.badge-default {
    border-color: #6b7280;
    color: #6b7280;
}

.badge-default:hover {
    background: linear-gradient(135deg, #6b7280, #4b5563);
    border-color: #6b7280;
    color: white;
}

.article-date {
    font-size: 14px;
    color: #666;
    background: rgba(0, 33, 69, 0.05);
    padding: 8px 12px;
    border-radius: 6px;
    white-space: nowrap;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 6px;
}

.article-date i {
    color: #002145;
    font-size: 12px;
}

.card-content {
    padding: 16px 24px;
    flex: 1;
}

.article-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: #111827;
    margin: 0;
    line-height: 1.5;
}

.title-link {
    color: inherit;
    text-decoration: none;
    transition: color 0.2s ease;
}

.title-link:hover {
    color: #002145;
}

.card-footer {
    padding: 0 24px 24px;
    margin-top: auto;
}

.read-more-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    background: linear-gradient(135deg, #002145, #003366);
    color: white;
    text-decoration: none;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.875rem;
    transition: all 0.2s ease;
}

.read-more-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 33, 69, 0.3);
    text-decoration: none;
    color: white;
}

.read-more-btn svg {
    width: 16px;
    height: 16px;
    transition: transform 0.2s ease;
}

.read-more-btn:hover svg {
    transform: translateX(2px);
}


/* No Articles State */

.no-articles {
    text-align: center;
    padding: 80px 20px;
    background: white;
    border-radius: 20px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.no-articles-icon {
    font-size: 4rem;
    margin-bottom: 24px;
    opacity: 0.5;
}

.no-articles h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #374151;
    margin: 0 0 12px 0;
}

.no-articles p {
    font-size: 1rem;
    color: #6b7280;
    margin: 0;
}


/* Responsive Design */

@media (max-width: 768px) {
    .filter-container {
        flex-direction: column;
        align-items: stretch;
        gap: 16px;
        padding: 20px;
    }
    .filter-form {
        max-width: none;
    }
    .articles-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    .card-header {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }
    .article-badge {
        align-self: flex-start;
    }
}

@media (max-width: 480px) {
    .filter-container {
        padding: 16px;
    }
    .card-header,
    .card-content,
    .card-footer {
        padding-left: 20px;
        padding-right: 20px;
    }
}