/*
 * BlitzBooking - site chrome (header and footer).
 *
 * The header is indigo because the homepage hero directly below it is indigo:
 * a light header would clamp a white strip on top of a dark band and the design
 * would appear to start below the fold. Off the homepage it bookends the footer.
 */

/* ---------------------------------------------------------------- header */

.bbs-chrome-header {
	position: sticky;
	top: 0;
	z-index: 40;
	background: var(--bbs-ink);
	color: var(--bbs-on-ink);
}

/* Only away from the homepage does the header need an edge to define itself.
   On the homepage that rule would cut a visible line across the hero. */
body:not(.bbs-home-page) .bbs-chrome-header {
	box-shadow: inset 0 -1px 0 var(--bbs-ink-line);
}

/* The sticky bar would otherwise cover whatever an in-page link jumps to,
   and the theme's own skip link. Derived, not hard-coded. */
html:has(.bbs-chrome-header) {
	scroll-padding-top: calc(var(--bbs-header-h, 4.25rem) + 1rem);
}

.admin-bar html:has(.bbs-chrome-header) {
	scroll-padding-top: calc(var(--bbs-header-h, 4.25rem) + 3rem);
}

.admin-bar .bbs-chrome-header { top: 32px; }

@media (max-width: 782px) {
	.admin-bar .bbs-chrome-header { top: 46px; }
}

@media (max-width: 600px) {
	.admin-bar .bbs-chrome-header { top: 0; }
}

/* The theme paints its own colours into this part; re-point them at the ink
   family. Scoped to the title and navigation subtrees only - putting this on
   the whole header would paint the mini-cart drawer indigo on indigo. */
.bbs-chrome-header .wp-block-site-title,
.bbs-chrome-header .wp-block-navigation {
	--wp--preset--color--contrast: var(--bbs-on-ink);
	--wp--preset--color--base: var(--bbs-ink);
	color: var(--bbs-on-ink);
}

.bbs-chrome-header .wp-block-site-title a {
	font-family: var(--bbs-display);
	font-weight: 800;
	font-size: 1.15rem;
	line-height: 1.2;
	letter-spacing: -0.02em;
	color: #fff;
	text-decoration: none;
	display: inline-flex;
	align-items: center;
	gap: 0.55rem;
}

/* One wordmark for the whole site: header and footer share this treatment,
   so there is never a second, different logo on the same page. */
.bbs-chrome-header .wp-block-site-title a::before,
.bbs-footer__brandname::before {
	content: "";
	width: 1.35em;
	height: 1.35em;
	flex: none;
	background: url("../brand/mark.svg") center / contain no-repeat;
}

.bbs-chrome-header .wp-block-navigation a,
.bbs-chrome-header .wp-block-navigation .wp-block-navigation-item__content {
	color: var(--bbs-on-ink-dim);
	text-decoration: none;
	font-size: 0.95rem;
}

.bbs-chrome-header .wp-block-navigation a:hover {
	color: #fff;
}

.bbs-chrome-header .wp-block-navigation [aria-current="page"] {
	color: #fff;
	position: relative;
}

.bbs-chrome-header .wp-block-navigation [aria-current="page"]::after {
	content: "";
	position: absolute;
	left: 0;
	right: 0;
	bottom: -6px;
	height: 2px;
	border-radius: 2px;
	background: var(--bbs-amber);
}

/* The call to action rides inside the <ul>, so the mobile overlay carries it
   without any separate responsive handling. */
/* Specificity deliberately one step above the generic nav link rule above, or the
   theme's own colour lands on the button label. */
.bbs-chrome-header .wp-block-navigation .bbs-nav__cta > a,
.bbs-chrome-header .wp-block-navigation .bbs-nav__cta .wp-block-navigation-item__content {
	display: inline-flex;
	align-items: center;
	background: var(--bbs-amber);
	color: var(--bbs-on-amber);
	font-weight: 600;
	padding: 0.55rem 1.15rem;
	border-radius: 999px;
	line-height: 1.2;
}

.bbs-chrome-header .wp-block-navigation .bbs-nav__cta > a:hover {
	background: #ffc154;
	color: var(--bbs-on-amber);
}

/* WooCommerce header icons inherit the theme's near-black and would vanish. */
.bbs-chrome-header .wp-block-woocommerce-customer-account,
.bbs-chrome-header .wp-block-woocommerce-customer-account a,
.bbs-chrome-header .wc-block-mini-cart__button {
	color: var(--bbs-on-ink);
}

.bbs-chrome-header .wp-block-woocommerce-customer-account svg,
.bbs-chrome-header .wc-block-mini-cart__button svg {
	fill: currentColor;
}

.bbs-chrome-header .wc-block-mini-cart__badge {
	background: var(--bbs-amber);
	color: var(--bbs-on-amber);
	border-color: var(--bbs-amber);
}

/* Hidden from sight, kept in the accessibility tree - display:none here would
   leave the account link with no accessible name at all. */
@media (max-width: 480px) {
	.bbs-chrome-header .wp-block-woocommerce-customer-account .label {
		position: absolute !important;
		width: 1px;
		height: 1px;
		overflow: hidden;
		clip-path: inset(50%);
		white-space: nowrap;
	}
}

