﻿
/* ===== 容器本身 ===== */
#index_qukA.unified-box {
    width: 100%;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    padding: var(--gap);
    gap: var(--gap);
}

/* ===== 顶部导航 ===== */
#index_qukA .top-nav-container {
    display: flex;
    justify-content: space-between;
    align-items: stretch;
    flex-wrap: wrap;
    gap: var(--gap);
}

#index_qukA .nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
    transition: transform .2s, box-shadow .2s, border-color .2s;
    background: var(--bg-card, #ffffff);
    border: 1px solid var(--border-color, #e4e9f2);
    border-radius: var(--b2radius);
    padding: 14px 18px;
    flex: 1;
    min-width: 0;
}

#index_qukA .nav-item:hover {
    border-color: var(--border-color);
    box-shadow: none;
}

#index_qukA .icon-box {
    flex-shrink: 0;
    width: 52px;
    height: 52px;
    background: var(--bg-body);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-primary);
    transition: background .2s, border-color .2s;
}

#index_qukA .nav-item:hover .icon-box {
    background: #fff2ec;
    border-color: #ffd5c2;
    color: var(--text-primary);
}

#index_qukA .nav-item:hover .title-row {
    color: var(--text-primary);
}

#index_qukA .icon-box i {
    font-size: 22px;
    line-height: 1;
}

#index_qukA .icon-box img {
    width: 22px !important;
    height: 22px !important;
    object-fit: contain;
    display: block;
}

#index_qukA .text-box {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
    flex: 1;
}

#index_qukA .title-row {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: var(--fs-md);
    font-weight: 600;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

#index_qukA .badge-go {
    font-size: 9px;
    color: white;
    padding: 1px 5px;
    border-radius: 3px;
    flex-shrink: 0;
}

#index_qukA .subtitle {
    font-size: var(--fs-xs);
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ===== 标题栏 ===== */
#index_qukA .section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

#index_qukA .section-title {
    font-size: var(--fs-lg);
    color: var(--text-primary);
    position: relative;
    padding-left: 12px;
}

#index_qukA .section-title::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 18px;
    background: var(--bg-card);
    border-radius: 2px;
}

#index_qukA .section-more {
    font-size: var(--fs-sm);
    color: var(--text-muted);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 4px;
    text-decoration: none;
    transition: color .2s;
}

#index_qukA .section-more:hover {
    color: var(--text-primary);
}

/* ===== 内容行 ===== */
#index_qukA .content-row {
    display: flex;
    width: 100%;
    align-items: stretch;
    overflow: visible;
    transform: translateZ(0);
    background: var(--bg-card);
    min-height: 180px;
}

/* ===== 左侧滑动区 ===== */
#index_qukA .left-slider-section {
    flex: 1 1 0;
    min-width: 0;
    position: relative;
    display: flex;
    flex-direction: column;
    align-self: stretch;
    overflow: visible;
}

/* ===== 滑动轨道 ===== */
#index_qukA .slider-track {
    display: flex;
    overflow-x: auto;
    scroll-behavior: smooth;
    scrollbar-width: none;
    width: 100%;
    will-change: transform;
    background: var(--bg-card);
    align-items: stretch;
    height: 100%;
}

#index_qukA .slider-track::-webkit-scrollbar {
    display: none;
}

/* ===== 卡片：撑满高度 ===== */
#index_qukA .card-item {
    flex: 0 0 calc(100% / var(--per-row, 4));
    padding-right: 16px;
    display: flex;
    flex-direction: column;
    gap: 0;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
    transition: transform .3s ease;
    min-width: 0;
    backface-visibility: hidden;
    height: 100%;
}

/* ===== 缩略图：撑满剩余空间 ===== */
#index_qukA .card-img {
    width: 100%;
    flex: 1 1 auto;
    min-height: 0;
    background-color: var(--bg-body);
    border-radius: var(--b2radius) var(--b2radius) 0 0;
    background-size: cover;
    background-position: center;
    position: relative;
    overflow: hidden;
    transition: box-shadow .3s;
    background-clip: padding-box;
}

#index_qukA .card-img::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, .35) 0%, transparent 50%);
    opacity: 0;
    transition: opacity .3s;
}

#index_qukA .card-item:hover .card-img::after {
    opacity: 1;
}

#index_qukA .card-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: rgba(255, 255, 255, .92);
    backdrop-filter: blur(4px);
    color: var(--text-primary);
    font-size: var(--fs-xs);
    padding: 3px 8px;
    border-radius: var(--b2radius);
    z-index: 2;
}

#index_qukA .card-badge.hot {
    background: var(--text-primary);
    color: #fff;
}

/* ===== 信息块：带背景 + 固定高度 ===== */
#index_qukA .card-info {
    flex-shrink: 0;
    background: var(--bg-body);
    border-radius: 0 0 var(--b2radius) var(--b2radius);
    padding: 8px 10px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-height: 52px;
    justify-content: center;
}

#index_qukA .card-title {
    font-size: var(--fs-base);
    color: var(--text-primary);
    line-height: 1.35;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: color .2s;
}

