/* ================================================================
 * DS v5.1 拼团 + 秒杀 样式
 * ================================================================ */

/* ========== 拼团 ========== */
.ds-gb-detail { margin: 24px 0; }
.ds-gb-hero { display: flex; gap: 24px; padding: 24px; background: linear-gradient(135deg, #ff6a00, #FF7D00 50%, #FFB347); color: #fff; border-radius: 12px; }
.ds-gb-cover, .ds-gb-cover-empty { width: 200px; height: 200px; border-radius: 8px; background: rgba(255,255,255,.15); flex-shrink: 0; }
.ds-gb-cover-empty { display: flex; align-items: center; justify-content: center; font-size: 60px; }
.ds-gb-cover { object-fit: cover; }
.ds-gb-info { flex: 1; }
.ds-gb-title { font-size: 22px; font-weight: 800; margin: 0 0 16px; }
.ds-gb-prices { display: flex; align-items: baseline; gap: 12px; margin-bottom: 16px; flex-wrap: wrap; }
.ds-gb-group-price { font-size: 36px; font-weight: 800; }
.ds-gb-original { font-size: 18px; text-decoration: line-through; opacity: 0.7; }
.ds-gb-save { padding: 4px 10px; background: rgba(255,255,255,.25); border-radius: 4px; font-size: 14px; }
.ds-gb-stats { display: flex; gap: 16px; font-size: 13px; opacity: 0.9; }

.ds-gb-team { margin: 24px 0; padding: 20px; background: var(--ds-color-white, #fff); border: 1px solid var(--ds-color-border, #ebeef5); border-radius: 12px; }
.ds-gb-team h3 { font-size: 16px; margin: 0 0 16px; }
.ds-gb-team-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(80px, 1fr)); gap: 12px; margin-bottom: 16px; }
.ds-gb-slot { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 12px; background: var(--ds-color-bg, #fafafa); border: 1px dashed #c0c4cc; border-radius: 8px; }
.ds-gb-slot.is-filled { background: #fff7e6; border-style: solid; border-color: #FF7D00; }
.ds-gb-slot img { width: 48px; height: 48px; border-radius: 50%; }
.ds-gb-avatar-empty { width: 48px; height: 48px; border-radius: 50%; background: #e0e0e0; color: #999; display: flex; align-items: center; justify-content: center; font-size: 24px; }
.ds-gb-slot span { font-size: 12px; }
.ds-gb-slot small { font-size: 10px; color: #FF7D00; font-weight: 700; }
.ds-gb-team-status { padding: 12px; background: var(--ds-color-bg, #fafafa); border-radius: 6px; font-size: 14px; text-align: center; }
.ds-gb-share { margin-top: 16px; padding: 12px; background: linear-gradient(90deg, rgba(255,125,0,.08), transparent); border-radius: 6px; }
.ds-gb-share p { margin: 0 0 8px; font-size: 14px; color: #FF7D00; }
.ds-gb-share-link { display: flex; gap: 8px; }
.ds-gb-share-link input { flex: 1; padding: 8px 12px; border: 1px solid #FF7D00; border-radius: 4px; font-size: 13px; background: #fff; }

.ds-gb-actions { text-align: center; margin: 24px 0; }
.ds-gb-description { margin: 24px 0; padding: 20px; background: var(--ds-color-white, #fff); border: 1px solid var(--ds-color-border, #ebeef5); border-radius: 12px; }
.ds-gb-description h3 { font-size: 16px; margin: 0 0 12px; }
.ds-gb-empty { padding: 40px; text-align: center; color: #999; }

/* ========== 秒杀 ========== */
.ds-fs-detail { margin: 24px 0; }
.ds-fs-hero { display: flex; gap: 24px; padding: 24px; background: linear-gradient(135deg, #dc2626, #ef4444 50%, #fb923c); color: #fff; border-radius: 12px; position: relative; overflow: hidden; }
.ds-fs-hero.is-inactive { background: linear-gradient(135deg, #6b7280, #9ca3af); }
.ds-fs-cover, .ds-fs-cover-empty { width: 200px; height: 200px; border-radius: 8px; background: rgba(255,255,255,.15); flex-shrink: 0; }
.ds-fs-cover-empty { display: flex; align-items: center; justify-content: center; font-size: 60px; }
.ds-fs-cover { object-fit: cover; }
.ds-fs-info { flex: 1; }
.ds-fs-title { font-size: 22px; font-weight: 800; margin: 0 0 16px; }
.ds-fs-prices { display: flex; align-items: baseline; gap: 12px; margin-bottom: 16px; flex-wrap: wrap; }
.ds-fs-sale-price { font-size: 36px; font-weight: 800; }
.ds-fs-original { font-size: 18px; text-decoration: line-through; opacity: 0.7; }
.ds-fs-save { padding: 4px 10px; background: rgba(255,255,255,.25); border-radius: 4px; font-size: 14px; }
.ds-fs-countdown { background: rgba(0,0,0,.3); padding: 8px 16px; border-radius: 6px; display: inline-block; margin-bottom: 12px; }
.ds-fs-countdown-label { font-size: 13px; opacity: 0.9; margin-right: 8px; }
.ds-fs-countdown-time { font-size: 18px; font-weight: 800; font-family: 'Courier New', monospace; letter-spacing: 2px; }

.ds-fs-stock { background: rgba(0,0,0,.2); padding: 8px 12px; border-radius: 6px; }
.ds-fs-stock-bar { height: 8px; background: rgba(255,255,255,.2); border-radius: 4px; overflow: hidden; margin-bottom: 6px; }
.ds-fs-stock-fill { height: 100%; background: linear-gradient(90deg, #fbbf24, #ef4444); border-radius: 4px; transition: width 0.4s; }
.ds-fs-stock-text { font-size: 12px; opacity: 0.95; }

.ds-fs-actions { text-align: center; margin: 24px 0; }
.ds-fs-grab-btn { font-size: 18px; padding: 16px 48px; background: linear-gradient(135deg, #fbbf24, #ef4444); color: #fff; border: 0; border-radius: 8px; font-weight: 700; cursor: pointer; box-shadow: 0 4px 16px rgba(239,68,68,.4); transition: all 0.2s; animation: ds-fs-pulse 2s infinite; }
.ds-fs-grab-btn:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(239,68,68,.5); }
.ds-fs-grab-btn:disabled { animation: none; opacity: 0.6; cursor: not-allowed; }
@keyframes ds-fs-pulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.03); } }

.ds-fs-description { margin: 24px 0; padding: 20px; background: var(--ds-color-white, #fff); border: 1px solid var(--ds-color-border, #ebeef5); border-radius: 12px; }
.ds-fs-description h3 { font-size: 16px; margin: 0 0 12px; }
.ds-fs-empty { padding: 40px; text-align: center; color: #999; }

/* 通用按钮 */
.ds-btn { display: inline-block; padding: 10px 24px; background: #FF7D00; color: #fff; border: 0; border-radius: 6px; font-size: 14px; font-weight: 600; cursor: pointer; text-decoration: none; transition: all 0.2s; }
.ds-btn:hover { background: #ff6a00; transform: translateY(-1px); }
.ds-btn-primary { background: #FF7D00; }
.ds-btn-secondary { background: #6b7280; }
.ds-btn-success { background: #10b981; }
.ds-btn:disabled { background: #ccc; cursor: not-allowed; transform: none; }

/* 暗黑模式 */
[data-ds-theme="dark"] .ds-gb-team, [data-ds-theme="dark"] .ds-gb-description, [data-ds-theme="dark"] .ds-fs-description { background: #1e1e1e; border-color: #333; }
[data-ds-theme="dark"] .ds-gb-slot, [data-ds-theme="dark"] .ds-gb-team-status, [data-ds-theme="dark"] .ds-gb-share-link input { background: #2a2a2a; border-color: #444; }
[data-ds-theme="dark"] .ds-gb-slot.is-filled { background: #3a2a00; }
[data-ds-theme="dark"] .ds-gb-avatar-empty { background: #444; color: #999; }
[data-ds-theme="dark"] .ds-gb-share-link input { color: #e0e0e0; }

/* 移动端 */
@media (max-width: 768px) {
    .ds-gb-hero, .ds-fs-hero { flex-direction: column; padding: 16px; }
    .ds-gb-cover, .ds-gb-cover-empty, .ds-fs-cover, .ds-fs-cover-empty { width: 100%; height: 180px; }
    .ds-gb-title, .ds-fs-title { font-size: 18px; }
    .ds-gb-group-price, .ds-fs-sale-price { font-size: 28px; }
    .ds-fs-grab-btn { font-size: 16px; padding: 14px 32px; }
}
