/* ===== Reset i zmienne ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #2563eb;
    --secondary-color: #1e40af;
    --accent-color: #f59e0b;
    --text-dark: #1f2937;
    --text-light: #6b7280;
    --bg-light: #f9fafb;
    --bg-white: #ffffff;
    --border-color: #e5e7eb;
    --success-color: #10b981;
    --error-color: #ef4444;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    --font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    --font-size-base: 16px;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-family, 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif);
    font-size: var(--font-size-base, 16px);
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--bg-white);
}

/* Neutralizacja inline-stylów czcionek wklejonych z zewnętrznych edytorów */
.about-text [style] {
    font-family: inherit !important;
    font-size: inherit !important;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ===== Nawigacja ===== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: var(--bg-white);
    box-shadow: var(--shadow-md);
    z-index: 1000;
    transition: all 0.3s ease;
}

.navbar.scrolled {
    box-shadow: var(--shadow-lg);
}

.nav-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
}

.logo img {
    height: 60px;
    width: auto;
    display: block;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
}

.nav-toggle span {
    width: 25px;
    height: 3px;
    background: var(--text-dark);
    margin: 3px 0;
    transition: 0.3s;
    border-radius: 3px;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 1.2rem;
    align-items: center;
    flex-wrap: nowrap;
    white-space: nowrap;
    margin-left: auto;
}

.nav-link {
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 500;
    padding: 0.5rem 0.7rem;
    border-radius: 0.5rem;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary-color);
    background: var(--bg-light);
}

/* ===== Hero Section ===== */
.hero {
    position: relative;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
    overflow: hidden;
}

/* Animowany slideshow w tle Hero */
.hero-slideshow {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
}

.hero-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 2s ease-in-out;
    animation: kenBurns 20s ease-in-out infinite;
}

.hero-slide.active {
    opacity: 1;
    z-index: 1;
}

@keyframes kenBurns {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
    100% {
        transform: scale(1);
    }
}

/* Video background (opcjonalne - wymaga dodania pliku /videos/hero.mp4) */
.hero-video {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    transform: translate(-50%, -50%);
    z-index: 0;
    object-fit: cover;
    display: none; /* Ukryj dopóki film nie zostanie dodany */
}

.hero-video[src]:not([src=""]) {
    display: block; /* Pokaż gdy src jest ustawione */
}

.hero::before {
    content: '';
    position: absolute;
    top: -10%;
    left: -10%;
    right: -10%;
    bottom: -10%;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 50%, var(--primary-color) 100%);
    background-size: 200% 200%;
    animation: gradientMove 6s ease infinite, zoomPulse 4s ease-in-out infinite alternate;
    z-index: 1;
    display: none; /* Ukryj gdy mamy slideshow */
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.82) 0%, rgba(30, 64, 175, 0.88) 100%);
    z-index: 2;
}

.hero-content {
    position: relative;
    z-index: 10;
    max-width: 900px;
    padding: 2rem;
    animation: fadeInUp 1s ease;
}

.hero-title {
    font-size: clamp(2rem, 5vw, 3.5rem);
    margin-bottom: 1.5rem;
    font-weight: 700;
    line-height: 1.2;
    animation: fadeInUp 1s ease, glowStrong 1.5s ease-in-out infinite alternate, colorShift 4s ease infinite;
}

.hero-subtitle {
    font-size: clamp(1rem, 2vw, 1.5rem);
    margin-bottom: 2.5rem;
    opacity: 0.95;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.scroll-indicator {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    animation: bounce 2s infinite;
    z-index: 10;
}

.scroll-arrow {
    font-size: 2rem;
    margin-top: 0.5rem;
}

/* ===== Buttons ===== */
.btn {
    display: inline-block;
    padding: 1rem 2rem;
    border-radius: 0.5rem;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    cursor: pointer;
    font-size: 1rem;
}

.btn-primary {
    background: var(--accent-color);
    color: white;
}

.btn-primary:hover {
    background: #d97706;
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    background: transparent;
    color: white;
    border-color: white;
}

.btn-secondary:hover {
    background: white;
    color: var(--primary-color);
}

/* ===== Stats Section ===== */
.stats {
    background: var(--bg-white);
    padding: 4rem 0;
    margin-top: -3rem;
    position: relative;
    z-index: 10;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
}

.stat-item {
    text-align: center;
    padding: 2rem;
    background: var(--bg-light);
    border-radius: 1rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.stat-item::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(37, 99, 235, 0.05) 0%, transparent 70%);
    animation: rotateGlow 10s linear infinite;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.stat-item:hover::before {
    opacity: 1;
}

.stat-item:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: var(--shadow-lg);
}

