<!doctype html>
<html lang="zh-CN">
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>SaaSShop 首页</title>
    <link rel="stylesheet" href="/css/public-pages.css">
</head>
<body class="dark-page">
<div class="public-wrap">
    <h1>SaaSShop 多端项目首页</h1>
    <p class="muted">当前基础框架已按多端方向铺开：PC、H5 可直接访问，微信生态与 APP 接口层已预留入口；后台当前已形成总台管理、站点后台、商家后台三层入口骨架。</p>
    <div class="grid-3">
        <div class="card"><h3>商家数</h3><p>{{ $merchantCount }}</p></div>
        <div class="card"><h3>商品数</h3><p>{{ $productCount }}</p></div>
        <div class="card"><h3>订单数</h3><p>{{ $orderCount }}</p></div>
    </div>

    <div class="card mt-20">
        <h3>管理与系统入口</h3>
        <ul>
            <li><a href="/admin">总台管理</a></li>
            <li><a href="/site-admin">站点后台</a></li>
            <li><a href="/merchant-admin">商家后台</a></li>
            <li><a href="/health">环境健康检查页</a></li>
            <li><a href="http://192.168.10.199:888/">phpMyAdmin</a></li>
            <li><a href="/api/v1/ping">API Ping</a></li>
            <li><a href="/api/v1/platforms">平台能力接口</a></li>
            <li><a href="/api/v1/products">商品列表接口</a></li>
            <li><a href="/api/v1/orders">订单列表接口</a></li>
        </ul>
        <p>项目目录：<code>/var/www/sites/app</code></p>
    </div>

    <div class="platforms">
        @foreach($platforms as $platform)
            <div class="card">
                <h3>{{ $platform['name'] }} <span class="tag">{{ $platform['status'] }}</span></h3>
                <p><a href="{{ $platform['path'] }}">访问入口 {{ $platform['path'] }}</a></p>
            </div>
        @endforeach
    </div>
</div>
</body>
</html>
