/*===================================*/
/*========== UPLOADS ==========*/
/*===================================*/
/* .uploadimages,
.uploadcaption,
.uploaduser {
    background-color: var(--secondary-colour);
    margin: 3px;
    display: inline-grid;
    padding: 3px;
    border-radius: var(--padding-lg);
    text-align: center;
} */

/*******************************************************-----------------******************************************************/
/******************************************************* CSS VARIABLES FOR THREADING *************************************************/
/*******************************************************-----------------******************************************************/

/* Add threading variables to eliminate magic numbers */
:root {
    /* Avatar measurements */
    --avatar-size: 32px;
    --avatar-padding: 8px;
    --avatar-gap: 10px;
    --avatar-center: calc(var(--avatar-padding) + (var(--avatar-size) / 2));

    /* Threading line measurements */
    --spine-width: 2px;
    --curve-width: 23px;
    --curve-height: 38px;
    --curve-radius: 12px;
    --curve-top-offset: -15px;
    --first-curve-height: 25px;
    --reply-indent: 45px;

    /* Derived values (no magic numbers!) */
    --curve-left-offset: calc(var(--avatar-center) - (var(--curve-width) * 2) + (var(--spine-width) / 2));
    --spine-stop-at-curve: calc(var(--curve-height) + var(--curve-top-offset));
}

/*******************************************************-----------------******************************************************/
/******************************************************* CSS FOR EDIT.PHP *************************************************/
/*******************************************************-----------------******************************************************/

/* Edit gallery wrapper — grid + pagination footer */
.edit-gallery-section {
    margin-bottom: 30px;
}

/* Grid container for edit.php cards */
.edit-items-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.edit-gallery-pagination {
    width: 100%;
    margin-top: 24px;
    padding-top: 20px;
    padding-bottom: 8px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.edit-gallery-pagination .pagination {
    margin-top: 0;
    margin-bottom: 0;
}

/* Label row: primary label left, .uploadinfo hint right (e.g. Timestamp) */
.card-field-label-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 8px;
    margin-bottom: 4px;
}

.card-field-label-row label {
    margin-bottom: 0;
}

.card-field-label-row .uploadinfo {
    font-size: 11px;
    margin: 0;
    padding: 0;
    flex-shrink: 0;
}

@media (max-width: 768px) {
    .edit-items-grid {
        grid-template-columns: 1fr;
    }
}

/* Card — theme-aware background/border, create.php card dimensions & shape */
.edit-item {
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: visible;
    color: var(--font-colour_offwhite);
    background-color: var(--desc-bg);
    border-radius: 8px;
    border: var(--desc-border-style);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
    transition: border-color 0.2s;
}

.edit-item.modified {
    border-left: 5px solid #ffc107;
    background-color: rgba(255, 193, 7, 0.08);
}

.edit-item img {
    display: block;
    max-height: 300px;
    min-height: 300px;
    width: auto;
    margin-bottom: 10px;
    object-fit: contain;
}

.edit-item img.selected {
    outline: 3px solid #007bff;
    outline-offset: -3px;
}

/* Field labels — compact, muted, uppercase-feeling weight */
.edit-item label {
    display: block;
    font-size: 11px;
    color: var(--font-colour_offwhite);
    font-weight: bold;
    opacity: 0.7;
    margin-bottom: 4px;
}

/* Inputs & selects — dark transparent style matching create.php cards */
.edit-item input,
.edit-item select {
    width: 100%;
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--font-colour_white);
    padding: 7px 10px;
    border-radius: 4px;
    font-size: 13px;
    outline: none;
    transition: border-color 0.2s;
    box-sizing: border-box;
}

.edit-item input:focus,
.edit-item select:focus {
    border-color: var(--main-colour);
}

/* Remove the old default bottom-margin that caused uneven spacing */
.edit-item input,
.edit-item select {
    margin-bottom: 0;
}



.success {
    color: var(--sales-price-green);
    background: var(--bg-colour);
    padding: var(--padding-md);
    border: var(--border-width-thin) solid var(--main-colour);
    width: fit-content;
    margin: 0 auto;
}

.error {
    color: var(--font-colour_white);
    background: var(--gallery-font_shadow);
    padding: var(--padding-md);
    border: var(--border-width) solid var(--sales-bright-red);
    width: fit-content;
    margin: 0 auto;
    font-weight: bold;
}

.alert {
    padding: 15px;
    margin: 10px 0;
    border: 1px solid transparent;
    border-radius: 4px;
    max-width: 400px;
}

.alert-success {
    color: var(--main-colour);
    background-color: rgba(0, 80, 0, 0.2);
    border-color: var(--main-colour);
}

.alert-danger {
    color: var(--secondary-colour);
    background-color: rgba(120, 0, 0, 0.2);
    border-color: var(--secondary-colour);
}

.submit_buttons {
    display: flex;
}


/* ===== SHARED FLOATING ACTION BAR (create.php + edit.php) ===== */

.floating-action-bar {
    position: fixed;
    bottom: -100px;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.95);
    border-top: 2px solid var(--main-colour);
    padding: 15px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 1000;
    transition: bottom 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 -5px 25px rgba(0, 0, 0, 0.7);
}

.floating-action-bar.visible {
    bottom: 0;
}

