/* ========== ROOT ========== */
:root {
  --bg: #0b1325;
  --bg-2: #0e1a33;
  --surface: #111a33;
  --card: #0f1730;
  --line: #1a2445;
  --text: #e7ecff;
  --muted: #9bb0da;
  --accent-1: #4cc2ff;
  --accent-2: #6b7dff;
  --accent-3: #00e0ff;
  --radius: 16px;
  --shadow: 0 10px 30px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.02);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, Arial,
    sans-serif;
  background: radial-gradient(
      1200px 600px at 75% -10%,
      rgba(76, 194, 255, 0.25),
      transparent 60%
    ),
    radial-gradient(
      900px 500px at 10% 0%,
      rgba(107, 125, 255, 0.22),
      transparent 60%
    ),
    var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* Container i razmak */
.container {
  width: min(1180px, 90%);
  margin-inline: auto;
}

.container.narrow {
  width: min(900px, 90%);
}

.section {
  position: relative;
}

.pad-xl {
  padding: 120px 0 100px;
}

.pad-lg {
  padding: 96px 0;
}

.center {
  text-align: center;
}

.small {
  font-size: 0.95rem;
}

.muted {
  color: var(--muted);
}

.section-lead {
  color: var(--muted);
  margin-top: 0.5rem;
}

/* Gradient text */
.grad-text {
  background: linear-gradient(
    92deg,
    var(--accent-1),
    var(--accent-2) 45%,
    var(--text) 100%
  );
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 1px 0 rgba(255, 255, 255, 0.04));
}

/* ====== Header / Nav ====== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: saturate(140%) blur(10px);
  background: linear-gradient(
    to bottom,
    rgba(10, 15, 30, 0.7),
    rgba(10, 15, 30, 0.3)
  );
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 14px 0;
}

.download-links {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  text-decoration: none;
  color: #fff;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 14px;
  font-weight: 500;
  background: #0b1226;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
  letter-spacing: 0.2px;
  color: var(--text);
  text-decoration: none;
}

.brand-dot {
  width: 100px;
  height: 50px;
}

.brand.foot {
  font-weight: 600;
}

.main-nav ul {
  display: flex;
  list-style: none;
  gap: 22px;
  margin: 0;
  padding: 0;
}

.main-nav a {
  color: var(--muted);
  text-decoration: none;
  font-weight: 500;
}

.main-nav a:hover,
.main-nav a.active {
  color: var(--text);
}

.main-nav a.active {
  color: var(--text);
  font-weight: 700;
  border-bottom: 2px solid var(--accent-1);
}

/* ======= Hamburger mobile zatvaranje ======= */
.nav-toggle {
  position: relative;
  width: 42px;
  height: 40px;
  padding: 0;
}

.nav-toggle span {
  position: absolute;
  left: 8px;
  right: 8px;
  height: 2px;
  background: #dfe7ff;
  border-radius: 2px;
  transform-origin: 50% 50%;
  transition: top 220ms ease, transform 220ms ease, opacity 180ms ease;
}

.nav-toggle span:nth-child(1) {
  top: 12px;
}

.nav-toggle span:nth-child(2) {
  top: 19px;
}

.nav-toggle span:nth-child(3) {
  top: 26px;
}

.nav-toggle.open span:nth-child(1) {
  top: 19px;
  transform: rotate(45deg);
}

.nav-toggle.open span:nth-child(2) {
  opacity: 0;
  transform: scaleX(0.5);
}

.nav-toggle.open span:nth-child(3) {
  top: 19px;
  transform: rotate(-45deg);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 18px;
  border-radius: 12px;
  background: var(--line);
  color: var(--text);
  text-decoration: none;
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: var(--shadow);
}

.btn.small {
  padding: 10px 14px;
}

.btn.ghost {
  background: transparent;
  border-color: rgba(255, 255, 255, 0.12);
}

.btn-grad {
  background: linear-gradient(92deg, var(--accent-2), var(--accent-1));
  border: 0;
}

