/* =========================================================
   MOBILE MECHANIC SITE — main.css
   ---------------------------------------------------------
   This one stylesheet is shared by every page (index.html,
   services.html, fleet-servicing.html, about.html,
   contact.html, privacy-policy.html). Every page links to it
   with: <link rel="stylesheet" href="css/main.css">

   Sections in this file, top to bottom:
     1. Design tokens (colors, fonts, spacing) — change these
        and the whole site updates.
     2. Reset / base element styles
     3. Buttons
     4. Header + navigation
     5. Homepage hero
     6. Section dividers (the diagonal stripe)
     7. General section spacing + service cards
     8. "Why choose us" grid
     9. Service area list
     10. Contact call-to-action band
     11. Page hero (used on Services/Fleet/About/Contact/Privacy)
     12. Page body content (paragraphs, headings, links)
     13. Contact page info cards
     14. Footer
     15. Responsive rules (tablet + mobile)
     16. Accessibility (reduced motion, focus outlines)
   ========================================================= */

/* ---------------------------------------------------------
   1. DESIGN TOKENS
   All colors and fonts are defined once here as CSS variables
   (the --name: value; lines). Every other rule in this file
   references them with var(--name). To re-theme the whole
   site, you only need to edit this block.
   --------------------------------------------------------- */
:root {
  --navy: #16232e; /* main dark background color (header text, hero, footer) */
  --navy-soft: #1f313f; /* slightly lighter navy, for subtle contrast panels */
  --steel: #3a4750; /* muted blue-grey, used sparingly */
  --white: #ffffff;
  --offwhite: #f4f6f8; /* light grey section background */
  --paper-dim: #e7eaee; /* slightly darker light grey */
  --orange: #f2a93b; /* primary accent (buttons, highlights) */
  --orange-dark: #d6900f; /* accent hover / link color */
  --ink: #1b242b; /* main body text color */
  --ink-soft: #57626b; /* secondary/muted text color */
  --border: #dbe0e5; /* light borders/dividers */

  --font-body:
    -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial,
    sans-serif;
  --font-display: "Arial Narrow", Arial, sans-serif; /* used for headings */

  --radius: 6px; /* corner rounding used everywhere */
  --container: 1160px; /* max width of page content */
}

/* ---------------------------------------------------------
   2. RESET / BASE STYLES
   Normalizes default browser styling and sets up the base
   look for text, links, lists, and images site-wide.
   --------------------------------------------------------- */
* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img {
  display: block;
  max-width: 100%;
  height: auto;
}
a {
  color: inherit;
  text-decoration: none;
}
h1,
h2,
h3,
h4 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: 0.2px;
  margin: 0 0 0.5em;
  color: var(--navy);
}
p {
  margin: 0 0 1em;
  color: var(--ink-soft);
}
ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

/* Centers page content and adds side padding on every section */
.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------------------------------------------------------
   3. BUTTONS
   Two button styles used throughout: a solid orange "primary"
   button (main call-to-action, e.g. "Call Now") and an
   outlined "secondary" button (e.g. "Contact Us").
   --------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: var(--radius);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.3px;
  border: 1.5px solid transparent;
  cursor: pointer;
  transition:
    transform 0.15s ease,
    background 0.15s ease,
    border-color 0.15s ease;
}
.btn:hover {
  transform: translateY(-1px);
}

.btn-primary {
  background: var(--orange);
  color: var(--navy);
}
.btn-primary:hover {
  background: var(--orange-dark);
}

.btn-outline {
  background: transparent;
  border-color: var(--navy);
  color: var(--navy);
}
.btn-outline:hover {
  background: var(--navy);
  color: var(--white);
}

/* ---------------------------------------------------------
   4. HEADER + NAVIGATION
   Sticky white header with logo on the left, nav links in the
   middle, a "Call Now" button, and a hamburger toggle that
   only shows on mobile (see responsive section near the bottom).
   --------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid var(--border);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 76px;
  gap: 24px;
}

/* Logo (text-based here — swap for an <img> if you have a logo file) */
.logo-wrap {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}
.logo {
  display: flex;
  flex-direction: column;
  white-space: nowrap;
}
.logo-text {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  color: var(--navy);
}
.logo-sub {
  font-size: 11px;
  color: var(--orange-dark);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-top: 2px;
}
/* If you replace the text logo with an <img>, this keeps it a sensible size */
.logo-wrap img {
  max-height: 56px;
  width: auto;
  display: block;
}

