/* =========================
   Product Table
========================= */

#psd-product-table-app {
    width: 100%;
    direction: rtl;
}

.psd-product-table-shell {
    width: 100%;
    overflow-x: auto;
    background: #101820;
    border: 1px solid rgba(255,255,255,.16);
    border-radius: 14px;
    box-shadow: 0 10px 30px rgba(0,0,0,.18);
}

.psd-product-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 860px;
    color: rgba(255,255,255,.86);
}

.psd-product-table th,
.psd-product-table td {
    padding: 14px 12px;
    text-align: center;
    border-bottom: 1px solid rgba(255,255,255,.10);
    border-left: 1px solid rgba(255,255,255,.08);
    font-size: 14px;
    white-space: nowrap;
}

.psd-product-table th:last-child,
.psd-product-table td:last-child {
    border-left: none;
}

.psd-product-table th {
    background: #0b121a;
    color: #ffffff;
    font-weight: 800;
    font-size: 13px;
}

.psd-product-table tbody tr {
    transition: background .2s ease;
}

.psd-product-table tbody tr:hover {
    background: rgba(255,255,255,.04);
}

.psd-product-table td:nth-last-child(2) {
    color: #4ade80;
    font-weight: 800;
}

.psd-product-table button {
    border: 0;
    border-radius: 8px;
    padding: 8px 14px;
    cursor: pointer;
    background: #d32f2f;
    color: #ffffff;
    font-family: inherit;
    font-size: 13px;
    font-weight: 700;
    transition: all .2s ease;
}

.psd-product-table button:hover {
    background: #b91c1c;
}

.psd-product-table button:disabled {
    opacity: .65;
    cursor: not-allowed;
}

.psd-table-empty,
.psd-table-error,
.psd-table-loading {
    background: #101820;
    border: 1px solid rgba(255,255,255,.16);
    border-radius: 14px;
    padding: 18px;
    color: rgba(255,255,255,.75);
}

/* =========================
   Product Categories Carousel
========================= */

.psd-category-grid {
    display: flex;
    flex-wrap: nowrap;
    gap: 20px;
    margin-bottom: 30px;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    padding-bottom: 10px;
    direction: rtl;
}

.psd-category-card {
    position: relative;
    min-width: 31.5%;
    width: 31.5%;
    min-height: 150px;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    text-decoration: none;
    background: #101820;
    border: 1px solid rgba(255,255,255,.16);
    border-radius: 12px;
    overflow: hidden;
    transition: all .25s ease;
    box-shadow: 0 4px 14px rgba(0,0,0,.12);
    padding: 18px 24px;
    scroll-snap-align: start;
    flex: 0 0 31.5%;
}

.psd-category-card:hover {
    transform: none;
    border-color: rgba(211,47,47,.65);
    box-shadow: 0 0 0 1px rgba(211,47,47,.25), 0 12px 24px rgba(0,0,0,.22);
}

.psd-category-card.active {
    border: 2px solid #d32f2f;
    box-shadow: 0 0 0 1px rgba(211,47,47,.25), 0 12px 30px rgba(211,47,47,.20);
}

.psd-category-image {
    width: 48%;
    height: 135px;
    background: transparent;
    overflow: visible;
    flex: 0 0 48%;
}

.psd-category-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
    display: block;
}

.psd-category-name {
    width: 48%;
    text-align: center;
    font-size: 22px;
    font-weight: 800;
    color: #ffffff;
    line-height: 1.6;
}

.psd-category-check {
    position: absolute;
    top: 10px;
    left: 50%;
    transform: translateX(-50%);
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #d32f2f;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 15px;
    font-weight: 800;
    z-index: 2;
}

.psd-category-placeholder {
    width: 100%;
    height: 100%;
    background: rgba(255,255,255,.08);
}

@media (max-width: 900px) {
    .psd-category-card {
        min-width: 48%;
        width: 48%;
        flex-basis: 48%;
    }
}

@media (max-width: 600px) {
    .psd-category-card {
        min-width: 85%;
        width: 85%;
        flex-basis: 85%;
    }

    .psd-category-name {
        font-size: 18px;
    }
}

.psd-category-grid::-webkit-scrollbar{
    display:none;
}

.psd-category-grid{
    -ms-overflow-style:none;
    scrollbar-width:none;
}

.psd-category-section{
    position:relative;
}

.psd-category-nav{
    position:absolute;
    top:50%;
    transform:translateY(-50%);
    width:44px;
    height:44px;
    border:none;
    border-radius:50%;
    background:#d32f2f;
    color:#fff;
    cursor:pointer;
    z-index:20;
    font-size:28px;
    line-height:1;
    display:flex;
    align-items:center;
    justify-content:center;
}

