/* --- VARIT --- */
:root {
    --blue: #00338D;
    --yellow: #EBB700;
    --dark:  #0D2240;
    --light: #F5F5F7;
}

/* --- YLEINEN --- */
body {
    margin: 0;
    font-family: "Inter", system-ui, sans-serif;
    background: var(--light);
    color: var(--dark);
    scroll-behavior: smooth;
    /* padding-top: 70px */

}
.container {
    max-width: 1200px;   /* Sivuston enimmäisleveys */
    margin: 0 auto 0 auto; /* 40px yläväli */   /*  margin: 0 auto; Keskittää sivun */
    padding: 0 10px;     /* Pieni sisämarginaali reunoille */
}

.center {
    text-align: justify;
}
img {
    max-width: 100%;
    height: auto;
    display: block;
}
/* --- NAVIGAATIO --- */
nav {
    position: sticky;
    top: 0;
    z-index: 1000;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    aspect-ratio: 1920 / 129;
    background-image: url('./nav_.jpg');
    background-size: cover;
    background-position: center;
}
nav .inner {
    max-width: 1200px;
	width: 100%;
    margin: 0 auto;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    padding: 0 20px;
}
.nav-under {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    margin-top: 0;
    aspect-ratio: 1920 / 472;   /* ← sama mittasuhde kuin nav-kuvassa */
    background-image: url('nav-under.jpg');
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center;
}
nav .logo {
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--blue);
}

nav ul {
    list-style: none;
    display: flex;
    gap: 30px;
    margin: 0;
    padding: 0;

}

nav ul li a {
    text-decoration: none;
    color: var(--blue);
    font-weight: 700;
    transition: 0.2s;
}

nav ul li a:hover {
    color: var(--dark);
}
/* Hero-osan oikean reunan navigaatio */
.hero-nav {
    position: absolute;
    top: 20px;
    right: 50px;
    display: inline-block;
    gap: 10px;
    z-index: 3;
}
.hero-nav a {
    color: var(--light);
    font-weight: 700;
    text-decoration: none;
    font-size: 1rem;
    transition: 0.5s;
}
.hero-nav a:hover {
    color: var(--blue);
    text-shadow: 0 0 6px rgba(255,255,255,0.7);
}
/* Yksi hero-kuva (ei slideshowa) */
.hero-single {
    height: 45vh;
    max-height: 1000px;
    min-height: 500px;
}

/* Overlay keskelle */
.hero-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;

}

/* --- MOBIILIVALIKKO --- */
.menu-toggle {
        display: none;
		font-size: 1.6rem;
        line-height: 1;
		color: var(--yellow);      /* ← KELTAINEN */
        cursor: pointer;
    }



.hero {
    position: relative;
    height: 15vh;              /* Hero-alueen korkeus */
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    padding: 150px 20px;
    text-align: center;
    color: white;
}
.hero-content {
    display: flex;
    flex-direction: column; /* Teksti omille riveille */
    gap: 18px;              /* Väli riveille */
}

/* Slideshow-tausta */
.slideshow-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    overflow: hidden;
    z-index: -1;
}


/* Yksittäinen kuva */
.galleria-item {
    position: relative;
    overflow: hidden;
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

/* --- SLIDESHOW --- */
.galleria {
    position: relative;
    width: 100%;
    height: 60vh;        /* 60% näytön korkeudesta */
	margin-top: 20px; /* ← säädä sopivaksi (10–40px) */
    max-height: 600px;
    min-height: 300px;
    overflow: hidden;
}

.galleria-item {
    position: absolute;
	overflow: hidden;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 1.2s ease-in-out;
}

.galleria-item.active {
    opacity: 1;
}

.galleria-item img {
    width: 100%;
    height: 100%;
	filter: blur(2px);
    object-fit: cover;   /* täyttää alueen kauniisti */
    pointer-events: none; /* lisätty jotta saa linkin kuvan päälle */
	display: block;
}


/* Teksti kuvan päällä */
.teksti-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 80%;
    padding: 10px;
	backdrop-filter: blur(3px);
    color: white;
    font-size: 1.2rem;
    opacity: 1;                 /* piilotettu */
    transform: translateY(20px); /* pieni liike alas */
    transition: 0.8s ease;       /* pehmeä animaatio */
    pointer-events: auto;
}

.galleria-item:hover .teksti-overlay {
    opacity: 1;
    transform: translateY(0);
}


/* Hover-efekti */
.galleria-item:hover img {
    transform: scale(1.05);
    filter: blur(6px)brightness(1.4);
}

/* Hero-sisältö */
.hero-content {
    position: relative;
    z-index: 10;
    padding: 100px 20px 100px;
    text-align: center;
}

.btn {
    display: inline-block;
    margin-top: 25px;
    background: var(--light, 0,4);
    color: var(--blue);
    padding: 12px 25px;
    border-radius: 6px;
    font-weight: 700;
	font-size: 2rem; 
    text-decoration: none;
    transition: 0.25s;
}

.btn:hover {
    background: var(--blue);
    color: var(--yellow);
}

/* --- OSIOT --- */
section {
    padding: 70px 20px;
    max-width: 1100px;
    margin: auto;
}

