/* =========================
RESET
========================= */

*{
  margin:0;
  padding:0;
  box-sizing:border-box;
}

html{
  scroll-behavior:smooth;
  overflow-x:hidden;
}

body{
  font-family:'Inter',sans-serif;
  min-height:100vh;

  background:
  linear-gradient(
    135deg,
    #eff6ff 0%,
    #f8fbff 45%,
    #eef4ff 100%
  );

  overflow-x:hidden;
  position:relative;
  color:#0f172a;
}

/* =========================
BACKGROUND
========================= */

.bg-circle{
  position:fixed;
  border-radius:50%;
  filter:blur(60px);
  z-index:0;
  pointer-events:none;
}

.circle1{
  width:260px;
  height:260px;
  background:rgba(37,99,235,0.12);
  top:-80px;
  left:-60px;
}

.circle2{
  width:220px;
  height:220px;
  background:rgba(16,185,129,0.10);
  bottom:-60px;
  right:-40px;
}

/* =========================
TOPBAR
========================= */

.topbar{
  width:100%;
  height:78px;
  padding:0 24px;

  display:flex;
  align-items:center;
  justify-content:space-between;

  background:rgba(255,255,255,0.75);

  backdrop-filter:blur(14px);

  border-bottom:1px solid #e2e8f0;

  position:sticky;
  top:0;
  z-index:100;
}

.logo{
  font-size:1.4rem;
  font-weight:800;
  color:#2563eb;
}

.back-btn{
  text-decoration:none;

  background:#eff6ff;
  color:#2563eb;

  padding:12px 18px;

  border-radius:14px;

  font-weight:700;

  transition:.3s;
}

.back-btn:hover{
  background:#2563eb;
  color:white;
}

/* =========================
MAIN
========================= */

.profile-editor{
  position:relative;
  z-index:2;

  width:100%;
  max-width:1300px;

  margin:auto;

  padding:50px 20px;

  display:grid;
  grid-template-columns:380px 1fr;

  gap:30px;
}

/* =========================
LEFT PREVIEW
========================= */

.preview-card{
  background:white;

  border-radius:34px;

  overflow:hidden;

  border:1px solid #e2e8f0;

  box-shadow:
  0 20px 40px rgba(15,23,42,.08);

  position:sticky;
  top:110px;
}

.preview-cover{
  height:140px;

  background:
  linear-gradient(
    135deg,
    #2563eb,
    #60a5fa
  );
}

/* =========================
AVATAR SECTION
========================= */

.avatar-section{
  margin-top:-70px;

  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;

  position:relative;

  padding:0 25px 40px;
}

.avatar-wrapper{
  width:140px;
  height:140px;

  border-radius:50%;

  overflow:hidden;

  position:relative;

  cursor:pointer;

  border:6px solid white;

  background:
  linear-gradient(
    135deg,
    #2563eb,
    #60a5fa
  );

  box-shadow:
  0 15px 30px rgba(37,99,235,.20);

  transition:.3s;
}

.avatar-wrapper:hover{
  transform:scale(1.03);
}

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

.avatar-overlay{
  position:absolute;
  inset:0;

  background:rgba(15,23,42,.55);

  display:flex;
  align-items:center;
  justify-content:center;

  color:white;

  font-weight:700;

  opacity:0;

  transition:.3s;
}

.avatar-wrapper:hover .avatar-overlay{
  opacity:1;
}

.online-dot{
  width:20px;
  height:20px;

  border-radius:50%;

  background:#22c55e;

  border:4px solid white;

  position:absolute;

  right:120px;
  top:105px;
}

.preview-card h2{
  margin-top:24px;

  font-size:1.7rem;

  font-weight:800;

  text-align:center;
}

.preview-role{
  margin-top:10px;

  text-align:center;

  color:#64748b;

  line-height:1.6;
}

.preview-badge{
  margin-top:22px;

  background:#eff6ff;

  color:#2563eb;

  padding:12px 22px;

  border-radius:999px;

  font-weight:700;

  font-size:.95rem;
}

/* =========================
DELETE BUTTON
========================= */

.delete-btn{
  margin-top:18px;

  border:none;

  background:#fee2e2;

  color:#dc2626;

  padding:12px 22px;

  border-radius:999px;

  font-weight:700;

  font-size:.9rem;

  cursor:pointer;

  transition:.3s;

  display:flex;
  align-items:center;
  justify-content:center;
}

.delete-btn:hover{
  background:#dc2626;
  color:white;

  transform:translateY(-2px);
}

.delete-btn:hover{
  background:#fecaca;
  transform:translateY(-2px);
}

/* =========================
RIGHT SIDE
========================= */

