/* BMW Classic Downloads - BMW Group CI overlay for h5ai
   Loaded via options.json "resources.styles": ["bmw/bmw.css"]. Kept separate from styles.css so h5ai updates do not overwrite it.
   CI: white ground, text #494949, accent Petrol #035970, greys #6F6F6F / #D6D6D6 / #F6F6F6, font BMWGroupTN. */

@font-face{font-family:"BMWGroupTN";font-weight:300;font-style:normal;font-display:swap;
  src:url("fonts/BMWGroupTNPro-Light.woff2") format("woff2"),url("fonts/BMWGroupTNProTT-Light.woff") format("woff")}
@font-face{font-family:"BMWGroupTN";font-weight:400;font-style:normal;font-display:swap;
  src:url("fonts/BMWGroupTNPro-Regular.woff2") format("woff2"),url("fonts/BMWGroupTNProTT-Regular.woff") format("woff")}
@font-face{font-family:"BMWGroupTN";font-weight:700;font-style:normal;font-display:swap;
  src:url("fonts/BMWGroupTNPro-Bold.woff2") format("woff2"),url("fonts/BMWGroupTNProTT-Bold.woff") format("woff")}
@font-face{font-family:"BMWGroupTNCondensed";font-weight:400;font-style:normal;font-display:swap;
  src:url("fonts/BMWGroupTNCondensedPro-Regular.woff2") format("woff2"),url("fonts/BMWGroupTNCondensedProTT-Regular.woff") format("woff")}
@font-face{font-family:"BMWGroupTNCondensed";font-weight:700;font-style:normal;font-display:swap;
  src:url("fonts/BMWGroupTNCondensedPro-Bold.woff2") format("woff2"),url("fonts/BMWGroupTNCondensedProTT-Bold.woff") format("woff")}

:root{
  --bmw-petrol:#035970;
  --bmw-text:#494949;
  --bmw-grey-mid:#6f6f6f;
  --bmw-grey-light:#d6d6d6;
  --bmw-bg:#f6f6f6;
}

html,body,#root,input,select,button{font-family:"BMWGroupTN",Arial,Helvetica,sans-serif}
code,pre{font-family:"BMWGroupTN",Arial,Helvetica,sans-serif}
body:not([data-theme="dark"]){background:#fff!important;color:var(--bmw-text)}
body:not([data-theme="dark"]) a,body:not([data-theme="dark"]) a:visited{color:var(--bmw-petrol)}
#root a:hover{color:var(--bmw-petrol);text-decoration:underline}
#tree,#info{display:none!important}
/* Sidebar schiebt den Inhalt zur Seite (statt ihn zu ueberdecken); auf schmalen Bildschirmen bleibt sie ein Overlay */
#sidebar{position:relative;top:auto;flex:0 0 auto;min-height:0;z-index:auto}
@media only screen and (max-width:700px){
  #sidebar{position:absolute;top:calc(var(--bmw-header-h,150px) + 48px);min-height:100%;z-index:1}
}

/* ---- Header (BMW Group CI: weisser Grund, Wortmarke BMW GROUP oben links mit "Classic" darunter, Markenlogos rechts davon, Headline rechts) ---- */
#bmwheader{position:relative;display:flex;flex-direction:row;align-items:flex-start;justify-content:space-between;gap:24px;
  min-height:0;padding:22px 40px 18px;box-sizing:border-box;width:100%;background:#fff;color:var(--bmw-text);
  border-bottom:3px solid var(--bmw-petrol)}
