/*** Erişilebilirlik menüsü ***/
.a11y {
    --a11y-navy: #0b1b40;
    --a11y-navy-2: #16295c;
    --a11y-blue: #355EFC;
    --a11y-card: #ffffff;
    --a11y-surface: #f1f3f8;
    --a11y-line: #dfe3ec;
    --a11y-text: #1b2233;
    --a11y-muted: #5b6478;
    font-family: "Open Sans", Arial, sans-serif;
    line-height: 1.3;
    letter-spacing: normal;
    word-spacing: normal;
    text-align: left;
}

.a11y *,
.a11y *::before,
.a11y *::after {
    box-sizing: border-box;
}

.a11y button {
    font-family: inherit;
}

.a11y :focus-visible {
    outline: 3px solid #ffbf00 !important;
    outline-offset: 2px;
}

.a11y [hidden] {
    display: none !important;
}

/* Açma butonu */
.a11y-toggle {
    position: fixed;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10050;
    width: 52px;
    height: 52px;
    border: 0;
    border-radius: 0 12px 12px 0;
    background: var(--a11y-navy);
    color: #fff;
    font-size: 30px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 14px rgba(1, 26, 65, 0.35);
    cursor: pointer;
    transition: width 0.2s ease, background-color 0.2s ease;
}

.a11y-toggle:hover {
    width: 58px;
    background: var(--a11y-blue);
}

.a11y--right .a11y-toggle {
    left: auto;
    right: 0;
    border-radius: 12px 0 0 12px;
}

/* Panel */
.a11y-panel {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 10060;
    width: 440px;
    max-width: 100vw;
    display: flex;
    flex-direction: column;
    background: var(--a11y-navy);
    color: var(--a11y-text);
    box-shadow: 0 0 40px rgba(1, 26, 65, 0.35);
    font-size: 14px;
}

.a11y--right .a11y-panel {
    left: auto;
    right: 0;
}

.a11y--mini .a11y-panel { zoom: 0.85; }
.a11y--xl .a11y-panel { zoom: 1.2; }

.a11y-panel-head {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 14px 16px;
    color: #fff;
}

.a11y-panel-title {
    flex: 1;
    margin: 0;
    font-size: 15px;
    font-weight: 700;
    color: #fff;
}

.a11y-panel-title kbd {
    font-family: inherit;
    font-size: 11px;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
}

.a11y-icon-btn {
    width: 36px;
    height: 36px;
    flex: 0 0 36px;
    border: 0;
    border-radius: 50%;
    background: #fff;
    color: var(--a11y-navy);
    font-size: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.a11y-icon-btn:hover {
    background: #dfe6ff;
}

.a11y-panel-body {
    flex: 1;
    overflow-y: auto;
    overscroll-behavior: contain;
    background: var(--a11y-surface);
    border-radius: 16px 16px 0 0;
    padding: 12px;
}

.a11y-panel-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 16px;
    color: #fff;
    font-size: 12px;
}

.a11y-panel-foot span {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

/* Panel boyutu */
.a11y-sizes {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
    margin-bottom: 10px;
}

.a11y-sizes button {
    padding: 9px 6px;
    border: 1px solid var(--a11y-line);
    border-radius: 999px;
    background: var(--a11y-card);
    color: var(--a11y-text);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
}

.a11y-sizes button[aria-pressed="true"] {
    background: var(--a11y-navy);
    border-color: var(--a11y-navy);
    color: #fff;
}

/* Profiller */
.a11y-profiles {
    background: var(--a11y-card);
    border: 1px solid var(--a11y-line);
    border-radius: 14px;
    margin-bottom: 12px;
    overflow: hidden;
}

.a11y-profiles-toggle {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px;
    border: 0;
    background: var(--a11y-card);
    color: var(--a11y-text);
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
}

.a11y-profiles-toggle[aria-expanded="true"] {
    background: var(--a11y-navy);
    color: #fff;
}

.a11y-profiles-toggle .a11y-chev {
    margin-left: auto;
    transition: transform 0.2s ease;
}

.a11y-profiles-toggle[aria-expanded="true"] .a11y-chev {
    transform: rotate(180deg);
}

.a11y-profile {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 11px 14px;
    border: 0;
    border-top: 1px solid var(--a11y-line);
    background: var(--a11y-card);
    color: var(--a11y-text);
    font-size: 14px;
    font-weight: 600;
    text-align: left;
    cursor: pointer;
}

.a11y-profile > i {
    width: 22px;
    text-align: center;
    font-size: 17px;
    color: var(--a11y-navy);
}

.a11y-profile-name {
    flex: 1;
}

.a11y-switch {
    position: relative;
    width: 46px;
    height: 26px;
    flex: 0 0 46px;
    border-radius: 999px;
    background: #cfd5e2;
    transition: background-color 0.2s ease;
}

.a11y-switch::after {
    content: "";
    position: absolute;
    top: 3px;
    left: 3px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25);
    transition: transform 0.2s ease;
}

