/*
Theme Name:   People & Machines Child
Description:  Child theme for People & Machines — redesigned 2025
Template:     twentytwentyfour
Version: 1.0.6
*/


/* Homepage logo & nav fixes */
.pm-nav__logo img {
  filter: hue-rotate(215deg) saturate(1.2) brightness(1.1);
}

.pm-nav__inner {
  display: flex;
  align-items: center;
  padding: 0 2rem;
  gap: 2rem;
}

.pm-nav__links {
  margin-left: auto;
  display: flex;
  gap: 1.5rem;
  align-items: center;
}

/* ─── Fonts ─────────────────────────────────────────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@300;400;500&family=DM+Serif+Display:ital@0;1&display=swap');

/* ─── Variables ──────────────────────────────────────────────────────── */
:root {
  --pm-dark:       #07101f;
  --pm-dark-mid:   #0e1e36;
  --pm-blue:       #3e8ff5;
  --pm-blue-pale:  #e6f1fb;
  --pm-teal:       #1d9e75;
  --pm-teal-pale:  #e1f5ee;
  --pm-amber:      #ba7517;
  --pm-amber-pale: #faeeda;
  --pm-text:       #1a1a1a;
  --pm-muted:      #5f5e5a;
  --pm-border:     rgba(0,0,0,0.09);
  --pm-bg:         #f7f6f2;
  --pm-white:      #ffffff;
  --pm-radius-sm:  6px;
  --pm-radius-md:  10px;
  --pm-radius-lg:  16px;
  --pm-radius-xl:  24px;
  --pm-font-head:  'DM Serif Display', Georgia, serif;
  --pm-font-body:  'DM Sans', sans-serif;
}

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

body {
  font-family: var(--pm-font-body);
  color: var(--pm-text);
  background: var(--pm-bg);
  -webkit-font-smoothing: antialiased;
}

/* Hide the default WP header ONLY on the homepage (front-page.php has its own nav) */
.home .wp-site-blocks > header { display: none !important; }

/* ─── PM Wrapper ─────────────────────────────────────────────────────── */
.pm-wrap {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 32px;
}

