html,
body {
    height: 100%;
    overflow-x: hidden;
}

body {
    display: flex;
    flex-direction: column;
}

code,
kbd,
pre,
samp {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, Liberation Mono, Courier New, monospace;
    font-size: 1em;
}

header {
    border-bottom: 1px solid rgba(243, 244, 246, 0.5);
    background-color: rgb(250 251 252);
}

md-block:not([rendered]) {
    display: none;
}

md-block {
    display: block; 
    line-height: 1.7;
    color: #212529; 
}

md-block p {
    font-size: 1.05rem; 
    margin-bottom: 1.25rem; 
    text-align: justify; 
    hyphens: auto; 
}

md-block h1,
md-block h2,
md-block h3 {
    font-weight: 600; 
    color: #1a1a1a;
    margin-top: 2rem;
    margin-bottom: 1rem;
    line-height: 1.3;
    border-bottom: 1px solid #dee2e6; 
    padding-bottom: 0.5rem;
}

md-block h1 { font-size: 1.8rem; }
md-block h2 { font-size: 1.5rem; }
md-block h3 { font-size: 1.25rem; }

md-block a {
    color: #0056b3; 
    text-decoration: none; 
    border-bottom: 1px dotted #0056b3; 
    transition: color 0.2s ease, border-bottom-color 0.2s ease;
}

md-block a:hover,
md-block a:focus {
    color: #003d80;
    border-bottom: 1px solid #003d80; 
}

md-block ul,
md-block ol {
    margin-left: 1.5rem;
    margin-bottom: 1.25rem;
    font-size: 1.05rem;
}

md-block li {
    margin-bottom: 0.5rem; 
}

md-block li::marker {
    color: #555; 
}

md-block blockquote {
    font-family: "Georgia", "Times New Roman", Times, serif;
    font-style: italic;
    color: #495057;
    border-left: 4px solid #ced4da; 
    padding: 0.75rem 1.25rem;
    margin: 1.5rem 0;
    background-color: #f8f9fa; 
}

md-block blockquote p {
    margin-bottom: 0; 
}

md-block strong,
md-block b {
    font-weight: 600; 
}

md-block em,
md-block i {

}

md-block code {
    font-family: "SFMono-Regular", "Menlo", "Monaco", "Consolas", "Liberation Mono", "Courier New", monospace;
    font-size: 0.9em;
    background-color: #e9ecef;
    padding: 0.2em 0.4em;
    border-radius: 3px;
    color: #333;
}

#expressionChart {
    width: 100% !important; 
}

  ul.features-list {
    list-style: none;        
    padding-left: 0;         
    margin-top: 1rem;
  }
  ul.features-list li {
    position: relative;
    padding-left: 2rem;      
    margin-bottom: 1rem;     
  }
  ul.features-list li::before {

    content: "🧬";              
    position: absolute;
    left: 0;
    top: 0;
    font-size: 1.2rem;
    color: var(--bs-primary);  
  }

  ul.features-list li strong {
    color: var(--bs-primary); 
  }

section.full-screen-section-details {
    width: 100%;
    height: 100vh;
    display: flex;
    flex-direction: column;
}

#searchResults {
    overflow-y: hidden;
}

.searchResultsTextarea {
    display: none;
}

#jsoncrackEmbed {
    flex: 1;
    order: 2;
    border: none;
    padding: 15px;
}

#details_schema {
    position: relative;
    z-index: 1;
}

.network-loader-overlay {
    position: absolute; 
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 255, 255, 0.85); 
    z-index: 9999; 
    display: none; 
    justify-content: center; 
    align-items: center;     
    text-align: center;

}

