/* ==========================================
   共通リセット・基本設定
   ========================================== */
*, *::before, *::after {
    box-sizing: border-box; 
}

body {
    font-family:'Noto Sans JP', sans-serif;
    background-color: #f6f5f4;    
    margin: 0;
    padding: 0;
}

/* インナー（横幅の固定と中央配置を共通化） */
.header-inner,
.app,
.footer-inner {
    /*max-width: 800px;*/
    width: 100%;
    margin: 0 auto;
}

/* ==========================================
   コンポーネント設定
   ========================================== */

/* --- ヘッダー --- */
.header {
    background-color: #000;
    opacity: 0.5;
}
.header-inner {
    position: relative;
    background-color: antiquewhite;
    height: 200px;
    overflow: hidden;
    line-height: 100px;
}
.header-inner p{
    position: absolute; /* 絶対位置 */
    color: white;/*文字は白に*/
    text-shadow: 1px 1px 10px#000;
    top: 50%;
    left: 50%;
    transform: translate(-50%,-50%);
    font-weight: bold; /*太字に*/
    font-size: 2em;/*サイズ2倍*/
    margin:0;
    padding:0;
}
.header-inner  img{
    max-width: 100%; /* 💡 親要素の幅を超えないようにする */
    object-fit: cover; /* 縦横比を維持し、枠に合わせてトリミング */
}

/* --- メインレイアウト（サイドバー含む） --- */
.app {
    position: relative; /* 💡 追加：サイドバーの基準点にする */
    display: flex;
    overflow: hidden; /* はみ出たサイドバーを隠す */
    background-color: red; /* 構造確認用 */
    align-items: stretch; /* 💡【追加】左右の要素（サイドバーとメイン）の高さを揃える */
}

/* サイドバー共通 */
.side {
    background-color: #ff838b;
    border-radius: 0 10px 10px 0; /* 四隅すべてに10pxの丸みをつける */
    width: 150px;

    /* 💡【変更】絶対配置にして上に重ねる */
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    z-index: 10; /* メインコンテンツより手前に表示 */

    text-align: left;
    transition: transform 0.3s ease; /* 💡margin-rightの記述は削除 */

    /* 
    min-height: 100vh;
    text-align: left;
    flex-shrink: 0; /* 折りたたまれて幅が縮むのを防ぐ *//*
    transition: transform 0.3s ease, margin-right 0.3s ease;
    */
}

/* 💡 【追加】リストの黒い点と左側の余白を消す */
.side ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

/* 💡 【追加】リスト間の上下の隙間（お好みで調整してください） */
.side .list {
    margin: 10px 3px 0 3px;
}

/* 💡 リンクの装飾（文字を大きくし、クリックエリアを広げる） */
.side a {
    text-decoration: none;
    color: #ffffff;
    border-radius: 0 10px 10px 0;
    font-size: 20px;       /* 👈 文字の大きさを調整（お好みのサイズに） */
    font-weight: bold;     /* 👈 文字を太字にして見やすく */
    display: block;        /* 👈 リンクの反応エリアを横幅いっぱいに広げる */
    padding: 10px 5px;       /* 👈 上下に余白を作って押しやすくする */
    transition: background-color 0.2s ease; /* 👈 色の変化を滑らかにする */
}

/* 💡 【追加】カーソルを当てた（ホバーした）ときの変化 */
.side a:hover {
    background-color: #e06b73; /* 👈 カーソルが乗ったときの背景色（少し濃いピンク） */
    /* color: #ffff00; */     /* 👈 もし文字の色も変えたい場合はここを設定 */
    border-left: 4px solid #ffffff;
}

/* 💡 閉じている状態：左側に100px押し出し、ネガティブマージンで隙間を消す */
.side.is-close {
    transform: translateX(-150px);
    /* margin-right: -150px; */
}


/* ==========================================
   メインコンテンツ
   ========================================== */
