﻿/* -----------------------------------------------
   カード（和紙パネル）
   ----------------------------------------------- */
.card {
    background-color: #FCFAF2; /* 生成り色 */
    border: 1px solid #E5E2D9;
    box-shadow: var(--washi-shadow);
    border-radius: 6px;
}


/* -----------------------------------------------
   テーブル（淡い和紙スタイル）
   ----------------------------------------------- */
.table {
    background-color: #FBF9F1;
    border-color: #DCD7C9;
}

    .table thead {
        background-color: #E8E5D7;
        color: #333;
    }

/* -----------------------------------------------
   フォーム（和風の淡い縁）
   ----------------------------------------------- */
.form-control {
    background-color: #FFFDF7;
    border: 1px solid #D7D3C5;
    border-radius: 4px;
}

    .form-control:focus {
        border-color: var(--bs-primary);
        box-shadow: 0 0 0 0.15rem rgba(11, 59, 140, 0.25);
    }

/* -----------------------------------------------
   ナビバー（紺藍 or 和紙）
   ----------------------------------------------- */
.navbar {
    background-color: #0B3B8C; /* 紺藍 */
}

    .navbar .navbar-brand,
    .navbar .nav-link {
        color: #FAF9F5 !important;
    }

        .navbar .nav-link:hover {
            color: #D6E2F0 !important;
        }

/* -----------------------------------------------
   アコーディオン（和紙 + 紺）
   ----------------------------------------------- */
.accordion-button {
    background-color: #F7F4EB;
    color: #2F2F2F;
}

    .accordion-button:not(.collapsed) {
        background-color: #E6E2D7;
        color: var(--bs-primary);
    }

/* リンクカラー（柔らか白群） */
a {
    color: #6BA9B3;
    text-decoration: none;
}

    a:hover {
        color: #5B98A3;
        text-decoration: underline;
    }

    a:visited {
        color: #6BA9B3;
    }

html {
  font-size: 14px;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
  position: relative;
  min-height: 100%;
}

body {
    margin-bottom: 60px;
    /*background-color: var(--bs-body-bg);*/
    color: var(--bs-body-color);
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
  color: var(--bs-secondary-color);
  text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
  text-align: start;
}

/* フォントの変更 */
body {
    font-family: 'M PLUS 1p', serif,'Roboto', sans-serif; /* 日本語フォント */
    color: #34495E;
}

.form-control:focus {
    box-shadow: 0px 0px 8px rgba(51, 135, 134, 0.5);
    border-color: #338786;
}



/* 和風テーブルデザイン */
.table-wafu {
    width: 100%;
    border-collapse: collapse;
    background-color: #f8f4e6; /* 和紙風の背景色 */
}

    .table-wafu th, .table-wafu td {
        border: 1px solid #dcdcdc; /* 薄いグレーのボーダー */
        padding: 10px;
        text-align: left;
    }

    .table-wafu thead {
        background-color: #b22222; /* 深い紅色 */
        color: #ffffff; /* 白文字 */
        font-weight: bold;
    }

    .table-wafu tr:nth-child(even) {
        background-color: #f2e8d5; /* 和紙風の薄いベージュ */
    }

    .table-wafu tr:hover {
        background-color: #e6d5c3; /* ホバー時のアクセント */
    }

    /*.table-wafu a {
        color: #264653;*/ /* 藍色 */
        /*text-decoration: none;
    }

        .table-wafu a:hover {
            text-decoration: underline;
        }*/


/* サイドメニューの初期状態 */
#sideMenu {
    width: 230px; /* サイドメニューの幅 */
    height: 100vh; /* 画面いっぱいの高さ */
    position: fixed; /* 固定位置 */    
    top: 57px;
    left: 0;
    background-color: #f8f9fa; /* 背景色 */
    border-right: 1px solid #ddd; /* 右側のボーダー */
    overflow-y: auto; /* コンテンツが多い場合にスクロール可能にする */
    transition: width 0.3s ease-in-out; /* 開閉時のアニメーション */
}

/* サイドメニューが閉じた状態 */
#sideMenu.collapsed {
    width: 80px; /* 閉じているときの幅 */
}

/* メインコンテンツの調整 */
main {
    margin-left: 220px; /* サイドメニューが開いているとき */
    transition: margin-left 0.3s ease-in-out;
}

#sideMenu.collapsed + main {
    margin-left: 60px; /* サイドメニューが閉じているとき */
}

/* メニュー名の表示切り替え */
#sideMenu .menu-text {
    display: inline; /* 開いているときは表示 */
    transition: opacity 0.3s ease-in-out;
}

#sideMenu.collapsed .menu-text {
    display: none; /* 閉じているときは非表示 */
}

