/* =================================================================
   BITS & BOLTS CONSULTING — industrial workshop × code shop
   Palette: warm blueprint paper, ink black, bolt orange,
            bit blue, acid highlight.
   ================================================================= */

:root {
  --paper:      #f4f0e6;
  --paper-2:    #ece6d6;
  --ink:        #17140f;
  --ink-soft:   #423b30;
  --bolts:      #ff5a1f;   /* orange — the physical / mechanical */
  --bolts-deep: #e3430c;
  --bits:       #1f49ff;   /* blue — the digital / software      */
  --acid:       #ffd23f;   /* highlight yellow                    */
  --line:       #17140f;

  --font-display: "Bricolage Grotesque", "Hanken Grotesk", sans-serif;
  --font-body:    "Hanken Grotesk", system-ui, sans-serif;
  --font-mono:    "Space Mono", ui-monospace, monospace;

  --maxw: 1200px;
  --r: 4px;
  --shadow: 6px 6px 0 var(--ink);
  --shadow-sm: 3px 3px 0 var(--ink);
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  background: var(--paper);
  color: var(--ink);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* blueprint paper texture on body */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(23,20,15,.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(23,20,15,.04) 1px, transparent 1px);
  background-size: 28px 28px;
  pointer-events: none;
  z-index: 0;
}

/* film grain */
.grain {
  position: fixed;
  inset: -50%;
  z-index: 1;
  pointer-events: none;
  opacity: .35;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.5'/%3E%3C/svg%3E");
  mix-blend-mode: multiply;
}

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

::selection { background: var(--acid); color: var(--ink); }

/* shared container helpers */
section { position: relative; z-index: 2; }

/* =================  NAV  ================= */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem clamp(1.1rem, 4vw, 3rem);
  background: rgba(244,240,230,.82);
  backdrop-filter: blur(10px);
  border-bottom: 2px solid var(--ink);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: .55rem;
  text-decoration: none;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.4rem;
  letter-spacing: -.02em;
  color: var(--ink);
}
.brand-mark {
  display: inline-grid;
  place-items: center;
  width: 38px; height: 38px;
  background: var(--ink);
  border-radius: 9px;
  color: var(--bolts);
  flex: none;
}
.brand-mark svg { width: 26px; height: 26px; }
.bolt-core { fill: var(--acid); }
.bolt-spin { transition: transform .8s cubic-bezier(.5,1.6,.4,1); }
.brand:hover .bolt-spin { transform: rotate(180deg); }
.brand-text .amp { color: var(--bolts); margin: 0 .04em; }

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.6rem;
  font-weight: 600;
  font-size: .98rem;
}
.nav-links a { text-decoration: none; position: relative; }
.nav-links a:not(.nav-cta)::after {
  content: "";
  position: absolute;
  left: 0; bottom: -5px;
  width: 0; height: 2px;
  background: var(--bolts);
  transition: width .25s ease;
}
.nav-links a:not(.nav-cta):hover::after { width: 100%; }

.nav-cta {
  background: var(--ink);
  color: var(--paper);
  padding: .55rem 1.1rem;
  border-radius: var(--r);
  text-decoration: none;
  box-shadow: var(--shadow-sm);
  transition: transform .12s ease, box-shadow .12s ease, background .2s;
}
.nav-cta:hover { transform: translate(-2px,-2px); box-shadow: 5px 5px 0 var(--bolts); background: var(--bits); }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: 0;
  cursor: pointer;
  padding: 6px;
}
.nav-toggle span {
  width: 26px; height: 3px;
  background: var(--ink);
  border-radius: 2px;
  transition: .25s;
}

/* =================  HERO  ================= */
.hero {
  position: relative;
  padding: clamp(2.5rem, 7vw, 6rem) clamp(1.1rem, 4vw, 3rem) 0;
  overflow: hidden;
}
.hero-grid {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(120% 90% at 80% -10%, rgba(31,73,255,.10), transparent 55%),
    radial-gradient(90% 80% at 0% 110%, rgba(255,90,31,.12), transparent 55%);
  z-index: 0;
}

/* ticker marquee */
.ticker {
  position: relative;
  z-index: 2;
  overflow: hidden;
  border-block: 2px solid var(--ink);
  background: var(--acid);
  margin-bottom: clamp(2rem, 5vw, 3.5rem);
  transform: rotate(-1deg) scale(1.04);
}
.ticker-track {
  display: inline-flex;
  align-items: center;
  gap: 1.4rem;
  white-space: nowrap;
  padding: .5rem 0;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.05rem;
  letter-spacing: .02em;
  text-transform: uppercase;
  animation: marquee 26s linear infinite;
}
.ticker-track i { color: var(--bolts); font-style: normal; }
@keyframes marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

