/*
Theme Name: NE WP Master 2
Description: WordPress Master for New Element
Author: New Element AS
Author URI: https://www.newelement.no
Template: flatsome
Version: 3.0.3
*/

/*************** ADD CUSTOM CSS HERE.   ***************/


@media only screen and (max-width: 48em) {
/*************** ADD MOBILE ONLY CSS HERE  ***************/


}


div#header_main_alternate {
    background-color: #3e3d3d;

}

#header_main {
    border-top-color: transparent;
}

#top .header_color input[type="text"], .header_color .ajax_search_excerpt{
    color:#3e3d3d;
}

.avia-search-tooltip, .avia-arrow{
    border-color:#d1cdcd !important;
}
.header_color .avia-menu-fx{
    background-color:#97989b;
}

div#header_main_alternate, #header_main {

    border-bottom-color:#3e3d3d;
}
.header_color .av-subnav-menu a:hover, .header_color .main_menu ul:first-child > li a:hover, .header_color .main_menu ul:first-child > li.current-menu-item > a, .header_color .main_menu ul:first-child > li.current_page_item > a, .header_color .main_menu ul:first-child > li.active-parent-item > a {

    color: #fff;

}

.html_av-overlay-side-classic #top #wrap_all .av-burger-overlay #av-burger-menu-ul li a {
    border-color: #f0f0f0;
}

/* cookie notice text fix*/
#cn-notice-text{
    color:#fff !important;
}

/* title Bar */
.title_container { background-color: #1967ab!important; }
.alternate_color .breadcrumb, .alternate_color .breadcrumb a, #top .alternate_color.title_container .main-title, #top .alternate_color.title_container .main-title a {
    color: #fff;
}

/* Icon List Title */
.avia-icon-list .iconlist_title {
    text-transform: none !important;
}


/* Terminliste */
.termi-head{
	background-color:#377bb6;
	padding:0 10px;
	margin-bottom:2px;
}

.termi-head h2{
	color:#fff;
	font-size:12px;
	text-align:left;
	line-height:30px;
	text-transform:uppercase;
	height:30px;
	background:#377bb6;
}

.temin-cont{
	border-bottom:1px solid #e9e9e9 !important;
}

.termi-inn{
	width:100%;
	clear:both;
	display:flex;
	align-items:stretch;
	border-right:1px solid #e9e9e9;
	border-top:1px solid #e9e9e9;
	background:transparent;
}

.termi-inn:nth-child(2n){
	background:transparent;
}

.termi-l{
	width:70px;
	min-width:70px;
	max-width:70px;
	flex:0 0 70px;
	float:none;
	background:#005CA9;
	text-align:center;
	font-size:11px;
}

.termi-l table{
	width:100%;
	height:auto;              /* viktig */
	margin:0;
	border-collapse:collapse;
	table-layout:fixed;
	background:#005CA9;
}

.termi-l table tbody,
.termi-l table tr{
	height:auto;              /* viktig */
}

.termi-l table td{
	background-color:#005CA9 !important;
	border:0;
	color:#d1d1d1;
	text-align:center;
	vertical-align:top;
	padding:0;
	line-height:1.1;
	font-size:11px;
}

/* Første rad = selve datoen */
.termi-l table tr:first-child td{
	padding:15px 0 2px 0;
}

/* Andre rad = måned + år */
.termi-l table tr:last-child td{
	padding:0 0 6px 0;
	line-height:1.05;
}

.termi-l span{
	display:block;
	margin:0;
	line-height:1;
	font-size:20px;
	font-weight:bold;
	color:#fff;
}

/* litt tettere på måned/år */
.termi-l table tr:last-child td br{
	line-height:1;
}

.termi-r{
	flex:1 1 auto;
	width:auto;
	min-width:0;
	float:none;
	padding:10px 8px 10px 10px;
	font-size:12px;
	background:#fff;
}

.termi-r h3{
	font-size:18px;
	font-weight:600;
	margin-bottom:4px;
}

