/**
 * Kronfönster page polish — contact, Snabba Fakta, cart order-info,
 * and a tighter rhythm on kf-* landing pages.
 *
 * Does not change stored copy. Overrides Woodmart custom CSS (which uses
 * !important) only for spacing, cards and the contact form.
 */

:root {
	--kf-navy: #163a55;
	--kf-navy-deep: #112e44;
	--kf-accent: #ffeb34;
	--kf-muted: #6a7a8a;
	--kf-line: #e4eaef;
}

/* ── Landing pages (kontakt, dörrar, …): less empty air, same text ── */

/* Woodmart custom CSS uses `body .entry-content .kf-*` + !important.
   Beat that specificity; do not edit the Woodmart option. */

body .entry-content .kf-page .kf-section,
body .entry-content .kf-page .kf-section-grey,
body .entry-content .kf-page .kf-section-navy {
	padding: 48px 6% !important;
}

body .entry-content .kf-page .kf-intro {
	padding: 40px 8% 32px !important;
}

body .entry-content .kf-page .kf-content-2col,
body .entry-content .kf-page .kf-content-2col-grey {
	padding: 40px 6% !important;
}

body .entry-content .kf-page .kf-section .kf-content-2col,
body .entry-content .kf-page .kf-section .kf-content-2col-grey,
body .entry-content .kf-page .kf-section-grey .kf-content-2col,
body .entry-content .kf-page .kf-section-grey .kf-content-2col-grey {
	padding: 0 !important;
}

body .entry-content .kf-page .kf-section-title {
	margin-bottom: 28px !important;
}

body .entry-content .kf-page .kf-col:empty {
	display: none !important;
}

/* ── Contact: form first, compact card ── */

body.page-id-5091 .entry-content .kf-hero {
	height: 260px !important;
	margin-top: 0 !important;
}

body.page-id-5091 .entry-content #kontaktformulär {
	position: relative;
	z-index: 2;
	margin-top: -24px;
}

body.page-id-5091 .entry-content #kontaktformulär .kf-section {
	padding: 0 6% 28px !important;
	background: transparent !important;
}

body.page-id-5091 .entry-content #kontaktformulär .kf-section > div {
	max-width: 860px !important;
	margin: 0 auto !important;
	background: #fff;
	border: 1px solid var(--kf-line);
	border-radius: 8px;
	padding: 24px 28px 22px;
	box-shadow: 0 8px 24px rgba(22, 58, 85, 0.06);
}

body.page-id-5091 .entry-content #kontaktformulär .kf-section > div > div:first-child {
	margin-bottom: 16px !important;
	text-align: center !important;
}

body.page-id-5091 .entry-content #kontaktformulär h2 {
	margin: 0 0 6px !important;
	font-size: 22px !important;
	letter-spacing: 0.02em;
	color: var(--kf-navy) !important;
}

body.page-id-5091 .entry-content #kontaktformulär p {
	margin: 0 !important;
	color: var(--kf-muted);
	font-size: 14px;
	line-height: 1.5;
}

body.page-id-5091 .entry-content .wpcf7 form {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 12px 18px;
	margin: 0;
}

body.page-id-5091 .entry-content .wpcf7 form > p {
	margin: 0 !important;
}

body.page-id-5091 .entry-content .wpcf7 form > *:not(p) {
	grid-column: 1 / -1;
}

body.page-id-5091 .entry-content .wpcf7 form > p:has(textarea),
body.page-id-5091 .entry-content .wpcf7 form > p:has([type="submit"]),
body.page-id-5091 .entry-content .wpcf7 form > p:has(input[name="your-subject"]),
body.page-id-5091 .entry-content .wpcf7 form > p:nth-of-type(n+5),
body.page-id-5091 .entry-content .wpcf7-response-output {
	grid-column: 1 / -1;
}

body.page-id-5091 .entry-content .wpcf7 label {
	display: block;
	font-size: 12px;
	font-weight: 600;
	color: #4a5a6a;
	letter-spacing: 0.01em;
}

