/* ========== Cover page: wide-screen horizontal layout, left-text right-image ========== */
.report-cover {
    width: 100%;
    background-color: #fff;
    margin-bottom: 40px;
    box-sizing: border-box;
}
/* Cover content width: 1200px, same as body container, for wide-screen horizontal layout */
.report-cover-inner {
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
    box-sizing: border-box;
    padding: 0 24px;
}

/* Top: logo.png on the left */
.cover-header {
    display: flex;
    justify-content: flex-start;
    align-items: flex-start;
    padding: 20px 0 12px;
    background: #ffffff;
}
.cover-logo img {
    height: auto;
    max-height: 64px;
    width: auto;
    max-width: 100%;
    display: block;
    object-fit: contain;
}
/* Main: horizontal left-right layout, left-text right-image */
.cover-body {
    background-color: #ffffff;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding: 0 0 8px;
    gap: 40px;
    min-height: 420px;
}
/* Left: title + red badge, left-aligned */
.cover-body-upper {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    flex: 0 0 auto;
    padding: 0;
    margin-bottom: 0;
    box-sizing: border-box;
}
.cover-center-block {
    text-align: left;
    width: auto;
    max-width: 100%;
    margin-top: 0;
    margin-bottom: 0;
    padding-top: 0;
    padding-bottom: 0;
}
.cover-main-title {
    margin: 0 0 0.14em 0;
    font-size: clamp(56px, 7vw, 100px);
    font-weight: 800;
    color: #111111;
    letter-spacing: 0.04em;
    line-height: 1.02;
}
.cover-title-badge {
    display: inline-block;
    position: relative;
    z-index: 1;
    margin-bottom: 0;
    padding: 0.6em 1.8em;
    min-width: 0;
    font-size: clamp(18px, 2.5vw, 28px);
    font-weight: 700;
    color: #ffffff;
    background: #d81e31;
    border-radius: 999px;
    letter-spacing: 0.35em;
    text-indent: 0.35em;
}
/* Right: background illustration, positioned in the right half */
.cover-artwork {
    flex: 1 1 auto;
    min-width: 0;
    max-width: 55%;
    height: auto;
    display: block;
    margin-top: 0;
    margin-bottom: 0;
    object-fit: contain;
    object-position: center center;
}
/* Bottom-left: protocol number */
.cover-footer {
    padding: 0 0 16px;
    background: #ffffff;
}
.cover-protocol {
    font-size: 18px;
    font-weight: 700;
    color: #000000;
    letter-spacing: 0.02em;
}

@media (max-width: 768px) {
    .report-cover-inner {
        padding: 0 16px;
        max-width: 100%;
    }
    .cover-header {
        padding: 16px 0 10px;
    }
    /* Small screens: fall back to vertical stacking */
    .cover-body {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
        min-height: auto;
    }
    .cover-body-upper {
        align-items: flex-start;
    }
    .cover-center-block {
        text-align: left;
        margin-top: 16px;
    }
    .cover-main-title {
        font-size: clamp(42px, 10vw, 72px);
    }
    .cover-artwork {
        max-width: 100%;
        width: 100%;
    }
    .cover-protocol {
        font-size: 15px;
    }
}

/* Base style reset */
html, body, div, ul, ol {
    margin: 0;
    padding: 0;
}

body {
    color: #3E3A39;
    font-family: 'Source Sans 3', 'Noto Sans SC', 'Microsoft YaHei', 'PingFang SC', sans-serif;
    font-size: 14px;
    line-height: 1.6;
    background: #FFFFFF;
}

