/* AW Catalog — [aw_fitments] shortcode styling.
 * Two stacked blocks: vehicles list + diagrams grid.
 */

.aw-fitments {
	margin: 1.5rem 0;
	font-family: inherit;
	color: #111;
}

.aw-fit-block + .aw-fit-block { margin-top: 1.5rem; }

.aw-fit-title {
	font-size: 1.05rem;
	font-weight: 700;
	margin: 0 0 0.7rem;
	padding: 0 0 0.4rem;
	border-bottom: 2px solid #c00;
	color: #111;
}
.aw-fit-counter {
	font-size: 0.78rem;
	color: #888;
	font-weight: 400;
}

/* ---- Vehicles ---- */
.aw-fit-list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-wrap: wrap;
	gap: 0.45rem;
}
.aw-fit-list li a {
	display: inline-flex;
	align-items: baseline;
	gap: 4px;
	padding: 5px 10px;
	background: #f7f7f8;
	border: 1px solid #e6e6e8;
	border-radius: 999px;
	font-size: 0.85rem;
	color: #111;
	text-decoration: none;
	transition: background 100ms ease, border-color 100ms ease;
}
.aw-fit-list li a:hover {
	background: #fff3d6;
	border-color: #c00;
}
.aw-fit-make { color: #888; font-size: 0.78rem; }
.aw-fit-model { font-weight: 600; }

/* ---- Diagrams grid ---- */
.aw-fit-grid {
	display: grid;
	grid-template-columns: repeat( 4, minmax( 0, 1fr ) );
	gap: 0.85rem;
}
@media ( max-width: 1100px ) { .aw-fit-grid { grid-template-columns: repeat( 3, minmax(0,1fr) ); } }
@media ( max-width: 700px  ) { .aw-fit-grid { grid-template-columns: repeat( 2, minmax(0,1fr) ); } }
@media ( max-width: 420px  ) { .aw-fit-grid { grid-template-columns: 1fr; } }

.aw-fit-card {
	display: flex;
	flex-direction: column;
	background: #fff;
	border: 1px solid #e6e6e8;
	border-radius: 6px;
	overflow: hidden;
	text-decoration: none;
	color: #111;
	transition: transform 0.12s ease, box-shadow 0.12s ease, border-color 0.12s ease;
}
.aw-fit-card:hover {
	transform: translateY( -2px );
	box-shadow: 0 6px 14px rgba( 0,0,0,0.08 );
	border-color: #c00;
}
.aw-fit-card img {
	width: 100%;
	aspect-ratio: 11 / 8;
	object-fit: contain;
	background: #fafafa;
	display: block;
}
.aw-fit-card-meta {
	display: flex;
	flex-direction: column;
	gap: 3px;
	padding: 0.5rem 0.6rem 0.6rem;
	font-size: 0.78rem;
	line-height: 1.3;
	min-width: 0;
}
.aw-fit-card-vehicle {
	color: #666;
	font-size: 0.72rem;
	letter-spacing: 0.02em;
	text-transform: uppercase;
	font-weight: 600;
}
.aw-fit-card-diag {
	color: #111;
	overflow: hidden;
	text-overflow: ellipsis;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
}
.aw-fit-card-diag code {
	font-size: 0.75rem;
	font-weight: 700;
	color: #c00;
	background: #fee;
	padding: 1px 5px;
	border-radius: 2px;
	margin-right: 4px;
}

/* ---- Grouped fitments table (v0.10.13) ---- */
.aw-fit-summary {
	margin: -0.3rem 0 0.9rem;
	font-size: 0.85rem;
	color: #777;
}
.aw-fit-veh {
	border: 1px solid #e6e6e8;
	border-radius: 6px;
	margin: 0 0 0.6rem;
	background: #fff;
	overflow: hidden;
}
.aw-fit-veh > summary {
	list-style: none;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	padding: 0.7rem 0.9rem;
	font-weight: 700;
	color: #111;
	background: #f7f7f8;
}
.aw-fit-veh > summary::-webkit-details-marker { display: none; }
.aw-fit-veh > summary::before {
	content: "▸";
	color: #c00;
	margin-right: 0.5rem;
	transition: transform 0.12s ease;
	display: inline-block;
}
.aw-fit-veh[open] > summary::before { transform: rotate( 90deg ); }
.aw-fit-veh-name { flex: 1; }
.aw-fit-veh-count { font-size: 0.75rem; font-weight: 400; color: #888; white-space: nowrap; }
.aw-fit-veh > summary:hover { background: #fff3d6; }

.aw-fit-tbl {
	width: 100%;
	border-collapse: collapse;
	font-size: 0.88rem;
}
.aw-fit-tbl th,
.aw-fit-tbl td {
	text-align: left;
	padding: 0.5rem 0.9rem;
	border-top: 1px solid #eee;
	vertical-align: top;
}
.aw-fit-tbl thead th {
	font-size: 0.72rem;
	text-transform: uppercase;
	letter-spacing: 0.03em;
	color: #888;
	font-weight: 700;
	background: #fcfcfc;
}
.aw-fit-th-item, .aw-fit-item { width: 5.5rem; white-space: nowrap; font-weight: 600; }
.aw-fit-th-qty,  .aw-fit-qty  { width: 4rem; text-align: center; }
.aw-fit-page a { color: #111; text-decoration: none; }
.aw-fit-page a:hover { color: #c00; text-decoration: underline; }
.aw-fit-page code {
	font-size: 0.78rem;
	font-weight: 700;
	color: #c00;
	background: #fee;
	padding: 1px 5px;
	border-radius: 2px;
	margin-right: 5px;
}
.aw-fit-dash { color: #bbb; }
.aw-fit-capped { font-size: 0.82rem; color: #777; margin: 0.4rem 0 0; }

/* ---- "Also fits" (vehicles with no diagram rows) ---- */
.aw-fit-also { margin-top: 1.2rem; }
.aw-fit-also-title {
	font-size: 0.9rem;
	font-weight: 700;
	margin: 0 0 0.5rem;
	color: #444;
}

/* ---- [aw_product_diagrams] grid: 2 rows of 3 (drops to 2-up on narrow columns) ---- */
.aw-product-diagrams .aw-fit-grid {
	grid-template-columns: repeat( 3, minmax( 0, 1fr ) );
}
@media ( max-width: 480px ) {
	.aw-product-diagrams .aw-fit-grid { grid-template-columns: repeat( 2, minmax( 0, 1fr ) ); }
}
.aw-pd-more { margin-top: 0.85rem; }
.aw-pd-more > summary {
	list-style: none;
	cursor: pointer;
	display: inline-block;
	font-size: 0.9rem;
	font-weight: 700;
	color: #c00;
}
.aw-pd-more > summary::-webkit-details-marker { display: none; }
.aw-pd-more-link::after { content: " →"; }
.aw-pd-more[open] .aw-pd-more-link::after { content: " ↑"; }
.aw-pd-more[open] > summary { margin-bottom: 0.85rem; }
.aw-pd-more > summary:hover { text-decoration: underline; }
