/* HDK Karczew – style bazowe wtyczki (motyw HDK Karczew rozbudowuje je). */
:root {
	--hdk-red: #d71f2b;
	--hdk-red-dark: #a8141f;
	--hdk-ink: #1d2127;
	--hdk-muted: #6b7280;
	--hdk-line: #e7e7ea;
	--hdk-radius: 14px;
}

.hdk-events, .hdk-events__items, .hdk-sponsors, .hdk-sponsors__track { list-style: none; margin: 0; padding: 0; }

.hdk-events__month {
	font-size: .8rem; letter-spacing: .12em; text-transform: uppercase;
	color: var(--hdk-muted); margin: 1.25rem 0 .5rem; font-weight: 600;
}
.hdk-events__month:first-child { margin-top: 0; }

.hdk-event {
	display: flex; align-items: center; gap: 14px;
	padding: 12px; margin: 0 0 10px;
	background: #fff; border: 1px solid var(--hdk-line); border-radius: var(--hdk-radius);
}
.hdk-event.is-past { opacity: .55; }
.hdk-event__body { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1; }
.hdk-event__title { font-weight: 600; color: var(--hdk-ink); line-height: 1.3; }
.hdk-event__title a { color: inherit; text-decoration: none; }
.hdk-event__title a:hover { color: var(--hdk-red); }
.hdk-event__meta { font-size: .85rem; color: var(--hdk-muted); display: flex; flex-wrap: wrap; gap: 0 10px; }
.hdk-event__weekday { text-transform: capitalize; }
.hdk-event__badge {
	align-self: flex-start; font-size: .7rem; font-weight: 600; white-space: nowrap; line-height: 1.3; margin-bottom: 2px;
	color: var(--hdk-red); background: #fdecee; border-radius: 99px; padding: 2px 9px;
}

.hdk-date-tile {
	flex: none; display: flex; flex-direction: column; align-items: center; justify-content: center;
	width: 58px; height: 64px; border-radius: 12px;
	background: var(--hdk-red); color: #fff; line-height: 1;
}
.hdk-event--inne .hdk-date-tile { background: var(--hdk-ink); }
.hdk-date-tile > span { display: block; line-height: 1.05; }
.hdk-date-tile__day { font-size: 1.45rem; font-weight: 700; }
.hdk-date-tile__mon { font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; margin-top: 3px; }
.hdk-date-tile__year { font-size: .62rem; opacity: .8; margin-top: 2px; }

.hdk-events--cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.hdk-events--cards .hdk-event { margin: 0; }

.hdk-events-empty { color: var(--hdk-muted); }

/* Szczegóły pojedynczej akcji */
.hdk-event-details {
	display: flex; flex-wrap: wrap; align-items: center; gap: 18px 24px;
	padding: 18px; margin: 0 0 1.5rem; border: 1px solid var(--hdk-line); border-radius: var(--hdk-radius); background: #fff;
}
.hdk-event-details .hdk-date-tile { width: 76px; height: 84px; }
.hdk-event-details .hdk-date-tile__day { font-size: 2rem; }
.hdk-event-details__list { margin: 0; display: grid; gap: 6px; flex: 1; min-width: 220px; }
.hdk-event-details__list div { display: flex; gap: 10px; }
.hdk-event-details__list dt { width: 72px; flex: none; color: var(--hdk-muted); font-size: .85rem; padding-top: 2px; }
.hdk-event-details__list dd { margin: 0; font-weight: 600; }
.hdk-event-details__addr { font-weight: 400; color: var(--hdk-muted); font-size: .9rem; }

