/* Text adaptation only; canonical sidebar dimensions and Studio geometry stay intact. */
#publicUiLanguage { max-width: 112px; min-width: 0; }
#authUiLanguage { max-width: 100%; color: inherit; background: #10152a; border: 1px solid #424c71; border-radius: 8px; padding: 7px; }
html[dir="rtl"] .timeline,
html[dir="rtl"] .studio-ref-timeline,
html[dir="rtl"] #studioScrub,
html[dir="rtl"] input[type="range"],
html[dir="rtl"] video,
html[dir="rtl"] .analytics-performance-svg { direction: ltr; }
html[dir="rtl"] input[type="email"],
html[dir="rtl"] input[type="url"] { direction: ltr; text-align: start; }
html[dir="rtl"] .auth-card,
html[dir="rtl"] .settings-v2-card,
html[dir="rtl"] .syra-agent-message { text-align: start; }
[data-i18n-language-selector] { max-width: 100%; }
/* Let translated actions wrap inside the existing fixed-height SYRA panel. */
html[lang] .home2-agent { grid-template-rows: 56px auto 28px minmax(0, 1fr) 60px; }
html[lang] .home2-agent .home2-agent-actions { grid-template-rows: repeat(3, minmax(24px, auto)); }
html[lang] .home2-agent .home2-agent-actions button { height: auto; white-space: normal; overflow-wrap: anywhere; line-height: 1.2; }
html[dir="rtl"] body.clipsyra-web2-reference-layout #app .clipsyra-sidebar { left: auto !important; right: 0 !important; border-right: 0; border-left: 1px solid var(--web2-line); }
html[dir="rtl"] body.clipsyra-web2-reference-layout #app .main.main { margin-left: 0 !important; margin-right: var(--web2-sidebar-width) !important; }
html[lang] .home2-hero-copy, html[lang] .home2-hero-copy h1 { min-width: 0; max-width: 100%; overflow-wrap: anywhere; }
html[dir="rtl"] .home2-growth-panel { margin-left: 0; margin-right: -22px; }
html[dir="rtl"] .home2-recent-panel { margin-left: 22px; margin-right: 3px; }
html[lang] #create .create2-tools-head button, html[lang] #create .clipsyra-step span { min-width: 0; max-width: 100%; white-space: normal; overflow-wrap: anywhere; }
@media (max-width: 1199px) {
  html[dir="rtl"] .home2-growth-panel, html[dir="rtl"] .home2-recent-panel { margin-left: 0; margin-right: 0; }
}
@media (max-width: 1250px) {
  html[lang] #create .create2-hero h1, html[lang] #create .create2-lead { max-width: 100%; overflow-wrap: anywhere; }
}
@media (max-width: 820px) {
  html[dir="rtl"] body.clipsyra-web2-reference-layout #app .main.main { margin-right: 0 !important; }
  html[dir="rtl"] body.clipsyra-web2-reference-layout #app .clipsyra-sidebar { transform: translateX(104%); }
  html[dir="rtl"] body.clipsyra-mobile-nav-open #app .clipsyra-sidebar { transform: translateX(0); }
  html[dir="rtl"] .clipsyra-mobile-menu-btn { left: auto; right: 14px; }
  html[dir="rtl"] .clipsyra-mobile-sidebar-close { right: auto; left: 10px; }
  html[dir="rtl"] body.clipsyra-web2-reference-layout #app .interior2-header { padding-left: 0; padding-right: 40px; }
}
/* Translated labels wrap within the existing Create card width. */
html[lang] #create .create2-card-head { flex-wrap: wrap; }
html[lang] #create .create2-card-head > div { min-width: 0; overflow-wrap: anywhere; }
html[lang] #create .create2-card-head button { max-width: 100%; white-space: normal; overflow-wrap: anywhere; }

/* Direction changes reposition the closed drawer without animating it across the viewport. */
html.i18n-direction-changing .clipsyra-sidebar { transition: none !important; }
