* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "PingFang SC", "Microsoft YaHei", sans-serif;
    color: #1a1a2e;
    line-height: 1.6;
    background: #f5f5f7;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    z-index: 1000;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.navbar .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 56px;
}

.logo {
    font-size: 1.15rem;
    font-weight: 700;
    color: #1a1a2e;
    text-decoration: none;
    letter-spacing: -0.3px;
}
.logo h1 {
    font-size: inherit;
    font-weight: inherit;
    margin: 0;
    color: inherit;
    display: inline;
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 4px;
}

.nav-links a {
    text-decoration: none;
    color: #555;
    font-size: 0.875rem;
    font-weight: 500;
    padding: 6px 14px;
    border-radius: 6px;
    transition: all 0.2s;
}

.nav-links a:hover,
.nav-links a.active {
    color: #1a1a2e;
    background: rgba(0, 0, 0, 0.04);
}

/* Marquee / 居中弹窗 */
.marquee-bar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1001;
    transform: translateY(-100%);
    opacity: 0;
    transition: opacity 0.4s, transform 0.4s;
    padding: 10px 0;
    text-align: center;
    pointer-events: none;
}
.marquee-bar.marquee-visible {
    transform: translateY(0);
    opacity: 1;
}
.marquee-text {
    display: block;
    white-space: nowrap;
    overflow: hidden;
    animation: marquee-scroll 15s linear infinite;
    font-weight: 600;
    padding: 0 20px;
}
@keyframes marquee-scroll {
    0% { transform: translateX(calc(50vw + var(--marquee-offset, 0px))); }
    100% { transform: translateX(-100%); }
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 8px;
}

.auth-buttons {
    display: flex;
    gap: 6px;
}

.auth-btn {
    padding: 6px 14px;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    border: none;
    transition: all 0.2s;
}

.login-btn {
    background: transparent;
    color: #555;
}

.login-btn:hover {
    background: rgba(0, 0, 0, 0.04);
    color: #1a1a2e;
}

.register-btn {
    background: #1a1a2e;
    color: #fff;
}

.register-btn:hover {
    background: #333;
}

.logout-btn {
    background: transparent;
    color: #999;
}

.logout-btn:hover {
    color: #ff6b6b;
}

.user-menu {
    display: flex;
    align-items: center;
    gap: 10px;
}

.user-name {
    font-size: 0.85rem;
    font-weight: 600;
    color: #1a1a2e;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.4rem;
    cursor: pointer;
    color: #1a1a2e;
    padding: 4px;
}

/* Banner */
.banner-section {
    padding-top: 80px;
}

.banner-carousel {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    background: #e8e8ed;
}

.banner-track {
    display: flex;
    transition: transform 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.banner-slide {
    min-width: 100%;
    height: 320px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.5rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    background-size: cover;
    background-position: center;
    position: relative;
}

.banner-slide::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.15);
}

.banner-overlay {
    position: relative;
    z-index: 1;
    text-align: center;
    padding: 20px;
    max-width: 80%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.banner-title {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 8px;
    text-shadow: 0 2px 8px rgba(0,0,0,0.3);
}

.banner-subtitle {
    font-size: 1rem;
    font-weight: 400;
    opacity: 0.9;
    text-shadow: 0 1px 4px rgba(0,0,0,0.2);
}

.banner-dots {
    position: absolute;
    bottom: 16px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
}

.banner-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    border: none;
    cursor: pointer;
    transition: all 0.2s;
}

.banner-dot.active {
    background: #fff;
    width: 24px;
    border-radius: 4px;
}

/* Mall Tabs */
.mall-tabs {
    padding: 24px 0 8px;
}

.tabs-list {
    list-style: none;
    display: flex;
    gap: 4px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 4px;
}

.tab-item {
    flex-shrink: 0;
    padding: 8px 18px;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 500;
    color: #666;
    cursor: pointer;
    transition: all 0.2s;
    user-select: none;
}

.tab-item:hover {
    background: rgba(0, 0, 0, 0.04);
    color: #333;
}

