/*
 * MTC Cabinet Niling - responsive theme (2026)
 * Mobile-first, plain CSS, no external fonts or CDN.
 * Everything is scoped under body.mtc so PHPCMS back-office pages are not affected.
 * Palette derived from the original site: #005475 (page), #0f5d7c (titles), #479cc5 (sub-menu), #ffa800 (hover).
 */

:root {
	--mtc-teal-900: #003f58;
	--mtc-teal-800: #005475;   /* original page background */
	--mtc-teal-700: #0f5d7c;   /* original titles */
	--mtc-teal-600: #136f94;
	--mtc-sky-500: #479cc5;    /* original sub-menu */
	--mtc-sky-100: #e4f1f7;
	--mtc-amber-400: #ffc04d;  /* lighter version of the original #ffa800 hover, AA on teal */
	--mtc-amber-600: #9a5c00;  /* AA on white (5.4:1) */
	--mtc-ink: #24292e;
	--mtc-ink-soft: #4a5258;
	--mtc-line: #d5dee3;
	--mtc-bg: #eef3f5;
	--mtc-card: #ffffff;
	--mtc-radius: 10px;
	--mtc-shadow: 0 1px 2px rgba(0, 40, 60, .06), 0 4px 14px rgba(0, 40, 60, .07);
	--mtc-font: "Segoe UI", -apple-system, BlinkMacSystemFont, Roboto, "Helvetica Neue", Arial, sans-serif;
	--mtc-font-title: Georgia, "Times New Roman", serif;
}

/* ---------- base ---------- */
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; background: var(--mtc-teal-800); }
body.mtc {
	margin: 0;
	background: var(--mtc-bg);
	color: var(--mtc-ink);
	font-family: var(--mtc-font);
	font-size: 1rem;
	line-height: 1.6;
}
.mtc *, .mtc *::before, .mtc *::after { box-sizing: border-box; }
.mtc img { border: 0; max-width: 100%; height: auto; }
.mtc a { color: var(--mtc-teal-700); text-decoration-thickness: 1px; text-underline-offset: 2px; }
.mtc a:hover { color: var(--mtc-amber-600); }
.mtc :focus-visible { outline: 3px solid var(--mtc-teal-600); outline-offset: 2px; border-radius: 3px; }
.mtc h1, .mtc h2, .mtc h3 { line-height: 1.25; }
.mtc-visually-hidden {
	position: absolute !important;
	width: 1px; height: 1px;
	margin: -1px; padding: 0; border: 0;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
}

/* ---------- header + navigation ---------- */
.mtc-header {
	background: var(--mtc-teal-800);
	color: #fff;
	position: relative;
	z-index: 20;
	box-shadow: 0 2px 10px rgba(0, 0, 0, .18);
}
.mtc-header__inner {
	max-width: 1180px;
	margin: 0 auto;
	padding: 10px 16px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
}
.mtc-logo { display: block; flex: 0 0 auto; width: 87px; height: 78px; overflow: hidden; border-radius: 8px; line-height: 0; }
/* show the portrait and red seal of the original logo image, without its empty margins (the file itself is unchanged) */
.mtc .mtc-logo img { display: block; width: 163px; height: auto; max-width: none; margin: -14px 0 0 -62px; }
.mtc .mtc-header :focus-visible { outline-color: var(--mtc-amber-400); }

.mtc-nav-toggle {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 48px;
	height: 48px;
	padding: 0;
	border: 2px solid rgba(255, 255, 255, .55);
	border-radius: 8px;
	background: transparent;
	color: #fff;
	cursor: pointer;
}
.mtc-nav-toggle:hover { border-color: var(--mtc-amber-400); color: var(--mtc-amber-400); }
.mtc-nav-toggle__bars,
.mtc-nav-toggle__bars::before,
.mtc-nav-toggle__bars::after {
	display: block;
	width: 22px;
	height: 2px;
	background: currentColor;
	border-radius: 2px;
	position: relative;
	transition: transform .2s ease, background-color .2s ease;
}
.mtc-nav-toggle__bars::before, .mtc-nav-toggle__bars::after { content: ""; position: absolute; left: 0; }
.mtc-nav-toggle__bars::before { top: -7px; }
.mtc-nav-toggle__bars::after { top: 7px; }
.mtc-nav-toggle[aria-expanded="true"] .mtc-nav-toggle__bars { background: transparent; }
.mtc-nav-toggle[aria-expanded="true"] .mtc-nav-toggle__bars::before { transform: translateY(7px) rotate(45deg); }
.mtc-nav-toggle[aria-expanded="true"] .mtc-nav-toggle__bars::after { transform: translateY(-7px) rotate(-45deg); }
/* no JavaScript: the menu is simply always open, the toggle is useless */
html:not(.mtc-js) .mtc-nav-toggle { display: none; }

