:root {
  /* Color principal */
  --primary: #052a51;
  --primary-dark: #041f3d;
  --primary-light: #0a3b6f;

  /* Fondos */
  --bg-section: #f6f8fb;
  --bg-card: #ffffff;

  /* Texto */
  --text-main: #052a51;
  --text-muted: #6b7280;

  /* Premium */
  --gold-premium: #d4af37;
  --gold-light: #f5d76e;

  /* Estados */
  --success: #2ecc71;
  --danger: #e74c3c;
}

:root {
  --primary: #052a51;
  --primary-light: #0b3f78;
  --primary-soft: #eaf1f8;

  --text-dark: #1f2a37;
  --text-muted: #6b7280;

  --border: #d1d9e6;
  --bg-input: #f9fbfd;

  --danger: #dc2626;
  --success: #16a34a;

  --gold-premium: #d4af37;
}






.settings-card h2 {
  text-align: center;
  margin-bottom: 25px;
}

.form-modal {
  margin: 50px auto;
  width: 95%;
  max-width: 600px;
  background: #fff;
  padding: 30px;
  border-radius: 16px;
  transition: all 0.35s ease;
}

.form-modal.active {
  display: block;
  opacity: 1;
}

.form-modal h2 {
  margin-bottom: 25px;
  color: var(--primary);
  text-align: center;
}

.form-group {
  display: flex;
  gap: 15px;
  margin-bottom: 18px;
}

.form-group input,
.form-group select{
  width: 100%;
  padding: 14px 16px;
  border-radius: 12px;
  border: 1px solid #d1d9e6;
  font-size: 0.95rem;
  transition: all 0.25s ease;
  background: #f9fbfd;
}

.subsection-title {
  font-size: 1.05rem;
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  font-weight: 600;
}

.field-with-error {
  display: flex;
  flex-direction: column;
  width: 100%;
}

.input-error-text {
  display: none;
  margin-top: 6px;
  font-size: 0.85rem;
  color: #e74c3c;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.input-error-text.show {
  display: block;
  opacity: 1;
}



#area{
  margin-bottom: 10px;
}

#otherArea{
  margin-bottom: 10px;
}

#skillInput{
  margin-bottom: 10px;
}

.input-add-container {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
}

#addSkillBtn {
  width: 50px;
  height: 50px;
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: 50%;
  padding: 0 14px;
  font-size: 1.25rem;
  cursor: pointer;
  transition: all 0.25s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

#addSkillBtn:active {
  transform: scale(0.95);
}

@media (max-width: 480px) {
  .input-add-container {
    flex-direction: row;
    gap: 6px;
  }

  #addSkillBtn {
    padding: 0 12px;
    font-size: 1.1rem;
  }
}



/* ---------- CV ---------- */
.upload-wrapper {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.cv-preview {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #f9fbfd;
  border: 1px solid #d1d9e6;
  border-radius: 10px;
  padding: 10px;
  color: var(--primary);
  font-size: 0.9rem;
}

.cv-preview i {
  font-size: 1.4rem;
}

#cvError{
  margin-top: 5px;
}

.cv-info {
  display: flex;
  align-items: center;
  gap: 10px;
}

.cv-text {
  font-weight: 600;
}

.cv-actions {
  display: flex;
  gap: 10px;
}

.cv-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  border: none;
  padding: 6px 10px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 13px;
  text-decoration: none;
  transition: 0.2s;
}

.disabled {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none; /* 🔥 CLAVE */
}

/* VER */
.cv-btn.view {
  background: #2d8cff;
  color: white;
}

.cv-btn.view:hover {
  background: #1a6fe0;
}

/* DESCARGAR */
.cv-btn.download {
  background: #00c853;
  color: white;
}

.cv-btn.download:hover {
  background: #00a844;
}

/* REEMPLAZAR */
.cv-btn.replace {
  background: #ff9800;
  color: white;
}

.cv-btn.replace:hover {
  background: #e68900;
}

.form-group input:focus,
.form-group select:focus{
  outline: none;
  border-color: var(--primary);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(5,42,81,0.12);
}

.submit-btn {
  width: 100%;
  padding: 15px;
  border-radius: 30px;
  border: none;
  background: linear-gradient(
    135deg,
    var(--primary),
    var(--primary-light)
  );
  color: #fff;
  font-size: 1.05rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.submit-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 25px rgba(5,42,81,0.35);
}

