/**
 * Quote Request Form Styles
 * QuarkCodeAI B2B Commerce Suite
 */

/* ============================================
   QUOTE REQUEST CONTAINER
   ============================================ */

.qb2b-quote-request-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

/* ============================================
   HEADER SECTION
   ============================================ */

.quote-request-header {
    text-align: center;
    margin-bottom: 50px;
    padding-bottom: 30px;
    border-bottom: 2px solid #e9ecef;
}

.quote-request-header .page-title {
    font-size: 36px;
    font-weight: 700;
    color: #2c3e50;
    margin: 0 0 15px 0;
}

.quote-request-header .page-description {
    font-size: 16px;
    color: #6c757d;
    margin: 0 0 30px 0;
    line-height: 1.6;
}

/* Customer Benefits */
.customer-benefits {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
    margin-top: 25px;
}

.benefit-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 20px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.benefit-icon {
    font-size: 24px;
}

.benefit-text {
    font-size: 14px;
    font-weight: 600;
    color: #2c3e50;
}

/* ============================================
   FORM SECTIONS
   ============================================ */

.qb2b-quote-form {
    background: #fff;
}

.form-section {
    background: #fff;
    border-radius: 12px;
    padding: 35px;
    margin-bottom: 30px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    border: 1px solid #e9ecef;
}

.section-header {
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 2px solid #f1f3f5;
}

.section-header h2 {
    font-size: 24px;
    font-weight: 700;
    color: #2c3e50;
    margin: 0 0 8px 0;
}

.section-description {
    font-size: 14px;
    color: #6c757d;
    margin: 0;
    line-height: 1.5;
}

.section-subheader {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid #e9ecef;
}

.section-subheader h3 {
    font-size: 18px;
    font-weight: 600;
    color: #2c3e50;
    margin: 0;
}

/* ============================================
   FORM GRID & GROUPS
   ============================================ */

.form-grid {
    display: grid;
    gap: 25px;
}

.form-grid.two-columns {
    grid-template-columns: repeat(2, 1fr);
}

