/* RESET BÀSIC */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* TIPOGRAFIA GLOBAL */
body {
  font-family: "Roboto", sans-serif;
  color: #000;
}

/* =========================
TOPBAR
========================= */

.topbar-ajuntament {
  width: 100%;
  background-color: #ffffff;
  border-bottom: 1px solid #e6e6e6;
}

.topbar-ajuntament__inner {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
  padding: 14px 20px;
}

/* Logo centrat real */
.topbar-ajuntament__logo {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}

.topbar-ajuntament__logo img {
  height: 44px;
  display: block;
  margin-top: -13px;
}

/* Idiomes a la dreta */
.topbar-ajuntament__lang {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 6px;
  font-size: 14px;
}

.topbar-ajuntament__lang a {
  text-decoration: none;
  color: #000;
  opacity: 0.5;
  font-weight: 400;
  transition: opacity 0.2s ease;
}

.topbar-ajuntament__lang a:hover {
  opacity: 0.8;
}

.topbar-ajuntament__lang a.is-active {
  opacity: 1;
  font-weight: 500;
}

.topbar-ajuntament__lang span {
  opacity: 0.4;
}

/* =========================
HERO
========================= */

.hero-ajuntament {
  position: relative;
  width: 100%;
  height: 90vh;
  min-height: 500px;
  overflow: hidden;
}

/* Video fons */
.hero-ajuntament__video {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: translate(-50%, -50%);
}

/* Overlay fosc */
.hero-ajuntament__overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;

  /* degradat focalitzat a baix */
  background: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0) 0%,
    rgba(0, 0, 0, 0.2) 50%,
    rgba(0, 0, 0, 0.55) 100%
  );

  z-index: 1;
}

/* Text */
.hero-ajuntament__text {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;

  width: 100%;
  max-width: 1000px;
  padding: 0 20px;

  text-align: center;
  color: #fff;
}

/* Kicker */
.hero-ajuntament__kicker {
  font-size: 18px;
  letter-spacing: 1px;
  font-weight: 500;
  margin-bottom: 10px;
}

/* Títol */
.hero-ajuntament__title {
  font-size: 50px;
  line-height: 1.2;
  font-weight: 700;
}

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

@media (max-width: 1024px) {
  .hero-ajuntament__title {
    font-size: 34px;
  }
}

@media (max-width: 768px) {
  .topbar-ajuntament__inner {
    padding: 12px 16px;
  }

  .topbar-ajuntament__logo img {
    height: 40px;
  }

  .hero-ajuntament {
    height: 80vh;
  }

  .hero-ajuntament__text {
    bottom: 30px;
  }

  .hero-ajuntament__title {
    font-size: 26px;
  }

  .hero-ajuntament__kicker {
    font-size: 18px;
  }
}

@media (max-width: 480px) {
  .hero-ajuntament {
    height: 75vh;
  }

  .hero-ajuntament__title {
    font-size: 34px;
  }
}

/* =========================
INTRO EDITORIAL
========================= */

.intro-ajuntament {
  padding: 30px 20px;
  background-color: #ffffff;
}

.intro-ajuntament__inner {
  max-width: 800px;
  margin: 0 auto;
}

/* Titular */
.intro-ajuntament__headline {
  font-size: 28px;
  line-height: 1.3;
  font-weight: 300;
  margin-bottom: 30px;
  margin-top: 20px;
}

/* Meta (autor + data) */
.intro-ajuntament__meta {
  margin-bottom: 25px;
}

.intro-ajuntament__author {
  display: block;
  font-weight: 500;
  margin-bottom: 4px;
}

.intro-ajuntament__date {
  font-size: 14px;
  opacity: 0.6;
}

/* Cos de text */
.intro-ajuntament__content p {
  font-size: 18px;
  line-height: 1.7;
  margin-bottom: 20px;
  color: #111;
}

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

@media (max-width: 768px) {
  .intro-ajuntament {
    padding: 50px 16px;
  }

  .intro-ajuntament__headline {
    font-size: 22px;
  }

  .intro-ajuntament__content p {
    font-size: 18px;
  }
  .promo-card {
    display: grid;
    grid-template-columns: inherit !important;
    cursor: pointer;
    max-width: 360px;
    margin: auto;
  }
}

/* =========================
PROMO BANNER
========================= */

.promo {
  padding: 30px 0;
}

.promo-card {
  display: grid;

  grid-template-columns: 1fr 1fr;

  cursor: pointer;

  max-width: 900px;

  margin: auto;
}