h2 {
    color: var(--blue);
    text-align: center;
    margin-bottom: 40px;
    font-size: 2.2rem;
}
/* kartta */
.map-image {
    max-width: 100%;   /* Ei ylitä sivun leveyttä */
    height: auto;      /* Säilyttää kuvasuhteen */
    display: block;    /* Poistaa ylimääräiset välit */
    margin: 0 auto;    /* Keskittää kuvan */
    border-radius: 10px; /* (valinnainen) pehmeät kulmat */
}
#aluekartta {
    max-width: none;          /* poistaa 1100px rajoituksen */
    padding-left: 0;
    padding-right: 0;
    text-align: center;       /* keskittää otsikon */
}

#aluekartta .map-image {
    display: block;
    max-width: 100%;
    height: auto;
    margin: 0 auto;           /* 🔑 keskitys */
}

#saapuminen {
    max-width: none;          /* poistaa 1100px rajoituksen */
    padding-left: 0;
    padding-right: 0;
    text-align: center;       /* keskittää otsikon */
}

#saapuminen .map-image {
    display: block;
    max-width: 100%;
    height: auto;
    margin: 0 auto;           /* 🔑 keskitys */
}


/* --- KORTIT --- */
.cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 25px;
}

.card {
    background: white;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.08);
    transition: 0.25s;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 18px rgba(0,0,0,0.12);
}

.card h3 {
    margin-top: 0;
    color: var(--blue);
}
.card a {
    text-decoration: none;
    color: inherit;
    display: block;
}

.error {
    color: red;
    font-weight: bold;
    text-align: center;
}

/* --- FOOTER --- */
footer {
    text-align: center;
    padding: 25px;
	background: linear-gradient(to right, #7A2582, #00338D, #00338D);
    color: var(--yellow);
    margin-top: 40px;
}
#yhteys { 
   text-align: center;
   background: #f7f7f7; 
   user-select: none;
   -webkit-user-select: none;
   -ms-user-select: none;
}
/* Facebook-ikkuna */
#facebook {
    display: flex;
    justify-content: center;
}

#facebook h2 {
    text-align: center;
    color: var(--blue);
    margin-bottom: 20px;
}
.fb-container {
    width: 100%;
    max-width: 500px;
    height: 600px;
    margin: 0 auto 40px;
}
.fb-container iframe {
    width: 100%;
    height: 100%;
    display: block;
}

.some-icons {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    text-align: center;
}

.some-icons img {
    width: 40px;
    height: 40px;
    transition: 0.25s;
}

.some-icons img:hover {
    transform: scale(1.15);
}


/* --- MOBIILI-OPTIMOINTI --- */
@media (max-width: 1100px) {
    /* NAV – vakaa korkeus mobiilissa */
    nav {
        aspect-ratio: 1920 / 129;
        padding: 0; /* EI paddingia naville */
    }

    /* Sisältö navin sisällä */
    nav .inner {
        height: 100%;
        padding: 0 auto-fit;
        display: flex;
        align-items: center;
        justify-content: flex-end;
    }

    /* Logo */
    nav .logo {
        font-size: 1.1rem;
    }
}
    /* Burger-ikoni */
	@media (max-width: 1100px) {
    .menu-toggle {
        display: block;
        font-size: 1.8rem;
        color: var(--yellow);
        cursor: pointer;
    }
    nav ul {
        position: absolute;
        top: 100%;
        right: 16px;
        width: 180px;
        background: var(--yellow);
        border-radius: 8px;
        padding: 10px 0;

        display: none;
        flex-direction: column;
    }
    nav ul.show {
        display: flex;
    }
    nav ul li a {
        padding: 12px 16px;
        color: var(--dark);
		min-height: 44px;
		display: block;
    }
    /* Hero-alue */
    .hero {
        height: 50vh;
        padding: 40px 15px;
    }

    .hero h1 {
        font-size: 2rem;
        line-height: 1.2;
    }

    .hero p {
        font-size: 1rem;
        margin-top: 10px;
    }

    .btn {
        padding: 10px 20px;
        font-size: 0.95rem;
        margin-top: 20px;
    }

    /* Taustakuvat */
    .slideshow-bg {
        background-position: center;
        background-size: cover;
        filter: brightness(0.5);
    }
    .galleria {
        width: 100vw;           /* koko näytön leveys */
        height: 45vh;           /* sopiva korkeus mobiilissa */
        min-height: 260px;
        max-height: 420px;
        margin-left: calc(-50vw + 50%);
        margin-right: calc(-50vw + 50%);
    }

    .galleria-item img {
        object-fit: cover;      /* täyttää alueen */
        object-position: center;
		filter: blur(3px);
    }
	
    /* Osiot */
    section {
        padding: 50px 15px;
        margin-top: 20px;
    }

    h2 {
        font-size: 1.8rem;
        margin-bottom: 25px;
    }



    /* Kortit */
    .cards {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .card {
        padding: 20px;
    }

    /* Lomake */
    form input,
    form textarea {
        font-size: 0.95rem;
        padding: 10px;
    }

    form button {
        padding: 10px 20px;
        font-size: 1rem;
    }

    /* Facebook-ikkuna */
    .fb-container iframe {
        width: 100% ;
        height: 550px ;
    }
}
