/* file-browser stylesheet.
   Plain CSS, served by the app from its own directory. No external font, no
   CDN, no image, and no network request of any kind from the served pages. */

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 1.5rem;
    background: #f5f6f8;
    color: #1d2129;
    font-family: system-ui, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    font-size: 15px;
    line-height: 1.5;
}

a {
    color: #1a4f8a;
    text-decoration: none;
}

a:hover,
a:focus {
    text-decoration: underline;
}

h1 {
    margin: 0;
    font-size: 1.25rem;
    font-weight: 600;
    letter-spacing: 0.01em;
}

button {
    padding: 0.45rem 0.9rem;
    border: 1px solid #1a4f8a;
    border-radius: 4px;
    background: #1a4f8a;
    color: #ffffff;
    font: inherit;
    cursor: pointer;
}

button:hover,
button:focus {
    background: #163f6e;
    border-color: #163f6e;
}

/* Login page */

main.login {
    max-width: 22rem;
    margin: 4rem auto;
    padding: 1.75rem;
    background: #ffffff;
    border: 1px solid #dcdfe4;
    border-radius: 6px;
}

main.login h1 {
    margin-bottom: 1.25rem;
    text-align: center;
}

main.login form {
    display: flex;
    flex-direction: column;
}

main.login label {
    margin-top: 0.75rem;
    margin-bottom: 0.25rem;
    font-size: 0.85rem;
    font-weight: 600;
    color: #4a5259;
}

main.login input {
    padding: 0.5rem;
    border: 1px solid #c8ccd2;
    border-radius: 4px;
    font: inherit;
    background: #ffffff;
    color: #1d2129;
}

main.login input:focus {
    border-color: #1a4f8a;
    outline: 2px solid #cfe0f3;
}

main.login button {
    margin-top: 1.25rem;
}

p.error {
    margin: 0 0 0.5rem 0;
    padding: 0.6rem 0.75rem;
    border: 1px solid #e0b4b4;
    border-radius: 4px;
    background: #fdf0f0;
    color: #8a1f1f;
    font-size: 0.9rem;
}

/* Message pages */

main.message {
    max-width: 30rem;
    margin: 4rem auto;
    padding: 1.5rem;
    background: #ffffff;
    border: 1px solid #dcdfe4;
    border-radius: 6px;
    text-align: center;
}

/* Listing page */

header.bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 60rem;
    margin: 0 auto 1rem auto;
}

header.bar form.logout {
    margin: 0;
}

main.listing {
    max-width: 60rem;
    margin: 0 auto;
    padding: 1.25rem;
    background: #ffffff;
    border: 1px solid #dcdfe4;
    border-radius: 6px;
}

nav.crumbs {
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #e6e8ec;
    font-size: 0.95rem;
    word-break: break-word;
}

nav.crumbs span.sep {
    color: #9aa1a9;
}

nav.crumbs span.here {
    font-weight: 600;
}

p.notice {
    margin: 0 0 1rem 0;
    padding: 0.6rem 0.75rem;
    border: 1px solid #b8ddb8;
    border-radius: 4px;
    background: #f0f9f0;
    color: #1f6b2a;
    font-size: 0.9rem;
}

table.entries {
    width: 100%;
    border-collapse: collapse;
}

table.entries th {
    padding: 0.4rem 0.5rem;
    border-bottom: 1px solid #dcdfe4;
    text-align: left;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: #6b727a;
}

table.entries td {
    padding: 0.4rem 0.5rem;
    border-bottom: 1px solid #f0f1f4;
    vertical-align: top;
    word-break: break-word;
}

table.entries a.dir {
    font-weight: 600;
}

table.entries td.size,
table.entries td.modified {
    white-space: nowrap;
    color: #4a5259;
    font-size: 0.9rem;
}

table.entries th:nth-child(2),
table.entries td.size {
    text-align: right;
}

table.entries td.empty {
    padding: 1.25rem 0.5rem;
    text-align: center;
    color: #6b727a;
}

span.note {
    color: #8a6d1f;
    font-size: 0.85rem;
}

p.counts {
    margin: 0.75rem 0 0 0;
    color: #6b727a;
    font-size: 0.85rem;
}

form.upload {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.6rem;
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid #e6e8ec;
}

form.upload label {
    font-size: 0.85rem;
    font-weight: 600;
    color: #4a5259;
}

form.upload input[type="file"] {
    font: inherit;
    font-size: 0.9rem;
}

@media (max-width: 40rem) {
    body {
        padding: 0.75rem;
    }

    table.entries td.modified,
    table.entries th:nth-child(3) {
        display: none;
    }
}