.submit-btn:active {
  transform: scale(0.97);
}

.close-form {
  position: absolute;
  top: 18px;
  right: 20px;
  background: none;
  border: none;
  font-size: 1.8rem;
  cursor: pointer;
  color: #999;
  transition: color 0.2s ease, transform 0.2s ease;
}

.close-form:hover {
  color: var(--danger);
  transform: rotate(90deg);
}

.premium-only {
  background: #fdfbf4;
  border: 1px dashed var(--gold-premium);
  padding: 14px;
  border-radius: 12px;
}




.checkbox {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.9rem;
  color: var(--primary);
}

.switch {
  display: flex;
  align-items: center;
  gap: 12px;
}

.switch input {
  display: none;
}

.slider {
  width: 46px;
  height: 26px;
  background: #ccc;
  border-radius: 50px;
  position: relative;
  cursor: pointer;
  transition: 0.3s;
}

.slider::before {
  content: "";
  width: 22px;
  height: 22px;
  background: #fff;
  border-radius: 50%;
  position: absolute;
  top: 2px;
  left: 2px;
  transition: 0.3s;
}

.switch input:checked + .slider {
  background: var(--primary);
}

.switch input:checked + .slider::before {
  transform: translateX(20px);
}



@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.form-group input:hover,
.form-group select:hover,
textarea:hover {
  border-color: var(--primary);
}


.upload-box {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px;
  border: 2px dashed var(--primary);
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.2s ease;
  font-weight: 500;
}

.upload-box:hover {
  background: var(--primary-soft);
  border-color: var(--primary);
}

textarea#presentation {
  margin-top: 10px;
  resize: none;
  min-height: 100px;
  padding: 12px;
  border-radius: 12px;
  border: 1px solid var(--border);
  width: 100%;
  transition: all 0.25s ease;
}

textarea#presentation:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(5, 42, 81, 0.15);
}

.candidate-form {
  display: flex;
  flex-direction: column;
}

.form-section {
  margin-bottom: 28px;
  animation: fadeUp 0.5s ease both;
}

.form-section h3 {
  font-size: 1.05rem;
  margin-bottom: 14px;
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: 10px;
}

.form-section-address h3 {
  font-size: 1.05rem;
  margin-bottom: 14px;
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: 10px;
}

input,
select,
textarea {
  width: 100%;
  padding: 14px 16px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--bg-input);
  font-size: 0.95rem;
  color: var(--text-dark);
  transition: all 0.25s ease;
}

input::placeholder,
textarea::placeholder {
  color: var(--text-muted);
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--primary);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(5,42,81,0.15);
}

input:hover,
select:hover,
textarea:hover {
  border-color: var(--primary);
}

.form-group {
  display: flex;
  gap: 15px;
  margin-bottom: 18px;
}

.form-group.column {
  flex-direction: column;
}


select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg fill='none' stroke='%23052a51' stroke-width='2' viewBox='0 0 24 24'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  background-size: 16px;
}

select[multiple] {
  height: auto;
  padding: 12px;
  background-image: none;
}


input[list] {
  cursor: pointer;
}


