.ui-autocomplete {
    max-height: 300px;
    overflow-y: auto;
    overflow-x: hidden;
    z-index: 9999 !important;
}
.ui-menu-item {
    padding: 5px;
}
.ui-menu-item:hover {
    background-color: #f8f9fa;
}

.brand-card {
    transition: all 0.2s ease-in-out;
    border: 1px solid rgba(0,0,0,0.125);
}

.brand-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1) !important;
    border-color: var(--bs-primary)!important;
}

.brand-logo-container {
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.brand-logo {
    max-height: 80px;
    max-width: 100%;
}


.brand-type .brand-type-card {
    transition: all 0.2s ease-in-out;
    border: 1px solid rgba(0,0,0,0.125);
}

.brand-type .brand-type-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1) !important;
    border-color: var(--bs-primary)!important;
}

.brand-type .model-specs {
    width: 100%;
    font-size: 0.9rem;
}

.brand-type .spec-item {
    display: flex;
    align-items: center;
    justify-content: center;
}

.brand-type .view-details-text {
    color: var(--bs-primary);
    font-size: 0.9rem;
    font-weight: 500;
    border-top: 1px solid rgba(0,0,0,0.1);
    padding-top: 0.75rem;
    margin-top: 0.5rem;
    width: 100%;
    display: block;
}

.brand-type .brand-type-card:hover .view-details-text {
    color: var(--bs-primary);
    text-decoration: underline;
}
/* Chat Widget Styles */
#chat-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 300px;
    height: 400px;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
    z-index: 1000;
    display: flex;
    flex-direction: column;
    background-color: white;
    display: none;
}

#chat-header {
    background-color: #4CAF50; /* Match button color - friendly green */
    color: white;
    padding: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: bold;
    font-size: 16px;
}

#chat-messages {
    flex-grow: 1;
    overflow-y: auto;
    padding: 10px;
    display: flex;
    flex-direction: column;
}

.message {
    margin-bottom: 10px;
    max-width: 80%;
    padding: 8px 12px;
    border-radius: 18px;
}

.bot-message {
    align-self: flex-start;
    background-color: #f1f0f0;
}

.user-message {
    align-self: flex-end;
    background-color: #06c;
    color: white;
}

#chat-form {
    display: flex;
    padding: 10px;
    border-top: 1px solid #ddd;
}

#user-input {
    flex-grow: 1;
    border-radius: 20px;
    border: 1px solid #ddd;
    padding: 8px 12px;
    margin-right: 10px;
}

#send-button {
    border-radius: 20px;
    background-color: #4CAF50; /* Match header and button color - friendly green */
    color: white;
    border: none;
    padding: 8px 15px;
    cursor: pointer;
    font-weight: bold;
    transition: background-color 0.2s ease;
}

#send-button:hover {
    background-color: #388E3C; /* Darker green shade on hover */
}

#chat-toggle {
    position: fixed;
    bottom: 20px;
    right: 20px;
    min-width: 170px;
    height: 60px;
    border-radius: 30px;
    background-color: #4CAF50; /* Friendly green */
    color: white;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    z-index: 1001;
    font-size: 20px;
    border: none;
    transition: all 0.3s ease;
    animation: pulse 2s infinite;
    padding: 0 20px;
}

.chat-label {
    margin-left: 10px;
    font-weight: bold;
    font-size: 16px;
}

#chat-toggle:hover {
    transform: scale(1.05);
    box-shadow: 0 7px 20px rgba(0, 0, 0, 0.4);
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(76, 175, 80, 0.4);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(76, 175, 80, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(76, 175, 80, 0);
    }
}

#close-chat {
    background: none;
    border: none;
    color: white;
    font-size: 18px;
    cursor: pointer;
}
/* Breadcrumb styling */
.breadcrumb {
    background-color: #f7f9fc;
    border-radius: 6px;
    padding: 0.6rem 1rem;
    border: 1px solid #e9ecef;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
    font-size: 0.9rem;
  }
  
  .breadcrumb-item + .breadcrumb-item::before {
    content: "›";
    color: #adb5bd;
    font-weight: 500;
    padding: 0 0.5rem;
    font-size: 1.1rem;
    line-height: 0.9;
  }
  
  .breadcrumb-item a {
    color: #4a7eff;
    text-decoration: none;
    transition: color 0.2s;
  }
  
  .breadcrumb-item a:hover {
    color: #2962ff;
    text-decoration: none;
  }
  
  .breadcrumb-item.active {
    color: #6c757d;
    font-weight: 500;
  }
  
  /* Optional: Add a very subtle hover effect to the container */
  .breadcrumb:hover {
    box-shadow: 0 1px 5px rgba(0, 0, 0, 0.05);
  }

