/* ==========================================================================
   快乐农场 - 商店与商品卡片系统 (shop.css)
   ========================================================================== */

/* ==========================================================================
   1. 商店网格布局 (Shop Grids)
   ========================================================================== */

/* 商店种子与道具专属网格布局 */
#shop-seeds-container,
#shop-items-container {
    display: grid;
    grid-template-columns: repeat(4, 1fr); /* 固定4列 */
    gap: 20px;
    margin-bottom: 20px;
}

/* ==========================================================================
   2. 通用商品卡片样式 (Shop Item Cards)
   ========================================================================== */

/* 商店与背包中的通用卡片样式 */
.shop-item {
    background: #fff;
    border-radius: 20px; /* 大圆角 */
    border: 1px solid #f0f0f0;
    box-shadow: 0 8px 20px rgba(0,0,0,0.03); /* 极淡的高级投影 */
    padding: 15px;
    overflow: hidden;
    position: relative;
}

/* 悬停浮动效果 */
.shop-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.08);
}

/* 图标区域 - 增加背景圆圈 */
.shop-item > div:first-child {
    background: #f8f9fa;
    width: 70px;
    height: 70px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 10px auto !important;
    font-size: 2.5em !important; /* 图标放大 */
}

/* 卡片内部文本元素样式 */
.shop-item h4 {
    margin: 0 0 5px 0;
    font-size: 1.1em;
    text-align: center; 
    width: 100%;
}

.shop-item .desc {
    font-size: 0.8em;
    color: #666;
    margin-bottom: 5px;
    min-height: 2.2em; /* 保证文字少时不塌陷 */
    line-height: 1.2;
    display: flex;
    align-items: center;
    justify-content: center;
}

.shop-item .price {
    color: #d35400;
    font-weight: bold;
    margin: 5px 0;
    font-size: 0.95em;
    text-align: center;
}

/* ==========================================================================
   3. 卡片特化与交互 (Specialized Cards & Interactions)
   ========================================================================== */

/* 道具卡片的特殊配色 */
.shop-item.item-card {
    background: linear-gradient(180deg, #ffffff 0%, #f0f7ff 100%);
    border: 1px solid #cce5ff;
}

.shop-item.item-card:hover {
    box-shadow: 0 8px 15px rgba(0, 123, 255, 0.15);
    border-color: #007bff;
}

/* 按钮美化 */
.shop-item button {
    width: 100%;
    border-radius: 12px;
    padding: 10px 0;
    font-weight: 600;
    margin-top: auto; /* 按钮沉底 */
}

/* 种子专属色 (使用现代CSS语法，检测是否是购买按钮) */
.shop-item.seed-card {
    border-bottom: 4px solid #e9ecef;
}

/* 可拖拽的物品（种子）交互 */
.shop-item[draggable="true"] {
    cursor: grab;
    transition: transform 0.2s, box-shadow 0.2s;
}

.shop-item[draggable="true"]:active {
    cursor: grabbing;
}