/*--------------------------------------------------------------
Typography
--------------------------------------------------------------*/
h1 a, h2 a, h3 a, h4 a, h5 a, h6 a {
	text-decoration: none;
	font-weight:inherit;
	color:inherit;
}

b,
strong {
	font-weight: bold;
}

dfn,
cite,
em,
i {
	font-style: italic;
}

/*--------------------------------------------------------------
Pills
--------------------------------------------------------------*/
/* Pill style for Paragraph block — applied via registered block style */
.is-style-rg-pill {
	display: inline-block;
	padding: 0.3em 0.85em;
	border-radius: 5px;
	letter-spacing: 0.05em;
	font-weight: 600;
	font-size: 0.85rem;
	line-height: 1;
	margin: 0;
}

.is-style-rg-pill a {
	text-decoration: none;
}

/* Default when no colour chosen in editor: beige bg, primary text */
.is-style-rg-pill:not(.has-background) {
	background: var(--wp--preset--color--beige);
}

.is-style-rg-pill:not(.has-text-color) {
	color: var(--wp--preset--color--theme-primary);
}

/* Dark-background variant — used in archive hero covers */
.is-style-rg-pill.rg-pill--on-dark,
.rg-pill--on-dark {
	background: transparent;
	color: rgba(240,237,231,0.85);
	border: 1px solid rgba(240,237,231,0.35);
}

/*--------------------------------------------------------------
Links
--------------------------------------------------------------*/
a {
	transition: color 0.2s ease, text-decoration-color 0.2s ease;
}

.has-theme-primary-background-color a {
	text-decoration-color: var(--wp--preset--color--white);
}

.rg-linked-block {
	text-decoration: none;
	position: relative;
}

.rg-linked-block:hover {
	text-decoration: none;
	transform: scale(1.05);
}

.rg-linked-block:hover :is(h1, h2, h3, h4, h5, h6) {
	text-decoration: underline;
	text-decoration-color: var(--wp--preset--color--theme-primary);
}

/* Reserve space in-flow */
.rg-linked-block.rg-has-corner-arrow::after {
	content: "";
	display: block;
	height: 40px;
}

