/* ============================================================
   MILLENNIALS CAPITAL · MEMBER PORTAL
   Liquid-Glass design system for Dashboard & Profile
============================================================ */

:root {
  /* ---- Palette ---- */
  --bg:            #060A0D;
  --bg-1:          #0A1315;
  --bg-2:          #0E1B1E;

  --glass:         rgba(13, 47, 49, 0.4);
  --glass-strong:  rgba(13, 47, 49, 0.6);
  --glass-border:  rgba(255, 255, 255, 0.10);
  --glass-hi:      rgba(255, 255, 255, 0.18);

  --teal:          #16b5a8;
  --teal-d:        #0f948a;
  --teal-l:        #4fd4c7;
  --teal-g:        rgba(22, 181, 168, 0.15);

  --green:         #3ecf8e;
  --green-g:       rgba(62, 207, 142, 0.14);
  --red:           #f05252;
  --red-g:         rgba(240, 82, 82, 0.14);

  --t1: #edf3f4;
  --t2: #9aa5b4;
  --t3: #5a6677;

  --line:          rgba(255, 255, 255, 0.07);

  /* ---- Spacing / radius ---- */
  --sp-1: .5rem;
  --sp-2: 1rem;
  --sp-3: 1.5rem;
  --sp-4: 2rem;
  --sp-5: 3rem;

  --r-1: 8px;
  --r-2: 12px;
  --r-3: 16px;
  --r-pill: 999px;

  /* ---- Shadows ---- */
  --sh-glass:  0 12px 40px rgba(0, 0, 0, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.08);
  --sh-glow:   0 0 40px rgba(22, 181, 168, 0.18);

  /* ---- Type ---- */
  --font: 'Poppins', system-ui, -apple-system, sans-serif;

  /* ---- Layout ---- */
  --nav-h: 68px;
  --container: 1180px;
}

/* ---- RESET ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; overflow-x: clip; }
body {
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.55;
  color: var(--t2);
  background:
    radial-gradient(1200px 700px at 15% -10%, rgba(22, 181, 168, 0.10), transparent 60%),
    radial-gradient(900px 700px at 100% 100%, rgba(22, 181, 168, 0.06), transparent 60%),
    var(--bg);
  min-height: 100vh;
  overflow-x: clip;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button, input, select, textarea { font-family: inherit; }
ul { list-style: none; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: var(--bg-1); }
::-webkit-scrollbar-thumb { background: rgba(22, 181, 168, 0.25); border-radius: 4px; }

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--sp-3);
  width: 100%;
}

/* ============================================================
   NAVIGATION — glass top bar
============================================================ */
.pnav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  height: var(--nav-h);
  display: flex; align-items: center;
  background: rgba(6, 10, 13, 0.55);
  backdrop-filter: blur(22px) saturate(1.6);
  -webkit-backdrop-filter: blur(22px) saturate(1.6);
  border-bottom: 1px solid var(--glass-border);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}
.pnav-inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: var(--sp-2);
  width: 100%; max-width: var(--container);
  margin: 0 auto; padding: 0 var(--sp-3);
}
.pnav-brand {
  display: flex; align-items: center; gap: .55rem;
  color: var(--t1); font-weight: 700; letter-spacing: -.01em;
  white-space: nowrap;
}
.pnav-brand img { height: 32px; width: auto; }
.pnav-links {
  display: flex; align-items: center; gap: .15rem;
}
.pnav-links a {
  position: relative;
  padding: .5rem .85rem;
  font-size: .875rem;
  font-weight: 500;
  color: var(--t2);
  border-radius: var(--r-1);
  transition: color .15s, background .15s;
  white-space: nowrap;
}
.pnav-links a:hover  { color: var(--t1); background: rgba(255, 255, 255, 0.05); }
.pnav-links a.active { color: var(--t1); font-weight: 700; }
.pnav-links a.active::after {
  content: '';
  position: absolute; left: .85rem; right: .85rem; bottom: 2px;
  height: 2px; border-radius: 2px; background: var(--teal);
}
.pnav-links a.logout { color: var(--t3); }
.pnav-links a.logout:hover { color: var(--red); background: var(--red-g); }
.pnav-sep {
  width: 1px; height: 18px;
  background: rgba(255, 255, 255, 0.22);
  margin: 0 .5rem;
}