body.page-id-5091 .entry-content .wpcf7 input[type="text"],
body.page-id-5091 .entry-content .wpcf7 input[type="email"],
body.page-id-5091 .entry-content .wpcf7 input[type="tel"],
body.page-id-5091 .entry-content .wpcf7 select,
body.page-id-5091 .entry-content .wpcf7 textarea {
	width: 100%;
	margin-top: 5px;
	padding: 9px 12px;
	border: 1px solid #d5dee6;
	border-radius: 6px;
	font-size: 15px;
	line-height: 1.35;
	background: #fff;
}

body.page-id-5091 .entry-content .wpcf7 textarea {
	min-height: 110px;
	resize: vertical;
}

body.page-id-5091 .entry-content .wpcf7 input[type="submit"],
body.page-id-5091 .entry-content .wpcf7 .wpcf7-submit {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	margin-top: 4px;
	padding: 10px 28px;
	background: var(--kf-navy);
	color: #fff;
	border: none;
	border-radius: 999px;
	font-size: 14px;
	font-weight: 700;
	letter-spacing: 0.04em;
	cursor: pointer;
}

body.page-id-5091 .entry-content .wpcf7 input[type="submit"]:hover,
body.page-id-5091 .entry-content .wpcf7 .wpcf7-submit:hover {
	background: var(--kf-navy-deep);
}

body.page-id-5091 .entry-content .wpcf7-response-output {
	display: block !important;
	margin: 4px 0 0 !important;
	padding: 10px 14px !important;
	border-radius: 6px;
	font-size: 14px;
}

body.page-id-5091 .entry-content .wpcf7 form.sent .wpcf7-response-output {
	border-color: #163a55;
}

@media (max-width: 767px) {
	body.page-id-5091 .entry-content .kf-hero {
		height: 180px !important;
	}

	body.page-id-5091 .entry-content .kf-fw div[style*="flex:1 1 200px"] {
		padding: 12px 20px !important;
		gap: 2px !important;
	}

	body.page-id-5091 .entry-content .wpcf7 form {
		grid-template-columns: 1fr;
	}

	body.page-id-5091 .entry-content #kontaktformulär .kf-section > div {
		padding: 20px 16px 18px;
	}

	body.page-id-5091 .entry-content #kontaktformulär .kf-section > div > div:first-child {
		text-align: center !important;
	}

	body .entry-content .kf-page .kf-section,
	body .entry-content .kf-page .kf-section-grey,
	body .entry-content .kf-page .kf-section-navy {
		padding: 32px 5% !important;
	}

	body .entry-content .kf-page .kf-intro {
		padding: 28px 5% 22px !important;
	}
}

/* /fonster/: Woodmart custom CSS shrinks .kf-hero to 210px on phones,
   which hides the house photo behind the title pill. Taller crop only;
   stored copy is unchanged. */
@media (max-width: 860px) {
	body.page-id-118916 .entry-content .kf-hero {
		height: 360px !important;
		background-position: center 42% !important;
	}

	body.page-id-118916 .entry-content .kf-hero-title {
		padding: 12px 28px !important;
	}
}

@media (max-width: 480px) {
	body.page-id-118916 .entry-content .kf-hero {
		height: 300px !important;
	}

	body.page-id-118916 .entry-content .kf-hero-title {
		top: 12px !important;
		padding: 10px 20px !important;
	}

	body.page-id-118916 .entry-content .kf-hero-title h1 {
		font-size: 20px !important;
		letter-spacing: 0.06em !important;
	}
}

/* ── Snabba Fakta card (Kron sidebar, homepage, shortcode) ── */

.kf-facts-card,
.kron-sidebar-card.kf-facts-card {
	background: #fff;
	border-radius: 12px;
	overflow: hidden;
	box-shadow: 0 10px 30px rgba(22, 58, 85, 0.08);
	border: 1px solid rgba(22, 58, 85, 0.05);
}

.kf-facts-map {
	position: relative;
	height: 160px;
	overflow: hidden;
	background: #d8e2ea;
}