@media (max-width: 600px) {
	.bbs-chrome-header .wp-block-group {
		flex-wrap: nowrap;
	}
}

/* Mobile overlay. The theme writes the sheet colour as an inline style and
   defaults it to light, so indigo links on a white sheet would be invisible.
   Both properties are needed; fixing only one moves the bug. */
.bbs-chrome-header .wp-block-navigation__responsive-container.is-menu-open {
	background-color: var(--bbs-ink) !important;
	color: var(--bbs-on-ink) !important;
}

.bbs-chrome-header .wp-block-navigation__responsive-container.is-menu-open a,
.bbs-chrome-header .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation-item__content,
.bbs-chrome-header .wp-block-navigation__responsive-container-close {
	color: var(--bbs-on-ink) !important;
}

.bbs-chrome-header .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation-item__content {
	font-family: var(--bbs-display);
	font-size: 1.5rem;
	font-weight: 700;
}

.bbs-chrome-header .wp-block-navigation__responsive-container.is-menu-open .bbs-nav__cta > a {
	font-family: var(--bbs-body);
	font-size: 1rem;
	color: var(--bbs-on-amber) !important;
	justify-content: center;
	width: 100%;
}

/* ---------------------------------------------------------------- footer */

.bbs-footer {
	background: var(--bbs-ink);
	color: var(--bbs-on-ink-dim);
	font-family: var(--bbs-body);
	font-size: 0.94rem;
	line-height: 1.6;
}

.bbs-footer__wrap {
	width: 100%;
	max-width: var(--bbs-maxw);
	margin-inline: auto;
	padding-inline: 24px;
}

.bbs-footer a {
	color: var(--bbs-on-ink-dim);
	text-decoration: none;
}

.bbs-footer a:hover {
	color: #fff;
	text-decoration: underline;
	text-underline-offset: 3px;
}

.bbs-footer ul {
	list-style: none;
	margin: 0;
	padding: 0;
}

/* Band 1 - what the shop can actually promise. */
.bbs-footer__trust {
	background: var(--bbs-ink-soft);
	border-bottom: 1px solid var(--bbs-ink-line);
}

.bbs-footer__trust .bbs-footer__wrap {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 12px 28px;
	padding-block: 16px;
}

.bbs-footer__promises {
	display: flex;
	flex-wrap: wrap;
	gap: 10px 28px;
	font-family: var(--bbs-mono);
	font-size: 0.74rem;
	letter-spacing: 0.07em;
	text-transform: uppercase;
	color: var(--bbs-on-ink-dim);
}

.bbs-footer__pay {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.bbs-footer__pay li {
	font-family: var(--bbs-mono);
	font-size: 0.7rem;
	letter-spacing: 0.05em;
	padding: 4px 10px;
	border: 1px solid var(--bbs-ink-line);
	border-radius: 6px;
	color: var(--bbs-on-ink-dim);
}

/* Band 2 - the site map. */
.bbs-footer__cols {
	display: grid;
	grid-template-columns: 1.5fr repeat(3, 1fr);
	gap: 34px;
	padding-block: 48px 40px;
}

@media (max-width: 900px) {
	.bbs-footer__cols { grid-template-columns: 1fr 1fr; gap: 30px; }
}

@media (max-width: 560px) {
	.bbs-footer__cols { grid-template-columns: 1fr; gap: 26px; padding-block: 36px 30px; }
}

.bbs-footer__brandname {
	font-family: var(--bbs-display);
	font-weight: 800;
	font-size: 1.15rem;
	letter-spacing: -0.02em;
	color: #fff;
	display: inline-flex;
	align-items: center;
	gap: 0.55rem;
	margin: 0 0 10px;
}


.bbs-footer__pitch {
	margin: 0 0 14px;
	max-width: 34ch;
}

.bbs-footer__contact {
	display: flex;
	flex-direction: column;
	gap: 4px;
	margin-bottom: 14px;
}

.bbs-footer__social {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.bbs-footer__social a {
	display: inline-block;
	font-size: 0.82rem;
	padding: 5px 12px;
	border: 1px solid var(--bbs-ink-line);
	border-radius: 999px;
}

.bbs-footer__social a:hover {
	border-color: var(--bbs-on-ink-dim);
	text-decoration: none;
}

/* Column headings are labels, not signals - so they are not amber. */
.bbs-footer__head {
	font-family: var(--bbs-body);
	font-size: 0.76rem;
	font-weight: 600;
	letter-spacing: 0.13em;
	text-transform: uppercase;
	color: #fff;
	margin: 0 0 12px;
}

.bbs-footer__col li + li { margin-top: 7px; }

/* Band 3 - the legal line. */
.bbs-footer__legal {
	border-top: 1px solid var(--bbs-ink-line);
}

.bbs-footer__legal .bbs-footer__wrap {
	display: flex;
	flex-wrap: wrap;
	gap: 8px 26px;
	justify-content: space-between;
	padding-block: 20px 26px;
	font-size: 0.84rem;
	color: var(--bbs-on-ink-dim);
}

.bbs-footer__legal p { margin: 0; }
