/* Section patterns. Values from post-447.css, post-11.css, post-603.css, and the reference screenshots. */

/* Page hero: photo, 80% ink overlay, uppercase white title, breadcrumb. 202 px top / 260 px bottom padding. */
.page-hero.wp-block-cover { padding: 202px 25px 260px; min-height: 0 !important; }
.page-hero h1 { color: var(--wp--preset--color--white); margin: 0 0 25px; }
.page-hero__crumbs { font-family: var(--wp--preset--font-family--body); font-size: 22px; line-height: 1.5; color: var(--wp--preset--color--white); margin: 0; }
.page-hero__crumbs a { color: var(--wp--preset--color--white); }
/* The old site showed this link in red, which has 1.9:1 contrast on the hero. Rose meets 4.5:1. */
.page-hero__crumbs a + a,
.page-hero__crumbs a:nth-of-type(2) { color: var(--jspa-link-on-dark); }

/* Image box card: icon, title, text; 35 x 28 px padding; right and bottom border #E1E1E1. */
.image-box-card { padding: 35px 28px; background: var(--wp--preset--color--white); border: solid #e1e1e1; border-width: 0 1px 1px 0; text-align: center; }
.image-box-card.is-grey { background: var(--wp--preset--color--light); }
.image-box-card > * { margin-block: 0; }
.image-box-card__icon { margin: 0 auto 20px; }
.image-box-card h3 { font-size: 24px; margin-bottom: 7px; color: var(--wp--preset--color--text); }
.image-box-card p { font-size: 16px; line-height: 1.5; color: var(--wp--preset--color--text); }
.image-box-card__more { margin-top: 20px !important; }
.image-box-card__more :is(a, span) { color: var(--wp--preset--color--red); font-size: 24px; text-decoration: none; display: inline-block; transition: transform 0.3s; }

/* Linked cards: the title link covers the whole card, so a click anywhere opens it and each card
   stays one link for keyboard and screen-reader users. Hover and keyboard focus lift the card, mark
   the title (red #9E1C32: 7.88:1 on white, 6.2:1 on grey), and slide the arrow. */
:is(.image-box-card, .service-card, .why-card):has(:is(h3, .service-card__title) a) { position: relative; transition: box-shadow 0.3s, transform 0.3s, background-color 0.3s; }
:is(.image-box-card, .service-card, .why-card) :is(h3, .service-card__title) a::after { content: ""; position: absolute; inset: 0; z-index: 1; }
:is(.image-box-card, .service-card, .why-card) :is(h3, .service-card__title) a:focus-visible { outline: none; }
:is(.image-box-card, .service-card):has(:is(h3, .service-card__title) a):is(:hover, :focus-within) { box-shadow: 0 12px 40px rgba(34, 30, 32, 0.18); z-index: 2; }
:is(.image-box-card, .service-card):has(:is(h3, .service-card__title) a):is(:hover, :focus-within) :is(h3, .service-card__title) a { color: var(--wp--preset--color--red); text-decoration: underline; text-underline-offset: 4px; }
:is(.image-box-card, .service-card):has(:is(h3, .service-card__title) a:focus-visible) { outline: 3px solid var(--wp--preset--color--red); outline-offset: -3px; }
.image-box-card:has(h3 a):is(:hover, :focus-within) .image-box-card__more span { transform: translateX(6px); }
.why-card:has(h3 a):is(:hover, :focus-within) { background: rgba(158, 28, 50, 0.9); box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35); }
.why-card:has(h3 a):is(:hover, :focus-within) h3 a { text-decoration: underline; text-underline-offset: 4px; }
.why-card:has(h3 a:focus-visible) { outline: 3px solid var(--wp--preset--color--white); outline-offset: -3px; }
@media (prefers-reduced-motion: no-preference) {
	:is(.image-box-card, .service-card, .why-card):has(:is(h3, .service-card__title) a):is(:hover, :focus-within) { transform: translateY(-4px); }
}

/* Practice-area grid (template 603): three columns, alternating cells. */
.practice-card-grid { gap: 0 !important; max-width: 1140px; margin-inline: auto; }

/* Service cards (home): white, monogram, uppercase Plantin title, red quarter-circle arrow. */
.service-card-grid { gap: 30px 30px !important; max-width: 1140px; margin-inline: auto; }
.service-card { position: relative; background: var(--wp--preset--color--white); padding: 24px 25px; min-height: 120px; gap: 37px !important; box-shadow: 0 0 10px rgba(0, 0, 0, 0.05); }
.service-card__icon { margin: 0; flex: 0 0 auto; }
.service-card__title { font-size: 24px; text-transform: uppercase; margin: 0; color: var(--wp--preset--color--text); }
.service-card__arrow { position: absolute; right: 0; bottom: 0; margin: 0; }
.service-card__arrow :is(a, span) {
	display: flex;
	align-items: flex-end;
	justify-content: flex-end;
	width: 66px;
	height: 48px;
	padding: 0 18px 12px 0;
	box-sizing: border-box;
	border-radius: 50px 0 0 0;
	background: var(--wp--preset--color--red);
	color: var(--wp--preset--color--white);
	font-size: 20px;
	line-height: 1;
	text-decoration: none;
}
.service-card__arrow a:hover,
.service-card:has(.service-card__title a):is(:hover, :focus-within) .service-card__arrow span { color: var(--wp--preset--color--white); background: var(--wp--preset--color--ink); }

