/* =========================================================
   BGF — public + admin styles
   Tokens → Reset → Layout → Components → Public pages → Admin
   ========================================================= */

:root {
  --green-900: #0e3b1b;
  --green-700: #196b2f;
  --green-500: #2c9a44;
  --green-300: #7ed188;
  --green-50:  #ecf6ee;

  --ink-900: #0e1411;
  --ink-700: #27322b;
  --ink-500: #556055;
  --ink-300: #98a29a;
  --ink-100: #e7ebe7;
  --ink-50:  #f5f7f5;

  --red-500: #c24040;
  --amber-500: #d68a1b;

  --radius: 8px;
  --radius-lg: 14px;
  --container: 1200px;
  --shadow-sm: 0 1px 2px rgba(0,0,0,.06), 0 1px 1px rgba(0,0,0,.04);
  --shadow:    0 6px 18px rgba(0,0,0,.08);
  --ease: cubic-bezier(.2,.7,.2,1);

  --font-body: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
  --font-head: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
}

/* Reset */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--font-body);
  color: var(--ink-900);
  background-color: #eeeeee;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
img, video { max-width: 100%; display: block; }
a { color: var(--green-700); text-decoration: none; }
a:hover { color: var(--green-900); }
h1, h2, h3, h4 { font-family: var(--font-head); line-height: 1.2; color: var(--ink-900); margin: 0 0 .5em; }
h1 { font-size: clamp(2rem, 4vw, 3rem); letter-spacing: -.02em; }
h2 { font-size: clamp(1.5rem, 2.8vw, 2.125rem); letter-spacing: -.015em; }
h3 { font-size: 1.25rem; }
p  { margin: 0 0 1rem; }
button { font: inherit; cursor: pointer; }

.container { width: min(100% - 32px, var(--container)); margin-inline: auto; }

/* =========================================================
   Site header / nav
========================================================= */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--ink-100);
}
.site-header .container {
  display: flex; align-items: center; gap: 24px;
  min-height: 72px;
}
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; color: var(--green-900); }
.brand-mark {
  width: 34px; height: 34px; border-radius: 8px;
  background: linear-gradient(135deg, var(--green-500), var(--green-700));
  display: inline-grid; place-items: center; color: #fff; font-weight: 800;
}
.primary-nav { display: flex; gap: 22px; margin-inline: auto; }
.primary-nav > a, .primary-nav .has-sub > button {
  color: var(--ink-700); font-weight: 500; padding: 8px 2px; background: transparent; border: 0;
  position: relative;
}
.primary-nav > a:hover, .primary-nav .has-sub > button:hover { color: var(--green-700); }
.primary-nav a.is-active::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -6px;
  height: 2px; background: var(--green-500); border-radius: 2px;
}
.has-sub { position: relative; }
.has-sub .sub {
  position: absolute; top: 100%; left: 0;
  background: #fff; border: 1px solid var(--ink-100); border-radius: var(--radius);
  padding: 8px; min-width: 180px; box-shadow: var(--shadow);
  opacity: 0; visibility: hidden; transform: translateY(4px);
  transition: .15s var(--ease);
}
.has-sub:hover .sub, .has-sub:focus-within .sub {
  opacity: 1; visibility: visible; transform: translateY(0);
}
.has-sub .sub a { display: block; padding: 8px 10px; border-radius: 6px; color: var(--ink-700); }
.has-sub .sub a:hover { background: var(--green-50); color: var(--green-900); }

