/* AM Speed Electrical — Wanneroo WA */
:root {
  --green: #5fbb46;
  --green-d: #4a9c34;
  --navy: #1b3e8c;
  --navy-d: #142f6b;
  --yellow: #ffd500;
  --ink: #1a1a1a;
  --black: #000;
  --paper: #f5f4f1;
  --line: #e2e0da;
  --muted: #5d5d5d;
  --on-dark: #cfcfcb;
  --max: 1080px;
  --dock: 64px;
  --display: "Archivo", "Arial Black", system-ui, sans-serif;
  --body: "Manrope", "Segoe UI", system-ui, sans-serif;
}

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
html, body { margin: 0; padding: 0; }

body {
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--ink);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  padding-left: env(safe-area-inset-left, 0px);
  padding-right: env(safe-area-inset-right, 0px);
  padding-bottom: calc(var(--dock) + env(safe-area-inset-bottom, 0px));
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; touch-action: manipulation; }

.wrap { width: min(var(--max), calc(100% - 36px)); margin-inline: auto; }

.skip {
  position: absolute;
  left: 12px;
  top: -60px;
  z-index: 100;
  background: var(--green);
  color: var(--ink);
  font-weight: 700;
  padding: 12px 16px;
  border-radius: 4px;
  text-decoration: none;
}
.skip:focus { top: calc(12px + env(safe-area-inset-top, 0px)); }

/* ---------- Wordmark ---------- */
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  min-width: 0;
  min-height: 44px;
}
.brand-mark { width: 34px; height: 34px; flex: none; }
.brand-text { display: flex; flex-direction: column; line-height: 1; min-width: 0; }
.brand-am {
  font-family: var(--display);
  font-weight: 800;
  font-size: 1.24rem;
  letter-spacing: -.01em;
  text-transform: uppercase;
  color: var(--green);
}
.brand-el {
  font-family: var(--display);
  font-weight: 700;
  font-size: .64rem;
  letter-spacing: .3em;
  text-transform: uppercase;
  color: #fff;
  background: var(--navy);
  padding: 3px 6px 3px 7px;
  margin-top: 5px;
  align-self: flex-start;
  border-radius: 2px;
}

/* ---------- Header ---------- */
.site-header {
  background: var(--black);
  border-bottom: 3px solid var(--green);
  padding-top: env(safe-area-inset-top, 0px);
}
.site-header .wrap {
  min-height: 66px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.header-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  min-width: 44px;
  padding: 10px 15px;
  background: var(--green);
  color: var(--ink);
  font-weight: 700;
  font-size: .92rem;
  text-decoration: none;
  border-radius: 4px;
  white-space: nowrap;
}
.header-cta:hover, .header-cta:active { background: var(--yellow); }
@media (max-width: 379px) {
  .header-cta { padding: 10px 12px; font-size: .86rem; }
  .brand-am { font-size: 1.1rem; }
}