/* Prevent content being hidden behind the floating bar when it's open */
body.floating-bar-open {
    padding-bottom: 90px;
    transition: padding-bottom 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@media (max-width: 768px) {
    body.floating-bar-open {
        padding-bottom: 160px;
    }
}

.action-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.selected-count-pill {
    background: var(--main-colour);
    color: var(--font-colour_white);
    padding: 4px 12px;
    border-radius: 20px;
    font-weight: bold;
    font-size: 14px;
    font-family: 'Amaranth', sans-serif;
}

.action-buttons-group {
    display: flex;
    gap: 12px;
}

.action-btn {
    padding: 10px 22px;
    font-family: 'Amaranth', sans-serif;
    font-size: 15px;
    font-weight: bold;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    transition: all 0.3s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.action-btn.approve {
    background: #27ae60;
    color: #fff;
}

.action-btn.approve:hover {
    background: #2ecc71;
    box-shadow: 0 0 10px rgba(46, 204, 113, 0.3);
}

.action-btn.discard {
    background: none;
    border: 2px solid #c0392b;
    color: #e74c3c;
}

.action-btn.discard:hover {
    background: #c0392b;
    color: #fff;
    box-shadow: 0 0 10px rgba(192, 57, 43, 0.3);
}

.action-btn.cancel {
    background: rgba(255, 255, 255, 0.1);
    color: #eee;
}

.action-btn.cancel:hover {
    background: rgba(255, 255, 255, 0.2);
}

@media (max-width: 768px) {
    .floating-action-bar {
        flex-direction: column;
        gap: 15px;
        padding: 20px;
        text-align: center;
    }

    .action-buttons-group {
        width: 100%;
    }

    .action-btn {
        flex: 1;
        justify-content: center;
    }
}

/*******************************************************-----------------******************************************************/
/******************************************************* CSS FOR UPLOAD FORM *************************************************/
/*******************************************************-----------------******************************************************/

/* Container for upload form and hashtag search */
.upload-search-container {
    display: flex;
    gap: 15px;
    justify-content: center;
    align-items: flex-start;
    width: 95%;
}

.uploadbuttonsbody {
    flex: 2;
    display: flex;
    justify-content: center;
    min-width: 50%;
}

.uploadbuttons {
    background-color: var(--main-colour_clear);
    padding: var(--padding-lg) var(--padding-lg) 0;
    border-radius: var(--padding-sm);
    display: block;
    width: 100%;
    border: var(--border-width-thin) solid var(--border-colour);
    box-sizing: border-box;
}

.hashtag-search {
    flex: 1;
    background-color: var(--main-colour_clear);
    padding: 10px;
    border-radius: 10px;
    border: var(--border-width-thin) solid var(--border-colour);
    box-sizing: border-box;
    min-width: 300px;
}

.hashtag-search form {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.hashtag-search input[type="text"] {
    width: 100%;
    padding: 8px;
    border-radius: 5px;
    border: var(--border-width-thin) solid var(--border-colour);
    background-color: var(--sidebar-menu_bg2);
    color: var(--font-colour_offwhite);
    outline: none;
}

.hashtag-search button {
    padding: 10px 20px;
    color: var(--font-colour_white);
    border-radius: 5px;
    cursor: pointer;
    font-family: 'Amaranth', sans-serif;
}

.search-buttons-container {
    display: flex;
    justify-content: center;
    gap: 5px;
    width: 100%;
}

/* Row layout for form fields */
.upload-row {
    display: flex;
    gap: 10px;
    margin-bottom: 5px;
    align-items: flex-start;
}

.upload-col-left,
.upload-col-right {
    flex: 1;
    display: flex;
    flex-direction: column;
}

/* Individual field containers */
.uploadimages,
.uploadcaption,
.uploaduser,
.uploadtype,
.uploadhashtags {
    background-color: var(--secondary-colour);
    padding: 10px;
    border-radius: 10px;
    text-align: center;
    flex: 1;
}

.uploadinfo {
    color: var(--link-colour);
    font-size: var(--font-base);
    text-align: right;
    padding-inline-end: var(--padding-sm);
}

.uploadimages {
    border: 2px dashed var(--border-colour);
    background-color: var(--main-colour);
    min-height: 200px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.uploadimages .upload-label {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 100%;
    cursor: pointer;
    color: var(--font-colour_white);
    font-family: 'Amaranth', sans-serif;
}

.uploadimages .upload-text {
    padding: 10px;
}

.uploadimages #image-preview {
    max-width: 150px;
    max-height: 150px;
    object-fit: contain;
    margin-bottom: 5px;
    display: block;
}

.uploadimages #file-name {
    font-size: x-small;
    color: var(--font-colour_offwhite);
    word-break: break-all;
    padding: 0 10px;
}

.uploadhashtags {
    min-height: 200px;
    display: flex;
    flex-direction: column;
}

/* Input styles matching style.css */
/* input[type="text"] {
    position: relative;
    left: 0;
    outline: none;
    border: var(--border-width-thin) solid var(--border-colour);
    background-color: var(--sidebar-menu_bg2);
    color: var(--font-colour_offwhite);
    padding: var(--padding-xs) var(--padding-sm);
    border-radius: var(--padding-lg);
    width: 100%;
    box-sizing: border-box;
} */

/* Button styles from sales_style.css */
/* Button styles moved to buttons.css */
/* .red-button,
.main-comment-form button,
.reply-form button,
.reply-form .cancel-reply,
.delete-button,
button[type="submit"] {
    display: inline-block;
    box-sizing: border-box;
    cursor: pointer;
    background: var(--sales-light-red);
    color: var(--font-colour_white);
    border: 2px solid var(--sales-red);
    border-radius: 10px;
    padding: 10px 18px;
    font-size: 1rem;
    font-family: 'Amaranth', sans-serif;
    text-decoration: none;
    text-align: center;
    margin: 2px 6px;
    transition: background 0.3s ease;
    min-width: 80px;
}

.red-button:hover,
.main-comment-form button:hover,
.reply-form button:hover,
.delete-button:hover,
button[type="submit"]:hover {
    background: var(--sales-hover-red);
}

.red-button:active,
button[type="submit"]:active {
    background: var(--sales-dark-red);
} */

.date-nav a.active {
    font-weight: bold;
    border: var(--border-width-thin) solid var(--border-colour);
}

/* Moved to buttons.css
.red-button.active {
    font-weight: bold;
    color: var(--font-colour_white);
    background-color: var(--sales-red);
}

.red-button.active:hover {
    background: var(--sales-hover-red);
} */

#hashtags {
    width: 100%;
    flex: 1;
    background-color: var(--sidebar-menu_bg2);
    border: var(--border-width-thin) solid var(--border-colour);
    border-radius: 5px;
    padding: 5px;
    resize: none;
    box-sizing: border-box;
    color: var(--font-colour_offwhite);
}

select {
    width: 100%;
    background-color: var(--sidebar-menu_bg2);
    color: var(--font-colour_offwhite);
    border: var(--border-width-thin) solid var(--border-colour);
    border-radius: 10px;
    padding: 5px;
}

.hashtags-input {
    width: 100%;
    padding: 5px;
    margin-top: 5px;
}

.hashtag-suggestions {
    position: absolute;
    background: white;
    border: 1px solid #ccc;
    max-height: 150px;
    overflow-y: auto;
    width: 200px;
    z-index: 1000;
}

.hashtag-suggestions div {
    padding: 5px;
    cursor: pointer;
}

.hashtag-suggestions div:hover {
    background: #f0f0f0;
}

.comment-indicator {
    height: 100%;
    max-height: 15px;
    width: auto;
    display: none;
    margin: 0 auto;
}

.comment-indicator.visible {
    display: inline-block;
    align-self: center;
}

/* Mobile responsive */
@media (max-width: 1200px) {
    .upload-search-container {
        flex-direction: column;
        width: 95%;
    }

    .uploadbuttonsbody,
    .hashtag-search {
        width: 100%;
    }

    .hashtag-search {
        min-width: unset;
    }
}

@media (max-width: 768px) {
    .upload-row {
        flex-direction: row;
        gap: 10px;
    }

    .uploadimages {
        min-height: 150px;
    }

    /* .uploadhashtags {
        min-height: 120px;
    } */
}

.album-navbody {
    text-align: center;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    background-color: var(--main-colour_clear);
    border-radius: 10px;
    width: clamp(50%, 75%, 100%);
    margin: 20px auto;
    border: var(--border-width-thin) solid var(--border-colour);
    padding: 20px;
    box-sizing: border-box;
}

@media (max-width: 768px) {
    .album-navbody {
        width: 95%;
        padding: 10px;
    }
}

.album-nav {
    display: inline-block;
    text-align: center;
    width: 100%;
}

.date-nav {
    border-radius: 5px;
    display: inline-block;
    text-align: center;
}

/* Pagination styles moved to buttons.css */
/* .pagination {
    text-align: center;
    margin-top: 20px;
}

.pagination a,
.pagination span {
    margin: 0 5px;
    padding: 5px 10px;
    white-space: nowrap;
} */

/*******************************************************-----------------******************************************************/
/******************************************************* CSS FOR VIEW_IMAGE.PHP *************************************************/
/*******************************************************-----------------******************************************************/

.image-viewer {
    max-width: 800px;
    margin: 20px auto;
    padding: 20px;
    background-color: var(--desc-bg);
    border: var(--border-width-thin) solid var(--border-colour);
    border-radius: 10px;
}

.navigation {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
}

.navigation a {
    color: var(--link-colour);
    text-decoration: none;
}

.image-viewer img {
    max-width: 100%;
    height: auto;
    border-radius: 5px;
}

.image-info_viewimage {
    position: relative;
    bottom: 0;
    left: 0;
    right: 0;
    background-color: rgba(0, 0, 0, 0.9);
    color: var(--font-colour_white);
    padding: 5px;
    font-weight: bold;
}


/* --- Threaded Comments Styles --- */
.thread-node {
    position: relative;
    /* No scope here - it lives in parent scope */
}

.comment-wrapper {
    margin-bottom: 15px;
    position: relative;
    anchor-scope: --comment-box, --last-reply-anchor;
}

.comment-box {
    display: flex;
    align-items: flex-start;
    background-color: var(--secondary-colour);
    padding: var(--avatar-padding);
    border-radius: 5px;
    margin-bottom: 0;
    border: 1px solid var(--border-colour);
    position: relative;
    anchor-name: --comment-box;
}

.comment-box.reply {
    background-color: var(--link-colour_visited);
}

.avatar {
    width: var(--avatar-size);
    height: var(--avatar-size);
    margin-right: 12px;
    border-radius: 50%;
    background-color: var(--secondary-colour);
    color: var(--font-colour_white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 16px;
    text-transform: uppercase;
    border: 1px solid var(--border-colour);
    flex-shrink: 0;
}

.username-input {
    width: 100%;
    padding: 8px;
    border-radius: 5px;
    border: var(--border-width-thin) solid var(--border-colour);
    color: var(--font-colour_offwhite);
    margin-bottom: 5px;
}

.avatar-placeholder {
    width: var(--avatar-size);
    height: var(--avatar-size);
    margin-right: 10px;
    border-radius: 50%;
    border: 1px dotted var(--border-colour);
    display: block;
}

/* The actual visual box for the comment text */
.comment-content {
    flex: 1;
    /* Styles moved back to .comment-box */
}

.comment-box.reply .comment-content {
    background-color: transparent;
}

.comment-header {
    margin-bottom: 2px;
}

.comment-username {
    font-weight: bold;
    color: var(--font-colour_white);
    font-size: 14px;
}

.comment-text {
    color: var(--font-colour_offwhite);
    font-size: 14px;
    line-height: 1.3;
}

.comment-meta {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 5px;
    position: relative;
    padding-left: calc(var(--avatar-size) + var(--avatar-gap));
}

.comment-timestamp {
    color: var(--font-colour_offwhite);
    font-size: 12px;
}

.reply-button {
    color: var(--font-colour_white);
    cursor: pointer;
    font-size: 14px;
    font-variant: all-small-caps;
    font-weight: bold;
    max-width: fit-content;
    display: block;
}

/*******************************************************-----------------******************************************************/
/******************************************************* IMPROVED THREADING SYSTEM *************************************************/
/*******************************************************-----------------******************************************************/

.replies {
    position: static;
    border-left: none;
    margin-left: 0;
    padding-left: var(--reply-indent);
}

/* Vertical Spine for Replies - Fixed for all nesting depths */

/* The spine extends from parent comment bottom to the last reply's curve start */
.replies::before {
    content: "";
    position: absolute;
    position-anchor: --comment-box;
    top: anchor(bottom);
    left: anchor(left);
    margin-left: var(--avatar-center);
    width: var(--spine-width);
    background: var(--border-colour);
    z-index: 0;
    /* Default: hide the spine */
    display: none;
}

/* Create a wider hoverable area over the threading line */
.replies::after {
    content: "";
    position: absolute;
    position-anchor: --comment-box;
    top: anchor(bottom);
    left: anchor(left);
    margin-left: calc(var(--avatar-center) - 10px);
    width: 20px;
    bottom: 0;
    z-index: 1;
    pointer-events: auto;
    display: none;
}

/* Show hoverable area when spine is visible */
.comment-box.has-replies+.comment-meta+.reply-form-container+.replies::after {
    display: block;
    bottom: anchor(--last-reply-anchor top);
}

/* For last thread-node in replies, use this as anchor reference */
.replies>.thread-node:last-child {
    anchor-name: --last-reply-anchor;
}

/* Hide spine when comment has no replies */
.comment-box:not(.has-replies)+.comment-meta+.reply-form-container+.replies::before {
    display: none;
}

/* Show spine when comment has replies - bottom anchored to last reply */
.comment-box.has-replies+.comment-meta+.reply-form-container+.replies::before {
    display: block;
    /* Bottom is anchored to the last reply thread-node's top */
    bottom: anchor(--last-reply-anchor top);
}

/* Hide spine when only one reply exists (curve alone handles connection) */
.replies:has(> .thread-node:only-child)::before {
    display: none;
}

/* Curved Connector for Child Comments - No more magic numbers! */
.replies>.thread-node::before {
    content: "";
    position: absolute;
    position-anchor: --comment-box;
    left: anchor(left);
    margin-left: var(--curve-left-offset);
    width: var(--curve-width);
    top: var(--curve-top-offset);
    height: var(--curve-height);
    border-bottom: var(--spine-width) solid var(--border-colour);
    border-left: var(--spine-width) solid var(--border-colour);
    border-bottom-left-radius: var(--curve-radius);
    z-index: 0;
    pointer-events: none;
}

/* Fix for first child */
.replies>.thread-node:first-child::before {
    top: anchor(bottom);
    height: var(--first-curve-height);
    border-top: none;
}

/* Create a hover zone on the left side of each thread-node (over threading lines) */
.thread-node::after {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: var(--reply-indent);
    z-index: 1;
    pointer-events: auto;
}

/* Thread hover highlight - like Reddit */
.replies::before,
.replies>.thread-node::before {
    transition: background-color 0.15s ease, border-color 0.15s ease;
}

/* Make sure comment content is above hover zone and blocks hover events */
.comment-box,
.comment-meta,
.reply-form-container {
    position: relative;
    z-index: 3;
}

/* ========== HOVER LOGIC ========== */

/* 
 * HOVER BEHAVIOR - CLEAN APPROACH:
 * Only the DEEPEST hovered thread should have its connections highlighted.
 * We use :not(:has(.thread-node:hover)) to identify the deepest hovered thread.
 * 
 * Connections to highlight for the deepest hovered thread:
 * 1. Its own curve (connecting to its parent)
 * 2. Its children's spine (below it)
 * 3. Its children's curves
 * 4. The parent's spine portion leading to it
 */

/* ===== STEP 1: Only highlight for the DEEPEST hovered thread ===== */
/* This thread is hovered AND has no hovered descendants */

/* NOTE: We do NOT highlight the curve ABOVE the hovered thread (connecting to parent)
   We only highlight: children's spine, children's curves, and parent's spine */

/* 1. Deepest thread's children's spine */
.thread-node:hover:not(:has(.thread-node:hover))>.comment-wrapper>.replies::before {
    background-color: var(--font-colour_lightgrey);
}

/* 3. Deepest thread's children's curves */
.thread-node:hover:not(:has(.thread-node:hover))>.comment-wrapper>.replies>.thread-node::before {
    border-color: var(--font-colour_lightgrey);
}

/* 4. Parent spine of the deepest hovered thread */
.replies:has(> .thread-node:hover:not(:has(.thread-node:hover)))::before {
    background-color: var(--font-colour_lightgrey);
}

/* ===== STEP 2: Disable highlighting when hovering comment content ===== */

.thread-node:hover:not(:has(.thread-node:hover)):has(.comment-box:hover)::before,
.thread-node:hover:not(:has(.thread-node:hover)):has(.comment-meta:hover)::before {
    border-color: var(--border-colour);
}

.thread-node:hover:not(:has(.thread-node:hover)):has(.comment-box:hover)>.comment-wrapper>.replies::before,
.thread-node:hover:not(:has(.thread-node:hover)):has(.comment-meta:hover)>.comment-wrapper>.replies::before {
    background-color: var(--border-colour);
}

.thread-node:hover:not(:has(.thread-node:hover)):has(.comment-box:hover)>.comment-wrapper>.replies>.thread-node::before,
.thread-node:hover:not(:has(.thread-node:hover)):has(.comment-meta:hover)>.comment-wrapper>.replies>.thread-node::before {
    border-color: var(--border-colour);
}

.replies:has(> .thread-node:hover:not(:has(.thread-node:hover)):has(.comment-box:hover))::before,
.replies:has(> .thread-node:hover:not(:has(.thread-node:hover)):has(.comment-meta:hover))::before {
    background-color: var(--border-colour);
}

.reply-form {
    display: flex;
    align-items: flex-start;
    background-color: var(--sales-light-red);
    padding: 10px;
    border-radius: 5px;
    gap: 10px;
    flex-wrap: wrap;
    margin: 5px 0px 5px var(--reply-indent);
    border: var(--border-width-thin) solid var(--border-colour);
}

.reply-form .avatar {
    margin-top: 5px;
    min-width: var(--avatar-size);
}

.reply-form textarea {
    width: 100%;
    min-height: 75px;
    max-height: 200px;
    resize: vertical;
    border: var(--border-width-thin) solid var(--border-colour);
    border-radius: 4px;
    padding: 5px;
    font-size: 14px;
    box-sizing: border-box;
    background-color: var(--sidebar-menu_bg2);
    color: var(--font-colour_offwhite);
}

/* Character counter styles */
.char-counter {
    font-size: 12px;
    color: var(--font-colour_grey);
    text-align: right;
    margin-top: 2px;
    margin-bottom: 5px;
}

.char-counter.near-limit {
    color: #f0ad4e;
}

.char-counter.at-limit {
    color: var(--sales-bright-red);
    font-weight: bold;
}

.reply-form .cancel-reply,
.delete-button {
    background-color: var(--lightbox-bg);
    color: var(--font-colour_offwhite);
    border: 1px solid var(--border-colour);
    font-size: var(--font-sm);
    max-height: fit-content !important;
    align-self: self-end;
    padding: 5px !important;
}

.main-comment-form {
    display: flex;
    align-items: flex-start;
    margin-top: 15px;
    background-color: var(--main-colour);
    padding: 10px;
    border-radius: 5px;
    gap: 10px;
    flex-wrap: wrap;
    border: var(--border-width-thin) solid var(--border-colour);
}

.main-comment-form .avatar {
    margin-top: 5px;
    flex-shrink: 0;
    min-width: var(--avatar-size);
}

.main-comment-form textarea {
    width: 100%;
    min-height: 75px;
    max-height: 200px;
    resize: vertical;
    border: var(--border-width-thin) solid var(--border-colour);
    border-radius: 4px;
    padding: 5px;
    font-size: 14px;
    box-sizing: border-box;
    background-color: var(--sidebar-menu_bg2);
    color: var(--font-colour_offwhite);
}

.hashtags {
    color: var(--link-colour);
    margin-top: 5px;
    display: block;
}

/*******************************************************-----------------******************************************************/
/******************************************************* CSS FOR UPLOADS GALLERY *************************************************/
/*******************************************************-----------------******************************************************/

.uploadbody {
    color: var(--font-colour_offwhite);
    font-family: 'Amaranth', sans-serif;
    /* background-color: var(--bg-colour); */
}

.uploads-gallery {
    display: inline-block;
    background-color: none;
    padding: var(--padding-lg) var(--padding-lg) 0;
    margin-top: var(--padding-lg);
    border-radius: var(--padding-sm);
}

.uploadcontainer {
    position: relative;
    display: inline-block;
    background-color: var(--secondary-colour);
    margin-right: var(--padding-md);
    margin-bottom: var(--padding-md);
    border-radius: var(--padding-lg);
    padding: var(--padding-md);
    border: 2px solid var(--border-colour);
    overflow: hidden;
}

/* Caption above image */
.uploadcontainer .caption {
    color: var(--font-colour_white);
    text-transform: capitalize;
    font-weight: bold;
    padding: 0 0 var(--padding-sm) 0;
    text-align: left;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    width: 100%;
}

/* Image container */
.uploadcontainer .image-link {
    display: block;
    overflow: hidden;
    border-radius: var(--padding-sm);
}

.upload {
    display: block;
    width: 100%;
    height: var(--vinyl-h);
    object-fit: cover;
    border-radius: var(--padding-sm);
    transition: transform 0.3s ease;
}

.uploadcontainer:hover .upload {
    transform: scale(1.05);
}

/* Details below image */
.upload-details {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    padding-top: var(--padding-sm);
    gap: var(--padding-xs);
}

.upload-details .type {
    color: var(--sidebar-menu_bg2);
    font-variant: all-small-caps;
    font-size: 0.85rem;
    text-align: left;
}

.upload-details .username {
    color: var(--font-colour_grey);
    font-variant: all-petite-caps;
    font-size: 0.85rem;
    text-align: right;
    /* margin-left: auto; */
}

.moderation-header {
    margin-bottom: 20px;
    padding: 15px;
    background: var(--desc-bg);
    border: 1px solid var(--main-colour);
    border-radius: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* .admin-button styles moved to css/buttons.css (source of truth) */

/* .delete-upload {
    position: absolute;
    top: 0;
    background-image: linear-gradient(to left, rgba(0, 0, 0, 1), rgba(0, 0, 0, 0));
    color: var(--font-colour_offwhite);
    width: 100%;
    transition: var(--transition-slow);
    opacity: 0;
    font-size: var(--font-lg);
    font-family: 'Signika', sans-serif;
    padding: 0 var(--padding-sm);
    text-align: right;
    border-radius: var(--padding-lg) var(--padding-lg) 0 0;
    left: 1px;
}

.uploadcontainer:hover .delete-upload,
.uploadcontainer:active .delete-upload {
    opacity: 1;
} */
/*******************************************************-----------------******************************************************/
/******************************************************* CSS FOR CREATE.PHP *************************************************/
/*******************************************************-----------------******************************************************/

:root {
    --accent-red: #c33;
    --accent-red-hover: #e44;
    --dark-glass-bg: rgba(20, 10, 10, 0.7);
    --dark-card-bg: rgba(10, 5, 5, 0.85);
    --glass-border: 1px solid rgba(178, 34, 34, 0.25);
    --font-inter: 'Inter', sans-serif;
    --font-title: 'Amaranth', sans-serif;
}

.dashboard-container {
    max-width: 1400px;
    margin: 0 auto;
    animation: fadeIn 0.4s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(15px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* Header – create.php keeps its dark glassmorphism look */
.dashboard-header {
    background: var(--dark-glass-bg);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: var(--glass-border);
    border-radius: 12px;
    padding: 20px 30px;
    margin-bottom: 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.6);
}

.header-title h1 {
    font-family: var(--font-title);
    font-size: 28px;
    color: #fff;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    gap: 12px;
}

.header-title p {
    font-size: 13px;
    color: #a09090;
    margin-top: 3px;
}

.header-actions {
    display: flex;
    gap: 12px;
    align-items: center;
}

.btn-panel {
    padding: 10px 18px;
    font-family: var(--font-title);
    font-size: 15px;
    background: rgba(178, 34, 34, 0.15);
    border: 1px solid var(--accent-red);
    border-radius: 6px;
    color: #fff;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-panel:hover {
    background: var(--accent-red);
    box-shadow: 0 0 10px rgba(178, 34, 34, 0.3);
}

.btn-panel.logout {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.2);
    color: #ff6b6b;
}

.btn-panel.logout:hover {
    background: rgba(255, 107, 107, 0.15);
    border-color: #ff6b6b;
}

/* Navigation Tabs */
.tabs-nav {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    border-bottom: 2px solid rgba(178, 34, 34, 0.15);
    padding-bottom: 5px;
}

.tab-btn {
    background: none;
    border: none;
    color: #a09090;
    font-family: var(--font-title);
    font-size: 18px;
    padding: 12px 24px;
    cursor: pointer;
    transition: all 0.3s;
    position: relative;
    border-radius: 6px 6px 0 0;
}

.tab-btn:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.03);
}

.tab-btn.active {
    color: #fff;
    font-weight: bold;
}

.tab-btn.active::after {
    content: '';
    position: absolute;
    bottom: -7px;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--accent-red);
    border-radius: 3px;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* Card Section */
.dashboard-section {
    background: var(--dark-glass-bg);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: var(--glass-border);
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.6);
    margin-bottom: 25px;
}