.network-loader-overlay .loader-content {

    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    padding: 20px;
    background-color: #f8f9fa; 
    border-radius: 5px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.network-loader-overlay p {
    margin-top: 10px;
    font-weight: bold;
    color: #333;
}

.loader {
    border: 6px solid #f3f3f3; 
    border-top: 6px solid #3498db; 
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite;
    margin: 0 auto; 
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.network-controls-disabled .form-control,
.network-controls-disabled .btn {
    pointer-events: none !important;
    opacity: 0.65 !important;
}

.navbar {
    font-family: "Courier New", Courier, monospace;
}

#introduction {
    position: relative;
    overflow: hidden;
}

#stats {
    font-family: "Courier New", Courier, monospace;
    color: #000;
    padding: 10px;
    font-size: 16px;
    margin-bottom: 20px;
}

.card-body {
    color: #000;
}

#string_canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
}

#introduction .container {
    position: relative;
    z-index: 1;
}

.loading-bar {
    display: none; 
    position: fixed; 
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    flex-direction: column; 
    justify-content: center; 
    align-items: center; 
    background-color: rgba(0, 0, 0, 0.5); 
    z-index: 9999; 
    text-align: center; 
}

.loading-bar img {
    width: 100px; 
    height: auto; 
}

.loading-text {
    color: #fff; 
    font-size: 16px; 
    margin: 0; 
    animation: fadeInOut 3s ease-in-out infinite;
}
@keyframes fadeInOut {
    0%,
    100% {
        opacity: 0;
    }
    50% {
        opacity: 1;
    }
}
.github-corner {
    fill: #151513;
    color: #fff;
    position: absolute;
    top: 0;
    border: 0;
    right: 0;
    z-index: 1000;
}
.github-corner:hover .octo-arm {
    animation: octocat-wave 560ms ease-in-out;
}
@keyframes octocat-wave {
    0%,
    100% {
        transform: rotate(0);
    }
    20%,
    60% {
        transform: rotate(-25deg);
    }
    40%,
    80% {
        transform: rotate(10deg);
    }
}
@media (max-width: 500px) {
    .github-corner:hover .octo-arm {
        animation: none;
    }
    .github-corner .octo-arm {
        animation: octocat-wave 560ms ease-in-out;
    }
}

@media (max-width: 500px) {
    .github-corner:hover .octo-arm {
        animation: none;
    }

    .github-corner .octo-arm {
        animation: octocat-wave 560ms ease-in-out;
    }
}
.select2-results__option span {
    display: inline-block; 
    max-width: calc(100% - 25px); 
    white-space: nowrap; 
    overflow: hidden; 
    text-overflow: ellipsis; 
    vertical-align: top; 
}

.main {
    flex: 1 0 auto;
    scroll-behavior: smooth;
}

.full-screen-section {
    position: relative;
}

.card-stats {
    font-size: 9px;
    float: right;
}

.footer {
    flex-shrink: 0;
    border-top: 1px solid rgba(243, 244, 246, 0.5);
    background-color: rgb(250 251 252);
}

.shadow-3xl {
    --tw-shadow: 7px 7px 15px 0 #000;
    --tw-shadow-colored: 7px 7px 15px 0 var(--tw-shadow-color);
    box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);
}
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

.heartbeat-line {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    opacity: 0.1;
}

.heartbeat-line svg {
    width: 100%;
    height: 100%;
}

.heartbeat-line path {
    stroke-dasharray: 1000;
    stroke-dashoffset: 1000;
    animation: heartbeat 500s linear 1;
}

#searchDescription {
    font-size: 12px;
    color: #6b7280;
    text-align: right;
}
.dt-buttons {
    margin-bottom: 15px;
}

@keyframes heartbeat {
    to {
        stroke-dashoffset: 0;
    }
}

.popover-explore-details {
    max-height: 250px;
    overflow-y: auto;
    margin: 0;
    padding: 0;
}

.popover-explore-details ul {
    list-style-type: none;
    margin: 0;
    padding: 0;
    width: 100%;
}

.popover-explore-details li {
    padding: 8px 12px; 
    border-bottom: 1px solid #e0e0e0; 
    display: flex;
    flex-direction: column;
    width: 100%;
    margin: 0;
}

.popover-explore-details li:last-child {
    border-bottom: none;
}

.popover-explore-details li:hover {
    background-color: #f9f9f9;
}
.watermarked-text {
    position: relative;
    padding: 20px;
    overflow: hidden;
}

