/* ========================================
   Kajishin News Archive - Contact Style Design
   ======================================== */

/* News Wrapper */
.news-wrapper {
    max-width: 1000px;
    margin: 0 auto;
    padding: 48px 24px 64px;
}

@media (min-width: 768px) {
    .news-wrapper {
        padding: 64px 24px 80px;
    }
}

@media (min-width: 1280px) {
    .news-wrapper {
        max-width: 1200px;
        padding: 80px 40px 100px;
    }
}

/* Single Page Wrapper */
.news-wrapper.news-single {
    max-width: 800px;
}

@media (min-width: 1280px) {
    .news-wrapper.news-single {
        max-width: 900px;
    }
}

/* Breadcrumb */
.news-breadcrumb {
    font-size: 0.75rem;
    color: #6b7280;
    margin-bottom: 40px;
    letter-spacing: 0.05em;
    font-weight: 300;
}

.news-breadcrumb a {
    color: #6b7280;
    text-decoration: none;
    transition: color 0.3s ease;
}

.news-breadcrumb a:hover {
    color: #333;
    opacity: 1;
}

/* Header */
.news-header {
    margin-bottom: 40px;
}

.news-title {
    font-size: 1.875rem;
    font-weight: 700;
    letter-spacing: -0.025em;
    color: #1f2937;
    margin-bottom: 4px;
}

@media (min-width: 768px) {
    .news-title {
        font-size: 2.25rem;
    }
}

@media (min-width: 1280px) {
    .news-title {
        font-size: 2.5rem;
    }
}

.news-subtitle {
    font-size: 0.875rem;
    color: #6b7280;
    font-weight: 300;
    margin: 0;
}

/* Single Page Title */
.news-single .news-title {
    font-size: 1.5rem;
    line-height: 1.6;
    margin-bottom: 16px;
}

@media (min-width: 768px) {
    .news-single .news-title {
        font-size: 1.75rem;
    }
}

@media (min-width: 1280px) {
    .news-single .news-title {
        font-size: 2rem;
    }
}

/* Single Page Meta */
.news-single-meta {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 0.8125rem;
    color: #6b7280;
    font-weight: 300;
}

.news-single-meta time {
    letter-spacing: 0.05em;
}

.news-single-categories {
    display: flex;
    gap: 8px;
}

.news-single-category {
    color: #4D4947;
    padding: 2px 10px;
    background: #F7F6F5;
    font-size: 0.75rem;
}

/* Divider */
.news-divider {
    width: 100%;
    height: 1px;
    background-color: #e5e7eb;
    margin-bottom: 48px;
}

/* ========================================
   Single Article Styles
   ======================================== */

.news-article {
    margin-bottom: 60px;
}

/* Featured Image */
.news-featured-image {
    margin-bottom: 40px;
}

.news-featured-image img {
    width: 100%;
    height: auto;
    display: block;
}

/* Content */
.news-content {
    font-size: 0.9375rem;
    line-height: 2;
    color: #374151;
}

.news-content p {
    margin-bottom: 24px;
}

.news-content h2 {
    font-size: 1.375rem;
    font-weight: 600;
    margin: 48px 0 24px;
    padding-bottom: 12px;
    border-bottom: 1px solid #e5e7eb;
    color: #1f2937;
}

.news-content h3 {
    font-size: 1.125rem;
    font-weight: 600;
    margin: 40px 0 16px;
    color: #1f2937;
}

.news-content h4 {
    font-size: 1rem;
    font-weight: 600;
    margin: 32px 0 12px;
    color: #1f2937;
}

.news-content ul,
.news-content ol {
    margin: 24px 0;
    padding-left: 24px;
}

.news-content li {
    margin-bottom: 8px;
}

.news-content blockquote {
    margin: 32px 0;
    padding: 24px 32px;
    background: #F7F6F5;
    border-left: 3px solid #4D4947;
    font-style: italic;
    color: #4D4947;
}

.news-content img {
    max-width: 100%;
    height: auto;
    margin: 32px 0;
}

.news-content a {
    color: #4D4947;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.news-content a:hover {
    opacity: 0.7;
}

/* Tags */
.news-tags {
    margin-top: 48px;
    padding-top: 24px;
    border-top: 1px solid #e5e7eb;
    font-size: 0.8125rem;
    color: #6b7280;
}

.news-tags-label {
    font-weight: 500;
    color: #4D4947;
    margin-right: 8px;
}

.news-tags a {
    color: #6b7280;
    text-decoration: none;
    transition: color 0.3s ease;
}

.news-tags a:hover {
    color: #4D4947;
    opacity: 1;
}

/* Page Links */
.news-page-links {
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid #e5e7eb;
    text-align: center;
}

/* ========================================
   Post Navigation
   ======================================== */

.news-post-nav {
    display: flex;
    justify-content: space-between;
    gap: 24px;
    margin-top: 60px;
    padding-top: 40px;
    border-top: 1px solid #e5e7eb;
}

.news-nav-prev,
.news-nav-next {
    flex: 1;
    max-width: 48%;
}

.news-nav-next {
    text-align: right;
}