.stat-number {
    font-size: 3rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.stat-label {
    color: var(--text-light);
    font-size: 1rem;
}

/* ===== Sections ===== */
section {
    padding: 5rem 0;
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-title {
    font-size: 2.5rem;
    color: var(--text-dark);
    margin-bottom: 1rem;
    font-weight: 700;
}

.section-subtitle {
    font-size: 1.25rem;
    color: var(--text-light);
}

/* ===== About Section ===== */
.about {
    background: var(--bg-light);
}

.about-text {
    max-width: 900px;
    margin: 0 auto;
}

.lead {
    font-size: 1.25rem;
    font-weight: 500;
    color: var(--text-dark);
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

.about-text p {
    margin-bottom: 1.25rem;
    line-height: 1.8;
    text-align: justify;
}

.branches-list {
    margin: 1.5rem 0 1.5rem 2rem;
    line-height: 1.8;
}

.branches-list li {
    margin-bottom: 0.75rem;
    color: var(--text-dark);
}

.features-grid {
    display: grid;
    gap: 2rem;
    margin-top: 3rem;
}

.feature-item {
    display: flex;
    gap: 1.5rem;
    padding: 2rem;
    background: var(--bg-white);
    border-radius: 1rem;
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
}

.feature-item:hover {
    box-shadow: var(--shadow-md);
    transform: translateX(10px);
}

.feature-icon {
    font-size: 2rem;
    color: var(--success-color);
    font-weight: 700;
}

.feature-text h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
    color: var(--text-dark);
}

.feature-text p {
    color: var(--text-light);
}

/* ===== Services Section ===== */
.services {
    background: var(--bg-white);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.service-card {
    background: var(--bg-white);
    border-radius: 1rem;
    padding: 2rem;
    box-shadow: var(--shadow-md);
    transition: all 0.3s ease;
    border: 2px solid transparent;
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(37, 99, 235, 0.1),
        transparent
    );
    transition: left 0.5s ease;
}

.service-card:hover::before {
    left: 100%;
}

.service-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: var(--shadow-xl);
    border-color: var(--primary-color);
}

.service-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    display: inline-block;
    transition: transform 0.3s ease;
    animation: iconFloat 3s ease-in-out infinite;
}

.service-card:hover .service-icon {
    transform: scale(1.3) rotate(10deg);
    animation: iconSpin 0.6s ease infinite, iconGlow 0.8s ease-in-out infinite;
}

@keyframes iconFloat {
    0%, 100% {
        transform: translateY(0px) rotate(0deg);
    }
    50% {
        transform: translateY(-10px) rotate(5deg);
    }
}

@keyframes iconSpin {
    0% {
        transform: rotate(0deg) scale(1.3);
    }
    50% {
        transform: rotate(180deg) scale(1.4);
    }
    100% {
        transform: rotate(360deg) scale(1.3);
    }
}

@keyframes iconGlow {
    0%, 100% {
        filter: drop-shadow(0 0 10px rgba(37, 99, 235, 0.6));
    }
    50% {
        filter: drop-shadow(0 0 25px rgba(245, 158, 11, 0.9));
    }
}

.service-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--text-dark);
}

.service-card p {
    color: var(--text-light);
    line-height: 1.8;
}

.service-short-desc {
    margin-bottom: 1rem;
}

/* Rozwijane szczegóły usługi */
.service-details {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, opacity 0.4s ease, margin 0.4s ease;
    opacity: 0;
    margin-top: 0;
    cursor: default; /* Normaly kursor w rozwiniętej treści */
}

.service-expanded .service-details {
    opacity: 1;
    margin-top: 1.5rem;
}

/* Video w karcie usługi */
.service-video-container {
    position: relative;
    width: 100%;
    padding-bottom: 35%; /* Zmniejszone z 56.25% (16:9) do 35% */
    margin-bottom: 1.5rem;
    border-radius: 0.75rem;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    background: #000;
}

/* Animowany obraz jako zamiennik video */
.service-animated-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    animation: kenBurnsZoom 20s ease-in-out infinite alternate;
}

@keyframes kenBurnsZoom {
    0% {
        transform: scale(1) translate(0, 0);
    }
    25% {
        transform: scale(1.15) translate(-2%, -2%);
    }
    50% {
        transform: scale(1.1) translate(2%, 1%);
    }
    75% {
        transform: scale(1.15) translate(-1%, 2%);
    }
    100% {
        transform: scale(1.2) translate(1%, -1%);
    }
}

