/**
 * Brutus Tools - Custom Styles
 */

:root {
    --primary: #7c3aed;
    --primary-dark: #6d28d9;
    --background: #0a0a12;
    --surface: #12121a;
    --text: #e0e0e0;
    --success: #4dff91;
    --warning: #f59e0b;
    --error: #ff6b6b;
    --info: #0ea5e9;
}

body {
    font-family: 'Inter', sans-serif;
    background: var(--background);
    color: var(--text);
    overflow-x: hidden;
}

.code-font {
    font-family: 'JetBrains Mono', monospace;
}

.gradient-bg {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: #12121a;
    border-radius: 5px;
}

::-webkit-scrollbar-thumb {
    background: #2a2a35;
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: #3a3a45;
}

/* Animation */
@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.float-animation {
    animation: float 6s ease-in-out infinite;
}

@keyframes pulse-glow {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

.pulse-glow {
    animation: pulse-glow 2s ease-in-out infinite;
}

/* Card hover effects */
.tool-card {
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.tool-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
    transition: 0.5s;
}

.tool-card:hover::before {
    left: 100%;
}

.tool-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.3);
}

/* Gradient borders */
.gradient-border {
    position: relative;
    background: var(--surface);
    border-radius: 0.75rem;
}

.gradient-border::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg, var(--primary), var(--info), var(--warning));
    border-radius: 0.875rem;
    z-index: -1;
    opacity: 0.5;
    transition: opacity 0.3s;
}

.gradient-border:hover::before {
    opacity: 1;
}

/* Grid background */
.grid-bg {
    background-image: 
        linear-gradient(rgba(124, 58, 237, 0.1) 1px, transparent 1px),
        linear-gradient(90deg, rgba(124, 58, 237, 0.1) 1px, transparent 1px);
    background-size: 50px 50px;
}

/* Blob animation */
.blob {
    position: absolute;
    width: 300px;
    height: 300px;
    background: linear-gradient(45deg, var(--primary), var(--info));
    border-radius: 50%;
    filter: blur(100px);
    opacity: 0.2;
    z-index: -1;
}

/* Tool icon styles */
.tool-icon {
    transition: all 0.3s ease;
}

.tool-card:hover .tool-icon {
    transform: scale(1.1) rotate(5deg);
}

/* Tag styles */
.tool-tag {
    font-size: 0.7rem;
    padding: 0.2rem 0.6rem;
    border-radius: 1rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* Stats counter */
.stat-counter {
    font-family: 'JetBrains Mono', monospace;
    font-size: 2.5rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--primary), var(--info));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Анимация для кнопки "Наверх" */
#backToTop {
    transition: opacity 0.3s ease, transform 0.3s ease, background-color 0.3s ease;
}

#backToTop:hover {
    background-color: #1a1a25;
    border-color: #7c3aed;
    transform: scale(1.1);
}

/* Анимация для социальных иконок */
footer a:hover {
    transform: translateY(-2px);
}

/* Градиентные текстовые эффекты */
footer h3 i {
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

/* Category filter active state */
.category-active {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
}

/* Анимации для шапки */
@keyframes gradient {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.animate-gradient {
    background-size: 200% auto;
    animation: gradient 3s ease infinite;
}

@keyframes spin-slow {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.animate-spin-slow {
    animation: spin-slow 20s linear infinite;
}

@keyframes progress {
    from { transform: translateX(-100%); }
    to { transform: translateX(0); }
}

.animate-progress {
    animation: progress 1.5s ease-out;
}

/* Анимация счетчика */
.animate-count {
    font-variant-numeric: tabular-nums;
}