/*
Theme Name: BlockchainSecurity Child
Template: astra
Description: Cyber dark theme for BlockchainSecurity.rs — Blockchain & Cybersecurity Intelligence Platform
Version: 1.0.0
Author: BlockchainSecurity.rs
*/

/* =============================================
   CSS CUSTOM PROPERTIES
   ============================================= */
:root {
  --bg:       #0A0F1E;
  --bg2:      #0E1629;
  --bg3:      #131D35;
  --surface:  #162040;
  --border:   rgba(0, 212, 255, 0.12);
  --accent:   #00D4FF;
  --accent2:  #7B4FE0;
  --accent3:  #00FF88;
  --text:     #E0EAF5;
  --muted:    #5A7A90;
  --white:    #FFFFFF;
  --danger:   #FF4444;
}

/* =============================================
   RESET & BASE
   ============================================= */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  background: var(--bg);
  font-family: 'Cabinet Grotesk', sans-serif;
  color: var(--text);
  /* CF hard rule: OS kursor ostaje vidljiv (mix-blend-mode:screen na .cursor) */
  overflow-x: hidden;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

body::after {
  content: '';
  position: fixed;
  inset: 0;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 2px,
    rgba(0, 212, 255, 0.012) 2px,
    rgba(0, 212, 255, 0.012) 4px
  );
  pointer-events: none;
  z-index: 9990;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  color: var(--white);
}

/* =============================================
   CUSTOM CURSOR
   ============================================= */
.cursor {
  width: 8px;
  height: 8px;
  background: var(--accent);
  border-radius: 50%;
  position: fixed;
  top: 0;
  left: 0;
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  mix-blend-mode: screen;
  transition: width 0.2s, height 0.2s, background 0.2s;
}

.cursor-ring {
  width: 32px;
  height: 32px;
  border: 1px solid rgba(0, 212, 255, 0.6);
  border-radius: 50%;
  position: fixed;
  top: 0;
  left: 0;
  pointer-events: none;
  z-index: 9998;
  transform: translate(-50%, -50%);
  transition: width 0.3s ease, height 0.3s ease, border-color 0.3s;
}

.cursor.grow {
  width: 16px;
  height: 16px;
  background: var(--accent2);
}

.cursor-ring.grow {
  width: 48px;
  height: 48px;
  border-color: var(--accent);
}

/* =============================================
   NAVIGATION
   ============================================= */
.site-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  background: rgba(10, 15, 30, 0.95);
  border-bottom: 1px solid var(--border);
  height: 64px;
  display: flex;
  align-items: center;
}

.nav-inner {
  width: 100%;
  max-width: 1440px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  align-items: center;
  gap: 2rem;
  justify-content: space-between;
}

.nav-logo {
  font-family: 'Cabinet Grotesk', sans-serif;
  font-weight: 900;
  font-size: 1.1rem;
  color: var(--white);
  text-decoration: none;
  white-space: nowrap;
  flex-shrink: 0;
}

.nav-logo span {
  color: var(--accent);
}

.nav-categories {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  overflow-x: auto;
  scrollbar-width: none;
  flex: 1;
  justify-content: flex-start;
  /* fade maske umesto tvrdog odsecanja na ivicama */
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 28px, #000 calc(100% - 28px), transparent 100%);
  mask-image: linear-gradient(90deg, transparent 0, #000 28px, #000 calc(100% - 28px), transparent 100%);
  padding: 0 28px;
}

/* Astra scroll-to-top dugme — ne uklapa se u dizajn */
#ast-scroll-top,
.ast-scroll-top-icon,
.ast-scroll-to-top-enable #ast-scroll-top {
  display: none !important;
}

.nav-categories::-webkit-scrollbar {
  display: none;
}

.nav-categories a {
  font-family: 'DM Mono', monospace;
  font-size: 0.7rem;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  text-decoration: none;
  padding: 0.35rem 0.6rem;
  border-radius: 4px;
  white-space: nowrap;
  transition: color 0.2s, background 0.2s;
  border: 1px solid transparent;
}

.nav-categories a:hover {
  color: var(--accent);
  background: rgba(0, 212, 255, 0.06);
  border-color: var(--border);
}

.nav-cta {
  font-family: 'DM Mono', monospace;
  font-size: 0.7rem;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--bg);
  background: var(--accent);
  padding: 0.5rem 1.25rem;
  border-radius: 4px;
  text-decoration: none;
  white-space: nowrap;
  flex-shrink: 0;
  transition: background 0.2s, transform 0.2s;
}

.nav-cta:hover {
  background: var(--white);
  color: var(--bg);
  transform: translateY(-1px);
}

/* Hamburger toggle — hidden on desktop */
.nav-hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 4px;
}

.nav-hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--accent);
  transition: transform 0.3s, opacity 0.3s;
}

.mobile-menu {
  display: none;
  position: fixed;
  top: 64px;
  left: 0;
  right: 0;
  background: rgba(10, 15, 30, 0.98);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  padding: 1.5rem 2rem;
  z-index: 99;
  flex-direction: column;
  gap: 0.5rem;
}

.mobile-menu.open {
  display: flex;
}

.mobile-menu a {
  font-family: 'DM Mono', monospace;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
  padding: 0.6rem 0;
  border-bottom: 1px solid var(--border);
  text-decoration: none;
  transition: color 0.2s;
}

.mobile-menu a:hover {
  color: var(--accent);
}

/* =============================================
   SCROLL REVEAL
   ============================================= */
