/* =========================================================
   NUCZU HOMEPAGE REDESIGN
   Ідея: державна солідність + emergency-tech + людяність
========================================================= */
:root{
  --nuczu-blue:#203955;
  --nuczu-blue-2:#144274;
  --nuczu-blue-3:#0d2742;
  --nuczu-accent:#ef6603;
  --nuczu-soft:#f5f7fb;
  --nuczu-text:#263447;
  --nuczu-muted:#6b7788;
  --nuczu-border:rgba(32,57,85,.12);
  --nuczu-shadow:0 18px 45px rgba(13,39,66,.12);
}

.nuczu-home{
  background:#fff;
  color:var(--nuczu-text);
}

.nuczu-section{
  padding:84px 0;
  position:relative;
}

.nuczu-section-soft{
  background:linear-gradient(180deg,#f7f9fd 0%,#ffffff 100%);
}

.nuczu-section-dark{
  background:
    radial-gradient(circle at 10% 20%, rgba(239,102,3,.22), transparent 28%),
    radial-gradient(circle at 92% 10%, rgba(255,255,255,.12), transparent 25%),
    linear-gradient(135deg,var(--nuczu-blue-3),var(--nuczu-blue));
  color:#fff;
}

.nuczu-kicker{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:7px 12px;
  border:1px solid rgba(239,102,3,.25);
  border-radius:999px;
  background:rgba(239,102,3,.08);
  color:var(--nuczu-accent);
  font-size:13px;
  font-weight:700;
  letter-spacing:.04em;
  text-transform:uppercase;
}

.nuczu-section-title{
  margin-bottom:34px;
}

.nuczu-section-title h2{
  margin:14px 0 10px;
  font-size:clamp(28px,3vw,44px);
  line-height:1.08;
  font-weight:800;
  letter-spacing:-.04em;
  color:var(--nuczu-blue-3);
}

.nuczu-section-title p{
  max-width:760px;
  margin:0;
  color:var(--nuczu-muted);
  font-size:17px;
  line-height:1.65;
}

.nuczu-section-dark .nuczu-section-title h2,
.nuczu-section-dark .nuczu-section-title p{
  color:#fff;
}

/* HERO */
.nuczu-hero{
  min-height:100vh;
  display:flex;
  align-items:center;
  overflow:hidden;
  padding:120px 0 90px;
  background:
    linear-gradient(90deg, rgba(13,39,66,.94) 0%, rgba(20,66,116,.82) 48%, rgba(13,39,66,.42) 100%),
    url("{% static 'assets/img/nuczu/1.jpg' %}") center/cover no-repeat;
  color:#fff;
}

.nuczu-hero::after{
  content:"";
  position:absolute;
  inset:auto -10% -25% -10%;
  height:280px;
  background:radial-gradient(closest-side, rgba(239,102,3,.24), transparent 72%);
  pointer-events:none;
}

.nuczu-hero-grid{
  display:grid;
  grid-template-columns:minmax(0,1.05fr) minmax(330px,.75fr);
  gap:42px;
  align-items:center;
  position:relative;
  z-index:2;
}

.nuczu-hero-badge{
  display:inline-flex;
  align-items:center;
  gap:10px;
  padding:8px 14px;
  border-radius:999px;
  color:#fff;
  background:rgba(255,255,255,.12);
  border:1px solid rgba(255,255,255,.18);
  backdrop-filter:blur(12px);
  font-weight:700;
  font-size:14px;
}

.nuczu-hero h1{
  margin:22px 0 18px;
  color:#fff;
  font-size:clamp(38px,6vw,76px);
  line-height:.98;
  font-weight:900;
  letter-spacing:-.06em;
}

.nuczu-hero-lead{
  max-width:720px;
  color:rgba(255,255,255,.88);
  font-size:clamp(17px,1.5vw,21px);
  line-height:1.6;
  margin:0 0 28px;
}

.nuczu-hero-actions{
  display:flex;
  flex-wrap:wrap;
  gap:12px;
  margin-bottom:28px;
}

.nuczu-btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:9px;
  min-height:46px;
  padding:12px 18px;
  border-radius:999px;
  font-weight:800;
  text-decoration:none;
  transition:.25s ease;
}

.nuczu-btn-primary{
  background:var(--nuczu-accent);
  color:#fff;
  box-shadow:0 14px 28px rgba(239,102,3,.26);
}

.nuczu-btn-primary:hover{
  color:#fff;
  transform:translateY(-2px);
  box-shadow:0 18px 34px rgba(239,102,3,.34);
}

.nuczu-btn-ghost{
  color:#fff;
  border:1px solid rgba(255,255,255,.28);
  background:rgba(255,255,255,.08);
}

.nuczu-btn-ghost:hover{
  color:#fff;
  background:rgba(255,255,255,.16);
  transform:translateY(-2px);
}

.nuczu-hero-mini{
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:12px;
  max-width:720px;
}

.nuczu-hero-mini div{
  padding:14px;
  border-radius:18px;
  background:rgba(255,255,255,.1);
  border:1px solid rgba(255,255,255,.14);
  backdrop-filter:blur(12px);
}

.nuczu-hero-mini strong{
  display:block;
  color:#fff;
  font-size:20px;
  line-height:1;
}

.nuczu-hero-mini span{
  display:block;
  margin-top:6px;
  color:rgba(255,255,255,.76);
  font-size:13px;
}

.nuczu-command-card{
  border-radius:32px;
  padding:24px;
  background:rgba(255,255,255,.92);
  color:var(--nuczu-text);
  box-shadow:0 28px 70px rgba(0,0,0,.26);
  backdrop-filter:blur(16px);
}

.nuczu-command-card h3{
  margin:0 0 16px;
  color:var(--nuczu-blue-3);
  font-weight:900;
  letter-spacing:-.03em;
}

.nuczu-command-list{
  display:grid;
  gap:10px;
}

.nuczu-command-link{
  display:flex;
  align-items:center;
  gap:12px;
  padding:13px 14px;
  border-radius:18px;
  background:#f6f8fc;
  color:var(--nuczu-text);
  border:1px solid rgba(32,57,85,.08);
  transition:.22s ease;
}

.nuczu-command-link i{
  width:34px;
  height:34px;
  display:grid;
  place-items:center;
  border-radius:12px;
  color:#fff;
  background:linear-gradient(135deg,var(--nuczu-blue-2),var(--nuczu-blue));
}

.nuczu-command-link:hover{
  color:var(--nuczu-blue-3);
  transform:translateX(4px);
  background:#fff;
  box-shadow:0 12px 28px rgba(13,39,66,.08);
}

/* QUICK ROUTES */
.nuczu-route-card,
.nuczu-info-card,
.nuczu-institute-card,
.nuczu-service-card{
  height:100%;
  padding:24px;
  border-radius:26px;
  background:#fff;
  border:1px solid var(--nuczu-border);
  box-shadow:0 12px 34px rgba(13,39,66,.06);
  transition:.25s ease;
}

.nuczu-route-card:hover,
.nuczu-info-card:hover,
.nuczu-institute-card:hover,
.nuczu-service-card:hover{
  transform:translateY(-6px);
  box-shadow:var(--nuczu-shadow);
}

.nuczu-icon{
  width:52px;
  height:52px;
  display:grid;
  place-items:center;
  border-radius:18px;
  color:#fff;
  background:linear-gradient(135deg,var(--nuczu-blue-2),var(--nuczu-blue));
  font-size:24px;
  margin-bottom:18px;
}

.nuczu-route-card h3,
.nuczu-info-card h3,
.nuczu-institute-card h3,
.nuczu-service-card h3{
  color:var(--nuczu-blue-3);
  font-size:20px;
  font-weight:850;
  letter-spacing:-.02em;
  margin-bottom:9px;
}

.nuczu-route-card p,
.nuczu-info-card p,
.nuczu-institute-card p,
.nuczu-service-card p{
  color:var(--nuczu-muted);
  line-height:1.6;
  margin-bottom:0;
}

.nuczu-card-link{
  display:inline-flex;
  align-items:center;
  gap:8px;
  margin-top:18px;
  font-weight:800;
  color:var(--nuczu-accent);
}

/* STATS */
.nuczu-stats{
  margin-top:-52px;
  position:relative;
  z-index:3;
}

.nuczu-stats-shell{
  border-radius:30px;
  background:#fff;
  border:1px solid var(--nuczu-border);
  box-shadow:var(--nuczu-shadow);
  overflow:hidden;
}

.nuczu-stat{
  padding:26px 22px;
  border-right:1px solid var(--nuczu-border);
}

.nuczu-stat:last-child{
  border-right:0;
}

.nuczu-stat strong{
  display:block;
  color:var(--nuczu-blue-3);
  font-size:34px;
  line-height:1;
  font-weight:900;
  letter-spacing:-.04em;
}

.nuczu-stat span{
  display:block;
  margin-top:8px;
  color:var(--nuczu-muted);
  font-size:14px;
}

/* ABOUT */
.nuczu-about-panel{
  padding:34px;
  border-radius:30px;
  background:linear-gradient(135deg,#fff,#f7f9fd);
  border:1px solid var(--nuczu-border);
  box-shadow:var(--nuczu-shadow);
}

.nuczu-about-list{
  display:grid;
  gap:12px;
  margin:24px 0 0;
  padding:0;
  list-style:none;
}

.nuczu-about-list li{
  display:flex;
  gap:10px;
  color:var(--nuczu-text);
}

.nuczu-about-list i{
  color:var(--nuczu-accent);
  font-size:20px;
  flex:0 0 auto;
}

.nuczu-photo-stack{
  position:relative;
  min-height:430px;
}

.nuczu-photo-main{
  position:absolute;
  inset:0 0 70px 40px;
  border-radius:34px;
  background:url("{% static 'assets/img/nuczu/2.jpg' %}") center/cover no-repeat;
  box-shadow:var(--nuczu-shadow);
}

.nuczu-photo-note{
  position:absolute;
  left:0;
  bottom:0;
  max-width:360px;
  padding:22px;
  border-radius:24px;
  background:var(--nuczu-blue-3);
  color:#fff;
  box-shadow:0 22px 46px rgba(13,39,66,.28);
}

.nuczu-photo-note strong{
  display:block;
  font-size:26px;
  line-height:1;
  margin-bottom:8px;
}

/* DIRECTIONS */
.nuczu-direction{
  display:flex;
  gap:14px;
  align-items:flex-start;
  padding:18px;
  border-radius:22px;
  background:#fff;
  border:1px solid var(--nuczu-border);
  height:100%;
  transition:.22s ease;
}

.nuczu-direction:hover{
  transform:translateY(-4px);
  box-shadow:0 14px 32px rgba(13,39,66,.08);
}

.nuczu-direction i{
  width:42px;
  height:42px;
  flex:0 0 auto;
  display:grid;
  place-items:center;
  border-radius:15px;
  color:var(--nuczu-accent);
  background:rgba(239,102,3,.1);
  font-size:22px;
}

.nuczu-direction h3{
  margin:0 0 6px;
  font-size:18px;
  color:var(--nuczu-blue-3);
  font-weight:850;
}

.nuczu-direction p{
  margin:0;
  color:var(--nuczu-muted);
  line-height:1.55;
}

/* PRACTICE */
.nuczu-practice-card{
  border-radius:34px;
  overflow:hidden;
  background:#fff;
  box-shadow:var(--nuczu-shadow);
}

.nuczu-practice-image{
  min-height:420px;
  background:url("{% static 'assets/img/nuczu/3.jpg' %}") center/cover no-repeat;
}

.nuczu-practice-content{
  padding:34px;
}

.nuczu-check-grid{
  display:grid;
  grid-template-columns:repeat(2,1fr);
  gap:12px;
  margin-top:22px;
}

.nuczu-check-item{
  display:flex;
  align-items:center;
  gap:9px;
  padding:12px;
  border-radius:16px;
  background:#f6f8fc;
  color:var(--nuczu-text);
  font-weight:700;
}

.nuczu-check-item i{
  color:var(--nuczu-accent);
}

/* NEWS */
.nuczu-news-wrap article{
  border-radius:26px;
  overflow:hidden;
  background:#fff;
  border:1px solid var(--nuczu-border);
  box-shadow:0 12px 30px rgba(13,39,66,.06);
  transition:.24s ease;
  height:100%;
}

.nuczu-news-wrap article:hover{
  transform:translateY(-6px);
  box-shadow:var(--nuczu-shadow);
}

.nuczu-news-wrap .post-img{
  height:210px;
  overflow:hidden;
  background:#eef2f7;
}

.nuczu-news-wrap .post-img img{
  width:100%;
  height:100%;
  object-fit:cover;
  transition:.35s ease;
}

.nuczu-news-wrap article:hover .post-img img{
  transform:scale(1.06);
}

.nuczu-news-body{
  padding:20px;
}

.nuczu-news-chip{
  display:inline-flex;
  align-items:center;
  padding:5px 10px;
  border-radius:999px;
  background:rgba(239,102,3,.1);
  color:var(--nuczu-accent);
  font-weight:800;
  font-size:12px;
  margin-bottom:10px;
}

.nuczu-news-wrap .title{
  font-size:19px;
  line-height:1.25;
  margin:10px 0 0;
}

.nuczu-news-wrap .title a{
  color:var(--nuczu-blue-3);
}

.nuczu-news-wrap .title a:hover{
  color:var(--nuczu-accent);
}

.nuczu-latest-panel{
  height:100%;
  padding:22px;
  border-radius:28px;
  background:#fff;
  border:1px solid var(--nuczu-border);
  box-shadow:var(--nuczu-shadow);
}

.nuczu-latest-panel h3{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:10px;
  margin:0 0 14px;
  font-size:22px;
  font-weight:900;
  color:var(--nuczu-blue-3);
}

.nuczu-latest-link{
  display:block;
  padding:14px 0;
  border-bottom:1px solid rgba(32,57,85,.1);
  color:var(--nuczu-text);
}

.nuczu-latest-link:last-child{
  border-bottom:0;
}

.nuczu-latest-link strong{
  display:block;
  line-height:1.35;
  color:var(--nuczu-blue-3);
}

.nuczu-latest-link small{
  display:block;
  margin-top:7px;
  color:var(--nuczu-muted);
}

/* CTA */
.nuczu-cta{
  border-radius:36px;
  padding:38px;
  background:
    linear-gradient(90deg, rgba(13,39,66,.95), rgba(20,66,116,.92)),
    url("{% static 'assets/img/nuczu/1.jpg' %}") center/cover no-repeat;
  color:#fff;
  box-shadow:var(--nuczu-shadow);
}

.nuczu-cta h2{
  color:#fff;
  font-weight:900;
  letter-spacing:-.04em;
  margin-bottom:10px;
}

.nuczu-cta p{
  color:rgba(255,255,255,.82);
  margin:0;
  line-height:1.65;
}

@media (max-width: 991.98px){
  .nuczu-hero{
    min-height:auto;
    padding:120px 0 70px;
  }
  .nuczu-hero-grid{
    grid-template-columns:1fr;
  }
  .nuczu-command-card{
    display:none;
  }
  .nuczu-stats{
    margin-top:0;
    padding-top:28px;
  }
  .nuczu-stat{
    border-right:0;
    border-bottom:1px solid var(--nuczu-border);
  }
  .nuczu-photo-stack{
    min-height:360px;
  }
  .nuczu-photo-main{
    inset:0;
  }
  .nuczu-photo-note{
    left:18px;
    right:18px;
  }
}

@media (max-width: 575.98px){
  .nuczu-section{
    padding:60px 0;
  }
  .nuczu-hero-mini,
  .nuczu-check-grid{
    grid-template-columns:1fr;
  }
  .nuczu-hero-actions .nuczu-btn{
    width:100%;
  }
  .nuczu-cta{
    padding:26px;
    border-radius:28px;
  }
}

/* =========================================================
   Friendly Cookie Banner
========================================================= */

.cookie-banner {
  position: fixed;
  left: 24px;
  right: 24px;
  bottom: 24px;
  z-index: 99998;

  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;

  max-width: 1180px;
  margin: 0 auto;
  padding: 18px 20px;

  background: rgba(255, 255, 255, 0.96);
  color: #203955;
  border: 1px solid rgba(32, 57, 85, 0.12);
  border-radius: 24px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.18);
  backdrop-filter: blur(14px);

  animation: cookieSlideUp 0.35s ease both;
}