.rg-linked-block.rg-has-corner-arrow::before {
	content: "";
	position: absolute;
	right: var(--wp--preset--spacing--xl);
	bottom: var(--wp--preset--spacing--xl);
	width: 45px;
	height: 45px;
	border-radius: 8px;
	background-color: var(--wp--preset--color--white);
	background-image: url("data:image/svg+xml,%3Csvg%20viewBox%3D%220%200%2024%2024%22%20width%3D%2222%22%20height%3D%2222%22%20fill%3D%22none%22%20xmlns%3D%22http%3A//www.w3.org/2000/svg%22%3E%3Cpath%20d%3D%22M5%2012h12M13%206l6%206-6%206%22%20stroke%3D%22%23000%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: center;
	background-size: 31px 31px;
	pointer-events: none;
	z-index: 2;
	transition: transform 0.3s ease;
}

.rg-linked-block.rg-has-corner-arrow:hover::before {
	transform: scale(1.2);
}

/*--------------------------------------------------------------
Buttons
--------------------------------------------------------------*/
.wp-block-buttons a:active,
.wp-block-buttons a:focus,
.wp-block-buttons a {
	text-decoration: none;
	text-decoration-thickness: 0;
}

.wp-block-button__link:focus-visible {
	outline: 2px solid var(--wp--preset--color--theme-primary);
	outline-offset: 3px;
}

/*--------------------------------------------------------------
Section Arrow
--------------------------------------------------------------*/
.is-style-rg-arrow-section {
	position: relative;
	z-index: 0;
}

/* Rounded diamond tab (background shape) */
.is-style-rg-arrow-section::before {
	content: "";
	position: absolute;
	left: 50%;
	top: 0;
	z-index: 0;

	width: 5rem;
	height: 5rem;

	background-color: inherit;
	border-radius: 1.7rem;

	transform: translateX(-50%) translateY(-30%) rotate(45deg);

	pointer-events: none;
}

/* The injected arrow button (click target + icon only) */
.is-style-rg-arrow-section > .rg-section-arrow {
	position: absolute;
	left: 50%;
	top: 0;
	transform: translateX(-50%) translateY(-95%);
	z-index: 1;
	width: 5rem;
	height: 2rem;
	padding: 0;
	display: grid;
	place-items: center;
	border: 0;
	border-radius: 0;
	cursor: pointer;
	-webkit-appearance: none;
	appearance: none;
	background: transparent;
	color: var(--wp--preset--color--black);
}

/* SVG sizing + color */
.is-style-rg-arrow-section > .rg-section-arrow svg {
	transform: translateY(30%);
	width: 1.5rem;
	height: 1.5rem;
	max-width: none;
	display: block;
	fill: currentColor;

	transition: transform 160ms ease;
}

/* Hover / focus interaction */
.is-style-rg-arrow-section > .rg-section-arrow:hover svg,
.is-style-rg-arrow-section > .rg-section-arrow:focus-visible svg {
	transform: translateY(45%);
}

/* Focus ring */
.is-style-rg-arrow-section > .rg-section-arrow:focus-visible {
	outline: 2px solid currentColor;
	outline-offset: 3px;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
	.is-style-rg-arrow-section > .rg-section-arrow svg {
		transition: none;
	}
}

/*--------------------------------------------------------------
People Block
--------------------------------------------------------------*/

.rg-people {
	--rg-people-cols: 4;
	--rg-people-gap: clamp(1rem, 2vw, 1.75rem);
	position: relative;
}

.rg-people--cols-3 { --rg-people-cols: 3; }
.rg-people--cols-4 { --rg-people-cols: 4; }

.rg-people__nav {
	display: flex;
	justify-content: flex-end;
	gap: 0.5rem;
	margin-bottom: 1rem;
	width: 100%;
}

.rg-people__nav-btn {
	width: 40px;
	height: 40px;
	padding: 0;
	margin: 0;
	border: 1px solid currentColor;
	border-radius: 50%;
	background: transparent;
	color: inherit;
	cursor: pointer;
	display: grid;
	place-items: center;
	transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.rg-people__nav-btn:hover:not(:disabled) {
	background-color: var(--wp--preset--color--theme-primary);
	border-color: var(--wp--preset--color--theme-primary);
	color: var(--wp--preset--color--white);
}

.rg-people__nav-btn:disabled {
	opacity: 0.25;
	cursor: default;
	pointer-events: none;
}

.rg-people__nav-btn svg {
	display: block;
	width: 1.2rem;
	height: 1.2rem;
}

.rg-people__viewport {
	overflow: hidden;
}

.rg-people__track {
	display: flex;
	gap: var(--rg-people-gap);
	will-change: transform;
	transform: translateX(0);
}

.rg-people__card {
	flex: 0 0 calc(
		(100% - var(--rg-people-gap) * (var(--rg-people-cols) - 1)) / var(--rg-people-cols)
	);
}

.rg-people__card-link {
	display: block;
	text-decoration: none;
	color: inherit;
}

.rg-people__card-link:hover {
	text-decoration: none;
}

.rg-people__img-wrap {
	aspect-ratio: 3 / 4;
	overflow: hidden;
	border-radius: var(--wp--preset--border-radius--md, 8px);
	background-color: var(--wp--preset--color--beige);
	margin-bottom: 1rem;
}

.rg-people__img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: top center;
	transition: transform 0.4s ease;
}

.rg-people__card-link:hover .rg-people__img {
	transform: scale(1.04);
}

.rg-people__img-placeholder {
	width: 100%;
	height: 100%;
	background-color: var(--wp--preset--color--beige);
	display: flex;
	align-items: center;
	justify-content: center;
	color: rgba(0, 0, 0, 0.2);
}

.rg-people__img-placeholder svg {
	width: 50%;
	height: 50%;
}

.rg-people__info {
	display: flex;
	flex-direction: column;
	gap: 0.2rem;
	padding-top: 0.75rem;
}

.rg-people__name {
	margin: 0;
	font-weight: 700;
}

.rg-people__role {
	margin: 0;
	font-size: 0.875em;
	opacity: 0.75;
}

.rg-people__card-link:hover .rg-people__name {
	text-decoration: underline;
	text-decoration-color: var(--wp--preset--color--theme-primary);
}

@media (max-width: 900px) {
	.rg-people { --rg-people-cols: 2; }
}

/*--------------------------------------------------------------
Practice Areas Block
--------------------------------------------------------------*/

/* Base — shared by both layouts */
.rg-practice-areas {
	position: relative;
}

/* --- Carousel layout --- */

.rg-practice-areas--carousel {
	--rg-pa-cols: 3;
	--rg-pa-gap: clamp(1rem, 2vw, 1.75rem);
}

.rg-practice-areas--carousel .rg-practice-areas__nav {
	display: flex;
	justify-content: flex-end;
	gap: 0.5rem;
	margin-bottom: 1rem;
	width: 100%;
}

.rg-practice-areas--carousel .rg-practice-areas__nav-btn {
	width: 40px;
	height: 40px;
	padding: 0;
	margin: 0;
	border: 1px solid currentColor;
	border-radius: 50%;
	background: transparent;
	color: inherit;
	cursor: pointer;
	display: grid;
	place-items: center;
	transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.rg-practice-areas--carousel .rg-practice-areas__nav-btn:hover:not(:disabled) {
	background-color: var(--wp--preset--color--theme-primary);
	border-color: var(--wp--preset--color--theme-primary);
	color: var(--wp--preset--color--white);
}

.rg-practice-areas--carousel .rg-practice-areas__nav-btn:disabled {
	opacity: 0.25;
	cursor: default;
	pointer-events: none;
}

.rg-practice-areas--carousel .rg-practice-areas__nav-btn svg {
	display: block;
	width: 1.2rem;
	height: 1.2rem;
}

.rg-practice-areas--carousel .rg-practice-areas__viewport {
	overflow: hidden;
}

.rg-practice-areas--carousel .rg-practice-areas__track {
	display: flex;
	gap: var(--rg-pa-gap);
	will-change: transform;
	transform: translateX(0);
}

.rg-practice-areas--carousel .rg-practice-areas__card {
	flex: 0 0 calc(
		(100% - var(--rg-pa-gap) * (var(--rg-pa-cols) - 1)) / var(--rg-pa-cols)
	);
}

@media (max-width: 900px) {
	.rg-practice-areas--carousel { --rg-pa-cols: 2; }
}

@media (max-width: 600px) {
	.rg-practice-areas--carousel { --rg-pa-cols: 1; }
}

/* --- Grid layout --- */

.rg-practice-areas--grid .rg-practice-areas__grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
	gap: clamp(1rem, 2vw, 1.75rem);
}

/* Stretch article wrapper so the card link fills full cell height */
.rg-practice-areas--grid .rg-practice-areas__card {
	display: flex;
	flex-direction: column;
}

.rg-practice-areas--grid .rg-practice-area-card__link {
	flex: 1;
}

.rg-practice-area-card__link {
	display: flex;
	flex-direction: column;
	align-items: stretch;
	gap: 0.75rem;
	text-decoration: none;
	color: inherit;
	height: 100%;
	padding: 1.25rem 1.5rem;
	background-color: var(--wp--preset--color--beige);
	transition: transform 0.2s ease;
}

.rg-practice-area-card__link:hover {
	text-decoration: none;
	transform: scale(1.02);
}

/* Icon + title side-by-side row */
.rg-practice-area-card__header {
	display: flex;
	align-items: center;
	gap: 0.75rem;
}

.rg-practice-area-card__icon {
	flex-shrink: 0;
}

.rg-practice-area-card__icon img {
	display: block;
	width: 36px;
	height: 36px;
	object-fit: contain;
}

.rg-practice-area-card__title {
	font-size: 0.8rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.06em;
	margin: 0;
	line-height: 1.3;
}

.rg-practice-area-card__desc {
	/* Indent to align under the title, not the icon */
	padding-left: calc(36px + 0.75rem);
	margin: 0;
	font-size: 0.875rem;
	line-height: 1.6;
	opacity: 0.75;
}

/*--------------------------------------------------------------
Cases List Block
--------------------------------------------------------------*/

/* --- Grid layout --- */

.rg-cases-list--grid .rg-cases-list__grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
	gap: clamp(1rem, 2vw, 1.75rem);
}

