/*
 * Ciosek Tours — style robocze (bez projektu graficznego).
 * Cel: czytelnie pokazać wszystkie elementy i dane. Każdy element = .ct-raw z etykietą.
 */

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

body {
	margin: 0;
	background: #fff;
	color: #222;
	font: 16px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}

img {
	max-width: 100%;
	height: auto;
}

a {
	color: #0645ad;
}

[hidden] {
	display: none !important;
}

.ct-skip {
	position: absolute;
	left: -9999px;
}

.ct-skip:focus {
	left: 16px;
	top: 16px;
	background: #fff;
	padding: 8px;
	z-index: 10;
}

/* ---------- Układ ---------- */

.ct-header,
.ct-main,
.ct-footer {
	max-width: 960px;
	margin: 0 auto;
	padding: 16px;
}

.ct-header,
.ct-footer {
	border-bottom: 1px solid #ddd;
}

.ct-footer {
	border-top: 1px solid #ddd;
	border-bottom: 0;
	color: #555;
}

.ct-header__name {
	margin: 0 0 8px;
	font-weight: 700;
	font-size: 20px;
}

.ct-header__name a {
	color: inherit;
	text-decoration: none;
}

/* ---------- Menu ---------- */

.ct-nav ul {
	list-style: none;
	margin: 0;
	padding: 0;
}

.ct-nav > ul {
	display: flex;
	flex-wrap: wrap;
	gap: 4px 16px;
}

.ct-nav li {
	position: relative;
}

.ct-nav a {
	display: inline-block;
	padding: 4px 0;
}

.ct-nav .current-menu-item > a,
.ct-nav .current_page_item > a {
	font-weight: 700;
}

/* Podmenu: rozwijane po najechaniu i przy nawigacji klawiaturą. */
.ct-nav li ul {
	display: none;
	position: absolute;
	top: 100%;
	left: 0;
	z-index: 20;
	min-width: 220px;
	padding: 6px 12px;
	background: #fff;
	border: 1px solid #999;
}

.ct-nav li:hover > ul,
.ct-nav li:focus-within > ul {
	display: block;
}

.ct-nav li ul a {
	display: block;
}

.ct-nav .menu-item-has-children > a::after,
.ct-nav .page_item_has_children > a::after {
	content: " ▾";
	font-size: 12px;
}

.ct-nav__toggle {
	font: inherit;
	font-weight: 700;
	padding: 6px 14px;
	border: 2px solid #222;
	background: #fff;
	cursor: pointer;
}

@media (min-width: 761px) {
	.ct-nav__toggle {
		display: none;
	}
}

/* Telefon: lista pionowo, podmenu zawsze widoczne z wcięciem; z JS — schowana do kliknięcia „Menu”. */
@media (max-width: 760px) {
	.ct-nav > ul {
		display: block;
		margin-top: 8px;
	}

	.ct-nav--js:not(.is-open) > ul {
		display: none;
	}

	.ct-nav li {
		border-top: 1px solid #eee;
	}

	.ct-nav a {
		padding: 8px 0;
	}

	.ct-nav li ul {
		display: block;
		position: static;
		min-width: 0;
		padding: 0 0 4px 16px;
		border: 0;
	}

	.ct-nav .menu-item-has-children > a::after,
	.ct-nav .page_item_has_children > a::after {
		content: "";
	}
}

/* ---------- Bloki elementów ---------- */

.ct-raw {
	border: 2px dashed #b5b5b5;
	padding: 12px 16px 16px;
	margin: 0 0 20px;
}

.ct-raw .ct-raw {
	border-color: #d6d6d6;
}

.ct-raw--editor {
	border-color: #c9a227;
	background: #fffbea;
}

.ct-raw__label {
	margin: 0 0 8px;
	font-size: 12px;
	letter-spacing: .04em;
	text-transform: uppercase;
	color: #888;
}

.ct-raw__note {
	font-size: 14px;
	color: #666;
}

