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

body {
    font-family: 'Arial', sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f8f9fa;
}

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

/* Header */
.navbar {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 0.8rem 0;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 20px rgba(0,0,0,0.15);
    backdrop-filter: blur(10px);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
}

.logo h2 {
    color: white;
    font-size: 1.6rem;
    font-weight: bold;
    margin: 0;
}

.logo h2 a {
    color: white;
    text-decoration: none;
    transition: color 0.3s ease;
}

.logo h2 a:hover {
    color: #ffd700;
}

/* 汉堡菜单按钮 */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
    padding: 5px;
    background: none;
    border: none;
}

.mobile-menu-toggle span {
    width: 25px;
    height: 3px;
    background: white;
    margin: 3px 0;
    transition: 0.3s;
    border-radius: 2px;
}

.mobile-menu-toggle.active span:nth-child(1) {
    transform: rotate(-45deg) translate(-5px, 6px);
}

.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
    transform: rotate(45deg) translate(-5px, -6px);
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 1.5rem;
    align-items: center;
    margin: 0;
}

.nav-menu li {
    position: relative;
}

.nav-menu a {
    color: white;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    padding: 0.5rem 0;
    position: relative;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -2px;
    left: 50%;
    background: #ffd700;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.nav-menu a:hover::after {
    width: 100%;
}

.nav-menu a:hover {
    color: #ffd700;
}

/* 余额显示样式 */
.balance-display {
    background: rgba(255,255,255,0.15);
    padding: 0.4rem 1rem;
    border-radius: 20px;
    border: 1px solid rgba(255,255,255,0.2);
    color: #ffd700;
    font-weight: 600;
    font-size: 0.9rem;
}

.login-btn, .register-btn {
    background: rgba(255,255,255,0.15);
    padding: 0.5rem 1.2rem;
    border-radius: 25px;
    border: 1px solid rgba(255,255,255,0.3);
    transition: all 0.3s ease;
    font-size: 0.9rem;
}

.login-btn:hover, .register-btn:hover {
    background: rgba(255,255,255,0.25);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 120px 0 80px;
    text-align: center;
    min-height: 100vh;
    display: flex;
    align-items: center;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 20px;
}

.hero h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
    font-weight: bold;
}

.subtitle {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    opacity: 0.9;
}

.description {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.service-title {
    font-size: 2rem;
    margin-bottom: 2rem;
    color: #ffd700;
}

.cta-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.btn {
    padding: 12px 30px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: bold;
    transition: all 0.3s ease;
    display: inline-block;
    border: none;
    cursor: pointer;
}

.btn-primary {
    background: #ffd700;
    color: #333;
}

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

.btn-secondary {
    background: transparent;
    color: white;
    border: 2px solid white;
}

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

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

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

/* Features Section */
.features {
    padding: 80px 0;
    background: white;
}

.features h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: #333;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.feature-card {
    text-align: center;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-5px);
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

/* Services Section */
.services {
    padding: 80px 0;
    background: #f8f9fa;
}

.services h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 2rem;
    color: #333;
}

.service-categories {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 3rem;
    flex-wrap: wrap;
}

.category-btn, .tab-btn {
    padding: 10px 20px;
    background: white;
    border: 2px solid #667eea;
    border-radius: 25px;
    color: #667eea;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.3s ease;
}