[aria-checked="true"] > .a11y-switch,
[aria-pressed="true"] > .a11y-switch {
    background: var(--a11y-blue);
}

[aria-checked="true"] > .a11y-switch::after,
[aria-pressed="true"] > .a11y-switch::after {
    transform: translateX(20px);
}

.a11y-profile--eco {
    background: #eaf6e1;
}

.a11y-profile--eco > i {
    color: #3f8a12;
}

/* Özellik kartları */
.a11y-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
}

.a11y-card {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    gap: 7px;
    min-height: 112px;
    padding: 12px 6px 10px;
    border: 2px solid var(--a11y-line);
    border-radius: 14px;
    background: var(--a11y-card);
    color: var(--a11y-text);
    font-size: 13px;
    font-weight: 600;
    line-height: 1.2;
    text-align: center;
    cursor: pointer;
    transition: border-color 0.15s ease, background-color 0.15s ease;
}

.a11y-card:hover {
    border-color: #b9c4e6;
}

.a11y-card-icon {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--a11y-line);
    border-radius: 12px;
    background: #fff;
    color: var(--a11y-navy);
    font-size: 19px;
}

.a11y-card-level {
    min-height: 14px;
    font-size: 11px;
    font-weight: 600;
    color: var(--a11y-blue);
}

.a11y-dots {
    display: flex;
    gap: 4px;
    margin-top: auto;
}

.a11y-dots span {
    width: 16px;
    height: 4px;
    border-radius: 2px;
    background: var(--a11y-line);
}

.a11y-dots span.on {
    background: var(--a11y-blue);
}

.a11y-card[aria-pressed="true"] {
    border-color: var(--a11y-blue);
    background: #eef2ff;
}

.a11y-card[aria-pressed="true"] .a11y-card-icon {
    background: var(--a11y-blue);
    border-color: var(--a11y-blue);
    color: #fff;
}

.a11y-card:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.a11y-actions {
    display: grid;
    gap: 8px;
    margin-top: 12px;
}

.a11y-reset {
    width: 100%;
    padding: 13px;
    border: 0;
    border-radius: 999px;
    background: var(--a11y-navy);
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
}

.a11y-row-switch {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 14px;
    border: 1px solid var(--a11y-line);
    border-radius: 999px;
    background: var(--a11y-card);
    color: var(--a11y-text);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}

.a11y-sr-only {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
    clip: rect(0 0 0 0) !important;
    white-space: nowrap !important;
}

