/* Milliy sertifikat — «Ball qanday hisoblanadi» sahifasi.
   Faqat shu sahifaga xos uslublar; umumiy qobiq cert_hub.css da.
   Ranglar faqat tokenlardan (dark mode o'zi ishlaydi). */

.mth-card-formula { display: flex; flex-direction: column; gap: .75rem; }
.mth-card-label {
    font-size: .72rem; font-weight: 800; letter-spacing: .08em;
    color: var(--text-3); text-transform: uppercase;
}
.mth-formula-big {
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: 1.05rem; font-weight: 700; line-height: 1.5; color: var(--text);
    background: var(--bg); border: 1px solid var(--border);
    border-radius: 12px; padding: .85rem .9rem;
}
.mth-legend { list-style: none; margin: 0; padding: 0; display: grid; gap: .35rem; }
.mth-legend li { font-size: .88rem; color: var(--text-2); }
.mth-legend b { color: var(--text); font-family: ui-monospace, monospace; margin-right: .25rem; }

.mth-para { font-size: 1rem; line-height: 1.75; color: var(--text-2); max-width: 68ch; margin: 0 0 .9rem; }
.mth-para b { color: var(--text); }
.mth-h3 { font-size: 1.15rem; font-weight: 800; color: var(--text); margin: 1.75rem 0 .75rem; }

.mth-formula {
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: 1rem; font-weight: 700; color: var(--text);
    background: var(--surface-2, var(--bg)); border: 1px solid var(--border);
    border-left: 3px solid var(--brand, var(--primary));
    border-radius: 12px; padding: .9rem 1.1rem; margin: .25rem 0 1.25rem;
    overflow-x: auto; white-space: nowrap;
}

/* Topshiriq turlari */
.mth-types { display: grid; gap: .75rem; margin: 1.25rem 0; }
.mth-type {
    display: flex; gap: .9rem; align-items: flex-start;
    background: var(--surface); border: 1px solid var(--border);
    border-radius: 14px; padding: .9rem 1rem;
}
.mth-type-code {
    flex: 0 0 auto; min-width: 48px; text-align: center;
    font-weight: 800; font-size: .82rem; color: var(--text);
    background: var(--bg); border: 1px solid var(--border);
    border-radius: 999px; padding: .3rem .6rem;
}
.mth-type-name { font-weight: 800; color: var(--text); margin-bottom: .2rem; }
.mth-type p { margin: 0; font-size: .9rem; line-height: 1.6; color: var(--text-2); }

.mth-notes { margin: 1rem 0 0; padding-left: 1.1rem; }
.mth-notes li { font-size: .9rem; color: var(--text-3); line-height: 1.7; }

/* Misol bloki */
.mth-example {
    background: var(--surface); border: 1px solid var(--border);
    border-radius: 16px; padding: 1.25rem; margin-top: 1rem;
}
.mth-example-title { font-weight: 800; color: var(--text); margin-bottom: .35rem; }
.mth-example > p { font-size: .95rem; color: var(--text-2); margin-bottom: 1rem; }
.mth-compare { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .85rem; }
.mth-compare-item { background: var(--bg); border: 1px solid var(--border); border-radius: 12px; padding: .9rem; }
.mth-compare-who { font-weight: 800; color: var(--text); font-size: .92rem; margin-bottom: .3rem; }
.mth-compare-what { font-size: .88rem; color: var(--text-2); line-height: 1.6; margin-bottom: .5rem; }
.mth-compare-res { font-size: .86rem; color: var(--text-3); line-height: 1.55; border-top: 1px dashed var(--border); padding-top: .5rem; }
.mth-example-note { margin: 1rem 0 0; font-size: .9rem; color: var(--text-2); line-height: 1.7; }

