/* Shared components: everything that appears on more than one page lives here. */

/* ---------- Pill title: the black rounded label from the printed menu ---------- */
.pill-title {
	display: inline-block;
	padding: 0.32em 1.05em 0.38em;
	background: var(--ink);
	color: var(--paper);
	border-radius: var(--r-pill);
	font-family: var(--f-head);
	font-size: var(--fs-sm);
	font-weight: 800;
	letter-spacing: 0.06em;
	line-height: 1.2;
	text-transform: uppercase;
}

.pill-title--yellow {
	background: var(--yellow);
	color: var(--ink);
}

.eyebrow {
	font-weight: 700;
	font-size: var(--fs-sm);
	letter-spacing: 0.04em;
}

/* ---------- Buttons ---------- */
.btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 0.5em;
	min-height: 48px;
	padding: 0.7em 1.35em;
	border: 2px solid transparent;
	border-radius: var(--r-pill);
	font-weight: 700;
	font-size: var(--fs-md);
	line-height: 1.1;
	text-decoration: none;
	white-space: nowrap;
	transition: transform 0.18s var(--ease), box-shadow 0.18s var(--ease), background-color 0.18s;
}

.btn:hover {
	transform: translateY(-2px);
}

.btn:active {
	transform: translateY(0);
}

.btn--lg {
	min-height: 56px;
	padding-inline: 1.6em;
	font-size: var(--fs-lg);
}

.btn--sm {
	min-height: 44px;
	padding: 0.5em 1em;
	font-size: var(--fs-sm);
}

.btn--block {
	width: 100%;
}

.btn--ink {
	background: var(--ink);
	color: var(--yellow);
}

.btn--ink:hover {
	box-shadow: 4px 4px 0 var(--teal);
}

.btn--wa {
	background: var(--wa);
	color: var(--paper);
}

.btn--wa:hover {
	background: var(--wa-dark);
}

.btn--wa:disabled {
	background: var(--ink-3);
	cursor: not-allowed;
	transform: none;
}

.btn--line {
	border-color: var(--ink);
	color: var(--ink);
	background: transparent;
}

.btn--line:hover {
	background: var(--ink);
	color: var(--yellow);
}

.btn--ghost {
	border-color: var(--line-strong);
	background: var(--paper);
	color: var(--ink);
}

.btn--ghost:hover {
	border-color: var(--ink);
}

.icon-btn {
	display: grid;
	place-items: center;
	width: 44px;
	height: 44px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: transparent;
}

.icon-btn:hover {
	background: rgb(35 31 32 / 0.08);
}

/* ---------- Status dots ---------- */
.dot {
	display: inline-block;
	width: 10px;
	height: 10px;
	border-radius: 50%;
	background: var(--bad);
	flex: none;
}

.dot.is-open {
	background: #1fbf5c;
	box-shadow: 0 0 0 0 rgb(31 191 92 / 0.6);
	animation: pulse 2.2s infinite;
}

@keyframes pulse {
	70% {
		box-shadow: 0 0 0 8px rgb(31 191 92 / 0);
	}
	100% {
		box-shadow: 0 0 0 0 rgb(31 191 92 / 0);
	}
}

.status {
	display: inline-flex;
	align-items: center;
	gap: 0.45em;
	padding: 0.3em 0.75em;
	border-radius: var(--r-pill);
	background: var(--paper);
	color: var(--ink);
	font-size: var(--fs-xs);
	font-weight: 700;
	line-height: 1.2;
}

.status::before {
	content: "";
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background: var(--bad);
}

.status.is-open::before {
	background: #1fbf5c;
}

/* ---------- Header ---------- */
.site-header {
	position: sticky;
	top: 0;
	z-index: 50;
	background: var(--yellow);
	border-bottom: 2px solid var(--ink);
}

.site-header__inner {
	display: flex;
	align-items: center;
	gap: var(--sp-5);
	height: var(--header-h);
}

.site-logo img {
	width: auto;
	height: 50px;
}

.site-nav {
	margin-right: auto;
}

.site-nav ul {
	display: flex;
	gap: var(--sp-2);
}

.site-nav a {
	display: block;
	padding: 0.5em 0.9em;
	border-radius: var(--r-pill);
	font-weight: 700;
	text-decoration: none;
}

.site-nav a:hover {
	background: rgb(35 31 32 / 0.08);
}