.ct-raw__empty {
	color: #999;
	font-style: italic;
}

h1,
h2,
h3 {
	line-height: 1.25;
	margin: 0 0 12px;
}

h1 {
	font-size: 28px;
}

h2 {
	font-size: 22px;
}

h3 {
	font-size: 18px;
}

/* ---------- Dane ---------- */

.ct-meta {
	margin: 0 0 12px;
}

.ct-meta dt {
	font-weight: 700;
	margin-top: 8px;
}

.ct-meta dd {
	margin: 0;
}

.ct-labels {
	list-style: none;
	margin: 0 0 8px;
	padding: 0;
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
}

.ct-label {
	border: 1px solid #222;
	padding: 0 6px;
	font-size: 13px;
}

.ct-gallery {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
	gap: 8px;
}

.ct-gallery img {
	display: block;
	width: 100%;
	aspect-ratio: 4 / 3;
	object-fit: cover;
}

.ct-trip__thumb {
	margin: 0;
}

/* ---------- Tabela terminów ---------- */

.ct-table-wrap {
	overflow-x: auto;
	-webkit-overflow-scrolling: touch;
}

.ct-terms {
	width: 100%;
	border-collapse: collapse;
	font-size: 15px;
}

.ct-terms th,
.ct-terms td {
	border: 1px solid #ccc;
	padding: 6px 8px;
	text-align: left;
	vertical-align: top;
}

.ct-terms th {
	background: #f3f3f3;
	white-space: nowrap;
}

.ct-terms tbody tr {
	cursor: pointer;
}

.ct-terms tr.is-selected td {
	background: #fff4c2;
}

.ct-terms tr.is-unavailable td {
	color: #777;
}

.ct-price {
	white-space: nowrap;
}

del {
	color: #888;
}

.ct-omnibus {
	color: #666;
}

.ct-status--last {
	font-weight: 700;
}

.ct-status--full,
.ct-status--closed {
	color: #a00;
}

/* ---------- Kalkulator ---------- */

.ct-form input[type="number"],
.ct-form select,
#ct-stop-search {
	font: inherit;
	padding: 6px 8px;
	max-width: 100%;
	border: 1px solid #999;
}

.ct-form input[type="number"] {
	width: 6em;
}

.ct-calc__result {
	border-top: 1px solid #ddd;
	margin-top: 8px;
	padding-top: 8px;
}

.ct-calc__result p {
	margin: 0 0 4px;
}

.ct-calc__total {
	font-weight: 700;
}

.ct-calc__warning {
	color: #a00;
	font-weight: 700;
}

.ct-button {
	display: inline-block;
	padding: 8px 16px;
	border: 2px solid #222;
	background: #222;
	color: #fff;
	text-decoration: none;
	font-weight: 700;
}

.ct-button:hover,
.ct-button:focus {
	background: #fff;
	color: #222;
}

/* ---------- Przystanki ---------- */

#ct-stop-search {
	width: 100%;
	max-width: 400px;
}

/* Akordeony „Miejsca odbioru — Bezpłatne / Płatne” */
.ct-stops__group {
	border: 1px solid #ccc;
	border-radius: 6px;
	margin: 0 0 8px;
	padding: 0 12px;
}

.ct-stops__group > summary {
	cursor: pointer;
	font-weight: 700;
	padding: 10px 0;
}

.ct-stops__group[open] > summary {
	border-bottom: 1px solid #eee;
	margin-bottom: 8px;
}

.ct-stops {
	margin: 0 0 12px;
	padding-left: 20px;
}

.ct-stops li {
	margin-bottom: 4px;
}

.ct-stops__street,
.ct-stops__time {
	font-size: 14px;
	color: #555;
}

.ct-stops__fee {
	font-size: 14px;
	margin-left: 4px;
}

.ct-stops li.is-match {
	background: #fff3b0;
	outline: 2px solid #f0c000;
	border-radius: 3px;
}

