/* =========================================
   BEGINNER / CHARACTERS PAGE
   /assets/css/pages/beginner/characters.css

   依存:
     beginner.css      — ヒーロー・ステップインジケーター・背景グリッド
     beginnerpages.css — fs-body / fs-section / fs-next / パンくず等共通コンポーネント
     characters.css    — .chara-grid / .chara-card / フィルターアコーディオン
   ========================================= */

/* =========================================
   BODY 幅拡張
   キャラグリッドがあるため fs-body より広く取る
   ========================================= */
.bc-body {
    max-width: 1100px;
}

/* イントロの段落間スペース */
.bc-intro p + p { margin-top: 10px; }

/* =========================================
   STARTER CARDS グリッド
   ========================================= */
.bc-starter-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
    margin-bottom: 8px;
}

/* =========================================
   STARTER CARD 本体
   ========================================= */
.bc-starter-card {
    display: flex;
    flex-direction: column;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(255, 255, 255, 0.03);
    overflow: hidden;
    position: relative;
    transition: border-color 0.3s, transform 0.3s;
}

/* 角アクセント（左上・右下） */
.bc-starter-card::before {
    content: '';
    position: absolute;
    top: -1px; left: -1px;
    width: 18px; height: 18px;
    border-top: 2px solid rgba(255, 255, 255, 0.18);
    border-left: 2px solid rgba(255, 255, 255, 0.18);
    z-index: 2;
    pointer-events: none;
    transition: border-color 0.3s;
}
.bc-starter-card::after {
    content: '';
    position: absolute;
    bottom: -1px; right: -1px;
    width: 18px; height: 18px;
    border-bottom: 2px solid rgba(255, 255, 255, 0.18);
    border-right: 2px solid rgba(255, 255, 255, 0.18);
    z-index: 2;
    pointer-events: none;
    transition: border-color 0.3s;
}

/* おすすめカード — シアンアクセント */
.bc-starter-card--recommended {
    border-color: rgba(0, 255, 255, 0.2);
    background: rgba(0, 255, 255, 0.02);
}
.bc-starter-card--recommended::before,
.bc-starter-card--recommended::after {
    border-color: rgba(0, 255, 255, 0.45);
}
.bc-starter-card--recommended:hover {
    border-color: rgba(0, 255, 255, 0.5);
    transform: translateY(-3px);
    box-shadow: 0 8px 32px rgba(0, 255, 255, 0.08);
}

/* 通常カード hover */
.bc-starter-card:not(.bc-starter-card--recommended):hover {
    border-color: rgba(255, 255, 255, 0.22);
    transform: translateY(-2px);
}

/* ---- 画像エリア ---- */
.bc-starter-card__img-wrap {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 7;
    overflow: hidden;
    background: #050508;
}
.bc-starter-card__img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center top;
    transition: transform 0.5s ease;
    filter: brightness(0.75);
}
.bc-starter-card:hover .bc-starter-card__img {
    transform: scale(1.04);
    filter: brightness(0.88);
}
.bc-starter-card__overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, transparent 40%, rgba(0,0,0,0.75) 100%);
}

/* ---- バッジ ---- */
.bc-starter-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    z-index: 3;
    font-size: 0.58rem;
    font-weight: 900;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    padding: 4px 10px;
}
.bc-starter-badge--best {
    color: var(--neon-cyan);
    background: rgba(0, 0, 0, 0.75);
    border: 1px solid var(--neon-cyan);
    text-shadow: 0 0 8px var(--neon-cyan);
}
.bc-starter-badge--strong {
    color: #fff;
    background: rgba(255, 0, 150, 0.75);
    border: 1px solid var(--neon-magenta);
}
.bc-starter-badge--normal {
    color: rgba(255,255,255,0.9);
    background: rgba(0, 0, 0, 0.65);
    border: 1px solid rgba(255,255,255,0.3);
}
.bc-starter-badge--adv {
    color: rgba(255,255,255,0.7);
    background: rgba(0, 0, 0, 0.65);
    border: 1px solid rgba(255,255,255,0.15);
}

/* ---- カード本文エリア ---- */
.bc-starter-card__body {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 18px 20px 20px;
    flex: 1;
}

.bc-starter-card__header {
    display: flex;
    align-items: baseline;
    gap: 10px;
}
.bc-starter-card__en {
    font-size: 1.15rem;
    font-weight: 900;
    font-family: 'Montserrat', sans-serif;
    color: #fff;
    letter-spacing: 0.05em;
}
.bc-starter-card__jp {
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.45);
    letter-spacing: 0.1em;
}

