/*
Theme Name:   North Georgia Repair
Theme URI:    https://northgeorgiarepair.com
Description:  Lead-focused theme for North Georgia Repair. Pairs with the NGR Leads plugin for quote forms and lead tracking.
Version:      1.0.0
Requires at least: 6.0
Requires PHP: 7.4
Author:       North Georgia Repair
Text Domain:  ngr-theme
*/

/* ---------- Tokens ---------- */
:root {
	--forest: #1f4d3a;
	--forest-deep: #143326;
	--ridge: #2f5d73;
	--amber: #b45309;
	--amber-hover: #92400e;
	--amber-light: #fbbf24;
	--paper: #f7f5f0;
	--surface: #ffffff;
	--ink: #1d2a24;
	--muted: #56655d;
	--line: #dde3df;
	--radius: 12px;
	--shadow: 0 1px 2px rgba(20, 51, 38, .06), 0 8px 24px rgba(20, 51, 38, .08);
	--wrap: 1160px;
	--font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
	margin: 0;
	font-family: var(--font);
	font-size: 17px;
	line-height: 1.65;
	color: var(--ink);
	background: var(--paper);
	-webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; }
a { color: var(--forest); text-underline-offset: 2px; }
a:hover { color: var(--amber); }
h1, h2, h3, h4 { line-height: 1.2; letter-spacing: -.01em; margin: 1.6em 0 .5em; color: var(--forest-deep); }
h1 { font-size: clamp(2rem, 4.5vw, 3rem); font-weight: 800; margin-top: 0; }
h2 { font-size: clamp(1.45rem, 2.6vw, 1.9rem); font-weight: 750; }
h3 { font-size: 1.2rem; }
p, ul, ol { margin: 0 0 1.1em; }
li { margin-bottom: .35em; }
:focus-visible { outline: 3px solid var(--amber-light); outline-offset: 2px; }

