/* Home page styles for deliddedtech4 theme */

/* ===================== SEO H1 (visually hidden) ===================== */
/*.resli-home-h1 {*/
/*    !*position: absolute;*!*/
/*    width: 1px;*/
/*    !*height: 1px;*!*/
/*    !*margin: -1px;*!*/
/*    !*padding: 0;*!*/
/*    overflow: hidden;*/
/*    clip: rect(0, 0, 0, 0);*/
/*    white-space: nowrap;*/
/*    border: 0;*/
/*}*/

.resli-home-h1 {
    margin-top: 20px;
    background: #fff;
    padding: 16px 28px;
    border-radius: 8px;
    display: block;
    width: 100%;
    box-sizing: border-box;
    box-shadow: 0 11px 33px rgba(0, 0, 0, 0.12);
    /*border-left: 5px solid #f9e04b;*/
    text-align: center;
}
.resli-home-h1 h1 { margin: 0; }

/* ===================== Trending Ticker ===================== */
.resli-trending {
    background: var(--resli-amber);
    color: #1a1a1a;
    overflow: hidden;
    display: flex;
    align-items: center;
    height: 38px;
}

.resli-trending-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 16px;
    display: flex;
    align-items: center;
    width: 100%;
    overflow: hidden;
}

.resli-trending-label {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1.5px;

    white-space: nowrap;
    padding-right: 12px;
    border-right: 2px solid rgba(0,0,0,0.2);
    margin-right: 12px;
    flex-shrink: 0;
}

.resli-trending-track {
    display: flex;
    gap: 40px;
    animation: resli-ticker 30s linear infinite;
    white-space: nowrap;
}

.resli-trending-track a {
    font-size: 13px;
    font-weight: 600;
    color: #1a1a1a;
    white-space: nowrap;
}

.resli-trending-track a:hover {
    color: #fff;
    opacity: 1;
    text-decoration: none;
}

.resli-trending:hover .resli-trending-track {
    animation-play-state: paused;
}

@keyframes resli-ticker {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* ===================== Hero Section ===================== */
/*.resli-hero {*/
/*    display: grid;*/
/*    grid-template-columns: 1.5fr 1fr;*/
/*    gap: 4px;*/
/*    margin-top: 16px;*/
/*}*/

.resli-hero-main {
    position: relative;
    overflow: hidden;
    height: 420px;
}

.resli-hero-main-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s;
}

.resli-hero-main:hover .resli-hero-main-img {
    transform: scale(1.03);
}

.resli-hero-main-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0,0,0,0.82));
    padding: 60px 20px 20px;
}

.resli-hero-main-cat {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;

    color: var(--resli-amber);
    display: inline-block;
    margin-bottom: 6px;
}

.resli-hero-main-cat:hover {
    color: #fff;
    opacity: 1;
    text-decoration: none;
}

.resli-hero-main-title {
    font-size: 22px;
    font-weight: 700;
    color: #fff;
    line-height: 1.35;
}

.resli-hero-main-title a {
    color: #fff;
}

.resli-hero-main-title a:hover {
    color: var(--resli-amber);
    opacity: 1;
    text-decoration: none;
}

.resli-hero-main-date {
    font-size: 12px;
    color: #ccc;
    margin-top: 8px;
}

.resli-hero-list {
    display: grid;
    gap: 4px;
    height: 320px;
    grid-template-columns: repeat(3, 1fr);
    margin-top: 20px;
}

.resli-hero-item {
    position: relative;
    overflow: hidden;
    flex: 1;
    min-height: 0;
}

.resli-hero-item-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s;
}

.resli-hero-item:hover .resli-hero-item-img {
    transform: scale(1.04);
}

.resli-hero-item-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0,0,0,0.75));
    padding: 24px 12px 10px;
}

.resli-hero-item-cat {
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1px;

    color: var(--resli-amber);
    display: block;
    margin-bottom: 4px;
}

