/* ==========================================================================
   Quick Order Top-Right Block
   Scoped under .nu-quick-order-top to avoid collisions
   ========================================================================== */

.nu-quick-order-top {
    border: none;
    border-radius: 6px;
    padding: 0;
    /* margin-top: 20px; */
    margin-bottom: 20px;
    background: #fff;
}

/* ---------- Color ---------- */
.nu-qo-color-picker {
    margin-bottom: 14px;
}

.nu-qo-color-picker-label {
    display: block;
    font-size: 14px;
    margin-bottom: 8px;
    color: #333;
}

.nu-qo-color-picker-label strong {
    font-weight: 700;
}

.nu-qo-swatches {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.nu-qo-swatch {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 2px solid #ddd;
    cursor: pointer;
    padding: 0;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
    position: relative;
}

.nu-qo-swatch:hover {
    border-color: #888;
}

.nu-qo-swatch.active {
    border-color: #ffffff;
    box-shadow: 0 0 0 2px #333;
}

/* White swatch: add subtle border */
.nu-qo-swatch[style*="background-color: #FFFFFF"],
.nu-qo-swatch[style*="background-color: #ffffff"],
.nu-qo-swatch[style*="background-color: #fff"],
.nu-qo-swatch[style*="background-color: white"] {
    border-color: #ccc;
}

#nu-qo-color-name{
    text-transform: uppercase;
}

/* ---------- Dropdown Row ---------- */
.nu-qo-dropdown-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
    display: none !important; /* Hidden by default, shown when colors are available */
}

.nu-qo-dropdown-row label {
    font-size: 14px;
    white-space: nowrap;
    color: #333;
}

.nu-qo-color-select {
    flex: 1;
    padding: 6px 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 14px;
    max-width: 220px;
}

/* ---------- Order Section ---------- */
.nu-qo-order-section {
    margin-bottom: 14px;
}

.nu-qo-order-header {
    background: #f0f4ff;
    padding: 8px 12px;
    border-radius: 4px 4px 0 0;
    font-size: 15px;
    color: #1a1a8e;
    margin-bottom: 0;
}

/* ---------- Sizes Row ---------- */
.nu-qo-sizes-row {
    display: flex;
    gap: 0;
    overflow-x: auto;
    border: 1px solid #ddd;
    border-top: none;
    border-radius: 0 0 4px 4px;
    -webkit-overflow-scrolling: touch;
}

.nu-qo-size-col {
    flex: 1 0 auto;
    min-width: 64px;
    text-align: center;
    padding: 8px 4px 10px;
    border-right: 1px solid #eee;
}

.nu-qo-size-col:last-child {
    border-right: none;
}

.nu-qo-size-label {
    font-weight: 700;
    font-size: 13px;
    color: #333;
    margin-bottom: 6px;
}

.nu-qo-qty-input {
    width: 80px;
    padding: 5px 3px;
    text-align: center;
    border: 1px solid #ccc;
    border-radius: 3px !important;
    font-size: 14px;
    -moz-appearance: textfield;
}

.nu-qo-qty-input::-webkit-outer-spin-button,
.nu-qo-qty-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.nu-qo-qty-input:disabled {
    background: #f0f0f0;
    color: #999;
    cursor: not-allowed;
}

.nu-qo-size-col-unavailable {
    background: #fafafa;
}

.nu-qo-unavailable-text {
    display: block;
    font-size: 10px;
    color: #e73939;
    text-align: center;
    padding: 4px 2px;
    line-height: 1.3;
    margin-top: 20px;
}

.nu-qo-size-price {
    display: flex;
    flex-direction: column;
    align-items: center;
    font-size: 13px;
    font-weight: 700;
    color: #e90a9b;
    margin-top: 4px;
    line-height: 1.3;
}

.nu-qo-price-original {
    text-decoration: line-through;
    color: #d33838;
    font-size: 11px;
    font-weight: 400;
}

.nu-qo-price-current {
    font-size: 13px;
    font-weight: 700;
    color: #e90a9b;
}

