@property --gradient-angle {
    syntax: "<angle>";
    initial-value: 0deg;
    inherits: false;
}

html, body {
    margin: 0;
    padding: 0;
    min-height: 100vh;
    background: linear-gradient(var(--gradient-angle), #ff7e5f, #feb47b, #86a8e7, #7f7fd5);
    background-size: 200% 200%;
    animation: spinAndShift 10s linear infinite;
    color: #222;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 13px;
}

@keyframes spinAndShift {
    0% {
        --gradient-angle: 0deg;
        filter: hue-rotate(0deg);
    }
    100% {
        --gradient-angle: 360deg;
        filter: hue-rotate(360deg);
    }
}

body {
    border-top: 4px solid #333;
}

.page {
    width: min(1000px, calc(100% - 30px));
    margin: 20px auto 50px;
}

a {
    color: #0645ad;
    text-decoration: underline;
}

h1 {
    margin: 0 0 10px;
    font-size: 19px;
    font-weight: normal;
}

h2 {
    margin: 0;
    font-size: 15px;
    font-weight: normal;
}

.muted,
.note {
    color: #777;
}

.note {
    margin-top: 18px;
    font-size: 11px;
    line-height: 1.5;
}

header {
    border-bottom: 1px solid #999;
    padding-bottom: 6px;
    margin-bottom: 18px;
}

.title {
    color: #222;
    text-decoration: none;
    font-size: 18px;
    font-weight: bold;
    letter-spacing: -0.5px;
}

.toplinks {
    float: right;
    color: #666;
}

.message {
    border: 1px solid #aaa;
    background: #fff;
    padding: 6px 8px;
    margin-bottom: 12px;
}

.message.error {
    color: #8a2600;
}

.message.ok {
    color: #176b2c;
}

.cloud {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 390px;
    gap: 24px;
    align-items: start;
}

.dropzone {
    position: relative;
    border: 1px solid #999;
    background: #fff;
    padding: 38px 20px 20px;
    text-align: center;
}

.dropzone.over {
    background: #eeeeea;
}

.dropzone input[type=file] {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
}

.droptext {
    display: block;
    padding: 25px 10px;
    border: 1px dashed #aaa;
    cursor: pointer;
    line-height: 1.6;
}

.droptext strong {
    font-size: 15px;
    font-weight: normal;
    text-decoration: underline;
}

.selected {
    min-height: 18px;
    margin: 10px 0;
    color: #555;
    font-family: "Courier New", monospace;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

button {
    font: inherit;
    padding: 3px 9px;
    border: 1px solid #777;
    background: #e7e7e2;
    color: #111;
    cursor: pointer;
}

button:hover {
    background: #d8d8d2;
}

.sidehead {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    border-bottom: 1px solid #999;
    padding-bottom: 6px;
}

.sidehead span {
    color: #777;
}

.filelist {
    border: 1px solid #999;
    border-top: 0;
    background: #fff;
}

.file {
    padding: 9px 10px 11px;
    border-bottom: 1px solid #ddd;
}

.file:last-child {
    border-bottom: 0;
}

.filename {
    font-weight: bold;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.meta {
    color: #777;
    font-size: 11px;
    margin-top: 2px;
}

.actions {
    display: flex;
    gap: 10px;
    align-items: center;
    margin-top: 7px;
}

.actions form,
.share form {
    display: inline;
}

.link {
    padding: 0;
    border: 0;
    background: none;
    color: #0645ad;
    text-decoration: underline;
}

.link:hover {
    background: none;
}

.danger {
    color: #8a2600;
}

.shareform {
    display: flex;
    gap: 5px;
    margin-top: 99px;
}

.shareform input {
    min-width: 0;
    width: 0;
    flex: 1;
    padding: 3px 5px;
    border: 1px solid #999;
    background: #fff;
    font: inherit;
}

.share {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 7px;
    margin-top: 8px;
    padding-top: 7px;
    border-top: 1px dotted #bbb;
    font-size: 11px;
}

.tag {
    color: #666;
    border: 1px solid #bbb;
    padding: 1px 4px;
}

.empty {
    border: 1px solid #999;
    border-top: 0;
    background: #fff;
    margin: 0;
    padding: 10px;
}

.loginbox,
.sharedbox {
    width: 280px;
    margin: 80px auto;
    border: 1px solid #999;
    background: #fff;
    padding: 15px;
}

.loginbox label {
    display: block;
    margin-bottom: 10px;
}

.loginbox input {
    width: 100%;
    box-sizing: border-box;
    margin-top: 3px;
    padding: 4px;
    border: 1px solid #999;
    font: inherit;
}

.sharedbox {
    width: min(500px, calc(100% - 30px));
    text-align: center;
}

.sharedname {
    margin: 20px 0 3px;
    font-size: 16px;
    font-weight: bold;
    overflow-wrap: anywhere;
}

.download {
    display: inline-block;
    border: 1px solid #777;
    background: #e7e7e2;
    color: #111;
    padding: 5px 12px;
    text-decoration: none;
}

.sharebox p {
    margin-bottom: 15px;
}

@media (max-width: 760px) {
    .cloud {
        grid-template-columns: 1fr;
    }
    
    .toplinks {
        float: none;
        display: block;
        margin-top: 5px;
    }
    
    .title {
        display: block;
        line-height: 1.3;
    }
}