.termi-r h4{
	font-size:13px;
	font-weight:600;
	text-transform:uppercase;
	margin-bottom:8px;
}



/* widgettitle style */
.widgettitle {
    border:0 !important;
    font-weight:400 !important;
    font-size: 20px !important;
    font-family:"Lato","HelveticaNeue","Helvetica Neue",Helvetica,Arial,sans-serif !important;
    text-transform:initial ;
    margin: 0 0 15px 0 !important;
    padding: 0 0 0px 0 !important;
    clear:both;
    float:none;
    display: inline-block !important;

}

.avia-content-slider{ margin:10px 0 30px 0; }

/* ajax search */

/* faltsome hack to make last colum auto width so the search box is not pushed to the center of the screen. */
#top-bar > .flex-row.container > .flex-col:last-child{
  flex: 0 auto !important;;
  padding-left: 20px;
}

#ajaxResults,
.ponni-search-results{
    background-color:#fff;
    position:absolute;
    width:100%;
    right:0; left:0;
    top: calc(100% + 6px);
    max-height:300px;
    overflow:auto;
    box-shadow:0 8px 24px rgba(0,0,0,0.25);
    border: 1px solid rgba(2, 27, 61, 0.18);
    border-radius: 8px;
    margin-top: 0;
    z-index:1100;
    line-height:22px !important;
    padding: 6px 0;
}

.ajax-result-table{
    width: 100%;
    margin: 0 !important;
    border-collapse: separate;
    border-spacing: 0;
    color:#4f4f4f !important;
    font-size: 15px;
}

.ajax-result-table tr:nth-child(2n){
    margin:0 !important;
    color:#4f4f4f !important;
}

.ajax-result-table td{
    padding: 12px 14px;
    border-bottom: 1px solid #eceff3;
    background: #fff;
    transition: background-color .18s ease, color .18s ease;
}

.ajax-result-table td:first-child{
    font-weight: 600;
    width: 80% !important;
}

.ajax-result-table tr:last-child td{
    border-bottom: 0;
}
.ajax-result-table span{
    display: inline-block;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .02em;
    border-radius: 999px;
    background-color:#f1f4f8;
    border:1px solid #d7dde6;
    padding:4px 10px;
    color:#516172 !important;
}
.ajax-result-table tr{
    cursor:pointer;
}
.ajax-result-table tr[data-href]:focus{
    outline: 2px solid #8fc7ff;
    outline-offset: -2px;
}
.ajax-result-table tr:hover{
    background-color:#f3f8ff;
}

.ajax-result-table tr:hover td{
    background-color:#f3f8ff;
}
.ajax-result-table .search-result-link{
    display: block;
    color: inherit !important;
    text-decoration: none !important;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.ajax-result-table td:first-child {
    width: 100%;
    max-width: 0;
}

#ajaxResults::-webkit-scrollbar,
.ponni-search-results::-webkit-scrollbar {
    width: 10px;
}

#ajaxResults::-webkit-scrollbar-thumb,
.ponni-search-results::-webkit-scrollbar-thumb {
    background: #c5ccd5;
    border-radius: 8px;
    border: 2px solid #fff;
}
.searchMsg,
#searchLoader,
.ponni-search-loader{
    padding:10px;

}
#searchFormPonni,
.ponni-search-form {
    margin: 0;
}

#searchFormPonni #searchTxt,
.ponni-search-form .ponni-search-input {
    width: clamp(220px, 28vw, 360px);
    height: 38px;
    margin: 0;
    padding: 0 14px;
    color: #fff !important;
    background-color: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.35) !important;
    border-radius: 6px;
    transition: border-color .2s ease, box-shadow .2s ease, background-color .2s ease;
}

#searchFormPonni #searchTxt:hover,
.ponni-search-form .ponni-search-input:hover {
    background-color: rgba(255, 255, 255, 0.12);
}

