/*
 * tomasirith-hub theme
 *
 * Písma podle grafického manuálu, nahrazená nejpodobnějšími volnými písmy (složka fonts/):
 *   Hlavní (nadpisy):  Hoefler Text Bold             → EB Garamond
 *   Doplňkové (text):  ITC Avant Garde Gothic Regular → TeX Gyre Adventor
 */

/* ========================================
   FONTS
   ======================================== */

@font-face {
	font-family: 'EB Garamond';
	src: url('../fonts/eb-garamond-400.woff2') format('woff2');
	font-weight: 400;
	font-style: normal;
	font-display: swap;
}

@font-face {
	font-family: 'EB Garamond';
	src: url('../fonts/eb-garamond-700.woff2') format('woff2');
	font-weight: 700;
	font-style: normal;
	font-display: swap;
}

@font-face {
	font-family: 'TeX Gyre Adventor';
	src: url('../fonts/tex-gyre-adventor-regular.woff2') format('woff2');
	font-weight: 400;
	font-style: normal;
	font-display: swap;
}

@font-face {
	font-family: 'TeX Gyre Adventor';
	src: url('../fonts/tex-gyre-adventor-bold.woff2') format('woff2');
	font-weight: 700;
	font-style: normal;
	font-display: swap;
}

/* ========================================
   TOKENS
   ======================================== */

:root {
	--c-red: #A7292A;
	--c-blue: #8EB4E3;
	--c-grey: #7F858B;
	--c-black: #000000;
	--c-white: #FFFFFF;

	--font-serif: 'EB Garamond', Garamond, 'Times New Roman', serif;
	--font-sans: 'TeX Gyre Adventor', 'Century Gothic', 'Helvetica Neue', Arial, sans-serif;

	/* výchozí barvy (přepisují se z nastavení sekce) */
	--bg: var(--c-grey);
	--fg: var(--c-black);
	--line: var(--c-black);
	--diamond: var(--c-grey);
	--diamond-stroke: var(--c-grey);

	--container: 1080px;
	--gutter: 24px;
}

/* Barvy sekcí se nastavují v pluginu Tomasirith Fields;
   šablona je dopočítá a vloží jako proměnné do atributu style (body, ikony sekcí). */

/* ========================================
   RESET & BASE
   ======================================== */

*, *::before, *::after {
	box-sizing: border-box;
	margin: 0;
	padding: 0;
}

html {
	font-size: 16px;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}

body {
	font-family: var(--font-sans);
	color: var(--fg);
	background-color: var(--bg);
	line-height: 1.6;
	min-height: 100vh;
	display: flex;
	flex-direction: column;
}

img {
	max-width: 100%;
	display: block;
}

a {
	color: inherit;
}

.container {
	width: 100%;
	max-width: var(--container);
	margin: 0 auto;
	padding: 0 var(--gutter);
}

/* ========================================
   PŘESKOČIT NA OBSAH (viditelné jen při ovládání klávesnicí)
   ======================================== */

.skip-link {
	position: absolute;
	left: 16px;
	top: -100px;
	z-index: 200;
	padding: 10px 16px;
	background: var(--c-black);
	color: var(--c-white);
	font-family: var(--font-sans);
	font-size: 0.9rem;
	text-decoration: none;
}

.skip-link:focus {
	top: 12px;
}

.site-main:focus {
	outline: none;
}

/* ========================================
   HEADER (bílý pruh s logem)
   ======================================== */

.brand-heading {
	margin: 0;
	font: inherit;
	line-height: 0;
}

.site-header {
	background: var(--c-white);
	color: var(--c-black);
	padding: 28px 0 22px;
}

.is-light .site-header {
	border-bottom: 1px solid var(--c-grey);
}

.brand {
	display: inline-flex;
	align-items: flex-end;
	text-decoration: none;
	color: var(--c-black);
}

.brand-mark {
	width: 64px;
	height: auto;
	flex: none;
}

.brand-name {
	font-family: var(--font-serif);
	font-weight: 400;
	font-size: 3rem;
	line-height: 1;
	letter-spacing: 0.01em;
	margin-left: -2px;
	margin-bottom: -0.17em;
}

