.perf-page { min-width: 0; }
.perf-toast { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%); max-width: calc(100vw - 32px); z-index: 1200; background: #273449; color: #fff; padding: 10px 18px; border-radius: 6px; font-size: 12px; }
.main:has([data-view="ad-data"].active) .topbar { padding-top: 18px; padding-bottom: 18px; min-height: 76px; }
.main:has([data-view="ad-data"].active) #pageTitle { font-size: 24px; }
.main:has([data-view="ad-data"].active) #pageSubtitle,
.main:has([data-view="ad-data"].active) #exportDataButton,
.main:has([data-view="ad-data"].active) #goBindingsButton { display: none; }
.main:has([data-view="ad-data"].active) .content { padding-top: 16px; }
#performanceRoot [hidden] { display: none !important; }
#performanceRoot .perf-platform-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
#perfPlatforms { display: flex; flex-wrap: wrap; gap: 6px; }
#perfPlatforms button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 38px; padding: 0 14px; border: 1px solid transparent; border-radius: 6px; background: transparent; color: var(--muted); font: inherit; font-size: 13px; cursor: pointer; }
#perfPlatforms button[aria-selected="true"] { color: var(--brand-button); background: #fff; border-color: var(--line); }
#perfPlatforms img { width: 20px; height: 20px; object-fit: contain; }
#perfPlatforms [data-platform="meta"] img { width: 24px; }
#performanceRoot .perf-navigation .perf-date-field { width: 270px; gap: 0; margin-left: auto; }
#performanceRoot .perf-navigation .perf-date-field > label { position: absolute; width: 1px; height: 1px; clip-path: inset(50%); overflow: hidden; }
#performanceRoot .perf-date-trigger { height: 36px; }
#perfLevels { display: flex; gap: 20px; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; background: transparent; padding: 0; margin-top: 8px; overflow-x: auto; max-width: 100%; }
#perfLevels button { display: inline-flex; gap: 6px; align-items: center; flex-shrink: 0; height: 44px; padding: 0 8px; font-size: 13px; border: 0; border-bottom: 2px solid transparent; border-radius: 0; background: transparent; box-shadow: none; }
#perfLevels button.active { border-bottom-color: var(--brand-button); color: var(--brand-button); background: transparent; }
#perfLevels .material-symbols-outlined { display: none; }
#performanceRoot .perf-toolbar { padding: 16px 0; gap: 12px 20px; border-bottom: 0; align-items: flex-end; }
#performanceRoot .perf-filters { display: flex; flex: 1 1 500px; align-items: center; gap: 12px; flex-wrap: wrap; margin: 0; min-width: 0; }
#performanceRoot .perf-filters > label { flex: 0 1 160px; min-width: 0; font-size: 0; gap: 0; }
#performanceRoot .perf-filters .perf-search { flex: 1 1 190px; }
#performanceRoot .perf-filters input, #performanceRoot .perf-filters .custom-select-trigger { height: 36px; min-height: 36px; font-size: 12px; }
#performanceRoot .perf-filters .custom-select-option { font-size: 12px; }
#performanceRoot .perf-campaign-filter { width: 180px; gap: 0; }
#performanceRoot .perf-campaign-filter > span { display: none; }
#performanceRoot .perf-toolbar .panel-actions { margin-left: auto; display: flex; flex-wrap: wrap; gap: 8px; }
#performanceRoot .perf-toolbar .panel-actions > button { min-height: 36px; padding: 0 10px; font-size: 12px; }
#performanceRoot #perfSync { min-width: 120px; padding: 0 8px; gap: 4px; }
#performanceRoot #perfSync .material-symbols-outlined { font-size: 16px; }
#performanceRoot[data-scoped="false"] #perfScope { display: none; }
#performanceRoot #perfScope .perf-timezone { display: none; }
#performanceRoot #perfMessage:empty, #performanceRoot #perfAutoStatus:empty { display: none; }
@media (max-width: 600px) {
  .main:has([data-view="ad-data"].active) .topbar { flex-direction: row; align-items: center; }
  .main:has([data-view="ad-data"].active) .top-actions { width: auto; }
  #perfPlatforms { width: 100%; justify-content: space-between; gap: 0; }
  #perfPlatforms button { padding: 0 6px; font-size: 12px; gap: 5px; }
  #performanceRoot .perf-navigation .perf-date-field { width: 100%; }
  #perfLevels { gap: 6px; justify-content: space-between; }
  #perfLevels button { padding: 0 3px; font-size: 12px; }
  #performanceRoot .perf-filters { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  #performanceRoot .perf-filters .perf-search, #performanceRoot .perf-campaign-filter { grid-column: 1 / -1; width: 100%; }
  #performanceRoot .perf-toolbar .panel-actions { width: 100%; justify-content: flex-end; }
}
.overview-live .overview-hero { margin-bottom: 18px; }
.overview-live .overview-filters { margin-bottom: 20px; grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr)); gap: 16px; }
.overview-live .overview-filters > * { min-width: 0; }
.overview-live .overview-summary { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.overview-live .overview-summary .metric strong { font-variant-numeric: tabular-nums; }
.overview-notice { min-height: 28px; padding: 0 0 12px; color: var(--muted); font-size: 13px; }
.overview-empty { height: 150px; text-align: center !important; vertical-align: middle !important; color: var(--muted); }
.overview-empty.error { color: #b42318; }
.overview-data-panel table { --table-min-width: 1942px; }
.account-content-table {
  table-layout: fixed;
  width: max(100%, var(--table-min-width));
  min-width: var(--table-min-width);
}
.account-content-table th,
.account-content-table td {
  white-space: normal;
  overflow-wrap: anywhere;
  letter-spacing: 0;
}
.account-content-table .campaign {
  min-width: 0;
  max-width: 100%;
  grid-template-columns: minmax(0, 1fr);
}
.account-content-table .campaign > * {
  min-width: 0;
  max-width: 100%;
  white-space: normal;
  overflow-wrap: anywhere;
}
.account-content-table .chip { max-width: 100%; white-space: normal; overflow-wrap: anywhere; }
.account-content-table button { max-width: 100%; }
.account-assets-table { --table-min-width: 1886px; }
.overview-data-panel td small { display: block; margin-top: 4px; color: var(--muted); font-size: 11px; }
.overview-data-panel th:nth-child(n+4):nth-child(-n+9),
.overview-data-panel td:nth-child(n+4):nth-child(-n+9) { text-align: right; font-variant-numeric: tabular-nums; }
@media (max-width: 1000px) { .overview-live .overview-summary { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 540px) { .overview-live .overview-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.perf-filters { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 14px; margin-bottom: 22px; align-items: end; }
.perf-filters label { display: grid; min-width: 0; gap: 7px; font-size: 13px; color: var(--muted); }
.perf-campaign-filter { position: relative; display: grid; gap: 7px; min-width: 0; font-size: 13px; color: var(--muted); }
.perf-campaign-filter[hidden], .perf-campaign-picker[hidden] { display: none; }
.perf-campaign-picker { position: absolute; top: calc(100% + 8px); left: 0; z-index: 65; width: min(460px, calc(100vw - 32px)); background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 12px; box-shadow: 0 8px 24px #172b4d24; color: var(--ink); font-size: 12px; }
#perfCampaignOptions { height: 268px; overflow-y: auto; margin: 8px 0; }
.perf-filters .perf-campaign-option { display: flex; align-items: flex-start; gap: 9px; padding: 9px 4px; cursor: pointer; font-size: 12px; }
.perf-campaign-option input { width: 14px; height: 14px; margin: 3px 0 0; flex: 0 0 14px; }
.perf-campaign-option span { min-width: 0; overflow-wrap: anywhere; }
.perf-campaign-option b { font-weight: 500; }
.perf-campaign-option small { display: block; font-size: 12px; color: var(--muted); margin-top: 4px; }
.perf-campaign-pages, .perf-campaign-picker footer { display: flex; align-items: center; gap: 10px; justify-content: space-between; }
.perf-campaign-picker footer { border-top: 1px solid var(--line); margin-top: 8px; padding-top: 10px; }
.perf-campaign-picker footer button, .perf-campaign-pages button { font-size: 12px; min-height: 32px; }
@media (max-width: 540px) { .perf-campaign-filter { grid-column: 1 / -1; } .perf-campaign-picker { position: fixed; top: 64px; left: 16px; max-height: calc(100dvh - 96px); overflow-y: auto; } }
.perf-filters input { width: 100%; min-width: 0; height: 44px; border: 1px solid var(--line); border-radius: 8px; background: #fff; padding: 0 12px; color: var(--ink); font: inherit; }
.perf-date-field { position: relative; display: grid; gap: 7px; min-width: 0; font-size: 13px; color: var(--muted); }
.perf-date-trigger { height: 44px; width: 100%; border: 1px solid var(--line); border-radius: 8px; background: #fff; color: var(--ink); padding: 0 12px; font: inherit; text-align: left; cursor: pointer; white-space: nowrap; }
.perf-date-trigger[aria-expanded="true"] { border-color: var(--brand-button); box-shadow: 0 0 0 4px rgba(37,99,235,.14); }
.perf-date-picker { position: absolute; z-index: 60; top: calc(100% + 9px); left: 0; width: min(780px, calc(100vw - 32px)); min-height: 320px; border: 1px solid var(--line); border-radius: 8px; background: #fff; box-shadow: 0 18px 42px rgba(15,23,42,.2); color: var(--ink); display: grid; grid-template-columns: 150px 1fr; overflow: hidden; }
.perf-date-picker[hidden] { display: none; }
.perf-date-picker aside { border-right: 1px solid var(--line-soft); background: #fafbfd; padding: 8px 0; }
.perf-date-picker aside button { display: block; width: 100%; border: 0; background: transparent; padding: 10px 18px; color: var(--ink); text-align: left; font: inherit; cursor: pointer; }
.perf-date-picker aside button:hover { background: #eef5ff; color: var(--brand-button); }
.perf-calendars { grid-column: 2; display: grid; grid-template-columns: 1fr 1fr; padding: 16px 20px 4px; gap: 24px; }
.perf-calendars section header { display: flex; align-items: center; justify-content: space-between; height: 34px; }
.perf-calendars section header strong { font-weight: 600; }
.perf-calendars section header button { width: 28px; height: 28px; border: 0; background: transparent; cursor: pointer; color: var(--ink); }
.perf-calendars section header .material-symbols-outlined { font-size: 19px; }
.perf-weekdays, .perf-days { display: grid; grid-template-columns: repeat(7, 1fr); text-align: center; gap: 3px; }
.perf-weekdays { margin: 10px 0 5px; color: var(--muted); font-size: 12px; }
.perf-day { min-width: 28px; height: 30px; border: 0; border-radius: 5px; background: transparent; color: var(--ink); cursor: pointer; font: inherit; }
.perf-day:hover { background: #eaf3ff; color: var(--brand-button); }
.perf-day.in-range { background: #eaf3ff; border-radius: 0; }
.perf-day.selected { background: #00a6a6; color: white; border-radius: 5px; }
.perf-day.empty { pointer-events: none; }
.perf-date-picker footer { grid-column: 1 / -1; border-top: 1px solid var(--line-soft); padding: 12px 20px; display: flex; justify-content: flex-end; gap: 10px; }
.perf-date-picker footer button { min-width: 88px; justify-content: center; }
.date-range-feedback { margin-right: auto; align-self: center; font-size: 12px; overflow-wrap: anywhere; }
.perf-date-picker { max-height: calc(100dvh - 96px); overflow-y: auto; font-size: 12px; }
.perf-date-trigger { font-size: 12px; font-weight: 400; }
.perf-day:disabled { opacity: .35; cursor: not-allowed; }
.perf-date-picker button:focus-visible { outline: 2px solid var(--brand-button); outline-offset: -2px; }
@media (max-width: 540px) {
  .perf-date-picker footer { flex-wrap: wrap; padding: 12px; }
  .date-range-feedback { flex-basis: 100%; }
}
#accountsTable .chip.coral { position: relative; overflow: hidden; background: linear-gradient(#fff,#fff) padding-box, linear-gradient(90deg,#25f4ee,#fe2c55) border-box; color: #253044; border: 1px solid transparent; border-radius: 5px; font-weight: 600; }
#accountsTable .chip.coral::after { content: ""; position: absolute; left: 10px; right: 10px; bottom: 3px; height: 2px; background: linear-gradient(90deg,#25f4ee,#fe2c55); opacity: .8; }
#accountsTable .row-actions { display: inline-flex; align-items: center; gap: 7px; }
#accountsTable .row-actions .mini { white-space: nowrap; }
#accountsTable .row-actions .mini.danger { display: inline-flex; align-items: center; justify-content: center; width: 32px; min-width: 32px; padding: 0; color: #d92d20; }
#accountsTable .row-actions .mini.danger .material-symbols-outlined { font-size: 17px; }
.perf-filters .custom-select-trigger { background: #fff; white-space: nowrap; overflow: hidden; }
.perf-filters .custom-select-option { white-space: normal; overflow-wrap: anywhere; }
.perf-filters .custom-select-options { max-height: 300px; }
.perf-filters .secondary-button { min-height: 44px; justify-content: center; }
.perf-toolbar, .perf-scope { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.perf-toolbar { padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.perf-toolbar .segmented button { display: inline-flex; align-items: center; gap: 7px; }
.perf-toolbar .segmented .material-symbols-outlined { font-size: 18px; }
.perf-page button:disabled { opacity: .5; cursor: default; }
.perf-scope { justify-content: flex-start; padding: 15px 0 8px; font-size: 13px; color: var(--muted); }
.perf-scope strong { font-size: 13px; color: var(--ink); overflow-wrap: anywhere; }
.perf-scope > * { min-width: 0; max-width: 100%; overflow-wrap: anywhere; }
.perf-scope .perf-link { display: inline-flex; align-items: center; gap: 4px; }
.perf-scope .material-symbols-outlined { font-size: 16px; }
.perf-timezone { margin-left: auto; }
.perf-link { border: 0; padding: 0; color: var(--brand-button); background: transparent; font: inherit; cursor: pointer; text-align: left; overflow-wrap: anywhere; }
.perf-link:hover { text-decoration: underline; }
.perf-message { min-height: 30px; font-size: 13px; line-height: 20px; color: var(--muted); padding-bottom: 8px; }
.perf-message.error { color: #b42318; }
.perf-job { border-left: 3px solid #2563eb; padding: 12px 16px; background: #eef5ff; margin: 4px 0 16px; color: var(--ink); font-size: 13px; }
.perf-job-heading { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.perf-job-active { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 14px; min-height: 20px; font-size: 12px; line-height: 20px; }
.perf-job-active span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (max-width: 600px) { .perf-job-active { grid-template-columns: minmax(0, 1fr); min-height: 60px; align-content: start; } }
.perf-job progress { width: 100%; height: 6px; margin-top: 10px; accent-color: #2563eb; }
.perf-job details { margin-top: 8px; }
.perf-job li { overflow-wrap: anywhere; margin: 6px 0; }
.perf-totals { display: flex; gap: 28px; flex-wrap: wrap; padding: 0 0 18px; }
.perf-totals[hidden] { display: none; }
#perfColumns[hidden] { display: none; }
.perf-auto-status { min-height: 20px; font-size: 12px; color: var(--muted); margin-bottom: 8px; }
#perfTable [data-sync-account] { width: 28px; height: 28px; display: inline-flex; align-items: center; justify-content: center; vertical-align: middle; }
#perfTable [data-sync-account] .material-symbols-outlined { font-size: 16px; }
.perf-totals > div { display: grid; gap: 5px; min-width: 140px; }
.perf-totals span, .perf-totals small { color: var(--muted); font-size: 12px; }
.perf-totals strong { font-size: 23px; font-weight: 600; color: var(--ink); font-variant-numeric: tabular-nums; }
.perf-table-surface { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: #fff; }
.perf-table-surface[aria-busy="true"] tbody { opacity: .45; pointer-events: none; }
.perf-page table th button { display: inline-flex; align-items: center; gap: 5px; border: 0; background: transparent; color: inherit; font: inherit; cursor: pointer; padding: 0; }
.perf-page table th .material-symbols-outlined { font-size: 15px; }
.perf-page table thead tr.ag-summary th { background: #f7f9fc; color: var(--ink); font-weight: 500; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.perf-page table thead tr.ag-summary th.perf-number { font-weight: 600; }
.perf-page table small { display: block; margin-top: 5px; color: var(--muted); font-size: 11px; line-height: 16px; }
.perf-page .campaign b { font-weight: 500; }
.perf-number { font-variant-numeric: tabular-nums; text-align: right; }
.perf-page .perf-empty { height: 150px; text-align: left; vertical-align: middle; color: var(--muted); }
#perfPage { min-width: 60px; text-align: center; }
.ad-preview-dialog { width: min(640px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); padding: 0; border: 1px solid var(--border, #dfe3e8); border-radius: 8px; color: var(--text, #222); background: var(--surface, #fff); overflow: auto; font: 12px/20px Inter, "Noto Sans SC", sans-serif; }
.ad-preview-dialog::backdrop { background: rgb(0 0 0 / 35%); }
.ad-preview-dialog header, .ad-preview-dialog footer { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; gap: 12px; }
.ad-preview-dialog header { border-bottom: 1px solid var(--border, #dfe3e8); }
.ad-preview-dialog h2 { font-size: 16px; font-weight: 500; margin: 0; }
.ad-preview-identity { display: grid; gap: 4px; padding: 16px 20px; overflow-wrap: anywhere; }
.ad-preview-identity strong { font-weight: 500; }
.ad-preview-identity small { color: var(--muted, #666); font-size: 12px; }
.ad-preview-media { margin: 0 20px; min-height: 160px; display: grid; place-items: center; background: #f4f5f6; border-radius: 4px; overflow-wrap: anywhere; }
.ad-preview-media video { width: 100%; height: 360px; max-height: 48dvh; object-fit: contain; background: #111; }
.ad-preview-text { margin: 12px 20px 0; white-space: pre-wrap; overflow-wrap: anywhere; }
.ad-preview-media img { display: block; width: 100%; height: 360px; max-height: 48dvh; object-fit: contain; }
.ad-preview-dialog footer { justify-content: flex-end; }
.creative-thumbnail { width: 56px; height: 40px; padding: 0; border: 1px solid var(--border, #dfe3e8); border-radius: 4px; background: #f4f5f6; display: grid; place-items: center; overflow: hidden; cursor: pointer; color: var(--muted, #697386); }
.creative-thumbnail img { width: 100%; height: 100%; object-fit: cover; display: block; }
.creative-thumbnail:hover { border-color: var(--brand-button, #2563eb); }
.creative-thumbnail-empty .material-symbols-outlined { font-size: 20px; }
.creative-name { display: block; max-width: 280px; overflow-wrap: anywhere; }
.creative-designer { font: inherit; padding: 0; border: 0; background: transparent; color: var(--brand-button, #2563eb); text-align: left; }
.creative-designer-readonly { color: var(--ink, #273043); }
.creative-assignment-overlay { position: fixed; inset: 0; z-index: 1200; display: grid; place-items: center; padding: 24px; background: rgb(20 27 42 / 34%); }
.creative-assignment-overlay[hidden] { display: none; }
.creative-assignment-dialog { width: min(460px, 100%); max-height: min(680px, calc(100vh - 48px)); display: flex; flex-direction: column; overflow: hidden; background: #fff; border: 1px solid #e4e8ef; border-radius: 8px; box-shadow: 0 18px 60px rgb(20 27 42 / 18%); }
.creative-assignment-dialog header, .creative-assignment-dialog footer { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 18px 20px; border-bottom: 1px solid #edf0f4; }
.creative-assignment-dialog footer { justify-content: flex-end; border-top: 1px solid #edf0f4; border-bottom: 0; }
.creative-assignment-dialog h2 { margin: 0; font-size: 16px; }
.creative-assignment-dialog p { margin: 5px 0 0; color: #6f788b; font-size: 12px; }
.creative-assignment-body { min-height: 180px; overflow: auto; padding: 16px 20px; }
.creative-assignment-search { display: flex; align-items: center; gap: 8px; height: 36px; margin-bottom: 12px; padding: 0 10px; border: 1px solid #d9dee8; border-radius: 6px; color: #7a8498; }
.creative-assignment-search input { width: 100%; border: 0; outline: 0; font: inherit; font-size: 12px; }
.creative-assignment-option { display: flex; align-items: center; gap: 10px; padding: 11px 4px; border-bottom: 1px solid #f0f2f5; cursor: pointer; }
.creative-assignment-option input { accent-color: #2563eb; }
.creative-assignment-option span { display: grid; gap: 3px; }
.creative-assignment-option small, .creative-assignment-empty { color: #7a8498; font-size: 12px; }
.creative-assignment-empty { padding: 30px 4px; text-align: center; }
.creative-assignment-message { min-height: 20px; padding: 0 20px 12px; color: #7a8498; font-size: 12px; }
@media (max-width: 640px) { .creative-assignment-overlay { padding: 12px; place-items: end center; } .creative-assignment-dialog { max-height: calc(100vh - 24px); } }
@media (max-width: 1000px) { .perf-filters { grid-template-columns: repeat(2,minmax(0,1fr)); } }
@media (max-width: 540px) { .perf-filters { gap: 12px; } .perf-search, .perf-date-field { grid-column: 1 / -1; } .perf-timezone { margin-left: 0; width: 100%; } .perf-toolbar .panel-actions { width: 100%; justify-content: flex-end; } .perf-date-picker { position: fixed; top: 80px; left: 16px; width: calc(100vw - 32px); grid-template-columns: 112px 1fr; } .perf-calendars { grid-template-columns: 1fr; overflow: auto; max-height: 380px; padding: 12px; } .perf-calendars section:nth-child(2) { display: none; } .perf-date-picker aside button { padding-left: 12px; padding-right: 8px; } }
