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

html {
    font-size: 14px;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background-color: #f5f5f5;
    color: #333;
    line-height: 1.6;
    min-width: 320px;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

.header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 12px 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 20px;
    font-weight: bold;
    white-space: nowrap;
}

.nav {
    display: flex;
    gap: 15px;
}

.nav-link {
    color: white;
    text-decoration: none;
    padding: 8px 12px;
    border-radius: 20px;
    transition: background 0.3s;
    font-size: 14px;
}

.nav-link:hover, .nav-link.active {
    background: rgba(255,255,255,0.2);
}

.user-actions {
    display: flex;
    gap: 10px;
}

.btn {
    padding: 10px 18px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    transition: all 0.3s;
    white-space: nowrap;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.btn-outline {
    background: transparent;
    color: #667eea;
    border: 2px solid #667eea;
}

.btn-outline:hover {
    background: #667eea;
    color: white;
}

.btn-lg {
    padding: 12px 28px;
    font-size: 16px;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 12px;
}

.btn-block {
    width: 100%;
}

.hero {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 60px 0;
    text-align: center;
}

.hero-title {
    font-size: 32px;
    margin-bottom: 15px;
}

.hero-subtitle {
    font-size: 16px;
    margin-bottom: 30px;
    opacity: 0.9;
}

.hero-actions {
    display: flex;
    justify-content: center;
    gap: 15px;
}

.services, .groups, .partner, .features {
    padding: 40px 0;
}

.section-title {
    text-align: center;
    font-size: 24px;
    margin-bottom: 30px;
    color: #333;
}

.service-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.service-card {
    background: white;
    border-radius: 14px;
    padding: 25px;
    text-align: center;
    box-shadow: 0 4px 12px rgba(0,0,0,0.06);
    transition: transform 0.3s, box-shadow 0.3s;
}

.service-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
}

.service-icon {
    font-size: 40px;
    margin-bottom: 12px;
}

.service-title {
    font-size: 18px;
    margin-bottom: 8px;
}

.service-desc {
    color: #666;
    font-size: 13px;
    margin-bottom: 15px;
}

.group-list, .partner-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.group-card, .partner-card {
    background: white;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0,0,0,0.06);
}

.group-header, .partner-header {
    padding: 15px;
    border-bottom: 1px solid #eee;
}

.group-tag {
    background: #ff6b6b;
    color: white;
    padding: 4px 10px;
    border-radius: 15px;
    font-size: 11px;
    margin-right: 8px;
}

.group-title, .partner-info h3 {
    font-size: 16px;
    margin-bottom: 4px;
}

.group-info {
    padding: 15px;
}

.group-desc {
    color: #666;
    font-size: 13px;
    margin-bottom: 12px;
}

.group-progress {
    margin-bottom: 12px;
}

.progress-bar {
    height: 6px;
    background: #eee;
    border-radius: 3px;
    overflow: hidden;
    margin-bottom: 4px;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #667eea, #764ba2);
    border-radius: 3px;
}

.progress-text {
    font-size: 12px;
    color: #666;
}

.group-price {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.price {
    font-size: 20px;
    color: #ff6b6b;
    font-weight: bold;
}

.original-price {
    text-decoration: line-through;
    color: #999;
    font-size: 13px;
}

.partner-avatar {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea, #764ba2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: white;
}

.partner-header {
    display: flex;
    align-items: center;
    gap: 12px;
}

.partner-info p {
    color: #999;
    font-size: 12px;
}

.partner-content {
    padding: 12px 15px;
    color: #666;
    font-size: 13px;
}

.partner-tags {
    padding: 0 15px 15px;
}

.tag {
    background: #f0f0f0;
    color: #666;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 11px;
    margin-right: 6px;
    margin-bottom: 5px;
    display: inline-block;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 20px;
}

.feature-item {
    text-align: center;
    padding: 20px;
}

.feature-icon {
    font-size: 32px;
    margin-bottom: 10px;
}

.feature-item h3 {
    font-size: 16px;
    margin-bottom: 8px;
}

.feature-item p {
    color: #666;
    font-size: 13px;
}

.footer {
    background: #333;
    color: white;
    padding: 30px 0 15px;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

.footer-col h4 {
    margin-bottom: 12px;
    font-size: 15px;
}

.footer-col ul {
    list-style: none;
}

.footer-col ul li {
    margin-bottom: 8px;
}

.footer-col a {
    color: #ccc;
    text-decoration: none;
    font-size: 13px;
}

.footer-col a:hover {
    color: white;
}

.footer-bottom {
    text-align: center;
    padding-top: 15px;
    border-top: 1px solid #444;
    color: #666;
    font-size: 12px;
}

.login-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 20px;
}

.login-box {
    background: white;
    padding: 30px;
    border-radius: 16px;
    box-shadow: 0 15px 40px rgba(0,0,0,0.15);
    width: 100%;
    max-width: 380px;
}

.login-title {
    text-align: center;
    font-size: 24px;
    margin-bottom: 20px;
    color: #333;
}

.login-subtitle {
    text-align: center;
    color: #999;
    margin-bottom: 25px;
    font-size: 14px;
}

.login-form {
    margin-bottom: 15px;
}

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

.form-group label {
    display: block;
    margin-bottom: 6px;
    font-weight: 500;
    font-size: 14px;
}

.form-group input, .form-group select, .form-group textarea {
    width: 100%;
    padding: 12px 14px;
    border: 2px solid #eee;
    border-radius: 10px;
    font-size: 14px;
    transition: border-color 0.3s;
}

.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
    outline: none;
    border-color: #667eea;
}

