/** LAYOUT
 * --------------------- */
:root{
    --default-font-size: 16px;
    --default-font-family:  "Lato", sans-serif;

    --theme-c01:    #9D2235; /* vermell, diba corporatiu */
    --theme-c02:    #2C5B70;
    --theme-c03:    #25824D;
    --theme-c04:    #004070;
    --theme-c05:    #225BC6;
    --theme-c06:    #6A229D;
    --theme-c07:    #D53F34;
    --theme-c08:    #687278;

    --tpl-color-base: #9D2235;
    --tpl-color-base2: #711926; /* title */
    --tpl-color-base3: #faf8f2; /* bg header */
    --tpl-color-base4: #2d2020; /* btn bg */
    --tpl-color-base5: #ffffff; /* btn text */
    --tpl-color-body: #ededed; /* bg body */

}
*,
*::before,
*::after {
  box-sizing: border-box;
}

/* This option is used when the user has not chosen to minimize non-essential motion */
@media (prefers-reduced-motion: no-preference) {
  :root {
    scroll-behavior: smooth;
  }
}

/* This option is used when the user has chosen to minimize non-essential motion */
@media (prefers-reduced-motion: reduce) {
  :root {
    scroll-behavior: auto;
    transition: none;
  }
}

/* ---------------- */
:root{
    --theme-color-diba: #9D2235;
    --theme-color: var(--tpl-color-base);
    --theme-video-aspect-ratio: 16/9;
    --theme-cover-padding: 10px;
    --theme-video-title-color: rgba(255,255,255,0.95);
    --theme-cover-title-font-family: "Raleway", sans-serif;
    --theme-controls-icons-color: rgba(0,0,0,.5);


    --theme-color-base2: var(--tpl-color-base2);
    --theme-color-base3: var(--tpl-color-base3);
    --theme-color-base4: var(--tpl-color-base4);
    --theme-color-body: var(--tpl-color-body);

    --theme-bgcolor-header: var( --theme-color-base3);

    --theme-field-border-corlor00: var(--theme-color-base2);
    --theme-field-border-corlor01: var(--theme-color-base2);
    --theme-field-border-corlor02: var(--theme-color-base2);

    --theme-btn-color: var(--theme-color-base4);
    --theme-footer-color: var(--theme-color-base4);

}

body {
  margin: 0;
  font-size: var(--default-font-size);
  font-family: var(--default-font-family);
  -webkit-text-size-adjust: 100%;
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
  background-color: var(--theme-color-body);
}

body.fullscreen{
    overflow: hidden;
}

form, input, select, option, label, button{
    font-family: var(--default-font-family);
}

.cover{
    min-height: 100vh;
    padding-bottom: 40px;
    background-color: var(--theme-color-body);
    background-image: url(pattern-cover-bg.svg);
    background-repeat: repeat;
    background-blend-mode: normal;
    /* background-size: 1600px 900px; */
    background-size: cover;
    padding-bottom: 12rem;
    border-bottom: 20px solid var(--theme-footer-color);
    background-attachment: fixed;
    background-position: top center;

}
.cover-overlay{
    position: absolute;
    top: 0;
    left: 0;
    width: 100vw;
    max-width: 100%;
    height: 400px;

    background-color: var(--theme-bgcolor-header);
    border-top: 8px solid var(--theme-color-base2);
    z-index: 0;
    opacity: 0.9;
}


/** Cover Header
 * ------------------- */

.cover-header{
    margin-top: 0;
    padding-top: 1.5rem;
    padding-left: var(--theme-cover-padding);
    padding-right: var(--theme-cover-padding);
    padding-bottom: 0;

    display: flex;
    flex-direction: column-reverse;
    align-items: center;
    justify-content: space-between;
    gap: 2px;
}
.cover-header .header-content{
    flex: 4;
    display: flex;
    flex-direction: column;
}
.cover-header .header-aux{
    width: 100%;
    min-width: 130px;

    flex: 1;
    display: flex;
    flex-direction: row;
    align-items: flex-end;
    justify-content: space-between;
    gap: 10px;
}
.cover-header .cover-logo{
    width: 100%;
    max-width: 190px;
    margin-top: 1rem;
    margin-left: 0;
}
.cover-header .cover-logo svg {
    fill: var(--theme-color-diba);
}
.cover-header .cover-logo img{
    max-width: 100%;
}
.cover-header h1{
    display: block;
    max-width: calc(-2rem + 96vw);
    margin: 0.25rem 0;

    font-family: var(--theme-cover-title-font-family);
    font-weight: 300;
    font-size: calc(1.95rem + 1.65vw);
    /*line-height: calc(2.0625rem + 3.5125vw);*/
    letter-spacing: calc(-0.125rem - 0.0025vw);

    color: var(--theme-color-base2);
}