.kf-facts-map img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.kf-facts-map-btn,
a.kron-sidebar-map-btn {
	position: absolute;
	bottom: 14px;
	left: 14px;
	background: var(--kf-accent);
	color: var(--kf-navy) !important;
	padding: 8px 15px;
	font-size: 11px;
	font-weight: 800;
	border-radius: 4px;
	text-decoration: none !important;
	letter-spacing: 0.04em;
}

.kf-facts-map-btn:hover,
a.kron-sidebar-map-btn:hover {
	background: #f5d400;
	color: var(--kf-navy) !important;
}

.kf-facts-body {
	padding: 22px 22px 24px;
}

.kf-facts-title,
.kf-facts-card .kron-page-title-small {
	font-weight: 800 !important;
	color: var(--kf-navy) !important;
	text-transform: uppercase !important;
	font-size: 16px !important;
	margin: 0 0 14px !important;
	letter-spacing: 0.04em;
}

.kf-facts-notice {
	margin: 0 0 14px !important;
	padding: 10px 12px 10px 14px;
	background: #f4f6f8;
	border-left: 4px solid var(--kf-accent);
	color: var(--kf-navy) !important;
	font-size: 13px;
	line-height: 1.45;
}

.kf-facts-links {
	list-style: none;
	margin: 0 0 18px !important;
	padding: 0;
}

.kf-facts-links li {
	margin: 0 0 8px;
	padding: 0;
}

.kf-facts-links a {
	color: var(--kf-navy);
	text-decoration: none;
	font-size: 14px;
	font-weight: 600;
}

.kf-facts-links a:hover {
	text-decoration: underline;
}

.kf-facts-hours,
.sidebar-hours-box {
	background: var(--kf-navy);
	padding: 20px 22px;
	border-radius: 10px;
	color: #fff !important;
}

.kf-facts-hours p,
.sidebar-hours-box p {
	color: #fff !important;
	margin: 0 0 6px !important;
	font-size: 14px;
}

.kf-facts-hours-label,
.hours-label {
	font-size: 10px !important;
	text-transform: uppercase;
	letter-spacing: 0.12em;
	opacity: 0.65;
	margin-bottom: 10px !important;
}

.kf-facts-welcome {
	margin-top: 12px !important;
	padding-top: 12px;
	border-top: 1px solid rgba(255, 255, 255, 0.12);
	font-style: italic;
	opacity: 0.85;
	font-size: 13px !important;
}

.kron-sidebar-area .kf-facts-card {
	position: sticky;
	top: 100px;
}

/*
 * Kron Master (template-kron-master.php) — 161 series/legal landings.
 * Woodmart Additional CSS still prints the flex shell with a transparent
 * content column. Keep the shell, but give WPBakery a white well so the
 * builder rows, images and Everest galleries sit on a card next to Snabba Fakta.
 */
html body .kron-page-wrapper {
	background-color: #f4f7f9 !important;
	padding: 24px 0 48px !important;
}

html body .kron-page-wrapper .kron-main-container {
	margin: 0 auto;
	padding: 0 20px;
	max-width: 1400px !important;
	display: flex !important;
	gap: 36px !important;
	align-items: stretch;
}

html body .kron-page-wrapper .kron-content-card {
	flex: 2.5 1 0% !important;
	min-width: 0;
	background: #fff !important;
	padding: 22px 26px 32px !important;
	border: 1px solid rgba(22, 58, 85, 0.06) !important;
	border-radius: 12px;
	box-shadow: 0 10px 30px rgba(22, 58, 85, 0.06) !important;
}

html body .kron-page-wrapper .kron-sidebar-area {
	flex: 1 1 0% !important;
	min-width: 280px;
	max-width: 360px;
}

.kron-page-wrapper .kron-content-card > .vc_row,
.kron-page-wrapper .kron-content-card > .wpb-content-wrapper > .vc_row {
	margin-left: 0 !important;
	margin-right: 0 !important;
}

.kron-page-wrapper .kron-content-card .wpb_single_image .vc_single_image-wrapper {
	background: #eef2f5;
	border-radius: 8px;
	overflow: hidden;
	min-height: 160px;
}

