/* =========================================================
   PERFECTION Q&A
   ========================================================= */

.faq-page {
  background: #f7f5ef;
  color: #22211e;
}

.faq-page main {
  overflow: hidden;
}


/* =========================================================
   COMMON
   ========================================================= */

.faq-kicker {
  margin: 0 0 22px;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(34, 33, 30, 0.5);
}

.faq-section-head {
  max-width: 1240px;
  margin: 0 auto 52px;
  padding: 0 32px;
}

.faq-section-head h2 {
  margin: 0;
  font-family: "Yu Mincho", "Hiragino Mincho ProN", serif;
  font-size: clamp(1.9rem, 2.85vw, 3.2rem);
  font-weight: 400;
  line-height: 1.25;
  letter-spacing: -0.025em;
}


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

.faq-hero {
  padding: 150px 0 110px;
  background: #f7f5ef;
  overflow: hidden;
}

.faq-hero-inner {
  width: min(1240px, calc(100% - 64px));
  margin: 0 auto;

  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(420px, 0.82fr);
  align-items: center;
  gap: clamp(70px, 8vw, 120px);
}

.faq-hero-text {
  min-width: 0;
}

.faq-kicker {
  margin: 0 0 28px;
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  color: #77736c;
}

.faq-hero h1 {
  margin: 0;
  font-family: "Yu Mincho", "Hiragino Mincho ProN", serif;
  font-size: clamp(1.9rem, 2.85vw, 3.2rem);
  font-weight: 400;
  line-height: 1.42;
  letter-spacing: -0.02em;
  color: #171717;
}

.faq-hero-copy {
  margin: 42px 0 0;
  font-size: 0.9rem;
  line-height: 2;
  letter-spacing: 0.05em;
  color: #77736c;
}

.faq-hero-visual {
  width: 100%;
  max-width: 500px;
  justify-self: end;

  aspect-ratio: 4 / 5;
  overflow: hidden;
  border-radius: 3px;
}

.faq-hero-visual img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* =========================================================
   SEARCH
   ========================================================= */

.faq-search-wrap {
  position: relative;
  width: min(760px, 100%);
  margin-top: 70px;
  border-bottom: 1px solid rgba(34, 33, 30, 0.25);
  transition:
    border-color 400ms ease,
    transform 500ms cubic-bezier(.16, 1, .3, 1);
}

.faq-search-wrap:focus-within {
  border-color: #22211e;
  transform: translateY(-2px);
}

.faq-search {
  width: 100%;
  height: 76px;
  padding: 0 115px 0 44px;
  border: 0;
  outline: 0;
  background: transparent;
  color: #22211e;
  font: inherit;
  font-size: 1.05rem;
}

.faq-search::placeholder {
  color: rgba(34, 33, 30, 0.38);
}

.faq-search-icon {
  position: absolute;
  left: 3px;
  top: 50%;
  width: 18px;
  height: 18px;
  border: 1.5px solid #22211e;
  border-radius: 50%;
  transform: translateY(-55%);
}

.faq-search-icon::after {
  content: "";
  position: absolute;
  width: 8px;
  height: 1.5px;
  right: -6px;
  bottom: -3px;
  background: #22211e;
  transform: rotate(45deg);
  transform-origin: left center;
}

.faq-search-shortcut {
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  font-size: 0.58rem;
  letter-spacing: 0.18em;
  color: rgba(34, 33, 30, 0.35);
}


/* =========================================================
   MOST ASKED
   ========================================================= */

.faq-popular {
  padding: 130px 0 150px;
  background: #ebe7df;
}

.faq-popular-grid {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 32px;

  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.faq-feature-card {
  position: relative;
  min-height: 420px;
  padding: 34px;
  border: 1px solid rgba(34, 33, 30, 0.11);
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.32);
  color: inherit;
  text-align: left;
  cursor: pointer;
  overflow: hidden;

  transition:
    transform 800ms cubic-bezier(.16, 1, .3, 1),
    background-color 600ms ease,
    box-shadow 800ms ease;
}

.faq-feature-card:hover {
  transform: translateY(-8px);
  background: rgba(255, 255, 255, 0.62);
  box-shadow: 0 30px 70px rgba(36, 32, 25, 0.08);
}

.faq-feature-number {
  display: block;
  margin-bottom: 96px;
  font-size: 0.6rem;
  letter-spacing: 0.18em;
  color: rgba(34, 33, 30, 0.4);
}

.faq-feature-card > p {
  margin: 0 0 14px;
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  color: rgba(34, 33, 30, 0.45);
}

