/* News grid + article page styles.
   Reuses shared color variables and typography from index.css. */

.news-tabs {
    max-width: 1280px;
    margin: 0 auto 36px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.news-tab {
    background: var(--white);
    border: 1px solid #d8dee5;
    color: var(--text-dark);
    font-size: 14px;
    font-weight: 600;
    padding: 10px 20px;
    border-radius: 999px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.news-tab:hover {
    border-color: var(--obx-mid-blue);
    color: var(--obx-mid-blue);
}

.news-tab.active {
    background: var(--obx-mid-blue);
    border-color: var(--obx-mid-blue);
    color: var(--white);
}

.news-pagination {
    max-width: 1280px;
    margin: 36px auto 0;
    display: flex;
    justify-content: center;
    gap: 8px;
}

.news-page-btn {
    width: 36px;
    height: 36px;
    border-radius: 6px;
    border: 1px solid #d8dee5;
    background: var(--white);
    color: var(--text-dark);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.news-page-btn:hover {
    border-color: var(--obx-mid-blue);
}

.news-page-btn.active {
    background: var(--obx-mid-blue);
    border-color: var(--obx-mid-blue);
    color: var(--white);
}

.news-grid-section {
    padding: 140px 60px 80px;
    background: var(--bg-light);
}

.news-grid {
    max-width: 1280px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
}

.news-card {
    background: var(--white);
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
    display: flex;
    flex-direction: column;
    text-decoration: none;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.news-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.1);
}

.news-card-image {
    width: 100%;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: var(--bg-light);
    display: flex;
    align-items: center;
    justify-content: center;
}

.news-card-image img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
}

.news-card-body {
    padding: 20px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.news-tag {
    display: inline-block;
    background: var(--obx-mid-blue);
    color: var(--white);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.3px;
    padding: 3px 10px;
    border-radius: 4px;
    text-transform: uppercase;
    align-self: flex-start;
}

.news-card-title {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-dark);
    line-height: 1.3;
    margin: 12px 0 6px;
}

.news-card-date {
    font-size: 12px;
    color: #7a8290;
    margin: 0 0 10px;
}

.news-card-excerpt {
    font-size: 13px;
    color: var(--text-medium, #4a4a4a);
    line-height: 1.55;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ===== Article page ===== */

.article-section {
    padding: 140px 60px 80px;
    background: var(--white);
}

.article-layout {
    max-width: 1280px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 50px;
    align-items: start;
}

.article-image {
    width: 100%;
    max-height: 520px;
    overflow: hidden;
    margin-bottom: 20px;
    border-radius: 4px;
    background: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
}

.article-image img {
    max-width: 100%;
    max-height: 520px;
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
}

.article-title {
    font-size: clamp(24px, 3vw, 32px);
    font-weight: 700;
    color: var(--text-dark);
    line-height: 1.25;
    margin: 12px 0 8px;
}

.article-date {
    font-size: 13px;
    color: #7a8290;
    margin: 0 0 24px;
}

.article-body p {
    font-size: 16px;
    color: var(--text-medium, #3a4252);
    line-height: 1.7;
    margin: 0 0 18px;
}

.article-list {
    margin: 0 0 18px;
    padding-left: 22px;
}

.article-list li {
    font-size: 16px;
    color: var(--text-medium, #3a4252);
    line-height: 1.7;
    margin-bottom: 8px;
}

.article-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 8px;
}

.article-tag {
    border: 1px solid #d8dee5;
    color: var(--text-medium, #3a4252);
    font-size: 12px;
    padding: 5px 14px;
    border-radius: 999px;
}

.article-sidebar-title {
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1px;
    color: var(--text-dark);
    text-transform: uppercase;
    margin: 0 0 16px;
    border-bottom: 2px solid var(--obx-red);
    padding-bottom: 10px;
}

.sidebar-post {
    display: flex;
    gap: 10px;
    margin-bottom: 16px;
    text-decoration: none;
}

.sidebar-post img {
    width: 56px;
    height: 56px;
    object-fit: cover;
    flex-shrink: 0;
    border-radius: 4px;
}

.sidebar-post-title {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-dark);
    line-height: 1.3;
    margin: 0 0 3px;
}

.sidebar-post-date {
    font-size: 11px;
    color: #7a8290;
    margin: 0;
}

@media (max-width: 900px) {
    .news-grid-section {
        padding: 100px 24px 50px;
    }
    .news-grid {
        grid-template-columns: 1fr;
    }
    .article-section {
        padding: 100px 24px 50px;
    }
    .article-layout {
        grid-template-columns: 1fr;
        gap: 32px;
    }
}

/* Article image gallery — auto-rotating crossfade between multiple photos */
.article-gallery {
    position: relative;
    width: 100%;
    max-height: 520px;
    overflow: hidden;
    margin-bottom: 20px;
    border-radius: 4px;
    background: var(--white);
}

.article-gallery-slide {
    display: none;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
}

.article-gallery-slide.active {
    display: flex;
}

.article-gallery-slide img {
    max-width: 100%;
    max-height: 520px;
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
}

.article-gallery-dots {
    position: absolute;
    bottom: 12px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 6px;
}

.article-gallery-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.6);
    border: 1px solid rgba(0, 0, 0, 0.1);
    cursor: pointer;
}

.article-gallery-dot.active {
    background: var(--obx-red);
}