/* ==========================================================================
   All Z Well Gas

   Hand-written for this site. No framework, no build step.
   The only outside resource is the IBM Plex Sans webfont (two weights).

   Colours are measured off assets/brand/allzwellgas-logo.png:
     ink     #0A1139   the "GAS" lettering, used for text
     blue    #082E9C   "ALL" / "WELL", used for headings, links, buttons
     flame   #F64B06   the "Z", used only for small accents (icons, focus)

   The logo's "GAS" is near-black, so the logo only sits on white or the
   light tint. Orange is never a background.

   The file follows the page from top to bottom:
     tokens · base · placeholders · buttons · site head · hero · facts ·
     sections · services · our work · photo viewer · about · team ·
     contact · site foot
   ========================================================================== */

:root {
  --ink:    #0A1139;
  --text:   #2A3150;
  --muted:  #5A6380;
  --blue:   #082E9C;
  --blue-d: #062373;
  --flame:  #F64B06;
  --paper:  #FFFFFF;
  --tint:   #F4F6FA;
  --line:   #DDE2EC;

  --font: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --measure: 70rem;
  --gutter: clamp(1rem, 4vw, 2rem);
  --radius: 6px;
}

/* base ------------------------------------------------------------------ */

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

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

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--text);
  font: 400 1rem/1.65 var(--font);
}

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

h1, h2, h3 { margin: 0; color: var(--ink); font-weight: 600; line-height: 1.2; }
h1 { font-size: clamp(1.9rem, 4vw, 2.6rem); text-wrap: balance; }
h2 { font-size: 1.6rem; }
h3 { font-size: 1.1rem; }

p { margin: 0; }

a { color: var(--blue); }
a:focus-visible, button:focus-visible, summary:focus-visible, video:focus-visible {
  outline: 2px solid var(--flame);
  outline-offset: 3px;
}

.wrap {
  max-width: calc(var(--measure) + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.sprite { display: none; }

svg {
  width: 1.1em;
  height: 1.1em;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

[id] { scroll-margin-top: 1rem; }

.skip {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 100;
  padding: 0.6rem 1rem;
  background: var(--blue);
  color: var(--paper);
  border-radius: var(--radius);
}
.skip:focus { top: 1rem; }

/* placeholders waiting on the client ----------------------------------- */

.tbc {
  display: inline-block;
  padding: 0.05rem 0.45rem;
  border: 1.5px dashed var(--flame);
  background: #FFF6E5;
  color: var(--ink);
  font-size: 0.85rem;
  line-height: 1.5;
}
.tbc::before { content: "TBC: "; font-weight: 600; }

/* buttons --------------------------------------------------------------- */

.actions { display: flex; flex-wrap: wrap; gap: 0.75rem; }

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.65rem 1.1rem;
  border: 1.5px solid var(--blue);
  border-radius: var(--radius);
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
}

.btn--primary { background: var(--blue); color: var(--paper); }
.btn--primary:hover { background: var(--blue-d); border-color: var(--blue-d); }

.btn--secondary { background: var(--paper); color: var(--blue); }
.btn--secondary:hover { background: var(--tint); }

/* site head ------------------------------------------------------------- */

.site-head { border-bottom: 1px solid var(--line); background: var(--paper); }

.site-head__inner {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  min-height: 6rem;
}

.site-head__logo img { width: 5.25rem; }

.nav { display: flex; gap: 1.5rem; margin-left: auto; }
.nav a, .menu__panel a { color: var(--ink); text-decoration: none; font-weight: 600; font-size: 0.95rem; }
.nav a:hover { color: var(--blue); }

.site-head__contact { display: flex; align-items: center; gap: 1rem; }
.site-head__phone { color: var(--ink); text-decoration: none; font-weight: 600; }

.icon-btn {
  display: none;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--blue);
  cursor: pointer;
  list-style: none;
}
.icon-btn svg { width: 1.3rem; height: 1.3rem; }
.icon-btn::-webkit-details-marker { display: none; }

.menu { position: relative; display: none; }
.menu__panel {
  position: absolute;
  right: 0;
  top: calc(100% + 0.5rem);
  z-index: 10;
  display: grid;
  min-width: 13rem;
  padding: 0.5rem;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 8px 24px rgba(10, 17, 57, 0.12);
}
.menu__panel a { padding: 0.7rem 0.75rem; border-radius: 4px; }
.menu__panel a:hover { background: var(--tint); }
.menu__panel a:last-child { margin-top: 0.25rem; border-top: 1px solid var(--line); color: var(--blue); }

@media (max-width: 60rem) {
  .nav, .site-head__contact { display: none; }
  .site-head__call { display: grid; margin-left: auto; }
  .menu { display: block; }
  .menu > summary { display: grid; }
  .site-head__inner { gap: 0.6rem; min-height: 5rem; }
  .site-head__logo img { width: 4.25rem; }
}

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

.hero { padding-block: clamp(2.5rem, 6vw, 4.5rem); }

.hero__inner {
  display: grid;
  gap: 2.5rem;
  align-items: center;
}

.hero__text { display: grid; gap: 1.25rem; justify-items: start; }
.hero__lede { font-size: 1.125rem; color: var(--muted); max-width: 34rem; }

.hero__photo { margin: 0; }
.hero__photo img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  object-position: center 30%;
  border-radius: var(--radius);
}