.faq-feature-card h3 {
  position: relative;
  z-index: 2;
  max-width: 330px;
  margin: 0;
  font-family: "Yu Mincho", "Hiragino Mincho ProN", serif;
  font-size: clamp(1.45rem, 2.2vw, 2.2rem);
  font-weight: 400;
  line-height: 1.55;
  letter-spacing: -0.02em;
}

.faq-feature-arrow {
  position: absolute;
  right: 30px;
  bottom: 28px;
  font-size: 1.2rem;
  transition: transform 500ms cubic-bezier(.16, 1, .3, 1);
}

.faq-feature-card:hover .faq-feature-arrow {
  transform: translate(4px, -4px);
}

.faq-feature-stat {
  position: absolute;
  right: -8px;
  bottom: -28px;
  font-family: Arial, sans-serif;
  font-size: clamp(5rem, 9vw, 9rem);
  font-weight: 600;
  letter-spacing: -0.08em;
  color: rgba(34, 33, 30, 0.045);
  pointer-events: none;
}


/* =========================================================
   Q&A BROWSER
   ========================================================= */

.faq-browser {
  padding: 125px 32px 170px;
  background: #f8f6f1;
}

.faq-category-bar {
  position: sticky;
  top: var(--header-height, 78px);
  z-index: 20;

  max-width: 1240px;
  margin: 0 auto;
  padding: 17px 0;

  display: flex;
  align-items: center;
  gap: 8px;

  background: rgba(248, 246, 241, 0.88);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);

  border-bottom: 1px solid rgba(34, 33, 30, 0.1);
}

.faq-category {
  flex: 0 0 auto;
  padding: 11px 18px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: rgba(34, 33, 30, 0.53);
  font: inherit;
  font-size: 0.75rem;
  cursor: pointer;

  transition:
    background-color 350ms ease,
    color 350ms ease,
    transform 350ms ease;
}

.faq-category:hover {
  color: #22211e;
  transform: translateY(-1px);
}

.faq-category.is-active {
  background: #22211e;
  color: #f7f3ea;
}

.faq-results-meta {
  max-width: 1240px;
  margin: 65px auto 20px;
}

.faq-results-meta p {
  margin: 0;
  font-size: 0.58rem;
  letter-spacing: 0.2em;
  color: rgba(34, 33, 30, 0.38);
}


/* =========================================================
   FAQ LIST
   ========================================================= */

.faq-list {
  max-width: 1240px;
  margin: 0 auto;
  border-top: 1px solid rgba(34, 33, 30, 0.15);
}

.faq-item {
  border-bottom: 1px solid rgba(34, 33, 30, 0.14);

  transition:
    opacity 450ms ease,
    background-color 450ms ease;
}

.faq-item[hidden] {
  display: none;
}

.faq-question {
  width: 100%;
  min-height: 118px;
  padding: 22px 0;

  display: grid;
  grid-template-columns: 180px 1fr 50px;
  align-items: center;
  gap: 26px;

  border: 0;
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: pointer;
}

.faq-item-meta {
  font-size: 0.58rem;
  letter-spacing: 0.18em;
  color: rgba(34, 33, 30, 0.38);
}

.faq-question-text {
  font-family: "Yu Mincho", "Hiragino Mincho ProN", serif;
  font-size: clamp(1.15rem, 2vw, 1.75rem);
  line-height: 1.55;
  letter-spacing: -0.015em;

  transition:
    transform 600ms cubic-bezier(.16, 1, .3, 1),
    color 350ms ease;
}

.faq-question:hover .faq-question-text {
  transform: translateX(8px);
}

.faq-toggle {
  position: relative;
  justify-self: end;
  width: 32px;
  height: 32px;
}

.faq-toggle::before,
.faq-toggle::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 16px;
  height: 1px;
  background: #22211e;

  transition:
    transform 600ms cubic-bezier(.16, 1, .3, 1),
    opacity 400ms ease;
}

.faq-toggle::before {
  transform: translate(-50%, -50%);
}

.faq-toggle::after {
  transform: translate(-50%, -50%) rotate(90deg);
}

.faq-item.is-open {
  background: rgba(229, 225, 216, 0.42);
}

.faq-item.is-open .faq-toggle::after {
  transform: translate(-50%, -50%) rotate(0deg);
  opacity: 0;
}


/* =========================================================
   ANSWER
   ========================================================= */

.faq-answer {
  display: grid;
  grid-template-rows: 0fr;
  opacity: 0;

  transition:
    grid-template-rows 900ms cubic-bezier(.16, 1, .3, 1),
    opacity 550ms ease;
}

.faq-item.is-open .faq-answer {
  grid-template-rows: 1fr;
  opacity: 1;
}

.faq-answer-inner {
  position: relative;
  min-height: 0;
  overflow: hidden;

  padding-left: 206px;
  padding-right: 90px;
}

