@media
only screen and (max-width: 760px),
(min-device-width: 768px) and (max-device-width: 1024px)  {

	/* Force table to not be like tables anymore */
	body:not(.cke_editable) .contenttable,
    body:not(.cke_editable) .contenttable thead,
    body:not(.cke_editable) .contenttable tbody,
    body:not(.cke_editable) .contenttable th,
    body:not(.cke_editable) .contenttable td,
    body:not(.cke_editable) .contenttable tr,	
	body:not(.cke_editable) .frame-default table,
    body:not(.cke_editable) .frame-default table thead,
    body:not(.cke_editable) .frame-default table tbody,
    body:not(.cke_editable) .frame-default table th,
    body:not(.cke_editable) .frame-default table td,
    body:not(.cke_editable) .frame-default table tr {
		display: block;
	}
	/* Hide table headers (but not display: none;, for accessibility) */
	.contenttable thead tr,
	.frame-default table thead tr {
		position: absolute;
		top: -9999px;
		left: -9999px;
	}

	.contenttable tr,
	.frame-default table tr { border: 1px solid #ccc; }

	.contenttable td,
	.frame-default table td {
		/* Behave  like a "row" */
		border: none !important;
		border-bottom: 1px solid #eee;
		position: relative;
		padding-left: 40%;
		width: auto;
	}
	.event-table td {
		padding: 10px;
		line-height: 1.2;
	}
	.event-table td + td {
		padding-top: 0;		
		margin-top: -5px;
	}
	.contenttable td:before,
	.frame-default table td:before {
		/* Now like a table header */
		position: absolute;
		/* Top/left values mimic padding */
		top: 10px;
		left: 10px;
		width: 35%;
		padding-right: 10px;
		white-space: nowrap;
		font-weight: bold;
	}
	.event-table td:before {
		display: none;
	}
	/*
	Label the data
	*/
    .contenttable td:before,
    .frame-default table td:before { content: attr(data-label); }

    .fpa label[for="date"] {
	  display: block; 
     }

}



/* kleine Bildschirme */
@media (max-width: 1320px) {
  #iconnav {
  	padding-left: 5px;
  	top: 140px;
  }
	#bahnenlogos > a {
		width: 300px;
	  height: 75px;
	}
	#bahnenlogos > a:hover,
	#bahnenlogos > a:focus {
	  background-position: 0 -75px;
	}	

}
@media (max-width: 1140px) {
	.infobox {
 	  position: relative;
	  top: 0;
	  left: 0;
	  margin: 5%;
	  max-width: 90%;
		width: 100%;
	  border: 1px solid #999;
	}	
	#familienfreundlich {
		width: 12%;
		top: -4%;
	}
	#familienfreundlich:hover {
		top: -3%;
	  }	
	#nav_button {
		left: 10px;
		width: 40px;
		overflow: hidden;
		text-indent: -10000px;
		margin-right: 30px;
	}
	#sb_kontakt,
	#sb_shop,
	#sb_anfahrt,
	#sb_news {
		display: none;
	}
    #iconnav {
      top: 250px;
      position: absolute;
    }
}