.form-hint {
    font-size: 11px;
    color: #999;
    margin-top: 4px;
}

.login-footer {
    text-align: center;
    color: #666;
    font-size: 13px;
}

.login-footer a {
    color: #667eea;
    text-decoration: none;
}

.wechat-login {
    margin: 15px 0;
}

.btn-wechat {
    background: #07c160;
    color: white;
    width: 100%;
    padding: 13px;
    font-size: 15px;
}

.btn-wechat:hover {
    background: #06ad56;
}

.alert {
    padding: 10px 12px;
    border-radius: 8px;
    margin-bottom: 15px;
    font-size: 13px;
}

.alert-danger {
    background: #ffebee;
    color: #c62828;
}

.alert-success {
    background: #e8f5e9;
    color: #2e7d32;
}

.user-header, .server-header, .order-header {
    background: white;
    padding: 12px 0;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

.user-header .container, .server-header .container, .order-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.user-info, .server-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-avatar, .server-avatar {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea, #764ba2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: white;
}

.user-detail h2, .server-detail h2 {
    font-size: 16px;
}

.user-detail p, .server-detail p {
    font-size: 12px;
    color: #999;
}

.back-btn {
    color: #667eea;
    text-decoration: none;
    font-weight: 500;
    font-size: 14px;
}

.user-stats, .server-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 15px;
    margin: 20px 0;
}

.stat-card {
    background: white;
    padding: 18px;
    border-radius: 14px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.06);
}

.stat-value {
    font-size: 24px;
    font-weight: bold;
    color: #667eea;
}

.stat-label {
    color: #666;
    margin: 4px 0;
    font-size: 13px;
}

.stat-link {
    color: #667eea;
    font-size: 12px;
}

.menu-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 15px;
}

.menu-item {
    background: white;
    padding: 20px 15px;
    border-radius: 14px;
    text-align: center;
    box-shadow: 0 4px 12px rgba(0,0,0,0.06);
    text-decoration: none;
    color: #333;
    transition: transform 0.3s;
}

.menu-item:hover {
    transform: translateY(-2px);
}

.menu-icon {
    font-size: 28px;
    margin-bottom: 8px;
}

.menu-item span {
    font-size: 13px;
}

.service-tabs, .order-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
    overflow-x: auto;
    padding-bottom: 8px;
}

.tab-item {
    padding: 8px 16px;
    background: white;
    border-radius: 20px;
    text-decoration: none;
    color: #666;
    white-space: nowrap;
    transition: all 0.3s;
    font-size: 13px;
    flex-shrink: 0;
}

.tab-item.active {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
}

.server-list, .order-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.server-card {
    background: white;
    padding: 18px;
    border-radius: 14px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.06);
    display: flex;
    align-items: center;
    gap: 15px;
    cursor: pointer;
    transition: box-shadow 0.3s;
}

.server-card:hover {
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
}

.server-info {
    flex: 1;
}

.server-name {
    font-size: 16px;
    margin-bottom: 6px;
}

.server-desc {
    color: #666;
    font-size: 13px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.server-price {
    text-align: right;
}

.server-price .price {
    font-size: 18px;
}

.order-card {
    background: white;
    padding: 18px;
    border-radius: 14px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.06);
}

.order-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 12px;
    padding-bottom: 12px;
    border-bottom: 1px solid #eee;
}

.order-no {
    font-size: 12px;
    color: #999;
}

.order-status {
    padding: 4px 10px;
    border-radius: 15px;
    font-size: 11px;
}

.order-status.pending {
    background: #fff3e0;
    color: #e65100;
}

.order-status.confirmed {
    background: #e3f2fd;
    color: #1565c0;
}

.order-status.completed {
    background: #e8f5e9;
    color: #2e7d32;
}

