:root {
  --bg: #f6f7ff;
  --surface: #ffffff;
  --surface-soft: #f8f6ff;
  --line: #ddd7ef;
  --text: #212529;
  --muted: #5d6472;
  --accent: #7a36fb;
  --accent-strong: #6129cd;
  --accent-soft: rgba(122, 54, 251, 0.12);
  --focus: #f5c542;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(1000px 520px at -10% -10%, rgba(112, 44, 249, 0.2), transparent 70%),
    radial-gradient(900px 450px at 110% 0%, rgba(255, 228, 132, 0.24), transparent 60%),
    radial-gradient(850px 500px at 100% 100%, rgba(122, 54, 251, 0.14), transparent 72%),
    var(--bg);
  color: var(--text);
  font-family: Roboto, system-ui, -apple-system, "Segoe UI", sans-serif;
  line-height: 1.45;
}

.container {
  max-width: 820px;
  margin: 54px auto;
  padding: 32px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: 0 18px 45px rgba(63, 47, 120, 0.12);
  position: relative;
  overflow: hidden;
}

.container::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 6px;
  background: linear-gradient(90deg, #7a36fb, #a15dff 55%, #f5c542);
}

h1 {
  margin: 10px 0 8px;
  font-size: clamp(1.85rem, 2.3vw, 2.5rem);
  line-height: 1.2;
}

h2 {
  margin: 24px 0 12px;
  font-family: "Bitter", Georgia, serif;
  font-size: 1.2rem;
}

p,
label,
legend {
  color: var(--text);
}

a {
  color: var(--accent-strong);
}

a:hover {
  color: var(--accent);
}

.muted {
  color: var(--muted);
}

fieldset {
  margin: 20px 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: linear-gradient(180deg, #ffffff, var(--surface-soft));
}

legend {
  font-weight: 700;
  padding: 0 8px;
}

.scale {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  margin-top: 10px;
}

.scale label {
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: center;
  text-align: center;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 11px 8px;
  font-size: 0.9rem;
  background: #ffffff;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.scale label:hover {
  border-color: rgba(122, 54, 251, 0.46);
  box-shadow: 0 8px 20px rgba(122, 54, 251, 0.12);
  transform: translateY(-1px);
}

input[type="radio"] {
  transform: scale(1.15);
  accent-color: var(--accent);
}

input[type="text"],
input[type="url"],
textarea {
  width: 100%;
  padding: 11px;
  margin-top: 6px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #ffffff;
  font: inherit;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

input[type="text"]:focus,
input[type="url"]:focus,
textarea:focus {
  outline: 0;
  border-color: rgba(122, 54, 251, 0.55);
  box-shadow: 0 0 0 4px var(--accent-soft);
}

textarea {
  min-height: 120px;
  resize: vertical;
}

button {
  border: 0;
  border-radius: 12px;
  padding: 12px 18px;
  font: inherit;
  font-weight: 700;
  color: #ffffff;
  background: linear-gradient(180deg, #7a36fb, #6129cd);
  box-shadow: 0 10px 22px rgba(97, 41, 205, 0.3);
  cursor: pointer;
  transition: transform 0.18s ease, filter 0.18s ease;
}

button:hover,
button:focus-visible {
  filter: brightness(1.03);
  transform: translateY(-1px);
}

button:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}

.link-list {
  padding-left: 18px;
}

.link-list li {
  margin: 8px 0;
}

@media (max-width: 700px) {
  .container {
    margin: 20px 12px;
    padding: 20px;
  }

  .scale {
    grid-template-columns: 1fr;
  }

  .scale label {
    align-items: flex-start;
    text-align: left;
    flex-direction: row;
    justify-content: flex-start;
    padding: 12px;
  }
}
