/**
 * 모달 공통 스타일
 * 세 파일에서 공통으로 사용되는 모달 스타일
 */

/* 모달 오버레이 */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(6px);
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideIn {
    from { 
        opacity: 0;
        transform: translate(-50%, -60%);
    }
    to { 
        opacity: 1;
        transform: translate(-50%, -50%);
    }
}

/* 모달 콘텐츠 */
.modal-content {
    background: var(--card-bg);
    margin: auto;
    padding: 0;
    border-radius: var(--border-radius-lg);
    width: 90%;
    max-width: 600px;
    max-height: 80vh;
    overflow: hidden;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.15);
    animation: slideIn 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.modal-header {
    padding: var(--spacing-lg) var(--spacing-xl);
    background: linear-gradient(135deg, var(--primary-light), #f8f9fa);
    border-bottom: 1px solid var(--border-color);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.modal-header h3 {
    margin: 0;
    color: var(--primary-dark);
    font-size: 1.4rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.modal-content h3 {
    margin: 0;
    color: var(--primary-dark);
    font-size: 1.4rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.modal-body {
    padding: var(--spacing-xl);
    max-height: calc(80vh - 80px);
    overflow-y: auto;
}

.modal-body p {
    color: var(--text-light);
    margin-bottom: 1.5rem;
    margin-top: 0;
}

/* 닫기 버튼 */
.close-btn {
    position: relative;
    top: 0;
    right: 0;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    background: transparent;
    border: none;
    cursor: pointer;
    color: var(--text-muted);
    transition: all 0.2s ease;
    font-size: 0;
    font-weight: 400;
    flex-shrink: 0;
}

.close-btn:hover {
    background: rgba(0, 0, 0, 0.08);
    color: var(--text-color);
    transform: scale(1.05);
}

.close-btn:active {
    transform: scale(0.95);
}

.close-btn::before {
    content: "✕";
    font-family: inherit;
    font-weight: 300;
    font-size: 1.5rem;
    line-height: 1;
}

