/*
Theme Name: Residential Siding Direct
Theme URI: https://residentialsidingdirect.com
Author: Residential Siding Direct
Author URI: https://residentialsidingdirect.com
Description: Pay-per-call landing page theme for residential siding lead generation. Connects homeowners with independent siding contractors. Set your tracking number, form action, and privacy email under Appearance > Customize > Residential Siding Direct.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: residential-siding-direct
*/

/* Residential Siding Direct — shared styles */

:root {
  --color-primary: #163a5f;
  --color-primary-dark: #0e2740;
  --color-primary-light: #21507f;
  --color-accent: #e8792e;
  --color-accent-dark: #c9631f;
  --color-bg: #f6f7f9;
  --color-surface: #ffffff;
  --color-text: #1f2937;
  --color-muted: #5b6472;
  --color-border: #e2e5ea;
  --color-success: #2f7a4d;
  --max-width: 1140px;
  --radius: 10px;
  --shadow: 0 8px 24px rgba(15, 35, 60, 0.08);
  font-size: 16px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "Segoe UI", Roboto, -apple-system, BlinkMacSystemFont, Arial, sans-serif;
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.55;
  padding-bottom: 74px; /* space for mobile sticky call bar */
}

img { max-width: 100%; display: block; }

a { color: inherit; }

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
}

h1, h2, h3 { line-height: 1.2; margin: 0 0 14px; color: var(--color-primary-dark); }
h1 { font-size: 1.9rem; }
h2 { font-size: 1.6rem; }
h3 { font-size: 1.15rem; }
p { margin: 0 0 14px; }

section { padding: 48px 0; }

/* ---------- Ad label ---------- */
.ad-banner {
  background: #fdf1e7;
  color: #7a4a1a;
  text-align: center;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 6px 10px;
  border-bottom: 1px solid #f0d9bd;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--color-primary-dark);
  color: #fff;
  box-shadow: 0 2px 10px rgba(0,0,0,0.15);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-top: 10px;
  padding-bottom: 10px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 800;
  font-size: 1.05rem;
  color: #fff;
  text-decoration: none;
  white-space: nowrap;
}

.logo svg { flex-shrink: 0; }

.header-cta {
  display: flex;
  align-items: center;
  gap: 10px;
}

.header-phone {
  display: none;
  color: #fff;
  font-weight: 700;
  text-decoration: none;
  font-size: 1.05rem;
  white-space: nowrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: none;
  border-radius: 999px;
  padding: 12px 22px;
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.15s ease, transform 0.1s ease;
}

.btn-call {
  background: var(--color-accent);
  color: #fff;
}
.btn-call:hover { background: var(--color-accent-dark); }
.btn-call:active { transform: scale(0.98); }

.btn-header-call {
  padding: 9px 16px;
  font-size: 0.85rem;
}

.btn-outline {
  background: transparent;
  border: 2px solid var(--color-primary);
  color: var(--color-primary);
}

.btn-large {
  padding: 16px 30px;
  font-size: 1.15rem;
}

.btn-block { width: 100%; }

/* ---------- Hero ---------- */
.hero {
  background:
    linear-gradient(160deg, rgba(22,58,95,0.68) 0%, rgba(14,39,64,0.72) 100%),
    url("assets/photos/home-hero.jpg") center 40% / cover no-repeat;
  color: #fff;
  padding: 44px 0 40px;
  position: relative;
  overflow: hidden;
}

.hero-inner {
  position: relative;
  z-index: 1;
  text-align: center;
}

.hero .eyebrow {
  display: inline-block;
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.25);
  color: #fff;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 16px;
}

.hero h1 { color: #fff; font-size: 2rem; margin-bottom: 10px; }
.hero .subhead { color: #dbe6f0; font-size: 1.05rem; max-width: 560px; margin: 0 auto 26px; }

.hero-cta-block { display: flex; flex-direction: column; align-items: center; gap: 10px; }

.consent-text {
  font-size: 0.74rem;
  color: var(--color-muted);
  max-width: 640px;
  margin: 8px auto 0;
  line-height: 1.5;
}
.hero .consent-text { color: #c3d2e0; margin-left: auto; margin-right: auto; }

.trust-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px 22px;
  margin-top: 26px;
  font-size: 0.85rem;
  color: #cfdcea;
}
.trust-row span { display: flex; align-items: center; gap: 6px; }

/* ---------- Feature / icon grid ---------- */
.feature-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 22px;
  margin-top: 10px;
}

.feature-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 22px;
  text-align: center;
  box-shadow: var(--shadow);
}

