            /* Custom styles for the part search page that are compatible with the main site theme */

/* Search page specific masthead styling */
.service-page-masthead {
    padding-top: 2rem !important;
    padding-bottom: 1rem !important;
    max-height: 200px !important;
    background: linear-gradient(to right, rgba(33, 37, 41, 0.95), rgba(33, 37, 41, 0.7)), url("../assets/img/header-bg.jpg");
    background-size: cover;
    background-position: center;
    color: white;
}

/* Accent styling for page heading - VERTICAL bar on left */
.page-heading {
    position: relative;
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    padding-left: 1rem;
    border-left: 4px solid #ffc800;
}

/* Remove the horizontal bar */
.page-heading::after {
    display: none;
}

.highlight-badge {
    display: inline-block;
    background-color: #ffc800;
    color: #212529;
    font-weight: 700;
    font-size: 0.8rem;
    padding: 0.35rem 0.75rem;
    margin-bottom: 0.5rem;
    border-radius: 3px;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

/* Enterprise styling for the search section */
.search-container {
    background: white;
    border-radius: 8px;
    padding: 1.75rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    margin-bottom: 2rem;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.search-input-group {
    display: flex;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.1);
    border-radius: 6px;
    overflow: hidden;
    width: 100%;
}

.search-input-group input {
    border: 1px solid #e0e0e0;
    border-right: none;
    padding: 0.85rem 1.2rem;
    font-size: 1rem;
    border-top-left-radius: 6px;
    border-bottom-left-radius: 6px;
    flex-grow: 1;
}

.search-input-group input:focus {
    box-shadow: none;
    border-color: #ffc800;
}

#searchButton {
    background-color: #ffc800;
    border-color: #ffc800;
    color: #212529;
    border: none;
    padding: 0.85rem 1.5rem;
    font-weight: 500;
    border-top-right-radius: 6px;
    border-bottom-right-radius: 6px;
    transition: all 0.2s;
}

#searchButton:hover {
    background-color: #e6b400;
    border-color: #e6b400;
    box-shadow: 0 2px 5px rgba(230, 180, 0, 0.3);
}

/* Search term badge styling */
#searchTermBadge {
    margin-bottom: 1.25rem;
}

#searchTermBadge .badge {
    font-size: 0.9rem;
    padding: 0.5rem 0.85rem;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    border-radius: 4px;
}

/* Filter options styling */
.form-check-inline {
    margin-right: 1.2rem;
}

.form-check-input:checked {
    background-color: #ffc800;
    border-color: #ffc800;
}

.form-check-label {
    font-weight: 500;
    color: #495057;
}

/* Compact and improved styling for tables */
.results-table {
    font-size: 0.9rem; /* Slightly smaller font size for better fit */
    table-layout: fixed; /* Fixed layout for better column width control */
    width: 100%;
}

/* Add word-wrap for table cells so text doesn't overflow */
.results-table td,
.results-table th {
    word-wrap: break-word;
    vertical-align: middle;
    padding: 0.6rem; /* Reduced padding for more compact view */
}

/* Adjust column widths for better space utilization */
.results-table th:nth-child(1), /* Part Number */
.results-table td:nth-child(1) {
    width: 12%;
}

.results-table th:nth-child(2), /* Description */
.results-table td:nth-child(2) {
    width: 22%;
    white-space: normal;
}

.results-table th:nth-child(3), /* Serial Number */
.results-table td:nth-child(3) {
    width: 10%;
}

.results-table th:nth-child(4), /* Tag */
.results-table td:nth-child(4) {
    width: 18%;
    white-space: normal;
}

.results-table th:nth-child(5), /* Condition */
.results-table td:nth-child(5) {
    width: 10%;
}

.results-table th:nth-child(6), /* QTY */
.results-table td:nth-child(6) {
    width: 6%;
}

.results-table th:nth-child(7), /* Tag Date */
.results-table td:nth-child(7) {
    width: 10%;
}

.results-table th:nth-child(8), /* Actions */
.results-table td:nth-child(8) {
    width: 12%;
    text-align: center;
}

/* Improved styling for quantity input in tables */
.qty-input {
    width: 50px;
    height: 32px;
    text-align: center;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    padding: 2px 5px;
    transition: border-color 0.2s;
}

.qty-input:focus {
    border-color: #ffc800;
    box-shadow: 0 0 0 0.15rem rgba(255, 200, 0, 0.25);
    outline: none;
}

