.as-deck-builder-split-wrapper,
.as-deck-list-wrapper {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", sans-serif;
    color: #1e293b;
    box-sizing: border-box;
}

.as-deck-builder-split-wrapper {
    display: flex;
    gap: 20px;
    align-items: flex-start;
    margin: 20px 0;
}

@media (min-width: 1048px) {

    .col-full:has(.as-deck-builder-split-wrapper),
    .col-full:has(.as-deck-list-wrapper),
    .site-main:has(.as-deck-builder-split-wrapper),
    .site-main:has(.as-deck-list-wrapper) {
        max-width: 100% !important;
        padding-left: 20px !important;
        padding-right: 20px !important;
        box-sizing: border-box !important;
    }
}

@media(max-width: 66.4989378333em) {
    .col-full {
        margin-left: 10px !important;
        margin-right: 10px !important;

        padding: 0
    }
}

.as-db-card-detail-panel {
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
}

.as-db-left-panel {
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.as-db-right-panel {
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
}


#as-db-canvas-view,
.as-db-canvas-empty {
    flex: 1;
    min-height: 480px;
}

.as-db-tab-body {
    flex: 1;
    display: flex;
    flex-direction: column;
}


@media (min-width: 1900px) {
    .as-deck-builder-split-wrapper {
        display: grid;
        grid-template-columns: 340px 1fr 420px;
        gap: 20px;
        align-items: stretch;
        min-height: calc(100vh - 120px);
    }

    .as-db-card-detail-panel {
        width: 100%;
        display: flex !important;
        flex-direction: column;
        height: auto;
        min-height: 100%;
        position: static;
    }

    .as-db-left-panel,
    .as-db-right-panel {
        width: 100%;
        height: auto;
        min-height: 100%;
    }
}


@media (min-width: 901px) and (max-width: 1899.98px) {
    .as-deck-builder-split-wrapper {
        display: grid;
        grid-template-columns: 1fr 420px;
        gap: 20px;
        align-items: stretch;
        min-height: calc(100vh - 120px);
    }

    .as-db-card-detail-panel {
        display: none !important;
    }

    .as-db-left-panel,
    .as-db-right-panel {
        width: 100%;
        height: auto;
        min-height: 100%;
    }
}


@media (max-width: 1899.98px) {
    .as-db-card-detail-panel {
        display: none !important;
    }
}


.as-db-detail-content {
    flex: 1;
    display: flex;
    flex-direction: column;
}


.as-db-modal-advanced-content .select2-container {
    width: 100% !important;
    margin-top: 4px;
}

.as-db-modal-advanced-content .select2-container--default .select2-selection--multiple {
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    min-height: 40px;
    padding: 3px 6px;
    background: #ffffff;
    transition: border-color 0.2s;
}

.as-db-modal-advanced-content .select2-container--default.select2-container--focus .select2-selection--multiple {
    border-color: #2563eb;
    box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.15);
}

.as-db-modal-advanced-content .select2-container--default .select2-selection--multiple .select2-selection__choice {
    background-color: #eff6ff;
    border: 1px solid #bfdbfe;
    border-radius: 4px;
    color: #1e40af;
    padding: 3px 8px;
    font-size: 0.85rem;
    font-weight: 600;
}

.as-db-modal-advanced-content .select2-container--default .select2-selection--multiple .select2-selection__choice__remove {
    color: #3b82f6;
    margin-right: 5px;
    font-weight: bold;
}

.as-db-modal-advanced-content .select2-container--default .select2-selection--multiple .select2-selection__choice__remove:hover {
    color: #ef4444;
}

.select2-dropdown {
    z-index: 100005 !important;
    border: 1px solid #cbd5e1 !important;
    border-radius: 8px !important;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15) !important;
    font-family: inherit;
}


.as-db-detail-empty {
    text-align: center;
    padding: 60px 16px;
    border: 2px dashed #cbd5e1;
    border-radius: 10px;
    background: #f8fafc;
    color: #94a3b8;
}

.as-db-empty-icon {
    font-size: 2.5rem;
    width: auto;
    height: auto;
    margin-bottom: 12px;
    color: #cbd5e1;
}

.as-db-detail-empty p {
    margin: 0;
    font-size: 0.9rem;
    font-weight: 500;
}

.as-db-detail-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 12px;
}

