/* ==========================================================================
   A-LIGHT – veřejný web
   Paleta převzatá z původní homepage: #202328 text, #805a20 akcent, #245448 zelená,
   #f3f5f3 plochy, #dce0df linky.
   ========================================================================== */

:root {
	--al-text: #202328;
	--al-muted: #60676b;
	--al-border: #dce0df;
	--al-soft: #f3f5f3;
	--al-accent: #805a20;
	--al-green: #245448;
	--al-green-dark: #1b4137;
	--al-radius: 10px;
	--al-max: 1240px;
}

html {
	scroll-behavior: smooth;
}

body {
	font: 17px/1.65 Arial, "Segoe UI", sans-serif;
	color: var(--al-text);
	background: #fff;
	display: flex;
	flex-direction: column;
	min-height: 100vh;
}

main {
	flex: 1 0 auto;
}

.container {
	max-width: var(--al-max);
}

a {
	color: var(--al-green);
}

a:hover {
	color: var(--al-accent);
}

h1, h2, h3 {
	line-height: 1.25;
}

.al-muted {
	color: var(--al-muted);
}

.flash-container {
	position: fixed;
	top: 16px;
	right: 16px;
	z-index: 1080;
	max-width: 420px;
}

/* --- Buttons --- */
.al-btn,
.al-btn-outline,
.al-btn-light {
	border-radius: 999px;
	padding: 9px 22px;
	font-weight: 700;
	font-size: 15px;
}

.al-btn {
	background: var(--al-green);
	border: 1px solid var(--al-green);
	color: #fff;
}

.al-btn:hover {
	background: var(--al-green-dark);
	border-color: var(--al-green-dark);
	color: #fff;
}

.al-btn-outline {
	background: #fff;
	border: 1px solid var(--al-green);
	color: var(--al-green);
}

.al-btn-outline:hover {
	background: var(--al-green);
	color: #fff;
}

.al-btn-light {
	background: #fff;
	border: 1px solid #fff;
	color: var(--al-green);
}

.al-btn-light:hover {
	background: var(--al-soft);
	color: var(--al-green-dark);
}

/* --- Header --- */
.al-header {
	background: #fff;
}

.al-brand-row {
	display: flex;
	align-items: center;
	gap: 24px;
	padding: 18px 0;
}

.al-logo {
	flex: 0 0 auto;
}

.al-logo img {
	display: block;
	width: 130px;
	height: auto;
}

.al-banner {
	flex: 1 1 auto;
	min-width: 0;
	border-radius: var(--al-radius);
	overflow: hidden;
	background: var(--al-soft);
}

.al-banner img {
	display: block;
	width: 100%;
	height: auto;
}

.al-nav-row {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	padding: 12px 0;
	border-top: 1px solid var(--al-border);
	border-bottom: 1px solid var(--al-border);
}

.al-menu {
	display: flex;
	flex-wrap: wrap;
	gap: 4px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.al-menu a {
	display: block;
	padding: 6px 12px;
	border-bottom: 2px solid transparent;
	color: var(--al-text);
	font-weight: 700;
	font-size: 16px;
	text-decoration: none;
}

.al-menu a:hover,
.al-menu a.active {
	color: var(--al-accent);
	border-bottom-color: var(--al-accent);
}

.al-search {
	display: flex;
	gap: 0;
}

.al-search input {
	min-width: 240px;
	padding: 8px 14px;
	border: 1px solid var(--al-border);
	border-right: 0;
	border-radius: 6px 0 0 6px;
	font-size: 15px;
	background: #fff;
}

.al-search input:focus {
	outline: 2px solid var(--al-green);
	outline-offset: -1px;
}

.al-search button {
	padding: 0 18px;
	border: 0;
	border-radius: 0 6px 6px 0;
	background: var(--al-green);
	color: #fff;
	font-weight: 700;
	font-size: 15px;
}

.al-search button:hover {
	background: var(--al-green-dark);
}

@media (max-width: 767.98px) {
	.al-banner {
		display: none;
	}

	.al-brand-row {
		padding: 12px 0;
	}

	.al-search {
		width: 100%;
	}

	.al-search input {
		flex: 1 1 auto;
		min-width: 0;
	}
}

/* --- Headings & sections --- */
.al-h1 {
	font-size: clamp(28px, 3.6vw, 40px);
	font-weight: 700;
	text-align: center;
	margin: 36px 0 28px;
}

.al-page-head {
	margin: 12px 0 24px;
}

.al-page-head h1 {
	font-size: clamp(28px, 3.6vw, 40px);
	font-weight: 700;
	margin-bottom: 8px;
}

.al-page-head p,
.al-page-lead {
	color: var(--al-muted);
	font-size: 18px;
	margin: 0;
}

.al-page-head-boxed {
	background: var(--al-soft);
	border-left: 5px solid var(--al-green);
	padding: 28px 32px;
	margin-bottom: 28px;
}

.al-section-title {
	font-size: 26px;
	font-weight: 700;
	text-align: center;
	margin: 52px 0 24px;
}

.al-more {
	margin-top: 48px;
	border-top: 2px solid var(--al-text);
}

.al-more .al-section-title {
	margin-top: 24px;
}

.al-empty {
	padding: 32px;
	text-align: center;
	color: var(--al-muted);
	background: var(--al-soft);
	border-radius: var(--al-radius);
}

/* --- Rubriky --- */
.al-pills {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin: 0 0 28px;
}

.al-home .al-pills {
	margin: 44px 0 0;
}

.al-pills a {
	display: inline-block;
	padding: 7px 18px;
	border: 1px solid var(--al-border);
	border-radius: 999px;
	color: var(--al-text);
	font-weight: 700;
	font-size: 15px;
	text-decoration: none;
	transition: background .15s, color .15s, border-color .15s;
}

.al-pills a:hover,
.al-pills a.active {
	background: var(--al-green);
	border-color: var(--al-green);
	color: #fff;
}

/* --- Article cards --- */
.al-card {
	position: relative;
	display: flex;
	flex-direction: column;
	height: 100%;
	background: #fff;
	border: 1px solid var(--al-border);
	border-radius: var(--al-radius);
	overflow: hidden;
	transition: box-shadow .2s, transform .2s;
}

.al-card:hover {
	box-shadow: 0 10px 28px rgba(32, 35, 40, .12);
	transform: translateY(-2px);
}

.al-card-img {
	display: block;
	aspect-ratio: 2 / 1;
	background: var(--al-soft);
	overflow: hidden;
}

.al-card-img img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform .35s;
}

