/*
Theme Name: Law Firm Starter
Description: Elegant, conversion-focused theme for US law firms. Works with the Law Firm Integrations plugin (CallRail, Smith.ai, Clio). Colors, fonts and homepage copy are set in Appearance → Customize → Law Firm Theme.
Version: 1.1.0
Requires PHP: 7.4
License: GPL-2.0-or-later
Text Domain: lawfirm-starter
*/

:root {
	/* Default palette: navy & brass. Each site overrides these in the Customizer. */
	--lf-ink: #14202f;
	--lf-taupe: #1e3150;
	--lf-cream: #f4eee3;
	--lf-rose: #c29a5b;
	--lf-mist: #f2f4f7;
	--lf-stone: #f7f3ec;
	--lf-night: #0f1b2d;
	--lf-on-rose: #fff;
	--lf-white: #fff;
	--lf-h-weight: 300;   /* heading weight, set per font pairing */
	--lf-h-scale: 1;      /* heading size multiplier, set per font pairing */
	--lf-serif: "Cormorant Garamond", Georgia, serif;
	--lf-sans: "Jost", "Helvetica Neue", Arial, sans-serif;
	--lf-gutter: clamp(20px, 6vw, 120px);
	--lf-section: clamp(72px, 10vw, 140px);
	--lf-max: 1440px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
	margin: 0;
	font-family: var(--lf-sans);
	font-weight: 300;
	font-size: 17px;
	line-height: 1.65;
	color: var(--lf-taupe);
	background: var(--lf-white);
	-webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
p { margin: 0 0 1.1em; }

h1, h2, h3, h4 {
	font-family: var(--lf-serif);
	font-weight: var(--lf-h-weight);
	color: var(--lf-ink);
	margin: 0 0 .4em;
	line-height: 1.1;
}
h1 { font-size: calc(clamp(46px, 6vw, 84px) * var(--lf-h-scale)); line-height: 1.04; }
h2 { font-size: calc(clamp(38px, 4.2vw, 56px) * var(--lf-h-scale)); }
h3 { font-size: calc(clamp(24px, 2.2vw, 30px) * var(--lf-h-scale)); font-weight: 400; line-height: 1.2; }
h1 em, h2 em, h3 em { font-style: italic; color: var(--lf-rose); }

.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(1px,1px,1px,1px); }
.skip-link:focus { position: fixed; top: 8px; left: 8px; z-index: 1000; width: auto; height: auto; clip: auto; padding: 10px 16px; background: var(--lf-white); color: var(--lf-ink); }

.container { width: 100%; max-width: var(--lf-max); margin: 0 auto; padding: 0 var(--lf-gutter); }
.section { padding: var(--lf-section) 0; }
.section--mist { background: var(--lf-mist); }
.section--stone { background: var(--lf-stone); }
.section--taupe { background: var(--lf-taupe); color: var(--lf-cream); }
.section--night { background: var(--lf-night); color: var(--lf-cream); }
.section--taupe h2, .section--night h2 { color: var(--lf-cream); }
.section--taupe h3, .section--night h3 { color: var(--lf-white); }

.eyebrow {
	display: block;
	font-family: var(--lf-sans);
	font-weight: 500;
	font-size: 13px;
	letter-spacing: .18em;
	text-transform: uppercase;
	color: var(--lf-rose);
	margin-bottom: 20px;
}
.lead { font-size: clamp(18px, 1.5vw, 20px); line-height: 1.6; }