#searchFormPonni #searchTxt:focus,
.ponni-search-form .ponni-search-input:focus {
    outline: none;
    background-color: rgba(255, 255, 255, 0.18);
    border-color: #8fc7ff !important;
    box-shadow: 0 0 0 3px rgba(79, 166, 255, 0.28);
}

input#searchTxt::-webkit-input-placeholder, input#s::-webkit-input-placeholder,
.ponni-search-input::-webkit-input-placeholder{
    color: rgba(255, 255, 255, 0.72) !important;
}
input#searchTxt::placeholder, input#s::placeholder,
.ponni-search-input::placeholder{
    color: rgba(255, 255, 255, 0.72) !important;
}
input#searchTxt:-ms-input-placeholder, input#s:-ms-input-placeholder,
.ponni-search-input:-ms-input-placeholder { /* IE 10+ */
  color: rgba(255, 255, 255, 0.72) !important;
}

.header-top .header-block,
.header-main .header-block {
    padding: 6px 10px;
}

/* tables */
.main_color tr:nth-child(2n){
    color:#b5c8d8;
}
table.dataTable.no-footer {
    border-bottom: none;
}

table.dataTable thead th, table.dataTable thead td {

    border-bottom: 1px solid #9d9d9e;
}

#racelist_table_length, #racelist_table_filter{
    display:none;
}
table.dataTable.dtr-inline.collapsed > tbody > tr > td:first-child::before, table.dataTable.dtr-inline.collapsed > tbody > tr > th:first-child::before {
    top: 9px;
    left: 4px;
    height: 16px;
    width: 18px;
    display: block;
    position: absolute;
    color: #fff;
    border: 1px solid #377ab5;
    border-radius: 4px;
    box-shadow: 0 0 3px #eee;
    box-sizing: content-box;
    text-align: center;
    font-family: 'Courier New', Courier, monospace;
    line-height: 14px;
    content: '+';
    font-size: 20px;
    padding: 3px 0px 0px 0px;
    background-color: #377ab5;
}
table.dataTable.dtr-inline.collapsed > tbody > tr.parent > td:first-child::before, table.dataTable.dtr-inline.collapsed > tbody > tr.parent > th:first-child::before {
    content: '-';
    background-color: #377ab5;
}

tr.group td:before{
    display:none !important;
}
.table_condensed{
    font-size:10px !important;
    border:none !important;
    width:60%;
    min-width:400px;


}
.table_condensed td{
    border:none !important;
    padding:0px 4px 0px 4px;
    background-color:#fff;
    font-size: 0.9rem;
    line-height: 130%;
}
.table_condensed tr td:first-child{
    text-align:right;
    border-right:1px solid #ccc !important;
}


/* header widget css */
#header .widget {
    left: 50%;
    padding-top: 0;
    position: absolute;
    top: 0;
    transform: translate(-50%);
    z-index: 100;
    padding-left: 0px;
    padding-top: 20px;
    margin-left: 400px;
    right: 0;
    padding-right: 440px;
}


@media only screen and (max-width: 990px) {

    .ponni_search_widget{
        display: block !important;
        position: relative !important;
        width: 100% !important;
        padding: 10px !important;
        top: 159px !important;
        margin-top: -65px !important;
        margin: -65px 0 0 0 !important;
    }
    /* #main{
        margin-top: 55px !important;
    } */

    #searchFormPonni #searchTxt,
    .ponni-search-form .ponni-search-input {
        width: 100%;
        margin-bottom: 10px;
    }
}

.top-hero-logo{ width:160px;}


/* footer icons */
#footer-icons .slide-entry-wrap{
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 40px;
    padding: 0;
    text-align: center;
}
@media only screen and (max-width: 767px) {
    #footer-icons .slide-entry-wrap{
        display: block;

    }

     #footer-icons .slide-entry-wrap .slide-entry{
        width:45% !important;
        float:left !important;
    }
}

/* single masonry for top post  */
.av-masonry-col-2 .av-masonry-container > a {
    /* Apply styles to article > p:first-of-type, which may or may not be :first-child */
    width: 100% ;

}

