:root {
    --primary: #0070f3;
    --primary-glow: rgba(0, 112, 243, 0.3);
    --bg: #050505;
    --surface: #111111;
    --text: #ffffff;
    --text-muted: #888888;
    --accent: #ff9d00;
    --success: #00ff88;
    --error: #ff4d4d;
    --glass: rgba(255, 255, 255, 0.03);
    --glass-border: rgba(255, 255, 255, 0.1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, sans-serif;
    background-color: var(--bg);
    color: var(--text);
    line-height: 1.6;
    overflow-x: hidden;
}

.background-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 50% -20%, #002d5a 0%, transparent 50%);
    z-index: -1;
    opacity: 0.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.nav-container {
    width: 100%;
    max-width: 100%;
    padding: 0 4rem;
}

nav {
    position: fixed;
    top: 0;
    width: 100%;
    height: 80px;
    display: flex;
    align-items: center;
    backdrop-filter: blur(10px);
    background: rgba(0, 0, 0, 0.5);
    border-bottom: 1px solid var(--glass-border);
    z-index: 1000;
}

.nav-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    max-width: 100%;
    padding: 0 4rem;
}

.logo {
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: -1px;
}

.logo-accent {
    color: var(--primary);
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.nav-icon-link {
    color: var(--text-muted);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
}

.nav-icon-link:hover {
    color: var(--accent);
    border-color: var(--accent);
    box-shadow: 0 0 20px rgba(255, 157, 0, 0.4);
    transform: translateY(-2px);
}

.discord-nav-link {
    color: var(--text-muted);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    animation: pulse-glow 3s infinite ease-in-out;
}

@keyframes pulse-glow {
    0%, 100% { box-shadow: 0 0 5px rgba(88, 101, 242, 0.2); border-color: var(--glass-border); }
    50% { box-shadow: 0 0 15px rgba(88, 101, 242, 0.4); border-color: rgba(88, 101, 242, 0.5); }
}

.discord-nav-link:hover {
    color: #5865F2; /* Discord Blue */
    border-color: #5865F2;
    box-shadow: 0 0 20px rgba(88, 101, 242, 0.4);
    transform: translateY(-2px);
}

.discord-nav-link svg {
    width: 20px;
    height: 20px;
}

/* Animations */
@keyframes reveal {
    from { transform: translate3d(0, 30px, 0); opacity: 0; }
    to { transform: translate3d(0, 0, 0); opacity: 1; }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.hero {
    padding: 160px 0 80px;
    text-align: center;
}

.hero-content > * {
    animation: reveal 0.8s cubic-bezier(0.4, 0, 0.2, 1) both;
}

.hero-content .badge { animation-delay: 0.1s; }
.hero-content h1 { animation-delay: 0.3s; }
.hero-content .hero-description { animation-delay: 0.5s; }
.hero-content .cta-group { animation-delay: 0.7s; }

.badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 6px;
    padding: 0.5rem 1rem;
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: 30px;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 2rem;
    max-width: 100%;
    word-break: break-all;
    text-align: center;
}

h1 {
    font-size: clamp(2.5rem, 8vw, 4.5rem);
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    letter-spacing: -2px;
}

.gradient-text {
    background: linear-gradient(to right, var(--primary), #00d2ff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-description {
    font-size: 1.25rem;
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto 3rem;
}

.cta-group {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-bottom: 4rem;
}

.btn {
    padding: 1rem 2rem;
    border-radius: 12px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    will-change: transform;
}

.btn-primary {
    background: var(--primary);
    color: white;
    box-shadow: 0 0 20px var(--primary-glow);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 30px var(--primary-glow);
}

.btn-secondary {
    background: var(--glass);
    color: var(--text);
    border: 1px solid var(--glass-border);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.08);
    transform: translateY(-2px);
}

/* Przycisk Wesprzyj projekt - styl i animacja pulsu */
#supportBtn {
    border-color: rgba(255, 74, 74, 0.3) !important;
    animation: pulse-glow-red 3s infinite ease-in-out;
    transition: all 0.3s ease;
}

#supportBtn:hover {
    border-color: #ff4a4a !important;
    box-shadow: 0 0 20px rgba(255, 74, 74, 0.4) !important;
    transform: translateY(-2px) !important;
    background: rgba(255, 74, 74, 0.05) !important;
}

@keyframes pulse-glow-red {
    0%, 100% { 
        box-shadow: 0 0 5px rgba(255, 74, 74, 0.15); 
        border-color: rgba(255, 74, 74, 0.3); 
    }
    50% { 
        box-shadow: 0 0 15px rgba(255, 74, 74, 0.35); 
        border-color: rgba(255, 74, 74, 0.6); 
    }
}

