@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=Manrope:wght@400;500;600;700;800&display=swap');

:root {
  color-scheme: light;
  --ink: #17241f;
  --muted: #78827d;
  --line: #e8ece8;
  --green: #2c805e;
  --green-dark: #20694c;
  --green-soft: #eaf5ee;
  --paper: #f7f9f6;
  --white: #fff;
  --orange: #e9a35f;
  font-family: "DM Sans", sans-serif;
}

* { box-sizing: border-box; }
body { margin: 0; background: var(--paper); color: var(--ink); font-size: 14px; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
.app-shell { min-height: 100vh; }
.sidebar { position: fixed; inset: 0 auto 0 0; z-index: 3; display: flex; width: 248px; flex-direction: column; padding: 28px 20px 20px; border-right: 1px solid var(--line); background: var(--white); }
.brand { display: flex; align-items: center; gap: 11px; font-family: Manrope, sans-serif; font-size: 19px; font-weight: 800; letter-spacing: -.8px; }
.brand-mark { display: grid; width: 39px; height: 39px; place-items: center; border-radius: 12px; background: var(--green); color: white; font-size: 20px; }
.brand-dot { color: var(--green); }
.brand small { display: block; margin-top: 1px; color: #97a09b; font-family: "DM Sans", sans-serif; font-size: 9px; font-weight: 700; letter-spacing: 1.3px; }
.nav-label, .eyebrow { color: #98a19b; font-size: 10px; font-weight: 700; letter-spacing: 1.5px; }
.nav-label { margin: 52px 0 12px 10px; }
.main-nav { display: grid; gap: 5px; }
.main-nav a { display: flex; align-items: center; gap: 13px; padding: 12px 13px; border-radius: 9px; color: #707b75; font-weight: 600; }
.main-nav a:first-child, .main-nav a:hover { background: var(--green-soft); color: var(--green-dark); }
.main-nav a:first-letter { font-size: 18px; }
.sidebar-bottom { margin-top: auto; }
.admin-chip { display: flex; align-items: center; gap: 10px; padding: 14px 5px; border-top: 1px solid var(--line); }
.avatar { display: grid; width: 34px; height: 34px; place-items: center; border-radius: 50%; background: #e7f2eb; color: var(--green-dark); font-weight: 700; }
.admin-chip strong, .admin-chip small { display: block; }
.admin-chip strong { font-size: 12px; }
.admin-chip small { margin-top: 3px; color: var(--muted); font-size: 11px; }
.logout-button { display: flex; gap: 11px; align-items: center; width: 100%; padding: 10px 12px; border: 0; background: transparent; color: #707b75; text-align: left; }
.main-content { min-height: 100vh; margin-left: 248px; }
.topbar { display: flex; height: 67px; align-items: center; justify-content: space-between; padding: 0 42px; border-bottom: 1px solid var(--line); background: var(--white); }
.topbar-status { color: #6d7972; font-size: 12px; }
.topbar-status i { display: inline-block; width: 7px; height: 7px; margin-right: 6px; border-radius: 50%; background: #54b77b; }
.page-content { max-width: 1440px; margin: 0 auto; padding: 34px 42px 56px; }
.page-heading { display: flex; justify-content: space-between; align-items: end; margin-bottom: 24px; }
.page-heading .eyebrow { margin: 0 0 8px; }
h1, h2, p { margin-top: 0; }
h1, h2 { font-family: Manrope, sans-serif; letter-spacing: -.7px; }
h1 { margin-bottom: 0; font-size: 27px; }
h2 { margin-bottom: 8px; font-size: 18px; }
.welcome-banner { position: relative; display: flex; min-height: 250px; overflow: hidden; align-items: center; justify-content: space-between; padding: 32px 42px; border-radius: 15px; background: #e8f2e9; }
.welcome-banner > div:first-child { position: relative; z-index: 1; max-width: 440px; }
.welcome-banner .eyebrow { color: var(--green); }
.welcome-banner h2 { margin: 13px 0 8px; font-size: 30px; line-height: 1.18; }
.welcome-banner p:not(.eyebrow) { max-width: 360px; margin-bottom: 18px; color: #68766d; line-height: 1.6; }
.banner-art { position: absolute; inset: 0 0 0 48%; overflow: hidden; }
.sun { position: absolute; top: 28px; right: 83px; width: 75px; height: 75px; border-radius: 50%; background: #f1c48a; opacity: .8; }
.mountain { position: absolute; right: -25px; bottom: 47px; width: 58%; height: 170px; transform: rotate(0deg); clip-path: polygon(0 100%, 46% 12%, 100% 100%); background: #9cbea2; }
.mountain-back { right: 32%; bottom: 34px; width: 50%; height: 135px; background: #bad1b8; }
.mountain-front { background: #72a27d; }
.banner-water { position: absolute; right: 0; bottom: 0; left: 0; height: 48px; background: #c9ded0; }
.button { display: inline-flex; min-height: 40px; align-items: center; justify-content: center; gap: 18px; padding: 0 16px; border: 0; border-radius: 8px; font-weight: 700; }
.button-primary { background: var(--green); color: white; }
.button-primary:hover { background: var(--green-dark); }
.button-light { background: white; color: var(--green-dark); }
.button-wide { width: 100%; }
.stats-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin: 22px 0; }
.stat-card, .panel { border: 1px solid var(--line); border-radius: 12px; background: var(--white); }
.stat-card { position: relative; min-height: 145px; padding: 19px 21px; }
.stat-icon { position: absolute; top: 18px; right: 19px; display: grid; width: 35px; height: 35px; place-items: center; border-radius: 10px; font-size: 17px; }
.icon-green { background: #eaf5ee; color: var(--green); }
.icon-blue { background: #eaf2fa; color: #4a83bd; }
.icon-orange { background: #fff2e4; color: #d98a42; }
.stat-card p { margin: 0 0 8px; color: var(--muted); font-size: 12px; }
.stat-card strong { display: block; font-family: Manrope, sans-serif; font-size: 27px; }
.stat-card small { display: block; margin-top: 5px; color: #98a19b; font-size: 11px; }
.panel { padding: 23px; }
.api-panel { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 6px 24px; margin-bottom: 22px; background: #fbfdfb; }
.api-panel .eyebrow, .section-heading .eyebrow, .form-panel .eyebrow { margin-bottom: 7px; }
.api-panel h2 { margin-bottom: 5px; }
.api-panel p:not(.eyebrow) { margin-bottom: 0; color: var(--muted); font-size: 12px; }
.api-panel code { grid-column: 2; grid-row: 1; padding: 10px 12px; border: 1px solid var(--line); border-radius: 7px; background: white; color: var(--green-dark); font-size: 11px; }
.api-panel .text-link { grid-column: 2; text-align: right; }
.text-link { color: var(--green); font-size: 12px; font-weight: 700; }
.section-heading { display: flex; align-items: center; justify-content: space-between; margin-bottom: 19px; }
.section-heading h2 { margin-bottom: 0; }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; text-align: left; }
th { padding: 11px 12px; border-bottom: 1px solid var(--line); color: #9aa39d; font-size: 9px; letter-spacing: 1px; white-space: nowrap; }
td { padding: 14px 12px; border-bottom: 1px solid #f0f2f0; color: #68736d; font-size: 12px; }
tbody tr:last-child td { border-bottom: 0; }
.table-primary { color: var(--ink); font-weight: 700; }
.table-subtext { display: block; margin-top: 4px; color: #939c96; font-size: 11px; font-weight: 400; }
.status { display: inline-flex; padding: 5px 8px; border-radius: 20px; font-size: 10px; font-weight: 700; white-space: nowrap; }
.status-published { background: #eaf5ee; color: #32815e; }
.status-draft { background: #f1f2f1; color: #737d77; }
.content-grid { display: grid; grid-template-columns: minmax(270px, .75fr) minmax(0, 1.6fr); align-items: start; gap: 20px; }
.form-panel h2 { margin-bottom: 6px; }
.muted { color: var(--muted); font-size: 12px; line-height: 1.6; }
.form-stack { display: grid; gap: 14px; margin-top: 19px; }
.form-stack label { display: grid; gap: 7px; color: #46534b; font-size: 12px; font-weight: 700; }
.form-stack input, .form-stack select, .form-stack textarea { width: 100%; min-height: 40px; padding: 10px 11px; border: 1px solid #e1e7e2; border-radius: 7px; outline: none; background: white; color: var(--ink); font-size: 12px; font-weight: 400; }
.form-stack textarea { resize: vertical; }
.form-stack input:focus, .form-stack select:focus, .form-stack textarea:focus { border-color: #75ae8e; box-shadow: 0 0 0 3px #eaf5ee; }
.optional { color: #99a29c; font-weight: 400; }
.actions { display: flex; align-items: center; gap: 12px; white-space: nowrap; }
.actions form { margin: 0; }
.link-danger { padding: 0; border: 0; background: none; color: #c25f55; font-size: 12px; font-weight: 700; }
.empty-state { display: grid; justify-items: center; padding: 32px 12px; text-align: center; }
.empty-state > span { display: grid; width: 42px; height: 42px; place-items: center; margin-bottom: 12px; border-radius: 50%; background: var(--green-soft); color: var(--green); font-size: 20px; }
.empty-state strong { font-family: Manrope, sans-serif; }
.empty-state p { margin: 6px 0 15px; color: var(--muted); font-size: 12px; }
.notice { margin-bottom: 18px; padding: 12px 15px; border-radius: 8px; font-size: 12px; }
.notice-success { background: #eaf5ee; color: #286f50; }
.notice-error { background: #fff0ef; color: #a63f39; }
.login-page { display: grid; min-height: 100vh; place-items: center; padding: 24px; background: radial-gradient(ellipse at 70% 20%, #edf5ed, transparent 38%), var(--paper); }
.login-card { width: min(100%, 410px); padding: 38px; border: 1px solid var(--line); border-radius: 16px; background: white; box-shadow: 0 18px 55px #183d2810; }
.login-brand { margin-bottom: 37px; }
.login-card .eyebrow { margin-bottom: 8px; }
.login-card h1 { font-size: 24px; }
.login-card > .muted { margin: 8px 0 22px; }
.login-footnote { margin: 25px 0 0; color: #9aa39d; font-size: 10px; text-align: center; }

@media (max-width: 1000px) {
  .sidebar { width: 205px; }
  .main-content { margin-left: 205px; }
  .page-content { padding-right: 25px; padding-left: 25px; }
  .content-grid { grid-template-columns: 1fr; }
}
@media (max-width: 680px) {
  .sidebar { position: static; width: auto; height: auto; padding: 14px 17px; border-right: 0; border-bottom: 1px solid var(--line); }
  .sidebar .brand { font-size: 17px; }
  .sidebar .brand-mark { width: 34px; height: 34px; }
  .nav-label, .sidebar-bottom { display: none; }
  .main-nav { display: flex; gap: 5px; margin-top: 13px; overflow-x: auto; }
  .main-nav a { flex: 0 0 auto; gap: 7px; padding: 9px 10px; font-size: 12px; }
  .main-content { margin-left: 0; }
  .topbar { height: 48px; padding: 0 18px; }
  .page-content { padding: 25px 17px 40px; }
  .page-heading { margin-bottom: 18px; }
  h1 { font-size: 24px; }
  .welcome-banner { min-height: 250px; padding: 27px 22px; }
  .welcome-banner h2 { font-size: 27px; }
  .banner-art { inset: 50% 0 0 25%; opacity: .68; }
  .stats-grid { grid-template-columns: 1fr; gap: 10px; margin: 14px 0; }
  .stat-card { min-height: 119px; padding: 15px 17px; }
  .api-panel { grid-template-columns: 1fr; gap: 12px; padding: 18px; }
  .api-panel code, .api-panel .text-link { grid-column: 1; grid-row: auto; justify-self: start; max-width: 100%; overflow-wrap: anywhere; }
  .api-panel .text-link { text-align: left; }
  .panel { padding: 17px; }
  .section-heading { align-items: start; gap: 12px; }
  .login-card { padding: 27px 22px; }
}
