/* ==============================================================================
   OgSiec.eu (strona v3) - Pływająca Nawigacja Pill-Dock, Mobile Drawer i Stopka
   ============================================================================== */

/* ============================================
   PŁYWAJĄCY HEADER (Floating Pill Header v3)
   ============================================ */
header {
    position: fixed;
    top: 16px;
    left: 50%;
    transform: translateX(-50%);
    width: min(1220px, calc(100% - 32px));
    background: rgba(12, 12, 18, 0.82);
    padding: 0.75rem 1.4rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 1000;
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.05);
    animation: fadeIn 0.6s ease-out;
    transition: var(--transition-fast);
}

header.scrolled {
    background: rgba(10, 10, 15, 0.94);
    border-color: var(--border-hover);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.65), 0 0 25px rgba(123, 63, 228, 0.15);
}

.logo-group {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo {
    font-family: var(--font-heading);
    font-size: 1.55rem;
    font-weight: 800;
    color: var(--text-white);
    text-decoration: none;
    letter-spacing: -0.5px;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    transition: var(--transition);
}

.logo-img {
    width: 34px;
    height: 34px;
    border-radius: 9px;
    object-fit: cover;
    border: 1px solid var(--border);
    box-shadow: 0 0 12px rgba(123, 63, 228, 0.35);
}

.logo-text {
    display: inline-flex;
    align-items: center;
    gap: 0;
}

.logo-text span {
    color: var(--accent-lavender);
    transition: var(--transition);
}

.logo:hover {
    transform: scale(1.03);
    text-shadow: 0 0 18px var(--glow-lavender);
}

nav {
    display: flex;
    align-items: center;
    gap: 1rem;
}

nav ul {
    display: flex;
    list-style: none;
    gap: 0.4rem;
    align-items: center;
    background: rgba(255, 255, 255, 0.03);
    padding: 4px;
    border-radius: var(--radius-full);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

nav a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition-fast);
    font-size: 0.9rem;
    position: relative;
    padding: 0.5rem 1.05rem;
    border-radius: var(--radius-full);
    display: inline-flex;
    align-items: center;
    gap: 7px;
}

nav a:hover {
    color: var(--text-white);
    background: rgba(123, 63, 228, 0.14);
}

nav a.active {
    color: #ffffff;
    background: linear-gradient(135deg, var(--accent-purple) 0%, var(--accent-lavender) 100%);
    box-shadow: 0 4px 14px rgba(123, 63, 228, 0.45);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.status-pill {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 0.4rem 0.85rem;
    border-radius: var(--radius-full);
    background: var(--success-bg);
    border: 1px solid rgba(46, 204, 113, 0.3);
    color: #6ee7b7;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.3px;
}

.status-pill .dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--success);
    animation: pulse-green 2s infinite;
}

.mobile-menu-btn {
    display: none;
    background: rgba(123, 63, 228, 0.15);
    border: 1px solid var(--border);
    color: var(--text-white);
    width: 40px;
    height: 40px;
    border-radius: var(--radius-md);
    font-size: 1.15rem;
    cursor: pointer;
    align-items: center;
    justify-content: center;
    transition: var(--transition-fast);
}

.mobile-menu-btn:hover {
    background: var(--accent-purple);
    border-color: var(--accent-lavender);
}

/* Mobilny drawer */
.mobile-drawer {
    position: fixed;
    top: 84px;
    left: 16px;
    right: 16px;
    background: rgba(14, 14, 22, 0.96);
    border: 1px solid var(--border-hover);
    border-radius: var(--radius-lg);
    padding: 1rem;
    z-index: 999;
    display: none;
    flex-direction: column;
    gap: 0.4rem;
    backdrop-filter: blur(20px);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.75);
    animation: fadeInUp 0.25s ease-out;
}

.mobile-drawer.open {
    display: flex;
}

.mobile-drawer a {
    color: var(--text-gray);
    text-decoration: none;
    padding: 0.85rem 1rem;
    border-radius: var(--radius-md);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: var(--transition-fast);
}

.mobile-drawer a:hover,
.mobile-drawer a.active {
    background: rgba(123, 63, 228, 0.2);
    color: #fff;
}

@media (max-width: 1024px) {
    .status-pill {
        display: none;
    }
    nav a {
        padding: 0.45rem 0.8rem;
        font-size: 0.86rem;
    }
}

