/* ============================================================
   modal.css — ポップアップモーダル共通スタイル
   ============================================================ */

/* ------------------------------------------------------------
   モーダルオーバーレイ
   ------------------------------------------------------------ */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1), backdrop-filter 0.3s ease;
    font-family: var(--font-sans);
}

.modal-overlay.is-open {
    opacity: 1;
    pointer-events: auto;
}

/* ------------------------------------------------------------
   モーダルダイアログ（共通枠・出現アニメーション）
   ※ width, max-width, height 等のサイズは各個別CSSで指定
   ------------------------------------------------------------ */
.modal-dialog {
    background-color: #FFFFFF;
    border-radius: 16px;
    width: 100%;
    position: relative;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    transform: scale(0.95) translateY(12px);
    opacity: 0;
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-overlay.is-open .modal-dialog {
    transform: scale(1) translateY(0);
    opacity: 1;
}

/* ------------------------------------------------------------
   閉じるボタン（右上の×ボタン共通）
   ------------------------------------------------------------ */
.modal-close-btn {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 9999px;
    color: #6B7280;
    background-color: #F5F5F4;
    border: none;
    cursor: pointer;
    transition: background-color 0.2s ease, color 0.2s ease;
    font-size: 16px;
}

.modal-close-btn:hover {
    background-color: #E7E5E4;
    color: #374151;
}
