/* Educational Tools — scoped styles, inherits the site palette */

.tools-hero { padding: 68px 0 34px; }
.tools-hero h1 { margin-bottom: 14px; }

/* ---- Folder / tool cards ---- */

.tool-grid { display: grid; gap: 20px; }
@media (min-width: 700px) { .tool-grid { grid-template-columns: repeat(2, 1fr); } }

.tool-card {
  display: flex; flex-direction: column;
  background: var(--white); border: 1px solid var(--line);
  border-radius: 18px; padding: 30px 28px 26px;
  box-shadow: 0 2px 4px rgba(19,18,16,.04), 0 8px 24px rgba(19,18,16,.05);
  transition: transform .45s cubic-bezier(.22,1,.36,1), box-shadow .45s, border-color .45s;
  position: relative; overflow: hidden;
}
.tool-card::before {
  content: ""; position: absolute; top: 0; left: 0; height: 3px; width: 0;
  background: linear-gradient(90deg, var(--gold), var(--gold-soft));
  transition: width .5s cubic-bezier(.22,1,.36,1);
}
.tool-card:hover::before { width: 100%; }
.tool-card:hover {
  transform: translateY(-4px); border-color: #ded7c6;
  box-shadow: 0 8px 16px rgba(19,18,16,.05), 0 28px 64px rgba(19,18,16,.10);
}

.tool-icon {
  width: 52px; height: 52px; border-radius: 14px; margin-bottom: 20px;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(160deg, #f8f2e2, var(--gold-faint));
  border: 1px solid #efe6cf; color: var(--gold);
}
.tool-icon svg { width: 25px; height: 25px; }

.tool-card h2, .tool-card h3 { font-size: 1.32rem; margin-bottom: 10px; }
.tool-card p { color: var(--stone); font-size: .97rem; line-height: 1.6; flex: 1; }

.tool-tag {
  align-self: flex-start; margin-top: 18px;
  font-size: .68rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase;
  color: var(--gold); background: var(--gold-faint);
  border: 1px solid #eadfc4; border-radius: 100px; padding: 6px 14px;
}
.tool-go {
  margin-top: 20px; font-size: .92rem; font-weight: 600; color: var(--ink);
  display: inline-flex; align-items: center; gap: 7px;
  border-bottom: 1px solid var(--gold); padding-bottom: 2px; align-self: flex-start;
  transition: gap .3s cubic-bezier(.22,1,.36,1), color .3s;
}
.tool-card:hover .tool-go { gap: 12px; color: var(--gold); }

/* ---- Practice screen ---- */

.m-wrap { max-width: 800px; margin: 0 auto; padding: 0 24px; }

.m-top { padding: 30px 0 22px; }
.m-back {
  font-size: .88rem; color: var(--stone); font-weight: 500;
  display: inline-flex; align-items: center; gap: 7px; margin-bottom: 18px;
}
.m-back:hover { color: var(--gold); }
.m-top h1 { font-size: clamp(1.7rem, 5vw, 2.4rem); margin-bottom: 8px; }
.m-top .m-sub { color: var(--stone); font-size: .98rem; }

.m-stats {
  display: flex; align-items: center; gap: 22px; flex-wrap: wrap;
  margin-top: 20px; padding: 16px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  font-size: .82rem; color: var(--stone);
}
.m-stats b { font-family: var(--font-display); font-size: 1.3rem; color: var(--ink); font-weight: 500; }
.m-track { flex: 1; min-width: 120px; height: 6px; background: var(--line); border-radius: 100px; overflow: hidden; }
.m-track i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--gold), var(--gold-soft)); transition: width .6s cubic-bezier(.22,1,.36,1); }
#reset { background: none; border: none; color: var(--stone); font-size: .8rem; cursor: pointer; text-decoration: underline; font-family: var(--font-body); }
#reset:hover { color: var(--gold); }

.m-card {
  background: var(--white); border: 1px solid var(--line); border-radius: 18px;
  padding: 30px 28px; margin: 26px 0 60px;
  box-shadow: 0 2px 4px rgba(19,18,16,.04), 0 8px 24px rgba(19,18,16,.05);
}
.m-meta {
  font-size: .7rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase;
  color: var(--gold); margin-bottom: 14px;
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
}
.m-marks { color: var(--stone); border-left: 1px solid var(--line); padding-left: 12px; }
.m-q { font-size: 1.3rem; line-height: 1.4; margin-bottom: 20px; }

.m-src { margin-bottom: 22px; display: grid; gap: 10px; }
.m-src img {
  width: 100%; border: 1px solid var(--line); border-radius: 10px; background: #fff;
}

.m-lab { display: block; font-size: .8rem; font-weight: 600; color: var(--ink-soft); margin-bottom: 8px; }
#ans {
  width: 100%; font-family: var(--font-body); font-size: 1rem; line-height: 1.6;
  padding: 15px 16px; border: 1px solid var(--line); border-radius: 12px;
  background: var(--paper); color: var(--ink); resize: vertical;
}
#ans:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 4px rgba(168,135,59,.13); background: #fff; }

.m-actions { display: flex; gap: 11px; flex-wrap: wrap; margin-top: 16px; }
.m-actions .btn { font-size: .93rem; padding: 13px 24px; }

.m-scheme { margin-top: 26px; padding-top: 22px; border-top: 1px solid var(--line); animation: mIn .4s cubic-bezier(.22,1,.36,1); }
@keyframes mIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

