:root {
    /* Light theme colors */
    --primary-color: #9370DB;
    --primary-light: #b19cd9;
    --primary-dark: #7b5fb6;
    --text-color: #333333;
    --text-light: #666666;
    --bg-color: #ffffff;
    --card-bg: #f8f9fa;
    --header-bg: rgba(255, 255, 255, 0.95);
    --footer-bg: #f5f5f5;
    --border-color: #e9ecef;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.15);
    --transition: all 0.3s ease;
    --success-color: #10B981;
    --warning-color: #F59E0B;
    --error-color: #EF4444;
}

[data-theme="dark"] {
    /* Dark theme colors */
    --primary-color: #8a63d2;
    --primary-light: #9d7fdf;
    --primary-dark: #6b4fa5;
    --text-color: #f0f0f0;
    --text-light: #b0b0b0;
    --bg-color: #1a1a1a;
    --card-bg: #2d2d2d;
    --header-bg: rgba(26, 26, 26, 0.95);
    --footer-bg: #252525;
    --border-color: #404040;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.5);
}

/* Dark theme colors */
@font-face {
    font-family: 'Virgo';
    src: url('/fonts/Virgo.ttf') format('truetype');
    src: url('./fonts/Virgo.ttf') format('truetype');
    src: url('../fonts/Virgo.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--bg-color);
    transition: var(--transition);
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
}

p {
    margin-bottom: 1rem;
}

/* Animated background */
.animated-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(-45deg, #f8f9fa, #e9ecef, #f1f3f4, #e9ecef);
    background-size: 400% 400%;
    animation: gradient 15s ease infinite;
    z-index: -2;
}

[data-theme="dark"] .animated-bg {
    background: linear-gradient(-45deg, #1a1a2e, #16213e, #0f3460, #1a1a2e);
}

@keyframes gradient {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Floating elements */
.global-floating-elements {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1;
}

.floating-element {
    position: absolute;
    font-size: 1.8rem;
    opacity: 0.4;
    animation: float-simple 6s ease-in-out infinite;
    display: block !important;
}

@keyframes float-simple {
    0%, 100% { 
        transform: translate(0, 0) rotate(0deg) scale(1);
        opacity: 0.3;
    }
    33% { 
        transform: translate(10px, -15px) rotate(120deg) scale(1.1);
        opacity: 0.5;
    }
    66% { 
        transform: translate(-5px, 10px) rotate(240deg) scale(0.9);
        opacity: 0.4;
    }
}

/* Floating elements positions */
.element-1 { top: 10%; left: 5%; animation-delay: 0s; }
.element-2 { top: 15%; right: 8%; animation-delay: 1s; }
.element-3 { top: 60%; left: 3%; animation-delay: 2s; }
.element-4 { top: 70%; right: 5%; animation-delay: 3s; }
.element-5 { top: 30%; left: 15%; animation-delay: 4s; }
.element-6 { top: 40%; right: 12%; animation-delay: 5s; }
.element-7 { top: 80%; left: 20%; animation-delay: 0s; }
.element-8 { top: 20%; right: 25%; animation-delay: 1s; }
.element-9 { top: 55%; left: 25%; animation-delay: 2s; }
.element-10 { top: 35%; right: 30%; animation-delay: 3s; }
.element-11 { top: 75%; left: 35%; animation-delay: 4s; }
.element-12 { top: 45%; right: 35%; animation-delay: 5s; }

/* Scroll to top button */
.scroll-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    border: none;
    border-radius: 50%;
    background: var(--primary-color);
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    box-shadow: var(--shadow-lg);
    transition: var(--transition);
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
}

.scroll-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.scroll-to-top:hover {
    background: var(--primary-dark);
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(147, 112, 219, 0.4);
}

/* Header */
.header {
    position: fixed;
    top: 0;
    width: 100%;
    background: var(--header-bg);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    z-index: 1000;
    transition: var(--transition);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
    height: 70px;
}

.logo {
    display: flex;
    align-items: center;
    height: 100%;
}

.logo h2 {
    color: var(--primary-color);
    font-weight: 700;
    font-size: 1.5rem;
    cursor: pointer;
    transition: var(--transition);
    margin: 0;
    line-height: 1;
    display: flex;
    align-items: center;
    height: 100%;
}

.logo h2:hover {
    transform: translateY(-2px);
}

.nav-list {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-link {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
    transition: var(--transition);
    position: relative;
    padding: 0.5rem 0;
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary-color);
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--primary-color);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
    height: 100%;
}

.theme-btn {
    background: none;
    border: none;
    font-size: 1.2rem;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 50%;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    height: 40px;
    width: 40px;
}

.theme-btn:hover {
    background: var(--card-bg);
}

.mobile-menu-btn {
    display: none;
    flex-direction: column;
    background: none;
    border: none;
    cursor: pointer;
    gap: 4px;
    padding: 0.5rem;
    height: 40px;
    width: 40px;
    justify-content: center;
    align-items: center;
}

.mobile-menu-btn span {
    width: 25px;
    height: 3px;
    background: var(--text-color);
    transition: var(--transition);
    border-radius: 2px;
}

/* Mobile avatar */
.mobile-avatar {
    display: none;
    justify-content: center;
    margin-bottom: 2rem;
    margin-top: 2rem;
}

/* Hero section */
.hero {
    padding: 120px 0 80px;
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-title {
    font-size: 3.5rem;
    margin-bottom: 1rem;
}

.highlight {
    color: var(--primary-color);
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--text-light);
    font-weight: 400;
}

.hero-description {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    color: var(--text-light);
    line-height: 1.7;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.btn {
    padding: 0.8rem 2rem;
    border: none;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-size: 1rem;
}

.btn-primary {
    background: var(--primary-color);
    color: white;
    box-shadow: 0 4px 15px rgba(147, 112, 219, 0.3);
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(147, 112, 219, 0.4);
}

.btn-secondary {
    background: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn-secondary:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(147, 112, 219, 0.3);
}

.hero-image {
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

.avatar-container {
    position: relative;
    display: inline-block;
}

.avatar {
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 2;
    box-shadow: var(--shadow-lg);
    border: 4px solid var(--bg-color);
}

.avatar-placeholder {
    font-family: 'Virgo', sans-serif;
    font-size: 4rem;
    font-weight: bold;
    color: white;
}

.avatar-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 320px;
    height: 320px;
    background: var(--primary-color);
    border-radius: 50%;
    filter: blur(40px);
    opacity: 0.3;
    z-index: 1;
    animation: pulse 4s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 0.3; transform: translate(-50%, -50%) scale(1); }
    50% { opacity: 0.5; transform: translate(-50%, -50%) scale(1.05); }
}

/* Avatar rings */
.avatar-ring {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    border: 2px solid var(--primary-color);
    border-radius: 50%;
    opacity: 0.3;
}

.ring-1 {
    width: 340px;
    height: 340px;
    animation: pulse-ring-1 3s ease-in-out infinite;
}

.ring-2 {
    width: 380px;
    height: 380px;
    animation: pulse-ring-2 3s ease-in-out infinite 0.5s;
}

.ring-3 {
    width: 420px;
    height: 420px;
    animation: pulse-ring-3 3s ease-in-out infinite 1s;
}

@keyframes pulse-ring-1 {
    0%, 100% { opacity: 0.1; transform: translate(-50%, -50%) scale(1); }
    50% { opacity: 0.3; transform: translate(-50%, -50%) scale(1.05); }
}

@keyframes pulse-ring-2 {
    0%, 100% { opacity: 0.05; transform: translate(-50%, -50%) scale(1); }
    50% { opacity: 0.2; transform: translate(-50%, -50%) scale(1.08); }
}

@keyframes pulse-ring-3 {
    0%, 100% { opacity: 0.03; transform: translate(-50%, -50%) scale(1); }
    50% { opacity: 0.15; transform: translate(-50%, -50%) scale(1.1); }
}

/* Hero floating elements */
.hero-floating-elements {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.floating-hero-element {
    position: absolute;
    font-size: 2.5rem;
    animation: hero-float 6s ease-in-out infinite;
    opacity: 0.8;
    z-index: 3;
}

@keyframes hero-float {
    0%, 100% { 
        transform: translate(0, 0) rotate(0deg) scale(1);
        opacity: 0.7;
    }
    33% { 
        transform: translate(15px, -20px) rotate(120deg) scale(1.2);
        opacity: 0.9;
    }
    66% { 
        transform: translate(-10px, 15px) rotate(240deg) scale(0.8);
        opacity: 0.6;
    }
}

.h-element-1 { top: 20%; right: 10%; animation-delay: 0s; }
.h-element-2 { bottom: 30%; left: 5%; animation-delay: 2s; }
.h-element-3 { top: 50%; right: 20%; animation-delay: 4s; }
.h-element-4 { top: 10%; left: 15%; animation-delay: 1.5s; }
.h-element-5 { bottom: 20%; right: 25%; animation-delay: 3s; }
.h-element-6 { top: 70%; left: 20%; animation-delay: 2.5s; }

/* Hero stats */
.hero-stats {
    display: flex;
    gap: 2rem;
    margin-top: 2rem;
    justify-content: flex-start;
    flex-wrap: wrap;
}

.stat {
    text-align: center;
    padding: 1.5rem 1rem;
    background: var(--card-bg);
    border-radius: 15px;
    min-width: 120px;
    transition: var(--transition);
    border: 1px solid var(--border-color);
}

.stat:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow);
}

.stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-color);
    display: block;
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-light);
    margin-top: 0.5rem;
}

/* Sections */
section {
    padding: 80px 0;
    position: relative;
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: var(--text-color);
}

/* About section */
.about-content {
    max-width: 800px;
    margin: 0 auto;
}

.about-text p {
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    text-align: left;
    color: var(--text-light);
    line-height: 1.7;
}

/* Timeline */
.experience-timeline {
    margin-top: 3rem;
    position: relative;
    padding-left: 2rem;
}

.experience-timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 2px;
    background: var(--primary-color);
}

.timeline-item {
    position: relative;
    margin-bottom: 2rem;
    padding: 1.5rem;
    background: var(--card-bg);
    border-radius: 15px;
    transition: var(--transition);
    border: 1px solid var(--border-color);
}

.timeline-item:hover {
    transform: translateX(10px);
    box-shadow: var(--shadow);
}

.timeline-item:last-child {
    margin-bottom: 0;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -2rem;
    top: 50%;
    transform: translateY(-50%);
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--primary-color);
    border: 3px solid var(--bg-color);
}

.timeline-date {
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.timeline-content h3 {
    margin-bottom: 0.5rem;
    color: var(--text-color);
}

.timeline-content p {
    opacity: 0.8;
    font-size: 0.95rem;
    margin-bottom: 0;
    text-align: left;
}

/* Skills section */
.skills-section {
    background: var(--card-bg);
    border-radius: 20px;
    margin: 40px auto;
    max-width: 1200px;
    padding: 60px 20px;
    border: 1px solid var(--border-color);
}

.skills-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    max-width: 1000px;
    margin: 0 auto;
}

