/* =====================================================================
   Vision Shop Design Layer — diviskit-com (portiert von divi-ops-ext)
   Alpine-Agentur-Look: Charcoal + Signalgelb, kantige Diagonalen.
   Portiert aus vision-divi-child (vision-remake-wordpress) — identische
   Token- und Klassennamen, damit Seiten 1:1 uebertragbar bleiben.

   Scope: body.vsn-dark (via body_class-Filter in functions.php) fuer
   Shop-Seiten, Produkte, Kategorien, Rechtsseiten, Landing.
   g-*-Utilities sind global (opt-in Klassen, wirken nur wo gesetzt).
   ===================================================================== */

:root {
  /* Alpine-Agentur-Design (Charcoal + Signalgelb) */
  --g-dark: #202325;
  --g-darker: #17191a;
  --g-surface: #2b2f31;
  --g-line: rgba(255, 255, 255, 0.12);
  --g-accent: #ffd400;
  --g-accent-deep: #e6be00;
  --g-muted: rgba(255, 255, 255, 0.62);

  /* Fonts */
  --font-anton: "Anton", Impact, sans-serif;
  --font-fraunces: "Fraunces", Georgia, serif;
  --font-geist-sans: "Geist", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-geist-mono: "Geist Mono", ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
}

/* ---------------------------------------------------------------------
   g-* Utilities (identisch zu vision-divi-child)
   --------------------------------------------------------------------- */

.font-anton {
  font-family: var(--font-anton);
  font-weight: 400;
  letter-spacing: -0.01em;
  text-transform: uppercase;
  line-height: 0.92;
}

.font-fraunces {
  font-family: var(--font-fraunces);
}

.font-geist-mono {
  font-family: var(--font-geist-mono);
}

/* Signalgelber Bracket-Kicker "[ ... ]" */
.g-kicker {
  color: var(--g-accent);
  font-family: var(--font-geist-mono);
  text-transform: uppercase;
  letter-spacing: 0.28em;
  font-size: 0.72rem;
}

.g-kicker::before {
  content: "[ ";
}

.g-kicker::after {
  content: " ]";
}

/* Endlos laufender Ticker */
@keyframes g-marquee {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-50%);
  }
}

.g-marquee-track {
  display: inline-flex;
  white-space: nowrap;
  animation: g-marquee 30s linear infinite;
  will-change: transform;
}

/* Hover pausiert den Ticker — auf die Section gelegt, damit die Pause
   band-weit gilt und nicht nur direkt ueber dem Text. */
.vsn-marquee:hover .g-marquee-track {
  animation-play-state: paused;
}

@media (prefers-reduced-motion: reduce) {
  .g-marquee-track {
    animation: none;
  }
}

/* Diagonale Sektionskante */
.g-slant-top {
  clip-path: polygon(0 3.5vw, 100% 0, 100% 100%, 0 100%);
}

.g-slant-bottom {
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 3.5vw), 0 100%);
}

/* Karten-Hover mit hartem Gelb-Schatten */
.g-card {
  transition:
    transform 0.25s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.25s ease,
    border-color 0.2s ease;
}

.g-card:hover {
  transform: translateY(-6px);
  box-shadow: 10px 10px 0 0 var(--g-accent);
  border-color: var(--g-accent) !important;
}

@media (prefers-reduced-motion: reduce) {
  .g-card,
  .g-card:hover {
    transform: none;
    transition: none;
  }
}

/* Druckbarer CTA im Gelb-Stil */
.g-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  transition:
    transform 0.15s ease,
    box-shadow 0.15s ease,
    background-color 0.2s ease,
    color 0.2s ease,
    border-color 0.2s ease;
  box-shadow: 5px 5px 0 0 rgba(0, 0, 0, 0.35);
  text-decoration: none;
}

.g-btn:hover {
  transform: translate(-2px, -2px);
  box-shadow: 7px 7px 0 0 rgba(0, 0, 0, 0.35);
}

.g-btn:active {
  transform: translate(3px, 3px);
  box-shadow: 0 0 0 0 rgba(0, 0, 0, 0.35);
}

@media (prefers-reduced-motion: reduce) {
  .g-btn,
  .g-btn:hover,
  .g-btn:active {
    transform: none;
    transition: none;
  }
}

/* Diagonaler Karo-Placeholder fuer fehlende Bilder */
.g-placeholder {
  background-color: var(--g-surface);
  background-image: repeating-linear-gradient(
    -45deg,
    rgba(255, 255, 255, 0.05) 0,
    rgba(255, 255, 255, 0.05) 1px,
    transparent 1px,
    transparent 12px
  );
}

/* Marquee-Section: Overflow verstecken, damit der Track nicht scrollt */
.vsn-marquee,
.vsn-marquee .et_pb_module_inner {
  overflow: hidden;
}

/* Pulsierender Live-Indikator */
@keyframes pulse-dot {
  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(255, 212, 0, 0.6);
  }
  60% {
    box-shadow: 0 0 0 5px rgba(255, 212, 0, 0);
  }
}

.live-dot {
  display: inline-block;
  border-radius: 9999px;
  animation: pulse-dot 1.8s ease-out infinite;
}

