/*
 * Vehicle card photos: fill the image frame on every page (owner decision 25 Oct 2026, evening).
 *
 * Root cause of the pale strip under some photos: every card frame (.motorit-v126-image, .motorit-recent-strip-v1-img)
 * has a fixed shape (4:3 aspect-ratio, or 86 x 66px) and its photo rule says width/height 100% + object-fit: cover, but
 * the page stylesheets extracted from the old site also carry generic resets (`img { height: auto }`,
 * `.motorit-shell img { height: auto }`) with the same specificity, later in the file. Those won, so a photo took its
 * own height: wider-than-4:3 photos left a strip (taller ones were cropped at the bottom instead of centred).
 * These rules are more specific than the resets and load after the page CSS, so they hold on every page. Hover zoom,
 * radius and everything else are unchanged; the home page's own !important rules already did the same thing.
 */
/* The photo is laid over the whole frame (absolute, inset 0): a percentage height alone did not resolve in every
   layout (e.g. the 86 x 66px "Continue browsing" thumbnails inside a grid card stayed at the photo's own height). */
.motorit-v126-card .motorit-v126-image,
.motorit-recent-strip-v1-card .motorit-recent-strip-v1-img { position: relative; }
.motorit-v126-card .motorit-v126-image > img,
.motorit-recent-strip-v1-card .motorit-recent-strip-v1-img > img {
  position: absolute; inset: 0; display: block; width: 100%; height: 100%; max-width: none; object-fit: cover; object-position: center center;
}
/* No photo: the "Vehicle image" placeholder fills the frame with the label centred (it was loose text in the corner). */
.motorit-v126-card .motorit-v126-image > .motorit-feature-image-placeholder-v4 {
  position: absolute; inset: 0; z-index: 0; display: flex; align-items: center; justify-content: center; padding: 12px;
  background: #edf5fc; color: rgb(84, 98, 118); font-size: 13px; font-weight: 700; line-height: 1.3; text-align: center;
}

/* m10 (owner 26 Oct 2026): card titles are make + base model; one line with an ellipsis as a safety net. */
.motorit-v126-title { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 100%; }

/* Update 26: insurance write-off pill ("Cat S"), next to the mileage on vehicle cards, in the saved-vehicle chips and in
   quick view; the advert page adds its own sizing (vehicle.css). A caution colour (amber), never green. */
.motorit-writeoff-badge {
  display: inline-flex; align-items: center; flex: 0 0 auto; margin: 0 0 0 2px; padding: 1px 7px; border: 1px solid #efc24a;
  border-radius: 999px; background: #ffe9a3; color: #5a3b00; font-family: inherit; font-size: 11px; font-style: normal;
  font-weight: 800; line-height: 1.35; letter-spacing: 0.01em; white-space: nowrap; text-decoration: none;
}
.motorit-writeoff-badge em { font-style: normal; }
.motorit-v126-info .motorit-writeoff-badge { margin-left: 4px; }
.msv2-meta .motorit-writeoff-badge { padding: 5px 9px; border-radius: 9px; font-size: 11px; }
.motorit-qv-modal-meta .motorit-writeoff-badge { vertical-align: 1px; }
/* Compare page (m33): after the title in the vehicle cards and the table header, and in the "Insurance category" row. */
.mcv2-title .motorit-writeoff-badge, .mcv2-row-head .motorit-writeoff-badge { margin-left: 6px; vertical-align: 2px; font-size: 11px; }
.mcv2-cell .motorit-writeoff-badge { font-size: 12px; }

