@charset "utf-8";

/* メインコンテナ */
.protected-content {
    position: relative;
    margin-bottom: 2em;
}

/* 可視部分のスタイル */
.content-visible {
    margin-bottom: 2em;
    line-height: 1.8;
}

/* プレビュー部分のスタイル */
.content-preview-blur {
    position: relative;
    padding: 1.5em 0;
    margin-bottom: 2em;
    max-height: 500px;
    overflow: hidden;
    filter: blur(var(--blur-strength, 3px));
    -webkit-filter: blur(var(--blur-strength, 3px));
    opacity: 0.7;
    transform: translateZ(0);
    will-change: transform;
    line-height: 1.8;
}

/* グラデーションマスク */
.content-preview-blur::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 150px;
    background: linear-gradient(
        rgba(255, 255, 255, 0),
        rgba(255, 255, 255, 1)
    );
    pointer-events: none;
}

/* 残りコンテンツ情報のスタイル */
.c-remaining {
    text-align: center;
    margin: 2em 0;
    padding: 1em;
}

.c-remaining__title {
    font-size: 1.2em;
    font-weight: 700;
    position: relative;
    display: inline-block;
    margin-bottom: 1em;
    padding: 0 3em;
}

.c-remaining__title::before,
.c-remaining__title::after {
    content: "";
    position: absolute;
    top: 50%;
    width: 2em;
    height: 1px;
    background: rgba(8,19,26,0.66);
}

.c-remaining__title::before {
    left: 0;
}

.c-remaining__title::after {
    right: 0;
}

.c-remaining__count {
    font-size: 0.75rem;
    color: rgba(8,19,26,0.66);
}

/* パスワードフォームのスタイル */
.p-passwordForm {
    margin-top: 3em;
    padding: 2em;
    background: #f8f9fa;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

/* ブログパーツエリア */
.password-form-blog-parts {
    margin: 2em 0;
    padding: 1em;
    background: #fff;
    border-radius: 4px;
}

.password-form-blog-parts:first-child {
    margin-top: 0;
}

.password-form-blog-parts:last-child {
    margin-bottom: 0;
}

/* パスワードフォーム要素 */
.c-pw__title {
    font-size: 1.2em;
    font-weight: bold;
    margin-bottom: 1.5em;
    text-align: center;
    color: #333;
}

.c-pw__form {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1em;
}

.c-pw__input {
    width: 100%;
    max-width: 400px;
}

.c-pw__pwd {
    width: 100%;
    padding: 0.8em;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1em;
    transition: border-color 0.3s ease;
}

.c-pw__pwd:focus {
    border-color: #4a90e2;
    outline: none;
    box-shadow: 0 0 0 2px rgba(74, 144, 226, 0.2);
}

.c-pw__btn {
    padding: 0.8em 2em;
    background: #4a90e2;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 1em;
    cursor: pointer;
    transition: all 0.3s ease;
}

.c-pw__btn:hover {
    background: #357abd;
    transform: translateY(-1px);
}

.c-pw__btn:active {
    transform: translateY(0);
}

.c-pw__btn:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
}

.c-pw__error {
    color: #dc3545;
    text-align: center;
    margin-top: 1em;
    padding: 0.5em;
    font-size: 0.9em;
    animation: fadeIn 0.3s ease-in-out;
}

/* 管理画面用のスタイル */
.preview-protector-range {
    width: 200px;
    vertical-align: middle;
}

.preview-protector-range-value {
    margin-left: 10px;
    font-weight: bold;
}

/* アニメーション */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* レスポンシブ対応 */
@media screen and (max-width: 767px) {
    .p-passwordForm {
        padding: 1.5em;
        margin: 2em -1em 0;
        border-radius: 0;
    }

    .c-pw__input {
        width: 100%;
        max-width: 100%;
    }

    .c-pw__btn {
        width: 100%;
    }

    .password-form-blog-parts {
        margin: 1.5em 0;
        padding: 0.8em;
    }
}

/* 印刷時の対応 */
@media print {
    .protected-content,
    .p-passwordForm,
    .password-form-blog-parts {
        display: none !important;
    }
}