/* UserProfile.module.css */
.pageWrapper {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: calc(90vh - 60px);
  background-color: #17153b;
  padding: 20px;
}

.profileCard {
  display: flex;
  width: 100%;
  height: 80vh;
  min-height: 600px;
  max-height: 1000px;
  max-width: 1300px;
  background-color: #1d1949;
  background-image: url("/UserImages/Containers/Container.svg");
  background-size: cover;
  border-radius: 10px;
  overflow: hidden;
  position: relative;
}

.avatarSection {
  padding: 0 7rem;
  display: flex;
  justify-content: center;
  align-items: center;
}

.avatarWrapper {
  position: relative;
  display: inline-block;
}

.avatarCircle {
  width: clamp(300px, 24vw, 500px);
  height: clamp(300px, 24vw, 500px);
  border-radius: 50%;
  background: #2e275f url("/UserImages/default_pfp.svg") center/contain;
  box-shadow: #000000 0 1px 20px -5px;
  position: relative;
}

.avatarImage {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  position: absolute;
  top: 0;
  left: 0;
}

.customUploadButton {
  position: absolute;
  bottom: 14%;
  right: 11%;
  width: 3.5em;
  height: 3.5em;
  border-radius: 50%;
  background: url("/UserImages/buttons/change_pfp.svg") center/contain;
  border: none;
  cursor: pointer;
  transform: translate(30%, 30%);
  transition: transform 0.2s ease;
  z-index: 1;
}

.customUploadButton:hover {
  transform: translate(30%, 30%) scale(1.2);
}

/*!* Custom styling for UploadButton *!*/
/*.customUploadButton {*/
/*    position: absolute !important;*/
/*    bottom: 14% !important;*/
/*    right: 11% !important;*/
/*    width: 3.5em !important;*/
/*    height: 3.5em !important;*/
/*    border-radius: 50% !important;*/
/*    background: url('/UserImages/buttons/change_pfp.svg') center/contain !important;*/
/*    border: none !important;*/
/*    cursor: pointer !important;*/
/*    transform: translate(30%, 30%) !important;*/
/*    transition: transform 0.2s ease !important;*/
/*    z-index: 1 !important;*/
/*    padding: 0 !important;*/
/*    overflow: hidden !important;*/
/*}*/

/*.customUploadButton:hover {*/
/*    transform: translate(30%, 30%) scale(1.2) !important;*/

/*}*/

/*.customUploadButton button,*/
/*.customUploadButton > * {*/
/*    width: 100% !important;*/
/*    height: 100% !important;*/
/*    background: transparent !important;*/
/*    border: none !important;*/
/*    color: transparent !important;*/
/*    padding: 0 !important;*/
/*    margin: 0 !important;*/
/*    opacity: 0 !important;*/
/*}*/

/*!* This hides any text content inside the button *!*/
/*.customUploadButton span,*/
/*.customUploadButton p,*/
/*.customUploadButton div {*/
/*    display: none !important;*/
/*}*/

/*!* Loading state for custom button *!*/
/*.customUploadButton.loading {*/
/*    animation: loadingPulse 1.5s infinite !important;*/
/*    background-color: #e0e0e0 !important;*/
/*    pointer-events: none !important;*/
/*}*/

/* Loading states */
@keyframes loadingPulse {
  0% {
    opacity: 1;
  }
  50% {
    opacity: 0.4;
  }
  100% {
    opacity: 1;
  }
}

.loading {
  animation: loadingPulse 1.5s infinite;
  background-color: #e0e0e0 !important;
  color: transparent !important;
  pointer-events: none;
}

.avatarCircle.loading {
  background: #e0e0e0;
}

.username.loading {
  width: 200px;
  height: 28px;
  border-radius: 4px;
}

.email.loading {
  width: 160px;
  height: 20px;
  border-radius: 4px;
  margin-top: 8px;
}

.button.loading {
  width: 140px;
  height: 36px;
  border-radius: 18px;
}

/* User info section */
.userInfo {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  color: white;
  padding-right: 2rem;
  gap: 1.3rem;
  margin-top: 120px;
}
.userInfoedit {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  color: white;
  padding-right: 2rem;
  gap: 0.8rem;
  margin-top: 140px;
}

.namefield {
  margin: 0;
}

.username {
  font-size: 2.5em;
  font-weight: 500;
  margin: 0;
}

.email {
  font-size: 1.2em;
  color: #aaa;
  margin: 12px 0 0 0;
}

.buttonContainer {
  display: flex;
  /*margin-top: 15px;*/
  /*gap: 16px;*/
}

.button {
  padding: 1rem 2rem;
  border-radius: 10px;
  border: none;
  color: white;
  font-size: 1.3em;
  font-weight: 400;
  transition: transform 0.1s ease;
  background: radial-gradient(
    circle at bottom right,
    #a078e4 0%,
    #8d80ec 57%,
    #738bf8 100%
  );
  cursor: pointer;
}

.button:hover {
  transform: scale(1.1);
}

.buttonDanger {
  background: radial-gradient(circle, rgb(161, 1, 1) 9%, rgb(119, 0, 0) 100%);
}

.icon {
  margin-right: 8px;
  margin-bottom: 4px;
  vertical-align: middle;
  width: 21px;
  height: 21px;
}

/* Add these styles to match the edit form fields */

.inputGroup {
  width: 100%;
  max-width: 500px;
}

.inputLabel {
  display: block;
  margin-bottom: 0.8rem;
  font-size: 1.2em;
  color: #aaa;
  font-weight: 400;
}

