/* farmers.css - Nyuts farmers single style - 2025.11.10修正版 */

:root {
  --ny-accent: #4C9D81;
  --text: #473c34;
  --muted: #8e8a86;
}

body.single-farmers {
  background: #F9F8F5;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.site-main.farmers-single {
  padding: 2rem 0;
}

.page-title {
  font-size: 2.2rem;
  color: var(--ny-accent);
  margin: 2rem 1rem 0;
  font-weight: 600;
}

/* ============================================
   メイン画像セクション
   ============================================ */

.section-hero {
  background: transparent;
  padding: 0 0 3rem 0;
}

.hero-image-wrapper {
  position: relative;
  width: 90%;
  margin: 0 auto 3rem;
}

.hero-image-card {
  position: relative;
  width: 100%;
  background: transparent;
}

.hero-image-card img {
  width: 100%;
  border-radius: 20px;
  border-bottom-right-radius: 0;
  object-fit: cover;
  display: block;
}

.hero-image-card::after {
  content: "";
  position: absolute;
  bottom: -20px;
  right: -20px;
  width: 100px;
  height: 100px;
  background: transparent;
  border-top-left-radius: 50%;
  z-index: 1;
}

.card-button {
  display: none !important;
}

/* バッジタグ */
.badge-tags {
  position: relative;
  bottom: auto;
  left: auto;
  display: flex;
  flex-wrap: wrap;
  gap: 0.625rem;
  list-style: none;
  padding: 1rem 0 0 0;
  margin: 0;
}

.badge-tags li {
  text-transform: uppercase;
  font-weight: 700;
  font-size: 0.75rem;
  padding: 0.375rem 0.75rem;
  border-radius: 3px;
  background: #d3b19a;
  color: #6b5344;
}

.badge-tags li.low-pesticide {
  background: #70B3B1;
  color: #fff;
}

.badge-tags li.free-cultivation {
  background: #d3b19a;
  color: #6b5344;
}

.badge-tags li.organic {
  background: #d3b19a;
  color: #6b5344;
}

.badge-tags li.eco {
  background: #d05fa2;
  color: #fff;
}

/* メイン情報 */
.hero-info {
  text-align: left;
  margin-top: 1.5rem;
  background: transparent;
  padding: 0;
  width: 90%;
  margin-left: auto;
  margin-right: auto;
}

.hero-subtitle {
  font-size: 0.9rem;
  color: var(--muted);
  margin-bottom: 0.5rem;
}

.hero-title {
  font-size: 1.6rem;
  color: var(--ny-accent);
  margin: 0.5rem 0 1.5rem;
  font-weight: 600;
}

.hero-intro {
  color: var(--text);
  line-height: 1.8;
  font-size: 0.95rem;
  margin: 0;
}

/* ============================================
   2カラムブロック　基本情報＋Google Map
   ============================================ */

.section-info {
  background: #fff;
  padding: 2rem;
  border-radius: 8px;
  margin-bottom: 3rem;
}

.info-grid {
  display: grid;
  grid-template-columns: 40% 60%;
  gap: 3rem;
}

@media (max-width: 900px) {
  .info-grid {
    grid-template-columns: 1fr;
  }
}

.info-left h2 {
  font-size: 1.05rem;
  color: var(--ny-accent);
  margin-bottom: 0.8rem;
  font-weight: 600;
}

.info-table {
  width: 100%;
  border-collapse: collapse;
}

.info-table tr {
  border-bottom: 1px dashed #eee;
}

.info-table th {
  text-align: left;
  padding: 0.45rem 0;
  font-weight: 600;
  color: var(--text);
  font-size: 0.95rem;
  width: 100px;
}

.info-table td {
  padding: 0.45rem 0;
  color: var(--text);
  font-size: 0.95rem;
}

.info-table a {
  color: #70B3B1;
  text-decoration: none;
}

.info-table a:hover {
  text-decoration: underline;
}

.socials {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid #eee;
}

.socials h3 {
  font-size: 1.05rem;
  color: var(--ny-accent);
  margin-bottom: 0.8rem;
  font-weight: 600;
}

.social-links {
  display: flex;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.social-links .sbtn {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.5rem 0.8rem;
  background: #fff;
  border: 1px solid #e9e9e9;
  border-radius: 8px;
  color: var(--text);
  text-decoration: none;
  font-size: 0.9rem;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.03);
  transition: all 0.3s;
}

