:root {
    --primary-color: #18a058;
    --primary-dark: #0d7a3f;
    --primary-light: rgba(24, 160, 88, 0.08);
    --primary-gradient: linear-gradient(145deg, #22b86a 0%, #0f9a52 50%, #0a7d42 100%);
    --wechat-color: #07c160;
    --alipay-color: #1677ff;
    --bg-color: #eef3f0;
    --card-bg: #ffffff;
    --text-main: #1a1a1a;
    --text-sub: #6b7280;
    --border-color: #e5ebe8;
    --accent-orange: #f59e0b;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.04);
    --shadow-md: 0 8px 32px rgba(24, 160, 88, 0.08);
    --radius-lg: 20px;
    --radius-md: 14px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", -apple-system, sans-serif;
    background-color: var(--bg-color);
    color: var(--text-main);
    line-height: 1.6;
    min-height: 100vh;
}

.page-bg {
    position: fixed;
    inset: 0;
    background:
        radial-gradient(ellipse 80% 50% at 50% -10%, rgba(24, 160, 88, 0.12) 0%, transparent 60%),
        radial-gradient(ellipse 60% 40% at 100% 100%, rgba(24, 160, 88, 0.06) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

.container {
    position: relative;
    z-index: 1;
    max-width: 580px;
    margin: 0 auto;
    padding: 20px 16px 32px;
}

/* Header */
.site-header {
    display: flex;
    align-items: center;
    padding: 20px 0 16px;
    gap: 14px;
}

.logo-wrap {
    position: relative;
    flex-shrink: 0;
}

.logo {
    width: 56px;
    height: 56px;
    border-radius: 16px;
    box-shadow: var(--shadow-md);
    display: block;
}

.logo-badge {
    position: absolute;
    bottom: -4px;
    right: -6px;
    background: var(--primary-gradient);
    color: #fff;
    font-size: 0.6rem;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 8px;
    border: 2px solid var(--bg-color);
    letter-spacing: 0.02em;
}

.header-text h1 {
    font-size: 1.35rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.3;
}

.header-tagline {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 6px;
}

.header-tagline .tag {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.72rem;
    color: var(--primary-dark);
    background: var(--primary-light);
    padding: 3px 8px;
    border-radius: 20px;
    font-weight: 500;
}

.header-tagline .tag i {
    font-size: 0.65rem;
}

/* Hero strip */
.hero-strip {
    display: flex;
    align-items: center;
    justify-content: space-around;
    background: var(--card-bg);
    border-radius: var(--radius-lg);
    padding: 16px 12px;
    margin-bottom: 16px;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
}

.hero-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    flex: 1;
}

.hero-item strong {
    font-size: 1rem;
    color: var(--primary-color);
    font-weight: 700;
}

.hero-item span {
    font-size: 0.72rem;
    color: var(--text-sub);
}

.hero-divider {
    width: 1px;
    height: 28px;
    background: var(--border-color);
    flex-shrink: 0;
}

/* Recharge card */
.recharge-card {
    background: var(--card-bg);
    border-radius: var(--radius-lg);
    padding: 24px 20px;
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border-color);
    margin-bottom: 20px;
}

.section-title {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-main);
}

.step-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    background: var(--primary-gradient);
    color: #fff;
    font-size: 0.75rem;
    font-weight: 700;
    border-radius: 50%;
    flex-shrink: 0;
}

.input-box {
    width: 100%;
    padding: 14px 16px;
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 0.95rem;
    background: #fafbfa;
    transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
    outline: none;
    margin-bottom: 22px;
    color: var(--text-main);
}

.input-box::placeholder {
    color: #aaa;
}

.input-box:focus {
    border-color: var(--primary-color);
    background: #fff;
    box-shadow: 0 0 0 3px rgba(24, 160, 88, 0.12);
}

/* Amount grid */
.amount-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-bottom: 22px;
}

@media (max-width: 400px) {
    .amount-grid { grid-template-columns: repeat(2, 1fr); }
}

.amount-item {
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 14px 6px;
    text-align: center;
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s, transform 0.15s, box-shadow 0.2s;
    background: #fafbfa;
    position: relative;
    overflow: hidden;
}

.amount-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: transparent;
    transition: background 0.2s;
}

.amount-item.active {
    border-color: var(--primary-color);
    background: var(--primary-light);
    box-shadow: 0 4px 12px rgba(24, 160, 88, 0.15);
    transform: translateY(-1px);
}

.amount-item.active::before {
    background: var(--primary-gradient);
}

.bean-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.05rem;
    margin-bottom: 3px;
    color: var(--text-main);
}

.bean-icon {
    width: 17px;
    height: 17px;
    margin-right: 3px;
}

.price-label {
    font-size: 0.78rem;
    color: var(--text-sub);
}

/* Payment */
.pay-selector {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 22px;
}

.pay-btn {
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 13px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 500;
    font-size: 0.9rem;
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s, color 0.2s;
    background: #fafbfa;
}

.pay-btn i {
    font-size: 1.15rem;
    margin-right: 7px;
}

.pay-btn.wechat.active {
    border-color: var(--wechat-color);
    color: var(--wechat-color);
    background: rgba(7, 193, 96, 0.06);
}

.pay-btn.alipay.active {
    border-color: var(--alipay-color);
    color: var(--alipay-color);
    background: rgba(22, 119, 255, 0.06);
}

/* Submit */
.submit-btn {
    width: 100%;
    padding: 16px 20px;
    border: none;
    border-radius: 50px;
    background: var(--primary-gradient);
    color: white;
    font-size: 1.05rem;
    font-weight: 600;
    box-shadow: 0 6px 20px rgba(24, 160, 88, 0.35);
    cursor: pointer;
    transition: transform 0.15s, box-shadow 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    letter-spacing: 0.02em;
}

