/*
 * AgroLatvija shared page template ("alc"): everything the pages built on it have in common.
 * Green band, section links, sections, phone accordion, cards, note box, buttons, form fields, focus.
 * Used by the contact page, the privacy policy and the cookie policy.
 *
 * Desktop  >= 1025px
 * Tablet   769-1024
 * Phone    <= 768px   one-section-open accordion
 * Small    <= 575px   single-column form fields
 *
 * Selectors start with #alc-page so they win over Woodmart's global
 * button / input / table rules without !important.
 */

#alc-page {
	--alc-green: #174735;
	--alc-dark: #242424;
	--alc-text: #767676;
	--alc-link: #333333;
	--alc-line: rgba(0, 0, 0, .105);
	--alc-orange: #ffac12;
	--alc-navy: #123950;
	--alc-badge: #ffb81c;
	--alc-red: #a82626;
	--alc-grey: #f7f7f7;
	--alc-focus: #fbbc34;
	grid-column: 1 / -1;
	min-width: 0;
	display: flex;
	flex-direction: column;
	gap: 20px;
	color: var(--alc-text);
	font-family: Roboto, Arial, Helvetica, sans-serif;
	font-size: 14px;
	line-height: 1.6;
}

#alc-page *,
#alc-page *::before,
#alc-page *::after {
	box-sizing: border-box;
}

#alc-page [hidden] {
	display: none !important;
}

#alc-page p {
	margin: 0;
}

#alc-page strong {
	color: var(--alc-dark);
	font-weight: 600;
}

#alc-page a {
	color: var(--alc-link);
	text-decoration: none;
}

#alc-page .alc-hv:hover {
	filter: brightness(1.08);
}

/* Focus: yellow ring from the prototype, plus a dark inner ring so it is visible on white too. */

#alc-page a:focus-visible,
#alc-page button:focus-visible,
#alc-page input:focus-visible,
#alc-page select:focus-visible,
#alc-page textarea:focus-visible,
#alc-page [tabindex]:focus-visible {
	outline: 2px solid var(--alc-focus) !important;
	outline-offset: 2px !important;
	box-shadow: 0 0 0 2px var(--alc-navy) !important;
}

#alc-page .alc-ic {
	flex: none;
	fill: none;
	stroke: var(--alc-green);
	stroke-width: 2;
	stroke-linecap: round;
	stroke-linejoin: round;
}

#alc-page .alc-sr {
	position: absolute !important;
	width: 1px;
	height: 1px;
	margin: -1px;
	padding: 0;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
	border: 0;
}

#alc-page .alc-nowrap {
	white-space: nowrap;
}

@media (min-width: 769px) {
	#alc-page .alc-phone-only {
		display: none !important;
	}
}

/* Missing-fact placeholder (shown to logged-in editors only). */

#alc-page .alc-todo {
	padding: 8px 12px;
	border: 1px dashed #a5a5a5;
	background: #fafafa;
	color: #555555;
	font-size: 13px;
}

/* ---------- Shared bits ---------- */

#alc-page .alc-kicker {
	font-weight: 600;
	font-size: 12px;
	line-height: 1.4;
	text-transform: uppercase;
	color: var(--alc-link);
}

#alc-page .alc-badge {
	background: var(--alc-badge);
	color: #000000;
	font-weight: 600;
	font-size: 11px;
	line-height: 12px;
	text-transform: uppercase;
	padding: 3px 6px;
	border-radius: 3px;
}

#alc-page .alc-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	width: auto;
	min-height: 42px;
	margin: 0;
	padding: 5px 20px;
	border: 0;
	border-radius: 0;
	box-shadow: none;
	font-family: inherit;
	font-weight: 600;
	font-size: 13px;
	line-height: 1.2;
	letter-spacing: normal;
	text-align: center;
	text-transform: uppercase;
	text-decoration: none;
	cursor: pointer;
}

#alc-page .alc-btn--green {
	background: var(--alc-green);
	color: #ffffff;
	box-shadow: inset 0 -2px 0 rgba(0, 0, 0, .15);
}

