/*
 * WCAG 2.1 AA adjustments – Theater am Spittelberg (+ Rosenstolz, same templates)
 * Based on the client's "To-do Developer" and "Change Log – Mobile (WCAG 2.1 AA)", 1 Dec 2026.
 *
 * Loaded after the theme CSS (fileadmin/templates/tas/css/*) and before rosenstolz.css.
 * Layout, spacing, images and typeface stay unchanged – only colours, font sizes,
 * focus indication, link underlines and the slider controls change.
 */

/* ---------------------------------------------------------------------------
 * Utilities
 * ------------------------------------------------------------------------- */
.visually-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

/* Skip link (8) – visible only when focused */
.skip-link {
    position: absolute;
    left: 8px;
    top: -100px;
    z-index: 100000000;
    padding: 10px 16px;
    background: #AA1317;
    color: #FFFFFF;
    font: 600 16px/24px 'Montserrat', sans-serif;
    text-decoration: underline;
    border-radius: 0 0 5px 5px;
}
.skip-link:focus {
    position: fixed;
    top: 0;
    outline: 3px solid #1A1A1A;
    outline-offset: 2px;
}
#main-content:focus {
    outline: none;
}

/* ---------------------------------------------------------------------------
 * 1. Colours
 * ------------------------------------------------------------------------- */
/* Main navigation + dropdown: #C61619 -> #AA1317 (4.84:1 on #F2CD51) */
#p .main-menu-outer li a span,
#p .main-menu-outer li a {
    color: #AA1317;
}

/* Programme + Kids list: event titles #FF9933 -> #B35900 (4.83:1 on white) */
#p .month_events .listprogramminfo .listprogrammheader a {
    color: #B35900;
}

/* Mobile top bar, page title: #6D7174 -> #5F6366 (4.99:1 on #E9E9E9) */
.wb-bar .wb-label .lbl-title {
    color: #5F6366;
}

/* Mobile menu panel: items #C61619 -> #AA1317 (4.84:1 on #F2CD51) */
.wb-content-wrapper .wb-content.cnt-menu .wb-responsive-menu li a {
    color: #AA1317;
}

/* ---------------------------------------------------------------------------
 * 2. Font sizes (15 px -> 16 px, nothing below 14 px, line height >= 1.5)
 * ------------------------------------------------------------------------- */
body {
    font-size: 16px;
}
#p p {
    font-size: 16px;
}
#p .main-menu-outer li a span,
#p .main-menu-outer li a {
    font-size: 16px;
}
#p .detail_events .listprogrammtickets a,
.listprogrammtickets {
    font-size: 16px;
    line-height: 24px;
}
#p .detail_events .listtotop a {
    font-size: 16px;
}
#p .detail_events .listprogrammdatetime {
    font-size: 14px;
}

/* Breadcrumb 12 -> 14 px */
#p .breadcrump-inner li a,
#p .breadcrump-inner li span {
    font-size: 14px;
    line-height: 21px;
}

/* Footer: top 14 px (line height 1.5), bottom 11 -> 14 px */
#p .footer-top-inner p {
    line-height: 21px;
}
#p .footer-bottom-inner p,
#p .footer-bottom-inner a {
    font-size: 14px;
}

/* Remaining small text */
#p .csc-textpic-caption,
#p figcaption {
    font-size: 14px;
    line-height: 21px;
}
.d h5,
.d h5 a,
#p .content-outer button,
#p .content-outer input.powermail_submit,
#p .content-outer input.subscribe-submit,
#p .tx-felogin-pi1 .submit-form input,
#p input.sword {
    font-size: 14px;
}

@media all and (max-width: 875px) {
    .month_events .listprogrammsubheader p,
    .month_events .listprogramminfo .listprogrammheader a {
        font-size: 16px !important;
    }
}
@media all and (max-width: 590px) {
    .month_events .listprogramminfo .listprogrammheader a,
    .month_events .listprogrammsubheader p {
        font-size: 16px !important;
    }
}
@media all and (max-width: 578px) {
    h5,
    h5 a {
        font-size: 16px !important;
    }
}
@media all and (max-width: 415px) {
    h5,
    h5 a {
        font-size: 14px !important;
    }
}
@media all and (max-width: 512px) {
    .signupform p {
        font-size: 16px !important;
    }
}
@media all and (max-width: 419px) {
    .signupform label {
        font-size: 14px !important;
    }
}

/* ---------------------------------------------------------------------------
 * 7. Structure: month headings in the programme list are h2 now (were h1) –
 *    same look as the former "#p .month_events h1" + "#p h1".
 * ------------------------------------------------------------------------- */
#p .month_events h2.month-heading {
    font-family: 'Montserrat';
    font-size: 35px;
    line-height: 35px;
    font-weight: bold;
    color: #AD2126;
    text-transform: uppercase;
    margin-top: 0;
    margin-bottom: 16px;
}