/* Stretch article wrapper so the card fills full grid cell height */
.rg-cases-list--grid .rg-cases-list__card {
	display: flex;
	flex-direction: column;
}

.rg-cases-list--grid .case-card {
	flex: 1;
	display: flex;
	flex-direction: column;
}

.rg-cases-list--grid .case-card__body {
	flex: 1;
}

/* --- List layout --- */

.rg-cases-list--list .rg-cases-list__list {
	list-style: none;
	margin: 0;
	padding: 0;
}

.rg-cases-list--list .rg-cases-list__item {
	border-bottom: 1px solid rgba(0, 0, 0, 0.12);
}

.rg-cases-list--list .rg-cases-list__item:first-child {
	border-top: 1px solid rgba(0, 0, 0, 0.12);
}

/* Case list item partial — used by list layout */
.case-list-item {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	padding: 0.8rem 0;
	text-decoration: none;
	color: inherit;
	transition: color 0.2s ease;
}

.case-list-item:hover {
	text-decoration: none;
	color: var(--wp--preset--color--theme-primary);
}

.case-list-item__title {
	flex: 1;
	font-size: 0.95rem;
	line-height: 1.4;
}

.case-list-item__arrow {
	flex-shrink: 0;
	width: 1.1rem;
	height: 1.1rem;
	opacity: 0.6;
	transition: transform 0.2s ease, opacity 0.2s ease;
}

