/* Domex Engineer Training – styled to match Domex documents (red / grey, Domex logo).
   Large touch targets for the Family Hub screen; works in portrait and landscape. */
@font-face { font-family: "Quicksand"; font-weight: 500; font-style: normal;
  src: url("../fonts/quicksand-latin-500-normal.woff2") format("woff2"), url("../fonts/quicksand-latin-500-normal.woff") format("woff"); }
@font-face { font-family: "Quicksand"; font-weight: 700; font-style: normal;
  src: url("../fonts/quicksand-latin-700-normal.woff2") format("woff2"), url("../fonts/quicksand-latin-700-normal.woff") format("woff"); }

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; min-height: 100%; overscroll-behavior: none; }
html:-webkit-full-screen, html:fullscreen { background: #fff; overflow-y: auto; }
body {
  font-family: "Quicksand", "SamsungOne", Arial, sans-serif; font-weight: 500;
  color: #4e5459; background: #fff; font-size: 23px; line-height: 1.38;
  -webkit-user-select: none; user-select: none;
  padding-left: 18px;   /* room for the red bar */
  /* Domex ring watermark */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 600 600'%3E%3Cpath d='M300 40a260 260 0 1 1-184 76' fill='none' stroke='%23f1f1f1' stroke-width='120'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right -220px bottom -220px; background-size: 760px 760px;
  background-attachment: fixed;
}
.hidden { display: none !important; }
.muted { color: #858b90; }
b { font-weight: 700; }

#redbar { position: fixed; left: 0; top: 0; bottom: 0; width: 18px; background: #be2a2a; z-index: 5; }

/* Header – like the Domex letterhead: logo, red divider, grey text */
#topbar { display: -webkit-flex; display: flex; -webkit-align-items: center; align-items: center;
  padding: 18px 28px; background: #fff; border-bottom: 1px solid #e6e6e6; }
#logo { height: 70px; width: auto; display: block; }
#headInfo { -webkit-flex: 1; flex: 1; margin-left: 28px; padding-left: 24px; border-left: 4px solid #be2a2a; min-height: 62px; }
#headTitle { color: #be2a2a; font-weight: 700; font-size: 26px; }
#progress { color: #4e5459; font-size: 21px; }

main { max-width: 1000px; margin: 0 auto; padding: 22px 28px 60px; }
h1 { font-size: 40px; margin: 10px 0 6px; color: #be2a2a; font-weight: 700; }
h2 { font-size: 29px; margin: 18px 0 16px; color: #3f4448; font-weight: 700; }

/* Buttons */
button {
  font: inherit; font-weight: 700; font-size: 25px; border: 2px solid #be2a2a; background: #be2a2a; color: #fff;
  border-radius: 12px; padding: 16px 24px; margin: 8px 0; width: 100%; min-height: 74px; cursor: pointer;
}
button:active { background: #9d2020; }
button.ghost { background: #fff; color: #4e5459; border-color: #c9ccce; }
button.ghost:active { background: #f1f1f1; }
button.small { width: auto; min-height: 0; padding: 10px 18px; font-size: 19px; margin: 0; }
button[disabled] { opacity: 0.45; }

.notice { background: #fff; border: 1px solid #e3e3e3; border-left: 8px solid #4e5459; border-radius: 10px;
  padding: 14px 18px; margin: 14px 0; font-size: 21px; }
.notice.ok { border-left-color: #2e8540; }
.notice.warn { border-left-color: #e0a100; }
.errmsg { color: #be2a2a; min-height: 30px; margin: 8px 0; font-weight: 700; }

/* Set-up cards with tick boxes */
.card { background: #fff; border: 1px solid #dcdcdc; border-radius: 14px; padding: 16px 20px; margin: 16px 0; }
.card.on { border-color: #be2a2a; box-shadow: 0 0 0 2px #be2a2a inset; }
.cardHead { display: -webkit-flex; display: flex; -webkit-align-items: center; align-items: center; margin-bottom: 6px; }
.cardTitle { -webkit-flex: 1; flex: 1; font-size: 28px; font-weight: 700; color: #3f4448; }
.cardCount { font-size: 19px; color: #858b90; }
.rowLabel { font-size: 18px; color: #858b90; margin: 10px 0 4px; text-transform: uppercase; letter-spacing: 1px; }
.chips { overflow: hidden; }
.chip { float: left; width: auto; min-height: 0; margin: 6px 10px 6px 0; padding: 12px 18px 12px 52px; position: relative;
  font-size: 21px; background: #fff; color: #4e5459; border: 2px solid #c9ccce; border-radius: 30px; }
.chip:before { content: ""; position: absolute; left: 14px; top: 50%; margin-top: -13px; width: 26px; height: 26px;
  border: 2px solid #9aa0a5; border-radius: 6px; background: #fff; }
.chip.on { border-color: #be2a2a; background: #fbeaea; color: #8e1b1b; }
.chip.on:before { background: #be2a2a; border-color: #be2a2a; }
.chip.on:after { content: ""; position: absolute; left: 23px; top: 50%; margin-top: -9px; width: 7px; height: 14px;
  border: solid #fff; border-width: 0 4px 4px 0; -webkit-transform: rotate(45deg); transform: rotate(45deg); }
.chip.radio:before { border-radius: 50%; }
.chip.radio.on:after { left: 21px; margin-top: -5px; width: 10px; height: 10px; border: 0; background: #fff; border-radius: 50%; -webkit-transform: none; transform: none; }
.chip.empty { color: #b0b4b8; }
.soon { font-size: 19px; color: #858b90; margin-top: 6px; }
.summary { margin: 18px 0 6px; font-size: 23px; color: #3f4448; }
.summary b { color: #be2a2a; }

/* Trainee name */
input[type=text] { font: inherit; font-size: 30px; width: 100%; padding: 18px 20px; border: 2px solid #4e5459;
  border-radius: 12px; background: #fff; color: #3f4448; -webkit-user-select: text; user-select: text; }
input[type=text]:focus { outline: none; border-color: #be2a2a; }

/* PIN */
.pindots { font-size: 48px; letter-spacing: 16px; min-height: 64px; text-align: center; color: #be2a2a; }
.pinpad { overflow: hidden; max-width: 480px; margin: 0 auto; }
.pinpad button { float: left; width: 31.3%; margin: 1%; font-size: 34px; min-height: 92px; background: #fff; color: #3f4448; border-color: #c9ccce; }
.pinpad button.primary { background: #be2a2a; color: #fff; border-color: #be2a2a; }

/* Question */
.tagrow { margin-top: 4px; }
.tag { display: inline-block; background: #f1f1f1; color: #4e5459; border-radius: 8px; padding: 4px 12px; font-size: 18px; font-weight: 700; margin-right: 8px; }
.tag.level { background: #fbeaea; color: #be2a2a; }
.answers button { text-align: left; position: relative; padding-left: 80px; background: #fff; color: #3f4448; border-color: #c9ccce; font-weight: 500; }
.answers .letter { position: absolute; left: 18px; top: 50%; margin-top: -22px; width: 44px; height: 44px;
  line-height: 44px; text-align: center; border-radius: 50%; background: #be2a2a; color: #fff; font-weight: 700; }
.answers button.correct { background: #e7f4ea; border-color: #2e8540; color: #1d5a2a; }
.answers button.correct .letter { background: #2e8540; }
.answers button.wrong { background: #f3f3f3; border-color: #4e5459; color: #4e5459; text-decoration: line-through; }
.answers button.wrong .letter { background: #4e5459; }
.answers button[disabled] { opacity: 1; cursor: default; }
.answers.pics { overflow: hidden; }
.answers.pics button { float: left; width: 48.5%; margin: 0 3% 3% 0; padding: 10px; text-align: center; min-height: 0; text-decoration: none; }
.answers.pics button:nth-child(2n) { margin-right: 0; }
.answers.pics button img { display: block; width: 100%; height: auto; border-radius: 6px; }
.answers.pics .letter { left: 12px; top: 12px; margin-top: 0; z-index: 2; }
.answers.pics button.correct, .answers.pics button.wrong { border-width: 6px; padding: 6px; }

.imgwrap { position: relative; margin: 12px auto; max-width: 100%; display: table; }
.imgwrap img { display: block; max-width: 100%; max-height: 58vh; border-radius: 10px; background: #fff; border: 1px solid #ececec; }
.hotspots { position: absolute; left: 0; top: 0; right: 0; bottom: 0; }
.hs { position: absolute; border: 3px solid transparent; border-radius: 8px; }
.hs.show.correct { border-color: #2e8540; background: rgba(46,133,64,0.18); }
.hs.show.picked.wrong { border-color: #4e5459; background: rgba(78,84,89,0.18); }
.hs .lbl { position: absolute; left: 0; top: 100%; margin-top: 4px; background: #3f4448; color: #fff;
  font-size: 16px; padding: 2px 8px; border-radius: 6px; white-space: nowrap; display: none; z-index: 3; }
.hs.show .lbl { display: block; }
.tapmark { position: absolute; width: 30px; height: 30px; margin: -15px 0 0 -15px; border-radius: 50%;
  border: 4px solid #4e5459; background: rgba(255,255,255,0.7); pointer-events: none; }
.tapmark.ok { border-color: #2e8540; }

.feedback { border-radius: 12px; padding: 16px 22px; margin: 14px 0; font-size: 23px; font-weight: 700; }
.feedback.ok { background: #e7f4ea; color: #1d5a2a; }
.feedback.bad { background: #fbeaea; color: #8e1b1b; }
.feedback .expl { color: #3f4448; margin-top: 8px; font-size: 21px; font-weight: 500; }
.calcbtn { width: auto; min-height: 0; padding: 10px 20px 10px 54px; position: relative; font-size: 20px; }
.calcbtn:before { content: "="; position: absolute; left: 16px; top: 50%; margin-top: -14px; width: 28px; height: 28px;
  line-height: 26px; text-align: center; border-radius: 6px; background: #4e5459; color: #fff; font-size: 20px; }

/* Results */
.resname { font-size: 30px; font-weight: 700; margin-top: 8px; color: #3f4448; }
.score { font-size: 84px; font-weight: 700; color: #be2a2a; line-height: 1.1; }
.review .item { background: #fff; border: 1px solid #e3e3e3; border-left: 8px solid #be2a2a; border-radius: 10px;
  padding: 12px 18px; margin: 10px 0; font-size: 20px; }
.review .item .ans { color: #1d5a2a; margin-top: 6px; font-weight: 700; }

/* Calculator */
.calc { position: fixed; right: 24px; bottom: 24px; width: 420px; max-width: 92%; background: #fff; border-radius: 16px;
  box-shadow: 0 8px 30px rgba(0,0,0,0.25); border-top: 8px solid #be2a2a; padding: 14px 16px 16px; z-index: 20; }
.calcHead { display: -webkit-flex; display: flex; -webkit-align-items: center; align-items: center; font-weight: 700; color: #3f4448; }
.calcHead span { -webkit-flex: 1; flex: 1; font-size: 22px; }
.calcHead button { color: #4e5459; border-color: #c9ccce; background: #fff; }
.calcDisplay { margin: 10px 0; padding: 12px 14px; background: #f3f3f3; border-radius: 10px; text-align: right;
  font-size: 36px; font-weight: 700; color: #3f4448; min-height: 64px; word-wrap: break-word; }
.calcKeys { overflow: hidden; }
.calcKeys button { float: left; width: 23.5%; margin: 0 2% 2% 0; min-height: 66px; padding: 0; font-size: 28px;
  background: #fff; color: #3f4448; border-color: #c9ccce; }
.calcKeys button:nth-child(4n) { margin-right: 0; }
.calcKeys button.op { background: #f1f1f1; }
.calcKeys button.eq { background: #be2a2a; color: #fff; border-color: #be2a2a; }
