/* ==========================================================================
   STL Manufacturing — stlmfg.com
   ========================================================================== */

:root {
  --ink: #16181c;
  --ink-soft: #43484f;
  --ink-faint: #6b7178;
  --paper: #faf8f5;
  --paper-raised: #ffffff;
  --line: #e4dfd7;
  --rust: #b0552a;
  --rust-deep: #8f3f1c;
  --rust-tint: #f4e5db;
  --steel: #23272e;
  --steel-deep: #191c21;
  --max: 1120px;
  --radius: 10px;
  --shadow: 0 1px 2px rgba(22, 24, 28, 0.06), 0 8px 24px rgba(22, 24, 28, 0.07);
  --font-display: "Barlow Condensed", "Arial Narrow", sans-serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}

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

a { color: var(--rust-deep); }

.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* --- Typography ------------------------------------------------------- */

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.08;
  letter-spacing: 0.01em;
  text-wrap: balance;
}

.kicker {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--rust);
  margin-bottom: 0.75rem;
}

.section-title {
  font-size: clamp(2.1rem, 4.5vw, 3rem);
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.section-intro {
  max-width: 46rem;
  color: var(--ink-soft);
  margin-bottom: 3rem;
}

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

.btn {
  display: inline-block;
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 0.8rem 1.9rem;
  border-radius: 6px;
  border: 2px solid transparent;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.btn-primary {
  background: var(--rust);
  color: #fff;
}
.btn-primary:hover { background: var(--rust-deep); }

.btn-ghost {
  background: transparent;
  color: #fff;
  border-color: rgba(255, 255, 255, 0.65);
}
.btn-ghost:hover { border-color: #fff; background: rgba(255, 255, 255, 0.1); }

.btn-dark {
  background: var(--steel);
  color: #fff;
}
.btn-dark:hover { background: var(--steel-deep); }

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(25, 28, 33, 0.92);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.brand {
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #fff;
  text-decoration: none;
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
}
.brand .brand-mark { color: var(--rust); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  list-style: none;
}

.nav-links a {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.85);
  text-decoration: none;
  padding: 0.25rem 0;
  border-bottom: 2px solid transparent;
  transition: color 0.15s ease, border-color 0.15s ease;
}

.nav-links a:hover,
.nav-links a[aria-current="page"] {
  color: #fff;
  border-bottom-color: var(--rust);
}

.nav-links .nav-cta {
  background: var(--rust);
  color: #fff;
  padding: 0.45rem 1.1rem;
  border-radius: 6px;
  border-bottom: none;
}
.nav-links .nav-cta:hover { background: var(--rust-deep); }

.nav-toggle {
  display: none;
  background: none;
  border: 0;
  color: #fff;
  font-size: 1.7rem;
  line-height: 1;
  cursor: pointer;
  padding: 0.4rem;
}

@media (max-width: 720px) {
  .nav-toggle { display: block; }
  .nav-links {
    display: none;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--steel-deep);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding: 0.5rem 0 1rem;
  }
  .nav-links.open { display: flex; }
  .nav-links li { padding: 0 1.25rem; }
  .nav-links a { display: block; padding: 0.75rem 0; border-bottom: 1px solid rgba(255,255,255,0.07); }
  .nav-links .nav-cta { margin-top: 0.75rem; text-align: center; }
}

/* --- Hero ---------------------------------------------------------------- */

.hero {
  position: relative;
  min-height: 82vh;
  display: flex;
  align-items: center;
  color: #fff;
  background:
    linear-gradient(rgba(18, 20, 25, 0.55), rgba(18, 20, 25, 0.72)),
    url("assets/img/hero.jpg") center 35% / cover no-repeat;
}

.hero-inner {
  padding: 6rem 0;
  max-width: 44rem;
}

.hero h1 {
  font-size: clamp(2.9rem, 7vw, 5rem);
  text-transform: uppercase;
  margin-bottom: 1.25rem;
}

.hero h1 .accent { color: #e8925f; }

.hero p {
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  color: rgba(255, 255, 255, 0.92);
  max-width: 36rem;
  margin-bottom: 2rem;
}

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

.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-top: 3rem;
  font-family: var(--font-display);
  font-size: 1rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.85);
}
.hero-badges span::before {
  content: "";
  display: inline-block;
  width: 7px;
  height: 7px;
  background: var(--rust);
  margin-right: 0.6rem;
  vertical-align: 2px;
}

/* Page hero (interior pages) */
.page-hero {
  background:
    linear-gradient(rgba(18, 20, 25, 0.6), rgba(18, 20, 25, 0.75)),
    url("assets/img/stairhero.jpg") center 45% / cover no-repeat;
  color: #fff;
  padding: 5.5rem 0 4rem;
}
.page-hero h1 {
  font-size: clamp(2.4rem, 5.5vw, 3.6rem);
  text-transform: uppercase;
}
.page-hero p {
  margin-top: 0.75rem;
  max-width: 40rem;
  color: rgba(255, 255, 255, 0.9);
}

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