.hero-inner {
  position: relative;
  z-index: 3;
  max-width: var(--maxw);
  margin: 0 auto;
  padding-bottom: clamp(3rem, 7vw, 6rem);
}

.eyebrow {
  font-family: var(--font-mono);
  font-size: .85rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--bolts-deep);
  margin-bottom: 1.2rem;
}

.hero-title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2.7rem, 8.5vw, 6.4rem);
  line-height: .96;
  letter-spacing: -.035em;
  margin-bottom: 1.6rem;
}
.hero-title .line { display: block; }
.hero-title em { font-style: italic; color: var(--bolts); }
.hl-bits {
  color: var(--bits);
  position: relative;
}
.hl-bits::after {
  content: "";
  position: absolute; left: -2%; right: -2%; bottom: .04em;
  height: .12em; background: var(--bits); opacity: .25;
}
.hl-bolts { color: var(--bolts); }

.hero-sub {
  max-width: 46ch;
  font-size: clamp(1.05rem, 1.6vw, 1.3rem);
  color: var(--ink-soft);
  margin-bottom: 2rem;
  font-weight: 500;
}

.hero-actions { display: flex; flex-wrap: wrap; gap: 1rem; margin-bottom: 2.6rem; }

.btn {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.02rem;
  padding: .85rem 1.5rem;
  border-radius: var(--r);
  text-decoration: none;
  border: 2px solid var(--ink);
  cursor: pointer;
  transition: transform .12s ease, box-shadow .12s ease, background .2s, color .2s;
}
.btn-primary {
  background: var(--bolts);
  color: var(--ink);
  box-shadow: var(--shadow);
}
.btn-primary:hover { transform: translate(-3px,-3px); box-shadow: 9px 9px 0 var(--ink); background: var(--acid); }
.btn-ghost { background: transparent; box-shadow: var(--shadow-sm); }
.btn-ghost:hover { transform: translate(-3px,-3px); box-shadow: 6px 6px 0 var(--bits); background: var(--bits); color: var(--paper); }

.hero-badges { display: flex; flex-wrap: wrap; gap: .7rem; }
.badge {
  font-family: var(--font-mono);
  font-size: .82rem;
  font-weight: 700;
  padding: .35rem .75rem;
  border: 2px solid var(--ink);
  border-radius: 100px;
  background: var(--paper);
}
.badge b { color: var(--bolts); margin-right: .35rem; }

/* =================  STRIP  ================= */
.strip {
  background: var(--ink);
  color: var(--paper);
  border-block: 2px solid var(--ink);
  padding: clamp(3rem, 8vw, 6rem) clamp(1.1rem, 4vw, 3rem);
  margin-top: clamp(1rem, 3vw, 2rem);
}
.strip-inner { max-width: var(--maxw); margin: 0 auto; }
.strip-lead {
  font-family: var(--font-mono);
  font-size: clamp(1rem, 2vw, 1.4rem);
  color: var(--acid);
  margin-bottom: .6rem;
  max-width: 40ch;
}
.strip-big {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2.4rem, 7vw, 5.5rem);
  line-height: .98;
  letter-spacing: -.03em;
}
.strip-big .u { color: var(--bolts); text-decoration: underline wavy var(--acid) .08em; text-underline-offset: .14em; }

/* =================  SECTION HEADS  ================= */
.section-head {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: clamp(3.5rem, 8vw, 6.5rem) clamp(1.1rem, 4vw, 3rem) clamp(1.5rem, 3vw, 2.5rem);
}
.section-num {
  display: inline-block;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: .9rem;
  color: var(--bolts);
  border: 2px solid var(--ink);
  border-radius: 100px;
  padding: .15rem .7rem;
  margin-bottom: 1.1rem;
}
.section-title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2rem, 5.5vw, 3.6rem);
  line-height: 1.02;
  letter-spacing: -.03em;
  margin-bottom: .8rem;
}
.section-desc {
  max-width: 52ch;
  color: var(--ink-soft);
  font-size: clamp(1rem, 1.4vw, 1.15rem);
  font-weight: 500;
}

