* {
  box-sizing: border-box;
}

.fixed-height {
  min-height: 48px;
  display: flex;
  align-items: center;
}

.profile-container {
  min-height: 100vh;
  background-color: rgba(24 24 27);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  position: relative;
}

.profile-header {
  position: absolute;
  top: 32px;
  left: 32px;
  color: rgba(161 161 170);
  font-size: 20px;
  font-weight: 500;
}

.card-wrapper {
  position: relative;
  width: 100%;
  max-width: 1200px;
}

.profile-card {
  display: flex;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-radius: 60px;
  padding: 40px;
  flex-direction: row;
  gap: 0;
  max-width: 1200px;
  width: 100%;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
  outline: 1px solid rgba(255, 255, 255);
  position: relative;
  height: 650px;
  overflow-x: visible;
  overflow-y: auto;
  align-items: stretch;
  min-height: 400px;
}

.left-section {
  flex-shrink: 0;
  display: flex;
  flex-direction: row;
  gap: 32px;
  align-items: flex-start;
  min-width: 500px;
  height: 100%;
  min-height: 400px;
}

.profile-image {
  width: 400px;
  height: 100%;
  max-height: 100%;
  border-radius: 60px;
  overflow: hidden;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.3);
  flex-shrink: 0;
  display: flex;
}


.profile-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.left-content {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: flex-start;
  gap: 24px;
  text-align: left;
  width: 330px;
  padding-top: 80px;
  font-size: 1.6rem;
}

.profile-name,
.name-input {
  min-height: 60px;
  font-size: 3.7rem;
  width: 250px;
  font-weight: bold;
  color: rgba(246 204 182);
  display: flex;
  align-items: center;
  line-height: 1.2;
}


.name-input {
  background-color: transparent;
  border: none;
  outline: none;
  border-bottom: 1px solid rgba(246 204 182);
  padding: 0;
  margin: 0;
  font-family: inherit;
}

.profile-bio,
.bio-textarea {
  height: 180px;
  min-height: 185px;
  max-height: 185px;
  width: 300px;
  max-width: 300px;
  font-family: inherit;
  font-size: 1.6rem;
  line-height: 1.8;
  color: rgba(246 204 182);

  padding: 10px;
  margin-bottom: 10px;
  box-sizing: border-box;
  border-radius: 6px;

  word-wrap: break-word;
  overflow-wrap: break-word;
  white-space: pre-wrap;

  display: block;
  flex-shrink: 0;
}

.bio-textarea {
  background-color: transparent;
  border: none;
  outline: 1px solid rgba(246 204 182);
  resize: none;
  overflow-y: auto;
  scrollbar-width: thin;
}

.tags-container {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  max-width: 340px;
  justify-content: flex-start;
  min-height: 44px;
  align-items: flex-start;
  align-content: flex-start;
}

.tag {
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.08);
  color: rgb(255 255 255);
  border-radius: 12px;
  font-size: 1.1rem;
  outline: 1px solid rgb(255 255 255);
  transition: background-color 0.2s ease;
  height: 32px;
  display: flex;
  align-items: center;
  box-sizing: border-box;
  line-height: 1;
}

.tag-remove-button {
  background: none;
  border: none;
  color: rgba(77 46 90);
  font-weight: bold;
  font-size: 12px;
  margin-left: 6px;
  cursor: pointer;
  line-height: 1;
  padding: 0;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.2s ease;
  flex-shrink: 0;
  position: relative;
  top: -5px;
}

.tag-remove-button:hover {
  color: rgba(221 51 51);
  background-color: rgba(255, 255, 255, 0.1);
}

.tag-input-wrapper {
  display: flex;
  align-items: center;
  gap: 6px;
  height: 32px;
}

.tag-add-button {
  background-color: transparent;
  color: rgba(77 46 90);
  font-weight: bold;
  border: none;
  border-radius: 50%;
  width: 32px;
  height: 32px;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.2s ease;
  flex-shrink: 0;
}

.tag-add-button:hover {
  color: rgba(224 185 161);
}

.tag-input {
  background-color: transparent;
  border: none;
  outline: 1px solid rgba(225 155 154);
  color: rgba(255 255 255);
  font-size: 1.1rem;
  border-radius: 16px;
  padding: 8px 10px;
  font-family: inherit;
  height: 32px;
  box-sizing: border-box;
}

.divider {
  width: 1px;
  background-color: rgba(246 204 182);
  margin-left: -5px;
  margin-right: 10px;
  align-self: stretch;
  height: 100%;
  flex-shrink: 0;
}

.right-section {
  flex: 2;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  gap: 10px;
  margin-left: 40px;
  padding-top: 70px;
  min-height: 400px;
}

.edit-button {
  position: absolute;
  top: 0px;
  right: 0px;
  background-color: transparent;
  border: none;
  cursor: pointer;
  z-index: 20;
  padding: 0;
}
.edit-button img {
  width: 56px;
  height: 56px;
}