/* Toggle button (mobile) */
.pnav-toggle {
  display: none;
  width: 40px; height: 40px;
  align-items: center; justify-content: center;
  background: none; border: none; color: var(--t1);
  border-radius: var(--r-1);
  cursor: pointer;
}
.pnav-toggle svg { width: 22px; height: 22px; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; }

/* ============================================================
   PAGE HEADER
============================================================ */
.page {
  padding: calc(var(--nav-h) + var(--sp-4)) 0 var(--sp-5);
}
.page-head { margin-bottom: var(--sp-4); }
.page-title {
  font-size: clamp(1.75rem, 3vw, 2.25rem);
  font-weight: 800;
  color: var(--t1);
  letter-spacing: -.02em;
  line-height: 1.15;
}
.page-sub {
  font-size: 1rem;
  color: var(--t2);
  margin-top: .5rem;
}

/* ============================================================
   REUSABLE GLASS CARD
============================================================ */
.glass {
  background: var(--glass);
  backdrop-filter: blur(16px) saturate(1.4);
  -webkit-backdrop-filter: blur(16px) saturate(1.4);
  border: 1px solid var(--glass-border);
  border-top: 1px solid var(--glass-hi);
  border-radius: var(--r-3);
  box-shadow: var(--sh-glass);
  position: relative;
  overflow: hidden;
}
.glass::after {
  content: '';
  position: absolute; inset: 0;
  border-radius: inherit;
  background: linear-gradient(150deg, rgba(255, 255, 255, 0.10) 0%, rgba(255, 255, 255, 0.02) 22%, transparent 46%);
  pointer-events: none;
  mix-blend-mode: screen;
  opacity: .7;
}
.glass > * { position: relative; z-index: 1; }

/* ============================================================
   SEGMENTED TABS
============================================================ */
.tabs {
  display: inline-flex;
  padding: .3rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--glass-border);
  border-radius: var(--r-pill);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  margin-bottom: var(--sp-4);
}
.tab {
  padding: .55rem 1.6rem;
  font: inherit;
  font-size: .875rem; font-weight: 600;
  color: var(--t2);
  background: none; border: none;
  border-radius: var(--r-pill);
  cursor: pointer;
  transition: color .2s, background .2s;
}
.tab:hover { color: var(--t1); }
.tab.active {
  background: var(--teal);
  color: #06131a;
  box-shadow: 0 0 20px rgba(22, 181, 168, 0.35);
}

/* ============================================================
   DASHBOARD · STOCK GRID
============================================================ */
.stock-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: var(--sp-3);
}

.stock-card {
  padding: var(--sp-3);
  display: flex; flex-direction: column; gap: var(--sp-3);
  transition: transform .25s cubic-bezier(.22, 1, .36, 1), box-shadow .25s;
}
.stock-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--sh-glass), var(--sh-glow);
}

.sc-head {
  display: grid; grid-template-columns: 1fr auto;
  align-items: flex-start; gap: var(--sp-2);
}
.sc-ticker {
  font-size: 1.35rem; font-weight: 800;
  color: var(--t1); letter-spacing: -.01em;
  line-height: 1;
}
.sc-name {
  font-size: .8rem; color: var(--teal);
  margin-top: .3rem; line-height: 1.35;
}
.sc-priceblock { text-align: right; }
.sc-price {
  font-size: 1.5rem; font-weight: 800;
  color: var(--t1);
  font-variant-numeric: tabular-nums;
  line-height: 1;
}
.pill {
  display: inline-block;
  margin-top: .4rem;
  padding: .2rem .55rem;
  border-radius: var(--r-pill);
  font-size: .72rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.pill.up { color: var(--green); background: var(--green-g); }
.pill.dn { color: var(--red);   background: var(--red-g); }

.sc-body {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: var(--sp-2) var(--sp-3);
  padding-top: var(--sp-3);
  border-top: 1px solid var(--line);
}
.sc-cell .k {
  font-size: .68rem;
  color: var(--t3);
  text-transform: uppercase;
  letter-spacing: .06em;
  font-weight: 600;
  margin-bottom: .3rem;
}
.sc-cell .v {
  font-size: .98rem;
  font-weight: 700;
  color: var(--t1);
  font-variant-numeric: tabular-nums;
}
.sc-cell .v.up { color: var(--green); }
.sc-cell .v.dn { color: var(--red); }

/* Webinars placeholder */
.webinars-empty {
  padding: var(--sp-5);
  text-align: center;
  color: var(--t2);
}
.webinars-empty h3 {
  color: var(--t1); font-size: 1.15rem; font-weight: 700; margin-bottom: .5rem;
}

.tab-panel { display: none; }
.tab-panel.active { display: block; animation: fadeUp .35s cubic-bezier(.22, 1, .36, 1) both; }
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: none; }
}

