/*
Theme Name: B2B SEO Services
Theme URI: https://b2b-seoservices.com/
Author: B2B SEO Services
Description: Lightweight, editable theme for the B2B SEO Services website. Server-rendered, no page builder.
Version: 1.2.0
Requires at least: 6.4
Tested up to: 6.8
Requires PHP: 7.4
Text Domain: b2b-seo
*/

:root {
  --ink: #17231e;
  --ink-soft: #3e4d46;
  --muted: #5e6b64;
  --paper: #f3efe6;
  --paper-2: #e8e2d6;
  --white: #fbfaf7;
  --line: #d8d1c4;
  --green: #1c4636;
  --green-deep: #10291f;
  --copper: #b85a2a;
  --copper-deep: #8a3e16;
  --shadow: 0 18px 50px rgba(23, 35, 30, 0.08);
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Times New Roman", serif;
  --sans: "Avenir Next", "Segoe UI", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --mono: "IBM Plex Mono", "SFMono-Regular", ui-monospace, Menlo, Consolas, monospace;
  --max: 1120px;
  --radius: 18px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.05rem;
  line-height: 1.6;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; height: auto; }
a { color: var(--green); text-underline-offset: 0.18em; }
a:hover { color: var(--copper-deep); }
:focus-visible {
  outline: 2px solid var(--copper);
  outline-offset: 3px;
}
.skip {
  position: absolute;
  left: 1rem;
  top: -4rem;
  background: var(--ink);
  color: white;
  padding: 0.6rem 0.9rem;
  z-index: 20;
}
.screen-reader-text {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.wrap { width: min(var(--max), calc(100% - 2rem)); margin-inline: auto; }
.wrap-narrow { width: min(760px, calc(100% - 2rem)); margin-inline: auto; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(243, 239, 230, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 76px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--ink);
  text-decoration: none;
  font-weight: 650;
  letter-spacing: -0.02em;
}
.mark {
  width: 36px;
  height: 36px;
  flex: none;
}
.brand small {
  display: block;
  font-family: var(--mono);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
.nav-toggle { position: relative; }
.nav-toggle > summary {
  list-style: none;
  cursor: pointer;
  border: 1px solid var(--line);
  background: var(--white);
  border-radius: 999px;
  padding: 0.45rem 0.8rem;
  font-size: 0.92rem;
}
.nav-toggle > summary::-webkit-details-marker { display: none; }
.primary-menu,
.footer-menu {
  list-style: none;
  margin: 0;
  padding: 0;
}
.primary-menu a,
.footer-menu a { text-decoration: none; color: var(--ink); }
.primary-menu a:hover,
.footer-menu a:hover { color: var(--copper-deep); }
.header-cta { display: none; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  min-height: 46px;
  padding: 0.7rem 1.05rem;
  border-radius: 999px;
  border: 1px solid transparent;
  text-decoration: none;
  font-weight: 650;
  letter-spacing: -0.01em;
  cursor: pointer;
}
.btn-primary { background: var(--copper); color: #fffaf6; }
.btn-primary:hover { background: var(--copper-deep); color: white; }
.btn-ghost { background: transparent; border-color: var(--line); color: var(--ink); }
.btn-ghost:hover { border-color: var(--ink); color: var(--ink); }
button.btn { font: inherit; }

.hero { padding: 3.2rem 0 1rem; }
.kicker {
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--copper-deep);
  margin: 0 0 0.8rem;
}
h1, h2, h3, h4 {
  font-family: var(--serif);
  font-weight: 560;
  letter-spacing: -0.03em;
  line-height: 1.08;
  color: var(--green-deep);
}
h1 { font-size: clamp(2.4rem, 5vw, 4.5rem); margin: 0 0 1rem; }
h2 { font-size: clamp(1.8rem, 3vw, 2.6rem); margin: 0 0 0.8rem; }
h3 { font-size: 1.35rem; margin: 0 0 0.4rem; }
.lede { font-size: 1.18rem; color: var(--ink-soft); max-width: 42rem; }
.hero-grid {
  display: grid;
  gap: 1.5rem;
}
.brief {
  background: var(--green-deep);
  color: #f6f1e6;
  border-radius: 24px;
  padding: 1.3rem 1.3rem 1.15rem;
  box-shadow: var(--shadow);
}
.brief h2 { color: #f6f1e6; font-size: 1.7rem; }
.brief p { color: #e4dccb; }
.brief ol { margin: 0.4rem 0 1rem; padding-left: 1.15rem; }
.brief a.btn-primary { background: #f3efe6; color: var(--green-deep); }
.brief a.btn-primary:hover { background: white; }

.fit {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding: 0.4rem 0 1.4rem;
}
.fit span, .tag {
  border: 1px solid var(--line);
  background: var(--white);
  border-radius: 999px;
  padding: 0.35rem 0.7rem;
  font-size: 0.86rem;
  color: var(--ink-soft);
}

.section { padding: 2.4rem 0; }
.section-head { max-width: 40rem; margin-bottom: 1.3rem; }
.grid-3, .grid-2 { display: grid; gap: 0.9rem; }
.card, .step, .standard, .post-card, .result-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.1rem 1.15rem 1rem;
}
.card p, .step p, .standard p { margin: 0.35rem 0 0.7rem; color: var(--ink-soft); }
.num {
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  color: var(--copper-deep);
}
.card a.more { font-weight: 650; text-decoration: none; }

.split { display: grid; gap: 0.9rem; }
.standard.no { background: #f7f3ec; }
.standard.yes { background: #f7faf7; }

.faq details {
  border-top: 1px solid var(--line);
  padding: 0.85rem 0;
}
.faq details:last-child { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; font-weight: 680; color: var(--green-deep); }
.faq p { margin: 0.55rem 0 0.2rem; color: var(--ink-soft); }

.cta-band {
  margin: 1rem 0 3rem;
  background: var(--green);
  color: #f6f1e6;
  border-radius: 28px;
  padding: 1.6rem;
}
.cta-band h2 { color: #f6f1e6; }
.cta-band p { color: #e5dccb; max-width: 38rem; }
.cta-actions { display: flex; flex-wrap: wrap; gap: 0.6rem; }

.page-hero { padding: 2.4rem 0 0.4rem; }
.crumbs { font-size: 0.88rem; color: var(--muted); margin-bottom: 0.8rem; }
.crumbs a { color: var(--muted); text-decoration: none; }
.entry-content { padding-bottom: 1rem; }
.entry-content > * { max-width: 740px; }
.entry-content > .wide,
.entry-content > .grid-3,
.entry-content > .grid-2,
.entry-content > .stat-row,
.entry-content > .table-wrap,
.entry-content > .cta-band { max-width: none; }
.entry-content h2 { margin-top: 1.8rem; }
.entry-content ul, .entry-content ol { color: var(--ink-soft); }
.entry-content li { margin: 0.3rem 0; }
.prose-wide .entry-content > * { max-width: none; }

.contact-grid { display: grid; gap: 1rem; align-items: start; }
.contact-grid .form { margin: 0; }
.form select { appearance: auto; }

.page-cta {
  margin: 0.5rem 0 3rem;
  padding: 1.2rem;
  border-radius: var(--radius);
  background: var(--white);
  border: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem 1.2rem;
  align-items: center;
  justify-content: space-between;
}

.form {
  display: grid;
  gap: 0.8rem;
  max-width: 680px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 1.1rem;
  margin: 1rem 0 2.5rem;
}
.form label { display: grid; gap: 0.3rem; font-weight: 650; font-size: 0.95rem; }
.form input, .form select, .form textarea {
  width: 100%;
  border: 1px solid var(--line);
  background: var(--paper);
  border-radius: 12px;
  padding: 0.75rem 0.8rem;
  font: inherit;
  color: var(--ink);
}
.hp { position: absolute; left: -9999px; height: 0; overflow: hidden; }
.notice {
  border-radius: 14px;
  padding: 0.8rem 1rem;
  background: #e7f2ea;
  border: 1px solid #b7d4c2;
}
.notice.err { background: #fdeee6; border-color: #f0c2ad; }

.post-list, .search-list { display: grid; gap: 0.8rem; padding-bottom: 3rem; }
.post-card h2 { font-size: 1.6rem; }
.post-card h2 a { color: inherit; text-decoration: none; }
.meta { color: var(--muted); font-size: 0.88rem; }

.site-footer {
  border-top: 1px solid var(--line);
  background: #ebe6dc;
  padding: 2rem 0 1.4rem;
}
.footer-grid { display: grid; gap: 1.2rem; }
.footer-menu { display: grid; gap: 0.35rem; }
.legal { color: var(--muted); font-size: 0.86rem; margin-top: 1.2rem; }

.search-form { display: flex; gap: 0.4rem; }
.search-form input {
  flex: 1;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.65rem 0.9rem;
  font: inherit;
  background: var(--white);
}

@media (min-width: 760px) {
  .header-inner { display: grid; grid-template-columns: auto 1fr auto; align-items: center; }
  .nav-toggle { display: flex; justify-content: flex-end; }
  .nav-toggle > summary { display: none; }
  .nav-toggle:not([open]) > .primary-menu,
  .nav-toggle .primary-menu { display: flex !important; gap: 1.1rem; align-items: center; }
  .header-cta { display: inline-flex; }
  .hero-grid { grid-template-columns: 1.35fr 0.85fr; align-items: stretch; }
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
  .grid-2, .split { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: 1.3fr 1fr 1fr; }
  .contact-grid { grid-template-columns: 0.8fr 1.2fr; }
  .hero { padding-top: 3.4rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

.stat-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0.8rem; margin: 1rem 0 1.2rem; }
.stat { background: var(--green-deep); color: #f6f1e6; border-radius: 20px; padding: 1rem 1.05rem; }
.stat b { display: block; font-family: var(--serif); font-size: 1.8rem; line-height: 1; }
.stat span { display: block; color: #d9d0c2; font-size: 0.86rem; margin-top: 0.35rem; }
.table-wrap { overflow-x: auto; background: var(--white); border: 1px solid var(--line); border-radius: 20px; margin: 1rem 0; }
table.data { width: 100%; border-collapse: collapse; font-size: 0.95rem; }
table.data th, table.data td { text-align: left; padding: 0.7rem 0.85rem; border-bottom: 1px solid var(--line); vertical-align: top; }
table.data th { font-size: 0.72rem; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); }
.source, .meta a { color: var(--muted); }
.group-label { font-family: var(--mono); font-size: 0.75rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--copper-deep); margin-bottom: 0.2rem; }
.footer-menu { list-style: none; padding: 0; margin: 0; }
.footer-menu li { margin: 0.28rem 0; }
@media (min-width: 760px) {
  .stat-row { grid-template-columns: repeat(4, 1fr); }
}