/* ======= Mobile nav toggle ======= */
.nav-toggle {
  display: none;
  background: none;
  border: 0;
  width: 42px;
  height: 40px;
  gap: 5px;
}

.nav-toggle span {
  display: block;
  height: 2px;
  background: #dfe7ff;
}

/* Hero */
.hero-grid {
  display: grid;
  grid-template-columns: 1.25fr 1fr;
  gap: 56px;
  align-items: center;
}

.hero-copy .eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 0.82rem;
  color: #cfe2ff;
  background: linear-gradient(
    180deg,
    rgba(107, 125, 255, 0.18),
    rgba(76, 194, 255, 0.14)
  );
  border: 1px solid rgba(255, 255, 255, 0.08);
  font-weight: 800;
}

.hero h1 {
  font-size: clamp(34px, 5vw, 60px);
  line-height: 1.02;
  margin: 14px 0;
}

.lead {
  font-size: 1.1rem;
  color: #d6e1ff;
  max-width: 52ch;
}

.hero-bullets {
  margin: 18px 0 24px;
  padding-left: 18px;
  color: #c8d6ff;
}

.hero-bullets li {
  margin: 6px 0;
}

.store-buttons {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin: 8px 0 18px;
}

.download-button {
  background: #000;
  display: inline-block;
  border-radius: 8px;
  padding: 0;
  overflow: hidden;
}

.download-links:hover {
  background-color: rgba(255, 255, 255, 0.15);
}

.store-btn .badge {
  height: 44px;
}

.badge-bg {
  fill: #0b1226;
}

.badge-top {
  fill: #cfe2ff;
  font: 600 10px/1 Inter, system-ui;
}

.badge-bottom {
  fill: #fff;
  font: 800 16px/1 Inter, system-ui;
}

.trust-row {
  display: flex;
  align-items: center;
  gap: 5px;
}

.logo-row {
  display: flex;
  gap: 5px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.logo-row li {
  color: #a9c0ff;
  font-weight: 600;
}

/* Hero visual / device */
.hero {
  position: relative;
  overflow: hidden;
}

/* Wrapper za sliku */
.hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  overflow: hidden;
}

.hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

/* Overlay da potamni sliku */
.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(11, 19, 37, 0.5),
    rgba(11, 19, 37, 0.85)
  );
}

/* Sadržaj hero sekcije preko slike */
.hero-grid {
  position: relative;
  z-index: 1;
}

.device-frame {
  position: relative;
  width: 60%;
  aspect-ratio: 9/19.5;
  margin-inline: auto;
  border-radius: 36px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: radial-gradient(
      120% 90% at 20% 0%,
      rgba(107, 125, 255, 0.18),
      transparent 60%
    ),
    linear-gradient(180deg, #0d1630, #0c1329);
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.45),
    inset 0 0 0 8px rgba(255, 255, 255, 0.04);
}

.device-glow {
  position: absolute;
  inset: -8% -8%;
  background: radial-gradient(
      60% 35% at 70% 10%,
      rgba(76, 194, 255, 0.25),
      transparent 60%
    ),
    radial-gradient(50% 30% at 20% 90%, rgba(0, 224, 255, 0.2), transparent 60%);
  filter: blur(30px);
  z-index: 0;
}

.device-placeholder {
  overflow: hidden;
  position: absolute;
  inset: 12px;
  border-radius: 28px;
  background: #0a1024;
  display: grid;
  place-items: center;
  color: #88a2ff;
  text-align: center;
  z-index: 1;
  border: 1px solid rgba(255, 255, 255, 0.08);

  align-items: stretch;
  justify-content: stretch;
}

.hero-img {
  display: block;
  object-fit: cover;
  width: 100%;
  height: 100%;
  border-radius: inherit;
  object-position: top center;
}

/* Cards grid */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  margin-top: 34px;
}

