/* News Detail Page Specific Styles */

/* Breadcrumb */
.breadcrumb {
    background-color: white;
    border-bottom: 1px solid #e5e7eb;
    margin-top: 4rem;
}

.breadcrumb-list {
    display: flex;
    align-items: center;
    padding: 1rem 0;
    margin: 0;
    list-style: none;
    font-size: 0.875rem;
}

.breadcrumb-item {
    display: flex;
    align-items: center;
}

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

.breadcrumb-link:hover {
    color: #dc2626;
}

.breadcrumb-separator {
    margin: 0 0.5rem;
    color: #9ca3af;
}

.breadcrumb-current {
    color: #111827;
    font-weight: 500;
}

/* Main Content */
.article-main {
    padding: 3rem 0 5rem;
    background-color: white;
    min-height: 60vh;
}

/* Loading State */
.loading-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 5rem 2rem;
    color: #6b7280;
}

.loading-spinner {
    width: 3rem;
    height: 3rem;
    border: 3px solid #e5e7eb;
    border-top: 3px solid #dc2626;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 1.5rem;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Error State */
.error-state {
    text-align: center;
    padding: 5rem 2rem;
    color: #6b7280;
}

.error-icon {
    margin-bottom: 2rem;
    opacity: 0.5;
}

.error-state h2 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #374151;
    margin-bottom: 1rem;
}

.error-state p {
    margin-bottom: 2rem;
    max-width: 32rem;
    margin-left: auto;
    margin-right: auto;
}

/* Article Content */
.article-content {
    max-width: 48rem;
    margin: 0 auto;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.8s ease forwards;
}

