@import url("https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap");

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

:root{
  --bg: #f4f6fb;
  --bg-soft: #eef1f8;
  --card: #ffffff;
  --text: #1a1d26;
  --muted: #64748b;
  --border: #e8ecf4;
  --primary: #5d5fef;
  --primary-soft: rgba(93, 95, 239, 0.12);
  --primary-700: #4f46e5;
  --accent-blue: #4895ef;
  --danger: #dc2626;
  --success: #16a34a;
  --success-soft: #dcfce7;
  --shadow-sm: 0 4px 14px rgba(26, 29, 38, 0.06);
  --shadow-md: 0 12px 32px rgba(26, 29, 38, 0.08);
  --shadow-lg: 0 24px 48px rgba(93, 95, 239, 0.18);
  --radius: 16px;
  --radius-lg: 20px;
  --sidebar-w: 268px;
}

body{
  font-family: "Plus Jakarta Sans", "Segoe UI", system-ui, -apple-system, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

a{ color: inherit; }

.app-shell{
  min-height: 100vh;
  display: grid;
  grid-template-columns: var(--sidebar-w) 1fr;
}

.sidebar{
  position: sticky;
  top: 0;
  height: 100vh;
  padding: 20px 14px;
  border-right: 1px solid var(--border);
  background: linear-gradient(180deg, #ffffff 0%, #fafbff 100%);
  display: flex;
  flex-direction: column;
  gap: 16px;
  box-shadow: 4px 0 24px rgba(26, 29, 38, 0.04);
}

.sidebar-brand{
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 12px 18px;
  border-bottom: 1px solid var(--border);
}

/* Full logo image (replaces gradient “APU” tile) */
.brand-mark{
  width: auto;
  height: 44px;
  max-width: min(200px, 100%);
  object-fit: contain;
  object-position: left center;
  border-radius: 12px;
  flex-shrink: 0;
  display: block;
  box-shadow: 0 8px 22px rgba(93, 95, 239, 0.16);
}

.brand-name{
  font-weight: 800;
  font-size: 15px;
  line-height: 1.25;
  color: var(--primary);
  letter-spacing: -0.02em;
}

.brand-subtitle{
  color: var(--muted);
  font-size: 12px;
  margin-top: 3px;
  font-weight: 500;
}

.sidebar-nav{
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 6px 4px;
  flex: 1;
  overflow-y: auto;
}

.sidebar-item{
  appearance: none;
  border: 1px solid transparent;
  background: transparent;
  width: 100%;
  text-align: left;
  padding: 11px 12px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  cursor: pointer;
  color: #334155;
  font-size: 14px;
  font-weight: 600;
  transition: background 180ms ease, border-color 180ms ease, transform 160ms ease, color 180ms ease;
}

.sidebar-item::before{
  content: "";
  width: 20px;
  height: 20px;
  flex: 0 0 20px;
  background: currentColor;
  -webkit-mask: var(--nav-icon) center / 20px 20px no-repeat;
  mask: var(--nav-icon) center / 20px 20px no-repeat;
  opacity: 0.95;
}

.sidebar-item[href$="home.html"]{
  --nav-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m3 11 9-8 9 8'/%3E%3Cpath d='M5 10v10h14V10'/%3E%3Cpath d='M9 20v-6h6v6'/%3E%3C/svg%3E");
}

.sidebar-item[href$="dashboard.html"]{
  --nav-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='3' width='7' height='7'/%3E%3Crect x='14' y='3' width='7' height='7'/%3E%3Crect x='14' y='14' width='7' height='7'/%3E%3Crect x='3' y='14' width='7' height='7'/%3E%3C/svg%3E");
}

.sidebar-item[href$="my-wallet.html"]{
  --nav-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M19 7V6a2 2 0 0 0-2-2H5a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-1'/%3E%3Cpath d='M16 12h5v4h-5a2 2 0 0 1 0-4Z'/%3E%3C/svg%3E");
}

.sidebar-item[href$="lockers.html"]{
  --nav-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 21h12'/%3E%3Cpath d='M8 21V4h8v17'/%3E%3Cpath d='M11 12h.01'/%3E%3C/svg%3E");
}

.sidebar-item[href$="my-reservation.html"]{
  --nav-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M19 21 12 17 5 21V5a2 2 0 0 1 2-2h10a2 2 0 0 1 2 2Z'/%3E%3Cpath d='m9 10 2 2 4-4'/%3E%3C/svg%3E");
}

.sidebar-item[href$="my-lockers.html"]{
  --nav-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='5' y='11' width='14' height='10' rx='2'/%3E%3Cpath d='M8 11V7a4 4 0 0 1 8 0v4'/%3E%3Cpath d='M12 15v2'/%3E%3C/svg%3E");
}

.sidebar-item[href$="pin-access.html"]{
  --nav-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='7.5' cy='15.5' r='3.5'/%3E%3Cpath d='m10 13 8-8'/%3E%3Cpath d='m15 5 3 3'/%3E%3Cpath d='m13 7 3 3'/%3E%3C/svg%3E");
}

.sidebar-item[href$="reservation-history.html"]{
  --nav-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 12a9 9 0 1 0 3-6.7'/%3E%3Cpath d='M3 3v6h6'/%3E%3Cpath d='M12 7v5l3 2'/%3E%3C/svg%3E");
}

.sidebar-item[href$="profile.html"]{
  --nav-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='8' r='4'/%3E%3Cpath d='M4 21a8 8 0 0 1 16 0'/%3E%3C/svg%3E");
}

.sidebar-item[href$="about.html"]{
  --nav-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='M12 8h.01'/%3E%3Cpath d='M11 12h1v5h1'/%3E%3C/svg%3E");
}

.sidebar-item.danger{
  --nav-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M10 17 15 12 10 7'/%3E%3Cpath d='M15 12H3'/%3E%3Cpath d='M13 3h7v18h-7'/%3E%3C/svg%3E");
}

.sidebar-item:hover{
  background: var(--bg-soft);
  border-color: rgba(93, 95, 239, 0.08);
}

.sidebar-item:active{ transform: translateY(1px); }

.sidebar-item.active{
  background: linear-gradient(90deg, var(--primary-soft), rgba(93, 95, 239, 0.06));
  border-color: rgba(93, 95, 239, 0.12);
  color: var(--primary);
  font-weight: 700;
  position: relative;
}

.sidebar-item.active::after{
  content: "";
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 56%;
  max-height: 28px;
  background: linear-gradient(180deg, var(--primary), var(--accent-blue));
  border-radius: 99px;
  box-shadow: 0 2px 8px rgba(93, 95, 239, 0.4);
}

.sidebar-ico{ width: 20px; display: inline-flex; justify-content: center; }

.sidebar-footer{
  margin-top: auto;
  padding: 8px 4px 4px;
  border-top: 1px solid var(--border);
}

.sidebar-item.danger{
  border: 1px solid var(--border);
  color: #64748b;
  background: #fff;
  box-shadow: var(--shadow-sm);
  margin-top: 8px;
  font-weight: 600;
}

.sidebar-item.danger:hover{
  color: var(--primary);
  border-color: rgba(93, 95, 239, 0.25);
  background: var(--primary-soft);
  box-shadow: var(--shadow-md);
}

.main{
  min-width: 0;
  display: flex;
  flex-direction: column;
  background: var(--bg);
}

.topbar{
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, 0.82);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
  padding: 14px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 72px;
}

.topbar::before{
  content: "🔍  Search lockers…";
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  width: min(420px, 36vw);
  padding: 11px 16px 11px 40px;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: var(--bg-soft);
  color: var(--muted);
  font-size: 13px;
  font-weight: 500;
  pointer-events: none;
  box-shadow: inset 0 1px 2px rgba(255, 255, 255, 0.8);
}

@media (max-width: 900px){
  .topbar::before{ display: none; }
}

.page-title-wrap{ position: relative; z-index: 1; }

.page-title{
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--text);
}

