.scrollImgFixed.foto1 { background-color: rgba(255,255,255,0); background-image: url('/cacheimg?q=75&zc=2&w=2000&src=/uploads/casas/ey/fincasgranvia/web/cabeceras/cabecera_administracioooon_de_fincas_y_gestioooon_inmobiliaria.jpg'); background-position: center center; background-repeat: no-repeat; height: 400px; /*padding-top: 250px; padding-bottom: 250px;*/ padding-right: 30px; padding-left: 30px; border-top-width: 0px; border-bottom-width: 0px; border-color: #eae9e9; border-top-style: solid; border-bottom-style: solid; -webkit-background-size: cover; -moz-background-size: cover; -o-background-size: cover; background-size: cover; background-attachment: fixed; position: relative; } @supports ( -webkit-touch-callout : none) { .scrollImgFixed.foto1 { background-attachment: scroll !important; background-position-x: 50% !important; } } @media only screen and (max-width: 1024px) { .scrollImgFixed.foto1 { background-image: url('/cacheimg?q=75&zc=1&w=1600&h=1000&src=/uploads/casas/ey/fincasgranvia/web/cabeceras/cabecera_administracioooon_de_fincas_y_gestioooon_inmobiliaria.jpg'); } } @media only screen and (max-width: 768px) { .scrollImgFixed.foto1 { background-image: url('/cacheimg?q=75&zc=1&w=1024&h=1000&src=/uploads/casas/ey/fincasgranvia/web/cabeceras/cabecera_administracioooon_de_fincas_y_gestioooon_inmobiliaria.jpg'); } } @media only screen and (max-width: 480px) { .scrollImgFixed.foto1 { background-image: url('/cacheimg?q=75&zc=1&w=800&h=600&src=/uploads/casas/ey/fincasgranvia/web/cabeceras/cabecera_administracioooon_de_fincas_y_gestioooon_inmobiliaria.jpg'); } } /* ============================== $-Modules ============================== */ /* ul-reset */ .ul-reset { padding-left: 0; margin-top: 0; margin-bottom: 0; list-style: none; } /* container */ .container { position: relative; top: 7.5vh; max-width: 46em; padding: 0.75rem; margin: auto; } /* ============================== $-Styles ============================== */ .description { text-align: center; } .nav-wrapper { margin: auto; text-align: left; font-size: 22px; } .nav-item-inner { border: 1px solid gray; margin: 10px 0; padding: 10px; } .nav .nav-sub-list { font-size: 15px; padding: 0 10px; line-height: 160%; } img.nav-item-icon { width: 50px; vertical-align: middle; margin-right: 20px; } /* jQuery Accordion Navigation Menu */ .nav-item { border-top: 1px solid rgba(255, 255, 255, 0.25); } .nav-item:first-child { border-top: none; } .nav-item-inner> a { display: block; } .nav-item-inner:hover { box-shadow: 0 0 10px #555; -moz-box-shadow: 0 0 10px #555; -webkit-box-shadow: 0 0 10px #555; -o-box-shadow: 0 0 10px #555; -o-ms-shadow: 0 0 10px #555; border: 1px solid #000000; } .nav-item-inner-heading { position: relative; padding: 0.75rem; padding-right: 2.5rem; font-weight: 700; } .nav-item-inner-heading:focus { opacity: 1; } .nav-item-inner-heading.minus:after, .nav-item-inner-heading.plus:after { position: absolute; top: 50%; right: 0.75rem; transform: translateY(-50%); width: 1rem; text-align: center; font-family: FontAwesome; font-style: normal; font-size: 0.6rem; color: GoldenRod; } .nav-item-inner-heading.minus:after { content: 068; } .nav-item-inner-heading.plus:after { content: 067; } .nav-sub-list { display: none; font-size: 0.8rem; overflow: hidden; } .nav-sub-list-inner { padding: 0 0.75rem 0.75rem; } .nav-sub-item { padding-left: 0.75rem; margin-top: 0.375rem; } .nav-sub-item:first-child { margin-top: 0; font-style: italic; } $(document).ready(function() { accordion('.nav-item', '.nav-item-inner-heading', '.nav-sub-list'); if(window.location.hash.replace(#,).split(_) == 'faq') { $(window.location.hash + .nav-item-inner).css(background-color,#f3f2eb) $(window.location.hash + .nav-sub-list).css(background-color,#f3f2eb) $(window.location.hash + .nav-item-inner).find(.nav-item-inner-heading).trigger(click); const element = document.querySelector(window.location.hash); const topPos = element.getBoundingClientRect().top + window.pageYOffset - 100; setTimeout(function() { window.scrollTo({ top: topPos, // scroll so that the element is at the top of the view behavior: 'smooth' // smooth scroll }); }, 20); } }); function accordion(section, heading, list){ $(section).each(function(){ var act = 'active', actClass = '.active', that = $(this); function tglH(){ that.find(list).slideToggle(250); } function open(click){ $(click).toggleClass('plus minus'); tglH(); that.find(list).addClass(act); } function close(click){ $(click).toggleClass('minus plus'); tglH(); that.find(list).removeClass(act); } if ( that.find(list).length == 0 ) { $(this).find(heading).removeClass('plus').addClass('no-sub'); } else { $(this).find(heading).click(function(e) { e.preventDefault(); }); } $(this).find(heading).click(function() { if ( $(this).hasClass('minus') ) { // close this menu close(this); that.find(list).removeClass(act); } else if ( $(this).hasClass('plus') ) { if ( $(heading).hasClass('minus') ) { $(heading).each(function(){ if ( !$(this).hasClass('no-sub') ) { $(this).removeClass('minus').addClass('plus'); } }) $(section).each(function() { if ( $(this).find(list).hasClass(act) ) { $(actClass).slideToggle(250); $(this).find(list).removeClass(act); } }); // open this menu open(this); } else if ( $(this).hasClass('plus') ) { // open this menu open(this); } } }) }) }