/* ============================================================
   KAPOLIS AUTO REPAIR — Shared Stylesheet
   Light theme: warm off-white bg, near-black ink, gold stars
   Fonts: Anton (display) · Crimson Pro (body) · Barlow Condensed (ui)
============================================================ */

/* ============================================================
   GOOGLE FONTS
============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Anton&family=Crimson+Pro:ital,wght@0,400;0,600;1,400;1,600&family=Barlow+Condensed:wght@400;500;600;700&display=swap');

/* ============================================================
   RESET
============================================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
img, svg { display: block; max-width: 100%; }
button { cursor: pointer; font: inherit; border: none; background: none; }
a { color: inherit; }

/* ============================================================
   DESIGN TOKENS
============================================================ */
:root {
  /* Backgrounds */
  --bg:       #FFFFFF;
  --bg-2:     #F5F5F5;
  --bg-card:  #EBEBEB;
  --bg-dark:  #0D0C0A;   /* Used for footer / contrast sections */

  /* Ink */
  --ink:      #0D0C0A;
  --ink-2:    #1C1B18;
  --ink-dim:  #6B6860;
  --ink-faint:#A8A49E;

  /* Accent = same near-black (no red) */
  --accent:   #0D0C0A;

  /* Gold — stars only */
  --gold:     #B88C20;

  /* Borders */
  --rule:     rgba(13,12,10,0.12);
  --rule-heavy: rgba(13,12,10,0.22);

  /* Typography */
  --display: 'Anton', sans-serif;
  --body:    'Crimson Pro', Georgia, serif;
  --ui:      'Barlow Condensed', sans-serif;

  /* Spacing scale */
  --section-pad: 8rem 2.5rem;
}

/* ============================================================
   BASE
============================================================ */
html { scroll-behavior: smooth; }

body {
  font-family: var(--body);
  background: var(--bg);
  color: var(--ink);
  line-height: 1.65;
  overflow-x: hidden;
}

/* Subtle grain on light bg */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9000;
  opacity: 0.018;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 512 512' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 180px 180px;
}

/* ============================================================
   TYPOGRAPHY UTILITIES
============================================================ */
.label {
  font-family: var(--ui);
  font-size: 0.7rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--ink-dim);
}

.display {
  font-family: var(--display);
  line-height: 1.02;
}

/* ============================================================
   SCROLL REVEAL
============================================================ */
.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.75s cubic-bezier(.16,1,.3,1),
              transform 0.75s cubic-bezier(.16,1,.3,1);
}
.reveal.in { opacity: 1; transform: translateY(0); }

/* ============================================================
   BUTTONS
============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-family: var(--ui);
  font-size: 0.88rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 0.9rem 2rem;
  border-radius: 2px;
  transition: transform 0.2s, box-shadow 0.2s, background 0.2s, color 0.2s;
  cursor: pointer;
  border: none;
}

.btn-dark {
  background: var(--ink);
  color: var(--bg);
}
.btn-dark:hover {
  background: var(--ink-2);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(13,12,10,0.2);
}

.btn-outline {
  background: transparent;
  color: var(--ink);
  border: 1.5px solid var(--rule-heavy);
}
.btn-outline:hover {
  border-color: var(--ink);
  transform: translateY(-2px);
}

/* ============================================================
   NAV
============================================================ */
#nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 200;
  padding: 1rem 2.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: background 0.4s, border-color 0.4s, backdrop-filter 0.4s;
  border-bottom: 1px solid transparent;
}
#nav.scrolled {
  background: rgba(255,255,255,0.94);
  border-color: var(--rule);
  backdrop-filter: blur(14px);
}

.nav-logo img {
  height: 50px;
  width: auto;
}

.nav-links {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 2.5rem;
}
.nav-links a {
  font-family: var(--ui);
  font-size: 0.82rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-dim);
  text-decoration: none;
  transition: color 0.2s;
}
.nav-links a:hover,
.nav-links a.active { color: var(--ink); }

.nav-links a.active {
  border-bottom: 1.5px solid var(--ink);
  padding-bottom: 1px;
}

.nav-book {
  background: var(--ink) !important;
  color: var(--bg) !important;
  padding: 0.5rem 1.3rem !important;
  border-radius: 2px;
  border-bottom: none !important;
  letter-spacing: 0.14em !important;
  transition: background 0.2s !important;
}
.nav-book:hover { background: var(--ink-2) !important; }

/* Burger */
.burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
}
.burger span {
  display: block;
  width: 26px;
  height: 2px;
  background: var(--ink);
  transition: transform 0.3s, opacity 0.3s;
}
.burger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger.open span:nth-child(2) { opacity: 0; }
.burger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile nav drawer */
.mobile-nav {
  display: none;
  position: fixed;
  top: 70px; left: 0; right: 0;
  background: rgba(255,255,255,0.98);
  border-bottom: 1px solid var(--rule);
  padding: 1.5rem 2rem;
  flex-direction: column;
  gap: 1.25rem;
  z-index: 199;
}
.mobile-nav.open { display: flex; }
.mobile-nav a {
  font-family: var(--ui);
  font-size: 1.1rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-dim);
  text-decoration: none;
}
.mobile-nav a:hover,
.mobile-nav a.active { color: var(--ink); }

/* ============================================================
   PAGE HEADER (used on interior pages)
============================================================ */
.page-header {
  padding: 10rem 2.5rem 5rem;
  background: var(--bg);
  border-bottom: 1px solid var(--rule);
  position: relative;
  overflow: hidden;
}
.page-header::before {
  content: attr(data-bg-text);
  position: absolute;
  font-family: var(--display);
  font-size: clamp(100px, 20vw, 260px);
  color: rgba(13,12,10,0.04);
  right: -2%;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  white-space: nowrap;
  line-height: 1;
  user-select: none;
}
.page-header-inner { max-width: 900px; }
.page-header-eyebrow { margin-bottom: 1rem; display: block; }
.page-header-title {
  font-family: var(--display);
  font-size: clamp(2.8rem, 7vw, 6rem);
  line-height: 0.98;
  margin-bottom: 1.25rem;
}
.page-header-sub {
  font-size: 1.15rem;
  color: var(--ink-dim);
  max-width: 560px;
  line-height: 1.75;
}

/* ============================================================
   SECTION UTILITIES
============================================================ */
.section-label { display: block; margin-bottom: 0.6rem; }
.section-title {
  font-family: var(--display);
  font-size: clamp(2.2rem, 4.5vw, 3.8rem);
  line-height: 1.05;
}

/* ============================================================
   FOOTER
============================================================ */
footer {
  background: var(--bg-dark);
  color: var(--bg);
  padding: 2.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  flex-wrap: wrap;
}
footer img { height: 44px; width: auto; opacity: 0.7; }
.foot-copy {
  font-family: var(--ui);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  color: rgba(244,241,235,0.4);
}
.foot-right {
  font-family: var(--ui);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  color: rgba(244,241,235,0.4);
}
.foot-right a { text-decoration: none; transition: color 0.2s; }
.foot-right a:hover { color: var(--bg); }

/* ============================================================
   NAV + FOOTER SHARED JS BEHAVIOR (applied via script.js)
============================================================ */

/* ============================================================
   RESPONSIVE — NAV
============================================================ */
@media (max-width: 960px) {
  .nav-links { display: none; }
  .burger { display: flex; }
  #nav { padding: 1rem 1.5rem; }
  footer { justify-content: center; text-align: center; }
  .page-header { padding: 8rem 1.5rem 4rem; }
}
