/* =============================== GLOBAL =============================== */
/* Resetowanie marginesów i ustawienie box-sizing */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    width: 100%;
}

body {
    font-family: 'Open Sans', Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f9f9f9;
    width: 100%;
    margin: 0;
    padding: 0;
}

/* Linki bez podkreśleń, dziedziczą kolor */
a {
    text-decoration: none;
    color: inherit;
}

/* =============================== HEADER =============================== */
header {
    min-height: 150px;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 40px;
    background-color: #fff;
    position: relative;
    z-index: 999;
}

.logo {
    display: flex;
    align-items: center;
}

.logo img {
    height: 130px;
    width: auto;
    display: block;
    object-fit: contain;
    min-width: 120px;
}

/* =============================== NAVIGATION =============================== */
nav {
    flex: 1;
    display: flex;
    justify-content: flex-end;
    align-items: center;
}

nav ul.menu {
    display: flex;
    list-style: none;
    gap: 20px;
    width: 100%;
    justify-content: flex-end;
}

nav ul.menu li a {
    display: block;
    padding: 10px 20px;
    font-weight: 600;
    font-size: 1rem;
    color: #1a1a1a;
    border-radius: 8px;
    transition: all 0.3s ease;
}

nav ul.menu li a:hover {
    background-color: #ff7f00;
    color: #fff;
}

/* =============================== RESPONSIVE MENU =============================== */
.menu-toggle {
    display: none;
    font-size: 1.8rem;
    cursor: pointer;
}

/* =============================== MOBILE RESPONSIVE HEADER =============================== */
@media screen and (max-width: 768px) {
    header {
        flex-direction: column;
        align-items: center;
        min-height: 120px;
        padding: 15px 20px;
    }

    .logo img {
        height: 120px;
    }

    .menu-toggle {
        display: block;
        position: absolute;
        right: 20px;
        top: 50%;
        transform: translateY(-50%);
    }

    nav ul.menu {
        flex-direction: column;
        max-height: 0;
        overflow: hidden;
        width: 100%;
        background-color: #fff;
        position: absolute;
        top: 100%;
        left: 0;
        box-shadow: 0 4px 12px rgba(0,0,0,0.1);
        transition: max-height 0.3s ease;
        padding: 0;
    }

    nav ul.menu.active {
        max-height: 500px;
        padding: 15px 0;
    }

    nav ul.menu li {
        width: 100%;
        margin: 5px 0;
        text-align: center;
    }

    nav ul.menu li a {
        font-size: 1.2rem;
    }
}

/* =============================== INTRO SECTION =============================== */
.intro-section {
    background-color: #fff;
    padding: 40px 20px;
    overflow: hidden;
    min-height: 300px;
    width: 100%;
}

/* FLEX DLA TEKSTU I ZDJĘCIA */
.wrapper.intro-flex {
    display: flex;
    align-items: flex-start;
    gap: 30px;
    flex-wrap: wrap;
}

/* TEKST */
.intro-text {
    flex: 1 1 500px;
    max-width: 600px;
    text-align: left;
}

.intro-text h1, #intro-title {
    font-size: 1.9rem;
    margin-bottom: 25px;
    color: #1a1a1a;
    line-height: 1.25;
}

/* RESPONSYWNOŚĆ TYTUŁU */
@media (max-width: 768px) {
    #intro-title {
        font-size: 1.6rem;
    }
}

.intro-text p {
    margin-bottom: 15px;
    font-size: 1.05rem;
    line-height: 1.7;
}

.intro-text ul {
    margin: 15px 0;
    padding-left: 20px;
}

.intro-text ul li {
    margin-bottom: 8px;
}

/* OBRAZEK OBOK TEKSTU */
.intro-image {
    flex: 1 1 400px;
    max-width: 620px;
}

.intro-image img {
    width: 100%;
    height: auto;
    border-radius: 12px;
    object-fit: cover;
}

/* AUTOMATYCZNY SLIDER */
.auto-slider {
    float: right;
    width: 40%;
    margin: 0 0 15px 15px;
    border-radius: 8px;
    aspect-ratio: 4 / 3;
    background: #eee;
    position: relative;
}

.auto-slider img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: absolute;
    top: 0;
    left: 0;
    opacity: 0;
    transition: opacity 0.6s ease-in-out;
}

.auto-slider img.active {
    opacity: 1;
    position: relative;
}

/* MOBILE RESPONSIVE */
@media (max-width: 900px) {
    .wrapper.intro-flex {
        flex-direction: column;
        gap: 20px;
    }

    .intro-image {
        order: 2;
    }

    .auto-slider {
        width: 100%;
        margin: 0 0 20px 0;
    }
}

/* =============================== SLIDER =============================== */
.inline-slider {
    position: relative;
    width: 100%;
    max-width: 600px;
    margin: 20px auto;
    overflow: hidden;
    border-radius: 8px;
    aspect-ratio: 16 / 9;
    background: #eee;
}

.inline-slider img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: none;
    transition: opacity 0.5s ease-in-out;
}

.inline-slider img.active {
    display: block;
    opacity: 1;
}

/* =============================== MAIN CONTENT =============================== */
.content {
    max-width: 900px;
    margin: 40px auto;
    padding: 0 20px;
    width: 100%;
}

.content h2 {
    margin: 30px 0 15px;
    color: #1a1a1a;
}

