* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  background: linear-gradient(135deg, #eef2ff, #f8fafc);
  color: #1e293b;
  min-height: 100vh;
}

.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 16px;
  padding: 20px;
}

.hero h1 { font-size: 2.5rem; }
.hero p { color: #64748b; max-width: 420px; }

.btn {
  border: none;
  border-radius: 8px;
  padding: 12px 24px;
  font-size: 1rem;
  cursor: pointer;
  transition: background .2s, transform .1s;
}
.btn:active { transform: scale(.98); }
.btn-primary { background: #4f46e5; color: #fff; }
.btn-primary:hover { background: #4338ca; }
.btn-full { width: 100%; margin-top: 8px; }

/* Модалка */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, .55);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  opacity: 0;
  visibility: hidden;
  transition: opacity .2s, visibility .2s;
}
.modal.open { opacity: 1; visibility: visible; }

.modal-content {
  background: #fff;
  width: 100%;
  max-width: 460px;
  border-radius: 12px;
  padding: 28px;
  position: relative;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 20px 50px rgba(0,0,0,.2);
}

.modal-close {
  position: absolute;
  top: 10px; right: 14px;
  background: none;
  border: none;
  font-size: 1.8rem;
  color: #94a3b8;
  cursor: pointer;
}
.modal-close:hover { color: #1e293b; }

.modal-content h2 { margin-bottom: 18px; }

/* Форма */
.field { display: flex; flex-direction: column; margin-bottom: 14px; }
.field label { font-size: .9rem; font-weight: 600; margin-bottom: 6px; }

.field input,
.field select,
.field textarea {
  padding: 10px 12px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  font-size: 1rem;
  font-family: inherit;
}
.field textarea { resize: vertical; }

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: #4f46e5;
  box-shadow: 0 0 0 3px rgba(79,70,229,.15);
}

.field.invalid input,
.field.invalid select,
.field.invalid textarea { border-color: #dc2626; }

.error { color: #dc2626; font-size: .8rem; min-height: 1em; margin-top: 4px; }

.success { text-align: center; }
.success p { margin: 10px 0 18px; color: #64748b; }
.hidden { display: none; }