@font-face {
  font-family: "Vazirmatn";
  src: url("/static/fonts/Vazirmatn-Regular.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}

:root {
  --bg: #f4efe6;
  --paper: #fffdf8;
  --ink: #2c241c;
  --muted: #6f6256;
  --line: #e6d9c8;
  --saffron: #b86a1a;
  --green: #1d6b48;
  --green-d: #145238;
  --red: #8d2d2d;
  --shadow: 0 10px 30px rgba(70, 44, 16, 0.06);
}

* { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "Vazirmatn", Tahoma, sans-serif;
  line-height: 1.7;
}
a { color: var(--green-d); }
h1, h2 { line-height: 1.4; }
.layout { display: flex; min-height: 100vh; }
aside {
  width: 230px;
  background: #24352c;
  color: #f6f1e7;
  padding: 24px 18px;
}
aside a, aside button.link {
  display: block;
  color: #f6f1e7;
  text-decoration: none;
  background: none;
  border: 0;
  padding: 8px 0;
  font: inherit;
  cursor: pointer;
  text-align: right;
}
.brand { font-weight: 700; margin-top: 0; }
main { flex: 1; padding: 28px 32px 64px; }
.solo { max-width: 420px; margin: 10vh auto; padding: 16px; }
.card, table {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: var(--shadow);
}
.card { padding: 18px 20px; margin: 16px 0; }
.narrow { padding: 28px; }
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; }
.stat { font-size: 1.8rem; margin: 8px 0; color: var(--green); }
.muted { color: var(--muted); }
label { display: block; margin: 12px 0; }
input, textarea, select, button {
  font: inherit;
}
input, textarea, select {
  width: 100%;
  margin-top: 4px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
}
button, .button {
  background: var(--green);
  color: white;
  border: 0;
  border-radius: 10px;
  padding: 8px 14px;
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
}
button.secondary, .button.secondary { background: #8a5a2b; }
button.danger { background: var(--red); }
button.link { width: auto; padding: 8px 0; }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 12px; }
.row-actions, .inline-form, .day-links { display: flex; flex-wrap: wrap; gap: 8px; align-items: end; }
.inline-form label { margin: 0; }
.day-links a { padding: 4px 8px; border-radius: 8px; background: white; text-decoration: none; }
.day-links a.active { background: var(--green); color: white; }
table { width: 100%; border-collapse: collapse; overflow: hidden; }
th, td { border-bottom: 1px solid var(--line); padding: 8px 10px; vertical-align: top; text-align: right; }
th { background: #f7f1e6; }
.flash { padding: 10px 12px; border-radius: 10px; }
.flash.ok { background: #e5f4ec; }
.flash.err { background: #fde8e4; }
.badge { background: var(--saffron); color: white; border-radius: 999px; padding: 0 8px; }
img.dish, img.receipt { max-width: min(420px, 100%); border-radius: 12px; }
.check { display: flex; gap: 8px; align-items: center; }
.check input, .file input { width: auto; }
.file { color: var(--muted); }
.nowrap form { display: inline; }
.print-page { padding: 24px; background: white; }
@media print {
  .noprint, aside, .row-actions { display: none !important; }
  body, .print-page { background: white; }
  table { box-shadow: none; }
}
@media (max-width: 800px) {
  .layout { flex-direction: column; }
  aside { width: auto; }
  main { padding: 16px; }
}
