/* Lysbro: only what theme.json cannot express. */

:root { --lysbro-radius: 14px; --lysbro-shadow: 0 18px 40px -24px rgb(20 32 43 / .45); }

body { -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
h1, h2, h3 { font-optical-sizing: auto; text-wrap: balance; }
p { text-wrap: pretty; }

/* Focus: visible on every surface (glød on dark, natt on light) */
:where(a, button, input, select, textarea, summary, [tabindex]):focus-visible {
	outline: 3px solid var(--wp--preset--color--glod);
	outline-offset: 3px;
	border-radius: 4px;
}
:where(.is-style-natt, .lysbro-hero) :focus-visible { outline-color: var(--wp--preset--color--glod); }

/* Concept bar */
.lysbro-konsept { font-size: var(--wp--preset--font-size--liten); }
.lysbro-konsept a { color: inherit; }
.lysbro-konsept strong { color: var(--wp--preset--color--glod); letter-spacing: .04em; }

/* Header */
.lysbro-header .wp-block-navigation a { text-decoration: none; }
.lysbro-header .wp-block-navigation a:hover { text-decoration: underline; text-underline-offset: 6px; }
.lysbro-logo { display: inline-flex; align-items: center; gap: .6rem; text-decoration: none; color: inherit; }
.lysbro-logo svg { width: 34px; height: 34px; flex: none; }

/* Group styles */
.is-style-kort {
	background: var(--wp--preset--color--kvit);
	border: 1px solid var(--wp--preset--color--linje);
	border-radius: var(--lysbro-radius);
	padding: clamp(1.25rem, 1rem + 1vw, 2rem);
}
.is-style-natt { background: var(--wp--preset--color--natt); color: var(--wp--preset--color--papir); }
.is-style-natt :where(h1, h2, h3, h4) { color: var(--wp--preset--color--kvit); }
.is-style-natt a:where(:not(.wp-element-button)) { color: var(--wp--preset--color--kvit); }
.is-style-natt a:where(:not(.wp-element-button)):hover { color: var(--wp--preset--color--glod); }

.wp-block-button.is-style-kontur .wp-block-button__link {
	background: transparent; color: currentColor; box-shadow: inset 0 0 0 2px currentColor;
}
.wp-block-button.is-style-kontur .wp-block-button__link:hover { color: var(--wp--preset--color--glod); }

.is-style-avrunda img, .lysbro-rounded img { border-radius: var(--lysbro-radius); }

/* Hero: text on a dark gradient over the photo, contrast independent of the image */
.lysbro-hero .wp-block-cover__background { background: linear-gradient(90deg, rgb(20 32 43 / .92) 0%, rgb(20 32 43 / .72) 45%, rgb(20 32 43 / .15) 100%) !important; opacity: 1 !important; }
.lysbro-hero h1 { max-width: 13ch; color: var(--wp--preset--color--kvit); }
.lysbro-hero .lysbro-eyebrow { color: var(--wp--preset--color--glod); }

.lysbro-eyebrow {
	font-family: var(--wp--preset--font-family--instrument);
	font-size: var(--wp--preset--font-size--liten);
	font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
	color: var(--wp--preset--color--glod-mork);
}
.is-style-natt .lysbro-eyebrow { color: var(--wp--preset--color--glod); }

/* Steps */
.lysbro-steg { counter-reset: steg; }
.lysbro-steg > .wp-block-column { counter-increment: steg; position: relative; padding-top: 3.25rem; }
.lysbro-steg > .wp-block-column::before {
	content: counter(steg); position: absolute; top: 0; left: 0;
	width: 2.4rem; height: 2.4rem; border-radius: 50%;
	display: grid; place-items: center;
	background: var(--wp--preset--color--glod); color: var(--wp--preset--color--natt);
	font-weight: 700; font-family: var(--wp--preset--font-family--fraunces);
}

/* Footer */
.lysbro-footer a { color: inherit; }
.lysbro-footer .lysbro-credits { font-size: var(--wp--preset--font-size--liten); color: #C9C3B8; }

@media (prefers-reduced-motion: reduce) { * { scroll-behavior: auto !important; transition: none !important; } }

/* Full-width sections sit flush against each other */
.wp-block-post-content > .alignfull { margin-block: 0; }
.wp-block-post-content > .alignfull + .alignfull { margin-top: 0; }

/* Hero content aligns with the rest of the page */
.wp-block-cover.lysbro-hero { padding-inline: clamp(1rem, 4vw, 2.5rem) !important; }
.wp-block-cover.lysbro-hero > .wp-block-cover__inner-container { width: 100% !important; max-width: 76rem; margin-inline: auto !important; padding: 0; }
.lysbro-hero .wp-block-cover__inner-container > * { max-width: 40rem; }

.lysbro-footer ul { list-style: none; padding: 0; display: grid; gap: .5rem; }

/* Template parts and main sit flush */
.wp-site-blocks > * { margin-block: 0; }
.lysbro-hero .wp-block-cover__inner-container > * { margin-left: 0 !important; margin-right: auto !important; }
.wp-block-group.is-layout-grid { gap: 1.25rem; }
