/* ============================================================
   Brand colors — from the logo
   ============================================================ */
:root {
  --blue: #1745a0;
  --blue-dark: #0f2f6e;
  --blue-light: #e8eef9;
  --gold: #cfb138;
  --gold-dark: #a88e22;
  --ink: #1b2233;
  --muted: #5b6477;
  --bg: #f6f7fa;
  --card: #ffffff;
  --line: #dde2ec;
  --radius: 12px;
  --shadow: 0 2px 10px rgba(15, 47, 110, 0.08);
  --max: 1120px;
}

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 1rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

main { flex: 1; }
img { max-width: 100%; display: block; }
a { color: var(--blue); }
h1, h2, h3 { line-height: 1.2; margin: 0 0 .5em; }
h1 { font-size: clamp(1.75rem, 6vw, 3rem); }
h2 { font-size: clamp(1.4rem, 4.5vw, 2rem); }
h3 { font-size: 1.15rem; }
p { margin: 0 0 1em; }

.container { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 16px; }
.muted { color: var(--muted); margin: 0; font-size: .95rem; }

.skip-link {
  position: absolute; left: -999px; top: 8px;
  background: var(--gold); color: var(--ink); padding: 8px 12px; border-radius: 6px; z-index: 100;
}
.skip-link:focus { left: 8px; }

:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }

/* ============================================================
   Header / navigation (mobile first)
   ============================================================ */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: #fff;
  border-bottom: 4px solid var(--blue);
  box-shadow: 0 2px 8px rgba(15, 47, 110, 0.08);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  min-height: 64px; gap: 12px;
}
.brand { display: flex; align-items: center; }
.brand img { height: 44px; width: auto; }
@media (min-width: 768px) { .brand img { height: 52px; } }

.nav-toggle {
  display: inline-flex; align-items: center; justify-content: center;
  width: 48px; height: 48px; padding: 0;
  background: transparent; border: 2px solid var(--blue-light); border-radius: 10px;
  color: var(--blue); cursor: pointer;
}
.nav-toggle svg { width: 26px; height: 26px; }
.nav-toggle[aria-expanded="true"] .icon-open,
.nav-toggle[aria-expanded="false"] .icon-close { display: none; }

#site-nav {
  display: none;
  position: absolute; left: 0; right: 0; top: 100%;
  background: #fff;
  border-bottom: 4px solid var(--blue);
  box-shadow: 0 8px 16px rgba(15, 47, 110, 0.12);
}
#site-nav.open { display: block; }
#site-nav ul { list-style: none; margin: 0; padding: 8px 16px 16px; }
#site-nav a {
  display: block; padding: 14px 12px;
  color: var(--blue); text-decoration: none; font-weight: 600; font-size: 1.1rem;
  border-radius: 8px;
}
#site-nav a:hover { background: var(--blue-light); }
#site-nav a[aria-current="page"] { color: var(--gold-dark); background: #faf6e6; }

@media (min-width: 768px) {
  .nav-toggle { display: none; }
  #site-nav, #site-nav.open {
    display: block; position: static; background: none; border: 0; box-shadow: none;
  }
  #site-nav ul { display: flex; gap: 4px; padding: 0; }
  #site-nav a { padding: 10px 14px; font-size: 1rem; }
  #site-nav a[aria-current="page"] { color: var(--blue); background: none; box-shadow: inset 0 -3px 0 var(--gold); border-radius: 0; }
}

/* ============================================================
   Buttons
   ============================================================ */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 12px 22px;
  font: inherit; font-weight: 700; text-decoration: none;
  border-radius: 10px; border: 2px solid transparent; cursor: pointer;
  transition: background .15s, transform .15s;
}
.btn:active { transform: translateY(1px); }
.btn-gold { background: var(--gold); color: var(--ink); }
.btn-gold:hover { background: #dcc053; }
.btn-outline { border-color: #fff; color: #fff; background: transparent; }
.btn-outline:hover { background: rgba(255,255,255,.1); }
.btn-blue { background: var(--blue); color: #fff; }
.btn-blue:hover { background: var(--blue-dark); }
.btn[disabled] { opacity: .6; cursor: wait; }

.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }
@media (max-width: 479px) { .btn-row .btn { flex: 1 1 100%; } }

/* ============================================================
   Hero + page headers
   ============================================================ */
.hero {
  background:
    linear-gradient(135deg, rgba(15,47,110,.95), rgba(23,69,160,.88)),
    var(--blue);
  color: #fff;
  padding: 56px 0 64px;
}
.hero .eyebrow {
  display: inline-block; margin-bottom: 12px;
  color: var(--gold); font-weight: 700; text-transform: uppercase; letter-spacing: .12em; font-size: .85rem;
}
.hero p { font-size: 1.1rem; max-width: 36em; opacity: .92; }

.page-header {
  background: var(--blue); color: #fff; padding: 36px 0;
}
.page-header p { margin: 0; opacity: .9; }

section { padding: 48px 0; scroll-margin-top: 68px; }

/* ============================================================
   Cards & grids
   ============================================================ */
.grid { display: grid; gap: 16px; grid-template-columns: 1fr; }
@media (min-width: 600px) { .grid-2 { grid-template-columns: repeat(2, 1fr); } .grid-3 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 960px) { .grid-3 { grid-template-columns: repeat(3, 1fr); } }

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow);
}

