/* Workelia Portal - Fondation & Auth V1.0 */
:root {
  --wpf-bg: #f4eef1;
  --wpf-purple: #5b3df5;
  --wpf-purple-dark: #4324b0;
  --wpf-deep: #17008a;
  --wpf-text: #12055f;
  --wpf-muted: #756f87;
  --wpf-white: #ffffff;
  --wpf-border: rgba(91, 61, 245, .13);
  --wpf-shadow: 0 24px 60px rgba(67, 36, 176, .12);
}

.wpf-root {
  width: 100vw;
  max-width: none;
  min-height: 100vh;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  background: var(--wpf-bg);
  color: var(--wpf-text);
  overflow-x: hidden;
  font-family: inherit;
}

.wpf-root * {
  box-sizing: border-box;
}

.wpf-mobilebar {
  display: none;
}

.wpf-app {
  width: 100%;
  min-height: 100vh;
  display: grid;
  grid-template-columns: 286px minmax(0, 1fr);
  background:
    radial-gradient(circle at 90% 4%, rgba(91,61,245,.15), transparent 28%),
    linear-gradient(135deg, #fbf9ff 0%, var(--wpf-bg) 100%);
}

.wpf-sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  background: linear-gradient(180deg, var(--wpf-purple) 0%, var(--wpf-purple-dark) 58%, var(--wpf-deep) 100%);
  color: #fff;
  padding: 28px 22px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.wpf-sidebar::before {
  content: "";
  position: absolute;
  width: 270px;
  height: 270px;
  border-radius: 999px;
  background: rgba(255,255,255,.12);
  left: -120px;
  bottom: -80px;
}

.wpf-brand {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 12px;
  align-items: center;
  margin-bottom: 34px;
}

.wpf-mark {
  width: 44px;
  height: 44px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  background: #fff;
  color: var(--wpf-purple);
  font-weight: 950;
  font-size: 20px;
}

.wpf-brand strong {
  display: block;
  font-size: 20px;
  line-height: 1;
  letter-spacing: -.04em;
}

.wpf-brand span {
  display: block;
  margin-top: 5px;
  font-size: 12px;
  opacity: .75;
}

.wpf-nav {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 7px;
  overflow-y: auto;
  padding-right: 3px;
}

.wpf-nav a,
.wpf-sidebar-footer a {
  color: rgba(255,255,255,.82) !important;
  text-decoration: none !important;
  border-radius: 15px;
  padding: 12px 14px;
  font-weight: 780;
  font-size: 14px;
  transition: .18s ease;
}

.wpf-nav a:hover,
.wpf-nav a.active,
.wpf-sidebar-footer a:hover {
  background: rgba(255,255,255,.16);
  color: #fff !important;
}

.wpf-sidebar-footer {
  position: relative;
  z-index: 1;
  margin-top: auto;
  padding-top: 16px;
}

.wpf-main {
  min-width: 0;
  padding: 38px;
}

.wpf-page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 28px;
}

.wpf-eyebrow {
  margin: 0 0 8px;
  color: var(--wpf-purple);
  text-transform: uppercase;
  letter-spacing: .08em;
  font-size: 12px;
  font-weight: 950;
}

.wpf-page-header h1 {
  margin: 0;
  color: var(--wpf-deep);
  font-size: clamp(34px, 4vw, 54px);
  line-height: .98;
  letter-spacing: -.055em;
  font-weight: 900;
}

.wpf-muted {
  color: var(--wpf-muted);
  line-height: 1.6;
}

.wpf-kpis {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  margin-bottom: 22px;
}