/* トグルボタンの矢印回転 */
#menuToggle {
    transition: transform 0.3s ease-in-out;
}

#sideMenu.collapsed #menuToggle i {
    transform: rotate(180deg); /* 矢印を反転 */
}



.post-content {
    font-size: 0.9rem;
    color: #555;
    word-wrap: break-word;
}

.post-date {
    font-size: 0.9rem;
    color: #6c757d; /* muted text color */
}


/* 画像の上にチェックボックスを配置 */
.sns-post-card {
    position: relative; /* 子要素を絶対位置で配置するため */
}

/* カスタムチェックボックスデザイン */
.checkbox-overlay {
    appearance: none; /* デフォルトのチェックボックススタイルを無効化 */
    position: absolute;
    top: 4px;
    right: 8px;
    z-index: 10;
    width: 24px;
    height: 24px;
    border: 2px solid var(--bs-primary); /* 枠線の色 */
    border-radius: 30%!important; /* 丸い形状 */
    background-color: white; /* 背景色 */
    cursor: pointer;
    transition: all 0.3s ease-in-out; /* アニメーション */
}

    .checkbox-overlay:hover {
        box-shadow: 0 0 8px rgba(0, 95, 204, 0.5); /* ホバー時の影 */
    }

    .checkbox-overlay:checked {
        background-color: var(--bs-primary); /* 選択時の背景色 */
        border-color: var(--bs-primary); /* 選択時の枠線色 */
        box-shadow: 0 0 8px rgba(0, 95, 204, 0.8); /* 選択時の影 */
        position: relative;
    }

        .checkbox-overlay:checked::after {
            /*content: '';*/ /* チェックマークを表示 */
            /*position: absolute;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%) scale(1);
            width: 12px;
            height: 12px;
            background-color: white;*/ /* チェックマークの色 */
            /*border-radius: 50%;*/ /* 丸い形状 */
            transition: transform 0.2s ease-in-out; /* アニメーション */
        }

    .checkbox-overlay:not(:checked)::after {
        transform: translate(-50%, -50%) scale(0); /* 非選択時は非表示 */
    }

/* ダウンロードボタン */
.download-btn {
    z-index: 2;
    opacity: 0.7;
}

    .download-btn:hover {
        opacity: 1;
    }


/* カルーセル矢印の背景色とアイコン色を変更 */
.carousel-control-prev-icon,
.carousel-control-next-icon {
    background-color: rgba(0,0,0,0.6); /* 半透明の黒背景 */
    border-radius: 50%;
    background-size: 60% 60%;
    width: 2.5rem;
    height: 2.5rem;
}

.carousel-control-prev,
.carousel-control-next {
    filter: none;
    opacity: 1;
}

.carousel-control-prev-icon::after,
.carousel-control-next-icon::after {
    /* アイコン色を白に */
    color: #fff;
}









/* サイドメニューのスタイル */
#sidebar {
    width: 250px; /* サイドメニューの幅 */
    position: fixed; /* 固定配置 */
    top: 0;
    left: 0;
    height: 100%; /* 画面全体の高さ */
    z-index: 1000; /* メインコンテンツより前面に表示 */
    background-color: #f8f9fa; /* 背景色 */
    overflow-y: auto; /* 縦スクロールを有効化 */
}

/* メインコンテンツのスタイル */
#content {
    margin-left: 250px; /* サイドメニューの幅と同じ値 */
    padding: 20px; /* コンテンツの内側余白 */
}





















body {
    overflow-x: hidden;
}

#sidebar {
    min-height: 100vh;
    transition: margin-left 0.3s;
}

    #sidebar.active {
        margin-left: -250px;
    }

#content {
    width: 100%;
    transition: margin-left 0.3s;
}

.sidebar-header {
    padding: 20px;
    background: var(--bs-primary);
    color: white;
}

.sidebar-menu {
    list-style: none;
    padding: 0;
    margin: 0;
}

    .sidebar-menu li a {
        padding: 15px 20px;
        display: block;
        color: #333;
        text-decoration: none;
        transition: all 0.3s;
        border-left: 3px solid transparent;
    }

        .sidebar-menu li a:hover,
        .sidebar-menu li a.active {
            background: #F7F4EB;
            border-left-color: var(--bs-primary);
            color: var(--bs-primary);
        }

        .sidebar-menu li a i {
            margin-right: 10px;
            width: 20px;
        }

@media (max-width: 768px) {
    #sidebar {
        margin-left: -250px;
    }

        #sidebar.active {
            margin-left: 0;
        }

    #content {
        margin-left: 0 !important;
    }
}

.overlay {
    display: none;
    position: fixed;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.5);
    z-index: 998;
    opacity: 0;
    transition: opacity 0.3s;
}

    .overlay.active {
        display: block;
        opacity: 1;
    }