/* --- GŁÓWNE STYLE (style.css) --- */
:root {
    --bg-body: #F4F4FC;
    --bg-card: #FFFFFF;
    --text-main: #1A1A2E;
    --text-muted: #555566;
    --primary: #7000FF; 
    --primary-dark: #5A00CC;
    --accent: #00D2FF;
    --gradient: linear-gradient(135deg, #7000FF 0%, #9D50BB 100%);
    --shadow-soft: 0 10px 40px -10px rgba(112, 0, 255, 0.15);
    --shadow-hard: 0 15px 35px rgba(0, 0, 0, 0.1);
    --radius: 16px;
    --container-width: 1100px;
}

html { scroll-behavior: smooth; }
* { box-sizing: border-box; margin: 0; padding: 0; }

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background-color: var(--bg-body);
    color: var(--text-main);
    line-height: 1.6;
    font-size: 16px;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

h1, h2, h3, h4 { font-weight: 800; color: #1A1A2E; letter-spacing: -0.5px; line-height: 1.2; }

/* TYPOGRAFIA RWD */
h1 { font-size: clamp(2rem, 5vw, 3.5rem); margin-bottom: 1rem; }
h2 { font-size: clamp(1.8rem, 4vw, 2.5rem); margin-bottom: 1rem; }
h3 { font-size: 1.3rem; margin-bottom: 0.5rem; }

p { margin-bottom: 1.5rem; color: var(--text-muted); font-weight: 400; max-width: 700px; margin-left: auto; margin-right: auto; }

.highlight { 
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    font-weight: 800;
}

.section-subtitle {
    font-weight: 700; 
    color: var(--primary); 
    letter-spacing: 1px; 
    margin-bottom: 1.5rem; 
    text-transform: uppercase;
}

.container { max-width: var(--container-width); margin: 0 auto; padding: 0 20px; }
.section-padding { padding: 80px 0; }
.text-center { text-align: center; }
.text-left { text-align: left; }

/* BUTTONY */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 10px;
    background: var(--gradient);
    color: #fff;
    padding: 20px 40px;
    text-decoration: none;
    font-weight: 700;
    font-size: 1.1rem;
    border-radius: 50px;
    box-shadow: 0 10px 25px rgba(112, 0, 255, 0.3);
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.btn:hover { transform: translateY(-3px) scale(1.02); box-shadow: 0 20px 40px rgba(112, 0, 255, 0.4); }
.btn-full { width: 100%; max-width: 400px; }

/* STYL DLA NIEAKTYWNEGO PRZYCISKU (DISABLED) */
.btn.disabled {
    background: #cccccc; /* Szare tło */
    color: #666666;      /* Ciemniejszy szary tekst */
    box-shadow: none;    /* Brak cienia */
    cursor: not-allowed; /* Kursor zakazu */
    pointer-events: none; /* KLUCZOWE: Blokuje kliknięcie w link */
    transform: none;     /* Brak animacji */
}

/* BACK TO TOP */
#backToTop {
    position: fixed; bottom: 30px; right: 30px; width: 50px; height: 50px;
    background: var(--primary); color: #fff; border: none; border-radius: 50%;
    font-size: 24px; cursor: pointer; box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    opacity: 0; visibility: hidden; transition: all 0.3s ease; z-index: 999;
    display: flex; align-items: center; justify-content: center;
}
#backToTop.show { opacity: 1; visibility: visible; }
#backToTop:hover { background: var(--primary-dark); transform: translateY(-5px); }

/* HERO */
.hero { 
    min-height: 70vh;
    display: flex; align-items: center; justify-content: center;
    text-align: center; background: #fff; padding: 120px 20px 60px;
    border-bottom: 1px solid #eee;
}
.hero-content { max-width: 900px; animation: fadeIn 1s ease-out; }

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* --- SLIDER PRZED/PO --- */
.comparison-wrapper {
    position: relative; border-radius: var(--radius);
    overflow: hidden; box-shadow: var(--shadow-hard);
    border: 4px solid #fff; 
    background: #fff; 
    width: 100%; max-width: 800px; margin: 0 auto;
}

.comparison-slider { 
    position: relative; 
    width: 100%; 
    overflow: hidden; 
    touch-action: pan-y; 
    cursor: col-resize;
    line-height: 0; 
}

/* Główny obrazek (PO) - Domyślne ustawienie "Naturalne" */
.comparison-slider img.img-after { 
    width: 100%; 
    height: auto; 
    display: block; 
    user-select: none; 
    pointer-events: none;
}

/* Ruchoma ramka (PRZED) */
.img-before {
    position: absolute; top: 0; left: 0; 
    width: 50%; 
    height: 100%;
    border-right: 3px solid #fff; 
    overflow: hidden; 
    z-index: 2; 
    will-change: width;
    background: #f4f4f4; 
}

/* Obrazek wewnątrz PRZED */
.img-before img {
    height: 100% !important; 
    width: auto !important;
    max-width: none !important;
    display: block;
    user-select: none;
    pointer-events: none;
}

.slider-handle {
    position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
    width: 40px; height: 40px; background: #fff; border-radius: 50%;
    z-index: 10; cursor: col-resize; box-shadow: 0 0 10px rgba(0,0,0,0.5);
    display: flex; align-items: center; justify-content: center;
    color: var(--primary); font-weight: bold; will-change: left; pointer-events: none;
}

/* STYL ETYKIET PRZED/PO */
.label-badge {
    position: absolute; top: 20px; 
    padding: 8px 18px; 
    background: rgba(0,0,0,0.6); color: #fff; border-radius: 20px;
    font-size: 0.8rem; font-weight: 700; z-index: 3; pointer-events: none;
}
.label-before { left: 20px; }
.label-after { right: 20px; }

/* OPIS POD SLIDEREM */
.example-desc {
    padding: 15px; 
    font-size: 0.9rem; 
    background: #fff; 
    margin-bottom: 0; 
    border-top: 1px solid #eee;
}

/* GRID DLA PRZYKŁADÓW */
.examples-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
    margin-top: 40px;
}

