/*!
 * Lucmedia Nav Menu — Frontend Styles
 * Version: 1.1.7
 * Author:  Pawel Cieslak <contact@lucmedia.pl>
 * URL:     https://lucmedia.pl
 *
 * RULE: This file contains ONLY structural/layout/animation properties.
 * All colour and typography values that have a matching Elementor control
 * are set via that control's 'default' value only — never hardcoded here.
 * This prevents CSS specificity from silently overriding Elementor output.
 */

/* ── Reset ────────────────────────────────────────────────── */
.lnm-widget,
.lnm-widget *,
.lnm-widget *::before,
.lnm-widget *::after {
  box-sizing: border-box;
}

.lnm-widget {
  position: relative;
  display: inline-flex;
  align-items: center;
}

/* ── Default panel background (fallback only) ─────────────── */
/* Elementor's generated style overrides this cleanly          */
.lnm-overlay,
.lnm-drawer,
.lnm-split__nav {
  background-color: #111111;
}

/* ── Editor notice ────────────────────────────────────────── */
.lnm-editor-notice {
  padding: 12px 16px;
  background: #fff8e1;
  border-left: 4px solid #ffc107;
  font-size: 13px;
  color: #555;
  border-radius: 2px;
}

/* ════════════════════════════════════════════════════════════
   TRIGGER BUTTON — structural only
   ════════════════════════════════════════════════════════════ */
.lnm-trigger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-direction: row;
  gap: 8px;
  cursor: pointer;
  /* No background, color, border — all via Elementor */
  background: transparent;
  border: none;
  border-style: none;
  padding: 0;
  border-radius: 0;
  width: 44px;
  height: 44px;
  transition:
    background-color 0.22s ease,
    border-color     0.22s ease,
    box-shadow       0.22s ease,
    color            0.22s ease;
  position: relative;
  flex-shrink: 0;
}

.lnm-trigger--hamburger {
  flex-direction: column;
  gap: 5px;
}

/* Hamburger lines — structural only, color via Elementor */
.lnm-trigger--hamburger span {
  display: block;
  width: 20px;
  height: 2px;
  /* background-color intentionally omitted — set by Elementor trigger_color */
  border-radius: 2px;
  transform-origin: center;
  transition:
    transform        0.34s cubic-bezier(0.23, 1, 0.32, 1),
    opacity          0.2s  ease,
    width            0.28s ease,
    background-color 0.22s ease;
  pointer-events: none;
  /* Fallback so lines are visible before any Elementor style is saved */
  background-color: currentColor;
}

/* Hamburger → X on active */
.lnm-trigger--hamburger.is-active span:nth-child(1) { transform: translateY(7px)  rotate(45deg);  }
.lnm-trigger--hamburger.is-active span:nth-child(2) { opacity: 0; width: 0; }
.lnm-trigger--hamburger.is-active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* SVG icons */
.lnm-trigger--dots svg,
.lnm-trigger--plus svg {
  display: block;
  width: 20px;
  height: 20px;
  /* stroke/color via Elementor; fallback: inherit */
  stroke: currentColor;
  fill: currentColor;
  transition:
    transform 0.34s cubic-bezier(0.23, 1, 0.32, 1),
    stroke    0.22s ease,
    color     0.22s ease;
  pointer-events: none;
}
.lnm-trigger--dots.is-active svg,
.lnm-trigger--plus.is-active svg { transform: rotate(45deg); }

/* Trigger label — typography via Elementor, structural only here */
.lnm-trigger__label {
  white-space: nowrap;
  line-height: 1;
  /* color via Elementor trigger_label_color */
  color: currentColor;
  transition: color 0.22s ease;
}

.lnm-trigger:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 3px;
}

/* ════════════════════════════════════════════════════════════
   CLOSE BUTTON — structural only
   ════════════════════════════════════════════════════════════ */
.lnm-close {
  position: absolute;
  top: 20px;
  right: 24px;
  z-index: 2;
  /* background/color via Elementor close_color/close_bg */
  background: transparent;
  border: none;
  cursor: pointer;
  /* Fallback color so it's visible before saved Elementor style */
  color: #ffffff;
  padding: 8px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 0;
  transition:
    transform  0.3s cubic-bezier(0.23, 1, 0.32, 1),
    color      0.2s ease,
    background 0.2s ease;
}
.lnm-close:hover { transform: rotate(90deg); }
.lnm-close svg {
  display: block;
  /* width/height via Elementor close_size — fallback only */
  width: 24px;
  height: 24px;
  stroke: currentColor;
}
.lnm-close:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 3px;
  border-radius: 50%;
}

