/* Johnstone & Co. — static rebuild
   Design tokens captured from the live site:
   Inter (body + headings), Archivo (logo wordmark), black on white. */

@import url('https://fonts.googleapis.com/css2?family=Archivo:wght@700;800;900&family=Inter:wght@400;500;600;700&display=swap');

:root {
  --ink: #000;
  --paper: #fff;
  --muted: #555;
  --line: #e5e5e5;
  --maxw: 1240px;
  --pad: 40px;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --brand-font: 'Archivo', var(--font);
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 18px;
  font-weight: 400;
  line-height: 1.6;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}

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

a { color: inherit; }

h1, h2 {
  font-size: 48px;
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 0.5em;
}

h3 {
  font-size: 24px;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -0.02em;
  margin: 0 0 0.4em;
}

p { margin: 0 0 1.2em; }

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

.section { padding: 80px 0; }

/* ---------- Header ---------- */
/* Top padding matches the container's side padding (--pad) so the logo sits
   with equal spacing from the top and left edges. */
.site-header {
  padding: var(--pad) 0;
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.brand {
  font-family: var(--brand-font);
  font-weight: 800;
  font-size: 40px;
  line-height: 0.98;
  letter-spacing: -0.01em;
  text-decoration: none;
  color: var(--ink);
}
.brand span { display: block; }
.brand-logo { height: 58px; width: auto; display: block; }
.content-img { width: 100%; height: auto; margin: 0 0 28px; }
.founder-photo { width: 360px; max-width: 100%; height: auto; margin: 8px 0 20px; }
.logo-row { display: flex; flex-wrap: wrap; align-items: center; gap: 32px; margin: 8px 0 28px; }
.logo-row img { height: 46px; width: auto; opacity: 0.9; }
.img-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin: 8px 0 28px; }
.img-grid img { width: 100%; height: auto; }
@media (max-width: 700px){ .img-grid { grid-template-columns: 1fr; } }

.nav {
  display: flex;
  align-items: center;
  gap: 28px;
  padding-top: 8px;
}
.nav a {
  text-decoration: none;
  font-size: 18px;
  color: var(--ink);
}
.nav a:hover { text-decoration: underline; }

/* dropdown */
.has-sub { position: relative; }
.has-sub > a::after { content: " \25BE"; font-size: 0.7em; }
.submenu {
  position: absolute;
  top: 100%;
  left: 0;
  background: var(--paper);
  border: 1px solid var(--line);
  padding: 10px 0;
  min-width: 220px;
  display: none;
  z-index: 20;
}
.has-sub:hover .submenu { display: block; }
.submenu a { display: block; padding: 8px 20px; white-space: nowrap; }
.submenu a:hover { background: #f5f5f5; text-decoration: none; }

/* mobile nav toggle (hamburger) — CSS-only, works without JS */
.nav-toggle { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; border: 0; clip: rect(0 0 0 0); overflow: hidden; }
.nav-burger {
  display: none;              /* shown only on mobile */
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 34px; height: 34px;
  padding: 5px 4px;
  cursor: pointer;
}
.nav-burger span {
  display: block;
  width: 26px; height: 2px;
  background: var(--ink);
  border-radius: 2px;
  transition: transform .2s ease, opacity .2s ease;
}
.nav-toggle:focus-visible ~ .nav-burger { outline: 2px solid var(--ink); outline-offset: 3px; }
.nav-toggle:checked ~ .nav-burger span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle:checked ~ .nav-burger span:nth-child(2) { opacity: 0; }
.nav-toggle:checked ~ .nav-burger span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero ---------- */
/* Full-bleed hero: image runs to the left viewport edge; copy aligns to the
   centred container's right content edge. */
.hero { padding: 0 0 40px; }
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 56px;
  align-items: stretch;
}
.hero-media img,
.hero-media .ph {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
  object-fit: cover;
}
/* Copy sits at the top next to the square image; only a small right pad. */
.hero-copy {
  padding-right: max(var(--pad), calc((50vw - var(--maxw)) / 2 + var(--pad)));
}
.hero-copy h1 { text-align: center; }
.hero-copy .lead { margin-top: 32px; }
.hero-cta { margin-top: 32px; }
.hero-cta .btn { text-decoration: none; }
.hero-trust { margin-top: 18px; color: var(--muted); font-size: 15px; }

