/*
Theme Name: Koszulki Historyczne
Author: Koszulki Historyczne
Description: Blokowy motyw sklepu koszulkihistoryczne.pl – koszulki z dawnymi mapami polskich miast. WooCommerce i druk na żądanie przez Loostra.
Requires at least: 6.6
Tested up to: 6.8
Requires PHP: 7.4
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: koszulki-historyczne
Tags: e-commerce, full-site-editing, block-patterns, block-styles, style-variations, wide-blocks, custom-colors
*/

/* ---------- Pomocnicze ---------- */

.kh-coords {
	font-family: var(--wp--preset--font-family--mono);
	font-size: 0.85rem;
	letter-spacing: 0.02em;
}

.kh-step-number {
	font-family: var(--wp--preset--font-family--mono);
	font-size: 0.875rem;
	letter-spacing: 0.1em;
	color: var(--wp--preset--color--oxide);
}

/* ---------- Nagłówek ---------- */

.kh-header {
	position: sticky;
	top: 0;
	z-index: 50;
}

@media (min-width: 783px) {
	.admin-bar .kh-header {
		top: 32px;
	}
}

.kh-header-bar {
	border-bottom: 1px solid color-mix(in srgb, var(--wp--preset--color--ink) 15%, transparent);
}

@media (max-width: 600px) {
	.kh-header .wp-block-search {
		display: none;
	}
}

/* ---------- Styl bloku: poziomice (Grupa, Okładka) ---------- */

.is-style-topo {
	position: relative;
	isolation: isolate;
}

.is-style-topo::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	pointer-events: none;
	background-color: currentColor;
	opacity: 0.09;
	-webkit-mask: url("assets/images/topo.svg") center / cover no-repeat;
	mask: url("assets/images/topo.svg") center / cover no-repeat;
}

/* ---------- Styl bloku: karta (Grupa) ---------- */

.is-style-card {
	border: 1px solid color-mix(in srgb, currentColor 18%, transparent);
	transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.is-style-card a {
	color: inherit;
}

.is-style-card:hover {
	transform: translateY(-3px);
	box-shadow: 6px 6px 0 var(--wp--preset--color--ink);
}

/* ---------- Plansza: mapa, czarna linia, podpis, tak jak na nadruku ---------- */

.is-style-plate img {
	display: block;
	border: 2px solid currentColor;
}

.kh-plate {
	display: block;
	border: 2px solid var(--wp--preset--color--ink);
	background: var(--wp--preset--color--paper);
	color: var(--wp--preset--color--ink);
	text-decoration: none;
	transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.kh-plate:hover {
	color: var(--wp--preset--color--ink);
	transform: translate(-2px, -2px);
	box-shadow: 6px 6px 0 var(--wp--preset--color--ink);
}

.kh-plate img {
	display: block;
	width: 100%;
	aspect-ratio: 4 / 3;
	object-fit: cover;
	border-bottom: 2px solid var(--wp--preset--color--ink);
}

.kh-plate__label {
	display: block;
	min-height: 6.5rem;
	padding: 1rem;
	text-align: center;
	font-family: var(--wp--preset--font-family--mono);
}

.kh-plate__label strong {
	display: block;
	font-size: 1.3rem;
}

.kh-plate__label small {
	display: block;
	margin-top: 0.25rem;
	color: var(--wp--preset--color--ink-soft);
	font-size: 0.875rem;
}

/* ---------- Drobiazgi ---------- */

.kh-logo {
	display: block;
	flex: none;
	line-height: 0;
}

.kh-logo img {
	display: block;
	width: auto;
	height: 60px;
}

.kh-logo-footer {
	display: inline-block;
	line-height: 0;
}

.kh-logo-footer img {
	display: block;
	width: auto;
	height: 150px;
}

@media (max-width: 600px) {
	.kh-logo img {
		height: 46px;
	}
}

.kh-hero-image img {
	border: 2px solid var(--wp--preset--color--ink);
	max-height: 680px;
	width: auto;
}

.kh-plain-list {
	list-style: none;
}

.kh-footer-legal {
	max-width: var(--wp--style--global--wide-size);
	margin-inline: auto;
}

/* ---------- Akordeon (Szczegóły) ---------- */

.wp-block-details {
	border-top: 1px solid color-mix(in srgb, currentColor 20%, transparent);
	padding-block: 0.9rem;
}

.wp-block-details summary {
	cursor: pointer;
	font-weight: 600;
	list-style: none;
	display: flex;
	justify-content: space-between;
	gap: 1rem;
}

.wp-block-details summary::-webkit-details-marker {
	display: none;
}

.wp-block-details summary::after {
	content: "+";
	font-family: var(--wp--preset--font-family--mono);
	transition: transform 0.2s ease;
}

.wp-block-details[open] summary::after {
	transform: rotate(45deg);
}

.wp-block-details > :not(summary) {
	margin-top: 0.75rem;
}

/* ---------- Ikony w nagłówku: równe pola, jedna linia ---------- */

.kh-header-icons {
	align-items: center;
}

.kh-header-icons > * {
	margin: 0;
	display: flex;
	align-items: center;
}

.kh-header-icons .wp-block-search__inside-wrapper {
	display: flex;
	align-items: center;
	margin: 0;
	padding: 0;
	border: 0;
}

.kh-header-icons .wp-block-search__button,
.kh-header-icons .wp-block-woocommerce-customer-account a,
.kh-header-icons .wc-block-mini-cart__button {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 24px;
	min-width: 24px;
	height: 24px;
	margin: 0;
	padding: 0;
	border: 0;
	background: transparent;
	color: var(--wp--preset--color--ink);
}

.kh-header-icons .wp-block-search__button:hover,
.kh-header-icons .wp-block-woocommerce-customer-account a:hover,
.kh-header-icons .wc-block-mini-cart__button:hover {
	background: transparent;
	color: var(--wp--preset--color--oxide);
}

.kh-header-icons svg {
	display: block;
	width: 24px;
	height: 24px;
	margin: 0;
	fill: currentColor;
}

.kh-header-icons .wc-block-mini-cart__icon {
	margin: 0;
}

.kh-header-icons svg {
	width: 24px !important;
	height: 24px !important;
}
