/*
 * Generation 22 — внутрішні сторінки, "Henna" (та сама система, що й
 * головна: assets/css/home-henna.css, токени --g22h-*). Підключається
 * поверх home-henna.css і на неї спирається (functions.php: dep 'g22-home').
 *
 * Марк-ап не змінюється — тільки стилі базових класів .g22-page-*,
 * .g22-cards/.g22-card, .g22-checklist, .g22-form, .g22-price-card,
 * .g22-google-reviews (шаблони page.php + inc/forms.php + patterns/*.php).
 *
 * Токени --g22h-* оголошені на :root у home-henna.css — доступні тут без
 * фолбеків.
 */

/* -------------------------------------------------- */
/* Page canvas                                         */
/* -------------------------------------------------- */

/* body background тепер задається сайт-вайд у home-henna.css (dep цього
   файлу) — тут лишається лише шрифт, специфічний для внутрішніх сторінок. */
body {
	font-family: var(--g22h-font);
}

.g22-page-shell {
	padding-bottom: clamp(64px, 8vw, 104px);
}

/* -------------------------------------------------- */
/* Header — sticky must always win over page content   */
/* (bug B: h2 rendering over the header while           */
/* scrolling). Matches the homepage stacking pattern.   */
/* -------------------------------------------------- */

/* Taste nav owns chrome; only keep stacking above page content. */
.g22-header.g22-header--taste {
	position: sticky;
	top: 14px;
	z-index: 300;
}

/* -------------------------------------------------- */
/* Intro poster (kicker + H1 + summary)                 */
/* -------------------------------------------------- */

/* -------------------------------------------------- */
/* Intro — also left-aligned editorial (same track)     */
/* -------------------------------------------------- */

.g22-page-intro {
	min-height: 0;
	display: block;
	background: none;
	text-align: left;
	padding: var(--g22-below-nav, clamp(72px, 9vw, 96px)) 24px 0;
}

.g22-page-intro__inner {
	display: block;
	max-width: 780px;
	margin-inline: 0;
}

.g22-page-intro .g22-page-kicker {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	margin: 0;
	font-family: "IBM Plex Mono", ui-monospace, monospace;
	font-size: var(--g22-hero-kicker-size, 0.72rem);
	font-weight: 500;
	letter-spacing: var(--g22-hero-kicker-tracking, 0.16em);
	text-transform: uppercase;
	color: var(--g22h-ink-55, rgba(26, 26, 26, 0.55));
}