.social-links .sbtn i {
  color: var(--ny-accent);
  font-size: 1rem;
}


/* box自体にもホバー効果を適用して、変化を同時に見せる */
a.sbtn:hover {
  background-color: #70b3b1;
  color:#F9F8F5;
}

a.sbtn:hover i {
  color: #F9F8F5;
}

.info-right h3 {
  font-size: 1.05rem;
  color: var(--ny-accent);
  margin-bottom: 1rem;
  font-weight: 600;
}

.farm-map iframe,
.farm-map .acf-map {
  width: 100%;
  height: 450px;
  border-radius: 6px;
  border: none;
}

.muted {
  color: var(--muted);
}

/* ============================================
     ギャラリー - 右下凹み＋ボタンカードスタイル（3列）
   ============================================ */

.section-gallery {
  background: #fff;
  padding: 2rem;
  border-radius: 8px;
  margin-bottom: 3rem;
}

.section-gallery h2 {
  font-size: 1.05rem;
  color: var(--ny-accent);
  margin-bottom: 1.5rem;
  font-weight: 600;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

@media (max-width: 1024px) {
  .gallery-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
  }
}

@media (max-width: 768px) {
  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.2rem;
  }
}

@media (max-width: 480px) {
  .gallery-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
}

/* ギャラリーアイテム */
.gallery-item {
  position: relative;
}

.gallery-link {
  display: block;
  text-decoration: none;
}

/* カード内部（画像を包む） */
.gallery-card-inner {
  position: relative;
  width: 100%;
  height: 14rem;
  background: #fff;
  border-radius: 1.25rem;
  border-bottom-right-radius: 0;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

/* 画像コンテナ */
.gallery-card {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.gallery-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease;
}

.gallery-item:hover .gallery-card img {
  transform: scale(1.05);
}

/* 右下の装飾背景 */
.gallery-card-inner::before {
  content: "";
  position: absolute;
  bottom: -0.375rem;
  right: -0.375rem;
  width: 3.4rem;
  height: 3.4rem;
  background: white;
  border-top-left-radius: 50%;
  z-index: 1;
}

.gallery-card-inner::after {
  content: "";
  position: absolute;
  bottom: -0.375rem;
  right: -0.375rem;
  width: 3.4rem;
  height: 3.4rem;
  background: transparent;
  border-top-left-radius: 50%;
  box-shadow: inset 0.313rem 0.313rem 0 0.313rem #fff;
  z-index: 2;
}

/* ボタン */
.gallery-button {
  position: absolute;
  bottom: 0.4rem;
  right: 0.4rem;
  width: 2rem;
  height: 2rem;
  background: #4C9D81;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 3;
  box-shadow: 0 3px 10px rgba(112, 179, 177, 0.3);
  transition: all 0.3s ease;
}

.gallery-button:hover {
  transform: scale(1.1);
  box-shadow: 0 4px 14px rgba(112, 179, 177, 0.4);
}

.gallery-button svg {
  width: 1.2rem;
  height: 1.2rem;
  color: #fff;
  transition: transform 0.3s ease;
}

.gallery-item:hover .gallery-button svg {
  transform: translateX(2px);
}

/* ============================================
   Hub Store - 右下凹み＋ボタンカードスタイル
   ============================================ */

.section-hubs {
  background: #fff;
  padding: 2rem;
  border-radius: 8px;
  margin-bottom: 3rem;
}

.section-hubs h2 {
  font-size: 1.05rem;
  color: var(--ny-accent);
  margin-bottom: 1.5rem;
  font-weight: 600;
}

.hubs-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

@media (max-width: 900px) {
  .hubs-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
  }
}

@media (max-width: 480px) {
  .hubs-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
}

/* Hub　Storeカードリンク */
.hub-card-link {
  text-decoration: none;
  color: inherit;
  display: block;
}