/* ============================================================
   PROFILE — layout & shared bits
============================================================ */
.profile-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--sp-3);
}
.profile-col { display: flex; flex-direction: column; gap: var(--sp-3); }

.sec-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--t1);
  letter-spacing: -.01em;
  margin: var(--sp-3) 0 var(--sp-2);
  padding-left: .1rem;
}
.sec-title:first-child { margin-top: 0; }

.card {
  padding: var(--sp-3) var(--sp-4);
}
.card-head {
  display: flex; align-items: center; gap: .75rem;
  margin-bottom: var(--sp-3);
}
.card-ic {
  width: 42px; height: 42px;
  flex-shrink: 0;
  border-radius: var(--r-2);
  background: rgba(22, 181, 168, 0.14);
  border: 1px solid rgba(22, 181, 168, 0.28);
  display: flex; align-items: center; justify-content: center;
}
.card-ic svg { width: 20px; height: 20px; stroke: var(--teal); fill: none; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.card-h {
  font-size: 1.02rem;
  font-weight: 700;
  color: var(--t1);
}

/* key/value rows (Basic info + Subscription) */
.kv-list { display: flex; flex-direction: column; gap: var(--sp-2); }
.kv {
  display: flex; align-items: center; justify-content: space-between;
  gap: var(--sp-2);
  padding: .6rem 0;
  border-bottom: 1px dashed var(--line);
}
.kv:last-child { border-bottom: none; }
.kv .k {
  font-size: .78rem;
  color: var(--t3);
  text-transform: uppercase;
  letter-spacing: .06em;
  font-weight: 600;
}
.kv .v {
  font-size: .95rem;
  color: var(--t1);
  font-weight: 600;
  text-align: right;
  word-break: break-word;
}

/* Badge (Active) */
.badge {
  display: inline-flex; align-items: center; gap: .35rem;
  padding: .2rem .6rem;
  border-radius: var(--r-pill);
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .04em;
}
.badge.active {
  color: var(--green);
  background: var(--green-g);
  border: 1px solid rgba(62, 207, 142, 0.3);
}
.badge.active::before {
  content: '';
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 8px var(--green);
}
.plan-line { display: inline-flex; align-items: center; gap: .5rem; }

/* ============================================================
   FORMS
============================================================ */
.fg {
  display: flex; flex-direction: column; gap: .4rem;
  margin-bottom: var(--sp-3);
}
.fg label {
  font-size: .78rem;
  font-weight: 600;
  color: var(--t2);
  text-transform: uppercase;
  letter-spacing: .06em;
}
.fg input, .fg textarea, .fg select {
  padding: .85rem 1.1rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1.5px solid var(--glass-border);
  border-radius: var(--r-2);
  color: var(--t1);
  font-size: .95rem;
  outline: none;
  transition: border-color .15s, background .15s, box-shadow .15s;
}
.fg input:focus, .fg textarea:focus, .fg select:focus {
  border-color: var(--teal);
  background: rgba(22, 181, 168, 0.05);
  box-shadow: 0 0 0 3px rgba(22, 181, 168, 0.15);
}

/* ============================================================
   BUTTONS
============================================================ */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: .5rem;
  padding: .8rem 1.5rem;
  border: none;
  border-radius: var(--r-2);
  font: inherit;
  font-size: .9rem; font-weight: 700;
  cursor: pointer;
  text-decoration: none;
  transition: transform .15s, box-shadow .15s, background .15s;
  position: relative; overflow: hidden;
}
.btn:active { transform: scale(.98); }

.btn-teal {
  background: var(--teal);
  color: #06131a;
  box-shadow: 0 0 22px rgba(22, 181, 168, 0.35);
}
.btn-teal:hover {
  background: var(--teal-d);
  box-shadow: 0 4px 34px rgba(22, 181, 168, 0.5);
  transform: translateY(-2px);
}