/* Style for cart quantity inputs */
.cart-qty-input {
    background-color: #f8f9fa;
}

/* Improved buttons in table */
.results-table .btn {
    padding: 0.25rem 0.5rem;
    font-size: 0.8rem;
    margin: 0.1rem;
    min-width: 32px;
}

/* Improved details button */
.btn-details {
    background-color: #ffc800;
    border-color: #ffc800;
    color: #212529;
    transition: all 0.2s;
}

.btn-details:hover {
    background-color: #e6b400;
    border-color: #e6b400;
    color: #212529;
}

/* Better badge styling */
.badge {
    font-weight: 500;
    letter-spacing: 0.02em;
    padding: 0.35em 0.65em;
    display: inline-block;
    text-align: center;
    white-space: nowrap;
    vertical-align: baseline;
    border-radius: 0.25rem;
    transition: all 0.2s ease;
}

/* Exact Contact Form Styles from index.html */
#rfqForm .form-control {
    padding: 1.25rem;
    font-family: "Roboto Slab", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
    font-size: 1.125rem;
    border-radius: 0.5rem;
}

#rfqForm .form-group-textarea textarea {
    height: 100%;
    min-height: 10rem;
}

#rfqForm .btn-primary {
    background-color: #ffc800;
    border-color: #ffc800;
    color: #212529;
    font-family: "Montserrat", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
    font-size: 1.125rem;
    font-weight: 700;
    padding: 1.25rem 2rem;
}

#rfqForm .btn-xl {
    padding: 1.25rem 2.5rem;
    font-size: 1.125rem;
    font-weight: 700;
}

#rfqForm .text-uppercase {
    text-transform: uppercase !important;
}

#rfqForm .form-check-input {
    width: 1.25rem;
    height: 1.25rem;
    margin-top: 0.25rem;
}

#rfqForm .form-check-label {
    margin-left: 0.5rem;
}

.bg-dark {
    background-color: #212529 !important;
}

.text-white {
    color: #fff !important;
}

.bg-gold {
    background-color: #ffc800;
}

.g-recaptcha {
    display: inline-block;
}

/* Enterprise Form Styling - KISS version */
.enterprise-form label {
    font-weight: 500;
}

.enterprise-form .form-control {
    border: 1px solid #ced4da;
    border-radius: 4px;
}

.enterprise-form .form-control:focus {
    border-color: #d3af37;
    box-shadow: 0 0 0 0.15rem rgba(211, 175, 55, 0.25);
}

/* Contact Form Styles - Exact match with index.html */
.section-heading {
    font-size: 2.5rem;
    margin-top: 0;
    margin-bottom: 1rem;
}

.section-subheading {
    font-size: 1.25rem;
    font-weight: 400;
    font-style: italic;
    margin-bottom: 3rem;
}

.bg-primary {
    background-color: #0077cc !important;
}

.bg-dark {
    background-color: #212529 !important;
}

.text-white {
    color: #fff !important;
}

/* Modal styling */
.modal-content {
    background-color: #f9f9f9;
    border: none;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

.modal-body {
    background-color: #ffffff;
}

/* CAPTCHA styling */
.g-recaptcha {
    margin: 0 auto;
    max-width: 100%;
    overflow: hidden;
}

@media (max-width: 302px) {
    .g-recaptcha {
        transform: scale(0.85);
        transform-origin: left center;
    }
}

/* Enhanced toast notifications */
.toast-container {
    position: fixed;
    bottom: 1rem;
    right: 1rem;
    z-index: 1090;
}

.toast {
    background-color: #fff;
    border: none;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
    border-radius: 0.25rem;
    max-width: 350px;
}

.toast-header {
    border-bottom: none;
    padding: 0.75rem 1rem;
}

.toast-body {
    padding: 0.75rem 1rem;
}

/* Mobile responsiveness improvements */
@media (max-width: 767.98px) {
    .results-table {
        font-size: 0.8rem;
    }
    
    .results-table td,
    .results-table th {
        padding: 0.4rem;
    }
    
    .qty-input {
        width: 40px;
        height: 28px;
    }
    
    .btn-sm {
        padding: 0.2rem 0.4rem;
        font-size: 0.75rem;
    }
    
    #rfqForm {
        padding: 1rem;
    }
    
    .modal-dialog {
        margin: 0.5rem;
    }
}