.al-card:hover .al-card-img img {
	transform: scale(1.03);
}

.al-card-img.is-empty {
	display: flex;
	align-items: center;
	justify-content: center;
	color: var(--al-border);
	font-size: 2.6rem;
}

.al-card-body {
	display: flex;
	flex-direction: column;
	flex: 1 1 auto;
	padding: 18px 20px 20px;
	text-align: center;
}

.al-meta a + time::before {
	content: "· ";
}

.al-meta {
	margin: 0 0 8px;
	font-size: 13px;
	color: var(--al-muted);
}

.al-meta a {
	position: relative;
	z-index: 2;
	margin-right: 10px;
	color: var(--al-accent);
	font-weight: 700;
	text-decoration: none;
}

.al-meta a:hover {
	text-decoration: underline;
}

.al-card-title {
	margin: 0 0 10px;
	font-size: 19px;
	font-weight: 700;
	line-height: 1.3;
}

.al-card-title a {
	color: var(--al-text);
	text-decoration: none;
}

.al-card-title a::after {
	content: "";
	position: absolute;
	inset: 0;
	z-index: 1;
}

.al-card:hover .al-card-title a {
	color: var(--al-green);
}

.al-perex {
	margin: 0;
	font-size: 15px;
	color: var(--al-muted);
}

.al-card-lg .al-card-title {
	font-size: clamp(22px, 2.4vw, 30px);
}

.al-card-lg .al-card-body {
	padding: 22px 26px 26px;
}

.al-card-lg .al-perex {
	font-size: 16px;
}

.al-card-row {
	flex-direction: row;
	height: auto;
}

.al-card-row .al-card-img {
	flex: 0 0 40%;
	aspect-ratio: auto;
	min-height: 120px;
}

.al-card-row .al-card-body {
	padding: 14px 16px;
	justify-content: center;
}

.al-card-row .al-card-title {
	font-size: 16px;
	margin-bottom: 0;
}

/* --- Praktická doporučení --- */
.al-aside {
	height: auto;
	text-align: center;
}

.al-aside-title {
	margin: 0 0 8px;
	padding-bottom: 10px;
	border-bottom: 1px solid var(--al-border);
	font-size: 24px;
	font-weight: 700;
}

.al-aside-item {
	padding: 18px 0;
	border-bottom: 1px solid var(--al-border);
}

.al-aside-item:last-child {
	border-bottom: 0;
}

.al-aside-item .al-meta {
	margin-bottom: 4px;
}

.al-aside-item h3 {
	margin: 0;
	font-size: 17px;
	font-weight: 700;
}

.al-aside-item h3 a {
	color: var(--al-text);
	text-decoration: none;
}

.al-aside-item h3 a:hover {
	color: var(--al-green);
}

/* --- E-shop & CTA --- */
.al-eshop {
	margin: 32px 0 40px;
	padding: 24px;
	background: var(--al-soft);
	border-radius: var(--al-radius);
	text-align: center;
}

.al-eshop img {
	display: block;
	width: 100%;
	height: auto;
	margin-bottom: 18px;
	border-radius: 8px;
}

.al-eshop h2 {
	font-size: 22px;
	font-weight: 700;
}

