/* === ZMIENNE GLOBALNE I PODSTAWOWE STYLE === */
:root {
    --brand-navy: #0A2540;
    --brand-blue: #0077B6;
    --brand-yellow: #FCA311;
    --dark-text: #32325D;
    --medium-gray: #6B7280;
    --light-gray: #F6F9FC;
    --white: #FFFFFF;
    --font-sans: 'Lato', sans-serif;
    --font-serif: 'EB Garamond', serif;
}

*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--light-gray);
    color: var(--dark-text);
    font-family: var(--font-sans);
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    text-decoration: none;
    color: inherit;
}

.section-subtitle {
    font-size: 0.875rem;
    font-weight: bold;
    text-transform: uppercase;
    color: var(--brand-blue);
    letter-spacing: 0.1em;
    margin-bottom: 0.5rem;
}

.section-title {
    font-family: var(--font-serif);
    font-size: 2.25rem;
    font-weight: bold;
    color: var(--dark-text);
    margin-bottom: 1.5rem;
}

.text-center {
    text-align: center;
}

/* === NAGŁÓWEK === */
#header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    transition: background-color 0.3s, box-shadow 0.3s, color 0.3s;
}

#header.scrolled {
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(5px);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0; 
}

.logo {
    font-family: var(--font-serif);
    font-size: 1.1rem; 
    font-weight: bold;
    color: var(--white);
    transition: color 0.3s;
    line-height: 1.2; 
}

#header.scrolled .logo {
    color: var(--brand-navy);
}

.desktop-nav {
    display: none;
    align-items: center;
    gap: 1.5rem;
}

.desktop-nav a {
    font-weight: 600;
    color: #E5E7EB; /* light gray */
    transition: color 0.3s;
}

.desktop-nav a:hover { color: var(--brand-yellow); }

#header.scrolled .desktop-nav a { color: var(--dark-text); }
#header.scrolled .desktop-nav a:hover { color: var(--brand-blue); }

.desktop-nav .social-icons {
    display: flex;
    gap: 1rem;
    padding-left: 1rem;
    border-left: 1px solid rgba(128, 128, 128, 0.3);
}
.desktop-nav .social-icons a { font-size: 1.25rem; }

.cta-button-header { display: none; }

.mobile-menu-button {
    background: none;
    border: none;
    color: var(--white);
    font-size: 1.5rem;
    cursor: pointer;
    z-index: 1001;
}

#header.scrolled .mobile-menu-button {
    color: var(--dark-text);
}

.mobile-menu {
    display: none;
    background-color: var(--white);
    border-radius: 0.5rem;
    box-shadow: 0 10px 15px rgba(0,0,0,0.1);
    margin-top: 1rem;
    padding: 1rem;
}
.mobile-menu.open { display: block; }
.mobile-menu nav { display: flex; flex-direction: column; gap: 1rem; }
.mobile-menu nav a {
    text-align: center;
    padding: 0.75rem;
    font-weight: 600;
    color: var(--dark-text);
    transition: color 0.3s;
}
.mobile-menu nav a:hover { color: var(--brand-blue); }

.mobile-menu .cta-button {
    background-color: var(--brand-blue);
    color: var(--white);
    padding: 0.75rem 1.5rem;
    border-radius: 0.375rem;
    text-align: center;
    font-weight: bold;
}

/* === SEKCJA HERO === */
.hero {
    position: relative;
    height: 100vh;
    display: flex;
    align-items: flex-end; /* Przesunięcie treści w dół w widoku mobilnym */
    justify-content: center;
    text-align: center;
    color: var(--white);
    background: url('hero.jpg') no-repeat center center/cover;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
}

.hero-content {
    position: relative;
    z-index: 10;
    padding-bottom: 4rem; 
}

