:root {
  --bg:#f3eadf;
  --paper:rgba(255,251,246,0.93);
  --paper-strong:#fff8ef;
  --ink:#1f2a24;
  --muted:#566358;
  --brand:#255c4b;
  --brand-strong:#174033;
  --accent:#c56444;
  --success:#287457;
  --warning:#8b5e00;
  --danger:#9c3a31;
  --line:rgba(31,42,36,0.1);
  --shadow:0 30px 70px rgba(31,42,36,0.13);
}

* { box-sizing:border-box; }
body {
  margin:0;
  min-height:100vh;
  font-family:"Manrope",sans-serif;
  color:var(--ink);
  background:radial-gradient(circle at top left, rgba(197,100,68,0.18), transparent 30%), radial-gradient(circle at top right, rgba(37,92,75,0.16), transparent 26%), linear-gradient(180deg, #f8f0e7 0%, #f3eadf 46%, #ede0d3 100%);
}

a { color:inherit; }
h1,h2,h3 { font-family:"Fraunces",serif; margin:0; line-height:1.05; }

.shell {
  width:min(1280px, calc(100% - 28px));
  margin:0 auto;
  padding:28px 0 56px;
}

.hero {
  display:grid;
  grid-template-columns:1.2fr 0.9fr;
  gap:22px;
  margin-bottom:22px;
}

.card {
  background:var(--paper);
  border:1px solid rgba(255,255,255,0.8);
  box-shadow:var(--shadow);
  backdrop-filter:blur(20px);
  border-radius:26px;
  padding:24px;
}

.hero-card {
  position:relative;
  overflow:hidden;
}

.hero-card::after {
  content:"";
  position:absolute;
  width:220px;
  height:220px;
  right:-40px;
  bottom:-60px;
  border-radius:999px;
  background:radial-gradient(circle, rgba(197,100,68,0.22), transparent 70%);
}

.eyebrow {
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:8px 12px;
  border-radius:999px;
  background:rgba(37,92,75,0.1);
  color:var(--brand-strong);
  font-size:12px;
  text-transform:uppercase;
  letter-spacing:0.08em;
  font-weight:700;
}

.hero-card h1 {
  font-size:clamp(2.4rem, 5vw, 4.8rem);
  margin-top:18px;
  max-width:9ch;
}

.hero-card p {
  color:var(--muted);
  line-height:1.7;
  max-width:62ch;
}

.chip-row {
  display:flex;
  flex-wrap:wrap;
  gap:10px;
  margin-top:18px;
}

.chip {
  padding:10px 14px;
  border-radius:999px;
  background:rgba(255,255,255,0.72);
  border:1px solid var(--line);
  font-size:13px;
}

.login-card {
  background:linear-gradient(180deg, rgba(37,92,75,0.95), rgba(23,64,51,0.96));
  color:#f7f2ea;
}

.login-card p,
.login-card label,
.login-card .small {
  color:rgba(247,242,234,0.82);
}

.login-card .field label {
  color:rgba(247,242,234,0.86);
}

.topbar {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  margin-bottom:22px;
}

.topbar .title { font-size:1.5rem; font-weight:700; }
.topbar .meta { color:var(--muted); font-size:14px; }

.feature-grid {
  display:grid;
  grid-template-columns:repeat(4, minmax(0,1fr));
  gap:18px;
  margin-bottom:22px;
}

.feature-card {
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  text-align:center;
  gap:10px;
  padding:22px 16px;
  border-radius:22px;
  background:var(--paper-strong);
  box-shadow:0 18px 40px rgba(31,42,36,0.08);
  border:1px solid rgba(255,255,255,0.8);
  cursor:pointer;
  transition:transform 160ms ease, box-shadow 160ms ease;
}

.feature-card:hover {
  transform:translateY(-2px);
  box-shadow:0 20px 42px rgba(31,42,36,0.12);
}

.feature-card.is-active {
  border-color:rgba(37,92,75,0.35);
  background:rgba(37,92,75,0.06);
}

.feature-icon { font-size:2.2rem; }
.feature-name { font-weight:700; }

.view-panel {
  background:var(--paper);
  border:1px solid rgba(255,255,255,0.8);
  box-shadow:var(--shadow);
  border-radius:26px;
  padding:24px;
}

.view-head {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  margin-bottom:18px;
}

.view-head p { margin:8px 0 0; color:var(--muted); }

.search-row {
  display:flex;
  flex-wrap:wrap;
  gap:12px;
  margin-bottom:16px;
}

.search-input { flex:1; min-width:220px; }

.table-wrap {
  overflow:auto;
  border-radius:18px;
  border:1px solid var(--line);
}

table {
  width:100%;
  border-collapse:collapse;
  min-width:760px;
  background:rgba(255,255,255,0.75);
}

th,td {
  padding:14px 16px;
  border-bottom:1px solid rgba(31,42,36,0.08);
  text-align:left;
  font-size:14px;
}

th {
  font-size:12px;
  text-transform:uppercase;
  letter-spacing:0.08em;
  color:var(--muted);
  background:rgba(255,248,239,0.92);
}

.badge {
  display:inline-flex;
  align-items:center;
  border-radius:999px;
  padding:7px 10px;
  font-size:12px;
  font-weight:700;
}

.badge.active { background:rgba(40,116,87,0.12); color:var(--success); }
.badge.inactive { background:rgba(139,94,0,0.12); color:var(--warning); }
.badge.archived { background:rgba(156,58,49,0.12); color:var(--danger); }

.pagination {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  margin-top:16px;
}

.mini-stat { display:flex; gap:14px; flex-wrap:wrap; }
.mini-stat .pill {
  padding:8px 12px;
  border-radius:999px;
  background:rgba(37,92,75,0.06);
  color:var(--brand-strong);
  font-weight:700;
}

.placeholder {
  display:flex;
  align-items:center;
  justify-content:center;
  min-height:240px;
  border:1px dashed rgba(31,42,36,0.2);
  border-radius:20px;
  background:rgba(255,255,255,0.6);
  color:var(--muted);
}

.field-grid {
  display:grid;
  grid-template-columns:repeat(2, minmax(0, 1fr));
  gap:14px;
}

.field {
  display:flex;
  flex-direction:column;
  gap:8px;
}

.field label {
  font-size:13px;
  font-weight:700;
  color:var(--muted);
}

.full { grid-column:1 / -1; }

.input,
.select,
.textarea {
  width:100%;
  border-radius:14px;
  border:1px solid rgba(31,42,36,0.12);
  padding:12px 14px;
  font:inherit;
  background:rgba(255,255,255,0.9);
  color:var(--ink);
  outline:none;
}

.textarea { min-height:120px; resize:vertical; }

.input:focus,
.select:focus,
.textarea:focus {
  box-shadow:0 0 0 4px rgba(37,92,75,0.13);
  border-color:rgba(37,92,75,0.35);
}

.button {
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:108px;
  border:0;
  border-radius:14px;
  padding:12px 16px;
  font:inherit;
  font-weight:700;
  cursor:pointer;
  line-height:1;
  white-space:nowrap;
  vertical-align:middle;
  text-decoration:none;
}

.button-primary { background:linear-gradient(135deg, var(--brand), var(--brand-strong)); color:white; }
.button-secondary { background:rgba(37,92,75,0.08); color:var(--brand-strong); }
.button-danger { background:rgba(156,58,49,0.12); color:var(--danger); }
.button-warm { background:var(--accent); color:white; }
.button:disabled { opacity:0.65; cursor:default; }

.toolbar {
  display:flex;
  flex-wrap:wrap;
  gap:10px;
}

.stack {
  display:flex;
  flex-direction:column;
  gap:14px;
}

.notice {
  border-radius:14px;
  padding:14px 16px;
  font-size:14px;
  line-height:1.55;
  margin-top:16px;
}

.notice.info { background:rgba(37,92,75,0.08); color:var(--brand-strong); }
.notice.error { background:rgba(156,58,49,0.1); color:var(--danger); }
.notice.success { background:rgba(40,116,87,0.12); color:var(--success); }

.demo-credentials {
  background:rgba(255,255,255,0.08);
  border:1px solid rgba(255,255,255,0.12);
  border-radius:16px;
  padding:14px;
}

.table-actions {
  display:flex;
  align-items:center;
  justify-content:flex-end;
  gap:8px;
  flex-wrap:nowrap;
  width:100%;
}

.actions-cell {
  width:190px;
  min-width:190px;
  padding-right:12px;
}

.hidden { display:none !important; }

@media (max-width:1080px) {
  .hero { grid-template-columns:1fr; }
  .feature-grid { grid-template-columns:repeat(2, minmax(0,1fr)); }
}

@media (max-width:720px) {
  .shell { width:min(100% - 20px, 1280px); padding-top:20px; }
  .hero-card h1 { font-size:2.5rem; }
  .card { padding:18px; }
  .feature-grid { grid-template-columns:1fr; }
  .topbar { flex-direction:column; align-items:flex-start; }
  .view-head { flex-direction:column; align-items:flex-start; }
  .field-grid { grid-template-columns:1fr; }
}
