/* Build your AI workforce (/build-your-workforce): this game's pieces only.
 * Everything else, tokens included (--ink, --paper, --gold, --line, --green, --red, Cinzel + Inter),
 * is Agent Academy's /learn-agents/rooms.css, linked first. Values below reuse that sheet's own colours
 * (the .answer, .reward-art and .primary families) rather than adding a palette. */

/* Tap targets: the visitor is on a phone, usually inside Instagram. rooms.css sizes these for a desk. */
.byw .settings button,
.byw .map button,
.byw .text-button { min-height: 44px; }
.byw .settings button { padding: 8px 14px; }
.byw .text-button { padding: 10px 6px; font-size: 13px; }
/* The rest of the chrome a thumb can reach: rooms.css draws these at desk size. Inline links inside a
   sentence (Privacy policy, Athena's Trials) stay inline; WCAG 2.5.8 exempts them. */
.byw .brand, .byw footer a { display: inline-flex; align-items: center; min-height: 44px; min-width: 44px; justify-content: center; }
.byw .volume input { width: 72px; height: 44px; margin: 0; }
.byw .about summary { padding: 12px 0; }
.byw footer { align-items: center; padding-top: 8px; padding-bottom: 8px; }

.byw #progress { color: #dfd0e6; letter-spacing: 1px; }
.byw .map { grid-template-columns: repeat(3, 1fr); }
.byw .map button { font-size: 13px; }
.byw .map button:disabled:not(.active) { opacity: .55; }

