.language-switcher { position: relative; flex: 0 0 auto; margin-inline-start: .65rem; }
.language-switcher summary { display: flex; align-items: center; gap: .3rem; cursor: pointer; list-style: none; font-size: .8rem; }
.language-switcher summary::-webkit-details-marker { display: none; }
.site-nav .language-switcher ul { position: absolute; inset-inline-end: 0; top: 100%; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); min-width: 24rem; padding: .6rem; background: var(--navy-900); list-style: none; }
.site-nav .language-switcher li a { display: block; padding: .4rem; white-space: nowrap; }
@media (min-width: 1051px) { .site-nav { display: flex; align-items: center; } }
@media (max-width: 1050px) { .language-switcher { margin: .65rem 0 0; } .site-nav .language-switcher ul { position: static; } }

.site-nav .language-switcher a[aria-current="true"] { background: rgba(255,255,255,.1); }
@media (max-width: 1050px) {
  .site-nav .language-switcher ul { min-width: 0; width: 100%; }
  .site-nav .language-switcher li a { padding: .55rem .4rem; }
}
html:lang(ar), html:lang(fa) { font-family: "Geeza Pro", "Segoe UI", Tahoma, "Noto Sans Arabic", sans-serif; }
html:lang(th) { font-family: Thonburi, "Leelawadee UI", Tahoma, "Noto Sans Thai", sans-serif; }
html:lang(ko) { font-family: "Apple SD Gothic Neo", "Malgun Gothic", "Noto Sans KR", sans-serif; word-break: keep-all; }
html:lang(ar) body, html:lang(fa) body, html:lang(th) body, html:lang(ko) body { font-family: inherit; }
/* Reserve room for the language control without increasing header height. */
@media (min-width: 1051px) {
  .header-inner { gap: 1rem; }
  .site-nav > ul { gap: .2rem; }
  .site-nav > ul > li > a { padding-inline: .5rem; white-space: nowrap; }
}

/* WO-6 exception approved 2026-10-13: keep frozen English unchanged. */
@media (min-width: 1051px) {
  /* design-card alignment now applies to all languages in styles.css */
}

/* Only overlays mirror: the product photographs keep their original orientation. */
[dir="rtl"] .hero--photo::before { background: linear-gradient(270deg, rgba(8,23,36,0.93) 0%, rgba(8,23,36,0.8) 36%, rgba(8,23,36,0.28) 64%, rgba(8,23,36,0) 100%), linear-gradient(0deg, rgba(8,23,36,0.55) 0%, rgba(8,23,36,0) 28%); }
[dir="rtl"] .direction-arrow,
[dir="rtl"] :is(.text-link-row, .case-card__link, .cap-link, .part-tile__link, .product-card__link, .why-card__link) span[aria-hidden="true"] { display: inline-block; transform: scaleX(-1); }
[dir="rtl"] bdi[dir="ltr"] { unicode-bidi: isolate; }
[dir="rtl"] .footer-title { letter-spacing: normal; }
[dir="rtl"][data-page] .hero:not(.hero--photo)::after,
[dir="rtl"] [data-page] .hero:not(.hero--photo)::after { -webkit-mask-image: linear-gradient(260deg, transparent 38%, #000 85%); mask-image: linear-gradient(260deg, transparent 38%, #000 85%); }
@media (min-width: 721px) {
  [dir="rtl"] .hero--split::before { background: linear-gradient(270deg, var(--navy-950) 0%, var(--navy-950) 45%, rgba(8,23,36,0.6) 50%, rgba(8,23,36,0.08) 64%, rgba(8,23,36,0) 100%); }
  [dir="rtl"] .hero--split-portrait::before { background: linear-gradient(270deg, var(--navy-950) 0%, var(--navy-950) 55%, rgba(8,23,36,0.5) 58%, rgba(8,23,36,0) 66%, rgba(8,23,36,0) 100%); }
}
@media (max-width: 720px) {
  [dir="rtl"] .hero--split::before { background: linear-gradient(0deg, rgba(8,23,36,0.96) 0%, rgba(8,23,36,0.82) 55%, rgba(8,23,36,0.35) 100%); }
}
/* Long translated technical terms must stay within the existing narrow cards. */
html:not([lang="en"]):not([lang="ko"]) .def-cards { hyphens: auto; overflow-wrap: anywhere; }

/* Language suggestion (shown once, in the visitor's browser language) */
.language-prompt { position: fixed; top: 92px; right: 1.25rem; z-index: 95; width: min(380px, calc(100vw - 2rem)); padding: 1.1rem 1.2rem 1rem; color: var(--ink); background: var(--white); border: 1px solid var(--steel-200); border-top: 3px solid var(--copper-500); border-radius: var(--radius-sm); box-shadow: var(--shadow-lift); opacity: 0; transform: translateY(-8px); transition: opacity 220ms ease, transform 220ms ease; }
.language-prompt.is-visible { opacity: 1; transform: translateY(0); }
.language-prompt p { margin: 0; font-size: 0.95rem; line-height: 1.5; }
.language-prompt__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 1rem; margin-top: 0.85rem !important; }
.language-prompt .button { min-height: 40px; padding: 0.5rem 1rem; font-size: 0.9rem; }
.language-prompt__stay { padding: 0.4rem 0; color: var(--muted); background: none; border: 0; font: inherit; font-size: 0.88rem; text-decoration: underline; text-underline-offset: 0.2em; cursor: pointer; }
.language-prompt__stay:hover { color: var(--navy-900); }
.language-prompt[lang="ko"] { word-break: keep-all; }
html[dir="rtl"] .language-prompt { right: auto; left: 1.25rem; }
@media (max-width: 720px) { .language-prompt, html[dir="rtl"] .language-prompt { top: 78px; left: 0.75rem; right: 0.75rem; width: auto; } }
@media (prefers-reduced-motion: reduce) { .language-prompt { transition: none; } }
