Files
BetterDesk/web/static/style.css
T
UNITRONIX bf68beed6f 1.2.0-v8
2026-01-06 03:24:36 +01:00

702 lines
12 KiB
CSS

* {
margin: 0;
padding: 0;
box-sizing: border-box;
}
:root {
/* Grayscale Dark Theme */
--primary-color: #6b7280;
--secondary-color: #4b5563;
--success-color: #10b981;
--danger-color: #ef4444;
--warning-color: #f59e0b;
--info-color: #3b82f6;
--dark-bg: #0a0a0a;
--card-bg: rgba(30, 30, 30, 0.8);
--text-primary: #e5e7eb;
--text-secondary: #9ca3af;
--glass-bg: rgba(20, 20, 20, 0.8);
--glass-border: rgba(75, 85, 99, 0.3);
--hover-bg: rgba(55, 65, 81, 0.5);
}
body {
font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
background: var(--dark-bg);
color: var(--text-primary);
min-height: 100vh;
overflow-x: hidden;
}
.bg-gradient {
position: fixed;
top: 0;
left: 0;
width: 200%;
height: 200%;
background: linear-gradient(135deg,
rgba(107, 114, 128, 0.15) 0%,
rgba(75, 85, 99, 0.1) 25%,
rgba(55, 65, 81, 0.12) 50%,
rgba(107, 114, 128, 0.15) 75%,
rgba(75, 85, 99, 0.1) 100%);
opacity: 1;
z-index: -1;
animation: gradientShift 20s ease infinite;
transform-origin: center center;
}
@keyframes gradientShift {
0% {
transform: translate(-25%, -25%) scale(1.2) rotate(0deg);
}
33% {
transform: translate(-20%, -30%) scale(1.3) rotate(3deg);
}
66% {
transform: translate(-30%, -20%) scale(1.25) rotate(-3deg);
}
100% {
transform: translate(-25%, -25%) scale(1.2) rotate(0deg);
}
}
/* Glass Effect */
.glass-effect {
background: var(--glass-bg);
backdrop-filter: blur(10px);
-webkit-backdrop-filter: blur(10px);
border: 1px solid var(--glass-border);
box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.37);
}
/* Navigation */
.navbar {
padding: 0.5rem 0;
position: sticky;
top: 0;
z-index: 100;
margin-bottom: 1rem;
}
.nav-content {
max-width: 1600px;
margin: 0 auto;
padding: 0 1rem;
display: flex;
justify-content: space-between;
align-items: center;
}
.nav-brand {
display: flex;
align-items: center;
gap: 0.75rem;
font-size: 1.5rem;
font-weight: 700;
color: var(--text-primary);
}
.nav-brand i {
color: var(--primary-color);
}
.nav-stats {
display: flex;
gap: 1rem;
}
.stat-badge {
display: flex;
align-items: center;
gap: 0.5rem;
padding: 0.5rem 1rem;
background: var(--glass-bg);
border-radius: 20px;
border: 1px solid var(--glass-border);
}
.stat-badge.active {
background: rgba(67, 233, 123, 0.1);
border-color: var(--success-color);
}
.stat-badge i {
color: var(--primary-color);
}
.stat-badge.active i {
color: var(--success-color);
}
/* Container */
.container {
max-width: 1400px;
margin: 0 auto;
padding: 0 2rem 2rem;
}
/* Header Section */
.header-section {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 2rem;
}
.page-title {
font-size: 2.5rem;
font-weight: 700;
background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
background-clip: text;
}
.action-buttons {
display: flex;
gap: 1rem;
}
/* Buttons */
.btn {
padding: 0.5rem 1rem;
border: none;
border-radius: 8px;
font-size: 0.9rem;
font-weight: 600;
cursor: pointer;
display: inline-flex;
align-items: center;
gap: 0.4rem;
transition: all 0.3s ease;
position: relative;
overflow: hidden;
}
.btn::before {
content: '';
position: absolute;
top: 50%;
left: 50%;
width: 0;
height: 0;
border-radius: 50%;
background: rgba(255, 255, 255, 0.2);
transform: translate(-50%, -50%);
transition: width 0.6s, height 0.6s;
}
.btn:hover::before {
width: 300px;
height: 300px;
}
.btn-primary {
background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
color: white;
}
.btn-secondary {
background: var(--glass-bg);
color: var(--text-primary);
border: 1px solid var(--glass-border);
}
.btn-danger {
background: linear-gradient(135deg, var(--danger-color), #ff6b6b);
color: white;
}
.btn:hover {
transform: translateY(-2px);
box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}
.btn-block {
width: 100%;
justify-content: center;
}
/* Stats Grid */
.stats-grid {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
gap: 1.5rem;
margin-bottom: 2rem;
}
.stat-card {
padding: 1rem;
border-radius: 12px;
display: flex;
align-items: center;
gap: 1rem;
transition: all 0.3s ease;
}
.stat-card:hover {
transform: translateY(-5px);
box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4);
}
.stat-icon {
width: 48px;
height: 48px;
border-radius: 10px;
display: flex;
align-items: center;
justify-content: center;
font-size: 1.5rem;
color: white;
}
.stat-info {
flex: 1;
}
.stat-label {
font-size: 0.9rem;
color: var(--text-secondary);
margin-bottom: 0.25rem;
}
.stat-value {
font-size: 2rem;
font-weight: 700;
color: var(--text-primary);
}
/* Table Container */
.table-container {
border-radius: 15px;
padding: 1.5rem;
}
.table-header {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 1.5rem;
}
.table-header h2 {
display: flex;
align-items: center;
gap: 0.5rem;
font-size: 1.5rem;
}
.search-box {
position: relative;
display: flex;
align-items: center;
}
.search-box i {
position: absolute;
left: 1rem;
color: var(--text-secondary);
}
.search-box input {
padding: 0.75rem 1rem 0.75rem 2.5rem;
background: var(--glass-bg);
border: 1px solid var(--glass-border);
border-radius: 10px;
color: var(--text-primary);
font-size: 1rem;
width: 300px;
transition: all 0.3s ease;
}
.search-box input:focus {
outline: none;
border-color: var(--primary-color);
box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}
/* Table */
.table-wrapper {
overflow-x: auto;
border-radius: 10px;
}
.devices-table {
width: 100%;
border-collapse: collapse;
}
.devices-table thead tr {
background: var(--glass-bg);
}
.devices-table th {
padding: 1rem;
text-align: left;
font-weight: 600;
color: var(--text-secondary);
text-transform: uppercase;
font-size: 0.85rem;
letter-spacing: 0.5px;
}
.devices-table tbody tr {
border-bottom: 1px solid var(--glass-border);
transition: all 0.3s ease;
}
.devices-table tbody tr:hover {
background: var(--glass-bg);
}
.devices-table td {
padding: 1rem;
color: var(--text-primary);
}
.status-badge {
display: inline-flex;
align-items: center;
gap: 0.5rem;
padding: 0.4rem 0.8rem;
border-radius: 20px;
font-size: 0.85rem;
font-weight: 600;
}
.status-active {
background: rgba(67, 233, 123, 0.2);
color: var(--success-color);
}
.status-inactive {
background: rgba(245, 87, 108, 0.2);
color: var(--danger-color);
}
.action-btn {
background: none;
border: none;
color: var(--text-secondary);
cursor: pointer;
padding: 0.5rem;
border-radius: 5px;
transition: all 0.3s ease;
font-size: 1rem;
}
.action-btn:hover {
background: var(--glass-bg);
}
.action-btn.edit:hover {
color: var(--info-color);
}
.action-btn.delete:hover {
color: var(--danger-color);
}
.action-btn.details:hover {
color: var(--primary-color);
}
.action-btn.connect:hover {
color: var(--success-color);
}
.loading {
text-align: center;
padding: 3rem;
color: var(--text-secondary);
}
.loading span {
display: inline-block;
margin-left: 1rem;
}
.spinner {
display: inline-block;
width: 30px;
height: 30px;
border: 3px solid var(--glass-border);
border-top-color: var(--primary-color);
border-radius: 50%;
animation: spin 1s linear infinite;
}
@keyframes spin {
to { transform: rotate(360deg); }
}
/* Modal */
.modal {
display: none;
position: fixed;
top: 0;
left: 0;
width: 100%;
height: 100%;
background: rgba(0, 0, 0, 0.7);
backdrop-filter: blur(5px);
z-index: 1000;
align-items: center;
justify-content: center;
animation: fadeIn 0.3s ease;
}
.modal.active {
display: flex;
}
@keyframes fadeIn {
from { opacity: 0; }
to { opacity: 1; }
}
.modal-content {
width: 90%;
max-width: 500px;
border-radius: 15px;
overflow: hidden;
animation: slideUp 0.3s ease;
}
.modal-large {
max-width: 700px;
}
@keyframes slideUp {
from {
transform: translateY(50px);
opacity: 0;
}
to {
transform: translateY(0);
opacity: 1;
}
}
.modal-header {
padding: 1.5rem;
display: flex;
justify-content: space-between;
align-items: center;
border-bottom: 1px solid var(--glass-border);
}
.modal-header h2 {
display: flex;
align-items: center;
gap: 0.5rem;
font-size: 1.5rem;
}
.modal-close {
background: none;
border: none;
color: var(--text-secondary);
font-size: 2rem;
cursor: pointer;
padding: 0;
width: 30px;
height: 30px;
display: flex;
align-items: center;
justify-content: center;
border-radius: 5px;
transition: all 0.3s ease;
}
.modal-close:hover {
background: var(--glass-bg);
color: var(--text-primary);
}
.modal-body {
padding: 1.5rem;
}
.modal-footer {
padding: 1.5rem;
display: flex;
gap: 1rem;
justify-content: flex-end;
border-top: 1px solid var(--glass-border);
}
.form-group {
margin-bottom: 1.5rem;
}
.form-group label {
display: block;
margin-bottom: 0.5rem;
color: var(--text-secondary);
font-weight: 600;
}
.form-control {
width: 100%;
padding: 0.75rem;
background: var(--glass-bg);
border: 1px solid var(--glass-border);
border-radius: 10px;
color: var(--text-primary);
font-size: 1rem;
transition: all 0.3s ease;
}
.form-control:focus {
outline: none;
border-color: var(--primary-color);
box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}
.form-control:read-only {
background: rgba(255, 255, 255, 0.03);
cursor: not-allowed;
}
textarea.form-control {
resize: vertical;
min-height: 100px;
font-family: inherit;
}
.warning-text {
color: var(--warning-color);
margin-top: 0.5rem;
font-size: 0.9rem;
}
.key-display {
background: var(--dark-bg);
padding: 1rem;
border-radius: 10px;
margin-bottom: 1rem;
word-break: break-all;
}
.key-display code {
color: var(--success-color);
font-family: 'Courier New', monospace;
font-size: 0.95rem;
}
.details-grid {
display: grid;
gap: 1rem;
}
.detail-item {
display: grid;
grid-template-columns: 150px 1fr;
gap: 1rem;
padding: 0.75rem;
background: var(--glass-bg);
border-radius: 10px;
}
.detail-label {
font-weight: 600;
color: var(--text-secondary);
}
.detail-value {
color: var(--text-primary);
word-break: break-all;
font-family: monospace;
}
/* Toast Notification */
.toast {
position: fixed;
bottom: 2rem;
right: 2rem;
padding: 1rem 1.5rem;
border-radius: 10px;
display: flex;
align-items: center;
gap: 0.75rem;
color: var(--text-primary);
transform: translateX(400px);
transition: transform 0.3s ease;
z-index: 2000;
}
.toast.show {
transform: translateX(0);
}
.toast i {
color: var(--success-color);
font-size: 1.2rem;
}
/* Animations */
.fade-in {
animation: fadeIn 0.6s ease;
}
@keyframes fadeIn {
from {
opacity: 0;
transform: translateY(20px);
}
to {
opacity: 1;
transform: translateY(0);
}
}
/* Responsive */
@media (max-width: 768px) {
.container {
padding: 0 1rem 1rem;
}
.header-section {
flex-direction: column;
gap: 1rem;
align-items: flex-start;
}
.action-buttons {
width: 100%;
}
.action-buttons .btn {
flex: 1;
}
.stats-grid {
grid-template-columns: 1fr;
}
.search-box input {
width: 100%;
}
.table-header {
flex-direction: column;
gap: 1rem;
align-items: flex-start;
}
.modal-content {
width: 95%;
}
.detail-item {
grid-template-columns: 1fr;
}
.nav-stats {
flex-wrap: wrap;
}
}