.card {
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.02),
    rgba(255, 255, 255, 0.01)
  );
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 18px;
  padding: 22px;
  min-height: 156px;
  box-shadow: var(--shadow);
}

.card h3 {
  margin: 0 0 8px;
  font-size: 1.05rem;
}

.card p {
  margin: 0;
  color: #c7d5ff;
}

.fade-bg {
  background: radial-gradient(
    8000px 280px at 15% 0%,
    rgba(107, 125, 255, 0.18),
    transparent 60%
  );
}

.steps {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  margin-top: 26px;
}

.step {
  background: var(--card);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 18px;
  padding: 22px;
}

.step h4 {
  margin: 8px 0 6px;
}

.step p {
  color: #c7d5ff;
}

.step-num {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  font-weight: 900;
  background: linear-gradient(92deg, var(--accent-2), var(--accent-1));
  color: #071022;
}

/* ======= Testimonials ======= */
.testimonials {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-top: 28px;
}

.t-card {
  background: var(--card);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 18px;
  padding: 22px;
}

.t-card p {
  margin: 0 0 10px;
}

.t-meta {
  color: #9db2e6;
  font-weight: 600;
}

/* ======= Metrics ======= */
.metrics-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-top: 26px;
}

.metric {
  background: var(--card);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 18px;
  padding: 28px 22px;
  text-align: center;
  box-shadow: var(--shadow);
}

.metric .num {
  font-weight: 900;
  font-size: clamp(32px, 6vw, 56px);
  line-height: 1;
  background: linear-gradient(
    92deg,
    var(--accent-1),
    var(--accent-2) 50%,
    var(--text)
  );
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 1px 0 rgba(255, 255, 255, 0.04));
  letter-spacing: 0.5px;
}
.metric .label {
  margin-top: 10px;
  color: #c7d5ff;
  font-weight: 600;
}

.results-icons {
  width: 40px;
  height: 40px;
  color: var(--accent-3);
}

/* Responsive za metrics */
@media (max-width: 1000px) {
  .metrics-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 720px) {
  .metrics-grid {
    grid-template-columns: 1fr;
  }
}

/* ======= Studio ======= */
.studio .studio-card {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 22px;
  background: var(--card);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 22px;
  padding: 26px;
  box-shadow: var(--shadow);
}

.media-ph {
  border-radius: 16px;
  border: 1px dashed rgba(255, 255, 255, 0.1);
  background: repeating-linear-gradient(
    135deg,
    #0d1630 0 12px,
    #0e1a33 12px 24px
  );
  width: 100%;
  height: 100%;
  min-height: 260px;
}

.studio-links {
  display: flex;
  gap: 10px;
  margin-top: 10px;
}

/* ======= FORMA ======= */

.contact-left {
  max-width: 500px;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-top: 18px;

  background: var(--card);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 16px;
  padding: 22px;
  box-shadow: var(--shadow);
}

/* Grid za mapu */
.map-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: stretch;
}

/* Prognoza (umesto stare kontakt forme) */
.contact-left {
  background: var(--card);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 16px;
  padding: 22px;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-top: 18px;
}

.contact-form input,
.contact-form textarea {
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: var(--surface);
  color: var(--text);
  font: inherit;
}

.contact-form textarea {
  min-height: 110px;
  resize: vertical;
}

/* Mapa desno */
.contact-map {
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow);
  min-height: 400px;
}

/* Responsive */
@media (max-width: 900px) {
  .map-grid {
    grid-template-columns: 1fr;
  }

  .contact-map {
    min-height: 300px;
  }
}

/* ======= Footer ======= */
.site-footer {
  padding: 40px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  background: linear-gradient(to top, rgba(0, 0, 0, 0.35), transparent);
}