/* ========================================
   ZNAK „T“
   ======================================== */

.ti-mark path {
	fill: currentColor;
}

.ti-mark .ti-mark-diamond {
	fill: var(--diamond);
	stroke: var(--diamond-stroke);
	stroke-width: 3px;
	transition: transform 0.2s ease;
}

/* ========================================
   MAIN
   ======================================== */

.site-main {
	flex: 1;
	padding: 40px 0 64px;
}

.text-body {
	font-family: var(--font-sans);
	font-size: 0.95rem;
	line-height: 1.65;
}

.text-body p + p,
.text-body ul,
.text-body ol,
.text-body h2,
.text-body h3,
.text-body blockquote {
	margin-top: 1em;
}

.text-body h2,
.text-body h3 {
	font-family: var(--font-serif);
	font-weight: 700;
	line-height: 1.25;
}

.text-body ul,
.text-body ol {
	padding-left: 1.4em;
}

.text-body a {
	text-decoration: underline;
	text-decoration-thickness: 1px;
	text-underline-offset: 3px;
	transition: opacity 0.3s ease;
}

.text-body a:hover {
	opacity: 0.7;
}

.text-body blockquote {
	padding-left: 1em;
	border-left: 2px solid var(--line);
}

/* Vložená videa (YouTube, Vimeo…) a mapy: přes celou šířku textu v poměru 16:9 */
.text-body iframe,
.text-body video,
.text-body embed {
	display: block;
	width: 100%;
	max-width: 100%;
	height: auto;
	aspect-ratio: 16 / 9;
	border: 0;
	margin: 1.6em 0;
	background: #000;
}

/* Krátká videa na výšku (YouTube Shorts) */
.text-body iframe[src*="/shorts/"] {
	aspect-ratio: 9 / 16;
	max-width: 360px;
	margin-left: auto;
	margin-right: auto;
}

.text-body audio {
	display: block;
	width: 100%;
	margin: 1.2em 0;
}

/* ========================================
   HOME (šedá)
   ======================================== */

.home-intro {
	max-width: 760px;
	margin: 64px auto 0;
	color: var(--c-black);
	text-align: center;
}

.home-sections {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
	gap: 32px 24px;
	align-items: end;
}

.home-section {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 14px;
	text-decoration: none;
	color: var(--c-black);
}

.home-section-mark {
	width: 96px;
	height: auto;
	/* kosočtverec je na 64 % šířky znaku – posun ho dá přesně nad střed textu */
	transform: translateX(-14%);
}

.home-section-name {
	font-family: var(--font-serif);
	font-size: 1.35rem;
	line-height: 1.2;
	text-align: center;
}

.home-section .ti-mark-diamond {
	transform-box: fill-box;
	transform-origin: center;
	transition: transform 0.35s ease;
}

.home-section:hover .ti-mark-diamond,
.home-section:focus-visible .ti-mark-diamond {
	transform: scale(1.25) rotate(90deg);
}

/* ========================================
   SEKCE (výpis karet)
   ======================================== */

.section-title {
	font-family: var(--font-serif);
	font-weight: 700;
	font-size: 2rem;
	line-height: 1.2;
	text-align: center;
	margin-bottom: 36px;
}

.section-description {
	max-width: 760px;
	margin: -16px auto 40px;
	text-align: center;
}

.empty-state {
	text-align: center;
	font-size: 0.95rem;
	opacity: 0.8;
}

/* Karty: 4 / 3 / 2 vedle sebe, neúplný poslední řádek zarovnaný na střed */
.cards {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 40px 28px;
}

.cards > .card {
	flex: 0 0 calc((100% - 3 * 28px) / 4);
	max-width: calc((100% - 3 * 28px) / 4);
}

/* Podsekce (Komorní / Velkoformátové): karty na neúplném řádku se zarovnají na střed.
   Desktop 2 vedle sebe, tablet 3, mobil 2 – plné řádky zůstávají beze změny. */
