/* ==========================================================================
   FACILIT8 — design tokens
   ========================================================================== */

:root {
  --navy: #1f3a70;
  --blue: #335fb7;
  --near-black: #111827;
  --body-gray: #374151;
  --section-gray: #ebecec;
  --white: #ffffff;

  --font-heading: 'Open Sans', sans-serif;
  --font-body: 'Inter', sans-serif;

  --container-width: 1320px;
  --section-pad: 80px;
  --section-pad-sm: 48px;
  --radius: 8px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--body-gray);
  background: var(--white);
  line-height: 1.5;
}

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

a {
  text-decoration: none;
  color: inherit;
}

ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

h1, h2, h3, h4 {
  font-family: var(--font-heading);
  font-weight: 700;
  color: var(--near-black);
  margin: 0;
}

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

.section {
  padding: var(--section-pad) 0;
}

.section--sm {
  padding: var(--section-pad-sm) 0;
}

.section--gray {
  background: var(--section-gray);
}

.section--navy {
  background: var(--navy);
}

.eyebrow {
  color: var(--navy);
}

.btn {
  display: inline-block;
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 16px;
  padding: 12px 20px;
  border-radius: var(--radius);
  border: none;
  cursor: pointer;
  transition: opacity 0.15s ease;
}

.btn:hover {
  opacity: 0.9;
}

.btn--white {
  background: var(--white);
  color: var(--navy);
}

.btn--blue {
  background: var(--blue);
  color: var(--white);
}

.text-center {
  text-align: center;
}

/* ==========================================================================
   Nav
   ========================================================================== */

.navbar {
  height: 80px;
  display: flex;
  align-items: center;
  background: var(--white);
}

.navbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

.navbar__logo img {
  height: 28px;
}

.navbar__links {
  display: flex;
  align-items: center;
  gap: 32px;
}

.navbar__links a {
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 16px;
  color: var(--body-gray);
}

.navbar__cta {
  display: flex;
  align-items: center;
  gap: 24px;
}

.navbar__toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.navbar__toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--near-black);
  margin: 5px 0;
}

/* ==========================================================================
   Hero
   ========================================================================== */

.hero {
  background: url('assets/hero-bg.jpg') center / cover no-repeat;
  text-align: center;
  padding-top: 96px;
  padding-bottom: 0;
}

.hero__eyebrow-space {
  padding-bottom: 64px;
}

.hero h1 {
  color: var(--white);
  font-size: 64px;
  line-height: 1.1;
  font-style: italic;
  text-transform: uppercase;
  margin: 0 auto 24px;
  max-width: 780px;
}

.hero p {
  color: var(--white);
  font-size: 18px;
  margin: 0 auto 32px;
  max-width: 480px;
}

.hero__mockup {
  max-width: 640px;
  margin: 64px auto 0;
  position: relative;
}

/* ==========================================================================
   Intro
   ========================================================================== */

.intro {
  text-align: center;
}

.intro h2 {
  font-size: 48px;
  line-height: 1.1;
  margin-bottom: 24px;
}

.intro p {
  max-width: 720px;
  margin: 0 auto;
  font-size: 16px;
}

/* ==========================================================================
   Feature row
   ========================================================================== */

.features {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 48px;
  text-align: center;
}

.feature img {
  width: 96px;
  height: 96px;
  margin: 0 auto 24px;
}

.feature h3 {
  font-size: 20px;
  letter-spacing: 0.5px;
  margin-bottom: 8px;
}

.feature__subhead {
  font-weight: 600;
  color: var(--near-black);
  margin-bottom: 8px;
}

.feature p {
  font-size: 16px;
}

/* ==========================================================================
   How it works (zig-zag)
   ========================================================================== */

.how-step {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}

.how-step + .how-step {
  margin-top: 80px;
}

.how-step:nth-child(even) .how-step__media {
  order: 2;
}

.how-step__media img {
  border-radius: var(--radius);
  width: 100%;
}

.how-step h3 {
  font-size: 32px;
  margin-bottom: 16px;
}

.how-step p {
  font-size: 16px;
}

/* ==========================================================================
   Services
   ========================================================================== */

.services {
  position: relative;
}

.services__divider {
  display: block;
  width: 100%;
  line-height: 0;
}

.services__divider img {
  width: 100%;
}

.services__divider--top {
  margin-bottom: -1px;
}

.services__divider--bottom {
  margin-top: -1px;
}

.services__intro {
  text-align: center;
  margin-bottom: 48px;
}