.cookie-banner[hidden],
.cookie-modal[hidden] {
  display: none !important;
}

.cookie-banner__content {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  min-width: 0;
}

.cookie-banner__icon {
  width: 44px;
  height: 44px;
  flex: 0 0 44px;

  display: inline-flex;
  align-items: center;
  justify-content: center;

  border-radius: 16px;
  background: rgba(239, 102, 3, 0.12);
  color: var(--accent-color);
  font-size: 22px;
}

.cookie-banner__text strong {
  display: block;
  margin-bottom: 4px;
  color: #203955;
  font-size: 16px;
}

.cookie-banner__text p {
  margin: 0;
  color: #5d6977;
  font-size: 14px;
  line-height: 1.45;
}

.cookie-banner__links {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
  font-size: 13px;
}

.cookie-banner__links a {
  color: var(--accent-color);
  font-weight: 600;
}

.cookie-banner__links span {
  color: #9aa5b1;
}

.cookie-banner__actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.cookie-btn {
  border: 0;
  border-radius: 999px;
  padding: 10px 16px;
  font-size: 14px;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  transition: 0.2s ease;
  white-space: nowrap;
}

.cookie-btn--primary {
  background: var(--accent-color);
  color: #fff;
  box-shadow: 0 10px 24px rgba(239, 102, 3, 0.28);
}

.cookie-btn--primary:hover {
  transform: translateY(-1px);
  background: color-mix(in srgb, var(--accent-color), #000 8%);
}

.cookie-btn--outline {
  background: #fff;
  color: #203955;
  border: 1px solid rgba(32, 57, 85, 0.18);
}

.cookie-btn--outline:hover {
  border-color: var(--accent-color);
  color: var(--accent-color);
}

.cookie-btn--ghost {
  background: transparent;
  color: #5d6977;
}

.cookie-btn--ghost:hover {
  background: rgba(32, 57, 85, 0.06);
  color: #203955;
}

/* Modal */

.cookie-modal {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.cookie-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(8, 22, 38, 0.62);
  backdrop-filter: blur(6px);
}

.cookie-modal__dialog {
  position: relative;
  width: min(620px, 100%);
  background: #fff;
  color: #203955;
  border-radius: 28px;
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.32);
  overflow: hidden;
  animation: cookiePop 0.25s ease both;
}

.cookie-modal__header,
.cookie-modal__footer {
  padding: 22px 24px;
}

.cookie-modal__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 1px solid rgba(32, 57, 85, 0.08);
}

.cookie-modal__header h3 {
  margin: 0 0 6px;
  color: #203955;
  font-size: 22px;
}

.cookie-modal__header p {
  margin: 0;
  color: #6b7582;
  font-size: 14px;
}

.cookie-modal__close {
  border: 0;
  background: rgba(32, 57, 85, 0.06);
  color: #203955;
  width: 38px;
  height: 38px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.cookie-modal__body {
  padding: 8px 24px;
}

.cookie-option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 18px 0;
  border-bottom: 1px solid rgba(32, 57, 85, 0.08);
}

.cookie-option:last-child {
  border-bottom: 0;
}

.cookie-option strong {
  display: block;
  margin-bottom: 5px;
  color: #203955;
}

.cookie-option p {
  margin: 0;
  color: #6b7582;
  font-size: 14px;
  line-height: 1.45;
}

.cookie-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;

  padding: 8px 10px;
  border-radius: 999px;
  background: rgba(32, 57, 85, 0.08);
  color: #203955;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

/* Switch */

.cookie-switch {
  position: relative;
  width: 52px;
  height: 30px;
  flex: 0 0 52px;
}

.cookie-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.cookie-switch span {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background: #d8dee6;
  border-radius: 999px;
  transition: 0.2s ease;
}

.cookie-switch span::before {
  content: "";
  position: absolute;
  width: 24px;
  height: 24px;
  left: 3px;
  top: 3px;
  background: #fff;
  border-radius: 50%;
  transition: 0.2s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.16);
}

.cookie-switch input:checked + span {
  background: var(--accent-color);
}

.cookie-switch input:checked + span::before {
  transform: translateX(22px);
}

.cookie-modal__footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  border-top: 1px solid rgba(32, 57, 85, 0.08);
}

/* Animations */

@keyframes cookieSlideUp {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes cookiePop {
  from {
    opacity: 0;
    transform: translateY(14px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* Mobile */

@media (max-width: 768px) {
  .cookie-banner {
    left: 12px;
    right: 12px;
    bottom: 12px;
    flex-direction: column;
    align-items: stretch;
    border-radius: 20px;
    padding: 16px;
  }

  .cookie-banner__actions {
    justify-content: stretch;
  }

  .cookie-banner__actions .cookie-btn {
    flex: 1 1 100%;
  }

  .cookie-option {
    align-items: flex-start;
    flex-direction: column;
  }

  .cookie-modal__footer {
    flex-direction: column-reverse;
    align-items: stretch;
  }

  .cookie-modal__footer .cookie-btn {
    width: 100%;
  }
}

/* =========================================================
   NUCZU Footer
========================================================= */

.nuczu-footer {
  position: relative;
  overflow: hidden;
  padding: 70px 0 26px;
  color: rgba(255, 255, 255, 0.82);
  background:
    radial-gradient(circle at top left, rgba(239, 102, 3, 0.18), transparent 34%),
    radial-gradient(circle at bottom right, rgba(255, 255, 255, 0.08), transparent 30%),
    linear-gradient(135deg, #102942 0%, #203955 48%, #102235 100%);
}

.nuczu-footer::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(rgba(255,255,255,0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.035) 1px, transparent 1px);
  background-size: 42px 42px;
  opacity: 0.35;
  pointer-events: none;
}

.nuczu-footer .container {
  position: relative;
  z-index: 2;
}

.nuczu-footer h3,
.nuczu-footer h4 {
  color: #fff;
}

.nuczu-footer h3 {
  margin: 0 0 8px;
  font-size: 28px;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.nuczu-footer h4 {
  margin: 0 0 18px;
  font-size: 16px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.nuczu-footer p {
  margin: 0;
  max-width: 420px;
  color: rgba(255, 255, 255, 0.74);
  font-size: 14px;
  line-height: 1.65;
}

.nuczu-footer-brand {
  display: flex;
  align-items: flex-start;
  gap: 16px;
}

.nuczu-footer-logo-wrap {
  width: 74px;
  height: 74px;
  flex: 0 0 74px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.10);
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 18px 38px rgba(0, 0, 0, 0.18);
}

.nuczu-footer-logo {
  width: 58px;
  height: 58px;
  object-fit: contain;
}

.nuczu-footer-socials {
  display: flex;
  align-items: center;
  gap: 10px;
}

.nuczu-footer-socials a {
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;

  border-radius: 999px;
  color: #fff;
  background: rgba(255, 255, 255, 0.10);
  border: 1px solid rgba(255, 255, 255, 0.14);

  transition: 0.22s ease;
}

.nuczu-footer-socials a:hover {
  transform: translateY(-2px);
  background: var(--accent-color);
  border-color: var(--accent-color);
  color: #fff;
}

.nuczu-footer-links,
.nuczu-footer-contact {
  list-style: none;
  margin: 0;
  padding: 0;
}

.nuczu-footer-links li {
  margin-bottom: 10px;
}

.nuczu-footer-links a,
.nuczu-footer-contact a,
.nuczu-footer-legal a {
  color: rgba(255, 255, 255, 0.74);
  text-decoration: none;
  transition: 0.2s ease;
}

.nuczu-footer-links a:hover,
.nuczu-footer-contact a:hover,
.nuczu-footer-legal a:hover {
  color: #fff;
}

.nuczu-footer-links a::before {
  content: "›";
  margin-right: 8px;
  color: var(--accent-color);
  font-weight: 800;
}

.nuczu-footer-contact li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 14px;
  line-height: 1.45;
}

.nuczu-footer-contact i {
  margin-top: 2px;
  color: var(--accent-color);
  font-size: 18px;
  flex: 0 0 20px;
}

.nuczu-footer-note {
  margin-top: 18px;
  padding: 14px 16px;
  border-radius: 18px;
  color: rgba(255, 255, 255, 0.74);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  font-size: 13px;
  line-height: 1.55;
}

.nuczu-footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-top: 52px;
  padding-top: 22px;
  border-top: 1px solid rgba(255, 255, 255, 0.14);
}

.nuczu-footer-copy {
  color: rgba(255, 255, 255, 0.68);
  font-size: 13px;
}

.nuczu-footer-legal {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 13px;
}

@media (max-width: 991.98px) {
  .nuczu-footer {
    padding-top: 54px;
  }

  .nuczu-footer-bottom {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 575.98px) {
  .nuczu-footer-brand {
    flex-direction: column;
  }

  .nuczu-footer-legal {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
}

/* Стилізація для людей з обмеженими можливостями (WCAG 2.1) */
/* ===== HEADER ALWAYS DARK ===== */
#header.header,
#header.header.header-scrolled,
#header.header.sticked {
  background: radial-gradient(60.38% 60.38% at 50% 39.62%, #144274 0, #203955 100%);
 /* темний */
  border-bottom: 1px solid rgba(255,255,255,.08);
  box-shadow: 0 10px 26px rgba(0,0,0,.25);
}
/* =========================
   LOGO
========================= */
.logo-img{
  width: 70px !important;
  height: 70px !important;
  max-width: none !important;
  max-height: none !important;
  object-fit: contain;
  flex-shrink: 0;
  display: block;
}

.header .logo,
#header .logo{
  height: auto !important;
  max-height: none !important;
  overflow: visible !important;
}


@media (min-width: 992px){

  /* 2-й рівень під пунктом (Структура -> ...) */
  #navmenu > ul > li.dropdown > ul{
    left: 0 !important;
    right: auto !important;
    top: 100% !important;
    transform: none !important;

    width: 220px;
    max-width: 240px;
  }

  /* базове: вкладені li повинні бути relative */
  #navmenu ul li.dropdown{
    position: relative !important;
  }

  /* щоб підменю не обрізалося */
  #navmenu ul li.dropdown > ul{
    overflow: visible !important;
  }

  /* 3-й рівень (Навчально-наукові інститути -> Інститут -> кафедри) */
  #navmenu ul li.dropdown ul li.dropdown > ul{
    top: 0 !important;
    left: 100% !important;
    right: auto !important;
    margin-left: 2px !important;     /* маленький зазор */
    transform: none !important;
    z-index: 9999 !important;

    width: 250px;
    max-width: 250px;
  }

  /* Дозволяємо перенос тексту (інакше вилазить за екран) */
  #navmenu .dropdown ul a{
    white-space: normal !important;
    overflow-wrap: anywhere;
    word-break: break-word;
    line-height: 1.25;
  }

  /* Трохи охайніше по відступах пунктів */
  #navmenu .dropdown ul a{
    padding: 10px 16px !important;
  }

  /* Прибираємо помаранчеву заливку/пігулку на 2-3 рівнях */
  #navmenu ul ul a,
  #navmenu ul ul a:focus,
  #navmenu ul ul li:hover > a,
  #navmenu ul ul .active,
  #navmenu ul ul .active:focus{
    background: transparent !important;
    border-radius: 0 !important;
    box-shadow: none !important;
  }

  /* Hover на вкладених меню: тільки акцентний текст + легкий сірий фон */
  #navmenu ul ul li:hover > a{
    color: var(--accent-color) !important;
    background: rgba(0,0,0,0.04) !important;
    border-radius: 10px !important;
  }
}

/* =========================
   MOBILE (<992px)
   - перенос рядка в пунктах
   - текст + стрілка в один ряд з переносом
========================= */
@media (max-width: 991.98px){

  /* прибираємо nowrap, якщо тема його нав’язує */
  #navmenu a{
    white-space: normal !important;
  }

  /* заголовок dropdown: span (текст) + іконка */
  #navmenu li.dropdown > a{
    display: flex !important;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
  }

  /* текст переноситься */
  #navmenu li.dropdown > a > span{
    flex: 1 1 auto;
    min-width: 0;                 /* КЛЮЧ для переносу у flex */
    overflow-wrap: anywhere;
    word-break: break-word;
    line-height: 1.2;
  }

  /* іконка не стискається і тримається справа */
  #navmenu li.dropdown > a > .toggle-dropdown,
  #navmenu li.dropdown > a > i.toggle-dropdown{
    flex: 0 0 auto;
    margin-left: auto;
  }
}
 /* Accent button (як "Застосувати"), але глобально */
