/*
Theme Name: Haat Child
Template: haat
Version: 1.0
*/

/* ============================================
   三连广告卡片
   ============================================ */

.haat-triple-banner {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 5px;
    margin-bottom: 60px;
}

/* 单张卡片 */
.haat-triple-banner__card {
    position: relative;
    display: block;
    overflow: hidden;
    aspect-ratio: 5 / 2;   /* 宽高比，参考站是 2.5:1 */
    text-decoration: none;
    color: #fff;
}

/* 背景图 */
.haat-triple-banner__bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    transition: transform 0.6s ease;
    z-index: 1;
}

/* 悬停时图片放大 */
.haat-triple-banner__card:hover .haat-triple-banner__bg {
    transform: scale(1.06);
}

/* 暗色遮罩，让文字更清晰 */
.haat-triple-banner__overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to top,
        rgba(0, 0, 0, 0.55) 0%,
        rgba(0, 0, 0, 0.15) 60%,
        rgba(0, 0, 0, 0) 100%
    );
    z-index: 2;
}

/* 文字容器 */
.haat-triple-banner__content {
    position: absolute;
    left: 24px;
    right: 24px;
    bottom: 24px;
    z-index: 3;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

/* 第一行小字 */
.haat-triple-banner__line1 {
    font-size: 14px;
    font-weight: 500;
    line-height: 1.2;
    color: #fff;
}

/* 第二行大字 */
.haat-triple-banner__line2 {
    font-size: 22px;
    font-weight: 500;
    line-height: 1.3;
    color: #fff;
    margin-bottom: 8px;
}

/* 高亮部分 */
.haat-triple-banner__line2 em {
    font-style: normal;
    color: #ffc600;   /* 换成你的品牌色 */
}

/* 第三行小字 */
.haat-triple-banner__line3 {
    font-size: 14px;
    font-weight: 500;
    line-height: 1.2;
    color: #fff;
}

/* 平板：保持 3 列但缩小字号 */
@media (max-width: 1024px) {
    .haat-triple-banner__content {
        left: 16px;
        right: 16px;
        bottom: 16px;
    }

    .haat-triple-banner__line1,
    .haat-triple-banner__line3 {
        font-size: 12px;
    }

    .haat-triple-banner__line2 {
        font-size: 16px;
        margin-bottom: 6px;
    }
}

/* 手机：改成一列 */
@media (max-width: 767px) {
    .haat-triple-banner {
        grid-template-columns: 1fr;
    }

    .haat-triple-banner__card {
        aspect-ratio: 16 / 9;
    }
}


/* 分类磁贴：桌面端每行 9 个 */
.haat-tile-grid {
    display: grid;
    grid-template-columns: repeat(9, 1fr);
    gap: 12px;
    list-style: none;
    padding: 0;
    margin: 0;
}

/* 平板：每行 5 个 */
@media (max-width: 1024px) {
    .haat-tile-grid {
        grid-template-columns: repeat(5, 1fr);
    }
}

/* 手机：每行 3 个 */
@media (max-width: 600px) {
    .haat-tile-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}