.editor-card{
  background:white;

  border-radius:34px;

  padding:45px;

  border:1px solid #e2e8f0;

  box-shadow:
  0 20px 40px rgba(15,23,42,.05);
}

/* HEADER */

.editor-header{
  margin-bottom:35px;
}

.editor-badge{
  display:inline-block;

  background:#dbeafe;

  color:#2563eb;

  padding:10px 18px;

  border-radius:999px;

  font-size:13px;
  font-weight:700;

  margin-bottom:20px;
}

.editor-header h1{
  font-size:2.4rem;

  font-weight:800;

  margin-bottom:14px;
}

.editor-header p{
  max-width:650px;

  line-height:1.8;

  color:#64748b;
}

/* =========================
SECTIONS
========================= */

.form-section{
  margin-top:35px;
}

.form-section h2{
  font-size:1.25rem;

  margin-bottom:24px;

  color:#2563eb;
}

/* GRID */

.input-grid{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:20px;
}

/* INPUTS */

.input-group{
  margin-bottom:22px;
}

.input-group label{
  display:block;

  margin-bottom:10px;

  font-size:14px;
  font-weight:700;

  color:#334155;
}

.input-group input,
.input-group textarea,
.input-group select{
  width:100%;

  border:none;

  background:#f8fafc;

  border:1px solid #dbeafe;

  border-radius:18px;

  padding:16px 18px;

  font-size:15px;

  font-family:'Inter',sans-serif;

  outline:none;

  transition:.3s;
}

.input-group textarea{
  resize:none;
  min-height:120px;
}

.input-group input:focus,
.input-group textarea:focus,
.input-group select:focus{
  border-color:#2563eb;

  background:white;

  box-shadow:
  0 0 0 4px rgba(37,99,235,.08);
}

.input-group input::placeholder,
.input-group textarea::placeholder{
  color:#94a3b8;
}

.char-count{
  margin-top:10px;

  font-size:13px;

  color:#94a3b8;
}

/* =========================
BUTTON
========================= */

.actions{
  margin-top:40px;
}

.save-btn{
  width:100%;

  border:none;

  background:
  linear-gradient(
    135deg,
    #2563eb,
    #1d4ed8
  );

  color:white;

  padding:18px;

  border-radius:20px;

  font-size:16px;
  font-weight:700;

  cursor:pointer;

  transition:.3s;

  box-shadow:
  0 15px 30px rgba(37,99,235,.20);
}

.save-btn:hover{
  transform:translateY(-3px);

  box-shadow:
  0 18px 35px rgba(37,99,235,.28);
}


/* =========================
AVISO PRIMER ACCESO
========================= */

.jenedu-alert-popup{
  border-radius:28px !important;
  padding:34px 28px !important;
  font-family:'Inter',sans-serif !important;
}

.jenedu-alert-title{
  color:#0f172a !important;
  font-size:1.8rem !important;
  font-weight:800 !important;
}

.first-access-alert{
  margin-top:8px;
  text-align:left;
}

.first-access-alert p{
  color:#64748b;
  font-size:1rem;
  line-height:1.7;
  margin-bottom:14px;
}

.jenedu-alert-button{
  border-radius:16px !important;
  padding:13px 24px !important;
  font-weight:800 !important;
  box-shadow:0 12px 26px rgba(37,99,235,.22) !important;
}

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

@media(max-width:1050px){

  .profile-editor{
    grid-template-columns:1fr;
  }

  .preview-card{
    position:relative;
    top:0;
  }

}

@media(max-width:768px){

  .topbar{
    height:65px;
    padding:0 14px;
  }

  .logo{
    font-size:1rem;
  }

  .back-btn{
    padding:9px 12px;
    font-size:.8rem;
  }

  .profile-editor{
    padding:22px 12px;
    gap:20px;
  }

  .editor-card{
    padding:25px 18px;
    border-radius:24px;
  }

  .preview-card{
    border-radius:24px;
  }

  .editor-header h1{
    font-size:1.7rem;
  }

  .editor-header p{
    font-size:.9rem;
  }

  .input-grid{
    grid-template-columns:1fr;
    gap:0;
  }

  .avatar-wrapper{
    width:105px;
    height:105px;
  }

  .online-dot{
    right:95px;
    top:80px;

    width:16px;
    height:16px;
  }

  .preview-card h2{
    font-size:1.25rem;
  }

  .preview-role{
    font-size:.85rem;
  }

  .delete-btn{
    padding:12px 18px;
    font-size:.85rem;
    border-radius:14px;
  }

  .input-group input,
  .input-group textarea,
  .input-group select{
    padding:14px 15px;
    font-size:14px;
    border-radius:14px;
  }

  .save-btn{
    padding:15px;
    border-radius:16px;
    font-size:.95rem;
  }

}