/* Quiz builder. Sits on top of site.css + content.css. */

.gatebar {
  margin: 22px 0 0;
  padding: 14px 18px;
  border: 1px solid var(--line);
  border-left: 3px solid var(--lime);
  border-radius: 10px;
  background: var(--card2, #1b1b26);
  font-size: 16px;
}
.gatebar strong { color: #fff; }

.titlelab { display: block; margin: 8px 0 6px; font-weight: 700; font-size: 14px; }
.muted { color: var(--dim); font-weight: 400; }
.small { font-size: 14px; }
.titleinput {
  width: 100%; padding: 13px 15px; font: 500 17px/1.3 'Space Grotesk', sans-serif;
  color: #fff; background: var(--card2, #1b1b26);
  border: 1px solid var(--line); border-radius: 10px; margin-bottom: 26px;
}
.titleinput:focus { outline: 2px solid var(--lime); outline-offset: 1px; }

.qrow {
  background: var(--card, #14141c); border: 1px solid var(--line);
  border-radius: 14px; padding: 20px 22px; margin: 14px 0;
}
.qrow-head { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.qnum {
  font-family: Anton, sans-serif; font-size: 26px; line-height: 1;
  color: var(--lime); min-width: 28px;
}
.qrow-head .spacer { flex: 1; }
.finalepill {
  font: 700 10px/1 'Space Grotesk', sans-serif; letter-spacing: .14em; text-transform: uppercase;
  color: var(--black, #0b0b10); background: var(--lime); padding: 6px 10px; border-radius: 100px;
}
.qdel {
  background: none; border: 1px solid var(--line); color: var(--dim);
  border-radius: 100px; padding: 6px 12px; font: 500 13px 'Space Grotesk', sans-serif; cursor: pointer;
}
.qdel:hover:not(:disabled) { color: var(--pink); border-color: var(--pink); }
.qdel:disabled { opacity: .35; cursor: not-allowed; }

.qrow label { display: block; font-weight: 700; font-size: 13px; margin: 14px 0 6px; }
.qrow textarea, .qrow input[type=text] {
  width: 100%; padding: 11px 14px; font: 400 16px/1.45 'Space Grotesk', sans-serif;
  color: #fff; background: #0f0f16; border: 1px solid var(--line); border-radius: 9px;
}
.qrow textarea { min-height: 62px; resize: vertical; }
.qrow textarea:focus, .qrow input:focus { outline: 2px solid var(--lime); outline-offset: 1px; }
.cnt { display: block; text-align: right; font-size: 12px; color: var(--dim); margin-top: 4px; }
.cnt.over { color: var(--pink); font-weight: 700; }

.ansrow { margin-bottom: 10px; }
.ansfield { display: block; }
.ansline { display: flex; gap: 8px; align-items: center; }
.ansline input { flex: 1; }
.ansnote { display: block; font-size: 13px; margin-top: 5px; color: var(--dim); }
.ansnote:empty { display: none; }
.ansnote.ok { color: var(--lime); }
.ansnote.tip { color: #ffb020; }
.ansnote.bad { color: var(--pink); font-weight: 700; }
.ansdel {
  background: none; border: 1px solid var(--line); color: var(--dim); border-radius: 8px;
  width: 34px; height: 34px; cursor: pointer; flex: none; font-size: 15px;
}
.ansdel:hover { color: var(--pink); border-color: var(--pink); }
.addans {
  background: none; border: 1px dashed var(--line); color: var(--lime);
  border-radius: 9px; padding: 8px 14px; font: 500 13px 'Space Grotesk', sans-serif; cursor: pointer;
}
.addans:disabled { opacity: .4; cursor: not-allowed; color: var(--dim); }

.rowactions { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; margin: 18px 0 8px; }
.savenote { font-size: 13px; color: var(--dim); }
.savenote.warn { color: var(--pink); }

.rulecard {
  background: var(--card, #14141c); border: 1px solid var(--line);
  border-left: 3px solid var(--pink); border-radius: 12px; padding: 20px 24px; margin: 26px 0;
}
.rulecard h3 { margin: 0 0 8px; font-size: 17px; }
.rulecard p { margin: 10px 0; font-size: 15.5px; }

.mainactions { display: flex; gap: 12px; flex-wrap: wrap; margin: 26px 0 10px; }
.mainactions .btn.disabled { opacity: .4; pointer-events: none; }

/* --- the free three question taste ------------------------------------- */
.tastestage {
  position: fixed; inset: 0; z-index: 90; background: rgba(6, 6, 10, .94);
  display: flex; align-items: center; justify-content: center; padding: 22px;
}
/* The `hidden` attribute only works via the UA stylesheet's display:none, which
   the rule above would otherwise beat, leaving a full-screen black sheet over
   the page. Attribute selector wins on specificity, so this stays closed. */
.tastestage[hidden] { display: none; }
.tastebox {
  width: min(560px, 100%); background: var(--card, #14141c);
  border: 1px solid var(--line); border-radius: 18px; padding: 26px 26px 30px; text-align: center;
}
.tastetop { display: flex; justify-content: space-between; font-size: 13px; color: var(--dim); margin-bottom: 14px; }
.tastetop b { color: var(--lime); }
.tasteq { font: 400 clamp(21px, 4vw, 27px)/1.25 Anton, sans-serif; margin: 10px 0 20px; color: #fff; }
.tastebar { height: 8px; background: #0f0f16; border-radius: 100px; overflow: hidden; margin-bottom: 6px; }
.tastefill { height: 100%; background: var(--lime); width: 100%; }
.tastefill.low { background: var(--pink); }
.tastenum { font-family: Anton, sans-serif; font-size: 22px; color: var(--dim); margin-bottom: 16px; }
.tasteinput {
  width: 100%; padding: 14px 16px; font: 500 18px 'Space Grotesk', sans-serif; text-align: center;
  color: #fff; background: #0f0f16; border: 2px solid var(--line); border-radius: 11px;
}
.tasteinput:focus { outline: none; border-color: var(--lime); }
.tastefb { min-height: 44px; margin-top: 14px; }
.tastechip {
  display: inline-block; font: 700 14px 'Space Grotesk', sans-serif; padding: 9px 15px; border-radius: 100px;
}
.tastechip.good { background: var(--lime); color: var(--black, #0b0b10); }
.tastechip.bad { background: var(--pink); color: #fff; }
.tasteclose {
  position: absolute; top: 18px; right: 22px; background: none; border: 0;
  color: var(--dim); font-size: 26px; cursor: pointer; line-height: 1;
}
@media (prefers-reduced-motion: reduce) { .tastefill { transition: none !important; } }