.promo-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.promo-content {
  background: #dfdad9;

  display: flex;

  flex-direction: column;

  justify-content: center;

  align-items: center;

  text-align: center;

  padding: 40px;
}

.promo-content h3 {
  color: #cf122b;

  font-size: 32px;

  line-height: 1.3;

  margin-bottom: 30px;
}

/* CTA */

.promo-btn {
  display: flex;

  align-items: center;

  gap: 12px;

  background: #cf122b;

  color: white;

  border: none;

  padding: 12px 24px;

  border-radius: 30px;

  font-weight: 700;

  cursor: pointer;
}

.promo-arrow {
  background: #96121c;

  padding: 8px 12px;

  border-radius: 20px;
}
/* =========================
MODAL GREEN
========================= */

.modal-green {
  position: fixed;
  inset: 0;
  display: none;
  z-index: 999;
}

.modal-green.is-open {
  display: block;
}

.modal__overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
}

/* contenidor modal */

.modal__dialog {
  position: relative;

  width: min(920px, calc(100% - 40px));

  margin: 40px auto;

  background: #dfdad9;

  max-height: 90vh;

  display: flex;

  flex-direction: column;

  overflow: hidden;
}

/* botó tancar */

.modal-close {
  position: absolute;

  top: 5px;
  right: 5px;

  width: 44px;
  height: 44px;

  border-radius: 50%;

  background: #cf122b;

  color: white;

  border: none;

  font-size: 22px;

  cursor: pointer;
}

/* imatge fixa */

.modal-image {
  width: 100%;

  display: block;

  flex-shrink: 0;
}

/* text scroll */

.modal-text {
  flex: 1;

  overflow-y: auto;

  padding: 40px;

  font-size: 20px;

  line-height: 1.7;
}

/* mòbil */

@media (max-width: 700px) {
  .modal__dialog {
    margin: 20px auto;
  }

  .modal-text {
    padding: 24px;
    font-size: 18px;
  }
}

/* =========================
MODEL MEDITERRANI
========================= */

.model-ajuntament {
  padding: 40px 20px;
  background: #ffffff;
}

.model-ajuntament__inner {
  max-width: 800px;
  margin: 0 auto;

  display: grid;
  grid-template-columns: 3fr 1fr;
  gap: 60px;

  align-items: center; /* 👈 clau */
}

/* text */
.model-ajuntament__title {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 20px;
}

.model-ajuntament__content p {
  font-size: 18px;
  line-height: 1.7;
  margin-bottom: 20px;
}

/* destacat */
.model-ajuntament__highlight {
  display: flex;
  align-items: flex-start;
}

.model-ajuntament__highlight-inner {
  border-top: 3px solid #c8102e;
  padding-top: 20px;
}

.model-ajuntament__highlight-inner p {
  font-size: 22px;
  font-weight: 700;
  line-height: 1.4;
}

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

@media (max-width: 768px) {
  .model-ajuntament__inner {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .model-ajuntament__highlight-inner p {
    font-size: 22px;
  }
}

/* =========================
10 RAONS
========================= */

.reasons-ajuntament {
  padding: 40px 20px;
  background: #ffffff;
}

.reasons-ajuntament__inner {
  max-width: 1000px;
  margin: 0 auto;
}

.reasons-ajuntament__title {
  text-align: center;
  font-size: 26px;
  font-weight: 700;
  margin-bottom: 50px;
}

/* grid 2 columnes */
.reasons-ajuntament__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 30px 40px;
}

/* item */
.reasons-ajuntament__item {
  display: flex;
  align-items: center;

  opacity: 0;
  transform: translateY(30px);
  transition: all 0.6s ease;
}

/* visible (scroll) */
.reasons-ajuntament__item.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* cercle */
.reasons-ajuntament__circle {
  min-width: 80px;
  height: 80px;
  border-radius: 50%;
  box-shadow: 5px 5px 10px #3d3c3c;

  background: #c8102e;
  color: #fff;

  display: flex;
  align-items: center;
  justify-content: center;

  font-weight: 700;
  font-size: 32px;

  margin-right: -20px;
  z-index: 2;
}

/* caixa */
.reasons-ajuntament__box {
  background: #e9e6e4;
  border-radius: 20px;
  padding: 20px 25px 20px 40px;
  flex: 1;
}

/* titol */
.reasons-ajuntament__box h3 {
  font-size: 22px;
  font-weight: 700;
  color: #c8102e;
  margin-bottom: 8px;
}

/* text */
.reasons-ajuntament__box p {
  font-size: 18px;
  line-height: 1.6;
}

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

