/* =========================================================
   Profi Upravnik — Maximilian AI
   Minimalistički, mobile-first dizajn sistem
   ========================================================= */

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

:root {
  /* Palette — light, lavender-tinted */
  --bg:        #f6f4fc;
  --bg-soft:   #faf9fe;
  --surface:   #ffffff;
  --ink:       #181527;
  --ink-2:     #3d3a52;
  --muted:     #6c6885;
  --line:      #ece8f7;
  --line-2:    #e1dcf1;

  --violet:        #6d4af0;
  --violet-600:    #5a35e0;
  --violet-700:    #4a29c4;
  --violet-soft:   #efeafe;
  --violet-tint:   #f4f1fe;
  --violet-glow:   #c9bafb;

  --mint:    #16b289;     /* secondary accent for "AI/eco" cues */
  --mint-soft: #e3f7f0;

  --amber:   #f0a93a;

  /* Effects */
  --radius:    18px;
  --radius-sm: 12px;
  --radius-lg: 26px;
  --radius-pill: 999px;
  --shadow-sm: 0 1px 2px rgba(24, 21, 39, .04), 0 2px 8px rgba(24, 21, 39, .04);
  --shadow:    0 4px 14px rgba(67, 45, 160, .07), 0 18px 48px rgba(67, 45, 160, .08);
  --shadow-violet: 0 10px 30px rgba(109, 74, 240, .28);

  --maxw: 1120px;
  --ease: cubic-bezier(.22, .61, .36, 1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  font-family: 'Manrope', system-ui, -apple-system, 'Segoe UI', sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.6;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

p { font-size: 16px; }

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }

/* ---------- Layout ---------- */
.wrap { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: 20px; }
.section { padding-block: 64px; }
.section-sm { padding-block: 40px; }

@media (min-width: 768px) {
  body { font-size: 17px; }
  p { font-size: 19px; }
  .wrap { padding-inline: 32px; }
  .section { padding-block: 104px; }
}

/* ---------- Typography ---------- */
h1, h2, h3, h4 { line-height: 1.12; letter-spacing: -0.02em; font-weight: 800; color: var(--ink); text-wrap: balance; }

.display {
  font-size: clamp(2.1rem, 8.5vw, 4.2rem);
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 1.04;
}
.h2 { font-size: clamp(1.7rem, 5.5vw, 2.6rem); letter-spacing: -0.03em; }
.h3 { font-size: clamp(1.25rem, 4vw, 1.5rem); letter-spacing: -0.02em; }
.page-hero-title { margin-top: 12px; font-size: clamp(2rem, 7vw, 3.4rem); }
.article-hero-title { font-size: clamp(1.9rem, 6vw, 3rem); }
.feature-title { font-size: 1.15rem; }
.meta-text { font-size: .88rem; }
.meta-text-sm { font-size: .85rem; }
.support-text { font-size: .95rem; }
.fine-print { font-size: .92rem; }

.lead { font-size: clamp(1.05rem, 3.4vw, 1.28rem); color: var(--ink-2); line-height: 1.55; font-weight: 500; text-wrap: pretty; }
.muted { color: var(--muted); }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: .82rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
  color: var(--violet-600);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  font-weight: 700; font-size: 1rem;
  padding: 15px 24px; border-radius: var(--radius-pill);
  border: 1.5px solid transparent;
  transition: transform .25s var(--ease), box-shadow .25s var(--ease), background .2s, border-color .2s, color .2s;
  white-space: nowrap; line-height: 1;
}
.btn svg { width: 18px; height: 18px; }
.btn-primary { background: var(--violet); color: #fff; box-shadow: var(--shadow-violet); }
.btn-primary:hover { background: var(--violet-600); transform: translateY(-2px); box-shadow: 0 14px 36px rgba(109,74,240,.36); }
.btn-primary:active { transform: translateY(0); }
.btn-ghost { background: var(--surface); color: var(--ink); border-color: var(--line-2); box-shadow: var(--shadow-sm); }
.btn-ghost:hover { border-color: var(--violet-glow); transform: translateY(-2px); color: var(--violet-700); }
.btn-soft { background: var(--violet-soft); color: var(--violet-700); }
.btn-soft:hover { background: #e6deff; transform: translateY(-2px); }
.btn-lg { padding: 17px 30px; font-size: 1.06rem; }
.btn-block { width: 100%; }

/* ---------- Badge / chip ---------- */
.badge {
  display: inline-flex; align-items: center; gap: 9px;
  padding: 8px 15px 8px 11px; border-radius: var(--radius-pill);
  background: var(--surface); border: 1px solid var(--line-2);
  font-size: .85rem; font-weight: 600; color: var(--ink-2);
  box-shadow: var(--shadow-sm);
}
.badge .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--mint); position: relative; }
.badge .dot::after {
  content: ''; position: absolute; inset: -4px; border-radius: 50%;
  border: 1.5px solid var(--mint); opacity: .5; animation: pulse 2.4s var(--ease) infinite;
}
@keyframes pulse { 0% { transform: scale(.7); opacity: .6; } 80%, 100% { transform: scale(1.7); opacity: 0; } }

.chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 13px; border-radius: var(--radius-pill);
  background: var(--violet-tint); color: var(--violet-700);
  font-size: .8rem; font-weight: 600;
}

/* ---------- Card ---------- */
.card {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 26px;
  box-shadow: var(--shadow-sm);
  transition: transform .3s var(--ease), box-shadow .3s var(--ease), border-color .3s;
}
.card-hover:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: var(--violet-soft); }

/* ---------- Header / Nav ---------- */
.site-header {
  position: sticky; top: 0; z-index: 60;
  background: rgba(246, 244, 252, .82);
  backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s, background .3s;
}
.site-header.scrolled { border-color: var(--line-2); background: rgba(246,244,252,.92); }
.nav { display: flex; align-items: center; justify-content: space-between; height: 66px; }
.brand { display: inline-flex; align-items: center; gap: 11px; font-weight: 800; letter-spacing: -.02em; font-size: 1.06rem; }
.brand .mark {
  width: 34px; height: 34px; border-radius: 10px; flex: none;
  background: linear-gradient(135deg, var(--violet), #9a7bff);
  display: grid; place-items: center; color: #fff; font-weight: 800; font-size: .95rem;
  box-shadow: 0 4px 12px rgba(109,74,240,.35);
}
.brand small { display: block; font-size: .68rem; font-weight: 600; color: var(--muted); letter-spacing: .02em; margin-top: 1px; }
.brand .brand-txt { line-height: 1.05; }

.nav-links { display: none; }
.nav-actions { display: flex; align-items: center; gap: 10px; }
.nav-cta { display: none; }

.menu-btn {
  display: inline-flex; flex-direction: column; gap: 5px; justify-content: center;
  width: 44px; height: 44px; border-radius: 12px; border: 1px solid var(--line-2);
  background: var(--surface); padding: 0 12px; box-shadow: var(--shadow-sm);
}
.menu-btn span { height: 2px; background: var(--ink); border-radius: 2px; transition: transform .3s var(--ease), opacity .2s; }
.menu-btn.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.menu-btn.open span:nth-child(2) { opacity: 0; }
.menu-btn.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

@media (min-width: 920px) {
  .nav-links {
    display: flex; align-items: center; gap: 4px;
    position: static; background: none; padding: 0; box-shadow: none; height: auto; transform: none; opacity: 1; visibility: visible;
  }
  .nav-links a {
    padding: 9px 14px; border-radius: var(--radius-pill); font-weight: 600; font-size: .96rem; color: var(--ink-2);
    transition: background .2s, color .2s;
  }
  .nav-links a:hover { background: var(--violet-tint); color: var(--violet-700); }
  .nav-links a.active { color: var(--violet-700); background: var(--violet-soft); }
  .nav-cta { display: inline-flex; }
  .menu-btn { display: none; }
}

/* Mobile drawer */
.mobile-menu {
  position: fixed; inset: 66px 0 0; z-index: 55;
  background: var(--bg); padding: 18px 20px 40px;
  transform: translateY(-8px); opacity: 0; visibility: hidden;
  transition: opacity .3s var(--ease), transform .3s var(--ease), visibility .3s;
  display: flex; flex-direction: column; gap: 6px;
  overflow-y: auto;
}
.mobile-menu.open { opacity: 1; visibility: visible; transform: none; }
.mobile-menu a.m-link {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 18px; border-radius: var(--radius); font-size: 1.15rem; font-weight: 700;
  background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-sm);
}
.mobile-menu a.m-link.active { color: var(--violet-700); border-color: var(--violet-glow); }
.mobile-menu a.m-link span { color: var(--violet-glow); }
.mobile-menu .m-cta { margin-top: 14px; display: grid; gap: 10px; }
@media (min-width: 920px) { .mobile-menu { display: none; } }

