/* =========================================================
   Ward & Partners — Shared Stylesheet
   Brand palette per official guidelines:
   - Pantone Cool Grey 11 C  → #414042
   - Pantone Cool Grey 7 C   → #8A8C8E
   Wordmark font: Miriam Libre Bold (UPPERCASE)
   ========================================================= */

:root {
  /* === Brand greys (from datasheet) === */
  --grey-11:   #414042;   /* Cool Grey 11 C — dark, primary */
  --grey-7:    #8A8C8E;   /* Cool Grey 7 C — mid, accent */
  --grey-11-soft: #2C2B2D;  /* slightly deeper for hovers/footer */
  --grey-11-tint: #5A595B;  /* lighter tint of dark */

  /* Neutrals (supporting palette, kept neutral to match the mono brand) */
  --ink-900:  #1B1B1D;
  --ink-800:  #2C2B2D;
  --ink-700:  #414042;     /* = brand dark */
  --ink-600:  #5A595B;
  --ink-500:  #8A8C8E;     /* = brand mid */
  --ink-400:  #A8A8AA;
  --ink-300:  #C9C9CB;
  --ink-200:  #E4E4E5;
  --ink-100:  #F1F1F2;
  --ink-50:   #F8F8F9;
  --white:    #FFFFFF;

  /* Tokens */
  --bg:           var(--white);
  --bg-soft:      var(--ink-50);
  --text:         var(--grey-11);
  --text-muted:   var(--ink-600);
  --text-subtle:  var(--grey-7);
  --border:       var(--ink-200);
  --border-strong:var(--ink-300);

  --container: 1200px;
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 16px;
  --radius-pill: 999px;

  --shadow-sm: 0 1px 2px rgba(27,27,29,.04), 0 1px 3px rgba(27,27,29,.06);
  --shadow-md: 0 4px 6px -1px rgba(27,27,29,.06), 0 2px 4px -1px rgba(27,27,29,.04);
  --shadow-lg: 0 20px 25px -5px rgba(27,27,29,.08), 0 10px 10px -5px rgba(27,27,29,.04);
  --shadow-xl: 0 25px 50px -12px rgba(27,27,29,.20);

  --font-sans:   'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  --font-mono:   'JetBrains Mono', ui-monospace, 'SF Mono', Menlo, Consolas, monospace;

  --transition: 200ms cubic-bezier(.4,0,.2,1);
}

/* =================== Reset =================== */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
img, svg { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }
h1, h2, h3, h4 { margin: 0; line-height: 1.15; letter-spacing: -0.02em; color: var(--grey-11); }
p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }

/* =================== Layout =================== */
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}
.section { padding: 96px 0; }
.section-sm { padding: 64px 0; }
.section-soft { background: var(--bg-soft); }
.section-dark { background: var(--grey-11); color: var(--ink-200); }
.section-dark h1, .section-dark h2, .section-dark h3 { color: var(--white); }

/* =================== Typography =================== */
.eyebrow {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--grey-7);
  margin-bottom: 16px;
}
.section-dark .eyebrow { color: var(--ink-300); }

h1, .h1 { font-size: clamp(2.25rem, 4.5vw, 3.75rem); font-weight: 700; }
h2, .h2 { font-size: clamp(1.875rem, 3.5vw, 2.5rem); font-weight: 700; }
h3, .h3 { font-size: 1.25rem; font-weight: 600; }
.lead { font-size: clamp(1.05rem, 1.3vw, 1.25rem); color: var(--text-muted); line-height: 1.65; }

