﻿/* forms/registration.css */

body {
  background-color: #f8f8f8;
}

.form-container {
  max-width: 800px;
  margin: auto;
  margin-top: 30px;
  background-color: white;
  padding: 30px;
  border-radius: 10px;
  box-shadow: 0 0 10px rgba(0,0,0,0.1);
}

.flag-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px;
  cursor: pointer;
  border: 2px solid transparent;
  border-radius: 5px;
}

.flag-option.selected {
  border-color: blue;
}

.flag-option img {
  width: 24px;
  height: 18px;
  object-fit: cover;
  border-radius: 3px;
}

.dropdown {
  position: relative;
  width: 100%;
}

.dropdown-btn {
  padding: 10px;
  border: 1px solid #ccc;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: white;
  border-radius: 0.375rem;
}

.dropdown-content {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  max-height: 300px;
  overflow-y: auto;
  border: 1px solid #ccc;
  background-color: white;
  display: none;
  z-index: 1000;
  border-radius: 0.375rem;
  box-shadow: 0 5px 10px rgba(0,0,0,0.1);
}

.dropdown-content div[data-value]:hover {
  background-color: #f0f0f0;
}

.dropdown-search {
  padding: 8px;
  border-bottom: 1px solid #ccc;
}

.dropdown-search input {
  width: 100%;
  padding: 6px;
  border: 1px solid #ddd;
  border-radius: 4px;
}

.no-results {
  padding: 10px;
  text-align: center;
  color: #777;
  display: none;
}

/* Styles for validation feedback */
.form-control.is-invalid {
  border-color: #dc3545;
  padding-right: calc(1.5em + 0.75rem);
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' width='12' height='12' fill='none' stroke='%23dc3545'%3e%3ccircle cx='6' cy='6' r='4.5'/%3e%3cpath stroke-linejoin='round' d='M5.8 3.6h.4L6 6.5z'/%3e%3ccircle cx='6' cy='8.2' r='.6' fill='%23dc3545' stroke='none'/%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right calc(0.375em + 0.1875rem) center;
  background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
}

.form-control.is-valid {
  border-color: #198754;
  padding-right: calc(1.5em + 0.75rem);
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3e%3cpath fill='%23198754' d='M2.3 6.73L.6 4.53c-.4-.4-.3-.7.1-.7s.7.3.7.7L2.3 6.73c.2.2.6.2.8 0L6.7 1.27c.4-.4.3-.7-.1-.7s-.7.3-.7.7L3.1 6.33c-.2.2-.5.2-.7 0z'/%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right calc(0.375em + 0.1875rem) center;
  background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
}

.invalid-feedback {
  color: #dc3545;
  font-size: 0.875em;
  margin-top: 0.25rem;
}

.valid-feedback {
  color: #198754;
  font-size: 0.875em;
  margin-top: 0.25rem;
}

/* Password toggle specific styles */
.password-input-group {
    position: relative;
}

.password-toggle {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    color: #6c757d;
    z-index: 10;
}

.password-toggle:hover {
    color: #343a40;
}

/* Welcome message and Profile Setup styles */
#welcomeSection, #profileSetupSection {
  text-align: center;
  padding: 40px 20px;
  background-color: white;
  border-radius: 10px;
  box-shadow: 0 0 10px rgba(0,0,0,0.1);
  display: none; /* Hidden by default */
  margin-top: 30px;
}

#welcomeSection h2, #profileSetupSection h2 {
  font-size: 2rem;
  color: #28a745;
  margin-bottom: 20px;
}

#profileImagePreview {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    object-fit: cover;
    margin-top: 20px;
    border: 2px solid #ddd;
}

.profile-img-upload-container {
    margin: 20px auto;
    width: fit-content;
    text-align: center;
}