/* ============================================================
   Heating and Air Conditioning in Chicago
   Composition: warm earth editorial · museum wall labels
   ============================================================ */

:root {
  --bg: #f5efe4;
  --bg-deep: #ece3d3;
  --ink: #2b1e14;
  --ink-soft: #5b4a3c;
  --accent: #c25a37;
  --secondary: #6a7a4a;
  --rule: rgba(43, 30, 20, 0.14);
  --warm-light: rgba(226, 168, 106, 0.42);
  --glow-y: 18%;
  --card: rgba(255, 252, 246, 0.72);
  --maxw: 1120px;
  --pad: clamp(1.25rem, 5vw, 3.5rem);
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1a1410;
    --bg-deep: #221a14;
    --ink: #f2e8da;
    --ink-soft: #c3b3a1;
    --accent: #e07a52;
    --secondary: #9aab72;
    --rule: rgba(242, 232, 218, 0.16);
    --warm-light: rgba(196, 118, 62, 0.30);
    --card: rgba(38, 29, 22, 0.66);
  }
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font-family: "Inter", system-ui, -apple-system, sans-serif;
  font-weight: 400;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 3px; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 2px;
}

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ---------- background: soft light source that follows scroll ---------- */

.glow {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 50% var(--glow-y), var(--warm-light) 0, transparent 62%),
    linear-gradient(180deg, transparent 0%, transparent 70%, var(--bg-deep) 100%);
  transition: background-position 0.15s linear;
}

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

.site-head {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 1rem 1.5rem;
  flex-wrap: wrap;
  padding: 0.85rem var(--pad);
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--rule);
  animation: slide-down 0.7s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}

.wordmark { text-decoration: none; color: var(--ink); line-height: 1.1; }
.wordmark-main {
  display: block;
  font-family: "Fraunces", Georgia, serif;
  font-size: 1.15rem;
  font-variation-settings: "wght" 600, "opsz" 20;
  letter-spacing: -0.01em;
}
.wordmark-sub {
  display: block;
  font-size: 0.62rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

.site-nav {
  display: flex;
  gap: 1.25rem;
  margin-inline-start: auto;
  flex-wrap: wrap;
}
.site-nav a {
  color: var(--ink-soft);
  text-decoration: none;
  font-size: 0.82rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.5rem 0.1rem;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  border-bottom: 1px solid transparent;
}
.site-nav a:hover { color: var(--ink); border-bottom-color: var(--accent); }

.call-btn {
  display: inline-flex;
  align-items: baseline;
  gap: 0.5rem;
  min-height: 44px;
  padding: 0.55rem 1rem;
  background: var(--accent);
  color: #fff8f2;
  text-decoration: none;
  border-radius: 2px;
  font-size: 0.9rem;
  letter-spacing: 0.01em;
}
.call-btn .call-label {
  font-size: 0.62rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  opacity: 0.85;
}
.call-btn .call-num { font-weight: 600; font-variant-numeric: tabular-nums; }
.call-btn:hover { background: color-mix(in srgb, var(--accent) 84%, #000); }

/* ---------- layout shell ---------- */

main { position: relative; z-index: 1; }

section {
  max-width: var(--maxw);
  margin-inline: auto;
  padding: clamp(3.5rem, 9vw, 7rem) var(--pad);
}

.eyebrow {
  font-size: 0.68rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--secondary);
  margin: 0 0 1rem;
  font-weight: 500;
}

.section-head { max-width: 46rem; margin-bottom: clamp(2rem, 5vw, 3.5rem); }
.section-head h2 {
  font-family: "Fraunces", Georgia, serif;
  font-variation-settings: "wght" 400, "opsz" 60;
  font-size: clamp(1.7rem, 4.2vw, 2.7rem);
  line-height: 1.12;
  letter-spacing: -0.02em;
  margin: 0 0 0.9rem;
  text-wrap: pretty;
}
.section-note { color: var(--ink-soft); margin: 0; max-width: 38rem; }

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

.hero {
  padding-top: clamp(3rem, 8vw, 6rem);
  padding-bottom: clamp(2.5rem, 6vw, 4.5rem);
}

.hero-title {
  font-family: "Fraunces", Georgia, serif;
  font-size: clamp(2.4rem, 8.5vw, 5.4rem);
  line-height: 1.02;
  letter-spacing: -0.035em;
  margin: 0 0 1.5rem;
  position: relative;
  font-variation-settings: "wght" 200, "opsz" 144;
  transition: font-variation-settings 0.45s cubic-bezier(0.2, 0.7, 0.2, 1);
  cursor: default;
  max-width: 18ch;
}
.hero-title:hover,
.hero-title:focus-visible { font-variation-settings: "wght" 900, "opsz" 144; }

.hero-title .default,
.hero-title .alt {
  display: block;
  transition: opacity 0.4s ease;
}
.hero-title .alt {
  position: absolute;
  inset: 0;
  opacity: 0;
  color: var(--accent);
  font-variation-settings: "wght" 700, "opsz" 144;
  font-style: italic;
}
.hero-title:hover .default,
.hero-title:focus-visible .default { opacity: 0; }
.hero-title:hover .alt,
.hero-title:focus-visible .alt { opacity: 1; }

.hero-lede {
  font-size: clamp(1rem, 1.6vw, 1.15rem);
  color: var(--ink-soft);
  max-width: 40rem;
  margin: 0 0 2rem;
  text-wrap: pretty;
}

.hero-actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-bottom: 3rem; }

.btn-primary,
.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0.8rem 1.5rem;
  text-decoration: none;
  border-radius: 2px;
  font-size: 0.95rem;
  letter-spacing: 0.01em;
}
.btn-primary {
  background: var(--ink);
  color: var(--bg);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.btn-primary:hover { background: var(--accent); color: #fff8f2; }
.btn-ghost { border: 1px solid var(--rule); color: var(--ink); }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }

.hero-facts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 1.25rem 2rem;
  margin: 0;
  padding-top: 1.75rem;
  border-top: 1px solid var(--rule);
}
.hero-facts dt {
  font-size: 0.62rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--secondary);
  margin-bottom: 0.3rem;
}
.hero-facts dd { margin: 0; font-size: 0.95rem; font-variant-numeric: tabular-nums; }