.nu-qo-price-current.tier-active {
    color: #220618;
}

.nu-qo-tier-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 12px;
    height: 12px;
    background: #555;
    color: #fff;
    border-radius: 50%;
    font-size: 8px;
    font-weight: bold;
    cursor: help;
    line-height: 1;
    margin-top: 2px;
    flex-shrink: 0;
}

.nu-qo-stock {
    display: block;
    font-size: 10px;
    margin-top: 2px;
    line-height: 1.2;
}

.nu-qo-in-stock {
    color: #007a00;
}

.nu-qo-out-of-stock {
    color: #e90a9b;
}

.nu-qo-backorder {
    color: #cc8800;
}

.nu-qo-no-sizes {
    padding: 12px;
    color: #666;
    font-style: italic;
}

/* ---------- Bulk Link ---------- */
.nu-qo-bulk-link {
    font-size: 13px;
    margin-bottom: 14px;
    color: #333;
}

.nu-qo-bulk-link a {
    color: #e90a9b;
    font-weight: 600;
    text-decoration: underline;
}

.nu-qo-bulk-link a:hover {
    color: #c4087f;
}

/* ---------- Bulk Pricing Note ---------- */
.nu-qo-bulk-pricing-note {
    position: relative;
    margin: 10px 0 14px;
    padding: 10px 14px 10px 14px;
    background: linear-gradient(90deg, #fff0f8 0%, #ffffff 100%);
    border: 1px solid #f8c7e3;
    border-left: 4px solid #e90a9b;
    border-radius: 6px;
    font-size: 13px;
    line-height: 1.4;
    color: #3a3a3a;
    letter-spacing: 0.2px;
}

.nu-qo-bulk-pricing-note strong {
    display: block;
    font-weight: 700;
    color: #9c0466;
}

.nu-qo-bulk-pricing-note::before {
    content: '';
    position: absolute;
    top: 50%;
    left: -7px;
    width: 10px;
    height: 10px;
    transform: translateY(-50%) rotate(45deg);
    background: #e90a9b;
    border-radius: 2px;
    display: none;
}

/* ---------- Order Summary ---------- */
.nu-qo-order-summary {
    background: #f7f7f9;
    border: 1px solid #e4e4ea;
    border-radius: 6px;
    padding: 10px 14px;
    margin-bottom: 12px;
}

.nu-qo-order-summary-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    font-size: 14px;
    color: #444;
}

.nu-qo-order-summary-row + .nu-qo-order-summary-row {
    margin-top: 4px;
    padding-top: 6px;
    border-top: 1px dashed #d9d9e0;
}

.nu-qo-order-summary-label {
    font-weight: 600;
    letter-spacing: 0.3px;
    text-transform: uppercase;
    font-size: 12px;
    color: #555;
}

.nu-qo-order-summary-total {
    font-size: 20px;
    font-weight: 700;
    color: #e90a9b;
}

.nu-qo-order-summary-qty {
    font-size: 16px;
    font-weight: 600;
    color: #222;
}

/* ---------- Add to Cart Button ---------- */
.nu-qo-add-to-cart-btn {
    display: block;
    width: 100%;
    padding: 14px 20px;
    background: #e90a9b;
    color: #fff;
    border: none;
    border-radius: 4px;
    font-size: 18px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 0.2s;
    position: relative;
}

.nu-qo-add-to-cart-btn:hover {
    background: #c4087f;
}

.nu-qo-add-to-cart-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.nu-qo-add-to-cart-btn.loading {
    color: transparent;
}

.nu-qo-add-to-cart-btn.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 22px;
    height: 22px;
    margin: -11px 0 0 -11px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: nu-qo-spin 0.6s linear infinite;
}

@keyframes nu-qo-spin {
    to { transform: rotate(360deg); }
}