.foot-grid {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.foot-links {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.foot-links a {
  color: #b9c7ee;
  text-decoration: none;
}

.foot-links a:hover {
  color: #fff;
}

.landexa {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 20px;
}

.landexa-link {
  color: var(--accent-3);
  text-decoration: none;
  font-weight: 500;
  padding: 5px 10px;
}

.landexa-link:hover {
  text-decoration: underline;
  color: var(--text);
  background: linear-gradient(92deg, var(--accent-2), var(--accent-1));
  border-radius: 9px;
  font-weight: 700;
}

/* Responsive */
@media (max-width: 1000px) {
  .hero-grid {
    grid-template-columns: 1fr;
  }

  .studio .studio-card {
    grid-template-columns: 1fr;
  }

  .steps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .cards-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 720px) {
  .testimonials {
    grid-template-columns: 1fr;
  }

  .logo-row {
    flex-wrap: wrap;
  }

  .nav-toggle {
    display: inline-grid;
  }

  .main-nav {
    position: fixed;
    inset: 60px 0 auto 0;
    background: rgba(10, 15, 30, 0.9);
    backdrop-filter: blur(10px);
    transform: translateY(-8px) scaleY(0);
    transform-origin: top;
    transition: 0.25s;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    flex-direction: column;
    max-height: calc(100dvh - 60px);
    overflow: auto;
  }

  .main-nav.open {
    transform: none;
  }

  .main-nav ul {
    flex-direction: column;
    padding: 14px 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
    padding: 14px 20px;
  }

  .btn.small {
    display: none;
  }

  .foot-grid {
    flex-direction: column;
  }

  .main-nav .nav-cta-mobile {
    display: block;
    position: sticky;
    bottom: 0;
    padding: 10px 20px 12px;
    max-width: 60%;
  }

  .main-nav .nav-cta-mobile .btn {
    width: 100%;
    justify-content: center;
    padding: 10px 14px;
    font-size: 0.95rem;
    border-radius: 10px;
  }
}

.nav-cta-mobile {
  display: none;
}

.margin-bottom {
  margin-bottom: 10px;
}

.margin-bottom-big {
  margin-bottom: 48px;
}

.icons {
  width: 20px;
  height: 20px;
}

.icon-centar {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 7px;
}

.team-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: inherit;
}

/* ======= Reveal animacija ======= */

.reveal {
  opacity: 0;
  transform: translate3d(var(--tx, 0), var(--ty, 16px), 0);
  transition: transform 0.6s ease, opacity 0.6s ease;
  will-change: transform, opacity;
}
.reveal.in {
  opacity: 1;
  transform: translate3d(0, 0, 0);
}

/* Smerovi */
.from-left {
  --tx: -22px;
  --ty: 0;
}
.from-right {
  --tx: 22px;
  --ty: 0;
}
.from-bottom {
  --tx: 0;
  --ty: 22px;
}

@media (prefers-reduced-motion: reduce) {
  .reveal {
    transition: none;
  }
}

/* ======= Weather card ======= */
.weather-card {
  display: flex;
  flex-direction: column;
  gap: 16px;
  background: var(--card);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 16px;
  padding: 22px;
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}

.weather-card::before {
  content: "";
  position: absolute;
  inset: -20% -10% auto -10%;
  height: 55%;
  background: radial-gradient(
      60% 60% at 20% 0%,
      rgba(107, 125, 255, 0.18),
      transparent 60%
    ),
    radial-gradient(
      60% 60% at 80% 10%,
      rgba(76, 194, 255, 0.16),
      transparent 60%
    );
  pointer-events: none;
}

.weather-head h2 {
  margin: 0 0 6px;
}
.weather-head p {
  margin: 0;
}

.weather-main {
  display: grid;
  grid-template-columns: 72px 1fr;
  align-items: center;
  gap: 14px;
}

.wx-icon-wrap {
  width: 72px;
  height: 72px;
  display: grid;
  place-items: center;
  border-radius: 16px;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.04),
    rgba(255, 255, 255, 0.02)
  );
  border: 1px solid rgba(255, 255, 255, 0.06);
}

#wx-icon {
  width: 42px;
  height: 42px;
  color: var(--accent-3);
}