#alc-page .alc-btn--green .alc-ic {
	stroke: currentColor;
}

#alc-page .alc-btn--grey {
	background: var(--alc-grey);
	border: 1px solid var(--alc-line);
	color: var(--alc-link);
}

#alc-page .alc-btn--orange {
	background: var(--alc-orange);
	color: var(--alc-navy);
	font-weight: 900;
}

#alc-page .alc-copy {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	min-height: 28px;
	margin: 0;
	padding: 0;
	background: none;
	border: 0;
	border-radius: 0;
	box-shadow: none;
	color: var(--alc-green);
	font-family: inherit;
	font-weight: 600;
	font-size: 13px;
	line-height: 1.4;
	letter-spacing: normal;
	text-transform: none;
	cursor: pointer;
}

#alc-page .alc-copy .alc-ic {
	stroke: currentColor;
}

/* ---------- Green band ---------- */

#alc-page .alc-hero {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 28px 40px;
	padding: 32px 36px;
	background: var(--alc-green);
	color: #ffffff;
}

#alc-page .alc-hero__intro {
	flex: 1 1 400px;
	min-width: 0;
	display: flex;
	flex-direction: column;
	gap: 10px;
}

#alc-page .alc-crumbs {
	font-size: 13px;
}

#alc-page .alc-crumbs a {
	color: #ffffff;
}

#alc-page .alc-crumbs__sep {
	margin: 0 8px;
}

#alc-page .alc-crumbs__cur {
	font-weight: 600;
}

#alc-page .alc-hero__title {
	margin: 0;
	padding: 0;
	color: #ffffff;
	font-family: inherit;
	font-weight: 600;
	font-size: 30px;
	line-height: 1.4;
	letter-spacing: -1.5px;
	text-transform: uppercase;
}

#alc-page .alc-status {
	display: flex;
	align-items: center;
	gap: 10px;
}

#alc-page .alc-pill {
	padding: 5px 10px;
	border-radius: 12px;
	background: #ffffff;
	color: var(--alc-green);
	font-weight: 600;
	font-size: 11px;
	line-height: 12px;
	text-transform: uppercase;
}

#alc-page .alc-pill.is-closed {
	background: var(--alc-red);
	color: #ffffff;
}

#alc-page .alc-status__txt {
	font-weight: 500;
}

#alc-page .alc-tiles {
	flex: 1.2 1 480px;
	min-width: 0;
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr));
	gap: 10px;
}

#alc-page .alc-tile {
	display: flex;
	align-items: center;
	gap: 14px;
	min-height: 76px;
	padding: 12px 16px;
	background: #ffffff;
	color: var(--alc-dark);
}

#alc-page .alc-tile__name {
	display: block;
	font-weight: 600;
	font-size: 13px;
	line-height: 1.4;
	text-transform: uppercase;
}

#alc-page .alc-tile__val {
	display: block;
	font-size: 13px;
	color: var(--alc-text);
}

/* ---------- Section links ---------- */

#alc-page .alc-toc {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 4px 12px;
	min-height: 50px;
	padding: 0 26px;
	background: #ffffff;
	border: 1px solid var(--alc-line);
	font-weight: 600;
	font-size: 11.2px;
	line-height: 1.4;
	text-transform: uppercase;
}

#alc-page .alc-toc__sep {
	width: 1px;
	height: 18px;
	background: rgba(0, 0, 0, .106);
}

/* ---------- Sections ---------- */

#alc-page .alc-stack {
	display: flex;
	flex-direction: column;
	gap: 20px;
}

#alc-page .alc-sec {
	min-width: 0;
	display: flex;
	flex-direction: column;
	gap: 16px;
	padding: 24px 26px;
	background: #ffffff;
	border: 1px solid var(--alc-line);
}

#alc-page .alc-sec__h {
	margin: 0;
	padding: 0;
	color: var(--alc-dark);
	font-family: inherit;
	font-weight: 600;
	font-size: 16px;
	line-height: 1.4;
	letter-spacing: normal;
	text-transform: uppercase;
}

#alc-page .alc-sec__h--form {
	color: #000000;
	font-size: 18px;
	line-height: 1.6;
}