.btn-accent{
  background: var(--accent-color) !important;
  border-color: var(--accent-color) !important;
  color: #fff !important;

  border-radius: 999px;
  padding: .65rem 1.1rem;
  font-weight: 600;
}

.btn-accent:hover,
.btn-accent:focus{
  background: color-mix(in srgb, var(--accent-color), #000 10%) !important;
  border-color: color-mix(in srgb, var(--accent-color), #000 10%) !important;
  color: #fff !important;
}


/* =========================
   ACCESSIBILITY BASE
========================= */
.skip-link {
  position: fixed;
  left: 16px;
  top: 16px;
  z-index: 100000;
  transform: translateY(-160%);
  background: #fff;
  color: #203955;
  padding: 12px 16px;
  border-radius: 999px;
  font-weight: 800;
  box-shadow: 0 14px 34px rgba(0,0,0,.22);
}

.skip-link:focus {
  transform: translateY(0);
  outline: 3px solid var(--accent-color);
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid var(--accent-color) !important;
  outline-offset: 3px;
}

.accessibility-toggle {
  position: fixed;
  right: 15px;
  bottom: 72px;
  z-index: 99997;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 999px;
  background: var(--accent-color);
  color: #fff;
  box-shadow: 0 14px 34px rgba(0,0,0,.25);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
}

.accessibility-panel {
  position: fixed;
  right: 15px;
  bottom: 130px;
  z-index: 99997;
  width: min(320px, calc(100vw - 30px));
  background: #fff;
  color: #203955;
  border-radius: 22px;
  box-shadow: 0 24px 64px rgba(0,0,0,.24);
  border: 1px solid rgba(32,57,85,.12);
  overflow: hidden;
}

.accessibility-panel[hidden] {
  display: none !important;
}

.accessibility-panel__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  border-bottom: 1px solid rgba(32,57,85,.1);
}

.accessibility-panel__header button {
  border: 0;
  background: rgba(32,57,85,.08);
  color: #203955;
  border-radius: 999px;
  width: 34px;
  height: 34px;
}

.accessibility-panel__body {
  display: grid;
  gap: 8px;
  padding: 14px;
}

.accessibility-action {
  border: 1px solid rgba(32,57,85,.14);
  background: #fff;
  color: #203955;
  border-radius: 14px;
  padding: 10px 12px;
  font-weight: 700;
  text-align: left;
}

.accessibility-action:hover {
  border-color: var(--accent-color);
  color: var(--accent-color);
}

/* User modes */
html.a11y-font-lg {
  font-size: 112.5%;
}

html.a11y-font-xl {
  font-size: 125%;
}

html.a11y-contrast body {
  background: #000 !important;
  color: #fff !important;
}

html.a11y-contrast a {
  color: #ffd166 !important;
}

html.a11y-contrast .section,
html.a11y-contrast .card,
html.a11y-contrast article,
html.a11y-contrast .nuczu-footer,
html.a11y-contrast .cookie-banner,
html.a11y-contrast .accessibility-panel {
  background: #000 !important;
  color: #fff !important;
  border-color: #fff !important;
}



html.a11y-reduce-motion *,
html.a11y-reduce-motion *::before,
html.a11y-reduce-motion *::after {
  animation-duration: 0.001ms !important;
  animation-iteration-count: 1 !important;
  scroll-behavior: auto !important;
  transition-duration: 0.001ms !important;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.001ms !important;
  }
}

/* Про університет */
/* =========================================================
   UNIVERSITY PAGE BUILDER
   Універсальні блоки для інформаційних сторінок
========================================================= */

.university-page-builder {
  padding-top: 88px;
  background: linear-gradient(180deg, #f7f9fd 0%, #ffffff 100%);
  color: var(--nuczu-text);
}

/* Admin panel */

.upb-admin-panel {
  margin: 26px 0 18px;
  padding: 18px 20px;
  border-radius: 24px;
  background: #ffffff;
  border: 1px solid var(--nuczu-border);
  box-shadow: var(--nuczu-shadow);

  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.upb-admin-panel strong {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--nuczu-blue-3);
  font-size: 16px;
}

.upb-admin-panel span {
  display: block;
  margin-top: 4px;
  color: var(--nuczu-muted);
  font-size: 14px;
}

.upb-admin-btn,
.upb-primary-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;

  min-height: 44px;
  padding: 11px 18px;
  border-radius: 999px;

  color: #ffffff;
  background: var(--nuczu-accent);
  border: 1px solid var(--nuczu-accent);

  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;

  box-shadow: 0 14px 28px rgba(239, 102, 3, 0.24);
  transition: 0.22s ease;
}

.upb-admin-btn:hover,
.upb-primary-link:hover {
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 18px 36px rgba(239, 102, 3, 0.32);
}

/* Page hero */

.upb-page-hero {
  position: relative;
  overflow: hidden;
  padding: 82px 0 76px;

  background:
    radial-gradient(circle at 10% 20%, rgba(239, 102, 3, 0.20), transparent 28%),
    radial-gradient(circle at 92% 12%, rgba(255, 255, 255, 0.13), transparent 25%),
    linear-gradient(135deg, var(--nuczu-blue-3), var(--nuczu-blue));

  color: #ffffff;
}

.upb-page-hero::before {
  content: "";
  position: absolute;
  inset: 0;

  background:
    linear-gradient(rgba(255,255,255,0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.035) 1px, transparent 1px);

  background-size: 42px 42px;
  opacity: 0.4;
  pointer-events: none;
}

.upb-page-hero-inner {
  position: relative;
  z-index: 2;
  max-width: 900px;
}

.upb-page-kicker {
  display: inline-flex;
  align-items: center;
  gap: 9px;

  padding: 8px 14px;
  margin-bottom: 20px;

  border-radius: 999px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.16);

  backdrop-filter: blur(12px);
  font-size: 14px;
  font-weight: 800;
}

.upb-page-hero h1 {
  margin: 0 0 18px;
  color: #ffffff;

  font-size: clamp(19px, 2.5vw, 35px);
  line-height: 1.08;
  font-weight: 950;
  letter-spacing: -0.02em;
}

.upb-page-hero p {
  max-width: 780px;
  margin: 0;

  color: rgba(255, 255, 255, 0.82);
  font-size: clamp(17px, 1.5vw, 21px);
  line-height: 1.65;
}

/* Empty */

.upb-empty-section {
  padding: 70px 0;
}

.upb-empty-card {
  max-width: 760px;
  margin: 0 auto;
  padding: 44px;

  text-align: center;
  background: #ffffff;
  border-radius: 32px;
  border: 1px solid var(--nuczu-border);
  box-shadow: var(--nuczu-shadow);
}

.upb-empty-icon {
  width: 76px;
  height: 76px;
  margin: 0 auto 20px;

  display: grid;
  place-items: center;

  border-radius: 24px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--nuczu-blue-2), var(--nuczu-blue));
  font-size: 34px;
}

.upb-empty-card h2 {
  color: var(--nuczu-blue-3);
  font-weight: 900;
  letter-spacing: -0.03em;
}

.upb-empty-card p {
  color: var(--nuczu-muted);
  line-height: 1.65;
  margin-bottom: 24px;
}

/* Blocks layout */

.upb-blocks-section {
  padding: 72px 0;
}

.upb-block {
  position: relative;
  height: 100%;
  padding: 28px;

  background: #ffffff;
  border: 1px solid var(--nuczu-border);
  border-radius: 28px;

  box-shadow: 0 14px 36px rgba(13, 39, 66, 0.07);
  overflow: hidden;

  transition: 0.24s ease;
}

.upb-block:hover {
  transform: translateY(-5px);
  box-shadow: var(--nuczu-shadow);
}

.upb-block h2,
.upb-block h3 {
  color: var(--nuczu-blue-3);
  font-weight: 900;
  letter-spacing: -0.035em;
}

.upb-block h2 {
  font-size: clamp(15px, 2vw, 27px);
  line-height: 1.16;
  margin-bottom: 12px;
}

.upb-block h3 {
  font-size: 30px;
  line-height: 1.28;
  margin-bottom: 8px;
}

.upb-subtitle {
  color: var(--nuczu-muted);
  font-size: 16px;
  font-weight: 700;
  line-height: 1.6;
  margin-bottom: 16px;
}

.upb-text {
  color: var(--nuczu-text);
  font-size: 16px;
  line-height: 1.76;
}

.upb-text p:last-child {
  margin-bottom: 0;
}

/* Icons */

.upb-icon {
  width: 54px;
  height: 54px;
  margin-bottom: 18px;

  display: grid;
  place-items: center;

  border-radius: 18px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--nuczu-blue-2), var(--nuczu-blue));
  font-size: 25px;
  box-shadow: 0 14px 30px rgba(13, 39, 66, 0.18);
}

/* Media: one standard */

.upb-media {
  width: 100%;
  aspect-ratio: 16 / 9;
  margin: 18px 0;

  border-radius: 24px;
  overflow: hidden;

  background: #eef2f7;
  border: 1px solid rgba(32, 57, 85, 0.10);
}

.upb-media img,
.upb-media iframe {
  width: 100%;
  height: 100%;
  display: block;
  border: 0;
}

.upb-media img {
  object-fit: cover;
  transition: 0.35s ease;
}

.upb-media:hover img {
  transform: scale(1.04);
}

.upb-media-hero {
  min-height: 340px;
  margin: 0;
}

.upb-media-tall {
  aspect-ratio: auto;
  height: 520px;
}

.upb-media-placeholder {
  min-height: 260px;

  display: grid;
  place-items: center;
  gap: 8px;

  color: var(--nuczu-muted);
  text-align: center;
}

.upb-media-placeholder i {
  font-size: 54px;
  color: rgba(32, 57, 85, 0.34);
}

.upb-media-placeholder span {
  display: block;
  padding: 0 18px;
  font-weight: 700;
}

/* Hero block */

.upb-hero-block {
  padding: 34px;
  color: #ffffff;

  background:
    radial-gradient(circle at 12% 18%, rgba(239, 102, 3, 0.24), transparent 28%),
    linear-gradient(135deg, var(--nuczu-blue-3), var(--nuczu-blue-2));
}

.upb-hero-block h2,
.upb-hero-block .upb-text,
.upb-hero-block .upb-subtitle {
  color: #ffffff;
}

.upb-hero-block .upb-subtitle,
.upb-hero-block .upb-text {
  color: rgba(255, 255, 255, 0.84);
}

.upb-hero-block .upb-icon {
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow: none;
}

/* Stat block */

.upb-stat-block {
  min-height: 260px;
}

.upb-stat-number {
  margin-bottom: 10px;

  color: var(--nuczu-blue-3);
  font-size: 42px;
  line-height: 1;
  font-weight: 950;
  letter-spacing: -0.05em;
}

.upb-stat-block h3 {
  font-size: 10px;
  margin-bottom: 6px;
}

.upb-stat-block p {
  margin-bottom: 0;
  color: var(--nuczu-muted);
  line-height: 1.55;
}

/* Timeline block */

.upb-timeline-block {
  display: grid;
  grid-template-columns: 160px minmax(0, 1fr);
  gap: 28px;
  align-items: start;
}

.upb-timeline-year {
  min-height: 64px;
  padding: 14px 16px;

  display: inline-flex;
  align-items: center;
  justify-content: center;

  border-radius: 20px;
  background: var(--nuczu-blue-3);
  color: #ffffff;

  font-size: 22px;
  font-weight: 950;
  text-align: center;
}

.upb-timeline-content {
  padding-left: 26px;
  border-left: 4px solid rgba(239, 102, 3, 0.28);
}

/* Quote block */

.upb-quote-block {
  padding: 46px;
  text-align: center;
  color: #ffffff;

  background:
    radial-gradient(circle at 10% 20%, rgba(239, 102, 3, 0.26), transparent 26%),
    linear-gradient(135deg, var(--nuczu-blue-3), var(--nuczu-blue));
}

.upb-quote-icon {
  width: 70px;
  height: 70px;
  margin: 0 auto 20px;

  display: grid;
  place-items: center;

  border-radius: 24px;
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
  font-size: 40px;
}

