:root {
    --green: #166534;
    --green-dark: #0f3f24;
    --orange: #f97316;
    --text: #18221b;
    --muted: #647067;
    --line: #e7ece8;
    --bg: #f8faf7;
    --white: #ffffff;
    --danger: #b91c1c;
    --warning: #92400e;
    --shadow: 0 18px 40px rgba(15, 63, 36, 0.08);
    --radius: 18px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
    font-family: Arial, Helvetica, sans-serif;
    color: var(--text);
    background: var(--bg);
    line-height: 1.55;
}
a { color: var(--green); text-decoration: none; }
a:hover { text-decoration: underline; }

.container {
    width: min(1120px, calc(100% - 32px));
    margin: 0 auto;
}

.site-header {
    background: rgba(255,255,255,0.92);
    border-bottom: 1px solid var(--line);
    position: sticky;
    top: 0;
    z-index: 20;
    backdrop-filter: blur(12px);
}
.nav-wrap {
    height: 72px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.brand {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--text);
}
.brand:hover { text-decoration: none; }
.brand-mark {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--green), var(--orange));
    color: white;
    font-weight: 800;
}
.brand small {
    display: block;
    color: var(--muted);
    margin-top: -3px;
}
.main-nav {
    display: flex;
    gap: 18px;
    align-items: center;
}
.nav-toggle {
    display: none;
    border: 0;
    background: var(--green);
    color: white;
    border-radius: 10px;
    padding: 9px 12px;
    font-size: 20px;
}

.hero {
    padding: 76px 0 54px;
    background:
        radial-gradient(circle at top right, rgba(249,115,22,.15), transparent 30%),
        radial-gradient(circle at top left, rgba(22,101,52,.12), transparent 32%);
}
.hero-grid {
    display: grid;
    grid-template-columns: 1.15fr .85fr;
    gap: 42px;
    align-items: center;
}
.eyebrow {
    display: inline-flex;
    padding: 8px 12px;
    border: 1px solid rgba(22,101,52,.18);
    border-radius: 99px;
    background: #fff;
    color: var(--green);
    font-weight: 700;
    font-size: 14px;
}
h1 {
    font-size: clamp(36px, 5vw, 62px);
    line-height: 1.04;
    margin: 18px 0;
    letter-spacing: -1.6px;
}
h2 { font-size: 30px; margin: 0 0 16px; letter-spacing: -.5px; }
h3 { margin-top: 0; }
.lead {
    font-size: 19px;
    color: var(--muted);
    max-width: 680px;
}
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.btn, button.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 13px 18px;
    border-radius: 12px;
    background: var(--green);
    color: #fff;
    border: 0;
    font-weight: 700;
    cursor: pointer;
    text-decoration: none;
}
.btn:hover { background: var(--green-dark); text-decoration: none; }
.btn.secondary {
    background: #fff;
    color: var(--green);
    border: 1px solid rgba(22,101,52,.18);
}
.btn.orange { background: var(--orange); }
.btn.small { padding: 9px 12px; font-size: 14px; }
.btn.danger { background: var(--danger); }

.card {
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 22px;
    box-shadow: var(--shadow);
}
.card.soft { box-shadow: none; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.section { padding: 54px 0; }
.muted { color: var(--muted); }
.badge {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 5px 10px;
    background: #edf7f0;
    color: var(--green);
    font-size: 12px;
    font-weight: 700;
}
.badge.orange { background: #fff2e9; color: #9a3412; }
.badge.gray { background: #f1f5f9; color: #475569; }

.form-card {
    max-width: 840px;
    margin: 42px auto;
}
.form-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}
.form-row { margin-bottom: 16px; }
label {
    display: block;
    font-size: 14px;
    font-weight: 700;
    margin-bottom: 7px;
}
input, select, textarea {
    width: 100%;
    border: 1px solid #d9e2dc;
    border-radius: 12px;
    padding: 12px 13px;
    font: inherit;
    background: #fff;
}
textarea { min-height: 120px; resize: vertical; }
.help { font-size: 13px; color: var(--muted); margin-top: 6px; }
.alert {
    margin-top: 18px;
    padding: 14px 16px;
    border-radius: 12px;
    border: 1px solid;
}
.alert.success { background: #ecfdf5; border-color: #bbf7d0; color: #166534; }
.alert.error { background: #fef2f2; border-color: #fecaca; color: #991b1b; }

.dashboard {
    padding: 34px 0 60px;
}
.dash-grid {
    display: grid;
    grid-template-columns: 250px 1fr;
    gap: 22px;
    align-items: start;
}
.sidebar {
    position: sticky;
    top: 92px;
}
.sidebar a {
    display: block;
    padding: 11px 12px;
    border-radius: 11px;
    color: var(--text);
    margin-bottom: 5px;
}
.sidebar a:hover, .sidebar a.active {
    background: #edf7f0;
    text-decoration: none;
    color: var(--green);
}
.stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
}
.stat {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 17px;
}
.stat strong {
    display: block;
    font-size: 28px;
}
.table-wrap {
    overflow-x: auto;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: #fff;
}
table {
    width: 100%;
    border-collapse: collapse;
    min-width: 780px;
}
th, td {
    padding: 12px 14px;
    border-bottom: 1px solid var(--line);
    text-align: left;
    vertical-align: top;
}
th { background: #f8faf7; font-size: 13px; color: var(--muted); }
tr:last-child td { border-bottom: 0; }
.inline-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}
.inline-actions form { display: inline; }

.post-item {
    padding: 18px;
    border-bottom: 1px solid var(--line);
}
.post-item:last-child { border-bottom: 0; }
.post-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: var(--muted);
    font-size: 13px;
}
.comment {
    border-left: 3px solid #d9e2dc;
    padding: 10px 0 10px 14px;
    margin: 14px 0;
}
.site-footer {
    background: #102a1b;
    color: #dbe8df;
    padding: 32px 0;
    margin-top: 40px;
}
.footer-grid {
    display: flex;
    justify-content: space-between;
    gap: 20px;
}
.site-footer p { margin: 4px 0; color: #b9c9be; }

@media (max-width: 860px) {
    .nav-toggle { display: block; }
    .main-nav {
        display: none;
        position: absolute;
        top: 72px;
        left: 16px;
        right: 16px;
        background: white;
        border: 1px solid var(--line);
        border-radius: 16px;
        box-shadow: var(--shadow);
        padding: 16px;
        flex-direction: column;
        align-items: flex-start;
    }
    body.nav-open .main-nav { display: flex; }
    .hero-grid, .grid-2, .grid-3, .dash-grid, .form-grid {
        grid-template-columns: 1fr;
    }
    .stats { grid-template-columns: repeat(2, 1fr); }
    .sidebar { position: static; }
    .footer-grid { flex-direction: column; }
}
@media (max-width: 520px) {
    .container { width: min(100% - 22px, 1120px); }
    .hero { padding: 44px 0 34px; }
    h1 { font-size: 34px; }
    .lead { font-size: 17px; }
    .stats { grid-template-columns: 1fr; }
    .card { padding: 18px; }
}