.kron-page-wrapper .kron-content-card .wpb_single_image img {
	opacity: 1 !important;
}

/* Leftover empty WPBakery columns (not spacers — those contain .vc_empty_space). */
.kron-page-wrapper .kron-content-card .wpb_column:not(:has(img, iframe, video, svg, canvas, picture, .wpb_text_column, .wpb_single_image, .wpb_video_widget, .vc_btn3, .wpb_gallery, .eg-wrap, .wpb_raw_html, .vc_empty_space, p, h1, h2, h3, h4, h5, ul, ol, table, form)) {
	display: none !important;
}

@media (max-width: 1024px) {
	.kron-sidebar-area .kf-facts-card {
		position: static;
	}

	html body .kron-page-wrapper .kron-main-container {
		flex-wrap: wrap;
		gap: 28px !important;
	}

	html body .kron-page-wrapper .kron-sidebar-area {
		flex: 1 1 100% !important;
		min-width: 0 !important;
		max-width: 420px;
	}

	html body .kron-page-wrapper .kron-content-card {
		padding: 18px 16px 24px !important;
	}
}

/* Homepage band */

.kf-home-facts {
	background: #f4f7f9;
	padding: 36px 24px 48px;
}

.kf-home-facts-inner {
	max-width: 1240px;
	margin: 0 auto;
}

.kf-home-facts .kf-facts-card {
	max-width: 400px;
	position: static;
}

@media (max-width: 767px) {
	.kf-home-facts {
		padding: 24px 16px 32px;
	}

	.kf-home-facts .kf-facts-card {
		max-width: none;
	}
}

/* ── Cart: Information om order ── */

.kf-order-info {
	background: #fff;
	border: 1px solid var(--kf-line);
	border-left: 4px solid var(--kf-navy);
	border-radius: 8px;
	padding: 18px 22px 16px;
	margin: 0 0 22px;
	box-shadow: 0 6px 18px rgba(22, 58, 85, 0.05);
}

.kf-order-info-title {
	margin: 0 0 8px !important;
	font-size: 15px !important;
	font-weight: 800 !important;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	color: var(--kf-navy) !important;
}

.kf-order-info-body {
	font-size: 14px;
	line-height: 1.65;
	color: #3a4a5a;
}

.kf-order-info-body p {
	margin: 0 0 0.7em;
}

.kf-order-info-body p:last-child {
	margin-bottom: 0;
}

/* Kron Master content: keep WPBakery readable next to the card */
.kron-page-wrapper .kron-content-card img {
	max-width: 100%;
	height: auto;
}

.kron-page-wrapper .blue-heading-h1 {
	margin-top: 0;
}

/* ── /dorrar/ytterdorrar/ (page 212487): full door in an even grid ──
   Woodmart custom CSS uses body .entry-content .kf-prod-imgbox { height: 260px;
   object-fit: cover } which crops portrait door photos to a zoomed strip.
   Flatten mixed 2/4-col rows into one 4-col grid; show the whole door. */

body.page-id-212487 .entry-content .kf-section-grey {
	display: grid !important;
	grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
	gap: 22px !important;
	align-items: stretch !important;
}

body.page-id-212487 .entry-content .kf-section-grey > .kf-section-title {
	grid-column: 1 / -1 !important;
	margin-bottom: 8px !important;
}

body.page-id-212487 .entry-content .kf-section-grey > .kf-row {
	display: contents !important;
	margin: 0 !important;
	gap: 0 !important;
}

body.page-id-212487 .entry-content .kf-section-grey > .kf-row > .kf-col {
	width: auto !important;
	max-width: none !important;
	flex: none !important;
	min-width: 0 !important;
}

body.page-id-212487 .entry-content .kf-prod-imgbox {
	height: auto !important;
	aspect-ratio: 3 / 4 !important;
	background: #eef2f5 !important;
}

body.page-id-212487 .entry-content .kf-prod-imgbox img {
	object-fit: contain !important;
	object-position: center center !important;
	padding: 10px 8px !important;
	box-sizing: border-box !important;
	transform: none !important;
}

