* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Microsoft YaHei', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    min-height: 100vh;
    color: #fff;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.header {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 20px 30px;
    margin-bottom: 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.header h1 {
    font-size: 28px;
    background: linear-gradient(90deg, #ff6b6b, #ffd93d);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 0 30px rgba(255, 107, 107, 0.5);
}

.user-info {
    display: flex;
    align-items: center;
    gap: 20px;
}

#pointsDisplay {
    background: linear-gradient(90deg, #ffd93d, #ff6b6b);
    padding: 8px 15px;
    border-radius: 20px;
    font-weight: bold;
}

.btn {
    padding: 10px 25px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
    font-weight: bold;
    transition: all 0.3s ease;
    text-transform: uppercase;
}

.btn-primary {
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(102, 126, 234, 0.4);
}

.btn-admin {
    background: linear-gradient(90deg, #f093fb 0%, #f5576c 100%);
    color: white;
}

.btn-admin:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(245, 87, 108, 0.4);
}

.btn-small {
    padding: 5px 15px;
    font-size: 14px;
    background: rgba(255, 255, 255, 0.2);
    color: white;
}

.btn-small:hover {
    background: rgba(255, 255, 255, 0.3);
}

.auth-container {
    max-width: 450px;
    margin: 50px auto;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 30px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.auth-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 30px;
}

.auth-tab {
    flex: 1;
    padding: 12px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: #fff;
    cursor: pointer;
    border-radius: 8px;
    transition: all 0.3s ease;
    font-size: 14px;
}

.auth-tab.active {
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
}

.auth-tab:hover:not(.active) {
    background: rgba(255, 255, 255, 0.2);
}

.auth-form h2 {
    text-align: center;
    margin-bottom: 25px;
    color: #ffd93d;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #ccc;
    font-size: 14px;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    font-size: 16px;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: #667eea;
    background: rgba(255, 255, 255, 0.15);
}

.form-group input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.auth-form .btn {
    width: 100%;
    margin-top: 10px;
}

.nav-tabs {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
    background: rgba(255, 255, 255, 0.1);
    padding: 15px;
    border-radius: 10px;
}

.nav-tab {
    padding: 12px 25px;
    background: transparent;
    border: 2px solid rgba(255, 255, 255, 0.2);
    color: #fff;
    cursor: pointer;
    border-radius: 8px;
    transition: all 0.3s ease;
    font-size: 15px;
}

.nav-tab.active {
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    border-color: transparent;
}

.nav-tab:hover:not(.active) {
    background: rgba(255, 255, 255, 0.1);
    border-color: #667eea;
}

.tab-content {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 30px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.tab-content h2 {
    margin-bottom: 25px;
    color: #ffd93d;
    font-size: 24px;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 25px;
}

.product-card {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.product-card:hover {
    transform: translateY(-5px);
    border-color: #667eea;
    box-shadow: 0 10px 30px rgba(102, 126, 234, 0.3);
}

.product-image {
    width: 100%;
    height: 150px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 60px;
    margin-bottom: 15px;
}

.product-name {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 10px;
    color: #fff;
}

.product-desc {
    font-size: 14px;
    color: #aaa;
    margin-bottom: 15px;
    min-height: 40px;
}

.product-points {
    font-size: 20px;
    font-weight: bold;
    color: #ffd93d;
    margin-bottom: 15px;
}

.product-stock {
    font-size: 12px;
    color: #aaa;
    margin-bottom: 15px;
}

.product-stock.low {
    color: #ff6b6b;
}

.product-stock.in-stock {
    color: #6bff6b;
}

.product-card.out-of-stock {
    opacity: 0.6;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

.data-table th,
.data-table td {
    padding: 15px;
    text-align: left;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.data-table th {
    background: rgba(102, 126, 234, 0.3);
    color: #ffd93d;
    font-weight: bold;
}

.data-table tr:hover {
    background: rgba(255, 255, 255, 0.05);
}

.profile-card {
    max-width: 500px;
    margin: 0 auto;
}

.profile-card input:disabled {
    background: rgba(255, 255, 255, 0.05);
    color: #aaa;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 12px;
    padding: 25px;
    text-align: center;
}

.stat-card h3 {
    font-size: 16px;
    margin-bottom: 10px;
    opacity: 0.9;
}

.stat-card .stat-value {
    font-size: 36px;
    font-weight: bold;
}

.db-info {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 12px;
    padding: 20px;
    font-family: 'Courier New', monospace;
}

.db-info p {
    margin-bottom: 10px;
}

.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal-content {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    border-radius: 15px;
    padding: 30px;
    max-width: 500px;
    width: 90%;
    position: relative;
}

.close {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 30px;
    cursor: pointer;
    color: #aaa;
}

.close:hover {
    color: #fff;
}

.toast {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    padding: 15px 30px;
    border-radius: 10px;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-weight: bold;
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 2000;
}

.toast.show {
    opacity: 1;
}

.toast.error {
    background: linear-gradient(90deg, #f5576c 0%, #f093fb 100%);
}

.toast.success {
    background: linear-gradient(90deg, #11998e 0%, #38ef7d 100%);
}

.action-btn {
    padding: 5px 12px;
    margin: 0 3px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 12px;
}

.action-btn.edit {
    background: #667eea;
    color: white;
}

.action-btn.delete {
    background: #f5576c;
    color: white;
}

.action-btn.redeem {
    background: #38ef7d;
    color: #1a1a2e;
}

.category-badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 15px;
    font-size: 12px;
    background: rgba(102, 126, 234, 0.3);
}

.category-badge.weapon {
    background: rgba(245, 87, 108, 0.3);
}

.category-badge.character {
    background: rgba(56, 239, 125, 0.3);
}

.category-badge.currency {
    background: rgba(255, 217, 61, 0.3);
}

.category-badge.grenade {
    background: rgba(240, 147, 251, 0.3);
}

@media (max-width: 768px) {
    .header {
        flex-direction: column;
        gap: 15px;
    }

    .nav-tabs {
        flex-wrap: wrap;
    }

    .products-grid {
        grid-template-columns: 1fr;
    }

    .auth-tabs {
        flex-direction: column;
    }
}