/* ==========================================================================
   Quartz Worktops Weybridge — Granite Revolutions Ltd
   Design tokens
   Colour:  --red (brand red, sampled from client logo), --red-dark (hover),
            --charcoal (near-black), --stone (warm grey body text),
            --paper (warm off-white bg), --line (hairline borders)
   Type:    Space Grotesk (display, geometric/precision) + Inter (body)
   Signature: mitre-cut corner motif — a 45 degree chamfer echoes the actual
              mitred joint used to fabricate stone worktop corners.
   ========================================================================== */

:root {
  --red: #e30613;
  --red-dark: #a30a10;
  --charcoal: #171614;
  --charcoal-soft: #2a2825;
  --stone: #6e6a63;
  --stone-light: #a6a199;
  --paper: #faf9f6;
  --paper-dim: #f1efe9;
  --line: #e4e1db;
  --white: #ffffff;

  --font-display: 'Space Grotesk', 'Arial Narrow', sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;

  --mitre: 22px;
  --container: 1180px;
  --radius: 2px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--charcoal);
  background: var(--paper);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul { margin: 0; padding: 0; list-style: none; }
button { font-family: inherit; cursor: pointer; }

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

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.15;
  margin: 0 0 0.5em;
  letter-spacing: -0.01em;
}
h1 { font-size: clamp(2.1rem, 4.5vw, 3.4rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.3rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; color: var(--charcoal-soft); }
.lede { font-size: 1.15rem; color: var(--stone); }

.eyebrow {
  font-family: var(--font-display);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.78rem;
  color: var(--red);
  font-weight: 600;
  display: inline-block;
  margin-bottom: 0.75em;
}

/* ---- Mitre-cut signature shape ------------------------------------- */
.mitre-tl { clip-path: polygon(var(--mitre) 0, 100% 0, 100% 100%, 0 100%, 0 var(--mitre)); }
.mitre-br { clip-path: polygon(0 0, 100% 0, 100% calc(100% - var(--mitre)), calc(100% - var(--mitre)) 100%, 0 100%); }
.mitre-both { clip-path: polygon(var(--mitre) 0, 100% 0, 100% calc(100% - var(--mitre)), calc(100% - var(--mitre)) 100%, 0 100%, 0 var(--mitre)); }

.divider-seam {
  height: 3px;
  width: 100%;
  background: linear-gradient(90deg, var(--red) 0 60px, var(--line) 60px 100%);
  margin: 0;
}

/* ---- Header ---------------------------------------------------------- */
.site-header {
  background: var(--white);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 100;
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 24px;
  gap: 24px;
}
.header-logo img { height: 42px; width: auto; }
.header-nav { display: flex; gap: 28px; align-items: center; }
.header-nav a {
  font-family: var(--font-display);
  font-size: 0.93rem;
  font-weight: 500;
  color: var(--charcoal);
  padding: 6px 0;
  border-bottom: 2px solid transparent;
  transition: border-color 0.15s ease, color 0.15s ease;
}
.header-nav a:hover, .header-nav a.active { color: var(--red); border-color: var(--red); }
.header-cta {
  display: flex;
  align-items: center;
  gap: 14px;
}
.phone-pill {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--charcoal);
  display: flex;
  align-items: center;
  gap: 6px;
}
.phone-pill svg { width: 16px; height: 16px; fill: var(--red); }
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--red);
  color: var(--white);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.92rem;
  padding: 12px 22px;
  clip-path: polygon(14px 0, 100% 0, 100% calc(100% - 14px), calc(100% - 14px) 100%, 0 100%, 0 14px);
  transition: background 0.15s ease;
  white-space: nowrap;
}
.btn:hover { background: var(--red-dark); }
.btn-outline {
  background: transparent;
  color: var(--charcoal);
  border: 1.5px solid var(--charcoal);
}
.btn-outline:hover { background: var(--charcoal); color: var(--white); }
.btn-sm { padding: 9px 16px; font-size: 0.85rem; }

.mobile-toggle { display: none; }

/* ---- Sticky mobile call button ---------------------------------------- */
.sticky-call {
  display: none;
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 200;
  background: var(--red);
}
.sticky-call a {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: var(--white);
  font-family: var(--font-display);
  font-weight: 600;
  padding: 14px;
  font-size: 1rem;
}
.sticky-call svg { width: 18px; height: 18px; fill: var(--white); }

