/* ==========================================================================
   FAQ Page Styles
   Based on src/pages/2025/faq/index.page.tsx + Tag.tsx + Accordion.tsx
   ========================================================================== */

/* Page Title */
.page-title {
  font-size: 100px;
  font-weight: 700;
  line-height: 1.5;
  letter-spacing: -0.01em;
  color: #fff;
  padding: 220px 60px 40px;
  background: #000 url('../../img/key-visuals/img_sub_key_visual_faq.jpg')
    center right/auto 100% no-repeat;
}

/* FAQ Article */
.faq-article {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 80px;
  width: 100%;
  height: 100%;
  margin: 0 auto;
  padding: 140px 0 160px;
  background: #e7e7e7;
}

/* FAQ Section */
.faq-section {
  display: flex;
  flex-direction: column;
  gap: 80px;
  width: 100%;
  max-width: 1190px;
  margin: 0 auto;
}

/* Tags Wrapper */
.faq-tags-wrap {
  overflow: auto;
}

.faq-tags-wrap::-webkit-scrollbar {
  width: 0;
}

/* Tags Container */
.faq-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.faq-tags button {
  display: block;
  overflow: hidden;
  max-width: 280px;
  white-space: nowrap;
  text-overflow: ellipsis;
}

/* Tag Button */
.faq-tag {
  padding: 10px 18px;
  border-radius: 10px;
  background-color: transparent;
  color: #c8c8c8;
  font-size: 24px;
  font-weight: 400;
  line-height: 1.6;
  cursor: pointer;
  transition: all 0.2s ease;
}

.faq-tag--selected {
  background-color: #fff;
  color: #000;
  font-weight: 700;
}

/* FAQ List */
.faq-list {
  background-color: #fff;
  border-radius: 20px;
}

/* Accordion List Container */
.faq-accordion-list {
  width: 100%;
  min-width: 1120px;
  padding: 60px;
}

/* Individual Accordion */
.faq-accordion {
  font-family: '42dotSansOTF', sans-serif;
  font-size: 16px;
  font-weight: 500;
  line-height: 1.5;
  border-bottom: 1px solid #ffffff10;
  display: flex;
  flex-direction: column;
  padding: 28px 0;
  cursor: pointer;
}

.faq-accordion:first-of-type {
  padding-top: 0;
}

.faq-accordion:last-of-type {
  padding-bottom: 0;
}

.faq-accordion:not(:first-of-type) {
  border-top: 1px solid #e7e7e7;
}

.faq-accordion--first-visible {
  border-top: none !important;
  padding-top: 0px;
}

/* Accordion Header */
.faq-accordion__header {
  position: relative;
  display: flex;
  gap: 96px;
  align-items: center;
}

.faq-accordion__category {
  width: 75px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: #000;
  flex-shrink: 0;
}

.type_en .faq-accordion__category {
  width: 125px;
}

.faq-accordion__title {
  flex: 1;
  font-size: 17px;
  font-weight: 700;
  line-height: 1.6;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: #000;
}

.faq-accordion__icon {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 29px;
  height: 24px;
  transition: transform 0.3s ease;
}

.faq-accordion--open .faq-accordion__icon {
  transform: rotate(180deg);
}

/* Accordion Content */
.faq-accordion__content {
  padding-left: 172px;
  font-family: '42dotSansOTF', sans-serif;
  font-size: 16px;
  font-weight: 500;
  line-height: 1.5;
  color: #808080;
  word-break: keep-all;
}

.type_en .faq-accordion__content {
  padding-left: 221px;
}

.faq-accordion__content p {
  margin: 20px 0 14px;
  font-weight: 500;
}

.faq-accordion__content p + p {
  margin-top: 58px;
}

.faq-accordion__content a {
  color: #808080;
  text-decoration: underline;
}

/* ==========================================================================
   Tablet Responsive (768px - 1200px)
   ========================================================================== */
