:root {
  --ink: #292d32;
  --muted: #7c838b;
  --cream: #f2f3f5;
  --green: #0c53a2;
  --green-2: #174f8f;
  --lime: #ff5410;
  --blue: #0c53a2;
  --orange: #ff5410;
  --line: #e3e6ea;
  --shadow: 0 4px 20px #26374d0a;
}

aside {
  background: linear-gradient(180deg, #0c53a2 0%, #083f7c 100%);
}

.brand {
  display: grid;
  align-items: initial;
  gap: 2px;
}

.brand b,
.logo {
  color: #ff5410;
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", sans-serif;
  font-weight: 800;
}

.brand b {
  font-size: 24px;
}

.brand span {
  color: #fff;
  font-size: 9px;
  letter-spacing: 1.1px;
  opacity: .8;
}

nav button {
  color: #d8e7f7;
}

nav button.active {
  box-shadow: inset 4px 0 0 #ff5410;
}

button.primary,
#loginBtn {
  background: #ff5410;
  color: #fff;
  box-shadow: 0 6px 16px #ff54102b;
}

button.primary:hover,
#loginBtn:hover {
  background: #e94708;
}

.metric strong {
  color: #0c53a2;
}

.quick-grid button > span {
  background: #eaf2fb;
  color: #0c53a2;
}

.quick-grid button:first-child > span,
.quick-grid button:last-child > span {
  background: #fff0ea;
  color: #ff5410;
}

.range-button.active,
.chart-tab.active {
  color: #0c53a2;
}

.chart-tab.active {
  background: #eaf2fb;
}

.project-groups > div:last-child h3 i {
  background: #ff5410;
}

.operator {
  border: 1px solid #e8eaed;
}

input:focus {
  border-color: #0c53a2;
  outline: 3px solid #0c53a21a;
}

.panel {
  border: 1px solid #e9ebee;
}

.status-dot {
  background: #ff5410;
  box-shadow: 0 0 0 4px #ff54101f;
}

.brand {
  display: grid;
  justify-items: start;
  gap: 8px;
  margin-bottom: 34px;
}

.brand img {
  width: 62px;
  height: 62px;
  border-radius: 50%;
  background: #fff;
  object-fit: cover;
  box-shadow: 0 5px 18px #032e5f55;
}

.brand > div {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.brand b {
  color: #fff;
  font-size: 17px;
  line-height: 1.25;
  white-space: nowrap;
}

.brand span {
  color: #ffb08f;
  font-size: 9px;
  font-weight: 700;
}

nav {
  overflow-y: auto;
}

.create-dialog {
  width: min(1180px, 96vw);
  max-width: none;
  max-height: 94vh;
  background: #f3f4f6;
}

.create-dialog form {
  width: auto;
  padding: 0;
}

.create-head {
  position: sticky;
  top: 0;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 28px;
  background: #fff;
  border-bottom: 1px solid #e3e6ea;
}

.create-head p {
  margin: 0 0 2px;
  color: #7c838b;
  font-size: 12px;
}

.dialog-close {
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 50%;
  background: #f0f2f4;
  font-size: 23px;
  cursor: pointer;
}

.form-section {
  margin: 18px 22px;
  padding: 24px;
  border: 1px solid #e4e7eb;
  border-radius: 14px;
  background: #fff;
}

.section-heading {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 18px;
}

.section-heading b {
  font-size: 19px;
}

.section-heading span {
  color: #7c838b;
  font-size: 12px;
}

.show-basic-layout {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 24px;
}

.poster-field {
  display: grid;
  gap: 8px;
  color: #7c838b;
}

.poster-field input,
.import-copy input {
  display: none;
}

.poster-preview {
  width: 180px;
  aspect-ratio: 3/4;
  border: 2px dashed #cfd5dc;
  border-radius: 12px;
  background: #f6f7f8 center/cover no-repeat;
  color: #0c53a2;
  display: grid;
  place-items: center;
  cursor: pointer;
}

.show-fields {
  align-content: start;
}

.editor-toolbar {
  display: flex;
  gap: 6px;
  padding: 9px;
  border: 1px solid #dfe3e7;
  border-bottom: 0;
  border-radius: 10px 10px 0 0;
  background: #f7f8fa;
}

.editor-toolbar button,
.import-copy {
  border: 0;
  border-radius: 6px;
  background: #fff;
  padding: 7px 11px;
  cursor: pointer;
  color: #4f565e;
}

.import-copy {
  margin-left: auto;
  color: #0c53a2;
}

.rich-editor {
  min-height: 220px;
  padding: 18px;
  border: 1px solid #dfe3e7;
  border-radius: 0 0 10px 10px;
  outline: none;
  line-height: 1.8;
}

.rich-editor:empty::before {
  content: attr(data-placeholder);
  color: #adb2b8;
}

.sessions-container {
  display: grid;
  gap: 14px;
}

.session-editor {
  border: 1px solid #dfe3e7;
  border-radius: 12px;
  overflow: hidden;
}

.session-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 17px;
  background: #f6f7f9;
}

.session-head button,
.remove-tier,
.add-tier {
  border: 0;
  background: transparent;
  color: #0c53a2;
  cursor: pointer;
}

.session-head .remove-session,
.remove-tier {
  color: #d93b45;
}

.session-fields {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  padding: 18px;
}

.session-fields label,
.settings-form label {
  display: grid;
  gap: 6px;
  color: #707780;
}

select {
  border: 1px solid #d8ddd9;
  border-radius: 9px;
  padding: 11px;
  background: #fff;
}