/* ---- タグ ---- */
.bc-starter-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}
.bc-tag {
    font-size: 0.62rem;
    font-weight: 800;
    letter-spacing: 0.15em;
    padding: 3px 8px;
    border: 1px solid;
}
.bc-tag--cyan    { color: var(--neon-cyan);    border-color: rgba(0, 255, 255, 0.4);    background: rgba(0, 255, 255, 0.06); }
.bc-tag--magenta { color: var(--neon-magenta); border-color: rgba(255, 0, 150, 0.4);    background: rgba(255, 0, 150, 0.06); }
.bc-tag--green   { color: #4ade80;             border-color: rgba(74, 222, 128, 0.4);   background: rgba(74, 222, 128, 0.06); }
.bc-tag--yellow  { color: #fbbf24;             border-color: rgba(251, 191, 36, 0.4);   background: rgba(251, 191, 36, 0.06); }
.bc-tag--red     { color: #f87171;             border-color: rgba(248, 113, 113, 0.4);  background: rgba(248, 113, 113, 0.06); }

/* ---- 説明文 ---- */
.bc-starter-card__desc {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.72);
    line-height: 1.8;
    margin: 0;
    flex: 1;
}
.bc-starter-card__desc strong { color: #fff; font-weight: 700; }

/* ---- ステータスバー ---- */
.bc-starter-card__stats {
    display: flex;
    flex-direction: column;
    gap: 7px;
    padding: 14px 0 0;
    border-top: 1px solid rgba(255, 255, 255, 0.07);
}
.bc-stat {
    display: grid;
    grid-template-columns: 5.5em 1fr 4.5em;
    align-items: center;
    gap: 8px;
}
.bc-stat__label {
    font-size: 0.68rem;
    color: rgba(255, 255, 255, 0.45);
    letter-spacing: 0.05em;
    white-space: nowrap;
}
.bc-stat__bar {
    height: 4px;
    background: rgba(255, 255, 255, 0.08);
    position: relative;
    overflow: hidden;
}
.bc-stat__fill {
    display: block;
    height: 100%;
    background: linear-gradient(to right, var(--neon-cyan), rgba(0,255,255,0.5));
    position: absolute;
    left: 0; top: 0;
}
/* 5段階 */
.bc-stat__fill--1 { width: 20%; }
.bc-stat__fill--2 { width: 40%; }
.bc-stat__fill--3 { width: 60%; }
.bc-stat__fill--4 { width: 80%; }
.bc-stat__fill--5 { width: 100%; background: linear-gradient(to right, var(--neon-magenta), rgba(255,0,150,0.5)); }
.bc-stat__val {
    font-size: 0.65rem;
    color: rgba(255, 255, 255, 0.5);
    text-align: right;
    white-space: nowrap;
}

/* ---- CTAボタン ---- */
.bc-starter-card__btn {
    display: inline-block;
    padding: 10px 20px;
    font-size: 0.74rem;
    font-weight: 800;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    text-decoration: none;
    color: var(--neon-cyan);
    border: 1px solid rgba(0, 255, 255, 0.45);
    background: rgba(0, 255, 255, 0.04);
    transition: all 0.25s ease;
    text-align: center;
    margin-top: auto;
}
.bc-starter-card__btn:hover {
    background: #fff;
    color: #000;
    border-color: #fff;
    box-shadow: 0 0 20px rgba(255,255,255,0.2);
}

/* =========================================
   診断ツール
   ========================================= */
.bc-diagnosis {
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(255, 255, 255, 0.02);
    overflow: hidden;
    position: relative;
}
.bc-diagnosis::before {
    content: '';
    position: absolute;
    top: -1px; left: -1px;
    width: 20px; height: 20px;
    border-top: 2px solid rgba(0, 255, 255, 0.4);
    border-left: 2px solid rgba(0, 255, 255, 0.4);
    pointer-events: none;
    z-index: 2;
}

/* ---- 質問エリア ---- */
.bc-diag-q {
    display: none;
    padding: 36px 32px;
}
.bc-diag-q.is-active { display: block; }

.bc-diag-q__label {
    font-size: 0.62rem;
    font-weight: 800;
    letter-spacing: 0.4em;
    color: var(--neon-cyan);
    text-shadow: 0 0 8px var(--neon-cyan);
    text-transform: uppercase;
    margin-bottom: 12px;
}
.bc-diag-q__text {
    font-size: clamp(1.1rem, 2.5vw, 1.6rem);
    font-weight: 900;
    color: #fff;
    margin: 0 0 28px;
    line-height: 1.3;
}

/* ---- 選択肢ボタン ---- */
.bc-diag-choices {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}
.bc-diag-choice {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 18px 16px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.12);
    cursor: pointer;
    color: rgba(255, 255, 255, 0.7);
    transition: all 0.25s ease;
    position: relative;
    min-height: 64px;
}
.bc-diag-choice::before {
    content: '';
    position: absolute;
    top: -1px; left: -1px;
    width: 10px; height: 10px;
    border-top: 2px solid rgba(0, 255, 255, 0.3);
    border-left: 2px solid rgba(0, 255, 255, 0.3);
    transition: border-color 0.25s;
}
.bc-diag-choice:hover {
    background: rgba(0, 255, 255, 0.07);
    border-color: rgba(0, 255, 255, 0.45);
    color: #fff;
    transform: translateY(-2px);
}
.bc-diag-choice:hover::before {
    border-color: var(--neon-cyan);
}
.bc-diag-choice__text {
    font-size: 0.86rem;
    font-weight: 700;
    text-align: center;
    line-height: 1.45;
    letter-spacing: 0.03em;
}

/* ---- 結果エリア ---- */
.bc-diag-result {
    padding: 36px 32px;
}
.bc-diag-result__label {
    font-size: 0.6rem;
    font-weight: 900;
    letter-spacing: 0.45em;
    color: var(--neon-cyan);
    text-shadow: 0 0 8px var(--neon-cyan);
    text-transform: uppercase;
    margin-bottom: 24px;
}
.bc-diag-result__inner {
    display: grid;
    grid-template-columns: 220px 1fr;
    gap: 32px;
    align-items: center;
}

.bc-diag-result__img-wrap {
    position: relative;
    aspect-ratio: 10 / 14;
    overflow: hidden;
    background: #050508;
    clip-path: polygon(15% 0, 100% 0, 85% 100%, 0% 100%);
}
.bc-diag-result__img-glow {
    position: absolute;
    inset: 0;
    box-shadow: inset 0 0 30px rgba(0, 255, 255, 0.25);
    pointer-events: none;
    z-index: 2;
}
.bc-diag-result__img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center top;
}

.bc-diag-result__rec {
    font-size: 0.7rem;
    font-weight: 800;
    letter-spacing: 0.3em;
    color: rgba(255, 255, 255, 0.4);
    text-transform: uppercase;
    margin-bottom: 8px;
}
.bc-diag-result__name {
    font-size: clamp(1.5rem, 4vw, 2.4rem);
    font-weight: 900;
    font-family: 'Montserrat', sans-serif;
    color: #fff;
    text-shadow: 0 0 20px rgba(0,255,255,0.3);
    margin: 0 0 14px;
    line-height: 1.1;
}
.bc-diag-result__reason {
    font-size: 0.88rem;
    color: rgba(255, 255, 255, 0.72);
    line-height: 1.8;
    margin: 0 0 24px;
}

.bc-result-cta {
    display: inline-block;
    margin-bottom: 14px;
}

.bc-diag-retry {
    display: block;
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.35);
    font-size: 0.75rem;
    letter-spacing: 0.1em;
    cursor: pointer;
    padding: 0;
    transition: color 0.2s;
}
.bc-diag-retry:hover { color: rgba(255, 255, 255, 0.7); }