.reveal {
  opacity: 0.85;
  transform: translateY(20px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* =============================================
   SCROLLBAR
   ============================================= */
::-webkit-scrollbar {
  width: 6px;
}

::-webkit-scrollbar-track {
  background: var(--bg);
}

::-webkit-scrollbar-thumb {
  background: rgba(0, 212, 255, 0.3);
  border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--accent);
}

/* =============================================
   KEYFRAMES
   ============================================= */
@keyframes gridFloat {
  0%, 100% { transform: translate(0, 0); }
  25%       { transform: translate(-5px, -5px); }
  50%       { transform: translate(5px, 5px); }
  75%       { transform: translate(-3px, 3px); }
}

@keyframes orbFloat {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33%       { transform: translate(30px, -20px) scale(1.05); }
  66%       { transform: translate(-20px, 30px) scale(0.95); }
}

@keyframes ringPulse {
  0%   { transform: translate(-50%, -50%) scale(0.8); opacity: 0.6; }
  100% { transform: translate(-50%, -50%) scale(2.2); opacity: 0; }
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(30px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes fadeChar {
  from { opacity: 0; transform: translateY(12px) rotate(3deg); }
  to   { opacity: 1; transform: translateY(0) rotate(0deg); }
}

@keyframes tickerScroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

@keyframes barGrow {
  from { transform: scaleY(0); }
  to   { transform: scaleY(1); }
}

@keyframes floatCard {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(-8px); }
}

@keyframes ecgScroll {
  from { stroke-dashoffset: 1000; }
  to   { stroke-dashoffset: 0; }
}

@keyframes glitch {
  0%, 100% {
    clip-path: polygon(0 0, 100% 0, 100% 45%, 0 45%);
    transform: translateX(-3px);
    color: var(--accent);
  }
  25% {
    clip-path: polygon(0 55%, 100% 55%, 100% 100%, 0 100%);
    transform: translateX(3px);
    color: var(--accent2);
  }
  50% {
    clip-path: polygon(0 20%, 100% 20%, 100% 60%, 0 60%);
    transform: translateX(-2px);
    color: var(--danger);
  }
  75% {
    clip-path: polygon(0 40%, 100% 40%, 100% 80%, 0 80%);
    transform: translateX(2px);
    color: var(--accent3);
  }
}

/* =============================================
   UTILITY CLASSES
   ============================================= */
.container {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 2rem;
}

.section-label {
  font-family: 'DM Mono', monospace;
  font-size: 0.75rem;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--accent);
  display: block;
  margin-bottom: 1rem;
}

/* =============================================
   RESPONSIVE
   ============================================= */
@media (max-width: 768px) {
  .nav-categories {
    display: none;
  }

  .nav-hamburger {
    display: flex;
  }

  body {
    cursor: auto;
  }

  .cursor,
  .cursor-ring {
    display: none;
  }
}

/* =============================================
   SCROLL-SCRUB SHARED (bcs-scrub.js)
   koristi se na front-page + category arhivama
   ============================================= */
@keyframes bcsDrip {
  60% { transform: translateY(100%); }
  100% { transform: translateY(100%); }
}
.bcs-block {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity .55s cubic-bezier(.22,.8,.26,1), transform .55s cubic-bezier(.22,.8,.26,1);
}
.bcs-block.on {
  opacity: 1;
  transform: none;
}
@media (prefers-reduced-motion: reduce) {
  .bcs-block { transition: none; }
}

/* =============================================
   CF Consent fields + form notice — Dark Mode (blockchainsecurity-child)
   Lane L2-BLOCKCHAIN 2026-07-02
   ============================================= */
.cf-consent-block {
  margin: 1rem 0 1.25rem;
  flex-basis: 100%;
  width: 100%;
  text-align: left;
}
.cf-consent-row {
  display: flex;
  gap: 8px;
  align-items: flex-start;
  margin: 0.5rem 0;
  cursor: pointer;
}
.cf-consent-row input[type="checkbox"] {
  flex-shrink: 0;
  width: 16px;
  height: 16px;
  margin-top: 2px;
  accent-color: var(--accent, #00D4FF);
  background: var(--bg2, #141e35);
  border: 1px solid var(--border, #1e2d4a);
  cursor: pointer;
}
.cf-consent-row span {
  font-family: 'Cabinet Grotesk', sans-serif;
  font-size: 0.85rem;
  color: var(--muted, #6b7fa3);
  line-height: 1.5;
}
.cf-consent-row:hover span {
  color: var(--text, #c8d4e8);
}
.cf-form-notice {
  max-width: 520px;
  margin: 0 auto 1.25rem;
  padding: 0.85rem 1.25rem;
  border-radius: 4px;
  font-family: 'Cabinet Grotesk', sans-serif;
  font-size: 0.9rem;
  line-height: 1.5;
  text-align: left;
}
.cf-form-ok {
  background: rgba(0, 255, 136, 0.08);
  border: 1px solid rgba(0, 255, 136, 0.35);
  color: #7ef2b0;
}
.cf-form-err {
  background: rgba(255, 59, 48, 0.08);
  border: 1px solid rgba(255, 59, 48, 0.35);
  color: #ff8a80;
}

/* =============================================
   MOBILE FIX — collapse fixed inline grids (contact + newsletter)
   Lane L2-BLOCKCHAIN 2026-07-02 (0 horizontal scroll @ 375px)
   ============================================= */
@media (max-width: 782px) {
  [style*="grid-template-columns:repeat(4,1fr)"],
  [style*="grid-template-columns:repeat(3,1fr)"],
  [style*="grid-template-columns:1.2fr 1fr"],
  [style*="grid-template-columns:2fr 1fr 1fr 1fr"] {
    grid-template-columns: 1fr !important;
    gap: 1.5rem !important;
  }
}
@media (max-width: 600px) {
  [style*="grid-template-columns:repeat(2,1fr)"] {
    grid-template-columns: 1fr !important;
  }
}