/* ---- Hero -------------------------------------------------------------- */
.hero {
  background: var(--charcoal);
  color: var(--white);
  position: relative;
  overflow: hidden;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  align-items: center;
  gap: 48px;
  padding: 64px 24px 70px;
}
.hero-copy p { color: #d8d5cf; }
.hero-stats {
  display: flex;
  gap: 32px;
  margin-top: 28px;
  flex-wrap: wrap;
}
.hero-stat .num {
  font-family: var(--font-display);
  font-size: 2.1rem;
  font-weight: 700;
  color: var(--red);
  line-height: 1;
}
.hero-stat .label {
  font-size: 0.82rem;
  color: var(--stone-light);
  margin-top: 4px;
}
.hero-actions { display: flex; gap: 14px; margin-top: 32px; flex-wrap: wrap; }
.hero-image-wrap {
  position: relative;
}
.hero-image-wrap img {
  width: 100%;
  border: 3px solid var(--red);
}
.hero-image-caption {
  position: absolute;
  bottom: -1px; left: -1px;
  background: var(--red);
  color: var(--white);
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 600;
  padding: 8px 14px;
  clip-path: polygon(0 0, 100% 0, 100% 100%, 16px 100%, 0 calc(100% - 16px));
}

/* ---- Sections ------------------------------------------------------- */
section { padding: 72px 0; }
.section-head { max-width: 640px; margin-bottom: 44px; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.bg-dim { background: var(--paper-dim); }
.bg-charcoal { background: var(--charcoal); color: var(--white); }
.bg-charcoal p { color: #d8d5cf; }
.bg-charcoal h2 { color: var(--white); }

/* ---- Bento service grid ------------------------------------------------ */
.bento {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: 190px;
  gap: 16px;
}
.bento-card {
  background: var(--white);
  border: 1px solid var(--line);
  padding: 26px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  transition: transform 0.15s ease, border-color 0.15s ease;
}
.bento-card:hover { transform: translateY(-3px); border-color: var(--red); }
.bento-card.wide { grid-column: span 2; }
.bento-card.tall { grid-row: span 2; }
.bento-card .icon { width: 34px; height: 34px; fill: var(--red); margin-bottom: auto; }
.bento-card h3 { margin-bottom: 6px; }
.bento-card p { font-size: 0.92rem; margin: 0; }

/* ---- Process timeline (vertical, real sequence: consult -> template -> fabricate -> install) */
.process {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  position: relative;
}
.process::before {
  content: '';
  position: absolute;
  top: 22px; left: 0; right: 0;
  height: 2px;
  background: var(--line);
}
.process-step { position: relative; padding: 0 20px; }
.process-num {
  width: 44px; height: 44px;
  background: var(--red);
  color: var(--white);
  font-family: var(--font-display);
  font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  clip-path: polygon(8px 0, 100% 0, 100% calc(100% - 8px), calc(100% - 8px) 100%, 0 100%, 0 8px);
  margin-bottom: 18px;
  position: relative;
  z-index: 2;
}
.process-step h3 { font-size: 1.05rem; }
.process-step p { font-size: 0.9rem; }

/* ---- Materials / products grid ----------------------------------------- */
.material-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.material-card {
  background: var(--white);
  border: 1px solid var(--line);
  overflow: hidden;
}
.material-card .swatch {
  height: 8px;
  background: var(--red);
}
.material-card-body { padding: 26px; }
.material-card ul { margin-top: 14px; }
.material-card li {
  font-size: 0.9rem;
  padding-left: 18px;
  position: relative;
  margin-bottom: 8px;
  color: var(--charcoal-soft);
}
.material-card li::before {
  content: '';
  position: absolute; left: 0; top: 8px;
  width: 8px; height: 2px;
  background: var(--red);
}

/* ---- Partner logo strip ------------------------------------------------ */
.partners-strip {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 44px;
  padding: 36px 0;
}
.partners-strip img {
  max-height: 46px;
  width: auto;
  filter: grayscale(100%) opacity(0.55);
  transition: filter 0.2s ease;
}
.partners-strip img:hover { filter: grayscale(0%) opacity(1); }

/* ---- FAQ accordion ------------------------------------------------------ */
.faq-list { max-width: 820px; margin: 0 auto; }
.faq-item {
  border-bottom: 1px solid var(--line);
}
.faq-question {
  width: 100%;
  background: none;
  border: none;
  text-align: left;
  padding: 20px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.02rem;
  color: var(--charcoal);
}
.faq-question .plus {
  font-size: 1.4rem;
  color: var(--red);
  flex-shrink: 0;
  margin-left: 20px;
  transition: transform 0.2s ease;
  line-height: 1;
}
.faq-item[open] .faq-question .plus { transform: rotate(45deg); }
.faq-answer { padding: 0 0 20px; color: var(--stone); font-size: 0.96rem; }

/* ---- Coverage grid ------------------------------------------------------ */
.coverage-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}
.coverage-card {
  background: var(--white);
  border: 1px solid var(--line);
  padding: 18px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: border-color 0.15s ease, background 0.15s ease;
}
.coverage-card:hover { border-color: var(--red); background: var(--paper-dim); }
.coverage-card span { font-family: var(--font-display); font-weight: 500; }
.coverage-card .arrow { color: var(--red); font-size: 1.1rem; }

/* ---- Town page hero (compact) ------------------------------------------ */
.subpage-hero {
  background: var(--charcoal);
  color: var(--white);
  padding: 52px 0 46px;
}
.subpage-hero p { color: #d8d5cf; max-width: 700px; }
.breadcrumbs {
  font-size: 0.82rem;
  color: var(--stone-light);
  margin-bottom: 18px;
}
.breadcrumbs a { color: var(--stone-light); }
.breadcrumbs a:hover { color: var(--red); }

/* ---- Two-column with image -------------------------------------------- */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
}
.split img { border: 3px solid var(--red); }
.split.reverse .split-img { order: 2; }

/* ---- CTA band ----------------------------------------------------------- */
.cta-band {
  background: var(--red);
  color: var(--white);
  padding: 52px 0;
  text-align: center;
}
.cta-band h2 { color: var(--white); margin-bottom: 10px; }
.cta-band p { color: #ffe3e5; margin-bottom: 28px; }
.cta-band .btn { background: var(--charcoal); }
.cta-band .btn:hover { background: #000; }

/* ---- Contact page -------------------------------------------------------- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
}
.contact-card {
  background: var(--white);
  border: 1px solid var(--line);
  padding: 28px;
  margin-bottom: 16px;
}
.contact-card h3 { font-size: 1rem; margin-bottom: 10px; }
.hours-table { width: 100%; border-collapse: collapse; }
.hours-table td { padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 0.92rem; }
.hours-table td:last-child { text-align: right; color: var(--stone); }
.map-frame { border: 1px solid var(--line); width: 100%; height: 340px; }

/* ---- Footer --------------------------------------------------------------- */
.site-footer {
  background: var(--charcoal);
  color: #cfcbc3;
  padding: 56px 0 28px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 36px;
  margin-bottom: 40px;
}
.footer-grid h4 { color: var(--white); font-size: 0.9rem; text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 16px; }
.footer-grid ul li { margin-bottom: 10px; font-size: 0.9rem; }
.footer-grid ul li a:hover { color: var(--red); }
.footer-logo img { height: 36px; margin-bottom: 16px; filter: brightness(0) invert(1); }
.footer-bottom {
  border-top: 1px solid #3a3833;
  padding-top: 22px;
  display: flex;
  justify-content: space-between;
  font-size: 0.82rem;
  color: var(--stone-light);
  flex-wrap: wrap;
  gap: 10px;
}
.footer-bottom a:hover { color: var(--red); }

/* ---- Video embed ---------------------------------------------------------- */
.video-embed {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border: 3px solid var(--red);
}
.video-embed iframe {
  position: absolute; top: 0; left: 0; width: 100%; height: 100%; border: 0;
}

/* ---- 404 ------------------------------------------------------------------ */
.error-page {
  text-align: center;
  padding: 110px 24px;
}
.error-page .code {
  font-family: var(--font-display);
  font-size: 6rem;
  color: var(--red);
  font-weight: 700;
  line-height: 1;
}

/* ---- Legal pages ------------------------------------------------------------ */
.legal-content { max-width: 780px; margin: 0 auto; }
.legal-content h2 { margin-top: 1.6em; }
.legal-content ul { list-style: disc; padding-left: 22px; margin-bottom: 1em; }
.legal-content li { margin-bottom: 6px; color: var(--charcoal-soft); }

.visually-hidden {
  position: absolute;
  left: -9999px;
  top: auto;
}
.visually-hidden:focus {
  left: 12px;
  top: 12px;
  z-index: 999;
  background: var(--white);
  padding: 10px 16px;
  border: 2px solid var(--red);
}

/* ---- Focus states / accessibility ------------------------------------------- */
a:focus-visible, button:focus-visible {
  outline: 2px solid var(--red);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; scroll-behavior: auto !important; }
}

/* ---- Responsive ------------------------------------------------------------- */
@media (max-width: 980px) {
  .hero-grid { grid-template-columns: 1fr; padding: 44px 24px 52px; }
  .bento { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 170px; }
  .bento-card.wide { grid-column: span 2; }
  .material-grid { grid-template-columns: 1fr; }
  .process { grid-template-columns: repeat(2, 1fr); gap: 28px; }
  .process::before { display: none; }
  .coverage-grid { grid-template-columns: repeat(2, 1fr); }
  .split { grid-template-columns: 1fr; gap: 28px; }
  .split.reverse .split-img { order: 0; }
  .contact-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 640px) {
  .header-nav { display: none; }
  .header-cta .phone-pill { display: none; }
  .bento { grid-template-columns: 1fr; }
  .bento-card.wide, .bento-card.tall { grid-column: span 1; grid-row: span 1; }
  .process { grid-template-columns: 1fr; }
  .coverage-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  section { padding: 52px 0; }
  .sticky-call { display: block; }
  body { padding-bottom: 54px; }
}