.lang-switch { display: inline-flex; border: 1px solid var(--ink-100); border-radius: 999px; overflow: hidden; }
.lang-switch a { padding: 6px 10px; font-size: .85rem; color: var(--ink-500); }
.lang-switch a.is-active { background: var(--green-700); color: #fff; }

.nav-toggle {
  display: none; background: transparent; border: 1px solid var(--ink-100);
  border-radius: 8px; padding: 8px 10px;
}

@media (max-width: 960px) {
  .nav-toggle { display: inline-flex; }
  .primary-nav {
    position: absolute; top: 72px; left: 0; right: 0; background: #fff;
    flex-direction: column; gap: 4px; padding: 12px 16px;
    border-bottom: 1px solid var(--ink-100); display: none;
  }
  .primary-nav.is-open { display: flex; }
  .primary-nav > a, .primary-nav .has-sub > button { padding: 10px 4px; }
}

/* =========================================================
   Buttons + badges + form controls
========================================================= */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 16px; border-radius: 999px;
  border: 1px solid var(--green-700); color: var(--green-900); background: transparent;
  font-weight: 600; transition: .18s var(--ease);
}
.btn:hover { background: var(--green-50); color: var(--green-900); }
.btn.primary { background: var(--green-700); color: #fff; border-color: var(--green-700); }
.btn.primary:hover { background: var(--green-900); }
.btn.ghost { border-color: var(--ink-100); color: var(--ink-700); }
.btn.link { padding: 0; border: 0; background: transparent; color: var(--green-700); font-weight: 600; }
.btn.link::after { content: " →"; }

.badge { display: inline-block; padding: 3px 10px; background: var(--green-50); color: var(--green-900); border-radius: 999px; font-size: .75rem; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; }

input[type="text"], input[type="email"], input[type="password"], input[type="url"], input[type="date"], input[type="number"], textarea, select {
  width: 100%; padding: 10px 12px; border: 1px solid var(--ink-100);
  border-radius: var(--radius); background: #fff; color: var(--ink-900);
  font: inherit; transition: border-color .15s var(--ease), box-shadow .15s var(--ease);
}
input:focus, textarea:focus, select:focus {
  outline: none; border-color: var(--green-500); box-shadow: 0 0 0 3px rgba(44,154,68,.2);
}
label { display: block; font-weight: 500; color: var(--ink-700); margin-bottom: 14px; }
label > span { display: block; font-size: .85rem; margin-bottom: 4px; color: var(--ink-500); }
textarea { min-height: 140px; resize: vertical; }

.alert { padding: 10px 14px; border-radius: var(--radius); margin: 12px 0; }
.alert.ok  { background: #e6f6e9; color: #195b2d; border: 1px solid #c9e8ce; }
.alert.err { background: #fbebea; color: #7a2323; border: 1px solid #f1c8c6; }

/* =========================================================
   Hero / carousel
========================================================= */
.hero { position: relative; overflow: hidden; background: #000; color: #fff; }
.hero-slides { position: relative; aspect-ratio: 21 / 9; min-height: 380px; }
@media (max-width: 720px) { .hero-slides { aspect-ratio: 4/5; min-height: 560px; } }
.hero-slide {
  position: absolute; inset: 0;
  background-size: cover; background-position: center;
  opacity: 0; transition: opacity .8s var(--ease);
}
.hero-slide.is-active { opacity: 1; }
.hero-slide::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,.15) 0%, rgba(0,0,0,.65) 80%);
}
.hero-copy {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 48px 0 56px;
  z-index: 2;
}
.hero-copy .container { max-width: 760px; }
.hero-copy .badge { background: rgba(255,255,255,.15); color: #fff; }
.hero-copy h1 { color: #fff; margin-top: 12px; }
.hero-copy p { color: rgba(255,255,255,.85); font-size: 1.05rem; }
.hero-copy .btn { border-color: rgba(255,255,255,.7); color: #fff; }
.hero-copy .btn:hover { background: rgba(255,255,255,.15); }
.hero-dots {
  position: absolute; bottom: 18px; left: 50%; transform: translateX(-50%); z-index: 3;
  display: flex; gap: 8px;
}
.hero-dots button {
  width: 24px; height: 4px; border-radius: 2px; border: 0; background: rgba(255,255,255,.4);
  transition: background .2s var(--ease);
}
.hero-dots button.is-active { background: #fff; }

/* =========================================================
   Section scaffolding
========================================================= */
section.section { padding: 72px 0; }
section.section.tight { padding: 48px 0; }
section.section.alt { background: var(--ink-50); }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 16px; margin-bottom: 32px; }
.section-head h2 { margin: 0; }
.lede { color: var(--ink-500); font-size: 1.05rem; text-align: justify; }
.section-head .lede { margin-left: auto; }

/* =========================================================
   Cards & grids
========================================================= */
.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 24px; }
.pub-type-section .card-grid,
.card-grid[data-press-list],
.card-grid[data-project-list] { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 900px) {
  .pub-type-section .card-grid,
  .card-grid[data-press-list],
  .card-grid[data-project-list] { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 680px) {
  .pub-type-section .card-grid,
  .card-grid[data-press-list],
  .card-grid[data-project-list] { grid-template-columns: 1fr; }
}
.card {
  background: #fff; border: 1px solid var(--ink-100); border-radius: var(--radius-lg);
  overflow: hidden; display: flex; flex-direction: column;
  transition: transform .2s var(--ease), box-shadow .2s var(--ease), border-color .2s var(--ease);
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: transparent; }
.card-media { aspect-ratio: 16/10; background: var(--ink-100) center/cover no-repeat; }
.card-body { padding: 18px 20px 22px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.card-date { color: var(--ink-500); font-size: .8rem; letter-spacing: .03em; }
.card h3 { font-size: 1.1rem; margin: 0; color: var(--ink-900); }
.card h3 a { color: inherit; }
.card h3 a:hover { color: var(--green-700); }
.card .excerpt { color: var(--ink-500); font-size: .95rem; flex: 1; }
.card .card-foot { margin-top: auto; }
.card-grid[data-tools-list] { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 680px) { .card-grid[data-tools-list] { grid-template-columns: 1fr; } }
.tool-desc {
  display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.tool-desc.is-open { display: block; -webkit-line-clamp: none; line-clamp: none; }
.tool-desc-toggle {
  align-self: flex-start; font-size: .85rem; padding: 0;
  background: none; border: 0; cursor: pointer; color: var(--green-700);
}
.opportunity-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 18px; }
.opportunity-card .card-media { aspect-ratio: 16/8; }
.opportunity-card .card-body { padding: 14px 16px 16px; gap: 8px; }
.opportunity-card h3 { font-size: 1rem; }
.opportunity-card .excerpt {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.opportunity-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

/* Programs strip */
.program-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
@media (max-width: 900px) { .program-grid { grid-template-columns: 1fr; } }
.program {
  padding: 28px; border-radius: var(--radius-lg);
  background: linear-gradient(160deg, var(--green-50), #fff 70%);
  border: 1px solid #dcecde;
  display: flex; flex-direction: column; gap: 12px;
}
.program h3 { color: var(--green-900); }
.program-list {
  display: flex;
  flex-direction: column;
  gap: 28px;
  margin-top: 40px;
}
.program-list-row {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr);
  gap: 24px;
  align-items: stretch;
}
.program-list-row.is-reversed .program-list-photo { order: 2; }
.program-list-row.is-reversed .program-list-copy { order: 1; }
.program-list-photo {
  display: block;
  min-height: 360px;
  border-radius: var(--radius-lg);
  background: var(--ink-100) center/cover no-repeat;
  overflow: hidden;
}
.program-list-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 14px;
  padding: 34px;
  background: #fff;
  border: 1px solid var(--ink-100);
  border-radius: var(--radius-lg);
}
.program-list-copy h2 { margin: 0; }
.program-list-copy p {
  color: var(--ink-700);
  font-size: 1rem;
  line-height: 1.7;
}
.program-list-copy .btn { align-self: flex-start; }
@media (max-width: 900px) {
  .program-list { margin-top: 28px; }
  .program-list-row { grid-template-columns: 1fr; }
  .program-list-row.is-reversed .program-list-photo,
  .program-list-row.is-reversed .program-list-copy { order: initial; }
  .program-list-photo { min-height: 240px; }
  .program-list-copy { padding: 24px; }
}

/* Team */
.team-groups { display: grid; gap: 48px; }
.team-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 20px; }
.member { text-align: center; position: relative; }
.member-trigger {
  display: block;
  position: relative;
  width: 160px;
  max-width: 100%;
  margin: 0 auto 12px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
}
.member-trigger:disabled { cursor: default; }
.member .avatar {
  display: block;
  aspect-ratio: 1; border-radius: 50%;
  background: var(--ink-100) center/cover no-repeat;
  width: 100%;
  box-shadow: var(--shadow-sm);
}
.member h4 { margin: 4px 0 2px; font-size: 1rem; }
.member .role { color: var(--ink-500); font-size: .9rem; }
.member-name {
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--ink-900);
  font-weight: 700;
}
.member.has-bio .member-name:hover,
.member.has-bio .member-name:focus {
  color: var(--green-700);
}
.member-hover {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(14,59,27,.78);
  color: #fff;
  font-weight: 700;
  opacity: 0;
  transition: opacity .18s var(--ease);
}
@media (hover: hover) and (pointer: fine) {
  .member.has-bio:hover .member-hover,
  .member.has-bio:focus-within .member-hover {
    opacity: 1;
  }
}
.member-modal[hidden] { display: none; }
.member-modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 24px;
}
.member-modal-backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(14,20,17,.58);
}
.member-dialog {
  position: relative;
  z-index: 1;
  width: min(960px, 100%);
  max-height: calc(100vh - 48px);
  overflow: auto;
  display: flex;
  flex-direction: column;
  gap: 28px;
  padding: 28px;
  border-radius: var(--radius-lg);
  background: #fff;
  box-shadow: var(--shadow);
}
.member-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 36px;
  height: 36px;
  border: 1px solid var(--ink-100);
  border-radius: 50%;
  background: #fff;
  color: var(--ink-700);
  font-size: 1.4rem;
  line-height: 1;
  z-index: 2;
}
.member-dialog-main {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 28px;
  transition: opacity .18s var(--ease);
}
.member-dialog-main.is-swapping { opacity: 0; }
.member-dialog-photo {
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--ink-100) center/cover no-repeat;
  box-shadow: var(--shadow-sm);
}
.member-dialog-copy h2 { margin-right: 32px; }
.member-dialog-copy .role { margin-bottom: 18px; color: var(--green-700); font-weight: 700; }
.member-dialog-copy .body { color: var(--ink-700); }

