/* SladdjansBar v5.9 – styrning i Inställningar > Neonfärg */

/* Äldre överlägg och canvasar får aldrig visas samtidigt med v5.9. */
.brand-flow-wrap::after,
.dashboard-logo-canvas {
  display: none !important;
  content: none !important;
  animation: none !important;
}
.brand-flow-wrap .shared-brand-logo {
  animation: none !important;
  filter: none !important;
}

.logo-neon-canvas {
  display: block;
  max-width: 100%;
  max-height: 54px;
  object-fit: contain;
}

/* Det tillfälliga fristående reglaget från v5.8 ersätts. */
#systemNeonSettings {
  display: none !important;
}

.logo-neon-controls {
  width: 100%;
  min-width: 0;
  max-width: none;
  grid-column: 1 / -1 !important;
  flex: 1 0 100%;
  align-self: stretch;
  order: 999;
  overflow: hidden;
  margin-top: 16px;
  padding: 17px;
  border: 1px solid rgba(42, 218, 204, .34);
  border-radius: 15px;
  color: #eef8fb;
  background:
    radial-gradient(circle at 91% 13%, rgba(239, 68, 181, .09), transparent 28%),
    linear-gradient(145deg, rgba(10, 34, 45, .96), rgba(5, 18, 29, .98));
  box-shadow: 0 10px 25px rgba(0,0,0,.17), 0 0 15px rgba(32,214,226,.05);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
.logo-neon-host {
  min-width: 0;
}
.logo-neon-controls * { box-sizing: border-box; }
.logo-neon-controls > header {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) minmax(260px, 340px);
  align-items: center;
  gap: 15px;
  margin-bottom: 15px;
}
.logo-neon-controls h3 { margin: 0 0 4px; font-size: 18px; }
.logo-neon-controls p { margin: 0; color: #8fa7b5; font-size: 12px; }
.logo-neon-preview {
  width: 100%;
  min-width: 0;
  min-height: 68px;
  display: grid;
  place-items: center;
  padding: 9px 14px;
  border: 1px solid rgba(66, 182, 194, .24);
  border-radius: 10px;
  background: rgba(4, 16, 26, .72);
}
.logo-neon-preview img {
  display: block;
  width: 270px;
  max-width: 100%;
  height: auto;
}
.logo-neon-preview canvas {
  display: block;
  width: min(270px, 100%) !important;
  max-width: 100%;
  max-height: 58px;
}

.logo-neon-row {
  min-width: 0;
  min-height: 62px;
  display: grid;
  grid-template-columns: minmax(190px, .65fr) minmax(0, 1.35fr) 64px;
  align-items: center;
  gap: 13px;
  padding: 10px 0;
  border-bottom: 1px solid rgba(76, 143, 166, .15);
}
.logo-neon-row > span { min-width: 0; display: grid; gap: 3px; }
.logo-neon-row strong { font-size: 13px; }
.logo-neon-row small { color: #8199a8; font-size: 11px; }
.logo-neon-row input[type="range"] {
  width: 100% !important;
  min-width: 0 !important;
  max-width: none !important;
  margin: 0 !important;
  accent-color: #ec48b1;
  cursor: pointer;
}
.logo-neon-value {
  width: 64px;
  min-width: 64px;
  min-height: 35px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(40, 212, 222, .34);
  border-radius: 8px;
  color: #76f2f8;
  background: rgba(18, 117, 130, .13);
  font-size: 12px;
  font-weight: 900;
}
.logo-neon-switch {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 55px;
  padding-bottom: 7px;
  border-bottom: 1px solid rgba(76, 143, 166, .15);
}
.logo-neon-switch span { display: grid; gap: 3px; }
.logo-neon-switch small { color: #8199a8; }
.logo-neon-toggle {
  position: relative;
  flex: 0 0 auto;
  width: 50px;
  height: 27px;
  display: block !important;
}
.logo-neon-toggle input {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  margin: 0 !important;
  opacity: 0 !important;
  pointer-events: none;
}
.logo-neon-toggle i {
  position: absolute;
  inset: 0;
  display: block;
  border-radius: 999px;
  background: #344754;
  box-shadow: inset 0 2px 5px rgba(0,0,0,.35);
  cursor: pointer;
  transition: .2s ease;
}
.logo-neon-toggle i::after {
  content: "";
  position: absolute;
  top: 4px;
  left: 4px;
  width: 19px;
  height: 19px;
  border-radius: 50%;
  background: #e5edf0;
  box-shadow: 0 2px 5px rgba(0,0,0,.3);
  transition: transform .2s ease;
}
.logo-neon-toggle input:checked + i {
  background: #29c97a;
  box-shadow: 0 0 12px rgba(52, 231, 137, .34), inset 0 1px rgba(255,255,255,.15);
}
.logo-neon-toggle input:checked + i::after {
  transform: translateX(23px);
}
.logo-neon-toggle input:focus-visible + i {
  outline: 2px solid #69ecf4;
  outline-offset: 3px;
}
.logo-neon-colors {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  padding-top: 12px;
}
.logo-neon-colors label {
  min-width: 0;
  min-height: 58px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 11px;
  border: 1px solid rgba(67, 134, 158, .21);
  border-radius: 10px;
  background: rgba(5, 19, 28, .6);
}
.logo-neon-colors span { display: grid; gap: 3px; font-size: 13px; font-weight: 800; }
.logo-neon-colors small { color: #8199a8; font-size: 10px; font-weight: 500; }
.logo-neon-colors input[type="color"] {
  width: 46px;
  height: 36px;
  padding: 2px;
  border: 1px solid #315063;
  border-radius: 8px;
  background: #071722;
  cursor: pointer;
}
.logo-neon-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  margin-top: 13px;
}
.logo-neon-message { min-height: 18px; margin: 0 !important; text-align: right; }
.logo-neon-message.ok { color: #6bedaa; }
.logo-neon-message.error { color: #ff8cab; }
.logo-neon-save {
  min-height: 41px;
  padding: 0 18px;
  border: 1px solid rgba(42, 218, 204, .47);
  border-radius: 10px;
  color: #aaf9ef;
  background: rgba(18, 104, 117, .29);
  font-weight: 850;
  cursor: pointer;
}
.logo-neon-save:disabled { cursor: wait; opacity: .55; }

@media (max-width: 700px) {
  .logo-neon-controls > header { grid-template-columns: 1fr; align-items: flex-start; }
  .logo-neon-row { grid-template-columns: 1fr 55px; }
  .logo-neon-row > span { grid-column: 1 / -1; }
  .logo-neon-colors { grid-template-columns: 1fr; }
}