/* Logoleiste wie bmwgroup-classic.com: Wortmarke, BMW, MINI, Rolls-Royce je 40 px hoch, Abstaende 60/13/13 px, "Classic" 12 px darunter */
#bmwheader{--bmw-logo-h:40px;--bmw-classic-size:12px}
#bmwheader .bmw-brand{display:inline-block;align-self:flex-start;text-decoration:none;color:var(--bmw-text)}
#bmwheader .bmw-logos{display:flex;align-items:center;height:var(--bmw-logo-h)}
#bmwheader .bmw-logo{display:block;height:var(--bmw-logo-h);width:auto}
#bmwheader .bmw-logo-dark{display:none}
#bmwheader .bmw-logo-bmw{margin-left:calc(var(--bmw-logo-h) * 1.5)}
#bmwheader .bmw-logo-mini,#bmwheader .bmw-logo-rollsroyce{margin-left:calc(var(--bmw-logo-h) * .325)}
#bmwheader .bmw-classic{display:block;margin-top:4px;font-family:"BMWGroupTN",Arial,sans-serif;font-weight:300;font-size:var(--bmw-classic-size);line-height:var(--bmw-classic-size);color:var(--bmw-text)}
#bmwheader .bmw-title{margin-left:auto;align-self:flex-start;text-align:right;font-family:"BMWGroupTNCondensed","BMWGroupTN",Arial,sans-serif;font-weight:700;
  font-size:28px;line-height:30px;letter-spacing:.01em;text-transform:uppercase;color:var(--bmw-text)}
#bmwheader .bmw-title span{display:block;font-weight:400}
/* ---- Theme-Schalter (Header oben rechts); h5ai-eigener Mond-Button in der Toolbar ist ausgeblendet ---- */
#toolbar #theme{display:none!important}
#topbar #backlink{display:none!important}
#topbar #bmwtheme{order:999;flex:0 0 auto;align-self:center;margin:0 16px 0 auto}
#bmwtheme{display:flex;align-items:center;gap:0;width:64px;height:32px;padding:3px;
  box-sizing:border-box;border:1px solid rgba(0,0,0,.35);border-radius:16px;background:transparent;cursor:pointer;color:var(--bmw-text)}
#bmwtheme .bmw-ico{flex:0 0 26px;width:26px;height:26px;padding:4px;box-sizing:border-box;border-radius:50%;
  fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round;transition:background .15s}
#bmwtheme.is-light .sun,#bmwtheme.is-dark .moon{background:rgba(0,0,0,.12)}
#bmwtheme:focus-visible{outline:2px solid var(--bmw-petrol);outline-offset:2px}
/* ---- Navigation / Listing ---- */
body:not([data-theme="dark"]) #topbar,body:not([data-theme="dark"]) #toolbar,body:not([data-theme="dark"]) #crumbbar{background:#fff}
body:not([data-theme="dark"]) #crumbbar,body:not([data-theme="dark"]) #crumbbar a{color:var(--bmw-text)}
body:not([data-theme="dark"]) #crumbbar a.active{color:var(--bmw-petrol)}
body:not([data-theme="dark"]) #view .item .label,body:not([data-theme="dark"]) #view .item .date,body:not([data-theme="dark"]) #view .item .size{color:var(--bmw-text)}
body:not([data-theme="dark"]) #view .item:hover{background:var(--bmw-bg)}
#view .item.folder .label{font-weight:700}
#view .header,#view .header a{font-family:"BMWGroupTNCondensed","BMWGroupTN",Arial,sans-serif;
  text-transform:uppercase;letter-spacing:.03em;color:var(--bmw-grey-mid)}

/* ---- Buttons (analog Newsletter-Template: grau, Radius 3px, Condensed Bold, VERSALIEN) ---- */
#root .el-button,#root .bar-button,#root #login,#root #logout{
  font-family:"BMWGroupTNCondensed","BMWGroupTN",Arial,sans-serif;font-weight:700;text-transform:uppercase;
  border-radius:3px;background:var(--bmw-grey-mid);color:#fff}
#root .el-button:hover{background:var(--bmw-petrol)}