.faq-item.is-open .faq-answer-inner {
  padding-bottom: 70px;
}

.faq-answer-inner p {
  position: relative;
  z-index: 2;

  max-width: 760px;
  margin: 0 0 18px;

  color: rgba(34, 33, 30, 0.68);
  font-size: 0.94rem;
  line-height: 2.05;
}

.faq-big-stat {
  position: absolute;
  z-index: 0;
  right: 30px;
  bottom: -55px;

  font-family: Arial, sans-serif;
  font-size: clamp(7rem, 17vw, 15rem);
  font-weight: 600;
  letter-spacing: -0.09em;

  color: rgba(34, 33, 30, 0.035);
  pointer-events: none;
}


/* =========================================================
   EMPTY SEARCH
   ========================================================= */

.faq-empty {
  max-width: 1240px;
  min-height: 320px;
  margin: 0 auto;
  padding: 90px 0;

  text-align: center;
}

.faq-empty p {
  margin: 0 0 14px;
  font-size: 0.6rem;
  letter-spacing: 0.2em;
  color: rgba(34, 33, 30, 0.4);
}

.faq-empty h3 {
  margin: 0 0 14px;
  font-family: "Yu Mincho", "Hiragino Mincho ProN", serif;
  font-size: 1.8rem;
  font-weight: 400;
}

.faq-empty span {
  color: rgba(34, 33, 30, 0.52);
  font-size: 0.86rem;
}


/* =========================================================
   CONTACT
   ========================================================= */

.faq-contact {
  min-height: 680px;
  padding: 150px 32px;

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

  background: #25231f;
  color: #f5f1e8;
  text-align: center;
}

.faq-contact .faq-kicker {
  color: rgba(255, 255, 255, 0.43);
}

.faq-contact h2 {
  margin: 0;
  font-family: "Yu Mincho", "Hiragino Mincho ProN", serif;
  font-size: clamp(1.9rem, 2.85vw, 3.2rem);
  font-weight: 400;
  line-height: 1.42;
  letter-spacing: -0.045em;
}

.faq-contact > p:not(.faq-kicker) {
  margin: 40px 0 0;
  color: rgba(255, 255, 255, 0.58);
  font-size: 0.9rem;
  line-height: 1.9;
}

.faq-contact > a {
  margin-top: 50px;
  padding-bottom: 7px;

  display: inline-flex;
  align-items: center;
  gap: 35px;

  border-bottom: 1px solid rgba(255, 255, 255, 0.45);

  color: #fff;
  text-decoration: none;
  font-size: 0.82rem;

  transition:
    gap 500ms cubic-bezier(.16, 1, .3, 1),
    border-color 300ms ease;
}

.faq-contact > a:hover {
  gap: 48px;
  border-color: #fff;
}



/* =========================================================
   DESKTOP HERO SIZE FIX
   ========================================================= */
@media (min-width: 901px) {
  .faq-hero-inner {
    width: min(1440px, calc(100% - 64px));
    grid-template-columns: minmax(0, 1fr) minmax(560px, 760px);
    gap: clamp(48px, 5vw, 72px);
  }

  .faq-hero-visual {
    width: 100%;
    max-width: 760px;
    justify-self: end;
  }
}

/* =========================================================
   TABLET
   ========================================================= */

@media (max-width: 900px) {

  .faq-hero {
    min-height: 650px;
    padding-top: 130px;
  }

  .faq-popular-grid {
    grid-template-columns: 1fr;
  }

  .faq-feature-card {
    min-height: 310px;
  }

  .faq-feature-number {
    margin-bottom: 60px;
  }

  .faq-question {
    grid-template-columns: 130px 1fr 40px;
  }

  .faq-answer-inner {
    padding-left: 156px;
    padding-right: 40px;
  }
}