@media (max-width: 860px) {
    header {
        top: 10px;
        width: calc(100% - 20px);
        padding: 0.65rem 1rem;
    }

    nav ul,
    .header-actions .nav-btn {
        display: none;
    }

    .mobile-menu-btn {
        display: inline-flex;
    }
}

/* ============================================
   STOPKA (FOOTER) - Bento Footer w stylu Panelu
   ============================================ */
footer {
    background: #06070a;
    border-top: 1px solid var(--border);
    padding: 4.5rem 5% 2rem;
    margin-top: auto;
    position: relative;
    z-index: 10;
}

.footer-content {
    max-width: 1260px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 0.85fr auto 1.15fr;
    align-items: start;
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-content > .footer-brand {
    order: 3;
    justify-self: end;
}

.footer-content > .footer-section:nth-child(2) {
    order: 1;
    justify-self: start;
}

.footer-content > .footer-section:nth-child(3) {
    order: 2;
    justify-self: center;
}

.footer-brand p {
    color: var(--text-muted);
    font-size: 1.05rem;
    line-height: 1.75;
    margin-top: 1rem;
    max-width: 360px;
}

.footer-section h3 {
    font-family: var(--font-heading);
    font-size: 1.22rem;
    font-weight: 800;
    color: var(--accent-lavender);
    letter-spacing: 1px;
    text-transform: uppercase;
    margin: 0 0 1.6rem 0;
}

.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 1.15rem;
}

.footer-links li a {
    color: #cbd5e1;
    text-decoration: none;
    font-size: 1.16rem;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 12px;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.footer-links li a i {
    color: var(--accent-lavender);
    font-size: 1.05rem;
    transition: transform 0.25s ease, color 0.25s ease;
}

.footer-links li a:hover {
    color: #ffffff;
    transform: translateX(5px);
}

.footer-links li a:hover i {
    transform: translateX(3px);
    color: var(--light-purple);
}

.footer-bottom {
    max-width: 1260px;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    flex-wrap: wrap;
    gap: 1rem;
    padding-top: 1.8rem;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    color: #64748b;
    font-size: 0.86rem;
    font-weight: 500;
    text-align: center;
}

.back-to-top {
    position: absolute;
    right: 0;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--accent-lavender);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.85rem;
    padding: 0.45rem 0.9rem;
    border-radius: var(--radius-full);
    background: rgba(123, 63, 228, 0.12);
    border: 1px solid var(--border);
    transition: var(--transition-fast);
}

.back-to-top:hover {
    background: var(--accent-purple);
    color: #fff;
    transform: translateY(-2px);
}

@media (max-width: 992px) {
    .footer-content {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 2.2rem;
    }
    .footer-content > * {
        order: initial !important;
    }
    .footer-content > .footer-brand,
    .footer-content > .footer-section:nth-child(2),
    .footer-content > .footer-section:nth-child(3) {
        justify-self: start;
        margin-left: 0;
    }
}

@media (max-width: 768px) {
    .back-to-top {
        position: static;
    }
    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }
}

@media (max-width: 600px) {
    .footer-content {
        grid-template-columns: 1fr;
    }
}

/* ============================================
   PRZYCISK ZMIANY MOTYWU (DARK / LIGHT)
   ============================================ */
.theme-toggle-btn {
    width: 38px;
    height: 38px;
    border-radius: 11px;
    background: rgba(26, 20, 46, 0.92);
    border: 1px solid rgba(157, 111, 243, 0.28);
    color: #f0e6ff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 0.95rem;
    transition: var(--transition-fast);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.28);
    flex-shrink: 0;
}

.theme-toggle-btn:hover {
    border-color: var(--accent-lavender);
    background: rgba(123, 63, 228, 0.24);
    transform: translateY(-1px);
    box-shadow: 0 6px 18px rgba(123, 63, 228, 0.28);
}

html[data-theme="light"] .theme-toggle-btn {
    background: #f3effd;
    border-color: rgba(123, 63, 228, 0.26);
    color: #2b2440;
    box-shadow: 0 4px 12px rgba(82, 46, 160, 0.08);
}

html[data-theme="light"] .theme-toggle-btn:hover {
    background: #e9e2fb;
    border-color: rgba(123, 63, 228, 0.45);
    color: #1a1625;
}

/* ============================================
   JASNY MOTYW — HEADER, NAV, DRAWER & FOOTER
   ============================================ */
