/* ============================================================
   Talent App — main.css
   Navy/Green paleta. Čisti CSS bez frameworka.
   ============================================================ */

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

/* ── RESET & ROOT ─────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --navy:        #0C1A2E;
  --navy2:       #132238;
  --navy3:       #1A2F47;
  --green:       #059669;
  --green-dark:  #047857;
  --green-light: #D1FAE5;
  --green-soft:  rgba(5,150,105,0.08);
  --teal:        #0D9488;

  --text:        #0F172A;
  --text2:       #475569;
  --text3:       #64748B;
  --bg:          #F8FAFC;
  --card:        #FFFFFF;
  --border:      rgba(0,0,0,0.06);
  --border2:     rgba(0,0,0,0.10);

  --r:           10px;
  --r2:          14px;
  --r3:          20px;
  --sh:          0 1px 2px rgba(0,0,0,0.04), 0 2px 4px rgba(0,0,0,0.04), 0 4px 8px rgba(0,0,0,0.02);
  --sh2:         0 4px 8px rgba(0,0,0,0.04), 0 8px 16px rgba(0,0,0,0.06), 0 16px 32px rgba(0,0,0,0.04);
  --sh3:         0 8px 16px rgba(0,0,0,0.06), 0 16px 32px rgba(0,0,0,0.08), 0 32px 64px rgba(0,0,0,0.06);

  --nav-h:       56px;
  --content-max: 1320px;
  --ease:        cubic-bezier(0.4,0,0.2,1);
}

html, body {
  font-family: 'Inter', -apple-system, sans-serif;
  font-size: 14px;
  line-height: 1.5;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }

/* ── TOP NAV ──────────────────────────────────────────────── */
.topnav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--navy);
  height: var(--nav-h);
  border-bottom: 1px solid rgba(255,255,255,0.06);
  box-shadow: 0 1px 0 rgba(0,0,0,0.2);
}

.topnav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: var(--content-max);
  margin: 0 auto;
  padding: 0 24px;
  height: 100%;
  gap: 16px;
}

.topnav-left  { display: flex; align-items: center; gap: 28px; }
.topnav-right { display: flex; align-items: center; gap: 12px; }

.brand {
  font-size: 15px;
  font-weight: 700;
  color: #F8FAFC;
  letter-spacing: -0.02em;
  white-space: nowrap;
}

/* Nav links */
.nav-links { display: flex; gap: 4px; }

.nav-link {
  padding: 6px 12px;
  border-radius: var(--r);
  color: rgba(255,255,255,0.5);
  font-size: 13.5px;
  font-weight: 500;
  transition: color 0.2s var(--ease), background 0.2s var(--ease);
  white-space: nowrap;
  position: relative;
}
.nav-link:hover { color: #E2E8F0; background: rgba(255,255,255,0.06); }
.nav-link.active {
  color: #6EE7B7;
  background: transparent;
}
.nav-link.active::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 8px;
  right: 8px;
  height: 2px;
  background: #6EE7B7;
  border-radius: 1px;
}

/* Period badge */
.period-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: var(--r);
  padding: 4px 12px;
  white-space: nowrap;
}
.period-label { font-size: 12px; font-weight: 600; color: #6EE7B7; }
.period-sep   { color: rgba(255,255,255,0.2); font-size: 12px; }
.period-dl    { font-size: 11px; color: rgba(255,255,255,0.35); }

/* Avatar dropdown */
.avatar-wrap { position: relative; cursor: pointer; }

.avatar {
  width: 34px; height: 34px;
  border-radius: 9px;
  background: linear-gradient(135deg, var(--green), var(--teal));
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 700; color: #fff;
  box-shadow: 0 2px 8px rgba(5,150,105,0.3);
  user-select: none;
}

.avatar-menu {
  display: none;
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--r2);
  box-shadow: var(--sh3);
  min-width: 180px;
  overflow: hidden;
  z-index: 200;
}
.avatar-wrap.open .avatar-menu { display: block; }

.avatar-menu-header {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
}
.avatar-menu-name { font-size: 13px; font-weight: 600; color: var(--text); }
.avatar-menu-role { font-size: 11px; color: var(--text3); margin-top: 2px; }

.avatar-menu-item {
  display: block;
  padding: 10px 16px;
  font-size: 13px;
  color: var(--text2);
  transition: background 0.1s;
}
.avatar-menu-item:hover { background: var(--bg); }
.avatar-menu-item.logout { color: #DC2626; }

/* ── MAIN CONTENT ─────────────────────────────────────────── */
.main-content {
  max-width: var(--content-max);
  margin: 0 auto;
  padding: 36px 32px 60px;
}

/* ── PAGE HEADER ──────────────────────────────────────────── */
.page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 32px;
}
.page-header h1 {
  font-size: 28px;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.04em;
}
.page-sub {
  font-size: 13px;
  color: var(--text3);
  margin-top: 3px;
}

/* ── CARD ─────────────────────────────────────────────────── */
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--r2);
  padding: 28px;
  box-shadow: var(--sh);
  transition: box-shadow 0.2s var(--ease);
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border);
}
.card-title {
  font-size: 15px;
  font-weight: 650;
  color: var(--text);
  letter-spacing: -0.01em;
}