.btn-white {
  background: #ffffff;
  color: #06131a;
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.35);
}
.btn-white:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 34px rgba(255, 255, 255, 0.15);
}

.btn-teal::before, .btn-white::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 50%;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.3), transparent);
  pointer-events: none;
  border-radius: inherit;
}

/* ============================================================
   PAYMENT / CARD VISUAL (Mastercard)
============================================================ */
.card-visual {
  position: relative;
  aspect-ratio: 1.586 / 1;
  max-width: 380px;
  border-radius: var(--r-3);
  padding: 1.5rem;
  color: #ffffff;
  background:
    radial-gradient(600px 260px at 20% 0%, rgba(22, 181, 168, 0.2), transparent 60%),
    linear-gradient(135deg, #0e1b1e 0%, #071013 100%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.12);
  overflow: hidden;
  display: flex; flex-direction: column; justify-content: space-between;
}
.card-visual::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(150deg, rgba(255, 255, 255, 0.14) 0%, rgba(255, 255, 255, 0.02) 24%, transparent 46%);
  pointer-events: none;
}
.cv-top {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 1rem;
  position: relative; z-index: 1;
}
.cv-brand {
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  opacity: .9;
}
.cv-chip {
  width: 40px; height: 30px;
  border-radius: 6px;
  background: linear-gradient(135deg, #d9c37a, #b58f36);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.15);
  position: relative;
}
.cv-chip::before, .cv-chip::after {
  content: '';
  position: absolute; left: 6px; right: 6px;
  height: 1px;
  background: rgba(0, 0, 0, 0.25);
}
.cv-chip::before { top: 10px; }
.cv-chip::after  { bottom: 10px; }

.cv-number {
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: .12em;
  font-variant-numeric: tabular-nums;
  margin: 1rem 0 .8rem;
  position: relative; z-index: 1;
}
.cv-bottom {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 1rem;
  position: relative; z-index: 1;
}
.cv-meta .k {
  font-size: .58rem;
  text-transform: uppercase;
  letter-spacing: .1em;
  opacity: .6;
  margin-bottom: .2rem;
}
.cv-meta .v {
  font-size: .88rem;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.mc-logo {
  display: inline-flex; align-items: center;
  width: 48px; height: 30px;
  position: relative;
}
.mc-logo span {
  width: 22px; height: 22px; border-radius: 50%;
  display: block; position: absolute;
}
.mc-logo span:first-child { left: 0; background: #eb001b; }
.mc-logo span:last-child  { right: 0; background: #f79e1b; mix-blend-mode: screen; }

/* ============================================================
   RESPONSIVE
============================================================ */
@media (max-width: 900px) {
  .profile-layout { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
  .pnav-toggle { display: inline-flex; }
  .pnav-links {
    display: none;
    position: fixed; top: 0; left: 0; right: 0;
    flex-direction: column; align-items: flex-end;
    gap: .3rem;
    padding: calc(var(--nav-h) + var(--sp-3)) 1.5rem var(--sp-4);
    background: linear-gradient(180deg, rgba(11, 26, 24, 0.94), rgba(7, 12, 15, 0.93));
    backdrop-filter: blur(44px) saturate(1.8);
    -webkit-backdrop-filter: blur(44px) saturate(1.8);
    border-bottom: 1px solid var(--glass-border);
    border-radius: 0 0 30px 30px;
    box-shadow: 0 30px 70px rgba(0, 0, 0, 0.55);
  }
  .pnav-links.open { display: flex; }
  .pnav-links a {
    font-size: 1.35rem;
    font-weight: 600;
    padding: .5rem 0;
  }
  .pnav-links a.active::after { display: none; }
  .pnav-sep { display: none; }

  .page { padding-top: calc(var(--nav-h) + var(--sp-3)); }
  .stock-grid { grid-template-columns: 1fr; }
  .card { padding: var(--sp-3); }
}

@media (max-width: 480px) {
  .sc-body { grid-template-columns: 1fr; }
  .cv-number { font-size: 1rem; letter-spacing: .1em; }
}

/* ============================================================
   FOCUSED LAYOUT — Message Board & Admin (max-width: 800px)
============================================================ */
.focused {
  max-width: 800px;
  margin: 0 auto;
}

/* ============================================================
   MESSAGE BOARD · FEED
============================================================ */
.feed { display: flex; flex-direction: column; gap: var(--sp-3); }

.post {
  padding: var(--sp-4);
  transition: transform .25s cubic-bezier(.22, 1, .36, 1), box-shadow .25s;
}
.post:hover { transform: translateY(-2px); box-shadow: var(--sh-glass), var(--sh-glow); }

.post-top {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: var(--sp-3);
  padding-bottom: var(--sp-3);
  border-bottom: 1px solid var(--glass-border);
}
.post-title {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--t1);
  letter-spacing: -.01em;
  line-height: 1.3;
}
.post-date {
  font-size: .8rem;
  font-weight: 600;
  color: var(--teal);
  white-space: nowrap;
  flex-shrink: 0;
  padding-top: .35rem;
}
.post-body {
  padding-top: var(--sp-3);
  color: var(--t1);
  font-size: 1rem;
  line-height: 1.7;
}
.post-body p + p { margin-top: var(--sp-2); }
.post-body strong { color: var(--t1); font-weight: 700; }
.post-body em { color: var(--teal-l); font-style: normal; font-weight: 600; }

/* ============================================================
   ADMIN · PUBLISH FORM
============================================================ */
.admin-card { padding: var(--sp-4); }

.admin-form .fg { margin-bottom: var(--sp-3); }
.admin-form textarea {
  min-height: 250px;
  resize: vertical;
  line-height: 1.6;
  font-family: inherit;
}
.admin-form .btn { width: 100%; padding: 1rem 1.5rem; font-size: 1rem; }

/* Form feedback (success / error) — populated by JS later */
#form-feedback {
  margin-top: var(--sp-3);
  min-height: 0;
  transition: min-height .2s;
}
#form-feedback:empty { padding: 0; border: 0; background: none; }
#form-feedback:not(:empty) {
  padding: .9rem 1.1rem;
  border-radius: var(--r-2);
  font-size: .9rem;
  font-weight: 600;
  border: 1px solid var(--glass-border);
  min-height: 46px;
}
#form-feedback.success {
  color: var(--green);
  background: var(--green-g);
  border-color: rgba(62, 207, 142, 0.28);
}
#form-feedback.error {
  color: var(--red);
  background: var(--red-g);
  border-color: rgba(240, 82, 82, 0.28);
}