.inputField {
  width: 97.5%;
  padding: 0.7rem;
  background-color: #2e275f;
  border: 1px solid #3a3468;
  border-radius: 8px;
  font-size: 1.1em;
  color: white;
  transition: all 0.3s ease;
}

.inputField:focus {
  outline: none;
  border-color: #738bf8;
  box-shadow: 0 0 0 3px rgba(115, 139, 248, 0.2);
}

.inputField::placeholder {
  color: #6b6892;
  opacity: 0.8;
}

.errorMessage {
  color: #ff6b6b;
  font-size: 0.9em;
  margin-top: 0.8rem;
  display: block;
}

.buttonContainer {
  gap: 3.6rem;
  margin-top: 10px;
}

.button:disabled {
  opacity: 0.7;
  cursor: not-allowed;
  background: #4a4569;
}

.inputField.loading {
  background-color: #3a3468;
  border-color: #4a4569;
}

/* In UserProfile.module.css */
.nameContainer {
  display: flex;
  gap: 1rem; /* Space between first and last name */
  width: 80%;
  margin: 0;
}

.fname {
  margin: 0;
  font-size: 1.2em;
}
.lname {
  margin: 0;
  font-size: 1.2em;
}

.nameFieldsContainer {
  display: flex;
  gap: 1.5rem;
  /*width: 82%;*/
  max-width: 500px;
}

.iban {
  font-size: 1.3rem;
  color: #666;
  margin: 0;
  font-family: monospace;
}

.nameFieldsContainer .inputGroup {
  flex: 1;
  margin-bottom: 0;
  margin-top: 0;
}
.inputGroup:has(#email) {
  padding-top: 1rem; /* Adjust this value as needed */
}

/* IBAN input specific styling */
#iban {
  font-family: monospace;
  letter-spacing: 0.1em;
}

/* Placeholder styling */
.inputField::placeholder {
  color: #6b6892;
  font-style: italic;
}

.modalOverlay {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  right: 0;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  justify-content: center;
  align-items: center;
}

.modalContent {
  margin-left: 1em;
  margin-right: 1em;
  color: white;
  background: #2e236b;
  padding: 24px;
  border-radius: 8px;
  width: 320px;
  max-width: 90%;
}

.modalContent h3 {
  margin-top: 0;
  margin-bottom: 1em;
}

.modalContent label {
  display: block;
  margin-top: 12px;
  margin-bottom: 6px;
  font-weight: 600;
}

.modalContent select,
.modalContent textarea {
  width: 100%;
  padding: 8px;
  font-size: 1rem;
  background-color: #433d8a;
  color: white;
  border-radius: 4px;
  border: 2px solid #c8a4e4;
  box-sizing: border-box;
  margin-bottom: 1em;
}

.buttonContainerReport {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.buttonSubmitReport {
  padding: 0.8rem;
  border-radius: 10px;
  border: none;
  color: white;
  font-size: 0.9em;
  font-weight: 500;
  transition: transform 0.1s ease;
  background: radial-gradient(
    circle at bottom right,
    #a078e4 0%,
    #8d80ec 57%,
    #738bf8 100%
  );
  cursor: pointer;
}

.cancelButton {
  padding: 8px 16px;
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.53);
  cursor: pointer;
  font-weight: 700;
}

.confirmationMessage p {
  font-size: 1.1rem;
  margin-bottom: 16px;
  text-align: center;
}

.closeButton {
  padding: 0.8rem;
  margin-left: 8.8em;
  border-radius: 10px;
  border: none;
  color: white;
  font-size: 0.9em;
  font-weight: 400;
  transition: transform 0.1s ease;
  background: radial-gradient(
    circle at bottom right,
    #a078e4 0%,
    #8d80ec 57%,
    #738bf8 100%
  );
  cursor: pointer;
}

@media (max-width: 1040px){

  .profileCard {
    flex-direction: column;
    height: auto;
  }

  .avatarSection {
    padding: 30px;
  }

  .userInfo {
    align-items: center;
    text-align: center;
    padding: 0 0 30px 0;
    margin-top: 0;
  }
  .userInfoedit {
    align-items: center;
    text-align: center;
    padding: 0 0 30px 0;
    margin-top: 0;
  }

  .nameContainer {
    justify-content: center;
    align-items: center;
    text-align: center;
  }
  .fname {
    margin: 0;
  }
  .lname {
    margin: 0;
  }
  .avatarCircle {
    width: 250px;
    height: 250px;
  }
}

@media (max-width: 720px) {
  .inputField{
    width: 70vw
  }
}

@media (max-width: 500px) {
  .inputField{
    width: 70vw
  }
  .nameContainer {
    flex-direction: column;
    gap: 1rem;
    width: 100%;
  }

  .nameContainer .inputGroup {
    width: 100%;
  }
}

@media (max-width: 720px) {
  .profileCard {
    margin-top: 60px;
  }
}

@media (max-width: 500px) {
  .buttonContainer {
    flex-direction: column;
    align-items: center;
    gap: 1.8rem;
  }

  .username {
    font-size: 1.8em;
  }

  .email {
    font-size: 1em;
  }
  .nameContainer {
    flex-direction: column; /* Stack vertically on mobile */
    gap: 1rem;
  }
  .iban {
    margin-bottom: 1rem;
  }
}

@media (max-width: 330px) {
  .avatarCircle {
    width: 200px;
    height: 200px;
  }

  .username {
    font-size: 1.5em;
  }

  .email {
    font-size: 0.8em;
  }
}
