/* FAQページのスタイル */

body.recruit-page {
  background-color: #fff;
}

/* ヒーローセクション */
.recruit-faq-hero {
  width: 100%;
  height: calc(100vh - 100px);
  margin-top: 100px;
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  grid-template-rows: repeat(8, 1fr);
  column-gap: 20px;
  row-gap: 20px;
  padding: 0 40px;
  box-sizing: border-box;
  background-color: #ffffff;
}

.recruit-faq-hero img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

/* グリッド配置用のクラス */
.recruit-faq-hero .faq-top-main {
  grid-column: 6 / 12;
  grid-row: 2 / 8;
}

.recruit-faq-hero .faq-top-sub {
  grid-column: 3 / 5;
  grid-row: 3 / 4;
}

.recruit-faq-hero .mark1 {
  grid-column: 10 / 12;
  grid-row: 2 / 4;
}

.recruit-faq-hero .mark2 {
  grid-column: 2 / 4;
  grid-row: 5 / 7;
  transform: scale(1.5);
  transform-origin: center;
}

.recruit-faq-hero .mark3 {
  grid-column: 10 / 12;
  grid-row: 5 / 7;
  transform: scale(1.5);
  transform-origin: center;
}

.recruit-faq-hero .recruit-faq-hero-title-wrapper {
  grid-column: 3 / 7;
  grid-row: 5 / 7;
  display: flex;
  flex-direction: column;
  padding-left: 32px;
}

.recruit-faq-hero .recruit-faq-hero-title-wrapper p {
  color: #005AB7;
  margin: 0;
  padding: 0;
  font-size: 28px;
}

.recruit-faq-hero .recruit-faq-hero-title {
  margin-top: 0 !important;
  font-size: 62px;
  font-weight: normal;
  line-height: 1;
  padding: 0 !important;
  text-align: left;
  color: #191e2e;
  background: none !important;
}

@media screen and (min-width: 1001px) {
  .recruit-faq-hero .recruit-faq-hero-title-wrapper {
    padding-left: 0;
  }

  .recruit-faq-hero .recruit-faq-hero-title {
    margin-top: 0 !important;
    font-size: 52px;
  }
}

/* 1200px以下 */
@media screen and (max-width: 1200px) {
  .recruit-faq-hero .faq-top-main {
    grid-column: 7 / 12;
  }

  .recruit-faq-hero .mark1 {
    grid-column: 11 / 13;
  }

  .recruit-faq-hero .mark2 {
    grid-column: 1 / 3;
  }

  .recruit-faq-hero .mark3 {
    grid-column: 11 / 13;
  }
}

/* 1024px以下 */
@media screen and (max-width: 1024px) {
  .recruit-faq-hero .faq-top-main {
    grid-column: 5 / 10;
  }

  .recruit-faq-hero .faq-top-sub {
    grid-column: 2 / 4;
    grid-row: 3 / 4;
  }

  .recruit-faq-hero .recruit-faq-hero-title-wrapper {
    grid-row: 7 / 8;
    padding-left: 0;
  }

  .recruit-faq-hero .recruit-faq-hero-title-wrapper p {
    font-size: 22px;
  }

  .recruit-faq-hero .recruit-faq-hero-title {
    font-size: 48px;
  }
}

/* タブレットサイズ（768px〜1024px） */
@media screen and (min-width: 768px) and (max-width: 1024px) {
  .recruit-faq-hero {
    height: 55vh;
    grid-template-rows: repeat(8, auto);
  }
}

/* タブレットサイズ（768px〜1024px）かつ横長 */
@media screen and (min-width: 768px) and (max-width: 1024px) and (orientation: landscape) {
  .recruit-faq-hero {
    height: 90vh;
  }
}

/* レスポンシブ */
@media screen and (max-width: 767px) {
  .recruit-faq-hero {
    height: auto;
    margin-top: 64px;
    grid-template-rows: repeat(8, auto);
  }

  .recruit-faq-hero .recruit-faq-hero-title-wrapper {
    grid-column: 3 / 8;
  }

  .recruit-faq-hero .recruit-faq-hero-title-wrapper p {
    font-size: 18px;
  }

  .recruit-faq-hero .recruit-faq-hero-title {
    font-size: 36px;
  }
}

/* 480px以下 */
@media screen and (max-width: 480px) {
  .recruit-faq-hero {
    grid-template-columns: repeat(4, 1fr);
    grid-template-rows: repeat(8, auto);
  }

  .recruit-faq-hero .faq-top-main {
    grid-column: 1 / 5;
    grid-row: 2 / 8;
  }

  .recruit-faq-hero .faq-top-sub {
    display: none;
  }

  .recruit-faq-hero .mark1 {
    display: none;
  }

  .recruit-faq-hero .mark2 {
    grid-column: 1 / 2;
    grid-row: 7 / 8;
  }

  .recruit-faq-hero .mark3 {
    grid-column: 4 / 5;
    grid-row: 2 / 3;
  }

  .recruit-faq-hero .recruit-faq-hero-title-wrapper {
    grid-column: 1 / 4;
    grid-row: 1 / 2;
    padding-top: 1.5em;
  }
}

