/*
 * Prices, set like a printed sheet: the groups on the left, the list, one photograph.
 * Only the underline of the group being read changes.
 */
.wpr {
	--wpr-ink: var(--wp--preset--color--contrast);
	--wpr-rule: color-mix(in srgb, var(--wpr-ink) 16%, transparent);
	--wpr-top: calc(var(--wauw-header) + var(--wp-admin--admin-bar--height, 0px));
	--wpr-nav: 3.25rem;
	--wpr-h2: clamp(1.75rem, 2.6vw, 2.4rem);
	color: var(--wpr-ink);
	font-variant-numeric: lining-nums tabular-nums;
}
.wpr :is(ul, p, figure, h1, h2, h3) { margin: 0; }
.wpr ul { padding: 0; list-style: none; }
.wpr :is(h1, h2, h3) { color: var(--wpr-ink); font-family: var(--wx-display); font-weight: 400; text-wrap: balance; }
.wpr :focus-visible { outline: 2px solid var(--wpr-ink); outline-offset: 3px; }

.wpr :is(.wpr-title, .wpr-intro, .wpr-list) { padding-inline: var(--wauw-gutter); }

.wpr-photo { overflow: hidden; background: var(--wx-ink); }
.wpr-photo img { display: block; width: 100%; height: auto; aspect-ratio: 2 / 1; object-fit: cover; object-position: 50% 62%; }

.wpr .wpr-title { padding-top: 1.9rem; font-size: var(--wx-title); line-height: 1.1; letter-spacing: -0.02em; }
.wpr-intro p { max-width: 32rem; margin-top: 0.85rem; font-size: 1.0625rem; font-weight: 500; line-height: 1.55; }
.wpr-act { display: flex; flex-wrap: wrap; gap: 0.5rem 1.75rem; align-items: center; margin-top: 1.4rem; }
.wpr .wx-btn { text-decoration: none; }
.wpr-link { color: inherit; text-decoration: underline 1px; text-underline-offset: 0.3em; white-space: nowrap; }
.wpr-group p .wpr-link { padding-block: 0.75rem; }
.wpr-call { display: inline-flex; align-items: center; min-height: 3rem; font-size: 1rem; font-weight: 600; }
:is(.wpr-link, .wpr-nav a):hover { text-decoration-thickness: 2px; }

/* ---------- Groups: one row of words on a phone ---------- */
.wpr-nav { position: sticky; top: var(--wpr-top); z-index: 10; margin-top: 1.75rem; background: var(--wp--preset--color--base); box-shadow: inset 0 -1px var(--wpr-rule); }
.wpr-nav ul { display: flex; gap: 1.5rem; padding-inline: var(--wauw-gutter); overflow-x: auto; overscroll-behavior-x: contain; scrollbar-width: none; transition: opacity 0.16s; }
.wpr-nav ul::-webkit-scrollbar { display: none; }
.wpr-nav ul.is-turning { opacity: 0; }
.wpr-nav a { display: flex; align-items: center; min-height: var(--wpr-nav); color: inherit; font-size: 1rem; font-weight: 500; line-height: 1.3; text-decoration: underline 1px transparent; text-underline-offset: 0.45em; white-space: nowrap; transition: text-decoration-color 0.2s; }
.wpr-nav a:is(:hover, [aria-current]) { text-decoration-color: currentColor; }
.wpr-nav a:focus-visible { outline-offset: -4px; }

