:root {
    --primary: #E6333A;
    --dark: #111111;
    --light: #f4f4f4; 
    --white: #ffffff;
    --grey: #888888;
    --card-bg: #1a1a1a;
    --font-head: 'Montserrat', sans-serif;
    --font-body: 'Open Sans', sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { 
    scroll-behavior: smooth; 
    scroll-padding-top: 80px; 
}

body { font-family: var(--font-body); background-color: var(--dark); color: var(--dark); line-height: 1.6; }
img { max-width: 100%; display: block; }

/* --- STYLE OGÓLNE --- */
.container { max-width: 1400px; margin: 0 auto; padding: 0 5%; }
.section { padding: 80px 0; background-color: var(--white); }
.bg-dark { background-color: var(--dark); color: var(--white); }
.bg-light { background-color: var(--light); color: var(--dark); } 
.text-white { color: var(--white); }
.text-gray { color: var(--grey); }

h1, h2, h3 { font-family: var(--font-head); font-weight: 700; }
.section-title { font-size: clamp(2rem, 4vw, 3rem); margin-bottom: 20px; position: relative; display: inline-block; color: var(--dark); }
.bg-dark .section-title { color: var(--white); }
.section-title::after { content: ''; display: block; width: 60px; height: 4px; background: var(--primary); margin-top: 10px; }
.highlight { color: var(--primary); }

/* --- PRZYCISKI --- */
.btn { padding: 12px 30px; display: inline-block; text-decoration: none; font-weight: 700; border-radius: 50px; transition: 0.3s; border: 2px solid transparent; cursor: pointer; }
.btn-primary { background: var(--primary); color: var(--white); border-color: var(--primary); }
.btn-primary:hover { background: transparent; color: var(--primary); }
.btn-outline { border-color: var(--white); color: var(--white); }
.btn-outline:hover { background: var(--white); color: var(--dark); }
.full-width { width: 100%; border: none; }
.mt-30 { margin-top: 30px; }

/* --- NAWIGACJA (PRZEZROCZYSTA -> CZARNA) --- */
.navbar { 
    position: fixed; 
    top: 0; 
    left: 0; 
    width: 100%; 
    height: 80px; 
    z-index: 1000; 
    display: flex; 
    align-items: center; 
    
    /* Start: przezroczyste */
    background: transparent; 
    transition: background 0.4s ease, box-shadow 0.4s ease; 
}

/* Po scrollu: czarne */
.navbar.scrolled { 
    background: rgba(0,0,0,0.95); 
    box-shadow: 0 2px 10px rgba(0,0,0,0.3); 
}

.nav-container { display: flex; justify-content: space-between; align-items: center; width: 100%; }

.logo { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.logo img { height: 45px; }
.logo-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-main { color: var(--white); font-weight: 900; font-family: var(--font-head); font-size: 1.2rem; }
.brand-sub { color: var(--primary); font-size: 0.7rem; text-transform: uppercase; font-weight: 700; }

.nav-menu { display: flex; list-style: none; gap: 30px; align-items: center; }
.nav-link { color: var(--white); text-decoration: none; font-weight: 600; transition: 0.3s; }
.nav-link:hover { color: var(--primary); }
.btn-contact { background: var(--primary); padding: 8px 20px; border-radius: 4px; border: 1px solid var(--primary); }
.btn-contact:hover { background: transparent; color: var(--white); }

.hamburger { display: none; cursor: pointer; }
.bar { display: block; width: 25px; height: 3px; background: var(--white); margin: 5px; transition: 0.3s; }

/* --- HERO --- */
.hero { height: 100vh; background: url('images/strona-glowna.png') center/cover no-repeat; display: flex; align-items: center; position: relative; color: var(--white); padding-top: 80px; }
.hero-overlay { position: absolute; inset: 0; background: rgba(0,0,0,0.6); }
.hero-content { position: relative; z-index: 2; width: 100%; max-width: 900px; }
.hero h1 { font-size: clamp(2.5rem, 6vw, 4rem); margin-bottom: 20px; line-height: 1.1; }
.hero p { font-size: clamp(1rem, 2vw, 1.2rem); margin-bottom: 30px; color: #ddd; }
.hero-btns { display: flex; gap: 20px; }

/* --- O NAS --- */
.split-layout { display: flex; align-items: center; gap: 50px; }
.split-text { flex: 1; }
.split-image { flex: 1; }
.split-image img { border-radius: 8px; box-shadow: 0 15px 30px rgba(0,0,0,0.1); }
.features-list { list-style: none; margin-top: 20px; }
.features-list li { margin-bottom: 10px; display: flex; gap: 10px; align-items: center; font-weight: 600; }
.features-list i { color: var(--primary); }

/* --- OFERTA --- */
.offer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 25px; margin-top: 50px; }
.offer-card { background: var(--card-bg); border-radius: 8px; overflow: hidden; transition: 0.3s ease; border-bottom: 4px solid transparent; position: relative; display: flex; flex-direction: column; }
.offer-card:hover { transform: translateY(-5px); box-shadow: 0 15px 30px rgba(0,0,0,0.5); border-bottom-color: var(--primary); }

.card-img-wrapper { height: 220px; overflow: hidden; }
.card-img-wrapper img { width: 100%; height: 100%; object-fit: cover; transition: 0.5s ease; }
.offer-card:hover .card-img-wrapper img { transform: scale(1.1); }

.card-body { padding: 15px; display: flex; flex-direction: column; flex-grow: 1; }
.card-body h3 { color: var(--white); font-size: 1.15rem; margin-bottom: 10px; min-height: 2.4rem; }
.card-body p { color: #aaa; font-size: 0.85rem; line-height: 1.6; margin-bottom: 20px; }
.card-link { text-decoration: none; color: var(--primary); font-weight: 700; font-size: 0.9rem; text-transform: uppercase; transition: 0.3s; letter-spacing: 1px; margin-top: auto; }
.card-link:hover { color: var(--white); padding-left: 5px; }
.stretched-link::after { content: ""; position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 1; cursor: pointer; }

/* --- KONTAKT (JASNA SEKCJA, BIAŁE KARTY) --- */
.contact-layout-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr;
    gap: 30px;
    align-items: start;
}

.contact-card {
    background: var(--white);
    padding: 40px;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08); 
    border: 1px solid #eaeaea;
}

.contact-heading {
    color: var(--primary);
    font-size: 1.8rem;
    margin-bottom: 15px;
}
.contact-desc {
    margin-bottom: 30px;
    color: #555; 
}

/* Formularz */
.new-contact-form .form-group {
    margin-bottom: 20px;
}
.new-contact-form input,
.new-contact-form textarea {
    width: 100%;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    background-color: #fafafa; 
    font-family: inherit;
    font-size: 0.95rem;
    transition: 0.3s;
    color: #333;
}
.new-contact-form input:focus,
.new-contact-form textarea:focus {
    outline: none;
    border-color: var(--primary);
    background-color: #fff;
    box-shadow: 0 0 0 4px rgba(230, 51, 58, 0.1);
}
.btn-submit {
    background-color: var(--primary);
    color: white;
    border: none;
    padding: 15px 30px;
    font-size: 1rem;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 700;
}
.btn-submit:hover {
    background-color: #c42b30;
}

.contact-sidebar {
    display: flex;
    flex-direction: column;
    gap: 30px;
}
.contact-subheading {
    color: var(--primary);
    font-size: 1.4rem;
    margin-bottom: 20px;
}
.info-row {
    margin-bottom: 15px;
    font-size: 1rem;
    color: #333;
    line-height: 1.6;
}
.info-row strong {
    color: var(--dark);
    font-weight: 700;
    margin-right: 5px;
}

/* MAPA (Kolorowa, bez filtrów) */
.map-card-wrapper {
    padding: 0;
    overflow: hidden;
    height: 300px;
    border: 1px solid #ddd;
}

.map-card-wrapper iframe {
    width: 100%;
    height: 100%;
    display: block;
}

/* --- STYLE DLA PODSTRONY DRUK OFFSETOWY I CYFROWY --- */
.service-hero {
    padding-top: 140px;
    padding-bottom: 80px;
    background-color: var(--white);
    min-height: 70vh;
    display: flex;
    align-items: center;
}

.service-hero-content {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr; 
    gap: 60px;
    align-items: center;
}

.service-tag {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--grey);
    letter-spacing: 2px;
    margin-bottom: 15px;
}

