/* Base: tokens, reset, typography, layout, buttons, breadcrumbs, hero band, accordion, modal.
   Colours come from theme.json (single source); here they are aliased to short names. */
:root {
	--py-ink: var(--wp--preset--color--ink);
	--py-muted: var(--wp--preset--color--muted);
	--py-navy: var(--wp--preset--color--navy);
	--py-gold: var(--wp--preset--color--gold);
	--py-alert: var(--wp--preset--color--alert);
	--py-dark: var(--wp--preset--color--dark);
	--py-surface: var(--wp--preset--color--surface);
	--py-surface-alt: var(--wp--preset--color--surface-alt);
	--py-hairline: var(--wp--preset--color--hairline);
	--py-white: var(--wp--preset--color--white);
	--py-font: var(--wp--preset--font-family--calibri);
	--py-max: 1380px;
	--py-gutter: 40px;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
	margin: 0;
	font-family: var(--py-font);
	font-size: 17px;
	line-height: 1.6;
	color: var(--py-ink);
	background: var(--py-white);
}

img, svg { max-width: 100%; }
img { height: auto; }

h1, h2, h3, h4 { color: var(--py-navy); font-weight: 700; line-height: 1.1; margin: 0 0 .5em; }
h1 { font-size: clamp(34px, 5vw, 70px); line-height: 1.05; }
h2 { font-size: clamp(28px, 3.4vw, 44px); }
h3 { font-size: clamp(22px, 2.2vw, 28px); line-height: 1.2; }

a { color: var(--py-navy); }

button { font: inherit; }

:focus-visible { outline: 3px solid var(--py-navy); outline-offset: 3px; }
.py-footer :focus-visible, .py-cta :focus-visible, .py-mobile-menu :focus-visible { outline-color: var(--py-gold); }

