/* Cyber-Zero Store / Liquid Glass Aesthetic */
/* 商店专用变量 - 避免覆盖全局 --glass-* 变量 */
#store-screen {
    --store-text-primary: #333;
    --store-text-secondary: #666;
    --store-accent-color: #ff7043;
}

/* Store Screen Container */
#store-screen {
    /* 核心修复：默认隐藏！JS会通过内联样式 display:flex 覆盖它 */
    display: none;
    
    /* 视觉修复：使用高模糊度的磨砂玻璃，既通透又看不清底部内容 */
    background: rgba(245, 247, 250, 0.85) !important;
    backdrop-filter: blur(40px) saturate(180%);
    -webkit-backdrop-filter: blur(40px) saturate(180%);
    
    /* 布局 */
    width: 100%;
    height: 100%;
    flex-direction: column;
    padding: 0;
    overflow: hidden;
    z-index: 200; /* 确保层级正确 */
}

/* Glass Header */
.store-glass-header {
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(0,0,0,0.05);
    padding: 15px 20px;
    padding-top: max(15px, env(safe-area-inset-top));
    display: flex;
    align-items: center;
    justify-content: space-between;
    z-index: 100;
    position: sticky;
    top: 0;
    box-shadow: 0 4px 20px rgba(0,0,0,0.03);
}

.store-title {
    font-size: 20px;
    font-weight: 700;
    /* 更加鲜艳的渐变色 */
    background: linear-gradient(135deg, #ff9966 0%, #ff5e62 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin: 0;
    letter-spacing: -0.5px;
}

.store-balance {
    font-size: 14px;
    font-weight: 600;
    color: var(--store-text-secondary);
    background: rgba(255, 255, 255, 0.6);
    padding: 6px 14px;
    border-radius: 20px;
    border: 1px solid rgba(255,255,255,0.8);
    display: flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.02);
}

/* Main Content Area */
.store-scroll-container {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    padding-bottom: 120px; /* Space for bottom nav/safe area */
}

/* Search Bar */
.store-search-bar {
    background: rgba(255, 255, 255, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.6);
    border-radius: 18px;
    padding: 14px 18px;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 4px 16px rgba(0,0,0,0.03);
    transition: all 0.3s ease;
}

.store-search-bar:focus-within {
    background: rgba(255, 255, 255, 0.8);
    box-shadow: 0 8px 24px rgba(255, 112, 67, 0.15);
    transform: translateY(-1px);
}

.store-search-input {
    border: none;
    background: transparent;
    width: 100%;
    font-size: 15px;
    color: var(--store-text-primary);
    outline: none;
    font-weight: 500;
}

/* Featured Section */
.store-featured {
    margin-bottom: 28px;
}

.featured-card {
    /* 更加高级的镭射玻璃质感 */
    background: linear-gradient(135deg, rgba(255,255,255,0.7) 0%, rgba(255,255,255,0.3) 100%);
    backdrop-filter: blur(20px);
    border-radius: 24px;
    border: 1px solid rgba(255,255,255,0.8);
    padding: 24px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 10px 40px -10px rgba(255, 94, 98, 0.3);
}

.featured-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.8) 0%, transparent 70%);
    opacity: 0.2;
    pointer-events: none;
}

.featured-label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: #ff7043;
    font-weight: 800;
    margin-bottom: 10px;
    opacity: 0.9;
}

.featured-title {
    font-size: 26px;
    font-weight: 800;
    margin-bottom: 10px;
    color: #2d3436;
    letter-spacing: -0.5px;
}

.featured-desc {
    font-size: 15px;
    color: #636e72;
    margin-bottom: 20px;
    line-height: 1.5;
}

/* Products Grid */
.store-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
}

.product-card {
    background: rgba(255, 255, 255, 0.5);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.6);
    border-radius: 22px;
    padding: 18px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    position: relative;
    box-shadow: 0 4px 15px rgba(0,0,0,0.03);
}

.product-card:hover {
    transform: translateY(-5px);
    background: rgba(255, 255, 255, 0.7);
    box-shadow: 0 15px 30px rgba(0,0,0,0.08);
}

.product-card:active {
    transform: scale(0.96);
}

.product-icon {
    font-size: 52px;
    margin-bottom: 15px;
    filter: drop-shadow(0 8px 16px rgba(0,0,0,0.1));
    transition: transform 0.4s ease;
}

.product-card:hover .product-icon {
    transform: scale(1.15) rotate(8deg);
}

.product-name {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 6px;
    color: var(--store-text-primary);
}

.product-price {
    font-size: 14px;
    color: var(--store-accent-color);
    font-weight: 800;
    margin-bottom: 16px;
    background: rgba(255, 112, 67, 0.1);
    padding: 4px 10px;
    border-radius: 12px;
}

.buy-btn {
    width: 100%;
    padding: 10px 0;
    border-radius: 14px;
    border: none;
    background: linear-gradient(135deg, #ffffff 0%, #f0f2f5 100%);
    color: var(--store-text-primary);
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid rgba(0,0,0,0.05);
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
}

.buy-btn:hover {
    background: linear-gradient(135deg, #ff9966 0%, #ff5e62 100%);
    color: white;
    border-color: transparent;
    box-shadow: 0 8px 20px rgba(255, 94, 98, 0.4);
}

/* Animations */
.store-grid > div {
    animation: fadeInUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) backwards;
}

.store-grid > div:nth-child(1) { animation-delay: 0.1s; }
.store-grid > div:nth-child(2) { animation-delay: 0.2s; }
.store-grid > div:nth-child(3) { animation-delay: 0.3s; }
.store-grid > div:nth-child(4) { animation-delay: 0.4s; }

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