/* by John Upload — Design System */

:root {
    --bg: #0a0a0a;
    --bg-elevated: #111;
    --bg-hover: #1a1a1a;
    --border: #222;
    --border-light: #333;
    --text: #f5f5f5;
    --text-muted: #888;
    --text-dim: #555;
    --gold: #C9A962;
    --gold-light: #DEC68A;
    --gold-dark: #A68B4B;
    --gold-glow: rgba(201, 169, 98, 0.12);
    --gold-border: rgba(201, 169, 98, 0.45);
    --accent: var(--gold);
    --accent-fg: #0a0a0a;
    --success: #4ade80;
    --error: #f87171;
    --warning: var(--gold);
    --sidebar-width: 260px;
    --radius: 2px;
    --transition: 0.2s ease;
    --font: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', sans-serif;
    --font-serif: Georgia, 'Times New Roman', 'Palatino Linotype', serif;
}

*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font);
    background-color: var(--bg);
    background-image:
        radial-gradient(ellipse 70% 55% at 15% 20%, rgba(201, 169, 98, 0.07) 0%, transparent 55%),
        radial-gradient(ellipse 50% 45% at 85% 75%, rgba(201, 169, 98, 0.05) 0%, transparent 50%),
        radial-gradient(ellipse 40% 30% at 50% 100%, rgba(201, 169, 98, 0.04) 0%, transparent 45%);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
    min-height: 100dvh;
}

a {
    color: inherit;
    text-decoration: none;
}

button, input, textarea, select {
    font: inherit;
    color: inherit;
}

/* Brand */
.brand-label {
    font-size: 0.75rem;
    letter-spacing: 0.12em;
    text-transform: none;
    color: var(--text);
    margin-bottom: 0.5rem;
}

.brand-accent {
    color: var(--gold);
    font-family: var(--font-serif);
    font-style: italic;
    letter-spacing: 0.02em;
}

.brand-dot {
    color: var(--gold);
}

/* Auth pages */
.auth-page {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
}

.auth-container {
    width: 100%;
    max-width: 420px;
}

.auth-card {
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-top: 2px solid var(--gold-border);
    padding: 3rem 2.5rem;
    position: relative;
}

.auth-card h1 {
    font-family: var(--font-serif);
    font-size: 2rem;
    font-weight: 400;
    letter-spacing: -0.02em;
    margin-bottom: 0.25rem;
}

.auth-card h1 .highlight {
    color: var(--gold);
}

.auth-subtitle {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-bottom: 2rem;
}

.auth-footer {
    text-align: center;
    color: var(--text-dim);
    font-size: 0.8rem;
    margin-top: 2rem;
}

.auth-footer a {
    color: var(--gold);
    text-decoration: none;
}

.auth-footer a:hover {
    color: var(--gold-light);
    text-decoration: underline;
}

.auth-link {
    text-align: center;
    margin-top: 1.25rem;
    font-size: 0.85rem;
}

.auth-link a {
    color: var(--text-muted);
    text-decoration: none;
}

.auth-link a:hover {
    color: var(--gold);
    text-decoration: underline;
}

/* Forms */
.form {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.form-group label {
    font-size: 0.8rem;
    color: var(--text-muted);
    letter-spacing: 0.03em;
}

.form-group input,
.form-group textarea,
.form-group select {
    background: var(--bg);
    border: 1px solid var(--border);
    padding: 0.75rem 1rem;
    font-size: 0.95rem;
    transition: border-color var(--transition);
    border-radius: var(--radius);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--gold-border);
    box-shadow: 0 0 0 1px var(--gold-glow);
}

.form-group input:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.form-hint {
    font-size: 0.75rem;
    color: var(--text-dim);
}

textarea {
    resize: vertical;
    min-height: 60px;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    font-size: 0.85rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    border: none;
    cursor: pointer;
    transition: all var(--transition);
    border-radius: var(--radius);
    position: relative;
    white-space: nowrap;
}

.btn-primary {
    background: transparent;
    color: var(--gold);
    border: 1px solid var(--gold);
}