.upb-quote-block h3 {
  color: #ffffff;
  font-size: clamp(13px, 1.5vw, 21px);
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

.upb-quote-block .upb-subtitle,
.upb-quote-block .upb-text {
  color: rgba(255, 255, 255, 0.84);
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

/* Actions */

.upb-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;

  margin-top: 20px;
  padding-top: 16px;

  border-top: 1px solid rgba(32, 57, 85, 0.10);
}

.upb-hero-block .upb-actions,
.upb-quote-block .upb-actions {
  justify-content: center;
  border-top-color: rgba(255, 255, 255, 0.18);
}

.upb-hero-block .upb-actions {
  justify-content: flex-start;
}

/* Accessibility high contrast support */

html.a11y-contrast .university-page-builder,
html.a11y-contrast .upb-blocks-section,
html.a11y-contrast .upb-empty-section {
  background: #000 !important;
  color: #fff !important;
}

html.a11y-contrast .upb-block,
html.a11y-contrast .upb-empty-card,
html.a11y-contrast .upb-admin-panel {
  background: #000 !important;
  color: #fff !important;
  border-color: #fff !important;
  box-shadow: none !important;
}

html.a11y-contrast .upb-block h2,
html.a11y-contrast .upb-block h3,
html.a11y-contrast .upb-empty-card h2,
html.a11y-contrast .upb-admin-panel strong,
html.a11y-contrast .upb-text,
html.a11y-contrast .upb-subtitle {
  color: #fff !important;
}

/* Responsive */

@media (max-width: 991.98px) {
  .university-page-builder {
    padding-top: 82px;
  }

  .upb-admin-panel {
    flex-direction: column;
    align-items: flex-start;
  }

  .upb-admin-btn {
    width: 100%;
  }

  .upb-page-hero {
    padding: 64px 0 58px;
  }

  .upb-timeline-block {
    grid-template-columns: 1fr;
  }

  .upb-timeline-content {
    padding-left: 0;
    border-left: 0;
  }

  .upb-media-hero {
    min-height: 280px;
  }
}

@media (max-width: 575.98px) {
  .upb-blocks-section {
    padding: 52px 0;
  }

  .upb-block,
  .upb-hero-block,
  .upb-quote-block,
  .upb-empty-card {
    padding: 22px;
    border-radius: 24px;
  }

  .upb-page-hero h1 {
    font-size: 18px;
  }

  .upb-page-hero p {
    font-size: 16px;
  }

  .upb-media {
    border-radius: 18px;
  }

  .upb-media-tall {
    height: 460px;
  }

  .upb-actions .btn {
    width: 100%;
  }
}

/* Wide text block */
.upb-text-wide {
  max-width: 100%;
}

.upb-text-wide .upb-text {
  width: 100%;
  max-width: none;
  font-size: 17px;
  line-height: 1.82;
  text-align: justify;
  text-justify: inter-word;
  hyphens: auto;
}

.upb-text-wide .upb-text p {
  text-align: justify;
  text-justify: inter-word;
  hyphens: auto;
}

.upb-text-wide h3 {
  width: 100%;
  max-width: none;
  font-size: 30px;
}

.upb-text-wide .upb-subtitle {
  width: 100%;
  max-width: none;
}

.upb-text-media {
  max-width: 760px;
}

/* =========================================================
   NUCZU CONSTRUCTOR FORM UI
   Форма додавання / редагування блоків конструктора
   Працює з:
   - form.upb-block
   - .upb-form-card
   - старими .ui-* класами, якщо вони вже є в шаблоні
========================================================= */

.upb-form-shell,
.ui-block-form-page {
  min-height: 100vh;
  padding: 118px 0 76px;
  background:
    radial-gradient(circle at 8% 10%, rgba(239, 102, 3, 0.13), transparent 28%),
    radial-gradient(circle at 92% 8%, rgba(20, 66, 116, 0.13), transparent 30%),
    linear-gradient(180deg, #f8fafc 0%, #eef3f8 100%);
  color: var(--nuczu-text);
}

.upb-form-header,
.ui-block-form-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 24px;
  margin-bottom: 30px;
}

.upb-form-kicker,
.ui-block-form-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(239, 102, 3, 0.10);
  color: var(--nuczu-accent);
  border: 1px solid rgba(239, 102, 3, 0.22);
  font-size: 13px;
  font-weight: 850;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.upb-form-header h1,
.ui-block-form-top h1 {
  margin: 0 0 10px;
  color: var(--nuczu-blue-3);
  font-size: clamp(32px, 4vw, 54px);
  line-height: 1.04;
  font-weight: 950;
  letter-spacing: -0.055em;
}

.upb-form-header p,
.ui-block-form-top p {
  max-width: 780px;
  margin: 0;
  color: var(--nuczu-muted);
  font-size: 17px;
  line-height: 1.65;
}

.ui-back-btn,
.upb-form-back {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 12px 18px;
  border-radius: 999px;
  background: #ffffff;
  color: var(--nuczu-blue-3);
  border: 1px solid var(--nuczu-border);
  box-shadow: 0 12px 28px rgba(13, 39, 66, 0.08);
  text-decoration: none;
  font-weight: 850;
  white-space: nowrap;
  transition: 0.22s ease;
}

.ui-back-btn:hover,
.upb-form-back:hover {
  color: var(--nuczu-accent);
  transform: translateY(-2px);
  box-shadow: var(--nuczu-shadow);
}

/* Main form card */
.upb-constructor-form,
form.upb-block,
.ui-form-card {
  position: relative;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(255, 255, 255, 0.94));
  border: 1px solid rgba(32, 57, 85, 0.12);
  border-radius: 32px;
  padding: 30px;
  box-shadow: 0 22px 56px rgba(13, 39, 66, 0.10);
  backdrop-filter: blur(14px);
}

form.upb-block:hover,
.upb-constructor-form:hover {
  transform: none;
}

.upb-constructor-form::before,
form.upb-block::before,
.ui-form-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 5px;
  background: linear-gradient(90deg, var(--nuczu-accent), var(--nuczu-blue-2));
}

.upb-form-section-title,
.ui-form-card-head {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 26px;
}

.upb-form-section-icon,
.ui-form-icon {
  width: 52px;
  height: 52px;
  flex: 0 0 52px;
  display: grid;
  place-items: center;
  border-radius: 18px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--nuczu-blue-2), var(--nuczu-blue));
  font-size: 24px;
  box-shadow: 0 14px 30px rgba(13, 39, 66, 0.20);
}

.upb-form-section-title h2,
.ui-form-card-head h2 {
  margin: 0 0 5px;
  color: var(--nuczu-blue-3);
  font-size: 22px;
  font-weight: 900;
  letter-spacing: -0.03em;
}

.upb-form-section-title p,
.ui-form-card-head p {
  margin: 0;
  color: var(--nuczu-muted);
  font-size: 14px;
  line-height: 1.55;
}

/* Fields */
.upb-constructor-form .form-label,
form.upb-block .form-label,
.ui-field label {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 8px;
  color: var(--nuczu-blue-3);
  font-size: 14px;
  font-weight: 850;
}

.upb-constructor-form .form-control,
.upb-constructor-form .form-select,
form.upb-block .form-control,
form.upb-block .form-select,
.ui-field .form-control,
.ui-field .form-select {
  width: 100%;
  min-height: 48px;
  border-radius: 16px;
  border: 1px solid rgba(32, 57, 85, 0.16);
  background: #ffffff;
  color: var(--nuczu-text);
  padding: 12px 15px;
  font-size: 15px;
  box-shadow: none;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.upb-constructor-form textarea.form-control,
form.upb-block textarea.form-control,
.ui-field textarea.form-control {
  min-height: 220px;
  resize: vertical;
  line-height: 1.7;
}

.upb-constructor-form .form-control:focus,
.upb-constructor-form .form-select:focus,
form.upb-block .form-control:focus,
form.upb-block .form-select:focus,
.ui-field .form-control:focus,
.ui-field .form-select:focus {
  border-color: var(--nuczu-accent);
  box-shadow: 0 0 0 4px rgba(239, 102, 3, 0.14);
  background: #ffffff;
}

.upb-constructor-form .form-text,
form.upb-block .form-text,
.ui-help {
  margin-top: 7px;
  color: var(--nuczu-muted);
  font-size: 13px;
  line-height: 1.5;
}

.upb-constructor-form .form-text code,
form.upb-block .form-text code,
.ui-help code {
  color: var(--nuczu-blue-2);
  background: #eef2f7;
  border-radius: 8px;
  padding: 2px 7px;
}

.upb-constructor-form .errorlist,
form.upb-block .errorlist,
.ui-field-error ul {
  margin: 8px 0 0;
  padding: 10px 12px 10px 30px;
  border-radius: 14px;
  background: #fff1f2;
  color: #be123c;
  border: 1px solid rgba(190, 18, 60, 0.16);
  font-size: 13px;
}

/* Files */
.upb-constructor-form input[type="file"],
form.upb-block input[type="file"],
.ui-field input[type="file"] {
  padding: 10px;
  background: #f8fafc;
}

.upb-constructor-form input[type="file"]::file-selector-button,
form.upb-block input[type="file"]::file-selector-button,
.ui-field input[type="file"]::file-selector-button {
  margin-right: 12px;
  border: 0;
  border-radius: 999px;
  padding: 8px 14px;
  background: var(--nuczu-blue-2);
  color: #ffffff;
  font-weight: 800;
  cursor: pointer;
}

.ui-current-image {
  margin-top: 14px;
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid var(--nuczu-border);
  background: #f8fafc;
}

.ui-current-image img {
  width: 100%;
  max-height: 240px;
  display: block;
  object-fit: cover;
}

.ui-current-image span {
  display: block;
  padding: 10px 13px;
  color: var(--nuczu-muted);
  font-size: 13px;
}

/* Checkbox / active */
.upb-constructor-form .form-check,
form.upb-block .form-check {
  min-height: 48px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 16px;
  background: #f8fafc;
  border: 1px solid rgba(32, 57, 85, 0.12);
}

.upb-constructor-form .form-check-input,
form.upb-block .form-check-input,
.ui-switch-wrap .form-check-input {
  width: 46px;
  height: 24px;
  margin: 0;
  cursor: pointer;
  border-color: rgba(32, 57, 85, 0.22);
}

.upb-constructor-form .form-check-input:checked,
form.upb-block .form-check-input:checked,
.ui-switch-wrap .form-check-input:checked {
  background-color: var(--nuczu-accent);
  border-color: var(--nuczu-accent);
}

.ui-active-box {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  padding: 16px;
  border-radius: 20px;
  background: #f8fafc;
  border: 1px solid var(--nuczu-border);
}

.ui-active-box strong {
  color: var(--nuczu-blue-3);
}

.ui-active-box p {
  margin: 4px 0 0;
  color: var(--nuczu-muted);
  font-size: 13px;
  line-height: 1.45;
}

/* Form actions */
.upb-constructor-form .upb-actions,
form.upb-block .upb-actions,
.ui-submit-card {
  margin-top: 28px;
  padding-top: 22px;
  border-top: 1px solid rgba(32, 57, 85, 0.10);
}

.ui-submit-card {
  padding: 18px;
  background: #ffffff;
  border-radius: 26px;
  border: 1px solid var(--nuczu-border);
  box-shadow: 0 16px 40px rgba(13, 39, 66, 0.08);
}

.btn-accent,
.ui-submit-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 46px;
  border: 0 !important;
  border-radius: 999px !important;
  padding: 12px 18px !important;
  background: var(--nuczu-accent) !important;
  color: #ffffff !important;
  font-weight: 900 !important;
  text-decoration: none;
  box-shadow: 0 14px 28px rgba(239, 102, 3, 0.24);
  transition: 0.22s ease;
}

.btn-accent:hover,
.btn-accent:focus,
.ui-submit-btn:hover {
  color: #ffffff !important;
  transform: translateY(-2px);
  box-shadow: 0 18px 36px rgba(239, 102, 3, 0.32);
}

.ui-cancel-btn {
  margin-top: 10px;
  width: 100%;
  min-height: 44px;
  border-radius: 999px;
  padding: 12px 18px;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  color: var(--nuczu-muted);
  text-decoration: none;
  font-weight: 850;
  transition: 0.2s ease;
}

.ui-cancel-btn:hover {
  color: #dc2626;
  background: #fff1f2;
}

.ui-mini-help,
.upb-form-help {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: 18px;
  padding: 16px;
  border-radius: 22px;
  background: rgba(20, 66, 116, 0.08);
  color: var(--nuczu-blue-2);
  border: 1px solid rgba(20, 66, 116, 0.10);
  font-size: 14px;
  line-height: 1.55;
}

.ui-mini-help i,
.upb-form-help i {
  font-size: 20px;
  margin-top: 1px;
  color: var(--nuczu-accent);
}

.ui-sticky-panel {
  position: sticky;
  top: 106px;
}

/* High contrast */
html.a11y-contrast .upb-form-shell,
html.a11y-contrast .ui-block-form-page {
  background: #000 !important;
  color: #fff !important;
}

html.a11y-contrast .upb-constructor-form,
html.a11y-contrast form.upb-block,
html.a11y-contrast .ui-form-card,
html.a11y-contrast .ui-submit-card,
html.a11y-contrast .ui-active-box,
html.a11y-contrast .ui-mini-help,
html.a11y-contrast .upb-form-help {
  background: #000 !important;
  color: #fff !important;
  border-color: #fff !important;
  box-shadow: none !important;
}

html.a11y-contrast .upb-form-header h1,
html.a11y-contrast .ui-block-form-top h1,
html.a11y-contrast .upb-form-section-title h2,
html.a11y-contrast .ui-form-card-head h2,
html.a11y-contrast form.upb-block .form-label,
html.a11y-contrast .ui-field label,
html.a11y-contrast .ui-active-box strong,
html.a11y-contrast .ui-help,
html.a11y-contrast .ui-mini-help {
  color: #fff !important;
}

/* Responsive */
@media (max-width: 991.98px) {
  .upb-form-shell,
  .ui-block-form-page {
    padding-top: 102px;
  }

  .upb-form-header,
  .ui-block-form-top {
    flex-direction: column;
  }

  .ui-back-btn,
  .upb-form-back {
    width: 100%;
  }

  .ui-sticky-panel {
    position: static;
  }
}

@media (max-width: 575.98px) {
  .upb-form-shell,
  .ui-block-form-page {
    padding-top: 92px;
  }

  .upb-constructor-form,
  form.upb-block,
  .ui-form-card {
    padding: 22px;
    border-radius: 24px;
  }

  .upb-form-header h1,
  .ui-block-form-top h1 {
    font-size: 32px;
  }

  .upb-constructor-form .upb-actions .btn,
  form.upb-block .upb-actions .btn {
    width: 100%;
  }
}

/* =========================================================
   UNIVERSITY BUILDER DOCUMENT BLOCK
========================================================= */

.upb-document-block {
  min-height: 100%;
}

.upb-document-card {
  display: flex;
  gap: 18px;
  align-items: flex-start;

  margin-top: 18px;
  padding: 20px;

  border-radius: 24px;
  background: linear-gradient(135deg, #fff, #f8fafc);
  border: 1px solid var(--nuczu-border);
}

.upb-document-icon {
  width: 64px;
  height: 64px;
  flex: 0 0 64px;

  display: grid;
  place-items: center;

  border-radius: 20px;
  background: rgba(220, 38, 38, 0.10);
  color: #dc2626;
  font-size: 32px;
}

.upb-document-body {
  min-width: 0;
  flex: 1;
}

.upb-document-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;

  margin-top: 14px;
  min-height: 44px;
  padding: 11px 18px;

  border-radius: 999px;
  background: var(--nuczu-accent);
  color: #ffffff;
  text-decoration: none;
  font-weight: 850;

  box-shadow: 0 14px 28px rgba(239, 102, 3, 0.22);
  transition: 0.22s ease;
}

