/* --- Hero w stylu Apple: Rozbijacz Blura (Spotlight Effect) podążający za myszką --- */
.hero-spotlight {
    --mouse-x: 50%;
    --mouse-y: 50%;
}

.hero-modern {
    position: relative;
    background-color: #000;
    overflow: hidden;
    background: url('../img/hero.webp') center/cover no-repeat;
    min-height: 85vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #fff;
    padding: 120px 20px;
}

/* Pełnoekranowy blur z dynamiczną "dziurą" */
.hero-modern::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        180deg,
        rgba(0,0,0,0.5) 0%,
        rgba(0,0,0,0.7) 100%
    );
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    z-index: 1;

    /* Magia Maskowania - podpięta pod zmienne CSS kontrolowane przez skrypt z index.php */
    -webkit-mask-image: radial-gradient(circle 25vw at var(--mouse-x) var(--mouse-y), rgba(0,0,0,0.05) 0%, rgba(0,0,0,1) 80%);
    mask-image: radial-gradient(circle 25vw at var(--mouse-x) var(--mouse-y), rgba(0,0,0,0.05) 0%, rgba(0,0,0,1) 80%);
    
    /* Zapewnia brak rwania animacji podczas szybkiego ruchu myszką */
    transition: -webkit-mask-position 0.1s ease-out, mask-position 0.1s ease-out;
}

.hero-overlay {
    display: none;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
}

.hero-content h1 {
    font-size: 80px;
    line-height: 1.05;
    font-weight: 700;
    letter-spacing: -0.015em;
    margin-bottom: 20px;
    color: #fff;
    text-shadow: 0 4px 15px rgba(0,0,0,0.4);
}