.btn-primary:hover:not(:disabled) {
    background: var(--gold);
    color: var(--accent-fg);
}

.btn-primary:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.btn-ghost {
    background: transparent;
    color: var(--text-muted);
    border: 1px solid var(--border);
}

.btn-ghost:hover {
    border-color: var(--gold-border);
    color: var(--gold-light);
}

.btn-danger {
    background: transparent;
    color: var(--error);
    border: 1px solid var(--error);
    padding: 0.4rem 0.75rem;
    font-size: 0.75rem;
}

.btn-danger:hover {
    background: var(--error);
    color: var(--bg);
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.75rem;
}

.btn-full {
    width: 100%;
}

.btn-loader {
    width: 16px;
    height: 16px;
    border: 2px solid transparent;
    border-top-color: currentColor;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

.btn.loading .btn-text { opacity: 0; }
.btn.loading .btn-loader { display: block; position: absolute; }
.btn-loader.hidden { display: none; }

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

/* Toast notifications (no alert()) */
.toast-container {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    pointer-events: none;
}

.toast {
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    padding: 0.875rem 1.25rem;
    font-size: 0.875rem;
    max-width: 360px;
    pointer-events: auto;
    transform: translateY(20px);
    opacity: 0;
    transition: all 0.3s ease;
    border-radius: var(--radius);
}

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

.toast-success { border-left: 3px solid var(--success); }
.toast-error { border-left: 3px solid var(--error); }
.toast-info { border-left: 3px solid var(--gold); }

/* Dashboard layout */
.dashboard-page {
    display: flex;
    min-height: 100vh;
    min-height: 100dvh;
}

.sidebar {
    width: var(--sidebar-width);
    background: var(--bg-elevated);
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    z-index: 100;
    transform: translateX(0);
    transition: transform var(--transition);
}

.sidebar-header {
    padding: 2rem 1.5rem 1.5rem;
    border-bottom: 1px solid var(--border);
}

.sidebar-title {
    font-family: var(--font-serif);
    font-size: 1.25rem;
    font-weight: 400;
    letter-spacing: -0.02em;
}

.sidebar-title .highlight {
    color: var(--gold);
}

.sidebar-nav {
    flex: 1;
    padding: 1rem 0;
    display: flex;
    flex-direction: column;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1.5rem;
    color: var(--text-muted);
    font-size: 0.875rem;
    transition: all var(--transition);
    border: none;
    background: none;
    cursor: pointer;
    width: 100%;
    text-align: left;
}

.nav-link:hover {
    color: var(--gold-light);
    background: var(--bg-hover);
}

.nav-link.active {
    color: var(--gold);
    background: var(--gold-glow);
    border-right: 2px solid var(--gold);
}

.nav-link.active svg {
    color: var(--gold);
}

.sidebar-footer {
    padding: 1rem 0;
    border-top: 1px solid var(--border);
}

.main-content {
    flex: 1;
    margin-left: var(--sidebar-width);
    min-height: 100vh;
    min-height: 100dvh;
}

.topbar {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.5rem 2rem;
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    background: var(--bg);
    z-index: 50;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--text);
    cursor: pointer;
    padding: 0.25rem;
}

.page-title {
    font-family: var(--font-serif);
    font-size: 1.25rem;
    font-weight: 400;
    letter-spacing: -0.02em;
}

.content-area {
    padding: 2rem;
}

/* Stats */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1rem;
    margin-bottom: 2.5rem;
}

.stat-card {
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    transition: border-color var(--transition);
}

.stat-card:hover {
    border-color: var(--gold-border);
}

.stat-value {
    font-family: var(--font-serif);
    font-size: 2rem;
    font-weight: 300;
    letter-spacing: -0.03em;
    color: var(--gold);
}

.stat-label {
    font-size: 0.8rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* Sections */
.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.25rem;
}

.section-header h2 {
    font-family: var(--font-serif);
    font-size: 1rem;
    font-weight: 400;
    letter-spacing: -0.01em;
    color: var(--gold-light);
}

.actions-row {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 2.5rem;
    flex-wrap: wrap;
}

