/* Share Panel Styles */

/* シェアボタン（記事見出しに追加） */
.share-button {
    display: inline-block;
    margin-left: 0.5rem;
    padding: 0.2rem 0.4rem;
    background: transparent;
    border: none;
    color: #6c757d;
    cursor: pointer;
    font-size: 0.9rem;
    vertical-align: middle;
    transition: color 0.2s;
}

.share-button:hover {
    color: #212529;
}

/* オーバーレイ */
.share-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    animation: fadeIn 0.2s;
}

.share-overlay.active {
    display: flex;
}

/* モーダル本体 */
.share-modal {
    background: white;
    border-radius: 8px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
    padding: 20px;
    max-width: 500px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    position: relative;
    animation: slideUp 0.3s;
}

/* 閉じるボタン */
.close-button {
    position: absolute;
    top: 10px;
    right: 10px;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #6c757d;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.close-button:hover {
    color: #000;
}

/* パネル内の見出し */
.share-modal h1 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #dee2e6;
}

.share-modal h2 {
    font-size: 1.1rem;
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
    color: #495057;
}

/* SNSボタン */
.sns-buttons {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.sns-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 16px;
    border-radius: 4px;
    text-decoration: none;
    color: white;
    font-size: 0.9rem;
    transition: opacity 0.2s;
}

.sns-button:hover {
    opacity: 0.8;
    color: white;
}

.sns-button i {
    margin-right: 6px;
}

.sns-button.twitter {
    background-color: #1da1f2;
}

.sns-button.bluesky {
    background-color: #0085ff;
}

.sns-button.facebook {
    background-color: #1877f2;
}

.sns-button.hatena {
    background-color: #00a4de;
}

/* テキストエリア */
.share-textarea {
    width: 100%;
    min-height: 80px;
    padding: 10px;
    border: 1px solid #ced4da;
    border-radius: 4px;
    font-family: monospace;
    font-size: 0.9rem;
    resize: vertical;
}

.share-textarea:focus {
    outline: none;
    border-color: #86b7fe;
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.25);
}

/* コピーボタン */
.copy-button {
    margin-top: 8px;
    padding: 4px 12px;
    font-size: 0.85rem;
}

/* アニメーション */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        transform: translateY(20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* モバイル対応 */
@media (max-width: 576px) {
    .share-modal {
        width: 95%;
        max-height: 90vh;
        padding: 15px;
    }
    
    .sns-buttons {
        flex-direction: column;
    }
    
    .sns-button {
        width: 100%;
    }
}