/* ===== m29 update 29: no valuation -> "Commercial vehicle" tag / "Seller's asking price" badge (parts/no-valuation.php) ===== */
.motorit-novalue { box-sizing: border-box; color: #163a63; }
.motorit-novalue__icon { display: block; flex: none; color: #1d5b93; }
/* Cards: one compact full-width line under the miles/location, same edges as Save + Compare (m31). */
.motorit-v126-detail-row.is-novalue, .motorit-home-wrap .motorit-v126-detail-row.is-novalue { grid-template-columns: minmax(0, 1fr) !important; min-height: 0 !important; }
.motorit-novalue--strip { position: relative; container-type: inline-size; box-sizing: border-box; width: 100%; min-width: 0; margin: 8px 0 0; padding: 6px 10px; min-height: 31px;
  display: flex; align-items: center; background: #eef5fb; border: 1px solid #d3e3f1; border-radius: 10px; color: #163a63; }
.motorit-novalue--strip .motorit-novalue__in { display: flex; flex-wrap: nowrap; align-items: center; gap: 6px; width: 100%; min-width: 0; font-size: 12px; line-height: 1.25; white-space: nowrap; }
.motorit-novalue--strip .motorit-novalue__icon { width: 20px; height: 17px; }
.motorit-novalue--strip .motorit-novalue__title { flex: none; font-size: 12px; font-weight: 800; color: #163a63; }
.motorit-novalue--strip .motorit-novalue__sep { flex: none; color: #7d93ad; }
.motorit-novalue--strip .motorit-novalue__sub { flex: none; font-size: 11.5px; font-weight: 600; color: #4a6585; }
.motorit-novalue--strip .motorit-novalue__info { position: relative; display: inline-flex; align-items: center; gap: 4px; flex: none; margin-left: auto; color: #1d5b93;
  font-size: 11px; font-weight: 600; cursor: help; border-radius: 6px; outline-offset: 2px; }
.motorit-novalue--strip .motorit-novalue__info svg { flex: none; }
/* Narrower cards (grid columns, phone list cards): smaller type, then the note becomes the icon alone (the tip keeps the words),
   and the commercial line wraps "Seller's asking price" under the title rather than cutting it off. */
@container (max-width: 310px) {
  .motorit-novalue__in { gap: 5px; }
  .motorit-novalue--strip .motorit-novalue__title { font-size: 11.5px; }
  .motorit-novalue--strip .motorit-novalue__sub, .motorit-novalue--strip .motorit-novalue__info { font-size: 10.5px; }
}
@container (max-width: 235px) {
  .motorit-novalue--strip .motorit-novalue__note { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .motorit-novalue--strip .is-commercial .motorit-novalue__in, .motorit-novalue--strip .motorit-novalue__in:has(.motorit-novalue__sep) { flex-wrap: wrap; row-gap: 1px; }
  .motorit-novalue--strip .motorit-novalue__sep { display: none; }
  .motorit-novalue--strip .motorit-novalue__sub { flex-basis: 100%; padding-left: 25px; }
}
.motorit-novalue__tip { position: absolute; right: -4px; bottom: calc(100% + 10px); z-index: 5; width: 200px; padding: 8px 10px; border-radius: 8px; background: #163a63; color: #fff;
  font-size: 11.5px; font-weight: 500; line-height: 1.35; text-align: left; white-space: normal; box-shadow: 0 6px 18px rgba(16, 40, 70, .22); opacity: 0; visibility: hidden; transition: opacity .15s ease; pointer-events: none; }
.motorit-novalue__tip::after { content: ""; position: absolute; right: 8px; top: 100%; border: 6px solid transparent; border-top-color: #163a63; }
.motorit-novalue__info:hover .motorit-novalue__tip, .motorit-novalue__info:focus .motorit-novalue__tip, .motorit-novalue__info:focus-within .motorit-novalue__tip { opacity: 1; visibility: visible; }
@media (max-width: 359px) { .motorit-novalue--strip .motorit-novalue__note { display: none; } }
/* Advert price card: the same treatment as a panel in place of the blank gauge + empty guide rows. */
.motorit-vehicle-v3 .motorit-vehicle-price-card__market.is-novalue { display: block; }
.motorit-vehicle-v3 .motorit-novalue--panel { display: grid; justify-items: center; gap: 6px; padding: 18px 16px 16px; text-align: center; background: #eef5fb; border: 1px solid #d3e3f1; border-radius: 14px; }
.motorit-vehicle-v3 .motorit-novalue--panel .motorit-novalue__icon { width: 30px; height: 25px; }
.motorit-vehicle-v3 .motorit-novalue--panel .motorit-novalue__title { display: block; font-size: 19px; font-weight: 800; line-height: 1.2; color: #163a63; letter-spacing: 0; text-transform: none; }
.motorit-vehicle-v3 .motorit-novalue--panel .motorit-novalue__sub { display: block; font-size: 13px; font-weight: 700; line-height: 1.25; color: #4a6585; }
.motorit-vehicle-v3 .motorit-novalue--panel .motorit-novalue__text { display: flex; align-items: flex-start; justify-content: center; gap: 6px; margin: 4px 0 0; font-size: 12.5px; font-weight: 500; line-height: 1.4; color: #4a6585; text-align: left; }
.motorit-vehicle-v3 .motorit-novalue--panel .motorit-novalue__text svg { flex: none; margin-top: 2px; color: #1d5b93; }
.motorit-vehicle-v3 .motorit-novalue--panel.is-commercial .motorit-novalue__text { text-align: center; }

/* ===== Update 48: "Verified" badge on the card title line (parts/verified-badge.php), no longer on the photo =====
   The title link takes all the free width and keeps its own truncation; the badge never shrinks, sits opposite it on the
   first title line, and turns icon-only (tooltip + screen-reader text keep the words) when the card body is narrow.
   Brand blue on the pale card tint, the Quick view pill's colours; never green. Same badge next to the quick view title. */
.motorit-v126-title-row { display: flex; align-items: flex-start; gap: 8px; min-width: 0; container-type: inline-size; }
.motorit-v126-title-row .motorit-v126-title-link { display: block; flex: 1 1 auto; min-width: 0; }
.motorit-card-verified {
  display: inline-flex; flex: 0 0 auto; align-items: center; gap: 4px; box-sizing: border-box; height: 22px; margin: -1px 0 0; padding: 0 8px 0 5px;
  border: 1px solid rgb(210, 223, 236); border-radius: 999px; background: rgb(241, 248, 253); color: rgb(6, 111, 142);
  font-family: inherit; font-size: 11px; font-style: normal; font-weight: 800; line-height: 1; letter-spacing: 0; white-space: nowrap; cursor: default;
}
.motorit-card-verified svg { display: block; flex: 0 0 14px; width: 14px; height: 14px; }
.motorit-card-verified__shield { fill: rgb(6, 123, 157); }
.motorit-card-verified__tick { fill: none; stroke: #ffffff; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
@container (max-width: 230px) {
  .motorit-v126-title-row .motorit-card-verified { width: 22px; padding: 0; justify-content: center; }
  .motorit-v126-title-row .motorit-card-verified__text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
}
.motorit-qv-overlay .motorit-qv-title-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; min-width: 0; }
.motorit-qv-overlay .motorit-qv-title-row .motorit-qv-modal-title { min-width: 0; }
.motorit-qv-overlay .motorit-card-verified { height: 26px; margin: 0; padding: 0 10px 0 6px; gap: 5px; font-size: 12px; }
.motorit-qv-overlay .motorit-card-verified svg { flex-basis: 16px; width: 16px; height: 16px; }