/* ---------- Buttons ---------- */
a.btn, .btn, a.lf-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	padding: 18px 32px;
	border-radius: 999px;
	border: 1px solid transparent;
	background: var(--lf-ink);
	color: var(--lf-cream);
	font-family: var(--lf-sans);
	font-weight: 500;
	font-size: 14px;
	line-height: 1;
	letter-spacing: .1em;
	text-transform: uppercase;
	text-decoration: none;
	cursor: pointer;
	transition: background .2s, color .2s, border-color .2s, transform .2s;
}
a.btn::before, .btn::before, a.lf-btn::before {
	content: "";
	width: 6px; height: 6px;
	border-radius: 50%;
	background: var(--lf-rose);
	flex: none;
}
a.btn:hover, .btn:hover, a.lf-btn:hover { transform: translateY(-1px); filter: none; }
a.btn--rose, .btn--rose { background: var(--lf-rose); color: var(--lf-on-rose); }
a.btn--rose::before, .btn--rose::before { background: var(--lf-on-rose); }
a.btn--rose:hover { filter: brightness(1.08); }
a.btn--outline-light { background: transparent; border-color: var(--lf-white); color: var(--lf-white); }
a.btn--outline-light:hover { background: var(--lf-white); color: var(--lf-ink); }
a.btn--outline-dark { background: transparent; border-color: var(--lf-ink); color: var(--lf-ink); }
a.btn--outline-dark:hover { background: var(--lf-ink); color: var(--lf-cream); }
a.btn--block { width: 100%; }
.btn-row { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; margin-top: 12px; }

/* ---------- Header ---------- */
.site-header {
	position: absolute;
	inset: 0 0 auto 0;
	z-index: 50;
	color: var(--lf-white);
	transition: background .3s, padding .3s, box-shadow .3s;
}
.site-header.is-scrolled { position: fixed; background: var(--lf-night); box-shadow: 0 6px 24px rgba(0,0,0,.15); }
.site-header__inner {
	max-width: var(--lf-max);
	margin: 0 auto;
	padding: 28px clamp(20px, 5.5vw, 80px);
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 24px;
}
.site-header.is-scrolled .site-header__inner { padding-top: 14px; padding-bottom: 14px; }
.brand { display: flex; align-items: center; gap: 14px; text-decoration: none; color: var(--lf-white); }
.brand__mark { font-family: var(--lf-serif); font-weight: 300; font-size: 52px; line-height: 1; color: var(--lf-rose); }
.brand__name { display: block; font-size: 20px; font-weight: 400; letter-spacing: .14em; text-transform: uppercase; line-height: 1.2; }
.brand__tag { display: block; font-size: 10px; font-weight: 500; letter-spacing: .18em; text-transform: uppercase; color: var(--lf-cream); }
.custom-logo { max-height: 64px; width: auto; }

.primary-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: clamp(18px, 2.4vw, 36px); }
.primary-nav a { text-decoration: none; font-size: 14px; font-weight: 400; letter-spacing: .08em; text-transform: uppercase; color: var(--lf-white); opacity: .92; }
.primary-nav a:hover, .primary-nav .current-menu-item > a { color: var(--lf-rose); opacity: 1; }
.header-cta .lf-phone { padding: 16px 26px; }
.menu-toggle { display: none; background: none; border: 0; color: var(--lf-white); padding: 6px; cursor: pointer; }

/* ---------- Hero ---------- */
.hero {
	position: relative;
	min-height: max(680px, 100vh);
	max-height: 960px;
	display: flex;
	align-items: flex-end;
	color: var(--lf-white);
	background-color: var(--lf-night);
	background-size: cover;
	background-position: center;
	isolation: isolate;
}
.hero::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	background:
		linear-gradient(90deg, color-mix(in srgb, var(--lf-night) 60%, transparent) 0%, transparent 60%),
		linear-gradient(180deg, color-mix(in srgb, var(--lf-night) 55%, transparent) 0%, color-mix(in srgb, var(--lf-night) 10%, transparent) 40%, color-mix(in srgb, var(--lf-night) 88%, transparent) 100%);
}
.hero--no-image { background-image: linear-gradient(135deg, var(--lf-taupe) 0%, var(--lf-night) 100%); }
.hero__inner {
	width: 100%;
	max-width: var(--lf-max);
	margin: 0 auto;
	padding: 160px clamp(20px, 5.5vw, 80px) 90px;
	display: flex;
	justify-content: space-between;
	align-items: flex-end;
	gap: 48px;
}
.hero__main { max-width: 780px; }
.hero .eyebrow { color: var(--lf-cream); }
.hero h1 { color: var(--lf-cream); margin-bottom: 36px; }
.hero__aside { max-width: 380px; font-size: 17px; color: var(--lf-white); }