/* =========================================
   全キャラ一覧 — フィルター・グリッド調整
   ========================================= */
.bc-allchara-note {
    margin-bottom: 20px;
    padding: 14px 18px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.02);
}
.bc-allchara-note p {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.65);
    line-height: 1.75;
    margin: 0;
}
.bc-allchara-note strong { color: #fff; }

/* フィルターの上マージン調整（beginner文脈では余白を詰める） */
.bc-filter-console {
    margin-top: 0;
    margin-bottom: 0;
    padding: 0;
}

/* キャラグリッドのパディング調整 */
.bc-chara-hub { padding: 24px 0 40px; }

/* =========================================
   RESPONSIVE
   ========================================= */
@media (max-width: 900px) {
    .bc-starter-grid { grid-template-columns: 1fr 1fr; gap: 16px; }
    .bc-diag-choices { grid-template-columns: 1fr; gap: 10px; }
    .bc-diag-choice { padding: 14px 18px; }
}

@media (max-width: 768px) {
    .bc-starter-grid { grid-template-columns: 1fr; gap: 16px; }

    .bc-diag-result__inner {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    .bc-diag-result__img-wrap {
        max-width: 200px;
        margin: 0 auto;
    }
    .bc-diag-q { padding: 24px 20px; }
    .bc-diag-result { padding: 24px 20px; }
}

@media (max-width: 480px) {
    .bc-stat { grid-template-columns: 5em 1fr 4em; }
    .bc-starter-card__body { padding: 14px 16px 16px; }
    .bc-diag-choices { gap: 8px; }
    .bc-diag-choice { padding: 12px 14px; }
}