/* Upload Area */
.dropzone-container {
    border: 2px dashed rgba(178, 34, 34, 0.4);
    background: rgba(10, 5, 5, 0.4);
    border-radius: 8px;
    padding: 50px 30px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    margin-bottom: 25px;
    position: relative;
}

.dropzone-container:hover,
.dropzone-container.dragover {
    border-color: var(--accent-red-hover);
    background: rgba(178, 34, 34, 0.05);
    box-shadow: inset 0 0 15px rgba(178, 34, 34, 0.1);
}

.dropzone-icon {
    font-size: 45px;
    color: var(--accent-red);
    margin-bottom: 15px;
    display: inline-block;
    /* item 1: no translateY hover on icon */
}

.dropzone-container h3 {
    font-family: var(--font-title);
    font-size: 20px;
    color: #fff;
    margin-bottom: 8px;
}

.dropzone-container p {
    font-size: 13px;
    color: #a09090;
}

.upload-selector-buttons {
    margin-top: 20px;
    display: flex;
    justify-content: center;
    gap: 15px;
}

/* Upload Progress Queue */
.upload-queue-container {
    display: none;
    margin-top: 20px;
}

.upload-queue-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.upload-queue-header h4 {
    font-family: var(--font-title);
    font-size: 16px;
    color: #fff;
}

