/* TheoryPrac Persian guide pages (/fa/guide/...) */
.tpg{
  --g-ink:#18213a; --g-soft:#4b5468; --g-navy:#1b2c52; --g-mark:#f2c200; --g-line:#dfe2e6;
  --g-ok:#1f8a4c; --g-bad:#c62f2b;
  max-width:760px; margin:0 auto; padding:16px 18px 56px;
  color:var(--g-ink); font-size:17px; line-height:1.95; text-align:right;
}
.tpg *{box-sizing:border-box}
.tpg a{color:var(--g-navy)}
.tpg :focus-visible{outline:3px solid var(--g-mark); outline-offset:2px; border-radius:4px}

.tpg-crumbs{font-size:14px; color:var(--g-soft); margin:0 0 22px}
.tpg-crumbs a{color:var(--g-soft); text-decoration:none}
.tpg-crumbs a:hover{text-decoration:underline}
.tpg-crumbs span{margin:0 6px; opacity:.5}

.tpg h1{font-size:clamp(27px,5.6vw,38px); line-height:1.4; font-weight:800; margin:0 0 16px; color:var(--g-ink)}
.tpg h2{font-size:22px; line-height:1.5; font-weight:800; margin:48px 0 10px; color:var(--g-ink)}
.tpg h3{font-size:18px; font-weight:700; margin:22px 0 4px; color:var(--g-ink)}
.tpg p{margin:0 0 14px}

.tpg-answer{font-size:19px; line-height:1.9; border-right:5px solid var(--g-mark); padding:2px 16px 2px 0; margin:0 0 8px}
.tpg-meta{font-size:14px; color:var(--g-soft); margin:0 0 26px}

.tpg .tpsd{margin:0 0 8px}

.tpg-tw{overflow-x:auto; margin:6px 0 8px}
.tpg-table{border-collapse:collapse; width:100%; font-size:16px; background:#fff}
.tpg-table th,.tpg-table td{padding:10px 12px; text-align:right; border-bottom:1px solid var(--g-line)}
.tpg-table thead th{font-weight:700; background:#eef0f3; font-size:15px}
.tpg-table tbody th{font-weight:700}
.tpg-table .tot{font-weight:800}
.tpg-table th,.tpg-table td{white-space:nowrap}
.tpg-table small{display:block; font-weight:400; font-size:13px; line-height:1.4; color:var(--g-soft)}
.tpg-table tr:last-child th,.tpg-table tr:last-child td{border-bottom:0}
.tpg-vocab td[dir="ltr"]{text-align:left; font-weight:700; white-space:nowrap}

.tpg-box{background:#fff; border:1px solid var(--g-line); border-radius:12px; padding:14px 18px; margin:12px 0}
.tpg-box p:last-child{margin:0}
.tpg-en{unicode-bidi:isolate}
.tpg-traps{padding-right:20px}
.tpg-traps li{margin-bottom:12px}
.tpg-traps strong{display:block}

.tpg-q{background:#fff; border:1px solid var(--g-line); border-radius:14px; padding:16px 18px; margin:0 0 14px}
.tpg-q-en{font-weight:700; text-align:left; margin:0 0 4px; line-height:1.6}
.tpg-q-fa{color:var(--g-soft); margin:0 0 10px}
.tpg-q-img{display:block; max-width:220px; height:auto; margin:6px 0 12px}
.tpg-opts{display:grid; gap:8px}
.tpg-opt{
  display:flex; flex-direction:column; align-items:flex-start; gap:2px; width:100%;
  font:inherit; text-align:left; direction:ltr; color:var(--g-ink); background:#f7f8fa;
  border:2px solid var(--g-line); border-radius:10px; padding:9px 14px; cursor:pointer;
}
.tpg-opt small{align-self:flex-end; color:var(--g-soft); font-size:14px}
.tpg-opt:hover{border-color:#b9c0cc}
.tpg-q.done .tpg-opt{cursor:default}
.tpg-opt.ok{border-color:var(--g-ok); background:#eaf6ef}
.tpg-opt.bad{border-color:var(--g-bad); background:#fbecec}
.tpg-expl{margin-top:12px; padding-top:10px; border-top:1px dashed var(--g-line); font-size:16px}
.tpg-expl p{margin:0}

.tpg-faq{border-bottom:1px solid var(--g-line); padding:12px 0}
.tpg-faq summary{font-weight:700; cursor:pointer; list-style:none}
.tpg-faq summary::-webkit-details-marker{display:none}
.tpg-faq summary::before{content:"+"; display:inline-block; width:22px; font-weight:800; color:var(--g-navy)}
.tpg-faq[open] summary::before{content:"–"}
.tpg-faq p{margin:8px 22px 0 0}

.tpg-cta{margin:48px 0 0; background:var(--g-navy); color:#fff; border-radius:16px; padding:24px 22px}
.tpg-cta h2{margin:0 0 6px; color:#fff; font-size:21px}
.tpg-cta p{color:#d6dcea; margin:0 0 16px}
.tpg-cta a{display:inline-block; background:var(--g-mark); color:#111; font-weight:800; text-decoration:none; padding:11px 24px; border-radius:10px}

.tpg-sources{font-size:14px; color:var(--g-soft); margin-top:32px}
.tpg-sources p{margin:0 0 6px}

.tpg-sec ul,.tpg-sec ol{padding-right:20px; margin:0 0 14px}
.tpg-sec li{margin-bottom:8px}
.tpg-steps{counter-reset:none}
.tpg-steps li{padding-right:4px}

.tpg-links{list-style:none; padding:0; margin:0 0 8px; display:grid; gap:8px}
.tpg-links-2{grid-template-columns:repeat(auto-fill,minmax(260px,1fr))}
.tpg-links a{display:block; background:#fff; border:1px solid var(--g-line); border-radius:10px; padding:10px 14px; text-decoration:none; font-weight:700; line-height:1.6}
.tpg-links a:hover{border-color:var(--g-navy)}

.tpg-search{display:flex; flex-direction:column; gap:4px; margin:4px 0 10px; font-size:15px; font-weight:700}
.tpg-search input{font:inherit; font-weight:400; padding:9px 12px; border:2px solid var(--g-line); border-radius:10px; max-width:360px; text-align:left}
.tpg-search input:focus{border-color:var(--g-navy); outline:none}
.tpg-centres th[dir="ltr"],.tpg-centres td[dir="ltr"]{text-align:left}
.tpg-centres th small{display:inline; font-weight:400; margin-left:6px}
.tpg-centres tr.up .tot{color:var(--g-ok)}
.tpg-centres tr.down .tot{color:var(--g-bad)}
.tpg-c-empty{color:var(--g-soft)}

@media (max-width:480px){
  .tpg{font-size:16px; padding:12px 14px 48px}
  .tpg-table th,.tpg-table td{padding:8px 6px; font-size:14px}
}
.tpg-sec .tpg-links{padding:0}