.tab-item.active {
    color: #1a1a2e;
    background: #fff;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
    font-weight: 600;
}

/* Product Grid */
.products {
    padding: 16px 0 48px;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
}

.product-card {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.25s;
    border: 1px solid rgba(0, 0, 0, 0.06);
    display: flex;
}

.product-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    border-color: transparent;
}

.card-img {
    width: 140px;
    flex-shrink: 0;
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    font-weight: 700;
    color: #fff;
    background-size: cover;
    background-position: center;
    position: relative;
}

.card-tag {
    position: absolute;
    top: 8px;
    left: 8px;
    padding: 2px 8px;
    background: #ff6b6b;
    color: #fff;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 600;
}

.card-platforms {
    position: absolute;
    bottom: 8px;
    right: 8px;
    display: flex;
    gap: 3px;
}

.card-platforms span {
    padding: 1px 8px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 4px;
    font-size: 0.7rem;
    color: #555;
    font-weight: 600;
}

.card-body {
    padding: 14px 16px;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 0;
}

.card-category {
    display: inline-block;
    padding: 1px 8px;
    background: #f0f0f5;
    border-radius: 4px;
    font-size: 0.72rem;
    color: #888;
    margin-bottom: 6px;
}

.card-title {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 4px;
    color: #1a1a2e;
}

.card-tagline {
    font-size: 0.8rem;
    color: #999;
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 12px;
    border-top: 1px solid #f0f0f0;
}

.card-price {
    font-size: 1.1rem;
    font-weight: 700;
    color: #1a1a2e;
}

.card-price .original {
    font-size: 0.75rem;
    color: #ccc;
    text-decoration: line-through;
    font-weight: 400;
    margin-left: 6px;
}

.card-sales {
    font-size: 0.75rem;
    color: #bbb;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 10px 28px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    border: none;
    transition: all 0.2s;
}

.btn-primary {
    background: #1a1a2e;
    color: #fff;
}

.btn-primary:hover {
    background: #333;
    transform: translateY(-1px);
}

.btn-full {
    width: 100%;
    text-align: center;
}

.btn-danger {
    background: #ff6b6b;
    color: #fff;
    border: none;
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 0.85rem;
    cursor: pointer;
    transition: background 0.2s;
}

.btn-danger:hover {
    background: #e05555;
}

/* Promo */
.promo {
    padding: 16px 0 64px;
}

.section-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 20px;
    color: #1a1a2e;
}

