/**
 * Shimada Fruits - メインスタイルシート
 *
 * CSS設計: BEM (block__element--modifier)
 * ブレークポイント: 480px / 768px
 * モバイルファースト: ベースをスマホ幅で書き、min-width で拡張
 *
 * 現行サイトの配色・余白を忠実に再現
 */

/* ==========================================================================
   カスタムプロパティ（現行サイトの配色）
   ========================================================================== */

:root {
    /* 背景色 */
    --color-bg-page: #5daa5d;
    --color-bg-main: #ffffff;
    --color-bg-kodawari: #efffbf;

    /* テキスト */
    --color-text: #000000;
    --color-text-heading: #288e28;
    --color-text-white: #ffffff;

    /* アクセント */
    --color-accent-green: #278d27;
    --color-accent-red: #ff0000;
    --color-accent-red-hover: #f55f5f;

    /* ナビゲーション */
    --color-nav-border: #ac8f58;
    --color-nav-grad-start: #e6ecd6;
    --color-nav-grad-end: #a0b964;
    --color-nav-border-item: #c6c6c6;

    /* フォント */
    --font-family: "メイリオ", Meiryo, "ヒラギノ角ゴ Pro W3", "Hiragino Kaku Gothic Pro", "HiraKakuPro-W3", "ＭＳ Ｐゴシック", "MS PGothic", Arial, Helvetica, sans-serif;

    /* サイズ */
    --width-main: 980px;
    --width-content: 940px;
}

/* ==========================================================================
   リセット・ベース
   ========================================================================== */

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

html {
    font-size: 16px;
}

body {
    font-family: var(--font-family);
    color: var(--color-text);
    background-color: var(--color-bg-page);
    line-height: 1.4;
}

img {
    max-width: 100%;
    height: auto;
    vertical-align: bottom;
}

a {
    color: inherit;
    text-decoration: none;
}

ul,
ol {
    list-style: none;
}

button {
    font: inherit;
    color: inherit;
    background: none;
    border: none;
    cursor: pointer;
}

address {
    font-style: normal;
}

/* ==========================================================================
   サイト全体レイアウト (.site)
   ========================================================================== */

.site {
    max-width: var(--width-main);
    margin: 0 auto;
}

.main {
    background-color: var(--color-bg-main);
    padding: 5px 15px 20px;
}

@media (min-width: 768px) {
    .main {
        padding: 5px 20px 20px;
    }
}

/* ==========================================================================
   ヘッダー (.header)
   ========================================================================== */

.header {
    background-color: var(--color-bg-main);
    padding: 5px 15px;
}

@media (min-width: 768px) {
    .header {
        padding: 5px 20px;
    }
}

.header__inner {
    max-width: var(--width-content);
    margin: 0 auto;
}

/* キャッチコピー */
.header__catchcopy {
    text-align: left;
    width: 85%;
    font-size: 0.75rem;
    margin-bottom: 10px;
}

@media (min-width: 768px) {
    .header__catchcopy {
        text-align: center;
        width: 100%;
        font-size: 0.875rem;
    }
}

/* ロゴ */
.header__logo {
    text-align: center;
    margin-bottom: 10px;
}

.header__logo img {
    max-width: 100%;
    width: 240px;
}

@media (min-width: 768px) {
    .header__logo img {
        width: 359px;
    }
}

/* ハンバーガーボタン */
.header__menu-btn {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 44px;
    height: 44px;
    gap: 6px;
    position: fixed;
    top: 10px;
    right: 10px;
    z-index: 1001;
    background-color: var(--color-accent-green);
    border-radius: 4px;
}

.header__menu-btn-line {
    display: block;
    width: 24px;
    height: 2px;
    background-color: var(--color-text-white);
    transition: transform 0.3s, opacity 0.3s;
}

.header__menu-btn[aria-expanded="true"] .header__menu-btn-line:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

.header__menu-btn[aria-expanded="true"] .header__menu-btn-line:nth-child(2) {
    opacity: 0;
}

.header__menu-btn[aria-expanded="true"] .header__menu-btn-line:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

@media (min-width: 880px) {
    .header__menu-btn {
        display: none;
    }
}

/* ==========================================================================
   ナビゲーション (.nav)
   ========================================================================== */

/* モバイル: スライドインメニュー */
.nav {
    position: fixed;
    top: 0;
    right: -100%;
    width: 80%;
    max-width: 300px;
    height: 100vh;
    background-color: var(--color-bg-main);
    box-shadow: -2px 0 8px rgba(0, 0, 0, 0.2);
    transition: right 0.3s;
    z-index: 1000;
    padding-top: 60px;
    overflow-y: auto;
}