/* ---------- Image placeholder ---------- */
.ph {
  background: repeating-linear-gradient(45deg, #efefef, #efefef 12px, #e7e7e7 12px, #e7e7e7 24px);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #999;
  font-size: 14px;
  text-align: center;
  padding: 12px;
}

/* ---------- Services ---------- */
.services-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 40px;
  margin-top: 40px;
}
.service-item a.service-link {
  font-size: 24px;
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.service-item p { margin-top: 16px; }
.arrow::after { content: " \2197"; }

/* ---------- Testimonials ---------- */
.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
  margin-top: 40px;
}
.testimonial .rule {
  width: 60px; height: 1px; background: var(--ink); margin-bottom: 28px;
}
.testimonial .who { font-weight: 700; text-align: right; }

/* ---------- Insights ---------- */
.insights-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 48px 40px;
  margin-top: 40px;
}
.post-card h3 { font-size: 28px; }
.post-card h3 a { text-decoration: none; }
.post-card h3 a:hover { text-decoration: underline; }
.post-meta {
  font-size: 14px;
  letter-spacing: 0.02em;
  margin: 14px 0 14px;
  color: var(--ink);
}
.post-meta .date { text-transform: uppercase; }
.post-meta .cats { color: var(--muted); }
.post-card p { margin: 0; }

/* ---------- Contact ---------- */
.contact-banner { text-align: center; padding-bottom: 20px; }
/* Full-bleed contact: image runs to the right viewport edge; form aligns to
   the centred container's left content edge. */
.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 56px;
  align-items: center;
}
.contact-copy {
  padding-left: max(var(--pad), calc((20vw - var(--maxw)) / 2 + var(--pad)));
}
.contact-media img,
.contact-media .ph { display: block; width: 100%; height: 720px; object-fit: cover; }

.field { margin-bottom: 20px; }
.field label { display: block; margin-bottom: 8px; font-size: 18px; }
.field input,
.field textarea {
  width: 100%;
  border: 1px solid var(--ink);
  padding: 12px 14px;
  font-family: var(--font);
  font-size: 16px;
  background: #fff;
}
.field textarea { min-height: 160px; resize: vertical; }
.field .help { color: var(--muted); font-size: 16px; margin: 4px 0 12px; }
.btn {
  display: inline-block;
  background: var(--ink);
  color: #fff;
  border: none;
  padding: 14px 34px;
  font-family: var(--font);
  font-size: 18px;
  cursor: pointer;
}
.btn:hover { opacity: 0.85; }