.hero-preview {
    margin-top: 4rem;
    perspective: 1000px;
}

.preview-window {
    background: #000;
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 40px 100px rgba(0,0,0,0.8);
    transform: rotateX(5deg);
    transition: transform 0.5s;
}

.preview-window:hover {
    transform: rotateX(0deg);
}

.window-header {
    background: #111;
    padding: 0.75rem 1rem;
    display: flex;
    align-items: center;
    border-bottom: 1px solid var(--glass-border);
}

.dots {
    display: flex;
    gap: 6px;
}

.dots span {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255,255,255,0.1);
}

.window-title {
    margin-left: 1.5rem;
    font-size: 0.8rem;
    color: var(--text-muted);
    font-family: 'JetBrains Mono', monospace;
}

.window-content {
    padding: 2rem;
    background: #000b1a;
    font-family: 'JetBrains Mono', monospace;
}

.sip-row {
    display: grid;
    grid-template-columns: 80px 120px 1fr 80px 120px;
    padding: 1rem 0;
    border-bottom: 1px solid rgba(0, 112, 243, 0.1);
    align-items: center;
    text-align: left;
}

.sip-row.header {
    color: var(--text-muted);
    font-size: 0.75rem;
    text-transform: uppercase;
    padding-top: 0;
}

.time { color: var(--accent); font-weight: bold; }
.train { color: #fff; }
.route { color: #fff; }
.platform { color: var(--accent); text-align: center; }
.status.on-time { color: var(--success); }
.status.delayed { color: var(--error); }

.features {
    padding: 100px 0;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.feature-card {
    background: var(--surface);
    padding: 2.5rem;
    border-radius: 24px;
    border: 1px solid var(--glass-border);
    transition: all 0.3s;
}

.feature-card:hover {
    border-color: var(--primary);
    transform: translateY(-10px);
}

.feature-header {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.feature-icon {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 112, 243, 0.1);
    color: var(--primary);
    border-radius: 10px;
    border: 1px solid rgba(0, 112, 243, 0.2);
}

.feature-card h3 {
    font-size: 1.25rem;
    font-weight: 700;
}

.feature-card p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

.toast-container {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.toast {
    background: rgba(20, 20, 20, 0.9);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    color: white;
    padding: 1rem 1.5rem;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    transform: translateX(120%);
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.toast.show {
    transform: translateX(0);
}

.toast-icon {
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--primary);
    border-radius: 50%;
    font-size: 12px;
}

.btn-disabled {
    opacity: 0.5 !important;
    cursor: not-allowed !important;
    pointer-events: none;
    transform: none !important;
    box-shadow: none !important;
}

.gallery {
    padding: 100px 0;
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-header h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    background: linear-gradient(to right, #fff, var(--text-muted));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.bento-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-auto-rows: 240px;
    gap: 1.5rem;
}

.bento-item {
    position: relative;
    background: var(--surface);
    border-radius: 24px;
    border: 1px solid var(--glass-border);
    overflow: hidden;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.bento-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.8s;
    opacity: 0.8;
}

.bento-item:hover {
    border-color: var(--primary);
    box-shadow: 0 20px 40px rgba(0,0,0,0.4);
    transform: translateY(-5px);
}

.bento-item:hover img {
    transform: scale(1.1);
    opacity: 1;
}

.item-large {
    grid-column: span 2;
    grid-row: span 2;
}

.item-wide {
    grid-column: span 2;
}

.item-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 2rem;
    background: linear-gradient(transparent, rgba(0,0,0,0.8));
    color: white;
    font-weight: 600;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.3s;
}

.bento-item:hover .item-overlay {
    opacity: 1;
    transform: translateY(0);
}

@media (max-width: 1024px) {
    .bento-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    .bento-grid {
        grid-template-columns: 1fr;
        grid-auto-rows: 300px;
    }
    .item-large, .item-wide {
        grid-column: span 1;
        grid-row: span 1;
    }
}

.lightbox-modal {
    display: none;
    position: fixed;
    z-index: 2000;
    padding-top: 50px;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(15px);
    cursor: pointer;
}

.lightbox-content {
    margin: auto;
    display: block;
    max-width: 90%;
    max-height: 80vh;
    border-radius: 12px;
    border: 1px solid var(--glass-border);
    animation: zoom 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes zoom {
    from { transform: scale(0.8); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

.close-lightbox {
    position: absolute;
    top: 30px;
    right: 50px;
    color: #fff;
    font-size: 50px;
    font-weight: bold;
    transition: 0.3s;
    cursor: pointer;
    z-index: 2001;
}

.close-lightbox:hover {
    color: var(--primary);
    transform: scale(1.1);
}

#lightbox-caption {
    margin: auto;
    display: block;
    width: 80%;
    max-width: 700px;
    text-align: center;
    color: #ccc;
    padding: 20px 0;
    font-size: 1.2rem;
    font-weight: 500;
}

footer {
    padding: 1.5rem 0;
    border-top: 1px solid var(--glass-border);
    margin-top: 4rem;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.footer-links {
    display: flex;
    gap: 2rem;
}

.footer-links a {
    color: var(--text-muted);
    text-decoration: none;
}

@media (max-width: 768px) {
    .nav-content { padding: 0 1.5rem; }
    .hero { padding: 120px 0 60px; }
    h1 { font-size: 2.8rem; letter-spacing: -1px; }
    .hero-description { font-size: 1.1rem; padding: 0 1rem; }
    .cta-group { flex-direction: column; width: 100%; max-width: 300px; margin: 0 auto 3rem; }
    .btn { width: 100%; justify-content: center; }
    .logo { margin-left: 0; }
    .container { padding: 0 1.5rem; }
}

.docs-page .docs-hero {
    padding: 160px 0 80px;
    text-align: center;
}

.docs-container {
    max-width: 1000px;
    margin: 4rem auto 0;
    background: #000;
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 40px 100px rgba(0,0,0,0.8);
    animation: reveal 0.8s cubic-bezier(0.4, 0, 0.2, 1) both;
    animation-delay: 0.2s;
    will-change: transform, opacity;
}

.docs-viewer-header {
    background: #111;
    padding: 1rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--glass-border);
}

.docs-viewer-header .window-title {
    margin-left: 0;
    font-size: 0.9rem;
}

.btn-download-icon {
    color: var(--text-muted);
    transition: color 0.3s, transform 0.3s;
}

.btn-download-icon:hover {
    color: var(--primary);
    transform: scale(1.1);
}

.docs-viewer-body {
    background: #1a1a1a;
    line-height: 0;
}

.docs-viewer-body iframe {
    border: none;
    background: #1a1a1a;
}

@media (max-width: 768px) {
    .docs-container {
        margin-top: 2rem;
        border-radius: 12px;
    }
    
    .docs-viewer-body iframe {
        height: 500px;
    }
}

.changelog-modal-card {
    background: #0f0f0f !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    border-radius: 24px !important;
    padding: 2.5rem !important;
    max-width: 500px;
    width: 90%;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #fff;
    max-height: 80vh;
    overflow-y: auto;
    overflow-x: hidden;
    box-shadow: 0 20px 50px rgba(0,0,0,0.8);
    backdrop-filter: blur(10px);
}
.changelog-version-item {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding-bottom: 1.25rem;
}
.changelog-version-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}
.changelog-version-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
    flex-wrap: wrap;
    gap: 8px;
}
.changelog-version-header h3 {
    font-size: 1.1rem;
    font-family: 'JetBrains Mono', monospace;
    color: var(--primary);
    font-weight: 700;
    word-break: break-all;
    margin-right: 12px;
}
.changelog-version-header span {
    font-size: 0.75rem;
    color: var(--text-muted);
    white-space: nowrap;
}
.changelog-version-content {
    font-size: 0.85rem;
    color: #ccc;
    white-space: pre-wrap;
    line-height: 1.5;
    word-break: break-word;
}

html::-webkit-scrollbar, 
body::-webkit-scrollbar, 
.changelog-modal-card::-webkit-scrollbar {
    width: 8px !important;
    height: 8px !important;
}

html::-webkit-scrollbar-track, 
body::-webkit-scrollbar-track, 
.changelog-modal-card::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.2) !important;
    border-radius: 4px !important;
}

html::-webkit-scrollbar-thumb, 
body::-webkit-scrollbar-thumb, 
.changelog-modal-card::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.08) !important;
    border: 2px solid transparent !important;
    border-radius: 4px !important;
    background-clip: padding-box !important;
}

html::-webkit-scrollbar-thumb:hover, 
body::-webkit-scrollbar-thumb:hover, 
.changelog-modal-card::-webkit-scrollbar-thumb:hover {
    background: var(--primary) !important;
    border: 2px solid transparent !important;
    background-clip: padding-box !important;
}

* {
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.08) rgba(0, 0, 0, 0.2);
}
