/* 改善されたニュースページのスタイル */

/* ユーティリティクラス */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* メインコンテナ */
.improved-main {
    min-height: 100vh;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
}

/* ===== ヒーローセクション ===== */
.hero-section {
    position: relative;
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background:
        linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)), 
        url('../images/news.webp');
    /* 背景画像の表示方法を調整 */
    background-size: cover;
    background-position: center;
}

.hero-content {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: -1;
}

.hero-gradient {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
}

.hero-pattern {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        radial-gradient(circle at 20% 80%, rgba(255, 255, 255, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(255, 255, 255, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(255, 255, 255, 0.05) 0%, transparent 50%);
    animation: float 20s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(1deg); }
}

.hero-text-container {
    text-align: center;
    color: white;
    max-width: 800px;
    padding: 60px 20px;
}

.hero-title {
    margin: 0 0 24px 0;
    line-height: 1.2;
}

.hero-title-main {
    display: block;
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 700;
    margin-bottom: 12px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    animation: slideInUp 1s ease-out;
}

.hero-title-sub {
    display: block;
    font-size: clamp(1rem, 2vw, 1.5rem);
    font-weight: 300;
    opacity: 0.9;
    letter-spacing: 2px;
    text-transform: uppercase;
    animation: slideInUp 1s ease-out 0.2s both;
}

.hero-description {
    text-align:left;
    font-size: clamp(1rem, 2vw, 1.25rem);
    margin: 0;
    opacity: 0.9;
    line-height: 1.6;
    animation: slideInUp 1s ease-out 0.4s both;
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* フィルターセクション */
.filter-section {
    padding: 3rem 0;
    background: white;
    border-bottom: 1px solid #e2e8f0;
}

.filter-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.filter-button {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.875rem 1.5rem;
    border: 2px solid #e2e8f0;
    background: white;
    color: #64748b;
    font-size: 0.875rem;
    font-weight: 600;
    border-radius: 2rem;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.filter-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    transition: left 0.5s ease;
}

.filter-button:hover::before {
    left: 100%;
}

.filter-button:hover {
    border-color: #3b82f6;
    color: #1e40af;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.15);
}

.filter-button:focus {
    outline: 2px solid #3b82f6;
    outline-offset: 2px;
}

.filter-button.active {
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
    border-color: #1d4ed8;
    color: white;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3);
}

.filter-button.active:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.4);
}

.filter-icon {
    font-size: 1rem;
}

/* ニュースセクション */
.news-section {
    padding: 4rem 0;
    background: #f8fafc;
}

.news-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

/* ニュースアイテム */
.news-item.enhanced {
    opacity: 1;
    transform: translateY(0);
    transition: all 0.3s ease;
}

.news-item.enhanced.hidden {
    opacity: 0;
    transform: translateY(20px);
    pointer-events: none;
}

.news-link {
    display: block;
    text-decoration: none;
    color: inherit;
    height: 100%;
}

.news-card {
    background: white;
    border-radius: 1rem;
    padding: 1.5rem;
    height: 100%;
    display: flex;
    flex-direction: column;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    border: 1px solid #e2e8f0;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.news-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #3b82f6, #8b5cf6, #06b6d4);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s ease;
}

.news-link:hover .news-card {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    border-color: #3b82f6;
}

.news-link:hover .news-card::before {
    transform: scaleX(1);
}

.news-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    gap: 1rem;
}

.news-category {
    display: inline-flex;
    align-items: center;
    padding: 0.375rem 0.875rem;
    border-radius: 1rem;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.news-category.research {
    background: linear-gradient(135deg, #06b6d4, #0891b2);
    color: white;
}

.news-category.announcement {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
}

.news-category.event {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: white;
}

.news-date {
    color: #64748b;
    font-size: 0.875rem;
    font-weight: 500;
}

.news-title {
    font-size: 1.25rem;
    font-weight: 700;
    line-height: 1.4;
    margin-bottom: 0.75rem;
    color: #1e293b;
}

.news-summary {
    color: #64748b;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    flex-grow: 1;
}

.news-footer {
    display: flex;
    justify-content: flex-end;
    align-items: center;
}

.read-more {
    color: #3b82f6;
    font-size: 0.875rem;
    font-weight: 600;
    transition: all 0.2s ease;
}

.news-link:hover .read-more {
    color: #1d4ed8;
    transform: translateX(4px);
}

/* 結果なしメッセージ */
.no-results {
    grid-column: 1 / -1;
    text-align: center;
    padding: 4rem 2rem;
}

.no-results-content {
    max-width: 400px;
    margin: 0 auto;
}

.no-results-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    display: block;
    opacity: 0.6;
}

.no-results-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: #374151;
    margin-bottom: 0.5rem;
}

.no-results-text {
    color: #6b7280;
    line-height: 1.6;
}

/* レスポンシブデザイン */
@media (max-width: 768px) {
    .breadcrumb-list {
        padding: 0 1rem;
    }
    
    .hero-section {
        height: 50vh;
        min-height: 300px;
    }
    
    .hero-text-container {
        padding: 0 1rem;
    }
    
    .filter-container {
        padding: 0 1rem;
        gap: 0.75rem;
    }
    
    .filter-button {
        padding: 0.75rem 1.25rem;
        font-size: 0.8rem;
    }
    
    .news-container {
        grid-template-columns: 1fr;
        padding: 0 1rem;
        gap: 1.5rem;
    }
    
    .news-card {
        padding: 1.25rem;
    }
}

@media (max-width: 480px) {
    .breadcrumb-list {
        flex-wrap: wrap;
        gap: 0.25rem;
    }
    
    .breadcrumb-link {
        padding: 0.375rem 0.5rem;
        font-size: 0.8rem;
    }
    
    .filter-container {
        justify-content: flex-start;
        overflow-x: auto;
        padding-bottom: 0.5rem;
    }
    
    .filter-button {
        flex-shrink: 0;
        padding: 0.625rem 1rem;
    }
}

/* アニメーション */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* ハイコントラストモード対応 */
@media (prefers-contrast: high) {
    .news-card {
        border: 2px solid #000;
    }
    
    .filter-button {
        border: 2px solid #000;
    }
    
    .filter-button.active {
        background: #000;
        color: #fff;
    }
}

/* ダークモード対応 */
@media (prefers-color-scheme: dark) {
    .improved-main {
        background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    }
    
    .breadcrumb-nav {
        background: rgba(30, 41, 59, 0.9);
        border-bottom-color: rgba(71, 85, 105, 0.8);
    }
    
    .breadcrumb-link {
        color: #94a3b8;
    }
    
    .breadcrumb-link:hover {
        color: #60a5fa;
        background-color: rgba(96, 165, 250, 0.1);
    }
    
    .breadcrumb-current {
        color: #f1f5f9;
    }
    
    .filter-section {
        background: #1e293b;
        border-bottom-color: #334155;
    }
    
    .filter-button {
        background: #334155;
        border-color: #475569;
        color: #cbd5e1;
    }
    
    .filter-button:hover {
        border-color: #60a5fa;
        color: #93c5fd;
    }
    
    .news-section {
        background: #0f172a;
    }
    
    .news-card {
        background: #1e293b;
        border-color: #334155;
        color: #f1f5f9;
    }
    
    .news-title {
        color: #f1f5f9;
    }
    
    .news-summary {
        color: #94a3b8;
    }
    
    .news-date {
        color: #94a3b8;
    }
    
    .read-more {
        color: #60a5fa;
    }
    
    .news-link:hover .read-more {
        color: #93c5fd;
    }
}

