* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    background: #0b0b12;
    color: #e8e8f0;
    line-height: 1.6;
    min-height: 100vh;
    transition: background 0.4s ease, color 0.4s ease;
    overflow-x: hidden;
}

/* Шум */
.noise {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    opacity: 0.03;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
    background-repeat: repeat;
}

/* Particles */
#particles-js {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1.5rem;
    position: relative;
    z-index: 1;
}

/* Шапка */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0 1.5rem;
    flex-wrap: wrap;
    gap: 1rem;
    border-bottom: 1px solid rgba(168, 85, 247, 0.15);
    margin-bottom: 1rem;
    backdrop-filter: blur(10px);
    background: rgba(11, 11, 18, 0.3);
    border-radius: 16px;
    padding: 0.5rem 1.5rem;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.6rem;
    font-weight: 800;
    background: linear-gradient(135deg, #c084fc, #60a5fa);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    letter-spacing: -0.02em;
}

.logo-icon {
    font-size: 2rem;
    color: #a855f7;
    background: none;
    -webkit-background-clip: unset;
    background-clip: unset;
}

.nav {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.nav-link {
    color: rgba(255, 255, 255, 0.5);
    text-decoration: none;
    font-weight: 500;
    padding: 0.5rem 1.2rem;
    border-radius: 100px;
    transition: all 0.25s ease;
    font-size: 0.95rem;
}

.nav-link:hover,
.nav-link.active {
    color: #fff;
    background: rgba(168, 85, 247, 0.15);
}

.theme-toggle {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(168, 85, 247, 0.2);
    border-radius: 50%;
    width: 42px;
    height: 42px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
    font-size: 1.2rem;
    color: #e8e8f0;
}

.theme-toggle:hover {
    background: rgba(168, 85, 247, 0.2);
    border-color: #a855f7;
    transform: rotate(15deg);
}

/* About */
.about-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0.5rem 0;
}

.about-photo-block {
    text-align: center;
    margin: 2rem 0 3rem;
    opacity: 0;
    animation: fadeInUp 0.8s ease forwards;
}

.photo-frame {
    width: 200px;
    height: 200px;
    margin: 0 auto;
    border-radius: 50%;
    padding: 4px;
    background: linear-gradient(135deg, #a855f7, #3b82f6, #a855f7);
    background-size: 300% 300%;
    animation: gradSpin 4s ease-in-out infinite alternate, glowPulse 3s ease-in-out infinite;
    transition: transform 0.3s;
    box-shadow: 0 0 80px rgba(168, 85, 247, 0.2);
}

.photo-frame:hover {
    transform: scale(1.05);
}

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

@keyframes glowPulse {
    0%, 100% { box-shadow: 0 0 40px rgba(168, 85, 247, 0.15); }
    50% { box-shadow: 0 0 80px rgba(168, 85, 247, 0.3); }
}

.about-photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
    display: block;
}

