:root {
    --mm-navy: #004160;
    --mm-gray: #7b7b7f;
    --mm-light-gray: #a7a8aa;
    --mm-light-beige: #efefef;
    --mm-turquoise: #3a8fb7;
    --bg-pale-navy: #8ca3bd;
    --bg-navy: #1c5b6d;
    --bg-pale-gray: #d9d9d9;
    --bg-light-beige: #f0f4f7;
    --mm-red: #bf6766;
    --bg-dark: #0a1014;
}

/* Infographic-specific body styles with high specificity */
body {
    font-family: 'Noto Sans JP', sans-serif !important;
    line-height: 1.8 !important;
    color: var(--mm-navy) !important;
    background-color: #010c12 !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow-x: hidden !important;
    padding-top: 64px !important;
}



/* Override global strong styles for infographic pages */
.container strong {
    color: var(--mm-turquoise);
    font-weight: bold !important;
}

/* Special case for outcome class */
.container .outcome {
    color: var(--mm-turquoise) !important;
    font-weight: 500 !important;
}

/* Override global list styles for infographic pages */
.container ul {
    color: var(--bg-pale-gray) !important;
}

.container li {
    color: var(--bg-pale-gray) !important;
    margin-bottom: 10px !important;
}

/* Keep specific feature-card li styles */
.container .feature-card li {
    color: var(--mm-light-gray) !important;
}

.fixed-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: rgba(1, 12, 18, 0.85);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: 1000;
    padding: 15px 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--bg-navy);
    box-sizing: border-box;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.header-subline {
    padding: 8px 25px;
    text-align: right;
    font-size: 0.8rem;
    color: #ffffff;
    font-weight: 300;
    letter-spacing: 0.5px;
}

.header-subline .author-name {
    color: #ffffff;
    font-weight: 400;
}

.header-logo img {
    height: 30px;
    width: auto;
    display: block;
    filter: brightness(0) invert(1);
}

.header-nav a {
    color: var(--mm-light-gray);
    text-decoration: none;
    margin-left: 12px;
    font-size: 12px;
    font-weight: 500;
    transition: color 0.3s, border-bottom-color 0.3s;
    white-space: nowrap;
    border-bottom: 2px solid transparent;
    padding-bottom: 5px;
}

.header-nav a:hover, .header-nav a.active {
    color: var(--mm-turquoise);
    border-bottom-color: var(--mm-turquoise);
}

.header-cta-btn {
    background: linear-gradient(135deg, var(--mm-turquoise) 0%, #2b7ba0 100%) !important;
    color: white !important;
    padding: 6px 12px !important;
    border-radius: 6px !important;
    border: none !important;
    font-weight: 600 !important;
    margin-left: 20px !important;
    transition: all 0.3s ease !important;
}

.header-cta-btn:hover {
    background: linear-gradient(135deg, #4a9fc7 0%, #3b8bb0 100%) !important;
    transform: translateY(-1px) !important;
    box-shadow: 0 4px 12px rgba(58, 143, 183, 0.4) !important;
    border-bottom-color: transparent !important;
}

#particles-js {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
}

.container {
    position: relative;
    z-index: 1;
    max-width: 900px;
    margin: 0 auto;
    padding: 40px 20px;
}

.section {
    padding: 10vh 0;
    min-height: 80vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.section.intro {
    text-align: center;
}

.intro-content {
    padding: 40px;
    margin: 0 auto 40px auto;
    max-width: 700px;
}

.intro-content h1 {
    margin: 0 0 20px 0;
    color: var(--bg-light-beige);
}

.intro-subtitle {
    font-size: 1.3rem;
    color: var(--mm-turquoise);
    margin: 0;
    font-weight: 500;
}

.intro-description {
    font-size: 1rem;
    color: var(--bg-pale-gray);
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.7;
}

.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 1s ease-out, transform 1s ease-out;
}
.fade-in.is-visible {
    opacity: 1;
    transform: translateY(0);
}

h1, h2, h3, h4 {
    font-family: 'Noto Serif JP', serif !important;
    font-weight: 600 !important;
    color: var(--bg-light-beige) !important;
}

h1 { font-size: 2.8rem; text-align: center; }
h2 { font-size: 2.2rem; }
h3 { font-size: 1.6rem; color: var(--mm-turquoise) !important; border-left: 4px solid var(--mm-turquoise); padding-left: 15px; margin: 60px 0 30px 0; }
h4 { font-size: 1.2rem; }

p {
    font-size: 1.1rem !important;
    color: var(--bg-pale-gray) !important;
    max-width: 700px;
}

.text-center { text-align: center; }
.text-center p { margin-left: auto; margin-right: auto; }

.question-block {
    margin-bottom: 40px;
}
.question-block p {
    font-family: 'Noto Serif JP', serif;
    font-size: 1.2rem;
    color: var(--bg-light-beige);
    margin-bottom: 15px;
}

.rating-group {
    display: flex;
    justify-content: space-between;
    background: rgba(28, 91, 109, 0.2);
    border-radius: 8px;
    padding: 10px;
    border: 1px solid var(--bg-navy);
}
.rating-group input { display: none; }
.rating-group label {
    flex: 1;
    text-align: center;
    padding: 10px 0;
    color: var(--mm-light-gray);
    cursor: pointer;
    transition: all 0.3s ease;
    border-radius: 5px;
}
.rating-group label:hover {
    background-color: rgba(58, 143, 183, 0.3);
    color: white;
}
.rating-group input:checked + label {
    background-color: var(--mm-turquoise);
    color: white;
    font-weight: bold;
}
.rating-label-desc {
    display: flex;
    justify-content: space-between;
    padding: 0 10px;
    font-size: 0.9rem;
    color: var(--mm-gray);
}

#calculate-btn {
    display: block;
    margin: 50px auto 0 auto;
    background-color: var(--mm-gray);
    color: #fff;
    padding: 15px 40px;
    text-decoration: none;
    border: none;
    border-radius: 5px;
    font-size: 1.2rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s;
}