.site-nav a[aria-current="page"] {
	background: var(--ink);
	color: var(--yellow);
}

.site-header__actions {
	display: flex;
	align-items: center;
	gap: var(--sp-2);
}

.branch-chip {
	display: inline-flex;
	align-items: center;
	gap: 0.45em;
	min-height: 44px;
	padding: 0.35em 0.8em;
	border: 2px solid var(--ink);
	border-radius: var(--r-pill);
	background: var(--paper);
	font-size: var(--fs-sm);
	line-height: 1.15;
	text-align: left;
}

.branch-chip__label {
	color: var(--muted);
	font-size: var(--fs-xs);
}

.branch-chip .icon-chevron {
	width: 1em;
	height: 1em;
}

.order-btn {
	position: relative;
	display: inline-flex;
	align-items: center;
	gap: 0.45em;
	min-height: 44px;
	padding: 0.35em 1.1em;
	border: 2px solid var(--ink);
	border-radius: var(--r-pill);
	background: var(--ink);
	color: var(--yellow);
	font-weight: 700;
}

.order-btn__count {
	display: grid;
	place-items: center;
	min-width: 22px;
	height: 22px;
	padding: 0 6px;
	border-radius: var(--r-pill);
	background: var(--yellow);
	color: var(--ink);
	font-size: var(--fs-xs);
	font-weight: 800;
}

.order-btn.is-bump {
	animation: bump 0.4s var(--ease);
}

@keyframes bump {
	40% {
		transform: scale(1.12);
	}
}

.nav-toggle {
	display: none;
	width: 44px;
	height: 44px;
	padding: 0;
	place-items: center;
	border: 2px solid var(--ink);
	border-radius: 50%;
	background: transparent;
}

.mobile-nav {
	border-top: 2px solid var(--ink);
	background: var(--yellow);
}

.mobile-nav a {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: var(--sp-4) 0;
	border-bottom: 1px solid var(--line-strong);
	font-family: var(--f-head);
	font-size: var(--fs-xl);
	font-weight: 800;
	text-decoration: none;
}

@media (max-width: 860px) {
	.site-nav {
		display: none;
	}
	.nav-toggle {
		display: grid;
	}
	.site-header__inner {
		gap: var(--sp-3);
	}
	.site-header__actions {
		margin-left: auto;
	}
}

@media (max-width: 520px) {
	:root {
		--header-h: 64px;
	}
	.site-logo img {
		height: 42px;
	}
	.branch-chip__label,
	.branch-chip .icon-chevron {
		display: none;
	}
	.branch-chip {
		max-width: 128px;
		padding-inline: 0.65em;
	}
	.branch-chip strong {
		display: block;
		overflow: hidden;
		text-overflow: ellipsis;
		white-space: nowrap;
	}
	.order-btn > span:not(.order-btn__count) {
		display: none;
	}
	.order-btn {
		padding-inline: 0.75em;
	}
}

/* ---------- Sections ---------- */
.section {
	padding-block: var(--sp-8);
}

.section--cream {
	background: var(--cream);
}

.section--yellow {
	background: var(--yellow);
}

.section--teal {
	background: var(--teal);
	color: var(--paper);
}

.section--ink {
	background: var(--ink);
	color: var(--cream);
}

.section__head {
	display: grid;
	justify-items: start;
	gap: var(--sp-3);
	max-width: 46rem;
	margin-bottom: var(--sp-6);
}

.section__head h2 {
	font-size: var(--fs-2xl);
}

.section__head p:not(.pill-title) {
	color: var(--muted);
	font-size: var(--fs-lg);
}

.section--ink .section__head p:not(.pill-title),
.section--teal .section__head p:not(.pill-title) {
	color: inherit;
	opacity: 0.88;
}

.section__more {
	margin-top: var(--sp-6);
	text-align: center;
}

/* ---------- Dishes (menu rows + home cards) ---------- */
.dish {
	position: relative;
	display: grid;
	gap: var(--sp-3) var(--sp-4);
	background: var(--paper);
	border: 1.5px solid var(--line);
	border-radius: var(--r-md);
	transition: border-color 0.2s, box-shadow 0.2s, opacity 0.2s;
}

.dish:hover {
	border-color: var(--ink);
}

.dish--row {
	grid-template-columns: 1fr auto;
	align-items: center;
	padding: var(--sp-4);
}

