/*
Theme Name: Truvendi
Theme URI: https://www.truvendi.com
Author: Truvendi
Author URI: https://www.truvendi.com
Description: Official WordPress theme for Truvendi, a data science consultancy focused on finding patterns of value with any tool — AI, data science, or statistics. Includes designed Home, About, Services, and Contact page layouts, editable in the block editor, built around the Truvendi brand identity (navy + teal, node-mark logo).
Version: 1.4.0
Requires at least: 6.7
Tested up to: 7.1
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: LICENSE
Text Domain: truvendi
*/

/* ---------- Variables ---------- */
:root {
  --navy: #0B2545;
  --navy-mid: #1B4B7A;
  --teal: #14B8A6;
  --teal-dark: #0B786D; /* darker than the logo's #0E8C7F so text passes WCAG AA on white and tint */
  --teal-bright: #2DD4BF;
  --white: #FFFFFF;
  --ink: #33475B;
  --muted: #62727E;
  --line: #E4E9ED;
  --bg-tint: #F4F7F9;
  --radius: 8px;
  --font-head: 'Helvetica Neue', Arial, sans-serif;
  --font-body: -apple-system, BlinkMacSystemFont, 'Helvetica Neue', Arial, sans-serif;
  --maxw: 1120px;
}

/* ---------- Reset ---------- */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--white);
  font-size: 16px;
  line-height: 1.7;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--teal-dark); text-decoration: none; }
a:hover { color: var(--navy); }
.site-main p a:not(.btn),
.entry-content a:not(.btn) { text-decoration: underline; text-underline-offset: 2px; }
.site-header ul, .site-footer ul { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, h4 {
  font-family: var(--font-head);
  font-weight: 700;
  color: var(--navy);
  line-height: 1.2;
  margin: 0 0 16px 0;
}
h1 { font-size: 44px; letter-spacing: -0.5px; }
h2 { font-size: 30px; letter-spacing: -0.3px; }
h3 { font-size: 19px; }
p { margin: 0 0 16px 0; }
.container {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 28px;
}
.kicker {
  display: block;
  font-family: var(--font-head);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--teal-dark);
  margin-bottom: 14px;
}
.rule {
  height: 3px;
  width: 46px;
  background: var(--teal);
  margin: 0 0 22px 0;
  border-radius: 2px;
}
.section { padding: 88px 0; }
.section.tint { background: var(--bg-tint); }
.section.dark { background: var(--navy); color: rgba(255,255,255,0.85); }
.section.dark h2, .section.dark h3 { color: var(--white); }
.section.dark .kicker { color: var(--teal-bright); }
.section.dark p { color: rgba(255,255,255,0.72); }
.wp-block-group { box-sizing: border-box; }
/*
 * Classic themes wrap each Group block's contents in an inner-container div
 * (in the editor and on the site). Let the children of the layout groups
 * below sit directly in their parent's grid or flex row.
 */
:is(.two-col, .contact-grid, .stat-row, .pillars, .service-row, .process, .contact-row) > .wp-block-group__inner-container { display: contents; }

/* ---------- Buttons ---------- */
.btn,
.wp-block-button .wp-block-button__link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.3px;
  padding: 14px 26px;
  border-radius: var(--radius);
  border: 2px solid transparent;
  cursor: pointer;
  line-height: 1.7;
  text-decoration: none;
  transition: transform 0.12s ease, background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}
