/* ─── Design System ──────────────────────────────────────────────────────── */
:root {
  --accent:       #e84393;   /* roza — primarna barva */
  --accent-dark:  #c2185b;
  --accent-light: #fce4ec;
  --bg:           #ffffff;
  --surface:      #f9f9fb;
  --surface-2:    #f1f1f5;
  --border:       #e5e7eb;
  --text:         #111827;
  --text-sec:     #6b7280;
  --text-ter:     #9ca3af;
  --radius:       12px;
  --radius-sm:    8px;
  --shadow:       0 1px 4px rgba(0,0,0,.07), 0 4px 16px rgba(0,0,0,.06);
  --shadow-md:    0 4px 24px rgba(0,0,0,.12);
  --font:         'Inter', system-ui, sans-serif;
}

[data-theme="temna"] {
  --bg:        #0f0f13;
  --surface:   #1a1a22;
  --surface-2: #222230;
  --border:    #2e2e3e;
  --text:      #f3f4f6;
  --text-sec:  #9ca3af;
  --text-ter:  #6b7280;
  --accent-light: #3d0a26;
}

/* ─── Reset & Base ───────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; }
body { font-family: var(--font); background: var(--bg); color: var(--text); line-height: 1.6; -webkit-font-smoothing: antialiased; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }
input, textarea, select, button { font-family: inherit; font-size: 1rem; }

/* ─── Typography ─────────────────────────────────────────────────────────── */
h1 { font-size: 2rem; font-weight: 700; line-height: 1.2; }
h2 { font-size: 1.4rem; font-weight: 700; }
h3 { font-size: 1.1rem; font-weight: 600; }
.text-sm  { font-size: .875rem; }
.text-xs  { font-size: .78rem; }
.text-sec { color: var(--text-sec); }
.font-600 { font-weight: 600; }
.font-700 { font-weight: 700; }

/* ─── Layout ─────────────────────────────────────────────────────────────── */
.container    { max-width: 1100px; margin: 0 auto; padding: 0 1.25rem; }
.container-sm { max-width:  560px; margin: 0 auto; padding: 0 1.25rem; }
.container-md { max-width:  780px; margin: 0 auto; padding: 0 1.25rem; }

/* ─── Nav ────────────────────────────────────────────────────────────────── */
nav {
  position: sticky; top: 0; z-index: 100;
  background: var(--bg); border-bottom: 1px solid var(--border);
  display: flex; align-items: center; justify-content: space-between;
  padding: .75rem 1.5rem; gap: 1rem;
}
.nav-logo { font-size: 1.25rem; font-weight: 700; color: var(--text); letter-spacing: -.02em; }
.nav-logo span { color: var(--accent); }
.nav-links { display: flex; align-items: center; gap: .75rem; }

/* ─── Buttons ────────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .4rem;
  padding: .55rem 1.25rem; border-radius: var(--radius-sm); border: 1px solid transparent;
  font-size: .9rem; font-weight: 600; cursor: pointer; transition: background .15s, opacity .15s;
  white-space: nowrap; text-decoration: none;
}
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn-primary   { background: var(--accent); color: #fff; border-color: var(--accent); }
.btn-primary:hover { background: var(--accent-dark); border-color: var(--accent-dark); }
.btn-secondary { background: var(--surface-2); color: var(--text); border-color: var(--border); }
.btn-secondary:hover { background: var(--border); }
.btn-ghost  { background: none; color: var(--text-sec); border-color: transparent; }
.btn-ghost:hover { background: var(--surface-2); }
.btn-outline { background: none; color: var(--accent); border-color: var(--accent); }
.btn-outline:hover { background: var(--accent-light); }
.btn-danger { background: #fee2e2; color: #dc2626; border-color: #fca5a5; }
.btn-danger:hover { background: #fca5a5; }
.btn-sm { padding: .35rem .85rem; font-size: .82rem; }
.btn-lg { padding: .75rem 2rem; font-size: 1rem; }
.btn-full { width: 100%; }

/* ─── Cards ──────────────────────────────────────────────────────────────── */
.card {
  background: var(--bg); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 1.5rem; box-shadow: var(--shadow);
}
.card-sm { padding: 1rem; border-radius: var(--radius-sm); }
.card-hover { transition: box-shadow .15s, transform .15s; cursor: pointer; }
.card-hover:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }

/* ─── Forms ──────────────────────────────────────────────────────────────── */
.form-group { margin-bottom: 1.1rem; }
.form-group label { display: block; font-size: .875rem; font-weight: 500; margin-bottom: .35rem; color: var(--text); }
.form-group input,
.form-group select,
.form-group textarea {
  width: 100%; padding: .6rem .9rem; border: 1px solid var(--border);
  border-radius: var(--radius-sm); background: var(--bg); color: var(--text);
  transition: border-color .15s; outline: none;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(232,67,147,.12); }
