/* =========================================================
   PELITA UI/UX 5A1 — LOGIN RESPONSIVE BACKGROUND
   Mobile & Desktop menggunakan ilustrasi khusus masing-masing.
   ========================================================= */

:root{
  --login-green:#0f8e66;
  --login-green-2:#18b47e;
  --login-ink:#20362d;
  --login-muted:#6e7d76;
  --login-border:rgba(72,110,92,.16);
  --login-shadow:0 24px 70px rgba(21,67,49,.18);
}

*{box-sizing:border-box}

html,body{min-height:100%}

body.pelita-login-page{
  margin:0;
  min-height:100dvh;
  overflow-x:hidden;
  color:var(--login-ink);
  font-family:"Plus Jakarta Sans",system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
  -webkit-text-size-adjust:100%;
  text-size-adjust:100%;
  background-color:#eefcf5;
  background-image:url("../images/login-bg-mobile-v2.png");
  background-repeat:no-repeat;
  background-position:center top;
  background-size:cover;
}

button,input{font:inherit}

.login-stage{
  min-height:100dvh;
  display:flex;
  align-items:flex-end;
  justify-content:center;
  padding:18px 14px calc(18px + env(safe-area-inset-bottom,0px));
}

.login-panel{
  width:min(100%,430px);
  padding:18px;
  border:1px solid rgba(255,255,255,.72);
  border-radius:25px;
  background:rgba(255,255,255,.91);
  box-shadow:var(--login-shadow);
  backdrop-filter:blur(15px);
  -webkit-backdrop-filter:blur(15px);
}