.service-hero h1 {
    font-size: 3.5rem;
    line-height: 1.1;
    color: var(--dark);
    margin-bottom: 25px;
}

.service-desc {
    font-size: 1.1rem;
    color: #555;
    margin-bottom: 30px;
    max-width: 95%;
}

.service-img-col img {
    border-radius: 20px 0 20px 0;
    box-shadow: 20px 20px 0px var(--light);
    width: 100%;
    display: block;
}

/* --- STYL SIATKI PRODUKTÓW W HERO --- */
.products-mini-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin-top: 25px;
}

.product-item {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(244, 244, 244, 0.7);
    padding: 12px 15px;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--dark);
    border-left: 3px solid var(--primary);
    transition: all 0.3s ease;
}

.product-item:hover {
    background: var(--white);
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    transform: translateX(5px);
}

.product-item i {
    color: var(--primary);
    font-size: 1rem;
    width: 20px;
    text-align: center;
}

.photo-gallery-section {
    background-color: var(--light);
    padding: 80px 0;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.gallery-item {
    height: 300px;
    border-radius: 15px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
}

.gallery-item:hover {
    transform: translateY(-5px);
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.gallery-item:hover img {
    transform: scale(1.1);
}

.split-layout {
    display: flex;
    align-items: center;
    gap: 60px;
}

.split-text { flex: 1; }
.split-image { flex: 1; }

.split-image img {
    width: 100%;
    border-radius: 15px;
    box-shadow: 0 15px 30px rgba(0,0,0,0.1);
}




/* --- NAWIGACJA NA PODSTRONACH --- */
.navbar.static-black {
    background: rgba(0,0,0,0.95);
    box-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

/* --- STOPKA --- */
.footer { background: var(--dark); color: #666; padding: 30px 0; text-align: center; border-top: 1px solid #222; }
.footer-content { display: flex; justify-content: space-between; align-items: center; }
.socials a { color: var(--white); margin-left: 15px; font-size: 1.2rem; transition: 0.3s; }
.socials a:hover { color: var(--primary); }

/* --- NOWE STYLE DLA KATALOGÓW (GRID) --- */
.catalogs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); 
    gap: 40px;
    padding: 10px;
}

.catalog-card {
    text-decoration: none;
    background: transparent;
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.catalog-cover {
    position: relative;
    width: 100%;
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 
        0 4px 6px rgba(0,0,0,0.1), 
        5px 5px 15px rgba(0,0,0,0.15); 
    transition: all 0.4s ease;
    aspect-ratio: 210/297; 
}

.catalog-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.catalog-overlay {
    position: absolute;
    inset: 0;
    background: rgba(17, 17, 17, 0.7);
    color: var(--white);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.catalog-overlay i {
    font-size: 2rem;
    color: var(--primary);
}

.catalog-info {
    text-align: center;
    margin-top: 15px;
}

.catalog-info h3 {
    font-size: 1.1rem;
    color: var(--dark);
    margin-bottom: 5px;
    font-weight: 700;
}

.catalog-info p {
    font-size: 0.85rem;
    color: var(--grey);
    margin: 0;
}

/* EFEKTY HOVER */
.catalog-card:hover .catalog-cover {
    transform: translateY(-10px); 
    box-shadow: 
        0 15px 25px rgba(0,0,0,0.2), 
        10px 10px 20px rgba(0,0,0,0.1); 
}

.catalog-card:hover .catalog-overlay {
    opacity: 1; 
}

.catalog-card:hover .catalog-info h3 {
    color: var(--primary); 
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.feature-box {
    background: var(--white);
    padding: 35px 25px;
    border-radius: 10px;
    text-align: center;
    border: 1px solid #eee;
    transition: all 0.3s ease;
    height: 100%; /* Żeby wszystkie kafelki były równe */
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* Efekt najechania */
.feature-box:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.08);
    border-color: var(--primary);
}

/* Ikona */
.feature-box i {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 20px;
    display: inline-block;
    transition: transform 0.3s;
}

.feature-box:hover i {
    transform: scale(1.1); /* Ikona lekko rośnie po najechaniu */
}

/* Tytuł kafelka */
.feature-box h3 {
    font-size: 1.2rem;
    margin-bottom: 15px;
    color: var(--dark);
    font-weight: 700;
}

/* Tekst opisu */
.feature-box p {
    font-size: 0.95rem;
    color: #666;
    line-height: 1.5;
    margin: 0;
}

/* --- STYLE DLA SEKCJI MATERIAŁY (GRAWEROWANIE) --- */
.materials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    gap: 30px;
    justify-content: center;
}

.material-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    transition: transform 0.3s ease;
}

.material-item:hover {
    transform: translateY(-5px);
}

.mat-img {
    width: 100px;
    height: 100px;
    border-radius: 50%; 
    overflow: hidden;
    margin-bottom: 15px;
    border: 3px solid #eee;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mat-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.material-item p {
    font-weight: 700;
    color: var(--dark);
    font-size: 0.95rem;
}

/* Wyróżnienie po najechaniu */
.material-item:hover .mat-img {
    border-color: var(--primary);
}

.external-link-box {
    background-color: #f7f7f7;
    border-left: 4px solid #ffcc00; 
    padding: 20px 25px;
    margin: 30px 0;
}

.external-link-box h4 {
    font-size: 1.1rem;
    color: var(--dark);
    margin-bottom: 5px;
    font-weight: 700;
}

.external-link-box p {
    font-size: 0.9rem;
    color: #666;
    margin-bottom: 5px !important;
}

.external-link-box a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 700;
    font-size: 1rem;
    transition: 0.3s;
}

.external-link-box a:hover {
    text-decoration: underline;
    opacity: 0.8;
}

/* Poprawka znikającego linku w białych kafelkach */
.feature-box .card-link:hover {
    color: var(--dark); 
    padding-left: 5px;  
}


@media (max-width: 992px) {
    /* Typografia i Layout Hero */
    .hero h1, 
    .service-hero h1 { 
        font-size: 2.5rem; 
    }

    .service-hero {
        padding-top: 100px;
        padding-bottom: 50px;
    }

    .service-hero-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 40px;
    }

    .service-img-col {
        order: -1; 
    }

    .service-desc { 
        margin: 0 auto 20px auto; 
    }

    /* Układy siatkowe (Grids) */
    .offer-grid,
    .products-mini-grid,
    .gallery-grid,
    .features-grid { 
        grid-template-columns: repeat(2, 1fr); 
    }

    .gallery-grid {
        gap: 20px;
    }

    /* Sekcje typu Split (Tekst + Obraz) */
    .split-layout, 
    .split-layout:nth-child(even) { 
        flex-direction: column !important; 
        gap: 40px;
        text-align: center;
    }

    .split-text, 
    .split-image { 
        width: 100%; 
    }

    .split-image img { 
        max-width: 500px; 
        margin: 0 auto 20px auto; 
    }

    .features-list {
        display: inline-block;
        text-align: left;
    }

    /* Kontakt */
    .contact-layout-grid {
        grid-template-columns: 1fr;
    }

    .contact-sidebar {
        flex-direction: column-reverse;
    }

    .contact-card {
        padding: 30px 20px;
    }
}

