/* =========================================================
   Red River Mechanical — Design System
   Palette drawn from brand logo: ice blue, flame orange,
   deep navy, and silver/steel neutrals.
   ========================================================= */

:root {
  --blue-600: #1568e0;
  --blue-500: #2b7ff0;
  --blue-100: #e3eefc;
  --orange-600: #e07a12;
  --orange-500: #f5921e;
  --orange-100: #fdeeda;
  --navy-900: #0d1b2e;
  --navy-800: #13253f;
  --navy-700: #1c3355;
  --ink: #1a2433;
  --slate: #55647a;
  --line: #e4e9f1;
  --bg: #ffffff;
  --bg-tint: #f4f7fb;
  --radius: 14px;
  --shadow-sm: 0 1px 3px rgba(13, 27, 46, 0.08);
  --shadow-md: 0 8px 28px rgba(13, 27, 46, 0.10);
  --shadow-lg: 0 18px 48px rgba(13, 27, 46, 0.16);
  --font-head: "Barlow Condensed", "Arial Narrow", sans-serif;
  --font-body: "Inter", -apple-system, "Segoe UI", sans-serif;
  --container: 1180px;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

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

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

h1, h2, h3, h4 {
  font-family: var(--font-head);
  line-height: 1.12;
  color: var(--navy-900);
  text-transform: uppercase;
  letter-spacing: 0.015em;
}

h1 { font-size: clamp(2.4rem, 5vw, 3.9rem); font-weight: 700; }
h2 { font-size: clamp(1.9rem, 3.4vw, 2.7rem); font-weight: 700; }
h3 { font-size: 1.45rem; font-weight: 600; }
h4 { font-size: 1.2rem; font-weight: 600; }

p { color: var(--slate); }

a { color: var(--blue-600); text-decoration: none; }

svg { width: 100%; height: 100%; }

.accent { color: var(--orange-500); }

.eyebrow {
  display: inline-block;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 1rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--blue-600);
  margin-bottom: 10px;
}
.eyebrow--light { color: #7db4ff; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 1.05rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 12px 24px;
  border-radius: 8px;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease, color 0.15s ease;
  white-space: nowrap;
}
.btn svg { width: 18px; height: 18px; flex: none; }
.btn--lg { padding: 15px 30px; font-size: 1.15rem; }
.btn--block { width: 100%; justify-content: center; }

.btn--primary {
  background: linear-gradient(135deg, var(--orange-500), var(--orange-600));
  color: #fff;
  box-shadow: 0 6px 18px rgba(224, 122, 18, 0.35);
}
.btn--primary:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(224, 122, 18, 0.45); }

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

.btn--outline {
  background: transparent;
  color: var(--blue-600);
  border-color: var(--blue-500);
  font-size: 0.95rem;
  padding: 10px 20px;
}
.btn--outline:hover { background: var(--blue-600); color: #fff; }

.btn--white {
  background: #fff;
  color: var(--navy-900);
  box-shadow: var(--shadow-md);
}
.btn--white:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }

/* ---------- Top bar ---------- */
.topbar {
  background: var(--navy-900);
  color: #b9c6d9;
  font-size: 0.82rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}
.topbar__inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding-top: 8px;
  padding-bottom: 8px;
  flex-wrap: wrap;
}
.topbar__group { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; }
.topbar__item { display: flex; align-items: center; gap: 7px; }
.topbar__item svg { width: 14px; height: 14px; color: var(--orange-500); flex: none; }
.topbar__phone {
  display: flex;
  align-items: center;
  gap: 7px;
  color: #fff;
  font-weight: 600;
  letter-spacing: 0.02em;
}
.topbar__phone svg { width: 14px; height: 14px; color: var(--orange-500); }
.topbar__phone:hover { color: var(--orange-500); }