.category-btn.active,
.category-btn:hover,
.tab-btn.active,
.tab-btn:hover {
    background: #667eea;
    color: white;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

/* Service Item Styles */
.service-item {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
    border: 1px solid #eee;
}

.service-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.service-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.service-header h3 {
    color: #333;
    font-size: 1.3rem;
    margin: 0;
}

.service-id {
    background: #667eea;
    color: white;
    padding: 0.3rem 0.8rem;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: bold;
}

.service-price {
    font-size: 1.8rem;
    font-weight: bold;
    color: #667eea;
    margin-bottom: 1rem;
    text-align: center;
}

.service-details {
    background: #f8f9fa;
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1rem;
}

.service-details p {
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    color: #666;
}

.service-details p:last-child {
    margin-bottom: 0;
}

.service-description {
    color: #666;
    margin-bottom: 1.5rem;
    line-height: 1.5;
    font-size: 0.95rem;
}

.order-form {
    border-top: 1px solid #eee;
    padding-top: 1.5rem;
}

.order-input {
    width: 100%;
    padding: 12px;
    border: 2px solid #ddd;
    border-radius: 5px;
    font-size: 1rem;
    margin-bottom: 1rem;
    transition: border-color 0.3s ease;
}

.order-input:focus {
    outline: none;
    border-color: #667eea;
}

.order-btn {
    width: 100%;
    padding: 12px;
    background: #667eea;
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 1rem;
    font-weight: bold;
    cursor: pointer;
    transition: background 0.3s ease;
}

.order-btn:hover {
    background: #5a6fd8;
}

.no-services {
    text-align: center;
    padding: 3rem;
    color: #666;
    background: white;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.service-card {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
    text-align: center;
}

.service-card:hover {
    transform: translateY(-5px);
}

.service-card h3 {
    color: #333;
    margin-bottom: 1rem;
    font-size: 1.3rem;
}

.service-price {
    font-size: 1.5rem;
    font-weight: bold;
    color: #667eea;
    margin-bottom: 1rem;
}

.service-description {
    color: #666;
    margin-bottom: 1.5rem;
    line-height: 1.5;
}

.service-details {
    background: #f8f9fa;
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
}

.service-details p {
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    color: #666;
}

.service-details p:last-child {
    margin-bottom: 0;
}

.feature-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: #333;
}

.feature-card p {
    color: #666;
    line-height: 1.6;
}

/* Services Preview */
.services-preview {
    padding: 80px 0;
    background: #f8f9fa;
}

.services-preview h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: #333;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.service-card {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    text-align: center;
    transition: transform 0.3s ease;
}

.service-card:hover {
    transform: translateY(-5px);
}

.service-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: #333;
}

.price {
    font-size: 2rem;
    font-weight: bold;
    color: #667eea;
    margin-bottom: 1rem;
}

.service-card ul {
    list-style: none;
    margin-bottom: 2rem;
}

.service-card li {
    padding: 0.5rem 0;
    color: #666;
    border-bottom: 1px solid #eee;
}

.service-card li:last-child {
    border-bottom: none;
}

/* Footer */
footer {
    background: #333;
    color: white;
    padding: 3rem 0 1rem;
}

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

.footer-section h3 {
    margin-bottom: 1rem;
    color: #ffd700;
}

.footer-section p {
    margin-bottom: 0.5rem;
    color: #ccc;
}

.footer-section a {
    color: #ccc;
    text-decoration: none;
}

.footer-section a:hover {
    color: #ffd700;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid #555;
    color: #ccc;
}

