/* ================================
   Topics Section — matches refs/business.html
   ================================ */

/* --- Section --- */
.topics-section {
  width: 100%;
  background: #ebebeb;
  padding: 120px 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
}

.topics-section__inner {
  width: 1320px;
  max-width: 100%;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 60px;
}

/* --- Heading --- */
.topics-section__heading {
  display: flex;
  flex-direction: column;
  gap: 15px;
  width: 100%;
}

.topics-section__label {
  font-family: 'Inter', sans-serif;
  font-size: 60px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0;
  color: #000;
  margin: 0;
}

.topics-section__subtitle {
  font-family: 'Noto Sans JP', sans-serif;
  font-size: 16px;
  font-weight: 600;
  line-height: 1;
  letter-spacing: 0;
  color: #000;
  margin: 0;
}

/* --- Carousel wrapper: break out to full viewport width --- */
.topics-section__carousel-wrap {
  width: 100vw;
  margin-left: calc(50% - 50vw);
  position: relative;
  padding-bottom: 50px; /* nav buttons space */
}

/* --- Slide width --- */
.topics-section .swiper-slide {
  width: 362px;
  height: auto;
}

/* --- Card (slide) --- */
.topics-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background: #fff;
  border: 1px solid #a0a0a0;
  border-right: 0;
  padding: 40px;
  gap: 70px;
  text-decoration: none;
  color: #000;
  height: 100%;
  box-sizing: border-box;
  transition: background 0.2s;
}

.swiper-slide:last-child .topics-card {
  border-right: 1px solid #a0a0a0;
}

.topics-card:hover {
  background: #f0f0f0;
}

.topics-card:focus-visible {
  outline: 2px solid #000;
}

/* --- Card upper (image + text) --- */
.topics-card__upper {
  display: flex;
  flex-direction: column;
  gap: 20px;
  width: 100%;
}

.topics-card__image {
  width: 100%;
  height: 180px;
  overflow: hidden;
  background: #f1f1f1;
}

.topics-card__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.topics-card__text {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 5px 0;
}

.topics-card__title {
  font-family: 'Noto Sans JP', sans-serif;
  font-size: 16px;
  font-weight: 400;
  line-height: 1.8;
  letter-spacing: -0.02em;
  color: #000;
  margin: 0;
}

.topics-card__date {
  font-family: 'Noto Sans JP', sans-serif;
  font-size: 14px;
  font-weight: 300;
  line-height: 1;
  letter-spacing: 0.05em;
  color: #999;
  margin: 0;
}

/* --- Card lower (category + arrow) --- */
.topics-card__lower {
  display: flex;
  flex-direction: column;
}

.topics-card__cat-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.topics-card__cat {
  display: inline-flex;
  align-items: center;
  background: #fff;
  border: 1px solid #a0a0a0;
  padding: 10px 13px;
  font-family: 'Noto Sans JP', sans-serif;
  font-size: 13px;
  font-weight: 300;
  line-height: 1;
  letter-spacing: 0.02em;
  color: #000;
}

.topics-card__arrow {
  width: 16px;
  height: 16px;
  color: #000;
}

/* --- Nav buttons (below carousel, right-aligned within 1320px) --- */
.topics-section__nav {
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 1320px;
  max-width: 100%;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 0;
  padding-right: 50px;
  box-sizing: border-box;
}

.topics-section__btn {
  width: 40px;
  height: 40px;
  background: transparent;
  border: none;
  border-radius: 0;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  transition: opacity 0.2s;
}

.topics-section__btn:hover {
  opacity: 0.5;
}

.topics-section__btn .material-icons {
  font-size: 36px;
  color: #222;
  line-height: 1;
}

.topics-section__btn--pause .material-icons {
  font-size: 28px;
}

/* --- CTA button --- */
.topics-section__cta {
  display: inline-flex;
  align-items: center;
  align-self: center;
  border: 1px solid #a0a0a0;
  padding: 12px 28px 11px 28px;
  text-decoration: none;
  color: #000;
  position: relative;
  overflow: hidden;
  box-sizing: border-box;
}

.topics-section__cta--sp {
  display: none;
}

.topics-section__cta-inner {
  display: flex;
  align-items: center;
  gap: 18px;
  position: relative;
  z-index: 5;
}

