        /* LaTeX-inspired Scientific Design */
        @import url('https://fonts.googleapis.com/css2?family=Computer+Modern&display=swap');

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

        body {
            font-family: 'Computer Modern', 'Latin Modern Roman', 'CMU Serif', Georgia, 'Times New Roman', serif;
            background: #f5f1e8;
            background-image:
                linear-gradient(90deg, #e8e2d5 1px, transparent 1px),
                linear-gradient(#e8e2d5 1px, transparent 1px);
            background-size: 20px 20px;
            padding: 40px 20px;
            color: #1a1a1a;
            line-height: 1.6;
        }

        .container {
            max-width: 1800px;
            margin: 0 auto;
            background: #fffef8;
            border: 2px solid #2c2c2c;
            box-shadow: 8px 8px 0 rgba(0, 0, 0, 0.1);
            padding: 40px;
        }

        /* Document Title Section */
        h1 {
            font-size: 2.5em;
            font-weight: normal;
            text-align: center;
            margin-bottom: 15px;
            letter-spacing: 0.5px;
            border-bottom: 2px solid #2c2c2c;
            padding-bottom: 20px;
            text-transform: uppercase;
            font-variant: small-caps;
        }

        .subtitle {
            text-align: center;
            font-style: italic;
            margin-bottom: 40px;
            color: #4a4a4a;
            font-size: 1.1em;
        }

        /* Theorem-style boxes */
        .theorem-box {
            border: 2px solid #2c2c2c;
            padding: 20px;
            margin: 30px 0;
            background: #faf8f0;
            position: relative;
        }

        .theorem-box::before {
            content: attr(data-title);
            position: absolute;
            top: -12px;
            left: 20px;
            background: #fffef8;
            padding: 0 10px;
            font-weight: bold;
            font-style: italic;
            font-size: 0.9em;
        }

        .controls {
            display: flex;
            gap: 20px;
            margin-bottom: 30px;
            flex-wrap: wrap;
            justify-content: center;
        }

        button {
            padding: 12px 30px;
            background: #2c2c2c;
            color: #fffef8;
            border: 2px solid #2c2c2c;
            cursor: pointer;
            font-size: 14px;
            font-weight: bold;
            font-family: 'Computer Modern', 'Latin Modern Roman', serif;
            text-transform: uppercase;
            letter-spacing: 1px;
            transition: all 0.2s;
        }

        button:hover {
            background: #fffef8;
            color: #2c2c2c;
        }

        button:disabled {
            background: #999;
            border-color: #999;
            cursor: not-allowed;
            color: #fffef8;
        }

        .column-toggle {
            position: relative;
        }

        .column-toggle-btn {
            padding: 12px 20px;
            background: #fffef8;
            color: #2c2c2c;
            border: 2px solid #2c2c2c;
            cursor: pointer;
            font-size: 13px;
        }

        .column-toggle-menu {
            display: none;
            position: absolute;
            top: 100%;
            right: 0;
            background: #fffef8;
            border: 2px solid #2c2c2c;
            padding: 15px;
            margin-top: 5px;
            z-index: 1000;
            min-width: 200px;
        }

        .column-toggle-menu.show {
            display: block;
        }

        .column-option {
            display: flex;
            align-items: center;
            gap: 8px;
            padding: 5px 0;
            font-size: 13px;
        }

        .column-option input[type="checkbox"] {
            width: 16px;
            height: 16px;
        }

        th[data-col] {
            cursor: pointer;
            user-select: none;
            position: relative;
        }

        th[data-col]:hover {
            background: #e8e2d5;
        }

        th[data-col].sorted-asc::after {
            content: ' ▲';
            font-size: 10px;
        }

        th[data-col].sorted-desc::after {
            content: ' ▼';
            font-size: 10px;
        }

        .search-box {
            flex: 1;
            min-width: 300px;
        }

        input[type="text"] {
            width: 100%;
            padding: 12px;
            border: 2px solid #2c2c2c;
            background: #fffef8;
            font-size: 14px;
            font-family: 'Computer Modern', Georgia, serif;
        }

        input[type="text"]:focus {
            outline: none;
            box-shadow: 0 0 0 3px rgba(44, 44, 44, 0.1);
        }

        .progress {
            display: none;
            margin-bottom: 30px;
        }

        .progress-bar {
            width: 100%;
            height: 12px;
            background: #e8e2d5;
            border: 2px solid #2c2c2c;
            overflow: hidden;
        }

        .progress-fill {
            height: 100%;
            background: #2c2c2c;
            transition: width 1.5s ease-in-out;
        }

        .progress-text {
            margin-top: 12px;
            font-style: italic;
            text-align: center;
            font-size: 14px;
        }

        /* Definition boxes for stats */
        .summary {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
            gap: 20px;
            margin-bottom: 40px;
        }

        .stat-card {
            border: 2px solid #2c2c2c;
            padding: 20px;
            background: #faf8f0;
            position: relative;
        }

        .stat-card::before {
            content: '□';
            position: absolute;
            top: -12px;
            left: 10px;
            background: #fffef8;
            padding: 0 5px;
            font-size: 0.8em;
        }

        .stat-card.success::before {
            content: '✓';
        }

        .stat-card.warning::before {
            content: '⚠';
        }

        .stat-card.error::before {
            content: '✗';
        }

        .stat-label {
            font-variant: small-caps;
            font-size: 13px;
            margin-bottom: 8px;
            letter-spacing: 0.5px;
            text-transform: lowercase;
        }

        .stat-value {
            font-size: 32px;
            font-weight: bold;
            font-family: 'Computer Modern', 'CMU Serif', serif;
        }

        /* Table wrapper */
        .table-wrapper {
            width: 100%;
            margin-bottom: 30px;
            background: #fffef8;
        }

        /* Academic table styling */
        table {
            width: 100%;
            border-collapse: collapse;
            border-top: 3px double #2c2c2c;
            border-bottom: 3px double #2c2c2c;
            table-layout: fixed;
        }

        thead {
            border-bottom: 2px solid #2c2c2c;
        }

        th {
            padding: 12px 8px;
            text-align: left;
            font-weight: bold;
            font-variant: small-caps;
            letter-spacing: 0.5px;
            background: #faf8f0;
            font-size: 13px;
        }

        td {
            padding: 10px 8px;
            border-bottom: 1px solid #d0d0d0;
            vertical-align: top;
            word-wrap: break-word;
            overflow-wrap: break-word;
            min-width: 60px;
            font-size: 13px;
        }

        tbody tr:hover {
            background: #f5f3eb;
        }

        .status-badge {
            display: inline-block;
            padding: 2px 8px;
            border: 1px solid #2c2c2c;
            font-size: 11px;
            font-weight: bold;
            font-variant: small-caps;
        }

        .status-valid {
            background: #e8f5e9;
            border-color: #2e7d32;
        }

        .status-invalid {
            background: #ffebee;
            border-color: #c62828;
        }

        .status-missing {
            background: #fff3e0;
            border-color: #e65100;
        }

        .link-detail {
            font-size: 12px;
            color: #4a4a4a;
            margin-top: 4px;
            font-style: italic;
        }

        .link-url {
            font-family: 'Courier New', monospace;
            font-size: 11px;
            color: #1a237e;
            word-break: break-all;
        }

        .error-message {
            border: 2px solid #c62828;
            background: #ffebee;
            padding: 20px;
            margin-bottom: 30px;
            font-style: italic;
        }

        .error-message::before {
            content: '⚠ Error: ';
            font-weight: bold;
            font-style: normal;
        }

        .no-results {
            text-align: center;
            padding: 60px;
            font-style: italic;
            color: #666;
        }

        /* Tab Styles - Footnote markers */
        .tabs {
            display: flex;
            gap: 5px;
            margin-bottom: 40px;
            border-bottom: 3px double #2c2c2c;
            padding-bottom: 10px;
        }

        .tab-button {
            padding: 10px 25px;
            background: none;
            color: #4a4a4a;
            border: 2px solid transparent;
            cursor: pointer;
            font-size: 14px;
            font-weight: normal;
            font-variant: small-caps;
            letter-spacing: 0.5px;
            transition: all 0.2s;
        }

        .tab-button:hover {
            color: #000;
            border-bottom-color: #2c2c2c;
        }

        .tab-button.active {
            color: #000;
            font-weight: bold;
            border: 2px solid #2c2c2c;
            background: #faf8f0;
        }

        .tab-content {
            display: none;
        }

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

        /* Analytics - Proposition boxes */
        .analytics-summary {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
            gap: 20px;
            margin-bottom: 40px;
        }

        .stat-card.blue {
            background: linear-gradient(135deg, #e8eaf6 0%, #c5cae9 100%);
            border-color: #3f51b5;
        }

        .stat-card.green {
            background: linear-gradient(135deg, #e8f5e9 0%, #c8e6c9 100%);
            border-color: #4caf50;
        }

        .stat-card.orange {
            background: linear-gradient(135deg, #fff3e0 0%, #ffe0b2 100%);
            border-color: #ff9800;
        }

        .stat-card.purple {
            background: linear-gradient(135deg, #f3e5f5 0%, #e1bee7 100%);
            border-color: #9c27b0;
        }

        .analytics-section {
            margin-bottom: 50px;
        }

        .section-title {
            font-size: 1.4em;
            font-weight: bold;
            margin-bottom: 25px;
            font-variant: small-caps;
            letter-spacing: 1px;
            border-left: 4px solid #2c2c2c;
            padding-left: 15px;
        }

        .section-title::before {
            content: '§ ';
            font-style: italic;
        }

        .analytics-table {
            width: 100%;
            border-collapse: collapse;
            border-top: 3px double #2c2c2c;
            border-bottom: 3px double #2c2c2c;
        }

        .analytics-table th {
            background: #faf8f0;
            padding: 12px;
            text-align: left;
            font-weight: bold;
            font-variant: small-caps;
            border-bottom: 2px solid #2c2c2c;
            cursor: pointer;
            user-select: none;
        }

        .analytics-table th:hover {
            background: #f0ede0;
        }

        .analytics-table td {
            padding: 10px 12px;
            border-bottom: 1px solid #d0d0d0;
        }

        .analytics-table tr:hover {
            background: #f5f3eb;
        }

        /* Corollary boxes */
        .top-performers {
            border: 2px solid #2c2c2c;
            padding: 25px;
            background: #faf8f0;
            position: relative;
            margin-top: 20px;
        }

        .top-performers::before {
            content: 'Corollary';
            position: absolute;
            top: -12px;
            left: 20px;
            background: #fffef8;
            padding: 0 10px;
            font-weight: bold;
            font-style: italic;
            font-size: 0.9em;
        }

        .top-performer-item {
            margin-bottom: 15px;
            font-size: 14px;
            padding-left: 20px;
            position: relative;
        }

        .top-performer-item::before {
            content: '•';
            position: absolute;
            left: 5px;
            font-weight: bold;
        }

        .top-performer-item:last-child {
            margin-bottom: 0;
        }

        .badge {
            display: inline-block;
            padding: 3px 10px;
            border: 1px solid #2c2c2c;
            font-size: 11px;
            font-weight: bold;
            font-variant: small-caps;
            margin-left: 8px;
            background: #fffef8;
        }

        .badge.gold {
            background: #ffd700;
            border-color: #b8860b;
        }

        .badge.silver {
            background: #c0c0c0;
            border-color: #808080;
        }

        .badge.bronze {
            background: #cd7f32;
            border-color: #8b4513;
            color: #fffef8;
        }

        .expand-btn {
            background: none;
            border: none;
            color: #1a237e;
            cursor: pointer;
            font-size: 11px;
            padding: 4px 8px;
            text-decoration: underline;
        }

        .details {
            display: none;
            margin-top: 10px;
            padding: 15px;
            border: 1px solid #d0d0d0;
            background: #f5f3eb;
            font-size: 12px;
        }

        .details.show {
            display: block;
        }

        .other-links {
            font-size: 12px;
            color: #4a4a4a;
            font-style: italic;
        }

        /* Page number footer effect */
        .container::after {
            content: '— § —';
            display: block;
            text-align: center;
            margin-top: 60px;
            padding-top: 20px;
            border-top: 1px solid #d0d0d0;
            font-style: italic;
            color: #999;
        }

        /* Publisher Insights Score Badges */
        .score-badge-high {
            background: #c6f6d5 !important;
            color: #22543d !important;
        }

        .score-badge-medium {
            background: #fef3c7 !important;
            color: #78350f !important;
        }

        .score-badge-low {
            background: #fed7d7 !important;
            color: #742a2a !important;
        }

        /* GA4 Analytics Tab Styles */
        .metric-card {
            background: #faf8f0;
            border: 2px solid #2c2c2c;
            padding: 20px;
            text-align: center;
            transition: all 0.2s;
        }

        .metric-card:hover {
            background: #fff;
            box-shadow: 4px 4px 0 rgba(0, 0, 0, 0.1);
        }

        .metric-label {
            font-size: 12px;
            color: #718096;
            margin-bottom: 8px;
            text-transform: uppercase;
            letter-spacing: 1px;
            font-weight: 600;
        }

        .metric-value {
            font-size: 28px;
            font-weight: bold;
            color: #1a202c;
        }
