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

/* Floating Disclaimer */
.floating-disclaimer {
    position: fixed;
    bottom: 5px;
    right: 5px;
    background: rgba(0, 0, 0, 0.85);
    color: white;
    padding: 7px 15px;
    font-size: clamp(0.7rem, 2vw, 0.8rem);
    border-radius: 10px;
    font-weight: 400;
    max-width: min(500px, calc(100vw - 20px));
    width: min(450px, calc(100vw - 20px));
    line-height: 1.4;
    z-index: 1000;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    opacity: 0.9;
    transition: opacity 0.3s ease;
    white-space: normal;
    word-wrap: break-word;
    overflow-wrap: break-word;
    box-sizing: border-box;
    margin-right: 2%;
}

.floating-disclaimer:hover {
    opacity: 1;
}

/* Responsive adjustments for floating disclaimer */
@media (max-width: 768px) {
    .floating-disclaimer {
        bottom: 10px;
        right: 10px;
        left: 10px;
        width: calc(100vw - 20px);
        font-size: clamp(0.65rem, 1.8vw, 0.75rem);
        padding: 8px 12px;
        box-sizing: border-box;
    }
}

@media (max-width: 480px) {
    .floating-disclaimer {
        bottom: 5px;
        right: 5px;
        left: 5px;
        width: calc(100vw - 10px);
        font-size: clamp(0.6rem, 1.5vw, 0.7rem);
        padding: 6px 10px;
        border-radius: 8px;
        box-sizing: border-box;
    }
}

@import url('https://fonts.googleapis.com/css2?family=Sora:wght@100;200;300;400;500;600;700;800&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@300;700&display=swap');

body {
    font-family: 'Sora', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: #333;
    background: white;
    min-height: 100vh;
}

/* Header Styles */
.header {
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(15px);
    box-shadow: 0 2px 30px rgba(0, 0, 0, 0.08);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    margin: 20px;
    border-radius: 25px;
}

.navbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.2rem;
    max-width: 100%;
    margin: 0;
    gap: 2rem;
    width: 100%;
}

.nav-left .logo {
    display: flex;
    align-items: center;
    flex-shrink: 0;
    padding-left: 1rem;
    margin-left: 1rem;
}

.logo-image {
    width: 200px;
    object-fit: contain;
}

.nav-center {
    flex: 1;
    display: flex;
    justify-content: center;
}

.nav-menu {
    display: flex;
    list-style: none;
    
}

