/* Graph Theory Playground (/graph-theory-playground): the drawing board, the Draws / Erases switch, the action row and
   the property buttons. Tiles, the callout, the buttons and the fields come from the app kit.
   Loaded only on its page (Views/SeoLanding/_GraphTheoryPlaygroundDemo.cshtml). */

.gtp-app .gtp-tool {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--ak-space-2) var(--ak-space-3);
    margin-bottom: var(--ak-space-2);
}

.gtp-app .gtp-board {
    border-radius: var(--ak-radius-sm);
}

.gtp-app .gtp-board:focus-visible {
    outline: 2px solid var(--ak-accent);
    outline-offset: 3px;
}

/* The board is 4:3, like the drawing area in the script, so a graph keeps its shape on every screen. */
.gtp-app .gtp-chart {
    max-width: 720px;
    height: auto;
    aspect-ratio: 4 / 3;
    margin-inline: auto;
    touch-action: none;
    user-select: none;
    -webkit-user-select: none;
    cursor: crosshair;
}

.gtp-app .gtp-actions {
    margin-top: var(--ak-space-2);
}

.gtp-app .gtp-say {
    min-height: 3.1rem;
}

.gtp-app .gtp-props {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(9.5rem, 1fr));
    gap: var(--ak-space-2);
    margin: 0;
    padding: 0;
    list-style: none;
}

.gtp-app .gtp-prop {
    display: flex;
    flex-direction: column;
    gap: 2px;
    width: 100%;
    height: 100%;
    padding: var(--ak-space-2) var(--ak-space-3);
    border: 1px solid var(--ak-border);
    border-radius: var(--ak-radius-sm);
    background: var(--ak-field);
    color: var(--ak-text);
    font: inherit;
    text-align: start;
}

.gtp-app button.gtp-prop {
    cursor: pointer;
}

.gtp-app button.gtp-prop:hover {
    background: var(--ak-hover);
}

.gtp-app button.gtp-prop:focus-visible {
    outline: 2px solid var(--ak-accent);
    outline-offset: 2px;
}

.gtp-app button.gtp-prop[aria-pressed="true"] {
    border-color: var(--ak-accent);
    box-shadow: inset 0 0 0 1px var(--ak-accent);
}

.gtp-app .gtp-prop-label {
    color: var(--ak-muted);
    font-size: var(--ak-fs-sm);
}

.gtp-app .gtp-prop-value {
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    overflow-wrap: anywhere;
}

.gtp-app button.gtp-prop[aria-pressed="true"] .gtp-prop-label {
    color: var(--ak-accent);
}

@media (max-width: 560px) {
    .gtp-app .gtp-props {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}