@media (max-width: 640px) {
  .post-top { flex-direction: column; gap: .5rem; }
  .post-date { padding-top: 0; }
  .admin-card { padding: var(--sp-3); }
}

/* ============================================================
   ADMIN APP · SIDEBAR LAYOUT (standalone dashboard)
============================================================ */
.admin-app-layout {
  display: flex;
  min-height: 100vh;
  gap: var(--sp-3);
  padding: var(--sp-3);
}

/* ---- Sidebar ---- */
.admin-sidebar {
  position: sticky;
  top: var(--sp-3);
  align-self: flex-start;
  width: 250px;
  flex-shrink: 0;
  height: calc(100vh - 2 * var(--sp-3));
  padding: var(--sp-3);
  display: flex; flex-direction: column;
  gap: var(--sp-3);
}
.admin-brand {
  display: flex; align-items: center;
  gap: .6rem;
  padding-bottom: var(--sp-3);
  border-bottom: 1px solid var(--glass-border);
  color: var(--t1);
  font-weight: 700;
  letter-spacing: -.01em;
}
.admin-brand img { height: 34px; width: auto; }

.admin-menu {
  display: flex; flex-direction: column;
  gap: .35rem;
  flex: 1;
}
.admin-menu-btn {
  display: flex; align-items: center;
  gap: .7rem;
  width: 100%;
  padding: .8rem 1rem;
  font: inherit;
  font-size: .95rem;
  font-weight: 600;
  color: var(--t2);
  background: transparent;
  border: 1px solid transparent;
  border-radius: var(--r-2);
  cursor: pointer;
  text-align: left;
  text-decoration: none;
  transition: background .18s, color .18s, border-color .18s, transform .12s;
}
.admin-menu-btn .icon {
  font-size: 1.05rem;
  line-height: 1;
  flex-shrink: 0;
}
.admin-menu-btn:hover {
  color: var(--t1);
  background: rgba(255, 255, 255, 0.04);
}
.admin-menu-btn.active {
  color: var(--t1);
  background: rgba(22, 181, 168, 0.14);
  border-color: rgba(22, 181, 168, 0.35);
  box-shadow: inset 0 0 0 1px rgba(22, 181, 168, 0.08), 0 0 20px rgba(22, 181, 168, 0.12);
}
.admin-menu-btn.active .icon { color: var(--teal); }

