/* ═══════════════════════════════════════════════════════════════════
   anticor.kaznpu.kz — modern look (2026-10)
   Loaded after style.css on the public pages (ru / kz / en headers);
   the admin does not include it. Only restyles, the markup stays the same.
   ═══════════════════════════════════════════════════════════════════ */

:root {
  --ac-navy: #1e3e94;
  --ac-navy-dark: #132a6b;
  --ac-blue: #2d61ec;
  --ac-ink: #172036;
  --ac-muted: #5b6478;
  --ac-line: #e3e8f4;
  --ac-soft: #f5f7fc;
  --ac-bg: #eef2f9;
  --ac-radius: 18px;
  --ac-shadow: 0 10px 30px rgba(19, 42, 107, 0.08);
  --ac-shadow-hover: 0 18px 40px rgba(19, 42, 107, 0.16);
}

body {
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  color: var(--ac-ink);
  background:
    radial-gradient(1200px 500px at 100% -10%, rgba(45, 97, 236, 0.10), transparent 60%),
    var(--ac-bg);
  -webkit-font-smoothing: antialiased;
}

/* ─── Header ─── */
header {
  position: sticky;
  top: 0;
  z-index: 100;
  margin-bottom: 0 !important;
  background: linear-gradient(100deg, var(--ac-navy-dark) 0%, var(--ac-navy) 55%, #2851c4 100%);
  box-shadow: 0 6px 24px rgba(19, 42, 107, 0.25);
}
header .header {
  padding: 12px 0;
  font-size: 15px;
}
header .logo-block {
  width: 74px;
}
header .phone-block {
  margin-left: 22px;
  padding: 8px 14px 8px 10px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.08);
}
header .phone-block img {
  width: 26px;
}
header .phone-block p:first-child {
  font-size: 12px;
  opacity: 0.8;
}
header .phone-block a {
  font-weight: 600;
  font-size: 16px;
}
header .main-menu ul {
  gap: 4px;
}
header .main-menu ul li a {
  display: block;
  padding: 8px 14px;
  border-radius: 999px;
  font-weight: 500;
  transition: background 0.2s;
}
header .main-menu ul li a:hover {
  background: rgba(255, 255, 255, 0.12);
}
header .main-menu ul li a.active {
  padding: 8px 14px;
  color: var(--ac-navy);
  background: #fff;
}
header .lang-btn-block {
  margin-left: 20px;
  padding: 4px 6px 4px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
}
header .switch > span {
  font-family: inherit;
  font-size: 13px;
}


/* ─── Page card ─── */
.container.main {
  margin-top: 28px;
  margin-bottom: 40px;
  border-radius: 24px;
  background: #fff;
  box-shadow: var(--ac-shadow);
}
.page-title,
.main-container h5,
.news-block h5 {
  font-weight: 700 !important;
  letter-spacing: -0.01em;
  color: var(--ac-navy);
}
.page-title {
  position: relative;
  font-size: 30px;
  line-height: 1.25;
  padding-bottom: 14px;
}
.page-title::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 48px;
  height: 4px;
  border-radius: 4px;
  background: linear-gradient(90deg, var(--ac-blue), #7aa2ff);
}
.page-title.text-center::after {
  left: 50%;
  transform: translateX(-50%);
}

/* ─── Buttons ─── */
.btn.basic-btn,
.basic-btn,
.search-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border: none;
  border-radius: 999px;
  font-weight: 600;
  color: #fff;
  background: linear-gradient(90deg, var(--ac-navy), var(--ac-blue));
  box-shadow: 0 8px 20px rgba(45, 97, 236, 0.25);
  transition: transform 0.2s, box-shadow 0.2s;
}
.btn.basic-btn:hover,
.basic-btn:hover,
.search-btn:hover {
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 12px 26px rgba(45, 97, 236, 0.35);
  background: linear-gradient(90deg, var(--ac-navy), var(--ac-blue));
}
.basic-btn img {
  filter: brightness(0) invert(1);
}