#alc-page .alc-acc {
	display: none;
}

#alc-page .alc-sec__body {
	min-width: 0;
	display: flex;
	flex-direction: column;
	gap: 16px;
}

#alc-page .alc-pair {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(min(420px, 100%), 1fr));
	gap: 20px;
}

#alc-page .alc-pair .alc-sec__body {
	flex: 1;
}

#alc-page .alc-cards {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr));
	gap: 1px;
	background: #e4e4e4;
	border: 1px solid #e4e4e4;
}

#alc-page .alc-card {
	display: flex;
	flex-direction: column;
	gap: 12px;
	padding: 22px 24px;
	background: #ffffff;
}

#alc-page .alc-card__h {
	margin: 0;
	padding: 0;
	color: #000000;
	font-family: inherit;
	font-weight: 600;
	font-size: 15px;
	line-height: 1.4;
	letter-spacing: normal;
	text-transform: uppercase;
}

#alc-page .alc-card__p {
	font-size: 13px;
}

#alc-page .alc-form {
	grid-column: 2;
	grid-row: 1 / span 2;
}

#alc-page .alc-hint {
	padding: 14px 16px;
	background: var(--alc-grey);
	border: 1px solid var(--alc-line);
}

#alc-page .alc-hint__h {
	color: var(--alc-dark);
	font-weight: 600;
}

#alc-page .alc-hint ul {
	margin: 6px 0 0;
	padding: 0 0 0 18px;
	color: #555555;
	font-size: 13px;
	list-style: disc;
}

#alc-page .alc-hint li {
	margin: 0;
}

#alc-page .alc-form {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr));
	gap: 12px 16px;
	align-content: start;
	margin: 0;
}

#alc-page .alc-field {
	min-width: 0;
	display: flex;
	flex-direction: column;
	gap: 2px;
}

#alc-page .alc-field--full {
	grid-column: 1 / -1;
}

#alc-page .alc-field label {
	display: block;
	margin: 0;
	color: var(--alc-text);
	font-weight: 400;
	font-size: 13px;
	line-height: 1.6;
}

#alc-page .alc-field input,
#alc-page .alc-field select,
#alc-page .alc-field textarea {
	width: 100%;
	max-width: 100%;
	height: 42px;
	margin: 0;
	padding: 0 15px;
	border: 1px solid rgba(0, 0, 0, .1);
	border-radius: 5px;
	background-color: #ffffff;
	box-shadow: none;
	color: var(--alc-link);
	font-family: inherit;
	font-size: 14px;
}

#alc-page .alc-field select {
	padding: 0 30px 0 12px;
}

#alc-page .alc-field textarea {
	height: auto;
	min-height: 0;
	padding: 10px 15px;
	line-height: 1.6;
	resize: vertical;
}

#alc-page .alc-submitrow {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 10px 20px;
}

#alc-page .alc-btn--submit {
	min-width: 260px;
}

/* =================== Tablet: 769–1024 =================== */

@media (max-width: 1024px) {
	#alc-page .alc-hero {
		padding: 28px;
	}

	#alc-page .alc-hero__title {
		font-size: 26px;
		letter-spacing: -1px;
	}

	#alc-page .alc-form {
		grid-column: 1;
		grid-row: auto;
	}
}

/* =================== Phone: <= 768 =================== */

