/* Barrierefreiheit: Darstellungs-Einstellungen (Klassen auf <html>, gesetzt von a11y.js) */

/* ---------- Button links unten (ueber dem Favoriten-Button) ---------- */
.a11yopener button {
    display: block;
    z-index: 1001;
    position: fixed;
    left: 20px;
    bottom: 90px;
    width: 3em;
    height: 3em;
    margin: 0;
    padding: 0;
    border: none;
    border-radius: 50%;
    background: #aaa;
    color: #fff;
    font-size: 1em;
    line-height: 1em;
    text-align: center;
    cursor: pointer;
    box-sizing: border-box;
}
.a11yopener button .fa {
    font-size: 1.4em;
}
.a11yopener button:hover, .a11yopener button:focus {
    background: #888;
}
.a11yopener button.a11y_on {
    background: #00acab;
}

/* ---------- Panel ---------- */
.a11ypanel {
    z-index: 1002;
    position: fixed;
    left: 20px;
    bottom: 160px;
    width: 20em;
    max-width: calc(100vw - 40px);
    max-height: calc(100vh - 180px);
    overflow-y: auto;
    padding: 12px 14px 14px;
    background: #1a1a1a;
    color: #ddd;
    border: 1px solid #3a3a3a;
    border-radius: 6px;
    box-shadow: rgba(0, 0, 0, 0.5) 0 5px 20px;
    text-align: left;
}
.a11ypanel[hidden] {
    display: none;
}
.a11ypanel h2 {
    margin: 0 0 10px;
    padding: 0;
    font-size: 1.1em;
    color: #fff;
    background: none;
}
.a11ypanel fieldset {
    margin: 0 0 10px;
    padding: 0;
    border: 0;
}
.a11ypanel legend {
    float: left;   /* Legende nicht auf die Rahmenlinie setzen */
    width: 100%;
    margin: 0 0 6px;
    padding: 0;
    border: 0;
    font-size: 0.9em;
    font-weight: bold;
    color: #ccc;
}
.a11ypanel fieldset + fieldset {
    border-top: 1px solid #3a3a3a;
    padding-top: 10px;
}
.a11ypanel label.citychip {
    padding: 2px 12px;
    margin: 0 6px 6px 0;
    font-weight: normal;
    cursor: pointer;
    white-space: nowrap;
}
/* Radios wie die Chip-Checkboxen verstecken (fokussierbar bleiben) */
input[type=radio].chipcheckbox {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    border: 0;
    clip: rect(0, 0, 0, 0);
    overflow: hidden;
}
.a11ypanel .a11ybuttons {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 4px;
}
.a11ypanel .a11ybuttons button {
    width: auto;
    margin: 0;
    padding: 2px 12px;
    border: 1px solid #555;
    border-radius: 12px;
    background: none;
    color: #ccc;
    font-size: 0.9em;
    line-height: 1.5;
    cursor: pointer;
}
.a11ypanel .a11ybuttons button:hover, .a11ypanel .a11ybuttons button:focus {
    border-color: #999;
    color: #fff;
}

/* ---------- Schriftgroesse (alles im Frontend ist rem/em-basiert) ---------- */
html.a11y-font-1 {
    font-size: 125%;
}
html.a11y-font-2 {
    font-size: 150%;
}
/* die runden schwebenden Buttons haben feste Pixel-Abstaende -> Groesse nicht mitskalieren */
html.a11y-font-1 .favopener button, html.a11y-font-2 .favopener button,
html.a11y-font-1 .cat_talk button, html.a11y-font-2 .cat_talk button,
html.a11y-font-1 .cat_onthestreets button, html.a11y-font-2 .cat_onthestreets button,
html.a11y-font-1 .cat_concert button, html.a11y-font-2 .cat_concert button,
html.a11y-font-1 .a11yopener button, html.a11y-font-2 .a11yopener button {
    font-size: 16px;
}

/* ---------- Kontrast erhoehen ---------- */
html.a11y-contrast #content {
    color: #111;
}
html.a11y-contrast .navbar {
    color: #eee;
}
html.a11y-contrast .post,
html.a11y-contrast .post *:not(.fa) {
    color: #111 !important;
}
/* eingebettete Beschreibungen bringen teils eigene (dunkle) Hintergruende mit */
html.a11y-contrast .post *:not(img) {
    background-color: transparent !important;
}
html.a11y-contrast .sr-only-focusable:focus {
    color: #111;
}
html.a11y-contrast .post .post_content a:not(.fa),
html.a11y-contrast .bottomline a {
    color: #0b3d91 !important;
}
/* eingeklappte Beschreibung nicht mehr halbtransparent */
html.a11y-contrast input[type=checkbox] ~ ul {
    opacity: 1;
}
html.a11y-contrast input[type=checkbox]:not(.chipcheckbox) + label:before {
    border-left-color: #333;
}
html.a11y-contrast label .expandhint,
html.a11y-contrast .post_fav {
    color: #333 !important;
}
html.a11y-contrast .navbar {
    opacity: 1;
}
html.a11y-contrast .navbar .citychip,
html.a11y-contrast .a11ypanel .citychip {
    border-color: #aaa;
    color: #fff !important;
}
/* helle Chip-Variante (Staedte-Suche auf weissem Grund) */
html.a11y-contrast .citysearchoption label.citychip {
    border-color: #555;
    color: #111 !important;
}
html.a11y-contrast .citysearchoption .chipcheckbox:checked + label.citychip {
    border-color: #007a79;
    background-color: rgba(0, 172, 171, 0.15);
    color: #111 !important;
}
html.a11y-contrast .citysearchsubmit {
    background: #555 !important;
    color: #fff !important;
}
html.a11y-contrast .search-field-input::placeholder {
    color: #444;
}
html.a11y-contrast .favopener button,
html.a11y-contrast .a11yopener button:not(.a11y_on) {
    background: #555;
}
html.a11y-contrast .a11ypanel,
html.a11y-contrast .a11ypanel legend {
    color: #fff;
}
html.a11y-contrast a:focus,
html.a11y-contrast button:focus,
html.a11y-contrast input:focus {
    outline: 3px solid #f0b400;
    outline-offset: 2px;
}

/* ---------- Links unterstreichen ---------- */
html.a11y-links #content a:not(.citychip) {
    text-decoration: underline !important;
}

/* ---------- Mehr Abstand (WCAG 1.4.12 Textabstaende) ---------- */
html.a11y-spacing #content p,
html.a11y-spacing #content li,
html.a11y-spacing #content .post_content,
html.a11y-spacing #content .post_contentblock,
html.a11y-spacing #content .post_subtitle {
    line-height: 1.6 !important;
    letter-spacing: 0.05em;
    word-spacing: 0.12em;
}
html.a11y-spacing #content p {
    margin-bottom: 1em;
}

/* ---------- Animationen aus ---------- */
html.a11y-motion *,
html.a11y-motion *:before,
html.a11y-motion *:after {
    transition: none !important;
    animation: none !important;
    scroll-behavior: auto !important;
}