/* Nakładka z gradientem */
.service-animated-image::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        135deg,
        rgba(37, 99, 235, 0.15),
        transparent 50%,
        rgba(245, 158, 11, 0.15)
    );
    z-index: 1;
    animation: gradientPulse 8s ease-in-out infinite;
}

@keyframes gradientPulse {
    0%, 100% {
        opacity: 0.3;
    }
    50% {
        opacity: 0.6;
    }
}

.service-details-content {
    padding: 1.5rem;
    background: var(--bg-light);
    border-radius: 0.5rem;
    border-left: 4px solid var(--primary-color);
}

.service-details-content p {
    margin-bottom: 0.75rem;
    font-size: 0.95rem;
    line-height: 1.7;
}

.service-details-content p:last-child {
    margin-bottom: 0;
}

/* Przycisk rozwijania */
.service-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 1rem;
    padding: 0.75rem 1.5rem;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 0.5rem;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    width: 100%;
}

.service-toggle:hover {
    background: var(--secondary-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.toggle-icon {
    font-size: 0.8rem;
    transition: transform 0.3s ease;
}

.service-expanded .toggle-icon {
    transform: rotate(180deg);
}

/* Karta rozwinięta */
.service-expanded {
    grid-column: span 1;
}

@media (min-width: 769px) {
    .service-expanded {
        grid-column: span 2;
    }
}

@media (min-width: 1024px) {
    .service-expanded {
        grid-column: span 3;
    }
}

/* ===== History Timeline ===== */
.history {
    background: var(--bg-light);
}

.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
    padding-left: 2rem;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: var(--primary-color);
}

.timeline-item {
    position: relative;
    padding-left: 3rem;
    margin-bottom: 3rem;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -10px;
    top: 0;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--accent-color);
    border: 4px solid var(--bg-light);
    box-shadow: var(--shadow-md);
}

.timeline-year {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.timeline-content h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
    color: var(--text-dark);
}

.timeline-content p {
    color: var(--text-light);
}

/* ===== Contact Section ===== */
.contact {
    background: var(--bg-white);
}

.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 3rem;
    max-width: 1000px;
    margin: 0 auto;
}

.contact-info {
    background: var(--bg-light);
    padding: 2rem;
    border-radius: 1rem;
}

.contact-info h3 {
    font-size: 1.5rem;
    margin-bottom: 2rem;
    color: var(--primary-color);
}

.contact-item {
    margin-bottom: 2rem;
}

.contact-item strong {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-dark);
}

.contact-item p {
    color: var(--text-light);
    line-height: 1.8;
}

.contact-item a {
    color: var(--primary-color);
    text-decoration: none;
}

.contact-item a:hover {
    text-decoration: underline;
}

/* ===== Forms ===== */
.contact-form,
.complaint-form {
    background: var(--bg-white);
    padding: 2rem;
    border-radius: 1rem;
    box-shadow: var(--shadow-md);
}

.complaint-form {
    max-width: 800px;
    margin: 0 auto;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--text-dark);
}

input,
textarea,
select {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 2px solid var(--border-color);
    border-radius: 0.5rem;
    font-size: 1rem;
    font-family: inherit;
    transition: all 0.3s ease;
}

input:focus,
textarea:focus,
select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

textarea {
    resize: vertical;
}

.complaint-fields {
    transition: all 0.3s ease;
}

/* ===== Footer ===== */
.footer {
    background: var(--text-dark);
    color: white;
    padding: 3rem 0 1rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 3rem;
    margin-bottom: 2rem;
}

.footer-col h3 {
    margin-bottom: 1rem;
    color: var(--accent-color);
}

.footer-col p {
    margin-bottom: 0.5rem;
    opacity: 0.8;
}

.footer-col ul {
    list-style: none;
}

.footer-col ul li {
    margin-bottom: 0.5rem;
}