/* =================  WORK CARDS  ================= */
.cards {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 clamp(1.1rem, 4vw, 3rem) clamp(2rem, 5vw, 4rem);
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.2rem;
}
.card {
  background: var(--paper);
  border: 2px solid var(--ink);
  border-radius: var(--r);
  padding: 1.6rem 1.5rem 1.7rem;
  box-shadow: var(--shadow-sm);
  transition: transform .15s ease, box-shadow .15s ease;
}
.card:hover { transform: translate(-4px,-4px); box-shadow: 8px 8px 0 var(--bolts); }
.card-icon {
  display: inline-grid;
  place-items: center;
  width: 48px; height: 48px;
  font-family: var(--font-mono);
  font-size: 1.3rem;
  font-weight: 700;
  background: var(--ink);
  color: var(--acid);
  border-radius: 10px;
  margin-bottom: 1rem;
}
.card:nth-child(3n+1) .card-icon { color: var(--bolts); }
.card:nth-child(3n+2) .card-icon { color: var(--bits); }
.card h3 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.3rem;
  letter-spacing: -.02em;
  margin-bottom: .5rem;
}
.card p { color: var(--ink-soft); font-size: .98rem; }
.card em { font-style: italic; color: var(--bolts-deep); }

/* =================  PROCESS  ================= */
.steps {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 clamp(1.1rem, 4vw, 3rem) clamp(2rem, 5vw, 4rem);
  list-style: none;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  border: 2px solid var(--ink);
  border-radius: var(--r);
  overflow: hidden;
  background: var(--paper);
}
/* override container padding for the bordered box */
.process .steps { padding: 0; margin-inline: auto; max-width: var(--maxw); width: calc(100% - clamp(2.2rem, 8vw, 6rem)); }
.step {
  padding: 1.8rem 1.4rem;
  border-right: 2px solid var(--ink);
  position: relative;
  transition: background .2s;
}
.step:last-child { border-right: 0; }
.step:hover { background: var(--acid); }
.step-num {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 2.4rem;
  color: var(--bolts);
  line-height: 1;
  display: block;
  margin-bottom: .8rem;
}
.step:hover .step-num { color: var(--ink); }
.step h3 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.35rem;
  margin-bottom: .4rem;
}
.step p { color: var(--ink-soft); font-size: .95rem; }
.step:hover p { color: var(--ink); }

/* =================  ABOUT  ================= */
.about-grid {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: clamp(3.5rem, 8vw, 6.5rem) clamp(1.1rem, 4vw, 3rem);
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: start;
}
.about-copy p { margin-bottom: 1.1rem; color: var(--ink-soft); font-size: 1.08rem; }
.about-copy strong { color: var(--ink); }
.about-copy .section-title { margin-top: 1rem; }

.stats { display: flex; flex-wrap: wrap; gap: 1.6rem; margin-top: 1.8rem; }
.stat { line-height: 1; }
.stat b {
  display: block;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 2.6rem;
  color: var(--bolts);
}
.stat span { font-family: var(--font-mono); font-size: .78rem; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-soft); }

