/* GamesOver site chrome. Tokens shared with the placeholder-era design. */
:root {
	--sunset-gold: #f5c86e;
	--sunset-deep: #e8974f;
	--grid-magenta: #d879e0;
	--sea-teal: #7fd8d4;
	--ink: #0b1016;
	--panel: rgba(10, 16, 24, 0.82);
	--text: #e8eef4;
	--text-dim: #9db0c0;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
	background: var(--ink);
	color: var(--text);
	font-family: "Inter", "Segoe UI", system-ui, sans-serif;
	line-height: 1.6;
	min-height: 100vh;
	display: flex;
	flex-direction: column;
}

main { flex: 1 0 auto; }

.arcade { font-family: "Press Start 2P", monospace; }

.visually-hidden {
	position: absolute !important;
	width: 1px; height: 1px;
	padding: 0; margin: -1px;
	overflow: hidden; clip: rect(0 0 0 0);
	white-space: nowrap; border: 0;
}

/* Accessibility: skip link + visible focus */
.skip-nav {
	position: absolute;
	left: -9999px;
	top: 0;
	background: var(--sunset-gold);
	color: var(--ink);
	padding: 0.6rem 1rem;
	z-index: 100;
	font-weight: 600;
}
.skip-nav:focus { left: 0; }

a:focus-visible, button:focus-visible {
	outline: 3px solid var(--sea-teal);
	outline-offset: 2px;
}

a { color: var(--sea-teal); }

/* Header + nav */
.site-header {
	background: rgba(11, 16, 22, 0.92);
	border-bottom: 1px solid rgba(245, 200, 110, 0.25);
}
.site-header-inner {
	max-width: 64rem;
	margin: 0 auto;
	padding: 0.75rem 1.25rem;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	flex-wrap: wrap;
}
.brand {
	display: flex;
	align-items: center;
	gap: 0.7rem;
	text-decoration: none;
}
.brand-avatar {
	border-radius: 50%;
	border: 2px solid var(--sunset-gold);
}
.brand-name {
	color: var(--sunset-gold);
	font-size: 0.85rem;
	letter-spacing: 0.08em;
}
.site-nav ul {
	display: flex;
	gap: 1.25rem;
	list-style: none;
}
.site-nav a {
	color: var(--text);
	text-decoration: none;
	font-weight: 600;
	padding: 0.35rem 0;
	border-bottom: 2px solid transparent;
}
.site-nav a:hover { color: var(--sunset-gold); }
.site-nav a[aria-current="page"] {
	color: var(--sunset-gold);
	border-bottom-color: var(--grid-magenta);
}

/* Footer */
.site-footer {
	border-top: 1px solid rgba(245, 200, 110, 0.25);
	padding: 1.75rem 1.25rem 2.25rem;
	text-align: center;
	color: var(--text-dim);
	font-size: 0.85rem;
}
.site-footer-coin {
	display: block;
	font-size: 0.6rem;
	color: var(--sunset-deep);
	letter-spacing: 0.1em;
	margin-bottom: 0.75rem;
}
.site-footer-legal { margin-top: 1.25rem; }

.social-links {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 0.6rem;
}
.social-link {
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	padding: 0.45rem 0.9rem;
	border: 1px solid rgba(157, 176, 192, 0.3);
	border-radius: 999px;
	color: var(--text);
	text-decoration: none;
	font-size: 0.85rem;
	font-weight: 600;
}
.social-link:hover { border-color: var(--brand, var(--sunset-gold)); color: var(--brand, var(--sunset-gold)); }
.social-link .social-glyph {
	width: 18px; height: 18px;
	flex: none;
	fill: currentColor;
	color: var(--sunset-gold);
	transition: color 0.15s ease;
}
.social-link:hover .social-glyph { color: var(--brand, var(--sunset-gold)); }

/* Hero (home) */
.hero {
	position: relative;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	text-align: center;
	padding: 4rem 1.25rem 4.5rem;
	background:
		linear-gradient(180deg, rgba(11, 16, 22, 0.55) 0%, rgba(11, 16, 22, 0.75) 60%, var(--ink) 100%),
		url("/webart/spotify-header-20260615071729.png") center 30% / cover no-repeat;
	overflow: hidden;
}
.hero::after {
	content: "";
	position: absolute;
	inset: 0;
	pointer-events: none;
	background: repeating-linear-gradient(
		0deg,
		rgba(0, 0, 0, 0.18) 0px,
		rgba(0, 0, 0, 0.18) 1px,
		transparent 1px,
		transparent 4px
	);
	mix-blend-mode: overlay;
}
.hero > * { position: relative; z-index: 1; }

