/*
 * Piece photographs (Mo, 16 November 2026): a piece's featured photograph (its first) fills its
 * frame (cover) wherever it appears: the grid on catalogue pages, the Sold and Saved pages, the
 * "From our archive" cards, the pieces on the home page, the small photograph in the Enquire
 * pop up, the first photograph on the piece page and in the quick view, and the first thumbnail.
 * Every other photograph of the piece is shown whole (contain), in its thumbnail and when it is
 * selected and shown large. Before this, every photograph was shown whole (Mo, 11 November).
 *
 * A plain stylesheet, loaded after the design system stylesheet on every page, so a theme
 * deploy leaves it alone and it wins over the rules it replaces (bricks/build/
 * cohane-adapter.css: .card img, .grid-panel .piece figure img, .enq-dialog .mini img).
 * Quick view (quick-view.css) and the archive cards on What We Do (pages.css) follow the same
 * rule in their own files. The enlarged full screen photograph still shows the whole photograph.
 *
 * The file keeps its old name so the stylesheet handle and its cache version carry on.
 */
body.grid-panel .piece figure img,
body.vc .card figure img,
.enq-dialog .mini img {
	object-fit: cover;
	object-position: center;
}
body.vc .piece-b .rec-media .main:not(.is-alt) img {
	object-fit: cover !important;
	object-position: center !important;
}
body.vc .piece-b .rec-media .main.is-alt img {
	object-fit: contain !important;
}
body.vc .rec-thumbs button img {
	object-fit: contain !important;
}
body.vc .rec-thumbs button:first-child img {
	object-fit: cover !important;
	object-position: center !important;
}

/* The piece title is 1.7rem at every width (Mo, 13 November), smaller than the design system's
   object size (2.1 to 2.75rem), so long titles sit on fewer lines. */
body.vc .rec .rec-body h1 {
	font-size: 1.7rem !important;
	line-height: 1.12 !important;
}

/* Alexander's call, 13 November: the standard section space halves, from 170px to 85px (48px
   under 900px, 36px under 640px). Same breakpoints as the design system, so these win by order.
   The home page gives each section half of it above and below (home.css). */
:root {
	--cohane-section-space: 85px;
}
@media (max-width: 900px) {
	:root {
		--cohane-section-space: 48px;
	}
}
@media (max-width: 640px) {
	:root {
		--cohane-section-space: 36px;
	}
}

/* Page heads on every page, smaller and closer (Mo's rules from the call, 13 November). Phones
   and tablets are never larger than the desktop: 32px above and below, the title at most 2.4rem
   and 2rem on phones (the design system had 48px and up to 3.25rem there). */
body.vc .page-head h1 {
	grid-column: 1 / 13;
	text-align: center;
	font-size: 2.4rem !important;
	line-height: 1.02 !important;
}
/* 42px above and 64px below on desktop (Mo, 14 November); tablets and phones keep 32px below. */
.vcp .page-head.split {
	padding-top: 42px;
	padding-bottom: 64px;
}
.vcp .page-head.split .sub {
	grid-column: 1 / 13;
	justify-self: center;
	margin: 14px 0 0;
	padding: 0;
	max-width: 33rem;
	text-align: center;
	font: var(--t-detail) !important;
	color: var(--muted);
	font-size: 14px !important;
}
@media (max-width: 900px) {
	.vcp .page-head,
	.vcp .page-head.split {
		padding-top: 32px;
		padding-bottom: 32px;
	}
	body.vc .page-head h1 {
		font-size: clamp(2rem, 5vw, 2.4rem) !important;
	}
}
@media (max-width: 640px) {
	body.vc .page-head h1 {
		font-size: 2rem !important;
	}
}

/* The selected thumbnail under a piece's photograph has no outline (Mo, 13 November), on the
   piece page and in the quick view. Keyboard users still see which thumbnail has focus. */