/* =================== Buttons =================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 24px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 0.95rem;
  border: 1px solid transparent;
  transition: all var(--transition);
  white-space: nowrap;
  letter-spacing: 0.01em;
}
.btn-primary {
  background: var(--grey-11);
  color: var(--white);
  border-color: var(--grey-11);
}
.btn-primary:hover { background: var(--grey-11-soft); border-color: var(--grey-11-soft); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-accent {
  background: var(--white);
  color: var(--grey-11);
  border-color: var(--white);
}
.btn-accent:hover { background: var(--ink-100); border-color: var(--ink-100); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-ghost {
  background: transparent;
  color: var(--grey-11);
  border-color: var(--border-strong);
}
.btn-ghost:hover { background: var(--ink-100); border-color: var(--ink-400); }
.section-dark .btn-ghost,
.cta-band .btn-ghost,
.footer .btn-ghost { color: var(--white); border-color: rgba(255,255,255,.25); }
.section-dark .btn-ghost:hover,
.cta-band .btn-ghost:hover,
.footer .btn-ghost:hover { background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.5); color: var(--white); }
.btn .arrow { transition: transform var(--transition); }
.btn:hover .arrow { transform: translateX(3px); }

/* =================== Navigation =================== */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255,255,255,.88);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--border);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 92px;
}
.nav-brand {
  display: inline-flex;
  align-items: center;
  color: var(--grey-11);
}
.nav-brand img.brand-logo {
  width: auto;
  height: 52px;
  display: block;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 36px;
}
.nav-links a {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--ink-600);
  transition: color var(--transition);
}
.nav-links a:hover, .nav-links a.active { color: var(--grey-11); }
.nav-cta {
  margin-left: 8px;
  color: var(--white) !important;
  background: var(--grey-11);
  border-color: var(--grey-11);
}
.nav-cta:hover { color: var(--white) !important; background: var(--grey-11-soft); border-color: var(--grey-11-soft); }

.nav-toggle {
  display: none;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 8px 10px;
}
.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--ink-700);
  margin: 4px 0;
}

@media (max-width: 860px) {
  .nav-inner { height: 76px; }
  .nav-brand img.brand-logo { height: 42px; }
  .nav-links {
    display: none;
    position: absolute;
    top: 76px; left: 0; right: 0;
    flex-direction: column;
    align-items: flex-start;
    background: var(--white);
    padding: 16px 24px;
    border-bottom: 1px solid var(--border);
    gap: 16px;
  }
  .nav-links.open { display: flex; }
  .nav-toggle { display: block; }
  .nav-cta { display: none; }
}

/* =================== Hero =================== */
.hero {
  position: relative;
  padding: 120px 0 96px;
  background:
    radial-gradient(900px 500px at 90% -10%, rgba(138,140,142,.18), transparent 60%),
    radial-gradient(900px 500px at 5% 110%, rgba(65,64,66,.06), transparent 60%),
    var(--bg);
  overflow: hidden;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 72px;
  align-items: center;
}
.hero h1 { margin-bottom: 24px; }
.hero .lead { margin-bottom: 32px; max-width: 560px; }
.hero-ctas { display: flex; gap: 12px; flex-wrap: wrap; }
.hero-meta {
  margin-top: 40px;
  display: flex;
  gap: 32px;
  flex-wrap: wrap;
  color: var(--text-subtle);
  font-size: 0.9rem;
}
.hero-meta .dot { color: var(--grey-11); margin-right: 8px; }

@media (max-width: 960px) {
  .hero { padding: 80px 0 64px; }
  .hero-grid { grid-template-columns: 1fr; gap: 48px; }
}

