/* ==========================================================================
   Skórka TMG Nieruchomości — koncepcja „Logo jako okno”
   Zasady i źródła: docs/design/zasady-projektu.md
   ========================================================================== */

:root {
	/* kolorystyka z logo TMG: bordo / śliwka / ciemny brązowo-bordowy + biel, jasne neutralne tła, grafit */
	--ink: #2B2B30;          /* grafit — tekst */
	--ink-2: #4A4A51;
	--muted: #6B6B72;
	--paper: #ffffff;
	--mist: #F6F4F3;         /* jasne neutralne tło */
	--line: #E6E1DF;
	--magenta: #7A2A55;      /* bordo — akcent, przyciski, elementy aktywne */
	--berry: #7A2A55;
	--plum: #5A2E49;         /* śliwka — hover, ciemniejszy akcent */
	--plum-deep: #3B1F2E;    /* ciemny brązowo-bordowy — stopka, ciemne tła */
	--rose: #EBC6D8;         /* jasny akcent na ciemnym tle */
	--grad: linear-gradient(135deg, #7A2A55 0%, #5A2E49 100%);
	--f-head: "Montserrat", system-ui, sans-serif;
	--f-body: "Manrope", system-ui, sans-serif;
	--wrap: 1240px;
	--gut: clamp(16px, 4vw, 48px);
	--r: 22px;
	--head-h: 78px;
	/* sygnet z logo jako obraz (punktory, dekoracje) — kolorowy i biały */
	--tmg-mark: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 520 520'%3E%3Cdefs%3E%3ClinearGradient id='g' x1='.12' y1='.12' x2='.88' y2='.88'%3E%3Cstop offset='0' stop-color='%23AB1E9E'/%3E%3Cstop offset='.55' stop-color='%23882B62'/%3E%3Cstop offset='1' stop-color='%235A2E49'/%3E%3C/linearGradient%3E%3Cmask id='m' maskUnits='userSpaceOnUse' x='0' y='-40' width='520' height='580'%3E%3Crect x='0' y='-40' width='520' height='580' fill='white'/%3E%3Cpath d='M231 -40L231 11C221 95 169 139 119 167C49 209 59 329 135 405L155 433L363 433L383 405C459 329 463 221 417 179C381 149 369 121 371 35L373 -40Z'/%3E%3C/mask%3E%3C/defs%3E%3Ccircle cx='259' cy='263' r='251' fill='url(%23g)' mask='url(%23m)'/%3E%3Cpath fill='url(%23g)' d='M258 209L382 317L361 317L361 445L155 445L155 317L134 317Z'/%3E%3C/svg%3E");
	--tmg-mark-w: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 520 520'%3E%3Cdefs%3E%3Cmask id='m' maskUnits='userSpaceOnUse' x='0' y='-40' width='520' height='580'%3E%3Crect x='0' y='-40' width='520' height='580' fill='white'/%3E%3Cpath d='M231 -40L231 11C221 95 169 139 119 167C49 209 59 329 135 405L155 433L363 433L383 405C459 329 463 221 417 179C381 149 369 121 371 35L373 -40Z'/%3E%3C/mask%3E%3C/defs%3E%3Ccircle cx='259' cy='263' r='251' fill='white' mask='url(%23m)'/%3E%3Cpath fill='white' d='M258 209L382 317L361 317L361 445L155 445L155 317L134 317Z'/%3E%3C/svg%3E");
	/* ikony kontaktowe (maski, kolor = currentColor) */
	--ico-tel: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 3h4l2 5-2.5 1.5a11 11 0 0 0 6 6L16 13l5 2v4a2 2 0 0 1-2 2A16 16 0 0 1 3 5a2 2 0 0 1 2-2'/%3E%3C/svg%3E");
	--ico-mail: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='5' width='18' height='14' rx='2'/%3E%3Cpath d='M3 7l9 6 9-6'/%3E%3C/svg%3E");
	--ico-pin: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 21s-7-6.2-7-11.5A7 7 0 0 1 19 9.5C19 14.8 12 21 12 21z'/%3E%3Ccircle cx='12' cy='9.5' r='2.5'/%3E%3C/svg%3E");
	--ico-www: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='M3 12h18M12 3a14 14 0 0 1 0 18M12 3a14 14 0 0 0 0 18'/%3E%3C/svg%3E");
}

/* ---------- baza ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
	margin: 0;
	background: var(--paper);
	color: var(--ink);
	font: 400 clamp(1rem, .95rem + .25vw, 1.125rem)/1.65 var(--f-body);
	overflow-x: hidden;
}
a { color: inherit; }
img { max-width: 100%; height: auto; }
h1, h2, h3, h4 { font-family: var(--f-head); color: var(--ink); }
:focus-visible { outline: 3px solid var(--magenta); outline-offset: 3px; border-radius: 6px; }
::selection { background: var(--rose); color: var(--ink); }
.tmg-wrap { max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gut); }
.tmg-skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--ink); color: #fff; padding: 12px 18px; border-radius: 10px; text-decoration: none; font: 700 .9rem/1 var(--f-head); }
.tmg-skip:focus { top: 12px; }

/* akcent ostatniego słowa tytułów: cienka linia w kolorze logo (bez jaskrawego zakreślacza) */
.tmg-hl { position: relative; white-space: nowrap; z-index: 0; }
.tmg-hl::after {
	content: ""; position: absolute; z-index: -1;
	left: 0; right: 0; bottom: -.06em; height: .08em; min-height: 3px;
	background: var(--berry); border-radius: 2px;
}

/* ---------- nagłówek ---------- */
.tmg-head {
	position: sticky; top: 0; z-index: 50;
	background: rgba(255, 255, 255, .92);
	-webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
	border-bottom: 1px solid var(--line);
	transition: box-shadow .25s;
}
.tmg-head.is-scrolled { box-shadow: 0 10px 30px -20px rgba(42, 20, 33, .45); }
.tmg-head .tmg-wrap { display: flex; align-items: center; gap: 24px; height: var(--head-h); }
.tmg-brand { display: flex; align-items: center; gap: 12px; text-decoration: none; flex: none; }
.tmg-mark { width: 44px; height: 44px; flex: none; }
.tmg-brand b { display: block; font: 800 1.35rem/1 var(--f-head); color: var(--plum); letter-spacing: .02em; }
.tmg-brand small { display: block; margin-top: 3px; font: 700 .8rem/1.2 var(--f-head); letter-spacing: normal; text-transform: uppercase; color: var(--berry); }
.tmg-navtoggle { position: absolute; opacity: 0; pointer-events: none; }
.tmg-burger { display: none; }

.tmg-nav { margin-left: auto; }
.tmg-nav ul { list-style: none; margin: 0; padding: 0; }
.tmg-nav > div > ul { display: flex; gap: 2px; }
.tmg-nav li { position: relative; }
.tmg-nav a {
	display: block; padding: 10px 14px; border-radius: 999px;
	text-decoration: none; font: 600 .95rem/1.2 var(--f-head); color: var(--ink);
	transition: background .2s, color .2s;
}
.tmg-nav a:hover { background-color: var(--mist); }
/* navigation.php dokleja obrazek strony (categories.img = tło nagłówka podstrony) jako inline background linku — w menu bez obrazków */
.tmg-nav a, .tmg-foot-nav a { background-image: none !important; }
.tmg-nav > div > ul > li > a.selected { background: var(--berry); color: #fff; }
.tmg-nav > div > ul > li:has(> ul) > a::after {
	content: ""; display: inline-block; width: .42em; height: .42em; margin-left: .5em;
	border: 2px solid currentColor; border-top: 0; border-left: 0;
	transform: translateY(-.22em) rotate(45deg);
}
/* rozwijane podmenu */
.tmg-nav li ul {
	position: absolute; left: 0; top: calc(100% + 8px); min-width: 300px;
	padding: 10px; background: var(--paper); border: 1px solid var(--line); border-radius: 18px;
	box-shadow: 0 24px 50px -24px rgba(42, 20, 33, .45);
	opacity: 0; visibility: hidden; transform: translateY(6px);
	transition: opacity .2s, transform .2s, visibility .2s;
}
.tmg-nav li ul::before { content: ""; position: absolute; left: 0; right: 0; top: -10px; height: 10px; }
.tmg-nav li:hover > ul, .tmg-nav li:focus-within > ul { opacity: 1; visibility: visible; transform: none; }
.tmg-nav li ul a { border-radius: 12px; font-weight: 600; font-size: .92rem; }
.tmg-nav li ul a.selected { background: var(--mist); color: var(--plum); }
/* podmenu „Oferta” zawsze w pełni rozwinięte (3. poziom widoczny od razu) */
.tmg-nav li ul li, .tmg-nav li ul ul { display: block !important; }
.tmg-nav li ul ul {
	position: static; min-width: 0; padding: 0 0 4px 14px; margin-left: 12px;
	border: 0; border-left: 2px solid var(--line); border-radius: 0; box-shadow: none;
	opacity: 1; visibility: visible; transform: none;
}
.tmg-nav li ul ul::before { display: none; }
.tmg-nav li ul ul a { font-weight: 500; font-size: .88rem; padding: 7px 12px; color: var(--ink-2); }

.tmg-cta {
	display: inline-flex; align-items: center; gap: 10px; flex: none;
	padding: 12px 20px; min-height: 46px; border-radius: 999px;
	background: var(--berry); color: #fff; text-decoration: none;
	font: 700 .95rem/1 var(--f-head); white-space: nowrap;
	transition: transform .2s, box-shadow .2s;
}
.tmg-cta:hover { transform: translateY(-2px); background: var(--plum); box-shadow: 0 10px 24px -10px rgba(59, 31, 46, .7); }
.tmg-cta svg { width: 18px; height: 18px; }

/* ---------- slider CMS jako tło (hero i nagłówki podstron) ---------- */

/* slider CMS (ct_slider2) dopasowany do okna — nadpisuje style inline */
.tmg-photo .rw-gadget, .tmg-photo .ct-panel-aware, .tmg-photo .ct_slider2_overall,
.tmg-photo .slider-box, .tmg-photo ul.slider {
	position: absolute !important; inset: 0 !important;
	width: 100% !important; height: 100% !important; margin: 0 !important; padding: 0 !important;
	visibility: visible !important;
}
.tmg-photo ul.slider { list-style: none; left: 0 !important; }
/* sections.css ogranicza slider na telefonie do 50vh — w tle hero ma wypełniać całość */
.tmg-photo ul.slider, .tmg-photo ul.slider li { max-height: none !important; }
.tmg-photo .anim_ct {
	position: absolute !important; inset: 0 !important; width: 100% !important; height: 100% !important;
	background-size: cover !important; background-position: center !important;
}
.tmg-photo .anim_text, .tmg-photo .slider-nav, .tmg-photo .ct-slider2-prev, .tmg-photo .ct-slider2-next,
.tmg-photo .loader, .tmg-photo .ie_dump, .tmg-photo .content_headers { display: none !important; }

/* ---------- hero strony głównej: klasyczny slider na całą szerokość ---------- */
.tmg-hero { position: relative; overflow: hidden; isolation: isolate; background: var(--plum-deep); color: #fff; }
.tmg-hero-bg { position: absolute; inset: 0; z-index: 0; isolation: isolate; overflow: hidden; }
/* przyciemnienie w tonacji logo — czytelność białego nagłówka (kontrast > 7:1 po lewej) */
.tmg-hero-shade {
	position: absolute; inset: 0; z-index: 1; pointer-events: none;
	background:
		linear-gradient(90deg, rgba(42, 20, 33, .9) 0%, rgba(42, 20, 33, .72) 38%, rgba(42, 20, 33, .18) 75%, rgba(42, 20, 33, 0) 100%),
		linear-gradient(0deg, rgba(42, 20, 33, .55) 0%, rgba(42, 20, 33, 0) 35%);
}
.tmg-hero .tmg-wrap {
	position: relative; z-index: 2; display: flex; align-items: center;
	min-height: min(76vh, 680px); padding-block: 72px 96px;
}
.tmg-hero-txt { width: min(100%, 760px); }
.tmg-hero .tmg-xl { color: #fff; }
.tmg-hero .tmg-lead { color: #F3E8ED; margin-top: 4px; }
.tmg-hero .tmg-btn-dark { background: var(--berry); color: #fff; }
.tmg-hero .tmg-btn-dark:hover { background: #fff; color: var(--plum); }
.tmg-hero .tmg-btn-ghost { border-color: #fff; color: #fff; }
.tmg-hero .tmg-btn-ghost:hover { background: #fff; color: var(--ink); }
.tmg-hero :focus-visible { outline-color: #fff; }
/* kafelek „Panel Mieszkańca” — prawy górny róg sekcji otwierającej, link zewnętrzny (MMSoft) */
.tmg-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.tmg-resident {
	position: absolute; top: 28px; right: var(--gut); z-index: 3;
	display: flex; align-items: center; gap: 14px; padding: 14px 18px 14px 14px;
	background: #fff; color: var(--ink); text-decoration: none; border-radius: 16px;
	box-shadow: 0 18px 44px -18px rgba(20, 8, 15, .6); transition: transform .2s, box-shadow .2s;
}
.tmg-resident:hover { transform: translateY(-2px); box-shadow: 0 24px 50px -18px rgba(20, 8, 15, .75); color: var(--ink); }
/* tło ikony = najjaśniejszy kolor gradientu logo (#AB1E9E); biała ikona — kontrast 6,2:1 */
.tmg-resident .ico { display: grid; place-items: center; width: 46px; height: 46px; flex: none; border-radius: 12px; background: #AB1E9E; color: #fff; }
.tmg-resident .ico svg { width: 26px; height: 26px; }
.tmg-resident .txt { display: flex; flex-direction: column; gap: 3px; }
.tmg-resident strong { font: 800 1.05rem/1.1 var(--f-head); color: var(--plum-deep); }
.tmg-resident small { font-size: .8rem; line-height: 1.2; color: #5E5560; }
.tmg-resident .arr { font: 700 1.1rem/1 var(--f-head); color: var(--berry); margin-left: 4px; transition: transform .2s; }
.tmg-resident:hover .arr { transform: translate(2px, -2px); }
.tmg-resident:hover .ico { background: var(--plum); }
.tmg-hero .tmg-resident:focus-visible { outline: 3px solid #fff; outline-offset: 3px; }
.tmg-eyebrow, .tmg-content .content_headers h3 {
	display: inline-flex; align-items: center; gap: 10px; margin: 0;
	font: 700 .78rem/1.2 var(--f-head); letter-spacing: .2em; text-transform: uppercase; color: var(--berry);
}
.tmg-eyebrow::before, .tmg-content .content_headers h3::before { content: ""; width: 28px; height: 3px; flex: none; background: var(--grad); border-radius: 3px; }
.tmg-xl {
	margin: .35em 0 .3em; color: var(--ink);
	font: 800 clamp(2.1rem, 1.2rem + 3vw, 3.9rem)/1.06 var(--f-head); letter-spacing: -.03em;
	max-width: 22ch; text-wrap: balance; overflow-wrap: normal;
}
.tmg-lead { max-width: 52ch; margin: 0; font-size: clamp(1.05rem, 1rem + .3vw, 1.25rem); color: var(--ink-2); }
.tmg-btns { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 58px; }
.tmg-btn {
	display: inline-flex; align-items: center; gap: 10px; min-height: 52px; padding: 16px 26px;
	border-radius: 999px; text-decoration: none; font: 700 1rem/1 var(--f-head);
	transition: background .2s, color .2s;
}
.tmg-btn-dark { background: var(--berry); color: #fff; }
.tmg-btn-dark:hover { background: var(--plum-deep); }
.tmg-btn-ghost { border: 2px solid var(--ink); color: var(--ink); }
.tmg-btn-ghost:hover { background: var(--ink); color: #fff; }

/* ---------- nagłówek podstrony ---------- */
.tmg-pagehead { position: relative; overflow: hidden; isolation: isolate; background: var(--plum-deep); color: #fff; }
.tmg-pagehead .tmg-wrap { position: relative; z-index: 2; display: flex; align-items: flex-end; min-height: clamp(220px, 28vw, 340px); padding-block: 48px; }
.tmg-pagehead .tmg-title { color: #fff; }
.tmg-pagehead .tmg-hl::after { background: var(--rose); }
.tmg-pagehead-img { background: center / cover no-repeat; }
.tmg-pagehead :focus-visible { outline-color: #fff; }
/* jeden rozmiar tytułu na wszystkich podstronach (bez skalowania JS); dobrany tak,
   by najdłuższe słowa („jednorodzinnych”, „Współpracujemy”) mieściły się od 360 px */
.tmg-title { margin: .45em 0 0; max-width: 900px; font: 800 clamp(1.85rem, 1.2rem + 3vw, 3.6rem)/1.06 var(--f-head); letter-spacing: -.035em; text-wrap: balance; }
.tmg-crumbs ul { display: flex; flex-wrap: wrap; gap: 6px 10px; list-style: none; margin: 0; padding: 0; font: 600 .85rem/1.3 var(--f-head); color: rgba(255, 255, 255, .78); }
.tmg-crumbs li + li::before { content: "/"; margin-right: 10px; color: rgba(255, 255, 255, .5); }
.tmg-crumbs a { text-decoration: none; }
.tmg-crumbs a:hover { text-decoration: underline; color: #fff; }

/* ---------- treść: sekcje CMS ---------- */
.tmg-content { padding-block: clamp(40px, 6vw, 88px); }
.thisishomepage .tmg-content { padding-block: 0; max-width: none; padding-inline: 0; }
.tmg-content .rwContentBox, .tmg-content .ct-section { float: none !important; width: auto !important; }
.tmg-content section.ct-section:not(:has(.tmg-contact-box)) { padding-inline: 0 !important; }
.tmg-content .rw-content-padding, .tmg-content .rw-inner-padding { padding-inline: 0 !important; }
.tmg-content .ie_dump, .tmg-content div[id^="section-"]:empty, .tmg-content div[id^="form-"]:empty { display: none !important; }
.tmg-content .page_content_container > div[style*="clear"] { display: none; }
.tmg-content section.ct-section + section.ct-section { margin-top: clamp(32px, 4vw, 56px); }
.tmg-content .content_headers:has(> header[style*="none"]), .tmg-content .content_headers[style*="none"] { display: none !important; }
.tmg-content .content_headers header { display: flex; flex-direction: column-reverse; align-items: flex-start; gap: 14px; margin-bottom: 20px; }
.tmg-content .content_title { margin: 0; font: 800 clamp(1.5rem, 1.1rem + 1.4vw, 2.2rem)/1.12 var(--f-head); letter-spacing: -.025em; }

/* tekst */
.tinymce-ct { max-width: 70ch; }
.tmg-content .tinymce-ct, .tmg-content .content_headers, .tmg-foot .tinymce-ct { padding-left: 0 !important; padding-right: 0 !important; }
.tinymce-ct p { margin: 0 0 1.1em; }
.tinymce-ct strong { font-weight: 700; }
.tinymce-ct a { color: var(--berry); text-decoration-thickness: 2px; text-underline-offset: 3px; }
.tinymce-ct a:hover { color: var(--plum); text-decoration-color: currentColor; }
.tinymce-ct ul { list-style: none; margin: 0 0 1.2em; padding: 0; }
.tinymce-ct ul li { position: relative; padding: 10px 0 10px 34px; border-top: 1px dashed var(--line); }
.tinymce-ct ul li:first-child { border-top: 0; }
/* punktor = sygnet z logo (pierścień z wycięciem + domek) */
.tinymce-ct ul li::before {
	content: ""; position: absolute; left: 0; top: calc(10px + .3em); width: 20px; height: 20px;
	background: var(--tmg-mark) center / contain no-repeat;
}
.tinymce-ct img { border-radius: 16px; }

/* ikony przed telefonem, e-mailem, adresem i adresem WWW */
.tinymce-ct a[href^="tel:"]::before, .tinymce-ct a[href^="mailto:"]::before,
.tinymce-ct .tmg-ico-addr::before, .tinymce-ct .tmg-ico-www::before {
	content: ""; display: inline-block; width: 1em; height: 1em; margin-right: .45em; vertical-align: -.14em;
	background: currentColor; -webkit-mask: var(--ico-tel) center / contain no-repeat; mask: var(--ico-tel) center / contain no-repeat;
}
.tinymce-ct a[href^="mailto:"]::before { -webkit-mask-image: var(--ico-mail); mask-image: var(--ico-mail); }
.tinymce-ct .tmg-ico-addr::before { -webkit-mask-image: var(--ico-pin); mask-image: var(--ico-pin); }
.tinymce-ct .tmg-ico-www::before { -webkit-mask-image: var(--ico-www); mask-image: var(--ico-www); }
.tinymce-ct .tmg-ico-addr, .tinymce-ct .tmg-ico-www { display: inline-block; padding-left: 1.45em; text-indent: -1.45em; }
/* w treści (jasne tło): ikony fioletowe, linki kontaktowe bez podkreślenia */
.tmg-content .tinymce-ct a[href^="tel:"]::before, .tmg-content .tinymce-ct a[href^="mailto:"]::before,
.tmg-content .tinymce-ct .tmg-ico-addr::before, .tmg-content .tinymce-ct .tmg-ico-www::before { background: var(--magenta); }
.tmg-content .tinymce-ct a[href^="tel:"], .tmg-content .tinymce-ct a[href^="mailto:"], .tmg-content .tinymce-ct a.tmg-ico-www { text-decoration: none; }
.tinymce-ct .tmg-nip { font-size: .8em; }
.tinymce-ct a[href^="tel:"] { white-space: nowrap; }

/* nagłówki i listy numerowane w treści (np. regulamin) */
.tinymce-ct h2 { margin: 1.8em 0 .6em; font: 800 clamp(1.2rem, 1rem + .6vw, 1.45rem)/1.25 var(--f-head); letter-spacing: -.015em; }
.tinymce-ct h3 { margin: 1.4em 0 .5em; font: 700 1.1rem/1.3 var(--f-head); }
.tinymce-ct > h2:first-child, .tinymce-ct > h3:first-child { margin-top: 0; }
.tinymce-ct ol { margin: 0 0 1.2em; padding-left: 1.6em; }
.tinymce-ct ol li { padding: 4px 0 4px .3em; }
.tinymce-ct ol li::marker { color: var(--berry); font-weight: 700; }
.tmg-legal-text .tinymce-ct { max-width: 78ch; }

/* strona główna — „O firmie” */
.tmg-content section:has(.tmg-intro) { background: var(--mist); padding-block: clamp(56px, 8vw, 112px); }
.tmg-content section:has(.tmg-intro) .rw-content-proper > div,
.tmg-content section:has(.tmg-tiles) .rw-content-proper > div {
	max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gut);
}
/* nagłówek po lewej, treść po prawej (nagłówek nie przykleja się przy przewijaniu) */
.tmg-intro { display: grid; grid-template-columns: minmax(260px, 5fr) minmax(0, 7fr); gap: clamp(24px, 5vw, 80px); align-items: start; }
.tmg-intro:not(:has(.content_headers header:not([style*="none"]))) { display: block; }
.tmg-intro .content_title { font-size: clamp(1.6rem, 1rem + 1.7vw, 2.4rem); line-height: 1.08; letter-spacing: -.03em; overflow-wrap: break-word; hyphens: manual; }
.tmg-intro .tinymce-ct { max-width: 920px; }
/* oryginalne logo (to samo co favicona, tmg/logo.jpg) nad tytułem sekcji —
   wersja z przezroczystym tłem tmg/logo-transparent.png (360 px) */
.tmg-intro .content_headers::before {
	content: ""; display: block; width: clamp(110px, 12vw, 160px); aspect-ratio: 777 / 820; margin-bottom: 24px;
	/* ścieżka względna do style.css — działa także w podkatalogu (np. xdp.pl/tmgnieruchomosci/) */
	background: url("../../../data/images/tmg/logo-transparent.png") center / contain no-repeat;
}
.tmg-intro .tinymce-ct p:first-child { font-size: 1.2em; line-height: 1.55; }
/* ilustracja pod tekstem sekcji (2× wcześniejszy rozmiar; bez opływania tekstem) */
.tmg-float { display: block; float: none; width: clamp(360px, 64%, 600px); margin: 0; border-radius: 16px !important; object-fit: cover; aspect-ratio: 3 / 2; }
.tinymce-ct p:has(> .tmg-float) { margin: 32px 0 0; }
.tinymce-ct p.tmg-oc {
	clear: both; position: relative; margin-top: 28px !important; padding: 18px 22px 18px 86px;
	border-radius: var(--r); background: var(--paper); border: 1px solid var(--line); font-weight: 500;
}
.tinymce-ct p.tmg-oc::before {
	content: ""; position: absolute; left: 22px; top: 50%; width: 48px; height: 48px; margin-top: -24px; border-radius: 50%;
	background: var(--berry) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='2.6'%3E%3Cpath d='M12 3l8 3v6c0 5-3.5 8-8 9-4.5-1-8-4-8-9V6z'/%3E%3Cpath d='M8.5 12.5l2.5 2.5 4.5-5'/%3E%3C/svg%3E") center / 24px no-repeat;
}

/* strona główna — kafle oferty (bento) */
.tmg-content section:has(.tmg-tiles) { padding-block: clamp(56px, 8vw, 112px); margin-top: 0 !important; }
.tmg-tiles .tinymce-ct { max-width: none; }
.tmg-bento { display: grid; grid-template-columns: repeat(2, 1fr); grid-template-rows: auto auto; gap: 16px; margin-top: 12px; }
.tmg-bento .tile {
	position: relative; overflow: hidden; display: flex; flex-direction: column; justify-content: flex-end; gap: 8px;
	min-height: 230px; padding: 28px; border-radius: var(--r); border: 1px solid var(--line);
	background: var(--paper); color: var(--ink); text-decoration: none; isolation: isolate;
	transition: transform .25s, border-color .25s;
}
/* miejsce na duży numer nad tytułem (dłuższe opisy kafli) */
.tmg-bento .tile { padding-top: 104px; }
.tmg-bento .tile:hover { transform: translateY(-4px); border-color: var(--plum); color: var(--ink); }
.tmg-bento .tile strong { font: 800 1.45rem/1.12 var(--f-head); letter-spacing: -.02em; }
.tmg-bento .tile .txt { color: var(--ink-2); font-size: .95rem; }
.tmg-bento .tile .num { position: absolute; top: 18px; left: 26px; font: 800 4.5rem/1 var(--f-head); color: transparent; -webkit-text-stroke: 1.5px var(--line); }
.tmg-bento .tile::after {
	content: "→"; position: absolute; top: 22px; right: 22px; width: 44px; height: 44px; border-radius: 50%;
	display: grid; place-items: center; background: var(--mist); font: 700 1.1rem/1 var(--f-head); transition: background .25s;
}
.tmg-bento .tile:hover::after { background: var(--berry); color: #fff; }
.tmg-bento .t-a { grid-row: span 2; min-height: 476px; border: 0; background: var(--grad); color: #fff; }
.tmg-bento .t-a:hover { color: #fff; }
.tmg-bento .t-a .txt { color: #F3E4EB; }
.tmg-bento .t-a .num { -webkit-text-stroke-color: rgba(255, 255, 255, .35); }
.tmg-bento .t-a::after { background: rgba(255, 255, 255, .14); }
.tmg-bento .t-a::before {
	content: ""; position: absolute; z-index: -1; right: -22%; top: -18%; width: 80%; aspect-ratio: 1; opacity: .12;
	background: var(--tmg-mark-w) center / contain no-repeat;
}

/* tekst wprowadzający (np. oferta dla wspólnot) — większy stopień */
.tmg-lead-text .tinymce-ct p { font-size: 1.15em; line-height: 1.6; }

/* oferta dla wspólnot — 4 karty obszarów z linkami do podstron (wykazy czynności) */
.tmg-areas .tinymce-ct { max-width: none; }
.tmg-areas-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.tmg-areas-grid .area {
	position: relative; display: flex; flex-direction: column; gap: 10px; min-height: 180px; padding: 26px 28px;
	border: 1px solid var(--line); border-radius: var(--r); background: var(--paper); color: var(--ink); text-decoration: none;
	transition: border-color .2s, transform .2s, box-shadow .2s;
}
.tmg-areas-grid .area:hover { border-color: var(--berry); transform: translateY(-3px); box-shadow: 0 18px 40px -26px rgba(59, 31, 46, .5); color: var(--ink); }
.tmg-areas-grid .num { font: 800 2.2rem/1 var(--f-head); color: var(--berry); }
.tmg-areas-grid strong { font: 800 1.3rem/1.2 var(--f-head); letter-spacing: -.015em; }
.tmg-areas-grid .more { margin-top: auto; font: 700 .92rem/1 var(--f-head); color: var(--berry); }
.tmg-areas-grid .more::after { content: " →"; }
.tmg-areas-grid .area:hover .more { color: var(--plum); }

/* podstrony obszarów wspólnot: wprowadzenie + zwarty wykaz czynności (długie listy) */
.tmg-scope .tinymce-ct { max-width: 80ch; }
.tmg-scope .tinymce-ct p.tmg-scope-intro { font-size: 1.1em; line-height: 1.6; }
.tmg-scope .tinymce-ct p.tmg-scope-label { margin: 1.6em 0 .5em; font: 800 1.15rem/1.2 var(--f-head); color: var(--plum-deep); }
.tmg-scope .tinymce-ct ul li { padding: 4px 0 4px 28px; border-top: 0; font-size: .95rem; line-height: 1.5; }
.tmg-scope .tinymce-ct ul li::before { top: calc(4px + .3em); width: 16px; height: 16px; }

/* kontakt — wprowadzenie na całą szerokość, dane obok formularza (desktop), mapa na całą szerokość */
.tmg-addr-label { margin: 16px 0 2px !important; font: 700 .72rem/1.2 var(--f-head); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.tmg-contact-box .tmg-addr-label:first-of-type { margin-top: 4px !important; }
@media (min-width: 861px) {
	.tmg-content .page_content_container:has(.tmg-contact-box) {
		display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); column-gap: clamp(32px, 5vw, 80px); align-items: start;
	}
	.tmg-content .page_content_container:has(.tmg-contact-box) > section:has(.tmg-contact-intro) { grid-column: 1 / -1; margin-bottom: 8px; }
	.tmg-content .page_content_container:has(.tmg-contact-box) > section:has(.tmg-contact-box) {
		padding: 28px !important; border-radius: var(--r); background: var(--mist); margin-top: 0 !important;
	}
	.tmg-content .page_content_container:has(.tmg-contact-box) > section.rw_ct_form { margin-top: 0 !important; }
	.tmg-content .page_content_container:has(.tmg-contact-box) > section.rw_ct_google_map { grid-column: 1 / -1; }
}
@media (max-width: 860px) {
	.tmg-content section:has(.tmg-contact-box) { padding: 22px !important; border-radius: var(--r); background: var(--mist); }
}

/* kontakt — formularz */
.tmg-content .form-auto input, .tmg-content .form-auto textarea { margin: 0; }
.tmg-content .form-auto { max-width: 720px; }
.tmg-content .form-auto > table, .tmg-content .form-auto > table > tbody, .tmg-content .form-auto > table > tbody > tr,
.tmg-content .form-auto > table > tbody > tr > td { display: block; width: 100%; }
.tmg-content .form-auto > table > tbody > tr { margin-bottom: 16px; }
.tmg-content .form-auto > table > tbody > tr > td:first-child { margin-bottom: 6px; padding: 0; text-align: left; font: 700 .9rem/1.3 var(--f-head); }
.tmg-content .form-auto td { padding: 0; text-align: left; }
.tmg-content .form-auto .required-asterix { display: none; }
.tmg-content .form-auto .uploadifive-button {
	width: auto !important; height: auto !important; min-height: 48px; padding: 0 22px; line-height: 44px !important;
	border: 2px dashed #cdb9c6; border-radius: 14px; background: var(--mist);
	font: 700 .92rem/44px var(--f-head); color: var(--plum); cursor: pointer; transition: border-color .2s, background .2s;
}
.tmg-content .form-auto .uploadifive-button:hover { border-color: var(--magenta); background: #fff; }
.tmg-content .form-auto .uploadifive-button input[type=file] { cursor: pointer; height: 100%; }
.tmg-content .rw-file-name { font-weight: 600; }
.tmg-content .form-auto tr.form-field-required > td:first-child::after { content: " *"; color: var(--magenta); }
.tmg-content .form-auto input[type=text], .tmg-content .form-auto input:not([type]), .tmg-content .form-auto input[type=email],
.tmg-content .form-auto textarea {
	width: 100% !important; max-width: none; min-height: 52px; padding: 14px 16px;
	border: 2px solid var(--line); border-radius: 14px; background: var(--paper);
	font: 500 1rem/1.4 var(--f-body); color: var(--ink); transition: border-color .2s;
}
.tmg-content .form-auto textarea { min-height: 160px; resize: vertical; }
.tmg-content .form-auto input:hover, .tmg-content .form-auto textarea:hover { border-color: #cdb9c6; }
.tmg-content .form-auto input:focus, .tmg-content .form-auto textarea:focus { outline: none; border-color: var(--magenta); box-shadow: 0 0 0 4px rgba(122, 42, 85, .16); }
.tmg-content .form-auto input[type=submit] {
	min-height: 52px; padding: 16px 34px; border: 0; border-radius: 999px; cursor: pointer;
	background: var(--berry); color: #fff; font: 700 1rem/1 var(--f-head); transition: background .2s;
}
.tmg-content .form-auto input[type=submit]:hover { background: var(--plum-deep); }
.tmg-content .form-auto > table > tbody > tr > td:first-child:empty { display: none; }
.tmg-content .rw-file-upload { width: 100%; }
.tmg-content .rw-file-upload td { padding: 0; }
.tmg-content .content_google { border-radius: var(--r); overflow: hidden; border: 1px solid var(--line); }
.tmg-content .content_google iframe { display: block; width: 100%; height: clamp(300px, 40vw, 440px); }
.tmg-content .content_google_description { margin-top: 12px !important; color: var(--muted); font-weight: 600; }

/* ---------- stopka ---------- */
.tmg-foot { position: relative; overflow: hidden; background: linear-gradient(160deg, #4A2638 0%, #3B1F2E 45%, #2A1620 100%); color: #F3E8ED; }
.tmg-bigring { position: absolute; right: -14vw; top: -10vw; width: 58vw; max-width: 820px; opacity: .09; pointer-events: none; }
/* siatka stopki: [logo | tytuł | Na skróty] / [telefony | . | dane adresowe] / [prawa]
   kontenery gadżetu 1159 są „spłaszczone” (display: contents), żeby jego akapity
   trafiły bezpośrednio do siatki */
.tmg-foot .tmg-wrap {
	--fgap: clamp(24px, 4vw, 64px);
	/* logo w stopce: szerokość obrazka; karta = obrazek (proporcja 820/777) + 2 × 14 px */
	--flogo: clamp(84px, 8vw, 110px);
	--flogo-h: calc(var(--flogo) * 1.0553 + 28px);
	position: relative; display: grid; column-gap: var(--fgap); row-gap: 0;
	grid-template-columns: auto minmax(0, 1fr) auto;
	grid-template-areas:
		"logo  title nav"
		"tel1  tel1  addr"
		"tel2  tel2  addr"
		"legal legal legal";
	padding-block: 80px 36px;
}
.tmg-foot a { color: #fff; }
.tmg-foot :focus-visible { outline-color: #fff; }
.tmg-foot-contact, .tmg-foot-contact .rw-gadget, .tmg-foot-contact .ct-panel-aware, .tmg-foot-contact .tinymce-ct { display: contents; }
.tmg-foot-contact .ie_dump { display: none !important; }
.tmg-foot-logo {
	grid-area: logo; align-self: start; justify-self: start;
	display: inline-block; padding: 14px; border-radius: 20px; background: #fff; line-height: 0;
	box-shadow: 0 18px 40px -20px rgba(0, 0, 0, .6); transition: transform .2s;
}
.tmg-foot-logo:hover { transform: translateY(-2px); }
.tmg-foot-logo img { display: block; width: var(--flogo); height: auto; }
.tmg-foot-contact .tinymce-ct h2 {
	grid-area: title; align-self: start; color: #fff; max-width: 11.5em;
	/* 3 linie przy line-height 1 (Montserrat 800, zmierzone w przeglądarce): od góry najwyższej litery
	   ("d") do linii bazowej ostatniej linii jest 2,824 em, a góra litery leży 0,0555 em pod górą pola
	   -> rozmiar = wysokość karty / 2,824, margines górny = -0,0555 em: tekst lico z górą i dołem karty */
	font: 800 calc(var(--flogo-h) / 2.824)/1 var(--f-head); letter-spacing: -.03em;
	margin: calc(var(--flogo-h) / 2.824 * -0.0555) 0 0 calc(22px - var(--fgap));
}
.tmg-foot-contact .tinymce-ct p { margin: 0; }
.tmg-foot-contact .tinymce-ct a { color: #fff; text-decoration: none; }
.tmg-foot-contact .tinymce-ct a:hover { text-decoration: underline; text-underline-offset: 5px; text-decoration-color: var(--rose); }
/* oba telefony tej samej wielkości: pierwszy zielony, drugi biały — na dole po lewej */
.tmg-foot-contact .tmg-tel { grid-area: tel1; align-self: end; margin-top: 48px !important; }
.tmg-foot-contact .tmg-tel2 { grid-area: tel2; align-self: start; }
.tmg-foot-contact .tmg-tel a, .tmg-foot-contact .tmg-tel2 a { font: 800 clamp(1.7rem, 1.1rem + 1.7vw, 2.5rem)/1.15 var(--f-head); letter-spacing: -.01em; }
.tmg-foot-contact .tmg-tel a { color: var(--rose); }
.tmg-foot-contact .tmg-tel2 a { color: #fff; font: 700 clamp(1.05rem, .9rem + .5vw, 1.3rem)/1.4 var(--f-body); letter-spacing: 0; }
.tmg-foot .tmg-addr-label { display: inline-block; margin: 0 !important; color: var(--rose); font-size: .7rem; }
/* dane adresowe pod „Na skróty”, z odstępem */
.tmg-foot-contact .tmg-addr { grid-area: addr; align-self: end; margin-top: 36px !important; line-height: 1.7; color: #e6d6e1; }
.tmg-foot-nav { grid-area: nav; }
.tmg-foot-nav h3 { margin: 8px 0 16px; color: var(--rose); font: 700 .78rem/1 var(--f-head); letter-spacing: .2em; text-transform: uppercase; }
.tmg-foot-nav ul { list-style: none; margin: 0; padding: 0; }
.tmg-foot-nav ul ul { display: none; }
.tmg-foot-nav a { display: inline-block; padding: 5px 0; text-decoration: none; }
.tmg-foot-nav a:hover { text-decoration: underline; text-underline-offset: 5px; text-decoration-color: var(--rose); }
.tmg-legal { grid-area: legal; margin-top: 56px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; padding-top: 22px; border-top: 1px solid rgba(255, 255, 255, .14); font-size: .595rem; color: #cdb9c6; }
.tmg-legal a { color: inherit; text-decoration: none; }

/* ---------- baner cookies (rwcookie) — kolory skórki ---------- */
.rwcc-box {
	background: var(--paper) !important; color: var(--ink) !important; font-family: var(--f-body) !important; font-size: .9rem !important;
	border: 1px solid var(--line); border-radius: var(--r) !important; box-shadow: 0 30px 60px -30px rgba(42, 20, 33, .55) !important;
	max-width: calc(100vw - 40px);
}
.rwcc-box p { line-height: 1.55; }
.rwcc-box a { color: var(--berry); }
.rwcc-box .rwcc-btn {
	min-height: 46px; padding: 12px 20px; border: 2px solid var(--ink) !important; border-radius: 999px !important;
	background: var(--paper) !important; color: var(--ink) !important; font: 700 .9rem/1.2 var(--f-head) !important;
	transition: background .2s, color .2s;
}
.rwcc-box .rwcc-btn:hover { background: var(--ink) !important; color: #fff !important; }
.rwcc-box #rwcc-accept-all-btn { background: var(--berry) !important; border-color: var(--berry) !important; color: #fff !important; }
.rwcc-box #rwcc-accept-all-btn:hover { background: var(--plum) !important; border-color: var(--plum) !important; color: #fff !important; }

/* ---------- responsywność ---------- */
@media (max-width: 1080px) {
	.tmg-burger {
		display: grid; place-items: center; order: 3; width: 48px; height: 48px; margin-left: 4px;
		border: 2px solid var(--ink); border-radius: 50%; cursor: pointer; flex: none;
	}
	.tmg-burger span, .tmg-burger span::before, .tmg-burger span::after { display: block; width: 20px; height: 2.5px; background: var(--ink); border-radius: 2px; transition: transform .25s, opacity .25s; }
	.tmg-burger span { position: relative; }
	.tmg-burger span::before, .tmg-burger span::after { content: ""; position: absolute; left: 0; }
	.tmg-burger span::before { top: -6px; }
	.tmg-burger span::after { top: 6px; width: 13px; }
	.tmg-navtoggle:checked + .tmg-burger span { background: transparent; }
	.tmg-navtoggle:checked + .tmg-burger span::before { transform: translateY(6px) rotate(45deg); }
	.tmg-navtoggle:checked + .tmg-burger span::after { width: 20px; transform: translateY(-6px) rotate(-45deg); }
	.tmg-navtoggle:focus-visible + .tmg-burger { outline: 3px solid var(--magenta); outline-offset: 3px; }
	/* backdrop-filter tworzy blok zawierający dla position:fixed — menu mobilne musi liczyć się od ekranu */
	.tmg-head { -webkit-backdrop-filter: none; backdrop-filter: none; background: var(--paper); }
	.tmg-cta { margin-left: auto; order: 2; }
	.tmg-nav {
		position: fixed; inset: var(--head-h) 0 0 0; margin: 0; overflow-y: auto;
		background: var(--plum-deep); padding: 24px var(--gut) 48px;
		opacity: 0; visibility: hidden; transform: translateY(-8px); transition: opacity .25s, transform .25s, visibility .25s;
	}
	.tmg-navtoggle:checked ~ .tmg-nav { opacity: 1; visibility: visible; transform: none; }
	.tmg-nav > div > ul { flex-direction: column; gap: 0; }
	.tmg-nav a { color: #fff; border-radius: 12px; font-size: 1.25rem; padding: 14px 12px; }
	.tmg-nav a:hover { background: rgba(255, 255, 255, .08); }
	.tmg-nav > div > ul > li > a.selected { background: #fff; color: var(--plum); }
	.tmg-nav > div > ul > li:has(> ul) > a::after { display: none; }
	.tmg-nav li ul, .tmg-nav li ul ul {
		position: static; min-width: 0; opacity: 1; visibility: visible; transform: none;
		background: none; border: 0; border-left: 2px solid rgba(255, 255, 255, .15); border-radius: 0; box-shadow: none;
		margin: 0 0 8px 14px; padding: 0 0 0 10px;
	}
	.tmg-nav li ul a, .tmg-nav li ul ul a { font-size: 1rem; color: #e6d6e1; padding: 9px 12px; }
	.tmg-nav li ul a.selected { background: rgba(255, 255, 255, .1); color: #fff; }
}
/* węższe ekrany: kafelek „Panel Mieszkańca” nad nagłówkiem, żeby nie nachodził na tekst */
@media (max-width: 1100px) {
	.tmg-hero .tmg-wrap { flex-direction: column; align-items: stretch; justify-content: center; }
	.tmg-resident { position: static; align-self: flex-start; margin-bottom: 28px; }
}
@media (max-width: 860px) {
	.tmg-hero .tmg-wrap { min-height: 520px; padding-block: 48px 80px; }
	.tmg-hero-shade { background: linear-gradient(0deg, rgba(42, 20, 33, .9) 0%, rgba(42, 20, 33, .7) 55%, rgba(42, 20, 33, .45) 100%); }
	.tmg-pagehead .tmg-wrap { min-height: 200px; padding-block: 32px; }
	.tmg-intro { grid-template-columns: 1fr; }
	.tmg-intro .content_headers { position: static; }
	.tmg-float { float: none; width: 100%; margin: 0; }
	.tinymce-ct p.tmg-oc { padding: 76px 20px 20px; }
	.tinymce-ct p.tmg-oc::before { top: 20px; margin-top: 0; }
	.tmg-bento { grid-template-columns: 1fr; }
	.tmg-bento .t-a { grid-row: auto; min-height: 260px; }
	.tmg-bento .tile { min-height: 0; padding-top: 100px; }
	.tmg-bento .tile .num { font-size: 3.6rem; }
	.tmg-areas-grid { grid-template-columns: 1fr; }
	.tmg-resident { padding: 10px 14px 10px 10px; gap: 12px; }
	.tmg-resident .ico { width: 38px; height: 38px; }
	.tmg-resident .ico svg { width: 22px; height: 22px; }
	.tmg-foot .tmg-wrap {
		grid-template-columns: auto minmax(0, 1fr);
		grid-template-areas: "logo title" "tel1 tel1" "tel2 tel2" "nav nav" "addr addr" "legal legal";
		row-gap: 0; padding-block: 64px 32px;
	}
	/* telefon: nagłówek sekcji otwierającej — „nieruchomościami” mieści się od 360 px */
	.tmg-hero .tmg-xl { font-size: clamp(1.7rem, 1rem + 4vw, 2.4rem); }
	/* telefon: jeden rozmiar tytułu podstron, najdłuższe słowo mieści się od 360 px */
	.tmg-pagehead .tmg-title { font-size: clamp(1.75rem, 1rem + 4vw, 2.4rem); }
	.tmg-foot .tmg-wrap { --flogo: 84px; }
	/* telefon: tytuł wysoki jak karta z logo nie zmieści się w szerokości ekranu — wyśrodkowany obok logo */
	.tmg-foot-contact .tinymce-ct h2 { align-self: center; max-width: none; margin: 0 0 0 calc(14px - var(--fgap)); font-size: clamp(1.15rem, .8rem + 1.6vw, 1.6rem); line-height: 1.08; }
	.tmg-foot-contact .tmg-tel { margin-top: 32px !important; }
	.tmg-foot-nav { margin-top: 32px; }
	.tmg-foot-contact .tmg-addr { margin-top: 24px !important; margin-bottom: 32px !important; }
}
@media (max-width: 420px) {
	.tmg-cta span { display: none; }
	.tmg-head .tmg-wrap { gap: 10px; }
	.tmg-brand { gap: 8px; }
	.tmg-cta { padding: 12px 14px; }
}
@media (prefers-reduced-motion: reduce) {
	*, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}