.page-subtitle{
  margin-top: 4px;
  font-size: 13px;
  color: var(--muted);
  font-weight: 500;
  max-width: 320px;
}

.topbar-right{
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.icon-btn{
  width: 40px;
  height: 40px;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: #fff;
  cursor: pointer;
  display: grid;
  place-items: center;
  text-decoration: none;
  font-size: 18px;
  transition: transform 160ms ease, box-shadow 180ms ease, border-color 180ms ease;
  box-shadow: var(--shadow-sm);
}

.icon-btn:hover{
  border-color: rgba(93, 95, 239, 0.25);
  box-shadow: var(--shadow-md);
}

.icon-btn:active{ transform: translateY(1px); }

.user-chip{
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: #fff;
  max-width: 320px;
  box-shadow: var(--shadow-sm);
}

.user-dot{
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #22c55e;
  box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.2);
}

.user-info{
  color: #475569;
  font-weight: 600;
  font-size: 12px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.logout-btn{
  border: 1px solid rgba(93, 95, 239, 0.2);
  background: #fff;
  color: var(--primary);
  padding: 10px 16px;
  border-radius: 14px;
  font-weight: 700;
  font-size: 13px;
  cursor: pointer;
  transition: background 180ms ease, transform 160ms ease, box-shadow 180ms ease;
  box-shadow: var(--shadow-sm);
}

.logout-btn:hover{
  background: var(--primary-soft);
  box-shadow: 0 8px 22px rgba(93, 95, 239, 0.15);
}

.logout-btn:active{ transform: translateY(1px); }

.content{
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 22px;
  max-width: 980px;
}

.content.content--profile{
  max-width: 1120px;
  margin: 0 auto;
  width: 100%;
  gap: 20px;
}

.profile-top-grid{
  display: grid;
  grid-template-columns: 1fr minmax(240px, 320px);
  gap: 20px;
  align-items: stretch;
}

.profile-mid-grid{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  align-items: start;
}

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

.dash-card{
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  padding: 22px 24px;
}

.dash-card-title{
  font-size: 15px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
  margin-bottom: 6px;
}

.dash-card-head{
  margin-bottom: 18px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

.dash-card-lead{
  font-size: 13px;
  color: var(--muted);
  font-weight: 500;
  margin-bottom: 18px;
  line-height: 1.5;
}

.profile-hero-card{
  padding: 24px;
}

.profile-hero-inner{
  display: flex;
  gap: 24px;
  align-items: flex-start;
  flex-wrap: wrap;
}

.profile-avatar-wrap{
  position: relative;
  flex-shrink: 0;
}

.profile-hero-meta{
  flex: 1;
  min-width: 200px;
}

.profile-hero-name{
  font-size: clamp(22px, 2.5vw, 28px);
  font-weight: 900;
  letter-spacing: -0.03em;
  margin-bottom: 12px;
}

.profile-hero-tags{
  margin-bottom: 12px;
}

.pill{
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}

.pill--primary{
  background: var(--primary-soft);
  color: var(--primary-700);
  border: 1px solid rgba(93, 95, 239, 0.15);
}

.profile-hero-line{
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 6px;
}

.profile-hero-line--muted{
  color: var(--muted);
  font-weight: 500;
  font-size: 13px;
  margin-bottom: 16px;
}

.btn-primary-solid{
  appearance: none;
  border: none;
  cursor: pointer;
  padding: 11px 20px;
  border-radius: 14px;
  font-size: 14px;
  font-weight: 800;
  font-family: inherit;
  color: #fff;
  background: linear-gradient(135deg, var(--primary), #6366f1);
  box-shadow: 0 12px 28px rgba(93, 95, 239, 0.28);
  transition: filter 160ms ease, transform 160ms ease;
}

.btn-primary-solid:hover:not(:disabled){
  filter: brightness(1.05);
}

.btn-primary-solid:active:not(:disabled){
  transform: translateY(1px);
}

.btn-primary-solid:disabled{
  opacity: 0.55;
  cursor: not-allowed;
}

.btn-primary-solid--muted{
  opacity: 0.75;
}

.btn-outline{
  appearance: none;
  cursor: not-allowed;
  padding: 10px 18px;
  border-radius: 14px;
  font-size: 13px;
  font-weight: 800;
  font-family: inherit;
  color: var(--primary-700);
  background: #fff;
  border: 1px solid rgba(93, 95, 239, 0.35);
  opacity: 0.7;
}

.btn-outline.is-enabled{
  cursor: pointer;
  opacity: 1;
  transition: background 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.btn-outline.is-enabled:hover{
  background: var(--primary-soft);
  box-shadow: var(--shadow-sm);
}

.btn-outline.is-enabled:active{
  transform: translateY(1px);
}

.account-standing-card .dash-card-title{
  margin-bottom: 16px;
}

.standing-stat{
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 14px;
  background: var(--bg-soft);
  border: 1px solid var(--border);
  margin-bottom: 12px;
}

.standing-label{
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.standing-value{
  font-size: 18px;
  font-weight: 900;
  color: var(--primary-700);
}

.standing-value--soft{
  background: var(--primary-soft);
  padding: 6px 14px;
  border-radius: 12px;
  font-size: 16px;
}

.badge-success{
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  border-radius: 10px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.04em;
  color: var(--success);
  background: var(--success-soft);
  border: 1px solid rgba(22, 163, 74, 0.2);
}

.badge-success.status-pending{
  color: #b45309;
  background: #fff7ed;
  border-color: rgba(245, 158, 11, 0.28);
}

.badge-success.status-suspended{
  color: #dc2626;
  background: #fff1f2;
  border-color: rgba(244, 63, 94, 0.25);
}

.badge-success.status-muted{
  color: var(--muted);
  background: #eef2f7;
  border-color: rgba(148, 163, 184, 0.3);
}

.standing-footnote{
  margin-top: 16px;
  font-size: 12px;
  color: var(--muted);
  font-weight: 600;
}

.profile-form--grid{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px 20px;
}

.form-group--full{
  grid-column: 1 / -1;
}

.security-card{
  padding: 22px 24px 24px;
}

.security-block{
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.security-heading{
  font-size: 14px;
  font-weight: 800;
  margin-bottom: 6px;
  color: var(--text);
}

.security-text{
  font-size: 13px;
  color: var(--muted);
  line-height: 1.55;
  max-width: 360px;
}

.profile-modal{
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(15, 23, 42, 0.56);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}

.profile-modal.show{
  display: flex;
}

.profile-modal-dialog{
  position: relative;
  width: min(100%, 450px);
  padding: 27px 26px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--card);
  box-shadow: 0 25px 70px rgba(0, 0, 0, 0.28);
}

.profile-modal-dialog h2{
  color: var(--text);
  font-size: 21px;
  font-weight: 800;
  letter-spacing: -0.03em;
  margin: 0 40px 8px 0;
}

.profile-modal-lead{
  margin-bottom: 21px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.profile-modal-close{
  position: absolute;
  right: 13px;
  top: 13px;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font-size: 26px;
  line-height: 1;
}

.profile-modal-close:hover{
  color: var(--text);
  background: var(--bg-soft);
}

.password-field{
  margin-bottom: 16px;
}

.password-field label{
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.password-field input{
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #fff;
  color: var(--text);
  font: inherit;
  font-size: 14px;
  outline: none;
}

.password-field input:focus{
  border-color: #c7d2fe;
  box-shadow: 0 0 0 4px rgba(93, 95, 239, 0.12);
}

.password-submit{
  width: 100%;
  margin-top: 4px;
}

.password-status{
  min-height: 0;
  margin-top: 15px;
  border-radius: 12px;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.5;
  text-align: center;
}

.password-status:not(:empty){
  padding: 11px 13px;
  color: #92400e;
  border: 1px solid #fde68a;
  background: #fffbeb;
}

.password-status.success:not(:empty){
  color: #065f46;
  border-color: #a7f3d0;
  background: #ecfdf5;
}

.password-status.error:not(:empty){
  color: #991b1b;
  border-color: #fecaca;
  background: #fef2f2;
}

.site-footer{
  margin-top: 8px;
  padding: 20px 4px 8px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-size: 12px;
  color: var(--muted);
  font-weight: 600;
  border-top: 1px solid var(--border);
}

.site-footer-links{
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.site-footer a{
  color: var(--primary-700);
  text-decoration: none;
  font-weight: 700;
}

.site-footer a:hover{
  text-decoration: underline;
}

.site-footer .dot{
  opacity: 0.5;
}

/* Profile Header (legacy avatar block — reused in hero) */
.profile-avatar-container {
  position: relative;
  display: inline-block;
  margin-bottom: 20px;
}

.profile-avatar-wrap .profile-avatar{
  margin: 0;
}

.profile-avatar {
  width: 120px;
  height: 120px;
  margin: 0 auto;
  background: var(--primary-soft);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 3px solid rgba(93, 95, 239, 0.2);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  position: relative;
}

.profile-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}

.profile-image-hidden {
  display: none;
}

.profile-input-hidden {
  display: none;
}

#formActions {
  display: none;
}

.profile-form--grid .form-actions{
  grid-column: 1 / -1;
  margin-top: 4px;
}

.upload-btn {
  position: absolute;
  bottom: 0;
  right: 0;
  width: 40px;
  height: 40px;
  background: linear-gradient(135deg, var(--primary), #6366f1);
  border: 1px solid rgba(93, 95, 239, 0.3);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 20px;
  color: #fff;
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
  box-shadow: 0 12px 28px rgba(93, 95, 239, 0.3);
  z-index: 10;
}

.upload-btn:hover {
  filter: brightness(1.05);
}

.avatar-icon {
  font-size: 52px;
  color: var(--primary-700);
}

.profile-header h2 {
  margin-top: 12px;
  font-size: 22px;
  font-weight: 900;
  letter-spacing: -0.3px;
}

.profile-email-legacy{ display: none; }

/* Profile Container */
.profile-container {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  box-shadow: var(--shadow-sm);
}

.profile-section {
  position: relative;
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
  padding-bottom: 15px;
  border-bottom: 1px solid var(--border);
}

.section-header h3 {
  font-size: 16px;
  font-weight: 900;
  letter-spacing: -0.2px;
  color: var(--primary);
}

.edit-btn {
  padding: 10px 14px;
  background: var(--primary-soft);
  border: 1px solid rgba(93, 95, 239, 0.15);
  color: var(--primary-700);
  border-radius: 14px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.edit-btn:hover {
  background: rgba(93, 95, 239, 0.18);
}

/* Profile Form */
.profile-form {
  display: flex;
  flex-direction: column;
  gap: 25px;
}

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

.form-group label {
  color: var(--muted);
  font-weight: 800;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 10px;
}

.form-group input,
.form-group select {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  font-size: 14px;
  transition: border-color 160ms ease, box-shadow 160ms ease;
  background: #fff;
  color: var(--text);
  font-family: inherit;
}

.form-group input::placeholder {
  color: rgba(255, 255, 255, 0.6);
}

.form-group input:focus,
.form-group select:focus {
  border-color: #c7d2fe;
  outline: none;
  box-shadow: 0 0 0 4px rgba(93, 95, 239, 0.12);
}

.form-group input[readonly],
.form-group select[disabled] {
  cursor: not-allowed;
  opacity: 0.7;
}

.form-group input[readonly]:focus,
.form-group select[disabled]:focus {
  transform: none;
  box-shadow: none;
}

select{ cursor: pointer; }

select:disabled {
  cursor: not-allowed;
  background-image: none;
}

/* Form Actions */
.form-actions {
  display: flex;
  gap: 15px;
  margin-top: 20px;
  flex-wrap: wrap;
}

.save-btn,
.cancel-btn {
  flex: 1;
  min-width: 150px;
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease, border-color 160ms ease;
  border: none;
}

.save-btn {
  background: linear-gradient(135deg, var(--primary), #6366f1);
  color: #fff;
  border-radius: 14px;
  box-shadow: 0 12px 28px rgba(93, 95, 239, 0.3);
}

.save-btn:hover {
  filter: brightness(1.05);
}

.cancel-btn {
  background: #fff;
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: var(--shadow-sm);
}

.cancel-btn:hover {
  background: var(--bg-soft);
  border-color: rgba(93, 95, 239, 0.2);
}

/* Status Message */
.status-message {
  margin-top: 20px;
  padding: 14px;
  border-radius: 12px;
  text-align: center;
  font-size: 14px;
  font-weight: 500;
  min-height: 20px;
  color: #111827;
}

.status-message:not(:empty) {
  background: #fffbeb;
  border: 1px solid #fde68a;
  color: #92400e;
}

.status-message.success {
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  color: #065f46;
}

.status-message.error {
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #991b1b;
}

/* Responsive Design */
@media (max-width: 1024px) {
  .profile-mid-grid{
    grid-template-columns: 1fr;
  }
}

@media (max-width: 900px) {
  .profile-top-grid{
    grid-template-columns: 1fr;
  }

}

@media (max-width: 768px) {
  :root{ --sidebar-w: 240px; }
  .content{ padding: 18px 16px; }
  .topbar{ padding: 12px 16px; min-height: auto; }

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

  .section-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 15px;
  }

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

  .save-btn,
  .cancel-btn {
    width: 100%;
  }
}

@media (max-width: 560px) {
  .app-shell{ grid-template-columns: 1fr; }
  .sidebar{
    position: relative;
    height: auto;
    border-right: 0;
    border-bottom: 1px solid var(--border);
    box-shadow: none;
  }
  .topbar{ position: relative; }
  .profile-avatar {
    width: 100px;
    height: 100px;
  }

  .avatar-icon {
    font-size: 50px;
  }

  .profile-header h2 { font-size: 20px; }
}