/* ════════════════════════════════════════════════════════════
   MENU LIST — structural only
   All color/typography properties via Elementor controls.
   ════════════════════════════════════════════════════════════ */
.lnm-menu-list,
.lnm-menu-list .sub-menu {
  list-style: none;
  margin: 0;
  padding: 0;
}

.lnm-menu-list > li { margin-bottom: 6px; }

.lnm-menu-list > li > a {
  display: inline-block;
  text-decoration: none;
  /* color via Elementor item_color — fallback only */
  color: #ffffff;
  /* font-size/weight via Elementor items_typography — fallback only */
  font-size: clamp(1.5rem, 3.5vw, 2.8rem);
  font-weight: 700;
  line-height: 1.1;
  position: relative;
  transition: color 0.22s ease, transform 0.22s ease;
}

/* Hover translate — visual micromovement only, no color here */
.lnm-menu-list > li > a:hover { transform: translateX(5px); }

/* Underline decoration */
.lnm-menu-list > li > a::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  /* background via Elementor item_underline_color — fallback only */
  background: #ffffff;
  transition: width 0.3s cubic-bezier(0.23, 1, 0.32, 1);
}
.lnm-menu-list > li > a:hover::after { width: 100%; }

/* Active / current page indicator — width only, color via Elementor */
.lnm-menu-list > li.current-menu-item > a::after,
.lnm-menu-list > li.current-menu-ancestor > a::after { width: 100%; }

/* Sub-menu */
.lnm-menu-list .sub-menu {
  padding: 8px 0 4px 18px;
  border-left: 1px solid rgba(255,255,255,0.18);
  margin-top: 6px;
  display: none;
}
.lnm-menu-list .sub-menu.is-open { display: block; }
.lnm-menu-list .sub-menu li { margin-bottom: 4px; }

.lnm-menu-list .sub-menu a {
  display: inline-block;
  text-decoration: none;
  /* color via Elementor sub_item_color — fallback only */
  color: rgba(255,255,255,0.55);
  /* font-size/weight via Elementor sub_items_typography — fallback only */
  font-size: clamp(0.85rem, 1.8vw, 1.1rem);
  font-weight: 400;
  transition: color 0.2s ease, transform 0.2s ease;
}
.lnm-menu-list .sub-menu a:hover {
  /* color via Elementor sub_item_color_hover — fallback only */
  color: #ffffff;
  transform: translateX(4px);
}

/* Sub-menu toggle indicator — structural symbol only */
.lnm-menu-list li.menu-item-has-children > a { padding-right: 28px; }
.lnm-menu-list li.menu-item-has-children > a::before {
  content: '+';
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  font-weight: 300;
  font-size: 1.2em;
  opacity: 0.55;
  transition: transform 0.22s ease, opacity 0.18s ease;
}
.lnm-menu-list li.menu-item-has-children.is-open > a::before { content: '−'; }

/* ════════════════════════════════════════════════════════════
   STAGGER ANIMATION BASE
   ════════════════════════════════════════════════════════════ */
.lnm-animate .lnm-menu-list > li {
  opacity: 0;
  transform: translateY(18px);
  transition:
    opacity   0.36s ease,
    transform 0.36s cubic-bezier(0.23, 1, 0.32, 1);
}
.lnm-animate.is-open .lnm-menu-list > li {
  opacity: 1;
  transform: translateY(0);
}

/* ════════════════════════════════════════════════════════════
   3-ZONE PANEL LAYOUT
   .lnm-panel-layout is a full-height flex column:
     ┌─────────────────┐
     │  .lnm-brand     │  ← pinned top
     ├─────────────────┤
     │  .lnm-panel-nav │  ← flex: 1, scrollable if needed
     ├─────────────────┤
     │ .lnm-panel-footer│  ← pinned bottom (only if present)
     └─────────────────┘
   ════════════════════════════════════════════════════════════ */
.lnm-panel-layout {
  display: flex;
  flex-direction: column;
  width: 100%;
  /* No height: 100% — let the layout grow to fit content.
     Each outer panel container (drawer, split nav, centered) is
     responsible for scrolling when the total content exceeds the viewport. */
  min-height: 100%;
}

/* Brand zone — always at top */
.lnm-brand {
  flex-shrink: 0;
  padding-bottom: 32px;
  /* align-self via Elementor logo_align control */
  align-self: flex-start;
}
.lnm-brand__logo {
  display: block;
  width: 120px;
  height: auto;
}

/* Nav zone — grows with content.
   Outer panel containers handle scrolling when total content
   exceeds the viewport. No internal scroll here — that was
   causing the footer to be unreachable when the full layout overflowed. */