.hero-avatar {
	width: 148px; height: 148px;
	border-radius: 50%;
	border: 3px solid var(--sunset-gold);
	box-shadow:
		0 0 0 3px rgba(11, 16, 22, 0.9),
		0 0 28px rgba(245, 200, 110, 0.55),
		0 0 64px rgba(216, 121, 224, 0.35);
	object-fit: cover;
}
.hero h1 {
	margin-top: 1.75rem;
	font-size: clamp(1.6rem, 6vw, 3.25rem);
	letter-spacing: 0.08em;
	color: var(--sunset-gold);
	text-shadow:
		0 0 12px rgba(245, 200, 110, 0.65),
		4px 4px 0 rgba(216, 121, 224, 0.45);
}
.hero-tagline {
	margin-top: 1.1rem;
	font-size: clamp(0.95rem, 2.5vw, 1.15rem);
	color: var(--text-dim);
	max-width: 34rem;
}
.hero-cta {
	display: inline-block;
	margin-top: 2rem;
	padding: 0.9rem 1.6rem;
	border: 2px solid var(--grid-magenta);
	color: var(--grid-magenta);
	text-decoration: none;
	font-size: clamp(0.6rem, 2vw, 0.8rem);
	text-shadow: 0 0 10px rgba(216, 121, 224, 0.7);
	box-shadow: 0 0 14px rgba(216, 121, 224, 0.35);
}
.hero-cta:hover, .hero-cta:focus-visible {
	color: var(--ink);
	background: var(--grid-magenta);
	text-shadow: none;
}

/* Link panels (home + 404) */
.page-wrap {
	max-width: 44rem;
	margin: 0 auto;
	padding: 0 1.25rem 3rem;
	width: 100%;
}
.panel {
	background: var(--panel);
	border: 1px solid rgba(245, 200, 110, 0.25);
	border-radius: 10px;
	padding: 2rem 1.5rem;
	margin-top: 2rem;
	backdrop-filter: blur(4px);
}
.panel h2 {
	font-family: "Press Start 2P", monospace;
	font-size: clamp(0.75rem, 2.4vw, 1rem);
	letter-spacing: 0.06em;
	color: var(--sunset-gold);
	text-align: center;
	margin-bottom: 1.5rem;
}
.links {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
	gap: 0.8rem;
	list-style: none;
}
.links a {
	display: flex;
	align-items: center;
	gap: 0.7rem;
	padding: 0.85rem 1.1rem;
	border: 1px solid rgba(157, 176, 192, 0.3);
	border-radius: 8px;
	color: var(--text);
	text-decoration: none;
	font-weight: 600;
	font-size: 0.95rem;
	background: rgba(255, 255, 255, 0.03);
	transition: transform 0.15s ease, border-color 0.15s ease;
}
.links a:hover, .links a:focus-visible {
	transform: translateY(-2px);
	border-color: var(--brand, var(--sunset-gold));
}
.links .social-glyph {
	flex: none;
	width: 22px; height: 22px;
	fill: currentColor;
	color: var(--sunset-gold);
	transition: color 0.15s ease;
}
.links a:hover .social-glyph,
.links a:focus-visible .social-glyph {
	color: var(--brand, var(--sunset-gold));
}

/* 404 */
.notfound { text-align: center; }
.notfound h1 {
	color: var(--grid-magenta);
	font-size: clamp(1.2rem, 5vw, 2rem);
	margin-bottom: 1.25rem;
	text-shadow: 0 0 12px rgba(216, 121, 224, 0.6);
}

/* Popup layout */
.popup-body { display: block; padding: 1rem; }

