/*
Theme Name:     Explainer.nl
Theme URI:      
Description:    Make-some-waves child theme.
Author:         0117 Web Wizards
Author URI:     https://www.0117.nl
Template:       make-some-waves
Version:        0.2.0
*/


/* * {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
} */
  
html{
    background-color: white;
}

::selection{
    background-color: var(--wp--preset--color--secondary-200);
    color: white;
}

h1 {
    word-break: break-word;
    hyphens: auto;
    hyphenate-limit-chars: 10 5 4;
}

h1.no-break{
    word-break: keep-all;
    hyphens: manual;
}

@media (max-width: 500px){
    header figure{
        max-width: 180px;
    }
}

#homeVideo{
    background-color: #7D00FF;
    width: 100%;
    height: auto;
}

header .wp-block-image{
 margin-top: -10px;
}

/* Cookie banner */
p.cky-title{
    font-size: 16px !important;
}
div.cky-notice-des p{
    font-size: 12px;
}
div.cky-notice-btn-wrapper button{
    font-size: 13px;
}

/* White border
* 
* White border around body
* Navbar selector from navigation.css
*/
body{
    background-color: white;
}
@media (min-width: 601px) {
    body{
        margin: 0 20px 20px;
    }
    .wp-block-template-part:has(>.is-position-sticky) {
        border-top: 20px solid white;
    }
}


/* Page templates
/* 
* Adds different body backgrounds to templates
*/
body.page-template-default{
    background-image: url('assets/graphics/explainer-bg-grid-left-orange.svg');
    background-size: clamp(1000px, 100%, 1500px) auto;
    background-position: left top px;
    background-repeat: no-repeat;
}
@media (max-width: 781px){
    body.page-template-default{
        background-position: left top 0px;
    }
}

body.home{
    background-image: url('assets/graphics/explainer-bg-grid-right-purple.svg');
    background-size: clamp(1000px, 100%, 1500px) auto;
    background-position: right top 200px;
    background-repeat: no-repeat;
}
@media (max-width: 781px){
    body.home{
        background-position: right top 0px;
    }
}

body.single-post{
    background-image: url('assets/graphics/explainer-bg-grid-left-orange.svg');
    background-size: clamp(1000px, 100%, 1800px) auto;
    background-position: left top;
    background-repeat: no-repeat;
}


/* DESKTOP NAVIGATION */
@media (min-width: 900px) {
    header .wp-block-navigation__responsive-container{
        position: absolute;
        bottom: unset;
        left: unset;
        width: auto !important;
        height: auto !important;
        background-color: var(--wp--preset--color--primary-200) !important;
    }
    header .wp-block-navigation__responsive-dialog{
        position: relative !important;
        padding: 50px !important;
    }
    header .wp-block-navigation__responsive-container-close{
        position: absolute !important;
        right: 20px !important;
        top: 20px !important;
    }
    header .wp-block-navigation__responsive-container-content{
        padding-top: 0 !important;
    }
    /* Fix top margin */
    header div.wp-block-navigation__responsive-dialog{
        margin: 0 !important;
    }
}

.wp-block-navigation:not(.has-background) .wp-block-navigation__responsive-container.is-menu-open{
    background-color: var(--wp--preset--color--primary-200);
    color: white;
}
/* Active item */
.wp-block-navigation .wp-block-navigation__responsive-container.is-menu-open .current-menu-item a{
    color: var(--wp--preset--color--tertiary-200) !important; 
}

.wp-block-navigation__responsive-container-open svg {
    height: 18px;
    width: unset;
}

html.has-modal-open{
    overflow: auto;
}

/* 
* Navigation text decoration
*/

:root :where(.wp-block-navigation a){
    text-decoration: none;
}

@media (hover: hover){
    :root :where(.wp-block-navigation a:hover){
        color: var(--wp--preset--color--secondary-200) !important;
    } 
}


/* Home video
* 
* Content over homepage video
*/

/* Chrome controls background */
video::-webkit-media-controls-panel {
    background-image: linear-gradient(0deg, rgba(0, 0, 0, .5) 0%, transparent 100%);
}

@media( max-width: 900px){
    div:has(> #homeVideo){
        padding: 0 !important;
    }
}

#homeVideo{
    position: relative;
    z-index: 1;
}