.footer-col a {
    color: white;
    text-decoration: none;
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.footer-col a:hover {
    opacity: 1;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    opacity: 0.6;
}

/* ===== Toast Notifications ===== */
.toast {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    padding: 1rem 1.5rem;
    border-radius: 0.5rem;
    background: var(--success-color);
    color: white;
    box-shadow: var(--shadow-xl);
    transform: translateX(400px);
    transition: transform 0.3s ease;
    z-index: 9999;
    max-width: 300px;
}

.toast.show {
    transform: translateX(0);
}

.toast.error {
    background: var(--error-color);
}

/* ===== Animations ===== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateX(-50%) translateY(0);
    }
    40% {
        transform: translateX(-50%) translateY(-10px);
    }
    60% {
        transform: translateX(-50%) translateY(-5px);
    }
}

@keyframes gradientShift {
    0%, 100% {
        background-position: 0% 50%;
        filter: hue-rotate(0deg);
    }
    50% {
        background-position: 100% 50%;
        filter: hue-rotate(10deg);
    }
}

@keyframes zoomIn {
    0% {
        transform: scale(1);
    }
    100% {
        transform: scale(1.1);
    }
}

@keyframes floatParallax {
    0%, 100% {
        transform: translate(0, 0) rotate(0deg);
    }
    25% {
        transform: translate(2%, -2%) rotate(0.5deg);
    }
    50% {
        transform: translate(0, -3%) rotate(-0.5deg);
    }
    75% {
        transform: translate(-2%, -1%) rotate(0.3deg);
    }
}

@keyframes rotateGlow {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

@keyframes shimmer {
    0% {
        background-position: -1000px 0;
    }
    100% {
        background-position: 1000px 0;
    }
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.8;
    }
}

@keyframes glow {
    0% {
        text-shadow: 0 0 10px rgba(255,255,255,0.5);
    }
    100% {
        text-shadow: 0 0 20px rgba(255,255,255,0.8), 0 0 30px rgba(245,158,11,0.5);
    }
}

@keyframes glowStrong {
    0% {
        text-shadow: 0 0 20px rgba(255,255,255,0.8), 0 0 40px rgba(245,158,11,0.6);
        filter: brightness(1);
    }
    100% {
        text-shadow: 0 0 40px rgba(255,255,255,1), 0 0 60px rgba(245,158,11,0.9), 0 0 80px rgba(245,158,11,0.5);
        filter: brightness(1.2);
    }
}

@keyframes colorShift {
    0%, 100% {
        color: #ffffff;
    }
    50% {
        color: #fef3c7;
    }
}

@keyframes gradientMove {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

@keyframes zoomPulse {
    0% {
        transform: scale(1);
    }
    100% {
        transform: scale(1.15);
    }
}

/* ===== Park Maszynowy Section - Accordion Style ===== */
.machine-park {
    background: var(--bg-light);
    padding: 4rem 0;
}

.machines-accordion {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

/* Karta maszyny */
.machine-card {
    background: white;
    border-radius: 1rem;
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: all 0.3s ease;
}

.machine-card:hover {
    box-shadow: var(--shadow-xl);
    transform: translateY(-2px);
}

/* Nagłówek karty (zawsze widoczny) */
.machine-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.5rem 2rem;
    background: linear-gradient(135deg, var(--primary-color), #1e40af);
    color: white;
    cursor: pointer;
    user-select: none;
    transition: all 0.3s ease;
}

.machine-card-header:hover {
    background: linear-gradient(135deg, #1e40af, var(--primary-color));
}

.machine-card-title {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex: 1;
}

.machine-icon {
    font-size: 2rem;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.2));
}

.machine-card-title h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0;
    text-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.machine-toggle {
    font-size: 2rem;
    font-weight: 300;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255,255,255,0.2);
    border-radius: 50%;
    transition: all 0.3s ease;
}

.machine-card-header:hover .machine-toggle {
    background: rgba(255,255,255,0.3);
    transform: scale(1.1);
}

.machine-card.active .machine-toggle {
    transform: rotate(45deg);
}

/* Zawartość karty (rozwijana) */
.machine-card-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.machine-card.active .machine-card-content {
    max-height: 2000px;
}

.machine-content-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    padding: 2rem;
}

/* Sekcja zdjęć */
.machine-images {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.machine-main-image {
    width: 100%;
    height: auto;
    border-radius: 0.75rem;
    box-shadow: var(--shadow-lg);
    transition: transform 0.3s ease;
}

.machine-main-image:hover {
    transform: scale(1.02);
}

.machine-gallery {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.75rem;
}

.machine-gallery img {
    width: 100%;
    height: 120px;
    object-fit: cover;
    border-radius: 0.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-sm);
}

.machine-gallery img:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow-md);
}

/* Sekcja specyfikacji */
.machine-specs {
    padding: 1rem;
}

.machine-specs h4 {
    font-size: 1.3rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
    margin-top: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--primary-color);
}