.btn:hover,
.wp-block-button .wp-block-button__link:hover { transform: translateY(-1px); }
.btn-primary,
.wp-block-button .wp-block-button__link { background: var(--teal); color: var(--navy); }
.btn-primary:hover,
.wp-block-button .wp-block-button__link:hover { background: var(--teal-dark); color: var(--white); }
.btn-outline,
.wp-block-button.is-style-outline-light .wp-block-button__link { background: transparent; border-color: rgba(255,255,255,0.4); color: var(--white); }
.btn-outline:hover,
.wp-block-button.is-style-outline-light .wp-block-button__link:hover { border-color: var(--white); color: var(--white); background: rgba(255,255,255,0.08); }
.btn-outline-dark,
.wp-block-button.is-style-outline-dark .wp-block-button__link { background: transparent; border-color: var(--navy); color: var(--navy); }
.btn-outline-dark:hover,
.wp-block-button.is-style-outline-dark .wp-block-button__link:hover { background: var(--navy); color: var(--white); }
.wp-block-buttons { display: flex; flex-wrap: wrap; gap: 16px; }
.wp-block-buttons > .wp-block-button { margin: 0; }
.wp-block-buttons.after-list { margin-top: 28px; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255,255,255,0.96);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--line);
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 84px;
}
.site-branding,
.site-branding a { display: flex; align-items: center; gap: 10px; }
.site-branding img { height: 30px; width: auto; }
.site-branding .site-title {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 19px;
  color: var(--navy);
  letter-spacing: 0.2px;
}
.primary-nav { display: flex; align-items: center; gap: 34px; }
.primary-nav ul { display: flex; gap: 34px; align-items: center; }
.primary-nav li a {
  font-family: var(--font-head);
  font-size: 14px;
  font-weight: 700;
  color: var(--navy);
  letter-spacing: 0.2px;
}
.primary-nav li a:hover { color: var(--teal-dark); }

.menu-toggle { display: none; }

/* ---------- Hero ---------- */
.hero {
  background: var(--navy);
  color: var(--white);
  position: relative;
  overflow: hidden;
  padding: 110px 0 100px 0;
}
.hero::before {
  content: "";
  position: absolute;
  top: -40px;
  right: -40px;
  width: 320px;
  height: 320px;
  opacity: 0.14;
  background-image: radial-gradient(circle, #FFFFFF 2px, transparent 2px);
  background-size: 28px 28px;
  pointer-events: none;
}
.hero .container { position: relative; }
.hero .eyebrow {
  font-family: var(--font-head);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--teal-bright);
  margin-bottom: 22px;
}
.hero h1 { color: var(--white); max-width: 780px; font-size: 50px; }
.hero .lede {
  max-width: 640px;
  font-size: 19px;
  color: rgba(255,255,255,0.78);
  margin-bottom: 36px;
}

/* ---------- Pillars / Cards ---------- */
.pillars {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 44px;
}
.pillar-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 32px 28px;
}
.pillars.with-mark .pillar-card::before {
  content: "";
  display: block;
  width: 30px;
  height: 30px;
  margin-bottom: 18px;
  background: url(assets/img/icon-color.svg) center / contain no-repeat;
}
.pillar-card h3 { margin-bottom: 10px; }
.pillar-card p { color: var(--muted); font-size: 14.5px; margin-bottom: 0; }

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

.stat-row { display: flex; gap: 48px; margin-top: 36px; flex-wrap: wrap; }
.stat p { margin: 0; }
.stat .num {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 34px;
  color: var(--teal);
}
.stat .label { font-size: 12.5px; color: rgba(255,255,255,0.65); letter-spacing: 0.5px; text-transform: uppercase; }

.mark-graphic { display: flex; align-items: center; justify-content: center; margin: 0; }
.mark-graphic img { width: 100%; max-width: 340px; height: auto; }

/* ---------- Services list ---------- */
.service-row {
  display: grid;
  grid-template-columns: 60px 1fr;
  gap: 22px;
  padding: 34px 0;
  border-top: 1px solid var(--line);
}
.service-row:last-child { border-bottom: 1px solid var(--line); }
.service-row p.num { margin: 0; }
.service-row .num {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 15px;
  color: var(--teal-dark);
}
.service-row h3 { margin-bottom: 8px; }
.service-row p { color: var(--muted); margin-bottom: 0; max-width: 640px; }

/* ---------- Process steps ---------- */
.process { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; margin-top: 40px; }
.process-step .step-no {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 13px;
  color: var(--navy);
  background: var(--teal);
  width: 30px; height: 30px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  margin: 0 0 16px 0;
}
.process-step h3 { font-size: 16px; margin-bottom: 8px; }
.process-step p { font-size: 13.5px; color: var(--muted); margin-bottom: 0; }

