/*
Theme Name: Pink Door Pros
Description: One-page lead funnel for a garage door insulation business. Quote form saves leads to the dashboard (Leads menu) and emails them to you. Set your business name, phone, prices and lead email in Appearance > Customize > Business Details.
Version: 1.1.0
Requires at least: 6.0
Requires PHP: 7.4
License: GPLv2 or later
Text Domain: noco-door-insulation
*/

/* Layout: contractor lead funnel. Hero = claim + photo on the left, quote form on the right
   (stacks claim, form, photo on phones). Then benefits, door cross-section, pricing,
   process, gallery, FAQ, closing CTA. */
/* Pink Door Pros: blush hero, deep plum header and closer, raspberry-pink calls to action. */
:root {
	--bg: #fdf7f9;
	--surface: #ffffff;
	--ink: #2b1630;
	--muted: #6f5a72;
	--line: #f1dfe7;
	--deep: #3a1538;
	--on-deep: #ffffff;
	--on-deep-muted: #e3c6d6;
	--hero-bg: #fbe3ec;
	--hero-ink: #2b1630;
	--hero-muted: #5e4862;
	--accent: #c92f6b;
	--accent-ink: #ffffff;
	--accent-text: #b0285d;
	--pink-light: #f7b8cf;
	--foam: #f2a9c4;
	--steel: #a99aab;
	--display: "Bricolage Grotesque", "Trebuchet MS", system-ui, sans-serif;
	--body: "DM Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
	--hdr: 64px;
}
@media (prefers-color-scheme: dark) {
	:root:not([data-theme="light"]) {
		--bg: #170c19; --surface: #24142a; --ink: #f7eaf0; --muted: #c3aac0; --line: #3a2440;
		--deep: #0f0711; --on-deep: #ffffff; --on-deep-muted: #c3aac0;
		--hero-bg: #2a1230; --hero-ink: #f7eaf0; --hero-muted: #d2b6cc;
		--accent: #ff6fa3; --accent-ink: #2a0716; --accent-text: #ff8ab4; --pink-light: #ff9cc0;
		--foam: #c7809e; --steel: #7c6c80; color-scheme: dark;
	}
}
:root[data-theme="dark"] {
	--bg: #170c19; --surface: #24142a; --ink: #f7eaf0; --muted: #c3aac0; --line: #3a2440;
	--deep: #0f0711; --on-deep: #ffffff; --on-deep-muted: #c3aac0;
	--hero-bg: #2a1230; --hero-ink: #f7eaf0; --hero-muted: #d2b6cc;
	--accent: #ff6fa3; --accent-ink: #2a0716; --accent-text: #ff8ab4; --pink-light: #ff9cc0;
	--foam: #c7809e; --steel: #7c6c80; color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--body); font-size: 17px; line-height: 1.6; -webkit-font-smoothing: antialiased; }
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 10; background: var(--deep); }
img { max-width: 100%; height: auto; }
a { color: var(--accent-text); }
.wrap {
	max-width: 1140px; margin: 0 auto;
	padding-left: max(20px, env(safe-area-inset-left, 0px));
	padding-right: max(20px, env(safe-area-inset-right, 0px));
}
h1, h2, h3 { font-family: var(--display); line-height: 1.05; margin: 0; text-wrap: balance; letter-spacing: -0.02em; }
h2 { font-size: clamp(2rem, 4.6vw, 3rem); font-weight: 800; }
h3 { font-size: 1.35rem; font-weight: 700; }
p { margin: 0; }
.eyebrow { font-size: .78rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--accent-text); }
section { padding-block: clamp(56px, 8vw, 96px); }
[id] { scroll-margin-top: calc(var(--hdr) + 16px); }
.sec-head { display: grid; gap: 10px; max-width: 640px; margin-bottom: 40px; }
.sec-head p { color: var(--muted); }
.band { background: var(--surface); border-block: 1px solid var(--line); }

/* Header */
.site-header { background: var(--deep); color: var(--on-deep); position: sticky; top: calc(env(safe-area-inset-top, 0px) + var(--wp-admin--admin-bar--height, 0px)); z-index: 5; }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-block: 12px; min-height: var(--hdr); }
.brand { display: flex; align-items: center; gap: 10px; font-family: var(--display); font-weight: 800; font-size: 1.45rem; letter-spacing: -0.02em; line-height: 1.05; color: var(--on-deep); text-decoration: none; min-width: 0; }
.brand svg { width: 26px; height: 34px; flex: none; }
.brand .door { fill: var(--accent); }
.brand .door-line { stroke: var(--deep); stroke-width: 2; }
.hdr-call { display: flex; align-items: baseline; gap: 10px; font-weight: 700; color: var(--on-deep); text-decoration: none; white-space: nowrap; }
.hdr-call small { color: var(--on-deep-muted); font-weight: 500; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 14px 24px; border-radius: 999px; font: 700 1rem/1.2 var(--body); text-decoration: none; border: 2px solid transparent; cursor: pointer; }
.btn-sm { padding: 9px 16px; font-size: .92rem; white-space: nowrap; flex: none; }
.btn-block { width: 100%; }
.btn-primary { background: var(--accent); color: var(--accent-ink); }
.btn-primary:hover { filter: brightness(1.07); }
.btn-ghost { border-color: currentColor; color: var(--ink); background: transparent; }
.btn:focus-visible, a:focus-visible, summary:focus-visible, input:focus-visible, textarea:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }

/* Hero */
.hero { background: var(--hero-bg); color: var(--hero-ink); padding-block: clamp(36px, 6vw, 72px); }
.hero .wrap {
	display: grid; gap: 28px clamp(28px, 4vw, 56px);
	grid-template-columns: 1fr minmax(0, 440px);
	grid-template-areas: "copy form" "photo form";
	align-items: start;
}
.hero-copy { grid-area: copy; display: grid; gap: 20px; min-width: 0; }
.hero h1 { font-size: clamp(2.8rem, 6.4vw, 4.9rem); font-weight: 800; }
.hero h1 em { font-style: normal; color: var(--accent); display: block; }
.hero-copy p { color: var(--hero-muted); font-size: 1.15rem; max-width: 34em; }
.facts { display: flex; flex-wrap: wrap; gap: 8px 22px; font-size: .95rem; color: var(--hero-ink); font-weight: 600; list-style: none; margin: 0; padding: 0; }
.facts li { display: flex; align-items: center; gap: 8px; }
.facts li::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: var(--accent); }
.hero-photo { grid-area: photo; margin: 0; min-width: 0; }
.hero-photo img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 20px; }

/* Quote form */
.form-card { grid-area: form; background: var(--surface); color: var(--ink); border-radius: 22px; padding: clamp(20px, 3vw, 30px); display: grid; gap: 14px; box-shadow: 0 24px 60px rgba(90, 20, 60, .18); min-width: 0; }
.form-card h2 { font-size: 1.85rem; }
.lead-form { display: grid; gap: 16px; }
.trap { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.doors { border: 0; padding: 0; margin: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.doors legend { font-weight: 600; font-size: .92rem; margin-bottom: 8px; padding: 0; }
.opt { position: relative; cursor: pointer; }
.opt input { position: absolute; opacity: 0; inset: 0; }
.opt span { display: grid; gap: 2px; border: 2px solid var(--line); border-radius: 14px; padding: 10px 12px; height: 100%; }
.opt b { font-size: 1rem; }
.opt small { color: var(--muted); font-size: .8rem; }
.opt input:checked + span { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 10%, var(--surface)); }
.opt input:focus-visible + span { outline: 3px solid var(--accent); outline-offset: 2px; }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: .92rem; cursor: pointer; }
.check input { width: 18px; height: 18px; margin-top: 3px; accent-color: var(--accent); flex: none; }
.estimate { display: flex; justify-content: space-between; align-items: baseline; border-block: 1px dashed var(--line); padding-block: 10px; }
.estimate span { font-weight: 600; color: var(--muted); }
.estimate b { font-family: var(--display); font-size: 2.6rem; font-weight: 800; line-height: 1; font-variant-numeric: tabular-nums; }
.fields { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.fields label { display: grid; gap: 5px; align-content: start; font-weight: 600; font-size: .88rem; min-width: 0; }
.fields label small { color: var(--muted); font-weight: 500; }
.fields .wide { grid-column: 1 / -1; }
.fields input, .fields textarea { width: 100%; font: 400 1rem/1.4 var(--body); color: var(--ink); background: var(--bg); border: 1px solid var(--line); border-radius: 12px; padding: 11px 12px; }
.fields textarea { resize: vertical; }
.fine { font-size: .82rem; color: var(--muted); text-align: center; }
.form-error { background: color-mix(in srgb, #d33 14%, var(--surface)); border: 1px solid #d33; border-radius: 8px; padding: 10px 12px; font-size: .92rem; }
.thanks { display: grid; gap: 12px; padding-block: 12px; }
.thanks p { color: var(--muted); }

/* Benefits */
.benefits { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.benefit { display: grid; gap: 8px; align-content: start; padding-top: 18px; border-top: 3px solid var(--accent); }
.benefit p { color: var(--muted); font-size: .98rem; }
.benefit .k { font-family: var(--display); font-weight: 800; font-size: 1rem; letter-spacing: .1em; color: var(--accent-text); text-transform: uppercase; }

/* Cross-section */
.split { display: grid; grid-template-columns: 1fr 1.1fr; gap: clamp(28px, 5vw, 64px); align-items: center; }
.split-copy { display: grid; gap: 18px; min-width: 0; }
.split-copy p { color: var(--muted); }
.spec { display: grid; grid-template-columns: auto 1fr; gap: 6px 18px; font-size: .92rem; border: 1px solid var(--line); border-radius: 16px; padding: 16px 18px; margin: 0; }
.spec dt { color: var(--muted); }
.spec dd { margin: 0; font-weight: 600; }
.diagram { min-width: 0; }
.diagram svg { width: 100%; height: auto; display: block; }
.diagram text { font-family: var(--body); fill: var(--ink); }
.diagram .lbl { font-size: 13px; font-weight: 600; }
.diagram .sub { font-size: 12px; fill: var(--muted); }
.diagram .side { font-family: var(--display); font-size: 16px; font-weight: 700; letter-spacing: .1em; fill: var(--muted); }
.f-steel { fill: var(--steel); }
.f-foam { fill: var(--foam); }
.f-grain line { stroke: var(--surface); stroke-opacity: .4; stroke-width: 1; }
.f-arrow { stroke: var(--muted); stroke-width: 2.5; fill: none; stroke-linecap: round; }
.f-dim { stroke: var(--muted); stroke-width: 1.5; }

/* Pricing */
.prices { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.price { position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 28px; display: grid; gap: 12px; align-content: start; }
.price.main { border: 2px solid var(--accent); }
.price .tag { position: absolute; top: -12px; left: 24px; background: var(--accent); color: var(--accent-ink); font-size: .72rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; padding: 3px 10px; border-radius: 999px; }
.price .amt { font-family: var(--display); font-size: 3.6rem; font-weight: 800; line-height: 1; font-variant-numeric: tabular-nums; }
.price .amt small { font-size: 1.05rem; color: var(--muted); font-weight: 600; margin-left: 6px; }
.price p { color: var(--muted); font-size: .95rem; }
.price ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 6px; font-size: .95rem; }
.price li { padding-left: 22px; position: relative; }
.price li::before { content: ""; position: absolute; left: 2px; top: .5em; width: 10px; height: 6px; border-left: 2px solid var(--accent-text); border-bottom: 2px solid var(--accent-text); transform: rotate(-45deg); }
.price-note { margin: 22px 0 18px; color: var(--muted); }

.promise { background: var(--hero-bg); }
.promises { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.promises div { background: var(--surface); border-radius: 20px; padding: 24px; display: grid; gap: 8px; align-content: start; }
.promises p { color: var(--muted); font-size: .96rem; }
.promises svg { width: 30px; height: 30px; }
.promises .ic { fill: none; stroke: var(--accent); stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }

/* Steps */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; counter-reset: s; list-style: none; margin: 0; padding: 0; }
.steps li { display: grid; gap: 8px; align-content: start; counter-increment: s; }
.steps li::before { content: counter(s); font-family: var(--display); font-weight: 800; font-size: 2.4rem; line-height: 1; color: var(--accent-text); }
.steps p { color: var(--muted); font-size: .96rem; }

/* Gallery */
.gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.gallery figure { margin: 0; min-width: 0; }
.gallery img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 16px; }
.gallery figcaption { font-size: .85rem; color: var(--muted); margin-top: 6px; }

/* FAQ */
.faq { display: grid; gap: 10px; max-width: 780px; }
.faq details { background: var(--bg); border: 1px solid var(--line); border-radius: 16px; padding: 0 20px; }
.faq summary { cursor: pointer; font-weight: 600; padding-block: 16px; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 1.4rem; line-height: 1; color: var(--accent-text); }
.faq details[open] summary::after { content: "\2013"; }
.faq details p { color: var(--muted); padding-bottom: 18px; max-width: 65ch; }

/* Closer */
.closer { background: var(--deep); color: var(--on-deep); text-align: center; }
.closer .wrap { display: grid; gap: 16px; justify-items: center; }
.closer h2 { font-size: clamp(2.4rem, 6vw, 4rem); }
.closer h2 em { font-style: normal; color: var(--pink-light); }
.closer p { color: var(--on-deep-muted); }
.closer-cta { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; margin-top: 8px; }
.closer .btn-ghost { color: var(--on-deep); }

.site-footer { padding-block: 26px; font-size: .85rem; color: var(--muted); }
.site-footer .wrap { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; }

/* Phone: sticky quote bar */
.mobile-bar { display: none; }

@media (max-width: 900px) {
	.hero .wrap { grid-template-columns: 1fr; grid-template-areas: "copy" "form" "photo"; }
	.split { grid-template-columns: 1fr; }
	.benefits, .steps, .promises { grid-template-columns: repeat(2, 1fr); row-gap: 32px; }
	.promises { row-gap: 16px; }
	.prices { grid-template-columns: 1fr; gap: 24px; }
	.gallery { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
	body { padding-bottom: calc(76px + env(safe-area-inset-bottom, 0px)); }
	.hdr-call small { display: none; }
	.brand { font-size: 1.15rem; }
	.benefits, .steps, .promises { grid-template-columns: 1fr; }
	.fields { grid-template-columns: 1fr; }
	.mobile-bar {
		display: flex; gap: 10px; position: fixed; left: 0; right: 0; bottom: 0; z-index: 6;
		background: var(--deep);
		padding: 12px max(16px, env(safe-area-inset-right, 0px)) calc(12px + env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px));
	}
	.mobile-bar .btn { flex: 1; }
	.mobile-bar .btn-ghost { color: var(--on-deep); flex: 0 0 auto; }
}
@media (max-width: 400px) {
	.gallery { grid-template-columns: 1fr; }
	.doors { grid-template-columns: 1fr 1fr; }
}
@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
}