/* Tables */
.table-wrapper {
    overflow-x: auto;
    border: 1px solid var(--border);
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}

.data-table th {
    text-align: left;
    padding: 0.75rem 1rem;
    color: var(--text-muted);
    font-weight: 400;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-bottom: 1px solid var(--border);
    background: var(--bg-elevated);
    white-space: nowrap;
}

.data-table td {
    padding: 0.875rem 1rem;
    border-bottom: 1px solid var(--border);
    vertical-align: middle;
}

.data-table tr:last-child td {
    border-bottom: none;
}

.data-table tr:hover td {
    background: var(--bg-hover);
}

.empty-state {
    text-align: center;
    color: var(--text-dim);
    padding: 2rem !important;
}

.file-name {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.file-icon {
    flex-shrink: 0;
    opacity: 0.5;
}

.badge {
    display: inline-block;
    padding: 0.2rem 0.6rem;
    font-size: 0.7rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    border-radius: var(--radius);
}

.badge-active {
    background: rgba(74, 222, 128, 0.1);
    color: var(--success);
}

.badge-inactive {
    background: rgba(248, 113, 113, 0.1);
    color: var(--error);
}

.table-actions {
    display: flex;
    gap: 0.5rem;
}

/* Dossiers clients — médias admin */
.media-folders {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.client-folder {
    border: 1px solid var(--border);
    background: var(--bg-elevated);
}

.folder-header {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.25rem;
    background: none;
    border: none;
    cursor: pointer;
    text-align: left;
    color: var(--text);
    transition: background var(--transition);
}

.folder-header:hover {
    background: var(--bg-hover);
}

.client-folder.open .folder-header {
    border-left: 2px solid var(--gold);
}

.folder-icon {
    color: var(--gold);
    flex-shrink: 0;
    display: flex;
}

.folder-name {
    font-family: var(--font-serif);
    font-size: 0.95rem;
    letter-spacing: -0.01em;
}

.folder-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
}

.folder-meta {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.folder-email {
    font-size: 0.75rem;
    color: var(--text-dim);
}

.folder-chevron {
    color: var(--text-muted);
    flex-shrink: 0;
    display: flex;
    transition: transform var(--transition);
}

.client-folder.open .folder-chevron {
    transform: rotate(180deg);
}

.folder-content {
    display: none;
    border-top: 1px solid var(--border);
}

.client-folder.open .folder-content {
    display: block;
}

.folder-table {
    border: none;
}

.folder-table th:first-child,
.folder-table td:first-child {
    padding-left: 1.25rem;
}

.folder-table th:last-child,
.folder-table td:last-child {
    padding-right: 1.25rem;
}

.btn-downloaded {
    background: rgba(74, 222, 128, 0.12);
    color: var(--success);
    border: 1px solid rgba(74, 222, 128, 0.35);
}

.upload-help {
    margin-top: 1rem;
    font-size: 0.85rem;
    color: var(--text-muted);
    text-align: center;
}

.upload-help strong {
    color: var(--gold);
    font-weight: 400;
}

.draft-section {
    margin-bottom: 3rem;
}

.finalize-box {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
}

.draft-header-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.finalize-sticky {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 150;
    background: rgba(10, 10, 10, 0.92);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-top: 1px solid var(--gold-border);
    padding: 0.875rem 1rem calc(0.875rem + env(safe-area-inset-bottom, 0px));
    box-shadow: 0 -8px 32px rgba(0, 0, 0, 0.45);
}

.finalize-sticky-inner {
    max-width: 800px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.finalize-sticky-info {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    min-width: 0;
}

.finalize-sticky-count {
    font-size: 0.9rem;
    color: var(--gold-light);
    font-family: var(--font-serif);
}

.finalize-sticky-hint {
    font-size: 0.75rem;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.finalize-sticky .btn-primary {
    flex-shrink: 0;
    min-width: 148px;
}

body.has-finalize-bar .client-main {
    padding-bottom: calc(5.5rem + env(safe-area-inset-bottom, 0px));
}

body.has-finalize-bar .toast-container {
    bottom: calc(5.5rem + env(safe-area-inset-bottom, 0px));
}

@media (max-width: 480px) {
    .finalize-sticky-inner {
        gap: 0.75rem;
    }

    .finalize-sticky-hint {
        display: none;
    }

    .finalize-sticky .btn-primary {
        min-width: auto;
        padding-left: 1rem;
        padding-right: 1rem;
    }

    #finalize-btn-top {
        display: none;
    }
}

@media (min-width: 769px) {
    .finalize-sticky {
        left: 50%;
        transform: translateX(-50%);
        max-width: 800px;
        border-left: 1px solid var(--gold-border);
        border-right: 1px solid var(--gold-border);
        border-radius: var(--radius) var(--radius) 0 0;
    }
}

.session-card {
    border: 1px solid var(--border);
    border-left: 2px solid var(--gold-border);
    background: var(--bg-elevated);
    margin-bottom: 1rem;
}

.session-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--border);
    flex-wrap: wrap;
}

.session-date {
    display: block;
    font-size: 0.9rem;
    color: var(--gold-light);
}

.session-meta {
    display: block;
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 0.15rem;
}

.session-note {
    font-size: 0.85rem;
    color: var(--text-dim);
    font-style: italic;
    margin-top: 0.5rem;
}

.batch-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.folder-toolbar {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1.25rem;
    border-bottom: 1px solid var(--border);
    flex-wrap: wrap;
}

.select-all-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.8rem;
    color: var(--text-muted);
    cursor: pointer;
}

