/* ============================================================
   «Sudga murojaat» — vaziyat kartalari, savollar va reja (js/org-sud-wiz.js, v113)
   org-sud.css tokenlari va kartalari ustiga: --op-*, --g2-*, body.dark — tun. Chop etish: body.osw-printing — faqat reja.
   ============================================================ */
.osw-gh { margin-top: 4px; font: 800 12px/1.3 'Inter', sans-serif; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.osw-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; }
@container osd (min-width: 640px) { .osw-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@container osd (min-width: 1040px) { .osw-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.osw-card { width: 100%; height: 100%; min-height: 72px; display: flex; align-items: center; gap: 12px; padding: 12px 12px 12px 10px; border-radius: 14px; font: inherit; text-align: left;
  cursor: pointer; color: var(--text); background: var(--op-tint); border: 1px solid transparent; transition: background-color var(--m1, .15s), border-color var(--m1, .15s); }
.osw-card:hover { background: var(--op-tint-h); border-color: rgba(47, 84, 168, .22); }
.osw-card:hover .osd-go { opacity: 1; transform: translateX(2px); }
.osw-ic { width: 40px; height: 40px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 12px; color: var(--navy); background: var(--op-card); border: 1px solid var(--op-card-b); }
.osw-ic svg { width: 20px; height: 20px; }
.osw-t { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.osw-t b { font-size: 14.5px; font-weight: 700; line-height: 1.3; color: var(--op-ink); }
.osw-t small { font-size: 12.5px; line-height: 1.4; color: var(--muted); }
.osw-resume { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 14px; text-decoration: none; color: var(--text);
  background: linear-gradient(135deg, rgba(233, 210, 138, .28), rgba(233, 210, 138, .08)); border: 1px solid rgba(201, 162, 39, .45); }
.osw-resume > svg { width: 20px; height: 20px; flex: 0 0 auto; color: #86650c; }
.osw-resume > svg:last-child { width: 16px; height: 16px; margin-left: auto; color: var(--muted); }
.osw-resume span { display: flex; flex-direction: column; gap: 1px; }
.osw-resume small { font: 800 11px/1.3 'Inter', sans-serif; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.osw-resume b { font-size: 14.5px; color: var(--op-ink); }

/* --- Savol --- */
.osw-home { display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 0 10px 0 6px; border: 0; border-radius: 10px; font: 600 13.5px 'Inter', sans-serif;
  color: var(--navy); background: transparent; cursor: pointer; }
.osw-home:hover { background: var(--op-tint-h); }
.osw-home svg { width: 16px; height: 16px; }
.osw-ask { max-width: 720px; gap: 12px; }
.osw-ask h1 { font: 800 24px/1.25 'Manrope', 'Inter', sans-serif; letter-spacing: -.01em; color: var(--op-ink); text-wrap: balance; }
.osw-hint { font-size: 14px; line-height: 1.55; color: var(--muted); max-width: 64ch; }
.osw-prog { width: 100%; height: 6px; border: 0; border-radius: 999px; overflow: hidden; appearance: none; -webkit-appearance: none; background: var(--op-tint); }
.osw-prog::-webkit-progress-bar { background: var(--op-tint); border-radius: 999px; }
.osw-prog::-webkit-progress-value { background: linear-gradient(90deg, #2f54a8, #c9a227); border-radius: 999px; }
.osw-prog::-moz-progress-bar { background: linear-gradient(90deg, #2f54a8, #c9a227); border-radius: 999px; }
.osw-opts { display: flex; flex-direction: column; gap: 8px; margin-top: 4px; }
.osw-opt { display: flex; align-items: center; gap: 12px; min-height: 56px; padding: 10px 14px; border-radius: 14px; font: 600 15px/1.35 'Inter', sans-serif; text-align: left;
  cursor: pointer; color: var(--op-ink); background: var(--op-card); border: 1px solid var(--op-card-b); transition: border-color var(--m1, .15s), background-color var(--m1, .15s); }
.osw-opt:hover { border-color: #2f54a8; }
.osw-opt[aria-pressed="true"] { border-color: #2f54a8; box-shadow: inset 3px 0 0 #c9a227; }
.osw-rad { width: 22px; height: 22px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 50%; border: 2px solid rgba(47, 84, 168, .45); color: #fff; }
.osw-opt[aria-pressed="true"] .osw-rad { background: #2f54a8; border-color: #2f54a8; }
.osw-rad svg { width: 13px; height: 13px; }
.osw-field { display: flex; flex-direction: column; gap: 8px; margin-top: 4px; }
.osw-in { width: 100%; max-width: 360px; min-height: 50px; padding: 10px 14px; border-radius: 12px; border: 1px solid var(--op-card-b); background: var(--op-card); color: var(--op-ink);
  font: 600 17px 'Inter', sans-serif; }
.osw-in:focus { outline: none; border-color: #2f54a8; box-shadow: 0 0 0 3px rgba(47, 84, 168, .18); }
.osw-err { min-height: 0; font-size: 13px; color: #b3261e; }
.osw-err:empty { display: none; }
.osw-row { display: flex; flex-wrap: wrap; gap: 8px; }
.osw-row .op-btn svg { width: 16px; height: 16px; }
.osw-nav { padding-top: 6px; border-top: 1px solid var(--op-line); }
.osw-back { display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 0 10px 0 6px; border: 0; border-radius: 10px; background: transparent;
  font: 600 13.5px 'Inter', sans-serif; color: var(--muted); cursor: pointer; }
.osw-back:hover { color: var(--op-ink); background: var(--op-tint-h); }
.osw-back svg { width: 16px; height: 16px; }

/* --- Reja --- */
.osw-plan { max-width: 980px; }
.osw-hacts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.osw-facts { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; }
@container osd (min-width: 640px) { .osw-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@container osd (min-width: 980px) { .osw-facts { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.osw-fact { display: flex; flex-direction: column; gap: 4px; padding: 14px 16px; border-radius: 16px; background: var(--g2-bg); border: var(--g2-border); box-shadow: var(--g2-hi), var(--g2-shadow); }
.osw-fact > span { font-size: 12.5px; font-weight: 600; color: var(--muted); }
.osw-fact > b { font: 800 20px/1.25 'Manrope', 'Inter', sans-serif; color: var(--op-ink); }
.osw-fact > small { font-size: 12.5px; font-weight: 700; color: #1f7a4d; }
.osw-fact[data-tone="warn"] > small { color: #9a5b00; }
.osw-fact[data-tone="bad"] { border-color: rgba(179, 38, 30, .45); }
.osw-fact[data-tone="bad"] > small { color: #b3261e; }
.osw-fact > a { margin-top: 2px; font-size: 12.5px; font-weight: 600; color: var(--navy-light, #2f54a8); }
.osw-steps { display: flex; flex-direction: column; }
.osw-st { display: flex; gap: 12px; padding: 12px 0; border-top: 1px solid var(--op-line); }
.osw-st:first-child { border-top: 0; padding-top: 2px; }
.osw-sn { width: 30px; height: 30px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 50%; font: 800 13px/1 'Inter', sans-serif; color: #142a52; background: #e9d28a; }
.osw-st.is-done .osw-sn { color: #fff; background: #1f7a4d; }
.osw-sn svg { width: 15px; height: 15px; }
.osw-st > div { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.osw-st h3 { font: 700 15.5px/1.35 'Inter', sans-serif; color: var(--op-ink); }
.osw-st p { font-size: 13.5px; line-height: 1.55; color: var(--text); }
.osw-acts { display: flex; flex-wrap: wrap; gap: 6px; }
.osw-tpl { display: inline-flex; align-items: center; gap: 8px; max-width: 100%; min-height: 36px; padding: 6px 10px; border-radius: 10px; text-decoration: none; font-size: 13px; line-height: 1.35;
  color: var(--op-ink); background: var(--op-tint); border: 1px solid transparent; }
.osw-tpl:hover { background: var(--op-tint-h); border-color: rgba(47, 84, 168, .22); }
.osw-tpl svg { width: 15px; height: 15px; flex: 0 0 auto; color: var(--navy-light, #2f54a8); }
.osw-tpl em { flex: 0 0 auto; font: 800 10.5px/1 'Inter', sans-serif; font-style: normal; letter-spacing: .04em; padding: 3px 6px; border-radius: 6px; color: #fff; background: #2b579a; }
.osw-tpl.is-ai svg { color: #86650c; }
.osw-ext { display: inline-flex; align-items: center; gap: 8px; min-height: 36px; padding: 6px 10px; border-radius: 10px; text-decoration: none; font-size: 13px; color: var(--op-ink); background: var(--op-tint); }
.osw-ext svg { width: 14px; height: 14px; color: var(--navy-light, #2f54a8); }
.osw-ext small { display: none; }
.osw-ext span { display: inline; }
.osw-more { display: inline-flex; align-items: center; gap: 4px; min-height: 36px; padding: 0 6px; font-size: 13px; font-weight: 600; text-decoration: none; color: var(--navy-light, #2f54a8); }
.osw-more svg { width: 14px; height: 14px; }
.osw-tl { display: flex; flex-direction: column; gap: 8px; counter-reset: tl; }
.osw-tl li { position: relative; padding-left: 26px; font-size: 13.5px; line-height: 1.5; color: var(--text); }
.osw-tl li::before { content: ''; position: absolute; left: 6px; top: 6px; width: 9px; height: 9px; border-radius: 50%; background: #2f54a8; box-shadow: 0 0 0 3px rgba(47, 84, 168, .15); }
.osw-ans { padding: 12px 16px; border-radius: 16px; background: var(--op-tint); }
.osw-ans summary { cursor: pointer; font-size: 14px; font-weight: 700; color: var(--op-ink); }
.osw-ans ul { display: flex; flex-direction: column; gap: 6px; margin-top: 10px; }
.osw-ans li { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 2px 12px; font-size: 13px; color: var(--muted); }
.osw-ans li b { color: var(--op-ink); }
@container osd (max-width: 560px) { .osw-ask h1 { font-size: 20px; } .osw-in { max-width: none; font-size: 16px; } .osw-fact > b { font-size: 18px; } }

body.dark .osw-ic { color: #c9d6f2; }
body.dark .osw-resume { background: linear-gradient(135deg, rgba(201, 162, 39, .18), rgba(201, 162, 39, .05)); border-color: rgba(233, 210, 138, .35); }
body.dark .osw-resume > svg:first-child, body.dark .osw-tpl.is-ai svg { color: #e9d28a; }
body.dark .osw-home, body.dark .osw-tpl svg, body.dark .osw-ext svg, body.dark .osw-more, body.dark .osw-fact > a { color: #9db9ff; }
body.dark .osw-opt[aria-pressed="true"], body.dark .osw-opt:hover, body.dark .osw-in:focus { border-color: #9db9ff; }
body.dark .osw-opt[aria-pressed="true"] .osw-rad { background: #4a6fc9; border-color: #4a6fc9; }
body.dark .osw-rad { border-color: rgba(157, 185, 255, .5); }
body.dark .osw-fact > small { color: #8fdcb4; }
body.dark .osw-fact[data-tone="warn"] > small { color: #f0c060; }
body.dark .osw-fact[data-tone="bad"] > small, body.dark .osw-err { color: #ff9b93; }
body.dark .osw-st.is-done .osw-sn { color: #0f2a1c; background: #8fdcb4; }
body.dark .osw-tl li::before { background: #9db9ff; box-shadow: 0 0 0 3px rgba(157, 185, 255, .18); }
@media (prefers-reduced-motion: reduce) { .osw-card, .osw-opt { transition: none; } }

/* --- Chop etish: reja nusxasi body ga qoʻshiladi (.osw-sheet), qolgani yashiriladi --- */
.osw-sheet { display: none; }
@media print {
  body.osw-printing > :not(.osw-sheet) { display: none !important; }
  body.osw-printing { background: #fff !important; }
  body.osw-printing .osw-sheet { display: block; color: #000; font-family: 'Inter', sans-serif; }
  .osw-sheet .osw-hacts, .osw-sheet .osw-acts, .osw-sheet .osw-fact > a, .osw-sheet .osd-exts, .osw-sheet .osd-note { display: none !important; }
  .osw-sheet .osd-card, .osw-sheet .osw-fact, .osw-sheet .osw-ans { background: #fff; border: 1px solid #bbb; box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none; break-inside: avoid; }
  .osw-sheet .osw-plan { display: flex; flex-direction: column; gap: 10px; }
  .osw-sheet svg { width: 14px; height: 14px; }
  .osw-sheet .osw-facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
  .osw-sheet * { color: #000 !important; }
}