.about-card {
  background: var(--ink);
  color: var(--paper);
  border-radius: var(--r);
  padding: 1.8rem 1.7rem;
  box-shadow: var(--shadow);
  position: sticky;
  top: 100px;
}
.about-card h3 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.5rem;
  color: var(--acid);
  margin-bottom: .8rem;
}
.about-card p { color: #d9d2c4; margin-bottom: 1.2rem; }
.about-card em { color: var(--bolts); font-style: italic; }
.check { list-style: none; display: grid; gap: .6rem; }
.check li {
  position: relative;
  padding-left: 1.8rem;
  font-weight: 600;
  font-size: .96rem;
}
.check li::before {
  content: "✔";
  position: absolute; left: 0; top: 0;
  color: var(--bolts);
  font-weight: 700;
}

/* =================  CONTACT  ================= */
.contact {
  background: var(--bits);
  color: var(--paper);
  border-top: 2px solid var(--ink);
  margin-top: clamp(1rem, 3vw, 2rem);
}
.contact-grid {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: clamp(3.5rem, 8vw, 6rem) clamp(1.1rem, 4vw, 3rem);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: start;
}
.contact .section-num { color: var(--acid); border-color: var(--paper); }
.contact .section-title { color: var(--paper); }
.contact-copy p { color: #e4e9ff; font-size: 1.08rem; margin-top: .8rem; }
.contact-direct a { color: var(--acid); text-decoration: underline; text-underline-offset: 3px; font-weight: 700; }

/* form */
.contact-form {
  background: var(--paper);
  color: var(--ink);
  border: 2px solid var(--ink);
  border-radius: var(--r);
  padding: 1.8rem 1.7rem;
  box-shadow: var(--shadow);
}
.field { margin-bottom: 1rem; display: flex; flex-direction: column; }
.field label {
  font-family: var(--font-mono);
  font-size: .8rem;
  text-transform: uppercase;
  letter-spacing: .06em;
  font-weight: 700;
  margin-bottom: .4rem;
}
.field .req { color: var(--bolts); }
.field input,
.field textarea {
  font-family: var(--font-body);
  font-size: 1rem;
  padding: .7rem .8rem;
  border: 2px solid var(--ink);
  border-radius: var(--r);
  background: var(--paper-2);
  color: var(--ink);
  transition: border-color .2s, box-shadow .2s;
  resize: vertical;
}
.field input:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--bolts);
  box-shadow: 3px 3px 0 var(--bolts);
}
.field input::placeholder,
.field textarea::placeholder { color: #9a9384; }
.field-submit { margin-top: 1.2rem; }
.field-submit .btn { width: 100%; justify-content: center; }
.form-fineprint {
  font-family: var(--font-mono);
  font-size: .76rem;
  color: var(--ink-soft);
  margin-top: .9rem;
  text-align: center;
}
.mc-responses .response { padding: .6rem .2rem; font-weight: 600; font-size: .9rem; }
#mce-error-response { color: var(--bolts-deep); }
#mce-success-response { color: #157a3c; }

/* =================  FOOTER  ================= */
.footer {
  background: var(--ink);
  color: var(--paper);
  padding: clamp(2.5rem, 6vw, 4rem) clamp(1.1rem, 4vw, 3rem) 2rem;
  position: relative;
  z-index: 2;
}
.footer-top {
  max-width: var(--maxw);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.2rem;
  padding-bottom: 1.8rem;
  border-bottom: 1px solid #3a342a;
}
.brand-foot { color: var(--paper); font-size: 1.5rem; }
.brand-foot .brand-mark { background: var(--paper); color: var(--bolts); }
.footer-tag { font-family: var(--font-mono); font-size: .9rem; color: var(--acid); }
.footer-links { display: flex; flex-wrap: wrap; gap: 1.3rem; font-weight: 600; }
.footer-links a { text-decoration: none; color: #d9d2c4; }
.footer-links a:hover { color: var(--bolts); }

.footer-bottom {
  max-width: var(--maxw);
  margin: 1.6rem auto 0;
  display: grid;
  gap: 1rem;
}
.footer-bottom p { color: #9b9488; }
.footer-bottom > p:first-child { font-weight: 600; color: #cfc8ba; font-size: .92rem; }
.disclaimer {
  font-size: .8rem;
  line-height: 1.6;
  color: #8a8475;
  max-width: 78ch;
  font-family: var(--font-mono);
}

/* =================  REVEAL ANIMATION  ================= */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .7s cubic-bezier(.2,.7,.2,1), transform .7s cubic-bezier(.2,.7,.2,1);
}
.reveal.in { opacity: 1; transform: none; }

/* =================  RESPONSIVE  ================= */
@media (max-width: 920px) {
  .cards { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .step:nth-child(2) { border-right: 0; }
  .step:nth-child(1), .step:nth-child(2) { border-bottom: 2px solid var(--ink); }
  .about-grid { grid-template-columns: 1fr; }
  .about-card { position: static; }
  .contact-grid { grid-template-columns: 1fr; }
}

@media (max-width: 680px) {
  .nav-links {
    position: fixed;
    inset: 64px 0 auto 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--paper);
    border-bottom: 2px solid var(--ink);
    padding: .5rem 1.2rem 1.2rem;
    transform: translateY(-130%);
    transition: transform .3s ease;
    box-shadow: var(--shadow);
  }
  .nav-links.open { transform: translateY(0); }
  .nav-links a { padding: .9rem 0; border-bottom: 1px solid var(--paper-2); }
  .nav-links a:not(.nav-cta)::after { display: none; }
  .nav-cta { text-align: center; margin-top: .6rem; }
  .nav-toggle { display: flex; }
  .nav-toggle.open span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
  .nav-toggle.open span:nth-child(2) { opacity: 0; }
  .nav-toggle.open span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }
  .cards { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
  .step { border-right: 0 !important; border-bottom: 2px solid var(--ink); }
  .step:last-child { border-bottom: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .ticker-track { animation: none; }
  .bolt-spin { transition: none; }
  html { scroll-behavior: auto; }
}
