@charset "UTF-8";

/* =========================================
   1. 基本設定 / Base
   ========================================= */
* {
    box-sizing: border-box;
}

body {
    font-family: "Helvetica Neue", Arial, sans-serif;
    line-height: 1.8;
    color: #333;
    background-color: #f4f4f4;
    margin: 0;
    padding: 0;
}

a {
    text-decoration: none;
    color: inherit;
    transition: 0.3s;
}

a:hover {
    opacity: 0.8;
}

/* =========================================
   2. ヘッダー & ナビゲーション
   ========================================= */
header {
    background: #1a252f;
    border-bottom: none;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-inner {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 20px;
    height: 90px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* ロゴ */
.logo {
    color: #fff;
    font-size: 20px;
    font-weight: 900;
    letter-spacing: 0.05em;
    display: flex;
    align-items: center;
}

.logo span {
    margin-right: 5px;
}

.logo img {
    max-height: 70px;
    width: auto;
    display: block;
}

/* PC用メニュー */
.pc-nav {
    display: flex;
    gap: 25px;
}

.nav-item {
    color: #fff;
    text-decoration: none;
    font-weight: bold;
    font-size: 14px;
    display: flex;
    align-items: center;
    transition: 0.3s;
}

.nav-item:hover {
    color: #ff9f43;
}

.nav-icon {
    margin-right: 5px;
    font-size: 18px;
}

/* モバイル用メニューアイコン */
.mobile-menu-icon {
    display: none;
    color: #fff;
    font-size: 24px;
    cursor: pointer;
}

/* =========================================
   3. 記事メインコンテナ (基本形)
   ※ 色やボーダーは各ページで上書き
   ========================================= */
.article-container {
    max-width: 800px;
    margin: 30px auto;
    background: #fff;
    padding: 40px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    border-radius: 4px;
    position: relative;
}

/* =========================================
   4. 汎用パーツ (監修者・FAQ・関連記事)
   ========================================= */

/* 監修者情報 */
.supervisor-box {
    background: #fff;
    border: 1px solid #ccc;
    padding: 25px;
    border-radius: 8px;
    margin-top: 50px;
    display: flex;
    gap: 20px;
    align-items: center;
}

.supervisor-img {
    width: 80px;
    height: 80px;
    background: #eee;
    border-radius: 50%;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 40px;
    border: 2px solid #999;
}

.supervisor-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.supervisor-info span {
    display: block;
}

/* 関連記事エリア */
.related-area {
    margin-top: 60px;
    padding-top: 40px;
    border-top: 2px dashed #ddd;
}

.related-head {
    font-size: 20px;
    font-weight: bold;
    margin-bottom: 25px;
    color: #2c3e50;
    display: flex;
    align-items: center;
}

.related-head::before {
    content: "\1F4D6";
    margin-right: 10px;
}

.related-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.related-card {
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
    transition: 0.3s;
    text-decoration: none;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.03);
}

.related-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    border-color: #ff9f43;
}

.related-icon {
    background: #f4f6f8;
    padding: 15px;
    text-align: center;
    font-size: 30px;
    border-bottom: 1px solid #eee;
}

.related-body {
    padding: 15px;
}

.related-tag {
    font-size: 11px;
    background: #e0f2f1;
    color: #00695c;
    padding: 3px 8px;
    border-radius: 4px;
    display: inline-block;
    margin-bottom: 8px;
    font-weight: bold;
}

.related-title {
    font-size: 16px;
    font-weight: bold;
    color: #2c3e50;
    margin: 0 0 8px 0;
    line-height: 1.5;
}

.related-desc {
    font-size: 12px;
    color: #7f8c8d;
    margin: 0;
    line-height: 1.6;
}

.related-arrow {
    text-align: right;
    color: #ff9f43;
    font-size: 12px;
    font-weight: bold;
    margin-top: auto;
    padding: 0 15px 15px;
}

/* FAQセクション (基本形) */
.faq-item {
    margin-bottom: 20px;
    border: 1px solid #ddd;
    border-radius: 6px;
    overflow: hidden;
}

.faq-q {
    background: #f4f4f4;
    padding: 15px;
    font-weight: bold;
    cursor: pointer;
    color: #2c3e50;
    display: flex;
    align-items: center;
}

/* FAQのQマークやAの背景色はページ固有のカラーがあるため、
   外部CSSでは基本レイアウトのみ定義し、色は各ページで調整可能にする */
.faq-a {
    padding: 15px 20px;
    background: #fff;
    font-size: 14px;
    border-top: 1px solid #eee;
    line-height: 1.6;
}

/* 広告表記のスタイル */
.ad-notice {
    font-size: 11px;           /* 小さめの文字 */
    color: #95a5a6;            /* 薄いグレー */
    text-align: right;         /* 右寄せ（または left で左寄せ） */
    margin-top: -20px;         /* タイトルとの距離を調整 */
    margin-bottom: 20px;       /* 本文との距離 */
    display: block;
}

/* =========================================
   5. フッター
   ========================================= */
footer {
    background: #1a252f;
    color: #fff;
    text-align: center;
    padding: 50px 20px;
    margin-top: 100px;
}

.footer-nav a {
    color: #ccc;
    margin: 0 15px;
    font-size: 14px;
    display: inline-block;
    padding: 5px 0;
}

.footer-nav a:hover {
    color: #fff;
    text-decoration: underline;
}

/* =========================================
   6. レスポンシブ設定 (共通)
   ========================================= */
.mobile-bottom-nav {
    display: none;
}

@media (max-width: 768px) {
    .article-container {
        padding: 25px 15px;
        margin: 0;
        border-radius: 0;
        border-top: none;
    }

    .header-inner {
        height: 70px;
    }

    .logo img {
        max-height: 45px;
        width: auto;
        display: block;
    }
    
    .supervisor-box {
        flex-direction: column;
        text-align: center;
    }

    .supervisor-info p {
        text-align: left;
    }

    .ad-notice {
        margin-top: -10px;
    }

    /* ナビゲーション切り替え */
    .pc-nav {
        display: none;
    }

    .mobile-menu-icon {
        display: block;
    }

    /* ハンバーガーメニュー展開時 */
    .pc-nav.active {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: 60px; /* ヘッダー高さに合わせる */
        left: 0;
        width: 100%;
        background: #1a252f;
        padding: 20px 0;
        box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2);
        animation: slideDown 0.3s ease;
        z-index: 999;
    }

    .pc-nav.active .nav-item {
        justify-content: center;
        padding: 15px 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        font-size: 16px;
    }

    @keyframes slideDown {
        from { opacity: 0; transform: translateY(-10px); }
        to { opacity: 1; transform: translateY(0); }
    }

    /* フッターボトムナビ */
    body {
        padding-bottom: 60px;
    }

    .mobile-bottom-nav {
        display: flex;
        position: fixed;
        bottom: 0;
        left: 0;
        width: 100%;
        background: #fff;
        border-top: 1px solid #ddd;
        z-index: 9999;
        box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.05);
        padding-bottom: env(safe-area-inset-bottom);
    }

    .mobile-bottom-nav a {
        flex: 1;
        text-align: center;
        padding: 8px 0;
        color: #546e7a;
        font-size: 10px;
        font-weight: bold;
        text-decoration: none;
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .mobile-bottom-nav a:active {
        background: #f5f5f5;
        color: #ff9f43;
    }

    .mb-icon {
        font-size: 20px;
        margin-bottom: 2px;
    }
}