/* ---------- CTA band ---------- */
.cta-band {
  background: var(--navy);
  color: var(--white);
  padding: 70px 0;
  text-align: center;
}
.cta-band h2 { color: var(--white); }
.cta-band p { color: rgba(255,255,255,0.75); max-width: 560px; margin-left: auto; margin-right: auto; }
.cta-band .wp-block-buttons { justify-content: center; margin-top: 26px; }

/* ---------- Contact ---------- */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; }
.contact-card {
  background: var(--bg-tint);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 36px;
}
.contact-row { display: flex; gap: 16px; padding: 16px 0; border-top: 1px solid var(--line); }
.contact-row:first-child { border-top: none; }
.contact-row p { margin: 0; }
.contact-row .label {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--teal-dark);
  width: 110px;
  flex-shrink: 0;
  padding-top: 2px;
}
.contact-row .value { font-size: 15px; color: var(--navy); font-weight: 500; }
.contact-row .value a { color: var(--navy); }
.contact-row .value a:hover { color: var(--teal-dark); }

/* ---------- Page hero (interior pages) ---------- */
.page-hero {
  background: var(--navy);
  color: var(--white);
  padding: 80px 0 64px 0;
}
.page-hero h1 { color: var(--white); margin-bottom: 14px; }
.page-hero .lede { color: rgba(255,255,255,0.75); font-size: 17px; max-width: 620px; margin-bottom: 0; }

/* ---------- Footer ---------- */
.site-footer { background: var(--navy); color: rgba(255,255,255,0.6); padding: 56px 0 30px 0; }
.footer-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding-bottom: 36px;
  margin-bottom: 30px;
  border-bottom: 1px solid rgba(255,255,255,0.12);
  flex-wrap: wrap;
  gap: 30px;
}
.footer-brand { display: flex; align-items: center; gap: 10px; }
.footer-brand img { height: 26px; }
.footer-brand .name { font-family: var(--font-head); font-weight: 700; color: var(--white); font-size: 17px; }
.footer-tag { font-size: 12px; letter-spacing: 2px; text-transform: uppercase; color: var(--teal-bright); margin-top: 6px; }
.footer-nav ul { display: flex; gap: 28px; }
.footer-nav a { color: rgba(255,255,255,0.7); font-size: 14px; font-weight: 500; }
.footer-nav a:hover { color: var(--white); }
.footer-bottom { display: flex; justify-content: space-between; font-size: 12.5px; flex-wrap: wrap; gap: 10px; }
.footer-bottom a { color: rgba(255,255,255,0.6); }

/* ---------- Utilities ---------- */
.text-center { text-align: center; }
.narrow { max-width: 680px; }
.mb-0 { margin-bottom: 0 !important; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  h1 { font-size: 34px; }
  .hero h1 { font-size: 36px; }
  .pillars { grid-template-columns: 1fr; }
  .two-col { grid-template-columns: 1fr; gap: 36px; }
  .process { grid-template-columns: 1fr 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
  .primary-nav,
  .primary-nav ul { gap: 18px; }
  .stat-row { gap: 28px; }
}
@media (max-width: 640px) {
  .container { padding: 0 20px; }
  .section { padding: 60px 0; }
  .primary-nav { display: none; }
  .menu-toggle { display: inline-flex; }
  .process { grid-template-columns: 1fr; }
  .site-header .container { height: 68px; }
}

/* ---------- Mobile nav toggle ---------- */
.menu-toggle {
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  cursor: pointer;
}
.menu-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--navy);
  position: relative;
}
.menu-toggle span::before,
.menu-toggle span::after {
  content: "";
  position: absolute;
  left: 0;
  width: 18px;
  height: 2px;
  background: var(--navy);
}
.menu-toggle span::before { top: -6px; }
.menu-toggle span::after { top: 6px; }

@media (max-width: 640px) {
  .site-header.nav-open .primary-nav {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
    position: absolute;
    top: 68px;
    left: 0;
    right: 0;
    background: var(--white);
    border-bottom: 1px solid var(--line);
    padding: 16px 20px 26px 20px;
  }
  .site-header.nav-open .primary-nav ul {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }
}
