Spaces:
Sleeping
Sleeping
| /* AgroSense modern dashboard — responsive, dark agriculture theme. */ | |
| :root { | |
| --bg: #0c1411; --panel: #12211b; --panel-2: #16291f; --border: #224436; | |
| --text: #e8f3ec; --muted: #9fb8ac; --accent: #36c98a; --accent-2: #2a9d6e; | |
| --warn: #ffcf5c; --danger: #ff7a7a; --ok: #7ce0a3; --info: #6cc6ff; | |
| --chip: #1d3a2c; --radius: 14px; --shadow: 0 6px 22px rgba(0,0,0,.35); | |
| } | |
| * { box-sizing: border-box; } | |
| html, body { margin: 0; padding: 0; } | |
| body { | |
| font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; | |
| background: radial-gradient(1200px 600px at 80% -10%, #16352700, var(--bg)) , var(--bg); | |
| color: var(--text); font-size: 15.5px; line-height: 1.5; | |
| } | |
| a { color: var(--accent); } | |
| h1,h2,h3 { margin: 0 0 .4rem; } | |
| .muted { color: var(--muted); } | |
| .small { font-size: .85rem; } | |
| /* Header */ | |
| header.topbar { | |
| position: sticky; top: 0; z-index: 50; | |
| background: linear-gradient(180deg, #103024, #0c1411); | |
| border-bottom: 1px solid var(--border); padding: 8px 16px; | |
| } | |
| .datebar { display: flex; gap: 16px; flex-wrap: wrap; justify-content: space-between; | |
| font-size: .9rem; color: #d7efe1; } | |
| .brand { display: flex; align-items: center; gap: 10px; } | |
| .brand .logo { font-size: 1.5rem; } | |
| .brand h1 { font-size: 1.25rem; } | |
| /* Tickers */ | |
| .ticker-wrap { width: 100%; overflow: hidden; background: #0e241b; | |
| border-radius: 10px; margin-top: 6px; padding: 6px 0; border: 1px solid var(--border); } | |
| .ticker { display: inline-block; white-space: nowrap; padding-left: 100%; | |
| animation: ticker 160s linear infinite; } | |
| .ticker.cmd { animation: ticker 110s linear infinite; } | |
| .ticker:hover { animation-play-state: paused; } | |
| .ticker a { color: #d6ffe7; text-decoration: none; margin: 0 .2rem; } | |
| .ticker .up { color: var(--ok); } .ticker .down { color: var(--danger); } | |
| @keyframes ticker { from { transform: translateX(0); } to { transform: translateX(-100%); } } | |
| /* Layout */ | |
| .container { max-width: 1180px; margin: 0 auto; padding: 14px; } | |
| .controls { display: grid; grid-template-columns: repeat(auto-fit,minmax(150px,1fr)); | |
| gap: 10px; background: var(--panel); border: 1px solid var(--border); | |
| border-radius: var(--radius); padding: 12px; margin-bottom: 12px; } | |
| label.field { display: flex; flex-direction: column; gap: 4px; font-size: .82rem; color: var(--muted); } | |
| input, select, textarea, button { font: inherit; } | |
| input, select, textarea { | |
| background: #0e1d16; color: var(--text); border: 1px solid var(--border); | |
| border-radius: 9px; padding: 8px 10px; width: 100%; } | |
| textarea { resize: vertical; min-height: 64px; } | |
| button { cursor: pointer; border: none; border-radius: 9px; padding: 9px 14px; | |
| background: var(--accent); color: #062313; font-weight: 600; } | |
| button:hover { background: var(--accent-2); } | |
| button.ghost { background: var(--chip); color: var(--text); border: 1px solid var(--border); } | |
| button:disabled { opacity: .5; cursor: not-allowed; } | |
| /* Tabs */ | |
| .tabs { display: flex; gap: 8px; flex-wrap: wrap; margin: 6px 0 14px; } | |
| .tab { background: var(--chip); color: var(--text); border: 1px solid var(--border); | |
| border-radius: 999px; padding: 8px 14px; font-size: .9rem; } | |
| .tab.active { background: var(--accent); color: #062313; border-color: var(--accent); } | |
| .panel { display: none; } .panel.active { display: block; } | |
| /* Cards */ | |
| .grid { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit,minmax(280px,1fr)); } | |
| .card { background: var(--panel); border: 1px solid var(--border); | |
| border-radius: var(--radius); padding: 14px; box-shadow: var(--shadow); } | |
| .card h3 { display: flex; align-items: center; gap: 8px; } | |
| .kv { display: flex; justify-content: space-between; gap: 10px; padding: 3px 0; | |
| border-bottom: 1px dashed #1e3a2c; } | |
| .kv .v { font-weight: 600; } | |
| .metrics { display: grid; grid-template-columns: repeat(auto-fit,minmax(90px,1fr)); gap: 8px; } | |
| .metric { background: var(--panel-2); border-radius: 10px; padding: 8px; text-align: center; } | |
| .metric .n { font-size: 1.15rem; font-weight: 700; } .metric .l { font-size: .72rem; color: var(--muted); } | |
| .badge { display: inline-block; padding: 2px 9px; border-radius: 999px; font-size: .78rem; font-weight: 600; } | |
| .badge.high { background: #4a1d1d; color: var(--danger); } | |
| .badge.medium { background: #4a3a18; color: var(--warn); } | |
| .badge.low { background: #16351f; color: var(--ok); } | |
| .alert { border-radius: 10px; padding: 9px 12px; margin: 6px 0; font-size: .92rem; } | |
| .alert.warn { background: #3a2f12; border: 1px solid #5a4a1c; } | |
| .alert.danger { background: #3a1717; border: 1px solid #5a2222; } | |
| .alert.ok { background: #143020; border: 1px solid #1e4a30; } | |
| .alert.info { background: #122a3a; border: 1px solid #1c4258; } | |
| .answer { background: var(--panel-2); border-radius: 10px; padding: 12px; white-space: normal; } | |
| .answer strong { color: #d7ffe9; } | |
| .cite { font-size: .82rem; color: var(--muted); } | |
| img.sat { width: 100%; border-radius: 10px; border: 1px solid var(--border); } | |
| table.tbl { width: 100%; border-collapse: collapse; font-size: .88rem; } | |
| table.tbl th, table.tbl td { text-align: left; padding: 6px 8px; border-bottom: 1px solid var(--border); } | |
| .spinner { width: 18px; height: 18px; border: 3px solid var(--border); | |
| border-top-color: var(--accent); border-radius: 50%; animation: spin .8s linear infinite; | |
| display: inline-block; vertical-align: middle; } | |
| @keyframes spin { to { transform: rotate(360deg); } } | |
| .row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; } | |
| .chat { background: var(--panel-2); border-radius: 10px; padding: 10px; max-height: 320px; overflow-y: auto; } | |
| .msg { padding: 5px 0; border-bottom: 1px dashed #1e3a2c; } | |
| .toggle { display: flex; gap: 6px; align-items: center; font-size: .85rem; color: var(--muted); } | |
| .disclaimer { font-size: .8rem; color: var(--muted); border-left: 3px solid var(--accent-2); | |
| padding-left: 10px; margin-top: 8px; } | |
| /* Docs dropdown menu */ | |
| .dropdown { position: relative; } | |
| .dd-toggle { background: var(--chip); color: var(--text); border: 1px solid var(--border); | |
| border-radius: 9px; padding: 7px 13px; cursor: pointer; font-size: .85rem; font-weight: 600; } | |
| .dd-toggle:hover { border-color: var(--accent); } | |
| .dd-menu { position: absolute; right: 0; top: calc(100% + 6px); min-width: 250px; | |
| background: var(--panel); border: 1px solid var(--border); border-radius: 12px; | |
| box-shadow: var(--shadow); padding: 7px; z-index: 200; display: none; } | |
| .dd-menu.open { display: block; } | |
| .dd-head { font-size: .72rem; text-transform: uppercase; letter-spacing: .08em; | |
| color: var(--muted); padding: 6px 10px 3px; } | |
| .dd-item { display: flex; align-items: center; gap: 10px; padding: 7px 10px; | |
| border-radius: 8px; font-size: .88rem; white-space: nowrap; } | |
| .dd-item:hover { background: var(--panel-2); } | |
| .dd-item span { flex: 1; color: var(--text); } | |
| .dd-item a { color: var(--accent); font-weight: 700; font-size: .82rem; } | |
| .dd-item a:hover { text-decoration: underline; } | |
| .dd-sep { height: 1px; background: var(--border); margin: 6px 4px; } | |
| /* Speaking advisor avatar (AgroBot) */ | |
| .advisor-head { display: flex; align-items: center; gap: 14px; margin: 6px 0 12px; } | |
| .advisor-meta { font-size: .9rem; } | |
| .avatar { position: relative; width: 78px; height: 78px; flex: 0 0 auto; } | |
| .avatar svg { width: 100%; height: 100%; display: block; animation: agroBob 3.4s ease-in-out infinite; } | |
| .avatar .face { filter: drop-shadow(0 6px 14px rgba(0,0,0,.45)); } | |
| .avatar .leaf { fill: #7ce0a3; } | |
| .avatar .eye { fill: #06251a; transform-box: fill-box; transform-origin: center; animation: agroBlink 5s infinite; } | |
| .avatar .mouth { fill: #06251a; transform-box: fill-box; transform-origin: center; } | |
| .avatar .ring { position: absolute; inset: -5px; border-radius: 50%; border: 2px solid var(--accent); opacity: 0; pointer-events: none; } | |
| .avatar.talking .mouth { animation: agroTalk .26s ease-in-out infinite; } | |
| .avatar.talking .ring { animation: agroPulse 1s ease-out infinite; } | |
| .avatar.talking svg { animation: agroBob 1.1s ease-in-out infinite; } | |
| @keyframes agroBob { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-3px); } } | |
| @keyframes agroBlink { 0%,92%,100% { transform: scaleY(1); } 96% { transform: scaleY(.1); } } | |
| @keyframes agroTalk { 0%,100% { transform: scaleY(.4); } 50% { transform: scaleY(1.6); } } | |
| @keyframes agroPulse { 0% { opacity: .6; transform: scale(1); } 100% { opacity: 0; transform: scale(1.45); } } | |