.cover-header h1.title-size1{
    font-size: calc(1.35rem + 1.65vw);
}

.cover-header h1.title-size2{
    font-size: calc(1.025rem + 1.65vw);

}

.cover-header .desc{
    color: #444;
}

.title-group{
    position: relative;
    /*display: flex;*/
    opacity: 0;
}
.cover-header .cover-controls{
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding:0;
    background-color: transparent;
    border-radius: 0.2rem;
}
.cover-header .cover-controls > div{
    position: relative;
    display: flex;
    padding-left: 0;
}
.cover-header .cover-controls .clink{
    display: flex;
    align-items: center;
    justify-content: center;
    width: 10vw;
    height: 10vw;
    max-width: 50px;
    max-height: 50px;
}
.cover-header .cover-controls svg{
    width: 70%;
    fill: var(--theme-controls-icons-color);
}

.cover-header .cover-controls > div:hover svg{
    --theme-controls-icons-color: rgba(0,0,0,.8);
}

.cover-header .cover-controls > div::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 100%;
    transition: all 0.25s ease;
    background-color: transparent;
    box-shadow: inset 0 0 0 0px rgba(0,0,0,.1);
    border-radius: 0.2rem;
    z-index: -1;
}
.cover-header .cover-controls > div:hover::before {
    box-shadow: inset 0 0 0 60px rgba(0,0,0,.1);
}

/** Cover Controls
 * ------------------- */

.cover-actions{
    position: relative;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    min-height: 2rem;
    padding-left: var(--theme-cover-padding);
    padding-right: var(--theme-cover-padding);
    margin: 1rem 0;
}

.cover-actions-controls{
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    flex-wrap: wrap;
}
.cover-actions-group{
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 6px;
}

.cover-actions-controls button{
    display: flex;
    align-items: center;
    justify-content: center;

    height: 32px;
    cursor: pointer;

    color:#333;
    background-color: transparent;
    border: 0 solid transparent;
    border-bottom: 4px solid var(--theme-field-border-corlor00);

}
.cover-actions-controls svg{
    width: 30px;
    fill: rgba(0, 0, 0, .3);
    transition: all 0.3s linear;
}
.cover-actions-controls .btn-gridview svg{
    width: 25px;
}

.cover-actions-controls:hover svg{
    fill: rgba(0, 0, 0, .6);
}

.scpform-select-group{
    position: relative;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 2px;
    color: #333;
    background-color: transparent;
    border: 0 solid transparent;
    border-bottom: 4px solid var(--theme-field-border-corlor01);
}
.scpform-select-group label{
    position: absolute;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
}
.scpform-select-group label svg{
    width: 80%;
    height: 80%;
}
.scpform-select-group select{
    height: 32px;
    padding-left: 28px;
    padding-right: 32px;
    cursor: pointer;
    background-color: transparent;
    border: none;
}

.scpform-select-group option{
}


.scpform-search-group{
    position: relative;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 2px;
    color: #333;
    background-color: transparent;
    border: 0 solid transparent;
    border-bottom: 4px solid var(--theme-field-border-corlor02);
}

.scpform-search-group:focus,
.scpform-search-group:focus-within{
    background-color: rgba(255,255,255, .7);
}

.scpform-search-group label{
    position: absolute;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
}
.scpform-search-group label svg{
    width: 80%;
    height: 80%;
}

