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

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f5f5f5;
}

/* Header */
header {
    background-color: #2c3e50;
    color: white;
    padding: 2rem 1rem;
    text-align: center;
}

header h1 {
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
}

.subtitle {
    font-size: 1rem;
    opacity: 0.9;
}

/* Key Players Section */
.key-players {
    display: flex;
    justify-content: center;
    gap: 1rem;
    padding: 1.5rem 1rem;
    background: #ecf0f1;
    flex-wrap: wrap;
}

.player-card {
    background: white;
    border-radius: 8px;
    padding: 1rem;
    text-align: center;
    min-width: 220px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}

.player-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.player-card.active {
    border: 3px solid #3498db;
    background: #ebf5fb;
}

.player-card.active .player-name {
    color: #3498db;
}

.player-photo {
    width: 80px;
    height: 80px;
    margin: 0 auto 0.75rem;
    border-radius: 50%;
    background: #bdc3c7;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.player-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.player-photo img[src=""],
.player-photo img:not([src]) {
    display: none;
}

.player-photo:has(img[src=""]),
.player-photo:has(img:not([src])) {
    background: #bdc3c7;
}

.player-photo::before {
    content: "";
    font-size: 2rem;
    color: #7f8c8d;
}

.player-name {
    font-weight: 600;
    font-size: 0.95rem;
    color: #2c3e50;
    margin-bottom: 0.25rem;
}

.player-title {
    font-size: 0.8rem;
    color: #7f8c8d;
    line-height: 1.3;
}

.player-contact {
    margin-top: 0.5rem;
    padding-top: 0.5rem;
    border-top: 1px solid #ecf0f1;
    font-size: 0.7rem;
    color: #7f8c8d;
}

.player-contact a {
    display: block;
    color: #3498db;
    text-decoration: none;
    margin-bottom: 0.25rem;
    word-break: break-all;
}

.player-contact a:hover {
    text-decoration: underline;
}

.player-contact span {
    display: block;
}

/* Tab content */
.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* Highlight section for key evidence */
.highlight-section {
    background: #fef9e7 !important;
    border-left: 4px solid #f39c12;
}

.highlight-section h2 {
    color: #d68910 !important;
    border-bottom-color: #f39c12 !important;
}

/* Open NOV Cards */
.nov-cards {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.nov-card {
    background: #fdedec;
    border: 2px solid #e74c3c;
    border-radius: 8px;
    padding: 1rem 1.5rem;
    min-width: 150px;
    text-align: center;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}

.nov-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(231, 76, 60, 0.3);
}

.nov-date {
    font-size: 0.85rem;
    color: #c0392b;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.nov-title {
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 0.25rem;
}

.nov-issues {
    font-size: 1.1rem;
    font-weight: 700;
    color: #e74c3c;
}

/* Violations Table */
.violations-table-section {
    background: white;
}

.table-responsive {
    overflow-x: auto;
}

.violations-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.violations-table thead {
    background: #8e44ad;
    color: white;
}

.violations-table th {
    padding: 0.75rem 1rem;
    text-align: left;
    font-weight: 600;
}

.violations-table td {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #ddd;
    vertical-align: top;
}

.violations-table tbody tr:hover {
    background: #f8f9fa;
}

.violations-table .index-cell {
    font-weight: 700;
    color: #7f8c8d;
    text-align: center;
    width: 30px;
}

.violations-table .cited-cell {
    text-align: center;
    font-weight: 600;
    font-size: 0.8rem;
    color: #27ae60;
    width: 60px;
}

.violations-table .doc-cell {
    text-align: center;
    width: 50px;
}

.violations-table .doc-cell a {
    color: #3498db;
    text-decoration: none;
    font-weight: 500;
    font-size: 0.85rem;
}

.violations-table .doc-cell a:hover {
    text-decoration: underline;
}

.violations-table .date-cell {
    font-weight: 600;
    color: #e74c3c;
    white-space: nowrap;
    width: 70px;
}

.violations-table .issue-cell {
    font-style: italic;
    color: #7d6608;
    background: #fef9e7;
    width: 30%;
}

.violations-table .code-cell {
    font-family: monospace;
    font-size: 0.8rem;
    color: #2980b9;
    width: 20%;
}

.violations-table .code-cell a {
    color: #2980b9;
    text-decoration: none;
    transition: color 0.2s, text-decoration 0.2s;
}

.violations-table .code-cell a:hover {
    color: #1a5276;
    text-decoration: underline;
}

.violations-table .text-cell {
    color: #555;
    line-height: 1.5;
    font-size: 0.85rem;
    width: 25%;
}

.violations-table .text-cell strong {
    color: #2c3e50;
}

.violations-table .nov-separator {
    background: #2c3e50 !important;
    color: white;
    font-weight: 600;
    text-align: center;
}

.violations-table .nov-separator:hover {
    background: #2c3e50 !important;
}

.violations-table .nov-separator td {
    padding: 0.5rem 1rem;
    background: #2c3e50 !important;
}

.violations-table .nov-summary {
    background: #fdedec;
    border-top: 2px solid #e74c3c;
}

.violations-table .nov-summary .issue-cell {
    background: #fdedec;
    color: #c0392b;
    font-weight: 600;
}

/* PDF Modal */
.pdf-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 1000;
    padding: 1rem;
    box-sizing: border-box;
}

