/* Jacob's Repairs & Installations LLC — option 2A
   Palette and type carried over verbatim from the design canvas. */

:root {
  --red:         oklch(0.53 0.19 30);
  --red-hover:   oklch(0.46 0.18 30);
  --red-deep:    oklch(0.44 0.17 30);
  --amber:       oklch(0.82 0.09 40);

  --ink:         oklch(0.22 0.01 40);
  --ink-2:       oklch(0.3 0.01 40);
  --ink-3:       oklch(0.35 0.01 40);
  --muted:       oklch(0.45 0.01 40);
  --muted-2:     oklch(0.48 0.01 40);
  --muted-3:     oklch(0.5 0.01 40);

  --dark:        oklch(0.24 0.01 40);
  --panel:       oklch(0.97 0.004 70);
  --line:        oklch(0.91 0.004 70);
  --line-soft:   oklch(0.93 0.004 70);
  --line-strong: oklch(0.84 0.004 70);
  --line-input:  oklch(0.87 0.004 70);

  --display: Oswald, "Arial Narrow", sans-serif;
  --body: Barlow, system-ui, -apple-system, "Segoe UI", sans-serif;

  --pad: 22px;
  --shell: 1120px;
}

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

/* Several hidden elements are flex containers, whose display would otherwise
   beat the UA's [hidden] rule. */
[hidden] { display: none !important; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: #fff;
  color: var(--ink);
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; }
a { color: var(--red); text-decoration: none; }
a:hover { color: var(--red-hover); }
h1, h2, h3 { margin: 0; font-family: var(--display); font-weight: 600; }
p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
input, button, select, textarea { font: inherit; }

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

.u-sr {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap;
}

/* Honeypot: off-screen rather than display:none, which some bots detect. */
.u-hp {
  position: absolute; left: -9999px; top: auto;
  width: 1px; height: 1px; overflow: hidden;
}

.skip-link {
  position: absolute; left: 8px; top: -60px; z-index: 60;
  background: var(--red); color: #fff; padding: 10px 14px;
  font-family: var(--display); font-size: 15px; border-radius: 2px;
  transition: top .15s;
}
.skip-link:focus { top: 8px; color: #fff; }

/* ---------- header ---------- */

.topbar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
  background: #fff;
  position: sticky; top: 0; z-index: 30;
}

.brand { display: flex; align-items: center; gap: 10px; color: inherit; }
.brand:hover { color: inherit; }
.brand__mark { height: 44px; width: auto; display: block; }
.brand__name {
  display: flex; flex-direction: column; line-height: 1.08;
  font-family: var(--display); font-size: 15px; font-weight: 600;
}
/* If assets/jri-mark.png is missing, fall back to a plain wordmark rather than a broken icon. */
.brand--nomark .brand__mark { display: none; }

.topbar__actions { display: flex; align-items: center; gap: 8px; }

.btn-ghost {
  border: 1px solid var(--line-strong); background: transparent;
  color: var(--ink-3); font-size: 12px; font-weight: 700;
  letter-spacing: .08em; padding: 6px 9px; border-radius: 2px; cursor: pointer;
}
.btn-ghost:hover { border-color: var(--ink-3); }

.btn-burger {
  display: flex; flex-direction: column; justify-content: center; gap: 4px;
  width: 40px; height: 40px; padding: 0 9px;
  border: 1px solid var(--line-strong); background: transparent;
  border-radius: 2px; cursor: pointer;
}
.btn-burger__bar { display: block; height: 2px; background: var(--ink-2); }
.btn-burger:hover { border-color: var(--ink-3); }

/* ---------- hero ---------- */

.hero__copy {
  padding: 36px var(--pad) 30px;
  display: flex; flex-direction: column; gap: 16px;
}

.eyebrow {
  font-size: 11px; letter-spacing: .18em; text-transform: uppercase;
  color: var(--red); font-weight: 700;
}

.hero h1 {
  font-size: clamp(32px, 8.5vw, 40px);
  line-height: 1.05;
  text-wrap: balance;
}