/* Improved empty state styling */
.empty-cart-message {
    padding: 2rem 1rem;
    text-align: center;
}

.empty-cart-message i {
    font-size: 3rem;
    color: #e9ecef;
    margin-bottom: 1rem;
}

/* Enhanced results table styling */
.card {
    border: none;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    border-radius: 8px;
    margin-bottom: 2rem;
}

.card-header {
    background-color: #f8f9fa;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    font-weight: 600;
    padding: 1rem 1.25rem;
    font-size: 1.1rem;
    color: #343a40;
}

.card-header i {
    color: #ffc800;
}

.table {
    margin-bottom: 0;
}

.table th {
    font-weight: 600;
    color: #495057;
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.5px;
    border-bottom-width: 1px;
    padding: 1rem;
    background-color: #f8f9fa;
}

.table td {
    padding: 0.85rem 1rem;
    vertical-align: middle;
}

.results-table th {
    position: sticky;
    top: 0;
    background-color: #f8f9fa;
    z-index: 1;
}

.results-table tbody tr:hover {
    background-color: rgba(255, 200, 0, 0.05);
}

/* Utility buttons */
.utility-btn {
    border-radius: 4px;
    padding: 0.5rem 0.85rem;
    font-size: 0.85rem;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    transition: all 0.2s;
    background-color: white;
}

.utility-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 3px 6px rgba(0,0,0,0.15);
}

.btn-outline-secondary:hover {
    border-color: #6c757d;
}

.btn-outline-success:hover {
    border-color: #198754;
}

.action-buttons {
    display: flex;
    gap: 0.7rem;
    margin-top: 0.75rem;
    justify-content: flex-end;
}

.action-buttons .btn {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-weight: 500;
}

/* Add to RFQ button styling */
.btn-primary.btn-sm {
    background-color: #ffc800;
    border-color: #ffc800;
    color: #212529;
    font-weight: 500;
    padding: 0.35rem 0.75rem;
    transition: all 0.2s;
}

.btn-primary.btn-sm:hover {
    background-color: #e6b400;
    border-color: #e6b400;
    transform: translateY(-1px);
    box-shadow: 0 2px 5px rgba(230, 180, 0, 0.3);
}

/* RFQ Cart button styling */
#rfqCartBtn {
    background-color: white;
    color: #212529;
    border: 1px solid #e0e0e0;
    transition: all 0.2s;
    font-weight: 500;
}

#rfqCartBtn:hover {
    border-color: #ffc800;
    background-color: rgba(255, 200, 0, 0.05);
}

#rfqCartBtn .badge {
    background-color: #ffc800;
    color: #212529;
    transition: all 0.2s;
}

/* Loading spinner styling */
#loadingSpinner {
    padding: 3rem 0;
}

#loadingSpinner .spinner-border {
    width: 3rem;
    height: 3rem;
    color: #ffc800;
}

/* No results message styling */
#noResults {
    border-left: 4px solid #ffc800;
    font-weight: 500;
}

/* RFQ Success Message */
.rfq-success-message {
    background-color: #28a745;
    color: white;
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    display: none;
}

.rfq-success-message i {
    margin-right: 10px;
}

/* Part details modal styling */
.part-details-content h4 {
    color: #212529;
    font-weight: 600;
}

.spec-item {
    transition: all 0.2s;
    height: 100%;
}

.spec-item:hover {
    border-color: #ffc800 !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.spec-item .small {
    color: #6c757d;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-size: 0.7rem;
}

/* Toast notification styling */
.toast-container {
    z-index: 1070;
}

.toast {
    opacity: 0.95;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    border: none;
    border-radius: 0.25rem;
    max-width: 350px;
}

/* Enhanced table styling for better readability */
.table-striped>tbody>tr:nth-of-type(odd) {
    background-color: rgba(0, 0, 0, 0.02);
}

.table-hover>tbody>tr:hover {
    background-color: rgba(255, 200, 0, 0.05);
}