.form-grid.three-columns {
    grid-template-columns: repeat(3, 1fr);
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group.full-width {
    grid-column: 1 / -1;
}

.form-group label {
    font-size: 14px;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.form-group label.required::after {
    content: '*';
    color: #dc3545;
    margin-left: 4px;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="tel"],
.form-group input[type="number"],
.form-group input[type="date"],
.form-group select,
.form-group textarea {
    padding: 12px 15px;
    border: 2px solid #dee2e6;
    border-radius: 6px;
    font-size: 14px;
    color: #495057;
    transition: all 0.2s ease;
    background: #fff;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: #2271b1;
    outline: none;
    box-shadow: 0 0 0 4px rgba(34, 113, 177, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
    font-family: inherit;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: #adb5bd;
}

/* ============================================
   PRODUCT SEARCH
   ============================================ */

.product-search-container {
    margin-bottom: 30px;
}

.search-bar {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.search-bar input {
    flex: 1;
    padding: 14px 18px;
    border: 2px solid #dee2e6;
    border-radius: 8px;
    font-size: 15px;
}

.search-bar input:focus {
    border-color: #2271b1;
    outline: none;
    box-shadow: 0 0 0 4px rgba(34, 113, 177, 0.1);
}

.search-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 14px 24px;
    background: #2271b1;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.search-btn:hover {
    background: #135e96;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(34, 113, 177, 0.3);
}

.search-btn .dashicons {
    font-size: 18px;
    width: 18px;
    height: 18px;
}

/* Search Filters */
.search-filters {
    display: flex;
    gap: 15px;
    align-items: center;
    flex-wrap: wrap;
}

.product-filter {
    padding: 10px 15px;
    border: 2px solid #dee2e6;
    border-radius: 6px;
    font-size: 14px;
    background: #fff;
    cursor: pointer;
    transition: all 0.2s;
}

.product-filter:focus {
    border-color: #2271b1;
    outline: none;
}

/* Product Results */
.product-results {
    margin-top: 20px;
    max-height: 400px;
    overflow-y: auto;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    background: #f8f9fa;
}

.product-results:empty {
    display: none;
}

.product-result-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    background: #fff;
    border-bottom: 1px solid #e9ecef;
    transition: all 0.2s;
}

.product-result-item:hover {
    background: #f1f3f5;
}

.product-result-item:last-child {
    border-bottom: none;
}

.product-info {
    flex: 1;
}

.product-name {
    font-size: 15px;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 4px;
}

.product-sku {
    font-size: 13px;
    color: #6c757d;
    margin-right: 15px;
}

.product-price {
    font-size: 14px;
    font-weight: 600;
    color: #2271b1;
}

/* ============================================
   SELECTED PRODUCTS
   ============================================ */

.selected-products-container {
    margin-top: 30px;
}

.selected-products-list {
    min-height: 200px;
}

.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    text-align: center;
    background: #f8f9fa;
    border: 2px dashed #dee2e6;
    border-radius: 8px;
}

.empty-state .dashicons {
    font-size: 48px;
    width: 48px;
    height: 48px;
    color: #adb5bd;
    margin-bottom: 15px;
}

.empty-state p {
    font-size: 15px;
    color: #6c757d;
    margin: 0;
}

.selected-product-item {
    display: grid;
    grid-template-columns: 60px 1fr 100px 120px 100px 50px;
    gap: 20px;
    align-items: center;
    padding: 20px;
    background: #fff;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    margin-bottom: 15px;
    transition: all 0.2s;
}

.selected-product-item:hover {
    border-color: #2271b1;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.product-image {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 6px;
}

.product-details {
    display: flex;
    flex-direction: column;
}

.product-details .name {
    font-size: 15px;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 4px;
}

.product-details .sku {
    font-size: 13px;
    color: #6c757d;
}

.quantity-input {
    width: 100%;
    padding: 10px;
    border: 2px solid #dee2e6;
    border-radius: 6px;
    text-align: center;
    font-size: 15px;
    font-weight: 600;
}

.product-price-display {
    font-size: 16px;
    font-weight: 600;
    color: #2271b1;
    text-align: right;
}

.product-total {
    font-size: 17px;
    font-weight: 700;
    color: #2c3e50;
    text-align: right;
}

.remove-product-btn {
    background: #dc3545;
    color: #fff;
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.remove-product-btn:hover {
    background: #c82333;
    transform: scale(1.1);
}

/* ============================================
   BULK ACTIONS
   ============================================ */

.bulk-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    background: #f8f9fa;
    border-radius: 8px;
    margin-top: 20px;
}

.bulk-quantity-update {
    display: flex;
    align-items: center;
    gap: 10px;
}

.bulk-quantity-update label {
    font-size: 14px;
    font-weight: 600;
    color: #495057;
}

.small-text {
    width: 80px;
    padding: 8px;
    border: 2px solid #dee2e6;
    border-radius: 4px;
    text-align: center;
}

/* ============================================
   FILE UPLOAD
   ============================================ */

.file-upload-area {
    border: 2px dashed #dee2e6;
    border-radius: 8px;
    padding: 40px;
    text-align: center;
    background: #f8f9fa;
    cursor: pointer;
    transition: all 0.2s;
}

.file-upload-area:hover {
    border-color: #2271b1;
    background: #f1f3f5;
}

.file-upload-area .dashicons {
    font-size: 48px;
    width: 48px;
    height: 48px;
    color: #adb5bd;
    margin-bottom: 15px;
}

.file-upload-area p {
    margin: 0;
    color: #6c757d;
}

.file-upload-area input[type="file"] {
    display: none;
}

.uploaded-files {
    margin-top: 15px;
}

.uploaded-file {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 15px;
    background: #fff;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    margin-bottom: 10px;
}

.file-name {
    font-size: 14px;
    color: #495057;
}

.file-size {
    font-size: 12px;
    color: #6c757d;
    margin-left: 10px;
}

.remove-file-btn {
    background: none;
    border: none;
    color: #dc3545;
    cursor: pointer;
    font-size: 18px;
}

/* ============================================
   BUTTONS
   ============================================ */

.button-primary,
.button-secondary,
.button-link {
    padding: 12px 24px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    border: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.button-primary {
    background: #2271b1;
    color: #fff;
}

.button-primary:hover {
    background: #135e96;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(34, 113, 177, 0.3);
}

.button-secondary {
    background: #fff;
    color: #2271b1;
    border: 2px solid #2271b1;
}

.button-secondary:hover {
    background: #2271b1;
    color: #fff;
}

.button-link {
    background: none;
    color: #2271b1;
    padding: 8px 12px;
}

.button-link:hover {
    text-decoration: underline;
}

.button-link.danger {
    color: #dc3545;
}

.button-link.danger:hover {
    color: #c82333;
}

.button .dashicons {
    font-size: 18px;
    width: 18px;
    height: 18px;
}

/* ============================================
   FORM ACTIONS
   ============================================ */

.form-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 30px 35px;
    background: #f8f9fa;
    border-radius: 12px;
    margin-top: 30px;
}

.form-actions-left {
    display: flex;
    gap: 15px;
}

.form-actions-right {
    display: flex;
    gap: 15px;
}

.submit-quote-btn {
    padding: 16px 40px;
    font-size: 16px;
    background: linear-gradient(135deg, #2271b1 0%, #135e96 100%);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 4px 12px rgba(34, 113, 177, 0.3);
}

.submit-quote-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(34, 113, 177, 0.4);
}

.submit-quote-btn:disabled {
    background: #adb5bd;
    cursor: not-allowed;
    transform: none;
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */

@media (max-width: 992px) {
    .form-grid.two-columns,
    .form-grid.three-columns {
        grid-template-columns: 1fr;
    }
    
    .selected-product-item {
        grid-template-columns: 50px 1fr 80px;
        grid-template-rows: auto auto;
        gap: 15px;
    }
    
    .selected-product-item .product-price-display {
        grid-column: 1 / -1;
    }
    
    .selected-product-item .product-total {
        grid-column: 1 / -1;
    }
}

@media (max-width: 768px) {
    .qb2b-quote-request-container {
        padding: 20px 15px;
    }
    
    .form-section {
        padding: 25px 20px;
    }
    
    .quote-request-header .page-title {
        font-size: 28px;
    }
    
    .customer-benefits {
        flex-direction: column;
        gap: 15px;
    }
    
    .search-bar {
        flex-direction: column;
    }
    
    .bulk-actions {
        flex-direction: column;
        gap: 15px;
        align-items: stretch;
    }
    
    .form-actions {
        flex-direction: column;
        gap: 15px;
    }
    
    .form-actions-left,
    .form-actions-right {
        width: 100%;
        justify-content: center;
    }
}

/* ============================================
   LOADING & SUCCESS STATES
   ============================================ */

.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 999999;
}

.loading-content {
    background: #fff;
    padding: 40px;
    border-radius: 12px;
    text-align: center;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #2271b1;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.success-message {
    padding: 20px;
    background: #d4edda;
    border: 2px solid #c3e6cb;
    border-radius: 8px;
    color: #155724;
    margin-bottom: 20px;
}

.error-message {
    padding: 20px;
    background: #f8d7da;
    border: 2px solid #f5c6cb;
    border-radius: 8px;
    color: #721c24;
    margin-bottom: 20px;
}

/* ============================================================================
   QUOTE REQUEST - PRODUCT SELECTION & SELECTED PRODUCTS SECTIONS
   ============================================================================ */

/* Product Selection Section */
.form-section.product-selection {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 25px;
    margin-bottom: 25px;
}

/* Product Search Container */
.product-search-container {
    margin-top: 20px;
}

.search-bar {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
}

.search-bar #product-search {
    flex: 1;
    padding: 12px 15px;
    border: 2px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    transition: all 0.3s ease;
}

