:root {
  --bg: #05070d;
  --bg-alt: #10182b;
  --field-bg: #0d1424;
  --border: #212c47;
  --border-focus: #2f6fed;
  --blue: #2f6fed;
  --blue-hover: #4c8dff;
  --text: #f5f7fb;
  --muted: #8f9bb5;
  --error: #ff5a5f;
  --radius: 10px;
}

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

.page {
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: radial-gradient(circle at 50% 0%, var(--bg-alt) 0%, var(--bg) 70%);
}

.brand {
  display: flex;
  justify-content: center;
  padding: 20px 16px 8px;
}

.logo {
  height: 28px;
  width: auto;
}

.content {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 8px 20px 32px;
  max-width: 480px;
  width: 100%;
  margin: 0 auto;
}

.title {
  font-size: 22px;
  font-weight: 800;
  margin: 0 0 4px;
  text-align: center;
  letter-spacing: -0.01em;
}

.subtitle {
  font-size: 14px;
  color: var(--muted);
  margin: 0 0 20px;
  text-align: center;
  font-weight: 400;
}

form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  border: none;
  padding: 0;
  margin: 0;
}

label, legend {
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  padding: 0;
}

input[type="text"],
input[type="tel"],
select {
  width: 100%;
  background: var(--field-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  font-size: 16px;
  font-weight: 600;
  padding: 13px 14px;
  outline: none;
  transition: border-color 0.15s ease;
  appearance: none;
  -webkit-appearance: none;
}

select {
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='14' height='9' viewBox='0 0 14 9'><path d='M1 1l6 6 6-6' stroke='%238f9bb5' stroke-width='2' fill='none' fill-rule='evenodd'/></svg>");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 36px;
}

input::placeholder {
  color: var(--muted);
  font-weight: 400;
}

input:focus, select:focus {
  border-color: var(--border-focus);
  box-shadow: 0 0 0 3px rgba(47, 111, 237, 0.25);
}

.field.invalid input,
.field.invalid select,
fieldset.invalid {
  border-color: var(--error);
}

fieldset.invalid .radio {
  border-color: var(--error);
}

.error-msg {
  display: none;
  font-size: 12px;
  color: var(--error);
  font-weight: 600;
}

.field.invalid .error-msg,
fieldset.invalid .error-msg {
  display: block;
}

.radio {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--field-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px 14px;
  margin-top: 6px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
}

.radio input {
  width: 18px;
  height: 18px;
  accent-color: var(--blue);
  flex-shrink: 0;
}

button[type="submit"] {
  margin-top: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--blue);
  color: #fff;
  border: none;
  border-radius: var(--radius);
  padding: 15px 18px;
  font-size: 16px;
  font-weight: 800;
  cursor: pointer;
  transition: background 0.15s ease, opacity 0.15s ease;
}

.wa-icon {
  flex-shrink: 0;
}

button[type="submit"]:hover {
  background: var(--blue-hover);
}

button[type="submit"]:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.submit-error {
  color: var(--error);
  font-size: 13px;
  font-weight: 600;
  text-align: center;
  margin: 0;
}

@media (max-height: 700px) {
  .brand { padding: 14px 16px 4px; }
  .subtitle { margin-bottom: 14px; }
  form { gap: 10px; }
}