/* ---------- Hero ---------- */
.hero { position: relative; padding-top: 30px; padding-bottom: 56px; overflow: hidden; }
.hero-orbs { position: absolute; inset: 0; z-index: 0; pointer-events: none; }
.hero-orbs i {
  position: absolute; border-radius: 50%; filter: blur(58px); opacity: .55;
}
.hero-orbs i:nth-child(1) { width: 320px; height: 320px; background: var(--violet-glow); top: -90px; right: -80px; }
.hero-orbs i:nth-child(2) { width: 260px; height: 260px; background: #b9e9da; bottom: -60px; left: -70px; opacity: .4; }
.hero-orbs i:nth-child(3) { width: 200px; height: 200px; background: #d9caff; top: 40%; left: 50%; opacity: .35; }
.hero-inner { position: relative; z-index: 1; }
@media (min-width: 768px) { .hero { padding-top: 56px; padding-bottom: 90px; } }

/* dotted grid background util */
.dotgrid {
  background-image: radial-gradient(var(--line-2) 1.1px, transparent 1.1px);
  background-size: 22px 22px;
}

/* ---------- Stat / feature rows ---------- */
.grid { display: grid; gap: 16px; }
.grid-2 { grid-template-columns: 1fr; }
.grid-3 { grid-template-columns: 1fr; }
.grid-4 { grid-template-columns: 1fr 1fr; }
@media (min-width: 640px) { .grid-2 { grid-template-columns: 1fr 1fr; } .grid-3 { grid-template-columns: 1fr 1fr; } }
@media (min-width: 920px) {
  .grid { gap: 20px; }
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
  .grid-4 { grid-template-columns: repeat(4, 1fr); }
}

.feature-ic {
  width: 48px; height: 48px; border-radius: 14px; flex: none;
  display: grid; place-items: center; margin-bottom: 16px;
  background: var(--violet-soft); color: var(--violet-700);
}
.feature-ic.mint { background: var(--mint-soft); color: var(--mint); }
.feature-ic svg { width: 24px; height: 24px; }

/* ---------- Section heading block ---------- */
.sec-head { max-width: 640px; margin-bottom: 36px; }
.sec-head.center { margin-inline: auto; text-align: center; }
.sec-head p { margin-top: 14px; }

/* ---------- Placeholder image ---------- */
.ph {
  position: relative; border-radius: var(--radius); overflow: hidden;
  background:
    repeating-linear-gradient(135deg, #efeafe 0 12px, #f6f2ff 12px 24px);
  border: 1px solid var(--line-2);
  display: grid; place-items: center; color: var(--violet-700);
  font-family: ui-monospace, 'SF Mono', Menlo, monospace; font-size: .8rem; font-weight: 600;
  min-height: 180px; text-align: center; padding: 16px;
}

/* ---------- Footer ---------- */
.site-footer { background: #14111f; color: #cfcadf; padding-block: 56px 30px; margin-top: 20px; }
.site-footer a { color: #cfcadf; }
.site-footer a:hover { color: #fff; }
.footer-grid { display: grid; gap: 34px; grid-template-columns: 1fr; }
@media (min-width: 760px) { .footer-grid { grid-template-columns: 1.6fr 1fr 1fr; gap: 40px; } }
.footer-col h4 { color: #fff; font-size: .8rem; text-transform: uppercase; letter-spacing: .08em; margin-bottom: 16px; font-weight: 700; }
.footer-col a { display: block; padding: 6px 0; font-weight: 500; font-size: .98rem; }
.footer-brand .brand .mark { box-shadow: none; }
.footer-brand .brand { color: #fff; }
.footer-brand p { color: #9a95b0; margin-top: 16px; max-width: 320px; font-size: .96rem; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.1); margin-top: 40px; padding-top: 22px; display: flex; flex-wrap: wrap; gap: 10px; justify-content: space-between; color: #837e99; font-size: .88rem; }

/* ---------- Reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; transition: none; } }

/* ---------- Utility ---------- */
.center { text-align: center; }
.stack { display: flex; flex-direction: column; }
.row { display: flex; align-items: center; }
.gap-8 { gap: 8px; } .gap-12 { gap: 12px; } .gap-16 { gap: 16px; }
.wrap-btns { display: flex; flex-wrap: wrap; gap: 12px; }
.mt-8 { margin-top: 8px; } .mt-16 { margin-top: 16px; } .mt-24 { margin-top: 24px; } .mt-32 { margin-top: 32px; }
.divider { height: 1px; background: var(--line-2); border: 0; }
.tinted { background: var(--bg-soft); }
.white-bg { background: var(--surface); }