/* ---------- Hero ---------- */
.hero { background: var(--ink); }
.hero-photo { background: var(--black); }
.hero-photo img {
  width: 100%;
  height: auto;
  object-fit: contain;
}
.hero-copy {
  background: var(--ink);
  color: #fff;
  padding: 26px 0 34px;
}
.badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 18px;
}
.badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: .74rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  padding: 7px 11px;
  border-radius: 999px;
}
.badge-hours { background: rgba(95, 187, 70, .16); color: var(--green); }
.badge-area { background: rgba(255, 255, 255, .09); color: var(--on-dark); }
.dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--yellow);
  flex: none;
}
.hero h1 {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(2rem, 8.2vw, 3.4rem);
  line-height: 1.05;
  letter-spacing: -.03em;
  margin: 0 0 14px;
  max-width: 16ch;
}
.hero h1 em { font-style: normal; color: var(--green); }
.lede {
  font-size: 1.04rem;
  color: var(--on-dark);
  margin: 0 0 16px;
  max-width: 40ch;
}
.rating {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: .92rem;
  font-weight: 600;
  color: #ecebe7;
  margin: 0 0 24px;
}
.stars { color: var(--yellow); letter-spacing: 1px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  min-width: 44px;
  padding: 13px 22px;
  font-family: var(--body);
  font-weight: 700;
  font-size: 1rem;
  text-decoration: none;
  border-radius: 4px;
}
.btn-primary { background: var(--green); color: var(--ink); }
.btn-primary:hover, .btn-primary:active { background: var(--yellow); }
.btn-ghost { background: transparent; color: #fff; border: 1px solid rgba(255,255,255,.4); }
.btn-ghost:hover, .btn-ghost:active { background: #fff; color: var(--ink); }
.btn-wide { width: 100%; max-width: 320px; }

/* ---------- Shared section bits ---------- */
.section-kicker {
  font-family: var(--display);
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--green-d);
  margin: 0 0 10px;
}
.section-title {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(1.6rem, 5.4vw, 2.3rem);
  line-height: 1.12;
  letter-spacing: -.025em;
  margin: 0 0 22px;
  max-width: 20ch;
}

/* ---------- Services ---------- */
.services { background: #fff; padding: 52px 0 56px; }
.service-list {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 2px solid var(--ink);
}
.service-list li {
  padding: 20px 0 22px;
  border-bottom: 1px solid var(--line);
}
.service-list h3 {
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.18rem;
  letter-spacing: -.015em;
  margin: 0 0 5px;
  color: var(--navy);
}
.service-list p { margin: 0; color: var(--muted); font-size: .96rem; max-width: 52ch; }

/* ---------- Proof ---------- */
.proof { background: var(--navy); color: #fff; padding: 52px 0 56px; }
.proof .section-kicker { color: var(--yellow); }
.proof-top { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 20px; }
.rating-num {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(3.4rem, 16vw, 5rem);
  line-height: .9;
  letter-spacing: -.04em;
  color: var(--green);
}
.rating-meta { display: flex; flex-direction: column; gap: 2px; }
.rating-meta .stars { font-size: 1.05rem; }
.rating-count { font-size: .98rem; color: #d5ddf0; }
.maps-link {
  display: inline-flex;
  align-items: center;
  align-self: flex-start;
  min-height: 44px;
  font-weight: 700;
  color: #fff;
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: var(--green);
}
.maps-link:hover { color: var(--green); }
.proof-note {
  margin: 20px 0 0;
  font-size: 1.05rem;
  color: #dbe2f2;
  max-width: 40ch;
}

/* ---------- The business ---------- */
.area { background: var(--paper); padding: 52px 0 56px; }
.area p { color: #3d3d3d; margin: 0 0 14px; max-width: 52ch; }
.hours-card {
  margin-top: 24px;
  padding: 16px 18px;
  background: #fff;
  border-left: 4px solid var(--green);
  max-width: 44ch;
}
.hours-card strong {
  display: block;
  font-family: var(--display);
  font-size: 1rem;
  letter-spacing: .02em;
  text-transform: uppercase;
  margin-bottom: 4px;
}
.hours-card p { margin: 0; font-size: .95rem; color: var(--muted); }

/* ---------- Closer ---------- */
.closer { background: var(--ink); color: #fff; padding: 52px 0 56px; text-align: center; }
.closer h2 {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(1.6rem, 5.4vw, 2.3rem);
  letter-spacing: -.025em;
  margin: 0 0 10px;
}
.closer p { color: var(--on-dark); margin: 0 auto 24px; max-width: 34ch; }
.closer .btn-wide { margin-inline: auto; }
.phone-xl {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  margin-top: 18px;
  padding: 4px 8px;
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(1.9rem, 8vw, 2.8rem);
  letter-spacing: -.02em;
  color: var(--green);
  text-decoration: none;
}
.phone-xl:hover { color: var(--yellow); }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--black);
  color: #9d9d9a;
  padding: 34px 0 30px;
  font-size: .94rem;
}
.foot-grid { display: flex; flex-wrap: wrap; gap: 14px 36px; }
.foot-brand { display: flex; flex-direction: column; align-items: flex-start; }
.foot-col { display: flex; flex-direction: column; min-width: 140px; }
.foot-col a, .foot-col span {
  display: inline-flex;
  align-items: center;
  align-self: flex-start;
  min-height: 44px;
}
.foot-col a { color: #ededea; text-decoration: none; }
.foot-col a:hover { color: var(--green); text-decoration: underline; }
.foot-note {
  margin: 22px 0 0;
  padding-top: 16px;
  border-top: 1px solid #2b2b2b;
  font-size: .84rem;
  color: #8b8b88;
}
.foot-fine { margin: 6px 0 0; font-size: .78rem; color: #6e6e6b; max-width: 56ch; }

/* ---------- Sticky contact dock ---------- */
.dock {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 60;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  background: var(--black);
  border-top: 2px solid var(--green);
  padding-bottom: env(safe-area-inset-bottom, 0px);
  padding-left: env(safe-area-inset-left, 0px);
  padding-right: env(safe-area-inset-right, 0px);
}
.dock a {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: var(--dock);
  font-weight: 700;
  font-size: 1rem;
  text-decoration: none;
}
.dock-primary { background: var(--green); color: var(--ink); }
.dock-primary:hover, .dock-primary:active { background: var(--yellow); }
.dock-secondary { background: var(--black); color: #fff; }
.dock-secondary:hover, .dock-secondary:active { color: var(--green); }

#top, #main, #services, #reviews, #area {
  scroll-margin-top: calc(10px + env(safe-area-inset-top, 0px));
  scroll-margin-bottom: calc(var(--dock) + env(safe-area-inset-bottom, 0px) + 12px);
}

/* ---------- Wider screens ---------- */
@media (min-width: 700px) {
  .hero-photo { max-width: 1536px; margin-inline: auto; }
  .hero-copy { padding: 36px 0 44px; }
  .services, .proof, .area, .closer { padding: 72px 0 76px; }
  .service-list { display: grid; grid-template-columns: 1fr 1fr; column-gap: 40px; }
  .rating-meta { flex-direction: row; align-items: center; gap: 16px; }
  .dock { grid-template-columns: minmax(0, 320px) minmax(0, 320px); justify-content: center; gap: 0 1px; }
}

/* ---------- Focus ---------- */
a:focus-visible {
  outline: 3px solid var(--yellow);
  outline-offset: 3px;
}
