body {
    background-color: #a7cef2;
    font-family: Arial, Verdana;
    margin: 40px 40px;
}

nav {
    font-family: 'Great Vibes', cursive;
    font-size: clamp(20px, 6vw, 65px);
    text-align: center;
    width: 100%;
    max-width: 1000px;
    border-left: 4px solid black;
    border-right: 4px solid black;
    border-bottom: 4px solid black;
    padding-top: 10px;
    box-sizing: border-box;
    margin: auto auto;
}

.otsikko {
    width: 100%;
    max-width: 1000px;
    border-top: 4px solid black;
    border-left: 4px solid black;
    border-right: 4px solid black;
    padding-top: 30px;
    padding-bottom: 30px;
    box-sizing: border-box;
    margin: auto auto;
}

.otsikko2 {
    width: 100%;
    max-width: 1000px;
    border-top: 4px solid black;
    border-left: 4px solid black;
    border-right: 4px solid black;
    padding-top: 1px;
    padding-bottom: 1px;
    box-sizing: border-box;
    margin: auto auto;
}

.kehys {
    width: 100%;
    max-width: 1000px;
    border: 4px solid black;
    padding-top: 0px;
    box-sizing: border-box;
    margin: auto auto;
}

nav a {

    text-decoration: none;
    margin: 0 20px
}

a:link {
    color: black;
}

a:visited {
    color: black;
}

a:hover {
    color: blueviolet;
}


h1 {
    font-family: 'Great Vibes', cursive;
    font-size: clamp(20px, 7vw, 60px);
    text-align: center
}

h2 {
    font-family: 'Great Vibes', cursive;
    font-size: clamp(10px, 5vw, 40px);
}

h3 {
    font-family: 'Great Vibes', cursive;
    font-size: clamp(20px, 5vw, 50px);
    text-align: center;
}

.teksti {
    padding: 20px;
    font-size: clamp(12px, 4vw, 18px);
    text-align: center;
}

table {
    font-family: arial, sans-serif;
    border-collapse: collapse;
    width: 100%;
}

td,
th {
    border: 1px solid #000000;
    text-align: left;
    padding: 8px;
}

tr:nth-child(even) {
    background-color: hsl(221, 100%, 94%);
}

.table-wrapper {
    overflow-x: auto;
    max-width: 1000px;
}


.galleria {
    max-width: 1000px;
    margin: 20px auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
    gap: 15px;
}

.galleria img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border: 3px solid black;
    cursor: pointer;

}

.lightbox {
    position: fixed;
    inset: 0;
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.lightbox:target {
    display: flex;
}

.lightbox-bg {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.788);
}

.lightbox img {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
    border: 4px solid white;
    z-index: 1;
}

.footer {
    width: 100%;
    max-width: 1000px;
    border: 4px solid black;
    padding: 16px 0;
    box-sizing: border-box;
    margin: auto auto;
}

.footer-ruudukko {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 40px;
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    font-size: clamp(14px, 3.5vw, 20px);
}

.footer-otsikko {
    margin: 0 0 8px 0;
    font-family: 'Great Vibes', cursive;
    font-size: clamp(28px, 6vw, 48px);
    color: black;
}

.footer-vasen a {
    margin: 4px 0;
    color: black;
    text-decoration: none;
}

.footer-oikea {
    text-align: right;
}

.somekuvat {
    display: flex;
    justify-content: flex-end;
    gap: clamp(16px, 5vw, 32px);
}

.somekuvat img {
    width: clamp(28px, 8vw, 60px);
    height: auto;
    display: block;
}

@media (max-width: 600px) {
    .footer-ruudukko {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 12px;
    }

    .footer-oikea {
        text-align: center;
    }

    .somekuvat {
        justify-content: center;
    }
}

.copyright {
    text-align: center;
    font-family: Arial, Helvetica, sans-serif;
    font-size: clamp(10px, 4vw, 18px);
}