@keyframes fadeInUp {
    0% {
        opacity: 0;
        transform: translateY(20px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Article Header */
.article-header {
    margin-bottom: 2rem;
}

.article-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.article-category {
    background-color: #dc2626;
    color: white;
    font-size: 0.75rem;
    font-weight: bold;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    text-transform: uppercase;
}

.article-date {
    color: #6b7280;
    font-size: 0.875rem;
}

.article-title {
    font-size: 2rem;
    font-weight: bold;
    color: #111827;
    line-height: 1.3;
    margin-bottom: 1.5rem;
}

.article-share {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 0;
    border-top: 1px solid #e5e7eb;
    border-bottom: 1px solid #e5e7eb;
}

.share-label {
    font-size: 0.875rem;
    font-weight: 500;
    color: #374151;
}

.share-buttons {
    display: flex;
    gap: 0.5rem;
}

.share-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

.share-btn.twitter {
    background-color: #1da1f2;
    color: white;
}

.share-btn.twitter:hover {
    background-color: #1a91da;
    transform: translateY(-2px);
}

.share-btn.facebook {
    background-color: #4267b2;
    color: white;
}

.share-btn.facebook:hover {
    background-color: #365899;
    transform: translateY(-2px);
}

.share-btn.linkedin {
    background-color: #0077b5;
    color: white;
}

.share-btn.linkedin:hover {
    background-color: #006396;
    transform: translateY(-2px);
}

.share-btn.copy {
    background-color: #6b7280;
    color: white;
}

.share-btn.copy:hover {
    background-color: #4b5563;
    transform: translateY(-2px);
}

.share-btn.copied {
    background-color: #10b981;
}

.share-btn.copied::after {
    content: 'コピー済み';
    position: absolute;
    top: -2.5rem;
    left: 50%;
    transform: translateX(-50%);
    background-color: #111827;
    color: white;
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
    white-space: nowrap;
    opacity: 0;
    animation: fadeInOut 2s ease;
}

@keyframes fadeInOut {
    0%, 100% { opacity: 0; }
    20%, 80% { opacity: 1; }
}

/* Article Image */
.article-image {
    margin-bottom: 2rem;
    border-radius: 0.5rem;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

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

/* Article Body */
.article-body {
    margin-bottom: 3rem;
}

.article-text {
    color: #374151;
    line-height: 1.8;
    font-size: 1rem;
}

.article-text h2 {
    font-size: 1.5rem;
    font-weight: bold;
    color: #111827;
    margin: 2rem 0 1rem;
    border-left: 4px solid #dc2626;
    padding-left: 1rem;
}

.article-text h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: #111827;
    margin: 1.5rem 0 0.75rem;
}

.article-text p {
    margin-bottom: 1.5rem;
}

.article-text ul,
.article-text ol {
    margin-bottom: 1.5rem;
    padding-left: 1.5rem;
}

.article-text li {
    margin-bottom: 0.5rem;
}

.article-text blockquote {
    border-left: 4px solid #e5e7eb;
    padding-left: 1rem;
    margin: 1.5rem 0;
    font-style: italic;
    color: #6b7280;
}

.article-text a {
    color: #dc2626;
    text-decoration: underline;
    transition: color 0.3s ease;
}

.article-text a:hover {
    color: #b91c1c;
}

.article-text img {
    max-width: 100%;
    height: auto;
    border-radius: 0.375rem;
    margin: 1.5rem 0;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Article Footer */
.article-footer {
    border-top: 1px solid #e5e7eb;
    padding-top: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.article-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tag {
    background-color: #f3f4f6;
    color: #374151;
    font-size: 0.875rem;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.tag:hover {
    background-color: #dc2626;
    color: white;
}

.article-actions {
    display: flex;
    justify-content: flex-end;
}

.action-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background-color: #f3f4f6;
    border: 1px solid #d1d5db;
    color: #374151;
    text-decoration: none;
    border-radius: 0.375rem;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.action-btn:hover {
    background-color: #e5e7eb;
}

/* Related Articles */
.related-articles {
    margin-top: 4rem;
    padding-top: 3rem;
    border-top: 2px solid #e5e7eb;
}

.related-title {
    font-size: 1.5rem;
    font-weight: bold;
    color: #111827;
    margin-bottom: 2rem;
    text-align: center;
}

.related-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

.related-card {
    background-color: #f9fafb;
    border-radius: 0.5rem;
    overflow: hidden;
    transition: all 0.3s ease;
}

.related-card:hover {
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.related-link {
    display: block;
    text-decoration: none;
    color: inherit;
}

.related-image {
    aspect-ratio: 16/9;
    overflow: hidden;
    background-color: #e5e7eb;
}

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

.related-card:hover .related-image img {
    transform: scale(1.05);
}

.related-content {
    padding: 1rem;
}

.related-meta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.related-category {
    background-color: #dc2626;
    color: white;
    font-size: 0.625rem;
    font-weight: bold;
    padding: 0.125rem 0.5rem;
    border-radius: 9999px;
}

.related-date {
    color: #6b7280;
    font-size: 0.75rem;
}

.related-title-text {
    font-size: 0.875rem;
    font-weight: 500;
    color: #111827;
    line-height: 1.4;
    transition: color 0.3s ease;
}

.related-card:hover .related-title-text {
    color: #dc2626;
}

/* Article Navigation */
.article-navigation {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid #e5e7eb;
}

.nav-prev,
.nav-next {
    display: block;
    padding: 1rem;
    background-color: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    text-decoration: none;
    color: inherit;
    transition: all 0.3s ease;
}

.nav-prev:hover,
.nav-next:hover {
    background-color: #f3f4f6;
    border-color: #dc2626;
}

.nav-direction {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: #6b7280;
    margin-bottom: 0.25rem;
}

.nav-title {
    font-weight: 500;
    color: #111827;
    line-height: 1.4;
}

/* Back to News */
.back-to-news {
    padding: 2rem 0;
    border-top: 1px solid #e5e7eb;
    background-color: #f9fafb;
}

.back-link {
    display: inline-flex;
    align-items: center;
    color: #6b7280;
    text-decoration: none;
    transition: color 0.3s ease;
}

.back-link:hover {
    color: #dc2626;
}

.back-link svg {
    margin-right: 0.5rem;
}

/* Responsive Design */
@media (min-width: 768px) {
    .article-title {
        font-size: 2.5rem;
    }
    
    .article-share {
        flex-direction: row;
        align-items: center;
    }
    
    .article-footer {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }
    
    .related-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .article-navigation {
        grid-template-columns: 1fr 1fr;
    }
    
    .nav-next {
        text-align: right;
    }
    
    .nav-next .nav-direction {
        justify-content: flex-end;
    }
}

@media (min-width: 1024px) {
    .article-title {
        font-size: 3rem;
    }
    
    .related-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Print Styles */
@media print {
    .header,
    .breadcrumb,
    .article-share,
    .article-actions,
    .related-articles,
    .article-navigation,
    .back-to-news,
    .footer {
        display: none;
    }
    
    .article-main {
        padding: 0;
    }
    
    .article-content {
        max-width: none;
    }
    
    .article-title {
        font-size: 1.5rem;
        margin-bottom: 1rem;
    }
    
    .article-text {
        font-size: 0.875rem;
        line-height: 1.6;
    }
    
    .article-image {
        margin: 1rem 0;
    }
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
    .article-content,
    .share-btn,
    .related-card,
    .nav-prev,
    .nav-next {
        animation: none;
        transition: none;
    }
}

/* Dark mode support (if needed) */
@media (prefers-color-scheme: dark) {
    .article-main {
        background-color: #111827;
        color: #f9fafb;
    }
    
    .article-title {
        color: #f9fafb;
    }
    
    .article-text {
        color: #d1d5db;
    }
    
    .article-text h2,
    .article-text h3 {
        color: #f9fafb;
    }
}