/* ---------- Nav ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  height: 78px;
}
.nav__brand { display: flex; align-items: center; }
.nav__brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.nav__brand-name {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.5rem;
  text-transform: uppercase;
  color: var(--navy-900);
  letter-spacing: 0.02em;
}
.nav__brand-name em { font-style: normal; color: var(--orange-500); }
.nav__brand-tag {
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--slate);
}
.nav__links { display: flex; gap: 30px; }
.nav__links a {
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 1.02rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--navy-800);
  position: relative;
  padding: 4px 0;
}
.nav__links a::after {
  content: "";
  position: absolute;
  left: 0; right: 100%; bottom: 0;
  height: 2px;
  background: var(--orange-500);
  transition: right 0.2s ease;
}
.nav__links a:hover::after { right: 0; }
.nav__actions { display: flex; align-items: center; gap: 14px; }

.nav__toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 42px;
  height: 42px;
  background: none;
  border: 1px solid var(--line);
  border-radius: 8px;
  cursor: pointer;
  padding: 10px;
}
.nav__toggle span { display: block; height: 2px; background: var(--navy-900); border-radius: 2px; transition: 0.2s; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  background:
    radial-gradient(1100px 500px at 85% -10%, rgba(43, 127, 240, 0.22), transparent 60%),
    radial-gradient(900px 480px at 10% 110%, rgba(245, 146, 30, 0.16), transparent 60%),
    linear-gradient(180deg, var(--navy-900) 0%, var(--navy-800) 100%);
  color: #fff;
  overflow: hidden;
}
.hero__glow { position: absolute; border-radius: 50%; filter: blur(90px); opacity: 0.35; pointer-events: none; }
.hero__glow--blue { width: 480px; height: 480px; background: var(--blue-500); top: -180px; right: -120px; }
.hero__glow--orange { width: 420px; height: 420px; background: var(--orange-500); bottom: -200px; left: -140px; }

.hero__inner {
  position: relative;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 48px;
  align-items: center;
  padding-top: 84px;
  padding-bottom: 92px;
}
.hero h1 { color: #fff; margin: 14px 0 18px; }
.hero__lead {
  color: #c3d0e2;
  font-size: 1.13rem;
  max-width: 560px;
  margin-bottom: 30px;
}
.hero__cta { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 30px; }
.hero__points {
  display: flex;
  gap: 26px;
  flex-wrap: wrap;
  list-style: none;
  color: #dbe5f2;
  font-size: 0.95rem;
  font-weight: 500;
}
.hero__points li { display: flex; align-items: center; gap: 9px; }
.check {
  width: 19px; height: 19px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--blue-500), var(--blue-600));
  flex: none;
  position: relative;
}
.check::after {
  content: "";
  position: absolute;
  left: 6px; top: 3.5px;
  width: 4.5px; height: 8.5px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(42deg);
}

.hero__art { display: flex; justify-content: center; }
.hero__logo {
  width: min(430px, 100%);
  filter: drop-shadow(0 24px 48px rgba(0, 0, 0, 0.45));
  animation: float 7s ease-in-out infinite;
}
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-14px); }
}

/* ---------- Trust strip ---------- */
.trust { background: #fff; border-bottom: 1px solid var(--line); }
.trust__inner {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  padding-top: 26px;
  padding-bottom: 26px;
}
.trust__item { display: flex; align-items: center; gap: 14px; }
.trust__item strong {
  display: block;
  font-family: var(--font-head);
  font-size: 1.08rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--navy-900);
}
.trust__item span { font-size: 0.84rem; color: var(--slate); }
.trust__icon {
  width: 48px; height: 48px;
  border-radius: 12px;
  padding: 11px;
  flex: none;
}
.trust__icon--blue { background: var(--blue-100); color: var(--blue-600); }
.trust__icon--orange { background: var(--orange-100); color: var(--orange-600); }