.login-brand{
  display:flex;
  align-items:center;
  justify-content:center;
  min-height:66px;
  margin-bottom:14px;
  padding:10px 14px;
  overflow:hidden;
  border-radius:18px;
  background:linear-gradient(135deg,#0c7e59 0%,#0f9c6c 55%,#26c38e 100%);
}
.login-brand img{
  display:block;
  width:min(100%,255px);
  max-height:48px;
  object-fit:contain;
}

.login-copy{margin-bottom:16px}
.login-kicker{
  margin:0 0 4px;
  color:var(--login-green);
  font-size:.67rem;
  font-weight:800;
  letter-spacing:.08em;
  text-transform:uppercase;
}
.login-copy h1{
  margin:0;
  color:#20392f;
  font-size:1.45rem;
  line-height:1.1;
  font-weight:800;
  letter-spacing:-.03em;
}
.login-copy p:not(.login-kicker){
  margin:7px 0 0;
  color:var(--login-muted);
  font-size:.72rem;
  line-height:1.55;
}

.login-alert{
  display:flex;
  align-items:flex-start;
  gap:8px;
  margin-bottom:12px;
  padding:9px 10px;
  border:1px solid #f0d3d7;
  border-radius:12px;
  background:#fff2f3;
  color:#b33f4a;
  font-size:.67rem;
  line-height:1.45;
}

.login-form{display:grid;gap:12px}
.login-field{display:grid;gap:5px}
.login-field label{
  color:#506159;
  font-size:.65rem;
  font-weight:800;
}
.login-input-wrap{position:relative}
.login-input-wrap>i{
  position:absolute;
  top:50%;
  left:13px;
  transform:translateY(-50%);
  color:#729184;
  pointer-events:none;
}
.login-input-wrap input{
  display:block;
  width:100%;
  min-height:48px;
  padding:10px 42px 10px 39px;
  border:1px solid #dbe6e1;
  border-radius:13px;
  outline:0;
  background:rgba(255,255,255,.88);
  color:#2c4037;
  font-size:16px;
}
.login-input-wrap input:focus{
  border-color:#62c19d;
  box-shadow:0 0 0 3px rgba(15,142,102,.10);
}
.password-toggle{
  position:absolute;
  top:50%;
  right:7px;
  display:grid;
  place-items:center;
  width:36px;
  height:36px;
  transform:translateY(-50%);
  border:0;
  border-radius:10px;
  background:transparent;
  color:#789087;
  cursor:pointer;
}

.login-submit{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  min-height:49px;
  margin-top:2px;
  border:0;
  border-radius:14px;
  background:linear-gradient(135deg,#0d815c,#0ea16d 60%,#27c18d);
  color:#fff;
  font-size:.75rem;
  font-weight:800;
  box-shadow:0 10px 20px rgba(15,142,102,.20);
  cursor:pointer;
}
.login-submit:active{transform:translateY(1px)}

.login-flow-note{
  display:grid;
  grid-template-columns:38px minmax(0,1fr);
  align-items:center;
  gap:8px;
  margin-top:13px;
  padding:9px;
  border:1px solid #dce9e3;
  border-radius:13px;
  background:#f3faf6;
}
.login-flow-icon{
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  width:38px;
  height:38px;
  border-radius:11px;
  background:#e1f4eb;
  color:var(--login-green);
  line-height:1;
}
.login-flow-icon>.bi,.login-flow-icon>.bi::before{display:block;line-height:1;margin:0}
.login-flow-note strong,.login-flow-note div>span{display:block}
.login-flow-note strong{font-size:.60rem;color:#405149}
.login-flow-note div>span{margin-top:2px;color:#74827b;font-size:.52rem;line-height:1.4}

.login-footer{
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:2px;
  margin-top:12px;
  color:#87948e;
  font-size:.50rem;
  text-align:center;
}

/* Pilih akses */
.access-success{
  display:inline-flex;
  align-items:center;
  gap:6px;
  margin-bottom:11px;
  padding:6px 9px;
  border-radius:999px;
  background:#e4f6ed;
  color:#0c8059;
  font-size:.58rem;
  font-weight:800;
}
.access-user{
  display:grid;
  grid-template-columns:44px minmax(0,1fr);
  align-items:center;
  gap:9px;
  margin-bottom:12px;
  padding:9px 10px;
  border:1px solid #e0e8e4;
  border-radius:13px;
  background:#f8fbf9;
}
.access-avatar{
  display:grid;
  place-items:center;
  width:44px;
  height:44px;
  border-radius:13px;
  background:#e2f4eb;
  color:#0f8961;
}
.access-user small,.access-user strong,.access-user div>span{display:block}
.access-user small{font-size:.49rem;color:#89958f}
.access-user strong{margin-top:1px;font-size:.67rem;color:#34473e}
.access-user div>span{margin-top:2px;font-size:.52rem;color:#7c8983}
.access-list{display:grid;gap:8px}
.access-form{margin:0}
.access-button{
  width:100%;
  display:grid;
  grid-template-columns:44px minmax(0,1fr) 24px;
  align-items:center;
  gap:9px;
  min-height:64px;
  padding:9px 10px;
  border:1px solid #dfe7e3;
  border-radius:14px;
  background:rgba(255,255,255,.92);
  color:#31443a;
  text-align:left;
  cursor:pointer;
}
.access-role-icon{
  display:grid;
  place-items:center;
  width:44px;
  height:44px;
  border-radius:13px;
  background:#e5f5ed;
  color:#10835d;
  font-size:1rem;
}
.role-guru .access-role-icon{background:#e8f4ff;color:#3475a5}
.role-wali_kelas .access-role-icon{background:#e5f5ed;color:#10835d}
.role-kesiswaan .access-role-icon{background:#fff1dd;color:#a36d00}
.role-admin .access-role-icon{background:#eee8fb;color:#7251a0}
.role-siswa .access-role-icon{background:#fee9eb;color:#c44955}
.access-role-copy strong,.access-role-copy small{display:block}
.access-role-copy strong{font-size:.66rem;font-weight:800}
.access-role-copy small{margin-top:2px;color:#78867f;font-size:.52rem;line-height:1.35}
.access-arrow{color:#94a19b}
.access-footer{
  display:flex;
  flex-wrap:wrap;
  justify-content:center;
  gap:4px 7px;
  margin-top:13px;
  padding-top:10px;
  border-top:1px solid #edf1ef;
  color:#819088;
  font-size:.51rem;
  text-align:center;
}
.access-footer a{color:#0e845d;font-weight:800;text-decoration:none}

/* Desktop / landscape */
@media(min-width:900px){
  body.pelita-login-page{
    background-image:url("../images/login-bg-desktop.png");
    background-position:center center;
    background-size:cover;
  }

  .login-stage{
    align-items:center;
    justify-content:flex-start;
    width:100%;
    padding:40px clamp(46px,7vw,120px) 40px clamp(120px,11vw,190px);
  }

  .login-panel{
    width:min(40vw,440px);
    padding:22px;
    border-radius:27px;
    background:rgba(255,255,255,.90);
    box-shadow:0 30px 80px rgba(23,73,54,.20);
  }

  .login-brand{
    min-height:72px;
    margin-bottom:16px;
  }
  .login-brand img{width:min(100%,280px);max-height:52px}

  .login-copy h1{font-size:1.72rem}
  .login-copy p:not(.login-kicker){font-size:.76rem}
  .login-kicker{font-size:.69rem}
  .login-field label,.login-submit{font-size:.71rem}
  .login-flow-note strong{font-size:.64rem}
  .login-flow-note div>span{font-size:.56rem}
  .login-footer{font-size:.53rem}

  .access-panel{
    width:min(42vw,470px);
  }
  .access-button:hover{
    border-color:#9bd5be;
    transform:translateY(-1px);
    box-shadow:0 9px 20px rgba(30,83,61,.08);
  }
  .access-role-copy strong{font-size:.70rem}
  .access-role-copy small{font-size:.56rem}
}

/* Mobile pendek */
@media(max-width:430px) and (max-height:760px){
  .login-stage{padding:12px 10px calc(12px + env(safe-area-inset-bottom,0px))}
  .login-panel{padding:14px;border-radius:21px}
  .login-brand{min-height:55px;margin-bottom:10px}
  .login-brand img{max-height:40px;width:min(100%,215px)}
  .login-copy{margin-bottom:11px}
  .login-copy h1{font-size:1.23rem}
  .login-copy p:not(.login-kicker){font-size:.64rem}
  .login-form{gap:9px}
  .login-input-wrap input{min-height:44px}
  .login-submit{min-height:45px}
  .login-flow-note{margin-top:10px}
  .login-footer{margin-top:8px}
}

@media(prefers-reduced-motion:reduce){
  *{scroll-behavior:auto!important;transition:none!important}
}
