/* ===== BODY ===== */
* { 
    margin: 0; 
    padding: 0; 
    box-sizing: border-box; 
}

html { 
    scroll-behavior: smooth; 
}

body {
    min-height: 100%;
    font-family: 'Rubik', sans-serif;
    background-color: #12161c;
    color: #d6dbea;
    line-height: 1.6;
}

.email-hidden {
    display: none;
}

/* ===== NAVBAR ===== */
header {
    position: fixed;
    top: 0;
    width: 100%;
    background-color: #21252b;
    transition: all 0.3s ease;
    z-index: 1000;
}

.navbar {
    max-width: 1300px;
    margin: 0 auto;
    padding: 24px 32px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: padding 0.3s ease;
}

header.shrink .navbar { 
    padding: 10px 20px; 
}

.logo { 
    font-family: 'IBM Plex Mono', monospace;
    font-weight: 500; 
    font-size: 1.32rem; 
    transition: color 0.3s ease;
    text-decoration: none;
    color: #d6dbea;
}

.logo:hover {
    color: #4da3ff;
}

.logo::after {
    content: "█";
    color: #4da3ff;
    animation: blink 1.1s step-end infinite;
    margin-left: 6px; 
    vertical-align: middle;
}

@keyframes blink {
    from, to { opacity: 1; }
    50% { opacity: 0; }
}

/* Language switcher - flags + text */
.lang-switch {
    display: flex;
    gap: 10px;
    align-items: center;
    margin-left: 20px;
}

.flag-text-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    color: #aaa;
    border: 1px solid transparent;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.85rem;
}

.flag-text-btn:hover {
    background: #2a2e35;
    color: #4da3ff;
    border-color: #4da3ff44;
}

.flag-text-btn.active {
    background: #2a2e35;
    color: #4da3ff;
    border-color: #4da3ff;
}

.flag-mini {
    width: 20px;
    height: 15px;
    border-radius: 2px;
    flex-shrink: 0;
}

/* Przycisk BLOG w navbarze */
.blog-btn {
    display: inline-block;
    padding: 8px 20px;
    background: #4da3ff;
    color: #ffffff !important;
    text-decoration: none;
    border-radius: 6px;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.9rem;
    font-weight: 500;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    margin-left: 20px;
}

.blog-btn:hover {
    background: #3d8fe6;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(77, 163, 255, 0.4);
}

/* Poprawka wyrównania navbara */
.nav-wrapper {
    display: flex;
    align-items: center;
}

@media (max-width: 768px) {
    .blog-btn {
        margin: 10px 0;
    }
}

/* Menu mobilne */
.menu-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 5px;
}

.menu-toggle span {
    width: 25px;
    height: 3px;
    background-color: #eaeaea;
    transition: all 0.3s ease;
}

.nav-wrapper {
    display: flex;
    align-items: center;
}

nav {
    display: flex;
}

nav a {
    color: #eaeaea;
    text-decoration: none;
    margin-left: 20px;
    font-size: 0.95rem;
    font-family: 'IBM Plex Mono', monospace;
    font-style: normal;
    font-weight: 400;
    letter-spacing: 0.4px;
    transition: color 0.3s ease;
}

nav a:hover { 
    color: #4da3ff; 
}

/* ===== MAIN ===== */
main {
    max-width: 900px;
    margin: 0 auto;
    padding: 20px 20px 60px;
}

section { 
    margin-bottom: 20px; 
    margin-top: 30px;
}

h1, h2 { 
    margin-bottom: 20px; 
    font-weight: normal;
    font-size: 2em;
}

p {
    margin-bottom: 15px; 
    color: #cccccc; 
}

ul { 
    margin-bottom: 15px; 
    padding-left: 40px; 
}

.hero-cta {
    display: inline-block;
    margin-top: 28px;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.9rem;
    letter-spacing: 0.4px;
    color: #4da3ff;
    text-decoration: none;
    transition: text-decoration 0.3s ease;
}

.hero-cta:hover {
    text-decoration: underline;
}

/* ===== TECH MARQUEE ===== */
.tech-marquee {
    position: relative;
    overflow: hidden;
    margin-top: 30px;
    -webkit-mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
    mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
}

.tech-track {
    display: flex;
    gap: 20px;
    width: fit-content;
}

.tech-track-inner {
    display: flex;
    gap: 20px;
    animation: scroll 20s linear infinite;
}

@keyframes scroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

.tech-item {
    padding: 12px 20px;      
    background-color: #1f1f1f;
    border-radius: 8px;
    border: 1px solid #2a2a2a;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 140px;
    height: 70px; 
    flex-shrink: 0;
    transition: all 0.25s ease;
}

.tech-item img {
    max-height: 100%; 
    max-width: 100%;
    width: auto;
    height: auto;
    object-fit: contain; 
}

.tech-item:hover {
    background-color: #252525;
    border-color: #4da3ff;
    transform: scale(1.05);
}

.tech-marquee:hover .tech-track-inner {
    animation-play-state: paused;
}

/* ===== HERO ===== */
.hero {
    background:
        linear-gradient(rgba(0,0,0,.65), rgba(0,0,0,.65)),
        url("../tlo.png") center / cover no-repeat;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background: inherit;
    filter: blur(6px);
    transform: scale(1.05);
    z-index: 0;
}

.hero-content {
    max-width: 900px;
    margin: 0 auto;
    padding: 150px 20px 60px;
    position: relative;
    z-index: 1;
}

.hero h1 {
    font-size: 2.4rem;
    margin-bottom: 20px;
}