.feature-card .icon {
  width: 54px;
  height: 54px;
  margin: 0 auto 14px;
  color: var(--color-accent);
}

/* ---------- Services ---------- */
.service-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
}

.service-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 22px;
}

.service-card .icon {
  width: 40px;
  height: 40px;
  color: var(--color-primary);
  margin-bottom: 12px;
}

/* ---------- Photo feature ---------- */
.photo-feature {
  display: grid;
  grid-template-columns: 1fr;
  gap: 26px;
  align-items: center;
}
.photo-feature-img img {
  width: 100%;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  object-fit: cover;
}
.photo-feature-text .btn { margin-top: 6px; }

@media (min-width: 860px) {
  .photo-feature { grid-template-columns: 1fr 1fr; gap: 44px; }
}

/* ---------- Section variants ---------- */
.section-alt { background: var(--color-surface); }
.section-dark {
  background: var(--color-primary-dark);
  color: #e8edf2;
}
.section-dark h2 { color: #fff; }
.section-dark .section-lead { color: #b9c8d6; }

.section-header { text-align: center; max-width: 640px; margin: 0 auto 30px; }
.section-lead { color: var(--color-muted); }

/* ---------- Process steps ---------- */
.steps-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  counter-reset: step;
}

.step-item {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: var(--radius);
  padding: 20px;
  position: relative;
}

.section-dark .step-item { background: rgba(255,255,255,0.05); }
.section-alt .step-item, body:not(.dark) .step-item {
  background: var(--color-surface);
  border-color: var(--color-border);
}
/* White cards sit inside a dark section — force readable dark text */
.step-item h3 { color: var(--color-primary-dark); }
.step-item p { color: var(--color-text); }

.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--color-accent);
  color: #fff;
  font-weight: 800;
  margin-bottom: 12px;
}

/* ---------- Siding types ---------- */
.type-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
}
.type-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.type-card img {
  width: 100%;
  height: 180px;
  object-fit: cover;
}
.type-card-body { padding: 18px 20px 22px; }

/* ---------- Before/After gallery ---------- */
.gallery-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 22px;
}
.project-card {
  margin: 0;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.ba-pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2px;
}
.ba-img { position: relative; }
.ba-img img {
  width: 100%;
  height: 190px;
  object-fit: cover;
}
.ba-tag {
  position: absolute;
  top: 10px;
  left: 10px;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #fff;
  padding: 4px 10px;
  border-radius: 999px;
}
.ba-tag-before { background: rgba(31,41,55,0.85); }
.ba-tag-after { background: var(--color-accent); }
.project-card figcaption {
  padding: 14px 18px;
  font-weight: 600;
  color: var(--color-primary-dark);
  font-size: 0.95rem;
}