/* Main navigation links */
.nav-menu {
  display: flex;
  gap: 28px;
}
.nav-menu a {
  font-size: 15px;
  font-weight: 600;
  color: var(--ink);
  padding: 6px 0;
}
.nav-menu a:hover {
  color: var(--orange-dark);
}
/* Highlights the link for the page you're currently on */
.nav-menu a[aria-current="page"] {
  color: var(--orange-dark);
}

.header-cta {
  flex-shrink: 0;
  white-space: nowrap;
}

/* Hamburger menu button — hidden on desktop, shown on mobile */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  background: none;
  border: none;
  cursor: pointer;
}
.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--navy);
  transition:
    transform 0.2s ease,
    opacity 0.2s ease;
}
/* When JS adds the "active" class, animate the 3 bars into an X */
.nav-toggle.active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.nav-toggle.active span:nth-child(2) {
  opacity: 0;
}
.nav-toggle.active span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ---------------------------------------------------------
   5. HOMEPAGE HERO
   The big dark intro banner at the top of index.html only.
   --------------------------------------------------------- */
.hero {
  background: var(--navy);
  color: var(--white);
  padding: 88px 0;
}
.hero-inner {
  display: grid;
  grid-template-columns: 1fr 2fr 1fr;
  gap: 100px;
  align-items: center;
}
.hero-side-image {
  width: 100%;
  height: 320px;
  object-fit: cover;
  border-radius: var(--radius);
  border: 1px solid #2b3e4c;
}
.eyebrow {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--orange);
  margin-bottom: 18px;
}
.hero h1 {
  font-size: clamp(32px, 4.5vw, 50px);
  color: var(--white);
  margin-bottom: 20px;
}
.hero-sub {
  font-size: 17px;
  color: #c7cfd6;
  max-width: 52ch;
  margin-bottom: 28px;
}
.hero-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}
.hero-actions-center {
  justify-content: center;
}
/* Outline buttons need a lighter border/text color on dark backgrounds
   (the homepage hero AND the dark contact-cta band both qualify) */
.hero .btn-outline,
.contact-cta .btn-outline {
  border-color: #4b5a67;
  color: var(--white);
}
.hero .btn-outline:hover,
.contact-cta .btn-outline:hover {
  background: var(--white);
  color: var(--navy);
  border-color: var(--white);
}
.hero-note {
  font-size: 13px;
  color: #93a0aa;
  max-width: 52ch;
  margin-bottom: 0;
}

/* ---------------------------------------------------------
   6. SECTION DIVIDER (diagonal hazard-style stripe)
   A thin decorative bar used between a couple of sections.
   --------------------------------------------------------- */
.stripe {
  height: 8px;
  background: repeating-linear-gradient(
    -45deg,
    var(--orange),
    var(--orange) 14px,
    var(--navy) 14px,
    var(--navy) 28px
  );
}

/* ---------------------------------------------------------
   7. GENERAL SECTIONS + SERVICE CARDS
   ".section" is the standard vertical padding wrapper used on
   every content block. ".section-alt" swaps in a light grey
   background so sections visually alternate down the page.
   ".card" is the small boxed layout used for each service.
   --------------------------------------------------------- */
.section {
  padding: 80px 0;
}
.section-alt {
  background: var(--offwhite);
}
.section h2 {
  font-size: clamp(24px, 3vw, 34px);
  color: var(--navy);
}
.section-sub {
  max-width: 56ch;
  font-size: 16px;
  margin-bottom: 40px;
}

.grid {
  display: grid;
  gap: 24px;
}
.services-grid {
  grid-template-columns: repeat(3, 1fr);
}

.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-left: 4px solid var(--orange);
  border-radius: var(--radius);
  padding: 26px;
  transition: transform 0.15s ease;
}
.card:hover {
  transform: translateY(-2px);
}
.card h3 {
  font-size: 18px;
  color: var(--navy);
  margin-bottom: 8px;
}
.card p {
  font-size: 14.5px;
  margin-bottom: 0;
}

.card-with-photo {
  padding: 0;
  overflow: hidden;
}
.card-with-photo .card-image {
  width: 100%;
  height: 160px;
  object-fit: cover;
  display: block;
}
.card-with-photo .card-body {
  padding: 20px 26px 26px;
}

/* ---------------------------------------------------------
   8. "WHY CHOOSE US" / BENEFITS GRID
   Reused on the homepage, About page, and Fleet Servicing page.
   --------------------------------------------------------- */
.why-grid {
  grid-template-columns: repeat(4, 1fr);
}

.home-why-grid {
  grid-template-columns: repeat(3, 1fr);
}