.admin-menu-back {
  margin-top: auto;
  padding-top: var(--sp-3);
  border-top: 1px solid var(--glass-border);
}
.admin-menu-back .admin-menu-btn {
  color: var(--t3);
}
.admin-menu-back .admin-menu-btn:hover { color: var(--teal); }

/* ---- Main content ---- */
.admin-content {
  flex: 1;
  min-width: 0;
  padding: var(--sp-3) var(--sp-4);
}
.admin-panel { display: none; }
.admin-panel.active {
  display: block;
  animation: fadeUp .35s cubic-bezier(.22, 1, .36, 1) both;
}

/* ============================================================
   ADMIN · MANAGE POSTS LIST
============================================================ */
.manage-list {
  display: flex; flex-direction: column;
  gap: .75rem;
}
.manage-item {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: var(--sp-3);
  padding: var(--sp-3);
  transition: transform .18s cubic-bezier(.22, 1, .36, 1), box-shadow .18s;
}
.manage-item:hover { transform: translateY(-1px); box-shadow: var(--sh-glass), var(--sh-glow); }

.manage-main { min-width: 0; }
.manage-title {
  font-size: 1.02rem;
  font-weight: 700;
  color: var(--t1);
  line-height: 1.35;
  margin-bottom: .25rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.manage-date {
  font-size: .78rem;
  color: var(--teal);
  font-weight: 600;
}

.btn-delete {
  display: inline-flex; align-items: center;
  gap: .4rem;
  padding: .55rem 1rem;
  font: inherit;
  font-size: .82rem;
  font-weight: 700;
  color: var(--red);
  background: var(--red-g);
  border: 1px solid rgba(240, 82, 82, 0.3);
  border-radius: var(--r-2);
  cursor: pointer;
  transition: background .15s, color .15s, transform .12s;
}
.btn-delete:hover:not(:disabled) {
  background: var(--red);
  color: #ffffff;
  transform: translateY(-1px);
}
.btn-delete:disabled {
  opacity: .55;
  cursor: not-allowed;
}

.manage-empty {
  padding: var(--sp-4);
  text-align: center;
  color: var(--t2);
}
.manage-loading {
  padding: var(--sp-3);
  text-align: center;
  color: var(--t2);
  font-size: .9rem;
}

/* ---- Sidebar responsive ---- */
@media (max-width: 900px) {
  .admin-app-layout {
    flex-direction: column;
    padding: var(--sp-2);
    gap: var(--sp-2);
  }
  .admin-sidebar {
    position: static;
    width: 100%;
    height: auto;
    flex-direction: row;
    align-items: center;
    gap: var(--sp-2);
    padding: var(--sp-2);
  }
  .admin-brand {
    padding-bottom: 0;
    padding-right: var(--sp-2);
    border-bottom: 0;
    border-right: 1px solid var(--glass-border);
    flex-shrink: 0;
  }
  .admin-brand span { display: none; }
  .admin-menu {
    flex-direction: row;
    flex: 1;
    gap: .3rem;
    overflow-x: auto;
    -ms-overflow-style: none;
    scrollbar-width: none;
  }
  .admin-menu::-webkit-scrollbar { display: none; }
  .admin-menu-btn { padding: .6rem .85rem; font-size: .85rem; white-space: nowrap; }
  .admin-menu-back {
    margin-top: 0;
    padding-top: 0;
    padding-left: var(--sp-2);
    border-top: 0;
    border-left: 1px solid var(--glass-border);
  }
  .admin-content { padding: var(--sp-2); }
}

@media (max-width: 560px) {
  .manage-item { grid-template-columns: 1fr; }
  .btn-delete { justify-self: flex-start; }
}

/* ============================================================
   AUTH LAYOUT (Login / Signup / Reset)
============================================================ */
.auth-layout {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--sp-3);
  background:
    radial-gradient(700px 500px at 20% 15%, rgba(22, 181, 168, 0.12), transparent 60%),
    radial-gradient(600px 500px at 85% 85%, rgba(22, 181, 168, 0.08), transparent 60%),
    var(--bg);
}

.auth-wrap {
  width: 100%;
  max-width: 400px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
}

