/* =========================================
   湖南新途医学检验实验室临床伦理委员会
   全局样式 - 简洁医疗风格
   ========================================= */

:root {
    /* 单一主色调 - 专业医疗蓝 */
    --primary: #0891b2;
    --primary-dark: #0e7490;
    --primary-light: #cffafe;
    
    /* 中性色 */
    --light: #f8fafc;
    --dark: #0f172a;
    --border: #e2e8f0;
    --text-muted: #64748b;
    --text-dark: #1e293b;
    --white: #ffffff;
    
    /* 背景色 */
    --bg-primary: #f8fafc;
    --bg-card: #ffffff;
    
    /* 阴影 */
    --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.04);
    --shadow: 0 2px 8px rgba(15, 23, 42, 0.06);
    --shadow-md: 0 4px 12px rgba(15, 23, 42, 0.08);
    
    /* 圆角 */
    --radius-sm: 6px;
    --radius: 10px;
    --radius-lg: 16px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "PingFang SC", "Microsoft YaHei", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    font-size: 14px;
    line-height: 1.7;
    color: var(--text-dark);
    background: var(--bg-primary);
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
}

/* 简洁背景 */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 280px;
    background: var(--primary);
    z-index: -1;
}

/* 布局 */
.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
}

.page-wrapper {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.main-content {
    flex: 1;
    padding: 32px 0;
}

/* =========================================
   导航栏
   ========================================= */
.navbar {
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px);
    box-shadow: var(--shadow);
    padding: 0 24px;
    position: sticky;
    top: 0;
    z-index: 100;
    border-radius: 0 0 var(--radius-lg) var(--radius-lg);
}

.navbar-inner {
    max-width: 1280px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
}

.navbar-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: var(--primary);
}

.navbar-brand img {
    width: 40px;
    height: 40px;
    border-radius: var(--radius);
}

.navbar-brand .brand-text {
    display: flex;
    flex-direction: column;
}

.navbar-brand .brand-name {
    font-size: 16px;
    font-weight: 700;
    color: var(--primary);
    line-height: 1.3;
}

.navbar-menu {
    display: flex;
    align-items: center;
    gap: 8px;
}

.navbar-menu a {
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    color: var(--text-dark);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s ease;
}

.navbar-menu a:hover {
    background: var(--primary-light);
    color: var(--primary);
}

.navbar-menu a.active {
    background: var(--primary);
    color: white;
}

.navbar-user {
    display: flex;
    align-items: center;
    gap: 16px;
}

.navbar-user .user-info {
    display: flex;
    align-items: center;
    gap: 8px;
}

.navbar-user .user-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--primary);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}

/* 语言切换 */
.lang-switcher {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    background: var(--light);
    padding: 4px 8px;
    border-radius: var(--radius-full);
}
.lang-switcher a {
    color: var(--text-muted);
    text-decoration: none;
    padding: 4px 10px;
    border-radius: var(--radius-full);
    transition: all 0.2s;
}
.lang-switcher a:hover,
.lang-switcher a.active {
    color: var(--primary);
    background: var(--primary-light);
    font-weight: 600;
}

/* =========================================
   Hero 区域
   ========================================= */
.hero-section {
    background: white;
    border-radius: var(--radius-xl);
    padding: 48px;
    text-align: center;
    box-shadow: var(--shadow-lg);
    margin-bottom: 32px;
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 6px;
    background: var(--primary-gradient);
}

.hero-section h1 {
    font-size: 32px;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 16px;
    letter-spacing: -0.5px;
}

.hero-section p {
    font-size: 16px;
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto 24px;
}

/* =========================================
   统计卡片
   ========================================= */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 32px;
}

.stat-card {
    background: white;
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    gap: 16px;
    transition: all 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.stat-card .stat-icon {
    width: 56px;
    height: 56px;
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
}

.stat-card .stat-icon.primary { background: var(--primary-light); color: var(--primary); }
.stat-card .stat-icon.success { background: var(--success-light); color: var(--success); }
.stat-card .stat-icon.warning { background: var(--warning-light); color: #856404; }
.stat-card .stat-icon.danger { background: var(--danger-light); color: var(--danger); }

.stat-card .stat-content h3 {
    font-size: 28px;
    font-weight: 700;
    color: var(--text-dark);
    line-height: 1;
}

.stat-card .stat-content p {
    font-size: 13px;
    color: var(--text-muted);
    margin-top: 4px;
}

/* =========================================
   卡片组件
   ========================================= */
.card {
    background: white;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    overflow: hidden;
    transition: all 0.3s ease;
}

.card:hover {
    box-shadow: var(--shadow-md);
}

.card-header {
    padding: 16px 24px;
    border-bottom: 1px solid var(--border);
    background: var(--light);
}

.card-header h2 {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-dark);
}

.card-body {
    padding: 24px;
}

/* =========================================
   按钮
   ========================================= */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: var(--radius);
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
    background: var(--primary);
    color: white;
}

