/* Special Fire Systems, Inc.
   Brand colours sampled from the logo: #C02534 red, #314C61 slate. */

:root {
  --red: #e11d33;
  --red-soft: #ff4d5e;
  --ink: #0b1017;
  --ink-2: #111823;
  --slate: #314c61;
  --body: #5b6b7a;
  --muted: #8c9bab;
  --line: #e6ebf0;
  --bg: #ffffff;
  --bg-soft: #f7f9fb;
  --r-lg: 22px;
  --r-md: 16px;
  --wrap: 1200px;
  --ease: cubic-bezier(.22,.61,.36,1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI Variable Text",
               "Segoe UI", Inter, Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--body);
  background: var(--bg);
  line-height: 1.62;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

h1, h2, h3, h4 { color: var(--ink); margin: 0 0 .55em; line-height: 1.06; font-weight: 760; }
h1 { font-size: clamp(2.6rem, 6.6vw, 5.2rem); letter-spacing: -.045em; }
h2 { font-size: clamp(1.9rem, 4vw, 3.1rem); letter-spacing: -.035em; }
h3 { font-size: 1.16rem; letter-spacing: -.015em; font-weight: 700; }
p { margin: 0 0 1.15em; }
a { color: var(--red); text-decoration: none; }
img { max-width: 100%; display: block; }

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

.eyebrow {
  display: inline-flex; align-items: center; gap: .55rem;
  font-size: .74rem; font-weight: 700; letter-spacing: .16em;
  text-transform: uppercase; color: var(--red); margin-bottom: 1.15rem;
}
.eyebrow::before {
  content: ""; width: 26px; height: 2px; background: var(--red); border-radius: 2px;
}

.lede { font-size: clamp(1.04rem, 1.7vw, 1.22rem); color: var(--body); }

/* ---------------------------------------------------------------- buttons */
.btn {
  display: inline-flex; align-items: center; gap: .5rem;
  background: var(--red); color: #fff;
  padding: .82rem 1.5rem; border-radius: 100px;
  font-weight: 650; font-size: .95rem; letter-spacing: -.01em;
  transition: transform .25s var(--ease), box-shadow .25s var(--ease), background .2s;
  box-shadow: 0 6px 20px -6px rgba(225,29,51,.55);
}
.btn:hover { background: #c8172b; transform: translateY(-2px); box-shadow: 0 12px 28px -8px rgba(225,29,51,.6); }
.btn-ghost {
  background: transparent; color: var(--ink);
  border: 1.5px solid var(--line); box-shadow: none;
}
.btn-ghost:hover { background: var(--bg-soft); border-color: #cfd9e2; }

/* ----------------------------------------------------------------- header */
.site-head {
  position: sticky; top: 0; z-index: 60;
  background: rgba(255,255,255,.72);
  backdrop-filter: saturate(180%) blur(16px);
  -webkit-backdrop-filter: saturate(180%) blur(16px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s, background .3s;
}
.site-head.stuck { border-bottom-color: var(--line); background: rgba(255,255,255,.9); }
.head-inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 82px; }
.brand img { height: 44px; }
.nav { display: flex; align-items: center; gap: 2.1rem; }
.nav a { color: var(--slate); font-weight: 560; font-size: .95rem; letter-spacing: -.01em; position: relative; }
.nav a:not(.btn)::after {
  content: ""; position: absolute; left: 0; bottom: -5px; height: 2px; width: 0;
  background: var(--red); border-radius: 2px; transition: width .28s var(--ease);
}
.nav a:not(.btn):hover::after { width: 100%; }
.nav a:not(.btn):hover { color: var(--ink); }
/* .nav a outranks .btn on specificity, so state this explicitly or the phone
   button renders with dark link text on the red fill. */
.nav a.btn, .nav a.btn:hover { color: #fff; }
.nav-toggle { display: none; background: none; border: 0; cursor: pointer; color: var(--ink); padding: .4rem; }

/* ------------------------------------------------------------------- hero */
.hero { position: relative; background: var(--ink); color: #fff; overflow: hidden; isolation: isolate; }
.hero-media { position: absolute; inset: 0; z-index: -2; }
.hero-media img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.06); }
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(120% 90% at 8% 15%, rgba(225,29,51,.30) 0%, transparent 58%),
    linear-gradient(100deg, rgba(9,13,19,.97) 0%, rgba(9,13,19,.88) 42%, rgba(9,13,19,.45) 100%);
}
.hero .wrap { position: relative; padding-top: clamp(5rem, 12vh, 9rem); padding-bottom: clamp(5rem, 12vh, 9rem); }
.hero-copy { max-width: 22ch; }
.hero h1 { color: #fff; max-width: 15ch; }
.hero h1 em { font-style: normal; color: var(--red-soft); }
.hero .lede { color: #b9c6d3; max-width: 46ch; margin-bottom: 2.4rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .85rem; }
.hero-actions .btn-ghost { color: #fff; border-color: rgba(255,255,255,.24); }
.hero-actions .btn-ghost:hover { background: rgba(255,255,255,.1); border-color: rgba(255,255,255,.4); }
.hero-copy { max-width: none; }

/* hero footer strip */
.hero-strip {
  position: relative; border-top: 1px solid rgba(255,255,255,.12);
  display: grid; grid-template-columns: repeat(4, 1fr);
}
.hero-strip div { padding: 1.6rem .4rem; }
.hero-strip b { display: block; font-size: clamp(1.5rem,2.6vw,2.1rem); color: #fff; font-weight: 780; letter-spacing: -.03em; line-height: 1; }
.hero-strip span { font-size: .82rem; color: #91a1b1; }

/* --------------------------------------------------------------- sections */
section { padding: clamp(4.5rem, 9vw, 7.5rem) 0; }
.section-soft { background: var(--bg-soft); }
.section-dark { background: var(--ink); color: #a9b8c6; }
.section-dark h2, .section-dark h3 { color: #fff; }
.section-head { max-width: 640px; margin-bottom: 3.4rem; }

/* bento */
.bento { display: grid; grid-template-columns: repeat(6, 1fr); gap: 1.1rem; }
.tile {
  background: #fff; border: 1px solid var(--line); border-radius: var(--r-lg);
  padding: 2rem; position: relative; overflow: hidden;
  transition: transform .35s var(--ease), box-shadow .35s var(--ease), border-color .3s;
}
.tile:hover { transform: translateY(-4px); box-shadow: 0 22px 50px -22px rgba(11,16,23,.28); border-color: #d5dee6; }
.tile-a { grid-column: span 4; }
.tile-b { grid-column: span 2; }
.tile-c { grid-column: span 2; }
.tile-d { grid-column: span 4; }
.tile .idx {
  font-size: .74rem; font-weight: 800; letter-spacing: .12em; color: var(--red);
  display: block; margin-bottom: 1.4rem;
}
.tile p:last-child { margin-bottom: 0; }
.tile-photo { padding: 0; min-height: 240px; border: 0; }
.tile-photo img { width: 100%; height: 100%; object-fit: cover; border-radius: var(--r-lg); }

/* split with sticky media */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }
.split-media img { border-radius: var(--r-lg); box-shadow: 0 30px 60px -30px rgba(11,16,23,.45); }

/* marquee of certifications */
.ticker { overflow: hidden; border-block: 1px solid var(--line); background: #fff; padding: 1.5rem 0; }
.ticker-row { display: flex; gap: 3rem; width: max-content; animation: slide 42s linear infinite; }
.ticker span { font-size: 1.02rem; font-weight: 650; color: var(--muted); white-space: nowrap; letter-spacing: -.01em; }
@keyframes slide { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) { .ticker-row { animation: none; } }

/* team */
.people { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.1rem; }
.person {
  background: #fff; border: 1px solid var(--line); border-radius: var(--r-lg);
  padding: 1.9rem; transition: transform .35s var(--ease), box-shadow .35s var(--ease);
}
.person:hover { transform: translateY(-4px); box-shadow: 0 22px 50px -22px rgba(11,16,23,.24); }
.person .role { color: var(--red); font-weight: 700; font-size: .87rem; letter-spacing: -.005em; }
.person .yrs { font-size: .8rem; color: var(--muted); margin-bottom: 1rem; }
.person p { font-size: .94rem; }
.person ul { margin: 0; padding: 0; list-style: none; font-size: .82rem; color: var(--muted); border-top: 1px solid var(--line); padding-top: .9rem; }
.person li { margin-bottom: .25rem; }

/* chips */
.chips { display: flex; flex-wrap: wrap; gap: .5rem; }
.chip {
  border: 1px solid var(--line); border-radius: 100px; padding: .45rem 1rem;
  font-size: .82rem; font-weight: 600; color: var(--slate); background: #fff;
}
.chip-red { background: rgba(225,29,51,.06); border-color: rgba(225,29,51,.22); color: var(--red); }
.section-dark .chip { background: rgba(255,255,255,.05); border-color: rgba(255,255,255,.14); color: #c8d4df; }

/* offices */
.offices { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.1rem; }
.office { background: #fff; border: 1px solid var(--line); border-radius: var(--r-lg); padding: 2rem; }
.office .tag { font-size: .72rem; text-transform: uppercase; letter-spacing: .13em; font-weight: 800; color: var(--red); }
.office address { font-style: normal; margin: .8rem 0; }
.office .who { font-weight: 700; color: var(--ink); }

/* cta */
.cta { background: linear-gradient(135deg, #121a24 0%, #1b2836 60%, #2a1116 100%); color: #fff; border-radius: var(--r-lg); padding: clamp(2.4rem,5vw,4rem); }
.cta h2 { color: #fff; }
.cta p { color: #b5c3d0; }
.cta-inner { display: flex; align-items: center; justify-content: space-between; gap: 2rem; flex-wrap: wrap; }
.cta .tel { font-size: clamp(1.7rem,3.4vw,2.5rem); font-weight: 800; color: #fff; letter-spacing: -.035em; }
.cta .tel:hover { color: var(--red-soft); }

/* footer */
.site-foot { background: var(--ink); color: #8496a6; padding: 4rem 0 2rem; font-size: .92rem; }
.foot-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr; gap: 2.6rem; margin-bottom: 2.6rem; }
.site-foot img { height: 50px; margin-bottom: 1.1rem; }
.site-foot h4 { color: #fff; font-size: .78rem; text-transform: uppercase; letter-spacing: .13em; margin-bottom: 1rem; font-weight: 700; }
.site-foot a { color: #8496a6; }
.site-foot a:hover { color: #fff; }
.site-foot ul { list-style: none; margin: 0; padding: 0; }
.site-foot li { margin-bottom: .5rem; }
.foot-bottom { border-top: 1px solid rgba(255,255,255,.09); padding-top: 1.6rem; display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; font-size: .84rem; color: #6d7f8f; }

/* scroll reveal */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; transition: none; } }
/* Browsers that report no scripting support get the content unconditionally. */
@media (scripting: none) { .reveal { opacity: 1; transform: none; } }

/* ------------------------------------------------------------ responsive */
@media (max-width: 1000px) {
  .bento { grid-template-columns: repeat(2, 1fr); }
  .tile-a, .tile-b, .tile-c, .tile-d { grid-column: span 1; }
  .people { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 760px) {
  body { font-size: 16px; }
  .nav {
    display: none; position: absolute; top: 82px; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0; background: #fff;
    border-bottom: 1px solid var(--line); padding: .4rem 1.6rem 1.4rem;
  }
  .nav.open { display: flex; }
  .nav a { padding: .85rem 0; border-bottom: 1px solid var(--line); }
  .nav a.btn { justify-content: center; margin-top: .9rem; border-bottom: 0; }
  .nav-toggle { display: block; }
  .bento, .people, .offices, .split { grid-template-columns: 1fr; }
  .hero-strip { grid-template-columns: repeat(2, 1fr); }
  .foot-grid { grid-template-columns: 1fr; gap: 2rem; }
  .cta-inner { flex-direction: column; align-items: flex-start; }
}

/* ==========================================================================
   Motion. Everything here is decorative and is switched off wholesale by
   prefers-reduced-motion at the bottom of this block.
   ========================================================================== */

/* hero: slow ken-burns push on the photo */
@keyframes kenburns {
  from { transform: scale(1.06) translate3d(0,0,0); }
  to   { transform: scale(1.16) translate3d(-1.2%, -1.2%, 0); }
}
.hero-media img { animation: kenburns 26s ease-out forwards; }

/* hero: staggered entrance */
@keyframes riseIn {
  from { opacity: 0; transform: translateY(26px); }
  to   { opacity: 1; transform: none; }
}
.hero .eyebrow,
.hero h1,
.hero .lede,
.hero-actions,
.hero-strip > div {
  animation: riseIn .85s var(--ease) both;
}
.hero .eyebrow    { animation-delay: .05s; }
.hero h1          { animation-delay: .16s; }
.hero .lede       { animation-delay: .30s; }
.hero-actions     { animation-delay: .44s; }
.hero-strip > div:nth-child(1) { animation-delay: .58s; }
.hero-strip > div:nth-child(2) { animation-delay: .66s; }
.hero-strip > div:nth-child(3) { animation-delay: .74s; }
.hero-strip > div:nth-child(4) { animation-delay: .82s; }

/* the red word in the headline gets a wipe */
/* 3px, not 100% - animating the height to full paints a solid block right
   over the word instead of drawing an underline beneath it. */
@keyframes wipe { from { background-size: 0% 3px; } to { background-size: 100% 3px; } }
.hero h1 em {
  background-image: linear-gradient(var(--red-soft), var(--red-soft));
  background-repeat: no-repeat;
  background-position: 0 88%;
  background-size: 0% 3px;
  animation: wipe .7s var(--ease) 1.05s forwards;
}

/* call button: a soft outward pulse so the primary action reads first */
@keyframes ring {
  0%   { box-shadow: 0 6px 20px -6px rgba(225,29,51,.55), 0 0 0 0 rgba(225,29,51,.45); }
  70%  { box-shadow: 0 6px 20px -6px rgba(225,29,51,.55), 0 0 0 14px rgba(225,29,51,0); }
  100% { box-shadow: 0 6px 20px -6px rgba(225,29,51,.55), 0 0 0 0 rgba(225,29,51,0); }
}
.hero-actions .btn:not(.btn-ghost) { animation: riseIn .85s var(--ease) .44s both, ring 3.4s ease-out 1.8s infinite; }

/* stagger the scroll reveals within a group */
.reveal { transition-delay: var(--d, 0s); }

/* photo tiles zoom gently on hover */
.tile-photo img, .split-media img { transition: transform .8s var(--ease); will-change: transform; }
.tile-photo:hover img, .split-media:hover img { transform: scale(1.05); }
.split-media, .tile-photo { overflow: hidden; border-radius: var(--r-lg); }

/* cards lift a touch more decisively, and the index label slides */
.tile .idx { transition: transform .35s var(--ease); }
.tile:hover .idx { transform: translateX(4px); }

/* chips settle in on hover */
.chip { transition: transform .25s var(--ease), border-color .25s, background .25s; }
.chip:hover { transform: translateY(-2px); border-color: var(--red); color: var(--red); }
.section-dark .chip:hover { border-color: var(--red-soft); color: #fff; background: rgba(225,29,51,.16); }

/* counter digits should not reflow the layout while ticking */
.hero-strip b { font-variant-numeric: tabular-nums; }

@media (prefers-reduced-motion: reduce) {
  .hero-media img,
  .hero .eyebrow, .hero h1, .hero .lede, .hero-actions, .hero-strip > div,
  .hero h1 em, .hero-actions .btn:not(.btn-ghost) { animation: none !important; }
  .hero h1 em { background-size: 100% 3px; }
  .tile-photo img, .split-media img { transition: none; }
}