.m-sh { font-size: .84rem; font-weight: 600; letter-spacing: .05em; color: var(--gold); text-transform: uppercase; margin-bottom: 14px; }
.m-pts { list-style: none; display: grid; gap: 9px; }
.m-pts label { display: flex; gap: 11px; align-items: flex-start; cursor: pointer; font-size: .97rem; line-height: 1.55; color: var(--ink-soft); }
.m-pts input { width: 19px; height: 19px; margin-top: 2px; flex-shrink: 0; accent-color: var(--gold); }
.m-pts input:checked + span { color: var(--stone); text-decoration: line-through; text-decoration-color: var(--gold-soft); }

.m-block {
  font-size: 1rem; line-height: 1.65; color: var(--ink-soft);
  background: var(--gold-faint); border-left: 3px solid var(--gold);
  border-radius: 0 10px 10px 0; padding: 18px 20px;
}

.m-score { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; margin-top: 24px; padding-top: 18px; border-top: 1px solid var(--line); }
.m-score span { font-size: .85rem; font-weight: 600; color: var(--ink-soft); margin-right: 4px; }
.m-sc {
  width: 44px; height: 44px; border-radius: 50%; cursor: pointer;
  border: 1px solid var(--line); background: var(--white);
  font-family: var(--font-display); font-size: 1.1rem; color: var(--ink);
  transition: all .25s cubic-bezier(.22,1,.36,1);
}
.m-sc:hover { border-color: var(--gold); background: var(--gold-faint); color: var(--gold); transform: translateY(-2px); }

.m-err { color: var(--stone); padding: 30px 0; }

@media (max-width: 680px) {
  .m-card { padding: 24px 20px; }
  .m-q { font-size: 1.15rem; }
  .m-actions .btn { width: 100%; justify-content: center; }
}

/* ---- Section picker ---- */

.m-picker {
  display: flex; align-items: center; gap: 9px; flex-wrap: wrap;
  margin-top: 22px;
}
.pk-lab {
  font-size: .7rem; font-weight: 600; letter-spacing: .16em;
  text-transform: uppercase; color: var(--stone); margin-right: 4px;
}
.pk {
  font-family: var(--font-body); font-size: .88rem; font-weight: 500;
  color: var(--ink-soft); cursor: pointer;
  background: var(--white); border: 1px solid var(--line);
  border-radius: 100px; padding: 9px 16px;
  display: inline-flex; align-items: center; gap: 8px;
  transition: border-color .25s cubic-bezier(.22,1,.36,1), background .25s, color .25s, transform .25s;
}
.pk i {
  font-style: normal; font-size: .72rem; font-weight: 600;
  color: var(--stone); background: var(--paper);
  border-radius: 100px; padding: 2px 8px;
}
.pk:hover { border-color: var(--gold-soft); transform: translateY(-1px); }
.pk.on {
  background: var(--ink); border-color: var(--ink); color: var(--paper);
}
.pk.on i { background: rgba(255,255,255,.14); color: var(--gold-soft); }

@media (max-width: 680px) {
  .m-picker { gap: 7px; }
  .pk { font-size: .82rem; padding: 8px 13px; }
  .pk-lab { width: 100%; margin-bottom: 2px; }
}

/* ---- Source A extract ---- */

.m-source {
  background: var(--gold-faint);
  border: 1px solid #eadfc4;
  border-left: 3px solid var(--gold);
  border-radius: 0 12px 12px 0;
  padding: 20px 22px;
  margin-bottom: 22px;
}
.m-srch {
  font-size: .68rem; font-weight: 700; letter-spacing: .18em;
  text-transform: uppercase; color: var(--gold); margin-bottom: 10px;
}
.m-source p:last-child {
  font-size: 1rem; line-height: 1.68; color: var(--ink-soft);
  text-wrap: pretty;
}
@media (max-width: 680px) {
  .m-source { padding: 16px 18px; }
  .m-source p:last-child { font-size: .95rem; }
}

/* ---- auto-marking: the matcher's verdict on the student's answer ---- */

.m-verdict {
  font-size: .95rem;
  line-height: 1.6;
  color: var(--ink-soft);
  background: var(--gold-faint);
  border: 1px solid var(--line);
  border-left: 3px solid var(--gold);
  border-radius: 8px;
  padding: 13px 16px;
  margin-bottom: 20px;
}
.m-verdict b { color: var(--ink); font-weight: 600; }

/* checked now means "we found this", not "cross it off" */
.m-pts input:checked + span { text-decoration: none; color: var(--ink); }

.m-pts li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 9px 12px;
  border: 1px solid transparent;
  border-radius: 8px;
  transition: background .18s ease, border-color .18s ease;
}
.m-pts li.got {
  background: var(--gold-faint);
  border-color: var(--line);
}
.m-pts li label { flex: 1; }

.tick {
  font-size: .66rem;
  font-weight: 600;
  letter-spacing: .09em;
  text-transform: uppercase;
  color: var(--gold);
  font-style: normal;
  white-space: nowrap;
  margin-top: 4px;
}

.m-sc.sug {
  border-color: var(--gold);
  background: var(--gold);
  color: #fff;
  box-shadow: 0 3px 12px rgba(168, 135, 59, .28);
}
.m-sc.sug:hover { background: var(--gold); color: #fff; }

.sug-note {
  font-size: .8rem;
  font-style: normal;
  color: var(--stone);
  margin-left: 6px;
}

/* Sub-line under the topical grid: says what is coming without pretending it
   is already here, so no card links to something unfinished. */
.topical-note { margin: 22px 2px 0; font-size: .95rem; color: var(--stone);
  line-height: 1.6; max-width: 46em; }

/* The ZAINORA credit under the topical grid. Slightly stronger than the
   "coming soon" note above it, because this is the line that tells a visitor
   who built the thing they are about to open. */
.topical-note.zainora-line { margin-top: 14px; color: var(--ink, #14130f); }
.topical-note.zainora-line a { text-decoration: underline; text-underline-offset: 2px; }