/* ---------- The list ---------- */
.wpr-list { padding-block: 2.25rem clamp(3.5rem, 7vw, 6.5rem); }
.wpr-group { scroll-margin-top: calc(var(--wpr-top) + var(--wpr-nav) + 1.75rem); }
.wpr-group + .wpr-group { margin-top: clamp(3rem, 5vw, 4.5rem); }
.wpr-group h2 { padding-bottom: 0.85rem; box-shadow: inset 0 -1px var(--wpr-ink); font-size: var(--wpr-h2); line-height: 1.1; letter-spacing: -0.01em; }
.wpr-rows li { display: flex; gap: 1.5rem; align-items: baseline; justify-content: space-between; padding: 0.75rem 0; border-bottom: 1px solid var(--wpr-rule); font-size: 1.0625rem; font-weight: 500; line-height: 1.4; }
.wpr-rows span { text-wrap: balance; }
.wpr-rows span:last-child { flex: none; font-family: var(--wx-display); font-size: 1.25rem; line-height: 1; white-space: nowrap; }
/* Crowns are written the Faroese way; the students' rows are percentages. */
.wpr-group:not(#naemingar) .wpr-rows span:last-child:not(:empty)::after { content: ",-"; content: ",-" / ""; }
/* The salon lists this one without a price. */
.wpr-rows span:last-child:empty::after { content: "Ring"; }
.wpr-note { max-width: 36rem; padding-top: 0.9rem; font-size: 1rem; font-weight: 500; line-height: 1.55; text-wrap: pretty; }
.wpr-group h3 { margin-top: 2.25rem; font-size: clamp(1.3rem, 1.7vw, 1.5rem); line-height: 1.2; }
.wpr-group h3 + p { padding: 0.5rem 0 0.9rem; box-shadow: inset 0 -1px var(--wpr-ink); font-size: 1.0625rem; font-weight: 500; line-height: 1.5; }
.wpr-list > .wpr-act { margin-top: clamp(2.25rem, 4vw, 3.25rem); }

/* ---------- Room for a column: the groups stand beside the list ---------- */
@media (min-width: 44rem) {
	.wpr { --wpr-nav: 0rem; }
	.wpr-sheet { display: grid; grid-template-columns: 11.5rem minmax(0, 1fr); grid-template-areas: "photo photo" "title intro" "nav list"; column-gap: clamp(2rem, 4.5vw, 4.5rem); padding-inline: var(--wauw-gutter); }
	.wpr :is(.wpr-title, .wpr-intro, .wpr-list) { padding-inline: 0; }
	.wpr-photo { grid-area: photo; margin-inline: calc(var(--wauw-gutter) * -1) !important; }
	.wpr-photo img { aspect-ratio: 5 / 2; }
	.wpr .wpr-title { grid-area: title; align-self: baseline; padding-top: clamp(2.5rem, 5vw, 4.5rem); }
	.wpr-intro { grid-area: intro; align-self: baseline; }
	.wpr-intro p { margin-top: 0; }
	.wpr-nav { grid-area: nav; align-self: baseline; top: calc(var(--wpr-top) + 2rem); margin-top: 0; background: none; box-shadow: none; }
	.wpr-nav ul { display: block; padding: 0; overflow: visible; }
	.wpr-nav li { display: flex; }
	.wpr-nav a { min-height: 2.75rem; }
	.wpr-nav a:focus-visible { outline-offset: 2px; }
	.wpr-list { grid-area: list; align-self: baseline; padding-top: clamp(2.75rem, 4.5vw, 4rem); }
	/* A chosen group stops with its name on the line of the first word beside it. */
	.wpr-group { scroll-margin-top: calc(var(--wpr-top) + 3.74rem - 0.865 * var(--wpr-h2)); }
}

/* ---------- Room for the photograph beside the list ---------- */
@media (min-width: 1100px) {
	.wpr-sheet { grid-template-columns: 12rem minmax(0, 40rem) minmax(20rem, 1fr); grid-template-areas: "title intro photo" "nav list photo"; grid-template-rows: auto 1fr; column-gap: clamp(2.75rem, 4.6vw, 4.75rem); padding-inline: max(var(--wauw-gutter), calc((100% - 96rem) / 2)) 0; }
	.wpr-photo { position: sticky; top: var(--wpr-top); align-self: start; height: calc(100svh - var(--wpr-top)); margin: 0 !important; }
	.wpr-photo img { height: 100%; aspect-ratio: auto; object-position: 69% 50%; }
}
@media (min-width: 1360px) {
	.wpr-sheet { grid-template-columns: 14rem minmax(0, 40rem) minmax(22rem, 1fr); }
}
@media (min-width: 1700px) {
	.wpr-sheet { grid-template-columns: 16rem minmax(0, 44rem) minmax(22rem, 1fr); }
}

@media (prefers-reduced-motion: reduce) {
	.wpr * { transition: none !important; }
}
