/* guides.css — the Guides screen (guides.js): a list of how-to guides, and
   one guide read in a frame so the bill behind it is kept. */

.gkg-intro { margin: 4px 0 16px; color: var(--text-secondary); }
.gkg-list { display: flex; flex-direction: column; gap: 12px; }
.gkg-card {
  display: flex; align-items: center; gap: 14px; width: 100%;
  padding: 14px 16px; text-align: left; cursor: pointer;
  background: var(--surface); color: var(--text-primary);
  border: 1px solid var(--border); border-radius: 16px;
}
.gkg-card:hover { border-color: var(--brand-border); background: var(--surface-hover); }
.gkg-card__icon {
  flex: none; display: grid; place-items: center; width: 48px; height: 48px;
  border-radius: 14px; background: var(--brand-tint); color: var(--brand-text); font-size: 1.3rem;
}
.gkg-card__text { display: flex; flex-direction: column; gap: 3px; min-width: 0; flex: 1; }
.gkg-card__text strong { font-size: 1rem; }
.gkg-card__text span { font-size: 0.86rem; color: var(--text-secondary); line-height: 1.45; }
.gkg-card__text em { font-style: normal; font-size: 0.8rem; color: var(--brand-text); font-weight: 600; }
.gkg-card__go { flex: none; color: var(--text-tertiary); }

.gkg-reader { display: flex; flex-direction: column; gap: 10px; }
.gkg-reader__bar { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.gkg-reader__bar a { text-decoration: none; }
.gkg-frame {
  display: block; width: 100%; border: 1px solid var(--border); border-radius: 16px;
  height: calc(100vh - 170px); height: calc(100dvh - 170px); min-height: 420px;
  background: #EFF6F7;
}
/* Phones: room for the bottom bar. */
@media (max-width: 768px) {
  .gkg-frame { height: calc(100dvh - 210px); }
}

/* My Stats: the way in for staff on a phone. */
.gkg-entry {
  display: flex; align-items: center; gap: 12px; width: 100%;
  padding: 12px 16px; cursor: pointer; text-align: left;
  background: var(--surface); color: var(--text-primary);
  border: 1px solid var(--border); border-radius: 16px;
}
.gkg-entry:hover { border-color: var(--brand-border); }
.gkg-entry > i:first-child { color: var(--brand-text); font-size: 1.2rem; }
.gkg-entry span { flex: 1; display: flex; flex-direction: column; }
.gkg-entry span em { font-style: normal; font-size: 0.82rem; color: var(--text-secondary); }

/* Lessons: your own status on the card, and Super Admin's Team training. */
.gkt-mine { font-weight: 600; font-size: 0.8rem; color: var(--text-secondary); }
.gkt-mine:empty { display: none; }
.gkt-mine.is-done { color: #0f8a5f; }
.gkt { margin-bottom: 14px; }
.gkt-lesson + .gkt-lesson { margin-top: 18px; }
.gkt-head { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; flex-wrap: wrap; margin-bottom: 6px; }
.gkt-head span { font-size: 0.86rem; color: var(--text-secondary); font-weight: 600; }
.gkt-table { border: 1px solid var(--border); border-radius: 14px; overflow: hidden; }
.gkt-row { display: grid; grid-template-columns: 1.6fr 0.8fr 0.6fr 1fr 1.1fr; gap: 8px; padding: 9px 12px; align-items: center; border-top: 1px solid var(--border); font-size: 0.9rem; }
.gkt-row:first-child { border-top: 0; }
.gkt-row--head { background: var(--surface-hover); font-size: 0.78rem; font-weight: 700; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 0.03em; }
.gkt-row.is-new { background: var(--brand-tint); }
.gkt-row small { display: block; font-size: 0.75rem; color: var(--text-tertiary); }
.gkt-ok { color: #0f8a5f; font-weight: 700; }
.gkt-bad { color: #c62842; font-weight: 700; }
.gkt-no { color: var(--text-tertiary); }
.gkt-new { font-style: normal; font-size: 0.7rem; font-weight: 700; color: #fff; background: var(--brand); border-radius: 999px; padding: 0 7px; }
.gkt-missed { margin: 8px 2px 0; font-size: 0.85rem; color: var(--text-secondary); }
.gkt-badge {
  display: inline-grid; place-items: center; min-width: 18px; height: 18px; padding: 0 5px;
  border-radius: 999px; background: var(--brand); color: #fff; font-size: 0.7rem; font-weight: 700; line-height: 1;
}
#menu-guides { position: relative; }
#menu-guides .gkt-badge { position: absolute; top: 4px; right: 6px; }
/* Team training is folded until opened. */
.gkt-sum { display: flex; align-items: center; gap: 10px; cursor: pointer; list-style: none; font-weight: 700; font-size: 1.05rem; }
.gkt-sum::-webkit-details-marker { display: none; }
.gkt-sum > span { flex: 1; }
.gkt-sum em { font-style: normal; font-size: 0.82rem; font-weight: 600; color: var(--text-secondary); }
.gkt-sum__go { color: var(--text-tertiary); transition: transform .2s; }
.gkt[open] .gkt-sum__go { transform: rotate(180deg); }
.gkt[open] .gkt-sum { margin-bottom: 10px; }
.gkt-see { display: block; margin-top: 4px; padding: 2px 10px; border: 1px solid var(--border); border-radius: 999px; background: var(--surface, #fff); color: var(--brand); font-size: 0.75rem; font-weight: 700; cursor: pointer; }
.gkt-answers { padding: 8px 14px 12px; border-top: 1px dashed var(--border); background: var(--surface-hover); font-size: 0.86rem; }
.gkt-answers p { margin: 0 0 6px; }
.gkt-answers ul { margin: 0; padding: 0; list-style: none; display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 3px 14px; }
.gkt-answers li { display: flex; gap: 6px; }
.gkt-answers li span { font-weight: 700; width: 1em; }
.gkt-answers .is-right span { color: #0f8a5f; }
.gkt-answers .is-wrong { color: #c62842; font-weight: 600; }
/* Phones: each person is a small card, not a five-column row. */
@media (max-width: 640px) {
  .gkt-row--head { display: none; }
  .gkt-row { grid-template-columns: 1fr 1fr; row-gap: 4px; }
  .gkt-row > span:first-child { grid-column: 1 / -1; }
  .gkt-row > span[data-l]::before { content: attr(data-l) ": "; color: var(--text-tertiary); font-size: 0.78rem; }
}

/* My books (reader/): Super Admin only, in the header and at the top of Guides. */
body:not(.gk-is-owner) .gk-owner-only { display: none !important; }
.gkg-books { display: flex; text-decoration: none; color: inherit; margin-bottom: 16px; }
