$ErrorActionPreference = 'Stop'
$root = Split-Path -Parent $PSScriptRoot
$g05 = Get-Content -LiteralPath (Join-Path $root 'pages/genealogy/g05-genealogy-overview.vue') -Raw -Encoding utf8
function Assert-Match { param([string]$Pattern,[string]$Message); if ($g05 -notmatch $Pattern) { throw $Message } }
Assert-Match 'overview-surface--state' 'G05 system states must own an independent surface'
Assert-Match 'class="overview-state__frame".*g01-empty-panel-frame\.png' 'G05 system states must reuse the transparent gold frame'
Assert-Match 'class="overview-state__seal".*brand-seal\.png' 'G05 non-loading states must use the approved red-gold seal'
Assert-Match '(?s)\.overview-surface--state\s+\.overview-surface__skin\s*\{[^}]*display:\s*none;' 'G05 system states must hide the legacy function-grid skin'
Assert-Match '(?s)\.overview-state__seal\s*\{[^}]*width:\s*132rpx;[^}]*height:\s*136rpx;' 'G05 state seal must use the approved size'
Assert-Match 'overview-action-lock' 'G05 member mode must explain owner-only actions instead of leaving blank cells'
Assert-Match '(?s)\.overview-actions--member\s*\{[^}]*grid-template-rows:\s*1fr 1fr;' 'G05 member actions must retain the full two-row surface'
Assert-Match '(?s)\.overview-public__details > view:nth-child\(5\)\s*\{[^}]*grid-column:\s*1 / -1;' 'G05 public fifth identity detail must span the full row'
Assert-Match '(?s)\.overview-public__details > view:nth-child\(5\)\s*\{[^}]*position:\s*absolute;[^}]*top:\s*250rpx;' 'G05 public parent genealogy must occupy the dedicated identity row'
Assert-Match '(?s)\s*.*publicDescription.*\s*