.nav[aria-hidden="false"] {
    right: 0;
}

.nav__list {
    padding: 10px;
}

.nav__item {
    border-bottom: 1px solid var(--color-nav-border-item);
}

.nav__item a {
    display: block;
    padding: 12px 10px;
    font-weight: bold;
}

/* タブレット以上: 横並びナビ（7項目が1行に収まるよう880pxで切替） */
@media (min-width: 880px) {
    .nav {
        position: static;
        width: auto;
        max-width: none;
        height: auto;
        box-shadow: none;
        padding-top: 0;
        overflow-y: visible;
        margin: 10px 0;
    }

    .nav__list {
        display: flex;
        padding: 0;
        border: solid 1px var(--color-nav-border);
    }

    .nav__item {
        flex: 1;
        text-align: center;
        border-bottom: none;
        border-right: solid 1px var(--color-nav-border-item);
    }

    .nav__item:last-child {
        border-right: none;
    }

    .nav__item a {
        display: block;
        padding: 10px;
        border: solid 1px var(--color-nav-border);
        background: linear-gradient(to bottom, var(--color-nav-grad-start), var(--color-nav-grad-end));
    }

    .nav__item a:hover {
        background: linear-gradient(to bottom, var(--color-nav-grad-end), var(--color-nav-grad-start));
    }

    /* 項目ごとの幅調整（現行に合わせる） */
    .nav__item--top,
    .nav__item--order {
        flex: 0 0 auto;
        width: 84px;
    }

    .nav__item--calendar {
        flex: 0 0 auto;
        width: 178px;
    }
}

/* ==========================================================================
   ヒーロー (.hero)
   ========================================================================== */

.hero {
    margin-bottom: 20px;
}

.hero__link {
    display: block;
}

.hero__slides {
    position: relative;
    width: 100%;
    /* アスペクト比: 940 x 345 */
    aspect-ratio: 940 / 345;
    overflow: hidden;
}

.hero__img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 1s ease-in-out;
    z-index: 1;
}

.hero__img--active {
    opacity: 1;
    z-index: 2;
}

/* ==========================================================================
   メインコンテンツ (.content)
   ========================================================================== */

.content__inner {
    max-width: var(--width-content);
    margin: 0 auto;
}

/* 引っ越しのお知らせ */
.notice-relocation {
    margin-bottom: 20px;
    line-height: 1.6;
    font-size: 0.875rem;
}

@media (min-width: 768px) {
    .notice-relocation {
        font-size: 1rem;
    }
}

/* 紹介文 */
.content__intro {
    margin-bottom: 20px;
    line-height: 1.6;
}

/* h2見出し */
.content__heading {
    background-color: var(--color-accent-green);
    color: var(--color-text-white);
    font-size: 1.125rem;
    text-align: center;
    padding: 10px;
    margin: 10px 0;
    border-radius: 20px;
}

@media (min-width: 768px) {
    .content__heading {
        width: 480px;
        font-size: 1.5rem;
    }
}

/* CTAボタン */
.content__cta {
    display: block;
    width: 100%;
    max-width: 300px;
    height: 50px;
    margin: 30px auto;
    background-color: var(--color-accent-red);
    color: var(--color-text-white);
    font-size: 1.25rem;
    font-weight: bold;
    text-align: center;
    line-height: 50px;
    border-radius: 8px;
}

.content__cta:hover {
    background-color: var(--color-accent-red-hover);
}

@media (min-width: 768px) {
    .content__cta {
        font-size: 1.5rem;
    }
}

/* ==========================================================================
   こだわりブロック (.kodawari)
   ========================================================================== */

.kodawari {
    background-color: var(--color-bg-kodawari);
    margin: 10px 0;
    padding: 10px;
    overflow: hidden;
}

.kodawari__title {
    font-size: 1.125rem;
    color: var(--color-text-heading);
    padding: 12px 0 12px 50px;
    background-image: url('../img/check.gif');
    background-size: 40px;
    background-repeat: no-repeat;
    background-position: left center;
    margin-bottom: 10px;
}

@media (min-width: 768px) {
    .kodawari__title {
        font-size: 1.5rem;
        height: 52px;
    }
}

.kodawari__img {
    display: block;
    width: 120px;
    margin: 0 auto 15px;
}

@media (min-width: 768px) {
    .kodawari__img {
        float: left;
        width: 150px;
        margin: 0 40px 0 0;
    }
}

