/* =========================================================
   New Safety — wspólny arkusz stylów dla wszystkich podstron
   Uzupełnia klasy narzędziowe Tailwind (CDN) o efekty specjalne.
   Kolor marki: zielony z logo (patrz tailwind.config w <head> każdej strony).
   ========================================================= */

/* --- Subtelny szum na całej stronie (efekt premium, matowa faktura) --- */
.noise-overlay {
    position: fixed;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.7' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
    opacity: 0.04;
    mix-blend-mode: overlay;
    pointer-events: none;
    z-index: 50;
}

.bg-grid-pattern {
    background-image: linear-gradient(to right, rgba(0,0,0,0.03) 1px, transparent 1px),
                      linear-gradient(to bottom, rgba(0,0,0,0.03) 1px, transparent 1px);
    background-size: 40px 40px;
}

/* --- Animacje wejścia --- */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(40px); }
    to { opacity: 1; transform: translateY(0); }
}
.animate-fade-in-up {
    animation: fadeInUp 1.2s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    opacity: 0;
}
.delay-100 { animation-delay: 0.15s; }
.delay-200 { animation-delay: 0.3s; }
.delay-300 { animation-delay: 0.45s; }
.delay-500 { animation-delay: 0.7s; }

.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: all 1s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

.glow-effect {
    box-shadow: 0 0 40px -10px rgba(76, 175, 46, 0.35);
}

/* --- Pseudo-3D okładka e-booka --- */
.book-cover {
    position: relative;
    transform: perspective(900px) rotateY(-18deg);
    transform-style: preserve-3d;
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}
.group:hover .book-cover {
    transform: perspective(900px) rotateY(-6deg);
}
.book-spine {
    position: absolute;
    left: -10px;
    top: 3%;
    width: 10px;
    height: 94%;
    background: linear-gradient(to right, rgba(0,0,0,0.5), rgba(0,0,0,0.1));
    transform: rotateY(90deg) translateZ(5px);
    transform-origin: right;
    border-radius: 2px 0 0 2px;
}

/* --- Nawigacja główna --- */
#site-nav {
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    transition: background-color 0.4s ease, border-color 0.4s ease, padding 0.4s ease;
}
#site-nav.nav-scrolled {
    background-color: rgba(10, 13, 10, 0.85);
    border-color: rgba(255,255,255,0.08);
}
#mobile-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}
#mobile-menu.open {
    max-height: 480px;
}

/* --- Ramka na zdjęcie w sekcji "O mnie" --- */
.photo-frame {
    position: relative;
}
.photo-frame::before {
    content: "";
    position: absolute;
    inset: -14px;
    border: 1px solid rgba(76, 175, 46, 0.35);
    border-radius: 1.25rem;
    pointer-events: none;
    z-index: 0;
}
.photo-frame img {
    position: relative;
    z-index: 1;
}

/* --- FAQ akordeon --- */
.faq-item .faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}
.faq-item.open .faq-answer {
    max-height: 320px;
}
.faq-item .faq-icon {
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.faq-item.open .faq-icon {
    transform: rotate(45deg);
}

/* --- Akordeon treści ogólnego przeznaczenia (np. lista szkoleń, dokumentów) — niezależny od FAQ/schema --- */
.info-item .info-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}
.info-item.open .info-answer {
    max-height: 420px;
}
.info-item .info-icon {
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.info-item.open .info-icon {
    transform: rotate(45deg);
}

/* --- Tabele referencyjne (np. częstotliwość szkoleń) --- */
.ref-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}
.ref-table th {
    text-align: left;
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-size: 0.7rem;
    color: #6B7280;
    padding: 0.9rem 1rem;
    border-bottom: 1px solid #E5E7EB;
    white-space: nowrap;
}
.ref-table td {
    padding: 1rem;
    border-bottom: 1px solid #F3F4F6;
    color: #374151;
    vertical-align: top;
}
.ref-table tr td:first-child {
    font-weight: 700;
    color: #111827;
}

/* --- Drobne detale --- */
::selection { background: rgba(76, 175, 46, 0.35); color: #fff; }