.wx-temp {
  display: flex;
  align-items: baseline;
  gap: 6px;
}

.wx-temp-val {
  font-size: clamp(34px, 6vw, 56px);
  font-weight: 900;
  line-height: 1;
  background: linear-gradient(
    92deg,
    var(--accent-1),
    var(--accent-2) 50%,
    var(--text)
  );
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.wx-unit {
  color: #c7d5ff;
  font-weight: 700;
  align-self: flex-start;
}

.wx-desc {
  margin: 4px 0 2px;
  color: #cfe2ff;
  font-weight: 600;
}

.wx-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}
.wx-item {
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.02),
    rgba(255, 255, 255, 0.01)
  );
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 14px;
  padding: 12px;
  text-align: center;
}
.wx-label {
  display: block;
  font-size: 0.85rem;
  color: var(--muted);
  margin-bottom: 6px;
}

.weather-card.sunny {
  background-image: radial-gradient(
    1200px 400px at 95% -10%,
    rgba(255, 213, 0, 0.1),
    transparent 60%
  );
}

.weather-card.cloudy {
  background-image: radial-gradient(
    1200px 400px at 95% -10%,
    rgba(160, 180, 210, 0.08),
    transparent 60%
  );
}

.weather-card.rainy {
  background-image: radial-gradient(
    1200px 400px at 95% -10%,
    rgba(20, 120, 200, 0.12),
    transparent 60%
  );
}

.weather-card.storm {
  background-image: radial-gradient(
    1200px 400px at 95% -10%,
    rgba(130, 100, 230, 0.12),
    transparent 60%
  );
}

.weather-card.snowy {
  background-image: radial-gradient(
    1200px 400px at 95% -10%,
    rgba(210, 230, 255, 0.12),
    transparent 60%
  );
}

.weather-card.foggy {
  background-image: radial-gradient(
    1200px 400px at 95% -10%,
    rgba(190, 200, 210, 0.1),
    transparent 60%
  );
}

.weather-card.windy {
  background-image: radial-gradient(
    1200px 400px at 95% -10%,
    rgba(0, 224, 255, 0.1),
    transparent 60%
  );
}

/* Responsive za weather grid */
@media (max-width: 900px) {
  .wx-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

html.no-smooth {
  scroll-behavior: auto !important;
}

/* =========== Uredjaji sa koridora =========== */
.device-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin: 20px 0 28px;
}

.chip {
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.04);
  padding: 8px 12px;
  border-radius: 999px;
  font-size: 14px;
  line-height: 1;
  cursor: pointer;
  transition: transform 0.15s ease, background 0.2s ease, border-color 0.2s ease;
}

.chip:hover {
  transform: translateY(-1px);
}

.chip.active {
  border-color: rgba(30, 160, 255, 0.45);
  background: linear-gradient(
    135deg,
    rgba(139, 60, 246, 0.15),
    rgba(30, 160, 255, 0.15)
  );
}

.chip-badge {
  margin-left: 6px;
  font-variant-numeric: tabular-nums;
  opacity: 0.9;
}

/* Grid i kartice */
.devices-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

@media (max-width: 980px) {
  .devices-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .devices-grid {
    grid-template-columns: 1fr;
  }
}

.device-card {
  position: relative;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
  border-radius: 14px;
  padding: 16px;
  overflow: hidden;
  backdrop-filter: blur(6px);
  transition: transform 0.18s ease, border-color 0.2s ease, background 0.2s ease;
}

.device-card:hover {
  transform: translateY(-2px);
  border-color: rgba(139, 60, 246, 0.35);
  background: rgba(255, 255, 255, 0.05);
}

.device-head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.device-ico {
  width: 36px;
  height: 36px;
  display: inline-grid;
  place-items: center;
  border-radius: 10px;
  background: radial-gradient(
    80% 80% at 20% 20%,
    rgba(139, 60, 246, 0.35),
    rgba(30, 160, 255, 0.2)
  );
}

.device-ico ion-icon {
  font-size: 20px;
}