.ct-stops__found {
	color: #0a6b2d;
	font-weight: 700;
}

.ct-stops__none {
	color: #a00;
}

/* ---------- Karta wycieczki ---------- */

.ct-card__thumb {
	display: block;
	margin-bottom: 8px;
}

.ct-card__thumb img {
	display: block;
	width: 100%;
	aspect-ratio: 3 / 2;
	object-fit: cover;
}

.ct-card p {
	margin: 0 0 6px;
}

/* ---------- Wyszukiwarka i filtry ---------- */

.ct-search {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
	gap: 8px 16px;
	align-items: end;
}

.ct-search__field {
	margin: 0;
}

.ct-search__field label {
	display: block;
	font-size: 14px;
	font-weight: 700;
}

.ct-search__field label:has(input[type="checkbox"]) {
	font-weight: 400;
	font-size: 16px;
	padding: 6px 0;
}

.ct-search select,
.ct-search input[type="number"] {
	font: inherit;
	width: 100%;
	padding: 6px 8px;
	border: 1px solid #999;
	background: #fff;
}

/* Opcje bez wyników (licznik 0) — nieaktywne, szare. */
.ct-search option:disabled {
	color: #aaa;
}

.ct-search__field.is-disabled label {
	color: #aaa;
}

/* Opcje z 0 ukryte (pola „warunkowe”; Safari ignoruje hidden na <option> — wtedy zostają nieaktywne). */
.ct-search option[hidden] {
	display: none;
}

/* Trwa pobieranie liczników (assets/search.js). */
.ct-search[aria-busy="true"] .ct-search__submit {
	opacity: .7;
	cursor: progress;
}

.ct-search__submit:disabled {
	background: #888;
	border-color: #888;
	cursor: not-allowed;
}

.ct-search__actions {
	margin: 0;
	grid-column: 1 / -1;
}

.ct-search__actions button {
	font: inherit;
	font-weight: 700;
	padding: 8px 20px;
	border: 2px solid #222;
	background: #222;
	color: #fff;
	cursor: pointer;
	margin-right: 12px;
}

.ct-count {
	color: #666;
	font-weight: 400;
}

.ct-cards {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
	gap: 16px;
}

/* ---------- Lista wycieczek (karty poziome, wzór: oskar.com.pl) ---------- */

.ct-cards--lista {
	grid-template-columns: minmax(0, 1fr);
}

/* Nagłówek miesiąca (lista po terminach, sortowanie po dacie): „Listopad 2026”, „Listopad 2026 (cd.)”. */
.ct-cards + .ct-raw[data-element="lista-miesiac"] {
	margin-top: 28px;
}

.ct-month {
	margin: 0;
	font-size: 22px;
	line-height: 1.3;
}

/* Nagłówek: „Wybieraj spośród N ofert” | „Sortuj”. */
.ct-list-head {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 8px 16px;
}

.ct-list-head__count {
	margin: 0;
}

.ct-list-head__page {
	color: #666;
	font-size: 14px;
}

.ct-list-head__sort {
	display: flex;
	align-items: center;
	gap: 6px;
	margin: 0;
}

.ct-list-head__sort select,
.ct-list-head__apply {
	font: inherit;
	padding: 4px 8px;
	border: 1px solid #999;
	background: #fff;
}

.ct-list-head__apply {
	cursor: pointer;
}

/* Karta: zdjęcie ~1/3 | środek | prawa kolumna (termin, cena, przycisk). */
.ct-raw.ct-lcard-wrap {
	padding: 6px 8px 8px;
	margin: 0;
}

.ct-lcard {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr) minmax(170px, .8fr);
	border: 1px solid #ccc;
	border-radius: 16px;
	overflow: hidden;
	background: #fff;
}

.ct-lcard p {
	margin: 0;
}

.ct-lcard__media {
	position: relative;
	min-height: 210px;
	background: #eee;
}

.ct-lcard__thumb {
	position: absolute;
	inset: 0;
	display: block;
	text-decoration: none;
}