.content p {
    margin-bottom: 15px;
    font-size: 1.05rem;
    line-height: 1.7;
}

/* =============================== OFERTA GRID =============================== */
.oferta-section {
    padding: 60px 5%;
    text-align: center;
    background: #f9f9f9;
    width: 100%;
}

.oferta-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 25px;
    justify-content: center;
    max-width: 900px;
    margin: 40px auto;
}

@media (max-width: 768px) {
    .oferta-grid {
        grid-template-columns: 1fr;
    }
}

.oferta-item {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    padding: 15px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.oferta-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.oferta-item img {
    width: 100%;
    height: auto;
    object-fit: cover;
    border-radius: 12px;
    margin-bottom: 10px;
    aspect-ratio: 4 / 3;
    background: #eee;
}

/* =============================== FOOTER =============================== */
footer, .site-footer {
    width: 100%;
    background-color: #0b0b0b;
    color: #e6e6e6;
    padding: 28px 0;
    box-shadow: 0 -2px 8px rgba(0,0,0,0.08);
    position: relative;
    left: 0;
    bottom: 0;
}

footer .footer-inner,
.site-footer .footer-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

footer a, .site-footer a {
    color: #fff;
    margin: 0 5px;
    transition: color 0.3s ease;
}

footer a:hover, .site-footer a:hover {
    color: #ff7f00;
}

.footer-social {
    display: flex;
    gap: 12px;
    align-items: center;
    font-size: 14px;
    color: #cfcfcf;
}

.footer-social .social-link {
    color: #cfcfcf;
    text-decoration: none;
    font-weight: 600;
    padding: 0 6px;
}

.site-footer p {
    margin: 0;
    font-size: 13px;
    color: #bfbfbf;
}

/* =============================== CONTACT SECTION =============================== */
.contact-section {
    background-color: #fff;
    padding: 60px 20px;
    width: 100%;
}

.contact-container {
    display: flex;
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
    flex-wrap: wrap;
}

.company-info, .contact-form {
    flex: 1 1 400px;
    background: #f7f7f7;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.contact-form form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid #ccc;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.contact-form input:focus,
.contact-form textarea:focus {
    border-color: #ff7f00;
    box-shadow: 0 0 5px rgba(255,127,0,0.4);
    outline: none;
}

.contact-form button {
    padding: 12px 20px;
    font-size: 1rem;
    font-weight: 600;
    color: #fff;
    background-color: #ff7f00;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.3s ease;
}

.contact-form button:hover {
    background-color: #e76b00;
}

@media (max-width: 900px) {
    .contact-container {
        flex-direction: column;
        gap: 20px;
    }
}

/* =============================== LIGHTBOX =============================== */
.lightbox {
    display: none; /* default */
    justify-content: center;
    align-items: center;
    position: fixed;
    top:0;
    left:0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.8);
    z-index: 1000;
}

.lightbox-img {
    max-width: 90%;
    max-height: 90%;
    border-radius: 8px;
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 40px;
    color: #fff;
    cursor: pointer;
    user-select: none;
}

.lightbox-close:hover {
    color: #ff7f00;
}

/* =============================== ANTI CLS – MIN HEIGHTS =============================== */
section {
    min-height: 200px;
    width: 100%;
}

/* =============================== WRAPPERS =============================== */
.wrapper,
.container,
.footer-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    width: 100%;
}

/* =============================== SEKCJA SPRZĘT =============================== */
.sprzet-section {
    padding: 60px 5%;
    text-align: center;
    background: #fff;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 600px;
}

.sprzet-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
    margin: 40px 0;
    max-width: 1200px;
    width: 100%;
}

.vehicle-item {
    background: #f9f9f9;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    padding: 20px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    font-size: 0.9rem;
    line-height: 1.45;
    min-height: 360px;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
}

.vehicle-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.vehicle-item img {
    width: 100%;
    height: auto;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    border-radius: 10px;
    margin-bottom: 10px;
}

.vehicle-item h3 {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 10px;
    color: #1a1a1a;
}

.vehicle-item ul {
    text-align: left;
    margin-top: 10px;
    padding-left: 20px;
    flex-grow: 1;
}

.vehicle-item ul li {
    margin-bottom: 6px;
    font-size: 0.85rem;
    color: #444;
    line-height: 1.4;
}

/* ======== PAGINACJA ======== */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin-top: 20px;
}

.pagination button {
    background-color: #ff7f00;
    color: #fff;
    border: none;
    padding: 10px 16px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s ease;
    font-size: 0.9rem;
}

.pagination button:disabled {
    background-color: #ccc;
    color: #666;
    cursor: not-allowed;
}

.pagination button:hover:not(:disabled) {
    background-color: #e76b00;
}

/* ======== RESPONSYWNOŚĆ ======== */
@media (max-width: 768px) {
    .sprzet-grid {
        grid-template-columns: 1fr;
    }

    .sprzet-section {
        min-height: auto;
    }

    .vehicle-item {
        font-size: 0.8rem;
        padding: 16px;
        min-height: auto;
    }

    .vehicle-item h3 {
        font-size: 0.9rem;
    }

    .vehicle-item ul li {
        font-size: 0.8rem;
    }

    .pagination button {
        padding: 8px 12px;
        font-size: 0.85rem;
    }

    .vehicle-item ul {
        flex-grow: 0;
        margin-top: 8px;
    }
}