.psd-category-prev{
    right:-22px;
}

.psd-category-next{
    left:-22px;
}

.psd-category-grid::-webkit-scrollbar{
    display:none;
}

.psd-category-grid{
    scrollbar-width:none;
    -ms-overflow-style:none;
}

/* =========================
   Product Filters - Dropdown Bar
========================= */

#psd-product-filters {
    width: 100%;
    direction: rtl;
    margin: 22px 0 26px;
}

.psd-filters-box {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    align-items: center;
    background: #101820;
    border: 1px solid rgba(255,255,255,.16);
    border-radius: 14px;
    padding: 16px 18px;
}

.psd-filter-group {
    position: relative;
    min-width: 170px;
    flex: 1 1 170px;
}

.psd-filter-title {
    color: #ffffff;
    font-size: 12px;
    font-weight: 800;
    margin-bottom: 7px;
}

.psd-filter-dropdown-toggle {
    width: 100%;
    height: 44px;
    border: 1px solid rgba(255,255,255,.16);
    border-radius: 10px;
    background: #0b121a;
    color: rgba(255,255,255,.88);
    padding: 0 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    font-family: inherit;
    font-size: 13px;
}

.psd-filter-arrow {
    font-size: 16px;
    color: #ffffff;
}

.psd-filter-dropdown-menu {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    width: 100%;
    max-height: 220px;
    overflow-y: auto;
    background: #0b121a;
    border: 1px solid rgba(255,255,255,.16);
    border-radius: 10px;
    padding: 10px;
    z-index: 999;
    box-shadow: 0 14px 30px rgba(0,0,0,.35);
}

.psd-filter-group.open .psd-filter-dropdown-menu {
    display: block;
}

.psd-filter-option {
    display: flex;
    align-items: center;
    gap: 8px;
    color: rgba(255,255,255,.78);
    font-size: 13px;
    cursor: pointer;
    padding: 7px 4px;
    margin: 0;
    white-space: nowrap;
}

.psd-filter-option input {
    width: 14px;
    height: 14px;
    accent-color: #d32f2f;
    cursor: pointer;
}

.psd-filter-option:hover {
    color: #ffffff;
}

.psd-filter-empty,
.psd-filter-loading {
    background: #101820;
    border: 1px solid rgba(255,255,255,.16);
    border-radius: 14px;
    padding: 16px 18px;
    color: rgba(255,255,255,.75);
}

.psd-product-row {
    cursor: pointer;
}

.psd-product-row-active {
    background: rgba(211,47,47,.16) !important;
}

/* =========================
   Selected Product Sidebar
========================= */

#psd-selected-product-panel {
    direction: rtl;
    width: 100%;
}

.psd-selected-empty {
    color: rgba(255,255,255,.55);
    font-size: 13px;
    line-height: 1.9;
    text-align: center;
    padding: 18px 8px;
}

.psd-selected-product {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.psd-selected-title {
    color: #ffffff;
    font-size: 16px;
    font-weight: 900;
    line-height: 1.8;
    text-align: center;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(211,47,47,.55);
}

.psd-selected-price {
    color: #ef4444;
    font-size: 24px;
    font-weight: 900;
    text-align: center;
    padding: 10px 0;
}

.psd-selected-attributes {
    background: rgba(255,255,255,.03);
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 12px;
    padding: 12px;
}

.psd-selected-attribute {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255,255,255,.08);
}

.psd-selected-attribute:last-child {
    border-bottom: none;
}

.psd-selected-label {
    color: rgba(255,255,255,.58);
    font-size: 12px;
}

.psd-selected-value {
    color: #ffffff;
    font-size: 13px;
    font-weight: 800;
    text-align: left;
}

.psd-selected-add-to-cart {
    width: 100%;
    border: 0;
    border-radius: 10px;
    padding: 13px 16px;
    background: #d32f2f;
    color: #ffffff;
    font-family: inherit;
    font-size: 14px;
    font-weight: 900;
    cursor: pointer;
    transition: all .2s ease;
}

.psd-selected-add-to-cart:hover {
    background: #b91c1c;
}

/* =========================
   Price Settings Panel
========================= */

.psd-price-panel {
    background: #101820;
    border: 1px solid rgba(255,255,255,.16);
    border-radius: 14px;
    padding: 18px;
    direction: rtl;
}

