@charset "UTF-8";

@font-face {
  font-family: "font";
  src: url("data:application/font-woff;base64, ") format("woff");
}

/* ============================= Global styles ============================= */

body, div, a, header, input, label, li, nav, p, section, span, ul, figure, figcaption, img {
  box-sizing: border-box;
  font-size: 100%;
  font-weight: inherit;
  text-size-adjust: 100%;
  vertical-align: baseline;
  -webkit-touch-callout: none;
  margin: 0;
  padding: 0;
  border: 0;
}

svg { fill: currentColor }
button { color: inherit }
li { list-style: none }
a  { text-decoration: none; background: transparent }
:focus, a:active, a:hover { outline: none }
button, input { font-family: inherit; font-size: 100%; margin: none; line-height: normal; border: none }
button, input, select, textarea { font-family: inherit; font-size: 100%; margin: 0 }
button, input { line-height: normal }

::-moz-focus-inner { border: none; padding: none; outline: none }
::-moz-focus-outer { border: none }

::-webkit-scrollbar, ::-webkit-scrollbar-track { background: transparent }
::-webkit-scrollbar-thumb      { background: #888 }
::-webkit-scrollbar:horizontal { height: 4px }
::-webkit-scrollbar:vertical   { width:  4px }

::selection      { background: #05a; color: #fff }
::-moz-selection { background: #05a; color: #fff }

input::-moz-placeholder          { color: #999; opacity: 1 }
input:-ms-input-placeholder      { color: #999 }
input::-webkit-input-placeholder { color: #999 }

@media screen and (max-resolution: 1.99dppx) {
  .navigation, .path, .tip:before {
    -moz-osx-font-smoothing: grayscale;
    -webkit-font-smoothing: antialiased;
  }
}

/* =============================== Animations ============================== */

@keyframes nodeInserted {
  50% { opacity: .99 }
}
@keyframes jump {
  0%, 100% { transform: translateY(-3px) }
  50%      { transform: translateY(3px)  }
}
@keyframes shake {
  0%, 50%, 100% { transform: translateX(-5px) }
  25%, 75%      { transform: translateX(5px)  }
}
@keyframes spin {
  from { transform: rotate(0deg)   }
  to   { transform: rotate(359deg) }
}
@keyframes zoom {
  0%, 100%  { transform: scale(1.3) }
  50%       { transform: scale(.9)  }
}

/* ============================ Main Page Layout =========================== */

#flex-container {
  position: absolute;
  left: 0; right: 0; top: 0; bottom: 0;
  display: flex;
  flex-direction: column;
}

#navigation {
  background: #181818;
  text-align: center;
  order: 1;
  flex: 0 0 1.5rem;
  display: flex;
  white-space: nowrap;
  user-select: none;
}
@media (min-width: 1024px) { #navigation { font-size: 1.1em } }

/* ============================= Header Buttons ============================ */

.button {
  color: #888;
  line-height: 1.5rem;
  cursor: pointer;
  flex: 1;
}
.button:not(.disabled):hover { color: #fff; background: #1f1f1f }

@media (min-width: 751px) { .button { font-size: .66em } }
@media (max-width: 750px) { .button span { display: none } }

.button svg {
  height: .8rem;
  width: .8rem;
  margin-right: .2rem;
  position: relative;
  top: .15rem;
}
@media (max-width: 750px) { .button svg { margin-right: 0 } }

#upload-file-button:hover svg        { fill: rgba(102,166,255,1) }
#upload-folder-button:hover svg      { fill: rgba(255,102,252,1) }
#create-file-button:hover svg        { fill: rgba(102,255,235,1) }
#create-folder-button:hover svg      { fill: rgba(102,255,125,1) }
#about-button:hover svg              { fill: rgba(148,102,255,1) }
#prefs-button:hover svg              { fill: rgba(255,212,102,1) }
#logout-button:hover svg             { fill: rgba(255, 82, 82,1) }
#split-button:hover svg.split .left  { fill: rgba(255, 82, 82,1) }
#split-button:hover svg.split .right { fill: rgba(102,166,255,1) }

.button.disabled       { color: #444 !important; cursor: not-allowed !important }
.button.disabled:hover { color: #444 !important; background: transparent !important }
.button.disabled:hover svg { fill: #444 !important }

#view-container {
  flex: 1 1;
  order: 2;
  overflow-y: auto;
}

/* ================================== View ================================= */
.view {
  position: absolute;
  bottom: 0; left:0; right:0; top:1.5rem;
  display: flex;
  flex-direction: column;
  transition: left .2s ease, right .2s ease;
}

.content-container {
  position: relative;
  background: #111;
  overflow-x: hidden;
  flex: 1;
  order: 2;
}

.view.left  { left:0; right:50% }
.view.right { left:50%; right:0 }
.view.right .content.directory { border-left: 1px solid #ccc }

.content {
  left: 0;
  width: 100%;
  transition: transform .175s ease;
}

@media (min-width: 1024px) { .content { font-size:  1em } }
@media (max-width: 1023px) { .content { font-size: .9em } }
@media (max-width:  639px) { .content { font-size: .8em } }

.content.directory {
  background: #eee;
  display: flex;
  flex-direction: column;
  transform: translate3d(0,0,0);
}

.content.media, .content.document {
  height: 100%;
  background: #0a0a0a;
  position: absolute;
  overflow: hidden;
}

.content.back    { z-index: 0; position:absolute; transform: translate3d(-100%,0,0) }
.content.forward { z-index: 0; position:absolute; transform: translate3d(100%,0,0)  }

/* ================================== Path ================================= */

.path {
  background: #181818;
  box-shadow: 0 0 .5em rgba(0,0,0,.15);
  overflow: hidden;
  white-space: nowrap;
  width: 100%;
  z-index: 1;
  flex: 0 0 1.5rem;
  order: 1;
}

@media (min-width: 1024px) { .path {font-size: .9em } }
@media (max-width: 1023px) { .path {font-size: .8em } }
@media (max-width:  639px) { .path {font-size: .7em; flex-basis: 1.25rem } }

.path li {
  color: #ccc;
  cursor: pointer;
  display: inline-block;
  line-height: 1.5rem;
  opacity: 0;
  position: relative;
  transform: translateX(-2em);
  transition: transform .2s ease, opacity .2s ease;
}
.path li.in { opacity: 1; transform: translateX(0) }

.path li.dirty { color: #f71 !important}
.path li.saved { background: #361 !important}
.path li.saved svg { fill: #361 !important}
.path li.save-failed { background: #b44 !important }
.path li.save-failed svg { background: #b44 !important }
.path li.dirty:after { content: "*" }

@media (min-width: 1024px) { .path li { padding: 0 .4em 0 1.6em } }
@media (max-width: 1023px) { .path li { padding: 0 .2em 0 1.4em } }
@media (max-width:  639px) { .path li { padding: 0 .2em 0 1.4em; line-height: 1.25rem } }

.path .triangle { position: absolute; height: 1.5rem; width: 1.5rem; right: -.875rem }
@media (max-width:  639px) {
  .path .triangle { height: 1.25rem; width: 1.25rem; right: -.74rem }
}

.path .home {
  height: .8rem;
  width: .8rem;
  position: relative;
  top: -2px;
  vertical-align: middle;
}
.path li:hover .home { fill: #fff }
.path li:first-of-type { padding-left: .5em }

.path li:nth-child(odd)        { background: #404040 }
.path li:nth-child(odd) > .triangle  { fill: #404040 }
.path li:nth-child(even)       { background: #2d2d2d }
.path li:nth-child(even) > .triangle { fill: #2d2d2d }

.path li:nth-child(odd):hover        { background: #812; color: #fff }
.path li:nth-child(odd):hover > .triangle  { fill: #812 }
.path li:nth-child(even):hover       { background: #25a; color: #fff }
.path li:nth-child(even):hover > .triangle { fill: #25a }

.path li:nth-child(1)  { z-index: 15 }
.path li:nth-child(2)  { z-index: 14 }
.path li:nth-child(3)  { z-index: 13 }
.path li:nth-child(4)  { z-index: 12 }
.path li:nth-child(5)  { z-index: 11 }
.path li:nth-child(6)  { z-index: 10 }
.path li:nth-child(7)  { z-index: 9 }
.path li:nth-child(8)  { z-index: 8 }
.path li:nth-child(9)  { z-index: 7 }
.path li:nth-child(11) { z-index: 6 }
.path li:nth-child(12) { z-index: 5 }
.path li:nth-child(13) { z-index: 4 }
.path li:nth-child(14) { z-index: 3 }
.path li:nth-child(15) { z-index: 2 }
.path li:nth-child(16) { z-index: 1 }

/* ========================= File/Folder Display =========================== */

.paste-button {
  background: #333;
  text-align: center;
  position: absolute;
  white-space: nowrap;
  z-index: 445;
  color: #bbb;
  padding: 0 .25em;
  right: 0;
  top: 0;
  cursor: pointer;
  transition: opacity .3s ease, visibility 0s .3s;
  user-select: none;
  opacity: 0; visibility: hidden;
  line-height: 1.5rem;
}
.paste-button.in  { opacity: 1; visibility: visible; transition: opacity .3s ease }

@media (min-width: 1024px) { .paste-button { font-size: .9em } }
@media (max-width: 1023px) { .paste-button { font-size: .8em } }
@media (max-width:  639px) { .paste-button { font-size: .7em; line-height: 1.25rem } }

.paste-button .triangle {
  position: absolute;
  transform: rotate(180deg);
  fill: #333;
}

.paste-button .triangle { position: absolute; height: 1.5rem; width: 1.5rem; left: -.875rem }
@media (max-width:  639px) {
  .paste-button .triangle { height: 1.25rem; width: 1.25rem; left: -.74rem  }
}

.paste-button svg.paste {
  display: inline-block;
  vertical-align: middle;
  position: relative;
  top: -.05em;
  margin-right: .25em;
}
.paste-button:hover svg.triangle {fill: #25a }
.paste-button:hover { background: #25a; color: #fff }
.paste-button .filename { color: #fff }

#click-catcher {
  background: #000;
  position: absolute;
  left: 0; right: 0; top: 0; bottom: 0;
  z-index: 31;
  opacity: 0;
  visibility: hidden;
  user-select: none;
}
#click-catcher.in { opacity: .4; visibility: visible }

.file-header {
  display: flex;
  order: -1;
  color: #666;
  font-size: .8rem;
  line-height: 1rem;
  border-bottom: 1px solid #bbb;
  background: #ddd;
  user-select: none;
  align-items: center;
}

.file-header span {
  white-space: nowrap;
  cursor: pointer;
}

.file-header .triangle {
  position: relative;
  height: .5em;
  width: .5em;
  margin-left: .25em;
  transition: all .3s ease;
  z-index: 2;
  top: -.1em;
  left: -.3em;
}

.file-header .down .triangle { transform: rotate(90deg);  top: -.15em }
.file-header .up   .triangle { transform: rotate(270deg); top: -.05em }
.file-header .active  { color: #000 }
.file-header, .data-row { padding: 0 .5em }

.header-name, .entry-link, .inline-namer {
  flex: 1 1;
  display: inline-block;
  overflow: hidden;
}

.header-mtime, .mtime {
  flex: 0 0 6rem;
  display: inline-block;
  text-align: right;
  white-space: nowrap;
}
.header-size, .size {
  flex: 0 0 6rem;
  display: inline-block;
  text-align: right;
  white-space: nowrap;
}

.header-line-buttons, .line-buttons {
  flex: 0 0 4.5rem;
  text-align: right;
  display: inline-block;
}

.line-buttons svg {
  cursor: pointer;
  fill: #555;
  padding: 0 .1em;
  position: relative;
  top: .2em;
}
.line-buttons svg:hover { fill: #000 }

.playable:not(.playing):hover .sprite { background: none }
.playable:not(.playing):hover .icon-play svg { visibility: visible }

.icon-play svg {
  width: 100%; height: 100%;
  visibility: hidden;
  cursor: pointer;
  position: absolute;
  fill: #222;
}

.data-row {
  display: flex;
  align-items: center;
  line-height: 1.4em;
  border-top: 1px solid transparent;
  border-bottom: 1px solid transparent;
}
.data-row[order="0"] { border-top: none }

.data-row.editing.invalid input { color: #d22 }
.data-row.editing .entry-link { display: none }
.data-row, .data-row a { color: #333 }

.data-row:not(.playing):not(.animating):not(.editing):hover,
.data-row:not(.playing):not(.animating):not(.editing).active {
  background: #e6e6e6;
  border-color: #d2d2d2;
}

.data-row.playing {
  background: #05a;
  border-color: #04b;
}

.data-row.playing a.entry-link, .playing span { color: #fff }
.data-row.playing svg { fill: #ccc !important }
.data-row.playing svg:hover { fill: #fff !important }

.entry-link {
  overflow: hidden;
  text-overflow: ellipsis;
  vertical-align: top;
  white-space: nowrap;
  cursor: pointer;
}

.error-link {
  cursor: default !important;
  color: #f44 !important;
}

.inline-namer { background: transparent }

/* Hide certain list elements when width gets too small */
@media (max-width: 639px) {
  .data-row, .file-header             { padding: 0 .25em  }
  .header-line-buttons, .line-buttons { flex: 0 0 3.25rem }
  .line-buttons svg                   { padding: 0        }
  .header-size, .size                 { flex: 0 0 3.25rem }
  .size                               { font-size: .7rem  }
  .header-mtime, .mtime               { display: none     }
}
@media (max-width: 319px) {
  .header-size, .size { display: none   }
  .download           { display: none   }
  .line-buttons       { flex: 0 0 2.5em }
}

/* Hide them sooner when the view is split */
@media (max-width: 1365px) {
  .left .data-row, .right .data-row,
  .left .file-header, .right .file-header                 { padding: 0 .25em  }
  .left .header-line-buttons, .right .header-line-buttons,
  .left .line-buttons, .right .line-buttons               { flex: 0 0 4rem    }
  .left .line-buttons svg, .right .line-buttons svg       { padding: 0        }
  .left .header-size, .right .header-size,
  .left .size, .right .size                               { flex: 0 0 3.25rem }
  .left .size, .right .size                               { font-size: .7rem  }
  .left .header-mtime, .right .header-mtime,
  .left .mtime, .right .mtime                             { display: none     }
}
@media (max-width: 799px)  {
  .left .header-size, .right .header-size,
  .left .size, .right  .size                              { display: none   }
  .left .download, .right .download                       { display: none   }
  .left .line-buttons, .right .line-buttons               { flex: 0 0 2.5em }
}

/* ============================= Empty Folder ============================== */

.empty {
  text-align: center;
  cursor: pointer;
  overflow: hidden;
  padding: 1em 0;
  order: 2;
}

.empty svg {
  fill: #666;
  height: 70px;
  width: 70px;
  transition: all .3s ease;
  position: relative;
  bottom: -12px;
}

.empty .text {
  font-size: 20px;
  line-height: 20px;
  position: relative;
  color: #666;
  top: -25px;
  opacity: 0;
  transition: all .3s ease;
}

.empty:hover svg   { opacity: 1; bottom: 0; fill:  #000 }
.empty:hover .text { opacity: 1; top: -5px; color: #000 }

/* ================================= Icons ================================= */

.sprite {
  flex: 0 0 24px;
  background-clip: content-box;
  height: 24px;
  background-size: 240px 216px;
  overflow: hidden;
  transform-origin: 0 50%;
  position: relative;
}

@media (min-width: 1024px) { .sprite { transform: scale(1.25); margin-right: .4em } }
@media (max-width: 1023px) { .sprite { transform: scale(1.2);  margin-right: .3em } }
@media (max-width:  639px) { .sprite { transform: scale(1);    margin-right: .1em } }

.spinner {
  position: absolute;
  right: 0;
  z-index: 16;
  height: 1.5rem;
  width: 1.5rem;
  visibility: hidden;
  pointer-events: none;
  fill: #ccc;
}
.spinner.in { visibility: visible; animation: spin .75s infinite linear }

@media (max-width:  639px) { .spinner { height: 1.25rem; width: 1.25rem; top: 0 } }

/* ============================ Entry Menu ============================ */

#entry-menu {
  background: #eee;
  border-radius: 4px;
  box-shadow: 0 8px 24px rgba(0,0,0,.3);
  color: #333;
  opacity: 0;
  overflow: hidden;
  position: absolute;
  user-select: none;
  visibility: hidden;
  cursor: pointer;
  z-index: 32;
}
#entry-menu.in { opacity: 1; visibility: visible }

@media (min-width: 1024px) { #entry-menu { font-size: .9em } }
@media (max-width: 1023px) { #entry-menu { font-size: .8em } }
@media (max-width:  639px) { #entry-menu { font-size: .7em } }

html:not(.mobile) #entry-menu a:hover,
html:not(.mobile) #entry-menu a.active {
  background: #05a;
  color: #fff;
}

#entry-menu a {
  padding: .25em .35em;
  color: #333;
  display: block;
}

#entry-menu svg {
  margin-right: .25em;
  float: left;
}

#entry-menu div {
  width: 100%;
}

#entry-menu div > span {
  display: inline-block;
  vertical-align: top;
}

#entry-menu a.play, #entry-menu.type-folder a.edit {
  display: none;
}

#entry-menu.type-audio .play {
  display: block;
}

/* ============================ Media View ============================ */
.arrow-back, .arrow-forward {
  position: absolute;
  top:0;
  bottom: 2.5rem;
  width: 3em;
  cursor: pointer;
  z-index: 33;
  user-select: none;
  fill: #222;
  stroke: #eee;
  stroke-width: 15;
  opacity: 0;
  transition: opacity .3s ease;
}
.mobile .arrow-back, .mobile .arrow-forward { display: none }

.arrow-back       { left:  0 }
.arrow-forward    { right: 0 }
.arrow-back.in    { opacity: 1 }
.arrow-forward.in { opacity: 1 }

.arrow-back svg, .arrow-forward svg {
  height: 2em;
  width: 2em;
  position: absolute;
  transition: all .25s ease;
  top: calc(50% + 1.25rem);
}

.arrow-back svg    { transform: rotate(270deg) translateX(50%);  left:  0 }
.arrow-forward svg { transform: rotate(90deg)  translateX(-50%); right: 0 }
.arrow-back:hover svg    { height: 3em; width: 3em; left:  -.25em }
.arrow-forward:hover svg { height: 3em; width: 3em; right: -.25em }

.media-container {
  position: absolute;
  left: 0; right: 0; top: 0; bottom: 0;
  transform: translateX(0);
}
.media-container:not(.draggable) {transition: all .25s ease }
.media-container.left  { opacity: 0; transform: translateX(-33%) }
.media-container.right { opacity: 0; transform: translateX(33%)  }

.view.left .media-container img, .view.right .media-container img,
.view.left .media-container video, .view.right .media-container video {
  max-width: 50vw;
}

.content:fullscreen { top: 0; height: 100% }
.content:fullscreen .media-container img,
.content:fullscreen .media-container video {
  max-width: 100vw;
}

.media-container img {
  position: absolute;
  max-height: 100%; max-width: 100vw;
  left: 50%; top: 50%; transform: translate(-50%, -50%);
}

.meta {
  position: absolute;
  font-size: .9rem;
  padding: .125rem;
  right: .25em; bottom: .25em;
  z-index: 1;
  color: #aaa;
  background: rgba(0,0,0,.4);
  border-radius: .125em;
  cursor: pointer;
  user-select: none;
  display: flex;
  align-items: center;
}
.meta:hover { background: rgba(0,0,0,.9) }

.fs {
  cursor: pointer;
  background: transparent;
}
.fs svg {
  height: 1.25em;
  width: 1.25em;
  position: relative;
  top: .1em;
}
.meta:hover svg { fill: #fff }
.meta:hover span { color: #fff }

.meta .counter { margin: 0 .25em }
.meta .dims    { display: none }
.meta .dims.in { display: inline }

.meta > div { display: inline }
.meta span > span { color: #bbb }
.type-video .fs, .type-video .meta { display: none }
/* ================================= Video.js ================================= */

html:not(.mobile) .vjs-big-play-button {
  display: none !important;
}

.media-container video:not(.vjs-tech) {
  display: none;
}

.vjs-fullscreen video {
  max-width: 100% !important;
}

.video-js {
  height: 100% !important;
  width: 100% !important;
  background: transparent !important;
}

.video-js.vjs-fullscreen {
  background: #000 !important;
}

.vjs-big-play-button {
  left: 50% !important;
  top: 50% !important;
  transform: translate(-50%, -50%) !important;
  color: #fff !important;
  border: none !important;
}

.vjs-mouse-display, .vjs-play-progress:after {
  font-family: Arial,Helvetica,sans-serif !important;
}

.vjs-slider {
  background: #666 !important;
}

.vjs-control-bar {
  background: rgba(16,16,16,.8) !important;
}

/* ============================ Document  ============================ */

.CodeMirror {
  font-family: "Consolas", "Monaco", "Droid Sans Mono", monospace !important;
  line-height: 1.2em !important;
  height: 100% !important;
  width: 100% !important;
}
/* Need some weight to override some themes */
.content div.CodeMirror { font-size: 16px }

.CodeMirror-scrollbar-filler { background: transparent !important }
.CodeMirror-lines { padding: 0 !important }

.CodeMirror-dialog-top { border-bottom: 1px solid #383838; top: 0 }
.CodeMirror-dialog-bottom { border-top: 1px solid #383838; bottom: 0 }

.CodeMirror-dialog {
  position: absolute;
  left: 0; right: 0;
  background: #282828;
  z-index: 15;
  padding: .1em .8em;
  overflow: hidden;
  color: #aaa;
  white-space: nowrap;
}

.CodeMirror-dialog input {
  border: none;
  outline: none;
  background: transparent;
  width: 20em !important;
  color: #eee;
  font-family: "Consolas", "Monaco", "Droid Sans Mono", monospace;
}

.CodeMirror-dialog button {
  background: #181818;
  padding: .05rem .2rem;
  color: #eee;
}
.CodeMirror-dialog button:hover {
  background: #383838;
}

.sidebar {
  position: absolute;
  top: .5em;
  right: .5em;
  width: 2.5em;
  user-select: none;
}
.sidebar > li {
  position: relative;
  z-index: 5;
  margin-bottom: .25em;
}

.sidebar svg {
  fill: rgba(128,128,128,.6);
  margin-left: .75em;
}

.sidebar span {
  display: block;
  text-align: center;
  opacity: 0;
  font-size: .7em;
}

.sidebar > li:hover         { cursor: pointer }
.sidebar > li:hover span    { color: #fff; opacity: 1 }
.sidebar > .exit:hover svg  {  fill: #d44 }
.sidebar > .exit:hover span { color: #d44 }
.sidebar > .save:hover svg  {  fill: #5c5 }
.sidebar > .save:hover span { color: #5c5 }
.sidebar > .ww:hover svg    {  fill: #18f }
.sidebar > .ww:hover span   { color: #18f }
.sidebar > .syntax:hover svg, .sidebar > .syntax.in svg { fill: #f82 }
.sidebar > .syntax:hover span, .sidebar > .syntax.in span { color: #f82; opacity: 1 }
.sidebar > .find:hover svg  {  fill: #a4c }
.sidebar > .find:hover span { color: #a4c }
.sidebar > .full:hover svg  {  fill: #bb4 }
.sidebar > .full:hover span { color: #bb4 }

.mode-select {
  background: #282828;
  border: none;
  box-shadow: 0 8px 16px rgba(0,0,0,.6);
  border-radius: 2px;
  color: #ccc;
  font-size: .8em;
  margin-top: -2.7em;
  padding: .7em 3em .7em .5em;
  position: absolute;
  right: 0;
  visibility: hidden;
  z-index: 4;
  appearance: none;
}
.mode-select.in { visibility: visible }

/* ============================ Upload Progress ============================ */

.upload-info {
  background: #181818;
  color: #aaa;
  transition: flex-basis .15s ease;
  width: 100%;
  position: relative;
  display: flex;
  flex: 0 0 0;
  order: 4;
  align-items: stretch;
  justify-content: space-between;
  overflow: hidden;
  z-index: 1;
}
.upload-info.in  { flex-basis: 1.5em }

@media (min-width: 1024px) { .upload-info { font-size: .9em } }
@media (max-width: 1023px) { .upload-info { font-size: .8em } }
@media (max-width:  639px) { .upload-info { font-size: .7em } }

.upload-info > span {
  vertical-align: middle;
  display: inline-block;
  line-height: 1.5em;
  z-index: 3;
}

.upload-percentage {
  flex: 0 0 3em;
  color: #bbb;
  text-align: center;
}

.upload-title {
  flex: 1 1;
  color: #fff;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.upload-speed {
  color: #ccc;
  flex: 0 0 6em;
  text-align: center;
  white-space: nowrap;
}

.upload-time {
  color: #ccc;
  flex: 0 0 6em;
  text-align: center;
  white-space: nowrap;
}

.upload-cancel {
  transition: color .2s ease;
  cursor: pointer;
  flex: 0 0 1.5em;
}

@media (max-width: 959px) {
  .view.left .upload-title, .view.right .upload-title   { display: none !important }
  .view.left .upload-cancel, .view.right .upload-cancel { flex: 0 0 2em !important }
  .view.left .upload-cancel span, .view.right .upload-cancel span { display: none !important }
}

@media (max-width: 479px) {
  .upload-title       { display: none !important }
  .upload-speed       { flex: 1 1 !important     }
  .upload-time        { flex: 1 1 !important     }
  .upload-cancel      { flex: 0 0 2em !important }
  .upload-cancel span { display: none !important }
}

.upload-bar {
  position: absolute;
  background: #05a;
  top: 0; bottom: 0; left: 0;
  transition: width .2s ease;
  width: 0;
  z-index: 2;
  pointer-event: none;
}

.upload-info svg {
  vertical-align: middle;
  transition: fill .15s ease;
  position: relative;
  top: -.1em;
}

.upload-cancel:hover { color: #f44 }
.upload-cancel:hover svg.remove { fill: #f44 }
#file { display: none }

/* =============================== Audio Panel =============================== */

.audio-bar {
  background: #181818;
  box-shadow: 0 0 .5em rgba(0,0,0,.2);
  flex: 0 0 0;
  order: 3;
  display: flex;
  position: relative;
  transition: flex-basis .15s ease;
  width: 100%;
  user-select: none;
  overflow: hidden;
}
.audio-bar.in { flex-basis: 1.5em }

@media (min-width: 1024px) { .audio-bar { font-size: .9em} }
@media (max-width: 1023px) { .audio-bar { font-size: .8em} }
@media (max-width:  639px) { .audio-bar { font-size: .7em} }

.audio-icon {
  z-index: 4;
  flex: 0 0 1.5em;
}
.audio-icon:first-of-type { margin-left: .25em }
@media (max-width: 639px) { .audio-icon { flex-basis: 1.25em } }

.audio-icon svg {
  fill: rgba(255,255,255,.55);
  height: 1.125em;
  width: 1.125em;
  margin: .0625em .25em;
  padding: .125em;
  pointer-events: none;
}
@media (max-width: 639px) { .audio-icon svg { height: 1em; width: 1em; margin: .125em } }

.audio-icon:hover svg { fill: #fff }
.audio-icon.active svg {
  fill: #fff;
  background: rgba(255,255,255,.3);
  border-radius: 4px;
}

.volume-slider {
  z-index: 4;
  height: .75em;
  transition: flex-basis .2s ease;
  flex: 0 0 0;
  margin: .375em 0;
}
.volume-slider.in { flex-basis: 4em; box-shadow: 0 0 0 1px #eee }

.volume-slider-inner {
  background: #eee;
  height: .75em;
}

.audio-title {
  overflow: hidden;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
  line-height: 1.5em;
  color: #fff;
  flex: 1;
  z-index: 4;
  cursor: default;
}

.seekbar {
  position: absolute;
  left: 0; right: 0; bottom: 0; top: 0;
  transition: all .2s ease;
  overflow: visible;
}

.seekbar-played {
  position: absolute;
  width: 0;
  background: #05a;
  height: 100%;
  z-index: 2;
}

.seekbar-loaded {
  position: absolute;
  width: 0;
  height: 100%;
  background: #282d38;
  z-index: 1;
}

.audio-bar .time {
  z-index: 4;
  flex: 0 0 7em;
  text-align: right;
  margin-right: .25em;
  display: block;
  color: #999;
  line-height: 1.5em;
  cursor: default;
}
@media (max-width: 639px) { .audio-bar .time { flex-basis: 2.8em } }

.time > * { pointer-events: none }
.time-cur, .time-max { color: #fff }
@media (max-width: 639px) { .time-max, .time-sep { visibility: hidden } }

/* =============================== About box =============================== */

#about-box {
  background: #eee;
  border-radius: 6px;
  box-shadow: 0 8px 24px rgba(0,0,0,.3);
  color: #333;
  height: 150px;
  left: 50%;
  top: 50%;
  opacity: 0;
  visibility: hidden;
  position: fixed;
  transition: opacity .3s ease, visibility 0s .3s;
  transform: translate(-50%, -50%);
  width: 300px;
  text-align: center;
  z-index: 64;
}
#about-box.in { opacity: 1; visibility: visible; transition: opacity .3s ease }

#about-title {
  font-size: 1.3em;
  padding: .5em 0 .25em 0;
}

#about-engine {
  font-size: .8em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  padding-bottom: .25em;
}

#about-copy {
  bottom: 0;
  font-size: .7em;
  margin-bottom: .2em;
  width: 300px;
  position: absolute;
}

#about-copy a {
  padding: 0 .3em;
  color: #000;
  border: 1px solid transparent;
}

#about-fork {
  font-size: .66em;
  color: #333;
  border-radius: .4em;
}

#about-fork .github {
  display: inline-block;
  vertical-align: middle;
  height: 1em;
  margin: 0 .25em .25em 0;
}

#about-fork:hover, #about-fork:hover svg, #about-copy a:hover {
  color: #05a;
  fill: #05a;
  border-radius: 4px;
  text-decoration: underline;
}

/* ================================= Prefs ================================ */

#prefs-box {
  background: #eee;
  border-radius: 6px;
  box-shadow: 0 8px 24px rgba(0,0,0,.3);
  color: #555;
  max-height: 95%;
  left: 50%;
  top: 50%;
  position: fixed;
  transition: opacity .3s ease, visibility 0s .3s;
  transform: translate(-50%, -50%);
  z-index: 64;
  padding: .33em;
  overflow-y: auto;
  opacity: 0;
  visibility: hidden;
}
#prefs-box.in { opacity: 1; visibility: visible; transition: opacity .3s ease }

@media (min-width: 800px) { #prefs-box { width: 24em } }
@media (max-width: 799px) { #prefs-box { width: 80%  } }
#prefs-box li:hover { background: #ddd; color: #000; border-radius: 3px }

.list-prefs li { display: flex; padding: .125em .25em }
.list-prefs li:first-of-type { margin-top: 0 }

.list-prefs label {
  display: inline-block;
  white-space: nowrap;
  line-height: 1.33em;
  flex: 1;
}

@media (max-width: 639px) {
  #prefs-box { font-size: .8em }
  .list-prefs li {
   flex-direction: column;
   height: auto;
  }
  .list-prefs label {
   width: 100%;
   text-align: center;
   margin-bottom: .25em;
   line-height: 1em;
  }
  .list-prefs select {
   width: 100%;
   margin-bottom: .25em;
  }
}

#prefs-box select {
  padding: 0 .25em;
  border-radius: 3px;
  border:none;
  color: #555;
  background-color: #fff;
  background-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSI2NDAiIGhlaWdodD0iNjQwIiB2aWV3Qm94PSIwIDAgNjQwIDY0MCI+PHBhdGggc3R5bGU9ImZpbGw6ICM5OTkiIGQ9Ik0zMjAgMGwtMTQ3LjIgMjMzLjZoMjk0LjM2OGwtMTQ3LjE2OC0yMzMuNnpNMzIwLjAzMiA2NDBsMTQ3LjE2OC0yMzMuNi0yOTQuNC0wLjAzMiAxNDcuMjMyIDIzMy42MzJ6Ij48L3BhdGg+PC9zdmc+");
  background-size: 1em;
  background-repeat: no-repeat;
  background-position: right;
  flex: 1;
  appearance: none;
}
#prefs-box li:hover select { color: #000 }

.list-user { padding:.3em 0}
.list-user:before {
  content: "Users";
  border-bottom: 1px solid #aaa;
  color: #333;
  padding: .125em;
  display: block;
}

.list-user li {
  padding: 0 .25em;
  line-height: 1.2em;
  display: flex;
  align-items: center;
  justify-content: center;
}

.username { flex: 1 }
.delete-user {
  cursor: pointer;
  flex: 0 0 1rem;
  display: flex;
}

.list-user svg {
  fill: #bbb;
}

.list-user li:hover .trash { fill: #f44 }

.add-user {
  cursor: pointer;
  text-align: center;
  user-select: none;
}
.add-user:hover svg { fill: #000 }

.add-user svg {
  height: .8em;
  width: .8em;
  margin-right: .25em;
  fill: #666;
}

/* ============================== Login Form =============================== */

#login-box {
  color: #222;
  background: #ccc;
  border-radius: 6px;
  box-shadow: 0 8px 24px #000;
  height: 11rem;
  width: 24rem;
  position: absolute;
  text-align: center;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

@media (max-width: 639px), (max-height: 399px) {
  #login-box {
   border-radius: 0;
   box-shadow: none;
   font-size: .7em;
   top: 50%;
   left: 50%;
   height: 100%;
   width: 100%;
   margin: 0;
  }
}

#form {
  position: absolute;
  width: 100%;
  height: 100%;
}

#firstrun-title {
  font-size: 1.33em;
  margin-top: 1.5em;
  width: 100%;
}

#login-info-box {
  line-height: 2rem;
  background: linear-gradient(#ccc,#fff);
  box-shadow: 0 0 10px rgba(0,0,0,.3);
  border-radius: 5px 5px 0 0;
  transition: background .2s ease;
  position: absolute;
  top: 0;
  width: 100%;
}

#login-info-box.error { background: #a33; color: #fff }
@media (max-width: 639px), (max-height: 399px) { #login-info-box { border-radius: 0 } }

#login-info {
  line-height: 1.75rem;
}

#fields {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 80%;
  transform: translate(-50%, -50%);
}

#fields input {
  background: rgba(255,255,255,.5);
  padding: 0 10px;
  height: 2rem;
  width: 100%;
  border-radius: 5px;
}

#fields input:focus {
  background: rgba(255,255,255,1);
}

#fields input + input {
  margin-top: .3rem;
}

#login-box .bottom {
  position: absolute;
  bottom: 0;
  width: 100%;
  height: 2rem;
  display: flex;
  background: linear-gradient(#fff,#ccc);
  border-radius: 0 0 5px 5px;
  box-shadow: 0 0 10px rgba(0,0,0,.3);
}

.remember, .submit {
  line-height: 2rem;
  height: 2rem;
  background: transparent;
  bottom: 0;
  color: #666;
  cursor: pointer;
  user-select: none;
  white-space: nowrap;
  flex: 1;
}

.remember svg, .submit svg {
  position: relative;
  top: .15rem;
  margin: 0 .1em;
}

.remember:hover, .remember:focus { color: #222 }
.submit:hover, .submit:focus     { color: #222 }
.submit svg                      { fill: #666; margin-right: .2em }
.remember svg                    { fill: transparent }
.remember.checked svg            { fill: #666 }
.submit:hover svg                { fill: #222 }
.remember.checked:hover svg      { fill: #222 }

@media (max-width: 639px), (max-height: 399px) {
  .remember, .submit {
    border-radius: 0;
  }
}

/* =============================== Info Box ================================ */

.info-box {
  border-radius: 6px;
  left: 50%;
  top: 50%;
  transform:  translate(-50%, -50%);
  position: absolute;
  transition: opacity .3s ease, visibility 0s .3s;
  z-index: 40;
  display: flex;
  opacity: 0;
  color: #333;
  background: #eee;
  visibility: hidden;
  box-shadow: 0 8px 24px rgba(0,0,0,.3);
  max-width: 90%;
}
.info-box.in { opacity: 1; visibility: visible; transition: opacity .3s ease }

@media (min-width: 1024px) { .info-box { font-size: 1em  } }
@media (max-width: 1023px) { .info-box { font-size: .9em } }
@media (max-width:  799px) { .info-box { font-size: .8em } }

.info-box .icon {
  display: flex;
  flex: 0 0 3em;
  border-radius: 6px 0 0 6px;
  justify-content: center;
  align-items: center;
}

.info-box.link .icon  { background: #05a }
.info-box.error .icon { background: #f44 }

.info-box .icon svg {
  height: 2.5em;
  width: 2.5em;
  fill: #fff;
}
.info-box.link span       { display: none }
.info-box.error .link-out { display: none }
.info-box.link  .icon svg { height: 2.5em             }
.info-box.error .icon svg { height: calc(100% - .5em) }

.info-box span, .link-out {
  color: #444;
}

.link-out {
  white-space: nowrap;
  padding: .25em .75em;
}

.info-box span {
  flex: 1;
  line-height: 1.25em;
  padding: .5em;
}

.info-box .link-out { flex: 1; line-height: 2.5em; overflow: hidden; }

.link-options {
  font-size: .7rem;
  white-space: nowrap;
  display: flex;
  flex-direction: column;
  justify-content: middle;
  background: #05a;
  color: #fff;
  border-radius: 0 6px 6px 0;
  cursor: pointer;
  margin-left: .25em;
  user-select: none;
}
.info-box.error .link-options { display: none }

.link-options svg {
  margin: 0 .25em 0 .5em;
  transition: opacity .2s ease;
}

.link-options .dl-link:not(.checked) svg { opacity: 0; }

.link-options > div {
  flex: 1;
  display: flex;
  align-items: center;
  padding-right: .5em;
}

.link-options > div:first-of-type { border-top-right-radius: 6px     }
.link-options > div:last-of-type  { border-bottom-right-radius: 6px  }
.link-options > div:hover {
  background: rgba(255,255,255,.2);
}

/* =========================== Drop Select Menu ============================ */

#drop-select {
  position: fixed;
  left: 50%;
  top: 50%;
  width: 10em;
  line-height: 2em;
  z-index: 34;
  transform: translate(-50%, -50%);
  background: #fff;
  box-shadow: 0 8px 24px rgba(0,0,0,.3);
  border-radius: 6px;
  visibility: hidden;
  opacity: 0;
  display: flex;
  flex-direction: row;
}
#drop-select.in { opacity: 1; visibility: visible }

#drop-select span {
  cursor: pointer;
  display: inline-block;
  text-align: center;
  flex: 1;
  font-size: .75em;
}

html:not(.mobile) #drop-select span:hover,
html:not(.mobile) #drop-select span.active {
  background: #05a; color: #fff;
}

.movefile:hover, .movefile.active { border-radius: 6px 0 0 6px }
.viewfile:hover, .viewfile.active { border-radius: 0 6px 6px 0 }

@media (max-width: 639px) {
  #drop-select {
   flex-direction: column;
   width: 3.5em;
   font-size: .8em;
   line-height: 1.75em;
  }
  #drop-select .movefile:hover { border-radius: 6px 6px 0 0 }
  #drop-select .viewfile:hover { border-radius: 0 0 6px 6px }
}
/* ============================= Misc Elements ============================= */

.dropzone {
  position: absolute;
  left: 0; right: 0; bottom: 0; top: 1.5rem;
  z-index: 5;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  background: #05a;
  display: flex;
  align-items: center;
  justify-content: center;
}
@media (max-width:  639px) { .dropzone { top: 1.25rem } }
.dropzone.in { opacity: .5; visibility: visible }

.dropzone svg {
  height: 50%;
  width: 50%;
  fill: #fff;
}

.shake { animation: shake .3s ease }

iframe { display: none }
