.user-profile-page {
  width: 100%;
  min-height: 100%;
  background: var(--gradient-bg-global);
}

.user-profile-main {
  width: 100%;
  min-height: 100%;
  padding: 18px 14px 90px;
}

.user-profile-wrap {
  width: 100%;
  max-width: 420px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.user-profile-header-row {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 4px;
  padding-bottom: 20px;
  border-bottom: 0.5px solid rgba(255, 255, 255, 0.12);
}

.user-profile-header-home {
  display: flex;
  border: none;
  background: transparent;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  gap: 4px;
  padding: 0;
  cursor: pointer;
  font-family: "Gellix", sans-serif;
}

.user-profile-header-modal {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 4px;
  padding-bottom: 20px;
  border-bottom: 0.5px solid rgba(255, 255, 255, 0.12);
}

.user-profile-header-settings {
  width: 30px;
  height: 30px;
  border: none;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.06);
  color: rgba(244, 248, 255, 0.95);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.2s ease;
}

.user-profile-header-settings.is-active,
#user-profile-settings-static {
  background: rgba(255, 79, 31, 0.28);
  /* box-shadow: 0 0 0 1px rgba(220, 100, 30, 0.55); */
}

.user-profile-header-modal-settings {
  width: 30px;
  height: 30px;
  border: none;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.06);
  color: rgba(244, 248, 255, 0.95);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.2s ease;
  /* margin-bottom: 20px; */
}

.user-profile-header-settings-icon {
  width: 16px;
  height: 16px;
  object-fit: contain;
  display: block;
}

.user-profile-header-title {
  color: rgba(241, 247, 255, 0.85);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -0.2px;
  line-height: 1;
}

.user-profile-header-brand {
  color: rgba(179, 191, 220, 0.75);
  font-size: 10px;
  letter-spacing: -0.2px;
}

.user-profile-modal-cancel {
  display: flex;
  align-items: center;
  align-self: center;
  color: rgba(255, 255, 255, 0.9);
  font-size: 10px;
  letter-spacing: 0px;
  font-weight: 400;
  margin-top: 10px;
  padding: 10px;
}

.user-profile-main-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 8px 0 2px;
}

.user-profile-avatar-wrap {
  width: 72px;
  height: 72px;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(0, 0, 0, 0.35);
  flex-shrink: 0;
}

