/**
 * DisCanVis brand — overrides Bootstrap 5.3 primary (and related tokens).
 * Load immediately after bootstrap.min.css (see Scripts.html).
 */
:root,
[data-bs-theme="light"] {
    --discanvis-brand: #c96d6a;
    --bs-primary: #c96d6a;
    --bs-primary-rgb: 201, 109, 106;
    --bs-blue: #c96d6a;

    /* Subtle surfaces derived from brand */
    --bs-primary-bg-subtle: #f8eceb;
    --bs-primary-border-subtle: #e9c5c3;
    --bs-primary-text-emphasis: #5a2e2c;

    --bs-link-color: #c96d6a;
    --bs-link-hover-color: #a55552;
    --bs-focus-ring-color: rgba(201, 109, 106, 0.35);
}

[data-bs-theme="dark"] {
    --bs-primary: #c96d6a;
    --bs-primary-rgb: 201, 109, 106;
    --bs-blue: #c96d6a;

    --bs-primary-bg-subtle: rgba(201, 109, 106, 0.15);
    --bs-primary-border-subtle: rgba(201, 109, 106, 0.35);
    --bs-primary-text-emphasis: #f0c9c7;

    --bs-link-color: #e8a8a5;
    --bs-link-hover-color: #f5d4d2;
    --bs-focus-ring-color: rgba(201, 109, 106, 0.45);
}

/* Bootstrap 5.3 maps button colours through these custom properties */
.btn-primary {
    --bs-btn-bg: var(--bs-primary);
    --bs-btn-border-color: var(--bs-primary);
    --bs-btn-hover-bg: #b8605d;
    --bs-btn-hover-border-color: #a85653;
    --bs-btn-active-bg: #a85653;
    --bs-btn-active-border-color: #954a47;
    --bs-btn-disabled-bg: #c96d6a;
    --bs-btn-disabled-border-color: #c96d6a;
}

.btn-outline-primary {
    --bs-btn-color: var(--bs-primary);
    --bs-btn-border-color: var(--bs-primary);
    --bs-btn-hover-bg: var(--bs-primary);
    --bs-btn-hover-border-color: var(--bs-primary);
    --bs-btn-hover-color: #fff;
    --bs-btn-active-bg: #a85653;
    --bs-btn-active-border-color: #954a47;
    --bs-btn-active-color: #fff;
}

/*
 * Bootstrap 5.3.x bakes default primary (#0d6efd) into these component scopes;
 * overriding :root --bs-primary alone does not change them.
 */
.nav-pills {
    --bs-nav-pills-link-active-bg: var(--bs-primary);
    --bs-nav-pills-link-active-color: #fff;
}

.pagination {
    --bs-pagination-active-bg: var(--bs-primary);
    --bs-pagination-active-border-color: var(--bs-primary);
    --bs-pagination-focus-box-shadow: 0 0 0 0.25rem rgba(var(--bs-primary-rgb), 0.25);
}
