Files
cats/client/src/index.css
heagbokat 91ab44c6fb feat: UI redesign — polished layout, modal, nav, profile
- CSS: refined shadows with border ring, dark bg #0A0A0A, larger card
  radius (16/22px), modal-backdrop blur, scrollbar styling, new
  dropzone + profile-grid CSS classes
- Navbar: paw emoji logo, labels under icons, accent gradient bar,
  active-state ring on avatar
- Login / Register: auth card with decorative background blobs,
  form wrapped in card, cleaner spacing
- CatModal: two-column layout on desktop (photo left, info right),
  modal-backdrop blur, comment input with user avatar, like label
- ProfilePage: 88px avatar with camera overlay, inline stat bar with
  icons, grid section divider, Stat helper component
- CatCard: points badge in header (amber), caption text secondary
  color, ring on avatar
- FeedSidebar: color-coded rank badges, hover rows, star icon
- UploadPage: new dropzone-idle/dropzone-active CSS classes,
  filename chip on preview, UserAvatar in caption row, HEIC/AVIF in
  accepted formats hint, 500-char counter

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-26 00:30:41 +03:00

384 lines
10 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.
@import "tailwindcss";
@plugin "tailwindcss-animate";
/* ── Светлая тема ── */
:root,
[data-theme="light"] {
--bg: #F5F5F5;
--surface: #FFFFFF;
--surface-hover: #F9F9F9;
--fg: #1A1A1A;
--fg-secondary: #737373;
--fg-tertiary: #B0B0B0;
--accent: #C9445D;
--accent-hover: #B03650;
--accent-soft: rgba(201, 68, 93, 0.09);
--accent-light: #FFF0F3;
--secondary: #FAFAFA;
--border: #E0E0E0;
--border-light: #EFEFEF;
--danger: #C9445D;
--danger-hover: #B03650;
--danger-light: #FFF0F3;
--success: #2E9E6B;
--success-light: #EEF8F3;
--radius: 10px;
--radius-lg: 16px;
--radius-xl: 22px;
--shadow-sm: 0 1px 2px rgba(0,0,0,0.04), 0 0 0 1px rgba(0,0,0,0.04);
--shadow-md: 0 4px 16px rgba(0,0,0,0.07), 0 0 0 1px rgba(0,0,0,0.03);
--shadow-lg: 0 12px 36px rgba(0,0,0,0.10), 0 0 0 1px rgba(0,0,0,0.03);
--shadow-xl: 0 24px 64px rgba(0,0,0,0.13), 0 0 0 1px rgba(0,0,0,0.04);
}
/* ── Тёмная тема ── */
[data-theme="dark"] {
--bg: #0A0A0A;
--surface: #141414;
--surface-hover: #1C1C1C;
--fg: #F0F0F0;
--fg-secondary: #A0A0A0;
--fg-tertiary: #4A4A4A;
--accent: #E8687E;
--accent-hover: #F07A8E;
--accent-soft: rgba(232, 104, 126, 0.12);
--accent-light: #2A0F16;
--secondary: #0A0A0A;
--border: #242424;
--border-light: #1C1C1C;
--danger: #E8687E;
--danger-hover: #F07A8E;
--danger-light: #2A0F16;
--success: #48B884;
--success-light: #0D2419;
--shadow-sm: 0 1px 3px rgba(0,0,0,0.5), 0 0 0 1px rgba(255,255,255,0.04);
--shadow-md: 0 4px 16px rgba(0,0,0,0.6), 0 0 0 1px rgba(255,255,255,0.04);
--shadow-lg: 0 12px 40px rgba(0,0,0,0.7), 0 0 0 1px rgba(255,255,255,0.05);
--shadow-xl: 0 24px 72px rgba(0,0,0,0.8), 0 0 0 1px rgba(255,255,255,0.06);
}
* { border-color: var(--border); box-sizing: border-box; }
html { transition: background-color 0.25s ease, color 0.25s ease; }
body {
background: var(--bg);
color: var(--fg);
font-family: "Manrope", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
line-height: 1.6;
letter-spacing: -0.01em;
transition: background-color 0.25s ease, color 0.25s ease;
}
::selection { background: var(--accent); color: white; }
/* ── Scrollbar ── */
::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 99px; }
::-webkit-scrollbar-thumb:hover { background: var(--fg-tertiary); }
/* ── Анимации ── */
@keyframes fade-up {
from { opacity: 0; transform: translateY(10px); }
to { opacity: 1; transform: translateY(0); }
}
@keyframes fade-in {
from { opacity: 0; }
to { opacity: 1; }
}
@keyframes scale-in {
from { opacity: 0; transform: scale(0.95) translateY(4px); }
to { opacity: 1; transform: scale(1) translateY(0); }
}
@keyframes pop {
0% { transform: scale(1); }
40% { transform: scale(1.3); }
100% { transform: scale(1); }
}
@keyframes toast-in {
from { opacity: 0; transform: translateY(10px) scale(0.94); }
to { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes shimmer {
0% { background-position: -200% 0; }
100% { background-position: 200% 0; }
}
@keyframes slide-up {
from { transform: translateY(100%); opacity: 0; }
to { transform: translateY(0); opacity: 1; }
}
@keyframes heart-burst {
0% { transform: scale(0) rotate(-15deg); opacity: 1; }
50% { transform: scale(1.4) rotate(5deg); opacity: 1; }
100% { transform: scale(1) rotate(0deg); opacity: 0; }
}
.animate-fade-up { animation: fade-up 0.4s cubic-bezier(0.16, 1, 0.3, 1) both; }
.animate-fade-in { animation: fade-in 0.25s ease both; }
.animate-scale-in { animation: scale-in 0.28s cubic-bezier(0.16, 1, 0.3, 1) both; }
.animate-pop { animation: pop 0.35s cubic-bezier(0.16, 1, 0.3, 1); }
.animate-toast-in { animation: toast-in 0.3s cubic-bezier(0.16, 1, 0.3, 1) both; }
.animate-slide-up { animation: slide-up 0.35s cubic-bezier(0.16, 1, 0.3, 1) both; }
.stagger-1 { animation-delay: 40ms; }
.stagger-2 { animation-delay: 80ms; }
.stagger-3 { animation-delay: 120ms; }
.stagger-4 { animation-delay: 160ms; }
/* ── Скелетон ── */
.skeleton-shimmer {
background: linear-gradient(90deg,
var(--border-light) 25%,
var(--border) 50%,
var(--border-light) 75%
);
background-size: 200% 100%;
animation: shimmer 1.6s ease infinite;
}
/* ── Карточки ── */
.card {
background: var(--surface);
border-radius: var(--radius-lg);
box-shadow: var(--shadow-sm);
transition: box-shadow 0.2s ease, transform 0.2s ease, background-color 0.25s ease;
}
.card-hover:hover {
box-shadow: var(--shadow-md);
transform: translateY(-2px);
}
.card-interactive:hover {
background: var(--surface-hover);
box-shadow: var(--shadow-md);
}
/* ── Пост-карточка ── */
.cat-card {
background: var(--surface);
border-radius: var(--radius-xl);
box-shadow: var(--shadow-sm);
overflow: hidden;
cursor: pointer;
transition:
box-shadow 0.28s cubic-bezier(0.25, 0.46, 0.45, 0.94),
transform 0.28s cubic-bezier(0.25, 0.46, 0.45, 0.94);
will-change: transform, box-shadow;
}
.cat-card:hover {
box-shadow: var(--shadow-lg);
transform: translateY(-4px);
}
.cat-card:active {
transform: translateY(-1px);
box-shadow: var(--shadow-md);
transition-duration: 0.1s;
}
.cat-card-image {
background: var(--bg);
overflow: hidden;
}
.cat-card-img {
transition: transform 0.55s cubic-bezier(0.25, 0.46, 0.45, 0.94);
will-change: transform;
}
.cat-card:hover .cat-card-img {
transform: scale(1.04);
}
/* ── Аватар ── */
.avatar-colored {
border-radius: 50%;
display: flex;
align-items: center;
justify-content: center;
font-weight: 700;
color: white;
user-select: none;
}
/* ── Кнопки ── */
.btn-ghost {
display: inline-flex;
align-items: center;
justify-content: center;
border-radius: 50%;
transition: background 0.15s ease, transform 0.15s cubic-bezier(0.34, 1.56, 0.64, 1);
cursor: pointer;
border: none;
background: transparent;
}
.btn-ghost:hover { background: var(--border-light); transform: scale(1.1); }
.btn-ghost:active { transform: scale(0.9); transition-duration: 0.08s; }
.action-btn {
padding: 6px 10px;
border-radius: 10px;
border: none;
background: transparent;
cursor: pointer;
transition:
background 0.15s ease,
color 0.15s ease,
transform 0.15s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.action-btn:hover {
background: var(--border-light);
color: var(--fg);
transform: scale(1.06);
}
.action-btn:active {
transform: scale(0.94);
transition-duration: 0.08s;
}
/* ── Тег ── */
.tag {
display: inline-flex;
align-items: center;
gap: 0.25rem;
padding: 0.15rem 0.6rem;
border-radius: 9999px;
font-size: 0.6875rem;
font-weight: 600;
letter-spacing: 0.02em;
}
/* ── Focus ── */
.focus-ring { transition: border-color 0.15s, box-shadow 0.15s; }
.focus-ring:focus {
border-color: var(--accent);
box-shadow: 0 0 0 3px var(--accent-soft);
outline: none;
}
/* ── Утилиты ── */
.text-secondary { color: var(--fg-secondary); }
.text-tertiary { color: var(--fg-tertiary); }
.divider { height: 1px; background: var(--border-light); width: 100%; }
.stat-value { font-variant-numeric: tabular-nums; font-weight: 700; letter-spacing: -0.02em; }
/* ── Навбар ── */
.nav-glass {
background: rgba(245, 245, 245, 0.88);
backdrop-filter: blur(24px) saturate(1.8);
-webkit-backdrop-filter: blur(24px) saturate(1.8);
transition: background 0.25s ease;
}
[data-theme="dark"] .nav-glass {
background: rgba(10, 10, 10, 0.88);
}
.nav-accent-bar {
height: 2px;
background: linear-gradient(90deg, var(--accent) 0%, transparent 100%);
width: 100%;
position: absolute;
top: 0;
left: 0;
opacity: 0.7;
}
.wordmark {
font-size: 15px;
font-weight: 800;
letter-spacing: 0.08em;
text-transform: uppercase;
color: var(--fg);
line-height: 1;
}
.wordmark-dot {
display: inline-block;
width: 5px;
height: 5px;
border-radius: 50%;
background: var(--accent);
margin-left: 2px;
margin-bottom: 2px;
vertical-align: middle;
}
/* ── Страница входа ── */
.auth-bg-blob {
position: absolute;
border-radius: 50%;
filter: blur(80px);
opacity: 0.12;
pointer-events: none;
}
/* ── Профиль ── */
.profile-stat-card {
background: var(--surface);
border-radius: var(--radius-lg);
box-shadow: var(--shadow-sm);
padding: 14px 20px;
display: flex;
align-items: center;
gap: 20px;
}
/* ── Grid профиля ── */
.profile-grid-item {
position: relative;
aspect-ratio: 1;
overflow: hidden;
border-radius: 10px;
background: var(--bg);
cursor: pointer;
}
.profile-grid-item img {
width: 100%;
height: 100%;
object-fit: cover;
transition: transform 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}
.profile-grid-item:hover img { transform: scale(1.07); }
.profile-grid-overlay {
position: absolute;
inset: 0;
background: rgba(0,0,0,0);
display: flex;
align-items: center;
justify-content: center;
transition: background 0.2s ease;
}
.profile-grid-item:hover .profile-grid-overlay { background: rgba(0,0,0,0.22); }
/* ── Дроп-зона ── */
.dropzone-idle {
border: 2px dashed var(--border);
border-radius: var(--radius-xl);
background: var(--surface);
transition: border-color 0.2s, background 0.2s, transform 0.2s;
cursor: pointer;
}
.dropzone-idle:hover {
border-color: var(--fg-tertiary);
background: var(--surface-hover);
}
.dropzone-active {
border-color: var(--accent) !important;
background: var(--accent-light) !important;
transform: scale(1.01);
}
/* ── Модал ── */
.modal-backdrop {
background: rgba(0,0,0,0.5);
backdrop-filter: blur(4px);
-webkit-backdrop-filter: blur(4px);
}
@media (max-width: 640px) {
.mobile-full {
border-radius: 0 !important;
margin-left: -1rem;
margin-right: -1rem;
width: calc(100% + 2rem);
}
}