/* ── Pack Builder Page ── */

#blast-pack-builder {
    max-width: 960px;
    margin: 0 auto;
    padding: 2rem 1rem;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.bpb-header {
    text-align: center;
    margin-bottom: 2rem;
}

.bpb-header h2 {
    font-family: "Bangers", cursive;
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.bpb-header p {
    color: #666;
    margin-bottom: 1.5rem;
}

/* Size selector */
.bpb-size-selector {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.bpb-size-btn {
    padding: 0.6rem 1.5rem;
    border: 2px solid #d4a017;
    background: transparent;
    color: #333;
    font-family: "Bangers", cursive;
    font-size: 1.1rem;
    letter-spacing: 0.05em;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s;
}

.bpb-size-btn:hover {
    background: #f5e6b8;
}

.bpb-size-btn.active {
    background: #d4a017;
    color: #000;
}

/* Progress bar */
.bpb-progress {
    max-width: 400px;
    margin: 0 auto;
}

.bpb-progress-bar {
    height: 8px;
    background: #e0e0e0;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 0.5rem;
}

.bpb-progress-fill {
    height: 100%;
    background: #d4a017;
    width: 0%;
    transition: width 0.3s ease;
    border-radius: 4px;
}

.bpb-progress-text {
    font-size: 0.9rem;
    color: #666;
}

/* Beer grid */
.bpb-beer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1.25rem;
    margin-bottom: 2rem;
}

.bpb-beer-card {
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    padding: 1rem;
    text-align: center;
    transition: border-color 0.2s, box-shadow 0.2s;
    position: relative;
}

.bpb-beer-card.has-cans {
    border-color: #d4a017;
    box-shadow: 0 0 0 1px #d4a017;
}

.bpb-beer-card .bpb-beer-name {
    font-family: "Bangers", cursive;
    font-size: 1.1rem;
    margin-bottom: 0.25rem;
    min-height: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.bpb-beer-card .bpb-beer-price {
    color: #888;
    font-size: 0.85rem;
    margin-bottom: 0.75rem;
}

.bpb-beer-card .bpb-qty-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
}

.bpb-qty-btn {
    width: 32px;
    height: 32px;
    border: 2px solid #d4a017;
    background: transparent;
    color: #333;
    font-size: 1.2rem;
    font-weight: bold;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    line-height: 1;
}

.bpb-qty-btn:hover:not(:disabled) {
    background: #d4a017;
    color: #000;
}

.bpb-qty-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.bpb-qty-display {
    font-size: 1.2rem;
    font-weight: bold;
    min-width: 1.5rem;
    text-align: center;
}

/* Footer */
.bpb-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    background: #f9f9f9;
    border-radius: 8px;
    position: sticky;
    bottom: 1rem;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.1);
}

.bpb-total {
    font-family: "Bangers", cursive;
    font-size: 1.5rem;
}

.bpb-add-to-cart {
    padding: 0.75rem 2rem;
    background: #d4a017;
    color: #000;
    border: none;
    font-family: "Bangers", cursive;
    font-size: 1.2rem;
    letter-spacing: 0.05em;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.2s;
}

.bpb-add-to-cart:hover:not(:disabled) {
    background: #b8860b;
}

.bpb-add-to-cart:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

/* ── Floating Pack Drawer (for tap list pages) ── */

.bpb-floating-toggle {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 60px;
    height: 60px;
    background: #d4a017;
    color: #000;
    border: none;
    border-radius: 50%;
    font-size: 1.5rem;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    z-index: 9998;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s;
}

.bpb-floating-toggle:hover {
    transform: scale(1.1);
}

.bpb-floating-toggle .bpb-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    background: #c0392b;
    color: #fff;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    font-size: 0.75rem;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
}

.bpb-drawer {
    position: fixed;
    top: 0;
    right: -400px;
    width: 380px;
    max-width: 90vw;
    height: 100vh;
    background: #fff;
    box-shadow: -4px 0 20px rgba(0,0,0,0.2);
    z-index: 9999;
    transition: right 0.3s ease;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.bpb-drawer.open {
    right: 0;
}

.bpb-drawer-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.4);
    z-index: 9998;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s;
}

.bpb-drawer-overlay.open {
    opacity: 1;
    pointer-events: auto;
}

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

.bpb-drawer-header h3 {
    font-family: "Bangers", cursive;
    font-size: 1.4rem;
    margin: 0;
}

.bpb-drawer-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #666;
    padding: 0.25rem;
}

.bpb-drawer-size-selector {
    padding: 1rem 1.25rem;
    display: flex;
    gap: 0.5rem;
    border-bottom: 1px solid #eee;
}

.bpb-drawer-size-btn {
    flex: 1;
    padding: 0.4rem;
    border: 2px solid #d4a017;
    background: transparent;
    font-family: "Bangers", cursive;
    font-size: 0.95rem;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s;
}

.bpb-drawer-size-btn.active {
    background: #d4a017;
    color: #000;
}

.bpb-drawer-progress {
    padding: 0.75rem 1.25rem;
    border-bottom: 1px solid #eee;
}

.bpb-drawer-items {
    flex: 1;
    overflow-y: auto;
    padding: 0.75rem 1.25rem;
}

.bpb-drawer-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
    border-bottom: 1px solid #f0f0f0;
}

.bpb-drawer-item-name {
    font-weight: 600;
    font-size: 0.9rem;
}

.bpb-drawer-item-meta {
    color: #888;
    font-size: 0.8rem;
}

.bpb-drawer-item-qty {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.bpb-drawer-qty-btn {
    width: 26px;
    height: 26px;
    border: 1px solid #d4a017;
    background: transparent;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s;
}

.bpb-drawer-qty-btn:hover {
    background: #d4a017;
}

.bpb-drawer-footer {
    padding: 1rem 1.25rem;
    border-top: 2px solid #d4a017;
    background: #fafafa;
}

.bpb-drawer-total {
    display: flex;
    justify-content: space-between;
    font-family: "Bangers", cursive;
    font-size: 1.2rem;
    margin-bottom: 0.75rem;
}

.bpb-drawer-checkout {
    width: 100%;
    padding: 0.75rem;
    background: #d4a017;
    color: #000;
    border: none;
    font-family: "Bangers", cursive;
    font-size: 1.1rem;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.2s;
}

.bpb-drawer-checkout:hover:not(:disabled) {
    background: #b8860b;
}

.bpb-drawer-checkout:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

/* ── Responsive ── */

@media (max-width: 600px) {
    .bpb-beer-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
    }

    .bpb-footer {
        flex-direction: column;
        gap: 0.75rem;
        text-align: center;
    }

    .bpb-header h2 {
        font-size: 2rem;
    }
}
