/* ═══════════════════════════════════════════════════════════
   UTILITIES.CSS — Nameštaj Crni bor
   Pomoćne klase za brzo stilizovanje. Koristiti umereno —
   osnovno stilizovanje ide u components.css.
   ═══════════════════════════════════════════════════════════ */

/* === TEXT ALIGNMENT === */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

/* === TEXT COLOR === */
.text-primary { color: var(--color-text-primary); }
.text-secondary { color: var(--color-text-secondary); }
.text-accent { color: var(--color-text-accent); }
.text-golden { color: var(--color-wood-golden); }

/* === TEXT SIZE === */
.text-xs { font-size: var(--text-xs); }
.text-sm { font-size: var(--text-sm); }
.text-base { font-size: var(--text-base); }
.text-lg { font-size: var(--text-lg); }

/* === FONT WEIGHT === */
.font-light { font-weight: var(--weight-light); }
.font-regular { font-weight: var(--weight-regular); }
.font-medium { font-weight: var(--weight-medium); }
.font-semibold { font-weight: var(--weight-semibold); }
.font-bold { font-weight: var(--weight-bold); }

/* === FONT FAMILY === */
.font-display { font-family: var(--font-display); }
.font-body { font-family: var(--font-body); }

/* === SPACING — Margin Top === */
.mt-0 { margin-top: 0; }
.mt-2 { margin-top: var(--space-2); }
.mt-4 { margin-top: var(--space-4); }
.mt-5 { margin-top: var(--space-5); }
.mt-6 { margin-top: var(--space-6); }
.mt-8 { margin-top: var(--space-8); }

/* === SPACING — Margin Bottom === */
.mb-0 { margin-bottom: 0; }
.mb-2 { margin-bottom: var(--space-2); }
.mb-4 { margin-bottom: var(--space-4); }
.mb-5 { margin-bottom: var(--space-5); }
.mb-6 { margin-bottom: var(--space-6); }
.mb-8 { margin-bottom: var(--space-8); }

/* === SPACING — Margin Auto === */
.mx-auto { margin-left: auto; margin-right: auto; }

/* === PADDING === */
.p-4 { padding: var(--space-4); }
.p-6 { padding: var(--space-6); }
.py-4 { padding-top: var(--space-4); padding-bottom: var(--space-4); }
.py-6 { padding-top: var(--space-6); padding-bottom: var(--space-6); }
.px-4 { padding-left: var(--space-4); padding-right: var(--space-4); }
.px-6 { padding-left: var(--space-6); padding-right: var(--space-6); }

/* === DISPLAY === */
.d-none { display: none; }
.d-block { display: block; }
.d-flex { display: flex; }
.d-grid { display: grid; }
.d-inline { display: inline; }
.d-inline-flex { display: inline-flex; }

/* === POSITION === */
.relative { position: relative; }

/* === OVERFLOW === */
.overflow-hidden { overflow: hidden; }

/* === WIDTH === */
.w-full { width: 100%; }

/* === ACCESSIBILITY — Screen reader only === */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

/* === SKIP LINK — Pristupačnost === */
.skip-link {
  position: absolute;
  top: -100%;
  left: var(--space-4);
  padding: var(--space-3) var(--space-5);
  background: var(--gradient-cta);
  color: #FFFFFF;
  border-radius: var(--radius-md);
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
  z-index: var(--z-toast);
  transition: top var(--duration-normal) var(--ease-out);
}

.skip-link:focus {
  top: var(--space-4);
}

/* === VISIBILITY PO UREĐAJU === */
.hidden-mobile {
  /* Sakriveno ispod 768px — definisano u responsive.css */
}

.hidden-desktop {
  /* Sakriveno iznad 1024px — definisano u responsive.css */
}

/* === IMAGE UTILITIES === */
.img-cover {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.img-contain {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* === ASPECT RATIOS === */
.aspect-video { aspect-ratio: 16 / 9; }
.aspect-square { aspect-ratio: 1 / 1; }
.aspect-card { aspect-ratio: 4 / 3; }

/* === ROUNDED === */
.rounded { border-radius: var(--radius-md); }
.rounded-lg { border-radius: var(--radius-lg); }
.rounded-xl { border-radius: var(--radius-xl); }
.rounded-full { border-radius: var(--radius-full); }

/* === NO SELECT === */
.no-select {
  -webkit-user-select: none;
  user-select: none;
}

/* === TRUNCATE TEXT === */
.truncate {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.line-clamp-2 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.line-clamp-3 {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