/* --- NOWA SEKCJA: WYRÓWNANIE ZDJĘĆ W SIATCE --- */
/* Te style dotyczą TYLKO małych sliderów w sekcji "Ratujemy..." */

.examples-grid .comparison-slider {
    /* Wymuszamy proporcje 4:3 (szerokość : wysokość), aby kafelki były równe */
    aspect-ratio: 4 / 3;
    width: 100%;
}

/* Dopasowanie zdjęć wewnątrz siatki (cropowanie do ramki) */
.examples-grid .comparison-slider img.img-after,
.examples-grid .comparison-slider .img-before img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important; /* Wypełnij ramkę przycinając nadmiar */
    display: block;
}

/* --- KONIEC SEKCJI WYRÓWNANIA --- */


/* STEPS */
.steps-grid { display: grid; grid-template-columns: 1fr; gap: 30px; margin-top: 3rem; }
.step-card { background: #fff; padding: 2rem; border-radius: var(--radius); box-shadow: var(--shadow-soft); text-align: left; position: relative; overflow: hidden; border-top: 4px solid var(--primary); }
.step-number { font-size: 4rem; font-weight: 900; color: #F0F0F5; position: absolute; top: -10px; right: 10px; z-index: 0; }
.step-content { position: relative; z-index: 1; }

/* VIDEO */
.video-container {
    max-width: 800px; margin: 60px auto 0; text-align: center;
}
video {
    width: 100%; border-radius: var(--radius); box-shadow: var(--shadow-hard); display: block;
}

/* OPINIE (TESTIMONIALS) */
.testimonials-grid { display: grid; grid-template-columns: 1fr; gap: 20px; margin-top: 2rem; }
.testimonial-card { background: #fff; padding: 25px; border-radius: 12px; text-align: left; box-shadow: var(--shadow-soft); }
.stars { color: #FFC107; font-size: 1.2rem; margin-bottom: 10px; }
.client-name { font-weight: 700; margin-top: 10px; font-size: 0.9rem; color: var(--primary); }

/* FORMULARZ I KONTAKT */
.form-section { background: var(--gradient); color: #fff; padding: 80px 0; }
.form-box { 
    background: #fff; color: var(--text-main); padding: 40px; 
    border-radius: var(--radius); box-shadow: 0 20px 50px rgba(0,0,0,0.2); 
    max-width: 600px; margin: 0 auto; 
}

/* STYLE DLA KOPIOWANIA MAILA */
.email-copy-wrapper {
    background: #F4F4FC;
    padding: 20px;
    border-radius: 12px;
    border: 1px dashed var(--primary);
    margin-top: 20px;
}
.email-copy-box {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}
.email-copy-box strong {
    font-size: 1.1rem;
    color: var(--text-main);
    word-break: break-all;
}
.btn-copy {
    background: var(--primary);
    color: #fff;
    border: none;
    padding: 6px 15px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.85rem;
    transition: 0.3s;
}
.btn-copy:hover { background: var(--primary-dark); }
#copySuccess {
    font-size: 0.85rem;
    color: #00b894;
    font-weight: 700;
    margin-top: 10px;
    opacity: 0;
    transition: opacity 0.3s ease;
    margin-bottom: 0;
}

/* FOOTER */
footer { background: #1A1A2E; color: #aaa; padding: 60px 0 20px; margin-top: auto; }
.footer-content { display: flex; flex-direction: column; gap: 20px; text-align: center; justify-content: space-between; align-items: center; }
.footer-links a { color: #fff; text-decoration: none; margin: 0 10px; font-weight: 600; font-size: 0.9rem; }

/* COOKIE BANNER */
.cookie-banner {
    position: fixed;
    bottom: -100%; /* Domyślnie schowany */
    left: 0;
    width: 100%;
    background: #1A1A2E; 
    color: #fff;
    padding: 20px;
    box-shadow: 0 -5px 20px rgba(0,0,0,0.2);
    z-index: 9999;
    transition: bottom 0.5s ease-in-out;
}
.cookie-banner.active { bottom: 0; }
.cookie-content {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    text-align: center;
}
.cookie-buttons { display: flex; gap: 20px; align-items: center; }
.cookie-link { color: #aaa; text-decoration: underline; font-size: 0.9rem; }
.cookie-link:hover { color: #fff; }
.btn-cookie {
    background: var(--primary); color: #fff; border: none; padding: 10px 20px;
    border-radius: 50px; font-weight: 700; cursor: pointer; transition: 0.3s;
}
.btn-cookie:hover { background: var(--primary-dark); }

/* STYLE DLA PODSTRONY PRAWNEJ (prawo.html) */
.legal-page { background: #fff; padding: 100px 0; color: var(--text-main); }
.legal-content h1 { margin-bottom: 40px; text-align: center; }
.legal-content h2 { margin-top: 40px; margin-bottom: 20px; border-bottom: 2px solid #eee; padding-bottom: 10px; font-size: 1.5rem; }
.legal-content p { margin-bottom: 15px; text-align: justify; max-width: 100%; }
.legal-content ul { margin-bottom: 20px; padding-left: 20px; }
.legal-content li { margin-bottom: 10px; color: var(--text-muted); }

@media (min-width: 768px) {
    .steps-grid { grid-template-columns: repeat(3, 1fr); }
    .testimonials-grid { grid-template-columns: repeat(3, 1fr); }
    .footer-content { flex-direction: row; text-align: left; }
    .cookie-content { flex-direction: row; justify-content: space-between; text-align: left; }
}