.as-db-detail-title-box h3 {
    margin: 0 0 2px 0;
    font-size: 1.2rem;
    font-weight: 700;
    color: #0f172a;
}

.as-db-detail-sub {
    font-size: 0.8rem;
    color: #64748b;
    font-weight: 600;
}

.as-db-detail-actions {
    display: flex;
    align-items: center;
    gap: 6px;
}

.as-db-detail-qty-bar {
    margin-top: 10px;
    margin-bottom: 14px;
}

.as-db-detail-image-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 12px 0;
}

.as-db-detail-image-wrapper img {
    width: 100%;
    max-height: 360px;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.as-detail-nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid #cbd5e1;
    border-radius: 50%;
    width: 34px;
    height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 5;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
    transition: all 0.2s;
}

.as-detail-nav-btn:hover {
    background: #ffffff;
    color: #b91c1c;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.as-detail-nav-prev {
    left: -8px;
}

.as-detail-nav-next {
    right: -8px;
}

.as-db-top-toolbar {
    display: flex;
    align-items: center;
    gap: 12px;
    padding-bottom: 14px;
    border-bottom: 1px solid #e2e8f0;
    margin-bottom: 14px;
    flex-wrap: wrap;
}

.as-db-cover-box {
    width: 48px;
    height: 48px;
    border-radius: 8px;
    border: 2px dashed #cbd5e1;
    display: flex;
    align-items: center;
    justify-content: center;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    flex-shrink: 0;
}

.as-db-cover-placeholder {
    font-size: 1.4rem;
    color: #94a3b8;
}

.as-db-title-box {
    flex-grow: 1;
}

.as-db-title-input {
    font-size: 1.15rem !important;
    font-weight: 700 !important;
    color: #0f172a !important;
    border: 1px solid #cbd5e1 !important;
    background: #ffffff !important;
    padding: 5px 10px !important;
    border-radius: 6px !important;
    width: 220px !important;
    max-width: 100% !important;
    transition: all 0.2s !important;
}

.as-db-title-input:hover,
.as-db-title-input:focus {
    border-color: #2563eb;
    background: #ffffff;
    outline: none;
    box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.15);
}

.as-db-deck-meta-info {
    font-size: 0.85rem;
    color: #64748b;
    margin-top: 2px;
}

.as-db-price {
    color: #16a34a;
    font-weight: 700;
}

.as-db-toolbar-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.as-db-btn,
.as-dl-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 8px 14px;
    font-size: 0.9rem;
    font-weight: 600;
    border-radius: 6px;
    cursor: pointer;
    border: none;
    transition: all 0.2s;
    text-decoration: none;
}

.as-db-btn-save {
    background-color: #dc2626;
    color: #ffffff !important;
}

.as-db-btn-save:hover {
    background-color: #b91c1c;
}

.as-db-btn-discard {
    background-color: #f1f5f9;
    color: #475569 !important;
    font-size: 1.1rem;
    padding: 6px 10px;
}

.as-db-btn-discard:hover {
    background-color: #fee2e2;
    color: #dc2626 !important;
}

.as-db-btn-secondary {
    background-color: #f1f5f9;
    color: #334155 !important;
    border: 1px solid #cbd5e1;
}

.as-db-btn-primary {
    background-color: #2563eb;
    color: #ffffff !important;
}

.as-db-btn-cart,
.as-dl-btn-cart {
    background: linear-gradient(135deg, #16a34a, #15803d);
    color: #ffffff !important;
    box-shadow: 0 4px 10px rgba(22, 163, 74, 0.2);
}

.as-dl-btn-red {
    background-color: #b91c1c;
    color: #ffffff !important;
    width: 100%;
    margin-bottom: 6px;
    padding: 10px 14px;
}

.as-dl-btn-red:hover {
    background-color: #991b1b;
}

.as-db-icon-btn {
    background: #f1f5f9;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    padding: 6px 10px;
    font-size: 1rem;
    cursor: pointer;
}

.as-db-dropdown-wrap {
    position: relative;
    display: inline-block;
}

.as-db-dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    z-index: 99;
    min-width: 160px;
    padding: 6px 0;
    margin-top: 4px;
}

.as-db-dropdown-wrap:hover .as-db-dropdown-menu,
.as-db-dropdown-wrap.open .as-db-dropdown-menu {
    display: block;
}