.order-status.cancelled {
    background: #fce4ec;
    color: #c2185b;
}

.order-content {
    display: flex;
    justify-content: space-between;
    margin-bottom: 12px;
}

.order-info p {
    color: #666;
    margin-bottom: 4px;
    font-size: 13px;
}

.order-actions {
    display: flex;
    gap: 8px;
}

.empty-state {
    text-align: center;
    padding: 40px 0;
}

.empty-icon {
    font-size: 48px;
    margin-bottom: 15px;
}

.empty-state p {
    color: #999;
    font-size: 14px;
}

.recharge-box, .withdraw-box, .price-form-box, .time-form-box {
    background: white;
    padding: 25px;
    border-radius: 14px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.06);
    max-width: 450px;
    margin: 20px auto;
}

.balance-info {
    text-align: center;
    margin-bottom: 25px;
}

.balance-info p {
    color: #666;
    margin-bottom: 4px;
    font-size: 14px;
}

.balance-amount {
    font-size: 36px;
    font-weight: bold;
    color: #667eea;
}

.amount-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 12px;
}

.amount-btn {
    padding: 10px 16px;
    background: #f5f5f5;
    border: 2px solid #eee;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 14px;
}

.amount-btn:hover {
    border-color: #667eea;
    background: #f0f4ff;
}

.payment-options {
    display: flex;
    gap: 15px;
}

.payment-option {
    flex: 1;
    padding: 12px;
    border: 2px solid #eee;
    border-radius: 8px;
    cursor: pointer;
    text-align: center;
    transition: all 0.3s;
}

.payment-option input[type="radio"] {
    display: none;
}

.payment-option:hover, .payment-option input[type="radio"]:checked ~ * {
    border-color: #667eea;
    background: #f0f4ff;
}

.payment-icon {
    font-size: 20px;
    display: block;
    margin-bottom: 6px;
}

.withdraw-history {
    margin-top: 25px;
    padding-top: 25px;
    border-top: 1px solid #eee;
}

.history-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 12px;
}

.history-table th, .history-table td {
    padding: 10px;
    text-align: left;
    border-bottom: 1px solid #eee;
    font-size: 13px;
}

.history-table th {
    background: #f9f9f9;
    font-weight: 500;
    font-size: 12px;
}

.status-tag {
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 11px;
}

.status-tag.active {
    background: #e8f5e9;
    color: #2e7d32;
}

.status-tag.frozen {
    background: #fce4ec;
    color: #c2185b;
}

.invite-card {
    background: white;
    padding: 25px;
    border-radius: 14px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.06);
    max-width: 450px;
    margin: 20px auto;
}

.invite-header {
    text-align: center;
    margin-bottom: 25px;
}

.invite-icon {
    font-size: 48px;
    margin-bottom: 12px;
}

.invite-code-box {
    text-align: center;
    padding: 18px;
    background: #f9f9f9;
    border-radius: 14px;
    margin-bottom: 25px;
}

.code-display {
    font-size: 24px;
    font-weight: bold;
    color: #667eea;
    letter-spacing: 4px;
    margin-bottom: 12px;
}

.invite-stats {
    display: flex;
    justify-content: space-around;
    margin-bottom: 25px;
}

.stat-item {
    text-align: center;
}

.stat-item .value {
    font-size: 20px;
    font-weight: bold;
    color: #667eea;
}

.stat-item .label {
    font-size: 12px;
    color: #999;
}

.invite-rules {
    background: #f9f9f9;
    padding: 18px;
    border-radius: 14px;
    margin-bottom: 25px;
}

.invite-rules h3 {
    margin-bottom: 12px;
    font-size: 15px;
}

.invite-rules ul {
    list-style: none;
    padding-left: 0;
}

.invite-rules li {
    padding: 6px 0;
    border-bottom: 1px solid #eee;
    font-size: 13px;
}

.invite-rules li:last-child {
    border-bottom: none;
}

.code-input-group {
    display: flex;
    gap: 8px;
}

.code-input-group input {
    flex: 1;
}

.order-summary {
    background: #f9f9f9;
    padding: 18px;
    border-radius: 14px;
    margin-bottom: 18px;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
}

.summary-row span {
    color: #666;
    font-size: 13px;
}

.summary-row .price {
    color: #333;
    font-size: 13px;
}

.summary-total {
    display: flex;
    justify-content: space-between;
    font-size: 16px;
    font-weight: bold;
    padding-top: 12px;
    border-top: 1px solid #eee;
}

.total-price {
    color: #ff6b6b;
}

.radio-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.radio-group label {
    cursor: pointer;
    font-size: 14px;
}

.form-section {
    margin-bottom: 25px;
    padding-bottom: 25px;
    border-bottom: 1px solid #eee;
}