a {
    color: #da1e33;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

/* Fixed top navigation */
.fixed-top-nav {
    position: fixed;
    top: 0;
    left: 0;
    width: 50%;
    z-index: 1000;
    background: #F3F3F3;
    border-bottom: 1px solid #eee;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.nav-table {
    background-image: -moz-linear-gradient(top, #EEEEEE, #FFFFFF);
    background-image: -webkit-gradient(linear, left top, left bottom, color-stop(0, #EEEEEE), color-stop(1, #FFFFFF));
    filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#EEEEEE', endColorstr='#FFFFFF', GradientType='0');
}

.nav-logo {
    height: 40px;
}

.nav-divider {
    margin: 5px;
    border-left: 1px solid #DCDCDC;
    height: 30px;
}

/* ========== Sidebar TOC: Quick Navigation card ========== */
.toc-sidebar {
    position: fixed;
    left: 16px;
    top: 16px;
    width: 240px;
    max-height: calc(100vh - 72px);
    z-index: 100;
    display: flex;
    flex-direction: column;
    background: #ffffff;
    border-radius: 10px;
    box-shadow: 0 4px 24px rgba(15, 23, 42, 0.08), 0 2px 10px rgba(15, 23, 42, 0.06);
    overflow: hidden;
}

.toc-sidebar-header {
    position: relative;
    flex-shrink: 0;
    padding: 14px 18px;
    background: #475569;
    color: #ffffff;
    font-size: 16px;
    font-weight: 600;
    letter-spacing: 0.02em;
    overflow: hidden;
}

.toc-sidebar-title {
    position: relative;
    z-index: 1;
}

.toc-sidebar-header-icon {
    position: absolute;
    right: -6px;
    top: 50%;
    transform: translateY(-50%);
    width: 64px;
    height: 64px;
    opacity: 0.14;
    color: #ffffff;
    pointer-events: none;
}

.toc-sidebar-header-icon svg {
    width: 100%;
    height: 100%;
    display: block;
}

.toc-sidebar-body {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 8px 0 14px;
}

/* tocify embedded in sidebar: override plugin default fixed/border */
.toc-sidebar .tocify {
    position: relative !important;
    left: auto !important;
    top: auto !important;
    width: 100% !important;
    max-height: none !important;
    height: auto !important;
    margin: 0 !important;
    padding: 0 !important;
    border: none !important;
    background: transparent !important;
    border-radius: 0 !important;
    box-shadow: none !important;
}

.toc-sidebar .tocify ul,
.toc-sidebar .tocify li {
    line-height: 1.45;
    font-size: 14px;
}

.toc-sidebar .tocify ul a {
    text-decoration: none;
    display: block;
    padding: 0;
    border: none;
}

.toc-sidebar .tocify ul a:hover {
    text-decoration: none;
}

/* Level 1 (h2): default gray-blue text */
.toc-sidebar .tocify-header > .tocify-item > a {
    color: #5c6b7a;
    font-weight: 400;
}

.toc-sidebar .tocify-header > .tocify-item {
    padding: 10px 18px;
    margin: 2px 0;
}

.toc-sidebar .tocify-header > .tocify-item.active {
    background: #DFE7F0;
    font-weight: 700;
}

.toc-sidebar .tocify-header > .tocify-item.active > a {
    color: #000000;
    font-weight: 700;
}

/* When a sub-section item is active, parent level-1 still shows highlight */
.toc-sidebar .tocify-header:has(.tocify-subheader li.active) > li.tocify-item:first-of-type {
    background: #DFE7F0;
}

.toc-sidebar .tocify-header:has(.tocify-subheader li.active) > li.tocify-item:first-of-type > a {
    color: #000000;
    font-weight: 700;
}

/* Level 2 (h3): indented */
.toc-sidebar .tocify-subheader .tocify-item {
    padding: 8px 18px 8px 32px;
    margin: 0;
}

.toc-sidebar .tocify-subheader .tocify-item > a {
    color: #3e3a39;
    font-weight: 400;
    font-size: 13px;
}

.toc-sidebar .tocify-subheader .tocify-item.active > a {
    color: #da1e33;
    font-weight: 600;
}

.toc-sidebar .tocify-header .tocify-item,
.toc-sidebar .tocify-subheader .tocify-item {
    border-radius: 0;
}

.toc-sidebar .tocify > ul.tocify-header.nav {
    padding-left: 0;
    margin-bottom: 0;
}

.toc-sidebar .tocify > ul.tocify-header + ul.tocify-header {
    margin-top: 6px;
}

/* Main content: symmetric margins for visual centering */
.main-content {
    margin-left: 280px;  /* Make room for left sidebar */
    margin-right: 280px; /* Right side keeps equal margin to force centering */
    padding-top: 30px;
    min-height: 100vh;
}

/* Content container: limit max width */
.report-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* When screen < 1600px, shrink right margin to prioritize content width */
@media (max-width: 1600px) {
    .main-content {
        margin-right: 30px;
    }
}

/* Mobile/small screen: hide sidebar, reduce side margins */
@media (max-width: 768px) {
    .toc-sidebar {
        display: none !important;
    }
    .main-content {
        margin-left: 15px;
        margin-right: 15px;
    }
    .report-container {
        padding: 0;
    }
}

/* Report header: title + info cards */
.report-header {
    margin-bottom: 2rem;
}

.report-title {
    text-align: center;
    color: #000000;
    font-size: 30px;
    font-weight: bold;
    margin: 30px 0 20px 0;
}

/* Bottom to top: #DFE7F0 at bottom, fading to white */
.report-header-box {
    padding: 28px 40px;
    background: linear-gradient(to top, #DFE7F0 0%, #ffffff 100%);
    border-radius: 8px;
    box-sizing: border-box;
}

.report-meta-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto auto;
    gap: 18px 40px;
}

.report-meta-row {
    display: flex;
    align-items: baseline;
    gap: 8px;
    white-space: nowrap;
}

.report-meta-label {
    font-size: 14px;
    color: #000000;
    line-height: 1.5;
    flex-shrink: 0;
}

.report-meta-value {
    font-size: 14px;
    color: #000000;
    font-weight: 500;
    line-height: 1.5;
    word-break: break-word;
}

@media (max-width: 768px) {
    .report-meta-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    .report-header-box {
        padding: 20px 24px;
    }
}

/* Section styles */
.report-section {
    margin-bottom: 40px;
}

.report-section h2 {
    color: #da1e33;
    font-size: 24px;
    margin-bottom: 20px;
    padding-bottom: 10px;
    /* Bottom green line moved to .section-title-modern, no longer conflicts */
}

/* Modern section title */
h2.section-title-modern {
    display: flex;
    align-items: center;
    font-size: 24px;
    font-weight: bold;
    color: #333;
    margin: 30px 0 20px 0;
    border-bottom: none !important;
    padding-bottom: 0;
}

h2.section-title-modern .num-box {
    background-color: #da1e33;
    color: white;
    width: 32px;
    height: 32px;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    margin-right: 15px;
    font-size: 20px;
    flex-shrink: 0;
}

.report-section h3 {
    color: #222;
    font-size: 18px;
    margin: 20px 0 15px 0;
    padding-left: 10px;
    border-left: 4px solid #da1e33;
    font-weight: bold;
}

.report-section h4 {
    color: #000;
    font-size: 15px;
    margin: 15px 0 10px 0;
    font-weight: bold;
    text-indent: 0;
}

/* Paragraph styles */
.paragraph {
    text-indent: 2em;
    line-height: 1.8;
    margin: 10px 0;
}

/* ---------- Project overview specific styles ---------- */

/* Paragraph (no first-line indent) */
.para-no-indent {
    text-indent: 0;
    line-height: 1.8;
    color: #3E3A39;
    margin: 10px 0;
}

/* Red entry title (Technical Overview) */
.title-bar-red {
    border-left: 4px solid #da1e33;
    padding-left: 10px;
    font-size: 20px;
    font-weight: bold;
    color: #333;
    margin: 25px 0 15px 0;
}

/* Numbered box title (Experimental Workflow) */
.title-num-block {
    display: flex;
    align-items: center;
    font-size: 20px;
    font-weight: bold;
    margin: 30px 0 20px 0;
}

.title-num-block span {
    background-color: #da1e33;
    color: white;
    width: 28px;
    height: 28px;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    margin-right: 12px;
    font-size: 16px;
    line-height: 1;
}

/* Red secondary title (1.1 Library Preparation etc.) */
.subtitle-red,
h4.subtitle-red {
    color: #da1e33;
    font-size: 16px;
    margin: 20px 0 10px 0;
    padding-left: 10px;
    border-left: 3px solid #da1e33;
    font-weight: bold;
}

/* Black tertiary title (for div, e.g. GSEA subsection title) */
.subtitle-black {
    color: #000;
    font-size: 15px;
    font-weight: bold;
    margin: 15px 0 10px 0;
}

/* h4 tertiary title (1.3.1 etc.) — indentation controlled by outer .sub-content-block */
h4.subtitle-black {
    color: #000;
    font-size: 15px;
    font-weight: bold;
    margin: 15px 0 10px 0;
    text-indent: 0;
}

/* Indented content block — wraps sub-content that needs overall indentation */
.sub-content-block {
    padding-left: 2em;
}

/* Rounded info box (fastq description box) */
.rounded-info-box {
    border: 1px solid #ccc;
    border-radius: 12px;
    padding: 20px;
    margin: 20px 0;
    background: #fff;
    overflow: hidden;
}

/* Report content images: auto-fit container width, prevent narrow-screen overflow */
.report-section img {
    max-width: 100%;
    height: auto;
}

/* Project overview unstyled list */
.overview-list {
    list-style: none;
    margin: 10px 0 10px 0;
    padding: 0;
}

.overview-list li {
    position: relative;
    padding-left: 18px;
    line-height: 1.9;
    color: #3E3A39;
    margin-bottom: 6px;
}

.overview-list li::before {
    content: "·";
    position: absolute;
    left: 0;
    color: #3E3A39;
    font-weight: bold;
}

/* Light gray formula box */
.gray-formula-box {
    background: #f4f5f7;
    padding: 15px 20px;
    border-radius: 4px;
    margin: 15px 0;
    font-family: Arial, sans-serif;
    color: #333;
    line-height: 2;
}

/* Modern Image Selector outer frame */
.modern-img-group {
    border: 2px solid #858d98;
    border-radius: 16px;
    margin-bottom: 30px;
    overflow: hidden;
    background: #fff;
}

/* Modern image group header with tabs */
.modern-tab-header {
    background: #858d98;
    border-radius: 16px 16px 0 0;
    display: flex;
    padding: 0 20px;
    align-items: flex-end;
    overflow-x: auto;
}

.modern-tab-item {
    color: #d1d4d7;
    padding: 15px 20px;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s;
    white-space: nowrap;
}

.modern-tab-item:hover {
    color: #fff;
}

.modern-tab-item.active {
    color: #fff;
    font-weight: bold;
}

.modern-tab-content {
    display: none;
    padding: 20px;
    background: #fff;
    border-radius: 0 0 16px 16px;
    text-align: center;
}

.modern-tab-content.active {
    display: block;
}

/* Modern Image Selector title bar */
.modern-img-header {
    background: #858d98;
    color: #fff;
    padding: 12px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 16px;
}

.modern-img-header .badge {
    background: rgba(0,0,0,0.2);
    padding: 2px 12px;
    border-radius: 12px;
    font-size: 13px;
}

/* Modern Image Selector content area */
.modern-img-body {
    display: flex;
    padding: 20px;
    gap: 20px;
    background: #fff;
}

/* Modern Image Gallery (left) */
.modern-img-view {
    flex: 1;
    text-align: center;
}

.modern-img-view img {
    max-width: 100%;
    max-height: 450px;
    object-fit: contain;
}

/* Modern image button list (right) */
.modern-img-list {
    width: 300px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    flex-shrink: 0;
    max-height: 450px;
    overflow-y: auto;
}

/* Modern capsule button */
.modern-img-btn {
    padding: 12px 20px;
    background: #f4f5f7;
    border-radius: 12px;
    cursor: pointer;
    text-align: center;
    color: #555;
    transition: all 0.3s;
    font-size: 14px;
}

.modern-img-btn:hover {
    background: #e8e9ea;
}

.modern-img-btn.active {
    background: #da1e33;
    color: #fff;
    font-weight: bold;
}

/* Stacked layout content area */
.modern-img-body-stacked {
    padding: 20px;
    background: #fff;
    text-align: center;
}

.modern-img-body-stacked .image-tabs-wrapper {
    margin-bottom: 20px;
    border-bottom: 1px solid #eee;
    padding-bottom: 15px;
}

/* Plain text description field */
.plain-field-desc {
    font-size: 13px;
    color: #555;
    line-height: 1.8;
    margin-top: 15px;
}

/* Divider line */
hr {
    border: none;
    height: 1px;
    line-height: 1px;
    background: #E5E5E5;
    margin-bottom: 20px;
    padding: 0;
}

/* Table styles - gy class */
.gy {
    font-family: 'Source Sans 3', 'Noto Sans SC', 'Microsoft YaHei', 'PingFang SC', sans-serif;
    width: auto;
    min-width: 100%;
    border-collapse: collapse;
    margin: 15px auto;
}

/* Fixed column width table styles */
.gy.fixed-first-col {
    table-layout: fixed;
    width: auto;
    min-width: 100%;
}

/* Fixed column width table column width settings */
.gy.fixed-first-col th:first-child,
.gy.fixed-first-col td:first-child {
    width: 40ch;
    min-width: 40ch;
    max-width: 40ch;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Header style: red background, white text, white dividers */
.gy th {
    font-size: 1em;
    border: 2px solid #ffffff;
    padding: 12px 15px;
    text-align: center;
    word-break: keep-all;
    white-space: nowrap;
    background-color: #da1e33;
    color: #ffffff;
    font-weight: 500;
}

/* Data cells: pure white dividers */
.gy td {
    font-size: 1em;
    border: 2px solid #ffffff;
    padding: 10px 15px;
    text-align: center;
    word-break: keep-all;
    white-space: nowrap;
    color: #333333;
}

/* Odd row background: very light gray */
.gy tr:nth-child(odd) {
    background: #f8f9fa;
}

/* Even row background: light gray-blue */
.gy tr:nth-child(even) {
    background: #e2e6ea;
}

/* Row hover highlight */
.gy tr:hover td {
    background: #d4d9df;
    transition: background 0.3s ease;
}

/* Table responsive */
.table-responsive {
    overflow-x: auto;
    margin: 15px 0;
}

.table {
    margin-bottom: 0;
}

/* ========== Image Selector styles ========== */
.image-selector-container {
    margin: 20px 0;
}

/* Group card */
.image-group-card {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    margin-bottom: 15px;
    overflow: hidden;
}

.image-group-header {
    background: linear-gradient(135deg, #da1e33 0%, #b01828 100%);
    color: white;
    padding: 12px 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: background 0.3s ease;
}

.image-group-header:hover {
    background: linear-gradient(135deg, #b01828 0%, #8a1220 100%);
}

.group-title {
    font-size: 16px;
    font-weight: 600;
}

.group-badge {
    background: rgba(255,255,255,0.2);
    padding: 2px 10px;
    border-radius: 12px;
    font-size: 12px;
}

.group-toggle {
    transition: transform 0.3s ease;
}

.group-toggle.collapsed {
    transform: rotate(-90deg);
}

.image-group-content {
    padding: 15px;
    background: #fafafa;
}

.image-group-content.collapsed {
    display: none;
}

/* Thumbnail list */
.image-tabs-wrapper {
    margin-bottom: 15px;
    border-bottom: 2px solid #e0e0e0;
    padding-bottom: 10px;
}

.image-tab-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    list-style: none;
    padding: 0;
    margin: 0;
}

.image-tab-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 8px 12px;
    background: #fff;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 100px;
    max-width: 120px;
}

.image-tab-item:hover {
    border-color: #da1e33;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.image-tab-item.active {
    border-color: #da1e33;
    background: #fceaea;
    box-shadow: 0 2px 8px rgba(218,30,51,0.3);
}

.image-thumbnail {
    width: 80px;
    height: 50px;
    object-fit: contain;
    border-radius: 4px;
    margin-bottom: 5px;
    background: #f0f0f0;
}

.image-tab-label {
    font-size: 11px;
    color: #666;
    text-align: center;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 100px;
}

.image-tab-item.active .image-tab-label {
    color: #da1e33;
    font-weight: 600;
}

/* Image Gallery */
.image-viewer {
    text-align: center;
    background: #fff;
    padding: 15px;
    border-radius: 8px;
    border: 1px solid #e0e0e0;
    max-height: none;
    overflow: visible;
}

.image-viewer img {
    max-width: 100%;
    max-height: 450px;
    cursor: pointer;
    transition: transform 0.3s ease;
    border-radius: 4px;
}

/* Image container - supports double-click zoom */
.image-container {
    display: block;
    text-align: center;
    width: 100%;
}

.image-container img {
    max-width: 100%;
    max-height: 450px;
    cursor: zoom-in;
    object-fit: contain;
}

.image-container.fullscreen-div {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 9999;
    background: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: zoom-out;
}

.image-container.fullscreen-div img {
    width: auto;
    height: auto;
    max-width: 90vw;
    max-height: 90vh;
    cursor: zoom-out;
}

/* Left-right layout styles */
.image-side-by-side {
    display: flex;
    background: #fafafa;
    padding: 15px;
    gap: 15px;
}

.image-viewer-large {
    flex: 1;
    background: #fff;
    padding: 10px;
    border-radius: 8px;
    border: 1px solid #e0e0e0;
    text-align: center;
}

.image-viewer-large img {
    max-width: 100%;
    max-height: 400px;
    height: 400px;
    object-fit: contain;
    cursor: pointer;
}

.image-viewer-large .tab-pane {
    display: none;
}

.image-viewer-large .tab-pane.active {
    display: block;
}

.image-list-sidebar {
    width: 180px;
    flex-shrink: 0;
    background: #fff;
    border-radius: 8px;
    border: 1px solid #e0e0e0;
    max-height: 420px;
    overflow-y: auto;
}

.image-name-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.image-name-item {
    padding: 10px 15px;
    border-bottom: 1px solid #f0f0f0;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 13px;
    color: #666;
}

.image-name-item:hover {
    background: #fceaea;
    color: #da1e33;
}

.image-name-item.active {
    background: #da1e33;
    color: #fff;
    font-weight: 600;
}

/* Responsive - small screen stacked layout */
@media (max-width: 768px) {
    .image-side-by-side {
        flex-direction: column;
    }
    
    .image-list-sidebar {
        width: 100%;
        max-height: 200px;
    }

    /* Modern image selector: narrow screen switches to stacked layout, images full width, options wrap below */
    .modern-img-body {
        flex-direction: column;
    }
    .modern-img-list {
        width: 100%;
        flex-direction: row;
        flex-wrap: wrap;
        max-height: none;
        overflow-x: auto;
    }
}

.image-viewer img:hover {
    transform: scale(1.02);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

/* Fullscreen image */
.fullscreen-div {
    z-index: 9999;
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    right: 0;
    margin: auto;
    background: rgba(0,0,0,0.9);
    display: flex;
    align-items: center;
    justify-content: center;
}

.fullscreen-img {
    max-width: 95vw;
    max-height: 95vh;
    cursor: pointer;
}

/* Back-to-top button */
#goTopBtn {
    position: fixed;
    text-align: center;
    line-height: 30px;
    width: 40px;
    height: 40px;
    bottom: 35px;
    right: 20px;
    cursor: pointer;
    background: #F7F7F7;
    border: 1px solid #D1D1D1;
    border-radius: 50%;
    transition: all 0.3s ease;
    z-index: 1000;
}

#goTopBtn:hover {
    background: #da1e33;
    transform: translateY(-3px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

#goTopBtn:hover svg path {
    fill: #ffffff;
}

/* Statistics metric cards */
.stat-card {
    background: linear-gradient(135deg, #da1e33 0%, #b01828 100%);
    color: white;
    padding: 20px;
    border-radius: 8px;
    text-align: center;
    margin-bottom: 15px;
}

.stat-card .stat-value {
    font-size: 28px;
    font-weight: bold;
}

.stat-card .stat-label {
    font-size: 14px;
    opacity: 0.9;
}

.stat-card.secondary {
    background: linear-gradient(135deg, #539A34 0%, #3d7a28 100%);
}

.stat-card.accent {
    background: linear-gradient(135deg, #A7C942 0%, #8fa832 100%);
}

/* Table search box */
.table-search {
    margin-bottom: 10px;
}

.table-search input {
    max-width: 300px;
    padding: 6px 12px;
    border: 1px solid #ced4da;
    border-radius: 4px;
}

.table-search input:focus {
    border-color: #da1e33;
    box-shadow: 0 0 0 0.2rem rgba(3, 110, 184, 0.25);
}

/* Table numeric filter */
.table-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 10px;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 4px;
}

.table-filter-item {
    display: flex;
    align-items: center;
    gap: 5px;
}

.filter-label {
    font-size: 12px;
    color: #333;
    white-space: nowrap;
}

.filter-input {
    width: 80px !important;
    padding: 4px 8px !important;
    font-size: 12px !important;
    border: 1px solid #ced4da !important;
    border-radius: 4px !important;
}

.filter-input:focus {
    border-color: #da1e33 !important;
    box-shadow: 0 0 0 0.2rem rgba(218, 30, 51, 0.25) !important;
}

.filter-separator {
    color: #666;
    font-size: 12px;
}

/* Table filter button */
.table-filter-btn-container {
    display: inline-block;
    margin-bottom: 10px;
    margin-left: 10px;
}

.table-filter-btn-container .btn-primary {
    background: linear-gradient(135deg, #da1e33 0%, #b01828 100%);
    border: none;
}

.table-filter-btn-container .btn-primary:hover {
    background: linear-gradient(135deg, #b01828 0%, #8a1220 100%);
}

.filter-icon {
    margin-right: 5px;
}

.filter-count {
    display: inline-block;
    background: #da1e33;
    color: white;
    border-radius: 10px;
    padding: 2px 8px;
    font-size: 12px;
    margin-left: 5px;
}

/* Filter modal styles */
.filter-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    animation: fadeIn 0.3s;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.filter-modal-content {
    background-color: #fff;
    margin: 5% auto;
    padding: 0;
    border-radius: 8px;
    width: 90%;
    max-width: 700px;
    max-height: 80vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.filter-modal-header {
    background: linear-gradient(135deg, #da1e33 0%, #b01828 100%);
    color: white;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.filter-modal-header h4 {
    margin: 0;
    font-size: 18px;
}

.filter-modal-close {
    color: white;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    line-height: 1;
}

.filter-modal-close:hover {
    color: #ff6b6b;
}

.filter-modal-body {
    padding: 20px;
    overflow-y: auto;
    flex: 1;
}

.filter-logic-section {
    margin-bottom: 20px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 6px;
}

.filter-logic-section label {
    font-weight: 600;
    color: #333;
    margin-bottom: 10px;
    display: block;
}

.filter-logic-buttons {
    display: flex;
    gap: 20px;
}

.filter-radio {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-weight: normal !important;
}

.filter-radio input {
    margin-right: 8px;
    width: 16px;
    height: 16px;
    accent-color: #da1e33;
}

.filter-conditions {
    min-height: 100px;
}

.filter-condition {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px;
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    margin-bottom: 10px;
    flex-wrap: wrap;
}

.filter-condition select,
.filter-condition input {
    padding: 6px 10px;
    border: 1px solid #ced4da;
    border-radius: 4px;
    font-size: 13px;
}

.filter-condition select {
    min-width: 120px;
}

.filter-condition input[type="number"] {
    width: 100px;
}

.filter-condition input[type="text"] {
    width: 120px;
}

.filter-condition .operator-select {
    width: 80px;
}

.filter-condition .remove-condition {
    background: none;
    border: none;
    color: #dc3545;
    font-size: 20px;
    cursor: pointer;
    padding: 0 5px;
    margin-left: auto;
}

.filter-condition .remove-condition:hover {
    color: #c82333;
}

.filter-actions {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

.filter-modal-footer {
    padding: 15px 20px;
    background: #f8f9fa;
    border-top: 1px solid #e0e0e0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.filter-result-count {
    color: #da1e33;
    font-weight: 600;
}

.filter-modal-buttons {
    display: flex;
    gap: 10px;
}

.filter-modal-buttons .btn-primary {
    background: linear-gradient(135deg, #da1e33 0%, #b01828 100%);
    border: none;
}

.filter-modal-buttons .btn-primary:hover {
    background: linear-gradient(135deg, #b01828 0%, #8a1220 100%);
}

/* Column sort indicator */
th {
    position: relative;
}
th .sort-indicator {
    position: absolute;
    margin-left: 4px;
    opacity: 0.3;
}

th .sort-indicator::before {
    content: "↕";
}

th.sorted-asc .sort-indicator::before {
    content: "↑";
    opacity: 1;
    color: #da1e33;
}

th.sorted-desc .sort-indicator::before {
    content: "↓";
    opacity: 1;
    color: #da1e33;
}

/* ========== Notebook/narrow screen: fixed tables switch to horizontal scroll ========== */
@media (max-width: 1400px) {
    /* Enable horizontal scroll, inertia scrolling, bottom space for scrollbar */
    .table-responsive {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        margin: 8px 0;
        padding-bottom: 4px;
    }

}

/* Phone/tablet portrait adaptation */
@media (max-width: 768px) {
    /* Horizontal scroll container: enable iOS inertia scroll, bottom space for scrollbar */
    .table-responsive {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        margin: 8px 0;
        padding-bottom: 4px;
    }

    /* Reduce table font size and padding; keep cells no-wrap, scroll horizontally on overflow */
    .gy {
        margin: 8px auto;
    }
    .gy th {
        font-size: 0.85em;
        padding: 8px 8px;
    }
    .gy td {
        font-size: 0.82em;
        padding: 6px 8px;
    }

    /* Toolbar: remove desktop negative margin offset, switch to vertical stacked full width */
    .modern-table-toolbar {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
        margin-top: 0;
        margin-bottom: 8px;
    }
    .modern-search {
        width: 100%;
    }
    .modern-search input {
        width: 100%;
        box-sizing: border-box;
    }
    .modern-filter-btn {
        justify-content: center;
    }

    /* Pagination controls: vertically centered stacked, enlarge click area */
    .table-pagination {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
        padding: 8px 10px;
    }
    .pagination-info {
        text-align: center;
        font-size: 12px;
    }
    .pagination-controls {
        justify-content: center;
        flex-wrap: wrap;
    }
    .page-num {
        min-width: 36px;
        height: 36px;
        font-size: 14px;
    }
    .page-arrow {
        min-width: 36px;
        font-size: 16px;
        text-align: center;
    }
    .page-nav {
        padding: 6px 8px;
        font-size: 14px;
        text-align: center;
    }

    /* Table title/download link smaller font */
    .name_table {
        margin: 6px 0 2px 0;
    }
    .table-caption-link {
        font-size: 14px;
    }
    .table-caption-link .download-icon svg {
        width: 16px;
        height: 16px;
    }
}

/* Table pagination styles —— new minimalist style */
.table-pagination {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 15px;
    background: #f5f5f5;
    border-radius: 4px;
    margin-top: 10px;
}

.pagination-info {
    color: #888;
    font-size: 13px;
}

.pagination-controls {
    display: flex;
    align-items: center;
    gap: 6px;
}

/* Prev / Next text buttons */
.page-nav {
    font-size: 13px;
    color: #555;
    cursor: pointer;
    user-select: none;
    padding: 2px 4px;
}
.page-nav:hover {
    color: #222;
}
.page-nav.disabled {
    color: #bbb;
    cursor: default;
    pointer-events: none;
}

/* < > arrows */
.page-arrow {
    font-size: 14px;
    color: #555;
    cursor: pointer;
    user-select: none;
    padding: 2px 4px;
    font-family: monospace;
}
.page-arrow:hover {
    color: #222;
}
.page-arrow.disabled {
    color: #bbb;
    cursor: default;
    pointer-events: none;
}

/* Page number container */
.page-nums {
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Single page number */
.page-num {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    min-width: 28px;
    height: 28px;
    font-size: 13px;
    color: #555;
    cursor: pointer;
    user-select: none;
    border-radius: 4px;
    transition: all 0.15s ease;
}
.page-num:hover {
    color: #222;
    background: #e8e8e8;
}

/* Active page: light gray-blue box + red number */
.page-num.active {
    background: #e3edf5;
    color: #da1e33;
    font-weight: 600;
    cursor: default;
}

/* Modern table toolbar container */
.modern-table-toolbar {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
    margin-top: -40px;
}

/* Modern search box */
.modern-search {
    position: relative;
    display: inline-flex;
    align-items: center;
}
.modern-search svg {
    position: absolute;
    left: 14px;
    width: 16px;
    height: 16px;
    fill: #333;
}
.modern-search input {
    background: #e6e9ec;
    border: none;
    border-radius: 20px;
    padding: 8px 15px 8px 36px;
    font-size: 14px;
    color: #333;
    width: 260px;
    outline: none;
    transition: all 0.3s;
}
.modern-search input:focus {
    background: #dce0e5;
    box-shadow: 0 0 0 2px rgba(218, 30, 51, 0.15);
}

/* Modern filter button */
.modern-filter-btn {
    display: inline-flex;
    align-items: center;
    background: #f0f2f5;
    border: none;
    border-radius: 20px;
    padding: 8px 18px;
    font-size: 14px;
    color: #555;
    cursor: pointer;
    transition: all 0.3s;
}
.modern-filter-btn svg {
    width: 16px;
    height: 16px;
    margin-right: 6px;
    fill: #666;
}
.modern-filter-btn:hover {
    background: #e6e9ec;
    color: #333;
}
.filter-count-badge {
    background: #da1e33;
    color: white;
    border-radius: 10px;
    padding: 1px 6px;
    font-size: 12px;
    margin-left: 6px;
    display: none;
}

/* Table title and download link styles */
.name_table {
    margin: 10px 0 2px 0;
    text-align: left;
}

.table-caption-link {
    display: inline-flex;
    align-items: center;
    color: #333333;
    text-decoration: none;
    font-size: 16px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.table-caption-link .download-text {
    text-decoration: underline;
    text-decoration-color: #cccccc;
    text-underline-offset: 3px;
    text-decoration-thickness: 1px;
}

.table-caption-link:hover .download-text {
    color: #da1e33;
    text-decoration-color: #da1e33;
}

.table-caption-link .download-icon {
    margin-right: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.table-caption-link .download-icon svg {
    fill: #da1e33;
    width: 20px;
    height: 20px;
}

/* Statistics grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin: 20px 0;
}

/* Print styles */
@media print {
    .toc-sidebar,
    #goTopBtn {
        display: none !important;
    }

    .main-content {
        margin: 0 !important;
        padding: 20px !important;
    }

    .image-viewer img {
        max-width: 100% !important;
        max-height: none !important;
        page-break-inside: avoid;
    }
}

/* Highlight untranslated Chinese text in report */
.untranslated-highlight {
    background-color: #ffeb3b;
    color: #000;
    padding: 0 2px;
    border-radius: 2px;
    border: 1px solid #f44336;
    cursor: help;
}

.blur-content {
    filter: blur(5px);
    user-select: none;
    pointer-events: none;
}