/* 키워드 밀도 분석기 스타일 - mockup-generator 디자인 언어 차용 (orange/amber 테마) */
.kd-tool {
    --tool-primary: #ea580c;
    --tool-bg: #fff7ed;
    --tool-gradient: linear-gradient(135deg, #f59e0b 0%, #ea580c 100%);
}

/* 히어로 */
.kd-hero {
    background: var(--tool-gradient);
    border-radius: 16px;
    padding: 36px 32px;
    color: #fff;
    text-align: center;
    position: relative;
    overflow: hidden;
    margin-bottom: 28px;
}
.kd-hero::before {
    content: '';
    position: absolute;
    top: -80px;
    right: -80px;
    width: 300px;
    height: 300px;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 50%;
}
.kd-hero::after {
    content: '';
    position: absolute;
    bottom: -120px;
    left: -60px;
    width: 260px;
    height: 260px;
    background: rgba(255, 255, 255, 0.04);
    border-radius: 50%;
}
.kd-hero h1 {
    font-size: 28px;
    font-weight: 800;
    position: relative;
    z-index: 1;
    margin: 10px 0 6px;
}
.kd-hero p {
    opacity: 0.85;
    position: relative;
    z-index: 1;
    margin-bottom: 0;
}

/* 에디터 카드 */
.editor-card {
    background: #fff;
    border: 1px solid #e9ecef;
    border-radius: 14px;
    overflow: hidden;
}
.editor-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    border-bottom: 1px solid #f1f3f5;
}
.editor-title {
    font-weight: 700;
    font-size: 14px;
    color: #343a40;
}
.editor-title i {
    color: var(--tool-primary);
}
.editor-body {
    padding: 16px;
}
.editor-textarea {
    width: 100%;
    min-height: 200px;
    resize: vertical;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    background: #f8f9fb;
    padding: 14px 16px;
    font-size: 14px;
    line-height: 1.6;
    color: #212529;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.editor-textarea:focus {
    border-color: var(--tool-primary);
    background: #fff;
    box-shadow: 0 0 0 3px rgba(234, 88, 12, 0.12);
}

/* 폼 컨트롤 포커스 테마 */
.kd-tool .form-select:focus {
    border-color: var(--tool-primary);
    box-shadow: 0 0 0 3px rgba(234, 88, 12, 0.12);
}
.kd-tool .form-check-input:checked {
    background-color: var(--tool-primary);
    border-color: var(--tool-primary);
}
.kd-tool .form-check-input:focus {
    border-color: var(--tool-primary);
    box-shadow: 0 0 0 3px rgba(234, 88, 12, 0.12);
}

/* 액션 버튼 */
.btn-action {
    display: inline-flex;
    align-items: center;
    padding: 9px 18px;
    border-radius: 10px;
    border: 1px solid #dee2e6;
    background: #fff;
    color: #495057;
    font-size: 13.5px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s;
    white-space: nowrap;
}
.btn-action:hover {
    border-color: var(--tool-primary);
    color: var(--tool-primary);
    background: var(--tool-bg);
}
.btn-action-sm {
    padding: 5px 11px;
    font-size: 12.5px;
    border-radius: 8px;
}
.btn-action-primary {
    background: var(--tool-gradient);
    border: none;
    color: #fff;
}
.btn-action-primary:hover {
    background: var(--tool-gradient);
    border: none;
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 6px 18px rgba(234, 88, 12, 0.3);
}

/* 통계 박스 */
.kd-stat-box {
    border: 1px solid #f1d4ba;
    background-color: var(--tool-bg);
}
.kd-stat-value {
    font-size: 1.75rem;
    color: var(--tool-primary);
    line-height: 1.2;
}
.kd-stat-label {
    font-size: 0.8rem;
    margin-top: 0.25rem;
}

/* 탭 스타일 */
.kd-tabs {
    border-bottom: 1px solid #e9ecef;
}
.kd-tabs .nav-link {
    font-weight: 600;
    font-size: 0.9rem;
    color: #6c757d;
    border: none;
    border-bottom: 2px solid transparent;
    border-radius: 0;
    padding: 0.5rem 1rem;
    transition: all 0.15s;
}
.kd-tabs .nav-link:hover {
    color: var(--tool-primary);
    border-color: transparent;
}
.kd-tabs .nav-link.active {
    color: var(--tool-primary);
    background: transparent;
    border-bottom-color: var(--tool-primary);
}
.kd-tabs .nav-link .badge {
    font-size: 0.7rem;
    font-weight: 600;
    vertical-align: middle;
    background-color: var(--tool-primary);
    color: #fff;
}

