/* ════════════════════════════════════════════════════════════════
   IA Outils — Design inspiré Circle.so
   Palette : crème chaud, olive foncé, accents violets & orange
   ════════════════════════════════════════════════════════════════ */

:root {
  --bg:           #FDF6E8;
  --bg-alt:       #F5ECD6;
  --card-bg:      #FFFFFF;
  --line:         #EAE1CC;
  --text:         #1A1A1A;
  --text-muted:   #6B6455;
  --accent:       #6B3FA0;      /* Purple — nav active */
  --accent-soft:  #EDE4F7;
  --olive:        #1B2D1E;      /* Dark olive — covers */
  --gold:         #F2E4C1;
  --cta:          #FF5A26;
  --admin-bg:     #6B3FA0;
  --admin-text:   #FFFFFF;
  --success:      #3B82F6;
  --danger:       #E13300;
  --radius:       14px;
  --radius-sm:    8px;
  --rail:         56px;
  --topbar:       56px;
  --sidebar:      260px;
  --shadow:       0 1px 2px rgba(27,45,30,.04), 0 4px 12px rgba(27,45,30,.05);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 15px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
a:hover { color: var(--accent); }

h1, h2, h3, h4 {
  font-family: 'Plus Jakarta Sans', sans-serif;
  margin: 0;
  color: var(--text);
  letter-spacing: -0.01em;
}

/* ──────── App Rail (extrême gauche, 56px) ──────── */
.app-rail {
  position: fixed;
  top: 0; left: 0; bottom: 0;
  width: var(--rail);
  background: var(--bg);
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 12px 0;
  gap: 10px;
  z-index: 20;
}

.rail-brand {
  width: 38px; height: 38px;
  border-radius: 10px;
  background: var(--olive);
  color: var(--gold);
  display: flex; align-items: center; justify-content: center;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 800;
  font-size: 20px;
  margin-bottom: 6px;
}
.rail-brand-letter { line-height: 1; }

.rail-icon {
  width: 38px; height: 38px;
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  color: var(--text-muted);
  border: 1px solid transparent;
  background: transparent;
  cursor: pointer;
  transition: all .15s;
}
.rail-icon:hover { background: var(--bg-alt); color: var(--text); }
.rail-icon.active {
  background: #1A1A1A;
  color: var(--gold);
  border-color: transparent;
}
.rail-icon.rail-purple {
  background: #A855F7;
  color: #fff;
  border: none;
}
.rail-icon.rail-plus {
  color: var(--text-muted);
  font-size: 22px;
  font-weight: 300;
  background: transparent;
  border: none;
}
.rail-icon.rail-plus:hover { background: var(--bg-alt); color: var(--text); }

/* ──────── Top Bar ──────── */
.topbar {
  position: fixed;
  top: 0; left: var(--rail); right: 0;
  height: var(--topbar);
  background: var(--bg);
  border-bottom: 1px solid var(--line);
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  padding: 0 20px;
  gap: 20px;
  z-index: 15;
}

.topbar-left { display: flex; align-items: center; }
.space-switcher {
  display: flex; align-items: center; gap: 10px;
  padding: 6px 12px;
  border-radius: 10px;
  cursor: pointer;
  transition: background .15s;
  font-weight: 500;
  font-size: 14px;
}
.space-switcher:hover { background: var(--bg-alt); }
.space-switcher-icon {
  width: 28px; height: 28px;
  border-radius: 7px;
  background: var(--olive);
  color: var(--gold);
  display: flex; align-items: center; justify-content: center;
  font-weight: 800;
  font-size: 14px;
  font-family: 'Plus Jakarta Sans', sans-serif;
}

.topbar-center { display: flex; justify-content: center; gap: 6px; }
.topnav-link {
  padding: 8px 18px;
  border-radius: 24px;
  font-weight: 500;
  font-size: 14px;
  color: var(--text-muted);
  transition: all .15s;
}
.topnav-link:hover { background: var(--bg-alt); color: var(--text); }
.topnav-link.active {
  background: var(--bg-alt);
  color: var(--text);
}

.topbar-right { display: flex; justify-content: flex-end; align-items: center; gap: 10px; }
.search-box {
  display: flex; align-items: center; gap: 8px;
  background: var(--bg-alt);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 6px 12px;
  width: 220px;
  color: var(--text-muted);
}
.search-box input {
  background: transparent;
  border: none;
  outline: none;
  font: inherit;
  color: var(--text);
  flex: 1;
  font-size: 13px;
}
.search-box input::placeholder { color: var(--text-muted); }

.icon-btn {
  width: 36px; height: 36px;
  border-radius: 9px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: all .15s;
}
.icon-btn:hover { background: var(--bg-alt); color: var(--text); }

.user-avatar {
  width: 32px; height: 32px;
  border-radius: 50%;
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-weight: 600;
  font-size: 13px;
  cursor: pointer;
}

/* ──────── App Shell (sidebar + main) ──────── */
.app-shell {
  display: grid;
  grid-template-columns: var(--sidebar) 1fr;
  padding-left: var(--rail);
  padding-top: var(--topbar);
  min-height: 100vh;
}

/* ──────── Sidebar ──────── */
.sidebar {
  background: var(--bg);
  border-right: 1px solid var(--line);
  padding: 18px 14px;
  position: sticky;
  top: var(--topbar);
  align-self: start;
  height: calc(100vh - var(--topbar));
  overflow-y: auto;
}

.sidebar-section-title {
  font-size: 12px;
  font-weight: 600;
  text-transform: none;
  color: var(--text-muted);
  margin: 22px 12px 8px;
  letter-spacing: 0;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  border-radius: 9px;
  font-size: 14px;
  color: var(--text);
  font-weight: 500;
  transition: background .15s;
  margin-bottom: 2px;
}
.nav-item:hover { background: var(--bg-alt); color: var(--text); }
.nav-item.active,
.nav-item.active-feed {
  background: var(--accent-soft);
  color: var(--accent);
}
.nav-item .arrow {
  color: var(--text-muted);
  font-size: 11px;
}

.nav-feed {
  background: var(--accent);
  color: #fff;
  margin-bottom: 14px;
}
.nav-feed:hover { background: #5a3388; color: #fff; }

.space-dot {
  width: 10px; height: 10px;
  border-radius: 50%;
  background: var(--success);
  display: inline-block;
  flex-shrink: 0;
}

/* ──────── Main Column ──────── */
.main-col {
  padding: 28px 44px;
  min-width: 0;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}

/* ──────── Feed Layout ──────── */
.feed-layout {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 28px;
  align-items: start;
}

.feed-header, .space-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 20px;
}

.feed-title, .space-title {
  font-size: 22px;
  font-weight: 700;
  display: flex; align-items: center; gap: 10px;
}
.feed-subtitle {
  color: var(--text-muted);
  font-size: 14px;
  margin: 4px 0 0;
}

.filter-btn {
  display: flex; align-items: center; gap: 6px;
  padding: 6px 12px;
  border: 1px solid var(--line);
  background: var(--card-bg);
  border-radius: 8px;
  font-size: 13px;
  color: var(--text-muted);
  cursor: pointer;
}
.filter-btn:hover { border-color: #ccc; }

/* ──────── Feed Cards ──────── */
.feed-card {
  background: var(--card-bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px 22px;
  margin-bottom: 16px;
  transition: box-shadow .15s;
}
.feed-card:hover { box-shadow: var(--shadow); }

.feed-card-head {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  margin-bottom: 14px;
}

.avatar {
  width: 36px; height: 36px;
  border-radius: 50%;
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-weight: 600;
  font-size: 14px;
  flex-shrink: 0;
}

.feed-card-meta { flex: 1; min-width: 0; }

.author-line {
  display: flex; align-items: center; gap: 8px;
  font-size: 14px;
  flex-wrap: wrap;
}
.author-line strong { font-weight: 600; }

.badge-admin {
  background: var(--admin-bg);
  color: var(--admin-text);
  font-size: 10px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: .03em;
}

.meta-date { color: var(--text-muted); font-size: 13px; }

.posted-in {
  color: var(--text-muted);
  font-size: 13px;
  margin-top: 2px;
}
.posted-in a { color: var(--text); font-weight: 500; }
.posted-in a:hover { text-decoration: underline; }

.feed-card-body { display: block; }
.feed-card-title {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 8px;
  line-height: 1.3;
}
.feed-card-summary {
  color: var(--text);
  margin: 0 0 16px;
  font-size: 15px;
}

.feed-card-cover {
  display: block;
  height: 200px;
  border-radius: 10px;
  padding: 28px 32px;
  color: #F2E4C1;
  position: relative;
  overflow: hidden;
  margin-bottom: 14px;
}
.feed-card-cover:hover { filter: brightness(1.05); }

.cover-content {
  position: relative;
  z-index: 2;
  max-width: 70%;
}

.cover-label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .12em;
  opacity: .7;
  margin-bottom: 10px;
}
.cover-title {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 32px;
  font-weight: 800;
  line-height: 1;
  margin-bottom: 8px;
  color: inherit;
}
.cover-sub {
  font-size: 14px;
  opacity: .85;
  margin: 0;
  font-style: italic;
}

.feed-card-foot {
  display: flex; align-items: center; justify-content: space-between;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  font-size: 13px;
  color: var(--text-muted);
}

.reactions { display: flex; align-items: center; gap: 8px; }
.reaction-btn {
  background: transparent;
  border: none;
  cursor: pointer;
  font: inherit;
  color: inherit;
  padding: 4px 8px;
  border-radius: 6px;
}
.reaction-btn:hover { background: var(--bg-alt); }
.meta-dot { color: var(--line); }

/* ──────── Trending Column ──────── */
.trending-card {
  background: var(--card-bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px 18px 10px;
  position: sticky;
  top: calc(var(--topbar) + 20px);
}
.trending-heading {
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 12px;
}
.trending-item {
  display: flex;
  gap: 10px;
  padding: 10px 0;
  align-items: flex-start;
}
.trending-item + .trending-item { border-top: 1px solid var(--line); }

.trending-avatar {
  width: 32px; height: 32px;
  border-radius: 50%;
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-weight: 600;
  font-size: 13px;
  flex-shrink: 0;
}
.trending-body { flex: 1; min-width: 0; }
.trending-title {
  font-weight: 600;
  font-size: 13px;
  line-height: 1.35;
  margin-bottom: 2px;
}
.trending-author { font-size: 12px; color: var(--text-muted); }

/* ──────── Space View ──────── */
.space-col { max-width: 1120px; }

.space-hero {
  border-radius: 14px;
  padding: 60px 48px 48px;
  margin-bottom: 28px;
  color: var(--gold);
  min-height: 220px;
  background-size: cover;
  background-position: right center;
  position: relative;
  overflow: hidden;
}
.space-hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(27,45,30,0) 40%, rgba(27,45,30,.2));
}
.space-hero-label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .1em;
  opacity: .8;
  margin-bottom: 12px;
  position: relative; z-index: 2;
}
.space-hero-title {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 48px;
  font-weight: 800;
  line-height: 1;
  margin: 0 0 12px;
  color: inherit;
  position: relative; z-index: 2;
}
.space-hero-sub {
  font-size: 15px;
  opacity: .85;
  margin: 0;
  position: relative; z-index: 2;
}