/* ─── Home slider ─── */
.owl-carousel-banner .item {
  overflow: hidden;
  border-radius: 22px;
}
.owl-carousel-banner .item > img {
  height: clamp(260px, 32vw, 440px);
  object-fit: cover;
}
.slider .item .slider_background {
  background: linear-gradient(90deg, rgba(10, 22, 60, 0.15) 0%, rgba(10, 22, 60, 0.55) 100%);
}
.slider .item .slider_text {
  max-width: 46%;
  padding: 26px 30px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 18px;
  background: rgba(12, 26, 70, 0.35);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  font-weight: 600;
  line-height: 1.35;
}
.slider .item .slider_text a {
  margin-top: 14px;
  padding: 8px 18px;
  border-radius: 999px;
  background: #fff;
  color: var(--ac-navy);
  font-size: 15px;
  font-weight: 600;
}
.owl-theme .owl-dots .owl-dot span {
  width: 9px;
  height: 9px;
  background: #c7d1ea;
  transition: width 0.25s;
}
.owl-theme .owl-dots .owl-dot.active span,
.owl-theme .owl-dots .owl-dot:hover span {
  width: 26px;
  background: var(--ac-blue);
}

/* ─── News cards (home + news page) ─── */
.news-items .news-item,
.event-item {
  display: block;
  overflow: hidden;
  border-radius: 16px;
  background: #fff;
  border: 1px solid var(--ac-line);
  box-shadow: 0 4px 14px rgba(19, 42, 107, 0.05);
  transition: transform 0.25s, box-shadow 0.25s;
}
.news-items .news-item:hover,
.event-item:hover {
  transform: translateY(-4px);
  box-shadow: var(--ac-shadow-hover);
}
.news-items .news-item img,
.event-item a img {
  display: block;
  width: 100%;
  max-height: none;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: 0;
  transition: transform 0.5s;
}
.news-items .news-item:hover img,
.event-item:hover a img {
  transform: scale(1.04);
}
.news-items .news-item p,
.event-item .event-name {
  margin: 0;
  padding: 14px 16px 16px;
  font-size: 15px;
  font-weight: 500;
  line-height: 1.45;
  color: var(--ac-ink);
}
.news-items .news-item:hover p,
.event-item:hover .event-name {
  color: var(--ac-blue);
}
/* the date sits as a badge over the photo */
.event-item {
  position: relative;
}
.event-item .event-data {
  position: absolute;
  z-index: 2;
  top: 12px;
  left: 12px;
  margin: 0;
  padding: 5px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  color: var(--ac-navy);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}
.event-item a {
  display: block;
  overflow: hidden;
}

/* home videos */
.video-block .video-container video {
  border-radius: 16px;
  background: #0b1430;
}

/* ─── News page: search + pagination ─── */
.events-header {
  flex-wrap: wrap;
}
.search-form {
  display: flex;
  gap: 8px;
}
.search-input {
  min-width: 240px;
  padding: 10px 16px;
  border: 1px solid var(--ac-line);
  border-radius: 999px;
  background: var(--ac-soft);
  outline: none;
  transition: border-color 0.2s, background 0.2s;
}
.search-input:focus {
  border-color: var(--ac-blue);
  background: #fff;
}
.pagination {
  gap: 6px;
}
.pagination .pagination-link,
.pagination a,
.pagination span {
  min-width: 40px;
  border-radius: 12px !important;
}

/* ─── News detail ─── */
.event-detail .event-title {
  font-size: clamp(24px, 2.6vw, 34px);
}
.event-detail .event-date {
  display: inline-block;
  padding: 5px 12px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  color: var(--ac-navy);
  background: var(--ac-soft);
}
.event-detail .event-detail-info p {
  font-size: 17px;
  line-height: 1.75;
  text-align: left !important;
  color: #2b3445;
}
.event-detail .event-images {
  gap: 16px;
}
.event-detail .event-images img {
  border-radius: 14px;
  object-fit: cover;
  box-shadow: 0 6px 18px rgba(19, 42, 107, 0.1);
}