.topics-section__cta-text {
  font-family: 'Noto Sans JP', sans-serif;
  font-size: 16px;
  font-weight: 500;
  line-height: 1.8;
  letter-spacing: 0.02em;
  color: inherit;
  white-space: nowrap;
}

.topics-section__cta-icon {
  color: inherit;
  transition: opacity 0.3s, transform 0.3s;
}

.topics-section__cta-arrow-wrap {
  position: absolute;
  right: 0;
  opacity: 0;
  transition: opacity 0.3s;
}

.topics-section__cta-arrow {
  color: #fff;
  transition: transform 0.3s;
  transform: translateX(0);
}

/* CTA hover effect: black fill from left */
.topics-section__cta-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 1px;
  height: 100%;
  background: #000;
  opacity: 0;
  transition: width 480ms cubic-bezier(0.19, 1, 0.22, 1), opacity 480ms cubic-bezier(0.19, 1, 0.22, 1);
  z-index: 0;
}

.topics-section__cta:hover .topics-section__cta-bg {
  width: 100%;
  opacity: 1;
}

.topics-section__cta:hover {
  color: #fff;
}

.topics-section__cta:hover .topics-section__cta-icon {
  opacity: 0;
  transform: translateX(10px);
}

.topics-section__cta:hover .topics-section__cta-arrow-wrap {
  opacity: 1;
}

.topics-section__cta:hover .topics-section__cta-arrow--black {
  transform: translateX(10px);
}
.topics-section__cta:hover .topics-section__cta-arrow--white {
  transform: translateX(0);
}

/* ================================
   Responsive
   ================================ */

/* 1140px */
@media (max-width: 1140px) {
  .topics-section__heading {
    text-align: left;
  }

  .topics-section__subtitle {
    line-height: 1.4;
  }
}

/* 768px */
@media (max-width: 768px) {
  .topics-section {
    padding: 80px 30px;
  }

  .topics-section__label {
    font-size: 50px;
  }

  .topics-section .swiper-slide {
    width: 342px;
  }

  .topics-card {
    padding: 30px;
  }

  .topics-card__title {
    font-size: 14px;
  }

  .topics-card__date {
    font-size: 13px;
  }

  .topics-card__cat {
    font-size: 12px;
    padding: 10px 12px;
  }

  .topics-section__cta-text {
    font-size: 14px;
  }

  .topics-section__nav {
    padding-right: 0;
  }

  /* PC CTA hidden, SP CTA shown */
  .topics-section__cta--pc {
    display: none;
  }

  .topics-section__cta--sp {
    display: inline-flex;
  }
}

/* 480px */
@media (max-width: 480px) {
  .topics-section {
    padding: 70px 20px;
  }

  .topics-section__inner {
    gap: 40px;
  }

  .topics-section__label {
    font-size: 44px;
  }

  .topics-section__subtitle {
    line-height: 1.3;
  }

  .topics-section .swiper-slide {
    width: calc(100% - 40px);
  }

  .topics-card {
    border: 1px solid #a0a0a0;
    padding: 30px;
    gap: 50px;
  }

  .swiper-slide:last-child .topics-card {
    border-right: 1px solid #a0a0a0;
  }

  .topics-card__text {
    gap: 6px;
    padding: 2px 0;
  }

  .topics-card__title {
    font-size: 15px;
  }

  .topics-card__date {
    font-size: 14px;
  }

  .topics-card__cat {
    font-size: 12px;
    padding: 10px 14px;
  }

  .topics-card__arrow {
    width: 20px;
    height: 20px;
  }

  .topics-section__cta-inner {
    gap: 8px;
    justify-content: center;
  }

  .topics-section__cta-text {
    font-size: 13px;
  }

  .topics-section__cta--sp {
    width: 100%;
    padding: 12px 0;
    justify-content: center;
  }

  .topics-section__nav {
    padding: 0 20px;
  }
}

.topics-section__cta-arrow {
  width: 10px;
  height: auto;
}

.topics-section__cta-arrow--white {
  display: none;
}
.topics-section__cta:hover .topics-section__cta-arrow--black {
  display: none;
}
.topics-section__cta:hover .topics-section__cta-arrow--white {
  display: inline;
}