/* Sprachwahl mit Flagge und Anpassungen je Schrift. Ergänzt future.css. */
.visually-hidden{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0}
h1,h2,h3,h4{overflow-wrap:break-word}

/* Sprachwahl im Kopf */
.lang-switch{position:relative;border:0;flex:none}
.lang-switch summary{display:flex;align-items:center;justify-content:center;gap:8px;height:42px;min-height:0;padding:0 14px;border:1px solid var(--line);border-radius:21px;font-size:11px;letter-spacing:1px;font-weight:700;color:var(--paper);transition:border-color .25s}
.lang-switch summary:hover,.lang-switch[open] summary{border-color:var(--green)}
.lang-switch .flag{font-size:17px;line-height:1;letter-spacing:0}
.lang-menu{position:absolute;top:calc(100% + 10px);inset-inline-end:0;z-index:60;min-width:200px;margin:0;padding:6px;list-style:none;background:#1b1a16;border:1px solid var(--line);border-radius:12px;box-shadow:0 18px 44px #0009}
.lang-menu a{display:flex;align-items:center;gap:12px;min-height:44px;padding:0 12px;border-radius:8px;font-size:14px;color:var(--paper)}
.lang-menu a:hover{background:#ede5d514}
.lang-menu a[aria-current]{color:#91cba0;background:#4a9e6a1f}
.lang-menu a[aria-current]:after{content:'✓';margin-inline-start:auto;color:var(--green)}
@media(max-width:650px){
  .lang-switch{margin-inline-start:auto}
  .lang-switch summary{height:44px;padding:0 12px;font-size:10px}
  #motion-toggle{margin-left:0}
}

/* Schriften: Arabisch und Chinesisch mit Systemschriften, die diese Zeichen sauber setzen */
html[lang=ar]{--script:"Geeza Pro","SF Arabic","Segoe UI","Noto Sans Arabic",Tahoma,Arial,sans-serif}
html[lang=zh-Hans]{--script:Arial,"PingFang SC","Hiragino Sans GB","Microsoft YaHei","Noto Sans SC",sans-serif}
html:is([lang=ar],[lang=zh-Hans]) body,
html:is([lang=ar],[lang=zh-Hans]) :is(.section-label,.experience-eyebrow,.experience-unit,.experience-source,.craft-number,.image-credit){font-family:var(--script)}
html:is([lang=ar],[lang=zh-Hans]) .monogram{font-family:Arial,Helvetica,sans-serif}
html:is([lang=ar],[lang=zh-Hans]) :is(.visual-label,.visual-tag,.visual-bottom,.hero-top,.hero-bottom,.section-label,.image-credit,.craft-number,.experience-eyebrow,.experience-unit,.experience-source){font-size:11px}
/* Arabische Buchstaben hängen zusammen: Sperrung zerreißt die Wörter */
html[lang=ar] body *:not(.monogram){letter-spacing:0!important}
html[lang=ar] :is(.hero h1,h2,.contact-main,.project-description .lead,.work-row h3,.personal-note){line-height:1.3}
html[lang=zh-Hans] :is(.hero h1,h2,.contact-main,.experience-scale,.project-description .lead,.work-row h3){letter-spacing:0;line-height:1.2}
html[lang=ru] :is(.hero h1,h2,.contact-main,.work-row h3){hyphens:auto}

/* Arabisch läuft von rechts nach links */
[dir=rtl] .site-header nav{margin-left:0;margin-right:auto}
[dir=rtl] .nav-contact{margin-left:0;margin-right:24px}
[dir=rtl] .reading-progress,[dir=rtl] .craft-track span{transform-origin:right}
[dir=rtl] .hero-grid{mask-image:linear-gradient(270deg,transparent,#000)}
[dir=rtl] .hero-bottom b{margin-left:0;margin-right:12px}
[dir=rtl] .hero-bottom a span{margin-left:0;margin-right:18px}
[dir=rtl] .row-arrow{text-align:left}
[dir=rtl] .stack-card>span{float:left}
[dir=rtl] .stack-card:hover{transform:translateX(6px)}
[dir=rtl] :is(.button span,.row-arrow,.contact-arrow,.cta-disc,.line-link>span[aria-hidden],.cv-link>span[aria-hidden],.visual-tag b,.mobile-dock a span){display:inline-block;transform:scaleX(-1)}
@media(max-width:900px){[dir=rtl] .nav-contact{margin-right:0}}
@media(max-width:650px){[dir=rtl] .header-name{margin-left:0;margin-right:4px}[dir=rtl] .section-label>span:last-child{text-align:left}}
[dir=rtl] :is(.monogram,.profile-monogram,.edition){direction:ltr;unicode-bidi:isolate}