.cat-tabs {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 28px;
}
.cat-tab {
  padding: 8px 18px;
  border: 1px solid var(--line);
  background: var(--card-bg);
  border-radius: 22px;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  color: var(--text);
  transition: all .15s;
}
.cat-tab:hover { border-color: #ccc; }
.cat-tab.active {
  background: var(--text);
  color: var(--bg);
  border-color: var(--text);
}

.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 18px;
}

.card {
  background: var(--card-bg);
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
  transition: transform .18s, box-shadow .18s;
  display: flex;
  flex-direction: column;
}
.card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.card-cover {
  padding: 26px 22px 22px;
  color: var(--gold);
  position: relative;
  min-height: 180px;
}
.card-cover-label {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: .12em;
  opacity: .7;
  margin-bottom: 10px;
}
.card-cover-title {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 24px;
  font-weight: 800;
  line-height: 1;
  margin: 0 0 6px;
  color: inherit;
}
.card-cover-sub {
  font-size: 12px;
  opacity: .8;
  margin: 0;
  font-style: italic;
}

.card-avatar {
  position: absolute;
  left: 18px; bottom: -18px;
  width: 36px; height: 36px;
  border-radius: 50%;
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-weight: 600;
  font-size: 14px;
  border: 3px solid var(--card-bg);
}

