/**
 * SYU AI4Recruit Custom Styles
 * 
 * @package SYU_AI4Recruit
 */

/* ========================================
   Header Styles
   ======================================== */
.site-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background-color: var(--primary-dark);
    color: white;
    box-shadow: var(--shadow-md);
}

.header-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
}

.header-brand {
    display: flex;
    align-items: center;
}

.site-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: white;
    font-weight: 700;
    font-size: 1.25rem;
}

.site-title:hover {
    color: var(--accent-light);
}

.site-logo-icon {
    color: var(--accent-color);
}

.header-nav {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav-user-info {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    font-size: 0.875rem;
}

.user-name {
    font-weight: 600;
}

.user-role {
    color: var(--accent-light);
    font-size: 0.75rem;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.nav-link {
    color: rgba(255, 255, 255, 0.85);
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: var(--radius-md);
    transition: all 0.2s ease;
}

.nav-link:hover {
    color: white;
    background-color: rgba(255, 255, 255, 0.1);
}

.nav-link-logout {
    color: var(--accent-light);
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
}

.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    padding: 0.5rem;
    cursor: pointer;
}

.hamburger {
    display: block;
    width: 24px;
    height: 2px;
    background-color: white;
    position: relative;
}

.hamburger::before,
.hamburger::after {
    content: '';
    position: absolute;
    width: 24px;
    height: 2px;
    background-color: white;
    left: 0;
}

.hamburger::before {
    top: -7px;
}

.hamburger::after {
    bottom: -7px;
}

/* ========================================
   Footer Styles
   ======================================== */
.site-footer {
    background-color: var(--primary-dark);
    color: rgba(255, 255, 255, 0.8);
    padding: 2rem 0;
    margin-top: auto;
}

.footer-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
}

.footer-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.footer-brand {
    display: flex;
    flex-direction: column;
}

.footer-logo {
    font-size: 1.125rem;
    font-weight: 700;
    color: white;
}

.footer-subtitle {
    font-size: 0.875rem;
    color: var(--accent-light);
}

.footer-info {
    text-align: right;
    font-size: 0.875rem;
}

.footer-contact a {
    color: var(--accent-light);
}

/* ========================================
   Welcome / Index Page
   ======================================== */
.welcome-section {
    max-width: 600px;
    margin: 4rem auto;
    text-align: center;
}

.action-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* ========================================
   Exam Page Styles
   ======================================== */
.exam-page {
    padding: 0;
}

.exam-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 2rem;
}

.exam-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 2rem;
}

.exam-title {
    font-size: 2rem;
    color: var(--primary-dark);
    margin-bottom: 0.5rem;
}

.exam-subtitle {
    color: var(--text-muted);
}

.user-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background-color: var(--surface-color);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    font-weight: 500;
}

.exam-notice {
    margin-bottom: 2rem;
}

.exam-notice h3 {
    margin-bottom: 1rem;
    font-size: 1.125rem;
}

.notice-list {
    list-style: none;
    padding: 0;
}

.notice-list li {
    position: relative;
    padding-left: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--text-muted);
}

.notice-list li::before {
    content: '•';
    position: absolute;
    left: 0;
    color: var(--accent-color);
    font-weight: bold;
}

/* AI Selector */
.ai-selector {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    background-color: var(--surface-color);
    padding: 0.5rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
}

.ai-tab {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 1rem;
    border: none;
    background: none;
    border-radius: var(--radius-md);
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.2s ease;
}

.ai-tab:hover {
    background-color: var(--background-color);
    color: var(--text-color);
}

.ai-tab.active {
    background-color: var(--primary-color);
    color: white;
}

.ai-icon {
    font-size: 1.25rem;
}

/* Chatbot Container */
.chatbot-container {
    margin-bottom: 2rem;
}

.chatbot-wrapper {
    background-color: var(--surface-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    overflow: hidden;
    min-height: 500px;
}

.chatbot-inner {
    height: 100%;
}

/* AI Engine 챗봇 스타일 오버라이드 */
.chatbot-wrapper .mwai-chatbot {
    height: 500px !important;
}

.exam-footer-notice {
    padding: 1rem;
    background-color: rgba(56, 178, 172, 0.1);
    border-radius: var(--radius-md);
}

/* ========================================
   Review Page Styles
   ======================================== */
.review-page {
    padding: 0;
}

.review-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem;
}

