/* 容器寬度限制 */
.container {
    max-width: 1600px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* 頁面標題區域 */
.page-header {
    background: #f8fafc;
    color: #1e293b;
    padding: 2rem 1rem;
    text-align: center;
    border-bottom: 1px solid #e2e8f0;
    position: relative;
}

.page-header-content {
    position: relative;
}

.back-link {
    position: absolute;
    left: 0;
    top: 0;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: #64748b;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s ease;
    padding: 0.5rem;
}

.back-link:hover {
    color: #2563eb;
    transform: translateX(-4px);
}

.page-header h1 {
    font-size: 2.5rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    letter-spacing: -0.02em;
    color: #1e293b;
}

.page-subtitle {
    font-size: 1.1rem;
    color: #64748b;
    max-width: 600px;
    margin: 0 auto;
    font-weight: 400;
}

/* 三欄布局 */
.research-content {
    padding: 2rem 1rem;
    background: white;
}

.research-layout {
    display: grid;
    grid-template-columns: 250px 1fr 280px;
    gap: 2rem;
    align-items: start;
}

/* 側邊欄樣式 */
.sidebar {
    position: sticky;
    top: 6rem;
}

.sidebar-section {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.sidebar-title {
    font-size: 1rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid #2563eb;
}

/* 左側邊欄 - 快速連結 */
.sidebar-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar-links li {
    margin-bottom: 0.5rem;
}

.sidebar-links a {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem;
    color: #64748b;
    text-decoration: none;
    border-radius: 6px;
    transition: all 0.2s ease;
    font-size: 0.9rem;
}

.sidebar-links a:hover {
    background: white;
    color: #2563eb;
}

.sidebar-links a i {
    width: 18px;
    text-align: center;
}

/* 分類列表 */
.sidebar-categories {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar-categories li {
    margin-bottom: 0.5rem;
}

.sidebar-categories a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem;
    color: #64748b;
    text-decoration: none;
    border-radius: 6px;
    transition: all 0.2s ease;
    font-size: 0.9rem;
}

.sidebar-categories a:hover,
.sidebar-categories a.active {
    background: white;
    color: #2563eb;
}

.sidebar-categories .count {
    background: #e2e8f0;
    color: #64748b;
    padding: 0.125rem 0.5rem;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
}

.sidebar-categories a.active .count {
    background: #2563eb;
    color: white;
}

/* 標籤 */
.sidebar-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tag {
    padding: 0.375rem 0.75rem;
    background: white;
    color: #64748b;
    text-decoration: none;
    border-radius: 6px;
    font-size: 0.8rem;
    border: 1px solid #e2e8f0;
    transition: all 0.2s ease;
}

.tag:hover {
    background: #2563eb;
    color: white;
    border-color: #2563eb;
}

/* 右側邊欄 - 最新更新 */
.update-item {
    padding-bottom: 1rem;
    margin-bottom: 1rem;
    border-bottom: 1px solid #e2e8f0;
}

.update-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.update-date {
    font-size: 0.75rem;
    color: #94a3b8;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.update-title {
    font-size: 0.9rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 0.25rem;
}

.update-desc {
    font-size: 0.8rem;
    color: #64748b;
    line-height: 1.4;
    margin: 0;
}

/* 熱門研究 */
.popular-item {
    display: flex;
    gap: 1rem;
    padding: 0.75rem;
    background: white;
    border-radius: 8px;
    margin-bottom: 0.75rem;
    border: 1px solid #e2e8f0;
}

.popular-rank {
    width: 32px;
    height: 32px;
    background: #2563eb;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.popular-info h4 {
    font-size: 0.875rem;
    font-weight: 600;
    color: #1e293b;
    margin: 0 0 0.25rem 0;
}

.popular-views {
    font-size: 0.75rem;
    color: #94a3b8;
}

.popular-views i {
    margin-right: 0.25rem;
}

/* Newsletter */
.newsletter-desc {
    font-size: 0.875rem;
    color: #64748b;
    margin-bottom: 1rem;
    line-height: 1.5;
}

.newsletter-form {
    display: flex;
    gap: 0.5rem;
}

.newsletter-form input {
    flex: 1;
    padding: 0.625rem;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    font-size: 0.875rem;
    background: white;
}

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

.newsletter-form button {
    padding: 0.625rem 1rem;
    background: #2563eb;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.newsletter-form button:hover {
    background: #1d4ed8;
}

/* 主要內容區域 */
.research-main {
    min-height: 500px;
}

/* 響應式設計 */
@media (max-width: 1400px) {
    .research-layout {
        grid-template-columns: 220px 1fr 240px;
        gap: 1.5rem;
    }
}

@media (max-width: 1200px) {
    .research-layout {
        grid-template-columns: 200px 1fr 220px;
        gap: 1.25rem;
    }
}

@media (max-width: 1024px) {
    .research-layout {
        grid-template-columns: 1fr;
    }

    .sidebar-left,
    .sidebar-right {
        display: none;
    }
}

@media (max-width: 768px) {
    .page-header h1 {
        font-size: 2rem;
    }

    .page-subtitle {
        font-size: 1rem;
    }
}