/* Picture explorer in i/, in the Safeguard scanner style of the other pages */

main.content {
    flex: 1 0 auto;
    width: 100%;
    max-width: 1300px;
    margin: 0 auto;
    padding: 20px 16px 80px;
}

/* Header */
.ex-header {
    text-align: center;
}

.ex-top {
    text-align: left;
}

.ex-header .tag {
    margin-top: 18px;
}

.ex-header .hud-title {
    font-size: clamp(26px, 8vw, 48px);
}

.crumbs {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 4px 6px;
    margin-top: 14px;
    font: 16px "JetBrains Mono", Consolas, monospace;
    color: rgba(var(--accent-rgb), 0.6);
}

/* every part of the path is a link back to that folder */
.crumbs a {
    padding: 2px 8px;
    border: 1px solid transparent;
    color: var(--accent-light);
    transition: background-color 0.2s, border-color 0.2s, color 0.2s;
}

.crumbs a:hover {
    border-color: rgba(var(--accent-rgb), 0.45);
    background: rgba(var(--accent-rgb), 0.15);
    color: #fff;
}

.crumbs a:last-child {
    color: #efe2f7;
}

.ex-meta {
    margin: 6px 0 0;
    font-size: 14px;
    color: rgba(220, 221, 222, 0.55);
}

/* the folders of an account that sees only some: its own and the shared ones */
.ex-meta a {
    color: var(--accent-light);
}

.notice {
    max-width: 640px;
    margin: 24px auto 0;
    padding: 12px 18px;
    border: 1px solid rgba(240, 178, 50, 0.35);
    background: rgba(240, 178, 50, 0.06);
    color: #e8d5a8;
    text-align: center;
}

/* Search and sorting, kept at the top while scrolling */
.toolbar {
    position: sticky;
    top: 0;
    z-index: 10;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 14px;
    margin: 28px -16px 0;
    padding: 12px 16px;
    background: rgba(14, 14, 17, 0.88);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(var(--accent-rgb), 0.2);
}

.toolbar .search {
    flex: 1 1 320px;
}

.sort {
    display: flex;
}

.sort button {
    padding: 8px 14px;
    border: 1px solid rgba(var(--accent-rgb), 0.35);
    background: transparent;
    color: rgba(220, 221, 222, 0.6);
    font: 13px/1.5 "Sanakan Mono", monospace;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    cursor: pointer;
    transition: background-color 0.2s, color 0.2s;
}

.sort button + button {
    border-left: 0;
}

.sort button:hover {
    color: #fff;
}

.sort button[aria-pressed="true"] {
    background: rgba(var(--accent-rgb), 0.22);
    color: #fff;
}

.toolbar .search-info {
    flex-basis: 100%;
    margin-top: 0;
}

/* Grid of folders and pictures */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
    gap: 16px;
    margin-top: 24px;
}

.tile {
    --corner: rgba(var(--accent-light-rgb), 0.35);
    --fill: rgba(255, 255, 255, 0.02);
    display: flex;
    flex-direction: column;
    min-width: 0;
    padding: 8px;
    color: var(--text);
}

.tile:hover,
.tile:focus-visible {
    --corner: var(--accent-light);
    --fill: rgba(var(--accent-rgb), 0.12);
    outline: 0;
}

.thumb {
    position: relative;
    display: grid;
    place-items: center;
    aspect-ratio: 4 / 5;
    overflow: hidden;
    background: #0b0b0d;
}

