/* Shared UI/UX polish — typography, a11y, contrast, hub consistency */
:root {
    --tb-ink: #12263a;
    --tb-ink-soft: #24272c;
    --tb-muted: #4b5563;
    --tb-muted-soft: #6b7280;
    --tb-red: #d81416;
    --tb-border: #e8ecf0;
    --tb-bg: #f5f6f8;
    --tb-focus: rgba(216, 20, 22, 0.35);
    --tb-h1: clamp(1.35rem, 2.5vw, 1.85rem);
    --tb-h2: clamp(1.15rem, 2vw, 1.35rem);
    --tb-h3: 1.05rem;
}

/* Skip link */
.tb-skip-link {
    position: absolute;
    left: 12px;
    top: 0;
    z-index: 100000;
    padding: 10px 14px;
    border-radius: 0 0 8px 8px;
    background: var(--tb-red);
    color: #fff !important;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none !important;
    transform: translateY(-120%);
    transition: transform .15s ease;
}

.tb-skip-link:focus,
.tb-skip-link:focus-visible {
    transform: translateY(0);
    outline: 2px solid #fff;
    outline-offset: 2px;
}

/* Focus visibility */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
    outline: 2px solid var(--tb-red);
    outline-offset: 2px;
}

/* Typography scale for hubs */
.dl-page h1,
.bm-page h1,
.emi-page-hero h1,
.listing-page .tb-save-page-header h1,
.tb-compare-result .tb-cr-hero h1 {
    color: var(--tb-ink);
    letter-spacing: -0.02em;
    line-height: 1.25;
}

.dl-page h1,
.bm-page h1,
.emi-page-hero h1,
.listing-page .tb-save-page-header h1 {
    font-size: var(--tb-h1);
    font-weight: 700;
}

.dl-section__title,
.bm-hero h1,
.tb-faq__heading,
.rm-footer__heading {
    font-size: var(--tb-h2);
    font-weight: 700;
    color: var(--tb-ink);
    line-height: 1.35;
}

.tb-home-page .listing-compare-title,
.tb-home-page .listing-brands-title,
.tb-home-page .home-section-title {
    font-size: clamp(1.35rem, 2.4vw, 1.75rem);
    font-weight: 800;
    color: var(--tb-ink);
    letter-spacing: -0.02em;
    line-height: 1.25;
}

.dl-section__body,
.bm-hero__sub,
.home-section-sub,
.tb-save-page-header p,
.tb-cr-desc-body {
    color: var(--tb-muted);
}

/* Contrast: muted text slightly darker */
.home-section-sub,
.listing-compare-sub,
.tb-price-clarity,
.hero-price-meta,
.dl-hero__sub,
.bm-hero__sub,
.dl-locator__hint {
    color: #4b5563 !important;
}

/* Icon-only controls: ensure min touch target */
.tb-wish-btn,
.tb-nav-drawer-toggle,
.tb-nav-drawer-panel__close,
.listing-filter-native-back,
.scroltop {
    min-width: 44px;
    min-height: 44px;
}

/* Used detail — PDP-like CTA/hero polish */
.used-detail-ui .product-content {
    padding: 8px 0 0;
}

.used-detail-ui .product-title {
    font-size: var(--tb-h1);
    font-weight: 700;
    color: var(--tb-ink);
    line-height: 1.3;
    margin: 0 0 10px;
}

.used-detail-ui .product-price {
    color: var(--tb-red);
    font-weight: 700;
}

.used-detail-ui .purchase-info {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 14px;
}

.used-detail-ui .purchase-info .n-Button,
.used-detail-ui .purchase-info .site-button,
.used-detail-ui .purchase-info .btn-primary {
    width: 100%;
    max-width: none;
    min-height: 44px;
    border-radius: 10px;
    font-weight: 700;
}

.used-detail-ui .vehicle-meta-card {
    border: 1px solid var(--tb-border);
    border-radius: 12px;
    box-shadow: 0 1px 4px rgba(36, 39, 44, 0.05);
    background: #fff;
}

.used-detail-ui .btn-bottom-sticky {
    box-shadow: 0 -4px 16px rgba(18, 38, 58, 0.12);
}

/* Brand hub */
.brand-hub-page .breadCrumn {
    background: #fff;
    border-bottom: 1px solid var(--tb-border);
}

.brand-hub-page .listing-card {
    border-radius: 12px;
}

