*{box-sizing:border-box}
body{margin:0;font-family:system-ui,-apple-system,Segoe UI,Roboto,Ubuntu,Helvetica,Arial,sans-serif;background:#f6f7f9;color:#111}
a{color:inherit;text-decoration:none}
.hidden{display:none!important}

.topbar{position:sticky;top:0;z-index:10;background:#fff;border-bottom:1px solid #e5e7eb;padding:.75rem 1rem;display:flex;align-items:center;justify-content:space-between}
.topbar h1{margin:0;font-size:1.1rem}
.tabs{display:flex;gap:.5rem;flex-wrap:wrap}
.tab{border:1px solid #e5e7eb;background:#f2f4f7;padding:.35rem .7rem;border-radius:999px;font-size:.85rem}
.tab.active{background:#2563eb;color:#fff;border-color:#2563eb}

.btn{border:1px solid #1f2937;background:#1f2937;color:#fff;border-radius:12px;padding:.45rem .8rem;font-weight:600;cursor:pointer}
.btn-emerald{background:#059669;border-color:#059669}
.btn-gray{background:#e5e7eb;color:#111;border-color:#e5e7eb}
.btn-sm{padding:.3rem .5rem;font-size:.85rem}

.container{max-width:1000px;margin:1rem auto 5rem;padding:0 1rem}
.card{background:#fff;border:1px solid #e5e7eb;border-radius:16px;padding:1rem;margin-bottom:1rem;box-shadow:0 1px 2px rgba(0,0,0,.04)}
.list-card{background:#f9fafb;border:1px solid #e5e7eb;border-radius:16px;margin-top:1rem}
.list-head{padding:.6rem .8rem;border-bottom:1px solid #e5e7eb;background:#fff;border-top-left-radius:16px;border-top-right-radius:16px}
.pad{padding:.8rem}
.search{padding:.55rem .7rem;border-radius:12px;border:1px solid #e5e7eb;min-width:250px}

.field{display:flex;flex-direction:column;gap:.3rem;position:relative} /* relative para dropdown absoluto */
.field input{padding:.55rem .7rem;border-radius:12px;border:1px solid #e5e7eb;background:#fff}
.grid2{display:grid;grid-template-columns:1fr 1fr;gap:.8rem}
.grid5{display:grid;grid-template-columns:2fr 1fr 2fr .8fr .8fr;gap:.8rem}
.grid5 .span2{grid-column:span 2}

.row{display:flex;align-items:center;gap:.6rem}
.row.between{justify-content:space-between}
.right{text-align:right}
.muted{color:#6b7280}

.dropdown{position:absolute;left:0;right:0;top:100%;background:#fff;border:1px solid #e5e7eb;border-radius:12px;margin-top:.2rem;max-height:14rem;overflow:auto;display:none;z-index:20;box-shadow:0 8px 16px rgba(2,6,23,.06)}
.dropdown.show{display:block}
.dropdown .dd-item{display:block;width:100%;text-align:left;padding:.55rem .7rem;border:0;background:#fff;border-bottom:1px solid #f1f5f9;cursor:pointer}
.dropdown .dd-item:last-child{border-bottom:0}
.dropdown .dd-item:hover{background:#f8fafc}

.table-wrap{max-height:18rem;overflow:auto;background:#fff;border-bottom-left-radius:16px;border-bottom-right-radius:16px}
.table{width:100%;border-collapse:collapse;font-size:.9rem}
.table th,.table td{padding:.5rem .6rem;border-bottom:1px solid #f1f5f9}
.table th{position:sticky;top:0;background:#f8fafc}

.footer{position:fixed;left:0;right:0;bottom:0;border-top:1px solid #e5e7eb;background:#fff;padding:.6rem 1rem;display:flex;align-items:center;justify-content:space-between}

.page{display:none}.page.show{display:block}
.bullets{padding-left:1.1rem}

.tag{display:inline-block;background:#e0f2fe;color:#0369a1;border:1px solid #bae6fd;border-radius:999px;padding:.2rem .55rem;font-size:.85rem;margin-right:.5rem}

@media (max-width:820px){
  .grid2{grid-template-columns:1fr}
  .grid5{grid-template-columns:1fr 1fr}
  .grid5 .span2{grid-column:span 2}
}
