* {
    box-sizing: border-box;
    margin: 0;
    font-family: 'Poppins', Arial, Helvetica, sans-serif;
}

body {
    background: linear-gradient(to bottom, #1c1c1c, #2a2a2a);
    display: grid;
    grid-template-rows: 130px 350px auto 130px;
    min-height: 100vh;
    color: white;
    box-shadow: 0 4px 15px rgba(0,0,0,0.5);
}

.wrapper_header {
    max-width: 1200px;
    width: 90%;
    height: 100%;
    margin: auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 22px;
    font-weight: bold;
    letter-spacing: 1px;
}

nav a {
 color: #f5f5f5;
    text-decoration: none;
    margin-left: 20px;
    font-weight: 500;
    position: relative;
    transition: 0.3s;
}

nav a:hover {
    color: #ff3c3c;   
}



.hero {
    background: url("gymer_jason-crossfit-1126999_1280.jpg") center/cover no-repeat;
    position: relative;
}

.hero::after {
    content: "";
    position: absolute;
    inset: 0;
   background: rgba(0,0,0,0.65);
}

.inner_wrapper {
    position: relative;
    z-index: 2;
    max-width: 1200px;
    width: 90%;
    height: 100%;
    margin: auto;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    color: white;
}

.inner_wrapper h1 {
    font-size: 40px;
}

main {
    max-width: 1200px;
    width: 90%;
    margin: 60px auto;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.card {
     background: #2f2f2f;
    padding: 25px;
    border-radius: 15px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.4);
    transition: 0.3s;
}


.card h2 {
  margin-bottom: 10px;
    color: #ff3c3c;
}

.card:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 30px rgba(255, 60, 60, 0.3);
}


.slika {
    position: relative;
    overflow: hidden;
    border-radius: 15px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.slika img {
    width: 100%;
    display: block;
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.img2 {
    position: absolute;
    top: 0;
    left: 0;
    opacity: 0;
}

.slika:hover .img2 {
    opacity: 1;
}

.slika:hover .img1 {
    opacity: 0;
}

.slika:hover img {
    transform: scale(1.1);
}


.text_drzac {
     background: #1f1f1f;
    border-left: 5px solid #ff3c3c;
    padding: 25px;
    border-radius: 15px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 10px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.4);
}

.line {
    font-weight: 500;
}

footer {
    background: #000000;
    color: #ccc;
}

.wrapper_footer {
    max-width: 1200px;
    width: 90%;
    height: 100%;
    margin: auto;

    display: flex;
    justify-content: space-between;
    align-items: center;
}


@media (max-width: 1400px) {
    main {
        grid-template-columns: repeat(3, 1fr);
    }
}


@media (max-width: 1024px) {
    body {
        grid-template-rows: 130px 300px auto 130px;
    }

    main {
        grid-template-columns: repeat(2, 1fr);
    }

    .text_drzac {
        grid-column: span 2;
    }
}


@media (max-width: 768px) {
    .inner_wrapper h1 {
        font-size: 28px;
    }

    .wrapper_header {
        flex-direction: column;
        justify-content: center;
        gap: 10px;
        text-align: center;
    }

    main {
        grid-template-columns: 1fr;
    }

    .text_drzac {
        grid-column: span 1;
    }
}


@media (max-width: 480px) {

    body {
        grid-template-rows: 150px 250px auto 150px;
    }

    nav a {
        margin-left: 10px;
        font-size: 14px;
    }

    .inner_wrapper h1 {
        font-size: 22px;
    }

    .wrapper_footer {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }
}