/* 통합 수술비 검색 결과 스타일 - 심플 버전 */

.results-content {
    padding: 0;
}

.results-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
}

/* N-level 카드는 전체 너비, 단일 열 */
.result-card.n-level-card {
    grid-column: 1 / -1;
}

/* 일반 수술비 결과는 2열 그리드 (N-level 아래) */
.result-card:not(.n-level-card) {
    /* 기본적으로 1열, 미디어 쿼리에서 2열로 변경 */
}

.result-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 0;
}

.result-category {
    font-size: 13px;
    color: #6b7280;
    margin-bottom: 8px;
}

.surgery-name {
    font-size: 18px;
    font-weight: 600;
    color: #111827;
    margin: 0 0 12px 0;
}

.standard-types {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 12px;
}

.type-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 13px;
    font-weight: 500;
}

.type-badge.type-standard {
    background: #f3f4f6;
    color: #374151;
    border: 1px solid #d1d5db;
}

.type-badge.type-old {
    background: #fef3c7;
    color: #92400e;
    border: 1px solid #fcd34d;
}

.insurance-section {
    margin-top: 12px;
    border-top: 1px solid #e5e7eb;
    padding-top: 12px;
}

.insurance-toggle {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: none;
    border: none;
    padding: 8px 0;
    cursor: pointer;
    font-size: 14px;
    color: #4b5563;
    transition: color 0.2s;
}

.insurance-toggle:hover {
    color: #111827;
}

.insurance-toggle .count {
    color: #9ca3af;
    margin-left: 8px;
}

.insurance-toggle i {
    transition: transform 0.2s;
    margin-left: 8px;
}

.insurance-toggle.active i {
    transform: rotate(180deg);
}

.insurance-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.insurance-content.expanded {
    max-height: 500px;
    padding-top: 8px;
}

.insurance-item {
    padding: 6px 0;
    font-size: 13px;
    color: #4b5563;
}

.insurance-type {
    font-weight: 500;
    color: #111827;
}

.insurance-companies {
    color: #6b7280;
}

.surgery-description-wrapper {
    margin-top: 14px;
}

.surgery-description {
    padding: 14px 16px;
    background-color: #f8f9fa;
    border-left: 3px solid #4f46e5;
    border-radius: 6px;
    font-size: 14px;
    line-height: 1.7;
    color: #374151;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
    margin: 0;
}

.surgery-description mark.highlight {
    background-color: #fef3c7;
    padding: 2px 4px;
    border-radius: 3px;
    font-weight: 500;
    color: #92400e;
}

.description-more-btn {
    background: none;
    border: none;
    color: #4f46e5;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    padding: 0 4px;
    margin-left: 4px;
    text-decoration: underline;
    transition: color 0.2s;
}

.description-more-btn:hover {
    color: #4338ca;
}

.description-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
}

.description-modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.description-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

.description-modal-content {
    position: relative;
    background: #fff;
    border-radius: 12px;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    display: flex;
    flex-direction: column;
    z-index: 10001;
}

.description-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    border-bottom: 1px solid #e5e7eb;
}

.description-modal-header h4 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: #111827;
}

.description-modal-close {
    background: none;
    border: none;
    font-size: 28px;
    color: #6b7280;
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    transition: all 0.2s;
}

.description-modal-close:hover {
    background: #f3f4f6;
    color: #111827;
}

.description-modal-body {
    padding: 24px;
    overflow-y: auto;
    flex: 1;
}

.description-modal-text {
    font-size: 14px;
    line-height: 1.8;
    color: #374151;
    margin: 0;
}

.description-modal-text mark.highlight {
    background-color: #fef3c7;
    padding: 2px 4px;
    border-radius: 3px;
    font-weight: 500;
    color: #92400e;
}

/* 반응형: 모바일 */
@media (max-width: 768px) {
    .surgery-description {
        font-size: 13px;
        padding: 12px 14px;
        margin-top: 12px;
        line-height: 1.6;
    }
}

/* 더보기+ 버튼 스타일 */
.load-more-container {
    text-align: center;
    margin-top: 30px;
    padding: 20px;
}

.load-more-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(79, 70, 229, 0.2);
}

.load-more-btn:hover {
    background: linear-gradient(135deg, #4338ca 0%, #6d28d9 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.3);
}

.load-more-btn:active {
    transform: translateY(0);
}

.load-more-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.load-more-btn i {
    font-size: 14px;
}

/* 반응형: 모바일 */
@media (max-width: 768px) {
    .load-more-btn {
        padding: 10px 20px;
        font-size: 14px;
        width: 100%;
        max-width: 300px;
    }
}

.n-level-card {
    border-left: 3px solid #6366f1;
    background: linear-gradient(135deg, #f8f9ff 0%, #ffffff 100%);
    padding: 16px;
    grid-column: 1 / -1;
}

.n-level-content {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 8px;
}

.n-level-disease-section {
    border-bottom: 1px solid #e5e7eb;
    padding: 8px 0;
}

.n-level-disease-section:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.n-level-disease-name {
    font-size: 14px;
    color: #374151;
    line-height: 1.6;
    margin: 0;
}

.n-level-disease-name strong {
    font-weight: 600;
    color: #111827;
    margin-right: 4px;
}

/* 보험사별 그룹화 스타일 (결과가 많은 경우) */
.n-level-company-section {
    border-bottom: 2px solid #d1d5db;
    padding: 12px 0;
    margin-bottom: 8px;
}

.n-level-company-section:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.n-level-company-header {
    font-size: 15px;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 8px;
    padding-bottom: 6px;
    border-bottom: 1px solid #e5e7eb;
}

.n-level-company-header strong {
    color: #4f46e5;
}

.n-level-company-diseases {
    padding-left: 12px;
}

.n-level-company-diseases .n-level-disease-section {
    border-bottom: 1px solid #f3f4f6;
    padding: 6px 0;
    margin-bottom: 4px;
}

.n-level-company-diseases .n-level-disease-section:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

/* 일반 수술비 결과 2열 그리드 (N-level 아래) */
@media (min-width: 769px) {
    .results-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    /* N-level 카드는 항상 전체 너비 */
    .result-card.n-level-card {
        grid-column: 1 / -1;
    }
}

/* 반응형: 모바일 */
@media (max-width: 768px) {
    .results-grid {
        grid-template-columns: 1fr;
    }
    
    .n-level-card {
        padding: 12px;
    }
    
    .n-level-company-item {
        font-size: 11px;
        padding: 3px 6px;
    }
    
    .n-level-company-group {
        padding: 8px;
        gap: 6px;
    }
    
    .n-level-disease-name {
        font-size: 13px;
    }
    
    .n-level-content {
        gap: 10px;
    }
}