.thumb img,
.thumb video {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.placeholder {
    display: grid;
    gap: 4px;
    text-align: center;
    font: 12px "Sanakan Mono", monospace;
    color: rgba(220, 221, 222, 0.5);
}

.placeholder b {
    font-size: 22px;
    font-weight: 400;
    letter-spacing: 0.12em;
    color: var(--accent-light);
}

.badge {
    position: absolute;
    top: 6px;
    right: 6px;
    padding: 1px 6px;
    background: rgba(14, 14, 17, 0.85);
    border: 1px solid rgba(var(--accent-rgb), 0.5);
    color: var(--accent-light);
    font: 11px/16px "Sanakan Mono", monospace;
    letter-spacing: 0.1em;
}

/* conversion of an uploaded file: its tile badge and the uploader's status line */
.job-badge {
    position: absolute;
    left: 6px;
    bottom: 6px;
    padding: 1px 6px;
    background: rgba(14, 14, 17, 0.85);
    border: 1px solid rgba(240, 178, 50, 0.5);
    color: #f0b232;
    font: 11px/16px "Sanakan Mono", monospace;
    letter-spacing: 0.1em;
}

.job-badge.failed {
    border-color: rgba(214, 78, 78, 0.6);
    color: #e06b6b;
}

.media-jobs {
    --corner: rgba(var(--accent-light-rgb), 0.55);
    --fill: rgba(var(--accent-rgb), 0.06);
    max-width: 760px;
    margin: 18px auto 0;
    padding: 12px 16px 14px;
    text-align: left;
}

.media-jobs-head {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 4px 12px;
}

.media-jobs-title {
    font: 13px/1.5 "Sanakan Mono", monospace;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--accent-light);
}

.media-jobs-summary {
    font-size: 13px;
    color: rgba(220, 221, 222, 0.55);
}

.media-jobs-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2px 24px;
    max-height: 190px;
    margin: 10px 0 0;
    padding: 0;
    overflow-y: auto;
    list-style: none;
}

.media-job {
    display: flex;
    align-items: baseline;
    gap: 8px;
    min-width: 0;
    padding: 3px 0;
    font: 12px/1.5 "Sanakan Mono", monospace;
    color: rgba(220, 221, 222, 0.6);
}

.media-job-dot {
    flex: none;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: rgba(220, 221, 222, 0.35);
}

.media-job-name {
    flex: 0 1 auto;
    min-width: 0;
    overflow: hidden;
    color: #efe2f7;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.media-job-state {
    flex: none;
    margin-left: auto;
    white-space: nowrap;
    color: rgba(220, 221, 222, 0.5);
}

.media-job.pending .media-job-dot,
.media-job.converting .media-job-dot {
    background: #f0b232;
    box-shadow: 0 0 6px rgba(240, 178, 50, 0.7);
}

.media-job.converting .media-job-dot {
    animation: media-job-pulse 1.2s ease-in-out infinite;
}

@keyframes media-job-pulse {
    50% { opacity: 0.35; }
}

.media-job.pending .media-job-state,
.media-job.converting .media-job-state {
    color: #f0b232;
}

.media-job.done .media-job-dot {
    background: #7fd18a;
}

.media-job.done .media-job-state {
    color: #7fd18a;
}

.media-job.failed .media-job-dot {
    background: #e06b6b;
}

.media-job.failed .media-job-state {
    color: #e06b6b;
}

.media-jobs-link {
    margin-left: auto;
    color: var(--accent-light);
    font: 13px/1.5 "Sanakan Mono", monospace;
    text-decoration: none;
}

.media-jobs-link:hover {
    color: #fff;
}

/* the tasks page (i/?zadania=1): every job of the account, with details */
.media-clear-form {
    margin: 0;
}

.media-tasks {
    max-width: 900px;
    margin: 18px auto 0;
}

.media-tasks .media-job {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) minmax(0, 2fr) auto;
    align-items: baseline;
    gap: 4px 14px;
    padding: 9px 4px;
    border-bottom: 1px solid rgba(var(--accent-rgb), 0.12);
    font: 13px/1.5 "Sanakan Mono", monospace;
}

.media-task-name {
    min-width: 0;
    overflow: hidden;
    color: #efe2f7;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.media-task-state {
    color: rgba(220, 221, 222, 0.6);
}

.media-job.pending .media-task-state,
.media-job.converting .media-task-state {
    color: #f0b232;
}

.media-job.done .media-task-state {
    color: #7fd18a;
}

.media-job.failed .media-task-state {
    color: #e06b6b;
}