.av-masonry-col-2 .av-masonry-container > a ~ a {
    /* Undo the above styles for every subsequent article > p */
    width:50%;

}
.av-masonry-col-2 .av-masonry-container > a .av-masonry-entry-title{
    /* Apply styles to article > p:first-of-type, which may or may not be :first-child */
     font-size:26px !important;
}

.av-masonry-col-2 .av-masonry-container > a ~ a .av-masonry-entry-title{
    /* Undo the above styles for every subsequent article > p */
     font-size:16px !important;
}
.av-inner-masonry-content-pos-content{
    position:absolute;
    bottom:8px;
    text-align:left;
}

.av-inner-masonry-content-pos-content .av-masonry-entry-title{
    background-color:#005baa;
    padding:2px 10px;
    margin-right:10px;

}

.av-inner-masonry-content-pos-content .av-masonry-date{
    background-color:black;
    padding:2px 4px;
    margin-right:10px;
    clear:both;

}
#top .av-caption-style-overlay .av-masonry-item-with-image .av-inner-masonry-content {
    /*background: rgba(255, 255, 255, 0.1) !important;*/
}
#top .av-caption-style-overlay .av-masonry-item-with-image .av-inner-masonry-content:hover {
    background: transparent !important;
}

@media only screen and (min-width: 768px) and (max-width: 989px) {

    .responsive.av-no-preview #top .av-medium-columns-3 .av-masonry-entry{width:100%;}
    .av-inner-masonry-content-pos-content .av-masonry-entry-title{
        background-color:red;
        padding:2px 10px;
        margin-right:10px;
         font-size:18px;
    }

}
@media only screen and (max-width: 768px) {
    .av-masonry-col-2 .av-masonry-container > a .av-masonry-entry-title{
    /* Apply styles to article > p:first-of-type, which may or may not be :first-child */
     font-size:16px !important;
    }
}

/* special headings */
.bg.av-special-heading > *, #main .widgettitle{
   /* color: #ffffff !important;
    background-color: #333;
    display: inline;
    clear: both;
    padding: 2px 8px !important;*/

}
#footer .widgettitle{
    /* override above */
    /*color: #ffffff inherit;
    background-color: transparent;*/
}
#footer .attachment-no.scaling.size-no {
    max-width: 120px;
}

.mini-list{
    margin-top: 10px;
}


.mt10{
     margin-top:10px !important;
}


#top .avia-button-fullwidth {
    padding: 14px;
    font-size: 1.5em;
}

body .terminliste .column-top-margin {
    margin-top: 10px !important;
}

#top .ui-datepicker-title select{
    margin-left: 2px;
}

.ui-datepicker th {
    padding: 3px;
    text-align: center;
}

/* override enfold styling */
.custom-select {

    display: inline-block !important;
    width: 100% !important;
    height: calc(2rem + 0px) !important;
    padding: .375rem 1.75rem .375rem .75rem !important;
    line-height: 1.5 !important;
    color: #495057;
    vertical-align: middle;
    background: #fff url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 4 5'%3E%3Cpath fill='%23343a40' d='M2 0L0 2h4zm0 5L0 3h4z'/%3E%3C/svg%3E") no-repeat right .75rem center !important;
        background-size: auto;
    background-size: 8px 10px !important;
    border: 1px solid #ced4da !important;
    border-radius: 0rem !important;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none !important;

}

/* Cookie Notice */
#cookie-notice .cn-button {
    color: white !important;
    background-color: #021b3d;
}

.dataTable{
    border: 1px solid #dee2e6;
    border-collapse: collapse;
    border-spacing: 0;
}

.dataTable tr:nth-child(2n+1) {
    background: rgb(248, 248, 248);
}

.dataTable th,
.dataTable td {
    padding: 0.5rem 0.75rem;
    border-right: 1px solid #dee2e6 !important;
    border-bottom: 1px solid #dee2e6 !important;
}