/* ---------- Sections ---------- */
.section { padding: 92px 0; }
.section--tint { background: var(--bg-tint); }
.section--dark {
  background:
    radial-gradient(900px 400px at 90% 0%, rgba(43, 127, 240, 0.18), transparent 55%),
    linear-gradient(180deg, var(--navy-900), var(--navy-800));
  color: #fff;
}
.section--dark h2 { color: #fff; }

.section__head {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 54px;
}
.section__head p { margin-top: 12px; font-size: 1.05rem; }

/* ---------- Services ---------- */
.services__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 26px;
}
.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px 28px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  display: flex;
  flex-direction: column;
}
.card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
  border-color: transparent;
}
.card__icon {
  width: 54px; height: 54px;
  border-radius: 13px;
  padding: 12px;
  margin-bottom: 18px;
}
.card__icon--blue { background: linear-gradient(135deg, var(--blue-500), var(--blue-600)); color: #fff; }
.card__icon--orange { background: linear-gradient(135deg, var(--orange-500), var(--orange-600)); color: #fff; }
.card h3 { margin-bottom: 10px; }
.card > p { font-size: 0.94rem; margin-bottom: 16px; }
.card ul { list-style: none; margin-top: auto; }
.card ul li {
  font-size: 0.9rem;
  color: var(--ink);
  padding: 7px 0 7px 26px;
  border-top: 1px solid var(--line);
  position: relative;
}
.card ul li::before {
  content: "";
  position: absolute;
  left: 4px; top: 14px;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--orange-500);
}

.services__note {
  margin-top: 44px;
  text-align: center;
  background: var(--bg-tint);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 18px 26px;
  font-size: 0.92rem;
  color: var(--slate);
}
.services__note strong {
  color: var(--navy-900);
  display: block;
  margin-bottom: 4px;
  font-family: var(--font-head);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: 1rem;
}

/* ---------- Why us ---------- */
.why__inner {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 60px;
  align-items: start;
}
.why__lead { color: #c3d0e2; font-size: 1.06rem; margin: 16px 0 36px; }
.why__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 26px 34px;
}
.why__item h4 {
  color: #fff;
  margin-bottom: 6px;
  padding-left: 14px;
  border-left: 3px solid var(--orange-500);
}
.why__item p { color: #a9b9cf; font-size: 0.92rem; }

.why__stats {
  display: grid;
  gap: 16px;
}
.stat {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius);
  padding: 22px 26px;
  backdrop-filter: blur(4px);
}
.stat__num {
  display: block;
  font-family: var(--font-head);
  font-size: 2.2rem;
  font-weight: 700;
  background: linear-gradient(90deg, #6db1ff, var(--orange-500));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  line-height: 1.1;
}
.stat__label { font-size: 0.88rem; color: #b9c6d9; }

/* ---------- Process ---------- */
.process {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 26px;
}
.process__step {
  position: relative;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px 24px 26px;
  box-shadow: var(--shadow-sm);
}
.process__num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px; height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--blue-500), var(--blue-600));
  color: #fff;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.3rem;
  margin-bottom: 16px;
}
.process__step:nth-child(even) .process__num {
  background: linear-gradient(135deg, var(--orange-500), var(--orange-600));
}
.process__step h4 { margin-bottom: 8px; }
.process__step p { font-size: 0.9rem; }

/* ---------- Service area ---------- */
.area__inner {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 60px;
  align-items: center;
}
.area__content > p { margin-top: 8px; max-width: 540px; }
.area__list {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px 18px;
  margin: 26px 0;
}
.area__list li {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 9px 14px;
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--navy-800);
  position: relative;
  padding-left: 32px;
}
.area__list li::before {
  content: "";
  position: absolute;
  left: 12px; top: 50%;
  transform: translateY(-50%);
  width: 8px; height: 8px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--blue-500), var(--orange-500));
}
.area__cta { font-size: 0.95rem; }
.area__cta a { font-weight: 600; }

.map-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  padding: 40px 34px;
  text-align: center;
}
.map-card__pin {
  width: 64px; height: 64px;
  margin: 0 auto 16px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--orange-500), var(--orange-600));
  color: #fff;
  padding: 15px;
  box-shadow: 0 10px 26px rgba(224, 122, 18, 0.4);
}
.map-card h4 { margin-bottom: 4px; }
.map-card p { margin-bottom: 20px; }

/* ---------- About ---------- */
.about__inner {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 70px;
  align-items: center;
}
.about__logo {
  background: var(--bg-tint);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 48px;
}
.about__content p { margin: 14px 0; }
.about__content .btn { margin-top: 12px; }

