/* ============================================================
   RESET / BAZA
   ------------------------------------------------------------
   Usuwa domyślne marginesy/paddingi przeglądarki i wyrównuje
   obliczenia rozmiarów dzięki box-sizing:border-box.
============================================================ */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* ============================================================
   GLOBALNE TŁO STRONY
   ------------------------------------------------------------
   Tło z rozmyciem + animacja przesuwania, ustawione na <html>.
============================================================ */
html {
    height: 100%;
    background:
        radial-gradient(circle at top, rgba(15,23,42,0.4), transparent 60%),
        #020617 url("images/brutus_tlo.png") center center / cover no-repeat !important;
}

/* Stała warstwa tła – animowane przesunięcie (paralaksa) */
#bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background:
        radial-gradient(circle at top, rgba(15,23,42,0.4), transparent 60%),
        #020617 url("images/brutus_tlo.png") center center / cover no-repeat;
    animation: bgDrift 40s ease-in-out infinite alternate;
}

/* ============================================================
   USTAWIENIA BODY
============================================================ */
body,
body.subpage,
body.home-page {
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: #e5e7eb;
    min-height: 100vh !important;
    display: flex !important;
    flex-direction: column !important;
    background: transparent;
    padding: 24px 16px;
    animation: bgDrift 40s ease-in-out infinite alternate;
}

/* Gdy header jest fixed – dodajemy padding */
body.with-fixed-header { padding-top: 70px; }

/* Podstrony nie mają flex layoutu */
body.subpage {
    display: block !important;
    padding-top: 120px !important;
}

/* Animacja tła */
@keyframes bgDrift {
    0% { background-position: center 0; }
    100% { background-position: center 60px; }
}

/* ============================================================
   STRUKTURA STRONY – .page
============================================================ */
.page {
    max-width: 1400px;
    width: 100%;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 32px;
}

/* ============================================================
   LOGO – KONTEJNER
============================================================ */
.branding {
    max-width: 480px;
    text-align: center;
}

/* Finalnie scalona wersja wrappera logo */
/* LOGO przypięte na stałe względem góry, poziom zostaje automatyczny */
.branding-logo {
    position: absolute;
    top: 220px; /* tutaj ustawiasz wysokość od góry */
    left: 0;
    right: 0;
    margin-left: auto;
    margin-right: auto;
    width: fit-content;
    z-index: 999;
}


/* Mobile – centrowanie i odsunięcie od góry */
@media (max-width: 900px) {
    .branding-logo {
        margin-left: auto;
        margin-right: auto;
        margin-top: -0px;
        text-align: center;
        width: fit-content;
    }
}

/* ============================================================
   LOGO – OBRAZEK
   Połączona pełna wersja (desktop + mobile)
============================================================ */
.branding-logo img {
    max-width: 480px;
    width: 100%;
    filter: drop-shadow(0 6px 10px rgba(0,0,0,0.8));
    animation: logoGlow 4s ease-in-out infinite;
    display: block;
    margin: 10px auto 10px auto;
    width: 250px; /* końcowy rozmiar logo */
}

/* Mobile – pomniejszone logo */
@media (max-width: 900px) {
    .branding-logo img {
        max-width: 350px;
        margin-left: auto;
        margin-right: auto;
    }
}

/* ============================================================
   ANIMACJE LOGO
============================================================ */
@keyframes logoGlow {
    0%, 100% { filter: drop-shadow(0 6px 10px rgba(0,0,0,0.8)); }
    50% { filter: drop-shadow(0 0 40px rgba(250,204,21,0.9)); }
}

body.home-page .branding-logo img {
    animation:
        logoGlow 4s ease-in-out infinite,
        logoBreath 10s ease-in-out infinite;
}

/* Animacja "oddychania" logo */
@keyframes logoBreath {
    0%, 100% { transform: scale(.6); }
    50% { transform: scale(1); }
}

/* Większy oddech na mobile */
@media (max-width: 900px) {
@keyframes logoBreath {
    0%, 100% { transform: scale(.6); }
    50% { transform: scale(1); }
}
}

/* Na podstronach logo nie jest wyświetlane */
body.subpage .branding,
body.subpage .branding-logo {
    display: none;
}

/* ============================================================
   HERO — NAGŁÓWEK I OPIS
============================================================ */
.hero {
    width: 100%;
    padding: 0px 20px 0px 20px;
    text-align: center;
    background: transparent;
}

.hero-content {
    max-width: 900px;
    margin: 50px auto 0 auto;
}

