@charset "UTF-8";

/* =========================================================
   記事ページ（/articles/）専用スタイル

   経理FC（keiri-jobs.com）の resources/views/articles/index.blade.php と
   show.blade.php のページ内CSSを移植したもの。
   ★ クラス名は1つも変えていない。同じマーケ担当が両サイトの本文を書くため、
     .article_h2 / .markerYellow / .lp_button_wrap などの記法を共通に保つ。
     変えたのは色（経理FCのアクセントは赤系）とブレークポイントだけ。

   SP 先行。PC 用は @media screen and (min-width: 601px) に書く（既存LPと共通の規約）。
   ========================================================= */

/* --navy / --orange / --bg / --text / --font-ja は assets/top/css/style.css の :root から受け取る。
   ヘッダ・フッタをトップページと共有しているので、色を二重に持たない。 */
:root {
    --article-bg: var(--bg);
    --article-text: var(--text);
    --article-mute: #6b7280;
    --article-line: #dfe3ea;
    --article-white: #ffffff;

    /* 段組みの基準。ヘッダ・パンくず・本体・フッタが同じ縦のラインに乗るよう、
       幅は必ずここを参照する。個別にベタ書きすると左端がずれる。 */
    --article-container: 1052px;
    --article-gutter: 16px;
    --article-sidebar: 262px;
    --article-gap: 28px;
}

/* ブレークポイントは2種類ある。メディアクエリには変数を使えないので、意味をここに書いておく。
     601px  カードを2列にする（既存LPと共通の規約）
     901px  サイドバーを本文の横に出す
   サイドバーを 601px で横に出すと、本文が 261px まで潰れて表や CTA が崩れる。 */

/* 記事が少ないとページが画面の高さに満たず、フッタの下に地の色が残る。
   body を縦方向の flex にして本文に余りを吸わせ、フッタを必ず最下部に置く。 */
.p-article-page {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    margin: 0;
    background: var(--article-bg);
    color: var(--article-text);
    font-family: var(--font-ja);
    font-size: 14px;
    line-height: 1.8;
    -webkit-font-smoothing: antialiased;
}
/* リセットは :where() で包んで詳細度を 0 にする。
   `.p-article-page ol`（クラス1+要素1）は `.breadcrumb`（クラス1）より強いため、
   素で書くとリセットの margin/padding/color が個別クラスの指定を打ち消してしまう。
   実際に .breadcrumb の `margin: 0 auto` が効かず左端に張り付いていた。
   :where() の中身は詳細度に加算されないので、以降のクラス指定が素直に勝つ。 */
.p-article-page *,
.p-article-page *::before,
.p-article-page *::after { box-sizing: border-box; }
.p-article-page :where(h1, h2, h3, h4, p, ul, ol, figure) { margin: 0; }
.p-article-page :where(ul, ol) { padding: 0; list-style: none; }
.p-article-page :where(img) { max-width: 100%; height: auto; }
.p-article-page :where(a) { color: inherit; text-decoration: none; }

/* ── ヘッダ ─────────────────────────────────────────────
   見た目は assets/top/css/style.css の .header をそのまま使う。
   ただしトップページは MV がヘッダの下に潜り込む前提で position: fixed のぶんの
   余白を持たないので、記事ページでは自前で空ける（SP 56px / PC 80px = ヘッダの高さ）。 */
.p-article-page { padding-top: 56px; }
@media screen and (min-width: 601px) {
    .p-article-page { padding-top: 80px; }
}