@media (max-width: 768px) {
    /* Nawigacja (Hamburger) */
    .hamburger { 
        display: block; 
    }

    .nav-menu { 
        position: fixed; 
        left: -100%; 
        top: 80px; 
        width: 100%; 
        height: calc(100vh - 80px); /* Pełna wysokość pod navbar */
        background: rgba(0, 0, 0, 0.98); 
        flex-direction: column; 
        padding: 40px 0; 
        transition: 0.4s cubic-bezier(0.4, 0, 0.2, 1); 
        z-index: 1000;
        justify-content: flex-start;
        overflow-y: auto;
    }

    .nav-menu.active { 
        left: 0; 
    }

    .nav-menu li {
        width: 100%;
        text-align: center;
        margin: 15px 0;
    }

    /* Animacja ikonki hamburgera */
    .hamburger.active .bar:nth-child(2) { opacity: 0; }
    .hamburger.active .bar:nth-child(1) { transform: translateY(8px) rotate(45deg); }
    .hamburger.active .bar:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

    /* Nagłówki i Przyciski */
    .page-header h1 {
        font-size: 2rem;
    }

    .hero-btns { 
        display: flex;
        flex-direction: column; 
        gap: 15px;
        align-items: center;
    }

    .hero-btns .btn {
        width: 100%;
        max-width: 300px;
    }

    /* Katalogi i Siatki */
    .offer-grid { 
        grid-template-columns: 1fr; 
    }

    .catalogs-grid {
        grid-template-columns: repeat(2, 1fr); 
        gap: 20px;
    }
    
    .footer-content { 
        flex-direction: column; 
        gap: 15px; 
        text-align: center;
    }
}

@media (max-width: 600px) {
    .service-hero h1 { 
        font-size: 2rem; 
    }
    
    .products-mini-grid,
    .gallery-grid,
    .features-grid {
        grid-template-columns: 1fr; 
    }

    .gallery-item {
        height: 250px;
    }

    .feature-box {
        padding: 25px 20px;
    }
}

@media (max-width: 480px) {
    .materials-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }

    .catalog-info h3 { 
        font-size: 0.95rem; 
    }

    .brand-main {
        font-size: 1.1rem;
    }
    
    .brand-sub {
        font-size: 0.6rem;
    }
}