.promo-banner {
    border-radius: 12px;
    background: linear-gradient(135deg, #1a1a2e 0%, #2d2d44 100%);
    color: #fff;
    padding: 48px;
    text-align: center;
}

.promo-content h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.promo-content p {
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 24px;
    font-size: 0.95rem;
}

.promo-content .btn-primary {
    background: #fff;
    color: #1a1a2e;
}

.promo-content .btn-primary:hover {
    background: rgba(255, 255, 255, 0.9);
}

/* Footer */
.footer {
    background: #fff;
    border-top: 1px solid rgba(0, 0, 0, 0.06);
    padding: 40px 0 0;
}

.footer-inner {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 40px;
    padding-bottom: 32px;
}

.footer-brand h3 {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 4px;
}

.footer-brand p {
    font-size: 0.85rem;
    color: #999;
}

.footer-links h4 {
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 12px;
    color: #1a1a2e;
}

.footer-links a {
    display: block;
    font-size: 0.85rem;
    color: #888;
    text-decoration: none;
    margin-bottom: 8px;
    transition: color 0.2s;
}

.footer-links a:hover {
    color: #1a1a2e;
}

.footer-bottom {
    padding: 20px 0;
    border-top: 1px solid rgba(0, 0, 0, 0.06);
    text-align: center;
    font-size: 0.8rem;
    color: #bbb;
}

.footer-bottom .icp-link {
    color: #bbb;
    text-decoration: none;
    transition: color 0.2s;
}

.footer-bottom .icp-link:hover {
    color: #666;
}

/* ========== Auth Modal ========== */
.auth-modal-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.auth-modal-overlay.active {
    display: flex;
}

.auth-modal {
    background: #fff;
    border-radius: 16px;
    max-width: 400px;
    width: 100%;
    padding: 36px 32px 28px;
    position: relative;
    animation: modalIn 0.2s ease;
}

@keyframes modalIn {
    from { transform: scale(0.95); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

.auth-modal-close {
    position: absolute;
    top: 14px;
    right: 18px;
    background: none;
    border: none;
    font-size: 1.6rem;
    color: #bbb;
    cursor: pointer;
    transition: color 0.2s;
    line-height: 1;
}

.auth-modal-close:hover {
    color: #333;
}

.auth-modal h2 {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 24px;
}

.form-group {
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    font-size: 0.82rem;
    font-weight: 500;
    color: #555;
    margin-bottom: 6px;
}

.form-group input {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    font-size: 0.9rem;
    outline: none;
    transition: border-color 0.2s;
}

.form-group input:focus {
    border-color: #1a1a2e;
}

.cat-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 8px;
}

.cat-chip {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 12px;
    border: 1px solid #d0d0d0;
    border-radius: 16px;
    font-size: 0.82rem;
    cursor: pointer;
    transition: all 0.15s;
    user-select: none;
}

.cat-chip:hover {
    border-color: #6c63ff;
    background: #f5f3ff;
}

.cat-chip input {
    display: none;
}

.cat-chip.checked {
    border-color: #6c63ff;
    background: #6c63ff;
    color: #fff;
}

.form-error {
    color: #ff6b6b;
    font-size: 0.8rem;
    margin-bottom: 12px;
    min-height: 1.2em;
}

.form-switch {
    text-align: center;
    font-size: 0.82rem;
    color: #999;
    margin-top: 16px;
}

.form-switch a {
    color: #1a1a2e;
    text-decoration: none;
    font-weight: 600;
}

.form-switch a:hover {
    text-decoration: underline;
}

/* ========== Product Detail ========== */
.detail-page {
    padding: 120px 0 40px;
}

.back-link {
    display: inline-block;
    color: #888;
    text-decoration: none;
    font-size: 0.85rem;
    margin-bottom: 24px;
    transition: color 0.2s;
}

.back-link:hover {
    color: #1a1a2e;
}

.detail-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    align-items: start;
}

.detail-gallery {
    position: sticky;
    top: 80px;
}

.detail-img-placeholder,
.detail-img {
    width: 100%;
    aspect-ratio: 1;
    border-radius: 16px;
    background: linear-gradient(135deg, #e0e0e8, #d0d0dc);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 5rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.6);
}

.detail-img {
    background-size: cover;
    background-position: center;
}

.platform-tags {
    display: flex;
    gap: 6px;
    margin-top: 16px;
    flex-wrap: wrap;
}

.platform-tag {
    padding: 4px 12px;
    background: #f0f0f5;
    border-radius: 6px;
    font-size: 0.8rem;
    color: #666;
    font-weight: 500;
}

.detail-category {
    display: inline-block;
    padding: 2px 10px;
    background: #f0f0f5;
    border-radius: 4px;
    font-size: 0.75rem;
    color: #888;
    margin-bottom: 8px;
}

.detail-tag {
    display: inline-block;
    padding: 2px 10px;
    background: #fff0f0;
    color: #ff6b6b;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    margin-left: 6px;
}

.detail-info h1 {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.detail-tagline {
    color: #999;
    font-size: 0.95rem;
    margin-bottom: 24px;
}

.detail-price-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 8px;
}

.detail-price {
    font-size: 2rem;
    font-weight: 700;
    color: #1a1a2e;
}

.detail-original-price {
    font-size: 1rem;
    color: #ccc;
    text-decoration: line-through;
}

.detail-discount {
    padding: 2px 8px;
    background: #ff6b6b;
    color: #fff;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 700;
}

.detail-meta {
    display: flex;
    gap: 16px;
    font-size: 0.85rem;
    color: #999;
    margin-bottom: 20px;
}

/* Plan selector */
.plan-selector {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
}

.plan-btn {
    flex: 1;
    min-width: 100px;
    padding: 10px 12px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    background: #fff;
    cursor: pointer;
    text-align: center;
    transition: all 0.2s;
}

.plan-btn:hover {
    border-color: #6c63ff;
}

.plan-btn.active {
    border-color: #6c63ff;
    background: #f8f8ff;
}

.plan-btn-name {
    display: block;
    font-size: 0.8rem;
    font-weight: 600;
    color: #1a1a2e;
    margin-bottom: 4px;
}

.plan-btn-price {
    display: block;
    font-size: 1.1rem;
    font-weight: 700;
    color: #6c63ff;
}

.plan-btn-oprice {
    display: block;
    font-size: 0.7rem;
    color: #bbb;
    text-decoration: line-through;
    margin-top: 2px;
}

/* Pay */
.pay-section h3,
.download-section h3 {
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 12px;
    color: #888;
}

.download-section .btn {
    width: 100%;
    padding: 12px;
    font-size: 0.95rem;
}

.pay-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: 8px;
    border: 1px solid #e8e8ed;
    background: #fff;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.2s;
    width: 100%;
    max-width: 280px;
}

.pay-btn:hover {
    border-color: #07c160;
    background: #f0faf4;
}

.pay-btn.wechat {
    border-color: #07c160;
    color: #07c160;
}

.pay-btn .icon {
    font-size: 1.2rem;
}

/* Detail Tabs */
.detail-body {
    padding: 0 0 80px;
}

.detail-tabs {
    display: flex;
    gap: 4px;
    border-bottom: 1px solid #e8e8ed;
    margin-bottom: 32px;
}

.tab-btn {
    padding: 12px 20px;
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    font-size: 0.9rem;
    font-weight: 500;
    color: #888;
    cursor: pointer;
    transition: all 0.2s;
    margin-bottom: -1px;
}

.tab-btn:hover {
    color: #555;
}

.tab-btn.active {
    color: #1a1a2e;
    border-bottom-color: #1a1a2e;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

.detail-desc {
    color: #555;
    line-height: 1.8;
    margin-bottom: 24px;
}

.feature-list {
    list-style: none;
}

.feature-list li {
    padding: 6px 0;
    color: #555;
}

.feature-list li::before {
    content: "✓";
    color: #6c63ff;
    font-weight: 700;
    margin-right: 8px;
}

.usage-list {
    padding-left: 20px;
    color: #555;
    line-height: 2;
}

.usage-content {
    color: #444;
    line-height: 1.8;
    font-size: 0.95rem;
}

.usage-content h3 {
    font-size: 1.1rem;
    font-weight: 600;
    margin: 24px 0 10px;
    color: #1a1a2e;
}

.usage-content p {
    margin: 0 0 12px;
}

.usage-content ul,
.usage-content ol {
    padding-left: 20px;
    margin: 8px 0 16px;
}

.usage-content li {
    margin-bottom: 4px;
}

.usage-content img {
    max-width: 100%;
    border-radius: 12px;
    margin: 12px 0;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
}

.usage-content video {
    max-width: 100%;
    border-radius: 12px;
    margin: 12px 0;
}

.usage-content code {
    background: #f0f0f5;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.85rem;
    color: #e74c3c;
}

.usage-content blockquote {
    border-left: 3px solid #6c63ff;
    margin: 12px 0;
    padding: 8px 16px;
    background: #f8f8ff;
    border-radius: 0 8px 8px 0;
}

/* ========== Cart & Orders ========== */
.icon-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 6px;
    border-radius: 6px;
    transition: background 0.2s;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.icon-btn:hover {
    background: rgba(0, 0, 0, 0.04);
}

.icon-svg {
    font-size: 1.15rem;
    line-height: 1;
}

.cart-icon {
    position: relative;
}

.cart-badge {
    position: absolute;
    top: 0;
    right: -2px;
    min-width: 16px;
    height: 16px;
    border-radius: 8px;
    background: #ff6b6b;
    color: #fff;
    font-size: 0.65rem;
    font-weight: 700;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
    display: none;
}

.cart-modal,
.orders-modal {
    max-width: 520px;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
}

.cart-modal #cartBody,
.orders-modal #ordersBody {
    flex: 1;
    overflow-y: auto;
    min-height: 100px;
}

.cart-empty {
    text-align: center;
    padding: 48px 0;
    color: #bbb;
    font-size: 0.9rem;
}

.cart-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid #f0f0f0;
}