.as-db-dropdown-menu button {
    display: block;
    width: 100%;
    text-align: left;
    background: none;
    border: none;
    padding: 8px 14px;
    font-size: 0.85rem;
    cursor: pointer;
    color: #334155;
}

.as-db-dropdown-menu button:hover {
    background-color: #f1f5f9;
    color: #2563eb;
}

.as-db-canvas-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.as-db-view-toggles,
.as-dl-view-group,
.as-dl-currency-group {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    background: #f1f5f9;
    padding: 3px;
    border-radius: 8px;
    border: 1px solid #cbd5e1;
}

.as-db-view-btn,
.as-dl-view-btn,
.as-dl-curr-btn {
    background: transparent;
    border: none;
    padding: 5px 12px;
    font-size: 0.85rem;
    font-weight: 700;
    cursor: pointer;
    border-radius: 6px;
    color: #64748b;
    transition: all 0.15s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1.2;
}

.as-dl-view-btn {
    padding: 5px 8px;
    min-width: 32px;
    min-height: 28px;
}

.as-dl-view-btn .dashicons,
.as-db-view-btn .dashicons {
    font-size: 18px;
    width: 18px;
    height: 18px;
    line-height: 18px;
    display: inline-block;
    vertical-align: middle;
}

.as-db-view-btn.active,
.as-dl-view-btn.active,
.as-dl-curr-btn.active {
    background: #ffffff;
    color: #0f172a;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
}

.as-db-view-btn:hover:not(.active),
.as-dl-view-btn:hover:not(.active),
.as-dl-curr-btn:hover:not(.active) {
    color: #1e293b;
}

.as-db-canvas-view {
    min-height: 400px;
    transition: border-color 0.2s ease;
}

.as-db-canvas-view.drag-active {
    border-color: #2563eb !important;
}

.as-db-icon-btn.is-favorite,
#as-modal-fav-btn.is-favorite,
#as-db-detail-fav-btn.is-favorite {
    color: #b91c1c !important;
}

.as-db-canvas-empty {
    text-align: center;
    padding: 60px 20px;
    color: #94a3b8;
    border: 2px dashed #e2e8f0;
    border-radius: 8px;
}

.as-db-search-tabs {
    display: flex;
    gap: 4px;
    border-bottom: 2px solid #e2e8f0;
    margin-bottom: 12px;
}

.as-db-search-tab {
    background: transparent;
    border: none;
    border-bottom: 3px solid transparent;
    padding: 8px 12px;
    font-size: 0.9rem;
    font-weight: 600;
    color: #64748b;
    cursor: pointer;
}

.as-db-search-tab.active {
    color: #2563eb;
    border-bottom-color: #2563eb;
}

.as-db-mobile-search-bar {
    display: none;
    position: relative;
    width: 100%;
    margin-bottom: 12px;
}

.as-db-search-bar-container {
    display: flex;
    flex-direction: column-reverse;
    gap: 6px;
    width: 100%;
}

.as-db-search-bar-actions {
    display: flex;
    align-items: center;
    gap: 4px;
    flex-shrink: 0;
}

.as-db-search-bar-actions .as-db-icon-btn {
    background: #f8fafc;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    padding: 6px 8px;
    font-size: 1rem;
    color: #475569;
    cursor: pointer;
    transition: all 0.15s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.as-db-search-bar-actions .as-db-icon-btn:hover {
    background: #eff6ff;
    color: #2563eb;
    border-color: #93c5fd;
}

.as-db-mobile-results-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 1000;
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 12px;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.2);
    margin-top: 6px;
    max-height: 480px;
    overflow-y: auto;
    padding: 12px;
}

.as-db-dropdown-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 8px;
    margin-bottom: 8px;
    border-bottom: 1px solid #e2e8f0;
}

.as-db-count-badge {
    font-size: 0.85rem;
    font-weight: 700;
    color: #2563eb;
}

.as-db-dropdown-close {
    background: transparent;
    border: none;
    color: #64748b;
    cursor: pointer;
    padding: 4px;
    font-size: 1.1rem;
}

.as-db-dropdown-close:hover {
    color: #ef4444;
}

.as-db-search-input-wrap {
    position: relative;
    flex-grow: 1;
    display: flex;
    align-items: center;
}

