/**
 * Product edit (pjAdminProducts / pjActionUpdate) — Deepak-style shell.
 * Loaded only on this action; scoped to #frmUpdateProduct.sc-product-update.
 */

/* ----- Page heading (match order-edit chrome) ----- */
.row.wrapper.border-bottom.white-bg.page-heading.sc-product-page-heading,
.sc-product-page-heading {
    padding-top: 18px;
    padding-bottom: 16px;
}

.sc-product-page-heading h2 {
    margin: 0 0 8px;
    font-size: 22px;
    font-weight: 700;
    color: var(--pj-text, #2d3436);
}

.sc-product-page-heading p {
    margin: 0;
    font-size: 14px;
    line-height: 1.5;
    color: var(--pj-text-muted, #636e72);
}

.sc-product-page-heading .fa-info-circle {
    color: var(--admin-primary, #c2570c);
    margin-right: 6px;
}

.sc-product-page-heading .product-page-heading__row {
    margin-top: 4px;
}

.sc-product-page-heading .btn-group-languages {
    margin-top: 4px;
}

@media (min-width: 768px) {
    .sc-product-page-heading .product-page-heading__row p.m-b-none {
        max-width: calc(100% - 220px);
    }
}

/* ----- Soft info banners (first alert in each tab) ----- */
#frmUpdateProduct.sc-product-update .tab-pane > .panel-body > .alert.alert-success:first-child {
    border-radius: var(--pj-radius, 8px);
    border: 1px solid rgba(249, 115, 22, 0.2);
    background: rgba(249, 115, 22, 0.06);
    color: #14532d;
    margin-bottom: 18px;
}

#frmUpdateProduct.sc-product-update .tab-pane > .panel-body > .alert.alert-success:first-child strong {
    color: var(--admin-primary-dark, #06370d);
}

/* Info strip inside adm-card (e.g. Similar tab: heading then alert) */
#frmUpdateProduct.sc-product-update .adm-card > .alert.alert-success {
    border-radius: var(--pj-radius, 8px);
    border: 1px solid rgba(249, 115, 22, 0.2);
    background: rgba(249, 115, 22, 0.06);
    color: #14532d;
    margin-bottom: 16px;
}

#frmUpdateProduct.sc-product-update .adm-card > .alert.alert-success strong {
    color: var(--admin-primary-dark, #06370d);
}

/* ----- adm-card panels ----- */
#frmUpdateProduct.sc-product-update .adm-card {
    background: rgba(249, 115, 22, 0.03);
    border: 1px solid var(--pj-border, #e8e4ef);
    border-radius: 10px;
    padding: 16px 20px;
    margin-bottom: 20px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

#frmUpdateProduct.sc-product-update .adm-card__heading {
    margin: 0 0 14px;
    padding: 0;
    font-size: 14px;
    font-weight: 700;
    color: var(--pj-text, #2d3436);
    display: flex;
    align-items: center;
    gap: 8px;
}

#frmUpdateProduct.sc-product-update .adm-card__heading .fa {
    color: var(--admin-primary, #c2570c);
    font-size: 16px;
}

#frmUpdateProduct.sc-product-update .adm-card .control-label {
    font-size: 13px;
    font-weight: 500;
    color: var(--pj-text, #2d3436);
}

/* ----- Action row ----- */
#frmUpdateProduct.sc-product-update .hr-line-dashed + .clearfix,
#frmUpdateProduct.sc-product-update .m-b-md {
    margin-bottom: 16px !important;
}

/* Multilang floating bar — brand primary (overrides inline theme hex) */
#frmUpdateProduct.sc-product-update .pj-form-langbar-item.btn-primary,
#frmUpdateProduct.sc-product-update .pj-form-langbar-item.btn-primary:focus {
    background: var(--admin-primary, #c2570c) !important;
    border-color: var(--admin-primary, #c2570c) !important;
}

/* Datagrid loading overlay (jquery.datagrid uses .ibox-content by default; Similar tab uses .adm-card + data-wrapper) */
#frmUpdateProduct.sc-product-update .adm-card > .sk-spinner {
    display: none;
}
#frmUpdateProduct.sc-product-update .adm-card.sk-loading {
    position: relative;
}
#frmUpdateProduct.sc-product-update .adm-card.sk-loading:after {
    content: '';
    background-color: rgba(255, 255, 255, 0.7);
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: inherit;
}
#frmUpdateProduct.sc-product-update .adm-card.sk-loading > .sk-spinner {
    display: block;
    position: absolute;
    top: 40%;
    left: 0;
    right: 0;
    z-index: 2000;
}

/* Model image tab (separate from Photos gallery) */
#frmUpdateProduct.sc-product-update #product-model-image .pj-model-image-grid-wrap {
    padding: 12px;
    background: #f9f9f9;
    border: 1px dashed var(--pj-border, #ddd);
    border-radius: 6px;
    min-height: 80px;
}

#frmUpdateProduct.sc-product-update #product-model-image .pj-model-image-item {
    position: relative;
    display: inline-block;
    vertical-align: top;
    margin: 0 10px 12px 0;
    text-align: center;
}

#frmUpdateProduct.sc-product-update #product-model-image .pj-model-image-delete {
    position: absolute;
    top: 4px;
    right: 4px;
    z-index: 2;
    width: 22px;
    height: 22px;
    padding: 0;
    line-height: 20px;
    border-radius: 50%;
    opacity: 0.92;
}

#frmUpdateProduct.sc-product-update #product-model-image .pj-model-image-grid .s-Img {
    width: 88px;
    height: 88px;
    max-width: 88px;
    max-height: 88px;
}

#frmUpdateProduct.sc-product-update #product-model-image .pj-model-image-active-badge {
    display: block;
    margin-top: 4px;
    font-size: 10px;
    font-weight: 600;
    padding: 2px 6px;
}
/* Stock tab wide table scroll */
#frmUpdateProduct.sc-product-update #product-stock .stockContainer {
    display: block;
    width: 100%;
    max-width: 100%;
    overflow-x: auto !important;
    overflow-y: visible;
    padding-bottom: 14px;
    margin-bottom: 18px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: #c2570c #e8e4ef;
}

#frmUpdateProduct.sc-product-update #product-stock .stockContainer::-webkit-scrollbar {
    height: 12px;
}

#frmUpdateProduct.sc-product-update #product-stock .stockContainer::-webkit-scrollbar-track {
    background: #e8e4ef;
    border-radius: 8px;
}

#frmUpdateProduct.sc-product-update #product-stock .stockContainer::-webkit-scrollbar-thumb {
    background: #c2570c;
    border-radius: 8px;
}

#frmUpdateProduct.sc-product-update #product-stock .tblStocks {
    width: 100%;
    max-width: none;
    margin-bottom: 0;
    table-layout: auto;
}

#frmUpdateProduct.sc-product-update #product-stock .tblStocks th,
#frmUpdateProduct.sc-product-update #product-stock .tblStocks td {
    white-space: nowrap;
    vertical-align: middle;
}

#frmUpdateProduct.sc-product-update #product-stock .tblStocks input.form-control,
#frmUpdateProduct.sc-product-update #product-stock .tblStocks select.form-control {
    min-width: 120px;
}

#frmUpdateProduct.sc-product-update #product-stock .tblStocks td:first-child,
#frmUpdateProduct.sc-product-update #product-stock .tblStocks th:first-child {
    min-width: 90px;
}