Files
router-lists-ui/frontend/src/index.css
T

363 lines
7.6 KiB
CSS

/* Using Bootstrap styles, this file can be empty or used for custom global styles. */
/* Sticky footer helpers */
.page { min-height: 100vh; display: flex; flex-direction: column; }
.footer { margin-top: auto; }
/* Table selected row styling */
.table-selected {
background-color: rgba(32, 107, 196, 0.08) !important;
}
.table-selected:hover {
background-color: rgba(32, 107, 196, 0.12) !important;
}
/* ===== Tabler visual consistency (global overrides) ===== */
:root {
--app-gap-xs: .25rem;
--app-gap-sm: .5rem;
--app-gap-md: .75rem;
--app-gap-lg: 1rem;
/* Semantic colors for statuses */
--status-online: #2fb344;
--status-offline: #d63939;
--status-warning: #f59f00;
--status-unknown: #868e96;
/* Accent colors for important actions */
--accent-primary: #206bc4;
--accent-danger: #d63939;
--accent-success: #2fb344;
--accent-info: #4299e1;
--accent-warning: #f59f00;
/* Enhanced spacing scale */
--space-xs: 0.25rem;
--space-sm: 0.5rem;
--space-md: 1rem;
--space-lg: 1.5rem;
--space-xl: 2rem;
--space-xxl: 3rem;
/* Shadow scale */
--shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
--shadow-md: 0 2px 8px rgba(0, 0, 0, 0.1);
--shadow-lg: 0 4px 16px rgba(0, 0, 0, 0.15);
--shadow-xl: 0 8px 32px rgba(0, 0, 0, 0.2);
}
/* ===== Improved Typography ===== */
.page-title {
font-size: 1.75rem;
font-weight: 700;
letter-spacing: -0.025em;
line-height: 1.2;
}
.card-title {
font-size: 1.125rem;
font-weight: 600;
line-height: 1.4;
}
.table td {
line-height: 1.6;
}
/* ===== Improved Spacing ===== */
.page-header {
margin-bottom: var(--space-xl);
}
.card + .card {
margin-top: var(--space-lg);
}
.table td, .table th {
padding: 0.75rem 1rem;
}
/* Header actions under page header */
.page-header .header-actions {
display: flex;
flex-wrap: wrap;
gap: var(--app-gap-sm);
}
.page-header .header-actions .btn-group { margin-right: var(--app-gap-sm); }
.page-header .vr { margin: 0 var(--app-gap-sm); }
/* Buttons: icon spacing left */
.btn .icon { margin-right: .375rem; }
.btn.btn-icon .icon { margin-right: 0; }
/* Tables: remove hover background for rows (as per project preference) */
.table tbody tr:hover { background-color: transparent; }
/* Центровка контента ячеек и компактный вид */
.table.card-table th, .table.card-table td { vertical-align: middle; }
/* Compact card spacing */
.card.card-md { margin-bottom: var(--app-gap-lg); }
/* Utilities used in components */
.cursor-pointer { cursor: pointer; }
.border-dashed { border: 2px dashed rgba(0,0,0,.08); }
.transition { transition: all .2s ease; }
.rotate-180 { transform: rotate(180deg); }
/* Input icon alignment tweaks */
.input-icon .input-icon-addon { display: flex; align-items: center; }
/* Modal close button click area */
.modal .btn-close { position: absolute; right: .75rem; top: .75rem; }
/* Фильтры: удобная ширина селектов */
.form-select.w-auto { min-width: 180px; }
/* Икон-кнопки одинакового размера */
.btn.btn-icon.btn-sm { width: 2rem; height: 2rem; display: inline-flex; align-items: center; justify-content: center; }
/* Отступы между бейджами и в empty-action */
.badge + .badge { margin-left: .25rem; }
.empty .empty-action .btn + .btn { margin-left: .5rem; }
/* ===== Enhanced Interactive Elements ===== */
/* Better hover states */
.btn:not(:disabled):hover {
transform: translateY(-1px);
box-shadow: var(--shadow-md);
transition: all 0.2s ease;
}
.btn:not(:disabled):active {
transform: translateY(0);
transition: all 0.1s ease;
}
/* Card hover effects */
.card.card-hover {
transition: all 0.2s ease;
cursor: pointer;
}
.card.card-hover:hover {
transform: translateY(-2px);
box-shadow: var(--shadow-lg);
}
/* Better focus states for accessibility */
*:focus-visible {
outline: 3px solid var(--accent-primary);
outline-offset: 3px;
border-radius: 3px;
}
button:focus-visible,
.btn:focus-visible {
box-shadow: 0 0 0 3px rgba(32, 107, 196, 0.3);
}
/* Badge animations */
.badge {
transition: all 0.2s ease;
}
.badge:hover {
transform: scale(1.05);
}
/* Minimum touch target size for mobile */
@media (max-width: 768px) {
.btn, .page-link, .dropdown-item {
min-height: 44px;
min-width: 44px;
display: inline-flex;
align-items: center;
justify-content: center;
}
.btn-icon {
width: 44px;
height: 44px;
}
}
/* Enhanced table row interactions */
.table tbody tr {
transition: background-color 0.15s ease;
}
.table tbody tr:hover {
background-color: rgba(32, 107, 196, 0.04);
}
.table tbody tr:focus-within {
background-color: rgba(32, 107, 196, 0.08);
box-shadow: inset 3px 0 0 var(--accent-primary);
}
/* Loading state improvements */
.btn.loading {
position: relative;
pointer-events: none;
}
.btn.loading::before {
content: '';
position: absolute;
top: 50%;
left: 50%;
width: 100%;
height: 100%;
border-radius: inherit;
background: rgba(255, 255, 255, 0.2);
transform: translate(-50%, -50%);
animation: pulse-button 1.5s infinite;
}
@keyframes pulse-button {
0%, 100% {
opacity: 0;
transform: translate(-50%, -50%) scale(1);
}
50% {
opacity: 1;
transform: translate(-50%, -50%) scale(1.05);
}
}
/* ===== Animations ===== */
@keyframes fadeIn {
from {
opacity: 0;
transform: translateY(10px);
}
to {
opacity: 1;
transform: translateY(0);
}
}
.animate-in {
animation: fadeIn 0.4s ease both;
}
/* ===== Statistics Cards ===== */
.card-sm .avatar {
width: 3rem;
height: 3rem;
display: flex;
align-items: center;
justify-content: center;
border-radius: var(--tblr-border-radius);
}
.card-sm .h2 {
font-size: 1.5rem;
font-weight: 600;
line-height: 1.2;
}
/* ===== Form Improvements ===== */
.form-label.required::after {
content: ' *';
color: var(--tblr-danger);
}
.input-icon {
position: relative;
}
.input-icon .input-icon-addon {
position: absolute;
left: 0.5rem;
top: 50%;
transform: translateY(-50%);
z-index: 1;
color: var(--tblr-muted);
}
.input-icon .form-control,
.input-icon .form-select {
padding-left: 2.5rem;
}
.input-icon .form-control:focus ~ .input-icon-addon,
.input-icon .form-select:focus ~ .input-icon-addon {
color: var(--tblr-primary);
}
/* Кнопка очистки поиска */
.input-icon .btn-icon {
position: absolute;
right: 0.25rem;
top: 50%;
transform: translateY(-50%);
z-index: 2;
}
/* ===== Table Improvements ===== */
.table thead th {
font-weight: 600;
text-transform: uppercase;
font-size: 0.75rem;
letter-spacing: 0.05em;
color: var(--tblr-muted);
border-bottom: 2px solid var(--tblr-border-color);
}
.table tbody tr {
border-bottom: 1px solid var(--tblr-border-color);
}
.table tbody tr:last-child {
border-bottom: none;
}
.table tbody tr.table-active {
background-color: rgba(32, 107, 196, 0.1);
}
.user-select-none {
user-select: none;
-webkit-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
}
/* ===== Pagination Improvements ===== */
.pagination .page-link {
min-width: 2.5rem;
text-align: center;
transition: all 0.2s ease;
}
.pagination .page-item.active .page-link {
font-weight: 600;
}
/* ===== Card Header Improvements ===== */
.card-header.bg-primary-lt {
background-color: rgba(32, 107, 196, 0.1);
border-bottom: 1px solid rgba(32, 107, 196, 0.2);
}
/* ===== Responsive Improvements ===== */
@media (max-width: 768px) {
.card-sm .avatar {
width: 2.5rem;
height: 2.5rem;
}
.card-sm .h2 {
font-size: 1.25rem;
}
.table-responsive {
font-size: 0.875rem;
}
.btn-group {
flex-wrap: wrap;
}
}