.modern-home {
    --brand: #6d4aff;
    --brand-dark: #5134d6;
    --accent: #3478f6;
    --ink: #192033;
    --muted: #687087;
    --line: #e7e9f2;
    --surface: rgba(255, 255, 255, .96);
    margin: 0;
    min-height: 100vh;
    color: var(--ink);
    background: #f4f5fb;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    -webkit-font-smoothing: antialiased;
}

.modern-home::before {
    position: fixed;
    inset: 0 0 auto;
    height: 440px;
    content: "";
    z-index: -1;
    background:
        radial-gradient(circle at 18% 0%, rgba(139, 92, 246, .9), transparent 42%),
        linear-gradient(125deg, #5034cf, #397cf4);
}

.modern-home *, .modern-home *::before, .modern-home *::after { box-sizing: border-box; }
.modern-home a { text-decoration: none; }
.modern-home button, .modern-home input { font: inherit; }

.site-shell { width: min(1080px, calc(100% - 32px)); margin: 0 auto; padding: 32px 0 28px; }
.panel { background: var(--surface); border: 1px solid rgba(255,255,255,.7); border-radius: 22px; box-shadow: 0 16px 45px rgba(35, 38, 80, .10); }

.hero-card { padding: 42px; text-align: center; }
.brand-icon { width: 92px; height: 92px; display: block; margin: 0 auto 22px; border-radius: 24px; box-shadow: 0 14px 30px rgba(67, 48, 176, .2); }
.eyebrow, .step-label { display: inline-block; color: var(--brand); font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.hero-copy h1 { margin: 10px 0 12px; font-size: clamp(30px, 5vw, 46px); line-height: 1.16; letter-spacing: -.035em; }
.hero-copy h1 strong { color: var(--brand); }
.hero-copy p { max-width: 650px; margin: 0 auto; color: var(--muted); font-size: 16px; line-height: 1.8; }
.source-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 30px; }

.action, .submit-action { min-height: 50px; display: inline-flex; align-items: center; justify-content: center; gap: 9px; border: 0; border-radius: 13px; color: #fff !important; font-weight: 700; cursor: pointer; transition: transform .18s ease, box-shadow .18s ease, background .18s ease; }
.action:hover, .submit-action:hover { transform: translateY(-1px); color: #fff; }
.action-primary, .submit-action { background: linear-gradient(120deg, var(--brand), var(--accent)); box-shadow: 0 10px 22px rgba(83, 72, 218, .2); }
.action-secondary { background: #28324a; }

.quick-actions { display: flex; justify-content: center; gap: 10px; margin: 18px 0; padding: 15px; }
.quick-actions button { min-height: 44px; padding: 0 18px; border: 1px solid var(--line); border-radius: 11px; color: #3f465a; background: #fff; font-weight: 650; cursor: pointer; }
.quick-actions i { margin-right: 8px; color: var(--brand); }

.install-card, .guide-card { padding: 36px 42px; }
.guide-card { margin-top: 18px; }
.section-heading { margin-bottom: 28px; }
.section-heading h2 { margin: 7px 0 6px; font-size: 28px; letter-spacing: -.02em; }
.section-heading p { margin: 0; color: var(--muted); }
.form-stack { display: grid; gap: 14px; }
.field-block { padding: 21px; border: 1px solid var(--line); border-radius: 16px; background: #fbfbfe; }
.field-title { display: flex; align-items: center; gap: 9px; margin-bottom: 11px; color: #333a4f; font-weight: 700; }
.field-title > span { width: 25px; height: 25px; display: inline-grid; place-items: center; border-radius: 8px; color: #fff; background: var(--brand); font-size: 13px; }
.modern-home input[type="text"] { width: 100%; height: 52px; padding: 0 16px; border: 1px solid #dcdfea; border-radius: 12px; color: var(--ink); background: #fff; outline: none; font-size: 16px !important; touch-action: manipulation; }
.modern-home input[type="text"]:focus { border-color: var(--brand); box-shadow: 0 0 0 4px rgba(109, 74, 255, .11); }
.udid-row { display: grid; grid-template-columns: 1fr auto; gap: 10px; }
.udid-row .action { padding: 0 22px; }
.field-help { margin: 9px 0 0; color: #858ca0; font-size: 13px; }
.install-options { display: flex; flex-wrap: wrap; gap: 10px; }
.install-options label { min-width: 130px; display: flex; align-items: center; gap: 9px; padding: 12px 15px; border: 1px solid var(--line); border-radius: 11px; background: #fff; cursor: pointer; }
.install-options input, .legal-check input { width: 18px; height: 18px; accent-color: var(--brand); }
.legal-check { display: flex; align-items: center; gap: 9px; }
.submit-action { width: 100%; margin-top: 16px; }

.modern-install-layer { overflow: hidden; border-radius: 20px !important; box-shadow: 0 24px 70px rgba(32, 30, 77, .24) !important; }
.modern-install-layer .layui-layer-title { height: 58px; padding: 0 58px 0 22px; border: 0; color: #22283a; background: #fff; font-size: 18px; font-weight: 750; line-height: 58px; }
.modern-install-layer .layui-layer-setwin { top: 20px; right: 20px; }
.modern-install-layer .layui-layer-content { background: #fff; }
.install-dialog-body { padding: 4px 22px 24px; text-align: center; }
.install-dialog-icon { width: 54px; height: 54px; display: grid; place-items: center; margin: 2px auto 14px; border-radius: 18px; color: #fff; font-size: 28px; font-weight: 800; }
.install-dialog-icon.success { background: linear-gradient(135deg, #6d4aff, #3478f6); box-shadow: 0 12px 24px rgba(83, 72, 218, .25); }
.install-dialog-icon.error { background: linear-gradient(135deg, #ff6b6b, #e84462); box-shadow: 0 12px 24px rgba(220, 62, 84, .2); }
.install-dialog-message { margin: 0 0 19px; color: #6b7285; font-size: 15px; line-height: 1.7; }
.install-dialog-actions { display: grid; gap: 10px; }
.install-dialog-action { width: 100%; min-height: 48px; padding: 10px 16px; border: 0; border-radius: 13px; font-size: 16px; font-weight: 750; cursor: pointer; touch-action: manipulation; }
.install-dialog-action.primary { color: #fff; background: linear-gradient(120deg, #6d4aff, #3478f6); box-shadow: 0 10px 22px rgba(83, 72, 218, .2); }
.install-dialog-action.secondary { color: #5134d6; background: #f0edff; }
.install-dialog-action.neutral { color: #465066; background: #f1f3f7; }
.install-dialog-action:active { transform: translateY(1px); }

.guide-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.guide-grid article { display: flex; gap: 16px; padding: 22px; border: 1px solid var(--line); border-radius: 16px; background: #fbfbfe; }
.guide-icon { width: 44px; height: 44px; flex: 0 0 44px; display: grid; place-items: center; border-radius: 13px; }
.guide-icon.blue { color: #276ee5; background: #eaf2ff; }
.guide-icon.amber { color: #c77800; background: #fff3d9; }
.guide-grid h3 { margin: 1px 0 9px; font-size: 18px; }
.guide-grid ol { margin: 0; padding-left: 19px; color: var(--muted); line-height: 1.9; }
.site-footer { padding: 25px 8px 0; text-align: center; color: #73798b; font-size: 13px; }
.site-footer p { margin: 0 0 5px; }
.site-footer a { color: inherit; }

@media (max-width: 720px) {
    .modern-home::before { height: 360px; }
    .site-shell { width: min(100% - 20px, 1080px); padding-top: 10px; }
    .panel { border-radius: 18px; }
    .hero-card, .install-card, .guide-card { padding: 25px 20px; }
    .brand-icon { width: 78px; height: 78px; border-radius: 20px; margin-bottom: 18px; }
    .hero-copy h1 { font-size: 29px; }
    .hero-copy p { font-size: 14px; line-height: 1.7; }
    .source-grid, .guide-grid, .udid-row { grid-template-columns: 1fr; }
    .quick-actions { flex-wrap: wrap; }
    .quick-actions button { flex: 1 1 135px; padding: 0 11px; }
    .section-heading h2 { font-size: 24px; }
    .field-block { padding: 17px 15px; }
    .udid-row .action { width: 100%; }
    .install-options { display: grid; grid-template-columns: 1fr 1fr; }
    .install-options label { min-width: 0; }
    .guide-grid article { padding: 18px 16px; }
}

@media (prefers-reduced-motion: reduce) {
    .modern-home *, .modern-home *::before, .modern-home *::after { scroll-behavior: auto !important; transition: none !important; }
}