.progress-bar-overall-bg {
    background: #201010;
    border-radius: 6px;
    overflow: hidden;
    height: 10px;
    margin-bottom: 15px;
}

.progress-bar-overall-fill {
    background: linear-gradient(90deg, var(--accent-red), #e44);
    height: 100%;
    width: 0%;
    transition: width 0.3s ease;
}

.upload-queue-list {
    max-height: 250px;
    overflow-y: auto;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    padding: 10px;
}

.upload-queue-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
    font-size: 13px;
}

.upload-queue-item:last-child {
    border-bottom: none;
}

.queue-filename {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    padding-right: 20px;
}

.queue-status {
    font-weight: 500;
}

.queue-status.uploading  { color: #3498db; }
.queue-status.converting { color: #f1c40f; }
.queue-status.success    { color: #2ecc71; }
.queue-status.error      { color: #e74c3c; }

/* Pending Review Holding Grid */
.pending-count-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.pending-count-badge {
    background: var(--accent-red);
    color: #fff;
    padding: 2px 10px;
    border-radius: 20px;
    font-family: var(--font-title);
    font-size: 14px;
    font-weight: bold;
}

/* Batch Controls Panel */
.batch-editor-panel {
    background: rgba(178, 34, 34, 0.05);
    border: 1px solid rgba(178, 34, 34, 0.2);
    border-radius: 8px;
    padding: 18px;
    margin-bottom: 25px;
    transition: all 0.3s ease;
    overflow: visible;
}

.batch-editor-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    user-select: none;
}

.batch-editor-header h4 {
    font-family: var(--font-title);
    font-size: 17px;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 10px;
}

.batch-editor-header .toggle-icon {
    font-size: 14px;
    transition: transform 0.3s;
}

.batch-editor-body {
    margin-top: 15px;
    display: none;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    animation: slideDown 0.3s ease-out forwards;
    overflow: visible;
}

@keyframes slideDown {
    from { opacity: 0; transform: translateY(-10px); }
    to   { opacity: 1; transform: translateY(0); }
}

.batch-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.batch-field label {
    font-size: 12px;
    color: #a09090;
    font-weight: 600;
}

.batch-field input,
.batch-field select {
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(178, 34, 34, 0.3);
    color: #fff;
    padding: 8px 12px;
    border-radius: 4px;
    font-size: 13px;
    outline: none;
}

.batch-field input:focus,
.batch-field select:focus {
    border-color: var(--accent-red);
}

.batch-field .checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    margin-top: 12px;
}

.batch-field .checkbox-label input {
    cursor: pointer;
    accent-color: var(--accent-red);
}

.batch-apply-btn {
    grid-column: 1 / -1;
    margin-top: 10px;
    padding: 10px;
    background: var(--accent-red);
    color: #fff;
    border: none;
    border-radius: 4px;
    font-family: var(--font-title);
    font-size: 14px;
    cursor: pointer;
    transition: background 0.2s;
    text-align: center;
}

.batch-apply-btn:hover {
    background: #c33;
}

/* Review Grid Cards */
.review-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 20px;
    overflow: visible;
}

.review-card {
    background: var(--dark-card-bg);
    border: var(--glass-border);
    border-radius: 8px;
    overflow: visible;
    display: flex;
    flex-direction: column;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
    transition: border-color 0.2s;
    /* item 1: no translateY on card hover */
    position: relative;
}

.review-card:hover {
    /* item 1: only border colour change, no translateY */
    border-color: rgba(178, 34, 34, 0.5);
}

.review-card.selected {
    border: 2px solid var(--accent-red);
    box-shadow: 0 0 15px rgba(178, 34, 34, 0.3);
}

.review-card.modified {
    border-left: 5px solid #ffc107;
    background-color: rgba(255, 193, 7, 0.1);
}

.review-card.selected.modified {
    border: 2px solid var(--accent-red);
    border-left: 5px solid #ffc107;
    background-color: rgba(255, 193, 7, 0.1);
    box-shadow: 0 0 15px rgba(178, 34, 34, 0.3);
}

.card-checkbox {
    position: absolute;
    top: 12px;
    left: 12px;
    z-index: 10;
    width: 20px;
    height: 20px;
    cursor: pointer;
    accent-color: var(--accent-red);
}

.card-preview-container {
    width: 100%;
    height: 180px;
    background: #000;
    position: relative;
    overflow: hidden;
    cursor: pointer;
    border-radius: 8px 8px 0 0;
}

.card-preview-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

.card-preview-container:hover .card-preview-img {
    transform: scale(1.05);
}

.card-orientation-badge {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(0, 0, 0, 0.7);
    color: #888;
    font-size: 10px;
    padding: 2px 6px;
    border-radius: 4px;
    text-transform: capitalize;
}

/* Card body layout — used both as form wrapper (edit.php) and content area (create.php) */
.card-body {
    padding: 15px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    flex: 1;
    overflow: visible;
}

/* When .card-body is also .edit-item (create.php), restore glassmorphism background
   and remove the theme border so the outer .review-card border takes over */
.review-card .card-body.edit-item {
    background-color: transparent;
    border: none;
    box-shadow: none;
    border-radius: 0;
    padding: 15px;
}

.card-original-title {
    font-size: 11px;
    color: #706060;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    margin-bottom: -5px;
}

.card-field {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.card-field label {
    font-size: 11px;
    font-weight: bold;
}

/* create.php glassmorphism context — dark hardcoded values */
.review-card .card-field label {
    color: #807070;
}

.card-field input,
.card-field select {
    width: 100%;
    padding: 7px 10px;
    border-radius: 4px;
    font-size: 13px;
    outline: none;
    transition: border-color 0.2s;
    box-sizing: border-box;
}

/* create.php glassmorphism context — dark hardcoded values */
.review-card .card-field input,
.review-card .card-field select {
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: #fff;
}

.card-field input:focus,
.card-field select:focus {
    border-color: var(--main-colour);
}

.review-card .card-field input:focus,
.review-card .card-field select:focus {
    border-color: var(--accent-red);
}

/* Autocomplete wrappers – item 5: z-index 200 so dropdowns escape card clipping */
.autocomplete-wrapper {
    position: relative;
}

/* Caret indicator: makes it clear the field has dropdown suggestions */
.autocomplete-wrapper::after {
    content: '▾';
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    color: #706060;
    pointer-events: none;
    font-size: 14px;
    line-height: 1;
}

/* Room for the caret glyph */
.autocomplete-wrapper input {
    padding-right: 28px;
}

.autocomplete-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #1a0f0f;
    border: 1px solid var(--accent-red);
    border-top: none;
    border-radius: 0 0 6px 6px;
    max-height: 150px;
    overflow-y: auto;
    z-index: 200;
    display: none;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.6);
}

