* { box-sizing: border-box; }
body { margin: 0; font-family: -apple-system, "Segoe UI", Arial, sans-serif; color: #1f2a1f; background: #f6f8f3; }
header { background: #2e7d32; color: white; padding: 18px 24px; }
header h1 { margin: 0 0 6px; font-size: 24px; }
header p { margin: 4px 0; }
header .muted { color: #dcedc8; }
nav { display: flex; flex-wrap: wrap; gap: 4px; padding: 10px 24px; background: white; border-bottom: 1px solid #ddd; position: sticky; top: 0; z-index: 5; }
nav button { background: #eef3ea; color: #1f2a1f; }
nav button.active { background: #2e7d32; color: white; }
main { padding: 16px 24px 40px; max-width: 1200px; }
footer { padding: 16px 24px; color: #777; font-size: 13px; }
h2 { color: #2e7d32; }
button { border: 0; border-radius: 6px; padding: 8px 14px; background: #2e7d32; color: white; cursor: pointer; font-size: 14px; margin: 4px 2px; }
button:disabled { opacity: .5; cursor: wait; }
button.big { font-size: 17px; padding: 12px 22px; background: #f57c00; }
input, select, textarea { padding: 7px; border: 1px solid #ccc; border-radius: 6px; font-size: 14px; font-family: inherit; }
textarea { width: 100%; }
input.small { width: 60px; }
.muted { color: #777; font-size: 13px; }
.tag { display: inline-block; padding: 2px 8px; border-radius: 10px; font-size: 12px; font-weight: 600; margin: 0 3px; white-space: nowrap; color: white; }
.tag.sim { background: #ef6c00; } .tag.pub { background: #1565c0; } .tag.ai { background: #6a1b9a; }
.tag.calc { background: #546e7a; } .tag.obs { background: #2e7d32; } .tag.fc { background: #c62828; } .tag.warn { background: #9e9e9e; }
.legend .tag { margin-bottom: 3px; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 800px) { .grid2 { grid-template-columns: 1fr; } }
.card { background: white; border-radius: 10px; padding: 14px 18px; box-shadow: 0 1px 3px rgba(0,0,0,.08); margin: 8px 0; }
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 14px; }
.card h3 { margin-top: 4px; }
.scroll { overflow-x: auto; }
table { border-collapse: collapse; width: 100%; background: white; font-size: 13px; margin: 8px 0; }
th, td { border: 1px solid #e0e0e0; padding: 6px 8px; text-align: left; vertical-align: top; }
th { background: #eef3ea; }
table.inputs { width: auto; } table.inputs input { width: 90px; }
.bar { display: grid; grid-template-columns: 170px 1fr 90px; align-items: center; gap: 8px; margin: 4px 0; font-size: 14px; }
.track { background: #eee; border-radius: 4px; height: 16px; }
.track i { display: block; height: 100%; background: #66bb6a; border-radius: 4px; }
.form { display: flex; flex-wrap: wrap; gap: 12px; margin: 10px 0; }
.form label { display: flex; flex-direction: column; font-size: 13px; gap: 4px; }
pre { white-space: pre-wrap; background: #fafafa; border: 1px solid #eee; padding: 10px; border-radius: 6px; font-size: 13px; }
pre.out { min-height: 60px; background: white; }
.chat { background: white; border-radius: 10px; padding: 12px; height: 320px; overflow-y: auto; border: 1px solid #ddd; }
.msg { margin: 6px 0; padding: 8px 12px; border-radius: 10px; max-width: 80%; }
.msg.user { background: #e8f5e9; margin-left: auto; }
.msg.bot { background: #f3e5f5; }
.chatbar { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: 8px; }
.chatbar #chatIn { flex: 1; min-width: 220px; }
.ok { color: #2e7d32; font-weight: bold; } .bad { color: #c62828; font-weight: bold; }
.big-num { font-size: 22px; font-weight: bold; color: #2e7d32; }
img.thumb { max-width: 90px; max-height: 70px; }
[dir=rtl] { text-align: right; }
header .tag.obs { background: white; color: #2e7d32; }
