/* KickRocksMF value card. Ported from Middle Mann's mm-value-card:
   - Mouse-tracked 3D tilt via CSS custom properties (no inline styles)
   - Neighbor-dim on hover
   - Underline slide 0->100% on headline on hover
   Uses --lite modifier layout (number + headline in a row, stacked body below). */

.kr-value-row {
    --tilt-x: 0deg;
    --tilt-y: 0deg;
    --tilt-z: 0px;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    perspective: 1200px;
}
.kr-value-row-3 { grid-template-columns: repeat(3, 1fr); }
.kr-value-row-4 { grid-template-columns: repeat(4, 1fr); }

.kr-value-card {
    --tilt-x: 0deg;
    --tilt-y: 0deg;
    --tilt-z: 0px;
    position: relative;
    padding: 32px 28px 28px;
    background: #0a0a0a;
    border: 1px solid #2a2a2a;
    display: flex;
    flex-direction: column;
    transform-style: preserve-3d;
    transform: perspective(1200px) rotateX(var(--tilt-x)) rotateY(var(--tilt-y)) translateZ(var(--tilt-z));
    will-change: transform;
    transition:
        opacity 200ms ease-out,
        filter 200ms ease-out,
        box-shadow 200ms ease-out,
        transform 200ms ease-out;
}

.kr-value-row-active .kr-value-card-dim {
    opacity: 0.55;
    filter: saturate(0.6);
}

.kr-value-card-active {
    box-shadow:
        0 25px 40px -20px rgba(0, 0, 0, 0.7),
        0 8px 20px -8px rgba(0, 0, 0, 0.5);
    z-index: 2;
}

.kr-value-head {
    display: flex;
    align-items: baseline;
    gap: 18px;
    margin-bottom: 18px;
}

.kr-value-num {
    font-size: 40px;
    font-weight: 900;
    line-height: 1;
    color: #CD3711;
    font-variant-numeric: tabular-nums;
    user-select: none;
}

.kr-value-headline {
    position: relative;
    display: inline-block;
    font-size: 20px;
    font-weight: 900;
    line-height: 1.15;
    letter-spacing: -0.01em;
    color: #fff;
    text-transform: uppercase;
    margin: 0;
}

.kr-value-headline::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -6px;
    height: 2px;
    width: 0;
    background: #CD3711;
    transition: width 500ms ease-out;
}
.kr-value-card-active .kr-value-headline::after { width: 100%; }

.kr-value-body {
    font-size: 15px;
    line-height: 1.55;
    color: #b6b6b6;
    margin: 0;
    font-weight: 400;
}

@media (prefers-reduced-motion: reduce) {
    .kr-value-card {
        transition: none;
        transform: none;
    }
    .kr-value-headline::after { transition: none; }
}

@media (max-width: 1199px) {
    .kr-value-row-4 { grid-template-columns: repeat(2, 1fr); }
    .kr-value-row-3 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 767px) {
    .kr-value-row,
    .kr-value-row-3,
    .kr-value-row-4 {
        grid-template-columns: 1fr;
        gap: 16px;
        perspective: none;
    }
    .kr-value-card {
        padding: 26px 22px 24px;
        transform: none;
    }
    .kr-value-num { font-size: 36px; }
    .kr-value-headline { font-size: 18px; }
}