/* Sidebar specific styling */
.sidebar .card {
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    border: 1px solid #e0e0e0;
    overflow: hidden;
    transition: all 0.3s ease;
    margin-bottom: 1.5rem;
  }
  
  .sidebar .card:hover {
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
  }
  
  /* Card header styling */
  .sidebar .card-header, .homepage-search .card-header {
    background: linear-gradient(135deg, #4a7eff 0%, #2962ff 100%);
    color: white;
    padding: 12px 16px;
    border-bottom: none;
  }
  
  .sidebar .card-header h5, .homepage-search .card-header h5 {
    font-weight: 600;
    font-size: 1.1rem;
    margin-bottom: 0;
    display: flex;
    align-items: center;
  }
  
  /* Card body styling */
  .sidebar .card-body {
    padding: 16px;
    background-color: #ffffff;
  }
  
  /* Select dropdown styling */
  .sidebar .form-select {
    padding: 10px 12px;
    border-radius: 6px;
    border: 1px solid #d0d0d0;
    background-color: #f7f9fc;
    font-size: 0.95rem;
    cursor: pointer;
    transition: border-color 0.2s, box-shadow 0.2s;
  }
  
  .sidebar .form-select:hover {
    border-color: #a0c0ff;
  }
  
  .sidebar .form-select:focus {
    border-color: #4a7eff;
    box-shadow: 0 0 0 3px rgba(74, 126, 255, 0.15);
    outline: none;
  }
  
  /* Popular models list styling */
  .sidebar .list-group-item {
    border-left: none;
    border-right: none;
    border-top: none;
    padding: 10px 0;
    transition: background-color 0.2s;
  }
  
  .sidebar .list-group-item:first-child {
    border-top: none;
  }
  
  .sidebar .list-group-item:hover {
    background-color: #f7f9fc;
  }
  
  .sidebar .list-group-item a {
    color: #2962ff;
    transition: color 0.2s;
    display: block;
  }
  
  .sidebar .list-group-item a:hover {
    color: #1e40af;
    text-decoration: none !important;
  }
  
  /* Mobile version styling */
  .sidebar-mobile .card {
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    border: 1px solid #e0e0e0;
  }
  
  .sidebar-mobile .card-body {
    padding: 16px;
  }
  
  .sidebar-mobile .form-select {
    padding: 10px 12px;
    border-radius: 6px;
    border: 1px solid #d0d0d0;
    background-color: #f7f9fc;
    transition: border-color 0.2s, box-shadow 0.2s;
  }
  
  .sidebar-mobile .form-select:hover {
    border-color: #a0c0ff;
  }
  
  .sidebar-mobile .form-select:focus {
    border-color: #4a7eff;
    box-shadow: 0 0 0 3px rgba(74, 126, 255, 0.15);
    outline: none;
  }

  .homepage-search .card.bg-light {
    position: relative;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid #e9ecef;
    box-shadow: 0 3px 15px rgba(0, 0, 0, 0.07);
    background: linear-gradient(to bottom, #f8f9fa 0%, #e9ecef 100%);
  }
  
  /* Style enhancements for the search box */
  .homepage-search .input-group-lg .form-control {
    border: 1px solid #ced4da;
    border-radius: 6px 0 0 6px;
    padding: 0.75rem 1rem;
    transition: border-color 0.2s, box-shadow 0.2s;
  }
  
  .homepage-search .input-group-lg .form-control:focus {
    border-color: #4a7eff;
    box-shadow: 0 0 0 3px rgba(74, 126, 255, 0.15);
    outline: none;
    z-index: 1;
  }
  
  .homepage-search .input-group-lg .btn-primary {
    background: linear-gradient(135deg, #4a7eff 0%, #2962ff 100%);
    border: none;
    border-radius: 0 6px 6px 0;
    padding-left: 1.5rem;
    padding-right: 1.5rem;
    font-weight: 500;
    transition: all 0.2s;
  }
  
  .homepage-search .input-group-lg .btn-primary:hover {
    background: linear-gradient(135deg, #3d6ae0 0%, #1e4fd6 100%);
    box-shadow: 0 2px 5px rgba(41, 98, 255, 0.3);
  }
  
  /* Add a subtle shadow to the heading */
  .homepage-search h1.display-5 {
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
  }
  


  
@media (max-width: 767px) {
    .custom-mobile-stack {
        flex-direction: column !important;
    }
    
    .custom-mobile-stack input, 
    .custom-mobile-stack button {
        width: 100% !important;
        border-radius: 0.3rem !important;
        margin-right: 0 !important;
    }
    
    .custom-mobile-stack input {
        margin-bottom: 0.5rem !important;
    }
    
    /* Reset Bootstrap's input-group styling for mobile */
    .custom-mobile-stack.input-group > :not(:first-child):not(.dropdown-menu):not(.valid-tooltip):not(.valid-feedback):not(.invalid-tooltip):not(.invalid-feedback) {
        margin-left: 0 !important;
        border-top-left-radius: 0.3rem !important;
        border-bottom-left-radius: 0.3rem !important;
    }
}

/* ----- Model page UI ----- */
.model-page__title {
    font-size: clamp(1.5rem, 2.5vw, 2rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-bottom: 0.5rem;
}

.model-page__lead {
    font-size: 1.05rem;
    color: #5c6570;
    margin-bottom: 0;
    line-height: 1.6;
}

.model-page__content {
    border: 1px solid #e8ecf1;
    border-radius: 12px;
    box-shadow: 0 4px 24px rgba(15, 23, 42, 0.06);
}

.rr-empty-banner {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
    padding: 1.25rem 1.35rem;
    background: linear-gradient(135deg, #f0f6ff 0%, #f7f9fc 100%);
    border: 1px solid #d6e4ff;
    border-radius: 12px;
    margin-bottom: 0.5rem;
}

.rr-empty-banner__icon {
    flex-shrink: 0;
    width: 2.5rem;
    height: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    border-radius: 50%;
    color: #2962ff;
    font-size: 1.1rem;
    box-shadow: 0 2px 8px rgba(41, 98, 255, 0.12);
}

.rr-empty-banner__title {
    font-size: 1.05rem;
    font-weight: 600;
    color: #1a2332;
    margin: 0 0 0.35rem;
}

.rr-empty-banner__text {
    font-size: 0.95rem;
    color: #5c6570;
    margin: 0 0 1rem;
    line-height: 1.55;
}

.rr-empty-banner__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
}

.rr-cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.65rem 1.1rem;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

.rr-cta-btn:hover {
    transform: translateY(-1px);
    text-decoration: none;
}

.rr-cta-btn--amazon {
    background: #232f3e;
    color: #fff;
    box-shadow: 0 4px 12px rgba(35, 47, 62, 0.25);
}

.rr-cta-btn--amazon:hover {
    background: #131921;
    color: #fff;
}

.rr-cta-btn--ebay {
    background: #3665f3;
    color: #fff;
    box-shadow: 0 4px 12px rgba(54, 101, 243, 0.25);
}

.rr-cta-btn--ebay:hover {
    background: #2450d8;
    color: #fff;
}

.rr-related-models {
    margin-top: 1.5rem;
    padding-top: 1.25rem;
    border-top: 1px solid #e8ecf1;
}

.rr-related-models__title {
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 0.25rem;
    color: #1a2332;
}

.rr-related-models__subtitle {
    font-size: 0.875rem;
    color: #6c757d;
    margin: 0 0 1rem;
}

.rr-related-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.65rem;
}

.rr-related-pill {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    background: #fff;
    border: 1px solid #e0e5eb;
    border-radius: 10px;
    color: #1a2332;
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    line-height: 1.35;
    transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}

.rr-related-pill__arrow {
    color: #adb5bd;
    font-size: 0.75rem;
    transition: transform 0.15s ease, color 0.15s ease;
}

.rr-related-pill:hover {
    border-color: #4a7eff;
    box-shadow: 0 4px 14px rgba(74, 126, 255, 0.12);
    transform: translateY(-2px);
    color: #2962ff;
    text-decoration: none;
}

.rr-related-pill:hover .rr-related-pill__arrow {
    color: #2962ff;
    transform: translateX(3px);
}

.rr-spec-card,
.rr-faq-card {
    border: 1px solid #e8ecf1;
    border-radius: 12px;
    overflow: hidden;
    background: #fff;
}

.rr-spec-card__header,
.rr-faq-card__header {
    padding: 1rem 1.25rem;
    background: #f7f9fc;
    border-bottom: 1px solid #e8ecf1;
}

.rr-spec-card__title,
.rr-faq-card__title {
    font-size: 1.1rem;
    font-weight: 600;
    margin: 0;
    color: #1a2332;
}

.rr-spec-card__subtitle {
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: #6c757d;
    margin: 0 0 0.75rem;
}

.rr-spec-card__body,
.rr-faq-card__body {
    padding: 1.25rem;
}

.rr-spec-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    margin: 0;
}

.rr-spec-grid__row {
    display: contents;
}

.rr-spec-grid__label,
.rr-spec-grid__value {
    margin: 0;
    padding: 0.75rem 0;
    border-bottom: 1px solid #eef1f5;
    font-size: 0.9rem;
}

.rr-spec-grid__label {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    color: #8b95a5;
    padding-right: 1rem;
}

.rr-spec-grid__value {
    color: #1a2332;
    font-weight: 500;
}

.rr-btn-specs-toggle {
    background: linear-gradient(135deg, #4a7eff 0%, #2962ff 100%);
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 0.55rem 1.15rem;
    font-size: 0.9rem;
    font-weight: 600;
    transition: background 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}

.rr-btn-specs-toggle:hover,
.rr-btn-specs-toggle:focus {
    background: linear-gradient(135deg, #3d6ae0 0%, #1e4fd6 100%);
    color: #fff;
    box-shadow: 0 4px 12px rgba(41, 98, 255, 0.3);
}

.rr-btn-specs-toggle[aria-expanded="true"] .fa-chevron-down {
    transform: rotate(180deg);
}

.rr-sidebar-accordion {
    border-radius: 8px;
    overflow: hidden;
}

.rr-sidebar-accordion__header {
    background: linear-gradient(135deg, #4a7eff 0%, #2962ff 100%);
}

.rr-sidebar-accordion__toggle {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    padding: 12px 16px;
    background: transparent;
    border: none;
    color: #fff;
    font-weight: 600;
    font-size: 1rem;
    text-align: left;
    cursor: pointer;
}

.rr-sidebar-accordion__toggle .fa-chevron-down {
    transition: transform 0.2s ease;
    font-size: 0.85rem;
}

.rr-sidebar-accordion__toggle:not(.collapsed) .fa-chevron-down {
    transform: rotate(180deg);
}

.rr-sidebar-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.rr-sidebar-tag {
    display: inline-block;
    padding: 0.35rem 0.65rem;
    background: #f0f4fa;
    border: 1px solid #dde4ee;
    border-radius: 999px;
    font-size: 0.78rem;
    color: #2962ff;
    text-decoration: none;
    line-height: 1.3;
    transition: background 0.15s ease, border-color 0.15s ease;
}

.rr-sidebar-tag:hover {
    background: #e8f0ff;
    border-color: #4a7eff;
    color: #1e4fd6;
    text-decoration: none;
}

.product-results-note {
    font-size: 0.85rem;
    color: #6c757d;
    margin-bottom: 1rem;
}

.ebayresult {
    margin-bottom: 0;
}

.product-list.row {
    margin-left: 0;
    margin-right: 0;
}

.product-card {
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.06);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.product-card:hover {
    transform: translateY(-3px);
    border-color: #cbd5e1;
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.12);
}

.product-card__overlay {
    position: absolute;
    inset: 0;
    z-index: 2;
    cursor: pointer;
}

.product-card__media {
    position: relative;
    height: 210px;
    background: #fff;
    border-bottom: 1px solid #f1f5f9;
    overflow: hidden;
}

.product-card__media img {
    position: absolute;
    top: 50%;
    left: 50%;
    max-width: calc(100% - 20px);
    max-height: calc(100% - 20px);
    transform: translate(-50%, -50%);
    transition: transform 0.25s ease;
}

.product-card:hover .product-card__media img {
    transform: translate(-50%, -50%) scale(1.04);
}

.product-card__no-image {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: #94a3b8;
    font-size: 13px;
    background: #f8fafc;
}

.product-card__body {
    display: flex;
    flex-direction: column;
    flex: 1;
    padding: 14px;
    gap: 10px;
}

.product-card__title {
    margin: 0;
    font-size: 14px;
    line-height: 1.45;
    font-weight: 600;
    color: #1e293b;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    overflow: hidden;
    min-height: 4.35em;
}

.product-card__meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-top: auto;
}

.product-card__price {
    font-size: 22px;
    font-weight: 800;
    line-height: 1;
    color: #15803d;
    letter-spacing: -0.02em;
}

.product-card__merchant {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 8px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
    line-height: 1;
    white-space: nowrap;
    border: 1px solid transparent;
}

.product-card__merchant--amazon {
    color: #111;
    background: #fff7ed;
    border-color: #fed7aa;
}

.product-card__merchant--amazon .fa-amazon {
    font-size: 16px;
    color: #ff9900;
}

.product-card__merchant--ebay {
    color: #fff;
    background: #e53238;
    border-color: #e53238;
    padding: 5px 10px;
}

.product-card__merchant--ebay .fa-ebay {
    font-size: 22px;
    line-height: 1;
}

.product-card__merchant--other {
    color: #334155;
    background: #f1f5f9;
    border-color: #e2e8f0;
}

.product-card__merchant--other .fa-store {
    color: #64748b;
}

.product-card__cta {
    position: relative;
    z-index: 3;
    margin: 0;
    padding: 11px 12px;
    font-size: 14px;
    font-weight: 700;
    border: none;
    border-radius: 8px;
    color: #fff !important;
    text-decoration: none !important;
    transition: background-color 0.2s ease, transform 0.2s ease;
}

.product-card__cta:hover,
.product-card__cta:focus {
    color: #fff !important;
    transform: translateY(-1px);
}

.product-card__cta--amazon {
    background: linear-gradient(180deg, #ffb84d 0%, #ff9900 100%);
}

.product-card__cta--amazon:hover,
.product-card__cta--amazon:focus {
    background: linear-gradient(180deg, #ff9900 0%, #e88b00 100%);
}

.product-card__cta--ebay {
    background: linear-gradient(180deg, #ef5350 0%, #e53238 100%);
}

.product-card__cta--ebay:hover,
.product-card__cta--ebay:focus {
    background: linear-gradient(180deg, #e53238 0%, #c72a2f 100%);
}

.product-card__cta--other {
    background: linear-gradient(180deg, #475569 0%, #334155 100%);
}

.product-card__cta--other:hover,
.product-card__cta--other:focus {
    background: linear-gradient(180deg, #334155 0%, #1e293b 100%);
}

.product-card__cta .fa-arrow-right {
    margin-left: 6px;
    font-size: 12px;
}

@media (max-width: 767px) {
    .product-card__media {
        height: 170px;
    }

    .product-card__title {
        min-height: 0;
        -webkit-line-clamp: 2;
    }

    .product-card__price {
        font-size: 20px;
    }

    .product-card__cta {
        padding: 12px;
        font-size: 15px;
    }
}

@media (max-width: 991px) {
    .rr-related-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .rr-spec-grid {
        grid-template-columns: 1fr;
    }

    .rr-spec-grid__label {
        padding-bottom: 0.15rem;
        border-bottom: none;
    }

    .rr-spec-grid__value {
        padding-top: 0;
        padding-bottom: 0.85rem;
    }
}

@media (max-width: 575px) {
    .rr-related-grid {
        grid-template-columns: 1fr;
    }

    .rr-empty-banner {
        flex-direction: column;
    }

    .rr-empty-banner__actions {
        flex-direction: column;
    }

    .rr-cta-btn {
        justify-content: center;
        width: 100%;
    }
}