/* Scroll-Reveal */
.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition:
    opacity 0.7s ease,
    transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
  transition-delay: var(--reveal-delay, 0ms);
}

.reveal.is-visible {
  opacity: 1;
  transform: none;
}

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

::selection {
  background: var(--g-accent);
  color: var(--g-darker);
}

/* ---------------------------------------------------------------------
   Dark scope: gilt fuer Shop-Seiten, Produkte, Kategorien, Landing,
   Rechtsseiten — via body_class 'vsn-dark' (functions.php).
   --------------------------------------------------------------------- */

body.vsn-dark {
  background: var(--g-dark);
  color: #fff;
  font-family: var(--font-geist-sans);
}

/* Feines Papierkorn ueber der ganzen Seite */
body.vsn-dark::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 40;
  opacity: 0.35;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.04 0'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)'/%3E%3C/svg%3E");
}

body.vsn-dark #main-content,
body.vsn-dark .et_pb_section,
body.vsn-dark .et_builder_inner_content {
  background-color: transparent;
}

/* Sections tragen ihre eigene dunkle Flaeche — Default-Section-BG nur
   als Fallback, falls ein Block ohne expliziten Hintergrund rendert. */
body.vsn-dark #page-container,
body.vsn-dark #et-main-area {
  background-color: var(--g-dark);
}

body.vsn-dark a {
  color: var(--g-accent);
}

body.vsn-dark a:hover {
  color: var(--g-accent-deep);
}

body.vsn-dark .et_pb_button {
  font-family: var(--font-geist-mono);
  text-transform: uppercase;
  letter-spacing: 0.15em;
}

/* =====================================================================
   Blog / Einzelbeitrag — Standard-Post-Template ins Vision-System
   =================================================================== */

body.vsn-dark.single-post .entry-title {
  font-family: var(--font-anton, 'Anton', Impact, sans-serif);
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: -0.01em;
  font-size: clamp(30px, 4vw, 48px);
  line-height: 0.95;
  color: var(--g-white, #fff);
}

body.vsn-dark.single-post .et_pb_post,
body.vsn-dark.single-post .et_post_meta_wrapper,
body.vsn-dark.single-post .entry-content {
  max-width: 820px;
}

body.vsn-dark .et_pb_post .entry-content,
body.vsn-dark .et_pb_post_content {
  font-family: var(--font-geist-sans, 'Geist', 'Helvetica Neue', Arial, sans-serif);
  font-size: 16px;
  line-height: 1.75;
  color: rgba(255, 255, 255, 0.85);
}

body.vsn-dark .et_pb_post .entry-content h2,
body.vsn-dark .et_pb_post .entry-content h3,
body.vsn-dark .et_pb_post_content h2,
body.vsn-dark .et_pb_post_content h3 {
  font-family: var(--font-anton, 'Anton', Impact, sans-serif);
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: -0.01em;
  color: var(--g-accent, #ffd400);
  line-height: 1.1;
  margin: 1.8em 0 0.6em;
  padding-bottom: 0;
}
body.vsn-dark .et_pb_post .entry-content h2,
body.vsn-dark .et_pb_post_content h2 { font-size: clamp(22px, 2.4vw, 30px); }
body.vsn-dark .et_pb_post .entry-content h3,
body.vsn-dark .et_pb_post_content h3 { font-size: clamp(19px, 2vw, 24px); color: var(--g-white, #fff); }

body.vsn-dark .et_pb_post .entry-content ul,
body.vsn-dark .et_pb_post_content ul {
  list-style: square;
  padding-left: 1.4em;
}
body.vsn-dark .et_pb_post .entry-content ul li,
body.vsn-dark .et_pb_post_content ul li { padding-bottom: 0.4em; }

body.vsn-dark .et_pb_post .entry-content code,
body.vsn-dark .et_pb_post .entry-content pre,
body.vsn-dark .et_pb_post_content code,
body.vsn-dark .et_pb_post_content pre,
body.vsn-dark .et_pb_text_inner code,
body.vsn-dark .et_pb_text_inner pre {
  font-family: var(--font-geist-mono, 'Geist Mono', monospace);
  font-size: 0.88em;
}
body.vsn-dark .et_pb_post .entry-content code,
body.vsn-dark .et_pb_post_content code,
body.vsn-dark .et_pb_text_inner code {
  background: var(--g-darker, #17191a);
  border: 1px solid var(--g-line, rgba(255,255,255,0.12));
  padding: 0.15em 0.4em;
}
body.vsn-dark .et_pb_post .entry-content pre,
body.vsn-dark .et_pb_post_content pre,
body.vsn-dark .et_pb_text_inner pre {
  background: var(--g-darker, #17191a);
  border: 1px solid var(--g-line, rgba(255,255,255,0.12));
  padding: 18px 20px;
  overflow-x: auto;
}
body.vsn-dark .et_pb_post .entry-content pre code,
body.vsn-dark .et_pb_post_content pre code,
body.vsn-dark .et_pb_text_inner pre code {
  background: transparent;
  border: none;
  padding: 0;
}
