body {
    /* Set line height to 1.5 times the font size
        and use the OS’s UI font as the website font
       */
    font: 100%/1.5 system-ui;
    max-width: 100ch;
    margin-inline: auto;
    padding: 3ch;

}
a {
    flex: 1;
    text-decoration: none;
    color: inherit;
    padding: 0.2em;
    margin-bottom: 1.5em;
    border-bottom-style: solid;
    border-bottom-color: oklch(80% 3% 200);
    border-bottom-width: 1px;
}

.current {
    padding: 0.2em;
    border-bottom-style: solid;
    border-bottom-color: var(--border-color);
    border-bottom-width: 4px;
}
nav {
    display: flex;
    
}

li {
    display: contents;
}

ul {
    display: contents;
}

:root {
    --color-accent: #304529;
    --border-color: oklch(50% 10% 200 / 40%);
}

html {
    accent-color: var(--color-accent);
    color-scheme: dark;
}

a:hover {
    padding: 0em;
    border-bottom-style: solid;
    border-bottom-color: var(--color-accent);
    border-bottom-width: 4px;
    background-color: color-mix(in oklch, var(--color-accent), canvas 85%);
}

input {
    display: grid;
    grid-template-columns: subgrid;
    min-height: 30px;
}

textarea {
    display: grid;
    grid-template-columns: subgrid;
    min-height: 30px;
}

button {
    display: grid;
    grid-template-columns: subgrid;
    
}

form {
    display: grid;
    grid-column: 1 / -1;
    gap: 1em; 
}

form div {
    display: grid;
    grid-template-columns: auto 1fr; 
    align-items: center; 
    gap: 0.5em; 
}

.projects {
    display: grid;               /* Enable Grid */
    grid-template-columns: repeat(3, 1fr); /* 3 equal-width columns */
    gap: 20px;                    /* Add space between grid items */
    padding: 20px;                /* Add padding around the container */
}

article {
    grid-template-rows: subgrid;
    grid-row: span 3;
}

h2 {
    margin: 0
}

h1 {
    font: 400%/1.5 system-ui;
}

edu {
    display: grid;
    grid-template-columns: 1fr 1fr; 
    justify-content: center; 
    gap: 2em; 
    margin: 2em 0; 
    padding: 1em; 
    border: 1px solid #ccc; 
    border-radius: 0.5em; 
    background-color: #f9f9f9;
}

edu div {
    display: grid;
    gap: 0.5em; 
    text-align: center; 
}

header {
    display: flex; 
    flex-direction: column; 
    align-items: center; 
    justify-content: center; 
    gap: 1em; 
    padding: 2em;
    text-align: center;
}
section {
    margin: 2em 0; 
    padding: 1em; 
}

.github-stats {
    font-family: 'Arial', sans-serif;
    background-color: #f9f9f9;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
    
}

.github-stats dt {
    font-weight: bold;
    color: #333;
    margin-top: 10px;
    font-size: 1.1rem;
}

.github-stats dd {
    margin: 5px 0 15px 0;
    color: #555;
    font-size: 1rem;
    line-height: 1.5;
}

p {
    padding-top: 60px;
}

.chart-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 2rem;
    margin: 2rem auto;
    max-width: 800px;
}

.legend {
    border: 2px solid #000 !important;
    border-radius: 8px;
    padding: 24px;
    margin: 48px;
    box-shadow: 2px 2px 5px rgba(0,0,0,0.1);
    background-color: #fff;
    min-width: 200px;
}

.legend-item {
    display: flex;
    align-items: center;
    padding: 8px 0;
    transition: background-color 0.2s;
}

.legend-item:hover {
    background-color: #f5f5f5;
}

.legend-circle {
    width: 24px;
    height: 24px;
    margin-right: 24px;
    border-radius: 50%;
    display: inline-block;
}

.legend-text {
    font-size: 16px;
    font-weight: 600;
    color: #333;
}

#projects-pie-plot {
    flex-shrink: 0;
    width: 300px;
    height: 300px;
}

.project-grid {
    display: block !important;  /* Override any conflicting display properties */
}

&:has(path:hover) {
    path:not(:hover) {
        opacity: 0.2;
    }
}
path {
    transition: 300ms;
    cursor: pointer;
}

.selected {
    --color: #800020 !important;

    &:is(path) {
    fill: var(--color);
    }
}

dl.info {
    display: grid;
    grid-template-columns: auto 1fr; /* dt in first column, dd in second */
    gap: 0.5em 1em; /* Adds spacing between rows and columns */
    margin: 0; /* Removes default margins */
}

dl.info dt {
    font-weight: normal; /* Makes labels less prominent */
    color: #666; /* Lighter text color for labels */
}

dl.info dd {
    font-weight: bold; /* Makes values stand out */
    margin: 0; /* Removes default margins */
}

.tooltip {
    display: none;  /* Hide by default */
    position: fixed;
    top: 1em;
    left: 1em;
    background: #f0e9e9;
    color: #242121;
    padding: 0.5em 1em;
    box-shadow: inset 1 1 1 1px #243121;
    border-radius: 5px;
    font-size: 0.9em;
    white-space: nowrap;
}

.tooltip.show {
    display: block;  /* Show when .show is added */
}


circle {
    transition: 200ms;
    transform-origin: center;
    transform-box: fill-box;
}

circle:hover {
    transform: scale(1.5);
}

dl.info {
    /* ... other styles ... */
    transition-duration: 500ms;
    transition-property: opacity, visibility;
}

dl.info[hidden]:not(:hover, :focus-within) {
opacity: 0;
visibility: hidden;
}

circle.selected {
    fill: #ff6b6b;
}