.content {
    position: relative; /* 💡【追加】暗い幕（オーバーレイ）の位置基準にする */
    background-color: #FBEFEF;
    flex-grow: 1; /* 残りの幅をいっぱいに広げる */
    min-height: 100vh; /* 💡【追加】中身が少なくても最低限画面いっぱいの高さにする */
    text-align: center;
}
.main-content {
    margin: 2rem;
}
/*画像*/
.content img {
    max-width: 40%; /* 💡 親要素の幅を超えないようにする */
    object-fit: cover;    /* ⚠️ 超重要：画像が縦横に歪むのを防ぐ */
}

/* 💡【追加】メインコンテンツの上に被せる暗い幕（初期設定） */
.content::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5); /* 黒色で透過率50% */
    z-index: 5; /* サイドバー(z-index: 10)より後ろ、コンテンツより前 */
    transition: opacity 0.3s ease; /* 0.3秒かけて滑らかに暗くする */
    opacity: 0; /* 最初は透明 */
    pointer-events: none; /* 透明の時は下のコンテンツをクリックできるようにする */
}

/* 💡【追加】サイドバーが開いているとき：幕を表示して暗くする */
.side + .content::before {
    opacity: 1;
    pointer-events: auto; /* 暗い時はコンテンツのクリックをブロック */
}

/* 💡【追加】サイドバーが閉じているとき：幕を消す */
.side.is-close + .content::before {
    opacity: 0;
    pointer-events: none;
}
/* ==========================================
   HOMEページ固有のスタイリング
   ========================================== */
.front-section {
    background-color: #ffffff;      /* 白いカード風背景 */
    padding: 1.2rem 1.5rem;         /* 内側の余白 */
    border-radius: 10px 10px 0 0;             /* 角を丸く */
    border-left: 4px solid #ff838b; 
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05); /* ほんのり優しい影 */
    margin-bottom: 2rem;            /* 下のコンテンツとの隙間 */
    text-align: left;               /* 文章を左揃えに */
    border-bottom: 2px dashed #ccc; 
}