.services__intro h2 {
  font-size: 48px;
  margin-bottom: 16px;
}

.services__intro p {
  max-width: 640px;
  margin: 0 auto;
}

.tabs__list {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-bottom: 48px;
}

.tabs__tab {
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 16px;
  padding: 12px 24px;
  border-radius: var(--radius);
  background: var(--white);
  color: var(--near-black);
  border: none;
  cursor: pointer;
}

.tabs__tab.is-active {
  background: var(--navy);
  color: var(--white);
}

.tabs__panel {
  display: none;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}

.tabs__panel.is-active {
  display: grid;
}

.tabs__panel h3 {
  font-size: 32px;
  margin-bottom: 16px;
}

.tabs__panel img {
  border-radius: var(--radius);
  width: 100%;
}

.tabs__link {
  display: inline-block;
  margin-top: 24px;
  color: var(--blue);
  font-weight: 600;
}

/* ==========================================================================
   Map
   ========================================================================== */

.map {
  text-align: center;
}

.map h2 {
  font-size: 32px;
  margin-bottom: 32px;
}

.map__embed {
  border-radius: var(--radius);
  overflow: hidden;
  max-width: 960px;
  margin: 0 auto;
}

.map__embed iframe {
  width: 100%;
  height: 480px;
  border: 0;
  display: block;
}

/* ==========================================================================
   FAQ
   ========================================================================== */

.faq__intro {
  text-align: center;
  margin-bottom: 48px;
}

.faq__intro h2 {
  font-size: 48px;
  margin-bottom: 16px;
}

.faq__intro p {
  max-width: 640px;
  margin: 0 auto;
}

.faq__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 48px;
}

.faq-item {
  border-bottom: 1px solid #d8dade;
}

.faq-item__question {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  background: none;
  border: none;
  text-align: left;
  padding: 20px 0;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 16px;
  color: var(--near-black);
  cursor: pointer;
}

.faq-item__icon {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  position: relative;
}

.faq-item__icon::before,
.faq-item__icon::after {
  content: '';
  position: absolute;
  background: var(--navy);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.faq-item__icon::before {
  width: 14px;
  height: 2px;
}

.faq-item__icon::after {
  width: 2px;
  height: 14px;
  transition: transform 0.2s ease;
}

.faq-item.is-open .faq-item__icon::after {
  transform: translate(-50%, -50%) scaleY(0);
}

.faq-item__answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.25s ease;
}

.faq-item__answer p {
  font-size: 15px;
  padding-bottom: 20px;
  margin: 0;
}

/* ==========================================================================
   CTA + Footer
   ========================================================================== */

.cta-footer {
  color: var(--white);
}

.cta {
  text-align: center;
}

.cta h2 {
  color: var(--white);
  font-size: 48px;
  margin-bottom: 16px;
}

.cta p {
  color: var(--white);
  margin-bottom: 32px;
}

.cta__mockup {
  max-width: 560px;
  margin: 64px auto 0;
}

.footer {
  border-top: 1px solid rgba(255, 255, 255, 0.15);
}

.footer__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.footer__grid h4 {
  color: var(--white);
  font-size: 20px;
  margin-bottom: 16px;
}

.footer__grid ul li {
  margin-bottom: 12px;
}

.footer__grid a {
  color: var(--white);
  font-size: 16px;
  font-weight: 500;
}

.footer__social img {
  width: 24px;
  margin-top: 8px;
}

.footer__bottom {
  text-align: center;
  margin-top: 48px;
  font-size: 16px;
  font-weight: 500;
  color: var(--white);
}

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 991px) {
  .features {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .how-step,
  .tabs__panel {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .how-step:nth-child(even) .how-step__media {
    order: 0;
  }

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

@media (max-width: 767px) {
  .navbar__links {
    display: none;
    position: absolute;
    top: 80px;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    background: var(--white);
    padding: 8px 24px 24px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.08);
  }

  .navbar__links a {
    padding: 12px 0;
    width: 100%;
  }

  .navbar__links.is-open {
    display: flex;
  }

  .navbar__cta a:first-child {
    display: none;
  }

  .navbar__toggle {
    display: block;
  }

  .navbar {
    position: relative;
  }

  .hero h1 {
    font-size: 40px;
  }

  .intro h2,
  .services__intro h2,
  .faq__intro h2,
  .cta h2 {
    font-size: 32px;
  }

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

  .tabs__list {
    flex-wrap: wrap;
  }

  .footer__grid {
    grid-template-columns: 1fr;
    text-align: center;
  }
}