.autocomplete-item {
    padding: 8px 12px;
    cursor: pointer;
    font-size: 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
    text-align: left;
}

.autocomplete-item:hover,
.autocomplete-item.selected {
    background: var(--accent-red);
    color: #fff;
}

/* Empty Review State */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #706060;
}

.empty-state-icon {
    font-size: 50px;
    margin-bottom: 15px;
    display: block;
}

.empty-state h3 {
    font-family: var(--font-title);
    font-size: 22px;
    color: #a09090;
    margin-bottom: 5px;
}

.empty-state p {
    font-size: 14px;
}

/* Grid Selection Header */
.selection-actions-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.selection-toggle-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 13px;
    color: #a09090;
}

.selection-toggle-label input {
    cursor: pointer;
    accent-color: var(--accent-red);
}

/* Modal Overlay */
.modal-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(5px);
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal-overlay.visible {
    display: flex;
}

.modal-content-img {
    max-width: 90%;
    max-height: 90vh;
    border-radius: 8px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.9);
    border: var(--glass-border);
}

/* Toast Notifications */
.toast {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 12px 24px;
    background: var(--dark-card-bg);
    border-left: 4px solid var(--accent-red);
    border-radius: 4px;
    color: #fff;
    font-size: 14px;
    font-weight: 500;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
    z-index: 100000;
    opacity: 0;
    transform: translateX(30px);
    transition: all 0.3s ease;
    pointer-events: none;
}