/* カード内部 */
.hub-card-inner {
  position: relative;
  width: 100%;
  height: 13rem;
  background: #fff;
  border-radius: 1.25rem;
  border-bottom-right-radius: 0;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

/* 画像 */
.hub-card {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.hub-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease;
}

.hub-card-link:hover .hub-card img {
  transform: scale(1.05);
}

/* 装飾 */
.hub-card-inner::before {
  content: "";
  position: absolute;
  bottom: -0.375rem;
  right: -0.375rem;
  width: 3.4rem;
  height: 3.4rem;
  background: #fff;
  border-top-left-radius: 50%;
  z-index: 1;
}

.hub-card-inner::after {
  content: "";
  position: absolute;
  bottom: -0.375rem;
  right: -0.375rem;
  width: 3.4rem;
  height: 3.4rem;
  background: transparent;
  border-top-left-radius: 50%;
  box-shadow: inset 0.313rem 0.313rem 0 0.313rem #fff;
  z-index: 2;
}

/* ボタン */
.hub-button {
  position: absolute;
  bottom: 0.4rem;
  right: 0.4rem;
  width: 2rem;
  height: 2rem;
  background: #70B3B1;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 3;
  box-shadow: 0 3px 10px rgba(154, 201, 132, 0.3);
  transition: all 0.3s ease;
}

.hub-button:hover {
  transform: scale(1.1);
  box-shadow: 0 4px 14px rgba(154, 201, 132, 0.4);
}

.hub-button svg {
  width: 1.2rem;
  height: 1.2rem;
  color: #fff;
  transition: transform 0.3s ease;
}

.hub-card-link:hover .hub-button svg {
  transform: translateX(2px);
}

.hub-name {
  margin-top: 0.625rem;
  color: var(--text);
  font-size: 0.85rem;
  text-align: center;
  font-weight: 500;
}

/* ============================================
   商品一覧 - 右下凹み＋ボタンカードスタイル
   ============================================ */

.section-products {
  background: #fff;
  padding: 2rem;
  border-radius: 8px;
  margin-bottom: 3rem;
}

.section-products h2 {
  font-size: 1.05rem;
  color: var(--ny-accent);
  margin-bottom: 1.5rem;
  font-weight: 600;
}

.products-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

@media (max-width: 900px) {
  .products-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
  }
}

@media (max-width: 480px) {
  .products-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
}

/* 商品カードリンク */
.prod-card-link {
  text-decoration: none;
  color: inherit;
  display: block;
}

