/* Shared controls use the same saved colour preference as the public website. */
.tpc-theme-control{display:inline-flex!important;align-items:center;justify-content:center;width:38px;min-width:38px;height:38px;min-height:38px;padding:8px!important;border:1px solid var(--line,#d8dce4)!important;border-radius:8px;background:transparent;color:var(--ink,var(--navy,#172334));cursor:pointer;line-height:1;flex-shrink:0}
.tpc-theme-control svg{display:block;width:20px;height:20px;flex:none;pointer-events:none}.tpc-theme-control:hover{background:var(--tint,#f0f3f8)}.tpc-theme-control:focus-visible,.tpc-return-admin:focus-visible{outline:3px solid #6f9fdf;outline-offset:3px}.tpc-login-theme{position:absolute;right:24px;top:24px}
.tpc-site-controls{position:fixed;right:max(18px,env(safe-area-inset-right));bottom:max(20px,env(safe-area-inset-bottom));z-index:40;display:flex;align-items:center;gap:9px;max-width:calc(100vw - 32px)}.tpc-site-controls:empty{display:none}.tpc-site-controls .tpc-theme-control{background:#fffdf9;color:#172334;border-color:#d8dce4!important;box-shadow:0 3px 16px #14213218}.tpc-return-admin{display:inline-flex;align-items:center;justify-content:center;gap:9px;min-height:42px;padding:10px 15px;border:1px solid #23364d;border-radius:9px;background:#172b43;color:#fff!important;box-shadow:0 4px 20px #14213225;font:600 12px/1.5 Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;text-decoration:none!important;white-space:nowrap}.tpc-return-admin:hover{background:#24405f}.tpc-return-admin svg{display:block;width:18px;height:18px;flex:none;pointer-events:none}
html[data-theme="dark"] .tpc-site-controls .tpc-theme-control{background:#1b2737;color:#e5edf7;border-color:#475569!important}html[data-theme="dark"] .tpc-theme-control{color:#e5edf7;border-color:#475569!important}html[data-theme="dark"] .tpc-theme-control:hover{background:#26364b}html[data-theme="dark"] .tpc-return-admin{background:#e5edf7;color:#142132!important;border-color:#e5edf7}html[data-theme="dark"] .tpc-return-admin:hover{background:#cbdaf0}
html[data-tpc-surface="studio"]{color-scheme:light}html[data-tpc-surface="studio"][data-theme="dark"]{color-scheme:dark;--paper:#192536;--wash:#101a28;--navy:#e5edf7;--muted:#a9b8cb;--line:#364559;--accent:#ffab8a;--tint:#372c2c;background:var(--wash);color:var(--navy)}
html[data-theme="dark"] .tpc-admin,html[data-theme="dark"] .tpc-login-page{background:var(--wash);color:var(--navy)}
html[data-theme="dark"] :is(.tpc-admin,.tpc-login-page) :is(input:not([type="checkbox"]):not([type="radio"]),select,textarea,.tpc-rich-content){background:#132031;color:var(--navy);border-color:#405168}html[data-theme="dark"] :is(.tpc-admin,.tpc-login-page) :is(input,textarea)::placeholder{color:#8fa0b8;opacity:1}
html[data-theme="dark"] .tpc-admin :is(.tpc-button,.tpc-media-card,.tpc-dialog,.tpc-table-wrap,.tpc-card,.tpc-stat){background:var(--paper);color:var(--navy);border-color:var(--line)}html[data-theme="dark"] .tpc-admin .tpc-button:hover{background:#26364b}html[data-theme="dark"] :is(.tpc-admin,.tpc-login-page) .tpc-button-primary{background:#c64321;color:#fff;border-color:#e45c37}html[data-theme="dark"] :is(.tpc-admin,.tpc-login-page) .tpc-button-primary:hover{background:#a73519}html[data-theme="dark"] .tpc-admin .tpc-button-danger{color:#ffb7a8}
html[data-theme="dark"] .tpc-admin :is(.tpc-table th,.tpc-rich-toolbar,.tpc-role-note,.tpc-media-file){background:#202f42;color:var(--muted)}html[data-theme="dark"] .tpc-admin .tpc-rich-toolbar button{color:#c4d2e5}html[data-theme="dark"] .tpc-admin .tpc-rich-toolbar button:hover,html[data-theme="dark"] .tpc-admin .tpc-rich-toolbar button.is-active{background:#31445d;color:var(--accent)}html[data-theme="dark"] .tpc-admin .tpc-sidebar nav a{color:#b9c8db}html[data-theme="dark"] .tpc-admin .tpc-sidebar nav a:hover{background:#26364b}html[data-theme="dark"] .tpc-admin .tpc-sidebar nav a.is-active{background:var(--tint);color:var(--accent)}html[data-theme="dark"] .tpc-admin .tpc-sidebar nav a span{color:inherit}
html[data-theme="dark"] .tpc-admin .tpc-badge{background:#29384b;color:#c3cfdd}html[data-theme="dark"] .tpc-admin :is(.tpc-badge-published,.tpc-badge-publish,.tpc-badge-approved,.tpc-badge-active){background:#17392e;color:#a4e2bd}html[data-theme="dark"] .tpc-admin :is(.tpc-badge-pending,.tpc-badge-scheduled,.tpc-badge-hold){background:#40351f;color:#f3d48b}html[data-theme="dark"] .tpc-admin :is(.tpc-badge-trash,.tpc-badge-spam,.tpc-badge-disabled){background:#462b2b;color:#ffbbb1}
html[data-theme="dark"] :is(.tpc-admin,.tpc-login-page) .tpc-notice{background:#17392e;color:#b4e9c7;border-color:#2d614a}html[data-theme="dark"] :is(.tpc-admin,.tpc-login-page) :is(.tpc-notice.is-error,.tpc-auth-invalid,.tpc-no-script){background:#462b2b;color:#ffc3b8;border-color:#7c4845}html[data-theme="dark"] .tpc-admin .tpc-code-editor{background:#0d1725;color:#dfebfa;border-color:#405168}
html[data-theme="dark"] #tp-studio{--tp-paper:#192536;--tp-wash:#101a28;--tp-text:#e5edf7;--tp-muted:#a9b8cb;--tp-line:#364559;--tp-accent:#ffab8a;--tp-accent-hover:#ffc4a8;--tp-tint:#372c2c}
html[data-theme="dark"] #tp-studio :is(.tp-document select,.tp-btn,.tp-segmented button.is-active,.tp-page-meta input:hover,.tp-page-meta input:focus,.tp-code-panel,.tp-seo-fields,.tp-seo-fields input,.tp-seo-fields textarea,.tp-dialog input,.tp-media-choice,.gjs-block,.gjs-field){background:#192536;color:var(--tp-text);border-color:var(--tp-line)}html[data-theme="dark"] #tp-studio :is(.tp-segmented,.tp-editor-main,.tp-page-meta,.tp-canvas-loading,.gjs-editor,.gjs-cv-canvas,.gjs-sm-composite.gjs-sm-open){background:#101a28}html[data-theme="dark"] #tp-studio .tp-btn:hover:not(:disabled){background:#26364b;border-color:#60738e}html[data-theme="dark"] #tp-studio .tp-btn-primary{background:#c64321;color:#fff;border-color:#e45c37}html[data-theme="dark"] #tp-studio .tp-btn-primary:hover:not(:disabled){background:#a73519;border-color:#e45c37}html[data-theme="dark"] #tp-studio .gjs-block:hover{background:#26364b;border-color:#9e6c57}html[data-theme="dark"] #tp-studio :is(.tp-notice,.tp-dialog-error){background:#17392e;color:#b4e9c7;border-color:#2d614a}html[data-theme="dark"] #tp-studio :is(.tp-notice.is-error,.tp-dialog-error){background:#462b2b;color:#ffc3b8;border-color:#7c4845}
@media(max-width:680px){.tpc-site-controls{right:max(12px,env(safe-area-inset-right));bottom:max(14px,env(safe-area-inset-bottom));gap:7px}.tpc-return-admin{font-size:11px;min-height:40px;padding:9px 12px}.tpc-login-theme{right:18px;top:18px}.tpc-top-actions .tpc-theme-control{width:34px;min-width:34px;height:34px;min-height:34px;padding:6px!important}}
html[data-theme="dark"] .tpc-admin .tpc-secret-state{color:#a4e2bd}
@media(max-width:680px){.tpc-topbar .tpc-brand small{display:none}}
@media print{.tpc-site-controls,.tpc-theme-control{display:none!important}}

/* Identity images preserve their ratio and use the configured theme pair. */
.tpc-brand-pair{display:inline-flex;align-items:center;max-width:100%}.tpc-brand-pair>[data-tpc-brand-slot="logo_dark"]{display:none!important}html[data-theme="dark"] .tpc-brand-pair>[data-tpc-brand-slot="logo_light"]{display:none!important}html[data-theme="dark"] .tpc-brand-pair>[data-tpc-brand-slot="logo_dark"]{display:block!important}[data-tpc-brand-slot]{object-fit:contain!important;content:normal!important;max-width:100%;height:auto}.tpc-brand-pair img{max-height:55px;width:auto!important;max-width:200px}.tpc-topbar .tpc-brand-pair img{max-height:42px;max-width:154px}
.site-header .brand [data-tpc-brand-slot],.tpj-header .tpj-brand [data-tpc-brand-slot]{max-height:44px;object-position:left center}.footer-brand [data-tpc-brand-slot]{max-height:43px;object-position:left center}.tpc-login-story [data-tpc-brand-slot]{max-height:55px;width:auto!important;max-width:200px}.tpd-brand-full[data-tpc-brand-slot]{width:138px!important;height:32px!important;object-position:left center}#tp-studio .tp-builder-logo[data-tpc-brand-slot]{width:140px!important;height:38px!important;object-position:left center}:is(.tpc-dialog-brand,.tpc-modal-brand) [data-tpc-brand-slot]{max-height:36px;width:auto!important;max-width:132px}
