/**
 * Layer by Layer - Mini Animal Pack Builder Styles
 */

.lbl-pack-builder {
    margin: 20px 0 30px 0;
    font-family: inherit;
}

/* Sticky Progress & Status Banner */
.lbl-sticky-bar {
    position: sticky;
    top: 20px;
    z-index: 100;
    background: #ffffff;
    border: 2px solid #0284c7;
    border-radius: 12px;
    padding: 14px 18px;
    box-shadow: 0 10px 25px -5px rgba(2, 132, 199, 0.15), 0 8px 10px -6px rgba(0, 0, 0, 0.05);
    margin-bottom: 20px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.lbl-sticky-bar.is-complete {
    border-color: #10b981;
    box-shadow: 0 10px 25px -5px rgba(16, 185, 129, 0.2);
}

.lbl-bar-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
}

.lbl-count-label {
    font-size: 15px;
    color: #1e293b;
}

.lbl-count-label strong {
    font-size: 18px;
    color: #0284c7;
}

.lbl-sticky-bar.is-complete .lbl-count-label strong {
    color: #10b981;
}

.lbl-status-text {
    font-size: 13px;
    font-weight: 600;
    color: #64748b;
}

.lbl-sticky-bar.is-complete .lbl-status-text {
    color: #059669;
}

.lbl-progress-track {
    width: 100%;
    height: 10px;
    background: #e2e8f0;
    border-radius: 999px;
    overflow: hidden;
}

.lbl-progress-fill {
    height: 100%;
    background: #0284c7;
    border-radius: 999px;
    transition: width 0.25s ease-out, background-color 0.25s ease-out;
}

.lbl-sticky-bar.is-complete .lbl-progress-fill {
    background: #10b981;
}

.lbl-bar-actions {
    display: flex;
    justify-content: flex-end;
}

.lbl-btn-reset {
    background: none;
    border: none;
    color: #94a3b8;
    font-size: 12px;
    text-decoration: underline;
    cursor: pointer;
    padding: 0;
}

.lbl-btn-reset:hover {
    color: #ef4444;
}

/* Search Controls */
.lbl-controls {
    margin-bottom: 16px;
}

.lbl-search-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

#lbl-mini-search {
    width: 100%;
    padding: 10px 14px;
    padding-right: 100px;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s;
    background: #f8fafc;
}

#lbl-mini-search:focus {
    border-color: #0284c7;
    background: #ffffff;
}

.lbl-search-count {
    position: absolute;
    right: 12px;
    font-size: 12px;
    color: #94a3b8;
    pointer-events: none;
}

/* Minis Grid */
.lbl-minis-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 12px;
    max-height: 520px;
    overflow-y: auto;
    padding: 4px;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    background: #f8fafc;
}

@media (min-width: 768px) {
    .lbl-minis-grid {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
        gap: 14px;
        max-height: 580px;
    }
}

/* Card */
.lbl-mini-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.lbl-mini-card.is-selected {
    border-color: #0284c7;
    box-shadow: 0 4px 12px rgba(2, 132, 199, 0.12);
}

.lbl-card-thumb {
    width: 100%;
    aspect-ratio: 1/1;
    background: #ffffff;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.lbl-card-thumb img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    padding: 6px;
    display: block;
}

.lbl-card-placeholder {
    font-size: 12px;
    color: #94a3b8;
    font-weight: 600;
}

.lbl-card-badge {
    position: absolute;
    top: 6px;
    right: 6px;
    background: #0284c7;
    color: #ffffff;
    font-size: 11px;
    font-weight: 700;
    width: 22px;
    height: 22px;
    border-radius: 999px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

.lbl-card-details {
    padding: 8px 10px 10px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    flex: 1;
    justify-content: space-between;
    background: #ffffff;
    border-top: 1px solid #f1f5f9;
}

.lbl-card-title {
    font-size: 13px;
    font-weight: 600;
    color: #1e293b;
    margin: 0;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Stepper */
.lbl-stepper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #f1f5f9;
    border-radius: 6px;
    padding: 2px;
}

.lbl-step-btn {
    width: 28px;
    height: 28px;
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 4px;
    color: #334155;
    font-size: 16px;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    transition: background 0.15s, border-color 0.15s, opacity 0.15s;
}

.lbl-step-btn:hover:not(:disabled) {
    background: #0284c7;
    border-color: #0284c7;
    color: #ffffff;
}

.lbl-step-btn:disabled {
    opacity: 0.35;
    cursor: not-allowed;
    background: #f8fafc;
    border-color: #e2e8f0;
}

.lbl-step-qty {
    font-size: 13px;
    font-weight: 700;
    color: #1e293b;
    min-width: 20px;
    text-align: center;
}

/* Add to Cart button state */
.single_add_to_cart_button.lbl-btn-locked {
    opacity: 0.55 !important;
    cursor: not-allowed !important;
    pointer-events: none !important;
    filter: grayscale(40%);
}
