body {
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease-in-out;
  background-color: var(--dark-bg);
  color: var(--light-text);
}

.content {
  opacity: 0;
  animation: fadeIn 0.3s forwards;
}

@keyframes fadeIn {
  to {
    opacity: 1;
  }
}

.navigating {
  opacity: 0;
}

.loaded {
  opacity: 1;
}

.logo {
  max-width: 3.5rem;
  height: auto;
  aspect-ratio: initial;
}

.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding-inline: var(--container-padding);
}

.header {
  top: 0;
  left: 0;
  right: 0;
  transition: all 0.3s ease;
  z-index: 99;
  position: fixed;
  height: 4.75rem;
  display: flex;
}

main {
  padding-top: 4.75rem;
}

main section .container {
  position: relative;
}

.flowers {
  position: absolute;
  inset: 0;
  display: flex;
  justify-content: space-between;
  overflow: visible;
}

.flower1,
.flower2 {
  position: sticky;
  top: 0;
  pointer-events: none;
  align-self: flex-start;
}

.flower1 {
  margin-left: -30%;
}

.flower2 {
  margin-right: -30%;
}

.content-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: relative;
  /* border: 1px solid green; */
}

.content-header::before {
  content: '';
  position: absolute;
  width: 120%;
  height: 180%;
  background: url('../../images/bg-pattern.png');
  box-shadow: inset 0 0 160px 160px hsla(220, 20%, 6%, 1);
  z-index: -1;
  opacity: 1;
  /* border: 1px solid red; */
}

.header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.main-nav {
  display: flex;
  gap: 2rem;
}

.main-nav li a {
  text-decoration: none;
  display: flex;
  height: 100%;
  align-items: center;
}

.eyebrown {
  color: var(--dark-text);
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

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

.hero .container {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.home .hero {
  text-align: center;
  overflow: clip;
}

.hero h1 {
  font-size: 4rem;
  margin-bottom: 1.5rem;
  max-width: 16ch;
  line-height: 1.2;
}

.hero .subtitle {
  font-size: 1.25rem;
  color: var(--dark-text);
  margin-bottom: 4rem;
  max-width: 60ch;
}

.case-list {
  display: flex;
  flex-direction: column;
  gap: 3rem;
}

.case-item {
  aspect-ratio: 16/9;
  background-color: blueviolet;
  width: 100%;
  margin: auto;
  border-radius: 0.75rem;
  position: relative;
  overflow: hidden;
  box-shadow: 0 1rem 4rem rgba(0, 0, 0, 0.4);
  max-height: 80vh;
}

.case-item::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  background: -moz-linear-gradient(0deg, rgba(0, 0, 0, 0.8519782913165266) 0%, rgba(0, 0, 0, 0.2497373949579832) 100%);
  background: -webkit-linear-gradient(0deg, rgba(0, 0, 0, 0.85) 0%, rgba(0, 0, 0, 0.25) 100%);
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.85) 0%, rgba(0, 0, 0, 0.25) 100%);
  filter: progid:DXImageTransform.Microsoft.gradient(startColorstr="#000000",endColorstr="#000000",GradientType=1);
  opacity: 0;
  transition: opacity 0.3s;
}

.case-item:hover::before,
.case-item:focus-within::before {
  opacity: 0.75;
}

.case-item > div {
  color: white;
  text-align: left;
  position: absolute;
  bottom: 0;
  font-size: 1.125rem;
  padding: 0 0 2.25rem 2.5rem;
  opacity: 0;
  transform: translateY(50%);
  transition: opacity 0.3s, transform 0.3s;
  width: 100%;
}

.case-item:hover > div,
.case-item:focus-within > div {
  opacity: 1;
  transform: translateY(0);
}

.case-item h3 {
  font-size: 2rem;
  margin-bottom: 0.375rem;
  text-shadow: 0.125rem 0.125rem 0.25rem rgba(0, 0, 0, 0.5);
}