.dish--row.has-img {
	grid-template-columns: 76px 1fr auto;
}

/* Dishes with sizes: name + description get the full width, sizes sit in a row below */
.dish--row.dish--sized {
	grid-template-columns: 1fr;
	align-content: start;
}

.dish--row.dish--sized.has-img {
	grid-template-columns: 76px 1fr;
}

.dish--row.dish--sized .dish__buy {
	grid-column: 1 / -1;
	justify-content: flex-start;
}

.dish--row.dish--sized.has-img .dish__buy {
	grid-column: 2 / -1;
}

.dish--row.dish--sized .variants {
	justify-content: flex-start;
}

.dish--row .dish__media img {
	width: 76px;
	height: 76px;
	object-fit: cover;
	border-radius: var(--r-sm);
}

.dish__name {
	font-family: var(--f-body);
	font-size: var(--fs-md);
	font-weight: 700;
	letter-spacing: 0;
	line-height: 1.3;
}

.dish__desc {
	margin-top: 2px;
	color: var(--muted);
	font-size: var(--fs-sm);
	line-height: 1.45;
}

.dish__flag {
	display: inline-block;
	margin-top: var(--sp-2);
	padding: 0.15em 0.6em;
	border-radius: var(--r-pill);
	background: #fde8e6;
	color: #8c1d13;
	font-size: var(--fs-xs);
	font-weight: 700;
}

.dish.is-off {
	background: #f6f3ea;
}

.dish.is-off .dish__name,
.dish.is-off .dish__price,
.dish.is-off .dish__media {
	opacity: 0.55;
}

.dish__buy {
	display: flex;
	align-items: center;
	gap: var(--sp-3);
	justify-content: flex-end;
}

.dish__price {
	font-family: var(--f-head);
	font-weight: 800;
	font-size: var(--fs-md);
	white-space: nowrap;
}

.add-btn {
	display: inline-flex;
	align-items: center;
	gap: 0.3em;
	min-height: 44px;
	padding: 0.4em 0.95em 0.4em 0.75em;
	border: 2px solid var(--ink);
	border-radius: var(--r-pill);
	background: var(--yellow);
	font-weight: 800;
	font-size: var(--fs-sm);
	transition: background-color 0.15s, transform 0.15s;
}

.add-btn:hover,
.variant-btn:hover {
	background: var(--ink);
	color: var(--yellow);
}

.add-btn:disabled,
.variant-btn:disabled {
	border-color: var(--line-strong);
	background: transparent;
	color: var(--muted);
	cursor: not-allowed;
}

.add-btn.is-added,
.variant-btn.is-added {
	background: var(--teal);
	border-color: var(--teal);
	color: var(--paper);
}

.variants {
	display: flex;
	flex-wrap: wrap;
	justify-content: flex-end;
	gap: var(--sp-2);
}

.variant-btn {
	display: inline-flex;
	align-items: center;
	gap: 0.45em;
	min-height: 44px;
	padding: 0.35em 0.6em 0.35em 0.85em;
	border: 2px solid var(--ink);
	border-radius: var(--r-pill);
	background: var(--paper);
	font-size: var(--fs-sm);
	line-height: 1.1;
	transition: background-color 0.15s;
}

.variant-btn__label {
	font-weight: 600;
}

.variant-btn__price {
	font-weight: 800;
	white-space: nowrap;
}

.variant-btn .icon {
	width: 1.05em;
	height: 1.05em;
}

/* Card layout (home favourites) */
.dish--card {
	grid-template-rows: auto 1fr auto;
	overflow: hidden;
	border: 2px solid var(--ink);
	border-radius: var(--r-lg);
}

.dish--card:hover {
	box-shadow: var(--shadow-pop);
	transform: translate(-3px, -3px);
}

.dish--card {
	transition: transform 0.2s var(--ease), box-shadow 0.2s var(--ease);
}

.dish--card .dish__media {
	aspect-ratio: 4 / 3;
	overflow: hidden;
	border-bottom: 2px solid var(--ink);
	background: var(--yellow-soft);
}

.dish--card .dish__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.5s var(--ease);
}

.dish--card:hover .dish__media img {
	transform: scale(1.05);
}

.dish--card .dish__body {
	padding: var(--sp-4) var(--sp-4) 0;
}

.dish--card .dish__name {
	font-family: var(--f-head);
	font-size: var(--fs-lg);
	font-weight: 800;
}

