/*
Theme Name:   FAZA IDZIE Kadence Child
Theme URI:    https://fazaidzie.pl
Description:  Kadence Child Theme dla serwisu FAZA IDZIE z dedykowanym nagłówkiem i dynamicznym menu WP
Author:       RedProjekt / Antigravity
Template:     kadence
Version:      1.0.1
Text Domain:  fazaidzie-kadence-child
*/

/* ==========================================================================
   ZMIENNE SYSTEMOWE MARKI FAZA IDZIE
   ========================================================================== */
:root {
  --faza-primary: #00a2ff;
  --faza-primary-hover: #38bdf8;
  --faza-primary-glow: rgba(0, 162, 255, 0.45);
  --faza-bg-deep: #060a12;
  --faza-bg-header: rgba(6, 10, 18, 0.94);
  --faza-text-white: #ffffff;
  --faza-text-muted: #94a3b8;
  --faza-text-sub: #cbd5e1;
  --faza-border-subtle: rgba(0, 162, 255, 0.18);
  --faza-font-heading: 'Manrope', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --faza-font-body: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

/* Reset tła globalnego strony */
html, body {
  background-color: var(--faza-bg-deep) !important;
  color: var(--faza-text-white) !important;
}

#wrapper, .site, #inner-wrap, .content-container {
  background-color: transparent !important;
}

/* ==========================================================================
   NAGŁÓWEK GŁÓWNY (HEADER FAZA IDZIE)
   ========================================================================== */
.faza-header {
  position: sticky;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 9999;
  background-color: var(--faza-bg-header);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--faza-border-subtle);
  transition: background-color 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.faza-header--scrolled {
  background-color: rgba(5, 8, 15, 0.98);
  box-shadow: 0 4px 25px rgba(0, 0, 0, 0.65), 0 1px 0 rgba(0, 162, 255, 0.28);
  border-bottom-color: rgba(0, 162, 255, 0.3);
}

.faza-header__inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 32px;
  height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

/* ─── LEWA STRONA: LOGOTYP ─── */
.faza-header__logo-link {
  display: flex;
  align-items: center;
  text-decoration: none;
  flex-shrink: 0;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.faza-header__logo-link:hover {
  opacity: 0.92;
  transform: translateY(-1px);
}

.faza-header__logo-img {
  height: 48px;
  width: auto;
  max-width: 160px;
  object-fit: contain;
  display: block;
}

/* ─── ŚRODEK: NAWIGACJA WORDPRESS (DESKTOP) ─── */
.faza-header__nav {
  display: flex;
  align-items: center;
}

.faza-header__menu {
  display: flex;
  align-items: center;
  gap: 34px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.faza-header__menu > li {
  position: relative;
  list-style: none;
  margin: 0;
  padding: 0;
}

.faza-header__menu > li > a {
  display: inline-block;
  font-family: var(--faza-font-heading);
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--faza-text-sub);
  text-decoration: none;
  padding: 8px 0;
  position: relative;
  letter-spacing: 0.01em;
  transition: color 0.2s ease, text-shadow 0.2s ease;
}

.faza-header__menu > li > a:hover {
  color: #ffffff;
  text-shadow: 0 0 14px rgba(0, 162, 255, 0.7);
}

/* ─── WSKAŹNIK AKTYWNEJ POZYCJI (SINGLE ACTIVE UNDERLINE) ───
   Usunięto podkreślenia z domyślnych klas WordPressa (.current-menu-item),
   ponieważ WP oznacza wszystkie kotwice "/#..." jako aktywne.
   Podkreślenie ma WYŁĄCZNIE i DOKŁADNIE JEDEN element z klasą .faza-active! */

.faza-header__menu > li > a::after,
.faza-header__menu > li.current-menu-item > a::after,
.faza-header__menu > li.current_page_item > a::after,
.faza-header__menu > li.current-menu-ancestor > a::after {
  content: none !important;
  display: none !important;
}

.faza-header__menu > li.faza-active > a {
  color: #ffffff !important;
  font-weight: 700 !important;
  text-shadow: 0 0 14px rgba(0, 162, 255, 0.75);
}

.faza-header__menu > li.faza-active > a::after {
  content: '' !important;
  display: block !important;
  position: absolute;
  bottom: 0px;
  left: 0;
  width: 100%;
  height: 2.5px;
  background: var(--faza-primary);
  box-shadow: 0 0 12px var(--faza-primary);
  border-radius: 2px;
  animation: fazaUnderlineIn 0.25s ease forwards;
}

@keyframes fazaUnderlineIn {
  from {
    transform: scaleX(0.3);
    opacity: 0;
  }
  to {
    transform: scaleX(1);
    opacity: 1;
  }
}

/* Obsługa rozwijanego menu potomnego (Sub-menu) */
.faza-header__menu .sub-menu {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 220px;
  background: #0b111e;
  border: 1px solid var(--faza-border-subtle);
  border-radius: 10px;
  padding: 10px 0;
  margin-top: 12px;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.6);
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: all 0.25s ease;
  list-style: none;
  z-index: 1000;
}

.faza-header__menu li:hover > .sub-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.faza-header__menu .sub-menu li a {
  display: block;
  padding: 10px 20px;
  font-family: var(--faza-font-heading);
  font-size: 0.875rem;
  color: var(--faza-text-sub);
  text-decoration: none;
  transition: all 0.2s ease;
}

.faza-header__menu .sub-menu li a:hover {
  background: rgba(0, 162, 255, 0.12);
  color: var(--faza-primary);
  padding-left: 24px;
}

/* ─── PRAWA STRONA: PRZYCISK CTA (ZADZWOŃ TERAZ) ─── */
.faza-header__cta-wrap {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-shrink: 0;
}

