/* static/css/xmin.css */

:root {
    /* -- DEFAULT (LIGHT) -- */
    --bg-color: #ffffff;
    --text-color: #333333;
    --heading-color: #111111;
    --link-color: #0000ff;
    --nav-border: #eeeeee;
    --wikilink-color: #d63384; 
    --code-bg: #dedede;
}

/* -- DARK OVERRIDES (Applied to HTML tag) -- */
html.dark-mode {
    --bg-color: #1a1a1a;
    --text-color: #e0e0e0;
    --heading-color: #ffffff;
    --link-color: #ffffff;
    --nav-border: #444444;
    --wikilink-color: #ff80bf;
    --code-bg: #000000;
}

/* -- APPLY TO BODY AND HTML -- */
html, body {
    background-color: var(--bg-color); /* Apply to both to prevent white edges */
    color: var(--text-color);
}

body {
    font-family: Palatino, "Palatino Linotype", serif;
    line-height: 1.6;
    margin-top: 2rem;
    transition: background-color 0.3s, color 0.3s;
}

/* Rest of the CSS remains the same */
h1, h2, h3 { color: var(--heading-color) !important; }

.container-xmin {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.nav-xmin {
    border-bottom: 1px solid var(--nav-border);
    padding-bottom: 1rem;
    margin-bottom: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-xmin a {
    color: var(--text-color);
    text-decoration: none;
    margin-right: 1.5rem;
    font-weight: bold;
}

/* Toggle Button */
#theme-toggle {
    background: none;
    border: 1px solid var(--text-color);
    color: var(--text-color);
    padding: 2px 10px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 0.8rem;
}

a.wikilink {
    color: var(--wikilink-color) !important;
    text-decoration: none;
    border-bottom: 1px dotted var(--wikilink-color);
}

/* Custom Icon Sizing */
.icon-sm {
    width: 1.2em;       /* Roughly the size of text */
    height: 1.2em;
    vertical-align: middle; /* Aligns icon with the text baseline */
    margin-top: -2px;   /* Slight tweak for perfect alignment */
    object-fit: contain; /* Ensures the icon doesn't stretch */
}

/* Optional: Invert icons in dark mode if they are black SVGs */
/* html.dark-mode .icon-sm {
    filter: invert(1); 
} */

/* Add this to the bottom of xmin.css */

/* Profile Links: Inherit the theme color instead of being blue or black */
.profile-link {
    color: var(--link-color);
    text-decoration: none; /* No underline by default */
    display: inline-flex;
    align-items: center;
}

.profile-link:hover {
    text-decoration: underline;
    opacity: 0.8;
}

/* Profile Description: slightly transparent version of the theme color */
.profile-desc {
    color: var(--text-color);
    opacity: 0.8; /* Makes it look "muted" but stays visible in dark mode */
}

/* Ensure Icons invert color in dark mode (if they are black SVGs) */
/* html.dark-mode .icon-sm {
    filter: invert(1);
} */
 /* --- CODE BLOCKS & INLINE CODE --- */

/* 1. Inline Code (e.g. `variable`) */

code {
    /* background-color: var(--code-bg); defined in your :root */
    color: var(--wikilink-color);     /* Use the pink accent for inline code */
    padding: 0.2rem 0.4rem;
    border-radius: 4px;
    font-family: "Menlo", "Monaco", "Consolas", "Courier New", monospace;
    font-size: 0.9em;
}

/* 2. Block Code (The large boxes) */
pre {
    background-color: var(--code-bg);
    padding: 1rem;
    /* border-radius: 8px; */
    overflow-x: auto; /* Adds scrollbar for long lines */
    margin-bottom: 1.5rem;
    /* border: 1px solid var(--nav-border); */
}

/* 3. Code inside Blocks (Reset) */
/* This prevents the inline style from doubling up inside the block */
pre code {
    background-color: transparent;
    color: inherit; /* Use standard text color for blocks */
    padding: 0;
    font-size: 0.95rem;
}

pre {
    border-left: 3px solid var(--wikilink-color);
}

/* #about .row {
  flex-direction: row-reverse;
} */