/**
 * Simulator Directory additions on top of the Club Directory / Single Club
 * styles (child-theme.css). Plain CSS so it ships without a Sass build.
 */

/* Directory card: # of Bays / Hours / GAP Member Offer row */
.club-directory-card__details {
	display: flex;
	align-items: flex-start;
	margin: 18px 0 0;
	border-top: 1px solid #6ea3a0;
}

.club-directory-card__detail {
	display: flex;
	flex: 1 1 0;
	flex-direction: column;
	gap: 8px;
	min-width: 0;
	padding-top: 16px;
	padding-right: 12px;
}

.club-directory-card__detail--bays {
	flex: 0 0 108px;
}

.club-directory-card__detail dt {
	color: #a99b57;
	font-size: 11px;
	font-weight: 700;
	line-height: normal;
}

.club-directory-card__detail dd {
	margin: 0;
	color: #0b6560;
	font-size: 12px;
	font-weight: 400;
	line-height: 1.2;
}

/* Logo frame uses the card's stroke color */
.page-template-page-template-simulator-directory .club-directory-card__logo-wrap {
	border-color: #d9d9d9;
}

/* Gotham Book per the design; otherwise inherits Light (300) */
.page-template-page-template-simulator-directory .club-directory-card__excerpt {
	font-weight: 400;
}

/* Hero: once stacked, show a smaller logo above the title */
@media (max-width: 991.98px) {
	.page-template-page-template-simulator-directory .club-directory-page-hero__logo-wrap {
		order: -1;
		margin-top: 0;
		margin-bottom: 24px;
	}

	.page-template-page-template-simulator-directory .club-directory-page-hero__logo {
		max-width: 90px;
	}
}

/* Results header: keep "Sort By" and "Map View" on one line; wrap the toggle below if needed */
.page-template-page-template-simulator-directory .club-directory-results__header {
	flex-wrap: wrap;
	row-gap: 12px;
}

.page-template-page-template-simulator-directory .club-directory-results__sort-label,
.page-template-page-template-simulator-directory .club-directory-results__map-view-toggle {
	white-space: nowrap;
}

/* List view: line the sort row and cards up with the hero text. The hero text
   is 22/24 of .container.tif-container (max-widths below, plus the hero's and
   container's 7.5px paddings), centered. */
@media (min-width: 992px) {
	.page-template-page-template-simulator-directory .club-directory-results.is-list-view .club-directory-results__container {
		max-width: 1185px;
		padding-right: 15px;
		padding-left: 15px;
	}

	.page-template-page-template-simulator-directory .club-directory-results.is-list-view .club-directory-results__header,
	.page-template-page-template-simulator-directory .club-directory-results.is-list-view .club-directory-results__body {
		width: calc(100% * 22 / 24);
		margin-right: auto;
		margin-left: auto;
		padding-right: 0;
		padding-left: 0;
	}

	.page-template-page-template-simulator-directory .club-directory-results.is-list-view .club-directory-results__list {
		padding-right: 0;
	}
}

@media (min-width: 1200px) {
	.page-template-page-template-simulator-directory .club-directory-results.is-list-view .club-directory-results__container {
		max-width: 1425px;
	}
}

@media (min-width: 1600px) {
	.page-template-page-template-simulator-directory .club-directory-results.is-list-view .club-directory-results__container {
		max-width: 1585px;
	}
}

@media (min-width: 992px) {
	.page-template-page-template-simulator-directory .club-directory-cards {
		gap: 25px;
	}

	.page-template-page-template-simulator-directory .club-directory-results.is-map-view .club-directory-cards {
		gap: 15px;
	}
}

/* Space below the last card (80px per the design), with or without pagination */
.page-template-page-template-simulator-directory .club-directory-cards {
	margin-bottom: 80px;
}

/* Pagination, per the design; the cards' bottom margin supplies the space above it */
.page-template-page-template-simulator-directory .club-directory-results__pagination {
	gap: 8px;
	padding: 0 0 80px;
}

.page-template-page-template-simulator-directory .club-directory-results__pagination-page {
	width: 42px;
	height: 42px;
}

.page-template-page-template-simulator-directory .club-directory-results__pagination-arrow {
	width: 28px;
	height: 34px;
}

.page-template-page-template-simulator-directory .club-directory-results__pagination-arrow.is-disabled {
	opacity: 0.5;
}

@media (max-width: 767.98px) {
	.page-template-page-template-simulator-directory .club-directory-cards {
		margin-bottom: 40px;
	}

	/* The results section's own 40px bottom padding supplies the space below */
	.page-template-page-template-simulator-directory .club-directory-results__pagination {
		padding: 0;
	}
}