.hero-title {
    font-family: var(--font-serif);
    font-size: 2.2rem; 
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 0.5rem; 
    /* Zmiana wysokości, aby lepiej pasowała do logo + tekstu */
    height: auto; 
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

/* NOWY STYL DLA LOGO W HERO */
.hero-logo-container {
    margin-bottom: 0.5rem; /* Odstęp między logo a tekstem */
}

.hero-logo-img {
    width: 270px; /* Stały rozmiar logo w widoku mobilnym */
    height: 270px;
    object-fit: contain; /* Upewnia się, że kwadratowe logo się zmieści */
    display: block;
    margin: 0 auto;
}

.hero-title .static-text {
    /* Styl dla napisu "MOBILE MECHANIC" pod logo */
    display: block;
    font-size: 2.2rem; /* Wartość dla mobilnych */
    line-height: 1.1;
    margin-top: 0;
}
/* KONIEC STYLI LOGO */

.hero-subtitle {
    font-size: 1.1rem; 
    font-weight: 300;
    margin-bottom: 1.5rem; 
    max-width: 48rem;
    margin-left: auto;
    margin-right: auto;
}

.hero-reviews {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem; 
    margin-bottom: 1.5rem; 
}

.stars { color: var(--brand-yellow); font-size: 1.25rem; } 

.review-text-container { height: 2.5rem; display: flex; align-items: center; justify-content: center; }
.review-text {
    font-style: italic;
    color: #E5E7EB;
    transition: opacity 0.5s;
}
.review-text.fading { opacity: 0; }

.hero-buttons {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.cta-button {
    font-weight: bold;
    padding: 0.75rem 2rem; 
    border-radius: 0.375rem;
    text-align: center;
    transition: all 0.3s;
    transform-origin: center;
}

.cta-button.primary {
    background-color: var(--brand-blue);
    color: var(--white);
}
.cta-button.primary:hover {
    background-color: #005f8e;
    transform: scale(1.05);
}

.cta-button.secondary {
    border: 2px solid var(--brand-yellow);
    color: var(--white);
}
.cta-button.secondary:hover {
    background-color: var(--brand-yellow);
    color: var(--brand-navy);
    transform: scale(1.05);
}

/* === ANIMACJE NA SCROLL === */
.animated-section {
    opacity: 0;
    transform: translateY(0); 
    transition: opacity 0.7s ease-out, transform 0.7s ease-out;
}

.animated-section.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* === OGÓLNE SEKCJE === */
section {
    padding: 5rem 0;
}

section:nth-of-type(even) {
    background-color: var(--white);
}

/* === SEKCJA O NAS (Zmieniona wysokość obrazu) === */
.about-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3rem;
}

.about-image {
    width: 100%;
    height: 350px; 
    object-fit: cover; 
    border-radius: 0.5rem;
    box-shadow: 0 10px 20px rgba(0,0,0,0.15);
}

.about-text {
    text-align: center;
}
.about-text p {
    color: var(--medium-gray);
    margin-bottom: 1rem;
}

/* === SEKCJA USŁUGI === */
.services-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    margin-top: 3rem;
}

