/*
Theme Name:     Trawell Child
Theme URI:      https://mekshq.com/theme/trawell	
Description:    Child theme for Trawell theme
Author:         meks
Author URI:     https://mekshq.com
Template:       trawell
Version:        0.1.0
*/

/* =====================================================================
   Leben in der Mupfel: design layer (added 21 September 2026)
   Palette: Mediterranean, sea and sand. Fonts are self-hosted through
   Appearance > Fonts: Source Serif 4 for headings, Inter for body text
   and navigation. Colours and font families are set in Theme Options;
   this file holds only what Trawell's options do not expose.
   ===================================================================== */

:root {
	--mupfel-accent:      #0E6A7D;
	--mupfel-accent-dark: #08505F;
	--mupfel-heading:     #1C2B33;
	--mupfel-text:        #2E3A42;
	--mupfel-meta:        #5E6A73;
	--mupfel-sand:        #F5F0E8;
	--mupfel-rule:        #E2DACF;

	/* Route category colours; white text on each exceeds 4.5 : 1.
	   Country categories use the accent colour. */
	--mupfel-route-sardinia: #1F4E79;
	--mupfel-route-evora:    #9E5623;
	--mupfel-route-olive:    #4F6B33;
	--mupfel-route-plum:     #6B3A5C;
}

/* Uppercase Inter labels read better with open tracking */
.trawell-header a,
.widget-title,
.section-title {
	letter-spacing: 0.06em;
}

/* Link hover and focus in body copy */
.entry-content a:hover,
.entry-content a:focus {
	color: var(--mupfel-accent-dark);
}

/* Visible keyboard focus in the accent colour */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
	outline: 2px solid var(--mupfel-accent);
	outline-offset: 2px;
}

/* Text selection */
::selection {
	background: var(--mupfel-accent);
	color: #FFFFFF;
}

/* Rules in warm sand rather than neutral grey */
.entry-content hr,
.wp-block-separator {
	border-color: var(--mupfel-rule);
}

/* Site title in the header: keep "Leben in der Mupfel" on one line.
   Trawell sizes it as an H1 (42 px), which wraps at desktop widths. */
.trawell-header .site-title a {
	white-space: nowrap;
}

@media (min-width: 1024px) {
	.trawell-header .site-title {
		font-size: 30px;
		line-height: 1.1;
	}
}

/* ---------- Mupfel: photo gallery and daily posts (added 22 September 2026) ---------- */

.mupfel-gallery-filters {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-end;
	gap: 12px 16px;
	margin: 0 0 20px;
	padding: 16px;
	background: var(--mupfel-sand);
	border: 1px solid var(--mupfel-rule);
	border-radius: 4px;
}

.mupfel-gallery-filters .mupfel-gallery-field {
	display: flex;
	flex: 1 1 150px;
	flex-direction: column;
	min-width: 150px;
	margin: 0;
}

.mupfel-gallery-filters label {
	margin: 0 0 4px;
	color: var(--mupfel-meta);
	font-size: 13px;
	font-weight: 600;
	letter-spacing: 0.02em;
}

.mupfel-gallery-filters select {
	width: 100%;
	min-height: 40px;
	padding: 6px 8px;
	border: 1px solid var(--mupfel-rule);
	border-radius: 3px;
	background: #fff;
	color: var(--mupfel-text);
	font-size: 15px;
}

.mupfel-gallery-filters .mupfel-gallery-actions {
	display: flex;
	align-items: center;
	gap: 16px;
	margin: 0;
}

.mupfel-gallery-filters button {
	min-height: 40px;
	padding: 0 20px;
	border: 0;
	border-radius: 3px;
	background: var(--mupfel-accent);
	color: #fff;
	font-size: 15px;
	font-weight: 600;
	cursor: pointer;
}

.mupfel-gallery-filters button:hover {
	background: var(--mupfel-accent-dark);
}

.mupfel-gallery-count,
.mupfel-gallery-empty {
	margin: 0 0 12px;
	color: var(--mupfel-meta);
	font-size: 14px;
}

.mupfel-gallery {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
	gap: 16px;
	margin: 0 0 24px;
}

.mupfel-gallery .wp-caption.mupfel-gallery-item {
	width: auto !important;
	max-width: none;
	margin: 0;
	padding: 0;
	border: 0;
	background: none;
	text-align: left;
}

.mupfel-gallery .mupfel-gallery-item a.trawell-popup-img {
	display: block;
	overflow: hidden;
	border-radius: 3px;
	background: var(--mupfel-sand);
}

.mupfel-gallery .mupfel-gallery-item img {
	display: block;
	width: 100%;
	height: auto;
	margin: 0;
	aspect-ratio: 4 / 3;
	object-fit: cover;
	transition: transform 0.3s ease;
}

.mupfel-gallery .mupfel-gallery-item a.trawell-popup-img:hover img {
	transform: scale(1.03);
}

.mupfel-gallery .mupfel-gallery-item figcaption {
	margin: 6px 0 0;
	padding: 0;
	color: var(--mupfel-meta);
	font-size: 13px;
	font-style: normal;
	line-height: 1.4;
	text-align: left;
}

.mupfel-gallery .mupfel-gallery-item figcaption a {
	color: var(--mupfel-accent);
	font-weight: 600;
	text-decoration: none;
}

.mupfel-gallery .mupfel-gallery-item figcaption a:hover {
	text-decoration: underline;
}

.mupfel-gallery .mupfel-gallery-item figcaption::after {
	display: none;
}

.mupfel-gallery-pages {
	margin: 0 0 24px;
}

.mupfel-gallery-pages .page-numbers {
	display: inline-block;
	margin: 0 4px 4px 0;
	padding: 6px 12px;
	border: 1px solid var(--mupfel-rule);
	border-radius: 3px;
	text-decoration: none;
}

.mupfel-gallery-pages .page-numbers.current {
	border-color: var(--mupfel-accent);
	background: var(--mupfel-accent);
	color: #fff;
}

.mupfel-gallery-more {
	margin: 0 0 24px;
	font-weight: 600;
}

.mupfel-day-facts {
	padding: 10px 14px;
	border-left: 3px solid var(--mupfel-accent);
	background: var(--mupfel-sand);
	color: var(--mupfel-text);
	font-size: 15px;
}

.mupfel-post-place {
	margin-top: 24px;
	padding-top: 12px;
	border-top: 1px solid var(--mupfel-rule);
	color: var(--mupfel-meta);
	font-size: 15px;
}

@media (max-width: 599px) {
	.mupfel-gallery {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 10px;
	}

	.mupfel-gallery-filters .mupfel-gallery-field {
		flex: 1 1 40%;
		min-width: 0;
	}

	.mupfel-gallery .mupfel-gallery-item figcaption {
		font-size: 12px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.mupfel-gallery .mupfel-gallery-item img {
		transition: none;
	}

	.mupfel-gallery .mupfel-gallery-item a.trawell-popup-img:hover img {
		transform: none;
	}
}

/* Home Stage cards: show the route only; keep country assignments for archives and galleries (19 October 2026). */
body.home article.trawell-item[class*="mupfel_place-"] .entry-category a[href*="/trip/location/"] {
    display: none;
}
body.home article.trawell-item[class*="mupfel_place-"] .entry-category a[href*="/trip/route/"]::before {
    content: none;
}