html[data-theme="light"] header {
    background: rgba(255, 255, 255, 0.84);
    border-color: rgba(123, 63, 228, 0.18);
    box-shadow: 0 12px 32px rgba(82, 46, 160, 0.09);
}

html[data-theme="light"] header.scrolled {
    background: rgba(255, 255, 255, 0.95);
    border-color: rgba(123, 63, 228, 0.3);
    box-shadow: 0 16px 40px rgba(82, 46, 160, 0.14);
}

html[data-theme="light"] .logo {
    color: #1a1625;
}

html[data-theme="light"] nav ul {
    background: rgba(123, 63, 228, 0.06);
    border-color: rgba(123, 63, 228, 0.14);
}

html[data-theme="light"] nav a {
    color: #4b445c;
}

html[data-theme="light"] nav a:hover {
    color: #1a1625;
    background: rgba(123, 63, 228, 0.1);
}

html[data-theme="light"] nav a.active {
    color: #ffffff;
}

html[data-theme="light"] .mobile-menu-btn {
    background: #f3effd;
    border-color: rgba(123, 63, 228, 0.22);
    color: #1a1625;
}

html[data-theme="light"] .mobile-drawer {
    background: rgba(255, 255, 255, 0.96);
    border-color: rgba(123, 63, 228, 0.22);
    box-shadow: 0 20px 50px rgba(82, 46, 160, 0.16);
}

html[data-theme="light"] .mobile-drawer a {
    color: #4b445c;
}

html[data-theme="light"] .mobile-drawer a:hover,
html[data-theme="light"] .mobile-drawer a.active {
    background: rgba(123, 63, 228, 0.1);
    color: #5b21b6;
}

html[data-theme="light"] footer {
    background: #ede8fa;
    border-top-color: rgba(123, 63, 228, 0.18);
}

html[data-theme="light"] .footer-links li a {
    color: #4b445c;
}

html[data-theme="light"] .footer-links li a:hover {
    color: #5b21b6;
}

html[data-theme="light"] .footer-bottom {
    border-top-color: rgba(123, 63, 228, 0.14);
    color: #6e6680;
}

html[data-theme="light"] .back-to-top {
    background: rgba(123, 63, 228, 0.1);
    color: #6d28d9;
}

html[data-theme="light"] .back-to-top:hover {
    color: #ffffff;
}


/* ============================================
   LANGUAGE SELECTOR (FLOATING)
   ============================================ */
.hero .lang-selector {
    position: absolute;
    top: 7rem;
    right: 5%;
    z-index: 900;
    opacity: 0;
    animation: fadeInLang 0.5s ease 0.3s forwards;
    width: 160px; /* Powiększona szerokość */
    /* Fixed width for better consistency */
}

@keyframes fadeInLang {
    from {
        opacity: 0;
        transform: translateY(-5px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.lang-btn {
    background: rgba(15, 15, 21, 0.95);
    border: 1px solid var(--accent-purple);
    color: var(--text-white);
    padding: 0.6rem 1rem;
    border-radius: 6px;
    /* Slightly more rounded */
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    /* Align contents to left */
    gap: 12px;
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.2s;
    backdrop-filter: blur(15px);
    width: 100%;
    /* Match container width */
}

/* Vertical alignment for items in button */
.lang-btn i {
    margin-left: auto;
    /* Push arrow to the right */
    font-size: 0.75rem;
}

.lang-selector:hover .lang-btn {
    background: var(--accent-purple);
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
}

.lang-btn img {
    width: 22px;
    height: auto;
    border-radius: 2px;
    display: block;
}

.lang-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    /* Match button width exactly */
    background: #0f0f15;
    border: 1px solid var(--accent-purple);
    border-top: none;
    border-radius: 0 0 6px 6px;
    padding: 5px 0;
    /* Vertical padding only */
    display: none;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.8);
    z-index: 1001;
}

.lang-selector:hover .lang-dropdown {
    display: block;
}

.lang-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0.8rem 1.2rem;
    /* Increased padding left as requested */
    color: var(--text-gray);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 600;
    transition: all 0.2s;
}

.lang-item:hover {
    background: rgba(123, 63, 228, 0.3);
    color: var(--text-white);
    /* Pure white on hover */
}

.lang-item img {
    width: 18px;
    border-radius: 1px;
