/* DonNTU Heritage — Design System v9 · DonNTU brand book · Open Sans */
@import url('https://fonts.googleapis.com/css2?family=Open+Sans:wght@300;400;500;600;700;800&family=Playfair+Display:wght@400;500;600;700&family=IBM+Plex+Mono:wght@400;500;700&display=swap');

:root {
  /* ── DonNTU brand book backgrounds ── */
  --bg:      #FFFFFF;
  --s1:      #F7F8FA;
  --s2:      #EDEEF0;
  --surface: #F7F8FA;

  /* ── borders ── */
  --b1: #E2E4E8;
  --b2: #CECFD3;
  --b3: #B0B2B8;
  --border:   #E2E4E8;
  --border-h: #CECFD3;

  /* ── Glass / surface ── */
  --glass:   rgba(255,255,255,0.92);
  --glass-2: rgba(0,0,0,0.03);

  /* ── DonNTU brand book primary palette ── */
  --navy:      #1b3769;   /* DonNTU primary blue (brand book) */
  --navy-d:    #122747;   /* deep navy */
  --navy-l:    #4869d6;   /* lighter navy used in nav */
  --maroon:    #7a0a0a;   /* DonNTU heritage maroon */
  --maroon-d:  #500000;
  --brand-org: #f26522;   /* DonNTU CTA orange (brand book) */
  --brand-org-d:#d65515;

  /* ── Accent palette (CTA + state) ── */
  --ac:      #f26522;     /* primary CTA orange */
  --ac2:     #d65515;
  --acg:     rgba(242,101,34,0.08);
  --lime:    #f26522;
  --sky:     #4869d6;
  --gr:      #098e00;     /* DonNTU green */
  --roboto:  'Open Sans', 'Helvetica Neue', Arial, sans-serif;

  /* Legacy aliases — mapped to DonNTU palette */
  --amber:   #f26522;     /* was WUF orange → DonNTU CTA orange */
  --amber-d: #d65515;
  --amber-g: rgba(242,101,34,0.08);
  --slate:   #1b3769;     /* now DonNTU navy (was generic slate-blue) */
  --sage:    #098e00;     /* DonNTU green */
  --rust:    #7a0a0a;     /* DonNTU heritage maroon */
  --violet:  #4869d6;     /* DonNTU light navy */

  /* ── WUF13 text ── */
  --t1: #111214;   /* nearly black */
  --t2: #3D4148;   /* dark gray */
  --t3: #7A7E87;   /* muted */
  --t4: #C8CAD0;   /* very light (for dark-on-light reversed use) */

  /* ── DonNTU brand book fonts — Open Sans (per donntu.edu.ua) ── */
  --display: 'Open Sans', 'Helvetica Neue', Arial, sans-serif;
  --serif:   'Playfair Display', Georgia, serif;
  --sans:    'Open Sans', 'Helvetica Neue', Arial, sans-serif;
  --mono:    'IBM Plex Mono', 'Menlo', monospace;

  --ease:  cubic-bezier(.16,1,.3,1);

  /* ── WUF13 border-radius ── */
  --r-sm: 3px;
  --r-md: 4px;
  --r-lg: 6px;
}

*,*::before,*::after { margin:0; padding:0; box-sizing:border-box; }
/* WUF13 base = 16px (Jost) */
html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
  -ms-text-size-adjust: 100%;
  text-size-adjust: 100%;
  overflow-x: hidden;
  width: 100%;
}
html, body { height: 100%; }
body {
  font-family: var(--sans);
  font-size: 1rem;
  font-weight: 400;
  line-height: 1.5;
  color: var(--t1);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow: hidden;
  overflow-x: hidden;
  width: 100%;
  max-width: 100%;
}
#root { height: 100%; width: 100%; }