.as-db-search-icon {
    position: absolute;
    left: 10px;
    color: #94a3b8;
    font-size: 1.1rem;
    pointer-events: none;
}

.as-db-search-input-wrap .as-db-search-input {
    width: 100%;
    padding: 8px 34px 8px 32px;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    font-size: 0.9rem;
    background: #ffffff;
}

.as-db-search-input-wrap .as-db-search-input:focus {
    border-color: #2563eb;
    outline: none;
}

/* Clear Search 'X' Button */
.as-db-clear-search-btn {
    position: absolute;
    right: 8px;
    background: transparent;
    border: none;
    color: #94a3b8;
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: color 0.15s;
}

.as-db-clear-search-btn:hover {
    color: #b91c1c;
    background: #fee2e2;
}

.as-db-search-input-group {
    display: flex;
    gap: 6px;
    margin-bottom: 10px;
    flex-direction: column-reverse;
}

.as-db-search-input {
    flex-grow: 1;
    padding: 8px 12px;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    font-size: 0.9rem;
}

.as-db-filter-controls {
    display: flex;
    gap: 6px;
    align-items: center;
    margin-bottom: 10px;
}

.as-db-filter-btn {
    background: #f8fafc;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    padding: 6px 10px;
    font-size: 0.85rem;
    cursor: pointer;
}

.as-db-quick-pills-panel {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 8px;
    margin-bottom: 12px;
}

.as-db-pill-group,
.as-db-pill-list {
    display: flex !important;
    flex-wrap: nowrap !important;
    overflow-x: auto !important;
    overflow-y: hidden !important;
    gap: 6px !important;
    padding-bottom: 4px !important;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
}

.as-db-pill-group::-webkit-scrollbar,
.as-db-pill-list::-webkit-scrollbar {
    height: 4px;
}

.as-db-pill-group::-webkit-scrollbar-thumb,
.as-db-pill-list::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}

.as-db-pill,
.as-adv-pill {
    background: #ffffff;
    border: 1px solid #cbd5e1;
    padding: 5px 12px;
    border-radius: 16px;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    flex: 0 0 auto !important;
    white-space: nowrap !important;
    transition: all 0.15s ease;
}

.as-db-pill.active,
.as-adv-pill.active {
    background-color: #2563eb;
    color: #ffffff;
    border-color: #2563eb;
}

.as-db-search-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
    gap: 10px;
    max-height: 520px;
    overflow-y: auto;
    padding: 4px;
}

.as-db-search-card-item {
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    padding: 6px;
    text-align: center;
    cursor: pointer;
    transition: transform 0.15s, box-shadow 0.15s;
    position: relative;
}

.as-db-search-card-item.is-out-of-stock {
    opacity: 0.65;
    border-color: #fca5a5;
    background: #fff5f5;
}

.as-db-card-stock-tag {
    position: absolute;
    bottom: 45px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.7rem;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 10px;
    white-space: nowrap;
    box-shadow: 0 2px 4px rgba(0,0,0,0.15);
}

.as-db-card-stock-tag.out-of-stock {
    background: #ef4444;
    color: #ffffff;
}

.as-db-card-stock-tag.in-stock {
    background: #10b981;
    color: #ffffff;
}

.as-db-stock-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 700;
    margin-left: 6px;
    background: #ecfdf5;
    color: #047857;
    border: 1px solid #a7f3d0;
}

.as-db-stock-badge.out-of-stock {
    background: #fef2f2;
    color: #b91c1c;
    border-color: #fecaca;
}

.as-db-search-card-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 14px rgba(0, 0, 0, 0.12);
}

.as-db-search-card-thumb {
    width: 100%;
    height: 130px;
    object-fit: cover;
    border-radius: 4px;
}

.as-db-search-card-title {
    font-size: 0.75rem;
    font-weight: 700;
    color: #0f172a;
    margin: 4px 0 2px 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.as-db-search-card-price {
    font-size: 0.75rem;
    color: #16a34a;
    font-weight: 700;
}

.as-db-modal,
.as-dl-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    z-index: 100005 !important;
    display: flex;
    align-items: center;
    justify-content: center;
}

.as-db-modal-overlay,
.as-dl-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.65);
    backdrop-filter: blur(4px);
}