.media-task-time {
    white-space: nowrap;
    color: rgba(220, 221, 222, 0.4);
}

@media (max-width: 640px) {
    .media-tasks .media-job {
        grid-template-columns: auto minmax(0, 1fr);
    }

    .media-task-state,
    .media-task-time {
        grid-column: 2;
    }
}

/* ".." tile, one folder up */
.up .thumb {
    background: rgba(var(--accent-rgb), 0.06);
}

.up-icon {
    width: 34%;
    fill: none;
    stroke: var(--accent-light);
    stroke-width: 1.6;
    stroke-linecap: round;
    stroke-linejoin: round;
    transition: transform 0.2s;
}

.up:hover .up-icon {
    transform: translateY(-4px);
}

.up .name {
    font-weight: 700;
}

/* a folder shows up to three pictures from inside, or a folder icon */
.mosaic {
    display: grid;
    gap: 3px;
    width: 100%;
    height: 100%;
}

.mosaic.n2 {
    grid-template-columns: 1fr 1fr;
}

.mosaic.n3 {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr 1fr;
}

.mosaic.n3 img:first-child {
    grid-row: span 2;
}

.mosaic img {
    min-height: 0;
    object-fit: cover;
}

.folder-icon {
    width: 40%;
    fill: rgba(var(--accent-rgb), 0.35);
}

.label {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 8px 2px 2px;
    min-width: 0;
}

.name {
    overflow: hidden;
    font: 13px "JetBrains Mono", Consolas, monospace;
    color: #efe2f7;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.name-icon {
    width: 14px;
    height: 14px;
    margin-right: 6px;
    vertical-align: -2px;
    fill: var(--accent-light);
}

.folder .name {
    font-weight: 700;
}

.info {
    font-size: 12px;
    color: rgba(220, 221, 222, 0.5);
}

/* in the search results: the folder a tile is in */
.where {
    overflow: hidden;
    font: 11px "JetBrains Mono", Consolas, monospace;
    color: rgba(var(--accent-light-rgb), 0.75);
    text-overflow: ellipsis;
    white-space: nowrap;
}

.empty {
    margin-top: 48px;
    text-align: center;
    color: rgba(220, 221, 222, 0.5);
    font-size: 18px;
}

/* Viewer */
.viewer {
    position: fixed;
    inset: 0;
    z-index: 100;
    display: flex;
    flex-direction: column;
    background: rgba(6, 6, 8, 0.94);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
}

.viewer-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 10px 20px;
    padding: 12px 16px;
    border-bottom: 1px solid rgba(var(--accent-rgb), 0.25);
}

