/* ═══════════════════════════════════════════════════════════════
   sati.ink — Globalni dizajn sistem
   Verzija: 1.0 · 2026-05-19
   Koristi: html.dark / html.light klase na <html> elementu
   Anti-FOUC: inline <script> u <head> svake stranice
   ═══════════════════════════════════════════════════════════════ */

/* ── Varijable: tamna tema (default) ── */
:root {
  --bg:     #0a0e1a;
  --bg2:    #131a2a;
  --card:   #1a2238;
  --card2:  #1f2940;
  --text:   #e8eef9;
  --muted:  #8b9bb8;
  --border: rgba(255,255,255,0.08);
  --accent: #00d4ff;
  --gold:   #ffd700;
  --err:    #ff4d6d;
  --ok:     #00e5a0;
  --r:      12px;
}

/* ── Varijable: svjetla tema ── */
html.light {
  --bg:     #fafbfc;
  --bg2:    #ffffff;
  --card:   #f0f3f8;
  --card2:  #e8edf5;
  --text:   #0a0e1a;
  --muted:  #4a5670;
  --border: rgba(0,0,0,0.08);
  --accent: #007fa8;
  --gold:   #b38600;
  --err:    #c0392b;
  --ok:     #0a7a55;
}

/* ── Fallback za system light preference (ako nema JS klase) ── */
@media (prefers-color-scheme: light) {
  :root:not(.dark) {
    --bg:     #fafbfc;
    --bg2:    #ffffff;
    --card:   #f0f3f8;
    --card2:  #e8edf5;
    --text:   #0a0e1a;
    --muted:  #4a5670;
    --border: rgba(0,0,0,0.08);
    --accent: #007fa8;
    --gold:   #b38600;
    --err:    #c0392b;
    --ok:     #0a7a55;
  }
}

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

/* ── Base ── */
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Inter", sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  transition: background 0.25s, color 0.25s;
  min-height: 100vh;
}
code, pre { font-family: "JetBrains Mono", "SF Mono", Consolas, monospace; }
a { color: var(--accent); text-decoration: none; transition: color 0.15s; }
a:hover { color: var(--gold); }
h1, h2, h3, h4 { font-weight: 700; line-height: 1.2; }
h2.section-title {
  font-size: clamp(24px, 4vw, 32px);
  margin-bottom: 36px;
  text-align: center;
}

/* ── Layout ── */
.container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
section { padding: 64px 0; }

/* ── Logo ── */
.logo { font-weight: 800; font-size: 20px; letter-spacing: -0.5px; cursor: pointer; }
.logo .dot { color: var(--accent); }
.logo .ink { color: var(--muted); font-weight: 400; }

/* ── Nav ── */
.site-nav {
  display: flex; justify-content: space-between; align-items: center;
  padding: 18px 0; border-bottom: 1px solid var(--border);
  gap: 16px;
}
.nav-links { display: flex; gap: 20px; align-items: center; font-size: 14px; flex-wrap: wrap; }
.nav-links a { color: var(--muted); font-weight: 500; transition: color 0.15s; }
.nav-links a:hover { color: var(--text); }

/* ── Sticky topbar (dashboard/app style) ── */
.topbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 24px; height: 56px;
  background: var(--bg2); border-bottom: 1px solid var(--border);
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: blur(8px);
}

/* ── Buttons ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 10px 20px; border-radius: var(--r);
  font-weight: 600; font-size: 14px; cursor: pointer;
  border: none; font-family: inherit; transition: all 0.2s;
  text-decoration: none; white-space: nowrap;
}
.btn-primary  { background: var(--accent); color: var(--bg); }
.btn-primary:hover  { filter: brightness(1.1); transform: translateY(-1px); color: var(--bg); }
.btn-outline  { background: none; border: 1px solid var(--border); color: var(--muted); }
.btn-outline:hover  { border-color: var(--accent); color: var(--text); }
.btn-gold     { background: var(--gold); color: #0a0e1a; }
.btn-gold:hover     { filter: brightness(1.08); transform: translateY(-1px); }
.btn-ghost    { background: none; border: 1px solid var(--border); color: var(--text); }
.btn-ghost:hover    { background: var(--card2); }
.btn:disabled { opacity: 0.4; cursor: not-allowed; transform: none !important; }

.btn-sm { padding: 7px 14px; font-size: 13px; }
.btn-lg { padding: 14px 28px; font-size: 15px; }

/* ── Theme toggle ── */
.theme-btn {
  background: none; border: 1px solid var(--border);
  color: var(--muted); border-radius: var(--r);
  width: 34px; height: 34px; cursor: pointer;
  font-size: 1rem; display: flex; align-items: center; justify-content: center;
  transition: all 0.2s; flex-shrink: 0;
}
.theme-btn:hover { color: var(--accent); border-color: var(--accent); }