.service-card {
    background-color: var(--white);
    padding: 2rem;
    border-radius: 0.5rem;
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
    text-align: center;
    transition: transform 0.3s, box-shadow 0.3s;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.service-card:hover {
    transform: translateY(-0.5rem);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

.service-icon {
    color: var(--brand-blue);
    font-size: 3rem;
    margin-bottom: 1.5rem;
}

.service-card h3 {
    font-family: var(--font-serif);
    font-size: 1.25rem;
    font-weight: bold;
    color: var(--dark-text);
    margin-bottom: 0.75rem;
    flex-grow: 1;
}

.service-card p {
    color: var(--medium-gray);
}

/* === SEKCJA DLACZEGO MY (Zmieniona wysokość obrazu) === */
.why-choose-us-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3rem;
}

.why-choose-us-text p {
    color: var(--medium-gray);
    margin-bottom: 2rem;
}

.features {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.feature-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.feature-icon {
    flex-shrink: 0;
    width: 3rem;
    height: 3rem;
    border-radius: 50%;
    background-color: var(--brand-navy);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
}

.feature-item h3 {
    font-weight: bold;
    font-size: 1.125rem;
    color: var(--dark-text);
}

.feature-item p {
    margin-top: 0.25rem;
    color: var(--medium-gray);
    margin-bottom: 0;
}

.why-choose-us-image {
    width: 100%;
    height: 450px; 
    object-fit: cover;
    border-radius: 0.5rem;
    box-shadow: 0 10px 20px rgba(0,0,0,0.15);
}

/* === SEKCJA OPINIE === */
.testimonials-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    margin-top: 3rem;
}

.testimonial-card {
    background-color: var(--white);
    padding: 2rem;
    border-radius: 0.5rem;
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
    display: flex;
    flex-direction: column;
    height: 100%;
}
.testimonial-card .stars { margin-bottom: 1rem; }
.testimonial-card p:first-of-type {
    color: var(--medium-gray);
    font-style: italic;
    margin-bottom: 1.5rem;
    flex-grow: 1;
}
.testimonial-card .name { font-weight: bold; color: var(--dark-text); }
.testimonial-card .service { font-size: 0.875rem; color: #9CA3AF; }

/* === SEKCJA BLOG (Zmieniona wysokość obrazu) === */
.blog-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    margin-top: 3rem;
}

.article-card {
    background-color: var(--white);
    border-radius: 0.5rem;
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
    border: 1px solid #E5E7EB;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: 100%;
}
.article-image { position: relative; }
.article-image img {
    width: 100%;
    height: 220px; 
    object-fit: cover;
    transition: transform 0.5s;
}
.article-card:hover .article-image img { transform: scale(1.1); }

.category {
    position: absolute;
    top: 1rem;
    left: 1rem;
    background-color: var(--brand-navy);
    color: var(--white);
    font-size: 0.75rem;
    font-weight: bold;
    text-transform: uppercase;
    padding: 0.25rem 0.75rem;
    border-radius: 0.375rem;
}

.article-content {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}
.article-content h3 { font-family: var(--font-serif); font-size: 1.25rem; margin-bottom: 0.75rem; flex-grow: 1; }
.article-content p { color: var(--medium-gray); margin-bottom: 1rem; flex-grow: 1; }
.article-content a {
    font-weight: bold;
    color: var(--brand-blue);
    align-self: flex-start;
    margin-top: auto;
    transition: color 0.3s;
}
.article-content a:hover { color: #005f8e; }
.article-content a i { margin-left: 0.25rem; }

/* === SEKCJA FAQ === */
.faq-container {
    max-width: 48rem;
    margin: 3rem auto 0;
    background-color: var(--light-gray);
    border-radius: 0.5rem;
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
    overflow: hidden;
}

.faq-item {
    border-bottom: 1px solid #E5E7EB;
}
.faq-item:last-child { border-bottom: none; }

.faq-question {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    text-align: left;
    padding: 1.25rem 1.5rem;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--dark-text);
}

.faq-question i {
    color: var(--brand-blue);
    transition: transform 0.3s;
}
.faq-item.active .faq-question i { transform: rotate(180deg); }

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.5s ease-in-out;
}
.faq-answer p {
    padding: 0 1.5rem 1.5rem;
    color: var(--medium-gray);
}
.faq-item.active .faq-answer {
    max-height: 15rem; /* Adjust as needed */
}

/* === SEKCJA KONTAKT === */
.contact-section p:first-of-type {
    max-width: 40rem;
    margin: 1rem auto 0;
    color: var(--medium-gray);
}
.contact-form-container {
    max-width: 56rem;
    margin: 3rem auto 0;
    background-color: var(--white);
    padding: 2rem;
    border-radius: 0.75rem;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.contact-info-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.contact-info-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    background-color: var(--white);
    padding: 1rem;
    border-radius: 0.5rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}
.contact-info-item i {
    color: var(--brand-blue);
    font-size: 1.5rem;
    width: 2rem;
    text-align: center;
}
.contact-info-item h4 { font-weight: bold; color: var(--dark-text); }
.contact-info-item a, .contact-info-item p { color: var(--medium-gray); }
.contact-info-item a:hover { color: var(--brand-blue); }