/* Truncate long text in table cells */
.results-table td {
    max-width: 250px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Description can be a bit longer */
.results-table td:nth-child(2) {
    max-width: 300px;
}

/* Styles for linked part numbers */
.results-table a.text-primary {
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s;
}

.results-table a.text-primary:hover {
    color: #ffc800 !important;
    text-decoration: underline;
}

/* Mobile responsiveness */
@media (max-width: 767.98px) {
    .search-input-group {
        flex-direction: column;
        box-shadow: none;
    }
    
    .search-input-group input {
        border-right: 1px solid #e0e0e0;
        border-bottom: none;
        border-radius: 6px 6px 0 0;
    }
    
    .search-input-group button {
        border-radius: 0 0 6px 6px;
    }
    
    .form-check-inline {
        display: block;
        margin-bottom: 0.5rem;
    }
    
    .card-header {
        padding: 0.85rem 1rem;
    }
    
    .table th, .table td {
        padding: 0.75rem;
    }
    
    .action-buttons {
        flex-wrap: wrap;
        justify-content: flex-start;
    }
}

@media (max-width: 767.98px) {
    #resultsTable th:nth-child(3),
    #resultsTable td:nth-child(3),
    #resultsTable th:nth-child(4),
    #resultsTable td:nth-child(4),
    #resultsTable th:nth-child(7),
    #resultsTable td:nth-child(7) {
        display: none;
    }
    
    .card-header {
        padding: 0.75rem;
    }
    
    .card-body {
        padding: 0;
    }
}

/* Ensure the RFQ cart button fits */
#rfqCartBtn {
    white-space: nowrap;
    padding: 0.375rem 0.5rem;
}

/* Make modal content fit better */
.modal-body {
    padding: 1rem;
    max-height: 75vh;
    overflow-y: auto;
}

/* Fix table width on small screens */
.table-responsive {
    width: 100%;
    overflow-x: auto;
}

/* Additional Cart Styling */
.cart-container {
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    border-radius: 0.5rem;
    overflow: hidden;
}

.cart-header {
    background-color: #f8f9fa;
    border-bottom: 1px solid #e9ecef;
    padding: 1rem 1.5rem;
}

.cart-body {
    padding: 1.5rem;
}

.cart-footer {
    background-color: #f8f9fa;
    border-top: 1px solid #e9ecef;
    padding: 1rem 1.5rem;
}

.cart-empty-state {
    padding: 3rem 1.5rem;
    text-align: center;
}

.cart-empty-icon {
    font-size: 3rem;
    color: #dee2e6;
    margin-bottom: 1rem;
}

.cart-table {
    border-radius: 0.25rem;
    overflow: hidden;
}

.cart-table thead th {
    background-color: #f8f9fa;
    border-bottom: 2px solid #dee2e6;
    font-weight: 600;
    color: #495057;
}

.cart-table tbody tr {
    transition: background-color 0.2s ease;
}

.cart-table tbody tr:hover {
    background-color: #f8f9fa;
}

.cart-item-highlight {
    animation: highlightFade 2s ease-out;
}

@keyframes highlightFade {
    0% { background-color: rgba(40, 167, 69, 0.2); }
    100% { background-color: transparent; }
}

.quantity-control {
    max-width: 120px;
}

.quantity-control .form-control {
    text-align: center;
    padding-left: 0.25rem;
    padding-right: 0.25rem;
}

.quantity-control .btn {
    border-color: #ced4da;
}

.cart-stats {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.875rem;
    color: #6c757d;
    padding: 0.5rem 0;
}

.cart-total {
    font-weight: 600;
    font-size: 1rem;
    color: #212529;
}

.cart-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.cart-actions .btn {
    padding: 0.375rem 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.375rem;
}

.notes-indicator {
    color: #6c757d;
    font-size: 0.75rem;
    margin-left: 0.25rem;
}

.badge-gold {
    background-color: #d4af37;
    color: #fff;
}

.btn-gold {
    background-color: #d4af37;
    border-color: #d4af37;
    color: #fff;
}

.btn-gold:hover, .btn-gold:focus {
    background-color: #c5a02f;
    border-color: #c5a02f;
    color: #fff;
}

.btn-outline-gold {
    color: #d4af37;
    border-color: #d4af37;
}

.btn-outline-gold:hover, .btn-outline-gold:focus {
    background-color: #d4af37;
    color: #fff;
}

.bg-gold {
    background-color: #d4af37 !important;
}

.text-gold {
    color: #d4af37 !important;
}

/* Saved cart item styles */
.saved-cart-item {
    border-left: 3px solid transparent;
    transition: border-color 0.2s ease;
}

.saved-cart-item:hover {
    border-left-color: #d4af37;
}