.split .cards-half {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	column-gap: 28px;
}

.split .cards-half > .card {
	flex: 0 0 calc((100% - 28px) / 2);
	max-width: calc((100% - 28px) / 2);
}

@media (max-width: 860px) {
	.split .cards-half > .card {
		flex-basis: calc((100% - 2 * 28px) / 3);
		max-width: calc((100% - 2 * 28px) / 3);
	}
}

@media (max-width: 600px) {
	.split .cards-half {
		column-gap: 16px;
	}

	.split .cards-half > .card {
		flex-basis: calc((100% - 16px) / 2);
		max-width: calc((100% - 16px) / 2);
	}
}

/* Podsekce pod sebou (1 nebo 3+ podsekcí) a „Ostatní“ */
.group .group-heading {
	margin-bottom: 24px;
}

.group + .group,
.split + .group {
	margin-top: 56px;
}

.card {
	display: flex;
	flex-direction: column;
	text-decoration: none;
	color: var(--fg);
}

.card-image {
	display: block;
	aspect-ratio: 3 / 4; /* obdélník na výšku, stejný jako náhled z pluginu */
	background: var(--c-white);
	overflow: hidden;
}

.is-light .card-image {
	background: #F2F2F3;
}

.card-image img {
	width: 100%;
	height: 100%;
	object-fit: contain; /* celý obrázek, bez ořezu */
	transition: transform 0.6s ease;
}

.card-image .card-placeholder {
	display: block;
	width: 55%;
	height: 100%;
	margin: 0 auto;
	color: var(--c-grey);
	--diamond: var(--c-white);
	--diamond-stroke: var(--c-grey);
}

.card-title {
	display: block;
	font-family: var(--font-serif);
	font-weight: 700;
	font-size: 1.3rem;
	line-height: 1.2;
	text-align: center;
	padding-top: 14px;
	transition: opacity 0.3s ease;
}

/* Rok / termín pod názvem karty */
.card-meta {
	display: block;
	font-family: var(--font-sans);
	font-size: 0.8rem;
	text-align: center;
	opacity: 0.8;
	margin-top: 4px;
}

/* Krátký popis pod názvem karty – zarovnaný do bloku */
.card-text {
	display: block;
	font-family: var(--font-serif);
	font-size: 1rem;
	line-height: 1.4;
	text-align: justify;
	-webkit-hyphens: auto;
	hyphens: auto;
	margin-top: 8px;
	transition: opacity 0.3s ease;
}

/* Šipka u odkazu, který vede na jiný web */
.external-mark {
	display: inline-block;
	margin-left: 0.25em;
	font-family: var(--font-sans);
	font-size: 0.8em;
	opacity: 0.7;
	transition: transform 0.3s ease;
}

.card:hover .external-mark {
	transform: translate(2px, -2px);
}

.card:hover .card-image img,
.card:focus-visible .card-image img {
	transform: scale(1.04);
}

.card:hover .card-title,
.card:focus-visible .card-title,
.card:hover .card-text,
.card:focus-visible .card-text {
	opacity: 0.7;
}

/* --- Podsekce: dva sloupce s kosočtvercem uprostřed --- */

.split {
	display: grid;
	grid-template-columns: minmax(0, 1fr) 1px minmax(0, 1fr);
	column-gap: 40px;
}

.split-col:first-child .split-title {
	text-align: right;
}

.split-title {
	font-family: var(--font-serif);
	font-weight: 700;
	font-size: 1.4rem;
	line-height: 1.2;
	margin-bottom: 28px;
}

.split-diamond {
	position: relative;
	background: var(--line);  /* starší prohlížeče bez color-mix */
	background: color-mix(in srgb, var(--fg) 35%, transparent);
	margin-top: 44px;
}

.split-diamond::before {
	content: '';
	position: absolute;
	top: -30px;
	left: 50%;
	width: 14px;
	height: 14px;
	border: 1px solid var(--fg);
	background: var(--bg);
	transform: translateX(-50%) rotate(45deg);
}