.brand-hub-hero {
    background: linear-gradient(135deg, #fff 0%, #fafbfc 55%, #fff5f5 100%);
    border-bottom: 1px solid var(--tb-border);
    padding: 20px 0 16px;
    margin-bottom: 12px;
}

.brand-hub-hero h1 {
    margin: 0 0 6px;
    font-size: var(--tb-h1);
    font-weight: 700;
    color: var(--tb-ink);
}

.brand-hub-hero p {
    margin: 0;
    max-width: 40rem;
    font-size: 14px;
    line-height: 1.5;
    color: var(--tb-muted);
}

/* Listing mobile filter polish */
.listing-filter-native-sheet {
    border-radius: 16px 16px 0 0 !important;
}

.listing-filter-native-header {
    border-bottom: 1px solid #eef1f4;
}

.listing-filter-native-title {
    font-size: 17px !important;
    font-weight: 700 !important;
    color: var(--tb-ink) !important;
}

.listing-filter-native-footer .listing-btn-apply {
    min-height: 48px;
    border-radius: 12px;
    font-weight: 700;
}

.listing-mobile-sticky-filter,
.listing-mobile-sticky-sort {
    min-height: 44px;
}

/* Compare result polish */
.tb-cr-desc {
    position: relative;
    overflow: hidden;
}

.tb-cr-desc::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(180deg, var(--tb-red) 0%, #f59e0b 100%);
}

.tb-cr-desc-body {
    font-size: 15px;
    line-height: 1.75;
    color: var(--tb-muted);
}

@media (max-width: 767px) {
    .tb-cr-desc {
        padding: 16px 16px 16px 18px;
        margin-top: 14px;
    }

    .tb-cr-desc h2 {
        font-size: 1.05rem;
    }

    .tb-cr-vehicles--mobile .tb-cr-vehicle-name {
        font-size: 13px;
        line-height: 1.35;
    }

    .tb-cr-vehicles--mobile .tb-cr-offer-btn {
        min-height: 40px;
        font-size: 13px;
        font-weight: 700;
    }
}

/* Home section hierarchy */
.tb-home-page .home-section-wrap {
    margin-bottom: 18px;
}

.tb-home-page .home-section-header {
    padding: 20px 20px 14px;
}

.tb-home-page .home-section-body {
    padding-top: 4px;
}

.tb-home-page .home-section-footer {
    padding: 12px 20px 18px;
}

/* Wishlist / recently viewed empty + cards */
.tb-save-empty {
    padding: 40px 20px;
    border-radius: 12px;
    background: #fff;
    border: 1px dashed #d1d5db;
}

.tb-save-empty__title {
    margin: 0 0 6px;
    font-size: 17px;
    font-weight: 700;
    color: var(--tb-ink);
}

.tb-save-empty__text {
    margin: 0 0 16px;
    font-size: 14px;
    color: var(--tb-muted);
    line-height: 1.5;
}

.tb-save-empty__cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0 18px;
    border-radius: 10px;
    background: var(--tb-red);
    color: #fff !important;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none !important;
}

.tb-save-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 14px;
}

.tb-save-page-header h1 {
    margin: 0 0 6px;
}

.tb-save-page-header p {
    margin: 0;
    max-width: 36rem;
    line-height: 1.5;
}

/* News / blog cards unify */
.tb-news-card {
    border: 1px solid var(--tb-border);
    border-radius: 12px;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 1px 4px rgba(36, 39, 44, 0.05);
}

.tb-news-card-title {
    font-size: 15px;
    font-weight: 700;
    color: var(--tb-ink);
    line-height: 1.35;
}

.tb-news-card-excerpt {
    color: var(--tb-muted);
    font-size: 13px;
    line-height: 1.5;
}

.tb-news-card-read {
    color: var(--tb-red);
    font-weight: 700;
    font-size: 13px;
}

.blog-listing-grid .blog-card,
.blog-card {
    border: 1px solid var(--tb-border);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 1px 4px rgba(36, 39, 44, 0.05);
}

/* FAQ accordion — align with PDP detail-faq look */
.tb-faq__heading {
    font-size: var(--tb-h2);
    color: var(--tb-ink);
}

.tb-faq__accordion .panel {
    border-radius: 8px;
}

.tb-faq-section .tb-faq__accordion .acod-head .acod-title > a:hover,
.tb-faq-section .tb-faq__accordion .acod-head > a:hover {
    background: #fff8f8 !important;
}

.listing-faq-section {
    background: #fff;
    border: 1px solid var(--tb-border);
    border-radius: 12px;
    padding: 20px 22px;
    box-shadow: 0 1px 4px rgba(36, 39, 44, 0.05);
}

