/* Shared content controls: balanced actions, compact episode tools and watched state. */
body.studio-theme .content-watched-button{display:inline-flex;align-items:center;justify-content:center;gap:8px;min-width:0;min-height:44px;padding:10px 14px;border:1px solid var(--studio-component-control-border);border-radius:11px;background:var(--studio-component-control-bg);color:var(--studio-color-text);font:600 12px/1.6 var(--studio-font-family-ui);cursor:pointer}
body.studio-theme .content-watched-button>i{display:grid;place-items:center;width:20px;height:20px;flex:none;border:1px solid currentColor;border-radius:50%;font:700 12px/1 Arial}
body.studio-theme .content-watched-button>span{min-width:0}
body.studio-theme .content-watched-button [data-manual-label]{font:inherit}
body.studio-theme .content-watched-button [data-manual-hint]{display:none}
body.studio-theme .content-watched-button.is-completed{color:var(--studio-color-success)!important;border-color:var(--studio-color-success)!important;background:color-mix(in srgb,var(--studio-color-success) 12%,var(--studio-component-control-bg))!important}
body.studio-theme .content-watched-button.is-completed>i{background:var(--studio-color-success);color:var(--studio-component-control-bg);border-color:var(--studio-color-success)}
body.studio-theme .content-watched-button.is-saving{opacity:.6;cursor:wait}
body.studio-theme .content-watched-button.is-error{border-color:var(--studio-color-danger)!important}
body.studio-theme .content-watched-button:focus-visible{outline:2px solid var(--studio-color-link);outline-offset:3px}
body.studio-theme :is(.manual-completion-status,.title-action-status){font:500 12px/1.7 var(--studio-font-family-ui);color:var(--studio-color-text-secondary);overflow-wrap:anywhere}
body.studio-theme :is(.manual-completion-status,.title-action-status):empty{display:none!important}
@media(min-width:741px){
  body.studio-theme.studio-title-detail .title-actions{display:flex!important;flex-wrap:wrap;align-items:center;justify-content:flex-start;gap:10px;width:100%;max-width:760px}
  body.studio-theme.studio-title-detail .title-actions :is(a,button,form){flex:0 0 auto;width:auto!important;min-width:0!important;max-width:100%;margin:0!important;box-sizing:border-box}
  body.studio-theme.studio-title-detail .title-actions :is(a,button){display:inline-flex!important;align-items:center;justify-content:center;gap:8px;min-height:44px;height:auto!important;padding:10px 16px!important;font-size:13px!important;line-height:1.6;white-space:normal;text-align:center}
}
body.studio-theme.studio-title-detail .journey-head{margin-bottom:16px!important}
body.studio-theme.studio-title-detail .journey-toolbar{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:16px 24px;padding:14px 16px;margin-bottom:18px;border:1px solid var(--studio-component-control-border);border-radius:14px;background:var(--studio-component-control-bg)}
body.studio-theme.studio-title-detail .journey-toolbar .title-journey-resume{flex:1 1 320px;max-width:540px;width:auto;display:flex;align-items:center;flex-wrap:nowrap;gap:16px}
body.studio-theme.studio-title-detail .journey-toolbar .title-journey-meter{flex:1;min-width:0;max-width:240px}
body.studio-theme.studio-title-detail .journey-toolbar .title-journey-meter>span{margin-bottom:7px;font-size:12px;line-height:1.6;white-space:normal}
body.studio-theme.studio-title-detail .journey-toolbar .title-journey-action{flex:none;min-height:44px;font-size:12px;padding:9px 12px;gap:8px;white-space:nowrap}
body.studio-theme.studio-title-detail .journey-toolbar .title-journey-action svg{width:18px;height:18px}
body.studio-theme.studio-title-detail .journey-toolbar .journey-library-tools{flex:1 1 280px;max-width:390px;min-width:0;display:grid;grid-template-columns:minmax(0,1fr);gap:8px;padding:0;margin:0;border:0;background:none;box-shadow:none}
body.studio-theme.studio-title-detail .journey-library-tools label{display:block;min-width:0;max-width:none;width:100%;margin:0}
body.studio-theme.studio-title-detail .journey-library-tools label>span{display:block;margin-bottom:6px;font-size:11px;color:var(--studio-color-text-secondary)}
body.studio-theme.studio-title-detail .journey-library-tools input{width:100%!important;max-width:none!important;min-height:44px;margin:0;padding:10px 12px;font:400 14px/1.5 var(--studio-font-family-ui);box-sizing:border-box}
body.studio-theme.studio-title-detail .journey-library-tools nav{display:flex;flex-wrap:nowrap;max-width:100%;min-width:0;overflow-x:auto;gap:6px;scrollbar-width:thin}
body.studio-theme.studio-title-detail .journey-library-tools nav button{flex:none;min-height:44px;min-width:50px}
body.studio-theme.studio-title-detail .journey-controls{align-items:center;gap:12px;margin-bottom:18px}
body.studio-theme.studio-title-detail .season-switcher{min-width:0;max-width:100%;overflow-x:auto;flex-wrap:nowrap}
body.studio-theme.studio-title-detail .season-switcher button{display:flex;align-items:center;flex:none;gap:8px;padding:8px 12px;min-height:48px;min-width:0}
body.studio-theme.studio-title-detail .season-switcher button span{font-size:11px;line-height:1.5}
body.studio-theme.studio-title-detail .season-switcher button b{font-size:21px;line-height:1.2;margin:0;font-variant-numeric:tabular-nums}
body.studio-theme.studio-title-detail .season-switcher button small{font-size:10px;line-height:1.5}
body.studio-theme.studio-title-detail .episode-filters button{min-height:44px;font-size:12px;padding:8px 12px}
@media(max-width:1000px) and (min-width:741px){
  body.studio-theme.studio-title-detail .title-actions :is(a,button){font-size:12px!important;padding-inline:8px!important}
}
@media(max-width:740px){
  body.studio-theme.studio-title-detail .title-secondary-actions>:last-child:nth-child(odd){grid-column:1/-1}
  body.studio-theme.studio-title-detail .journey-toolbar{padding:12px;gap:14px;margin-bottom:12px}
  body.studio-theme.studio-title-detail .journey-toolbar :is(.title-journey-resume,.journey-library-tools){flex:1 1 100%;max-width:none;width:100%}
  body.studio-theme.studio-title-detail .journey-toolbar .title-journey-resume{gap:10px}
  body.studio-theme.studio-title-detail .journey-toolbar .title-journey-meter>span{font-size:10px}
  body.studio-theme.studio-title-detail .journey-toolbar .title-journey-action{font-size:11px;padding-inline:9px}
  body.studio-theme.studio-title-detail .journey-library-tools input{font-size:16px}
  body.studio-theme.studio-title-detail .journey-controls{display:grid;grid-template-columns:minmax(0,1fr)}
  body.studio-theme.studio-title-detail .episode-filters button{font-size:11px;padding-inline:10px}
}
@media(max-width:1050px){
  body.studio-watch-page .w146.is-movie .w146-head{flex-wrap:wrap}
  body.studio-watch-page .w146.is-movie .w146-head-actions{flex:1 0 100%;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));width:100%}
  body.studio-watch-page .w146.is-movie .w146-head-actions :is(a,button){white-space:normal;min-width:0;width:100%;font-size:11px;padding:8px}
}
@media(max-width:400px){
  body.studio-watch-page .w146.is-movie .w146-head-actions{grid-template-columns:repeat(2,minmax(0,1fr))}
  body.studio-watch-page .w146.is-movie .w146-head-actions>.content-watched-button{grid-column:1/-1}
}