/* ── METRIC CARDS ─────────────────────────────────────────── */
.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.metric-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--r2);
  padding: 22px 24px;
  box-shadow: var(--sh);
  transition: box-shadow 0.2s var(--ease), transform 0.2s var(--ease);
  position: relative;
  overflow: hidden;
  border-left: 4px solid var(--border);
}
.metric-card:hover {
  box-shadow: var(--sh2);
  transform: translateY(-1px);
}
.metric-card:nth-child(1) { border-left-color: #059669; }
.metric-card:nth-child(2) { border-left-color: #1976d2; }
.metric-card:nth-child(3) { border-left-color: #D97706; }
.metric-card:nth-child(4) { border-left-color: #7C3AED; }

.metric-label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text3);
  margin-bottom: 8px;
}
.metric-value {
  font-size: 36px;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.03em;
  line-height: 1.1;
}
.metric-total { font-size: 18px; font-weight: 400; color: var(--text3); }
.metric-sub   { font-size: 13px; font-weight: 400; color: var(--text3); margin-top: 4px; }
.metric-sub.text-green { color: #059669; font-weight: 500; }
.metric-sub.text-amber { color: #D97706; font-weight: 500; }
.metric-sub.text-red   { color: #DC2626; font-weight: 500; }

/* ── TEAM LIST ────────────────────────────────────────────── */
.team-list { display: flex; flex-direction: column; gap: 16px; }

.team-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: #fff;
  border: 1px solid rgba(0,0,0,0.06);
  border-radius: 14px;
  margin-bottom: 0;
  box-shadow: 0 1px 2px rgba(0,0,0,0.04), 0 2px 4px rgba(0,0,0,0.03);
  transition: box-shadow 0.2s var(--ease), border-color 0.2s var(--ease);
}
.team-row:hover {
  border-color: rgba(5,150,105,0.15);
  box-shadow: 0 4px 8px rgba(0,0,0,0.04), 0 8px 16px rgba(0,0,0,0.06);
}

.team-avatar {
  width: 36px; height: 36px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 700;
  flex-shrink: 0;
  background: linear-gradient(135deg, var(--green), var(--teal));
  color: #fff;
  letter-spacing: 0.02em;
}

.team-info { flex: 1; min-width: 0; overflow: hidden; }
.team-name {
  font-size: 14px;
  font-weight: 700;
  color: #0F172A;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.team-role {
  font-size: 11px;
  font-weight: 500;
  color: #64748B;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.team-pills { display: flex; gap: 5px; flex-shrink: 0; align-items: center; flex-wrap: nowrap; }
.team-pills .pill { font-size: 10px; padding: 2px 8px; white-space: nowrap; }
.team-scores { display: flex; gap: 6px; flex-shrink: 0; }

.score-chip {
  font-size: 11px;
  font-weight: 600;
  color: var(--text2);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 2px 8px;
}

/* ── PILLS ────────────────────────────────────────────────── */
.pill {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 99px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.02em;
  white-space: nowrap;
}
.pill-green  { background: rgba(5,150,105,0.10);  color: #059669; }
.pill-amber  { background: rgba(245,158,11,0.10); color: #D97706; }
.pill-red    { background: rgba(220,38,38,0.10);  color: #DC2626; }
.pill-blue   { background: rgba(59,130,246,0.10); color: #2563EB; }
.pill-purple { background: rgba(139,92,246,0.10); color: #7C3AED; }
.pill-gray   { background: #F1F5F9; color: #64748B; }

/* ── PROGRESS STRIP ───────────────────────────────────────── */
.progress-strip {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--r2);
  padding: 14px 18px;
}
.progress-bar-wrap {
  flex: 1;
  height: 6px;
  background: #E2E8F0;
  border-radius: 99px;
  overflow: visible;
  position: relative;
}
.progress-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #059669, #0D9488);
  border-radius: 99px;
  transition: width 0.6s cubic-bezier(0.4,0,0.2,1);
  min-width: 4px;
  position: relative;
}
.progress-bar-fill::after {
  content: '';
  position: absolute;
  right: -6px;
  top: 50%;
  transform: translateY(-50%);
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #fff;
  border: 2.5px solid #059669;
  box-shadow: 0 0 0 3px rgba(5,150,105,0.15), 0 2px 6px rgba(0,0,0,0.12);
}
.progress-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text2);
  white-space: nowrap;
}

/* ── RATING WIDGET (slider za ocjene) ────────────────────── */
.rating-item {
  padding: 20px 0;
  border-bottom: 1px solid #F1F5F9;
}
.rating-item:last-child { border-bottom: none; }

.rating-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 6px;
  gap: 12px;
}
.rating-title {
  font-size: 15px;
  font-weight: 650;
  color: var(--text);
  letter-spacing: -0.01em;
  line-height: 1.3;
}
.rating-value {
  font-size: 24px;
  font-weight: 800;
  color: #059669;
  min-width: 32px;
  text-align: right;
  letter-spacing: -0.03em;
  line-height: 1;
  flex-shrink: 0;
}
.rating-def {
  font-size: 13px;
  color: #64748B;
  margin-bottom: 12px;
  line-height: 1.5;
}

.rating-slider {
  width: 100%;
  -webkit-appearance: none;
  appearance: none;
  height: 4px;
  border-radius: 99px;
  background: #E2E8F0;
  outline: none;
  cursor: pointer;
  transition: background 0.2s var(--ease);
}
.rating-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #fff;
  border: 2.5px solid #059669;
  box-shadow: 0 0 0 4px rgba(5,150,105,0.12), 0 2px 8px rgba(0,0,0,0.15);
  cursor: pointer;
  transition: box-shadow 0.2s var(--ease), transform 0.15s var(--ease);
}
.rating-slider::-webkit-slider-thumb:hover {
  box-shadow: 0 0 0 6px rgba(5,150,105,0.16), 0 2px 10px rgba(0,0,0,0.18);
  transform: scale(1.08);
}
.rating-slider:active::-webkit-slider-thumb {
  transform: scale(0.95);
  box-shadow: 0 0 0 8px rgba(5,150,105,0.12), 0 2px 6px rgba(0,0,0,0.12);
}
.rating-slider::-moz-range-thumb {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #fff;
  border: 2.5px solid #059669;
  box-shadow: 0 0 0 4px rgba(5,150,105,0.12), 0 2px 8px rgba(0,0,0,0.15);
  cursor: pointer;
  transition: box-shadow 0.2s var(--ease);
}
.rating-slider::-moz-range-thumb:hover {
  box-shadow: 0 0 0 6px rgba(5,150,105,0.16), 0 2px 10px rgba(0,0,0,0.18);
}
.rating-slider::-moz-range-track {
  height: 4px;
  border-radius: 99px;
  background: #E2E8F0;
}
.rating-slider::-moz-range-progress {
  height: 4px;
  border-radius: 99px;
  background: linear-gradient(90deg, #059669, #0D9488);
}

.rating-scale {
  display: flex;
  justify-content: space-between;
  margin-top: 6px;
  font-size: 11px;
  font-weight: 500;
  color: #94A3B8;
  padding: 0 2px;
  user-select: none;
}

/* ── FORM ELEMENTS ────────────────────────────────────────── */
.two-col-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid #E2E8F0;
  border-radius: var(--r);
  font-family: inherit;
  font-size: 13px;
  color: var(--text);
  background: var(--card);
  resize: vertical;
  transition: border-color 0.15s var(--ease), box-shadow 0.15s var(--ease);
  line-height: 1.6;
}
.textarea::placeholder { color: #94A3B8; font-style: normal; }
.textarea:hover { border-color: #CBD5E1; }
.textarea:focus {
  outline: none;
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(5,150,105,0.08);
}

.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 16px;
}

.comment-box {
  background: #F0FDF4;
  border: 1px solid #BBF7D0;
  border-left: 3px solid var(--green);
  border-radius: var(--r);
  padding: 16px 20px;
}
.comment-label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--green-dark);
  margin-bottom: 6px;
}
.comment-text { font-size: 13px; color: var(--text2); line-height: 1.6; }

/* ── BUTTONS ──────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 22px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: all 0.2s var(--ease);
  white-space: nowrap;
  font-family: inherit;
  letter-spacing: 0.01em;
}
.btn-primary {
  background: var(--green);
  color: #fff;
  box-shadow: 0 1px 4px rgba(5,150,105,0.25);
}
.btn-primary:hover {
  background: var(--green-dark);
  box-shadow: 0 6px 20px rgba(5,150,105,0.38);
  filter: brightness(1.04);
}
.btn-secondary {
  background: #F1F5F9;
  color: #334155;
  border: none;
}
.btn-secondary:hover {
  background: #E2E8F0;
}
.btn-outline {
  background: transparent;
  color: var(--green);
  border: 1px solid var(--green);
}
.btn-outline:hover {
  background: var(--green-soft);
  box-shadow: 0 2px 8px rgba(5,150,105,0.12);
}
.btn-ghost {
  background: transparent;
  color: var(--text2);
  border: 1px solid var(--border);
}
.btn-ghost:hover { background: var(--bg); color: var(--text); }
.btn-sm { padding: 5px 12px; font-size: 12px; }
.btn-full { width: 100%; justify-content: center; }

/* ── ALERTS ───────────────────────────────────────────────── */
.alert {
  padding: 14px 18px;
  border-radius: var(--r);
  font-size: 13px;
  font-weight: 500;
  margin-bottom: 16px;
}
.alert-error {
  background: #FEF2F2;
  border: 1px solid #FECACA;
  color: #991B1B;
}
.alert-success {
  background: #F0FDF4;
  border: 1px solid #BBF7D0;
  color: #065F46;
  padding: 14px 18px;
  border-radius: var(--r);
  font-size: 13px;
  font-weight: 500;
  margin-bottom: 14px;
}

/* ── EMPTY STATE ──────────────────────────────────────────── */
.empty-state {
  text-align: center;
  padding: 64px 32px;
  background: transparent;
}
.empty-icon  { font-size: 56px; margin-bottom: 16px; display: inline-block; }
.empty-title { font-size: 18px; font-weight: 700; color: var(--text); margin-bottom: 8px; }
.empty-sub   { font-size: 14px; font-weight: 400; color: var(--text3); }

/* ── UTILITY ──────────────────────────────────────────────── */
.text-green { color: var(--green); }
.text-amber { color: #D97706; }
.text-red   { color: #DC2626; }

/* ── LOGIN PAGE ───────────────────────────────────────────── */
.login-page {
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 24px;
}

.login-wrap {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--r3);
  padding: 44px 40px;
  width: 100%;
  max-width: 400px;
  box-shadow: var(--sh3);
}

.login-logo {
  font-size: 26px;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.04em;
  margin-bottom: 6px;
}
.login-sub {
  font-size: 14px;
  color: var(--text2);
  margin-bottom: 28px;
}
.login-form .field { margin-bottom: 12px; }
.login-form input {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: var(--r);
  font-size: 14px;
  font-family: inherit;
  color: var(--text);
  background: var(--card);
  transition: border-color 0.15s, box-shadow 0.15s;
}
.login-form input:focus {
  outline: none;
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(5,150,105,0.1);
}
.login-form .btn { margin-top: 8px; }

/* ── SCROLLBAR ────────────────────────────────────────────── */
::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border2); border-radius: 99px; }
::-webkit-scrollbar-thumb:hover { background: var(--text3); }

/* ── RESPONSIVE ───────────────────────────────────────────── */
@media (max-width: 900px) {
  .metric-grid   { grid-template-columns: repeat(2, 1fr); }
  .two-col-grid  { grid-template-columns: 1fr; }
  .nav-links     { display: none; }
}
@media (max-width: 600px) {
  .metric-grid   { grid-template-columns: 1fr; }
  .main-content  { padding: 16px; }
  .topnav-inner  { padding: 0 16px; }
}

/* ── DASHBOARD GRID (tim + 9-box side by side) ───────────── */
.dashboard-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  align-items: start;
}
@media (max-width: 960px) {
  .dashboard-grid { grid-template-columns: 1fr; }
}
.card-hint {
  font-size: 12px;
  color: var(--text3);
  font-weight: 400;
}

/* ── MODAL ────────────────────────────────────────────────── */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(15,23,42,0.5);
  z-index: 500;
  align-items: flex-start;
  justify-content: center;
  padding: 40px 16px;
  overflow-y: auto;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}
.modal-overlay.open { display: flex; }

.modal-box {
  background: var(--card);
  border-radius: var(--r3);
  width: 100%;
  max-width: 560px;
  box-shadow: var(--sh3);
  position: relative;
  animation: modalIn 0.2s var(--ease);
}
@keyframes modalIn {
  from { opacity: 0; transform: scale(0.95) translateY(-8px); }
  to   { opacity: 1; transform: scale(1) translateY(0); }
}

.modal-close {
  position: absolute;
  top: 16px; right: 16px;
  background: #F1F5F9;
  border: none;
  font-size: 14px;
  color: var(--text3);
  cursor: pointer;
  width: 36px; height: 36px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.2s var(--ease), color 0.2s var(--ease);
  z-index: 1;
}
.modal-close:hover { background: #E2E8F0; color: var(--text); }

.modal-body { padding: 32px; }
.modal-loading {
  text-align: center;
  padding: 48px;
  color: var(--text3);
  font-size: 13px;
}
.modal-error {
  text-align: center;
  padding: 48px;
  color: #DC2626;
  font-size: 13px;
}

/* ── DOSSIER SADRŽAJ ─────────────────────────────────────── */
.dossier-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--border);
}
.dossier-avatar {
  width: 56px; height: 56px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--green), var(--teal));
  display: flex; align-items: center; justify-content: center;
  font-size: 18px; font-weight: 700; color: #fff;
  flex-shrink: 0;
  box-shadow: 0 3px 10px rgba(5,150,105,0.3);
}
.dossier-name { font-size: 18px; font-weight: 700; color: var(--text); }
.dossier-meta { font-size: 13px; color: var(--text3); margin-top: 3px; }
.dossier-label {
  margin-top: 6px;
  display: inline-block;
  background: var(--green-light);
  color: var(--green-dark);
  font-size: 11px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 99px;
}