.case-item p {
  text-shadow: 0.0625rem 0.0625rem 0.125rem rgba(0, 0, 0, 0.5);
}

.case-item a {
  position: absolute;
  inset: 0;
  opacity: 0;
}

.case-item:has(a:focus-visible) {
  outline: 2px solid white;
  outline-offset: 2px;
}

.companies {
  text-align: center;
}

.companies h2 {
  font-weight: normal;
  font-size: 1.25rem;
  margin-bottom: 3rem;
}

.companies .logos {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  padding-bottom: var(--section-padding);
}

.companies .logos img {
  filter: grayscale(100%) brightness(1.5);
  transition: filter 0.3s;
}

/* Domino's */
.companies .logos img:nth-child(1) {
  max-height: min(3.5vw, 2.5rem);
}

/* S&P */
.companies .logos img:nth-child(2) {
  max-height: min(3.25vw, 2.32rem);
}

/* CIBC */
.companies .logos img:nth-child(3) {
  max-height: min(2.5vw, 1.785rem);
}

/* MAGALU */
.companies .logos img:nth-child(4) {
  max-height: min(2.75vw, 1.963rem);
}

/* Itaú */
.companies .logos img:nth-child(5) {
  max-height: min(4.25vw, 3.03rem);
}

.companies .logos img:hover {
  filter: none;
}

.section-border {
  border-bottom: 2px solid var(--darker-stroke);
}

.expertise {
  padding-top: var(--section-padding);
}

.expertise .title,
.contact .title {
  font-size: 2.25rem;
  margin-bottom: 1.25rem;
}

.expertise .title {
  max-width: 32ch;
}

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

.expertise .subtitle {
  font-size: 1.25rem;
  color: var(--dark-text);
  margin-bottom: 4rem;
  max-width: 64ch;
}

.skills {
  display: flex;
  gap: 4rem;
  padding-bottom: var(--section-padding);
  width: 100%;
}

.skills > div {
  flex-basis: 50%;
}

.skill-logos {
  display: flex;
  position: relative;
  align-items: center;
}

.skill-logos img {
  max-width: 124px;
  aspect-ratio: 1;
}

.logos-container {
  padding: 0 3.5rem;
  flex-wrap: wrap;
  justify-content: space-between;
  align-content: center;
  row-gap: 1.5rem;
  width: 100%;
  display: flex;
  opacity: 0;
  position: absolute;
  transition: opacity 0.3s;
  pointer-events: none;
}

.logos-container.active {
  opacity: 1;
  transition: opacity 0.3s 0.3s;
  pointer-events: all;
}

.skill-item h3 {
  font-size: 1.5rem;
  margin-bottom: 0.5rem;
}

.skill-item p {
  color: var(--dark-text);
}

.skill-list {
  display: flex;
  padding-left: 2rem;
  position: relative;
}

.skill-list::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 0.25rem;
  height: 100%;
  background-color: var(--dark-stroke);
}

.active-skill-indicator {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 0.25rem;
  height: 33.33%;
  background-color: var(--primary);
  transition: transform 0.3s;
}

.skill-list ul,
.skill-item {
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.skill-item {
  justify-content: center;
  cursor: pointer;
  padding: 1rem 0;
}

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

.contact .methods {
  display: flex;
  justify-content: center;
  gap: 2rem;
  color: var(--dark-text);
  font-size: 1.25rem;
  margin-bottom: 2.5rem;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  margin: auto;
  max-width: 480px;
}

.contact-form label {
  display: block;
  margin-bottom: 0.5rem;
}

.contact-form input,
.contact-form textarea {
  padding: 0.5rem 1rem;
  border: 1px solid var(--dark-stroke);
  border-radius: 0.5rem;
  width: 100%;
  background-color: transparent;
  color: var(--light-text);
}
.contact-form textarea {
  height: 8rem;
}

.contact-form input {
  height: 2.75rem;
}

input placeholder,
textarea placeholder {
  color: var(--dark-text);
}

footer .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 0.5rem;
  color: var(--dark-text);
  font-size: 0.875rem;
}