.viewer-title {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.viewer-name {
    overflow: hidden;
    font: 15px "JetBrains Mono", Consolas, monospace;
    color: #efe2f7;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.viewer-details {
    font-size: 13px;
    color: rgba(220, 221, 222, 0.55);
}

.viewer-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.viewer-btn {
    padding: 6px 12px;
    border: 1px solid rgba(var(--accent-rgb), 0.45);
    background: transparent;
    color: var(--accent-light);
    font: 13px/1.5 "Sanakan Mono", monospace;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    cursor: pointer;
    transition: background-color 0.2s, color 0.2s, border-color 0.2s;
}

.viewer-btn:hover {
    background: rgba(var(--accent-rgb), 0.2);
    color: #fff;
}

.viewer-btn.danger {
    border-color: rgba(217, 83, 79, 0.6);
    color: #e57373;
}

.viewer-btn.danger:hover {
    background: rgba(217, 83, 79, 0.25);
    color: #fff;
}

.viewer-btn.done {
    border-color: rgba(35, 165, 90, 0.6);
    color: #3fca7a;
}

.viewer-close {
    font: 22px/1 Lato, sans-serif;
    padding: 2px 12px 6px;
}

/* flex, not grid: a grid row sized by its content makes max-height: 100% on
   the picture indefinite, so a very large one would not fit the screen */
.viewer-stage {
    position: relative;
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 0;
    padding: 16px 72px;
    overflow: hidden;
}

.viewer-img {
    display: block;
    min-width: 0;
    min-height: 0;
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    box-shadow: 0 0 40px rgba(var(--accent-rgb), 0.25);
    transform-origin: center;
    user-select: none;
    -webkit-user-drag: none;
}

/* a zoomed picture can be dragged */
.viewer.zoomed .viewer-img {
    cursor: grab;
}

.viewer.panning .viewer-img {
    cursor: grabbing;
}

.viewer-loading {
    position: absolute;
    font: 14px "Sanakan Mono", monospace;
    letter-spacing: 0.14em;
    color: rgba(220, 221, 222, 0.6);
}

.viewer-nav {
    position: absolute;
    top: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    margin-top: -24px;
    padding: 0;
    border: 0;
    color: var(--text);
    font: 22px/1 Lato, sans-serif;
    cursor: pointer;
}

.viewer-nav:hover {
    --arm: 18px;
    --fill: rgba(var(--accent-rgb), 0.18);
    color: #fff;
}

.viewer-nav.prev {
    left: 12px;
}

.viewer-nav.next {
    right: 12px;
}

body.viewer-open {
    overflow: hidden;
}

@media only screen and (max-width: 600px) {
    .grid {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
        gap: 10px;
    }

    .viewer-stage {
        padding: 12px 8px 72px;
    }

    .viewer-nav {
        top: auto;
        bottom: 12px;
        margin-top: 0;
    }
}

/* Account: Discord login and the logged-in admin */
.ex-top {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

/* Managing files */
.admin-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    flex-basis: 100%;
}

.admin-btn {
    padding: 7px 14px;
    border: 1px solid rgba(var(--accent-rgb), 0.45);
    background: transparent;
    color: var(--accent-light);
    font: 13px "JetBrains Mono", Consolas, monospace;
    cursor: pointer;
    transition: background-color 0.2s, color 0.2s, border-color 0.2s, opacity 0.2s;
}

.admin-btn:hover {
    background: rgba(var(--accent-rgb), 0.2);
    color: #fff;
}

.admin-btn.primary {
    border-color: var(--accent);
    background: rgba(var(--accent-rgb), 0.35);
    color: #fff;
}

.admin-btn.primary:hover {
    background: var(--accent);
}

.admin-btn.danger {
    border-color: rgba(217, 83, 79, 0.6);
    color: #e57373;
}

.admin-btn.danger:hover {
    background: rgba(217, 83, 79, 0.25);
    color: #fff;
}

.admin-btn[aria-pressed="true"] {
    background: rgba(var(--accent-rgb), 0.25);
    color: #fff;
}

.admin-btn:disabled {
    opacity: 0.4;
    cursor: default;
    pointer-events: none;
}

.admin-selection {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.admin-count {
    margin: 0 4px;
    font-size: 13px;
    color: #efe2f7;
}

.admin-hint {
    margin-left: auto;
    font-size: 12px;
    color: rgba(220, 221, 222, 0.45);
}

/* picking tiles to move or delete */
.check {
    position: absolute;
    top: 8px;
    left: 8px;
    z-index: 1;
    display: none;
    width: 22px;
    height: 22px;
    border: 2px solid #efe2f7;
    background: rgba(14, 14, 17, 0.75);
}

body.selecting .check {
    display: block;
}

.tile.selected {
    --corner: #f0d4ff;
    --fill: rgba(var(--accent-rgb), 0.28);
    --arm: 18px;
}

.tile.selected .check {
    border-color: var(--accent);
    background: var(--accent);
}

.tile.selected .check::after {
    content: "";
    position: absolute;
    left: 6px;
    top: 1px;
    width: 6px;
    height: 12px;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

body.selecting .tile.up {
    opacity: 0.35;
}

/* files dragged onto the page */
.drop {
    position: fixed;
    inset: 0;
    z-index: 90;
    display: grid;
    place-items: center;
    background: rgba(8, 8, 10, 0.8);
    pointer-events: none;
}

.drop-box {
    --arm: 30px;
    --corner: var(--accent-light);
    --fill: rgba(var(--accent-rgb), 0.15);
    padding: 48px 64px;
    color: #efe2f7;
    font-size: 20px;
    text-align: center;
}

.progress,
.toast {
    position: fixed;
    left: 50%;
    bottom: 24px;
    z-index: 120;
    width: min(520px, calc(100vw - 32px));
    transform: translateX(-50%);
    padding: 12px 16px;
    border: 1px solid rgba(var(--accent-rgb), 0.45);
    background: rgba(18, 18, 22, 0.96);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
    font-size: 14px;
}

.toast {
    cursor: pointer;
}

.toast.error {
    border-color: rgba(217, 83, 79, 0.6);
    color: #f0b4b2;
}

.progress-text {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.progress-bar {
    display: block;
    height: 4px;
    margin-top: 8px;
    background: rgba(var(--accent-rgb), 0.2);
}

.progress-bar span {
    display: block;
    width: 0;
    height: 100%;
    background: var(--accent-light);
    transition: width 0.2s;
}

/* dialogs for a new folder, moving and deleting */
.ex-dialog {
    width: min(460px, calc(100vw - 32px));
    padding: 22px 24px;
    border: 1px solid rgba(var(--accent-rgb), 0.45);
    background: #121216;
    color: var(--text);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.7);
}

.ex-dialog::backdrop {
    background: rgba(4, 4, 6, 0.7);
    -webkit-backdrop-filter: blur(4px);
    backdrop-filter: blur(4px);
}

.ex-dialog h2 {
    margin: 0 0 6px;
    font-size: 18px;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #efe2f7;
}

.ex-dialog p {
    margin: 0 0 14px;
    font-size: 14px;
    color: rgba(220, 221, 222, 0.75);
    overflow-wrap: anywhere;
}

.ex-dialog input[type="text"],
.ex-dialog select {
    width: 100%;
    margin-bottom: 14px;
    padding: 10px 12px;
    border: 1px solid rgba(var(--accent-rgb), 0.4);
    background: #0b0b0d;
    color: var(--text);
    font: 16px Lato, sans-serif;
    outline: 0;
}

.ex-dialog input[type="text"]:focus,
.ex-dialog select:focus {
    border-color: var(--accent-light);
}

.ex-dialog select {
    padding: 6px;
    font: 14px "JetBrains Mono", Consolas, monospace;
}

.ex-dialog option {
    padding: 4px 6px;
}

.ex-dialog option:disabled {
    color: rgba(220, 221, 222, 0.3);
}

.ex-dialog option:checked {
    background: rgba(var(--accent-rgb), 0.45);
    color: #fff;
}

.dialog-warning {
    color: #e8d5a8 !important;
}

.dialog-error {
    color: #f0b4b2 !important;
}

.dialog-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
}

/* Manual change to WebP: the quality choice and the comparison of the result */
.ex-dialog.webp-result {
    width: min(760px, calc(100vw - 32px));
}

.webp-quality {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 14px;
    font: 14px "JetBrains Mono", Consolas, monospace;
    color: rgba(220, 221, 222, 0.8);
}

.webp-quality output {
    min-width: 2.4em;
    text-align: right;
    color: var(--accent-light);
}

.webp-quality input[type="range"] {
    flex: 1;
    accent-color: var(--accent-light);
}

.webp-processing {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 14px;
    color: rgba(220, 221, 222, 0.8);
    font: 14px "JetBrains Mono", Consolas, monospace;
}

.webp-spinner {
    flex: none;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(var(--accent-rgb), 0.35);
    border-top-color: var(--accent-light);
    border-radius: 50%;
    animation: webp-spin 0.8s linear infinite;
}

@keyframes webp-spin {
    to { transform: rotate(360deg); }
}

.webp-compare {
    position: relative;
    overflow: hidden;
    background: #0b0b0d;
    border: 1px solid rgba(var(--accent-rgb), 0.3);
}

.webp-divider {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 50%;
    z-index: 2;
    width: 2px;
    margin-left: -1px;
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 0 8px rgba(0, 0, 0, 0.65);
    pointer-events: none;
}

.webp-compare img {
    display: block;
    width: 100%;
    height: auto;
    max-height: 58vh;
    object-fit: contain;
}

.webp-compare .webp-new {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.webp-tag {
    position: absolute;
    top: 6px;
    padding: 1px 6px;
    background: rgba(14, 14, 17, 0.8);
    border: 1px solid rgba(var(--accent-rgb), 0.5);
    color: var(--accent-light);
    font: 11px/16px "Sanakan Mono", monospace;
    letter-spacing: 0.1em;
}

.webp-tag.orig {
    left: 6px;
}

.webp-tag.new {
    right: 6px;
}

.webp-slider {
    width: 100%;
    margin: 10px 0 16px;
    accent-color: var(--accent-light);
}

/* login screen, shown instead of the gallery without access */
.locked {
    --corner: rgba(var(--accent-light-rgb), 0.6);
    --fill: rgba(var(--accent-rgb), 0.06);
    max-width: 480px;
    margin: 48px auto 0;
    padding: 36px 32px 32px;
    text-align: center;
}

.lock-icon {
    width: 44px;
    height: 44px;
    fill: none;
    stroke: var(--accent-light);
    stroke-width: 1.6;
    stroke-linecap: round;
}

.locked h2 {
    margin: 14px 0 8px;
    font-size: 20px;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #efe2f7;
}

.locked p {
    margin: 0 0 22px;
    color: rgba(220, 221, 222, 0.7);
}

.locked p:last-child {
    margin-bottom: 0;
}

.locked .admin-btn {
    display: inline-block;
    padding: 10px 20px;
    font-size: 15px;
}

/* "change to WebP" next to the upload button */
.admin-check {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 4px;
    font-size: 13px;
    color: rgba(220, 221, 222, 0.75);
    cursor: pointer;
}

.admin-check input {
    width: 16px;
    height: 16px;
    margin: 0;
    accent-color: var(--accent);
    cursor: pointer;
}

/* asking for access, on the locked gallery */
.request-form {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
    margin-top: 6px;
}

.request-form input[type="text"] {
    flex: 1 1 220px;
    max-width: 320px;
    padding: 7px 10px;
    border: 1px solid rgba(var(--accent-rgb), 0.35);
    background: #0b0b0d;
    color: var(--text);
    font: 14px Lato, sans-serif;
    outline: 0;
}

.request-form input[type="text"]:focus {
    border-color: var(--accent);
}

.request-sent {
    color: #3fca7a;
}

/* the whole folder as a ZIP, next to the sorting */
.toolbar .zip-btn {
    padding: 8px 14px;
    font: 13px/1.5 "Sanakan Mono", monospace;
    letter-spacing: 0.1em;
    text-decoration: none;
}

/* The trash of an account's own folder (i/?kosz=1), rows like the panel's */
.gallery-trash .trash-row {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(0, 2fr) auto;
    align-items: center;
    gap: 8px 16px;
    padding: 10px 2px;
    border-bottom: 1px solid rgba(var(--accent-rgb), 0.12);
}

.gallery-trash .trash-name {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.gallery-trash .trash-name b {
    overflow: hidden;
    font: 700 14px "JetBrains Mono", Consolas, monospace;
    color: #efe2f7;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.gallery-trash .trash-name code {
    overflow-wrap: anywhere;
    font: 12px "JetBrains Mono", Consolas, monospace;
    color: rgba(var(--accent-light-rgb), 0.75);
}

.gallery-trash .trash-info {
    font-size: 13px;
    color: rgba(220, 221, 222, 0.55);
}

.gallery-trash .trash-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: flex-end;
}

@media (max-width: 640px) {
    .gallery-trash .trash-row {
        grid-template-columns: 1fr;
    }

    .gallery-trash .trash-actions {
        justify-content: flex-start;
    }
}
