/* 首页特定样式 */
.articles-section {
    padding: 2rem 0;
    min-height: 70vh;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    gap: 1rem;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: #1e293b;
    margin: 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.section-actions {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.articles-filters {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 2rem;
    align-items: center;
    flex-wrap: wrap;
    background: white;
    padding: 1.5rem;
    border-radius: 16px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    border: 1px solid #f1f5f9;
}

.search-box {
    position: relative;
    flex: 1;
    min-width: 300px;
}

.search-input {
    width: 100%;
    padding: 0.875rem 1rem 0.875rem 3rem;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    background: #f8fafc;
}

.search-input:focus {
    outline: none;
    border-color: #667eea;
    background: white;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
    transform: translateY(-1px);
}

.search-icon {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: #64748b;
    font-size: 1.1rem;
}

.filter-options {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.filter-select {
    padding: 0.875rem 1rem;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    font-size: 0.95rem;
    background: #f8fafc;
    cursor: pointer;
    min-width: 140px;
    transition: all 0.3s ease;
}

.filter-select:focus {
    outline: none;
    border-color: #667eea;
    background: white;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(380px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.article-card {
    background: white;
    border: 1px solid #f1f5f9;
    border-radius: 16px;
    padding: 2rem;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.article-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.article-card:hover {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    transform: translateY(-8px);
    border-color: #e2e8f0;
}

.article-card:hover::before {
    transform: scaleX(1);
}

.article-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1.25rem;
}

.article-type {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: linear-gradient(135deg, #667eea20 0%, #764ba220 100%);
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    color: #667eea;
    border: 1px solid #667eea30;
}

.article-actions {
    display: flex;
    gap: 0.5rem;
}

.btn-icon {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    font-size: 1rem;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 8px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-icon:hover {
    background: #667eea;
    color: white;
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.article-title {
    font-size: 1.3rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 1rem;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.article-content {
    color: #64748b;
    line-height: 1.7;
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.article-tags {
    margin-bottom: 1.5rem;
    min-height: 2rem;
}

.article-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.8rem;
    color: #94a3b8;
    padding-top: 1.25rem;
    border-top: 1px solid #f1f5f9;
}

.tag {
    display: inline-block;
    background: linear-gradient(135deg, #eff6ff 0%, #f0f9ff 100%);
    color: #3b82f6;
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    margin-right: 0.5rem;
    margin-bottom: 0.5rem;
    border: 1px solid #dbeafe;
    transition: all 0.3s ease;
}

.tag:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.2);
}

.status-badge {
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    margin-left: 0.5rem;
}

.status-draft {
    background: #fef3c7;
    color: #d97706;
    border: 1px solid #fcd34d;
}

.status-published {
    background: #d1fae5;
    color: #065f46;
    border: 1px solid #34d399;
}

/* 文章详情模态框 */
.modal-content.large {
    max-width: 900px;
    width: 95%;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    border-radius: 20px;
    overflow: hidden;
}

.modal-header {
    padding: 2rem 2.5rem 1.5rem;
    border-bottom: 1px solid #f1f5f9;
    flex-shrink: 0;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
}

.modal-title {
    font-size: 1.8rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 1rem;
    line-height: 1.3;
}

.modal-body {
    flex: 1;
    padding: 2.5rem;
    overflow-y: auto;
    background: white;
}

.article-content {
    line-height: 1.8;
    color: #374151;
    font-size: 1.05rem;
}

.article-content h1, .article-content h2, .article-content h3 {
    color: #1e293b;
    margin: 1.5rem 0 1rem 0;
}

.article-content p {
    margin-bottom: 1.2rem;
}

.article-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.5rem 0;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.article-content table th,
.article-content table td {
    border: 1px solid #e2e8f0;
    padding: 1rem;
    text-align: left;
}

.article-content table th {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-weight: 600;
}

.article-content table tr:nth-child(even) {
    background: #f8fafc;
}

.modal-actions {
    padding: 1.5rem 2.5rem;
    border-top: 1px solid #f1f5f9;
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    flex-shrink: 0;
    background: #f8fafc;
}

/* 分页 */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1.5rem;
    margin-top: 3rem;
    padding: 2rem;
    background: white;
    border-radius: 16px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.pagination-info {
    color: #64748b;
    font-size: 0.95rem;
    font-weight: 500;
}

/* 登录模态框 */
.login-modal {
    max-width: 440px;
    border-radius: 20px;
    overflow: hidden;
}

.modal-header {
    text-align: center;
    margin-bottom: 2rem;
    padding: 2.5rem 2.5rem 1.5rem;
}

.modal-icon {
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.modal-title {
    font-size: 1.8rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 0.75rem;
}

.modal-subtitle {
    color: #64748b;
    font-size: 1.05rem;
}

.modal-form {
    margin-bottom: 2rem;
    padding: 0 2.5rem;
}

.demo-info {
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    border: 1px solid #bae6fd;
    border-radius: 16px;
    padding: 1.5rem;
    margin: 0 2.5rem 2.5rem;
}

.demo-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
    font-size: 0.95rem;
}

.demo-icon {
    font-size: 1.2rem;
}

.demo-accounts {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.demo-account {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.95rem;
}

.demo-label {
    color: #64748b;
    min-width: 70px;
    font-weight: 500;
}

.demo-value {
    background: white;
    color: #0369a1;
    padding: 0.5rem 0.75rem;
    border-radius: 8px;
    font-family: 'Monaco', 'Consolas', monospace;
    font-size: 0.9rem;
    border: 1px solid #bae6fd;
    flex: 1;
}

.loading {
    text-align: center;
    padding: 4rem 2rem;
    color: #64748b;
    grid-column: 1 / -1;
    font-size: 1.1rem;
}

.empty-state {
    text-align: center;
    padding: 4rem 2rem;
    color: #64748b;
    grid-column: 1 / -1;
    background: white;
    border-radius: 16px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.empty-state .icon {
    font-size: 4rem;
    margin-bottom: 1.5rem;
    opacity: 0.7;
}

.empty-state h3 {
    font-size: 1.5rem;
    margin-bottom: 0.75rem;
    color: #374151;
}

.empty-state p {
    font-size: 1.05rem;
    margin-bottom: 2rem;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .section-header {
        flex-direction: column;
        align-items: stretch;
        gap: 1.5rem;
        text-align: center;
    }
    
    .section-actions {
        justify-content: center;
    }
    
    .articles-filters {
        flex-direction: column;
        align-items: stretch;
        gap: 1rem;
        padding: 1.25rem;
    }
    
    .search-box {
        min-width: auto;
    }
    
    .filter-options {
        justify-content: space-between;
    }
    
    .articles-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .modal-content.large {
        width: 98%;
        margin: 2% auto;
    }
    
    .modal-header,
    .modal-body,
    .modal-actions {
        padding: 1.5rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
}

@media (max-width: 480px) {
    .pagination {
        flex-direction: column;
        gap: 1rem;
        padding: 1.5rem;
    }
    
    .filter-options {
        flex-direction: column;
        gap: 0.75rem;
    }
    
    .filter-select {
        width: 100%;
    }
    
    .article-card {
        padding: 1.5rem;
    }
    
    .modal-form {
        padding: 0 1.5rem;
    }
    
    .demo-info {
        margin: 0 1.5rem 1.5rem;
    }
}