.ct-lcard__thumb img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.ct-lcard__nophoto {
	display: flex;
	height: 100%;
	align-items: center;
	justify-content: center;
	color: #888;
	font-style: italic;
}

.ct-lcard__labels {
	position: absolute;
	top: 10px;
	left: 10px;
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 4px;
}

.ct-lcard__labels .ct-label {
	border: 0;
	border-radius: 4px;
	padding: 1px 8px;
	background: #222;
	color: #fff;
	font-weight: 700;
	text-transform: uppercase;
}

.ct-lcard__labels .ct-label--promocja {
	background: #1f9d3a;
}

.ct-lcard__labels .ct-label--nowosc {
	background: #0645ad;
}

.ct-lcard__labels .ct-label--polecamy {
	background: #b36b00;
}

/* Ulubione (assets/favorites.js). */
.ct-fav {
	position: absolute;
	top: 10px;
	right: 10px;
	display: grid;
	place-items: center;
	width: 40px;
	height: 40px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: #fff;
	color: #222;
	box-shadow: 0 1px 4px rgba(0, 0, 0, .25);
	cursor: pointer;
}

.ct-fav[aria-pressed="true"] {
	color: #c00;
}

.ct-fav[aria-pressed="true"] .ct-icon path {
	fill: currentColor;
}

.ct-lcard__body {
	display: flex;
	flex-direction: column;
	gap: 4px;
	padding: 16px 20px;
}

.ct-lcard__title {
	margin: 0;
	font-size: 18px;
}

.ct-lcard__title a {
	text-decoration: none;
}

.ct-lcard__title a:hover,
.ct-lcard__title a:focus {
	text-decoration: underline;
}

.ct-lcard__location {
	color: #444;
	font-size: 15px;
}

.ct-lcard__highlights {
	list-style: none;
	margin: 6px 0 0;
	padding: 0;
	font-size: 13px;
	color: #333;
}

.ct-lcard__highlights li::before {
	content: "✓ ";
	color: #1f9d3a;
	font-weight: 700;
}

/* .ct-lcard p zeruje marginesy — tu potrzebna wyższa waga (transport na dole kolumny). */
.ct-lcard .ct-lcard__transport {
	display: flex;
	align-items: center;
	gap: 6px;
	margin-top: auto;
	padding-top: 12px;
	font-size: 14px;
	color: #333;
}

.ct-icon {
	flex: none;
}

.ct-lcard__side {
	display: flex;
	flex-direction: column;
	align-items: flex-end;
	gap: 6px;
	padding: 16px 20px 16px 0;
	text-align: right;
}

.ct-lcard__date {
	font-size: 14px;
}

.ct-lcard__length {
	white-space: nowrap;
}

.ct-lcard__chips {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	align-items: flex-end;
	gap: 4px;
}

.ct-chip {
	padding: 1px 8px;
	border-radius: 4px;
	font-size: 14px;
	background: #f0f0f0;
	color: #555;
}

.ct-chip--last {
	background: #fde8e8;
	color: #c00;
}

.ct-lcard__more {
	font-size: 13px;
	color: #666;
}

/* Rozwijana lista terminów (<details>): na całą szerokość kolumny, wiersze się zawijają (karta się nie rozpycha). */
.ct-lcard__terms {
	align-self: stretch;
	min-width: 0;
	font-size: 13px;
}

.ct-lcard__terms-toggle {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	gap: 4px;
	list-style: none;
	color: #0645ad;
	cursor: pointer;
}

.ct-lcard__terms-toggle::-webkit-details-marker {
	display: none;
}

.ct-lcard__terms-toggle:hover,
.ct-lcard__terms-toggle:focus-visible {
	text-decoration: underline;
}

.ct-lcard__terms-toggle .ct-icon {
	width: 16px;
	height: 16px;
	transition: transform .15s;
}

.ct-lcard__terms[open] .ct-lcard__terms-toggle .ct-icon {
	transform: rotate(180deg);
}