@media (max-width: 768px) {
	#alc-page {
		gap: 12px;
	}

	#alc-page .alc-desk-only {
		display: none !important;
	}

	#alc-page .alc-phone-only {
		display: block;
	}

	/* Green band runs edge to edge, whatever the container padding is. */

	#alc-page .alc-hero {
		width: 100vw;
		margin-left: calc(50% - 50vw);
		flex-direction: column;
		align-items: stretch;
		gap: 14px;
		padding: 18px 15px 20px;
	}

	#alc-page .alc-hero__intro {
		flex: none;
		gap: 6px;
	}

	#alc-page .alc-hero__title {
		font-size: 22px;
		letter-spacing: -.5px;
	}

	#alc-page .alc-tiles.alc-phone-only {
		flex: none;
		display: grid;
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 8px;
	}

	#alc-page .alc-ptile {
		display: flex;
		flex-direction: column;
		gap: 4px;
		min-height: 108px;
		padding: 12px 14px;
		background: #ffffff;
		color: var(--alc-dark);
	}

	#alc-page .alc-ptile__name {
		font-weight: 600;
		font-size: 12px;
		line-height: 1.4;
		text-transform: uppercase;
	}

	#alc-page .alc-ptile__act {
		margin-top: auto;
		color: var(--alc-green);
		font-weight: 600;
		font-size: 13px;
		line-height: 1.4;
	}

	/* Accordion box: 15px from the screen edges, whatever the container padding is. */

	#alc-page .alc-stack {
		width: calc(100vw - 30px);
		margin-left: calc(50% - 50vw + 15px);
		gap: 0;
		background: #ffffff;
		border: 1px solid var(--alc-line);
		border-top: 0;
	}

	#alc-page .alc-pair {
		display: contents;
	}

	#alc-page .alc-sec {
		display: block;
		padding: 0;
		background: none;
		border: 0;
		border-top: 1px solid var(--alc-line);
	}

	#alc-page .alc-sec__h,
	#alc-page .alc-sec__h--form {
		font-size: 14px;
		line-height: 1.4;
		color: var(--alc-dark);
	}

	/* Without JavaScript the plain headings stay, and every section is open. */

	#alc-page:not(.alc-js) .alc-sec__plain {
		display: block;
		padding: 16px 16px 4px;
	}

	#alc-page.alc-js .alc-sec__plain {
		display: none;
	}

	#alc-page.alc-js .alc-acc {
		display: flex;
		align-items: center;
		gap: 12px;
		width: 100%;
		min-height: 60px;
		margin: 0;
		padding: 8px 16px;
		background: none;
		border: 0;
		border-radius: 0;
		box-shadow: none;
		color: var(--alc-dark);
		font-family: inherit;
		font-weight: 400;
		line-height: 1.4;
		letter-spacing: normal;
		text-align: left;
		text-transform: none;
		cursor: pointer;
	}

	#alc-page .alc-acc__txt {
		flex: 1;
		min-width: 0;
	}

	#alc-page .alc-acc__name {
		display: block;
		font-weight: 600;
		font-size: 14px;
		line-height: 1.4;
		text-transform: uppercase;
	}

	#alc-page .alc-acc__sub {
		display: block;
		color: var(--alc-text);
		font-weight: 400;
		font-size: 13px;
		line-height: 1.4;
	}

	#alc-page .alc-acc__chev {
		transition: transform .2s ease;
	}

	#alc-page .alc-acc[aria-expanded="true"] .alc-acc__chev {
		transform: rotate(180deg);
	}

	#alc-page .alc-sec__body {
		display: flex;
		flex-direction: column;
		gap: 14px;
		padding: 4px 16px 20px;
	}

	#alc-page.alc-js .alc-sec:not(.is-open) > .alc-sec__body {
		display: none;
	}

	/* Form */

	#alc-page .alc-hint {
		padding: 12px 14px;
	}

	#alc-page .alc-form {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 12px;
	}

	#alc-page .alc-field--full {
		grid-column: 1 / -1;
	}

	#alc-page .alc-field input,
	#alc-page .alc-field select {
		height: 44px;
		font-size: 16px;
	}

	#alc-page .alc-field textarea {
		font-size: 16px;
	}

	#alc-page .alc-submitrow {
		flex-direction: column;
		align-items: stretch;
	}

	#alc-page .alc-btn--submit {
		width: 100%;
		min-width: 0;
		min-height: 48px;
	}
}

/* =================== Small phone: <= 575 =================== */

@media (max-width: 575px) {
	#alc-page .alc-form {
		grid-template-columns: minmax(0, 1fr);
	}

	#alc-page .alc-field {
		grid-column: 1 / -1;
	}
}

@media (prefers-reduced-motion: reduce) {
	#alc-page .alc-acc__chev {
		transition: none;
	}
}
