/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-bg: #f5f0ff;      /* light purple background */
    --primary-accent: #7b5cff;  /* main purple */
    --primary-accent-dark: #5a3fd6;
    --secondary-accent: #e0e0f5;/* soft grey-purple */
    --text-dark: #262338;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--primary-bg);
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
header {
    background: linear-gradient(135deg, #5a3fd6 0%, #7b5cff 50%, #a08bff 100%);
    color: white;
    padding: 40px 0 20px 0;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 8px;
    font-weight: 800;
    color: #000000;
}

header .subtitle {
    font-size: 1.05rem;
    font-weight: 500;
    color: #f0f0ff;
    opacity: 1;
}

/* Top nav */
.main-nav {
    margin-top: 22px;
    display: inline-flex;
    gap: 12px;
    background: rgba(10, 10, 40, 0.22);
    padding: 6px;
    border-radius: 999px;
    border: 1px solid rgba(255,255,255,0.25);
    backdrop-filter: blur(10px);
}

.main-nav a {
    display: inline-block;
    padding: 10px 22px;          /* larger pill */
    border-radius: 999px;
    font-size: 0.95rem;          /* slightly larger text */
    font-weight: 500;
    color: #f5f0ff;
    text-decoration: none;
    border: 1px solid transparent;
    transition: 
        background-color 0.2s ease,
        color 0.2s ease,
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        transform 0.1s ease;
}

/* NO underlines ever */
.main-nav a,
.main-nav a:hover,
.main-nav a:focus,
.main-nav a:active,
.main-nav a:visited {
    text-decoration: none !important;
}



.main-nav a:hover {
    background-color: rgba(255,255,255,0.15);
    border-color: rgba(255,255,255,0.4);
    box-shadow: 0 2px 8px rgba(0,0,0,0.25);
    transform: translateY(-1px);
}

.main-nav a.active {
    background-color: #ffffff;
    color: var(--primary-accent-dark);
    border-color: rgba(255,255,255,0.7);
    box-shadow: 0 3px 10px rgba(0,0,0,0.25);
}



/* Main Content */
main {
    padding: 40px 0;
}

section {
    background: #ffffff;
    border-radius: 14px;
    padding: 32px;
    margin-bottom: 28px;
    box-shadow: 0 2px 14px rgba(0,0,0,0.06);
}

h2 {
    font-size: 1.8rem;
    color: var(--primary-accent-dark);
    margin-bottom: 18px;
    padding-bottom: 8px;
    border-bottom: 3px solid #c7b5ff;
    display: inline-block;
}

h3 {
    font-size: 1.3rem;
    color: #16213e;
    margin: 25px 0 15px 0;
}

p {
    margin-bottom: 15px;
    color: #555;
}

a {
    color: #e94560;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

/* Motivation Grid */
.motivation-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.motivation-card {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 25px;
    border-left: 4px solid #e94560;
}

.motivation-card h3 {
    margin-top: 0;
    color: #e94560;
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin: 30px 0;
}

.stat-card {
    background: linear-gradient(135deg, #1a1a2e, #16213e);
    color: white;
    padding: 30px;
    border-radius: 8px;
    text-align: center;
}

.stat-number {
    display: block;
    font-size: 2.5rem;
    font-weight: 700;
    color: #e94560;
}

.stat-label {
    display: block;
    font-size: 0.9rem;
    opacity: 0.9;
    margin-top: 5px;
}

/* Entity Tags */
.entity-types {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 15px;
}

.entity-tag {
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
    color: white;
}

.entity-tag.drug { background: #e94560; }
.entity-tag.gene { background: #4ecdc4; }
.entity-tag.disease { background: #ff6b6b; }
.entity-tag.anatomy { background: #95e1d3; color: #333; }
.entity-tag.pathway { background: #a66cff; }
.entity-tag.phenotype { background: #ffd93d; color: #333; }
.entity-tag.bp { background: #6bcb77; }
.entity-tag.mf { background: #4d96ff; }
.entity-tag.cc { background: #ff8e71; }
.entity-tag.exposure { background: #b4b4b4; }

/* Pathway Visualization container */
.pathway-container {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 48px 24px;
    margin: 30px 0;
    overflow-x: auto;
}

/* If you still use linear pathway cards on other pages */
.pathway-visualization {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    flex-wrap: nowrap;
    gap: 0;
    min-width: 1200px;
}

.pathway-node {
    background: white;
    border-radius: 12px;
    padding: 20px;
    min-width: 140px;
    display: flex;               /* ADD */
    flex-direction: column;      /* ADD */
    align-items: center;         /* ADD */
    justify-content: center; 
    text-align: center;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    border: 3px solid;
    transition: transform 0.2s;
}

.pathway-node:hover {
    transform: translateY(-5px);
}

.pathway-node.drug {
    border-color: #e94560;
    background: linear-gradient(to bottom, white, #fff5f7);
}

.pathway-node.gene {
    border-color: #4ecdc4;
    background: linear-gradient(to bottom, white, #f0fffe);
}

.pathway-node.pathway {
    border-color: #a66cff;
    background: linear-gradient(to bottom, white, #f9f5ff);
}

.pathway-node.disease {
    border-color: #ff6b6b;
    background: linear-gradient(to bottom, white, #fff5f5);
}

.node-icon {
    font-size: 2.1rem;
    margin-bottom: 6px;
}

.node-name {
    font-weight: 700;
    font-size: 1.05rem;
    color: #1a1a2e;
    margin-bottom: 4px;
}

.node-meta {
    font-size: 0.75rem;
    color: #888;
}

.pathway-edge {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0 5px;
}

.edge-line {
  width: 70px;
  height: 2px;
  background: #ef4444;
  position: relative;
}

.edge-line::after {
  content: "";
  position: absolute;
  right: -6px;
  top: -4px;
  border-left: 8px solid #ef4444;
  border-top: 5px solid transparent;
  border-bottom: 5px solid transparent;
}

.edge-label {
    font-size: 0.7rem;
    color: #888;
    margin-top: 5px;
    white-space: nowrap;
}

/* Pathway Explanation */
.pathway-explanation {
    background: #f0f7ff;
    border-radius: 8px;
    padding: 25px;
    border-left: 4px solid #4d96ff;
}

.pathway-explanation ol {
    margin-left: 20px;
}

.pathway-explanation li {
    margin-bottom: 12px;
    color: #444;
}

/* Methodology */
.methodology-list {
    margin-left: 20px;
}

.methodology-list li {
    margin-bottom: 15px;
    padding-left: 10px;
}

/* Code Block */
pre {
    background: #1a1a2e;
    color: #a8dadc;
    padding: 25px;
    border-radius: 8px;
    overflow-x: auto;
    font-family: 'Monaco', 'Menlo', monospace;
    font-size: 0.9rem;
    line-height: 1.5;
}

/* Footer */
footer {
    background: #1a1a2e;
    color: white;
    padding: 30px 0;
    text-align: center;
}

footer a {
    color: #e94560;
}

/* Pathway controls dropdown + reset button */
.pathway-controls {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 18px 0 8px 0;
    flex-wrap: wrap;
}

.pathway-label {
    font-size: 1rem;
    font-weight: 500;
    color: var(--primary-accent-dark);
}

.pathway-select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    padding: 10px 42px 10px 18px;
    border-radius: 999px;
    border: 1px solid rgba(0,0,0,0.08);
    background:
        linear-gradient(135deg, #ffffff, #f5f0ff),
        url("data:image/svg+xml,%3Csvg width='14' height='9' viewBox='0 0 12 8' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%235a3fd6' stroke-width='1.6' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat, no-repeat;
    background-position: 0 0, right 14px center;
    background-size: auto, 14px 9px;
    color: var(--primary-accent-dark);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    position: relative;
    outline: none;
    transition:
        background-color 0.2s ease,
        box-shadow 0.2s ease,
        transform 0.1s ease,
        border-color 0.2s ease;
}

.pathway-select:hover {
    border-color: rgba(90,63,214,0.4);
    box-shadow: 0 3px 12px rgba(0,0,0,0.12);
    transform: translateY(-1px);
}

.pathway-select:focus {
    border-color: var(--primary-accent-dark);
    box-shadow: 0 0 0 2px rgba(123,92,255,0.25);
}

/* Reset button styled like nav pills */
.pathway-reset-btn {
    margin-left: 8px;
    padding: 9px 18px;
    border-radius: 999px;
    border: 1px solid rgba(255,255,255,0.8);
    background: #ffffff;
    color: var(--primary-accent-dark);
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0,0,0,0.10);
    transition:
        background-color 0.2s ease,
        color 0.2s ease,
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        transform 0.1s ease;
}

.pathway-reset-btn:hover {
    background-color: #f5f0ff;
    border-color: rgba(90,63,214,0.4);
    box-shadow: 0 3px 12px rgba(0,0,0,0.14);
    transform: translateY(-1px);
}

.pathway-reset-btn:active {
    transform: translateY(0);
    box-shadow: 0 1px 6px rgba(0,0,0,0.18);
}

/* Tooltip styling - much larger with scrolling */
.graph-tooltip {
    background: #111827;
    color: #f9fafb;
    padding: 16px 18px;
    border-radius: 10px;
    font-size: 0.85rem;
    max-width: 480px;        /* much wider */
    min-width: 320px;        /* minimum size */
    max-height: 400px;       /* height limit */
    box-shadow: 0 8px 24px rgba(0,0,0,0.4);
    z-index: 9999;
    word-wrap: break-word;
    white-space: normal;
    overflow: hidden;        /* ensure container clips scrollable content */
    border: 1px solid rgba(255,255,255,0.1);
}

.graph-tooltip .tooltip-title {
    font-weight: 700;
    font-size: 1rem;
    margin-bottom: 8px;
    color: #e5e7eb;
    padding-bottom: 6px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.graph-tooltip .tooltip-meta {
    margin-bottom: 10px;
    padding: 8px;
    background: rgba(255,255,255,0.05);
    border-radius: 6px;
}

.graph-tooltip .tooltip-meta div {
    margin-bottom: 3px;
}

.graph-tooltip .tooltip-section-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #9ca3af;
    margin: 8px 0 4px 0;
    font-weight: 600;
}

.graph-tooltip .tooltip-rel-container {
    max-height: 220px;       /* much taller scrollable area */
    overflow-y: auto;        /* scrollable! */
    padding-right: 4px;      /* room for scrollbar */
    scrollbar-width: thin;   /* Firefox */
    scrollbar-color: rgba(255,255,255,0.3) transparent;
}

.graph-tooltip .tooltip-rel-container::-webkit-scrollbar {
    width: 6px;
}

.graph-tooltip .tooltip-rel-container::-webkit-scrollbar-track {
    background: transparent;
}

.graph-tooltip .tooltip-rel-container::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.3);
    border-radius: 3px;
}

.graph-tooltip .tooltip-rel {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 6px;
    margin-bottom: 4px;
    padding: 4px 0;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.graph-tooltip .tooltip-rel:last-child {
    border-bottom: none;
}

.graph-tooltip .tooltip-rel-name {
    font-weight: 600;
    color: #e5e7eb;
    flex: 1;
    min-width: 0;           /* allow shrinking */
}

.graph-tooltip .tooltip-rel-type {
    color: #a5b4fc;
    font-size: 0.8rem;
    white-space: nowrap;
}

.graph-tooltip .tooltip-rel-edge {
    color: #fbbf24;
    font-size: 0.8rem;
    white-space: nowrap;
}

.graph-tooltip .tooltip-empty {
    color: #9ca3af;
    font-style: italic;
    padding: 12px;
    text-align: center;
}


/* Responsive */
@media (max-width: 768px) {
    header h1 {
        font-size: 1.8rem;
    }
    
    section {
        padding: 25px;
    }
    
    .pathway-visualization {
        flex-direction: column;
        min-width: auto;
    }
    
    .pathway-edge {
        transform: rotate(90deg);
        padding: 10px 0;
    }
    
    .edge-line {
        width: 40px;
    }
}


/* Ground Truth Curation / Data Pipeline */
.pipeline-card {
  background: white;
  border-radius: 20px;
  padding: 24px 28px;
  margin-top: 24px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.pipeline-super-title {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: #3b82f6;
  margin-bottom: 16px;
}

.pipeline {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.pipeline-row {
  display: flex;
  gap: 20px;
  width: 100%;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
}

.data-block {
  flex: 1;
  min-width: 260px;
  max-width: 300px;
}

.block-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-bottom: 8px;
}

.block-label.source {
  color: #ec4899;
}

.block-label.target {
  color: #8b5cf6;
}

.main-data-box {
  border-radius: 14px;
  padding: 16px 12px;
  text-align: center;
  margin-bottom: 10px;
}

.main-data-box.drugmechdb {
  background: #ec4899;
}

.main-data-box.primekg-box {
  background: #8b5cf6;
}

.data-title {
  font-size: 22px;
  font-weight: 800;
  color: white;
}

.stats-boxes {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.mini-stat-box {
  background: #fce7f3;
  border-radius: 8px;
  padding: 12px 8px;
  text-align: center;
}

.mini-stat-box.primekg {
  background: #ede9fe;
}

.mini-stat-number {
  font-size: 20px;
  font-weight: 800;
  color: #1e293b;
  margin-bottom: 2px;
}

.mini-stat-label {
  font-size: 10px;
  font-weight: 600;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.horizontal-arrow-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: 120px;
}

.label-above-arrow,
.label-below-arrow,
.filter-label {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  color: #3b82f6;
  text-align: center;
}

.arrow-horizontal,
.arrow-down {
  font-size: 56px;
  color: #1e293b;
  line-height: 1;
}

.vertical-arrow-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  margin: 8px 0;
}

.final-benchmark-wrap {
  width: 100%;
  display: flex;
  justify-content: center;
}

.final-box {
  background: #ecfdf5;
  border: 3px solid #10b981;
  border-radius: 14px;
  padding: 16px 22px;
  display: flex;
  align-items: center;
  gap: 22px;
  min-width: 340px;
}

.final-left {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: #059669;
}

.final-center {
  display: flex;
  align-items: center;
  gap: 12px;
}

.final-number {
  font-size: 48px;
  font-weight: 800;
  color: #10b981;
  line-height: 1;
}

.final-label {
  font-size: 16px;
  font-weight: 700;
  color: #065f46;
}

.final-sublabel {
  font-size: 12px;
  font-weight: 600;
  color: #059669;
}

.curation-notes {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-top: 20px;
}

.curation-note {
  background: white;
  border-radius: 14px;
  padding: 18px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
}

.curation-note h3 {
  margin-top: 0;
  margin-bottom: 8px;
}

/* Algorithm Table */
.algorithm-table-card {
  background: white;
  border: 2px solid #d7dee8;
  border-radius: 22px;
  overflow: hidden;
  box-shadow: 0 8px 28px rgba(15, 23, 42, 0.08);
  margin-top: 20px;
}

.algorithm-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}

.algorithm-table thead th {
  background: #eef4fb;
  color: #1f2937;
  font-size: 28px;
  font-weight: 900;
  text-align: left;
  padding: 16px 14px;
  border-bottom: 2px solid #d7dee8;
}

.algorithm-table tbody td {
  font-size: 24px;
  font-weight: 700;
  line-height: 1.15;
  padding: 14px;
  border-bottom: 1.5px solid #e5e7eb;
  vertical-align: middle;
}

.algorithm-table tbody tr:last-child td {
  border-bottom: none;
}

.alg-cell {
  display: flex;
  align-items: center;
  gap: 14px;
  font-weight: 800;
  color: #1f2937;
}

.swatch {
  width: 14px;
  height: 46px;
  border-radius: 999px;
  flex: 0 0 auto;
}

.alg-tag {
  display: inline-block;
  min-width: 110px;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 16px;
  font-weight: 900;
  text-align: center;
  color: #0f172a;
  background: #f8fafc;
  border: 1.5px solid #dbe4ee;
}

.alg-tag.classical { background: #edf7fc; }
.alg-tag.heuristic { background: #fff7ea; }
.alg-tag.centrality { background: #f5effc; }
.alg-tag.learned { background: #eef8ef; }
.alg-tag.llm { background: #fcf0f6; }
.alg-tag.search { background: #fceeee; }
.alg-tag.hybrid { background: #eef8ef; }

.star {
  color: #d95f5f;
  font-weight: 900;
  margin-left: 4px;
}

@media (max-width: 900px) {
  .curation-notes {
    grid-template-columns: 1fr;
  }

  .pipeline-row {
    flex-direction: column;
  }

  .horizontal-arrow-container {
    min-width: auto;
  }

  .algorithm-table thead th,
  .algorithm-table tbody td {
    font-size: 16px;
  }

  .alg-tag {
    min-width: 80px;
    font-size: 12px;
  }
}


.results-two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
  margin-top: 24px;
}

.results-card {
  background: white;
  border-radius: 18px;
  padding: 24px;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.08);
}

.results-card h3 {
  margin-top: 0;
  margin-bottom: 16px;
  font-size: 28px;
}

.phase-title {
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  margin: 18px 0 10px;
}

.phase-title.phase-1 {
  color: #f59e0b;
}

.phase-title.phase-2 {
  color: #10b981;
}

.result-bar-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}

.result-label {
  min-width: 135px;
  text-align: right;
  font-size: 15px;
  font-weight: 600;
  color: #475569;
}

.result-label.best,
.result-value.best {
  color: #b91c1c;
  font-weight: 800;
}

.result-bar-track {
  flex: 1;
  height: 30px;
  background: #eef2f7;
  border-radius: 8px;
  overflow: hidden;
}

.result-bar {
  height: 100%;
  border-radius: 8px;
}

.result-bar.pink { background: #ec4899; }
.result-bar.purple { background: #a78bfa; }
.result-bar.blue { background: #4ea1cc; }
.result-bar.gold { background: #dfab4c; }
.result-bar.green { background: #69bc78; }
.result-bar.red { background: #d95f5f; }
.result-bar.yellow { background: #d8be3f; }

.result-value {
  min-width: 70px;
  font-size: 15px;
  font-weight: 700;
  color: #1e293b;
}

.results-insight-box {
  background: #f8fafc;
  border: 2px solid #e2e8f0;
  border-radius: 16px;
  padding: 22px 26px;
  margin-top: 28px;
}

.results-insight-box p {
  font-size: 18px;
  line-height: 1.6;
  color: #334155;
  margin: 0;
}

.case-study-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-top: 20px;
}

.case-study-card {
  background: white;
  border-radius: 16px;
  padding: 22px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.07);
}

.case-study-card h3 {
  margin-top: 0;
  margin-bottom: 6px;
}

.case-meta {
  color: #64748b;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 12px;
}

@media (max-width: 900px) {
  .results-two-col,
  .case-study-grid {
    grid-template-columns: 1fr;
  }

  .result-label {
    min-width: 110px;
    font-size: 13px;
  }
}



.case-study-stack {
  display: flex;
  flex-direction: column;
  gap: 28px;
  margin-top: 24px;
}

.case-card {
  background: #ffffff;
  border: 1.5px solid #c7d9f8;
  border-radius: 14px;
  padding: 16px 18px;
  width: 100%;
  box-shadow: 0 2px 16px rgba(37, 99, 235, 0.07);
}

.case-card h3 {
  font-family: 'Inter', sans-serif;
  font-size: 18px;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 10px;
  letter-spacing: -0.2px;
  line-height: 1.3;
}

.case-tag {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.18em;
  color: #2563eb;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.gt-badge {
  background: #eef4ff;
  color: #2563eb;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 9px;
  font-family: 'DM Mono', monospace;
}

.divider {
  height: 1px;
  background: #e8effc;
  margin: 8px 0;
}

.row-label {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: #94a3b8;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.row-inline {
  margin-bottom: 0;
}

.algo-name {
  color: #334155;
  font-weight: 500;
}

.int-count {
  margin-left: auto;
  font-size: 10px;
  padding: 2px 9px;
  border-radius: 4px;
  font-weight: 600;
  font-family: 'DM Mono', monospace;
}

.int-good {
  background: #dcfce7;
  color: #15803d;
}

.int-bad {
  background: #fee2e2;
  color: #b91c1c;
}

.int-partial {
  background: #fef9c3;
  color: #854d0e;
}

.algo-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 4px;
}

.algo-box {
  border: 1.5px solid #e8effc;
  border-radius: 8px;
  padding: 10px 12px;
  background: #fafcfe;
}

.algo-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.path-row {
  display: flex;
  align-items: flex-start;
  flex-wrap: nowrap;
  gap: 0;
  justify-content: center;
  overflow-x: auto;
  padding-bottom: 2px;
}

.node-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
  width: 72px;
}

.node {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border: 2.5px solid;
  background: white;
  flex-shrink: 0;
}

.node-type {
  font-family: 'DM Mono', monospace;
  font-size: 7px;
  font-weight: 500;
  letter-spacing: 0.03em;
}

.node-abbr {
  font-size: 10.5px;
  font-weight: 700;
  margin-top: 1px;
  text-align: center;
  padding: 0 2px;
  line-height: 1.1;
}

.node-name {
  font-size: 8.5px;
  color: #64748b;
  text-align: center;
  max-width: 64px;
  line-height: 1.3;
  font-weight: 400;
}

.n-drug {
  border-color: #2563eb;
}
.n-drug .node-type,
.n-drug .node-abbr {
  color: #2563eb;
}

.n-dis {
  border-color: #db2777;
}
.n-dis .node-type,
.n-dis .node-abbr {
  color: #db2777;
}

.n-prt {
  border-color: #6366f1;
}
.n-prt .node-type,
.n-prt .node-abbr {
  color: #6366f1;
}

.n-bio {
  border-color: #d97706;
}
.n-bio .node-type,
.n-bio .node-abbr {
  color: #d97706;
}

.n-hit {
  border-color: #16a34a;
  background: #f0fdf4;
}
.n-hit .node-type,
.n-hit .node-abbr {
  color: #16a34a;
}

.n-miss {
  border-color: #dc2626;
  background: #fef2f2;
}
.n-miss .node-type,
.n-miss .node-abbr {
  color: #dc2626;
}

.arrow-wrap {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  margin-top: 25px;
}

.arrow {
  width: 20px;
  height: 1.5px;
  background: #94a3b8;
  position: relative;
}

.arrow::after {
  content: '';
  position: absolute;
  right: -1px;
  top: -3.5px;
  border-left: 7px solid #94a3b8;
  border-top: 4.5px solid transparent;
  border-bottom: 4.5px solid transparent;
}

.verdict {
  margin-top: 6px;
  font-size: 10px;
  color: #64748b;
  font-style: italic;
  line-height: 1.5;
}

.v-good {
  color: #15803d;
  font-style: normal;
  font-weight: 600;
}

.v-bad {
  color: #b91c1c;
  font-style: normal;
  font-weight: 600;
}

.v-partial {
  color: #854d0e;
  font-style: normal;
  font-weight: 600;
}

@media (max-width: 900px) {
  .algo-grid {
    grid-template-columns: 1fr;
  }

  .case-card {
    padding: 14px;
  }

  .case-card h3 {
    font-size: 16px;
  }

  .node-wrap {
    width: 64px;
  }

  .node {
    width: 44px;
    height: 44px;
  }

  .node-name {
    font-size: 8px;
    max-width: 58px;
  }

  .arrow-wrap {
    margin-top: 22px;
  }

  .arrow {
    width: 16px;
  }
}
