/*
 * width 641px is portrait tablets, portrait iPad
 */
@media (max-width: 640px) {
  body {
    width: 640px;
  }
}

/*************************************************
 *
 * access link
 *
 *************************************************/
@media (max-height: 345px) {
  .access-link {
    height: 335px;
  }
}

/*************************************************
 *
 * folder name length 
 *
 *************************************************/
@media (max-width: 562px) {
  table.list-of-all-file tr.uploading-file td:nth-child(3) {
    display: table-cell;
  }
  .table.list-of-all-file td .cancel-confirm span.text {
    display: none;
  }
}

@media (max-width: 768px) {
  .current-page-menu .btn i {
    padding-left: 0;
  }
  .setting:hover #setting-icon-hover {
    padding: 0px 28px 11px 10px;
  }

  .current-page-menu {
    padding-right: 0px;
  }

  .fix-scroll {
    position: relative;
  }
  .fix-to-top {
    position: fixed;
    top: 0;
  }
  .nav-side-menu.fix-to-top  {
    top: 0;
  }

  .main-menu-modal-trigger {
    display: inline;
    position: absolute;
    left: 15px;
    top: 20px;
    cursor: pointer;
  }

  .wrapper {
    padding-top: 0;
    margin-top: 0;
  }

  #header_inbox_bar .badge {
    right: -15px;
    top: -8px;
  }

  .notify-arrow.notify-arrow-yellow, .notify-arrow.notify-arrow-red {
    right: auto;
    left: 7px;
  }

  /* left side bar */
  #main-content {
    left: 70px;
    
    width: auto !important;
    /*z-index: 500;*/
    padding-top: 0 !important;
  }
  .nav-side-menu {
    width: 70px;
    overflow: hidden;
  }

  .nav-side-menu.expand {
    width: 200px;
  }

  .secondary-bar {
    left: 70px;
  }

  .nav-side-menu.expand .app-logo img.normal-size,
  .nav-side-menu .app-logo img.small-size {
    opacity: 1;
  }
  .nav-side-menu .app-logo img.normal-size,
  .nav-side-menu.expand .app-logo img.small-size {
    opacity: 0;
  }

  /*
   * hide menu text in left side bar 
   */
  .nav-side-menu .menu-list li {
    height: 35px;
  }

  .nav-side-menu .menu-list li a img {
    width: 28px;
    height: 28px;
  }
  .nav-side-menu .menu-list li a img.selected {
    border-bottom: 1px solid #7BAFC2;
    padding-bottom: 5px;
    width: 32px;
    height: 32px;
  }
  .nav-side-menu .menu-list li a span {
    display: none;
  }
  .user-profile .show-user-detail i.fa-chevron-circle-down {
    display: none;
  }
  .nav-side-menu .menu-list li {
    margin: 15px 0;
  }

  .nav-side-menu ul {
    padding-top: 20%;
  }
  .nav-side-menu-footer {
    position: relative;
    bottom: 50px;
    height: 50px;
    font-size: 25px;
    color: #FFF;
    text-align: center;
    z-index: 2;
  }

  /*.list-view-table {
    position: inherit;
    margin-top: 80px;
  }*/

  .main .modal-backdrop.fade.in {
    background-color: #808080;
  }
  .modal-body.app-modal.menu-list {
    padding: 0;
    height: 100%;
  }

  .modal-content {
    padding-left: 0;
  }

  .nav-side-menu .nav-header {
    height: 60px;
  }

  #header_notification_bar, #header_inbox_bar {
    position: absolute;
    left: 55px;
    top: 16px;
  }
  #header_inbox_bar {
    left: 95px;
  }

  /* middle header*/
  .breadcrumb .current-folder span {
    font-family: 'Open Sans', 'sans-serif';
  }

  .profile-header {
    border-top: 1px solid #D1D3D4;
  }

  .modal-error-message {
    /*height: 50px;*/
  }

  /* detail view --> last file */
  /*table.list-of-all-file.small-view tbody tr:last-child {
    height: 120px;
  }
  .table.list-of-all-file.small-view tbody tr:last-child td {
    vertical-align: super;
  }*/
  /* list view --> last file */
  /*table.list-of-all-file.small-view.list-view tbody tr:last-child {
    height: 90px;
  }*/
}

@media (min-width: 769px) {
  body {
    overflow: hidden;
  }

  .nav-side-menu .menu-list .menu-content {
    display: block;
  }

  .secondary-bar {
    left: 200px;
  }

  #main-content {
    left: 200px;

    width: auto !important;
    /*z-index: 500;*/
    padding-top: 0 !important;

    overflow-y: auto;
    overflow-x: hidden;
  }

  #main {
    overflow: hidden;
    height: 100%;
  }

  #main-view {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
  }

  #main-container {
    height: 100%;
  }

  .main-menu-modal-container {
    display: none !important;
  }
}