.submit-btn:active {
    transform: scale(0.98);
    box-shadow: 0 3px 12px rgba(24, 160, 88, 0.25);
}

.submit-btn i {
    font-size: 0.85rem;
    transition: transform 0.2s;
}

.submit-btn:active i {
    transform: translateX(3px);
}

/* Agreement */
.agreement-box {
    margin-top: 14px;
    text-align: center;
}

.agreement-label {
    display: inline-flex;
    align-items: center;
    font-size: 0.82rem;
    color: var(--text-sub);
    cursor: pointer;
    user-select: none;
}

.agreement-label input[type="checkbox"] {
    display: none;
}

.checkmark {
    width: 17px;
    height: 17px;
    border: 1.5px solid var(--border-color);
    border-radius: 4px;
    margin-right: 7px;
    position: relative;
    background: #fff;
    transition: background 0.2s, border-color 0.2s;
    flex-shrink: 0;
}

.agreement-label input[type="checkbox"]:checked + .checkmark {
    background: var(--primary-color);
    border-color: var(--primary-color);
}

.checkmark::after {
    content: '';
    position: absolute;
    display: none;
    left: 5px;
    top: 1px;
    width: 4px;
    height: 8px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.agreement-label input[type="checkbox"]:checked + .checkmark::after {
    display: block;
}

.agreement-link {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
}

.agreement-link:hover {
    text-decoration: underline;
}

/* Feature section */
.feature-section {
    margin-bottom: 16px;
}

.block-heading {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 12px;
    padding-left: 4px;
    color: var(--text-main);
}

.advantage-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
}

.adv-item {
    background: var(--card-bg);
    padding: 16px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: flex-start;
    gap: 14px;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    transition: box-shadow 0.2s;
}

.adv-item:hover {
    box-shadow: var(--shadow-md);
}

.adv-icon {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.adv-icon i {
    font-size: 1.1rem;
}

.icon-shield {
    background: rgba(24, 160, 88, 0.1);
    color: var(--primary-color);
}

.icon-speed {
    background: rgba(245, 158, 11, 0.1);
    color: var(--accent-orange);
}

.icon-support {
    background: rgba(22, 119, 255, 0.1);
    color: var(--alipay-color);
}

.adv-content h4 {
    font-size: 0.92rem;
    margin-bottom: 4px;
    font-weight: 600;
}

.adv-content p {
    font-size: 0.8rem;
    color: var(--text-sub);
    line-height: 1.55;
}

/* Info boxes */
.info-box {
    margin-top: 14px;
    background: var(--card-bg);
    padding: 18px 20px;
    border-radius: var(--radius-md);
    font-size: 0.82rem;
    color: var(--text-sub);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
}

.info-box h5 {
    color: var(--text-main);
    margin-bottom: 12px;
    font-size: 0.9rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 6px;
}

.info-box h5 i {
    color: var(--primary-color);
    font-size: 0.85rem;
}

.notice-box ul {
    padding-left: 18px;
    list-style: disc;
}

.notice-box li {
    margin-bottom: 7px;
    line-height: 1.55;
}

.notice-box li:last-child {
    margin-bottom: 0;
}

/* FAQ */
.faq-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.faq-item {
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border-color);
}

.faq-item:last-child {
    padding-bottom: 0;
    border-bottom: none;
}

.faq-item dt {
    font-weight: 600;
    color: var(--text-main);
    font-size: 0.85rem;
    margin-bottom: 4px;
}

.faq-item dd {
    font-size: 0.8rem;
    color: var(--text-sub);
    line-height: 1.55;
    margin: 0;
}

/* Modal */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.45);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    padding: 16px;
}

.modal {
    background: #fff;
    width: 100%;
    max-width: 360px;
    border-radius: 24px;
    padding: 24px;
    animation: modalPop 0.28s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
}

@keyframes modalPop {
    from { opacity: 0; transform: scale(0.92) translateY(8px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}

.modal-title {
    text-align: center;
    font-weight: 700;
    margin-bottom: 18px;
    font-size: 1.05rem;
}

.modal-body {
    background: #f7faf8;
    border-radius: 14px;
    padding: 14px 16px;
}

.modal-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    font-size: 0.88rem;
}

.modal-row:last-child {
    margin-bottom: 0;
}

.modal-row .label {
    color: var(--text-sub);
}

.modal-row .val {
    font-weight: 600;
    display: flex;
    align-items: center;
    color: var(--text-main);
}

.total-row {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px dashed var(--border-color);
}

.modal-row .price {
    color: #e53e3e;
    font-size: 1.15rem;
}

.btn-group {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.btn-group button {
    flex: 1;
    padding: 13px;
    border: none;
    border-radius: var(--radius-md);
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: opacity 0.15s;
}

.btn-group button:active {
    opacity: 0.85;
}

.btn-cancel {
    background: #f0f2f1;
    color: var(--text-sub);
}

.btn-confirm {
    background: var(--primary-gradient);
    color: #fff;
}

/* Footer */
.site-footer {
    text-align: center;
    padding: 36px 0 12px;
    color: #aaa;
    font-size: 0.73rem;
    line-height: 1.8;
}

.footer-brand {
    font-size: 0.82rem;
    color: var(--text-sub);
    font-weight: 500;
    margin-bottom: 6px;
}

.footer-meta {
    color: #bbb;
}

.footer-meta .dot {
    margin: 0 4px;
}

.footer-copy {
    margin-top: 4px;
    color: #ccc;
}