.dossier-section {
  margin-bottom: 20px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--border);
}
.dossier-section:last-child { border-bottom: none; margin-bottom: 0; }

.dossier-section-title {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text3);
  margin-bottom: 12px;
}

/* Score blokovi */
.dossier-scores {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 12px;
}
.score-block {
  background: var(--bg);
  border-radius: var(--r);
  padding: 12px;
  text-align: center;
  border: 1px solid rgba(0,0,0,0.04);
}
.score-label { font-size: 10px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.06em; color: var(--text3); }
.score-val   { font-size: 26px; font-weight: 800; color: var(--text); letter-spacing: -0.03em; }
.score-cat   { font-size: 13px; font-weight: 600; color: var(--text); margin-top: 2px; line-height: 1.3; }
.score-gap   { font-size: 11px; font-weight: 600; margin-top: 3px; }
.gap-pos     { color: var(--green); }
.gap-neg     { color: #DC2626; }

.dossier-comment {
  background: #F0FDF4;
  border: 1px solid #BBF7D0;
  border-left: 3px solid var(--green);
  border-radius: var(--r);
  padding: 14px 16px;
  font-size: 13px;
  color: var(--text2);
  line-height: 1.6;
}

/* Ciljevi u dosjeju */
.goal-row {
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 10px;
  align-items: center;
  margin-bottom: 8px;
}
.goal-title { font-size: 13px; color: var(--text); }
.goal-bar-wrap {
  width: 80px; height: 5px;
  background: var(--border);
  border-radius: 99px;
  overflow: hidden;
}
.goal-bar { height: 100%; border-radius: 99px; transition: width 0.4s; }
.goal-pct  { font-size: 11px; font-weight: 600; min-width: 32px; text-align: right; }

/* IDP */
.idp-goal { font-size: 14px; font-weight: 600; color: var(--text); margin-bottom: 8px; }
.idp-row  { font-size: 13px; color: var(--text2); margin-bottom: 5px; line-height: 1.5; }
.idp-lbl  { font-weight: 600; color: var(--text); }

/* ============================================================
   KUDOS WALL — Premium Recognition System
   ============================================================ */

/* ── RECOGNITION WALL — grid layout ─────────────────────── */
.kudos-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
@media (max-width: 768px) {
  .kudos-grid { grid-template-columns: 1fr; }
}

/* ── KUDOS CARD — individual recognition ────────────────── */
.kudos-row {
  background: #fff;
  border: 1px solid rgba(0,0,0,0.06);
  border-radius: 12px;
  padding: 16px 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  position: relative;
  transition: box-shadow 0.2s var(--ease), border-left-color 0.2s var(--ease);
  border-left: 3px solid transparent;
}
.kudos-row:hover {
  box-shadow: 0 4px 12px rgba(0,0,0,0.08), 0 1px 3px rgba(0,0,0,0.04);
  border-left-color: var(--green);
}
.kudos-row:last-child { border-bottom: none; }

/* Category badge top-left */
.kudos-cat {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  font-weight: 600;
  color: var(--green-dark);
  white-space: nowrap;
  background: rgba(5,150,105,0.08);
  padding: 3px 8px;
  border-radius: 6px;
  align-self: flex-start;
}

/* Recipient name */
.kudos-receiver {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.3;
}

/* Message */
.kudos-msg {
  font-size: 14px;
  font-style: italic;
  color: #334155;
  line-height: 1.6;
  flex: 1;
}
.kudos-msg::before { content: '\201C'; }
.kudos-msg::after  { content: '\201D'; }

/* From + date row */
.kudos-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 4px;
}
.kudos-from {
  font-size: 13px;
  font-weight: 400;
  color: #64748B;
}
.kudos-date {
  font-size: 12px;
  color: #94A3B8;
}