.scpform-search-group input.filter-control{
    display: flex;
    align-items: center;
    justify-content: flex-start;
    height: 32px;
    padding-left: 32px;
    background-color: transparent;
    border: none;
    outline-offset: -1px;
}


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

.video-grid-container{
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(23.125rem, 1fr));
    gap: 1.25rem;
    min-width: 370px;
    margin-bottom: 0.9375rem;

    padding-left: var(--theme-cover-padding);
    padding-right: var(--theme-cover-padding);
}

.grid-views{
    grid-template-columns: repeat(auto-fill, minmax(23.125rem, 1fr));
}

.list-views{
    grid-template-columns: 1fr;
}

.video-grid-item{
    position: relative;
    display: flex;
    flex-direction: column;
    flex: 0 1 330px;
    margin-bottom: 1.25rem;
    margin-right: 0.75rem;


    color: #ddd;
    background-color: rgba(0, 0, 0, .4);
    border: 1px solid rgba(0,0,0,.1);
    box-shadow: 0px 0px 12px 2px rgba(0, 0, 0, 0.25);

    cursor: pointer;
    opacity: 1;


    transition: transform 0.5s linear;
}

.video-grid-item:hover,
.video-grid-item:focus{
    color: #fff;
    border: 1px solid rgba(255,255,255,.1);
    box-shadow: 0px 0px 12px 4px rgba(128, 128, 140, 0.6);
    transform: translateY(-5px);
}
.video-grid-item:focus-within{
    color: #fff;
    border: 1px solid rgba(255,255,255,.1);
    box-shadow: 0px 0px 12px 4px rgba(128, 128, 140, 0.6);
    outline: 2px solid #000;
    outline-offset: 3px;
    transform: translateY(-5px);
}


.bounce-enter-active {
  animation: bounce-in 1.5s;
}
.bounce-leave-active {
  animation: bounce-out 1.5s;
}

