.site-footer {
    position: relative;
    display: block;
    margin-top: 0;
    padding: 0;
    color: rgba(255, 255, 255, 0.7);
    background: linear-gradient(180deg, #0f223d 0%, #0a1a30 100%);
    overflow: hidden;
}

.site-footer::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, rgba(185, 138, 58, 0), rgba(185, 138, 58, 0.6) 50%, rgba(185, 138, 58, 0));
}

.site-footer::after {
    content: "";
    position: absolute;
    top: -180px;
    left: -120px;
    width: 420px;
    height: 420px;
    background: radial-gradient(circle, rgba(185, 138, 58, 0.14), transparent 70%);
    pointer-events: none;
}

.site-footer-inner,
.site-footer-bottom {
    position: relative;
    width: min(1180px, calc(100% - 48px));
    max-width: 1180px;
    margin-right: auto;
    margin-left: auto;
}

.site-footer-inner {
    padding: 56px 0 26px;
}

/* --- GÓRNA LINIA --- */
.footer-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 32px;
}

.footer-brand-group {
    display: flex;
    align-items: center;
    gap: 20px;
    min-width: 0;
}

.footer-brand {
    display: inline-flex;
    align-items: center;
    flex: 0 0 auto;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.footer-brand:hover {
    transform: translateY(-1px);
    opacity: 0.85;
}

.footer-logo {
    display: block;
    height: 28px;
    width: auto;
    max-width: 176px;
    object-fit: contain;
}

.footer-tagline {
    max-width: 300px;
    color: rgba(255, 255, 255, 0.45);
    font-size: 0.86rem;
    font-style: italic;
    line-height: 1.55;
}

.footer-top-right {
    display: flex;
    align-items: center;
    gap: clamp(20px, 3vw, 40px);
}

/* --- Nawigacja --- */
.footer-nav {
    display: flex;
    align-items: center;
    gap: 4px;
}

.footer-nav a {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 8px 14px;
    color: rgba(255, 255, 255, 0.72);
    font-size: 0.94rem;
    font-weight: 500;
    border-radius: 999px;
    text-decoration: none;
    transition: color 0.18s ease, background 0.18s ease;
}

.footer-nav a::before {
    content: "\2192";
    color: var(--gold);
    font-size: 0.85em;
    transition: transform 0.18s ease;
}

.footer-nav a:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.05);
}

.footer-nav a:hover::before {
    transform: translateX(3px);
}

/* --- Social media --- */
.footer-socials {
    display: flex;
    gap: 10px;
}

