/**
 * The terms page.
 *
 * A reading page, so the only real decisions are measure and rhythm: the
 * column is held near 65 characters and the headings are far enough apart that
 * the sections read as separate promises rather than one wall of conditions.
 *
 * Logical properties throughout, so the Arabic build mirrors from `dir="rtl"`.
 */

.grv-terms {
	min-height: 100vh;
	min-height: 100dvh;
	display: flex;
	flex-direction: column;
	background: var(--grv-cream);
	color: var(--grv-ink);
}

.grv-terms-bar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	width: 100%;
	max-width: var(--grv-max);
	margin-inline: auto;
	padding: 18px var(--grv-gutter);
}

.grv-terms-logo img {
	display: block;
	height: 34px;
	width: auto;
}

.grv-terms-bar-side {
	display: flex;
	align-items: center;
	gap: 10px;
}

.grv-terms-order {
	padding: 9px 18px;
	border-radius: 100px;
	background: var(--grv-ink);
	color: var(--grv-cream);
	font-size: 13.5px;
	font-weight: 600;
	white-space: nowrap;
}

.grv-terms-order:hover {
	background: #16130e;
}

.grv-terms-body {
	flex: 1;
	width: 100%;
	max-width: 720px;
	margin-inline: auto;
	padding: clamp(20px, 5vw, 56px) var(--grv-gutter) 100px;
}

.grv-terms-title {
	font-family: var(--grv-serif);
	font-weight: 600;
	font-size: clamp(38px, 6vw, 58px);
	line-height: 1.06;
	margin: 8px 0 14px;
}

.grv-terms-lede {
	font-size: 17px;
	line-height: 1.7;
	color: var(--grv-body);
	margin: 0 0 34px;
	max-width: 60ch;
}

/* ------------------------------------------------------------------- toc */

.grv-terms-toc {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	padding: 18px 0 30px;
	border-block: 1px solid rgba(110, 99, 71, 0.16);
	margin-bottom: 8px;
	padding-block-start: 18px;
}

.grv-terms-toc a {
	padding: 7px 14px;
	border-radius: 100px;
	background: rgba(110, 99, 71, 0.08);
	font-size: 14px;
	font-weight: 500;
	color: var(--grv-muted);
	white-space: nowrap;
	transition: background 0.25s, color 0.25s;
}

.grv-terms-toc a:hover {
	background: rgba(190, 115, 80, 0.15);
	color: var(--grv-clay);
}

.grv-terms-toc a:focus-visible {
	outline: 2px solid var(--grv-clay);
	outline-offset: 2px;
}

/* -------------------------------------------------------------- sections */

.grv-terms-section {
	padding-block-start: 40px;
	/* An anchor jump should not tuck the heading under the top of the window. */
	scroll-margin-block-start: 24px;
}

.grv-terms-section h2 {
	font-family: var(--grv-serif);
	font-weight: 600;
	font-size: clamp(26px, 3.6vw, 34px);
	line-height: 1.16;
	margin: 0 0 14px;
}

.grv-terms-section h3 {
	font-size: 15px;
	font-weight: 600;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: var(--grv-muted);
	margin: 28px 0 10px;
}

.grv-terms-section p {
	font-size: 16.5px;
	line-height: 1.75;
	color: var(--grv-body);
	margin: 0 0 16px;
	max-width: 65ch;
}

.grv-terms-section ul {
	margin: 0 0 16px;
	padding: 0;
	list-style: none;
	max-width: 65ch;
}

.grv-terms-section li {
	position: relative;
	padding-inline-start: 22px;
	margin-bottom: 11px;
	font-size: 16.5px;
	line-height: 1.7;
	color: var(--grv-body);
}

/* A leaf-coloured marker rather than a disc: the page is a list of promises,
   and the café's own green is what the rest of the site marks things with. */
.grv-terms-section li::before {
	content: "";
	position: absolute;
	inset-inline-start: 2px;
	inset-block-start: 0.62em;
	inline-size: 6px;
	block-size: 6px;
	border-radius: 50%;
	background: var(--grv-leaf);
}

.grv-terms-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
	margin-top: 6px;
}

/* The outline button is built for a dark ground; on cream it needs its own ink. */
.grv-terms-wa {
	background: transparent;
	color: var(--grv-ink);
	border-color: rgba(110, 99, 71, 0.4);
	backdrop-filter: none;
	-webkit-backdrop-filter: none;
}

.grv-terms-wa:hover {
	background: rgba(110, 99, 71, 0.08);
}

.grv-terms-updated {
	margin: 54px 0 0;
	padding-top: 20px;
	border-top: 1px solid rgba(110, 99, 71, 0.16);
	font-size: 13.5px;
	color: var(--grv-soft);
}

@media (prefers-reduced-motion: reduce) {
	.grv-terms * {
		transition-duration: 0.01ms !important;
	}
}