.pdf-modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.pdf-modal-content {
    background: white;
    width: 100%;
    height: 100%;
    max-width: 1200px;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.pdf-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.5rem;
    background: #2c3e50;
    color: white;
}

.pdf-modal-header h2 {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 500;
}

.close-pdf {
    background: none;
    border: none;
    color: white;
    font-size: 2rem;
    cursor: pointer;
    line-height: 1;
    padding: 0;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: background 0.2s;
}

.close-pdf:hover {
    background: rgba(255, 255, 255, 0.1);
}

.pdf-modal-body {
    flex: 1;
    overflow-y: auto;
    padding: 10px;
    background: #525659;
}

.pdf-modal-body iframe {
    width: 100%;
    height: 100%;
    border: none;
}

.pdf-modal-body canvas {
    display: block;
    margin: 0 auto;
    max-width: 100%;
}

.pdf-nav-controls {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-right: auto;
    margin-left: 15px;
}

.pdf-nav-btn {
    background: rgba(255, 255, 255, 0.15);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: 8px 15px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: background 0.2s;
}

.pdf-nav-btn:hover {
    background: rgba(255, 255, 255, 0.25);
}

#pdf-page-info {
    color: white;
    font-size: 14px;
    min-width: 100px;
    text-align: center;
}

/* Main content */
main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem;
}

