:root {
  color-scheme: light;
  font-family: "Segoe UI", Tahoma, Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: #f3f5f8;
  color: #111827;
  display: grid;
  place-items: center;
  padding: 1rem;
}

.app {
  width: min(680px, 100%);
  background: #ffffff;
  border-radius: 14px;
  padding: 1.25rem;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.08);
}

h1 {
  margin: 0 0 0.4rem;
  font-size: clamp(1.35rem, 2.8vw, 1.9rem);
}

.subtitle {
  margin: 0 0 1rem;
  color: #4b5563;
}

.owner-name {
  margin: 0 0 0.4rem;
  font-weight: 600;
  color: #1d4ed8;
}

label {
  display: inline-block;
  margin-bottom: 0.45rem;
  font-weight: 600;
}

textarea {
  width: 100%;
  border: 1px solid #c9d2dd;
  border-radius: 10px;
  padding: 0.75rem;
  font: inherit;
  resize: vertical;
  outline: none;
}

textarea:focus {
  border-color: #3b82f6;
}

.actions {
  display: flex;
  gap: 0.65rem;
  margin: 0.85rem 0;
}

button {
  border: 0;
  border-radius: 9px;
  padding: 0.62rem 0.9rem;
  font: inherit;
  cursor: pointer;
}

#generate-btn {
  background: #2563eb;
  color: #fff;
}

#download-btn {
  background: #e5e7eb;
  color: #111827;
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.error {
  margin: 0;
  min-height: 1.2rem;
  color: #dc2626;
}

.result-card {
  border: 1px dashed #d1d5db;
  border-radius: 12px;
  background: #f9fafb;
  min-height: 270px;
  display: grid;
  place-items: center;
  padding: 1rem;
}

#qr-wrapper {
  width: 320px;
  min-height: 320px;
  display: grid;
  place-items: center;
  background: #fff;
  border-radius: 8px;
}

.app-footer {
  margin-top: 1rem;
  text-align: center;
  color: #6b7280;
  font-size: 0.92rem;
}

@media (max-width: 530px) {
  .actions {
    flex-direction: column;
  }

  #qr-wrapper {
    width: 260px;
    min-height: 260px;
  }
}