.page-hero {
	background: var(--lf-taupe);
	color: var(--lf-cream);
	padding: 200px 0 90px;
}
.page-hero h1 { color: var(--lf-cream); font-size: clamp(42px, 5vw, 68px); margin: 0; }
.page-hero .eyebrow { margin-bottom: 16px; }

/* ---------- Trust bar ---------- */
.trust { background: var(--lf-night); color: var(--lf-cream); }
.trust ul { list-style: none; margin: 0 auto; max-width: var(--lf-max); padding: 28px var(--lf-gutter); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 14px 32px; }
.trust li { font-weight: 500; font-size: 13px; letter-spacing: .18em; text-transform: uppercase; }

/* ---------- Split sections ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(40px, 7vw, 100px); align-items: center; }
.split--reverse .split__media { order: 2; }
.split__media img { width: 100%; aspect-ratio: 7 / 8; object-fit: cover; }
.split__media .ph { aspect-ratio: 7 / 8; background: linear-gradient(135deg, var(--lf-taupe), var(--lf-night)); }
.split__body { max-width: 560px; }
.split__body .lead { margin-bottom: 1em; }
.attorney-name { font-family: var(--lf-serif); font-size: 30px; color: var(--lf-white); margin-bottom: .6em; }

/* ---------- Practice areas ---------- */
.section-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; flex-wrap: wrap; margin-bottom: 64px; }
.section-head h2 { margin: 0; }
.section-head--center { flex-direction: column; align-items: center; text-align: center; }
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.card {
	background: var(--lf-white);
	border: 1px solid var(--lf-cream);
	padding: 40px 36px 36px;
	display: flex;
	flex-direction: column;
	gap: 14px;
	text-decoration: none;
	transition: transform .25s, box-shadow .25s;
}
.card:hover { transform: translateY(-4px); box-shadow: 0 18px 40px color-mix(in srgb, var(--lf-night) 10%, transparent); }
.card__num { font-weight: 500; font-size: 13px; letter-spacing: .18em; color: var(--lf-rose); }
.card h3 { margin: 0; }
.card p { margin: 0; flex: 1; }
.card__link { font-weight: 500; font-size: 14px; letter-spacing: .1em; text-transform: uppercase; color: var(--lf-ink); }