.watermarked-text::before {
    content: "LLM GENERATED";
    position: absolute;
    top: 30px;
    right: 15px;
    background-color: rgb(255 0 0 / 75%);
    color: #6cff00;
    padding: 5px;
    font-size: 0.8rem;
    z-index: 1;
    pointer-events: none;
    border-radius: 3px;
    font-weight: bold;
}

.watermarked-text.blurred {
    filter: blur(5px);
    transition: filter 0.3s ease; /* Adds a smooth blur/un-blur effect */
}

.badge {
    white-space: nowrap;
}

#wordCloudCanvas {
    max-width: 800px;
    max-height: 400px;
    width: 100%;
    height: 400px;
}

.word-cloud-wrapper {
    width: 100%;
    max-width: 600px;
    height: auto;
}

@media (max-width: 576px) {
    .word-cloud-wrapper {
        max-width: 100%;
    }
}

.formatted-sequence {
    font-family: monospace;
    background-color: #f8f9fa; 
    padding: 10px;
    border: 1px solid #ccc;
    white-space: pre-wrap; 
}

[id^="hover-info-"] {
    display: none; 
}
.network-legend .legend-swatch {
    display: inline-block;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    margin-right: 5px;
    vertical-align: middle;
    border: 1px solid #777;
}
.network-legend .query-node-swatch { background-color: #007bff; border-color: #0056b3; }
.network-legend .csi-high-swatch { background-color: #d62728;  }
.network-legend .csi-mid-swatch { background-color: #ff7f00;   } 
.network-legend .csi-low-swatch { background-color: #1f77b4;   }
.network-legend .csi-na-swatch { background-color: #dfdfdf;   }

.network-legend .legend-edge {
    display: inline-block;
    width: 20px;
    height: 2px; 
    margin-right: 5px;
    vertical-align: middle;
    margin-bottom: 3px; 
}
.network-legend .ppi-edge-swatch { background-color: #555; }
.network-legend .pathway-edge-swatch {
    background: repeating-linear-gradient(
        to right,
        #bababa,
        #bababa 4px,
        transparent 4px,
        transparent 8px
    ); 
    height: 1.5px; 
}
.network-legend ul li {
    padding-bottom: 2px;
}
.network-legend .legend-label {
    font-weight: 500;
}

.legend-swatch-modal {
    display: inline-block;
    width: 12px;
    height: 12px;
    border-radius: 3px; 
    margin-right: 5px;
    vertical-align: middle;
    border: 1px solid #999;
}
.legend-edge-modal {
    display: inline-block;
    width: 20px;
    height: 2px; 
    margin-right: 5px;
    vertical-align: middle;
    margin-bottom: 3px; 
}
.ppi-edge-swatch-modal { background-color: #555; }
.pathway-edge-swatch-modal {
    background: repeating-linear-gradient(
        to right,
        #bababa,
        #bababa 4px,
        transparent 4px,
        transparent 8px
    );
    height: 1.5px;
}
.modal-body ul ul { 
    padding-left: 25px;
    list-style-type: disc; 
}
.modal-body ul ul li {
    margin-bottom: 2px;
}
.modal-body .card-header {
    background-color: #f8f9fa; 
    font-weight: 500;
}
.modal-body .list-group-item {
    border-left: 0;
    border-right: 0;
}
.modal-body .list-group-item:first-child {
    border-top: 0;
}
.modal-body .list-group-item:last-child {
    border-bottom: 0;
}
.badge { 
    font-size: 0.9em;
    padding: 0.4em 0.6em;
}
.network-control-label {
    display: block; 
    min-height: 45px;

    margin-bottom: .5rem; 
}

#llm-chat-toggle {
    position: fixed;
    bottom: 50px;
    right: 25px;
    width: 60px;
    height: 60px;
    font-size: 24px;
    z-index: 1040;
    box-shadow: 0 4px 12px rgba(0,0,0,0.25);
    transition: transform 0.2s ease-in-out;
}
#llm-chat-toggle:hover {
    transform: scale(1.1);
}

.chat-messages-container {
    height: 450px;
    overflow-y: auto;
    border: 1px solid #e9ecef;
    padding: 15px;
    border-radius: 8px;
    background-color: #f8f9fa;
    display: flex;
    flex-direction: column;
}

.chat-message {
    margin-bottom: 15px;
    display: flex;
    flex-direction: column;
    max-width: 90%;
}
.chat-message .message-bubble {
    padding: 12px 18px;
    border-radius: 20px;
    word-wrap: break-word;
    position: relative;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}
.chat-message .copy-btn {
    position: absolute;
    top: 5px;
    right: 8px;
    font-size: 0.8em;
    padding: 2px 6px;
    border-radius: 4px;
    background-color: rgba(0,0,0,0.1);
    color: #fff;
    border: none;
    opacity: 0;
    transition: opacity 0.2s;
    cursor: pointer;
}
.chat-message .message-bubble:hover .copy-btn {
    opacity: 1;
}
.chat-message .copy-btn:hover {
    background-color: rgba(0,0,0,0.3);
}

.chat-message.user { align-self: flex-end; }
.chat-message.user .message-bubble {

    background-color: #e9ecef;
    color: #212529;

    border-radius: 20px;
    border-bottom-right-radius: 5px;

    box-shadow: 0 1px 3px rgba(0,0,0,0.08);

    animation: fadeIn 0.3s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
.chat-message.user .message-role { align-self: flex-end; margin-right: 5px; }

.chat-message.assistant { align-self: flex-start; }
.chat-message.assistant .message-bubble {
    background-color: #e9ecef;
    color: #212529;
    border-bottom-left-radius: 5px;
}
.chat-message.assistant .message-role { align-self: flex-start; margin-left: 5px; }
.chat-message.assistant .message-bubble md-block > *:first-child { margin-top: 0; }
.chat-message.assistant .message-bubble md-block > *:last-child { margin-bottom: 0; }

.chat-message .message-role {
    font-size: 0.8rem;
    font-weight: bold;
    color: #6c757d;
    margin-bottom: 4px;
}

.chat-input-area #chat-input {
    resize: none;
    transition: height 0.2s;
    box-shadow: none !important;
}

#suggested-questions-container {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.suggested-question-btn {
    font-size: 0.85rem;
    padding: 5px 12px;
    border-radius: 15px;
    background-color: #f1f3f5;
    border: 1px solid #dee2e6;
    cursor: pointer;
    transition: all 0.2s;
}
.suggested-question-btn:hover {
    background-color: #e9ecef;
    border-color: #ced4da;
    transform: translateY(-1px);
}

#chat-toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1055; 
}

.admin-banner {

    position: fixed; 
    bottom: 0;       
    right: 0;         
    width: 25%;     
    min-width: 250px; 
    z-index: 9999;   
    padding: 8px 15px;
    box-sizing: border-box; 

    background-color: #2c3e50; 
    color: #ecf0f1;           
    border-top: 2px solid #e74c3c; 
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.2); 

    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    font-size: 14px;
    font-weight: 600;
    text-align: center;
    letter-spacing: 0.5px;

    transform: translateY(100%); 
    animation: slide-up 0.5s ease-out forwards;
    animation-delay: 0.2s; 
}

.admin-banner a {
    color: #3498db; 
    text-decoration: none;
    font-weight: 700;
    margin-left: 10px;
    border-bottom: 1px dotted #3498db;
    transition: color 0.2s ease, border-bottom-color 0.2s ease;
}

.admin-banner a:hover {
    color: #5dade2;
    border-bottom-color: #5dade2;
}

@keyframes slide-up {
    from {
        transform: translateY(100%);
    }
    to {
        transform: translateY(0);
    }
}

.navbar-light .navbar-nav .nav-item.dropdown.active > .nav-link {
    color: rgba(0, 0, 0, 0.9);
    font-weight: 600; /* Makes it slightly bolder */
};