/* ====================================
   ONEONELITE - 玩具新聞區塊樣式 (精簡版)
   ==================================== */

.toy-news-section {
    padding: 30px 0;
    background: #fff;
}

/* 標題區域 */
.news-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 1px solid #e8e8e8;
}

.news-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: #333;
    margin: 0;
    display: flex;
    align-items: center;
}

.news-title i {
    color: #D1080F;
    font-size: 1.25rem;
}

.news-actions {
    display: flex;
    gap: 10px;
    align-items: center;
}

.btn-refresh {
    padding: 8px 12px;
    background: white;
    border: 1px solid #ddd;
    border-radius: 500px;
    color: #666;
    font-size: 13px;
    cursor: pointer;
    display: flex;
    align-items: center;
    height: 32px;
    min-width: 80px;
    justify-content: center;
}


.btn-refresh:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.news-btn-more {
    padding: 8px 16px;
    background: #D1080F;
    color: white;
    text-decoration: none;
    border-radius: 500px;
    font-size: 13px;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    height: 32px;
    justify-content: center;
    margin: 0;
    border: none;
}


/* 新聞列表 */
.news-list {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

@media (max-width: 991px) {
    .news-list {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
}

@media (max-width: 768px) {
    .news-list {
        display: flex;
        flex-direction: column;
        gap: 15px;
    }
}

/* 新聞項目 */
.news-item {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    height: 160px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}


.news-item-link {
    text-decoration: none;
    color: inherit;
    display: block;
    height: 100%;
    position: relative;
}

.news-item-link:hover {
    text-decoration: none;
    color: inherit;
}


/* 背景圖片 */
.news-bg-image {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}


/* 內容遮罩 */
.news-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        135deg,
        rgba(0, 0, 0, 0.6) 0%,
        rgba(0, 0, 0, 0.3) 50%,
        rgba(0, 0, 0, 0.7) 100%
    );
    z-index: 1;
}

/* 新聞內容 */
.news-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 20px;
    z-index: 2;
}

.news-item-title {
    font-size: 1rem;
    font-weight: 700;
    color: white;
    margin: 0 0 8px 0;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.news-meta {
    display: flex;
    align-items: center;
    gap: 8px;
}

.news-date {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 500;
    background: rgba(255, 255, 255, 0.1);
    padding: 4px 8px;
    border-radius: 4px;
    backdrop-filter: blur(4px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}


/* 載入狀態 */
.news-loading,
.news-error,
.news-empty {
    text-align: center;
    padding: 40px 20px;
    color: #666;
}

.news-error i,
.news-empty i {
    color: #D1080F;
    margin-bottom: 15px;
}

/* 響應式設計 */
@media (max-width: 768px) {
    .toy-news-section {
        padding: 20px 0;
    }

    .news-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .news-title {
        font-size: 1.25rem;
    }

    .news-actions {
        width: 100%;
        justify-content: space-between;
    }

    .news-item {
        height: 130px;
    }

    .news-content {
        padding: 15px;
    }

    .news-item-title {
        font-size: 0.9rem;
    }

    .news-date {
        font-size: 11px;
        padding: 3px 6px;
    }
}

@media (max-width: 576px) {
    .news-list {
        gap: 12px;
    }

    .news-item {
        height: 110px;
    }

    .news-content {
        padding: 12px;
    }

    .news-item-title {
        font-size: 0.85rem;
        -webkit-line-clamp: 1;
        margin-bottom: 6px;
    }

    .news-date {
        font-size: 10px;
        padding: 2px 5px;
    }

    .btn-refresh {
        padding: 6px 8px;
        height: 28px;
        min-width: 40px;
        font-size: 12px;
    }

    .news-btn-more {
        padding: 6px 12px;
        height: 28px;
        font-size: 12px;
        margin: 0;
        border: none;
    }
}

/* 動畫效果 */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(15px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.news-item {
    animation: fadeInUp 0.4s ease-out;
}

/* 旋轉動畫 */
.fa-spin {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

