/* mobile phones responsive
-------------------------------------------------*/

/*
  /* I need to use a CSS guard .when 
  http://lesscss.org/features/#css-guards-feature
  
@media screen and (min-width: 1100px){
  #header, #wrapper { background-size: contain; }
  ul#nav { position: relative; top: 0.35em; }
  form#dw__search { bottom: 70px; }
}
*/

@media screen and (max-width: 1000px) {
	body {
		width: unset;
	}
}

@media screen and (max-width: 500px) {
	#nav li { clear: both; float: none; padding: 2px; }
	#nav {
		background: url('images/menuback.png') repeat center bottom;
		background-size: cover;
		padding: 8px 0px;
		position: static;
		/*padding: 30px 10px 110px;*/
	}
	#nav li:hover a {
		background: url('images/nav-bg.png') repeat right -85px;
	}
	#wrapper { overflow: auto; }
	#content { width: 70%; }
	.post-data span { margin-bottom: 8px; display: block; }
	ul li { margin: 1em 0px !important; }
	button { margin: 6px 8px; }
	button img { padding: 3px; }
	textarea { font-family: 'Courier New', 'Courier', monospace; }
	.notify { width: 75% !important; }
}

@media screen and (max-width: 480px) {
	#content { width: 100%; padding: 0px 1em; margin: 0px; box-sizing: border-box; }
}


/* media manager and config manager for mobile */

#config__manager fieldset { background-color: transparent; }

@media screen and (max-width: 480px){
  fieldset, 
  #mediamanager__page, 
  #mediamanager__page .filelist{ 
    max-width: 100%; min-width: unset; 
  }
  #mediamanager__page .file, 
  #mediamanager__page .namespaces, 
  #mediamanager__page .panel { 
    width: 100%; clear: both; float: none;
  }

/* #mediamanager__page .namespaces { min-width: unset; } */

  /*.page li, .page dd { margin: 1.35em 0px !important; display: block; }*/
  #config__manager tr { }
  #config__manager td { display: block;  padding: 1.15em 0px; max-width: 75%;  }
  #config__manager fieldset {  margin: 1em 0px; width: 100%; box-sizing: border-box; }

     /* make <select> not exceed it's parent div's width */
    /* https://stackoverflow.com/q/44810056/337306 */
    div.input, label.nowrap { display: flex; } select { width: 100%; flex-shrink: 1; }

  fieldset { width: unset; }
  #config__manager fieldset td.value { width: unset; }
  td.label { word-wrap: anywhere; }

  #config__manager td .input, 
  #config__manager fieldset td.value, 
  input, textarea,
  #config__manager td input.edit,
  #config__manager td textarea.edit { 
    max-width: 100%; 
    width: auto;
  }
}