.btn:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
}

.btn-outline {
    background: transparent;
    color: var(--primary);
    border: 1.5px solid var(--primary);
}

.btn-outline:hover {
    background: var(--primary-light);
}

.btn-sm {
    padding: 6px 12px;
    font-size: 13px;
    border-radius: var(--radius-sm);
}

.btn-lg {
    padding: 14px 28px;
    font-size: 16px;
}

/* =========================================
   表单
   ========================================= */
.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-dark);
    margin-bottom: 8px;
}

.form-label .required {
    color: var(--danger);
    margin-left: 4px;
}

.form-control {
    width: 100%;
    padding: 12px 16px;
    font-size: 14px;
    border: 1.5px solid var(--border);
    border-radius: var(--radius);
    transition: all 0.2s ease;
    background: white;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(13, 110, 253, 0.15);
}

.form-control::placeholder {
    color: var(--text-muted);
}

textarea.form-control {
    resize: vertical;
    min-height: 100px;
}

select.form-control {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%236c757d' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    padding-right: 40px;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.form-text {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 6px;
}

/* =========================================
   徽章
   ========================================= */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    font-size: 12px;
    font-weight: 500;
    border-radius: var(--radius-full);
}

.badge-primary { background: var(--primary-light); color: var(--primary); }
.badge-success { background: var(--success-light); color: var(--success); }
.badge-warning { background: var(--warning-light); color: #856404; }
.badge-danger { background: var(--danger-light); color: var(--danger); }
.badge-info { background: var(--info-light); color: #0c5968; }
.badge-secondary { background: var(--light); color: var(--text-muted); }

/* =========================================
   表格
   ========================================= */
.data-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
}

.data-table th,
.data-table td {
    padding: 14px 16px;
    text-align: left;
    border-bottom: 1px solid var(--border);
}

.data-table th {
    background: var(--light);
    font-weight: 600;
    font-size: 13px;
    color: var(--text-dark);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.data-table th:first-child {
    border-radius: var(--radius) 0 0 0;
}

.data-table th:last-child {
    border-radius: 0 var(--radius) 0 0;
}

.data-table tr:hover td {
    background: var(--light);
}

.data-table td {
    font-size: 14px;
}

.table-actions {
    display: flex;
    gap: 8px;
}

/* =========================================
   详情行
   ========================================= */
.detail-row {
    display: flex;
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
}

.detail-row:last-child {
    border-bottom: none;
}

.detail-label {
    width: 140px;
    flex-shrink: 0;
    color: var(--text-muted);
    font-weight: 500;
}

.detail-value {
    flex: 1;
    color: var(--text-dark);
}

/* =========================================
   警告/提示框
   ========================================= */
.alert {
    padding: 16px 20px;
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 14px;
}

.alert-success {
    background: var(--success-light);
    color: #0f5132;
    border: 1px solid #a3cfbb;
}

.alert-danger {
    background: var(--danger-light);
    color: #842029;
    border: 1px solid #f1b0b7;
}

.alert-warning {
    background: var(--warning-light);
    color: #856404;
    border: 1px solid #ffe69c;
}

.alert-info {
    background: var(--info-light);
    color: #055160;
    border: 1px solid #6edff6;
}

/* =========================================
   详情区域
   ========================================= */
.detail-section {
    margin-bottom: 24px;
}

.detail-section-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--primary);
    display: flex;
    align-items: center;
    gap: 8px;
}

/* =========================================
   审核类型选择
   ========================================= */
.review-type-selector {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    margin-bottom: 20px;
}

.review-type-option {
    position: relative;
    cursor: pointer;
}

.review-type-option input {
    position: absolute;
    opacity: 0;
}