/* Intro with call to action: grey band; white-framed photo pulled 200 px up over the hero. */
/* flow-root keeps the card's negative top margin inside the band: without it the margin collapses
   through the band, the band slides up under the hero's overlay, and a flat dark strip shows. */
.cta-band { display: flow-root; background: var(--wp--preset--color--light); padding: 0 25px 100px; }
.cta-band__card { max-width: 1140px; margin: -200px auto 0; position: relative; z-index: 1; }
.cta-band__image { margin: 0 0 40px; padding: 10px; background: var(--wp--preset--color--white); }
/* A card that starts with text (Privacy Policy) is a white box, as on the old site, so the text it
   lifts over the hero stays on white. */
.cta-band__card:has(> :is(h1, h2, h3, h4, p):first-child) { background: var(--wp--preset--color--white); padding: 10px 10px 20px; }
.cta-band__image img { width: 100%; height: auto; display: block; }
.cta-band h2 { margin: 0; }
.cta-band .wp-block-separator.is-style-jspa-short { margin: 20px 0 25px; }
.cta-band .wp-block-separator.is-style-jspa-short:not(.alignleft) { margin-inline: auto; }
/* The contact map: 96 px below it (Elementor widget margin; 55 px tablet, 17 px mobile). */
.cta-band__card > .map-embed { margin-bottom: 96px; }
@media (max-width: 1024.98px) { .cta-band__card > .map-embed { margin-bottom: 55px; } }
@media (max-width: 767.98px) { .cta-band__card > .map-embed { margin-bottom: 17px; } }
.cta-band p { font-size: 16px; line-height: 1.5; }
.cta-band .wp-block-buttons { margin-top: 30px; gap: 20px 100px; }

@media (max-width: 1024.98px) {
	.practice-card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
}
@media (max-width: 767.98px) {
	.page-hero.wp-block-cover { padding: 140px 20px 160px; }
	.page-hero__crumbs { font-size: 16px; }
	.practice-card-grid,
	.service-card-grid { grid-template-columns: 1fr !important; }
	.service-card { flex-direction: column; text-align: center; padding: 40px 25px 60px; }
	.cta-band__card { margin-top: -120px; }
}