.search-bar #product-search:focus {
    border-color: #0073aa;
    outline: none;
    box-shadow: 0 0 0 3px rgba(0, 115, 170, 0.1);
}

.search-btn {
    padding: 12px 24px;
    background: #0073aa;
    color: #fff;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
}

.search-btn:hover {
    background: #005a87;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 115, 170, 0.3);
}

.search-btn .dashicons {
    font-size: 18px;
}

/* Search Filters */
.search-filters {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 20px;
}

.product-filter {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    background: #fff;
    cursor: pointer;
    transition: all 0.2s ease;
    min-width: 150px;
}

.product-filter:focus {
    border-color: #0073aa;
    outline: none;
}

.button-link {
    background: none;
    border: none;
    color: #0073aa;
    cursor: pointer;
    text-decoration: underline;
    font-size: 13px;
    padding: 5px 10px;
}

.button-link:hover {
    color: #005a87;
}

/* Product Search Results */
.product-results {
    min-height: 100px;
    margin-top: 20px;
}

.product-search-results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.product-result-card {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 15px;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    position: relative;
}

.product-result-card:hover {
    border-color: #0073aa;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transform: translateY(-2px);
}

.product-result-card .product-image {
    width: 100%;
    height: 180px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f9f9f9;
    border-radius: 6px;
    margin-bottom: 15px;
    overflow: hidden;
}