/* ---------- Loading skeleton (shown while AJAX fetches variation data) ---------- */
.nu-qo-loading {
    padding: 20px 10px;
    text-align: center;
    color: #999;
    font-size: 13px;
    letter-spacing: 0.02em;
}
.nu-qo-loading .nu-qo-spinner {
    display: inline-block;
    vertical-align: middle;
    width: 14px;
    height: 14px;
    margin-right: 6px;
    border: 2px solid #ddd;
    border-top-color: #e90a9b;
    border-radius: 50%;
    animation: nu-qo-spin 0.7s linear infinite;
    /* override the add-to-cart button spinner styles */
    position: static;
    margin-top: 0;
    margin-left: 0;
    background: none;
}

/* ---------- Message ---------- */
.nu-qo-message {
    margin-top: 10px;
    padding: 10px 14px;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
}

.nu-qo-msg-success {
    background: #e6f9e6;
    color: #007a00;
    border: 1px solid #b3e6b3;
}

.nu-qo-msg-error {
    background: #fde8e8;
    color: #e90a9b;
    border: 1px solid #f5c6c6;
}

/* ---------- Top Savings Summary (above color picker) ---------- */
.nu-qo-savings-top {
    display: flex;
    align-items: stretch;
    border: 1px solid #ddd;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 20px;
    background: #fff;
}

.nu-qo-savings-top.nu-qo-savings-scroll {
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
}

.nu-qo-savings-top.nu-qo-savings-scroll .nu-qo-savings-top-box {
    flex: 0 0 130px;
    min-width: 130px;
}

.nu-qo-savings-top-label {
    background: #1b5fc4;
    color: #fff;
    padding: 20px 24px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-width: 155px;
    text-align: center;
    gap: 3px;
    flex: 0 0 auto;
}

.nu-qo-savings-top-label strong {
    font-size: 15px;
    font-weight: 800;
    letter-spacing: 0.5px;
    line-height: 1.2;
    display: block;
}

.nu-qo-savings-top-label span {
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.3px;
}

.nu-qo-savings-top-box {
    flex: 1 1 0;
    min-width: 0;
    background: #fef9e7;
    border-left: 1px solid #e8dfc8;
    padding: 14px 10px 12px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
}

.nu-qo-savings-top-tier {
    font-size: 12px;
    font-weight: 700;
    color: #1b5fc4;
    line-height: 1.2;
    margin-bottom: 2px;
    white-space: nowrap;
}

.nu-qo-savings-top-starting {
    font-size: 11px;
    color: #000;
}

.nu-qo-savings-top-price {
    font-size: 28px;
    font-weight: 800;
    color: #d63384;
    line-height: 1.1;
    white-space: nowrap;
}

.nu-qo-savings-top-retail {
    font-size: 11px;
    color: #000;
    margin-top: 2px;
    line-height: 1.6;
    white-space: nowrap;
}

.nu-qo-savings-top-retail span {
    display: block;
    text-decoration: line-through;
    font-size: 12px;
}

.nu-qo-savings-top-badge {
    background: #d63384;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 3px;
    margin-top: 5px;
    display: inline-block;
    white-space: nowrap;
}

@media (max-width: 600px) {
    .nu-qo-savings-top { flex-wrap: wrap; }
    .nu-qo-savings-top-label { min-width: 100%; padding: 14px; }
    .nu-qo-savings-top-box { min-width: 30%; }
    .nu-qo-savings-top-price { font-size: 22px; }
}


/* Retail price column — strikethrough in bulk chart */
.nu-qo-bulk-chart-table .nu-qo-bulk-retail {
    text-align: left;
    font-weight: 700;
    background: linear-gradient(to bottom, #fdf0f9, #fce4f6);
    color: #d63384;
}

/* Tier price columns — dark, no color change */
.nu-qo-bulk-chart-table .nu-qo-bulk-tier-price {
    font-weight: 600;
    color: #222;
}

/* ---------- Bulk Pricing Chart ---------- */
.nu-qo-bulk-chart {
    margin-top: 24px;
    border: 1px solid #e8e8e8;
    border-radius: 6px;
    overflow: hidden;
    background: #fff;
}

.nu-qo-bulk-chart-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px 12px;
    border-bottom: 1px solid #e0e0e0;
    background: #fff;
}