.psd-price-panel-title {
    color: #ffffff;
    font-size: 17px;
    font-weight: 900;
    padding-bottom: 12px;
    margin-bottom: 14px;
    border-bottom: 1px solid rgba(211,47,47,.65);
}

.psd-vat-toggle {
    display: flex;
    align-items: center;
    gap: 8px;
    color: rgba(255,255,255,.85);
    font-size: 14px;
    cursor: pointer;
}

.psd-vat-toggle input {
    width: 16px;
    height: 16px;
    accent-color: #d32f2f;
}

.psd-vat-note {
    margin-top: 10px;
    color: rgba(255,255,255,.55);
    font-size: 13px;
}

/* =========================
   Export Button
========================= */

.psd-export-csv {
    border: 1px solid rgba(255,255,255,.16);
    border-radius: 10px;
    padding: 10px 16px;
    background: #101820;
    color: #ffffff;
    font-family: inherit;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
    transition: all .2s ease;
}

.psd-export-csv:hover {
    border-color: rgba(211,47,47,.75);
    background: #d32f2f;
}

.psd-export-csv::before {
    content: "📊";
    margin-left: 6px;
}

/* =========================
   Table Plus Button
========================= */

.psd-row-action {
    width: 34px !important;
    height: 34px !important;
    padding: 0 !important;
    border-radius: 50% !important;
    background: transparent !important;
    border: 2px solid rgba(255,255,255,.45) !important;
    color: #ffffff !important;
    font-size: 22px !important;
    font-weight: 700 !important;
    line-height: 1 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    transition: all .2s ease;
}

.psd-row-action:hover {
    border-color: #d32f2f !important;
    background: rgba(211,47,47,.15) !important;
    color: #ffffff !important;
}

.psd-row-action:disabled {
    opacity: .7;
}

/* =========================
   Filters UI Upgrade
========================= */

.psd-filters-box{
    background: linear-gradient(180deg,#101820 0%,#0b121a 100%);
    box-shadow: 0 10px 30px rgba(0,0,0,.18);
}

.psd-filter-group{
    min-width: 200px;
}

.psd-filter-title{
    font-size: 13px;
    font-weight: 900;
    margin-bottom: 10px;
    color: #ffffff;
}

.psd-filter-dropdown-toggle{
    height: 48px;
    border-radius: 12px;
    border: 1px solid rgba(255,255,255,.12);
    transition: all .2s ease;
}

.psd-filter-dropdown-toggle:hover{
    border-color: rgba(211,47,47,.55);
}

.psd-filter-group.open .psd-filter-dropdown-toggle{
    border-color: #d32f2f;
    box-shadow: 0 0 0 1px rgba(211,47,47,.25);
}

.psd-filter-selected-text{
    font-weight: 700;
    color: #ffffff;
}

.psd-filter-arrow{
    transition: transform .2s ease;
}

.psd-filter-group.open .psd-filter-arrow{
    transform: rotate(180deg);
}

.psd-filter-dropdown-menu{
    border-radius: 12px;
    padding: 8px;
    background: #081018;
}

.psd-filter-option{
    border-radius: 8px;
    padding: 10px;
    transition: all .15s ease;
}

.psd-filter-option:hover{
    background: rgba(255,255,255,.05);
}

.psd-filter-option input{
    width: 16px;
    height: 16px;
}

.psd-filter-dropdown-menu::-webkit-scrollbar{
    width: 6px;
}

.psd-filter-dropdown-menu::-webkit-scrollbar-thumb{
    background: rgba(255,255,255,.15);
    border-radius: 20px;
}

/* =========================
   Reset Filters Button
========================= */

.psd-reset-filters {
    min-width: 150px;
    height: 48px;
    border: 1px solid rgba(255,255,255,.16);
    border-radius: 12px;
    background: #0b121a;
    color: #ffffff;
    font-family: inherit;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
    transition: all .2s ease;
}

.psd-reset-filters:hover {
    border-color: rgba(211,47,47,.75);
    background: rgba(211,47,47,.18);
}

/* =========================
   Active Filter Chips
========================= */

#psd-active-filters {
    width: 100%;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 14px;
}

.psd-filter-chip {
    border: 1px solid rgba(211,47,47,.55);
    border-radius: 30px;
    background: rgba(211,47,47,.16);
    color: #ffffff;
    padding: 7px 12px;
    font-family: inherit;
    font-size: 12px;
    font-weight: 800;
    cursor: pointer;
    transition: all .2s ease;
}

.psd-filter-chip:hover {
    background: #d32f2f;
}