/* Cards */
.image-contain {
    width: 100%;
    padding-top: 100%;
    /* 1:1 Aspect Ratio */
    position: relative;
}

.image-contain img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.card {
    padding: 10px;
    margin-bottom: 20px;
    border: 1px solid #9639ff;
    border-radius: 5px;
    display: flex;
    flex-direction: row;
    transition: border 0.3s ease;
}

.col-md-2,
.col-md-8 {
    flex: 1;
    padding: 10px;
}

.col-md-2 {
    max-width: 200px;
}

.col-md-2-comeup {
    flex: 1;
    padding: 10px;
}

.col-md-2-comeup {
    max-width: 270px;
}

/* Cards END*/

/* Instagram stories card*/
.card-stories {
    padding: 10px;
    margin-bottom: 20px;
    border: 1px solid #9639ff;
    border-radius: 5px;
    display: flex;
    flex-direction: row;
    transition: border 0.1s ease;
}

.card-stories:hover {
    border-width: 1px;
    border-color: #ddd;
    color: black;
    background-color: transparent;
}

.card-stories:link {
    color: black;
    background-color: transparent;
    text-decoration: none;
}

.card-stories:active {
    color: black;
    background-color: transparent;
    text-decoration: none;
}

.card-stories:visited {
    color: black;
    background-color: transparent;
    text-decoration: none;
}

/* Instagram stories card END */


/* SoME stories */
.image-SoMe-table {
    margin: 20px auto 0px auto;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-bottom: 40px;
}

.image-SoMe-cell {
    position: relative;
    width: 100%;
    overflow: hidden;
    box-sizing: border-box;
}

.image-SoMe-cell img {
    width: 100%;
    height: auto;
    max-height: 400px;
    display: block;
    object-fit: cover;
}

.image-container {
    position: relative;
    width: 100%;
    overflow: hidden;
}

.image-container img {
    width: 100%;
    height: auto;
    display: block;
    transition: opacity 0.3s ease;
}

.image-container iframe {
    width: 100%;
    height: auto;
    display: block;
    transition: opacity 0.3s ease;
}

.image-container .overlay {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    right: 0;
    height: 100%;
    width: 100%;
    opacity: 0;
    transition: .5s ease;
    /* background-color: #9639ff; */
    background-color: rgba(150, 57, 255, 0.8);
    color: #fff;
    font: clamp(10px, 1vw, 14px) 'TECSans-Regular', Arial, Helvetica, sans-serif;
    overflow-wrap: break-word;
    padding: 20px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    transition: opacity 0.3s ease;
}

.image-container:hover img {
    opacity: 1;
}

.image-container:hover iframe {
    opacity: 1;
}

.image-container:hover .overlay {
    opacity: 1;
}

/* SoME stories END */


/*-------------- Video --------------*/

#video-special1 {
    margin-top: 20px;
}

#video-special2 {
    margin-top: 20px;
}

/*iframe in stories*/
.present-video {
    width: 100%;
    height: 100%;
    aspect-ratio: 16/9;
    margin-bottom: 20px;
}

/*video.htm*/
video {
    width: 100%;
    height: auto;
    aspect-ratio: 16/9;
}

.video-container {
    overflow: hidden;
    /* Skjuler scrollbaren */
    width: 100%;
    height: auto;

}

/*Border*/
.video-card {
    border: 1px solid #9639ff;
    border-radius: 5px;
    display: flex;
    flex-direction: column;
    padding: 10px;
    margin-bottom: 20px;
}

/*header*/
.video-card-title {
    font-weight: bold;
}

/*Text*/
.video-card-text {
    font-family: Arial, Helvetica;
    font-size: 16px;
}

/*-------------- Video END --------------*/



/* Media query for tablets */
@media screen and (max-width: 768px) {
    .image-SoMe-table {
        grid-template-columns: 1fr;
    }

    .image-SoMe-cell {
        flex: 1 1 100%;
        padding: 10px;
        box-sizing: border-box;
    }

    .image-dev-table {
        grid-template-columns: repeat(2, 1fr);
    }

    .card {
        flex-direction: column;
    }

    .card-stories {
        flex-direction: column;
    }

    .col-md-2,
    .col-md-8 {
        flex: none;
        max-width: 100%;
    }

    .container {
        padding: 0 30px;
        background-color: #fff;
        font-family: Arial, Helvetica, sans-serif;
    }

    .present-video {
        width: 100%;
        height: auto;
        aspect-ratio: 16/9;
    }

    .image-container .overlay {
        position: relative;
        top: 0;
        bottom: 0;
        left: 0;
        right: 0;
        height: 100%;
        width: 100%;
        opacity: 1;
        transition: .5s ease;
        background-color: #9639ff;
        color: #fff;
        font: 14px Verdana, sans-serif;
        padding: 20px 20px 20px 20px;
    }

    .image-container:hover img {
        opacity: 1;
    }

    .movingtext-container {
        overflow: hidden;
        white-space: nowrap;
        position: relative;
        width: 100%;
        margin: 0 auto;
        /*   text-align: center;*/
        /* font: 50px Garamond, serif; */
    }

    object.word-image {
        width: auto;
        height: 77px;
        display: inline-block;
        animation: scrollText 30s infinite;
        opacity: 1;
        margin: 0 30px 10px 0;
        vertical-align: top;
    }

    .row1 .column {
        flex: 1 1 100%;
        /* Flex-grow, flex-shrink, flex-basis */
        padding: 10px;
        box-sizing: border-box;
    }

    .row4 h1 {
        font-size: 20px;
    }

    .logo-container {
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
    }

    .logo-container img {
        height: auto;
        margin: 10px 0;
    }

    #hofor {
        max-width: 100px;
        margin-left: 48px;
    }

    #tietgen {
        max-width: 180px;
        margin-left: 30px;
    }

    #tec {
        max-width: 150px;
        margin-left: 28px;
    }

    .atopos-text {
        margin-top: 20px;
        width: 100%
    }
}

/* Media query for mobile phones */
@media (max-width: 480px) {
    .image-dev-table {
        grid-template-columns: 1fr;
    }

    .image-SoMe-table {
        grid-template-columns: 1fr;
    }

    .video-card {
        flex-direction: column;
    }

    .present-video {
        width: 100%;
        height: auto;
        aspect-ratio: 16/9;
    }

    object.word-image {
        width: auto;
        height: 50px;
        display: inline-block;
        animation: scrollText 30s infinite;
        opacity: 1;
        margin: 0 10px 10px 0;
        vertical-align: top;
    }
}