/* Тест на расстройство личности в новом виде (redesign, ветка Дизайн 27.09.2026). Работает вместе с rd.css и rd-rasstroystvo.js */

.rd #pdt-test { font-family: var(--f-ui); color: var(--ink); }
.rd #pdt-test p { display: block; font-size: inherit; opacity: 1; margin: 0; }
.rd #pdt-test .pdt-screen { width: 100%; }
.rd #pdt-test .rd-label { display: block; font: 500 11px/1.3 var(--f-mono); letter-spacing: .06em; text-transform: uppercase; color: var(--mute); }
.rd #pdt-test .rdp-icon { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }

/* кнопки теста: у .button на сайте font-size 0, возвращаем текст */
.rd #pdt-test .button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; font: 500 15px/1 var(--f-ui); border-radius: 999px; padding: 16px 24px; border: 1px solid var(--line); background: transparent; color: var(--ink); text-decoration: none; cursor: pointer; transition: opacity .15s, background .15s; }
.rd #pdt-test .button:hover { opacity: .85; color: var(--ink); }
.rd #pdt-test .button.black { background: var(--ink); border-color: var(--ink); color: #fff; }
.rd #pdt-test .button.black:hover { color: #fff; }

/* ===== интро ===== */
.rd #pdt-test .pdt-lead { font: 400 17px/1.6 var(--f-text); margin: 0 0 24px; max-width: 760px; }
.rd #pdt-test .pdt-facts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; list-style: none; padding: 0; margin: 0 0 24px; }
.rd #pdt-test .pdt-facts li { background: var(--tile); border-radius: 20px; padding: 20px 16px; margin: 0; }
.rd #pdt-test .pdt-facts li::before { display: none; }
.rd #pdt-test .pdt-facts b { display: block; font: 700 32px/1 var(--f-ui); letter-spacing: -1px; }
.rd #pdt-test .pdt-facts span { display: block; font: 400 13px/1.3 var(--f-ui); color: var(--mute); margin-top: 8px; }
.rd #pdt-test .pdt-resume { display: flex; align-items: center; justify-content: space-between; gap: 16px; background: var(--accent-soft); border-radius: 20px; padding: 16px 20px; margin: 0 0 24px; }
.rd #pdt-test .pdt-resume p { font-size: 15px; }
.rd #pdt-test .pdt-start-wrap { margin: 0 0 16px; }
.rd #pdt-test #pdt-start { width: 100%; height: 60px; font-size: 17px; }
.rd #pdt-test .pdt-disclaimer { font: 400 13px/1.5 var(--f-ui); color: var(--mute); }

/* ===== экран вопроса ===== */
.rd #pdt-test #pdt-test-screen { flex-direction: column; gap: 24px; }
.rd #pdt-test #pdt-test-screen:not([style*="none"]) { display: flex; }
.rd #pdt-test .pdt-topbar, .rd #pdt-test .pdt-scale-hint { display: none; }
.rd #pdt-test .rdq-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.rd #pdt-test .rdq-pill { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 999px; background: var(--tile); font: 600 12px/1.2 var(--f-mono); letter-spacing: .04em; text-transform: uppercase; transition: background .2s; }
.rd #pdt-test .rdq-pill b { font-weight: 600; }
.rd #pdt-test .rdq-pill span { color: var(--mute); font-weight: 500; }
.rd #pdt-test .rdq-pill.is-flash { background: var(--bad-soft); }
.rd #pdt-test .rdq-status { display: inline-flex; align-items: center; gap: 6px; font: 400 13px/1.3 var(--f-ui); color: var(--mute); }
.rd #pdt-test .pdt-progress { height: 8px; border-radius: 4px; background: var(--line); overflow: hidden; margin-top: -8px; }
.rd #pdt-test .pdt-progress__fill { height: 100%; background: var(--ink); border-radius: 4px; transition: width .25s; }

