/* Scoped layout overrides; selection, compatibility warnings and vehicle context remain intact. */
.fb-compact-page-title .main-page-title { gap: 12px; }
.fb-compact-page-title .fb-catalog-page-heading { margin: 0; gap: 16px; }
.fb-compact-page-title .fb-catalog-page-title { margin: 0; font-size: 26px; line-height: 1.25; }
.fb-vehicle-card--compact > .fb-vehicle-card__summary {
    display: grid; grid-template-columns: 100px minmax(0, 1fr) auto;
    min-height: 0; align-items: center; gap: 16px; padding: 14px 18px;
}
.fb-vehicle-card--compact .fb-vehicle-card__image-wrap { height: 64px; background: transparent; }
.fb-vehicle-card--compact .fb-vehicle-card__content { min-width: 0; }
.fb-vehicle-card--compact .fb-vehicle-card__eyebrow { margin-bottom: 3px; font-size: 10px; line-height: 1.3; }
.fb-vehicle-card--compact .fb-vehicle-card__title { font-size: 17px; line-height: 1.3; overflow-wrap: anywhere; }
.fb-vehicle-card--compact .fb-vehicle-card__engine,
.fb-vehicle-card--compact .fb-vehicle-card__details { margin: 3px 0 0; font-size: 12px; line-height: 1.35; }
.fb-vehicle-card--compact .fb-vehicle-card__content > p:not(.fb-vehicle-card__engine):not(.fb-vehicle-card__details) {
    margin: 4px 0 0; font-size: 12px; line-height: 1.4;
}
.fb-vehicle-card--compact .fb-vehicle-card__compatibility-row { margin-top: 5px; }
.fb-vehicle-card--compact .fb-vehicle-card__compatibility { margin-top: 4px; padding: 4px 8px; font-size: 12px; line-height: 1.4; }
.fb-vehicle-card--compact .fb-vehicle-context-actions { margin-top: 4px; gap: 4px 10px; }
.fb-vehicle-card--compact .fb-vehicle-context-actions__remove { padding: 2px 0; font-size: 11px; }
.fb-vehicle-card--compact .fb-vehicle-context-actions__message { font-size: 11px; }
.fb-vehicle-card__compact-actions { align-self: center; }
.fb-vehicle-card__compact-open {
    display: inline-flex; justify-content: center; align-items: center; gap: 12px;
    min-height: 42px; padding: 10px 16px; border: 1px solid var(--primary, #c25512);
    border-radius: 3px; background: var(--primary, #c25512); color: #fff;
    font-size: 13px; font-weight: 600; line-height: 1.25; white-space: nowrap; cursor: pointer;
}
.fb-vehicle-card--complete .fb-vehicle-card__compact-open { background: #fff; color: var(--primary, #c25512); }
.fb-vehicle-card__compact-open:hover { filter: brightness(.94); }
.fb-vehicle-card__compact-open:focus-visible,
.fb-vehicle-sheet__close:focus-visible { outline: 3px solid var(--primary, #c25512); outline-offset: 4px; }
.fb-vehicle-card__compact-open[hidden],
[data-vehicle-sheet-header][hidden] { display: none; }
.fb-vehicle-card[data-compact-ready="1"] .fb-vehicle-card__change-button { display: none; }
/* The heading and category links remain real server-rendered links, with less empty padding. */
.fb-compact-content { padding-top: 12px !important; }
.fb-compact-content .fb-category-browser,
.fb-compact-content .fb-filter-categories { padding: 8px 0; }
.fb-compact-content .fb-category-browser__heading { margin-bottom: 10px; }
.fb-compact-content .fb-category-browser__title,
.fb-compact-content .fb-category-leaf-browser__title { font-size: 17px; margin-top: 3px; }
.fb-compact-content .fb-category-browser__eyebrow { font-size: 10px; }
.fb-compact-content .fb-category-browser__description,
.fb-compact-content .fb-category-browser__context { font-size: 12px; margin-top: 4px; }
.fb-compact-content .fb-category-group-card__header { padding-top: 12px; padding-bottom: 12px; }
.fb-compact-content .fb-category-leaf-browser__heading { margin-bottom: 8px; }
.fb-compact-product { padding-top: 18px !important; }
.fb-compact-product-page .flat-spacing-4 { padding-top: 36px; padding-bottom: 36px; }
.fb-compact-quote-content { padding-top: 20px !important; }
.fb-compact-quote-content > .container > .mb-5 { margin-bottom: 20px !important; }
.fb-compact-common-catalog { padding-top: 22px !important; }
.fb-compact-common-catalog .breadcrumbs { margin-bottom: 14px; }
.fb-compact-common-catalog > .container > .fb-common-intro { margin-top: 8px; margin-bottom: 16px; }
/* The original selector stays in the document; JS only places its existing DOM in this dialog. */
.fb-vehicle-sheet {
    position: fixed; inset: 0 0 0 auto; margin: 0; padding: 0;
    width: min(460px, 100vw); max-width: 100vw; height: 100dvh; max-height: 100dvh;
    border: 0; background: #fff; color: var(--main, #242424);
    box-shadow: -12px 0 45px #0002; overflow: auto; overscroll-behavior: contain;
}
.fb-vehicle-sheet::backdrop { background: rgba(24, 26, 22, .43); }
.fb-vehicle-sheet__header {
    display: flex; align-items: flex-start; justify-content: space-between; gap: 16px;
    padding: 22px 22px 16px; border-bottom: 1px solid var(--line, #e5ddd5);
}
.fb-vehicle-sheet__eyebrow { display: block; font-size: 10px; color: var(--text-secondary, #6e6862); text-transform: uppercase; letter-spacing: .06em; }
.fb-vehicle-sheet__header h2 { font-size: 22px; line-height: 1.25; margin: 4px 0 0; }
.fb-vehicle-sheet__close {
    display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px;
    flex-shrink: 0; padding: 0; border: 0; border-radius: 50%; background: var(--surface, #faf7f3);
    color: var(--main, #242424); font-size: 26px; line-height: 1; cursor: pointer;
}
.fb-vehicle-sheet .fb-vehicle-card__selector { border: 0; padding: 20px 22px 28px; }
.fb-vehicle-sheet .fb-vehicle-selector { padding: 0; border: 0; background: #fff; }
.fb-vehicle-sheet .fb-vehicle-selector__path { padding: 12px; margin-bottom: 20px; }
.fb-vehicle-sheet .fb-vehicle-selector__path-items { font-size: 13px; gap: 5px; }
.fb-vehicle-sheet .fb-vehicle-selector__label { font-size: 13px; margin-bottom: 8px; }
.fb-vehicle-sheet .fb-vehicle-selector__input { min-height: 46px; font-size: 16px; }
.fb-vehicle-sheet .fb-vehicle-selector__options { position: static; max-height: none; margin-top: 8px; box-shadow: none; }
.fb-vehicle-sheet .fb-vehicle-selector__option { padding: 13px 12px; }
.fb-vehicle-sheet .fb-vehicle-selector__status { margin-top: 12px; }
@media (max-width: 767px) {
    .fb-compact-page-title .fb-catalog-page-title { font-size: 22px; }
    .fb-compact-page-title .fb-catalog-page-heading { align-items: flex-start; flex-wrap: wrap; gap: 7px; }
    .fb-compact-page-title .fb-catalog-page-heading__back { font-size: 11px; }
    .fb-vehicle-card--compact > .fb-vehicle-card__summary { grid-template-columns: 72px minmax(0, 1fr) auto; gap: 12px; padding: 12px; }
    .fb-vehicle-card--compact .fb-vehicle-card__image-wrap { height: 52px; }
    .fb-vehicle-card--compact .fb-vehicle-card__title { font-size: 15px; }
    .fb-vehicle-card--compact .fb-vehicle-card__engine,
    .fb-vehicle-card--compact .fb-vehicle-card__details { font-size: 11px; }
    .fb-compact-product { padding-top: 14px !important; }
    .fb-compact-product-page .flat-spacing-4 { padding-top: 25px; padding-bottom: 25px; }
    .fb-compact-content .fb-category-browser__heading { margin-bottom: 8px; }
    .fb-vehicle-sheet { inset: auto 0 0; width: 100vw; height: 90dvh; max-height: 90dvh; border-radius: 16px 16px 0 0; }
    .fb-vehicle-sheet__header { padding: 18px 18px 14px; }
    .fb-vehicle-sheet .fb-vehicle-card__selector { padding: 16px 18px 24px; }
}
@media (max-width: 575px) {
    .fb-vehicle-card--compact > .fb-vehicle-card__summary { grid-template-columns: 64px minmax(0, 1fr); gap: 8px 12px; }
    .fb-vehicle-card--compact .fb-vehicle-card__compact-actions { grid-column: 2; }
    .fb-vehicle-card__compact-open { padding: 9px 13px; min-height: 40px; font-size: 12px; }
    .fb-vehicle-card--compact .fb-vehicle-card__eyebrow--product { display: block; }
    .fb-vehicle-card--compact .fb-vehicle-card__compatibility { max-width: 100%; font-size: 11px; padding: 4px 7px; }
    .fb-vehicle-card--compact .fb-vehicle-card__content > p:not(.fb-vehicle-card__engine):not(.fb-vehicle-card__details) { font-size: 11px; }
}
