:root {
  --bg-a: #f4f0e8;
  --bg-b: #e1d3b8;
  --card: #fff8ed;
  --ink: #2a1f15;
  --accent: #c44f24;
  --accent-dark: #9e3f1d;
  --danger: #8f2d21;
  --line: #d8c8ad;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  color: var(--ink);
  background: radial-gradient(circle at 20% 20%, var(--bg-a), var(--bg-b));
  display: grid;
  place-items: center;
  padding: 24px;
}

.background-shape {
  position: fixed;
  width: 60vw;
  height: 60vw;
  max-width: 720px;
  max-height: 720px;
  border-radius: 50%;
  background: linear-gradient(120deg, #e7c9a1, #d98d5a);
  filter: blur(80px);
  opacity: 0.35;
  z-index: -1;
  animation: drift 12s ease-in-out infinite;
}

@keyframes drift {
  0% {
    transform: translate(-8%, -6%) scale(1);
  }
  50% {
    transform: translate(8%, 6%) scale(1.08);
  }
  100% {
    transform: translate(-8%, -6%) scale(1);
  }
}

.card {
  width: min(820px, 100%);
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: 0 14px 35px rgba(69, 39, 14, 0.2);
  padding: 24px;
}

.card.small {
  width: min(460px, 100%);
}

.top-bar {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: start;
  margin-bottom: 20px;
}

.auth-box {
  display: flex;
  flex-direction: column;
  gap: 8px;
  text-align: right;
}

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

input,
textarea,
button {
  font: inherit;
}

input,
textarea {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 10px 12px;
  background: #fff;
}

button {
  border: none;
  border-radius: 10px;
  padding: 10px 14px;
  background: var(--accent);
  color: #fff;
  font-weight: 600;
  cursor: pointer;
}

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

.status {
  min-height: 20px;
  margin-top: 12px;
}

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

.hint {
  margin-top: 0;
  color: #584131;
}

@media (max-width: 700px) {
  .card {
    padding: 18px;
  }

  .top-bar {
    flex-direction: column;
    align-items: stretch;
  }

  .auth-box {
    text-align: left;
  }
}