.hdk-btn {
	display: inline-flex; align-items: center; gap: 8px; justify-content: center;
	padding: 10px 18px; border-radius: 99px; font-weight: 600; text-decoration: none;
	background: var(--hdk-red); color: #fff; border: 2px solid var(--hdk-red);
}
.hdk-btn:hover { background: var(--hdk-red-dark); border-color: var(--hdk-red-dark); color: #fff; }
.hdk-btn--outline { background: transparent; color: var(--hdk-red); }
.hdk-btn--outline:hover { color: #fff; }

/* Sponsorzy */
.hdk-sponsor__link { display: flex; align-items: center; justify-content: center; height: 100%; }
.hdk-sponsor__img { max-width: 100%; max-height: 70px; width: auto; height: auto; object-fit: contain; }

.hdk-sponsors--grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 12px; }
.hdk-sponsors--grid .hdk-sponsor { background: #fff; border: 1px solid var(--hdk-line); border-radius: 12px; padding: 12px; height: 90px; }

.hdk-sponsors--slider {
	display: flex; overflow: hidden; gap: 0;
	-webkit-mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
	mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
}
.hdk-sponsors--slider .hdk-sponsors__track {
	display: flex; flex: none; align-items: center; gap: 22px; padding-right: 22px;
	animation: hdk-marquee var(--hdk-marquee-duration, 40s) linear infinite;
}
.hdk-sponsors--slider:hover .hdk-sponsors__track,
.hdk-sponsors--slider:focus-within .hdk-sponsors__track { animation-play-state: paused; }
.hdk-sponsors--slider .hdk-sponsor { flex: none; width: 160px; height: 96px; background: #fff; border-radius: 12px; padding: 12px; border: 1px solid var(--hdk-line); }

@keyframes hdk-marquee { from { transform: translateX(0); } to { transform: translateX(-100%); } }

@media (prefers-reduced-motion: reduce) {
	.hdk-sponsors--slider { flex-wrap: wrap; -webkit-mask-image: none; mask-image: none; }
	.hdk-sponsors--slider .hdk-sponsors__track { animation: none; flex-wrap: wrap; justify-content: center; }
	.hdk-sponsors--slider .hdk-sponsors__track[aria-hidden="true"] { display: none; }
}

.screen-reader-text:not(:focus) {
	border: 0; clip: rect(1px,1px,1px,1px); clip-path: inset(50%);
	height: 1px; width: 1px; margin: -1px; overflow: hidden; padding: 0; position: absolute; word-wrap: normal !important;
}

/* Baner „Oddaliśmy już ponad … litrów krwi” */
.hdk-counter {
	position: relative; display: block; width: 100%; aspect-ratio: 570 / 300; overflow: hidden;
	border-radius: var(--hdk-radius); background: var(--hdk-red); color: #fff; text-decoration: none;
	container-type: inline-size; isolation: isolate;
}
a.hdk-counter:hover { color: #fff; }
.hdk-counter__photo {
	position: absolute; inset: 0 auto 0 0; width: 66%;
	background-size: cover; background-position: right top; background-repeat: no-repeat;
}
.hdk-counter__panel {
	position: absolute; inset: 0 0 0 auto; width: 40%; z-index: 1;
	display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center;
	padding: 4% 2.5% 4% 8%; line-height: 1.12;
	background: var(--hdk-red);
	clip-path: polygon(18% 0, 100% 0, 100% 100%, 0 100%);
}
.hdk-counter__before, .hdk-counter__unit { font-weight: 600; font-size: 14px; font-size: 3.9cqw; }
.hdk-counter__num { font-weight: 800; font-size: 48px; font-size: 12.5cqw; line-height: 1; letter-spacing: -.02em; margin: 1.2cqw 0; font-variant-numeric: tabular-nums; }
.hdk-counter__after { font-weight: 800; font-size: 15px; font-size: 4.1cqw; margin-top: 2.6cqw; letter-spacing: .02em; }

/* Wynik akcji, odwołane */
.hdk-event__result { font-size: .8rem; color: var(--hdk-ink); font-weight: 500; margin-top: 2px; }
.hdk-event.is-cancelled .hdk-event__title { text-decoration: line-through; text-decoration-thickness: 1px; }
.hdk-event.is-cancelled .hdk-date-tile { background: #9aa0a8 !important; }
.hdk-event__badge--cancelled { background: #eef0f2 !important; color: #5b616b !important; }

/* Kalendarz miesięczny */
.hdk-cal { background: #fff; border: 1px solid var(--hdk-line); border-radius: var(--hdk-radius); padding: 18px; font-size: 15px; }
.hdk-cal__head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.hdk-cal__title { margin: 0; font-size: 1.15rem; text-align: center; flex: 1; color: var(--hdk-ink); }
.hdk-cal__nav {
	width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--hdk-line); background: #fff; color: var(--hdk-ink);
	font-size: 1.4rem; line-height: 1; cursor: pointer; display: inline-flex; align-items: center; justify-content: center;
}
.hdk-cal__nav:hover { background: var(--hdk-red); border-color: var(--hdk-red); color: #fff; }
.hdk-cal__tools { display: flex; justify-content: center; gap: 8px; margin: 10px 0 12px; }
.hdk-cal__today, .hdk-cal__year {
	font: inherit; font-size: .8rem; border: 1px solid var(--hdk-line); background: #fff; border-radius: 99px; padding: 4px 12px; cursor: pointer; color: var(--hdk-ink);
}
.hdk-cal__year { padding-right: 26px; }
.hdk-cal__weekdays, .hdk-cal__grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.hdk-cal__weekdays span { text-align: center; font-size: .72rem; font-weight: 600; color: var(--hdk-muted); text-transform: uppercase; padding: 4px 0; }
.hdk-cal__day {
	position: relative; aspect-ratio: 1; border: 0; border-radius: 10px; background: transparent; color: var(--hdk-ink);
	font: inherit; font-size: .9rem; cursor: pointer; display: flex; align-items: center; justify-content: center; padding: 0;
}
.hdk-cal__day:disabled { cursor: default; color: #9aa0a8; }
.hdk-cal__day:not(:disabled):not(.has-krew):not(.has-inne):not(.has-cancelled):hover { background: #f3f3f5; }
.hdk-cal__day.is-empty { pointer-events: none; }
.hdk-cal__day.is-today { box-shadow: inset 0 0 0 2px var(--hdk-ink); }
.hdk-cal__day.is-today:disabled { color: var(--hdk-ink); }
.hdk-cal__day.has-krew { background: var(--hdk-red); color: #fff; font-weight: 700; }
.hdk-cal__day.has-krew:hover { background: var(--hdk-red-dark); }
.hdk-cal__day.has-inne { background: var(--hdk-ink); color: #fff; font-weight: 700; }
.hdk-cal__day.has-krew.has-inne { background: linear-gradient(135deg, var(--hdk-red) 50%, var(--hdk-ink) 50%); }
.hdk-cal__day.has-cancelled { background: #eef0f2; color: #5b616b; text-decoration: line-through; }
.hdk-cal__day.is-past.has-krew, .hdk-cal__day.is-past.has-inne { opacity: .55; }
.hdk-cal__day.is-selected { outline: 3px solid rgba(215, 31, 43, .35); outline-offset: 1px; }
.hdk-cal__legend { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 12px; font-size: .75rem; color: var(--hdk-muted); }
.hdk-cal__legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.hdk-cal__legend i.is-krew { background: var(--hdk-red); }
.hdk-cal__legend i.is-inne { background: var(--hdk-ink); }
.hdk-cal__details { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--hdk-line); }
.hdk-cal__details-title { margin: 0 0 8px; font-size: .78rem; text-transform: uppercase; letter-spacing: .1em; color: var(--hdk-muted); }
.hdk-cal__list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.hdk-cal__item { display: flex; flex-direction: column; gap: 1px; padding: 8px 10px 8px 12px; border-left: 3px solid var(--hdk-red); background: #faf7f7; border-radius: 0 8px 8px 0; }
.hdk-cal__item.is-inne { border-color: var(--hdk-ink); background: #f6f6f7; }
.hdk-cal__item.is-cancelled { border-color: #9aa0a8; opacity: .75; }
.hdk-cal__item.is-cancelled .hdk-cal__item-title { text-decoration: line-through; }
.hdk-cal__item-date { font-size: .75rem; color: var(--hdk-muted); }
.hdk-cal__item-title { font-weight: 600; color: var(--hdk-ink); text-decoration: none; line-height: 1.35; }
a.hdk-cal__item-title:hover { color: var(--hdk-red); }
.hdk-cal__item-meta { font-size: .8rem; color: var(--hdk-muted); }
.hdk-cal__empty { color: var(--hdk-muted); font-size: .85rem; }
.hdk-cal__add { margin-top: 12px !important; }
.hdk-admin-cal .hdk-cal { max-width: 560px; margin-top: 14px; }

/* Statystyki */
.hdk-stats { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); margin: 0 0 24px; }
.hdk-stat { background: #fff; border: 1px solid var(--hdk-line); border-radius: var(--hdk-radius); padding: 16px 18px; }
.hdk-stat__num { display: block; font-size: 1.8rem; font-weight: 800; line-height: 1.1; color: var(--hdk-red); letter-spacing: -.02em; }
.hdk-stat__label { font-size: .82rem; color: var(--hdk-muted); }
.hdk-chart { display: grid; gap: 6px; }
.hdk-chart__row { display: grid; grid-template-columns: 44px 1fr 70px; align-items: center; gap: 10px; font-size: .82rem; }
.hdk-chart__year { color: var(--hdk-muted); font-variant-numeric: tabular-nums; }
.hdk-chart__bar { height: 14px; background: #f1f1f3; border-radius: 99px; overflow: hidden; }
.hdk-chart__bar span { display: block; height: 100%; background: linear-gradient(90deg, #e0313c, var(--hdk-red-dark)); border-radius: 99px; }
.hdk-chart__val { text-align: right; font-weight: 600; color: var(--hdk-ink); font-variant-numeric: tabular-nums; }
