:root {
    --luna-dark-blue: #2f4056;
    --luna-primary-blue: #3C8CE7;
    --luna-light-gray: #f2f2f2;
    --luna-text-dark: #333;
    --luna-box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}
body {
    background-color: var(--luna-light-gray);
    color: var(--luna-text-dark);
    overflow-y: scroll; 
}
a {
    color: var(--luna-text-dark);
    text-decoration: none;
    transition: color 0.2s;
}
a:hover {
    color: var(--luna-primary-blue);
    text-decoration: none;
}
.main-box {
    background-color: #fff;
    padding: 10px;
    margin-bottom: 20px;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgb(0 0 0 / 5%);
}
.goods .title-2 {
    font-size: 17px;
    font-weight: 600;
    color: var(--luna-text-dark);
    margin-top: 0px;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
}
.goods .title-2 i {
    margin-right: 8px;
}
.badge-tag {
    border: 1px solid #dc3545;
    background-color: #dc3545;
    margin-right: 4px;
    margin-bottom: 4px;
    display: inline-block;
    padding: 0.01em 0.6em;
    font-size: 11px;
    font-weight: 400;
    color: #fff;
    text-align: center;
    white-space: nowrap;
    vertical-align: baseline;
    border-radius: 3em;
}
.category-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 20px;
}
.product-detail-grid {
    display: grid;
    grid-template-columns: 1.8fr 1fr; 
    gap: 15px; 
    margin-bottom: 30px;
    align-items: start; 
}
.detail-left {
    min-width: 0;
}
.detail-right {
    min-width: 0;
}
.detail-right .sidebar-inner {
    margin-bottom: 0 !important;
}
.img-aspect-ratio-box {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%; 
    height: 0;
    overflow: hidden;
    border-radius: 6px;
    border: 1px solid #eee;
    margin-bottom: 15px;
    background-color: #f8f9fa;
}
.detail-product-img {
    position: absolute !important;
    top: 50% !important;
    left: 50% !important;
    transform: translate(-50%, -50%) !important;
    width: auto !important;
    height: auto !important;
    max-width: calc(100% - 35px) !important;
    max-height: calc(100% - 35px) !important;
    border-radius: 8px; 
    box-shadow: 0 4px 12px rgba(0,0,0,0.15); 
}
.product-page-title {
    font-size: 18px;
    font-weight: 700;
    color: var(--luna-text-dark);
    margin-bottom: 8px;
    line-height: 1.4;
}
.detail-price-lg {
    font-size: 24px;
    color: var(--luna-primary-blue);
    font-weight: 700;
    margin-right: 5px;
}
.variant-btn {
    position: relative;
    overflow: visible; 
    border: 1px solid #ddd;
    background: #fff;
    color: #555;
    padding: 3px 8px;
    margin-right: 5px;
    margin-bottom: 8px;
    border-radius: 4px;
    font-family: "Arial Narrow", Arial, sans-serif !important;
    font-weight: 700 !important;
    font-size: 15px !important;
    cursor: pointer;
    transition: all 0.2s;
}
.variant-btn:hover {
    border-color: var(--luna-primary-blue);
    color: var(--luna-primary-blue);
}
.variant-btn.active {
    background-color: var(--luna-primary-blue);
    color: #fff;
    border-color: var(--luna-primary-blue);
}
.variant-btn.disabled {
    opacity: 0.6;
    cursor: not-allowed;
    background-color: #f9f9f9;
}
.variant-btn.no-stock {
    background-color: #f5f5f5;
    color: #999;
    border-color: #eee;
    text-decoration: line-through; 
}
.sku-oos-badge {
    position: absolute;
    top: -9px;
    right: -5px;
    background-color: #dc3545;
    color: #fff;
    font-size: 10px;
    padding: 2px 4px;
    border-radius: 4px;
    line-height: 1;
    z-index: 10;
    text-decoration: none; 
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    font-weight: normal;
}
.method-btn {
    font-family: "Arial Narrow", Arial, sans-serif !important;
    font-size: 15px !important;
    font-weight: bold !important;
}
.method-btn.active-method {
    background-color: var(--luna-primary-blue);
    color: #fff;
    border-color: var(--luna-primary-blue);
}
.number-selector-overlay {
    display: none;
    flex-direction: column;
    background: #fff;
    border: 1px solid #eee;
    border-radius: 8px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.15);
    z-index: 100;
    overflow: hidden;
}
.ns-header {
    padding: 8px 12px;
    background: #f8f9fa;
    border-bottom: 1px solid #eee;
    font-weight: bold;
    font-size: 13px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.ns-close { cursor: pointer; padding: 0 5px; font-size: 16px; color: #999; }
.ns-body { flex: 1; overflow-y: auto; padding: 10px; }
.ns-footer {
    text-align: center; padding: 8px 0; border-top: 1px solid #eee;
    cursor: pointer; color: #666; font-size: 12px; background: #fff;
}
.ns-item {
    display: inline-block;
    padding: 4px 8px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 12px;
    cursor: pointer;
    margin-right: 6px; margin-bottom: 6px;
    transition: all 0.2s;
    font-family: Arial, sans-serif;
}
.ns-item:hover { border-color: var(--luna-primary-blue); color: var(--luna-primary-blue); }
.ns-item.selected {
    background-color: var(--luna-primary-blue);
    border-color: var(--luna-primary-blue);
    color: #fff;
}
.spec-pagination-container {
    margin-top: 8px;
    text-align: left;
    display: none;
    padding-top: 8px;
    border-top: 1px dashed #eee;
}
.spec-pagination-btn {
    display: inline-block;
    padding: 2px 8px;
    margin: 0 3px;
    border: 1px solid #ddd;
    background-color: #fff;
    color: #555;
    cursor: pointer;
    border-radius: 3px;
    font-size: 12px;
    user-select: none;
    transition: all 0.2s;
}
.spec-pagination-btn:hover { background-color: #f0f0f0; border-color: #ccc; }
.spec-pagination-btn.active {
    background-color: var(--luna-primary-blue); color: #fff; border-color: var(--luna-primary-blue);
}
.spec-pagination-btn.disabled { opacity: 0.5; cursor: not-allowed; background-color: #f9f9f9; }
.payment-option {
    position: relative; 
    display: inline-flex;
    align-items: center; 
    justify-content: center;
    padding: 4px 8px; 
    height: 36px; 
    min-width: 36px;
    font-size: 20px; 
    border: 1px solid #ddd; 
    border-radius: 4px;
    margin-right: 10px; 
    cursor: pointer; 
    background: #fff; 
    transition: all 0.2s;
}
.payment-option:hover { border-color: var(--luna-primary-blue); }
.payment-option.active { border-color: var(--luna-primary-blue); color: var(--luna-primary-blue); }
.payment-check-mark {
    position: absolute; top: -6px; right: -6px;
    width: 14px; height: 14px; 
    background-color: var(--luna-primary-blue); 
    color: #fff;
    border-radius: 50%; font-size: 9px; 
    display: flex; align-items: center; justify-content: center;
    opacity: 0; transform: scale(0); transition: all 0.2s; z-index: 1;
}
.payment-option.active .payment-check-mark { opacity: 1; transform: scale(1); }
.form-control:focus {
    border-color: var(--luna-primary-blue);
    box-shadow: none !important; 
    outline: none;
}
.form-control::placeholder { color: #ccc !important; font-size: 12px; opacity: 1; }
.form-control::-webkit-input-placeholder { color: #ccc !important; font-size: 12px; }
.form-control::-moz-placeholder { color: #ccc !important; font-size: 12px; opacity: 1; }
.form-control:-ms-input-placeholder { color: #ccc !important; font-size: 12px; }
.status-badge {
    font-size: 12px;
    font-weight: 600;
    padding: 3px 6px;
    border-radius: 4px;
}
.bg-warning { background-color: #ffc107!important; color: #333!important; }
.bg-info { background-color: #0dcaf0!important; color: #333!important; }
.bg-success { background-color: #198754!important; color: #fff!important; }
@media (max-width: 991px) {
    .product-detail-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    .detail-right {
        position: static;
        order: -1; 
    }
}
.responsive-price, .responsive-btn {
    min-width: 80px;
}
@media (max-width: 767px) {
    .responsive-price {
        min-width: 0px;
    }
    .responsive-btn {
        min-width: 0px;
    }
    .goods .title-2 { font-size: 13px; margin-bottom: 6px; }
    .badge-tag { font-size: 10px; }
    .main-box { margin-bottom: 10px; }
    .category-bar {gap: 0px;}
    .my-4 { margin-top: 1rem !important; margin-bottom: 1rem !important; }
}

.stepper { display: flex; border: 1px solid #dee2e6; border-radius: 4px; overflow: hidden; width: 90px; height: 28px; }
.stepper-btn { width: 26px; display: flex; align-items: center; justify-content: center; background: #f8f9fa; cursor: pointer; font-size: 14px; border: none; transition: background 0.2s; color: #555; padding: 0; }
.stepper-btn:hover { background: #e9ecef; color: var(--luna-primary-blue); }
.stepper-input { width: 38px; border: none; border-left: 1px solid #dee2e6; border-right: 1px solid #dee2e6; text-align: center; font-size: 13px; outline: none; color: #333; padding: 0; }
.stepper-input::-webkit-outer-spin-button, .stepper-input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.cart-footer-bar { z-index: 1030; background: #fff; border-top: 1px solid #eee; box-shadow: 0 -2px 10px rgba(0,0,0,0.05); padding: 10px 15px; }
.payment-list-container { display: flex; flex-wrap: wrap; gap: 8px; }
.table > :not(caption) > * > * { border-bottom-width: 1px; padding: 1rem 0.5rem; }
.back-to-top {
    position: fixed;
    bottom: 120px;
    right: 30px;
    width: 45px;
    height: 45px;
    border: 1px solid #e9e9e9;
    background-color: #fffcfcfa;
    color: #00000091;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    z-index: 1050;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}
.back-to-top.show {
    opacity: 1;
    visibility: visible;
}
.back-to-top:hover {
    transform: translateY(-5px);
    opacity: 0.9;
    background-color:#ffffff; 
}

@media (max-width: 991px) {
    .cart-grid-fallback { display: block !important; }
    .back-to-top {
        bottom: 110px;
        right: 12px;
        width: 43px;
        height: 43px;
    }
    body { padding-bottom: 55px; }
    .mobile-bottom-nav {
        position: fixed; bottom: 0; left: 0; width: 100%; height: 47px; 
        background: #fff; border-top: 1px solid #eee; z-index: 1025; 
        display: flex; justify-content: space-around; box-shadow: 0 -2px 10px rgba(0,0,0,0.05);
    }
    .mbn-item {
        flex: 1; display: flex; flex-direction: column; align-items: center;
        justify-content: center; color: #666; font-size: 10px; padding: 5px 0;
        text-decoration: none; position: relative;
    }
    .mbn-item i { font-size: 14px; margin-bottom: 1px; line-height: 1; }
    .mbn-item.active, .mbn-item:hover { color: var(--luna-primary-blue); }
    .footer-cart-badge {
        top: 2px !important; 
        right: calc(50% - 20px) !important;
    }
}
#mobile-checkout-row::-webkit-scrollbar {
    height: 4px; 
    display: block; 
}

#mobile-checkout-row::-webkit-scrollbar-track {
    background: #f8f9fa; 
    border-radius: 4px;
}

#mobile-checkout-row::-webkit-scrollbar-thumb {
    background: #c5c5c5; 
    border-radius: 4px;
}
#mobile-checkout-row {
    scrollbar-width: thin;
    scrollbar-color: #c5c5c5 #f8f9fa;
}