.mtc-nav { background: var(--mtc-teal-900); }
.mtc-js .mtc-nav { display: none; }
.mtc-js .mtc-nav.mtc-nav--open { display: block; }
.mtc-nav__list, .mtc-nav__sub { list-style: none; margin: 0; padding: 0; }
.mtc-nav__list { max-width: 1180px; margin: 0 auto; padding: 6px 0 12px; }
.mtc-nav__item { border-top: 1px solid rgba(255, 255, 255, .1); }
.mtc-nav__item:first-child { border-top: 0; }
.mtc-nav__link,
.mtc-nav__button {
	display: flex;
	align-items: center;
	justify-content: space-between;
	width: 100%;
	min-height: 48px;
	padding: 10px 18px;
	border: 0;
	background: transparent;
	color: #fff;
	font: inherit;
	font-size: 1.05rem;
	font-weight: 600;
	text-align: left;
	text-decoration: none;
	cursor: pointer;
}
.mtc .mtc-nav__link { color: #fff; }
.mtc .mtc-nav__link:hover, .mtc-nav__button:hover { color: var(--mtc-amber-400); }
.mtc-nav__item--current > .mtc-nav__link,
.mtc-nav__item--current > .mtc-nav__button { box-shadow: inset 4px 0 0 var(--mtc-amber-400); }
.mtc-nav__button::after {
	content: "";
	width: 9px;
	height: 9px;
	margin-left: 12px;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	transform: rotate(45deg) translateY(-3px);
	transition: transform .2s ease;
	flex: 0 0 auto;
}
.mtc-nav__button[aria-expanded="true"]::after { transform: rotate(-135deg) translateY(-2px); }
.mtc-nav__sub { background: rgba(255, 255, 255, .06); padding: 4px 0 8px; }
.mtc-js .mtc-nav__sub { display: none; }
.mtc-js .mtc-nav__sub.mtc-nav__sub--open { display: block; }
.mtc .mtc-nav__sub a {
	display: block;
	padding: 10px 18px 10px 34px;
	color: #e9f5fa;
	text-decoration: none;
	font-size: 1rem;
}
.mtc .mtc-nav__sub a:hover { color: var(--mtc-amber-400); background: rgba(255, 255, 255, .06); }

/* ---------- page frame ---------- */
.mtc-layout {
	max-width: 1180px;
	margin: 0 auto;
	padding: 16px 16px 32px;
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: 24px;
}
.mtc-main { min-width: 0; }

.mtc-banner { margin: 0 0 20px; line-height: 0; }
.mtc-banner img {
	display: block;
	width: 100%;
	max-width: 768px;
	margin: 0 auto;
	/* no frame, no shadow: the white edges of the picture melt into the page background (like the original site) */
	mix-blend-mode: multiply;
	clip-path: inset(.5% 0 0 .3%); /* hides the 1px grey line on the top/left edge of the picture file */
}

.mtc-card {
	background: var(--mtc-card);
	border: 1px solid var(--mtc-line);
	border-radius: var(--mtc-radius);
	box-shadow: var(--mtc-shadow);
	padding: 18px;
}
.mtc-section { margin: 0 0 24px; }
.mtc-title {
	margin: 0 0 10px;
	color: var(--mtc-teal-700);
	font-family: var(--mtc-font-title);
	font-size: 1.45rem;
	font-weight: 700;
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	justify-content: space-between;
	gap: 4px 16px;
}
.mtc-title {
	padding-bottom: 10px;
	background: linear-gradient(var(--mtc-amber-400), var(--mtc-amber-400)) left bottom / 64px 3px no-repeat;
}
.mtc-title__more { font-family: var(--mtc-font); font-size: .95rem; margin-left: auto; }

.mtc-more { margin: 10px 0 0; text-align: right; }
.mtc a.plus, .mtc .mtc-more a, .mtc .mtc-title__more a { color: var(--mtc-teal-700); font-weight: 700; text-decoration: none; white-space: nowrap; }
.mtc a.plus:hover, .mtc .mtc-more a:hover, .mtc .mtc-title__more a:hover { color: var(--mtc-amber-600); text-decoration: underline; }

/* ---------- home: information + opening hours ---------- */
.mtc-notice { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; margin: 0 0 24px; }
.mtc-notice__title { margin: 0 0 10px; color: #0072a0; font-family: var(--mtc-font-title); font-size: 1.4rem; text-align: center; }
.mtc-notice__list { margin: 0; padding: 0 0 0 1.2em; }
.mtc-notice__list li { padding: 6px 0; border-bottom: 1px dotted var(--mtc-line); font-weight: 600; overflow-wrap: anywhere; }
.mtc-notice__list:empty { display: none; }
.mtc .rN_2_a { margin: 4px 0; color: var(--mtc-ink-soft); font-size: 1.05rem; font-weight: 700; }

/* ---------- home: specialist block ---------- */
.mtc-specialist a {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: center;
	gap: 16px;
	text-decoration: none;
}
.mtc-specialist img { display: block; border-radius: 6px; }

.mtc-welcome { font-size: 1.02rem; }
.mtc-welcome p { margin: 0 0 .6em; }

/* ---------- home: therapy thumbnails ---------- */
.mtc-tiles {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
	gap: 14px;
}
.mtc-tiles:empty { display: none; }
.mtc .mtc-tile a {
	display: block;
	height: 100%;
	background: var(--mtc-card);
	border: 1px solid var(--mtc-line);
	border-radius: var(--mtc-radius);
	overflow: hidden;
	text-decoration: none;
	box-shadow: var(--mtc-shadow);
	transition: transform .15s ease, box-shadow .15s ease;
}
.mtc .mtc-tile a:hover { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(0, 40, 60, .16); }
.mtc-tile img { display: block; width: 100%; aspect-ratio: 151 / 102; object-fit: cover; }
.mtc-tile__title {
	margin: 0;
	padding: 8px 10px;
	background: var(--mtc-teal-700);
	color: #fff;
	font-size: .95rem;
	font-weight: 700;
	text-align: center;
}
.mtc .mtc-tile a:hover .mtc-tile__title { background: var(--mtc-teal-800); color: var(--mtc-amber-400); }

/* ---------- breadcrumb ---------- */
.mtc-breadcrumb { margin: 0 0 12px; color: var(--mtc-teal-700); font-size: .95rem; font-weight: 600; overflow-wrap: anywhere; }
.mtc-breadcrumb a { color: var(--mtc-teal-700); }

/* ---------- lists ---------- */
.mtc-list { list-style: none; margin: 0; padding: 0; }
.mtc-list li {
	display: flex;
	flex-wrap: wrap-reverse;
	justify-content: space-between;
	gap: 2px 16px;
	padding: 10px 0;
	border-bottom: 1px dotted var(--mtc-line);
}
.mtc-list li:last-child { border-bottom: 0; }
.mtc-list a { font-weight: 600; text-decoration: none; }
.mtc-list a:hover { text-decoration: underline; }
.mtc-list__date { color: var(--mtc-ink-soft); font-size: .9rem; font-variant-numeric: tabular-nums; }
.mtc-list:empty { display: none; }

.mtc-cards { list-style: none; margin: 0; padding: 0; display: grid; gap: 16px; }
.mtc-cards:empty { display: none; }
.mtc-entry {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: 14px;
	padding: 14px;
	background: #f6f9fa;
	border: 1px solid var(--mtc-line);
	border-radius: var(--mtc-radius);
}
.mtc-entry__img { display: block; width: 100%; max-width: 211px; padding: 3px; background: #fff; border: 1px solid var(--mtc-line); border-radius: 6px; }
.mtc-entry__title { margin: 0 0 6px; padding: 4px 10px; background: #dde6ea; border-radius: 6px; font-size: 1.1rem; text-align: center; }
.mtc-entry__text { margin: 0; line-height: 1.55; }

/* ---------- pagination (PHPCMS pages() markup) ---------- */
.mtc-pages { margin: 20px 0 0; text-align: center; }
.mtc-pages a, .mtc-pages span {
	display: inline-block;
	min-width: 36px;
	margin: 3px 2px;
	padding: 6px 10px;
	border: 1px solid var(--mtc-line);
	border-radius: 6px;
	background: #fff;
	text-decoration: none;
	vertical-align: middle;
}
.mtc-pages span { background: var(--mtc-teal-700); border-color: var(--mtc-teal-700); color: #fff; }
.mtc-pages img { vertical-align: middle; }
.mtc-pages:empty { display: none; }

/* ---------- article / page content coming from the CMS ---------- */
.mtc-content { font-size: 1.02rem; line-height: 1.7; overflow-wrap: break-word; }
.mtc-content > :first-child { margin-top: 0; }
.mtc-content img { height: auto !important; max-width: 100% !important; }
.mtc-content table { display: block; max-width: 100%; overflow-x: auto; border-collapse: collapse; }
.mtc-content td, .mtc-content th { padding: 4px 8px; vertical-align: top; }
.mtc-content iframe, .mtc-content object, .mtc-content embed, .mtc-content video { max-width: 100%; }
.mtc-content p { margin: 0 0 .8em; }

/* ---------- aside: maps + contact ---------- */
.mtc-aside { min-width: 0; }
.mtc-aside__title {
	margin: 0 0 12px;
	padding: 6px 14px;
	border-radius: 6px;
	background: var(--mtc-teal-700);
	color: #fff;
	font-size: 1.05rem;
}
.mtc-maps { display: flex; flex-wrap: wrap; gap: 12px; margin: 0 0 16px; }
.mtc-maps img { display: block; border: 1px solid var(--mtc-line); border-radius: 6px; background: #fff; }

.mtc-contact {
	overflow: hidden;
	border-radius: var(--mtc-radius);
	background: #005f86;
	color: #fff;
	box-shadow: var(--mtc-shadow);
}
/* top strip of the original contact image (it holds the phone icon and the word CONTACT) */
.mtc-contact__head {
	width: 206px;
	max-width: 100%;
	height: 62px;
	background: #0a86c0 url(../../images/index_07.jpg) no-repeat 0 0;
	border-bottom-right-radius: 8px;
}
.mtc-contact__body { padding: 12px 16px 16px; font-size: 1.05rem; }
.mtc-contact__body p { margin: 0 0 6px; }
.mtc .mtc-contact a { color: #fff; text-decoration: underline; }
.mtc .mtc-contact a:hover { color: var(--mtc-amber-400); }
/* old absolute positioning of the contact lines is no longer needed */
.mtc .lc-1, .mtc .lc-2, .mtc .lc-3, .mtc .lc-4 { position: static; color: inherit; font-size: inherit; }

/* ---------- forms (formguide "Message") ---------- */
.mtc-form { max-width: 640px; }
.mtc-form__row { margin: 0 0 16px; }
.mtc-form__label { display: block; margin: 0 0 4px; font-weight: 700; }
.mtc-form__req { color: #b00020; }
.mtc-form input[type="text"], .mtc-form input[type="email"], .mtc-form textarea, .mtc-form select {
	width: 100% !important;
	max-width: 100%;
	min-height: 44px;
	padding: 8px 10px;
	border: 1px solid #8a99a3;
	border-radius: 6px;
	font: inherit;
	color: var(--mtc-ink);
	background: #fff;
}
.mtc-form textarea { min-height: 160px; }
.mtc-form input:focus, .mtc-form textarea:focus { border-color: var(--mtc-teal-600); }
.mtc-button {
	display: inline-block;
	min-height: 44px;
	padding: 10px 22px;
	border: 0;
	border-radius: 8px;
	background: var(--mtc-teal-700);
	color: #fff;
	font: inherit;
	font-weight: 700;
	cursor: pointer;
}
.mtc-button:hover { background: var(--mtc-teal-800); color: var(--mtc-amber-400); }

/* ---------- footer ---------- */
.mtc-footer { background: var(--mtc-teal-800); color: #fff; text-align: center; padding: 22px 16px 26px; }
.mtc-footer p { margin: 0 0 10px; }
.mtc-footer p:last-child { margin-bottom: 0; }
.mtc .mtc-footer a { color: #fff; text-decoration: none; padding: 4px 2px; }
.mtc .mtc-footer a:hover { color: var(--mtc-amber-400); text-decoration: underline; }
.mtc .mtc-footer :focus-visible { outline-color: var(--mtc-amber-400); }

/* ---------- tablet ---------- */
@media (min-width: 640px) {
	.mtc-notice { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.mtc-entry { grid-template-columns: 211px minmax(0, 1fr); align-items: start; }
	.mtc-card { padding: 22px 24px; }
}

/* ---------- desktop ---------- */
@media (min-width: 960px) {
	/* logo and menu share one bar */
	.mtc-header { display: flex; align-items: center; padding: 0 max(24px, calc((100% - 1180px) / 2 + 24px)); }
	.mtc-header__inner { margin: 0; padding: 10px 0; flex: 0 0 auto; }
	.mtc-logo { width: 124px; height: 112px; }
	.mtc .mtc-logo img { width: 233px; margin: -20px 0 0 -88px; }
	.mtc-nav-toggle { display: none; }

	.mtc-js .mtc-nav, .mtc-nav { display: block; background: transparent; flex: 1 1 auto; }
	.mtc-nav__list { display: flex; flex-wrap: wrap; justify-content: flex-end; padding: 0; margin: 0; max-width: none; }
	.mtc-nav__item { position: relative; border-top: 0; }
	.mtc-nav__link, .mtc-nav__button { min-height: 52px; padding: 10px 18px; width: auto; font-size: 1rem; }
	.mtc-nav__item--current > .mtc-nav__link,
	.mtc-nav__item--current > .mtc-nav__button { box-shadow: inset 0 -4px 0 var(--mtc-amber-400); }
	.mtc-nav__sub {
		position: absolute;
		top: 100%;
		left: 0;
		min-width: 240px;
		padding: 6px 0;
		background: #fff;
		border-radius: 0 0 8px 8px;
		box-shadow: 0 10px 24px rgba(0, 30, 45, .25);
		z-index: 30;
		display: none;
	}
	/* hover/keyboard fallback, and the JS-controlled state */
	.mtc-nav__item:hover > .mtc-nav__sub,
	.mtc-nav__item:focus-within > .mtc-nav__sub,
	.mtc-js .mtc-nav__sub.mtc-nav__sub--open { display: block; }
	.mtc .mtc-nav__sub a { padding: 9px 18px; color: var(--mtc-teal-700); font-weight: 600; }
	.mtc .mtc-nav__sub a:hover { color: var(--mtc-amber-600); background: var(--mtc-sky-100); }
	.mtc .mtc-nav__sub :focus-visible { outline-color: var(--mtc-teal-600); outline-offset: -3px; }

	.mtc-layout { grid-template-columns: minmax(0, 1fr) 250px; gap: 28px; padding: 24px 24px 40px; }
	.mtc-aside { padding-top: 0; }
	.mtc-maps { flex-direction: column; }
	.mtc-title { font-size: 1.6rem; }
}

@media (prefers-reduced-motion: reduce) {
	.mtc *, .mtc *::before, .mtc *::after { transition: none !important; }
}

@media print {
	.mtc-header, .mtc-nav, .mtc-aside .mtc-maps, .mtc-footer { display: none; }
	body.mtc { background: #fff; }
	.mtc-card { box-shadow: none; border: 0; padding: 0; }
}
