/* ========================================
   解説ページ共通スタイル
   プレフィックス: help-

   全シミュレーターの解説ページで共有する
   標準的なスタイル定義
   ======================================== */

/* ========================================
   リセット・基本設定
   ======================================== */

/* 既存のstyle.cssからフォントを継承するため、
   @font-faceは定義しない */

* {
    padding: 0;
    margin: 0;
}

/* ========================================
   ページ全体レイアウト
   ======================================== */

body.help-page {
    color: #333;
    font-size: 15px;
    background: #f5f7fb;
    line-height: 1.7;
    font-family: 'Noto Sans JP', 'メイリオ', sans-serif;
    padding: 0;
    margin: 0;
}

/* ========================================
   見出しスタイル
   ======================================== */

.help-page h1 {
    font-size: 20px;
    background: #023F64;
    color: #fff;
    font-weight: normal;
    padding: 10px 15px;
    margin: 0;
}

.help-page h2 {
    font-size: 18px;
    font-weight: normal;
    border-left: 4px solid #165e7d;
    padding-left: 10px;
    color: #165e7d;
    margin: 20px 0 10px;
}

.help-page h3 {
    font-size: 16px;
    font-weight: normal;
    color: #165e7d;
    margin: 15px 0 10px;
}

/* ========================================
   コンテンツエリア
   ======================================== */

.help-content {
    background: #fff;
    padding: 15px 25px;
    border-top: 4px solid #D6AE58;
    border-bottom: 3px solid #D6AE58;
    min-height: 300px;
}

/* ========================================
   テキスト要素
   ======================================== */

.help-page p {
    margin: 15px 0;
    line-height: 1.8;
}

.help-page strong {
    color: #cc0000;
    font-weight: bold;
}

.help-page em {
    color: #313e9d;
    font-style: normal;
}

/* ========================================
   リスト
   ======================================== */

.help-page ul,
.help-page ol,
.help-page dl {
    margin: 15px 0;
}

.help-page li {
    margin-left: 25px;
    margin-bottom: 8px;
}

.help-page dt {
    font-weight: bold;
    margin-top: 10px;
    color: #023F64;
}

.help-page dd {
    margin-left: 30px;
    margin-bottom: 10px;
}

.help-page dd li {
    margin-left: 15px;
}

/* アルファベットリスト */
.help-alphalist {
    list-style-type: lower-alpha;
}

/* 注釈リスト（※付き） */
.help-note-list {
    list-style: none;
    padding-left: 0;
}

.help-note-list li {
    position: relative;
    padding-left: 1.3em;
    margin-left: 0 !important;
}

.help-note-list li::before {
    content: "※";
    position: absolute;
    left: 0;
    top: 0;
    width: 1em;
    text-align: right;
    vertical-align: top;
    color: #cc0000;
}

/* ========================================
   テーブル
   ======================================== */

.help-page table {
    width: 100%;
    border-collapse: collapse;
    margin: 15px 0;
    border: 1px solid #ccc;
}

.help-page table caption {
    color: #3a636c;
    font-weight: bold;
    text-align: left;
    padding: 5px 0;
}

.help-page table th,
.help-page table td {
    border: 1px solid #aaa;
    padding: 8px 10px;
    text-align: left;
}

.help-page table th {
    background: #f5f6fb;
    color: #000;
    font-weight: normal;
}

.help-page table td {
    background: #fff;
}

.help-page table td.help-total {
    background: #e4fed8;
    font-weight: bold;
}

/* ========================================
   フィールドセット
   ======================================== */

.help-page fieldset {
    border: 1px solid #ccc;
    margin: 15px 0;
    padding: 10px 15px;
}

.help-page fieldset legend {
    padding: 5px 10px;
    color: #407b9b;
    font-weight: bold;
}

/* ========================================
   数式表示
   ======================================== */

.help-math {
    display: block;
    padding: 10px 15px;
    background: #dff2ff;
    margin: 15px 0;
    border-left: 3px solid #25a7f0;
    font-family: 'Courier New', monospace;
}

/* ========================================
   リンク
   ======================================== */

.help-page a {
    color: #25a7f0;
    text-decoration: underline;
}

.help-page a:hover {
    color: #ff0000;
}

/* ========================================
   画像
   ======================================== */

.help-page img {
    border: none;
    max-width: 100%;
    height: auto;
    display: block;
    margin: 15px auto;
}

/* ========================================
   閉じるボタン
   ======================================== */

.help-close {
    text-align: right;
    margin: 15px 15px 15px 0;
    padding-bottom: 10px;
}

.help-close a {
    display: inline-block;
    text-align: center;
    padding: 8px 20px;
    font-size: 14px;
    border-radius: 3px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    transition: all 0.3s ease;
    color: #fff;
    background: #023F64;
    white-space: nowrap;
    text-decoration: none !important;
}

.help-close a:hover {
    background: #0cc8f8;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
    transform: translateY(-1px);
}

/* ========================================
   レスポンシブ対応
   ======================================== */

@media screen and (max-width: 768px) {
    .help-content {
        padding: 10px 15px;
    }

    .help-page h1 {
        font-size: 18px;
        padding: 8px 12px;
    }

    .help-page h2 {
        font-size: 16px;
    }

    .help-page table {
        font-size: 13px;
    }

    .help-page table th,
    .help-page table td {
        padding: 5px 8px;
    }
}

/* ========================================
   印刷対応
   ======================================== */

@media print {
    body.help-page {
        background: #fff;
        font-size: 12pt;
    }

    .help-close {
        display: none;
    }

    .help-page a {
        color: #000;
        text-decoration: none;
    }

    .help-page table th,
    .help-page table td {
        border: 1px solid #000;
    }
}