@media (max-width: 768px) {
  .reasons-ajuntament__grid {
    grid-template-columns: 1fr;
  }

  .reasons-ajuntament__circle {
    min-width: 50px;
    height: 50px;
    font-size: 18px;
  }
}

/* =========================
SECTOR
========================= */

.sector-ajuntament {
  padding: 40px 20px;
  background: #ffffff;
}

.sector-ajuntament__inner {
  max-width: 900px;
  margin: 0 auto;
}

/* text */
.sector-ajuntament__title {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 20px;
}

.sector-ajuntament__content p {
  font-size: 18px;
  line-height: 1.7;
  margin-bottom: 20px;
}

/* imatge */
.sector-ajuntament__media {
  margin-top: 40px;
}

.sector-ajuntament__media img {
  width: 100%;
  display: block;
}

/* credit */
.sector-ajuntament__credit {
  display: block;
  font-size: 16px;
  margin-top: 8px;
  opacity: 0.6;
}

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

@media (max-width: 768px) {
  .sector-ajuntament {
    padding: 60px 16px;
  }

  .sector-ajuntament__title {
    font-size: 20px;
  }
}

/* =========================
ESTRATEGIA
========================= */

.estrategia-ajuntament {
  padding: 40px 20px;
  background: #ffffff;
}

.estrategia-ajuntament__inner {
  max-width: 800px;
  margin: 0 auto;

  display: grid;
  grid-template-columns: 1fr 3fr;
  gap: 60px;

  align-items: center; /* centrat vertical */
}

/* destacat */
.estrategia-ajuntament__highlight-inner {
  border-top: 3px solid #c8102e;
  padding-top: 20px;
}

.estrategia-ajuntament__highlight-inner p {
  font-size: 22px;
  font-weight: 700;
  line-height: 1.4;
}

/* text */
.estrategia-ajuntament__title {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 20px;
}

.estrategia-ajuntament__content p {
  font-size: 18px;
  line-height: 1.7;
  margin-bottom: 20px;
}

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

@media (max-width: 768px) {
  .estrategia-ajuntament__inner {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .estrategia-ajuntament__highlight-inner p {
    font-size: 22px;
  }
}

/* =========================
IMATGE FULL WIDTH
========================= */

.media-full-ajuntament {
  width: 100%;
  background: #e9e6e4;
}

.media-full-ajuntament img {
  width: 100%;
  height: auto;
  display: block;
}

/* =========================
FONS GRIS + CONTINGUT
========================= */

.content-grey-ajuntament {
  background: #e9e6e4;
  padding: 60px 20px;
}

.content-grey-ajuntament__inner {
  max-width: 800px;
  margin: 0 auto;
}

/* titol */
.content-grey-ajuntament__title {
  font-size: 31px;
  font-weight: 700;
  color: #c8102e;
  margin-bottom: 25px;
}

/* text */
.content-grey-ajuntament__text p {
  font-size: 18px;
  line-height: 1.7;
  margin-bottom: 20px;
}

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

@media (max-width: 768px) {
  .content-grey-ajuntament {
    padding: 40px 16px;
  }

  .content-grey-ajuntament__title {
    font-size: 26px;
  }
}

/* =========================
CONTINUACIÓ FONS GRIS
========================= */

.content-grey-ajuntament__media {
  margin-top: 60px;
  margin-bottom: 40px;
}

.content-grey-ajuntament__media img {
  width: 100%;
  display: block;
}

/* credit */
.content-grey-ajuntament__credit {
  display: block;
  font-size: 16px;
  margin-top: 8px;
  opacity: 0.6;
}

/* subtítol */
.content-grey-ajuntament__subtitle {
  font-size: 24px;
  font-weight: 700;
  margin: 30px 0 15px;
}

/* =========================
CREDITS FINAL
========================= */

.credits-ajuntament {
  background: #ffffff;
  padding: 40px 20px;
}

.credits-ajuntament__inner {
  max-width: 900px;
  margin: 0 auto;
  text-align: center;
}

.credits-ajuntament__line {
  font-size: 16px;
  line-height: 1.6;
  margin-bottom: 10px;
}

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

@media (max-width: 768px) {
  .credits-ajuntament {
    padding: 30px 16px;
  }

  .credits-ajuntament__line {
    font-size: 13px;
  }
}

/* peu foto */
.media-full-ajuntament__caption {
  display: block;
  max-width: 800px;
  margin: 8px auto 0;

  padding: 0 20px;

  font-size: 16px;
  line-height: 1.4;
  opacity: 0.6;
}