#skills {
  display: flex;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.chip {
  background: var(--primary);
  color: #fff;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 0.85rem;
  margin: 4px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.chip button {
  background: none;
  border: none;
  color: #fff;
  font-size: 0.85rem;
  cursor: pointer;
  margin-bottom: -5px;
}

.add-btn {
  background: transparent;
  border: 1px dashed var(--primary);
  color: var(--primary);
  padding: 10px;
  border-radius: 10px;
  cursor: pointer;
  font-size: 0.9rem;
  transition: 0.25s;
}

.add-btn:hover {
  background: var(--primary-soft);
}

.remove-btn {
  pointer-events: auto;
  z-index: 10;
  cursor: pointer;
  background: transparent;
  border: none;
}


.remove-btn:hover{
    cursor: pointer;
}


.upload-box {
  border: 2px dashed var(--primary);
  padding: 18px;
  border-radius: 14px;
  text-align: center;
  cursor: pointer;
  transition: 0.3s;
  background: var(--bg-input);
  color: var(--primary);
  margin-bottom: 10px;
}

.upload-box i {
  font-size: 1.6rem;
  margin-bottom: 6px;
  display: block;
}

.upload-box:hover {
  background: var(--primary-soft);
}

.error {
  color: var(--danger);
  font-size: 0.85rem;
  margin-top: 4px;
}

/* Mensajes de error específicos para habilidades y estudio */
#error, .error {
  color: var(--danger, #e74c3c);
  font-size: 0.85rem;
  display: block;
  margin-top: -8px;  /* sube un poco el mensaje hacia el input */
  margin-bottom: 15px; /* espacio debajo del mensaje */
}



.account-box {
  border: 1px solid var(--border);
  padding: 20px;
  border-radius: 14px;
  background: var(--bg-input);
}

.account-box input{
  margin-bottom: 10px;
  margin-top: 10px;
}


.switch {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.9rem;
  color: var(--primary);
}

.switch input {
  display: none;
}

.slider {
  width: 46px;
  height: 26px;
  background: #ccc;
  border-radius: 50px;
  position: relative;
  cursor: pointer;
  transition: 0.3s;
}

.slider::before {
  content: "";
  width: 22px;
  height: 22px;
  background: #fff;
  border-radius: 50%;
  position: absolute;
  top: 2px;
  left: 2px;
  transition: 0.3s;
}

.switch input:checked + .slider {
  background: var(--primary);
}

.switch input:checked + .slider::before {
  transform: translateX(20px);
}

.input-error {
  border-color: #e74c3c !important;
  box-shadow: 0 0 0 3px rgba(231, 76, 60, 0.35) !important;
}

.input-success {
  border-color: #2ecc71 !important;
  box-shadow: 0 0 0 3px rgba(46, 204, 113, 0.35) !important;
}

select.input-error {
  border: 2px solid #e74c3c !important;
  box-shadow: 0 0 0 3px rgba(231, 76, 60, 0.35) !important;
}

select.input-success {
  border: 2px solid #2ecc71 !important;
  box-shadow: 0 0 0 3px rgba(46, 204, 113, 0.35) !important;
}



.phone-dropdown {
  position: relative;
  width: 220px;
  cursor: pointer;
  font-family: sans-serif;
}
.phone-dropdown .selected {
  display: flex;
  align-items: center;
  gap: 5px;
  height: 100%;
  border: 1px solid #ccc;
  padding: 5px;
  border-radius: 4px;
  position: relative;
}
.phone-dropdown .selected img {
  width: 20px;
  height: 14px;
  object-fit: cover;
}
.phone-dropdown .options {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  border: 1px solid #ccc;
  max-height: 250px;
  overflow-y: auto;
  background: white;
  z-index: 10000000;
  border-radius: 4px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.15);
}
.phone-dropdown.active .options {
  display: block;
}
.phone-dropdown .options li {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 5px;
}
.phone-dropdown .options li:hover {
  background: #f0f0f0;
}
.phone-dropdown .options img {
  width: 20px;
  height: 14px;
  object-fit: cover;
}



.submit-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 25px rgba(5,42,81,0.35);
}

.submit-btn:active {
  transform: scale(0.97);
}



#addressCountry {
  height: 50px;
}


#addressCountry option {
  font-size: 0.9rem;
  padding: 6px 10px;
}




.password-wrapper {
  position: relative;
  width: 100%;
}

.password-wrapper input {
  width: 100%;
  padding-right: 40px; /* espacio para el ojito */
}

.password-wrapper .toggle-password {
  position: absolute;
  top: 50%;
  right: 12px;
  transform: translateY(-50%);
  cursor: pointer;
  color: #999;
  font-size: 16px;
}

.password-wrapper .toggle-password:hover {
  color: #333;
}

.password-rules {
  display: none;
  margin-top: 6px;
  font-size: 0.85rem;
  color: #e53935; /* rojo */
}

.password-match {
  display: block;
  margin-top: 6px;
  font-size: 0.85rem;
  color: #e53935;
}

.password-rules.valid {
  color: #28a745; /* verde */
}

.password-rules.invalid {
  color: #dc3545; /* rojo */
}

.password-match.valid {
  color: #28a745;
}

.password-match.invalid {
  color: #dc3545;
}




