/* ==========================================================================
   Ski Lappersdorf – styles theme.json cannot express
   (dark mode, flyer elements, block styles, header)
   ========================================================================== */

/* ---------- Colour schemes ---------------------------------------------- */
:root {
	color-scheme: light;
	--skl-logo-primary: #9c50a8;
	--skl-logo-light: #ffffff;
	--skl-logo-text: #9c50a8;
	--skl-img-filter: none;
	--skl-stripe: var(--wp--preset--color--primary-soft);
	--skl-border: #e4dbe7;
}

:root[data-theme="dark"] {
	color-scheme: dark;
	--wp--preset--color--base: #141016;
	--wp--preset--color--base-2: #1c1620;
	--wp--preset--color--contrast: #f1ecf3;
	--wp--preset--color--muted: #b9afbd;
	--wp--preset--color--primary: #c58bce;
	--wp--preset--color--primary-strong: #9c50a8;
	--wp--preset--color--primary-soft: #2a1f2e;
	--skl-logo-text: #e6cdea;
	--skl-img-filter: brightness(.9);
	--skl-stripe: #221a26;
	--skl-border: #3a2e3f;
}

@media (prefers-color-scheme: dark) {
	:root:not([data-theme="light"]) {
		color-scheme: dark;
		--wp--preset--color--base: #141016;
		--wp--preset--color--base-2: #1c1620;
		--wp--preset--color--contrast: #f1ecf3;
		--wp--preset--color--muted: #b9afbd;
		--wp--preset--color--primary: #c58bce;
		--wp--preset--color--primary-strong: #9c50a8;
		--wp--preset--color--primary-soft: #2a1f2e;
		--skl-logo-text: #e6cdea;
		--skl-img-filter: brightness(.9);
		--skl-stripe: #221a26;
		--skl-border: #3a2e3f;
	}
}

/* Links on dark backgrounds need the light purple, headings on base use primary in dark */
:root[data-theme="dark"] :where(h1, h2),
:root[data-theme="dark"] :where(a:not(.wp-element-button)) { color: var(--wp--preset--color--primary); }
@media (prefers-color-scheme: dark) {
	:root:not([data-theme="light"]) :where(h1, h2),
	:root:not([data-theme="light"]) :where(a:not(.wp-element-button)) { color: var(--wp--preset--color--primary); }
}

/* Dark: button hover turns the light purple; white text on it would be 2.6:1, so the text turns dark */
:root[data-theme="dark"] :where(.wp-element-button, .wp-block-button__link):not(.has-text-color):hover,
:root[data-theme="dark"] .skl-header .skl-nav-cta > .wp-block-navigation-item__content:hover,
:root[data-theme="dark"] .tribe-events .tribe-common-c-btn.tribe-common-c-btn:hover { color: var(--wp--preset--color--base) !important; }
@media (prefers-color-scheme: dark) {
	:root:not([data-theme="light"]) :where(.wp-element-button, .wp-block-button__link):not(.has-text-color):hover,
	:root:not([data-theme="light"]) .skl-header .skl-nav-cta > .wp-block-navigation-item__content:hover,
	:root:not([data-theme="light"]) .tribe-events .tribe-common-c-btn.tribe-common-c-btn:hover { color: var(--wp--preset--color--base) !important; }
}

img { filter: var(--skl-img-filter); }

/* ---------- Typography --------------------------------------------------- */
h1, h2, .wp-block-site-title, .has-display-font-family, .is-style-bar :where(h1, h2, h3) {
	font-stretch: 125%;
}
.has-display-font-family { font-weight: 900; text-transform: uppercase; line-height: 1.02; }

/* Correct heading level for screen readers, the look of the next smaller level (no visual change) */
:is(h2, h3).skl-as-h3 {
	font-family: var(--wp--preset--font-family--body); font-size: var(--wp--preset--font-size--large); font-weight: 800;
	font-stretch: 100%; line-height: 1.15; letter-spacing: .01em; text-transform: uppercase; color: var(--wp--preset--color--contrast);
}
h3.skl-as-h4 { font-size: 1.1rem; text-transform: none; }

.screen-reader-text {
	border: 0; clip: rect(1px, 1px, 1px, 1px); clip-path: inset(50%);
	height: 1px; margin: -1px; overflow: hidden; padding: 0; position: absolute !important;
	width: 1px; word-wrap: normal !important;
}
.screen-reader-text:focus {
	clip: auto !important; clip-path: none; display: block; height: auto; width: auto;
	left: 6px; top: 7px; z-index: 100000; padding: 1em; background: var(--wp--preset--color--base);
}