.ct-lcard__terms-list {
	list-style: none;
	margin: 6px 0 0;
	padding: 0;
	border-top: 1px solid #ddd;
	text-align: left;
}

.ct-lcard__term {
	border-bottom: 1px solid #ddd;
}

.ct-lcard__term a {
	display: flex;
	flex-wrap: wrap;
	gap: 0 6px;
	padding: 5px 2px;
	color: inherit;
	text-decoration: none;
	overflow-wrap: anywhere;
}

.ct-lcard__term a:hover,
.ct-lcard__term a:focus-visible {
	background: #f3f6fb;
}

.ct-lcard__term-date {
	flex: 1 1 100%;
}

.ct-lcard__term-meta {
	color: #444;
}

.ct-lcard__term-status {
	color: #555;
}

.ct-lcard__term-status--last {
	color: #c00;
}

.ct-lcard__term.is-current {
	font-weight: 700;
}

.ct-lcard__term-current {
	margin-left: auto;
	font-size: 12px;
	color: #1f9d3a;
}

.ct-lcard__price {
	margin-top: auto;
}

.ct-lcard__old {
	font-size: 14px;
}

.ct-lcard__now strong {
	font-size: 24px;
	color: #c00;
}

.ct-lcard__pilot {
	font-size: 13px;
	color: #555;
}

.ct-lcard__price .ct-omnibus {
	font-size: 12px;
}

.ct-lcard__cta {
	margin-top: 6px;
	border-radius: 8px;
	white-space: nowrap;
}

/* Telefon: karta pionowa — zdjęcie, środek, prawa kolumna. */
@media (max-width: 699px) {
	.ct-lcard {
		grid-template-columns: minmax(0, 1fr);
	}

	.ct-lcard__media {
		min-height: 0;
		aspect-ratio: 16 / 9;
	}

	.ct-lcard__body {
		padding: 12px 16px 8px;
	}

	.ct-lcard .ct-lcard__transport {
		padding-top: 6px;
	}

	.ct-lcard__side {
		align-items: flex-start;
		padding: 0 16px 16px;
		text-align: left;
	}

	.ct-lcard__chips {
		flex-direction: row;
		flex-wrap: wrap;
	}

	.ct-lcard__terms-toggle {
		justify-content: flex-start;
	}

	.ct-lcard__price {
		margin-top: 4px;
	}

	.ct-lcard__cta {
		align-self: stretch;
		text-align: center;
	}
}

/* ---------- Skróty i kierunki ---------- */

.ct-shortcuts__group {
	margin: 0 0 6px;
	font-weight: 700;
}

.ct-shortcuts,
.ct-directions {
	list-style: none;
	margin: 0 0 12px;
	padding: 0;
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.ct-shortcut a {
	display: inline-block;
	padding: 6px 12px;
	border: 1px solid #222;
	text-decoration: none;
}

.ct-shortcut a:hover,
.ct-shortcut a:focus {
	background: #f3f3f3;
}

.ct-shortcut.is-empty a,
.ct-directions__item.is-empty a {
	color: #aaa;
	border-color: #ccc;
}

.ct-directions {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
	gap: 4px 16px;
}

/* ---------- Paginacja ---------- */

.ct-pagination ul {
	list-style: none;
	margin: 16px 0 0;
	padding: 0;
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
}

.ct-pagination a,
.ct-pagination span {
	display: inline-block;
	min-width: 40px;
	padding: 6px 10px;
	border: 1px solid #999;
	text-align: center;
	text-decoration: none;
}

.ct-pagination [aria-current="page"] {
	background: #222;
	border-color: #222;
	color: #fff;
	font-weight: 700;
}

/* ---------- Telefon ---------- */

@media (max-width: 600px) {
	body {
		font-size: 15px;
	}

	h1 {
		font-size: 24px;
	}

	.ct-raw {
		padding: 10px 12px 12px;
	}
}
