/* ===================================================== */
/* BASE PROJECTE                                         */
/* ===================================================== */

body.projecte {
  line-height: 1.7;
  color: #e6e6e6;
}

/* Fons fix */
body.projecte #fons-fixe {
  position: fixed;
  inset: 0;
  background: url("../img/FonsCards.jpg") center/cover no-repeat;
  z-index: -1;
}

/* ✅ BLOQUEIG TOTAL DEL TALL LATERAL EN MÒBIL */
html, body {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
}
/* ===================================================== */
/* CONTENIDOR GENERAL                                    */
/* ===================================================== */

.contenidor-centre {
  display: flex;
  justify-content: center;
  width: 100%;
  padding: 0 10px;
  box-sizing: border-box;
}

/* ===================================================== */
/* CAPSA LILA                                            */
/* ===================================================== */

.CapsaLila {
  width: 100%;
  max-width: 400px;
  margin: 0px auto 80px;
  padding: 30px 22px;

  background: rgba(66, 65, 109, 0.70);
  border-radius: 22px;
  overflow: hidden;                 /* CLAU pel radius */
  overflow: hidden;

  box-shadow: 0 12px 30px rgba(0,0,0,0.35);
  box-sizing: border-box;
  text-align: center;
}


/* ===================================================== */
/* IMATGES                                               */
/* ===================================================== */

.zhi {
  width: 120px;
  height: 120px;
  border-radius: 20%;
  display: block;
  margin: 20px auto;
  object-fit: cover;
}

.caixes {
  width: 100%;
  display: block;
  padding-top: 20px;
  margin: 20px auto;
  object-fit: cover;
}

.drac {
  width: 250px;
  height: auto;
  display: block;
  margin: 30px auto 0;
}

/* ===================================================== */
/* TITOLS I TEXT                                         */
/* ===================================================== */

.CapsaLila h2,
.CapsaLila h3,
.CapsaLila h4 {
  color: #fff;
  font-weight: 600;
  margin: 25px 0 10px;
  opacity: 0.7 ;
}

.CapsaLila p {
  color: #e6e6e6;
  font-size: 1em;
  margin-bottom: 18px;
  text-align: left;
  line-height: inherit;
  letter-spacing: 0.3px;
  opacity: 0.7;
}

/* ===================================================== */
/* BLOCS DE TEXT (READ MORE)                              */
/* ===================================================== */

.bloc-text {
  max-width: 720px;
  margin: 25px auto;
  padding: 26px 24px;

  background: rgba(66, 65, 109, 0.78);
  border-radius: 22px;

  box-shadow: 0 10px 24px rgba(0,0,0,0.15);
}

.text-llegible {
  position: relative;
  overflow: hidden;
  max-height: none;              /* ← OBERT per defecte */
}

.text-llegible.colapsat {
  max-height: 200px;             /* ← NOMÉS quan està tancat */
  transition: max-height .45s ease;
}
/* Estat colapsat */
.text-llegible.colapsat::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 70px;

  background: linear-gradient(
    to bottom,
    rgba(66,65,109,0),
    rgba(66,65,109,1)
);

  pointer-events: none;
}

.tancament {
  margin-top: 2em;
  font-style: italic;
}

/* Botó read more */
.btn-llegir {
  margin-top: 12px;
  background: none;
  border: none;
  color: #e6e6e6;
  font-weight: 600;
  cursor: pointer;
  letter-spacing: 0.6px;
  transition: transform 0.15s ease, opacity 0.15s ease;
}

.btn-llegir:hover {
  transform: scale(1.05);
  opacity: 0.85;
}

.text-llegible p {
  text-align: justify;
  hyphens: auto;
  line-height: 1.75;
  letter-spacing: 0.02em;
  margin-bottom: 1em;
}
/* ===================================================== */
/* HR                                                    */
/* ===================================================== */

hr {
  border: 0;
  border-top: 1px solid rgba(82, 85, 137, 0.92);
  margin: 18px 0;
}

/* ===================================================== */
/* BOTÓ DONACIÓ                                         */
/* ===================================================== */

.btnDonacio {
  display: block;
  width: 160px;
  margin: 25px auto;
  padding: 12px 0;

  background: linear-gradient(145deg, #d4af37, #f9e79f);
  color: #000;
  text-align: center;
  text-decoration: none;
  font-weight: bold;

  border-radius: 30px;

  box-shadow:
    0 8px 16px rgba(0,0,0,0.35),
    0 0 12px rgba(255,215,0,0.6);
}

/* ===================================================== */
/* XARXES                                                */
/* ===================================================== */

.xarxes {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  margin: 25px 0;

}

.xarxes img {
  width: 70px;
  height: 70px;
  display: block;
  object-fit: contain;
  opacity: 0.65;
  transition: opacity 0.2s ease, transform 0.2s ease;
  margin-left: 60px;
  margin-right: 60px;
  margin-top: 20px;
}

.xarxes img:hover {
  opacity: 1;
  transform: scale(1.05);
}
/* ============================= */
/* VIDEO RESPONSIVE              */
/* ============================= */

/* ============================= */
/* VIDEO RESPONSIVE – GLOBAL     */
/* ============================= */

.video-wrap {
  width: 100%;
  max-width: 100%;

  aspect-ratio: 17 / 8.9;   /* cinematogràfic */
  margin: 20px auto;

  border-radius: 18px;
  overflow: hidden;         /* 🔑 imprescindible */

  background: #000;
}

.video-wrap iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

.video-wrap {
  aspect-ratio: 17 / 8.9;
}



/* ===================================================== */
/* RESPONSIVE                                            */
/* ===================================================== */

@media (max-width: 400px) {
  .CapsaLila {
    padding: 24px 18px;
  }

  .xarxes img {
    width: 56px;
    height: 56px;
  }
}
