Files
tauri-router-app-template/styles.css

135 lines
3.1 KiB
CSS

/* --- Root Variables & Reset --- */
:root {
--bg-color: #0f0f13;
--card-bg: rgba(255, 255, 255, 0.03);
--card-border: rgba(255, 255, 255, 0.08);
--text-primary: #e2e2e7;
--text-secondary: #a0a0b0;
--accent-color: #4a90e2;
--nav-bg: rgba(30, 30, 46, 0.95);
/* Fallback for blur */
--danger: #ef4444;
}
* {
box-sizing: border-box;
-webkit-tap-highlight-color: transparent;
/* UX-Finishing: No blue flash */
}
/* --- Global & Layout --- */
body {
background-color: var(--bg-color);
color: var(--text-primary);
font-family:
"Inter",
-apple-system,
BlinkMacSystemFont,
"Segoe UI",
Roboto,
sans-serif;
margin: 0;
line-height: 1.5;
display: flex;
justify-content: center;
min-height: 100vh;
overflow-x: hidden;
/* Performance: Prevent horizontal scroll */
-webkit-tap-highlight-color: transparent;
/* Fix: Blurry text */
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
text-rendering: optimizeLegibility;
}
/* --- Navigation Dock --- */
.navbar-dock {
position: fixed;
/* Safe Areas: Bottom inset */
bottom: calc(20px + env(safe-area-inset-bottom));
left: 50%;
transform: translateX(-50%);
background-color: var(--nav-bg);
padding: 12px 24px;
border-radius: 50px;
border: 1px solid rgba(255, 255, 255, 0.1);
display: flex;
gap: 20px;
box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
z-index: 1000;
width: max-content;
max-width: 90%;
/* Fix: Blurry text in transformed elements */
backface-visibility: hidden;
}
@supports (backdrop-filter: blur(12px)) or (-webkit-backdrop-filter: blur(12px)) {
.navbar-dock {
background-color: rgba(30, 30, 46, 0.85);
backdrop-filter: blur(12px);
-webkit-backdrop-filter: blur(12px);
}
}
.nav-link {
color: var(--text-secondary);
text-decoration: none;
font-weight: 600;
font-size: 0.9rem;
transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
/* Touch-Ergonomie: Min 44px effective height */
padding: 10px 12px;
user-select: none;
/* UX-Finishing */
display: flex;
align-items: center;
justify-content: center;
min-height: 44px;
position: relative;
}
.nav-link:hover {
color: #ffffff;
transform: translateY(-3px);
}
.nav-link.active {
color: var(--accent-color);
}
/* --- Pages (Profile & Settings) --- */
.profile-container,
.settings-container {
width: 100%;
max-width: 800px;
padding: 40px 24px 120px 24px; /* Bottom padding to clear navbar */
display: flex;
flex-direction: column;
align-items: flex-start;
animation: fadeIn 0.4s ease-out;
}
h1 {
font-size: 2rem;
font-weight: 700;
margin-bottom: 24px;
background: linear-gradient(135deg, #fff 0%, #a5a5a5 100%);
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
background-clip: text;
}
/* Animation */
@keyframes fadeIn {
from {
opacity: 0;
transform: translateY(10px);
}
to {
opacity: 1;
transform: translateY(0);
}
}