/* ryandam.net - modern minimal theme */
:root {
    --bg: #fafafa;
    --bg-card: #ffffff;
    --bg-code: #f4f4f5;
    --text: #18181b;
    --text-muted: #71717a;
    --accent: #10b981;
    --accent-hover: #059669;
    --border: #e4e4e7;
    --radius: 12px;
}

@media (prefers-color-scheme: dark) {
    :root {
        --bg: #09090b;
        --bg-card: #18181b;
        --bg-code: #27272a;
        --text: #f4f4f5;
        --text-muted: #a1a1aa;
        --accent: #34d399;
        --accent-hover: #10b981;
        --border: #27272a;
    }
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Google Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.8;
    -webkit-font-smoothing: antialiased;
}

a {
    color: var(--accent);
    text-decoration: none;
    transition: color 0.2s;
}

a:hover {
    color: var(--accent-hover);
}

/* Navigation */
.nav {
    border-bottom: 1px solid var(--border);
    background: var(--bg-card);
    position: sticky;
    top: 0;
    z-index: 10;
    backdrop-filter: blur(8px);
    background: color-mix(in srgb, var(--bg-card) 80%, transparent);
}

.nav-inner {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 2rem;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nav-logo {
    font-weight: 800;
    font-size: 1.25rem;
    color: var(--text) !important;
    letter-spacing: -0.025em;
}

.nav-links {
    display: flex;
    gap: 2rem;
}

.nav-links a {
    color: var(--text-muted) !important;
    font-size: 0.95rem;
    font-weight: 500;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--text) !important;
}

/* Blog listing */
.listing {
    max-width: 900px;
    margin: 4rem auto;
    padding: 0 2rem;
}

.listing h1 {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 4rem;
    letter-spacing: -0.04em;
}

.post-list {
    list-style: none;
}

.post-item {
    padding: 2.5rem 0;
    border-bottom: 1px solid var(--border);
    transition: transform 0.2s ease;
}

.post-item:last-child {
    border-bottom: none;
}

.post-link {
    display: inline-block;
    text-decoration: none !important;
    margin-bottom: 0.75rem;
}

.post-title {
    font-size: 1.875rem;
    font-weight: 800;
    color: var(--text);
    line-height: 1.2;
    letter-spacing: -0.03em;
    transition: color 0.2s;
}

.post-link:hover .post-title {
    color: var(--accent);
}

.post-date {
    font-size: 0.9rem;
    color: var(--text-muted);
    font-weight: 500;
}

.post-desc {
    font-size: 1.05rem;
    color: var(--text-muted);
    line-height: 1.6;
    max-width: 65ch;
    margin-bottom: 1rem;
}

.post-item .post-desc {
    margin-bottom: 0.75rem;
}

.post-tags {
    margin-bottom: 0.5rem;
}

.tag {
    display: inline-block;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 0.25rem 0.6rem;
    background: var(--bg-code);
    border-radius: 6px;
    color: var(--text-muted);
    border: 1px solid var(--border);
}

.post-item:hover .tag {
    border-color: var(--accent);
    color: var(--accent);
}

/* Blog post */
.post {
    max-width: 1000px;
    margin: 0 auto;
    padding: 4rem 2rem 8rem;
}

.post-header {
    margin-bottom: 4rem;
    text-align: center;
}

.post-header h1 {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    letter-spacing: -0.05em;
}

/* Post body content */
.post-body {
    font-size: 1.125rem;
    color: var(--text);
}

.post-body h2 {
    font-size: 1.875rem;
    font-weight: 700;
    margin: 3rem 0 1.25rem;
    letter-spacing: -0.025em;
}

.post-body h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 2.5rem 0 1rem;
}

.post-body p {
    margin: 0 0 1.5rem;
}

.post-body ul,
.post-body ol {
    margin: 0 0 1.5rem 1.5rem;
}

.post-body li {
    margin-bottom: 0.5rem;
}

.post-body blockquote {
    margin: 2rem 0;
    padding: 1.5rem 2rem;
    border-left: 4px solid var(--accent);
    background: var(--bg-code);
    border-radius: 0 var(--radius) var(--radius) 0;
    font-style: italic;
    color: var(--text-muted);
}