.as-db-modal-card-content,
.as-db-modal-advanced-content,
.as-dl-modal-image-content {
    position: relative;
    background: #ffffff;
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.25);
    max-height: 90vh;
    overflow-y: auto;
    z-index: 2;
}

.as-db-modal-card-content {
    width: 90%;
    max-width: 600px;
}

.as-modal-card-title {
    margin: 0;
}

.as-db-modal-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.as-db-modal-top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.as-db-modal-qty-bar {
    display: flex;
    align-items: center;
    border: 2px solid #b91c1c;
    border-radius: 8px;
    overflow: hidden;
    margin-top: 14px;
    margin-bottom: 14px;
    background: #ffffff;
}

.as-db-qty-bar-btn {
    flex: 1;
    padding: 10px;
    background: transparent;
    border: none;
    font-weight: 800;
    font-size: 1.1rem;
    cursor: pointer;
    color: #0f172a;
    transition: background 0.15s;
}

.as-db-qty-bar-btn:hover {
    background-color: #fee2e2;
    color: #b91c1c;
}

.as-db-qty-bar-status {
    flex: 2;
    text-align: center;
    font-weight: 700;
    font-size: 0.95rem;
    border-left: 1px solid #fee2e2;
    border-right: 1px solid #fee2e2;
    padding: 8px 0;
}

.as-db-modal-image-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 10px 0;
}

.as-db-modal-image-wrapper img {
    width: 100%;
    max-height: 380px;
    object-fit: contain;
    border-radius: 8px;
}

.as-modal-nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.85);
    border: 1px solid #cbd5e1;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 5;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    transition: all 0.2s;
}

.as-modal-nav-btn:hover {
    background: #ffffff;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
    color: #2563eb;
}

.as-modal-nav-prev {
    left: -10px;
}

.as-modal-nav-next {
    right: -10px;
}

.as-db-modal-details-body {
    text-align: center;
    margin-bottom: 12px;
}

.as-db-modal-category-text {
    font-size: 0.85rem;
    font-weight: 600;
    color: #64748b;
    margin-bottom: 6px;
}

.as-db-modal-desc-text {
    font-size: 0.82rem;
    color: #334155;
    line-height: 1.4;
    margin-bottom: 12px;
}

.as-db-modal-price-badges {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 12px;
}

.as-db-price-badge {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    padding: 6px 12px;
    font-size: 0.85rem;
    color: #475569;
}

.as-db-modal-btn-link {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: 100%;
    padding: 8px 0;
    text-align: center;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    background: #f8fafc;
    color: #334155 !important;
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s;
}

.as-db-modal-btn-link:hover {
    background: #ffffff;
    border-color: #2563eb;
    color: #2563eb !important;
}

.as-deck-list-wrapper {
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.as-dl-top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 14px;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 15px;
}

.as-dl-title {
    font-size: 1.5rem;
    margin: 0;
    color: #0f172a;
}

.as-dl-price {
    font-size: 1.25rem;
    font-weight: 700;
    color: #0284c7;
    margin-left: 8px;
}

.as-dl-controls {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.as-dl-select {
    padding: 6px 12px;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    font-size: 0.85rem;
    background: #ffffff;
    color: #1e293b;
    height: 34px;
}

.as-dl-list-layout {
    display: flex;
    gap: 24px;
}

.as-dl-tables-column {
    flex: 2;
}

.as-dl-preview-column {
    flex: 1;
    min-width: 240px;
}

.as-dl-preview-box {
    position: sticky;
    top: 20px;
    background: #f8fafc;
    border: 1px solid #cbd5e1;
    border-radius: 12px;
    padding: 12px;
    text-align: center;
}

.as-dl-preview-box img {
    width: 100%;
    max-height: 320px;
    object-fit: contain;
    border-radius: 8px;
    margin-bottom: 12px;
}

.as-dl-cat-header {
    background-color: #b91c1c;
    color: #ffffff;
    padding: 8px 14px;
    font-weight: 700;
    font-size: 1.05rem;
    border-radius: 6px 6px 0 0;
    margin-top: 14px;
}

.as-dl-row-item {
    display: flex;
    justify-content: space-between;
    padding: 8px 12px;
    border-bottom: 1px solid #f1f5f9;
    font-size: 0.9rem;
    cursor: pointer;
}

.as-dl-row-item:hover {
    background-color: #eff6ff;
}

.as-dl-card-link {
    color: #1e293b;
    text-decoration: none;
    font-weight: 600;
}

.as-dl-card-link:hover {
    color: #2563eb;
    text-decoration: underline;
}

.as-dl-set-badge {
    background: #0f172a;
    color: #ffffff;
    font-size: 0.7rem;
    padding: 2px 6px;
    border-radius: 4px;
    margin-left: 6px;
}

.as-dl-visual-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    gap: 14px;
    padding: 10px 0;
}