.front-section p {
    margin: 0;
    font-size: 1rem;
    color: #555;
    line-height: 1.7; /* 文章が読みやすい行間 */

    background-image: linear-gradient(180deg, #ccc 1px, transparent 1px); 
    background-size: 100% 2.5em; /* 行の高さ */
    line-height: 2.5em; /* 文字の高さ */
    padding-bottom: 0.5px;
}
.front-section h3{
    margin: 0;
    font-size: 1.2rem;
    color: #555;
    line-height: 1.7;
}

/* セクション見出し */
.home-section {
    margin-top: 2.5rem;
    text-align: left;
}

.section-title {
    font-size: 1.25rem;
    color: #333;
    border-left: 4px solid #ff838b;
    padding-left: 10px;
    margin: 0 0 1.2rem 0;
    display: flex;
    align-items: baseline;
}

.section-title span {
    font-size: 0.8rem;
    color: #888;
    margin-left: 10px;
    font-weight: normal;
}

/* 単一カード（1つの記事） */
.single-card-container {
    max-width: 480px;
    margin: 0 auto;
}

.card {
    background-color: #ffffff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 5px 5px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s ease;
}

.card:hover {
    transform: translateY(-4px);
}

.card-img {
    position: relative;
    height: 220px;
}

.card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.card-tag {
    position: absolute;
    bottom: 8px;
    left: 8px;
    background-color: rgba(0, 0, 0, 0.65);
    color: #ffffff;
    font-size: 0.7rem;
    padding: 3px 8px;
    border-radius: 4px;
    letter-spacing: 1px;
}

.card-body {
    padding:20px;
    text-align: left;
}

.card-body h3 {
    margin: 0 0 5px 0;
    font-size: 1.1rem;
    color: #333;
}

.card-body p {
    margin: 0 0 12px 0;
    font-size: 0.85rem;
    color: #666;
    line-height: 1.6;
}

.read-more {
    color: #e06b73;
    text-decoration: none;
    font-weight: bold;
    font-size: 0.85rem;
}

.read-more:hover {
    text-decoration: underline;
}

/* ギャラリーピックアップ */
.mini-gallery {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    max-width: 1440px;
    margin: 0 auto;
}

.gallery-item {
    aspect-ratio: 4 / 3;
    overflow: hidden;
    border-radius: 6px;
    box-shadow: 0 5px 5px rgba(0, 0, 0, 0.1);
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.gallery-item:hover img {
    transform: scale(1.1);
}

.btn-center {
    text-align: center;
    margin-top: 1.5rem;
}

.btn-link {
    display: inline-block;
    padding: 10px 24px;
    background-color: #ff838b;
    color: #ffffff;
    text-decoration: none;
    border-radius: 20px;
    font-weight: bold;
    font-size: 0.85rem;
    box-shadow: 0 2px 6px rgba(255, 131, 139, 0.4);
    transition: background-color 0.2s ease;
}

.btn-link:hover {
    background-color: #e06b73;
}

/* カードを中央に寄せ、読みやすい幅にする */
.single-card-container {
    max-width: 480px;
    margin: 0 auto;
}

/* 💡【重要】カードやギャラリーの中の画像が横いっぱいに広がるように上書き修正 */
.card-img img,
.gallery-item img {
    width: 100% !important;
    max-width: 100% !important;
    height: 100%;
    object-fit: cover;
}

/* ==========================================
   JOURNEY（旅行記本編）スタイリング
   ========================================== */

/* 全体の白枠カード */
.journey-container {
    background-color: #ffffff;
    max-width: 800px;
    margin: 0 auto 3rem auto;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    text-align: left;
}


/* 記事ヘッダー周り */
.journey-header{
    padding-top: 1.5rem;
    margin-bottom: 2.5rem;
}
.journey-date {
    display: inline-block;
    background-color: #ff838b;
    color: #ffffff;
    font-size: 0.8rem;
    font-weight: bold;
    padding: 4px 12px;
    border-radius: 20px;
    margin-bottom: 0.8rem;
    letter-spacing: 1px;
}

.journey-title {
    font-size: 1.8rem;
    color: #333;
    margin: 0 0 0.5rem 0;
}

.journey-lead {
    font-size: 1rem;
    color: #666;
    margin-bottom: 1.5rem;
}

/* スポット（各セクション） */
.spot-item {
    padding-top: 1.5rem;
    margin-bottom: 2.5rem;
    border-top: 3px dashed #e0e0e0; /* セクション間の点線区切り */
}

.spot-text p {
    font-size: 0.95rem;
    color: #444;
    line-height: 1.8;
    margin-bottom: 1rem;
}

.custom-tooltip {
    position: fixed;
    top: 0;
    left: 0;
    background-color: rgba(51, 51, 51, 0.85); /* 半透明の黒背景 */
    color: #ffffff;                            /* 文字は白 */
    padding: 5px 10px;
    border-radius: 6px;
    font-size: 0.75rem;
    pointer-events: none;                      /* カーソルの邪魔をしない */
    opacity: 0;                                /* 最初は隠しておく */
    transition: opacity 0.15s ease;
    z-index: 9999;
    white-space: nowrap;                       /* 勝手に改行させない */
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.spot-images img:hover {
    transform: scale(1.03); /* ホバー時に少し拡大 */
}

/* カーソルに乗った時に表示 */
.custom-tooltip.is-active {
    opacity: 1;
}

/* スポット内の複数枚の写真配置 */
/* 💡【修正】スポット内の写真エリア（Masonry風レイアウトに変更） */
.spot-images {
    /* 以前の display: grid; などは削除 */
    column-count: 3;    /* 💡 写真を3列に分割 */
    column-gap: 10px;    /* 列間の間隔（横） */
    margin-top: 1rem;
    width: 100%;
}

/* 💡【修正】写真自体のサイズ設定（高さを自動にしてトリミングしない） */
.spot-images img {
    width: 100%;        /* 列幅いっぱいに広げる */
    max-width: 100%;
    height: auto;       /* 💡 高さを自動にしてアスペクト比を維持 */
    object-fit: contain; /* 💡 トリミングしない（写真全体を表示） */
    display: block;      /* 下部の隙間を消す */
    margin-bottom: 10px; /* 写真間の縦方向の間隔（column-gapは横のみ） */
    border-radius: 6px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.08);
}

/* 💡 スマホ対応：2列にする */
@media (max-width: 600px) {
    .spot-images {
        column-count: 2;
    }
}
.main-content-gallery{
    display: flex;
    justify-content: center; /* 💡 写真全体を中央寄せ */
}

/* ギャラリー全体の外枠（中央寄せ用） */
.gallery-container {
    width: 100%;
    display: flex;
    justify-content: center; /* グリッド全体を完全に中央へ */
    margin-bottom: 3rem;
}

/* 写真の配置グリッド */
.gallery-grid {
    display: flex;
    justify-content: center; /* 写真たちを中央寄せ */
    align-items: flex-start;
    flex-wrap: wrap;         /* 折返し許可 */
    gap: 16px;               /* 写真同士の隙間 */
    max-width: 960px;        /* ギャラリーの最大幅 */
    width: 100%;
}

/* 写真自体のスタイル */
.gallery-grid img {
    /* PCでは3列並び（隙間を考慮した幅設定） */
    width: calc(33.333% - 11px);
    max-width: 100%;
    height: auto;            /* 縦長写真の比率を保つ */
    object-fit: contain;     /* トリミングせずに全体表示 */
    border-radius: 8px;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    cursor: pointer;
}

/* ホバー時のちょっとした演出 */
.gallery-grid img:hover {
    transform: translateY(-4px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

/* スマホ対応（600px以下は2列表示） */
@media (max-width: 600px) {
    .gallery-grid img {
        width: calc(50% - 8px);
    }
}

/* ==========================================
   ボタン回り
   ========================================== */
/* ボタンの配置 */
.btn-container {
    margin: 10px 10px 10px 0px;
    text-align: left;
    display: flex;
    align-items: center; /* 💡 追加：中身の要素を縦方向の中央で揃える */
    position: relative; 
}
/* 💡 追加：「ここに名前」のh2タグが持つデフォルトの余白を消す */
.daimei h2 {
    margin: 0 0 0 20px;
}

/*ボタン本体 */
#toggle-btn {
    margin: 0; /* 左余白を0にして左端に固定 */    
    padding: 10px 12px 10px 10px; /* 内側の余白（上・右・下・左） */
    cursor: pointer;
    background-color: #ff838b; /* 💡 サイドバーと同じピンク色 */
    
    /* 💡 右側の角だけを丸くして「付箋・タブ」っぽくする */
    border-radius: 0 10px 10px 0; 
    
    /* 💡 ほんのり影をつけて立体感を出す */
    box-shadow: 3px 3px 5px -2px rgba(0, 0, 0, 0.2);    
    /* 💡 開閉時に滑らかに動かすアニメーション */
    transition: transform 0.3s ease;
}
.sideber-btn{
    z-index: 20; /* 💡【追加】サイドバー（z-index: 10）より手前にする */
    transition: transform 0.3s ease;/* 💡【追加】右へ移動するときの滑らかなアニメーション */
    background-color:#ff838b;
}
/*ボタンの棒の表示*/
#toggle-btn span{
    display: block;
    width: 35px;
    height: 4px;
    border-radius: 100vh;
    background-color: white;
}
/*ボタンの棒の間隔*/
#toggle-btn span:not(:last-child){
    margin-bottom: 9px;
}
/* 💡【超重要】サイドバーが開いているとき：ボタンを150px右に移動させる */
.side + .content #toggle-btn {
    transform: translateX(150px);
}
/* 💡【超重要】サイドバーが閉じているとき：ボタンの位置を0（元）に戻す */
.side.is-close + .content #toggle-btn {
    transform: translateX(0);
}

/* --- フッター --- */
.footer {
    background-color:black;
}
.footer-inner {
    background-color: #FFE2E2;
    height: 100px;
    text-align: center;
    overflow: hidden;
}