#homeVideo:hover{
    cursor: pointer;
}
/* Mute Icon */
/* #homeVideo::before{
    content: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 576 512"><path fill="white" d="M301.1 34.8C312.6 40 320 51.4 320 64l0 384c0 12.6-7.4 24-18.9 29.2s-25 3.1-34.4-5.3L131.8 352 64 352c-35.3 0-64-28.7-64-64l0-64c0-35.3 28.7-64 64-64l67.8 0L266.7 40.1c9.4-8.4 22.9-10.4 34.4-5.3zM425 167l55 55 55-55c9.4-9.4 24.6-9.4 33.9 0s9.4 24.6 0 33.9l-55 55 55 55c9.4 9.4 9.4 24.6 0 33.9s-24.6 9.4-33.9 0l-55-55-55 55c-9.4 9.4-24.6 9.4-33.9 0s-9.4-24.6 0-33.9l55-55-55-55c-9.4-9.4-9.4-24.6 0-33.9s24.6-9.4 33.9 0z"/></svg>');
    color: white;
    position: absolute;
    left: 30px;
    top: 30px;
    width: 50px;
    height: 50px;
} */

/* Logo */
#homeVideo::after{
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    left: 0;
    top: 0;
    background-color: none; 
    z-index: 20;
    background: transparent url('assets/graphics/play.png') center center no-repeat;
    background-size: 100%;
}

/* Remove when clicked, functions.js */
#homeVideo.hide-overlay::before{
    opacity: 0;
    transition: opacity .4s ease;
}

#homeVideo.hide-overlay::after{
    opacity: 0;
    transition: opacity .4s ease;
}

#homeVideo.playing::before, #homeVideo.playing::after{
    width: 0px;
    height: 0px;
    content: unset;
    position: relative;
}


/* Home Projects
* 
* Cover block styling
*/
.explainer-latest-projects .wp-block-cover .wp-block-cover__inner-container{
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity .3s, transform .2s ease;
  }
  
  .explainer-latest-projects .wp-block-cover .wp-block-cover__background{
    opacity: 0 !important;
  }
  
  .explainer-latest-projects .wp-block-cover img{
    scale: 1;
    transition: .3s ease;
  }
  
  .explainer-latest-projects .wp-block-cover:hover .wp-block-cover__inner-container{
      opacity: 1;
      transform: translatey(0px);
  }
  
  .explainer-latest-projects .wp-block-cover:hover img{
        filter: blur(2px) brightness(0.9);
      /* opacity: .2 !important; */
  }
  
  .explainer-latest-projects .wp-block-cover:focus-within img,
  .explainer-latest-projects .wp-block-cover:hover img{
    scale: 1.05;
    transition: .2s ease;
  }
  
  .explainer-latest-projects .wp-block-cover a::after{
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
  }


/* Projects block */

@media (min-width: 800px){
    div.more-projects .wp-block-query{
        margin: 0 -80px;
    }
}

    /* Home Projects
* 
* Cover block styling
*/

div.more-projects div.wp-block-query{
    min-width: -moz-available;
    min-width: -webkit-fill-available;
}

.more-projects .wp-block-cover .wp-block-cover__inner-container{
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity .3s, transform .2s ease;
  }
  
  .more-projects .wp-block-cover .wp-block-cover__background{
    opacity: 0 !important;
  }
  
  .more-projects .wp-block-cover img{
    scale: 1;
    transition: .3s ease;
  }
  
  .more-projects .wp-block-cover:hover .wp-block-cover__inner-container{
      opacity: 1;
      transform: translatey(0px);
  }
  
  .more-projects .wp-block-cover:hover img{
        filter: blur(2px) brightness(0.9);
      /* opacity: .2 !important; */
  }
  
  .more-projects .wp-block-cover:focus-within img,
  .more-projects .wp-block-cover:hover img{
    scale: 1.05;
    transition: .2s ease;
  }
  
  .more-projects .wp-block-cover a::after{
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
  }



/* After elements */
/* 
* Extends variations in styles/blocks
*/

@media (max-width: 781px){
    h1.is-style-cursor::after{
        display: none;
    }
}

@media (max-width: 781px){
    h1.is-style-circle-arrow::after{
        display: none;
    }
}


/* Next section clip fix */
div:has(.is-style-pointer),
section:has(.is-style-pointer){
    position: relative;
    z-index: 1;
}



/* Mark
* 
* Styles default <mark> element from editor
*/
h1:has(mark),
h2:has(mark),
h3:has(mark),
h4:has(mark),
p:has(mark){
    position: relative;
    z-index: 1;
}

mark {
    position: relative;
    background-clip: text;
}
  
mark::after{
    background-color: inherit;
    content: ' ';
    display: inline-block;
    width: 110%;
    height: 110%;
    position: absolute;
    top: -5%;
    left: -5%;
    z-index: -1;
    transform: rotate(1deg);
    z-index: -1;
}


/* EM
* 
* Styles default <em> element from editor
*/
h1:has(em),
h2:has(em),
h3:has(em),
h4:has(em),
h5:has(em),
p:has(em){
  position: relative;
}

em{
  font-style: normal;
  position: relative;
  z-index: 1;
}

em::after{
  content: '';
  position: absolute;
  bottom: 10%;
  left: 0;
  width: 100%;
  height: 30%;
  background-color: var(--wp--preset--color--tertiary-200);
  z-index: -1;
}