.machine-specs h4:first-child {
    margin-top: 0;
}

.specs-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.specs-list li {
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
}

.specs-list li:last-child {
    border-bottom: none;
}

.specs-list li strong {
    color: var(--text-dark);
    min-width: 140px;
    font-weight: 600;
}

.specs-list.features li {
    color: var(--success-color);
    font-weight: 500;
}

.specs-list.features li::before {
    content: '✓';
    color: var(--success-color);
    font-weight: bold;
    margin-right: 0.5rem;
}

/* Responsive - Park Maszynowy */
@media (max-width: 968px) {
    .machine-content-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .machine-card-title h3 {
        font-size: 1.2rem;
    }
    
    .machine-icon {
        font-size: 1.5rem;
    }
}

@media (max-width: 768px) {
    .machine-card-header {
        padding: 1rem 1.5rem;
    }
    
    .machine-card-title h3 {
        font-size: 1rem;
    }
    
    .machine-content-grid {
        padding: 1.5rem;
    }
    
    .machine-gallery {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .specs-list li strong {
        min-width: 100px;
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .machines-accordion {
        margin: 0 0.5rem;
    }
    
    .machine-card-header {
        padding: 0.75rem 1rem;
    }
    
    .machine-card-title {
        gap: 0.5rem;
    }
    
    .machine-card-title h3 {
        font-size: 0.9rem;
    }
    
    .machine-icon {
        font-size: 1.2rem;
    }
    
    .machine-toggle {
        width: 32px;
        height: 32px;
        font-size: 1.5rem;
    }
}

/* ===== Portfolio Section ===== */
.portfolio {
    background: var(--bg-white);
    padding: 4rem 0;
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.portfolio-item {
    position: relative;
    overflow: hidden;
    border-radius: 1rem;
    height: 350px;
    cursor: pointer;
    box-shadow: var(--shadow-md);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.portfolio-item:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-xl);
}

.portfolio-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transition: transform 0.5s ease;
    display: block;
}

.portfolio-item:hover .portfolio-image {
    transform: scale(1.15);
}

.portfolio-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(37, 99, 235, 0.95), rgba(30, 64, 175, 0.8));
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 2rem;
    opacity: 0;
    transition: opacity 0.4s ease;
    color: white;
}

.portfolio-item:hover .portfolio-overlay {
    opacity: 1;
}

.portfolio-overlay h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    transform: translateY(20px);
    transition: transform 0.4s ease 0.1s;
}

.portfolio-item:hover .portfolio-overlay h3 {
    transform: translateY(0);
}

.portfolio-overlay p {
    font-size: 1rem;
    opacity: 0.9;
    transform: translateY(20px);
    transition: transform 0.4s ease 0.2s;
}

.portfolio-item:hover .portfolio-overlay p {
    transform: translateY(0);
}

/* Parallax Scroll Effect */
.parallax-section {
    position: relative;
    overflow: hidden;
}

.parallax-bg {
    position: absolute;
    top: -10%;
    left: -10%;
    width: 120%;
    height: 120%;
    background-size: cover;
    background-position: center;
    will-change: transform;
    transition: transform 0.1s ease-out;
}

/* Service Card Gallery */
.service-gallery {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    margin-top: 1.5rem;
}

.service-gallery-item {
    position: relative;
    height: 150px;
    border-radius: 0.5rem;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s ease;
}

.service-gallery-item:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow-lg);
}

.service-gallery-image {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    transition: transform 0.3s ease;
}

.service-gallery-item:hover .service-gallery-image {
    transform: scale(1.1);
}