.al-link-arrow {
	font-weight: 700;
	color: var(--al-accent);
	text-decoration: none;
}

.al-link-arrow:hover {
	text-decoration: underline;
}

.al-cta-row {
	margin-bottom: 8px;
}

.al-cta {
	padding: 16px 24px;
	text-align: center;
}

.al-cta h2 {
	font-size: 22px;
	font-weight: 700;
}

.al-cta p {
	margin-bottom: 12px;
	color: var(--al-muted);
}

/* --- Article / page detail --- */
.al-article {
	max-width: 860px;
	margin-inline: auto;
}

.breadcrumb {
	--bs-breadcrumb-divider-color: var(--al-muted);
}

.breadcrumb a {
	color: var(--al-muted);
	text-decoration: none;
}

.breadcrumb a:hover {
	color: var(--al-accent);
}

.al-article-head {
	margin-bottom: 28px;
}

.al-article-head h1 {
	font-size: clamp(28px, 4vw, 40px);
	font-weight: 700;
	margin: 0;
}

.al-article-head .al-meta {
	font-size: 14px;
}

.al-article-foot {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	gap: 12px;
	margin-top: 40px;
	padding-top: 24px;
	border-top: 1px solid var(--al-border);
}

.article-prose {
	font-size: 17px;
	overflow-wrap: anywhere;
}

.article-prose h1 {
	font-size: clamp(28px, 4vw, 40px);
	font-weight: 700;
	margin: 0 0 24px;
}

.article-prose h2 {
	font-size: 26px;
	font-weight: 700;
	margin: 2.2rem 0 1rem;
}

.article-prose h3 {
	font-size: 21px;
	font-weight: 700;
	margin: 1.8rem 0 .8rem;
}

.article-prose p {
	margin: 0 0 1.1rem;
}

.article-prose img {
	max-width: 100%;
	height: auto;
	border-radius: 8px;
}

.article-prose figure {
	margin: 1.8rem 0;
}

.article-prose figcaption {
	margin-top: 8px;
	font-size: 14px;
	color: var(--al-muted);
}

.article-prose a {
	color: var(--al-green);
	text-decoration: underline;
	text-underline-offset: 2px;
}

.article-prose a:hover {
	color: var(--al-accent);
}

.article-prose ul,
.article-prose ol {
	margin-bottom: 1.1rem;
}

.article-prose table {
	width: 100%;
	margin: 1.4rem 0;
	border-collapse: collapse;
	font-size: 15px;
}

.article-prose th,
.article-prose td {
	padding: 8px 10px;
	border: 1px solid var(--al-border);
}

.article-prose th {
	background: var(--al-soft);
}

.al-category-long {
	margin: 0 0 32px;
}

/* --- Pagination --- */
.pagination {
	--bs-pagination-color: var(--al-green);
	--bs-pagination-hover-color: var(--al-green-dark);
	--bs-pagination-active-bg: var(--al-green);
	--bs-pagination-active-border-color: var(--al-green);
	--bs-pagination-focus-color: var(--al-green-dark);
	--bs-pagination-border-color: var(--al-border);
}

/* --- Footer --- */
footer.container {
	margin-top: 48px;
	margin-bottom: 24px;
}

.al-footer {
	padding: 36px 32px 20px;
	background: var(--al-soft);
	border-radius: var(--al-radius);
}

.al-footer-brand {
	margin-bottom: 10px;
	font-size: 20px;
	font-weight: 700;
}

.al-footer-title {
	margin-bottom: 14px;
	font-size: 13px;
	font-weight: 700;
	letter-spacing: .08em;
	text-transform: uppercase;
	color: var(--al-muted);
}

.al-footer-link {
	color: var(--al-text);
	text-decoration: none;
}

.al-footer-link:hover {
	color: var(--al-accent);
}

.al-footer-bottom {
	padding-top: 16px;
	border-top: 1px solid var(--al-border);
	font-size: 14px;
	color: var(--al-muted);
}

/* --- Drobná doladění --- */
.al-meta time {
	white-space: nowrap;
}

.al-aside {
	height: auto;
}

.article-prose a:has(> img) {
	text-decoration: none;
}

/* Tlačítka z obsahu stránek (HTML z databáze) */
.btn-primary {
	--bs-btn-bg: var(--al-green);
	--bs-btn-border-color: var(--al-green);
	--bs-btn-hover-bg: var(--al-green-dark);
	--bs-btn-hover-border-color: var(--al-green-dark);
	--bs-btn-active-bg: var(--al-green-dark);
	--bs-btn-active-border-color: var(--al-green-dark);
	--bs-btn-focus-shadow-rgb: 36, 84, 72;
}

.article-prose a.btn {
	color: #fff;
	text-decoration: none;
}

/* Detail článku má stejnou šířku jako zbytek stránky */
.al-article.al-article-wide {
	max-width: none;
}