/* ---- Fallback-Ansicht ohne JavaScript ---- */
#fallback-hints{padding:16px 32px;color:var(--bmw-grey-mid);font-size:13px}
#fallback-hints .backlink img{height:48px;width:auto}
body[data-theme="dark"] #fallback-hints .backlink img{filter:invert(1)}
@media (prefers-color-scheme:dark){html.bmw-dark #fallback-hints .backlink img{filter:invert(1)}}

/* ---- Dark mode (h5ai toggle sets body[data-theme=dark]); CI defines no dark palette: neutral greys + petrol tint ---- */
body[data-theme="dark"]{background:#1b1b1b!important;color:#e6e6e6}
body[data-theme="dark"] a,body[data-theme="dark"] a:visited{color:#7fc4d6}
body[data-theme="dark"] #bmwheader{background:#1b1b1b;color:#e6e6e6}
body[data-theme="dark"] #bmwheader .bmw-logo-light{display:none}
body[data-theme="dark"] #bmwheader .bmw-logo-dark{display:block}
body[data-theme="dark"] #bmwheader .bmw-classic,body[data-theme="dark"] #bmwheader .bmw-title,body[data-theme="dark"] #bmwheader .bmw-brand{color:#e6e6e6}
body[data-theme="dark"] #bmwtheme{border-color:rgba(255,255,255,.6);color:#e6e6e6}
body[data-theme="dark"] #bmwtheme.is-dark .moon{background:rgba(255,255,255,.22)}
body[data-theme="dark"] #topbar,body[data-theme="dark"] #toolbar,body[data-theme="dark"] #crumbbar{background:#1b1b1b}
body[data-theme="dark"] #crumbbar a.active{color:#7fc4d6}
body[data-theme="dark"] #view .item:hover{background:#2a2a2a}

/* Tablet: kleinerer Header */
@media only screen and (max-width:1100px){
  #bmwheader{padding:14px 24px 10px;gap:16px}
  #bmwheader{--bmw-logo-h:32px;--bmw-classic-size:11px}
  #bmwheader .bmw-title{font-size:22px;line-height:26px;white-space:nowrap}
}
@media only screen and (max-width:700px){
  #bmwheader{min-height:0;padding:16px 16px 14px;flex-direction:column;align-items:flex-start;gap:8px}
  #bmwheader{--bmw-logo-h:24px;--bmw-classic-size:10px}
  #bmwheader .bmw-title{display:none}
}
@media print{#bmwtheme{display:none}#bmwheader{border-bottom:1px solid #000}}

/* Infoseite: kein Spendenblock */
#support{display:none!important}

/* ---- Footer (rechtliche Links), Einwilligung (Matomo nur mit Opt-in) und Datenschutzhinweis ---- */
#bmwfooter{order:999;flex:0 0 auto;display:flex;flex-wrap:wrap;gap:6px 22px;align-items:center;justify-content:center;
  padding:10px 24px;border-top:1px solid var(--bmw-grey-light);background:#fff;font-size:13px}
#bmwfooter a,#bmwfooter .bmw-link-btn{color:var(--bmw-text)!important}
#bmwfooter a:hover,#bmwfooter .bmw-link-btn:hover{color:var(--bmw-petrol)!important;text-decoration:underline}
#bmwfooter .bmw-operator{color:var(--bmw-grey-mid);flex:1 1 100%;text-align:center;font-size:12px}
body[data-theme="dark"] #bmwfooter .bmw-operator{color:#b5b5b5}
.bmw-link-btn{appearance:none;border:0;background:none;padding:0;margin:0;font:inherit;color:var(--bmw-petrol);cursor:pointer;text-decoration:underline}
.bmw-link-btn:focus-visible,#bmwfooter a:focus-visible{outline:2px solid var(--bmw-petrol);outline-offset:2px}

#bmwconsent{position:fixed;left:0;right:0;bottom:0;z-index:2000;display:flex;flex-wrap:wrap;gap:12px 28px;align-items:center;justify-content:space-between;
  padding:16px 32px;background:var(--bmw-bg);color:var(--bmw-text);border-top:3px solid var(--bmw-petrol);box-shadow:0 -4px 18px rgba(0,0,0,.18);box-sizing:border-box}
#bmwconsent .bmw-consent-text{flex:1 1 520px;font-size:14px;line-height:20px}
#bmwconsent strong{font-family:"BMWGroupTNCondensed","BMWGroupTN",Arial,sans-serif;font-weight:700;font-size:18px;text-transform:uppercase;letter-spacing:.02em}
#bmwconsent p{margin:4px 0 6px}
#bmwconsent .bmw-consent-actions{display:flex;gap:10px;flex:0 0 auto}

.bmw-btn{appearance:none;font-family:"BMWGroupTNCondensed","BMWGroupTN",Arial,sans-serif;font-weight:700;font-size:14px;text-transform:uppercase;letter-spacing:.03em;
  padding:11px 22px;border-radius:3px;border:1px solid var(--bmw-grey-mid);cursor:pointer;line-height:18px}
.bmw-btn-primary{background:var(--bmw-petrol);border-color:var(--bmw-petrol);color:#fff}
.bmw-btn-primary:hover{background:#024658}
.bmw-btn-secondary{background:#fff;color:var(--bmw-text)}
.bmw-btn-secondary:hover{background:var(--bmw-grey-light)}
.bmw-btn:focus-visible{outline:2px solid var(--bmw-petrol);outline-offset:2px}

#bmwprivacy{position:fixed;inset:0;z-index:2100;display:flex;align-items:center;justify-content:center;padding:16px;background:rgba(0,0,0,.55)}
#bmwprivacy .bmw-modal{width:min(720px,100%);max-height:calc(100vh - 32px);display:flex;flex-direction:column;background:#fff;color:var(--bmw-text);border-radius:3px;box-shadow:0 10px 40px rgba(0,0,0,.4)}
#bmwprivacy h2{margin:0;padding:20px 24px 12px;font-family:"BMWGroupTNCondensed","BMWGroupTN",Arial,sans-serif;font-weight:700;font-size:24px;text-transform:uppercase;letter-spacing:.02em;border-bottom:1px solid var(--bmw-grey-light)}
#bmwprivacy .bmw-modal-body{padding:8px 24px;overflow:auto;font-size:14px;line-height:21px}
#bmwprivacy h3{margin:16px 0 4px;font-size:15px;font-weight:700}
#bmwprivacy p{margin:0 0 8px}
#bmwprivacy ul{margin:0 0 8px;padding-left:20px}
#bmwprivacy a{color:var(--bmw-petrol,#035970)}
#bmwprivacy .bmw-modal-actions{padding:14px 24px 20px;display:flex;justify-content:flex-end;border-top:1px solid var(--bmw-grey-light)}

body[data-theme="dark"] #bmwfooter{background:#1b1b1b;border-top-color:#3a3a3a}
body[data-theme="dark"] #bmwfooter a,body[data-theme="dark"] #bmwfooter .bmw-link-btn{color:#e6e6e6!important}
body[data-theme="dark"] .bmw-link-btn{color:#7fc4d6}
body[data-theme="dark"] #bmwconsent{background:#2a2a2a;color:#e6e6e6;border-top-color:#7fc4d6}
body[data-theme="dark"] .bmw-btn-secondary{background:#2a2a2a;color:#e6e6e6;border-color:#8a8a8a}
body[data-theme="dark"] .bmw-btn-secondary:hover{background:#3a3a3a}
body[data-theme="dark"] #bmwprivacy .bmw-modal{background:#2a2a2a;color:#e6e6e6}
body[data-theme="dark"] #bmwprivacy h2,body[data-theme="dark"] #bmwprivacy .bmw-modal-actions{border-color:#444}
body[data-theme="dark"] #bmwprivacy a{color:#7fc4d6}

.bmw-optout{display:flex;gap:12px;align-items:center;margin:8px 0;padding:10px 12px;border:1px solid var(--bmw-grey-light);border-radius:3px;cursor:pointer;font-weight:700}
.bmw-optout input{flex:0 0 auto;width:20px;height:20px;margin:0;accent-color:var(--bmw-petrol);cursor:pointer;opacity:1!important;position:static!important;appearance:auto!important;-webkit-appearance:checkbox!important}
#bmwprivacy .bmw-small{font-size:12px;line-height:18px;color:var(--bmw-grey-mid)}
#bmwprivacy .bmw-optout-status{font-weight:400;margin:4px 0}
body[data-theme="dark"] .bmw-optout{border-color:#555}
body[data-theme="dark"] #bmwprivacy .bmw-small{color:#b5b5b5}

@media only screen and (max-width:700px){
  #bmwconsent{padding:14px 16px}
  #bmwconsent .bmw-consent-actions{width:100%}
  #bmwconsent .bmw-btn{flex:1 1 0}
  #bmwfooter{padding:8px 12px;gap:4px 16px;font-size:12px}
}
@media print{#bmwfooter,#bmwconsent,#bmwprivacy{display:none!important}}

/* background photo behind the file list: a strong veil keeps text readable, rows and tiles get an almost opaque base */
html body:not([data-theme="dark"]) #mainrow #content{background-color:#fff;background-image:linear-gradient(rgba(255,255,255,.84),rgba(255,255,255,.84)),url("../../images/bg/header.jpg");background-size:cover;background-position:center top;background-repeat:no-repeat}
body:not([data-theme="dark"]) #view .item{background:rgba(255,255,255,.92)}
body:not([data-theme="dark"]) #view .header{background:rgba(255,255,255,.92);color:var(--bmw-text)}
body:not([data-theme="dark"]) #view .header a,body:not([data-theme="dark"]) #view .header span{color:var(--bmw-text)}
html body[data-theme="dark"] #mainrow #content{background-color:#181818;background-image:linear-gradient(rgba(24,24,24,.68),rgba(24,24,24,.68)),url("../../images/bg/header.jpg");background-size:cover;background-position:center top;background-repeat:no-repeat}
body[data-theme="dark"] #view .item{background:rgba(32,32,32,.94)}
body[data-theme="dark"] #view .header{background:rgba(32,32,32,.94)}body:not([data-theme="dark"]) #view .header a *{color:var(--bmw-text);opacity:1}
body:not([data-theme="dark"]) #view #view-hint{color:var(--bmw-text)!important;text-shadow:0 0 10px #fff,0 0 4px #fff}
body[data-theme="dark"] #view .header a *{color:#d6d6d6;opacity:1}
/* no underline on hover in breadcrumb, toolbar and tree (the whitespace between the elements was underlined and showed as small dashes) */
#root #crumbbar a:hover,#root #toolbar a:hover,#root #tree a:hover,#root #topbar a:hover{text-decoration:none}

/* converted picture for HEIC / TIFF (lightbox) */
#bmwlightbox{position:fixed;inset:0;z-index:2200;display:flex;flex-direction:column;background:rgba(0,0,0,.88)}
#bmwlightbox .bmw-lb-stage{flex:1;min-height:0;display:flex;align-items:center;justify-content:center;padding:16px}
#bmwlightbox .bmw-lb-stage img{max-width:100%;max-height:100%;object-fit:contain;background:#fff}
#bmwlightbox .bmw-lb-status{color:#fff;margin:0}
#bmwlightbox .bmw-lb-bar{display:flex;align-items:center;gap:12px;flex-wrap:wrap;justify-content:flex-end;padding:10px 16px;background:#1b1b1b;color:#e6e6e6}
#bmwlightbox .bmw-lb-name{margin-right:auto;font-size:14px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:50%}
#bmwlightbox .bmw-btn{text-decoration:none}