/* Hover Effects Enhancement */
.service-card {
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.service-card:hover {
    transform: translateY(-15px) scale(1.02);
    box-shadow: 0 20px 40px rgba(37, 99, 235, 0.2);
}

.service-card:hover .service-icon {
    transform: scale(1.2) rotate(5deg);
    animation: iconBounce 0.6s ease;
}

@keyframes iconBounce {
    0%, 100% {
        transform: scale(1.2) rotate(5deg);
    }
    50% {
        transform: scale(1.3) rotate(-5deg);
    }
}

/* ===== Recruitment Section ===== */
.recruitment {
    padding: 5rem 0;
    background: var(--bg-light);
}

.recruitment-wrapper {
    display: grid;
    grid-template-columns: 1fr 1.4fr;
    gap: 3rem;
    align-items: start;
}

/* -- Job listings -- */
.recruitment-list-title,
.recruitment-form-title {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.4rem;
}

.recruitment-form-subtitle {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
}

.job-listings-container {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 1rem;
}

.recruitment-loading {
    color: var(--text-secondary);
    font-style: italic;
}

.no-jobs-message {
    color: var(--text-secondary);
    font-style: italic;
    padding: 1.5rem;
    background: var(--bg-white);
    border-radius: 0.75rem;
    text-align: center;
    border: 2px dashed var(--border-color);
}

.job-card {
    background: var(--bg-white);
    border-radius: 1rem;
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
    border: 2px solid transparent;
    cursor: pointer;
    transition: all 0.25s ease;
}

.job-card:hover {
    border-color: var(--primary-color);
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.job-card.selected {
    border-color: var(--primary-color);
    background: rgba(37, 99, 235, 0.04);
}

.job-card-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.job-card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
}

.job-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    background: var(--primary-light, rgba(37,99,235,0.1));
    color: var(--primary-color);
    border-radius: 2rem;
    padding: 0.2rem 0.75rem;
    font-size: 0.8rem;
    font-weight: 600;
}

.job-card-desc {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.6;
    white-space: pre-line;
}

.job-card-apply-hint {
    margin-top: 0.75rem;
    font-size: 0.82rem;
    color: var(--primary-color);
    font-weight: 600;
}

/* -- Application form -- */
.recruitment-form {
    background: var(--bg-white);
    border-radius: 1rem;
    padding: 2rem;
    box-shadow: var(--shadow-sm);
}

.selected-job-badge {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(37, 99, 235, 0.08);
    border: 1.5px solid var(--primary-color);
    border-radius: 0.5rem;
    padding: 0.6rem 1rem;
    margin-bottom: 1.25rem;
    font-weight: 600;
    color: var(--primary-color);
    font-size: 0.95rem;
}

.badge-clear {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--primary-color);
    font-size: 1rem;
    line-height: 1;
    padding: 0;
}

/* -- File upload -- */
.recruitment-uploads {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin: 1.25rem 0;
}

.upload-item label:first-child {
    display: block;
    font-weight: 600;
    margin-bottom: 0.4rem;
    color: var(--text-primary);
    font-size: 0.95rem;
}

.upload-hint {
    font-weight: 400;
    color: var(--text-secondary);
    font-size: 0.82rem;
}

.file-upload-wrapper {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.file-upload-wrapper input[type="file"] {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    overflow: hidden;
}

.file-upload-label {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.5rem 1.1rem;
    background: var(--primary-color);
    color: #fff;
    border-radius: 0.5rem;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 600;
    white-space: nowrap;
    transition: background 0.2s;
}

.file-upload-label:hover {
    background: var(--primary-dark, #1d4ed8);
}

.file-upload-name {
    font-size: 0.85rem;
    color: var(--text-secondary);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 200px;
}

.file-upload-name.has-file {
    color: var(--success-color, #16a34a);
    font-weight: 600;
}

.rodo-note {
    font-size: 0.78rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 1.25rem;
}

.btn-full {
    width: 100%;
    justify-content: center;
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
    .nav-toggle {
        display: flex;
    }

    .nav-menu {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--bg-white);
        flex-direction: column;
        gap: 0;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease;
        box-shadow: var(--shadow-md);
    }

    .nav-menu.active {
        max-height: 400px;
    }

    .nav-link {
        padding: 1rem;
        border-radius: 0;
    }

    .hero-title {
        font-size: 2rem;
    }

    .hero-subtitle {
        font-size: 1.2rem;
    }

    .contact-wrapper {
        grid-template-columns: 1fr;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .services-grid {
        grid-template-columns: 1fr;
    }

    .timeline {
        padding-left: 1rem;
    }

    .timeline-item {
        padding-left: 2rem;
    }

    .toast {
        right: 1rem;
        left: 1rem;
        max-width: none;
    }
    
    .machine-slideshow {
        height: 350px;
    }
    
    .machine-slide-content h3 {
        font-size: 1.3rem;
    }
    
    .machine-slide-content p {
        font-size: 0.9rem;
    }
    
    .portfolio-grid {
        grid-template-columns: 1fr;
    }
    
    .service-gallery {
        grid-template-columns: 1fr;
    }

    .recruitment-wrapper {
        grid-template-columns: 1fr;
    }

    .file-upload-name {
        max-width: 140px;
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }

    .hero-buttons {
        flex-direction: column;
    }

    .btn {
        width: 100%;
        text-align: center;
    }
}