.cart-item:first-of-type {
    padding-top: 0;
}

.cart-item-icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    background: linear-gradient(135deg, #6c63ff, #a78bfa);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1rem;
    flex-shrink: 0;
}

.cart-item-info {
    flex: 1;
    min-width: 0;
}

.cart-item-name {
    font-size: 0.9rem;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.cart-item-desc {
    font-size: 0.75rem;
    color: #999;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.cart-item-price {
    font-size: 0.95rem;
    font-weight: 700;
    color: #1a1a2e;
    white-space: nowrap;
}

.cart-item-remove {
    background: none;
    border: none;
    color: #ccc;
    cursor: pointer;
    font-size: 1rem;
    padding: 4px;
    transition: color 0.2s;
}

.cart-item-remove:hover {
    color: #ff6b6b;
}

.cart-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 0;
    font-size: 0.9rem;
    color: #888;
}

.cart-total-price {
    font-size: 1.15rem;
    font-weight: 700;
    color: #1a1a2e;
}

.order-card {
    background: #f8f8fa;
    border-radius: 10px;
    padding: 16px;
    margin-bottom: 12px;
}

.order-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    padding-bottom: 10px;
    border-bottom: 1px solid #e8e8ed;
}

.order-id {
    font-size: 0.82rem;
    font-weight: 600;
    color: #1a1a2e;
}