.rd #pdt-test .pdt-qtext { font: 600 30px/1.3 var(--f-ui); letter-spacing: -.5px; }
.rd #pdt-test .rdq-hint { margin-top: -14px; font: 400 15px/1.5 var(--f-ui); color: var(--mute); }
.rd #pdt-test .pdt-options { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; background: var(--tile); border-radius: 20px; padding: 28px 24px; }
.rd #pdt-test .pdt-opt { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; width: 100%; box-sizing: border-box; padding: 16px 20px; background: #fff; border: 1.5px solid var(--line); border-radius: 14px; color: var(--ink); text-align: left; cursor: pointer; transition: border-color .15s, background .15s; }
.rd #pdt-test .pdt-opt:hover { border-color: var(--accent-mid); }
.rd #pdt-test .pdt-opt__lb { font: 600 18px/1.25 var(--f-ui); }
.rd #pdt-test .pdt-opt__hn { font: 400 13px/1.3 var(--f-ui); color: var(--mute); }
.rd #pdt-test .pdt-opt.is-sel { background: var(--ink); border-color: var(--ink); color: #fff; }
.rd #pdt-test .pdt-opt.is-sel .pdt-opt__hn { color: #fff; opacity: .8; }

.rd #pdt-test .pdt-nav { display: flex; align-items: center; gap: 16px; }
.rd #pdt-test .pdt-nav .button { padding: 12px 22px; }
.rd #pdt-test #pdt-next { padding: 13px 24px; font-weight: 600; }
.rd #pdt-test .rdq-chosen { margin-left: auto; font: 400 13px/1.3 var(--f-ui); color: var(--mute); text-align: right; }
.rd #pdt-test .rdq-foot { font: 400 13px/1.5 var(--f-ui); color: var(--mute); }

/* ===== результат ===== */
.rd #pdt-test .rdr { display: flex; flex-direction: column; gap: 24px; }
.rd #pdt-test .rdr-box { background: var(--tile); border-radius: 20px; padding: 28px; display: flex; flex-direction: column; gap: 20px; }
.rd #pdt-test .rdr-sum__hd { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.rd #pdt-test .rdr-meta { display: inline-flex; align-items: center; gap: 6px; font: 400 13px/1.3 var(--f-ui); color: var(--mute); }
.rd #pdt-test .rdr-title { margin: 0; font: 700 34px/1.2 var(--f-mono); letter-spacing: -.5px; }
.rd #pdt-test .rdr-text { font: 500 22px/1.4 var(--f-ui); }
.rd #pdt-test .rdr-badges { display: flex; flex-wrap: wrap; gap: 8px; }
.rd #pdt-test .rdr-badge { display: inline-flex; align-items: center; padding: 6px 14px; border-radius: 999px; border: 1px solid var(--line); font: 600 13px/1.3 var(--f-ui); }
.rd #pdt-test .rdr-badge--ink { background: var(--ink); border-color: var(--ink); color: #fff; }

.rd #pdt-test .rdr-h3 { margin: 0; font: 600 20px/1.3 var(--f-ui); letter-spacing: -.2px; }
.rd #pdt-test .rdr-note { margin-top: -12px; font: 400 15px/1.5 var(--f-ui); color: var(--mute); }
.rd #pdt-test .rdr-rows { display: flex; flex-direction: column; gap: 18px; }
.rd #pdt-test .rdr-row { display: flex; flex-direction: column; gap: 8px; }
.rd #pdt-test .rdr-row__hd { display: flex; justify-content: space-between; gap: 12px; font: 500 15px/1.3 var(--f-ui); }
.rd #pdt-test .rdr-row__val { flex: none; font-size: 13px; color: var(--mute); }
.rd #pdt-test .rdr-track { height: 12px; border-radius: 6px; background: var(--card); overflow: hidden; }
.rd #pdt-test .rdr-track i { display: block; height: 100%; border-radius: 6px; background: var(--ink); }
.rd #pdt-test .rdr-track i.is-accent { background: var(--accent); }
.rd #pdt-test .rdr-row__band { font: 400 14px/1.3 var(--f-ui); color: var(--mute); }
.rd #pdt-test .rdr-row__band b { font-weight: 600; color: var(--ink); }
.rd #pdt-test .rdr-row__lead { font: 400 14px/1.5 var(--f-text); }

