@charset "UTF-8";

/* ===== Works Filter ===== */
.works-filter {
  padding: 32px 0 24px;
  background: #fff;  
  border-radius: 16px;  
  width: 80%; 
  margin: 0 auto  ;
}

.works-filter__label {
  font-size: 1.8rem;
  font-weight: 700;
  color: #372929;
  letter-spacing: 0.08em;
  margin-bottom: 18px;
  border-radius: 16px;
}

.works-filter__form {
  max-width: 1300px;      /* ← 範囲（幅制限） */
  margin: 0 auto;         /* ← 中央寄せ */
  background-color: #fff;
}

.works-filter__tabs {
  display: grid;
  grid-template-columns: repeat(4, 30fr); /* ← 修正 */
  gap: 130px;
}

.works-filter__dropdown-btn {
  min-width: 100px;
  min-height: 42px;
  background: linear-gradient(135deg, #0b7b6d 0%, #06675b 100%);
  color: #fff;
  border: none;
  padding: 8px 14px;
  font-family: inherit;
  font-size: 1.4rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  transition: opacity 0.2s, transform 0.2s;
}

.works-filter__dropdown-btn:hover {
  opacity: 0.92;
}

.works-filter__dropdown-btn--open {
  transform: translateY(-1px);
}

.works-filter__dropdown-label {
  width: 100%;
  text-align: center;
  font-size: 1.8rem;
  font-weight: 550;
  letter-spacing: 0.28em;
}

.works-filter__dropdown-arrow {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  transition: transform 0.2s;
}

.works-filter__dropdown-btn--open .works-filter__dropdown-arrow {
  transform: rotate(180deg);
}

.works-filter__panels {
  margin-top: -1px;
  border-radius: 0 0 12px 12px;
}

.works-filter__dropdown-panel {
  background: #fff;
  border: 1.6px solid #333;
  padding: 10px 18px;
  min-height: 40px;
  width: 100%;
  display: flex;
  align-items: center;
}

.works-filter__dropdown-panel[hidden] {
  display: none;
}

.works-filter__panel-content {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 45px;
}

.works-filter__empty {
  font-size: 1.4rem;
  color: #777;
  letter-spacing: 0.05em;
}

.works-filter__check {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 1.8rem;
  color: #333;
  cursor: pointer;
  letter-spacing: 0.09em;
  line-height: 1.6;
}

  .works-filter__check input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  width: 16px;
  height: 16px;
  border: 2px solid #7a7a7a;
  background: #fff;
  cursor: pointer;
  position: relative;
  border-radius: 4.5px;  
}

.works-filter__check input[type="checkbox"]:checked {
  background: #aae72b;
}

.works-filter__check input[type="checkbox"]:checked::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 5px;
  width: 4px;
  height: 8px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.works-filter__actions {
  display: flex;
  justify-content: flex-end;
  padding-top: 14px;
}

.works-filter__search-btn {
  background: #DEEDCD;
  color: #0b7b6d;
  border: none;
  min-width: 190px;
  padding: 8px 28px;
  font-family: inherit;
  font-size: 1.8rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  cursor: pointer;
  transition: opacity 0.2s, transform 0.2s;
}

.works-filter__search-btn:hover {
  opacity: 0.85;
  transform: translateY(-1px);
}

/* ===== Works Archive Grid ===== */
.works-archive {
  padding: 40px 0 80px;
}
.works-archive__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px 20px;
  margin-bottom: 60px;
}
[data-filter-item][hidden] {
  display: none !important;
}
.works-archive__none {
  text-align: center;
  font-size: 1.6rem;
  color: #777;
  padding: 60px 0;
}

/* --- Works Card --- */
.works-card__link {
  display: flex;
  flex-direction: column;
  gap: 0;
  color: inherit;
  text-decoration: none;
  transition: opacity 0.2s;
}
.works-card__link:hover {
  opacity: 0.8;
}
.works-card__img-after {
  width: 100%;
  aspect-ratio: 1 / 1;
  background: #C7C7C7;
  overflow: hidden;
  margin-bottom: 8px;
}
.works-card__img-after img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.works-card__info {
  display: flex;
  align-items: flex-start;
  gap: 15px;
  align-items: center;
}
.works-card__img-before {
  width: 80px;
  height: 80px;
  flex-shrink: 0;
  background: #C7C7C7;
  overflow: hidden;
  margin-top: 10px;
}
.works-card__img-before img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.works-card__meta {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.works-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}
.works-card__tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 1.2rem;
  font-weight: 400;
  letter-spacing: 0.18;
  line-height: 1.2;
  color: #3b3b3b;
}

