/* UK Local SEO — redesign. Brand: Helvetica Now, #FDF800 / #FB4E4E / #0D0D0D. */

@font-face {
  font-family: "Helvetica Now";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("fonts/HelveticaNowVar.woff2") format("woff2"),
       url("fonts/HelveticaNowVar.ttf") format("truetype");
}

:root {
  --yellow: #FDF800;
  --yellow-deep: #f0eb00;
  --coral: #FB4E4E;
  --coral-ink: #DC2F2F;   /* accessible on white for text-size use */
  --ink: #0D0D0D;
  --ink-2: #3a3a3a;
  --muted: #5d5d5d;
  --hairline: #dddddd;
  --bg: #ffffff;
  --bg-light: #F0F0F0;
  --bg-dark: #1A1A1A;
  --radius: 16px;
  --content: 1110px;
  --wide: 1310px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "Helvetica Now", "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-weight: 330;
  font-size: clamp(1rem, 0.95rem + 0.3vw, 1.1rem);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

::selection { background: var(--yellow); color: #000; }
body { caret-color: var(--coral); }

:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
  border-radius: 4px;
}
.btn:focus-visible { outline-offset: 4px; border-radius: 60px; }

* { scrollbar-width: thin; scrollbar-color: #c4c4c4 transparent; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: #c4c4c4; border-radius: 6px; border: 2px solid var(--bg); }
::-webkit-scrollbar-track { background: transparent; }

a {
  color: var(--ink);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  transition: color 120ms ease-out, text-decoration-color 120ms ease-out;
}
a:hover { color: var(--coral-ink); text-decoration-thickness: 2px; }

h1, h2, h3, h4 {
  font-weight: 500;
  line-height: 1.05;
  margin: 0 0 0.5em;
  text-wrap: balance;
}
h1 { font-size: clamp(2.7rem, 6.5vw, 5.6rem); letter-spacing: -0.03em; line-height: 1.08; }
h2 { font-size: clamp(2.2rem, 4.5vw, 4rem); letter-spacing: -0.025em; }
h3 { font-size: clamp(1.45rem, 2.2vw, 2rem); letter-spacing: -0.015em; }

p { margin: 0 0 1em; max-width: 68ch; }

/* highlighter stripe behind the lower half of the glyphs, not the full line box */
mark {
  background-color: transparent;
  background-image: linear-gradient(var(--yellow), var(--yellow));
  background-size: 100% 0.48em;
  background-position: 0 76%;
  background-repeat: no-repeat;
  color: var(--ink);
  padding: 0 0.12em;
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
}

.wrap { max-width: var(--content); margin: 0 auto; padding: 0 24px; }
.wrap--wide { max-width: var(--wide); }

/* ---------- header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid transparent;
  transition: border-color 160ms ease-out, box-shadow 160ms ease-out;
}
.site-header.is-stuck {
  border-bottom-color: var(--hairline);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.05);
}
.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding-top: 18px;
  padding-bottom: 18px;
}
.wordmark {
  font-size: 1.35rem;
  font-weight: 560;
  letter-spacing: -0.02em;
  text-decoration: none;
  white-space: nowrap;
}
.wordmark:hover { color: var(--ink); }
.wordmark .dot { color: transparent; position: relative; }
.wordmark .dot::before {
  content: "";
  position: absolute;
  left: 0.06em; bottom: 0.09em;
  width: 0.34em; height: 0.34em;
  border-radius: 50%;
  background: var(--yellow);
  border: 2px solid var(--ink);
}
.site-nav { display: flex; align-items: center; gap: 32px; }
.site-nav a { text-decoration: none; font-weight: 460; font-size: 0.95rem; }
.site-nav a:hover { text-decoration: underline; text-decoration-thickness: 2px; text-decoration-color: var(--yellow); }

/* ---------- buttons ---------- */

.btn {
  display: inline-block;
  border-radius: 60px;
  padding: 15px 30px;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 560;
  line-height: 1.2;
  letter-spacing: 0;
  text-decoration: none;
  cursor: pointer;
  border: 2px solid transparent;
  transition: transform 140ms cubic-bezier(0.2, 0.9, 0.3, 1), box-shadow 140ms ease-out, background 140ms ease-out;
}
.btn--yellow { background: var(--yellow); color: #000; border-color: var(--yellow); }
.btn--yellow:hover { background: var(--yellow-deep); color: #000; transform: translateY(-1px); box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12); }
.btn--outline { background: transparent; color: currentColor; border-color: currentColor; }
.btn--outline:hover { color: currentColor; transform: translateY(-1px); box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08); }
.btn--dark { background: var(--ink); color: #fff; border-color: var(--ink); }
.btn--dark:hover { background: #000; color: #fff; transform: translateY(-1px); box-shadow: 0 10px 24px rgba(0, 0, 0, 0.22); }
.btn--sm { padding: 10px 22px; font-size: 0.88rem; }

/* ---------- hero ---------- */

.hero { padding: clamp(64px, 10vw, 128px) 0 clamp(56px, 8vw, 104px); }
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 4fr);
  gap: clamp(32px, 5vw, 80px);
  align-items: center;
}
.hero-art { max-width: 100%; height: auto; }
.hero h1 { max-width: 17ch; margin-bottom: 28px; }
.hero .lede { font-size: clamp(1.1rem, 1rem + 0.6vw, 1.35rem); max-width: 52ch; }
.hero .cta-row { display: flex; flex-wrap: wrap; gap: 14px; margin: 36px 0 44px; }
.hero .proof {
  font-size: 0.95rem;
  color: var(--muted);
  max-width: 62ch;
  border-top: 1px solid var(--hairline);
  padding-top: 20px;
}
.hero .proof strong { color: var(--ink); font-weight: 560; }

/* ---------- section shell ---------- */

.band { padding: clamp(64px, 9vw, 120px) 0; }
.band--light { background: var(--bg-light); }
.band--yellow { background: var(--yellow); }
.band-head { margin-bottom: clamp(36px, 5vw, 64px); }
.band-head p { font-size: clamp(1.05rem, 1rem + 0.4vw, 1.3rem); font-weight: 260; max-width: 46ch; }

/* ---------- case studies ---------- */

.case {
  background: var(--bg);
  border-radius: var(--radius);
  padding: clamp(28px, 4vw, 56px);
  margin-bottom: clamp(24px, 3vw, 40px);
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: clamp(28px, 4vw, 64px);
  align-items: center;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}
.case:last-child { margin-bottom: 0; }
.case--flip .case-body { order: 2; }
.case--flip .case-figure { order: 1; }

.case-kind { color: var(--muted); font-size: 0.95rem; margin: -4px 0 18px; }
.case-kind a { color: inherit; }
.case-body h3 { margin-bottom: 6px; }
.case-body > p { font-size: 1rem; }

.case-stats { margin: 24px 0 0; }
.case-stats > div {
  display: flex;
  align-items: baseline;
  gap: 16px;
  padding: 13px 0;
  border-top: 1px solid var(--hairline);
}
.case-stats .n {
  font-size: clamp(1.5rem, 2vw, 1.9rem);
  font-weight: 560;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  min-width: 5.4ch;
}
.case-stats .d { color: var(--ink-2); font-size: 0.95rem; line-height: 1.45; }

.case-figure { min-width: 0; }
.chart { margin: 0; }
.chart svg { display: block; width: 100%; height: auto; }
.chart-title { font-size: 0.95rem; font-weight: 500; margin-bottom: 14px; }
.chart-src { color: var(--muted); font-size: 0.8rem; margin-top: 12px; }

.chart .bar { fill: var(--ink); }
.chart .bar--part { fill: url(#hatch); stroke: var(--ink); stroke-width: 1; }
.chart .gridline { stroke: #e3e3e3; stroke-width: 1; }
.chart .baseline { stroke: #bdbdbd; stroke-width: 1; }
.chart .axis-label { fill: var(--muted); font-size: 11px; font-variant-numeric: tabular-nums; }
.chart .data-label { fill: var(--ink); font-size: 11.5px; font-weight: 560; font-variant-numeric: tabular-nums; }
.chart .anno { fill: #C42222; font-size: 11.5px; font-weight: 560; }
.chart .anno-line { stroke: var(--coral); stroke-width: 1.5; }
.chart .line { stroke: var(--ink); stroke-width: 2; fill: none; stroke-linejoin: round; stroke-linecap: round; }
.chart .area { fill: var(--yellow); opacity: 0.55; }
.chart .hover-dot { fill: var(--ink); stroke: #fff; stroke-width: 2; r: 5; opacity: 0; }
.chart .hit { fill: transparent; }
.chart .window { fill: var(--yellow); opacity: 0.35; }
.chart .window-label { fill: var(--ink); font-size: 11px; font-weight: 560; font-variant-numeric: tabular-nums; }

/* keyword position plot (Field Cottage) */
.kw-plot { display: grid; gap: 0; }
.kw-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
  gap: 16px;
  align-items: center;
  padding: 11px 0;
  border-top: 1px solid var(--hairline);
}
.kw-row:first-child { border-top: 0; padding-top: 0; }
.kw-q { font-size: 0.92rem; line-height: 1.35; color: var(--ink-2); }
.kw-q em { font-style: normal; font-weight: 500; color: var(--ink); }
.kw-track { position: relative; height: 26px; }
.kw-zone {
  position: absolute; inset: 4px auto 4px 0;
  width: 50%;
  background: var(--yellow);
  opacity: 0.5;
  border-radius: 4px;
}
.kw-dot {
  position: absolute; top: 50%;
  width: 12px; height: 12px;
  border-radius: 50%;
  background: var(--ink);
  transform: translate(-50%, -50%);
}
.kw-pos {
  position: absolute; top: 50%;
  transform: translate(10px, -50%);
  font-size: 0.82rem; font-weight: 560;
  font-variant-numeric: tabular-nums;
}
.kw-scale-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
  gap: 16px;
  padding-top: 8px;
}
.kw-scale {
  position: relative;
  height: 1.2em;
  font-size: 0.75rem; color: var(--muted);
}
.kw-scale span { position: absolute; top: 0; white-space: nowrap; }
.kw-scale .s-1 { left: 0; }
.kw-scale .s-10 { left: 50%; transform: translateX(-50%); }
.kw-scale .s-20 { right: 0; }
.kw-legend { color: var(--muted); font-size: 0.8rem; margin-top: 10px; }
.kw-legend .swatch {
  display: inline-block; width: 10px; height: 10px;
  background: var(--yellow); opacity: 0.6; border-radius: 3px;
  margin-right: 6px; vertical-align: baseline;
}

/* shipped list (UK Brewery Tours) */
.ship-list { list-style: none; margin: 0; padding: 0; }
.ship-list li {
  padding: 14px 0 14px 34px;
  border-top: 1px solid var(--hairline);
  position: relative;
  font-size: 0.98rem;
  color: var(--ink-2);
}
.ship-list li:first-child { border-top: 0; }
.ship-list li strong { color: var(--ink); font-weight: 540; }
.ship-list li svg { position: absolute; left: 2px; top: 17px; }

/* ---------- AI expertise ---------- */

.ai-grid {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 4fr);
  gap: clamp(32px, 5vw, 80px);
  align-items: center;
}
.ai-art { max-width: 100%; height: auto; }
.ai-list { max-width: 62rem; }
.ai-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2fr);
  gap: 16px clamp(24px, 4vw, 64px);
  border-top: 1px solid var(--hairline);
  padding: 28px 0;
}
.ai-row h3 { font-size: 1.25rem; margin: 0; }
.ai-row p { color: var(--ink-2); font-size: 0.98rem; margin: 0; }

/* ---------- services ---------- */

.services { display: grid; grid-template-columns: 1fr 1fr; gap: 0 clamp(40px, 6vw, 96px); }
.service { border-top: 1px solid var(--hairline); padding: 26px 0 30px; }
.service h3 { font-size: 1.25rem; margin-bottom: 8px; }
.service p { color: var(--ink-2); font-size: 0.98rem; margin: 0; }

/* ---------- trial band ---------- */

.band--yellow h2 { max-width: 16ch; }
.band--yellow .trial-grid {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: clamp(28px, 5vw, 80px);
  align-items: center;
}
.band--yellow p { color: var(--ink); }
.band--yellow .fine { font-size: 0.95rem; }
.trial-cta { display: flex; flex-direction: column; align-items: flex-start; gap: 14px; }
.trial-cta .note { font-size: 0.88rem; margin: 0; }

/* ---------- contact ---------- */

.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 6fr) minmax(0, 5fr);
  gap: clamp(32px, 5vw, 80px);
  align-items: start;
}
.contact-email {
  font-size: clamp(1.3rem, 1.1rem + 1.2vw, 2rem);
  font-weight: 500;
  letter-spacing: -0.01em;
  word-break: break-word;
}
.contact-art { max-width: min(340px, 80%); height: auto; margin-top: 28px; }
.contact-aside { border-top: 1px solid var(--hairline); }
.contact-aside div { padding: 16px 0; border-bottom: 1px solid var(--hairline); }
.contact-aside .k { font-weight: 540; }
.contact-aside p { margin: 2px 0 0; color: var(--ink-2); font-size: 0.95rem; }

/* ---------- footer ---------- */

.site-footer { background: var(--bg-dark); color: #cfcfcf; padding: 56px 0 40px; }
.site-footer .top {
  display: flex; flex-wrap: wrap; gap: 24px;
  align-items: baseline; justify-content: space-between;
  padding-bottom: 28px; margin-bottom: 24px;
  border-bottom: 1px solid #3a3a3a;
}
.site-footer .wordmark { color: #fff; font-size: 1.5rem; }
.site-footer a { color: #e8e8e8; }
.site-footer a:hover { color: var(--yellow); }
.site-footer .clients { font-size: 0.9rem; color: #b5b5b5; max-width: 72ch; }
.site-footer .legal { font-size: 0.8rem; color: #9a9a9a; margin-top: 20px; }
.site-footer ::selection { background: var(--yellow); color: #000; }

/* ---------- case study pages ---------- */

.cs-hero { padding: clamp(48px, 7vw, 96px) 0 clamp(40px, 5vw, 72px); }
.cs-back { font-size: 0.9rem; }
.cs-back a { text-decoration: none; color: var(--muted); }
.cs-back a:hover { color: var(--coral-ink); text-decoration: underline; }
.cs-hero h1 { margin: 18px 0 10px; font-size: clamp(2.4rem, 5vw, 4.4rem); }
.cs-hero .case-kind { margin-bottom: 24px; }
.cs-hero .lede { font-size: clamp(1.05rem, 1rem + 0.5vw, 1.3rem); max-width: 58ch; }
.cs-hero .case-stats { max-width: 46rem; margin-top: 32px; }

.cs-grid {
  display: grid;
  grid-template-columns: minmax(0, 6fr) minmax(0, 5fr);
  gap: clamp(32px, 5vw, 88px);
  align-items: start;
}
.cs-grid > .chart { min-width: 0; }

.q-table-wrap { overflow-x: auto; }
.q-table { width: 100%; border-collapse: collapse; }
.q-table th {
  text-align: left; font-weight: 560; font-size: 0.82rem;
  color: var(--muted); letter-spacing: 0.01em;
  padding: 0 16px 10px 0; border-bottom: 2px solid var(--ink);
  white-space: nowrap;
}
.q-table td {
  padding: 11px 16px 11px 0;
  border-bottom: 1px solid var(--hairline);
  font-size: 0.95rem;
  font-variant-numeric: tabular-nums;
}
.q-table th.num, .q-table td.num { text-align: right; padding-right: 0; padding-left: 20px; }
.q-table td:first-child { font-weight: 460; }
.table-src { color: var(--muted); font-size: 0.8rem; margin-top: 12px; }

.cs-more { border-top: 1px solid var(--hairline); padding: 36px 0 8px; }
.cs-more p { color: var(--muted); font-size: 0.95rem; }
.cs-more a { font-weight: 460; }
.case-more { margin-top: 22px; font-size: 0.95rem; }
.case-more a { font-weight: 500; text-decoration-color: var(--yellow); text-decoration-thickness: 2px; }

@media (max-width: 900px) {
  .cs-grid { grid-template-columns: 1fr; }
}

/* ---------- tooltip ---------- */

.tip {
  position: fixed;
  z-index: 60;
  pointer-events: none;
  background: var(--bg-dark);
  color: #fff;
  font-size: 0.82rem;
  font-weight: 460;
  font-variant-numeric: tabular-nums;
  line-height: 1.4;
  padding: 8px 12px;
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 100ms ease-out, transform 100ms ease-out;
  white-space: nowrap;
}
.tip.on { opacity: 1; transform: translateY(0); }
.tip .t-k { color: #b9b9b9; }

/* ---------- chart draw-in (the one authored motion) ---------- */

.chart[data-anim] .bar,
.chart[data-anim] .bar-hit-label { transform-origin: bottom; transform-box: fill-box; }
.chart.pre .bar { transform: scaleY(0); }
.chart.in .bar {
  animation: grow 700ms cubic-bezier(0.16, 1, 0.3, 1) both;
  animation-delay: calc(var(--i) * 26ms);
}
@keyframes grow { from { transform: scaleY(0); } to { transform: scaleY(1); } }
.chart.pre .line { stroke-dasharray: var(--len); stroke-dashoffset: var(--len); }
.chart.in .line { stroke-dasharray: var(--len); animation: draw 1100ms cubic-bezier(0.33, 1, 0.68, 1) both; }
@keyframes draw { to { stroke-dashoffset: 0; } }
.chart.pre .area, .chart.pre .data-label, .chart.pre .anno, .chart.pre .anno-line, .chart.pre .window, .chart.pre .window-label { opacity: 0; }
.chart.in .area { animation: fadein 500ms 600ms ease-out both; }
.chart.in .data-label, .chart.in .anno, .chart.in .anno-line, .chart.in .window, .chart.in .window-label { animation: fadein 400ms 550ms ease-out both; }
.chart.in .window { animation-name: fadewin; }
@keyframes fadein { from { opacity: 0; } to { opacity: 1; } }
@keyframes fadewin { from { opacity: 0; } to { opacity: 0.35; } }
@media (prefers-reduced-motion: reduce) {
  .chart.pre .bar { transform: none; }
  .chart.pre .line { stroke-dashoffset: 0; }
  .chart.pre .area, .chart.pre .data-label, .chart.pre .anno, .chart.pre .anno-line, .chart.pre .window-label { opacity: 1; }
  .chart.pre .window { opacity: 0.35; }
}

/* ---------- responsive ---------- */

@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-art { max-width: min(320px, 70%); margin: 0 auto; }
  .ai-grid { grid-template-columns: 1fr; }
  .ai-art { max-width: min(320px, 70%); margin: 0 auto; }
  .case { grid-template-columns: 1fr; }
  .case--flip .case-body { order: 1; }
  .case--flip .case-figure { order: 2; }
  .ai-row { grid-template-columns: 1fr; gap: 8px; }
  .services { grid-template-columns: 1fr; }
  .band--yellow .trial-grid { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .site-nav .nav-link { display: none; }
  .hero .cta-row .btn { width: 100%; text-align: center; }
  .kw-row { grid-template-columns: 1fr; gap: 6px; }
  .kw-scale-row { grid-template-columns: 1fr; }
  /* SVG text scales with the viewBox; larger units keep labels legible on phones */
  .chart .axis-label { font-size: 15px; }
  .chart .data-label { font-size: 16px; }
  .chart .anno { font-size: 16px; }
  .chart .window-label { font-size: 15px; }
}