/* T-shkala chizig'i */
.mth-scale { margin: 1.25rem 0 1.75rem; padding: 0 .5rem; }
.mth-scale-bar {
    position: relative; height: 8px; border-radius: 999px;
    background: linear-gradient(90deg, var(--border), var(--brand, var(--primary)));
    margin: 2.5rem 0 3rem;
}
.mth-scale-mark { position: absolute; top: -2px; transform: translateX(-50%); text-align: center; }
.mth-scale-mark::before {
    content: ''; display: block; width: 12px; height: 12px; border-radius: 50%;
    background: var(--surface); border: 3px solid var(--brand, var(--primary)); margin: 0 auto;
}
.mth-scale-mark b { display: block; margin-top: .4rem; font-size: .9rem; color: var(--text); }
.mth-scale-mark i { display: block; font-size: .75rem; color: var(--text-3); font-style: normal; }
.mth-scale-mark.mth-mid::before { width: 16px; height: 16px; margin-top: -2px; }

/* TestMakon bloklari */
.mth-blocks { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1rem; margin-top: 1.25rem; }
.mth-block { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 1.2rem; }
.mth-block-icon { font-size: 1.6rem; line-height: 1; margin-bottom: .6rem; }
.mth-block h3 { font-size: 1.02rem; font-weight: 800; color: var(--text); margin: 0 0 .5rem; line-height: 1.4; }
.mth-block p { font-size: .92rem; line-height: 1.7; color: var(--text-2); margin: 0 0 .75rem; }
.mth-block p b { color: var(--text); }
.mth-block-ex {
    font-size: .86rem; line-height: 1.65; color: var(--text-3);
    background: var(--bg); border-radius: 10px; padding: .7rem .8rem;
}

/* Halollik */
.mth-honest { display: grid; gap: .85rem; margin-top: 1rem; }
.mth-honest-item {
    background: var(--surface); border: 1px solid var(--border);
    border-left: 3px solid var(--warning, var(--accent, var(--border)));
    border-radius: 14px; padding: 1rem 1.15rem;
}
.mth-honest-title { font-weight: 800; color: var(--text); margin-bottom: .35rem; }
.mth-honest-item p { margin: 0; font-size: .92rem; line-height: 1.7; color: var(--text-2); }

/* Qadamlar */
.mth-steps { counter-reset: mth; list-style: none; margin: 1rem 0 0; padding: 0; display: grid; gap: .85rem; }
.mth-steps li {
    counter-increment: mth; position: relative; padding-left: 3rem;
    background: var(--surface); border: 1px solid var(--border);
    border-radius: 14px; padding-top: 1rem; padding-bottom: 1rem; padding-right: 1rem;
}
.mth-steps li::before {
    content: counter(mth); position: absolute; left: 1rem; top: 1rem;
    width: 26px; height: 26px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: .8rem; font-weight: 800;
    color: var(--on-brand, #fff); background: var(--brand, var(--primary));
}
.mth-step-title { font-weight: 800; color: var(--text); margin-bottom: .25rem; }
.mth-steps p { margin: 0; font-size: .9rem; line-height: 1.65; color: var(--text-2); }

.mth-cta { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1.5rem; }
.mth-faq { display: grid; gap: .6rem; }

/* ── Urinishlar tarixi ── */
.mth-hist-top { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: .85rem; margin-bottom: 1.25rem; }
.mth-stat { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 1rem; }
.mth-stat-v { font-size: 1.7rem; font-weight: 900; color: var(--text); line-height: 1.1; }
.mth-stat-l { font-size: .8rem; color: var(--text-3); margin-top: .25rem; }
.mth-trend { display: flex; align-items: flex-end; gap: 6px; height: 64px; margin-top: .5rem; }
.mth-trend span { flex: 1; min-width: 6px; background: var(--brand, var(--primary)); border-radius: 4px 4px 0 0; opacity: .85; }
.mth-empty { text-align: center; padding: 2.5rem 1rem; color: var(--text-3); }

/* ── Mobil ── */
@media (max-width: 720px) {
    .mth-compare { grid-template-columns: 1fr; }
    .mth-formula, .mth-formula-big { font-size: .88rem; white-space: normal; }
    .mth-para { font-size: .96rem; }
    .mth-cta .ms-btn-p, .mth-cta .ms-btn-g { width: 100%; text-align: center; }
    .mth-type { flex-direction: column; gap: .5rem; }
    .mth-scale-bar { margin: 2.25rem 0 2.75rem; }
}