/* ========================================
   DETAIL
   ======================================== */

.gallery {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 28px;
	margin-bottom: 36px;
}

.gallery-item {
	display: block;
	aspect-ratio: 3 / 4; /* stejný obdélník na výšku jako karty */
	background: var(--c-white);
	overflow: hidden;
	cursor: zoom-in;
}

.is-light .gallery-item {
	background: #F2F2F3;
}

.gallery-item img {
	width: 100%;
	height: 100%;
	object-fit: contain; /* celý obrázek, bez ořezu */
	transition: transform 0.6s ease;
}

.gallery-item:hover img {
	transform: scale(1.04);
}

.detail-text {
	max-width: 100%;
}

.detail-actions {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	align-items: center;
	gap: 16px;
	margin-top: 40px;
	font-family: var(--font-serif);
	font-size: 1.1rem;
}

.detail-back,
.detail-link {
	text-decoration: none;
	transition: opacity 0.3s ease;
}

.detail-link {
	font-weight: 700;
}

.detail-back:hover,
.detail-link:hover {
	opacity: 0.7;
}

/* ========================================
   BLOG – výpis článků
   ======================================== */

.posts {
	max-width: 880px;
	margin: 0 auto;
}

.post {
	display: grid;
	grid-template-columns: 240px minmax(0, 1fr);
	gap: 32px;
	align-items: start;
	padding: 36px 0;
	border-top: 1px solid var(--line);  /* starší prohlížeče bez color-mix */
	border-top: 1px solid color-mix(in srgb, var(--fg) 25%, transparent);
}

.post:first-child {
	border-top: 0;
	padding-top: 0;
}

.post-no-image {
	grid-template-columns: minmax(0, 1fr);
}

.post-image {
	display: block;
	aspect-ratio: 1 / 1;
	overflow: hidden;
	background: var(--c-white);
}

.is-light .post-image {
	background: #F2F2F3;
}

.post-image img {
	width: 100%;
	height: 100%;
	object-fit: contain; /* celý obrázek, bez ořezu */
	transition: transform 0.6s ease;
}

.post-image:hover img,
.post:hover .post-image img {
	transform: scale(1.04);
}

.post-date {
	display: block;
	font-family: var(--font-sans);
	font-size: 0.8rem;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	opacity: 0.75;
	margin-bottom: 6px;
}

.post-title {
	font-family: var(--font-serif);
	font-weight: 700;
	font-size: 1.6rem;
	line-height: 1.2;
	margin-bottom: 12px;
}

.post-title a {
	text-decoration: none;
	transition: opacity 0.3s ease;
}

.post-title a:hover {
	opacity: 0.7;
}

.post-excerpt {
	font-family: var(--font-sans);
	font-size: 0.95rem;
	line-height: 1.65;
	margin-bottom: 14px;
}

.post-more {
	font-family: var(--font-serif);
	font-size: 1.05rem;
	text-decoration: none;
	transition: opacity 0.3s ease;
}

.post-more:hover {
	opacity: 0.7;
}

/* --- Stránkování --- */

.pagination {
	max-width: 880px;
	margin: 48px auto 0;
	display: grid;
	grid-template-columns: 1fr auto 1fr;
	align-items: center;
	gap: 16px;
	font-family: var(--font-serif);
	font-size: 1.1rem;
}

.pagination a {
	text-decoration: none;
	transition: opacity 0.3s ease;
}

.pagination a:hover {
	opacity: 0.7;
}

.pagination-next {
	text-align: right;
}

.pagination-pages {
	display: flex;
	gap: 14px;
}

.pagination-pages .is-current {
	font-weight: 700;
	position: relative;
}

.pagination-pages .is-current::after {
	content: '';
	position: absolute;
	left: 50%;
	bottom: -8px;
	width: 5px;
	height: 5px;
	background: currentColor;
	transform: translateX(-50%) rotate(45deg);
}

/* ========================================
   BLOG – článek
   ======================================== */

.article-header {
	text-align: center;
	margin-bottom: 36px;
}

.article-header .section-title {
	margin-bottom: 10px;
}