.branch-year {
  color: rgba(77 46 90);
  font-size: 40px;
  font-weight: 600;
  padding: 0;
  padding-left: 6px;
  min-height: 60px;
  height: 60px;
  box-sizing: border-box;
  line-height: 1.2;
  margin: 0;
  width: 100%;
  position: relative;
  font-family: inherit;
  display: flex;
  align-items: center;
}

.branch-input {
  background-color: transparent;
  border: none;
  outline: none;
  border-bottom: 1px solid rgba(246 204 182);
  color: rgba(77 46 90);
  font-size: 40px;
  font-weight: 600;
  min-height: 60px;
  height: 60px;
  line-height: 1.2;
  box-sizing: border-box;
  padding: 0;
  margin: 0;
  font-family: inherit;
  position: absolute;
  top: 0;
  text-align: left;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
  flex-shrink: 0;
}

.branch-input:first-of-type {
  width: 120px;
  min-width: 120px;
  max-width: 120px;
  left: 6px;
  padding-left: 0;
}

.branch-input:last-of-type {
  width: 140px;
  min-width: 140px;
  max-width: 140px;
  left: 141px;
  padding-left: 0;
}

.detail-row {
  font-size: 20px;
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  min-height: 48px;
}
.detail-label {
  color: rgba(246 204 182);
  font-weight: 600;
  margin-right: 10px;
  min-width: auto;
  white-space: nowrap;
}
.detail-value {
  color: rgba(246 204 182);
}
.detail-input {
  background-color: transparent;
  width: 155px;
  border: none;
  outline: none;
  border-bottom: 1px solid rgba(246 204 182);
  color: rgba(246 204 182);
  font-size: 20px;
  height: 32px;
  box-sizing: border-box;
  padding: 0;
  font-family: inherit;
  font-weight: inherit;
}
.detail-label,
.detail-input,
.detail-value {
  font-size: 1.8rem;
}

.save-button {
  margin-top: 32px;
  padding: 14px 28px;
  background-color: rgba(124 58 237);
  color: rgba(255 255 255);
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-size: 18px;
  font-weight: 500;
  align-self: flex-start;
  transition: background-color 0.2s;
}
.save-button:hover {
  background-color: rgb(109 40 217);
}

@media (max-width: 768px) {
  .profile-container {
    padding: 16px;
    padding-top: 40px;
  }

  .profile-header {
    top: 16px;
    left: 16px;
    font-size: 16px;
  }

  .profile-card {
    border-radius: 24px;
    padding: 20px;
    flex-direction: column;
    gap: 20px;
    max-height: none;
    overflow-y: auto;
    height: auto;
    min-height: 400px;
  }

  .left-section {
    flex-direction: column;
    gap: 20px;
    align-items: center;
    min-width: 100%;
  }

  .profile-image {
    width: 220px;
    height: 280px;
  }

  .left-content {
    padding-top: 0;
    align-items: center;
    text-align: center;
    width: 100%;
  }

  .profile-name,
  .name-input {
    font-size: 40px;
    text-align: center;
    min-height: 44px;
  }

  .profile-bio,
  .bio-textarea {
    max-width: 100%;
    font-size: 16px;
    min-height: 80px;
  }

  .tags-container {
    max-width: 100%;
    justify-content: center;
    min-height: 38px;
  }

  .tag,
  .tag-input {
    padding: 6px 10px;
    font-size: 13px;
    height: 28px;
  }

  .tag-input-wrapper {
    height: 28px;
  }

  .tag-add-button {
    width: 28px;
    height: 28px;
    font-size: 18px;
  }

  .tag-remove-button {
    width: 14px;
    height: 14px;
    font-size: 10px;
    margin-left: 4px;
  }

  .divider {
    width: 100%;
    height: 1px;
    margin: 20px 0;
    align-self: stretch;
  }

  .right-section {
    justify-content: flex-start;
    gap: 20px;
  }

  .edit-button {
    top: 16px;
    right: 16px;
  }

  .branch-year {
    font-size: 20px;
    min-height: 40px;
    height: 40px;
    gap: 10px;
    line-height: 1.2;
    margin: 0;
    width: 100%;
    position: relative;
  }

  .branch-input {
    font-size: 20px;
    min-height: 40px;
    height: 40px;
    line-height: 1.2;
    margin: 0;
    flex-shrink: 0;
  }

  .branch-input:first-of-type {
    width: 80px;
    position: absolute;
    left: 6px;
    top: 0;
  }

  .branch-input:last-of-type {
    width: 100px;
    position: absolute;
    left: 95px;
    top: 0;
  }

  .branch-input:first-of-type {
    width: 100px;
  }

  .branch-input:last-of-type {
    width: 120px;
  }

  .detail-row {
    font-size: 18px;
    flex-wrap: wrap;
  }

  .detail-label {
    min-width: 100px;
  }
  .detail-label,
  .detail-value,
  .detail-input {
    font-size: 19px;
  }
  .right-section {
  align-items: flex-start;
  text-align: left;
  }

  .detail-input {
    font-size: 18px;
    min-width: 140px;
  }

  .save-button {
    padding: 16px 32px;
    align-self: stretch;
  }
  .profile-card {
    max-height: 90vh;
    overflow-y: auto;
  }
}

.left-section,
.right-section {
  height: 100%;
}