.skill-category {
    background: var(--bg-color);
    padding: 2rem;
    border-radius: 15px;
    box-shadow: var(--shadow);
    transition: var(--transition);
    border: 1px solid var(--border-color);
}

.skill-category:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg);
}

.skill-category-icon {
    font-size: 3rem;
    text-align: center;
    margin-bottom: 1rem;
    opacity: 0.7;
}

.skill-category h3 {
    margin-bottom: 1.5rem;
    color: var(--primary-color);
    text-align: center;
    font-size: 1.3rem;
}

.skill-bar {
    margin-bottom: 1.5rem;
}

.skill-bar:last-child {
    margin-bottom: 0;
}

.skill-info {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    color: var(--text-color);
}

.skill-progress {
    height: 8px;
    background: var(--border-color);
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--primary-light));
    border-radius: 4px;
    width: 0;
    transition: width 1.5s ease-in-out;
    position: relative;
}

/* Works section */
.works-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2rem;
}

.work-card {
    background: var(--card-bg);
    border-radius: 15px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    min-height: 450px;
    max-width: 100%;
    border: 1px solid var(--border-color);
    opacity: 1;
    transform: translateY(0);
    transition: all 0.3s ease;
}

.work-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg);
}

.work-image {
    height: 200px;
    background: linear-gradient(135deg, var(--primary-light), var(--primary-dark));
    position: relative;
    overflow: hidden;
    flex-shrink: 0;
}