.service-card { border-top: 4px solid var(--gold); display: flex; flex-direction: column; }
.service-card .icon {
  width: 52px; height: 52px; border-radius: 12px;
  display: grid; place-items: center;
  background: var(--blue-light); color: var(--blue); margin-bottom: 12px;
}
.service-card .icon svg { width: 30px; height: 30px; }
.service-card ul { padding-left: 1.2em; margin: 0 0 16px; color: var(--muted); }
.service-card > :last-child { margin-bottom: 0; }
.service-card .btn { margin-top: auto; align-self: flex-start; }

.badge {
  display: inline-block; padding: 2px 10px; margin: 6px 0 8px;
  background: var(--blue-light); color: var(--blue);
  border-radius: 999px; font-size: .8rem; font-weight: 700;
}

/* ============================================================
   Home — info + map
   ============================================================ */
.info-list { list-style: none; padding: 0; margin: 0 0 20px; }
.info-list li { display: flex; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.info-list li:last-child { border-bottom: 0; }
.info-list svg { flex: none; width: 22px; height: 22px; color: var(--gold-dark); margin-top: 2px; }
.info-list a { text-decoration: none; font-weight: 600; }

.hours { margin: 0; }
.hours-row { display: flex; justify-content: space-between; gap: 12px; padding: 4px 0; }
.hours dt { font-weight: 600; }
.hours dd { margin: 0; color: var(--muted); text-align: right; }

.map-wrap {
  position: relative; width: 100%;
  aspect-ratio: 4 / 3;
  border-radius: var(--radius); overflow: hidden;
  border: 1px solid var(--line); box-shadow: var(--shadow);
  background: var(--blue-light);
}
@media (min-width: 768px) { .map-wrap { aspect-ratio: auto; min-height: 380px; height: 100%; } }
.map-wrap iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

.cta-band { background: var(--gold); color: var(--ink); text-align: center; }
.cta-band h2 { margin-bottom: .3em; }
.cta-band .btn-row { justify-content: center; margin-top: 16px; }

/* ============================================================
   Tires & oil lists
   ============================================================ */
.toolbar { display: grid; gap: 12px; margin-bottom: 20px; }
.search {
  width: 100%; min-height: 48px; padding: 12px 14px;
  font: inherit; font-size: 16px; /* 16px stops iOS zooming on focus */
  border: 2px solid var(--line); border-radius: 10px; background: #fff;
}
.search:focus { border-color: var(--blue); outline: none; }

.chips {
  display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px;
  scrollbar-width: thin; -webkit-overflow-scrolling: touch;
}
@media (min-width: 768px) { .chips { flex-wrap: wrap; overflow: visible; } }
.chip {
  flex: none; min-height: 40px; padding: 8px 16px;
  font: inherit; font-weight: 600; font-size: .9rem;
  background: #fff; color: var(--blue);
  border: 2px solid var(--blue-light); border-radius: 999px; cursor: pointer;
}
.chip[aria-pressed="true"] { background: var(--blue); border-color: var(--blue); color: #fff; }

.result-count { color: var(--muted); font-size: .9rem; margin-bottom: 12px; }

.item-list {
  list-style: none; margin: 0; padding: 0;
  display: grid; gap: 12px;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 240px), 1fr));
}
.empty { grid-column: 1 / -1; text-align: center; padding: 32px; color: var(--muted); }

