/* ==========================================================================
   DirectFlow Consulting & Logistics
   Brand colours sampled from the original logo mark.
   ========================================================================== */

:root {
  --orange: #f28c1e;
  --orange-dark: #d97710;
  --teal: #2e7183;
  --teal-dark: #245a68;
  --ink: #111315;
  --body: #2b2f33;
  --muted: #5f676e;
  --line: #e4e7ea;
  --bg-soft: #f6f7f8;
  --white: #fff;

  --wrap: 1240px;
  --header-h: 84px;

  --font: "Poppins", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;
}

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

html { scroll-behavior: smooth; }

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

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

a { color: var(--teal); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3, h4 {
  font-weight: 700;
  line-height: 1.15;
  color: var(--ink);
  margin: 0 0 .6em;
  letter-spacing: -0.01em;
}

h1 { font-size: clamp(2.1rem, 5.2vw, 4rem); }
h2 { font-size: clamp(1.7rem, 3.6vw, 2.9rem); }
h3 { font-size: clamp(1.15rem, 1.8vw, 1.5rem); }

p { margin: 0 0 1rem; }

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: 24px;
}

.section { padding: 84px 0; }
.section--soft { background: var(--bg-soft); }
.section__head { text-align: center; max-width: 760px; margin: 0 auto 48px; }

.skip-link {
  position: absolute; left: -9999px; top: 0;
  background: var(--ink); color: #fff; padding: 12px 20px; z-index: 200;
}
.skip-link:focus { left: 0; }

