*,
*::before,
*::after { box-sizing: border-box; }
main {
  flex: 1;
  width: 90%;
  margin: 6rem auto;
  font-family: 'Segoe UI', sans-serif;
  color: #000000;
}

/* titlul și butonul înapoi */
.project-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: 3rem;
}

.project-header h1 {
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  margin: 0;
}

.back-btn {
  background: #A6CFD5;
  color: black;
  border: none;
  padding: 0.7rem 1.5rem;
  font-size: 1rem;
  border-radius: 4px;
  cursor: pointer;
  transition: background 0.2s ease;
}
.back-btn:hover {
  background: #91b8be;
}

/* layout principal (2 coloane) */
.project-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: start;
}
.project-text {
  height: fit-content;
  text-align: right;
}
/* partea stângă: imagini */
.project-images {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}
.project-images img {
  width: 100%;
  border-radius: 8px;
  object-fit: cover;
  box-shadow: 0 4px 10px rgba(0,0,0,0.15);
}

/* partea dreaptă: text */
.project-text h2 {
  margin-top: 0;
  font-size: 1.5rem;
}
.project-text p, .project-text li {
  line-height: 1.6;
}
.project-text ul {
  padding-left: 1.2rem;
}

.project-text { position: relative; }
.project-text .aliniat {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  
}
.mobile-aliniat {
  display: none;
}
html {
  scroll-behavior: smooth;
}
/* hidden by default */
.begin-mobile { display: none; }

/* on mobile: show the cloned title before images, hide the original in text column */
@media (max-width: 900px) {
  .begin-mobile {
    display: block;
    font-size: 1.1rem;          /* tweak as you like */
    line-height: 1.4;
    margin: 0 0 1rem 0;
    text-align: left;           /* or center */
  }
  .project-text h3#begin {
    display: none;
  }
}


/* responsive: pe mobile devine vertical */
@media (max-width: 900px) {
  .project-content {
    grid-template-columns: 1fr;
  }
.project-text {
    order: 2;
    text-align: center;
  }
  .project-images {
    order: 1;
  }
  
  .project-header {
    flex-direction: column-reverse;
    gap: 3rem;
  }
  .project-images {
    flex-direction: column;
    align-items: center;
  }
  .project-images img {
    width: 90%;
  }
  .back-btn
  {
    padding: 0.7rem 1.3rem;
    font-size: 0.8rem;
  }
    .project-text {
    position: static;
    text-align: left;
  }

  .project-text .aliniat {
    display: none;
  }

  /* și afișăm textul pus sub imagine */
  .mobile-aliniat {
    display: block;
    width: 90%;
    margin: 0.5rem auto 1.5rem;
    font-size: 0.9rem;
    line-height: 1.5;
    text-align: center; /* sau center dacă vrei */

  }
  p 
  {
    font-size: 0.9rem;
  }

}