#contact-form { display: flex; flex-direction: column; gap: 1.5rem; }
.form-row { display: flex; flex-direction: column; gap: 1.5rem; }
#contact-form label { display: block; font-weight: 600; margin-bottom: 0.5rem; }
#contact-form input, #contact-form textarea {
    width: 100%;
    background-color: var(--light-gray);
    border: 1px solid #D1D5DB;
    border-radius: 0.5rem;
    padding: 0.75rem 1rem;
    color: var(--dark-text);
    font-size: 1rem;
}
#contact-form input:focus, #contact-form textarea:focus {
    outline: none;
    box-shadow: 0 0 0 2px var(--brand-blue);
}

#contact-form .cta-button {
    background-color: var(--brand-navy);
    padding: 0.75rem 2.5rem;
    border: none;
    cursor: pointer;
}
#contact-form .cta-button:hover { background-color: #1a3b5c; }

/* === STOPKA === */
.footer {
    background-color: var(--white);
    border-top: 1px solid #E5E7EB;
    padding: 3rem 0;
    color: var(--medium-gray);
}
.footer .logo { color: var(--dark-text); margin-bottom: 1rem; display: inline-block; }
.footer .logo:hover { color: var(--brand-blue); }
.footer-nav { display: flex; justify-content: center; gap: 1.5rem; margin: 1.5rem 0; font-weight: 600; }
.footer-nav a:hover { color: var(--brand-blue); }
.footer .social-icons { display: flex; justify-content: center; gap: 1.5rem; margin-bottom: 1.5rem; }
.footer .social-icons a { font-size: 1.5rem; color: var(--dark-text); }
.footer .social-icons a:hover { color: var(--brand-blue); }
.footer p { font-size: 0.875rem; }


/* === MEDIA QUERIES (RESPONSYWNOŚĆ) === */
@media (min-width: 768px) {
    .section-title { font-size: 2.5rem; }

    .header-content {
        padding: 1.25rem 0; /* Reset dla widoków desktopowych */
    }

    .logo {
        font-size: 1.5rem; /* Reset dla widoków desktopowych */
    }

    /* ZMIANA: Dodanie transform dla animacji na desktopie */
    .animated-section {
        transform: translateY(2rem); 
    }
    .animated-section.is-visible {
        transform: translateY(0);
    }
    
    .hero {
        align-items: center; /* Wyrównanie do środka na desktopie */
    }

    .hero-content {
        padding-bottom: 0; /* Brak dodatkowego paddingu na desktopie */
    }

    .hero-title {
        /* Powrót do większego rozmiaru na desktopie */
        font-size: 4.5rem; 
        height: auto;
    }
    
    .hero-logo-img {
        width: 300px; /* Większe logo na desktopie */
        height: 300px;
    }

    .hero-title .static-text {
        font-size: 4.5rem;
    }


    .desktop-nav { display: flex; }
    .cta-button-header { display: inline-block; background-color: var(--brand-blue); color: var(--white); font-weight: bold; padding: 0.5rem 1.5rem; border-radius: 0.375rem; transition: all 0.3s; }
    .cta-button-header:hover { background-color: #005f8e; transform: scale(1.05); }
    .mobile-menu-button { display: none; }

    .about-container { flex-direction: row; gap: 5rem; }
    .about-text { text-align: left; flex: 1; }
    .about-image { flex: 1; height: 450px; } 
    
    .services-grid { grid-template-columns: repeat(2, 1fr); }
    .testimonials-grid { grid-template-columns: repeat(2, 1fr); }
    .blog-grid { grid-template-columns: repeat(2, 1fr); }
    
    .contact-info-grid { grid-template-columns: repeat(2, 1fr); }
    .form-row { flex-direction: row; }
    .form-row > div { flex: 1; }

    .why-choose-us-image { height: 500px; } 
}

@media (min-width: 1024px) {
    .services-grid { grid-template-columns: repeat(4, 1fr); }
    .blog-grid { grid-template-columns: repeat(4, 1fr); }
    .testimonials-grid { grid-template-columns: repeat(3, 1fr); }

    .why-choose-us-container { flex-direction: row; gap: 5rem; }
    .why-choose-us-text { flex: 1; }
    .why-choose-us-image { flex: 1; height: 600px; }

    .about-image { height: 500px; } 
}