/* ── TYPOGRAPHY ── */
.display   { font-family: var(--display); letter-spacing: 0.04em; }
.display-i { font-family: var(--display); font-style: italic; }
.serif     { font-family: var(--sans); font-weight: 400; }
.serif-i   { font-family: var(--sans); font-style: italic; font-weight: 400; }
.mono      { font-family: var(--mono); }
.lbl {
  font-family: var(--mono);
  font-size: 0.625rem;
  font-weight: 400;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--t3);
  display: inline-block;
}
.lbl-amber  { color: var(--ac); }
.lbl-gold   { color: var(--ac); }
.lbl-dim    { color: var(--t3); }
.lbl-lime   { color: var(--ac); }
.lbl-violet { color: var(--violet); }
.lbl-sage   { color: var(--sage); }
.lbl-slate  { color: var(--slate); }
.lbl-rust   { color: var(--rust); }
.t2  { color: var(--t2); }
.t3  { color: var(--t3); }
.tg  { color: var(--ac); }
.tc  { color: var(--slate); }
.tgr { color: var(--gr); }

/* WUF13 exact: h2=40px/48px, p=24px/32px, body=16px — all Jost */
.h1 { font-family: var(--display); font-size: clamp(2.5rem,5vw,4rem); font-weight: 700; line-height: 1.05; letter-spacing: -0.01em; }
.h2 { font-family: var(--display); font-size: 2.5rem; font-weight: 400; line-height: 1.2; letter-spacing: 0; }
.h3 { font-family: var(--display); font-size: 1.5rem; font-weight: 600; line-height: 1.3; }
.h4 { font-family: var(--display); font-size: 1rem; font-weight: 600; line-height: 1.3; }
.h1 em, .h2 em { font-style: italic; color: var(--ac); }

.body   { font-size: 1rem; line-height: 1.65; color: var(--t2); }
.caption { font-size: 0.8rem; color: var(--t3); }

/* ══ SHELL — WUF13: navbar + full-width main ══ */
.shell { height: 100%; display: flex; flex-direction: column; position: relative; z-index: 1; }
.main {
  flex: 1; overflow-y: auto; overflow-x: hidden;
  padding: 0;
  scrollbar-width: thin;
  scrollbar-color: var(--b2) transparent;
  background: var(--bg);
}
.main::-webkit-scrollbar { width: 4px; }
.main::-webkit-scrollbar-thumb { background: var(--b2); border-radius: 2px; }
/* inner content wrapper for non-landing pages */
.page-inner { padding: 3rem 6vw 5rem; max-width: 1280px; margin: 0 auto; }