@media (max-width: 960px) {
	#page > header {
		height: 60px;
	}
	nav {
		padding-top: 10px;
	}
	a#home_link img {
		max-height: 80px;
	}
	#titletext {
		display: none;
	}
	#langmenu {
		padding-top: 20px;
	}
	#megamenu {
		top: 60px;
		background: #FFF;
		box-shadow: 0 0 10px rgba(0,0,0,0.2);
	}
	#megamenu > ul > li,
	#megamenu > ul > li:first-child {
	  width: 50%;
	  margin-bottom: 15px;
	}
	#megamenu > ul > li:nth-child(2n+1) {
		clear: left;
	}


	#bahnenlogos > a {
	  width: 200px;		
	  height: 50px;
	}
	#bahnenlogos > a:hover,
	#bahnenlogos > a:focus {
	  background-position: 0 -50px;
	}	

  

	.infobox {
	  font-size: 90%;
	} 
	.infobox .symbol {
	  font-size: 200%;
	}
	.infobox .bahnname {
	  font-size: 150%;
	  margin-top: 3px;
	}

	.frame-type-menu_sitemap > ul > li {  	  
  	  width: 50%; 
  	  margin-bottom: 30px;
	}	

	footer .frame-type-menu_subpages a {
	  display: block;
	  padding: 3px 0;
	}	
}
@media (max-width: 767px) {

  #iconnav {
    top: 200px;
  }	

  #content {
  	font-size: 1.6rem;
  }

  .ce-textpic.ce-left.ce-intext .ce-gallery,
  .ce-textpic.ce-right.ce-intext .ce-gallery {
    max-width: 40%;
  }

  #page .powermail_label,
  #page .powermail_field,
  #page .powermail_radio_outer,
  #page .powermail_captcha_outer,
  #page .powermail_check_outer,
  #page .powermail_fieldwrap_file_inner ul:not(.parsley-errors-list) {
    float: none;
    width: 100%;
  }
  #page .powermail_submit {
    width: 50%;
    max-width: 100%;
    margin-left: 0 !important;
  }
  #page .parsley-errors-list li {
    margin-left: 0;
  }
  #page .powermail_fieldwrap.layout1,
  #page .powermail_fieldwrap.layout2 {
    float: none;
    width: 100%;
    margin: 0%;
  }
  select,
  textarea,
  input {
    width: 96%;
  }
  .g-recaptcha {
    margin-left: 0%;
  }
  input#saddr,
  input#addr_submit {
    float: none;
    width: 100%;
  }
  input#addr_submit {
    width: 50%;
    max-width: 100%;
    margin-left: 0% !important;
  }
  footer h3 {
	margin-top: 20px;
  	font-size: 120%;
  }

  footer h3.header {
    cursor: pointer;
  }
  footer h3.header:hover,
  footer h3.header:focus {
	text-decoration: underline;
  }
  footer h3.header:after {
	display: inline-block;
    padding-left: 5px;
    font-family: 'Font Awesome 5 Free';
	font-weight: 900;	
    font-size: 70%;
    content: "\f054";
    position: relative;
    top: -1px;
  }  
  footer .open > h5.header:after {
    content: "\f078";
    top: -2px;
  }
  footer .content {
  	display: none;
  	transition: all 300ms ease;
	margin-bottom: 40px;
  }
  footer .open .content {
  	display: block;
  }

  footer .h4 {
  	font-size: 150%;
  }
}
@media (max-width: 640px) {
	#familienfreundlich {
	  height: 70px;
	  width: 80px;
	  right: 15%;
	}
	#bahnenlogos > a {
	  display: block;
	  width: 400px;
	  height: 80px;
	  margin: 0 auto 30px;
	}
	#bahnenlogos > a:hover,
	#bahnenlogos > a:focus {
	  background-position: 0 0;
	}	
	#bahnenlogos > a#homelogo_fbb {
	  background-image: url('gfx/logohome_fbb_mobil.png');
	}
	#bahnenlogos > a#homelogo_lgb {
	  background-image: url('gfx/logohome_lgb_mobil.png');
	}
	#bahnenlogos > a#homelogo_wtb {
	  background-image: url('gfx/logohome_wtb_mobil.png');
	}		
    #iconnav {
      top: 170px;
    }		
	#megamenu > ul > li,
	#megamenu > ul > li:first-child {
	  width: 100%;
	}
    #megamenu > ul > li, #megamenu > ul > li:first-child {
      margin-bottom: 0;
    }
    #megamenu > ul > li > a {
      font-size: 120%;
      padding-bottom: 10px;
    }
	#megamenu li.ifsub > a::after {
	  display: inline-block;
	  padding-left: 15px;
	  font-family: 'Font Awesome 5 Free';
	  font-weight: 900;	  
	  font-size: 70%;
	  content: "\f054";
	}
	#megamenu li.ifsub.open > a::after {
	  content: "\f078";
	}	
	/* 2. Ebene einklappen */
	#megamenu li > ul,
	#megamenu li:hover > ul,
	#megamenu li.active > ul {
	  height: auto;
	  max-height: 0;
	  padding: 0;
	  padding-left: 0;
	  opacity: 1;
	  visibility: visible;
	  overflow: hidden;
	  -webkit-transition: all 0.5s ease-in-out;
		 -moz-transition: all 0.5s ease-in-out;
		  -ms-transition: all 0.5s ease-in-out;
		   -o-transition: all 0.5s ease-in-out;
			  transition: all 0.5s ease-in-out;
	}
	#megamenu li.open > ul {
	  max-height: 1000px;
	  padding-bottom: 10px;
	}
	#megamenu li > a {
	  padding: 5px 13px;
	  font-size: 1.4rem;
	  line-height: 1.2;	
	}
    .col-xxs-12 {
      width: 100%;
    }
	.event-detail .whitebox .image-wrap {
	  margin: 0 4% 20px 0;
	  width: 45%;
	}

	.whitebox, 
	.event-detail .daten,
	#page .powermail_fieldset,
	.news-single .content {
		padding: 20px;
	}
	.event-detail .daten {
		font-size: 1.4rem;
	}

	.news-list-view .teaser-text {
        min-height: auto;
  	}

    .homekachel .text > * {
        margin-bottom: 0;
    }

    .parallax p br {
        display: none;
    }

    footer {
      padding-top: 30px;
    }

	.fpa form > div {
	  float: none;
	  width: 100%;
	  margin-right: 0;
	}    
}
@media (max-width: 600px) {

}
@media (max-width: 480px) {
	
	#iconnav {
	  top: 118px;
	}
    #sb_suche {
      width: 40px;
      height: 40px;
    }
    #sb_suche .tx-indexedsearch-searchbox {
      left: 50px;
    }	
	a#home_link img {
	  /*max-height: 71px;*/
	}
	#megamenu {
	  padding: 20px;
	}

	h1 {
	  font-size: 175%;
	}
	h2 {
	  font-size: 150%;
	}
	h3 {
	  font-size: 120%;
	}	

	.frame-type-menu_sitemap > ul > li {  	  
	  float: none;
  	  width: 100%; 
  	  margin-bottom: 30px;
	}		
}
@media (max-width: 400px) {
	#bahnenlogos > a {
	  width: 300px;
	  height: 60px;
	}
}