.nav-link {
    text-decoration: none;
    color: black;
    font-weight: 500;
    font-size: 0.9rem;
    padding: 0.75rem;
    padding-left: 1rem;
    padding-right: 1rem;
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
    border-radius: 8px;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.nav-link span {
    display: inline-block;
    transition: transform 0.3s ease;
}

.nav-link:hover {
    color: Black;
    background: rgba(128, 128, 128, 0.185);
}

.nav-link:hover span {
    animation: textSlideUp 0.3s ease-out;
}

.nav-link span {
    animation: textSlideDown 0.3s ease-out;
    animation-fill-mode: both;
}

.nav-link:hover span {
    animation: textSlideUp 0.3s ease-out;
    animation-fill-mode: both;
}

@keyframes textSlideUp {
    0% {
        transform: translateY(0);
        opacity: 1;
    }
    50% {
        transform: translateY(-15px);
        opacity: 0;
    }
    51% {
        transform: translateY(15px);
        opacity: 0;
    }
    100% {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes textSlideDown {
    0% {
        transform: translateY(0);
        opacity: 1;
    }
    50% {
        transform: translateY(15px);
        opacity: 0;
    }
    51% {
        transform: translateY(-15px);
        opacity: 0;
    }
    100% {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes pulseGlow {
    0% {
        box-shadow: 0 3px 12px rgba(139, 92, 246, 0.6);
        transform: translateX(-50%) scale(1.2);
    }
    100% {
        box-shadow: 0 4px 16px rgba(139, 92, 246, 0.8);
        transform: translateX(-50%) scale(1.25);
    }
}

.nav-link.active {
    background: rgba(0, 0, 0, 0.849);
    color: white;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-shrink: 0;
    padding-right: 1rem;
}

/* Removed search button styles */

.cta-btn {
    background: white;
    color: black;
    padding: 1rem 2.8rem;
    border-radius: 50px;
    font-weight: 550;
    font-style: normal;
    font-size: 16px;
    line-height: 27px;
    letter-spacing: 0%;
    text-align: center;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: none;
    position: relative;
    white-space: nowrap;
    margin-right: 1rem;
    text-decoration: none;
}

.cta-btn::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(135deg, #45D0BD 0%, #44B6E9 100%);
    border-radius: 50px;
    z-index: -1;
}

.cta-btn:hover {
    background: linear-gradient(135deg, #45D0BD 0%, #44B6E9 100%);
    color: black;
}

/* Main Content */
main {
    margin-top: 90px;
    position: relative;
    z-index: 2;
}

/* Hero Section */
.hero {
    text-align: center;
    padding: 4rem 2rem 3rem;
    background: white;
    color: white;
    position: relative;
    overflow: visible;
    min-height: 70vh;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: -2rem 0;
    z-index: 1;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('img/Hero_bg.png') center/cover no-repeat;
    background-size: 120% 120%;
    opacity: 0.3;
    z-index: -2;
    animation: heroBackgroundFloat 6s ease-in-out infinite;
}

.hero::after {
    content: '';
    position: absolute;
    top: -4rem;
    left: -2rem;
    right: -2rem;
    bottom: -4rem;
    background: url('img/Hero_bg.png') center/cover no-repeat;
    background-size: 125% 125%;
    z-index: -1;
    opacity: 0.3;
    animation: heroBackgroundFloat 8s ease-in-out infinite reverse;
}

@keyframes heroBackgroundFloat {
    0%, 100% {
        transform: translateY(0px) scale(1);
    }
    50% {
        transform: translateY(-10px) scale(1.02);
    }
}

.hero-content {
    max-width: 1200px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
    animation: heroContentFadeIn 1.2s ease-out;
}

@keyframes heroContentFadeIn {
    0% {
        opacity: 0;
        transform: translateY(30px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-title {
    font-weight: 400;
    font-style: normal;
    font-size: 100px;
    line-height: 100%;
    letter-spacing: -3%;
    text-align: center;
    margin-bottom: 1.5rem;
    color: black;
    animation: heroTitleSlideIn 1s ease-out 0.3s both;
}

@keyframes heroTitleSlideIn {
    0% {
        opacity: 0;
        transform: translateY(50px) scale(0.9);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.gradient-text {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    color: transparent;
    text-shadow: none;
    animation: gradientTextGlow 3s ease-in-out infinite;
}

@keyframes gradientTextGlow {
    0%, 100% {
        filter: brightness(1);
    }
    50% {
        filter: brightness(1.1);
    }
}

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 2.5rem;
    opacity: 0.9;
    line-height: 1.6;
    color: black;
    animation: heroSubtitleSlideIn 1s ease-out 0.6s both;
}

@keyframes heroSubtitleSlideIn {
    0% {
        opacity: 0;
        transform: translateY(30px);
    }
    100% {
        opacity: 0.9;
        transform: translateY(0);
    }
}

.learn-more-btn {
    background: #40e0d0;
    color: white;
    border: none;
    padding: 1rem 1.5rem;
    border-radius: 15px;
    font-size: 16px;
    font-weight: 500;
    line-height: 27px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(64, 224, 208, 0.4);
    animation: heroButtonSlideIn 1s ease-out 0.9s both;
    position: relative;
    overflow: hidden;
}

@keyframes heroButtonSlideIn {
    0% {
        opacity: 0;
        transform: translateY(40px) scale(0.8);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.learn-more-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.learn-more-btn:hover::before {
    left: 100%;
}

.learn-more-btn:hover {
    box-shadow: 0 8px 25px rgba(64, 224, 208, 0.6);
    background: #36d9cc;
    transform: translateY(-2px);
}

.arrow-icon {
    width: 14px;
    height: 14px;
    margin-left: 30px;
    display: inline-block;
    transition: transform 0.3s ease;
    animation: textSlideDown 0.3s ease-out;
    animation-fill-mode: both;
}

.learn-more-btn:hover .arrow-icon {
    animation: textSlideUp 0.3s ease-out;
    animation-fill-mode: both;
}

/* AI Pipeline Section */
.ai-pipeline {
    padding: 2rem 0;
    background: linear-gradient(180deg, #ffffff 31.58%, #F5F2F6 70.49%);
    position: relative;
    z-index: 2;
    margin-top: -2rem;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 80vh;
    /* Ensure consistent container for all elements */
    contain: layout style;
}

.pipeline-container {
    position: relative;
    width: min(100vw, 1600px);
    height: clamp(450px, 45vw, 700px);
    max-width: 1600px;
    background-image: url('img/pipeline_design.png');
    background-size: contain;
    background-position: left center;
    background-repeat: no-repeat;
    /* Ensure consistent aspect ratio */
    aspect-ratio: 1600 / 700;
    container-type: inline-size;
    /* Ensure risk prediction cards are positioned relative to this container */
    position: relative;
}

/* Pipeline Text Labels */
.pipeline-label {
    position: absolute;
    font-family: 'Sora', sans-serif;
    color: #333;
    z-index: 10;
    text-align: center;
    line-height: 1.3;
    /* Responsive font scaling based on container width */
    font-size: clamp(0.7rem, 1.2vw, 1.1rem);
    transition: all 0.3s ease;
}

/* Container Queries for even more precise responsive control */
@container (max-width: 800px) {
    .pipeline-label {
        font-size: clamp(0.6rem, 1vw, 0.9rem);
    }
    
    .rna-expression-label {
        font-size: clamp(0.75rem, 1.1vw, 1rem);
    }
    
    .risk-prediction-label {
        font-size: clamp(0.85rem, 1.3vw, 1.1rem);
    }
}

@container (max-width: 600px) {
    .pipeline-label {
        font-size: clamp(0.5rem, 0.9vw, 0.8rem);
    }
    
    .rna-expression-label {
        font-size: clamp(0.65rem, 1vw, 0.9rem);
    }
    
    .risk-prediction-label {
        font-size: clamp(0.75rem, 1.2vw, 1rem);
    }
}

.pipeline-label h3 {
    font-family: 'Manrope', sans-serif;
    font-weight: 600;
    font-style: normal;
    font-size: 14px;
    margin: 0;
}

/* RNA Expression Section Labels */
.rna-expression-label {
    top: 8%;
    left: calc(13% - 20px);
    font-size: clamp(0.9rem, 1.4vw, 1.25rem);
    font-weight: 600;
    color: #333;
}

.rna-expression-label h3 {
    margin: 0;
    font-family: 'Manrope', sans-serif;
    font-weight: 600;
    font-style: normal;
    font-size: clamp(1rem, 1.6vw, 1.4rem);
}

.gene-count-label {
    top: 15%;
    left: 13.5%;
    font-size: clamp(0.7rem, 1vw, 0.9rem);
    font-weight: 400;
    color: #666;
}

/* Pre-training Section Labels */
.pretraining-main-label {
    top: 9%;
    left: 17%;
    font-size: clamp(0.8rem, 1.3vw, 1.1rem);
    font-weight: 500;
    color: #000000;
    text-align: center;
}

.encoder-label {
    top: 45%;
    left: 21.5%;
    font-size: clamp(0.7rem, 1.2vw, 1rem);
    font-weight: 600;
    color: #fff;
    text-align: center;
}

/* Latent Representation Label */
.latent-label {
    top: 33%;
    left: 37%;
    font-size: clamp(0.8rem, 1.3vw, 1.1rem);
    font-weight: 600;
    color: #333;
    text-align: center;
}

/* Fine-tuning Section Labels */
.finetuning-label {
    top: 20%;
    right: 43%;
    font-size: clamp(0.8rem, 1.3vw, 1.1rem);
    font-weight: 500;
    color: #000000;
    text-align: left;
}

.classifier-label {
    top: 48.5%;
    right: 44%;
    font-size: clamp(0.8rem, 1.3vw, 1.1rem);
    font-weight: 600;
    color: #fff;
    text-align: center;
}

/* Bottom Section Labels */
.bottom-left-label {
    bottom: 8%;
    left: calc(5% - 20px);
    font-size: clamp(0.7rem, 1vw, 0.9rem);
    font-weight: 600;
    color: #000000;
    text-align: left;
}

.bottom-left-unsupervised-label {
    bottom: 10%;
    left: 18%;
    font-size: clamp(0.7rem, 1.2vw, 1rem);
    font-weight: 500;
    color: #000000;
    text-align: center;
}

.bottom-right-label {
    bottom: 15%;
    right: 45%;
    font-size: clamp(0.8rem, 1.3vw, 1.1rem);
    font-weight: 500;
    color: #000000;
    text-align: left;
}

/* Risk Prediction Label */
.risk-prediction-label {
    top: clamp(8%, 10vh, 15%);
    right: clamp(15%, 20vw, 23.5%);
    font-size: clamp(1rem, 1.6vw, 1.4rem);
    font-weight: 600;
    color: #333;
}

/* Hide mobile-specific elements on desktop */
.mobile-rna-heading,
.mobile-pipeline-image,
.mobile-risk-heading,
.bioinformatics-text {
    display: none;
}

/* RNA Expression */
.rna-expression {
    position: absolute;
    left: 13%;
    top: 21%;
    width: clamp(3%, 5vw, 6%);
    text-align: left;
    backdrop-filter: blur(10px);
    border-radius: 15px;
    transform-origin: top left;
}

.rna-expression h3 {
    font-size: 1.75rem;
    font-weight: 700;
    color: #1f2937;
}

.gene-count {
    font-size: 1rem;
    color: #6b7280;
}

.gene-visualization {
    display: flex;
    flex-direction: column;
    gap: 0.05rem;
}

.gene-bar {
    height: clamp(12px, 1.2vw, 20px);
    width: 100%;
    position: relative;
    transform: perspective(200px) rotateX(2deg);
    box-shadow: 
        0 2px 4px rgba(0, 0, 0, 0.15),
        0 1px 2px rgba(0, 0, 0, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.2),
        inset 0 -1px 0 rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    overflow: hidden;
}

.gene-bar::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 50%;
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0.15), rgba(255, 255, 255, 0.05));
    border-radius: 4px 4px 0 0;
    pointer-events: none;
}

.gene-bar:hover {
    transform: perspective(200px) rotateX(1deg) translateY(-1px);
    box-shadow: 
        0 3px 6px rgba(0, 0, 0, 0.2),
        0 2px 4px rgba(0, 0, 0, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.25),
        inset 0 -1px 0 rgba(0, 0, 0, 0.15);
}

/* Gene bar gradients using the provided colors */
.gene-bar-1 {
    background: linear-gradient(to bottom, #93DE35 0%, #93DE35 40%, rgba(147, 222, 53, 0.6) 100%);
}

.gene-bar-2 {
    background: linear-gradient(to bottom, #FF7676 0%, #FF7676 40%, rgba(255, 118, 118, 0.6) 100%);
}

.gene-bar-3 {
    background: linear-gradient(to bottom, #3ECE77 0%, #3ECE77 40%, rgba(62, 206, 119, 0.6) 100%);
}

.gene-bar-4 {
    background: linear-gradient(to bottom, #FFF700 0%, #FFF700 40%, rgba(255, 247, 0, 0.6) 100%);
}

.gene-bar-5 {
    background: linear-gradient(to bottom, #FFA222 0%, #FFA222 40%, rgba(255, 162, 34, 0.6) 100%);
}

.gene-bar-6 {
    background: linear-gradient(to bottom, #93DE35 0%, #93DE35 40%, rgba(147, 222, 53, 0.6) 100%);
}

.gene-bar-7 {
    background: linear-gradient(to bottom, #FF7676 0%, #FF7676 40%, rgba(255, 118, 118, 0.6) 100%);
}

.gene-bar-8 {
    background: linear-gradient(to bottom, #3ECE77 0%, #3ECE77 40%, rgba(62, 206, 119, 0.6) 100%);
}

.gene-bar-9 {
    background: linear-gradient(to bottom, #FFF700 0%, #FFF700 40%, rgba(255, 247, 0, 0.6) 100%);
}

.gene-bar-10 {
    background: linear-gradient(to bottom, #FFA222 0%, #FFA222 40%, rgba(255, 162, 34, 0.6) 100%);
}

.gene-bar-11 {
    background: linear-gradient(to bottom, #93DE35 0%, #93DE35 40%, rgba(147, 222, 53, 0.6) 100%);
}

.gene-bar-12 {
    background: linear-gradient(to bottom, #FF7676 0%, #FF7676 40%, rgba(255, 118, 118, 0.6) 100%);
}

.gene-bar-13 {
    background: linear-gradient(to bottom, #3ECE77 0%, #3ECE77 40%, rgba(62, 206, 119, 0.6) 100%);
}

.gene-bar-14 {
    background: linear-gradient(to bottom, #FFF700 0%, #FFF700 40%, rgba(255, 247, 0, 0.6) 100%);
}

.gene-bar-15 {
    background: linear-gradient(to bottom, #FFA222 0%, #FFA222 40%, rgba(255, 162, 34, 0.6) 100%);
}

.gene-bar-16 {
    background: linear-gradient(to bottom, #93DE35 0%, #93DE35 40%, rgba(255, 162, 34, 0.6) 100%);
}

.gene-bar-17 {
    background: linear-gradient(to bottom, #FF7676 0%, #FF7676 40%, rgba(255, 118, 118, 0.6) 100%);
}

.gene-bar-18 {
    background: linear-gradient(to bottom, #3ECE77 0%, #3ECE77 40%, rgba(62, 206, 119, 0.6) 100%);
}

.gene-bar-dots {
    text-align: center;
    color: #6b7280;
    font-weight: bold;
    font-size: 1.5rem;
    margin-top: 0;
    padding-top: 0;
}

.bio-description {
    font-size: 0.875rem;
    color: #6b7280;
    line-height: 1.5;
}


/* Risk Prediction */
.risk-prediction {
    position: absolute;
    right: clamp(5%, 10vw, 20%);
    top: clamp(15%, 19vh, 19%);
    width: clamp(18%, 20.7vw, 22%);
    min-width: 288px;
    max-width: 350px;
    text-align: left;
    border-radius: 13.5px;
    transform-origin: top right;
    /* Position relative to pipeline container until mobile breakpoint */
    z-index: 15;
    /* Ensure it's positioned relative to the pipeline container */
    position: absolute;
}

.risk-prediction h4 {
    font-size: 21.6px;
    font-weight: 600;
    color: #1f2937;
}

.prediction-cards {
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
}

.prediction-card {
    border-radius: 10.8px;
    box-shadow: 0 2px 10px rgba(113, 177, 214, 0.329);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.675rem;
    background: linear-gradient(135deg, #80B9F8, #B093E3);
    padding: 10.8px;
    position: relative;
}

.prediction-card::before {
    content: '';
    position: absolute;
    top: 3.6px;
    left: 3.6px;
    right: 3.6px;
    bottom: 3.6px;
    background: white;
    border-radius: 9px;
    z-index: -1;
}

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

.card-content {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.risk-icon {
    height: 70.2px;
    color: #667eea;
    flex-shrink: 0;
    object-fit: contain;
}

.risk-icon.lungs {
    height: 36px;
}

/* Progress Container */
.progress-container {
    position: relative;
    display: inline-block;
}

.progress-circle {
    transform: rotate(-90deg);
    width: 50px;
    height: 50px;
}

.progress-circle circle {
    r: 23;
}

.progress__meter,
.progress__value {
    fill: none;
}

.progress__meter {
    stroke: #e5e7eb;
    stroke-width: 5;
}

.progress__value {
    stroke-linecap: round;
    stroke-width: 5;
}

.risk-percentage {
    position: absolute;
    top: 43%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 0.8rem;
    font-weight: 700;
    color: #1f2937;
    pointer-events: none;
}

.prediction-card h4 {
    font-size: 19.8px;
    font-weight: 600;
    margin-bottom: 0.3375rem;
    color: #1f2937;
}

.prediction-card p {
    font-size: 0.7875rem;
    color: #6b7280;
    margin-bottom: 0.675rem;
    line-height: 1.4;
}

.risk-timeline {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.6rem;
    color: #9ca3af;
    position: relative;
    margin-top: 0.3rem;
    padding: 0 5px;
    height: 20px;
}

.risk-timeline::before {
    content: '';
    position: absolute;
    top: -5px;
    left: 5px;
    right: 5px;
    height: 2px;
    background: #e5e7eb;
    border-radius: 1.8px;
    z-index: 1;
}

.risk-timeline span {
    position: relative;
    z-index: 3;
    text-align: center;
    font-weight: 500;
    transition: all 0.3s ease;
    cursor: pointer;
    user-select: none;
    padding: 0.225rem 0.45rem;
    border-radius: 3.6px;
}

.risk-timeline span:hover {
    color: #6366f1;
    background: rgba(99, 102, 241, 0.05);
}

.risk-timeline span:hover::before {
    border-color: #8b5cf6;
    transform: translateX(-50%) scale(1.1);
}

.risk-timeline span::before {
    content: '';
    position: absolute;
    top: -9px;
    left: 50%;
    transform: translateX(-50%);
    width: 8px;
    height: 8px;
    background: white;
    border: 2px solid #e5e7eb;
    border-radius: 50%;
    z-index: 2;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    opacity: 1;
}

.risk-timeline span.active {
    color: #8b5cf6;
    font-weight: 600;
    transform: scale(1.05);
}

.risk-timeline span.active::before {
    background: linear-gradient(135deg, #8b5cf6 0%, #6366f1 100%);
    box-shadow: 0 1px 12px rgba(139, 92, 246, 0.6);
    border: 2px solid rgba(255, 255, 255, 0.9);
    animation: pulseGlow 2s ease-in-out infinite alternate;
}

/* Randomize shimmer effect */
.prediction-card.randomize-shimmer {
    transform: scale(1.02);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.timeline-indicator {
    display: none;
}

/* Interactive Controls Section */
.interactive-controls {
    padding: 0 2rem 0 2rem;
    background: #F5F2F6;
}

.controls-container {
    max-width: 1600px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    align-items: start;
}

/* Controls Panel */
.controls-panel {
    background: white;
    border-radius: 20px 0 0 20px;
    padding: 2.5rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    min-height: 755px; /* Increased to better match human video section */
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Apply Manrope Light to all controls-panel elements except headings */
.controls-panel *:not(h2):not(h3):not(h4):not(h5):not(h6) {
    font-family: 'Manrope', sans-serif;
    font-weight: 300;
    font-size: 12px;
    line-height: 100%;
    vertical-align: middle;
}

/* Control Section Headings */
.controls-panel h2, .controls-panel h3, .controls-panel h4, .controls-panel h5, .controls-panel h6 {
    font-family: 'Manrope', sans-serif;
    font-weight: 700;
    font-size: 14px;
    line-height: 100%;
    vertical-align: middle;
}

/* Control Section Labels */
.controls-panel .control-label {
    font-family: 'Manrope', sans-serif;
    font-weight: 300;
    font-size: 14px;
    line-height: 100%;
    vertical-align: middle;
}

.control-group {
    margin-bottom: 3rem;
}

.control-label {
    display: block;
    font-size: 1rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 1rem;
}

.slider-container {
    display: flex;
    align-items: center;
    gap: 1rem;
    position: relative;
}

.slider-label-left,
.slider-label-right {
    font-size: 0.875rem;
    color: #6b7280;
    min-width: 50px;
}

.slider-label-left {
    text-align: right;
}

.slider {
    flex: 1;
    height: 22px;
    border-radius: 16px;
    background: #E6DFF080;
    outline: none;
    -webkit-appearance: none;
    appearance: none;
    cursor: pointer;
    position: relative;
    z-index: 1;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1), 0 1px 2px rgba(255, 255, 255, 0.8);
}

.slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: linear-gradient(119.39deg, #EF87FF -23.27%, #69B1FF 95.01%);
    
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
    border: 4px solid white;
    position: relative;
    z-index: 10;
}

.slider::-moz-range-thumb {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: #667eea;
    cursor: pointer;
    border: 4px solid white;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
    position: relative;
    z-index: 10;
}

.slider.genetic-risk {
    background: #E6DFF080;
    position: relative;
}

.slider.genetic-risk::-webkit-slider-thumb {
    background: linear-gradient(119.39deg, #FFB347 -23.27%, #ff5c1b 95.01%);
}

.slider.genetic-risk::-moz-range-thumb {
    background: linear-gradient(119.39deg, #ff8a47 -23.27%, #ff231b 95.01%);
}

.slider.bmi {
    background: #E6DFF080;
    position: relative;
}

.slider.bmi::-webkit-slider-thumb {
    background: linear-gradient(119.39deg, #FF8C42 -23.27%, #FFB347 95.01%);
}

.slider.bmi::-moz-range-thumb {
    background: linear-gradient(119.39deg, #FF8C42 -23.27%, #FFB347 95.01%);
}

/* Age and Disease Progress sliders with purple-red gradient and fill effect */
.slider.age {
    background: #E6DFF080;
    position: relative;
}

.slider.disease-progress {
    background: #E6DFF080;
    position: relative;
}

.slider.age::before,
.slider.disease-progress::before {
    content: '';
    position: absolute;
    left: 6px;
    width: calc(var(--fill-percentage, 0%) - 12px);
    max-width: calc(100% - 12px);
    height: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: 
        /* Cylindrical highlight on top */
        linear-gradient(to bottom, 
            rgba(255, 255, 255, 0.4) 0%, 
            rgba(255, 255, 255, 0.1) 25%, 
            transparent 50%, 
            rgba(0, 0, 0, 0.1) 75%, 
            rgba(0, 0, 0, 0.2) 100%
        ),
        /* Diagonal texture */
        repeating-linear-gradient(
            -60deg,
            transparent,
            transparent 8px,
            rgba(255, 255, 255, 0.2) 5px,
            rgba(255, 255, 255, 0.2) 15px
        ),
        /* Base color gradient */
        linear-gradient(to right, rgba(146, 51, 234, 0.534) 0%, rgba(220, 38, 38, 0.541) 100%);
    border-radius: 6px;
    transition: width 0.2s ease;
    z-index: 0;
    pointer-events: none;
    box-shadow: 
        0 2px 4px rgba(0, 0, 0, 0.2),
        0 1px 2px rgba(0, 0, 0, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.3),
        inset 0 -1px 0 rgba(0, 0, 0, 0.2),
        inset 0 0 0 1px rgba(255, 255, 255, 0.1);
}

.slider.genetic-risk::before,
.slider.bmi::before {
    content: '';
    position: absolute;
    left: 6px;
    width: calc(var(--fill-percentage, 0%) - 12px);
    max-width: calc(100% - 12px);
    height: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: 
        /* Cylindrical highlight on top */
        linear-gradient(to bottom, 
            rgba(255, 255, 255, 0.4) 0%, 
            rgba(255, 255, 255, 0.1) 25%, 
            transparent 50%, 
            rgba(0, 0, 0, 0.1) 75%, 
            rgba(0, 0, 0, 0.2) 100%
        ),
        /* Diagonal texture */
        repeating-linear-gradient(
            -60deg,
            transparent,
            transparent 8px,
            rgba(255, 255, 255, 0.2) 5px,
            rgba(255, 255, 255, 0.2) 15px
        ),
        /* Base color gradient */
        linear-gradient(to right, rgba(64, 224, 208, 0.623) 0%, rgba(255, 107, 107, 0.582) 100%);
    border-radius: 6px;
    transition: width 0.2s ease;
    z-index: 0;
    pointer-events: none;
    box-shadow: 
        0 2px 4px rgba(0, 0, 0, 0.2),
        0 1px 2px rgba(0, 0, 0, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.3),
        inset 0 -1px 0 rgba(0, 0, 0, 0.2),
        inset 0 0 0 1px rgba(255, 255, 255, 0.1);
}

.slider-value {
    position: absolute;
    top: -8px;
    left: var(--slider-position, 50%);
    transform: translateX(-50%);
    text-align: center;
    font-size: 1rem;
    font-weight: 600;
    color: #1f2937;
    background: white;
    padding: 0.5rem 0.75rem;
    border-radius: 8px;
    min-width: 50px;
    border: 1px solid #8B5CF6;
    box-shadow: 0 2px 4px rgba(139, 92, 246, 0.1);
    pointer-events: none;
    z-index: 10;
    transition: left 0.1s ease;
}

.slider-value::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 6px solid transparent;
    border-right: 6px solid transparent;
    border-top: 6px solid white;
}

.slider-value::before {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 7px solid transparent;
    border-right: 7px solid transparent;
    border-top: 7px solid #8B5CF6;
    z-index: -1;
}

/* Smoking Discrete Slider */
.smoking-discrete-slider {
    position: relative;
    margin-top: 1rem;
    margin-left: 2rem;
}

.slider-track {
    position: relative;
    height: 18px;
    display: flex;
    align-items: center;
    margin-bottom: 0.5rem;
    width: 80%;
    margin-right: auto;
}

/* Grey base line */
.slider-base {
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 100%;
    height: 4px;
    background: #8258C833;
    border-radius: 4px;
    z-index: 0;
}

/* Purple fill line */
.slider-fill {
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    height: 4px;
    background: linear-gradient(to right, #AA77FF 0%, #7c3aed 100%);
    border-radius: 4px;
    transition: width 0.3s cubic-bezier(.4,1.3,.6,1);
    z-index: 1;
}

.slider-dot {
    position: absolute;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 12px;
    height: 12px;
    background: #c7b6e4;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(.4,1.3,.6,1);
    z-index: 2;
    box-shadow: none;
}

.slider-dot.progress {
    background: #a78bfa;
    width: 16px;
    height: 16px;
}

.slider-dot.active {
    background: linear-gradient(to top, #7c3aed 50%, rgba(124, 58, 237, 0.5) 100%);
    width: 24px;
    height: 24px;
    z-index: 3;
}

.slider-dot:last-child {
    margin-right: 0;
}

.slider-dot[data-value="0"] { left: 0%; }
.slider-dot[data-value="1"] { left: 25%; }
.slider-dot[data-value="2"] { left: 50%; }
.slider-dot[data-value="3"] { left: 75%; }
.slider-dot[data-value="4"] { left: 100%; }

.smoking-labels {
    position: relative;
    margin-top: 0.5rem;
    height: 14px;
    width: 80%;
    margin-right: auto;
}
.smoking-labels span {
    font-family: 'Manrope', sans-serif !important;
    font-weight: 300 !important;
    font-size: 12px !important;
    line-height: 100%;
    vertical-align: middle;
    position: absolute;
    color: #6b7280;
    text-align: center;
    transition: all 0.3s ease;
    transform: translateX(-50%);
    cursor: pointer;
}
.smoking-labels span:nth-child(1) {
    left: 0%;
    transform: translateX(0);
    margin-left: -15px;
    padding-left: 0;
}
.smoking-labels span:nth-child(2) {
    left: 25%;
}
.smoking-labels span:nth-child(3) {
    left: 50%;
}
.smoking-labels span:nth-child(4) {
    left: 75%;
}
.smoking-labels span:nth-child(5) {
    left: 100%;
    transform: translateX(0);
    font-size: 0.7rem;
    white-space: nowrap;
    margin-left: -40px;
    margin-right: 0;
    padding-right: 0;
}
.smoking-labels span.active {
    color: #1f2937;
    font-weight: 600;
}

/* Sex Options */
.sex-options {
    display: flex;
    gap: 2rem;
}

.sex-option {
    display: flex;
    align-items: center;
    flex-direction: row;
    gap: 0.5rem;
}

.sex-option input[type="radio"] {
    appearance: none;
    -webkit-appearance: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    border: 2px solid transparent;
    background: radial-gradient(circle at 30% 30%, #EF87FF 0%, #69B1FF 100%);
    transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
    cursor: pointer;
    position: relative;
    outline: none;
    box-shadow: 0 1px 4px rgba(239, 135, 255, 0.10), 0 1px 4px rgba(105, 177, 255, 0.10);
}

.sex-option input[type="radio"]:checked {
    background: radial-gradient(circle at 30% 30%, #EF87FF 0%, #69B1FF 100%);
    box-shadow: 0 0 0 4px rgba(192, 192, 192, 0.459);
}

.sex-option input[type="radio"]:not(:checked) {
    background: radial-gradient(circle at 30% 30%, rgba(239, 135, 255, 0.2) 0%, rgba(105, 177, 255, 0.2) 100%);
}

.sex-option label {
    font-size: 1rem;
    color: #374151;
    cursor: pointer;
    font-weight: 500;
}

/* Body Visualization */
.body-visualization {
    display: flex;
    justify-content: center;
    align-items: center;
}

.body-container {
    position: relative;
    border-radius: 0 24px 24px 0;
    min-height: 650px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    overflow: hidden;
    width: 100%;
    max-width: 100%;
    margin-bottom: 100px;
}

.human-silhouette {
    position: relative;
    width: 400px;
    height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
}

.hologram-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 1;
}

.body-content {
    position: relative;
    z-index: 10;
    padding: 2.5rem;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
}

.info-card {
    position: absolute;
    background: linear-gradient(135deg, #80B9F8, #B093E3);
    padding: 2px;
    font-size: 14px;
    font-weight: 300;
    color: #333333;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
    z-index: 10;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
    min-width: 120px;
    width: auto;
}

/* Left side cards - no top-left and bottom-right radius */
.info-card:nth-child(odd) {
    border-radius: 0 12px 0 12px;
    max-width: 180px; /* Prevent overflow into center area */
}

.info-card:nth-child(odd) .card-inner {
    border-radius: 0 10px 0 10px;
}

/* Right side cards - no top-right and bottom-left radius */
.info-card:nth-child(even) {
    border-radius: 12px 0 12px 0;
    max-width: 180px; /* Prevent overflow into center area */
}

.info-card:nth-child(even) .card-inner {
    border-radius: 10px 0 10px 0;
}

.info-card .card-inner {
    background: white;
    padding: 0.8rem;
    white-space: normal;
    word-wrap: break-word;
    word-break: break-word;
    overflow-wrap: break-word;
    line-height: 1.3;
    hyphens: auto;
}

.info-card:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

/* Slanted connection lines with gradient circles */
.info-card::before {
    content: '';
    position: absolute;
    width: 60px;
    height: 1px; /* Decreased thickness from 2px to 1px */
    background: linear-gradient(135deg, #80B9F8, #B093E3);
    z-index: -1;
    transform-origin: left center;
}

.info-card::after {
    content: '';
    position: absolute;
    width: 8px;
    height: 8px;
    background: linear-gradient(135deg, #80B9F8, #B093E3);
    border-radius: 50%;
    z-index: -1;
    /* Add white dot in the middle */
    box-shadow: inset 0 0 0 2px white;
}

/* Left side cards - lines go right and down */
.info-card:nth-child(odd)::before {
    right: -60px;
    top: 50%;
    transform: translateY(-50%) rotate(15deg);
}

.info-card:nth-child(odd)::after {
    right: -58px;
    top: calc(50% + 15px);
    transform: translateY(-50%);
}

/* Right side cards - lines go left and down */
.info-card:nth-child(even)::before {
    left: -60px;
    top: 50%;
    transform: translateY(-50%) rotate(-15deg);
    transform-origin: right center;
}

.info-card:nth-child(even)::after {
    left: -64px;
    top: calc(50% + 15px);
    transform: translateY(-50%);
}

/* Randomize shimmer effect for info cards */
.info-card.randomize-shimmer {
    animation: infoCardShimmer 1.2s ease-in-out;
}

@keyframes infoCardShimmer {
    0% {
        background: linear-gradient(135deg, #80B9F8, #B093E3);
        transform: scale(1);
    }
    50% {
        background: linear-gradient(135deg, #B093E3, #80B9F8, #B093E3);
        transform: scale(1.05);
    }
    100% {
        background: linear-gradient(135deg, #80B9F8, #B093E3);
        transform: scale(1);
    }
}

/* Enhanced connection line animations */
.info-card:hover::before {
    background: linear-gradient(135deg, #667eea, #764ba2);
    height: 2px; /* Decreased hover thickness from 3px to 2px */
    transition: all 0.3s ease;
}

.info-card:hover::after {
    background: linear-gradient(135deg, #667eea, #764ba2);
    width: 10px;
    height: 10px;
    transition: all 0.3s ease;
    /* Maintain white dot in hover state */
    box-shadow: inset 0 0 0 2px white;
}

.randomize-btn {
    background: rgba(255, 255, 255, 0.356);
    color: #374151;
    border: none;
    padding: 0.5rem 0.7rem;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 500;
    font-style: normal;
    line-height: 100%;
    letter-spacing: 0%;
    vertical-align: middle;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 1rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.623);
}


.randomize-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
    background: rgba(255, 255, 255, 0.74);
}

.randomize-icon {
    width: 40px;
    height: 40px;
    object-fit: contain;
    vertical-align: middle;
    margin-right: 8px;
}

@media (max-width: 2000px) {   

    .pretraining-main-label {
        top: 8%;
        left: 26%;
        font-size: 18px;
        font-weight: 500;
        color: #000000;
        text-align: left;
    }
    
    .encoder-label {
        top: 43%;
        left: 30%;
        font-size: 16px;
        font-weight: 600;
        color: #fff;
        text-align: left;
    }
    
    /* Latent Representation Label */
    .latent-label {
        top: 32%;
        left: 45.5%;
        font-size: 18px;
        font-weight: 600;
        color: #333;
        text-align: left;
    }
    
    /* Fine-tuning Section Labels */
    .finetuning-label {
        top: 19%;
        right: 35%;
        font-size: 18px;
        font-weight: 500;
        color: #000000;
        text-align: left;
    }
    
    .classifier-label {
        top: 45.5%;
        right: 37%;
        font-size: 18px;
        font-weight: 600;
        color: #fff;
        text-align: center;
    }
    
    /* Bottom Section Labels */
    .bottom-left-label {
        bottom: 10%;
        Margin-left:8%;
        font-size: 14px;
        font-weight: 600;
        color: #000000;
        text-align: left;
        left: calc(5% - 20px);
    
    }
    
    .bottom-left-unsupervised-label {
        bottom: 14%;
        left: 26%;
        font-size: 16px;
        font-weight: 500;
        color: #000000;
        text-align: center;
    }
    
    .bottom-right-label {
        bottom: 20%;
        right: 36.5%;
        font-size: 18px;
        font-weight: 500;
        color: #000000;
        text-align: left;
    }
    
    /* Risk Prediction Label */
    .risk-prediction-label {
        top: 12%;
        right: 20%;
        font-size: 22px;
        font-weight: 600;
        color: #333;
    }
    .risk-prediction {
        right: 9%;
        top: 18%;
    }
}

@media (max-width: 1600px) {

    .rna-expression {
        left: 13%;
        top: 21%;
    }
    .pretraining-main-label {
        top: 8%;
        left: 26%;
        font-size: 18px;
        font-weight: 500;
        color: #000000;
        text-align: left;
    }
    
    .encoder-label {
        top: 43%;
        left: 31%;
        font-size: 16px;
        font-weight: 600;
        color: #fff;
        text-align: left;
    }
    
    /* Latent Representation Label */
    .latent-label {
        top: 32%;
        left: 46.5%;
        font-size: 18px;
        font-weight: 600;
        color: #333;
        text-align: left;
    }
    
    /* Fine-tuning Section Labels */
    .finetuning-label {
        top: 19%;
        right: 32.5%;
        font-size: 18px;
        font-weight: 500;
        color: #000000;
        text-align: left;
    }
    
    .classifier-label {
        top: 45.5%;
        right: 35%;
        font-size: 18px;
        font-weight: 600;
        color: #fff;
        text-align: center;
    }
    
    /* Bottom Section Labels */
    .bottom-left-label {
        bottom: 13%;
        margin-left: 9%;
        font-size: 14px;
        font-weight: 600;
        color: #000000;
        text-align: left;
        left: calc(5% - 20px);
    
    }
    
    .bottom-left-unsupervised-label {
        bottom: 14%;
        left: 26%;
        font-size: 16px;
        font-weight: 500;
        color: #000000;
        text-align: center;
    }
    
    .bottom-right-label {
        bottom: 20%;
        right: 34.5%;
        font-size: 18px;
        font-weight: 500;
        color: #000000;
        text-align: left;
    }
    
    /* Risk Prediction Label */
    .risk-prediction-label {
        top: 11%;
        right: 18.5%;
        font-size: 22px;
        font-weight: 600;
        color: #333;
    }
    .risk-prediction {
        right: 9%;
        top: 17%;
    }
}

@media (max-width: 1400px) {

    .rna-expression {
        left: 13.5%;
        top: 21%;
    }
    .pretraining-main-label {
        top: 6.5%;
        left: 26%;
        font-size: 18px;
        font-weight: 500;
        color: #000000;
        text-align: left;
    }
    
    .encoder-label {
        top: 43%;
        left: 31%;
        font-size: 14px;
        font-weight: 600;
        color: #fff;
        text-align: left;
    }
    
    /* Latent Representation Label */
    .latent-label {
        top: 30%;
        left: 46%;
        font-size: 18px;
        font-weight: 600;
        color: #333;
        text-align: left;
    }
    
    /* Fine-tuning Section Labels */
    .finetuning-label {
        top: 17.5%;
        right: 31%;
        font-size: 18px;
        font-weight: 500;
        color: #000000;
        text-align: left;
    }
    
    .classifier-label {
        top: 45.5%;
        right: 34%;
        font-size: 18px;
        font-weight: 600;
        color: #fff;
        text-align: center;
    }
    
    /* Bottom Section Labels */
    .bottom-left-label {
        bottom: 13%;
        margin-left: 9%;
        font-size: 12px;
        font-weight: 600;
        color: #000000;
        text-align: left;
        left: calc(5% - 20px);
    
    }
    
    .bottom-left-unsupervised-label {
        bottom: 13%;
        left: 26%;
        font-size: 16px;
        font-weight: 500;
        color: #000000;
        text-align: center;
    }
    
    .bottom-right-label {
        bottom: 19%;
        right: 33%;
        font-size: 18px;
        font-weight: 500;
        color: #000000;
        text-align: left;
    }
    
    /* Risk Prediction Label */
    .risk-prediction-label {
        top: 3%;
        right: 16%;
        font-size: 22px;
        font-weight: 600;
        color: #333;
    }
    .risk-prediction {
        right: 6.5%;
        top: 9%;
    }
}

/* Intermediate Responsive Breakpoints for Smoother Scaling */
@media (max-width: 1000px) {
    .pipeline-container {
        height: 52vw;
        max-height: 600px;
    }
    
    /* Adjust label font sizes for intermediate screen */
    .rna-expression-label {
        font-size: clamp(0.85rem, 1.3vw, 1.1rem);
    }
    
    .pretraining-main-label,
    .finetuning-label,
    .latent-label,
    .classifier-label,
    .bottom-right-label {
        font-size: clamp(0.75rem, 1.2vw, 1rem);
    }
    
    .encoder-label {
        font-size: clamp(0.65rem, 1.1vw, 0.9rem);
    }
    
    .gene-count-label,
    .bottom-left-label,
    .bottom-left-unsupervised-label {
        font-size: clamp(0.6rem, 0.95vw, 0.8rem);
    }
    
    .risk-prediction-label {
        font-size: clamp(0.9rem, 1.4vw, 1.2rem);
        top: 8%;
        right: 14.5%;
    }
    
    .risk-prediction {
        right: 8%;
        top: 16%;
    }
}

@media (max-width: 900px) {
    .pipeline-container {
        height: 55vw;
        max-height: 550px;
    }
    
    /* Further adjust positioning for smaller screens */
    .rna-expression {
        left: 6%;
        width: 4.5%;
    }
    
    .gene-bar {
        height: 12px;
    }
    
    /* Adjust some label positions for better fit */
    .pretraining-main-label {
        left: 19%;
    }
    
    .encoder-label {
        left: 23%;
    }
    
    .latent-label {
        left: 40%;
    }
    
    .finetuning-label {
        right: 38%;
    }
    
    .classifier-label {
        right: 39%;
    }
    
    .bottom-right-label {
        right: 40%;
    }
    
    .risk-prediction-label {
        top: 8%;
        right: 14.5%;
    }
    
    .risk-prediction {
        right: 5%;
        top: 14%;
    }
}

/* Below 1100px - Move cards below pipeline and display horizontally */
@media (max-width: 1100px) {
    .risk-prediction {
        position: static;
        width: 100%;
        min-width: auto;
        right: auto;
        top: auto;
        transform: none;
        margin: 2rem auto 0 auto;
        padding: 0 2rem;
        text-align: center;
        /* Ensure cards are positioned outside the pipeline container */
        position: static;
    }
    
    .prediction-cards {
        flex-direction: row;
        justify-content: center;
        gap: 1.5rem;
        flex-wrap: wrap;
        max-width: 1200px;
        margin: 0 auto;
    }
    
    .prediction-card {
        flex: 0 0 auto;
        min-width: 280px;
        max-width: 320px;
    }
}

/* Mobile View */
@media (max-width: 768px) {
    .navbar {
        flex-direction: row;
        gap: 1rem;
        padding: 0.5rem 0;
        justify-content: space-between;
    }
    
    .nav-center {
        display: none;
    }
    
    .nav-menu {
        flex-wrap: wrap;
        justify-content: center;
        gap: 1rem;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .ai-pipeline {
        min-height: auto;
        padding: 2rem 1rem 4rem 1rem;
        margin-bottom: 3rem;
        background: none;
    }
    
    .pipeline-container {
        background: none;
        background-size: none;
        width: 100%;
        height: auto;
        max-width: none;
        max-height: none;
        min-height: auto;
        position: static;
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 2rem;
    }
    
    /* Mobile RNA Heading */
    .mobile-rna-heading {
        display: block;
        text-align: center;
        margin-bottom: 1rem;
    }
    
    .mobile-rna-heading h3 {
        font-size: 1.5rem;
        font-weight: 600;
        color: #333;
        margin: 0 0 0.5rem 0;
    }
    
    .mobile-gene-count {
        font-size: 1rem;
        color: #666;
        margin: 0;
    }
    
    /* Hide desktop pipeline labels on mobile */
    .pipeline-label {
        display: none;
    }
    
    /* RNA Expression Mobile Styles */
    .rna-expression {
        position: static;
        width: 50%;
        left: auto;
        top: auto;
        backdrop-filter: none;
        border-radius: 0;
        transform: none;
        text-align: center;
    }
    
    .bioinformatics-text {
        margin-top: 1rem;
        font-size: 0.9rem;
        color: #666;
        text-align: center;
    }
    
    /* Mobile Pipeline Image */
    .mobile-pipeline-image {
        display: block;
        width: 90%;
        text-align: center;
    }
    
    .mobile-pipeline-image img {
        width: 100%;
        height: auto;
        max-width: 400px;
    }
    
    .gene-bar {
        height: 16px;
        margin: 0 auto;
        width: 30%;
    }
    
    /* Hide latent representation and pipeline flow on mobile */
    .latent-representation,
    .pipeline-flow {
        display: none;
    }
    
    /* Mobile Risk Heading */
    .mobile-risk-heading {
        display: block;
        text-align: center;
        margin-bottom: 1.5rem;
    }
    
    .mobile-risk-heading h3 {
        font-size: 1.5rem;
        font-weight: 600;
        color: #333;
        margin: 0;
    }

    
    .risk-icon.lungs {
        height: 35px;
    }
    
    .progress-circle {
        width: 45px;
        height: 45px;
    }
    
    .progress-circle circle {
        r: 18;
    }
    
    .progress__meter,
    .progress__value {
        stroke-width: 4;
    }
    
    .risk-percentage {
        font-size: 0.8rem;
        top: 43%;
    }
    
    .risk-timeline {
        font-size: 0.6rem;
        margin-top: 0.3rem;
        padding: 0 6px;
        height: 20px;
    }
    
    .risk-timeline::before {
        top: -6px;
        left: 6px;
        right: 6px;
        height: 2px;
    }
    
    .risk-timeline span::before {
        top: -12px;
        width: 8px;
        height: 8px;
        border-width: 2px;
    }
    
    .controls-panel {
        padding: 1.5rem;
    }
    
    .smoking-options {
        flex-direction: column;
        gap: 1rem;
    }
    
    .smoking-option {
        flex-direction: row;
        justify-content: flex-start;
    }
}

/* Small Mobile View */
@media (max-width: 480px) {
    .navbar {
        padding: 0.5rem 0;
    }
    
    .nav-left .logo {
        padding-left: 0.5rem;
    }
    
    .nav-right {
        padding-right: 0.5rem;
    }
    
    .logo-image {
        width: 120px;
    }
    
    .cta-btn {
        padding: 1rem 2rem;
        font-size: 14px;
    }
    
    .hero {
        padding: 2rem 1rem;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .interactive-controls {
        padding: 3rem 1rem 2rem 1rem;
        margin-top: 2rem;
    }
    
    .gene-bar {
        height: 10px;
        width: 70%;
    }

    
    .risk-icon.lungs {
        height: 28px;
    }
    
    .progress-circle {
        width: 40px;
        height: 40px;
    }
    
    .progress-circle circle {
        r: 16;
    }
    
    .progress__meter,
    .progress__value {
        stroke-width: 3;
    }
    
    .risk-percentage {
        font-size: 0.7rem;
        top: 42%;
    }
    
    .risk-timeline {
        font-size: 0.55rem;
        margin-top: 0.25rem;
        padding: 0 4px;
        height: 16px;
    }
    
    .risk-timeline::before {
        top: -4px;
        left: 4px;
        right: 4px;
        height: 1.5px;
    }
    
    .risk-timeline span::before {
        top: -9px;
        width: 6px;
        height: 6px;
        border-width: 1.5px;
    }
    
    .body-container {
        padding: 1rem;
        min-height: 500px;
    }
    
    .human-silhouette {
        width: 250px;
        height: 400px;
    }
}

/* Footer Styles */
.footer {
    background-color: #161616;
    background-image: url('img/footer-bg-min.png');
    background-size: cover;
    background-position: bottom center;
    background-repeat: no-repeat;
    color: #ffffff;
    padding: 6rem 0 0 0;
    position: relative;
    border-bottom-right-radius: 30px;
    border-bottom-left-radius: 30px;
    margin: 20px;
    margin-top: 0px;
}

.footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(22, 22, 22, 0.2);
    z-index: 1;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    position: relative;
    z-index: 2;
}

/* Footer Header */
.footer-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 3rem;
    padding-top: 2rem;
}

.footer-main-title {
    font-family: 'Sora', sans-serif;
    font-weight: 400;
    font-style: normal;
    font-size: 60px;
    line-height: 70px;
    letter-spacing: -0.05em;
    color: #ffffff;
    max-width: 600px;
    margin: 0;
}

/* Footer Divider */
.footer-divider {
    width: 100%;
    height: 1px;
    background: rgba(255, 255, 255, 0.671);
    margin-bottom: 3rem;
}

.footer-content {
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 4rem;
    margin-bottom: 2rem;
    padding-bottom: 2rem;
}

.footer-brand {
    display: flex;
    flex-direction: column;
}

.footer-logo-image {
    width: 180px;
    height: auto;
}

.footer-links {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 3rem;
}

/* Footer Social Section */
.footer-social-section {
    margin-bottom: 3rem;
}

.footer-social-section .footer-title {
    margin-bottom: 1rem;
}


.footer-links {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem;
}

.footer-section {
    flex-direction: column;
    gap: 1rem;
    width: 225px;
    margin-left: 100px;
}

.footer-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 0.5rem;
}

.footer-menu {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.footer-link {
    color: #ffffff;
    text-decoration: none;
    font-size: 1rem;
    transition: color 0.3s ease;
}

.footer-link:hover {
    color: #ffffff;
    opacity: 0.8;
}

.footer-link[style*="text-decoration: underline"] {
    text-underline-offset: 4px;
}

.footer-text {
    color: #ffffff;
    font-size: 1rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    word-wrap: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
}

.footer-email {
    color: #ffffff;
    font-size: 1rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    text-decoration: none;
    display: inline-block;
    white-space: nowrap;
    transition: color 0.3s ease, opacity 0.3s ease;
}

.footer-email:hover {
    color: #ffffff;
    opacity: 0.8;
    text-decoration: underline;
}

.social-links {
    display: flex;
    gap: 3rem;
    margin-top: 0.5rem;
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    border-radius: 8px;
    color: #ffffff;
    text-decoration: none;
    transition: all 0.3s ease;
}

.social-link:hover {
    background-color: #2a2a2ad7;
    color: #ffffff;
    transform: translateY(-2px);
}

.footer-bottom {
    padding: 0 0 2rem 0;
}

.footer-bottom-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 200px;

}

.copyright {
    color: grey;
    font-size: 0.9rem;
    margin: 0;
}

.back-to-top {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    border-radius: 15px;
    cursor: pointer;
    display: flex;
    align-items: center;
    transition: all 0.3s ease;
    position: relative;
}

.back-to-top-inner {
    background: #1F1F1F;
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 13px;
    font-size: 16px;
    font-weight: 500;
    line-height: 27px;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    width: 100%;
}

.back-to-top-inner:hover {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.back-to-top::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 17px;
    z-index: -1;
}

.back-to-top:hover {
    transform: translateY(-2px);
}

.back-to-top-arrow {
    width: 14px;
    height: 14px;
    transition: transform 0.3s ease;
    animation: textSlideDown 0.3s ease-out;
    animation-fill-mode: both;
}

.back-to-top:hover .back-to-top-arrow {
    animation: textSlideUp 0.3s ease-out;
    animation-fill-mode: both;
}

/* Footer Responsive Design */
@media (max-width: 768px) {
    .footer {
        padding: 3rem 0 0 0;
        margin-top: 3rem;
    }
    
    .footer-container {
        padding: 0 1rem;
    }
    
    .footer-header {
        flex-direction: column;
        gap: 2rem;
        text-align: left;
        padding-top: 1rem;
        margin-bottom: 2rem;
    }
    
    .footer-main-title {
        font-size: 2.5rem;
        max-width: 100%;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
        margin-bottom: 2rem;
    }
    
    .footer-links {
        grid-template-columns: repeat(2, 1fr);
        gap: 2rem;
    }
    
    .footer-bottom-content {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    .social-links {
        justify-content: flex-start;
    }
}

@media (max-width: 480px) {
    .footer-logo-image {
        width: 140px;
    }
    
    .footer-main-title {
        font-size: 2rem;
    }
    
    .footer-title {
        font-size: 1.1rem;
    }
    
    .footer-links {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .social-links {
        justify-content: center;
    }
} 