<?php
if (!defined('ROOT_PATH')) {
    define('ROOT_PATH', dirname(dirname(__DIR__)) . '/');
}

$premiumFile = ROOT_PATH . 'modules-premium/pro/recharge/member_page.php';
if (!is_file($premiumFile)) {
    require_once ROOT_PATH . 'core/lib/license.php';
    require_once ROOT_PATH . 'core/lib/license_guard.php';
    require_once ROOT_PATH . 'core/lib/module_loader.php';
    $license = new \Core\Lib\License();
    if ($license->getLevel() > \Core\Lib\License::LEVEL_FREE) {
        $loader = new \Core\Lib\ModuleLoader($license);
        $loader->syncAuthorizedModules();
    }
}

if (is_file($premiumFile)) {
    require $premiumFile;
    return;
}
?>
<div class="page-header">
    <h1 class="page-title">
        <i class="icon-credit-card"></i>
        充值中心
    </h1>
</div>
<div class="page-content recharge-page">
    <div class="empty-state" style="padding:60px 20px;">
        <div class="empty-state-icon">🔒</div>
        <div class="empty-state-text" style="font-size:18px;color:#0f172a;margin-bottom:8px;">在线充值未开通</div>
        <div style="color:#64748b;line-height:1.8;max-width:520px;margin:0 auto;">
            当前站点未安装充值模块，免费版不包含在线充值能力。请升级授权后同步商业模块。
        </div>
        <div style="margin-top:20px;">
            <a href="http://www.yutoucms.cn/license-center/user.php?act=buy" target="_blank" class="btn btn-primary">立即升级</a>
        </div>
    </div>
</div>