.g22-page-intro .g22-page-kicker::before {
	content: "";
	display: inline-block;
	width: var(--g22-hero-kicker-dash-w, 18px);
	height: var(--g22-hero-kicker-dash-h, 3px);
	flex: 0 0 var(--g22-hero-kicker-dash-w, 18px);
	border-radius: 1px;
	background: var(--g22h-yellow, #fcc708);
}

.g22-page-intro .g22-page-title {
	max-width: var(--g22-hero-title-max, 18ch);
	margin: 16px 0 0;
	font-family: "Manrope", var(--g22h-font);
	font-weight: 700;
	font-size: var(--g22-hero-title, clamp(2.75rem, 5.4vw, 3.75rem));
	line-height: var(--g22-hero-title-lh, 1.04);
	letter-spacing: var(--g22-hero-title-ls, -0.035em);
	text-align: left;
	color: var(--g22h-ink);
}

.g22-page-intro .g22-page-summary {
	max-width: var(--g22-hero-summary-max, 54ch);
	margin: 20px 0 0;
	text-align: left;
	font-size: var(--g22-hero-summary-size, clamp(1rem, 1.4vw, 1.2rem));
	line-height: var(--g22-hero-summary-lh, 1.65);
	color: var(--g22h-ink-70);
	font-weight: 400;
}

/* -------------------------------------------------- */
/* Content-embedded hero (no .g22-page-intro)           */
/* One editorial track for every inner page hero.       */
/* Tokens: --g22-hero-* in tokens.css                   */
/* -------------------------------------------------- */

.g22-page-shell:not(:has(.g22-page-intro)) .g22-page-content {
	padding-top: var(--g22-below-nav, clamp(72px, 9vw, 96px));
}

.g22-page-content > .g22-page-section:first-of-type {
	text-align: left;
	padding-block: 0 clamp(24px, 3vw, 40px);
}

.g22-page-content > .g22-page-section:first-of-type .g22-page-kicker,
.g22-about-hero__kicker,
.g22-studio__eyebrow {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	margin: 0;
	font-family: "IBM Plex Mono", ui-monospace, monospace;
	font-size: var(--g22-hero-kicker-size, 0.72rem);
	font-weight: 500;
	letter-spacing: var(--g22-hero-kicker-tracking, 0.16em);
	text-transform: uppercase;
	color: var(--g22h-ink-55, var(--g22-ink-mute, rgba(26, 26, 26, 0.55)));
}

.g22-page-content > .g22-page-section:first-of-type .g22-page-kicker::before,
.g22-about-hero__kicker::before,
.g22-studio__eyebrow::before {
	content: "";
	display: inline-block;
	width: var(--g22-hero-kicker-dash-w, 18px);
	height: var(--g22-hero-kicker-dash-h, 3px);
	flex: 0 0 var(--g22-hero-kicker-dash-w, 18px);
	margin-right: 0;
	border-radius: 1px;
	background: var(--g22h-yellow, var(--g22-yellow, #fcc708));
}

.g22-page-content > .g22-page-section:first-of-type .g22-page-title,
.g22-about-hero__title,
.g22-studio__title {
	max-width: var(--g22-hero-title-max, 18ch);
	margin: 16px 0 0;
	font-family: "Manrope", var(--g22h-font, var(--g22-font-display));
	font-weight: 700;
	font-size: var(--g22-hero-title, clamp(2.75rem, 5.4vw, 3.75rem));
	line-height: var(--g22-hero-title-lh, 1.04);
	letter-spacing: var(--g22-hero-title-ls, -0.035em);
	text-align: left;
	text-wrap: balance;
	color: var(--g22h-ink, var(--g22-ink, #1a1a1a));
}

.g22-page-content > .g22-page-section:first-of-type .g22-page-summary,
.g22-about-hero__summary,
.g22-studio__lede {
	max-width: var(--g22-hero-summary-max, 54ch);
	margin: 20px 0 0;
	font-size: var(--g22-hero-summary-size, clamp(1rem, 1.4vw, 1.2rem));
	line-height: var(--g22-hero-summary-lh, 1.6);
	text-align: left;
	text-wrap: pretty;
	color: var(--g22h-ink-70, var(--g22-ink-mute, rgba(26, 26, 26, 0.7)));
}

@media (max-width: 781px) {
	.g22-page-content > .g22-page-section:first-of-type .g22-page-title,
	.g22-about-hero__title,
	.g22-studio__title {
		max-width: none;
		font-size: clamp(2.4rem, 10vw, 3.25rem);
	}
}

/* -------------------------------------------------- */
/* Shared page-hero photo card (one type sitewide)      */
/* -------------------------------------------------- */

.g22-eksternat-hero__figure,
.g22-study-hero__figure,
.g22-about-hero__image--main,
.g22-kontakty__hero-figure {
	margin: 0;
	border-radius: var(--g22-hero-media-radius, 20px);
	overflow: hidden;
	aspect-ratio: var(--g22-hero-media-ratio, 4 / 3);
	box-shadow: var(--g22-hero-media-shadow, 0 18px 44px rgba(26, 26, 26, 0.12), 0 4px 12px rgba(63, 39, 128, 0.06), inset 0 0 0 1px rgba(26, 26, 26, 0.05));
	background: transparent;
}

.g22-eksternat-hero__figure img,
.g22-study-hero__figure img,
.g22-about-hero__image--main img,
.g22-kontakty__hero-photo {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

@media (max-width: 860px) {
	.g22-eksternat-hero__figure,
	.g22-study-hero__figure,
	.g22-about-hero__image--main,
	.g22-kontakty__hero-figure {
		aspect-ratio: var(--g22-hero-media-ratio-narrow, 16 / 10);
	}
}

/* -------------------------------------------------- */
/* Content column                                       */
/* -------------------------------------------------- */

.g22-page-content {
	width: auto;
	max-width: 1200px;
	margin-inline: auto;
	/* Top pad is for section rhythm after .g22-page-intro (intro owns --g22-below-nav). */
	padding: clamp(40px, 5vw, 64px) 24px 0;
}

.g22-page-content > p,
.g22-page-content > ul,
.g22-page-content > ol,
.g22-page-content > blockquote {
	max-width: 68ch;
}

.g22-page-content h2 {
	margin-top: clamp(48px, 6vw, 72px);
	font-family: var(--g22h-font);
	font-weight: 800;
	font-size: clamp(1.6rem, 2.6vw, 2.1rem);
	line-height: 1.15;
	letter-spacing: -0.02em;
	color: var(--g22h-ink);
}

.g22-page-content > h2:first-child {
	margin-top: 0;
}

.g22-page-content p {
	color: var(--g22h-ink-70);
	line-height: 1.65;
}

.g22-page-content ul:not(.g22-cards__grid):not(.g22-checklist):not(.g22-hero-stats):not(.g22-kontakty__hero-stats):not(.g22-study-hero__stats):not(.g22-eksternat-hero__stats):not(.g22-discounts__list),
.g22-checklist {
	list-style: none;
	margin: 1rem 0 0;
	padding: 0;
	display: grid;
	gap: 10px;
}

.g22-page-content ul:not(.g22-cards__grid):not(.g22-checklist):not(.g22-hero-stats):not(.g22-kontakty__hero-stats):not(.g22-study-hero__stats):not(.g22-eksternat-hero__stats):not(.g22-discounts__list) li,
.g22-checklist li {
	position: relative;
	padding-left: 22px;
	color: var(--g22h-ink-70);
	line-height: 1.55;
}

.g22-page-content ul:not(.g22-cards__grid):not(.g22-checklist):not(.g22-hero-stats):not(.g22-kontakty__hero-stats):not(.g22-study-hero__stats):not(.g22-eksternat-hero__stats):not(.g22-discounts__list) li::before,
.g22-checklist li::before {
	content: "";
	position: absolute;
	left: 0;
	top: 0.55em;
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background: var(--g22h-yellow);
}

/*
 * Shared hero proof strip — Контакти / Екстернат / Навч. процес.
 * One stacked cell pattern. Never overflow-wrap:anywhere (it splits
 * Ukrainian words mid-glyph). Opaque fill so page ornaments don’t bleed.
 */
.g22-hero-stats,
.g22-kontakty__hero-stats,
.g22-study-hero__stats,
.g22-eksternat-hero__stats {
	list-style: none;
	margin: 0;
	padding: 14px 8px;
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 0;
	align-items: stretch;
	inline-size: 100%;
	min-height: 76px;
	border-radius: 16px;
	background: #ececee;
	position: relative;
	z-index: 1;
	isolation: isolate;
	font-family: "Manrope", -apple-system, system-ui, sans-serif;
	box-sizing: border-box;
}

.g22-hero-stats li,
.g22-kontakty__hero-stats li,
.g22-study-hero__stats li,
.g22-eksternat-hero__stats li {
	position: relative;
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	justify-content: center;
	gap: 0.15em;
	margin: 0;
	padding: 4px 8px 4px 1.05rem;
	min-width: 0;
	border: 0;
	color: var(--g22h-ink, #1a1a1a);
	line-height: 1.2;
	text-align: left;
	box-sizing: border-box;
}

.g22-hero-stats li:not(:last-child),
.g22-kontakty__hero-stats li:not(:last-child),
.g22-study-hero__stats li:not(:last-child),
.g22-eksternat-hero__stats li:not(:last-child) {
	border-inline-end: 1px solid rgba(26, 26, 26, 0.1);
}

.g22-hero-stats li::before,
.g22-kontakty__hero-stats li::before,
.g22-study-hero__stats li::before,
.g22-eksternat-hero__stats li::before {
	content: "";
	position: absolute;
	left: 2px;
	top: 0.55em;
	width: 7px;
	height: 7px;
	border-radius: 50%;
	background: #ffd141;
}

.g22-hero-stats b,
.g22-kontakty__hero-stats b,
.g22-study-hero__stats b,
.g22-eksternat-hero__stats b {
	display: block;
	max-width: 100%;
	font-family: "Manrope", sans-serif;
	font-weight: 800;
	font-size: clamp(0.88rem, 0.95vw + 0.35rem, 1.1rem);
	letter-spacing: -0.02em;
	line-height: 1.2;
	color: var(--g22h-ink, #1a1a1a);
	font-variant-numeric: tabular-nums;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.g22-hero-stats span,
.g22-kontakty__hero-stats span,
.g22-study-hero__stats span,
.g22-eksternat-hero__stats span {
	display: block;
	max-width: 100%;
	font-family: "Manrope", -apple-system, system-ui, sans-serif;
	font-size: clamp(0.7rem, 0.55vw + 0.4rem, 0.82rem);
	line-height: 1.25;
	font-weight: 600;
	color: rgba(26, 26, 26, 0.72);
	overflow-wrap: normal;
	word-break: normal;
	hyphens: none;
}

@media (max-width: 860px) {
	.g22-hero-stats,
	.g22-kontakty__hero-stats,
	.g22-study-hero__stats,
	.g22-eksternat-hero__stats {
		padding: 12px 6px;
	}

	.g22-hero-stats li,
	.g22-kontakty__hero-stats li,
	.g22-study-hero__stats li,
	.g22-eksternat-hero__stats li {
		padding: 4px 6px 4px 0.95rem;
	}
}

@media (max-width: 560px) {
	.g22-hero-stats,
	.g22-kontakty__hero-stats,
	.g22-study-hero__stats,
	.g22-eksternat-hero__stats {
		grid-template-columns: 1fr;
		min-height: 0;
		padding: 4px 12px;
	}

	.g22-hero-stats li,
	.g22-kontakty__hero-stats li,
	.g22-study-hero__stats li,
	.g22-eksternat-hero__stats li {
		padding: 10px 8px 10px 1.15rem;
	}

	.g22-hero-stats li:not(:last-child),
	.g22-kontakty__hero-stats li:not(:last-child),
	.g22-study-hero__stats li:not(:last-child),
	.g22-eksternat-hero__stats li:not(:last-child) {
		border-inline-end: 0;
		border-block-end: 1px solid rgba(26, 26, 26, 0.1);
	}

	.g22-hero-stats b,
	.g22-kontakty__hero-stats b,
	.g22-study-hero__stats b,
	.g22-eksternat-hero__stats b {
		white-space: normal;
		overflow: visible;
		text-overflow: clip;
		font-size: 1.05rem;
	}

	.g22-hero-stats span,
	.g22-kontakty__hero-stats span,
	.g22-study-hero__stats span,
	.g22-eksternat-hero__stats span {
		font-size: 0.82rem;
	}
}

@media (max-width: 768px) {
	.g22-page-content {
		padding-inline: 20px;
	}
}

/* -------------------------------------------------- */
/* Cards (generation22/cards block, rendered inside     */
/* .g22-page-content)                                   */
/* -------------------------------------------------- */

.g22-page-content .g22-cards {
	padding-block: clamp(32px, 5vw, 56px);
}

.g22-page-content .g22-cards__head {
	display: block;
	max-width: 640px;
	margin: 0 0 32px;
	text-align: left;
}

.g22-page-content .g22-cards__eyebrow {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	grid-column: auto;
	margin: 0 0 16px;
	font-family: var(--g22h-font);
	font-size: 13px;
	font-weight: 600;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--g22h-ink-55);
}

.g22-page-content .g22-cards__eyebrow::before {
	content: "";
	width: 8px;
	height: 8px;
	flex: 0 0 8px;
	border-radius: 50%;
	background: var(--g22h-yellow);
}

.g22-page-content .g22-cards h2 {
	grid-column: auto;
	max-width: 20ch;
	margin: 0 0 12px;
	font-family: var(--g22h-font);
	font-weight: 800;
	font-size: clamp(1.8rem, 3vw, 2.6rem);
	line-height: 1.1;
	letter-spacing: -0.03em;
}

.g22-page-content .g22-cards__intro {
	grid-column: auto;
	max-width: 52ch;
	margin: 0;
	font-size: 0.9375rem;
	line-height: 1.6;
	color: var(--g22h-ink-70);
}

.g22-page-content .g22-cards__grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 16px;
	border-top: 0;
}

.g22-page-content .g22-card,
.g22-card {
	display: block;
	grid-column: auto;
	min-height: 0;
	padding: 28px;
	border: 1px solid var(--g22h-ink-08);
	border-radius: var(--g22h-radius-md);
	background: #fff;
	box-shadow: none;
	transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.g22-page-content .g22-card::before,
.g22-card::after {
	content: none;
}

.g22-page-content .g22-card h3,
.g22-card h3 {
	grid-column: auto;
	margin: 0 0 12px;
	font-family: var(--g22h-font);
	font-weight: 700;
	font-size: clamp(1.125rem, 1.8vw, 1.5rem);
	letter-spacing: -0.02em;
	color: var(--g22h-ink);
}

.g22-page-content .g22-card p,
.g22-card p {
	grid-column: auto;
	max-width: none;
	margin: 0;
	font-size: 0.9375rem;
	line-height: 1.65;
	color: var(--g22h-ink-70);
}

.g22-page-content .g22-card:hover,
.g22-card:hover {
	transform: translateY(-4px);
	border-color: var(--g22h-ink-08);
	box-shadow: 0 16px 40px rgba(26, 26, 26, 0.08);
}

@media (max-width: 640px) {
	.g22-page-content .g22-cards__grid {
		grid-template-columns: 1fr;
	}
}

/* -------------------------------------------------- */
/* CTA panel / form card — light, per bug C spec         */
/* -------------------------------------------------- */

.g22-cta-panel {
	max-width: min(640px, 100%);
	margin: clamp(48px, 6vw, 72px) auto 0;
	border-radius: var(--g22h-radius-lg);
	background: #fff;
	border: 1px solid var(--g22h-ink-10);
	color: var(--g22h-ink);
	padding: clamp(24px, 3.5vw, 40px);
	box-shadow: none;
}

.g22-cta-panel h2,
.g22-cta-panel p,
.g22-cta-panel label {
	color: var(--g22h-ink);
}

.g22-form {
	display: grid;
	gap: 16px;
}

.g22-form label {
	font-family: var(--g22h-font);
	font-size: 0.8125rem;
	font-weight: 600;
	color: var(--g22h-ink);
}

.g22-form input,
.g22-cta-panel .g22-form input,
.g22-form textarea,
.g22-cta-panel .g22-form textarea {
	box-sizing: border-box;
	width: 100%;
	min-height: 46px;
	border: 1px solid var(--g22h-ink-10);
	border-radius: 12px;
	background: var(--g22h-soft-gray);
	color: var(--g22h-ink);
	padding: 0.75rem 0.9rem;
	font: inherit;
	font-family: var(--g22h-font);
	font-size: 0.9375rem;
	transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.g22-form textarea { min-height: 100px; resize: vertical; }

.g22-form input:focus-visible,
.g22-form textarea:focus-visible {
	outline: 2px solid var(--g22h-purple);
	outline-offset: 2px;
	border-color: var(--g22h-purple);
	box-shadow: none;
}

.g22-form button {
	min-height: 48px;
	border: 0;
	border-radius: 999px;
	background: var(--g22h-purple);
	color: #fff;
	/* Sitewide pill-button normalization (2026-07-22): pure horizontal
	   padding, height governed by min-height above (was 0.85rem 1.5rem —
	   vertical component was redundant with min-height, now trimmed for
	   consistency with home-studio.css/inner-studio.css/pages/*.css). */
	padding: 0 24px;
	font: inherit;
	font-family: var(--g22h-font);
	font-size: 0.9375rem;
	font-weight: 700;
	letter-spacing: 0.02em;
	cursor: pointer;
	touch-action: manipulation;
	transition: background-color 0.2s ease, transform 0.2s ease;
}

.g22-form button:hover { background: var(--g22h-purple-hover); }
.g22-form button:active { transform: translateY(1px); }
.g22-form button:focus-visible {
	outline: 2px solid var(--g22h-purple);
	outline-offset: 2px;
}

.g22-form__notice--success { background: #edf3ec; color: #2b5230; }
.g22-form__notice--error { background: #fdebec; color: #8a2523; }

/* -------------------------------------------------- */
/* Price card                                           */
/* -------------------------------------------------- */

.g22-price-card {
	position: relative;
	overflow: hidden;
	min-height: 100%;
	padding: 28px;
	border: 1px solid var(--g22h-ink-08);
	border-radius: var(--g22h-radius-md);
	background: #fff;
}

.g22-price-card::after { content: none; }

.g22-price-card__label {
	display: block;
	margin: 0;
	font-family: var(--g22h-font);
	font-size: 0.8125rem;
	font-weight: 700;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--g22h-ink-55);
}

.g22-price-card__label::before { content: none; }

.g22-price-card__value {
	margin: 12px 0 0;
	font-family: var(--g22h-font);
	font-weight: 800;
	font-size: clamp(1.75rem, 3vw, 2.5rem);
	letter-spacing: -0.02em;
	color: var(--g22h-purple);
}

/* -------------------------------------------------- */
/* Focus / motion craft floor                           */
/* -------------------------------------------------- */

.g22-page-content a:focus-visible {
	outline: 2px solid var(--g22h-purple);
	outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
	.g22-card,
	.g22-form button,
	.g22-form input,
	.g22-form textarea {
		transition: none !important;
	}
}