.upb-document-btn:hover {
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 18px 36px rgba(239, 102, 3, 0.30);
}

.upb-document-empty {
  display: inline-flex;
  align-items: center;
  gap: 8px;

  margin-top: 14px;
  padding: 10px 14px;

  border-radius: 999px;
  background: #fff1f2;
  color: #be123c;
  font-weight: 800;
}

@media (max-width: 575.98px) {
  .upb-document-card {
    flex-direction: column;
  }

  .upb-document-icon {
    width: 58px;
    height: 58px;
    flex-basis: 58px;
  }

  .upb-document-btn {
    width: 100%;
  }
}

/* url_card */
.upb-url-card-block,
.upb-contact-card-block,
.upb-person-card-block {
  height: 100%;
}

.upb-url-card-box,
.upb-contact-card,
.upb-person-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  gap: 18px;
}

.upb-url-card-head {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

.upb-url-card-icon {
  width: 54px;
  height: 54px;
  border-radius: 18px;
  background: rgba(13, 110, 253, 0.1);
  color: #0d6efd;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  flex-shrink: 0;
}

.upb-url-card-subtitle {
  margin: 0;
  color: #64748b;
  font-size: 0.95rem;
  line-height: 1.5;
}

.upb-url-card-btn {
  margin-top: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: fit-content;
  padding: 10px 16px;
  border-radius: 999px;
  background: #0d6efd;
  color: #fff;
  font-weight: 700;
  text-decoration: none;
  transition: 0.2s ease;
}

.upb-url-card-btn:hover {
  background: #0b5ed7;
  color: #fff;
  transform: translateY(-2px);
}

.upb-person-photo {
  width: 100%;
  aspect-ratio: 4 / 3;
  border-radius: 20px;
  overflow: hidden;
  background: #f1f5f9;
}

.upb-person-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.upb-person-photo-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  color: #94a3b8;
  font-size: 54px;
}

.upb-alert-box {
  display: flex;
  gap: 18px;
  padding: 20px;
  border-radius: 20px;
  background: rgba(13, 110, 253, 0.08);
  border: 1px solid rgba(13, 110, 253, 0.15);
}

.upb-alert-icon {
  width: 48px;
  height: 48px;
  border-radius: 16px;
  background: #0d6efd;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* =========================================================
   NUCZU CONSTRUCTOR FORM — CARD UI
========================================================= */

.constructor-form {
  position: relative;
}

.constructor-form-card,
.constructor-side-card,
.constructor-submit-card {
  height: auto;
}

.constructor-form-card:hover,
.constructor-side-card:hover,
.constructor-submit-card:hover {
  transform: none;
}

.constructor-card-head {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 24px;
}

.constructor-card-head.compact {
  margin-bottom: 18px;
}

.constructor-card-icon {
  width: 52px;
  height: 52px;
  flex: 0 0 52px;

  display: grid;
  place-items: center;

  border-radius: 18px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--nuczu-blue-2), var(--nuczu-blue));
  font-size: 24px;
  box-shadow: 0 14px 30px rgba(13, 39, 66, 0.18);
}

.constructor-card-head h2 {
  margin: 0 0 5px;
  color: var(--nuczu-blue-3);
  font-size: 22px;
  font-weight: 900;
  letter-spacing: -0.03em;
}

.constructor-card-head p {
  margin: 0;
  color: var(--nuczu-muted);
  font-size: 14px;
  line-height: 1.5;
}

.constructor-form .form-label {
  color: var(--nuczu-blue-3);
  font-size: 14px;
  margin-bottom: 7px;
}

.constructor-form .form-control,
.constructor-form .form-select {
  min-height: 46px;
  border-radius: 16px;
  border: 1px solid rgba(32, 57, 85, 0.16);
  background-color: #ffffff;
  color: var(--nuczu-text);
  padding: 12px 14px;
  box-shadow: none;
  transition: 0.2s ease;
}

.constructor-form textarea.form-control {
  min-height: 260px;
  line-height: 1.75;
  resize: vertical;
}

.constructor-form .form-control:focus,
.constructor-form .form-select:focus {
  border-color: var(--nuczu-accent);
  box-shadow: 0 0 0 4px rgba(239, 102, 3, 0.14);
}

.constructor-form .form-text {
  margin-top: 7px;
  color: var(--nuczu-muted);
  font-size: 13px;
}

.constructor-form .form-text code {
  padding: 2px 6px;
  border-radius: 7px;
  color: var(--nuczu-blue-2);
  background: #eef2f7;
}

.constructor-form .errorlist {
  margin: 7px 0 0;
  padding-left: 18px;
  color: #dc2626;
  font-size: 13px;
}

.constructor-sticky {
  position: sticky;
  top: 106px;
}

.constructor-help {
  display: flex;
  align-items: flex-start;
  gap: 10px;

  padding: 14px;
  border-radius: 18px;

  color: var(--nuczu-blue-2);
  background: rgba(20, 66, 116, 0.08);
  border: 1px solid rgba(20, 66, 116, 0.10);

  font-size: 13px;
  line-height: 1.55;
}

.constructor-help i {
  color: var(--nuczu-accent);
  font-size: 18px;
  margin-top: 1px;
}

.constructor-active-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;

  padding: 16px;
  border-radius: 20px;

  background: #f8fafc;
  border: 1px solid var(--nuczu-border);
}

.constructor-active-box strong {
  color: var(--nuczu-blue-3);
}

.constructor-active-box p {
  margin: 4px 0 0;
  color: var(--nuczu-muted);
  font-size: 13px;
  line-height: 1.45;
}

.constructor-active-box .form-check-input {
  width: 52px;
  height: 28px;
  cursor: pointer;
}

.constructor-submit-card .btn {
  min-height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 800;
}

html.a11y-contrast .constructor-card-head h2,
html.a11y-contrast .constructor-card-head p,
html.a11y-contrast .constructor-form .form-label,
html.a11y-contrast .constructor-help,
html.a11y-contrast .constructor-active-box strong,
html.a11y-contrast .constructor-active-box p {
  color: #fff !important;
}

html.a11y-contrast .constructor-help,
html.a11y-contrast .constructor-active-box {
  background: #000 !important;
  border-color: #fff !important;
}

@media (max-width: 991.98px) {
  .constructor-sticky {
    position: static;
  }
}

@media (max-width: 575.98px) {
  .constructor-card-head {
    flex-direction: column;
  }

  .constructor-card-icon {
    width: 48px;
    height: 48px;
    flex-basis: 48px;
  }

  .constructor-active-box {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* Конструктор секцій */
.constructor-section-preview {
  padding: 28px;
  border-radius: 26px;
  background:
    radial-gradient(circle at top left, rgba(239, 102, 3, 0.12), transparent 32%),
    linear-gradient(135deg, #ffffff, #f8fafc);
  border: 1px solid var(--nuczu-border);
}

.constructor-section-preview-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  padding: 7px 12px;
  border-radius: 999px;
  background: rgba(239, 102, 3, 0.10);
  color: var(--nuczu-accent);
  font-size: 13px;
  font-weight: 800;
}

.constructor-section-preview h3 {
  margin: 0 0 10px;
  color: var(--nuczu-blue-3);
  font-size: 32px;
  font-weight: 950;
  letter-spacing: -0.04em;
}

.constructor-section-preview p {
  max-width: 720px;
  margin: 0;
  color: var(--nuczu-muted);
  line-height: 1.65;
}

.constructor-section-preview-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-top: 24px;
}

.constructor-section-preview-grid div {
  height: 96px;
  border-radius: 20px;
  background: #ffffff;
  border: 1px solid var(--nuczu-border);
  box-shadow: 0 12px 26px rgba(13, 39, 66, 0.06);
}

@media (max-width: 575.98px) {
  .constructor-section-preview-grid {
    grid-template-columns: 1fr;
  }
}

.upb-admin-actions,
.upb-empty-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.upb-admin-btn-secondary,
.upb-primary-link-secondary {
  background: #ffffff;
  color: var(--nuczu-blue-3);
  border-color: var(--nuczu-border);
  box-shadow: 0 12px 28px rgba(13, 39, 66, 0.08);
}

.upb-admin-btn-secondary:hover,
.upb-primary-link-secondary:hover {
  color: var(--nuczu-accent);
  background: #ffffff;
  border-color: rgba(239, 102, 3, 0.35);
}

@media (max-width: 575.98px) {
  .upb-admin-actions,
  .upb-empty-actions {
    width: 100%;
    flex-direction: column;
    align-items: stretch;
  }

  .upb-admin-actions .upb-admin-btn,
  .upb-empty-actions .upb-primary-link {
    width: 100%;
  }
}


/* =========================================================
   NUCZU PAGE SECTIONS
   Назви розділів сторінки без картки
========================================================= */

.upb-section-group {
  position: relative;
  padding: 72px 0 38px;
  background: transparent;
}

.upb-section-group + .upb-section-group {
  padding-top: 56px;
}

.upb-section-head {
  position: relative;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 28px;

  margin-bottom: 34px;
  padding: 0 0 22px;

  background: transparent;
  border: 0;
  box-shadow: none;
}

.upb-section-head::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;

  height: 1px;
  background: linear-gradient(
    90deg,
    rgba(239, 102, 3, 0.75),
    rgba(32, 57, 85, 0.16),
    transparent
  );
}

.upb-section-head::before {
  content: "";
  position: absolute;
  left: 0;
  bottom: -2px;

  width: 92px;
  height: 4px;
  border-radius: 999px;
  background: var(--nuczu-accent);
  box-shadow: 0 8px 18px rgba(239, 102, 3, 0.28);
}

.upb-section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;

  margin-bottom: 14px;
  padding: 7px 13px;

  border-radius: 999px;
  color: var(--nuczu-accent);
  background: rgba(239, 102, 3, 0.08);
  border: 1px solid rgba(239, 102, 3, 0.18);

  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.upb-section-kicker i {
  font-size: 16px;
}

.upb-section-head h2,
.upb-section-head h3 {
  position: relative;
  margin: 0 0 10px;

  color: var(--nuczu-blue-3);
  font-size: clamp(17px, 2vw, 29px);
  line-height: 1.12;
  font-weight: 950;
  letter-spacing: -0.02em;
}

.upb-section-subtitle {
  max-width: 820px;
  margin: 0;

  color: var(--nuczu-muted);
  font-size: 18px;
  line-height: 1.6;
  font-weight: 750;
}

.upb-section-description {
  max-width: 900px;
  margin-top: 14px;

  color: var(--nuczu-text);
  font-size: 16px;
  line-height: 1.75;
}

.upb-section-description p:last-child {
  margin-bottom: 0;
}

.upb-section-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
  flex-shrink: 0;
  margin-bottom: 8px;
}

.upb-section-actions .btn {
  border-radius: 999px;
  font-weight: 800;
}

.upb-section-empty {
  max-width: 760px;
  margin: 0;
}

/* Трошки стискаємо відстань між заголовком розділу і картками */
.upb-section-head + .row {
  margin-top: 0;
}

/* Варіанти layout розділів */
.upb-section-layout-grid_1 > [class*="col-"] {
  width: 100%;
}

.upb-section-layout-grid_2 > [class*="col-"] {
  flex: 0 0 auto;
  width: 50%;
}

.upb-section-layout-grid_3 > [class*="col-"] {
  flex: 0 0 auto;
  width: 33.333333%;
}

.upb-section-layout-grid_4 > [class*="col-"] {
  flex: 0 0 auto;
  width: 25%;
}

.upb-section-layout-full_width > [class*="col-"] {
  width: 100%;
}

.upb-section-layout-people > [class*="col-"],
.upb-section-layout-grid_3 > .upb-person-card-block {
  flex: 0 0 auto;
  width: 33.333333%;
}

.upb-section-layout-documents > [class*="col-"],
.upb-section-layout-faq > [class*="col-"] {
  flex: 0 0 auto;
  width: 50%;
}

@media (max-width: 991.98px) {
  .upb-section-group {
    padding: 58px 0 30px;
  }

  .upb-section-head {
    flex-direction: column;
    align-items: flex-start;
    gap: 18px;
  }

  .upb-section-actions {
    width: 100%;
    justify-content: flex-start;
    margin-bottom: 0;
  }

  .upb-section-actions .btn {
    width: auto;
  }

  .upb-section-layout-grid_2 > [class*="col-"],
  .upb-section-layout-grid_3 > [class*="col-"],
  .upb-section-layout-grid_4 > [class*="col-"],
  .upb-section-layout-people > [class*="col-"],
  .upb-section-layout-documents > [class*="col-"],
  .upb-section-layout-faq > [class*="col-"] {
    width: 50%;
  }
}

@media (max-width: 575.98px) {
  .upb-section-group {
    padding: 46px 0 24px;
  }

  .upb-section-head h2,
  .upb-section-head h3 {
    font-size: 17px;
  }

  .upb-section-subtitle {
    font-size: 16px;
  }

  .upb-section-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .upb-section-actions .btn {
    width: 100%;
  }

  .upb-section-layout-grid_2 > [class*="col-"],
  .upb-section-layout-grid_3 > [class*="col-"],
  .upb-section-layout-grid_4 > [class*="col-"],
  .upb-section-layout-people > [class*="col-"],
  .upb-section-layout-documents > [class*="col-"],
  .upb-section-layout-faq > [class*="col-"] {
    width: 100%;
  }
}

/* =========================================================
   SECTION LAYOUT CONTROL
   Розділ керує шириною блоків усередині себе
========================================================= */

.upb-section-layout-grid_1 > div {
  flex: 0 0 auto !important;
  width: 100% !important;
}

.upb-section-layout-grid_2 > div {
  flex: 0 0 auto !important;
  width: 50% !important;
}

.upb-section-layout-grid_3 > div {
  flex: 0 0 auto !important;
  width: 33.333333% !important;
}

.upb-section-layout-grid_4 > div {
  flex: 0 0 auto !important;
  width: 25% !important;
}

.upb-section-layout-full_width > div {
  flex: 0 0 auto !important;
  width: 100% !important;
}

.upb-section-layout-people > div {
  flex: 0 0 auto !important;
  width: 33.333333% !important;
}

.upb-section-layout-documents > div {
  flex: 0 0 auto !important;
  width: 50% !important;
}