.nu-qo-bulk-chart-title {
    font-size: 16px;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0;
    padding: 0;
    letter-spacing: 0;
}

.nu-qo-bulk-chart-color-info {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
}

.nu-qo-bulk-chart-color-label {
    font-size: 10px;
    font-weight: 700;
    color: #000;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.nu-qo-bulk-chart-color-display {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nu-qo-bulk-color-name {
    font-size: 13px;
    font-weight: 600;
    color: #333;
    text-transform: capitalize;
}

.nu-qo-bulk-color-swatch {
    display: inline-block;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    border: 2px solid #ddd;
    flex-shrink: 0;
    box-shadow: 0 1px 3px rgba(0,0,0,0.12);
}

.nu-qo-bulk-chart-table-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.nu-qo-bulk-chart-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
    min-width: 420px;
}

.nu-qo-bulk-chart-table thead tr:first-child th {
    padding: 0;
}

.nu-qo-bulk-th-empty {
    background: #fff;
    border-right: 1px solid #e0e0e0;
}

.nu-qo-bulk-th-discount {
    background: #fde8f6;
    color: #d63384;
    font-weight: 700;
    font-size: 11px;
    letter-spacing: 0.04em;
    text-align: center;
    padding: 5px 8px;
    border-bottom: 1px solid #f4b8e2;
}

.nu-qo-bulk-chart-table thead tr:last-child th {
    padding: 6px 8px;
    text-align: center;
    font-weight: 700;
    font-size: 12px;
    color: #333;
    border-bottom: 2px solid #e0e0e0;
    background: #f9f9f9;
    white-space: nowrap;
}

.nu-qo-bulk-chart-table thead tr:last-child th:first-child,
.nu-qo-bulk-chart-table thead tr:last-child th:nth-child(2) {
    text-align: left;
}

.nu-qo-bulk-tier-head {
    color: #1a3a8a !important;
}

/* Price column header — pink to match body gradient */
.nu-qo-bulk-chart-table thead tr:last-child th:nth-child(2) {
    background: linear-gradient(to bottom, #fdf0f9, #fce4f6);
    color: #d63384;
}

.nu-qo-bulk-chart-table tbody tr {
    border-bottom: 1px solid #efefef;
}

.nu-qo-bulk-chart-table tbody tr:last-child {
    border-bottom: none;
}

.nu-qo-bulk-chart-table tbody tr:nth-child(even) {
    background: #f7f9ff;
}

.nu-qo-bulk-chart-table tbody td {
    padding: 6px 8px;
    text-align: center;
    color: #333;
    font-size: 13px;
}

.nu-qo-bulk-chart-table tbody td:first-child {
    text-align: left;
    font-weight: 600;
    color: #1a1a1a;
}

.nu-qo-bulk-chart-table tbody td:nth-child(2) {
    text-align: left;
    color: #444;
}

/* ---------- Responsive ---------- */
@media (max-width: 768px) {
    .nu-quick-order-top {
        padding: 0;
    }

    .nu-qo-swatches {
        gap: 5px;
    }

    .nu-qo-swatch {
        width: 24px;
        height: 24px;
    }

    .nu-qo-sizes-row {
        gap: 0;
    }

    .nu-qo-size-col {
        min-width: 56px;
        padding: 6px 3px 8px;
    }

    .nu-qo-qty-input {
        font-size: 13px;
    }

    .nu-qo-add-to-cart-btn {
        font-size: 16px;
        padding: 12px 16px;
    }
}

@media (max-width: 480px) {
    .nu-qo-dropdown-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }

    .nu-qo-color-select {
        max-width: 100%;
        width: 100%;
    }

    .nu-qo-size-col {
        min-width: 50px;
    }

    .nu-qo-qty-input {
        padding: 4px 2px;
    }
}
