/* news.css - ニュースページ専用スタイル（サイトレイアウト統合版） */

/* ページヘッダーの拡張 */
#news-page .page-header {
    position: relative;
    padding: 2rem 2rem 1.5rem;
}

.live-indicator {
    position: absolute;
    top: 2rem;
    right: 2rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.25rem 0.75rem;
    background: rgba(234, 67, 53, 0.1);
    border-radius: 16px;
    font-size: 0.75rem;
    font-weight: 600;
    color: #ea4335;
}

.live-dot {
    width: 6px;
    height: 6px;
    background: #ea4335;
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(234, 67, 53, 0.7); }
    70% { box-shadow: 0 0 0 6px rgba(234, 67, 53, 0); }
    100% { box-shadow: 0 0 0 0 rgba(234, 67, 53, 0); }
}

/* マーケットティッカーヘッダー */
.market-ticker-header {
    display: flex;
    justify-content: center;
    gap: 2rem;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 8px;
    margin-bottom: 2rem;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.ticker-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    white-space: nowrap;
}

.ticker-label {
    font-size: 0.875rem;
    color: #5f6368;
}

.ticker-value {
    font-weight: 600;
    color: #202124;
}

.ticker-change {
    font-size: 0.875rem;
    font-weight: 500;
}

.ticker-change.positive {
    color: #34a853;
}

.ticker-change.negative {
    color: #ea4335;
}

/* ブレーキングニュース */
.breaking-news-section {
    display: flex;
    align-items: center;
    background: #1a1a1a;
    color: white;
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 1.5rem;
    height: 40px;
}

.breaking-label {
    background: #ea4335;
    padding: 0 1.25rem;
    height: 100%;
    display: flex;
    align-items: center;
    font-weight: bold;
    font-size: 0.875rem;
    flex-shrink: 0;
}

.breaking-scroll {
    flex: 1;
    overflow: hidden;
    position: relative;
}

.breaking-text {
    display: inline-block;
    white-space: nowrap;
    padding-left: 100%;
    animation: scroll-text 40s linear infinite;
    font-size: 0.875rem;
}

@keyframes scroll-text {
    0% { transform: translateX(0); }
    100% { transform: translateX(-100%); }
}

/* フィルタータブ */
.filter-tabs-wrapper {
    margin-bottom: 2rem;
    border-bottom: 1px solid #e0e0e0;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.filter-tabs {
    display: flex;
    gap: 0;
    min-width: fit-content;
}

.filter-btn {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.75rem 1.5rem;
    background: none;
    border: none;
    border-bottom: 3px solid transparent;
    cursor: pointer;
    font-size: 0.875rem;
    font-weight: 500;
    color: #5f6368;
    transition: all 0.2s;
    white-space: nowrap;
}

.filter-btn:hover {
    color: #202124;
    background: rgba(26, 115, 232, 0.05);
}

.filter-btn.active {
    color: #1a73e8;
    border-bottom-color: #1a73e8;
}

.importance-dot {
    width: 6px;
    height: 6px;
    background: #ea4335;
    border-radius: 50%;
}

/* メインコンテンツレイアウト */
.news-main-content {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 2rem;
    align-items: start;
}

/* ニュースタイムライン */
.news-timeline {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    overflow: hidden;
}

/* タイムラインアイテム */
.timeline-item {
    display: flex;
    border-bottom: 1px solid #e8e8e8;
    position: relative;
    transition: all 0.2s;
    padding: 1rem;
}

.timeline-item:hover {
    background: #fafafa;
}

.timeline-item.new-item {
    opacity: 0;
    transform: translateY(-20px);
    animation: slideDown 0.5s ease forwards;
}

