/* Common styles */
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans", Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji";
  max-width: 800px;
  margin: 0 auto;
  padding: 20px;
  background-color: #f5f5f5;
}

.container {
  background-color: white;
  padding: 30px;
  border-radius: 10px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.container.header {
  margin-bottom: 20px;
  padding: 15px 30px;
}

.header-flex {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}

.header-flex h1 {
  margin: 0;
  font-size: 24px;
}

h1 {
  color: #333;
  text-align: center;
  margin-top: 0;
}

h1 a {
  color: #333;
  text-decoration: none;
}

.kuma-image-box {
  max-width: 300px;
  margin: 0 auto 20px;
}

.kuma-image {
  max-width: 100%;
  margin: 0 auto;
}

/* User info section */
.user-info {
  padding: 4px 0;
  border-radius: 5px;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin: 0 0 0 auto;
}

.user-info-status {
  color: #555;
  font-size: 14px;
  border-radius: 5px;
  padding: 5px 10px;
  background-color: #e0e0e0;
}

.user-info-avater {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  vertical-align: middle;
}

.btn-logout-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s ease-in-out;
  position: relative;
}

.btn-logout-icon:hover {
  transform: scale(1.1);
}

.btn-logout-icon:hover::after {
  content: "ログアウト";
  position: absolute;
  bottom: -30px;
  left: 50%;
  transform: translateX(-50%);
  background-color: rgba(0, 0, 0, 0.8);
  color: white;
  padding: 5px 10px;
  border-radius: 4px;
  font-size: 12px;
  white-space: nowrap;
  z-index: 10;
  pointer-events: none;
}

.btn-logout-icon:hover::before {
  content: "";
  position: absolute;
  bottom: -5px;
  left: 50%;
  transform: translateX(-50%);
  border-width: 5px;
  border-style: solid;
  border-color: transparent transparent rgba(0, 0, 0, 0.8) transparent;
  z-index: 10;
  pointer-events: none;
}

.logout-icon {
  width: 30px;
  height: 30px;
  filter: invert(21%) sepia(100%) saturate(6467%) hue-rotate(347deg) brightness(94%) contrast(93%);
}

/* Form elements */
.form-group {
  margin-bottom: 20px;
}

label {
  display: block;
  margin-bottom: 5px;
  font-weight: bold;
}

input[type="file"],
input[type="text"],
textarea,
select {
  width: 100%;
  padding: 10px;
  border: 1px solid #ddd;
  border-radius: 5px;
  box-sizing: border-box;
}

textarea {
  height: 80px;
  resize: vertical;
}

/* Buttons */
.btn {
  border: none;
  padding: 12px 24px;
  border-radius: 5px;
  font-size: 16px;
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
  transition: background-color 0.3s;
}

.btn-primary {
  background-color: #28a745;
  color: white;
}

.btn-primary:hover {
  background-color: #218838;
}

.btn-secondary {
  background-color: #6c757d;
  color: white;
}

.btn-secondary:hover {
  background-color: #5a6268;
}

.btn-discord {
  background-color: #5865f2;
  color: white;
}

.btn-discord:hover {
  background-color: #3f4bd7;
}

.btn-logout {
  background-color: #dc3545;
  color: white;
}

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

.btn-primary:disabled {
  background-color: #6c757d;
  cursor: not-allowed;
}

.full-width {
  width: 100%;
}

/* Checkbox styles */
.checkbox-container {
  display: block;
  position: relative;
  padding-left: 30px;
  margin-bottom: 12px;
  cursor: pointer;
  user-select: none;
  font-weight: normal;
  line-height: 22px;
}

.checkbox-container input {
  position: absolute;
  opacity: 0;
  cursor: pointer;
  height: 0;
  width: 0;
}

.checkmark {
  position: absolute;
  top: 0;
  left: 0;
  height: 20px;
  width: 20px;
  background-color: #eee;
  border: 1px solid #ccc;
  border-radius: 3px;
}

.checkbox-container:hover input~.checkmark {
  background-color: #ccc;
}

.checkbox-container input:checked~.checkmark {
  background-color: #2196F3;
  border-color: #2196F3;
}

.checkmark:after {
  content: "";
  position: absolute;
  display: none;
}

.checkbox-container input:checked~.checkmark:after {
  display: block;
}

.checkbox-container .checkmark:after {
  left: 6px;
  top: 2px;
  width: 5px;
  height: 10px;
  border: solid white;
  border-width: 0 3px 3px 0;
  transform: rotate(45deg);
}

/* Success/Error messages */
.success {
  background-color: #d4edda;
  color: #155724;
  padding: 15px;
  border-radius: 5px;
  margin-bottom: 20px;
  border: 1px solid #c3e6cb;
}

.error {
  background-color: #f8d7da;
  color: #721c24;
  padding: 15px;
  border-radius: 5px;
  margin-bottom: 20px;
  border: 1px solid #f5c6cb;
}

.footer {
  text-align: center;
  margin-top: 20px;
}

/* Image preview */
#imagePreview {
  max-width: 100%;
  max-height: 400px;
  margin-top: 20px;
  display: none;
  border-radius: 5px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

/* Loading state */
#uploadStatus {
  margin-top: 20px;
  padding: 10px;
  border-radius: 5px;
  display: none;
}

#uploadStatus.uploading {
  background-color: #cfe2ff;
  color: #004085;
  border: 1px solid #b6d4fe;
}

#uploadStatus.success {
  background-color: #d1e7dd;
  color: #0f5132;
  border: 1px solid #badbcc;
}

#uploadStatus.error {
  background-color: #f8d7da;
  color: #842029;
  border: 1px solid #f5c2c7;
}
