html,
body {
    margin: 0;
    padding: 0;
    height: 100%;
    /* Pakottaa sivun pohjan ulottumaan ruudun alareunaan asti */
}

body {
    background: url("tausta1.png") center center / cover no-repeat fixed;
    display: flex;
    flex-direction: column;
}

/* Yleinen kuvien nollaus (Siirretty tänne, jotta se ei ylikirjoita logoja) */
img {
    max-width: 100%;
    height: auto;
    display: block;
}

body::before {
    left: 0;
}

body::after {
    right: 0;
}


/* ==========================================
   2. NAVIGAATIOPALKKI JA NAVBAR-LOGO
   ========================================== */
.navbar {
    z-index: 1030;
}

.navbar .container {
    /* Poistaa tyhjää tilaa navigaatiopalkin vasemmasta reunasta */
    padding-left: 0px !important;
}

.navbar-nav .nav-link {
    color: #ffffff;
    transition: all 0.3s ease;
}

.navbar-nav .nav-link:hover {
    color: #00bafe !important;
    text-shadow: 0 0 8px rgba(0, 255, 136, 0.6);
}

.navbar-brand img {
    height: 70px !important;
    /* KORJATTU: Tämä poistaa viallisen clamp-funktion ja pitää mittasuhteet ehjinä */
    width: auto !important;
    margin-left: 0 !important;
}

/* ==========================================
   3. SIVUN SISÄLTÖ JA SIVUN (BODY) LOGO
   ========================================== */
.hero-section {
    padding: 20px 0 30px;
}

/* SIVUN LOGO: Hienosäätö kohdistettu konttiin */
.hero-section .logo img {
    margin-left: 0 !important;
    /* Säädä tätä siirtääksesi sivun logoa sivusuunnassa */

    /* SIIRTO ALEMMAS NATTIIN PAIKKAAN: */
    /* Jos logo on vieläkin liian ylhäällä, nosta tätä lukua (esim. 80px tai 100px) */
    margin-top: 60px !important;

    display: inline-block;
}

.section {
    padding: 80px 0;
}

.section-title {
    text-align: center;
    margin-bottom: 50px;
}

.section-title h2 {
    color: black;
}

.section-title p {
    color: black;
}


/* ==========================================
   4. PALVELUKORTIT (FEATURE CARDS) - KESKITETTY
   ========================================== */
.feature-card {
    background: #4c4e4f;
    border: 1px solid #333;
    border-radius: 12px;
    padding: 30px;
    text-align: center;
    height: 100%;
    transition: transform .2s ease;
}

.feature-card:hover {
    transform: translateY(-5px);
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 15px;
}

.feature-card h4 {
    color: #ffffff;
}

/* Korjattu: Poistettu vino left-siirto keskityksen takaamiseksi */
.feature-card p {
    color: #d8d8d8;
    position: static;
    left: 0;
}


/* ==========================================
   5. KUVA-KARUSELLI (CAROUSEL)
   ========================================== */
.carousel {
    max-width: 100%;
    margin: 0 auto;
}

.carousel img {
    height: 400px;
    object-fit: cover;
    border-radius: 100px;
}

#heroCarousel {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
}

#heroCarousel .carousel-item img {
    height: 500px;
    object-fit: cover;
}


/* ==========================================
   6. ALAPALKKI (STICKY FOOTER KORJAUKSILLA)
   ========================================== */
.site-footer {
    background: #111;
    color: white;
    border-top: 3px solid #c7c7c7;
    padding: 10px 0;
}

.page-wrapper {
    border-left: 4px solid #00ff88;
    border-right: 4px solid #00ff88;
    min-height: 100vh;
}

/* Korjattu: Poistettu väärä välilyönti kaksoispisteen jälkeen */
body>*:not(footer):not(script) {
    flex: 1 0 auto;
}

footer {
    flex-shrink: 0;
}