/* 결과 테이블 */
.kd-table {
    font-size: 0.9rem;
}
.kd-table thead th {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: #6c757d;
    border-bottom-width: 2px;
    padding: 0.5rem 0.75rem;
}
.kd-table tbody td {
    padding: 0.6rem 0.75rem;
    vertical-align: middle;
}
.kd-table tbody tr:last-child td {
    border-bottom: none;
}
.kd-keyword-cell {
    font-weight: 600;
    word-break: break-all;
}
.kd-density-cell {
    font-weight: 600;
    font-size: 0.85rem;
}

/* 밀도 바 (차트) */
.kd-chart-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.5rem;
}
.kd-chart-label {
    flex-shrink: 0;
    width: 120px;
    font-weight: 600;
    font-size: 0.85rem;
    text-align: right;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.kd-chart-bar-wrap {
    flex: 1;
    min-width: 0;
}
.kd-chart-bar-wrap .progress {
    height: 24px;
    border-radius: 0.5rem;
    background-color: #f1f3f5;
}
.kd-chart-bar-wrap .progress-bar {
    border-radius: 0.5rem;
    font-size: 0.75rem;
    font-weight: 600;
    line-height: 24px;
    padding: 0 0.5rem;
    text-align: left;
    min-width: 2rem;
    transition: width 0.6s ease;
}
/* 차트 막대 테마 (JS가 .bg-primary 클래스를 출력하므로 오버라이드) */
.kd-tool .kd-chart-bar-wrap .progress-bar.bg-primary {
    background: var(--tool-gradient) !important;
}
.kd-chart-count {
    flex-shrink: 0;
    width: 60px;
    font-size: 0.8rem;
    color: #6c757d;
    text-align: left;
}

/* 밀도 인라인 바 (테이블 내) */
.kd-density-inline {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.5rem;
}
.kd-density-bar-mini {
    width: 50px;
    height: 4px;
    border-radius: 2px;
    background-color: #e9ecef;
    overflow: hidden;
}
.kd-density-bar-mini-fill {
    height: 100%;
    border-radius: 2px;
    background-color: var(--tool-primary);
    transition: width 0.4s ease;
}

/* 밀도 수준 색상 */
.kd-density-low { color: #16a34a; }
.kd-density-mid { color: #d97706; }
.kd-density-high { color: #dc2626; }
.kd-density-bar-mini-fill.bar-low { background-color: #16a34a; }
.kd-density-bar-mini-fill.bar-mid { background-color: #d97706; }
.kd-density-bar-mini-fill.bar-high { background-color: #dc2626; }

/* 빈 결과 */
.kd-empty {
    text-align: center;
    padding: 2rem 1rem;
    color: #6c757d;
    font-size: 0.9rem;
}

/* 서포트 카드 */
.support-card {
    background: #fff;
    border: 1px solid #e9ecef;
    border-radius: 14px;
    overflow: hidden;
}
.support-card .card-hd {
    padding: 14px 18px;
    font-weight: 700;
    font-size: 15px;
    border-bottom: 1px solid #f1f3f5;
}
.support-card .card-bd {
    padding: 18px;
}
.support-subtitle {
    font-size: 15px;
    font-weight: 700;
    color: #343a40;
    margin: 18px 0 10px;
}

/* 아코디언 */
.kd-tool .accordion-button:not(.collapsed) {
    background-color: var(--tool-bg);
    color: var(--tool-primary);
    box-shadow: none;
}
.kd-tool .accordion-button:focus {
    box-shadow: none;
    border-color: transparent;
}

/* 반응형 */
@media (max-width: 768px) {
    .kd-hero { padding: 28px 20px; border-radius: 12px; }
    .kd-hero h1 { font-size: 22px; }
}
@media (max-width: 576px) {
    .kd-chart-label {
        width: 80px;
        font-size: 0.75rem;
    }
    .kd-chart-count {
        width: 45px;
        font-size: 0.7rem;
    }
    .kd-stat-value {
        font-size: 1.25rem;
    }
}
</content>