/* Połączona finalna wersja — H1 */
.hero-heading {
    font-family: "Dancing Script", cursive;
    font-size: 2.8rem;
    line-height: 1.3;
    color: #c0a570;
    margin-bottom: 5px;
    margin-top: 5px;
    text-align: center;
    text-shadow:
        0 0 6px rgba(0, 0, 0, 0.7),
        0 0 14px rgba(250, 204, 21, 0.5);
}

/* H2 */
.hero-subheading {
    font-size: 1.2rem;
    color: #c0a570;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-weight: 600;
    margin-bottom: 5px;
    margin-top: 5px;
    text-align: center;
}

/* Tekst pod hero */
.hero-description {
    font-size: 1.5rem;
    color: #c0a570;
    max-width: 750px;
    margin: 410px auto 30px auto;
    line-height: 1.6;
    text-align: center; /* <<< TO DODAJE PEŁNE WYŚRODKOWANIE */
}
@media (max-width: 600px) {
    .hero-description {
        margin: 370px auto 20px auto; /* mniejszy odstęp na mobile */
        font-size: 0.95rem; /* możesz zostawić lub zmienić */
    }
}

/* Mobile – mniejsze nagłówki */
@media (max-width: 600px) {
    .hero-heading { font-size: 2rem; }
    .hero-subheading { font-size: 1rem; }
    .hero-description { font-size: 0.95rem; }
}

/* ============================================================
   BUTTON HERO
============================================================ */
.hero-button {
    display: inline-block;
    padding: 12px 24px;
    background-color: #facc15;
    color: #000;
    font-weight: 700;
    border-radius: 6px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    transition: 0.3s;
}

.hero-button:hover {
    background-color: #d4b013;
}

/* ============================================================
   HEADER / MENU DESKTOP
============================================================ */
.site-header {
    width: 100%;
    z-index: 1000;
    background: rgba(2,6,23,0.9);
    backdrop-filter: blur(6px);
}

/* Desktop – sticky header */
@media (min-width: 901px) {
    .site-header {
        position: fixed;
        top: 0;
        left: 0;
    }
}

/* Wewnętrzny kontener nagłówka */
.site-header-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 10px 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Logo tekstowe w headerze */
.site-header-logo {
    color: #facc15;
    font-weight: 700;
    letter-spacing: 0.18em;
}

/* Menu główne */
.main-nav {
    display: flex;
    gap: 18px;
}

/* Linki menu */
.nav-link {
    font-size: 1.05rem;
    color: #facc15;
    text-transform: uppercase;
    letter-spacing: 0.20em;
    padding-bottom: 6px;
    position: relative;
}

/* Efekt podświetlenia */
.nav-link:hover,
.nav-link.active {
    text-shadow:
        0 0 6px rgba(250,204,21,.7),
        0 0 12px rgba(250,204,21,.9),
        0 0 22px rgba(250,204,21,1);
}

/* Kreska pod linkiem */
.nav-link::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 100%;
    height: 2px;
    background: #facc15;
    opacity: 0;
    transform: scaleX(0);
    transition: .35s;
}

.nav-link:hover::after {
    opacity: 1;
    transform: scaleX(1);
}

