/* ══════════════════════════════════════════════════════════════ admin.css — Backoffice Mon Cinéma (Version Améliorée) ═══════════════════════════════════════════════════════════════ */ /* Conteneur principal */ .admin-wrap { max-width: 1400px; padding-top: 2rem; } /* ══════════════════════════════════════════════════════════════ EN-TÊTE ADMIN ═══════════════════════════════════════════════════════════════ */ .admin-header { display: flex; justify-content: space-between; align-items: center; padding: 1.5rem 0; margin-bottom: 2rem; border-bottom: 1px solid var(--border); } .header-titles h1 { font-family: 'Playfair Display', Georgia, serif; font-size: 2rem; font-weight: 700; margin-bottom: 0.3rem; color: var(--text); } .header-titles h1 span { color: var(--gold); } .header-titles p { color: var(--muted); font-size: 0.9rem; margin: 0; } .header-actions { display: flex; gap: 0.6rem; align-items: center; } /* ══════════════════════════════════════════════════════════════ BOUTONS D'ACTION ═══════════════════════════════════════════════════════════════ */ .btn-action { background: var(--surface-card); color: var(--text); border: 1px solid var(--border); padding: 0.6rem 1rem; border-radius: 8px; font-family: inherit; font-size: 0.85rem; font-weight: 500; cursor: pointer; display: inline-flex; align-items: center; gap: 0.5rem; transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1); text-decoration: none; } .btn-action:hover { border-color: var(--gold); background: var(--gold-dim); color: var(--gold); transform: translateY(-1px); } .btn-action.primary { background: var(--gold); color: var(--background); border-color: var(--gold); font-weight: 600; } .btn-action.primary:hover { background: var(--gold); box-shadow: 0 4px 15px var(--gold-glow); transform: translateY(-2px); } .btn-action.danger-solid { background: #ff4757; color: #fff; border-color: #ff4757; } .btn-action.danger-solid:hover { background: #ff6b81; box-shadow: 0 4px 15px rgba(255, 71, 87, 0.3); } .btn-small { padding: 0.4rem 0.8rem; font-size: 0.8rem; } /* ══════════════════════════════════════════════════════════════ ONGLETS ═══════════════════════════════════════════════════════════════ */ .pub-tabs-container { display: flex; justify-content: center; margin-bottom: 2rem; } .pub-tabs { background-color: var(--surface); border: 1px solid var(--border); padding: 0.4rem; border-radius: 30px; display: inline-flex; gap: 0.4rem; } .tab-btn { background: none; border: none; color: #d4d4de; font-family: 'DM Sans', sans-serif; font-size: 0.9rem; font-weight: 500; cursor: pointer; padding: 0.65rem 1.6rem; border-radius: 25px; display: flex; align-items: center; gap: 0.6rem; transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1); } .tab-btn i { font-size: 1.15rem; } .tab-btn:hover { color: var(--text); background-color: var(--surface-hover); } .tab-btn.active { color: var(--background); background-color: var(--gold); font-weight: 600; box-shadow: 0 4px 15px var(--gold-glow); } /* ═════════════════════════════════════════════════════════════ BARRE D'OUTILS & FILTRES ═══════════════════════════════════════════════════════════════ */ .admin-toolbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.5rem; flex-wrap: wrap; gap: 1rem; } .admin-filters { margin-bottom: 1.5rem; } .search-box { position: relative; max-width: 400px; } .search-box input { width: 100%; padding: 0.75rem 1rem 0.75rem 2.8rem; background: var(--surface); border: 1px solid var(--border); border-radius: 8px; color: var(--text); font-family: inherit; font-size: 0.9rem; transition: all 0.2s; } .search-box input:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px var(--gold-dim); } .search-box i { position: absolute; left: 1rem; top: 50%; transform: translateY(-50%); color: var(--muted); font-size: 1.1rem; pointer-events: none; } /* Barre bulk actions */ .bulk-actions-bar { background: var(--gold-dim); border: 1px solid var(--gold); border-radius: 8px; padding: 0.8rem 1.5rem; display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.5rem; color: var(--gold); animation: slideDown 0.3s ease; } @keyframes slideDown { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: translateY(0); } } /* ══════════════════════════════════════════════════════════════ TABLEAU ═══════════════════════════════════════════════════════════════ */ .table-container { background: var(--surface-card); border: 1px solid var(--border); border-radius: 12px; overflow-y: auto; /* Permet le défilement vertical */ max-height: 75vh; /* Évite que le tableau prenne toute la page */ box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3); } .admin-table thead th:nth-child(1), .admin-table tbody td:nth-child(1) { width: 50px; text-align: center; } .admin-table thead th:nth-child(2), .admin-table tbody td:nth-child(2) { width: 80px; text-align: center; } .admin-table thead th:nth-child(3), .admin-table tbody td:nth-child(3) { width: 30%; } .admin-table thead th:nth-child(4), .admin-table tbody td:nth-child(4) { width: 80px; } .admin-table thead th:nth-child(5), .admin-table tbody td:nth-child(5) { width: 20%; } .admin-table thead th:nth-child(6), .admin-table tbody td:nth-child(6) { width: 25%; } .admin-table thead th:nth-child(7), .admin-table tbody td:nth-child(7) { width: 120px; text-align: right; } /* ══════════════════════════════════════════════════════════════ ÉLÉMENTS DU TABLEAU ══════════════════════════════════════════════════════════════ */ .thumb { width: 50px; height: 70px; object-fit: cover; border-radius: 6px; border: 1px solid var(--border); box-shadow: 0 4px 10px rgba(0,0,0,0.5); display: block; margin: 0 auto; transition: transform 0.3s; } .thumb:hover { transform: scale(1.05); } .thumb-ph { width: 50px; height: 70px; background: var(--surface); border-radius: 6px; display: flex; align-items: center; justify-content: center; color: var(--muted); border: 1px solid var(--border); margin: 0 auto; } .badge-format { background: var(--surface); border: 1px solid var(--border); padding: 0.3rem 0.8rem; border-radius: 20px; font-size: 0.8rem; color: var(--gold); display: inline-block; font-weight: 500; } .tbl-stars { color: var(--gold); letter-spacing: 2px; font-size: 0.95rem; } .info-cell { display: flex; flex-direction: column; gap: 0.5rem; align-items: flex-start; } .rating-badge { background: var(--surface); border: 1px solid var(--border); color: var(--gold); font-size: 0.75rem; font-weight: 600; padding: 0.1rem 0.4rem; border-radius: 4px; display: inline-block; } .streaming-badge { font-size: 0.75rem; color: var(--gold); background: var(--gold-dim); padding: 0.25rem 0.7rem; border-radius: 20px; display: inline-block; width: fit-content; border: 1px solid rgba(212, 175, 55, 0.2); font-weight: 500; max-width: 200px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .physical-badge { font-size: 0.75rem; color: var(--muted); background: var(--surface); padding: 0.25rem 0.7rem; border-radius: 20px; display: inline-block; width: fit-content; border: 1px solid var(--border); } /* Actions */ .tbl-actions { display: flex; justify-content: flex-end; gap: 0.3rem; } .tbl-actions button { background: transparent; border: none; color: var(--muted); cursor: pointer; padding: 0.5rem; font-size: 1.2rem; transition: all 0.2s; border-radius: 6px; display: inline-flex; align-items: center; justify-content: center; } .tbl-actions button:hover { color: var(--gold); background: var(--surface); } .tbl-actions button.del:hover { color: #ff4757; } /* Checkbox personnalisées */ input[type="checkbox"] { appearance: none; width: 20px; height: 20px; border: 2px solid var(--muted); border-radius: 6px; background: var(--surface); cursor: pointer; position: relative; transition: all 0.2s; display: inline-block; vertical-align: middle; } input[type="checkbox"]:checked { background: var(--gold); border-color: var(--gold); } input[type="checkbox"]:checked::after { content: '✓'; color: var(--background); position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); font-size: 13px; font-weight: 900; } /* Demi-étoiles */ .half-star { position: relative; display: inline-block; color: #ffffff; opacity: 0.45; font-size: 0.95rem; } .half-star::before { content: '★'; position: absolute; left: 0; width: 50%; overflow: hidden; color: var(--gold); opacity: 1; } .stars-muted { color: #ffffff; opacity: 0.35; } /* ══════════════════════════════════════════════════════════════ PAGINATION ═══════════════════════════════════════════════════════════════ */ .pagination { display: flex; justify-content: center; align-items: center; gap: 0.4rem; margin-top: 2rem; padding: 1rem 0; flex-wrap: wrap; } .pagination button { background: var(--surface); border: 1px solid var(--border); color: var(--text-secondary); min-width: 38px; height: 38px; border-radius: 8px; display: flex; align-items: center; justify-content: center; cursor: pointer; transition: all 0.25s; font-weight: 500; font-size: 0.9rem; } .pagination button:hover:not(:disabled):not(.active) { border-color: var(--gold); color: var(--gold); background: var(--gold-dim); } .pagination button.active { background: var(--gold); color: var(--background); border-color: var(--gold); font-weight: 600; box-shadow: 0 4px 10px var(--gold-glow); } .pagination button:disabled { opacity: 0.3; cursor: not-allowed; } .pagination-info { color: var(--muted); font-size: 0.9rem; margin: 0 1rem; font-weight: 500; } /* ══════════════════════════════════════════════════════════════ BANDEAU DE SÉCURITÉ ═══════════════════════════════════════════════════════════════ */ .security-banner { background: rgba(255, 71, 87, 0.05); border: 1px solid rgba(255, 71, 87, 0.3); color: #ff4757; padding: 1.2rem 1.5rem; border-radius: 12px; margin-bottom: 2.5rem; display: flex; justify-content: space-between; align-items: center; } .security-banner i { font-size: 1.3rem; margin-right: 0.5rem; } .security-banner .sec-text { display: flex; align-items: center; } /* ══════════════════════════════════════════════════════════════ MODALES ═══════════════════════════════════════════════════════════════ */ .overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0, 0, 0, 0.85); backdrop-filter: blur(8px); display: flex; align-items: center; justify-content: center; opacity: 0; visibility: hidden; transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1); z-index: 1000; } .overlay.open { opacity: 1; visibility: visible; } .modal { background: var(--surface-card); border: 1px solid var(--border); border-radius: 16px; padding: 2.5rem; width: 90%; max-width: 600px; position: relative; transform: translateY(30px) scale(0.95); transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1); box-shadow: 0 30px 70px rgba(0, 0, 0, 0.9); max-height: 90vh; overflow-y: auto; } .overlay.open .modal { transform: translateY(0) scale(1); } .modal-close { position: absolute; top: 1.5rem; right: 1.5rem; background: var(--surface); border: 1px solid var(--border); color: var(--muted); width: 32px; height: 32px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 1.1rem; cursor: pointer; transition: all 0.2s; } .modal-close:hover { color: var(--text); border-color: var(--text); } .modal-h { margin-bottom: 2rem; color: var(--text); font-size: 1.4rem; display: flex; align-items: center; gap: 0.6rem; } .modal-h i { color: var(--gold); font-size: 1.6rem; } /* ═════════════════════════════════════════════════════════════ FORMULAIRES ═══════════════════════════════════════════════════════════════ */ .form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.2rem; } .form-group { margin-bottom: 1.2rem; text-align: left; } .form-group label { display: block; margin-bottom: 0.6rem; font-size: 0.9rem; color: var(--muted); font-weight: 500; } .form-group input, .form-group textarea, .form-group select { width: 100%; padding: 0.8rem 1rem; background: var(--background); border: 1px solid var(--border); color: var(--text); border-radius: 8px; font-family: inherit; font-size: 0.95rem; transition: all 0.2s; } .form-group input:focus, .form-group textarea:focus, .form-group select:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px var(--gold-dim); } .divider { margin: 2rem 0 1.5rem; padding-bottom: 0.5rem; border-bottom: 1px solid var(--border); color: var(--gold); font-size: 0.9rem; text-transform: uppercase; letter-spacing: 1px; font-weight: 600; } /* ══════════════════════════════════════════════════════════════ ZONE D'IMPORT CSV ══════════════════════════════════════════════════════════════ */ .import-box { border: 2px dashed var(--border); border-radius: 12px; padding: 3rem 2rem; text-align: center; background: var(--surface); transition: all 0.2s; cursor: pointer; position: relative; } .import-box:hover { border-color: var(--gold); background: var(--gold-dim); } .import-box input[type="file"] { position: absolute; top: 0; left: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; } .import-box i { font-size: 3rem; color: var(--gold); margin-bottom: 1rem; display: block; } /* ══════════════════════════════════════════════════════════════ BARRE DE PROGRESSION ═══════════════════════════════════════════════════════════════ */ #progress-overlay .modal { max-width: 500px; text-align: center; } #progress-bar { width: 0%; height: 12px; background: var(--gold); border-radius: 6px; transition: width 0.3s ease; } /* ══════════════════════════════════════════════════════════════ RESPONSIVE MOBILE ═══════════════════════════════════════════════════════════════ */ @media (max-width: 768px) { .admin-header { flex-direction: column; align-items: flex-start; gap: 1.5rem; } .header-actions { width: 100%; flex-wrap: wrap; } /* On rend le conteneur transparent pour laisser les "cartes" respirer */ .table-container { background: transparent; border: none; box-shadow: none; overflow-y: visible; max-height: none; } .admin-table, .admin-table tbody { display: block; width: 100%; } /* Masquer l'en-tête classique du tableau */ .admin-table thead { display: none; } /* --- TRANSFORMATION DES LIGNES EN CARTES (GRID) --- */ .admin-table tbody tr { display: grid; /* Définition des colonnes : Checkbox | Affiche | Contenu | Actions */ grid-template-columns: 30px 80px 1fr 40px; grid-template-areas: "check poster title actions" "check poster year actions" "check poster director actions" "check poster badges actions"; gap: 0.3rem 0.8rem; background: var(--surface-card); border: 1px solid var(--border); border-radius: 12px; margin-bottom: 1rem; padding: 1rem 0.8rem; box-shadow: 0 4px 12px rgba(0,0,0,0.15); align-items: center; } /* Nettoyage des styles de cellules bureau */ .admin-table td { display: block; padding: 0; border: none; text-align: left; } /* Nettoyage des anciens préfixes ("Année", "Réal.") */ .admin-table td:nth-child(4)::before, .admin-table td:nth-child(5)::before, .admin-table td:nth-child(6)::before { display: none; } /* 1. Checkbox */ .admin-table td:nth-child(1) { grid-area: check; display: flex; justify-content: center; margin-bottom: 0; } /* 2. Affiche */ .admin-table td:nth-child(2) { grid-area: poster; display: flex; justify-content: center; } .thumb, .thumb-ph { width: 80px; height: 115px; margin: 0; border-radius: 8px; } /* 3. Titre */ .admin-table td:nth-child(3) { grid-area: title; align-self: end; } .admin-table td:nth-child(3) strong { font-size: 1.1rem; line-height: 1.2; color: var(--gold); white-space: normal; /* Le titre peut passer à la ligne sur mobile */ } /* 4. Année */ .admin-table td:nth-child(4) { grid-area: year; font-size: 0.85rem; color: var(--muted); } .admin-table td:nth-child(4)::before { content: '🗓 '; opacity: 0.7; } /* 5. Réalisateur */ .admin-table td:nth-child(5) { grid-area: director; font-size: 0.85rem; color: var(--muted); } .admin-table td:nth-child(5)::before { content: '🎬 '; opacity: 0.7; } /* 6. Informations (Étoiles ou Format) */ .admin-table td:nth-child(6) { grid-area: badges; align-self: start; margin-top: 0.4rem; } /* 7. Actions (Modifier / Supprimer) */ .admin-table td:nth-child(7) { grid-area: actions; display: flex; flex-direction: column; gap: 0.8rem; justify-content: center; align-items: flex-end; padding-top: 0; } .tbl-actions { flex-direction: column; gap: 0.8rem; } /* Boutons d'action plus faciles à cliquer sur écran tactile */ .tbl-actions button { background: var(--surface); border: 1px solid var(--border); padding: 0.6rem; border-radius: 8px; font-size: 1.2rem; } .search-box { max-width: 100%; } }