/* ─── Documents ─── */
.documets ul {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 460px), 1fr));
  gap: 12px;
}
.documets ul li a {
  display: flex !important;
  align-items: center;
  gap: 14px;
  max-width: none !important;
  height: 100%;
  margin: 0 !important;
  padding: 14px 18px;
  border: 1px solid var(--ac-line);
  border-radius: 14px;
  background: #fff;
  font-size: 15px;
  font-weight: 500;
  line-height: 1.4;
  text-transform: none !important;
  color: var(--ac-ink);
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
}
.documets ul li a::first-letter {
  text-transform: uppercase;
}
.documets ul li a:hover {
  color: var(--ac-navy);
  border-color: #b8c7f2;
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(19, 42, 107, 0.1);
}
.documets ul li a img {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  margin: 0 !important;
  padding: 9px;
  border-radius: 10px;
  background: var(--ac-soft);
}
/* "***" between the groups becomes a thin line */
.center-divider {
  height: 1px;
  margin: 28px 0;
  overflow: hidden;
  font-size: 0 !important;
  color: transparent;
  background: linear-gradient(90deg, transparent, var(--ac-line) 15%, var(--ac-line) 85%, transparent);
}
.certificate-block img,
.anti-corruption-policy img {
  border-radius: 14px;
  box-shadow: var(--ac-shadow);
}

/* ─── Employees ─── */
.profile-block {
  display: grid !important;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 32px;
  padding: 28px !important;
  margin: 20px 0;
  border: 1px solid var(--ac-line);
  border-radius: var(--ac-radius);
  background: #fff;
  font-family: inherit !important;
}
.profile-block .left-side {
  margin: 0 !important;
}
.profile-block .profile-photo {
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 16px;
}
.profile-block .profile-photo--initials {
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    radial-gradient(120% 90% at 85% 10%, rgba(255, 255, 255, 0.18), transparent 55%),
    linear-gradient(150deg, var(--ac-blue) 0%, var(--ac-navy) 60%, var(--ac-navy-dark) 100%);
}
.profile-block .profile-photo--initials span {
  font-size: 64px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: #fff;
}
.profile-block .right-side h3 {
  font-size: 26px;
  font-weight: 700;
  color: var(--ac-navy);
}
.profile-block .right-side h5 {
  margin-top: 22px;
  font-size: 17px;
  font-weight: 700;
  color: var(--ac-ink);
}
.profile-block .right-side a {
  color: var(--ac-blue);
  text-decoration: none;
}
.profile-block + hr,
.main hr {
  display: none;
}

/* ─── Sanaly Urpaq ─── */
.sanaly-urpaq iframe,
.sanaly-urpaq embed,
.sanaly-urpaq object {
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--ac-shadow);
}

/* ─── Footer ─── */
footer {
  margin-top: 0 !important;
  padding: 48px 0 20px;
  border-radius: 28px 28px 0 0;
  background:
    radial-gradient(800px 300px at 90% 0%, rgba(45, 97, 236, 0.35), transparent 60%),
    linear-gradient(160deg, var(--ac-navy) 0%, var(--ac-navy-dark) 100%);
}
footer .foor-left-menu ul li a {
  opacity: 0.9;
  transition: opacity 0.2s;
}
footer .foor-left-menu ul li a:hover {
  opacity: 1;
}
footer .social_btns {
  display: flex;
  gap: 10px;
}
footer .social_btns li a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.1);
  transition: background 0.2s;
}
footer .social_btns li a:hover {
  background: rgba(255, 255, 255, 0.2);
}
footer .social_btns li a img {
  margin: 0 !important;
}
/* the QR picture is white on transparent: a glass tile, not a white one */
footer .footer-qr-img {
  max-height: 180px;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.06);
}
footer .footer-medium p {
  margin-top: 12px;
  font-weight: 600;
  letter-spacing: 0.02em;
}
footer p.copyright {
  opacity: 0.7;
}