.dish--card .dish__desc {
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.dish--card .dish__buy {
	justify-content: space-between;
	padding: 0 var(--sp-4) var(--sp-4);
}

.dish--card .dish__buy:has(.variants) {
	padding-top: var(--sp-1);
}

.dish--card .variants {
	display: grid;
	grid-auto-flow: column;
	grid-auto-columns: 1fr;
	width: 100%;
	gap: var(--sp-2);
}

.dish--card .variant-btn {
	flex-direction: column;
	justify-content: center;
	gap: 1px;
	width: 100%;
	min-height: 54px;
	padding: 0.4em 0.3em;
	border-radius: var(--r-md);
	text-align: center;
}

.dish--card .variant-btn__label {
	color: var(--muted);
	font-size: var(--fs-xs);
	text-transform: uppercase;
	letter-spacing: 0.05em;
}

.dish--card .variant-btn:hover .variant-btn__label {
	color: inherit;
}

.dish--card .variant-btn .icon {
	display: none;
}

.dish-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr));
	gap: var(--sp-5);
}

@media (max-width: 600px) {
	.dish--row,
	.dish--row.has-img {
		grid-template-columns: 1fr;
	}
	.dish--row.has-img {
		grid-template-columns: 64px 1fr;
	}
	.dish--row .dish__media img {
		width: 64px;
		height: 64px;
	}
	.dish--row.has-img .dish__buy {
		grid-column: 1 / -1;
	}
	.dish--row .dish__buy {
		justify-content: space-between;
	}
	.dish--row .variants {
		justify-content: flex-start;
	}
}

/* ---------- Branch cards ---------- */
.branch-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr));
	gap: var(--sp-5);
}

.branch-grid--two {
	grid-template-columns: repeat(auto-fill, minmax(min(100%, 420px), 1fr));
}

.branch-grid--three {
	grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr));
}

.branch-card {
	display: flex;
	flex-direction: column;
	overflow: hidden;
	background: var(--paper);
	border: 2px solid var(--ink);
	border-radius: var(--r-lg);
}

.branch-card__media {
	position: relative;
	display: block;
	aspect-ratio: 4 / 3;
	overflow: hidden;
	border-bottom: 2px solid var(--ink);
	background: var(--ink);
}

.branch-card__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.5s var(--ease);
}

.branch-card:hover .branch-card__media img {
	transform: scale(1.04);
}

.branch-card__media .status {
	position: absolute;
	left: var(--sp-3);
	top: var(--sp-3);
	box-shadow: var(--shadow-1);
}

.branch-card__body {
	display: grid;
	gap: var(--sp-2);
	flex: 1;
	align-content: start;
	padding: var(--sp-4);
}

.branch-card__name {
	font-size: var(--fs-xl);
}

.branch-card__name a {
	text-decoration: none;
}

.branch-card__name a:hover {
	text-decoration: underline;
}

.branch-card__body > p {
	display: flex;
	gap: 0.5em;
	color: var(--muted);
	font-size: var(--fs-sm);
	line-height: 1.45;
}

.branch-card__body > p .icon {
	margin-top: 1px;
	color: var(--teal);
}

.branch-card__actions {
	display: flex;
	flex-wrap: wrap;
	gap: var(--sp-2);
	margin-top: var(--sp-3);
}

/* ---------- Footer ---------- */
.site-footer {
	background: var(--ink);
	color: var(--cream);
	padding-top: var(--sp-8);
	font-size: var(--fs-sm);
}

.site-footer__grid {
	display: grid;
	grid-template-columns: 1.4fr repeat(4, 1fr);
	gap: var(--sp-6);
}

.site-footer__brand img {
	width: 200px;
	margin-bottom: var(--sp-4);
}

.site-footer__brand p {
	max-width: 22rem;
	opacity: 0.85;
}

.site-footer__social {
	display: flex;
	gap: var(--sp-2);
	margin-top: var(--sp-4);
}

.site-footer__social a {
	display: grid;
	place-items: center;
	width: 44px;
	height: 44px;
	border: 1.5px solid rgb(255 252 238 / 0.35);
	border-radius: 50%;
}

.site-footer__social a:hover {
	background: var(--yellow);
	color: var(--ink);
}

.site-footer__branch h2 {
	margin-bottom: var(--sp-2);
	color: var(--yellow);
	font-size: var(--fs-md);
}