/* ── パンくず ──────────────────────────────────────────── */
.breadcrumb-bar {
    background: var(--article-bg);
    border-bottom: 1px solid var(--article-line);
}
.breadcrumb {
    max-width: var(--article-container);
    margin: 0 auto;
    padding: 10px var(--article-gutter);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    font-size: 11.5px;
    color: var(--article-mute);
}
.breadcrumb__link { color: var(--navy); font-weight: 500; }
.breadcrumb__link:hover { text-decoration: underline; }
.breadcrumb__sep {
    display: inline-block;
    width: 5px;
    height: 5px;
    border-top: 1.5px solid #aab;
    border-right: 1.5px solid #aab;
    transform: rotate(45deg);
    margin: 0 8px;
}
.breadcrumb__current { color: #374151; }

/* ── ページ本体 ────────────────────────────────────────── */
.article-main { flex: 1 0 auto; padding: 26px 0 40px; }
.article-main__inner { max-width: var(--article-container); margin: 0 auto; padding: 0 var(--article-gutter); }
@media screen and (min-width: 601px) { .article-main { padding: 34px 0 48px; } }

/* ── 一覧: 見出し ─────────────────────────────────────── */
.articles-section { margin-bottom: 22px; }
.articles-section__en {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.2em;
    color: var(--orange);
    margin-bottom: 5px;
}
.articles-section__title {
    font-size: 21px;
    font-weight: 700;
    color: var(--navy);
    line-height: 1.35;
}
@media screen and (min-width: 601px) { .articles-section__title { font-size: 26px; } }

/* ── 一覧: カードグリッド（SP 1列 / 601px〜 2列 / 901px〜 3列） ── */
.article-grid { display: grid; grid-template-columns: 1fr; gap: 20px; }
@media screen and (min-width: 601px) { .article-grid { grid-template-columns: repeat(2, 1fr); } }
@media screen and (min-width: 901px) { .article-grid { grid-template-columns: repeat(3, 1fr); } }

.article-card {
    display: flex;
    flex-direction: column;
    background: var(--article-white);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(26, 50, 97, 0.1);
    transition: box-shadow 0.2s, transform 0.2s;
}
.article-card:hover {
    box-shadow: 0 6px 18px rgba(26, 50, 97, 0.14);
    transform: translateY(-2px);
}
.article-card__thumb {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: linear-gradient(135deg, #22406f 0%, #1a3261 55%, #14264a 100%);
}
.article-card__thumb img { width: 100%; height: 100%; object-fit: cover; }
/* アイキャッチ未設定のときだけ、紺一色にならないよう右下に薄い円を敷く */
.article-card__thumb--empty::after {
    content: "";
    position: absolute;
    right: -22%;
    bottom: -58%;
    width: 118%;
    aspect-ratio: 1;
    border-radius: 50%;
    background: rgba(205, 211, 224, 0.16);
}
.article-card__thumb-empty {
    position: absolute;
    left: 12px;
    bottom: 10px;
    z-index: 2;
    font-size: 9px;
    letter-spacing: 0.14em;
    color: rgba(255, 255, 255, 0.6);
}
.article-card__body { display: flex; flex-direction: column; flex: 1; padding: 13px 15px 16px; }
.article-card__date {
    display: block;
    font-size: 11px;
    color: var(--article-mute);
    letter-spacing: 0.04em;
}
.article-card__title {
    font-size: 14px;
    font-weight: 700;
    color: var(--article-text);
    line-height: 1.55;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.articles-empty { padding: 60px 0; text-align: center; color: var(--article-mute); font-size: 14px; }

/* ── 詳細: 2カラム（901px 未満は1カラム） ──────────────────
   一覧カードの 601px とは切り替え幅が違う。601px でサイドバーを横に出すと
   本文が 261px しか残らず、表・CTA・コードが軒並み崩れるため。 */
.article-layout { display: flex; flex-direction: column; gap: 24px; }
@media screen and (min-width: 901px) {
    .article-layout { flex-direction: row; align-items: flex-start; gap: var(--article-gap); }
    .article-layout__sidebar { width: var(--article-sidebar); flex-shrink: 0; }
}
.article-layout__main {
    flex: 1;
    min-width: 0;
    background: var(--article-white);
    border-radius: 10px;
    padding: 22px 18px 28px;
}
@media screen and (min-width: 601px) { .article-layout__main { padding: 30px 34px 36px; } }

/* ── 詳細: 記事ヘッダ ─────────────────────────────────── */
.article-header { margin-bottom: 18px; }
.article-header__meta { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; margin-bottom: 11px; }
.article-header__date { font-size: 12px; color: var(--article-mute); letter-spacing: 0.04em; }
.article-header__title { font-size: 20px; font-weight: 700; line-height: 1.45; color: var(--navy); }
@media screen and (min-width: 601px) { .article-header__title { font-size: 24px; } }

.article-hero { margin: 0 0 26px; border-radius: 8px; overflow: hidden; }
.article-hero img { width: 100%; height: auto; display: block; }

/* ── 詳細: 本文 ────────────────────────────────────────
   ここから下のクラス名は経理FCと同一。追加・改名しないこと。 */
.article-body { font-size: 13.5px; line-height: 1.95; color: #333; }
.article-body p { margin: 8px 0; }
.article-body a { color: var(--navy); text-decoration: underline; }

.article-body h2.article_h2 {
    font-size: 17px;
    font-weight: 700;
    color: var(--navy);
    border-left: 5px solid var(--orange);
    padding: 7px 0 7px 13px;
    margin: 28px 0 12px;
    line-height: 1.5;
}
.article-body h4.article_h4 {
    font-size: 14.5px;
    font-weight: 700;
    color: #2b3550;
    margin: 18px 0 7px;
    line-height: 1.5;
}

/* 本文中の目次（ツールバーの「目次」ボタンで手動挿入する） */
.article-body .mokuji {
    background: var(--article-bg);
    border-radius: 8px;
    padding: 16px 20px;
    margin: 0 0 26px;
}
.article-body .mokuji h2 {
    font-size: 14px;
    font-weight: 700;
    color: var(--navy);
    margin-bottom: 7px;
    border: none;
    padding: 0;
}
.article-body .mokuji ol { padding-left: 20px; margin: 0; list-style: decimal; }
.article-body .mokuji li { margin: 4px 0; font-size: 12.5px; line-height: 1.8; }
.article-body .mokuji a { color: var(--navy); }

.article-body .article_blockquote {
    border-left: 4px solid #d1d5db;
    padding: 11px 18px;
    margin: 18px 0;
    background: #f9fafb;
    color: var(--article-mute);
    font-style: italic;
}

.article-body .mark_addition_ul { padding-left: 22px; margin: 12px 0; list-style: disc; }
.article-body .mark_addition_ol { padding-left: 22px; margin: 12px 0; list-style: decimal; }
.article-body .mark_addition_ul li,
.article-body .mark_addition_ol li { margin: 5px 0; }

.article-body .markerYellow { background: linear-gradient(transparent 60%, #fef08a 60%); padding: 0 2px; }
.article-body .markerBlue { background: linear-gradient(transparent 60%, #bfdbfe 60%); padding: 0 2px; }
.article-body .markerGreen { background: linear-gradient(transparent 60%, #bbf7d0 60%); padding: 0 2px; }
.article-body .markerPink { background: linear-gradient(transparent 60%, #fbcfe8 60%); padding: 0 2px; }

.article-body .sc_frame_wrap { margin: 18px 0; border-radius: 8px; overflow: hidden; }
.article-body .sc_frame_wrap_a { border: 2px solid var(--navy); }
.article-body .sc_frame_wrap_a .sc_frame_title { background: var(--navy); }
.article-body .sc_frame_wrap_b { border: 2px solid #1c7a4c; }
.article-body .sc_frame_wrap_b .sc_frame_title { background: #1c7a4c; }
.article-body .sc_frame_wrap_c { border: 2px solid var(--orange); }
.article-body .sc_frame_wrap_c .sc_frame_title { background: var(--orange); }
.article-body .sc_frame_title { color: #fff; font-weight: 700; font-size: 13px; padding: 7px 15px; }
.article-body .sc_frame { padding: 14px 16px; }
.article-body .sc_frame_text { font-size: 13px; line-height: 1.85; }

.article-body .article_table { width: 100%; border-collapse: collapse; margin: 14px 0; font-size: 12.5px; }
.article-body .article_table th,
.article-body .article_table td { border: 1px solid #d1d5db; padding: 8px 12px; text-align: left; }
.article-body .article_table th { background: #f3f4f6; font-weight: 700; }
.article-body .article_table thead th { background: var(--navy); color: #fff; }

.article-body .out_site_url { color: var(--navy); text-decoration: underline; }
.article-body .article_link { margin: 16px 0; }
.article-body .article_link a { color: var(--navy); text-decoration: underline; font-weight: 500; }

/* CTA */
.article-body .lp_button_wrap { margin: 24px 0; text-align: center; }
.article-body .lp_button_wrap .inner_wrap a {
    display: inline-block;
    background: var(--orange);
    color: #fff;
    text-decoration: none;
    font-weight: 700;
    font-size: 14px;
    padding: 14px 34px;
    border-radius: 999px;
    min-height: 44px;
    box-shadow: 0 3px 0 rgba(0, 0, 0, 0.14);
}
.article-body .lp_button_wrap .inner_wrap a p { margin: 0; color: #fff; line-height: 1.2; }

.article-body .article_video { margin: 18px 0; }
.article-body .article_video iframe { width: 100%; aspect-ratio: 16 / 9; height: auto; border: 0; }

/* ── 詳細: 執筆者 ──────────────────────────────────────── */
.article-author {
    margin-top: 30px;
    padding: 18px;
    background: var(--article-bg);
    border-radius: 8px;
}
.article-author__label { font-size: 10.5px; color: var(--article-mute); font-weight: 700; letter-spacing: 0.04em; }
.article-author__name { margin-top: 4px; font-size: 15px; font-weight: 700; color: var(--navy); line-height: 1.4; }
/* 入力欄に打った改行をそのまま出す（肩書きと紹介文を分けたい、等）。
   pre-line なので、行頭の字下げや連続空白までは持ち込まれない */
.article-author__bio { margin-top: 10px; font-size: 12.5px; line-height: 1.9; color: var(--article-text); white-space: pre-line; }

/* ── 詳細: 一覧に戻る ─────────────────────────────────── */
.article-back { margin-top: 34px; padding-top: 20px; border-top: 1px solid var(--article-line); }
.article-back__link { font-size: 13px; font-weight: 500; color: var(--navy); text-decoration: underline; }

/* ── サイドバー ────────────────────────────────────────── */
.sidebar-section {
    background: var(--article-white);
    border-radius: 10px;
    padding: 17px 19px;
    margin-bottom: 16px;
}
.sidebar-section__title {
    font-size: 12.5px;
    font-weight: 700;
    color: var(--navy);
    padding-bottom: 9px;
    margin-bottom: 10px;
    border-bottom: 2px solid var(--orange);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}
.sidebar-section__title em {
    font-style: normal;
    font-size: 8.5px;
    letter-spacing: 0.08em;
    color: var(--article-mute);
    font-weight: 400;
}

.sidebar-toc__list { font-size: 12px; line-height: 1.65; }
.sidebar-toc__item { border-bottom: 1px dotted #e3e6ec; }
.sidebar-toc__item:last-child { border-bottom: 0; }
.sidebar-toc__link {
    display: block;
    position: relative;
    padding: 5px 0 5px 15px;
    color: #3d4658;
}
.sidebar-toc__link::before {
    content: "";
    position: absolute;
    left: 3px;
    top: 13px;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--orange);
}
.sidebar-toc__link:hover { color: var(--navy); }

.related-item { border-bottom: 1px dotted #e3e6ec; }
.related-item:last-child { border-bottom: 0; }
.related-item__link { display: flex; gap: 10px; padding: 9px 0; }
.related-item__link:hover { opacity: 0.7; }
.related-item__thumb {
    width: 62px;
    flex: none;
    aspect-ratio: 16 / 9;
    border-radius: 4px;
    overflow: hidden;
    background: linear-gradient(135deg, #22406f, #14264a);
}
.related-item__thumb img { width: 100%; height: 100%; object-fit: cover; }
.related-item__thumb-empty {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 8px;
    color: rgba(255, 255, 255, 0.6);
}
.related-item__body { flex: 1; min-width: 0; }
.related-item__title {
    font-size: 11px;
    font-weight: 700;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* 2カラムになってから追従させる（1カラムでは stick しても意味がない） */
@media screen and (min-width: 901px) {
    .sidebar-sticky { position: sticky; top: 20px; }
}

/* フッタ（.p-footer）は assets/top/css/style.css の指定をそのまま使うので、
   ここには何も持たない。トップページと差が出ないようにするため。 */