.why-item {
  background: var(--white);
  border: 1px solid var(--border);
  border-left: 4px solid var(--orange);
  border-radius: var(--radius);
  padding: 26px;
  transition: transform 0.15s ease;
}
.why-item:hover {
  transform: translateY(-2px);
}
.why-item h3 {
  font-size: 17px;
  color: var(--navy);
  margin-bottom: 6px;
}
.why-item p {
  font-size: 14px;
  margin-bottom: 0;
}

/* ---------------------------------------------------------
   9. SERVICE AREA LIST
   The bullet-style list of towns/areas covered, on the homepage.
   --------------------------------------------------------- */
.area-list {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px 24px;
  margin-top: 8px;
}
.area-list li {
  font-size: 14.5px;
  font-weight: 600;
  color: var(--ink);
  padding-left: 18px;
  position: relative;
}
/* The small orange dot before each town name */
.area-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 8px;
  width: 8px;
  height: 8px;
  background: var(--orange-dark);
  border-radius: 50%;
}

/* ---------------------------------------------------------
   10. CONTACT CALL-TO-ACTION BAND
   The dark "Need a mechanic? Call now" band repeated near the
   bottom of most pages.
   --------------------------------------------------------- */
.contact-cta {
  background: var(--navy);
  color: var(--white);
  text-align: center;
}
.contact-cta h2 {
  color: var(--white);
}
.contact-simple {
  text-align: center;
  max-width: 560px;
  margin: 0 auto;
}
.contact-sub-center {
  margin-left: auto;
  margin-right: auto;
  color: #c7cfd6;
}

/* ---------------------------------------------------------
   11. PAGE HERO (Services / Fleet Servicing / About / Contact /
   Privacy Policy). A shorter, simpler version of the homepage
   hero — just an eyebrow label and the page title.
   --------------------------------------------------------- */
.page-hero {
  background: var(--navy);
  color: var(--white);
  padding: 48px 0;
}
.page-hero .eyebrow {
  margin-bottom: 10px;
}
.page-hero h1 {
  color: var(--white);
  font-size: clamp(28px, 4vw, 42px);
  margin-bottom: 0;
}

/* ---------------------------------------------------------
   12. PAGE BODY CONTENT
   Styling for ordinary written content — paragraphs, lists,
   headings, links — inside the main text area of a page.
   --------------------------------------------------------- */
.page-content {
  padding: 64px 0;
}
.page-container {
  max-width: 760px;
}
.page-title {
  font-size: clamp(28px, 4vw, 40px);
}
.page-body {
  font-size: 16px;
  color: var(--ink);
}
.page-body p {
  color: var(--ink);
}
.page-body h2 {
  margin-top: 1.4em;
}
.page-body ul,
.page-body ol {
  padding-left: 22px;
  margin-bottom: 1em;
}
.page-body li {
  color: var(--ink-soft);
  margin-bottom: 6px;
}
.page-body a {
  color: var(--orange-dark);
  text-decoration: underline;
}

/* ---------------------------------------------------------
   13. CONTACT PAGE INFO CARDS
   The 3-across "Call / Hours / Coverage" cards on contact.html.
   --------------------------------------------------------- */
.quick-contact-grid {
  grid-template-columns: repeat(3, 1fr);
}
.info-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-top: 4px solid var(--orange);
  border-radius: var(--radius);
  padding: 26px;
  text-align: center;
}
.info-card h3 {
  font-size: 16px;
  margin-bottom: 12px;
}
.info-card p {
  font-size: 14px;
  margin-bottom: 0;
}
.info-card-cta {
  width: 100%;
}

/* ---------------------------------------------------------
   14. FOOTER
   Dark footer with a short about blurb, quick links, contact
   info, and a legal disclaimer line at the very bottom.
   --------------------------------------------------------- */