#calculate-btn:not(:disabled) {
    background-color: var(--mm-turquoise);
}
#calculate-btn:not(:disabled):hover {
    background-color: #4ab0d6;
}

#results-section {
    display: none;
}
.results-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
    margin-top: 50px;
}
.result-card {
    background: rgba(28, 91, 109, 0.2);
    border: 1px solid var(--bg-navy);
    padding: 30px;
    border-radius: 8px;
    text-align: center;
}
.result-card h4 {
    color: var(--mm-turquoise);
    font-size: 1.4rem;
}
.result-card .score {
    font-size: 4rem;
    font-weight: bold;
    color: var(--mm-turquoise);
}
.result-card .comment {
    font-size: 1.1rem;
    color: var(--bg-light-beige);
}

.cta-section {
    background-color: rgba(140, 163, 189, 0.1);
    border-radius: 10px;
    padding: 50px;
    text-align: center;
    border: 1px solid var(--bg-pale-navy);
}
.cta-button {
    display: inline-block;
    background-color: var(--mm-turquoise);
    color: #fff;
    padding: 15px 40px;
    text-decoration: none;
    border-radius: 5px;
    font-size: 1.2rem;
    font-weight: bold;
    margin-top: 30px;
    transition: background-color 0.3s;
}
.cta-button:hover {
    background-color: #4ab0d6;
}

/* Learning Nervous System & Deep Dive specific styles */
.phase-content {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 50px;
    align-items: flex-start;
}
.diagram-placeholder {
    border: 1px solid var(--bg-navy);
    background-color: rgba(0, 65, 96, 0.1);
    min-height: 400px;
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--mm-gray);
    font-family: 'Noto Serif JP', serif;
    font-size: 1.2rem;
    padding: 30px;
    text-align: center;
    border-radius: 8px;
    position: sticky;
    top: 40px;
}

/* Mermaid container specific styling */
.mermaid-container {
    width: 100%;
    height: 100%;
    min-height: 350px;
}

.mermaid-container svg {
    max-width: 100% !important;
    height: auto !important;
    min-height: 300px;
}

/* Alternative: Full-width diagram layout for even larger display */
.phase-content.large-diagram {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.phase-content.large-diagram .diagram-placeholder {
    min-height: 500px;
    max-width: 800px;
    margin: 0 auto;
    position: static;
}

/* New large diagram style for vertical layout */
.diagram-placeholder-large {
    border: 1px solid var(--bg-navy);
    background-color: rgba(0, 65, 96, 0.1);
    min-height: 500px;
    max-width: 1000px;
    margin: 40px auto;
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--mm-gray);
    font-family: 'Noto Serif JP', serif;
    font-size: 1.2rem;
    padding: 40px;
    text-align: center;
    border-radius: 8px;
}

.diagram-placeholder-large .mermaid-container {
    width: 100%;
    height: 100%;
    min-height: 400px;
}

.diagram-placeholder-large .mermaid-container svg {
    max-width: 100% !important;
    height: auto !important;
    min-height: 350px;
    width: 100% !important;
}
.principle {
    background-color: rgba(28, 91, 109, 0.1);
    border-left: 3px solid var(--mm-turquoise);
    padding: 15px 20px;
    margin: 20px 0;
    font-family: 'Noto Serif JP', serif;
    font-style: italic;
    color: var(--bg-light-beige);
}
.outcome {
    font-weight: 500;
    color: var(--mm-turquoise);
}

