/* メインの要素を真ん中によせます */
main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  box-sizing: border-box;
}

/* 各セクション間の余白を統一 */
.hajimete-all > div {
  margin-bottom: 80px;
}

.hajimete-all > div:last-child {
  margin-bottom: 0;
}

/* ヒーロー画像 */
.member-hero {
  display: flex;
  align-items: center;
  justify-content: center;
  background-image: url(../image/img_member/hero2.jpg);
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  padding: 200px 20px;
  margin-bottom: 60px;
}

.member-hero h1 {
  color: white;
  font-size: 48px;
  text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
  font-family: "Noto Serif JP", "Hiragino Mincho ProN", "Yu Mincho", serif;
}

.hajimete-custom {
  margin: 20px auto;
  max-width: 1000px;
  padding: 16px;
  background: rgba(255, 255, 255, 0.6);
  border-radius: 12px;
}

/* 追記　初めての方　ヒーロー */
.hajimete-hero {
  display: flex;
  align-items: center;
  justify-content: center;
  background-image: url(../image/img_hajimete/hero2.jpg);
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  padding: 200px 20px;
  margin-bottom: 60px;
}

.hajimete-hero h1 {
  color: white;
  font-size: 48px;
  text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
  font-family: "Noto Serif JP", "Hiragino Mincho ProN", "Yu Mincho", serif;
  margin-top: -100px; /* 追記 */
}

/* h2タイトル */
.htitle {
  display: flex;
  align-items: center;
  font-size: clamp(1.5rem, 2vw, 1.8rem);
  position: relative;
  max-width: 97%;
  box-sizing: border-box;
  color: #754b21;
  margin: 0 auto 30px;
  padding: 0 10px;
}

.htitle::after {
  content: "";
  flex: 1;
  margin-left: 10px;
  border-bottom: 2px solid #754b21;
}

.htitle_osusume {
  margin-bottom: 40px;
}

/* 全部を中央寄せ */
.hajimete-all > div {
  margin: 0 auto 80px;
  max-width: 1000px;
  padding: 0 10px;
}

/* 【派遣のしくみ】 */
.shikumi {
  width: calc(100% + 40px);
  background-color: #ffe4b3;
  border-radius: 0 70px;
  padding: 0 60px;
  padding-bottom: 100px;
  box-sizing: border-box;
  margin-left: -20px;
  margin-right: -20px;
}

.shikumi .js-scroll {
  padding-top: 50px;
}

.shikumi .htitle {
  margin-top: 0;
}

.shikumi-flex-1 {
  display: flex;
  gap: 50px;
  justify-content: center;
  flex-wrap: wrap;
  align-items: center;
  font-size: 115%;
  padding-bottom: 30px;
}

.shikumi-flex-2 {
  width: 390px;
  max-width: 100%;
  text-align: left;
  line-height: 1.8;
}