.screen-reader-text {
	position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden;
	clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.py-skip-link {
	position: absolute; left: 16px; top: -100px; z-index: 1000; padding: 12px 20px;
	background: var(--py-ink); color: var(--py-white); font-weight: 700; text-decoration: none;
}
.py-skip-link:focus { top: 16px; }

/* Layout */
.py-container { width: 100%; max-width: var(--py-max); margin: 0 auto; padding-inline: var(--py-gutter); }
.py-section { padding-block: 80px; }
.py-main { display: block; min-width: 0; }

/* Buttons */
.py-btn {
	display: inline-flex; align-items: center; justify-content: center; height: 48px; padding: 0 30px;
	border: 0; font-size: 15px; font-weight: 600; text-decoration: none; cursor: pointer;
	transition: background-color .15s ease, color .15s ease;
}
.py-btn--dark { background: var(--py-ink); color: var(--py-white); }
.py-btn--dark:hover { background: #000; }
.py-btn--white { background: var(--py-white); color: var(--py-ink); height: 52px; }
.py-btn--white:hover { background: var(--py-surface); }
.py-btn--gold { background: var(--py-gold); color: var(--py-dark); font-weight: 700; border-radius: 6px; }
.py-btn--gold:hover { background: #E6A53A; }
.py-btn--block { display: flex; width: 100%; height: 54px; }
.py-btn--outline { height: 44px; padding: 0 26px; border: 1px solid var(--py-ink); border-radius: 4px; background: var(--py-white); color: var(--py-ink); }
.py-btn--outline:hover { background: var(--py-surface); }

/* Eyebrow label (small uppercase tag used above headings and in modals) */
.py-eyebrow { margin: 0 0 12px; font-size: 13px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: #B8913F; }

/* Breadcrumbs */
.py-breadcrumbs { margin: 0 0 24px; font-size: 13px; color: var(--py-muted); }
.py-breadcrumbs a { color: var(--py-muted); }
.py-breadcrumbs--dark, .py-breadcrumbs--dark a { color: #B9B9BF; }
.py-breadcrumbs--gold { margin-bottom: 22px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--py-gold); }
.py-breadcrumbs--gold a { color: var(--py-gold); text-decoration: none; }
.py-breadcrumbs--gold a:hover { text-decoration: underline; text-underline-offset: 4px; }
.py-breadcrumbs--gold .py-breadcrumbs__sep { margin-inline: 4px; }

/* Page hero band (breadcrumb + H1, intro from the page excerpt; template-parts/page-hero.php) */
.py-hero { background: var(--py-surface-alt); border-bottom: 1px solid var(--py-hairline); padding-block: 40px 56px; }
.py-hero h1 { margin: 0; font-size: clamp(44px, 5vw, 70px); font-weight: 400; line-height: 1.05; color: var(--py-ink); }
.py-hero__row { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 20px 64px; }
.py-hero__row .py-hero__intro { max-width: 480px; color: var(--py-muted); }
.py-hero__intro p { margin: 0; }
.py-hero__intro p + p { margin-top: 18px; }

/* Dark hero (template "Dark page"): title and a rule, intro below. */
.py-hero--dark { background: transparent; border: 0; padding-block: 48px 0; color: var(--py-white); }
.py-hero--dark .py-breadcrumbs { margin-bottom: 28px; }
.py-hero__heading { display: flex; align-items: center; gap: 22px; margin-bottom: 26px; }
.py-hero--dark h1 { min-width: 0; color: var(--py-white); }
.py-hero__rule { flex: 1; min-width: 24px; height: 1px; background: #3A3A40; }
.py-hero--dark .py-hero__intro { max-width: 760px; font-size: 16px; color: #D2D2D8; }

/* Dark pages: the whole page body on the dark ground. */
.py-dark-page .py-main { background: var(--py-dark); color: var(--py-white); }
.py-dark-page .py-main :focus-visible { outline-color: var(--py-gold); }

/* Empty image: used wherever a photo is missing (carousel slides, news cards). A quiet dark
   ground with a navy glow and a hint of gold, so the page still looks finished. The photo wall
   placeholder (assets/images/placeholder-photo.svg) draws the same thing. */
.py-empty-bg {
	background:
		radial-gradient(ellipse at 78% 30%, rgba(30, 74, 140, .55) 0%, rgba(11, 46, 99, .25) 38%, transparent 66%),
		radial-gradient(ellipse at 96% 100%, rgba(217, 150, 42, .22) 0%, transparent 42%),
		var(--py-dark);
}

/* Editor content */
.py-prose > * { max-width: var(--wp--style--global--content-size, 820px); }
.py-prose > .alignwide, .py-prose > .alignfull { max-width: none; }
.py-prose :where(p, ul, ol) { margin: 0 0 1.2em; }

/* Accordion (button + panel; behaviour in main.js) */
.py-accordion { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--py-ink); }
.py-accordion__item { border-bottom: 1px solid #D4D4D0; }
.py-accordion__trigger {
	display: flex; width: 100%; justify-content: space-between; align-items: flex-start; gap: 22px;
	padding: 20px 0; border: 0; background: transparent; text-align: left; color: var(--py-ink);
	font-size: 21px; line-height: 1.3; cursor: pointer;
}
.py-accordion__sign { flex: none; font-size: 22px; line-height: 1; color: var(--py-muted); }
.py-accordion__panel { padding: 0 44px 22px 0; font-size: 15px; color: var(--py-muted); }
.py-accordion__panel[hidden] { display: none; }

/* Modal ("Read more" dialogs; behaviour in main.js) */
.py-modal { position: fixed; inset: 0; z-index: 200; display: flex; align-items: center; justify-content: center; padding: 24px; }
.py-modal[hidden] { display: none; }
.py-modal__backdrop { position: absolute; inset: 0; background: rgba(20, 20, 23, .65); }
.py-modal__dialog {
	position: relative; width: 100%; max-width: 640px; max-height: 86vh; overflow: auto; padding: 48px 44px 40px;
	background: var(--py-white); border-radius: 12px; border-top: 4px solid var(--py-gold); box-shadow: 0 24px 60px rgba(0, 0, 0, .35);
}
.py-modal__close {
	position: absolute; top: 14px; right: 16px; width: 40px; height: 40px; border: 0; border-radius: 50%; background: var(--py-surface);
	font-size: 24px; line-height: 1; color: var(--py-ink); cursor: pointer;
}
.py-modal__close:hover { background: #E4E4E0; }
.py-modal__title { margin: 0 0 20px; font-size: 30px; font-weight: 400; line-height: 1.25; color: var(--py-ink); }
.py-modal__body { font-size: 17px; color: #3A3A40; }
.py-modal__body > :where(p, ul, ol) { margin: 0 0 1em; }
.py-modal__body > :last-child { margin-bottom: 0; }
/* Lists in dialog text: gold square markers, a hairline under each item. */
.py-modal__body ul { padding: 0; list-style: none; }
.py-modal__body ul > li { position: relative; padding: 8px 0 8px 18px; border-bottom: 1px solid var(--py-hairline); font-size: 16px; color: var(--py-ink); }
.py-modal__body ul > li::before { content: ""; position: absolute; left: 0; top: 18px; width: 6px; height: 6px; background: var(--py-gold); }
.py-modal__body :where(h2, h3, h4) { margin: 1.2em 0 .5em; font-size: 20px; line-height: 1.3; color: var(--py-ink); }
.py-modal__icon {
	display: inline-flex; align-items: center; justify-content: center; width: 58px; height: 58px; margin-bottom: 18px;
	border-radius: 12px; background: #EEF1F7; color: var(--py-navy);
}
.py-modal__actions { display: flex; justify-content: flex-end; margin-top: 32px; }
body.py-modal-open { overflow: hidden; }

@media (max-width: 700px) {
	:root { --py-gutter: 20px; }
	.py-section { padding-block: 56px; }
	.py-modal__dialog { padding: 44px 24px 28px; }
	.py-modal__title { font-size: 26px; }
}

@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	*, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
}