/* ---------------------------------------------------------------------------
 * 3. Links in body text are underlined; standalone links are not.
 *    wcag.js marks links that are the only content of their paragraph/list item
 *    with .link-standalone.
 * ------------------------------------------------------------------------- */
#p main p a,
#p main li a,
#p main td a,
#p main dd a,
#p .footer-top-inner p a {
    text-decoration: underline;
    text-underline-offset: 2px;
}
#p main a.link-standalone,
#p main .listprogrammheader a,
#p main .month_link a,
#p main .listprogrammtickets a,
#p main .listtotop a,
#p main .spittelberg a,
#p main a.teaser {
    text-decoration: none;
}
#p main a.link-standalone:hover,
#p main .listprogrammheader a:hover {
    text-decoration: underline;
}

/* ---------------------------------------------------------------------------
 * 4. Slider (home page): dots, pause/play button, keyboard-reachable arrows
 *    Markup for .slider-controls is created in quickstart_main.js.
 * ------------------------------------------------------------------------- */
/* Note: #slider must NOT get position:relative – the arrows are positioned against the
   full-width .keyvisual-placeholder-inner (at the browser edges), as before. The controls
   below are centred against the same container, which has the slider's height. */
#slider .slider-controls {
    position: absolute;
    bottom: 7px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 20;
    display: flex;
    align-items: center;
    gap: 6px;
    line-height: 0;
    opacity: 0;
    transition: opacity 150ms linear;
}
.main_slider:hover #slider .slider-controls,
#slider .slider-controls:focus-within {
    opacity: 1;
}
#slider .slider-dots {
    display: flex;
    align-items: center;
    padding: 5px;
    background: #DADADA;
    border-radius: 5px;
}
#slider .slider-dots .owl-dot {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 17px;
    height: 17px;
    margin: 0;
    padding: 0;
    border: 0;
    background: none;
    cursor: pointer;
}
#slider .slider-dots .owl-dot span {
    display: block;
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: #767676;
}
#slider .slider-dots .owl-dot.active span {
    width: 13px;
    height: 13px;
    background: #C6161A;
}
#slider .slider-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 5px;
    background: #DADADA;
    color: #1A1A1A;
    cursor: pointer;
}
#slider .slider-toggle svg {
    width: 12px;
    height: 12px;
    fill: currentColor;
}
#slider .slider-toggle .icon-play,
#slider .slider-toggle.is-paused .icon-pause {
    display: none;
}
#slider .slider-toggle.is-paused .icon-play {
    display: block;
}

/* Arrows: hidden until hover as before, but reachable (and visible) via keyboard */
.owl-theme .owl-nav {
    display: block;
    opacity: 0;
    transition: opacity 150ms linear;
}
.main_slider:hover .owl-theme .owl-nav,
.owl-theme .owl-nav:focus-within {
    opacity: 1;
}

/* Touch / mobile: only the pause button, bottom left (8 px), no dots/arrows (as before) */
@media (hover: none) {
    #slider .slider-controls {
        opacity: 1;
        left: 8px;
        bottom: 8px;
        transform: none;
    }
    #slider .slider-dots {
        display: none;
    }
    .owl-theme .owl-nav {
        display: none;
    }
}

/* ---------------------------------------------------------------------------
 * 5. Visible focus (replaces outline: 0 / outline: none of the theme)
 *    #1A1A1A on light backgrounds (>= 11:1), white on dark backgrounds.
 * ------------------------------------------------------------------------- */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible,
[tabindex]:not([tabindex="-1"]):focus-visible,
.signupform input:focus-visible,
.signupform textarea:focus-visible,
.frame-signupform input:focus-visible,
.frame-signupform textarea:focus-visible {
    outline: 3px solid #1A1A1A !important;
    outline-offset: 2px;
}
#slider button:focus-visible {
    outline-offset: -3px;
}
#p .footer-outer a:focus-visible,
#p .footer-outer button:focus-visible {
    outline-color: #FFFFFF !important;
}

/* Cookie banner */
.cookie-consent-container a:focus-visible,
.cookie-consent-container .show-details:focus-visible,
.cookie-consent-container .buttons .btn:focus-visible,
.cookie-consent-container .consent-modal .footer-links a:focus-visible,
.cookie-consent-container .label input:focus-visible ~ .checkmark {
    outline: 3px solid #1A1A1A !important;
    outline-offset: 2px;
}

/* Desktop dropdown opens on keyboard focus, not only on hover */
#p .main-menu-outer li:focus-within > .level-2,
#p .main-menu-outer .level-2 > li:focus-within > .level-3 {
    display: block;
}
#p .main-menu-outer li.wcag-menu-closed > .level-2,
#p .main-menu-outer li.wcag-menu-closed > .level-3 {
    display: none !important;
}
#p .main-menu-outer ul.level-2 > li:focus-within,
#p .main-menu-outer ul.level-3 > li:focus-within {
    background: #C6161A;
}
#p .main-menu-outer ul.level-2 > li:focus-within > a > span,
#p .main-menu-outer ul.level-3 > li:focus-within > a > span,
#p .main-menu-outer .main-menu .level-3 > li:focus-within > a {
    color: #F9E2A3;
}
#p .main-menu-outer .level-2 a:focus-visible,
#p .main-menu-outer .level-3 a:focus-visible {
    outline-color: #F9E2A3 !important;
    outline-offset: -3px;
}

