/* ==========================================================
   ICHKI SAHIFALAR uchun uslublar (style.css dan keyin ulanadi)
   ========================================================== */
.is-hidden { display: none !important; }

/* ---------- Sahifa sarlavhasi ---------- */
.page-hero { background: #fff; border-bottom: 1px solid var(--line); padding: 40px 0 36px; position: relative; overflow: hidden; }
.page-hero::after { content: ""; position: absolute; right: -80px; top: -120px; width: 380px; height: 380px; border-radius: 50%; background: radial-gradient(circle, var(--primary-50) 0%, rgba(243,240,252,0) 70%); pointer-events: none; }
.page-hero h1 { font-size: clamp(28px, 3.6vw, 42px); font-weight: 800; letter-spacing: -.4px; margin-top: 14px; position: relative; z-index: 1; }
.page-hero p { color: var(--text-2); font-size: 17px; margin-top: 10px; max-width: 720px; position: relative; z-index: 1; }
.crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 14px; color: var(--muted); position: relative; z-index: 1; }
.crumbs a { color: var(--text-2); font-weight: 500; }
.crumbs a:hover { color: var(--primary); }
.crumbs .sep { color: #c9c7d8; }
.crumbs [aria-current] { color: var(--primary); font-weight: 600; }

/* ---------- Sahifa ichki menyusi ---------- */
.subnav { position: sticky; top: var(--header-h); z-index: 30; background: #fff; border-bottom: 1px solid var(--line); }
.subnav ul { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; }
.subnav ul::-webkit-scrollbar { display: none; }
.subnav a { display: block; padding: 14px 16px; font-size: 14.5px; font-weight: 600; color: var(--text-2); border-bottom: 2px solid transparent; white-space: nowrap; }
.subnav a:hover { color: var(--primary); border-bottom-color: var(--primary); }

/* ---------- Matn ---------- */
.prose { color: var(--text-2); font-size: 16.5px; line-height: 1.75; }
.prose > * + * { margin-top: 18px; }
.prose h2 { font-size: 24px; color: var(--text); margin-top: 36px; }
.prose h3 { font-size: 19px; color: var(--text); margin-top: 28px; }
.prose ul { list-style: disc; padding-left: 22px; }
.prose ul li + li { margin-top: 8px; }
.prose blockquote { margin: 28px 0; padding: 20px 24px; border-left: 4px solid var(--primary); background: var(--primary-50); border-radius: 0 12px 12px 0; color: var(--text); font-weight: 500; font-style: italic; }
.prose figure { margin: 28px 0; }
.prose figure .ph { aspect-ratio: 16/9; border-radius: var(--radius); }
.prose figcaption { font-size: 13.5px; color: var(--muted); margin-top: 8px; text-align: center; }
.prose a { color: var(--primary); text-decoration: underline; text-underline-offset: 3px; }

/* ---------- Kontent + yon panel ---------- */
.layout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 40px; align-items: start; }
.sidebar { display: grid; gap: 24px; position: sticky; top: calc(var(--header-h) + 20px); }
.widget { border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; background: #fff; }
.widget h3 { font-size: 17px; padding-bottom: 12px; margin-bottom: 6px; border-bottom: 2px solid var(--primary); }
.widget--accent { background: var(--primary); border-color: var(--primary); color: #fff; }
.widget--accent h3 { color: #fff; border-color: rgba(255,255,255,.3); }
.widget--accent p { color: rgba(255,255,255,.88); font-size: 14.5px; margin: 10px 0 16px; }
.widget--accent .btn { background: #fff; color: var(--primary); }
.cat-list li a { display: flex; justify-content: space-between; align-items: center; padding: 11px 0; border-bottom: 1px solid var(--line); font-size: 15px; font-weight: 500; }
.cat-list li:last-child a { border-bottom: 0; padding-bottom: 0; }
.cat-list li a:hover { color: var(--primary); }
.cat-list span { font-size: 12.5px; font-weight: 700; color: var(--primary); background: var(--primary-50); padding: 2px 9px; border-radius: 20px; }
.mini { display: flex; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.mini:last-child { border-bottom: 0; padding-bottom: 0; }
.mini__num { font-family: var(--ff-head); font-size: 22px; font-weight: 800; color: var(--primary-100); line-height: 1; width: 26px; flex-shrink: 0; }
.mini a { font-size: 14.5px; font-weight: 600; line-height: 1.4; display: block; }
.mini a:hover { color: var(--primary); }
.mini .meta { margin-top: 4px; font-size: 12.5px; }

/* ---------- Yangiliklar ro'yxati ---------- */
.news--list { grid-template-columns: repeat(2, 1fr); }
.news-featured { display: grid; grid-template-columns: 1.2fr 1fr; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; margin-bottom: 24px; background: #fff; transition: .25s; }
.news-featured:hover { box-shadow: var(--shadow); }
.news-featured .card__media { aspect-ratio: auto; min-height: 300px; }
.news-featured__body { padding: 30px; display: flex; flex-direction: column; gap: 14px; justify-content: center; }
.news-featured h2 { font-size: 24px; line-height: 1.3; }
.news-featured h2 a:hover { color: var(--primary); }
.news-featured p { color: var(--text-2); }
.toolbar { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; margin-bottom: 24px; }
.input-search { position: relative; flex: 1; max-width: 320px; min-width: 220px; }
.input-search svg { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--muted); }
.input-search input { width: 100%; font: inherit; font-size: 15px; padding: 11px 14px 11px 42px; border: 1.5px solid var(--line); border-radius: 10px; background: #fff; }
.input-search input:focus { outline: 0; border-color: var(--primary); box-shadow: 0 0 0 4px var(--primary-50); }
.empty { text-align: center; padding: 48px 20px; color: var(--muted); border: 1px dashed var(--line); border-radius: var(--radius); margin-top: 8px; }
.pagination { display: flex; justify-content: center; gap: 6px; margin-top: 40px; flex-wrap: wrap; }
.pagination a, .pagination span { min-width: 42px; height: 42px; padding: 0 12px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 10px; font-weight: 600; font-size: 14.5px; color: var(--text-2); background: #fff; }
.pagination a:hover { border-color: var(--primary); color: var(--primary); }
.pagination .is-active { background: var(--primary); border-color: var(--primary); color: #fff; }
.pagination svg { width: 16px; height: 16px; }

/* ---------- Yangilik ichki sahifasi ---------- */
.article__head h1 { font-size: clamp(26px, 3.2vw, 38px); font-weight: 800; letter-spacing: -.3px; margin: 14px 0 16px; }
.article__cover { aspect-ratio: 16/9; border-radius: 18px; margin: 26px 0 30px; }
.article__lead { font-size: 19px; color: var(--text); font-weight: 500; line-height: 1.6; }
.article__foot { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; margin-top: 36px; padding-top: 22px; border-top: 1px solid var(--line); }
.tags { display: flex; flex-wrap: wrap; gap: 8px; }
.tags a { font-size: 13px; font-weight: 600; padding: 6px 12px; border-radius: 20px; background: var(--soft); border: 1px solid var(--line); color: var(--text-2); }
.tags a:hover { border-color: var(--primary); color: var(--primary); }
.share { display: flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 600; color: var(--text-2); }
.share a, .share button { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 10px; border: 1px solid var(--line); background: #fff; color: var(--text-2); transition: .2s; }
.share a:hover, .share button:hover, .share button.is-done { background: var(--primary); border-color: var(--primary); color: #fff; }
.gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 28px 0; }
.gallery .ph { aspect-ratio: 4/3; border-radius: 12px; }

/* ---------- Qadriyatlar ---------- */
.values { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.value { border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; background: #fff; }
.value .course__icon { margin-bottom: 16px; }
.value h3 { font-size: 17px; margin-bottom: 8px; }
.value p { font-size: 14.5px; color: var(--text-2); }

/* ---------- Tarix ---------- */
.timeline { position: relative; display: grid; gap: 24px; padding-left: 34px; }
.timeline::before { content: ""; position: absolute; left: 9px; top: 6px; bottom: 6px; width: 2px; background: var(--primary-100); }
.timeline__item { position: relative; }
.timeline__item::before { content: ""; position: absolute; left: -31px; top: 5px; width: 14px; height: 14px; border-radius: 50%; background: #fff; border: 3px solid var(--primary); }
.timeline__item strong { font-family: var(--ff-head); color: var(--primary); font-size: 15px; }
.timeline__item h3 { font-size: 17px; margin: 2px 0 4px; }
.timeline__item p { color: var(--text-2); font-size: 15px; }

/* ---------- Jadval ---------- */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.table { width: 100%; border-collapse: collapse; font-size: 14.5px; min-width: 680px; }
.table th { text-align: left; font-weight: 700; color: var(--text); background: var(--soft); padding: 14px 18px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.table td { padding: 14px 18px; border-bottom: 1px solid var(--line); color: var(--text-2); vertical-align: top; }
.table tr:last-child td { border-bottom: 0; }
.table tbody tr:hover td { background: #fcfcfe; }
.table td strong { color: var(--text); }
.table a { color: var(--primary); font-weight: 600; white-space: nowrap; }
.pill { display: inline-block; font-size: 12.5px; font-weight: 700; padding: 3px 10px; border-radius: 20px; white-space: nowrap; }
.pill--green { background: #e8f7ef; color: #1a8a50; }
.pill--yellow { background: #fff6e0; color: #a06c00; }
.pill--gray { background: var(--soft); color: var(--muted); border: 1px solid var(--line); }

/* ---------- Hujjatlar ---------- */
.docs { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
.doc { display: flex; align-items: center; gap: 16px; padding: 18px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; transition: .2s; }
.doc:hover { border-color: var(--primary-100); box-shadow: var(--shadow); }
.doc__icon { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; background: #fdecee; color: #c2334a; flex-shrink: 0; }
.doc__icon svg { width: 22px; height: 22px; }
.doc__body { flex: 1; min-width: 0; }
.doc__body strong { display: block; font-size: 15px; line-height: 1.4; }
.doc__body small { color: var(--muted); font-size: 13px; }

/* ---------- Yo'nalish kartasi (kengaytirilgan) ---------- */
.course__teacher { display: flex; align-items: center; gap: 10px; margin-top: 16px; font-size: 13.5px; color: var(--text-2); }
.course__teacher > span:first-child { width: 32px; height: 32px; border-radius: 50%; background: var(--primary-50); color: var(--primary); display: grid; place-items: center; flex-shrink: 0; }
.course__teacher svg { width: 16px; height: 16px; }

/* ---------- Tadbirlar ---------- */
.event--big { align-items: flex-start; }
.event__desc { color: var(--text-2) !important; font-size: 14.5px !important; display: block !important; margin-top: 8px; }
.event.is-past .event__date { background: var(--soft); }
.event.is-past .event__date strong { color: var(--muted); }
.calendar { border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; background: #fff; }
.calendar__head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; }
.calendar__title { font-family: var(--ff-head); font-weight: 700; font-size: 17px; }
.calendar__head .icon-btn { width: 34px; height: 34px; }
.calendar__grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; text-align: center; }
.calendar__dow { font-size: 12px; font-weight: 700; color: var(--muted); padding: 4px 0 8px; }
.calendar__day { aspect-ratio: 1; display: grid; place-items: center; font-size: 14px; border-radius: 8px; color: var(--text-2); }
.calendar__day.is-today { border: 1.5px solid var(--primary); color: var(--primary); font-weight: 700; }
.calendar__day.has-event { background: var(--primary); color: #fff; font-weight: 700; }
.calendar__day.has-event:hover { background: var(--primary-600); }
.calendar__legend { display: flex; gap: 16px; margin-top: 14px; font-size: 12.5px; color: var(--muted); }
.calendar__legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; background: var(--primary); margin-right: 6px; vertical-align: middle; }
.calendar__legend i.t { background: #fff; border: 1.5px solid var(--primary); }

/* ---------- Kengash ---------- */
.council-hero { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.council-hero__logo { border: 1px solid var(--line); border-radius: 20px; padding: 40px; display: grid; place-items: center; background: #fff; box-shadow: var(--shadow); }
.initiatives { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.initiative { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: #fff; }
.initiative .ph { aspect-ratio: 16/9; }
.initiative__body { padding: 20px; }
.initiative__body h3 { font-size: 17px; margin: 10px 0 6px; }
.initiative__body p { color: var(--text-2); font-size: 14.5px; }
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; counter-reset: step; }
.step { padding: 26px 22px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.step::before { counter-increment: step; content: counter(step); width: 38px; height: 38px; display: grid; place-items: center; border-radius: 50%; background: var(--navy); color: #fff; font-family: var(--ff-head); font-weight: 800; margin-bottom: 14px; }
.step h3 { font-size: 16.5px; margin-bottom: 6px; }
.step p { font-size: 14.5px; color: var(--text-2); }

/* ---------- Aloqa ---------- */
.contact-cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.contact-card { border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; background: #fff; }
.contact-card .quick__icon { margin-bottom: 14px; }
.contact-card small { display: block; color: var(--muted); font-size: 13px; }
.contact-card strong { font-size: 16px; display: block; margin-top: 2px; line-height: 1.4; }
.contact-card a:hover { color: var(--primary); }
.form textarea { font: inherit; font-size: 15px; color: var(--text); width: 100%; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: 10px; background: #fff; resize: vertical; min-height: 130px; transition: .2s; }
.form textarea:focus { outline: 0; border-color: var(--primary); box-shadow: 0 0 0 4px var(--primary-50); }
.form textarea.is-invalid { border-color: #d64545; }
.form .form__check { display: flex; align-items: flex-start; gap: 10px; font-weight: 500; font-size: 13.5px; }
.form .form__check input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--primary); flex-shrink: 0; padding: 0; }

/* ---------- Moslashuvchan ---------- */
@media (max-width: 1180px) {
  .layout { grid-template-columns: minmax(0, 1fr); }
  .sidebar { position: static; grid-template-columns: repeat(2, 1fr); }
  .values, .steps, .contact-cards { grid-template-columns: repeat(2, 1fr); }
  .initiatives { grid-template-columns: repeat(2, 1fr); }
  .council-hero { grid-template-columns: 1fr; gap: 32px; }
}
@media (max-width: 720px) {
  .page-hero { padding: 26px 0 24px; }
  .sidebar { grid-template-columns: 1fr; }
  .news--list, .values, .steps, .contact-cards, .initiatives, .docs { grid-template-columns: 1fr; }
  .news-featured { grid-template-columns: 1fr; }
  .news-featured .card__media { min-height: 200px; }
  .news-featured__body { padding: 22px; }
  .news-featured h2 { font-size: 20px; }
  .gallery { grid-template-columns: 1fr 1fr; }
  .article__lead { font-size: 17px; }
  .input-search { max-width: none; }
  .council-hero__logo { padding: 24px; }
}
