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

body {
  font-family: 'Arial', sans-serif;
  background-color: #f5f5f5;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
}

.container {
  background-color: white;
  border-radius: 10px;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.1);
  padding: 30px;
  width: 100%;
  max-width: 400px;
}

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

h2 {
  color: #333;
  margin-bottom: 20px;
  font-size: 18px;
}

input {
  width: 100%;
  padding: 12px;
  margin-bottom: 15px;
  border: 1px solid #ddd;
  border-radius: 5px;
  font-size: 16px;
}

button {
  width: 100%;
  padding: 12px;
  background-color: #4CAF50;
  color: white;
  border: none;
  border-radius: 5px;
  font-size: 16px;
  cursor: pointer;
  transition: background-color 0.3s;
}

button:hover {
  background-color: #45a049;
}

button:disabled {
  background-color: #cccccc;
  cursor: not-allowed;
}

#login-message, #exchange-message {
  margin-top: 15px;
  text-align: center;
  padding: 10px;
  border-radius: 5px;
  font-size: 14px;
}

.success {
  background-color: #d4edda;
  color: #155724;
  border: 1px solid #c3e6cb;
}

.error {
  background-color: #f8d7da;
  color: #721c24;
  border: 1px solid #f5c6cb;
}

#send-code {
  margin-bottom: 15px;
}

#code {
  margin-bottom: 15px;
}

.test-section {
  margin-top: 30px;
  padding-top: 20px;
  border-top: 1px solid #eee;
}

.test-section h3 {
  color: #666;
  margin-bottom: 15px;
  font-size: 16px;
}

#generated-codes {
  margin-top: 15px;
  padding: 10px;
  background-color: #f9f9f9;
  border-radius: 5px;
  font-family: monospace;
  font-size: 14px;
  white-space: pre-wrap;
  word-break: break-all;
}

/* 会员状态样式 */
.member-status {
  margin-bottom: 20px;
  padding: 15px;
  border-radius: 8px;
  background-color: #f8f9fa;
  border: 1px solid #e9ecef;
}

.member-active {
  border-left: 4px solid #4CAF50;
}

.member-inactive {
  border-left: 4px solid #ff9800;
}

.member-status h3 {
  margin: 0 0 10px 0;
  color: #333;
  font-size: 16px;
}

.status-text {
  margin: 5px 0;
  font-size: 14px;
  color: #666;
}

.status-active {
  color: #4CAF50;
  font-weight: bold;
}

.status-inactive {
  color: #ff9800;
  font-weight: bold;
}

.expiry-date {
  margin: 5px 0;
  font-size: 13px;
  color: #888;
}

.status-hint {
  margin: 5px 0;
  font-size: 13px;
  color: #888;
  font-style: italic;
}

/* 登出按钮样式 */
.logout-btn {
  margin-top: 20px;
  background-color: #f44336;
}

.logout-btn:hover {
  background-color: #d32f2f;
}

/* 响应式设计 */
@media (max-width: 480px) {
  .container {
    padding: 20px;
    margin: 10px;
  }
  
  h1 {
    font-size: 20px;
    margin-bottom: 20px;
  }
  
  h2 {
    font-size: 16px;
    margin-bottom: 15px;
  }
  
  input {
    padding: 10px;
    font-size: 14px;
  }
  
  button {
    padding: 10px;
    font-size: 14px;
  }
  
  .member-status {
    padding: 10px;
  }
  
  .test-section {
    margin-top: 20px;
    padding-top: 15px;
  }
}

/* 动画效果 */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.member-status,
.test-section {
  animation: fadeIn 0.3s ease-in-out;
}

/* 输入框聚焦效果 */
input:focus {
  outline: none;
  border-color: #4CAF50;
  box-shadow: 0 0 0 2px rgba(76, 175, 80, 0.2);
  transition: all 0.3s ease;
}

/* 按钮点击效果 */
button:active {
  transform: translateY(1px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}