/* Works filter */
.works-filter {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 0.5rem 1.5rem;
    background: transparent;
    border: 1px solid var(--primary-color);
    color: var(--primary-color);
    border-radius: 50px;
    cursor: pointer;
    transition: var(--transition);
    font-size: 0.9rem;
    font-weight: 500;
}

.filter-btn.active,
.filter-btn:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-2px);
}

/* Work overlay */
.work-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: var(--transition);
}

.work-card:hover .work-overlay {
    opacity: 1;
}

.work-actions {
    display: flex;
    gap: 1rem;
}

.work-link {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: var(--primary-color);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    text-decoration: none;
}

.work-link:hover {
    background: var(--primary-dark);
    transform: translateY(-5px) scale(1.1);
}

/* Work content */
.work-content {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.work-content h3 {
    margin-bottom: 0.5rem;
    color: var(--primary-color);
}

.work-content p {
    flex-grow: 1;
    margin-bottom: 1rem;
    color: var(--text-light);
    line-height: 1.6;
}

.work-tech {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-top: auto;
}

.tech-tag {
    background: var(--bg-color);
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    border: 1px solid var(--border-color);
    color: var(--text-color);
    transition: var(--transition);
}

.tech-tag:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-2px);
}

/* Contact section */
.contact-content {
    max-width: 800px;
    margin: 0 auto;
}

.contact-form {
    width: 100%;
    background: var(--card-bg);
    padding: 3rem;
    border-radius: 20px;
    box-shadow: var(--shadow);
    transition: var(--transition);
    border: 1px solid var(--border-color);
}

.contact-form:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.form-group {
    margin-bottom: 2rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 1.2rem;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    background: var(--bg-color);
    color: var(--text-color);
    transition: var(--transition);
    font-family: inherit;
    font-size: 1.1rem;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(147, 112, 219, 0.2);
    transform: translateY(-2px);
}

.form-group textarea {
    resize: vertical;
    min-height: 150px;
}

/* Form messages */
.form-message {
    margin-top: 1.5rem;
    padding: 1.2rem;
    border-radius: 12px;
    text-align: center;
    font-weight: 500;
    display: none;
    transition: var(--transition);
}

.form-message.success {
    background: var(--success-color);
    color: white;
    display: block;
}

.form-message.error {
    background: var(--error-color);
    color: white;
    display: block;
}

.form-message.cooldown {
    background: var(--warning-color);
    color: white;
    display: block;
}

.form-message.cooldown #cooldownTime {
    font-weight: bold;
    font-size: 1.1rem;
}

/* Icons */
.btn i {
    transition: transform 0.3s ease;
}

.btn:hover i {
    transform: translateX(4px);
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
}

.modal-content {
    background-color: var(--bg-color);
    margin: 10% auto;
    padding: 0;
    border-radius: 20px;
    width: 90%;
    max-width: 500px;
    box-shadow: var(--shadow-lg);
    animation: modalSlideIn 0.3s ease-out;
    border: 1px solid var(--border-color);
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 2rem;
    border-bottom: 1px solid var(--border-color);
}

.modal-header h3 {
    color: var(--primary-color);
    margin: 0;
}

.modal-close {
    background: none;
    border: none;
    font-size: 2rem;
    cursor: pointer;
    color: var(--text-color);
    transition: var(--transition);
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover {
    color: var(--primary-color);
    transform: scale(1.1);
}

.modal-body {
    padding: 2rem;
}

.modal-body p {
    margin-bottom: 1rem;
    text-align: center;
    color: var(--text-color);
}

.cooldown-info {
    background: var(--card-bg);
    padding: 1rem;
    border-radius: 10px;
    margin-top: 1rem;
    text-align: center;
    border: 1px solid var(--border-color);
}

.cooldown-info p {
    margin: 0;
    font-size: 0.9rem;
    color: var(--text-light);
}

#cooldownTimer {
    font-weight: bold;
    color: var(--primary-color);
    font-size: 1.1rem;
}

