@charset "UTF-8";

/* ==========================================================================
   Base
   ========================================================================== */
:root {
  --c-brown: #5c3509;
  --c-green: #216e00;
  --c-yellow: #f3f33e;
  --c-cream: #fffdf2;
  --c-note: #4a0c0c;
  --c-gray: #d9d9d9;
  --c-line: rgba(92, 53, 9, 0.47);

  --container: 1140px;
  --gutter: 16px;
  --fz-body: clamp(15px, 0.9rem + 0.3vw, 18px);
  --fz-h2: clamp(24px, 1rem + 1.6vw, 36px);
  --sec-pt: clamp(56px, 6vw, 90px);
  --title-mb: clamp(32px, 4vw, 60px);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}

body {
  margin: 0;
  background: var(--c-cream);
  color: var(--c-brown);
  font-family: "Noto Sans JP", "Hiragino Kaku Gothic ProN", "Hiragino Sans", Meiryo, sans-serif;
  font-size: var(--fz-body);
  font-weight: 500;
  line-height: 1.5;
  overflow-wrap: anywhere;
  line-break: strict;
}

h1, h2, h3, p, ul, ol, figure {
  margin: 0;
}

ul, ol {
  padding: 0;
  list-style: none;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: inherit;
}

button {
  font: inherit;
  color: inherit;
  cursor: pointer;
}

:focus-visible {
  outline: 3px solid var(--c-green);
  outline-offset: 3px;
}

address {
  font-style: normal;
}

/* ==========================================================================
   Utility
   ========================================================================== */
.u-visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.u-sp {
  display: none;
}

@media (max-width: 767px) {
  .u-pc {
    display: none;
  }

  .u-sp {
    display: inline;
  }
}

/* ==========================================================================
   Layout
   ========================================================================== */
.l-container {
  width: 100%;
  max-width: calc(var(--container) + var(--gutter) * 2);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.l-container--narrow {
  max-width: calc(900px + var(--gutter) * 2);
}

/* 見出し（左右に罫線） */
.c-title {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(12px, 2vw, 20px);
  margin-bottom: var(--title-mb);
  font-size: var(--fz-h2);
  font-weight: 700;
  line-height: 1.39;
  text-align: center;
  white-space: nowrap;
}

.c-title::before,
.c-title::after {
  content: "";
  flex: 0 1 240px;
  min-width: 24px;
  height: 1px;
  background: var(--c-line);
}

/* ==========================================================================
   Header / Hero
   ========================================================================== */
.l-header {
  padding-top: clamp(16px, 2.3vw, 33px);
  background: #fff;
}

/* ページトップボタンからのフォーカス移動先（枠は表示しない） */
.l-header:focus {
  outline: none;
}

.hero__lead {
  margin-bottom: clamp(12px, 2vw, 30px);
  font-size: clamp(12px, 0.6rem + 0.6vw, 18px);
  font-weight: 700;
  line-height: 1.5;
  letter-spacing: 0.1em;
}

.hero__title img {
  width: 100%;
  border-radius: clamp(12px, 2.1vw, 30px);
}

/* ==========================================================================
   About
   ========================================================================== */
.about {
  padding-block: var(--sec-pt) clamp(56px, 6vw, 90px);
  background: #fff;
  text-align: center;
}

.about__title {
  font-size: var(--fz-h2);
  font-weight: 700;
  line-height: 1.39;
}

.about__badge {
  max-width: 800px;
  margin: 30px auto 0;
  padding: clamp(14px, 2vw, 26px) 16px clamp(12px, 1.2vw, 17px);
  border-radius: 10px;
  background: var(--c-yellow);
}

.about__badge-main {
  color: var(--c-green);
  font-size: clamp(20px, 0.8rem + 1.7vw, 36px);
  font-weight: 700;
  line-height: 1.39;
}

.about__badge-note {
  color: var(--c-note);
  font-size: clamp(13px, 0.7rem + 0.3vw, 18px);
  line-height: 1.5;
}

.about__body {
  margin-top: clamp(40px, 4vw, 60px);
  line-height: 2;
}

.about__body p + p {
  margin-top: 2em;
}

@media (max-width: 767px) {
  .about__badge-sep {
    display: none;
  }

  .about__body {
    text-align: left;
  }
}

/* ==========================================================================
   Flow
   ========================================================================== */
.flow {
  position: relative;
  padding-top: calc(clamp(24px, 7.1vw, 102px) + 16px);
  padding-bottom: 40px;
}

/* 上端の波 */
.flow::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: clamp(24px, 7.1vw, 102px);
  background: #fff url("../images/common/wave.svg") no-repeat center bottom / 100% 100%;
}