/*************************************************
 * 
 * hide button name on toolbar
 *
 *************************************************/
@media (max-width: 1250px) {
  .my-file-page .selected-item-toolbar .tool-group ul span {
    display: none;
  }

  .my-shared-drive-page .selected-item-toolbar .tool-group ul span {
    display: none;
  }
}

/*************************************************
 *
 * feedback information
 *
 *************************************************/
@media (max-width: 991px) {
  .modal-error-message {
    padding-left: 60px;
  }

  .storage-chart {
    padding: 0;
  }

  .modal-open .modal.push-delete-alert, .push-delete-alert .modal-content,
  .modal-open .modal.alert-modal, .alert-modal .modal-content,
  .modal-open .modal.information-warning, .information-warning .modal-content,
  .modal-open .modal.push-delete-link-alert, .push-delete-link-alert .modal-content,
  .modal-open .modal.setting-displayname, .setting-displayname .modal-content,
  .modal-open .modal.batch-information-warning, .batch-information-warning .modal-content {
    background: transparent;
  }
  .modal-open .modal, .modal-content {
    background: #FFF;
  }

  .app-modal {
    border-radius: 0;
    box-shadow: none;
  }

  .edit-field-slideup {
    top: -5px;
    margin-bottom: 30px
  }
}

/*************************************************
 *
 * edit profile
 *
 *************************************************/
@media (max-width: 644px) {
  .edit-profile, .edit-profile-input  {
    width: 100%;
  }
  .profile-detail li span.edit {
    font-family: 'Open Sans', 'sans-serif';
    font-size: 11px;
    font-style: italic;
    padding: 5px 0;
  }
}
@media (min-width: 645px) and (max-width: 821px) {
  .edit-profile, .edit-profile-input {
    width: 200px;
  }
  .edit-field-slideup .edit-profile-input {
    width: 100%;
  }
}

/*@media (min-width: 455px) and (max-width: 539px) {
  .cbox-progress {
    top: 112px;
    right: 30px;
  }
}
@media (max-width: 454px) {
  .show-page-number {
    position: absolute;
    top: 145px;
  }
  .cbox-progress {
    top: 128px;
    right: 50px;
  }
  .preview-file-tools-group {
    width: 332px;
  }
  ul.preview-file-tools li.select-point-color {
    border-left: 0;
    margin-left: 0;
    margin-left: -20px;
  }
}*/

/*************************************************
 *
 * comment box tool
 *
 *************************************************/
@media (max-width: 453px) {
  .pull-right.point-color>.dropdown-menu {
    left: 28px;
    right: auto;
  }
  .point-color ul:after {
    margin-right: 130px;
  }
  .preview-file-tools.comment-tools {
    margin-left: 20px;
  }
}


/************************************************* 
 * 
 * file list - hide/show column
 *
 *************************************************/
@media (max-width: 1000px) {
  table.list-of-all-file td:nth-child(4), 
  table.list-of-all-file th:nth-child(4), 
  table.list-of-all-file td:nth-child(3), 
  table.list-of-all-file th:nth-child(3) {
    display: none;
  }

  table.list-of-all-file td:nth-child(1), 
  table.list-of-all-file th:nth-child(1) {
    width: auto;
  }
}

@media (min-width: 850px) and (max-width: 1000px){ 
  table.list-of-all-file td:nth-child(2), 
  table.list-of-all-file th:nth-child(2) {
    width: 20%;
  }

  table.list-of-all-file td:nth-child(5), 
  table.list-of-all-file th:nth-child(5) {
    width: 20%;
  }
}

@media (max-width: 849px) { 
  table.list-of-all-file td:nth-child(5), 
  table.list-of-all-file th:nth-child(5) {
    display: none;
  }

  table.list-of-all-file td:nth-child(2), 
  table.list-of-all-file th:nth-child(2) {
    width: 25%;
  }

  .small-view .open-text {
    max-width: 260px;
  }

  .uploading-file .remaining-col {
    display: none;
  }
  /*.small-view td.share-mgnt-btn {
    width: 10%;
  }*/
}

@media (max-width: 562px) {
  table.list-of-all-file td:nth-child(2), table.list-of-all-file th:nth-child(2) {
    display: none;
  }

  .list-view tr.uploading-file .open-text {
    max-width: 160px;
  }

  .small-view .open-text {
    max-width: 390px;
  }
}

@media (max-width: 471px) {
  /* List view */
  table.list-of-all-file thead {
    color: transparent;
  }
  .table > thead > tr > th {
    border-bottom-color: transparent;
  }
  .table.list-of-all-file > tbody > tr > td span {
    padding-left: 10px;
  }
  .rename-row .newname-input {
    margin-left: 0;
  } 

  .list-view tr.uploading-file .open-text {
    max-width: 100px;
  }

}