.news-post-nav a {
    display: block;
    padding: 20px 24px;
    background: #F7F6F5;
    text-decoration: none;
    transition: all 0.3s ease;
}

.news-post-nav a:hover {
    background: #4D4947;
    opacity: 1;
}

.news-post-nav a:hover .news-nav-label,
.news-post-nav a:hover .news-nav-title {
    color: #fff;
}

.news-nav-label {
    display: block;
    font-size: 0.75rem;
    color: #6b7280;
    letter-spacing: 0.1em;
    margin-bottom: 8px;
    transition: color 0.3s ease;
}

.news-nav-title {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: #1f2937;
    line-height: 1.6;
    transition: color 0.3s ease;
}

@media (max-width: 640px) {
    .news-post-nav {
        flex-direction: column;
    }

    .news-nav-prev,
    .news-nav-next {
        max-width: 100%;
        text-align: left;
    }
}

/* Back to List */
.news-back-link {
    margin-top: 40px;
    text-align: center;
}

.news-back-link a {
    display: inline-block;
    padding: 14px 32px;
    font-size: 0.8125rem;
    font-weight: 400;
    color: #4D4947;
    letter-spacing: 0.1em;
    text-decoration: none;
    border: 1px solid #4D4947;
    transition: all 0.3s ease;
}

.news-back-link a:hover {
    background: #4D4947;
    color: #fff;
    opacity: 1;
}

/* ========================================
   Related Posts
   ======================================== */

.news-related {
    margin-top: 80px;
    padding-top: 60px;
    border-top: 1px solid #e5e7eb;
}

.news-related-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 40px;
    letter-spacing: 0.05em;
}

.news-related .news-grid {
    margin-bottom: 0;
}

/* ========================================
   News Grid - Archive List
   ======================================== */

.news-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 40px;
    margin-bottom: 60px;
}

@media (min-width: 640px) {
    .news-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 32px;
    }
}

@media (min-width: 1024px) {
    .news-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 40px;
    }
}

@media (min-width: 1280px) {
    .news-grid {
        gap: 48px;
    }
}

/* News Item (Card) */
.news-item {
    display: block;
    text-decoration: none;
    color: inherit;
    overflow: hidden;
    transition: all 0.3s ease;
}

.news-item:hover {
    transform: translateY(-4px);
    opacity: 1;
}

/* News Meta */
.news-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.news-meta p {
    margin: 0;
}

/* News Date */
.news-date {
    font-size: 0.75rem;
    color: #6b7280;
    letter-spacing: 0.05em;
    font-weight: 300;
}

/* News Category */
.news-category {
    font-size: 0.7rem;
    color: #4D4947;
    padding: 2px 8px;
    background: #F7F6F5;
    transition: all 0.3s ease;
}

.news-item:hover .news-category {
    background: #4D4947;
    color: #fff;
}

/* News Thumbnail */
.news-thumbnail {
    overflow: hidden;
    aspect-ratio: 16 / 10;
    background: #f3f4f6;
    margin-bottom: 16px;
}

.news-thumbnail-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.news-item:hover .news-thumbnail-image {
    transform: scale(1.05);
}

/* Thumbnail Placeholder */
.news-thumbnail-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #e5e7eb 0%, #d1d5db 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

/* News Excerpt */
.news-excerpt {
    font-size: 0.875rem;
    line-height: 1.8;
    color: #4D4947;
    font-weight: 400;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin: 0;
}

/* ========================================
   Pagination
   ======================================== */

.pagination,
.nav-links {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    padding-top: 40px;
    border-top: 1px solid #e5e7eb;
}

.pagination a,
.pagination span,
.nav-links a,
.nav-links span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    height: 44px;
    padding: 0 14px;
    font-size: 0.8125rem;
    font-weight: 400;
    color: #4D4947;
    text-decoration: none;
    background: transparent;
    border: 1px solid transparent;
    transition: all 0.3s ease;
    letter-spacing: 0.02em;
}

.pagination a:hover,
.nav-links a:hover {
    border-color: #4D4947;
    opacity: 1;
}

.pagination .current,
.nav-links .current {
    background: #4D4947;
    color: #fff;
    border-color: #4D4947;
}

.pagination .prev,
.pagination .next,
.nav-links .prev,
.nav-links .next {
    font-weight: 300;
    letter-spacing: 0.05em;
}

/* No Posts */
.news-no-posts {
    grid-column: 1 / -1;
    text-align: center;
    padding: 80px 20px;
    background: #F7F6F5;
}

.news-no-posts h2 {
    font-size: 1.25rem;
    font-weight: 500;
    color: #4D4947;
    margin-bottom: 16px;
    letter-spacing: 0.05em;
}

.news-no-posts p {
    color: #6b7280;
    font-size: 0.875rem;
    font-weight: 300;
    margin: 0;
}

/* ========================================
   Hide old page-header for archive/single
   ======================================== */

.archive .page-header,
.blog .page-header,
.category .page-header,
.home .page-header,
.single .page-header {
    display: none;
}

.archive .container.section,
.blog .container.section,
.category .container.section,
.home .container.section,
.single .section {
    display: none;
}

/* Show new wrapper content */
.single .news-wrapper {
    display: block;
}
