:root {
    --bg: #F5F0E8;
    --card-bg: #FEFCF8;
    --text: #2D2820;
    --text-dark: #1A1510;
    --accent: #A0714F;
    --accent-muted: rgba(160, 113, 79, 0.1);
    --muted: #9E8E7E;
    --subtitle: #7A6A5A;
    --border: #E8E0D4;
    --tag-bg: #F0EAE0;
    --tag-text: #5A4A3A;
    --shadow: 0 2px 8px rgba(0, 0, 0, 0.05), 0 20px 48px rgba(0, 0, 0, 0.08);
}

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

body {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--bg);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    color: var(--text);
    padding: 2rem 1rem;
}

body::before,
body::after {
    content: '';
    position: fixed;
    inset: -50%;
    width: 200%;
    height: 200%;
    pointer-events: none;
    z-index: 0;
}

body::before {
    background:
        radial-gradient(ellipse 60% 50% at 20% 20%, rgba(160, 113, 79, 0.14) 0%, transparent 60%),
        radial-gradient(ellipse 50% 40% at 75% 75%, rgba(200, 160, 120, 0.12) 0%, transparent 60%);
    animation: drift-a 40s ease-in-out infinite alternate;
}

body::after {
    background:
        radial-gradient(ellipse 45% 40% at 70% 15%, rgba(220, 195, 160, 0.18) 0%, transparent 55%);
    animation: drift-b 55s ease-in-out infinite alternate;
}

@keyframes drift-a {
    0%   { transform: translate(0, 0) rotate(0deg); }
    33%  { transform: translate(3%, 4%) rotate(3deg); }
    66%  { transform: translate(-2%, 3%) rotate(-2deg); }
    100% { transform: translate(4%, -3%) rotate(2deg); }
}

@keyframes drift-b {
    0%   { transform: translate(0, 0) rotate(0deg); }
    40%  { transform: translate(-4%, 2%) rotate(-3deg); }
    80%  { transform: translate(3%, -4%) rotate(2deg); }
    100% { transform: translate(-2%, 3%) rotate(-1deg); }
}

.card {
    position: relative;
    z-index: 1;
    background: var(--card-bg);
    border-radius: 24px;
    box-shadow: var(--shadow);
    padding: 2.5rem 3rem;
    max-width: 460px;
    width: 100%;
    text-align: center;
}

/* Переключатель языка */
.lang-switcher {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 2rem;
}

.lang-switcher a {
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: all 0.2s ease;
    opacity: 0.35;
    filter: grayscale(60%);
    border-radius: 6px;
    padding: 2px;
}

.lang-switcher a:hover {
    opacity: 0.75;
    filter: grayscale(0%);
    transform: scale(1.1);
}

.lang-switcher a.active {
    opacity: 1;
    filter: grayscale(0%);
}

.flag-icon {
    font-size: 22px;
    line-height: 1;
}

/* Имя и должность */
.name {
    font-size: clamp(1.6rem, 5vw, 2.1rem);
    font-weight: 500;
    letter-spacing: -0.02em;
    color: var(--text-dark);
    margin-bottom: 0.4rem;
}

.title {
    font-size: 0.9rem;
    font-weight: 300;
    color: var(--subtitle);
    letter-spacing: 0.05em;
    text-transform: lowercase;
}

/* Разделитель */
.divider {
    height: 1px;
    background: var(--border);
    margin: 1.75rem 0;
}

/* Стек технологий */
.stack {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    justify-content: center;
}

.tag {
    display: inline-block;
    padding: 0.3rem 0.7rem;
    background: var(--tag-bg);
    color: var(--tag-text);
    border-radius: 8px;
    font-size: 0.78rem;
    font-weight: 500;
    border: 1px solid var(--border);
    transition: all 0.2s ease;
    user-select: none;
}

.tag:hover {
    background: var(--accent-muted);
    border-color: var(--accent);
    color: var(--accent);
    transform: translateY(-1px);
}

/* Проекты */
.section-label {
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--muted);
    margin-bottom: 0.85rem;
}

.projects {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    text-align: left;
}

.project {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    border: 1px solid var(--border);
    border-radius: 12px;
    text-decoration: none;
    color: inherit;
    transition: all 0.2s ease;
}

.project:hover {
    border-color: var(--accent);
    background: var(--accent-muted);
    transform: translateY(-1px);
}

.project-info {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    min-width: 0;
}

.project-name {
    font-size: 0.88rem;
    font-weight: 500;
    color: var(--text-dark);
}

.project-desc {
    font-size: 0.78rem;
    color: var(--muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.project-arrow {
    color: var(--muted);
    font-size: 0.8rem;
    flex-shrink: 0;
    transition: color 0.2s ease;
}

.project:hover .project-arrow {
    color: var(--accent);
}

/* Социальные ссылки */
.social-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.15rem;
    justify-content: center;
    align-items: center;
}

.social-links a {
    color: var(--muted);
    text-decoration: none;
    transition: color 0.2s ease, background 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px 12px;
    border-radius: 10px;
}

.social-links a:hover {
    color: var(--accent);
    background: var(--accent-muted);
}

.social-links i {
    font-size: 20px;
    line-height: 1;
}

/* GPG ссылка */
.gpg-link {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    margin-top: 1.25rem;
    padding: 0.45rem 1rem;
    font-size: 0.78rem;
    font-weight: 400;
    color: var(--muted);
    text-decoration: none;
    border: 1px solid var(--border);
    border-radius: 2rem;
    transition: all 0.2s ease;
}

.gpg-link:hover {
    color: var(--accent);
    border-color: var(--accent);
    background: var(--accent-muted);
}

.gpg-link i {
    font-size: 0.8rem;
}

/* Кастомный курсор */
.cursor {
    position: fixed;
    width: 20px;
    height: 20px;
    border: 2px solid var(--accent);
    border-radius: 50%;
    pointer-events: none;
    transform: translate(-50%, -50%);
    transition: width 0.2s, height 0.2s, border-color 0.2s;
    z-index: 9999;
}

.cursor-dot {
    position: fixed;
    width: 6px;
    height: 6px;
    background-color: var(--accent);
    border-radius: 50%;
    pointer-events: none;
    transform: translate(-50%, -50%);
    z-index: 9999;
}

.cursor.hover {
    width: 40px;
    height: 40px;
    border-color: rgba(217, 119, 87, 0.4);
}

@media (pointer: coarse) {
    .cursor, .cursor-dot { display: none; }
}

/* Котик */
.cat {
    position: fixed;
    bottom: -80px;
    right: 30px;
    font-size: 48px;
    transition: bottom 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
    z-index: 100;
    cursor: pointer;
}

.cat.visible { bottom: 20px; }

.cat-body { transform: scaleX(-1); }

.cat-paw {
    position: absolute;
    top: -20px;
    left: 5px;
    font-size: 24px;
    animation: wave 0.6s ease-in-out infinite;
    transform-origin: bottom center;
}

@keyframes wave {
    0%, 100% { transform: rotate(-10deg); }
    50% { transform: rotate(20deg); }
}

/* Мобильная адаптивность */
@media (max-width: 480px) {
    .card {
        padding: 2rem 1.5rem;
        border-radius: 18px;
    }

    .social-links a { padding: 8px 10px; }
    .social-links i { font-size: 18px; }
    .cat { right: 15px; font-size: 40px; }
}