.kodawari__text {
    line-height: 1.6;
}

@media (min-width: 768px) {
    .kodawari__text {
        margin-top: 30px;
    }
}

.kodawari__text a {
    color: var(--color-text-heading);
    text-decoration: underline;
}

/* ==========================================================================
   フッター (.footer)
   ========================================================================== */

.footer {
    background-color: var(--color-bg-main);
    padding: 20px 15px;
    font-size: 0.875rem;
    border-top: 1px solid #ccc;
}

@media (min-width: 768px) {
    .footer {
        padding: 20px;
        font-size: 0.8rem;
    }
}

.footer__inner {
    max-width: var(--width-content);
    margin: 0 auto;
}

/* フッターリンク4カラム */
.footer__links {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

@media (min-width: 480px) {
    .footer__links {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 768px) {
    .footer__links {
        grid-template-columns: repeat(3, 1fr);
        gap: 20px;
    }
}

.footer__col {
    /* 各カラム */
}

.footer__heading {
    font-weight: bold;
    margin-bottom: 5px;
}

.footer__list {
    margin-left: 5px;
    margin-bottom: 15px;
}

.footer__list li {
    margin-top: 5px;
}

.footer__list a:hover {
    text-decoration: underline;
}

.footer__address {
    margin-left: 5px;
    margin-bottom: 15px;
    line-height: 1.6;
}

.footer__contact {
    display: inline-block;
    margin-left: 5px;
}

.footer__contact:hover {
    text-decoration: underline;
}

/* コピーライト */
.footer__copyright {
    position: relative;
    min-height: 80px;
    padding-top: 10px;
    border-top: 1px solid #ddd;
}

.footer__illust {
    display: none;
}

@media (min-width: 768px) {
    .footer__illust {
        display: block;
        max-width: 200px;
    }

    .footer__copyright {
        border-top: none;
    }
}

.footer__copyright-text {
    text-align: center;
    line-height: 1.6;
}

@media (min-width: 768px) {
    .footer__copyright-text {
        position: absolute;
        right: 0;
        bottom: 0;
        text-align: right;
    }
}

/* ==========================================================================
   固定ページ (.page)
   ========================================================================== */

.page__inner {
    max-width: var(--width-content);
    margin: 0 auto;
    padding: 20px 0;
}

.page__title {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--color-text-heading);
    color: var(--color-text-heading);
}

.page__content {
    line-height: 1.8;
}

.page__content p {
    margin-bottom: 1rem;
}

/* ==========================================================================
   下層ページ共通（本文 .entry-content 配下で使う部品）
   ========================================================================== */

/* 本文エリア */
.entry-content {
    line-height: 1.8;
}

.entry-content p {
    margin-bottom: 1rem;
}

/* 青文字（現行サイトで多用 #000099） */
.text--blue {
    color: #000099;
}

/* 大見出し（現行 size+2 相当） */
.entry-content__heading {
    font-size: 1.3rem;
    font-weight: bold;
    margin-bottom: 1rem;
}

@media (min-width: 768px) {
    .entry-content__heading {
        font-size: 1.5rem;
    }
}

/* セクション見出し */
.section__heading {
    font-size: 1.25rem;
    font-weight: bold;
    margin: 1.5rem 0 1rem;
}

/* 区切り線 */
.divider {
    border: none;
    border-top: 1px solid #ccc;
    margin: 1.5rem 0;
}

/* 罫線テーブル */
.table--bordered {
    width: 100%;
    border-collapse: collapse;
    margin: 1rem 0;
}

.table--bordered th,
.table--bordered td {
    border: 1px solid #ccc;
    padding: 0.75rem;
    text-align: left;
}

.table--bordered th {
    background-color: #f5f5f5;
    font-weight: normal;
    width: 30%;
}

@media (max-width: 479px) {
    .table--bordered tr {
        display: block;
        border: 1px solid #ccc;
        margin-bottom: 0.5rem;
    }

    .table--bordered th,
    .table--bordered td {
        display: block;
        width: 100%;
        border: none;
        border-bottom: 1px solid #ccc;
    }

    .table--bordered td {
        border-bottom: none;
    }

    .table--bordered th {
        background-color: #eee;
        font-weight: bold;
    }
}

/* ラベル/値テーブル（罫線なし） */
.table--info {
    width: 100%;
    border-collapse: collapse;
    margin: 1rem 0;
}

.table--info th,
.table--info td {
    padding: 0.5rem;
    text-align: left;
    vertical-align: top;
}

.table--info th {
    width: 30%;
    font-weight: normal;
}

@media (max-width: 479px) {
    .table--info th,
    .table--info td {
        display: block;
        width: 100%;
        padding: 0.25rem 0;
    }

    .table--info th {
        font-weight: bold;
    }
}

/* 赤背景ヘッダーセル */
.table__header--red {
    background-color: #cc0000;
    color: #fff;
}

/* ==========================================================================
   アクセスページ
   ========================================================================== */

/* Google Maps 埋め込み（レスポンシブ） */
.access__map {
    position: relative;
    width: 100%;
    aspect-ratio: 4 / 3;
    margin: 1rem 0;
}

.access__map iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

@media (min-width: 768px) {
    .access__map {
        aspect-ratio: 16 / 9;
    }
}

/* 住所テキスト */
.access__address {
    margin: 1rem 0;
}

/* 注記（控えめ） */
.access__note {
    margin: 1.5rem 0;
    font-size: 0.875rem;
    color: #666;
}

/* 購入リンク */
.access__link {
    margin: 1rem 0;
}

.access__link a {
    color: #0000ee;
    text-decoration: underline;
}

.access__link a:hover {
    color: #551a8b;
}


/* ==========================================================================
   プロフィールカード（staff / voice 共通）
   ========================================================================== */

.profile-card {
    margin: 0 0 2rem;
}

@media (min-width: 768px) {
    .profile-card {
        display: flex;
        align-items: flex-start;
        gap: 1.5rem;
    }
}

.profile-card__image {
    display: block;
    max-width: 280px;
    height: auto;
    margin: 0 auto 1rem;
}

@media (min-width: 768px) {
    .profile-card__image {
        margin: 0;
        flex-shrink: 0;
    }
}

.profile-card__body {
    flex: 1;
}

.profile-card__name {
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
    color: #333;
    text-align: center;
}

@media (min-width: 768px) {
    .profile-card__name {
        text-align: left;
    }
}

.profile-card__text {
    line-height: 1.6;
}

/* ==========================================================================
   生産者紹介ページ（staff）
   ========================================================================== */

/* 産地セクション */
.staff__section {
    margin: 0 0 2rem;
}

@media (min-width: 768px) {
    .staff__section {
        display: flex;
        align-items: flex-start;
        gap: 1.5rem;
    }
}

/* 産地風景画像 */
.staff__landscape {
    display: block;
    max-width: 330px;
    height: auto;
    margin: 0 auto 1rem;
}

@media (min-width: 768px) {
    .staff__landscape {
        margin: 0;
        flex-shrink: 0;
    }
}

/* 産地説明文 */
.staff__description {
    flex: 1;
    line-height: 1.8;
}

/* ==========================================================================
   お客様の声ページ（voice）
   ========================================================================== */

/* イントロ文 */
.voice__intro {
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

/* 声カード（縦積み） */
.voice-card {
    margin-bottom: 1.5rem;
}

.voice-card__header {
    font-weight: bold;
    margin-bottom: 0.5rem;
}

.voice-card__image {
    display: block;
    max-width: 100%;
    height: auto;
    margin: 1rem 0;
}

@media (min-width: 768px) {
    .voice-card__image {
        max-width: 400px;
    }
}

.voice-card__text {
    line-height: 1.8;
}

.voice-card__text p {
    margin-bottom: 0.5rem;
}

/* ==========================================================================
   観光スポットページ（sightseeing）
   ========================================================================== */

.sightseeing__intro {
    text-align: center;
    margin-bottom: 2rem;
    line-height: 1.8;
}

.spot-card {
    text-align: center;
    margin-bottom: 2rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid #ccc;
}

.spot-card:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.spot-card__image {
    display: block;
    max-width: 100%;
    height: auto;
    margin: 0 auto 1rem;
}

@media (min-width: 768px) {
    .spot-card__image {
        max-width: 400px;
    }
}

.spot-card__text {
    line-height: 1.8;
    text-align: left;
}

@media (min-width: 768px) {
    .spot-card__text {
        text-align: center;
    }
}

/* ==========================================================================
   りんごレシピページ（recipe）
   ========================================================================== */

.recipe__intro {
    margin-bottom: 2rem;
    line-height: 1.8;
}

.recipe-card {
    margin-bottom: 2rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid #ccc;
}

.recipe-card:last-child {
    border-bottom: none;
}

.recipe-card__title {
    font-size: 1.1rem;
    font-weight: bold;
    margin-bottom: 1rem;
}

.recipe-card__heading {
    font-weight: bold;
    margin: 1rem 0 0.5rem;
    background-color: #f5f5f5;
    padding: 0.75rem 1rem;
    border-radius: 4px;
}

.recipe-card__ingredients {
    margin-bottom: 1rem;
}

@media (min-width: 480px) {
    .recipe-card__ingredients {
        display: flex;
        align-items: flex-start;
        gap: 1rem;
    }
}

.recipe-card__image {
    display: block;
    max-width: 200px;
    height: auto;
    margin: 0 auto 1rem;
}

@media (min-width: 480px) {
    .recipe-card__image {
        margin: 0;
        flex-shrink: 0;
    }
}

.recipe-card__ingredient-table {
    flex: 1;
}

.recipe-card__ingredient-row {
    display: flex;
    gap: 1rem;
    padding: 0.375rem 0;
    border-bottom: 1px solid #ccc;
}

.recipe-card__ingredient-row:last-child {
    border-bottom: none;
}

.recipe-card__ingredient-name {
    flex: 1;
}

.recipe-card__ingredient-amount {
    flex-shrink: 0;
    text-align: right;
}

.recipe-card__text {
    line-height: 1.8;
}

.recipe-card__back {
    text-align: right;
    margin-top: 1rem;
    font-size: 0.875rem;
}

.recipe-card__back a {
    color: var(--color-accent-green);
    text-decoration: none;
}

.recipe-card__back a:hover {
    text-decoration: underline;
}

/* レシピメニュー */
.recipe-menu {
    margin: 1.5rem 0 2rem;
    padding: 1rem;
    background-color: #f9f9f9;
    border-radius: 8px;
}

.recipe-menu__list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    list-style: none;
    padding: 0;
    margin: 0;
}

.recipe-menu__list li {
    margin: 0;
}

.recipe-menu__list a {
    display: inline-block;
    padding: 0.25rem 0.5rem;
    font-size: 0.875rem;
    color: var(--color-accent-green);
    text-decoration: none;
    border: 1px solid var(--color-accent-green);
    border-radius: 4px;
    transition: background-color 0.2s, color 0.2s;
}

.recipe-menu__list a:hover {
    background-color: var(--color-accent-green);
    color: #fff;
}

/* ==========================================================================
   りんごカレンダー（calendar）
   ========================================================================== */

/* スクロールラッパー */
.calendar-wrapper {
    position: relative;
    margin: 1.5rem 0;
}

.calendar-wrapper__scroll {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

/* スクロールヒント（右端フェード影） */
.calendar-wrapper__hint {
    position: absolute;
    top: 0;
    right: 0;
    width: 40px;
    height: 100%;
    background: linear-gradient(to right, rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.9));
    pointer-events: none;
    transition: opacity 0.3s;
}

.calendar-wrapper--scrolled-end .calendar-wrapper__hint {
    opacity: 0;
}

/* スクロール注記 */
.calendar-wrapper__note {
    font-size: 0.75rem;
    color: #666;
    text-align: right;
    margin-bottom: 0.5rem;
    transition: opacity 0.3s;
}

.calendar-wrapper--scrolled-end .calendar-wrapper__note {
    opacity: 0;
}

@media (min-width: 768px) {
    .calendar-wrapper__hint,
    .calendar-wrapper__note {
        display: none;
    }
}

/* カレンダーテーブル */
.calendar-table {
    border-collapse: collapse;
    table-layout: fixed;
    min-width: 600px;
    width: 100%;
}

.calendar-table th,
.calendar-table td {
    border: 1px solid #ccc;
    padding: 0.5rem;
    text-align: center;
    vertical-align: middle;
    white-space: nowrap;
}

/* ヘッダー行 */
.calendar-table__header {
    background-color: #008000;
    color: #fff;
    font-weight: normal;
}

/* 品種名セル */
.calendar-table__variety {
    background-color: #008000;
    color: #fff;
    font-weight: bold;
    text-align: left;
    font-size: 0.85rem;
    white-space: nowrap;
}

@media (max-width: 767px) {
    .calendar-table__variety {
        min-width: 110px;
        white-space: normal;
        font-weight: normal;
        font-size: 0.75rem;
        position: sticky;
        left: 0;
        z-index: 1;
    }
}

/* 旬セル（薄緑塗り） */
.calendar-table__season {
    background-color: #93c47d4f;
}

/* 非旬セル（白） */
.calendar-table__empty {
    background-color: #fff;
}

/* ==========================================================================
   ユーティリティ
   ========================================================================== */

/* スクリーンリーダー用非表示 */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}