/* Peer carousel rail inside the bio modal */
.member-rail[hidden] { display: none; }
.member-rail {
  border-top: 1px solid var(--ink-100);
  padding-top: 20px;
}
.member-rail-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}
.member-rail-eyebrow {
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-500);
}
.member-rail-nav {
  display: flex;
  gap: 8px;
}
.member-rail-arrow {
  width: 34px;
  height: 34px;
  border: 1px solid var(--ink-100);
  border-radius: 50%;
  background: #fff;
  color: var(--ink-700);
  font-size: 1.1rem;
  line-height: 1;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: color .15s var(--ease), border-color .15s var(--ease), transform .15s var(--ease);
}
.member-rail-arrow:hover:not(:disabled) {
  color: var(--green-700);
  border-color: var(--green-300);
  transform: translateY(-1px);
}
.member-rail-arrow:disabled {
  opacity: .3;
  cursor: default;
}
.member-rail-track {
  list-style: none;
  margin: 0;
  padding: 4px 2px 6px;
  display: flex;
  gap: 18px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-width: none;
  -ms-overflow-style: none;
}
.member-rail-track::-webkit-scrollbar { display: none; }
.member-rail-item {
  flex: 0 0 96px;
  scroll-snap-align: start;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.member-rail-btn {
  width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}
.member-rail-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--ink-100) center/cover no-repeat;
  box-shadow: var(--shadow-sm);
  transition: box-shadow .18s var(--ease), transform .18s var(--ease);
}
.member-rail-btn:hover .member-rail-avatar,
.member-rail-btn:focus-visible .member-rail-avatar {
  transform: translateY(-2px);
  box-shadow: 0 0 0 2px var(--green-300), var(--shadow-sm);
}
.member-rail-item.is-active .member-rail-avatar {
  box-shadow: 0 0 0 3px var(--green-700), var(--shadow-sm);
}
.member-rail-name {
  font-size: .82rem;
  font-weight: 700;
  color: var(--ink-900);
  line-height: 1.2;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.member-rail-item.is-active .member-rail-name { color: var(--green-900); }
.member-rail-role {
  font-size: .72rem;
  color: var(--ink-500);
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

@media (max-width: 680px) {
  .member-dialog { padding: 24px 18px; gap: 22px; }
  .member-dialog-main {
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: center;
  }
  .member-dialog-photo { width: 160px; }
  .member-dialog-copy h2 { margin-right: 0; }
}

/* Newsletter */
.newsletter {
  background: linear-gradient(120deg, var(--green-700), var(--green-900));
  color: #fff; padding: 56px 0; margin-top: 64px;
}
.newsletter h2 { color: #fff; }
.newsletter form { display: flex; gap: 10px; max-width: 520px; }
.newsletter input[type="email"] {
  flex: 1; border-color: rgba(255,255,255,.2); background: rgba(255,255,255,.1); color: #fff;
}
.newsletter input::placeholder { color: rgba(255,255,255,.6); }
.newsletter .btn { border-color: #fff; color: #fff; }
.newsletter .btn:hover { background: #fff; color: var(--green-900); }
.newsletter .msg { font-size: .9rem; margin-top: 10px; min-height: 1.2em; }

/* Footer */
.site-footer {
  background: var(--ink-900); color: #c6ccc6; padding: 56px 0 28px;
}
.site-footer h4 { color: #fff; margin-bottom: 14px; font-size: .95rem; letter-spacing: .08em; text-transform: uppercase; }
.footer-grid {
  display: grid; grid-template-columns: 1.2fr 1fr 1fr 1fr; gap: 32px;
}
@media (max-width: 820px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .footer-grid { grid-template-columns: 1fr; } }
.site-footer a { color: #c6ccc6; }
.site-footer a:hover { color: #fff; }
.footer-bottom {
  border-top: 1px solid #2a322d; margin-top: 40px; padding-top: 20px;
  display: flex; justify-content: space-between; gap: 12px; font-size: .85rem;
  color: #89938a;
}
.socials { display: flex; gap: 10px; }
.socials a {
  width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center;
  border: 1px solid #2a322d; transition: .2s var(--ease);
}
.socials a:hover { background: var(--green-700); color: #fff; border-color: var(--green-700); }

/* Filters / pagination */
.filters { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 28px; }
.filters a {
  padding: 6px 12px; border-radius: 999px; border: 1px solid var(--ink-100);
  color: var(--ink-700); font-size: .9rem;
}
.filters a.is-active { background: var(--green-700); color: #fff; border-color: var(--green-700); }
.more-wrap { display: flex; justify-content: center; margin-top: 28px; }

/* Detail pages */
.article {
  max-width: 760px; margin-inline: auto;
}
.article h1 { margin-bottom: 8px; }
.article .meta { color: var(--ink-500); font-size: .9rem; margin-bottom: 28px; }
.article img.cover { width: 100%; border-radius: var(--radius-lg); margin-bottom: 28px; }
.article .body { font-size: 1.05rem; line-height: 1.75; color: var(--ink-700); }

/* Error pages */
.page-error { padding: 140px 0; text-align: center; }
.page-error h1 { font-size: clamp(4rem, 10vw, 7rem); color: var(--green-700); }

/* Contact layout */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; }
@media (max-width: 820px) { .contact-grid { grid-template-columns: 1fr; } }
.contact-info p { color: var(--ink-500); }
.contact-info strong { color: var(--ink-900); display: block; }

/* Videos + infographics */
.video-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px,1fr)); gap: 24px; }
.video iframe { width: 100%; aspect-ratio: 16/9; border: 0; border-radius: var(--radius); }

/* Partners */
.partner-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 28px;
  align-items: center;
}
.partner-grid img { max-height: 60px; margin-inline: auto; filter: grayscale(1); opacity: .8; transition: .2s var(--ease); }
.partner-grid a:hover img { filter: none; opacity: 1; }

/* =========================================================
   Admin
========================================================= */
body.admin { background: var(--ink-50); display: grid; grid-template-columns: 240px 1fr; min-height: 100vh; }
@media (max-width: 820px) { body.admin { grid-template-columns: 1fr; } }

.admin-side {
  background: var(--ink-900); color: #c6ccc6; padding: 20px 14px;
  display: flex; flex-direction: column; min-height: 100vh; position: sticky; top: 0;
}
.admin-brand { color: #fff; font-weight: 700; font-size: 1.1rem; margin-bottom: 20px; display: block; }
.admin-nav { display: grid; gap: 2px; }
.admin-nav a {
  padding: 8px 12px; border-radius: 6px; color: #c6ccc6; font-size: .92rem;
}
.admin-nav a:hover { background: rgba(255,255,255,.06); color: #fff; }
.admin-nav a.is-active { background: var(--green-700); color: #fff; }
.admin-logout { margin-top: auto; padding-top: 16px; }
.admin-logout button {
  width: 100%; padding: 8px 12px; border-radius: 6px; border: 1px solid #2a322d;
  background: transparent; color: #c6ccc6;
}
.admin-logout button:hover { background: rgba(255,255,255,.06); color: #fff; }

.admin-main { padding: 28px; }
.admin-page-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; margin-bottom: 24px;
}
.admin-page-head h1 { margin: 0; font-size: 1.6rem; }

.admin-login {
  max-width: 360px; margin: 80px auto; background: #fff; padding: 32px;
  border-radius: var(--radius-lg); box-shadow: var(--shadow); grid-column: 1 / -1;
}
body.admin:has(.admin-login) { grid-template-columns: 1fr; }

.stat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px,1fr)); gap: 16px; }
.stat {
  background: #fff; border: 1px solid var(--ink-100); border-radius: var(--radius-lg);
  padding: 20px; display: flex; flex-direction: column; gap: 4px;
}
.stat:hover { border-color: var(--green-500); }
.stat-n { font-size: 2rem; font-weight: 700; color: var(--green-900); }
.stat-l { color: var(--ink-500); text-transform: capitalize; }

.admin-table {
  width: 100%; border-collapse: collapse; background: #fff;
  border: 1px solid var(--ink-100); border-radius: var(--radius-lg); overflow: hidden;
}
.admin-table th, .admin-table td {
  padding: 12px 14px; text-align: left; border-bottom: 1px solid var(--ink-100);
  vertical-align: middle;
}
.admin-table th { background: var(--ink-50); font-size: .85rem; color: var(--ink-500); text-transform: uppercase; letter-spacing: .05em; }
.admin-table tr:last-child td { border-bottom: 0; }
.admin-table .actions { display: flex; gap: 8px; justify-content: end; }
.admin-table .thumb { width: 60px; height: 40px; background: var(--ink-100) center/cover no-repeat; border-radius: 4px; }

.admin-form {
  background: #fff; border: 1px solid var(--ink-100); border-radius: var(--radius-lg);
  padding: 28px; display: grid; gap: 0;
}
.admin-language-block {
  border: 1px solid var(--ink-100);
  border-radius: var(--radius);
  padding: 18px;
  margin-bottom: 18px;
  background: var(--ink-50);
}
.admin-language-block h2 {
  margin: 0 0 14px;
  font-size: 1rem;
}
.admin-form .row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
@media (max-width: 720px) { .admin-form .row-2 { grid-template-columns: 1fr; } }
.admin-form .form-actions { display: flex; gap: 10px; justify-content: end; margin-top: 16px; }
.admin-form .current-file { margin-top: 4px; font-size: .85rem; color: var(--ink-500); }
.admin-form .current-file img { max-height: 90px; margin-top: 6px; border-radius: 6px; }
.rich-editor-wrap {
  border: 1px solid var(--ink-100);
  border-radius: var(--radius);
  background: #fff;
  overflow: hidden;
}
.rich-editor-toolbar {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  padding: 8px;
  border-bottom: 1px solid var(--ink-100);
  background: var(--ink-50);
}
.rich-editor-toolbar button {
  border: 1px solid var(--ink-100);
  background: #fff;
  color: var(--ink-700);
  border-radius: 6px;
  padding: 5px 8px;
  font-size: .85rem;
}
.rich-editor-toolbar button:hover {
  border-color: var(--green-500);
  color: var(--green-900);
}
.rich-editor-surface {
  min-height: 240px;
  padding: 12px;
  color: var(--ink-900);
  background: #fff;
  outline: none;
}
.rich-editor-surface:focus {
  box-shadow: inset 0 0 0 3px rgba(44,154,68,.16);
}
.rich-editor-surface ul,
.rich-editor-surface ol {
  margin: 0 0 1rem 1.5rem;
}
.rich-editor-source {
  display: none;
}

.admin-search input { max-width: 280px; }
