/*
 * Accessibility overrides (WCAG 2.2 AA). Loaded after style.css / responsive.css.
 * style.css is served from the CDN, so fixes live here rather than in that file.
 */

/* --- 2.4.1 Skip link --------------------------------------------------- */
.skip-link {
	position: absolute;
	left: -9999px;
	top: 0;
	z-index: 10000;
	padding: 10px 16px;
	background: #000;
	color: #fff !important;
	font-weight: 600;
}
.skip-link:focus {
	left: 8px;
	top: 8px;
}
#main-content:focus {
	outline: none;
}

/* --- 2.4.7 Visible keyboard focus ---------------------------------------
 * style.css sets "a:focus, .btn:focus { outline: none }". Restore a ring for
 * keyboard users only (:focus-visible), with a white halo so it shows on both
 * the light page and the dark nav bar. */
a:focus-visible,
button:focus-visible,
.btn:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible,
[tabindex]:not([tabindex="-1"]):focus-visible,
[role="button"]:focus-visible {
	outline: 3px solid #1a5fd0 !important;
	outline-offset: 2px !important;
	box-shadow: 0 0 0 5px #fff !important;
}

/* --- 1.4.3 Text contrast (min 4.5:1 on #fff and on the #ececec page) ---- */
.ad-title,
.ad-group,
.ad-size,
#search_select,
#search_select_xs,
#comments_login_register,
.card-sub,
.blog-body,
.request-sub,
.tag-counter,
.tag-item i,
.comments-list .comment-item .comment-info .comment-user-info .comment-add-time,
.comments-section .comment-reply a,
.comments-section .comment-reply a i,
.feed-blog div,
.fileupload-theme-dragdrop .fileupload-input {
	color: #5c5c5c;
}
.text-muted,
.form-horizontal .text-muted {
	color: #5c5c5c !important;
}
.text-danger {
	color: #b02a37 !important;
}

/* Brand red buttons: #f54a5d with white text is 3.5:1; #d42a3f is 5.0:1. */
.btn-primary,
.btn-primary:not(:disabled):not(.disabled):active,
.list-group-item.active {
	background-color: #d42a3f !important;
	border-color: #d42a3f !important;
	color: #fff !important;
}
.btn-primary:hover,
.btn-primary:focus {
	background-color: #b5233a !important;
	border-color: #b5233a !important;
}

/* --- Headings re-levelled for 1.3.1 but kept at their old look --------- */
.a11y-h1 {
	font-size: 18px;
	color: #000;
	font-weight: 500;
	line-height: 1.2;
	margin-bottom: .5rem;
	font-family: open sans, helvetica neue, Helvetica, Arial, sans-serif;
}
.well-filters .a11y-h1 {
	padding: 10px 0;
	margin: 0;
}
.footer-container h2.footer-heading {
	color: #fff;
	font-size: 18px;
}
.sidebar-heading {
	font-size: 1.25rem;
}

/* 1.4.1: links inside running text must not rely on colour alone */
.form-text a,
.card-text a,
.blog-body a,
#comments_login_register a {
	text-decoration: underline;
}