.case-list-item:hover .case-list-item__arrow {
	transform: translateX(3px);
	opacity: 1;
}

/*--------------------------------------------------------------
News Block
--------------------------------------------------------------*/

.rg-news__grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: clamp(1rem, 2vw, 1.75rem);
}

@media (max-width: 900px) {
	.rg-news__grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 600px) {
	.rg-news__grid { grid-template-columns: 1fr; }
}

/* posts-card — base styles live in style.css; no overrides needed here */

/*--------------------------------------------------------------
Testimonials
--------------------------------------------------------------*/
.testimonial-card {
	--testimonial-quote-pad: 4.7rem;
}

.testimonial-card__grid {
	display: grid;
	grid-template-columns: 1fr minmax(0, 280px);
	gap: var(--wp--preset--spacing--xl);
	align-items: center;
}

.testimonial-card--no-image .testimonial-card__grid {
	grid-template-columns: 1fr;
}

@media (max-width: 900px) {
	.testimonial-card__grid {
		grid-template-columns: 1fr;
	}
}

.testimonial-card__quote {
	position: relative;
	padding-left: var(--testimonial-quote-pad);
}

.testimonial-card__quote > *:first-child {
	margin-top: 0;
}

.testimonial-card__quote > *:last-child {
	margin-bottom: 0;
}

.testimonial-card__quote > * {
	position: relative;
	z-index: 1;
}

.testimonial-card__quote::before {
	content: "“";
	position: absolute;
	left: 0;
	top: 0;
	font-family: var(--wp--preset--font-family--montserrat);
	font-size: 130px;
	line-height: .7;
	font-weight: 700;
	color: var(--wp--preset--color--theme-primary);
	z-index: 0;
	pointer-events: none;
}

.testimonial-card__attribution {
	margin: var(--wp--preset--spacing--md) 0 0;
	padding-left: var(--testimonial-quote-pad);
	font-weight: 700;
}

.testimonial-card__imagewrap {
	border-radius: var(--wp--preset--border-radius--md);
	overflow: hidden;
}

.testimonial-card__img {
	display: block;
	width: 100%;
	height: auto;
}

/* ── Testimonial list (slider) ── */

.testimonial-list {
	position: relative;
}

.testimonial-list__viewport {
	width: 100vw;
	margin-left: calc(50% - 50vw);
	overflow: hidden;
	padding-top: var(--wp--preset--spacing--lg);
	padding-bottom: var(--wp--preset--spacing--lg);
	padding-left: max(
		var(--wp--style--root--padding-left),
		calc((100vw - var(--wp--style--global--content-size)) / 2)
	);
	padding-right: max(
		var(--wp--style--root--padding-right),
		calc((100vw - var(--wp--style--global--content-size)) / 2)
	);
}

.testimonial-list__track {
	display: flex;
	gap: 34px;
	align-items: stretch;
	will-change: transform;
	transform: translate3d(0, 0, 0);
}

.testimonial-list .testimonial-card {
	flex: 0 0 auto;
	width: 700px;
	max-width: 700px;
}

.testimonial-list .testimonial-card__link {
	display: block;
	color: inherit;
	text-decoration: none;
	background: var(--wp--preset--color--white);
	border-radius: var(--wp--preset--border-radius--md);
	padding: var(--wp--preset--spacing--xl);
}

.testimonial-list .testimonial-card__link:hover {
	text-decoration: none;
	transform: scale(1.05);
}

.testimonial-list .testimonial-card__link:hover .testimonial-card__attribution {
	text-decoration: underline;
	text-decoration-color: var(--wp--preset--color--theme-primary);
}

.testimonial-list .testimonial-card__grid {
	grid-template-columns: 1fr minmax(0, 220px);
	gap: var(--wp--preset--spacing--2-xl);
}

.testimonial-list .testimonial-card--no-image .testimonial-card__grid {
	grid-template-columns: 1fr;
}

@media (max-width: 900px) {
	.testimonial-list .testimonial-card {
		width: min(700px, 90vw);
		max-width: none;
	}

	.testimonial-list .testimonial-card__grid {
		grid-template-columns: 1fr;
	}
}

/*--------------------------------------------------------------
Block Layout Utilities
--------------------------------------------------------------*/

/* Reverse column stacking order on mobile.
   Added via block options toggle on core/columns (see functions-blocks.php). */
@media (max-width: 782px) {
	.wp-block-columns.rg-reverse-order-mobile {
		flex-direction: column-reverse;
	}
}