@media (max-width: 400px) {
  .current-page-menu .fa.upload-file, 
  .current-page-menu .fa.add-collection, 
  .current-page-menu .download {
    margin-right: 10px;
  }
  .form-signin.register {
    margin-top: 50px;
  }
}

@media (max-width: 350px) {
  .current-page-menu .fa.upload-file, 
  .current-page-menu .fa.add-collection, 
  .current-page-menu .download {
    margin-right: 0;
  }

  .form-signin.register {
    margin-top: 0px;
  }
  .form-signin.register {
    margin-top: 0px;
  }
}


/*************************************************
 *
 * secondary tool (toolbar item)
 * file/folder/collection name 
 *
 *************************************************/

/* 
 * item name in toolbar and item name in file list
 */
@media (min-width: 1701px) and (max-width: 1708px) {
  .edit-mode .small-view .open-text {
    max-width: 430px
  }
}
@media (min-width: 1701px) {
  .selected-item-toolbar .selected-item-name {
    width: 730px;
  }
  .small-view .open-text {
    max-width: 430px
  }
}

@media (min-width: 1601px) and (max-width: 1700px){
  .selected-item-toolbar .selected-item-name {
    width: 610px;
  }
  .small-view .open-text {
    max-width: 400px
  }
}
@media (min-width: 1601px) and (max-width: 1622px){
  .edit-mode .small-view .open-text {
    max-width: 390px
  }
}

@media (min-width: 1501px) and (max-width: 1600px){
  .selected-item-toolbar .selected-item-name {
    width: 510px;
  }
  .small-view .open-text {
    max-width: 360px
  }
}
@media (min-width: 1501px) and (max-width: 1508px){
  .edit-mode .small-view .open-text {
    max-width: 360px
  }
}

@media (min-width: 1401px) and (max-width: 1500px){
  .selected-item-toolbar .selected-item-name {
    width: 420px;
  }
  .small-view .open-text {
    max-width: 320px
  }
}
@media (min-width: 1401px) and (max-width: 1422px){
  .edit-mode .small-view .open-text {
    max-width: 330px
  }
}

@media (min-width: 1301px) and (max-width: 1400px){
  .selected-item-toolbar .selected-item-name {
    width: 300px;
  }
  .small-view .open-text {
    max-width: 290px
  }
}
@media (min-width: 1301px) and (max-width: 1308px) {
  .edit-mode .small-view .open-text {
    max-width: 290px
  }
}

@media (min-width: 1201px) and (max-width: 1250px) {
  .selected-item-toolbar .selected-item-name {
    width: 600px;
  }
}

@media (min-width: 1251px) and (max-width: 1300px) {
  .selected-item-toolbar .selected-item-name {
    width: 260px;
  }
  .small-view .open-text {
    max-width: 260px
  }
}
@media (min-width: 1201px) and (max-width: 1222px){
  .edit-mode .small-view .open-text {
    max-width: 255px
  }
}

@media (min-width: 1101px) and (max-width: 1200px) {
  .small-view .open-text {
    max-width: 230px
  }
}
@media (min-width: 1101px) and (max-width: 1122px) {
  .edit-mode .small-view .open-text {
    max-width: 220px
  }
}

@media (min-width: 1001px) and (max-width: 1100px) {
  .small-view .open-text {
    max-width: 195px
  }
}
@media (min-width: 1001px) and (max-width: 1022px) {
  .edit-mode .small-view .open-text {
    max-width: 185px
  }
}

@media (min-width: 951px) and (max-width: 976px) {
  .edit-mode .small-view .open-text {
    max-width: 220px
  }
}
@media (min-width: 901px) and (max-width: 917px) {
  .edit-mode .small-view .open-text {
    max-width: 200px
  }
}
@media (min-width: 863px) and (max-width: 900px) {
  .edit-mode .small-view .open-text {
    max-width: 185px;
  }
}
@media (min-width: 850px) and (max-width: 862px) {
  .edit-mode .small-view .open-text {
    max-width: 180px
  }
}

/* 
 * item name in toolbar
 */
@media (min-width: 769px) and (max-width: 840px) {
  .selected-item-toolbar .selected-item-name {
    width: 240px;
  }
}
@media (min-width: 1151px) and (max-width: 1200px) {
  .selected-item-toolbar .selected-item-name {
    width: 500px;
  }
}
@media (min-width: 992px) and (max-width: 1150px) {
  .selected-item-toolbar .selected-item-name {
    width: 430px;
  }
}
@media (min-width: 841px) and (max-width: 991px) {
  .selected-item-toolbar .selected-item-name {
    width: 310px;
  }
}