.form-section:last-child {
    border-bottom: none;
}

.form-section h3 {
    margin-bottom: 18px;
    font-size: 16px;
}

.rest-days-select {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.day-checkbox {
    padding: 8px 16px;
    background: #f5f5f5;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 13px;
}

.day-checkbox input {
    display: none;
}

.day-checkbox:hover, .day-checkbox input:checked + span {
    background: #667eea;
    color: white;
}

.work-time-grid {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.work-time-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.day-label {
    width: 50px;
    font-size: 13px;
}

.separator {
    color: #999;
}

.time-form-box {
    max-width: 500px;
}

@media (max-width: 768px) {
    html {
        font-size: 13px;
    }
    
    .header {
        padding: 10px 0;
    }
    
    .logo {
        font-size: 18px;
    }
    
    .nav {
        display: none;
    }
    
    .hero {
        padding: 40px 0;
    }
    
    .hero-title {
        font-size: 24px;
    }
    
    .hero-subtitle {
        font-size: 14px;
    }
    
    .hero-actions {
        flex-direction: column;
        align-items: center;
        gap: 10px;
    }
    
    .services, .groups, .partner, .features {
        padding: 30px 0;
    }
    
    .section-title {
        font-size: 20px;
        margin-bottom: 20px;
    }
    
    .service-grid, .group-list, .partner-list, .feature-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .service-card {
        padding: 20px;
    }
    
    .service-icon {
        font-size: 32px;
    }
    
    .service-title {
        font-size: 16px;
    }
    
    .server-card {
        flex-direction: column;
        text-align: center;
    }
    
    .server-info {
        flex: none;
        text-align: center;
    }
    
    .server-desc {
        white-space: normal;
        overflow: visible;
    }
    
    .server-price {
        text-align: center;
        margin-top: 12px;
    }
    
    .order-content {
        flex-direction: column;
        gap: 12px;
    }
    
    .order-actions {
        flex-direction: column;
    }
    
    .payment-options {
        flex-direction: column;
    }
    
    .group-price {
        flex-direction: column;
        gap: 8px;
    }
    
    .footer-grid {
        gap: 15px;
    }
    
    .footer-col h4 {
        font-size: 14px;
    }
    
    .footer-col ul li {
        margin-bottom: 6px;
    }
    
    .footer-col a {
        font-size: 12px;
    }
    
    .login-box {
        padding: 25px;
    }
    
    .login-title {
        font-size: 22px;
    }
    
    .form-group input, .form-group select, .form-group textarea {
        padding: 10px 12px;
    }
    
    .btn {
        padding: 10px 16px;
    }
    
    .btn-lg {
        padding: 12px 24px;
        font-size: 15px;
    }
    
    .user-stats, .server-stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    
    .stat-card {
        padding: 15px;
    }
    
    .stat-value {
        font-size: 20px;
    }
    
    .menu-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 12px;
    }
    
    .menu-item {
        padding: 15px 10px;
    }
    
    .menu-icon {
        font-size: 24px;
    }
}

@media (max-width: 480px) {
    html {
        font-size: 12px;
    }
    
    .container {
        padding: 0 12px;
    }
    
    .hero {
        padding: 30px 0;
    }
    
    .hero-title {
        font-size: 20px;
    }
    
    .hero-subtitle {
        font-size: 13px;
    }
    
    .service-card {
        padding: 15px;
    }
    
    .service-icon {
        font-size: 28px;
    }
    
    .user-stats, .server-stats {
        grid-template-columns: 1fr;
    }
    
    .menu-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .menu-item {
        padding: 12px 8px;
    }
    
    .menu-icon {
        font-size: 22px;
    }
    
    .login-box {
        padding: 20px;
    }
    
    .login-title {
        font-size: 20px;
    }
    
    .btn {
        padding: 9px 14px;
        font-size: 13px;
    }
    
    .btn-lg {
        padding: 10px 20px;
        font-size: 14px;
    }
    
    .amount-btn {
        padding: 8px 12px;
        font-size: 13px;
    }
    
    .tab-item {
        padding: 6px 12px;
        font-size: 12px;
    }
}

@media (max-width: 360px) {
    .container {
        padding: 0 10px;
    }
    
    .logo {
        font-size: 16px;
    }
    
    .hero-title {
        font-size: 18px;
    }
    
    .service-icon {
        font-size: 24px;
    }
    
    .service-title {
        font-size: 14px;
    }
    
    .server-card {
        padding: 12px;
    }
    
    .order-card {
        padding: 12px;
    }
    
    .recharge-box, .withdraw-box, .price-form-box, .time-form-box {
        padding: 18px;
    }
}