.tire-card { border-left: 5px solid var(--gold); }
.tire-card .muted { margin-top: 4px; }
.tire-size {
  font-size: 1.6rem; font-weight: 800; color: var(--blue);
  font-variant-numeric: tabular-nums; letter-spacing: .01em;
}

.oil-card { padding: 0; overflow: hidden; display: flex; flex-direction: column; border-bottom: 4px solid var(--blue); }
.oil-img { width: 100%; height: auto; aspect-ratio: 1 / 1; object-fit: cover; background: var(--blue-light); }
.oil-body { padding: 16px 18px 18px; display: flex; flex-direction: column; flex: 1; }
.oil-bottom {
  display: flex; justify-content: space-between; align-items: baseline; gap: 12px;
  margin-top: auto; padding-top: 12px; border-top: 1px solid var(--line);
}
.oil-body .muted + .oil-bottom, .oil-body .badge + .oil-bottom { margin-top: 12px; }
.price { font-weight: 800; color: var(--blue); font-size: 1.05rem; white-space: nowrap; }

/* Phones: photo beside the details so more products fit on screen */
@media (max-width: 559px) {
  .oil-card { flex-direction: row; }
  .oil-img { width: 38%; max-width: 150px; align-self: stretch; aspect-ratio: auto; min-height: 150px; }
  .oil-body { padding: 12px 14px; min-width: 0; }
  .oil-top { flex-direction: column-reverse; gap: 6px; }
  .viscosity { padding: 3px 8px; font-size: .85rem; }
  .oil-name { font-size: 1rem; }
  .oil-body .badge { margin: 4px 0; align-self: flex-start; }
  .oil-body .muted { font-size: .85rem; }
  .oil-bottom { flex-direction: column; align-items: flex-start; gap: 0; padding-top: 8px; }
  .price { font-size: 1rem; white-space: normal; }
}
.oil-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.oil-brand { font-size: .8rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--gold-dark); }
.oil-name { font-weight: 700; font-size: 1.1rem; }
.viscosity {
  flex: none; padding: 6px 10px;
  background: var(--blue); color: #fff; border-radius: 8px;
  font-weight: 800; font-variant-numeric: tabular-nums;
}

.note {
  margin-top: 24px; padding: 16px 20px;
  background: var(--blue-light); border-left: 4px solid var(--blue); border-radius: 8px;
}

/* ============================================================
   Contact form
   ============================================================ */
.contact-layout { display: grid; gap: 24px; }
@media (min-width: 900px) { .contact-layout { grid-template-columns: 3fr 2fr; align-items: start; } }

.field { margin-bottom: 16px; }
.field label { display: block; font-weight: 600; margin-bottom: 6px; }
.field .req { color: #b3261e; }
.field input, .field select, .field textarea {
  width: 100%; min-height: 48px; padding: 12px 14px;
  font: inherit; font-size: 16px; color: var(--ink);
  background: #fff; border: 2px solid var(--line); border-radius: 10px;
}
.field textarea { min-height: 140px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--blue); outline: none; }
.field-row { display: grid; gap: 0 16px; }
@media (min-width: 600px) { .field-row { grid-template-columns: 1fr 1fr; } }

form .btn { width: 100%; }
@media (min-width: 600px) { form .btn { width: auto; } }

.form-status { margin-top: 16px; padding: 12px 16px; border-radius: 8px; font-weight: 600; }
.form-status:empty { display: none; }
.form-status.ok { background: #e7f5ea; color: #1d6b32; }
.form-status.error { background: #fdecea; color: #b3261e; }

/* ============================================================
   Footer
   ============================================================ */
.site-footer {
  background: var(--blue-dark); color: rgba(255,255,255,.85);
  border-top: 4px solid var(--gold);
  padding: 32px 0 24px; font-size: .95rem;
}
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { color: var(--gold); }
.footer-grid { display: grid; gap: 24px; }
@media (min-width: 768px) { .footer-grid { grid-template-columns: 2fr 1fr 1fr; } }
.footer-logo { height: 48px; width: auto; margin-bottom: 12px; }
.site-footer h3 { color: var(--gold); font-size: 1rem; text-transform: uppercase; letter-spacing: .08em; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { padding: 4px 0; }
.site-footer .hours dd { color: rgba(255,255,255,.7); }
.copyright { margin-top: 24px; padding-top: 16px; border-top: 1px solid rgba(255,255,255,.15); font-size: .85rem; opacity: .75; }