/* ---------------------------------------------------------------------------
 * Mobile navigation: hamburger + submenu chevrons are real <button>s now (same look)
 * ------------------------------------------------------------------------- */
.wb-bar button.wb-button {
    padding: 0;
    border: 0;
    border-radius: 0;
    background-color: transparent;
    font: inherit;
    color: inherit;
}
.wb-content-wrapper .wb-content.cnt-menu .wb-responsive-menu li button.wb-view-more {
    padding: 0;
    border: 0;
    background-color: transparent;
    /* chevron image #C61619 -> about #AA1317 */
    filter: brightness(0.86);
}
.wb-content-wrapper .wb-content.cnt-menu .wb-responsive-menu li button.wb-view-more:focus-visible {
    outline-offset: -3px;
}

/* ---------------------------------------------------------------------------
 * Reflow (SC 1.4.10): no horizontal scrolling at 320 px
 * (Festivals: line of underscores, Datenschutz/Impressum: long URLs)
 * ------------------------------------------------------------------------- */
#p main p,
#p main li,
#p main td,
#p main h1,
#p main h2,
#p main h3,
#p main h4,
#p main h5,
#p main a {
    overflow-wrap: anywhere;
}
#p main img,
#p main iframe,
#p main video {
    max-width: 100%;
}
#p main img {
    height: auto;
}

/* Footer links AGB | Datenschutz | Impressum: >= 24 px touch target, invisible padding */
#p .footer-bottom-inner .footer-menu a {
    display: inline-block;
    padding: 5px 0;
    margin: -5px 0;
}

/* ---------------------------------------------------------------------------
 * Cookie banner (EXT:mindshape_cookie_consent; root font size is 12 px)
 * grey #999999 -> #767676, checkbox border #767676, text 12 -> 14 px,
 * small print 9/10 -> 12 px, title 15 -> 16 px
 * ------------------------------------------------------------------------- */
.cookie-consent-container {
    --color-gray: #767676;
    font-size: 14px;
}
.cookie-consent-container p,
.cookie-consent-container .label,
.cookie-consent-container .buttons .btn,
.cookie-consent-container .consent-modal .option-wrapper .option-detail-wrapper .option-detail.cookie-option {
    font-size: 14px;
}
.cookie-consent-container .show-details,
.cookie-consent-container .footer-links,
.cookie-consent-container .footer-links a,
.cookie-consent-container .consent-modal .option-wrapper .option-detail-wrapper .option-detail {
    font-size: 12px;
}
.cookie-consent-container .consent-modal .cookie-headline,
.cookie-consent-container .consent-modal .option-wrapper .option-headline {
    font-size: 16px;
}
.cookie-consent-container .label .checkmark,
.cookie-consent-container .consent-modal .option-wrapper .label .checkmark {
    border-color: #767676;
}

/* ---------------------------------------------------------------------------
 * Rosenstolz (same templates, own colours – not part of the client's design)
 * ------------------------------------------------------------------------- */
/* Dropdown hover/focus: white on #F60808 is only 4.24:1 -> #E10000 (5:1) */
body#rosenstolz #p .main-menu-outer ul.level-2 > li:hover,
body#rosenstolz #p .main-menu-outer ul.level-3 > li:hover,
body#rosenstolz #p .main-menu-outer ul.level-2 > li:focus-within,
body#rosenstolz #p .main-menu-outer ul.level-3 > li:focus-within,
body#rosenstolz #p .main-menu-outer .main-menu .level-3 > li:hover > a,
body#rosenstolz #p .main-menu-outer .main-menu .level-3 > li.active > a {
    background: #E10000;
}
body#rosenstolz #p .main-menu-outer ul.level-2 > li:focus-within > a > span,
body#rosenstolz #p .main-menu-outer ul.level-3 > li:focus-within > a > span {
    color: #FFFFFF;
}
/* Bold link text #F60808 on white is 4.24:1 -> #E10000 (5:1) */
body#rosenstolz #p a b,
body#rosenstolz #p a strong {
    color: #E10000;
}
/* Focus ring on the dark red menu bar, breadcrumb and mobile menu */
body#rosenstolz #p .header-outer.custom a:focus-visible,
body#rosenstolz #p .breadcrump-outer a:focus-visible,
body#rosenstolz .wb-content.cnt-menu a:focus-visible,
body#rosenstolz .wb-content.cnt-menu button:focus-visible {
    outline-color: #FFFFFF !important;
}
/* Mobile chevrons: red image on dark red -> white */
body#rosenstolz .wb-content-wrapper .wb-content.cnt-menu .wb-responsive-menu li button.wb-view-more {
    filter: brightness(0) invert(1);
}
