/* 推荐页面专用样式 */

/* 顶部Banner */
.hero-banner {
    position: relative;
    height: 300px;
    margin-bottom: 32px;
    border-radius: 12px;
    overflow: hidden;
    background: linear-gradient(135deg, #7FBF8B 0%, #5a9f67 100%);
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 300"><path d="M0,100 Q300,50 600,100 T1200,100 L1200,300 L0,300 Z" fill="rgba(255,255,255,0.1)"/></svg>') no-repeat bottom;
    background-size: cover;
}

.hero-content {
    position: relative;
    z-index: 1;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #fff;
    text-align: center;
}

.hero-title {
    font-size: 36px;
    font-weight: bold;
    margin-bottom: 12px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.hero-subtitle {
    font-size: 18px;
    margin-bottom: 32px;
    opacity: 0.95;
}

.hero-btn {
    background: #fff;
    color: #7FBF8B;
    border: none;
    border-radius: 24px;
    padding: 14px 48px;
    font-size: 18px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.hero-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

/* 场景推荐入口 */
.scene-section {
    margin-bottom: 40px;
}

.scene-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 16px;
}

.scene-item {
    background: #fff;
    border-radius: 12px;
    padding: 24px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.scene-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.scene-icon-wrap {
    width: 60px;
    height: 60px;
    margin: 0 auto 12px;
    border-radius: 50%;
    background: linear-gradient(135deg, #E6F4EA 0%, #d4ead9 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.scene-icon-img {
    width: 36px;
    height: 36px;
    object-fit: contain;
}

.scene-icon-text {
    font-size: 32px;
}

.scene-name {
    font-size: 16px;
    font-weight: 500;
    color: #333;
}

/* 推荐商品区域 */
.recommend-section {
    margin-bottom: 40px;
}

.product-scroll-container {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.product-scroll {
    display: flex;
    gap: 16px;
    padding-bottom: 8px;
}

.recommend-card {
    flex: 0 0 240px;
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    transition: all 0.3s;
}

.recommend-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.recommend-img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    background: #f0f0f0;
}

.recommend-info {
    padding: 12px;
}

.recommend-name {
    font-size: 14px;
    font-weight: 500;
    color: #333;
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.4;
    height: 39px;
    word-break: break-all;
}

.recommend-tags {
    display: flex;
    gap: 6px;
    margin-bottom: 8px;
    flex-wrap: wrap;
}

.tag-mini {
    display: inline-block;
    font-size: 11px;
    padding: 3px 8px;
    border-radius: 10px;
    font-weight: 500;
}

.tag-mini.taste {
    background: linear-gradient(135deg, #e8f5e9 0%, #c8e6c9 100%);
    color: #2e7d32;
}

.tag-mini.user {
    background: linear-gradient(135deg, #e3f2fd 0%, #bbdefb 100%);
    color: #1565c0;
}

.recommend-taste {
    font-size: 12px;
    color: #999;
    margin-bottom: 8px;
    display: block;
}

.recommend-price {
    font-size: 14px;
    font-weight: 600;
    color: #ff6b00;
}

.recommend-price::before {
    content: '价格：¥';
    font-size: 14px;
}

/* 茶知识区域 */
.knowledge-section {
    margin-bottom: 40px;
}

.knowledge-list {
    display: grid;
    gap: 16px;
}

.knowledge-card {
    background: #fff;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s;
    cursor: pointer;
}

.knowledge-card:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.knowledge-content {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.knowledge-title {
    font-size: 16px;
    font-weight: 500;
    color: #333;
}

.knowledge-preview {
    font-size: 14px;
    color: #666;
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* 智能选茶弹窗 */
.picker-mask {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
}

.picker-mask.show {
    display: block;
}

.picker-popup {
    position: fixed;
    bottom: -100%;
    left: 0;
    right: 0;
    background: #fff;
    border-radius: 20px 20px 0 0;
    max-height: 80vh;
    z-index: 1000;
    transition: bottom 0.3s ease;
    display: flex;
    flex-direction: column;
}

.picker-popup.show {
    bottom: 0;
}

.picker-header {
    padding: 20px;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.picker-title {
    font-size: 18px;
    font-weight: 600;
    color: #333;
}

.picker-close {
    background: none;
    border: none;
    font-size: 32px;
    color: #999;
    cursor: pointer;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    line-height: 1;
}

.picker-close:hover {
    color: #333;
}

.picker-content {
    flex: 1;
    overflow-y: auto;
    padding: 24px;
}

.picker-step {
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.step-question {
    font-size: 20px;
    font-weight: 500;
    color: #333;
    margin-bottom: 24px;
    text-align: center;
}

.option-list {
    display: grid;
    gap: 12px;
}

.option-item {
    background: #f8f8f8;
    border: 2px solid transparent;
    border-radius: 12px;
    padding: 16px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
}

.option-item:hover {
    background: #E6F4EA;
    border-color: #7FBF8B;
}

.option-item.active {
    background: #E6F4EA;
    border-color: #7FBF8B;
    color: #7FBF8B;
}

.option-text {
    font-size: 16px;
    font-weight: 500;
}

.picker-footer {
    padding: 16px 24px;
    border-top: 1px solid #eee;
    display: flex;
    gap: 12px;
}

.picker-btn-back,
.picker-btn-next {
    flex: 1;
    padding: 14px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
}

.picker-btn-back {
    background: #f8f8f8;
    color: #666;
}

.picker-btn-back:hover {
    background: #e8e8e8;
}

.picker-btn-next {
    background: #7FBF8B;
    color: #fff;
}

.picker-btn-next:hover {
    background: #6aaa76;
}

.picker-btn-next.full {
    flex: 1;
}

/* 推荐结果 */
.picker-result {
    animation: fadeIn 0.3s ease;
}

.result-title {
    font-size: 20px;
    font-weight: 600;
    color: #333;
    margin-bottom: 12px;
    text-align: center;
}

.result-reason {
    font-size: 14px;
    color: #666;
    margin-bottom: 24px;
    text-align: center;
    line-height: 1.6;
}

.result-products {
    display: grid;
    gap: 12px;
}

.result-card {
    background: #f8f8f8;
    border-radius: 12px;
    padding: 12px;
    display: flex;
    gap: 12px;
    cursor: pointer;
    transition: all 0.3s;
}

.result-card:hover {
    background: #E6F4EA;
}

.result-img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 8px;
    background: #fff;
}

.result-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.result-name {
    font-size: 16px;
    font-weight: 500;
    color: #333;
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.4;
    word-break: break-all;
}

.result-price {
    font-size: 14px;
    font-weight: 600;
    color: #ff6b00;
}

.result-price::before {
    content: '价格：¥';
    font-size: 14px;
}

body.hide-price .recommend-price,
body.hide-price .result-price {
    display: none;
}

/* 首页底部备案 */
.site-footer {
    padding: 0 16px 24px;
}

.site-footer-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 14px 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
    color: #999;
    font-size: 13px;
    line-height: 1.6;
}

.record-link {
    color: #7d7d7d;
    text-decoration: none;
    transition: color 0.2s;
}

.record-link:hover {
    color: #5a9f67;
    text-decoration: underline;
}

.record-separator {
    color: #c7c7c7;
}

.police-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.police-dot {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: linear-gradient(135deg, #2d5016 0%, #7FBF8B 100%);
    box-shadow: inset 0 0 0 1px rgba(45, 80, 22, 0.18);
}

/* 响应式设计 */
@media (max-width: 768px) {
    .hero-title {
        font-size: 28px;
    }

    .hero-subtitle {
        font-size: 16px;
    }

    .hero-btn {
        padding: 12px 36px;
        font-size: 16px;
    }

    .scene-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .recommend-card {
        flex: 0 0 190px;
    }

    .recommend-img {
        height: 160px;
    }

    .picker-popup {
        max-height: 90vh;
    }
}

@media (max-width: 480px) {
    .hero-banner {
        height: 240px;
    }

    .hero-title {
        font-size: 24px;
    }

    .hero-subtitle {
        font-size: 14px;
        margin-bottom: 24px;
    }

    .scene-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .scene-item {
        padding: 16px;
    }

    .scene-icon-wrap {
        width: 50px;
        height: 50px;
    }

    .scene-icon-text {
        font-size: 24px;
    }

    .recommend-card {
        flex: 0 0 170px;
    }

    .recommend-img {
        height: 140px;
    }

    .site-footer {
        padding: 0 12px 20px;
    }

    .site-footer-inner {
        font-size: 12px;
        padding: 12px;
        gap: 6px;
    }

    .record-separator {
        display: none;
    }
}
