/* 基础样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
body {
    background-color: #E5E5E5;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

/* 导航栏 */
.header {
    background-color: #ff5e62;
    color: white;
    text-align: center;
    padding: 15px 0;
    font-size: 18px;
    font-weight: bold;
    position: sticky;
    top: 0;
    z-index: 100;
}

/* 页面内容容器 */
.page-content {
    padding-bottom: 60px; /* 为底部导航栏留出空间 */
    min-height: calc(100vh - 115px);
}

/* 轮播图 - 已更新为首页轮播图样式 */
.home-carousel-container {
    position: relative;
    width: 100%;
    height: 200px;
    overflow: hidden;
    border-radius: 0;
    background: #ff5e62;
    /* 响应式背景覆盖 */
    box-sizing: border-box;
    padding: 0 10px; /* 内边距确保内容不贴边 */
}
.home-carousel-slider {
    position: relative;
    width: 100%;
    height: 100%;
    border-radius: 8px; /* 添加圆角效果 */
    overflow: hidden; /* 确保圆角正确显示 */
}
.home-carousel-item {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.5s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}
.home-carousel-item.carousel-active {
    opacity: 1;
}
.home-carousel-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.home-carousel-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0,0,0,0.7));
    color: white;
    padding: 10px 15px;
}
.home-carousel-caption h3 {
    margin: 0;
    font-size: 16px;
    font-weight: bold;
}
.home-carousel-caption p {
    margin: 5px 0 0 0;
    font-size: 14px;
}
.home-carousel-indicators {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 5px;
}
.home-carousel-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255,255,255,0.5);
    cursor: pointer;
    transition: background 0.3s ease;
}
.home-carousel-dot.dot-active {
    background: white;
}
.home-carousel-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: #999;
    text-align: center;
}
.home-carousel-empty p {
    margin: 0 0 5px 0;
    font-size: 16px;
}
.home-carousel-empty small {
    font-size: 12px;
}

/* 通知栏 */
.notice {
    background-color: #fff;
    margin: 5px 12px;
    padding: 10px 12px;
    border-radius: 4px;
    font-size: 16px;
    color: #d9a676;
}

/* 分区标题 */
.section-title {
    padding: 15px 10px 10px;
    font-size: 16px;
    font-weight: bold;
    display: flex;
    align-items: center;
}
.section-title::before {
    content: '';
    display: inline-block;
    width: 4px;
    height: 16px;
    background-color: #ff5e62;
    margin-right: 8px;
    border-radius: 2px;
}

/* 新品区域 */
.new-products {
    display: flex;
    overflow-x: auto;
    padding: 0 15px 15px;
    gap: 10px;
}
.new-product {
    flex: 0 0 120px;
    text-align: center;
}
.new-product img {
    width: 120px;
    height: 120px;
    border-radius: 8px;
    background-color: #eee;
    margin-bottom: 8px;
}
.new-product-name {
    font-size: 13px;
    color: #333;
}

/* 商品列表 */
.product-list {
    padding: 0 12px;
}
.product-card {
    background-color: #fff;
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
}
.product-img {
    width: 100px;
    height: 100px;
    border-radius: 6px;
    background-color: #eee;
    flex-shrink: 0;
}
.product-info {
    flex: 1;
    margin-left: 12px;
}
.product-title {
    font-size: 16px;
    font-weight: bold;
    color: #333;
}
.product-tags {
    display: flex;
    gap: 6px;
    margin: 4px 0;
}
.tag {
    font-size: 11px;
    padding: 2px 6px;
    border-radius: 2px;
    border: 1px solid #fcebeb;
    color: #ff5e62;
    background-color: #fff0f0;
}
.product-price {
    font-size: 18px;
    font-weight: bold;
    color: #e63030;
}

/* 底部导航栏 */
.tab-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 55px;
    background-color: #fff;
    border-top: 1px solid #eee;
    display: flex;
    justify-content: space-around;
    align-items: center;
    z-index: 100;
}
.tab-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    color: #999;
    font-size: 10px;
    cursor: pointer;
    transition: color 0.3s;
}
.tab-item.active {
    color: #ff5e62;
}
.tab-icon {
    width: 24px;
    height: 24px;
    margin-bottom: 4px;
}

/* 页面切换 */
.page {
    display: none;
}
.page.active {
    display: block;
}

/* 抢购页面样式 - 新设计 */
.rush-purchase-page {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background-color: #ffffff;
    color: #333;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.rush-purchase-page .main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background-color: #ffffff;
    min-height: calc(100vh - 115px);
}

.rush-purchase-page .empty-state-img {
    width: 140px;
    height: auto;
    margin-bottom: 20px;
    opacity: 0.9;
    display: block;
}

.rush-purchase-page .status-text {
    font-size: 16px;
    color: #666;
    letter-spacing: 1px;
}

/* 仓库页面样式 */
.warehouse-stats {
    background: white;
    margin: 10px;
    padding: 15px;
    border-radius: 8px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}
.stat-item {
    text-align: center;
}
.stat-number {
    font-size: 20px;
    font-weight: bold;
    color: #ff5e62;
}
.stat-label {
    font-size: 12px;
    color: #666;
}