@media (min-width: 56rem) {
  .hero__inner { grid-template-columns: minmax(0, 1fr) 26rem; gap: 4rem; }
  .hero__photo img { aspect-ratio: 4 / 5; }
}

/* facts strip ----------------------------------------------------------- */

.facts { border-block: 1px solid var(--line); background: var(--tint); }

.facts__inner {
  display: grid;
  gap: 1.25rem;
  padding-block: 1.5rem;
}

.facts h2 {
  font-size: 0.85rem;
  color: var(--muted);
  margin-bottom: 0.2rem;
}
.facts p { color: var(--ink); }

@media (min-width: 48rem) {
  .facts__inner { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2rem; }
  .facts__inner > div + div { border-left: 1px solid var(--line); padding-left: 2rem; }
}

/* sections -------------------------------------------------------------- */

.section { padding-block: clamp(3rem, 7vw, 5rem); }
.section--tint { background: var(--tint); }

.section__title { margin-bottom: 0.75rem; }
.section__intro { color: var(--muted); margin-bottom: 2rem; }
.section__title + .services, .section__title + .team { margin-top: 2rem; }

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

.services {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 2rem 2.5rem;
}

.services li { display: grid; gap: 0.4rem; align-content: start; }
.services p { color: var(--muted); }

.services__icon {
  width: 2rem;
  height: 2rem;
  margin-bottom: 0.4rem;
  color: var(--flame);
  stroke-width: 1.6;
}