/* ─── Responsive ─── */
@media (max-width: 1200px) {
  header .main-menu ul li a {
    padding: 8px 10px;
  }
}
@media (max-width: 991px) {
  .container.main {
    margin-top: 16px;
    border-radius: 18px;
  }
  .slider .item .slider_text {
    max-width: 70%;
  }
  .profile-block {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  .profile-block .left-side {
    max-width: 220px;
  }
}
@media (max-width: 768px) {
  header .phone-block {
    padding: 6px 10px 6px 8px;
  }
  .page-title {
    font-size: 24px;
  }
  .owl-carousel-banner .item > img {
    height: 220px;
  }
  .slider .item .slider_text {
    max-width: 88%;
    padding: 14px 16px;
    font-size: 15px;
  }
  /* the title, "Recommendations" and the search stack instead of one wide row */
  .events-header,
  .events-header-right {
    flex-wrap: wrap;
    width: 100%;
  }
  .search-form {
    width: 100%;
  }
  .search-input {
    flex: 1;
    min-width: 0;
  }
  .documets ul {
    grid-template-columns: 1fr;
  }
  footer {
    border-radius: 20px 20px 0 0;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
  }
}

/* documents: the policy block holds a big picture link, not a card row */
.documets ul.anti-corruption-policy {
  display: block;
}
.documets .anti-corruption-policy li a.policy-img-download {
  display: block !important;
  margin-top: 16px !important;
  padding: 0;
  border: none;
  background: none;
  box-shadow: none;
  transform: none;
  text-align: center;
}
.documets .anti-corruption-policy li a.policy-img-download img {
  width: auto;
  height: auto;
  max-width: min(100%, 560px);
  padding: 0;
  border-radius: 14px;
  background: none;
  box-shadow: var(--ac-shadow);
}
.certificate-block {
  margin-top: 36px;
}
.certificate-block a {
  display: block;
  text-align: center;
}
.certificate-block img {
  max-width: min(100%, 460px);
}

/* employees: "Руководство:" heading like the other page titles */
.container.main > h5 {
  margin-bottom: 8px;
  font-size: 26px;
  font-weight: 700;
  color: var(--ac-navy);
}

/* burger button: a real 40px tap target (the icon was cut to 22x25) */
header .mobile_menu_btn {
  position: relative;
  width: 40px !important;
  height: 40px !important;
  margin: 0 0 0 8px !important;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.12);
  cursor: pointer;
}
header .mobile_menu_btn i {
  position: absolute;
  left: 50%;
  top: 50%;
  margin: 0 !important;
  font-size: 20px;
  line-height: 1;
  color: #fff;
  transform: translate(-50%, -50%);
  transition: opacity 0.2s;
}
header .mobile_menu_btn .mobile_menu_close_btn {
  opacity: 0;
}
header .mobile_menu_btn.open .mobile_menu_close_btn {
  opacity: 1;
}
header .mobile_menu_btn.open .mobile_menu_open_btn {
  opacity: 0;
}

@media (max-width: 768px) {
  /* compact header: logo, phone on one line, languages, burger */
  header .header {
    gap: 8px;
  }
  header .logo-block {
    width: 52px;
  }
  header .phone-block {
    margin-left: 10px;
    gap: 6px;
  }
  header .phone-block img {
    width: 20px;
  }
  header .phone-block p:first-child {
    display: none;
  }
  header .phone-block a {
    font-size: 14px;
    white-space: nowrap;
  }
  header .lang-btn-block {
    margin-left: 0;
    padding: 3px 4px;
  }
  header .lang-btn-block > img {
    display: none;
  }
  .container.main > h5 {
    font-size: 22px;
  }
}
@media (max-width: 400px) {
  header .phone-block {
    padding: 6px 8px;
  }
  header .phone-block a {
    font-size: 13px;
  }
}

/* mobile menu panel: a list of pill links (custom.js paints the active <li> blue inline).
   The panel opens by max-height on .menu_list.open, so the look goes there too:
   nothing is visible while it is closed. */