/* ---------- services: museum wall labels ---------- */

.wall {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: clamp(2.25rem, 5vw, 4rem) clamp(1.75rem, 4vw, 3.25rem);
}

.work-item {
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 1.1rem;
}

.work-item figure {
  margin: 0;
  overflow: hidden;
  background: var(--bg-deep);
  aspect-ratio: 4 / 3;
}
.work-item figure img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.work-item:hover figure img { transform: scale(1.03); }

.work-item .label {
  border-left: 2px solid var(--accent);
  padding-left: 0.9rem;
}
.work-item .label h3 {
  font-family: "Fraunces", Georgia, serif;
  font-variation-settings: "wght" 500, "opsz" 30;
  font-size: 1.15rem;
  letter-spacing: -0.01em;
  margin: 0 0 0.35rem;
}
.work-item .meta {
  font-size: 0.7rem;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--secondary);
  margin: 0 0 0.7rem;
}
.work-item .desc {
  font-size: 0.92rem;
  color: var(--ink-soft);
  margin: 0;
  text-wrap: pretty;
}

/* ---------- recent work list ---------- */

.job-list {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--rule);
}
.job-list li {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0.4rem;
  padding: 1.4rem 0;
  border-bottom: 1px solid var(--rule);
}
@media (min-width: 720px) {
  .job-list li { grid-template-columns: 20rem minmax(0, 1fr); gap: 2.5rem; align-items: baseline; }
}
.job-place {
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--secondary);
}
.job-desc { color: var(--ink-soft); font-size: 0.95rem; text-wrap: pretty; }

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

.about-body { max-width: 44rem; }
.about-body p { margin: 0 0 1.15rem; color: var(--ink-soft); text-wrap: pretty; }
.about-body p:first-child { color: var(--ink); }

.credentials {
  list-style: none;
  margin: 2.5rem 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 0.75rem 2rem;
}
.credentials li {
  font-size: 0.85rem;
  color: var(--ink-soft);
  padding-left: 1.1rem;
  position: relative;
}
.credentials li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.62em;
  width: 0.42rem;
  height: 0.42rem;
  background: var(--secondary);
  border-radius: 50%;
}