body.studio-theme.studio-title-detail .title-action-status{order:4}

/* Bound intrinsic SVG sizes: a new action must never resize the entire grid. */
body.studio-theme.studio-title-detail .title-actions svg{width:20px;height:20px;flex:0 0 20px}

/* Primary decisions above a compact, consistently labelled utility row. */
@media(min-width:821px){
 body.studio-theme.studio-title-detail .title-actions .title-actions-more{display:contents}
 body.studio-theme.studio-title-detail .title-actions .title-secondary-actions{display:flex;flex:0 0 100%;flex-wrap:wrap;gap:8px;padding-top:2px}
 body.studio-theme.studio-title-detail .title-actions .title-secondary-actions :is(a,button){flex-direction:column;gap:4px;min-width:76px!important;min-height:62px;padding:8px 12px!important;font-size:11px!important}
 body.studio-theme.studio-title-detail .title-actions .title-trailer-secondary{display:none!important}
 body.studio-theme.studio-title-detail .title-actions .mobile-app-episodes-link{display:inline-flex!important}
}
@media(max-width:820px),(max-width:1024px) and (max-height:500px){
 body.studio-theme.studio-title-detail .title-actions{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;align-items:start}
 body.studio-theme.studio-title-detail .title-actions>.primary{grid-column:1/-1}
 body.studio-theme.studio-title-detail .title-actions .title-trailer-primary{display:none!important}
 body.studio-theme.studio-title-detail .title-actions .title-actions-more,
 body.studio-theme.studio-title-detail .title-actions .title-actions-more::details-content{display:contents!important}
 body.studio-theme.studio-title-detail .title-actions .title-actions-more>summary{grid-column:2;grid-row:2;justify-content:center!important;gap:6px}
 body.studio-theme.studio-title-detail .title-actions:not(:has(.mobile-app-episodes-link)) .title-actions-more>summary{grid-column:1/-1}
 body.studio-theme.studio-title-detail .title-actions .mobile-app-episodes-link{display:flex!important;grid-column:1;grid-row:2;justify-content:center;align-items:center;min-height:48px;box-sizing:border-box}
 body.studio-theme.studio-title-detail .title-actions .title-actions-more:not([open]) .title-secondary-actions{display:none!important}
 body.studio-theme.studio-title-detail .title-actions .title-secondary-actions{grid-column:1/-1;display:grid!important;grid-template-columns:repeat(4,minmax(0,1fr));gap:7px;padding-top:4px}
 body.studio-theme.studio-title-detail .title-actions .title-secondary-actions>*{grid-column:auto!important}
 body.studio-theme.studio-title-detail .title-actions .title-secondary-actions :is(a,button){display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4px;min-height:62px!important;padding:7px 4px!important;font-size:10px!important;line-height:1.5}
}

@media(max-width:820px),(max-width:1024px) and (max-height:500px){
 body.studio-theme.studio-title-detail .title-actions .title-actions-more>summary>i{display:inline!important;font-style:normal}
 body.studio-theme.studio-title-detail .title-actions .title-secondary-actions:has(>:nth-child(5)){grid-template-columns:repeat(3,minmax(0,1fr))}
}