.upb-section-layout-faq > div {
  flex: 0 0 auto !important;
  width: 50% !important;
}

.upb-section-layout-timeline > div {
  flex: 0 0 auto !important;
  width: 50% !important;
}

@media (max-width: 991.98px) {
  .upb-section-layout-grid_3 > div,
  .upb-section-layout-grid_4 > div,
  .upb-section-layout-people > div {
    width: 50% !important;
  }

  .upb-section-layout-grid_2 > div,
  .upb-section-layout-documents > div,
  .upb-section-layout-faq > div,
  .upb-section-layout-timeline > div {
    width: 50% !important;
  }
}

@media (max-width: 575.98px) {
  .upb-section-layout-grid_1 > div,
  .upb-section-layout-grid_2 > div,
  .upb-section-layout-grid_3 > div,
  .upb-section-layout-grid_4 > div,
  .upb-section-layout-full_width > div,
  .upb-section-layout-people > div,
  .upb-section-layout-documents > div,
  .upb-section-layout-faq > div,
  .upb-section-layout-timeline > div {
    width: 100% !important;
  }
}

/* Аватарки */
.nuczu-auth-avatar {
  width: 38px;
  height: 38px;
  margin-left: 8px;
  border-radius: 50%;
  object-fit: cover;
}

.nuczu-google-login {
  display: flex;
  align-items: center;
  padding-left: 12px;
}

/* Конструктор інструкцій */
.constructor-help-card {
  padding: 26px;
  border-radius: 28px;
}

.constructor-help-card-head {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  margin-bottom: 18px;
}

.constructor-help-card-head h2 {
  margin: 4px 0 0;
  font-size: 1.25rem;
  font-weight: 800;
}

.constructor-help-type {
  display: inline-flex;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(13, 110, 253, 0.1);
  color: #0d6efd;
  font-size: 0.75rem;
  font-weight: 700;
}

.constructor-help-desc {
  color: #4b5563;
  margin-bottom: 18px;
}

.constructor-help-list {
  margin-top: 14px;
}

.constructor-help-list h3 {
  font-size: 0.85rem;
  font-weight: 800;
  margin-bottom: 8px;
  color: #111827;
}

.constructor-help-list ul {
  margin: 0;
  padding-left: 18px;
}

.constructor-help-list li {
  margin-bottom: 5px;
  color: #374151;
}

.constructor-help-list.muted li {
  color: #9ca3af;
}

.constructor-help-example {
  margin-top: 18px;
  padding: 14px;
  border-radius: 18px;
  background: rgba(25, 135, 84, 0.08);
  color: #166534;
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: 0.9rem;
}

/* =========================================================
   Constructor sidebar layout
   Navbar зверху на всю ширину,
   sidebar зліва від краю екрана,
   весь контент конструктора праворуч
========================================================= */

:root {
  --upb-sidebar-width: 320px;
  --upb-header-height: 116px;
  --upb-content-max-width: 1180px;
}

/* Загальний фон сторінки конструктора */
.university-page-builder {
  background: linear-gradient(180deg, #f7f9fd 0%, #ffffff 100%);
}

/* Оболонка сторінки конструктора */
.upb-constructor-shell {
  width: 100%;
  min-height: calc(100vh - var(--upb-header-height));
  display: block;
}

/* Sidebar фіксований зліва, під navbar */
.upb-constructor-sidebar {
  position: fixed;
  left: 0;
  top: var(--upb-header-height);

  width: var(--upb-sidebar-width);
  height: calc(100vh - var(--upb-header-height));

  background:
    radial-gradient(circle at 20% 8%, rgba(255, 255, 255, .10), transparent 28%),
    radial-gradient(circle at 85% 92%, rgba(239, 102, 3, .14), transparent 32%),
    linear-gradient(180deg, var(--nuczu-blue-2), var(--nuczu-blue-3));

  border-right: 1px solid rgba(255, 255, 255, .10);
  box-shadow: 18px 0 45px rgba(13, 39, 66, .22);

  z-index: 30;
  overflow: hidden;
}

/* Увесь контент конструктора праворуч від sidebar */
.upb-constructor-main {
  min-width: 0;
  width: calc(100% - var(--upb-sidebar-width));
  margin-left: var(--upb-sidebar-width);
}

/* Контейнери всередині правої частини */
.upb-constructor-main > .container,
.upb-constructor-main .container {
  max-width: var(--upb-content-max-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
}

/* Основна секція контенту */
.upb-content-layout-section {
  padding: 42px 0 84px;
}

/* Прибираємо зайві верхні відступи */
.upb-constructor-main .upb-blocks-section {
  padding-top: 0;
}

.upb-constructor-main .upb-section-group:first-child {
  padding-top: 0;
}


/* =========================================================
   Sidebar visual — dark navbar style
========================================================= */

.upb-sidebar-menu {
  width: 100%;
  height: 100%;
}

.upb-sidebar-menu-inner {
  height: 100%;
  padding: 24px 18px;
  background: transparent;
  overflow-y: auto;
  color: #ffffff;
}

.upb-sidebar-title {
  display: flex;
  align-items: center;
  gap: 12px;

  padding: 10px 8px 18px;
  margin-bottom: 16px;

  color: #ffffff;
  font-size: 17px;
  font-weight: 900;
  line-height: 1.2;

  border-bottom: 1px solid rgba(255, 255, 255, .16);
}

.upb-sidebar-title i {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;

  display: inline-flex;
  align-items: center;
  justify-content: center;

  border-radius: 14px;
  color: #ffffff;
  background: rgba(255, 255, 255, .12);
  border: 1px solid rgba(255, 255, 255, .18);
}

.upb-sidebar-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.upb-sidebar-item {
  margin: 4px 0;
}

.upb-sidebar-item ul {
  margin-top: 4px;
  margin-bottom: 7px;
}

/* Основний пункт */
.upb-sidebar-link {
  position: relative;

  display: flex;
  align-items: center;
  gap: 9px;

  padding: 10px 12px;
  border-radius: 14px;

  color: rgba(255, 255, 255, .78);
  text-decoration: none;

  font-size: 14px;
  font-weight: 750;
  line-height: 1.25;

  transition: .2s ease;
}

.upb-sidebar-link i {
  color: rgba(255, 255, 255, .58);
  font-size: 14px;
  flex: 0 0 auto;
}

/* Hover */
.upb-sidebar-link:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, .10);
  transform: translateX(3px);
}

.upb-sidebar-link:hover i {
  color: #ffffff;
}

/* Батько активної гілки */
.upb-sidebar-item.has-active-child > .upb-sidebar-link {
  color: #ffffff;
  background: rgba(255, 255, 255, .10);
}

.upb-sidebar-item.has-active-child > .upb-sidebar-link i {
  color: var(--nuczu-accent);
}

/* Поточна сторінка */
.upb-sidebar-link.active {
  color: #ffffff;
  background: rgba(239, 102, 3, .26);
  border: 1px solid rgba(239, 102, 3, .58);
  box-shadow: 0 12px 24px rgba(0, 0, 0, .14);
}

.upb-sidebar-link.active::before {
  content: "";
  position: absolute;
  left: -8px;
  top: 9px;
  bottom: 9px;

  width: 4px;
  border-radius: 99px;
  background: var(--nuczu-accent);
}

.upb-sidebar-link.active i {
  color: #ffffff;
}

/* Рівні вкладеності */
.upb-sidebar-level-2 > .upb-sidebar-link {
  padding-left: 26px;
  font-size: 13px;
  font-weight: 700;
  color: rgba(255, 255, 255, .72);
}

.upb-sidebar-level-3 > .upb-sidebar-link {
  padding-left: 44px;
  font-size: 13px;
  font-weight: 600;
  color: rgba(255, 255, 255, .66);
}

.upb-sidebar-level-4 > .upb-sidebar-link {
  padding-left: 62px;
  font-size: 12.5px;
  font-weight: 600;
  color: rgba(255, 255, 255, .60);
}


/* =========================================================
   Sidebar scrollbar
========================================================= */

.upb-sidebar-menu-inner {
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, .30) transparent;
}

.upb-sidebar-menu-inner::-webkit-scrollbar {
  width: 6px;
}

.upb-sidebar-menu-inner::-webkit-scrollbar-track {
  background: transparent;
}

.upb-sidebar-menu-inner::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, .26);
  border-radius: 999px;
}

.upb-sidebar-menu-inner::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, .42);
}


/* =========================================================
   Tablet / mobile
========================================================= */

@media (max-width: 1199.98px) {
  .upb-constructor-shell {
    display: block;
    width: 100%;
  }

  .upb-constructor-sidebar {
    display: none;
  }

  .upb-constructor-main {
    width: 100%;
    margin-left: 0;
  }

  .upb-constructor-main > .container,
  .upb-constructor-main .container {
    max-width: 100%;
    padding-left: 12px;
    padding-right: 12px;
  }

  .upb-content-layout-section {
    padding: 42px 0 70px;
  }
}

/* Footer shift for constructor sidebar */
@media (min-width: 1200px) {
  .nuczu-footer--with-constructor-sidebar {
    width: calc(100% - var(--upb-sidebar-width));
    margin-left: var(--upb-sidebar-width);
  }
}

@media (max-width: 1199.98px) {
  .nuczu-footer--with-constructor-sidebar {
    width: 100%;
    margin-left: 0;
  }
}

/* Sidebar collapse button */
/* navbar має бути вище кнопки */
#header,
.header,
#navmenu,
#navmenu > ul,
#navmenu .dropdown ul {
  z-index: 1200 !important;
}

/* sidebar нижче navbar */
.upb-constructor-sidebar {
  z-index: 900;
}

/* кнопка вище sidebar, але нижче navbar */
.upb-sidebar-toggle {
  position: fixed;
  top: calc(var(--upb-header-height) + 18px);
  left: calc(var(--upb-sidebar-width) - 19px);
  z-index: 950;

  width: 42px;
  height: 42px;

  display: inline-flex;
  align-items: center;
  justify-content: center;

  border: 2px solid rgba(255, 255, 255, .35);
  border-radius: 999px;

  background: var(--nuczu-accent);
  color: #ffffff;

  box-shadow: 0 14px 30px rgba(0, 0, 0, .28);
  cursor: pointer;

  transition:
    left .25s ease,
    transform .25s ease,
    background .2s ease,
    box-shadow .2s ease;
}

.upb-sidebar-toggle:hover {
  background: color-mix(in srgb, var(--nuczu-accent), #000 10%);
  transform: scale(1.06);
}

.upb-sidebar-toggle i {
  font-size: 20px;
  line-height: 1;
}

/* Collapsed state */
@media (min-width: 1200px) {
  body.upb-sidebar-collapsed .upb-constructor-sidebar {
    transform: translateX(calc(-1 * var(--upb-sidebar-width)));
  }

  body.upb-sidebar-collapsed .upb-constructor-main {
    width: 100%;
    margin-left: 0;
  }

  body.upb-sidebar-collapsed .nuczu-footer--with-constructor-sidebar {
    width: 100%;
    margin-left: 0;
  }

  body.upb-sidebar-collapsed .upb-sidebar-toggle {
    left: 18px;
    transform: rotate(180deg);
  }

  body.upb-sidebar-collapsed .upb-sidebar-toggle:hover {
    transform: rotate(180deg) scale(1.06);
  }

  .upb-constructor-sidebar,
  .upb-constructor-main,
  .nuczu-footer--with-constructor-sidebar {
    transition: transform .25s ease, width .25s ease, margin-left .25s ease;
  }
}


/* ХІРОУ */
.nuczu-hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  overflow: hidden;
  isolation: isolate;
  padding: 130px 0 90px;
}

.nuczu-hero-bg {
  position: absolute;
  inset: 0;
  z-index: -3;
  background-image: var(--hero-bg);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.nuczu-hero-overlay {
  position: absolute;
  inset: 0;
  z-index: -2;
  background: linear-gradient(
    90deg,
    rgba(5, 18, 45, 0.90) 0%,
    rgba(5, 18, 45, 0.72) 45%,
    rgba(5, 18, 45, 0.42) 100%
  );
}

.nuczu-hero .container {
  position: relative;
  z-index: 2;
}

/* Стилі фотми */
.constructor-ai-helper {
  position: sticky;
  top: 90px;
  background:
    radial-gradient(circle at top right, rgba(13,110,253,.18), transparent 35%),
    linear-gradient(135deg, #ffffff, #f4f8ff);
  border: 1px solid rgba(13,110,253,.14);
  border-radius: 24px;
  padding: 22px;
  box-shadow: 0 22px 55px rgba(15, 23, 42, .08);
  transition: .3s ease;
}

.constructor-ai-helper.is-pulse {
  transform: translateY(-4px);
  box-shadow: 0 28px 70px rgba(13, 110, 253, .18);
}

.helper-head {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 14px;
}

.helper-avatar {
  width: 56px;
  height: 56px;
  border-radius: 18px;
  background: linear-gradient(135deg, #0d6efd, #7c3aed);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  animation: helperFloat 2.8s ease-in-out infinite;
}

@keyframes helperFloat {
  0%, 100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-7px);
  }
}

.helper-label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: #0d6efd;
  font-weight: 800;
}

.constructor-ai-helper h5 {
  margin: 0;
  font-weight: 900;
  color: #0f172a;
}

.constructor-ai-helper p {
  color: #475569;
}

.helper-section {
  margin-top: 14px;
}

.helper-section strong {
  display: block;
  font-size: 14px;
  margin-bottom: 8px;
  color: #0f172a;
}

.helper-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.helper-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(13,110,253,.09);
  color: #0d6efd;
  font-size: 13px;
  font-weight: 700;
}

.helper-chips.muted .helper-chip {
  background: #f1f5f9;
  color: #64748b;
}

.helper-example {
  margin-top: 16px;
  padding: 14px;
  border-radius: 18px;
  background: #fff;
  border: 1px solid #e2e8f0;
}

.helper-example p {
  margin: 6px 0 0;
}