/* Code card on the right side of hero */
.code-card {
  background: var(--grey-11);
  border-radius: var(--radius-lg);
  padding: 28px;
  font-family: var(--font-mono);
  font-size: 13px;
  line-height: 1.7;
  color: var(--ink-200);
  box-shadow: var(--shadow-xl);
  position: relative;
  border: 1px solid rgba(255,255,255,.05);
}
.code-card::before {
  content: '';
  position: absolute;
  top: 14px; left: 18px;
  width: 10px; height: 10px;
  border-radius: 50%;
  background: rgba(255,255,255,.25);
  box-shadow: 16px 0 0 rgba(255,255,255,.18), 32px 0 0 rgba(255,255,255,.12);
}
.code-card pre { margin: 28px 0 0; white-space: pre-wrap; }
.code-card .k { color: #d8a4f9; }
.code-card .s { color: #c4dffd; }
.code-card .c { color: #8c8c8e; font-style: italic; }
.code-card .n { color: #f0f0f0; font-weight: 600; }
.code-card .v { color: #ffd8a2; }

/* =================== Trust strip =================== */
.trust {
  padding: 48px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.trust-label {
  text-align: center;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.20em;
  text-transform: uppercase;
  color: var(--text-subtle);
  margin-bottom: 28px;
}
.trust-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 16px;
  align-items: center;
}
.tech-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 16px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 0.92rem;
  color: var(--ink-600);
  background: var(--white);
  border: 1px solid var(--border);
  transition: all var(--transition);
  letter-spacing: 0.01em;
}
.tech-badge:hover { border-color: var(--grey-11); color: var(--grey-11); transform: translateY(-2px); box-shadow: var(--shadow-sm); }
.tech-badge .tag {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--grey-7);
}
@media (max-width: 860px) {
  .trust-grid { grid-template-columns: repeat(3, 1fr); gap: 12px; }
}

/* =================== Section headers =================== */
.section-head {
  max-width: 720px;
  margin: 0 auto 64px;
  text-align: center;
}
.section-head h2 { margin-bottom: 16px; }

/* =================== Cards / Services =================== */
.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}
@media (max-width: 960px) { .cards { grid-template-columns: 1fr; } }

.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 32px;
  transition: all var(--transition);
  position: relative;
  overflow: hidden;
}
.card:hover { border-color: var(--grey-11); transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.card-icon {
  width: 48px; height: 48px;
  border-radius: var(--radius-sm);
  background: var(--grey-11);
  display: grid; place-items: center;
  color: var(--white);
  margin-bottom: 20px;
}
.card h3 { margin-bottom: 12px; }
.card p { color: var(--text-muted); margin-bottom: 20px; }
.card .tags {
  display: flex; flex-wrap: wrap; gap: 8px;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}
.tag-pill {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  background: var(--ink-100);
  color: var(--ink-700);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
}

/* =================== Service deep section =================== */
.service-block {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 72px;
  align-items: center;
  padding: 80px 0;
}
.service-block + .service-block { border-top: 1px solid var(--border); }
.service-block.reverse > :first-child { order: 2; }
@media (max-width: 960px) {
  .service-block, .service-block.reverse > :first-child { grid-template-columns: 1fr; gap: 32px; order: initial; }
}
.service-block h2 { margin-bottom: 16px; }
.service-block .feature-list {
  margin-top: 24px;
  display: grid;
  gap: 16px;
}
.feature-item {
  display: flex;
  gap: 14px;
  align-items: flex-start;
}
.feature-item .check {
  flex-shrink: 0;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: var(--ink-100);
  color: var(--grey-11);
  display: grid; place-items: center;
  margin-top: 2px;
  font-weight: 700;
  font-size: 12px;
}
.feature-item strong { display: block; color: var(--grey-11); margin-bottom: 2px; }
.feature-item span { color: var(--text-muted); font-size: 0.95rem; }

.service-visual {
  background: var(--grey-11);
  border-radius: var(--radius-lg);
  padding: 36px;
  color: var(--ink-200);
  box-shadow: var(--shadow-xl);
  position: relative;
  overflow: hidden;
}
.service-visual::after {
  content: '';
  position: absolute;
  top: -50%; right: -30%;
  width: 400px; height: 400px;
  background: radial-gradient(circle, rgba(138,140,142,.20), transparent 60%);
  pointer-events: none;
}
.diagram {
  display: grid;
  gap: 12px;
  position: relative;
  z-index: 1;
}
.diagram-row {
  display: flex; gap: 12px; align-items: stretch;
}
.diagram-box {
  flex: 1;
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.10);
  border-radius: var(--radius-sm);
  padding: 14px;
  font-family: var(--font-mono);
  font-size: 12px;
}
.diagram-box .label { color: var(--ink-300); font-size: 10px; text-transform: uppercase; letter-spacing: 0.12em; margin-bottom: 6px; }
.diagram-box .val { color: var(--white); font-weight: 600; }
.diagram-arrow {
  text-align: center;
  color: var(--ink-500);
  font-size: 14px;
  margin: 4px 0;
}

/* =================== Why us / stats =================== */
.why-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}
@media (max-width: 860px) { .why-grid { grid-template-columns: 1fr; } }
.why-item h3 { color: var(--white); margin-bottom: 12px; }
.why-item p { color: var(--ink-300); }
.why-item .num {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--ink-300);
  margin-bottom: 16px;
  letter-spacing: 0.10em;
}