/* ============================================================
   IKONY KONTAKTU – HEADER
============================================================ */
.header-contact-icons {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Ikony — uniwersalny styl */
.header-contact-icons .contact-icon img {
    object-fit: contain;
    filter: drop-shadow(0 0 4px rgba(0,0,0,0.8));
    transition: transform 0.15s ease, filter 0.15s ease;
}

.icon-whatsapp img { width: 50px; height: 50px; }
.icon-messenger img { width: 40px; height: 40px; }
.icon-email img     { width: 40px; height: 40px; }
.icon-facebook img  { width: 32px; height: 32px; }

.header-contact-icons .contact-icon:hover img {
    transform: scale(1.08);
    filter: drop-shadow(0 0 8px rgba(250, 204, 21, 0.9));
}

/* ============================================================
   MENU MOBILNE
============================================================ */

.nav-toggle-checkbox { display: none; }
.nav-toggle { display: none; }

@media (max-width: 900px) {

    /* Mobile – header fixed */
    .site-header {
        position: fixed !important;
        top: 0; left: 0;
        width: 100%;
        z-index: 2000;
        background: rgba(2, 6, 23, 0.96) !important;
        height: 60px;
        padding: 0;
        box-shadow: 0 2px 8px rgba(0,0,0,0.6);
    }

    body.with-fixed-header { padding-top: 80px !important; }

    .site-header-inner {
        padding: 0 16px;
        height: 60px;
        display: flex;
        justify-content: space-between !important;
        align-items: center;
    }

    /* Logo + ikony obok siebie */
    .site-header-logo {
        display: flex !important;
        align-items: center;
        gap: 10px;
    }

    .header-contact-icons { order: 1; }

    /* Hamburger */
    .nav-toggle {
        display: flex;
        gap: 10px;
        align-items: center;
        position: absolute;
        top: 14px; right: 16px;
        z-index: 2500;
        cursor: pointer;
    }

    .nav-toggle-icon {
        display: flex;
        flex-direction: column;
        gap: 6px;
    }

    .nav-toggle-icon span {
        width: 26px;
        height: 3px;
        background: #fff;
        border-radius: 2px;
    }

    .nav-toggle-text {
        font-size: 0.8rem;
        color: #facc15;
        letter-spacing: 0.18em;
    }

    /* Animacja “pulse” gdy menu zamknięte */
    .nav-toggle-checkbox:not(:checked) + .nav-toggle {
        animation: menuPulse 2.2s ease-in-out infinite;
    }

    @keyframes menuPulse {
        0%,100% { transform: scale(1); opacity: 1; }
        50%     { transform: scale(1.12); opacity: .88; }
    }

    /* Mobile – rozwijane menu */
    .main-nav {
        display: none;
        position: absolute;
        top: 60px;
        right: 0;
        width: 200px;
        padding: 15px 20px;
        background: rgba(2, 6, 23, 0.95);
        border-radius: 0 0 0 12px;
        flex-direction: column;
        gap: 12px;
    }

    .nav-toggle-checkbox:checked + .nav-toggle + .main-nav {
        display: flex;
    }

    /* Mobile – layout strony */
    body {
        display: block;
        padding: 16px;
    }

    .page {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
    }

    .branding {
        text-align: left;
        width: 100%;
    }

    .card {
        width: 100%;
        max-width: 430px;
    }
}

/* ============================================================
   GLOBALNE LINKI
============================================================ */
a, a:link, a:visited {
    text-decoration: none !important;
}

/* ============================================================
   KONTAKT – TEKST I BLOKI
============================================================ */
.contact-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 20px;
    text-align: center;
}

.contact-title,
.contact-subtitle,
.contact-address {
    color: #facc15;
    text-transform: uppercase;
    letter-spacing: .12em;
    margin-bottom: 20px;
}

/* Email */
.email a {
    color: #3b82f6 !important;
    font-size: 22px;
}

.email a:hover {
    color: #60a5fa !important;
    text-shadow: 0 0 8px rgba(96,165,250,0.8);
}

/* Facebook link */
.facebook-link {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    font-size: 22px;
    color: #facc15 !important;
    font-weight: bold;
    margin-bottom: 30px;
}

.facebook-link img {
    width: 40px !important;
    height: 40px !important;
}

/* WhatsApp */
.whatsapp-box { margin-top: 20px; }

.whatsapp-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 22px;
    color: #25D366;
    font-weight: bold;
}

.whatsapp-link:hover {
    text-shadow: 0 0 8px rgba(37,211,102,.8);
}

.whatsapp-icon {
    width: 34px;
    height: 34px;
}

/* ============================================================
   KONTAKT – TELEFON Z ANIMACJĄ
============================================================ */
.phone-number {
    font-size: 46px;
    font-weight: 900;
    color: #ff0000;
    letter-spacing: 0.08em;
    text-shadow:
        0 0 8px rgba(0,0,0,0.8),
        0 0 14px rgba(250,204,21,0.9),
        0 0 28px rgba(250,204,21,1);
    animation: phoneGlow 1.2s ease-in-out infinite alternate;
}

@keyframes phoneGlow {
    0% {
        text-shadow:
            0 0 6px rgba(0,0,0,0.8),
            0 0 10px rgba(250,204,21,0.7),
            0 0 18px rgba(250,204,21,0.8);
    }
    50% {
        text-shadow:
            0 0 10px rgba(0,0,0,0.9),
            0 0 20px rgba(250,204,21,0.9),
            0 0 35px rgba(250,204,21,1),
            0 0 55px rgba(250,204,21,0.9);
    }
    100% {
        text-shadow:
            0 0 4px rgba(0,0,0,0.7),
            0 0 6px rgba(250,204,21,0.6),
            0 0 12px rgba(250,204,21,0.7);
    }
}