@media screen and (max-width: 1200px) and (min-width: 768px) {
  .page-title {
    font-size: calc(100 / 1200 * 100vw);
    padding: calc(220 / 1200 * 100vw) calc(40 / 1200 * 100vw)
      calc(40 / 1200 * 100vw);
  }

  .faq-article {
    padding: calc(140 / 1200 * 100vw) calc(60 / 1920 * 100vw)
      calc(80 / 1920 * 100vw);
    gap: calc(80 / 1200 * 100vw);
  }

  .faq-section {
    gap: calc(80 / 1200 * 100vw);
  }

  .faq-tags button {
    max-width: calc(280 / 1200 * 100vw);
  }

  .faq-tag {
    padding: calc(10 / 1200 * 100vw) calc(18 / 1200 * 100vw);
    border-radius: calc(10 / 1200 * 100vw);
    font-size: calc(24 / 1200 * 100vw);
  }

  .faq-accordion-list {
    min-width: calc(1120 / 1200 * 100vw);
    padding: calc(60 / 1200 * 100vw);
  }

  .faq-accordion {
    padding: calc(28 / 1200 * 100vw) 0;
  }

  .faq-accordion__header {
    gap: calc(90 / 1200 * 100vw);
  }

  .faq-accordion__category {
    width: calc(75 / 1200 * 100vw);
  }

  .type_en .faq-accordion__category {
    width: calc(125 / 1200 * 100vw);
  }

  .faq-accordion__content {
    padding-left: calc(172 / 1200 * 100vw);
  }

  .type_en .faq-accordion__content {
    padding-left: calc(215 / 1200 * 100vw);
  }

  .faq-accordion__content p + p {
    margin-top: calc(20 / 1200 * 100vw);
  }
}

/* ==========================================================================
   Mobile Responsive (max-width: 767px)
   ========================================================================== */
@media screen and (max-width: 767px) {
  .page-title {
    font-size: 50px;
    font-weight: 700;
    line-height: 1.5;
    letter-spacing: -0.01em;
    padding: 155px 20px 10px;
    background: #000 url('../../img/key-visuals/img_sub_key_visual_faq_mo.jpg')
      center/auto 100% no-repeat;
  }

  .faq-article {
    padding: 60px 20px;
    gap: 60px;
  }

  .faq-section {
    gap: 40px;
  }

  .faq-tags-wrap {
    margin: 0 -20px;
    padding: 0 20px;
  }

  .faq-tags {
    flex-wrap: nowrap;
  }

  .faq-tags button {
    overflow: initial;
    max-width: initial;
  }

  .faq-tag {
    font-size: 16px;
    font-weight: 400;
    line-height: 1.6;
  }

  .faq-tag--selected {
    font-size: 16px;
    font-weight: 700;
    line-height: 1.6;
  }

  .faq-list {
    border-radius: 14px;
  }

  .faq-accordion-list {
    padding: 57px 28px;
    min-width: 100%;
  }

  .faq-accordion__header {
    height: auto;
    gap: 6px;
    flex-wrap: wrap;
    justify-content: space-between;
  }

  .faq-accordion__category {
    font-family: '42dotSansOTF', sans-serif;
    font-size: 13px;
    font-weight: 400;
    line-height: 1.5;
    width: auto;
    color: #808080;
  }

  .faq-accordion__title {
    font-family: '42dotSansOTF', sans-serif;
    font-size: 16px;
    font-weight: 500;
    line-height: 1.6;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    flex: initial;
    white-space: initial;
    width: 100%;
    margin-right: 38px;
  }

  .faq-accordion__icon {
    position: absolute;
    top: 50%;
    right: 0;
    transform: translateY(-50%);
    width: 26px;
    height: 24px;
  }

  .faq-accordion--open .faq-accordion__icon {
    transform: translateY(-50%) rotate(180deg);
  }

  .faq-accordion__content {
    padding-left: 0 !important;
    font-family: '42dotSansOTF', sans-serif;
    font-size: 14px;
    font-weight: 400;
    line-height: 1.428;
  }

  .type_en .faq-accordion__content {
    padding-left: 0 !important;
  }

  .faq-accordion__content p + p {
    margin-top: 58px;
  }
}

/* ========================================
   Footer Background Color Override
   ======================================== */
.footer-container {
  background-color: #e7e7e7;
}