.works-card__tag .works-card__tag-icon {
  display: inline-block;
  width: 14px;
  height: 14px;
  background-image: url("../images/mark-icon.png");
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
}

.works-card__location,
.works-card__customer {
  font-size: 1.3rem;
  color: #333;
  letter-spacing: 0.03em;
  line-height: 1.5;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-weight: 500;
}

/* ===== Pagination ===== */
.works-archive__pagination {
  display: flex;
  justify-content: center;
  margin-top: 40px;
  margin-bottom: 16px;
}
.works-archive__pagination-nav {
  display: flex;
  align-items: center;
  gap: 18px;
}
.works-archive__pagination-number,
.works-archive__pagination-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  background: transparent;
  font-family: inherit;
  cursor: pointer;
  transition: opacity 0.15s, transform 0.15s, background-color 0.15s, color 0.15s;
  padding: 0;
  line-height: 1;
}
.works-archive__pagination-number {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: #e0e0e0;
  font-size: 2.2rem;
  font-weight: 400;
  color: #555;
  letter-spacing: 0;
}
.works-archive__pagination-number:not([disabled]):hover {
  background: #d0d0d0;
}
.works-archive__pagination-number.is-active {
  background: #00b8cc;
  color: #fff;
  font-weight: 600;
}
.works-archive__pagination-arrow {
  width: 50px;
  height: 50px;
  border: 1.5px solid #ccc;
  background: #fff;
  font-size: 2.0rem;
  color: #555;
  border-radius: 4px;
}
.works-archive__pagination-arrow:not([disabled]):hover {
  border-color: #aaa;
  color: #333;
}
.works-archive__pagination-arrow[disabled],
.works-archive__pagination-number[disabled] {
  opacity: 0.35;
  cursor: default;
}

@media (max-width: 1024px) {
  .works-filter__tabs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
  }

  .works-archive__grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 767px) {
  .works-filter {
    padding: 24px 0 18px;
  }

  .works-filter__label {
    font-size: 1.6rem;
    margin-bottom: 14px;
  }

  .works-filter__tabs {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .works-filter__panels {
    display: none;
  }

  .works-filter__dropdown-btn {
    min-height: 58px;
    padding: 16px 18px;
    font-size: 1.6rem;
  }

  .works-filter__tabs .works-filter__dropdown-panel {
    margin-top: -12px;
    padding: 16px;
    min-height: 60px;
    border-top: none;
  }

  .works-filter__dropdown-panel {
    padding: 16px;
    min-height: 60px;
  }

  .works-filter__panel-content {
    gap: 12px 18px;
  }

  .works-filter__check {
    font-size: 1.5rem;
  }

  .works-filter__actions {
    padding-top: 12px;
  }

  .works-filter__search-btn {
    width: 100%;
    min-width: 0;
  }

  .works-archive {
    padding: 32px 0 60px;
  }

  .works-archive__grid {
    grid-template-columns: repeat(1, minmax(0, 1fr));
    gap: 18px 10px;
    margin-bottom: 40px;
  }

  .works-archive__pagination-nav {
    gap: 10px;
  }

  .works-archive__pagination-number {
    width: 48px;
    height: 48px;
    font-size: 1.8rem;
  }

  .works-archive__pagination-arrow {
    width: 40px;
    height: 40px;
    font-size: 1.6rem;
  }

  .works-card__img-after {
    margin-bottom: 6px;
    width: 70%;
    aspect-ratio: 1 / 1;
    margin: 0 auto;
  }

  .works-card__info {
    gap: 6px;
  }

  .works-card__img-before {
    width: 60px;
    height: 60px;
    margin-left:50px;
  }

  .works-card__meta {
    gap: 2px;
  }

  .works-card__tags {
    gap: 4px;
  }

  .works-card__tag {
    gap: 2px;
    font-size: 0.9rem;
  }

  .works-card__tag-icon {
    width: 10px;
    height: 10px;
    background-size: 10px 10px;
  }

  .works-card__location,
  .works-card__customer {
    font-size: 1rem;
    line-height: 1.35;
    white-space: normal;
    overflow: hidden;
    text-overflow: initial;
    word-break: break-word;
  }
}
