
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700&family=Press+Start+2P&display=swap');

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    --red: #fa3030;
    --dark-red: #a50000;
    --background: #080808;
    --card-background: rgba(10, 10, 10, 0.88);
    --text: #ffffff;
    --pixel-font: 'Press Start 2P', monospace;
}

html {
    min-height: 100%;
    background: var(--background);
}

body {
    min-height: 100vh;
    color: var(--text);
    font-family: 'Poppins', sans-serif;
    overflow-x: hidden;
    cursor: none;
    background:
        linear-gradient(rgba(0, 0, 0, 0.72), rgba(0, 0, 0, 0.88)),
        url("https://rare-gallery.com/mocahbig/481356-Chihuri-45-city-building-looking-at-viewer-Russia.jpg")
        center / cover fixed no-repeat;
}

#intro {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 24px;
    padding: 24px;
    background: #000;
    text-align: center;
    cursor: none;
    transition: opacity 0.8s ease, visibility 0.8s ease;
}

#intro.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.intro-text {
    color: var(--red);
    font-family: var(--pixel-font);
    font-size: clamp(16px, 3vw, 30px);
    line-height: 1.8;
    text-shadow: 0 0 18px rgba(250, 48, 48, 0.7);
}

.intro-subtext {
    color: #ccc;
    font-size: 14px;
    animation: pulse 1.5s infinite;
}

.site-content {
    display: none;
    min-height: 100vh;
    padding: 40px 24px 60px;
}

.site-content.show {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.site-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    margin-bottom: 48px;
    text-align: center;
}

.site-header h1 {
    color: var(--red);
    font-family: var(--pixel-font);
    font-size: clamp(13px, 2.4vw, 23px);
    font-weight: 400;
    line-height: 1.9;
    text-shadow: 0 0 18px rgba(250, 48, 48, 0.45);
    overflow-wrap: anywhere;
}

.view-counter {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 9px;
    color: #ddd;
    font-family: var(--pixel-font);
    font-size: 9px;
    line-height: 1.8;
}

.view-counter i {
    color: var(--red);
}

#viewCount {
    color: var(--red);
    font-weight: 400;
    overflow-wrap: anywhere;
}

.profile-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: flex-start;
    gap: 32px;
    width: 100%;
    max-width: 1000px;
}

.flip-card {
    width: min(100%, 360px);
    height: 440px;
    perspective: 1200px;
    cursor: none;
    outline: none;
}

.flip-card:focus-visible .flip-card-inner {
    outline: 2px solid var(--red);
    outline-offset: 5px;
}

.flip-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transform-style: preserve-3d;
    transition: transform 0.7s ease;
}

.flip-card.flipped .flip-card-inner {
    transform: rotateY(180deg);
}

.flip-card-front,
.flip-card-back {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 28px;
    border: 1px solid rgba(250, 48, 48, 0.65);
    border-radius: 16px;
    background: var(--card-background);
    box-shadow: 0 0 24px rgba(250, 48, 48, 0.1);
    text-align: center;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--red) #111;
}

.flip-card-front {
    gap: 16px;
}

.flip-card-back {
    align-items: flex-start;
    justify-content: flex-start;
    gap: 10px;
    transform: rotateY(180deg);
    text-align: left;
}

.profile-avatar {
    width: 132px;
    height: 132px;
    flex-shrink: 0;
    border: 3px solid var(--red);
    border-radius: 50%;
    object-fit: cover;
    box-shadow: 0 0 24px rgba(250, 48, 48, 0.3);
}

.flip-card-front h2,
.flip-card-back h2 {
    color: var(--red);
    font-family: var(--pixel-font);
    font-size: clamp(12px, 1.8vw, 16px);
    font-weight: 400;
    line-height: 1.9;
    overflow-wrap: anywhere;
}

.profile-status {
    color: #ccc;
    font-size: 13px;
    line-height: 1.8;
    overflow-wrap: anywhere;
}

.flip-hint {
    margin-top: 12px;
    color: #888;
    font-size: 12px;
}

.flip-card-back h2 {
    width: 100%;
    margin-bottom: 8px;
}

.flip-card-back p {
    width: 100%;
    color: #ddd;
    font-size: 13px;
    line-height: 1.7;
    overflow-wrap: anywhere;
}

.sparkle {
    position: fixed;
    z-index: 2000;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--red);
    box-shadow: 0 0 10px var(--red);
    pointer-events: none;
    animation: sparkle-fade 0.8s forwards;
}

#customCursor {
    position: fixed;
    z-index: 3000;
    top: 0;
    left: 0;
    width: 22px;
    height: 22px;
    pointer-events: none;
    transform: translate(-50%, -50%);
}

.cursor-horizontal,
.cursor-vertical,
.cursor-dot {
    position: absolute;
    display: block;
    background: var(--red);
    box-shadow: 0 0 5px rgba(250, 48, 48, 0.8);
}

.cursor-horizontal {
    top: 10px;
    left: 0;
    width: 22px;
    height: 1px;
}

.cursor-vertical {
    top: 0;
    left: 10px;
    width: 1px;
    height: 22px;
}

.cursor-dot {
    top: 9px;
    left: 9px;
    width: 3px;
    height: 3px;
    border-radius: 50%;
}

@keyframes pulse {
    0%, 100% {
        opacity: 0.45;
    }
    50% {
        opacity: 1;
    }
}

@keyframes sparkle-fade {
    0% {
        opacity: 1;
        transform: scale(1);
    }
    100% {
        opacity: 0;
        transform: scale(0);
    }
}

@media (max-width: 600px) {
    .site-content {
        padding: 30px 16px 40px;
    }

    .site-header {
        margin-bottom: 32px;
    }

    .site-header h1 {
        font-size: clamp(11px, 3vw, 17px);
    }

    .view-counter {
        font-size: 8px;
    }

    .profile-container {
        gap: 24px;
    }

    .flip-card {
        height: 420px;
    }

    .flip-card-back {
        padding: 22px;
    }
}

@media (pointer: coarse) {
    body,
    #intro,
    .flip-card {
        cursor: auto;
    }

    #customCursor {
        display: none;
    }
}