.device-title {
  font-weight: 700;
  line-height: 1.2;
}

.device-meta {
  display: grid;
  gap: 6px;
  font-size: 14px;
  color: #cbd5e1;
}

.device-meta .row {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Status badževi */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.badge.ok {
  background: rgba(34, 197, 94, 0.12);
  border-color: rgba(34, 197, 94, 0.35);
}

.badge.warn {
  background: rgba(234, 179, 8, 0.12);
  border-color: rgba(234, 179, 8, 0.35);
}

.badge.err {
  background: rgba(239, 68, 68, 0.12);
  border-color: rgba(239, 68, 68, 0.35);
}

/* Skeleton */
.device-skeleton {
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: linear-gradient(
    90deg,
    rgba(255, 255, 255, 0.03) 25%,
    rgba(255, 255, 255, 0.06) 37%,
    rgba(255, 255, 255, 0.03) 63%
  );
  background-size: 400% 100%;
  animation: sk 1.2s ease-in-out infinite;
  padding: 16px;
}

.device-skeleton .sk-row {
  height: 14px;
  background: rgba(255, 255, 255, 0.15);
  border-radius: 6px;
  margin-bottom: 10px;
}

.device-skeleton .sk-row.short {
  width: 55%;
}

@keyframes sk {
  0% {
    background-position: 100% 50%;
  }

  100% {
    background-position: 0% 50%;
  }
}

.devices-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 14px;
}

.devices-error {
  display: flex;
  gap: 10px;
  align-items: center;
  color: #fca5a5;
  margin-top: 12px;
}

#devices-metrics {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: stretch;
}

@media (max-width: 640px) {
  #devices-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.device-filters,
.devices-grid {
  display: none !important;
}

#devices-error[hidden] {
  display: none !important;
}

.devices-foot {
  flex-wrap: wrap;
}

@media (max-width: 640px) {
  .devices-foot {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }

  #devices .btn.ghost.small {
    display: inline-flex;
    width: 100%;
    justify-content: center;
  }
}

.download-hover:hover {
  filter: brightness(0.85);
}

/* ======== Lightbox ======== */
.lightbox-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.86);
  backdrop-filter: blur(2px);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.lightbox-overlay.show {
  display: flex;
  opacity: 1;
}

.lightbox-inner {
  position: relative;
  max-width: 92vw;
  max-height: 92vh;
  display: grid;
  place-items: center;
}

.lightbox-img {
  max-width: 92vw;
  max-height: 85vh;
  width: auto;
  height: auto;
  border-radius: 18px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  background: #0b1020;
}

.lightbox-prev,
.lightbox-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.8);
  color: #000;
  display: grid;
  place-items: center;
  font-size: 24px;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease;
}

.lightbox-prev:hover,
.lightbox-next:hover {
  background: rgba(255, 255, 255, 1);
  transform: translateY(-50%) scale(1.05);
}

.lightbox-prev {
  left: -70px;
}

.lightbox-next {
  right: -70px;
}

.lightbox-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.6);
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 20px;
  cursor: pointer;
  transition: background 0.2s ease;
}

.lightbox-close:hover {
  background: rgba(0, 0, 0, 0.8);
}

/* Mobilni prikaz */
@media (max-width: 900px) {
  .lightbox-prev,
  .lightbox-next {
    background: rgba(255, 255, 255, 0.8);
    color: #000;
    width: 42px;
    height: 42px;
  }

  .lightbox-prev {
    left: 12px;
  }

  .lightbox-next {
    right: 12px;
  }

  .lightbox-close {
    top: 10px;
    right: 10px;
  }
}

/* ======== WEATHER ANIMATED OVERLAYS ======= */
.weather-card {
  position: relative;
  overflow: hidden;
}

.wx-anim-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.wx-anim-layer span {
  position: absolute;
  will-change: transform, opacity;
}

.wx-anim-layer,
.wx-anim-layer * {
  animation-play-state: var(--anim-state, running);
}

