/* How to Play page styles — scoped under .how-to-play-page */

.how-to-play-page .page-wrap {
    max-width: 860px;
}

/* Step-by-step instructions */
.howto-steps {
    margin: 0 0 24px;
    padding-left: 22px;
    color: #ccc;
    font-size: 14px;
    line-height: 1.7;
}

.howto-steps li {
    margin-bottom: 10px;
}

.howto-steps strong {
    color: var(--safe-color);
}

/* Screenshots */
.howto-screenshots {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-top: 24px;
}

.howto-shot {
    margin: 0;
}

.howto-shot img {
    width: 100%;
    border-radius: 8px;
    border: 1px solid #2a2a2a;
    background: #000;
    display: block;
}

.howto-shot figcaption {
    margin-top: 8px;
    font-size: 12px;
    color: #888;
    text-align: center;
}

/* Type tables */
.type-table-wrap {
    overflow-x: auto;
    margin-top: 8px;
}

.type-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}

.type-table th,
.type-table td {
    padding: 12px;
    border-bottom: 1px solid #222;
    text-align: left;
    vertical-align: top;
}

.type-table th {
    color: #888;
    text-transform: uppercase;
    font-size: 11px;
}

.type-table td.type-name {
    color: var(--safe-color);
    font-weight: 700;
    white-space: nowrap;
}

.type-table td.type-preview {
    width: 200px;
    min-width: 160px;
}

/* 3D visualizer canvas */
.viz-canvas {
    width: 100%;
    height: 200px;
    border-radius: 8px;
    border: 1px solid #2a2a2a;
    background: #0a0c14;
    overflow: hidden;
    position: relative;
}

.viz-canvas canvas {
    display: block;
    width: 100%;
    height: 100%;
}

/* Type label overlaid in the top-left corner of the preview */
.viz-label {
    position: absolute;
    top: 8px;
    left: 10px;
    z-index: 2;
    font-family: 'Creepster', cursive;
    font-size: 18px;
    color: var(--safe-color);
    letter-spacing: 1px;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.7);
    pointer-events: none;
}

.viz-canvas::after {
    content: "Drag to rotate · scroll to zoom";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 4px 0;
    text-align: center;
    font-size: 10px;
    color: rgba(255, 255, 255, 0.45);
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.55));
    pointer-events: none;
}

@media (max-width: 700px) {
    .howto-screenshots {
        grid-template-columns: 1fr;
    }

    .type-table td.type-preview {
        width: 140px;
        min-width: 120px;
    }

    .viz-canvas {
        height: 160px;
    }
}