@import url('https://fonts.googleapis.com/css2?family=Montserrat:ital,wght@0,100..900;1,100..900&display=swap');

#bg-video {
    position: fixed;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    z-index: -2;
    transform: translateX(-50%) translateY(-50%);
    filter: brightness(30%) blur(8px);
    object-fit: cover;
}

body {
    font-family: "Montserrat", sans-serif;
    font-optical-sizing: auto;
    background-color: #212121;
    color: white;

    background-color: #2c2c2c;
    /*background-image: url("data:image/svg+xml,%3Csvg width='64' height='64' viewBox='0 0 64 64' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M8 16c4.418 0 8-3.582 8-8s-3.582-8-8-8-8 3.582-8 8 3.582 8 8 8zm0-2c3.314 0 6-2.686 6-6s-2.686-6-6-6-6 2.686-6 6 2.686 6 6 6zm33.414-6l5.95-5.95L45.95.636 40 6.586 34.05.636 32.636 2.05 38.586 8l-5.95 5.95 1.414 1.414L40 9.414l5.95 5.95 1.414-1.414L41.414 8zM40 48c4.418 0 8-3.582 8-8s-3.582-8-8-8-8 3.582-8 8 3.582 8 8 8zm0-2c3.314 0 6-2.686 6-6s-2.686-6-6-6-6 2.686-6 6 2.686 6 6 6zM9.414 40l5.95-5.95-1.414-1.414L8 38.586l-5.95-5.95L.636 34.05 6.586 40l-5.95 5.95 1.414 1.414L8 41.414l5.95 5.95 1.414-1.414L9.414 40z' fill='%23717171' fill-opacity='0.65' fill-rule='evenodd'/%3E%3C/svg%3E");*/
}
body::before {
    content: " ";
    display: block;
    position: fixed;
    top: 0; left: 0; bottom: 0; right: 0;
    background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.1) 50%), 
                linear-gradient(90deg, rgba(255, 0, 0, 0.03), rgba(0, 255, 0, 0.01), rgba(0, 0, 255, 0.03));
    z-index: 9999;
    background-size: 100% 4px, 3px 100%;
    pointer-events: none;
}
body::after {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 9998;

    background: radial-gradient(
        ellipse at center,
        rgba(0, 0, 0, 0) 40%,
        rgba(0, 0, 0, 0.7) 100%
    );

    transform: scale(1);
}
body {
    cursor: url('https://thatmaidguy.ru/img/pointer.png'), auto !important;
}
a, button, .button {
    cursor: url('https://thatmaidguy.ru/img/link.png'), pointer !important;
}


/* Бешеное вращение аватарки */
@keyframes mega-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Тряска экрана */
@keyframes screen-shake {
    0% { transform: translate(0, 0); }
    10% { transform: translate(-12px, -12px); }
    20% { transform: translate(12px, -11px); }
    30% { transform: translate(-13px, 11px); }
    40% { transform: translate(13px, 12px); }
    50% { transform: translate(-11px, -11px); }
    60% { transform: translate(-13px, 11px); }
    70% { transform: translate(12px, 11px); }
    80% { transform: translate(-11px, -12px); }
    90% { transform: translate(13px, 12px); }
    100% { transform: translate(0, 0); }
}

/* Применяем эффекты, когда активен радужный режим */
.rainbow-mode #avatar {
    animation: mega-spin 0.5s linear infinite !important;
}

.rainbow-mode .content {
    animation: screen-shake 0.2s infinite !important;
    backdrop-filter: blur(5px); 
}

/* Анимация перелива (из прошлого шага) */
@keyframes rainbow-cycle {
    0% { filter: hue-rotate(0deg); }
    100% { filter: hue-rotate(360deg); }
}

.rainbow-mode {
    animation: rainbow-cycle 1s linear infinite !important;
}
.rainbow-mode .button {
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.5);
    border-color: #fff;
}

#avatar {
    transition: transform 0.1s ease;
    will-change: transform;
}

#username {
    position: relative;
    display: inline-block; /* Важно для позиционирования слоев */
}

#username:hover {
    animation: main-glitch 0.2s infinite;
}

#username:hover::before,
#username:hover::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: transparent;
}

#username:hover::before {
    left: 2px;
    text-shadow: -2px 0 #ff00c1;
    clip-path: polygon(0 0, 100% 0, 100% 45%, 0 45%);
    animation: glitch-anim-1 0.5s infinite linear alternate-reverse;
}