/* ヘッダーの「お問い合わせ」と「EN」を非表示 */
body.page-recruit-faq .header_info .web_info,
body.recruit-faq .header_info .web_info,
body:has(main.recruit-faq) .header_info .web_info {
  display: none !important;
}

body.page-recruit-faq #global_nav ul li:has(a[href*="/contact"]),
body.recruit-faq #global_nav ul li:has(a[href*="/contact"]),
body:has(main.recruit-faq) #global_nav ul li:has(a[href*="/contact"]) {
  display: none !important;
}

body.page-recruit-faq #global_nav ul li:has(a[href*="/en"]):not(:has(ul)),
body.recruit-faq #global_nav ul li:has(a[href*="/en"]):not(:has(ul)),
body:has(main.recruit-faq) #global_nav ul li:has(a[href*="/en"]):not(:has(ul)) {
  display: none !important;
}

:root {
  --color-dark-blue: #1a4a7a;
  --color-light-blue: #99C1D5;
  --color-accent-yellow: #caf880;
  --color-white: #ffffff;
  --color-text-dark: #333333;
  --color-text-gray: #666666;
  --color-border-gray: #e0e0e0;
  --color-bright-blue: #4A90E2;
  --color-orange-red: #FF6B6B;
}

.recruit-faq-section {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 60px 40px 100px;
  background-color: var(--color-white);
  overflow: visible;
}

.recruit-faq-section .container {
  width: 100%;
  margin: 0 auto;
  overflow: visible;
}

/* ページタイトルセクション */
.faq-page-header {
  text-align: center;
  margin-bottom: 60px;
  padding-bottom: 30px;
  border-bottom: 2px solid var(--color-border-gray);
}

.faq-main-title {
  font-size: 48px;
  font-weight: bold;
  color: var(--color-dark-blue);
  margin-bottom: 15px;
  text-transform: lowercase;
  letter-spacing: 2px;
}

.faq-sub-title {
  font-size: 24px;
  font-weight: normal;
  color: var(--color-text-dark);
  margin: 0;
}

/* FAQコンテンツセクション */
.faq-content-section {
  width: 100%;
  overflow: visible;
}

.faq-list {
  width: 100%;
  margin-bottom: 60px;
}

/* FAQグルーピング */
.faq-group {
  margin-bottom: 50px;
}

.faq-group:last-of-type {
  margin-bottom: 0;
}

.faq-group-title {
  font-size: 24px;
  font-weight: bold;
  color: var(--color-dark-blue);
  margin-bottom: 30px;
  padding-bottom: 15px;
  border-bottom: 2px solid var(--color-border-gray);
}

/* FAQ項目 */
.faq-item {
  border: 1.25px solid var(--color-border-gray);
  border-radius: 8px;
  margin-bottom: 20px;
  background-color: var(--color-white);
  overflow: hidden;
  transition: box-shadow 0.3s ease;
}

