/************************ MAIN ***********************/

#main .welcome,

.intro,

#portfolio,

#contact {
  animation: Bdanim 1s cubic-bezier(0.4, 0, 0.2, 1) 0.2s forwards;
}

#main {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  min-height: 100dvh;
  text-align: center;
}

#main img {
  position: absolute;
  opacity: 0.1;
  mix-blend-mode: luminosity;
  object-fit: cover;
  width: 100%;
  height: 100%;
  z-index: -1;
  object-position: 50% 50%;
  top:0;
}

#main .welcome {
  display: flex;
  flex-direction: column;
  justify-content: center;
  margin: 0 var(--large-margin);
  position: absolute;
  align-items: flex-start;
  text-align: left;
  gap: 1.5rem;
  max-width: 1300px;
}

.intro {
  display: flex;
  align-items: center;
  flex-direction: column;
  gap: 3.5rem;
  text-align: center;
}


/********************** LAST PROJECTS ***********************/


#portfolio {
  padding: 6rem var(--large-margin);
}

#portfolio h2 {
  text-align: center;
}

.grid {
  margin-top: 1.5rem;
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

.grid-item {
  display: flex;
  justify-content: center;
  align-items: stretch;
  flex-direction: column;
  position: relative;
  padding: 1px;
  border-radius: 1.4rem;
  overflow: hidden;
  background-color: rgba(128, 128, 128, 0.1);
  transition: transform 0.5s ease-out;
}

@media (pointer: fine) {
  .grid-item:hover > .glow-section__top-layer {
    background: rgb(25, 25, 29, 0.85);
  }
}


.grid-item:hover img {
  transform: scale(1.0);
}

.image-wrapper {
  overflow: hidden;
  width: 100%;
  height: 250px;
  border-radius: 12px;
}

.grid-item img {
  width: 100%;
  height: 250px;
  object-fit: cover;
  object-position: center;
  display: block;
  border-radius: 12px;
  margin-bottom: 1rem;
  overflow: hidden;
  transition: transform 0.4s ease;
  transform: scale(1.05);
}

.glow-section__top-layer {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  height: 100%;
  background-color: var(--color-bg-secondary);
  transition: background-color 0.3s ease-out;
  padding: 1.2rem;
  gap: 1.2rem;
  border-radius: 1.4rem;
}

.glow-section__blob {
  position: absolute;
  z-index: -1;
  top: 0;
  left: 0;
  width: 200px;
  height: 200px;
  border-radius: 100%;
  filter: blur(40px);
  opacity: 0;
}

.glow-section__blob--1 {
  background: rgb(255,255,255,0.8);
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}


/************************ CONTACT ************************/


#contact {
  padding: 6rem var(--large-margin);
}

.contact-banner {
  justify-content: space-between;
  align-items: center;
  background: linear-gradient(120deg, var(--color-button-primary-bg) -200%, var(--color-bg-secondary) 35%, var(--color-bg-secondary)55%, var(--color-button-primary-bg) 140%);
  padding: 2rem;
  border-radius: 1rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.contact-left {
  display: flex;
  flex-direction: column;
  text-align: center;
  align-items: center;
  gap: 1rem;
}

.contact-left h2 {
  color: var(--color-text-primary);
  margin-bottom: 2rem;
}

.contact-left p {
  font-size: 1.1rem;
}