/* Readable contrast for the admin theme (WCAG AA, 4.5:1 for normal text).
   Same hues as the theme, a little darker; light mode only (dark mode keeps the theme's own colours).
   Loaded after app.min.css in layout/sidebar.blade.php and auth/auth-login.blade.php. */

html[data-bs-theme="light"], html:not([data-bs-theme]) {
    --bs-secondary-color: #5d6b80;           /* muted / help text (was #9ba6b7, 2.3:1) */
    --bs-link-color: #2f7d6d;
    --bs-link-color-rgb: 47, 125, 109;
    --bs-link-hover-color: #24665a;
}

html[data-bs-theme="light"] .btn-primary, html:not([data-bs-theme]) .btn-primary {
    --bs-btn-bg: #308170; --bs-btn-border-color: #308170;          /* teal, white text 4.7:1 (was 2.1:1) */
    --bs-btn-hover-bg: #276b5d; --bs-btn-hover-border-color: #276b5d;
    --bs-btn-active-bg: #215b4f; --bs-btn-active-border-color: #215b4f;
    --bs-btn-disabled-bg: #308170; --bs-btn-disabled-border-color: #308170;
}
html[data-bs-theme="light"] .btn-success, html:not([data-bs-theme]) .btn-success {
    --bs-btn-bg: #218540; --bs-btn-border-color: #218540;          /* green, white text 4.7:1 (was 2.2:1) */
    --bs-btn-hover-bg: #1b6e35; --bs-btn-hover-border-color: #1b6e35;
    --bs-btn-active-bg: #165c2c; --bs-btn-active-border-color: #165c2c;
    --bs-btn-disabled-bg: #218540; --bs-btn-disabled-border-color: #218540;
}
html[data-bs-theme="light"] .btn-outline-danger, html:not([data-bs-theme]) .btn-outline-danger {
    --bs-btn-color: #c81e2c; --bs-btn-border-color: #c81e2c;       /* red text 5.7:1 (was 2.9:1) */
    --bs-btn-hover-bg: #c81e2c; --bs-btn-hover-border-color: #c81e2c;
    --bs-btn-active-bg: #a8192a; --bs-btn-active-border-color: #a8192a;
}

/* Footer line and the user name on the teal top bar */
html[data-bs-theme="light"] .footer { color: #5d6b80; }
html[data-bs-theme="light"] .app-topbar .nav-user .topbar-link,
html[data-bs-theme="light"] .app-topbar .nav-user .topbar-link .my-0 { color: #0d3b33; }

/* Links inside running text are underlined, not told apart by colour alone */
.page-content p a:not(.btn), .page-content .form-text a:not(.btn), .page-content small a:not(.btn) { text-decoration: underline; }

/* Quill editor toolbar: touch targets of at least 28 px with spacing */
/* (higher specificity: quill.snow.css is loaded after this file on some pages) */
html body .ql-toolbar.ql-snow button { width: 32px; height: 32px; margin: 1px; }
html body .ql-toolbar.ql-snow .ql-picker { margin: 1px; }
html body .ql-toolbar.ql-snow .ql-picker-label { min-height: 32px; display: flex; align-items: center; }

/* Phones: the page padding is 10 px but the theme's footer pulls out 12 px each side (2 px sideways scroll) */
@media (max-width: 575.98px) { .page-content > .footer { margin-left: -10px; margin-right: -10px; } }