.toast.visible {
    opacity: 1;
    transform: translateX(0);
}

.toast.success {
    border-left-color: #2ecc71;
}

.toast.error {
    border-left-color: #e74c3c;
}

/* Upload Preview Pre-Queue Grid */
.upload-preview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    gap: 15px;
    margin-top: 25px;
    margin-bottom: 25px;
}

.upload-preview-item {
    position: relative;
    background: rgba(10, 5, 5, 0.6);
    border: 1px solid rgba(178, 34, 34, 0.2);
    border-radius: 8px;
    padding: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
    transition: border-color 0.2s;
    /* item 1: no translateY on hover */
    animation: previewFadeIn 0.3s ease-out;
}

@keyframes previewFadeIn {
    from { opacity: 0; transform: scale(0.9); }
    to   { opacity: 1; transform: scale(1); }
}

.upload-preview-item:hover {
    /* item 1: only border colour, no translateY */
    border-color: var(--accent-red);
}

.upload-preview-item img {
    width: 100%;
    height: 100px;
    object-fit: cover;
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    background: #000;
}

.upload-preview-item .remove-btn {
    position: absolute;
    top: -6px;
    right: -6px;
    background: var(--accent-red);
    color: white;
    border: none;
    border-radius: 50%;
    width: 22px;
    height: 22px;
    cursor: pointer;
    font-size: 13px;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.5);
    transition: background 0.2s, transform 0.2s;
    z-index: 10;
}

