/* C4 — PAGE SHELL
   Header, menu, hero frame, contact strip, footer, phone tap bar.
   Phone width first; wider screens are added with min-width rules. */

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

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

body {
  margin: 0;
  background: var(--white);
  color: var(--text);
  font-family: var(--font-body);
  font-size: var(--size-body);
  line-height: var(--line-height);
  /* Room for the fixed tap bar on phones */
  padding-bottom: calc(var(--tap-min) + var(--space-3));
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

h1,
h2,
h3 {
  font-family: var(--font-heading);
  color: var(--maroon);
  line-height: 1.2;
  margin: 0 0 var(--space-2);
}

h1 { font-size: var(--size-h1); }
h2 { font-size: var(--size-h2); }
h3 { font-size: var(--size-h3); }

p {
  margin: 0 0 var(--space-2);
}

a {
  color: var(--maroon);
}

a:focus-visible,
.btn:focus-visible {
  outline: 3px solid var(--maroon);
  outline-offset: 3px;
}

.wrap {
  width: 100%;
  max-width: var(--page-max);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--maroon);
  color: var(--white);
  padding: var(--space-1) var(--space-2);
  z-index: 100;
}

.skip-link:focus {
  left: 0;
}

/* ---------- Header ---------- */

.site-header {
  border-top: 6px solid var(--maroon);
  border-bottom: 1px solid var(--line);
  background: var(--white);
}

.site-header .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-1) var(--space-3);
  padding-top: var(--space-2);
  padding-bottom: var(--space-2);
}

.brand img {
  height: 64px;
  width: auto;
}

.header-phone {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap-min);
  font-weight: 700;
  font-size: 1.125rem;
  text-decoration: none;
  white-space: nowrap;
}

.site-nav {
  flex-basis: 100%;
}

.site-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0 var(--space-3);
}

.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap-min);
  color: var(--text);
  font-weight: 600;
  text-decoration: none;
  border-bottom: 3px solid transparent;
}

.site-nav a:hover {
  color: var(--maroon);
  border-bottom-color: var(--maroon);
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--tap-min);
  padding: 0.75rem 1.5rem;
  border: 2px solid var(--maroon);
  border-radius: var(--radius);
  font-weight: 700;
  text-decoration: none;
  text-align: center;
}

.btn-primary {
  background: var(--maroon);
  color: var(--white);
}

.btn-primary:hover {
  background: var(--maroon-dark);
  border-color: var(--maroon-dark);
}

.btn-secondary {
  background: var(--white);
  color: var(--maroon);
}

.btn-secondary:hover {
  background: var(--maroon-tint);
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-top: var(--space-3);
}

/* ---------- Sections ---------- */

.section {
  padding: var(--space-5) 0;
}

.section-alt {
  background: var(--gray);
}

.section-bar {
  width: 4rem;
  height: 4px;
  background: var(--maroon);
  margin: 0 0 var(--space-3);
}

/* ---------- Contact strip ---------- */

.contact-grid {
  display: grid;
  gap: var(--space-3);
}

.contact-item h3 {
  margin-bottom: var(--space-1);
}

.contact-item a {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap-min);
  font-weight: 700;
  font-size: 1.125rem;
  overflow-wrap: anywhere;
}

.contact-item address {
  font-style: normal;
}

/* ---------- Footer ---------- */

.site-footer {
  background: var(--maroon);
  color: var(--white);
  padding: var(--space-4) 0;
  font-size: var(--size-small);
}

.site-footer a {
  color: var(--white);
}

.site-footer .wrap {
  display: grid;
  gap: var(--space-2);
}

.site-footer p {
  margin: 0;
}

.footer-utility a {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap-min);
}

/* ---------- Phone tap bar: one tap to call or email from anywhere ---------- */

.tapbar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 50;
  display: grid;
  grid-template-columns: 1fr 1fr;
  background: var(--white);
  border-top: 1px solid var(--line);
  box-shadow: 0 -2px 8px rgba(0, 0, 0, 0.12);
}

.tapbar a {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: calc(var(--tap-min) + 8px);
  padding: 0 var(--space-1);
  font-weight: 700;
  text-decoration: none;
  text-align: center;
}

.tapbar .tap-call {
  color: var(--maroon);
}

.tapbar .tap-plans {
  background: var(--maroon);
  color: var(--white);
}

/* ---------- Wider screens ---------- */

@media (min-width: 760px) {
  :root {
    --gutter: 2rem;
  }

  body {
    padding-bottom: 0;
  }

  .tapbar {
    display: none;
  }

  .brand img {
    height: 96px;
  }

  .site-header {
    position: sticky;
    top: 0;
    z-index: 40;
  }

  section[id] {
    scroll-margin-top: 140px;
  }

  .site-nav {
    flex-basis: auto;
    margin-left: auto;
    order: 2;
  }

  .header-phone {
    order: 3;
  }

  .contact-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .site-footer .wrap {
    grid-template-columns: 1fr auto;
    align-items: center;
  }
}

/* ---------- Print: a page someone can hand across a desk ---------- */

@media print {
  body {
    padding-bottom: 0;
    font-size: 11pt;
  }

  .tapbar,
  .site-nav,
  .skip-link {
    display: none;
  }

  .site-header {
    position: static;
  }

  .section-alt {
    background: none;
  }

  .site-footer {
    background: none;
    color: var(--text);
    border-top: 2px solid var(--maroon);
  }

  .site-footer a {
    color: var(--text);
  }

  .btn {
    border: 1px solid var(--text);
    background: none;
    color: var(--text);
  }
}