.card-body {
  padding: 28px 20px 16px;
}
.card-title {
  font-size: 16px;
  font-weight: 700;
  margin: 0 0 6px;
  line-height: 1.35;
}
.card-meta {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 10px;
}
.card-stats {
  display: flex;
  gap: 16px;
  font-size: 13px;
  color: var(--text-muted);
}

/* ──────── Post View ──────── */
.post-view { max-width: 760px; margin: 0 auto; }

.back-link {
  display: inline-flex;
  align-items: center;
  color: var(--text-muted);
  font-size: 13px;
  margin-bottom: 20px;
}
.back-link:hover { color: var(--text); }

.post-card {
  background: var(--card-bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 32px 36px 28px;
}

.post-head {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  margin-bottom: 24px;
}

.post-title {
  font-size: 30px;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 10px;
}
.post-summary {
  font-size: 17px;
  color: var(--text-muted);
  margin: 0 0 24px;
}

.post-cover {
  height: 220px;
  border-radius: 10px;
  padding: 32px 36px;
  color: var(--gold);
  margin-bottom: 28px;
  display: flex;
  align-items: flex-end;
}

.post-body {
  font-size: 16px;
  line-height: 1.7;
  color: var(--text);
}
.post-body p { margin: 0 0 16px; }
.post-body strong { color: var(--text); font-weight: 600; }
.post-body pre {
  background: #1A1A1A;
  color: #E6D7A8;
  padding: 16px 18px;
  border-radius: 10px;
  overflow-x: auto;
  font-size: 13px;
  font-family: 'JetBrains Mono', Menlo, monospace;
  margin: 16px 0;
}
.post-body code { font-family: inherit; }

.post-foot {
  margin-top: 28px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

/* ──────── Locked Space ──────── */
.locked {
  background: var(--card-bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 80px 40px;
  text-align: center;
}
.locked-icon { font-size: 48px; margin-bottom: 12px; }
.locked h2 { font-size: 24px; margin-bottom: 8px; }
.locked p { color: var(--text-muted); margin: 0; }

/* ──────── Footer ──────── */
.app-footer {
  text-align: center;
  padding: 14px;
  color: var(--text-muted);
  font-size: 12px;
  margin-left: var(--rail);
  background: var(--bg);
  border-top: 1px solid var(--line);
}

/* ──────── Responsive ──────── */
@media (max-width: 900px) {
  :root { --sidebar: 0px; }
  .sidebar { display: none; }
  .app-shell { grid-template-columns: 1fr; }
  .feed-layout { grid-template-columns: 1fr; }
  .trending-col { display: none; }
  .main-col { padding: 20px; }
  .search-box { width: 140px; }
  .topbar-center { display: none; }
}

/* ══════════════ Auth ══════════════ */
.auth-wrap { max-width: 480px; margin: 40px auto; padding: 0 16px; }
.auth-card {
  background: #fff; border: 1px solid #e8dcc1; border-radius: 18px;
  padding: 36px 32px; box-shadow: 0 4px 24px rgba(27,45,30,0.06);
}
.auth-title { margin: 0 0 8px; font-size: 26px; font-weight: 800; color: #1B2D1E; }
.auth-sub   { margin: 0 0 24px; font-size: 15px; color: #5a6a5e; line-height: 1.5; }
.auth-form  { display: flex; flex-direction: column; gap: 16px; }
.auth-form label { display: flex; flex-direction: column; gap: 6px; font-size: 13px; font-weight: 600; color: #3a4a3e; }
.auth-form input[type="email"],
.auth-form input[type="text"],
.auth-form input[type="url"],
.auth-form textarea,
.auth-form select {
  padding: 12px 14px; border: 1.5px solid #e8dcc1; border-radius: 10px;
  font-size: 15px; font-family: inherit; background: #fdfbf5; color: #1B2D1E;
  transition: border-color .15s;
}
.auth-form input:focus, .auth-form textarea:focus, .auth-form select:focus {
  outline: none; border-color: #6B3FA0; background: #fff;
}
.auth-check { flex-direction: row !important; align-items: center; gap: 10px !important; font-weight: 500 !important; color: #5a6a5e !important; font-size: 14px !important; }
.auth-check input { width: 18px; height: 18px; accent-color: #6B3FA0; }
.btn-primary {
  background: #1B2D1E; color: #F2E4C1; padding: 13px 24px; border: none;
  border-radius: 10px; font-weight: 700; font-size: 15px; cursor: pointer;
  transition: transform .1s, background .15s; text-decoration: none; display: inline-block; text-align: center;
}
.btn-primary:hover { background: #2a3f2e; transform: translateY(-1px); }
.btn-ghost {
  background: transparent; color: #1B2D1E; padding: 10px 20px;
  border: 1.5px solid #d4c59e; border-radius: 10px; font-weight: 600; cursor: pointer;
  font-size: 14px; transition: background .15s;
}
.btn-ghost:hover { background: #f5ecd4; }
.btn-danger {
  background: #DC2626; color: #fff; padding: 10px 18px; border: none;
  border-radius: 8px; font-weight: 600; cursor: pointer; font-size: 13px;
}
.btn-danger:hover { background: #b91c1c; }
.auth-foot { margin: 24px 0 0; font-size: 13px; color: #6b7a6e; text-align: center; }
.auth-err  { background: #fef2f2; color: #991b1b; padding: 12px 14px; border-radius: 10px; font-size: 14px; margin-bottom: 16px; border: 1px solid #fecaca; }
.auth-ok   { background: #f0fdf4; color: #166534; padding: 12px 14px; border-radius: 10px; font-size: 14px; margin-bottom: 16px; border: 1px solid #bbf7d0; }
.me-row    { display: flex; justify-content: space-between; padding: 12px 0; border-bottom: 1px solid #f1e8d0; font-size: 14px; }
.me-row span { color: #6b7a6e; }

/* ══════════════ Admin panel ══════════════ */
.admin-shell {
  display: grid; grid-template-columns: 220px 1fr; gap: 24px;
  max-width: 1200px; margin: 16px auto; padding: 0 16px;
}
.admin-nav {
  background: #fff; border: 1px solid #e8dcc1; border-radius: 14px; padding: 14px;
  display: flex; flex-direction: column; gap: 2px; height: fit-content; position: sticky; top: 80px;
}
.admin-nav a {
  padding: 10px 12px; border-radius: 8px; text-decoration: none; color: #3a4a3e;
  font-size: 14px; font-weight: 500; transition: background .15s;
}
.admin-nav a:hover { background: #f5ecd4; }
.admin-nav a.active { background: #1B2D1E; color: #F2E4C1; font-weight: 600; }
.admin-nav .nav-sep { height: 1px; background: #e8dcc1; margin: 8px 0; }
.admin-main {
  background: #fff; border: 1px solid #e8dcc1; border-radius: 14px; padding: 28px;
}
.admin-header {
  display: flex; justify-content: space-between; align-items: center; margin-bottom: 24px;
  padding-bottom: 16px; border-bottom: 1px solid #f1e8d0;
}
.admin-header h1 { margin: 0; font-size: 22px; font-weight: 800; color: #1B2D1E; }
.admin-table {
  width: 100%; border-collapse: collapse; font-size: 14px;
}
.admin-table th, .admin-table td {
  padding: 12px 10px; text-align: left; border-bottom: 1px solid #f1e8d0;
}
.admin-table th { font-size: 12px; font-weight: 700; text-transform: uppercase; color: #6b7a6e; letter-spacing: 0.5px; }
.admin-table tr:hover td { background: #fdfbf5; }
.admin-badge {
  display: inline-block; padding: 3px 10px; border-radius: 20px; font-size: 11px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.5px;
}
.badge-admin   { background: #6B3FA0; color: #fff; }
.badge-member  { background: #e8dcc1; color: #5a6a5e; }
.badge-pro     { background: #F2E4C1; color: #1B2D1E; }
.badge-banned  { background: #fee2e2; color: #991b1b; }
.admin-form { display: grid; gap: 16px; max-width: 640px; }
.admin-form label { display: flex; flex-direction: column; gap: 6px; font-size: 13px; font-weight: 600; color: #3a4a3e; }
.admin-form input, .admin-form textarea, .admin-form select {
  padding: 10px 12px; border: 1.5px solid #e8dcc1; border-radius: 8px;
  font-size: 14px; font-family: inherit; background: #fdfbf5;
}
.admin-form textarea { min-height: 140px; resize: vertical; font-family: 'SF Mono', Consolas, monospace; font-size: 13px; }
.admin-form input:focus, .admin-form textarea:focus, .admin-form select:focus {
  outline: none; border-color: #6B3FA0; background: #fff;
}
.admin-row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.admin-actions { display: flex; gap: 8px; align-items: center; }
.admin-stat {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 12px;
  margin-bottom: 24px;
}
.stat-card { background: #fdfbf5; border: 1px solid #e8dcc1; border-radius: 12px; padding: 16px; }
.stat-label { font-size: 12px; color: #6b7a6e; text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 6px; }
.stat-value { font-size: 26px; font-weight: 800; color: #1B2D1E; }
.admin-link { color: #6B3FA0; text-decoration: none; font-weight: 600; font-size: 13px; }
.admin-link:hover { text-decoration: underline; }
.flash {
  padding: 12px 16px; border-radius: 10px; margin-bottom: 20px; font-size: 14px; font-weight: 500;
}
.flash-ok  { background: #f0fdf4; color: #166534; border: 1px solid #bbf7d0; }
.flash-err { background: #fef2f2; color: #991b1b; border: 1px solid #fecaca; }

@media (max-width: 900px) {
  .admin-shell { grid-template-columns: 1fr; }
  .admin-nav { position: static; flex-direction: row; overflow-x: auto; flex-wrap: nowrap; }
  .admin-nav a { white-space: nowrap; }
  .admin-row2 { grid-template-columns: 1fr; }
}

/* ══════════════ Topbar user state ══════════════ */
.topbar-auth { display: flex; align-items: center; gap: 8px; }
.topbar-auth a { font-size: 13px; font-weight: 600; color: #1B2D1E; text-decoration: none; padding: 8px 14px; border-radius: 8px; }
.topbar-auth a:hover { background: #f5ecd4; }
.topbar-auth .btn-primary { padding: 8px 16px; font-size: 13px; }
.user-menu { position: relative; }
.user-menu-btn {
  display: flex; align-items: center; gap: 8px; background: transparent; border: none; cursor: pointer;
  padding: 4px; border-radius: 20px;
}
.user-menu-btn:hover { background: #f5ecd4; }

/* ══════════════ Footer ══════════════ */
.app-footer {
  margin: 60px 0 0; padding: 40px 24px 24px;
  border-top: 1px solid #e8dcc1; background: #f9f2df;
  color: #3a4a3e; font-size: 14px;
}
.footer-grid {
  display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 40px;
  max-width: 1200px; margin: 0 auto 32px;
}
.footer-col { display: flex; flex-direction: column; gap: 8px; }
.footer-col a { color: #3a4a3e; text-decoration: none; transition: color .15s; }
.footer-col a:hover { color: #6B3FA0; }
.footer-brand { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.footer-brand-icon {
  width: 32px; height: 32px; background: #1B2D1E; color: #F2E4C1;
  border-radius: 8px; display: grid; place-items: center; font-weight: 800;
}
.footer-brand strong { font-size: 16px; color: #1B2D1E; }
.footer-tag { color: #6b7a6e; line-height: 1.5; font-size: 13px; margin: 0; }
.footer-heading { font-size: 12px; font-weight: 700; color: #1B2D1E; text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 4px; }
.footer-bottom {
  max-width: 1200px; margin: 0 auto; padding-top: 24px;
  border-top: 1px solid #e8dcc1; color: #6b7a6e; font-size: 13px; text-align: center;
}
.footer-bottom a { color: #6B3FA0; text-decoration: none; font-weight: 600; }
.footer-bottom a:hover { text-decoration: underline; }

/* ══════════════ About page ══════════════ */
.about-wrap { max-width: 720px; margin: 32px auto; padding: 0 16px; }
.about-hero {
  background: linear-gradient(135deg, #1B2D1E, #2a3f2e); color: #F2E4C1;
  border-radius: 18px; padding: 48px 40px; margin-bottom: 32px;
}
.about-hero h1 { margin: 0 0 12px; font-size: 32px; font-weight: 800; }
.about-hero p { margin: 0; font-size: 17px; line-height: 1.6; opacity: 0.9; }
.about-section {
  background: #fff; border: 1px solid #e8dcc1; border-radius: 14px;
  padding: 28px 32px; margin-bottom: 20px;
}
.about-section h2 { margin: 0 0 12px; font-size: 20px; font-weight: 800; color: #1B2D1E; }
.about-section p { margin: 0 0 12px; line-height: 1.7; color: #3a4a3e; font-size: 15px; }
.about-section ul { margin: 12px 0; padding-left: 20px; line-height: 1.8; color: #3a4a3e; }
.about-section a { color: #6B3FA0; font-weight: 600; text-decoration: none; }
.about-section a:hover { text-decoration: underline; }

@media (max-width: 900px) {
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 24px; }
}
@media (max-width: 540px) {
  .footer-grid { grid-template-columns: 1fr; }
}