.flow .c-title {
  margin-bottom: clamp(40px, 4vw, 57px);
}

.flow__list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 30px;
}

.flow__item {
  position: relative;
  margin-top: 25px;
  padding: 0 15px 23px;
  border-radius: 30px;
  background: #fff;
}

.flow__num {
  position: absolute;
  top: -25px;
  left: 0;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 100px;
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--c-green);
  color: #fff;
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-size: 24px;
  font-weight: 700;
  line-height: 1;
}

.flow__img {
  width: calc(100% + 30px);
  max-width: none;
  margin: -4px -15px 0;
}

.flow__title {
  margin: 26px 0 0;
  color: var(--c-green);
  font-size: 24px;
  font-weight: 700;
  line-height: 50px;
  text-align: center;
}

.flow__text {
  line-height: 1.5;
}

.flow__text + .flow__text {
  margin-top: 10px;
}

@media (max-width: 1023px) {
  .flow__list {
    gap: 20px;
  }

  .flow__num {
    width: 80px;
    font-size: 20px;
  }

  .flow__title {
    font-size: 20px;
    line-height: 1.6;
  }
}

@media (max-width: 767px) {
  .flow__list {
    grid-template-columns: minmax(0, 1fr);
    gap: 24px;
    max-width: 420px;
    margin-inline: auto;
  }

  .flow__num {
    width: 72px;
    font-size: 18px;
  }

  .flow__title {
    margin-top: 12px;
  }
}

/* ==========================================================================
   Target
   ========================================================================== */
.target {
  padding-top: clamp(56px, 5vw, 70px);
}

.target__lead {
  margin-bottom: 30px;
}

.target__list li {
  position: relative;
  padding-left: 36px;
}

.target__list li + li {
  margin-top: 1.5em;
}

.target__list li::before {
  content: "";
  position: absolute;
  top: calc((1.7em - 30px) / 2);
  left: 0;
  width: 30px;
  height: 30px;
  background: url("../images/common/icon_check.svg") no-repeat center / contain;
}

.target__note {
  margin-top: 34px;
  padding-left: 1em;
  text-indent: -1em;
}

@media (max-width: 767px) {
  .target__list li {
    padding-left: 32px;
  }

  .target__list li::before {
    width: 24px;
    height: 24px;
    top: calc((1.7em - 24px) / 2);
  }
}

/* ==========================================================================
   Farms（体験先・日程）
   ========================================================================== */
.farms {
  padding-top: clamp(56px, 6vw, 91px);
  overflow-x: clip;
}

.farms .c-title {
  margin-bottom: clamp(32px, 4vw, 52px);
}

.farms__carousel {
  --card-w: 360px;
  --card-gap: 30px;
  --edge: 70px;
  --arrow-top: 229px;
  position: relative;
}

.farms__track {
  display: flex;
  align-items: flex-start;
  gap: var(--card-gap);
  padding: 9px max(var(--gutter), (100% - var(--container)) / 2) 24px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: max(var(--gutter), (100% - var(--container)) / 2);
  scrollbar-width: none;
  overscroll-behavior-x: contain;
}