.a11y-toast {
    position: fixed;
    left: 50%;
    bottom: 24px;
    transform: translateX(-50%);
    z-index: 10090;
    max-width: calc(100vw - 32px);
    padding: 12px 18px;
    border-radius: 12px;
    background: var(--a11y-navy);
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

/* Okuma maskesi, ayracı, mavi ışık, büyüteç */
.a11y-overlay {
    position: fixed;
    left: 0;
    right: 0;
    pointer-events: none;
    z-index: 10040;
}

.a11y-mask-top { top: 0; background: rgba(0, 0, 0, 0.65); }
.a11y-mask-bottom { bottom: 0; background: rgba(0, 0, 0, 0.65); }

.a11y-guide {
    height: 12px;
    background: #ffbf00;
    border-top: 3px solid #0b1b40;
    border-bottom: 3px solid #0b1b40;
    opacity: 0.9;
}

.a11y-bluelight {
    top: 0;
    bottom: 0;
    background: rgb(255, 150, 20);
    mix-blend-mode: multiply;
}

.a11y-tooltip {
    position: fixed;
    z-index: 10080;
    max-width: min(520px, calc(100vw - 24px));
    padding: 12px 16px;
    border-radius: 10px;
    background: #0b1b40;
    color: #fff;
    font-size: 26px;
    line-height: 1.35;
    font-weight: 600;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
    pointer-events: none;
    word-break: break-word;
}

.a11y-tooltip--small {
    font-size: 15px;
}

/* Sayfa yapısı penceresi */
.a11y-dialog-backdrop {
    position: fixed;
    inset: 0;
    z-index: 10070;
    background: rgba(1, 12, 33, 0.55);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
}

.a11y-dialog {
    width: 560px;
    max-width: 100%;
    max-height: calc(100vh - 32px);
    display: flex;
    flex-direction: column;
    background: #fff;
    color: var(--a11y-text);
    border-radius: 16px;
    overflow: hidden;
    font-size: 14px;
}

.a11y-dialog-head {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 16px;
    background: var(--a11y-navy);
    color: #fff;
}

.a11y-dialog-head h2 {
    flex: 1;
    margin: 0;
    font-size: 17px;
    font-weight: 700;
    color: #fff;
}

.a11y-tabs {
    display: flex;
    gap: 6px;
    padding: 10px 12px;
    border-bottom: 1px solid var(--a11y-line);
}

.a11y-tabs button {
    flex: 1;
    padding: 9px 6px;
    border: 1px solid var(--a11y-line);
    border-radius: 999px;
    background: #fff;
    color: var(--a11y-text);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
}

.a11y-tabs button[aria-selected="true"] {
    background: var(--a11y-navy);
    border-color: var(--a11y-navy);
    color: #fff;
}

.a11y-structure-list {
    list-style: none;
    margin: 0;
    padding: 8px 12px 14px;
    overflow-y: auto;
}

.a11y-structure-list li + li {
    border-top: 1px solid var(--a11y-surface);
}

.a11y-structure-list button {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 6px;
    border: 0;
    background: none;
    color: var(--a11y-text);
    font-size: 14px;
    text-align: left;
    cursor: pointer;
}

.a11y-structure-list button:hover {
    background: var(--a11y-surface);
}

.a11y-structure-tag {
    flex: 0 0 auto;
    min-width: 34px;
    padding: 2px 6px;
    border-radius: 6px;
    background: #dfe6ff;
    color: var(--a11y-navy);
    font-size: 11px;
    font-weight: 700;
    text-align: center;
}

.a11y-structure-empty {
    padding: 16px;
    color: var(--a11y-muted);
}

.a11y-target-flash {
    outline: 4px solid #ffbf00 !important;
    outline-offset: 4px !important;
}

@media (max-width: 576px) {
    .a11y-toggle {
        width: 44px;
        height: 44px;
        font-size: 26px;
    }

    .a11y-toggle:hover {
        width: 44px;
    }

    .a11y-panel {
        top: auto;
        width: 100%;
        height: 88vh;
        border-radius: 16px 16px 0 0;
    }

    .a11y-panel-head {
        padding: 12px;
    }

    .a11y-panel-title kbd {
        display: none;
    }

    .a11y-grid {
        gap: 6px;
    }

    .a11y-card {
        min-height: 104px;
        font-size: 12px;
    }

    .a11y-tooltip {
        font-size: 20px;
    }
}

@media (max-width: 340px) {
    .a11y-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/*** Uygulanan ayarlar (menünün kendisi hariç) ***/

/* Filtreler tek bir filter özelliğinde birleşir */
html.a11y-f-inv { --a11y-f-inv: invert(1) hue-rotate(180deg); }
html.a11y-sat-1 { --a11y-f-sat: saturate(0.5); }
html.a11y-sat-2 { --a11y-f-sat: saturate(2); }
html.a11y-sat-3 { --a11y-f-sat: grayscale(1); }

html.a11y-f-inv,
html.a11y-sat-1,
html.a11y-sat-2,
html.a11y-sat-3 {
    filter: var(--a11y-f-inv, ) var(--a11y-f-sat, );
}

html.a11y-f-inv img,
html.a11y-f-inv video,
html.a11y-f-inv iframe,
html.a11y-f-inv [style*="background-image"] {
    filter: invert(1) hue-rotate(180deg);
}

/* Metin boyutu */
html.a11y-fs-1 { font-size: 112.5%; }
html.a11y-fs-2 { font-size: 125%; }
html.a11y-fs-3 { font-size: 137.5%; }
html.a11y-fs-4 { font-size: 150%; }

/* Karanlık mod */
html.a11y-dark,
html.a11y-dark body {
    background-color: #121418 !important;
}

html.a11y-dark body *:not(.a11y, .a11y *, img, video, iframe, svg, path) {
    background-color: transparent !important;
    color: #e4e6eb !important;
    border-color: #3a3f4b !important;
    box-shadow: none !important;
}

html.a11y-dark body a:not(.a11y *) {
    color: #8ab4ff !important;
}

html.a11y-dark #topbar,
html.a11y-dark .dropdown-menu,
html.a11y-dark .navbar-collapse,
html.a11y-dark .modal-content {
    background-color: #1c1f26 !important;
}

/* Kontrast: koyu / açık */
html.a11y-contrast-1,
html.a11y-contrast-1 body {
    background-color: #000 !important;
}

html.a11y-contrast-1 body *:not(.a11y, .a11y *, img, video, iframe, svg, path) {
    background-color: transparent !important;
    color: #fff !important;
    border-color: #fff !important;
    text-shadow: none !important;
    box-shadow: none !important;
}

html.a11y-contrast-1 body a:not(.a11y *),
html.a11y-contrast-1 body a:not(.a11y *) * {
    color: #ffeb3b !important;
}

html.a11y-contrast-1 #topbar,
html.a11y-contrast-1 .dropdown-menu,
html.a11y-contrast-1 .navbar-collapse,
html.a11y-contrast-1 .modal-content {
    background-color: #000 !important;
}

html.a11y-contrast-2,
html.a11y-contrast-2 body {
    background-color: #fff !important;
}

html.a11y-contrast-2 body *:not(.a11y, .a11y *, img, video, iframe, svg, path) {
    background-color: transparent !important;
    color: #000 !important;
    border-color: #000 !important;
    text-shadow: none !important;
    box-shadow: none !important;
}

html.a11y-contrast-2 body a:not(.a11y *),
html.a11y-contrast-2 body a:not(.a11y *) * {
    color: #0000c8 !important;
}

html.a11y-contrast-2 #topbar,
html.a11y-contrast-2 .dropdown-menu,
html.a11y-contrast-2 .navbar-collapse,
html.a11y-contrast-2 .modal-content {
    background-color: #fff !important;
}

/* Metin hizalama */
html.a11y-align-1 body *:not(.a11y, .a11y *) { text-align: left !important; }
html.a11y-align-2 body *:not(.a11y, .a11y *) { text-align: center !important; }
html.a11y-align-3 body *:not(.a11y, .a11y *) { text-align: right !important; }

/* Satır yüksekliği */
html.a11y-lh-1 body *:not(.a11y, .a11y *) { line-height: 1.6 !important; }
html.a11y-lh-2 body *:not(.a11y, .a11y *) { line-height: 1.9 !important; }
html.a11y-lh-3 body *:not(.a11y, .a11y *) { line-height: 2.2 !important; }

/* Harf boşluğu */
html.a11y-ls-1 body *:not(.a11y, .a11y *) { letter-spacing: 0.05em !important; word-spacing: 0.1em !important; }
html.a11y-ls-2 body *:not(.a11y, .a11y *) { letter-spacing: 0.1em !important; word-spacing: 0.2em !important; }
html.a11y-ls-3 body *:not(.a11y, .a11y *) { letter-spacing: 0.15em !important; word-spacing: 0.3em !important; }

/* Okunabilir / disleksi dostu yazı tipi */
html.a11y-font-1 body *:not(.a11y, .a11y *, i, [class*="fa-"]) {
    font-family: Verdana, Tahoma, Arial, sans-serif !important;
}

html.a11y-font-2 body *:not(.a11y, .a11y *, i, [class*="fa-"]) {
    font-family: "OpenDyslexicRegular", Verdana, Arial, sans-serif !important;
}

/* Başlıkları göster */
html.a11y-headings body :is(h1, h2, h3, h4, h5, h6):not(.a11y *) {
    outline: 2px dashed #355EFC !important;
    outline-offset: 3px;
}

html.a11y-headings body :is(h1, h2, h3, h4, h5, h6):not(.a11y *)::before {
    display: inline-block;
    margin-right: 8px;
    padding: 1px 6px;
    border-radius: 4px;
    background: #355EFC;
    color: #fff;
    font: 700 12px/1.4 Arial, sans-serif;
    letter-spacing: 0;
    vertical-align: middle;
}

html.a11y-headings body h1:not(.a11y *)::before { content: "H1"; }
html.a11y-headings body h2:not(.a11y *)::before { content: "H2"; }
html.a11y-headings body h3:not(.a11y *)::before { content: "H3"; }
html.a11y-headings body h4:not(.a11y *)::before { content: "H4"; }
html.a11y-headings body h5:not(.a11y *)::before { content: "H5"; }
html.a11y-headings body h6:not(.a11y *)::before { content: "H6"; }

/* Bağlantı seçimi */
html.a11y-links body a:not(.a11y *) {
    text-decoration: underline !important;
    text-underline-offset: 3px;
    outline: 2px dashed #ffbf00 !important;
    outline-offset: 2px;
}

/* Alternatif metin: açıklaması olmayan görselleri işaretle */
html.a11y-alt body img:not(.a11y *):not([alt]),
html.a11y-alt body img:not(.a11y *)[alt=""] {
    outline: 3px dashed #e11d48 !important;
    outline-offset: -3px;
}

/* Resimleri gizle — anasayfadaki buton görselleri (Balkart, Otobüs vb.) buton oldukları için gizlenmez */
html.a11y-hideimg body :is(img, picture, video, figure svg):not(.a11y *, #button-bar-sabit *, #button-bar-mobile *) {
    visibility: hidden !important;
}

html.a11y-hideimg body *:not(.a11y, .a11y *) {
    background-image: none !important;
}

/* Animasyonları durdur */
html.a11y-motion *,
html.a11y-motion *::before,
html.a11y-motion *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
}

/* İmleç */
html.a11y-cursor-1,
html.a11y-cursor-1 * {
    cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='48' height='48' viewBox='0 0 48 48'%3E%3Cpath d='M6 3 L6 40 L15 31 L22 46 L29 43 L22 28 L35 28 Z' fill='%23000' stroke='%23fff' stroke-width='3' stroke-linejoin='round'/%3E%3C/svg%3E") 6 3, auto !important;
}

html.a11y-cursor-2,
html.a11y-cursor-2 * {
    cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='48' height='48' viewBox='0 0 48 48'%3E%3Cpath d='M6 3 L6 40 L15 31 L22 46 L29 43 L22 28 L35 28 Z' fill='%23fff' stroke='%23000' stroke-width='3' stroke-linejoin='round'/%3E%3C/svg%3E") 6 3, auto !important;
}