/* ---------- Testimonials ---------- */
.quotes { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.quote { background: var(--lf-white); border-radius: 4px; padding: 40px; margin: 0; display: flex; flex-direction: column; gap: 20px; }
.quote__stars { color: var(--lf-rose); letter-spacing: .15em; }
.quote blockquote { margin: 0; font-family: var(--lf-serif); font-size: clamp(22px, 2vw, 28px); line-height: 1.25; color: var(--lf-ink); }
.quote blockquote p { margin: 0; }
.quote figcaption { font-weight: 500; font-size: 13px; letter-spacing: .18em; text-transform: uppercase; color: var(--lf-taupe); }

/* ---------- Consultation ---------- */
.consult { display: grid; grid-template-columns: 5fr 7fr; gap: clamp(40px, 8vw, 120px); align-items: start; }
.consult__call .eyebrow { color: var(--lf-cream); margin: 32px 0 8px; }
.consult__phone a { font-family: var(--lf-serif); font-size: clamp(38px, 4vw, 56px); color: var(--lf-white); text-decoration: none; }
.consult__form { border: 1px solid var(--lf-taupe); padding: clamp(28px, 4vw, 56px); }
.consult__form iframe { width: 100%; min-height: 640px; border: 0; background: transparent; }
.consult__fallback { color: var(--lf-cream); }
.lf-notice { color: var(--lf-rose); border-color: var(--lf-rose); }

/* ---------- Content pages ---------- */
.content-wrap { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: clamp(40px, 6vw, 96px); }
.entry-content { font-size: 18px; }
.entry-content h2 { font-size: clamp(32px, 3vw, 42px); margin-top: 1.4em; }
.entry-content h3 { margin-top: 1.4em; }
.entry-content a { color: var(--lf-ink); text-decoration-color: var(--lf-rose); text-underline-offset: 3px; }
.entry-content > *:first-child { margin-top: 0; }
.sidebar-cta { background: var(--lf-night); color: var(--lf-cream); padding: 40px 32px; position: sticky; top: 110px; align-self: start; }
.sidebar-cta h3 { color: var(--lf-cream); }
.sidebar-cta .btn-row { flex-direction: column; align-items: stretch; }
.post-list { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
.post-card { text-decoration: none; display: flex; flex-direction: column; gap: 14px; }
.post-card img { aspect-ratio: 3 / 2; object-fit: cover; width: 100%; }
.post-card__meta { font-size: 13px; letter-spacing: .14em; text-transform: uppercase; color: var(--lf-rose); font-weight: 500; }
.pagination { margin-top: 56px; display: flex; gap: 12px; }
.pagination .page-numbers { padding: 8px 14px; border: 1px solid var(--lf-cream); text-decoration: none; }
.pagination .current { background: var(--lf-ink); color: var(--lf-cream); }

/* ---------- Footer ---------- */
.site-footer { background: var(--lf-ink); color: var(--lf-cream); padding: 100px 0 40px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 48px; }
.footer-grid h4 { font-family: var(--lf-sans); font-weight: 500; font-size: 13px; letter-spacing: .18em; text-transform: uppercase; color: var(--lf-rose); margin-bottom: 16px; }
.footer-grid ul { list-style: none; margin: 0; padding: 0; }
.footer-grid li { margin-bottom: 6px; }
.footer-grid a { color: var(--lf-white); text-decoration: none; }
.footer-grid a:hover { color: var(--lf-rose); }
.footer-brand { font-size: 20px; letter-spacing: .14em; text-transform: uppercase; color: var(--lf-white); margin-bottom: 16px; font-weight: 400; }
.footer-bottom { margin-top: 64px; padding-top: 28px; border-top: 1px solid var(--lf-taupe); display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-size: 13px; }
.footer-bottom a { color: var(--lf-cream); text-decoration: none; margin-left: 18px; }

/* Mobile sticky call / book bar */
.mobile-bar { display: none; }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
	.primary-nav ul { gap: 18px; }
	.cards, .quotes, .post-list { grid-template-columns: repeat(2, 1fr); }
	.footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 900px) {
	.menu-toggle { display: block; }
	.header-cta { display: none; }
	.primary-nav {
		position: fixed; inset: 0; z-index: 60;
		background: var(--lf-night);
		display: flex; align-items: center; justify-content: center;
		opacity: 0; visibility: hidden; transition: opacity .25s;
	}
	.primary-nav.is-open { opacity: 1; visibility: visible; }
	.primary-nav ul { flex-direction: column; align-items: center; gap: 26px; }
	.primary-nav a { font-size: 18px; }
	.menu-close { position: absolute; top: 24px; right: 24px; }
	.hero__inner { flex-direction: column; align-items: flex-start; padding-bottom: 120px; }
	.hero__aside { display: none; }
	.split, .consult, .content-wrap { grid-template-columns: 1fr; }
	.split--reverse .split__media { order: 0; }
	.split__media img, .split__media .ph { aspect-ratio: 4 / 4.4; }
	.sidebar-cta { position: static; }
	.trust ul { justify-content: center; text-align: center; }
	.mobile-bar {
		display: flex; gap: 8px;
		position: fixed; inset: auto 0 0 0; z-index: 40;
		padding: 12px; background: var(--lf-white);
		box-shadow: 0 -4px 16px rgba(0,0,0,.15);
	}
	.mobile-bar a.btn { flex: 1; padding: 16px 10px; }
	body { padding-bottom: 72px; }
}
@media (max-width: 640px) {
	.cards, .quotes, .post-list, .footer-grid { grid-template-columns: 1fr; }
	.card { padding: 28px 24px; }
	.brand__mark { font-size: 38px; }
	.brand__name { font-size: 15px; }
	.brand__tag { display: none; }
	.hero .btn-row { flex-direction: column; align-items: stretch; }
	.hero .btn-row a { width: 100%; }
	.page-hero { padding: 150px 0 64px; }
}

/* =====================================================================
   Layout variants (Appearance → Customize → Law Firm Theme → Brand)
   body.lf-layout-classic | -split | -centered | -editorial
   ===================================================================== */

.hero__media { display: none; }
.hero__text { max-width: 560px; font-size: 18px; margin: -12px 0 28px; }
.hero--classic .hero__text { display: none; }
.hero:not(.hero--classic) .hero__aside { display: none; }

/* ---------- Split: color panel left, photo right ---------- */
.lf-layout-split .site-header { background: var(--lf-night); }
.lf-layout-split .site-header__inner { padding-top: 22px; padding-bottom: 22px; }
.hero--split { background: var(--lf-night) !important; min-height: 760px; max-height: none; align-items: stretch; }
.hero--split::before { display: none; }
.hero--split .hero__inner { display: grid; grid-template-columns: 1fr 1fr; gap: 0; padding: 0; max-width: none; align-items: stretch; }
.hero--split .hero__main { max-width: 640px; justify-self: end; padding: 200px clamp(28px, 5vw, 88px) 100px clamp(20px, 5.5vw, 80px); align-self: center; }
.hero--split h1 { font-size: calc(clamp(42px, 5vw, 72px) * var(--lf-h-scale)); }
.hero--split .hero__text { color: var(--lf-cream); opacity: .9; }
.hero--split .hero__media { display: block; position: relative; min-height: 560px; }
.hero--split .hero__media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero--split .hero__media::after { content: ""; position: absolute; left: 0; bottom: 0; width: 120px; height: 6px; background: var(--lf-rose); }
.lf-layout-split .card { border: 0; border-top: 3px solid var(--lf-rose); }

/* ---------- Centered: dramatic photo, centered message ---------- */
.hero--centered { align-items: center; text-align: center; }
.hero--centered::before { background: linear-gradient(180deg, color-mix(in srgb, var(--lf-night) 70%, transparent) 0%, color-mix(in srgb, var(--lf-night) 55%, transparent) 50%, color-mix(in srgb, var(--lf-night) 88%, transparent) 100%); }
.hero--centered .hero__inner { justify-content: center; padding-top: 180px; padding-bottom: 140px; }
.hero--centered .hero__main { max-width: 900px; margin: 0 auto; }
.hero--centered .hero__text { margin-left: auto; margin-right: auto; color: var(--lf-white); }
.hero--centered .btn-row { justify-content: center; }
.hero--centered .eyebrow { color: var(--lf-rose); }
.lf-layout-centered .trust { background: var(--lf-rose); color: var(--lf-on-rose); }
.lf-layout-centered .trust ul { justify-content: center; gap: 14px 0; }
.lf-layout-centered .trust li { padding: 0 28px; }
.lf-layout-centered .trust li + li { border-left: 1px solid color-mix(in srgb, var(--lf-on-rose) 35%, transparent); }
.lf-layout-centered #practice-areas { background: var(--lf-night); }
.lf-layout-centered #practice-areas h2 { color: var(--lf-cream); }
.lf-layout-centered #practice-areas .card { background: transparent; border-color: color-mix(in srgb, var(--lf-cream) 18%, transparent); }
.lf-layout-centered #practice-areas .card h3 { color: var(--lf-white); }
.lf-layout-centered #practice-areas .card p { color: var(--lf-cream); opacity: .8; }
.lf-layout-centered #practice-areas .card__link { color: var(--lf-rose); }
.lf-layout-centered #practice-areas .btn--outline-dark { border-color: var(--lf-cream); color: var(--lf-cream); }
.lf-layout-centered .section-head { flex-direction: column; align-items: center; text-align: center; }

/* ---------- Editorial: light hero, framed photo, numbered list ---------- */
.lf-layout-editorial .site-header:not(.is-scrolled), .lf-layout-editorial .site-header:not(.is-scrolled) .brand { color: var(--lf-ink); }
.lf-layout-editorial .site-header:not(.is-scrolled) .primary-nav a { color: var(--lf-ink); }
.lf-layout-editorial .site-header:not(.is-scrolled) .brand__tag { color: var(--lf-taupe); }
.lf-layout-editorial .site-header:not(.is-scrolled) .menu-toggle { color: var(--lf-ink); }
.hero--editorial { background: var(--lf-stone) !important; color: var(--lf-ink); min-height: 0; max-height: none; align-items: center; }
.hero--editorial::before { display: none; }
.hero--editorial .hero__inner { display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(40px, 6vw, 100px); align-items: center; padding-top: 190px; padding-bottom: 120px; }
.hero--editorial h1 { color: var(--lf-ink); }
.hero--editorial .eyebrow { color: var(--lf-rose); }
.hero--editorial .hero__text { color: var(--lf-taupe); }
.hero--editorial a.btn--outline-light { border-color: var(--lf-ink); color: var(--lf-ink); }
.hero--editorial a.btn--outline-light:hover { background: var(--lf-ink); color: var(--lf-cream); }
.hero--editorial .hero__media { display: block; position: relative; }
.hero--editorial .hero__media::before { content: ""; position: absolute; inset: 28px -28px -28px 28px; border: 1px solid var(--lf-rose); }
.hero--editorial .hero__media img { position: relative; width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
.lf-layout-editorial .trust { background: var(--lf-ink); }
.lf-layout-editorial #practice-areas { background: var(--lf-white); }
.lf-layout-editorial .cards { grid-template-columns: 1fr 1fr; gap: 0 64px; }
.lf-layout-editorial .card { background: none; border: 0; border-top: 1px solid color-mix(in srgb, var(--lf-ink) 15%, transparent); padding: 28px 0; flex-direction: row; flex-wrap: wrap; align-items: baseline; gap: 6px 24px; }
.lf-layout-editorial .card:hover { transform: none; box-shadow: none; }
.lf-layout-editorial .card:hover h3 { color: var(--lf-rose); }
.lf-layout-editorial .card__num { font-family: var(--lf-serif); font-size: 28px; letter-spacing: 0; width: 48px; }
.lf-layout-editorial .card h3 { flex: 1; }
.lf-layout-editorial .card p { flex-basis: 100%; padding-left: 72px; }
.lf-layout-editorial .card__link { display: none; }

@media (max-width: 900px) {
	.hero--split .hero__inner, .hero--editorial .hero__inner { grid-template-columns: 1fr; }
	.hero--split .hero__main { justify-self: stretch; padding: 150px 20px 48px; max-width: none; }
	.hero--split .hero__media { min-height: 320px; }
	.hero--editorial .hero__inner { padding-top: 140px; padding-bottom: 80px; }
	.hero--editorial .hero__media::before { inset: 16px -12px -16px 12px; }
	.hero--centered .hero__inner { padding-bottom: 120px; }
	.hero--centered .hero__inner { align-items: center; }
	.lf-layout-centered .trust li + li { border-left: 0; }
	.lf-layout-editorial .cards { grid-template-columns: 1fr; }
	.lf-layout-editorial .card p { padding-left: 0; }
}
