:root {
  color-scheme: dark;
  --panel-bg: rgba(10, 12, 18, 0.82);
  --panel-border: rgba(255, 255, 255, 0.08);
  --accent: #6bc4ff;
  --accent-2: #ffb28a;
  --text: #dfe7f5;
  --muted: #7e8aa1;
  --shadow: 0 15px 45px rgba(0, 0, 0, 0.35);
  --radius: 16px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #05070c;
  font-family: "Inter", system-ui, -apple-system, Segoe UI, sans-serif;
  color: var(--text);
}

#app {
  position: relative;
  width: 100%;
  height: 100%;
}

#sky {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  background: radial-gradient(ellipse at center, #1b2b4b, #05070c 70%);
}

.panel {
  position: absolute;
  top: 16px;
  right: 16px;
  left: auto;
  transform: translateX(0);
  width: min(1120px, calc(100% - 32px));
  max-height: calc(100% - 32px);
  overflow: auto;
  background: var(--panel-bg);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius);
  padding: 16px 16px 12px;
  backdrop-filter: blur(14px) saturate(120%);
  box-shadow: var(--shadow);
  transition: opacity 0.3s ease, transform 0.4s ease;
}

.panel.hidden {
  opacity: 0;
  pointer-events: none;
  transform: translateX(110%);
}

.panel__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
}

.dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, #fff, #6bc4ff 60%, #0a4d9f);
  box-shadow: 0 0 20px rgba(107, 196, 255, 0.8);
}

.title {
  font-weight: 700;
  letter-spacing: 0.12em;
  font-size: 13px;
}

.subtitle {
  color: var(--muted);
  font-size: 12px;
}

.header-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

button,
select,
input,
textarea {
  font: inherit;
  color: var(--text);
}

button {
  padding: 8px 12px;
  border-radius: 10px;
  border: 1px solid var(--panel-border);
  background: rgba(255, 255, 255, 0.06);
  cursor: pointer;
  transition: border 0.2s ease, transform 0.15s ease, background 0.2s ease;
}

button:hover {
  border-color: rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.09);
}

button:active {
  transform: translateY(1px);
}

label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 13px;
  color: var(--muted);
}

label span {
  letter-spacing: 0.02em;
}

input[type="range"] {
  width: 100%;
  accent-color: var(--accent);
}

select,
input[type="text"] {
  width: 100%;
  padding: 8px 10px;
  border-radius: 10px;
  border: 1px solid var(--panel-border);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
}

textarea {
  width: 100%;
  min-height: 80px;
  border-radius: 12px;
  border: 1px dashed var(--panel-border);
  background: rgba(255, 255, 255, 0.02);
  padding: 10px;
  resize: vertical;
  color: var(--text);
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}

.presets {
  margin-top: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.row .grow {
  flex: 1;
}

.row input {
  flex: 1;
}

.tips {
  margin-top: 10px;
  font-size: 12px;
  color: var(--muted);
  display: grid;
  gap: 4px;
}

.conditional {
  opacity: 1;
  transition: opacity 0.2s ease;
}

.conditional.disabled {
  opacity: 0.35;
}

@media (max-width: 720px) {
  .panel {
    top: auto;
    bottom: 12px;
    left: 12px;
    right: 12px;
    width: auto;
    transform: translateY(0);
    max-height: calc(100% - 24px);
  }

  .panel.hidden {
    transform: translateY(110%);
  }

  .panel__header {
    flex-direction: column;
    align-items: flex-start;
  }

  .header-actions {
    width: 100%;
  }
}