.article-cover {
	max-width: 880px;
	margin: 0 auto 40px;
}

.article-cover img {
	width: 100%;
	max-height: 520px;
	object-fit: contain; /* celý obrázek, bez ořezu */
}

.article-text,
.article-actions {
	max-width: 720px;
	margin-left: auto;
	margin-right: auto;
}

.article-text {
	font-size: 1rem;
	line-height: 1.75;
	text-align: justify;
	-webkit-hyphens: auto;
	hyphens: auto;
}

.article-text h2,
.article-text h3,
.article-text h4 {
	text-align: left;
}

.article-text h2,
.article-text h3 {
	margin-top: 1.8em;
	margin-bottom: 0.5em;
}

.article-text img {
	display: block;
	height: auto;
	margin: 1.6em auto; /* obrázky na střed */
}

.article-text p img {
	margin-top: 0.4em;
	margin-bottom: 0.4em;
}

.article-text figure {
	margin: 1.6em 0;
	text-align: center;
}

.article-text figcaption {
	font-size: 0.85rem;
	opacity: 0.75;
	text-align: center;
	margin-top: -1em;
}

.is-zoomable {
	cursor: zoom-in;
}

/* ========================================
   PROFILY (O nás) – fotka střídavě vpravo a vlevo
   ======================================== */

.profiles {
	max-width: 980px;
	margin: 0 auto;
}

.profile {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(0, 340px);
	gap: 48px;
	align-items: center;
}

.profile + .profile {
	margin-top: 72px;
}

.profile-reverse {
	grid-template-columns: minmax(0, 340px) minmax(0, 1fr);
}

.profile-reverse .profile-photo {
	order: -1;
}

.profile-no-photo {
	grid-template-columns: minmax(0, 1fr);
}

.profile-name {
	font-family: var(--font-serif);
	font-weight: 700;
	font-size: 1.6rem;
	line-height: 1.2;
	margin-bottom: 16px;
}

.profile-text {
	text-align: justify;
	-webkit-hyphens: auto;
	hyphens: auto;
}

.profile-photo img {
	display: block;
	width: 100%;
	height: auto;
}

.section-credits {
	margin: 80px auto 0;
	font-size: 0.85rem;
	opacity: 0.85;
}

/* ========================================
   AKCE / TERMÍNY
   ======================================== */

.events {
	max-width: 880px;
	margin: 0 auto;
}

.events-heading,
.group-heading {
	display: flex;
	align-items: center;
	gap: 16px;
	font-family: var(--font-serif);
	font-weight: 700;
	font-size: 1.4rem;
	line-height: 1.2;
	margin-bottom: 8px;
}

/* tenká linka s kosočtvercem za nadpisem */
.events-heading::after,
.group-heading::after {
	content: '';
	flex: 1;
	order: 3;
	height: 1px;
	background: var(--line);  /* starší prohlížeče bez color-mix */
	background: color-mix(in srgb, var(--fg) 35%, transparent);
}

.events-heading::before,
.group-heading::before {
	content: '';
	flex: none;
	width: 9px;
	height: 9px;
	border: 1px solid var(--fg);
	transform: rotate(45deg);
	order: 2;
	margin-right: -12px;
}

.events-heading-past {
	margin-top: 64px;
}

.event {
	display: grid;
	grid-template-columns: 112px minmax(0, 1fr) auto;
	gap: 28px;
	align-items: center;
	padding: 26px 0;
	border-bottom: 1px solid var(--line);  /* starší prohlížeče bez color-mix */
	border-bottom: 1px solid color-mix(in srgb, var(--fg) 18%, transparent);
}

.event:last-child {
	border-bottom: 0;
}

.event-date {
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	text-decoration: none;
	line-height: 1;
}

.event-day {
	font-family: var(--font-serif);
	font-weight: 700;
	font-size: 2.8rem;
	letter-spacing: -0.01em;
	white-space: nowrap;
}

.event-day-end {
	font-size: 0.6em;
	vertical-align: 0.5em;
	margin-left: 1px;
}