@media (min-width: 40rem) { .services { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 60rem) { .services { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

/* our work -------------------------------------------------------------- */

.work-group + .work-group { margin-top: 3rem; padding-top: 2.5rem; border-top: 1px solid var(--line); }
.work-group > h3 { margin-bottom: 1.25rem; }

.gallery {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.25rem 1rem;
}

.gallery a { display: block; border-radius: var(--radius); }

.gallery img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--paper);
}
.gallery a:hover img { border-color: var(--blue); }

.gallery p { margin-top: 0.45rem; font-size: 0.9rem; color: var(--text); line-height: 1.4; }

@media (min-width: 40rem) { .gallery { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 60rem) { .gallery { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

/* the water-heater group: the video beside its photos */
.work-group__media { display: grid; gap: 1.5rem; }

.video { margin: 0; width: 100%; max-width: 20rem; }
.video video {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 9 / 16;
  background: var(--ink);
  border-radius: var(--radius);
}
.video__frame { position: relative; }

.video__play {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  width: 100%;
  padding: 0;
  border: 0;
  border-radius: var(--radius);
  background: linear-gradient(to top, rgba(10, 17, 57, 0.35), rgba(10, 17, 57, 0) 45%);
  cursor: pointer;
}
.video__play[hidden] { display: none; }

.video__play-icon {
  display: grid;
  place-items: center;
  width: 4rem;
  height: 4rem;
  border-radius: 50%;
  background: var(--paper);
  color: var(--blue);
  box-shadow: 0 4px 16px rgba(10, 17, 57, 0.3);
}
.video__play-icon svg { width: 1.8rem; height: 1.8rem; margin-left: 0.2rem; fill: currentColor; stroke: none; }
.video__play:hover .video__play-icon { background: var(--tint); }

.video figcaption { margin-top: 0.45rem; font-size: 0.9rem; line-height: 1.4; }

@media (min-width: 60rem) {
  .work-group__media { grid-template-columns: 16rem minmax(0, 1fr); gap: 1.5rem; align-items: start; }
  .work-group__media .gallery { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* photo viewer (site.js) ------------------------------------------------ */

.viewer {
  width: 100%;
  max-width: none;
  height: 100%;
  max-height: none;
  margin: 0;
  padding: 3.5rem 0.5rem 1.5rem;
  border: 0;
  background: transparent;
  color: var(--paper);
}
.viewer::backdrop { background: rgba(10, 17, 57, 0.94); }
.viewer[open] { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 0.5rem; }

.viewer figure { margin: 0; display: grid; gap: 0.75rem; justify-items: center; }
.viewer__img {
  width: auto;
  max-width: min(100%, 1080px);
  max-height: calc(100vh - 9rem);
  max-height: calc(100dvh - 9rem);
  border-radius: 4px;
}
.viewer__caption { text-align: center; }

.viewer__btn {
  display: grid;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  padding: 0;
  color: var(--paper);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: var(--radius);
  cursor: pointer;
}
.viewer__btn:hover { background: rgba(255, 255, 255, 0.18); }
.viewer__btn svg { width: 1.4rem; height: 1.4rem; }
.viewer__close { position: absolute; top: 0.75rem; right: 0.75rem; }

/* about ----------------------------------------------------------------- */

.about__text { display: grid; gap: 1rem; max-width: 40rem; font-size: 1.0625rem; }

/* team ------------------------------------------------------------------ */

.team {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.5rem 1rem;
}

.team img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: center 20%;
  border-radius: var(--radius);
  margin-bottom: 0.75rem;
}

/* keep each partner's face in the 4:5 crop */
.team .team__photo--bright   { object-position: 70% 22%; }
.team .team__photo--blessing { object-position: 60% 30%; }
.team .team__photo--trueman  { object-position: 50% 18%; }

.team__name { font-weight: 600; color: var(--ink); }
.team__role { color: var(--muted); font-size: 0.95rem; }

@media (min-width: 56rem) { .team { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1.5rem; } }

/* contact --------------------------------------------------------------- */

.contact { display: grid; gap: 2.5rem; }

.contact__list {
  display: grid;
  grid-template-columns: 7rem minmax(0, 1fr);
  gap: 0.75rem 1rem;
  margin: 1.5rem 0 2rem;
}
.contact__list dt { color: var(--muted); }
.contact__list dd { margin: 0; color: var(--ink); }
.contact__list a { font-weight: 600; }

.contact h3 { margin-bottom: 0.5rem; }

@media (min-width: 56rem) {
  .contact { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 4rem; }
  .contact > div + div { padding-top: 3.1rem; }
}

/* site foot ------------------------------------------------------------- */

.site-foot { border-top: 1px solid var(--line); font-size: 0.925rem; }

.site-foot__inner {
  display: grid;
  gap: 2rem;
  padding-block: 2.5rem;
}

.site-foot__logo { width: 5rem; }
.site-foot h2 { font-size: 0.95rem; margin-bottom: 0.5rem; }
.site-foot p { color: var(--muted); }
.site-foot a { color: var(--muted); }

.site-foot__legal {
  padding-block: 1.25rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.85rem;
}

@media (min-width: 40rem) { .site-foot__inner { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 56rem) { .site-foot__inner { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
