.demo-mode-banner[hidden] {
  display: none !important;
}

.demo-mode-banner {
  box-sizing: border-box;
  width: 100%;
  padding: 13px 16px;
  color: #fff;
  background: #43346f;
  border-bottom: 1px solid #312451;
  font-size: 13px;
  line-height: 1.45;
}

.demo-mode-banner-inner {
  width: min(1100px, 100%);
  margin: 0 auto;
  display: grid;
  grid-template-columns: auto minmax(240px, 1fr) auto auto;
  align-items: center;
  gap: 8px 14px;
  text-align: left;
}

.demo-mode-title {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #fff;
  font-size: 16px;
  font-weight: 900;
  letter-spacing: -0.01em;
  white-space: nowrap;
}

.demo-mode-title::before {
  content: 'DEMO';
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 2px 8px;
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 999px;
  background: #fff;
  color: #43346f;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.demo-mode-description {
  min-width: 0;
  color: #f0ecff;
  font-size: 13px;
  font-weight: 600;
}

.demo-mode-data-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px 9px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.35);
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}

.demo-mode-time {
  padding: 4px 8px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.1);
  color: #f5f2ff;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

@media (max-width: 900px) {
  .demo-mode-banner-inner {
    grid-template-columns: auto 1fr auto;
  }

  .demo-mode-description {
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .demo-mode-time {
    grid-column: 2;
    grid-row: 1;
    justify-self: end;
  }
}

@media (max-width: 640px) {
  .demo-mode-banner {
    padding: 12px;
  }

  .demo-mode-banner-inner {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 7px 8px;
  }

  .demo-mode-title {
    min-width: 0;
    font-size: 15px;
  }

  .demo-mode-title::before {
    min-height: 20px;
    padding: 1px 7px;
    font-size: 9px;
  }

  .demo-mode-description {
    grid-column: 1 / -1;
    grid-row: 2;
    font-size: 12px;
    line-height: 1.5;
    overflow-wrap: anywhere;
  }

  .demo-mode-time {
    grid-column: 1 / -1;
    grid-row: 3;
    justify-self: start;
    padding: 3px 7px;
    font-size: 10px;
    white-space: normal;
  }

  .demo-mode-data-badge {
    grid-column: 2;
    grid-row: 1;
    padding: 3px 7px;
    font-size: 9px;
  }
}