/* ============================================================
   IKONKI KONTAKTU — BLOKI NA STRONIE KONTAKT
============================================================ */
img.icon-whatsapp { width: 50px; height: 50px; }
img.icon-email    { width: 40px; height: 40px; }
img.icon-facebook { width: 32px; height: 32px; }
img.icon-messenger{ width: 40px; height: 40px; }

/* Lista ikonek */
.contact-links {
    display: flex;
    flex-direction: column;
    gap: 22px;
    width: fit-content;
    margin-left: auto;
    margin-right: auto;
}

/* Jeden wiersz ikony + tekstu */
.contact-row {
    display: flex;
    align-items: center;
    gap: 14px;
}

.contact-row img:not(.icon-messenger) {
    width: 48px;
    height: 48px;
}

.contact-row span {
    color: #fff;
    font-size: 22px;
    font-weight: 600;
}

/* Efekt hover */
.contact-row:hover span {
    text-shadow: 0 0 10px rgba(250,204,21,.8);
}

/* Mobile – mniejsze ikony */
@media (max-width: 600px) {
    .contact-row img { width: 42px; height: 42px; }
    .contact-row span { font-size: 18px; }
}

/* Adres kontaktowy */
.address-inline {
    display: flex;
    align-items: center;
    gap: 12px;
    width: fit-content;
    margin: 20px auto 0;
}

.address-inline span {
    font-size: 15px;
    color: #fff;
    font-weight: 600;
}

/* ============================================================
   MAPA
============================================================ */
.map-container {
    width: 100%;
    height: 400px;
    border: 3px solid #ccc;
    margin-top: 20px;
}

@media (min-width: 901px) {
    .contact-container {
        padding-left: 100px;
        padding-right: 100px;
    }

    .desktop-wide-map {
        width: 100%;
        height: 400px;
        border-left: 3px solid #ccc;
        border-right: 3px solid #ccc;
    }
}

/* ============================================================
   FORMULARZ KONTAKTOWY
============================================================ */
.contact-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
    max-width: 450px;
    margin: 0 auto 40px auto;
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 14px 16px;
    border-radius: 8px;
    border: 1px solid #4b5563;
    background: rgba(15,23,42,0.8);
    color: #facc15;
    font-size: 16px;
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
    color: #9ca3af;
}

.contact-form input:focus,
.contact-form textarea:focus {
    border-color: #facc15;
    box-shadow: 0 0 0 1px rgba(250,204,21,.5);
}

.contact-form textarea {
    min-height: 220px;
    resize: vertical;
    line-height: 1.5;
}

/* Przycisk wysyłania */
.send-button {
    background: #facc15;
    color: #111827;
    padding: 14px;
    font-size: 18px;
    font-weight: 700;
    border-radius: 999px;
    border: none;
    cursor: pointer;
}

.send-button:hover {
    background: #ffde45;
    box-shadow: 0 10px 25px rgba(250, 204, 21, 0.35);
    transform: translateY(-1px);
}

/* Wiadomości zwrotne */
.contact-success,
.contact-error {
    max-width: 700px;
    margin: 0 auto 20px auto;
    padding: 14px 16px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
}

.contact-success {
    background: rgba(22,163,74,.25);
    border: 1px solid rgba(22,163,74,.8);
    color: #bbf7d0;
}

.contact-error {
    background: rgba(220,38,38,.25);
    border: 1px solid rgba(220,38,38,.8);
    color: #fecaca;
}

/* Recaptcha – centrowanie */
.recaptcha-wrapper {
    display: flex;
    justify-content: center;
    margin: 10px 0 6px;
}

/* Rotujący tekst w hero – płynne pojawianie i znikanie */
#rotating-text {
    opacity: 0;
    animation: rotatingFade 5s ease-in-out infinite;
}

/* 0% – ciemny, 25–75% – jasny, 100% – znowu ciemny */
@keyframes rotatingFade {
    0%   { opacity: 0; }
    25%  { opacity: 1; }
    75%  { opacity: 1; }
    100% { opacity: 0; }
}

/* H1 i H2 – identyczny wygląd jak menu */
#rotating-h1,
#rotating-h2 {
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
    color: #c0a570 !important;
    text-transform: uppercase;
    letter-spacing: 0.20em;
    font-weight: 700;
    font-size: 1.1rem; /* identyczny rozmiar */
    margin: 5px 0;
    text-shadow:
        0 0 6px rgba(0,0,0,0.7),
        0 0 14px rgba(250,204,21,0.5);
}
/* Animacja słowo po słowie dla hero-description */
.hero-description span {
    opacity: 0;
    transition: opacity 0.2s ease-in-out;
}