.section { padding: 5.5rem 0; }
.section-tight { padding: 4rem 0; }
.section-dark {
  background: var(--steel-deep);
  color: #fff;
}
.section-dark .section-intro { color: rgba(255, 255, 255, 0.75); }

/* --- Services grid --------------------------------------------------------- */

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.5rem;
}

.card {
  background: var(--paper-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
}

.card img {
  aspect-ratio: 4 / 3;
  object-fit: cover;
  width: 100%;
}

.card-body { padding: 1.4rem 1.4rem 1.6rem; flex: 1; }

.card h3 {
  font-size: 1.5rem;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}

.card p { color: var(--ink-soft); font-size: 0.98rem; }

/* --- Feature / why-us list ----------------------------------------------- */

.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 2.25rem 2rem;
}

.feature h3 {
  font-size: 1.35rem;
  text-transform: uppercase;
  margin-bottom: 0.4rem;
}
.feature p { font-size: 0.97rem; color: var(--ink-soft); }
.section-dark .feature p { color: rgba(255, 255, 255, 0.72); }

.feature .num {
  font-family: var(--font-display);
  font-size: 2.6rem;
  font-weight: 700;
  color: var(--rust);
  line-height: 1;
  display: block;
  margin-bottom: 0.6rem;
}

/* --- Split (about) --------------------------------------------------------- */

.split {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 3.5rem;
  align-items: center;
}

.split-media img {
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  aspect-ratio: 4 / 5;
  object-fit: cover;
  width: 100%;
}

.split-body p + p { margin-top: 1rem; }
.split-body p { color: var(--ink-soft); }
.section-dark .split-body p { color: rgba(255, 255, 255, 0.82); }
.section-dark .kicker { color: #e8925f; }

@media (max-width: 820px) {
  .split { grid-template-columns: 1fr; gap: 2.25rem; }
  .split-media img { aspect-ratio: 16 / 10; }
}

/* --- Gallery -------------------------------------------------------------- */

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-bottom: 2.25rem;
}

.filter-btn {
  font-family: var(--font-display);
  font-size: 1.02rem;
  font-weight: 600;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  padding: 0.45rem 1.2rem;
  border-radius: 999px;
  border: 1.5px solid var(--line);
  background: var(--paper-raised);
  color: var(--ink-soft);
  cursor: pointer;
  transition: all 0.15s ease;
}

.filter-btn:hover { border-color: var(--rust); color: var(--rust-deep); }

.filter-btn.active {
  background: var(--steel);
  border-color: var(--steel);
  color: #fff;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.1rem;
}

.gallery-item {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  cursor: zoom-in;
  border: 0;
  padding: 0;
  background: var(--steel);
  box-shadow: var(--shadow);
}

.gallery-item img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  transition: transform 0.35s ease, opacity 0.35s ease;
}

.gallery-item:hover img { transform: scale(1.045); opacity: 0.88; }

.gallery-item .tag {
  position: absolute;
  left: 0.75rem;
  bottom: 0.75rem;
  font-family: var(--font-display);
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #fff;
  background: rgba(18, 20, 25, 0.72);
  padding: 0.2rem 0.7rem;
  border-radius: 4px;
}

.gallery-item.hidden { display: none; }

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(12, 13, 16, 0.93);
  padding: 2.5rem 1rem;
}
.lightbox.open { display: flex; }
.lightbox img {
  max-width: min(1100px, 94vw);
  max-height: 88vh;
  object-fit: contain;
  border-radius: 6px;
}
.lightbox-close {
  position: absolute;
  top: 1rem;
  right: 1.25rem;
  background: none;
  border: 0;
  color: #fff;
  font-size: 2.4rem;
  line-height: 1;
  cursor: pointer;
  opacity: 0.8;
}
.lightbox-close:hover { opacity: 1; }

/* --- CTA band --------------------------------------------------------------- */

.cta-band {
  background:
    linear-gradient(rgba(143, 63, 28, 0.88), rgba(143, 63, 28, 0.88)),
    url("assets/img/stairhero.jpg") center / cover no-repeat;
  color: #fff;
  text-align: center;
  padding: 4.5rem 1.25rem;
}

.cta-band h2 {
  font-size: clamp(2rem, 4.5vw, 2.9rem);
  text-transform: uppercase;
  margin-bottom: 0.75rem;
}

.cta-band p {
  max-width: 38rem;
  margin: 0 auto 2rem;
  color: rgba(255, 255, 255, 0.92);
}