/* ── RECOGNITION LEADERBOARD ─────────────────────────────── */
.kudos-leaderboard {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.kudos-leader-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.kudos-leader-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--green), var(--teal));
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  letter-spacing: 0.02em;
}

.kudos-leader-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  min-width: 100px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.kudos-leader-bar-wrap {
  flex: 1;
  height: 8px;
  background: #E2E8F0;
  border-radius: 99px;
  overflow: hidden;
}

.kudos-leader-bar {
  height: 100%;
  border-radius: 99px;
  background: linear-gradient(90deg, #059669, #0D9488);
  transition: width 0.6s cubic-bezier(0.4,0,0.2,1), transform 0.2s var(--ease);
  transform-origin: left center;
}
.kudos-leader-row:hover .kudos-leader-bar {
  transform: scaleY(1.25);
}

.kudos-leader-count {
  font-size: 13px;
  font-weight: 700;
  color: var(--text2);
  min-width: 20px;
  text-align: right;
}

/* ── RECOGNIZE FORM CARD ─────────────────────────────────── */
.kudos-form-card {
  background: linear-gradient(135deg, #F0FDF4, #F8FAFC);
  border: 1px solid rgba(5,150,105,0.12);
  border-radius: 14px;
  padding: 28px;
  box-shadow: 0 1px 2px rgba(0,0,0,0.04), 0 2px 4px rgba(0,0,0,0.03);
}
.kudos-form-card .card-title {
  color: var(--green-dark);
  font-size: 16px;
  font-weight: 700;
}

/* Full-width submit button for kudos form */
.kudos-form-card .btn-primary {
  width: 100%;
  justify-content: center;
  height: 48px;
  font-size: 15px;
  font-weight: 600;
  margin-top: 4px;
  letter-spacing: -0.01em;
}

/* ── CATEGORY COLOR VARIANTS ─────────────────────────────── */
.kudos-row[data-cat="Innovation"]    { border-left-color: #F59E0B; }
.kudos-row[data-cat="Innovation"]:hover { border-left-color: #F59E0B; }
.kudos-row[data-cat="Innovation"] .kudos-cat    { background: rgba(245,158,11,0.08); color: #B45309; }

.kudos-row[data-cat="Teamwork"]      { border-left-color: #3B82F6; }
.kudos-row[data-cat="Teamwork"]:hover { border-left-color: #3B82F6; }
.kudos-row[data-cat="Teamwork"] .kudos-cat      { background: rgba(59,130,246,0.08); color: #1D4ED8; }

.kudos-row[data-cat="Initiative"]    { border-left-color: #8B5CF6; }
.kudos-row[data-cat="Initiative"]:hover { border-left-color: #8B5CF6; }
.kudos-row[data-cat="Initiative"] .kudos-cat    { background: rgba(139,92,246,0.08); color: #6D28D9; }

.kudos-row[data-cat="Goal Focus"]    { border-left-color: #059669; }
.kudos-row[data-cat="Goal Focus"] .kudos-cat    { background: rgba(5,150,105,0.08); color: #047857; }

.kudos-row[data-cat="Quality"]       { border-left-color: #059669; }
.kudos-row[data-cat="Quality"] .kudos-cat       { background: rgba(5,150,105,0.10); color: #065F46; }

.kudos-row[data-cat="Perseverance"]  { border-left-color: #EF4444; }
.kudos-row[data-cat="Perseverance"]:hover { border-left-color: #EF4444; }
.kudos-row[data-cat="Perseverance"] .kudos-cat  { background: rgba(239,68,68,0.08); color: #B91C1C; }

.kudos-row[data-cat="Expertise"]     { border-left-color: #0D9488; }
.kudos-row[data-cat="Expertise"]:hover { border-left-color: #0D9488; }
.kudos-row[data-cat="Expertise"] .kudos-cat     { background: rgba(13,148,136,0.08); color: #0F766E; }

.kudos-row[data-cat="Team Support"]  { border-left-color: #F97316; }
.kudos-row[data-cat="Team Support"]:hover { border-left-color: #F97316; }
.kudos-row[data-cat="Team Support"] .kudos-cat  { background: rgba(249,115,22,0.08); color: #C2410C; }

.empty-mini {
  text-align: center;
  padding: 16px;
  color: var(--text3);
  font-size: 13px;
}

/* ── TABS — segmented control ─────────────────────────────── */
.tab-bar {
  display: flex;
  gap: 2px;
  background: #F1F5F9;
  border-radius: var(--r);
  padding: 4px;
  margin-bottom: 0;
  overflow: visible;
  border-bottom: none;
}
.tab-link {
  padding: 8px 16px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text3);
  border-radius: 8px;
  border-bottom: none;
  margin-bottom: 0;
  transition: background 0.2s var(--ease), color 0.15s var(--ease), box-shadow 0.2s var(--ease);
  cursor: pointer;
  white-space: nowrap;
}
.tab-link:hover { color: #334155; background: rgba(255,255,255,0.6); }
.tab-link.active {
  color: var(--text);
  font-weight: 600;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08), 0 1px 2px rgba(0,0,0,0.04);
}
.tab-panel { padding-top: 0; }

/* ── FORM FIELDS ──────────────────────────────────────────── */
.field-group { display: flex; flex-direction: column; gap: 6px; margin-bottom: 12px; }
.field-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text2);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.input {
  height: 44px;
  padding: 0 14px;
  border: 1px solid #E2E8F0;
  border-radius: var(--r);
  font-size: 13px;
  font-family: inherit;
  color: var(--text);
  background: var(--card);
  transition: border-color 0.15s var(--ease), box-shadow 0.15s var(--ease);
  width: 100%;
}
.input::placeholder { color: #94A3B8; font-style: normal; }
.input:hover { border-color: #CBD5E1; }
.input:focus {
  outline: none;
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(5,150,105,0.08);
}
.select {
  height: 40px;
  padding: 0 36px 0 12px;
  border: 1px solid #E2E8F0;
  border-radius: var(--r);
  font-size: 13px;
  font-weight: 500;
  font-family: inherit;
  color: var(--text);
  background: var(--card) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2394A3B8' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") no-repeat right 12px center;
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  cursor: pointer;
  transition: border-color 0.15s var(--ease), box-shadow 0.15s var(--ease);
}
.select:hover { border-color: #CBD5E1; }
.select:focus {
  outline: none;
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(5,150,105,0.08);
}

/* ── IDP TABLICA ──────────────────────────────────────────── */
.idp-table-wrap {
  overflow-x: auto;
  border-radius: var(--r2);
  overflow: hidden;
}
.idp-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}
.idp-table th {
  text-align: left;
  padding: 12px 16px;
  background: #F8FAFC;
  font-size: 11px;
  font-weight: 600;
  color: var(--text3);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  border-bottom: 1px solid rgba(0,0,0,0.06);
}
.idp-table td {
  padding: 12px 16px;
  border-bottom: 1px solid rgba(0,0,0,0.04);
  vertical-align: middle;
  font-size: 13px;
  font-weight: 400;
  color: var(--text);
}
.idp-table tr:hover td { background: #F0FDF4; }
.idp-table tr:last-child td { border-bottom: none; }
.input-cell {
  width: 100%;
  padding: 5px 8px;
  border: 1px solid transparent;
  border-radius: 4px;
  font-size: 12px;
  font-family: inherit;
  background: transparent;
  color: var(--text);
  transition: border-color 0.1s, background 0.1s;
}
.input-cell:focus { outline: none; border-color: var(--green); background: var(--card); }
.btn-icon-del {
  background: transparent;
  border: none;
  cursor: pointer;
  color: var(--text3);
  font-size: 12px;
  padding: 4px;
  border-radius: 4px;
  transition: color 0.1s, background 0.1s;
}
.btn-icon-del:hover { color: #DC2626; background: #FEE2E2; }

/* ── ADD FORM (details/summary) ───────────────────────────── */
.add-form-wrap { margin-top: 12px; }
.add-form-wrap summary {
  list-style: none;
  cursor: pointer;
  font-weight: 600;
  color: var(--green);
  transition: color 0.15s var(--ease);
}
.add-form-wrap summary::-webkit-details-marker { display: none; }
.add-form-wrap summary::marker { display: none; }
.add-form-wrap summary:hover { color: var(--green-dark); }
.add-form-wrap[open] summary { color: var(--green-dark); }
.add-form {
  margin-top: 8px;
  padding-top: 12px;
  padding: 16px;
  background: var(--bg);
  border-radius: var(--r2);
  border-top: 1px solid #F1F5F9;
}

/* ── GOAL CARDS ───────────────────────────────────────────── */
.goal-card {
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 24px;
  margin-bottom: 0;
  background: var(--card);
  box-shadow: 0 1px 2px rgba(0,0,0,0.04), 0 2px 4px rgba(0,0,0,0.03), 0 4px 8px rgba(0,0,0,0.02);
  transition: box-shadow 0.2s var(--ease), border-color 0.2s var(--ease);
}
.goal-card:hover {
  box-shadow: 0 4px 8px rgba(0,0,0,0.04), 0 8px 16px rgba(0,0,0,0.06), 0 16px 32px rgba(0,0,0,0.04);
  border-color: rgba(5,150,105,0.12);
}
.goal-card-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 10px; }
.goal-card-title {
  font-size: 14px;
  font-weight: 600;
  color: #1E293B;
  letter-spacing: -0.01em;
  line-height: 1.4;
}
.goal-card-sub { font-size: 13px; font-weight: 400; color: #64748B; margin-top: 4px; line-height: 1.5; }

.goal-row-emp {
  padding: 12px 0;
  border-bottom: 1px solid rgba(0,0,0,0.04);
}
.goal-row-emp:last-child { border-bottom: none; }
.goal-parent { font-size: 11px; color: #1976d2; margin-top: 2px; font-weight: 500; }

/* ── ORG GOAL ROW ─────────────────────────────────────────── */
.org-goal-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--bg);
}
.org-goal-title { flex: 1; font-size: 13px; font-weight: 600; color: var(--text); }
.mini-progress-wrap {
  width: 120px;
  height: 6px;
  background: #E2E8F0;
  border-radius: 99px;
  overflow: hidden;
  flex-shrink: 0;
}
.mini-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #059669, #0D9488);
  border-radius: 99px;
  transition: width 0.4s var(--ease);
}
.mini-progress-pct  { font-size: 11px; font-weight: 600; color: var(--text2); min-width: 32px; text-align: right; }

/* ── GAP ANALIZA (employee) ───────────────────────────────── */
.gap-row {
  display: grid;
  grid-template-columns: 90px 1fr 1fr 60px;
  gap: 8px;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid var(--bg);
  font-size: 13px;
}
.gap-row:last-child { border-bottom: none; }
.gap-label   { font-weight: 600; color: var(--text2); }
.gap-self    { color: var(--text3); }
.gap-mgr     { color: var(--text2); font-weight: 500; }
.gap-diff    { font-weight: 700; text-align: right; }
.gap-pos     { color: var(--green); }
.gap-neg     { color: #DC2626; }
.gap-neutral { color: var(--text3); }

/* ── MISC ─────────────────────────────────────────────────── */
.link-green { color: var(--green); font-weight: 600; }
.link-green:hover { color: var(--green-dark); }

/* ============================================================
   DESIGN POLISH — Premium detalji
   ============================================================ */

/* ── Kartice — hover shadow raste, bez translate ────────── */
.card:hover {
  box-shadow: var(--sh2);
}

/* ── Metric cards — bez border-left accenta ─────────────── */
.metric-card {
  transition: box-shadow 0.2s var(--ease);
}
.metric-card:hover {
  box-shadow: var(--sh2);
}

/* ── Page header gradient tekst ─────────────────────────── */
.page-header h1 {
  background: linear-gradient(135deg, var(--text) 0%, #334155 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ── Period Stepper ──────────────────────────────────────── */
.period-stepper {
  display: flex;
  align-items: center;
  gap: 0;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--r2);
  padding: 10px 20px;
  margin-bottom: 20px;
  box-shadow: var(--sh);
  overflow-x: auto;
}
.step {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
.step-circle {
  width: 28px; height: 28px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 11px; font-weight: 700;
  flex-shrink: 0;
}
.step-circle.done    { background: var(--green-light); color: var(--green-dark); }
.step-circle.active  { background: var(--green); color: #fff; box-shadow: 0 0 0 3px rgba(5,150,105,0.2); }
.step-circle.pending { background: #F1F5F9; color: var(--text3); }
.step-label {
  font-size: 12px; font-weight: 600;
  white-space: nowrap;
}
.step-label.done    { color: var(--green-dark); }
.step-label.active  { color: var(--text); }
.step-label.pending { color: var(--text3); }
.step-connector {
  flex: 1; min-width: 24px; max-width: 60px;
  height: 2px;
  margin: 0 8px;
  border-radius: 99px;
  flex-shrink: 0;
}
.step-connector.done    { background: var(--green); }
.step-connector.pending { background: var(--border); }

/* ── Navigacija — active border-bottom indikator ────────── */
.nav-link.active {
  color: #6EE7B7;
  background: transparent;
}

/* ── Scrollbar — tanji i zeleniji ────────────────────────── */
::-webkit-scrollbar       { width: 4px; height: 4px; }
::-webkit-scrollbar-thumb { background: rgba(0,0,0,0.15); border-radius: 99px; }
::-webkit-scrollbar-thumb:hover { background: var(--green); }

/* ── KALIBRACIJA ──────────────────────────────────────────── */
.cal-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 4px;
  border-bottom: 0.5px solid var(--border);
  border-radius: var(--r);
  transition: background 0.15s;
}
.cal-row:hover     { background: #F0FDF4; }
.cal-row:last-child { border-bottom: none; }
.cal-row--done     { background: #F0FDF9; }
.cal-row--done:hover { background: #E6FBF3; }

/* ============================================================
   MOBILE RESPONSIVE — Media Queries za ekrane < 768px
   ============================================================ */

/* ── 1. HAMBURGER NAVIGACIJA ─────────────────────────────── */

.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 6px;
  border-radius: var(--r);
  border: none;
  background: transparent;
  flex-shrink: 0;
}
.hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: rgba(255,255,255,0.7);
  border-radius: 99px;
  transition: all 0.25s;
}
.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile nav dropdown */
.mobile-nav {
  display: none;
  position: absolute;
  top: var(--nav-h);
  left: 0; right: 0;
  background: var(--navy2);
  border-bottom: 1px solid rgba(255,255,255,0.08);
  box-shadow: 0 8px 24px rgba(0,0,0,0.3);
  z-index: 99;
  flex-direction: column;
  padding: 8px 0;
}
.mobile-nav.open { display: flex; }
.mobile-nav a {
  display: block;
  padding: 12px 20px;
  color: rgba(255,255,255,0.7);
  font-size: 14px;
  font-weight: 500;
  border-bottom: 1px solid rgba(255,255,255,0.05);
  transition: background 0.15s, color 0.15s;
}
.mobile-nav a:last-child { border-bottom: none; }
.mobile-nav a:hover,
.mobile-nav a.active {
  background: rgba(5,150,105,0.15);
  color: #6EE7B7;
}

@media (max-width: 768px) {
  /* Sakrij desktop nav, prikaži hamburger */
  .nav-links   { display: none !important; }
  .hamburger   { display: flex; }
  .topnav      { position: sticky; top: 0; z-index: 100; }
  .topnav-inner { position: relative; }

  /* Sakrij period badge na mobitelu (štedi prostor) */
  .period-badge { display: none; }

  /* ── 2. VERTIKALNO SLAGANJE ─────────────────────────────── */
  .metric-grid,
  .two-col-grid,
  .dashboard-grid {
    grid-template-columns: 1fr !important;
  }

  /* ── 3. SKROLANJE TABLICA ───────────────────────────────── */
  .idp-table-wrap,
  .card > div[style*="overflow"] {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  /* Svaka tablica unutar card dobiva scroll wrapper automatski */
  .card table {
    min-width: 500px;
  }
  .idp-table {
    min-width: 600px;
  }

  /* ── 4. MODALI PREKO CIJELOG EKRANA ─────────────────────── */
  .modal-overlay {
    padding: 0 !important;
    align-items: flex-end;
  }
  .modal-box {
    max-width: 100% !important;
    width: 100% !important;
    border-radius: var(--r2) var(--r2) 0 0 !important;
    max-height: 92vh;
    overflow-y: auto;
    animation: slideUp 0.25s ease !important;
  }
  @keyframes slideUp {
    from { transform: translateY(100%); opacity: 0; }
    to   { transform: translateY(0);    opacity: 1; }
  }

  /* ── 5. TOUCH TARGETS ───────────────────────────────────── */
  .btn {
    min-height: 44px;
    padding: 10px 16px;
  }
  .btn-sm {
    min-height: 36px;
    padding: 6px 12px;
  }
  input[type="text"],
  input[type="password"],
  input[type="email"],
  input[type="number"],
  input[type="date"],
  input[type="file"],
  select,
  textarea {
    min-height: 44px;
    font-size: 16px !important; /* sprječava iOS auto-zoom */
  }
  .select  { font-size: 16px !important; }
  .input   { font-size: 16px !important; }
  .textarea { font-size: 16px !important; }

  /* ── OSTALE MOBILE PRILAGODBE ───────────────────────────── */

  /* Main content padding manji */
  .main-content { padding: 16px 12px 40px; }

  /* Page header vertikalno */
  .page-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }
  .page-header h1 {
    font-size: 22px;
    background: none;
    -webkit-text-fill-color: var(--text);
  }

  /* Team rows kompaktnije */
  .team-row { gap: 8px; flex-wrap: wrap; }
  .team-pills { flex-wrap: wrap; }

  /* Tab bar scroll */
  .tab-bar {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    flex-wrap: nowrap;
    scrollbar-width: none;
  }
  .tab-bar::-webkit-scrollbar { display: none; }
  .tab-link { white-space: nowrap; }

  /* Login forma */
  .login-wrap { padding: 28px 20px; }

  /* Score chips sakrij na manjim ekranima */
  .score-chip { display: none; }

  /* Metric value manji font */
  .metric-value { font-size: 24px; }

  /* Rating slider lakši za touch */
  .rating-slider { height: 6px; }
  .rating-slider::-webkit-slider-thumb { width: 28px; height: 28px; }

  /* Dossier modal body padding */
  .modal-body { padding: 16px; }
  .dossier-scores { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 480px) {
  /* Još manji ekrani */
  .dossier-scores { grid-template-columns: 1fr 1fr; }
  .gap-row { grid-template-columns: 70px 1fr 1fr 50px; font-size: 12px; }
  .metric-grid { gap: 8px; }
}

/* ============================================================
   MICRO-INTERACTIONS & PREMIUM POLISH — Layer 3
   ============================================================ */

/* ── SCROLL BEHAVIOR ─────────────────────────────────────── */
html { scroll-behavior: smooth; }

/* ── FOCUS STATES — accessibility + premium ─────────────── */
*:focus { outline: none; }
*:focus-visible {
  outline: 2px solid #059669;
  outline-offset: 2px;
  transition: outline 0.15s var(--ease);
}
.input:focus,
.select:focus,
.textarea:focus,
.login-form input:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(5,150,105,0.10);
  outline: none;
  transition: border-color 0.15s var(--ease), box-shadow 0.15s var(--ease);
}

/* ── GLOBAL TRANSITIONS ──────────────────────────────────── */
a, button, .btn, .card, .metric-card, .team-row,
.nav-link, .tab-link, .pill, .avatar-menu-item {
  transition: all 0.2s cubic-bezier(0.4,0,0.2,1);
}

/* ── SKELETON LOADER ─────────────────────────────────────── */
@keyframes shimmer {
  0%   { background-position: -200% 0; }
  100% { background-position:  200% 0; }
}
.skeleton {
  background: linear-gradient(
    90deg,
    #F1F5F9 25%,
    #E2E8F0 50%,
    #F1F5F9 75%
  );
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: var(--r);
  color: transparent !important;
  pointer-events: none;
  user-select: none;
}
.skeleton * { visibility: hidden; }

/* ── TOOLTIPS ────────────────────────────────────────────── */
[data-tooltip] { position: relative; }

[data-tooltip]::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%);
  background: #1E293B;
  color: #fff;
  font-size: 12px;
  font-weight: 500;
  font-family: 'Inter', sans-serif;
  line-height: 1.4;
  white-space: nowrap;
  padding: 6px 12px;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  pointer-events: none;
  opacity: 0;
  animation: none;
  transition: opacity 0.15s var(--ease), transform 0.15s var(--ease);
  transform: translateX(-50%) translateY(4px);
  z-index: 999;
}

/* Arrow */
[data-tooltip]::before {
  content: '';
  position: absolute;
  bottom: calc(100% + 2px);
  left: 50%;
  transform: translateX(-50%);
  border: 5px solid transparent;
  border-top-color: #1E293B;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.15s var(--ease);
  z-index: 999;
}

[data-tooltip]:hover::after,
[data-tooltip]:hover::before {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ── STICKY NAV GLASSMORPHISM ────────────────────────────── */
.topnav {
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

/* ── CARD HOVER — suptilni scale ─────────────────────────── */
.metric-card:hover {
  transform: scale(1.01);
}

/* ── MODAL ANIMATION — unaprijeđena ─────────────────────── */
@keyframes modalIn {
  from { opacity: 0; transform: translateY(-16px) scale(0.97); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

/* ── BUTTON ACTIVE STATE ─────────────────────────────────── */
.btn:active { transform: scale(0.98); }
.btn-primary:active { box-shadow: 0 2px 6px rgba(5,150,105,0.2); }

/* ── INPUT GROUP LABEL ANIMATION ─────────────────────────── */
.field-group:focus-within .field-label {
  color: var(--green);
  transition: color 0.15s var(--ease);
}

/* ── AVATAR HOVER ────────────────────────────────────────── */
.avatar-wrap:hover .avatar {
  box-shadow: 0 4px 16px rgba(5,150,105,0.4);
}

/* ── ALERT ANIMATIONS ────────────────────────────────────── */
@keyframes slideDown {
  from { opacity: 0; transform: translateY(-8px); }
  to   { opacity: 1; transform: translateY(0); }
}
.alert {
  animation: slideDown 0.2s cubic-bezier(0.4,0,0.2,1);
}

/* ── EMPTY STATE ICON ────────────────────────────────────── */
.empty-icon {
  display: inline-block;
  animation: float 3s ease-in-out infinite;
}
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(-6px); }
}

/* ── PILL HOVER ──────────────────────────────────────────── */
.pill { transition: filter 0.15s var(--ease); }
.pill:hover { filter: brightness(0.95); }

/* ============================================================
   INLINE STYLE INCONSISTENCIES — Za ručnu korekciju u templateima
   ============================================================
   Sljedeće inline style vrijednosti u templateima su nekonzistentne
   s novim design systemom. Mogu se ispraviti ručno:

   color:#94A3B8  → color:var(--text3)  ili  color:#64748B
   border-radius:8px  → border-radius:var(--r)  (10px)
   border-radius:4px  → border-radius:6px
   font-size:12px;color:#64748B  → ok (text3 je sada #64748B)
   background:#FAFBFC  → background:var(--card)  ili var(--bg)
   border:1px solid #E2E8F0  → border:1px solid var(--border)
   padding:10px treba biti 12px ili 14px za card sadržaj
   ============================================================ */

/* ============================================================
   GOALS / OKR VIEW — Premium component overrides
   ============================================================ */

/* ── GOAL PROGRESS (pct label desno od bara) ─────────────── */
.goal-bar-wrap {
  flex: 1;
  height: 6px;
  background: #E2E8F0;
  border-radius: 99px;
  overflow: hidden;
}
.goal-bar {
  height: 100%;
  border-radius: 99px;
  background: linear-gradient(90deg, #059669, #0D9488);
  transition: width 0.6s cubic-bezier(0.4,0,0.2,1);
}
.goal-pct {
  font-size: 14px;
  font-weight: 700;
  color: #059669;
  min-width: 40px;
  text-align: right;
}
.goal-title {
  font-size: 14px;
  font-weight: 600;
  color: #1E293B;
  line-height: 1.4;
}

/* ── WEIGHT BADGE — pill-green redizajn ─────────────────── */
.pill-green {
  background: rgba(5,150,105,0.08);
  color: #059669;
  border-radius: 6px;
  padding: 4px 10px;
  font-size: 12px;
  font-weight: 600;
}
.pill-amber {
  background: rgba(245,158,11,0.08);
  color: #D97706;
  border-radius: 6px;
  padding: 4px 10px;
  font-size: 12px;
  font-weight: 600;
}

/* ── ADD CILJ BUTTON — dashed ghost ─────────────────────── */
.btn-ghost-dashed,
.add-form-wrap summary.btn-ghost,
details.add-form-wrap > summary {
  background: transparent;
  border: 1px dashed #CBD5E1;
  border-radius: 10px;
  padding: 10px 20px;
  color: #64748B;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: border-color 0.2s var(--ease), color 0.2s var(--ease), background 0.2s var(--ease);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.btn-ghost-dashed:hover,
.add-form-wrap summary.btn-ghost:hover,
details.add-form-wrap > summary:hover {
  border-color: #059669;
  color: #059669;
  background: rgba(5,150,105,0.04);
}

/* ── ORG GOAL ROW — premium spacing ─────────────────────── */
.org-goal-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 0;
  border-bottom: 1px solid rgba(0,0,0,0.04);
}
.org-goal-row:last-child { border-bottom: none; }
.org-goal-title {
  flex: 1;
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  line-height: 1.4;
}

/* ── GOAL CARD container gap ─────────────────────────────── */
.card > .goal-card + .goal-card {
  margin-top: 12px;
}

/* ── MINI PROGRESS wider in goals context ───────────────── */
.goal-row .mini-progress-wrap,
.goal-row-emp .mini-progress-wrap {
  flex: 1;
  width: auto;
}

/* ── GOAL TIER LABELS (Org / Dept / Employee) ────────────── */
.goal-tier-label {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #94A3B8;
  padding: 14px 0 6px;
  border-top: 1px solid rgba(0,0,0,0.05);
  margin-top: 8px;
}
.goal-tier-label:first-child {
  border-top: none;
  padding-top: 0;
  margin-top: 0;
}

/* ============================================================
   EVALUATION / REVIEW PAGE — Premium layout
   ============================================================ */

/* ── EVALUATION PAGE HEADER ──────────────────────────────── */
.eval-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 32px;
}

.eval-emp-name {
  font-size: 28px;
  font-weight: 800;
  color: #0F172A;
  letter-spacing: -0.04em;
  line-height: 1.15;
  margin-bottom: 6px;
}

.eval-meta {
  font-size: 14px;
  font-weight: 400;
  color: #64748B;
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}
.eval-meta-sep {
  color: #CBD5E1;
  font-size: 12px;
}

/* Status pills */
.pill-draft {
  background: #FEF3C7;
  color: #92400E;
  border-radius: 6px;
  padding: 4px 10px;
  font-size: 12px;
  font-weight: 600;
}
.pill-submitted {
  background: #D1FAE5;
  color: #065F46;
  border-radius: 6px;
  padding: 4px 10px;
  font-size: 12px;
  font-weight: 600;
}
.pill-locked {
  background: #E2E8F0;
  color: #475569;
  border-radius: 6px;
  padding: 4px 10px;
  font-size: 12px;
  font-weight: 600;
}

/* ── TWO-COLUMN EVAL LAYOUT ──────────────────────────────── */
.eval-columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  align-items: start;
}
@media (max-width: 900px) {
  .eval-columns { grid-template-columns: 1fr; gap: 20px; }
}

/* Section column card */
.eval-section {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 28px;
  box-shadow: 0 1px 2px rgba(0,0,0,0.04), 0 2px 4px rgba(0,0,0,0.03), 0 4px 8px rgba(0,0,0,0.02);
}

/* Section heading (Performance / Potential) */
.eval-section-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.02em;
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.eval-section-sub {
  font-size: 13px;
  color: #64748B;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid #F1F5F9;
}

/* ── SCORE SUMMARY CIRCLES ───────────────────────────────── */
.eval-summary {
  display: flex;
  gap: 24px;
  justify-content: center;
  margin-top: 32px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

.eval-score-circle {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.eval-score-ring {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  border: 3px solid #059669;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(5,150,105,0.04);
  position: relative;
  transition: transform 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
.eval-score-ring:hover {
  transform: scale(1.04);
  box-shadow: 0 0 0 6px rgba(5,150,105,0.08);
}

.eval-score-ring-num {
  font-size: 28px;
  font-weight: 800;
  color: #059669;
  letter-spacing: -0.04em;
  line-height: 1;
}

.eval-score-ring-label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #64748B;
  text-align: center;
  max-width: 90px;
  line-height: 1.3;
}

/* Potential ring — teal accent */
.eval-score-circle:nth-child(2) .eval-score-ring {
  border-color: #0D9488;
  background: rgba(13,148,136,0.04);
}
.eval-score-circle:nth-child(2) .eval-score-ring-num {
  color: #0D9488;
}
.eval-score-circle:nth-child(2) .eval-score-ring:hover {
  box-shadow: 0 0 0 6px rgba(13,148,136,0.08);
}

/* ── BACK LINK AS GHOST BUTTON ───────────────────────────── */
.btn-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text2);
  background: transparent;
  border: 1px solid var(--border);
  cursor: pointer;
  transition: all 0.2s var(--ease);
  text-decoration: none;
  white-space: nowrap;
}
.btn-back:hover {
  background: var(--bg);
  color: var(--text);
  border-color: #CBD5E1;
}

/* ── LOCKED STATE — read-only overlay ───────────────────── */
.eval-locked-banner {
  background: #F8FAFC;
  border: 1px solid #E2E8F0;
  border-radius: var(--r);
  padding: 12px 16px;
  font-size: 13px;
  color: #475569;
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 20px;
}

/* ── FORM ACTIONS ROW ────────────────────────────────────── */
.eval-actions {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 12px;
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid #F1F5F9;
}
.eval-actions .btn-primary {
  min-width: 160px;
  justify-content: center;
}

/* ============================================================
   HIERARCHY VIEW — Premium metric cards + 9-Box container
   ============================================================ */

/* ── METRIC CARD WITH ICON ───────────────────────────────── */
.metric-card-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  margin-bottom: 14px;
  flex-shrink: 0;
}

/* Accent variants */
.metric-card-icon--green  { background: rgba(5,150,105,0.10); }
.metric-card-icon--blue   { background: rgba(59,130,246,0.10); }
.metric-card-icon--amber  { background: rgba(245,158,11,0.10); }
.metric-card-icon--teal   { background: rgba(13,148,136,0.10); }
.metric-card-icon--purple { background: rgba(139,92,246,0.10); }

/* Horizontal metric card layout (icon left, content right) */
.metric-card-h {
  display: flex;
  align-items: flex-start;
  gap: 16px;
}
.metric-card-h .metric-card-icon {
  margin-bottom: 0;
  margin-top: 2px;
}
.metric-card-h .metric-card-body {
  flex: 1;
  min-width: 0;
}

/* ── PERCENTAGE COLORING HELPERS ─────────────────────────── */
.pct-good   { color: #059669 !important; font-weight: 600; }
.pct-medium { color: #D97706 !important; font-weight: 600; }
.pct-low    { color: #DC2626 !important; font-weight: 600; }

/* ── 9-BOX CHART CARD ────────────────────────────────────── */
.ninebox-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--r2);
  padding: 28px;
  box-shadow: var(--sh);
}

.ninebox-card .card-header {
  margin-bottom: 4px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border);
}

.ninebox-card .card-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.02em;
}

/* Period badge inside chart header */
.ninebox-period-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: rgba(5,150,105,0.08);
  color: #059669;
  font-size: 12px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 6px;
}

.ninebox-subtitle {
  font-size: 12px;
  color: #94A3B8;
  margin-top: 2px;
  font-weight: 400;
}

/* Chart container min-height */
#ninebox-chart {
  min-height: 460px;
  width: 100%;
  margin-top: 8px;
}

/* ── HIERARCHY STATS ROW ─────────────────────────────────── */
.hier-metric-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}
@media (max-width: 768px) {
  .hier-metric-grid { grid-template-columns: 1fr; }
}

/* ── MANAGER CARD IN HIERARCHY ───────────────────────────── */
.hier-mgr-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 10px;
}
.hier-mgr-name {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
}
.hier-mgr-role {
  font-size: 12px;
  color: #64748B;
  margin-top: 1px;
}
.hier-mgr-stats {
  margin-left: auto;
  text-align: right;
  flex-shrink: 0;
}
.hier-mgr-pct {
  font-size: 13px;
  font-weight: 700;
}
.hier-mgr-count {
  font-size: 11px;
  color: #94A3B8;
  margin-top: 1px;
}

/* ── EMPLOYEE ROW IN HIERARCHY ───────────────────────────── */
.hier-emp-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 4px;
  border-radius: 8px;
  transition: background 0.15s var(--ease);
}
.hier-emp-row:hover { background: #F8FAFC; }

.hier-emp-name {
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
  flex: 1;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.hier-emp-role {
  font-size: 11px;
  color: #94A3B8;
  white-space: nowrap;
}
