.user-profile-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem;
}

.user-header {
  display: flex;
  align-items: center;
  gap: 2rem;
  margin-bottom: 3rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--color-border);
}

.user-icon-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}

.user-icon {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  background-color: #f0f0f0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  color: var(--color-text-muted);
  overflow: hidden;
}

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

.default-icon {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #e0e0e0 0%, #f5f5f5 100%);
}

.user-info h1 {
  margin: 0;
  font-size: 2rem;
  color: #333;
}

.user-email {
  color: var(--color-text-muted);
  margin-top: 0.5rem;
}

.list-section {
  margin-bottom: 3rem;
}

.list-section h2 {
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  border-left: 4px solid #333;
  padding-left: 1rem;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 2rem;
}

.product-card {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: transform 0.2s;
}

.product-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.product-card a {
  text-decoration: none;
  color: inherit;
}

.product-image {
  aspect-ratio: 1;
  background-color: var(--color-bg-base);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

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

.no-image {
  color: #ccc;
  font-size: 0.9rem;
}

.product-info {
  padding: 1rem;
}

.brand-name {
  font-size: 0.8rem;
  color: var(--color-text-muted);
  margin: 0;
}

.product-name {
  font-size: 1rem;
  margin: 0.25rem 0 0;
  font-weight: bold;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.empty-message {
  color: var(--color-text-light);
  font-style: italic;
  grid-column: 1 / -1;
}

.edit-icon-btn {
  font-size: 0.8rem;
  color: var(--color-text-muted);
  text-decoration: none;
  border: 1px solid #ddd;
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  transition: all 0.2s;
}

.edit-icon-btn:hover {
  background-color: #f5f5f5;
  color: #333;
  border-color: #ccc;
}

.edit-user-form {
  max-width: 500px;
  margin: 0 auto;
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: bold;
}

.form-control {
  width: 100%;
  padding: 0.5rem;
  border: 1px solid #ddd;
  border-radius: var(--radius-sm);
}

.current-avatar {
  margin-bottom: 1rem;
}

.avatar-preview {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  object-fit: cover;
}

.default-avatar-preview {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  background: linear-gradient(135deg, #e0e0e0 0%, #f5f5f5 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  color: var(--color-text-muted);
}

.form-actions {
  display: flex;
  gap: 1rem;
  margin-top: 2rem;
}

.btn {
  padding: 0.5rem 1.5rem;
  border-radius: var(--radius-sm);
  text-decoration: none;
  cursor: pointer;
  border: none;
  font-size: 1rem;
}

.btn-primary {
  background-color: #333;
  color: white;
}

.btn-secondary {
  background-color: var(--color-border);
  color: #333;
}

.btn-danger {
  background-color: #dc3545;
  color: white;
}

.btn-danger:hover {
  background-color: #c82333;
}

.account-deletion-section {
  margin-top: 4rem;
  padding-top: 2rem;
  border-top: 2px solid var(--color-border);
}

.account-deletion-section h2 {
  font-size: 1.5rem;
  color: #dc3545;
  margin-bottom: 1rem;
}

.deletion-warning {
  color: var(--color-text-muted);
  margin-bottom: 1.5rem;
  line-height: 1.6;
}

/* Phase Refresh: user pages */
.user-profile-container {
  max-width: 1100px;
  border-radius: 16px;
  background: linear-gradient(180deg, #ffffff 0%, #fafcfb 100%);
  box-shadow: 0 12px 28px rgba(30, 43, 35, 0.08);
}

.user-tabs {
  border-bottom: 1px solid #dbe5dd;
  margin-bottom: 24px;
}

.user-tabs button {
  border: 0;
  background: transparent;
  padding: 12px 16px;
  font-size: 0.95rem;
}

.user-tab-content {
  background: #ffffff;
  border: 1px solid #e1e9e4;
  border-radius: 14px;
  padding: 18px;
}

.list-section {
  padding: 16px;
  border: 1px solid #e3ebe5;
  border-radius: 12px;
  background: #fcfefd;
}

.list-section h2 {
  border-left-color: #8faf95;
}

@media (max-width: 768px) {
  .user-profile-container {
    padding: 1rem;
    border-radius: 12px;
  }

  .user-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .user-tab-content {
    padding: 14px;
  }
}

/* Public profile page */
.public-profile-page {
  max-width: 980px;
}

.public-profile-header {
  display: flex;
  gap: 20px;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid #dfe8e2;
}

.public-profile-info {
  flex: 1;
}

.public-profile-info h1 {
  margin: 0;
  font-size: clamp(1.7rem, 3.8vw, 2.2rem);
  font-weight: 500;
  color: #1f2923;
}

.public-profile-subtitle {
  margin: 6px 0 10px;
  color: #6d766f;
  font-size: 0.92rem;
}

.public-profile-stats {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  color: #3f4942;
  font-size: 0.95rem;
}

.public-profile-follow-action {
  margin-top: 12px;
}

.public-profile-tabs .tabs.user-tabs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  border: 1px solid #dfe8e2;
  border-radius: 10px 10px 0 0;
  overflow: hidden;
  margin-bottom: 0;
}

.public-profile-tabs .tabs.user-tabs button {
  margin: 0;
  border-radius: 0;
  border-right: 1px solid #dfe8e2;
  background: #f7faf8;
  color: #6c756f;
  font-size: 0.95rem;
}

.public-profile-tabs .tabs.user-tabs button:last-child {
  border-right: 0;
}

.public-profile-tabs .tabs.user-tabs button.active {
  background: #b6c4b9;
  color: #ffffff;
}

.public-profile-tabs .user-tab-content {
  border-radius: 0 0 12px 12px;
  border-top: 0;
}

@media (max-width: 768px) {
  .public-profile-header {
    align-items: flex-start;
    gap: 14px;
  }

  .public-profile-tabs .tabs.user-tabs button {
    padding: 10px 6px;
    font-size: 0.84rem;
  }
}

/* Account profile page */
.account-profile-page {
  max-width: 980px;
}

.account-profile-header {
  display: flex;
  gap: 20px;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid #dfe8e2;
}

.account-profile-info {
  flex: 1;
}

.account-profile-info h1 {
  margin: 0;
  font-size: clamp(1.7rem, 3.8vw, 2.2rem);
  font-weight: 500;
  color: #1f2923;
}

.account-profile-stats {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  color: #3f4942;
  font-size: 0.95rem;
  margin: 8px 0 14px;
}

.account-profile-tabs .tabs.user-tabs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  border: 1px solid #dfe8e2;
  border-radius: 10px 10px 0 0;
  overflow: hidden;
  margin-bottom: 0;
}

.account-profile-tabs .tabs.user-tabs button {
  margin: 0;
  border-radius: 0;
  border-right: 1px solid #dfe8e2;
  background: #f7faf8;
  color: #6c756f;
  font-size: 0.95rem;
}

.account-profile-tabs .tabs.user-tabs button:last-child {
  border-right: 0;
}

.account-profile-tabs .tabs.user-tabs button.active {
  background: #b6c4b9;
  color: #ffffff;
}

.account-profile-tabs .user-tab-content {
  border-radius: 0 0 12px 12px;
  border-top: 0;
}

.account-profile-page #perfume-list-panel .list-section {
  position: relative;
  margin-bottom: 2.4rem;
  padding: 0 0 0 18px;
  border: none;
  border-radius: 0;
  background: transparent;
}

.account-profile-page #perfume-list-panel .list-section:last-child {
  margin-bottom: 0;
}

.account-profile-page #perfume-list-panel .list-section::before {
  content: "";
  position: absolute;
  top: 4px;
  bottom: 0;
  left: 0;
  width: 3px;
  border-radius: 999px;
  background: #8faf95;
}

.account-profile-page #perfume-list-panel .list-section h2 {
  border-left: none;
  padding-left: 0;
}

.public-profile-link-box {
  border: 1px solid #dfe8e2;
  border-radius: 12px;
  background: #f8fbf9;
  padding: 14px;
  margin-bottom: 16px;
}

.public-profile-link-box h2 {
  margin: 0 0 6px;
  font-size: 1rem;
}

.public-profile-link-box p {
  margin: 0 0 12px;
  color: #5f6861;
}

.bookmark-subtitle {
  font-size: 1rem;
  margin: 0 0 12px;
  color: #344039;
}

@media (max-width: 768px) {
  .account-profile-header {
    align-items: flex-start;
    gap: 14px;
  }

  .account-profile-tabs .tabs.user-tabs button {
    padding: 10px 6px;
    font-size: 0.84rem;
  }

  .account-profile-page #perfume-list-panel .list-section {
    padding-left: 14px;
  }
}