.saved-cart-item .saved-cart-name {
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.saved-cart-item .saved-cart-meta {
    font-size: 0.75rem;
    color: #6c757d;
}

/* Toast enhancements */
.toast {
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
    border: none;
}

.toast-container {
    z-index: 1060;
}

/* Responsive adjustments */
@media (max-width: 767.98px) {
    .cart-table thead {
        display: none;
    }
    
    .cart-table tbody tr {
        display: block;
        border-bottom: 1px solid #dee2e6;
        padding: 0.5rem 0;
    }
    
    .cart-table tbody td {
        display: flex;
        justify-content: space-between;
        align-items: center;
        border: none;
        padding: 0.25rem 0.5rem;
    }
    
    .cart-table tbody td:before {
        content: attr(data-label);
        font-weight: 600;
        margin-right: 0.5rem;
    }
    
    .cart-table tbody td:last-child {
        border-bottom: none;
    }
    
    .quantity-control {
        max-width: 100%;
    }
    
    .cart-actions {
        flex-direction: column;
    }
    
    .cart-actions .btn {
        width: 100%;
    }
}

/* Print-friendly styling */
@media print {
    .navbar, 
    .footer,
    .action-buttons,
    .no-print,
    .btn,
    #searchForm,
    #rfqCartBtn {
        display: none !important;
    }
    
    .card {
        border: 1px solid #dee2e6 !important;
        box-shadow: none !important;
    }
    
    .card-header {
        background-color: #f8f9fa !important;
        color: #000 !important;
        border-bottom: 1px solid #dee2e6 !important;
    }
    
    .table th {
        background-color: #f8f9fa !important;
        color: #000 !important;
    }
    
    .table td, .table th {
        padding: 0.5rem !important;
    }
    
    .badge {
        border: 1px solid #dee2e6 !important;
        color: #000 !important;
        background-color: transparent !important;
    }
    
    .container {
        max-width: 100% !important;
        width: 100% !important;
    }
}

/* Ensure all containers have proper visibility settings */
#searchResultsArea {
    position: relative;
}

/* Force the containers to be 100% visible with no animations */
#resultsContainer {
    display: none;
    opacity: 1 !important;
    visibility: visible !important;
}

#noResults {
    display: none;
    opacity: 1 !important;
    visibility: visible !important;
}

#loadingSpinner {
    display: none;
    opacity: 1 !important;
    visibility: visible !important;
}

/* Reset any transitions on the table elements */
.results-table,
.results-table tr,
.results-table td,
.results-table th {
    transition: none !important;
}

/* Ensure modal doesn't interfere */
.modal {
    transition: none !important;
}

/* Ensure no Bootstrap transitions interfere */
.collapsing {
    transition: none !important;
}

/* Ensure all rows are visible */
tbody tr {
    display: table-row !important;
    visibility: visible !important;
    opacity: 1 !important;
}

/* Form adjustments for better spacing */
#searchForm {
    padding: 15px;
    margin-bottom: 1rem;
}

#searchForm .form-group {
    margin-bottom: 0.5rem;
}

/* Make form fields more compact */
#searchForm .form-control {
    padding: 0.375rem 0.5rem;
}

/* Make table more compact */
.results-table th, 
.results-table td {
    padding: 0.5rem 0.75rem;
    white-space: normal;
    word-break: break-word;
}

/* Improve responsive behavior */
@media (max-width: 991.98px) {
    .search-field-group {
        margin-bottom: 0.5rem;
    }
    
    .filter-group {
        display: flex;
        flex-wrap: wrap;
    }
    
    .filter-group .form-check {
        margin-right: 1rem;
    }
    
    .action-buttons .btn {
        margin-bottom: 0.5rem;
    }
}

/* Improve table header styling */
.table th.sortable {
    padding-right: 1.5rem;
    position: relative;
    cursor: pointer;
    white-space: nowrap;
}

.table th.sortable .fa-sort {
    position: absolute;
    right: 0.5rem;
    top: 50%;
    transform: translateY(-50%);
    font-size: 0.75rem;
    opacity: 0.5;
}

/* Improve section margins */
#search-results-section {
    padding: 2rem 0;
}

#search-results-section > .container {
    max-width: 95%;
    margin: 0 auto;
}

/* Ensure table cells don't wrap unnecessarily */
.table td, .table th {
    white-space: nowrap;
    padding: 0.75rem;
}

/* Allow description to wrap */
.table td:nth-child(2) {
    white-space: normal;
    max-width: 250px;
}