.listing-faq-heading {
    font-size: var(--tb-h2);
    font-weight: 700;
    color: var(--tb-ink);
}

/* Listing FAQ accordion — match Faq.ascx chevron pattern */
.listing-faq-accordion .panel {
    border: 1px solid #f0f2f5;
    border-radius: 10px;
    margin-bottom: 10px;
    overflow: hidden;
    background: #fff;
}

.listing-faq-accordion .acod-head a {
    display: flex !important;
    align-items: flex-start !important;
    gap: 12px;
    position: relative;
    padding: 14px 44px 14px 16px !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    line-height: 1.5 !important;
    color: var(--tb-ink-soft) !important;
    text-decoration: none !important;
    background: #fafbfc;
}

.listing-faq-accordion .acod-head a:hover,
.listing-faq-accordion .acod-head a:focus {
    background: #fff8f8 !important;
    color: var(--tb-red) !important;
}

.listing-faq-accordion .acod-head a::after {
    font-family: inherit !important;
    content: "" !important;
    float: none !important;
    position: absolute;
    right: 18px;
    top: 50%;
    width: 8px;
    height: 8px;
    margin-top: -5px;
    border-right: 2px solid #6b7280;
    border-bottom: 2px solid #6b7280;
    transform: rotate(45deg);
    transition: transform 0.2s ease, border-color 0.15s ease;
}

.listing-faq-accordion .acod-head a:not(.collapsed)::after {
    transform: rotate(-135deg);
    margin-top: -2px;
    border-color: var(--tb-red);
}

.listing-faq-accordion .acod-content {
    padding: 12px 16px 16px;
    font-size: 14px;
    line-height: 1.65;
    color: var(--tb-muted);
}

/* Brand hub extras */
.brand-hub-page .brand-hub-hero .card,
.brand-hub-page .brand-hub-hero .card-body {
    border: 0;
    box-shadow: none;
    background: transparent;
    padding-left: 0;
    padding-right: 0;
}

.brand-hub-page .brand-hub-hero h1.card-title,
.brand-hub-page .brand-hub-hero .card-title {
    font-size: var(--tb-h1);
    font-weight: 700;
    color: var(--tb-ink);
    letter-spacing: -0.02em;
    line-height: 1.25;
}

.brand-hub-page .side-bar .widget {
    border: 1px solid var(--tb-border);
    border-radius: 12px;
    padding: 12px 14px;
    background: #fff;
}

.brand-hub-page .filterSticky .open {
    min-height: 44px;
    padding: 0 18px;
    border: 0;
    background: transparent;
    font-weight: 800;
    color: var(--tb-ink);
}

.brand-hub-page #masonry .listing-card,
.brand-hub-page .listing-card-inner {
    border-radius: 12px;
}

.brand-hub-models-heading {
    font-size: var(--tb-h2) !important;
    font-weight: 700;
    color: var(--tb-ink);
}

/* Used detail CTA row */
.used-detail-ui .purchase-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: stretch;
}

.used-detail-ui .purchase-actions .action-item {
    flex: 1 1 140px;
}

.used-detail-ui .purchase-actions .action-item .card-link,
.used-detail-ui .purchase-actions .action-item .n-Button,
.used-detail-ui .purchase-actions .action-item .b-Button,
.used-detail-ui .purchase-actions .tb-whatsapp-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 44px;
    border-radius: 10px;
    font-weight: 700;
    text-align: center;
}

.used-detail-ui .product-imgs {
    border-radius: 12px;
    overflow: hidden;
}

.used-detail-ui .product-title .widget-title,
.used-detail-ui .product-title h1 {
    font-size: var(--tb-h1);
    font-weight: 700;
    color: var(--tb-ink);
    line-height: 1.3;
    margin: 0;
}

/* Icon-only extras */
.tb-recent-remove,
.listing-filter-close,
.tb-account-chip {
    min-width: 44px;
    min-height: 44px;
}

/* Blog / news unify with home news cards */
.blog-listing-page .blog-card__title {
    font-size: 15px;
    font-weight: 700;
    color: var(--tb-ink);
    line-height: 1.35;
}

.blog-listing-page .blog-card__excerpt {
    color: var(--tb-muted);
    font-size: 13px;
    line-height: 1.5;
}

.blog-listing-page .blog-card__cta-text {
    color: var(--tb-red);
    font-weight: 700;
    font-size: 13px;
}

.blog-listing-page .blog-listing-section-head__sub {
    color: #4b5563 !important;
}

