/* 구독 및 유료 컨텐츠 모달 공통 CSS */

.subscription-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    backdrop-filter: blur(4px);
}

.subscription-modal {
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    border-radius: 20px;
    width: 90%;
    max-width: 480px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
    animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(30px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.modal-header {
    padding: 20px 20px 15px;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-title {
    font-size: 20px;
    font-weight: 700;
    color: #1a202c;
    margin: 0;
}

.close-btn {
    background: none;
    border: none;
    font-size: 24px;
    color: #718096;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background-color 0.2s;
}

.close-btn:hover {
    background: #f7fafc;
    color: #2d3748;
}

.creator-info {
    padding: 15px;
    display: flex;
    align-items: center;
    gap: 15px;
    border-bottom: 1px solid #e2e8f0;
}

.creator-avatar {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    overflow: hidden;
}

.creator-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.creator-name {
    font-size: 18px;
    font-weight: 600;
    color: #1a202c;
    margin: 0 0 5px 0;
}

.creator-description {
    font-size: 14px;
    color: #718096;
    margin: 0 0 15px 0;
}

.subscription-benefits {
    font-size: 14px;
    color: #4a5568;
    line-height: 1.6;
    margin-top: 10px;
}

.subscription-plans {
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.plan-card {
    background: linear-gradient(135deg, #00aff0 0%, #0091ea 100%);
    color: white;
    border: 2px solid #00aff0;
    border-radius: 12px;
    padding: 16px 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    box-shadow: 0 2px 8px rgba(0, 175, 240, 0.2);
}

.plan-card:hover {
    background: linear-gradient(135deg, #0091ea 0%, #1976d2 100%);
    border-color: #0091ea;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 175, 240, 0.3);
}

.plan-card.selected {
    background: linear-gradient(135deg, #28a745 0%, #1e7e34 100%);
    border-color: #28a745;
    box-shadow: 0 4px 12px rgba(40, 167, 69, 0.3);
}

.plan-card.best-value {
    background: linear-gradient(135deg, #00aff0 0%, #0091ea 100%);
    border-color: #00aff0;
    color: white;
}

.plan-card.best-value:hover {
    background: linear-gradient(135deg, #0091ea 0%, #1976d2 100%);
    border-color: #0091ea;
}

.plan-card.best-value.selected {
    background: linear-gradient(135deg, #28a745 0%, #1e7e34 100%);
    border-color: #28a745;
    color: white;
}

/* 무료 플랜 스타일 */
.plan-card.free-plan {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    border-color: #28a745;
    color: white;
}

.plan-card.free-plan:hover {
    background: linear-gradient(135deg, #20c997 0%, #17a2b8 100%);
    border-color: #20c997;
}

.plan-card.free-plan.selected {
    background: linear-gradient(135deg, #155724 0%, #1e7e34 100%);
    border-color: #155724;
}

.plan-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.plan-text {
    font-size: 16px;
    font-weight: 400;
}

.plan-total {
    font-size: 16px;
    font-weight: 700;
}

.modal-footer {
    padding: 20px;
    border-top: 1px solid #e2e8f0;
}

.subscribe-btn {
    width: 100%;
    background: linear-gradient(135deg, #00aff0 0%, #0091ea 100%);
    color: white;
    border: none;
    border-radius: 15px;
    padding: 16px 24px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 15px;
}

.subscribe-btn:hover {
    background: linear-gradient(135deg, #0091ea 0%, #1976d2 100%);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 175, 240, 0.3);
}

.subscribe-btn:disabled {
    background: #cbd5e0;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* 무료 구독 버튼 스타일 */
.subscribe-btn.free-subscription {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
}

.subscribe-btn.free-subscription:hover {
    background: linear-gradient(135deg, #20c997 0%, #17a2b8 100%);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(40, 167, 69, 0.3);
}

.btn-price {
    font-weight: 700;
}

.terms-text {
    font-size: 12px;
    color: #718096;
    text-align: center;
    margin: 0;
    line-height: 1.4;
}

.terms-text a {
    color: #00aff0;
    text-decoration: none;
}

.terms-text a:hover {
    text-decoration: underline;
}

/* 로딩 스피너 스타일 */
.loading-container {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    padding: 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
    backdrop-filter: blur(10px);
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #e2e8f0;
    border-top: 4px solid #00aff0;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loading-text {
    font-size: 16px;
    color: #4a5568;
    font-weight: 500;
    text-align: center;
}

/* 유료 컨텐츠 관련 스타일 */
.content-type-info {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 10px;
}

.content-type-badge {
    display: flex;
    align-items: center;
    gap: 5px;
    background: rgba(0, 175, 240, 0.1);
    border: 1px solid #00aff0;
    border-radius: 8px;
    padding: 4px 8px;
}

.content-type-badge span {
    font-size: 12px;
    color: #00aff0;
    font-weight: 500;
}

/* 모바일 최적화 */
@media (max-width: 480px) {
    .subscription-modal {
        width: 95%;
        margin: 10px;
        max-height: 95vh;
    }

    .modal-title {
        font-size: 18px;
    }

    .creator-info {
        padding: 15px;
    }

    .creator-avatar {
        width: 50px;
        height: 50px;
    }

    .creator-name {
        font-size: 16px;
    }

    .subscription-plans {
        padding: 15px;
        gap: 12px;
    }

    .plan-card {
        padding: 15px;
    }

    .plan-duration {
        font-size: 16px;
    }

    .price {
        font-size: 20px;
    }

    .modal-footer {
        padding: 15px;
    }
}
