/* Harrogate Self Defence. One stylesheet for the whole site.
   Breakpoints: 991px (tablet), 767px (mobile), 479px (small mobile). */

/* ---------- Tokens ---------- */
:root {
  --font-body: "Inter", system-ui, sans-serif;
  --font-heading: "Epilogue", var(--font-body);
  --white: #fff;
  --ink: #03060b;
  --green: #0b3d2e;
  --green-dark: #083024;
  --radius: 16px;
  --gutter: 5%;
  --max-width: 80rem;
  --section-space: 7rem;
}

/* Each section picks a theme; buttons and borders follow it. */
:root,
.theme-green { --bg: #03120d; --text: var(--white); --border: #fff3; --ghost: #ffffff1a; --ghost-hover: #fff3; }
.theme-black { --bg: #03060b; }
.theme-grey  { --bg: #1c1e23; }
.theme-blue  { --bg: #2e58ac; }
.theme-light { --bg: #ebf0fb; --text: var(--ink); --border: #03060b26; --ghost: #03060b0d; --ghost-hover: #03060b26; }

[class*="theme-"] { background: var(--bg); color: var(--text); }

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }

body {
  margin: 0;
  font: 400 1rem/1.5 var(--font-body);
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
p, ul, h1, h2, h3, h4 { margin: 0; }
p + p, p + ul, ul + p { margin-top: 1.5em; }

h1, h2, h3 { font-weight: 700; line-height: 1.2; }
h1 { font-family: var(--font-body); font-size: 4.5rem; letter-spacing: -0.045rem; }
h2 { font-family: var(--font-heading); font-size: 3.25rem; letter-spacing: -0.0325rem; }
h3 { font-family: var(--font-heading); font-size: 2.25rem; letter-spacing: -0.0225rem; line-height: 1.3; }

:focus-visible { outline: 2px solid #4d65ff; outline-offset: 2px; }

/* ---------- Layout ---------- */
.section { padding: var(--section-space) var(--gutter); }
.container { max-width: var(--max-width); margin-inline: auto; }

.eyebrow { display: block; font-size: 0.875rem; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; margin-bottom: 1rem; }
.section h1, .section h2 { margin-bottom: 1.5rem; }
.lead { font-size: 1.125rem; }
.center { text-align: center; }
.narrow { max-width: 48rem; }
.section-head { max-width: 48rem; margin-bottom: 5rem; }
.center.narrow, .center.section-head { margin-inline: auto; }

/* Tick lists: <ul class="ticks"><li>…</li></ul> */
.ticks { list-style: none; padding: 0; }
.ticks li::before { content: "✔ "; }
.plain { list-style: none; padding: 0; }

/* ---------- Buttons ---------- */
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem; margin-top: 2rem; }
.center .actions { justify-content: center; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  border-radius: 12px;
  font-weight: 500;
  text-align: center;
  text-decoration: none;
  background: var(--white);
  color: var(--ink);
  box-shadow: 0 1px 2px #03060b0d, inset 0 -2px 1px #03060b0d;
  transition: transform 0.2s, background-color 0.2s;
}
.btn:hover { background: #d9d9da; transform: translateY(-2px); }

.btn-ghost { background: var(--ghost); color: var(--text); box-shadow: inset 0 0 0 1px var(--ghost); }
.btn-ghost:hover { background: var(--ghost-hover); }

.btn-green {
  background: var(--green);
  color: var(--white);
  box-shadow: inset 0 -2px 1px #0003, inset 0 32px 24px #ffffff0d, inset 0 1px 1px 1px #ffffff40, 0 1px 2px #03060b26;
}
.btn-green:hover { background: var(--green-dark); }

.btn-link { display: inline-flex; align-items: center; gap: 0.5rem; padding: 0.25rem 0; font-weight: 500; text-decoration: none; }
.btn-link::after { content: "›"; font-size: 1.4em; line-height: 0.7; }

/* Bouncing "scroll down" arrow under a hero */
.scroll-cue { display: inline-flex; width: 3rem; height: 3rem; margin-top: 2.5rem; padding: 0.5rem; border: 1px solid var(--border); border-radius: 50%; animation: bob 2s ease-in-out infinite; }
.scroll-cue:hover { background: var(--ghost); }
@keyframes bob { 50% { transform: translateY(6px); } }
@media (prefers-reduced-motion: reduce) { .scroll-cue { animation: none; } }

/* ---------- Site header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  padding-inline: var(--gutter);
  background: #03060b;
}
.site-header .container {
  max-width: none;
  display: grid;
  grid-template-columns: 1fr minmax(0, 28.5rem) 1fr;
  align-items: center;
  gap: 1rem;
  min-height: 4.5rem;
}
.site-header .btn { justify-self: end; white-space: nowrap; }
.logo img { width: 100%; }
.nav-logo { width: 12rem; }

.site-nav { display: flex; }
.site-nav { gap: 0.25rem; }
.site-nav a { padding: 0.5rem 1rem; border-radius: 8px; text-decoration: none; }
.site-nav a:hover { background: var(--ghost); }
.site-nav a[aria-current="page"] { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 0.4em; }
.nav-logo, .menu-toggle { display: none; }

/* ---------- Home hero ---------- */
.hero { display: grid; grid-template-columns: 0.5fr 1fr; gap: 4rem; }
.hero h1 { font-family: var(--font-heading); font-size: 3.25rem; letter-spacing: -0.0325rem; }
.hero-images { display: grid; grid-template-columns: 1fr 0.75fr; gap: 2rem; align-items: start; }
.hero-images img { width: 100%; border-radius: var(--radius); object-fit: cover; }
.hero-images img:first-child { aspect-ratio: 2 / 3; }
.hero-images img:last-child { aspect-ratio: 1; }

/* ---------- Split: text beside a square image ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem 5rem; align-items: center; }
.split > img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: var(--radius); }
.crop-top { object-position: top; } /* tall photos: keep heads in the square crop */

/* ---------- Card grids ---------- */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4rem 3rem; }
.grid-3 h3 { margin-bottom: 1.5rem; }
.icon { width: 3rem; height: 3rem; margin-bottom: 1.5rem; }

/* ---------- Pricing plans ---------- */
.plans { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; max-width: 64rem; margin-inline: auto; }
.plan {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 2rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.plan header { text-align: center; margin-bottom: 2rem; }
.plan h3 { font-family: var(--font-body); font-size: 1.375rem; line-height: 1.4; letter-spacing: -0.01375rem; }
.plan header p { margin: 0; }
.plan header .price { font-size: 4.5rem; font-weight: 700; line-height: 1.2; letter-spacing: -0.045rem; margin: 0.5rem 0; }
.plan .ticks { display: grid; gap: 1rem; padding-block: 0.5rem; }
.plan .ticks li { display: flex; gap: 1rem; }
.plan .ticks li::before { content: "✓"; }
.plan .btn { margin-top: 2rem; }

/* ---------- Feature cards (pricing) ---------- */
.features { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2rem; }
.card { display: flex; flex-direction: column; border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.card-body { flex: 1; padding: 1.5rem; }
.card img { width: 100%; object-fit: cover; } /* small cards: natural shape (16:9 cut heads off); wide card: fills its height without stretching */
.card .eyebrow { font-size: 0.75rem; margin-bottom: 0.5rem; }
.card h3 { font-size: 1.75rem; line-height: 1.4; letter-spacing: -0.0175rem; margin-bottom: 0.5rem; }
.card .btn-link { margin-top: 1.5rem; }
.card-wide { grid-column: span 2; display: grid; grid-template-columns: 1fr 1fr; }
.card-wide .card-body { display: flex; flex-direction: column; justify-content: center; }
.card-wide img { height: 100%; aspect-ratio: auto; }

/* ---------- FAQ ---------- */
/* Native <details> accordions, no JS */
.faq { max-width: 48rem; margin-inline: auto; border-top: 1px solid var(--border); }
.faq details { border-bottom: 1px solid var(--border); }
.faq summary { display: flex; justify-content: space-between; gap: 1rem; padding: 1.25rem 0; font-size: 1.125rem; font-weight: 600; cursor: pointer; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 1.5rem; line-height: 1; }
.faq details[open] summary::after { content: "–"; }
.faq details > p:last-child { padding-bottom: 1.25rem; }
.faq-more { max-width: 35rem; margin: 5rem auto 0; }
.faq-more h3 { margin-bottom: 1rem; }

/* ---------- Full-width image under a CTA ---------- */
.wide-image { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: var(--radius); margin-top: 5rem; }

/* ---------- Contact ---------- */
.contact-list { display: grid; gap: 1rem; padding-block: 0.5rem; margin-top: 2rem; }
.contact-list li { display: flex; gap: 1rem; align-items: flex-start; }
.contact-list svg { flex: none; width: 1.5rem; height: 1.5rem; }
.split-top { align-items: start; }

/* ---------- Footer ---------- */
.site-footer { padding: 5rem var(--gutter) 2rem; }
.footer-top { display: flex; flex-direction: column; align-items: center; padding-bottom: 5rem; border-bottom: 1px solid var(--border); }
.footer-top img { margin-bottom: 2rem; }
.footer-links { display: flex; justify-content: center; gap: 1.5rem; font-weight: 600; }
.footer-links a { text-decoration: none; }
.footer-contact { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.5rem 1.5rem; margin-top: 1.5rem; font-size: 0.875rem; text-align: center; }
.footer-bottom { padding-top: 2rem; font-size: 0.875rem; }

/* ---------- Tablet ---------- */
@media (max-width: 991px) {
  :root { --section-space: 6rem; }
  h1 { font-size: 3.25rem; }
  h2, .hero h1 { font-size: 2.75rem; }
  h3 { font-size: 1.75rem; }
  .section-head { margin-bottom: 4.5rem; }
  .split { gap: 4rem 3rem; }
  .grid-3 { column-gap: 2rem; }
  .features { grid-template-columns: 1fr 1fr; }
  .split-top { grid-template-columns: 1fr; }
  .site-footer { padding-top: 4.5rem; }
  .footer-top { padding-bottom: 4.5rem; }
  .faq-more, .wide-image { margin-top: 4.5rem; }

  /* Off-canvas menu, opened by js/menu.js toggling body.nav-open */
  .menu-toggle {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 6px;
    width: 48px;
    height: 48px;
    margin-left: -0.5rem;
    padding: 0 12px;
    background: none;
    border: 0;
    cursor: pointer;
  }
  .menu-toggle span { height: 2px; background: var(--text); }
  .site-header .container { grid-template-columns: auto 1fr auto; }
  .logo { justify-self: center; }
  .logo img { width: 100%; max-width: 16rem; }
  .plan header .price { font-size: 3.25rem; }
  .site-nav {
    display: none;
    position: fixed;
    inset: 0 auto 0 0;
    z-index: 2;
    width: 80vw;
    padding: 0 5vw 6.5rem;
    overflow: auto;
    flex-direction: column;
    background: #03060b;
  }
  .site-nav a { padding: 0.75rem 0; font-size: 1.125rem; background: none; }
  .site-nav a[aria-current="page"] { font-weight: 600; }
  .nav-logo { display: block; margin: 2.5rem 0 2rem; }
  .nav-open .site-nav { display: flex; }
  .nav-open::after { content: ""; position: fixed; inset: 0; z-index: 1; background: #00000080; }
}

/* ---------- Mobile ---------- */
@media (max-width: 767px) {
  :root { --section-space: 4rem; }
  h1 { font-size: 2.5rem; }
  h2, .hero h1 { font-size: 2.25rem; }
  h3 { font-size: 1.5rem; line-height: 1.4; }
  .card h3 { font-size: 1.25rem; }
  .plan h3 { font-size: 1.125rem; }
  .plan header .price { font-size: 2.5rem; }
  .lead { font-size: 1rem; }
  .eyebrow { margin-bottom: 0.75rem; }
  .section h1, .section h2 { margin-bottom: 1.25rem; }
  .actions { margin-top: 1.5rem; }
  .section-head { margin-bottom: 3rem; }
  .site-header .container { min-height: 4rem; }
  .site-header .btn { padding: 0.6rem 0.9rem; font-size: 0.875rem; }
  .site-nav { width: 90vw; padding-bottom: 5rem; }
  .hero, .split, .grid-3, .plans { grid-template-columns: 1fr; gap: 3rem; }
  .split > img { order: 1; } /* text first on phones */
  .plan { padding-inline: 1.5rem; }
  .features { gap: 1.5rem; }
  .site-footer { padding-top: 3rem; }
  .footer-top { padding-bottom: 3rem; }
  .footer-links, .footer-contact { flex-direction: column; align-items: center; }
  .footer-bottom { text-align: center; }
  .faq-more, .wide-image { margin-top: 3rem; }
}

/* ---------- Small mobile ---------- */
@media (max-width: 479px) {
  .logo img { max-width: 10rem; }
  .hero-images { gap: 1.5rem; }
  .features { grid-template-columns: 1fr; }
  .card-wide { grid-column: auto; grid-template-columns: 1fr; }
  .card-wide img { aspect-ratio: 16 / 9; }
}