.site-footer {
  background: var(--navy);
  color: #c7cfd6;
  padding: 56px 0 0;
}
.footer-inner {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 40px;
  border-bottom: 1px solid #2b3e4c;
}
.logo-footer {
  color: var(--white);
  margin-bottom: 12px;
  display: inline-block;
  font-size: 19px;
}
.footer-about p {
  font-size: 14px;
  max-width: 36ch;
  color: #abb6bf;
}
.footer-links {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.footer-links h4 {
  color: var(--white);
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 4px;
}
.footer-links a {
  font-size: 14px;
  color: #c7cfd6;
}
.footer-links a:hover {
  color: var(--orange);
}
.footer-area {
  font-size: 13px;
  color: #93a0aa;
  margin-top: 6px;
}

.footer-vat {
  font-size: 13px;
  color: #93a0aa;
  margin-top: 4px;
}

.footer-bottom {
  padding: 22px 24px;
  text-align: center;
  font-size: 13px;
  color: #8493a0;
}
.footer-disclaimer {
  font-size: 12.5px;
  color: #7c8b97;
  max-width: 60ch;
  margin: 0 auto 8px;
}

/* ---------------------------------------------------------
   15. RESPONSIVE RULES
   Tablet breakpoint (900px) stacks grids into 2 columns.
   Mobile breakpoint (700px) turns the nav into a slide-down
   menu controlled by js/main.js, and stacks grids to 1 column.
   --------------------------------------------------------- */
@media (max-width: 900px) {
  .services-grid,
  .why-grid,
  .home-why-grid,
  .quick-contact-grid,
  .fleet-gallery-grid,
  .services-gallery-grid,
  .about-gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .footer-inner {
    grid-template-columns: 1fr;
  }
  .area-list {
    grid-template-columns: repeat(2, 1fr);
  }
  .hero-inner {
    grid-template-columns: 1fr;
  }
  .hero-side-image {
    display: none;
  }
}

@media (max-width: 700px) {
  /* The nav becomes a full-width dropdown panel under the header */
  .nav {
    position: absolute;
    top: 76px;
    left: 0;
    right: 0;
    background: var(--white);
    border-bottom: 1px solid var(--border);
    display: none; /* hidden until js/main.js toggles the .nav-open class */
  }
  .nav.nav-open {
    display: block;
  }
  .nav-menu {
    flex-direction: column;
    gap: 0;
    padding: 8px 24px 16px;
  }
  .nav-menu a {
    display: block;
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
  }
  .header-cta {
    display: none;
  } /* hide the header call button, mobile nav has its own space */
  .nav-toggle {
    display: flex;
  } /* show the hamburger icon */
  .services-grid,
  .why-grid,
  .home-why-grid,
  .area-list,
  .quick-contact-grid,
  .fleet-gallery-grid,
  .services-gallery-grid,
  .about-gallery-grid {
    grid-template-columns: 1fr;
  }
  .section {
    padding: 56px 0;
  }
  .hero {
    padding: 56px 0;
  }
}

/* ---------------------------------------------------------
   16. FAQ ACCORDION
   Uses native <details>/<summary> elements — no JavaScript
   needed, works with keyboards and screen readers by default.
   --------------------------------------------------------- */
.faq-list {
  max-width: 760px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.faq-item {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 4px 22px;
}
.faq-item summary {
  list-style: none; /* hide the default disclosure triangle */
  cursor: pointer;
  padding: 18px 0;
  font-weight: 700;
  color: var(--navy);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.faq-item summary::-webkit-details-marker {
  display: none;
} /* Safari/Chrome default arrow */
/* Custom plus/minus indicator, drawn with CSS instead of an icon font */
.faq-item summary::after {
  content: "+";
  flex-shrink: 0;
  font-size: 20px;
  color: var(--orange-dark);
  transition: transform 0.15s ease;
}
.faq-item[open] summary::after {
  content: "\2212";
} /* minus sign when open */
.faq-item p {
  padding-bottom: 18px;
  margin: 0;
  color: var(--ink-soft);
  font-size: 15px;
}

/* ---------------------------------------------------------
   17. ACCESSIBILITY
   Respect the user's OS-level "reduce motion" preference, and
   make sure keyboard users always see a visible focus outline.
   --------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .btn,
  .card {
    transition: none;
  }
}

a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--orange-dark);
  outline-offset: 2px;
}

/* ---------------------------------------------------------
   13b. FLEET SERVICING IMAGE GALLERY
   Three images split into equal columns on the Fleet
   Servicing page, each with a short caption underneath.
   --------------------------------------------------------- */
.fleet-gallery-grid {
  grid-template-columns: repeat(3, 1fr);
}

.services-gallery-grid {
  grid-template-columns: repeat(3, 1fr);
}

.gallery-item {
  margin: 0;
}
.gallery-item img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  border-radius: var(--radius);
  border: 1px solid var(--border);
}
.gallery-item figcaption {
  margin-top: 10px;
  font-size: 13px;
  color: var(--ink-soft);
  text-align: center;
}

.about-gallery-grid {
  grid-template-columns: repeat(4, 1fr);
}
.about-gallery-grid .gallery-item img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  border-radius: var(--radius);
  border: 1px solid var(--border);
}