/* ---- SUNNY ---- */
.weather-card.sunny .wx-anim-layer::after {
  content: "";
  position: absolute;
  inset: -20% -20% auto -20%;
  height: 60%;
  border-radius: 50%;
  background: radial-gradient(
    closest-side,
    rgba(255, 220, 80, 0.25),
    transparent 70%
  );
  animation: sunnyGlow 4s ease-in-out infinite alternate;
}

@keyframes sunnyGlow {
  from {
    transform: translateY(0);
  }
  to {
    transform: translateY(10px);
  }
}

/* ---- CLOUDY ---- */
.weather-card.cloudy .wx-anim-layer span.cloud {
  width: 220px;
  height: 90px;
  top: 10%;
  left: -240px;
  background: radial-gradient(
      60% 80% at 30% 60%,
      rgba(255, 255, 255, 0.08),
      rgba(255, 255, 255, 0) 70%
    ),
    radial-gradient(
      50% 70% at 70% 50%,
      rgba(255, 255, 255, 0.08),
      rgba(255, 255, 255, 0) 70%
    );
  filter: blur(2px);
  animation: cloudDrift 28s linear infinite;
}

.weather-card.cloudy .wx-anim-layer span.cloud:nth-child(2) {
  top: 35%;
  animation-duration: 36s;
  opacity: 0.7;
}

.weather-card.cloudy .wx-anim-layer span.cloud:nth-child(3) {
  top: 60%;
  animation-duration: 44s;
  opacity: 0.5;
}

@keyframes cloudDrift {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(140%);
  }
}

/* ---- RAINY ---- */
.weather-card.rainy .wx-anim-layer span.drop {
  width: 2px;
  height: 16px;
  background: rgba(180, 210, 255, 0.55);
  top: -20px;
  left: var(--x, 50%);
  border-radius: 2px;
  transform: translate3d(0, -40px, 0) rotate(12deg);
  animation: rainFall var(--d, 900ms) linear infinite;
}

@keyframes rainFall {
  to {
    transform: translate3d(0, calc(100vh * 0.25), 0) rotate(12deg);
    opacity: 0.1;
  }
}

/* ---- STORM  ---- */
.weather-card.storm .wx-anim-layer::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    transparent,
    rgba(255, 255, 255, 0.05),
    transparent
  );
  animation: stormFlash 6s ease-in-out infinite;
}

@keyframes stormFlash {
  0%,
  92%,
  100% {
    opacity: 0;
  }

  93% {
    opacity: 0.8;
  }

  94% {
    opacity: 0;
  }

  96% {
    opacity: 0.6;
  }

  97% {
    opacity: 0;
  }
}
.weather-card.storm .wx-anim-layer span.drop {
  background: rgba(200, 220, 255, 0.7);
  height: 18px;
  animation-duration: var(--d, 750ms);
}

/* ---- SNOWY ---- */
.weather-card.snowy .wx-anim-layer span.flake {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 0 6px rgba(255, 255, 255, 0.5);
  top: -10px;
  left: var(--x, 50%);
  transform: translate3d(0, -20px, 0);
  animation: snowFall var(--d, 8s) linear infinite;
  opacity: 0.9;
}

.weather-card.snowy .wx-anim-layer span.flake::after {
  content: "";
  position: absolute;
  inset: -2px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.6);
}

@keyframes snowFall {
  to {
    transform: translate3d(0, calc(100vh * 0.22), 0);
    opacity: 0.2;
  }
}

/* ---- FOGGY ---- */
.weather-card.foggy .wx-anim-layer::after {
  content: "";
  position: absolute;
  inset: -10% -10% -20% -10%;
  background: radial-gradient(
      60% 80% at 50% 10%,
      rgba(220, 230, 240, 0.12),
      transparent 70%
    ),
    radial-gradient(
      60% 80% at 30% 60%,
      rgba(220, 230, 240, 0.08),
      transparent 70%
    ),
    radial-gradient(
      60% 80% at 70% 60%,
      rgba(220, 230, 240, 0.08),
      transparent 70%
    );
  filter: blur(6px);
  animation: fogMove 30s ease-in-out infinite alternate;
}