@media (min-width: 640px) {
  .gallery-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ---------- CTA banner ---------- */
.cta-banner {
  background: var(--color-accent);
  color: #fff;
  text-align: center;
  border-radius: var(--radius);
  padding: 32px 20px;
}
.cta-banner h2, .cta-banner p { color: #fff; }
.cta-banner .btn-call { background: #fff; color: var(--color-accent-dark); }
.cta-banner .btn-call:hover { background: #f2f2f2; }
.cta-banner .consent-text { color: rgba(255,255,255,0.85); }

.cta-inline { text-align: center; padding: 34px 0; }

/* ---------- FAQ ---------- */
.faq-list { max-width: 760px; margin: 0 auto; }
.faq-item {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  margin-bottom: 12px;
  overflow: hidden;
}
.faq-question {
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  padding: 16px 20px;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  color: var(--color-primary-dark);
}
.faq-question .chevron { transition: transform 0.2s ease; flex-shrink: 0; }
.faq-item.open .faq-question .chevron { transform: rotate(180deg); }
.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.25s ease;
  padding: 0 20px;
}
.faq-item.open .faq-answer { max-height: 400px; padding-bottom: 16px; }
.faq-answer p { color: var(--color-muted); margin: 0; }

/* ---------- Qualifier form ---------- */
.form-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 26px 22px;
  max-width: 560px;
  margin: 0 auto;
}
.form-row { margin-bottom: 16px; }
.form-row label {
  display: block;
  font-weight: 700;
  font-size: 0.9rem;
  margin-bottom: 6px;
  color: var(--color-primary-dark);
}
.form-row input[type="text"],
.form-row input[type="tel"] {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  font-size: 1rem;
  font-family: inherit;
}
.radio-group { display: flex; gap: 18px; }
.radio-group label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 500;
  font-size: 0.95rem;
}
.radio-group input { width: 18px; height: 18px; }

.consent-row {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin-bottom: 18px;
}
.consent-row input[type="checkbox"] {
  margin-top: 4px;
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}
.consent-row label { font-size: 0.78rem; color: var(--color-muted); line-height: 1.5; }

.form-message {
  display: none;
  margin-top: 14px;
  padding: 12px 14px;
  border-radius: 8px;
  font-size: 0.9rem;
}
.form-message.success {
  display: block;
  background: #e9f6ee;
  color: var(--color-success);
  border: 1px solid #cdeadb;
}
.form-message.blocked {
  display: block;
  background: #fdecec;
  color: #a4302a;
  border: 1px solid #f6cccb;
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--color-primary-dark);
  color: #b9c8d6;
  padding: 40px 0 90px;
  font-size: 0.88rem;
}
.site-footer a { color: #dbe6f0; text-decoration: underline; }
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 18px;
}
.footer-disclosure {
  border-top: 1px solid rgba(255,255,255,0.12);
  padding-top: 18px;
  margin-top: 18px;
  color: #93a4b5;
  font-size: 0.78rem;
  line-height: 1.6;
}

/* ---------- Floating sticky call button (desktop) ---------- */
.sticky-cta {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 45;
  display: none;
  align-items: center;
  gap: 9px;
  background: var(--color-accent);
  color: #fff;
  font-weight: 800;
  font-size: 1.05rem;
  padding: 15px 26px;
  border-radius: 999px;
  text-decoration: none;
  box-shadow: 0 10px 28px rgba(0,0,0,0.28);
  transition: background 0.15s ease, transform 0.12s ease, box-shadow 0.15s ease;
}
.sticky-cta:hover {
  background: var(--color-accent-dark);
  transform: translateY(-2px);
  box-shadow: 0 14px 32px rgba(0,0,0,0.34);
}

/* ---------- Sticky mobile call bar ---------- */
.mobile-call-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 50;
  background: var(--color-accent);
  padding: 10px 16px;
  box-shadow: 0 -4px 14px rgba(0,0,0,0.18);
}
.mobile-call-bar a {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: #fff;
  font-weight: 800;
  font-size: 1.05rem;
  text-decoration: none;
}

/* ---------- Simple pages (privacy / disclaimer) ---------- */
.legal-content { background: var(--color-surface); padding: 34px 24px; border-radius: var(--radius); border: 1px solid var(--color-border); margin: 26px auto; max-width: 820px; }
.legal-content h2 { margin-top: 28px; }
.legal-content h2:first-child { margin-top: 0; }
.legal-content ul { padding-left: 20px; }
.legal-content li { margin-bottom: 8px; }
.updated-date { color: var(--color-muted); font-size: 0.85rem; margin-bottom: 24px; }

/* ---------- Responsive ---------- */
@media (min-width: 640px) {
  .feature-grid { grid-template-columns: repeat(3, 1fr); }
  .service-grid { grid-template-columns: repeat(2, 1fr); }
  .type-grid { grid-template-columns: repeat(2, 1fr); }
  .steps-list { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 860px) {
  body { padding-bottom: 0; }
  .mobile-call-bar { display: none; }
  .sticky-cta { display: inline-flex; }
  .header-phone { display: inline-block; }
  h1 { font-size: 2.5rem; }
  .hero { padding: 64px 0 56px; }
  .hero h1 { font-size: 2.7rem; }
  .hero .subhead { font-size: 1.15rem; }
  .service-grid { grid-template-columns: repeat(2, 1fr); }
  .steps-list { grid-template-columns: repeat(4, 1fr); }
  section { padding: 68px 0; }
}