.col-check {
    width: 36px;
    padding-left: 1.25rem !important;
}

.file-checkbox-label {
    display: flex;
    align-items: center;
    cursor: pointer;
}

.file-checkbox {
    width: 16px;
    height: 16px;
    accent-color: var(--accent);
    cursor: pointer;
}

.row-ref {
    font-size: 0.72rem;
    color: var(--gold);
    letter-spacing: 0.04em;
    margin-top: 0.2rem;
}

.session-block {
    border-top: 1px solid var(--border);
}

.session-block-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.875rem 1.25rem;
    background: rgba(201, 169, 98, 0.04);
    flex-wrap: wrap;
}

.session-ref {
    display: block;
    font-size: 0.8rem;
    color: var(--gold);
    letter-spacing: 0.06em;
    text-transform: uppercase;
    margin-bottom: 0.15rem;
}

.col-thumb {
    width: 72px;
}

.media-thumb {
    width: 64px;
    height: 48px;
    padding: 0;
    border: 1px solid var(--border);
    background: var(--bg);
    overflow: hidden;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    flex-shrink: 0;
}

.media-thumb img,
.media-thumb video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    pointer-events: none;
}

.media-thumb.fallback {
    flex-direction: column;
    gap: 0.15rem;
    color: var(--gold);
}

.media-thumb-icon {
    font-size: 1.1rem;
    line-height: 1;
}

.media-thumb-label,
.media-thumb-badge {
    font-size: 0.6rem;
    letter-spacing: 0.08em;
    color: var(--gold);
}

.media-thumb-badge {
    position: absolute;
    bottom: 3px;
    right: 4px;
    background: rgba(10, 10, 10, 0.75);
    padding: 0.1rem 0.25rem;
}

.media-thumb:hover {
    border-color: var(--gold-border);
    box-shadow: 0 0 0 1px var(--gold-glow);
}

.preview-modal {
    position: fixed;
    inset: 0;
    z-index: 400;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.25s ease;
}

.preview-modal.open {
    opacity: 1;
    visibility: visible;
}

.preview-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.88);
}

.preview-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    z-index: 2;
    background: none;
    border: 1px solid var(--gold-border);
    color: var(--gold);
    width: 40px;
    height: 40px;
    font-size: 1.5rem;
    cursor: pointer;
}

.preview-content {
    position: relative;
    z-index: 1;
    max-width: min(92vw, 960px);
    max-height: 85vh;
    text-align: center;
}

.preview-content img,
.preview-content video {
    max-width: 100%;
    max-height: 75vh;
    display: block;
    margin: 0 auto;
}