@keyframes bounce-in {
  0% {
    transform: scale(0);
    opacity: 0;
  }
  50% {
    transform: scale(1.05);
    opacity: 0.8;
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}
@keyframes bounce-out {
  0% {
    opacity: 0;
  }
  100% {
    opacity: 1;
  }
}


.video-player{
    position: relative;
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: var(--theme-video-aspect-ratio);
    margin: 0;
    padding: 0;
    overflow: hidden;
}
.video-player-overlay{
    position: absolute;
    width: 100%;
    height: 100%;
    z-index: 10;
}

.video-player-icon{
    display: none;
}

.video-player iframe{
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: var(--theme-video-aspect-ratio);
    border: none;
    margin: 0;
    padding: 0;
}

.video-info{
    display: flex;
    flex-direction: column;footer
    align-items: center;
    justify-content: center;
    padding: 1.25rem;
    color: #eee;
    background-color: var(--theme-color);
    background-image: url(../images/backgrounds/pattern-title-bg.svg);
    background-repeat: no-repeat;
    background-position: right top;
    background-blend-mode: soft-light;

    min-height: 4rem;
    transition: all 0.5s linear;
}

.video-grid-item:hover .video-info{
    color: #fff;
    background-color: var(--theme-color-base4);
}

.video-info .video-title{

    font-size: 1.15rem;
    font-weight: 700;
    line-height: 1.2;

    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.video-info .video-title a{
    text-decoration: none;
    color: var(--theme-video-title-color);
}

.video-info .video-title a:hover{
    text-decoration: underline;
}


.video-info .video-title .video-pagelink{
    position: relative;

    display: inline;
    padding: 0px;
    font-size: inherit;
    line-height: inherit;
    text-decoration: none;

    appearance: none;
    cursor: pointer;

    transition: all 0.1s ease-in-out 0s;
    border: 0px;
    background-color: transparent;
}

.list-views .video-grid-item{
    flex-direction: row;
    gap: 0;
    margin-bottom: 0;
    margin-right: 0;
    background-color: rgba(255, 255, 255, .85);
}

.list-views .video-grid-item .video-player{
    width: 100px;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}
.list-views .video-grid-item .video-player iframe{
    display: none;
}
.list-views .video-grid-item .video-player-icon{
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.list-views .video-grid-item .video-player-icon svg{
    width: 100%;
    max-width: 60px;
    fill: var(--theme-btn-color);
}

.list-views .video-grid-item .video-info{
    width: calc(100% - 100px);
}

/** Cover footer
 * ------------------- */

.cover-footer{
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 2rem;
    padding-left: var(--theme-cover-padding);
    padding-right: var(--theme-cover-padding);
}

.btn-paginator{
    min-width: 2.5rem;
    height: 2.5rem;

    display: flex;
    align-items: center;
    justify-content: center;
    gap: 2px;

    font-size: 0.875rem;
    font-weight: 600;
    line-height: 2.375rem;

    white-space: nowrap;
    cursor: pointer;
    font-family: inherit;
    text-rendering: optimizelegibility;


    transition: all 170ms ease-in-out 0s, font-size 50ms ease-in-out 0s, width 0ms linear 0s, padding 130ms ease-in-out 0s;
    /* box-shadow: inset 0 0 0 0px rgba(0,0,0,.1); */
    box-shadow: 0px 8px 8px 0px rgba(50, 50, 50, 0.5);

    color: rgb(255, 255, 255);
    background: var(--theme-btn-color);
    border: 1px solid var(--theme-btn-color);
    border-radius: 0.2rem;
    transition: all 1s linear;
}
.paginator-controls .btn-paginator{
    padding: 3px 20px;
}


.btn-paginator:hover {
    box-shadow: inset 0 0 0 60px rgba(0,0,0,.3);
}

.btn-paginator svg{
    display: block;
    width: 2rem;
    fill: rgb(255, 255, 255);
}

.hidden {
  display: none;
  visibility: hidden;
}

/** Fullscreen videoplayer
 * -------------------------- */

.fullscreen-vp{
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    max-width: 100%;
    height: 100vh;

    opacity: 1;
    color: #fff;
    background: #000;
    z-index: 9999;
}

.fsfade-enter-active {
  transition: all 0.3s ease-out;
}

.fsfade-leave-active {
  transition: all 0.8s cubic-bezier(1, 0.5, 0.8, 1);
}

.fsfade-enter-from,
.fsfade-leave-to {
    transform: translateX(20px);
    opacity: 0;
}

.fullscreen-vp .video-content{
    height: calc(100vh - 70px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding-top: 25px;
}

.fullscreen-vp .video-player{
    display: flex;
    align-items: center;
    justify-content: center;
    width: auto;
    max-width: 100%;
    height: 100%;
    max-height: 100%;
    margin: 0 auto;
}

.fullscreen-vp .video-info{
    height: 70px;
    padding-top: 5px;
    padding-bottom: 5px;
    padding-left: 10vw;
    color: #fff;
    background-color: rgba(20, 20, 20, .4);
}

.btn-fullscreen-vp{
    position: absolute;

    display: flex;
    align-items: center;
    justify-content: center;

    cursor: pointer;
    z-index: 100;

    background-color: rgba(0,0,0,.2);
    border: none;

    transition: all .3s linear;
}

.btn-fullscreen-vp svg{
    fill: rgba(255,255,255, .5);
}

.btn-fullscreen-vp:hover,
.btn-fullscreen-vp:focus{
    background-color: rgba(128,128,128,.2);
}

.btn-fullscreen-vp:hover svg,
.btn-fullscreen-vp:focus svg{
    fill: #fff;
}

.btn-close-fullscreen-vp{
    top: 1rem;
    right: 2px;
    width: 52px;
    height: 52px;
}
.btn-prev-fullscreen-vp{
    top: 50vh;
    left: 2px;
    width: 62px;
    height: 62px;
}
.btn-next-fullscreen-vp{
    top: 50vh;
    right: 2px;
    width: 62px;
    height: 62px;
}

/** BACK TO TOP
 * ------------------------ */
.back-to-top {
  display: none;
  opacity: 0;
  cursor: pointer;
  position: fixed;
  bottom: 40px;
  right: 20px;
  z-index: 2;
  transition: opacity 1s cubic-bezier(0.23, 1, 0.32, 1);
}
.back-to-top button {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 50px;
  text-align: center;
  cursor: pointer;
  color: #fff;
  background-color: var(--theme-btn-color);
  border: 1px solid var(--theme-btn-color);
  border-radius: 50%;
  box-shadow: 0px 8px 8px 0px rgba(50, 50, 50, 0.5);
  transition: all 1s linear;
}

.back-to-top button:hover {
    box-shadow: inset 0 0 0 60px rgba(0,0,0,.3);
}


.back-to-top button svg{
    fill: #fff;
}

.back-to-top.open{
    display: block;
    opacity: 1;
}

/* RESPONSIVE
 * ---------------- */
@media (min-width: 576px) {
    :root{
        --theme-cover-padding: 25px;
    }
    .cover-header{
        flex-direction: row;
        gap: 20px;
    }
    .cover-header .header-aux {
        width: 130px;
        display: flex;
        flex-direction: column;
        align-items: flex-end;
        justify-content: flex-start;
    }
    .cover-header .cover-logo{
        margin-left: auto;
    }
    .cover-header .cover-controls {
        justify-content: flex-end;
    }
}
@media (min-width: 768px) {
    .cover-actions-controls {
        justify-content: flex-start;
    }
}
@media (min-width: 992px) {
    :root{
        --theme-cover-padding: 65px;
    }
}
@media (min-width: 1200px) {

}
@media (min-width: 1400px) {

}

/** CREDITS
 * --------------------- */
.credits{

}
.credits-container {
    position: absolute;
    top: 0;
    left: 50%;
    width: 70%;
    max-width: 700px;
    z-index: 200;
    padding: 60px;
    overflow: visibĺe;

    color: #222;
    background-color: #fff;
    border-radius: 0;

    -webkit-transform: translate(-50%, -200%);
    -ms-transform: translate(-50%, -200%);
    transform: translate(-50%, -200%);

    transition: transform 0.4s ease-out;
}
.credits-backdrop{
    position: absolute;
    top: 0;
    left: -200vw;
    opacity: 0;
    height: 100vh;
    transition-delay: 2s;
    transition: opacity 0.6s ease-out;
}
.credits.open .credits-backdrop{
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    height: 100%;
    width: 100%;
    color: #FFF;
    background-color: rgba(0,0,0,.75);
    z-index:110;
    opacity: 1;
    cursor: pointer;
    transition: opacity 0.6s ease-out;

}
.credits.open .credits-container {
    top: 50%;
    margin-bottom: 10%;
    -webkit-transform: translate(-50%, -50%);
    -ms-transform: translate(-50%, -50%);
    transform: translate(-50%, -50%);

    transition: transform 0.4s ease-out;
}
.credits-close{
    float: right;
    display: flex;
    flex-wrap: wrap;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    width: 40px;
    height: 40px;
    overflow: hidden;
    cursor: pointer;
    font-size:26px;
    font-weight: bold;
    text-align: center;
    color: #fff;
    background-color: #000;
}
.credits-close:hover,
.credits-close:focus{
    color: #fff;
    background-color: #333;
}
.credits-head{
    display: block;
    overflow: hidden;
}
.credits-title{
    font-size: 40px;
}
.credits-body{
    display: block;
    overflow-y: auto;
    max-height: 80%;
    clear: both;
    font-size: 14px;
}
.credits-body a{
    color: #990025;
    text-decoration: none;
}
.credits-body a:active,
.credits-body a:focus,
.credits-body a:hover{
    text-decoration: underline;
}



/* EXTRAS */
.hide, .hidden {
  display: none !important;
}
.hide-accessible {
    transform: scale(0);
    -webkit-transform-origin-x: 0px;
    -webkit-transform-origin-y: 0px;
    clip: rect(0px, 0px, 0px, 0px) !important;
    position: absolute !important;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  -webkit-clip-path: inset(50%);
  clip-path: inset(50%);
  border: 0;
}
.sr-only-focusable:active,
.sr-only-focusable:focus {
  position: static;
  width: auto;
  height: auto;
  overflow: visible;
  clip: auto;
  white-space: normal;
  -webkit-clip-path: none;
  clip-path: none;
}