/* Blog */
.page-wrap-wide { max-width: 52rem; }
.page-title {
	color: var(--sunset-gold);
	font-size: clamp(1.1rem, 4vw, 1.6rem);
	margin: 2rem 0 0.5rem;
	text-align: center;
}
.crumbs { margin-top: 1.5rem; font-size: 0.9rem; }
.post-list { display: flex; flex-direction: column; gap: 0.5rem; }
.post-card { display: flex; gap: 1.25rem; align-items: flex-start; }
.post-card-art { flex: none; width: 128px; }
.post-card-art img { width: 128px; height: 128px; object-fit: cover; border-radius: 8px; }
.post-card-title { font-size: 1.25rem; margin-bottom: 0.25rem; }
.post-card-title a { color: var(--text); text-decoration: none; }
.post-card-title a:hover { color: var(--sunset-gold); }
.post-meta { color: var(--text-dim); font-size: 0.85rem; margin-bottom: 0.6rem; }
/* Underlined so the link is distinguishable from adjacent text without relying on color (WCAG 1.4.1). */
.tag-link { color: var(--sea-teal); text-decoration: underline; margin-right: 0.35rem; }
.tag-link:hover { text-decoration: none; }
.pager { display: flex; justify-content: center; gap: 1.5rem; padding: 1.5rem 0; color: var(--text-dim); }
.post-full .post-title { font-size: clamp(1.4rem, 4.5vw, 2rem); margin-bottom: 0.4rem; }
.post-hero { max-width: 100%; border-radius: 8px; margin: 0.75rem 0 1.25rem; }
.draft-banner {
	background: rgba(216, 121, 224, 0.15);
	border: 1px solid var(--grid-magenta);
	color: var(--grid-magenta);
	padding: 0.5rem 0.9rem;
	border-radius: 6px;
	font-weight: 600;
	margin-bottom: 1rem;
}
.blog-empty { text-align: center; color: var(--text-dim); }
.post-nav { display: flex; justify-content: space-between; gap: 1rem; padding: 1.25rem 0 2rem; flex-wrap: wrap; }
.prose { line-height: 1.75; }
.prose h2, .prose h3 { color: var(--sunset-gold); margin: 1.5rem 0 0.5rem; }
.prose p, .prose ul, .prose ol, .prose blockquote { margin-bottom: 1rem; }
.prose ul, .prose ol { padding-left: 1.5rem; }
.prose blockquote { border-left: 3px solid var(--grid-magenta); padding-left: 1rem; color: var(--text-dim); }
.prose code { background: rgba(255, 255, 255, 0.08); padding: 0.1rem 0.35rem; border-radius: 4px; }
.prose pre { background: rgba(0, 0, 0, 0.4); padding: 1rem; border-radius: 8px; overflow-x: auto; margin-bottom: 1rem; }
.prose img { max-width: 100%; }

/* Home: latest release + blog panels */
.latest-card {
	display: flex;
	align-items: center;
	gap: 1rem;
	text-decoration: none;
	color: var(--text);
	border: 1px solid rgba(157, 176, 192, 0.3);
	border-radius: 8px;
	padding: 0.9rem 1.1rem;
}
.latest-card:hover, .latest-card:focus-visible { border-color: var(--sunset-gold); }
.latest-card img { border-radius: 8px; flex: none; }
.latest-info { display: flex; flex-direction: column; gap: 0.2rem; }
.latest-title { font-weight: 700; font-size: 1.1rem; }
.latest-info time { color: var(--text-dim); font-size: 0.85rem; }
.home-posts { list-style: none; display: flex; flex-direction: column; gap: 0.6rem; }
.home-posts li { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.home-posts a { color: var(--text); text-decoration: none; font-weight: 600; }
.home-posts a:hover { color: var(--sunset-gold); }
.home-posts time { color: var(--text-dim); font-size: 0.85rem; }
.home-posts-more { margin-top: 1rem; text-align: right; font-size: 0.9rem; }

@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	.links a { transition: none; }
}

/* Store */
.store-intro { text-align: center; color: var(--text-dim); margin-bottom: 1.5rem; }
.product-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 1.25rem; }
.product-card { background: var(--panel); border: 1px solid rgba(245, 200, 110, 0.25); border-radius: 10px; overflow: hidden; display: flex; flex-direction: column; }
.product-art { aspect-ratio: 1 / 1; background: rgba(255, 255, 255, 0.03); }
.product-art img { width: 100%; height: 100%; object-fit: cover; display: block; }
.product-noart { width: 100%; height: 100%; background: linear-gradient(135deg, rgba(216,121,224,0.25), rgba(127,216,212,0.25)); }
.product-body { padding: 1rem; display: flex; flex-direction: column; gap: 0.5rem; flex: 1; }
.product-title { font-size: 1.05rem; }
.product-desc { color: var(--text-dim); font-size: 0.85rem; }
.product-price { font-weight: 700; color: var(--sunset-gold); margin-top: auto; }
.btn-buy { display: inline-block; text-align: center; padding: 0.55rem 1rem; border-radius: 8px; font-weight: 600; text-decoration: none; background: var(--grid-magenta); color: var(--ink); }
.btn-buy.is-disabled { background: rgba(157, 176, 192, 0.2); color: var(--text-dim); cursor: not-allowed; }
.store-empty { text-align: center; color: var(--text-dim); }

