@import url('https://fonts.googleapis.com/css2?family=Roboto+Slab:wght@400;700;900&family=Lato:wght@400;600;700&family=Roboto+Mono:wght@400;700&display=swap');

:root {
    --font-scale: 1.1; /* Adjust this value: 1.2 = 20% larger, 0.9 = 10% smaller */
    --jp-ui-font-family: "Lato", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
    --jp-code-font-family: "Roboto Mono", "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace !important;
    --jp-content-font-family: "Lato", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
}

html {
    background-color: #e8e8e8;
}

body {
    font-family: "Lato", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
 
    line-height: .9;
    color: #333333;
    background-color: #ffffff;
    /* center the body content */
    margin-left: auto;
    margin-right: auto;
    /* add a shadowlike border around the content */
    box-shadow: 0 4px 12px rgba(0,0,0,0.1), 0 8px 24px rgba(0,0,0,0.08);
    
    border-radius: 8px;
    padding: 40px 20px;
    max-width: 1100px;
    overflow-x: auto;
}

.container {
    max-width: 900px;
    
    margin: 0 auto 200px auto;
    background-color: #ffffff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1), 0 4px 16px rgba(0,0,0,0.08);
    border-radius: 4px;
}

h1, h2, h3 {
    color: #2b2a5e;
    font-family: "Roboto Slab", serif;
    font-weight: 900;
}

h1 {
    font-size: calc(2.0em * var(--font-scale)) !important;
    margin: 30px 0 20px 0;
    padding-bottom: 0px;
    padding-top: 0px;
    border-bottom: 3px solid currentColor;
    letter-spacing: -0.5px;
}

h2 {
    font-size: calc(1.75em * var(--font-scale)) !important;
    margin: 28px 0 16px 0;
    padding-top: 15px;
    border-bottom: 2px solid #eeeeee;
}

h3 {
    font-size: calc(1.5em * var(--font-scale)) !important;
    margin: 20px 0 12px 0;
}

p {
    font-size: calc(1.1em * var(--font-scale)) !important;
    margin: 15px 0;
    line-height: 1.5;
    margin-left: 20px;
    padding-right: 10px;
    padding-left: 20px;
    
}

.cell {
    margin: 25px 0;
    padding: 18px;
    background-color: #f8f9fa;
    border-left: 5px solid #007bff;
    border-radius: 6px;
}

 
 

.cell-code-toggle {
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    user-select: none;
    font-weight: 600;
    color: #007bff;
}

.cell-code-toggle:hover {
    color: #0052a3;
}

.cell-code-toggle::before {
    content: '▶';
    display: inline-block;
    transition: transform 0.3s ease;
    font-size: 0.85em;
}

.cell-code-toggle.expanded::before {
    transform: rotate(90deg);
}

.cell-code {
    font-family: 'Fira Code', 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    background-color: #2d2d30;
    color: #d4d4d4;
    padding: 16px;
    border-radius: 6px;
    overflow-x: auto;
    font-size: 1.18em;
    line-height: 1.6;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.highlight {
    font-size: 1.1em;
    /* change color to  faint yellow */
    background-color: #f5f4ed;
    padding: 16px;
    border-radius: 6px;
    overflow: hidden;
    max-height: 1000px;
    overflow-y: auto;
    position: relative;
}

.highlight-wrapper {
    position: relative;
}

.copy-button {
    position: absolute;
    top: 8px;
    right: 8px;
    background-color: #808080;
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.85em;
    font-weight: 600;
    transition: background-color 0.2s ease;
    z-index: 10;
}

.copy-button:hover {
    background-color: #606060;
}

.copy-button.copied {
    background-color: #28a745;
}

.highlight pre {
    margin: 0;
    overflow-x: auto;
    white-space: pre;
}

.cell-code.expanded {
    max-height: 2000px;
}

/* nbconvert code cell collapse styles */
.jp-Cell-inputWrapper.collapsed {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.jp-Cell-inputWrapper.expanded {
    max-height: 2000px;
    overflow: visible;
    transition: max-height 0.3s ease;
}

.output {
    margin-top: 15px;
    padding: 16px;
    background-color: #fafbfc;
    border: 1px solid #e1e8ed;
    border-radius: 6px;
}

.widget-embed {
    margin: 20px 0;
    padding: 15px;
    background-color: #fff;
    border: 2px solid #007bff;
    border-radius: 8px;
}

.widget-output {
    width: 100%;
    min-height: 400px;
}

code {
    background-color: #f1f3f5;
    padding: 3px 8px;
    border-radius: 4px;
    font-family: 'Fira Code', 'Monaco', monospace;
    font-size: 0.92em;
    color: #d63384;
}

ul, ol {
    font-size: calc(1.0em * var(--font-scale)) !important;
    margin-left: 40px;
    padding-left: 20px;
}

li {
    font-size: calc(1.0em * var(--font-scale)) !important;
 
}

pre {
    overflow-x: auto;
}

a {
    color: #0066cc;
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    text-decoration: underline;
    color: #0052a3;
}

/* Hide the paragraph symbols (¶) from heading anchor links */
a.anchor-link {
    display: none;
}

/* Table of contents styles */
 

#toc-container a {
    color: #0066cc !important;
    text-decoration: none;
    font-size: 16px;
    margin: 0px 0;
    padding: 0px 0;
}

footer {
    text-align: center;
    margin-top: 50px;
    padding-top: 20px;
    border-top: 1px solid #e1e8ed;
    color: #7f8c8d;
    font-size: 0.95em;
}

/* Image styling */
img {
    display: block;
    margin: 20px auto;
    max-width: 90%;
    height: auto;
}

/* SVG-specific sizing */
img[src$=".svg"] {
    width: 300px;
}

/* Collapsible code cells for nbconvert */

/* Add right inset to main content */
main {
    max-width: 1000px !important;
    margin-left: auto !important;
    margin-right: auto !important;
}

.jp-Notebook {
    max-width: 1000px !important;
    padding-right: 80px;
    
}