@keyframes slideDown {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.timeline-item.vip-article {
    background: linear-gradient(to right, #fffbf0 0%, transparent 100%);
    border-left: 4px solid #ffd700;
}

.timeline-item.important {
    border-left: 4px solid #ea4335;
}

/* タイムスタンプ */
.timeline-time {
    width: 90px;
    font-size: 0.8125rem;
    color: #5f6368;
    font-family: monospace;
    flex-shrink: 0;
    padding-right: 1rem;
}

/* ニュースコンテンツ */
.timeline-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.news-text {
    font-size: 0.9375rem;
    line-height: 1.6;
    color: #202124;
}

.news-detail {
    font-size: 0.875rem;
    color: #5f6368;
    line-height: 1.5;
}

/* ニュースバッジ */
.news-badge {
    display: inline-block;
    padding: 0.125rem 0.5rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    align-self: flex-start;
}

.news-badge.vip {
    background: #ffd700;
    color: #333;
}

.news-badge.high {
    background: #ea4335;
    color: white;
}

.news-badge.medium {
    background: #fbbc04;
    color: #333;
}

.news-badge.crypto {
    background: #f7931a;
    color: white;
}

/* マーケットインパクト */
.market-impact {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.impact {
    font-size: 0.8125rem;
    font-weight: 500;
    padding: 0.25rem 0.75rem;
    border-radius: 4px;
}

.impact.positive {
    background: rgba(52, 168, 83, 0.1);
    color: #34a853;
}

.impact.negative {
    background: rgba(234, 67, 53, 0.1);
    color: #ea4335;
}

/* データ行 */
.data-row {
    display: flex;
    gap: 1.5rem;
    font-size: 0.875rem;
    color: #5f6368;
}

.data-point strong {
    color: #202124;
    font-weight: 600;
}

.data-point strong.positive {
    color: #34a853;
}

.data-point strong.negative {
    color: #ea4335;
}

/* 暗号資産データ */
.crypto-data {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.375rem 0.75rem;
    background: #f8f9fa;
    border-radius: 4px;
}

.crypto-symbol {
    font-weight: 600;
    color: #202124;
}

.crypto-price {
    font-weight: 600;
    color: #202124;
}

.crypto-change {
    font-weight: 500;
}

.crypto-change.positive {
    color: #34a853;
}

/* ニュースフッター */
.news-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.8125rem;
    margin-top: 0.5rem;
}

.news-source {
    color: #5f6368;
}

.detail-link {
    color: #1a73e8;
    text-decoration: none;
    font-weight: 500;
}

.detail-link:hover {
    text-decoration: underline;
}

/* ニュースアクション */
.news-actions {
    display: flex;
    gap: 0.5rem;
}

.action-btn {
    padding: 0.25rem 0.75rem;
    background: #f8f9fa;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.2s;
}

.action-btn:hover {
    background: #e8e8e8;
    border-color: #d0d0d0;
}

/* タグ */
.news-tags {
    display: flex;
    gap: 0.5rem;
}

.tag {
    padding: 0.125rem 0.5rem;
    background: #e8f0fe;
    color: #1a73e8;
    border-radius: 4px;
    font-size: 0.75rem;
}

/* もっと見る */
.load-more-section {
    padding: 2rem;
    text-align: center;
    background: #fafafa;
}

.load-more-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 2rem;
    background: white;
    border: 1px solid #dadce0;
    border-radius: 24px;
    cursor: pointer;
    font-size: 0.875rem;
    font-weight: 500;
    color: #202124;
    transition: all 0.2s;
}

.load-more-btn:hover {
    background: #f8f9fa;
    border-color: #1a73e8;
    color: #1a73e8;
}

.spinner {
    width: 14px;
    height: 14px;
    border: 2px solid #dadce0;
    border-top-color: #1a73e8;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    display: none;
}

.spinner.active {
    display: inline-block;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* サイドバー */
.news-sidebar {
    position: sticky;
    top: 100px;
}

.sidebar-widget {
    background: white;
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    margin-bottom: 1.5rem;
}

.sidebar-widget h3 {
    font-size: 1rem;
    margin-bottom: 1rem;
    color: #202124;
}

/* マーケットリスト */
.market-list {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.market-item {
    display: flex;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px solid #f0f0f0;
}

.market-item:last-child {
    border-bottom: none;
}

.market-name {
    flex: 1;
    font-size: 0.875rem;
    color: #5f6368;
}

.market-price {
    font-size: 0.9375rem;
    font-weight: 600;
    color: #202124;
    margin-right: 0.75rem;
}

.market-change {
    font-size: 0.8125rem;
    font-weight: 500;
    min-width: 60px;
    text-align: right;
}

.market-change.positive {
    color: #34a853;
}

.market-change.negative {
    color: #ea4335;
}

/* トピックリスト */
.topic-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.topic-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem;
    background: #f8f9fa;
    border-radius: 6px;
    text-decoration: none;
    color: #202124;
    transition: all 0.2s;
}

.topic-item:hover {
    background: rgba(26, 115, 232, 0.1);
    transform: translateX(4px);
}

.topic-rank {
    width: 24px;
    height: 24px;
    background: #1a73e8;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: bold;
}

.topic-name {
    flex: 1;
    font-size: 0.875rem;
}

/* レスポンシブデザイン */
@media (max-width: 1024px) {
    .news-main-content {
        grid-template-columns: 1fr;
    }
    
    .news-sidebar {
        display: none;
    }
}

@media (max-width: 768px) {
    .live-indicator {
        position: static;
        margin-top: 1rem;
        display: inline-flex;
    }
    
    .market-ticker-header {
        gap: 1rem;
        padding: 0.75rem;
    }
    
    .ticker-item {
        font-size: 0.75rem;
    }
    
    .filter-btn {
        padding: 0.5rem 1rem;
        font-size: 0.8125rem;
    }
    
    .timeline-item {
        padding: 0.75rem;
    }
    
    .timeline-time {
        width: 70px;
        font-size: 0.75rem;
    }
    
    .news-text {
        font-size: 0.875rem;
    }
}

/* 印刷対応 */
@media print {
    .market-ticker-header,
    .breaking-news-section,
    .filter-tabs-wrapper,
    .news-sidebar,
    .load-more-section {
        display: none;
    }
}