.wrap { width: min(100% - 2.5rem, var(--wrap)); margin-inline: auto; }
.wrap--narrow { width: min(100% - 2.5rem, 780px); margin-inline: auto; }
.screen-reader-text { position: absolute !important; clip: rect(1px, 1px, 1px, 1px); width: 1px; height: 1px; overflow: hidden; }
.skip-link:focus { clip: auto; width: auto; height: auto; z-index: 1000; top: 8px; left: 8px; padding: 10px 16px; background: #fff; }

/* ---------- Buttons ---------- */
.btn {
	display: inline-flex; align-items: center; gap: .5rem;
	padding: .85rem 1.4rem; border-radius: 10px; border: 2px solid transparent;
	font-weight: 700; font-size: 1rem; text-decoration: none; line-height: 1.2;
	transition: background .15s, color .15s, border-color .15s;
}
.btn--primary { background: var(--amber); color: #fff; }
.btn--primary:hover { background: var(--amber-hover); color: #fff; }
.btn--ghost { border-color: rgba(255,255,255,.55); color: #fff; }
.btn--ghost:hover { background: #fff; color: var(--forest-deep); }
.btn--outline { border-color: var(--forest); color: var(--forest); }
.btn--outline:hover { background: var(--forest); color: #fff; }

/* ---------- Header ---------- */
.topbar { background: var(--forest-deep); color: #d7e5dc; font-size: .875rem; }
.topbar .wrap { display: flex; justify-content: space-between; gap: 1rem; padding: .45rem 0; }
.topbar a { color: #fff; font-weight: 600; text-decoration: none; }

.site-header { background: var(--surface); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 50; }
.site-header .wrap { display: flex; align-items: center; gap: 1.5rem; min-height: 72px; }
.brand { display: flex; align-items: center; gap: .6rem; text-decoration: none; color: var(--forest-deep); margin-right: auto; }
.brand svg { flex: none; }
.brand__name { font-weight: 800; font-size: 1.2rem; letter-spacing: -.01em; line-height: 1.1; }
.brand__name small { display: block; font-weight: 600; font-size: .72rem; color: var(--muted); letter-spacing: .06em; text-transform: uppercase; }
.custom-logo { max-height: 52px; width: auto; }

.nav ul { list-style: none; margin: 0; padding: 0; }
.nav > ul { display: flex; gap: .25rem; }
.nav li { position: relative; margin: 0; }
.nav a { display: block; padding: .6rem .8rem; color: var(--ink); font-weight: 600; text-decoration: none; border-radius: 8px; }
.nav a:hover, .nav .current-menu-item > a, .nav .current-menu-ancestor > a { color: var(--forest); background: #eef3f0; }
.nav .sub-menu {
	position: absolute; top: 100%; left: 0; min-width: 230px; padding: .4rem;
	background: #fff; border: 1px solid var(--line); border-radius: 10px; box-shadow: var(--shadow);
	opacity: 0; visibility: hidden; transform: translateY(6px); transition: .15s;
}
.nav li:hover > .sub-menu, .nav li:focus-within > .sub-menu { opacity: 1; visibility: visible; transform: none; }
.nav .menu-item-has-children > a::after { content: "▾"; font-size: .75em; margin-left: .35em; }
.header-cta { white-space: nowrap; }
.nav-toggle { display: none; background: none; border: 1px solid var(--line); border-radius: 8px; padding: .5rem .7rem; font: inherit; font-weight: 700; cursor: pointer; }

@media (max-width: 960px) {
	.nav-toggle { display: block; }
	.nav { position: absolute; top: 100%; left: 0; right: 0; background: #fff; border-bottom: 1px solid var(--line); display: none; padding: .5rem 1.25rem 1rem; }
	.nav.is-open { display: block; }
	.nav > ul { flex-direction: column; }
	.nav .sub-menu { position: static; opacity: 1; visibility: visible; transform: none; box-shadow: none; border: 0; padding: 0 0 0 1rem; }
	.header-cta { display: none; }
	.topbar__area { display: none; }
}

/* ---------- Hero ---------- */
.hero {
	position: relative; overflow: hidden; color: #e8f0eb;
	background: linear-gradient(160deg, var(--forest-deep) 0%, var(--forest) 55%, var(--ridge) 100%);
	padding: clamp(2.5rem, 6vw, 5rem) 0 clamp(6rem, 10vw, 8rem);
}
.hero__ridge { position: absolute; left: 0; right: 0; bottom: -1px; width: 100%; height: auto; display: block; }
.hero .wrap { position: relative; display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(2rem, 5vw, 4rem); align-items: start; }
.hero h1 { color: #fff; }
.hero__lead { font-size: 1.2rem; max-width: 36ch; color: #d7e5dc; }
.hero__points { list-style: none; padding: 0; margin: 1.5rem 0 2rem; display: grid; gap: .5rem; }
.hero__points li { display: flex; gap: .6rem; align-items: center; font-weight: 600; }
.hero__points li::before { content: ""; width: 1.25rem; height: 1.25rem; border-radius: 50%; background: var(--amber-light) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5 10.5l3 3 7-7' fill='none' stroke='%23143326' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/80% no-repeat; flex: none; }
.hero__actions { display: flex; flex-wrap: wrap; gap: .75rem; }
#quote, #services { scroll-margin-top: 96px; } /* Clear the sticky header when a link jumps here. */
.hero__card { background: #fff; color: var(--ink); border-radius: var(--radius); padding: 1.5rem; box-shadow: 0 20px 50px rgba(0,0,0,.25); }
.hero__card h2 { margin: 0 0 .25rem; font-size: 1.35rem; }
.hero__card > p { color: var(--muted); margin-bottom: 1rem; font-size: .95rem; }
@media (max-width: 960px) { .hero .wrap { grid-template-columns: 1fr; } }

/* ---------- Sections ---------- */
.section { padding: clamp(3rem, 7vw, 5rem) 0; }
.section--white { background: var(--surface); }
.section__head { max-width: 640px; margin-bottom: 2rem; }
.section__head h2 { margin-top: 0; }
.eyebrow { display: inline-block; font-size: .8rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--amber); margin-bottom: .5rem; }

.grid { display: grid; gap: 1.25rem; }
.grid--4 { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.grid--3 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }

.service-card {
	display: flex; flex-direction: column; gap: .5rem; padding: 1.5rem;
	background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
	text-decoration: none; color: var(--ink); transition: transform .15s, box-shadow .15s, border-color .15s;
}
.service-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: #c6d3cb; color: var(--ink); }
.service-card h3 { margin: .5rem 0 0; }
.service-card p { color: var(--muted); margin: 0; flex: 1; }
.service-card .more { color: var(--amber); font-weight: 700; }
.icon { width: 52px; height: 52px; border-radius: 12px; display: grid; place-items: center; background: #eaf2ed; color: var(--forest); }

.steps { counter-reset: step; list-style: none; padding: 0; }
.steps li { counter-increment: step; position: relative; padding: 1.5rem 1.5rem 1.5rem 4.5rem; background: var(--paper); border-radius: var(--radius); margin: 0; }
.steps li::before { content: counter(step); position: absolute; left: 1.25rem; top: 1.35rem; width: 2.25rem; height: 2.25rem; border-radius: 50%; background: var(--forest); color: #fff; display: grid; place-items: center; font-weight: 800; }
.steps strong { display: block; font-size: 1.1rem; color: var(--forest-deep); }

.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 5vw, 4rem); align-items: center; }
@media (max-width: 860px) { .split { grid-template-columns: 1fr; } }

.chips { display: flex; flex-wrap: wrap; gap: .5rem; list-style: none; padding: 0; }
.chips li { margin: 0; padding: .4rem .85rem; border-radius: 99px; background: #fff; border: 1px solid var(--line); font-weight: 600; font-size: .92rem; }
.county { margin-bottom: 1.25rem; }
.county h3 { margin: 0 0 .5rem; font-size: 1rem; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }

/* ---------- Cards (posts / guides) ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; }
.card__img img { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.card__body { padding: 1.25rem 1.4rem 1.5rem; display: flex; flex-direction: column; gap: .5rem; flex: 1; }
.card__meta { font-size: .82rem; color: var(--muted); font-weight: 600; text-transform: uppercase; letter-spacing: .05em; }
.card h3 { margin: 0; font-size: 1.15rem; }
.card h3 a { text-decoration: none; color: var(--forest-deep); }
.card h3 a:hover { color: var(--amber); }
.card p { color: var(--muted); margin: 0; flex: 1; }

/* ---------- CTA band ---------- */
.cta-band { background: var(--forest); color: #e8f0eb; border-radius: var(--radius); padding: clamp(2rem, 5vw, 3rem); display: flex; flex-wrap: wrap; gap: 1.5rem; align-items: center; justify-content: space-between; }
.cta-band h2 { color: #fff; margin: 0 0 .25rem; }
.cta-band p { margin: 0; }

/* ---------- Page / post ---------- */
.page-head { background: linear-gradient(160deg, var(--forest-deep), var(--forest)); color: #d7e5dc; padding: clamp(2.5rem, 6vw, 4rem) 0; }
.page-head h1 { color: #fff; margin: 0; }
.page-head p { margin: .75rem 0 0; max-width: 60ch; font-size: 1.1rem; }
.crumbs { font-size: .88rem; margin-bottom: .75rem; }
.crumbs a { color: #fff; }
.content { padding: clamp(2rem, 5vw, 3.5rem) 0; }
.entry > *:first-child { margin-top: 0; }
.entry h2 a { text-decoration: none; }
.entry .ngr-form-wrap { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(1.25rem, 3vw, 2rem); margin: 1.5rem 0 2rem; box-shadow: var(--shadow); }
.entry blockquote { margin: 1.5rem 0; padding: 1rem 1.25rem; border-left: 4px solid var(--amber); background: #fff; }
.entry-meta { color: #d7e5dc; font-size: .95rem; margin-top: .75rem; }
.aside-cta { margin-top: 2.5rem; padding: 1.5rem; border-radius: var(--radius); background: #fff7ed; border: 1px solid #fed7aa; }
.aside-cta h2 { margin-top: 0; font-size: 1.3rem; }

.pagination { display: flex; gap: .5rem; justify-content: center; margin-top: 2.5rem; }
.pagination .page-numbers { padding: .5rem .9rem; border-radius: 8px; background: #fff; border: 1px solid var(--line); text-decoration: none; }
.pagination .current { background: var(--forest); color: #fff; border-color: var(--forest); }

/* Forms from the NGR Leads plugin pick up the theme colours. */
.ngr-form-wrap { --ngr-accent: var(--amber); --ngr-ink: var(--ink); --ngr-muted: var(--muted); --ngr-line: #cfd8d3; --ngr-radius: 10px; }
.hero__card .ngr-form-wrap { box-shadow: none; border: 0; padding: 0; margin: 0; }
.hero__card .ngr-submit { width: 100%; }

/* ---------- Footer ---------- */
.site-footer { background: var(--forest-deep); color: #b9cbbf; margin-top: 0; font-size: .95rem; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { color: var(--amber-light); }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 2rem; padding: 3.5rem 0 2.5rem; }
.footer-grid h2 { color: #fff; font-size: 1rem; text-transform: uppercase; letter-spacing: .08em; margin: 0 0 1rem; }
.footer-grid ul { list-style: none; padding: 0; margin: 0; }
.footer-brand p { max-width: 34ch; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.12); padding: 1.25rem 0 2rem; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem; font-size: .85rem; }
.footer-bottom ul { display: flex; flex-wrap: wrap; gap: 1.25rem; list-style: none; padding: 0; margin: 0; }
.footer-bottom li { margin: 0; }
.disclosure { max-width: 70ch; }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 540px) { .footer-grid { grid-template-columns: 1fr; } }

/* Mobile sticky call/quote bar */
.mobile-bar { display: none; }
@media (max-width: 700px) {
	.mobile-bar { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; position: fixed; bottom: 0; left: 0; right: 0; z-index: 60; box-shadow: 0 -4px 16px rgba(0,0,0,.12); }
	.mobile-bar a { padding: .95rem; text-align: center; font-weight: 800; text-decoration: none; color: #fff; background: var(--amber); }
	.mobile-bar a.call { background: var(--forest); }
	body { padding-bottom: 56px; }
}