footer .logo {
  max-width: 2.5rem;
  aspect-ratio: initial;
}

.button {
  padding: 0.75rem 1.125rem;
  border: 2px solid var(--primary);
  border-radius: 0.5rem;
  background-color: var(--primary);
  color: var(--light-text);
  cursor: pointer;
  transition: background-color 0.3s;
  display: inline-block;
}

.button--lg {
  padding: 1rem 1.5rem;
  font-size: 1.25rem;
}

.button:hover {
  background-color: transparent;
  text-decoration: none;
}

.button.loading {
  opacity: 0.5;
  pointer-events: none;
}

.title {
  font-family: 'Libre Baskerville', serif;
  font-weight: 400;
  font-style: normal;
}

.logos-container-mobile {
  display: none;
}

h3,
h4,
h5,
h6,
.button,
nav a {
  font-weight: 600;
  margin: 0;
}

.orphan-item {
  margin: 0 auto;
}

.form-message {
  text-align: center;
  margin-top: 1rem;
}

.italic {
  font-style: italic;
}

.sticky-bg {
  backdrop-filter: blur(0.25rem);
  background-color: #0c0e12c4;
}

.hide {
  top: calc(-6rem) !important;
}

@media screen and (max-width: 1439px) {
  .flower1,
  .flower2 {
    display: none;
  }
}

@media screen and (max-width: 1279px) {
  .skill-logos,
  .skill-list::before,
  .active-skill-indicator {
    display: none;
  }

  .expertise .container {
    align-items: center;
    display: flex;
    flex-direction: column;
    text-align: center;
  }

  .skills > div {
    flex-basis: 100%;
  }

  .skill-list {
    padding-left: 0;
  }

  .skill-list ul {
    gap: 4rem;
  }

  .logos-container-mobile {
    display: flex;
    position: relative;
    padding: 0;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
  }

  .logos-container-mobile img {
    width: min(20%, 80px);
  }

  .skill-item {
    cursor: initial;
    align-items: center;
    padding: 0;
    max-width: 560px;
    margin: auto;
  }

  .skill-item p {
    margin-bottom: 1rem;
    text-align: left;
  }

  .hero h1 {
    font-size: 3.25rem;
  }
}

@media screen and (max-width: 1023px) {
  .case-item::before {
    opacity: 0.75;
  }

  .case-item > div {
    opacity: 1;
    transform: translateY(0);
  }

  .hero h1 {
    font-size: 3rem;
  }
}

@media screen and (max-width: 767px) {
  .contact .methods {
    flex-direction: column;
    text-align: center;
    gap: 0.75rem;
    font-size: 1rem;
  }

  .hero h1 {
    font-size: 1.75rem;
  }

  .hero .subtitle {
    font-size: 1.125rem;
    text-wrap: balance;
  }

  .case-item article {
    padding: 0 0 1.25rem 1.5rem;
  }

  .case-item h3 {
    font-size: 1.125rem;
    margin-bottom: 0.125rem;
  }

  .case-item p {
    font-size: 1rem;
  }

  .case-item > div {
    padding: 0 1rem 1.25rem 1.5rem;
  }

  .case-list {
    gap: 2rem;
  }

  .expertise .title,
  .contact .title {
    font-size: 1.75rem;
    text-wrap: balance;
  }

  .expertise .subtitle {
    font-size: 1.125rem;
    text-wrap: balance;
    margin-bottom: 3rem;
  }

  .main-nav {
    gap: 1rem;
  }

  .logo {
    max-width: 2.5rem;
  }

  .button:hover {
    background-color: var(--primary);
  }

  .skill-item h3 {
    margin-bottom: 0.75rem;
  }

  footer .logo {
    max-width: 2rem;
  }

  .companies h2 {
    margin-bottom: 1.5rem;
  }
}