.hero-content .lead {
    font-size: 28px;
    font-weight: 400;
    letter-spacing: 0.004em;
    margin-bottom: 40px;
    color: #fff;
    text-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

.hero-actions {
    display: flex;
    justify-content: center;
    gap: 16px;
    z-index: 2;
}

/* --- Sekcja Przyciski --- */
.btn {
    display: inline-block;
    padding: 12px 24px;
    border-radius: 980px;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: -0.01em;
    transition: transform 0.2s ease, background-color 0.2s ease;
    border: none;
    cursor: pointer;
    text-transform: uppercase;
    color: #fff !important;
}

.btn:active {
    transform: scale(0.96);
}

.btn-primary {
    background-color: var(--primary-color);
}

.btn-primary:hover {
    background-color: #333;
}

.btn-outline {
    background-color: rgba(255, 255, 255, 0.1);
    border: 2px solid #fff;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.btn-outline:hover {
    background-color: #fff;
    color: var(--primary-color) !important;
}

/* --- Sekcja O Nas --- */
.about-seo {
    padding: 140px 0;
    background-color: var(--bg-color);
}

.about-grid {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 60px;
}

.about-text {
    max-width: 700px;
}

.about-text h2 {
    font-size: 48px;
    line-height: 1.08349;
    font-weight: 600;
    letter-spacing: -0.003em;
    margin-bottom: 24px;
    color: #000;
}

.about-text p {
    font-size: 21px;
    line-height: 1.38105;
    font-weight: 400;
    letter-spacing: 0.011em;
    color: #1d1d1f;
    margin-bottom: 20px;
}

.about-text strong {
    color: #000;
}

.about-image {
    width: 100%;
    max-width: 980px;
}

.about-image img {
    width: 100%;
    border-radius: var(--border-radius);
    box-shadow: 0 20px 40px rgba(0,0,0,0.08);
}

/* --- Sekcja Oferta (Karty) --- */
.home-products {
    padding: 100px 0 140px;
    background-color: #fff;
}

.section-header {
    text-align: center;
    margin-bottom: 80px;
}

.section-header h2 {
    font-size: 48px;
    line-height: 1.08349;
    letter-spacing: -0.003em;
    margin-bottom: 16px;
    color: #000;
}

.section-header p {
    font-size: 21px;
    color: #1d1d1f;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    padding: 0 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.product-card {
    background-color: var(--bg-color);
    border-radius: var(--border-radius);
    overflow: hidden;
    transition: transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: scale(1.02);
}

.card-image {
    width: 100%;
    aspect-ratio: 4/3;
    overflow: hidden;
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.card-content {
    padding: 40px 30px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.card-content h3 {
    font-size: 28px;
    margin-bottom: 12px;
    color: #000;
}

.card-content p {
    font-size: 17px;
    color: #1d1d1f;
    margin-bottom: 24px;
    flex-grow: 1;
}

.link-arrow {
    font-size: 17px;
    font-weight: 600;
    color: var(--accent-color);
    align-self: flex-start;
}

.link-arrow:hover {
    text-decoration: underline;
}

/* --- Sekcja Zalety --- */
.why-us-modern {
    padding: 140px 0;
    background-color: #000;
    color: #fff;
    text-align: center;
}

.why-us-modern .section-header h2 {
    color: #fff;
}

.why-us-modern .section-header p {
    color: #fff;
}

.benefits-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 40px;
    max-width: 980px;
    margin: 0 auto;
    padding: 0 20px;
    text-align: left;
}

.benefit-box {
    padding: 0;
}

.benefit-number {
    font-size: 17px;
    font-weight: 600;
    color: #fff;
    margin-bottom: 16px;
    display: block;
}

.benefit-box h4 {
    font-size: 21px;
    font-weight: 600;
    color: #fff;
    margin-bottom: 12px;
}

.benefit-box p {
    font-size: 17px;
    color: #fff;
    line-height: 1.47059;
}

/* --- Sekcja CTA (Call to Action) --- */
.cta-section {
    padding: 120px 0;
    background-color: var(--bg-color);
    text-align: center;
}

.cta-content {
    max-width: 800px;
    margin: 0 auto;
    background-color: #fff;
    padding: 80px 40px;
    border-radius: 24px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.04);
}

.cta-content h2 {
    font-size: 42px;
    line-height: 1.1;
    letter-spacing: -0.003em;
    margin-bottom: 20px;
    color: #000;
}

.cta-content p {
    font-size: 21px;
    color: #1d1d1f;
    margin-bottom: 40px;
}

.cta-btn {
    font-size: 16px;
    padding: 16px 36px;
}

/* --- Responsywność Mobile --- */
@media (max-width: 1024px) {
    .hero-content h1 { font-size: 64px; }
    .about-text h2, .section-header h2 { font-size: 40px; }
}

@media (max-width: 768px) {
    .hero-modern {
        padding: 80px 20px;
        min-height: 70vh;
        /* NA MOBILE: Włączamy czytelny, prosty gradient zamiast szkła */
        background: linear-gradient(rgba(0,0,0,0.4), rgba(0,0,0,0.6)), url('../img/hero.webp') center/cover no-repeat;
    }
    
    /* NA MOBILE: Całkowicie ukrywamy skomplikowany blur i maskowanie */
    .hero-modern::before {
        display: none;
    }
    
    .hero-content h1 {
        font-size: 48px;
    }
    
    .hero-content .lead {
        font-size: 21px;
    }
    
    .hero-actions {
        flex-direction: column;
        width: 100%;
        max-width: 300px;
        margin: 0 auto;
    }
    
    .btn-primary, .btn-outline {
        text-align: center;
        width: 100%;
    }
    
    .about-seo {
        padding: 80px 0;
    }
    
    .about-text h2, .section-header h2 {
        font-size: 32px;
    }
    
    .about-text p {
        font-size: 17px;
    }
    
    .home-products {
        padding: 80px 0;
    }
    
    .why-us-modern {
        padding: 80px 0;
    }
    
    .benefits-grid {
        grid-template-columns: 1fr;
        gap: 40px;
        text-align: center;
    }
    
    .benefit-number {
        margin-bottom: 8px;
    }
    
    .cta-section {
        padding: 80px 20px;
    }
    
    .cta-content {
        padding: 40px 20px;
    }
    
    .cta-content h2 {
        font-size: 32px;
    }
    
    .cta-content p {
        font-size: 17px;
    }
}