/*
Theme Name: David X
Description: Block theme for davidx.ai — a portfolio of small, private, carefully made apps. Colours, fonts and spacing live in theme.json; layouts are HTML templates in /templates and /parts.
Version: 0.1.0
Requires at least: 6.7
Requires PHP: 8.1
Author: David Xiao
Text Domain: davidx
*/

/* Most styling is in theme.json. Only things theme.json can't express go here. */

/* App icons: the iOS rounded-square shape and a soft shadow. */
.app-icon img {
	border-radius: 22.5%;
	box-shadow: 0 6px 18px rgb(43 36 32 / 0.14);
	aspect-ratio: 1;
	object-fit: cover;
}

/* Icons keep their size inside the card's flex row instead of being squeezed. */
.app-card .app-icon { flex: 0 0 72px; width: 72px; margin: 0; }
.app-card .app-icon img { width: 72px; height: 72px; }

/* App names in ink, subtitles in violet. */
.app-card .wp-block-post-title a { color: var(--wp--preset--color--contrast); }

/* App cards lift slightly on hover (not for people who prefer reduced motion). */
.app-card {
	transition: transform 0.15s ease, box-shadow 0.15s ease;
	height: 100%;
}
@media (prefers-reduced-motion: no-preference) {
	.app-card:hover {
		transform: translateY(-2px);
		box-shadow: 0 10px 28px rgb(43 36 32 / 0.10);
	}
}
.app-card .wp-block-post-title a { text-decoration: none; }
.app-card .wp-block-post-title a::after { content: ""; position: absolute; inset: 0; } /* whole card clickable */
.app-card { position: relative; }

/* Keyboard focus is always visible. */
:where(a, button, input):focus-visible {
	outline: 3px solid var(--wp--preset--color--accent);
	outline-offset: 2px;
}