.resli-hero-item-cat:hover {
    color: #fff;
    opacity: 1;
    text-decoration: none;
}

.resli-hero-item-title {
    font-size: 14px;
    font-weight: 700;
    color: #fff;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.resli-hero-item-title a {
    color: #fff;
}

.resli-hero-item-title a:hover {
    color: var(--resli-amber);
    opacity: 1;
    text-decoration: none;
}

.resli-hero-item-date {
    font-size: 12px;
    color: #ccc;
    margin-top: 4px;
}

/* ===================== Category Sections ===================== */
.resli-cat-section {
    margin: 32px 0 0;
}

.resli-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 12px;
    margin-bottom: 12px;
}

.resli-section-title {
    font-size: 16px;
    font-weight: 700;
    letter-spacing: 0.5px;

    color: #fff;
}

.resli-section-title a {
    color: #fff;
}

.resli-section-title a:hover {
    color: rgba(255,255,255,0.85);
    opacity: 1;
    text-decoration: none;
}

.resli-section-more {
    font-size: 12px;
    color: rgba(255,255,255,0.8);
    font-weight: 600;
}

.resli-section-more:hover {
    color: #fff;
    opacity: 1;
    text-decoration: none;
}

.resli-cat-section-body {
    display: grid;
    grid-template-columns: 3fr 1fr;
    gap: 16px;
    align-items: stretch;
}

/* Left: featured card + small list */
.resli-cat-main {
    display: grid;
    flex-direction: column;
    gap: 12px;
    grid-template-columns: 1fr 1fr;
}

.resli-home-featured-card {
    position: relative;
    overflow: hidden;
    height: 350px;
}

.resli-home-featured-card-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s;
}

.resli-home-featured-card:hover .resli-home-featured-card-img {
    transform: scale(1.03);
}

.resli-home-featured-card-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0,0,0,0.78));
    padding: 40px 14px 12px;
}

.resli-home-featured-card-cat {
    font-size: 10px;
    font-weight: 700;

    letter-spacing: 1px;
    color: var(--resli-amber);
    display: block;
    margin-bottom: 4px;
}

.resli-home-featured-card-cat:hover {
    color: #fff;
    opacity: 1;
    text-decoration: none;
}

.resli-home-featured-card-title {
    font-size: 15px;
    font-weight: 700;
    color: #fff;
    line-height: 1.3;
}

.resli-home-featured-card-title a {
    color: #fff;
}

.resli-home-featured-card-title a:hover {
    color: var(--resli-amber);
    opacity: 1;
    text-decoration: none;
}

.resli-cat-small-list {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.resli-cat-small-item {
    display: flex;
    gap: 10px;
    padding: 8px 0;
    border-bottom: 1px solid var(--resli-border);
    align-items: flex-start;
}

.resli-cat-small-item:last-child {
    border-bottom: none;
}

.resli-cat-small-item-img {
    width: 102px;
    height: 103px;
    flex-shrink: 0;
    overflow: hidden;
}

.resli-cat-small-item-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.resli-cat-small-item-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--resli-text-main);
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.resli-cat-small-item-title a {
    color: var(--resli-text-main);
}

.resli-cat-small-item-title a:hover {
    color: var(--resli-primary);
    opacity: 1;
    text-decoration: none;
}

.resli-cat-small-item-date {
    font-size: 12px;
    color: var(--resli-text-muted);
    margin-top: 4px;
}

/* Right: 2x2 grid */
.resli-home-cat-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    align-self: stretch;
    height: 100%;
}

