/* =====================================================================
   Tajwid dan pasangkan hukum
   Gaya game tajwid dan halaman materi tajwid.
   ===================================================================== */

/* ===== TAJWID ===== */

.tj {
  color: #C2410C;
  display: inline;
  unicode-bidi: normal;
}

.taj-big {
  font-size: clamp(2.2rem,10vw,3.5rem);
  line-height: 1.9;
  color: var(--night);
  text-align: center;
}

.taj-sub {
  font-size: 1.5rem;
  line-height: 1.8;
  color: var(--mint-d);
  text-align: center;
}

.taj-opt {
  font-size: 1.45rem;
  line-height: 1.9;
  color: var(--night);
}

.taj-let {
  font-size: 1.35rem;
  line-height: 1.9;
  letter-spacing: .12em;
  color: var(--night);
}

#stage .taj-big {
  font-size: clamp(2rem,9vw,3.1rem);
  line-height: 1.8;
}

#stage .taj-opt {
  font-size: 1.3rem;
  line-height: 1.8;
}

.opt .taj-opt {
  display: block;
  text-align: center;
}

.pairs {
  display: grid;
  grid-template-columns: minmax(0,1fr) minmax(0,1fr);
  gap: 10px 14px;
  align-items: stretch;
  width: 100%;
}

.pcol {
  display: grid;
  gap: 8px;
  align-content: center;
}

.pbtn {
  min-height: 56px;
  padding: 8px 10px;
  border-radius: 16px;
  border: 3px solid #B8DCCB;
  border-bottom-width: 6px;
  background: #E8F4EE;
  font-family: var(--f-body,inherit);
  font-weight: 800;
  font-size: .95rem;
  color: var(--ink);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  line-height: 1.35;
  cursor: pointer;
  min-width: 0;
}

.pbtn.name {
  background: #FFF8E1;
  border-color: #EBD58C;
}

.pbtn:active {
  transform: translateY(3px);
  border-bottom-width: 3px;
}

.pbtn.sel {
  border-color: var(--sun);
  background: #FFF0BF;
  transform: translateY(2px);
  box-shadow: 0 0 0 4px rgba(232,182,58,.3);
}

.pbtn.done {
  background: var(--ok-bg);
  border-color: var(--ok);
  color: #0B5C40;
  opacity: .8;
}

.pbtn.shake {
  animation: shake .4s;
  border-color: var(--bad);
  background: var(--bad-bg);
}

.tajrow .meta {
  display: flex;
  justify-content: space-between;
  gap: 8px;
}

/* materi */

.tajpage {
  max-width: 1100px;
  margin-inline: auto;
}

.tajintro {
  display: grid;
  grid-template-columns: repeat(auto-fit,minmax(260px,1fr));
  gap: 14px;
  margin: 12px 0;
}

.tajintro>div {
  display: grid;
  gap: 4px;
  font-weight: 600;
  color: #3E5A57;
}

.tajintro b {
  color: var(--night);
  font-family: var(--f-disp);
}

.taj-table {
  display: grid;
  gap: 8px;
  margin: 12px 0 16px;
}

.taj-table .trow {
  display: grid;
  grid-template-columns: minmax(120px,1fr) minmax(0,1.4fr) minmax(0,1.3fr);
  gap: 10px;
  align-items: center;
  padding: 10px 14px;
  border-radius: 16px;
  background: #fff;
  border: 3px solid var(--line);
  border-left: 8px solid var(--tc);
}

.taj-table .trow b {
  font-family: var(--f-disp);
  color: var(--night);
}

.taj-table .trow .ar {
  font-size: 1.25rem;
  line-height: 1.8;
  text-align: center;
  letter-spacing: .1em;
}

.taj-table .trow small {
  font-weight: 700;
  color: var(--muted);
}

@media(max-width:560px) {
  .taj-table .trow {
    grid-template-columns: 1fr;
    gap: 2px;
  }
  .taj-table .trow .ar {
    text-align: left;
    direction: rtl;
  }
}

.tajgrid {
  display: grid;
  grid-template-columns: repeat(auto-fill,minmax(320px,1fr));
  gap: 14px;
  align-items: stretch;
}

.tajcard {
  background: #fff;
  border: 3px solid var(--line);
  border-top: 8px solid var(--tc);
  border-radius: 20px;
  padding: 14px;
  display: grid;
  gap: 8px;
  align-content: start;
}

.tajcard header {
  display: flex;
  align-items: center;
  gap: 10px;
}

.tajcard header .tag {
  margin-left: auto;
  text-align: center;
}

.tajno {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--tc);
  color: #fff;
  display: grid;
  place-items: center;
  font-family: var(--f-disp);
  font-weight: 800;
  flex: none;
}

.tajname h3 {
  font-size: 1.15rem;
  color: var(--night);
  margin: 0;
}

.tajname .ar {
  font-size: 1.1rem;
  line-height: 1.7;
  color: var(--muted);
}

.tajhuruf {
  display: grid;
  gap: 2px;
  justify-items: center;
  padding: 8px;
  border-radius: 14px;
  background: #F4FAF6;
  border: 2px dashed var(--line);
  text-align: center;
}

.tajhuruf .ar {
  font-size: 1.6rem;
  line-height: 1.8;
  letter-spacing: .16em;
  color: var(--night);
}

.tajhuruf small,
.tajex small {
  font-weight: 700;
  color: var(--muted);
}

.tajcard p {
  margin: 0;
  font-weight: 600;
  color: #3E5A57;
  font-size: .93rem;
}

.tajex {
  display: grid;
  gap: 6px;
}

.tajex .ex {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 4px 10px;
  border-radius: 12px;
  background: #FFFBEA;
  border: 2px solid #F0E2A8;
}

.tajnote {
  margin-top: 14px;
  display: grid;
  gap: 6px;
  background: #FFFBEA;
  border-color: #EBD58C;
}

.tajnote p {
  margin: 0;
  font-weight: 600;
  color: #3E5A57;
}

/* penyempurnaan tampilan game tajwid */

.pcol {
  align-content: stretch;
  grid-auto-rows: 1fr;
}

.taj-let {
  font-size: 1.1rem;
  line-height: 1.6;
  letter-spacing: .06em;
}

.gh-c h2 {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

@media(max-width:440px) {
  #g-fs {
    display: none;
  }
}

@media(orientation:landscape) and (max-height:520px) {
  .pbtn {
    min-height: 40px;
    padding: 3px 8px;
    border-bottom-width: 4px;
    font-size: .88rem;
  }
  .pcol {
    gap: 5px;
  }
  .pairs {
    gap: 5px 12px;
  }
  .phint {
    display: none;
  }
  .taj-opt {
    font-size: 1.2rem;
    line-height: 1.6;
  }
}