.modal-footer {
    padding: 1.5rem 2rem;
    border-top: 1px solid var(--border-color);
    text-align: right;
}

/* Подвал */
.footer {
    background: var(--footer-bg);
    padding: 3rem 0 1rem;
    position: relative;
    border-top: 1px solid var(--border-color);
}

.footer-main {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 3rem;
    margin-bottom: 2rem;
}

.footer-brand h3 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
    font-size: 1.5rem;
}

.footer-brand p {
    margin-bottom: 0.5rem;
    color: var(--text-light);
}

.footer-tagline {
    font-style: italic;
    opacity: 0.8;
    font-size: 0.9rem;
}

.footer-links {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.footer-column h4 {
    color: var(--text-color);
    margin-bottom: 1rem;
    font-size: 1.1rem;
    position: relative;
    text-align: left;
    display: inline-block;
}

.footer-column h4::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--primary-color);
}

.footer-column ul {
    list-style: none;
}

.footer-column li {
    margin-bottom: 0.5rem;
}

.footer-column a {
    color: var(--text-light);
    text-decoration: none;
    transition: var(--transition);
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.footer-column a:hover {
    color: var(--primary-color);
    transform: translateX(5px);
}

.contact-link {
    padding: 0.3rem 0;
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
}

.footer-copyright p {
    margin-bottom: 0.3rem;
    color: var(--text-light);
    font-size: 0.9rem;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-20px);
    }
}

.animate-fade-in {
    animation: fadeIn 1s ease-out;
}

.animate-fade-in-delay {
    animation: fadeIn 1s ease-out 0.3s both;
}

.animate-fade-in-delay-2 {
    animation: fadeIn 1s ease-out 0.6s both;
}

.animate-float {
    animation: float 3s ease-in-out infinite;
}