.event-month {
	font-family: var(--font-sans);
	font-size: 0.75rem;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	margin-top: 8px;
	opacity: 0.8;
}

.event-tba-mark {
	width: 22px;
	height: 22px;
	border: 1px solid var(--fg);
	transform: rotate(45deg);
	opacity: 0.6;
}

.event-meta {
	display: flex;
	flex-wrap: wrap;
	gap: 4px 0;
	font-family: var(--font-sans);
	font-size: 0.8rem;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	opacity: 0.8;
	margin-bottom: 6px;
}

.event-place::before,
.event-info .event-place::before {
	content: '◇';
	display: inline-block;
	margin: 0 10px;
	font-size: 0.85em;
	opacity: 0.8;
}

.event-meta > :first-child.event-place::before,
.event-info > :first-child.event-place::before {
	display: none;
}

/* Vlastní text místo data (např. „Hrajeme opakovaně…“) – běžné písmo, ne verzálky */
.event-note {
	text-transform: none;
	letter-spacing: 0;
	font-size: 1.05em;
}

.event-title {
	font-family: var(--font-serif);
	font-weight: 700;
	font-size: 1.5rem;
	line-height: 1.2;
}

.event-title a {
	text-decoration: none;
	transition: opacity 0.3s ease;
}

.event-title a:hover {
	opacity: 0.7;
}

.event-excerpt {
	font-family: var(--font-sans);
	font-size: 0.92rem;
	line-height: 1.6;
	margin-top: 8px;
}

.event-image {
	display: block;
	width: 150px;
	aspect-ratio: 1 / 1;
	overflow: hidden;
	background: var(--c-white);
}

.is-light .event-image {
	background: #F2F2F3;
}

.event-image img {
	width: 100%;
	height: 100%;
	object-fit: contain; /* celý obrázek, bez ořezu */
	transition: transform 0.6s ease;
}

.event:hover .event-image img {
	transform: scale(1.04);
}

/* --- Odkazy na kalendář (iCal) --- */

.events-subscribe {
	text-align: right;
	font-family: var(--font-sans);
	font-size: 0.8rem;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	margin: -12px 0 28px;
}

.events-subscribe a,
.event-add a {
	text-decoration: none;
	opacity: 0.8;
	transition: opacity 0.3s ease;
}

.events-subscribe a:hover,
.event-add a:hover {
	opacity: 1;
	text-decoration: underline;
	text-underline-offset: 3px;
}

.events-subscribe span {
	margin: 0 6px;
	opacity: 0.5;
}

.event-add {
	text-align: center;
	font-family: var(--font-sans);
	font-size: 0.8rem;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	margin: -24px 0 36px;
}

/* --- Archiv proběhlých akcí --- */

.event-archive {
	list-style: none;
}

.event-archive li {
	border-bottom: 1px solid var(--line);  /* starší prohlížeče bez color-mix */
	border-bottom: 1px solid color-mix(in srgb, var(--fg) 18%, transparent);
}

.event-archive a {
	display: grid;
	grid-template-columns: 112px minmax(0, 1fr) auto;
	gap: 28px;
	align-items: baseline;
	padding: 14px 0;
	text-decoration: none;
	transition: opacity 0.3s ease;
}

.event-archive a:hover {
	opacity: 0.7;
}

.event-archive-date {
	font-family: var(--font-sans);
	font-size: 0.85rem;
	text-align: center;
	opacity: 0.8;
}

.event-archive-title {
	font-family: var(--font-serif);
	font-size: 1.15rem;
}

.event-archive-place {
	font-family: var(--font-sans);
	font-size: 0.85rem;
	opacity: 0.8;
	text-align: right;
}

/* --- Detail akce --- */

.event-info {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	align-items: center;
	gap: 6px 0;
	margin: -22px 0 36px;
	font-family: var(--font-sans);
	font-size: 0.85rem;
	letter-spacing: 0.06em;
	text-transform: uppercase;
}

.event-badge {
	border: 1px solid var(--fg);
	padding: 2px 9px;
	margin-right: 12px;
	font-size: 0.75rem;
}