.order-date {
    font-size: 0.75rem;
    color: #999;
}

.order-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 6px 0;
}

.order-plan {
    font-size: 0.75rem;
    color: #6c63ff;
    background: #f0f0ff;
    padding: 1px 6px;
    border-radius: 4px;
    margin-left: 4px;
    font-weight: 500;
}

.cart-item-code {
    font-size: 0.78rem;
    color: #666;
    margin-top: 2px;
}

.cart-item-code code {
    color: #6c63ff;
    font-weight: 600;
    background: #f0f0ff;
    padding: 1px 6px;
    border-radius: 4px;
    user-select: all;
}

.download-btn {
    flex-shrink: 0;
    padding: 4px 12px;
    background: #6c63ff;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 0.78rem;
    cursor: pointer;
    transition: background 0.2s;
}

.download-btn:hover {
    background: #5a52e0;
}

.order-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 10px;
    margin-top: 10px;
    border-top: 1px solid #e8e8ed;
    font-size: 0.82rem;
    color: #888;
}

.detail-actions {
    margin-bottom: 24px;
}

.detail-actions .btn {
    width: 100%;
    max-width: 280px;
    text-align: center;
}

.btn-outline {
    background: transparent;
    border: 2px solid #6c63ff;
    color: #6c63ff;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.2s;
    font-weight: 600;
    width: 100%;
    max-width: 280px;
}

.btn-outline:hover {
    background: #6c63ff;
    color: #fff;
}

.trial-section {
    margin-bottom: 16px;
}

.trial-note {
    font-size: 0.78rem;
    color: #999;
    margin-top: 6px;
    max-width: 280px;
}

/* ========== Profile ========== */
.profile-btn {
    background: transparent;
    color: #555;
    font-size: 0.78rem;
}

.profile-btn:hover {
    color: #1a1a2e;
    background: rgba(0, 0, 0, 0.04);
}

.profile-body {
    text-align: center;
    padding: 8px 0;
}