/* ---------- visit ---------- */

.visit-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.25rem;
}

.visit-card {
  background: var(--card);
  border: 1px solid var(--rule);
  padding: 1.6rem 1.5rem;
  backdrop-filter: blur(6px);
}
.visit-card h3 {
  font-size: 0.68rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--secondary);
  margin: 0 0 1rem;
  font-weight: 500;
}

.big-phone {
  margin: 0 0 0.9rem;
  font-family: "Fraunces", Georgia, serif;
  font-variation-settings: "wght" 600, "opsz" 40;
  font-size: clamp(1.4rem, 3.5vw, 1.85rem);
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}
.big-phone a { text-decoration: none; }
.big-phone a:hover { text-decoration: underline; }

.hours { width: 100%; border-collapse: collapse; font-size: 0.88rem; }
.hours th, .hours td { text-align: left; padding: 0.34rem 0; font-weight: 400; }
.hours th { color: var(--ink-soft); }
.hours td { text-align: right; font-variant-numeric: tabular-nums; }
.hours tr + tr th, .hours tr + tr td { border-top: 1px solid var(--rule); }

.visit-card address { font-style: normal; color: var(--ink-soft); margin-bottom: 0.9rem; }
.fine { font-size: 0.85rem; color: var(--ink-soft); margin: 0; text-wrap: pretty; }

.visit-note {
  margin: 2.25rem 0 0;
  padding: 1.1rem 1.25rem;
  border-left: 2px solid var(--secondary);
  background: var(--card);
  font-size: 0.92rem;
  color: var(--ink-soft);
  max-width: 44rem;
}

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

.site-foot {
  position: relative;
  z-index: 1;
  border-top: 1px solid var(--rule);
  background: var(--bg-deep);
  padding: clamp(2.5rem, 6vw, 4rem) var(--pad) 5rem;
}
.foot-inner { max-width: var(--maxw); margin-inline: auto; }
.foot-name {
  font-family: "Fraunces", Georgia, serif;
  font-variation-settings: "wght" 500, "opsz" 30;
  font-size: 1.1rem;
  margin: 0 0 0.5rem;
}
.foot-line { font-size: 0.85rem; color: var(--ink-soft); margin: 0 0 0.35rem; }

.claim-banner {
  display: inline-block;
  margin-top: 1.75rem;
  padding: 0.5rem 0.85rem;
  font-size: 0.78rem;
  color: var(--ink-soft);
  background: color-mix(in srgb, var(--ink) 6%, transparent);
  border: 1px solid var(--rule);
  border-radius: 2px;
  text-decoration: none;
}
.claim-banner:hover { color: var(--accent); border-color: var(--accent); }

.attribution {
  margin: 1.5rem 0 0;
  font-size: 0.72rem;
  opacity: 0.6;
}
.attribution a { color: inherit; }

/* ---------- page-load orchestration (one shot, then still) ---------- */

@keyframes slide-down {
  from { transform: translateY(-100%); opacity: 0; }
  to   { transform: translateY(0);     opacity: 1; }
}
@keyframes rise-in {
  from { transform: translateY(14px); opacity: 0; }
  to   { transform: translateY(0);    opacity: 1; }
}
@keyframes fade-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.hero .eyebrow      { animation: fade-in 0.6s ease both; animation-delay: 0.12s; }
.hero-title         { animation: rise-in 0.75s cubic-bezier(0.2, 0.7, 0.2, 1) both; animation-delay: 0.24s; }
.hero-lede          { animation: rise-in 0.75s cubic-bezier(0.2, 0.7, 0.2, 1) both; animation-delay: 0.36s; }
.hero-actions       { animation: rise-in 0.75s cubic-bezier(0.2, 0.7, 0.2, 1) both; animation-delay: 0.48s; }
.hero-facts         { animation: fade-in 0.8s ease both; animation-delay: 0.6s; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-delay: 0ms !important;
    transition-duration: 0.01ms !important;
  }
  .hero-title .alt { display: none; }
  .hero-title:hover .default, .hero-title:focus-visible .default { opacity: 1; }
}