.post-body img {
    max-width: 100%;
    height: auto;
    border-radius: var(--radius);
    margin: 3rem 0;
    display: block;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

.post-body pre {
    font-family: 'Overpass Mono', monospace;
    background: var(--bg-code) !important;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.5rem;
    margin: 2rem 0;
    overflow-x: auto;
}

.post-body code {
    font-family: 'Overpass Mono', monospace;
    font-size: 0.9em;
    background: var(--bg-code);
    padding: 0.2em 0.4em;
    border-radius: 6px;
}

.post-body pre code {
    background: none;
    padding: 0;
    font-size: 0.95rem;
}

/* Tables */
.post-body table {
    width: 100%;
    border-collapse: collapse;
    margin: 2rem 0;
    font-size: 1rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
}

.post-body th,
.post-body td {
    padding: 0.75rem 1rem;
    border: 1px solid var(--border);
    text-align: left;
}

.post-body th {
    background: var(--bg-code);
    font-weight: 700;
    color: var(--text);
}

.post-body tr:nth-child(even) {
    background: color-mix(in srgb, var(--bg-code) 30%, transparent);
}

/* Chroma Syntax Highlighting Fixes */
.chroma {
    background-color: transparent !important;
}

/* Callout / Admonition */
.callout {
    margin: 2rem 0;
    padding: 1.25rem 1.5rem;
    border-radius: var(--radius);
    border-left: 4px solid;
}

.callout > :last-child {
    margin-bottom: 0;
}

.callout::before {
    display: block;
    font-weight: 700;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 0.5rem;
}

.callout-info {
    background: #eff6ff;
    border-left-color: #3b82f6;
    color: #1e40af;
}
.callout-info::before { content: "Info"; }

.callout-warning {
    background: #fffbeb;
    border-left-color: #f59e0b;
    color: #92400e;
}
.callout-warning::before { content: "Warning"; }

.callout-tip {
    background: #f0fdf4;
    border-left-color: #22c55e;
    color: #166534;
}
.callout-tip::before { content: "Tip"; }

.callout-success {
    background: #ecfdf5;
    border-left-color: #10b981;
    color: #065f46;
}
.callout-success::before { content: "Success"; }

.callout-note {
    background: #f8fafc;
    border-left-color: #64748b;
    color: #334155;
}
.callout-note::before { content: "Note"; }

.callout-danger,
.callout-error {
    background: #fef2f2;
    border-left-color: #ef4444;
    color: #991b1b;
}
.callout-danger::before,
.callout-error::before { content: "Danger"; }

@media (prefers-color-scheme: dark) {
    .callout {
        background: var(--bg-card);
    }

    .callout-info {
        border-left-color: #60a5fa;
        color: #93c5fd;
    }

    .callout-warning {
        border-left-color: #fbbf24;
        color: #fde68a;
    }

    .callout-tip {
        border-left-color: #34d399;
        color: #a7f3d0;
    }

    .callout-success {
        border-left-color: #34d399;
        color: #6ee7b7;
    }

    .callout-note {
        border-left-color: #94a3b8;
        color: #cbd5e1;
    }

    .callout-danger,
    .callout-error {
        border-left-color: #f87171;
        color: #fca5a5;
    }
}

/* Footer */
.footer {
    text-align: center;
    padding: 4rem 2rem;
    border-top: 1px solid var(--border);
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Responsive */
@media (max-width: 768px) {
    .nav-inner {
        padding: 0 1.5rem;
    }

    .post {
        padding: 2rem 1.5rem 4rem;
    }

    .post-header h1 {
        font-size: 2.5rem;
    }

    .listing h1 {
        font-size: 2rem;
    }
}

/* Syntax Highlighting - Light */
/* Background */ .bg { background-color: #f7f7f7; }
/* PreWrapper */ .chroma { background-color: #f7f7f7; -webkit-text-size-adjust: none; }
/* Error */ .chroma .err { color: #f6f8fa; background-color: #82071e }
/* LineLink */ .chroma .lnlinks { outline: none; text-decoration: none; color: inherit }
/* LineTableTD */ .chroma .lntd { vertical-align: top; padding: 0; margin: 0; border: 0; }
/* LineTable */ .chroma .lntable { border-spacing: 0; padding: 0; margin: 0; border: 0; }
/* LineHighlight */ .chroma .hl { background-color: #dedede }
/* LineNumbersTable */ .chroma .lnt { white-space: pre; -webkit-user-select: none; user-select: none; margin-right: 0.4em; padding: 0 0.4em 0 0.4em;color: #7f7f7f }
/* LineNumbers */ .chroma .ln { white-space: pre; -webkit-user-select: none; user-select: none; margin-right: 0.4em; padding: 0 0.4em 0 0.4em;color: #7f7f7f }
/* Line */ .chroma .line { display: flex; }
/* Keyword */ .chroma .k { color: #cf222e }
/* KeywordConstant */ .chroma .kc { color: #cf222e }
/* KeywordDeclaration */ .chroma .kd { color: #cf222e }
/* KeywordNamespace */ .chroma .kn { color: #cf222e }
/* KeywordPseudo */ .chroma .kp { color: #cf222e }
/* KeywordReserved */ .chroma .kr { color: #cf222e }
/* KeywordType */ .chroma .kt { color: #cf222e }
/* NameAttribute */ .chroma .na { color: #1f2328 }
/* NameClass */ .chroma .nc { color: #1f2328 }
/* NameConstant */ .chroma .no { color: #0550ae }
/* NameDecorator */ .chroma .nd { color: #0550ae }
/* NameEntity */ .chroma .ni { color: #6639ba }
/* NameLabel */ .chroma .nl { color: #990000; font-weight: bold }
/* NameNamespace */ .chroma .nn { color: #24292e }
/* NameOther */ .chroma .nx { color: #1f2328 }
/* NameTag */ .chroma .nt { color: #0550ae }
/* NameBuiltin */ .chroma .nb { color: #6639ba }
/* NameBuiltinPseudo */ .chroma .bp { color: #6a737d }
/* NameVariable */ .chroma .nv { color: #953800 }
/* NameVariableClass */ .chroma .vc { color: #953800 }
/* NameVariableGlobal */ .chroma .vg { color: #953800 }
/* NameVariableInstance */ .chroma .vi { color: #953800 }
/* NameVariableMagic */ .chroma .vm { color: #953800 }
/* NameFunction */ .chroma .nf { color: #6639ba }
/* NameFunctionMagic */ .chroma .fm { color: #6639ba }
/* LiteralString */ .chroma .s { color: #0a3069 }
/* LiteralStringAffix */ .chroma .sa { color: #0a3069 }
/* LiteralStringBacktick */ .chroma .sb { color: #0a3069 }
/* LiteralStringChar */ .chroma .sc { color: #0a3069 }
/* LiteralStringDelimiter */ .chroma .dl { color: #0a3069 }
/* LiteralStringDoc */ .chroma .sd { color: #0a3069 }
/* LiteralStringDouble */ .chroma .s2 { color: #0a3069 }
/* LiteralStringEscape */ .chroma .se { color: #0a3069 }
/* LiteralStringHeredoc */ .chroma .sh { color: #0a3069 }
/* LiteralStringInterpol */ .chroma .si { color: #0a3069 }
/* LiteralStringOther */ .chroma .sx { color: #0a3069 }
/* LiteralStringRegex */ .chroma .sr { color: #0a3069 }
/* LiteralStringSingle */ .chroma .s1 { color: #0a3069 }
/* LiteralStringSymbol */ .chroma .ss { color: #032f62 }
/* LiteralNumber */ .chroma .m { color: #0550ae }
/* LiteralNumberBin */ .chroma .mb { color: #0550ae }
/* LiteralNumberFloat */ .chroma .mf { color: #0550ae }
/* LiteralNumberHex */ .chroma .mh { color: #0550ae }
/* LiteralNumberInteger */ .chroma .mi { color: #0550ae }
/* LiteralNumberIntegerLong */ .chroma .il { color: #0550ae }
/* LiteralNumberOct */ .chroma .mo { color: #0550ae }
/* Operator */ .chroma .o { color: #0550ae }
/* OperatorWord */ .chroma .ow { color: #0550ae }
/* OperatorReserved */ .chroma .or { color: #0550ae }
/* Punctuation */ .chroma .p { color: #1f2328 }
/* Comment */ .chroma .c { color: #57606a }
/* CommentHashbang */ .chroma .ch { color: #57606a }
/* CommentMultiline */ .chroma .cm { color: #57606a }
/* CommentSingle */ .chroma .c1 { color: #57606a }
/* CommentSpecial */ .chroma .cs { color: #57606a }
/* CommentPreproc */ .chroma .cp { color: #57606a }
/* CommentPreprocFile */ .chroma .cpf { color: #57606a }
/* GenericDeleted */ .chroma .gd { color: #82071e; background-color: #ffebe9 }
/* GenericEmph */ .chroma .ge { color: #1f2328 }
/* GenericInserted */ .chroma .gi { color: #116329; background-color: #dafbe1 }
/* GenericOutput */ .chroma .go { color: #1f2328 }
/* GenericUnderline */ .chroma .gl { text-decoration: underline }
/* TextWhitespace */ .chroma .w { color: #ffffff }

@media (prefers-color-scheme: dark) {
/* Background */ .bg { color: #f8f8f2; background-color: #282a36; }
/* PreWrapper */ .chroma { color: #f8f8f2; background-color: #282a36; -webkit-text-size-adjust: none; }
/* LineLink */ .chroma .lnlinks { outline: none; text-decoration: none; color: inherit }
/* LineTableTD */ .chroma .lntd { vertical-align: top; padding: 0; margin: 0; border: 0; }
/* LineTable */ .chroma .lntable { border-spacing: 0; padding: 0; margin: 0; border: 0; }
/* LineHighlight */ .chroma .hl { background-color: #3d3f4a }
/* LineNumbersTable */ .chroma .lnt { white-space: pre; -webkit-user-select: none; user-select: none; margin-right: 0.4em; padding: 0 0.4em 0 0.4em;color: #7f7f7f }
/* LineNumbers */ .chroma .ln { white-space: pre; -webkit-user-select: none; user-select: none; margin-right: 0.4em; padding: 0 0.4em 0 0.4em;color: #7f7f7f }
/* Line */ .chroma .line { display: flex; }
/* Keyword */ .chroma .k { color: #ff79c6 }
/* KeywordConstant */ .chroma .kc { color: #ff79c6 }
/* KeywordDeclaration */ .chroma .kd { color: #8be9fd; font-style: italic }
/* KeywordNamespace */ .chroma .kn { color: #ff79c6 }
/* KeywordPseudo */ .chroma .kp { color: #ff79c6 }
/* KeywordReserved */ .chroma .kr { color: #ff79c6 }
/* KeywordType */ .chroma .kt { color: #8be9fd }
/* NameAttribute */ .chroma .na { color: #50fa7b }
/* NameClass */ .chroma .nc { color: #50fa7b }
/* NameLabel */ .chroma .nl { color: #8be9fd; font-style: italic }
/* NameTag */ .chroma .nt { color: #ff79c6 }
/* NameBuiltin */ .chroma .nb { color: #8be9fd; font-style: italic }
/* NameBuiltinPseudo */ .chroma .bp { font-style: italic }
/* NameVariable */ .chroma .nv { color: #8be9fd; font-style: italic }
/* NameVariableClass */ .chroma .vc { color: #8be9fd; font-style: italic }
/* NameVariableGlobal */ .chroma .vg { color: #8be9fd; font-style: italic }
/* NameVariableInstance */ .chroma .vi { color: #8be9fd; font-style: italic }
/* NameVariableMagic */ .chroma .vm { color: #8be9fd; font-style: italic }
/* NameFunction */ .chroma .nf { color: #50fa7b }
/* NameFunctionMagic */ .chroma .fm { color: #50fa7b }
/* LiteralString */ .chroma .s { color: #f1fa8c }
/* LiteralStringAffix */ .chroma .sa { color: #f1fa8c }
/* LiteralStringBacktick */ .chroma .sb { color: #f1fa8c }
/* LiteralStringChar */ .chroma .sc { color: #f1fa8c }
/* LiteralStringDelimiter */ .chroma .dl { color: #f1fa8c }
/* LiteralStringDoc */ .chroma .sd { color: #f1fa8c }
/* LiteralStringDouble */ .chroma .s2 { color: #f1fa8c }
/* LiteralStringEscape */ .chroma .se { color: #f1fa8c }
/* LiteralStringHeredoc */ .chroma .sh { color: #f1fa8c }
/* LiteralStringInterpol */ .chroma .si { color: #f1fa8c }
/* LiteralStringOther */ .chroma .sx { color: #f1fa8c }
/* LiteralStringRegex */ .chroma .sr { color: #f1fa8c }
/* LiteralStringSingle */ .chroma .s1 { color: #f1fa8c }
/* LiteralStringSymbol */ .chroma .ss { color: #f1fa8c }
/* LiteralNumber */ .chroma .m { color: #bd93f9 }
/* LiteralNumberBin */ .chroma .mb { color: #bd93f9 }
/* LiteralNumberFloat */ .chroma .mf { color: #bd93f9 }
/* LiteralNumberHex */ .chroma .mh { color: #bd93f9 }
/* LiteralNumberInteger */ .chroma .mi { color: #bd93f9 }
/* LiteralNumberIntegerLong */ .chroma .il { color: #bd93f9 }
/* LiteralNumberOct */ .chroma .mo { color: #bd93f9 }
/* Operator */ .chroma .o { color: #ff79c6 }
/* OperatorWord */ .chroma .ow { color: #ff79c6 }
/* OperatorReserved */ .chroma .or { color: #ff79c6 }
/* Comment */ .chroma .c { color: #6272a4 }
/* CommentHashbang */ .chroma .ch { color: #6272a4 }
/* CommentMultiline */ .chroma .cm { color: #6272a4 }
/* CommentSingle */ .chroma .c1 { color: #6272a4 }
/* CommentSpecial */ .chroma .cs { color: #6272a4 }
/* CommentPreproc */ .chroma .cp { color: #ff79c6 }
/* CommentPreprocFile */ .chroma .cpf { color: #ff79c6 }
/* GenericDeleted */ .chroma .gd { color: #ff5555 }
/* GenericEmph */ .chroma .ge { text-decoration: underline }
/* GenericHeading */ .chroma .gh { font-weight: bold }
/* GenericInserted */ .chroma .gi { color: #50fa7b; font-weight: bold }
/* GenericOutput */ .chroma .go { color: #44475a }
/* GenericSubheading */ .chroma .gu { font-weight: bold }
/* GenericUnderline */ .chroma .gl { text-decoration: underline }
}