.site-footer__branch h2 a {
	text-decoration: none;
}

.site-footer__branch p {
	opacity: 0.85;
	margin-bottom: var(--sp-1);
}

.site-footer__hours {
	font-weight: 700;
}

.site-footer__base {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	gap: var(--sp-3);
	margin-top: var(--sp-7);
	padding-block: var(--sp-5) calc(var(--sp-5) + 72px);
	border-top: 1px solid rgb(255 252 238 / 0.18);
	opacity: 0.75;
}

@media (max-width: 980px) {
	.site-footer__grid {
		grid-template-columns: repeat(2, 1fr);
	}
	.site-footer__brand {
		grid-column: 1 / -1;
	}
}

@media (max-width: 520px) {
	.site-footer__grid {
		grid-template-columns: 1fr;
	}
}

/* ---------- Sheets (native <dialog>) ---------- */
.sheet {
	padding: 0;
	border: 0;
	background: var(--cream);
	color: var(--ink);
	box-shadow: var(--shadow-2);
}

.sheet::backdrop {
	background: rgb(35 31 32 / 0.55);
	backdrop-filter: blur(2px);
}

.sheet__head {
	position: sticky;
	top: 0;
	z-index: 1;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: var(--sp-3);
	padding: var(--sp-4) var(--sp-5);
	background: var(--yellow);
	border-bottom: 2px solid var(--ink);
}

.sheet__head h2 {
	font-size: var(--fs-xl);
}

.sheet__lede {
	padding: var(--sp-4) var(--sp-5) 0;
	color: var(--muted);
}

.sheet--center {
	width: min(560px, 100% - 2 * var(--gutter));
	max-height: min(88vh, 760px);
	border: 2px solid var(--ink);
	border-radius: var(--r-lg);
}

.sheet--side {
	position: fixed;
	inset: 0 0 0 auto;
	width: min(460px, 100%);
	max-width: 100%;
	height: 100%;
	max-height: 100%;
	margin: 0;
	border-left: 2px solid var(--ink);
	display: none;
	flex-direction: column;
}

.sheet--side[open] {
	display: flex;
}

@media (prefers-reduced-motion: no-preference) {
	.sheet--side[open] {
		animation: slide-in 0.28s var(--ease);
	}
	.sheet--center[open] {
		animation: pop-in 0.22s var(--ease);
	}
}

@keyframes slide-in {
	from {
		transform: translateX(100%);
	}
}

@keyframes pop-in {
	from {
		transform: translateY(12px) scale(0.98);
		opacity: 0;
	}
}

.branch-options {
	display: grid;
	gap: var(--sp-3);
	padding: var(--sp-4) var(--sp-5) var(--sp-5);
}

.branch-option {
	display: grid;
	gap: 4px;
	justify-items: start;
	width: 100%;
	padding: var(--sp-4);
	border: 2px solid var(--ink);
	border-radius: var(--r-md);
	background: var(--paper);
	text-align: left;
	transition: background-color 0.15s, box-shadow 0.15s;
}

.branch-option:hover {
	box-shadow: 4px 4px 0 var(--ink);
}

.branch-option[aria-pressed="true"] {
	background: var(--yellow);
}

.branch-option__name {
	font-family: var(--f-head);
	font-weight: 800;
	font-size: var(--fs-lg);
}

.branch-option__addr {
	color: var(--muted);
	font-size: var(--fs-sm);
}

.branch-option .status {
	margin-top: 4px;
	background: var(--cream);
	border: 1px solid var(--line);
}

.branch-option__del {
	display: inline-flex;
	align-items: center;
	gap: 0.4em;
	color: var(--teal-dark);
	font-size: var(--fs-sm);
	font-weight: 600;
}

/* ---------- Cart ---------- */
.cart__body {
	flex: 1;
	overflow-y: auto;
	overscroll-behavior: contain;
	padding: var(--sp-4) var(--sp-5) var(--sp-5);
}

.cart__empty {
	display: grid;
	justify-items: center;
	gap: var(--sp-4);
	padding: var(--sp-7) var(--sp-3);
	text-align: center;
}

.cart__empty-icon,
.cart__done-icon {
	display: grid;
	place-items: center;
	width: 72px;
	height: 72px;
	border-radius: 50%;
	background: var(--yellow);
	border: 2px solid var(--ink);
}