body.page-id-212487 .entry-content .kf-prod-card:hover .kf-prod-imgbox img {
	transform: none !important;
}

body.page-id-212487 .entry-content .kf-prod-body {
	padding: 16px 16px 18px !important;
}

body.page-id-212487 .entry-content .kf-prod-body h3 {
	font-size: 16px !important;
	line-height: 1.3 !important;
	min-height: 2.5em;
	margin-bottom: 12px !important;
}

body.page-id-212487 .entry-content .kf-prod-body .kf-btns {
	margin-top: auto;
}

body.page-id-212487 .entry-content .kf-prod-body .kf-btn {
	width: 100%;
	text-align: center;
	box-sizing: border-box;
}

@media (max-width: 1100px) {
	body.page-id-212487 .entry-content .kf-section-grey {
		grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
	}
}

@media (max-width: 767px) {
	body.page-id-212487 .entry-content .kf-section-grey {
		grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
		gap: 14px !important;
	}

	body.page-id-212487 .entry-content .kf-prod-body {
		padding: 12px 12px 14px !important;
	}

	body.page-id-212487 .entry-content .kf-prod-body h3 {
		font-size: 14px !important;
		min-height: 2.4em;
	}
}

@media (max-width: 420px) {
	body.page-id-212487 .entry-content .kf-section-grey {
		grid-template-columns: 1fr !important;
	}
}

/* ── Enquiry pages: Tillbaka till våra ytterdörrar ── */

.kf-ytterdorrar-back.vc_btn3-container {
	max-width: 720px;
	margin: 8px auto 28px !important;
}

.kf-ytterdorrar-back a.vc_btn3,
a.kf-ytterdorrar-back {
	display: inline-flex !important;
	align-items: center;
	justify-content: center;
	gap: 8px;
	width: 100%;
	background: #f4f6f8 !important;
	color: #163a55 !important;
	border: 1px solid #d5dee6 !important;
	border-radius: 6px !important;
	box-shadow: none !important;
	font-weight: 600 !important;
	letter-spacing: 0.02em;
	text-transform: none !important;
	text-decoration: none !important;
}

.kf-ytterdorrar-back a.vc_btn3::before {
	content: "←";
	font-size: 1.05em;
	line-height: 1;
}

.kf-ytterdorrar-back a.vc_btn3:hover,
.kf-ytterdorrar-back a.vc_btn3:focus-visible {
	background: #163a55 !important;
	color: #fff !important;
	border-color: #163a55 !important;
}

/* ── /alla-produkter/ ──
   The page is nine [product_categories] grids under plain headings. It had no
   H1 and used &nbsp; paragraphs as spacing; both are gone from the content, so
   the rhythm is set here instead. Woodmart already styles the tiles. */
.page-id-21740 .entry-content > h1 {
	margin: 0 0 10px;
	font-size: clamp(26px, 3vw, 36px);
	color: var(--kf-navy);
}

.page-id-21740 .entry-content > .kf-allprod-intro {
	max-width: 62ch;
	margin: 0 0 8px;
	color: var(--kf-muted);
	font-size: 15px;
	line-height: 1.65;
}

.page-id-21740 .entry-content > h2 {
	margin: 48px 0 18px;
	padding-bottom: 10px;
	border-bottom: 1px solid var(--kf-line);
	font-size: clamp(19px, 1.8vw, 23px);
	color: var(--kf-navy);
}

/* Woodmart gives each grid a bottom margin of its own; without this the gap
   before the next heading reads as a hole in the page. */
.page-id-21740 .entry-content .wd-products,
.page-id-21740 .entry-content ul.products {
	margin-bottom: 0 !important;
}

@media (max-width: 767px) {
	.page-id-21740 .entry-content > h2 {
		margin-top: 36px;
	}
}

/* Contact / showroom navy strips: keep the full e-mail visible. */
body .entry-content .kf-fw a[href^="mailto:"] {
	font-size: 16px !important;
	line-height: 1.35 !important;
	overflow-wrap: anywhere;
	word-break: break-word;
	white-space: normal !important;
}
