/* ==========================================================================
   Crochetant: header, footer & mobile tab bar
   ========================================================================== */

/* Skip link */
.cct-skip {
	position: absolute;
	top: 8px;
	left: -9999px;
	z-index: 1000;
	padding: 10px 16px;
	border-radius: 8px;
	background: var(--cct-text);
	color: var(--cct-bg);
	font-weight: 600;
}
.cct-skip:focus { left: 12px; }

/* Header ------------------------------------------------------------------ */

.cct.cct-header {
	position: relative;
	z-index: 900;
	overflow: visible;
	border-bottom: 1.5px dashed var(--cct-stitch);
	background: var(--cct-bg);
}
@media (min-width: 960px) {
	.cct.cct-header { position: sticky; top: 0; }
	.admin-bar .cct.cct-header { top: 32px; }
}

.cct-header__inner { display: flex; align-items: center; gap: 16px; min-height: 64px; }
@media (min-width: 960px) { .cct-header__inner { gap: 28px; min-height: 76px; } }

.cct .cct-logo {
	display: inline-flex;
	flex: none;
	align-items: center;
	gap: 8px;
	color: var(--cct-text);
	font-family: var(--cct-font-heading);
	font-size: 1.4rem;
	font-weight: 700;
	letter-spacing: -.01em;
	text-decoration: none;
}
.cct .cct-logo img { display: block; width: 100%; height: auto; max-height: 52px; }
.cct .cct-logo .cct-icon { width: 28px; height: 28px; color: var(--cct-primary); }

.cct-nav { display: none; }
@media (min-width: 960px) { .cct-nav { display: block; margin-left: auto; } }
.cct-nav ul { display: flex; gap: 4px; margin: 0; padding: 0; list-style: none; }
.cct .cct-nav a {
	display: block;
	padding: 10px 14px;
	border-radius: 999px;
	color: var(--cct-text);
	font-size: .975rem;
	font-weight: 600;
	text-decoration: none;
}
.cct .cct-nav a:hover { background: var(--cct-alt); }
.cct .cct-nav a[aria-current="page"] { background: var(--cct-accent); color: var(--cct-primary-dark); }

.cct-header__actions { display: flex; align-items: center; gap: 10px; margin-left: auto; }
@media (min-width: 960px) { .cct-header__actions { margin-left: 0; } }

.cct .cct-cart {
	position: relative;
	display: none;
	place-items: center;
	width: 46px;
	height: 46px;
	border-radius: 50%;
	color: var(--cct-text);
	text-decoration: none;
}
@media (min-width: 960px) { .cct .cct-cart { display: grid; } }
.cct .cct-cart:hover { background: var(--cct-alt); }
.cct .cct-cart .cct-icon { width: 24px; height: 24px; }

.cct-cart-count {
	position: absolute;
	top: 4px;
	right: 2px;
	min-width: 19px;
	height: 19px;
	padding: 0 5px;
	border-radius: 999px;
	background: var(--cct-primary);
	color: #fff;
	font-size: .7rem;
	font-weight: 700;
	line-height: 19px;
	text-align: center;
}
.cct-cart-count.is-empty { display: none; }

.cct .cct-header__cta { min-height: 40px; padding: 8px 16px; font-size: .875rem; box-shadow: none; }
@media (min-width: 960px) { .cct .cct-header__cta { min-height: 44px; padding: 10px 20px; font-size: .9375rem; } }

/* Mobile tab bar ---------------------------------------------------------- */

.cct.cct-tabbar {
	position: fixed;
	right: 0;
	bottom: 0;
	left: 0;
	z-index: 950;
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 4px;
	padding: 6px 8px calc(6px + env(safe-area-inset-bottom));
	overflow: visible;
	border-top: 1.5px dashed var(--cct-stitch);
	background: var(--cct-surface);
	box-shadow: 0 -10px 26px -20px rgba(58, 46, 40, .55);
}
@media (min-width: 960px) { .cct.cct-tabbar { display: none; } }

.cct .cct-tab {
	position: relative;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 3px;
	min-height: 54px;
	border-radius: 14px;
	color: var(--cct-muted);
	font-size: .72rem;
	font-weight: 600;
	text-decoration: none;
	transition: background-color .15s ease, color .15s ease;
}
.cct .cct-tab .cct-icon { width: 24px; height: 24px; }
.cct .cct-tab[aria-current="page"] { background: var(--cct-accent); color: var(--cct-primary-dark); }
.cct .cct-tab:focus-visible { outline: 3px solid var(--cct-primary); outline-offset: -3px; }
.cct-tab .cct-cart-count { top: 4px; right: calc(50% - 22px); }

@media (max-width: 959px) {
	body.cct-has-tabbar { padding-bottom: calc(70px + env(safe-area-inset-bottom)); }
}

/* Footer ------------------------------------------------------------------ */

.cct.cct-footer {
	position: relative;
	margin-top: 28px;
	padding: 64px 0 28px;
	overflow: visible;
	background: var(--cct-text);
	color: var(--cct-bg);
}
.cct-footer .cct-wave { color: var(--cct-text); }

.cct-footer__grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 36px 24px; }
.cct-footer__brand { grid-column: 1 / -1; }
@media (min-width: 960px) {
	.cct-footer__grid { grid-template-columns: 1.6fr repeat(4, 1fr); }
	.cct-footer__brand { grid-column: auto; }
}

.cct .cct-footer .cct-logo { color: var(--cct-bg); }
.cct .cct-footer .cct-logo .cct-icon { color: var(--cct-accent); }
.cct .cct-footer__text { max-width: 380px; margin: 14px 0 0; color: var(--cct-bg); font-size: .95rem; opacity: .78; }
.cct .cct-footer__title { margin: 0 0 12px; color: var(--cct-bg); font-family: var(--cct-font-heading); font-size: 1.05rem; font-weight: 600; }
.cct-footer ul { display: grid; gap: 8px; margin: 0; padding: 0; list-style: none; }
.cct .cct-footer a { color: var(--cct-bg); font-size: .95rem; text-decoration: none; opacity: .8; }
.cct .cct-footer a:hover { text-decoration: underline; opacity: 1; }

.cct-footer__socials { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.cct .cct-footer__socials a {
	padding: 7px 14px;
	border: 1.5px solid rgba(251, 246, 239, .35);
	border-radius: 999px;
	font-size: .85rem;
	opacity: 1;
}
.cct .cct-footer__socials a:hover { background: rgba(251, 246, 239, .1); text-decoration: none; }

.cct-footer__bottom {
	margin-top: 44px;
	padding-top: 20px;
	border-top: 1.5px dashed rgba(251, 246, 239, .25);
	font-size: .85rem;
	opacity: .75;
}
.cct .cct-footer__bottom p { margin: 0; }