.review-type-option > div,
.review-type-option h4,
.review-type-option p {
    padding: 20px;
    border: 2px solid var(--border);
    border-radius: var(--radius-lg);
    transition: all 0.2s;
    margin: 0;
}

.review-type-option h4 {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 8px;
}

.review-type-option p {
    font-size: 13px;
    color: var(--text-muted);
    margin: 0;
}

.review-type-option input:checked + div,
.review-type-option input:checked ~ h4,
.review-type-option input:checked ~ p {
    border-color: var(--primary);
    background: var(--primary-light);
}

.review-type-option input:checked + div h4,
.review-type-option input:checked ~ h4 {
    color: var(--primary);
}

/* 决策选择 */
.decision-selector {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
    margin-bottom: 20px;
}

.decision-option {
    position: relative;
    cursor: pointer;
}

.decision-option input {
    position: absolute;
    opacity: 0;
}

.decision-option span {
    display: block;
    padding: 16px;
    text-align: center;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    font-weight: 600;
    transition: all 0.2s;
}

.decision-option input:checked + span {
    border-color: var(--primary);
    background: var(--primary);
    color: white;
}

.decision-option input:checked + span.approved {
    background: var(--success);
    border-color: var(--success);
}

.decision-option input:checked + span.approved-with-conditions {
    background: var(--warning);
    border-color: var(--warning);
    color: #856404;
}

.decision-option input:checked + span.rejected {
    background: var(--danger);
    border-color: var(--danger);
}

/* =========================================
   工具类
   ========================================= */
.d-flex { display: flex; }
.flex-1 { flex: 1; }
.justify-between { justify-content: space-between; }
.align-center { align-items: center; }
.gap-1 { gap: 8px; }
.gap-2 { gap: 16px; }
.mb-1 { margin-bottom: 8px; }
.mb-2 { margin-bottom: 16px; }
.mt-2 { margin-top: 16px; }
.p-2 { padding: 16px; }
.text-center { text-align: center; }
.text-muted { color: var(--text-muted); }
.text-success { color: var(--success); }
.text-danger { color: var(--danger); }

/* =========================================
   表单样式
   ========================================= */
.form-section {
    max-width: 900px;
    margin: 0 auto;
}

.form-card {
    background: #fff;
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 20px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.form-card h2 {
    font-size: 16px;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 1px solid #e2e8f0;
}

.field {
    margin-bottom: 16px;
}

.field label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    color: #475569;
    margin-bottom: 6px;
}

.field input[type="text"],
.field input[type="number"],
.field input[type="email"],
.field input[type="tel"],
.field input[type="date"],
.field select,
.field textarea {
    width: 100%;
    padding: 10px 12px;
    font-size: 14px;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    background: #fff;
    color: #1e293b;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(8, 145, 178, 0.1);
}

.field textarea {
    min-height: 100px;
    resize: vertical;
    line-height: 1.6;
}

.field-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
}

.field-sm {
    flex: 0 0 120px;
}

.red {
    color: #dc2626;
}

/* =========================================
   页脚
   ========================================= */
.footer {
    background: white;
    border-top: 1px solid var(--border);
    padding: 24px 0;
    margin-top: auto;
    text-align: center;
}

.footer p {
    font-size: 13px;
    color: var(--text-muted);
}

.footer a {
    color: var(--primary);
    text-decoration: none;
}

/* =========================================
   登录页面
   ========================================= */
.login-container {
    min-height: calc(100vh - 200px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
}

.login-card {
    background: white;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-xl);
    width: 100%;
    max-width: 420px;
    overflow: hidden;
}

.login-header {
    background: var(--primary-gradient);
    padding: 32px;
    text-align: center;
    color: white;
}

.login-header h1 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 8px;
}

.login-header p {
    font-size: 14px;
    opacity: 0.9;
}

.login-body {
    padding: 32px;
}

/* =========================================
   动画
   ========================================= */
.fade-in {
    animation: fadeIn 0.4s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* =========================================
   审批报告
   ========================================= */
.approval-report {
    background: white;
    padding: 48px;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-lg);
    max-width: 800px;
    margin: 0 auto;
}

.approval-report .report-header {
    text-align: center;
    margin-bottom: 40px;
    padding-bottom: 24px;
    border-bottom: 3px solid var(--primary);
}

.approval-report .report-header h1 {
    font-size: 26px;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 8px;
}

.approval-report .report-header h2 {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-dark);
}