#username:hover::after {
    left: -2px;
    text-shadow: -2px 0 #00fff9;
    clip-path: polygon(0 80%, 100% 20%, 100% 100%, 0 100%);
    animation: glitch-anim-2 0.3s infinite linear alternate-reverse;
}

/* Анимации прыжков */
@keyframes main-glitch {
    0% { transform: translate(0); }
    20% { transform: translate(-1px, 1px); }
    40% { transform: translate(-1px, -1px); }
    60% { transform: translate(1px, 1px); }
    80% { transform: translate(1px, -1px); }
    100% { transform: translate(0); }
}

@keyframes glitch-anim-1 {
    0% { clip-path: inset(20% 0 30% 0); }
    20% { clip-path: inset(60% 0 10% 0); }
    40% { clip-path: inset(40% 0 50% 0); }
    60% { clip-path: inset(80% 0 5% 0); }
    80% { clip-path: inset(10% 0 70% 0); }
    100% { clip-path: inset(30% 0 20% 0); }
}

@keyframes glitch-anim-2 {
    0% { clip-path: inset(15% 0 15% 0); }
    20% { clip-path: inset(5% 0 85% 0); }
    40% { clip-path: inset(75% 0 5% 0); }
    60% { clip-path: inset(35% 0 35% 0); }
    80% { clip-path: inset(85% 0 5% 0); }
    100% { clip-path: inset(15% 0 15% 0); }
}

.content {
    text-align: center;
    max-width: 480px;
    margin: 24px auto;

    background-color: rgba(0, 0, 0, 0.75);
    border-radius: 16px;
    border-style: solid;
    border-color: white;
    border-width: 2px;
    padding: 12px 48px 32px 48px;

    backdrop-filter: blur(5px)
}

.block {
    margin-top: 24px;
}
.block-title {
    font-size: 1.2rem;
    margin-bottom: 15px;
    margin-top: 10px;
    display: block;
    text-align: left;
    border-left: 3px solid #8F0177;
    padding-left: 10px;
}

.small-info {
    border-collapse: collapse;
    width: 100%;
    margin: 0px auto;
}
.small-info td {
    vertical-align: top;
    padding-bottom: 10px; 
}
td.q {
    text-align: left;
    font-weight: bold;
    padding-right: 20px;
}
td.a {
    text-align: right;
}
.small-info tr:last-child td {
    padding-bottom: 0;
}


.tech-stack {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
    margin-top: 16px;
}
.badge {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    padding: 4px 10px;
    font-size: 12px;
    font-weight: 600;
    transition: all 0.3s ease;
    cursor: default;
}
.badge:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: #8F0177; /* Твой основной цвет */
    transform: translateY(-2px);
    cursor: url('img/link.png'), pointer;
}


.social-icons img {
    margin-left: 4px;
    margin-right: 4px;
    transition: all 0.3s ease;
}
.social-icons img:hover {
    transform: scale(1.2);
}
.social-icons img:active {
    transform: scale(1);
}

.fading-hr {
    border: none;
    height: 2px;
    background: linear-gradient(
        to right,
        rgba(1, 1, 1, 0),
        #ffffff,
        rgba(1, 1, 1, 0)
    );
    margin: 2rem 0;
}

.button {
    display: block;
    background-color: #121212;
    border: 3px solid #8F0177;
    border-radius: 0;
    padding: 14px;
    color: #e0e0e0;
    font-weight: bold;
    font-family: "Montserrat", sans-serif;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 12px;
    margin-top: 12px;
    text-decoration: none;
    cursor: url('img/cursor-hover.png'), pointer;
    position: relative;
    top: 0;
    left: 0;

    transition: all 0.15s ease-out;

    box-shadow: 0 4px 0 rgba(143, 1, 119, 0.4);
}
.button:hover {
    background-color: #8F0177;
    color: white;
    border-color: white;
    box-shadow: 0 6px 0 rgba(255, 255, 255, 0.3);
    text-shadow: 0 0 8px rgba(255, 255, 255, 0.8);
    transform: translateY(-2px);
}
.button:active {
    background-color: #6B0159; 
    box-shadow: 0 0 0 rgba(143, 1, 119, 0);
    top: 4px;
    left: 2px;
    transition: all 0.05s ease-in;
}

.footer {
    margin-top: 32px;
    opacity: 0.8;
}

.footer-content {
    text-align: center;
    font-size: 13px;
}

.footer-line {
    margin-top: 6px;
}

.footer-line.small {
    font-size: 12px;
    opacity: 0.7;
}

.footer-line.tiny {
    font-size: 11px;
    opacity: 0.5;
    letter-spacing: 1px;
}