@charset "utf-8";

.works-page {
  min-width: 320px;
  background: #fff;
}

.works-page header #wrap-header {
  height: 80px;
}

.works-page header h1 {
  height: 80px;
}

.works-page header h1 a {
  display: flex;
  height: 80px;
  align-items: center;
}

.works-page header h1 img {
  top: 0;
  width: 422px;
  height: 18px;
  padding: 0;
}

.works-page .hbgbtn {
  border: 0;
  background: transparent;
  padding: 0;
}

.works-main {
  padding-top: 80px;
}

.works-section {
  box-sizing: border-box;
  padding: 80px 80px 120px;
}

.works-section h2 {
  margin-bottom: 80px;
}

.works-filters {
  display: flex;
  flex-direction: column;
  gap: 40px;
  margin-bottom: 80px;
}

.works-category-filter,
.works-tag-filter {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
}

.works-category-filter {
  gap: 20px;
}

.works-tag-filter {
  gap: 0 20px;
  max-width: 1060px;
}

.works-filter-button {
  appearance: none;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  cursor: pointer;
  transition: background-color 0.3s, color 0.3s, opacity 0.3s;
}

.works-category-filter .works-filter-button {
  box-sizing: border-box;
  width: 180px;
  padding: 8px 20px;
  border: 1px solid #000;
  border-radius: 1000px;
  background: #fff;
  font-family: "Inter", sans-serif;
  font-size: 16px;
  font-weight: 700;
  line-height: 2;
  text-align: center;
}

.works-category-filter .works-filter-button.is-active {
  background: #000;
  color: #fff;
}

.works-category-filter .works-filter-button:not(.is-active):hover,
.works-category-filter .works-filter-button:not(.is-active):focus-visible {
  background: #000;
  color: #fff;
}

.works-category-filter .works-filter-button.is-active:hover,
.works-category-filter .works-filter-button.is-active:focus-visible {
  opacity: 0.65;
}

.works-tag-filter .works-filter-button {
  color: #666;
  font-family: "Noto Sans JP", sans-serif;
  font-size: 12px;
  line-height: 2;
}

.works-tag-filter .works-filter-button.is-active {
  color: #000;
  font-weight: 700;
}

.works-tag-filter .works-filter-button:hover,
.works-tag-filter .works-filter-button:focus-visible {
  color: #000;
}

.works-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 80px 40px;
}

.works-card {
  display: block;
  min-width: 0;
  color: inherit;
  cursor: pointer;
  opacity: 1;
  text-decoration: none;
  transition: opacity 0.36s ease;
}

.works-card:hover {
  opacity: 0.6;
}

.works-card.is-leaving {
  opacity: 0;
  pointer-events: none;
}

.works-card.is-entering {
  opacity: 0;
  pointer-events: none;
}

.works-card.is-entering.is-visible {
  opacity: 1;
  pointer-events: auto;
}

.works-card:focus-visible {
  outline: 2px solid #000;
  outline-offset: 4px;
}

.works-card .img {
  position: relative;
  aspect-ratio: 3 / 2;
  margin-bottom: 20px;
  overflow: hidden;
  background: #f3f3f3;
}

.works-card .img::before {
  content: "";
  position: absolute;
  z-index: 1;
  top: 50%;
  left: 50%;
  box-sizing: border-box;
  width: 28px;
  height: 28px;
  margin: -14px 0 0 -14px;
  border: 1.5px solid rgba(0, 0, 0, 0.14);
  border-top-color: #111;
  border-radius: 50%;
  opacity: 0;
  pointer-events: none;
}

.works-card .img.is-loading::before {
  opacity: 1;
  animation: workImageLoading 0.85s linear infinite;
}

.works-card .img.is-error::after {
  content: "IMAGE UNAVAILABLE";
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #888;
  font-family: "Inter", sans-serif;
  font-size: 10px;
  letter-spacing: 0.12em;
}

@keyframes workImageLoading {
  to { transform: rotate(360deg); }
}

.works-card .img img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.45s ease;
}

.works-card .img.is-loaded img {
  opacity: 1;
}

@media (prefers-reduced-motion: reduce) {
  .works-card .img.is-loading::before {
    animation: none;
  }

  .works-card .img img {
    transition: none;
  }
}

.works-card-body {
  padding: 0 10px;
}

.works-card .title {
  margin-bottom: 10px;
  font-size: 18px;
  font-weight: 700;
  line-height: 2;
}

.works-card .category {
  display: flex;
  flex-wrap: wrap;
  color: #999;
  line-height: 2;
}

.works-card .category li::before {
  content: "／";
  margin: 0 5px;
}

.works-card .category li:first-child::before {
  content: none;
}

.works-card .categorys {
  font-family: "Inter", sans-serif;
  font-size: 14px;
  font-weight: 700;
}