@media (min-width: 646px) and (max-width: 764px) {
  .selected-item-toolbar .selected-item-name {
    width: 240px;
  }
}
@media (min-width: 500px) and (max-width: 645px) {
  .selected-item-toolbar .selected-item-name {
    width: 230px;
  }
}
@media (min-width: 400px) and (max-width: 499px) {
  .selected-item-toolbar .selected-item-name {
    width: 120px;
  }
}
@media (max-width: 399px) {
  .selected-item-toolbar .selected-item-name {
    width: 100px;
  }

  .move-tree {
    height: 250px;
  }
}

/* 
 * item name in file list
 */
@media (min-width: 951px) and (max-width: 1000px) {
  .small-view.list-view .open-text {
    max-width: 245px
  }
}
@media (min-width: 901px) and (max-width: 950px) {
  .small-view.list-view .open-text {
    max-width: 220px
  }
}
@media (min-width: 641px) and (max-width: 900px) {
  .small-view.list-view .open-text {
    max-width: 200px
  }
}
@media (min-width: 563px) and (max-width: 640px) {
  .small-view.list-view .open-text {
    max-width: 160px
  }
}

/*************************************************
 *
 * share modal
 *
 *************************************************/
@media (max-width: 836px) {
  .modal-body.share-modal {
    width: 850px;
  }

  .unshare-area .btn-cancel, .unshare-area .btn-remove{
    width: 60px;
  }

  .selected-user-table .permission-setting td.username .username .user-detail {
    width: 255px;
  }
}

@media (min-width: 837px) and (max-width: 880px) {
  .selected-user-table .permission-setting td.username .username .user-detail {
    width: 247px;
  }
}
@media (min-width: 881px) and (max-width: 940px) {
  .selected-user-table .permission-setting td.username .username .user-detail {
    width: 261px;
  }
}
@media (min-width: 941px) and (max-width: 991px) {
  .selected-user-table .permission-setting td.username .username .user-detail {
    width: 281px;
  }
}

@media (min-width: 992px) and (max-width: 1070px) {
  .selected-user-table .permission-setting td.username .username .user-detail {
    width: 244px;
  }
}
@media (min-width: 1071px) and (max-width: 1170px) {
  .selected-user-table .permission-setting td.username .username .user-detail {
    width: 268px;
  }
}
@media (min-width: 1171px) and (max-width: 1199px) {
  .selected-user-table .permission-setting td.username .username .user-detail {
    width: 294px;
  }
}

@media (min-width: 1200px) and (max-width: 1300px) {
  .selected-user-table .permission-setting td.username .username .user-detail {
    width: 236px;
  }
}
@media (min-width: 1301px) and (max-width: 1400px) {
  .selected-user-table .permission-setting td.username .username .user-detail {
    width: 260px;
  }
}
@media (min-width: 1401px) and (max-width: 1500px) {
  .selected-user-table .permission-setting td.username .username .user-detail {
    width: 280px;
  }
}
@media (min-width: 1501px) and (max-width: 1600px) {
  .selected-user-table .permission-setting td.username .username .user-detail {
    width: 303px;
  }
}

/*************************************************
 *
 * set modal : top position 
 *
 *************************************************/
@media (max-height: 300px) {
  .modal-body {
    top: 150px;
  }
}
@media (max-height: 400px) {
  .modal-body.rename-modal,
  .modal-body.create-shared-drive-modal {
    top: 200px;
  }
}
@media (max-height: 455px) {
  .manage-version-modal .modal-body {
    top: 225px;
  }
}
@media (max-height: 550px) {
  .modal-body.share-modal {
    top: 310px;
  }

  .modal-body.instant-share-modal {
    top: 277px;
  }
}
@media (max-height: 630px) {
  .modal-body.move-modal {
    top: 305px;
  }
}

@media (max-height: 250px) {
  .modal-body.restore-modal {
    top: 125px;
  }
}

@media (max-width: 600px) {
  /*.modal-body.share-modal {
    width: 600px;
  }*/
}

/*************************************************
 *
 * create new TD
 *
 *************************************************/
@media (max-width: 880px) {
  .list-view .create-item.folder td {
    height: 41px;
  }

  .list-view .create-item.thumbdrive input[type="text"] {
    left: 40px;
  }
  .list-view .create-item.folder input[type="text"] {
    margin-left: 40px;
  }

  .cancel-create-button {
    padding: 10px 15px 15px 15px;
  }
}

/*************************************************
 *
 * uploading failed
 *
 *************************************************/
@media (min-width: 769px) and (max-width: 910px) {
  .uploading-file .upload-failed-detail .cancel-confirm {
    width: 85px;
    right: -27px;
  }
  .uploading-file .upload-failed-detail p {
    width: 95px;
  }
}