/* Form Styles */
.form-container {
    max-width: 400px;
    margin: 120px auto 50px;
    padding: 2rem;
    background: white;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.form-container h2 {
    text-align: center;
    margin-bottom: 2rem;
    color: #333;
}

.form-group {
    margin-bottom: 1rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: #333;
    font-weight: 500;
}

.form-group input {
    width: 100%;
    padding: 12px;
    border: 2px solid #ddd;
    border-radius: 5px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

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

.form-submit {
    width: 100%;
    padding: 12px;
    background: #667eea;
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 1rem;
    font-weight: bold;
    cursor: pointer;
    transition: background 0.3s ease;
}

.form-submit:hover {
    background: #5a6fd8;
}

.form-links {
    text-align: center;
    margin-top: 1rem;
}

.form-links a {
    color: #667eea;
    text-decoration: none;
}

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

/* Admin Styles */
.admin-container {
    max-width: 1200px;
    margin: 120px auto 50px;
    padding: 2rem;
}

.admin-header {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    margin-bottom: 2rem;
}

.admin-nav {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.admin-nav button {
    padding: 10px 20px;
    background: #667eea;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background 0.3s ease;
}

.admin-nav button:hover {
    background: #5a6fd8;
}

.admin-nav button.active {
    background: #ffd700;
    color: #333;
}

.admin-section {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    margin-bottom: 2rem;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1rem;
}

.admin-table th,
.admin-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

.admin-table th {
    background: #f8f9fa;
    font-weight: bold;
}

.status-pending {
    color: #ffa500;
    font-weight: bold;
}

.status-completed {
    color: #28a745;
    font-weight: bold;
}

.status-cancelled {
    color: #dc3545;
    font-weight: bold;
}

/* Alert Styles */
.alert {
    padding: 1rem;
    border-radius: 5px;
    margin-bottom: 1rem;
    border: 1px solid transparent;
}

.alert-success {
    background: #d4edda;
    color: #155724;
    border-color: #c3e6cb;
}

.alert-error {
    background: #f8d7da;
    color: #721c24;
    border-color: #f5c6cb;
}

.alert-warning {
    background: #fff3cd;
    color: #856404;
    border-color: #ffeaa7;
}

.alert-info {
    background: #d1ecf1;
    color: #0c5460;
    border-color: #bee5eb;
}



@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes modalSlideIn {
    from { opacity: 0; transform: scale(0.8); }
    to { opacity: 1; transform: scale(1); }
}

/* Responsive */
@media (max-width: 768px) {
    .mobile-menu-toggle {
        display: flex;
    }
    
    .nav-menu {
        position: fixed;
        top: 100%;
        left: 0;
        width: 100%;
        background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
        flex-direction: column;
        gap: 0;
        padding: 1rem 0;
        box-shadow: 0 4px 20px rgba(0,0,0,0.2);
        transform: translateY(-100%);
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
        z-index: 999;
    }
    
    .nav-menu.active {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }
    
    .nav-menu li {
        width: 100%;
        text-align: center;
        border-bottom: 1px solid rgba(255,255,255,0.1);
    }
    
    .nav-menu li:last-child {
        border-bottom: none;
    }
    
    .nav-menu a {
        display: block;
        padding: 1rem 2rem;
        width: 100%;
    }
    
    .nav-menu a::after {
        display: none;
    }
    
    .balance-display {
        margin: 0.5rem 2rem;
        text-align: center;
        display: block;
    }
    
    .login-btn, .register-btn {
        margin: 0.5rem 2rem;
        text-align: center;
        display: block;
    }
    
    .navbar {
        padding: 0.6rem 0;
    }
    
    .logo h2 {
        font-size: 1.4rem;
    }
    
    .hero {
        padding: 100px 0 60px;
    }
    
    .hero h1 {
        font-size: 2rem;
    }
    
    .service-title {
        font-size: 1.5rem;
    }
    
    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .features-grid,
    .services-grid {
        grid-template-columns: 1fr;
    }
    
    .admin-nav {
        flex-direction: column;
    }
    
    .categories-tabs {
        gap: 0.5rem;
        justify-content: flex-start;
        overflow-x: auto;
        padding: 0 1rem;
    }
    
    .category-tab {
        padding: 0.8rem 1.5rem;
        font-size: 0.9rem;
        white-space: nowrap;
    }
    
    .products-grid {
        grid-template-columns: 1fr;
    }
    
    .product-card {
        padding: 1.5rem;
    }
    
    .modal-content {
        padding: 1.5rem;
        margin: 1rem;
    }
    
    .modal-buttons {
        flex-direction: column;
    }
    
    .container {
        padding: 0 15px;
    }
}

/* 平板适配 */
@media (max-width: 1024px) and (min-width: 769px) {
    .nav-menu {
        gap: 1rem;
    }
    
    .logo h2 {
        font-size: 1.5rem;
    }
    
    .categories-tabs {
        gap: 0.8rem;
    }
}

/* 超小屏幕适配 */
@media (max-width: 480px) {
    .navbar {
        padding: 0.5rem 0;
    }
    
    .nav-container {
        padding: 0 15px;
    }
    
    .logo h2 {
        font-size: 1.2rem;
    }
    
    .hero h1 {
        font-size: 1.8rem;
    }
    
    .btn {
        padding: 10px 20px;
        font-size: 0.9rem;
    }
    
    .categories-tabs {
        padding: 0 10px;
    }
    
    .category-tab {
        padding: 0.6rem 1rem;
        font-size: 0.8rem;
    }
}