:root {
  --bg: #f6f7f2;
  --ink: #17201b;
  --muted: #66706b;
  --line: #dfe4dc;
  --panel: #ffffff;
  --accent: #0f766e;
  --accent-dark: #115e59;
  --warn: #b42318;
  --ok: #1f7a4d;
}
* { box-sizing: border-box; }
body { margin: 0; font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; background: var(--bg); color: var(--ink); }
a { color: inherit; text-decoration: none; }
.shell { width: min(1120px, calc(100% - 32px)); margin: 0 auto; }
.topbar { height: 72px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 800; }
.brand-mark { width: 34px; height: 34px; border-radius: 8px; display: grid; place-items: center; color: white; background: var(--ink); }
.nav { display: flex; align-items: center; gap: 16px; color: var(--muted); font-size: 14px; }
.nav form { margin: 0; }
main { padding: 34px 0 64px; }
.login-panel { min-height: calc(100vh - 170px); display: grid; grid-template-columns: 1.05fr 0.95fr; align-items: center; gap: 54px; }
h1 { font-size: clamp(36px, 7vw, 72px); line-height: .95; margin: 8px 0 18px; letter-spacing: 0; }
h2 { margin: 0 0 18px; font-size: 20px; }
.eyebrow { margin: 0; color: var(--accent-dark); font-weight: 800; text-transform: uppercase; font-size: 12px; letter-spacing: .12em; }
.muted { color: var(--muted); font-size: 18px; line-height: 1.55; max-width: 560px; }
.form, .panel { background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 24px; box-shadow: 0 18px 50px rgba(23, 32, 27, .08); }
.form { display: grid; gap: 16px; }
label { display: grid; gap: 8px; color: var(--muted); font-size: 13px; font-weight: 700; }
input { width: 100%; border: 1px solid var(--line); border-radius: 6px; padding: 12px 13px; font: inherit; color: var(--ink); background: #fbfcfa; }
input:focus { outline: 3px solid rgba(15,118,110,.18); border-color: var(--accent); }
button, .primary, .ghost { min-height: 40px; border-radius: 6px; padding: 0 14px; border: 0; cursor: pointer; font-weight: 800; font: inherit; }
.primary { color: white; background: var(--accent); }
.primary:hover { background: var(--accent-dark); }
.ghost { color: var(--ink); background: #eef2ec; }
.page-head { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 24px; }
.page-head h1 { font-size: clamp(34px, 5vw, 56px); margin-bottom: 0; }
.user-pill, .status { border: 1px solid var(--line); background: white; border-radius: 999px; padding: 8px 12px; color: var(--muted); font-size: 13px; font-weight: 800; }
.tool-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; }
.tool-card { display: grid; grid-template-columns: 54px 1fr auto; align-items: center; gap: 16px; min-height: 116px; background: white; border: 1px solid var(--line); border-radius: 8px; padding: 18px; transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease; }
.tool-card:hover { transform: translateY(-2px); border-color: rgba(15,118,110,.45); box-shadow: 0 16px 42px rgba(23, 32, 27, .1); }
.tool-icon { width: 54px; height: 54px; border-radius: 8px; display: grid; place-items: center; color: white; background: var(--accent); font-weight: 900; }
.tool-card strong, .tool-card small { display: block; }
.tool-card small { margin-top: 6px; color: var(--muted); line-height: 1.35; }
.arrow { color: var(--accent-dark); font-weight: 900; font-size: 13px; }
.admin-layout { display: grid; grid-template-columns: 360px 1fr; gap: 18px; align-items: start; }
.check { display: flex; align-items: center; gap: 10px; }
.check input { width: auto; }
.table { display: grid; gap: 10px; }
.row { display: grid; grid-template-columns: 1fr auto auto; align-items: center; gap: 12px; border-top: 1px solid var(--line); padding-top: 10px; }
.row:first-child { border-top: 0; padding-top: 0; }
.row small { display: block; color: var(--muted); margin-top: 4px; }
.status.active { color: var(--ok); }
.status.blocked { color: var(--warn); }
.messages { display: grid; gap: 10px; margin-top: 10px; }
.message { border-radius: 6px; padding: 12px 14px; background: white; border: 1px solid var(--line); }
.message.error { border-color: rgba(180,35,24,.35); color: var(--warn); }
.message.success { border-color: rgba(31,122,77,.35); color: var(--ok); }
@media (max-width: 760px) {
  .topbar, .page-head { align-items: flex-start; flex-direction: column; height: auto; padding-top: 18px; }
  .nav { width: 100%; flex-wrap: wrap; }
  .login-panel, .admin-layout { grid-template-columns: 1fr; gap: 22px; }
  .row { grid-template-columns: 1fr; }
  .tool-card { grid-template-columns: 46px 1fr; }
  .arrow { grid-column: 2; }
}