/* MMP Deep Dive Specific */
.symptom-card {
    background-color: rgba(191, 103, 102, 0.05);
    border: 1px solid rgba(191, 103, 102, 0.5);
    border-radius: 8px;
    padding: 25px;
    margin: 40px 0;
}
.symptom-card h3 {
    margin-top: 0;
    border-left-color: var(--mm-red);
}
.symptom-title {
    color: var(--mm-red) !important;
}
.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
    margin-top: 30px;
}
.feature-card {
    background-color: rgba(28, 91, 109, 0.15);
    border: 1px solid var(--bg-navy);
    border-radius: 8px;
    padding: 25px;
}
.feature-card h4 {
    margin-top: 0;
    font-size: 1.2rem;
    color: var(--mm-turquoise);
}
.feature-card ul {
    padding-left: 20px;
    color: var(--mm-light-gray);
    font-size: 1rem;
}
.feature-card li { margin-bottom: 8px; }

.status-badge {
    display: inline-block;
    font-size: 0.8rem;
    padding: 2px 8px;
    border-radius: 12px;
    color: white;
    margin-left: 8px;
    font-family: 'Noto Sans JP', sans-serif;
    vertical-align: middle;
}
.status-dev { background-color: #ff9800; }
.status-planned { background-color: #2196f3; }

/* Value Destruction Model Specific */
.param-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.param-card {
    background: rgba(28, 91, 109, 0.2);
    border: 1px solid var(--bg-navy);
    padding: 25px;
    border-radius: 8px;
    backdrop-filter: blur(5px);
}
.param-card h3 {
    color: var(--mm-turquoise);
    margin-top: 0;
    font-size: 1.4rem;
}
.param-card p {
    font-size: 1rem;
    color: var(--mm-light-gray);
}

.simulation-container {
    display: flex;
    align-items: center;
    gap: 40px;
}

.simulation-chart {
    flex: 1;
}

.simulation-text {
    flex: 1;
}
.simulation-text blockquote {
    font-family: 'Noto Serif JP', serif;
    font-size: 1rem;
    color: var(--mm-light-gray);
    border-left: 3px solid var(--mm-turquoise);
    padding-left: 20px;
    margin: 20px 0 0 0;
    font-style: italic;
}

svg .step-node { fill: var(--mm-turquoise); transition: fill 0.5s; }
svg .step-node.damaged { fill: var(--mm-red); }
svg .step-text { font-family: 'Noto Sans JP', sans-serif; fill: var(--bg-pale-gray); }
svg .step-line { stroke: var(--mm-turquoise); stroke-width: 2; transition: stroke-dashoffset 2s ease-out; stroke-dasharray: 1000; stroke-dashoffset: 1000; }
svg .damage-text { fill: var(--mm-red); font-size: 1.2rem; font-weight: bold; opacity: 0; transition: opacity 0.5s; }

.final-result-section {
    text-align: center;
}
.final-number {
    font-family: 'Noto Serif JP', serif;
    font-size: 8rem;
    font-weight: 600;
    color: var(--mm-red);
    margin: 20px 0;
    line-height: 1;
}

@media (max-width: 960px) {
    .fixed-header {
        flex-direction: column;
        align-items: center;
        gap: 15px;
        padding: 15px 20px;
    }
    .header-subline {
        font-size: 0.75rem;
        padding: 6px 20px;
    }
    body {
        padding-top: 130px;
    }
}

@media (max-width: 768px) {
    .results-grid, .phase-content, .feature-grid, .simulation-container {
        grid-template-columns: 1fr;
        flex-direction: column;
    }
    .diagram-placeholder {
        position: static;
        min-height: 250px;
    }
    .diagram-placeholder-large {
        max-width: 100%;
        min-height: 350px;
        margin: 20px auto;
        padding: 20px;
    }
    .diagram-placeholder-large .mermaid-container {
        min-height: 300px;
    }
    .diagram-placeholder-large .mermaid-container svg {
        min-height: 250px;
    }
    h1 { font-size: 2.2rem; }
    h2 { font-size: 1.8rem; }
}

@media (max-width: 520px) {
    .header-nav {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 10px;
    }
    .header-nav a {
        margin-left: 0;
    }
    .header-subline {
        font-size: 0.7rem;
        padding: 5px 15px;
        text-align: center;
    }
    body {
        padding-top: 230px;
    }
} 