.preview-name {
    margin-top: 1rem;
    color: var(--text-muted);
    font-size: 0.875rem;
}

.preview-fallback {
    padding: 3rem;
    font-size: 3rem;
}

.upload-item .media-thumb {
    width: 72px;
    height: 54px;
}

/* Modal */
.modal {
    position: fixed;
    inset: 0;
    z-index: 200;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.modal.open {
    opacity: 1;
    visibility: visible;
}

.modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
}

.modal-content {
    position: relative;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    width: 90%;
    max-width: 480px;
    padding: 2rem;
    transform: translateY(20px);
    transition: transform 0.3s ease;
}

.modal.open .modal-content {
    transform: translateY(0);
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.5rem;
}

.modal-header h2 {
    font-size: 1.125rem;
    font-weight: 400;
}

.modal-close {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 1.5rem;
    cursor: pointer;
    line-height: 1;
    padding: 0.25rem;
}

.modal-close:hover {
    color: var(--text);
}

.modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    margin-top: 0.5rem;
}

.modal-warning {
    color: var(--text-muted);
    line-height: 1.5;
    margin: 0 0 1rem;
}

.modal-warning strong {
    color: var(--text);
}

/* Client page */
.client-page {
    display: block;
}

.client-header {
    border-bottom: 1px solid var(--border);
    padding: 1.5rem 2rem;
}

.client-header-inner {
    max-width: 800px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.client-header h1 {
    font-family: var(--font-serif);
    font-size: 1.5rem;
    font-weight: 400;
    letter-spacing: -0.02em;
    color: var(--gold-light);
}

.client-main {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem;
}

.upload-section {
    margin-bottom: 3rem;
}

.upload-zone {
    border: 2px dashed var(--border);
    padding: 3rem 2rem;
    text-align: center;
    transition: all var(--transition);
    cursor: pointer;
    border-radius: var(--radius);
}

.upload-zone:hover,
.upload-zone.dragover {
    border-color: var(--gold);
    background: var(--gold-glow);
}

.upload-zone-content svg {
    color: var(--gold);
    margin-bottom: 1rem;
}

.upload-zone-title {
    font-size: 1.1rem;
    margin-bottom: 0.25rem;
}

.upload-zone-hint {
    color: var(--text-muted);
    font-size: 0.85rem;
    margin-bottom: 1.25rem;
}

.uploads-section h2,
.draft-section h2 {
    font-family: var(--font-serif);
    font-size: 1rem;
    font-weight: 400;
    margin-bottom: 1rem;
    color: var(--gold-light);
}

.uploads-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.upload-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.25rem;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    gap: 1rem;
}

.upload-item-info {
    flex: 1;
    min-width: 0;
}

.upload-item-actions {
    display: flex;
    gap: 0.5rem;
    flex-shrink: 0;
}

.upload-item-name {
    font-size: 0.9rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.upload-item-meta {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 0.15rem;
}

.upload-item-message {
    font-size: 0.8rem;
    color: var(--text-dim);
    margin-top: 0.35rem;
    font-style: italic;
}

/* Upload progress */
.upload-progress {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 300;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.upload-progress.visible {
    opacity: 1;
    visibility: visible;
}

.upload-progress-inner {
    width: 90%;
    max-width: 400px;
    text-align: center;
}

.progress-bar {
    height: 3px;
    background: var(--border);
    margin-bottom: 1rem;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--gold-dark), var(--gold));
    width: 0%;
    transition: width 0.3s ease;
}

#progress-text {
    color: var(--text-muted);
    font-size: 0.875rem;
}

.hidden { display: none !important; }

/* Responsive */
@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
    }

    .sidebar.open {
        transform: translateX(0);
    }

    .main-content {
        margin-left: 0;
    }

    .menu-toggle {
        display: block;
    }

    .content-area,
    .client-main {
        padding: 1.25rem;
    }

    .auth-card {
        padding: 2rem 1.5rem;
    }

    .toast-container {
        left: 1rem;
        right: 1rem;
        bottom: 1rem;
    }

    .toast {
        max-width: none;
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }
}