/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 700px) {

  .faq-hero {
    min-height: auto;
    padding: 125px 22px 78px;
  }
.faq-hero-copy {
    margin-top: 30px;
    font-size: 0.88rem;
  }

  .faq-search-wrap {
    margin-top: 48px;
  }

  .faq-search {
    height: 66px;
    padding-left: 37px;
    padding-right: 20px;
    font-size: 0.9rem;
  }

  .faq-search-shortcut {
    display: none;
  }


  .faq-popular {
    padding: 82px 0 95px;
  }

  .faq-section-head {
    margin-bottom: 34px;
    padding: 0 22px;
  }

  .faq-popular-grid {
    padding: 0 22px;

    display: flex;
    gap: 12px;

    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
  }

  .faq-popular-grid::-webkit-scrollbar {
    display: none;
  }

  .faq-feature-card {
    flex: 0 0 84vw;
    min-height: 360px;
    padding: 26px;
    scroll-snap-align: center;
  }

  .faq-feature-number {
    margin-bottom: 72px;
  }

  .faq-feature-card h3 {
    font-size: 1.65rem;
  }


  .faq-browser {
    padding: 72px 22px 105px;
  }

  .faq-category-bar {
    top: 62px;
    margin-left: -22px;
    margin-right: -22px;
    padding: 14px 22px;

    overflow-x: auto;
    scrollbar-width: none;
  }

  .faq-category-bar::-webkit-scrollbar {
    display: none;
  }

  .faq-category {
    padding: 10px 15px;
    font-size: 0.7rem;
  }

  .faq-results-meta {
    margin-top: 45px;
  }

  .faq-question {
    min-height: 104px;
    padding: 20px 0;

    grid-template-columns: 1fr 36px;
    gap: 18px;
  }

  .faq-item-meta {
    grid-column: 1 / -1;
    margin-bottom: -5px;
  }

  .faq-question-text {
    font-size: 1.12rem;
    line-height: 1.6;
  }

  .faq-question:hover .faq-question-text {
    transform: none;
  }

  .faq-answer-inner {
    padding-left: 0;
    padding-right: 0;
  }

  .faq-item.is-open .faq-answer-inner {
    padding-bottom: 48px;
  }

  .faq-answer-inner p {
    font-size: 0.88rem;
    line-height: 1.95;
  }

  .faq-big-stat {
    right: -10px;
    bottom: -15px;
    font-size: 7rem;
  }


  .faq-contact {
    min-height: 580px;
    padding: 110px 22px;
  }

}


/* =========================================================
   REDUCED MOTION
   ========================================================= */

@media (prefers-reduced-motion: reduce) {

  .faq-feature-card,
  .faq-question-text,
  .faq-answer,
  .faq-toggle::before,
  .faq-toggle::after,
  .faq-contact > a,
  .faq-search-wrap {
    transition: none;
  }

}
/* =========================================================
   FINAL RESPONSIVE FIXES — Q&A
   ========================================================= */

/* Keep the category filter sticky on desktop and mobile. */
.faq-page main {
  overflow-x: clip;
  overflow-y: visible;
}

.faq-category-bar {
  position: sticky;
  top: var(--header-height, 78px);
  z-index: 100;
  background: rgba(248, 246, 241, 0.96);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

/* Used for the intentional mobile line break in
   「よく見られている / 質問。」 */
.faq-mobile-br {
  display: none;
}

@media (max-width: 700px) {

  /* HERO: image and copy overlap instead of squeezing into two columns. */
  .faq-hero {
    min-height: auto;
    padding: 0;
  }

  .faq-hero-inner {
    position: relative;
    width: 100%;
    min-height: 720px;
    display: block;
    overflow: hidden;
  }

  .faq-hero-visual {
    position: absolute;
    inset: 0;
    width: 100%;
    max-width: none;
    height: 100%;
    aspect-ratio: auto;
    border-radius: 0;
    justify-self: auto;
  }

  .faq-hero-visual img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 75% center;
  }

  .faq-hero-inner::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    background: linear-gradient(
      90deg,
      rgba(20, 18, 15, 0.62) 0%,
      rgba(20, 18, 15, 0.40) 42%,
      rgba(20, 18, 15, 0.08) 76%,
      rgba(20, 18, 15, 0) 100%
    );
  }

.faq-hero-text {
  position: relative;
  z-index: 2;
  width: 100%;
  padding: 145px 24px 70px;
  box-sizing: border-box;
}

  .faq-hero .faq-kicker {
    color: rgba(255, 255, 255, 0.72);
  }

  .faq-hero h1 {
  color: #f7f5ef;
  font-size: clamp(1.9rem, 8vw, 2.2rem);
  line-height: 1.42;
  letter-spacing: -0.02em;
  text-shadow: 0 2px 14px rgba(0, 0, 0, 0.24);
}

  .faq-hero-copy {
    margin-top: 30px;
    color: rgba(255, 255, 255, 0.80);
    font-size: 0.88rem;
    line-height: 2;
    text-shadow: 0 1px 8px rgba(0, 0, 0, 0.22);
  }

  .faq-hero-copy br {
    display: none;
  }

  /* Match Q&A section headings to the site's mobile heading scale. */
  .faq-mobile-br {
    display: block;
  }

  .faq-section-head h2,
  .faq-contact h2 {
    font-size: clamp(1.9rem, 2.85vw, 3.2rem);
    line-height: 1.42;
    letter-spacing: -0.02em;
    word-break: keep-all;
    overflow-wrap: normal;
  }
}
