/* ============================================================
   All Energy Management — site styles
   Warm, approachable, professional. Built mobile-first.
============================================================ */

:root {
  --primary: #1f3a5f;
  --primary-dark: #152a47;
  --primary-soft: #2c4f7c;
  --accent: #d97706;
  --accent-dark: #b45309;
  --accent-soft: #fbbf24;
  --bg: #faf7f2;
  --bg-alt: #ffffff;
  --bg-warm: #f3ece0;
  --text: #1a1a1a;
  --text-muted: #5c6470;
  --border: #e8e2d7;
  --shadow: 0 1px 3px rgba(31, 58, 95, 0.05), 0 4px 12px rgba(31, 58, 95, 0.08);
  --shadow-lg: 0 4px 6px rgba(31, 58, 95, 0.05), 0 10px 30px rgba(31, 58, 95, 0.12);
  --radius: 10px;
  --radius-lg: 16px;
  --container: 1180px;
  --transition: 0.2s ease;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img, svg {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: color var(--transition);
}

a:hover {
  color: var(--accent-dark);
}

/* ----------- Layout helpers ----------- */
.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 1.25rem;
}

section {
  padding: 4rem 0;
}

@media (min-width: 768px) {
  section {
    padding: 5.5rem 0;
  }
}

/* ----------- Typography ----------- */
h1, h2, h3, h4 {
  font-weight: 700;
  line-height: 1.2;
  color: var(--primary);
  letter-spacing: -0.02em;
}

h1 {
  font-size: 2.25rem;
}

h2 {
  font-size: 1.75rem;
  margin-bottom: 1rem;
}

h3 {
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
}

p {
  margin-bottom: 1rem;
  color: var(--text);
}

p.lead {
  font-size: 1.125rem;
  color: var(--text-muted);
  max-width: 60ch;
}

@media (min-width: 768px) {
  h1 { font-size: 3rem; }
  h2 { font-size: 2.25rem; }
  h3 { font-size: 1.375rem; }
}

.eyebrow {
  display: inline-block;
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-dark);
  margin-bottom: 0.75rem;
}

/* ----------- Buttons ----------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.875rem 1.5rem;
  font-weight: 600;
  font-size: 1rem;
  border-radius: var(--radius);
  border: 2px solid transparent;
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
  white-space: nowrap;
}

.btn-primary {
  background: var(--accent);
  color: white;
}

.btn-primary:hover {
  background: var(--accent-dark);
  color: white;
  transform: translateY(-1px);
  box-shadow: var(--shadow);
}

.btn-secondary {
  background: transparent;
  color: var(--primary);
  border-color: var(--primary);
}

.btn-secondary:hover {
  background: var(--primary);
  color: white;
}

.btn-light {
  background: white;
  color: var(--primary);
}

.btn-light:hover {
  background: var(--bg-warm);
  color: var(--primary-dark);
}

/* ----------- Header / nav ----------- */
.site-header {
  background: var(--bg);
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(8px);
  background: rgba(250, 247, 242, 0.95);
}

.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.25rem;
  max-width: var(--container);
  margin: 0 auto;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  font-weight: 700;
  font-size: 1.125rem;
  color: var(--primary);
  letter-spacing: -0.01em;
  text-decoration: none;
}

.logo:hover {
  color: var(--primary);
}

.logo-img {
  display: block;
  height: 75px;
  width: auto;
}

@media (min-width: 768px) {
  .logo-img {
    height: 110px;
  }
}

/* small icon + text used in footer */
.logo-mark {
  width: 36px;
  height: 36px;
  flex-shrink: 0;
}

.logo-text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.logo-text small {
  font-size: 0.6875rem;
  font-weight: 500;
  color: var(--text-muted);
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.nav-toggle {
  display: block;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  color: var(--primary);
}

.nav-toggle svg {
  width: 28px;
  height: 28px;
}

#nav-check {
  display: none;
}

.main-nav {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--bg-alt);
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow);
}

#nav-check:checked ~ .main-nav {
  display: block;
}

.main-nav ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  padding: 0.5rem 0;
}

.main-nav a {
  display: block;
  padding: 0.875rem 1.5rem;
  color: var(--text);
  font-weight: 500;
}

.main-nav a:hover,
.main-nav a.active {
  background: var(--bg-warm);
  color: var(--primary);
}

@media (min-width: 880px) {
  .nav-toggle {
    display: none;
  }
  .main-nav {
    display: block !important;
    position: static;
    background: transparent;
    border: none;
    box-shadow: none;
  }
  .main-nav ul {
    flex-direction: row;
    align-items: center;
    gap: 0.25rem;
    padding: 0;
  }
  .main-nav a {
    padding: 0.5rem 0.875rem;
    border-radius: var(--radius);
  }
  .main-nav a.active {
    color: var(--accent-dark);
    background: transparent;
  }
  .main-nav .nav-cta {
    margin-left: 0.5rem;
  }
  .main-nav .nav-cta a {
    background: var(--accent);
    color: white;
    padding: 0.625rem 1.125rem;
  }
  .main-nav .nav-cta a:hover {
    background: var(--accent-dark);
    color: white;
  }
}