.hero p {
    font-size: 1.05rem;
    max-width: 720px;
    color: #dcdcdc;
}

/* ===== SERVICES GRID ===== */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 28px;
    margin-top: 20px;
}

.service-card {
    background: #1c1f26;
    border: 1px solid #252529;
    border-radius: 16px;
    padding: 32px 28px;
    transition: all 0.35s ease;
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(to right, #4da3ff, #6ab0ff);
    opacity: 0.7;
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.5);
    border-color: #4da3ff44;
}

.service-card:hover::before {
    transform: scaleX(1);
}

.card-icon {
    width: 50px;
    height: 50px;
    margin-bottom: 16px;
    color: #4da3ff;
    opacity: 0.9;
}

.service-card h3 {
    font-family: 'Rubik', sans-serif;
    font-weight: 500;
    font-size: 1.5rem;
    margin-bottom: 20px;
    color: #ffffff;
}

.service-card ul {
    list-style: none;
    padding: 0;
}

.service-card li {
    position: relative;
    padding-left: 28px;
    margin-bottom: 12px;
    color: #cccccc;
}

.service-card li::before {
    content: "→";
    position: absolute;
    left: 0;
    color: #4da3ff;
    font-weight: bold;
}

/* ===== PROJECTS ACCORDION ===== */
.projects-accordion {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-top: 20px;
}

.project-item {
    background: #1c1f26;
    border: 1px solid #252529;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.project-item.active {
    border-color: #4da3ff;
    box-shadow: 0 10px 30px rgba(77, 163, 255, 0.2);
}

.project-header {
    display: flex;
    align-items: center;
    padding: 24px 28px;
    cursor: pointer;
    transition: background 0.3s ease;
}

.project-header:hover {
    background: #21252b;
}

.project-icon {
    font-size: 2.5rem;
    margin-right: 20px;
    min-width: 60px;
    text-align: center;
}

.project-title {
    flex: 1;
}

.project-title h3 {
    font-size: 1.4rem;
    color: #fff;
    margin-bottom: 6px;
    font-weight: 500;
}

.project-subtitle {
    font-size: 0.9rem;
    color: #aaa;
}

.project-arrow {
    font-size: 1.5rem;
    color: #4da3ff;
    transition: transform 0.3s ease;
    margin-left: 15px;
}

.project-item.active .project-arrow {
    transform: rotate(180deg);
}

.project-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease;
    background: #12161c;
}

.project-content-inner {
    padding: 28px;
    border-top: 1px solid #252529;
}

.project-item.active .project-content {
    max-height: 1200px;
}

.project-content-inner p {
    margin-bottom: 16px;
    color: #ccc;
    line-height: 1.7;
}

.project-content-inner strong {
    color: #fff;
}

.project-content-inner ul {
    list-style: none;
    padding: 0;
    margin-bottom: 16px;
}

.project-content-inner li {
    position: relative;
    padding-left: 24px;
    margin-bottom: 10px;
    color: #ccc;
}

.project-content-inner li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: #4da3ff;
    font-weight: bold;
}

.project-content-inner a {
    color: #4da3ff;
    text-decoration: none;
    transition: color 0.3s ease;
}

.tech-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 16px;
}

.tech-tag {
    background: #4da3ff22;
    color: #4da3ff;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.85rem;
}

/* ===== FOOTER ===== */
.footer-section {
    border-top: 1px solid #222;
    background-color: #080d18;
    padding: 60px 20px 30px;
    margin-bottom: 0;
}

.footer-grid {
    max-width: 1100px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
}

.footer-col h4 {
    font-family: 'IBM Plex Mono', monospace;
    font-weight: 400;
    margin-bottom: 12px;
    color: #ffffff;
}

.footer-col p {
    font-size: 0.9rem;
    color: #bdbdbd;
    line-height: 1.6;
}

.footer-col a {
    color: #4da3ff;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-col a:hover {
    color: #6ab0ff;
    text-decoration: underline;
}

.footer-logo .logo {
    margin-bottom: 12px;
}

.footer-bottom {
    text-align: center;
    margin-top: 40px;
    font-size: 0.8rem;
    color: #777;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 800px) {
    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }
}

@media (max-width: 768px) {
    .menu-toggle {
        display: flex;
    }
    
    .nav-wrapper {
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background-color: #21252b;
        flex-direction: column;
        align-items: center;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease;
    }
    
    .nav-wrapper.active {
        max-height: 400px;
        padding: 20px 0;
    }
    
    nav {
        flex-direction: column;
        align-items: center;
    }
    
    nav a {
        margin: 10px 0;
    }
    
    .lang-switch {
        margin: 15px 0 0 0;
    }
    
    .hero h1 {
        font-size: 1.8rem;
    }
    
    .hero p {
        font-size: 0.95rem;
    }
    
    .project-header {
        padding: 20px;
    }
    
    .project-icon {
        font-size: 2rem;
        min-width: 50px;
        margin-right: 15px;
    }
    
    .project-title h3 {
        font-size: 1.2rem;
    }
}

@media (max-width: 600px) {
    main {
        padding-left: 15px;
        padding-right: 15px;
    }
    
    .services-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .service-card {
        padding: 24px 20px;
    }
    
    .card-icon {
        width: 40px;
        height: 40px;
    }
    
    .service-card h3 {
        font-size: 1.35rem;
    }
    
    .tech-item {
        padding: 8px 12px;
        min-width: 120px;
        height: 60px;
    }
    
    .project-content-inner {
        padding: 20px;
    }
}