section {
    background: white;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

section h2 {
    font-size: 1.3rem;
    color: #2c3e50;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #3498db;
}

.placeholder {
    color: #888;
    font-style: italic;
}

/* Timeline styles */
.timeline-entry {
    border-left: 3px solid #3498db;
    padding-left: 1rem;
    margin-bottom: 1.5rem;
}

.timeline-entry .date {
    font-weight: bold;
    color: #3498db;
    font-size: 0.9rem;
}

.timeline-entry .title {
    font-weight: bold;
    margin: 0.25rem 0;
}

.timeline-entry .description {
    color: #555;
}

/* Audio player styles */
.audio-entry {
    background: #f8f9fa;
    border-radius: 6px;
    padding: 1rem;
    margin-bottom: 1rem;
}

.audio-entry .audio-title {
    font-weight: bold;
    margin-bottom: 0.5rem;
}

.audio-entry .audio-date {
    font-size: 0.85rem;
    color: #666;
    margin-bottom: 0.5rem;
}

.audio-entry audio {
    width: 100%;
    margin-top: 0.5rem;
}

.audio-entry .transcript {
    margin-top: 1rem;
    padding: 1rem;
    background: white;
    border-radius: 4px;
    font-size: 0.9rem;
    border-left: 3px solid #e74c3c;
}

.audio-entry .transcript-label {
    font-weight: bold;
    color: #e74c3c;
    margin-bottom: 0.5rem;
}

/* Document list */
.document-list {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
}

.document-entry {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 6px;
    text-align: center;
    min-height: 60px;
}

.document-entry a {
    color: #3498db;
    text-decoration: none;
    font-weight: 500;
}

.document-entry a:hover {
    text-decoration: underline;
}

/* Footer */
footer {
    text-align: center;
    padding: 2rem 1rem;
    color: #666;
    font-size: 0.85rem;
    background: #f8f9fa;
    border-top: 1px solid #ddd;
}

.footer-content {
    max-width: 900px;
    margin: 0 auto;
}

.footer-content p {
    margin-bottom: 0.75rem;
    line-height: 1.5;
}

.footer-content a {
    color: #3498db;
    text-decoration: none;
}

.footer-content a:hover {
    text-decoration: underline;
}

.footer-content .copyright {
    margin-top: 1rem;
    font-size: 0.8rem;
    color: #999;
}

/* Contradictions Table */
.contradictions-section {
    background: #fef5f5;
}

.contradictions-section h2 {
    color: #c0392b !important;
    border-bottom-color: #e74c3c !important;
}

.contradictions-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.contradictions-table thead {
    background: #c0392b;
    color: white;
}

.contradictions-table th {
    padding: 0.75rem 1rem;
    text-align: left;
    font-weight: 600;
}

.contradictions-table th:first-child {
    text-align: center;
    width: 50px;
    min-width: 50px;
    max-width: 50px;
    padding: 0.75rem 0.25rem;
}

.contradictions-table td {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #ddd;
    vertical-align: top;
}

.contradictions-table tbody tr:hover {
    background: #fce8e8;
}

.contradictions-table .date-cell {
    font-weight: 600;
    color: #7f8c8d;
    white-space: nowrap;
    width: 80px;
}

.contradictions-table .quote-cell {
    font-style: italic;
    color: #2c3e50;
    background: #fff;
    width: 30%;
    line-height: 1.5;
}

.contradictions-table .reality-cell {
    color: #c0392b;
    font-weight: 500;
    background: #fdedec;
    width: 35%;
    line-height: 1.5;
}

.contradictions-table .code-cell {
    font-family: monospace;
    font-size: 0.8rem;
    width: 15%;
}

.contradictions-table .code-cell a {
    color: #2980b9;
    text-decoration: none;
    transition: color 0.2s, text-decoration 0.2s;
}

.contradictions-table .code-cell a:hover {
    color: #1a5276;
    text-decoration: underline;
}

.contradictions-table .audio-cell,
.self-contradictions-table .audio-cell {
    text-align: center;
    width: 50px;
    min-width: 50px;
    max-width: 50px;
    vertical-align: middle !important;
    padding: 0.5rem 0.25rem !important;
}

.contradictions-table .audio-cell button,
.contradictions-table .audio-cell .audio-duration,
.self-contradictions-table .audio-cell button,
.self-contradictions-table .audio-cell .audio-duration {
    display: block;
    margin: 0 auto;
}

.play-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 2px solid #27ae60;
    background: white;
    color: #27ae60;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.play-btn:hover {
    background: #27ae60;
    color: white;
}

.play-btn.playing {
    background: #e74c3c;
    border-color: #e74c3c;
    color: white;
}

.play-btn.playing:hover {
    background: #c0392b;
    border-color: #c0392b;
}

/* Audio duration indicator */
.audio-duration {
    display: block;
    font-size: 0.7rem;
    color: #7f8c8d;
    margin-top: 0.25rem;
    text-align: center;
}

/* Evidence highlight for linked cells */
.evidence-highlight {
    background: #d5f5e3 !important;
    animation: highlight-pulse 1s ease-in-out 3;
    box-shadow: inset 0 0 0 3px #27ae60;
    border-radius: 4px;
}