@keyframes fogMove {
  from {
    transform: translateX(-10px);
  }
  to {
    transform: translateX(10px);
  }
}

/* ---- WINDY  ---- */
.weather-card.windy .wx-anim-layer span.gust {
  height: 2px;
  width: 120px;
  left: -140px;
  top: var(--y, 40%);
  background: linear-gradient(
    90deg,
    transparent,
    rgba(0, 255, 255, 0.28),
    transparent
  );
  filter: blur(0.4px);
  animation: windSweep var(--d, 4.5s) linear infinite;
}

.weather-card.windy .wx-anim-layer span.gust:nth-child(2) {
  top: 55%;
  animation-duration: 5.5s;
}

.weather-card.windy .wx-anim-layer span.gust:nth-child(3) {
  top: 70%;
  animation-duration: 6.2s;
  opacity: 0.7;
}

@keyframes windSweep {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(140%);
  }
}

/* prefers-reduced-motion */
@media (prefers-reduced-motion: reduce) {
  .wx-anim-layer,
  .wx-anim-layer *,
  .weather-card.sunny .wx-anim-layer::after,
  .weather-card.foggy .wx-anim-layer::after,
  .weather-card.storm .wx-anim-layer::before {
    animation: none !important;
  }
}

/* ============= Showcase grid — 3 slike gore + 3 slike dole ============ */
.showcase-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 40px;
  align-items: start;
  justify-items: center;
  margin-top: 36px;
}

.showcase-item {
  background: none;
  border: none;
  box-shadow: none;
  padding: 0;
  max-width: 330px;
}

.showcase-item img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 20px;
  object-fit: cover;
  transition: transform 0.3s ease, filter 0.3s ease;
}

.showcase-item img:hover {
  transform: scale(1.03);
  filter: brightness(0.95);
}

.showcase-item.horizontal img {
  aspect-ratio: 16 / 9;
}
.showcase-item.vertical img {
  aspect-ratio: 9 / 19.5;
  max-width: 220px;
}

.showcase-arrow {
  display: none !important;
}

@media (max-width: 1100px) {
  .showcase-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 28px;
  }
}
@media (max-width: 720px) {
  .showcase-grid {
    grid-template-columns: 3fr;
    gap: 24px;
  }
  .showcase-item {
    max-width: 260px;
  }
}

.margin-showcase {
  margin-top: 90px;
  margin-bottom: 15px;
}

/* ======== download links bottom ======== */

.footer-download {
  align-items: center;
  justify-content: center;
}

.dwnld-bottom {
  background: linear-gradient(92deg, var(--accent-2), var(--accent-1));
}

.dwnld-bottom:hover {
  filter: brightness(0.85);
}

/* =========== Dorada weather Api ============== */
.wx-icon-wrap {
  position: relative;
}

.wx-icon-wrap.night-cloudy::after {
  content: "";
  position: absolute;
  right: 4px;
  bottom: 6px;
  width: 28px;
  height: 18px;
  background: currentColor;

  -webkit-mask: url("data:image/svg+xml;utf8,\
  <svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 40'>\
    <path fill='black' d='M20 30h24a10 10 0 0 0 0-20 14 14 0 0 0-27-3A8 8 0 0 0 20 30z'/>\
  </svg>")
    no-repeat center / contain;
  mask: url("data:image/svg+xml;utf8,\
  <svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 40'>\
    <path fill='black' d='M20 30h24a10 10 0 0 0 0-20 14 14 0 0 0-27-3A8 8 0 0 0 20 30z'/>\
  </svg>")
    no-repeat center / contain;

  opacity: 0.95;
  filter: drop-shadow(0 1px 1px rgba(0, 0, 0, 0.15));
}
