/******************
    User custom CSS
    ---------------

    In this file you can add your own custom CSS
    It will be loaded last, so you can override any other property.
    Also, it will never be updated. So if you inheritate a core template and just add here some CSS, you'll still benefit of all the updates
*/



/* Claude Code: */



/* Stop automatic hyphenation; wrap whole words instead */
* {
    -webkit-hyphens: manual !important;
    hyphens: manual !important;
}

/* Still let very long strings (URLs, email addresses) break on narrow screens rather than overflow */
body {
    overflow-wrap: break-word;
}




/* ===== Accessible blue colour scheme ===== */
:root {
    --ts-link: #095F99;          /* links, ~6.8:1 on white */
    --ts-link-hover: #074A77;    /* link hover, ~9.3:1 on white */
    --ts-accent: #234880;        /* buttons, controls, ~9.1:1 on white */
    --ts-accent-dark: #1A3660;   /* button hover, focus outlines, ~12:1 on white */
    --bs-primary: #234880;
    --bs-primary-rgb: 35, 72, 128;
}

/* Links in the survey content: #095F99 and underlined */
#outerframeContainer a:not(.btn) {
    color: var(--ts-link) !important;
    text-decoration: underline !important;
}
#outerframeContainer a:not(.btn):hover {
    color: var(--ts-link-hover) !important;
}

/* Primary buttons (Next, Submit, etc.) */
.btn-primary,
.btn-primary:focus,
.btn-primary:active,
.btn-primary.active,
.btn-check:checked + .btn-primary,
.btn-check:active + .btn-primary {
    background-color: var(--ts-accent) !important;
    border-color: var(--ts-accent) !important;
    color: #ffffff !important;
}
.btn-primary:hover,
.btn-check + .btn-primary:hover {
    background-color: var(--ts-accent-dark) !important;
    border-color: var(--ts-accent-dark) !important;
    color: #ffffff !important;
}

/* Radio buttons */
.radio-item input[type=radio]:checked + label::before {
    border-color: var(--ts-accent) !important;
}
.radio-item label::after,
.radio-item input[type=radio]:checked + label::after {
    background-color: var(--ts-accent) !important;
}

/* Checkboxes */
.checkbox-item input[type=checkbox]:checked + label::before {
    border-color: var(--ts-accent) !important;
}
.checkbox-item input[type=checkbox]:checked + label::after {
    color: var(--ts-accent) !important;
}

/* Selected option text */
.radio-item input[type=radio]:checked + label,
.checkbox-item input[type=checkbox]:checked + label {
    color: var(--ts-accent) !important;
}

/* Progress bar */
.progress-bar {
    background-color: var(--ts-accent) !important;
}

/* Clear, visible focus indicators */
.btn:focus-visible,
a:focus-visible {
    outline: 3px solid var(--ts-accent-dark) !important;
    outline-offset: 2px;
}
.form-control:focus,
.form-select:focus {
    border-color: var(--ts-accent) !important;
    box-shadow: 0 0 0 3px rgba(35, 72, 128, 0.35) !important;
}
.radio-item input[type=radio]:focus-visible + label::before,
.checkbox-item input[type=checkbox]:focus-visible + label::before {
    box-shadow: 0 0 0 3px rgba(35, 72, 128, 0.45) !important;
}


/* ===== Arial for headings and body text ===== */
body,
.large-heading,
h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6 {
    font-family: Arial, Helvetica, sans-serif !important;
}

/* ===== Line spacing ===== */
body,
p, li, label,
.form-heading,
.survey-description,
.survey-description span,
.question-text,
.ls-label-question,
.question-help-container,
.question-valid-container {
    line-height: 1.5 !important;
}


/* Headings: a little tighter so multi-line headings still hold together */
h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6,
.large-heading,
.group-title {
    line-height: 1.25 !important;
}

/* ===== Images in survey text ===== */
/* Never let an image be wider than the page */
.survey-description img,
.survey-welcome img,
.question-text img {
    max-width: 100% !important;
    height: auto !important;
}

/* Keep the visual tick but stop screen readers reading the icon font character */
html body .checkbox-item input[type="checkbox"]:checked + label::after,
html body .checkbox-item input[type="radio"]:checked + label::after {
    content: "\EB7A" / "";
}

