﻿/* footer.css — _Footer.cshtml 專用樣式 */

/* === 訊息切換按鈕 === */
.news-toggle-btn {
    border: none;
    background: transparent;
    color: rgba(255, 255, 255, 0.7);
    font-size: 15px;
    font-weight: 600;
    padding: 10px 24px;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.news-toggle-btn:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
}

.news-toggle-btn.active {
    background: var(--color-primary, #2563eb);
    color: #fff;
    box-shadow: 0 4px 15px rgba(37, 99, 235, 0.4);
}

.news-toggle-btn i {
    font-size: 14px;
}

/* === 首頁訊息卡片 === */
.hp-news-card {
    display: block;
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    text-decoration: none;
    color: inherit;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    height: 100%;
}

.hp-news-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.2);
    color: inherit;
    text-decoration: none;
}

.hp-news-thumb {
    width: 100%;
    height: 120px;
    background-size: cover;
    background-position: center;
    background-color: #f0f0f0;
}

.hp-news-thumb--placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #e8f0ff 0%, #f0e8ff 100%);
    color: #a0a0c0;
    font-size: 28px;
}

.hp-news-body {
    padding: 14px;
}

.hp-news-cat {
    display: inline-block;
    font-size: 11px;
    font-weight: 600;
    padding: 2px 10px;
    border-radius: 12px;
    margin-bottom: 6px;
}

.hp-news-title {
    font-size: 14px;
    font-weight: 700;
    line-height: 1.4;
    margin: 0 0 8px 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.hp-news-meta {
    display: flex;
    gap: 10px;
    font-size: 11px;
    color: #999;
}

.hp-news-meta i {
    font-size: 11px;
    margin-right: 2px;
}

/* === 切換按鈕容器 === */
.news-toggle-tabs {
    display: inline-flex;
    gap: 8px;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(8px);
    border-radius: 30px;
    padding: 5px;
}

/* === 手機/平板：水平捲動 === */
@media (max-width: 991px) {
    .news-toggle-tabs {
        display: flex;
        justify-content: center;
        margin: 0 auto;
    }

    .news-toggle-btn {
        font-size: 13px;
        padding: 8px 16px;
    }

    .news-toggle-btn i {
        font-size: 12px;
    }

    .hp-news-scroll-row {
        flex-wrap: nowrap !important;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scroll-snap-type: x mandatory;
        gap: 16px;
        padding-bottom: 8px;
        margin: 0;
        padding-left: 0;
        padding-right: 16px;
    }

    .hp-news-scroll-row>[class*="col-"] {
        scroll-snap-align: center;
        padding: 0;
    }

    .hp-news-thumb {
        height: 180px;
    }
}

/* 平板 (768~991px) */
@media (min-width: 768px) and (max-width: 991px) {
    .hp-news-scroll-row>[class*="col-"] {
        flex: 0 0 calc(33.333% - 12px);
        max-width: calc(33.333% - 12px);
    }
}

/* 手機 (<768px) */
@media (max-width: 767px) {
    .hp-news-scroll-row>[class*="col-"] {
        flex: 0 0 calc(100% - 32px);
        max-width: calc(100% - 32px);
        margin-left: 8px;
    }
}

/* 捲軸樣式 */
@media (max-width: 991px) {
    .hp-news-scroll-row::-webkit-scrollbar {
        height: 4px;
    }

    .hp-news-scroll-row::-webkit-scrollbar-track {
        background: rgba(255, 255, 255, 0.1);
        border-radius: 2px;
    }

    .hp-news-scroll-row::-webkit-scrollbar-thumb {
        background: rgba(255, 255, 255, 0.3);
        border-radius: 2px;
    }
}

@keyframes pulse {

    0%,
    100% {
        opacity: 0.4;
    }

    50% {
        opacity: 0.8;
    }
}