.helper-tip {
  margin-top: 14px;
  padding: 13px 14px;
  border-radius: 18px;
  background: linear-gradient(135deg, #eef6ff, #f5f3ff);
  color: #334155;
  font-weight: 700;
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.helper-tip i {
  color: #7c3aed;
  font-size: 20px;
}

/* Поля форми */

.constructor-field {
  position: relative;
  border-radius: 18px;
  padding: 14px;
  margin-bottom: 14px;
  border: 1px solid transparent;
  transition: .25s ease;
}

.constructor-field.field-required {
  background: #f0f7ff;
  border-color: rgba(13,110,253,.35);
  box-shadow: 0 10px 28px rgba(13,110,253,.08);
}

.constructor-field.field-optional {
  background: #f8fafc;
  border-color: #e2e8f0;
}

.constructor-field.field-muted {
  opacity: .45;
  filter: grayscale(.45);
  background: #f8fafc;
}

.constructor-field.field-required::after {
  content: "рекомендовано";
  position: absolute;
  top: 10px;
  right: 12px;
  font-size: 11px;
  font-weight: 800;
  color: #0d6efd;
  background: #fff;
  border-radius: 999px;
  padding: 4px 8px;
}

.constructor-field.field-muted::after {
  content: "не потрібно";
  position: absolute;
  top: 10px;
  right: 12px;
  font-size: 11px;
  font-weight: 800;
  color: #64748b;
  background: #fff;
  border-radius: 999px;
  padding: 4px 8px;
}

/* Пошук по типовій сторінці */




  /* =========================================================
     Sticky search + page section navigation
  ========================================================= */

  .upb-page-search-sticky {
    position: sticky;
    top: 96px;
    z-index: 60;
    margin-top: -26px;
    margin-bottom: 28px;
    pointer-events: none;
}

  .upb-page-search-sticky .container,
  .upb-page-search-sticky .row,
  .upb-page-search-sticky [class*="col-"] {
    pointer-events: none;
  }

  .upb-hero-search-card,
  .upb-section-nav-card {
    pointer-events: auto;
  }

  .upb-hero-search-card {
    width: 100%;
    min-height: 42px;

    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;

    background: rgba(255, 255, 255, .97);
    border: 1px solid rgba(226, 232, 240, .95);
    border-radius: 999px;
    padding: 5px 10px 5px 14px;

    box-shadow: 0 12px 30px rgba(15, 23, 42, .12);
    backdrop-filter: blur(14px);
  }

  .upb-hero-search-input-wrap {
    flex: 1;
    min-width: 0;

    display: flex;
    align-items: center;
    gap: 10px;
  }

  .upb-hero-search-input-wrap > i {
    color: #0d6efd;
    font-size: 18px;
    flex: 0 0 auto;
  }

  .upb-hero-search-input {
    width: 100%;
    min-height: 32px;

    border: 0 !important;
    outline: 0 !important;
    background: transparent !important;
    box-shadow: none !important;

    color: #0f172a;
    font-size: 14px;
  }

  .upb-hero-search-input:focus,
  .upb-hero-search-input:focus-visible {
    border: 0 !important;
    outline: 0 !important;
    box-shadow: none !important;
  }

  .upb-hero-search-input::placeholder {
    color: #94a3b8;
  }

  .upb-hero-search-clear {
    width: 26px;
    height: 26px;
    border: 0;
    border-radius: 50%;

    background: #f1f5f9;
    color: #475569;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    font-size: 12px;
    transition: .2s ease;
  }

  .upb-hero-search-clear:hover {
    background: #e2e8f0;
    color: #0f172a;
  }

  .upb-hero-search-clear:focus,
  .upb-hero-search-clear:focus-visible {
    outline: 0 !important;
    box-shadow: none !important;
  }

  .upb-hero-search-counter {
    white-space: nowrap;
    font-size: 12px;
    font-weight: 800;
    color: #0d6efd;
    background: rgba(13, 110, 253, .09);
    padding: 5px 8px;
    border-radius: 999px;
  }

  .upb-section-nav-card {
    width: 100%;
    min-height: 42px;

    display: flex;
    align-items: center;
    gap: 12px;

    background: rgba(255, 255, 255, .97);
    border: 1px solid rgba(226, 232, 240, .95);
    border-radius: 22px;
    padding: 6px 10px;

    box-shadow: 0 12px 30px rgba(15, 23, 42, .10);
    backdrop-filter: blur(14px);
  }

  .upb-section-nav-title {
    flex: 0 0 auto;

    display: inline-flex;
    align-items: center;
    gap: 7px;

    padding: 5px 8px;
    border-radius: 999px;

    background: rgba(13, 110, 253, .08);
    color: #0d6efd;

    font-size: 12px;
    font-weight: 900;
    white-space: nowrap;
  }

  .upb-section-nav-title i {
    font-size: 15px;
  }

  .upb-section-nav-links {
    flex: 1;
    min-width: 0;

    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 7px;

    overflow: visible;
    padding-bottom: 0;
  }

  .upb-section-nav-link {
    flex: 0 1 auto;
    max-width: none;
  }

  .upb-section-nav-link span {
    white-space: normal;
    line-height: 1.2;
  }

  .upb-section-nav-link i {
    color: #0d6efd;
    font-size: 14px;
    flex: 0 0 auto;
  }

  .upb-section-nav-link:hover,
  .upb-section-nav-link.is-active {
    background: #0d6efd;
    border-color: #0d6efd;
    color: #fff;
    transform: translateY(-1px);
  }

  .upb-section-nav-link:hover i,
  .upb-section-nav-link.is-active i {
    color: #fff;
  }

  .upb-search-hidden {
    display: none !important;
  }

  .upb-section-hidden-by-search {
    display: none !important;
  }

  @media (max-width: 991.98px) {
    .upb-page-search-sticky {
      position: static;
      margin-top: -20px;
      margin-bottom: 24px;
    }

    .upb-hero-search-card,
    .upb-section-nav-card {
      border-radius: 20px;
    }

    .upb-section-nav-card {
      align-items: flex-start;
      flex-direction: column;
      gap: 8px;
    }

    .upb-section-nav-links {
      width: 100%;
    }
  }

  @media (max-width: 575.98px) {
    .upb-hero-search-card {
      align-items: stretch;
      flex-direction: column;
      border-radius: 20px;
    }

    .upb-hero-search-counter {
      width: fit-content;
    }
  }

 /* =========================================================
   Compact document block
========================================================= */

.upb-document-block {
  padding: 8px;
}

.upb-document-compact {
  display: flex;
  align-items: flex-start;
  gap: 16px;
}

.upb-document-compact-icon {
    width: 40px;
    height: 40px;
    flex: 0 0 40px;
    display: grid;
    place-items: center;
    border-radius: 16px;
    color: #fff;
    background: linear-gradient(135deg, var(--nuczu-accent), #d9480f);
    font-size: 25px;
    box-shadow: 0 12px 24px rgba(239, 102, 3, 0.20);
}

.upb-document-compact-body {
  min-width: 0;
  flex: 1 1 auto;
}

.upb-document-title-link {
  display: block;
  color: inherit;
  text-decoration: none;
}

.upb-document-title-link h3 {
  margin: 0 0 8px;
  color: var(--nuczu-blue-3);
  font-size: 11px;
  font-weight: 900;
  line-height: 1.28;
  letter-spacing: -0.01em;
}

.upb-document-title-link:hover h3 {
  color: var(--nuczu-accent);
}

.upb-document-title-link .upb-subtitle {
  margin-bottom: 10px;
}

.upb-document-title-link .upb-text {
  color: var(--nuczu-muted);
  font-size: 15px;
  line-height: 1.6;
}

.upb-document-title-link .upb-text p:last-child {
  margin-bottom: 0;
}

.upb-document-block:hover .upb-document-compact-icon {
  transform: scale(1.04);
}

@media (max-width: 575.98px) {
  .upb-document-compact {
    gap: 14px;
  }

.upb-document-compact-icon {
        width: 29px;
        height: 31px;
        flex-basis: 29px;
        font-size: 18px;
    }
}

/* ==========================================================
   NUCZU ONLY MEGA MENU
   Працює тільки для <nav class="navmenu nuczu-navmenu">
========================================================== */

@media (min-width: 1200px) {

  .nuczu-navmenu .nuczu-mega-dropdown {
    position: static;
  }

  .nuczu-navmenu .nuczu-mega-dropdown > a {
    padding: 8px 18px;
    border-radius: 50px;
    font-weight: 500;
    background: transparent;
    color: var(--nav-color);
    transition: .22s ease;
  }

  .nuczu-navmenu .nuczu-mega-dropdown > a i {
    font-size: 12px;
    margin-left: 6px;
  }

  .nuczu-navmenu .nuczu-mega-dropdown:hover > a,
  .nuczu-navmenu .nuczu-mega-dropdown > a.active {
    background: var(--accent-color);
    color: var(--contrast-color);
  }

  /* Невидимий місток між пунктом меню і dropdown.
     Саме він прибирає блимання при русі курсора вниз. */
  .nuczu-navmenu .nuczu-mega-dropdown::after {
    content: "";
    position: fixed;
    left: 0;
    right: 0;
    top: 70px;
    height: 48px;
    display: none;
    z-index: 995;
    background: transparent;
  }

  .nuczu-navmenu .nuczu-mega-dropdown:hover::after {
    display: block;
  }

  .nuczu-navmenu .nuczu-mega-menu {
    position: fixed;
    left: 0;
    right: 0;
    top: 98px;
    width: 100vw;

    background: #16283d;

    padding: 24px 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(6px);
    transition: opacity .22s ease, visibility .22s ease, transform .22s ease;

    z-index: 996;
    box-shadow: 0 18px 38px rgba(0, 0, 0, .22);
    border-top: 1px solid rgba(255, 255, 255, .07);
  }

  .nuczu-navmenu .nuczu-mega-dropdown:hover .nuczu-mega-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
  }

  .nuczu-mega-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(180px, 1fr));
    column-gap: 28px;
    row-gap: 10px;
    align-items: start;
  }

  .nuczu-mega-link {
    display: flex !important;
    align-items: center;
    gap: 9px;

    min-height: 40px;
    padding: 8px 14px !important;

    border-radius: 999px !important;
    background: transparent !important;
    color: rgba(255, 255, 255, .92) !important;

    font-size: 14px !important;
    font-weight: 600 !important;
    line-height: 1.35;
    white-space: normal !important;

    transition: .2s ease;
  }

  .nuczu-mega-link i {
    flex: 0 0 auto;
    font-size: 14px !important;
    margin-left: 0 !important;
    color: rgba(255, 255, 255, .72);
    transition: .2s ease;
  }

  .nuczu-mega-link:hover {
    color: #ffffff !important;
    background: var(--accent-color) !important;
    transform: translateX(3px);
  }

  .nuczu-mega-link:hover i {
    color: #ffffff;
  }
}
@media (min-width: 1200px) {

  .nuczu-mega-grid {
    align-items: start;
  }

  .nuczu-mega-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
  }

  .nuczu-mega-group-title {
    display: flex !important;
    align-items: center;
    gap: 8px;

    padding: 6px 10px !important;
    border-radius: 12px !important;

    color: var(--accent-color) !important;
    background: transparent !important;

    font-size: 13px !important;
    font-weight: 850 !important;
    line-height: 1.25;
    text-transform: uppercase;
    letter-spacing: .035em;

    text-decoration: none !important;
    white-space: normal !important;
  }

  .nuczu-mega-group-title:hover {
    color: #ffffff !important;
    background: rgba(239, 102, 3, .18) !important;
  }

  .nuczu-mega-sublist {
    display: flex;
    flex-direction: column;
    gap: 3px;
  }

  .nuczu-mega-sublink {
    display: flex !important;
    align-items: center;
    gap: 8px;

    min-height: 34px;
    padding: 6px 12px !important;

    border-radius: 999px !important;
    color: rgba(255, 255, 255, .9) !important;
    background: transparent !important;

    font-size: 14px !important;
    font-weight: 500 !important;
    line-height: 1.35;
    text-decoration: none !important;
    white-space: normal !important;

    transition: .2s ease;
  }

  .nuczu-mega-sublink:hover {
    color: #ffffff !important;
    background: var(--accent-color) !important;
    transform: translateX(3px);
  }
}


/* ==========================================================
   Mobile
========================================================== */

@media (max-width: 1199px) {

  .nuczu-navmenu .nuczu-mega-menu {
    display: none;

    margin: 8px 18px 12px;
    padding: 8px;

    background: rgba(33, 37, 41, .04);
    border: 1px solid rgba(0, 0, 0, .08);
    border-radius: 14px;
  }

  .nuczu-navmenu .nuczu-mega-dropdown.active .nuczu-mega-menu,
  .nuczu-navmenu .nuczu-mega-menu.dropdown-active {
    display: block;
  }

  .nuczu-mega-grid {
    display: grid;
    gap: 2px;
  }

  .nuczu-mega-link {
    display: flex !important;
    align-items: center;
    gap: 8px;

    padding: 10px 14px !important;
    border-radius: 12px !important;

    color: var(--nav-dropdown-color) !important;
    background: transparent !important;

    font-size: 15px !important;
    font-weight: 600 !important;
    line-height: 1.35;
  }

  .nuczu-mega-link:hover {
    color: var(--nav-dropdown-hover-color) !important;
    background: rgba(239, 102, 3, .08) !important;
  }

  .nuczu-mega-link i {
    font-size: 14px !important;
    margin-left: 0 !important;
  }
}
@media (max-width: 1199px) {

  .nuczu-mega-group {
    display: flex;
    flex-direction: column;
    gap: 2px;
  }

  .nuczu-mega-group-title {
    display: flex !important;
    padding: 10px 14px !important;
    border-radius: 12px !important;

    color: var(--accent-color) !important;
    background: rgba(239, 102, 3, .08) !important;

    font-size: 13px !important;
    font-weight: 850 !important;
    text-transform: uppercase;
    letter-spacing: .035em;
  }

  .nuczu-mega-sublist {
    display: flex;
    flex-direction: column;
    padding-left: 12px;
  }

  .nuczu-mega-sublink {
    display: flex !important;
    padding: 9px 14px !important;
    border-radius: 12px !important;

    color: var(--nav-dropdown-color) !important;
    background: transparent !important;

    font-size: 14px !important;
    font-weight: 500 !important;
  }

  .nuczu-mega-sublink:hover {
    color: var(--nav-dropdown-hover-color) !important;
    background: rgba(239, 102, 3, .08) !important;
  }
}