.shikumi-moji {
  background: linear-gradient(transparent 60%, #f4cc71 60%);
  display: inline;
}

.shikumi-flex-3 {
  flex-shrink: 0;
}

.shikumi-flex-3 img {
  width: 350px;
  max-width: 100%;
  height: auto;
  display: block;
  margin: 0 auto;
}

/* 【派遣はどんな方におすすめ?】 */
.osusume {
  margin: 0 auto;
  padding: 40px 20px;
}

.osusume-flex-1 {
  display: flex;
  gap: 50px;
  justify-content: center;
  flex-wrap: wrap;
  align-items: center;
}

.osusume-flex-2 {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
  align-items: center;
}

.osusume-flex-4 img {
  width: 300px;
  max-width: 100%;
  height: auto;
  display: block;
}

.osusume-flex-3 img {
  width: 300px;
  max-width: 100%;
  height: auto;
  display: block;
}

/* 【ユニファーストのおすすめポイント】 */
.unipoint {
  margin: 0 auto;
  width: calc(100% + 40px);
  background-color: #ffe4b3;
  border-radius: 0 70px;
  background-repeat: no-repeat;
  padding: 0 60px;
  padding-bottom: 100px;
  box-sizing: border-box;
  margin-left: -20px;
  margin-right: -20px;
}

.unipoint .js-scroll {
  padding-top: 50px;
}

.unipoint .htitle {
  margin-top: 0;
}

.unipoint-flex-1 {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: nowrap;
  padding-bottom: 30px;
}

.unipoint-flex-2 {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  width: 600px;
  margin: 40px auto 20px;
}

.unipoint-flex-4 img {
  width: 200px;
  height: auto;
  display: block;
}

.unipoint-flex-3 {
  width: 350px;
  justify-content: center;
  line-height: 1.8;
}

.unipoint-moji {
  color: #754b21;
  font-size: 16px;
  font-weight: bold;
  background: linear-gradient(transparent 60%, #f4cc71 60%);
}

/* アニメーション */
.js-scroll {
  opacity: 0;
  transform: translateY(3rem);
  transition: opacity 2s, transform 2s;
}

.js-scroll.is-active {
  opacity: 1;
  transform: translateY(0);
}

.-slidein-right {
  transform: translateX(50px);
}

.-slidein-left {
  transform: translateX(-50px);
}

.-slidein-right.is-active,
.-slidein-left.is-active {
  transform: translateX(0);
  opacity: 1;
}

/* 【よくある質問】 */
.faq {
  padding: 0px 20px 40px;
}

:root {
  --bg: #f4cc71;
  --paper: #fff7ea;
  --ink: #3b2e22;
  --accent: #c28a45;
  --line: #d7b88a;
  --accordion-maxheight-transition: 0.6s;
  --accordion-opacity-transition: 0.36s;
  --accordion-icon-transition: 0.32s;
}

.faq__list {
  list-style: none;
  margin: 30px auto;
  padding: 0;
  max-width: 900px;
}

.faq__item {
  border-bottom: 1px solid var(--line);
  position: relative;
}

.faq__q {
  all: unset;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 0.75rem;
  width: 100%;
  cursor: pointer;
  padding: 14px 44px 14px 14px;
  box-sizing: border-box;
}

.faq__q-label {
  color: var(--accent);
  font-weight: 700;
}

.faq__q-text {
  font-weight: 600;
}

.faq__q::after {
  content: "+";
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 20px;
  transition: transform var(--accordion-icon-transition) ease;
}

.faq__a-wrap {
  background: var(--bg);
  margin: 0 0 12px 0;
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height var(--accordion-maxheight-transition) ease,
              opacity var(--accordion-opacity-transition) ease;
}

.faq__a {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.75rem;
  padding: 12px 14px 14px;
  line-height: 1.6;
}

.faq__a-label {
  font-weight: 700;
}

.faq__item:not(.is-fixed):hover .faq__a-wrap {
  max-height: 400px;
  opacity: 1;
}

.faq__item[aria-expanded="true"] .faq__a-wrap {
  max-height: 600px;
  opacity: 1;
}

.faq__item[aria-expanded="true"] .faq__q::after {
  transform: translateY(-50%) rotate(45deg);
}

/* ★PC幅のみ：本文の上余白 var(--header-h) を打ち消して "かぶせる" */
@media (min-width: 901px) {
  .member-hero {
    margin-top: calc(-1 * var(--header-h));
  }
}

/* モバイル用ヒーロー差し替え */
@media (max-width: 768px) {
  .hajimete-hero {
    background-image: url(../image/img_hajimete/hero1.jpg);
    padding: 100px 20px;
    margin-bottom: 40px;
  }

  .hajimete-hero h1 {
    font-size: clamp(24px, 6vw, 32px);
  }

  /* 各セクション間の余白をスマホ用に調整 */
  .hajimete-all > div {
    margin-bottom: 50px;
  }

  .htitle {
    font-size: clamp(1.3rem, 5vw, 1.5rem);
    margin-bottom: 10px;
  }

  /* 派遣のしくみ */
  .shikumi {
    width: 100%;
    padding: 0 20px;
    padding-bottom: 60px;
    border-radius: 0 40px;
    margin-left: 0;
    margin-right: 0;
  }
  
  .shikumi .js-scroll {
    padding-top: 40px;
  }
  
  .shikumi .htitle {
    margin-top: 0;
  }

  .shikumi-flex-1 {
    gap: 30px;
    padding-bottom: 20px;
  }

  .shikumi-flex-2 {
    width: 100%;
    padding: 0 10px;
    font-size: 100%;
  }

  .shikumi-moji {
    white-space: normal;
  }

  .shikumi-flex-3 img {
    width: 100%;
    max-width: 350px;
    margin-top: 20px;
  }

  /* おすすめセクション */
  .osusume {
    padding: 10px 0px;
  }

  .osusume-flex-1 {
    gap: 10px;
  }

  .osusume-flex-2 {
    gap: 15px;
    width: 100%;
  }

  .osusume-flex-4 img,
  .osusume-flex-3 img {
    width: 100%;
    max-width: 300px;
  }

  .htitle_osusume {
    margin-bottom: 20px;
  }

  /* ユニファーストポイント */
  .unipoint {
    width: 100%;
    padding: 0 20px;
    padding-bottom: 60px;
    border-radius: 0 40px;
    margin-left: 0;
    margin-right: 0;
  }
  
  .unipoint .js-scroll {
    padding-top: 40px;
  }
  
  .unipoint .htitle {
    margin-top: 0;
  }

  .unipoint-flex-1 {
    flex-direction: column;
    padding-bottom: 20px;
  }

  .unipoint-flex-2,
  .unipoint-flex-3 {
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
    box-sizing: border-box;
  }

  .unipoint-flex-3 {
    padding: 0 10px;
    text-align: center;
  }

  .unipoint-flex-4 img {
    width: 95%;
    max-width: 100%;
    height: auto;
    margin: 0 auto;
    display: block;
    object-fit: contain;
  }

  .unipoint-moji {
    font-size: 14px;
  }

  /* FAQ */
  .faq {
    padding: 0px 10px 20px;
  }

  .faq__list {
    margin: 20px 0;
  }

  .faq__q {
    padding: 12px 40px 12px 10px;
    grid-template-columns: auto 1fr;
    gap: 0.5rem;
  }

  .faq__q-text {
    padding-right: 0;
    font-size: 14px;
  }

  .faq__q::after {
    right: 10px;
    font-size: 18px;
  }

  .faq__a {
    padding: 10px 12px 12px;
    font-size: 14px;
    grid-template-columns: auto 1fr;
    gap: 0.5rem;
  }
}