/* Bitness Labs — static site styles.
   Mirrors the look of the previous Next.js + Tailwind build. */

:root {
  --brand-blue: #094d82;
  --brand-cyan: #98d8f8;
  --brand-charcoal: #273642;
  --brand-light-grey: #dce9ed;
}

@font-face {
  font-family: 'Vollkorn';
  font-style: normal;
  font-weight: 400 900;
  font-display: swap;
  src: url('fonts/vollkorn-latin.woff2') format('woff2');
}

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

html {
  line-height: 1.5;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: 'Vollkorn', 'Times New Roman', serif;
  background: #fff;
}

h1,
h2,
p {
  margin: 0;
  font-size: inherit;
  font-weight: inherit;
}

img,
svg {
  display: block;
}

img {
  max-width: 100%;
  height: auto;
}

a {
  color: var(--brand-blue);
  text-decoration: underline;
}

a:hover {
  color: var(--brand-charcoal);
}

main {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
}

/* Hero: the background photo is mirrored, the logo is not. */
.hero {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100vw;
  max-width: 100%;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.1)),
    url('images/bitnesslabs-hero.webp') 0 0 / max(100%, 1900px) auto;
  transform: scaleX(-1);
}

.hero img {
  position: relative;
  width: auto; /* keep natural size; the width/height attributes only reserve space */
  padding: 3rem;
}

.content {
  width: 100%;
  background: var(--brand-cyan);
}

/* Intro + services */
.intro {
  margin: 1.25rem;
}

.intro h1 {
  margin: 1.5rem;
  font-size: 1.5rem;
  line-height: 2rem;
  text-align: center;
}

.intro .lead,
.intro .categories {
  margin: 0.75rem;
}

.services {
  display: grid;
  grid-template-columns: 1fr;
  justify-items: center;
  margin: 0 auto;
  text-align: center;
}

.service {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1.25rem 0.75rem;
}

.service svg {
  width: 6rem;
  height: 6rem;
}

.service h3 {
  margin: 0;
  padding-bottom: 0.25rem;
  font-size: 1.5rem;
  line-height: 2rem;
  font-weight: inherit;
}

.service p {
  text-align: left;
}

/* Clients */
.clients {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--brand-charcoal);
  background: #fff; /* the logos are drawn for a white background */
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
}

.clients h2 {
  margin: 1.5rem;
  font-size: 2.25rem;
  line-height: 2.5rem;
}

.client-logos {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  justify-items: center;
  margin: 0 auto;
  padding: 0 0 0.5rem;
  list-style: none;
}

.client-logos li {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0.5rem;
}

/* Phones: every logo gets the same box, so tall logos don't stretch the rows. */
.client-logos img {
  width: 100%;
  height: 6rem;
  padding: 0.75rem;
  object-fit: contain;
}

/* Contact */
.contact {
  margin: 2.5rem;
}

.contact p {
  margin: 1.5rem;
  font-size: 1.25rem;
  line-height: 1.75rem;
  text-align: center;
}

.contact svg {
  display: inline-block;
  width: 1.5rem;
  height: 1.5rem;
  margin: 0.5rem;
  vertical-align: middle;
}

@media (min-width: 640px) {
  .intro .categories {
    text-align: center;
  }
}

@media (min-width: 768px) {
  .intro h1 {
    margin: 2.5rem;
    font-size: 2.25rem;
    line-height: 2.5rem;
  }

  .intro .lead,
  .intro .categories {
    font-size: 1.25rem;
    line-height: 1.75rem;
  }

  .intro .lead {
    margin: 2.5rem 8rem;
  }

  .intro .categories {
    margin: 1.5rem 5rem;
  }

  .services,
  .client-logos {
    width: 100%;
    max-width: 56rem;
  }

  .services {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .clients h2 {
    margin: 2.5rem;
  }

  .client-logos {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .client-logos img {
    height: auto;
    padding: 1rem;
  }
}

@media (min-width: 1024px) {
  .client-logos {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

  .client-logos img {
    max-width: 20rem;
  }
}