/* ----------- Hero ----------- */
.hero {
  padding: 3rem 0 4rem;
  background: linear-gradient(180deg, var(--bg) 0%, var(--bg-warm) 100%);
  overflow: hidden;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
  align-items: center;
}

@media (min-width: 880px) {
  .hero {
    padding: 5rem 0 6rem;
  }
  .hero-grid {
    grid-template-columns: 1.1fr 1fr;
    gap: 4rem;
  }
}

.hero-text h1 {
  margin-bottom: 1.25rem;
  font-size: 2.5rem;
}

@media (min-width: 768px) {
  .hero-text h1 {
    font-size: 3.5rem;
  }
}

.hero-text p {
  font-size: 1.125rem;
  color: var(--text-muted);
  margin-bottom: 2rem;
  max-width: 52ch;
}

.hero-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.hero-illustration {
  display: flex;
  justify-content: center;
  align-items: center;
}

.hero-illustration svg {
  width: 100%;
  max-width: 500px;
  height: auto;
}

/* ----------- Photos ----------- */
.hero-illustration .photo {
  width: 100%;
  max-width: 460px;
  max-height: 520px;
  height: auto;
  object-fit: cover;
  border-radius: 16px;
  box-shadow: 0 12px 32px rgba(31, 58, 95, 0.18);
}

.photo-frame {
  width: 100%;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 12px 32px rgba(31, 58, 95, 0.18);
}

.photo-frame img {
  display: block;
  width: 100%;
  height: auto;
}

.photo-block {
  margin: 2.5rem 0;
}

.photo-block img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 16px;
  box-shadow: 0 12px 32px rgba(31, 58, 95, 0.18);
}

.photo-band {
  max-width: 860px;
  margin: 0 auto;
}

.photo-band img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 16px;
  box-shadow: 0 12px 32px rgba(31, 58, 95, 0.18);
}

.photo-caption {
  margin-top: 0.75rem;
  font-size: 0.9rem;
  color: var(--text-muted);
  text-align: center;
}

/* ----------- Trust strip ----------- */
.trust-strip {
  background: var(--primary);
  color: white;
  padding: 2rem 0;
}

.trust-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  text-align: center;
}

@media (min-width: 768px) {
  .trust-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.trust-item {
  padding: 0 0.5rem;
}

.trust-item strong {
  display: block;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent-soft);
  margin-bottom: 0.25rem;
}

.trust-item span {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.85);
}

/* ----------- Page header (interior pages) ----------- */
.page-header {
  background: linear-gradient(180deg, var(--bg) 0%, var(--bg-warm) 100%);
  padding: 3rem 0 3rem;
  border-bottom: 1px solid var(--border);
}

.page-header h1 {
  margin-bottom: 0.75rem;
}

.page-header p.lead {
  font-size: 1.125rem;
}

/* ----------- Card grids ----------- */
.section-intro {
  text-align: center;
  max-width: 720px;
  margin: 0 auto 3rem;
}

.section-intro p.lead {
  margin: 0 auto;
}

.card-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

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

@media (min-width: 960px) {
  .card-grid.cols-3 {
    grid-template-columns: repeat(3, 1fr);
  }
}

.card {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  transition: transform var(--transition), box-shadow var(--transition);
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.card-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius);
  background: var(--bg-warm);
  color: var(--accent-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
}

.card-icon svg {
  width: 26px;
  height: 26px;
}

.card h3 {
  margin-bottom: 0.5rem;
}

.card p {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin: 0;
}

/* ----------- Service detail blocks ----------- */
.service-block {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
  padding: 2.5rem 0;
  border-bottom: 1px solid var(--border);
  align-items: start;
}

@media (min-width: 768px) {
  .service-block {
    grid-template-columns: 240px 1fr;
    gap: 3rem;
  }
}

.service-block:last-child {
  border-bottom: none;
}

.service-block .service-label {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}

.service-block .service-icon {
  width: 56px;
  height: 56px;
  border-radius: var(--radius);
  background: var(--bg-warm);
  color: var(--accent-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.service-block .service-icon svg {
  width: 30px;
  height: 30px;
}

.service-block h3 {
  font-size: 1.5rem;
  margin: 0;
  line-height: 1.3;
}

.service-block .service-body p {
  color: var(--text-muted);
  font-size: 1rem;
  margin-bottom: 1rem;
}

.service-block .service-body p:last-child {
  margin-bottom: 0;
}

/* ----------- Two-column content ----------- */
.two-col {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
  align-items: center;
}

@media (min-width: 880px) {
  .two-col {
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
  }
  .two-col.photo-lead {
    grid-template-columns: 1.6fr 1fr;
  }
  .two-col.flip > div:first-child {
    order: 2;
  }
}

/* ----------- CTA section ----------- */
.cta-band {
  background: var(--primary);
  color: white;
  text-align: center;
}

.cta-band h2 {
  color: white;
  margin-bottom: 1rem;
}

.cta-band p {
  color: rgba(255, 255, 255, 0.85);
  font-size: 1.125rem;
  max-width: 540px;
  margin: 0 auto 2rem;
}

/* ----------- Alt section background ----------- */
.section-alt {
  background: var(--bg-alt);
}

.section-warm {
  background: var(--bg-warm);
}

/* ----------- Values list ----------- */
.values-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
  list-style: none;
}

@media (min-width: 768px) {
  .values-list {
    grid-template-columns: repeat(3, 1fr);
  }
}

.values-list li {
  background: var(--bg-alt);
  padding: 1.75rem;
  border-radius: var(--radius-lg);
  border-left: 4px solid var(--accent);
}

.values-list h3 {
  font-size: 1.125rem;
  margin-bottom: 0.5rem;
}

.values-list p {
  font-size: 0.95rem;
  color: var(--text-muted);
  margin: 0;
}

/* ----------- Task grid (services page) ----------- */
.task-section + .task-section {
  margin-top: 4rem;
}

.task-section h2 {
  margin-bottom: 0.5rem;
}

.task-section .task-intro {
  color: var(--text-muted);
  font-size: 1.05rem;
  max-width: 60ch;
  margin-bottom: 2.5rem;
}

.task-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem 2rem;
}

