/* style3.css - Compilation correcte : style.css puis style2.css */

/* ===== BASE : style.css ===== */
:root {
    --primary-color: #4a6cf7;
    --secondary-color: #6c757d;
    --success-color: #28a745;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
    --info-color: #17a2b8;
    --dark-color: #343a40;
    --light-color: #f8f9fa;
    --sidebar-width: 250px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Plus Jakarta Sans', 'Plus Jakarta Sans Fallback', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.container {
    display: flex;
    min-height: 100vh;
}

/* Sidebar */
.sidebar {
    width: var(--sidebar-width);
    background: #040c14;
    color: white;
    padding: 20px 0;
    position: fixed;
    height: 100vh;
    overflow-y: auto;
}

.sidebar-header {
    padding: 0 20px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar-header h2 {
    color: white;
    font-size: 1.5rem;
}

.menu {
    list-style: none;
    padding: 20px 0;
}

.menu-item {
    padding: 10px 20px;
    border-left: 3px solid transparent;
    transition: all 0.3s;
}

.menu-item:hover {
    background: rgba(255, 255, 255, 0.1);
    border-left-color: #53b0e5;
}

.menu-item a {
    color: white;
    text-decoration: none;
    display: block;
}

.menu-item.active {
    background: rgba(255, 255, 255, 0.1);
    border-left-color: var(--primary-color);
}

/* Main content */
.main-content {
    flex: 1;
    margin-left: var(--sidebar-width);
    padding: 20px;
}

.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 1px solid #e0e0e0;
}

.header h1 {
	font-style: italic;
            font-size: 4vw;
            font-family: 'Orbitron', 'Rajdhani', sans-serif;
            font-weight: 700;
            text-transform: uppercase;
    color: var(--dark-color);
    font-size: 1.8rem;
}

.card {
    background: white;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    padding: 20px;
    margin-bottom: 20px;
}

.card-header {
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

.card-title {
    font-size: 1.2rem;
    color: var(--dark-color);
}

/* Form styles */
.form-group {
    margin-bottom: 15px;
}

.form-label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
}

.form-control {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1rem;
}

.form-control:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 0 3px rgba(74, 108, 247, 0.1);
}

textarea.form-control {
    min-height: 100px;
    resize: vertical;
}

.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
    transition: background 0.3s;
    text-decoration: none;
    display: inline-block;
    text-align: center;
}

.btn-primary {
    background: linear-gradient(90deg, #007BFF, #FF1493);
    color: white;
}

.btn-primary:hover {
    background: linear-gradient(90deg, #007BFF, #FF1493);
}

.btn-danger {
    background: var(--danger-color);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: all 0.2s;
}

.btn-danger:hover {
    background: #bd2130;
    transform: scale(1.1);
}

.btn-success {
    background: var(--success-color);
    color: white;
}

.btn-success:hover {
    background: #218838;
}

.btn-warning {
    background: var(--warning-color);
    color: var(--dark-color);
}

.btn-warning:hover {
    background: #e0a800;
}

/* Alert */
.alert {
    padding: 12px 15px;
    border-radius: 4px;
    margin-bottom: 20px;
}

.alert-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.alert-error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.server-info {
    background: #d1ecf1;
    color: #0c5460;
    border: 1px solid #bee5eb;
    padding: 10px 15px;
    border-radius: 4px;
    margin-bottom: 20px;
}

/* Drag handle styles */
.drag-handle {
    cursor: move;
    padding: 5px;
    margin-right: 5px;
    color: #6c757d;
}

.preview-media-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    margin: 8px 0;
    border: 1px solid #ddd;
    border-radius: 8px;
    background: white;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    flex-wrap: wrap;
    transition: transform 0.2s, box-shadow 0.2s;
}

/* Style pour les calques masqués (non utilisés) */
.preview-media-item.hidden-layer {
    background-color: #bcbcbc;
    opacity: 0.7;
}

.preview-media-item.dragging {
    background-color: #f0f4ff;
    transform: scale(1.02);
    box-shadow: 0 4px 8px rgba(74, 108, 247, 0.3);
}

/* Drag and drop styles */
.preview-media-item.dragover {
    border: 2px dashed var(--primary-color);
    background-color: #f0f4ff;
}

.preview-media-item.placeholder {
    height: 60px;
    background-color: #f8f9fa;
    border: 2px dashed #4a6cf7;
    justify-content: center;
    align-items: center;
    color: #6c757d;
}

.preview-media-item.placeholder::before {
    content: "Déplacer ici";
    font-size: 0.9rem;
}

/* Media info styles */
.media-info {
    display: flex;
    align-items: center;
    flex: 1;
    min-width: 120px;
    padding: 5px;
}

.media-type-icon {
    margin-right: 10px;
    font-size: 1.2rem;
}

.media-status {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    margin-right: 10px;
}

.media-status.visible {
    background-color: #28a745;
}

.media-status.hidden {
    background-color: #dc3545;
}

/* Media grid styles */
.media-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.media-item {
    border: 1px solid #e9ecef;
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
    background: white;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    position: relative;
}

.media-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.media-thumb {
    height: 180px;
    overflow: hidden;
    background: #f8f9fa;
    display: flex;
    align-items: center;
    justify-content: center;
    border-bottom: 1px solid #e9ecef;
}

.media-thumb img, .media-thumb video {
    max-width: 100%;
    max-height: 100%;
    object-fit: cover;
}

.media-info-detailed {
    padding: 15px;
}

.media-title {
    font-size: 16px;
    margin: 0 0 12px 0;
    font-weight: 600;
    color: #333;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.media-detail {
    display: flex;
    flex-direction: column;
}

.media-detail {
    display: flex;
    justify-content: between;
    margin-bottom: 5px;
    font-size: 0.9rem;
}

.detail-label {
    font-size: 11px;
    color: #777;
    font-weight: 500;
    margin-bottom: 2px;
}

/* Indicateur de statut plus petit */
.detail-value:contains('🟢'), 
.detail-value:contains('🔴') {
    font-size: 12px;
}

.detail-value {
    font-size: 13px;
    color: #333;
    font-weight: 400;
}

.file-size {
    color: var(--info-color);
    font-weight: 500;
}

.file-extension {
    background: var(--info-color);
    color: white;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 600;
}

.media-actions {
    position: absolute;
    top: 10px;
    right: 10px;
}

/* Stats container */
.stats-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-bottom: 20px;
}