.farms__track::-webkit-scrollbar {
  display: none;
}

/* JS有効時：ループカルーセル（transform で移動、現在のカードを中央表示） */
.js .farms__track {
  padding-inline: 0;
  overflow: visible;
  scroll-snap-type: none;
  touch-action: pan-y;
  cursor: grab;
  user-select: none;
  -webkit-user-select: none;
}

.js .farms__track.is-animating {
  transition: transform 0.6s ease;
}

.js .farms__track.is-dragging {
  cursor: grabbing;
}

.farm-card.is-clone .farm-card__btn {
  cursor: pointer;
}

/* 左右の帯（デザインの Rectangle 19/20） */
.farms__carousel::before,
.farms__carousel::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  z-index: 1;
  width: var(--edge);
  background: var(--c-cream);
  pointer-events: none;
}

.farms__carousel::before {
  left: 0;
}

.farms__carousel::after {
  right: 0;
}

.farm-card {
  flex: 0 0 var(--card-w);
  display: flex;
  flex-direction: column;
  min-height: 500px;
  padding: 16px 15px 18px;
  border-radius: 30px;
  background: #fff;
  box-shadow: 0 0 4px rgba(0, 0, 0, 0.25);
  scroll-snap-align: start;
  user-select: text;
  -webkit-user-select: text;
}

/* 詳細を閉じた状態の高さを全カードで統一（高さは main.js で算出） */
.js .farm-card {
  min-height: var(--farm-card-h, 500px);
}

.farm-card__photo {
  aspect-ratio: 330 / 240;
  margin-bottom: 15px;
  border-radius: 20px;
  overflow: hidden;
  background: var(--c-gray);
}

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

.farm-card__name,
.farm-card__meta,
.farm-card__date,
.farm-card__desc,
.farm-card__point {
  font-size: var(--fz-body);
  font-weight: 500;
  line-height: 1.5;
}

.farm-card__name {
  font-size: calc(var(--fz-body) + 3px);
  font-weight: 700;
}

/* JS有効時は main.js で上余白を調整し、全カードの開始位置を揃える */
.farm-card__point {
  margin-top: 20px;
}

.farm-card__btn {
  position: relative;
  display: block;
  width: 160px;
  height: 50px;
  margin: auto auto 0;
  padding: 0 20px 0 0;
  border: 0;
  border-radius: 25px;
  background: var(--c-green);
  color: #fff;
  font-size: 18px;
  font-weight: 700;
  line-height: 50px;
  transition: opacity 0.2s;
}

/* JS有効時は main.js でボタン上余白を調整し、全カードのボタン位置を揃える */
.farm-card__point + .farm-card__btn {
  margin-top: 22px;
}

.farm-card__btn::after {
  content: "";
  position: absolute;
  top: 50%;
  right: 12px;
  width: 44px;
  height: 44px;
  margin-top: -22px;
  background: url("../images/common/icon_arrow.svg") no-repeat center / contain;
  transform: rotate(90deg);
  transition: transform 0.3s;
}

.farm-card__btn[aria-expanded="true"]::after {
  transform: rotate(-90deg);
}

@media (hover: hover) {
  .farm-card__btn:hover {
    opacity: 0.8;
  }
}

.farm-card__detail {
  overflow: hidden;
}

.farm-card__detail > p {
  padding-top: 28px;
  line-height: 1.5;
}

.farms__arrow {
  position: absolute;
  top: var(--arrow-top);
  z-index: 2;
  width: 50px;
  height: 50px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: var(--c-green) url("../images/common/icon_arrow.svg") no-repeat center / 60px;
  box-shadow: 0 0 4px rgba(0, 0, 0, 0.25);
  transition: opacity 0.2s;
}

.farms__arrow--prev {
  left: 5px;
  transform: scaleX(-1);
}

.farms__arrow--next {
  right: 5px;
}

.farms__arrow:disabled {
  opacity: 0.35;
  cursor: default;
}