.lede { font-size: 16px; line-height: 1.5; color: var(--muted); text-wrap: pretty; }

.hero__cta { display: flex; flex-direction: column; gap: 8px; margin-top: 4px; }

.hero__photo {
  width: 100%; height: 220px; object-fit: cover; display: block;
  background: var(--line);
}

.btn-primary {
  display: block; text-align: center; border: 0;
  background: var(--red); color: #fff;
  font-family: var(--display); font-size: 17px; font-weight: 600;
  letter-spacing: .03em; padding: 16px; border-radius: 2px; cursor: pointer;
}
.btn-primary:hover { background: var(--red-hover); color: #fff; }

.btn-outline {
  display: block; text-align: center; color: var(--ink-2);
  font-family: var(--display); font-size: 17px; font-weight: 500;
  padding: 12px; border: 1px solid oklch(0.86 0.004 70); border-radius: 2px;
}
.btn-outline:hover { color: var(--ink); border-color: var(--ink-2); }

/* ---------- services ---------- */

.services {
  padding: 34px var(--pad);
  display: flex; flex-direction: column; gap: 18px;
}

.section-kicker {
  font-size: 15px; letter-spacing: .12em;
  text-transform: uppercase; color: var(--muted);
}

.service-list { display: flex; flex-direction: column; }
.service-list li { display: flex; }
.service-list a {
  flex: 1;
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 15px 0;
  border-top: 1px solid var(--line);
  color: var(--ink);
  font-family: var(--display); font-size: 18px; font-weight: 500;
}
.service-list li:last-child a { border-bottom: 1px solid var(--line); }
.service-list a:hover { color: var(--red); }
.arrow { color: var(--red); transition: transform .15s; }
.service-list a:hover .arrow { transform: translateX(3px); }

.systems {
  display: flex; flex-wrap: wrap; gap: 4px 14px;
  font-size: 13px; color: var(--muted-3);
}

/* ---------- quote ---------- */

.quote {
  background: var(--panel);
  border-top: 1px solid var(--line);
  padding: 34px var(--pad);
}
.quote__inner { display: flex; flex-direction: column; gap: 16px; }

.quote-form { display: flex; flex-direction: column; gap: 14px; }
.quote-form__head { display: flex; flex-direction: column; gap: 6px; }
.quote-form__head h2 { font-size: 26px; line-height: 1.1; }
.quote-form__head p { font-size: 14.5px; line-height: 1.5; color: var(--muted-2); }

.quote-form__fields { display: flex; flex-direction: column; gap: 9px; }
.quote-form__fields input {
  border: 1px solid var(--line-input); background: #fff; border-radius: 2px;
  padding: 15px 13px; font-size: 15px; color: var(--ink);
  outline: none; width: 100%;
}
.quote-form__fields input:focus { border-color: var(--red); }
.quote-form__fields input[aria-invalid="true"] { border-color: var(--red); background: oklch(0.98 0.02 40); }

.quote-form__error { font-size: 14px; color: var(--red-deep); font-weight: 600; }

.quote-sent { display: flex; flex-direction: column; gap: 9px; padding: 6px 0; }
.quote-sent__title { font-family: var(--display); font-size: 22px; font-weight: 600; color: var(--red-deep); }
.quote-sent p { font-size: 15px; line-height: 1.55; color: oklch(0.4 0.01 40); }
.quote-sent__call { font-family: var(--display); font-size: 16px; font-weight: 600; color: var(--red-deep); }

.map { position: relative; height: 170px; border: 1px solid oklch(0.9 0.004 70); }
.map iframe { width: 100%; height: 100%; border: 0; display: block; filter: saturate(0.5); }
.map__link {
  position: absolute; right: 8px; bottom: 8px;
  background: #fff; color: var(--dark);
  font-size: 12px; font-weight: 700; padding: 7px 11px;
  box-shadow: 0 1px 6px rgb(0 0 0 / .2);
}
.map__link:hover { color: var(--red); }

/* ---------- footer ---------- */

.footer { background: var(--dark); color: oklch(0.9 0.004 70); padding: 26px var(--pad) 30px; }
.footer__inner { display: flex; flex-direction: column; gap: 6px; font-size: 14px; line-height: 1.55; }
.footer__name { font-family: var(--display); font-size: 16px; letter-spacing: .02em; color: #fff; }
.footer__link { color: var(--amber); font-weight: 600; }
.footer__link:hover { color: #fff; }
.footer__link--mail { font-weight: 400; word-break: break-all; }
.footer__note { opacity: .65; }

/* ---------- menu overlay ---------- */

.menu { position: fixed; inset: 0; z-index: 50; background: rgb(0 0 0 / .45); overflow-y: auto; }
.menu__panel {
  background: #fff; color: var(--ink);
  display: flex; flex-direction: column;
  box-shadow: 0 20px 40px -20px rgb(0 0 0 / .35);
  max-width: 480px;
}
.menu__head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 18px; border-bottom: 1px solid var(--line);
}
.menu__mark { height: 40px; width: auto; display: block; }

.btn-close {
  width: 40px; height: 40px; border: 1px solid var(--line-strong);
  background: transparent; font-size: 18px; line-height: 1;
  color: var(--ink-2); border-radius: 2px; cursor: pointer;
}
.btn-close:hover { border-color: var(--ink-2); }

.menu__title {
  background: var(--red); color: #fff; padding: 14px 18px;
  font-family: var(--display); font-size: 17px; font-weight: 600; letter-spacing: .04em;
}
.menu__nav { display: flex; flex-direction: column; }
.menu__nav a {
  padding: 16px 18px; border-bottom: 1px solid var(--line-soft);
  color: oklch(0.28 0.01 40); font-size: 17px;
}
.menu__nav a:hover { color: var(--red); background: var(--panel); }

.menu__foot { padding: 20px 18px 26px; display: flex; flex-direction: column; gap: 8px; }
.menu__foot span { text-align: center; font-size: 13px; color: var(--muted-3); }

body.is-locked { overflow: hidden; }

/* ---------- wider viewports ----------
   Same design, laid out across a centred column instead of stretched. */

@media (min-width: 700px) {
  :root { --pad: 40px; }

  .topbar { padding: 16px 40px; }
  .brand__mark { height: 54px; }
  .brand__name { font-size: 18px; }

  .hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    align-items: center;
    gap: 40px;
    max-width: var(--shell); margin: 0 auto;
    padding: 0 var(--pad);
  }
  .hero__copy { padding: 56px 0; }
  .hero h1 { font-size: clamp(38px, 4.4vw, 52px); }
  .lede { font-size: 18px; }
  .hero__cta { flex-direction: row; }
  .hero__cta .btn-primary, .hero__cta .btn-outline { flex: 1; }
  .hero__photo { height: 100%; min-height: 380px; }

  .services { max-width: var(--shell); margin: 0 auto; padding: 56px var(--pad); }
  .service-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 40px;
  }
  .service-list li:nth-last-child(2) a { border-bottom: 1px solid var(--line); }

  .quote__inner {
    max-width: var(--shell); margin: 0 auto;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    align-items: start;
    gap: 40px;
  }
  .quote { padding: 56px 0; }
  .quote__inner { padding: 0 var(--pad); }
  .quote-form, .quote-sent { grid-column: 1; }
  .map { grid-column: 2; grid-row: 1; height: 100%; min-height: 340px; }
  .quote-form__head h2 { font-size: 32px; }

  .footer__inner { max-width: var(--shell); margin: 0 auto; }
  .footer { padding: 40px var(--pad); }
}

@media (min-width: 1000px) {
  .footer__inner {
    display: grid;
    grid-template-columns: 1.4fr 1fr;
    gap: 6px 40px;
  }
  .footer__name { grid-column: 1; grid-row: 1; font-size: 20px; }
  .footer__note { grid-column: 1; grid-row: 2; }
  .footer__link { grid-column: 2; }
  .footer__link:first-of-type { grid-row: 1; }
}