.works-card .tags {
  font-size: 12px;
}

.works-status {
  display: none;
  padding: 80px 0;
  color: #666;
  font-size: 14px;
  text-align: center;
}

.works-status.is-visible {
  display: block;
}

.work-detail-main {
  padding: 160px 80px 120px;
}

.work-detail {
  max-width: 1600px;
  margin: 0 auto;
}

.work-detail-back {
  display: inline-block;
  margin-bottom: 80px;
  color: #000;
  font-family: "Inter", sans-serif;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-decoration: none;
  transition: opacity 0.3s;
}

.work-detail-back:hover,
.work-detail-back:focus-visible {
  opacity: 0.5;
}

.work-detail-copy {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 40px;
  margin-bottom: 60px;
}

.work-detail-heading h2 {
  margin-bottom: 16px;
  font-size: 30px;
  font-weight: 700;
  line-height: 1.5;
}

.work-detail-copy .category {
  display: flex;
  flex-wrap: wrap;
  color: #999;
  line-height: 2;
}

.work-detail-copy .category li::before {
  content: "／";
  margin: 0 5px;
}

.work-detail-copy .category li:first-child::before {
  content: none;
}

.work-detail-copy .categorys {
  font-family: "Inter", sans-serif;
  font-size: 14px;
  font-weight: 700;
}

.work-detail-copy .tags {
  font-size: 12px;
}

.work-detail-inquiry-note {
  margin-top: 14px;
  color: #999;
  font-size: 10px;
  line-height: 1.8;
}

.work-detail-description {
  font-size: 16px;
  line-height: 2;
}

.work-detail-description.null {
  display: none;
}

.work-detail-images {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.work-detail-image {
  position: relative;
  overflow: hidden;
  background: #f3f3f3;
}

.work-detail-image::before {
  content: "";
  position: absolute;
  z-index: 1;
  top: 50%;
  left: 50%;
  width: 28px;
  height: 28px;
  margin: -14px 0 0 -14px;
  border: 1.5px solid rgba(0, 0, 0, 0.14);
  border-top-color: #111;
  border-radius: 50%;
  opacity: 0;
}

.work-detail-image.is-loading::before {
  opacity: 1;
  animation: workImageLoading 0.85s linear infinite;
}

.work-detail-image img {
  display: block;
  width: 100%;
  height: auto;
  opacity: 0;
  transition: opacity 0.45s ease;
}

.work-detail-image.is-loaded img {
  opacity: 1;
}

.work-detail-status {
  padding: 80px 0;
  color: #666;
  text-align: center;
}

@media (prefers-reduced-motion: reduce) {
  .works-card {
    transition: none;
  }
}

.works-page.modal-on {
  overflow: hidden;
}

@media screen and (max-width: 1024px) and (min-width: 768px) {
  .works-page header #wrap-header {
    height: auto;
  }

  .works-main {
    padding-top: 143px;
  }
}

@media screen and (max-width: 767px) {
  .works-page header,
  .works-page header #wrap-header {
    height: 70px;
  }

  .works-page header #wrap-header {
    box-sizing: border-box;
    padding: 0 20px;
    overflow: hidden;
  }

  .works-page header h1,
  .works-page header h1 a {
    height: 70px;
  }

  .works-page header h1 img {
    width: 305px;
    max-width: calc(100vw - 85px);
    height: auto;
  }

  .works-page header .hbgbtn {
    right: 10px;
  }

  .works-page header #wrap-header .gnaviBox {
    top: -430px;
    width: 100%;
  }

  .works-main {
    padding-top: 70px;
  }

  .work-detail-main {
    padding: 110px 20px 80px;
  }

  .work-detail-back {
    margin-bottom: 60px;
  }

  .work-detail-copy {
    grid-template-columns: 1fr;
    gap: 30px;
    margin-bottom: 40px;
  }

  .work-detail-heading h2 {
    font-size: 24px;
  }

  .works-section {
    padding: 80px 20px;
  }

  .works-section h2 {
    margin-bottom: 80px;
  }

  .works-filters {
    gap: 40px;
    margin-bottom: 80px;
  }

  .works-category-filter {
    flex-wrap: nowrap;
    gap: 10px;
    width: calc(100vw - 40px);
    overflow-x: auto;
    scrollbar-width: none;
  }

  .works-category-filter::-webkit-scrollbar {
    display: none;
  }

  .works-category-filter .works-filter-button {
    width: auto;
    min-width: max-content;
    padding: 4px 20px;
  }

  .works-tag-filter {
    gap: 0 20px;
    width: 100%;
  }

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

  .works-card-body {
    padding: 0;
  }

  .works-page footer #wrap-footer .footerBox {
    padding: 0;
  }

  .works-page footer #wrap-footer .footerBox .logo img {
    width: 100%;
    max-width: 350px;
    height: auto;
  }
}
