/* ===== PROFILE EDIT PAGE ===== */

.pe-header {
  padding: 100px 0 0;
  background: var(--bg);
  border-bottom: 1.5px solid var(--border);
}

.pe-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 24px;
}

.pe-header-left {
  display: flex;
  align-items: center;
  gap: 16px;
}

.pe-back {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  border: 1.5px solid var(--border);
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  text-decoration: none;
  transition: all 0.2s;
}

.pe-back:hover {
  border-color: var(--primary);
  color: var(--primary);
}

.pe-header-left h1 {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--text);
}

.pe-header-left span {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.88rem;
  color: var(--muted);
}

/* Progress steps */
.pe-steps {
  display: flex;
  gap: 0;
  padding-top: 8px;
}

.pe-step {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 14px 24px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
  border-bottom: 3px solid transparent;
  transition: all 0.2s;
  background: none;
  border-top: none;
  border-left: none;
  border-right: none;
  white-space: nowrap;
}

.pe-step:hover {
  color: var(--text);
}

.pe-step.active {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

.pe-step.completed {
  color: #2ea043;
}

.pe-step-num {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #f0f0f2;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  flex-shrink: 0;
}

.pe-step.active .pe-step-num {
  background: var(--accent);
  color: #fff;
}

.pe-step.completed .pe-step-num {
  background: #2ea043;
  color: #fff;
}

/* Layout */
.pe-layout {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 36px;
  padding: 36px 0 80px;
}

/* Sections */
.pe-section {
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: 18px;
  padding: 32px;
  margin-bottom: 24px;
}

.pe-section-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
}

.pe-section-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: rgba(232,68,58,0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  flex-shrink: 0;
}

.pe-section h2 {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
}

.pe-section h2 span {
  display: block;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.82rem;
  font-weight: 400;
  color: var(--muted);
  margin-top: 2px;
}

/* Form fields */
.pe-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 16px;
}

.pe-row.full {
  grid-template-columns: 1fr;
}

.pe-field {
  margin-bottom: 0;
}

.pe-field label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 6px;
}

.pe-field label .required {
  color: var(--accent);
}

.pe-field input,
.pe-field select,
.pe-field textarea {
  width: 100%;
  padding: 12px 16px;
  border-radius: 10px;
  border: 1.5px solid var(--border);
  font-family: 'Inter', sans-serif;
  font-size: 0.92rem;
  color: var(--text);
  background: var(--bg);
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  box-sizing: border-box;
}

.pe-field input:focus,
.pe-field select:focus,
.pe-field textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(232,68,58,0.1);
}

.pe-field textarea {
  min-height: 100px;
  resize: vertical;
  line-height: 1.7;
}

.pe-field input::placeholder,
.pe-field textarea::placeholder {
  color: #bbb;
}

.pe-field-hint {
  font-size: 0.78rem;
  color: var(--muted);
  margin-top: 4px;
}

/* Avatar upload */
.pe-avatar-upload {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 24px;
}

.pe-avatar-preview {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent) 0%, #ff7b6b 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.6rem;
  color: #fff;
  flex-shrink: 0;
  position: relative;
  cursor: pointer;
}

.pe-avatar-overlay {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: rgba(0,0,0,0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.2s;
  color: #fff;
}

.pe-avatar-preview:hover .pe-avatar-overlay {
  opacity: 1;
}

.pe-avatar-info p {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 4px;
}

.pe-avatar-info span {
  font-size: 0.78rem;
  color: var(--muted);
}

/* Experience / Education blocks */
.pe-entry {
  background: #f7f7f8;
  border-radius: 14px;
  padding: 24px;
  margin-bottom: 16px;
  position: relative;
}

.pe-entry-remove {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 28px;
  height: 28px;
  border-radius: 6px;
  border: none;
  background: none;
  color: var(--muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.2s;
}

.pe-entry-remove:hover {
  color: var(--accent);
}

.pe-add-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 14px;
  border-radius: 12px;
  border: 2px dashed var(--border);
  background: none;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.pe-add-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
}

/* Skills input */
.pe-skills-input {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 10px;
  border: 1.5px solid var(--border);
  min-height: 48px;
  align-items: center;
  cursor: text;
  transition: border-color 0.2s;
}

.pe-skills-input:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(232,68,58,0.1);
}

.pe-skill-chip {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 4px 12px;
  border-radius: 100px;
  background: var(--primary);
  color: #fff;
  font-size: 0.82rem;
  font-weight: 500;
}

.pe-skill-chip button {
  background: none;
  border: none;
  color: rgba(255,255,255,0.7);
  cursor: pointer;
  padding: 0;
  font-size: 1rem;
  line-height: 1;
  display: flex;
}

.pe-skill-chip button:hover {
  color: #fff;
}

.pe-skills-input input {
  border: none;
  outline: none;
  font-size: 0.88rem;
  flex: 1;
  min-width: 120px;
  padding: 4px 0;
  background: transparent;
}

/* Actions bar */
.pe-actions {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  padding: 24px 0;
  border-top: 1.5px solid var(--border);
  margin-top: 8px;
}

/* Sidebar */
.pe-sidebar {
  position: sticky;
  top: 100px;
  align-self: start;
}

.pe-sidebar-card {
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: 16px;
  padding: 24px;
  margin-bottom: 20px;
}

.pe-sidebar-card h4 {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.pe-progress-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 0;
  border-top: 1px solid var(--border);
}

.pe-progress-item:first-child {
  border-top: none;
  padding-top: 0;
}

.pe-progress-check {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: transparent;
  transition: all 0.2s;
}

.pe-progress-check.done {
  background: #2ea043;
  border-color: #2ea043;
  color: #fff;
}

.pe-progress-label {
  font-size: 0.85rem;
  color: var(--muted);
}

.pe-progress-check.done + .pe-progress-label {
  color: var(--text);
}

.pe-sidebar-tip {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 14px;
  background: rgba(232,68,58,0.04);
  border-radius: 12px;
  margin-top: 8px;
}

.pe-sidebar-tip svg {
  flex-shrink: 0;
  color: var(--accent);
  margin-top: 1px;
}

.pe-sidebar-tip p {
  font-size: 0.82rem;
  color: #555;
  line-height: 1.5;
}

/* ===== RESPONSIVE ===== */

@media (max-width: 1024px) {
  .pe-layout { grid-template-columns: 1fr; }
  .pe-sidebar { position: static; }
}

@media (max-width: 768px) {
  .pe-header-inner { flex-direction: column; align-items: flex-start; gap: 12px; }
  .pe-steps { overflow-x: auto; }
  .pe-step { padding: 12px 16px; }
  .pe-row { grid-template-columns: 1fr; }
  .pe-section { padding: 24px; }
  .pe-actions { flex-direction: column; }
  .pe-actions .btn { width: 100%; text-align: center; }
}

@media (max-width: 480px) {
  .pe-header { padding: 80px 0 0; }
  .pe-avatar-upload { flex-direction: column; text-align: center; }
  .pe-entry { padding: 18px; }
}