.profile-avatar {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: linear-gradient(135deg, #6c63ff, #a78bfa);
    color: #fff;
    font-size: 1.6rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 12px;
}

.profile-name {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 20px;
}

.profile-stats {
    display: flex;
    justify-content: center;
    gap: 32px;
    margin-bottom: 24px;
    padding: 16px;
    background: #f8f8fa;
    border-radius: 12px;
}

.profile-stat {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

.profile-stat-num {
    font-size: 1.3rem;
    font-weight: 700;
    color: #1a1a2e;
}

.profile-stat-label {
    font-size: 0.78rem;
    color: #999;
}

.profile-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.profile-action-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    border: 1px solid #e8e8ed;
    border-radius: 10px;
    background: #fff;
    cursor: pointer;
    font-size: 0.9rem;
    color: #1a1a2e;
    transition: all 0.2s;
}

.profile-action-btn:hover {
    background: #f8f8fa;
    border-color: #ccc;
}

/* ========== Responsive ========== */
@media (max-width: 768px) {
    .banner-slide { height: 180px; }
    .banner-title { font-size: 1.2rem; }
    .banner-subtitle { font-size: 0.78rem; }
    .nav-links { display: none; }
    .nav-links.open { display: flex; flex-direction: column; position: absolute; top: 56px; left: 0; width: 100%; background: rgba(255,255,255,0.98); padding: 12px 20px; border-bottom: 1px solid rgba(0,0,0,0.06); gap: 2px; }
    .menu-toggle { display: block; }
    .product-grid { grid-template-columns: repeat(2, 1fr); }
    .footer-inner { grid-template-columns: 1fr; gap: 24px; }
    .detail-layout { grid-template-columns: 1fr; gap: 24px; }
    .detail-gallery { position: static; }
    .detail-img-placeholder { aspect-ratio: 16/9; font-size: 3rem; }
    .detail-body .container { padding: 0 16px; }
    .auth-buttons { gap: 4px; }
    .auth-btn { font-size: 0.75rem; padding: 5px 10px; }
    .icon-btn { padding: 4px; }
    .icon-svg { font-size: 1rem; }
    .cart-modal, .orders-modal { max-width: 100%; margin: 0 10px; }
}

@media (max-width: 480px) {
    .product-grid { grid-template-columns: 1fr; }
    .tab-item { padding: 6px 14px; font-size: 0.8rem; }
    .promo-banner { padding: 32px 20px; }
}

/* ========== Flash Sale ========== */
.flash-section {
    padding: 4px 0 0;
}
.flash-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px;
    padding: 10px 16px;
    background: linear-gradient(135deg, #fff5f5, #ffe0e0);
    border-radius: 10px;
    border: 1px solid #ffcccc;
}
.flash-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #e74c3c;
    animation: flash-pulse 1.5s ease-in-out infinite;
}
@keyframes flash-pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}
.flash-countdown {
    font-size: 1.1rem;
    font-weight: 700;
    color: #e74c3c;
    font-variant-numeric: tabular-nums;
    background: #fff;
    padding: 4px 12px;
    border-radius: 6px;
    border: 1px solid #ffcccc;
}
.flash-card {
    border: 2px solid #ffcccc !important;
    transition: box-shadow 0.2s;
}
.flash-card:hover {
    box-shadow: 0 4px 16px rgba(231,76,60,0.2);
}
.flash-card .card-img {
    height: 140px;
}
.flash-stock {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.78rem;
    color: #e74c3c;
}
.stock-bar {
    display: inline-block;
    width: 40px;
    height: 4px;
    background: #ffe0e0;
    border-radius: 2px;
    overflow: hidden;
    vertical-align: middle;
}
.stock-fill {
    display: block;
    height: 100%;
    background: #e74c3c;
    border-radius: 2px;
}
.flash-waiting {
    text-align: center;
    padding: 40px 0;
    color: #888;
}
.flash-waiting p {
    font-size: 1rem;
}
.flash-countdown-sm {
    font-variant-numeric: tabular-nums;
}

/* ========== 侧边悬浮单元 ========== */
#spContainer {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 0;
    z-index: 999;
}
.sp-item:hover {
    opacity: 0.9;
}
