/* =========================================================
   ArmorPlus Wiki - Individual Material & Soul Pages
   ========================================================= */

.material-profile {
    display: grid;
    grid-template-columns: 112px minmax(0, 1fr);
    gap: 1.25rem;
    align-items: center;
}

.material-profile-visual {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 112px;
    height: 112px;
    box-sizing: border-box;
    overflow: hidden;
    background: #080812;
    border: 1px solid rgba(114, 137, 218, 0.32);
    border-radius: 10px;
}

.material-profile-visual img,
.material-profile-visual .material-profile-sprite {
    display: block;
    width: 88px;
    height: 88px;
    object-fit: contain;
    image-rendering: pixelated;
}

.material-profile-visual .material-profile-sprite {
    background-repeat: no-repeat;
    background-position: center top;
}

.material-profile-type {
    display: block;
    margin-bottom: 0.45rem;
    color: #8195e5;
    font-family: var(--font-accent);
    font-size: 0.58rem;
    letter-spacing: 0.07em;
    text-transform: uppercase;
}

.wiki-article .material-profile h2 {
    margin: 0 0 0.55rem;
}

.material-profile p {
    margin: 0;
}

.material-source-card {
    padding: 1rem;
    background: linear-gradient(145deg, #15152d, #101020);
    border: 1px solid rgba(114, 137, 218, 0.18);
    border-radius: 9px;
}

.material-source-card h3 {
    margin: 0.45rem 0;
    color: #c6d2ff;
}

#material-acquisition-content > p:first-child,
#material-uses-content > p:first-child {
    margin-top: 0;
}

#material-acquisition-content .recipe-card,
#material-acquisition-content .searchable-recipe {
    margin-top: 1rem;
}

@media (max-width: 600px) {
    .material-profile {
        grid-template-columns: 76px minmax(0, 1fr);
        gap: 0.9rem;
    }

    .material-profile-visual {
        width: 76px;
        height: 76px;
    }

    .material-profile-visual img,
    .material-profile-visual .material-profile-sprite {
        width: 60px;
        height: 60px;
    }
}

.material-profile-fallback {
    width: 88px;
    height: 88px;
    font-size: 1.4rem;
}

.material-profile > .registry-id { grid-column: 1 / -1; }

/* Static-first animated infused materials: works even when JavaScript is disabled. */
.css-sprite-5 { background-repeat:no-repeat; background-position:center 0; background-size:100% 500%; animation:armorplus-sprite-5 .75s steps(1,end) infinite; image-rendering:pixelated; }
@keyframes armorplus-sprite-5 { 0%,19.999%{background-position:center 0%} 20%,39.999%{background-position:center 25%} 40%,59.999%{background-position:center 50%} 60%,79.999%{background-position:center 75%} 80%,100%{background-position:center 100%} }
@media (prefers-reduced-motion:reduce){.css-sprite-5{animation:none}}

.static-material-visual{display:flex;align-items:center;justify-content:center}
