/* Promzapad — боковая панель справа, amber / stone */
.quiz-root {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: stretch;
  justify-content: flex-end;
  padding: 0;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity .25s ease, visibility .25s ease;
  font-family: "Golos Text", "Segoe UI", sans-serif;
  color: #1c2124;
}

.quiz-root.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.quiz-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(20, 24, 27, .58);
}

.quiz-panel {
  position: relative;
  z-index: 1;
  width: min(480px, 100%);
  max-height: 100svh;
  height: 100%;
  overflow: auto;
  background: #f3f0ea;
  border: 0;
  border-left: 1px solid #cfc6b8;
  border-radius: 0;
  box-shadow: -24px 0 60px rgba(0, 0, 0, .22);
  padding: 32px 28px 28px;
  transform: translateX(28px);
  transition: transform .3s cubic-bezier(.22, .8, .28, 1);
}

.quiz-root.is-open .quiz-panel {
  transform: none;
}

.quiz-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 44px;
  height: 44px;
  border: 1px solid #cfc6b8;
  border-radius: 0;
  background: #e5e1d8;
  color: #1c2124;
  font-size: 24px;
  cursor: pointer;
  line-height: 1;
}

.quiz-close:hover {
  border-color: #e29a32;
  color: #e29a32;
}

.quiz-progress {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 48px 26px 0;
}

.quiz-progress i {
  width: 10px;
  height: 10px;
  border-radius: 0;
  flex: 0 0 auto;
  background: #cfc6b8;
  transform: rotate(45deg);
}

.quiz-progress i.on {
  background: #e29a32;
}

.quiz-kicker {
  margin: 0 0 10px;
  font-size: 12px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: #5c656b;
  font-weight: 600;
}

.quiz-title {
  margin: 0 0 10px;
  font-family: Prata, Georgia, serif;
  font-weight: 400;
  font-size: clamp(1.85rem, 3.8vw, 2.35rem);
  line-height: 1.05;
  color: #14181b;
  padding-right: 36px;
}

.quiz-sub {
  margin: 0 0 24px;
  color: #5c656b;
  font-size: .98rem;
  line-height: 1.45;
  max-width: 34ch;
}

.quiz-options {
  display: grid;
  gap: 0;
}

.quiz-option {
  appearance: none;
  width: 100%;
  text-align: left;
  border: 0;
  border-top: 1px solid #cfc6b8;
  background: transparent;
  color: #1c2124;
  border-radius: 0;
  padding: 16px 4px 16px 18px;
  font: inherit;
  font-weight: 600;
  font-size: 1.02rem;
  cursor: pointer;
  position: relative;
  transition: color .15s, padding-left .15s, background .15s;
}

.quiz-option:last-child {
  border-bottom: 1px solid #cfc6b8;
}

.quiz-option::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: transparent;
}

.quiz-option:hover {
  color: #14181b;
  background: rgba(226, 154, 50, .08);
}

.quiz-option.is-selected {
  color: #14181b;
  background: rgba(226, 154, 50, .14);
  padding-left: 22px;
}

.quiz-option.is-selected::before {
  background: #e29a32;
}

.quiz-fields {
  display: grid;
  gap: 16px;
}

.quiz-field label {
  display: block;
  margin-bottom: 8px;
  font-size: .78rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  font-weight: 700;
  color: #5c656b;
}

.quiz-field input {
  width: 100%;
  height: 52px;
  border: 0;
  border-bottom: 1.5px solid #cfc6b8;
  border-radius: 0;
  padding: 0 2px;
  font: inherit;
  font-size: 1.05rem;
  outline: none;
  background: transparent;
  color: #1c2124;
}

.quiz-field input:focus {
  border-bottom-color: #e29a32;
}

.quiz-messengers {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.quiz-messenger {
  appearance: none;
  border: 1px solid #cfc6b8;
  background: #e5e1d8;
  border-radius: 0;
  min-height: 48px;
  font: inherit;
  font-weight: 650;
  letter-spacing: .04em;
  text-transform: uppercase;
  font-size: .82rem;
  cursor: pointer;
  color: #1c2124;
}

.quiz-messenger.is-selected {
  border-color: #e29a32;
  background: #e29a32;
  color: #14181b;
}

.quiz-nav {
  display: flex;
  gap: 12px;
  margin-top: 22px;
}

.quiz-nav-back .quiz-btn-ghost {
  width: 100%;
}

.quiz-btn {
  appearance: none;
  border: 0;
  border-radius: 0;
  min-height: 54px;
  padding: 0 22px;
  font: inherit;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  font-size: .82rem;
  cursor: pointer;
}

.quiz-btn-ghost {
  background: transparent;
  color: #1c2124;
  border: 1px solid #cfc6b8;
}

.quiz-btn-primary {
  flex: 1;
  background: #e29a32;
  color: #14181b;
}

.quiz-btn-primary:disabled {
  opacity: .4;
  cursor: not-allowed;
}

.quiz-note {
  margin: 16px 0 0;
  font-size: 12px;
  color: #5c656b;
  text-align: left;
  line-height: 1.45;
}

.quiz-note a {
  color: #1c2124;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.quiz-step { display: none; }
.quiz-step.is-active { display: block; }

@media (max-width: 640px) {
  .quiz-panel {
    width: 100%;
    padding: 24px 18px 20px;
  }
}