:where(a, button):focus-visible { outline: 2px solid var(--skl-focus, var(--wp--preset--color--primary)); outline-offset: 3px; }
/* On purple and on photos the purple ring disappears (1.4:1): a white ring there */
.skl-footer, .wp-block-group.is-style-bar, .wp-block-group.is-style-info, .wp-block-heading.is-style-bar,
.wp-block-cover, .skl-hero-title-bar { --skl-focus: #fff; }
/* The skip link moves focus to <main> (tabindex="-1"); no ring around the whole content */
main[tabindex="-1"]:focus { outline: none; }

/* Zoom to 400 % (320 px wide): long German words in the wide uppercase headings must not run out of the box */
:where(h1, h2, h3, h4, h5, h6, .has-display-font-family) { overflow-wrap: break-word; }
:where(legend, label) { overflow-wrap: anywhere; } /* "anywhere" also lets a label next to a checkbox shrink */
@media (max-width: 40rem) {
	:where(h1, h2, h3, h4, h5, h6, legend, .has-display-font-family) { hyphens: auto; hyphenate-limit-chars: 8 4 3; }
}

/* ---------- Header -------------------------------------------------------- */
.skl-header { position: relative; z-index: 20; border-bottom: 1px solid var(--skl-border); }
.skl-header .wp-block-navigation__submenu-container {
	background: var(--wp--preset--color--base) !important;
	color: var(--wp--preset--color--contrast) !important;
	border: 1px solid var(--skl-border) !important;
	box-shadow: var(--wp--preset--shadow--card);
	min-width: 16rem !important;
}
.skl-header .wp-block-navigation-item__content { text-decoration: none; }
.skl-header .wp-block-navigation .wp-block-navigation-item__content:hover { color: var(--wp--preset--color--primary); }
.skl-header .wp-block-navigation__responsive-container.is-menu-open {
	background: var(--wp--preset--color--base) !important;
	color: var(--wp--preset--color--contrast) !important;
}
.skl-header .current-menu-item > .wp-block-navigation-item__content,
.skl-header .wp-block-navigation-item__content[aria-current="page"] { color: var(--wp--preset--color--primary); }

/* Logo block */
.skl-logo { display: inline-flex; align-items: center; line-height: 0; text-decoration: none; }
.skl-logo svg { display: block; width: 100%; height: auto; }
.skl-logo__full { width: var(--skl-logo-width, 360px); max-width: 100%; }
.skl-logo__badge { display: none; width: 64px; }
@media (max-width: 899px) {
	.skl-logo__full { width: min(var(--skl-logo-width, 360px), 62vw); }
}
@media (max-width: 479px) {
	.skl-logo__full { display: none; }
	.skl-logo__badge { display: block; }
}

/* Theme switch: one quiet icon button, cycles auto / light / dark */
.skl-theme-toggle {
	display: grid; place-items: center; flex: none; width: 30px; height: 30px; padding: 0;
	border: 0; border-radius: 999px; background: transparent; color: var(--wp--preset--color--muted); cursor: pointer;
}
.skl-theme-toggle:hover { color: var(--wp--preset--color--contrast); background: var(--wp--preset--color--base-2); }
.skl-theme-toggle:focus-visible { outline: 2px solid var(--wp--preset--color--primary); outline-offset: 2px; }
.skl-theme-toggle__icon { display: none; line-height: 0; }
.skl-theme-toggle__icon svg { width: 16px; height: 16px; }
.skl-theme-toggle[data-skl-mode="auto"] [data-skl-icon="auto"],
.skl-theme-toggle[data-skl-mode="light"] [data-skl-icon="light"],
.skl-theme-toggle[data-skl-mode="dark"] [data-skl-icon="dark"] { display: block; }

.skl-theme-toggle__label { display: none; }
/* Variant inside the collapsed menu: shown only in the open overlay, as a labelled row at the end */
.skl-theme-toggle--menu { display: none; }
.is-menu-open .skl-theme-toggle--menu {
	display: inline-flex; align-items: center; gap: .5rem; width: auto; height: auto; margin-top: 1rem; padding: .35rem .8rem .35rem .6rem;
	border: 1px solid var(--skl-border); font: inherit; font-size: .95rem; font-weight: 600;
}
.is-menu-open .skl-theme-toggle--menu .skl-theme-toggle__label { display: inline; }
@media (max-width: 1099px) { .skl-header .skl-theme-toggle:not(.skl-theme-toggle--menu) { display: none; } }

/* Submenu buttons ("Untermenü von …") next to the parent link: at least 24 × 24 px to hit (WCAG 2.5.8) */
.skl-header .wp-block-navigation__responsive-container:not(.is-menu-open) .wp-block-navigation__submenu-icon {
	display: inline-flex; align-items: center; justify-content: center; width: 24px; height: 24px; margin-left: .1em; border-radius: 4px;
}
.skl-header .wp-block-navigation__responsive-container:not(.is-menu-open) .wp-block-navigation__submenu-icon svg { width: 12px; height: 12px; margin: 0; }
.skl-header .wp-block-navigation__responsive-container:not(.is-menu-open) .wp-block-navigation__submenu-icon:hover { background: var(--wp--preset--color--base-2); }

/* Header layout: logo left, one-line menu right; hamburger below 1100px (core switches at 600px only) */
.skl-header > .wp-block-group { align-items: center; }
.skl-header .skl-logo { flex: 0 1 auto; min-width: 0; }
.skl-header .wp-block-navigation { flex: none; font-weight: 700; }
.skl-header .wp-block-navigation .wp-block-navigation-item { white-space: nowrap; }
@media (min-width: 600px) and (max-width: 1099px) {
	.skl-header .wp-block-navigation__responsive-container:not(.is-menu-open) { display: none; }
	.skl-header .wp-block-navigation__responsive-container-open:not(.always-shown) { display: flex; }
}
@media (min-width: 1100px) and (max-width: 1279px) {
	.skl-header .skl-logo__full { width: 250px; }
	.skl-header .wp-block-navigation__container { gap: 1rem; }
}

/* ---------- Flyer elements / block styles --------------------------------- */

/* Heading "bar": white display heading on a purple bar (like the flyer) */
.wp-block-heading.is-style-bar {
	display: block; background: var(--wp--preset--color--primary-strong); color: #fff !important;
	font-family: var(--wp--preset--font-family--display); font-weight: 900; font-stretch: 125%;
	text-transform: uppercase; padding: .35em .6em .3em; line-height: 1.05;
}
.wp-block-heading.is-style-bar a { color: inherit !important; }

/* Group "bar": full purple band */
.wp-block-group.is-style-bar { background: var(--wp--preset--color--primary-strong); color: #fff; }
.wp-block-group.is-style-bar :where(h1, h2, h3, h4, p, li, a:not(.wp-element-button)) { color: #fff !important; }
.wp-block-group.is-style-bar .wp-element-button { background: #fff; color: #7d3d88; }
.wp-block-group.is-style-bar .wp-element-button:hover { background: #f3e9f5; color: #7d3d88; }
.wp-block-group.is-style-bar .is-style-outline .wp-element-button { background: transparent; color: #fff; border-color: #fff; }

/* Group "info": purple callout */
.wp-block-group.is-style-info {
	background: var(--wp--preset--color--primary); color: #fff;
	padding: var(--wp--preset--spacing--40); border-radius: 4px;
}
:root[data-theme="dark"] .wp-block-group.is-style-info { background: var(--wp--preset--color--primary-strong); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .wp-block-group.is-style-info { background: var(--wp--preset--color--primary-strong); } }
.wp-block-group.is-style-info :where(h2, h3, h4, p, li, a, strong) { color: #fff !important; }

/* Group "card" */
.wp-block-group.is-style-card {
	background: var(--wp--preset--color--base); border: 1px solid var(--skl-border); border-radius: 6px;
	padding: var(--wp--preset--spacing--40); box-shadow: var(--wp--preset--shadow--card);
}
.wp-block-group.is-style-card > :first-child { margin-top: 0; }

/* Group "fahrt": trip card – title left, date right, short bullets */
.wp-block-group.is-style-fahrt {
	border-top: 4px solid var(--wp--preset--color--primary);
	background: var(--wp--preset--color--base-2); padding: var(--wp--preset--spacing--40); border-radius: 0 0 6px 6px;
}
.wp-block-group.is-style-fahrt > :first-child { margin-top: 0; }
.skl-fahrt-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: .25rem 1rem; }
.skl-fahrt-head > * { margin: 0 !important; min-width: 0; } /* min-width: long titles may wrap instead of overflowing at 400 % zoom */
.skl-fahrt-date { font-weight: 700; color: var(--wp--preset--color--primary); text-align: right; }

/* List "checks" */
ul.is-style-checks { list-style: none; padding-left: 0; }
ul.is-style-checks li { position: relative; padding-left: 1.8em; margin-bottom: .35em; }
ul.is-style-checks li::before {
	content: ""; position: absolute; left: 0; top: .3em; width: 1.05em; height: 1.05em; border-radius: 50%;
	background: var(--wp--preset--color--primary) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4 8.5l2.5 2.5L12 5.5' fill='none' stroke='%23fff' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/75% no-repeat;
}

/* Tables */
.wp-block-table table { border-collapse: collapse; width: 100%; }
.wp-block-table :where(th, td) { border: 0; border-bottom: 1px solid var(--skl-border); padding: .6em .75em; text-align: left; vertical-align: top; overflow-wrap: break-word; }
@media (max-width: 40rem) {
	.wp-block-table :where(th, td) { hyphens: auto; padding: .5em .45em; }
	.skl-facts th { width: auto; }
}
/* A table still wider than the screen scrolls sideways inside its frame; functions.php then makes the frame
   focusable (role="region"), so keyboard users can scroll it too */
figure.wp-block-table[tabindex]:focus-visible { outline: 2px solid var(--skl-focus, var(--wp--preset--color--primary)); outline-offset: 2px; }
.wp-block-table thead { border-bottom: 0; }
.wp-block-table thead th { background: var(--wp--preset--color--primary-strong); color: #fff; font-weight: 700; }
.wp-block-table.is-style-stripes tbody tr:nth-child(odd) { background: var(--skl-stripe); }
.wp-block-table.is-style-stripes { border-bottom: 0; }

/* Images */
.wp-block-image.is-style-rounded-soft img { border-radius: 8px; }

/* Mountain silhouette (cover bottom edge, footer top edge) */
.wp-block-cover.is-style-mountains { overflow: hidden; }
.wp-block-cover.is-style-mountains::after,
.skl-footer::before {
	content: ""; display: block; height: clamp(40px, 7vw, 110px);
	-webkit-mask: url("../mountains.svg?v=2") bottom / 100% 100% no-repeat;
	mask: url("../mountains.svg?v=2") bottom / 100% 100% no-repeat;
}
.wp-block-cover.is-style-mountains::after {
	position: absolute; left: 0; right: 0; bottom: -1px; z-index: 2; background: var(--wp--preset--color--base);
}
.skl-footer::before { position: absolute; left: 0; right: 0; bottom: calc(100% - 1px); background: inherit; }

/* Hero */
.skl-hero .wp-block-cover__inner-container { padding-bottom: clamp(40px, 7vw, 110px); }
.skl-hero h1, .skl-hero .has-display-font-family { color: #fff !important; text-shadow: 0 2px 18px rgba(40, 10, 50, .35); }
.skl-hero-title-bar { background: var(--wp--preset--color--primary-strong); display: inline-block; padding: .2em .45em .15em; }
/* One h1 "Winterprogramm 26/27": the bar on its own line in the smaller size, the year below in poster size */
.skl-hero-title .skl-hero-title-bar {
	display: table; margin-bottom: 1.25rem; font-size: var(--wp--preset--font-size--xx-large); line-height: 1;
}
.skl-hero-title .skl-hero-year { display: block; }

/* Footer */
.skl-footer { position: relative; background: var(--wp--preset--color--primary-strong); color: #fff; margin-top: clamp(60px, 10vw, 150px) !important; }
.skl-footer :where(h2, h3, h4, p, li, a) { color: #fff !important; }
.skl-footer a:hover { opacity: .85; }
/* Impressum · Datenschutz · …: a list; the dots are drawn by CSS and are not read aloud (alt text "") */
.skl-footer-legal { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .2em .5em; }
.skl-footer-legal li + li::before { content: "·"; content: "·" / ""; margin-right: .5em; }
:root[data-theme="dark"] .skl-footer { background: #3c2342; }
@media (prefers-color-scheme: dark) {
	:root:not([data-theme="light"]) .skl-footer { background: #3c2342; }
}

/* Post cards in query loops */
.skl-post-card { height: 100%; }
.skl-post-card .wp-block-post-featured-image img { aspect-ratio: 16 / 10; object-fit: cover; border-radius: 6px 6px 0 0; }
.skl-post-card .wp-block-post-title a { text-decoration: none; }

/* Page header band */
.skl-page-header { border-bottom: 1px solid var(--skl-border); }


/* Forms (contact form + custom plugins) */
:where(input:not([type=checkbox], [type=radio], [type=submit]), select, textarea) {
	font: inherit; color: var(--wp--preset--color--contrast); background: var(--wp--preset--color--base);
	border: 1px solid var(--skl-border); border-radius: 4px; padding: .55em .7em; max-width: 100%; box-sizing: border-box;
}

/* Contact form (mu-plugins/skl-kontakt.php) */
.skl-form { display: grid; gap: 1.1rem; max-width: 40rem; }
.skl-form p { margin: 0; }
.skl-form__field { display: grid; gap: .35rem; }
.skl-form__field label { font-weight: 600; }
.skl-form__field :is(input, textarea) { width: 100%; }
.skl-form__field textarea { resize: vertical; min-height: 9rem; }
.skl-form__field [aria-invalid="true"] { border-color: #b3261e; }
.skl-form__req { color: var(--wp--preset--color--primary-strong); }
.skl-form__error { color: #b3261e; font-size: .9rem; }
.skl-form__alert { border-left: 4px solid #b3261e; background: color-mix(in srgb, #b3261e 8%, transparent); padding: .75rem 1rem; border-radius: 4px; }
.skl-form__note { font-size: .9rem; opacity: .85; }
.skl-form__alert ul { margin: .35em 0 0; padding-left: 1.2em; }
.skl-form__hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.skl-form-done:focus { outline: none; }
@media (prefers-color-scheme: dark) {
	:root:not([data-theme="light"]) :is(.skl-form__error, .skl-form__field [aria-invalid="true"]) { color: #ffb4ab; border-color: #ffb4ab; }
}
:root[data-theme="dark"] :is(.skl-form__error, .skl-form__field [aria-invalid="true"]) { color: #ffb4ab; border-color: #ffb4ab; }

/* Header CTA item + footer lists */
.skl-header .skl-nav-cta > .wp-block-navigation-item__content {
	background: var(--wp--preset--color--primary-strong); color: #fff !important; padding: .5em 1em; border-radius: 4px;
	text-transform: uppercase; letter-spacing: .04em; font-size: .85rem;
}
.skl-header .skl-nav-cta > .wp-block-navigation-item__content:hover { background: var(--wp--preset--color--primary); }
.skl-footer-list { list-style: none; }
.skl-footer-list a { text-decoration: none; }
.skl-footer-list a:hover { text-decoration: underline; }
.skl-footer .wp-block-social-link a { color: #7d3d88 !important; }
/* One calm hover instead of core's quick scale stacked with the footer's link fade */
.skl-footer .wp-block-social-link { transition: transform .2s ease, background-color .2s ease; }
.skl-footer .wp-block-social-link:hover,
.skl-footer .wp-block-social-link:focus-within { transform: translateY(-2px); background-color: #f3e9f5 !important; }
.skl-footer .wp-block-social-link a:hover { opacity: 1; }
@media (prefers-reduced-motion: reduce) {
	.skl-footer .wp-block-social-link { transition: background-color .2s ease; }
	.skl-footer .wp-block-social-link:hover, .skl-footer .wp-block-social-link:focus-within { transform: none; }
}

/* Events list block (skl/events) */
.skl-events { display: grid; gap: var(--wp--preset--spacing--30); grid-template-columns: repeat(auto-fill, minmax(min(100%, 22rem), 1fr)); }
.skl-events.is-list { grid-template-columns: 1fr; }
.skl-events > * { min-width: 0; } /* a long one-word title must wrap, not widen the grid track */
.skl-events .wp-block-group.is-style-fahrt { display: flex; flex-direction: column; gap: .5rem; margin: 0; }
.skl-event__title { margin: 0; font-size: var(--wp--preset--font-size--large); }
.skl-event__title a { color: inherit !important; text-decoration: none; }
.skl-event__title a:hover { text-decoration: underline; }
.skl-event__meta { margin: 0; color: var(--wp--preset--color--muted); font-weight: 600; }
.skl-event__excerpt { margin: 0; }
.skl-event__excerpt ul { margin: .25rem 0 0; padding-left: 1.1rem; }
.skl-event__more { margin: auto 0 0; font-weight: 700; }
.skl-event__more a { text-decoration: none; }
.skl-events__empty { color: var(--wp--preset--color--muted); }

/* Contact cards & fact tables */
.skl-contact__role { color: var(--wp--preset--color--muted); margin-top: 0 !important; }
.skl-contact h3 { margin-bottom: 0; }
.skl-contact a { text-underline-offset: .15em; } /* underlined: colour alone (2.4:1 to the text) is not enough */
.skl-facts th { width: 38%; font-weight: 700; color: var(--wp--preset--color--muted); background: transparent !important; }
.skl-facts td, .skl-facts th { border-bottom-color: var(--skl-border); }
.skl-fahrt-date { margin: 0; }

/* Flyer-like sections use the wide width inside normal page content */
.wp-block-post-content.is-layout-constrained > :is(.wp-block-heading.is-style-bar, .skl-events, .wp-block-columns, .wp-block-group.is-layout-grid, .wp-block-query, .wp-block-group.is-style-bar) {
	max-width: var(--wp--style--global--wide-size);
}
.wp-block-post-content.is-layout-constrained > .wp-block-heading.is-style-bar { margin-top: var(--wp--preset--spacing--60); margin-bottom: var(--wp--preset--spacing--40); }

/* The Events Calendar single view */
.tribe-events-single a.wp-block-button__link, .tribe-events-single .wp-element-button { color: #fff; }
.tribe-events-single .is-style-outline .wp-block-button__link { color: var(--wp--preset--color--primary-strong); }
.tribe-events-single .tribe-events-single-event-title { font-family: var(--wp--preset--font-family--display); font-stretch: 125%; font-weight: 900; text-transform: uppercase; color: var(--wp--preset--color--primary-strong); }
.tribe-events-single .tribe-events-schedule h2, .tribe-events-schedule .tribe-events-schedule__datetime { font-family: var(--wp--preset--font-family--body); font-stretch: 100%; text-transform: none; font-weight: 700; color: var(--wp--preset--color--primary); font-size: var(--wp--preset--font-size--large); }
.tribe-events-single, .tribe-events-single p, .tribe-events-single li { font-size: var(--wp--preset--font-size--medium); color: var(--wp--preset--color--contrast); }
/* TEC removes the underline; links in running text must not differ by colour alone (2.3:1 in dark mode) */
.tribe-events-single :where(p, li, td, dd) a:not(.wp-element-button):not(.wp-block-button__link) { text-decoration: underline; text-underline-offset: .15em; }

/* Mobile overlay menu: left-aligned, larger targets */
.skl-header .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-container-content,
.skl-header .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__container,
.skl-header .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation-item,
.skl-header .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__submenu-container { align-items: flex-start !important; text-align: left; }
.skl-header .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-container-content { padding: 3.5rem 1.5rem 2rem; }
.skl-header .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__container { gap: 1.1rem; font-size: 1.15rem; }
.skl-header .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__submenu-container { border: 0 !important; box-shadow: none; padding: .4rem 0 0 1rem !important; gap: .6rem; font-size: 1rem; font-weight: 600; min-width: 0 !important; }

/* Logged-in only: keep the WordPress toolbar on one row at tablet widths (it would wrap over the header) */
@media (min-width: 783px) and (max-width: 1150px) {
	#wpadminbar #wp-admin-bar-tribe-events,
	#wpadminbar #wp-admin-bar-comments,
	#wpadminbar #wp-admin-bar-customize,
	#wpadminbar #wp-admin-bar-new-content { display: none; }
}
.skl-header .wp-block-navigation__responsive-container.is-menu-open .skl-nav-cta > .wp-block-navigation-item__content { padding: .5em 1em !important; }

/* Open menu, compact: sub-items flow in a wrapping row under their parent so the whole menu fits one screen */
.skl-header .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-container-content { padding: 3rem 1.25rem 1.5rem; }
.skl-header .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__container { gap: .85rem; font-size: 1.1rem; }
.skl-header .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__submenu-container {
	flex-direction: row !important; flex-wrap: wrap; gap: .1rem 1.1rem; padding: .2rem 0 0 0 !important;
	font-size: .93rem; font-weight: 500;
}
.skl-header .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__submenu-container .wp-block-navigation-item__content {
	padding: .15rem 0 !important; color: var(--wp--preset--color--muted);
}
.skl-header .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation-item > .wp-block-navigation-item__content { padding-top: 0; padding-bottom: 0; }

/* ---------- The Events Calendar ------------------------------------------ */
/* The plugin declares its colour variables on :root and derives others from them there, so the
   mapping must sit on :root too (html:root outranks the plugin's own :root). All values are theme
   tokens, which already switch with the colour scheme – no separate dark block needed. */
html:root {
	--tec-font-family-sans-serif: var(--wp--preset--font-family--body);
	--tec-font-family-base: var(--wp--preset--font-family--body);
	--tec-color-text-primary: var(--wp--preset--color--contrast);
	--tec-color-text-primary-light: var(--wp--preset--color--muted);
	--tec-color-text-secondary: var(--wp--preset--color--muted);
	--tec-color-text-disabled: var(--skl-border);
	--tec-color-text-events-title: var(--wp--preset--color--contrast);
	--tec-color-text-event-title: var(--wp--preset--color--contrast);
	--tec-color-text-event-date: var(--wp--preset--color--primary);
	--tec-color-text-secondary-event-date: var(--wp--preset--color--muted);
	--tec-color-link-primary: var(--wp--preset--color--contrast);
	--tec-color-link-accent: var(--wp--preset--color--primary);
	--tec-color-link-accent-hover: var(--wp--preset--color--primary-strong);
	--tec-color-accent-primary: var(--wp--preset--color--primary-strong);
	--tec-color-accent-primary-hover: var(--wp--preset--color--primary);
	--tec-color-accent-primary-active: var(--wp--preset--color--primary);
	--tec-color-accent-primary-background: var(--wp--preset--color--primary-soft);
	--tec-color-accent-primary-background-datepicker: var(--wp--preset--color--primary-soft);
	--tec-color-accent-secondary: var(--wp--preset--color--contrast);
	--tec-color-accent-secondary-hover: var(--wp--preset--color--primary);
	--tec-color-accent-secondary-active: var(--wp--preset--color--primary);
	--tec-color-accent-secondary-background: var(--wp--preset--color--base-2);
	--tec-color-button-primary: var(--wp--preset--color--primary-strong);
	--tec-color-button-primary-hover: var(--wp--preset--color--primary);
	--tec-color-button-primary-active: var(--wp--preset--color--primary);
	--tec-color-button-primary-background: var(--wp--preset--color--primary-soft);
	--tec-color-button-secondary: var(--wp--preset--color--contrast);
	--tec-color-button-secondary-hover: var(--wp--preset--color--primary);
	--tec-color-button-secondary-active: var(--wp--preset--color--primary);
	--tec-color-button-secondary-background: var(--wp--preset--color--base-2);
	--tec-color-background: var(--wp--preset--color--base);
	--tec-color-background-events: transparent;
	--tec-color-background-transparent: color-mix(in srgb, var(--wp--preset--color--base) 60%, transparent);
	--tec-color-background-secondary: var(--wp--preset--color--base-2);
	--tec-color-background-secondary-datepicker: var(--wp--preset--color--base-2);
	--tec-color-background-secondary-hover: var(--wp--preset--color--primary-soft);
	--tec-color-background-messages: var(--wp--preset--color--base-2);
	--tec-color-background-primary-multiday: var(--wp--preset--color--primary-soft);
	--tec-color-background-primary-multiday-hover: color-mix(in srgb, var(--wp--preset--color--primary) 35%, transparent);
	--tec-color-background-secondary-multiday: var(--wp--preset--color--primary-soft);
	--tec-color-background-secondary-multiday-hover: color-mix(in srgb, var(--wp--preset--color--primary) 35%, transparent);
	--tec-color-border-default: var(--skl-border);
	--tec-color-border-secondary: var(--skl-border);
	--tec-color-border-tertiary: var(--wp--preset--color--muted);
	--tec-color-border-hover: var(--wp--preset--color--primary);
	--tec-color-border-active: var(--wp--preset--color--primary);
	--tec-color-icon-primary: var(--wp--preset--color--muted);
	--tec-color-icon-primary-alt: var(--wp--preset--color--muted);
	--tec-color-icon-secondary: var(--wp--preset--color--muted);
	--tec-color-icon-active: var(--wp--preset--color--contrast);
	--tec-color-icon-disabled: var(--skl-border);
	--tec-color-icon-focus: var(--wp--preset--color--primary);
	--tec-color-event-icon: var(--wp--preset--color--muted);
	--tec-color-event-icon-hover: var(--wp--preset--color--primary);
}

/* TEC switches the focus ring off on some of its buttons ("Heute"): always a visible ring */
.tribe-events :is(a, button):focus-visible { outline: 2px solid var(--skl-focus, var(--wp--preset--color--primary)) !important; outline-offset: 2px; }

/* Archive (list / month / day) */
.tribe-events.tribe-common { background: transparent; }
.tribe-events .tribe-events-l-container { padding-top: var(--wp--preset--spacing--50) !important; padding-bottom: var(--wp--preset--spacing--60) !important; }
.tribe-events .tribe-events-header__events-bar,
.tribe-events .tribe-events-c-events-bar,
.tribe-events .tribe-events-c-events-bar__search-container,
.tribe-events .tribe-events-c-events-bar__views,
.tribe-events .tribe-events-c-view-selector__content {
	background-color: var(--wp--preset--color--base-2) !important;
}
.tribe-events .tribe-events-c-events-bar { border: 1px solid var(--skl-border) !important; border-radius: 6px; }
.tribe-events .tribe-events-c-events-bar .tribe-common-form-control-text__input {
	background: transparent !important; color: var(--wp--preset--color--contrast) !important; border: 0;
}
.tribe-events .tribe-events-c-events-bar .tribe-common-form-control-text__input::placeholder { color: var(--wp--preset--color--muted); opacity: 1; }
.tribe-events .tribe-common-c-btn,
.tribe-events .tribe-common-c-btn:focus {
	background-color: var(--wp--preset--color--primary-strong); color: #fff !important; border-radius: 4px;
	text-transform: uppercase; letter-spacing: .04em; font-size: .85rem; font-weight: 700;
}
.tribe-events .tribe-common-c-btn:hover { background-color: var(--wp--preset--color--primary); color: #fff; }
.tribe-events .tribe-common-c-btn-border,
.tribe-events a.tribe-common-c-btn-border,
.tribe-events .tribe-common-c-btn-border-small,
.tribe-events a.tribe-common-c-btn-border-small {
	background: transparent; color: var(--wp--preset--color--contrast); border-color: var(--skl-border); border-radius: 4px;
}
.tribe-events .tribe-common-c-btn-border:hover,
.tribe-events .tribe-common-c-btn-border-small:hover { border-color: var(--wp--preset--color--primary); color: var(--wp--preset--color--primary); background: transparent; }
.tribe-events .tribe-events-c-top-bar__datepicker-button,
.tribe-events .tribe-events-calendar-list__month-separator-text,
.tribe-events .tribe-events-calendar-list__event-date-tag-daynum,
.tribe-events .tribe-events-calendar-month__day-date-daynum,
.tribe-events .tribe-events-calendar-month__header-column-title { color: var(--wp--preset--color--contrast); }
.tribe-events .tribe-events-c-top-bar__datepicker-button { font-family: var(--wp--preset--font-family--display); font-stretch: 125%; font-weight: 800; text-transform: uppercase; font-size: clamp(1.1rem, 2.2vw, 1.6rem); }
.tribe-events .tribe-events-calendar-list__event-title,
.tribe-events .tribe-events-calendar-day__event-title { font-family: var(--wp--preset--font-family--body); font-weight: 800; }
.tribe-events .tribe-events-calendar-list__event-title-link,
.tribe-events .tribe-events-calendar-day__event-title-link,
.tribe-events .tribe-events-calendar-month__calendar-event-title-link,
.tribe-events .tribe-events-calendar-month-mobile-events__mobile-event-title-link { color: var(--wp--preset--color--contrast) !important; text-decoration: none; }
.tribe-events .tribe-events-calendar-list__event-title-link:hover,
.tribe-events .tribe-events-calendar-day__event-title-link:hover,
.tribe-events .tribe-events-calendar-month__calendar-event-title-link:hover { color: var(--wp--preset--color--primary) !important; border-bottom-color: transparent !important; }
.tribe-events .tribe-events-calendar-list__event-datetime,
.tribe-events .tribe-events-calendar-list__event-date-tag-weekday { color: var(--wp--preset--color--primary); font-weight: 700; }
.tribe-events .tribe-events-calendar-list__event-description,
.tribe-events .tribe-events-calendar-list__event-venue { color: var(--wp--preset--color--contrast); }
.tribe-events .tribe-events-calendar-list__event-description ul { margin: .3em 0 0; padding-left: 1.1em; }

/* List rows as the theme's "fahrt" trip cards: tinted card, purple top bar, uppercase title */
.tribe-events .tribe-events-calendar-list__event-row {
	margin: 0 0 var(--wp--preset--spacing--30) !important; padding: var(--wp--preset--spacing--30) 0;
	background: var(--wp--preset--color--base-2); border-top: 4px solid var(--wp--preset--color--primary); border-radius: 0 0 6px 6px;
}
.tribe-events .tribe-events-calendar-list__event-row .tribe-events-calendar-list__event { margin-bottom: 0; margin-right: 0; } /* TEC's -21px gutter ran past the card edge (and the screen at 400 % zoom) */
.tribe-events .tribe-events-calendar-list__event-title { text-transform: uppercase !important; letter-spacing: .01em; line-height: 1.15 !important; font-weight: 800 !important; }
.tribe-events .tribe-events-calendar-list__event-title-link { font-weight: inherit; }
.tribe-events .tribe-events-calendar-list__event-date-tag-weekday { text-transform: uppercase; letter-spacing: .06em; font-size: .8rem !important; }
.tribe-events .tribe-events-calendar-list__event-date-tag-daynum { font-family: var(--wp--preset--font-family--display) !important; font-stretch: 125%; font-weight: 900 !important; }
.tribe-events .tribe-events-calendar-list__month-separator { margin-top: var(--wp--preset--spacing--40); }
.tribe-events .tribe-events-calendar-list__month-separator::after { display: none; }
.tribe-events .tribe-events-calendar-list__month-separator-text {
	font-family: var(--wp--preset--font-family--display) !important; font-stretch: 125%; font-weight: 900 !important; text-transform: uppercase !important;
	color: var(--wp--preset--color--primary) !important; font-size: var(--wp--preset--font-size--large) !important; line-height: 1.1 !important;
}

/* Bottom pagination + subscribe: the theme's outline buttons */
.tribe-events .tribe-events-calendar-list-nav.tribe-events-c-nav { border-top: 0 !important; padding-top: var(--wp--preset--spacing--20) !important; }
.tribe-events .tribe-events-c-nav__prev, .tribe-events .tribe-events-c-nav__next {
	display: inline-flex; align-items: center; gap: .5em; padding: .8em 1.4em; border: 1px solid var(--wp--preset--color--primary); border-radius: 4px;
	color: var(--wp--preset--color--primary) !important; background: transparent; text-transform: uppercase; letter-spacing: .04em; text-decoration: none;
	font-weight: 700 !important; font-size: .95rem !important; line-height: 1.2 !important;
}
.tribe-events .tribe-events-c-nav__prev:not(:disabled):hover, .tribe-events .tribe-events-c-nav__next:not(:disabled):hover {
	background: var(--wp--preset--color--primary-strong); border-color: var(--wp--preset--color--primary-strong); color: #fff !important;
}
.tribe-events .tribe-events-c-nav__prev svg, .tribe-events .tribe-events-c-nav__next svg { margin: 0; }
.tribe-events .tribe-events-c-nav__prev path, .tribe-events .tribe-events-c-nav__next path { fill: currentColor !important; }
.tribe-events .tribe-events-c-nav__today { color: var(--wp--preset--color--contrast); }
/* Nothing earlier/later to page to: drop the dead button instead of showing it greyed out */
.tribe-events .tribe-events-c-nav__list-item:has(> :disabled) { visibility: hidden; }
.tribe-events .tribe-events-c-subscribe-dropdown__button {
	border: 1px solid var(--wp--preset--color--primary); border-radius: 4px; color: var(--wp--preset--color--primary) !important; background: transparent;
}
.tribe-events .tribe-events-c-subscribe-dropdown__button-text { font-weight: 700; text-transform: uppercase; letter-spacing: .04em; font-size: .95rem; color: inherit !important; }
.tribe-events .tribe-events-c-subscribe-dropdown__button:hover,
.tribe-events .tribe-events-c-subscribe-dropdown__button:focus-within { background: var(--wp--preset--color--primary-strong); border-color: var(--wp--preset--color--primary-strong); color: #fff !important; }
.tribe-events .tribe-events-c-subscribe-dropdown__content,
.tribe-events .tribe-events-c-subscribe-dropdown__list { background: var(--wp--preset--color--base-2); border-color: var(--skl-border); }
.tribe-events .tribe-events-c-subscribe-dropdown__list-item a { color: var(--wp--preset--color--contrast); }
.tribe-events .tribe-events-calendar-month__day--current .tribe-events-calendar-month__day-date-daynum,
.tribe-events .tribe-events-calendar-month__day--current .tribe-events-calendar-month__day-date-link { color: var(--wp--preset--color--primary); }
/* Phone month view: the selected day (today on load) is filled with the accent colour; its number in white
   (the two rules above would make it primary on primary-strong, 1.4:1, or dark on the accent) */
.tribe-events .tribe-events-calendar-month__day-cell--selected .tribe-events-calendar-month__day-date-daynum,
.tribe-events .tribe-events-calendar-month__day-cell--selected .tribe-events-calendar-month__day-date-link { color: #fff; }
.tribe-events .datepicker { background: var(--wp--preset--color--base-2); color: var(--wp--preset--color--contrast); border-color: var(--skl-border); }
.tribe-events .datepicker .datepicker-switch, .tribe-events .datepicker .day, .tribe-events .datepicker .month, .tribe-events .datepicker .year, .tribe-events .datepicker .dow { color: var(--wp--preset--color--contrast); }