.lnm-panel-nav {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding-top: 32px;
  padding-bottom: 16px;
}

/* Footer zone — always at bottom */
.lnm-panel-footer {
  flex-shrink: 0;
  padding-top: 32px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* Social links */
.lnm-social {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 18px;
}
.lnm-social a {
  text-decoration: none;
  color: rgba(255,255,255,0.55);
  transition: color 0.2s ease;
}
.lnm-social a:hover { color: #ffffff; }

/* Secondary info */
.lnm-secondary-info {
  margin: 0;
  line-height: 1.6;
  color: rgba(255,255,255,0.4);
}

/* ════════════════════════════════════════════════════════════
   STYLE 1 — CENTERED STACK
   ════════════════════════════════════════════════════════════ */
.lnm-overlay--centered {
  position: fixed;
  inset: 0;
  z-index: 99990;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  overflow-y: auto;
  /* background via Elementor panel_background */
  opacity: 0;
  visibility: hidden;
  transition:
    opacity    0.38s cubic-bezier(0.23, 1, 0.32, 1),
    visibility 0s   linear 0.38s;
  text-align: center;
}
.lnm-overlay--centered.is-open {
  opacity: 1;
  visibility: visible;
  transition:
    opacity    0.38s cubic-bezier(0.23, 1, 0.32, 1),
    visibility 0s   linear 0s;
}

.lnm-centered {
  width: 100%;
  max-width: 640px;
  min-height: 100%;
  padding: 32px 40px 40px;
  display: flex;
  flex-direction: column;
  /* Scrolls when logo + expanded menu + footer exceed viewport height */
  overflow-y: auto;
}
/* Centered layout: logo and footer align to center of their zones */
.lnm-overlay--centered .lnm-brand        { align-self: center; }
.lnm-overlay--centered .lnm-panel-nav    { align-items: center; text-align: center; }
.lnm-overlay--centered .lnm-panel-footer { align-items: center; text-align: center; }

/* Centered stagger: up from below */
.lnm-overlay--centered.lnm-animate .lnm-menu-list > li { transform: translateY(28px); }

/* ════════════════════════════════════════════════════════════
   STYLE 2 — SPLIT PANEL
   ════════════════════════════════════════════════════════════ */
.lnm-overlay--split {
  position: fixed;
  inset: 0;
  z-index: 99990;
  opacity: 0;
  visibility: hidden;
  transition:
    opacity    0.42s cubic-bezier(0.23, 1, 0.32, 1),
    visibility 0s   linear 0.42s;
}
.lnm-overlay--split.is-open {
  opacity: 1;
  visibility: visible;
  transition:
    opacity    0.42s cubic-bezier(0.23, 1, 0.32, 1),
    visibility 0s   linear 0s;
}

.lnm-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  height: 100%;
}

.lnm-split__nav {
  display: flex;
  flex-direction: column;
  padding: 32px 64px 48px;
  /* background via Elementor panel_background */
  overflow-y: auto;
}

.lnm-split__accent {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 56px;
  /* background via Elementor split_accent_bg */
  background: linear-gradient(145deg, #1a1a2e 0%, #16213e 55%, #0f3460 100%);
  overflow: hidden;
  transform: translateX(0);
  transition: transform 0.5s cubic-bezier(0.23, 1, 0.32, 1);
}
.lnm-overlay--split:not(.is-open) .lnm-split__accent { transform: translateX(32px); }

/* Tagline / sub — structural only, color/typography via Elementor */
.lnm-split__tagline {
  font-size: clamp(1.4rem, 2.8vw, 2.6rem);
  font-weight: 700;
  /* color via Elementor split_tagline_color — fallback only */
  color: #ffffff;
  line-height: 1.2;
  margin: 0 0 14px;
  position: relative;
  z-index: 1;
}
.lnm-split__sub {
  font-size: 1rem;
  /* color via Elementor split_sub_color — fallback only */
  color: rgba(255,255,255,0.58);
  line-height: 1.65;
  max-width: 360px;
  margin: 0;
  position: relative;
  z-index: 1;
}

/* Decorative orbs */
.lnm-split__deco { position: absolute; inset: 0; pointer-events: none; overflow: hidden; }
.lnm-split__deco span {
  position: absolute;
  border-radius: 50%;
  background: rgba(255,255,255,0.035);
  animation: lnm-float 10s ease-in-out infinite;
}
.lnm-split__deco span:nth-child(1) { width: 380px; height: 380px; top: -80px;   right: -60px; animation-duration: 9s;  }
.lnm-split__deco span:nth-child(2) { width: 220px; height: 220px; bottom: 50px; right: 60px;  animation-duration: 12s; animation-delay: -4s; }
.lnm-split__deco span:nth-child(3) { width: 140px; height: 140px; top: 42%;     right: 20px;  animation-duration: 7s;  animation-delay: -7s; }

@keyframes lnm-float {
  0%, 100% { transform: translateY(0)     scale(1);    }
  50%       { transform: translateY(-18px) scale(1.04); }
}

/* Split — accent panel hidden: nav goes full width */
.lnm-overlay--split-full .lnm-split {
  grid-template-columns: 1fr;
}
.lnm-overlay--split-full .lnm-split__nav {
  align-items: center;
  text-align: center;
}
.lnm-overlay--split-full .lnm-panel-nav    { align-items: center; }
.lnm-overlay--split-full .lnm-panel-footer { align-items: center; text-align: center; }
.lnm-overlay--split-full .lnm-brand        { align-self: center; }

/* Split stagger: in from left */
.lnm-overlay--split.lnm-animate .lnm-menu-list > li       { transform: translateX(-22px); }
.lnm-overlay--split.lnm-animate.is-open .lnm-menu-list > li { transform: translateX(0);    }

@media ( max-width: 768px ) {
  .lnm-split             { grid-template-columns: 1fr; grid-template-rows: 1fr auto; }
  .lnm-split__nav        { padding: 24px 32px 32px; }
  .lnm-split__accent     { padding: 32px; min-height: 140px; transform: none !important; }
  .lnm-split__deco       { display: none; }
  .lnm-split__tagline    { font-size: 1.2rem; }
}

/* ════════════════════════════════════════════════════════════
   STYLE 3 — SIDE DRAWER
   ════════════════════════════════════════════════════════════ */
.lnm-drawer-backdrop {
  position: fixed;
  inset: 0;
  z-index: 99989;
  background: rgba(0,0,0,0.52);
  -webkit-backdrop-filter: blur(3px);
  backdrop-filter: blur(3px);
  opacity: 0;
  visibility: hidden;
  transition:
    opacity    0.32s ease,
    visibility 0s   linear 0.32s;
}
.lnm-drawer-backdrop.is-open {
  opacity: 1;
  visibility: visible;
  transition:
    opacity    0.32s ease,
    visibility 0s   linear 0s;
}

.lnm-drawer {
  position: fixed;
  top: 0;
  bottom: 0;
  z-index: 99990;
  width: min(400px, 88vw);
  /* background via Elementor panel_background */
  overflow-y: auto;
  overscroll-behavior: contain;
  display: flex;
  flex-direction: column;
  visibility: hidden;
  transition:
    transform  0.38s cubic-bezier(0.23, 1, 0.32, 1),
    visibility 0s   linear 0.38s;
}
.lnm-drawer--left  { left: 0;  transform: translateX(-100%); }
.lnm-drawer--right { right: 0; transform: translateX(100%);  }
.lnm-drawer.is-open {
  visibility: visible;
  transform: translateX(0);
  transition:
    transform  0.38s cubic-bezier(0.23, 1, 0.32, 1),
    visibility 0s   linear 0s;
}

.lnm-drawer__inner {
  padding: 32px 36px 40px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

/* Drawer menu item sizing — slightly smaller than overlay styles.
   These are fallbacks only; Elementor items_typography overrides them. */
.lnm-drawer .lnm-menu-list > li > a {
  font-size: clamp(1.1rem, 2.4vw, 1.55rem);
  font-weight: 600;
}

/* Drawer stagger */
.lnm-drawer.lnm-animate             .lnm-menu-list > li { transform: translateX(-16px); }
.lnm-drawer--right.lnm-animate      .lnm-menu-list > li { transform: translateX(16px);  }
.lnm-drawer.lnm-animate.is-open     .lnm-menu-list > li { transform: translateX(0);     }

/* ════════════════════════════════════════════════════════════
   ACCESSIBILITY & REDUCED MOTION
   ════════════════════════════════════════════════════════════ */
.lnm-menu-list a:focus-visible,
.lnm-social a:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 3px;
  border-radius: 2px;
}

@media ( prefers-reduced-motion: reduce ) {
  .lnm-overlay,
  .lnm-drawer,
  .lnm-drawer-backdrop,
  .lnm-menu-list a,
  .lnm-menu-list a::after,
  .lnm-close,
  .lnm-trigger span,
  .lnm-trigger svg,
  .lnm-split__accent,
  .lnm-split__deco span,
  .lnm-animate .lnm-menu-list > li {
    transition: none !important;
    animation:  none !important;
  }
}