/* Contact form */
.contact-form label { display: block; margin: 1rem 0 0.3rem; font-weight: 600; }
.contact-form input, .contact-form textarea {
	width: 100%;
	padding: 0.6rem;
	border-radius: 6px;
	border: 1px solid rgba(157, 176, 192, 0.35);
	background: rgba(255, 255, 255, 0.04);
	color: var(--text);
	font: inherit;
	box-sizing: border-box;
}
.contact-form input:focus-visible, .contact-form textarea:focus-visible {
	outline: 3px solid var(--sea-teal);
	outline-offset: 1px;
}
.btn-submit {
	margin-top: 1.25rem;
	padding: 0.65rem 1.4rem;
	border: 0;
	border-radius: 8px;
	background: var(--sunset-gold);
	color: var(--ink);
	font-weight: 700;
	cursor: pointer;
}
.hp-field { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-errors {
	background: rgba(216, 121, 224, 0.15);
	border: 1px solid var(--grid-magenta);
	border-radius: 6px;
	padding: 0.75rem 1rem;
	margin-bottom: 1rem;
}
.form-errors ul { margin: 0.5rem 0 0 1.25rem; }
.field-error { display: block; color: #ff9db0; font-size: 0.85rem; margin-top: 0.25rem; }
.contact-form input[aria-invalid="true"], .contact-form textarea[aria-invalid="true"] { border-color: var(--grid-magenta); }
.contact-success { color: var(--sea-teal); }

/* Share */
.share { margin-top: 1rem; display: flex; align-items: center; gap: 0.6rem; }
.share-btn {
	padding: 0.4rem 0.9rem;
	border: 1px solid var(--sea-teal);
	background: transparent;
	color: var(--sea-teal);
	border-radius: 999px;
	font-weight: 600;
	cursor: pointer;
}
.share-btn:hover, .share-btn:focus-visible { background: var(--sea-teal); color: var(--ink); }
.share-status { font-size: 0.85rem; color: var(--text-dim); }

/* store detail + cart (Phase 4A) */
.store-crumb { margin-bottom: 1rem; }
.store-crumb a { color: var(--text-dim); text-decoration: none; }
.store-crumb a:hover { color: var(--sunset-gold); }
.detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; align-items: start; }
.detail-image { width: 100%; border-radius: 10px; border: 1px solid rgba(245,200,110,0.25); }
.detail-info { display: flex; flex-direction: column; gap: 0.9rem; }
.detail-form { display: flex; flex-direction: column; gap: 0.9rem; margin-top: 0.5rem; }
.detail-option { display: flex; flex-direction: column; gap: 0.3rem; color: var(--text-dim); font-size: 0.9rem; }
.detail-option select, .detail-option input { background: var(--panel); color: var(--text); border: 1px solid rgba(245,200,110,0.3); border-radius: 6px; padding: 0.5rem; font: inherit; }
.detail-add { align-self: flex-start; cursor: pointer; border: 0; }
.detail-status { color: var(--sea-teal); font-size: 0.9rem; min-height: 1.2em; }
@media (max-width: 640px) { .detail-grid { grid-template-columns: 1fr; } }
.cart-table { width: 100%; border-collapse: collapse; }
.cart-table th, .cart-table td { border-bottom: 1px solid rgba(245,200,110,0.15); padding: 0.6rem 0.4rem; text-align: left; }
.cart-empty { color: var(--text-dim); text-align: center; padding: 2rem 0; }
.cart-summary { margin-top: 1rem; text-align: right; font-weight: 700; color: var(--sunset-gold); }
.cart-actions { margin-top: 1.25rem; display: flex; justify-content: flex-end; gap: 0.75rem; }
.cart-remove { background: none; border: 0; color: var(--text-dim); cursor: pointer; text-decoration: underline; }
.cart-count { background: var(--grid-magenta); color: var(--ink); border-radius: 999px; padding: 0 0.45rem; font-size: 0.75rem; margin-left: 0.25rem; }
.site-nav-cart[hidden] { display: none; }   /* cart link only appears once the cart has items */

/* store checkout (Phase 4B) */
.checkout-grid { display: grid; grid-template-columns: 1.5fr 1fr; gap: 2rem; align-items: start; }
.checkout-form { display: flex; flex-direction: column; gap: 1.25rem; }
.checkout-section { display: flex; flex-direction: column; gap: 0.5rem; }
.checkout-h { color: var(--sunset-gold); font-size: 1rem; }
.checkout-summary { background: var(--panel); border: 1px solid rgba(245,200,110,0.25); border-radius: 10px; padding: 1.1rem; }
.checkout-summary .sum-row { display: flex; justify-content: space-between; padding: 0.25rem 0; color: var(--text-dim); }
.checkout-summary .sum-total { display: flex; justify-content: space-between; padding: 0.5rem 0 0; margin-top: 0.4rem; border-top: 1px solid rgba(245,200,110,0.2); color: var(--sunset-gold); font-weight: 700; }
.checkout-pay { align-self: flex-start; cursor: pointer; border: 0; }
.checkout-empty { color: var(--text-dim); text-align: center; }
.complete-status { color: var(--sea-teal); font-size: 1.1rem; }
.text-dim { color: var(--text-dim); }
@media (max-width: 720px) { .checkout-grid { grid-template-columns: 1fr; } }