@media (min-width: 700px) {
  .task-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.task-item {
  display: flex;
  gap: 0.875rem;
  align-items: flex-start;
}

.task-item .check {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  background: var(--accent);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 3px;
}

.task-item .check svg {
  width: 14px;
  height: 14px;
}

.task-item h3 {
  margin: 0 0 0.375rem;
  font-size: 1.0625rem;
  font-weight: 600;
  color: var(--primary);
}

.task-item p {
  margin: 0;
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.55;
}

/* ----------- Capability rows ----------- */
.capability-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  padding: 2rem 0;
  border-bottom: 1px solid var(--border);
}

@media (min-width: 768px) {
  .capability-row {
    grid-template-columns: 64px 1fr;
    gap: 2rem;
    align-items: start;
  }
}

.capability-row:last-child {
  border-bottom: none;
}

.capability-row .icon-circle {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--primary);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.capability-row .icon-circle svg {
  width: 28px;
  height: 28px;
}

.capability-row h3 {
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
}

.capability-row p {
  color: var(--text-muted);
  margin: 0;
}

/* ----------- Form ----------- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3rem;
}

@media (min-width: 880px) {
  .contact-grid {
    grid-template-columns: 1.5fr 1fr;
    gap: 4rem;
  }
}

.contact-form {
  background: var(--bg-alt);
  padding: 2rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
}

@media (min-width: 768px) {
  .contact-form {
    padding: 2.5rem;
  }
}

.form-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  margin-bottom: 1rem;
}

@media (min-width: 640px) {
  .form-row.cols-2 {
    grid-template-columns: 1fr 1fr;
  }
}

.form-field label {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 0.375rem;
}

.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  padding: 0.75rem 0.875rem;
  font-family: inherit;
  font-size: 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg);
  color: var(--text);
  transition: border-color var(--transition), box-shadow var(--transition);
}

.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(217, 119, 6, 0.15);
}

.form-field textarea {
  resize: vertical;
  min-height: 120px;
}

.form-note {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-top: 1rem;
}

.contact-info {
  background: var(--primary);
  color: white;
  padding: 2rem;
  border-radius: var(--radius-lg);
  align-self: start;
}

.contact-info h3 {
  color: white;
  margin-bottom: 1.25rem;
}

.contact-info dl {
  margin: 0;
}

.contact-info dt {
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--accent-soft);
  margin-bottom: 0.25rem;
  margin-top: 1.25rem;
}

.contact-info dt:first-child {
  margin-top: 0;
}

.contact-info dd {
  font-size: 1rem;
  color: rgba(255, 255, 255, 0.95);
  margin: 0;
}

.contact-info dd a {
  color: white;
  border-bottom: 1px solid rgba(255, 255, 255, 0.4);
}

.contact-info dd a:hover {
  color: var(--accent-soft);
  border-color: var(--accent-soft);
}

/* ----------- Footer ----------- */
.site-footer {
  background: var(--primary-dark);
  color: rgba(255, 255, 255, 0.8);
  padding: 3rem 0 1.5rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  margin-bottom: 2rem;
}

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

.footer-grid h4 {
  color: white;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 1rem;
}

.footer-grid p,
.footer-grid li {
  font-size: 0.9rem;
  margin-bottom: 0.375rem;
  color: rgba(255, 255, 255, 0.85);
}

/* Belt-and-suspenders: force white text on every text element inside the footer */
.site-footer p,
.site-footer li,
.site-footer span,
.site-footer dd,
.site-footer dt {
  color: rgba(255, 255, 255, 0.85);
}

.footer-grid ul {
  list-style: none;
}

.footer-grid a {
  color: rgba(255, 255, 255, 0.8);
}

.footer-grid a:hover {
  color: var(--accent-soft);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 1.5rem;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.6);
  text-align: center;
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.footer-logo svg {
  width: 32px;
  height: 32px;
}

.footer-logo strong {
  color: white;
  font-size: 1rem;
  font-weight: 700;
}
