:root {
  --bg: #f6f7f9;
  --surface: #ffffff;
  --text: #1f1f1f;
  --muted: #666666;
  --brand: #e1292f;
  --brand-dark: #af2328;
  --danger: #b42318;
  --border: #aaaaaa;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Verdana, Geneva, Tahoma, sans-serif;
}

b {
  color: gray;
}

.pay-shell {
  max-width: 480px;
  margin: 20px auto;
  padding: 15px;
  border-radius: 10px;
  background: var(--surface);
  box-shadow: 0 0 10px #0001;
}

.brand-head {
  margin-bottom: 10px;
  padding: 12px;
  border-radius: 10px;
  background: #000;
  text-align: center;
}

.brand-logo {
  display: block;
  width: 100%;
  max-width: 380px;
  margin: 0 auto;
  height: auto;
}

label {
  display: block;
  margin-bottom: 8px;
  font-size: 0.9rem;
}

.block-fieldset {
  margin: 0;
  padding: 20px;
  border: solid 1px silver;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  transition: box-shadow 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}

.block-fieldset:hover {
  border-color: #bdbdbd;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.14);
  transform: translateY(-1px);
}

.block-fieldset legend {
  padding: 0 6px;
  font-size: 0.9rem;
  color: #444;
}

.row {
  display: block;
}

.resolve-row {
  display: flex;
  align-items: stretch;
  justify-content: center;
  gap: 6px;
}

.amount-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

input[type="text"],
input[type="number"] {
  width: 100%;
  border: 1px solid #aaa;
  border-radius: 12px;
  padding: 6px;
  font-size: 34px;
  border-radius: 6px;
}

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

button {
  border: none;
  border-radius: 6px;
  padding: 8px;
  margin-top: 6px;
  width: 100%;
  font-size: 14px;
  cursor: pointer;
  color: white;
  background: var(--brand);
}

button:hover {
  background: var(--brand-dark);
}

button:active {
  transform: none;
}

#pay-btn {
  margin-top: 0;
  width: 52px;
  min-width: 52px;
  height: 52px;
  padding: 0;
  font-size: 24px;
  align-self: center;
}

.pay-btn-icon {
  width: 30px;
  height: 20px;
  display: block;
  margin: auto;
}

.checkbox {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
  font-size: 0.9rem;
}

.recommendations {
  display: grid;
  gap: 10px;
}

.recommendation-option {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 0;
  padding: 12px 14px;
  border: 1px solid #d4d4d4;
  border-radius: 12px;
  background: #fbfbfb;
  cursor: pointer;
}

.recommendation-option:has(input:checked) {
  border-color: var(--brand);
  background: #fff4f4;
}

.recommendation-option input[type="radio"] {
  margin: 3px 0 0;
}

.recommendation-copy {
  display: grid;
  gap: 3px;
}

.recommendation-title {
  font-size: 0.95rem;
  font-weight: bold;
  color: var(--text);
}

.recommendation-amount {
  display: block;
  margin-top: 2px;
  font-weight: normal;
}

.recommendation-description {
  font-size: 0.82rem;
  color: var(--muted);
}

#status {
  margin-top: 8px;
  min-height: 20px;
  text-align: left;
  font-weight: normal;
  font-size: 0.95rem;
  white-space: pre-line;
}

#status.error {
  color: var(--danger);
}

.hidden {
  display: none;
}

.helper {
  margin: 10px 0 0;
  font-size: 0.8rem;
  text-align: center;
  color: var(--muted);
}

.account-input,
.amount-input {
  margin-top: 0;
  flex: 0 0 200px;
  width: 200px;
  max-width: 200px;
  font-size: 34px;
  line-height: 1;
  letter-spacing: 0.08em;
  text-align: center;
  font-weight: bold;
  padding: 10px 8px;
}

.resolve-submit {
  margin-top: 0;
  width: 52px;
  min-width: 52px;
  font-size: 24px;
  font-weight: bold;
  padding: 0;
}

@media (max-width: 640px) {
  .pay-shell {
    margin: 12px;
  }

  .row {
    display: flex;
  }

  .resolve-row {
    display: flex;
  }

  .account-input {
    font-size: 30px;
  }

  .amount-input {
    font-size: 30px;
  }
}