.as-dl-grid-card {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
}

.as-dl-grid-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: 8px;
}

.as-dl-grid-badge {
    position: absolute;
    bottom: 8px;
    left: 50%;
    transform: translateX(-50%);
    background: #b91c1c;
    color: #ffffff;
    font-weight: 800;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
}

.as-canvas-qty-control {
    position: absolute;
    bottom: 8px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    z-index: 10;
    pointer-events: auto;
}

.as-canvas-qty-circle-btn {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #18181b;
    border: 2px solid #ffffff;
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.15rem;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.45);
    transition: transform 0.15s, background-color 0.15s;
    padding: 0;
    user-select: none;
}

.as-canvas-qty-circle-btn:hover {
    background: #27272a;
    transform: scale(1.1);
}

.as-canvas-qty-circle-btn:active {
    transform: scale(0.92);
}

.as-canvas-qty-hex-badge {
    width: 32px;
    height: 36px;
    background: #b91c1c;
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    font-weight: 800;
    font-size: 1.05rem;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
    filter: drop-shadow(0 2px 5px rgba(0, 0, 0, 0.4));
    user-select: none;
}
.as-canvas-row-left {
    display: flex;
    align-items: center;
    gap: 8px;
}

.as-canvas-row-qty-btns {
    display: inline-flex;
    align-items: center;
    gap: 3px;
}

.as-canvas-row-btn {
    width: 20px;
    height: 20px;
    border-radius: 4px;
    border: 1px solid #cbd5e1;
    background: #f1f5f9;
    color: #0f172a;
    font-size: 0.85rem;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    padding: 0;
    line-height: 1;
    transition: background 0.15s;
}

.as-canvas-row-btn:hover {
    background: #e2e8f0;
    color: #b91c1c;
}

.as-canvas-row-qty-val {
    font-weight: 700;
    min-width: 14px;
    text-align: center;
}

.as-dl-grid-tools-group {
    display: none;
    align-items: center;
    gap: 6px;
    margin-left: 4px;
}

.as-dl-grid-tools-group.visible {
    display: inline-flex !important;
}

.as-dl-tool-btn {
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #1e293b;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
    transition: all 0.15s ease;
    padding: 0;
}

.as-dl-tool-btn:hover {
    background: #f8fafc;
    border-color: #2563eb;
    color: #2563eb;
    box-shadow: 0 2px 6px rgba(37, 99, 235, 0.15);
    transform: translateY(-1px);
}

.as-dl-tool-btn .dashicons {
    font-size: 1.15rem;
    width: auto;
    height: auto;
}

.as-dl-grid-layout {
    display: none;
}

.as-dl-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 100000;
}

.as-db-grid-notice {
    grid-column: 1 / -1;
    padding: 30px 20px;
    text-align: center;
    color: #94a3b8;
    font-size: 0.95rem;
}

.as-db-grid-notice.as-db-notice-loading {
    color: #64748b;
    padding: 24px 20px;
}

.as-db-grid-notice.as-db-notice-error {
    color: #ef4444;
    padding: 20px;
}

.as-dl-empty-category-notice {
    padding: 8px 12px;
    color: #94a3b8;
    font-size: 0.85rem;
    font-style: italic;
}

.as-dl-export-visual-grid {
    background: #111827;
    padding: 20px;
    border-radius: 12px;
}

.as-db-mobile-tab-bar {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #ffffff;
    border-top: 1px solid #cbd5e1;
    z-index: 9999;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
}

.as-db-mobile-tab-btn {
    flex: 1;
    padding: 12px;
    border: none;
    background: transparent;
    font-size: 1rem;
    font-weight: 700;
    color: #64748b;
    cursor: pointer;
}