.footer-socials a {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    color: rgba(255, 255, 255, 0.78);
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 999px;
    text-decoration: none;
    transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.footer-socials a::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 2;
    pointer-events: none;
    background: linear-gradient(115deg, transparent 34%, rgba(255, 255, 255, 0.5) 50%, transparent 66%);
    transform: translateX(-140%);
    transition: transform 0.7s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.footer-socials a:hover::before,
.footer-socials a:focus-visible::before {
    transform: translateX(140%);
}

.footer-socials a:hover,
.footer-socials a:focus-visible {
    color: #ffffff;
    background: rgba(185, 138, 58, 0.22);
    border-color: rgba(185, 138, 58, 0.55);
    transform: translateY(-2px);
}

.footer-socials a span {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.footer-social-icon {
    width: 18px;
    height: 18px;
    flex: 0 0 auto;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* --- Divider --- */
.footer-divider {
    height: 1px;
    margin: 34px 0 26px;
    background: linear-gradient(90deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.03));
}

/* --- Listwa danych firmy: jedna linia, 4 kolumny --- */
.footer-data {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.02);
    list-style: none;
    margin: 0;
    padding: 0;
}

.footer-data li {
    display: block;
    min-width: 0;
}

.footer-data li + li {
    border-left: 1px solid rgba(255, 255, 255, 0.07);
}

.footer-data a,
.footer-data .footer-data-static {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    padding: 16px 22px;
    text-align: left;
    text-decoration: none;
    transition: background 0.18s ease;
}

.footer-data a:hover {
    background: rgba(185, 138, 58, 0.08);
}

/* defensywne wyrównanie — wygrywa nad ewentualnymi globalnymi regułami/cache */
.site-footer .footer-data > li {
    text-align: left !important;
}

.site-footer .footer-data > li > a,
.site-footer .footer-data > li > .footer-data-static {
    align-items: flex-start !important;
    text-align: left !important;
}

.footer-data span {
    font-family: "Cinzel", Georgia, serif;
    color: rgba(255, 255, 255, 0.42);
    font-size: 0.62rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.footer-data strong,
.footer-data em {
    max-width: 100%;
    color: rgba(255, 255, 255, 0.92);
    font-size: 0.92rem;
    font-weight: 500;
    font-style: normal;
    overflow-wrap: anywhere;
}

/* --- DOLNY PASEK --- */
.site-footer-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 22px 0 28px;
    margin-top: 36px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.site-footer-bottom p {
    margin: 0;
    color: rgba(255, 255, 255, 0.4);
    font-size: 0.85rem;
}

.site-footer-bottom nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 24px;
}

.site-footer-bottom a {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.85rem;
    text-decoration: none;
    transition: color 0.18s ease;
}

.site-footer-bottom a:hover {
    color: var(--gold);
}

/* --- Animacja wejścia (footer-fx.js dodaje .is-revealed) --- */
.site-footer [data-fin] {
    opacity: 0;
}

.site-footer.is-revealed [data-fin] {
    animation: footerIn 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.site-footer.is-revealed [data-fin]:nth-child(1) { animation-delay: 0ms; }
.site-footer.is-revealed .footer-top-right[data-fin] { animation-delay: 90ms; }
.site-footer.is-revealed .footer-divider[data-fin] { animation-delay: 150ms; }
.site-footer.is-revealed .footer-data[data-fin] { animation-delay: 220ms; }
.site-footer.is-revealed .site-footer-bottom[data-fin] { animation-delay: 320ms; }

@keyframes footerIn {
    from { opacity: 0; transform: translateY(26px); }
    to { opacity: 1; transform: none; }
}

@media (max-width: 860px) {
    /* Wszystko wyśrodkowane, równo pod sobą, oddzielone cienką linią:
       LOGO / NAWIGACJA / MEDIA */
    .footer-top {
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        text-align: center;
    }

    .footer-brand-group {
        flex-direction: column;
        align-items: center;
        gap: 12px;
        padding-bottom: 24px;
        border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    }

    .footer-tagline {
        max-width: 340px;
    }

    .footer-top-right {
        flex-direction: column;
        align-items: center;
        gap: 0;
        width: 100%;
    }

    .footer-nav {
        justify-content: center;
        flex-wrap: wrap;
        width: 100%;
        padding: 24px 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    }

    .footer-socials {
        justify-content: center;
        width: 100%;
        padding-top: 24px;
    }

    /* Dane firmy: jedna kolumna, równo pod sobą, oddzielone cienką linią */
    .footer-data {
        grid-template-columns: 1fr;
    }

    .footer-data li + li {
        border-left: 0;
        border-top: 1px solid rgba(255, 255, 255, 0.07);
    }

    .footer-data a,
    .footer-data .footer-data-static {
        padding: 15px 20px;
    }
}

@media (max-width: 680px) {
    .site-footer-inner,
    .site-footer-bottom {
        width: min(100% - 32px, 1180px);
    }

    .site-footer-inner {
        padding: 48px 0 24px;
    }

    .footer-logo {
        height: 24px;
    }

    .site-footer-bottom {
        align-items: center;
        flex-direction: column;
        gap: 12px;
        padding-bottom: 26px;
        text-align: center;
    }

    .site-footer-bottom nav {
        justify-content: center;
    }
}

@media (prefers-reduced-motion: reduce) {
    .footer-brand,
    .footer-nav a,
    .footer-data a,
    .site-footer-bottom a,
    .footer-socials a,
    .footer-socials a::before {
        transition: none;
    }

    .site-footer [data-fin],
    .site-footer.is-revealed [data-fin] {
        opacity: 1;
        animation: none;
    }

    .footer-socials a::before {
        display: none;
    }
}

.footer-data strong {
    overflow-wrap: normal;
    word-break: keep-all;
    white-space: nowrap;
}