/* Responsive design */
@media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }

    .global-floating-elements {
        display: block !important;
    }
    
    .floating-element {
        font-size: 1.2rem;
        opacity: 0.3;
    }
    
    /* Перераспределяем элементы для мобильных */
    .element-1 { top: 5%; left: 5%; }
    .element-2 { top: 8%; right: 5%; }
    .element-3 { top: 15%; left: 10%; }
    .element-4 { top: 20%; right: 8%; }
    .element-5 { top: 30%; left: 5%; }
    .element-6 { top: 35%; right: 5%; }
    .element-7 { top: 45%; left: 8%; }
    .element-8 { top: 50%; right: 10%; }
    .element-9 { top: 60%; left: 5%; }
    .element-10 { top: 65%; right: 5%; }
    .element-11 { top: 75%; left: 10%; }
    .element-12 { top: 80%; right: 8%; }

    .nav {
        display: none;
    }

    .mobile-menu-btn {
        display: flex;
    }

    .nav.active {
        display: flex !important;
        position: fixed;
        top: 70px;
        left: 0;
        width: 100%;
        background: var(--header-bg);
        backdrop-filter: blur(20px);
        flex-direction: column;
        padding: 2rem;
        box-shadow: var(--shadow-lg);
        border-bottom: 1px solid var(--border-color);
    }

    .nav.active .nav-list {
        flex-direction: column;
        gap: 1rem;
    }

    .mobile-menu-btn.active span:nth-child(1) {
        transform: rotate(45deg) translate(6px, 6px);
    }

    .mobile-menu-btn.active span:nth-child(2) {
        opacity: 0;
    }

    .mobile-menu-btn.active span:nth-child(3) {
        transform: rotate(-45deg) translate(6px, -6px);
    }

    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 2rem;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .hero-subtitle {
        font-size: 1.3rem;
    }

    .hero-buttons {
        justify-content: center;
    }

    .avatar {
        width: 250px;
        height: 250px;
    }

    .avatar-glow {
        width: 280px;
        height: 280px;
    }

    .ring-1 {
        width: 290px;
        height: 290px;
    }
    
    .ring-2 {
        width: 330px;
        height: 330px;
    }
    
    .ring-3 {
        width: 370px;
        height: 370px;
    }

    .hero-stats {
        justify-content: center;
    }
    
    .contact-content {
        padding: 0 10px;
    }
    
    .contact-form {
        padding: 2rem;
    }
    
    .skills-container {
        grid-template-columns: 1fr;
    }
    
    .skills-section {
        margin: 20px;
        padding: 40px 20px;
    }
    
    .skill-category {
        padding: 1.5rem;
    }
    
    .works-filter {
        gap: 0.5rem;
    }
    
    .filter-btn {
        padding: 0.4rem 1rem;
        font-size: 0.8rem;
    }

    .scroll-to-top {
        bottom: 20px;
        right: 20px;
        width: 45px;
        height: 45px;
        font-size: 1.3rem;
    }
    
    .stat {
        min-width: 100px;
        padding: 1rem 0.8rem;
    }
    
    .stat-number {
        font-size: 1.5rem;
    }
    
    .footer-main {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .footer-links {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .footer-bottom {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    .footer-brand {
        text-align: center;
    }
    
    .footer-column {
        text-align: center;
    }
    
    .footer-column h4::after {
        left: 50%;
        transform: translateX(-50%);
    }
    
    .footer-column a {
        justify-content: center;
    }

    .works-grid {
        grid-template-columns: 1fr;
    }
    
    .work-card {
        min-height: 400px;
    }

    .modal-content {
        margin: 20% auto;
        width: 95%;
    }
    
    .modal-header,
    .modal-body,
    .modal-footer {
        padding: 1rem 1.5rem;
    }

    /* Мобильный аватар */
    .mobile-avatar {
        display: flex;
    }
    
    .hero-image {
        display: none;
    }
    
    .about-text p {
        text-align: left;
    }
    
    .hero-floating-elements .floating-hero-element {
        font-size: 1.8rem;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 2rem;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }

    .btn {
        width: 200px;
    }

    .section-title {
        font-size: 2rem;
    }

    .hero-stats {
        flex-direction: column;
        gap: 1rem;
    }
    
    .stat-number {
        font-size: 1.5rem;
    }
    
    .contact-form {
        padding: 1.5rem;
    }
    
    .form-group {
        margin-bottom: 1.5rem;
    }
    
    .form-group input,
    .form-group textarea {
        padding: 1rem;
        font-size: 1rem;
    }
    
    .scroll-to-top {
        bottom: 15px;
        right: 15px;
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
    }
    
    .timeline-item {
        padding: 1rem;
    }

    .avatar {
        width: 200px;
        height: 200px;
    }

    .avatar-glow {
        width: 240px;
        height: 240px;
    }

    .ring-1 {
        width: 240px;
        height: 240px;
    }
    
    .ring-2 {
        width: 280px;
        height: 280px;
    }
    
    .ring-3 {
        width: 320px;
        height: 320px;
    }

    /* Мобильный аватар размеры */
    .mobile-avatar .avatar {
        width: 150px;
        height: 150px;
    }
    
    .mobile-avatar .avatar-glow {
        width: 180px;
        height: 180px;
    }
    
    .mobile-avatar .avatar-placeholder {
        font-family: 'Virgo', sans-serif;
        font-size: 3rem;
    }
    
    .mobile-avatar .ring-1 {
        width: 170px;
        height: 170px;
    }
    
    .mobile-avatar .ring-2 {
        width: 190px;
        height: 190px;
    }
    
    .mobile-avatar .ring-3 {
        width: 210px;
        height: 210px;
    }
    
    .footer {
        padding: 1.5rem 0 1rem;
    }
    
    .footer-main {
        gap: 1.5rem;
    }
    
    .footer-links {
        gap: 1rem;
    }
    
    .floating-element {
        font-size: 1rem;
    }
}