.about-name {
    font-size: 2.8rem;
    font-weight: 900;
    margin: 1.2rem 0 0.25rem;
    background: linear-gradient(135deg, #c084fc, #60a5fa);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    letter-spacing: -0.03em;
    animation: fadeInUp 0.8s ease 0.2s forwards;
    opacity: 0;
}

.about-tagline {
    color: rgba(255, 255, 255, 0.5);
    font-size: 1.1rem;
    font-weight: 400;
    animation: fadeInUp 0.8s ease 0.4s forwards;
    opacity: 0;
}

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Humor */
.humor-block {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(168, 85, 247, 0.12);
    border-radius: 1.5rem;
    padding: 1.8rem 2rem;
    margin: 2rem 0;
    transition: all 0.3s;
    opacity: 0;
    animation: fadeInUp 0.8s ease 0.6s forwards;
}

.humor-block:hover {
    border-color: rgba(168, 85, 247, 0.3);
    box-shadow: 0 0 40px rgba(168, 85, 247, 0.05);
}

.humor-block p {
    margin: 0.5rem 0;
    color: rgba(255, 255, 255, 0.7);
    font-style: italic;
    font-size: 1.05rem;
}

.humor-block p:first-child {
    font-style: normal;
    font-weight: 600;
    color: #c084fc;
    font-size: 1.1rem;
}

/* Lang */
.lang-section {
    margin: 3rem 0;
    opacity: 0;
    animation: fadeInUp 0.8s ease 0.8s forwards;
}

.section-title {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: #c084fc;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.lang-table {
    width: 100%;
    border-collapse: collapse;
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(12px);
    border-radius: 1.5rem;
    overflow: hidden;
    border: 1px solid rgba(168, 85, 247, 0.08);
}

.lang-table th,
.lang-table td {
    padding: 1rem 1.5rem;
    text-align: left;
    border-bottom: 1px solid rgba(168, 85, 247, 0.06);
}

.lang-table th {
    background: rgba(168, 85, 247, 0.08);
    color: #c084fc;
    font-weight: 600;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.lang-table td:first-child {
    font-weight: 600;
    color: #e8e8f0;
}

.lang-table tr:last-child td {
    border-bottom: none;
}

.level {
    display: inline-block;
    padding: 0.25rem 1rem;
    border-radius: 100px;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.level-c2 { background: rgba(52, 211, 153, 0.15); color: #34d399; }
.level-b2 { background: rgba(96, 165, 250, 0.15); color: #60a5fa; }
.level-b1 { background: rgba(251, 191, 36, 0.15); color: #fbbf24; }
.level-a2 { background: rgba(248, 113, 113, 0.15); color: #f87171; }

.lang-table td:last-child {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.95rem;
}

/* Hobby */
.hobby-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin: 2.5rem 0;
    opacity: 0;
    animation: fadeInUp 0.8s ease 1s forwards;
}

.hobby-card {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(12px);
    border-radius: 1.5rem;
    padding: 1.8rem 1.5rem;
    text-align: center;
    border: 1px solid rgba(168, 85, 247, 0.08);
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    cursor: default;
}

.hobby-card:hover {
    transform: translateY(-8px) scale(1.02);
    border-color: rgba(168, 85, 247, 0.3);
    box-shadow: 0 20px 40px -12px rgba(0, 0, 0, 0.4);
    background: rgba(255, 255, 255, 0.06);
}

.hobby-emoji {
    font-size: 2.8rem;
    margin-bottom: 0.75rem;
    display: block;
}

.hobby-card h3 {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #c084fc;
}

.hobby-card p {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.5);
}

/* Contacts */
.contacts-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 1rem 0;
}

.contacts-header {
    text-align: center;
    margin-bottom: 3rem;
    opacity: 0;
    animation: fadeInUp 0.8s ease forwards;
}

.contacts-header h1 {
    font-size: 2.8rem;
    font-weight: 900;
    background: linear-gradient(135deg, #c084fc, #60a5fa);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    letter-spacing: -0.03em;
}

.contacts-header p {
    color: rgba(255, 255, 255, 0.5);
    font-size: 1.1rem;
}

.contacts-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin: 2rem 0;
    opacity: 0;
    animation: fadeInUp 0.8s ease 0.2s forwards;
}

.contact-card {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(12px);
    border-radius: 2rem;
    padding: 2.5rem 1.5rem;
    text-align: center;
    border: 1px solid rgba(168, 85, 247, 0.08);
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    text-decoration: none;
    color: inherit;
    display: block;
}

.contact-card:hover {
    transform: translateY(-8px) scale(1.02);
    border-color: rgba(168, 85, 247, 0.3);
    box-shadow: 0 20px 40px -12px rgba(0, 0, 0, 0.4);
    background: rgba(255, 255, 255, 0.06);
}

.contact-icon {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    display: block;
}

.contact-title {
    font-size: 1.6rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: #c084fc;
}

.contact-value {
    font-size: 1rem;
    color: #e8e8f0;
    font-weight: 500;
}

.contact-note {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.4);
    margin-top: 0.75rem;
}

/* Footer */
.footer {
    margin-top: 4rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(168, 85, 247, 0.08);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.3);
    opacity: 0;
    animation: fadeInUp 0.8s ease 1.2s forwards;
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-link {
    color: rgba(255, 255, 255, 0.4);
    text-decoration: none;
    transition: all 0.25s ease;
    font-weight: 500;
    padding: 0.3rem 0.8rem;
    border-radius: 100px;
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.social-link:hover {
    color: #fff;
    border-color: rgba(168, 85, 247, 0.3);
    background: rgba(168, 85, 247, 0.08);
}

/* Light theme */
body.light-theme {
    background: #f5f0ff;
    color: #1a1a2e;
}

body.light-theme .header {
    background: rgba(245, 240, 255, 0.6);
}

body.light-theme .nav-link {
    color: rgba(0, 0, 0, 0.4);
}

body.light-theme .nav-link:hover,
body.light-theme .nav-link.active {
    color: #1a1a2e;
    background: rgba(168, 85, 247, 0.08);
}

body.light-theme .theme-toggle {
    background: rgba(0, 0, 0, 0.03);
    border-color: rgba(168, 85, 247, 0.15);
    color: #1a1a2e;
}

body.light-theme .about-tagline {
    color: rgba(0, 0, 0, 0.4);
}

body.light-theme .humor-block {
    background: rgba(255, 255, 255, 0.6);
    border-color: rgba(168, 85, 247, 0.15);
}

body.light-theme .humor-block p {
    color: rgba(0, 0, 0, 0.6);
}

body.light-theme .lang-table {
    background: rgba(255, 255, 255, 0.6);
    border-color: rgba(168, 85, 247, 0.1);
}

body.light-theme .lang-table th {
    background: rgba(168, 85, 247, 0.06);
}

body.light-theme .lang-table td:first-child {
    color: #1a1a2e;
}

body.light-theme .lang-table td:last-child {
    color: rgba(0, 0, 0, 0.5);
}

body.light-theme .hobby-card {
    background: rgba(255, 255, 255, 0.6);
    border-color: rgba(168, 85, 247, 0.1);
}

body.light-theme .hobby-card p {
    color: rgba(0, 0, 0, 0.5);
}

body.light-theme .contact-card {
    background: rgba(255, 255, 255, 0.6);
    border-color: rgba(168, 85, 247, 0.1);
}

body.light-theme .contact-value {
    color: #1a1a2e;
}

body.light-theme .contact-note {
    color: rgba(0, 0, 0, 0.4);
}

body.light-theme .footer {
    border-top-color: rgba(168, 85, 247, 0.08);
    color: rgba(0, 0, 0, 0.3);
}

body.light-theme .social-link {
    color: rgba(0, 0, 0, 0.3);
    border-color: rgba(0, 0, 0, 0.06);
}

body.light-theme .social-link:hover {
    color: #1a1a2e;
    border-color: rgba(168, 85, 247, 0.2);
    background: rgba(168, 85, 247, 0.05);
}

/* Adaptive */
@media (max-width: 768px) {
    .container {
        padding: 1rem;
    }

    .header {
        flex-direction: column;
        text-align: center;
    }

    .nav {
        justify-content: center;
        gap: 0.25rem;
    }

    .about-name {
        font-size: 2rem;
    }

    .photo-frame {
        width: 160px;
        height: 160px;
    }

    .contacts-grid,
    .hobby-grid {
        grid-template-columns: 1fr;
    }

    .lang-table {
        font-size: 0.85rem;
    }

    .lang-table th,
    .lang-table td {
        padding: 0.75rem 1rem;
    }

    .footer {
        flex-direction: column;
        text-align: center;
    }
}
