:root {
    --bg: #f3f7f6;
    --surface: #ffffff;
    --primary: #157f6b;
    --primary-dark: #0f5d50;
    --secondary: #f0a202;
    --text: #16302b;
    --muted: #68837e;
    --border: #d9e7e3;
    --success: #1e9c5d;
    --danger: #cc4b4b;
    --warning: #e6a23c;
    --info: #2e82d1;
    --shadow: 0 18px 45px rgba(18, 61, 57, 0.08);
    --radius: 22px;
}

* { box-sizing: border-box; }
body {
    margin: 0;
    min-height: 100vh;
    font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
    color: var(--text);
    background:
        radial-gradient(circle at top left, rgba(240, 162, 2, 0.14), transparent 28%),
        linear-gradient(180deg, #f8fbfa 0%, #eef5f3 100%);
}
a { color: inherit; text-decoration: none; }
.site-shell {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}
.topbar {
    position: sticky;
    top: 0;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem 2rem;
    backdrop-filter: blur(18px);
    background: rgba(248, 251, 250, 0.88);
    border-bottom: 1px solid rgba(21, 127, 107, 0.1);
}
.brand { display: inline-flex; align-items: center; gap: 0.9rem; }
.brand small { display: block; color: var(--muted); }
.brand-mark {
    width: 48px;
    height: 48px;
    display: inline-grid;
    place-items: center;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: 16px;
    color: white;
    font-weight: 700;
    box-shadow: var(--shadow);
}
.topnav { display: flex; align-items: center; flex-wrap: wrap; gap: 0.75rem; }
.container {
    flex: 1 0 auto;
    width: min(1160px, calc(100% - 2rem));
    margin: 2rem auto;
}
.hero, .card, .stat-card, .auth-card, .table-card {
    background: var(--surface);
    border: 1px solid rgba(21, 127, 107, 0.08);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}
.hero {
    display: grid;
    grid-template-columns: 1.4fr 1fr;
    gap: 2rem;
    padding: 2rem;
}
.hero-panel {
    background: linear-gradient(145deg, rgba(21, 127, 107, 0.1), rgba(240, 162, 2, 0.12));
    border-radius: 20px;
    padding: 1.5rem;
}
.hero h1, .section-title { margin-top: 0; }
.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    border: none;
    border-radius: 999px;
    padding: 0.85rem 1.3rem;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: #fff;
    font-weight: 600;
    cursor: pointer;
}
.button-ghost { background: rgba(21, 127, 107, 0.08); color: var(--primary-dark); }
.grid { display: grid; gap: 1.2rem; }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.stat-card, .card, .table-card, .auth-card { padding: 1.4rem; }
.stat-card .number { font-size: 2rem; font-weight: 700; margin-bottom: 0.35rem; }
.muted { color: var(--muted); }
.alert { padding: 1rem 1.2rem; border-radius: 18px; margin-bottom: 1rem; }
.alert-success { background: rgba(30, 156, 93, 0.12); color: #13653c; }
.alert-danger { background: rgba(204, 75, 75, 0.12); color: #932929; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.field { display: flex; flex-direction: column; gap: 0.45rem; }
.field.full { grid-column: 1 / -1; }
.span-full { grid-column: 1 / -1; }
label { font-weight: 600; }
input, select, textarea {
    width: 100%;
    padding: 0.9rem 1rem;
    border-radius: 16px;
    border: 1px solid var(--border);
    background: #fbfdfd;
    color: var(--text);
}
textarea { min-height: 120px; resize: vertical; }
table { width: 100%; border-collapse: collapse; }
th, td {
    text-align: left;
    padding: 1rem 0.8rem;
    border-bottom: 1px solid #edf3f1;
    vertical-align: top;
}
th { color: var(--muted); font-size: 0.86rem; text-transform: uppercase; letter-spacing: 0.04em; }
.badge {
    display: inline-flex;
    align-items: center;
    padding: 0.4rem 0.8rem;
    border-radius: 999px;
    font-size: 0.85rem;
    font-weight: 700;
}
.badge-success { background: rgba(30, 156, 93, 0.14); color: var(--success); }
.badge-info { background: rgba(46, 130, 209, 0.14); color: var(--info); }
.badge-warning { background: rgba(230, 162, 60, 0.18); color: #996400; }
.badge-danger { background: rgba(204, 75, 75, 0.14); color: var(--danger); }
.badge-muted { background: rgba(104, 131, 126, 0.14); color: var(--muted); }
.timeline { display: grid; gap: 1rem; }
.timeline-item { position: relative; padding-left: 1.2rem; border-left: 2px solid rgba(21, 127, 107, 0.18); }
.timeline-item::before {
    content: "";
    position: absolute;
    left: -7px;
    top: 0.3rem;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--primary);
}
.auth-wrap { min-height: calc(100vh - 100px); display: grid; place-items: center; }
.auth-card { width: min(540px, 100%); }
.table-responsive { overflow-x: auto; }
.actions { display: flex; flex-wrap: wrap; gap: 0.7rem; }
@media (max-width: 900px) {
    .hero, .grid-3, .grid-2, .form-grid { grid-template-columns: 1fr; }
    .topbar { padding: 1rem; }
}

.site-footer {
    flex-shrink: 0;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.25rem 1rem 2rem;
    text-align: center;
    color: var(--muted);
}

.site-footer p {
    margin: 0;
    width: 100%;
    font-size: 0.95rem;
}

.hero-banner-wrap { margin-top: 1.25rem; }
.hero-banner { display: block; width: 100%; max-width: 100%; border-radius: 22px; border: 1px solid rgba(21, 127, 107, 0.12); box-shadow: var(--shadow); object-fit: cover; }
