* { margin:0; padding:0; box-sizing:border-box; }
body {
  font-family:'Inter',-apple-system,BlinkMacSystemFont,'Segoe UI',Roboto,sans-serif;
  background:#fff; color:#1a1a1a; line-height:1.6; padding-top:130px;
}
a { color:#0a84ff; text-decoration:none; }
a:hover { text-decoration:underline; }
code { background:#f1f3f5; padding:1px 6px; border-radius:5px; font-size:.9em; }

.header {
  position:fixed; top:0; left:0; right:0; z-index:1000;
  background:rgba(255,255,255,.96); backdrop-filter:blur(10px);
  border-bottom:1px solid #eee; padding:1rem 0;
}
.header-content {
  max-width:1100px; margin:0 auto; padding:0 1.5rem;
  display:flex; align-items:center; gap:1.5rem;
}
.brand { display:flex; flex-direction:column; align-items:flex-start; }
.brand .logo { font-size:1.6rem; font-weight:800; letter-spacing:-.5px; }
.brand .logo .blue { color:#0a84ff; }
.brand .slogan { font-size:.78rem; color:#888; }
.search-wrap { flex:1; position:relative; }
.search-bar { display:flex; gap:.5rem; }
.search-bar input {
  flex:1; padding:.85rem 1rem; font-size:1rem; border:1px solid #ddd;
  border-radius:10px; outline:none; transition:border .15s;
}
.search-bar input:focus { border-color:#0a84ff; }
.search-bar button {
  background:#000; color:#fff; border:0; border-radius:10px;
  padding:0 1.6rem; font-weight:600; cursor:pointer; font-size:.95rem;
}
.search-bar button:hover { background:#0a84ff; }
.home-btn {
  background:#f1f3f5; border:0; border-radius:10px; padding:0 .9rem;
  font-size:1.1rem; cursor:pointer; text-decoration:none; display:flex; align-items:center;
}

/* dropdown autocomplete */
.ac {
  position:absolute; left:0; right:0; top:calc(100% + 6px);
  background:#fff; border:1px solid #e5e5e5; border-radius:12px;
  box-shadow:0 12px 32px rgba(0,0,0,.12); max-height:380px; overflow:auto; display:none; z-index:1100;
}
.ac.show { display:block; }
.ac-item { padding:.6rem .9rem; cursor:pointer; border-bottom:1px solid #f4f4f4; display:flex; gap:.75rem; align-items:baseline; }
.ac-item:last-child { border-bottom:0; }
.ac-item:hover, .ac-item.active { background:#f6f9ff; }
.ac-item .c { font-weight:700; color:#000; min-width:90px; }
.ac-item .d { color:#555; font-size:.9rem; flex:1; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.ac-item .m { font-size:.72rem; color:#0a84ff; background:#eef5ff; padding:1px 7px; border-radius:20px; }

.container { max-width:1100px; margin:0 auto; padding:1.5rem; }

/* home */
.hero { text-align:center; padding:2rem 0 2.5rem; }
.hero h1 { font-size:2rem; font-weight:800; margin-bottom:.4rem; }
.hero p { color:#777; }
.modgrid { display:grid; grid-template-columns:repeat(auto-fill,minmax(260px,1fr)); gap:1rem; }
.modcard {
  border:1px solid #eee; border-radius:14px; padding:1.1rem 1.2rem; transition:.15s;
  display:block; color:inherit;
}
.modcard:hover { border-color:#0a84ff; box-shadow:0 6px 20px rgba(10,132,255,.08); text-decoration:none; transform:translateY(-2px); }
.modcard .mc { font-size:.72rem; color:#0a84ff; font-weight:700; }
.modcard h3 { font-size:1rem; margin:.2rem 0; }
.modcard .n { color:#999; font-size:.85rem; }

/* ficha */
.card { border:1px solid #eee; border-radius:16px; padding:1.8rem; }
.card-head { display:flex; align-items:center; justify-content:space-between; flex-wrap:wrap; gap:1rem; border-bottom:1px solid #f0f0f0; padding-bottom:1rem; margin-bottom:1.2rem; }
.card-head h1 { font-size:2rem; }
.badge { background:#000; color:#fff; padding:.4rem .9rem; border-radius:8px; font-size:.8rem; font-weight:600; }
.sec { margin:1.3rem 0; }
.sec h3 { font-size:.82rem; text-transform:uppercase; letter-spacing:.5px; color:#999; margin-bottom:.5rem; }
.sec p { color:#333; }
.explain { background:#f8fafc; border-left:3px solid #0a84ff; padding:1rem 1.2rem; border-radius:8px; }
.rel-list { display:flex; flex-direction:column; gap:.5rem; }
.rel-item { display:flex; align-items:baseline; gap:.8rem; padding:.55rem .8rem; border:1px solid #f0f0f0; border-radius:10px; }
.rel-item:hover { border-color:#0a84ff; }
.rel-item .c { font-weight:700; min-width:110px; }
.rel-item .a { font-size:.72rem; background:#eef5ff; color:#0a84ff; padding:1px 8px; border-radius:20px; }
.rel-item .d { color:#666; font-size:.9rem; }
.chips { display:flex; flex-wrap:wrap; gap:.4rem; }
.chip { background:#f1f3f5; padding:.35rem .8rem; border-radius:20px; font-size:.85rem; color:#333; }
.note { font-size:.8rem; color:#aaa; margin-top:.3rem; }

.crumbs { font-size:.85rem; color:#999; margin-bottom:1rem; }
.footer { text-align:center; color:#bbb; font-size:.85rem; padding:2.5rem 0 1.5rem; }
.empty { text-align:center; padding:3rem 1rem; color:#888; }
@media(max-width:680px){
  body{padding-top:150px;}
  .header-content{flex-wrap:wrap;}
  .search-wrap{order:3; flex-basis:100%;}
}