/* カード内部 */
.prod-card-inner {
  position: relative;
  width: 100%;
  height: 13rem;
  background: #fff;
  border-radius: 1.25rem;
  border-bottom-right-radius: 0;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

/* 画像 */
.prod-card {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.prod-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease;
}

.prod-card-link:hover .prod-card img {
  transform: scale(1.05);
}

/* 装飾 */
.prod-card-inner::before {
  content: "";
  position: absolute;
  bottom: -0.375rem;
  right: -0.375rem;
  width: 3.4rem;
  height: 3.4rem;
  background: white;
  border-top-left-radius: 50%;
  z-index: 1;
}

.prod-card-inner::after {
  content: "";
  position: absolute;
  bottom: -0.375rem;
  right: -0.375rem;
  width: 3.4rem;
  height: 3.4rem;
  background: transparent;
  border-top-left-radius: 50%;
  box-shadow: inset 0.313rem 0.313rem 0 0.313rem #fff;
  z-index: 2;
}

/* ボタン */
.prod-button {
  position: absolute;
  bottom: 0.4rem;
  right: 0.4rem;
  width: 2rem;
  height: 2rem;
  background: #FFC509;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 3;
  box-shadow: 0 3px 10px rgba(255, 197, 9, 0.3);
  transition: all 0.3s ease;
}

.prod-button:hover {
  transform: scale(1.1);
  box-shadow: 0 4px 14px rgba(255, 197, 9, 0.4);
}

.prod-button svg {
  width: 1.2rem;
  height: 1.2rem;
  color: #fff;
  transition: transform 0.3s ease;
}

.prod-card-link:hover .prod-button svg {
  transform: translateX(2px);
}

.prod-name {
  margin-top: 0.625rem;
  color: var(--text);
  font-size: 0.85rem;
  text-align: center;
  font-weight: 500;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

/* ========================================
   farmers.css - スマホレイアウト修正版
   2025.11.10 - モバイル対応改善
   ======================================== */

/* ========================================
   ① main.site-main の幅制御修正
   PC: 変更なし / スマホ: padding削減
   ======================================== */

@media (max-width: 768px) {
  main.site-main {
    width: 100%;
    max-width: 100%;
    margin: 0;
    padding: 1.5rem 1rem;
  }
}

@media (max-width: 480px) {
  main.site-main {
    padding: 1rem 0.75rem;
  }
}

/* ========================================
   ② section-info のパディング・マージン削減
   ========================================= */

@media (max-width: 768px) {
  .section-info {
    padding: 1.5rem 1rem;
    margin-bottom: 2rem;
    border-radius: 4px;
  }

  .info-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
}

@media (max-width: 480px) {
  .section-info {
    padding: 1rem 0.75rem;
  }

  .info-table th,
  .info-table td {
    font-size: 0.85rem;
    padding: 0.35rem 0;
  }

  .info-table th {
    width: 80px;
  }
}

/* 地図の高さ調整 */
@media (max-width: 768px) {
  .farm-map iframe,
  .farm-map .acf-map {
    height: 300px;
  }
}

@media (max-width: 480px) {
  .farm-map iframe,
  .farm-map .acf-map {
    height: 250px;
  }
}

/* ========================================
   ③ ギャラリー・スライダー化
   水平スクロール対応
   ========================================= */

@media (max-width: 768px) {
  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.2rem;
  }

  .section-gallery {
    padding: 1.5rem 1rem;
  }
}

@media (max-width: 480px) {
  /* スマホは水平スクロール対応に変更 */
  .section-gallery {
    padding: 1rem 0;
    overflow: visible;
  }

  .gallery-grid {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    gap: 1rem;
    padding: 0.5rem 1.5rem;
    scroll-snap-type: x mandatory;
    /* iOSスムーズスクロール */
    -webkit-overflow-scrolling: touch;
    /* スクロールバー非表示（スタイリング） */
    scrollbar-width: thin;
    scrollbar-color: var(--ny-accent) transparent;
  }

  /* Webkit系ブラウザのスクロールバーカスタマイズ */
  .gallery-grid::-webkit-scrollbar {
    height: 4px;
  }

  .gallery-grid::-webkit-scrollbar-track {
    background: transparent;
  }

  .gallery-grid::-webkit-scrollbar-thumb {
    background: var(--ny-accent);
    border-radius: 2px;
  }

  .gallery-item {
    flex: 0 0 calc(85vw - 2rem);
    scroll-snap-align: start;
    scroll-snap-stop: always;
    min-width: 0;
  }

  .gallery-card-inner {
    height: 16rem;
  }

  .section-gallery h2 {
    margin-bottom: 1rem;
    padding: 0 1.5rem;
  }
}

/* ========================================
   ④ Hub Store・Products もスマホで調整
   ========================================= */

@media (max-width: 768px) {
  .section-hubs,
  .section-products {
    padding: 1.5rem 1rem;
    margin-bottom: 2rem;
  }

  .hubs-grid,
  .products-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.2rem;
  }
}

@media (max-width: 480px) {
  .section-hubs,
  .section-products {
    padding: 1rem 0.75rem;
  }

  .hubs-grid,
  .products-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .hub-card-inner,
  .prod-card-inner {
    height: 14rem;
  }

  .section-hubs h2,
  .section-products h2 {
    padding: 0 0.75rem;
  }
}

/* ========================================
   ⑤ ヒーロー画像セクションの幅調整
   ========================================= */

@media (max-width: 768px) {
  .hero-image-wrapper {
    width: 100%;
    margin: 0 auto 2rem;
  }

  .section-hero {
    padding: 0 0 2rem 0;
  }

  .hero-info {
    width: 100%;
    margin-left: 0;
    margin-right: 0;
    padding: 0 1rem;
  }
}

@media (max-width: 480px) {
  .hero-image-wrapper {
    margin: 0 auto 1.5rem;
  }

  .hero-info {
    padding: 0 0.75rem;
  }

  .hero-title {
    font-size: 1.3rem;
  }

  .hero-intro {
    font-size: 0.9rem;
  }

  .badge-tags {
    padding: 0.75rem 0 0 0;
    gap: 0.5rem;
  }

  .badge-tags li {
    font-size: 0.65rem;
    padding: 0.3rem 0.6rem;
  }
}