.faza-header__cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 11px 24px;
  background: rgba(0, 162, 255, 0.08);
  border: 1.5px solid var(--faza-primary);
  border-radius: 9999px;
  color: #ffffff;
  font-family: var(--faza-font-heading);
  font-size: 0.9375rem;
  font-weight: 700;
  text-decoration: none;
  box-shadow: 0 0 16px rgba(0, 162, 255, 0.25);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: pointer;
  white-space: nowrap;
}

.faza-header__cta-btn:hover {
  background: var(--faza-primary);
  color: #060a12;
  box-shadow: 0 0 25px rgba(0, 162, 255, 0.65);
  transform: translateY(-2px);
}

.faza-header__cta-icon {
  width: 18px;
  height: 18px;
  color: var(--faza-primary);
  flex-shrink: 0;
  transition: color 0.2s ease;
}

.faza-header__cta-btn:hover .faza-header__cta-icon {
  color: #060a12;
}

.faza-header__cta-arrow {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  transition: transform 0.2s ease;
}

.faza-header__cta-btn:hover .faza-header__cta-arrow {
  transform: translateX(4px);
}

/* ─── PRZYCISK HAMBURGER (MOBILE) ─── */
.faza-header__hamburger {
  display: none;
  width: 44px;
  height: 44px;
  background: rgba(0, 162, 255, 0.06);
  border: 1px solid rgba(0, 162, 255, 0.35);
  border-radius: 10px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  cursor: pointer;
  padding: 0;
  transition: all 0.25s ease;
}

.faza-header__hamburger:hover {
  background: rgba(0, 162, 255, 0.15);
  border-color: var(--faza-primary);
  box-shadow: 0 0 15px rgba(0, 162, 255, 0.35);
}

.faza-header__hamburger-bar {
  width: 22px;
  height: 2px;
  background-color: #ffffff;
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.25s ease, background-color 0.25s ease;
}

/* Animacja ikony hamburgera na X */
.faza-header--menu-open .faza-header__hamburger-bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
  background-color: var(--faza-primary);
}

.faza-header--menu-open .faza-header__hamburger-bar:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

.faza-header--menu-open .faza-header__hamburger-bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
  background-color: var(--faza-primary);
}

/* ─── SZUFLADA MOBILNA (MOBILE DRAWER) ─── */
.faza-header__mobile-drawer {
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  background: #060a12;
  border-bottom: 2px solid var(--faza-primary);
  box-shadow: 0 25px 45px rgba(0, 0, 0, 0.85);
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.25s ease;
  opacity: 0;
  pointer-events: none;
}

.faza-header--menu-open .faza-header__mobile-drawer {
  max-height: 85vh;
  opacity: 1;
  pointer-events: auto;
  overflow-y: auto;
}

.faza-header__mobile-inner {
  padding: 24px 28px 32px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.faza-header__mobile-menu {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.faza-header__mobile-menu > li > a {
  font-family: var(--faza-font-heading);
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--faza-text-sub);
  text-decoration: none;
  padding: 12px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: color 0.2s ease, padding 0.2s ease;
}

.faza-header__mobile-menu > li > a:hover {
  color: var(--faza-primary);
  padding-left: 6px;
}

/* Pojedyncza aktywna pozycja w menu mobilnym */
.faza-header__mobile-menu > li.faza-active > a {
  color: var(--faza-primary) !important;
  font-weight: 700 !important;
  border-bottom-color: rgba(0, 162, 255, 0.4) !important;
  padding-left: 8px;
}

.faza-header__cta-btn--mobile {
  width: 100%;
  justify-content: center;
  padding: 14px;
  font-size: 1rem;
}

/* Blokada przewijania tła gdy menu otwarte */
body.faza-menu-locked {
  overflow: hidden;
}

/* ==========================================================================
   STOPKA DEDYKOWANA FAZA IDZIE (BEZ KADENCE)
   ========================================================================== */
.faza-footer {
  background-color: var(--faza-bg-deep) !important;
  border-top: 1px solid var(--faza-border-subtle);
  padding: 30px 24px;
  width: 100%;
  position: relative;
  z-index: 10;
}

.faza-footer__inner {
  max-width: 1400px;
  margin: 0 auto;
  text-align: center;
}

.faza-footer__content {
  display: flex;
  align-items: center;
  justify-content: center;
}

.faza-footer__text {
  font-family: var(--faza-font-body);
  font-size: 0.9rem;
  color: var(--faza-text-muted);
  margin: 0;
  line-height: 1.6;
}

.faza-footer__brand {
  color: var(--faza-primary);
  font-weight: 700;
  letter-spacing: 0.02em;
}

/* Ukrycie ewentualnych pozostałości oryginalnego footera Kadence */
.site-bottom-footer-wrap,
.footer-widget-area.site-info {
  background: transparent !important;
}

/* ==========================================================================
   RESPONSYWNOŚĆ NAGŁÓWKA (BREAKPOINTY)
   ========================================================================== */
@media (max-width: 1024px) {
  .faza-header__inner {
    padding: 0 24px;
    height: 70px;
  }

  .faza-header__menu {
    gap: 22px;
  }

  .faza-header__menu > li > a {
    font-size: 0.875rem;
  }
}

@media (max-width: 860px) {
  .faza-header__nav {
    display: none; /* Ukryj menu poziome na tabletach i mobile */
  }

  .faza-header__hamburger {
    display: flex; /* Pokaż hamburger */
  }
}

@media (max-width: 540px) {
  .faza-header__inner {
    padding: 0 18px;
    height: 66px;
  }

  .faza-header__logo-img {
    height: 40px;
  }

  .faza-header__cta-btn {
    padding: 9px 16px;
    font-size: 0.84rem;
    gap: 6px;
  }

  .faza-header__cta-text {
    font-size: 0.84rem;
  }
}
