:root {
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #172033;
  background: #f5f7fb;
  font-synthesis: none;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { min-height: 100%; }
html.app-active { height: 100%; overflow: hidden; overscroll-behavior: none; }
body { margin: 0; min-height: 100vh; background: #f5f7fb; }
body.app-active { height: 100%; min-height: 0; overflow: hidden; overscroll-behavior: none; }
button, input, textarea, select { font: inherit; }
button { cursor: pointer; }
.auth-screen { display: grid; min-height: 100vh; place-items: center; padding: 28px; background: radial-gradient(circle at 20% 10%, #eeeaff 0, transparent 34%), linear-gradient(145deg, #f8f9fc, #eef1f8); }
.auth-card { display: grid; width: min(460px, 100%); gap: 28px; border: 1px solid #e0e4ed; border-radius: 22px; padding: 34px; background: #fff; box-shadow: 0 28px 80px #27344b1f; }
.auth-brand { display: flex; align-items: center; gap: 12px; }
.auth-logo { width: 72px; height: 48px; object-fit: contain; object-position: left center; }
.auth-brand strong, .auth-brand small { display: block; }
.auth-brand small { margin-top: 2px; color: #8a93a3; font-size: .72rem; }
.auth-heading h1 { font-size: 1.8rem; }
.auth-heading > p:last-child { margin: 10px 0 0; color: #778195; font-size: .86rem; line-height: 1.55; }
.auth-form { display: grid; gap: 16px; }
.auth-form > label { display: grid; gap: 7px; color: #596579; font-size: .76rem; font-weight: 750; }
.auth-form input[type="email"], .auth-form input[type="password"], .auth-form input[type="text"] { width: 100%; border: 1px solid #d9dee7; border-radius: 10px; padding: 12px 13px; color: #263148; background: #fff; outline: none; }
.auth-form input:focus { border-color: #6757ed; box-shadow: 0 0 0 3px #6757ed17; }
.password-field { position: relative; display: block; }
.password-field input { padding-right: 48px !important; }
.password-toggle { position: absolute; top: 50%; right: 7px; display: grid; width: 36px; height: 34px; place-items: center; transform: translateY(-50%); border: 0; border-radius: 8px; padding: 0; color: #778195; background: transparent; line-height: 1; }
.password-toggle:hover { color: #5144c9; background: #f2f0ff; }
.password-toggle:focus-visible { outline: 2px solid #6757ed; outline-offset: 1px; }
.password-toggle[aria-pressed="true"] { color: #5144c9; background: #eeecff; }
.eye-icon { position: relative; display: block; width: 19px; height: 13px; border: 2px solid currentColor; border-radius: 70% 20%; transform: rotate(45deg); }
.eye-icon::before { position: absolute; top: 50%; left: 50%; width: 5px; height: 5px; transform: translate(-50%, -50%); border-radius: 50%; background: currentColor; content: ""; }
.password-toggle[aria-pressed="true"] .eye-icon::after { position: absolute; top: 50%; left: 50%; width: 24px; height: 2px; transform: translate(-50%, -50%) rotate(-45deg); border-radius: 2px; background: currentColor; box-shadow: 0 0 0 2px #eeecff; content: ""; }
.persistent-login-note { margin: -2px 0 0; border-radius: 9px; padding: 10px 12px; color: #656f82; background: #f5f6fa; font-size: .7rem; line-height: 1.5; }
.auth-error { margin: 0; border-radius: 9px; padding: 10px 12px; color: #9e3046; background: #fff0f3; font-size: .74rem; font-weight: 700; line-height: 1.45; }
.auth-error.success { color: #176b4a; background: #eaf8f1; }
.auth-link-button { width: max-content; margin: -7px 0 0 auto; border: 0; padding: 2px; color: #5b4ed7; background: transparent; font-size: .72rem; font-weight: 800; }
.auth-link-button:hover { color: #4033b9; text-decoration: underline; }
.auth-link-button.centered { margin: -5px auto 0; }
.auth-submit { width: 100%; padding: 12px 16px; }
.auth-setup-note { margin: -10px 0 0; color: #7e8797; font-size: .7rem; line-height: 1.5; text-align: center; }
.app-shell { --sidebar-width: 270px; position: relative; display: grid; min-width: 1180px; height: 100vh; grid-template-columns: var(--sidebar-width) minmax(0, 1fr); overflow: hidden; }
.app-shell.sidebar-collapsed { --sidebar-width: 36px; }
.app-shell > .workspace { grid-column: 2; grid-row: 1; }
.sidebar-toggle { position: absolute; z-index: 60; top: 12px; left: calc(var(--sidebar-width) - 16px); display: grid; place-items: center; width: 32px; height: 36px; padding: 0; border: 1px solid #dce1ed; border-radius: 9px; background: #fff; color: #6754ed; box-shadow: 0 2px 8px #25325214; font-size: 28px; line-height: 1; cursor: pointer; }
.sidebar-toggle:hover { background: #f0edff; }
.sidebar-toggle:focus-visible { outline: 3px solid #8b7aff; outline-offset: 2px; }
.sidebar-collapsed .sidebar-toggle { left: 2px; }
.table-storage-usage.total-storage-usage { background: #f4f1ff; border-color: #dcd5ff; }
.media-ocr-source { display: block; width: 100%; height: 110px; object-fit: contain; background: #eef2f7; border-radius: 6px; }
.media-ocr-source:not([src]) { display: none; }
.media-ocr-language-select { max-width: 100%; margin-left: 8px; border: 1px solid #d8deeb; border-radius: 5px; padding: 4px; color: #24344f; background: #fff; }
.sidebar { display: flex; height: 100vh; flex-direction: column; gap: 28px; overflow-y: auto; padding: 28px 20px 20px; border-right: 1px solid #e4e8ef; background: #fff; }
.brand { display: flex; align-items: center; justify-content: center; gap: 12px; color: inherit; text-decoration: none; }
.brand-logo { display: block; width: 230px; max-width: 100%; height: 116px; object-fit: contain; object-position: center; }
.brand-mark { display: grid; width: 42px; height: 42px; place-items: center; border-radius: 13px; color: #fff; background: linear-gradient(135deg, #6859ec, #8d7ff8); box-shadow: 0 8px 20px #6757ed33; font-size: 1.25rem; font-weight: 900; }
.brand strong, .brand small { display: block; }
.brand strong { font-size: 1.05rem; }
.brand small { margin-top: 2px; color: #8a93a3; font-size: .72rem; }
.sidebar-section { display: grid; gap: 10px; }
.section-heading { display: flex; min-height: 32px; align-items: center; justify-content: space-between; padding: 0 6px; color: #8b94a5; font-size: .72rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.icon-button { display: grid; width: 28px; height: 28px; place-items: center; border: 1px solid #e1e5ec; border-radius: 8px; color: #6757ed; background: #fff; font-size: 1.2rem; line-height: 1; }
.icon-button:hover { border-color: #6757ed; background: #f4f2ff; }
.table-navigation { display: grid; gap: 5px; }
.nav-item { display: flex; width: 100%; align-items: center; gap: 10px; border: 0; border-radius: 10px; padding: 10px 11px; color: #5e6879; background: transparent; text-align: left; }
.nav-item:hover { background: #f7f8fb; }
.nav-item.active { color: #4e40d6; background: #eeecff; font-weight: 750; }
.nav-badge { display: grid; width: 28px; height: 28px; flex: 0 0 28px; place-items: center; border-radius: 8px; color: #6d62d5; background: #fff; font-size: .7rem; font-weight: 800; }
.subadmin-list { display: grid; gap: 8px; }
.subadmin-item { display: grid; grid-template-columns: 28px minmax(0, 1fr) 28px; align-items: center; gap: 9px; padding: 3px 6px; }
.subadmin-item .avatar { width: 28px; height: 28px; font-size: .62rem; }
.subadmin-item > div { min-width: 0; }
.subadmin-item strong, .subadmin-item small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.subadmin-item strong { font-size: .8rem; }
.subadmin-item small { margin-top: 2px; color: #969eac; font-size: .67rem; }
.edit-access-button { display: grid; width: 28px; height: 28px; place-items: center; border: 1px solid transparent; border-radius: 8px; color: #7d8695; background: transparent; font-size: .85rem; }
.edit-access-button:hover { border-color: #ded9ff; color: #5748dc; background: #f2f0ff; }
.full-width { width: 100%; }
.account-card { display: grid; margin-top: auto; grid-template-columns: 36px minmax(0, 1fr); align-items: center; gap: 10px; border-top: 1px solid #edf0f4; padding: 18px 6px 0; }
.avatar { display: grid; width: 36px; height: 36px; place-items: center; border-radius: 50%; color: #fff; background: #27344b; font-size: .72rem; font-weight: 800; }
.account-card strong, .account-card small { display: block; }
.account-card strong { overflow: hidden; font-size: .78rem; text-overflow: ellipsis; white-space: nowrap; }
.account-card small { margin-top: 2px; color: #8d96a5; font-size: .68rem; }
.logout-button { grid-column: 1 / -1; width: 100%; border: 1px solid #dce1e8; border-radius: 8px; padding: 7px 8px; color: #5d6879; background: #fff; font-size: .72rem; font-weight: 750; }
.logout-button:hover { border-color: #c9c0ff; color: #5546dc; background: #f5f3ff; }
#open-role-preview { color: #5144c9; border-color: #d7d0ff; background: #f7f5ff; }
#exit-role-preview { color: #fff; border-color: #6757ed; background: #6757ed; }
#exit-role-preview:hover { color: #fff; background: #5444d9; }

.workspace { display: flex; min-width: 0; height: 100vh; min-height: 0; flex-direction: column; overflow: hidden; padding: 38px 40px 40px; }
.role-preview-banner { position: sticky; z-index: 13; top: 12px; display: flex; align-items: center; justify-content: space-between; gap: 15px; margin: -20px 0 22px; border: 1px solid #c9c2ff; border-radius: 12px; padding: 10px 14px; color: #382c9f; background: #f2f0ff; box-shadow: 0 10px 30px #4f42b51c; font-size: .82rem; font-weight: 750; }
body.is-role-preview .content-card { opacity: .92; }
.history-preview-banner { position: sticky; z-index: 12; top: 12px; display: flex; min-height: 58px; align-items: center; justify-content: space-between; gap: 20px; margin: -20px 0 22px; border: 1px solid #c9c2ff; border-radius: 12px; padding: 11px 14px; color: #382c9f; background: #f2f0ff; box-shadow: 0 10px 30px #4f42b51c; }
.history-preview-banner strong, .history-preview-banner span { display: block; }
.history-preview-banner span { margin-top: 3px; color: #7168ad; font-size: .72rem; }
.history-preview-actions { display: flex; gap: 9px; }
body.is-history-preview .sidebar,
body.is-history-preview .workspace > :not(.history-preview-banner) { pointer-events: none; user-select: none; filter: saturate(.7); opacity: .72; }
.topbar { display: flex; align-items: flex-end; justify-content: space-between; gap: 30px; margin-bottom: 24px; }
.eyebrow { margin: 0 0 7px; color: #6757ed; font-size: .72rem; font-weight: 850; letter-spacing: .12em; text-transform: uppercase; }
h1 { margin: 0; font-size: clamp(2rem, 3vw, 2.6rem); letter-spacing: -.035em; line-height: 1.1; }
.subtitle { margin: 9px 0 0; color: #778195; font-size: .9rem; }
.topbar-actions { display: flex; align-items: center; gap: 12px; }
.shootings-actions { display: inline-flex; flex: 0 0 auto; align-items: center; gap: 4px; }
#shootings-button { display: inline-flex; align-items: center; text-decoration: none; white-space: nowrap; }
#shootings-button[aria-disabled="true"] { opacity: .55; cursor: default; }
#shootings-settings-button { padding: 6px 9px; font-size: 1.1rem; line-height: 1; }
.table-settings-stack { display: grid; min-width: 142px; gap: 5px; }
.table-settings-stack .secondary-button { width: 100%; }
.table-storage-usage { display: flex; align-items: center; justify-content: space-between; gap: 8px; border: 1px solid #dfe4ec; border-radius: 8px; padding: 5px 8px; color: #758093; background: #fff; box-shadow: 0 2px 8px #2532520a; font-size: .58rem; font-weight: 750; line-height: 1.1; }
.table-storage-usage strong { color: #4d40c8; font-size: .68rem; white-space: nowrap; }
.view-controls { display: flex; align-items: center; gap: 8px; }
.view-controls [hidden] { display: none !important; }
.current-calendar-week { display: inline-flex; align-items: center; flex: 0 0 auto; gap: 8px; padding: 6px 12px 6px 6px; border: 1px solid #d6d0ff; border-radius: 9px; background: #eeecff; color: #5546dc; text-align: center; white-space: nowrap; }
.current-calendar-week-label { display: grid; gap: 2px; }
.current-calendar-week-label > span { font-size: .58rem; font-weight: 750; }
.current-calendar-week-label > strong { font-size: 1.2rem; font-weight: 850; line-height: 1.15; }
#jump-to-current-week { display: grid; place-items: center; width: 34px; height: 34px; padding: 0; border: 1px solid #d6d0ff; border-radius: 7px; background: #fff; color: #5546dc; font-size: 1.4rem; cursor: pointer; }
#jump-to-current-week:hover { background: #e1dcff; }
#jump-to-current-week:focus-visible { outline: 2px solid #5546dc; outline-offset: 2px; }
.view-switch { display: inline-flex; border: 1px solid #dce1e8; border-radius: 9px; padding: 3px; background: #fff; }
.view-switch button { border: 0; border-radius: 6px; padding: 6px 10px; color: #758093; background: transparent; font-size: .72rem; font-weight: 750; }
.view-switch button.active { color: #5546dc; background: #eeecff; box-shadow: 0 1px 3px #28334a12; }
.week-picker { display: inline-flex; height: 35px; align-items: center; gap: 5px; border: 1px solid #dce1e8; border-radius: 9px; padding: 0 7px 0 9px; color: #6e788b; background: #fff; font-size: .7rem; font-weight: 800; }
.week-picker select { border: 0; color: #3e4a5f; background: transparent; font-size: .73rem; font-weight: 800; outline: none; }
.week-step-button { display: grid; width: 35px; height: 35px; place-items: center; border: 1px solid #dce1e8; border-radius: 9px; padding: 0; color: #5c4ed8; background: #fff; font-size: 1.25rem; font-weight: 800; line-height: 1; }
.week-step-button:hover:not(:disabled) { border-color: #bfb6ff; background: #f3f1ff; }
.week-step-button:disabled { color: #b3bac5; background: #f6f7f9; cursor: default; }
.save-status { display: inline-flex; align-items: center; gap: 7px; color: #748092; font-size: .76rem; }
.save-status > span { width: 7px; height: 7px; border-radius: 50%; background: #35b47b; box-shadow: 0 0 0 3px #35b47b1f; }
.save-status[data-state="saving"] > span { background: #e6a23c; box-shadow: 0 0 0 3px #e6a23c1f; }
.save-status[data-state="error"] { color: #b43d52; }
.save-status[data-state="error"] > span { background: #c44860; box-shadow: 0 0 0 3px #c448601f; }
.primary-button, .secondary-button { border-radius: 9px; padding: 9px 13px; font-size: .78rem; font-weight: 750; }
.primary-button { border: 1px solid #6757ed; color: #fff; background: #6757ed; }
.primary-button:hover { background: #5546dc; }
.secondary-button { border: 1px solid #dce1e8; color: #4e5a6d; background: #fff; }
.secondary-button:hover { border-color: #bfc6d1; background: #fafbfc; }
.compact-button { padding: 7px 10px; font-size: .7rem; }
.quota-card { display: grid; margin-bottom: 20px; grid-template-columns: minmax(340px, 1fr) 190px 190px; align-items: center; gap: 24px; border: 1px solid #e2e6ed; border-radius: 14px; padding: 17px 20px; background: #fff; box-shadow: 0 8px 25px #1f2a4409; }
.quota-card > div { display: flex; align-items: center; gap: 12px; }
.card-icon { display: grid; width: 38px; height: 38px; place-items: center; border-radius: 10px; color: #6757ed; background: #efedff; font-size: 1.1rem; }
.quota-card h2, .content-card h2 { margin: 0; font-size: .95rem; }
.quota-card p, .content-card-header p { margin: 4px 0 0; color: #929baa; font-size: .73rem; }
.quota-card label { display: flex; align-items: center; justify-content: flex-end; gap: 9px; color: #657084; font-size: .76rem; font-weight: 700; }
.quota-card input { width: 58px; border: 1px solid #d9dee7; border-radius: 8px; padding: 7px 8px; text-align: center; }
.quota-card input:focus, dialog input:focus, dialog select:focus { border-color: #6757ed; outline: 3px solid #6757ed1c; }
.content-card { display: flex; min-height: 0; flex: 1; flex-direction: column; overflow: hidden; border: 1px solid #e2e6ed; border-radius: 15px; background: #fff; box-shadow: 0 12px 32px #1f2a440c; }
.content-card-header { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 17px 20px; border-bottom: 1px solid #e7eaf0; }
.content-header-actions { display: flex; align-items: center; gap: 18px; }
.undo-button { display: grid; width: 32px; height: 32px; flex: 0 0 32px; place-items: center; border: 1px solid #d8dce4; border-radius: 50%; padding: 0; color: #5d4ed5; background: #fff; font-size: 1.15rem; font-weight: 850; line-height: 1; transition: .15s ease; }
.undo-button:hover:not(:disabled) { border-color: #8173ee; color: #fff; background: #6757ed; transform: translateY(-1px); }
.undo-button:disabled { color: #b7bdc8; background: #f5f6f8; cursor: default; opacity: .75; }
.hidden-weeks-button { display: inline-flex; align-items: center; gap: 6px; border: 1px solid #ded9ff; border-radius: 8px; padding: 7px 10px; color: #5c4ed8; background: #f4f2ff; font-size: .7rem; font-weight: 750; }
.hidden-weeks-button strong { display: grid; min-width: 18px; height: 18px; place-items: center; border-radius: 999px; color: #fff; background: #6757ed; font-size: .62rem; }
.hidden-weeks-button:disabled { border-color: #e4e7ec; color: #9ba3b0; background: #f7f8fa; cursor: default; }
.hidden-weeks-button:disabled strong { background: #aab1bc; }
.table-scroll { min-height: 0; flex: 1; overflow: auto; overscroll-behavior: contain; }
.content-card.week-view .content-table tr[data-week] > td { height: var(--week-row-height, 165px); }
.content-card:not(.week-view) .content-table tr[data-year-week-height] > td { height: var(--year-week-row-height, 132px); }
.content-table { width: 100%; min-width: 100%; border-collapse: separate; border-spacing: 0; table-layout: fixed; }
.content-table th { position: sticky; z-index: 50; top: 0; padding: 12px 13px; border-bottom: 1px solid #dee3ea; color: #727d8f; background: #f8f9fb; font-size: .68rem; font-weight: 850; letter-spacing: .045em; text-align: left; text-transform: uppercase; }
.content-table th.has-delete-column { padding-right: 34px; }
.content-table th.column-draggable { cursor: grab; user-select: none; }
.content-table th.column-draggable:active { cursor: grabbing; }
.content-table th.column-dragging { opacity: .42; }
.content-table th.column-drop-before::before,
.content-table th.column-drop-after::after { position: absolute; z-index: 8; top: 4px; bottom: 4px; width: 3px; border-radius: 3px; background: #6757ed; box-shadow: 0 0 0 2px #fff; content: ""; }
.content-table th.column-drop-before::before { left: -2px; }
.content-table th.column-drop-after::after { right: -2px; }
body.is-dragging-columns { cursor: grabbing; }
.column-resizer { position: absolute; z-index: 5; top: 0; right: 0; width: 8px; height: 100%; cursor: col-resize; user-select: none; }
.column-resizer::after { position: absolute; top: 24%; bottom: 24%; left: 3px; width: 2px; border-radius: 2px; background: transparent; content: ""; transition: background .12s ease; }
.column-resizer:hover::after, body.is-resizing-columns .column-resizer::after { background: #8b7ff2; }
body.is-resizing-columns { cursor: col-resize; user-select: none; }
.content-table th + th, .content-table td + td { border-left: 1px solid #e7eaf0; }
.content-table td { height: 132px; padding: 12px 13px; border-bottom: 1px solid #e7eaf0; vertical-align: top; }
.content-table .virtual-week-placeholder td { height: var(--virtual-week-height, 132px); padding: 0; background: #fff; pointer-events: none; }
.content-table tbody tr:hover td { background: #fcfcfe; }
.content-table .virtual-week-placeholder:hover td { background: #fff; }
.content-table tbody tr.story-row td { background: #fcfbff; }
.content-table tbody tr.week-end td { border-bottom: 2px solid #d9dee7; }
.content-card:not(.week-view) .content-table tbody tr.week-end td,
.content-card:not(.week-view) .content-table tbody .week-cell { border-bottom: 3px solid #c9d0db; }
.week-column { width: 1%; white-space: nowrap; }
.approval-column { width: 92px; text-align: center !important; }
.media-column { width: 380px; }
.text-column { width: 300px; }
.translated-text-column { width: 300px; }
.changes-column { width: 360px; }
.column-title-with-legend { display: grid; gap: 8px; }
.change-author-legend { display: flex; flex-wrap: wrap; gap: 5px 9px; color: #536074; font-size: .62rem; font-weight: 750; letter-spacing: 0; text-transform: none; }
.change-author { display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; }
.change-author i, .change-message header i { display: inline-block; width: 9px; height: 9px; flex: 0 0 9px; border-radius: 2px; background: var(--comment-color); content: ""; }
.status-column { width: 155px; text-align: center !important; }
.custom-column { width: 180px; padding-right: 40px !important; }
.delete-custom-column { position: absolute; z-index: 6; top: 50%; right: 11px; display: grid; width: 22px; height: 22px; place-items: center; border: 0; border-radius: 6px; padding: 0; color: #a34b5e; background: #fff0f3; font-size: .9rem; font-weight: 800; line-height: 1; opacity: 0; pointer-events: none; transform: translateY(-50%); transition: opacity .12s ease, background .12s ease; }
.custom-column:hover .delete-custom-column, .delete-custom-column:focus-visible { opacity: 1; pointer-events: auto; }
.delete-custom-column:hover { color: #fff; background: #c44860; }
.delete-translated-column { position: absolute; z-index: 6; top: 50%; right: 12px; display: grid; width: 14px; height: 14px; place-items: center; border: 1px solid #d9a9b2; border-radius: 50%; padding: 0 0 1px; color: #a45a68; background: #fff; font-size: .56rem; font-weight: 900; line-height: 1; opacity: .58; transform: translateY(-50%); transition: opacity .12s ease, color .12s ease, background .12s ease; }
.delete-translated-column:hover, .delete-translated-column:focus-visible { color: #fff; background: #c44860; opacity: 1; }
.week-cell { width: 1%; padding: 12px 8px !important; border-right: 1px solid #e7eaf0; color: #253148; font-size: .8rem; font-weight: 850; text-align: center; vertical-align: middle !important; white-space: nowrap; }
.content-table .week-cell + td { border-left: 0; }
.week-cell small { display: block; margin-top: 4px; color: #a1a8b4; font-size: .64rem; font-weight: 600; }
.month-week { display: flex; width: max-content; margin: 10px auto 0; border-radius: 6px; padding: 4px 7px; color: #6757ed; background: #efedff; font-size: .64rem; font-weight: 850; letter-spacing: .02em; }
.hide-week-button { display: flex; width: 28px; height: 28px; margin: 7px auto 0; align-items: center; justify-content: center; border: 0; border-radius: 7px; padding: 0; color: #8a92a1; background: #f0f2f5; }
.hide-week-button svg { width: 16px; height: 16px; }
.hide-week-button:hover { color: #c13d55; background: #fff0f3; }
.content-type { display: inline-flex; margin-top: 9px; border-radius: 999px; padding: 5px 10px; font-size: .68rem; font-weight: 850; letter-spacing: .05em; text-transform: uppercase; }
.content-type.story { color: #7b45b0; background: #f4eaff; }
.content-type.post { color: #176b8c; background: #e7f6fb; }
.ai-row-button { display: grid; width: 24px; height: 24px; margin: 7px auto 0; place-items: center; border: 1px solid #d8d2ff; border-radius: 50%; padding: 0; color: #5e4fe0; background: #f4f2ff; font-size: .72rem; line-height: 1; transition: .15s ease; }
.ai-row-button:hover:not(:disabled), .ai-row-button:focus-visible { border-color: #6757ed; color: #fff; background: #6757ed; box-shadow: 0 0 0 3px #6757ed18; outline: none; }
.ai-row-button:disabled { color: #aab0bb; background: #f2f3f5; border-color: #e0e3e8; cursor: default; }
.ai-row-button.is-loading { animation: ai-pulse .9s ease-in-out infinite alternate; }
@keyframes ai-pulse { to { transform: scale(1.12); box-shadow: 0 0 0 5px #6757ed18; } }
.row-cut-button, .row-paste-button { display: grid; min-width: 24px; min-height: 24px; margin: 6px auto 0; place-items: center; border: 1px solid #f0c9cf; border-radius: 7px; padding: 2px 6px; color: #ac3650; background: #fff3f5; font-size: .74rem; font-weight: 800; line-height: 1; }
.row-cut-button:hover:not(:disabled), .row-cut-button:focus-visible { border-color: #b83b55; color: #fff; background: #b83b55; outline: none; }
.row-cut-button:disabled { opacity: .45; cursor: default; }
.row-paste-button { color: #16734e; border-color: #a9dcc3; background: #ebf9f2; font-size: .6rem; }
.row-paste-button:hover, .row-paste-button:focus-visible { color: #fff; border-color: #218963; background: #218963; outline: none; }
.check-cell .row-action-buttons { display: inline-flex; width: 100%; flex-direction: row; flex-wrap: nowrap; align-items: center; justify-content: center; gap: 6px; margin-top: 7px; }
.row-action-buttons:empty { display: none; }
.check-cell .row-action-buttons > .ai-row-button, .check-cell .row-action-buttons > .row-cut-button, .check-cell .row-action-buttons > .row-paste-button { flex: 0 0 auto; margin: 0; }
.row-cut-banner { display: flex; width: calc(100% - 40px); margin: 12px 20px; align-items: center; justify-content: center; gap: 12px; border: 1px solid #c53650; border-radius: 9px; padding: 9px 12px; color: #fff; background: #c53650; font-size: .76rem; font-weight: 800; }
.row-cut-banner:hover { background: #a92740; }
.row-cut-banner[hidden] { display: none; }
.invitation-result { margin: 12px 0; padding: 12px; border: 1px solid #cdd7fa; border-radius: 9px; background: #f5f7ff; }
.invitation-result[hidden], #invitation-delivery[hidden], #subadmin-save-button[hidden] { display: none; }
.invitation-result input { width: 100%; }
.invitation-result textarea { width: 100%; min-height: 78px; resize: vertical; }
#subadmin-dialog { width: min(680px, calc(100% - 30px)); }
.invitation-steps { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin: 14px 0; }
.invitation-step { display: flex; gap: 10px; align-items: flex-start; min-width: 0; border: 1px solid #d9def7; border-radius: 11px; padding: 12px; background: #f8f9ff; }
.invitation-step > div { min-width: 0; width: 100%; }
.invitation-step label { display: block; margin-top: 12px; }
.invitation-step input { width: 100%; }
.invitation-step button { margin-top: 12px; width: 100%; }
.invitation-step-number { display: grid; flex: 0 0 25px; width: 25px; height: 25px; place-items: center; border-radius: 50%; color: #fff; background: #6355dc; font-size: .73rem; font-weight: 800; }
.invitation-step strong, .invitation-step small { display: block; }
.invitation-step strong { color: #26324a; font-size: .76rem; }
.invitation-step small { margin-top: 4px; color: #667286; font-size: .68rem; line-height: 1.35; }
@media (max-width: 540px) { .invitation-steps { grid-template-columns: 1fr; } }
.content-table tbody tr.row-cut-source td { background: #fff4f5 !important; }
.check-cell { padding-top: 12px !important; vertical-align: middle !important; text-align: center; }
.check-cell > .content-type { display: flex; width: max-content; margin: 7px auto 0; align-items: center; justify-content: center; }
.check-cell > .needs-work-control { display: flex; margin: 7px auto 1px; }
.check-control { position: relative; display: inline-flex; cursor: pointer; }
/* Keep the native focus target inside its visible label in the scrolled table. */
.check-control input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; pointer-events: none; }
.check-box { display: grid; width: 25px; height: 25px; place-items: center; border: 1.5px solid #cdd3dd; border-radius: 7px; color: transparent; background: #fff; transition: .14s ease; }
.check-control input:focus-visible + .check-box { outline: 3px solid #6757ed26; }
.check-control input:checked + .check-box { border-color: #35b47b; color: #fff; background: #35b47b; }
.status-check input:checked + .check-box { border-color: #6757ed; background: #6757ed; }
.status-label { display: block; margin-top: 8px; color: #929aa8; font-size: .65rem; }
.publication-control { display: grid; justify-items: center; }
.completed-control { display: grid; justify-items: center; margin-top: 10px; padding-top: 10px; border-top: 1px solid #e7e9ef; }
.completed-check input:checked + .check-box { border-color: #168665; background: #168665; }
.completed-status-label { margin-top: 5px; color: #405065; font-weight: 800; }
.completed-control small { display: block; margin-top: 3px; color: #9aa3b1; font-size: .52rem; line-height: 1.25; }
.completion-preview-media { outline: none; }
.instagram-plan-button { display: block; width: 100%; margin-top: 9px; border: 1px solid #dfd9ff; border-radius: 7px; padding: 6px 7px; color: #594bd7; background: #f4f2ff; font-size: .61rem; font-weight: 800; line-height: 1.25; }
.instagram-plan-button:hover { border-color: #8f83ef; background: #ebe8ff; }
.instagram-row-status { display: inline-flex; margin-top: 8px; border-radius: 999px; padding: 4px 7px; color: #6658d8; background: #efedff; font-size: .56rem; font-weight: 800; }
.instagram-row-status.published { color: #13724c; background: #e5f7ef; }
.instagram-row-status.failed { color: #aa3d52; background: #fff0f3; }
.content-card.week-view .content-table tr[data-week] > td { border-bottom-width: 3px; border-bottom-color: #dfe3e9; }
.content-card.week-view .content-table tr[data-week].row-resize-target > td { border-bottom-color: #7566eb; }
.content-card.week-view .content-table tr[data-week].row-resize-target > td,
.content-card.week-view .content-table tr[data-week].row-resize-target > td * { cursor: row-resize !important; }
.content-card:not(.week-view) .content-table tr.week-end.row-resize-target > td,
.content-card:not(.week-view) .content-table .week-cell.row-resize-target { border-bottom-color: #7566eb; }
.content-card:not(.week-view) .content-table tr.week-end.row-resize-target > td,
.content-card:not(.week-view) .content-table tr.week-end.row-resize-target > td *,
.content-card:not(.week-view) .content-table .week-cell.row-resize-target,
.content-card:not(.week-view) .content-table .week-cell.row-resize-target * { cursor: row-resize !important; }
body.is-resizing-rows { cursor: row-resize; user-select: none; }
body.is-resizing-rows * { cursor: row-resize !important; }
.media-list { display: grid; height: auto; min-width: 0; min-height: 0; grid-template-columns: minmax(0, 1fr) minmax(0, 112px); align-items: stretch; gap: 9px; }
.media-list.is-empty { grid-template-columns: minmax(0, 1fr); }
.media-list.is-empty .media-slots { grid-column: 1 / -1; width: 100%; }
.media-cell { position: relative; }
.media-cell .media-list { position: absolute; inset: 12px 13px; }
/* Shared by every existing/new customer table, regardless of media orientation. */
.media-slots { display: grid; width: 100%; height: 100%; min-width: 0; min-height: 0; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); grid-template-rows: minmax(0, 1fr); column-gap: min(9px, calc(50% / var(--media-slot-count, 1))); }
.media-slot { position: relative; width: 100%; height: 100%; min-width: 0; max-width: 100%; min-height: 0; max-height: 100%; aspect-ratio: auto; }
.drop-zone { display: grid; width: 100%; height: 100%; min-width: 0; min-height: 0; grid-template-columns: minmax(0, 1fr); grid-template-rows: minmax(0, 1fr); place-items: center; overflow: hidden; border: 1.5px dashed #cbd1db; border-radius: 9px; color: #6e788a; background: #fafbfc; cursor: pointer; outline: none; transition: .15s ease; }
.drop-zone:hover, .drop-zone:focus-visible, .drop-zone.dragging { border-color: #6757ed; color: #5547d4; background: #f5f3ff; box-shadow: 0 0 0 3px #6757ed17; }
.drop-zone.has-media { border-color: transparent; border-style: solid; background: #fff; box-shadow: none; }
.drop-zone.has-media:hover, .drop-zone.has-media:focus-visible, .drop-zone.has-media.dragging { border-color: #6757ed; background: #fff; box-shadow: 0 0 0 3px #6757ed17; }
.drop-placeholder { display: flex; align-items: center; flex-direction: column; gap: 2px; padding: 8px; text-align: center; }
.drop-placeholder > span { font-size: 1rem; font-weight: 900; }
.drop-placeholder strong { font-size: .7rem; }
.drop-placeholder small { color: #a0a7b3; font-size: .6rem; }
.preview { position: relative; width: 100%; height: 100%; min-height: 0; overflow: hidden; border-radius: 8px; background: transparent; }
.media-file-state-indicator { position: absolute; z-index: 6; bottom: 7px; left: 7px; display: flex; align-items: center; gap: 4px; border-radius: 999px; padding: 3px; background: #fffffff2; box-shadow: 0 1px 5px #17203338; pointer-events: none; }
.media-file-state-dot { display: block; width: 9px; height: 9px; border: 1px solid #fff; border-radius: 50%; box-shadow: 0 0 0 1px #17203326; }
.media-file-state-dot.original { background: #159447; }
.media-file-state-dot.preview { background: #1976d2; }
.drop-zone[data-file-state="preview_only"] .media-file-state-dot.preview { background: #ec4899; }
.preview img, .preview video { display: block; width: 100%; height: 100%; min-width: 0; max-width: 100%; min-height: 0; max-height: 100%; object-fit: cover; cursor: grab; transition: opacity .15s ease, transform .15s ease; }
.preview img.portrait-media, .preview video.portrait-media { object-fit: contain; background: #eef1f5; }
.preview img:active, .preview video:active { cursor: grabbing; }
.preview img.media-copy-dragging, .preview video.media-copy-dragging { opacity: .62; transform: scale(.98); }
.preview::after { position: absolute; right: 34px; bottom: 5px; border-radius: 6px; padding: 4px 6px; color: #fff; background: #172033d9; content: "Ziehen: sortieren oder kopieren"; font-size: .55rem; font-weight: 750; opacity: 0; pointer-events: none; transition: opacity .15s ease; }
.media-slot:hover .preview:not([hidden])::after { opacity: 1; }
.media-slot.media-drop-before::before,
.media-slot.media-drop-after::after { position: absolute; z-index: 7; top: 4px; bottom: 4px; width: 4px; border-radius: 4px; background: #6757ed; box-shadow: 0 0 0 2px #fff; content: ""; pointer-events: none; }
.media-slot.media-drop-before::before { left: -6px; }
.media-slot.media-drop-after::after { right: -6px; }
.remove-media { position: absolute; top: 5px; right: 5px; display: grid; width: 22px; height: 22px; place-items: center; border: 0; border-radius: 50%; color: #fff; background: #172033cc; line-height: 1; }
.media-note-button { position: absolute; z-index: 9; right: 5px; bottom: 5px; display: grid; width: 25px; height: 25px; place-items: center; border: 1px solid #ffffffc7; border-radius: 7px; padding: 0; color: #fff; background: #172033dd; box-shadow: 0 2px 7px #1720334a; font-size: .78rem; font-weight: 900; line-height: 1; }
.media-note-button:hover, .media-note-button:focus-visible, .media-note-button.has-note { color: #fff; background: #6757ed; }
.media-ocr-button { position: absolute; z-index: 9; top: 5px; left: 5px; min-width: 32px; height: 24px; border: 1px solid #ffffffc7; border-radius: 7px; padding: 0 5px; color: #fff; background: #172033dd; box-shadow: 0 2px 7px #1720334a; font-size: .56rem; font-weight: 900; letter-spacing: .04em; line-height: 1; }
.media-ocr-button:hover, .media-ocr-button:focus-visible, .media-ocr-button.has-text { color: #fff; background: #0a8f9c; }
.media-note-tooltip { position: absolute; z-index: 30; top: calc(100% + 7px); left: 0; display: grid; width: clamp(210px, 230%, 320px); gap: 3px; border: 1px solid #d7dcea; border-radius: 10px; padding: 10px 12px; color: #202b3f; background: #fff; box-shadow: 0 14px 32px #17203330; font-size: .72rem; font-weight: 650; line-height: 1.5; opacity: 0; overflow-wrap: anywhere; pointer-events: none; transform: translateY(-3px); transition: opacity .14s ease, transform .14s ease; white-space: pre-wrap; }
.media-note-tooltip strong { color: #6757ed; font-size: .62rem; letter-spacing: .05em; text-transform: uppercase; }
.media-slot:last-child .media-note-tooltip { right: 0; left: auto; }
.media-slot:hover, .media-slot:focus-within { z-index: 25; }
.media-slot:hover .media-note-tooltip, .media-slot:focus-within .media-note-tooltip { opacity: 1; transform: translateY(0); }
.media-slot.is-editing-note { z-index: 40; }
.media-slot.is-editing-note .media-note-tooltip { display: none; }
.media-slot.is-editing-ocr { z-index: 40; }
.media-slot.is-editing-ocr .media-note-tooltip { display: none; }
.media-note-editor { position: absolute; z-index: 40; top: calc(100% + 7px); left: 0; display: grid; width: min(360px, calc(100vw - 36px)); gap: 8px; border: 1px solid #cfc9ff; border-radius: 12px; padding: 11px; color: #202b3f; background: #fff; box-shadow: 0 16px 38px #17203335; }
.media-slot:last-child .media-note-editor { right: 0; left: auto; }
.media-note-editor-header { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.media-note-editor-header strong { color: #4f42cf; font-size: .72rem; }
.media-note-editor-close { display: grid; width: 24px; height: 24px; flex: 0 0 24px; place-items: center; border: 0; border-radius: 7px; padding: 0; color: #7c8594; background: #f3f4f7; font-size: 1rem; line-height: 1; }
.media-note-editor-close:hover { color: #fff; background: #6757ed; }
.media-note-editor-file { overflow: hidden; color: #7c8594; font-size: .62rem; font-weight: 700; text-overflow: ellipsis; white-space: nowrap; }
.media-note-editor textarea { width: 100%; min-height: 92px; resize: vertical; border: 1px solid #d9deea; border-radius: 9px; padding: 9px 10px; color: #263148; background: #fcfcfd; font-size: .72rem; line-height: 1.45; outline: none; }
.media-note-editor textarea:focus { border-color: #6757ed; box-shadow: 0 0 0 3px #6757ed17; }
.media-note-editor-actions { display: flex; align-items: center; justify-content: flex-end; gap: 7px; }
.media-note-editor-actions .primary-button, .media-note-editor-actions .secondary-button { padding: 7px 10px; font-size: .68rem; }
.media-note-editor-actions .media-note-delete { margin-right: auto; padding: 6px 0; }
.media-ocr-editor { position: absolute; z-index: 41; top: calc(100% + 7px); left: 0; display: grid; width: min(440px, calc(100vw - 36px)); gap: 8px; border: 1px solid #9edee3; border-radius: 12px; padding: 11px; color: #202b3f; background: #fff; box-shadow: 0 16px 38px #17203335; }
.media-slot:last-child .media-ocr-editor { right: 0; left: auto; }
.media-slot.portrait-media .media-ocr-editor { right: auto; left: 0; }
.media-ocr-editor-header { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.media-ocr-editor-header strong { color: #087c86; font-size: .74rem; }
.media-ocr-editor-close { display: grid; width: 24px; height: 24px; flex: 0 0 24px; place-items: center; border: 0; border-radius: 7px; padding: 0; color: #7c8594; background: #f3f4f7; font-size: 1rem; line-height: 1; }
.media-ocr-editor-close:hover { color: #fff; background: #0a8f9c; }
.media-ocr-editor-file { overflow: hidden; color: #7c8594; font-size: .62rem; font-weight: 700; text-overflow: ellipsis; white-space: nowrap; }
.media-ocr-language { margin: 0; color: #6c7789; font-size: .61rem; font-weight: 700; }
.media-ocr-editor textarea { width: 100%; min-height: 120px; resize: vertical; border: 1px solid #d9deea; border-radius: 9px; padding: 9px 10px; color: #263148; background: #fcfcfd; font-size: .72rem; line-height: 1.45; outline: none; }
.media-ocr-editor textarea:focus { border-color: #0a8f9c; box-shadow: 0 0 0 3px #0a8f9c18; }
.media-ocr-status { min-height: 1.1em; margin: 0; color: #687588; font-size: .62rem; font-weight: 700; }
.media-ocr-status.loading { color: #765dd6; }
.media-ocr-status.success { color: #087c56; }
.media-ocr-status.error { color: #b43d52; }
.media-ocr-copy-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; }
.media-ocr-copy-actions .secondary-button { width: 100%; border-color: #91d7d0; padding: 8px 9px; color: #087d70; background: #f2fffc; font-size: .68rem; }
.media-ocr-copy-actions .secondary-button:hover:not(:disabled), .media-ocr-copy-actions .secondary-button.copied { border-color: #18a997; color: #fff; background: #18a997; }
.media-ocr-copy-actions .secondary-button:disabled { opacity: .48; cursor: default; }
.media-ocr-editor-actions { display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: 7px; }
.media-ocr-editor-actions .primary-button, .media-ocr-editor-actions .secondary-button { padding: 7px 10px; font-size: .68rem; }
.media-ocr-editor-actions .media-ocr-delete { margin-right: auto; padding: 6px 0; }
@media (max-width: 560px) { .media-ocr-copy-actions { grid-template-columns: 1fr; } }
.add-media-button { display: flex; width: 100%; height: 100%; min-height: 0; grid-column: 2; align-items: center; justify-content: center; flex-direction: column; gap: 5px; border: 1.5px dashed #c9c4ed; border-radius: 8px; padding: 9px; color: #6757ed; background: #fff; font-size: .68rem; font-weight: 800; text-align: center; cursor: pointer; outline: none; transition: .15s ease; }
.add-media-button strong { font-size: 1.1rem; line-height: 1; }
.add-media-button small { color: #9b94bf; font-size: .58rem; font-weight: 650; }
.add-media-button:hover, .add-media-button:focus-visible, .add-media-button.dragging { border-color: #6757ed; background: #f5f3ff; box-shadow: 0 0 0 3px #6757ed17; }
.content-text, .translated-content-text, .change-request { width: 100%; min-height: 96px; resize: vertical; border: 1px solid #dce1e8; border-radius: 9px; padding: 10px 11px; color: #263148; background: #fcfcfd; font-size: .75rem; line-height: 1.5; outline: none; }
.content-text:focus, .translated-content-text:focus, .change-request:focus { border-color: #6757ed; box-shadow: 0 0 0 3px #6757ed17; }
.customer-text-cell { position: relative; }
.text-cell-layout { position: absolute; inset: 12px 13px; display: grid; min-height: 0; grid-template-rows: minmax(0, 1fr) auto; gap: 5px; }
.text-cell-layout > .proofreading-field { min-height: 0; height: 100%; }
.text-cell-layout > .content-text, .text-cell-layout > .translated-content-text,
.text-cell-layout > .proofreading-field > .content-text, .text-cell-layout > .proofreading-field > .translated-content-text { height: 100%; min-height: 0; resize: none; }
.text-cell-layout.is-expanded > .content-text, .text-cell-layout.is-expanded > .translated-content-text,
.text-cell-layout.is-expanded > .proofreading-field > .content-text, .text-cell-layout.is-expanded > .proofreading-field > .translated-content-text { overflow-y: hidden; }
.content-table tr.text-row-expanded > td { height: var(--expanded-text-row-height) !important; }
.proofreading-field { position: relative; border-radius: 9px; background: #fcfcfd; }
.proofreading-field .content-text, .proofreading-field .translated-content-text { position: relative; z-index: 1; display: block; background: transparent; }
.proofreading-highlights { position: absolute; z-index: 0; inset: 0; overflow: hidden; border: 1px solid transparent; border-radius: 9px; padding: 10px 11px; color: transparent; background: transparent; font-family: inherit; font-size: .75rem; line-height: 1.5; overflow-wrap: break-word; pointer-events: none; white-space: pre-wrap; }
.proofreading-highlights mark { border-radius: 3px; color: transparent; background: #f59e0b66; box-shadow: 0 0 0 1px #e58a0838; }
.proofreading-warning { display: inline-grid; width: 22px; height: 22px; flex: 0 0 22px; place-items: center; border: 1px solid #eaa33a; border-radius: 50%; color: #a85d00; background: #fff2cf; font-size: .72rem; font-weight: 950; line-height: 1; cursor: help; }
.proofreading-warning[hidden] { display: none; }
.change-comments-cell { position: relative; padding: 9px !important; }
/* Reserve the original minimum/expanded height while anchoring the composer to the cell bottom. */
.content-card:not(.week-view) .change-comments-cell::before { content: ""; display: block; height: 155px; }
.content-card:not(.week-view) .change-comments-cell:has(> .change-chat.is-expanded)::before { height: 395px; }
.change-comments-cell > .change-chat { position: absolute; inset: 9px; display: grid; min-height: 0; gap: 8px; grid-template-rows: minmax(0, 1fr) auto; padding-top: 20px; }
.change-comments-cell .change-message-list, .change-comments-cell .change-chat.is-expanded .change-message-list { min-height: 0; max-height: none; }
.change-chat-toolbar { position: absolute; z-index: 2; top: -2px; left: 0; display: flex; align-items: center; gap: 5px; }
.change-chat-expand-button, .change-chat-clear-button { display: grid; width: 20px; height: 20px; place-items: center; border: 1px solid #d9dee7; border-radius: 6px; padding: 0; color: #687387; background: #fff; font-size: .9rem; font-weight: 900; line-height: 1; transition: .15s ease; cursor: pointer; }
.change-chat-expand-button:hover, .change-chat-expand-button:focus-visible { border-color: #6757ed; color: #fff; background: #6757ed; outline: none; }
.change-chat-clear-button { color: #b95260; font-size: .72rem; }
.change-chat-clear-button:hover, .change-chat-clear-button:focus-visible { border-color: #c85665; color: #fff; background: #c85665; outline: none; }
.change-chat-expand-button span { display: block; transform: translateY(-1px); transition: transform .16s ease; }
.change-chat.is-expanded .change-chat-expand-button span { transform: translateY(1px) rotate(180deg); }
.change-message-list { display: flex; max-height: 145px; min-height: 62px; flex-direction: column; gap: 7px; overflow-y: auto; padding: 2px 5px 2px 2px; scrollbar-gutter: stable; }
.change-chat.is-expanded .change-message-list { min-height: 320px; max-height: min(55vh, 700px); }
.change-message { width: fit-content; max-width: 88%; align-self: flex-start; border: 1px solid var(--comment-border); border-radius: 10px 10px 10px 3px; padding: 7px 9px; color: var(--comment-color); background: var(--comment-soft); overflow-wrap: anywhere; }
.change-message.is-own { align-self: flex-end; border-radius: 10px 10px 3px; }
.change-message header { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 4px; font-size: .59rem; font-weight: 850; }
.change-message header span { display: flex; align-items: center; gap: 4px; }
.change-message header .change-message-header-actions { gap: 5px; }
.change-message time { color: #8d95a3; font-size: .53rem; font-weight: 650; white-space: nowrap; }
.change-message-edited { color: #8d95a3; font-size: .5rem; font-weight: 650; }
.change-message-edit-button { display: grid; width: 16px; height: 16px; place-items: center; border: 1px solid color-mix(in srgb, var(--comment-color) 28%, transparent); border-radius: 50%; padding: 0 0 1px; color: var(--comment-color); background: #fff; font-size: .57rem; line-height: 1; cursor: pointer; opacity: .72; }
.change-message-delete-button { display: grid; width: 16px; height: 16px; place-items: center; border: 1px solid #e3aeb5; border-radius: 50%; padding: 0 0 1px; color: #b95260; background: #fff; font-size: .62rem; line-height: 1; cursor: pointer; opacity: .72; }
.change-message-edit-button:hover, .change-message-edit-button:focus-visible, .change-message-delete-button:hover, .change-message-delete-button:focus-visible { opacity: 1; box-shadow: 0 0 0 2px color-mix(in srgb, var(--comment-color) 14%, transparent); outline: none; }
.change-message.is-editing .change-message-edit-button, .change-message.is-editing .change-message-delete-button { visibility: hidden; }
.change-message p { margin: 0; color: #344055; font-size: .7rem; line-height: 1.4; white-space: pre-wrap; }
.change-message-editor { display: grid; min-width: 210px; gap: 5px; }
.change-message-edit-input { width: 100%; min-height: 54px; resize: vertical; border: 1px solid var(--comment-border); border-radius: 7px; padding: 7px 8px; color: #344055; background: #fff; font: inherit; font-size: .7rem; line-height: 1.4; outline: none; }
.change-message-edit-input:focus { border-color: var(--comment-color); box-shadow: 0 0 0 2px color-mix(in srgb, var(--comment-color) 15%, transparent); }
.change-message-edit-actions { display: flex; justify-content: flex-end; gap: 5px; }
.change-message-edit-actions button { border: 1px solid var(--comment-border); border-radius: 6px; padding: 4px 7px; color: var(--comment-color); background: #fff; font-size: .55rem; font-weight: 800; cursor: pointer; }
.change-message-edit-actions [data-save-change-message] { border-color: var(--comment-color); color: #fff; background: var(--comment-color); }
.change-chat-empty { margin: auto; color: #9aa2af; font-size: .66rem; text-align: center; }
.change-message-composer { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: 6px; }
.change-message-input { width: 100%; min-height: 47px; max-height: 90px; resize: vertical; border: 1px solid var(--comment-border); border-radius: 9px; padding: 8px 9px; color: var(--comment-color); background: #fff; font-size: .7rem; font-weight: 650; line-height: 1.4; outline: none; }
.change-message-input:focus { border-color: var(--comment-color); box-shadow: 0 0 0 3px color-mix(in srgb, var(--comment-color) 18%, transparent); }
.change-message-composer button { min-height: 34px; border: 1px solid var(--comment-color); border-radius: 8px; padding: 7px 9px; color: #fff; background: var(--comment-color); font-size: .62rem; font-weight: 800; }
.change-message-composer button:hover { filter: brightness(.93); }
.character-count { display: block; margin-top: 5px; color: #a0a7b3; font-size: .62rem; text-align: right; }
.text-cell-footer { display: flex; align-items: center; justify-content: flex-end; gap: 7px; }
.text-cell-footer .character-count { margin-top: 0; }
.text-cell-footer-left { display: flex; min-width: 0; align-items: center; gap: 6px; margin-right: auto; }
.customer-text-ok-control { position: relative; display: inline-flex; flex: 0 0 auto; align-items: center; gap: 6px; color: #768195; font-size: .59rem; font-weight: 750; cursor: pointer; white-space: nowrap; }
.customer-text-ok-control input { position: absolute; inset: 0; width: 1px; height: 1px; margin: 0; overflow: hidden; opacity: 0; pointer-events: none; }
.customer-text-ok-box { display: inline-grid; width: 18px; height: 18px; place-items: center; border: 1px solid #cfd6df; border-radius: 5px; color: transparent; background: #fff; font-size: .7rem; font-weight: 900; transition: .15s ease; }
.customer-text-ok-control:hover .customer-text-ok-box, .customer-text-ok-control input:focus-visible + .customer-text-ok-box { border-color: #47ae77; box-shadow: 0 0 0 3px #47ae7718; }
.customer-text-ok-control input:checked + .customer-text-ok-box { border-color: #25a764; color: #fff; background: #25a764; }
.customer-text-cell { transition: background-color .18s ease, box-shadow .18s ease; }
.customer-text-cell.customer-text-approved { background: #effaf3 !important; box-shadow: inset 0 0 0 1px #83d4a5; }
.customer-text-cell.customer-text-approved .proofreading-field { background: #f5fcf7; }
.customer-text-cell.customer-text-approved .content-text, .customer-text-cell.customer-text-approved .translated-content-text { border-color: #8bd5aa; background: #f5fcf7; }
.customer-text-cell.customer-text-approved .customer-text-ok-control { color: #17784b; }
.content-table tbody tr.customer-approved-row > td:not(.week-cell) { background: #effaf3; box-shadow: inset 0 1px 0 #b9e7cc, inset 0 -1px 0 #b9e7cc; }
.content-table tbody tr.customer-approved-row > td:not(.week-cell):first-of-type,
.content-table tbody tr.customer-approved-row > .week-cell + td:not(.week-cell) { box-shadow: inset 1px 0 0 #83d4a5, inset 0 1px 0 #b9e7cc, inset 0 -1px 0 #b9e7cc; }
.content-table tbody tr.customer-approved-row > td:not(.week-cell):last-of-type { box-shadow: inset -1px 0 0 #83d4a5, inset 0 1px 0 #b9e7cc, inset 0 -1px 0 #b9e7cc; }
.content-table tbody tr.customer-approved-row .content-text, .content-table tbody tr.customer-approved-row .translated-content-text, .content-table tbody tr.customer-approved-row .change-message-input { border-color: #8bd5aa; background: #f5fcf7; }
.content-table tbody tr.customer-approved-row .proofreading-field { background: #f5fcf7; }
.needs-work-control { position: relative; display: inline-flex; width: max-content; max-width: 100%; align-items: center; justify-content: center; gap: 5px; margin: 6px auto 1px; border: 1px solid #d8dde6; border-radius: 7px; padding: 4px 6px; color: #7f8998; background: #fff; font-size: .52rem; font-weight: 850; line-height: 1.15; cursor: pointer; }
.needs-work-control input { position: absolute; inset: 0; width: 1px; height: 1px; margin: 0; overflow: hidden; opacity: 0; pointer-events: none; }
.needs-work-box { display: inline-grid; width: 15px; height: 15px; flex: 0 0 15px; place-items: center; border: 1px solid #cdd3dd; border-radius: 4px; color: transparent; background: #fff; font-size: .58rem; font-weight: 950; }
.needs-work-control:hover, .needs-work-control:has(input:focus-visible) { border-color: #b8c0cd; box-shadow: 0 0 0 3px #7f899814; }
.needs-work-control:has(input:checked) { border-color: #c6ccd6; color: #657083; background: #f7f8fa; }
.needs-work-control input:checked + .needs-work-box { border-color: #8993a3; color: #fff; background: #8993a3; }
.content-table tbody tr.needs-work-row > td:not(.week-cell) { background: #fff6e8; box-shadow: inset 0 1px 0 #f3ca94, inset 0 -1px 0 #f3ca94; }
.content-table tbody tr.needs-work-row > td:not(.week-cell):last-of-type { box-shadow: inset -1px 0 0 #e4aa60, inset 0 1px 0 #f3ca94, inset 0 -1px 0 #f3ca94; }
.content-table tbody tr.needs-work-row .content-text, .content-table tbody tr.needs-work-row .translated-content-text, .content-table tbody tr.needs-work-row .change-message-input { border-color: #edc287; background: #fffbf4; }
.content-table tbody tr.needs-work-row .proofreading-field { background: #fffbf4; }
.content-table tbody tr.needs-work-row > .customer-text-cell.customer-text-approved { background: #effaf3 !important; box-shadow: inset 0 1px 0 #83d4a5, inset 0 -1px 0 #83d4a5; }
.content-table tbody tr.needs-work-row > .customer-text-cell.customer-text-approved .proofreading-field, .content-table tbody tr.needs-work-row > .customer-text-cell.customer-text-approved .content-text, .content-table tbody tr.needs-work-row > .customer-text-cell.customer-text-approved .translated-content-text { border-color: #8bd5aa; background: #f5fcf7; }
.content-table tbody tr.completed-row > td:not(.week-cell),
.content-table tbody tr.completed-row > td.customer-text-cell.customer-text-approved { background: #a8dbba !important; box-shadow: inset 0 2px 0 #4bb77a, inset 0 -2px 0 #4bb77a; }
.content-table tbody tr.completed-row > td:not(.week-cell):first-of-type,
.content-table tbody tr.completed-row > .week-cell + td:not(.week-cell) { box-shadow: inset 2px 0 0 #2e9b61, inset 0 2px 0 #4bb77a, inset 0 -2px 0 #4bb77a; }
.content-table tbody tr.completed-row > td:not(.week-cell):last-of-type { box-shadow: inset -2px 0 0 #2e9b61, inset 0 2px 0 #4bb77a, inset 0 -2px 0 #4bb77a; }
.content-table tbody tr.completed-row .proofreading-field, .content-table tbody tr.completed-row .content-text, .content-table tbody tr.completed-row .translated-content-text, .content-table tbody tr.completed-row .change-message-input { border-color: #65bd88 !important; background: #d5efdf !important; }
.content-table tbody tr.completed-row .completed-status-label { color: #106c3f; font-weight: 900; }
.translation-feedback { min-width: 0; margin-right: auto; overflow: hidden; color: #2d8b61; font-size: .57rem; font-weight: 750; text-overflow: ellipsis; white-space: nowrap; }
.translation-feedback.error { color: #b43d52; }
.translation-language-switch { display: inline-flex; gap: 3px; border-radius: 8px; padding: 2px; background: #f0f2f6; }
.translation-language-button { display: grid; width: 27px; height: 23px; place-items: center; border: 1px solid transparent; border-radius: 6px; padding: 0; background: transparent; font-size: .86rem; line-height: 1; transition: .14s ease; }
.translation-language-button:hover, .translation-language-button:focus-visible { border-color: #cfc8ff; background: #fff; outline: none; }
.translation-language-button.active { border-color: #bfb7ff; background: #fff; box-shadow: 0 1px 3px #17203316; }
.translation-language-button:disabled { opacity: .48; cursor: wait; }
.copy-contribution-button { display: inline-grid; width: 25px; height: 25px; place-items: center; border: 1px solid #ddd8ff; border-radius: 7px; padding: 0; color: #5b4ed7; background: #f4f2ff; font-size: .8rem; font-weight: 850; line-height: 1; transition: .15s ease; }
.copy-contribution-button:hover, .copy-contribution-button:focus-visible { border-color: #6757ed; color: #fff; background: #6757ed; outline: none; }
.copy-contribution-button.copied { border-color: #9bd8ba; color: #13724c; background: #e9f8f1; }
.text-expand-button { display: inline-grid; width: 25px; height: 25px; flex: 0 0 25px; place-items: center; border: 1px solid #d6dce6; border-radius: 7px; padding: 0; color: #687387; background: #fff; font-size: .82rem; font-weight: 900; line-height: 1; transition: .15s ease; }
.text-expand-button:hover, .text-expand-button:focus-visible, .text-cell-layout.is-expanded .text-expand-button { border-color: #6757ed; color: #fff; background: #6757ed; outline: none; }
.text-expand-button[hidden] { display: none; }
.text-expand-button span { transition: transform .16s ease; }
.text-cell-layout.is-expanded .text-expand-button span { transform: rotate(180deg); }
#fixed-hashtags-button.has-value { border-color: #cfc8ff; color: #4f40d2; background: #f0eeff; }
.empty-state { padding: 70px 30px; color: #7d8798; text-align: center; }

dialog { width: min(470px, calc(100% - 30px)); border: 0; border-radius: 16px; padding: 0; color: #172033; background: #fff; box-shadow: 0 28px 80px #17203340; }
dialog::backdrop { background: #1720337a; backdrop-filter: blur(3px); }
dialog form { display: grid; gap: 17px; padding: 24px; }
.dialog-header { display: flex; align-items: flex-start; justify-content: space-between; }
.dialog-header h2 { margin: 0; font-size: 1.35rem; }
.dialog-close { border: 0; color: #87909f; background: transparent; font-size: 1.5rem; line-height: 1; }
dialog label { display: grid; gap: 7px; color: #596579; font-size: .76rem; font-weight: 750; }
dialog input, dialog select, dialog textarea { width: 100%; border: 1px solid #d9dee7; border-radius: 9px; padding: 10px 11px; color: #263148; background: #fff; outline: none; }
dialog textarea { resize: vertical; font: inherit; line-height: 1.5; }
dialog textarea:focus { border-color: #6757ed; box-shadow: 0 0 0 3px #6757ed17; }
.ai-agent-top-button { display: inline-flex; align-items: center; gap: 7px; }
.ai-agent-status-dot { width: 7px; height: 7px; border-radius: 50%; background: #aab1bc; box-shadow: 0 0 0 3px #aab1bc18; }
.ai-agent-top-button.is-active { border-color: #bcb4ff; color: #5143d5; background: #f2f0ff; }
.ai-agent-top-button.is-active .ai-agent-status-dot { background: #2fa06c; box-shadow: 0 0 0 3px #2fa06c20; }
.ai-agent-dialog { width: min(720px, calc(100% - 30px)); }
.ai-agent-dialog form { max-height: min(900px, 92vh); overflow-y: auto; }
.ai-agent-table-picker { border: 1px solid #e1e5ec; border-radius: 11px; padding: 13px 14px; background: #f8f9fc; }
.ai-agent-toggle { grid-template-columns: auto minmax(0, 1fr); align-items: start; border: 1px solid #ddd8ff; border-radius: 11px; padding: 13px 14px; background: #f6f4ff; }
.ai-agent-toggle input { width: 18px; height: 18px; margin: 1px 0 0; accent-color: #6757ed; }
.ai-agent-toggle span { display: grid; gap: 3px; color: #3b4659; }
.ai-agent-toggle small, .ai-agent-dialog label > small { color: #838c9b; font-size: .65rem; font-weight: 600; line-height: 1.45; }
.ai-agent-runtime-status { border-radius: 9px; padding: 10px 12px; color: #5f6878; background: #f4f5f8; font-size: .7rem; font-weight: 700; }
.ai-agent-runtime-status.ready { color: #166b49; background: #eaf8f2; }
.ai-agent-runtime-status.warning { color: #93621a; background: #fff6e7; }
.ai-agent-runtime-status.error { color: #a83b50; background: #fff0f3; }
.ai-agent-folder-picker { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: stretch; gap: 8px; margin-top: 5px; }
.ai-agent-folder-picker input { margin-top: 0; }
.ai-agent-folder-picker .secondary-button { min-width: 130px; white-space: nowrap; }
.ai-agent-websites-field { display: grid; gap: 8px; color: #596579; font-size: .76rem; font-weight: 750; }
.ai-agent-websites-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.ai-agent-websites-header .secondary-button { flex: 0 0 auto; padding: 8px 10px; }
.ai-agent-websites-list { display: grid; gap: 8px; }
.ai-agent-website-row { display: grid; grid-template-columns: minmax(0, 1fr) 40px; gap: 8px; }
.ai-agent-website-input:focus { border-color: #6757ed; box-shadow: 0 0 0 3px #6757ed17; }
.ai-agent-website-remove { display: grid; width: 40px; min-height: 40px; place-items: center; border: 1px solid #f0bdc6; border-radius: 9px; padding: 0; color: #bd4057; background: #fff7f8; font-size: 1.25rem; line-height: 1; }
.ai-agent-website-remove:hover:not(:disabled) { color: #fff; background: #bd4057; }
.ai-agent-website-remove:disabled { border-color: #e1e5ec; color: #a7afbb; background: #f5f6f8; cursor: not-allowed; }
.ai-agent-websites-field > small { color: #838c9b; font-size: .65rem; font-weight: 600; line-height: 1.45; }
@media (max-width: 620px) { .ai-agent-folder-picker { grid-template-columns: 1fr; } }
.permission-fieldset { min-width: 0; margin: 0; border: 0; padding: 0; }
.permission-fieldset legend { margin-bottom: 8px; color: #596579; font-size: .76rem; font-weight: 750; }
.planning-cadence-fieldset { margin-top: 2px; }
.planning-cadence-options { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.planning-cadence-options > label { display: flex; min-width: 0; align-items: flex-start; gap: 9px; margin: 0; border: 1px solid #d8deea; border-radius: 10px; padding: 11px 12px; background: #fff; cursor: pointer; }
.planning-cadence-options > label:has(input:checked) { border-color: #7966ff; background: #f5f2ff; box-shadow: 0 0 0 1px #7966ff; }
.planning-cadence-options input { width: auto; margin: 2px 0 0; accent-color: #6757ed; }
.planning-cadence-options span { display: grid; min-width: 0; gap: 2px; }
.planning-cadence-options strong { color: #253047; font-size: .78rem; }
.planning-cadence-options small { color: #778197; font-size: .66rem; font-weight: 550; line-height: 1.35; }
.monthly-extra-settings { display: grid; gap: 10px; }
.monthly-extra-settings[hidden] { display: none !important; }
.permission-list { display: grid; max-height: 210px; gap: 7px; overflow-y: auto; border: 1px solid #e0e4eb; border-radius: 10px; padding: 8px; background: #fafbfc; }
.permission-option { display: flex; grid-template-columns: none; align-items: center; gap: 10px; border: 1px solid transparent; border-radius: 8px; padding: 9px 10px; color: #3f4b60; background: #fff; font-size: .76rem; }
.permission-option:has(input:checked) { border-color: #cfc8ff; color: #4f40d2; background: #f0eeff; }
.permission-option input { width: 16px; height: 16px; margin: 0; accent-color: #6757ed; outline: none; }
.year-visibility-options { display: grid; grid-template-columns: repeat(3, 1fr); gap: 7px; }
.year-visibility-options .permission-option { justify-content: center; }
.permission-empty { margin: 0; padding: 10px; color: #858e9d; font-size: .72rem; text-align: center; }
.form-error { margin: -7px 0 0; color: #b43d52; font-size: .72rem; font-weight: 700; }
.dialog-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 13px; }
.dialog-actions { display: flex; justify-content: flex-end; gap: 9px; margin-top: 4px; }
.dialog-actions .dialog-action-left { margin-right: auto; }
.table-delete-button { margin-right: auto; }
.dialog-hint { margin: -2px 0 0; border-radius: 8px; padding: 10px; color: #6e788a; background: #f6f7fa; font-size: .7rem; line-height: 1.5; }
.hidden-weeks-dialog-content { display: grid; gap: 16px; padding: 24px; }
.hide-weeks-range-form { display: grid; gap: 12px; border: 1px solid #ddd8ff; border-radius: 11px; padding: 14px; background: #f8f7ff; }
.hide-weeks-range-form h3, .hidden-weeks-list-title { margin: 0; font-size: .82rem; }
.hide-weeks-range-form > div > p { margin: 4px 0 0; color: #858e9d; font-size: .68rem; }
.hide-weeks-range-fields { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto; align-items: end; gap: 10px; }
.hide-weeks-range-fields label { gap: 5px; }
.hide-weeks-range-fields select { min-width: 0; padding: 8px 9px; }
.hide-weeks-range-fields .primary-button { min-height: 35px; white-space: nowrap; }
.hidden-weeks-list-title { color: #536075; }
.hidden-weeks-list { display: grid; max-height: 360px; gap: 8px; overflow: auto; }
.hidden-week-item { display: flex; align-items: center; justify-content: space-between; gap: 14px; border: 1px solid #e4e7ed; border-radius: 9px; padding: 10px 11px; }
.hidden-week-item div { display: flex; align-items: baseline; gap: 8px; }
.hidden-week-item strong { font-size: .8rem; }
.hidden-week-item span { color: #8b94a3; font-size: .68rem; }
.hidden-week-item button { border: 0; color: #5b4ed7; background: transparent; font-size: .7rem; font-weight: 800; }
.hidden-week-empty { padding: 60px 20px !important; color: #7c8798; text-align: center; }
.hidden-week-empty strong, .hidden-week-empty span { display: block; }
.hidden-week-empty span { margin: 7px 0 14px; color: #9aa2af; font-size: .75rem; }
.columns-dialog { width: min(560px, calc(100% - 30px)); }
.columns-dialog-content { display: grid; gap: 16px; padding: 24px; }
.custom-columns-list { display: grid; max-height: 190px; gap: 8px; overflow-y: auto; }
.custom-column-item { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: 10px; border: 1px solid #e2e6ed; border-radius: 9px; padding: 10px 11px; }
.custom-column-item strong { overflow: hidden; font-size: .78rem; text-overflow: ellipsis; white-space: nowrap; }
.custom-column-type { border-radius: 999px; padding: 4px 8px; color: #6557d9; background: #efedff; font-size: .62rem; font-weight: 800; }
.custom-column-item button { border: 0; border-radius: 7px; padding: 6px 8px; color: #5a4bd6; background: #f2f0ff; font-size: .67rem; font-weight: 800; }
.custom-column-empty { margin: 0; border: 1px dashed #dfe3ea; border-radius: 9px; padding: 18px; color: #8d96a4; font-size: .72rem; text-align: center; }
.columns-dialog-content .custom-column-form { display: grid; gap: 13px; border: 1px solid #e3e6ed; border-radius: 11px; padding: 16px; background: #fafbfc; }
.custom-column-form h3 { margin: 0; font-size: .88rem; }
.custom-cell textarea { height: 100%; min-height: 96px; }
.delete-column-dialog-content { display: grid; gap: 16px; padding: 24px; }
.history-dialog { width: min(720px, calc(100% - 30px)); }
.history-dialog-content { display: grid; gap: 15px; padding: 24px; }
.history-summary { display: flex; align-items: center; justify-content: space-between; gap: 16px; border: 1px solid #e2e6ed; border-radius: 10px; padding: 10px 12px; color: #707b8e; background: #fafbfc; font-size: .7rem; }
.history-summary strong { color: #4f40d2; }
.history-list { display: grid; max-height: min(520px, 58vh); gap: 8px; overflow-y: auto; padding-right: 3px; }
.history-item { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 14px; border: 1px solid #e2e6ed; border-radius: 10px; padding: 11px 12px; background: #fff; }
.history-item:hover { border-color: #ccc5ff; background: #fcfbff; }
.history-item strong, .history-item span { display: block; }
.history-item strong { font-size: .78rem; }
.history-item span { margin-top: 4px; color: #8a93a3; font-size: .66rem; line-height: 1.4; }
.history-item button { border: 1px solid #ddd8ff; border-radius: 8px; padding: 7px 9px; color: #5648d4; background: #f2f0ff; font-size: .68rem; font-weight: 800; }
.history-empty { border: 1px dashed #dfe3ea; border-radius: 10px; padding: 34px 20px; color: #87909f; font-size: .74rem; text-align: center; }
.instagram-dialog { width: min(650px, calc(100% - 30px)); }
.instagram-dialog-content { display: grid; gap: 16px; padding: 24px; }
.instagram-table-picker { display: grid; gap: 7px; border: 1px solid #e1e5ec; border-radius: 11px; padding: 13px 14px; color: #4f5b70; background: #f8f9fc; font-size: .75rem; font-weight: 800; }
.instagram-table-picker select { width: 100%; border: 1px solid #d7dce6; border-radius: 9px; padding: 10px 11px; color: #263148; background: #fff; outline: none; }
.instagram-table-picker select:focus { border-color: #6757ed; box-shadow: 0 0 0 3px #6757ed17; }
.instagram-table-picker small { color: #7e8797; font-size: .66rem; font-weight: 600; line-height: 1.45; }
.instagram-setup-card, .instagram-profile-card { display: grid; gap: 12px; border: 1px solid #ddd8ff; border-radius: 11px; padding: 14px; background: #f8f7ff; }
.instagram-setup-card > div > strong, .instagram-setup-card > div > small { display: block; }
.instagram-setup-card > div > strong { color: #4438b6; font-size: .82rem; }
.instagram-setup-card > div > small, .instagram-profile-card label > small, .instagram-app-config-form label > small { margin-top: 4px; color: #7e8797; font-size: .64rem; font-weight: 600; line-height: 1.45; }
.instagram-app-config-form { display: grid; grid-template-columns: 1fr 1fr; gap: 11px; }
.instagram-app-config-form label { min-width: 0; }
.instagram-config-actions { display: flex; grid-column: 1 / -1; align-items: center; gap: 10px; }
.instagram-config-actions span { color: #697488; font-size: .65rem; font-weight: 700; line-height: 1.4; }
.instagram-config-actions span.success { color: #168055; }
.instagram-config-actions span.error { color: #b43d52; }
.instagram-profile-card { border-color: #e1e5ec; background: #fafbfc; }
.instagram-profile-input-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; }
.instagram-profile-input-row button { white-space: nowrap; }
.instagram-connection-card { border: 1px solid #e1e5ec; border-radius: 11px; padding: 14px; background: #fafbfc; }
.instagram-connection-card.connected { border-color: #bce7d2; background: #f0fbf6; }
.instagram-connection-card.warning { border-color: #f0d59c; background: #fffaf0; }
.instagram-connection-card strong, .instagram-connection-card span { display: block; }
.instagram-connection-card strong { font-size: .84rem; }
.instagram-connection-card span, .instagram-connection-card p { margin: 4px 0 0; color: #768194; font-size: .7rem; line-height: 1.5; }
.instagram-dialog-actions { display: flex; align-items: center; gap: 10px; }
.danger-text-button { border: 0; color: #ad3f54; background: transparent; font-size: .72rem; font-weight: 800; }
.instagram-publications-title { margin: 0 0 9px; font-size: .82rem; }
.instagram-publications-list { display: grid; max-height: 260px; gap: 7px; overflow-y: auto; }
.instagram-publication-item { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 12px; border: 1px solid #e3e6ec; border-radius: 9px; padding: 10px 11px; }
.instagram-publication-item strong, .instagram-publication-item span { display: block; }
.instagram-publication-item strong { font-size: .75rem; }
.instagram-publication-item span { margin-top: 3px; color: #8a93a2; font-size: .64rem; }
.insights-top-button { border-color: #c9c1ff; color: #5142c9; background: #f7f5ff; }
.insights-dialog { width: min(1400px, calc(100% - 28px)); }
.insights-dialog-content { display: grid; max-height: min(930px, 95vh); gap: 15px; overflow-y: auto; padding: 24px; }
.insights-subtitle { margin: 4px 0 0; color: #7a8495; font-size: .7rem; }
.insights-toolbar { display: grid; grid-template-columns: minmax(190px, 1fr) 180px auto auto; align-items: end; gap: 10px; border: 1px solid #e2e5ec; border-radius: 12px; padding: 13px; background: #fafbfc; }
.insights-toolbar label, .insights-section-heading label { display: grid; gap: 5px; color: #697487; font-size: .64rem; font-weight: 800; }
.insights-toolbar select, .insights-section-heading select, .insights-section-heading label select { min-height: 38px; border: 1px solid #d9dee7; border-radius: 9px; padding: 8px 10px; color: #2d384d; background: #fff; font: inherit; font-size: .72rem; outline: none; }
.insights-connection-card { display: flex; align-items: center; gap: 11px; border: 1px solid #e0e4eb; border-radius: 11px; padding: 12px 13px; background: #fafbfc; }
.insights-connection-card.connected { border-color: #b8e4ce; background: #f0fbf6; }
.insights-connection-card.warning { border-color: #efd29a; background: #fff9ed; }
.insights-connection-card > div { min-width: 0; flex: 1; }
.insights-connection-card strong, .insights-connection-card small { display: block; }
.insights-connection-card strong { font-size: .79rem; }
.insights-connection-card small { margin-top: 3px; color: #788396; font-size: .64rem; line-height: 1.4; }
.insights-status-dot { width: 10px; height: 10px; flex: 0 0 10px; border-radius: 50%; background: #9ca5b3; box-shadow: 0 0 0 4px #9ca5b322; }
.insights-connection-card.connected .insights-status-dot { background: #22a56b; box-shadow: 0 0 0 4px #22a56b22; }
.insights-connection-card.warning .insights-status-dot { background: #d69325; box-shadow: 0 0 0 4px #d6932522; }
.insights-loading { display: grid; min-height: 180px; place-items: center; align-content: center; gap: 7px; border: 1px dashed #dcd8fa; border-radius: 13px; color: #5548c9; background: #faf9ff; text-align: center; }
.insights-loading span { width: 28px; height: 28px; border: 3px solid #dcd7ff; border-top-color: #6757ed; border-radius: 50%; animation: insights-spin .75s linear infinite; }
.insights-loading strong { font-size: .82rem; }
.insights-loading small { color: #838b9a; font-size: .66rem; }
@keyframes insights-spin { to { transform: rotate(360deg); } }
#insights-dashboard { display: grid; gap: 14px; }
.insights-tabs { display: flex; gap: 6px; overflow-x: auto; border-bottom: 1px solid #e5e8ee; padding-bottom: 7px; }
.insights-tabs button { flex: 0 0 auto; border: 1px solid transparent; border-radius: 8px; padding: 8px 11px; color: #6f7a8d; background: transparent; font-size: .68rem; font-weight: 850; }
.insights-tabs button:hover { color: #5143ca; background: #f6f4ff; }
.insights-tabs button.active { border-color: #d7d1ff; color: #4f40ca; background: #efedff; }
.insights-panel { display: grid; gap: 13px; }
.insights-kpis { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 9px; }
.insights-kpi { border: 1px solid #e0e4eb; border-radius: 11px; padding: 12px; background: #fff; }
.insights-kpi span, .insights-kpi strong, .insights-kpi small { display: block; }
.insights-kpi span { color: #798497; font-size: .59rem; font-weight: 800; letter-spacing: .03em; text-transform: uppercase; }
.insights-kpi strong { margin-top: 6px; color: #4336b5; font-size: 1.22rem; font-variant-numeric: tabular-nums; }
.insights-kpi small { margin-top: 3px; color: #9aa2af; font-size: .58rem; }
.insights-two-column { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(280px, .75fr); gap: 11px; }
.insights-card { min-width: 0; border: 1px solid #e1e5ec; border-radius: 12px; padding: 14px; background: #fff; }
.insights-section-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 14px; }
.insights-section-heading h3 { margin: 0; color: #303b50; font-size: .84rem; }
.insights-section-heading p { margin: 4px 0 0; color: #8a93a2; font-size: .63rem; line-height: 1.4; }
.insights-trend-chart { display: flex; min-height: 230px; align-items: flex-end; gap: 3px; overflow-x: auto; padding: 18px 3px 28px; }
.insights-trend-bar { position: relative; min-width: 8px; flex: 1 0 8px; border-radius: 5px 5px 2px 2px; background: linear-gradient(180deg,#6a58ef,#a69cff); box-shadow: 0 2px 8px #6858ed26; }
.insights-trend-bar:hover { background: #4e3ed2; }
.insights-trend-bar span { position: absolute; bottom: -22px; left: 50%; color: #8992a1; font-size: .5rem; transform: translateX(-50%); white-space: nowrap; }
.insights-trend-empty, .insights-empty { border: 1px dashed #dfe3ea; border-radius: 10px; padding: 30px 18px; color: #8992a1; font-size: .69rem; line-height: 1.5; text-align: center; }
.insights-breakdown { display: grid; gap: 9px; padding-top: 15px; }
.insights-breakdown-row { display: grid; grid-template-columns: 90px minmax(0, 1fr) auto; align-items: center; gap: 9px; color: #556176; font-size: .65rem; font-weight: 750; }
.insights-breakdown-track { height: 9px; overflow: hidden; border-radius: 999px; background: #edf0f5; }
.insights-breakdown-track span { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg,#6757ed,#9d91f4); }
.insights-media-list { display: grid; gap: 8px; }
.insights-media-item { display: grid; grid-template-columns: 70px minmax(180px, 1.15fr) repeat(5, minmax(72px, .48fr)) auto; align-items: center; gap: 9px; border: 1px solid #e1e5ec; border-radius: 11px; padding: 9px; background: #fff; }
.insights-media-thumb { width: 70px; height: 70px; overflow: hidden; border-radius: 9px; background: #eef0f4; }
.insights-media-thumb img { width: 100%; height: 100%; object-fit: cover; }
.insights-media-copy { min-width: 0; }
.insights-media-copy strong, .insights-media-copy span, .insights-media-copy small { display: block; }
.insights-media-copy strong { overflow: hidden; color: #344055; font-size: .7rem; text-overflow: ellipsis; white-space: nowrap; }
.insights-media-copy span { margin-top: 4px; color: #8a93a2; font-size: .59rem; }
.insights-media-copy small { display: -webkit-box; margin-top: 5px; overflow: hidden; color: #687487; font-size: .61rem; line-height: 1.35; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.insights-media-value { min-width: 0; text-align: right; }
.insights-media-value span, .insights-media-value strong { display: block; }
.insights-media-value span { color: #929baa; font-size: .53rem; font-weight: 800; text-transform: uppercase; }
.insights-media-value strong { margin-top: 4px; color: #38445a; font-size: .74rem; font-variant-numeric: tabular-nums; }
.insights-media-open { border: 1px solid #d7d1ff; border-radius: 8px; padding: 7px 9px; color: #5546d1; background: #f5f3ff; font-size: .62rem; font-weight: 850; text-decoration: none; }
.insights-audience-grid { display: grid; grid-template-columns: repeat(auto-fit,minmax(270px,1fr)); gap: 10px; }
.insights-audience-card { border: 1px solid #e1e5ec; border-radius: 11px; padding: 12px; background: #fff; }
.insights-audience-card h4 { margin: 0 0 10px; font-size: .72rem; }
.insights-audience-card ol { display: grid; gap: 6px; margin: 0; padding: 0; list-style: none; }
.insights-audience-card li { display: flex; justify-content: space-between; gap: 10px; border-radius: 7px; padding: 6px 8px; color: #596579; background: #f5f7fa; font-size: .63rem; }
.insights-metrics-table { overflow: hidden; border: 1px solid #e1e5ec; border-radius: 11px; }
.insights-metric-row { display: grid; grid-template-columns: minmax(150px,.8fr) minmax(90px,.35fr) minmax(260px,1.4fr); gap: 12px; border-top: 1px solid #edf0f4; padding: 9px 11px; color: #647084; font-size: .64rem; }
.insights-metric-row:first-child { border-top: 0; }
.insights-metric-row.head { color: #7c8696; background: #f7f8fa; font-size: .57rem; font-weight: 850; letter-spacing: .03em; text-transform: uppercase; }
.insights-metric-row strong { color: #354157; font-size: .7rem; }
.insights-metric-row .value { color: #4e40c8; font-weight: 850; font-variant-numeric: tabular-nums; }
.backend-dialog { width: min(1360px, calc(100% - 30px)); }
.backend-dialog-content { display: grid; max-height: min(920px, 94vh); gap: 16px; overflow-y: auto; padding: 24px; }
.backend-status-card { display: flex; align-items: center; gap: 11px; border: 1px solid #e1e5ec; border-radius: 11px; padding: 13px 14px; background: #fafbfc; }
.backend-status-card.online { border-color: #bce7d2; background: #f0fbf6; }
.backend-status-card.error { border-color: #f0bfc8; background: #fff4f6; }
.backend-status-dot { width: 10px; height: 10px; flex: 0 0 auto; border-radius: 50%; background: #a1a8b4; box-shadow: 0 0 0 4px #a1a8b422; }
.backend-status-card.online .backend-status-dot { background: #26a66f; box-shadow: 0 0 0 4px #26a66f22; }
.backend-status-card.error .backend-status-dot { background: #c44860; box-shadow: 0 0 0 4px #c4486022; }
.backend-status-card strong, .backend-status-card small { display: block; }
.backend-status-card strong { font-size: .84rem; }
.backend-status-card small { margin-top: 3px; color: #7e899a; font-size: .67rem; }
.backend-metrics { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 9px; }
.backend-metrics article { border: 1px solid #e2e6ed; border-radius: 10px; padding: 12px; background: #fafbfc; }
.backend-metrics span, .backend-metrics strong { display: block; }
.backend-metrics span { color: #7f8999; font-size: .65rem; font-weight: 700; }
.backend-metrics strong { margin-top: 6px; color: #4f40d2; font-size: 1.15rem; }
.backend-section { display: grid; gap: 8px; }
.backend-section-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.backend-section-heading h3 { margin: 0; font-size: .82rem; }
.backend-section-heading span { color: #8a93a2; font-size: .64rem; }
.backend-system-details { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; }
.backend-system-details div { display: flex; justify-content: space-between; gap: 10px; border: 1px solid #e5e8ee; border-radius: 8px; padding: 9px 10px; color: #727d8f; background: #fff; font-size: .68rem; }
.backend-system-details strong { color: #303b50; }
.backend-list { display: grid; max-height: 230px; gap: 7px; overflow-y: auto; }
.backend-list-item { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 12px; border: 1px solid #e3e6ec; border-radius: 9px; padding: 10px 11px; }
.backend-list-item strong, .backend-list-item span { display: block; }
.backend-list-item strong { font-size: .74rem; }
.backend-list-item span { margin-top: 3px; color: #8a93a2; font-size: .64rem; }
.backend-empty { border: 1px dashed #dfe3ea; border-radius: 9px; padding: 18px; color: #87909f; font-size: .7rem; text-align: center; }
.backend-media-section { border-top: 1px solid #e8ebf0; padding-top: 14px; }
.backend-media-toggle { display: flex; width: 100%; align-items: center; justify-content: space-between; gap: 14px; border: 1px solid #dcd7ff; border-radius: 11px; padding: 12px 14px; color: #4135b4; background: #f7f5ff; text-align: left; }
.backend-media-toggle:hover { border-color: #bdb4ff; background: #f1efff; }
.backend-media-toggle strong, .backend-media-toggle small { display: block; }
.backend-media-toggle strong { font-size: .77rem; }
.backend-media-toggle small { margin-top: 3px; color: #7b73ae; font-size: .64rem; font-weight: 650; }
.backend-media-toggle > span:last-child { font-size: 1.15rem; transition: transform .15s ease; }
.backend-media-toggle[aria-expanded="true"] > span:last-child { transform: rotate(180deg); }
.backend-media-panel { display: grid; gap: 10px; }
.backend-media-controls { display: flex; align-items: flex-end; justify-content: flex-end; gap: 9px; }
.backend-media-expand { min-height: 34px; margin-right: auto; white-space: nowrap; }
.backend-media-sort-hint { align-self: center; color: #7c8799; font-size: .65rem; font-weight: 700; }
.backend-media-controls label { display: grid; gap: 4px; color: #7d8797; font-size: .61rem; font-weight: 750; }
.backend-media-controls select { min-width: 145px; border: 1px solid #dce1e8; border-radius: 8px; padding: 7px 9px; color: #38445a; background: #fff; font-size: .68rem; font-weight: 700; outline: none; }
.backend-media-controls select:focus { border-color: #6757ed; box-shadow: 0 0 0 3px #6757ed17; }
.backend-media-table { overflow: hidden; border: 1px solid #e0e4eb; border-radius: 10px; background: #fff; }
.backend-media-list { overflow: visible; }
.backend-media-row { display: grid; grid-template-columns: 65px minmax(210px, 1fr) 140px 145px 135px 155px 185px; align-items: center; gap: 10px; min-height: 48px; padding: 8px 11px; border-top: 1px solid #edf0f4; font-size: .68rem; }
.backend-media-row:first-child { border-top: 0; }
.backend-media-head { min-height: 35px; border-top: 0; color: #737e90; background: #f7f8fa; font-size: .6rem; font-weight: 850; letter-spacing: .04em; text-transform: uppercase; }
.backend-media-head [role="columnheader"] { min-width: 0; }
.backend-media-head button { display: inline-flex; max-width: 100%; align-items: center; gap: 5px; border: 0; padding: 5px 0; color: inherit; background: transparent; font: inherit; letter-spacing: inherit; text-align: left; text-transform: inherit; }
.backend-media-head button:hover { color: #5143ca; }
.backend-media-head button:focus-visible { border-radius: 5px; outline: 2px solid #6757ed; outline-offset: 2px; }
.backend-media-head button.active { color: #5143ca; }
.backend-media-sort-arrow { display: inline-grid; width: 16px; height: 16px; flex: 0 0 16px; place-items: center; border-radius: 5px; color: #fff; background: #6757ed; font-size: .7rem; line-height: 1; opacity: 0; transform: scale(.8); transition: opacity .15s ease, transform .15s ease; }
.backend-media-head button.active .backend-media-sort-arrow { opacity: 1; transform: scale(1); }
.backend-media-name { min-width: 0; }
.backend-media-name strong, .backend-media-name small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.backend-media-name strong { color: #303b50; font-size: .69rem; }
.backend-media-name small { margin-top: 2px; color: #929baa; font-size: .59rem; }
.backend-media-row-group-label { display: inline-flex; width: max-content; margin-top: 4px; border-radius: 999px; padding: 3px 6px; color: #5042c7; background: #efedff; font-size: .54rem; font-style: normal; font-weight: 800; }
.backend-media-locations { display: flex; min-width: 0; flex-wrap: wrap; gap: 4px; }
.backend-media-locations > span { display: inline-grid; grid-template-columns: auto auto; align-items: center; column-gap: 3px; border-radius: 7px; padding: 4px 6px; color: #3f4b61; background: #f1f3f7; font-size: .59rem; white-space: nowrap; }
.backend-media-locations > span small { grid-column: 1 / -1; margin-top: 1px; color: #8490a2; font-size: .52rem; }
.backend-media-locations.empty { color: #9ba4b2; font-size: .61rem; }
.backend-media-kind { width: max-content; border-radius: 999px; padding: 4px 7px; color: #315aad; background: #eaf1ff; font-size: .58rem; font-weight: 850; }
.backend-media-kind.video { color: #15725b; background: #e7f7f1; }
.backend-media-kind.story { color: #7b45b0; background: #f4eaff; }
.backend-media-size { display: grid; min-width: 0; gap: 4px; font-variant-numeric: tabular-nums; }
.backend-media-size > span { display: flex; min-width: 0; align-items: center; justify-content: space-between; gap: 7px; border-radius: 6px; padding: 3px 6px; background: #f4f6f9; }
.backend-media-size > span.original { border-left: 3px solid #24a568; }
.backend-media-size > span.preview { border-left: 3px solid #3988e8; }
.backend-media-size > span.missing { opacity: .6; }
.backend-media-size strong { overflow: hidden; color: #4b566b; font-size: .52rem; font-weight: 850; letter-spacing: .035em; text-overflow: ellipsis; text-transform: uppercase; white-space: nowrap; }
.backend-media-size small { color: #687487; font-size: .59rem; font-weight: 750; white-space: nowrap; }
.backend-media-availability { display: flex; min-width: 0; align-items: center; gap: 7px; }
.backend-media-availability-check { display: inline-grid; width: 24px; height: 24px; flex: 0 0 24px; place-items: center; border-radius: 50%; color: #fff; font-size: .82rem; font-weight: 900; line-height: 1; box-shadow: 0 0 0 1px #fff, 0 2px 8px #17203318; }
.backend-media-availability-check.original { background: #24a568; }
.backend-media-availability-check.preview { background: #3988e8; }
.backend-media-file-state { display: grid; width: max-content; max-width: 100%; gap: 2px; border-radius: 8px; padding: 6px 8px; color: #72531c; background: #fff6dd; font-size: .6rem; font-weight: 850; }
.backend-media-file-state small { color: #967b48; font-size: .55rem; font-weight: 700; }
.backend-media-file-state.with-preview { color: #176b53; background: #eaf8f2; }
.backend-media-file-state.with-preview small { color: #568676; }
.backend-media-file-state.preview-only { color: #8f4050; background: #fff0f3; }
.backend-media-file-state.preview-only small { color: #a66a76; }
.backend-media-file-state.preview-only.restorable { color: #176b53; background: #eaf8f2; }
.backend-media-file-state.preview-only.restorable small { color: #568676; }
.backend-media-actions { display: flex; align-items: center; gap: 6px; }
.backend-media-open, .backend-media-original { border-radius: 7px; padding: 6px 8px; font-size: .61rem; font-weight: 800; }
.backend-media-open { border: 1px solid #cfc9ff; color: #5446cc; background: #f6f4ff; }
.backend-media-open:hover { border-color: #9f94f6; background: #efecff; }
.backend-media-original.restore { border: 1px solid #9ed8c1; color: #176b53; background: #ecfaf4; }
.backend-media-original.restore:hover:not(:disabled) { border-color: #55b78f; background: #ddf6eb; }
.backend-media-original.delete { border: 1px solid #efc2ca; color: #ae4055; background: #fff6f7; }
.backend-media-original.delete:hover:not(:disabled) { border-color: #d98998; color: #923247; background: #ffedf0; }
.backend-media-original:disabled { opacity: .58; cursor: wait; }
.backend-media-empty { margin: 10px; }
.backend-media-list .backend-media-row { margin: 0; border: 0; border-top: 1px solid #edf0f4; border-radius: 0; background: #fff; }
.backend-media-week-group { overflow: hidden; margin: 5px 4px; border: 3px solid #df3f99; border-radius: 9px; background: #fffafd; }
.backend-media-week-group .backend-media-row { border-top-color: #f3b6d8; background: #fffafd; }
.backend-media-week-group .backend-media-row:first-child { border-top: 0; }
.backend-media-week-group.unassigned { margin: 0; border: 0; border-radius: 0; background: #fff; }
.backend-media-week-group.unassigned .backend-media-row { border-top-color: #edf0f4; background: #fff; }
.backend-media-week-group.unassigned:first-child .backend-media-row:first-child { border-top: 0; }
.media-library-dialog { width: min(1500px, calc(100% - 28px)); }
.media-library-content { display: grid; grid-template-rows: auto auto minmax(0, 1fr) auto; height: min(880px, calc(100vh - 38px)); gap: 16px; padding: 24px; }
.media-library-summary { margin: 5px 0 0; color: #7a8495; font-size: .72rem; }
.media-library-controls { border-top: 1px solid #eaecf0; padding-top: 14px; }
.media-library-controls .backend-media-sort-hint { margin-left: auto; }
.media-library-table { min-height: 0; overflow: auto; }
.media-library-table > .backend-media-head, .media-library-list .backend-media-row { grid-template-columns: 72px minmax(300px, 1fr) 165px 170px 160px 170px 205px; }
.media-library-table > .backend-media-head { position: sticky; z-index: 2; top: 0; }
.media-library-list { overflow: visible; }
.media-library-content > .dialog-actions { margin-top: 0; }
.publication-state { border-radius: 999px; padding: 4px 7px; color: #6658d8; background: #efedff; font-size: .59rem; font-weight: 800; }
.publication-state.published { color: #13724c; background: #e5f7ef; }
.publication-state.failed { color: #aa3d52; background: #fff0f3; }
.instagram-publications-empty { border: 1px dashed #dfe3ea; border-radius: 9px; padding: 20px; color: #8b94a3; font-size: .7rem; text-align: center; }
.publication-dialog { width: min(610px, calc(100% - 30px)); }
.publication-dialog form { max-height: min(900px, 92vh); overflow-y: auto; }
.publication-dialog textarea { width: 100%; resize: vertical; border: 1px solid #d9dee7; border-radius: 9px; padding: 10px 11px; color: #263148; background: #fff; outline: none; }
.publication-dialog textarea:focus { border-color: #6757ed; outline: 3px solid #6757ed1c; }
.publication-media-summary { display: flex; align-items: center; gap: 10px; border-radius: 10px; padding: 11px 12px; color: #5b4ed7; background: #f2f0ff; font-size: .72rem; font-weight: 750; }
.publication-media-summary strong { display: grid; width: 28px; height: 28px; place-items: center; border-radius: 8px; color: #fff; background: #6757ed; }
.publication-media-summary.warning { color: #9b3d50; background: #fff0f3; }
.publication-media-summary.warning strong { background: #bd3f58; }
.publication-crop-section { display: grid; gap: 12px; border: 1px solid #ddd8ff; border-radius: 11px; padding: 13px; background: #faf9ff; }
.publication-crop-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; }
.publication-crop-heading strong, .publication-crop-heading span { display: block; }
.publication-crop-heading strong { color: #3f4a5e; font-size: .77rem; }
.publication-crop-heading div > span { max-width: 440px; margin-top: 3px; color: #7f899a; font-size: .64rem; line-height: 1.45; }
.crop-format-badge { flex: 0 0 auto; border-radius: 999px; padding: 4px 8px; color: #fff; background: #6757ed; font-size: .61rem; font-weight: 850; }
.publication-crop-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 11px; }
.publication-crop-item { display: grid; gap: 8px; border: 1px solid #e2dfff; border-radius: 10px; padding: 10px; background: #fff; }
.publication-crop-item-header { display: flex; align-items: center; justify-content: space-between; gap: 8px; color: #404b60; font-size: .67rem; }
.publication-crop-item-header span { color: #8a93a2; font-size: .59rem; }
.publication-crop-preview { position: relative; width: min(100%, 190px); aspect-ratio: 4 / 5; justify-self: center; overflow: hidden; border-radius: 9px; background: #e9ebf1; box-shadow: inset 0 0 0 1px #d8dce5; }
.publication-crop-preview img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: 50% 50%; }
.publication-crop-preview::after { position: absolute; inset: 0; border: 1px solid #ffffffa8; border-radius: inherit; box-shadow: inset 0 0 0 1px #1720331a; content: ""; pointer-events: none; }
.publication-crop-control { display: grid; gap: 5px; color: #687386; font-size: .61rem; font-weight: 750; }
.publication-crop-control input { width: 100%; accent-color: #6757ed; }
.publish-approval-option { display: grid; grid-template-columns: 18px minmax(0, 1fr); align-items: start; gap: 10px; border: 1px solid #e0e4ea; border-radius: 10px; padding: 11px 12px; background: #fafbfc; }
.publish-approval-option.final { border-color: #d8d2ff; background: #f7f5ff; }
.publish-approval-option input { width: 17px; height: 17px; margin: 1px 0 0; accent-color: #6757ed; }
.publish-approval-option strong, .publish-approval-option small { display: block; }
.publish-approval-option strong { color: #3f4a5e; font-size: .74rem; }
.publish-approval-option small { margin-top: 3px; color: #8a93a2; font-size: .64rem; font-weight: 500; line-height: 1.4; }
.delete-warning { margin: 0; color: #a33e52; font-size: .73rem; line-height: 1.5; }
.danger-button { border: 1px solid #bd3f58; border-radius: 9px; padding: 9px 13px; color: #fff; background: #bd3f58; font-size: .78rem; font-weight: 750; }
.danger-button:hover { background: #a63249; }
.media-viewer { width: min(1100px, calc(100% - 48px)); max-width: none; background: #111827; }
.media-viewer .media-viewer-header { display: flex; align-items: center; justify-content: space-between; padding: 14px 17px; color: #fff; background: #1d2739; }
.media-viewer-header > div { display: flex; align-items: center; gap: 10px; }
.media-viewer-counter { color: #aeb7c7; font-size: .72rem; font-weight: 750; }
.media-viewer .dialog-close { color: #fff; }
.media-viewer-stage { position: relative; }
.media-viewer-content { display: grid; min-height: 400px; max-height: calc(100vh - 150px); place-items: center; overflow: auto; padding: 18px; }
.media-viewer-item { display: grid; width: fit-content; max-width: 100%; gap: 12px; }
.media-viewer-media-frame { position: relative; display: grid; width: fit-content; max-width: 100%; place-items: center; }
.media-viewer-play-button { position: absolute; z-index: 12; top: 50%; left: 50%; display: grid; width: 72px; height: 72px; place-items: center; transform: translate(-50%, -50%); border: 2px solid #ffffffd9; border-radius: 50%; padding: 0 0 0 5px; color: #fff; background: #111827d9; box-shadow: 0 8px 28px #0008; font-size: 2rem; line-height: 1; cursor: pointer; transition: transform .15s ease, background .15s ease, box-shadow .15s ease; }
.media-viewer-play-button:hover, .media-viewer-play-button:focus-visible { background: #6757ed; box-shadow: 0 10px 34px #0009, 0 0 0 4px #ffffff30; outline: none; transform: translate(-50%, -50%) scale(1.06); }
.media-viewer-play-button[hidden] { display: none; }
.media-viewer-video-progress { position: absolute; z-index: 11; right: 60px; bottom: 10px; left: 10px; display: grid; grid-template-columns: minmax(90px, 1fr) auto; align-items: center; gap: 9px; border: 1px solid #ffffff75; border-radius: 10px; padding: 7px 9px; color: #fff; background: #111827dc; box-shadow: 0 4px 16px #0007; }
.media-viewer-video-range { width: 100%; height: 5px; margin: 0; appearance: none; border-radius: 999px; outline: none; background: linear-gradient(to right, #8b7cff 0 var(--video-progress, 0%), #ffffff70 var(--video-progress, 0%) 100%); cursor: pointer; }
.media-viewer-video-range::-webkit-slider-thumb { width: 15px; height: 15px; appearance: none; border: 2px solid #fff; border-radius: 50%; background: #6757ed; box-shadow: 0 2px 7px #0007; cursor: grab; }
.media-viewer-video-range::-moz-range-thumb { width: 12px; height: 12px; border: 2px solid #fff; border-radius: 50%; background: #6757ed; box-shadow: 0 2px 7px #0007; cursor: grab; }
.media-viewer-video-range:focus-visible { box-shadow: 0 0 0 3px #ffffff4d; }
.media-viewer-video-range:disabled { opacity: .55; cursor: default; }
.media-viewer-video-time { min-width: 72px; font-size: .64rem; font-weight: 800; font-variant-numeric: tabular-nums; text-align: right; white-space: nowrap; }
.media-viewer-media-frame .media-viewer-ocr-button { top: 8px; left: 8px; }
.media-viewer-media-frame .media-viewer-note-button { right: 10px; bottom: 10px; width: 38px; height: 38px; border-radius: 10px; font-size: 1.05rem; }
.media-viewer-media-frame .media-note-editor.in-media-viewer,
.media-viewer-media-frame .media-ocr-editor.in-media-viewer { position: absolute; z-index: 50; top: 50%; right: auto; bottom: auto; left: 50%; width: min(440px, calc(100vw - 70px)); max-height: calc(100vh - 180px); overflow-y: auto; transform: translate(-50%, -50%); }
.media-viewer-content img, .media-viewer-content video { display: block; max-width: 100%; max-height: calc(100vh - 190px); object-fit: contain; }
.media-viewer-item.has-note img, .media-viewer-item.has-note video { max-height: calc(100vh - 300px); }
.media-viewer-note { display: grid; gap: 5px; border: 1px solid #bfeee7; border-left: 5px solid #18b6a2; border-radius: 10px; padding: 12px 15px; color: #202b3f; background: #f7fffd; box-shadow: 0 6px 18px #0003; overflow-wrap: anywhere; }
.media-viewer-note strong { color: #087d70; font-size: .7rem; letter-spacing: .055em; text-transform: uppercase; }
.media-viewer-note p { margin: 0; font-size: .92rem; font-weight: 650; line-height: 1.55; white-space: pre-wrap; }
.media-viewer-navigation { position: absolute; z-index: 2; top: 50%; display: grid; width: 46px; height: 58px; transform: translateY(-50%); place-items: center; border: 1px solid #ffffff38; border-radius: 12px; padding: 0; color: #fff; background: #111827bf; box-shadow: 0 8px 24px #0005; font-size: 2rem; line-height: 1; }
.media-viewer-navigation:hover:not(:disabled) { border-color: #ffffff78; background: #6757ed; }
.media-viewer-navigation:disabled { opacity: .28; cursor: default; }
.media-viewer-navigation.previous { left: 18px; }
.media-viewer-navigation.next { right: 18px; }
.is-hidden { display: none !important; }

@media (max-width: 1300px) {
  .app-shell { --sidebar-width: 235px; }
  .workspace { padding: 32px 26px 50px; }
  .quota-card { grid-template-columns: 1fr 170px 170px; }
  .insights-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .insights-media-item { grid-template-columns: 64px minmax(180px, 1fr) repeat(3, minmax(68px, .45fr)) auto; }
  .insights-media-value.optional { display: none; }
}

@media (max-width: 760px) {
  .role-preview-banner { align-items: stretch; flex-direction: column; }
  .planning-cadence-options { grid-template-columns: 1fr; }
  .instagram-app-config-form, .instagram-profile-input-row { grid-template-columns: 1fr; }
  .instagram-config-actions { align-items: stretch; flex-direction: column; }
  .backend-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .backend-system-details { grid-template-columns: 1fr; }
  .insights-toolbar { grid-template-columns: 1fr 1fr; }
  .insights-toolbar button { width: 100%; }
  .insights-two-column { grid-template-columns: 1fr; }
  .insights-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .insights-media-item { grid-template-columns: 58px minmax(0, 1fr) auto; }
  .insights-media-thumb { width: 58px; height: 58px; }
  .insights-media-value { display: none; }
  .insights-section-heading { align-items: stretch; flex-direction: column; }
  .insights-metric-row { grid-template-columns: minmax(120px,.8fr) 80px; }
  .insights-metric-row > :last-child { display: none; }
}