@media (max-width: 1279px) {
  .farms__carousel {
    --edge: 0px;
  }
}

@media (max-width: 767px) {
  .farms__carousel {
    --card-w: min(calc(100vw - 72px), 330px);
    --card-gap: 16px;
    --arrow-top: calc((min(calc(100vw - 72px), 330px) - 30px) * 240 / 330 / 2 + 9px);
  }

  .farms__track {
    padding-inline: 36px;
    scroll-padding-inline: 36px;
  }

  .farm-card {
    min-height: 0;
  }

  .farms__arrow {
    width: 40px;
    height: 40px;
    background-size: 48px;
  }

  .farms__arrow--prev {
    left: 2px;
  }

  .farms__arrow--next {
    right: 2px;
  }
}

/* ==========================================================================
   Entry（お申し込み）
   ========================================================================== */
.entry {
  padding-block: clamp(40px, 5vw, 64px) clamp(80px, 10vw, 150px);
}

.entry .c-title {
  margin-bottom: clamp(32px, 4vw, 63px);
}

/* フォームは別ドメインのため高さを自動取得できない。
   画面幅ごとの実測値（フォーム内の縦スクロールが出ない高さ）＋エラー表示分の余白で指定 */
.entry__iframe {
  display: block;
  width: 100%;
  height: 3900px;
  border: 0;
}

/* フォーム側は iframe 幅 800px 前後でスマホレイアウトに切り替わる（実測：幅600〜832px で 4686〜4821px） */
@media (max-width: 832px) {
  .entry__iframe {
    height: 5000px;
  }
}

/* 実測：幅430px で 5280px */
@media (max-width: 599px) {
  .entry__iframe {
    height: 5450px;
  }
}

/* 実測：幅360px で 5768px */
@media (max-width: 429px) {
  .entry__iframe {
    height: 5950px;
  }
}

/* 実測：幅320px で 6164px */
@media (max-width: 359px) {
  .entry__iframe {
    height: 6350px;
  }
}

/* ==========================================================================
   Page top
   ========================================================================== */
.pagetop {
  position: fixed;
  right: clamp(12px, 1.4vw, 20px);
  bottom: clamp(12px, 1.4vw, 20px);
  z-index: 10;
  width: clamp(56px, 5.6vw, 80px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--c-green) url("../images/common/icon_arrow.svg") no-repeat center / 75%;
  box-shadow: 0 0 4px rgba(0, 0, 0, 0.25);
  transform: rotate(-90deg);
  transition: opacity 0.3s, visibility 0.3s;
}

.js .pagetop:not(.is-visible) {
  opacity: 0;
  visibility: hidden;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.l-footer__soil {
  /* 土の画像は波形に切り抜き済みの透過画像（CSS mask はブラウザ差が出るため不使用） */
  height: max(32px, 100vw * 100 / 1440);
  background: url("../images/common/footer_soil.webp") no-repeat center bottom / 100% 100%;
}

.l-footer__inner {
  margin-top: -1px;
  padding: clamp(32px, 3.6vw, 52px) 0 22px;
  background: var(--c-green);
  color: #fff;
}

.l-footer__logo img {
  width: min(310px, 70vw);
}

.l-footer__address {
  margin-top: 15px;
  font-size: clamp(13px, 0.7rem + 0.2vw, 16px);
  line-height: 1.5;
}

.l-footer__address a {
  text-decoration: none;
}

.l-footer__copy {
  margin-top: clamp(24px, 2.3vw, 33px);
  text-align: center;
  font-size: clamp(12px, 0.7rem + 0.2vw, 16px);
  line-height: 1.5;
}

.l-footer__copy small {
  font-size: inherit;
}

@media (max-width: 767px) {
  /* 固定のページトップボタンと重ならないよう下に余白 */
  .l-footer__inner {
    padding-bottom: 84px;
  }
}
