#tool-root {
  width: 100%;
}
.gradientstudio {
  overflow: hidden;
  border: 1px solid rgba(139, 92, 246, 0.38);
  border-radius: 1rem;
  background: #090a10;
  color: #f8f7ff;
  box-shadow: 0 1.5rem 4.5rem rgba(0, 0, 0, 0.3);
}
.gradientstudio__header,
.gradientstudio__toolbar,
.gradientstudio__footer {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
}
.gradientstudio__header {
  align-items: flex-start;
  padding: 1.25rem 1.35rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.09);
  background:
    radial-gradient(circle at 0 0, rgba(124, 58, 237, 0.18), transparent 40%),
    #090a10;
}
.gradientstudio__eyebrow {
  margin: 0 0 0.38rem;
  color: #c4b5fd;
  font-size: 0.67rem;
  font-weight: 900;
  letter-spacing: 0.1em;
}
.gradientstudio__header h2 {
  margin: 0;
  color: #ffffff;
  font-size: 1.32rem;
  line-height: 1.2;
}
.gradientstudio__header p:not(.gradientstudio__eyebrow) {
  max-width: 43rem;
  margin: 0.46rem 0 0;
  color: #aaa7b8;
  font-size: 0.85rem;
  line-height: 1.55;
}
.gradientstudio__state {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 0.42rem;
  min-height: 2.15rem;
  padding: 0.28rem 0.7rem;
  border: 1px solid rgba(139, 92, 246, 0.55);
  border-radius: 999px;
  background: rgba(124, 58, 237, 0.13);
  color: #e0d9ff;
  font-size: 0.75rem;
}
.gradientstudio__state > span {
  width: 0.48rem;
  height: 0.48rem;
  border-radius: 50%;
  background: #a78bfa;
}
.gradientstudio__state[data-tone="success"] {
  border-color: rgba(52, 211, 153, 0.55);
  background: rgba(16, 185, 129, 0.12);
  color: #c7f8df;
}
.gradientstudio__state[data-tone="success"] > span {
  background: #34d399;
}
.gradientstudio__state[data-tone="error"] {
  border-color: rgba(251, 113, 133, 0.56);
  background: rgba(244, 63, 94, 0.11);
  color: #ffd5dc;
}
.gradientstudio__state[data-tone="error"] > span {
  background: #fb7185;
}
.gradientstudio__toolbar {
  align-items: center;
  padding: 0.76rem 1.35rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.09);
  background: #0b0c13;
}
.gradientstudio__toolbar-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.gradientstudio__toolbar .btn,
.gradientstudio__stops-header .btn {
  min-height: 2.35rem;
  padding: 0.46rem 0.82rem;
  border-radius: 0.68rem;
  font-size: 0.78rem;
}
.gradientstudio__workspace {
  display: grid;
  grid-template-columns: minmax(20rem, 0.95fr) minmax(0, 1.05fr);
}
.gradientstudio__preview-panel,
.gradientstudio__controls-panel {
  min-width: 0;
  padding: 1.12rem 1.35rem;
}
.gradientstudio__preview-panel {
  border-right: 1px solid rgba(255, 255, 255, 0.09);
  background: #0a0b12;
}
.gradientstudio__controls-panel {
  background: #090a10;
}
.gradientstudio__section-head {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 1.55rem;
}
.gradientstudio__section-head h3 {
  margin: 0;
  color: #ffffff;
  font-size: 0.92rem;
}
.gradientstudio__icon {
  display: grid;
  width: 1.45rem;
  height: 1.45rem;
  place-items: center;
  border-radius: 0.35rem;
  background: rgba(124, 58, 237, 0.28);
  color: #e4ddff;
  font-size: 0.72rem;
  font-weight: 900;
}
.gradientstudio__section-head code,
.gradientstudio__count {
  margin-left: auto;
  color: #9691a1;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.7rem;
}
.gradientstudio__preview-shell {
  margin-top: 0.9rem;
  padding: 0.62rem;
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 0.82rem;
  background:
    linear-gradient(135deg, rgba(124, 58, 237, 0.1), transparent),
    #11121a;
}
.gradientstudio__preview {
  display: flex;
  align-items: flex-end;
  min-height: 18rem;
  padding: 1rem;
  box-sizing: border-box;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: 0.58rem;
  background: linear-gradient(135deg, #6D28D9 0%, #A855F7 48%, #22D3EE 100%);
}
.gradientstudio__preview-label {
  display: grid;
  gap: 0.2rem;
  width: 100%;
  padding: 0.7rem 0.78rem;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 0.55rem;
  background: rgba(8, 9, 13, 0.68);
  color: #ffffff;
}
.gradientstudio__preview-label span {
  color: #e3def0;
  font-size: 0.68rem;
  font-weight: 700;
}
.gradientstudio__preview-label strong {
  font-size: 0.95rem;
}
.gradientstudio__rail-section {
  margin-top: 0.76rem;
  padding: 0.72rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 0.68rem;
  background: #0d0e16;
}
.gradientstudio__mini-head,
.gradientstudio__presets-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.7rem;
}
.gradientstudio__mini-head {
  color: #c6c1d2;
  font-size: 0.69rem;
  font-weight: 850;
}
.gradientstudio__mini-head small {
  color: #898496;
  font-size: 0.64rem;
  font-weight: 600;
}
.gradientstudio__stop-rail {
  position: relative;
  height: 1rem;
  margin-top: 1.15rem;
  border: 1px solid rgba(255, 255, 255, 0.19);
  border-radius: 999px;
  background: linear-gradient(135deg, #6D28D9 0%, #A855F7 48%, #22D3EE 100%);
}
.gradientstudio__rail-stop {
  position: absolute;
  top: 50%;
  width: 1.15rem;
  height: 1.15rem;
  padding: 0;
  border: 2px solid #ffffff;
  border-radius: 50%;
  box-shadow: 0 0.2rem 0.65rem rgba(0, 0, 0, 0.36);
  cursor: grab;
  transform: translate(-50%, -50%);
  touch-action: none;
}
.gradientstudio__rail-stop:active {
  cursor: grabbing;
}
.gradientstudio__output {
  margin-top: 0.8rem;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 0.68rem;
  background: #0d0e16;
}
.gradientstudio__output-head {
  display: grid;
  grid-template-columns: 1fr auto auto;
  align-items: center;
  gap: 0.5rem;
  padding: 0.55rem 0.7rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.gradientstudio__output-head h4 {
  margin: 0;
  color: #aaa5b7;
  font-size: 0.68rem;
  font-weight: 850;
  text-transform: uppercase;
}
.gradientstudio__output-head select {
  min-height: 1.75rem;
  max-width: 8rem;
  padding: 0.16rem 0.3rem;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 0.35rem;
  background: #151621;
  color: #d9d5e4;
  font: inherit;
  font-size: 0.62rem;
}
.gradientstudio__output-head button,
.gradientstudio__presets-head button {
  padding: 0.16rem 0.4rem;
  border: 1px solid rgba(139, 92, 246, 0.48);
  border-radius: 0.35rem;
  background: rgba(124, 58, 237, 0.14);
  color: #e0d9ff;
  cursor: pointer;
  font: inherit;
  font-size: 0.62rem;
  font-weight: 800;
}
.gradientstudio__output pre {
  overflow-x: auto;
  margin: 0;
  padding: 0.8rem;
  white-space: pre-wrap;
}
.gradientstudio__output code {
  color: #f4f2fb;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.74rem;
  line-height: 1.5;
}
.gradientstudio__message {
  margin: 0.72rem 0 0;
  color: #a7a2b3;
  font-size: 0.75rem;
}
.gradientstudio__message[data-tone="success"] {
  color: #a7f3d0;
}
.gradientstudio__message[data-tone="error"] {
  color: #fda4af;
}
.gradientstudio__settings-grid,
.gradientstudio__custom-origin {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.7rem;
  margin-top: 0.9rem;
}
.gradientstudio__custom-origin {
  margin-top: 0.7rem;
}
.gradientstudio__custom-origin[hidden] {
  display: none;
}
.gradientstudio__field {
  display: grid;
  gap: 0.38rem;
  color: #bbb6c7;
  font-size: 0.74rem;
  font-weight: 800;
}
.gradientstudio__field span {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.gradientstudio__field b {
  color: #e2dcff;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.72rem;
}
.gradientstudio__field select {
  min-height: 2.42rem;
  padding: 0.5rem 0.65rem;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 0.6rem;
  outline: 0;
  background: #12131c;
  color: #ffffff;
  font: inherit;
  font-size: 0.78rem;
}
.gradientstudio__field input[type="range"] {
  width: 100%;
  min-height: 2.42rem;
  accent-color: #8b5cf6;
  cursor: pointer;
}
.gradientstudio__field[data-disabled="true"] {
  opacity: 0.42;
}
.gradientstudio__field select:disabled,
.gradientstudio__field input:disabled {
  cursor: not-allowed;
}
.gradientstudio__stops-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  margin-top: 1.1rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.09);
}
.gradientstudio__stops-header h4,
.gradientstudio__presets-head h4 {
  margin: 0;
  color: #f4f2fb;
  font-size: 0.84rem;
}
.gradientstudio__stops-header p {
  margin: 0.22rem 0 0;
  color: #898496;
  font-size: 0.68rem;
  line-height: 1.4;
}
.gradientstudio__stops {
  display: grid;
  gap: 0.58rem;
  margin-top: 0.72rem;
}
.gradientstudio__stop {
  display: grid;
  grid-template-columns: 2.45rem minmax(5.7rem, 0.7fr) minmax(7rem, 1fr) minmax(7rem, 1fr) 1.8rem;
  align-items: end;
  gap: 0.5rem;
  padding: 0.58rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 0.64rem;
  background: #0e0f17;
}
.gradientstudio__stop-picker {
  width: 2.45rem;
  height: 2.38rem;
  padding: 0.18rem;
  border: 1px solid rgba(255, 255, 255, 0.17);
  border-radius: 0.52rem;
  background: #12131c;
  cursor: pointer;
}
.gradientstudio__stop-picker::-webkit-color-swatch-wrapper {
  padding: 0;
}
.gradientstudio__stop-picker::-webkit-color-swatch {
  border: 0;
  border-radius: 0.32rem;
}
.gradientstudio__stop label {
  display: grid;
  gap: 0.32rem;
  color: #a9a4b5;
  font-size: 0.65rem;
  font-weight: 800;
}
.gradientstudio__stop label span {
  display: flex;
  justify-content: space-between;
}
.gradientstudio__stop label b {
  color: #d9d3e8;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.63rem;
}
.gradientstudio__stop-hex {
  box-sizing: border-box;
  width: 100%;
  min-height: 2.38rem;
  padding: 0.46rem 0.54rem;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 0.52rem;
  outline: 0;
  background: #12131c;
  color: #ffffff;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.72rem;
}
.gradientstudio__stop-position,
.gradientstudio__stop-alpha {
  width: 100%;
  min-height: 2.38rem;
  accent-color: #8b5cf6;
  cursor: pointer;
}
.gradientstudio__remove-stop {
  width: 1.8rem;
  height: 2.38rem;
  padding: 0;
  border: 1px solid rgba(251, 113, 133, 0.34);
  border-radius: 0.5rem;
  background: rgba(244, 63, 94, 0.08);
  color: #fda4af;
  cursor: pointer;
  font-size: 1.1rem;
}
.gradientstudio__remove-stop:disabled {
  opacity: 0.32;
  cursor: not-allowed;
}
.gradientstudio__presets,
.gradientstudio__favorites {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.09);
}
.gradientstudio__presets-head span {
  color: #898496;
  font-size: 0.68rem;
}
.gradientstudio__preset-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.5rem;
  margin-top: 0.68rem;
}
.gradientstudio__preset {
  display: grid;
  gap: 0.35rem;
  padding: 0.43rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 0.58rem;
  background: #10111a;
  color: #bbb6c7;
  cursor: pointer;
  font: inherit;
  font-size: 0.66rem;
  text-align: left;
}
.gradientstudio__preset i {
  display: block;
  min-height: 1.55rem;
  border-radius: 0.34rem;
}
.gradientstudio__preset.is-active {
  border-color: rgba(139, 92, 246, 0.72);
  box-shadow: 0 0 0 1px rgba(139, 92, 246, 0.15);
  color: #f5f2ff;
}
.gradientstudio__favorites-list {
  display: grid;
  gap: 0.48rem;
  margin-top: 0.68rem;
}
.gradientstudio__favorites-list > p {
  margin: 0;
  color: #898496;
  font-size: 0.72rem;
}
.gradientstudio__favorite {
  display: grid;
  grid-template-columns: 3.4rem 1fr 1.75rem;
  align-items: center;
  gap: 0.55rem;
  padding: 0.45rem;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 0.55rem;
  background: #0e0f17;
}
.gradientstudio__favorite-preview {
  min-height: 2rem;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 0.36rem;
  cursor: pointer;
}
.gradientstudio__favorite strong,
.gradientstudio__favorite span {
  display: block;
}
.gradientstudio__favorite strong {
  overflow: hidden;
  color: #e9e6f2;
  font-size: 0.7rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.gradientstudio__favorite span {
  margin-top: 0.14rem;
  color: #8f8a9b;
  font-size: 0.62rem;
}
.gradientstudio__favorite-delete {
  width: 1.75rem;
  height: 1.9rem;
  padding: 0;
  border: 1px solid rgba(251, 113, 133, 0.34);
  border-radius: 0.42rem;
  background: rgba(244, 63, 94, 0.08);
  color: #fda4af;
  cursor: pointer;
  font-size: 1rem;
}
.gradientstudio__footer {
  align-items: center;
  padding: 0.85rem 1.35rem;
  border-top: 1px solid rgba(255, 255, 255, 0.09);
  background: #0b0c13;
  color: #9691a1;
  font-size: 0.72rem;
}
@media (max-width: 1040px) {
  .gradientstudio__workspace {
    grid-template-columns: 1fr;
  }
  .gradientstudio__preview-panel {
    border-right: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.09);
  }
  .gradientstudio__stop {
    grid-template-columns: 2.45rem minmax(6rem, 0.8fr) 1fr 1fr 1.8rem;
  }
}
@media (max-width: 620px) {
  .gradientstudio__header,
  .gradientstudio__toolbar,
  .gradientstudio__footer {
    flex-direction: column;
    align-items: stretch;
    padding: 1rem;
  }
  .gradientstudio__toolbar-group {
    width: 100%;
  }
  .gradientstudio__toolbar .btn {
    flex: 1 1 auto;
  }
  .gradientstudio__preview-panel,
  .gradientstudio__controls-panel {
    padding: 1rem;
  }
  .gradientstudio__settings-grid,
  .gradientstudio__custom-origin {
    grid-template-columns: 1fr;
  }
  .gradientstudio__stop {
    grid-template-columns: 2.45rem 1fr 1.8rem;
  }
  .gradientstudio__stop label {
    grid-column: 1 / -1;
  }
  .gradientstudio__preset-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .gradientstudio__output-head {
    grid-template-columns: 1fr auto;
  }
  .gradientstudio__output-head select {
    grid-column: 1 / 2;
  }
  .gradientstudio__output-head button {
    grid-column: 2 / 3;
    grid-row: 1 / 3;
  }
}