/* ---------- CTA banner ---------- */
.cta-banner {
  background:
    radial-gradient(700px 300px at 15% 0%, rgba(255, 255, 255, 0.14), transparent 55%),
    linear-gradient(120deg, var(--orange-600), var(--orange-500));
  color: #fff;
  padding: 52px 0;
}
.cta-banner__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 26px;
  flex-wrap: wrap;
}
.cta-banner h2 { color: #fff; margin-bottom: 6px; }
.cta-banner p { color: rgba(255, 255, 255, 0.9); font-size: 1.05rem; }

/* ---------- Contact ---------- */
.contact__inner {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 60px;
  align-items: start;
}
.contact__info > p { margin: 10px 0 30px; max-width: 420px; }
.contact__rows { display: grid; gap: 14px; }
.contact__row {
  display: flex;
  align-items: center;
  gap: 16px;
  background: var(--bg-tint);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 15px 18px;
  color: inherit;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
a.contact__row:hover { border-color: var(--blue-500); box-shadow: var(--shadow-sm); }
.contact__row-icon {
  width: 42px; height: 42px;
  flex: none;
  border-radius: 10px;
  background: #fff;
  border: 1px solid var(--line);
  color: var(--blue-600);
  padding: 10px;
}
.contact__row strong {
  display: block;
  font-family: var(--font-head);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-size: 0.95rem;
  color: var(--navy-900);
}
.contact__row span { font-size: 0.92rem; color: var(--slate); }

.contact__form {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  padding: 36px;
}
.form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.form__field { margin-bottom: 18px; }
.form__field label {
  display: block;
  font-weight: 600;
  font-size: 0.85rem;
  margin-bottom: 6px;
  color: var(--navy-800);
}
.form__field input,
.form__field select,
.form__field textarea {
  width: 100%;
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--ink);
  background: var(--bg-tint);
  border: 1.5px solid var(--line);
  border-radius: 9px;
  padding: 12px 14px;
  transition: border-color 0.15s ease, background 0.15s ease;
}
.form__field textarea { resize: vertical; }
.form__field input:focus,
.form__field select:focus,
.form__field textarea:focus {
  outline: none;
  border-color: var(--blue-500);
  background: #fff;
}
.form__field input.invalid,
.form__field select.invalid,
.form__field textarea.invalid { border-color: #d94040; }

.form__check {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.92rem;
  color: var(--navy-800);
  font-weight: 500;
  margin-bottom: 22px;
  cursor: pointer;
}
.form__check input { width: 17px; height: 17px; accent-color: var(--orange-500); }

.hidden { display: none !important; }

.form__status { margin-top: 14px; font-size: 0.92rem; font-weight: 500; text-align: center; }
.form__status.ok { color: #1a8a4a; }
.form__status.err { color: #d94040; }

/* ---------- Footer ---------- */
.footer { background: var(--navy-900); color: #a9b9cf; }
.footer__inner {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  gap: 44px;
  padding-top: 64px;
  padding-bottom: 48px;
}
.footer__brand img { width: 190px; margin-bottom: 18px; }
.footer__brand p { color: #8496ad; font-size: 0.9rem; max-width: 300px; }
.footer__col { display: flex; flex-direction: column; gap: 10px; }
.footer__col h5 {
  font-family: var(--font-head);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 1rem;
  color: #fff;
  margin-bottom: 6px;
}
.footer__col a, .footer__col span { color: #a9b9cf; font-size: 0.92rem; }
.footer__col a:hover { color: var(--orange-500); }
.footer__bar { border-top: 1px solid rgba(255, 255, 255, 0.08); }
.footer__bar-inner {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding-top: 18px;
  padding-bottom: 18px;
  font-size: 0.82rem;
  color: #71829a;
}

/* ---------- Back to top ---------- */
.back-top {
  position: fixed;
  right: 26px;
  bottom: 26px;
  width: 48px; height: 48px;
  border-radius: 50%;
  background: var(--navy-900);
  color: #fff;
  padding: 13px;
  box-shadow: var(--shadow-lg);
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: 0.25s ease;
  z-index: 90;
}
.back-top.show { opacity: 1; visibility: visible; transform: translateY(0); }
.back-top:hover { background: var(--blue-600); }

/* ---------- Reveal on scroll ---------- */
.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.in { opacity: 1; transform: translateY(0); }

/* =========================================================
   Responsive
   ========================================================= */
@media (max-width: 1024px) {
  .hero__inner { grid-template-columns: 1fr; text-align: center; padding-top: 64px; padding-bottom: 64px; }
  .hero__lead { margin-left: auto; margin-right: auto; }
  .hero__cta, .hero__points { justify-content: center; }
  .hero__art { order: -1; }
  .hero__logo { width: min(300px, 80%); }
  .trust__inner { grid-template-columns: repeat(2, 1fr); }
  .services__grid { grid-template-columns: repeat(2, 1fr); }
  .why__inner, .area__inner, .about__inner, .contact__inner { grid-template-columns: 1fr; gap: 44px; }
  .why__stats { grid-template-columns: repeat(2, 1fr); }
  .process { grid-template-columns: repeat(2, 1fr); }
  .footer__inner { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 920px) {
  .nav__links {
    position: absolute;
    top: 100%;
    left: 0; right: 0;
    flex-direction: column;
    gap: 0;
    background: #fff;
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow-md);
    display: none;
    padding: 10px 24px 16px;
  }
  .nav__links.open { display: flex; }
  .nav__links a { padding: 13px 0; border-bottom: 1px solid var(--line); }
  .nav__links a:last-child { border-bottom: none; }
  .nav__toggle { display: flex; }
  .nav__brand-tag { display: none; }
}

@media (max-width: 760px) {
  .topbar__inner { justify-content: center; }
  .topbar__inner > .topbar__item { display: none; }
  .nav__actions .btn { display: none; }
  .section { padding: 64px 0; }
  .services__grid, .process, .trust__inner, .why__grid, .why__stats, .form__row { grid-template-columns: 1fr; }
  .area__list { grid-template-columns: repeat(2, 1fr); }
  .contact__form { padding: 26px 20px; }
  .footer__inner { grid-template-columns: 1fr; gap: 30px; }
  .cta-banner__inner { justify-content: center; text-align: center; }
}