.product-result-card .product-image img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.product-result-card .product-info {
    flex: 1;
    margin-bottom: 15px;
}

.product-result-card .product-name {
    font-size: 15px;
    font-weight: 600;
    margin: 0 0 8px 0;
    color: #1e1e1e;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-result-card .product-sku {
    display: block;
    font-size: 12px;
    color: #666;
    margin-bottom: 10px;
}

.product-result-card .product-pricing {
    margin: 10px 0;
}

.product-result-card .regular-price {
    text-decoration: line-through;
    color: #999;
    font-size: 13px;
    margin-right: 8px;
}

.product-result-card .price {
    font-size: 18px;
    font-weight: 700;
    color: #0073aa;
}

.product-result-card .stock-status {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.product-result-card .stock-status.in-stock {
    background: #d4edda;
    color: #155724;
}

.product-result-card .stock-status.out-of-stock {
    background: #f8d7da;
    color: #721c24;
}

.product-result-card .product-actions {
    display: flex;
    gap: 10px;
    align-items: center;
    margin-top: auto;
    padding-top: 15px;
    border-top: 1px solid #f0f0f0;
}

.product-result-card .quantity-input {
    width: 70px;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    text-align: center;
    font-size: 14px;
}

.product-result-card .add-to-quote {
    flex: 1;
    padding: 8px 12px;
    background: #46b450;
    color: #fff;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: all 0.2s ease;
}

.product-result-card .add-to-quote:hover:not(:disabled) {
    background: #3a9940;
    transform: translateY(-1px);
}

.product-result-card .add-to-quote:disabled {
    background: #ccc;
    cursor: not-allowed;
}

.product-result-card .add-to-quote .dashicons {
    font-size: 16px;
}

/* Loading and Empty States */
.product-results .loading,
.product-results .no-results,
.product-results .error {
    text-align: center;
    padding: 40px 20px;
    color: #666;
}

.product-results .loading .spinner {
    float: none;
    margin: 0 auto 15px;
}

.product-results .no-results,
.product-results .error {
    background: #f9f9f9;
    border-radius: 8px;
    border: 1px solid #e0e0e0;
}

.product-results .error {
    background: #fff3cd;
    border-color: #ffc107;
    color: #856404;
}

/* Selected Products Container */
.selected-products-container {
    margin-top: 40px;
    padding: 25px;
    background: #f9f9f9;
    border: 2px dashed #ddd;
    border-radius: 8px;
}

.section-subheader {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #ddd;
}

.section-subheader h3 {
    margin: 0;
    font-size: 18px;
    color: #1e1e1e;
}

#import-cart-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    font-size: 14px;
}

#import-cart-btn .dashicons {
    font-size: 18px;
}

/* Selected Products List */
.selected-products-list {
    min-height: 100px;
}

.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #999;
}

.empty-state .dashicons {
    font-size: 48px;
    width: 48px;
    height: 48px;
    color: #ccc;
    margin-bottom: 15px;
}

.empty-state p {
    margin: 0;
    font-size: 14px;
    line-height: 1.6;
}

/* Selected Product Items */
.selected-product-item {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 15px;
    display: grid;
    grid-template-columns: 80px 1fr auto auto auto;
    gap: 15px;
    align-items: center;
    transition: all 0.2s ease;
}

.selected-product-item:hover {
    border-color: #0073aa;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.selected-product-item .product-thumbnail {
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f9f9f9;
    border-radius: 6px;
    overflow: hidden;
}

.selected-product-item .product-thumbnail img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.selected-product-item .product-details {
    flex: 1;
    margin-left: 20px;
}

.selected-product-item .product-details .product-name {
    font-size: 15px;
    font-weight: 600;
    margin: 0 0 5px 0;
    color: #1e1e1e;
}

.selected-product-item .product-details .product-sku {
    display: block;
    font-size: 12px;
    color: #666;
    margin-bottom: 5px;
}

.selected-product-item .product-details .product-price {
    font-size: 14px;
    font-weight: 700;
    color: #0073aa;
}

.selected-product-item .quantity-controls {
    display: flex;
    align-items: center;
    gap: 8px;
}

.selected-product-item .quantity-controls label {
    font-size: 13px;
    font-weight: 600;
    color: #666;
}

.selected-product-item .quantity-controls .quantity-input {
    width: 80px;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    text-align: center;
    font-size: 14px;
}

.selected-product-item .product-notes {
    min-width: 200px;
}