@keyframes highlight-pulse {
    0%, 100% { background: #d5f5e3; }
    50% { background: #abebc6; }
}

/* Self-Contradictions Table (Ben vs Ben) */
.self-contradictions-section {
    background: #fef5e7;
}

.self-contradictions-section h2 {
    color: #d68910 !important;
    border-bottom-color: #f39c12 !important;
}

.self-contradictions-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.self-contradictions-table thead {
    background: #d68910;
    color: white;
}

.self-contradictions-table th {
    padding: 0.75rem 1rem;
    text-align: left;
    font-weight: 600;
}

.self-contradictions-table th:nth-child(1),
.self-contradictions-table th:nth-child(3) {
    text-align: center;
    width: 50px;
    min-width: 50px;
    max-width: 50px;
    padding: 0.75rem 0.25rem;
}

.self-contradictions-table td {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #ddd;
    vertical-align: top;
}

.self-contradictions-table tbody tr:hover {
    background: #fef0db;
}

.self-contradictions-table .statement-a {
    background: #e8f8f5;
    color: #1e8449;
    font-style: italic;
    width: 35%;
    line-height: 1.5;
}

.self-contradictions-table .statement-b {
    background: #fdedec;
    color: #922b21;
    font-style: italic;
    width: 35%;
    line-height: 1.5;
}

.self-contradictions-table .date-tag {
    display: block;
    margin-top: 0.5rem;
    font-size: 0.75rem;
    font-style: normal;
    font-weight: 600;
    color: #7f8c8d;
}

.play-btn.self-contra {
    border-color: #f39c12;
    color: #f39c12;
}

.play-btn.self-contra:hover {
    background: #f39c12;
    color: white;
}

.play-btn.self-contra.playing {
    background: #e74c3c;
    border-color: #e74c3c;
    color: white;
}

/* Notes Section */
.notes-section {
    background: #eef9ff;
    margin-top: 2rem;
}

.notes-section h2 {
    color: #2980b9 !important;
    border-bottom-color: #3498db !important;
}

.notes-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.note-item {
    background: white;
    border-radius: 8px;
    border-left: 4px solid #3498db;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    overflow: hidden;
}

.note-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem;
    background: #d6eaf8;
    font-weight: 600;
    color: #2471a3;
}

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

.note-title {
    font-size: 1.1rem;
}

.note-content {
    padding: 1rem;
}

.note-content p {
    margin-bottom: 0.75rem;
    line-height: 1.6;
}

.note-content ul {
    margin: 0.5rem 0 0 1.5rem;
}

.note-content li {
    margin-bottom: 0.25rem;
}

.note-content a {
    color: #2980b9;
    text-decoration: none;
    font-weight: 500;
}

.note-content a:hover {
    text-decoration: underline;
}

.note-action {
    background: #fef9e7;
    padding: 0.75rem;
    border-radius: 4px;
    border-left: 3px solid #f1c40f;
}

/* Tara Thornton Section */
.tara-contradiction-section {
    background: #fdf2e9;
}

.tara-contradiction-section h2 {
    color: #d35400 !important;
    border-bottom-color: #e67e22 !important;
}

.contradiction-highlight {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin: 2rem 0;
    flex-wrap: wrap;
    justify-content: center;
}

.contradiction-box {
    flex: 1;
    min-width: 280px;
    max-width: 400px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.contradiction-box .box-header {
    padding: 0.75rem 1rem;
    font-weight: 600;
    color: white;
}

.contradiction-box .box-content {
    padding: 1rem;
    background: white;
}

.contradiction-box .box-content p {
    margin: 0 0 0.5rem 0;
    font-style: italic;
    color: #2c3e50;
}

.chris-says .box-header {
    background: #34495e;
}

.tara-admits .box-header {
    background: #e67e22;
}

.contradiction-arrow {
    font-size: 1.5rem;
    font-weight: 700;
    color: #e74c3c;
}

.play-btn.tara-play {
    border-color: #e67e22;
    color: #e67e22;
    margin: 0 auto;
}

.play-btn.tara-play:hover {
    background: #e67e22;
    color: white;
}

/* Center Tara audio button and duration */
.tara-admits .box-content {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.tara-admits .box-content p {
    text-align: center;
    margin-bottom: 0.75rem;
}

.listen-label {
    margin-left: 0.5rem;
    font-size: 0.85rem;
    color: #7f8c8d;
}

.tara-summary {
    background: white;
    border-radius: 8px;
    padding: 1.5rem;
    margin-top: 1.5rem;
    border-left: 4px solid #e67e22;
}

.tara-summary h3 {
    margin: 0 0 1rem 0;
    color: #d35400;
}

.tara-summary ul {
    margin: 0;
    padding-left: 1.25rem;
}

.tara-summary li {
    margin-bottom: 0.75rem;
    line-height: 1.5;
}

.tara-summary li:last-child {
    margin-bottom: 0;
}

/* Documentation Requests Table (Chris Balster) */
.documentation-requests-section {
    background: #f8f9fa;
}

.documentation-requests-section h2 {
    color: #2c3e50 !important;
    border-bottom-color: #34495e !important;
}

.requests-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85rem;
}

.requests-table thead {
    background: #34495e;
    color: white;
}

.requests-table th {
    padding: 0.75rem 1rem;
    text-align: left;
    font-weight: 600;
}

.requests-table td {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #ddd;
    vertical-align: top;
}

.requests-table tbody tr:hover {
    background: #ecf0f1;
}

.requests-table .category-header {
    background: #2c3e50 !important;
    color: white;
    font-weight: 600;
}

.requests-table .category-header td {
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
}

.requests-table .category-header:hover {
    background: #2c3e50 !important;
}

.requests-table .status-none {
    background: #e74c3c;
    color: white;
    font-weight: 600;
    font-size: 0.75rem;
    text-align: center;
    white-space: nowrap;
    width: 90px;
}

.requests-table .status-deflected {
    background: #e67e22;
    color: white;
    font-weight: 600;
    font-size: 0.75rem;
    text-align: center;
    white-space: nowrap;
    width: 90px;
}

.requests-table .status-partial {
    background: #f39c12;
    color: white;
    font-weight: 600;
    font-size: 0.75rem;
    text-align: center;
    white-space: nowrap;
    width: 90px;
}

.requests-table .status-request {
    background: #3498db;
    color: white;
    font-weight: 600;
    font-size: 0.75rem;
    text-align: center;
    white-space: nowrap;
    width: 90px;
}

.requests-table .evidence-cell {
    font-size: 0.8rem;
    width: 150px;
}

.requests-table .evidence-cell a {
    color: #27ae60;
    text-decoration: none;
    font-weight: 500;
    display: inline-block;
    padding: 0.25rem 0.5rem;
    background: #e8f8f5;
    border-radius: 4px;
    border: 1px solid #27ae60;
    transition: all 0.2s;
}

.requests-table .evidence-cell a:hover {
    background: #27ae60;
    color: white;
}

/* Summary Stats */
.summary-stats {
    margin-top: 2rem;
    padding: 1.5rem;
    background: white;
    border-radius: 8px;
    border: 2px solid #34495e;
}

.summary-stats h3 {
    margin: 0 0 1rem 0;
    color: #2c3e50;
    font-size: 1.1rem;
}

.stats-grid {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.stat-box {
    flex: 1;
    min-width: 100px;
    padding: 1rem;
    background: #ecf0f1;
    border-radius: 8px;
    text-align: center;
}

.stat-box .stat-number {
    display: block;
    font-size: 2rem;
    font-weight: 700;
    color: #2c3e50;
}

.stat-box .stat-label {
    display: block;
    font-size: 0.75rem;
    color: #7f8c8d;
    margin-top: 0.25rem;
}

.stat-box.stat-bad {
    background: #fdedec;
    border: 2px solid #e74c3c;
}

.stat-box.stat-bad .stat-number {
    color: #e74c3c;
}

.stat-box.stat-warning {
    background: #fef5e7;
    border: 2px solid #e67e22;
}

.stat-box.stat-warning .stat-number {
    color: #e67e22;
}

.stat-box.stat-partial {
    background: #fef9e7;
    border: 2px solid #f39c12;
}

.stat-box.stat-partial .stat-number {
    color: #f39c12;
}

.stat-box.stat-good {
    background: #e8f8f5;
    border: 2px solid #27ae60;
}

.stat-box.stat-good .stat-number {
    color: #27ae60;
}

/* Export Button */
.export-btn {
    background: #27ae60;
    color: white;
    border: none;
    padding: 0.4rem 0.8rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    margin-left: 1rem;
    vertical-align: middle;
    transition: background 0.2s;
}

.export-btn:hover {
    background: #1e8449;
}

/* Evidence TOC Sidebar */
.evidence-toc {
    position: fixed;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    padding: 1rem;
    z-index: 100;
    width: 180px;
}

.toc-title {
    font-weight: 600;
    font-size: 0.8rem;
    color: #7f8c8d;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.75rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #ecf0f1;
}

.evidence-toc a {
    display: block;
    padding: 0.4rem 0;
    color: #2c3e50;
    text-decoration: none;
    font-size: 0.85rem;
    transition: color 0.2s, padding-left 0.2s;
    border-left: 2px solid transparent;
    padding-left: 0.5rem;
}

.evidence-toc a:hover {
    color: #3498db;
    border-left-color: #3498db;
    padding-left: 0.75rem;
}

.evidence-toc a.active {
    color: #3498db;
    border-left-color: #3498db;
    font-weight: 600;
    padding-left: 0.75rem;
}

/* Evidence Gallery */
.evidence-gallery {
    background: white;
}

.evidence-gallery h2 {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.gallery-page-info {
    font-size: 0.85rem;
    font-weight: normal;
    color: #7f8c8d;
}

.gallery-controls {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.gallery-page-btn {
    background: #3498db;
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.85rem;
    transition: background 0.2s;
}

.gallery-page-btn:hover {
    background: #2980b9;
}

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

.gallery-item {
    aspect-ratio: 1;
    overflow: hidden;
    border-radius: 8px;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    background: #ecf0f1;
}

.gallery-item:hover {
    transform: scale(1.03);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.gallery-item img,
.gallery-item video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Video thumbnail styling */
.video-item {
    position: relative;
}

.video-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 50px;
    height: 50px;
    background: rgba(0, 0, 0, 0.7);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 20px;
    pointer-events: none;
    transition: background 0.2s;
}

.video-item:hover .video-overlay {
    background: rgba(231, 76, 60, 0.9);
}

/* Gallery Modal */
.gallery-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    z-index: 1001;
    align-items: center;
    justify-content: center;
}

.gallery-modal.active {
    display: flex;
}

.gallery-modal-content {
    max-width: 90%;
    max-height: 90%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.gallery-modal-content img,
.gallery-modal-content video {
    max-width: 100%;
    max-height: 80vh;
    object-fit: contain;
    border-radius: 4px;
}

.gallery-counter {
    color: white;
    margin-top: 1rem;
    font-size: 0.9rem;
}

.gallery-close {
    position: absolute;
    top: 1rem;
    right: 1.5rem;
    background: none;
    border: none;
    color: white;
    font-size: 2.5rem;
    cursor: pointer;
    z-index: 1002;
    line-height: 1;
    padding: 0.5rem;
    transition: color 0.2s;
}

.gallery-close:hover {
    color: #e74c3c;
}

.gallery-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: white;
    font-size: 2rem;
    padding: 1rem 1.25rem;
    cursor: pointer;
    transition: background 0.2s;
    border-radius: 4px;
}

.gallery-nav:hover {
    background: rgba(255, 255, 255, 0.2);
}

.gallery-prev {
    left: 1rem;
}

.gallery-next {
    right: 1rem;
}

/* Mobile responsive */
@media (max-width: 1100px) {
    .evidence-toc {
        display: none;
    }
}

@media (max-width: 600px) {
    header h1 {
        font-size: 1.5rem;
    }

    .key-players {
        gap: 0.75rem;
        padding: 1rem 0.5rem;
    }

    .player-card {
        min-width: 130px;
        max-width: 150px;
        padding: 0.75rem;
    }

    .player-photo {
        width: 60px;
        height: 60px;
    }

    .player-name {
        font-size: 0.85rem;
    }

    .player-title {
        font-size: 0.7rem;
    }

    section {
        padding: 1rem;
    }

    section h2 {
        font-size: 1.1rem;
    }

    .pdf-modal {
        padding: 0;
    }

    .pdf-modal-content {
        border-radius: 0;
        max-width: 100%;
    }

    .pdf-modal-header {
        padding: 0.75rem 1rem;
    }

    .pdf-modal-header h2 {
        font-size: 0.85rem;
        max-width: 100px;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .pdf-nav-controls {
        gap: 5px;
        margin-left: 5px;
    }

    .pdf-nav-btn {
        padding: 6px 10px;
        font-size: 12px;
    }

    #pdf-page-info {
        font-size: 12px;
        min-width: 70px;
    }

    .pdf-modal-body {
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    /* NOV table: Show only Issue and Code Text columns on mobile */
    .violations-table {
        font-size: 0.8rem;
    }

    .violations-table th,
    .violations-table td {
        padding: 0.5rem;
    }

    /* Hide # column (1st) */
    .violations-table th:nth-child(1),
    .violations-table td:nth-child(1):not([colspan]) {
        display: none;
    }

    /* Hide Cited column (2nd) */
    .violations-table th:nth-child(2),
    .violations-table td:nth-child(2):not([colspan]) {
        display: none;
    }

    /* Hide Doc column (3rd) */
    .violations-table th:nth-child(3),
    .violations-table td:nth-child(3):not([colspan]) {
        display: none;
    }

    /* Hide Date column (4th) */
    .violations-table th:nth-child(4),
    .violations-table td:nth-child(4):not([colspan]) {
        display: none;
    }

    .violations-table .code-cell {
        white-space: normal;
        word-break: break-word;
    }

    .violations-table .issue-cell {
        width: auto;
    }

    /* Ben's table: Show only Play and Ben's Statement columns on mobile */
    .contradictions-table {
        font-size: 0.85rem;
    }

    .contradictions-table th,
    .contradictions-table td {
        padding: 0.5rem;
    }

    /* Hide Date column (2nd column) */
    .contradictions-table th:nth-child(2),
    .contradictions-table td:nth-child(2) {
        display: none;
    }

    /* Hide Reality / NOV Finding column (4th column) */
    .contradictions-table th:nth-child(4),
    .contradictions-table td:nth-child(4) {
        display: none;
    }

    /* Make Ben's Statement column take more width */
    .contradictions-table .quote-cell {
        width: auto;
        font-size: 0.9rem;
    }

    .self-contradictions-table {
        font-size: 0.8rem;
    }

    .self-contradictions-table th,
    .self-contradictions-table td {
        padding: 0.5rem;
    }

    .self-contradictions-table .statement-a,
    .self-contradictions-table .statement-b {
        width: auto;
    }

    /* Chris's table: Show only Status and Question columns on mobile */
    .requests-table {
        font-size: 0.8rem;
    }

    .requests-table th,
    .requests-table td {
        padding: 0.5rem;
    }

    /* Hide Category column (2nd column) */
    .requests-table th:nth-child(2),
    .requests-table td:nth-child(2):not([colspan]) {
        display: none;
    }

    /* Adjust category header colspan */
    .requests-table .category-header td[colspan="3"] {
        display: table-cell;
    }

    .stats-grid {
        flex-direction: column;
    }

    .stat-box {
        min-width: auto;
    }

    .stat-box .stat-number {
        font-size: 1.5rem;
    }

    .gallery-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 0.5rem;
    }

    .gallery-nav {
        font-size: 1.5rem;
        padding: 0.75rem 1rem;
    }

    .gallery-prev {
        left: 0.5rem;
    }

    .gallery-next {
        right: 0.5rem;
    }

    .document-list {
        grid-template-columns: repeat(2, 1fr);
    }
}