/* FAQ accordion: dark photo panel, white Plantin title, uppercase Montserrat 600 questions with a plus sign. */
.faq-accordion { position: relative; padding: 300px 50px 60px; color: var(--wp--preset--color--white); background-color: var(--wp--preset--color--ink); }
.faq-accordion::before { content: ""; position: absolute; inset: 0; background: rgba(34, 30, 32, 0.6); }
.faq-accordion > * { position: relative; }
.faq-accordion__title { color: var(--wp--preset--color--white); font-size: var(--wp--preset--font-size--title-2-caps); font-weight: 500; margin: 0 0 30px; }
/* Accordion items: dark text on light backgrounds; white on the dark panels (see below). */
.faq-item { border-bottom: 1px solid #e1e1e1; margin: 0; color: var(--wp--preset--color--text); }
.faq-item[open] { padding-bottom: 16px; }
.faq-item summary {
	position: relative;
	list-style: none;
	cursor: pointer;
	padding: 12px 40px 12px 0;
	font-family: var(--wp--preset--font-family--body);
	font-size: 14px;
	font-weight: 600;
	line-height: 1.3;
	text-transform: uppercase;
	color: var(--wp--preset--color--ink);
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; position: absolute; right: 10px; top: 50%; transform: translateY(-50%); font-size: 22px; font-weight: 400; }
.faq-item[open] summary::after { content: "−"; }
.faq-item summary:focus-visible { outline: 2px solid var(--wp--preset--color--red); outline-offset: 2px; }
.faq-item p { color: inherit; font-size: 15px; line-height: 1.5; margin: 0 0 10px; }
.faq-item p:last-child { margin-bottom: 0; }
:is(.faq-accordion, .faq-split, .is-photo-bg) .faq-item { border-bottom-color: rgba(255, 255, 255, 0.25); color: var(--wp--preset--color--white); }
:is(.faq-accordion, .faq-split, .is-photo-bg) .faq-item summary { color: var(--wp--preset--color--white); }
:is(.faq-accordion, .faq-split, .is-photo-bg) .faq-item summary:focus-visible { outline-color: var(--wp--preset--color--white); }

/* Contact trio: centred title, three bordered cards with red line icons. */
.contact-trio { padding: 100px 25px; }
.contact-trio__title { font-size: var(--wp--preset--font-size--title-2-caps); font-weight: 500; margin: 0; }
.contact-trio__cards { max-width: 1140px; margin: 20px auto 0 !important; gap: 30px !important; }
.contact-card { border: 1px solid #e1e1e1; padding: 50px 30px; text-align: center; }
.contact-card > * { margin-block: 0; }
/* The three icons have different shapes, so each is 56 px high (width follows): the titles and
   values then line up across the cards. The img carries an inline 40 px width from the editor. */
.contact-card__icon { margin: 0 auto 20px; height: 56px; }
.contact-card__icon img { height: 56px !important; width: auto !important; max-width: 100%; object-fit: contain; }
.contact-card__title { font-family: var(--wp--preset--font-family--roboto); font-size: 22px; font-weight: 400; text-transform: uppercase; margin-bottom: 10px; }
.contact-card__value .wp-block-button__link {
	padding: 0;
	background: none;
	font-family: var(--wp--preset--font-family--body);
	font-size: 18px;
	font-weight: 400;
	line-height: 1.5;
	color: var(--wp--preset--color--text);
	white-space: normal;
}
.contact-card__value .wp-block-button__link:hover { color: var(--wp--preset--color--red); background: none; }

/* About split: portrait beside a white card; red and outlined buttons. */
.about-split { max-width: 1140px; margin-inline: auto; gap: 0 !important; background: var(--wp--preset--color--white); }
.about-split__media figure { margin: 0; height: 100%; }
.about-split__media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.about-split__card { padding: 0 30px 0 30px; display: flex; flex-direction: column; justify-content: center; }
.about-split__title { font-size: var(--wp--preset--font-size--title-2-caps); font-weight: 500; margin: 0; }
.about-split .wp-block-separator.is-style-jspa-short { margin: 25px 0; }
.about-split p { font-size: 16px; line-height: 1.6; }
.about-split .wp-block-buttons { gap: 20px; }
.wp-block-button.is-style-outline .wp-block-button__link { background: transparent; color: var(--wp--preset--color--ink); border: 1px solid var(--wp--preset--color--ink); }
.wp-block-button.is-style-outline .wp-block-button__link:hover { background: var(--wp--preset--color--ink); color: var(--wp--preset--color--white); }

/* Why choose: dark band, maroon cards (red at 80% over the band), white monogram and text. */
.why-choose { background: #4f4c4d; padding: 100px 25px 110px; }
.why-choose__title { color: var(--wp--preset--color--white); font-size: var(--wp--preset--font-size--title-2-caps); font-weight: 500; margin: 0; }
.why-choose__cards { max-width: 1105px; margin: 20px auto 0 !important; gap: 16px !important; }
.why-card { background: rgba(158, 28, 50, 0.6); border: 1px solid rgba(255, 255, 255, 0.25); padding: 55px 25px 40px; text-align: center; }
.why-card > * { margin-block: 0; }
.why-card figure { margin-bottom: 30px; }
.why-card h3 { color: var(--wp--preset--color--white); font-size: 24px; margin-bottom: 25px; }
/* Room for two lines in every title, so the texts under one- and two-line titles start on one line. */
.why-card h3 { min-height: 2lh; display: flex; align-items: flex-end; justify-content: center; }
.why-card p { color: var(--wp--preset--color--white); font-size: 16px; line-height: 1.5; }

/* Map in a white frame, pulled up over the page hero on the contact page. */
.map-embed { max-width: 1120px; margin: 0 auto; padding: 10px; background: var(--wp--preset--color--white); }
.map-embed iframe { display: block; width: 100%; height: 600px; border: 0; }

/* Two-column list (.bp-list on Employment Law). */
ul.is-style-jspa-two-column { columns: 2; column-gap: 40px; }

@media (max-width: 1024.98px) {
	.why-choose__cards,
	.contact-trio__cards { grid-template-columns: 1fr !important; }
	.map-embed iframe { height: 450px; }
}
@media (max-width: 767.98px) {
	.faq-accordion { padding: 160px 20px 40px; }
	.about-split__card { padding: 30px 20px; }
	.about-split__media img { height: auto; }
	ul.is-style-jspa-two-column { columns: 1; }
	.map-embed iframe { height: 350px; }
}

/* Icon list (Elementor icon list and icon box): red check marks (Font Awesome 5 "check", assets/icons). */
ul.is-style-jspa-icon-list { list-style: none; padding-left: 0; }
ul.is-style-jspa-icon-list li { position: relative; padding-left: 28px; margin-bottom: 8px; }
ul.is-style-jspa-icon-list li::before {
	content: "";
	position: absolute;
	left: 0;
	top: 0.35em;
	width: 14px;
	height: 14px;
	background: var(--wp--preset--color--red);
	-webkit-mask: url("../icons/check.svg") no-repeat center / contain;
	mask: url("../icons/check.svg") no-repeat center / contain;
}