/* ==========================================================
   PERSON CARD — клік тільки по фото/тексту, не по кнопках
========================================================== */

.upb-person-click-area {
  display: block;
  color: inherit;
  text-decoration: none;
  cursor: pointer;
}

.upb-person-click-area:hover {
  color: inherit;
  text-decoration: none;
}

.upb-person-click-area h3,
.upb-person-click-area .upb-url-card-subtitle,
.upb-person-click-area .upb-text {
  transition: .22s ease;
}

.upb-person-click-area:hover h3 {
  color: var(--accent-color);
}

.upb-person-photo {
  overflow: hidden;
}

.upb-person-photo img {
  transition: .24s ease;
}

.upb-person-click-area:hover .upb-person-photo img {
  transform: scale(1.04);
}

/* щоб кнопки точно були видимі й поверх будь-яких hover-ефектів */
.upb-person-card .upb-actions {
  position: relative;
  z-index: 5;
}


/* ==========================================================
   RIGHT PAGE SECTION RAIL
   Локальна навігація по розділах конкретної сторінки
========================================================== */

.upb-page-rail {
  position: fixed;
  top: 112px;
  right: 18px;
  z-index: 1030;
  width: 150px;
  max-height: calc(100vh - 145px);
  padding: 10px;
  border: 1px solid rgba(13, 59, 102, 0.12);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 12px 32px rgba(10, 31, 68, 0.10);
  overflow-y: auto;
}

.upb-page-rail::-webkit-scrollbar {
  width: 4px;
}

.upb-page-rail::-webkit-scrollbar-thumb {
  background: rgba(13, 59, 102, 0.22);
  border-radius: 999px;
}

.upb-page-rail-title {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 8px;
  padding: 0 2px 8px;
  border-bottom: 1px solid rgba(13, 59, 102, 0.08);
  font-size: 11px;
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: rgba(13, 59, 102, 0.72);
}

.upb-page-rail-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.upb-page-rail-link {
  display: flex;
  align-items: center;
  gap: 7px;
  min-height: 30px;
  padding: 6px 8px;
  border-radius: 11px;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.15;
  color: rgba(13, 59, 102, 0.72);
  text-decoration: none;
  transition: background-color .2s ease, color .2s ease, transform .2s ease;
}

.upb-page-rail-link::before {
  content: "";
  width: 7px;
  height: 7px;
  flex: 0 0 7px;
  border-radius: 999px;
  background: rgba(13, 59, 102, 0.24);
  box-shadow: 0 0 0 3px rgba(13, 59, 102, 0.04);
  transition: background-color .2s ease, box-shadow .2s ease;
}

.upb-page-rail-link:hover {
  color: var(--nuczu-orange, #ef6603);
  background: rgba(239, 102, 3, 0.08);
  transform: translateX(-2px);
}

.upb-page-rail-link.is-active {
  color: var(--nuczu-orange, #ef6603);
  background: rgba(239, 102, 3, 0.12);
}

.upb-page-rail-link.is-active::before {
  background: var(--nuczu-orange, #ef6603);
  box-shadow: 0 0 0 4px rgba(239, 102, 3, 0.14);
}

.upb-section-group {
  scroll-margin-top: 145px;
}

/* 
  На менших desktop-екранах ховаємо, щоб rail не перекривав контент.
  За потреби поріг можна знизити до 1400px.
*/
@media (max-width: 1530px) {
  .upb-page-rail {
    display: none !important;
  }
}

/* ОГОЛОШЕННЯ НА ГОЛОВНІЙ СТОРІНЦІ */
/* =========================================================
   HERO Announcements Slider
   Напівпрозора glass-картка з адаптивним текстом
========================================================= */

.nuczu-hero-ann-card {
  position: relative;
  overflow: hidden;

  height: 370px;
  padding: 20px 22px;

  display: grid;
  grid-template-rows: auto minmax(0, 1fr);

  border-radius: 46px;
  color: #ffffff;

  background:
    linear-gradient(135deg, rgba(255, 255, 255, .24), rgba(255, 255, 255, .09)),
    radial-gradient(circle at 12% 8%, rgba(239, 102, 3, .22), transparent 34%),
    radial-gradient(circle at 92% 88%, rgba(255, 255, 255, .10), transparent 30%);

  border: 1px solid rgba(255, 255, 255, .30);

  box-shadow:
    0 34px 86px rgba(0, 0, 0, .30),
    inset 0 1px 0 rgba(255, 255, 255, .18);

  backdrop-filter: blur(22px);
}

/* затемнення для читабельності */
.nuczu-hero-ann-card::before {
  content: "";
  position: absolute;
  inset: 0;

  background:
    linear-gradient(135deg, rgba(13, 39, 66, .42), rgba(13, 39, 66, .20));

  pointer-events: none;
}

/* акцентна вертикальна смуга */
.nuczu-hero-ann-card::after {
  content: "";
  position: absolute;
  left: 0;
  top: 30px;
  bottom: 30px;

  width: 5px;
  border-radius: 999px;

  background: linear-gradient(180deg, var(--nuczu-accent), #ff9a3d);
  box-shadow: 0 0 28px rgba(239, 102, 3, .75);
}

.nuczu-hero-ann-card > * {
  position: relative;
  z-index: 2;
}

/* =========================
   Header
========================= */

.nuczu-hero-ann-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 10px;

  margin-bottom: 10px;
  padding: 7px 6px 10px 0;

  border-bottom: 1px solid rgba(255, 255, 255, .15);
}

.nuczu-hero-ann-title {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.nuczu-hero-ann-icon {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;

  display: grid;
  place-items: center;

  border-radius: 16px;

  color: #ffffff;
  background:
    linear-gradient(135deg, rgba(255,255,255,.24), rgba(255,255,255,.10));

  border: 1px solid rgba(255,255,255,.20);

  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.20),
    0 10px 22px rgba(0, 0, 0, .16);

  font-size: 19px;
}

.nuczu-hero-ann-head span {
  display: block;
  margin-bottom: 1px;

  color: rgba(255, 255, 255, .70);
  font-size: 9px;
  line-height: 1;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .11em;
}

/* слово "Оголошення" — НЕ чорне */
.nuczu-hero-ann-head h3 {
  margin: 0;

  color: #ffffff;
  text-shadow: 0 2px 12px rgba(0, 0, 0, .28);

  font-size: 18px;
  line-height: 1;
  font-weight: 950;
  letter-spacing: -.025em;
}

/* =========================
   Верхній тег + дата
========================= */

.nuczu-hero-ann-current-meta {
  display: flex;
  align-items: center;
  justify-content: flex-end;

  min-width: 88px;
}

.nuczu-hero-ann-top-meta {
  display: none;
  flex-direction: column;
  align-items: flex-end;
  gap: 3px;
}

.nuczu-hero-ann-top-meta.active {
  display: flex;
}

.nuczu-hero-ann-priority {
  display: inline-flex;
  align-items: center;
  justify-content: center;

  padding: 4px 9px;
  border-radius: 999px;

  color: #ffffff;

  font-size: 9px;
  line-height: 1;
  font-weight: 950;
  text-transform: uppercase;
  letter-spacing: .05em;

  box-shadow: 0 8px 18px rgba(0, 0, 0, .18);
}

/* Інформація */
.nuczu-hero-ann-priority--info {
  background: linear-gradient(135deg, #203955, #144274);
}

/* Важливо */
.nuczu-hero-ann-priority--important {
  background: linear-gradient(135deg, var(--nuczu-accent), #c2410c);
}

/* Терміново */
.nuczu-hero-ann-priority--urgent {
  background: linear-gradient(135deg, #dc2626, #991b1b);
}

/* Вступнику */
.nuczu-hero-ann-priority--admission {
  background: linear-gradient(135deg, #2563eb, #144274);
}

.nuczu-hero-ann-top-meta small {
  color: rgba(255, 255, 255, .72);
  font-size: 11px;
  line-height: 1;
  font-weight: 750;
}

/* =========================
   Кнопки слайдера
========================= */

.nuczu-hero-ann-controls {
  display: flex;
  align-items: center;
  gap: 6px;
  flex: 0 0 auto;
}

.nuczu-hero-ann-controls button {
  width: 36px;
  height: 36px;

  display: inline-flex;
  align-items: center;
  justify-content: center;

  border: 1px solid rgba(255, 255, 255, .25);
  border-radius: 999px;

  color: #ffffff;
  background:
    linear-gradient(135deg, rgba(255,255,255,.22), rgba(255,255,255,.08));

  box-shadow:
    0 11px 24px rgba(0, 0, 0, .18),
    inset 0 1px 0 rgba(255, 255, 255, .18);

  backdrop-filter: blur(12px);
  transition: .22s ease;
}

.nuczu-hero-ann-controls button i {
  font-size: 15px;
  line-height: 1;
}

.nuczu-hero-ann-controls button:hover {
  color: #ffffff;
  background: var(--nuczu-accent);
  border-color: rgba(255, 255, 255, .32);

  transform: translateY(-2px) scale(1.04);

  box-shadow:
    0 16px 34px rgba(239, 102, 3, .34),
    inset 0 1px 0 rgba(255, 255, 255, .20);
}

.nuczu-hero-ann-controls button:active {
  transform: translateY(0) scale(.98);
}

/* =========================
   Carousel
========================= */

.nuczu-hero-ann-carousel {
  height: 100%;
  min-height: 0;
}

.nuczu-hero-ann-carousel .carousel-inner,
.nuczu-hero-ann-carousel .carousel-item {
  height: 100%;
}

.nuczu-hero-ann-item {
  height: 100%;
  min-height: 0;

  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  gap: 10px;

  padding: 0;

  background: transparent;
  border: 0;
  box-shadow: none;
}

/* =========================
   Текстова частина
========================= */

.nuczu-hero-ann-text {
  min-height: 0;

  display: flex;
  flex-direction: column;
  justify-content: flex-start;

  padding: 6px 2px 0;
}

.nuczu-hero-ann-item h4 {
  margin: 0 0 8px;

  color: #ffffff;
  text-shadow: 0 2px 14px rgba(0, 0, 0, .28);

  font-size: clamp(18px, 1.45vw, 24px);
  line-height: 1.08;
  font-weight: 950;
  letter-spacing: -.035em;
}

.nuczu-hero-ann-item p {
  margin: 0;

  color: rgba(255, 255, 255, .86);

  font-size: 15px;
  line-height: 1.43;

  overflow: hidden;
}

/* Варіанти розміру тексту залежно від кількості символів */

/* =========================
   Текстова частина — adaptive fit
========================= */

.nuczu-hero-ann-text {
  min-height: 0;
  height: 100%;

  display: flex;
  flex-direction: column;
  justify-content: flex-start;

  padding: 8px 2px 0;
  overflow: hidden;
}

.nuczu-hero-ann-item h4 {
  margin: 0 0 10px;

  color: #ffffff;
  text-shadow: 0 2px 14px rgba(0, 0, 0, .28);

  font-size: var(--ann-title-size, 28px);
  line-height: var(--ann-title-line, 1.08);
  font-weight: 950;
  letter-spacing: -.035em;
}

.nuczu-hero-ann-item p {
  margin: 0;

  color: rgba(255, 255, 255, .88);

  font-size: var(--ann-text-size, 17px);
  line-height: var(--ann-text-line, 1.45);
  font-weight: 650;

  overflow: hidden;
}

/* кнопка нижче, але не краде багато місця */
.nuczu-hero-ann-link {
  margin-top: 10px;
}
/* =========================
   Кнопка "Детальніше"
========================= */

.nuczu-hero-ann-link {
  width: fit-content;

  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;

  min-height: 36px;
  padding: 8px 14px;

  border-radius: 999px;

  color: #ffffff;
  background:
    linear-gradient(135deg, var(--nuczu-accent), #ff8a2a);

  font-size: 12px;
  line-height: 1;
  font-weight: 900;
  text-decoration: none;

  box-shadow:
    0 14px 30px rgba(239, 102, 3, .32),
    inset 0 1px 0 rgba(255,255,255,.18);

  transition: .22s ease;
}

.nuczu-hero-ann-link:hover {
  color: #ffffff;
  transform: translateY(-2px) scale(1.02);
  box-shadow:
    0 18px 38px rgba(239, 102, 3, .38),
    inset 0 1px 0 rgba(255,255,255,.20);
}

/* =========================
   Empty state
========================= */

.nuczu-hero-ann-empty {
  height: 100%;
  min-height: 0;

  display: grid;
  place-items: center;
  text-align: center;

  padding: 24px;
}

.nuczu-hero-ann-empty i {
  font-size: 34px;
  color: rgba(255, 255, 255, .84);
}

.nuczu-hero-ann-empty p {
  margin: 8px 0 0;
  color: rgba(255, 255, 255, .80);
}

/* =========================
   Mobile
========================= */

@media (max-width: 991.98px) {
  .nuczu-hero-ann-card {
    height: auto;
    min-height: 330px;
    padding: 20px;
    border-radius: 34px;
  }

  .nuczu-hero-ann-item {
    min-height: 235px;
  }
}

@media (max-width: 575.98px) {
  .nuczu-hero-ann-card {
    border-radius: 30px;
  }

  .nuczu-hero-ann-head {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .nuczu-hero-ann-current-meta {
    grid-column: 1 / 2;
    justify-content: flex-start;
    margin-left: 48px;
  }

  .nuczu-hero-ann-controls {
    grid-column: 2 / 3;
    grid-row: 1 / 3;
  }

  .nuczu-hero-ann-icon {
    width: 36px;
    height: 36px;
    flex-basis: 36px;
    font-size: 18px;
  }

  .nuczu-hero-ann-head h3 {
    font-size: 17px;
  }

  .nuczu-hero-ann-controls button {
    width: 33px;
    height: 33px;
  }

  .nuczu-hero-ann-item.ann-text-short h4 {
    font-size: 24px;
  }

  .nuczu-hero-ann-item.ann-text-short p {
    font-size: 16px;
  }

  .nuczu-hero-ann-item.ann-text-long p,
  .nuczu-hero-ann-item.ann-text-xl p {
    -webkit-line-clamp: 12;
  }
}