.stat-card {
    background: white;
    padding: 15px;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    text-align: center;
}

.stat-number {
	margin-top: 12px;
    font-size: 2rem;
    font-weight: bold;
    color: #53b0e5;
    margin-bottom: 12px;
}

.stat-label {
    color: var(--secondary-color);
    font-size: 0.9rem;
}

.total-size {
    color: #53b0e5;
}

/* Copy field styles */
.copy-field {
    display: flex;
    align-items: center;
    gap: 10px;
}

.form-control.readonly {
    background-color: #f8f9fa;
    color: #6c757d;
    cursor: text;
    flex: 1;
    user-select: all;
}

.btn-copy {
    padding: 10px 12px;
    background: linear-gradient(90deg, #53b0e5, #0a68cd);
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.3s;
    white-space: nowrap;
}

.btn-copy:hover {
    background: linear-gradient(90deg, #afdff7, #53b0e5);
	color: black;
}

.btn-copy.copied {
    background: var(--success-color);
}

/* Responsive */
@media (max-width: 992px) {
    .sidebar {
        width: 70px;
        overflow: visible;
    }
    
    .sidebar-header h2, .menu-item span {
        display: none;
    }
    
    .main-content {
        margin-left: 70px;
    }
    
    .copy-field {
        flex-direction: column;
        align-items: stretch;
    }
}

@media (max-width: 768px) {
    .media-grid {
        grid-template-columns: 1fr;
    }
    
    .stats-container {
        grid-template-columns: 1fr;
    }
}

/* ===== OVERLAY : style2.css (écrase les styles précédents) ===== */
:root {
    --sidebar-width: 250px;
    --primary-color: #4a6cf7;
    --danger-color: #dc3545;
    --success-color: #28a745;
    --dark-color: #343a40;
    --g1: #53b0e5;
    --g2: #1b3653;
    --g3: #53b0e5;
}

body {
    color: #a1a7bb;
    line-height: 0.8;
    background: url("../medias/background_01.jpg") center / cover no-repeat fixed;
    min-height: 100vh;
}


/* Contrôle de volume */
.volume-control {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 15px;
    background: #f8f9fa;
}

.volume-label {
    font-size: 13px;
    color: #666;
    font-weight: 500;
    min-width: 50px;
}

.volume-slider {
    flex: 1;
    height: 5px;
    -webkit-appearance: none;
    appearance: none;
    background: #ddd;
    border-radius: 5px;
    outline: none;
}

.volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 15px;
    height: 15px;
    border-radius: 50%;
    background: #4a90e2;
    cursor: pointer;
    transition: all 0.2s;
}

.volume-slider::-webkit-slider-thumb:hover {
    background: #357abd;
    transform: scale(1.2);
}

.volume-slider::-moz-range-thumb {
    width: 15px;
    height: 15px;
    border-radius: 50%;
    background: #4a90e2;
    cursor: pointer;
    border: none;
    transition: all 0.2s;
}

.volume-slider::-moz-range-thumb:hover {
    background: #357abd;
    transform: scale(1.2);
}

.volume-value {
    font-size: 13px;
    color: #333;
    font-weight: 600;
    min-width: 35px;
    text-align: center;
}

.menu-item:hover {
    color: white;
}

.menu-item.active {
    background: linear-gradient(90deg, #0b1f34, #36587c);
    border-left-color: #53b0e5;
}

.header {
    border-bottom: 1px solid #757575;
}

/* Fallback (couleur unie) */
.header h1 {
    font-size: 1.8rem;
    color: #0a68cd;
}

/* Gradient de texte si supporté */
@supports ((-webkit-background-clip: text) or (background-clip: text)) {
    .header h1 {
        background: linear-gradient(-90deg, #0a68cd, #53b0e5);
        -webkit-background-clip: text;
        background-clip: text;
        color: transparent;
        -webkit-text-fill-color: transparent;
    }
}

.card {
    background: transparent;
    border-radius: 0px;
}

.card-title {
    color: #a1a7bb;
}

.btn-primary {
    background: linear-gradient(90deg, #53b0e5, #0a68cd);
	font-weight: 600;
    color: white;
}

.btn-primary:hover {
    background: linear-gradient(90deg, #afdff7, #53b0e5);
	font-weight: 600;
    color: black;
}

.server-info {
    background:
        linear-gradient(90deg, #1b3653 0%, #0d0e20 100%) padding-box,
        linear-gradient(90deg, var(--g1), var(--g2)) border-box;
    border: 1px solid transparent;
    border-radius: 4px;
    color: #74a6ea;
    padding: 10px 15px;
    margin-bottom: 20px;
}

/* Utilitaire pour texte en dégradé */
.text-gradient {
    background: linear-gradient(90deg, var(--g1), var(--g2));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.drag-handle {
    color: #6fafe6;
}

.drag-handle:hover {
    color: white;
}

.card-blur {
    background: rgba(19, 34, 53, 0.5);
    border: 1px solid rgba(32, 77, 118, 0.6);
    border-radius: 2px;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    background-clip: padding-box;
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 300px;
    flex: 2;
}

.preview-media-item {
    display: flex;
    align-items: center;
    padding: 8px;
    margin: 6px 0;
    margin-bottom: 8px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid transparent;
    border-radius: 1px;
    transition: all 0.3s ease;
    background: 
        linear-gradient(1deg,#09121bE0, #1b365380) padding-box,
        linear-gradient(90deg, var(--g3), var(--g2)) border-box;
    box-shadow: 0 2px 4px rgba(0,0,0,0.95);
    flex-wrap: wrap;
    transition: transform 0.2s, box-shadow 0.2s;
}

.preview-media-item:hover {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid transparent;
    border-radius: 1px;
    transition: all 0.3s ease;
    background: 
        linear-gradient(-2deg,#09121b80, #1b365360) padding-box,
        linear-gradient(90deg, var(--g3), var(--g2)) border-box;
    box-shadow: 0 2px 4px rgba(0,0,0,0.95);
    flex-wrap: wrap;
    transition: transform 0.2s, box-shadow 0.2s;
}

.preview-media-item.dragging {
    opacity: 0.5;
    transform: rotate(5deg);
}

.media-info {
    display: flex;
    align-items: center;
    flex: 1;
    min-width: 120px;
}

.media-status {
    display: inline-block;
    width: 3px;
    height: 35px;
    border-radius: 2px;
    margin-right: 8px;
    vertical-align: middle;
}

.media-status.visible {
    background-color: #a4ffc8;
    box-shadow: 0 0 6px 2px rgba(24, 178, 24, 0.9);
}

.media-status.hidden {
    background-color: #b10019;
    box-shadow: 0 0 6px 2px rgba(187, 50, 50, 0.2);
}

.layer-position-badge {
    color: #a1a7bb;
    font-size: 12px;
}

		
.card-blur {
  background: rgba(19, 34, 53, 0.5);
  border: 1px solid rgba(32, 77, 118, 0.6);
  border-radius: 2px;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  background-clip: padding-box; /* optionnel */
  padding: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 300px;
  flex: 2;
}
		
			.preview-media-item {
         display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 8px;
	margin: 6px 0;
	/* Bordure en dégradé */
	border: 1px solid transparent;
	border-radius: 1px;
	background:
    /* couche fond (semi-transparente) */
    linear-gradient(1deg,#09121bE0, #1b365380) padding-box,
    /* couche bordure (dégradé) */
    linear-gradient(90deg, var(--g3), var(--g2)) border-box;
	box-shadow: -2px 2px 5px rgba(0,0,0,0.95);
	flex-wrap: wrap;
	transition: transform 0.2s, box-shadow 0.2s;
}
        
        .preview-media-item.dragging {
            background-color: #f0f4ff;
            transform: scale(1.02);
            box-shadow: 0 4px 8px rgba(74, 108, 247, 0.3);
        }
		
		
        /* Drag and drop styles */		
        .preview-media-item.dragover {
            border: 2px dashed var(--primary-color);
            background-color: #f0f4ff;
        }

        .preview-media-item.placeholder {
            height: 60px;
            background-color: #f8f9fa;
            border: 2px dashed #4a6cf7;
            justify-content: center;
            align-items: center;
            color: #6c757d;
        }
        
        .preview-media-item.placeholder::before {
            content: "Déplacer ici";
            font-size: 0.9rem;
        }
        
        /* Media info styles */
        .media-info {
            display: flex;
            align-items: center;
            flex: 1;
            min-width: 120px;
        }
        
        .media-type-icon {
			color: white;
            margin-right: 10px;
            font-size: 1.2rem;
        }
        
        .fa-eye {
		color: white;
}

	/* Icône œil barré = gris clair */
	.fa-eye-slash {
		color: #ff0000;
}
        
        .media-status.visible {
            background-color: #a4ffc8;
			box-shadow:
    0 0 6px 2px rgba(24, 178, 24, 0.9); /* glow orange */
        }
        
        .media-status.hidden {
            background-color: #b10019;
			box-shadow:
    0 0 6px 2px rgba(187, 50, 50, 0.2); /* glow orange */
        }
        
		.layer-position-badge {
    color: #a1a7bb;
    font-size: 12px;
}

    /* Styles spécifiques pour cette page */
    .media-title-section {
        background-color: #d1d1d1;
        padding: 7px 7px;
        border-bottom: 1px solid #b8b8b8;
        margin: 0;
    }
    
    .media-title-section h3 {
        color: #000;
        margin: 0;
        font-size: 14px;
        font-weight: 600;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }
    
    .media-thumb {
        position: relative;
        height: 180px;
        overflow: hidden;
        background: linear-gradient(135deg, #8bc34a, #4caf50); /* Dégradé vert clair à vert foncé */
    }
    
    .media-actions-top {
        position: absolute;
        top: 10px;
        right: 10px;
        z-index: 10;
    }
	
	    .media-info {
        padding: 10px;
    }
    
    /* Badge de résolution en bas à gauche */
    .resolution-badge {
        position: absolute;
        bottom: 10px;
        left: 10px;
        background: rgba(0, 0, 0, 0.5);
        color: white;
        padding: 6px 8px;
        border-radius: 4px;
        font-size: 11px;
        font-weight: 500;
        z-index: 5;
    }
    
    /* Badge d'extension en haut à gauche */
    .extension-badge {
        position: absolute;
        top: 10px;
        left: 10px;
        background: rgba(0, 0, 0, 0.5);
        color: white;
        padding: 7px 8px;
        border-radius: 4px;
        font-size: 11px;
        font-weight: 600;
        z-index: 5;
    }
    
    .file-size {
        color: black;
        font-weight: 600;
    }
	
	    .upload-content {
        pointer-events: none;
    }

    .upload-icon {
        font-size: 4rem;
        color: #b3c9eb;
        margin-bottom: 20px;
        transition: all 0.3s ease;
    }

    .upload-area:hover .upload-icon {
        color: #37bff7;
        transform: scale(1.1);
    }

    .upload-text {
        font-size: 1.2rem;
        color: #53b0e5;
        margin-bottom: 15px;
        line-height: 1.5;
    }

    .upload-text strong {
        color: #53b0e5;
    }

    .upload-formats {
        font-size: 0.9rem;
        color: #667389;
        line-height: 1.4;
    }
    /* Modal styles */
    .modal-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.6);
        z-index: 1000;
        display: flex;
        align-items: center;
        justify-content: center;
        backdrop-filter: blur(3px);
    }

    .modal-content {
        background: white;
        border-radius: 12px;
        box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
        width: 90%;
        max-width: 500px;
        overflow: hidden;
        animation: modalAppear 0.3s ease-out;
    }
    .modal-header {
        background: linear-gradient(135deg, #4a90e2 0%, #357abd 100%);
        color: white;
        padding: 20px;
        display: flex;
        justify-content: space-between;
        align-items: center;
    }

    .modal-header h3 {
        margin: 0;
        font-weight: 600;
    }

    .modal-close {
        font-size: 1.5rem;
        cursor: pointer;
        opacity: 0.8;
        transition: opacity 0.2s;
    }

    .modal-close:hover {
        opacity: 1;
    }

    .modal-body {
        padding: 25px;
    }

    .modal-body p {
        margin-bottom: 15px;
        color: #495057;
    }

    .modal-footer {
        padding: 20px 25px;
        background: #606871;
        display: flex;
        justify-content: flex-end;
        gap: 10px;
    }

.edit-icon {
    color: #6c757d;
    margin-left: 8px;
    font-size: 14px;
    transition: color 0.2s;
}

.edit-icon:hover {
    color: #007bff;
}