.wpf-kpis.consultant {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.wpf-kpi,
.wpf-card,
.wpf-auth-card {
  background: rgba(255,255,255,.78);
  border: 1px solid var(--wpf-border);
  border-radius: 26px;
  box-shadow: 0 16px 40px rgba(67,36,176,.08);
  backdrop-filter: blur(10px);
}

.wpf-kpi {
  padding: 22px;
  min-height: 134px;
}

.wpf-kpi:nth-child(1) {
  background: linear-gradient(135deg, #5b3df5, #4324b0);
  color: #fff;
}

.wpf-kpi:nth-child(1) span,
.wpf-kpi:nth-child(1) strong,
.wpf-kpi:nth-child(1) small {
  color: #fff;
}

.wpf-kpi span {
  display: block;
  color: var(--wpf-muted);
  font-weight: 880;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: .04em;
}

.wpf-kpi strong {
  display: block;
  margin: 10px 0 8px;
  color: var(--wpf-deep);
  font-size: 34px;
  line-height: 1;
  letter-spacing: -.04em;
  font-weight: 920;
}

.wpf-kpi small {
  color: var(--wpf-muted);
}

.wpf-grid,
.wpf-admin-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.wpf-admin-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.wpf-card {
  padding: 26px;
}

.wpf-card h2,
.wpf-auth-card h1 {
  margin: 0 0 12px;
  color: var(--wpf-deep);
  letter-spacing: -.035em;
}

.wpf-card p,
.wpf-card li,
.wpf-auth-card p {
  color: var(--wpf-muted);
  line-height: 1.65;
}

.wpf-list {
  margin: 0;
  padding-left: 18px;
}

.wpf-btn,
.wpf-auth-card input[type="submit"],
.wpf-form .button-primary {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: var(--wpf-deep) !important;
  color: #fff !important;
  border: 0 !important;
  border-radius: 999px !important;
  padding: 12px 21px !important;
  text-decoration: none !important;
  font-weight: 880 !important;
  cursor: pointer;
  box-shadow: 0 14px 26px rgba(91,61,245,.16);
}

.wpf-auth-wrap {
  width: 100vw;
  min-height: 100vh;
  margin-left: calc(50% - 50vw);
  background: var(--wpf-bg);
  display: grid;
  place-items: center;
  padding: 24px;
}

.wpf-auth-card {
  width: min(460px, 100%);
  padding: 34px;
}

.wpf-auth-card input[type="text"],
.wpf-auth-card input[type="password"],
.wpf-auth-card input[type="email"],
.wpf-form input,
.wpf-form select {
  width: 100%;
  border: 1px solid var(--wpf-border);
  border-radius: 14px;
  padding: 12px 14px;
  margin-top: 6px;
  background: #fff;
}

.wpf-form {
  display: grid;
  gap: 14px;
}

.wpf-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 14px;
}

.wpf-admin {
  background: var(--wpf-bg);
  padding: 20px;
  border-radius: 24px;
}

.wpf-admin .wpf-card {
  background: #fff;
  margin: 18px 0;
}

.wpf-table-wrap {
  overflow-x: auto;
}

/* TABLET */
@media (max-width: 1100px) {
  .wpf-app {
    grid-template-columns: 92px minmax(0, 1fr);
  }

  .wpf-sidebar {
    padding: 22px 12px;
  }

  .wpf-brand {
    justify-content: center;
  }

  .wpf-brand div:not(.wpf-mark) {
    display: none;
  }

  .wpf-nav a,
  .wpf-sidebar-footer a {
    font-size: 0;
    padding: 13px;
    text-align: center;
  }

  .wpf-nav a::first-letter,
  .wpf-sidebar-footer a::first-letter {
    font-size: 15px;
  }

  .wpf-nav a::before {
    content: "•";
    font-size: 25px;
    line-height: 1;
  }

  .wpf-kpis,
  .wpf-kpis.consultant,
  .wpf-admin-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .wpf-main {
    padding: 28px;
  }
}

/* MOBILE */
@media (max-width: 767px) {
  .wpf-mobilebar {
    position: sticky;
    top: 0;
    z-index: 30;
    display: flex;
    align-items: center;
    gap: 12px;
    height: 58px;
    padding: 0 16px;
    background: var(--wpf-deep);
    color: #fff;
  }

  .wpf-menu-toggle {
    appearance: none;
    border: 0;
    background: rgba(255,255,255,.14);
    color: #fff;
    border-radius: 12px;
    width: 38px;
    height: 38px;
    font-size: 22px;
  }

  .wpf-app {
    display: block;
    min-height: calc(100vh - 58px);
  }

  .wpf-sidebar {
    position: fixed;
    left: 0;
    top: 58px;
    bottom: 0;
    width: 84vw;
    max-width: 340px;
    height: auto;
    z-index: 40;
    transform: translateX(-102%);
    transition: transform .22s ease;
    border-radius: 0 26px 26px 0;
  }

  body.wpf-menu-open .wpf-sidebar {
    transform: translateX(0);
  }

  .wpf-brand div:not(.wpf-mark) {
    display: block;
  }

  .wpf-brand {
    justify-content: flex-start;
  }

  .wpf-nav a,
  .wpf-sidebar-footer a {
    font-size: 14px;
    text-align: left;
  }

  .wpf-nav a::before {
    display: none;
  }

  .wpf-main {
    padding: 22px;
  }

  .wpf-page-header {
    display: grid;
  }

  .wpf-page-header h1 {
    font-size: 34px;
  }

  .wpf-kpis,
  .wpf-kpis.consultant,
  .wpf-grid,
  .wpf-admin-grid,
  .wpf-form-grid {
    grid-template-columns: 1fr;
  }

  .wpf-kpi,
  .wpf-card {
    border-radius: 22px;
    padding: 20px;
  }

  .wpf-btn {
    width: 100%;
  }
}

/* V3.2 Auth */
.wpf-auth-wrap{width:100vw;min-height:100vh;margin-left:calc(50% - 50vw);margin-right:calc(50% - 50vw);display:grid;place-items:center;background:radial-gradient(circle at 88% 8%,rgba(91,61,245,.18),transparent 28%),linear-gradient(135deg,#fbf9ff 0%,var(--wpf-bg) 100%);padding:28px;color:var(--wpf-text)}
.wpf-auth-card-v32,.wpf-auth-card{width:min(520px,100%);padding:34px}.wpf-auth-card h1{margin:0 0 12px;color:var(--wpf-deep);letter-spacing:-.04em;font-size:clamp(30px,4vw,44px);line-height:1}.wpf-form{display:grid;gap:16px}.wpf-form label{display:grid;gap:7px;font-weight:850;color:var(--wpf-text)}.wpf-form input,.wpf-form select{width:100%;border:1px solid var(--wpf-border);border-radius:16px;padding:13px 14px;background:#fff;color:var(--wpf-text);font:inherit;outline:none}.wpf-form input:focus{border-color:var(--wpf-purple);box-shadow:0 0 0 4px rgba(91,61,245,.10)}.wpf-form small{font-weight:500;color:var(--wpf-muted)}.wpf-check{display:flex!important;grid-template-columns:auto 1fr!important;align-items:center;gap:10px!important}.wpf-check input{width:auto}.wpf-btn{display:inline-flex!important;align-items:center;justify-content:center;gap:10px;background:linear-gradient(135deg,var(--wpf-purple),var(--wpf-purple-dark));color:#fff!important;text-decoration:none!important;border:0;border-radius:16px;padding:13px 18px;font-weight:900;cursor:pointer;box-shadow:0 14px 30px rgba(91,61,245,.22)}.wpf-alert{padding:13px 15px;border-radius:16px;margin:0 0 14px;font-weight:760}.wpf-alert.error{background:#fff1f1;color:#9b1111;border:1px solid rgba(155,17,17,.16)}.wpf-alert.success{background:#effaf3;color:#176b36;border:1px solid rgba(23,107,54,.16)}.wpf-qr{display:grid;gap:12px;place-items:center;padding:20px;border:1px dashed var(--wpf-border);border-radius:22px;background:rgba(255,255,255,.62);margin:18px 0}.wpf-qr img{width:220px;height:220px;border-radius:12px;background:#fff}.wpf-qr code{display:block;max-width:100%;overflow-wrap:anywhere;background:#fff;border:1px solid var(--wpf-border);border-radius:12px;padding:10px;color:var(--wpf-deep)}

/* v3.3.0 — Auth dark/light Workelia */
.wpf-auth-wrap{
  width:100vw;min-height:100vh;margin-left:calc(50% - 50vw);margin-right:calc(50% - 50vw);
  display:grid;place-items:center;padding:34px;background:#050509;color:#f7f4ff;font-family:Inter,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
}
.wpf-auth-wrap[data-wpf-theme="dark"]{
  background:radial-gradient(circle at 80% 0%,rgba(111,85,255,.28),transparent 34%),linear-gradient(135deg,#050509 0%,#0b0b12 52%,#160f2c 100%);
}
.wpf-auth-wrap[data-wpf-theme="light"]{
  background:radial-gradient(circle at 80% 0%,rgba(111,85,255,.16),transparent 34%),linear-gradient(135deg,#fbfaff 0%,#f6f4ff 52%,#eee9ff 100%);color:#171321;
}
.wpf-auth-card-v32{width:min(520px,94vw)!important;border-radius:30px!important;padding:34px!important;background:linear-gradient(180deg,rgba(255,255,255,.08),rgba(255,255,255,.035))!important;border:1px solid rgba(168,150,255,.20)!important;box-shadow:0 28px 90px rgba(0,0,0,.30)!important;color:#f7f4ff!important;backdrop-filter:blur(16px)!important;}
.wpf-auth-wrap[data-wpf-theme="light"] .wpf-auth-card-v32{background:rgba(255,255,255,.92)!important;border:1px solid rgba(91,61,245,.16)!important;box-shadow:0 28px 90px rgba(33,24,84,.12)!important;color:#171321!important;}
.wpf-auth-card-v32 h1{margin:0 0 12px!important;font-size:clamp(32px,4vw,54px)!important;line-height:.95!important;letter-spacing:-.06em!important;color:inherit!important;}
.wpf-auth-card-v32 p,.wpf-auth-card-v32 .wpf-muted{color:rgba(245,242,255,.70)!important;line-height:1.6!important;}
.wpf-auth-wrap[data-wpf-theme="light"] .wpf-auth-card-v32 p,.wpf-auth-wrap[data-wpf-theme="light"] .wpf-auth-card-v32 .wpf-muted{color:#635c72!important;}
.wpf-auth-card-v32 label{display:block;margin:16px 0 8px!important;color:inherit!important;font-weight:850!important;}
.wpf-auth-card-v32 input{width:100%!important;min-height:48px!important;border-radius:16px!important;border:1px solid rgba(168,150,255,.24)!important;background:rgba(255,255,255,.07)!important;color:#fff!important;padding:12px 14px!important;}
.wpf-auth-wrap[data-wpf-theme="light"] .wpf-auth-card-v32 input{background:#fff!important;color:#171321!important;border-color:rgba(91,61,245,.18)!important;}
.wpf-auth-card-v32 .wpf-check{display:flex!important;align-items:center!important;gap:10px!important;}
.wpf-auth-card-v32 .wpf-check input{width:auto!important;min-height:0!important;}
.wpf-auth-card-v32 .wpf-btn,.wpf-auth-card-v32 button{width:100%!important;margin-top:14px!important;min-height:50px!important;border-radius:999px!important;background:linear-gradient(135deg,#8b6dff 0%,#5b3df5 48%,#2b218e 100%)!important;color:#fff!important;border:1px solid rgba(255,255,255,.18)!important;font-weight:950!important;box-shadow:0 16px 38px rgba(91,61,245,.30)!important;}
.wpf-auth-card-v32 a{color:#a896ff!important;font-weight:850!important;}
.wpf-auth-wrap[data-wpf-theme="light"] .wpf-auth-card-v32 a{color:#5b3df5!important;}