.upload-preview-item .remove-btn:hover {
    background: #f00;
    transform: scale(1.1);
}

.upload-preview-item .filename {
    width: 100%;
    font-size: 11px;
    color: #a09090;
    text-align: center;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    margin-top: 8px;
}

.upload-action-container {
    display: none;
    text-align: center;
    margin-top: 25px;
    margin-bottom: 10px;
    animation: actionFadeIn 0.3s ease-out;
}

@keyframes actionFadeIn {
    from { opacity: 0; transform: translateY(5px); }
    to   { opacity: 1; transform: translateY(0); }
}

.btn-upload-start {
    padding: 12px 35px;
    font-size: 16px;
    font-weight: bold;
    background: var(--accent-red);
    border: none;
    border-radius: 6px;
    color: #fff;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(178, 34, 34, 0.4);
    transition: background 0.3s, box-shadow 0.3s;
    /* item 1: no translateY transforms */
    font-family: var(--font-title);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-upload-start:hover {
    background: var(--accent-red-hover);
    box-shadow: 0 6px 20px rgba(178, 34, 34, 0.6);
    /* item 1: translateY(-1px) removed */
}

/* create.php responsive breakpoints */
@media (max-width: 768px) {
    .dashboard-header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }

    .header-actions {
        flex-wrap: wrap;
        justify-content: center;
        width: 100%;
    }

    .header-actions .btn-panel {
        flex: 1;
        justify-content: center;
    }

    .review-grid {
        grid-template-columns: 1fr;
    }
}