.selected-product-item .product-note-input {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 13px;
}

.selected-product-item .product-note-input:focus {
    border-color: #0073aa;
    outline: none;
}

.selected-product-item .product-actions .remove-product {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: none;
    background: #dc3232;
    color: #fff;
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.selected-product-item .product-actions .remove-product:hover {
    background: #a00;
    transform: scale(1.1);
}

/* Bulk Actions */
.bulk-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 20px;
    padding: 15px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 6px;
}

.bulk-quantity-update {
    display: flex;
    align-items: center;
    gap: 10px;
}

.bulk-quantity-update label {
    font-size: 14px;
    font-weight: 500;
}

.bulk-quantity-update .small-text {
    width: 80px;
    padding: 6px;
    border: 1px solid #ddd;
    border-radius: 4px;
    text-align: center;
}

#apply-bulk-quantity {
    padding: 6px 16px;
}

.bulk-remove .danger {
    color: #dc3232;
}

.bulk-remove .danger:hover {
    color: #a00;
    text-decoration: underline;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .product-search-results-grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    }
    
    .selected-product-item {
        grid-template-columns: 60px 1fr;
        gap: 10px;
    }
    
    .selected-product-item .quantity-controls,
    .selected-product-item .product-notes {
        grid-column: 1 / -1;
    }
    
    .selected-product-item .product-actions {
        grid-column: 1 / -1;
        justify-content: flex-end;
    }
}

@media (max-width: 768px) {
    .search-bar {
        flex-direction: column;
    }
    
    .search-filters {
        flex-direction: column;
        align-items: stretch;
    }
    
    .product-filter {
        width: 100%;
    }
    
    .product-search-results-grid {
        grid-template-columns: 1fr;
    }
    
    .section-subheader {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }
    
    .bulk-actions {
        flex-direction: column;
        align-items: stretch;
        gap: 15px;
    }
    
    .bulk-quantity-update {
        flex-wrap: wrap;
    }
}

@media (max-width: 480px) {
    .product-result-card .product-image {
        height: 150px;
    }
    
    .selected-product-item {
        grid-template-columns: 1fr;
    }
    
    .selected-product-item .product-thumbnail {
        width: 100%;
        height: 120px;
    }
}

/* Quote Preview Modal */
.quote-preview-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 99999;
    overflow-y: auto;
}

.quote-preview-content {
    background: #fff;
    max-width: 800px;
    margin: 50px auto;
    padding: 0;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.preview-header {
    background: #0073aa;
    color: #fff;
    padding: 20px;
    border-radius: 8px 8px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.preview-header h2 {
    margin: 0;
    color: #fff;
    font-size: 24px;
}

.close-preview {
    background: none;
    border: none;
    color: #fff;
    font-size: 32px;
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    line-height: 1;
}

.preview-section {
    padding: 20px 30px;
    border-bottom: 1px solid #eee;
}

.preview-section:last-child {
    border-bottom: none;
}

.preview-section h3 {
    margin-top: 0;
    margin-bottom: 15px;
    color: #333;
    font-size: 18px;
}

.preview-section p {
    margin: 8px 0;
    line-height: 1.6;
}

.preview-products-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
}

.preview-products-table th,
.preview-products-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

.preview-products-table th {
    background: #f5f5f5;
    font-weight: 600;
}

.preview-actions {
    padding: 20px 30px;
    text-align: right;
    background: #f9f9f9;
    border-radius: 0 0 8px 8px;
}

.preview-actions button {
    margin-left: 10px;
}


/* Saved Drafts Panel */
.saved-drafts-panel {
    background: #f9f9f9;
    border: 1px solid #ddd;
    border-radius: 6px;
    padding: 20px;
    margin-bottom: 30px;
}

.saved-drafts-panel h3 {
    margin-top: 0;
    margin-bottom: 15px;
    color: #333;
    font-size: 18px;
}

.drafts-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.draft-item {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    padding: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.draft-info strong {
    color: #333;
    font-size: 14px;
}

.draft-info small {
    color: #666;
    font-size: 12px;
}

.draft-actions {
    display: flex;
    gap: 8px;
}

.draft-actions button {
    padding: 6px 12px;
    font-size: 13px;
}

.delete-draft-btn {
    background: #dc3545 !important;
    border-color: #dc3545 !important;
    color: #fff !important;
}

.delete-draft-btn:hover {
    background: #c82333 !important;
    border-color: #bd2130 !important;
}