.mobile_menu ul.menu_list {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin: 0;
}
.mobile_menu ul.menu_list.open {
  max-height: 420px;
  padding: 10px 14px 16px;
  border-radius: 0 0 20px 20px;
  box-shadow: var(--ac-shadow-hover);
}
.mobile_menu ul li {
  margin: 0 !important;
  background: none !important;
  text-align: left;
}
.mobile_menu ul li a {
  display: block;
  padding: 12px 16px;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 500;
  color: var(--ac-ink) !important;
  text-decoration: none;
}
.mobile_menu ul li a:hover {
  background: var(--ac-soft);
}
.mobile_menu ul li a.active {
  color: #fff !important;
  background: linear-gradient(90deg, var(--ac-navy), var(--ac-blue));
}

@media (max-width: 400px) {
  header .logo-block {
    width: 44px;
  }
  header .phone-block {
    margin-left: 6px;
    padding: 5px 7px;
    gap: 4px;
  }
  header .phone-block img {
    width: 16px;
  }
  header .phone-block a {
    font-size: 12px;
  }
  header .switch > span > a,
  header .switch > span.on a {
    padding: 4px 5px;
  }
  header .mobile_menu_btn {
    width: 36px !important;
    height: 36px !important;
    margin-left: 4px !important;
  }
}
/* very narrow phones: the hotline number stays in the footer */
@media (max-width: 350px) {
  header .phone-block {
    display: none !important;
  }
}

/* phones: long quotes fit the slide, the emblem would overlap them */
@media (max-width: 576px) {
  .owl-carousel-banner .item > img {
    height: 300px;
  }
  .slider .item .logo {
    display: none;
  }
  .slider .item .slider_text {
    left: 50%;
    right: auto;
    max-width: none;
    width: calc(100% - 28px);
    transform: translate(-50%, -50%);
    font-size: 14px;
    line-height: 1.35;
    text-align: left;
  }
  .slider .item .slider_text i {
    font-size: 13px;
  }
}

/* ─── Modals ("Рекомендации" on the news page, director's "read more") ───
   style.css had position:absolute + z-index:1 inside the page card, so the news date
   badges (z-index 2) showed through. Now a full-screen layer above the sticky header. */
.modal {
  position: fixed !important;
  inset: 0;
  z-index: 1050 !important;
  width: auto !important;
  height: auto !important;
  padding: 32px 16px !important;
  overflow-y: auto;
  background: rgba(10, 20, 50, 0.55) !important;
  -webkit-backdrop-filter: blur(3px);
  backdrop-filter: blur(3px);
}
.modal .modal-content {
  max-width: 1100px;
  margin: 0 auto;
  border-radius: 22px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.3);
}
.modal .modal-content > span.close:not(.back-btn) {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--ac-soft);
  transition: background 0.2s;
}
/* the title is position:relative (for its underline) and comes later in the markup,
   so it covered the close button and swallowed the click */
.modal .modal-content > span.close:not(.back-btn) {
  z-index: 3;
}
.modal .modal-content > .page-title {
  padding-right: 64px;
}
.modal .modal-content > span.close:not(.back-btn):hover {
  background: #e3e9f8;
}
.modal .modal-content > span.close:not(.back-btn) img {
  width: 18px;
}
/* no page scrolling behind an open modal */
body:has(.modal[style*="display: block"]) {
  overflow: hidden;
}
@media (max-width: 768px) {
  .modal {
    padding: 12px 8px !important;
  }
  .modal .modal-content {
    padding: 24px 18px;
    border-radius: 18px;
  }
  .modal .modal-content > span.close:not(.back-btn) {
    right: 14px;
    top: 14px;
  }
}

/* style.css gives .modal-content height:100% on phones: with the full-screen layer the
   white box ended at one screen and the long text ran over the backdrop */
.modal .modal-content {
  height: auto !important;
}
/* "Назад" at the end of the modal is also .close: a normal pill button, not the X tile */
.modal .modal-content > .back-btn {
  position: static !important;
  display: inline-flex;
  width: max-content !important;
  float: none;
  margin: 28px 0 0;
  padding: 10px 22px;
  border-radius: 999px;
  color: #fff;
}