.dataTable tr > *:last-child {
    border-right: 0 !important;
}

.dataTable tbody tr:last-child > * {
    border-bottom: 1px solid #dee2e6 !important;
}

#table_data_wrapper, #raceinfo_table, #racelist_table{
    font-size: 0.9rem;
}

/* Show races filter layout */
.page-template-template-show-races #filter_form_races fieldset {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

.page-template-template-show-races #filter_form_races .form_element {
    margin: 0;
}

.page-template-template-show-races #filter_form_races label {
    display: block;
    margin-bottom: 0.5rem;
}

.page-template-template-show-races #filter_form_races select,
.page-template-template-show-races #filter_form_races input[type="text"] {
    width: 100%;
}

.page-template-template-show-races #filter_form_races .filter_do {
    margin-top: 0.25rem;
}

@media (min-width: 1024px) {
    .page-template-template-show-races #filter_form_races fieldset {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        align-items: end;
    }

    .page-template-template-show-races #filter_form_races fieldset > .form_element:last-child {
        grid-column: 1 / -1;
    }
}

/*hide sidebar on print */
@media print {
    .page-template-template-show-info .row.row-large.row-divided > .large-3.col,
    .page-template-template-show-races .row.row-large.row-divided > .large-3.col,
    .page-template-template-show-raceinfo .row.row-large.row-divided > .large-3.col {
        display: none !important;
    }

    .page-template-template-show-info .row.row-large.row-divided > .large-9.col,
    .page-template-template-show-races .row.row-large.row-divided > .large-9.col,
    .page-template-template-show-raceinfo .row.row-large.row-divided > .large-9.col {
        flex: 0 0 100% !important;
        max-width: 100% !important;
        width: 100% !important;
    }
}

/* Show report filter layout */
.page-template-template-show-report #filter_form_races fieldset {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

.page-template-template-show-report #filter_form_races .form_element {
    margin: 0;
}

.page-template-template-show-report #filter_form_races label {
    display: block;
    margin-bottom: 0.5rem;
}

.page-template-template-show-report #filter_form_races select,
.page-template-template-show-report #filter_form_races input[type="text"],
.page-template-template-show-report #filter_form_races input[type="number"] {
    width: 100%;
}

.page-template-template-show-report #filter_form_races .filter_do {
    margin-top: 0.25rem;
}

@media (min-width: 1024px) {
    .page-template-template-show-report #filter_form_races fieldset {
        grid-template-columns: repeat(4, minmax(0, 1fr));
        align-items: end;
    }

    .page-template-template-show-report #filter_form_races fieldset > .form_element:last-child {
        grid-column: 4;
    }
}

/* Reusable top spacing for template main content */
.ponni-content-top-pad {
    padding-top: 2rem; 
}

/* =========================================================
   OVERRIDES: Terminliste (KUN siden med slug/klasse page-terminliste)
   - Kun dato-feltet blått
   - Smalere dato-kolonne
   - Tekst sentrert
   - Toppjustert dato
   ========================================================= */

   body.page-terminliste .termi-inn{
	background-color: transparent !important; /* fjerner blå bakgrunn på hele raden */
}

body.page-terminliste .termi-inn:nth-child(2n){
	background-color: transparent !important; /* fjerner zebra-blå på hele raden */
}

/* sørg for at flex-raden ikke "viser" blått felt til høyre */
body.page-terminliste .termi-inn{
	display:flex;
	align-items:flex-start;
}

body.page-terminliste .termi-l{
	width:65px !important;
	min-width:65px !important;
	text-align:center;
	align-self:flex-start;
}

body.page-terminliste .termi-l table{
	margin:0 auto;
}

body.page-terminliste .termi-l td{
	text-align:center;
}

/* Innhold skal fylle resten (hindrer rare felt) */
body.page-terminliste .termi-r{
	flex:1 1 auto;
	min-width:0;
	width:auto !important; /* overstyrer 80% kun på denne siden */
	background:#fff;
}