.as-db-mobile-tab-btn.active {
    color: #2563eb;
    border-top: 3px solid #2563eb;
    background: #f8fafc;
}

@media (min-width: 901px) {
    .as-dl-tables-column {
        flex: 2;
        display: grid;
        grid-template-columns: 1fr 1fr;
        grid-template-rows: 1fr 1fr;
        gap: 20px;
    }

    #as-dl-block-pokemon {
        grid-column: 1;
        grid-row: 1 / 3;
    }

    #as-dl-block-trainer {
        grid-column: 2;
        grid-row: 1;
    }

    #as-dl-block-energy {
        grid-column: 2;
        grid-row: 2;
    }
}
.as-db-modal-close{
    padding: 10px;
}
.as-db-modal-header{
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.as-db-modal-advanced-content{
    width: 90%;
}
@media (max-width: 768px) {
    .as-db-modal-top-bar{
        display: flex;
        align-items: start;
        flex-direction: column;
    }
    #as-modal-card-title,#as-modal-card-title{
        font-size: 18px !important;
    }
    .as-db-modal-card-content{
        width: 85% !important;
    }
    .as-db-modal-header h3{
        font-size: 18px;
    }
   .as-db-modal-top-bar{
    flex-direction: column;
    align-items: start;
   }
}
@media (max-width: 900px) {
    .as-deck-builder-split-wrapper {
        flex-direction: column;
        gap: 12px;
        margin-bottom: 20px;
    }

    .as-db-left-panel,
    .as-db-right-panel {
        width: 100%;
        box-sizing: border-box;
    }

    .as-db-mobile-tab-bar {
        display: none !important;
    }

    .as-db-card-detail-panel {
        display: none !important;
    }


    .as-db-top-toolbar {
        display: flex;
        flex-direction: row;
        flex-wrap: nowrap;
        align-items: center;
        justify-content: space-between;
        gap: 8px;
        padding-bottom: 10px;
        margin-bottom: 10px;
    }

    .as-db-cover-box {
        width: 38px;
        height: 38px;
        flex-shrink: 0;
    }

    .as-db-title-box {
        flex: 1 1 auto;
        min-width: 0;
    }


    .as-db-title-input {
        width: 100%;
        font-size: 0.95rem;
        font-weight: 700;
        color: #0f172a !important;
        background: #ffffff;
        border: 1px solid #cbd5e1;
        border-radius: 6px;
        padding: 5px 8px;
    }

    .as-db-deck-meta-info {
        font-size: 0.72rem;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }


    .as-db-toolbar-actions {
        display: flex;
        flex-direction: row;
        flex-wrap: nowrap;
        align-items: center;
        gap: 4px;
        flex-shrink: 0;
    }

    .as-db-toolbar-actions .as-db-btn {
        padding: 6px 8px;
        font-size: 0.85rem;
        border-radius: 6px;
    }

    .as-db-toolbar-actions .as-db-btn-text {
        display: none !important;
    }

    .as-db-toolbar-actions .dashicons {
        margin: 0;
    }


    .as-db-mobile-search-bar {
        display: flex;
        flex-direction: column;
        position: relative;
        gap: 6px;
        margin-bottom: 12px;
        width: 100%;
    }

    .as-db-desktop-search-group {
        display: none !important;
    }

    .as-dl-list-layout {
        flex-direction: column;
    }

    .as-dl-preview-column {
        width: 100%;
    }

    .as-db-modal-card-content {
        width: 92%;
        padding: 14px;
        max-height: 85vh;
    }

    .as-db-search-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 6px;
    }

    #as-dl-preview-image {
        display: none;
    }

    .as-db-search-card-thumb {
        height: 100px;
    }
}
@media (max-width: 600px) {

    .as-db-top-toolbar {
        display: grid;
        grid-template-columns: 60px 1fr;
        grid-template-rows: auto auto;
        gap: 10px;
        align-items: center;
    }

    .as-db-cover-box {
        grid-column: 1;
        grid-row: 1;
        width: 60px;
        height: 85px;
        background-size: cover;
        background-position: center;
        background-repeat: no-repeat;
    }

    .as-db-title-box {
        grid-column: 2;
        grid-row: 1;
        min-width: 0;
    }

    .as-db-title-input {
        width: 100%;
        box-sizing: border-box;
    }

    .as-db-toolbar-actions {
        grid-column: 1 / -1;
        grid-row: 2;
        display: flex;
        align-items: center;
        gap: 6px;
        flex-wrap: wrap;
        width: 100%;
    }

    .as-db-btn-text {
        display: none;
    }
}
.as-db-loader-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 30px 15px;
    gap: 12px;
    width: 100%;
    grid-column: 1 / -1;
}