.faq-item:hover {
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.faq-item.active {
  border-color: var(--color-dark-blue);
}

/* 質問ヘッダー */
.faq-question-header {
  display: flex;
  align-items: center;
  padding: 25px 30px;
  cursor: pointer;
  background-color: var(--color-white);
  transition: background-color 0.3s ease;
}

.faq-item.active .faq-question-header {
  background-color: #f8f9fa;
}

.faq-question-header:hover {
  background-color: #f8f9fa;
}

/* Qアイコン */
.faq-q-icon {
  width: 40px;
  height: 40px;
  min-width: 40px;
  background-color: var(--color-dark-blue);
  color: var(--color-white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  font-weight: bold;
  margin-right: 20px;
  line-height: 1;
  text-align: center;
  padding-bottom: 3.5px;
}

/* 質問テキスト */
.faq-question {
  flex: 1;
  font-size: 18px;
  font-weight: 600;
  color: var(--color-text-dark);
  margin: 0;
  line-height: 1.6;
  text-align: left;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

/* トグルボタン */
.faq-toggle {
  width: 32px;
  height: 32px;
  min-width: 32px;
  border: 2px solid var(--color-dark-blue);
  border-radius: 50%;
  background-color: var(--color-white);
  color: var(--color-dark-blue);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  margin-left: 20px;
  padding: 0;
}

.faq-toggle:hover {
  background-color: var(--color-dark-blue);
  color: var(--color-white);
}

.faq-toggle-icon {
  font-size: 20px;
  font-weight: bold;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  transform: translateY(1px);
  transition: opacity 0.3s ease;
}

/* 回答ラッパー */
.faq-answer-wrapper {
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  padding: 0 30px;
  background-color: var(--color-white);
  transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.3s ease, padding 0.3s ease;
  display: flex;
  align-items: center;
  gap: 20px;
}

.faq-item.active .faq-answer-wrapper {
  max-height: 2000px;
  opacity: 1;
  padding: 20px 30px;
}

/* Aアイコン */
.faq-a-icon {
  width: 40px;
  height: 40px;
  min-width: 40px;
  background-color: var(--color-light-blue);
  color: var(--color-white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  font-weight: bold;
  margin-top: 0;
  flex-shrink: 0;
  line-height: 1;
  text-align: center;
  padding-bottom: 3.5px;
}

/* 回答テキスト */
.faq-answer {
  flex: 1;
  font-size: 16px;
  line-height: 1.8;
  color: var(--color-text-dark);
  word-wrap: break-word;
  overflow-wrap: break-word;
  padding: 0;
  margin: 0;
}

.faq-answer p {
  margin-bottom: 15px;
  font-weight: normal;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.faq-answer p:last-child {
  margin-bottom: 0;
}

.faq-answer strong {
  font-weight: bold;
  color: var(--color-dark-blue);
}

.faq-answer a {
  word-wrap: break-word;
  overflow-wrap: break-word;
  word-break: break-all;
}

/* リスト */
.faq-list-items {
  margin: 15px 0;
  padding-left: 25px;
}

.faq-list-items li {
  margin-bottom: 10px;
  line-height: 1.8;
}

.faq-ordered-list {
  margin: 15px 0;
  padding-left: 25px;
}

.faq-ordered-list li {
  margin-bottom: 10px;
  line-height: 1.8;
}

/* 注釈 */
.faq-note {
  margin-top: 15px;
  padding: 10px 15px;
  background-color: #fff3cd;
  border-left: 4px solid #ffc107;
  font-size: 14px;
  color: #856404;
}

/* 次のページへのリンク */
.faq-next-link {
  text-align: center;
  margin-top: 60px;
  padding-top: 40px;
  border-top: 2px solid var(--color-border-gray);
  overflow: visible;
}

.faq-next-link .btn-new {
  position: relative;
}

.faq-next-link .btn-new a {
  position: relative;
  text-decoration: none;
}

.faq-next-link .btn-new a::before {
  content: '';
  position: absolute;
  bottom: -7px;
  right: -7px;
  width: 100%;
  height: 2px;
  background-color: #bbbbbb;
  transition: 0.2s ease 0s;
}

.faq-next-link .btn-new a::after {
  content: '';
  position: absolute;
  top: 7px;
  right: -7px;
  width: 2px;
  height: 100%;
  background-color: #bbbbbb;
  transition: 0.2s ease 0.2s;
}

.faq-next-link .btn-new a:hover::before {
  width: 0%;
}

.faq-next-link .btn-new a:hover::after {
  height: 0%;
}

/* レスポンシブデザイン */
@media screen and (max-width: 767px) {
  .recruit-faq-section {
    padding: 40px 20px 80px;
    margin: 0 auto;
  }

  .recruit-faq-section .container {
    margin: 0 auto;
    padding: 0;
  }

  .faq-main-title {
    font-size: 36px;
  }

  .faq-sub-title {
    font-size: 20px;
  }

  .faq-question-header {
    padding: 20px 15px;
    flex-wrap: wrap;
  }

  .faq-q-icon {
    width: 35px;
    height: 35px;
    min-width: 35px;
    font-size: 18px;
    margin-right: 15px;
    padding-bottom: 3.5px;
  }

  .faq-question {
    font-size: 16px;
    flex: 1;
    min-width: 0;
    word-wrap: break-word;
    overflow-wrap: break-word;
  }

  .faq-toggle {
    width: 28px;
    height: 28px;
    min-width: 28px;
    margin-left: 10px;
  }

  .faq-toggle-icon {
    font-size: 18px;
    transform: translateY(1px);
  }

  .faq-answer-wrapper {
    padding: 0 15px;
  }

  .faq-item.active .faq-answer-wrapper {
    padding: 15px 15px;
  }

  .faq-a-icon {
    width: 35px;
    height: 35px;
    min-width: 35px;
    font-size: 18px;
    padding-bottom: 3.5px;
  }

  .faq-answer {
    font-size: 14px;
    line-height: 1.8;
    word-wrap: break-word;
    overflow-wrap: break-word;
  }

  .faq-answer p {
    word-wrap: break-word;
    overflow-wrap: break-word;
  }

  .faq-answer a {
    word-wrap: break-word;
    overflow-wrap: break-word;
    word-break: break-all;
  }
}

