Files
maria_uslugi/includes/admin_style.css
T
2026-03-05 10:25:39 +01:00

401 lines
7.8 KiB
CSS
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
/* ==========================================================================
admin_style.css — Mobile global (≤ 956px)
Charge APRÈS Bootstrap
========================================================================== */
/* --- Dropdown admin (utilisé aussi hors mobile) --- */
:root {
--header: #f1f1f1;
}
.menu-wrap {
position: relative;
display: inline-block;
}
.dropdown-menu-custom {
position: absolute;
top: calc(100% + 8px);
right: 0;
background: #fff;
border: 1px solid #dee2e6;
border-radius: 8px;
list-style: none;
padding: 0;
margin: 0;
width: 230px;
box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
display: none;
z-index: 1100;
}
.dropdown-menu-custom li {
padding: 12px 18px;
border-bottom: 1px solid #f1f1f1;
cursor: pointer;
font-size: 15px;
}
.dropdown-menu-custom li:last-child {
border-bottom: none;
}
.dropdown-menu-custom li:hover {
background: #f8f9fa;
}
/* ======================== Mobile-first (≤ 956px) ======================== */
@media (max-width: 956px) {
/* Garde-fous */
html,
body {
width: 100%;
max-width: 100%;
overflow-x: hidden;
-webkit-text-size-adjust: 100%;
}
*,
*::before,
*::after {
box-sizing: border-box;
}
img,
video,
iframe {
max-width: 100%;
height: auto;
display: block;
}
body {
padding-left: env(safe-area-inset-left);
padding-right: env(safe-area-inset-right);
-webkit-tap-highlight-color: transparent;
}
/* Grille & conteneurs */
.row {
margin-left: 0 !important;
margin-right: 0 !important;
}
.container {
width: 100% !important;
max-width: 100% !important;
padding-left: 16px !important;
padding-right: 16px !important;
}
/* Layout principal */
main,
.main,
.main1,
.main2 {
display: block !important;
align-items: initial !important;
justify-content: initial !important;
background: transparent !important;
margin: 0 !important;
padding: 0 !important;
width: 100% !important;
max-width: none !important;
}
.btn-lg,
.btn-sm {
min-height: 38px !important;
padding: 0.35rem 0.7rem !important;
font-size: 0.92rem !important;
border-radius: 10px !important;
}
.btn-outline-primary,
.btn-outline-secondary,
.btn-outline-danger,
.btn-outline-dark {
border-width: 1px !important;
box-shadow: none !important;
}
/* groupes d’actions dans les tableaux → même largeur */
.d-flex.gap-2 .btn,
.row .btn {
flex: 1 1 0;
text-align: center;
}
.text-end {
text-align: initial !important;
}
.text-end .btn {
width: 100%;
}
.btn-group {
flex-wrap: wrap;
}
.btn-group .btn {
margin-bottom: 6px;
}
/* Cartes */
.card,
.card * {
overflow-wrap: anywhere;
word-break: break-word;
}
.card,
.card.shadow-sm,
.card.shadow-sm.p-3 {
border-radius: 16px;
overflow: hidden;
}
/* Formulaires */
.form-control,
.form-select,
.form-check-input,
.input-group-text,
.input-group > .btn {
min-height: 44px;
}
/* Tables: scroll horizontal “propre” */
.table-responsive {
overflow-x: auto;
-webkit-overflow-scrolling: touch;
}
table.table {
font-size: 14px;
}
table.table th,
table.table td {
vertical-align: middle;
}
/* Listes → actions tap-friendly */
td.text-end .d-flex {
gap: 8px;
flex-wrap: wrap;
}
td.text-end .d-flex .btn {
flex: 1 1 calc(50% - 4px);
min-width: 140px;
}
/* Split list/detail */
.row.g-3 > [class*="col-"] .card {
margin-bottom: 0;
}
/* Autocomplete / suggestions */
.suggest,
#suggestions {
position: static !important;
max-height: none !important;
overflow: visible !important;
width: 100% !important;
}
/* Footer */
.site-footer {
font-size: 12px;
padding-bottom: 16px;
}
/* Menu hamburger */
.header-actions .btn {
min-width: 44px;
}
}
/* ====== Composants “pages admin” (tous écrans, pensés mobile) ====== */
.table th {
white-space: nowrap;
}
.table .minw-120 {
min-width: 120px;
}
.photo {
width: 40px;
height: 40px;
object-fit: cover;
border-radius: 8px;
}
.badge {
display: inline-block;
padding: 0.35rem 0.6rem;
border-radius: 9999px;
font-size: 0.85rem;
border: 1px solid transparent;
}
.badge-active {
background: #e8f6ee;
border-color: #27ae60;
color: #2e07a3ff;
}
.badge-expiring {
background: #fff8e6;
border-color: #f39c12;
color: #2e07a3ff;
}
.badge-expired {
background: #fdecea;
border-color: #c0392b;
color: #2e07a3ff;
}
.card pre {
font-size: 0.85rem;
line-height: 1.45;
}
.list-group-item > .badge {
margin-left: auto;
}
:focus-visible {
outline: 2px solid #6366f1;
outline-offset: 2px;
border-radius: 8px;
}
/* ====== Table -> cartes (opt-in via .mobile-cards) ====== */
@media (max-width: 768px) {
table.mobile-cards {
border-collapse: separate;
border-spacing: 0;
}
table.mobile-cards thead {
display: none;
}
table.mobile-cards tbody {
display: block;
}
table.mobile-cards tr {
display: block;
margin: 12px 0;
background: #fff;
border: 1px solid rgba(0, 0, 0, 0.06);
border-radius: 14px;
box-shadow: 0 6px 14px rgba(0, 0, 0, 0.08);
overflow: hidden;
}
table.mobile-cards tr::before {
content: "";
display: block;
height: 3px;
background: #38378b;
opacity: 0.9;
}
table.mobile-cards td {
display: block;
padding: 10px 14px !important;
border: none !important;
background: transparent !important;
}
table.mobile-cards td + td {
border-top: 1px dashed rgba(0, 0, 0, 0.08) !important;
}
table.mobile-cards td::before {
content: attr(data-label);
display: inline-block;
min-width: 120px;
margin-right: 8px;
font-weight: 600;
color: #666;
}
table.mobile-cards td::before:empty {
display: none;
}
}
@media (max-width: 956px) {
.d-flex.justify-content-end.gap-2 .btn {
flex: 1 1 0; /* même largeur */
min-width: 120px; /* évite les boutons trop petits */
text-align: center; /* centre le texte */
}
}
/* Header */
.site-header {
background: var(--header);
border-bottom: 1px solid rgba(168, 39, 39, 0.06);
}
.site-header .container {
margin: 0 auto;
padding: 10px 18px;
display: flex;
align-items: center;
justify-content: space-between;
}
.site-header .btn-circle {
border-radius: 8px;
box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08);
}
.site-header .avatar {
width: 32px;
height: 32px;
border-radius: 999px;
display: inline-grid;
place-items: center;
font-weight: 600;
background: #eef2ff;
color: #3730a3;
}
/* ==== LOGO: mobile vs desktop (béton) ==== */
.brand {
letter-spacing: 0.5px;
font-weight: 700;
display: flex;
align-items: center;
line-height: 0; /* évite petits décalages baseline */
}
.header-left {
display: flex;
align-items: center;
gap: 8px; /* distance logo ↔ langue */
}
.brand .logo-mobile,
.brand .logo-desktop {
display: none !important; /* on cache tout par défaut */
height: 40px; /* taille unique (tu ajustes) */
width: auto;
}
/* Mobile: logo_u */
@media (max-width: 767.98px) {
.brand .logo-mobile {
display: block !important;
}
}
/* Desktop: logo.png */
@media (min-width: 768px) {
.brand .logo-desktop {
display: block !important;
}
}
/* Langue choix*/
/* Sélecteur de langue dans le header */
.lang-switch {
display: flex;
gap: 6px;
height: 42px;
background: #fff;
padding: 6px;
border-radius: 20px;
box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
}
.lang-btn {
display: inline-block;
padding: 4px 10px;
font-size: 13px;
font-weight: 700;
text-decoration: none;
color: #38378b; /* bleu foncé */
border-radius: 14px;
transition: all 0.2s ease-in-out;
}
.lang-btn:hover {
background: rgba(56, 55, 139, 0.08);
}
.lang-btn.active {
background: #38378b; /* bleu foncé */
color: #fff;
}