/*
 * 会員限定記事 - ペイウォール風ゲート
 *
 * 未ログイン時に本文をブラーして読めなくし、その上にログイン/会員登録 CTA を
 * オーバーレイ表示する。写真は視認できるため会員登録のトリガーとして機能する。
 */

/* ちらつき防止: Vue マウント前は本文をブラーしておく
 * カスタム要素セレクタを使用。Vue マウント後はコンポーネントの
 * テンプレート（.members-only-gate）に置換されるためこのルールは無効になる */
members-only-gate {
    display: block;
    filter: blur(8px);
    user-select: none;
    pointer-events: none;
}

/* Vue マウント後のラッパー */
.members-only-gate {
    position: relative;
}

/* ロック中（未ログイン）の本文表示 */
.members-only-gate.is-locked .members-only-gate__content {
    filter: blur(8px);
    user-select: none;
    pointer-events: none;
    /* スクリーンリーダーからは隠す（aria は別途 noise になるので最低限） */
}
.members-only-gate.is-locked .members-only-gate__content * {
    /* 子要素のリンク・ボタンを操作不可にする */
    pointer-events: none !important;
}

/* オーバーレイ CTA カード: 記事本文の左右中央・上部に配置 */
.members-only-gate__overlay {
    position: absolute;
    top: 24px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
    width: calc(100% - 32px);
    max-width: 420px;
    padding: 32px 24px;
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    text-align: center;
}

.members-only-gate__title {
    font-size: 18px;
    font-weight: bold;
    margin: 0 0 8px;
    color: #333;
}

.members-only-gate__lead {
    font-size: 14px;
    color: #666;
    margin: 0 0 20px;
    line-height: 1.6;
}

.members-only-gate__cta {
    display: inline-block;
    padding: 12px 28px;
    /* 白文字とのコントラスト比 5.2:1（WCAG AA 通過） */
    background-color: #8a6a00;
    color: #fff;
    text-decoration: none;
    border-radius: 4px;
    font-weight: bold;
    font-size: 15px;
    transition: opacity 0.2s;
}

.members-only-gate__cta:hover {
    opacity: 0.85;
    color: #fff;
}

.members-only-gate__register {
    display: block;
    margin-top: 16px;
    font-size: 13px;
    color: #666;
    text-decoration: underline;
}

.members-only-gate__register:hover {
    color: #333;
}