/* The two choices */
.byw .answers-business { grid-template-columns: repeat(4, 1fr); }
.byw .answers-drain { grid-template-columns: repeat(3, 1fr); }
.byw .answer { font-size: 14px; }
.byw .answer .letter { font-family: Georgia, 'Times New Roman', serif; font-size: 14px; color: #8b6e3c; }
.byw .back { margin-top: 10px; }
.byw .question:focus { outline: none; }

/* The result */
.byw .result-title { font: 700 clamp(22px, 2.6vw, 28px)/1.25 Cinzel, Georgia, serif; margin: 10px 0 6px; }
.byw .result-lead { margin: 0 0 18px; color: #4f5b5f; font-size: 15px; }
.recruits {
  display: grid; gap: 12px;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 176px), 1fr));
}
.recruit {
  position: relative; display: flex; flex-direction: column; align-items: center; text-align: center;
  background: #fff8e8; border: 2px solid #d9c8aa; border-bottom-width: 4px; border-bottom-color: #c6b28e;
  border-radius: 12px; padding: 16px 14px 18px; min-width: 0;
}
.recruit-first { background: linear-gradient(#fff1bf, #fff8e8 55%); border-color: #c8ab68; border-bottom-color: #a68d53; }
.recruit-relic {
  width: 68px; height: 68px; flex: none; border-radius: 50%; padding: 7px;
  background: #f5e6b3; border: 2px solid #c8ab68; box-shadow: 0 0 0 6px #f5e6b344;
}
.recruit-relic svg { width: 100%; height: 100%; display: block; }
.recruit-numeral { position: absolute; top: 9px; left: 12px; font: 600 13px Cinzel, Georgia, serif; color: #a68d53; }
.recruit-copy { min-width: 0; }
.recruit-badge {
  display: inline-block; margin: 12px 0 0; padding: 3px 10px; border-radius: 20px;
  background: #354951; color: #fff5e2; font-size: 11px; font-weight: 600; letter-spacing: .3px;
}
.recruit-service { margin: 12px 0 4px; font-size: 10px; letter-spacing: 1.6px; font-weight: 700; color: #8b6e3c; text-transform: uppercase; }
.recruit-first .recruit-service { margin-top: 8px; }
.recruit-title { margin: 0 0 8px; font: 700 16px/1.3 Cinzel, Georgia, serif; color: var(--ink); overflow-wrap: anywhere; }
.recruit-body { margin: 0; font-size: 13.5px; line-height: 1.55; color: #3d4a50; }
.recruit.rising { animation: recruit-rise var(--rise, .42s) cubic-bezier(.2, .8, .2, 1) var(--delay, 0ms) backwards; }
@keyframes recruit-rise { from { opacity: 0; transform: translateY(18px) scale(.95); } }

/* The email step: the restaurant checklist's states, in this world's parchment. */
.muster-form {
  margin-top: 22px; padding: 18px 20px 16px; border-radius: 12px;
  background: #f1e9da; border: 1.5px solid #d9c8aa;
}
.muster-form h3 { font: 700 20px/1.3 Cinzel, Georgia, serif; margin: 0 0 10px; }
.byw-label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 6px; }
.byw-row { display: flex; gap: 10px; flex-wrap: wrap; }
.byw-row input {
  flex: 1 1 260px; min-width: 0; min-height: 48px; padding: 10px 14px;
  font-size: 16px; /* 16px or iOS zooms the page when the field takes focus */
  color: var(--ink); background: #fffdf7; border: 2px solid #c6b28e; border-radius: 9px;
}
.byw-row input[aria-invalid="true"] { border-color: var(--red); }
.byw-row .primary { min-height: 48px; font-size: 14px; }
.byw-row .primary:disabled { cursor: progress; opacity: .75; transform: none; }
#byw-form.is-busy .primary::before {
  content: ""; display: inline-block; vertical-align: -3px; width: 14px; height: 14px; margin-right: 8px;
  border-radius: 50%; border: 2px solid #fff8ed55; border-top-color: #fff8ed; animation: byw-spin .8s linear infinite;
}
@keyframes byw-spin { to { transform: rotate(360deg); } }
#byw-form.is-sent .byw-label, #byw-form.is-sent .byw-row { display: none; }
.byw-status { margin: 10px 0 0; font-size: 14px; font-weight: 600; line-height: 1.5; }
.byw-status:empty { margin: 0; }
.byw-status.is-error { color: var(--red); }
.byw-status.is-success { color: var(--green); }
.byw-consent { margin: 10px 0 0; font-size: 12.5px; line-height: 1.55; color: #5d686b; }
.byw-hp { position: absolute !important; left: -10000px !important; width: 1px; height: 1px; overflow: hidden; }

.result-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 16px; margin-top: 20px; }
.talk-lead { margin: 0; font-weight: 600; font-size: 15px; }
.byw .primary.talk { display: inline-flex; align-items: center; min-height: 44px; text-decoration: none; font-size: 14px; }
.byw .restart { margin-left: auto; }

.byw .relic-slot svg { pointer-events: none; }
.byw .under-game p { max-width: 760px; }

@media (max-width: 900px) {
  .byw .answers-business { grid-template-columns: repeat(2, 1fr); }
  .byw .answers-drain { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 760px) {
  .byw .settings button { font-size: 12px; padding: 8px 12px; }
  .byw .map { padding: 8px; gap: 6px; }
  .byw .map button { flex-direction: row; gap: 6px; font-size: 12px; padding: 6px 4px; }
  .byw .map button b { font-size: 11px; }
  .byw .question { font-size: 18px; }
  .byw .answer { font-size: 15px; min-height: 50px; }
  .byw .result-lead { font-size: 14.5px; }
}
@media (max-width: 560px) {
  .byw .answers-business, .byw .answers-drain { grid-template-columns: 1fr; }
  .byw .map button span { font-size: 11px; }
  /* One helper per row, relic beside the words, so each card reads at full phone width. */
  .recruit { display: grid; grid-template-columns: 56px 1fr; gap: 0 14px; align-items: start; text-align: left; padding: 14px 14px 16px; }
  .recruit-relic { width: 56px; height: 56px; padding: 6px; box-shadow: 0 0 0 4px #f5e6b344; }
  .recruit-numeral { position: static; grid-column: 1; grid-row: 2; text-align: center; margin-top: 8px; }
  .recruit-copy { grid-column: 2; grid-row: 1 / span 2; }
  .recruit-badge { margin-top: 0; }
  .recruit-service { margin-top: 0; }
  .recruit-first .recruit-service { margin-top: 8px; }
  .recruit-title { font-size: 17px; }
  .recruit-body { font-size: 15px; }
  .muster-form { padding: 16px 14px 14px; }
  .byw-row .primary { flex: 1 1 100%; }
  .byw .restart { margin-left: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .recruit.rising { animation: none; }
}
