/* DBMN Brand Tokens — single source of truth */

@font-face {
    font-family: 'Cooper Black';
    src: url('/fonts/Cooper-Black.woff2') format('woff2');
    font-weight: 900;
    font-style: normal;
    font-display: swap;
}

:root {
    --brand-font-heading: 'Cooper Black', Georgia, serif;
    --brand-font-body: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    /* The site's colours: Retro 82 until a theme is picked. assets/js/site-theme.js puts the
     * picked theme's colours (exported from the app: assets/js/dbmn-themes.js) over these. */
    --brand-bg-start: #05182e;
    --brand-bg-end: #05182e;
    --brand-accent: #faa968;
    --brand-accent-text: #05182e;
    --brand-text: #f6dcac;
    --brand-text-body: #dec89f;
    --brand-text-muted: #71938a;
    --brand-surface: #112234;
    --brand-surface-strong: #1d2c3b;
    --brand-border: #293541;
    --brand-link: #f6dcac;
    --brand-link-underline: #656660;
    --brand-success: #028391;
    --brand-info: #3f8f8a;
    --brand-warning: #faa968;
    --brand-danger: #f85525;
    color-scheme: dark;
}

/* The palette button, in a page's nav bar or header (the picker itself: assets/css/theme-picker.css) */
.site-theme-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    padding: 0;
    border: 1px solid transparent;
    border-radius: 6px;
    background: transparent;
    color: var(--brand-text-muted);
    cursor: pointer;
}
.site-theme-btn[hidden] {
    display: none;
}
.site-theme-btn:hover {
    color: var(--brand-text);
    background: var(--brand-surface);
}
.site-theme-btn svg {
    width: 20px;
    height: 20px;
}

/* Default link styling — readable on the page's background without the
 * browser's old-school royal blue. Any page-specific or scoped rule (nav
 * bars, footers, buttons) still wins via specificity. */
a {
    color: var(--brand-link);
    text-decoration: underline;
    text-decoration-color: var(--brand-link-underline);
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
    transition: text-decoration-color 0.15s ease;
}

a:hover {
    text-decoration-color: var(--brand-link);
}

/* DBMN icon tokens — `{icon:<role>}` in docs/lessons becomes an inline SVG
 * taken from the extension's own icon registry (see _plugins/dbmn_icons.rb).
 * Sized to the surrounding text and coloured by it, so "click {icon:x}"
 * reads like a glyph in the sentence, not a picture dropped into it. */
.dbmn-icon {
    display: inline-block;
    width: 1.1em;
    height: 1.1em;
    vertical-align: -0.2em;
    margin: 0 0.1em;
    color: inherit;
}
.dbmn-icon svg {
    display: block;
    width: 100%;
    height: 100%;
}