.form-message {
  display: none;
  margin-bottom: 18px;
  padding: 14px 18px;
  border-radius: 12px;
  font-size: 0.95rem;
  font-weight: 500;
  animation: fadeDown 0.35s ease;
}

.form-message.error {
  display: block;
  background: #fdecea;
  color: #b42318;
  border: 1px solid #f5c2c7;
}

.form-message.success {
  display: block;
  background: #ecfdf3;
  color: #027a48;
  border: 1px solid #abefc6;
}

@keyframes fadeDown {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.checkbox{
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.9rem;
  color: green;
}

.switch-change-status {
  display: flex;
  align-items: center;
  gap: 12px;
  justify-self: center;
}

.switch-change-status input {
  display: none;
}



.change-status {
  padding: 14px;
  border-radius: 12px;
}


.estado-activo {
  background: #27ae60;
}

.estado-desactivado {
  background: #7f8c8d;
}

.estado-contratado {
  background: #0a3d62;
}


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

/* TEXTO ARRIBA */
.status-top-label {
  font-size: 0.75rem;
  font-weight: bold;
  color: #fff;
  letter-spacing: 1px;
  opacity: 0;
  transition: 0.3s;
}

.estado-contratado .status-top-label {
  opacity: 1;
}

/* CUANDO ES CONTRATADO */
.estado-contratado .status-top-label {
  opacity: 1;
}

/* WRAPPER */
.status-switch-wrapper {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  width: 100%;
}

.status-label {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 4px 8px;
  border-radius: 6px;
  transition: 0.3s;
  color: #fff;
  opacity: 0.8;
}

/* IZQUIERDA */
.estado-desactivado .status-label.left {
  background: rgba(0,0,0,0.2);
  opacity: 1;
}

/* DERECHA */
.estado-activo .status-label.right {
  background: rgba(0,0,0,0.2);
  opacity: 1;
}

/* CONTRATADO */
.estado-contratado .status-label {
  background: rgba(255,255,255,0.15);
  opacity: 1;
}

.status-label.left {
  justify-self: end;
  margin-right: 15px;

}

.status-label.right {
  justify-self: start;
  margin-left: 15px;
}

/* SWITCH */
.slider-change-status {
  width: 60px;
  height: 28px;
  background: #ccc;
  border-radius: 50px;
  position: relative;
  cursor: pointer;
  transition: 0.3s;
}

/* BOLITA */
.slider-change-status::before {
  content: "";
  width: 22px;
  height: 22px;
  background: #fff;
  border-radius: 50%;
  position: absolute;
  top: 3px;
  left: 3px;
  transition: 0.3s;
}

/* ACTIVO */
.switch-change-status input:checked + .slider-change-status {
  background: #1a7640;
}

.switch-change-status input:checked + .slider-change-status::before {
  transform: translateX(30px);
}

/* 🔥 CONTRATADO (CENTRO) */
.estado-contratado .slider-change-status {
  background: #072941;
}

.estado-contratado .slider-change-status::before {
  transform: translateX(15px); /* 🔥 CENTRO */
}


.info-wrapper {
  position: relative;
  display: inline-flex;
  align-items: center;
  cursor: pointer;
}

.status-tooltip {
  position: absolute;
  bottom: 130%;
  left: 50%;
  transform: translateX(-50%);
  width: 260px;
  background: #1f2937;
  color: #fff;
  font-size: 13px;
  line-height: 1.4;
  padding: 10px 12px;
  border-radius: 8px;
  display: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
  z-index: 10;
}

/* FLECHITA */
.status-tooltip::after {
  content: "";
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border-width: 6px;
  border-style: solid;
  border-color: #1f2937 transparent transparent transparent;
}

.info-wrapper:hover .status-tooltip {
  display: block;
}


.inicial-btns-change{
  margin-top: 10px;
}

.icon-back{
  font-size: 1.05rem;
  color: #052a51;
  cursor: pointer;
}



@media (max-width: 480px) {
  .form-group {
    flex-direction: column;
  }

  .form-modal {
    padding: 22px;
  }
}

@media (max-width: 600px) {
  .form-modal {
    max-height: 100vh;
    border-radius: 0;
  }
}

@media (max-width: 400px) {
  .submit-btn {
    font-size: 0.95rem;
    padding: 13px;
  }
}