#index_qukA .card-item:hover .card-title {
    color: var(--text-primary);
}

#index_qukA .card-meta {
    font-size: var(--fs-xs);
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 6px;
}

/* ===== 胶囊按钮：整行居中 ===== */
#index_qukA .slider-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    margin-top: 12px;
    flex-shrink: 0;
}

#index_qukA .slider-btn {
    width: 26px;
    height: 26px;
    background: var(--bg-body);
    border: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--text-secondary);
    transition: all .2s;
    padding: 0;
    flex-shrink: 0;
}

#index_qukA .slider-btn:hover {
    background: var(--text-primary);
    color: #fff;
    border-color: var(--text-primary);
    transform: scale(1.08);
}

#index_qukA .slider-btn:disabled {
    opacity: .35;
    cursor: not-allowed;
}

#index_qukA .slider-btn svg {
    width: 14px;
    height: 14px;
}

#index_qukA .slider-dots {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
}

#index_qukA .dot {
    width: 6px;
    height: 6px;
    border-radius: 3px;
    background: var(--bg-muted);
    transition: all .3s;
    cursor: pointer;
}

#index_qukA .dot.active {
    width: 18px;
    background: var(--text-primary);
}

/* ===== 右侧活动 / 倒计时 ===== */
#index_qukA .right-event-section {
    flex: 0 0 300px;
    display: flex;
    align-self: stretch;
    position: relative;
}

#index_qukA .event-card {
    position: absolute;
    inset: 0;
    background: var(--bg-card);
    border-radius: var(--b2radius);
    padding: 14px 16px;
    color: #fff;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden;
}

#index_qukA .event-card::before {
    content: '';
    position: absolute;
    width: 180px;
    height: 180px;
    background: rgba(255, 255, 255, .07);
    border-radius: 50%;
    top: -60px;
    right: -60px;
}

#index_qukA .event-card::after {
    content: '';
    position: absolute;
    width: 130px;
    height: 130px;
    background: rgba(255, 255, 255, .05);
    border-radius: 50%;
    bottom: -50px;
    left: -40px;
}

#index_qukA .event-tag {
    position: relative;
    z-index: 2;
    font-size: var(--fs-xs);
    background: rgba(255, 255, 255, .22);
    padding: 2px 10px;
    border-radius: 20px;
    margin-bottom: 6px;
    letter-spacing: 1px;
}

#index_qukA .event-title {
    font-size: var(--fs-md);
    margin-bottom: 3px;
    z-index: 2;
    letter-spacing: 1px;
}

#index_qukA .event-desc {
    font-size: var(--fs-xs);
    opacity: .9;
    margin-bottom: 10px;
    z-index: 2;
}

#index_qukA .countdown-timer {
    display: flex;
    gap: 5px;
    z-index: 2;
    margin-bottom: 10px;
}

#index_qukA .time-block {
    background: var(--overlay-soft);
    border-radius: var(--b2radius);
    padding: 6px 0;
    width: 42px;
    display: flex;
    flex-direction: column;
    align-items: center;
    backdrop-filter: blur(6px);
    border: 1px solid rgba(255, 255, 255, .12);
}

#index_qukA .time-num {
    font-size: var(--fs-base);
    line-height: 1;
}

#index_qukA .time-label {
    font-size: 9.5px;
    margin-top: 3px;
    opacity: .85;
}

#index_qukA .event-btn {
    z-index: 2;
    background: var(--bg-card);
    color: var(--text-primary);
    border: none;
    padding: 7px 20px;
    border-radius: var(--b2radius);
    font-size: var(--fs-sm);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 4px;
    transition: all .25s;
    box-shadow: none;
    text-decoration: none;
}

#index_qukA .event-btn:hover {
    transform: translateY(-2px);
    box-shadow: none;
}

/* ===== 右侧关闭时：左侧撑满 ===== */
#index_qukA .content-row.no-event .left-slider-section {
    flex: 1 1 100%;
    width: 100%;
    margin-right: -16px;
}

/* ===== 响应式 ===== */
@media (max-width: 1024px) {
    #index_qukA .content-row {
        flex-direction: column;
        gap: 20px;
        overflow: visible;
        min-height: auto;
    }

    #index_qukA .left-slider-section {
        flex: 1 1 auto;
        width: 100%;
    }

    #index_qukA .right-event-section {
        flex: 1 1 auto;
        width: 100%;
        min-height: 200px;
        position: relative;
    }
}

/* ============ 暗夜模式适配（quka.css） ============ */
[data-theme="dark"] #index_qukA .nav-item { background: var(--bg-card); border-color: #2d3a4d; }
[data-theme="dark"] #index_qukA .nav-item:hover { border-color: #46586f; box-shadow: none; }
[data-theme="dark"] #index_qukA .nav-item:hover .icon-box { background: #3a2b20; border-color: #5a4030; }
[data-theme="dark"] #index_qukA .dot { background: #3a3f47; }
[data-theme="dark"] #index_qukA .event-btn { background: #24262c; }