.as-db-paytm-loader {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.as-db-paytm-loader .as-db-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: #2563eb;
    display: inline-block;
    animation: as-db-dot-blink 1.2s infinite ease-in-out both;
}

.as-db-paytm-loader .as-db-dot:nth-child(1) { animation-delay: 0.0s; }
.as-db-paytm-loader .as-db-dot:nth-child(2) { animation-delay: 0.15s; }
.as-db-paytm-loader .as-db-dot:nth-child(3) { animation-delay: 0.30s; }
.as-db-paytm-loader .as-db-dot:nth-child(4) { animation-delay: 0.45s; }
.as-db-paytm-loader .as-db-dot:nth-child(5) { animation-delay: 0.60s; }

@keyframes as-db-dot-blink {
    0%, 80%, 100% {
        opacity: 0.25;
        transform: scale(0.7);
    }
    40% {
        opacity: 1;
        transform: scale(1.3);
    }
}

.as-db-loader-text {
    font-size: 0.85rem;
    font-weight: 600;
    color: #64748b;
}

.as-toast-container {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 999999;
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-width: 400px;
    width: calc(100% - 48px);
    pointer-events: none;
}

.as-toast {
    pointer-events: auto;
    display: flex;
    align-items: center;
    gap: 12px;
    background: #0f172a;
    color: #f8fafc;
    padding: 14px 18px;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.3);
    font-size: 0.9rem;
    font-weight: 600;
    line-height: 1.4;
    border-left: 5px solid #64748b;
    transform: translateY(0);
    opacity: 1;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    animation: as-toast-slide-in 0.35s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.as-toast.as-toast-hiding {
    opacity: 0;
    transform: translateY(20px) scale(0.95);
}

.as-toast-success {
    background: #0f172a;
    border-left-color: #22c55e;
}
.as-toast-success .as-toast-icon {
    color: #22c55e;
}

.as-toast-error {
    background: #0f172a;
    border-left-color: #ef4444;
}
.as-toast-error .as-toast-icon {
    color: #ef4444;
}

.as-toast-warning {
    background: #0f172a;
    border-left-color: #f59e0b;
}
.as-toast-warning .as-toast-icon {
    color: #f59e0b;
}

.as-toast-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    flex-shrink: 0;
}

.as-toast-content {
    flex: 1;
}

.as-toast-close {
    background: none;
    border: none;
    color: #94a3b8;
    cursor: pointer;
    padding: 2px;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s;
}
.as-toast-close:hover {
    color: #ffffff;
}

@keyframes as-toast-slide-in {
    from {
        opacity: 0;
        transform: translateY(30px) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}


.as-db-variation-wrapper {
    margin-top: 6px;
    width: 100%;
}

.as-db-variation-select {
    width: 100%;
    padding: 5px 8px;
    font-size: 0.78rem;
    font-weight: 600;
    color: #1e293b;
    background-color: #f8fafc;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    outline: none;
    cursor: pointer;
    transition: all 0.2s ease;
    text-overflow: ellipsis;
    white-space: nowrap;
    overflow: hidden;
    appearance: auto;
}

.as-db-variation-select:hover,
.as-db-variation-select:focus {
    border-color: #2563eb;
    background-color: #ffffff;
    box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.15);
}

.as-db-variation-select option {
    font-size: 0.82rem;
    padding: 4px 6px;
    color: #0f172a;
    background-color: #ffffff;
}

.as-db-search-input-wrap textarea.as-db-search-textarea {
    min-height: 48px;
    max-height: 120px;
    resize: vertical;
    padding: 8px 36px 8px 32px;
    font-family: inherit;
    font-size: 0.88rem;
    line-height: 1.4;
    border-radius: 8px;
    border: 1px solid #cbd5e1;
    width: 100%;
    box-sizing: border-box;
}

.as-db-search-input-wrap textarea.as-db-search-textarea:focus {
    border-color: #2563eb;
    outline: none;
    box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.15);
}