/* ---------- Buttons ---------------------------------------------------- */
.btn {
  display: inline-block;
  padding: 14px 30px;
  font-weight: 600;
  font-size: .95rem;
  border: 0;
  cursor: pointer;
  transition: background .18s ease, color .18s ease;
  text-align: center;
}
.btn:hover { text-decoration: none; }
.btn--orange { background: var(--orange); color: #1b1b1b; }
.btn--orange:hover { background: var(--orange-dark); }
.btn--teal { background: var(--teal); color: #fff; }
.btn--teal:hover { background: var(--teal-dark); }
.btn--ghost { background: transparent; color: #fff; border: 2px solid #fff; }
.btn--ghost:hover { background: #fff; color: var(--ink); }

/* ---------- Header ------------------------------------------------------ */
.header {
  position: sticky; top: 0; z-index: 100;
  background: var(--ink);
  height: var(--header-h);
  display: flex; align-items: center;
}
.header__inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: 24px; width: 100%;
}
.brand { display: flex; align-items: center; gap: 12px; }
.brand:hover { text-decoration: none; }
.brand img { width: 46px; height: 46px; }
.brand__name {
  color: #fff; font-weight: 700; font-size: 1.65rem; line-height: 1;
  letter-spacing: -0.02em;
}
.brand__tag {
  display: block; color: #b9c0c6; font-size: .52rem;
  letter-spacing: .22em; font-weight: 500; margin-top: 4px;
}

.nav { display: flex; align-items: center; gap: 26px; }
.nav a {
  color: #e9edf0; font-size: .88rem; font-weight: 500;
  padding: 6px 0; border-bottom: 2px solid transparent;
}
.nav a:hover { color: var(--orange); text-decoration: none; }
.nav a.is-active { color: var(--orange); border-bottom-color: var(--orange); }

.nav a.nav__portal {
  background: var(--orange); color: #1b1b1b; padding: 9px 18px;
  font-weight: 600; border-bottom: 0;
}
.nav a.nav__portal:hover { background: #fff; color: var(--ink); }

.nav-toggle {
  display: none; background: none; border: 0; cursor: pointer;
  padding: 8px; width: 44px; height: 44px;
}
.nav-toggle span {
  display: block; width: 26px; height: 2px; background: #fff; margin: 5px 0;
  transition: transform .2s ease, opacity .2s ease;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero -------------------------------------------------------- */
.hero {
  position: relative;
  min-height: clamp(520px, 74vh, 760px);
  display: flex; align-items: center;
  background: #0c0e10 center/cover no-repeat;
  color: #fff;
}
.hero::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(8,10,12,.86) 0%, rgba(8,10,12,.6) 45%, rgba(8,10,12,.15) 100%);
}
.hero .wrap { position: relative; z-index: 1; }
.hero h1 { color: #fff; max-width: 15ch; margin-bottom: 34px; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 0; }
.hero__cta .btn--teal { padding: 22px 34px; font-size: 1rem; text-decoration: underline; }
.hero__quote {
  background: var(--orange); color: #1b1b1b;
  padding: 16px 26px; max-width: 260px;
}
.hero__quote strong { display: block; font-size: .95rem; letter-spacing: .02em; }
.hero__quote span { font-size: .82rem; line-height: 1.35; display: block; margin-top: 4px; }

.page-hero {
  background: var(--ink) center/cover no-repeat;
  color: #fff; padding: 92px 0; position: relative; text-align: center;
}
.page-hero::after { content: ""; position: absolute; inset: 0; background: rgba(10,12,14,.66); }
.page-hero .wrap { position: relative; z-index: 1; }
.page-hero h1 { color: #fff; margin: 0 auto; max-width: 20ch; }
.page-hero p { color: #d7dcdf; max-width: 62ch; margin: 18px auto 0; }

/* ---------- Split band -------------------------------------------------- */
.split { display: grid; grid-template-columns: 1fr 1fr; align-items: stretch; }
.split__text { background: var(--orange); padding: 84px 6vw; display: flex; flex-direction: column; justify-content: center; }
.split__text h2 { color: #fff; max-width: 12ch; }
.split__text p { color: #23282c; max-width: 52ch; font-size: .95rem; }
.split__text .btn { align-self: flex-start; margin-top: 14px; }
.split__media { background: #ddd center/cover no-repeat; min-height: 460px; }
.split--flip .split__text { order: 2; }
.split--teal .split__text { background: var(--teal); }
.split--teal .split__text p { color: #eaf1f3; }

/* ---------- Service cards ---------------------------------------------- */
.cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 4px; }
.card { background: var(--white); display: flex; flex-direction: column; }
.card__media { aspect-ratio: 16 / 9; background: #e9ecee center/cover no-repeat; }
.card__body { padding: 34px 34px 40px; display: flex; flex-direction: column; flex: 1; }
.card__body h3 { margin-bottom: 14px; }
.card__body p { font-size: .88rem; font-weight: 600; color: #33383d; max-width: 42ch; }
.card__body .btn { align-self: flex-start; margin-top: auto; padding: 12px 26px; }

/* ---------- Feature band ------------------------------------------------ */
.band {
  position: relative; padding: 110px 0; text-align: center; color: #fff;
  background: #2a2d30 center/cover no-repeat;
}
.band::after { content: ""; position: absolute; inset: 0; background: rgba(18,20,22,.55); }
.band .wrap { position: relative; z-index: 1; }
.band h2 { color: #fff; margin-bottom: 46px; }
.band__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.band__item {
  background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.22);
  backdrop-filter: blur(3px); padding: 30px 24px;
}
.band__item h3 { color: #fff; font-size: 1.1rem; margin: 0; }

/* ---------- Testimonial ------------------------------------------------- */
.quote { text-align: center; max-width: 760px; margin-inline: auto; }
.quote blockquote {
  margin: 0 0 18px; font-size: clamp(1.1rem, 2vw, 1.5rem);
  font-weight: 500; color: var(--ink); line-height: 1.5;
}
.quote cite { font-style: normal; color: var(--muted); font-size: .9rem; }

/* ---------- Partner logos ----------------------------------------------- */
.logos {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 34px 28px; align-items: center; margin-top: 8px;
}
.logos img {
  max-height: 46px; width: auto; margin-inline: auto;
  transition: transform .2s ease;
}
.logos img:hover { transform: scale(1.06); }

/* ---------- Forms ------------------------------------------------------- */
.form { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.form .full { grid-column: 1 / -1; }
.field label {
  display: block; font-size: .78rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: .08em; color: var(--muted); margin-bottom: 7px;
}
.field input, .field textarea {
  width: 100%; padding: 13px 15px; font: inherit; font-size: .95rem;
  color: var(--ink); background: #fff; border: 1px solid var(--line);
  border-radius: 2px;
}
.field input:focus, .field textarea:focus {
  outline: 2px solid var(--teal); outline-offset: 1px; border-color: var(--teal);
}
.field textarea { min-height: 138px; resize: vertical; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.notice { padding: 14px 18px; margin-bottom: 22px; font-size: .92rem; border-left: 4px solid; }
.notice--ok { background: #eef7f0; border-color: #3f9a5c; color: #1f5c33; }
.notice--bad { background: #fdf0ee; border-color: #c4462f; color: #8a2c1c; }

/* ---------- Contact strip ----------------------------------------------- */
.info-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 34px; }
.info-grid h3 { font-size: 1rem; text-transform: uppercase; letter-spacing: .1em; }
.info-grid p { font-size: .93rem; margin-bottom: .3rem; }

/* ---------- FAQ --------------------------------------------------------- */
.faq { max-width: 860px; margin-inline: auto; }
.faq details {
  border-bottom: 1px solid var(--line); padding: 20px 0;
}
.faq summary {
  cursor: pointer; font-weight: 600; color: var(--ink); font-size: 1.05rem;
  list-style: none; display: flex; justify-content: space-between; gap: 20px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--orange); font-size: 1.5rem; line-height: 1; }
.faq details[open] summary::after { content: "\2013"; }
.faq details p { margin: 14px 0 0; color: var(--muted); font-size: .95rem; }

/* ---------- Service page content ---------------------------------------- */
.intro {
  font-size: clamp(1rem, 1.5vw, 1.18rem); line-height: 1.7; color: var(--body);
  max-width: 74ch; margin-inline: auto; text-align: center;
}
.prose--wide .intro { text-align: left; margin-inline: 0; }

.benefits { list-style: none; margin: 0; padding: 0; max-width: 900px; margin-inline: auto; }
.benefits li {
  position: relative; padding: 14px 0 14px 34px; border-bottom: 1px solid var(--line);
  font-size: .96rem; color: var(--body);
}
.benefits li:last-child { border-bottom: 0; }
.benefits li::before {
  content: ""; position: absolute; left: 6px; top: 22px;
  width: 8px; height: 8px; background: var(--orange); border-radius: 50%;
}
.benefits strong { color: var(--ink); }

.pillgrid { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }
.pillgrid span {
  background: var(--bg-soft); border: 1px solid var(--line);
  padding: 12px 22px; font-size: .93rem; font-weight: 600; color: var(--ink);
}

/* Client logos are wordmarks, not square icons, so they need more room and a
   little more presence than the partner rows — these are the proof points. */
.logos--clients { gap: 46px 40px; }
.logos--clients img { max-height: 52px; }

/* ---------- Lifecycle flow ----------------------------------------------
   A five-step flow that reads left-to-right on a desktop and top-to-bottom on
   a phone. Steps 2-4 are the repeating part of the season, marked with a tinted
   top edge and called out beneath, because that loop is the bit words struggle
   to explain. */
.flow {
  list-style: none; margin: 0; padding: 0;
  display: grid; grid-template-columns: repeat(5, 1fr); gap: 18px;
  counter-reset: flow;
}

.flow__step {
  position: relative; background: #fff; border: 1px solid var(--line);
  border-top: 3px solid var(--teal);
  padding: 26px 20px 22px; text-align: center;
}
.flow__step--cycle { border-top-color: var(--orange); }

/* Connector arrow between steps. */
.flow__step::after {
  content: ""; position: absolute; top: 50%; right: -14px;
  width: 10px; height: 10px; margin-top: -5px; z-index: 2;
  border-top: 2px solid var(--muted); border-right: 2px solid var(--muted);
  transform: rotate(45deg);
}
.flow__step:last-child::after { content: none; }

.flow__num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 38px; height: 38px; border-radius: 50%;
  background: var(--teal); color: #fff; font-weight: 700; font-size: 1.05rem;
  margin-bottom: 14px;
}
.flow__step--cycle .flow__num { background: var(--orange); color: #1b1b1b; }

.flow__step h3 { font-size: 1rem; margin-bottom: 8px; }
.flow__step p { font-size: .85rem; color: var(--muted); margin: 0; line-height: 1.55; }

.flow__loop {
  margin: 22px auto 0; max-width: 760px; text-align: center;
  font-size: .88rem; color: var(--muted);
  background: #fff; border: 1px dashed var(--orange);
  padding: 13px 20px;
}
.flow__loop span {
  color: var(--orange); font-size: 1.25rem; font-weight: 700;
  margin-right: 8px; vertical-align: -2px;
}

@media (max-width: 1024px) {
  .flow { grid-template-columns: repeat(2, 1fr); }
  /* Sideways arrows stop making sense once the row wraps. */
  .flow__step::after { content: none; }
}

@media (max-width: 640px) {
  .flow { grid-template-columns: 1fr; gap: 12px; }
  .flow__step {
    text-align: left; display: grid; grid-template-columns: 44px 1fr;
    column-gap: 14px; align-items: start; padding: 18px 16px;
  }
  .flow__num { grid-row: span 2; margin-bottom: 0; width: 34px; height: 34px; font-size: .95rem; }
  .flow__step h3 { margin-bottom: 4px; }
  .flow__loop { text-align: left; font-size: .84rem; }
}

/* ---------- Prose (privacy / terms) ------------------------------------- */
.prose { max-width: 800px; margin-inline: auto; }
.prose--wide { max-width: 900px; }
.prose--wide p { font-size: 1rem; color: var(--body); line-height: 1.8; }
.prose h2 { font-size: 1.4rem; margin-top: 2em; }
.prose p, .prose li { font-size: .95rem; color: var(--muted); }

/* ---------- Footer ------------------------------------------------------ */
.footer { background: var(--ink); color: #c3cacf; padding: 72px 0 30px; }
.footer h4 {
  color: #fff; font-size: .8rem; letter-spacing: .16em;
  text-transform: uppercase; margin: 0 0 16px;
}
.footer a { color: #c3cacf; font-size: .92rem; }
.footer a:hover { color: var(--orange); text-decoration: none; }
.footer__grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 40px; }
.footer__grid p, .footer__grid li { font-size: .92rem; margin-bottom: .45rem; }
.footer ul { list-style: none; margin: 0; padding: 0; }
.footer__social { display: flex; gap: 12px; margin-top: 18px; }
.footer__social img { width: 28px; height: 28px; opacity: .8; }
.footer__social a:hover img { opacity: 1; }
.footer__base {
  margin-top: 48px; padding-top: 22px; border-top: 1px solid #262a2e;
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  font-size: .82rem; color: #8a9299;
}

/* ---------- Responsive -------------------------------------------------- */
@media (max-width: 1024px) {
  .band__grid { grid-template-columns: 1fr; }
  .info-grid { grid-template-columns: 1fr 1fr; }
  .footer__grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 860px) {
  .nav-toggle { display: block; }
  .nav {
    position: fixed; inset: var(--header-h) 0 auto 0;
    background: var(--ink); flex-direction: column; align-items: stretch;
    gap: 0; padding: 8px 24px 26px; display: none;
    border-top: 1px solid #24282c; max-height: calc(100vh - var(--header-h));
    overflow-y: auto;
  }
  .nav.is-open { display: flex; }
  .nav a { padding: 15px 0; border-bottom: 1px solid #22262a; }
  .nav a.is-active { border-bottom-color: var(--orange); }

  .split { grid-template-columns: 1fr; }
  .split--flip .split__text { order: 0; }
  .split__media { min-height: 300px; }
  .split__text { padding: 56px 24px; }

  .cards { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
  .section { padding: 56px 0; }
  .wrap { padding-inline: 18px; }
  .hero { min-height: 78vh; }
  .hero::after {
    background: linear-gradient(180deg, rgba(8,10,12,.55) 0%, rgba(8,10,12,.85) 70%);
  }
  .hero h1 { max-width: 100%; }
  .hero__cta { flex-direction: column; align-items: stretch; }
  .hero__quote { max-width: 100%; }
  .hero .btn--teal { width: 100%; }

  .form { grid-template-columns: 1fr; }
  .info-grid { grid-template-columns: 1fr; gap: 26px; }
  .footer { padding-top: 52px; }
  .footer__grid { grid-template-columns: 1fr; gap: 32px; }
  .footer__base { flex-direction: column; }
  .band { padding: 68px 0; }
  .card__body { padding: 26px 22px 30px; }
  .logos { gap: 26px 18px; }
  .logos img { max-height: 36px; }
  .logos--clients { gap: 28px 20px; }
  .logos--clients img { max-height: 30px; }
  .intro { text-align: left; font-size: 1rem; }
  .benefits li { padding-left: 26px; font-size: .92rem; }
  .pillgrid { justify-content: flex-start; gap: 8px; }
  .pillgrid span { padding: 10px 16px; font-size: .86rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
