/* ===================================
   Module – Alla projekt (Isotope masonry + lazy batches)
=================================== */

.m-alla-projekt{
  padding: var(--space-xl) 0;
}

.m-alla-projekt__heading {
    margin: 0 0 var(--space-sm);
    font-family: var(--font-heading);
    font-size: var(--fs-h2);
    color: var(--c-gran);
    padding: 35px 0;
}

/* Filters */
.m-alla-projekt__filters {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
    position: relative;
    z-index: 10;
    padding-bottom: 35px;
}

.m-alla-projekt__filter {
    padding: 10px 18px;
    border: 0;
    border-radius: 6px;
    cursor: pointer;
    background: transparent;
    color: var(--c-gran);
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 16px;
    line-height: 1;
    transition: background-color .18s ease, color .18s ease, opacity .18s ease;
    text-transform: uppercase;
    letter-spacing: .05em;
}

.m-alla-projekt__filter.is-checked{
  background: var(--c-bjork);
  color: #fff;
}


.m-alla-projekt__filter:focus-visible{
  outline: 2px solid var(--c-gran);
  outline-offset: 4px;
}

/* Isotope grid */
.m-alla-projekt__grid {
    --gap: clamp(20px, 3vw, 50px);
    position: relative;
    margin-bottom: 50px;
}

.m-alla-projekt__sizer{
  width: calc((100% - (var(--gap) * 2)) / 3);
}

.m-alla-projekt__gutter{
  width: var(--gap);
}

.m-alla-projekt__item{
  width: calc((100% - (var(--gap) * 2)) / 3);
  margin-bottom: var(--gap);
}

.m-alla-projekt__item > .m-projektkort__card{
  width: 100%;
}


/* 2 col */
@media (max-width: 1290px){
  .m-alla-projekt__sizer{
    width: calc((100% - var(--gap)) / 2);
  }
  .m-alla-projekt__item{
    width: calc((100% - var(--gap)) / 2);
  }
}

/* 1 col */
@media (max-width: 900px){
  .m-alla-projekt__sizer{ width: 100%; }
  .m-alla-projekt__item{ width: 100%; }
}

/* -----------------------------------
   “Ladda fler”
----------------------------------- */
.m-alla-projekt__more {
    margin-top: var(--space-lg);
    display: flex;
    justify-content: center;
    padding-bottom: 100px;
}

.m-alla-projekt__more-btn {
    appearance: none;
    border: 0;
    cursor: pointer;
    background: var(--c-gran);
    color: #fff;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: clamp(18px, 3.5vw, 23px);
    line-height: 1;
    padding: 14px 22px;
    border-radius: 6px;
    transition: transform .15s ease, opacity .15s ease;
    letter-spacing: 0.03em;
}

.m-alla-projekt__more-btn:hover {
    background: var(--c-bjork);
    color: #fff;
}

.m-alla-projekt__more-btn:active{
  transform: translateY(0);
}

.m-alla-projekt__more-btn:focus-visible{
  outline: 2px solid var(--c-gran);
  outline-offset: 4px;
}

/* När inget mer finns */
.m-alla-projekt__more.is-hidden{
  display: none;
}

.m-alla-projekt__item.is-lazy-hidden{
  display: none;
}