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

html, body {
  height: 100%;
  font-family: 'Inter', sans-serif;
  background: #f4f4f4;
}

/* ── Navbar (mobile only) ── */
.navbar { display: none; }
.navbar-title { font-size: 17px; font-weight: 600; color: #1F2937; }

/* ── Layout ── */
.main-layout { display: flex; height: 100vh; }

/* ── Sidebar ── */
.sidebar {
  width: 250px; background: #2E2E2E;
  border-top-right-radius: 40px; border-bottom-right-radius: 40px;
  display: flex; flex-direction: column; flex-shrink: 0;
}
.side-nav {
  padding: 24px 16px; color: #fff;
  display: flex; flex-direction: column; gap: 12px;
  width: 100%; flex: 1; overflow: auto;
}
.side-title { font-size: 18px; font-weight: 600; opacity: .9; margin-bottom: 6px; }
.side-menu { list-style: none; display: grid; gap: 6px; margin: 0; padding: 0; }
.side-menu a {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 14px; width: 100%; border-radius: 14px;
  color: rgba(255,255,255,.9); text-decoration: none;
  font-weight: 500; transition: background .2s ease;
}
.side-menu a:hover { background: #3a3a3a; }
.side-menu a.active { background: #1F6F79; color: #fff; box-shadow: 0 6px 18px rgba(31,111,121,.35); }
.side-menu a::before {
  content: ""; width: 8px; height: 8px; border-radius: 50%;
  background: transparent; transition: background .2s ease; flex-shrink: 0;
}
.side-menu a.active::before { background: #fff; }
.side-footer { margin-top: auto; padding: 16px; border-top: 1px solid rgba(255,255,255,.08); }
.logout-btn {
  width: 100%; padding: 10px 14px; border-radius: 12px;
  border: 1px solid #ef4444; background: transparent;
  color: #ef4444; font-size: 14px; font-weight: 500;
  font-family: 'Inter', sans-serif; cursor: pointer;
  transition: background .2s ease, color .2s ease;
}
.logout-btn:hover { background: #ef4444; color: #fff; }

/* ── Content ── */
.content {
  flex: 1; overflow-y: auto;
  padding: 40px; display: flex; flex-direction: column; gap: 24px;
}

/* ── Page header ── */
.page-header {
  display: flex; align-items: center; gap: 20px;
  margin-bottom: 8px;
}
.avatar {
  width: 64px; height: 64px; border-radius: 50%;
  background: #1F6F79; color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 22px; font-weight: 700; flex-shrink: 0;
}
.page-title { font-size: 24px; font-weight: 700; color: #1a1a1a; }
.page-sub { font-size: 14px; color: #6b7280; margin-top: 2px; }

/* ── Cards ── */
.card {
  background: #fff; border-radius: 20px;
  box-shadow: 0 2px 12px rgba(0,0,0,.06);
}
.card-header {
  display: flex; align-items: center; gap: 12px;
  padding: 20px 24px 0;
}
.card-title { font-size: 16px; font-weight: 600; color: #1a1a1a; }
.card-sub { font-size: 13px; color: #6b7280; margin-left: auto; }
.badge-readonly {
  margin-left: auto;
  font-size: 11px; font-weight: 600; color: #6b7280;
  background: #f3f4f6; border: 1px solid #e5e7eb;
  padding: 2px 8px; border-radius: 999px;
}
.card-body { padding: 20px 24px 24px; display: flex; flex-direction: column; gap: 16px; }

/* ── Fields ── */
.field { display: flex; flex-direction: column; gap: 6px; flex: 1; }
.field label { font-size: 13px; font-weight: 500; color: #374151; }
.field input, .field select {
  padding: 10px 14px; border: 1px solid #e5e7eb; border-radius: 10px;
  font-size: 14px; font-family: 'Inter', sans-serif; color: #1a1a1a;
  background: #fafafa; transition: border-color .15s ease, box-shadow .15s ease;
  outline: none;
}
.field input:focus, .field select:focus { border-color: #1F6F79; box-shadow: 0 0 0 3px rgba(31,111,121,.12); background: #fff; }
.field input:disabled, .field select:disabled {
  background: #f3f4f6; color: #6b7280; cursor: not-allowed;
}
.field-row { display: flex; gap: 16px; }
.optional { font-size: 11px; color: #9ca3af; font-weight: 400; }

/* ── Password field with eye toggle ── */
.field-password { position: relative; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.field-password label { font-size: 13px; font-weight: 500; color: #374151; }
.field-password input {
  padding: 10px 42px 10px 14px; border: 1px solid #e5e7eb; border-radius: 10px;
  font-size: 14px; font-family: 'Inter', sans-serif; color: #1a1a1a;
  background: #fafafa; transition: border-color .15s ease, box-shadow .15s ease;
  outline: none; width: 100%;
}
.field-password input:focus { border-color: #1F6F79; box-shadow: 0 0 0 3px rgba(31,111,121,.12); background: #fff; }
.field-password input:disabled { background: #f3f4f6; color: #6b7280; cursor: not-allowed; }
.pw-eye {
  position: absolute; right: 12px; bottom: 10px;
  background: none; border: none; cursor: pointer; padding: 0;
  color: #9ca3af; line-height: 1; display: flex; align-items: center;
}
.pw-eye:hover { color: #1F6F79; }
.pw-eye svg { width: 18px; height: 18px; display: block; }

/* ── Inline OTP step ── */
.otp-step { display: none; flex-direction: column; gap: 12px; }
.otp-step.visible { display: flex; }
.otp-hint { font-size: 13px; color: #6b7280; }
.otp-hint strong { color: #1a1a1a; }
.otp-row { display: flex; gap: 10px; align-items: flex-end; }
.otp-row input {
  width: 140px; padding: 10px 14px; border: 1px solid #e5e7eb; border-radius: 10px;
  font-size: 16px; font-weight: 600; letter-spacing: 4px; text-align: center;
  font-family: 'Inter', sans-serif; color: #1a1a1a;
  background: #fafafa; outline: none;
  transition: border-color .15s, box-shadow .15s;
}
.otp-row input:focus { border-color: #1F6F79; box-shadow: 0 0 0 3px rgba(31,111,121,.12); background: #fff; }
.otp-resend {
  font-size: 13px; color: #1F6F79; background: none; border: none;
  cursor: pointer; font-family: 'Inter', sans-serif; padding: 0; text-decoration: underline;
}

/* ── Buttons ── */
.card-actions { display: flex; align-items: center; gap: 16px; margin-top: 4px; flex-wrap: wrap; }
.btn-primary {
  padding: 10px 22px; background: #1F6F79; color: #fff;
  border: none; border-radius: 10px; font-size: 14px; font-weight: 600;
  font-family: 'Inter', sans-serif; cursor: pointer;
  transition: background .2s ease;
}
.btn-primary:hover { background: #185f68; }
.btn-primary:disabled { background: #9ca3af; cursor: not-allowed; }
.btn-outline {
  padding: 9px 20px; background: transparent; color: #1F6F79;
  border: 1px solid #1F6F79; border-radius: 10px;
  font-size: 14px; font-weight: 500; font-family: 'Inter', sans-serif;
  cursor: pointer; transition: background .2s ease;
}
.btn-outline:hover { background: #f0f9fa; }
.save-msg { font-size: 13px; font-weight: 500; }

/* ── Locker box ── */
.locker-description { font-size: 14px; color: #6b7280; }
.locker-box {
  background: #f7fbfc; border: 1px solid #d0eaed;
  border-radius: 12px; padding: 16px 20px;
  display: flex; flex-direction: column; gap: 12px;
}
.locker-field { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.locker-label { font-size: 13px; color: #6b7280; font-weight: 500; flex-shrink: 0; }
.locker-value { font-size: 14px; font-weight: 600; color: #1a1a1a; text-align: right; }

/* ── Account info grid ── */
.info-grid { gap: 0 !important; }
.info-row {
  display: flex; justify-content: space-between; align-items: center;
  padding: 12px 0; border-bottom: 1px solid #f3f4f6;
}
.info-row:last-child { border-bottom: none; }
.info-label { font-size: 14px; color: #6b7280; }
.info-value { font-size: 14px; font-weight: 600; color: #1a1a1a; }

/* ── Sidebar overlay ── */
.sidebar-overlay { display: none; }

/* ── Mobile ── */
@media (max-width: 900px) {
  html, body { background: #f7f7f7; }

  .navbar {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 12px; padding: 10px 14px;
    position: sticky; top: 0; z-index: 1000;
    background: rgba(255,255,255,.92);
    -webkit-backdrop-filter: saturate(180%) blur(10px);
    backdrop-filter: saturate(180%) blur(10px);
    border-bottom: 1px solid #e5e7eb;
  }
  .navbar-title { display: flex; align-items: center; font-size: 17px; font-weight: 600; }

  .dash-toggle {
    display: inline-grid; width: 38px; height: 38px; place-items: center;
    border: 1px solid #e5e7eb; border-radius: 10px; background: #fff;
  }
  .dash-toggle img { width: 22px; height: 22px; display: block; }

  .main-layout { display: block; height: auto; }

  .sidebar {
    position: fixed; inset: 0 auto 0 0; z-index: 1100;
    width: min(84vw, 320px); border-radius: 0 20px 20px 0;
    transform: translateX(-100%); transition: transform .25s ease;
    box-shadow: 8px 0 24px rgba(0,0,0,.12);
  }
  .sidebar.open { transform: translateX(0); }
  .sidebar-overlay {
    position: fixed; inset: 0; z-index: 1090;
    display: none; background: rgba(0,0,0,.38);
  }
  .sidebar-overlay.show { display: block; }

  .content { padding: 16px; gap: 16px; }

  .page-header { gap: 14px; }
  .avatar { width: 52px; height: 52px; font-size: 18px; }
  .page-title { font-size: 20px; }

  .card { border-radius: 16px; }
  .card-header { padding: 16px 16px 0; }
  .card-body { padding: 16px; gap: 14px; }

  .field-row { flex-direction: column; gap: 14px; }

  .locker-field { flex-direction: column; align-items: flex-start; gap: 2px; }
  .locker-value { text-align: left; }

  .otp-row { flex-direction: column; align-items: flex-start; }
  .otp-row input { width: 100%; letter-spacing: 6px; }
}