/* ══ WUF13 NAVBAR ══ */
.wuf-nav {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 3rem;
  height: 64px; min-height: 64px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  background: #0d0f14;
  position: sticky; top: 0; z-index: 100;
  box-shadow: 0 2px 20px rgba(0,0,0,0.4);
  gap: 2rem; flex-shrink: 0;
}
.wuf-nav-logo {
  display: flex; align-items: center; gap: 0.625rem;
  cursor: pointer; flex-shrink: 0; text-decoration: none;
}
.wuf-nav-logo-mark {
  width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.wuf-nav-logo-mark img {
  width: 100%; height: 100%; object-fit: contain;
  filter: brightness(0) invert(1);
}
.wuf-nav-logo-text { display: flex; flex-direction: column; }
.wuf-nav-brand {
  font-family: var(--display); font-size: 1.125rem; font-weight: 400;
  letter-spacing: 0.1em; color: #fff; line-height: 1;
}
.wuf-nav-sub {
  font-family: var(--mono); font-size: 0.5rem; letter-spacing: 0.12em;
  color: rgba(255,255,255,0.35); text-transform: uppercase; line-height: 1; margin-top: 2px;
}
.wuf-nav-links {
  display: flex; align-items: center; gap: 0; flex: 1; justify-content: center;
}
.wuf-nav-link {
  background: none; border: none; cursor: pointer;
  font-family: var(--sans); font-size: 0.875rem; font-weight: 600;
  color: rgba(255,255,255,0.65); padding: 0 1.125rem; height: 64px;
  display: flex; align-items: center;
  border-bottom: 3px solid transparent;
  transition: color .2s, border-color .2s;
  white-space: nowrap;
}
.wuf-nav-link:hover { color: #fff; }
.wuf-nav-link.act { color: var(--ac); border-bottom-color: var(--ac); }
.wuf-nav-cta { display: flex; align-items: center; gap: 0.75rem; flex-shrink: 0; }
.wuf-nav-btn { font-size: 0.75rem; font-weight: 700; padding: 0.55rem 1.25rem; border-radius: var(--r-md); white-space: nowrap; }
.wuf-nav-more {
  background: none; border: 1px solid rgba(255,255,255,0.15); color: rgba(255,255,255,0.5);
  width: 36px; height: 36px; border-radius: var(--r-md);
  cursor: pointer; font-size: 1rem; display: flex; align-items: center; justify-content: center;
  transition: border-color .2s, color .2s;
}
.wuf-nav-more:hover { border-color: var(--ac); color: var(--ac); }

/* ══ CARD ══ */
.gc {
  position: relative; padding: 1.5rem;
  background: var(--bg);
  border: 1px solid var(--b1);
  border-radius: var(--r-md);
  display: flex; flex-direction: column;
  transition: border-color .25s, box-shadow .25s;
}
.gc:hover { border-color: var(--b2); box-shadow: 0 2px 12px rgba(0,0,0,0.07); }
.gc-static:hover { box-shadow: none; }
.gc-amber { border-color: rgba(224,120,48,0.25); }
.gc-amber:hover { border-color: rgba(224,120,48,0.5); }
.gc-gold { border-color: rgba(224,120,48,0.25); }
.gc-gold:hover { border-color: rgba(224,120,48,0.5); }
.gc-flush { padding: 0; overflow: hidden; }
.gc-lime { border-color: rgba(224,120,48,0.25); }
.gc-lime:hover { border-color: var(--ac); }
.gc-violet { border-color: rgba(123,94,167,0.2); }
.gc-violet:hover { border-color: rgba(123,94,167,0.5); }
.gc-sage { border-color: rgba(58,140,92,0.2); }
.gc-sage:hover { border-color: rgba(58,140,92,0.5); }
.gc-slate { border-color: rgba(91,127,166,0.2); }
.gc-slate:hover { border-color: rgba(91,127,166,0.5); }
.gc-rust { border-color: rgba(192,57,43,0.2); }
.gc-rust:hover { border-color: rgba(192,57,43,0.5); }

/* corner accent — subtle */
.gc::before, .gc::after {
  content: ''; position: absolute;
  width: 8px; height: 8px;
  border-color: rgba(224,120,48,0.15); border-style: solid; pointer-events: none;
}
.gc::before { top: -1px; left: -1px; border-width: 2px 0 0 2px; border-radius: var(--r-sm) 0 0 0; }
.gc::after  { bottom: -1px; right: -1px; border-width: 0 2px 2px 0; border-radius: 0 0 var(--r-sm) 0; }
.gc-amber::before, .gc-amber::after,
.gc-gold::before,  .gc-gold::after { border-color: rgba(224,120,48,0.4); }

/* ══ BUTTONS — WUF13 orange ══ */
.btn {
  background: transparent; border: 1.5px solid var(--b2); color: var(--t2);
  font-family: var(--sans); font-size: 0.75rem;
  letter-spacing: 0.04em; font-weight: 600;
  padding: 0.6rem 1.25rem; cursor: pointer;
  transition: all .2s; border-radius: var(--r-md);
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
}
.btn:hover { border-color: var(--ac); color: var(--ac); background: var(--acg); }
/* primary = orange WUF13 */
.btn-g {
  background: var(--ac); border-color: var(--ac); color: #FFFFFF; font-weight: 700;
  border-radius: var(--r-md);
}
.btn-g:hover { background: var(--ac2); border-color: var(--ac2); color: #fff; }
.btn-amber { background: var(--ac); border-color: var(--ac); color: #FFFFFF; font-weight: 700; border-radius: var(--r-md); }
.btn-amber:hover { background: var(--ac2); border-color: var(--ac2); }
.btn-slate { background: rgba(91,127,166,0.08); border-color: rgba(91,127,166,0.3); color: var(--slate); }
.btn-slate:hover { background: rgba(91,127,166,0.16); border-color: var(--slate); }
.btn-sky { background: var(--sky); border-color: var(--sky); color: #fff; font-weight: 700; border-radius: var(--r-md); }
.btn-sm { padding: 0.35rem 0.875rem; font-size: 0.6875rem; }
.btn-full { width: 100%; justify-content: space-between; }

/* ══ BADGE / STATUS ══ */
.badge {
  display: inline-flex; align-items: center; gap: 0.375rem;
  padding: 0.2rem 0.625rem;
  border: 1px solid var(--b1);
  border-radius: var(--r-sm);
  font-family: var(--mono); font-size: 0.5625rem; letter-spacing: 0.1em;
  background: var(--s1);
}
.badge-dot { width: 5px; height: 5px; border-radius: 50%; }

/* ══ STAT ══ */
.stat {
  padding: 14px 12px;
  background: var(--s1);
  border: 1px solid var(--b1);
  border-radius: var(--r-md);
  transition: border-color .25s;
}
.stat:hover { border-color: var(--ac); }
.stat-v { font-family: var(--display); font-size: 2.5rem; font-weight: 400; line-height: 1; margin-bottom: 6px; color: var(--ac); letter-spacing: 0.04em; }
.stat-l { font-family: var(--mono); font-size: 0.5625rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--t3); display: block; }

/* ══ PROGRESS ══ */
.bar { height: 3px; background: var(--b1); overflow: hidden; border-radius: 2px; }
.bar-fill { height: 100%; background: var(--ac); transition: width .6s var(--ease); border-radius: 2px; }
.bar-fill.bar-c { background: var(--slate); }
.bar-fill.bar-g { background: var(--gr); }
.bar-fill.bar-lime { background: var(--ac); }

.pdots { display: flex; gap: 3px; font-size: 0.5625rem; }
.pd-f { color: var(--ac); }
.pd-e { color: var(--b2); }

/* ══ DIVIDER ══ */
.div-row { display: flex; align-items: center; gap: 1rem; margin: 1.5rem 0; }
.div-line { flex: 1; height: 1px; background: var(--b1); }

/* ══ PAGE TRANSITIONS ══ */
.page { opacity: 1; }
.page.page-anim { animation: pgIn .35s var(--ease); }
@keyframes pgIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* ══ MODAL ══ */
.modal-bg {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(0,0,0,0.4);
  display: flex; align-items: center; justify-content: center;
  padding: 2rem;
}
.modal { max-width: 680px; width: 100%; max-height: 85vh; overflow-y: auto; position: relative;
  background: var(--bg); border: 1px solid var(--b1); border-radius: var(--r-lg);
  box-shadow: 0 8px 40px rgba(0,0,0,0.15);
}
.modal-close {
  position: absolute; top: 1rem; right: 1rem;
  background: none; border: none; color: var(--t3);
  font-size: 0.875rem; cursor: pointer; font-family: var(--mono);
  transition: color .2s;
}
.modal-close:hover { color: var(--t1); }

/* ══ RESPONSIVE ══ */
@media (max-width: 1024px) {
  .top-nav { display: none; }
  .side { width: 64px; min-width: 64px; }
  .side-hdr { padding: 0 0.75rem 0.75rem; }
  .si { grid-template-columns: 1fr; padding: 0.875rem 0.5rem; justify-items: center; gap: 0; }
  .si:hover { padding-left: 0.5rem; }
  .si-label { display: none; }
  .si-mark { display: none; }
  .main { padding: 0; }
  .sbar-l span:nth-child(n+3), .sbar-r span:nth-child(n+3) { display: none; }
}
@media (max-width: 720px) {
  .side { display: none; }
  .sbar-r { display: none; }
  .main { padding: 0; }
  .top-r > *:nth-child(1) { display: none; }
}

@keyframes shimmer {
  0%   { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}