.cart__empty-icon .icon,
.cart__done-icon .icon {
	width: 34px;
	height: 34px;
}

.cart__items {
	display: grid;
	gap: var(--sp-2);
}

.cart-item {
	display: grid;
	grid-template-columns: 1fr auto;
	gap: var(--sp-2) var(--sp-3);
	align-items: center;
	padding: var(--sp-3);
	background: var(--paper);
	border: 1.5px solid var(--line);
	border-radius: var(--r-md);
}

.cart-item.is-problem {
	border-color: var(--bad);
	background: #fff4f2;
}

.cart-item__name {
	font-weight: 700;
	line-height: 1.3;
}

.cart-item__meta {
	color: var(--muted);
	font-size: var(--fs-sm);
}

.cart-item__warn {
	grid-column: 1 / -1;
	color: var(--bad);
	font-size: var(--fs-sm);
	font-weight: 700;
}

.cart-item__line {
	font-weight: 800;
	white-space: nowrap;
	text-align: right;
}

.qty {
	grid-column: 1 / -1;
	display: flex;
	align-items: center;
	gap: var(--sp-2);
}

.qty button {
	display: grid;
	place-items: center;
	width: 40px;
	height: 40px;
	padding: 0;
	border: 2px solid var(--ink);
	border-radius: 50%;
	background: var(--paper);
}

.qty button:hover {
	background: var(--yellow);
}

.qty output {
	min-width: 2ch;
	font-weight: 800;
	text-align: center;
}

.qty .qty__remove {
	margin-left: auto;
	width: auto;
	height: 40px;
	padding: 0 var(--sp-3);
	border: 0;
	border-radius: var(--r-pill);
	background: transparent;
	color: var(--muted);
	font-size: var(--fs-sm);
	text-decoration: underline;
}

.cart__form {
	display: grid;
	gap: var(--sp-4);
	margin-top: var(--sp-5);
	padding-top: var(--sp-5);
	border-top: 2px dashed var(--line-strong);
}

.cart__label {
	display: block;
	margin-bottom: var(--sp-2);
	font-weight: 700;
	font-size: var(--fs-sm);
}

.cart__branch-btn {
	display: flex;
	align-items: center;
	gap: var(--sp-3);
	width: 100%;
	padding: var(--sp-3) var(--sp-4);
	border: 2px solid var(--ink);
	border-radius: var(--r-md);
	background: var(--paper);
	text-align: left;
}

.cart__branch-btn > span:nth-child(2) {
	display: grid;
	flex: 1;
	line-height: 1.3;
}

.cart__branch-btn small {
	color: var(--muted);
	font-size: var(--fs-xs);
}

.cart__branch-btn.is-missing {
	border-color: var(--bad);
	background: #fff4f2;
}

.cart__change {
	color: var(--teal);
	font-size: var(--fs-sm);
	font-weight: 700;
	text-decoration: underline;
}

.seg {
	margin: 0;
	padding: 0;
	border: 0;
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: var(--sp-2);
}

.seg legend {
	grid-column: 1 / -1;
	padding: 0;
}

.seg label {
	position: relative;
}

.seg input {
	position: absolute;
	opacity: 0;
	inset: 0;
}

.seg span {
	display: grid;
	place-items: center;
	min-height: 48px;
	padding: var(--sp-2);
	border: 2px solid var(--ink);
	border-radius: var(--r-md);
	background: var(--paper);
	font-weight: 700;
	cursor: pointer;
}

.seg input:checked + span {
	background: var(--ink);
	color: var(--yellow);
}

.seg input:focus-visible + span {
	outline: 3px solid var(--teal);
	outline-offset: 2px;
}

.cart__hint {
	margin-top: calc(-1 * var(--sp-2));
	color: var(--teal-dark);
	font-size: var(--fs-sm);
	font-weight: 600;
}

.cart__hint:empty {
	display: none;
}

.field {
	display: grid;
	gap: var(--sp-1);
}

.field label {
	font-weight: 700;
	font-size: var(--fs-sm);
}

.field .opt {
	color: var(--muted);
	font-weight: 400;
}

.field input,
.field textarea {
	width: 100%;
	min-height: 48px;
	padding: 0.7em 0.9em;
	border: 2px solid var(--line-strong);
	border-radius: var(--r-md);
	background: var(--paper);
	font-size: 16px;
	resize: vertical;
}