/*===================================================================*/
/*  OVERRIDES — formerly upload/css/style.css (the trimmed fork)      */
/*  Upload pages now link the canonical /css/style.css. These rules   */
/*  reproduce the few places the old fork intentionally diverged from */
/*  it, so the rendered result is unchanged. Loaded after style.css,  */
/*  so equal-specificity rules here win.                              */
/*===================================================================*/

/* Links: fork treated visited the same as unvisited, removed the default
   underline and added a transition (canonical style.css does not). */
a:link,
a:visited {
    color: var(--link-colour);
}

a {
    text-decoration: none;
    transition: var(--transition-fast);
}

a:hover {
    color: var(--link-colour_hover);
}

a:active {
    color: var(--link-colour_active);
}

a:focus {
    color: var(--link-colour_focus);
}

/* Header / Title / Logo — fork clamped the logo to 400px and animated the
   theme filter, instead of the canonical clamp(200px, 30vw, 800px). */
.title {
    text-align: center;
    padding: var(--padding-lg) 0;
    width: 100%;
}

.title > img {
    display: block;
    margin: 0 auto;
    max-width: 400px !important;
    height: auto;
    filter: var(--logo-colour);
    transition: filter var(--transition-normal);
}

/* Theme selector — only ever existed in the upload fork. */
.theme-selector {
    z-index: 9999 !important;
    position: fixed !important;
}

/*===================================================================*/
/*  MODERATION PANEL — moved out of moderate.php's inline <style>.    */
/*  Page-wide body styling is scoped to .mod-panel so it cannot leak  */
/*  onto the other upload pages that share this stylesheet.           */
/*===================================================================*/
body.mod-panel {
    font-family: 'Amaranth', sans-serif;
    color: var(--font-colour_white);
    background-color: #000;
    padding: 20px;
}

.moderation-item {
    background: var(--desc-bg);
    border: 2px solid var(--main-colour);
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 20px;
}

.moderation-item img {
    width: 100%;
    height: auto;
    border-radius: 4px;
    border: 1px solid var(--main-colour);
}

.moderation-details {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.flag-list {
    background: rgba(255, 0, 0, 0.1);
    border: 1px solid rgba(255, 0, 0, 0.3);
    padding: 10px;
    border-radius: 4px;
}

.flag-item {
    display: flex;
    justify-content: space-between;
    padding: 5px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.flag-item:last-child {
    border-bottom: none;
}

.action-buttons {
    display: flex;
    gap: 10px;
    margin-top: auto;
}

.action-buttons button {
    flex: 1;
    padding: 12px 24px;
    font-size: 16px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
}

.approve-btn {
    background: #28a745;
    color: white;
}

.approve-btn:hover {
    background: #218838;
}

.reject-btn {
    background: #dc3545;
    color: white;
}

.reject-btn:hover {
    background: #c82333;
}

.no-pending {
    text-align: center;
    padding: 60px 20px;
    font-size: 18px;
    color: var(--font-colour_white);
}

.info-row {
    display: flex;
    justify-content: space-between;
    padding: 5px 0;
}

.info-label {
    font-weight: bold;
    opacity: 0.8;
}

.logout-btn {
    padding: 8px 16px;
    background: var(--main-colour);
    border: none;
    border-radius: 4px;
    color: white;
    cursor: pointer;
}

.success-message {
    background: rgba(40, 167, 69, 0.2);
    border: 1px solid rgba(40, 167, 69, 0.5);
    padding: 15px;
    border-radius: 4px;
    margin-bottom: 20px;
    text-align: center;
}

#moderationList {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

@media (max-width: 1200px) {
    #moderationList {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .moderation-item {
        grid-template-columns: 1fr;
    }
}
