@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600&display=swap');

/* ── Reset & base ── */
* {
  box-sizing: border-box;
}

body {
  font-family: 'Inter', system-ui, sans-serif;
  background-color: #F0F2F5;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  color: #1E2235;
}

.registration h3, .login h3 {
  font-size: 1.35rem;
  font-weight: 600;
  color: #FFFFFF;
  letter-spacing: -0.02em;
  margin-top: 0.25rem;
  margin-bottom: 2.3rem;
}

/* ── Registration/login cards ── */
.registration,
.login {
  background: #1E2235;
  border-radius: 16px;
  padding: 2.5rem 2.25rem;
  width: 90%;
  max-width: 577px;
  box-shadow:
    0 4px 24px rgba(30, 34, 53, 0.18),
    0 1px 4px rgba(30, 34, 53, 0.10);
}

.login {
  display: inline-block;
  padding-bottom: 2rem;
}

/* ── Form layout ── */
form {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

/* ── Inputs ── */
.text_input,
.dropdown {
  width: 100%;
  padding: 0.7rem 1rem;
  font-family: inherit;
  font-size: 0.9rem;
  color: #1E2235;
  background: #FFFFFF;
  border: 1.5px solid transparent;
  border-radius: 8px;
  outline: none;
  transition:
    border-color 0.18s ease,
    box-shadow 0.18s ease;
}

.dropdown {
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
}

/* ── Birthdate row (year / month / day side by side) ── */
.date_row {
  display: flex;
  gap: 0.6rem;
}

.short_dropdown {
  flex: 1;
  min-width: 0;
  padding: 0.7rem 0.5rem;
  font-family: inherit;
  font-size: 0.9rem;
  color: #1E2235;
  background: #FFFFFF;
  border: 1.5px solid transparent;
  border-radius: 8px;
  outline: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  transition:
    border-color 0.18s ease,
    box-shadow 0.18s ease;
}

.short_dropdown:focus {
  border-color: #6C7AE0;
  box-shadow: 0 0 0 3.5px rgba(108, 122, 224, 0.22);
}

/* Placeholder hints via attribute — browsers show name as placeholder */
.text_input[name="email"]::placeholder    { content: "Email address"; }
.text_input[name="username"]::placeholder { content: "Username"; }
.text_input[name="password"]::placeholder { content: "Password"; }

/* Signature element: indigo glow on focus */
.text_input:focus,
.dropdown:focus {
  border-color: #6C7AE0;
  box-shadow: 0 0 0 3.5px rgba(108, 122, 224, 0.22);
}

.inner_text {
  margin-bottom: 1.25rem;
  color: #D1D5DB;
  line-height: 1.6;
}

.inner_bonus_text {
  color: #d6dbe1;
  font-size: 0.8rem;
  line-height: 1.55;
  margin-top: 0.25rem;
  margin-bottom: 0.5rem;
}

/* ── Parent/Guardian block ── */
.parent_block {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding-top: 0.5rem;
}

/* ── Waiver block ── */
.waiver_block {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  padding: 0.7rem 0.1rem 0;
}

.waiver_block a {
  color: #A7B2FF;
  font-size: 0.86rem;
  text-decoration: underline;
}

.waiver_label {
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
  color: #E5E7EB;
  font-size: 0.84rem;
  line-height: 1.45;
}

.waiver_label input {
  margin-top: 0.2rem;
}

/* ── Submit button ── */
.submit {
  margin-top: 0.4rem;
  width: 100%;
  padding: 0.75rem 1rem;
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: #FFFFFF;
  background: #6C7AE0;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition:
    background 0.15s ease,
    transform 0.1s ease,
    box-shadow 0.15s ease;
}

.submit:hover {
  background: #5A67D8;
  box-shadow: 0 4px 14px rgba(108, 122, 224, 0.38);
}

.invalid_input {
  border-color: #F56565 !important;
  box-shadow: 0 0 0 3px rgba(245, 101, 101, 0.18) !important;
}

.disabled_button {
  background: #9CA3AF;
  cursor: not-allowed;
  box-shadow: none;
}

.disabled_button:hover {
  background: #9CA3AF;
  box-shadow: none;
}

.submit:active {
  transform: translateY(1px);
  box-shadow: none;
}

.extra_text {
  margin-top: 2rem;
}

.extra_text > p {
  font-size: 0.82rem;
  color: #6b7280;
}

.extra_text a {
  font-size: 0.82rem;
  color: #6c7ae0;
}

/* ── Flash messages ── */
.flashes {
  position: fixed;
  top: 1rem;
  width: 100%;
  max-width: 400px;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.flashes p {
  background: #FFF5F5;
  color: #C53030;
  border: 1px solid #FEB2B2;
  border-radius: 10px;
  padding: 0.65rem 1rem;
  font-size: 0.82rem;
  font-weight: 500;
}

/* ── Responsive ── */
@media (max-width: 640px) {
  .registration,
  .login {
    width: 90%;
    padding: 2rem 1.5rem;
  }

  .date_row {
    gap: 0.4rem;
  }

  .short_dropdown {
    padding: 0.7rem 0.35rem;
    font-size: 0.82rem;
  }
}