.field input:focus,
.field textarea:focus {
	border-color: var(--ink);
	outline: none;
	box-shadow: 0 0 0 3px var(--yellow);
}

.field [aria-invalid="true"] {
	border-color: var(--bad);
}

.hp {
	position: absolute;
	left: -9999px;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

.form-error {
	padding: var(--sp-3) var(--sp-4);
	border-radius: var(--r-md);
	background: #fde8e6;
	color: #8c1d13;
	font-weight: 600;
	font-size: var(--fs-sm);
}

.cart__done {
	display: grid;
	justify-items: center;
	gap: var(--sp-4);
	padding: var(--sp-7) var(--sp-3);
	text-align: center;
}

.cart__done-icon {
	background: var(--wa);
	color: var(--paper);
	border-color: var(--wa);
}

.cart__done h3 {
	font-size: var(--fs-xl);
}

.cart__foot {
	padding: var(--sp-4) var(--sp-5) calc(var(--sp-4) + env(safe-area-inset-bottom));
	background: var(--paper);
	border-top: 2px solid var(--ink);
}

.cart__total {
	display: flex;
	justify-content: space-between;
	align-items: baseline;
	font-weight: 700;
}

.cart__total strong {
	font-family: var(--f-head);
	font-size: var(--fs-xl);
}

.cart__tax {
	margin-bottom: var(--sp-3);
	color: var(--muted);
	font-size: var(--fs-xs);
}

/* ---------- Floating order bar (mobile) + toast ---------- */
.order-bar {
	position: fixed;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: 40;
	padding: var(--sp-3) var(--gutter) calc(var(--sp-3) + env(safe-area-inset-bottom));
	pointer-events: none;
}

.order-bar__btn {
	pointer-events: auto;
	display: flex;
	align-items: center;
	gap: var(--sp-3);
	width: min(520px, 100%);
	min-height: 56px;
	margin-inline: auto;
	padding: var(--sp-2) var(--sp-5) var(--sp-2) var(--sp-2);
	border: 2px solid var(--ink);
	border-radius: var(--r-pill);
	background: var(--ink);
	color: var(--paper);
	font-weight: 700;
	box-shadow: 0 10px 30px -8px rgb(35 31 32 / 0.6);
}

.order-bar__btn strong {
	margin-left: auto;
	color: var(--yellow);
	font-family: var(--f-head);
	font-size: var(--fs-lg);
}

.order-bar__count {
	display: grid;
	place-items: center;
	min-width: 38px;
	height: 38px;
	padding: 0 8px;
	border-radius: var(--r-pill);
	background: var(--yellow);
	color: var(--ink);
	font-weight: 800;
}

/* Desktop has the header Order button with its count; the bar would cover content */
@media (min-width: 861px) {
	.order-bar {
		display: none !important;
	}
}

@media (prefers-reduced-motion: no-preference) {
	.order-bar:not([hidden]) {
		animation: rise 0.3s var(--ease);
	}
}

@keyframes rise {
	from {
		transform: translateY(100%);
	}
}

.toast {
	position: fixed;
	left: 50%;
	bottom: 96px;
	z-index: 60;
	max-width: calc(100% - 2 * var(--gutter));
	padding: var(--sp-3) var(--sp-5);
	border-radius: var(--r-pill);
	background: var(--teal);
	color: var(--paper);
	font-weight: 700;
	font-size: var(--fs-sm);
	box-shadow: var(--shadow-2);
	transform: translate(-50%, 20px);
	opacity: 0;
	pointer-events: none;
	transition: opacity 0.2s, transform 0.2s var(--ease);
}

.toast.is-on {
	opacity: 1;
	transform: translate(-50%, 0);
}

/* ---------- Reveal on scroll ---------- */
@media (prefers-reduced-motion: no-preference) {
	.js [data-reveal] > * {
		opacity: 0;
		transform: translateY(18px);
		transition: opacity 0.5s var(--ease), transform 0.5s var(--ease);
		transition-delay: calc(var(--i, 0) * 60ms);
	}
	.js [data-reveal].is-in > * {
		opacity: 1;
		transform: none;
	}
}

@media (prefers-reduced-motion: reduce) {
	*,
	*::before,
	*::after {
		animation-duration: 0.001ms !important;
		transition-duration: 0.001ms !important;
	}
}