/* ---------- Footer ---------- */
.site-footer { padding: 60px 0; border-top: 1px solid var(--line); }
.site-footer .container {
  display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap;
}
.site-footer .social { display: flex; gap: 20px; }
.site-footer a { text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.credit { color: var(--muted); font-size: 15px; }

/* ---------- Generic content page ---------- */
.page-hero { padding: 20px 0 10px; }
.page-body { max-width: 820px; }
.page-body h2 { font-size: 36px; margin-top: 1.2em; }
.page-body ul { padding-left: 1.2em; }
.page-body li { margin-bottom: 0.5em; }
.page-body a { text-decoration: underline; }
.page-body a:hover { text-decoration: none; }
.page-body .read-more { margin-top: 0.4em; font-weight: 600; }
.page-body .read-more a { text-decoration: none; }
.page-body .read-more a:hover { text-decoration: underline; }

/* ---------- Post / article ---------- */
article .page-hero .post-meta {
  font-size: 14px;
  letter-spacing: 0.02em;
  margin-top: 12px;
}
article .page-hero .post-meta .date { text-transform: uppercase; }
article .page-hero .post-meta .cats,
article .page-hero .post-meta .author { color: var(--muted); }

.page-body ol.numbered { padding-left: 1.2em; }
.page-body ol.numbered li { margin-bottom: 0.8em; }
.form-intro { max-width: 820px; margin-bottom: 24px; }

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; margin: 20px 0 28px; }
.pax-table { border-collapse: collapse; width: 100%; font-size: 16px; }
.pax-table th, .pax-table td { border: 1px solid var(--line); padding: 10px 14px; text-align: left; }
.pax-table th { background: #f5f5f5; font-weight: 600; }
.small { font-size: 14px; color: var(--muted); }

/* PAX clearance table: caption, embedded diagrams + notes */
.pax-caption { font-weight: 700; margin: 6px 0 10px; }
.pax-note { font-style: italic; font-size: 14px; margin: 6px 0; }
.pax-table td img { display: block; max-width: 100%; height: auto; margin-top: 10px; }

/* ---------- Pricing cards ---------- */
.price-cards {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 20px; margin: 24px 0 12px; align-items: stretch;
}
.price-card { display: flex; flex-direction: column; padding: 28px 26px; }
.price-card.c-yellow { background: #ffe97d; }
.price-card.c-lilac  { background: #d1d1e1; }
.price-card.c-blue   { background: #c0ebf1; }
.price-card .pc-name  { font-size: 30px; font-weight: 700; line-height: 1.05; margin: 0; }
.price-card .pc-price { font-size: 34px; font-weight: 800; margin: 2px 0 0; }
.price-card .pc-tier  { font-weight: 700; margin: 16px 0 12px; padding-top: 14px; border-top: 1px solid rgba(0,0,0,.25); }
.price-card .pc-lead  { margin: 16px 0 12px; padding-top: 14px; border-top: 1px solid rgba(0,0,0,.25); }
.price-card ul { padding-left: 1.15em; margin: 0 0 14px; }
.price-card li { margin-bottom: 6px; }
.price-card .pc-note { font-style: italic; color: #333; margin: 4px 0 16px; }
.price-card .see-design { display: inline-block; margin: 0 0 14px; }
.price-card .btn { margin-top: auto; display: block; text-align: center; text-decoration: none; }
@media (max-width: 780px) { .price-cards { grid-template-columns: 1fr; } }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  h1, h2 { font-size: 36px; }
  /* Stack: image full-width on top, copy below with normal gutters. */
  .hero-grid, .contact-grid { grid-template-columns: minmax(0, 1fr); gap: 28px; }
  .hero-copy { padding: 0 var(--pad); }
  .contact-copy { padding: 0 var(--pad); order: 2; }
  .contact-media { order: 1; }
  .hero-media img, .hero-media .ph { height: 380px; }
  .contact-media img, .contact-media .ph { height: 420px; }
  .services-grid { grid-template-columns: 1fr 1fr; }
  .testimonials-grid, .insights-grid { grid-template-columns: 1fr; }
  /* Mobile header: logo left, hamburger right, nav drops below when opened. */
  .site-header .container { flex-wrap: wrap; align-items: center; gap: 0; }
  .nav-burger { display: flex; }
  .nav {
    display: none;
    order: 3;
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding-top: 12px;
  }
  .nav-toggle:checked ~ .nav { display: flex; }
  .nav a { padding: 13px 2px; border-top: 1px solid var(--line); }
  .nav > .has-sub:first-child > a { border-top: 0; }  /* no divider above the first item */
  .nav a:hover { text-decoration: none; }
  .has-sub { position: static; }
  .has-sub > a::after { content: ""; }
  .submenu { position: static; display: block; border: 0; min-width: 0; padding: 0; }
  .submenu a { padding: 11px 2px 11px 20px; border-top: 1px solid var(--line); font-size: 16px; white-space: normal; }
}
@media (max-width: 560px) {
  :root { --pad: 20px; }
  .services-grid { grid-template-columns: 1fr; }
  /* Full-width primary buttons on phones. */
  .hero-cta .btn,
  .contact-form button[type="submit"] { display: block; width: 100%; text-align: center; }
}
