@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500&display=swap');

html { font-size: 110%; }
body { font-family: 'Inter', sans-serif !important; }
.mono { font-family: 'JetBrains Mono', monospace !important; font-size: 12px !important; font-weight: 500 !important; }

/* ── RUBY THEME ── */
:root {
  --tblr-primary:          #BA1A32;
  --tblr-primary-rgb:      186, 26, 50;
  --tblr-primary-lt:       #fef2f2;
  --tblr-primary-lt-rgb:   248, 228, 231;
  --tblr-primary-darken:   #9A152A;
  --tblr-link-color:       #BA1A32;
  --tblr-link-hover-color: #9A152A;
}

/* ── NAVBAR ── */
header.navbar {
  border-bottom: 2px solid #BA1A32 !important;
  box-shadow: none !important;
}

/* Nav-link — без будь-яких ліній */
.navbar-nav .nav-link {
  text-decoration: none !important;
  border: none !important;
  border-bottom: none !important;
  box-shadow: none !important;
}
.navbar-nav .nav-link:focus,
.navbar-nav .nav-link:active,
.navbar-nav .nav-link:hover {
  text-decoration: none !important;
  border: none !important;
  border-bottom: none !important;
  box-shadow: none !important;
}

/* Активний пункт — тільки колір тексту */
.navbar-nav .nav-item.active .nav-link {
  color: #BA1A32 !important;
  font-weight: 600 !important;
}

/* Hover */
.navbar-nav .nav-link:hover { color: #BA1A32 !important; }

/* ── АВАТАР ── */
.avatar { background-color: #BA1A32 !important; color: #fff !important; }

/* ── КНОПКИ ── */
.btn-primary,
button.btn-primary,
a.btn-primary {
  background-color: #BA1A32 !important;
  border-color: #BA1A32 !important;
  color: #fff !important;
}
.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active,
.btn-primary:not(:disabled):not(.disabled):active {
  background-color: #9A152A !important;
  border-color: #9A152A !important;
}
.btn-outline-primary {
  color: #BA1A32 !important;
  border-color: #BA1A32 !important;
}
.btn-outline-primary:hover,
.btn-outline-primary:focus {
  background-color: #BA1A32 !important;
  border-color: #BA1A32 !important;
  color: #fff !important;
}

/* Логін кнопка — максимальна специфічність */
button#btn-login.btn.btn-primary.w-100 {
  background-color: #BA1A32 !important;
  border-color: #BA1A32 !important;
  color: #fff !important;
}
button#btn-login.btn.btn-primary.w-100:hover {
  background-color: #9A152A !important;
  border-color: #9A152A !important;
}

/* ── ФОРМИ ── */
.form-control:focus,
.form-select:focus {
  border-color: #BA1A32 !important;
  box-shadow: 0 0 0 .25rem rgba(186,26,50,.15) !important;
}
.form-check-input:checked {
  background-color: #BA1A32 !important;
  border-color: #BA1A32 !important;
}


/* ── DROPDOWN ── */
.dropdown-item.active,
.dropdown-item:active {
  background-color: #BA1A32 !important;
}

/* ── PAGINATION ── */
.page-item.active .page-link {
  background-color: #BA1A32 !important;
  border-color: #BA1A32 !important;
}

/* ── BADGES ── */
.badge.bg-primary { background-color: #BA1A32 !important; }
.badge.bg-success-lt { background-color: #16a34a !important; color: #fff !important; border: none !important; }
.badge.bg-secondary-lt { background-color: #64748b !important; color: #fff !important; border: none !important; }
.badge.bg-warning-lt { background-color: #d97706 !important; color: #fff !important; border: none !important; }

/* ── ТАБЛИЦЯ ── */
.mono.text-primary, a.mono { color: #BA1A32 !important; }

/* Зебра */
.table tbody tr:nth-child(odd) td  { background-color: #ffffff !important; }
.table tbody tr:nth-child(even) td { background-color: #f4f6f9 !important; }
.table-hover tbody tr:hover td,
.table tbody tr:hover td { background-color: #fef2f2 !important; }
.table-clickable tbody tr { cursor: pointer; }

/* Контрастніший текст */
.table tbody td { color: #1e293b !important; }
.table thead th { color: #475569 !important; background-color: #eef0f4 !important; }

/* ── BLOCK LABEL ── */
.block-label {
  color: #BA1A32 !important;
  border-left: 2px solid #BA1A32;
  padding-left: 8px;
}

/* ── ФОН ── */
body,
.page-wrapper { background-color: #d4d9e3 !important; }

/* ── LAYOUT ── */
.floating-bar {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1050;
  white-space: nowrap;
}

/* ── АНІМАЦІЯ ПЕРЕХОДІВ ── */
body {
  opacity: 1;
  transition: opacity 150ms ease;
}


/* ── LOADING SPINNER ── */
#mp-spinner {
  position: fixed;
  inset: 0;
  background: #d4d9e3;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: opacity 200ms ease;
}
#mp-spinner.hide {
  opacity: 0;
  pointer-events: none;
}
@keyframes mp-pulse {
  0%, 100% { opacity: .25; transform: scale(.97); }
  50%       { opacity: 1;   transform: scale(1); }
}
.mp-logo-pulse {
  text-align: left;
  animation: mp-pulse 1.6s ease infinite;
}
.mp-logo-pulse .mp-l1 {
  font-family: Arial, sans-serif;
  font-size: 22px;
  font-weight: 900;
  color: #1a1a1a;
  line-height: 1.1;
}
.mp-logo-pulse .mp-l1 span { color: #BA1A32; }
.mp-logo-pulse .mp-l2 {
  font-family: Arial, sans-serif;
  font-size: 22px;
  font-weight: 900;
  color: #94a3b8;
  line-height: 1.1;
}

/* ── PRINT ── */
@media print {
  header.navbar, .btn, .floating-bar, .no-print { display: none !important; }
}