.user-profile-avatar {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.user-profile-name-block {
  /* display: flex;
  flex-direction: column;
  gap: -4px; */
  min-width: 0;
}

.user-profile-name-label {
  color: rgba(200, 215, 255, 0.4);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: -0.75px;
  line-height: 1.2;
}

.user-profile-name-meta {
  color: rgba(170, 183, 220, 0.6);
  font-size: 10px;
  letter-spacing: 0.2px;
  line-height: 1.25;
  margin-top: 2px;
  opacity: 0.75;
}

.user-profile-name-value {
  margin-top: -2px;
  color: #1491e7;
  /* font-size: clamp(34px, 10vw, 64px); */
  font-size: 44px;
  line-height: 0.95;
  font-weight: 600;
  letter-spacing: -2.4px;
  cursor: pointer;
  user-select: none;
}

.user-profile-board {
  /* border: 1px solid rgba(124, 149, 236, 0.22); */
  color: rgba(238, 244, 255, 0.92);
  text-align: left;
  gap: 12px;
  padding: 20px 16px;
  background: linear-gradient(
    135deg,
    rgba(0, 18, 51, 0.1),
    rgba(0, 0, 0, 0.08)
  );
  border-radius: 16px;
  cursor: pointer;
  transition: all 0.2s ease;
  backdrop-filter: blur(4px);
}

.board-full {
  width: 100%;
}

.board-label {
  font-size: 14px;
  font-weight: 600;
  color: rgba(200, 215, 255, 0.5);
  margin-bottom: 4px;
  letter-spacing: -0.5px;
}

.board-content-row {
  display: flex;
  align-items: center;
  gap: 8px;
  color: rgba(200, 215, 255, 0.55);
  font-size: 11px;
  font-weight: 400;
  letter-spacing: -0.1px;
}

.board-icon {
  width: 20px;
  height: 20px;
  object-fit: contain;
  opacity: 0.65;
  flex-shrink: 0;
}

.user-profile-grid {
  width: 100%;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.board-half {
  min-height: 116px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.board-logout {
  background: linear-gradient(
    130deg,
    rgba(70, 8, 20, 0.9),
    rgba(166, 15, 22, 0.9)
  );
  border-color: rgba(255, 125, 125, 0.45);
  border: none;
  font-family: "Gellix", sans-serif;
}

.logout-icon {
  width: 20px;
  height: 20px;
  opacity: 0.75;
}

.contact-btn {
  border: none;
  background: transparent;
  cursor: pointer;
  padding: 0;
  font-family: "Gellix", sans-serif;
  width: 100%;
  justify-content: flex-start;
}

.user-profile-settings-view {
  gap: 12px;
}

.user-settings-title {
  width: 100%;
  text-align: left;
  color: #88d4ff;
  font-family: "Gellix", sans-serif;
  font-size: 17px;
  line-height: 0.9;
  letter-spacing: -0.75px;
  font-weight: 500;
}

.user-settings-section-title {
  color: rgba(200, 215, 255, 0.4);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: -0.75px;
  line-height: 1.2;
}

.user-settings-profile-row {
  width: 100%;
  display: flex;
  gap: 12px;
  align-items: center;
}

.user-settings-avatar-upload {
  width: 78px;
  height: 78px;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(0, 0, 0, 0.35);
  position: relative;
  padding: 0;
  cursor: pointer;
}

.user-settings-avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.user-settings-upload-icon {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 28px;
  height: 28px;
  transform: translate(-50%, -50%);
  opacity: 0.92;
}

.user-settings-name-wrap {
  min-width: 0;
  flex: 1;
}

.user-settings-name-input {
  width: 100%;
  border: none;
  background: transparent;
  color: #1491e7;
  /* font-size: clamp(34px, 10vw, 58px); */
  font-size: 28px;
  line-height: 0.95;
  font-weight: 600;
  letter-spacing: -2px;
  padding: 0;
  outline: none;
  font-family: "Gellix", sans-serif;
}

.user-settings-name-meta {
  color: rgba(170, 183, 220, 0.6);
  font-size: 10px;
  letter-spacing: 0;
  line-height: 1.25;
  margin-top: 5px;
  opacity: 0.75;
}

.user-settings-email-board {
  cursor: default;
  font-family: "Gellix", sans-serif;
}

.user-settings-email-row {
  gap: 10px;
}

.user-settings-email-input {
  width: 100%;
  border: none;
  background: transparent;
  color: rgba(200, 215, 255, 0.7);
  font-size: 10px;
  letter-spacing: -0.2px;
  line-height: 0.95;
  padding: 0;
  outline: none;
  font-family: "Gellix", sans-serif;
}

.user-settings-email-input::placeholder,
.user-settings-name-input::placeholder {
  color: rgba(170, 183, 220, 0.45);
}

.user-settings-choice-grid {
  width: 100%;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.user-settings-choice {
  min-height: 102px;
  border-radius: 16px;
  border: 0.25px solid rgba(124, 149, 236, 0.14);
  background: linear-gradient(
    135deg,
    rgba(0, 18, 51, 0.1),
    rgba(0, 0, 0, 0.08)
  );
  color: rgba(238, 244, 255, 0.92);
  font-size: 11px;
  letter-spacing: -0.2px;
  cursor: pointer;
  font-family: "Gellix", sans-serif;
  transition: all 0.2s ease;
  backdrop-filter: blur(4px);
}

.user-settings-choice.is-selected {
  border: 1px solid rgba(238, 244, 255, 0.55);
  background: linear-gradient(
    135deg,
    rgba(20, 60, 140, 0.35),
    rgba(10, 30, 80, 0.28)
  );
  color: rgba(241, 247, 255, 0.98);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.07);
}

.user-settings-save {
  border: none;
  background: linear-gradient(
    130deg,
    rgba(70, 8, 20, 0.9),
    rgba(166, 15, 22, 0.9)
  );
  color: rgba(238, 244, 255, 0.92);
  font-size: 13px;
  letter-spacing: -0.3px;
  text-align: center;
  font-weight: 600;
  font-family: "Gellix", sans-serif;
}

.user-profile-footer-brand {
  text-align: center;
  font-size: 11px;
  font-weight: 400;
  color: rgba(200, 215, 255, 0.4);
  letter-spacing: var(--letter-spacing-normal);
  padding: 10px 0 28px;
}

@media (max-width: 390px) {
  .user-profile-header-title {
    font-size: 12px;
  }

  .user-profile-name-value {
    font-size: clamp(30px, 9vw, 44px);
  }

  .user-settings-name-input,
  .user-settings-email-input {
    font-size: 28px;
  }

  .user-settings-choice,
  .user-settings-save {
    font-size: 30px;
  }

  .board-content-row {
    font-size: 12px;
  }
}

/* Email Edit Modal */
.user-profile-email-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.user-profile-modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(2px);
  pointer-events: none;
}

.user-profile-modal-content {
  position: relative;
  width: 100%;
  max-width: 420px;
  background: var(--gradient-bg-global);
  border-radius: 20px;
  padding: 18px 24px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  max-height: none;
  overflow-y: auto;
}

.auth-passcode-inputs {
  padding: 15px 0;
}

.user-email-modal-passcode-label {
  color: rgba(200, 215, 255, 0.6);
  font-size: 12px;
  letter-spacing: -0.3px;
  line-height: 1.4;
  margin-top: 8px;
}

.user-email-modal-actions {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.email-modal-action {
  color: rgba(200, 215, 255, 0.6);
  font-size: 11px;
  font-family: "Gellix", sans-serif;
}

.email-modal-cancel {
  display: flex;
  color: rgba(200, 215, 255, 0.6);
  font-size: 11px;
  font-family: "Gellix", sans-serif;
  cursor: pointer;
  align-items: center;
  align-self: center;
  margin-top: 10px;
}

.user-email-modal-confirm {
  width: 100%;
  margin-top: 14px;
}

/* Update email board to be button-like */
.user-settings-email-board {
  display: flex;
  flex-direction: column;
  border: none;
  background: linear-gradient(
    135deg,
    rgba(0, 18, 51, 0.1),
    rgba(0, 0, 0, 0.08)
  );
  border-radius: 16px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.user-settings-email-board:active {
  background: linear-gradient(
    135deg,
    rgba(20, 145, 231, 0.08),
    rgba(20, 145, 231, 0.05)
  );
}

#user-settings-email-display {
  color: rgba(200, 215, 255, 0.7);
  font-size: 10px;
  letter-spacing: -0.2px;
  line-height: 0.95;
  font-family: "Gellix", sans-serif;
}