.tier-table {
  margin: 0 18px;
  overflow-x: auto;
}

.tier-row {
  min-width: 850px;
  display: grid;
  grid-template-columns: 110px 110px 1.1fr 1.4fr 95px 100px 65px;
  gap: 8px;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid #edf0f2;
}

.tier-header {
  color: #7c838b;
  font-size: 12px;
  background: #fafbfc;
}

.add-tier {
  margin: 12px 18px 18px;
}

.add-session {
  width: 100%;
  margin-top: 14px;
  padding: 14px;
  border: 1px dashed #0c53a2;
  border-radius: 10px;
  background: #edf5fd;
  color: #0c53a2;
  font-weight: 700;
  cursor: pointer;
}

.sticky-actions {
  position: sticky;
  bottom: 0;
  z-index: 5;
  margin: 0;
  padding: 16px 26px;
  background: #fff;
  border-top: 1px solid #e3e6ea;
}

.show-cell {
  display: flex;
  align-items: center;
  gap: 10px;
}

.show-cell img {
  width: 42px;
  height: 54px;
  border-radius: 6px;
  object-fit: cover;
}

.report-cards,
.sentiment-cards {
  margin-bottom: 16px;
}

.sentiment-banner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  padding: 24px;
  border-radius: 16px;
  background: linear-gradient(120deg, #0c53a2, #1769bd);
  color: #fff;
}

.sentiment-banner b {
  font-size: 21px;
}

.sentiment-banner p {
  margin: 5px 0 0;
  color: #dbeaf8;
}

.sentiment-banner span {
  padding: 6px 11px;
  border-radius: 99px;
  background: #ff5410;
  font-weight: 700;
}

.platform-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}

.platform-chips input {
  display: none;
}

.platform-chips span {
  display: block;
  padding: 8px 14px;
  border: 1px solid #dce1e6;
  border-radius: 99px;
  cursor: pointer;
}

.platform-chips input:checked + span {
  border-color: #0c53a2;
  background: #eaf2fb;
  color: #0c53a2;
  font-weight: 700;
}

.collection-panel,
.task-panel {
  margin-bottom: 16px;
}

.collection-mode {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 18px;
}

.collection-mode button {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 15px;
  border: 1px solid #dfe3e7;
  border-radius: 12px;
  background: #fafbfc;
  text-align: left;
  cursor: pointer;
}

.collection-mode button > b {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #eaf2fb;
  color: #0c53a2;
}

.collection-mode button span,
.collection-mode button strong,
.collection-mode button small {
  display: block;
}

.collection-mode button small {
  margin-top: 2px;
  color: #7c838b;
}

.collection-mode button.active {
  border-color: #0c53a2;
  background: #f1f7fd;
  box-shadow: 0 0 0 3px #0c53a212;
}

.collection-mode button.active > b {
  background: #ff5410;
  color: #fff;
}

.collection-form {
  display: grid;
  grid-template-columns: minmax(260px, 1.6fr) minmax(180px, .8fr) minmax(140px, .6fr) auto;
  align-items: end;
  gap: 12px;
}

.collection-form label {
  display: grid;
  gap: 6px;
  color: #707780;
}

.collection-form input,
.collection-form select {
  width: 100%;
}

.link-mode .keyword-field,
.keyword-mode .link-field,
.collection-panel:has(.link-mode) > .keyword-field {
  display: none;
}

.keyword-platforms {
  margin-top: 16px;
}

.keyword-platforms > span {
  display: block;
  margin-bottom: 8px;
  color: #707780;
}

.task-platform-chips span {
  border-radius: 10px;
}

.task-platform-chips small {
  display: block;
  color: #8a929b;
  font-size: 10px;
}

.task-platform-chips input:checked + span small {
  color: #567aa4;
}

.compliance-note {
  margin: 16px 0 0;
  padding: 10px 12px;
  border-radius: 8px;
  background: #fff7f2;
  color: #87513a;
  font-size: 12px;
}

.positive-card strong {
  color: #168a58;
}

.negative-card strong {
  color: #d93b45;
}

.sentiment-grid,
.settings-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 16px;
  margin: 16px 0;
}

.suggestion {
  padding: 14px;
  border-left: 4px solid #ff5410;
  border-radius: 7px;
  background: #fff3ed;
  line-height: 1.7;
}

.sentiment-chart {
  display: grid;
  gap: 10px;
  margin-bottom: 20px;
}

.sentiment-chart > div {
  display: grid;
  grid-template-columns: 64px 1fr 36px;
  align-items: center;
  gap: 10px;
}

.sentiment-chart i {
  height: 9px;
  overflow: hidden;
  border-radius: 99px;
  background: #edf0f3;
}

.sentiment-chart i b {
  display: block;
  height: 100%;
  min-width: 2px;
  border-radius: inherit;
  background: linear-gradient(90deg, #0c53a2, #ff5410);
}

.settings-form {
  display: grid;
  gap: 14px;
}

.check-setting {
  grid-template-columns: auto 1fr;
  align-items: center;
  justify-content: start;
}

.admin-create {
  display: grid;
  grid-template-columns: repeat(4, 1fr) auto;
  gap: 10px;
  margin-bottom: 18px;
}

@media (max-width: 1100px) {
  .show-basic-layout,
  .sentiment-grid,
  .settings-grid {
    grid-template-columns: 1fr;
  }
  .session-fields,
  .admin-create {
    grid-template-columns: 1fr 1fr;
  }
  .collection-form {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 760px) {
  .collection-mode,
  .collection-form {
    grid-template-columns: 1fr;
  }
}