/* ── Cards ── */
.card {
  background: var(--card); padding: 28px;
  border-radius: var(--r); border: 1px solid var(--border);
  transition: border-color 0.2s, box-shadow 0.2s;
}
.card:hover { border-color: var(--accent); }
.card h3 { font-size: 17px; margin-bottom: 10px; color: var(--accent); }
.card p  { color: var(--muted); font-size: 14px; line-height: 1.6; }

/* ── Grids ── */
.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 20px; }
.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; }
.grid-4 { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; }

/* ── Pricing cards ── */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px; max-width: 1000px; margin: 0 auto;
}
.pricing-card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--r); padding: 32px 24px;
  text-align: center; transition: all 0.25s; position: relative;
  display: flex; flex-direction: column;
}
.pricing-card:hover { border-color: var(--accent); box-shadow: 0 4px 24px rgba(0,212,255,0.08); }
.pricing-card.featured {
  border-color: var(--accent);
  box-shadow: 0 0 40px rgba(0,212,255,0.15);
  transform: translateY(-4px);
}
.pricing-card .badge-top {
  position: absolute; top: -13px; left: 50%; transform: translateX(-50%);
  background: var(--accent); color: var(--bg);
  font-size: 10px; font-weight: 700; padding: 4px 16px; border-radius: 20px;
  text-transform: uppercase; letter-spacing: 1.5px; white-space: nowrap;
}
.pc-tier {
  font-size: 11px; text-transform: uppercase; letter-spacing: 2px;
  color: var(--muted); margin-bottom: 14px;
}
.pc-price {
  font-size: 40px; font-weight: 800; color: var(--text); line-height: 1;
  margin-bottom: 4px;
}
.pc-price sub { font-size: 16px; font-weight: 400; color: var(--muted); vertical-align: baseline; }
.pc-period { font-size: 13px; color: var(--muted); margin-bottom: 24px; }
.pc-features {
  list-style: none; text-align: left; margin-bottom: 28px; flex: 1;
}
.pc-features li {
  padding: 7px 0; font-size: 13px; color: var(--muted);
  border-bottom: 1px solid var(--border);
  display: flex; align-items: flex-start; gap: 8px;
}
.pc-features li:last-child { border-bottom: none; }
.pc-features li::before {
  content: "✓"; color: var(--accent); font-weight: 700;
  flex-shrink: 0; margin-top: 1px;
}
.pricing-card .btn { width: 100%; margin-top: auto; }

/* ── Stats ── */
.stats-row {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 20px; padding: 40px 0;
  border-top: 1px solid var(--border); border-bottom: 1px solid var(--border);
}
.stat { text-align: center; }
.stat .num {
  display: block; font-size: 34px; font-weight: 800;
  color: var(--accent); margin-bottom: 4px; line-height: 1;
}
.stat .label {
  font-size: 12px; color: var(--muted);
  text-transform: uppercase; letter-spacing: 1px;
}

/* ── Form inputs ── */
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.field label { font-size: 13px; color: var(--muted); font-weight: 500; }
input[type="text"], input[type="email"], input[type="password"], textarea {
  width: 100%; padding: 11px 14px;
  background: var(--bg); border: 1px solid var(--border);
  border-radius: var(--r); color: var(--text);
  font-size: 14px; font-family: inherit; transition: border-color 0.2s;
}
input:focus, textarea:focus { outline: none; border-color: var(--accent); }

/* ── Alert / notice ── */
.alert {
  padding: 12px 16px; border-radius: var(--r);
  font-size: 13px; display: flex; gap: 10px; align-items: flex-start;
}
.alert-info  { background: rgba(0,212,255,0.08); border: 1px solid rgba(0,212,255,0.25); color: var(--accent); }
.alert-ok    { background: rgba(0,229,160,0.08); border: 1px solid rgba(0,229,160,0.25); color: var(--ok); }
.alert-err   { background: rgba(255,77,109,0.08); border: 1px solid rgba(255,77,109,0.25); color: var(--err); }

/* ── Footer ── */
.site-footer {
  padding: 40px 0; text-align: center; color: var(--muted);
  font-size: 13px; border-top: 1px solid var(--border); margin-top: 40px;
}
.site-footer a { color: var(--muted); margin: 0 10px; }
.site-footer a:hover { color: var(--accent); }

/* ── Accent bar ── */
.accent-line { height: 2px; background: linear-gradient(90deg, var(--accent), var(--gold), var(--accent)); }

/* ── Scrollbar ── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: var(--bg2); }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--muted); }