.review-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 2rem;
}

.review-title {
    font-size: 2rem;
    color: var(--primary-dark);
    margin-bottom: 0.5rem;
}

.review-subtitle {
    color: var(--text-muted);
}

.review-stats {
    display: flex;
    gap: 2rem;
}

.stat-item {
    text-align: center;
}

.stat-value {
    display: block;
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-color);
}

.stat-label {
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* Filters */
.review-filters {
    margin-bottom: 2rem;
}

.filter-form {
    display: flex;
    align-items: flex-end;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.filter-group {
    flex: 1;
    min-width: 200px;
    margin-bottom: 0;
}

.filter-label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    font-size: 0.875rem;
}

.filter-actions {
    display: flex;
    gap: 0.5rem;
}

/* Review Content Layout */
.review-content {
    display: grid;
    grid-template-columns: 400px 1fr;
    gap: 2rem;
    min-height: 600px;
}

/* Chat List Panel */
.chat-list-panel {
    background-color: var(--surface-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.panel-header {
    padding: 1rem 1.5rem;
    background-color: var(--primary-dark);
    color: white;
}

.panel-title {
    font-size: 1rem;
    font-weight: 600;
    margin: 0;
}

.chat-list {
    flex: 1;
    overflow-y: auto;
}

.chat-list-item {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--border-color);
    cursor: pointer;
    transition: all 0.2s ease;
}

.chat-list-item:hover {
    background-color: var(--background-color);
}

.chat-list-item.active {
    background-color: rgba(56, 178, 172, 0.1);
    border-left: 3px solid var(--accent-color);
}

.chat-item-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.5rem;
}

.chat-user {
    font-weight: 600;
    color: var(--text-color);
}

.chat-bot-badge {
    font-size: 0.75rem;
    font-weight: 600;
    padding: 0.25rem 0.5rem;
    border-radius: var(--radius-sm);
}

.chat-bot-badge.chatgpt {
    background-color: #10a37f;
    color: white;
}

.chat-bot-badge.claude {
    background-color: #8b5cf6;
    color: white;
}

.chat-item-meta {
    display: flex;
    gap: 1rem;
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

.chat-item-preview {
    font-size: 0.875rem;
    color: var(--text-muted);
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Chat Detail Panel */
.chat-detail-panel {
    background-color: var(--surface-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.chat-detail-content {
    flex: 1;
    overflow-y: auto;
    padding: 1.5rem;
}

.chat-detail-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 1rem;
    margin-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.detail-user-name {
    font-size: 1.125rem;
    margin: 0 0 0.25rem 0;
}

.detail-user-email {
    font-size: 0.875rem;
    color: var(--text-muted);
}

.detail-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.detail-bot-badge {
    font-size: 0.875rem;
    font-weight: 600;
    padding: 0.375rem 0.75rem;
    border-radius: var(--radius-md);
}

.detail-bot-badge.chatgpt {
    background-color: #10a37f;
    color: white;
}

.detail-bot-badge.claude {
    background-color: #8b5cf6;
    color: white;
}

.detail-time {
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* Chat Messages */
.chat-messages {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.message {
    max-width: 85%;
    padding: 1rem;
    border-radius: var(--radius-lg);
}

.message.user {
    align-self: flex-end;
    background-color: var(--primary-color);
    color: white;
}

.message.assistant {
    align-self: flex-start;
    background-color: var(--background-color);
    color: var(--text-color);
}

.message-role {
    font-size: 0.75rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    opacity: 0.8;
}

.message-content {
    line-height: 1.6;
    word-break: break-word;
}

.message-content pre {
    background-color: rgba(0, 0, 0, 0.1);
    padding: 0.75rem;
    border-radius: var(--radius-sm);
    overflow-x: auto;
    margin: 0.5rem 0;
}

.message-content code {
    font-family: var(--font-mono);
    font-size: 0.875rem;
}

.message.user .message-content pre {
    background-color: rgba(255, 255, 255, 0.15);
}

/* Empty State */
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem;
    text-align: center;
    color: var(--text-muted);
}

.empty-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

/* Loading */
.loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem;
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--border-color);
    border-top-color: var(--accent-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 1rem;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Pagination */
.pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    padding: 1rem;
    border-top: 1px solid var(--border-color);
}

.page-link {
    padding: 0.5rem 1rem;
    border-radius: var(--radius-md);
    background-color: var(--background-color);
    color: var(--text-color);
    font-weight: 500;
    transition: all 0.2s ease;
}

.page-link:hover {
    background-color: var(--primary-color);
    color: white;
}

.page-info {
    color: var(--text-muted);
    font-size: 0.875rem;
}

/* ========================================
   Responsive Styles
   ======================================== */
@media (max-width: 1024px) {
    .review-content {
        grid-template-columns: 1fr;
    }
    
    .chat-detail-panel {
        order: -1;
    }
}

@media (max-width: 768px) {
    .header-container {
        padding: 0 1rem;
    }
    
    .header-nav {
        display: none;
    }
    
    .mobile-menu-toggle {
        display: block;
    }
    
    .exam-header,
    .review-header {
        flex-direction: column;
        gap: 1rem;
    }
    
    .exam-container,
    .review-container {
        padding: 1rem;
    }
    
    .filter-form {
        flex-direction: column;
    }
    
    .filter-group {
        width: 100%;
    }
    
    .filter-actions {
        width: 100%;
    }
    
    .filter-actions .btn {
        flex: 1;
    }
    
    .review-stats {
        width: 100%;
        justify-content: center;
    }
    
    .footer-content {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    .footer-info {
        text-align: center;
    }
    
    .action-buttons {
        flex-direction: column;
    }
    
    .action-buttons .btn {
        width: 100%;
    }
}

/* ========================================
   AI Evaluation Section
   ======================================== */
.ai-evaluation-section {
    margin-bottom: 2rem;
}

.ai-eval-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.eval-result-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--border-color);
}

.eval-result-content {
    max-height: 600px;
    overflow-y: auto;
    padding: 1rem;
    background-color: var(--background-color);
    border-radius: var(--radius-md);
}

.markdown-content h2 {
    font-size: 1.5rem;
    margin: 1.5rem 0 1rem;
    color: var(--primary-dark);
    border-bottom: 2px solid var(--accent-color);
    padding-bottom: 0.5rem;
}

.markdown-content h3 {
    font-size: 1.25rem;
    margin: 1.25rem 0 0.75rem;
    color: var(--primary-color);
}

.markdown-content h4 {
    font-size: 1.1rem;
    margin: 1rem 0 0.5rem;
    color: var(--text-color);
}

.markdown-content hr {
    margin: 1.5rem 0;
    border: none;
    border-top: 1px solid var(--border-color);
}

/* ========================================
   AI 이용 행태 흐름 시각화
   ======================================== */

/* 코드 블록 (ASCII 차트용) */
.markdown-content pre {
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    color: #e2e8f0;
    padding: 1.5rem;
    border-radius: var(--radius-lg);
    overflow-x: auto;
    font-family: 'JetBrains Mono', 'Fira Code', 'Consolas', monospace;
    font-size: 0.9rem;
    line-height: 1.8;
    margin: 1rem 0;
    box-shadow: var(--shadow-md);
    border-left: 4px solid var(--accent-color);
}

.markdown-content pre code {
    background: none;
    padding: 0;
    color: inherit;
    font-size: inherit;
}

/* ASCII 차트 강조 */
.markdown-content pre .chart-bar {
    color: var(--accent-color);
}

/* 이모지 강조 */
.markdown-content .emoji {
    font-size: 1.1em;
    margin-right: 0.25rem;
}

/* 흐름 타임라인 스타일 */
.flow-timeline {
    background-color: var(--surface-color);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    margin: 1rem 0;
}

.flow-item {
    display: flex;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px dashed var(--border-color);
}

.flow-item:last-child {
    border-bottom: none;
}

.flow-user {
    min-width: 120px;
    font-weight: 600;
    color: var(--primary-dark);
}

.flow-icons {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    flex-wrap: wrap;
}

.flow-arrow {
    color: var(--text-muted);
    margin: 0 0.25rem;
}

.flow-icon {
    font-size: 1.5rem;
    transition: transform 0.2s ease;
}

.flow-icon:hover {
    transform: scale(1.2);
}

/* 패턴 분포 차트 영역 */
.pattern-chart {
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    margin: 1rem 0;
}

.chart-row {
    display: flex;
    align-items: center;
    margin-bottom: 0.75rem;
}

.chart-label {
    min-width: 140px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.chart-bar-container {
    flex: 1;
    height: 24px;
    background-color: var(--border-color);
    border-radius: 12px;
    overflow: hidden;
    margin-right: 1rem;
}

.chart-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--accent-color) 0%, var(--primary-color) 100%);
    border-radius: 12px;
    transition: width 0.5s ease;
}

.chart-value {
    min-width: 80px;
    text-align: right;
    font-weight: 600;
    color: var(--primary-dark);
}

/* 매트릭스 표 스타일 */
.markdown-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.5rem 0;
    font-size: 0.9rem;
    background-color: var(--surface-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
}

.markdown-content table th {
    background: linear-gradient(135deg, var(--primary-dark) 0%, #1a365d 100%);
    color: white;
    font-weight: 600;
    padding: 1rem;
    text-align: left;
    border-bottom: 2px solid var(--accent-color);
}

.markdown-content table td {
    padding: 0.875rem 1rem;
    border-bottom: 1px solid var(--border-color);
    vertical-align: middle;
}

.markdown-content table tr:nth-child(even) td {
    background-color: rgba(0, 0, 0, 0.02);
}

.markdown-content table tr:hover td {
    background-color: rgba(56, 178, 172, 0.08);
}

/* 그룹 뱃지 스타일 */
.markdown-content strong {
    color: var(--primary-dark);
}

/* 상위/중위/하위 그룹 강조 */
.markdown-content em {
    font-style: normal;
    padding: 0.125rem 0.5rem;
    border-radius: var(--radius-sm);
    font-weight: 500;
}

/* 섹션 구분 */
.section-divider {
    display: flex;
    align-items: center;
    margin: 2rem 0;
}

.section-divider::before,
.section-divider::after {
    content: '';
    flex: 1;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--border-color), transparent);
}

.section-divider-text {
    padding: 0 1rem;
    font-weight: 600;
    color: var(--primary-color);
}

/* 결과 영역 스크롤 향상 */
.eval-result-content {
    max-height: 70vh;
    overflow-y: auto;
    padding: 1.5rem;
    background-color: var(--background-color);
    border-radius: var(--radius-md);
    scrollbar-width: thin;
    scrollbar-color: var(--accent-color) var(--border-color);
}

.eval-result-content::-webkit-scrollbar {
    width: 8px;
}

.eval-result-content::-webkit-scrollbar-track {
    background: var(--border-color);
    border-radius: 4px;
}

.eval-result-content::-webkit-scrollbar-thumb {
    background-color: var(--accent-color);
    border-radius: 4px;
}

/* 인쇄용 코드블록 */
@media print {
    .markdown-content pre {
        background: #f5f5f5 !important;
        color: #333 !important;
        border: 1px solid #ddd;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }
    
    .markdown-content table th {
        background: #333 !important;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }
}

.eval-table {
    width: 100%;
    border-collapse: collapse;
    margin: 1rem 0;
    font-size: 0.9rem;
}

.eval-table td {
    padding: 0.75rem 1rem;
    border: 1px solid var(--border-color);
    vertical-align: top;
}

.eval-table tr:first-child td {
    background-color: var(--primary-dark);
    color: white;
    font-weight: 600;
}

.eval-table tr:nth-child(even) td {
    background-color: var(--background-color);
}

.mb-4 {
    margin-bottom: 2rem;
}

.mb-3 {
    margin-bottom: 1rem;
}

/* ========================================
   개별 리포트 카드
   ======================================== */
.individual-reports-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.report-card {
    background: var(--surface-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
    transition: all 0.2s ease;
    border: 1px solid var(--border-color);
}

.report-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.report-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border-bottom: 1px solid var(--border-color);
}

.report-user-info {
    display: flex;
    flex-direction: column;
}

.report-user-name {
    font-weight: 700;
    font-size: 1rem;
    color: var(--primary-dark);
}

.report-user-login {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.report-group-badge {
    padding: 0.375rem 0.75rem;
    border-radius: var(--radius-md);
    font-weight: 700;
    font-size: 0.875rem;
}

.report-group-badge.group-high {
    background: linear-gradient(135deg, #c6f6d5 0%, #9ae6b4 100%);
    color: #22543d;
}

.report-group-badge.group-mid {
    background: linear-gradient(135deg, #fefcbf 0%, #faf089 100%);
    color: #744210;
}

.report-group-badge.group-low {
    background: linear-gradient(135deg, #fed7d7 0%, #feb2b2 100%);
    color: #822727;
}

.report-group-badge.group-na {
    background: #e2e8f0;
    color: #4a5568;
}

.report-card-summary {
    padding: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.report-flow {
    font-size: 1.25rem;
    letter-spacing: 2px;
    margin-bottom: 0.5rem;
}

.report-patterns {
    font-size: 1rem;
    margin-bottom: 0.5rem;
}

.report-stats {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.report-card-preview {
    padding: 0.75rem 1rem;
    background-color: var(--background-color);
    font-size: 0.8rem;
}

.preview-item {
    margin-bottom: 0.25rem;
    color: var(--text-muted);
}

.preview-item strong {
    color: var(--text-color);
}

.report-card-actions {
    display: flex;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    background: var(--surface-color);
}

.report-card-actions .btn {
    flex: 1;
}

/* ========================================
   리포트 모달
   ======================================== */
.report-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.report-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
}

.report-modal-container {
    position: relative;
    background: var(--surface-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    width: 90%;
    max-width: 800px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.report-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.5rem;
    background: linear-gradient(135deg, var(--primary-dark) 0%, #2c5282 100%);
    color: white;
}

.report-modal-header h3 {
    margin: 0;
    font-size: 1.125rem;
}

.btn-close-modal {
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0;
    line-height: 1;
    opacity: 0.8;
    transition: opacity 0.2s;
}

.btn-close-modal:hover {
    opacity: 1;
}

.report-modal-content {
    flex: 1;
    overflow-y: auto;
    padding: 1.5rem;
    background: var(--background-color);
}

.report-modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--border-color);
    background: var(--surface-color);
}

/* 인쇄용 리포트 스타일 (모달 내) */
.print-report {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-md);
}

.print-header {
    text-align: center;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 2px solid var(--primary-dark);
}

.print-logo h1 {
    font-size: 1.75rem;
    color: var(--primary-dark);
    margin-bottom: 0.25rem;
}

.print-logo h2 {
    font-size: 1rem;
    color: var(--text-muted);
    font-weight: normal;
}

.print-date {
    text-align: right;
    color: var(--text-muted);
    font-size: 0.875rem;
    margin-top: 0.5rem;
}

.print-applicant-info {
    margin-bottom: 1.5rem;
}

.info-table {
    width: 100%;
    border-collapse: collapse;
}

.info-table th,
.info-table td {
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    text-align: left;
}

.info-table th {
    background: var(--background-color);
    font-weight: 600;
    width: 100px;
}

.print-section {
    margin-bottom: 1.5rem;
}

.print-section h3 {
    font-size: 1rem;
    color: var(--primary-dark);
    margin-bottom: 0.75rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border-color);
}

.flow-display {
    font-size: 1.5rem;
    letter-spacing: 4px;
    padding: 1rem;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border-radius: var(--radius-md);
    text-align: center;
    margin-bottom: 1rem;
}

.pattern-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.75rem;
}

.pattern-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 0.875rem;
}

.pattern-item.used {
    background: linear-gradient(135deg, #e6fffa 0%, #b2f5ea 100%);
    border-color: var(--accent-color);
}

.pattern-item.not-used {
    background: #f5f5f5;
    color: #999;
}

.pattern-icon {
    font-size: 1.125rem;
}

.pattern-status {
    margin-left: auto;
    font-weight: 600;
}

.pattern-item.used .pattern-status {
    color: #22543d;
}

.pattern-item.not-used .pattern-status {
    color: #999;
}

.print-footer {
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color);
    text-align: center;
    color: var(--text-muted);
    font-size: 0.75rem;
}

/* 반응형 */
@media (max-width: 768px) {
    .individual-reports-list {
        grid-template-columns: 1fr;
    }
    
    .pattern-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .report-modal-container {
        width: 95%;
        max-height: 95vh;
    }
}

/* ========================================
   공식 평가 섹션 스타일
   ======================================== */

/* 평가 기준 배지 */
.criteria-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.criteria-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    border-radius: var(--radius-md);
    font-size: 0.75rem;
    font-weight: 600;
    color: #92400e;
}

/* 버튼 색상 변형 */
.btn-warning {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
    border: none;
}

.btn-warning:hover {
    background: linear-gradient(135deg, #d97706 0%, #b45309 100%);
    transform: translateY(-1px);
}

/* 공식 요약 콘텐츠 */
.official-summary-content {
    display: grid;
    gap: 1.5rem;
}

.grade-distribution-chart h4,
.top-performers h4,
.needs-attention h4,
.general-observations h4 {
    font-size: 0.95rem;
    color: var(--primary-dark);
    margin-bottom: 0.75rem;
}

/* 등급 분포 차트 */
.grade-bars {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.grade-bar-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.grade-label {
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-md);
    font-weight: 700;
    font-size: 0.875rem;
}

.grade-label.grade-a {
    background: linear-gradient(135deg, #c6f6d5 0%, #9ae6b4 100%);
    color: #22543d;
}

.grade-label.grade-b {
    background: linear-gradient(135deg, #fefcbf 0%, #faf089 100%);
    color: #744210;
}

.grade-label.grade-c {
    background: linear-gradient(135deg, #fed7d7 0%, #feb2b2 100%);
    color: #822727;
}

.grade-label.grade-n {
    background: #e2e8f0;
    color: #4a5568;
}

.grade-bar-container {
    flex: 1;
    height: 20px;
    background: #e2e8f0;
    border-radius: var(--radius-sm);
    overflow: hidden;
}

.grade-bar {
    height: 100%;
    border-radius: var(--radius-sm);
    transition: width 0.3s ease;
}

.grade-bar.grade-a {
    background: linear-gradient(90deg, #48bb78 0%, #38a169 100%);
}

.grade-bar.grade-b {
    background: linear-gradient(90deg, #ecc94b 0%, #d69e2e 100%);
}

.grade-bar.grade-c {
    background: linear-gradient(90deg, #fc8181 0%, #f56565 100%);
}

.grade-bar.grade-n {
    background: linear-gradient(90deg, #a0aec0 0%, #718096 100%);
}

.grade-count {
    min-width: 50px;
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* 우수/주의 응시자 배지 */
.performers-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.performer-badge {
    padding: 0.375rem 0.75rem;
    border-radius: var(--radius-md);
    font-size: 0.8rem;
    font-weight: 600;
}

.performer-badge.top {
    background: linear-gradient(135deg, #c6f6d5 0%, #9ae6b4 100%);
    color: #22543d;
}

.performer-badge.attention {
    background: linear-gradient(135deg, #fed7d7 0%, #feb2b2 100%);
    color: #822727;
}

.general-observations p {
    line-height: 1.7;
    color: var(--text-color);
}

/* 공식 리포트 카드 목록 */
.official-reports-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1rem;
}

.official-report-card {
    background: var(--surface-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
    border: 1px solid var(--border-color);
    transition: all 0.2s ease;
}

.official-report-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.official-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    background: linear-gradient(135deg, #f8fafc 0%, #edf2f7 100%);
    border-bottom: 1px solid var(--border-color);
}

.official-user-info {
    display: flex;
    align-items: baseline;
    gap: 0.5rem;
}

.official-user-name {
    font-weight: 700;
    font-size: 1rem;
    color: var(--primary-dark);
}

.official-user-rank {
    font-size: 0.8rem;
    color: var(--text-muted);
    font-weight: 600;
}

.official-grade-badge {
    padding: 0.5rem 1rem;
    border-radius: var(--radius-md);
    font-weight: 700;
    font-size: 1.25rem;
}

.official-grade-badge.official-grade-a {
    background: linear-gradient(135deg, #c6f6d5 0%, #9ae6b4 100%);
    color: #22543d;
}

.official-grade-badge.official-grade-b {
    background: linear-gradient(135deg, #fefcbf 0%, #faf089 100%);
    color: #744210;
}

.official-grade-badge.official-grade-c {
    background: linear-gradient(135deg, #fed7d7 0%, #feb2b2 100%);
    color: #822727;
}

.official-grade-badge.official-grade-n {
    background: #e2e8f0;
    color: #4a5568;
}

.official-card-criteria {
    padding: 0.75rem 1rem;
    background: var(--background-color);
    border-bottom: 1px solid var(--border-color);
}

.criteria-mini-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.criteria-mini-item {
    padding: 0.25rem 0.5rem;
    border-radius: var(--radius-sm);
    font-size: 0.7rem;
    font-weight: 600;
}

.criteria-mini-item.official-grade-a {
    background: #c6f6d5;
    color: #22543d;
}

.criteria-mini-item.official-grade-b {
    background: #fefcbf;
    color: #744210;
}

.criteria-mini-item.official-grade-c {
    background: #fed7d7;
    color: #822727;
}

.criteria-mini-item.official-grade-n {
    background: #e2e8f0;
    color: #4a5568;
}

.official-card-preview {
    padding: 0.75rem 1rem;
    font-size: 0.8rem;
}

.preview-strengths {
    color: var(--text-muted);
}

.preview-strengths strong {
    color: #22543d;
}

.official-card-actions {
    display: flex;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    background: var(--surface-color);
    border-top: 1px solid var(--border-color);
}

.official-card-actions .btn {
    flex: 1;
}

/* 영역별 평가 결과 그리드 */
.criteria-results-grid {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.criteria-result-item {
    background: linear-gradient(135deg, #fafafa 0%, #f5f5f5 100%);
    padding: 1rem;
    border-radius: var(--radius-md);
    border-left: 4px solid #553c9a;
}

.criteria-result-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.5rem;
}

.criteria-num {
    background: #553c9a;
    color: white;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 700;
}

.criteria-label {
    font-weight: 600;
    flex: 1;
    color: var(--primary-dark);
}

.criteria-grade {
    font-size: 1.25rem;
    font-weight: 700;
}

.criteria-desc {
    color: var(--text-muted);
    font-size: 0.8rem;
    margin-bottom: 0.5rem;
}

.criteria-evidence {
    font-size: 0.875rem;
    line-height: 1.6;
    color: var(--text-color);
}

.criteria-quote {
    font-style: italic;
    color: #553c9a;
    background: linear-gradient(135deg, #f0ebf8 0%, #e9e1f5 100%);
    padding: 0.5rem 1rem;
    margin-top: 0.5rem;
    border-radius: var(--radius-md);
    font-size: 0.8rem;
    border-left: 3px solid #553c9a;
}

/* 대화 요약 박스 */
.conversation-summary-box {
    background: var(--background-color);
    padding: 1rem;
    border-radius: var(--radius-md);
}

.conv-summary-item {
    display: inline-block;
    margin-right: 1.5rem;
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
}

.conv-summary-item strong {
    color: var(--primary-dark);
}

/* 공식 모달 헤더 */
#official-report-modal .report-modal-header {
    background: linear-gradient(135deg, #553c9a 0%, #6b46c1 100%);
}

/* 반응형 */
@media (max-width: 768px) {
    .official-reports-list {
        grid-template-columns: 1fr;
    }
    
    .criteria-badges {
        justify-content: center;
    }
    
    .grade-bar-item {
        flex-wrap: wrap;
    }
    
    .grade-bar-container {
        order: 3;
        width: 100%;
        margin-top: 0.25rem;
    }
}

/* ========================================
   단일 응시자 평가 페이지 전용 스타일
   ======================================== */

/* 응시자 선택 그리드 */
.applicant-select-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 1rem;
}

.applicant-select-card {
    display: block;
    padding: 1.25rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    text-decoration: none;
    color: var(--text-color);
    background: var(--surface-color);
    transition: border-color 0.2s, box-shadow 0.2s, transform 0.15s;
}

.applicant-select-card:hover {
    border-color: var(--primary-color);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    transform: translateY(-2px);
    text-decoration: none;
    color: var(--text-color);
}

.asc-name {
    font-weight: 700;
    font-size: 1rem;
    margin-bottom: 0.25rem;
    color: var(--primary-dark);
}

.asc-login {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: 0.75rem;
}

.asc-meta {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    font-size: 0.8rem;
}

.asc-evaluated {
    color: #22543d;
    font-weight: 600;
}

.asc-pending {
    color: #744210;
}

/* 단일 평가 헤더 레이아웃 */
.single-review-header {
    flex-wrap: wrap;
    gap: 1rem;
    align-items: flex-end;
}

/* 응시자 드롭다운 선택기 */
.single-applicant-selector {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.selector-label {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-muted);
    white-space: nowrap;
}

.selector-wrapper {
    position: relative;
}

.applicant-dropdown {
    min-width: 280px;
    font-size: 0.9rem;
    padding-right: 2rem;
    cursor: pointer;
}

@media (max-width: 768px) {
    .single-applicant-selector {
        width: 100%;
    }
    .applicant-dropdown {
        min-width: 100%;
        width: 100%;
    }
}

/* 재평가 경고 */
.reeval-warning {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-bottom: 0.75rem;
    padding: 0.5rem 0.75rem;
    background: #fffbeb;
    border: 1px solid #f6ad55;
    border-radius: var(--radius-md);
}

.reeval-badge {
    font-size: 0.85rem;
    color: #744210;
    font-weight: 500;
}

/* 단일 평가 요약 카드 */
.single-summary-card {
    background: var(--background-color);
    border-radius: var(--radius-lg);
    padding: 1rem;
    margin-top: 0.75rem;
}

.single-summary-top {
    display: flex;
    gap: 2rem;
    align-items: center;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.summary-grade-block,
.summary-score-block {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 80px;
}

.summary-grade-label,
.summary-score-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-bottom: 0.25rem;
}

.summary-grade-value {
    font-size: 2.5rem;
    font-weight: 800;
    line-height: 1;
}

.summary-score-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-dark);
}

.summary-criteria-row {
    margin-top: 0.5rem;
}

/* D 등급 */
.official-grade-d {
    color: #c53030;
    font-weight: bold;
}

/* 영역별 점수 표시 */
.criteria-score {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-left: 0.25rem;
}

/* 인용 하이라이트 */
.quote-clickable {
    cursor: pointer;
    position: relative;
}

.quote-clickable:hover {
    background: #fef3c7;
    border-color: #f59e0b;
}

.quote-hint {
    display: inline-block;
    margin-left: 0.5rem;
    font-size: 0.75rem;
    font-style: normal;
    color: var(--primary-color);
    opacity: 0;
    transition: opacity 0.2s;
}

.quote-clickable:hover .quote-hint {
    opacity: 1;
}

.message.quote-highlight {
    background: #fefce8;
    border-left: 3px solid #f59e0b;
    padding-left: 0.75rem;
    transition: background 0.3s;
}

.chat-list-item.quote-match {
    border-color: #f59e0b;
    background: #fffbeb;
}

.chat-list-item.active {
    border-color: var(--primary-color);
    background: #ebf8ff;
}

/* 단일 평가 모달 헤더 */
#single-report-modal .report-modal-header {
    background: linear-gradient(135deg, #744210 0%, #975a16 100%);
}

/* ========================================
   Print Styles
   ======================================== */
@media print {
    .site-header,
    .site-footer,
    .review-filters,
    .chat-list-panel,
    .pagination {
        display: none !important;
    }
    
    .review-content {
        grid-template-columns: 1fr;
    }
    
    .chat-detail-panel {
        box-shadow: none;
    }
}