/* Mobile list view: buttons line up with the text column, not the logo */
@media (max-width: 767.98px) {
	.page-template-page-template-simulator-directory .club-directory-results.is-list-view .club-directory-card__actions {
		grid-column: 2;
	}
}

/* Smallest mobile: full-width stacked buttons */
@media (max-width: 575.98px) {
	.page-template-page-template-simulator-directory .club-directory-results .club-directory-card__actions {
		flex-direction: column;
		align-items: stretch;
	}

	.page-template-page-template-simulator-directory .club-directory-card__view-course,
	.page-template-page-template-simulator-directory .club-directory-card__website {
		width: 100%;
	}
}

/* Keep "View Simulator" on one line in the narrow list-view button column */
.page-template-page-template-simulator-directory .club-directory-card__view-course,
.page-template-page-template-simulator-directory .club-directory-card__website {
	padding-right: 16px;
	padding-left: 16px;
	white-space: nowrap;
}

/* List view: "Address | X miles away" on one line, per the large card design */
@media (min-width: 768px) {
	.page-template-page-template-simulator-directory .club-directory-results.is-list-view .club-directory-card__address,
	.page-template-page-template-simulator-directory .club-directory-results.is-list-view .club-directory-card__address + .club-directory-card__zip-distance {
		display: inline;
		line-height: 1.2;
	}

	.page-template-page-template-simulator-directory .club-directory-results.is-list-view .club-directory-card__detail--bays {
		flex: 1 1 0;
	}

	.page-template-page-template-simulator-directory .club-directory-results.is-list-view .club-directory-card__address + .club-directory-card__zip-distance::before {
		content: "|\00a0";
		margin-left: 11px;
	}
}

@media (max-width: 575.98px) {
	.club-directory-card__details {
		flex-wrap: wrap;
	}

	.club-directory-card__detail,
	.club-directory-card__detail--bays {
		flex: 1 1 100%;
	}
}

/* Single page header: GAP Member Offer banner */
.single-club-hero__offer {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: center;
	gap: 4px;
	max-width: 726px;
	margin: 40px 0 0;
	padding: 12px;
	border: 1px solid #0b6560;
	border-radius: 8px;
	background: rgba(110, 163, 160, 0.2);
	color: #0b6560;
	font-size: 14px;
	line-height: 1.2;
	text-align: center;
}

.single-club-hero__offer-label {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	font-weight: 700;
	line-height: 2.09;
	text-transform: uppercase;
}

.single-club-hero__offer-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 16px;
	height: 16px;
	/* Optical centering: the hole's base hangs below the caps' baseline */
	position: relative;
	top: -1px;
}

/* Mobile: the label wraps onto its own all-caps line, so lift the icon a bit more */
@media (max-width: 575.98px) {
	.single-club-hero__offer-icon {
		top: -2px;
	}
}

.single-club-hero__offer-icon img {
	display: block;
	transform: scaleX(-1);
}

/* Single page: same content width as the directory's hero text and list view
   (22/24 of .container.tif-container, less its 15px of paddings), centered */
@media (min-width: 992px) {
	.single-simulator .single-club-hero__container,
	.single-simulator .single-club-content > .container {
		width: calc((100% - 30px) * 22 / 24);
		max-width: calc((1170px - 15px) * 22 / 24);
		padding-right: 0;
		padding-left: 0;
	}
}

@media (min-width: 1200px) {
	.single-simulator .single-club-hero__container,
	.single-simulator .single-club-content > .container {
		max-width: calc((1410px - 15px) * 22 / 24);
	}
}

@media (min-width: 1600px) {
	.single-simulator .single-club-hero__container,
	.single-simulator .single-club-content > .container {
		max-width: calc((1570px - 15px) * 22 / 24);
	}
}

@media (max-width: 767.98px) {
	.single-simulator .single-club-hero__logo-wrap {
		max-width: none;
	}
}

/* Desktop: 40px between the pills and the phone / website row, per the design */
@media (min-width: 992px) {
	.single-simulator .single-club-hero__pills {
		margin-bottom: 40px;
	}
}

.single-simulator .single-club-hero__summary-link--website span:last-child {
	text-decoration: underline;
}

/* Single page photos */
.single-simulator-photos {
	display: flex;
	flex-direction: column;
	gap: 51px;
}

.single-simulator-photos__image {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: 811 / 536;
	object-fit: cover;
}