.form-group textarea { resize: vertical; min-height: 90px; }
.form-row { display: flex; gap: 1rem; flex-wrap: wrap; }
.form-row .form-group { flex: 1; min-width: 180px; }

/* ─── Alerts ─────────────────────────────────────────────────────────────── */
.alert { padding: .75rem 1rem; border-radius: var(--radius-sm); font-size: .875rem; margin-bottom: 1rem; }
.alert-success { background: #f0fdf4; color: #166534; border: 1px solid #bbf7d0; }
.alert-error   { background: #fef2f2; color: #991b1b; border: 1px solid #fecaca; }
.alert-info    { background: #eff6ff; color: #1e40af; border: 1px solid #bfdbfe; }
.alert-warn    { background: #fffbeb; color: #92400e; border: 1px solid #fde68a; }

/* ─── Badges ─────────────────────────────────────────────────────────────── */
.badge { display: inline-flex; align-items: center; padding: .2rem .6rem; border-radius: 99px; font-size: .75rem; font-weight: 600; }
.badge-pink  { background: var(--accent-light); color: var(--accent-dark); }
.badge-green { background: #dcfce7; color: #166534; }
.badge-gray  { background: var(--surface-2); color: var(--text-sec); }
.badge-blue  { background: #dbeafe; color: #1d4ed8; }

/* ─── Score ring (ujemanje %) ────────────────────────────────────────────── */
.score-ring { position: relative; display: inline-flex; align-items: center; justify-content: center; width: 56px; height: 56px; }
.score-ring svg { position: absolute; inset: 0; transform: rotate(-90deg); }
.score-ring .score-num { font-size: .95rem; font-weight: 700; color: var(--accent); position: relative; }

/* ─── Match card ─────────────────────────────────────────────────────────── */
.match-card {
  display: flex; align-items: center; gap: 1rem;
  padding: 1rem; border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--bg); transition: box-shadow .15s;
}
.match-card:hover { box-shadow: var(--shadow-md); }
.match-avatar {
  width: 60px; height: 60px; border-radius: 50%; object-fit: cover;
  background: var(--surface-2); flex-shrink: 0; font-size: 1.75rem;
  display: flex; align-items: center; justify-content: center;
}
.match-info { flex: 1; min-width: 0; }
.match-ime  { font-weight: 600; font-size: 1rem; }
.match-meta { font-size: .82rem; color: var(--text-sec); margin-top: .1rem; }

/* ─── Onboarding wizard ──────────────────────────────────────────────────── */
.wizard-step { display: none; }
.wizard-step.active { display: block; }
.wizard-progress { display: flex; gap: .35rem; margin-bottom: 2rem; }
.wizard-dot { flex: 1; height: 4px; border-radius: 2px; background: var(--border); transition: background .3s; }
.wizard-dot.done { background: var(--accent); }

/* ─── Tag chips (vrednote, interesi) ────────────────────────────────────── */
.chip-grid { display: flex; flex-wrap: wrap; gap: .5rem; }
.chip {
  padding: .3rem .85rem; border: 1.5px solid var(--border); border-radius: 99px;
  font-size: .85rem; cursor: pointer; transition: background .12s, border-color .12s, color .12s;
  background: var(--bg); color: var(--text-sec); user-select: none;
}
.chip:hover { border-color: var(--accent); color: var(--accent); }
.chip.selected { background: var(--accent-light); border-color: var(--accent); color: var(--accent-dark); font-weight: 600; }

/* ─── Utility ────────────────────────────────────────────────────────────── */
.hidden   { display: none !important; }
.flex     { display: flex; }
.flex-between { display: flex; align-items: center; justify-content: space-between; }
.text-center  { text-align: center; }
.mt-1 { margin-top: .5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mb-1 { margin-bottom: .5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.gap-1 { gap: .5rem; }
.gap-2 { gap: 1rem; }

.spinner {
  width: 24px; height: 24px; border: 3px solid var(--border);
  border-top-color: var(--accent); border-radius: 50%;
  animation: spin .7s linear infinite; display: inline-block;
}
@keyframes spin { to { transform: rotate(360deg); } }

.divider { border: none; border-top: 1px solid var(--border); margin: 1.5rem 0; }

/* ─── Responsive ─────────────────────────────────────────────────────────── */
@media (max-width: 600px) {
  h1 { font-size: 1.5rem; }
  nav { padding: .65rem 1rem; }
  .container, .container-sm, .container-md { padding: 0 1rem; }
  .form-row { flex-direction: column; gap: 0; }
}