/* ---- Brand / header block ---- */
.auth-head { text-align: center; }
.auth-brand {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .55rem;
  margin-bottom: var(--sp-3);
  color: var(--t1);
  font-weight: 800;
  letter-spacing: -.01em;
  text-decoration: none;
}
.auth-brand img { height: 40px; width: auto; }

.auth-title {
  font-size: clamp(1.6rem, 3vw, 2rem);
  font-weight: 800;
  color: var(--t1);
  letter-spacing: -.02em;
  line-height: 1.2;
  margin-bottom: .5rem;
}
.auth-sub {
  font-size: .95rem;
  color: var(--t2);
  line-height: 1.5;
}

/* ---- Auth card + form ---- */
.auth-card { padding: var(--sp-4); }

.auth-form { display: flex; flex-direction: column; }
.auth-form .fg { margin-bottom: var(--sp-3); }
.auth-form .btn { width: 100%; padding: .95rem 1.5rem; font-size: .95rem; }

/* Row with checkbox + right-aligned link */
.auth-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-2);
  margin: -.25rem 0 var(--sp-3);
}
.auth-link {
  font-size: .85rem;
  font-weight: 600;
  color: var(--teal);
  text-decoration: none;
  transition: color .15s;
}
.auth-link:hover { color: var(--teal-l); text-decoration: underline; }

/* Footer (below the card) */
.auth-foot {
  text-align: center;
  font-size: .9rem;
  color: var(--t2);
}
.auth-foot .auth-link { margin-left: .35rem; }

/* Feedback area for Memberstack error/success messages */
#auth-feedback { margin-top: var(--sp-3); }

@media (max-width: 480px) {
  .auth-wrap { padding: 12px; }
  .auth-card { padding: var(--sp-3); }
}

/* ============================================================
   DASHBOARD · DISCORD VIP BANNER (Tier 2 & 3)
============================================================ */
.discord-banner {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  padding: var(--sp-3) var(--sp-4);
  margin-bottom: var(--sp-4);
}
.discord-icon {
  flex: 0 0 auto;
  width: 52px; height: 52px;
  display: grid; place-items: center;
  border-radius: var(--r-2);
  background: var(--teal-g);
  border: 1px solid rgba(22, 181, 168, 0.32);
  color: var(--teal);
}
.discord-body { flex: 1 1 auto; min-width: 0; }
.discord-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--t1);
  letter-spacing: -.01em;
  margin-bottom: .2rem;
}
.discord-text {
  font-size: .85rem;
  color: var(--t2);
  line-height: 1.45;
}
.discord-cta {
  flex: 0 0 auto;
  padding: .7rem 1.25rem;
  font-size: .85rem;
  border-radius: var(--r-pill);
}

/* ============================================================
   DASHBOARD · LOCKED STATE (non-members)
============================================================ */
.locked-card {
  max-width: 520px;
  margin: var(--sp-4) auto var(--sp-5);
  padding: var(--sp-5) var(--sp-4);
  text-align: center;
}
.locked-icon {
  width: 78px; height: 78px;
  margin: 0 auto var(--sp-3);
  display: grid; place-items: center;
  border-radius: var(--r-3);
  background: var(--teal-g);
  border: 1px solid rgba(22, 181, 168, 0.32);
  color: var(--teal);
}
.locked-title {
  font-size: clamp(1.4rem, 2.5vw, 1.75rem);
  font-weight: 800;
  color: var(--t1);
  letter-spacing: -.02em;
  margin-bottom: .5rem;
}
.locked-text {
  font-size: .98rem;
  color: var(--t2);
  line-height: 1.5;
  margin-bottom: var(--sp-4);
}
.locked-actions {
  display: flex;
  justify-content: center;
  gap: .75rem;
  flex-wrap: wrap;
}
.locked-actions .btn { min-width: 140px; }

/* ---- Ghost button variant (used by locked state) ---- */
.btn-ghost {
  background: rgba(255, 255, 255, 0.04);
  color: var(--t1);
  border: 1px solid var(--glass-border);
}
.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--glass-hi);
  transform: translateY(-2px);
}

/* ---- Discord banner responsive ---- */
@media (max-width: 640px) {
  .discord-banner {
    flex-direction: column;
    align-items: flex-start;
    text-align: left;
    padding: var(--sp-3);
  }
  .discord-cta { align-self: stretch; text-align: center; }
}