.rd #pdt-test .rdr-desc { font: 400 16px/1.55 var(--f-text); }
.rd #pdt-test .rdr-feat { background: var(--card); border-radius: 16px; padding: 16px 18px; }
.rd #pdt-test .rdr-feat__hd { display: flex; align-items: center; gap: 8px; font: 600 15px/1.3 var(--f-ui); margin-bottom: 10px; }
.rd #pdt-test .rdr-feat ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 6px; }
.rd #pdt-test .rdr-feat li { margin: 0; padding: 0; font: 400 14px/1.45 var(--f-text); }
.rd #pdt-test .rdr-feat li::before { content: "— "; display: inline; position: static; width: auto; height: auto; background: none; }
.rd #pdt-test .rdr-facts { display: grid; grid-template-columns: 190px 1fr; gap: 12px 20px; margin: 0; }
.rd #pdt-test .rdr-facts dt { margin: 3px 0 0; }
.rd #pdt-test .rdr-facts dd { margin: 0; font: 400 15px/1.5 var(--f-text); }

.rd #pdt-test .rdr-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.rd #pdt-test .rdr-actions .button { padding: 14px 24px; font-size: 14px; }
.rd #pdt-test .rdr-actions .rdr-link { background: var(--tile); border-color: var(--tile); }
.rd #pdt-test .rdr-foot { margin: -8px 0 0; font: 400 12px/1.5 var(--f-ui); color: var(--mute); }

/* таблицы статьи */
.rd .pdt-tbl2 .pdt-muted { font-size: 12px; color: var(--mute); font-weight: 400; }
.rd .pdt-txt-good { color: var(--good); }
.rd .pdt-txt-neutral { color: var(--mute); }
.rd .pdt-txt-warn { color: #B7791F; }
.rd .pdt-txt-bad { color: var(--bad); }

@media (max-width: 639px) {
    .rd #pdt-test .pdt-facts { grid-template-columns: 1fr 1fr; }
    .rd #pdt-test .pdt-resume { flex-direction: column; align-items: stretch; }
    .rd #pdt-test #pdt-test-screen { gap: 20px; }
    .rd #pdt-test .rdq-time { display: none; }
    .rd #pdt-test .pdt-qtext { font-size: 22px; }
    .rd #pdt-test .rdq-hint { margin-top: -10px; font-size: 14px; }
    .rd #pdt-test .pdt-options { grid-template-columns: 1fr; padding: 18px; }
    .rd #pdt-test .rdq-chosen { display: none; }
    .rd #pdt-test .pdt-nav { justify-content: space-between; }
    .rd #pdt-test #pdt-next { margin-left: auto; }
    .rd #pdt-test .rdr { gap: 16px; }
    .rd #pdt-test .rdr-box { padding: 18px; gap: 16px; }
    .rd #pdt-test .rdr-sum__hd { flex-direction: column; align-items: flex-start; gap: 6px; }
    .rd #pdt-test .rdr-title { font-size: 24px; }
    .rd #pdt-test .rdr-text { font-size: 18px; }
    .rd #pdt-test .rdr-badges { flex-direction: column; align-items: flex-start; }
    .rd #pdt-test .rdr-facts { grid-template-columns: 1fr; gap: 4px; }
    .rd #pdt-test .rdr-facts dd { margin-bottom: 10px; }
    .rd #pdt-test .rdr-actions { flex-direction: column; }
    .rd #pdt-test .rdr-actions .button { width: 100%; }
}