body.vc .rec-thumbs button[aria-current="true"]::after {
	border-color: transparent !important;
}
body.vc .qv-dialog .rec-thumbs button[aria-current="true"] {
	border-color: transparent !important;
}
body.vc .rec-thumbs button:focus-visible {
	outline: 2px solid var(--state, #25337b);
	outline-offset: 2px;
}

/* Small spaced capital labels (SAVED and MENU in the header, section labels such as SOURCING,
   breadcrumbs, specification labels, footer headings). Mo took them to 0.6rem on 13 November;
   Alexander asked on 14 November for their previous size back, the design system's 0.75rem.
   Body text and section spacing from 13 November are unchanged. */
:root {
	--t-label: 500 .75rem/1.25 var(--sans);
}

/* The catalogue sidebar list (categories and filters) in the interface type rather than the
   list type (Mo, 13 November). The links carry the text, so they take it too. */
body.vc .side ul,
body.vc .side a,
body.vc .side ul button {
	font: var(--t-ui) !important;
	letter-spacing: -.005em !important;
}

/* Who We Are: a divider line between the team (Alexander and Ellie) and Alexander's story, with
   the section space on both sides of it (85px on desktop) (Mo, 13 November). */
body.vc.who .team-c + .bio::before,
body.vc.who .bio + .ellie-c::before,
body.vc.who .ellie-c + .access-close::before {
	content: "";
	display: block;
	height: 1px;
	margin: 0 var(--m, 16px) var(--cohane-section-space);
	background: rgb(0 0 0 / 7%);
}

/* The same divider between Alexander's story and Ellie's section, and between Ellie's section and
   the closing block (Mo, 13 November). Both sections hold their content inside them, so the space
   above each line is measured from the last words, not from an edge they overhang. */
body.vc.who .bio,
body.vc.who .ellie-c {
	display: flow-root;
}
/* The closing block already sits inside the page margin, so its line needs no inset of its own. */
body.vc.who .ellie-c + .access-close::before {
	margin-left: 0;
	margin-right: 0;
}

/* No breadcrumb at the foot of the pages (Mo, 13 November). Its block stays as an empty spacer
   exactly one section space tall, so every page's last section ends the same distance above the
   footer; the block before it gives up its own bottom spacing so nothing doubles. */
body.vc .crumb-end {
	height: var(--cohane-section-space) !important;
	padding: 0 !important;
	margin: 0 !important;
	overflow: hidden;
}
body.vc .crumb-end > * {
	display: none !important;
}
body.vc :has(+ .crumb-end) {
	margin-bottom: 0 !important;
	padding-bottom: 0 !important;
}
body.vc :has(+ .crumb-end) > :last-child {
	padding-bottom: 0 !important;
	margin-bottom: 0 !important;
}
/* Pages without that block: Saved and the piece page end with the section space too. */
body.vc .saved-archive,
body.vc .piece-page .related {
	padding-bottom: var(--cohane-section-space) !important;
}

/* What We Do, From the Archive (Mo, 13 November): the two buttons under the archive are removed,
   "See more from the archive" sits on the left (pages.css), and the eight pieces sit in four columns, two
   rows (two columns on phones, where four would be too small). */
body.vc .wwd-archive .wwd-links {
	display: none !important;
}
body.vc .wwd-archive .wwd-grid {
	grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
}
@media (max-width: 640px) {
	body.vc .wwd-archive .wwd-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
	}
}

/* Footer links and text in the UI type (Mo, 14 November). The small spaced capital headings stay as labels. */
#brx-footer .foot-c li a,
#brx-footer .foot-c p,
#brx-footer .foot-c .base > * {
	font: var(--t-ui) !important;
	letter-spacing: -.005em !important;
}
/* Copyright bar (Mo, 17 November): copyright and Privacy together on the left (inc/pages.php
   wraps them in .base-l), "Crafted by" and the Mota logo on the right. */
#brx-footer .foot-c .base-l {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 6px 20px;
}
#brx-footer .foot-c .base-l > *,
#brx-footer .foot-c .mota-credit > span:first-child {
	font: var(--t-ui) !important;
	letter-spacing: -.005em !important;
}
#brx-footer .foot-c .mota-credit {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	color: var(--on-field-muted);
	text-decoration: none;
	transition: color .2s ease;
}
#brx-footer .foot-c .mota-credit:hover,
#brx-footer .foot-c .mota-credit:focus-visible {
	color: var(--on-field);
}
#brx-footer .foot-c .mota-logo {
	display: block;
	width: 59px;
	height: 14px;
	background-color: currentColor;
	-webkit-mask: url(../img/mota-creative.svg) no-repeat center / contain;
	mask: url(../img/mota-creative.svg) no-repeat center / contain;
}
/* Multi line footer text (addresses, the Clients note) keeps room between its lines. */
#brx-footer .foot-c p {
	line-height: 1.5 !important;
}

/* What We Do: the same divider line above From the Archive, with the section space on both
   sides of it (Mo, 14 November). */
body.vc.wwd .wwd-archive::before {
	content: "";
	display: block;
	height: 1px;
	margin: 0 0 var(--cohane-section-space);
	background: rgb(0 0 0 / 7%);
}

/* Piece page photographs (Mo, 16 November): the thumbnails sit on the page background, with no
   grey box behind them. A supporting photograph shown large does the same, from the top of a
   frame shaped to it (cohane-catalogue.js sets --alt-ar, never taller than 4:5), so the gap
   above the thumbnails matches the first photograph's. The first photograph is unchanged. */
body.vc .piece-b .rec-thumbs button {
	background: transparent !important;
}
body.vc .piece-b .rec-media .main.is-alt {
	background: transparent !important;
	aspect-ratio: var(--alt-ar, 4/5) !important;
}
body.vc .piece-b .rec-media .main.is-alt img {
	object-position: center top !important;
}

/* No dimensions on piece cards: listing pages (New Arrivals, New York Collection, Archive,
   Private Collection, categories) and the block of pieces at the foot of a piece page (Mo,
   16 Nov). The piece page and its quick view keep them, both read from .rec, not a.piece.
   The Saved page keeps them. */
body.vc.vcp:not(.saved-page) a.piece > .dims {
	display: none !important;
}