.approval-report .report-info {
    background: var(--light);
    padding: 24px;
    border-radius: var(--radius);
    margin-bottom: 32px;
}

.approval-report .report-section {
    margin-bottom: 32px;
}

.approval-report .report-section h3 {
    font-size: 18px;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border);
}

.approval-report .decision {
    font-size: 20px;
    font-weight: 700;
    text-align: center;
    padding: 20px;
    border: 2px solid var(--primary);
    border-radius: var(--radius-lg);
    color: var(--primary);
}

.approval-report .signatures {
    display: flex;
    justify-content: flex-end;
    gap: 80px;
    margin-top: 48px;
    padding-top: 24px;
    border-top: 1px solid var(--border);
}

.approval-report .signature-block p {
    margin-bottom: 8px;
    font-size: 14px;
}

/* =========================================
   响应式
   ========================================= */
@media (max-width: 768px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .review-type-selector,
    .decision-selector {
        grid-template-columns: 1fr;
    }
    
    .hero-section {
        padding: 32px 20px;
    }
    
    .hero-section h1 {
        font-size: 24px;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .navbar-inner {
        flex-wrap: wrap;
        height: auto;
        padding: 12px 0;
        gap: 12px;
    }
    
    .navbar-menu {
        order: 3;
        width: 100%;
        overflow-x: auto;
        padding-bottom: 8px;
    }
}

/* =========================================
   打印样式
   ========================================= */
@media print {
    body {
        background: white;
        font-size: 12px;
    }
    
    body::before,
    .navbar,
    .footer,
    .btn,
    .alert {
        display: none !important;
    }
    
    .main-content {
        padding: 0;
    }
    
    .card {
        border: none;
        box-shadow: none;
    }
    
    .approval-report {
        padding: 20px;
        box-shadow: none;
    }
}


/* =========================================
   功能卡片
   ========================================= */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 24px;
}

.feature-card {
    background: var(--light);
    border-radius: var(--radius-lg);
    padding: 28px;
    text-align: center;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.feature-card:hover {
    background: white;
    border-color: var(--primary-light);
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.feature-card .feature-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 16px;
    background: var(--primary-light);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
}

.feature-card h3 {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 12px;
}

.feature-card p {
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.6;
}

/* =========================================
   查询结果卡片
   ========================================= */
.query-result-card {
    background: linear-gradient(135deg, var(--primary-light) 0%, #e7f1ff 100%);
    border-radius: var(--radius-xl);
    padding: 32px;
    margin-bottom: 24px;
    border: 1px solid var(--primary-light);
}

.query-result-header {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 24px;
}

.query-result-icon {
    width: 72px;
    height: 72px;
    background: var(--primary);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

.query-result-title {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 4px;
}

.query-result-subtitle {
    font-size: 14px;
    color: var(--text-muted);
}

/* 状态徽章大号 */
.status-badge-lg {
    display: inline-flex;
    align-items: center;
    padding: 8px 16px;
    font-size: 14px;
    font-weight: 600;
    border-radius: var(--radius-full);
}

.status-badge-lg.badge-success {
    background: var(--success);
    color: white;
}

.status-badge-lg.badge-danger {
    background: var(--danger);
    color: white;
}

.status-badge-lg.badge-warning {
    background: var(--warning);
    color: #856404;
}

/* =========================================
   面包屑导航
   ========================================= */
.breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: var(--text-muted);
    margin-bottom: 24px;
}

.breadcrumb a {
    color: var(--primary);
    text-decoration: none;
}

.breadcrumb a:hover {
    text-decoration: underline;
}

.breadcrumb-separator {
    color: var(--border);
}

/* =========================================
   空状态
   ========================================= */
.empty-state {
    text-align: center;
    padding: 60px 20px;
}

.empty-state-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    background: var(--light);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
}

.empty-state h3 {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 8px;
}

.empty-state p {
    font-size: 14px;
    color: var(--text-muted);
    margin-bottom: 20px;
}

/* =========================================
   加载动画
   ========================================= */
.loading {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 40px;
}

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

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

/* =========================================
   页面标题
   ========================================= */
.page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
    flex-wrap: wrap;
    gap: 16px;
}

.page-title {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-dark);
    margin: 0;
}

.page-subtitle {
    font-size: 14px;
    color: var(--text-muted);
    margin-top: 4px;
}

