/*
Blog style inspired by Medium.com
2024 Jal
*/

@font-face {
    font-family: 'charter';
    src: url('../../fonts/Charter Regular.ttf');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'charter';
    src: url('../../fonts/Charter Bold.ttf');
    font-weight: bold;
    font-style: normal;
}

@font-face {
    font-family: 'charter';
    src: url('../../fonts/Charter Italic.ttf');
    font-weight: normal;
    font-style: italic;
}

@font-face {
    font-family: 'charter';
    src: url('../../fonts/Charter Bold Italic.ttf');
    font-weight: bold;
    font-style: italic;
}

@font-face {
    font-family: 'lato';
    src: url('../../fonts/Lato-Black.ttf');
}

@font-face {
    font-family: 'helveticaneuelight';
    src: url('../../fonts/HelveticaNeueLight.ttf');
}


body {
    font-family: 'charter', Georgia, serif;
    font-size: 21px;
    line-height: 1.58;
    color: rgba(0, 0, 0, 0.84);
    padding: 0;
    margin: 0 auto;
}

h1 {
    font-family: 'lato', Helvetica, Arial, sans-serif;
    font-size: 42px;
    font-weight: bold;
    line-height: 1.15;
    color: rgba(0, 0, 0, 0.84);
    margin: 1em 0 0.5em;
    letter-spacing: -0.03em;
}

h2 {
    font-family: 'lato', Helvetica, Arial, sans-serif;
    font-size: 34px;
    font-weight: bold;
    line-height: 1.22;
    color: rgba(0, 0, 0, 0.84);
    margin: 1.5em 0 0.4em;
    letter-spacing: -0.025em;
}

h3, h4, h5 {
    font-family: 'lato', Helvetica, Arial, sans-serif;
    font-weight: bold;
    color: rgba(0, 0, 0, 0.84);
    margin: 1.5em 0 0.4em;
}

h3 {
    font-size: 28px;
    line-height: 1.22;
    letter-spacing: -0.02em;
}

h4 {
    font-size: 24px;
    line-height: 1.22;
    letter-spacing: -0.015em;
}

a {
    color: rgba(0, 0, 0, 0.84);
    text-decoration: underline;
}

table {
    border-collapse: collapse;
    margin: 1.5em 0;
    width: 100%;
    font-size: 0.9em;
}

th, td {
    border: 1px solid rgba(0, 0, 0, 0.15);
    padding: 0.8em;
}

th {
    background-color: rgba(0, 0, 0, 0.05);
    font-weight: bold;
}

code {
    font-family: 'SF Mono', Menlo, Monaco, Consolas, 'Courier New', monospace;
    font-size: 0.85em;
    background-color: rgba(0, 0, 0, 0.05);
    padding: 0.2em 0.4em;
    border-radius: 3px;
    border: 1px solid rgba(0, 0, 0, 0.1);
}

pre code.hljs {
    background-color: rgba(0, 0, 0, 0.05);
    padding: 1.2em;
    border-radius: 5px;
    font-size: 0.85em;
    line-height: 1.5;
    overflow-x: auto;
    border: 1px solid rgba(0, 0, 0, 0.1);
}

blockquote {
    padding-left: 20px;
    margin-left: 0;
    margin-right: 0;
    font-style: italic;
    font-size: 1.2em;
    color: rgba(0, 0, 0, 0.531);
    font-family: "Helvetica Neue Light", 'helveticaneuelight', "Helvetica Neue", Helvetica, Arial, sans-serif;
    font-weight: 300;
}

hr {
    border: none;
    text-align: center;
    margin: 2em 0;
    height: 1em;
}

hr:after {
    content: "•••";
    display: inline-block;
    letter-spacing: 0.6em;
    color: rgba(0, 0, 0, 0.84);
}


/* Dark mode */
@media (prefers-color-scheme: dark) {
    body {
        background-color: #121212;
        color: rgba(255, 255, 255, 0.87);
    }

    h1, h2, h3, h4, h5 {
        color: rgba(255, 255, 255, 0.95);
    }

    a {
        color: rgba(255, 255, 255, 0.87);
    }

    table {
        border-color: rgba(255, 255, 255, 0.15);
    }

    th, td {
        border-color: rgba(255, 255, 255, 0.15);
    }

    th {
        background-color: rgba(255, 255, 255, 0.05);
    }

    code {
        background-color: rgba(255, 255, 255, 0.1);
        color: rgba(255, 255, 255, 0.87);
        border: 1px solid rgba(255, 255, 255, 0.15);
    }

    pre code.hljs {
        background-color: rgba(255, 255, 255, 0.1);
        border: 1px solid rgba(255, 255, 255, 0.15);
    }

    blockquote {
        border-left-color: rgba(255, 255, 255, 0.6);
        color: rgba(255, 255, 255, 0.585);
        font-family: "Helvetica Neue Light", 'helveticaneuelight', "Helvetica Neue", Helvetica, Arial, sans-serif;
        font-weight: 300;
    }
    
    hr:after {
        color: rgba(255, 255, 255, 0.7);
    }
}

/* Print styles */
@media print {
    body {
        color: #000;
        background: #fff;
        font-size: 12pt;
    }

    a {
        color: #000;
        text-decoration: underline;
        border-bottom: none;
    }
} 