.resli-home-list-card {
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.resli-home-list-card-img {
    width: 100%;
    flex: 1;
    min-height: 100px;
    height: 0;
    object-fit: cover;
    display: block;
    transition: transform 0.3s;
}

.resli-home-list-card:hover .resli-home-list-card-img {
    transform: scale(1.04);
}

.resli-home-list-card-body {
    padding: 6px 0;
}

.resli-home-list-card-cat {
    font-size: 10px;
    font-weight: 700;

    letter-spacing: 0.8px;
    color: var(--resli-primary);
    display: block;
    margin-bottom: 3px;
}

.resli-home-list-card-cat:hover {
    color: var(--resli-primary-dark);
    opacity: 1;
    text-decoration: none;
}

.resli-home-list-card-title {
    font-size: 12px;
    font-weight: 700;
    color: var(--resli-text-main);
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.resli-home-list-card-title a {
    color: var(--resli-text-main);
}

.resli-home-list-card-title a:hover {
    color: var(--resli-primary);
    opacity: 1;
    text-decoration: none;
}

.resli-home-list-card-date {
    font-size: 11px;
    color: var(--resli-text-muted);
    margin-top: 3px;
}

/* ===================== Latest + Popular Row ===================== */
.resli-latest-row {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 24px;
    margin: 32px 0 0;
    /*padding-bottom: 32px;*/
}

.resli-latest-section-label {
    font-size: 16px;
    font-weight: 700;
    letter-spacing: 1px;

    background: var(--resli-primary);
    color: #fff;
    padding: 8px 12px;
    margin-bottom: 14px;
}

.resli-popular-section-label {
    font-size: 16px;
    font-weight: 700;
    letter-spacing: 1px;

    background: var(--resli-dark-section);
    color: #fff;
    padding: 8px 12px;
    margin-bottom: 14px;
}

.resli-latest-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.resli-latest-card {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.resli-latest-card-img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    display: block;
    transition: transform 0.3s;
}

.resli-latest-card-wrap:hover .resli-latest-card-img {
    transform: scale(1.03);
}

.resli-latest-card-wrap {
    overflow: hidden;
    display: block;
}

.resli-latest-card-cat {
    font-size: 12px;
    font-weight: 700;

    letter-spacing: 0.8px;
    color: var(--resli-primary);
}

.resli-latest-card-cat:hover {
    color: var(--resli-primary-dark);
    opacity: 1;
    text-decoration: none;
}

.resli-latest-card-title {
    font-size: 14px;
    font-weight: 700;
    color: var(--resli-text-main);
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.resli-latest-card-title a {
    color: var(--resli-text-main);
}

.resli-latest-card-title a:hover {
    color: var(--resli-primary);
    opacity: 1;
    text-decoration: none;
}

.resli-latest-card-date {
    font-size: 12px;
    color: var(--resli-text-muted);
}

/* Popular list */
.resli-popular-list {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.resli-popular-item {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    padding: 10px 0;
    border-bottom: 1px solid var(--resli-border);
}

.resli-popular-item:last-child {
    border-bottom: none;
}

.resli-popular-num {
    font-size: 20px;
    font-weight: 700;
    color: var(--resli-border);
    flex-shrink: 0;
    width: 28px;
    line-height: 1;
}

.resli-popular-item-img {
    width: 65px;
    height: 52px;
    flex-shrink: 0;
    overflow: hidden;
}

.resli-popular-item-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.resli-popular-item-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--resli-text-main);
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.resli-popular-item-title a {
    color: var(--resli-text-main);
}

.resli-popular-item-title a:hover {
    color: var(--resli-primary);
    opacity: 1;
    text-decoration: none;
}

/* ===================== Responsive ===================== */
@media (max-width: 1024px) {
    .resli-hero {
        margin-top: 12px;
    }

    .resli-hero-main {
        height: 360px;
    }

    .resli-hero-list {
        height: 360px;
    }

    /*.resli-cat-section-body {*/
    /*    grid-template-columns: 1fr 1fr;*/
    /*}*/

    .resli-latest-row {
        margin-left: 0;
        margin-right: 0;
    }
}

@media (max-width: 768px) {
    .resli-hero {
        grid-template-columns: 1fr;
        margin: 0;
    }

    .resli-hero-main {
        height: 260px;
    }

    .resli-hero-list {
        flex-direction: row;
        height: 180px;
    }

    .resli-hero-item {
        min-width: 0;
        min-height: 0;
    }

    .resli-cat-section {
        margin: 20px 0 0;
    }

    .resli-cat-section-body {
        grid-template-columns: 1fr;
    }

    .resli-home-cat-grid {
        grid-template-columns: 1fr 1fr;
        height: auto;
    }

    .resli-home-list-card-img {
        height: 300px;
        flex: none;
    }

    .resli-latest-row {
        grid-template-columns: 1fr;
        margin: 20px 0 0;
    }

    .resli-latest-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 480px) {
    .resli-hero-list {
        flex-direction: column;
        height: auto;
        display: flex;
    }

    .resli-hero-item {
        height: 140px;
    }

    .resli-latest-grid {
        grid-template-columns: 1fr;
    }
    .resli-cat-main {
        grid-template-columns: 1fr;
    }
    .resli-home-cat-grid {
        grid-template-columns: 1fr;
    }
}
/* ================================================
   方案一：横向新闻列表式
   将以下代码粘贴到 home.blade.php @push('styles') 中
   ================================================ */

/* 容器：改为竖向列表，去掉固定高度 */
.resli-hero-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    height: auto;             /* 覆盖原版 height: 320px */
    margin-top: 20px;
    /* border: 1px solid #e5e5e5;
    border-radius: 10px; */
    overflow: hidden;
    background: #fff;
    /* box-shadow: 0 2px 12px rgba(0,0,0,0.08); */
}

/* 每条新闻：横向图左文右 */
.resli-hero-item {
    display: flex;
    flex-direction: row;      /* 覆盖原版 position:relative（无 flex） */
    align-items: stretch;
    height: 110px;
    /* border-bottom: 1px solid #f0f0f0; */
    background: #fff;
    transition: background 0.2s;
    overflow: hidden;
}
.resli-hero-item:last-child {
    border-bottom: none;
}
.resli-hero-item:hover {
    background: #fafafa;
}

/* 左侧缩略图：固定宽高，不铺满 */
.resli-hero-item-img {
    width: 160px;
    height: 100%;
    flex-shrink: 0;
    object-fit: cover;
    display: block;
    transition: transform 0.3s;
}
.resli-hero-item:hover .resli-hero-item-img {
    transform: scale(1.05);
}

/* 右侧文字区：静态布局，不再是绝对定位遮罩 */
.resli-hero-item-overlay {
    position: static;         /* 覆盖原版 position: absolute */
    background: transparent;  /* 去掉渐变遮罩 */
    padding: 14px 18px;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
}

/* 分类标签：改为带背景色的小胶囊 */
.resli-hero-item-cat {
    display: inline-block;
    width: fit-content;
    background: #1e88e5;
    color: #fff !important;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    padding: 2px 8px;
    border-radius: 20px;
    margin-bottom: 0;
}
.resli-hero-item-cat:hover {
    background: #1565c0;
    color: #fff !important;
    opacity: 1;
}

/* 标题：深色，换行最多2行 */
.resli-hero-item-title {
    font-size: 15px;
    font-weight: 700;
    color: #1a1a1a !important;
    line-height: 1.45;
    -webkit-line-clamp: 2;
}
.resli-hero-item-title a {
    color: #1a1a1a !important;
}
.resli-hero-item-title a:hover {
    color: #1e88e5 !important;
    opacity: 1;
}

/* 日期：灰色小字 */
.resli-hero-item-date {
    font-size: 11px;
    color: #aaa;
    margin-top: 2px;
}
@media(max-width:768px){
    .resli-hero-list{
        display:flex;
        flex-direction: column;
    }
}
/* 响应式 */
@media (max-width: 480px) {
    .resli-hero-item { height: auto; flex-direction: column; }
    .resli-hero-item-img { width: 100%; height: 160px; }
}