:root {
  --bg: #000000;
  --bg-elevated: #111111;
  --nav-bg: #2a2c17;
  --olive: #4c5320;
  --olive-active: #5c6528;
  --olive-border: #6b7530;
  --green-bright: #22c55e;
  --green-card-bg: #0f2418;
  --green-card-border: #1f7a4d;
  --blue-progress: #3b5bfd;
  --text-primary: #ffffff;
  --text-secondary: #9a9a9a;
  --text-muted: #6b6b6b;
  --border: #232323;
  --card-bg: #0d0d0d;
  --danger-red: #e5484d;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  background: var(--bg);
  color: var(--text-primary);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  overscroll-behavior-y: none;
}

body {
  padding-bottom: 76px; /* room for bottom mobile nav */
  min-height: 100vh;
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; }

img, video { max-width: 100%; display: block; }

/* ---------- TOP HEADER ---------- */
.topbar {
  background: var(--nav-bg);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  position: sticky;
  top: 0;
  z-index: 40;
}
.topbar-title { font-weight: 700; font-size: 17px; }
.hamburger-btn {
  width: 40px; height: 40px; display: flex; align-items: center; justify-content: center;
  background: transparent; color: #fff;
}
.hamburger-btn svg { width: 22px; height: 22px; }

/* ---------- MEHR SLIDE-IN PANEL ---------- */
.mehr-overlay {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(0,0,0,0.5);
  opacity: 0; pointer-events: none;
  transition: opacity .2s ease;
}
.mehr-overlay.open { opacity: 1; pointer-events: auto; }
.mehr-panel {
  position: absolute; top: 0; left: 0; bottom: 0;
  width: min(320px, 84vw);
  background: #0a0a0a;
  transform: translateX(-100%);
  transition: transform .25s ease;
  display: flex; flex-direction: column;
  overflow-y: auto;
}
.mehr-overlay.open .mehr-panel { transform: translateX(0); }
.mehr-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px; border-bottom: 1px solid var(--border);
}
.mehr-brand { display: flex; align-items: center; gap: 8px; font-weight: 700; }
.mehr-brand .mark { width: 24px; height: 24px; background: #000; border-radius: 6px; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 800; }
.mehr-brand .mehr-logo-img { width: 26px; height: 26px; border-radius: 6px; object-fit: cover; }
.mehr-header button { background: transparent; color: #fff; font-size: 18px; width: 32px; height: 32px; }
.mehr-list { flex: 1; padding: 6px 0; }
.mehr-row {
  display: flex; align-items: center; gap: 12px;
  padding: 13px 16px; font-size: 14.5px; font-weight: 600; color: #e2e2e2;
  border-bottom: 1px solid #161616;
}
.mehr-ico { font-size: 17px; width: 22px; text-align: center; }
.mehr-userrow {
  display: flex; align-items: center; gap: 12px;
  padding: 16px; border-top: 1px solid var(--border);
}
.mehr-userrow img { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; background: #222; }
.mehr-userrow .name { font-weight: 700; font-size: 14px; }
.mehr-userrow .email { font-size: 12px; color: var(--text-secondary); }
.skeleton-avatar { width: 40px; height: 40px; border-radius: 50%; background: #222; }

/* ---------- BOTTOM MOBILE NAV ---------- */
.bottom-nav {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  background: var(--nav-bg);
  border-top: 1px solid #1c1d10;
  display: flex;
  z-index: 50;
  padding-bottom: env(safe-area-inset-bottom);
}
.bottom-nav a {
  flex: 1;
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  padding: 9px 2px 10px;
  color: #9a9c82;
  font-size: 10.5px;
  font-weight: 600;
}
.bottom-nav a svg { width: 20px; height: 20px; }
.bottom-nav a.active { color: #fff; }
.bottom-nav a.active svg { color: var(--green-bright); }

/* ---------- GENERIC LAYOUT ---------- */
.page { max-width: 720px; margin: 0 auto; }
.section { padding: 16px; }

.hero-video {
  position: relative;
  width: 100%;
  aspect-ratio: 4/5;
  background: #0a0a0a;
  overflow: hidden;
  display: flex; align-items: flex-end;
}
@media (min-width: 720px) { .hero-video { aspect-ratio: 16/8; } }
.hero-video video, .hero-video img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
}
.hero-video .overlay-label {
  position: relative; z-index: 2;
  padding: 24px;
  font-size: 34px;
  font-weight: 800;
  letter-spacing: -0.02em;
  text-shadow: 0 2px 12px rgba(0,0,0,.6);
}
.hero-video .gradient {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0) 40%, rgba(0,0,0,.75) 100%);
  z-index: 1;
}
.hero-video .cta-pill {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%);
  z-index: 3;
  background: var(--olive);
  color: #fff;
  font-weight: 700;
  padding: 16px 28px;
  border-radius: 40px;
  font-size: 18px;
  white-space: nowrap;
}

.wordmark {
  font-size: 15px; letter-spacing: 0.08em; font-weight: 700; color: #e7e7e7;
}
.wordmark .sub { font-size: 9px; letter-spacing: 0.25em; color: #9a9a9a; display:block; margin-top:2px; }

/* ---------- CARDS ---------- */
.card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 16px;
}
.card-green {
  background: var(--green-card-bg);
  border: 1px solid var(--green-card-border);
  border-radius: 14px;
  padding: 18px 16px;
}
.card-green .row { display: flex; gap: 14px; align-items: flex-start; }
.card-green .badge5 {
  width: 60px; height: 60px; border-radius: 50%;
  border: 2px solid var(--green-bright);
  background: #0d2417;
  display: flex; align-items: center; justify-content: center;
  font-weight: 800; color: var(--green-bright); font-size: 16px;
  flex-shrink: 0; overflow: hidden;
}
.card-green .badge5 img { width: 100%; height: 100%; object-fit: contain; }
.card-green h3 { font-size: 16px; margin-bottom: 5px; font-weight: 800; letter-spacing: -0.01em; line-height: 1.25;}
.card-green p { font-size: 13.5px; color: #a9c9b6; line-height: 1.5; }
.btn-green {
  display: block; width: 100%;
  background: var(--green-bright);
  color: #06170d;
  font-weight: 800;
  text-align: center;
  padding: 13px;
  border-radius: 10px;
  margin-top: 14px;
  font-size: 14.5px;
}

.btn-olive {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%;
  background: var(--olive);
  color: #fff;
  font-weight: 700;
  padding: 13px;
  border-radius: 10px;
  font-size: 14.5px;
}
.btn-olive:active { background: var(--olive-active); }
.btn-olive.done { background: #3a4016; }

/* ---------- SECTION TITLES ---------- */
.section-title {
  font-size: 13px; font-weight: 700; color: #d8d8d8;
  text-transform: uppercase; letter-spacing: 0.04em;
  margin-bottom: 10px;
}
.section-title .right { float: right; color: var(--text-secondary); font-weight: 600; text-transform: none; }

/* ---------- PROGRESS BAR ---------- */
.progress-track {
  width: 100%; height: 4px; background: #1c1c1c; border-radius: 4px; overflow: hidden;
  margin-top: 6px;
}
.progress-fill { height: 100%; background: var(--blue-progress); border-radius: 4px; transition: width .4s ease; }

/* ---------- CALENDAR ---------- */
.calendar { border: 1px solid var(--border); border-radius: 12px; overflow: hidden; background: #121212; }
.calendar-head { display: flex; align-items: center; justify-content: space-between; padding: 12px 14px; background: #161616; }
.calendar-head h4 { font-size: 15px; font-weight: 700; }
.calendar-head .nav-btns { display: flex; gap: 6px; }
.calendar-head .nav-btns button {
  width: 28px; height: 28px; border-radius: 50%; background: #1a1a1a; color: #fff;
  display: flex; align-items: center; justify-content: center;
}
.calendar-grid { display: grid; grid-template-columns: repeat(7, 1fr); background: #121212; }
.calendar-grid .dow { text-align: center; font-size: 11px; color: var(--text-muted); padding: 6px 0; border-bottom: 1px solid #232323; background: #161616; }
.calendar-grid .day {
  aspect-ratio: 1; border-right: 1px solid #232323; border-bottom: 1px solid #232323;
  padding: 6px; font-size: 12px; color: #d8d8d8; position: relative; background: #151515;
}
.calendar-grid .day.muted { color: #4a4a4a; background: #101010; }
.calendar-grid .day .done-badge {
  position: absolute; bottom: 5px; left: 5px; right: 5px;
  background: var(--green-bright); color: #06170d;
  border-radius: 4px; font-size: 10px; font-weight: 800;
  padding: 1px 0; text-align: center;
}

/* ---------- COMMUNITY PREVIEW ---------- */
.avatar-row { display: flex; gap: 12px; overflow-x: auto; padding: 4px 2px 2px; }
.avatar-row img { width: 64px; height: 64px; border-radius: 50%; object-fit: cover; flex-shrink: 0; background:#222; }
.btn-olive-outline {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%;
  background: var(--olive);
  color: #fff; font-weight: 700; font-size: 14px;
  padding: 12px; border-radius: 10px; margin-bottom: 14px;
}

/* ---------- PROFILE ---------- */
.profile-head { text-align: center; padding: 30px 20px 10px; }
.profile-head .avatar-big {
  width: 96px; height: 96px; border-radius: 50%; object-fit: cover;
  border: 3px solid var(--nav-bg);
  margin: 0 auto 16px; background: #222;
}
.profile-head h1 { font-size: 21px; font-weight: 800; }
.btn-outline-sm {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--olive); color: #fff; font-weight: 700; font-size: 13px;
  padding: 9px 16px; border-radius: 20px; margin-top: 14px;
}
.since-text { color: var(--text-secondary); font-size: 12.5px; margin-top: 12px; }

.quick-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.quick-cards .qc {
  background: var(--card-bg); border: 1px solid var(--border); border-radius: 12px;
  padding: 14px 6px; text-align: center; font-size: 12px; font-weight: 600; color: #d8d8d8;
}
.quick-cards .qc svg { width: 20px; height: 20px; margin: 0 auto 6px; display:block; }

.weight-strip {
  background: var(--card-bg); border: 1px solid var(--border);
  border-radius: 10px; padding: 10px 14px; font-size: 13px; color: #d8d8d8; font-weight: 600;
}

/* ---------- TRENINZI LIST ---------- */
.program-tabs { display: flex; gap: 8px; }
.program-tabs button {
  flex: 1; background: var(--card-bg); border: 1px solid var(--border);
  color: #d8d8d8; font-weight: 700; font-size: 13.5px;
  padding: 13px 6px; border-radius: 10px;
}
.program-tabs button.active { background: var(--olive); border-color: var(--olive-border); color: #fff; }

.week-grid { display: grid; grid-template-columns: 1fr; gap: 16px; margin-top: 16px; }
.workout-card {
  background: var(--card-bg); border: 1px solid var(--border); border-radius: 12px; overflow: hidden;
}
.workout-card .thumb {
  aspect-ratio: 16/9; background: #0a0a0a; position: relative; overflow: hidden;
}
.workout-card .thumb img { width: 100%; height: 100%; object-fit: cover; }
.workout-card .thumb .badge {
  position: absolute; top: 6px; right: 6px; background: #b6ff3c; color: #06170d;
  font-size: 8.5px; font-weight: 800; padding: 2px 5px; border-radius: 4px; line-height: 1.3; text-align:right;
}
.workout-card .thumb .duration-badge {
  position: absolute; top: 6px; left: 6px; background: rgba(0,0,0,.7); color: #fff;
  font-size: 10px; font-weight: 700; padding: 2px 6px; border-radius: 4px;
}
.workout-card .thumb .completed-check {
  position: absolute; bottom: 6px; right: 6px;
  width: 22px; height: 22px; border-radius: 50%;
  background: var(--green-bright); display: flex; align-items: center; justify-content: center;
}
.workout-card .meta { padding: 10px 10px 12px; }
.workout-card .meta .duration { font-size: 10.5px; color: var(--text-muted); font-weight: 700; text-transform: uppercase; }
.workout-card .meta .day { font-size: 13.5px; font-weight: 700; margin-top: 2px; }
.workout-card.pause .thumb { display:flex; align-items:center; justify-content:center; }
.workout-card.pause .thumb span { font-weight: 800; letter-spacing: 0.1em; color: #444; font-size: 13px;}

/* ---------- TRENING DETAIL ---------- */
.breadcrumb {
  padding: 14px 16px 0; font-size: 13px; color: var(--text-secondary); display: flex; align-items: center; gap: 6px;
}
.breadcrumb b { color: #fff; }

.video-wrap { position: relative; width: 100%; aspect-ratio: 16/9; background: #050505; margin-top: 12px; }
.video-wrap video { width: 100%; height: 100%; object-fit: cover; }
.video-wrap .vid-overlay-top {
  position: absolute; top: 10px; left: 10px; right: 10px; display: flex; justify-content: space-between; z-index: 2; pointer-events:none;
}
.video-wrap .timer { background: rgba(0,0,0,.75); font-weight: 800; font-size: 20px; padding: 4px 10px; border-radius: 6px; }
.video-wrap .level-box { background: #b6ff3c; color: #06170d; font-size: 10px; font-weight: 800; padding: 4px 8px; border-radius: 4px; text-align: right; line-height: 1.35; }
.video-wrap .caption-bar {
  position: absolute; bottom: 0; left: 0; right: 0; background: rgba(0,0,0,.55);
  color: #fff; font-size: 12px; padding: 6px 10px; text-align: center; z-index: 2;
}

.day-title { font-size: 21px; font-weight: 800; padding: 16px 16px 4px; }

.instructor-row {
  display: flex; align-items: center; gap: 12px; padding: 12px 16px;
  border-bottom: 1px solid var(--border);
}
.instructor-row img { width: 54px; height: 54px; border-radius: 10px; object-fit: cover; background:#222; }
.instructor-row .name { font-weight: 700; font-size: 14.5px; }
.instructor-row .role { font-size: 12.5px; color: var(--text-secondary); }
.instructor-row .chev { margin-left: auto; color: var(--text-muted); }

.completed-note { padding: 14px 16px 0; font-size: 13px; color: #d8d8d8; }
.duration-line { padding: 8px 16px 0; font-size: 12.5px; color: var(--text-secondary); display:flex; align-items:center; gap:6px; }
.mark-done-wrap { padding: 16px; }

.workout-content { padding: 4px 16px 40px; }
.workout-content h3 { font-size: 17px; font-weight: 800; margin: 20px 0 12px; }
.wblock { margin-bottom: 22px; }
.wblock .block-title { font-size: 13px; font-weight: 800; color: #e2e2e2; text-transform: uppercase; margin-bottom: 8px; }
.wblock .move { font-size: 13.5px; color: #cfcfcf; margin-bottom: 4px; }
.wblock .eq { font-size: 13px; color: #8a8a8a; margin: 6px 0; }
.wblock .divider { border-top: 1px solid #262626; margin: 8px 0; width: 34px; }
.wblock .level { font-size: 13px; color: #9a9a9a; }

.see-all-btn {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  margin: 8px 16px 24px; padding: 14px; border-radius: 10px;
  background: #14150c; border: 1px solid var(--border); color: #b7bd8f; font-weight: 700; font-size: 13px;
}

.toast {
  position: fixed; bottom: 90px; left: 50%; transform: translateX(-50%);
  background: #1c1c1c; border: 1px solid var(--green-card-border); color: #fff;
  padding: 10px 18px; border-radius: 30px; font-size: 13.5px; font-weight: 600;
  z-index: 100; opacity: 0; pointer-events: none; transition: opacity .25s, transform .25s;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(-6px); }

/* ---------- COMMUNITY / RANG LISTA / ONLINE (Faza 2) ---------- */
.page-hero-banner {
  background: var(--nav-bg);
  padding: 20px 16px;
  font-size: 22px;
  font-weight: 800;
}
.intro-text { padding: 16px; color: #cfcfcf; font-size: 14px; line-height: 1.5; }

.member-list { display: flex; flex-direction: column; }
.member-row {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 16px; border-bottom: 1px solid var(--border);
}
.member-row img { width: 52px; height: 52px; border-radius: 50%; object-fit: cover; background: #222; flex-shrink: 0; }
.member-row .info { flex: 1; min-width: 0; }
.member-row .info .name { font-weight: 700; font-size: 14.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.member-row .info .sub { font-size: 12.5px; color: var(--text-secondary); margin-top: 2px; }
.member-row .chev { color: var(--text-muted); font-size: 18px; }
.member-row .rank-num { font-weight: 800; font-size: 15px; width: 22px; text-align: center; color: #d8d8d8; flex-shrink: 0; }
.member-row .rank-num.top1 { color: #ffd700; }
.member-row .rank-num.top2 { color: #c0c0c0; }
.member-row .rank-num.top3 { color: #cd7f32; }

.online-dot { width: 9px; height: 9px; border-radius: 50%; display: inline-block; margin-right: 6px; }
.online-dot.on { background: #22c55e; }
.online-dot.off { background: #e5484d; }

.empty-state { padding: 40px 20px; text-align: center; color: var(--text-secondary); font-size: 14px; }

/* Community member profile page */
.member-profile-banner {
  background: var(--nav-bg); padding: 30px 16px 60px; position: relative;
}
.member-profile-card {
  margin: -50px 16px 0; background: var(--bg); position: relative;
  display: flex; gap: 14px; align-items: flex-end;
}
.member-profile-card img { width: 88px; height: 88px; border-radius: 14px; object-fit: cover; border: 3px solid #000; background:#222; }
.member-profile-card h1 { font-size: 19px; font-weight: 800; margin-bottom: 4px; }
.member-profile-card .status { font-size: 12.5px; color: var(--text-secondary); display:flex; align-items:center; }

.stat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; padding: 20px 16px; }
.stat-grid .stat .label { font-size: 12px; color: var(--text-secondary); margin-bottom: 3px; }
.stat-grid .stat .value { font-size: 14px; font-weight: 700; }
.stat-grid .stat .value a { color: #6bc98a; }

.bio-section { padding: 0 16px 30px; }
.bio-section h3 { font-size: 16px; font-weight: 800; margin-bottom: 8px; }
.bio-section p { color: #cfcfcf; font-size: 13.5px; line-height: 1.5; }

.chat-invite-card {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  background: var(--olive); color: #fff; font-weight: 700; padding: 13px;
  border-radius: 10px; margin: 0 16px 14px;
}

/* ---------- 28 DAY RESET CHALLENGE ---------- */
.challenge-frame { border: 1px solid var(--green-card-border); border-radius: 14px; overflow: hidden; }
.challenge-title-bar { background: var(--green-card-bg); text-align: center; padding: 16px; }
.challenge-title-bar h2 { font-size: 17px; font-weight: 800; }
.challenge-title-bar p { font-size: 12px; color: #a9c9b6; margin-top: 4px; }

.challenge-task-grid { display: grid; grid-template-columns: 1fr 1fr; }
.challenge-task {
  background: var(--green-card-bg); border-top: 1px solid #123a26; padding: 16px; text-align: center;
}
.challenge-task .num { color: var(--green-bright); font-weight: 800; font-size: 13px; margin-bottom: 6px; }
.challenge-task .label { font-weight: 700; font-size: 13.5px; }
.challenge-task.done { opacity: 0.55; }
.challenge-task.done .label { text-decoration: line-through; }

.challenge-ready-bar { background: var(--green-card-bg); border-top: 1px solid #123a26; text-align: center; padding: 16px; }
.challenge-ready-bar .eyebrow { font-size: 12px; color: #a9c9b6; }
.challenge-ready-bar .main { font-weight: 800; font-size: 14px; margin-top: 2px; }

.challenge-intro { text-align: center; color: var(--text-secondary); font-size: 13px; padding: 18px 10px; line-height: 1.5; }

.tasks-today-title { font-size: 13px; font-weight: 700; color: #d8d8d8; text-transform: uppercase; margin-bottom: 6px; }

.progress-day-grid { display: grid; grid-template-columns: 1fr 1fr; }
.progress-day-card {
  background: var(--green-card-bg); padding: 16px; text-align: center; border: 1px solid var(--green-card-border);
}
.progress-day-card .num { color: var(--green-bright); font-weight: 800; font-size: 13px; }
.progress-day-card .daylabel { font-weight: 800; font-size: 15px; margin: 4px 0; color: #7a8b7f; }
.progress-day-card .instr { font-size: 12px; color: #a9c9b6; margin-bottom: 8px; }
.progress-day-card .open-link { color: var(--green-bright); font-weight: 700; font-size: 12.5px; }

.upload-label { font-weight: 700; font-size: 14px; margin: 18px 0 8px; }
.upload-box {
  display: flex; align-items: center; gap: 10px; background: var(--card-bg); border: 1px solid var(--border);
  border-radius: 10px; padding: 13px 14px; color: var(--text-muted); font-size: 13.5px;
}

.challenge-footer-text { color: var(--text-secondary); font-size: 12.5px; line-height: 1.6; padding: 18px 4px 30px; }

.cal-toggle { display: flex; align-items: center; gap: 8px; }
.cal-toggle select {
  background: #1a1a1a; color: #fff; border: 1px solid var(--border); border-radius: 8px; padding: 5px 8px; font-size: 12.5px;
}

/* ---------- TVOJA ANALIZA ---------- */
.goal-list { display: flex; flex-direction: column; }
.goal-row { display: flex; align-items: center; gap: 16px; padding: 14px 16px; border-bottom: 1px solid var(--border); }
.goal-row .thumb { width: 96px; height: 68px; border-radius: 8px; overflow: hidden; flex-shrink: 0; display:flex; }
.goal-row .thumb img { width: 50%; height: 100%; object-fit: cover; }
.goal-row .label { font-weight: 700; font-size: 15px; }

.analiza-hero { display: flex; aspect-ratio: 16/9; }
.analiza-hero img { width: 50%; height: 100%; object-fit: cover; }
.analiza-goal-title { font-size: 24px; font-weight: 800; padding: 20px 16px 4px; }

.tip-block { padding: 16px; }
.tip-block .tip-text { font-size: 13.5px; color: #d8b96b; font-weight: 600; line-height: 1.5; margin-bottom: 10px; }
.tip-block img { width: 100%; border-radius: 10px; aspect-ratio: 16/10; object-fit: cover; }

.info-block { background: var(--card-bg); border: 1px solid var(--border); border-radius: 12px; padding: 16px; margin: 0 16px 16px; }
.info-block p { font-size: 13.5px; color: #d8d8d8; line-height: 1.6; margin-bottom: 10px; }
.info-block p:last-child { margin-bottom: 0; }
.info-block b { color: #fff; }

/* ---------- KETTLEBELLS KALKULATOR ---------- */
.kb-frame { border: 1px solid var(--green-card-border); border-radius: 14px; overflow: hidden; }
.kb-header { background: var(--green-card-bg); text-align: center; padding: 18px 16px; }
.kb-header h2 { font-size: 16px; font-weight: 800; }
.kb-header p { font-size: 13px; color: #a9c9b6; margin-top: 4px; }

.kb-card { position: relative; background: var(--card-bg); border-top: 1px solid var(--border); padding: 16px; padding-right: 90px; }
.kb-card .meta { font-size: 12px; color: var(--text-secondary); margin-bottom: 8px; }
.kb-card .tier { color: var(--green-bright); font-weight: 800; font-size: 14px; margin-bottom: 6px; }
.kb-card .row { font-weight: 700; font-size: 14.5px; line-height: 1.5; }
.kb-card .focus { font-size: 12.5px; color: var(--text-secondary); margin-top: 8px; }
.kb-card .score-badge {
  position: absolute; top: 16px; right: 16px;
  width: 52px; height: 52px; border-radius: 50%; border: 2px solid var(--green-bright);
  display: flex; align-items: center; justify-content: center; font-weight: 800; color: var(--green-bright); font-size: 14px;
}
.kb-footer { background: var(--green-card-bg); border-top: 1px solid var(--green-card-border); text-align: center; padding: 18px; }
.kb-footer .q { font-size: 13px; color: #a9c9b6; }
.kb-footer .a { font-weight: 800; font-size: 14.5px; margin-top: 4px; }

/* ---------- NOVOSTI NEDELJE ---------- */
.news-heading { text-align: center; font-size: 17px; font-weight: 800; padding: 16px; }
.news-item { margin-bottom: 8px; }
.news-item .posted { font-size: 12.5px; color: var(--text-secondary); padding: 10px 16px 0; }
.news-item .section-h { font-size: 15px; font-weight: 800; text-align: center; padding: 20px 16px 12px; }

/* ---------- PREPORUCI I ZARADI ---------- */
.referral-link-box {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  background: var(--card-bg); border: 1px solid var(--border); border-radius: 10px;
  padding: 13px 14px; margin: 14px 16px; color: #d8b96b; font-weight: 700; font-size: 13.5px;
}
.referral-link-box button { background: var(--olive); color: #fff; border-radius: 8px; padding: 6px 12px; font-size: 12px; font-weight: 700; flex-shrink:0; }

/* ---------- PITANJA I ODGOVORI ---------- */
.faq-intro { padding: 16px; font-size: 14px; color: #d8d8d8; }
.faq-item { padding: 14px 16px; border-bottom: 1px solid var(--border); }
.faq-item .q { font-weight: 700; font-size: 14.5px; margin-bottom: 6px; }
.faq-item .a { font-size: 13.5px; color: #b8b8b8; line-height: 1.5; }

/* ---------- USLOVI KORISCENJA ---------- */
.legal-text { padding: 16px; font-size: 14px; color: #d8d8d8; line-height: 1.7; }
.legal-text h2 { font-size: 17px; font-weight: 800; color: #fff; margin-bottom: 14px; }
.legal-text p { margin-bottom: 16px; }

/* ---------- HOME PAGE (tacan redosled po originalu) ---------- */
.scan-promo-card { border: 1px solid var(--green-card-border); border-radius: 16px; overflow: hidden; margin: 0 16px; }
.scan-promo-head { display: flex; align-items: center; gap: 14px; padding: 16px; background: var(--green-card-bg); }
.scan-promo-head img { width: 54px; height: 54px; border-radius: 10px; object-fit: cover; }
.scan-promo-head h2 { font-size: 17px; font-weight: 800; }
.scan-promo-badge { display: inline-block; margin-top: 4px; background: rgba(34,197,94,.15); color: var(--green-bright); font-size: 10.5px; font-weight: 800; padding: 3px 9px; border-radius: 20px; }
.scan-benefits-row { display: flex; gap: 14px; padding: 10px 16px; background: var(--green-card-bg); border-top: 1px solid #123a26; font-size: 11px; color: #a9c9b6; font-weight: 700; flex-wrap: wrap; }
.scan-weeks-strip { display: flex; gap: 8px; overflow-x: auto; padding: 14px 16px; background: #06110c; }
.scan-weeks-strip .wk { flex-shrink: 0; text-align: center; width: 84px; }
.scan-weeks-strip .wk img { width: 84px; height: 110px; object-fit: cover; border-radius: 8px; border: 1px solid #1f7a4d; }
.scan-weeks-strip .wk span { display: block; font-size: 10px; font-weight: 800; margin-top: 6px; color: #d8d8d8; }
.scan-how-row { padding: 10px 16px; background: var(--green-card-bg); border-top: 1px solid #123a26; font-size: 11.5px; color: var(--green-bright); font-weight: 700; }
.scan-how-row b { color: #fff; }
.scan-cta-btn { display: block; text-align: center; margin: 14px 16px; background: var(--green-bright); color: #06170d; font-weight: 800; padding: 14px; border-radius: 10px; font-size: 14px; }

.hero-cta-pill {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%);
  z-index: 3; background: var(--olive); color: #fff; font-weight: 700;
  padding: 15px 30px; border-radius: 40px; font-size: 16px; white-space: nowrap;
}

.live-bar {
  display: flex; align-items: center; gap: 10px; margin: 16px; padding: 13px 16px;
  border: 1px solid var(--green-card-border); border-radius: 12px; font-size: 13.5px; font-weight: 700;
}
.live-bar .dot { width: 9px; height: 9px; border-radius: 50%; background: var(--green-bright); animation: pulse-dot 1.5s infinite; }
@keyframes pulse-dot { 0%,100%{opacity:1;} 50%{opacity:.3;} }
.live-bar .tag { color: var(--green-bright); font-weight: 800; letter-spacing: .04em; }

.activity-heading { font-size: 19px; font-weight: 800; padding: 4px 16px 12px; }
.activity-progress-row { display: flex; align-items: center; justify-content: space-between; padding: 0 16px; font-size: 13px; color: var(--text-secondary); margin-bottom: 8px; }

.activity-stat-card { margin: 0 16px 16px; background: var(--card-bg); border: 1px solid var(--border); border-radius: 16px; padding: 30px 16px; display: flex; flex-direction: column; align-items: center; }
.activity-stat-frame {
  width: 130px; height: 130px; border: 1.5px solid #3a3a3a; border-radius: 4px;
  display: flex; align-items: center; justify-content: center; margin-bottom: -18px;
}
.activity-stat-frame .num { font-size: 42px; font-weight: 800; color: #fff; }
.activity-stat-pill { background: #1a1a1a; border: 1px solid var(--border); border-radius: 8px; padding: 10px 22px; font-size: 13px; font-weight: 700; color: #d8d8d8; }

.analiza-avatar-card img.avatar-photo {
  width: 88px; height: 88px; border-radius: 50%; object-fit: cover;
  border: 2px solid var(--green-bright); flex-shrink: 0;
  box-shadow: 0 0 14px rgba(34,197,94,.35);
}

.community-section-btn { display: flex; align-items: center; justify-content: center; gap: 8px; margin: 0 16px 14px; background: var(--olive); color: #fff; font-weight: 700; padding: 13px; border-radius: 10px; font-size: 14.5px; }
.community-meta-row { display: flex; align-items: center; justify-content: space-between; padding: 4px 16px 16px; font-size: 13px; }
.community-meta-row .count { color: var(--text-secondary); }
.community-meta-row .see-all { color: #d8d8d8; font-weight: 700; }

.shop-promo-card { margin: 0 16px 16px; border-radius: 14px; overflow: hidden; position: relative; min-height: 260px; display: flex; }
.shop-promo-card img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 0; }
.shop-promo-card .gradient { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,.25) 0%, rgba(0,0,0,.35) 40%, rgba(0,0,0,.88) 100%); z-index: 1; }
.shop-promo-card .content {
  position: relative; z-index: 2; margin-top: auto; width: 100%;
  padding: 20px; display: flex; flex-direction: column; gap: 4px;
}
.shop-promo-card .content h2 { font-size: 19px; font-weight: 800; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; line-height: 1.25; }
.shop-promo-card .live-badge { background: var(--olive); color: #fff; font-size: 10.5px; font-weight: 800; padding: 3px 10px; border-radius: 6px; flex-shrink: 0; }
.shop-promo-card p { font-size: 13.5px; color: #e2e2e2; margin: 8px 0 14px; line-height: 1.4; }
.shop-promo-card .btn { display: inline-block; align-self: flex-start; background: var(--olive); color: #fff; font-weight: 700; padding: 12px 22px; border-radius: 10px; font-size: 14px; }

/* ---------- EDIT PROFIL ---------- */
.edit-form { padding: 16px; display: flex; flex-direction: column; gap: 14px; }
.edit-form label { font-size: 13px; font-weight: 700; color: #d8d8d8; }
.edit-form input {
  width: 100%; background: #1a1a1a; border: 1px solid var(--border); color: #fff;
  padding: 12px 14px; border-radius: 10px; font-size: 14px; margin-top: 6px;
}

/* ---------- ADMIN PANEL ---------- */
.admin-section { padding: 16px; }
.admin-section h2 { font-size: 16px; font-weight: 800; margin-bottom: 12px; }
.admin-field { margin-bottom: 12px; }
.admin-field label { display: block; font-size: 12.5px; font-weight: 700; color: #d8d8d8; margin-bottom: 5px; }
.admin-field input, .admin-field select, .admin-field textarea {
  width: 100%; background: #1a1a1a; border: 1px solid var(--border); color: #fff;
  padding: 11px 12px; border-radius: 8px; font-size: 13.5px; font-family: inherit;
}
.admin-field textarea { min-height: 100px; resize: vertical; white-space: pre-line; }
.admin-divider { height: 1px; background: var(--border); margin: 24px 0; }
.admin-list-item {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 10px 0; border-bottom: 1px solid #1a1a1a; font-size: 13px;
}
.admin-list-item .del-btn { background: var(--danger-red); color: #fff; padding: 5px 10px; border-radius: 6px; font-size: 11.5px; font-weight: 700; flex-shrink: 0; }
.admin-count-row { display: flex; align-items: center; gap: 10px; }
.admin-count-row input { width: 70px; }

/* ---------- ONLINE/OFFLINE TOGGLE ---------- */
.online-toggle-row {
  display: flex; align-items: center; justify-content: space-between;
  background: var(--card-bg); border: 1px solid var(--border); border-radius: 12px; padding: 14px 16px;
}
.switch { position: relative; display: inline-block; width: 46px; height: 26px; flex-shrink: 0; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch-slider {
  position: absolute; cursor: pointer; inset: 0; background: #333; border-radius: 26px; transition: .2s;
}
.switch-slider::before {
  content: ""; position: absolute; height: 20px; width: 20px; left: 3px; bottom: 3px;
  background: #fff; border-radius: 50%; transition: .2s;
}
.switch input:checked + .switch-slider { background: var(--green-bright); }
.switch input:checked + .switch-slider::before { transform: translateX(20px); }

/* ---------- NOVOSTI NEDELJE (kompletna verzija) ---------- */
.news-post { position: relative; }
.news-post .icons-topright { position: absolute; top: 14px; right: 14px; z-index: 2; display: flex; flex-direction: column; gap: 10px; }
.news-post .icons-topright span { width: 34px; height: 34px; background: rgba(0,0,0,.6); border-radius: 50%; display: flex; align-items: center; justify-content: center; color: #fff; font-size: 15px; }
.news-post .icons-bottomleft { position: absolute; bottom: 14px; left: 14px; z-index: 2; }
.news-post .icons-bottomleft span { width: 34px; height: 34px; background: rgba(0,0,0,.6); border-radius: 50%; display: flex; align-items: center; justify-content: center; color: #fff; font-size: 15px; }
.news-post .yt-badge {
  position: absolute; bottom: 14px; right: 14px; z-index: 2;
  background: rgba(0,0,0,.75); color: #fff; font-size: 12px; font-weight: 700;
  padding: 6px 12px; border-radius: 6px; display: flex; align-items: center; gap: 6px;
}
.news-posted-date { padding: 8px 16px 0; font-size: 12.5px; color: var(--text-secondary); }
.news-section-heading { text-align: center; font-size: 17px; font-weight: 800; padding: 24px 16px 12px; }

.mini-rang-list { display: flex; flex-direction: column; }
.mini-rang-row { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--border); }
.mini-rang-row img { width: 46px; height: 46px; border-radius: 50%; object-fit: cover; background:#222; }
.mini-rang-row .name { font-weight: 700; font-size: 14px; }
.mini-rang-row .hrs { font-size: 12.5px; color: var(--text-secondary); }
.mini-rang-row .chev { margin-left: auto; color: var(--text-muted); }

.quote-of-week-box { background: var(--olive); text-align: center; padding: 18px 20px; margin: 0 16px 16px; border-radius: 12px; font-weight: 700; font-size: 15px; }
.quote-of-week-box .bang { color: #e5484d; }

.location-section { padding: 4px 16px 0; }
.location-section h2 { font-size: 19px; font-weight: 800; margin-bottom: 4px; }
.location-section .city { font-size: 22px; font-weight: 800; margin-bottom: 10px; }
.location-section p { font-size: 13.5px; color: var(--text-secondary); margin-bottom: 14px; }
.location-map { width: 100%; aspect-ratio: 16/10; border: 0; border-radius: 12px; }

.team-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 16px; }
.team-card { background: var(--card-bg); border-radius: 12px; overflow: hidden; }
.team-card img { width: 100%; aspect-ratio: 1; object-fit: cover; background: #222; }
.team-card .info { padding: 10px; }
.team-card .name { font-weight: 700; font-size: 13px; }
.team-card .role { font-size: 11.5px; color: var(--text-secondary); }

/* ---------- PLAIN HERO SLIKE (Borislav sam uploaduje sa vec ugradjenim tekstom) ---------- */
.plain-hero-link { display: block; width: 100%; background: #101010; }
.plain-hero-link img { width: 100%; display: block; object-fit: contain; background: #101010; }
.plain-hero-link.square { aspect-ratio: 1 / 1; }
.plain-hero-link.square img { height: 100%; }
.plain-hero-link.rect { aspect-ratio: 16 / 9; }
.plain-hero-link.rect img { height: 100%; }

/* ---------- ADMIN IMAGE UPLOAD WIDGET ---------- */
.admin-img-field { margin-bottom: 18px; }
.admin-img-field label { display: block; font-size: 12.5px; font-weight: 700; color: #d8d8d8; margin-bottom: 8px; }
.admin-img-preview {
  width: 100%; max-height: 140px; object-fit: cover; border-radius: 10px;
  background: #1a1a1a; border: 1px solid var(--border); display: block; margin-bottom: 8px;
}
.admin-img-preview:not([src]), .admin-img-preview[src=""] { display: none; }
.admin-upload-btn { width: 100%; }
.admin-upload-status { font-size: 11.5px; color: var(--text-secondary); margin-top: 6px; }

/* ---------- SPREČAVANJE "TREPTANJA" SLIKA PRI UČITAVANJU ---------- */
img { background: #0d0d0d; }
/* Sprečava da se vidi "slomljena slika" ikonica ili prazan prostor
   dok se nova slika učitava kada se predje sa stranice na stranicu */
img:not([src]), img[src=""] { visibility: hidden; }
img:not([src]), img[src=""] { visibility: hidden; }

/* ---------- CHALLENGE UPLOAD PREVIEW ---------- */
.upload-preview-img { width: 100%; max-height: 260px; object-fit: cover; border-radius: 10px; margin: 8px 0; display: block; }

/* ---------- HAMBURGER: 3 opcije inline (klik na ime) ---------- */
#__mehr-account-options { flex-direction: column; gap: 8px; }
.mehr-account-card {
  display: flex; align-items: center; gap: 10px;
  background: #161616; border: 1px solid var(--border); border-radius: 10px;
  padding: 12px 14px; font-size: 13.5px; font-weight: 600; color: #e2e2e2;
}
.mehr-userrow[type="button"] { background: transparent; font-family: inherit; }

/* ---------- SAKRIJ ONESIGNAL SOPSTVENO ZVONCE (garancija) ----------
   notifyButton:false u OneSignal.init() TREBA da ovo spreči, ali ovo je
   dodatna, tvrda garancija preko CSS-a — bez obzira šta OneSignal SDK
   interno uradi (keširano stanje, dashboard podešavanje, race condition
   pri učitavanju), ovo zvonce NIKAD ne sme biti vidljivo. Pokriva sve
   poznate varijante naziva koje OneSignal koristi kroz verzije. */
#onesignal-bell-container,
.onesignal-bell-launcher,
.onesignal-bell-launcher-button,
.OneSignal-bell-launcher,
[id*="onesignal-bell"],
[class*="onesignal-bell"],
iframe[id*="onesignal"] {
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
  pointer-events: none !important;
  width: 0 !important;
  height: 0 !important;
}

/* ---------- Admin tabela korisnika - polja za direktnu izmenu ---------- */
.admin-cell-input {
  background: #1a1a1a; border: 1px solid var(--border); color: #fff;
  padding: 5px 7px; border-radius: 6px; font-size: 12px; width: 100%;
}
.admin-cell-input:focus { border-color: #3cff88; outline: none; }
#users-table-wrap table { min-width: 700px; }
