* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: #0f1419;
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 16px;
  color: #d9d9d9;
}

a {
  color: #45dd92;
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.wrap {
  width: 100%;
  max-width: 770px;
  margin: 0 auto;
  padding: 0 12px;
}

.wrap.narrow {
  max-width: 520px;
  padding-top: 40px;
}

.columns {
  padding: 20px 0;
}

.main-col {
  width: 100%;
}

.box {
  background: #15212b;
  border: 1px solid #2f3b44;
  border-radius: 4px;
  padding: 14px;
  margin-bottom: 12px;
}

.box > h1:first-child,
.box > h2:first-child,
.box > h3:first-child {
  margin-top: 0;
}

.section-title {
  color: #e7e9ea;
  margin: 0 0 10px;
}

label {
  display: block;
  margin-bottom: 10px;
  font-weight: bold;
  color: #c7d0d6;
}

.checkbox-label {
  display: flex;
  align-items: flex-start;
  gap: 6px;
  font-weight: normal;
}

.checkbox-label input {
  margin-top: 4px;
  flex-shrink: 0;
}

.checkbox-label.radio-inline {
  align-items: center;
  flex-wrap: wrap;
}

.checkbox-label.radio-inline input[type="radio"] {
  margin-top: 0;
}

.rules-list {
  padding-left: 20px;
  margin: 10px 0 16px;
}

.rules-list li {
  margin-bottom: 8px;
  line-height: 1.4;
}

.stats-list {
  list-style: none;
  margin: 10px 0 0;
  padding: 0;
}

.stats-list li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 0;
  border-bottom: 1px solid #243140;
}

.stats-list li:last-child {
  border-bottom: none;
}

.stats-list span {
  color: #9fb6c2;
  text-align: right;
}

.yellow-card {
  background: #2e2810;
  border: 1px solid #e0a64a;
  border-left: 4px solid #e0a64a;
  border-radius: 4px;
  padding: 12px 14px;
  margin: 8px 0;
  color: #f0d9a6;
  font-size: 13px;
  line-height: 1.5;
}

.about-headline {
  font-size: 28px;
  font-style: italic;
  color: #fff;
  margin: 0 0 8px;
}

.about-subhead {
  font-size: 15px;
  color: #c7d0d6;
  margin: 0;
}

input[type="text"], input[type="password"], input[type="number"], textarea {
  width: 100%;
  padding: 7px;
  border: 1px solid #2f3b44;
  background: #0f1419;
  color: #e7e9ea;
  border-radius: 3px;
  font-family: inherit;
  font-size: 14px;
  margin-top: 4px;
}

input[type="text"]:focus, input[type="password"]:focus, input[type="number"]:focus, textarea:focus {
  outline: none;
  border-color: #2fe28a;
}

input[type="number"].input-inline {
  display: inline-block;
  width: 70px;
  margin: 0 4px;
}

select {
  width: 100%;
  padding: 7px;
  border: 1px solid #2f3b44;
  background: #0f1419;
  color: #e7e9ea;
  border-radius: 3px;
  font-family: inherit;
  font-size: 14px;
  margin-top: 4px;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath fill='%237e8d97' d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  background-size: 10px 6px;
  padding-right: 28px;
  cursor: pointer;
}

select:focus {
  outline: none;
  border-color: #2fe28a;
}

select.input-inline {
  display: inline-block;
  width: auto;
  margin: 0 4px;
}

textarea {
  resize: vertical;
  min-height: 50px;
}

small {
  display: block;
  color: #7e8d97;
  margin: -6px 0 10px;
}

.btn-primary {
  background: #2fe28a;
  color: #062919;
  border: none;
  border-radius: 4px;
  padding: 8px 16px;
  font-weight: bold;
  font-size: 14px;
  cursor: pointer;
}

.btn-primary:hover {
  background: #5eebab;
}

.btn-link {
  display: inline-block;
}

.btn-following {
  background: #1c2c38;
  color: #45dd92;
  border: 1px solid #2fe28a;
}

.btn-following:hover {
  background: #2c3e4a;
  color: #45dd92;
}

.btn-danger {
  background: #e0444d;
  color: #fff;
  border: none;
  border-radius: 4px;
  padding: 8px 16px;
  font-weight: bold;
  font-size: 14px;
  cursor: pointer;
}

.btn-danger:hover {
  background: #ff6b6b;
}

.box.danger-zone {
  border-color: #5c2026;
}

.settings-section p {
  color: #9fb6c2;
  font-size: 13px;
  margin: 0 0 10px;
}

.error {
  color: #ff6b6b;
  font-weight: bold;
}

.pagination {
  text-align: center;
  margin: 12px 0 30px;
}

.badge {
  background: #e0444d;
  color: #fff;
  border-radius: 8px;
  font-size: 10px;
  padding: 1px 5px;
  vertical-align: top;
}

.error-details {
  text-align: left;
  margin-top: 20px;
  padding: 12px;
  background: #0f1419;
  border: 1px solid #2f3b44;
  border-radius: 4px;
  color: #ff6b6b;
  font-size: 12px;
  line-height: 1.5;
  overflow-x: auto;
  white-space: pre-wrap;
  word-break: break-word;
}

.empty-state {
  color: #7e8d97;
  text-align: center;
}

@media (max-width: 600px) {
  body {
    /* Stop iOS Safari from auto-inflating text on rotate/zoom */
    -webkit-text-size-adjust: 100%;
  }

  .columns {
    padding: 12px 0;
  }

  .box {
    padding: 12px;
  }

  .about-headline {
    font-size: 23px;
  }

  /* Slightly larger tap targets on touch screens */
  .btn-primary,
  .btn-danger {
    padding: 10px 16px;
  }

  /* 16px font stops iOS Safari from zooming in when a field is focused */
  input[type="text"],
  input[type="password"],
  input[type="number"],
  textarea,
  select {
    font-size: 16px;
  }
}