/* 我的页面样式 */
.header-mine {
    background: #ff5e62;
    padding: 10px 20px 30px 20px;
    display: flex;
    align-items: center;
    color: #fff;
}
.avatar-box {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    overflow: hidden;
    margin-right: 15px;
    border: 2px solid rgba(255,255,255,0.5);
}
.avatar-box img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.user-info {
    flex: 1;
}
.user-name {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 4px;
    color: white;
}
.user-level {
    font-size: 12px;
    font-weight: normal;
}
.user-phone {
    font-size: 14px;
    opacity: 0.9;
}
.settings-icon {
    width: 24px;
    height: 24px;
}
.settings {
    margin-left: 10px;
}

/* 通用卡片样式 */
.card {
    background: #fff;
    margin: 12px;
    border-radius: 10px;
    padding: 10px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.02);
}

/* 订单区域样式 */

.more-link {
    font-size: 16px;
    color: #999;
    font-weight: normal;
    text-decoration: none;
}
.mine-page .order-grid {
    display: flex;
    justify-content: space-around;
    text-align: center;
    text-decoration: none;
}
.order-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    font-size: 13px;
    color: #555;
    text-decoration: none;
}
.mine-page .order-item img {
    width: 28px;
    height: 28px;
    margin-bottom: 8px;
    text-decoration: none;
}

/* 资产区域样式 */
.mine-page .asset-container {
    display: flex;
    margin: 12px;
    border-radius: 10px;
    overflow: hidden;
}
.mine-page .asset-box {
    flex: 1;
    padding: 20px 15px;
    position: relative;
    min-height: 90px;
}
.mine-page .asset-left {
    background-color: #fff8f0;
}
.mine-page .asset-right {
    background-color: #e6f0ff;
}
.mine-page .asset-num {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 5px;
    display: block;
}
.mine-page .asset-label {
    font-size: 14px;
    color: #666;
}
.mine-page .asset-left .asset-num {
    color: #ff9800;
}
.mine-page .asset-right .asset-num {
    color: #2196f3;
}
.mine-page .asset-img-decor {
    position: absolute;
    right: 10px;
    bottom: 5px;
    width: 40px;
    height: auto;
    opacity: 0.9;
}

/* 功能列表样式 */
.mine-page .menu-list-full {
    margin: 12px;
    background: #fff;
    border-radius: 10px;
}
.mine-page .menu-item {
    display: flex;
    align-items: center;
    text-decoration: none;
    justify-content: space-between;
    padding: 16px 15px;
    border-bottom: 1px solid #f5f5f5;
}
.mine-page .menu-item:last-child {
    border-bottom: none;
}
.mine-page .menu-icon {
    width: 24px;
    height: 24px;
    margin-right: 12px;
}
.menu-text {
    flex: 1;
    font-size: 16px;
    color: #333;
}    
    
/* 没有更多提示 */
.no-more-divider {
    display: flex;
    align-items: center;
    margin: 15px 0;
    padding: 0 15px;
}
.no-more-divider .line {
    flex: 1;
    height: 1px;
    background-color: #eee;
    transform: scaleY(0.5);
}
.no-more-text {
    margin: 0 15px;
    font-size: 13px;
    color: #999;
}

/* 备案号 */
.footer-record {
    width: 100%;
    text-align: center;
    font-size: 12px;
    color: #999;
    padding: 10px 0 20px; /* 底部留出空间避免与导航栏重叠 */
    background-color: #fff;
}

/* 仓库页面独立版本样式 - 使用独特类名避免冲突 */
.warehouse-standalone {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background-color: #f5f6fa;
    color: #333;
    height: 100%;
    display: flex;
    flex-direction: column;
}

/* --- Tab 选项卡 - 独立版本 --- */
.warehouse-tabs-container {
    background-color: #fff;
    display: flex;
    padding: 0 15px;
    border-bottom: 1px solid #f0f0f0;
}
.warehouse-tab-item {
    flex: 1;
    text-align: center;
    padding: 12px 8px;
    font-size: 15px;
    color: #666;
    position: relative;
    cursor: pointer;
    min-width: 60px;
}
.warehouse-tab-item.warehouse-active {
    color: #ff4d4f;
    font-weight: bold;
    background-color: #fff5f5;
}
/* 底部红色下划线 - 增强效果 */
.warehouse-tab-item.warehouse-active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 4px;
    background-color: #ff0000;
    border-radius: 2px;
}

/* --- 主内容区域 --- */
.warehouse-new-design .warehouse-main-content {
    flex: 1;
    overflow-y: auto;
    position: relative;
}

/* 隐藏/显示控制 - 独立版本 (使用!important确保不被覆盖) */
.warehouse-view-section { 
    display: none !important; 
    min-height: 100%;
    padding: 20px;
    text-align: center;
}
.warehouse-view-section.warehouse-active { 
    display: block !important; 
}

/* --- 买方视图 (空状态) - 独立版本 --- */
#warehouse-buyer-view {
    background: #ffffff;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding-top: 100px;
    height: 100%;
}

/* --- 卖方视图 (空状态) - 独立版本 --- */
#warehouse-seller-view {
    background:#ffffff;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding-top: 100px;
    height: 100%;
}

/* 空状态样式 - 独立版本 */
.warehouse-empty-placeholder {
    width: 180px;
    height: 180px;
    background: #f0f0f0;
    border-radius: 10px;
    margin: 0 auto 20px auto;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #999;
}
.warehouse-empty-text {
    color: #999;
    font-size: 15px;
}