/* ==========================================
   PROFILE IMAGE STYLES
   ========================================== */

.profile-image-container {
    width: 320px;
    height: 320px;
    border-radius: 30px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 0 40px rgba(99, 102, 241, 0.4);
    animation: float 4s cubic-bezier(0.4, 0, 0.2, 1) infinite;
    border: 3px solid transparent;
    background: linear-gradient(var(--card-bg), var(--card-bg)) padding-box,
        linear-gradient(135deg, var(--primary), var(--secondary)) border-box;
}

.pixel-content {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.first-content {
    z-index: 1;
}

.second-content {
    z-index: 0;
    pointer-events: none; /* Make click pass through to the grid */
}

/* Background panel for the second content (Meow / Hi there text) */
.second-content-inner {
    width: 100%;
    height: 100%;
    display: grid;
    place-items: center;
    background-color: #111;
}

.second-content-inner p {
    font-weight: 900;
    font-size: 3rem;
    color: #ffffff;
    margin: 0;
}

.profile-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    /* transition removed because pixel animation replaces the simple scale hover */
}

/* Pixel Grid setup */
.pixel-grid-container {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: flex;
    flex-wrap: wrap; /* Grid is built with flex wrap */
    pointer-events: none; /* Clicking passes through to the image */
}

.pixel-block {
    background-color: var(--pixel-color, #ffffff);
    opacity: 0;
    /* The JS will handle the transition directly */
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .profile-image-container {
        width: 250px;
        height: 250px;
    }
}

@media (max-width: 480px) {
    .profile-image-container {
        width: 200px;
        height: 200px;
    }
}