/* ═══════════════════════════════════════════════════════════════════════
   HOMEPAGE NAV (front-page.php only)
═══════════════════════════════════════════════════════════════════════ */
.pm-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: rgba(7, 16, 31, 0.88);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 0.5px solid rgba(255,255,255,0.08);
}
.pm-nav__inner {
  max-width: 1200px;
  margin: 0;
  padding: 0 32px;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.pm-nav__logo {
  font-family: var(--pm-font-body);
  font-size: 15px;
  font-weight: 500;
  color: #fff;
  text-decoration: none;
  letter-spacing: 0.01em;
}
.pm-nav__logo span { color: var(--pm-blue); }
.pm-nav__links {
  display: flex;
  gap: 28px;
  list-style: none;
}
.pm-nav__links a {
  font-size: 13px;
  color: rgba(255,255,255,0.55);
  text-decoration: none;
  transition: color 0.2s;
}
.pm-nav__links a:hover { color: #fff; }
.pm-nav__links a.pm-nav__cta {
  color: var(--pm-blue);
  font-weight: 500;
}
.pm-nav__hamburger {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  flex-direction: column;
  gap: 5px;
  padding: 4px;
}
.pm-nav__hamburger span {
  display: block;
  width: 22px;
  height: 1.5px;
  background: rgba(255,255,255,0.7);
  border-radius: 2px;
  transition: all 0.25s;
}

/* ═══════════════════════════════════════════════════════════════════════
   HERO
═══════════════════════════════════════════════════════════════════════ */
.pm-hero {
  background: var(--pm-dark);
  padding: 160px 0 100px;
  overflow: hidden;
  position: relative;
}
.pm-hero__orb {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
}
.pm-hero__orb--1 {
  width: 520px; height: 520px;
  top: -180px; right: -100px;
  background: radial-gradient(circle, #163560 0%, transparent 70%);
  opacity: 0.7;
}
.pm-hero__orb--2 {
  width: 360px; height: 360px;
  bottom: -100px; left: 20%;
  background: radial-gradient(circle, #0a2840 0%, transparent 70%);
  opacity: 0.5;
}
.pm-hero__inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 32px;
  position: relative;
  z-index: 1;
}
.pm-hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--pm-blue);
  margin-bottom: 24px;
}
.pm-hero__eyebrow::before {
  content: '';
  display: block;
  width: 24px;
  height: 1px;
  background: var(--pm-blue);
}
.pm-hero__h1 {
  font-family: var(--pm-font-head);
  font-size: clamp(36px, 5vw, 56px);
  font-weight: 400;
  line-height: 1.15;
  color: #fff;
  max-width: 640px;
  margin-bottom: 24px;
}
.pm-hero__h1 em { font-style: italic; color: var(--pm-blue); }
.pm-hero__sub {
  font-size: 17px;
  line-height: 1.65;
  color: rgba(255,255,255,0.55);
  max-width: 480px;
  margin-bottom: 40px;
}
.pm-hero__ctas { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.pm-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border-radius: var(--pm-radius-md);
  font-family: var(--pm-font-body);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s;
  padding: 13px 24px;
  border: none;
}
.pm-btn--primary { background: var(--pm-blue); color: #fff; }
.pm-btn--primary:hover { background: #5aa3ff; color: #fff; transform: translateY(-1px); }
.pm-btn--ghost {
  background: transparent;
  color: rgba(255,255,255,0.65);
  border: 0.5px solid rgba(255,255,255,0.2);
}
.pm-btn--ghost:hover { color: #fff; border-color: rgba(255,255,255,0.5); }
.pm-hero__stats {
  display: flex;
  gap: 40px;
  margin-top: 60px;
  padding-top: 40px;
  border-top: 0.5px solid rgba(255,255,255,0.08);
}
.pm-hero__stat-num {
  font-family: var(--pm-font-head);
  font-size: 28px;
  color: #fff;
  line-height: 1;
  margin-bottom: 5px;
}
.pm-hero__stat-label { font-size: 12px; color: rgba(255,255,255,0.4); letter-spacing: 0.02em; }

/* ═══════════════════════════════════════════════════════════════════════
   SECTIONS
═══════════════════════════════════════════════════════════════════════ */
.pm-section { padding: 80px 0; }
.pm-section--alt { background: var(--pm-white); }
.pm-section__label {
  font-size: 11px; font-weight: 500; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--pm-muted); margin-bottom: 12px;
}
.pm-section__heading {
  font-family: var(--pm-font-head);
  font-size: clamp(26px, 3.5vw, 38px);
  font-weight: 400; line-height: 1.2;
  color: var(--pm-text); max-width: 520px; margin-bottom: 12px;
}
.pm-section__heading em { font-style: italic; color: var(--pm-blue); }
.pm-section__sub { font-size: 15px; color: var(--pm-muted); max-width: 440px; line-height: 1.65; margin-bottom: 48px; }

/* Services */
.pm-services-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.pm-service-card {
  background: var(--pm-white); border: 0.5px solid var(--pm-border);
  border-radius: var(--pm-radius-lg); padding: 28px 24px;
  transition: transform 0.2s, box-shadow 0.2s;
}
.pm-service-card:hover { transform: translateY(-3px); box-shadow: 0 12px 32px rgba(0,0,0,0.07); }
.pm-service-card__icon {
  width: 40px; height: 40px; border-radius: var(--pm-radius-md);
  display: flex; align-items: center; justify-content: center; margin-bottom: 18px; font-size: 20px;
}
.pm-service-card__icon--blue  { background: var(--pm-blue-pale);  color: #185fa5; }
.pm-service-card__icon--teal  { background: var(--pm-teal-pale);  color: var(--pm-teal); }
.pm-service-card__icon--amber { background: var(--pm-amber-pale); color: var(--pm-amber); }
.pm-service-card h3 { font-size: 16px; font-weight: 500; color: var(--pm-text); margin-bottom: 10px; }
.pm-service-card p  { font-size: 13.5px; color: var(--pm-muted); line-height: 1.6; margin-bottom: 20px; }
.pm-service-card__link {
  font-size: 13px; font-weight: 500; color: var(--pm-blue);
  text-decoration: none; display: inline-flex; align-items: center; gap: 4px;
}
.pm-service-card__link:hover { gap: 8px; }

/* Capabilities */
.pm-capabilities { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: start; }
.pm-cap-list { display: flex; flex-wrap: wrap; gap: 8px; }
.pm-cap-chip {
  background: var(--pm-bg); border: 0.5px solid var(--pm-border);
  border-radius: 999px; padding: 7px 16px; font-size: 13px;
  color: var(--pm-muted); transition: all 0.15s; cursor: default;
}
.pm-cap-chip:hover { background: var(--pm-dark); color: #fff; border-color: transparent; }
.pm-sectors-list { list-style: none; display: flex; flex-direction: column; }
.pm-sector-item {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 0; border-bottom: 0.5px solid var(--pm-border);
  font-size: 14px; color: var(--pm-text);
}
.pm-sector-item::before {
  content: ''; display: block; width: 6px; height: 6px;
  border-radius: 50%; background: var(--pm-blue); flex-shrink: 0;
}

/* About strip */
.pm-about-strip { background: var(--pm-dark); padding: 80px 0; position: relative; overflow: hidden; }
.pm-about-strip__inner {
  max-width: 1100px; margin: 0 auto; padding: 0 32px;
  display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; position: relative; z-index: 1;
}
.pm-about-strip__label {
  font-size: 11px; font-weight: 500; letter-spacing: 0.1em;
  text-transform: uppercase; color: rgba(255,255,255,0.35); margin-bottom: 16px;
}
.pm-about-strip h2 {
  font-family: var(--pm-font-head); font-size: clamp(26px, 3vw, 36px);
  font-weight: 400; color: #fff; line-height: 1.25; margin-bottom: 20px;
}
.pm-about-strip h2 em { font-style: italic; color: var(--pm-blue); }
.pm-about-strip p { font-size: 15px; color: rgba(255,255,255,0.5); line-height: 1.7; margin-bottom: 16px; }
.pm-about-strip__facts { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.pm-fact-card {
  background: rgba(255,255,255,0.04); border: 0.5px solid rgba(255,255,255,0.08);
  border-radius: var(--pm-radius-lg); padding: 20px;
}
.pm-fact-card__num { font-family: var(--pm-font-head); font-size: 30px; color: #fff; line-height: 1; margin-bottom: 6px; }
.pm-fact-card__label { font-size: 12px; color: rgba(255,255,255,0.38); line-height: 1.4; }

/* CTA */
.pm-cta { padding: 80px 0; background: var(--pm-bg); }
.pm-cta__card {
  background: var(--pm-dark-mid); border-radius: var(--pm-radius-xl);
  padding: 56px 64px; display: flex; align-items: center; justify-content: space-between; gap: 40px;
}
.pm-cta__card h2 {
  font-family: var(--pm-font-head); font-size: clamp(24px, 3vw, 34px);
  font-weight: 400; color: #fff; line-height: 1.3; max-width: 400px;
}
.pm-cta__card h2 em { font-style: italic; color: var(--pm-blue); }

/* Footer */
.pm-footer { background: var(--pm-dark); padding: 48px 0 32px; border-top: 0.5px solid rgba(255,255,255,0.06); }
.pm-footer__inner {
  max-width: 1100px; margin: 0 auto; padding: 0 32px;
  display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap;
}
.pm-footer__logo { font-size: 14px; font-weight: 500; color: rgba(255,255,255,0.5); }
.pm-footer__logo span { color: var(--pm-blue); }
.pm-footer__links { display: flex; gap: 20px; list-style: none; }
.pm-footer__links a { font-size: 12px; color: rgba(255,255,255,0.35); text-decoration: none; }
.pm-footer__links a:hover { color: rgba(255,255,255,0.7); }
.pm-footer__copy { font-size: 12px; color: rgba(255,255,255,0.2); }

/* Animations */
.pm-fade-up { opacity: 0; transform: translateY(22px); transition: opacity 0.55s ease, transform 0.55s ease; }
.pm-fade-up.pm-visible { opacity: 1; transform: translateY(0); }
.pm-fade-up--d1 { transition-delay: 0.1s; }
.pm-fade-up--d2 { transition-delay: 0.2s; }
.pm-fade-up--d3 { transition-delay: 0.3s; }

/* Responsive */
@media (max-width: 860px) {
  .pm-nav__links { display: none; }
  .pm-nav__links.pm-open {
    display: flex; flex-direction: column;
    position: absolute; top: 60px; left: 0; right: 0;
    background: var(--pm-dark); padding: 16px 32px 24px;
    border-bottom: 0.5px solid rgba(255,255,255,0.08); gap: 16px;
  }
  .pm-nav__hamburger { display: flex; }
  .pm-hero__stats { flex-direction: column; gap: 24px; }
  .pm-services-grid { grid-template-columns: 1fr; }
  .pm-capabilities { grid-template-columns: 1fr; gap: 32px; }
  .pm-about-strip__inner { grid-template-columns: 1fr; gap: 40px; }
  .pm-about-strip__facts { grid-template-columns: 1fr 1fr; }
  .pm-cta__card { flex-direction: column; align-items: flex-start; padding: 40px 32px; }
  .pm-footer__inner { flex-direction: column; align-items: flex-start; }
}
@media (max-width: 560px) {
  .pm-wrap, .pm-hero__inner, .pm-about-strip__inner, .pm-footer__inner { padding: 0 20px; }
  .pm-hero { padding: 120px 0 72px; }
  .pm-about-strip__facts { grid-template-columns: 1fr; }
}

/* ═══════════════════════════════════════════════════════════════════════
   INNER PAGE OVERRIDES (all pages except homepage)
═══════════════════════════════════════════════════════════════════════ */

/* ── Blue accent ────────────────────────────────────────────────────── */
.has-primary-color,
.has-secondary-color,
.has-vivid-red-color  { color: #3e8ff5 !important; }

/* Bold intro text (was red in old theme) */
.wp-block-post-content p strong,
.entry-content p strong { color: #3e8ff5 !important; }

/* Links */
body a       { color: #3e8ff5; }
body a:hover { color: #5aa3ff; }

/* Buttons */
.wp-block-button__link, .wp-element-button {
  background-color: #3e8ff5 !important;
  color: #fff !important;
  border-color: #3e8ff5 !important;
}
.wp-block-button__link:hover { background-color: #5aa3ff !important; }

/* ── Full-width images ──────────────────────────────────────────────── */
.wp-block-post-content .wp-block-image,
.entry-content .wp-block-image {
  max-width: 100% !important;
  width: 100% !important;
}
.wp-block-post-content .wp-block-image img,
.entry-content .wp-block-image img {
  width: 100% !important;
  max-width: 100% !important;
  height: auto !important;
  border-radius: 12px;
  display: block;
}

/* ── Fixed dark nav on inner pages ─────────────────────────────────── */
/* Only target the WP site header on NON-home pages */
.not-home .wp-site-blocks > header,
body:not(.home) .wp-site-blocks > header {
  position: fixed !important;
  top: 0 !important; left: 0 !important; right: 0 !important;
  width: 100% !important;
  z-index: 9999 !important;
  background: #07101f !important;
  border-bottom: 1px solid rgba(255,255,255,0.1) !important;
  height: 72px !important;
  box-sizing: border-box !important;
  display: flex !important;
  align-items: center !important;
}

/* Push content below nav */
body:not(.home) .wp-site-blocks {
  padding-top: 60px !important;
}

/* Inner group layout */
/* Outer wrapper group — flex item filling header height */
body:not(.home) .wp-site-blocks > header .wp-block-group:not(.alignwide):not(.is-layout-flex) {
  display: flex !important;
  align-items: center !important;
  width: 100% !important;
  max-width: 100% !important;
  height: 100% !important;
  padding: 0 !important;
  margin: 0 !important;
}
/* Alignwide group — the actual flex nav row */
body:not(.home) .wp-site-blocks > header .wp-block-group.alignwide {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  width: 100% !important;
  max-width: 1200px !important;
  min-height: 72px !important;
  padding: 0 32px !important;
  margin: 0 !important;
}
/* Inner flex groups — natural sizing, vertically centred */
body:not(.home) .wp-site-blocks > header .wp-block-group.is-layout-flex {
  padding: 0 !important;
  margin: 0 !important;
  gap: 12px !important;
  align-items: center !important;
}

/* Logo */
body:not(.home) .wp-site-blocks > header .wp-block-site-title a {
  color: #fff !important;
  font-size: 15px !important;
  font-weight: 500 !important;
  text-decoration: none !important;
}

/* Nav links */
body:not(.home) .wp-site-blocks > header .wp-block-navigation a {
  color: rgba(255,255,255,0.7) !important;
  font-size: 13px !important;
  text-decoration: none !important;
}
body:not(.home) .wp-site-blocks > header .wp-block-navigation a:hover {
  color: #fff !important;
}

/* Mobile nav open state */
.wp-block-navigation__responsive-container.is-menu-open {
  background: #07101f !important;
}
.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation-item a {
  color: rgba(255,255,255,0.8) !important;
}

/* ── Wide content layout ────────────────────────────────────────────── */
body:not(.home) .wp-block-post-content {
  max-width: 1100px !important;
  margin: 0 auto !important;
  padding: 48px 48px 80px !important;
}

body:not(.home) .wp-block-post-content > * {
  max-width: 100% !important;
}

/* Typography */
.wp-block-post-content p,
.entry-content p { font-size: 16px; line-height: 1.75; color: #1a1a1a; }

.wp-block-post-content h1, .wp-block-post-content h2, .wp-block-post-content h3,
.entry-content h1, .entry-content h2, .entry-content h3 {
  font-weight: 400; line-height: 1.25; color: #07101f; margin-top: 40px; margin-bottom: 14px;
}

.wp-block-post-title { text-align: center; font-weight: 400; color: #07101f; }

@media (max-width: 600px) {
  body:not(.home) .wp-site-blocks > header .wp-block-group { padding: 0 16px !important; }
  body:not(.home) .wp-block-post-content { padding: 32px 20px 60px !important; }
}


/* === Dark theme: all subpages === */
body:not(.home) {
  background-color: #07101f !important;
}

body:not(.home) .wp-site-blocks,
body:not(.home) main,
body:not(.home) .wp-block-post-content {
  background-color: #07101f !important;
}

body:not(.home) .wp-block-group:not(.wp-block-template-part) {
  background-color: #07101f !important;
}

/* Text colors on dark subpages */
body:not(.home) p,
body:not(.home) li {
  color: #c8cdd8 !important;
}

body:not(.home) h1,
body:not(.home) h2,
body:not(.home) h3,
body:not(.home) h4,
body:not(.home) h5 {
  color: #ffffff !important;
}

body:not(.home) .wp-block-post-title,
body:not(.home) .entry-title {
  color: #ffffff !important;
}

/* Dark footer on subpages */
body:not(.home) footer.wp-block-template-part {
  background-color: #050d18 !important;
  color: #8892a4 !important;
}

body:not(.home) footer a {
  color: #8892a4 !important;
}

body:not(.home) footer a:hover {
  color: #3e8ff5 !important;
}

/* === Logo colour: red -> blue #3e8ff5 === */
.wp-block-site-logo img,
.custom-logo-link .custom-logo {
  filter: hue-rotate(215deg) saturate(1.2) brightness(1.1);
}


/* ============================================================
   pm-sub-page-nav-custom: Sub-page nav spacing & sizing
   ============================================================ */

/* Sub-page nav: increase font size and spread links */
.wp-block-navigation .wp-block-navigation-item__content {
  font-size: 15px !important;
  letter-spacing: -0.01em !important;
}
.wp-block-navigation.is-horizontal {
  gap: 40px !important;
}
.wp-block-navigation.is-horizontal .wp-block-navigation__submenu-icon {
  display: none !important;
}

/* Fix subpage nav full-width alignment */
body.not-home .wp-site-blocks > header .wp-block-group.alignwide {
  max-width: 100% !important;
  width: 100% !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
}
body.not-home .wp-site-blocks > header .wp-block-group.is-layout-flex.alignwide {
  justify-content: space-between !important;
  padding: 0 32px !important;
}

/* ── Subpage logo size (match homepage 36px) ────────────────────────── */
.wp-block-site-logo {
  flex-shrink: 0 !important;
  width: 36px !important;
  height: 36px !important;
}
.wp-block-site-logo img {
  height: 36px !important;
  width: 36px !important;
  max-width: 36px !important;
}

/* ── Homepage logo filter (red -> blue) + size ──────────────────────── */
.pm-nav__logo img {
  filter: hue-rotate(215deg) saturate(1.2) brightness(1.1);
  height: 36px;
  width: auto;
}

/* ── Subpage logo filter (red -> blue) ──────────────────────────────── */
.wp-block-site-logo img,
.custom-logo-link .custom-logo {
  filter: hue-rotate(215deg) saturate(1.2) brightness(1.1);
}

/* ── Nav text sizes (bigger menu) ──────────────────────────────────── */
/* Homepage nav */
.pm-nav__logo {
  font-size: 22px !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 12px !important;
}
.pm-nav__logo span {
  margin: 0 -4px;
}
.pm-nav__links a {
  font-size: 20px !important;
}
.pm-nav__inner {
  height: 72px !important;
}

/* Subpage nav */
body:not(.home) .wp-site-blocks > header .wp-block-site-title a {
  font-size: 22px !important;
}
body:not(.home) .wp-site-blocks > header .wp-block-navigation a {
  font-size: 20px !important;
}
body:not(.home) .wp-site-blocks > header .wp-block-navigation .wp-block-navigation__container {
  gap: 28px !important;
}
body:not(.home) .wp-site-blocks > header {
  min-height: 72px !important;
}
body:not(.home) .wp-site-blocks > header .wp-block-group {
  min-height: 72px !important;
}

/* ── Solutions (delivery) page: cover block → plain image style ──────── */
.page-id-643 .wp-block-cover__inner-container {
  display: none !important;
}
.page-id-643 .wp-block-cover {
  min-height: 0 !important;
  height: auto !important;
  border-radius: 12px !important;
  overflow: hidden !important;
  max-width: 860px !important;
  margin-left: auto !important;
  margin-right: auto !important;
}
.page-id-643 .wp-block-cover__image-background {
  position: relative !important;
  height: auto !important;
  width: 100% !important;
  object-fit: cover !important;
}