/* =========================================================================
   Pines Energy Group LLC — site stylesheet
   -------------------------------------------------------------------------
   Colors live in the variables below. Division pages add one class to
   <body> to swap the accent color:

     (no class)            Pines Energy Group   red, white, navy
     body.theme-usa        Pines USA            red, white, navy
     body.theme-solutions  Pines Solutions      pine green, white, navy
   ========================================================================= */

@import url('https://fonts.googleapis.com/css2?family=Jost:wght@400;500;600&family=Source+Sans+3:wght@400;600&display=swap');

:root {
  --navy:        #0b1b33;
  --navy-2:      #132744;
  --navy-3:      #1c355a;
  --line-dark:   rgba(255, 255, 255, 0.14);
  --on-dark:     #c6d0df;

  --accent:       #c0152f;
  --accent-dark:  #9c0f25;
  --accent-light: #f07386;   /* accent for small text on navy */

  --green:       #1f6b42;
  --green-deep:  #133f28;

  --ink:    #0f1a2b;
  --text:   #3a4557;
  --muted:  #6b7587;
  --line:   #dfe4eb;
  --bg:     #ffffff;
  --bg-alt: #f3f5f8;

  --font-head: 'Jost', 'Futura', 'Century Gothic', Arial, sans-serif;
  --font-body: 'Source Sans 3', 'Segoe UI', Arial, sans-serif;

  --container: 1200px;
  --header-h:  76px;
  --radius:    4px;
}

body.theme-solutions {
  --accent:       #1f6b42;
  --accent-dark:  #17532f;
  --accent-light: #86d0a3;
}