.cta-band .btn-primary { background: #fff; color: var(--rust-deep); }
.cta-band .btn-primary:hover { background: var(--rust-tint); }

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

.contact-layout {
  display: grid;
  grid-template-columns: 1fr 1.35fr;
  gap: 3.5rem;
  align-items: start;
}

@media (max-width: 820px) {
  .contact-layout { grid-template-columns: 1fr; }
}

.contact-info h2 {
  font-size: 1.9rem;
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.contact-list { list-style: none; margin-top: 1.5rem; }

.contact-list li {
  padding: 1rem 0;
  border-top: 1px solid var(--line);
}
.contact-list li:last-child { border-bottom: 1px solid var(--line); }

.contact-list .label {
  font-family: var(--font-display);
  font-size: 0.92rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-faint);
  display: block;
}

.contact-list a {
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--ink);
  text-decoration: none;
}
.contact-list a:hover { color: var(--rust-deep); }

/* Form */
.form-card {
  background: var(--paper-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 2rem;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.1rem;
}

.form-field.full { grid-column: 1 / -1; }

@media (max-width: 560px) {
  .form-grid { grid-template-columns: 1fr; }
  .form-field.full { grid-column: auto; }
}

.form-field label {
  display: block;
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 0.35rem;
}

.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--ink);
  background: var(--paper);
  border: 1.5px solid var(--line);
  border-radius: 6px;
  padding: 0.7rem 0.85rem;
  transition: border-color 0.15s ease;
}

.form-field textarea { resize: vertical; min-height: 130px; }

.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  outline: none;
  border-color: var(--rust);
}

.form-note {
  font-size: 0.88rem;
  color: var(--ink-faint);
  margin-top: 1rem;
}

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

.site-footer {
  background: var(--steel-deep);
  color: rgba(255, 255, 255, 0.75);
  padding: 3.5rem 0 2.5rem;
  font-size: 0.95rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 2.5rem;
  margin-bottom: 2.5rem;
}

@media (max-width: 720px) {
  .footer-grid { grid-template-columns: 1fr; }
}

.site-footer h3 {
  font-size: 1.2rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #fff;
  margin-bottom: 0.8rem;
}

.site-footer a { color: rgba(255, 255, 255, 0.85); text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }

.site-footer ul { list-style: none; }
.site-footer li { margin-bottom: 0.45rem; }

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  padding-top: 1.5rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.5rem;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.5);
}

/* --- Testimonials ------------------------------------------------------------ */

.testimonial-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}

@media (max-width: 720px) {
  .testimonial-grid { grid-template-columns: 1fr; }
}

.testimonial {
  background: var(--paper-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1.9rem 1.7rem 1.6rem;
  display: flex;
  flex-direction: column;
}

.testimonial::before {
  content: "\201C";
  font-family: var(--font-display);
  font-size: 3.4rem;
  font-weight: 700;
  line-height: 1;
  color: var(--rust);
  display: block;
  margin-bottom: 0.4rem;
}

.testimonial blockquote {
  margin: 0;
  color: var(--ink-soft);
  flex: 1;
}

.testimonial cite {
  display: block;
  margin-top: 1.25rem;
  font-style: normal;
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink);
}

.testimonial cite span {
  display: block;
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 400;
  letter-spacing: 0;
  text-transform: none;
  color: var(--ink-faint);
  margin-top: 0.15rem;
}

/* --- FAQ -------------------------------------------------------------------- */

.faq-list { max-width: 50rem; }

.faq-list details {
  background: var(--paper-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  margin-bottom: 0.75rem;
  overflow: hidden;
}

.faq-list summary {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  padding: 1rem 1.25rem;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.faq-list summary::-webkit-details-marker { display: none; }

.faq-list summary::after {
  content: "+";
  font-size: 1.5rem;
  font-weight: 500;
  color: var(--rust);
  flex-shrink: 0;
  transition: transform 0.2s ease;
}

.faq-list details[open] summary::after { transform: rotate(45deg); }

.faq-list details p {
  padding: 0 1.25rem 1.15rem;
  color: var(--ink-soft);
  font-size: 0.98rem;
}

/* --- Map -------------------------------------------------------------------- */

.map-embed {
  margin-top: 2.5rem;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.map-embed iframe {
  display: block;
  width: 100%;
  height: 340px;
  border: 0;
}

/* --- Mobile call bar --------------------------------------------------------- */

.mobile-cta-bar {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 60;
  background: var(--steel-deep);
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  padding: 0.6rem 0.75rem calc(0.6rem + env(safe-area-inset-bottom));
  gap: 0.6rem;
}

.mobile-cta-bar a {
  flex: 1;
  text-align: center;
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 0.65rem 0.5rem;
  border-radius: 6px;
}

.mobile-cta-bar .bar-call {
  background: transparent;
  color: #fff;
  border: 1.5px solid rgba(255, 255, 255, 0.5);
}

.mobile-cta-bar .bar-estimate {
  background: var(--rust);
  color: #fff;
}

@media (max-width: 720px) {
  .mobile-cta-bar { display: flex; }
  body { padding-bottom: 64px; }
}

/* --- Utility -------------------------------------------------------------- */

.center { text-align: center; }
.mt-2 { margin-top: 2rem; }

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--rust);
  color: #fff;
  padding: 0.6rem 1rem;
  z-index: 200;
}
.skip-link:focus { left: 0; }
