/* Hub Cap Annie — Modernized Annie brand
   Pink + black heritage, clean modern layout */
:root {
  --pink: #E0447C;
  --pink-dark: #C2325F;
  --pink-soft: #FDEEF4;
  --ink: #171214;
  --ink-soft: #47404A;
  --paper: #FFFFFF;
  --paper-warm: #FAF7F8;
  --line: #EFE3E8;
  --radius: 14px;
  --shadow: 0 6px 24px rgba(23, 18, 20, .08);
  --maxw: 1120px;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Poppins', system-ui, -apple-system, sans-serif;
  color: var(--ink);
  background: var(--paper);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
/* height:auto lets width/height attributes on <img> supply an aspect ratio (which stops
   layout shift as images load) without the fixed height fighting max-width on small
   screens. The explicit heights on .card img and the logos below still take precedence. */
img { max-width: 100%; display: block; height: auto; }
a { color: var(--pink-dark); text-decoration: none; }
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }

/* ---------- Header ---------- */
.topbar {
  background: var(--ink); color: #fff; font-size: .85rem;
  padding: 6px 0; text-align: center;
}
.topbar a { color: #fff; font-weight: 600; }
header.site {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.96); backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.nav {
  display: flex; align-items: center; gap: 18px;
  max-width: var(--maxw); margin: 0 auto; padding: 10px 20px;
}
.nav .logo img { height: 46px; width: auto; }
.nav ul {
  display: flex; gap: 20px; list-style: none; margin-left: auto;
  align-items: center;
}
.nav ul a { color: var(--ink); font-weight: 500; font-size: .95rem; }
.nav ul a:hover { color: var(--pink); }
.btn {
  display: inline-block; background: var(--pink); color: #fff !important;
  padding: 11px 22px; border-radius: 999px; font-weight: 600;
  border: none; cursor: pointer; font-size: .95rem;
  transition: background .15s, transform .15s;
}
.btn:hover { background: var(--pink-dark); transform: translateY(-1px); }
.btn.ghost {
  background: transparent; color: var(--ink) !important;
  border: 2px solid var(--ink);
}
.btn.ghost:hover { background: var(--ink); color: #fff !important; }
.btn.big { padding: 15px 30px; font-size: 1.05rem; }
#menu-toggle { display: none; background: none; border: none; font-size: 1.6rem; cursor: pointer; color: var(--ink); }

/* ---------- Hero ---------- */
.hero {
  position: relative; color: #fff; text-align: center;
  padding: 110px 20px 120px;
  background: linear-gradient(rgba(18,12,15,.72), rgba(18,12,15,.72)) center/cover no-repeat;
}
.hero h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); line-height: 1.15; font-weight: 700; }
.hero p.sub { font-size: clamp(1rem, 2.2vw, 1.3rem); margin: 18px auto 8px; max-width: 720px; opacity: .95; }
.hero .cta-row { margin-top: 30px; display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }
.hero .btn.ghost { color: #fff !important; border-color: #fff; }
.hero .btn.ghost:hover { background: #fff; color: var(--ink) !important; }

/* checkered accent strip */
.checker {
  height: 14px;
  background:
    repeating-conic-gradient(#171214 0% 25%, #ffffff 0% 50%) 0 0/28px 28px;
}

/* ---------- Trust bar ---------- */
.trustbar { background: var(--ink); color: #fff; padding: 18px 0; }
.trustbar .wrap {
  display: flex; flex-wrap: wrap; gap: 10px 34px; justify-content: center;
  font-size: .95rem; font-weight: 500;
}
.trustbar span { display: flex; align-items: center; gap: 8px; }
.trustbar b { color: var(--pink); }

/* ---------- Sections ---------- */
section.block { padding: 72px 0; }
section.block.alt { background: var(--paper-warm); }
.kicker {
  color: var(--pink); font-weight: 700; letter-spacing: .12em;
  text-transform: uppercase; font-size: .8rem;
}
h2.title { font-size: clamp(1.6rem, 3.5vw, 2.3rem); line-height: 1.2; margin: 6px 0 14px; }
.lead { color: var(--ink-soft); max-width: 760px; }
.center { text-align: center; }
.center .lead { margin: 0 auto; }

/* cards */
.grid { display: grid; gap: 24px; margin-top: 40px; }
.grid.cols-4 { grid-template-columns: repeat(4, 1fr); }
.grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
.grid.cols-2 { grid-template-columns: repeat(2, 1fr); }
.card {
  background: var(--paper); border: 1px solid var(--line);
  border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow);
  display: flex; flex-direction: column;
  transition: transform .18s, box-shadow .18s;
}
.card:hover { transform: translateY(-4px); box-shadow: 0 12px 32px rgba(23,18,20,.13); }
.card img { height: 190px; object-fit: cover; width: 100%; }
.card .pad { padding: 22px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.card h3 { font-size: 1.15rem; }
.card p { color: var(--ink-soft); font-size: .95rem; flex: 1; }
.card .link { font-weight: 600; color: var(--pink-dark); }

/* why us */
.why { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; margin-top: 40px; }
.why .item { text-align: center; padding: 0 10px; }
.why .ico {
  width: 62px; height: 62px; margin: 0 auto 14px; border-radius: 50%;
  background: var(--pink-soft); color: var(--pink-dark);
  display: flex; align-items: center; justify-content: center; font-size: 1.5rem;
}
.why h3 { font-size: 1.02rem; font-weight: 600; }

/* finance banner */
.finance-banner {
  background: linear-gradient(120deg, var(--pink) 0%, var(--pink-dark) 100%);
  color: #fff; border-radius: var(--radius); padding: 44px 40px;
  display: flex; align-items: center; gap: 30px; flex-wrap: wrap;
  box-shadow: var(--shadow);
}
.finance-banner h2 { font-size: clamp(1.4rem, 3vw, 2rem); }
.finance-banner p { opacity: .95; max-width: 560px; }
.finance-banner .btn { background: #fff; color: var(--ink) !important; white-space: nowrap; }
.finance-banner .btn:hover { background: var(--ink); color: #fff !important; }
.finance-banner .grow { flex: 1; min-width: 260px; }

/* steps */
.steps { counter-reset: step; display: grid; grid-template-columns: repeat(3,1fr); gap: 26px; margin-top: 40px; }
.step {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px 24px; box-shadow: var(--shadow); position: relative;
}
.step::before {
  counter-increment: step; content: counter(step);
  position: absolute; top: -18px; left: 24px;
  width: 38px; height: 38px; border-radius: 50%;
  background: var(--pink); color: #fff; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}
.step h3 { margin-bottom: 8px; font-size: 1.05rem; padding-top: 6px; }
.step p { color: var(--ink-soft); font-size: .95rem; }

/* reviews */
.quote {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 26px; box-shadow: var(--shadow); font-size: .97rem; color: var(--ink-soft);
}
.quote .stars { color: #E8A33D; letter-spacing: 2px; margin-bottom: 10px; }
.quote footer { margin-top: 12px; font-weight: 600; color: var(--ink); font-size: .9rem; }

/* faq */
.faq details {
  background: var(--paper); border: 1px solid var(--line); border-radius: 12px;
  padding: 18px 22px; margin-top: 14px; box-shadow: var(--shadow);
}
.faq summary { font-weight: 600; cursor: pointer; }
.faq p { margin-top: 10px; color: var(--ink-soft); }

/* contact / info */
.info-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 30px; margin-top: 40px; align-items: start; }
.info-card {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px; box-shadow: var(--shadow);
}
.info-card h3 { margin-bottom: 6px; }
.info-card p { color: var(--ink-soft); }
.info-card + .info-card { margin-top: 22px; }
.map-embed { border: 0; width: 100%; height: 100%; min-height: 420px; border-radius: var(--radius); box-shadow: var(--shadow); }

/* page hero (interior pages) */
.page-hero {
  background: var(--ink); color: #fff; text-align: center; padding: 64px 20px;
}
.page-hero h1 { font-size: clamp(1.8rem, 4vw, 2.6rem); }
.page-hero p { opacity: .9; max-width: 700px; margin: 12px auto 0; }

/* two-col feature */
.feature { display: grid; grid-template-columns: 1.1fr 1fr; gap: 44px; align-items: center; margin-top: 40px; }
.feature img { border-radius: var(--radius); box-shadow: var(--shadow); }
.feature ul { margin: 16px 0 0 20px; color: var(--ink-soft); }
.feature ul li { margin-bottom: 8px; }

/* ---------- Footer ---------- */
footer.site {
  background: var(--ink); color: #CFC7CB; padding: 56px 0 0; font-size: .93rem;
}
footer.site .cols {
  display: grid; grid-template-columns: 1.3fr 1fr 1fr 1.2fr; gap: 36px;
  max-width: var(--maxw); margin: 0 auto; padding: 0 20px 40px;
}
footer.site h4 { color: #fff; margin-bottom: 14px; font-size: 1rem; }
footer.site a { color: #CFC7CB; display: block; margin-bottom: 8px; }
footer.site a:hover { color: var(--pink); }
/* width:auto is required alongside the fixed height — without it the width attribute on
   the <img> wins and the logo renders stretched. Same pattern as .nav .logo img. */
footer.site .logo img { height: 52px; width: auto; margin-bottom: 14px; }
.footer-legal {
  border-top: 1px solid rgba(255,255,255,.12); padding: 18px 20px; text-align: center;
  font-size: .85rem; color: #9D939A;
}

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .grid.cols-4 { grid-template-columns: repeat(2, 1fr); }
  .why { grid-template-columns: repeat(2, 1fr); }
  footer.site .cols { grid-template-columns: 1fr 1fr; }
  .feature { grid-template-columns: 1fr; }
}
/* Nav collapses at 900px, not 720px. With Services, Tools, Gallery, Reviews, About,
   Contact, Español and the Finance button, the horizontal row no longer fits a tablet
   — below this it was squeezing the logo to 15px and wrapping the button onto two
   lines. The rest of the layout still reflows at 720px. */
@media (max-width: 900px) {
  #menu-toggle { display: block; margin-left: auto; }
  .nav ul {
    display: none; position: absolute; top: 100%; left: 0; right: 0;
    background: #fff; flex-direction: column; padding: 18px 24px 24px;
    border-bottom: 1px solid var(--line); margin: 0; gap: 4px; align-items: flex-start;
    box-shadow: 0 14px 24px rgba(0,0,0,.08);
  }
  .nav ul.open { display: flex; }
  .nav ul li { width: 100%; }
  .nav ul li a:not(.btn) { display: block; padding: 11px 0; }
  .nav .btn.nav-cta { margin-left: 0; }
}

@media (max-width: 720px) {
  .grid.cols-3, .grid.cols-2, .steps { grid-template-columns: 1fr; }
  .grid.cols-4 { grid-template-columns: 1fr; }
  .why { grid-template-columns: 1fr; }
  .info-grid { grid-template-columns: 1fr; }
  footer.site .cols { grid-template-columns: 1fr; }
  .hero { padding: 80px 20px 90px; }
}

/* ---------- Touch targets ----------
   Interactive elements need roughly 44px of tappable height. Three places fell short:
   the topbar phone number (20px), the mobile menu button (31px) and the footer links
   (25px). The phone number matters most — on a mobile local-business site it is the
   primary conversion path, and it sat in the smallest target on the page. */

.topbar { padding: 0; }
.topbar a {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 44px; padding: 0 8px;
}

/* No `display` here on purpose — the mobile media query above flips this to block, and
   restating it would override that and hide the menu button. */
#menu-toggle { min-width: 44px; min-height: 44px; line-height: 1; }

footer.site a { padding: 7px 0; margin-bottom: 2px; }

/* ---------- Open now indicator ---------- */
.open-now { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; }
.open-now .dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }
.open-now.is-open .dot { background: #35c46a; box-shadow: 0 0 0 3px rgba(53,196,106,.22); }
.open-now.is-closed .dot { background: #9aa0a6; }

/* ---------- Interactive tools ---------- */
.tool { max-width: 720px; margin: 0 auto; }
.tool-form { display: flex; flex-wrap: wrap; gap: 12px; align-items: stretch; margin: 24px 0 8px; }
.tool-form input[type="text"], .tool-form input[type="number"] {
  flex: 1 1 200px; min-height: 52px; padding: 0 16px; font: inherit; font-size: 1.05rem;
  border: 2px solid var(--line); border-radius: var(--radius); background: #fff; color: var(--ink);
}
.tool-form input:focus { outline: none; border-color: var(--pink); }
.tool-form .btn { min-height: 52px; display: inline-flex; align-items: center; }
.tool-hint { color: var(--muted); font-size: .92rem; margin-top: 4px; }

.tool-result { margin-top: 26px; padding: 26px; border-radius: var(--radius); border-left: 6px solid var(--pink); background: #fff; box-shadow: var(--shadow); }
.tool-result:focus { outline: none; }
.tool-result h3 { font-size: 1.35rem; margin-bottom: 10px; }
.tool-result p { margin-bottom: 12px; }
.tool-result .big-answer { color: var(--pink); font-weight: 700; font-size: 1.5rem; }
.tool-result.tone-ok { border-left-color: #35c46a; }
.tool-result.tone-warn { border-left-color: #e8a13a; }
.tool-result.tone-bad { border-left-color: #d6453d; }
.tool-cta { display: flex; flex-wrap: wrap; gap: 10px; margin: 18px 0 6px; }
.tool-note { color: var(--muted); font-size: .92rem; }

.tool-table { width: 100%; border-collapse: collapse; margin: 8px 0 16px; }
.tool-table th { text-align: center; vertical-align: top; padding: 12px 14px 12px 0; font-size: 1.35rem; color: var(--pink); white-space: nowrap; width: 1%; }
.tool-table td { padding: 12px 0; border-bottom: 1px solid var(--line); }
.tool-table tr:last-child td { border-bottom: none; }

/* Choice buttons — used by the tread gauge and the symptom triage */
.choices { display: grid; gap: 12px; margin-top: 22px; }
.choices.two { grid-template-columns: repeat(2, 1fr); }
.choice {
  display: block; width: 100%; text-align: left; font: inherit; cursor: pointer;
  padding: 18px 20px; min-height: 44px; border: 2px solid var(--line);
  border-radius: var(--radius); background: #fff; color: var(--ink); transition: .15s;
}
.choice:hover, .choice:focus-visible { border-color: var(--pink); transform: translateY(-1px); box-shadow: var(--shadow); }
.choice b { display: block; font-size: 1.05rem; margin-bottom: 3px; }
.choice span { color: var(--muted); font-size: .93rem; }
.choice.danger { border-color: #d6453d; }
.choice.danger b { color: #d6453d; }

.step-back { background: none; border: none; color: var(--muted); font: inherit; cursor: pointer; padding: 12px 0; min-height: 44px; text-decoration: underline; }

@media (max-width: 720px) {
  .choices.two { grid-template-columns: 1fr; }
  .tool-table th { font-size: 1.15rem; padding-right: 10px; }
}