/* =================== CTA band =================== */
.cta-band {
  background: var(--grey-11);
  border-radius: var(--radius-lg);
  padding: 64px 56px;
  text-align: center;
  color: var(--white);
  position: relative;
  overflow: hidden;
}
.cta-band::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(700px 250px at 20% 0%, rgba(138,140,142,.22), transparent 70%),
    radial-gradient(500px 200px at 80% 100%, rgba(255,255,255,.04), transparent 70%);
  pointer-events: none;
}
.cta-band > * { position: relative; z-index: 1; }
.cta-band h2 { color: var(--white); margin-bottom: 12px; }
.cta-band p { color: var(--ink-300); margin-bottom: 28px; max-width: 620px; margin-left: auto; margin-right: auto; }
.cta-actions { display: inline-flex; gap: 12px; flex-wrap: wrap; justify-content: center; }
@media (max-width: 640px) { .cta-band { padding: 40px 24px; } }

/* =================== Footer =================== */
.footer {
  background: var(--grey-11);
  color: var(--ink-300);
  padding: 64px 0 32px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px;
  padding-bottom: 48px;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
@media (max-width: 860px) {
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
}
.footer-brand .nav-brand img.brand-logo { height: 44px; }
.footer-brand p { margin-top: 20px; color: var(--ink-300); max-width: 360px; font-size: 0.95rem; }
.footer h4 { color: var(--white); font-size: 0.875rem; text-transform: uppercase; letter-spacing: 0.12em; margin-bottom: 16px; font-weight: 600; }
.footer ul li { margin-bottom: 10px; }
.footer ul a { color: var(--ink-300); transition: color var(--transition); font-size: 0.95rem; }
.footer ul a:hover { color: var(--white); }
.footer-bottom {
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 0.875rem;
  color: var(--ink-400);
}

/* =================== Contact / Forms =================== */
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
@media (max-width: 640px) { .form-grid { grid-template-columns: 1fr; } }
.form-field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 16px; }
.form-field label {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--ink-700);
}
.form-field input, .form-field textarea, .form-field select {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  font: inherit;
  background: var(--white);
  color: var(--grey-11);
  transition: border-color var(--transition), box-shadow var(--transition);
}
.form-field textarea { min-height: 140px; resize: vertical; }
.form-field input:focus, .form-field textarea:focus, .form-field select:focus {
  outline: none;
  border-color: var(--grey-11);
  box-shadow: 0 0 0 3px rgba(65,64,66,.10);
}
.form-note { font-size: 0.85rem; color: var(--text-subtle); margin-top: 8px; }

.contact-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 64px;
  align-items: start;
}
@media (max-width: 960px) { .contact-grid { grid-template-columns: 1fr; gap: 40px; } }

.contact-info-card {
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 32px;
}
.contact-info-card h3 { margin-bottom: 20px; }
.contact-info-item {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
}
.contact-info-item:last-child { border-bottom: none; }
.contact-info-item .ico {
  flex-shrink: 0;
  width: 36px; height: 36px;
  border-radius: var(--radius-sm);
  background: var(--white);
  border: 1px solid var(--border);
  display: grid; place-items: center;
  color: var(--grey-11);
}
.contact-info-item .label { font-size: 0.8rem; color: var(--text-subtle); text-transform: uppercase; letter-spacing: 0.10em; margin-bottom: 2px; }
.contact-info-item .val { font-weight: 600; color: var(--grey-11); }
.contact-info-item .val a:hover { color: var(--grey-11-soft); text-decoration: underline; }

/* =================== Page header (interior pages) =================== */
.page-header {
  padding: 88px 0 56px;
  background:
    radial-gradient(700px 300px at 85% 0%, rgba(138,140,142,.14), transparent 60%),
    var(--bg-soft);
  border-bottom: 1px solid var(--border);
}
.page-header .container { max-width: 820px; }
.page-header h1 { margin-bottom: 16px; }
.page-header .lead { max-width: 640px; }