/* ---- BASE ---- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }

html { font-size: 16px; scroll-padding-top: calc(var(--header-h) + 16px); }

body {
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

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

a { color: var(--accent); text-underline-offset: 3px; }
a:hover { color: var(--accent-dark); }

h1, h2, h3, h4 {
  font-family: var(--font-head);
  font-weight: 500;
  color: var(--ink);
  line-height: 1.2;
}
h1 { font-size: clamp(2.2rem, 4.4vw, 3.4rem); letter-spacing: -0.01em; }
h2 { font-size: clamp(1.6rem, 2.6vw, 2.15rem); margin-bottom: 14px; }
h3 { font-size: 1.25rem; font-weight: 500; margin-bottom: 8px; }
h4 { font-size: 1.05rem; font-weight: 600; margin-bottom: 4px; }

p + p { margin-top: 14px; }
strong { color: var(--ink); font-weight: 600; }

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

.eyebrow {
  display: block;
  font-family: var(--font-head);
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 12px;
}

.lead { font-size: 1.2rem; line-height: 1.6; }
.muted { color: var(--muted); }

/* ---- ACCESSIBILITY ---- */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 2000;
  background: var(--accent);
  color: #fff;
  padding: 12px 20px;
  font-weight: 600;
  text-decoration: none;
}
.skip-link:focus { left: 0; color: #fff; }

a:focus-visible,
button:focus-visible,
summary:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}
.dark a:focus-visible,
.site-footer a:focus-visible { outline-color: #ffffff; }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* ---- BUTTONS & LINKS ---- */
.btn {
  display: inline-block;
  font-family: var(--font-head);
  font-size: 1rem;
  font-weight: 500;
  text-decoration: none;
  padding: 12px 26px;
  border: 1.5px solid transparent;
  border-radius: var(--radius);
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-dark); color: #fff; }
.btn-outline { border-color: var(--ink); color: var(--ink); }
.btn-outline:hover { background: var(--ink); color: #fff; }
.btn-light { border-color: rgba(255, 255, 255, 0.6); color: #fff; }
.btn-light:hover { background: #fff; border-color: #fff; color: var(--navy); }

.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }

.more {
  display: inline-block;
  margin-top: 18px;
  font-family: var(--font-head);
  font-weight: 500;
  color: var(--accent);
  text-decoration: none;
}
.more::after { content: ' \2192'; }
.more:hover { text-decoration: underline; }

/* ---- HEADER ---- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: #ffffff;
  border-top: 4px solid var(--accent);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-h);
}
.wordmark {
  font-family: var(--font-head);
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--navy);
  text-decoration: none;
}
.wordmark:hover { color: var(--navy); }

.nav-list { display: flex; align-items: center; gap: 32px; list-style: none; }
.nav-list a {
  display: block;
  font-family: var(--font-head);
  font-size: 0.98rem;
  font-weight: 500;
  color: var(--ink);
  text-decoration: none;
  line-height: calc(var(--header-h) - 4px);
  border-bottom: 3px solid transparent;
}
.nav-list a:hover { color: var(--accent); }
.nav-list a[aria-current="page"] { border-bottom-color: var(--accent); }
.nav-list .nav-cta {
  line-height: 1;
  padding: 12px 22px;
  background: var(--accent);
  color: #ffffff;
  border: 0;
  border-radius: var(--radius);
}
.nav-list .nav-cta:hover { background: var(--accent-dark); color: #ffffff; }

.nav-toggle {
  display: none;
  background: none;
  border: 0;
  padding: 8px;
  cursor: pointer;
}
.nav-toggle-bar { display: block; width: 24px; height: 2px; background: var(--navy); margin: 5px 0; }

/* ---- HEROES ---- */
/* To add a photo later, set --hero-img on the section, e.g.
   <section class="hero" style="--hero-img: url('images/hero.jpg')"> */
.hero,
.page-hero {
  color: var(--on-dark);
  background-color: var(--navy);
  background-image:
    linear-gradient(100deg, rgba(11, 27, 51, 0.96) 0%, rgba(11, 27, 51, 0.86) 50%, rgba(11, 27, 51, 0.55) 100%),
    var(--hero-img, linear-gradient(135deg, var(--navy) 0%, var(--navy-3) 100%));
  background-size: cover;
  background-position: center;
}
.hero h1, .page-hero h1 { color: #ffffff; max-width: 820px; }
.hero .eyebrow, .page-hero .eyebrow { color: var(--accent-light); }
.hero .lead, .page-hero .lead { color: var(--on-dark); max-width: 640px; margin-top: 18px; }

.hero { padding: 104px 0 96px; }
.page-hero { padding: 48px 0 56px; }

.breadcrumb { margin-bottom: 28px; }
.breadcrumb ol { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; font-size: 0.88rem; }
.breadcrumb li { color: var(--on-dark); }
.breadcrumb li + li::before { content: '\203A'; margin-right: 8px; opacity: 0.6; }
.breadcrumb a { color: var(--on-dark); text-decoration: none; }
.breadcrumb a:hover { color: #ffffff; text-decoration: underline; }
.breadcrumb [aria-current="page"] { color: #ffffff; }

/* ---- KEY FIGURES ---- */
.figures { border-bottom: 1px solid var(--line); }
.figures ul {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}
.figures li { padding: 30px 28px; border-left: 1px solid var(--line); }
.figures li:first-child { border-left: 0; padding-left: 0; }
.figures b {
  display: block;
  font-family: var(--font-head);
  font-size: 1.9rem;
  font-weight: 500;
  color: var(--navy);
  line-height: 1.15;
}
.figures span { font-size: 0.95rem; color: var(--muted); }

/* ---- SECTIONS ---- */
.section { padding: 64px 0; }
.section.alt { background: var(--bg-alt); }
.section-head { max-width: 760px; margin-bottom: 32px; }

.dark { background: var(--navy); color: var(--on-dark); }
.dark h2, .dark h3, .dark h4, .dark strong { color: #ffffff; }
.dark .eyebrow { color: var(--accent-light); }

/* Heading on the left, text on the right. */
.statement {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 48px;
}
.statement h2 { margin-bottom: 0; }

.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; }
.center-y { align-items: center; }

/* ---- BUSINESS PANELS (home) ---- */
.businesses { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.business {
  display: flex;
  flex-direction: column;
  padding: 40px;
  border-radius: var(--radius);
  color: var(--on-dark);
  background: var(--navy);
  border-top: 5px solid var(--biz-accent);
}
.business h3 { font-size: 1.9rem; color: #ffffff; margin-bottom: 12px; }
.business .eyebrow { color: var(--biz-light); }
.business p { max-width: 460px; }
.business .more { color: #ffffff; margin-top: auto; padding-top: 24px; }
.business-usa       { --biz-accent: #c0152f; --biz-light: #f07386; }
.business-solutions { --biz-accent: #2f9a5f; --biz-light: #86d0a3; background: var(--green-deep); }

/* ---- FACT LIST (short label / value rows) ---- */
.facts { list-style: none; border-top: 1px solid var(--line); }
.facts li {
  display: grid;
  grid-template-columns: 130px 1fr;
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}
.facts b {
  font-family: var(--font-head);
  font-weight: 500;
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  padding-top: 2px;
}
.facts span, .facts a { color: var(--ink); }
.dark .facts { border-top-color: var(--line-dark); }
.dark .facts li { border-bottom-color: var(--line-dark); }
.dark .facts b { color: var(--accent-light); }
.dark .facts span, .dark .facts a { color: #ffffff; }

/* ---- STEPS ---- */
.steps {
  list-style: none;
  counter-reset: step;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
}
.steps li { counter-increment: step; border-top: 2px solid var(--accent); padding-top: 16px; }
.steps li::before {
  content: counter(step, decimal-leading-zero);
  display: block;
  font-family: var(--font-head);
  font-weight: 500;
  color: var(--accent);
  margin-bottom: 6px;
}
.steps h3 { font-size: 1.15rem; margin-bottom: 4px; }
.steps p { font-size: 0.98rem; }

/* ---- PANELS (two side-by-side offers) ---- */
.panels { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.panel {
  background: #ffffff;
  border: 1px solid var(--line);
  border-top: 4px solid var(--accent);
  border-radius: var(--radius);
  padding: 32px;
}
.panel h3 { font-size: 1.5rem; }
.panel .tag {
  display: inline-block;
  font-family: var(--font-head);
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 8px;
}

/* ---- LISTS ---- */
.ticks { list-style: none; margin-top: 14px; }
.ticks li { position: relative; padding: 5px 0 5px 26px; }
.ticks li::before {
  content: '';
  position: absolute;
  left: 2px; top: 0.85em;
  width: 11px; height: 6px;
  border-left: 2px solid var(--accent);
  border-bottom: 2px solid var(--accent);
  transform: rotate(-45deg);
}
.ticks.cross li::before {
  width: 11px; height: 2px;
  border: 0;
  background: var(--muted);
  top: 1.05em;
  transform: none;
}

.sectors {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.sectors li {
  font-family: var(--font-head);
  font-weight: 500;
  color: var(--ink);
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 8px 16px;
}

/* ---- SPEC GRID (biodiesel blends) ---- */
.spec {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}
.spec li {
  background: #ffffff;
  padding: 22px 24px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.spec b {
  display: block;
  font-family: var(--font-head);
  font-size: 1.7rem;
  font-weight: 600;
  color: var(--accent);
  line-height: 1.1;
}
.spec .mix { display: block; font-size: 0.9rem; font-weight: 600; color: var(--ink); margin: 4px 0 6px; }
.spec p { font-size: 0.94rem; }
.note { font-size: 0.95rem; color: var(--muted); margin-top: 16px; }

/* ---- FAQ ---- */
.faq { max-width: 800px; border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  list-style: none;
  cursor: pointer;
  position: relative;
  padding: 18px 40px 18px 0;
  font-family: var(--font-head);
  font-size: 1.1rem;
  font-weight: 500;
  color: var(--ink);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: '+';
  position: absolute;
  right: 4px; top: 50%;
  transform: translateY(-50%);
  font-size: 1.4rem;
  color: var(--accent);
}
.faq details[open] summary::after { content: '\2212'; }
.faq details > p { padding: 0 40px 18px 0; }

/* ---- CTA STRIP ---- */
.cta-strip { background: var(--navy); color: var(--on-dark); padding: 44px 0; }
.cta-strip .container { display: flex; align-items: center; justify-content: space-between; gap: 24px 48px; flex-wrap: wrap; }
.cta-strip h2 { color: #ffffff; font-size: 1.6rem; margin-bottom: 4px; }
.cta-strip .actions { margin-top: 0; }

/* ---- STRUCTURE (about) ---- */
.org { display: grid; gap: 16px; }
.org-parent {
  background: var(--navy);
  color: var(--on-dark);
  border-radius: var(--radius);
  padding: 26px 30px;
}
.org-parent h3 { color: #ffffff; margin-bottom: 2px; }
.org-children { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.org-child {
  display: block;
  background: #ffffff;
  border: 1px solid var(--line);
  border-left: 5px solid var(--biz-accent);
  border-radius: var(--radius);
  padding: 22px 26px;
  color: var(--text);
  text-decoration: none;
}
.org-child h3 { margin-bottom: 2px; }
.org-child:hover h3 { color: var(--biz-accent); }

/* ---- PRINCIPLES (about) ---- */
.principles { list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); gap: 32px; }
.principles li { border-top: 2px solid var(--accent); padding-top: 16px; }
.principles h3 { font-size: 1.15rem; margin-bottom: 4px; }
.principles p { font-size: 0.98rem; }

/* ---- CONTACT ---- */
.contact-grid { display: grid; grid-template-columns: 1fr 1.6fr; gap: 64px; align-items: start; }
.contact-grid .facts li { grid-template-columns: 1fr; gap: 2px; }
.contact-grid .facts address { font-style: normal; color: var(--ink); }

.form { display: grid; gap: 18px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-size: 0.92rem; font-weight: 600; color: var(--ink); }
.field .optional { font-weight: 400; color: var(--muted); }
.field input,
.field select,
.field textarea {
  font: inherit;
  font-size: 1rem;
  color: var(--ink);
  background: #ffffff;
  border: 1px solid #b9c3d3;
  border-radius: var(--radius);
  padding: 11px 14px;
  width: 100%;
}
.field input:focus,
.field select:focus,
.field textarea:focus { border-color: var(--accent); outline: 1px solid var(--accent); outline-offset: 0; }
.field textarea { min-height: 140px; resize: vertical; }
.form-legal { font-size: 0.9rem; color: var(--muted); }
.form-status {
  padding: 14px 18px;
  border-left: 3px solid var(--accent);
  background: var(--bg-alt);
  color: var(--ink);
}
.form-status[hidden] { display: none; }
.form button[disabled] { opacity: 0.6; cursor: wait; }

/* ---- LEGAL ---- */
.legal { display: grid; grid-template-columns: 230px 1fr; gap: 64px; align-items: start; }
.legal-toc { position: sticky; top: calc(var(--header-h) + 28px); font-size: 0.92rem; }
.legal-toc h2 {
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 10px;
}
.legal-toc ol { list-style: none; border-left: 2px solid var(--line); }
.legal-toc a { display: block; padding: 4px 0 4px 14px; color: var(--text); text-decoration: none; }
.legal-toc a:hover { color: var(--accent); }
.legal-body { max-width: 780px; }
.legal-body h2 { font-size: 1.45rem; margin: 40px 0 12px; }
.legal-body h2:first-child { margin-top: 0; }
.legal-body h3 { font-size: 1.1rem; font-weight: 600; margin: 20px 0 6px; }
.legal-body ul { margin: 10px 0 0 22px; }
.legal-body li { margin-bottom: 6px; }
.legal-body p + ul, .legal-body ul + p { margin-top: 10px; }
.legal-body address { font-style: normal; margin-top: 10px; color: var(--ink); }
.legal-caps { text-transform: uppercase; font-size: 0.95rem; }
.page-hero .effective { margin-top: 12px; color: var(--on-dark); }

/* ---- FOOTER ---- */
.site-footer { background: #07111f; color: var(--on-dark); padding: 52px 0 24px; font-size: 0.95rem; }
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  gap: 40px;
  padding-bottom: 36px;
  border-bottom: 1px solid var(--line-dark);
}
.site-footer .wordmark { color: #ffffff; }
.footer-brand p { margin-top: 12px; max-width: 280px; }
.site-footer h2 {
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #ffffff;
  margin-bottom: 12px;
}
.site-footer ul { list-style: none; }
.site-footer li + li { margin-top: 6px; }
.site-footer a { color: var(--on-dark); text-decoration: none; }
.site-footer a:hover { color: #ffffff; text-decoration: underline; }
.site-footer address { font-style: normal; }
.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px 24px;
  padding-top: 20px;
  font-size: 0.85rem;
  color: #8e9bb2;
}
.footer-bottom ul { display: flex; gap: 24px; }
.footer-bottom li + li { margin-top: 0; }
.footer-bottom a { color: #8e9bb2; }

/* ---- RESPONSIVE ---- */
@media (max-width: 1000px) {
  .figures ul { grid-template-columns: 1fr 1fr; }
  .figures li:nth-child(3) { border-left: 0; padding-left: 0; }
  .figures li:nth-child(n+3) { border-top: 1px solid var(--line); }
  .steps, .principles { grid-template-columns: 1fr 1fr; }
  .spec { grid-template-columns: repeat(3, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 860px) {
  .nav-toggle { display: block; }
  .site-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0; right: 0;
    background: #ffffff;
    border-bottom: 1px solid var(--line);
    padding: 8px 32px 24px;
  }
  .site-nav.is-open { display: block; }
  .nav-list { flex-direction: column; align-items: stretch; gap: 0; }
  .nav-list a { line-height: 1.4; padding: 14px 0; border-bottom: 1px solid var(--line); }
  .nav-list a[aria-current="page"] { border-bottom-color: var(--line); color: var(--accent); }
  .nav-list .nav-cta { margin-top: 16px; text-align: center; padding: 14px; }

  .statement, .two-col, .businesses, .panels, .org-children, .contact-grid, .legal { grid-template-columns: 1fr; gap: 28px; }
  .legal-toc { position: static; }
  .hero { padding: 72px 0 64px; }
  .section { padding: 52px 0; }
  .business { padding: 32px; }
}

@media (max-width: 600px) {
  .container { padding: 0 20px; }
  .site-nav { padding: 8px 20px 20px; }
  .steps, .principles, .form-row, .footer-grid { grid-template-columns: 1fr; }
  .figures li { padding: 18px 0 18px 16px; }
  .figures li:nth-child(odd) { padding-left: 0; }
  .figures b { font-size: 1.4rem; }
  .spec { grid-template-columns: 1fr 1fr; }
  .facts li { grid-template-columns: 1fr; gap: 2px; }
  .actions .btn { width: 100%; text-align: center; }
  .cta-strip .actions { width: 100%; }
  .page-hero { padding: 36px 0 44px; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
}
