/* Gallery
   Tiles under the main photo, drawn only when a vehicle has more than one - see
   fetch-vehicle-gallery-rem.php. Four to a row at a set width, left-aligned, the same look as the
   new-vehicle page's gallery. Tiles past eight are .thumb_extra, shown when vehicle.js adds
   .vehicle-gallery-expanded. */
#photos-container {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 8px;
	margin-top: 8px;
}

.thumb_container {
	aspect-ratio: 4 / 3;
	overflow: hidden;
	background-color: #f5f5f5;
}

.thumb_extra {
	display: none;
}

.vehicle-gallery-expanded .thumb_extra {
	display: block;
}

.vehicle-gallery-more {
	padding: 8px 0 0;
}

.thumb_container a {
	display: block;
	width: 100%;
	height: 100%;
}

.thumb_image {
	width: 100%;
	height: 100%;
	display: block;
	object-fit: cover;
	background-position: center center;
	background-size: cover;
	background-repeat: no-repeat;
}

.vehicle-main-image-link {
	display: block;
	aspect-ratio: 16 / 9;
	overflow: hidden;
	background-color: #f5f5f5;
}

.vehicle-main-image {
	width: 100%;
	height: 100%;
	display: block;
	object-fit: cover;
}

#vehicle-price-container {
	color: #333;
	font-weight: 600;
}

.vehicle-dealership-map {
	margin-top: 15px;
	border-radius: 4px;
	overflow: hidden;
}

#vehicle-dealership-map-container iframe {
	display: block;
	width: 100%;
}

/* Sticky action bar - the Call / Send us a message buttons from the top of the page follow
   the visitor down in a translucent bar once the inline ones scroll up under the header */
#vehicle-sticky-actions {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	z-index: 1020;
	padding: 8px 0;
	background-color: rgba(255, 255, 255, 0.85);
	-webkit-backdrop-filter: blur(6px);
	backdrop-filter: blur(6px);
	border-bottom: 1px solid rgba(0, 0, 0, 0.1);
	box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
	opacity: 0;
	visibility: hidden;
	transform: translateY(-100%);
	transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s ease;
}

#vehicle-sticky-actions.is-visible {
	opacity: 1;
	visibility: visible;
	transform: translateY(0);
}

/* Phones.

   The three actions are btn-lg, and one of them is pulled left of the two the row right-aligns.
   Side by side they are wider than any phone, so what a visitor actually got was a ragged stack at
   three different widths with a stray 5px indent under it - and the same three in the sticky bar,
   which then stood about a third of the screen tall over the page it was following.

   Inline they become one full width button per line. In the sticky bar they stay on one row,
   sharing it equally at a size that fits - a bar that follows the visitor down the page has to
   stay a bar. */

@media (max-width: 767px) {

	#vehicle-action-buttons {
		text-align: left;
	}

	/* float: none needs !important to beat .pull-left on "Make us an offer" - left floated at full width,
	   it covered "Give us a call" under it and pushed that button's icon off the screen */
	#vehicle-action-buttons .btn {
		display: block;
		width: 100%;
		float: none !important;
		margin-left: 0px !important;
		margin-bottom: 8px;
	}

	#vehicle-sticky-actions {
		padding: 6px 0;
	}

	#vehicle-sticky-actions .col-xs-12 {
		display: flex;
		align-items: stretch;
		text-align: center;
	}

	#vehicle-sticky-actions .btn {
		flex: 1 1 0px;
		float: none;
		min-width: 0px;
		margin-left: 5px !important;
		padding: 7px 5px;
		font-size: 12px;
		line-height: 1.25;
		white-space: normal;
	}

	#vehicle-sticky-actions .col-xs-12 > :first-child {
		margin-left: 0px !important;
	}
}

/* Sticker price shown beside a sale price - reads as the price that was, see VehicleInventory::displayPrice() */
#vehicle-price-container .vehicle-price-was {
	color: #595959;
	font-size: 17px;
	font-weight: 400;
	margin-right: 4px;
}

/* Carfax report banner under the gallery, shown when the vehicle has a Carfax link */
.vehicle-carfax-link {
	display: inline-block;
	margin-top: 12px;
}

.vehicle-carfax-link img {
	display: block;
	max-width: 100%;
	height: auto;
}

/* Panel titles became <h2> for the page outline (WCAG 1.3.1) - they keep the look they had as plain text in the panel heading */
.panel-heading > h2.panel-title {
	font-size: inherit;
	font-weight: inherit;
	line-height: inherit;
	font-family: inherit;
	text-transform: inherit;
	letter-spacing: inherit;
	margin: 0;
}

/* The "Fields marked * are required." line above each form - the asterisk itself is aria-hidden, the inputs carry aria-required */
.form-required-note {
	font-size: 13px;
	color: #595959;
	margin: 0 0 15px;
}
