aero-mail/src/renderer/src/assets/styles/base.css
d.a.kolesov dffc85a24b
All checks were successful
Release / release (push) Successful in 2m35s
material3
2026-07-30 08:43:33 +07:00

242 lines
8.2 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.

/* Регистрируем glow-компоненты как анимируемые свойства */
@property --glow-r { syntax: '<number>'; initial-value: 0; inherits: true; }
@property --glow-g { syntax: '<number>'; initial-value: 0; inherits: true; }
@property --glow-b { syntax: '<number>'; initial-value: 0; inherits: true; }
@property --glow-a { syntax: '<number>'; initial-value: 0; inherits: true; }
@property --glow-x { syntax: '<number>'; initial-value: 75; inherits: true; }
@property --glow-y { syntax: '<number>'; initial-value: 50; inherits: true; }
*,
*::before,
*::after {
margin: 0;
padding: 0;
box-sizing: border-box;
}
html,
body {
height: 100%;
overflow: hidden;
font-family: var(--font-sans);
font-size: 13px;
line-height: 1.5;
color: var(--text-primary);
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
user-select: none;
/* Rich gradient base — accent-glow и content-glow выставляются через JS */
background:
radial-gradient(ellipse 60% 50% at 15% 15%, var(--accent-glow, rgba(168,230,0,0.08)) 0%, transparent 70%),
radial-gradient(ellipse 95% 85% at calc(var(--glow-x) * 1%) calc(var(--glow-y) * 1%), rgba(var(--glow-r), var(--glow-g), var(--glow-b), var(--glow-a)) 0%, transparent 100%),
radial-gradient(ellipse 45% 55% at 88% 90%, rgba(0, 110, 220, 0.05) 0%, transparent 70%),
radial-gradient(ellipse 60% 40% at 50% 50%, rgba(80, 0, 160, 0.04) 0%, transparent 100%),
#09090e;
/* Плавный переход между цветами свечения */
transition:
--glow-r 400ms ease,
--glow-g 400ms ease,
--glow-b 400ms ease,
--glow-a 400ms ease;
}
#app {
height: 100%;
}
a {
color: var(--accent);
text-decoration: none;
}
a:hover { color: var(--accent-hover); }
button {
font-family: inherit;
font-size: inherit;
color: inherit;
cursor: pointer;
border: none;
background: none;
outline: none;
}
button:focus-visible {
outline: 2px solid var(--accent);
outline-offset: 1px;
border-radius: var(--radius-sm);
}
input,
select,
textarea {
font-family: inherit;
font-size: inherit;
color: var(--text-primary);
background:
linear-gradient(180deg, rgba(255, 255, 255, 0.055) 0%, rgba(255, 255, 255, 0.02) 100%),
rgba(12, 12, 20, 0.55);
border: 1px solid rgba(255, 255, 255, 0.13);
border-radius: var(--radius-sm);
padding: 7px 10px;
outline: none;
backdrop-filter: blur(16px) saturate(1.6);
-webkit-backdrop-filter: blur(16px) saturate(1.6);
box-shadow:
inset 0 1.5px 0 rgba(255, 255, 255, 0.13),
inset 0 -1px 0 rgba(0, 0, 0, 0.18),
inset 1px 0 0 rgba(255, 255, 255, 0.04),
inset -1px 0 0 rgba(255, 255, 255, 0.04),
0 1px 3px rgba(0, 0, 0, 0.22);
transition:
border-color var(--transition-fast),
box-shadow var(--transition-fast),
background var(--transition-fast);
}
input:hover:not(:focus),
select:hover:not(:focus),
textarea:hover:not(:focus) {
background:
linear-gradient(180deg, rgba(255, 255, 255, 0.07) 0%, rgba(255, 255, 255, 0.03) 100%),
rgba(12, 12, 20, 0.60);
border-color: rgba(255, 255, 255, 0.18);
}
input:focus,
select:focus,
textarea:focus {
background:
linear-gradient(180deg, rgba(255, 255, 255, 0.08) 0%, rgba(255, 255, 255, 0.03) 100%),
rgba(14, 14, 24, 0.65);
border-color: color-mix(in srgb, var(--accent) 60%, transparent);
box-shadow:
inset 0 1.5px 0 rgba(255, 255, 255, 0.16),
inset 0 -1px 0 rgba(0, 0, 0, 0.20),
inset 1px 0 0 rgba(255, 255, 255, 0.05),
inset -1px 0 0 rgba(255, 255, 255, 0.05),
0 0 0 3px color-mix(in srgb, var(--accent) 15%, transparent),
0 0 12px color-mix(in srgb, var(--accent) 8%, transparent);
}
/* ── Scrollbar ─────────────────────────────────────────── */
::-webkit-scrollbar { width: 4px; height: 4px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb {
background: rgba(255, 255, 255, 0.12);
border-radius: var(--radius-full);
}
::-webkit-scrollbar-thumb:hover {
background: rgba(255, 255, 255, 0.22);
}
/* ── Custom tooltip ────────────────────────────────────── */
.app-tooltip {
position: fixed;
z-index: 9999;
max-width: 480px;
padding: 5px 10px;
font-size: 11.5px;
font-weight: 500;
line-height: 1.4;
color: rgba(255, 255, 255, 0.88);
white-space: pre-wrap;
word-break: break-all;
pointer-events: none;
/* Liquid glass: тёмный непрозрачный фон + frosted border */
background:
linear-gradient(135deg, rgba(255, 255, 255, 0.08) 0%, rgba(255, 255, 255, 0.02) 100%),
rgba(14, 14, 22, 0.92);
border: 1px solid rgba(255, 255, 255, 0.16);
border-radius: 7px;
box-shadow:
inset 0 1px 0 rgba(255, 255, 255, 0.20),
0 0 0 1px rgba(0, 0, 0, 0.35),
0 6px 20px rgba(0, 0, 0, 0.50),
0 2px 6px rgba(0, 0, 0, 0.30);
opacity: 0;
transform: translateY(4px) scale(0.96);
transition:
opacity 110ms ease,
transform 140ms cubic-bezier(0.34, 1.15, 0.64, 1);
}
.app-tooltip--visible {
opacity: 1;
transform: translateY(0) scale(1);
}
/* ── Utilities ─────────────────────────────────────────── */
.truncate {
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.visually-hidden {
position: absolute;
width: 1px; height: 1px;
padding: 0; margin: -1px;
overflow: hidden;
clip: rect(0, 0, 0, 0);
border: 0;
}
/* ══════════════════════════════════════════════════════════
Material 3 — глобальные оверрайды input/select/textarea,
скроллбара и tooltip (activно только при html[data-design="material3"])
══════════════════════════════════════════════════════════ */
html[data-design='material3'] input,
html[data-design='material3'] select,
html[data-design='material3'] textarea {
background: var(--md-sys-color-surface-container-highest);
border: 1px solid var(--md-sys-color-outline);
border-radius: var(--md-sys-shape-corner-small);
box-shadow: none;
font-size: var(--md-sys-typescale-body-large-size);
line-height: var(--md-sys-typescale-body-large-line);
}
html[data-design='material3'] input:hover:not(:focus),
html[data-design='material3'] select:hover:not(:focus),
html[data-design='material3'] textarea:hover:not(:focus) {
background: color-mix(in srgb, var(--md-sys-color-on-surface) 4%, var(--md-sys-color-surface-container-highest));
border-color: var(--md-sys-color-on-surface);
}
html[data-design='material3'] input:focus,
html[data-design='material3'] select:focus,
html[data-design='material3'] textarea:focus {
background: var(--md-sys-color-surface-container-highest);
border-color: var(--md-sys-color-primary);
box-shadow: inset 0 0 0 1px var(--md-sys-color-primary);
}
/* ── Scrollbar ─────────────────────────────────────────── */
html[data-design='material3'] ::-webkit-scrollbar-thumb {
background: var(--md-sys-color-outline);
border-radius: var(--md-sys-shape-corner-full);
}
html[data-design='material3'] ::-webkit-scrollbar-thumb:hover {
background: var(--md-sys-color-on-surface-variant);
}
/* ── Tooltip (M3 plain tooltip: inverse-surface/inverse-on-surface) ── */
html[data-design='material3'] .app-tooltip {
background: var(--md-sys-color-inverse-surface);
color: var(--md-sys-color-inverse-on-surface);
border: none;
border-radius: var(--md-sys-shape-corner-extra-small);
box-shadow: var(--md-sys-elevation-2);
font-size: var(--md-sys-typescale-body-small-size);
font-weight: var(--md-sys-typescale-body-small-weight);
line-height: var(--md-sys-typescale-body-small-line);
transition:
opacity var(--md-sys-motion-duration-short2) var(--md-sys-motion-easing-standard),
transform var(--md-sys-motion-duration-short3) var(--md-sys-motion-easing-emphasized-decelerate);
}