/* ========================================
   FOOTER
   ======================================== */

.site-footer {
	padding: 24px 0;
	font-size: 0.85rem;
	text-align: center;
	opacity: 0.85;
}

/* ========================================
   LIGHTBOX
   ======================================== */

.lightbox {
	position: fixed;
	inset: 0;
	z-index: 100;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(0, 0, 0, 0.92);
	padding: 48px 56px;
}

.lightbox[hidden] {
	display: none;
}

.lightbox img {
	max-width: 100%;
	max-height: 100%;
	object-fit: contain;
}

.lightbox button {
	position: absolute;
	background: none;
	border: 0;
	color: var(--c-white);
	font-family: var(--font-serif);
	font-size: 2.2rem;
	line-height: 1;
	padding: 8px 14px;
	cursor: pointer;
}

.lightbox .lb-close { top: 8px; right: 8px; }
.lightbox .lb-prev  { left: 4px; top: 50%; transform: translateY(-50%); }
.lightbox .lb-next  { right: 4px; top: 50%; transform: translateY(-50%); }

/* ========================================
   RESPONSIVE
   ======================================== */

@media (max-width: 860px) {
	.gallery {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}

	.cards > .card {
		flex-basis: calc((100% - 2 * 28px) / 3);
		max-width: calc((100% - 2 * 28px) / 3);
	}

	.split {
		grid-template-columns: minmax(0, 1fr);
		row-gap: 0;
	}

	.split-col:first-child .split-title {
		text-align: center;
	}

	.split-title {
		text-align: center;
	}

	.split-diamond {
		height: 1px;
		margin: 44px 0 40px;
	}

	.split-diamond::before {
		top: 50%;
		transform: translate(-50%, -50%) rotate(45deg);
	}
}

@media (max-width: 600px) {
	:root {
		--gutter: 16px;
	}

	.site-header {
		padding: 18px 0 14px;
	}

	.brand-mark {
		width: 44px;
	}

	.brand-name {
		font-size: 2.1rem;
	}

	.site-main {
		padding: 28px 0 48px;
	}

	.section-title {
		font-size: 1.6rem;
		margin-bottom: 28px;
	}

	.home-intro {
		margin-top: 44px;
	}

	.card-title {
		font-size: 1.15rem;
	}

	.card-text {
		font-size: 0.9rem;
	}

	.profile,
	.profile-reverse {
		grid-template-columns: minmax(0, 1fr);
		gap: 20px;
	}

	.profile-photo,
	.profile-reverse .profile-photo {
		order: -1;
		max-width: 320px;
	}

	.profile + .profile {
		margin-top: 48px;
	}

	.home-sections {
		grid-template-columns: repeat(2, 1fr);
		gap: 36px 16px;
	}

	.home-section-mark {
		width: 80px;
	}

	.gallery {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 20px 16px;
	}

	.cards {
		gap: 28px 16px;
	}

	.cards > .card {
		flex-basis: calc((100% - 16px) / 2);
		max-width: calc((100% - 16px) / 2);
	}

	.post {
		grid-template-columns: 96px minmax(0, 1fr);
		gap: 16px;
		padding: 28px 0;
	}

	.post-no-image {
		grid-template-columns: minmax(0, 1fr);
	}

	.post-title {
		font-size: 1.3rem;
	}

	.event {
		grid-template-columns: 64px minmax(0, 1fr);
		gap: 16px;
		align-items: start;
		padding: 22px 0;
	}

	.event-image {
		display: none;
	}

	.event-day {
		font-size: 2rem;
	}

	.event-title {
		font-size: 1.25rem;
	}

	.event-archive a {
		grid-template-columns: 84px minmax(0, 1fr);
		gap: 4px 16px;
	}

	.event-archive-place {
		grid-column: 2;
		text-align: left;
	}

	.pagination {
		grid-template-columns: 1fr 1fr;
	}

	.pagination-pages {
		grid-column: 1 / -1;
		grid-row: 1;
		justify-content: center;
	}
}
