/* sc — public SmartCity app website (PeruConecta, GTConecta …). --c / --cd / --ct come from the group colour. */
:root { --bg:#f4f6f9; --card:#fff; --ink:#14171f; --mut:#667085; --line:#e4e7ec; --warn:#d97706; --emer:#dc2626; --ok:#16a34a; --info:#2563eb; }
* { box-sizing:border-box; }
html, body { margin:0; background:var(--bg); color:var(--ink); font:15px/1.5 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; }
a { color:var(--c); text-decoration:none; }
button { font:inherit; cursor:pointer; }
[hidden] { display:none !important; }
.muted { color:var(--mut); }
.small { font-size:12.5px; }
.btn { display:inline-flex; align-items:center; justify-content:center; gap:8px; height:40px; padding:0 16px; border-radius:20px; border:0; background:var(--c); color:#fff; font-weight:600; white-space:nowrap; }
.btn.ghost { background:var(--ct); color:var(--cd); }

/* top bar */
.top { position:sticky; top:0; z-index:500; display:flex; align-items:center; justify-content:space-between; gap:12px; padding:10px max(16px, calc(50% - 560px)); background:rgba(255,255,255,.92); backdrop-filter:blur(10px); border-bottom:1px solid var(--line); }
.brand { display:flex; align-items:center; gap:10px; color:var(--ink); font-weight:700; font-size:17px; }
.brand img { width:32px; height:32px; border-radius:8px; }
.lang { border:1px solid var(--line); background:#fff; border-radius:16px; height:32px; padding:0 12px; font-weight:600; color:var(--mut); }

/* phone "open the app" bar */
.openbar { display:flex; align-items:center; gap:10px; padding:8px 16px; background:var(--ct); border-bottom:1px solid var(--line); }
.openbar img { width:36px; height:36px; border-radius:9px; }
.openbar div { flex:1; line-height:1.2; }
.openbar small { display:block; color:var(--mut); }
.openbar .btn { height:32px; padding:0 14px; }

/* home */
.hero { background:linear-gradient(150deg, var(--c), var(--cd)); color:#fff; padding:56px 16px 64px; text-align:center; }
.hero-in { max-width:640px; margin:0 auto; }
.hero-logo { width:96px; height:96px; border-radius:24px; box-shadow:0 14px 40px rgba(0,0,0,.25); background:#fff; }
.hero h1 { font-size:36px; margin:18px 0 6px; letter-spacing:-.5px; }
.lead { font-size:18px; opacity:.92; margin:0 0 24px; }
.stores { display:flex; flex-wrap:wrap; justify-content:center; gap:12px; }
.store { display:inline-flex; align-items:center; gap:10px; min-width:176px; height:52px; padding:0 16px; border-radius:12px; background:#0b0c0f; color:#fff; font-weight:600; font-size:17px; line-height:1.1; text-align:left; }
.store small { display:block; font-size:10.5px; font-weight:500; opacity:.85; }
.store .tag { margin-left:auto; font-size:10px; font-weight:700; background:#fff3; padding:2px 6px; border-radius:6px; }
.beta { font-size:13px; opacity:.85; margin:14px 0 0; }
.feats { max-width:1120px; margin:-32px auto 0; padding:0 16px; display:grid; grid-template-columns:repeat(4, 1fr); gap:12px; position:relative; }
.feat { background:var(--card); border-radius:16px; padding:18px; box-shadow:0 6px 24px rgba(16,24,40,.08); }
.feat i { font-style:normal; font-size:22px; display:block; }
.feat b { display:block; margin:6px 0 4px; }
.feat span { color:var(--mut); font-size:13.5px; }
.find { max-width:1120px; margin:32px auto; padding:0 16px; }
.find h2 { margin:0 0 12px; }
input[type=search] { width:100%; height:46px; border-radius:23px; border:1px solid var(--line); padding:0 18px; font:inherit; background:#fff; outline:none; }
input[type=search]:focus { border-color:var(--c); box-shadow:0 0 0 3px var(--ct); }
.chips { display:flex; gap:8px; overflow-x:auto; padding:12px 0 4px; scrollbar-width:none; }
.chips::-webkit-scrollbar { display:none; }
.chip { flex:0 0 auto; height:34px; padding:0 14px; border-radius:17px; border:1px solid var(--line); background:#fff; color:var(--ink); font-size:13.5px; }
.chip.on { background:var(--c); border-color:var(--c); color:#fff; }
.chip em { font-style:normal; opacity:.65; margin-left:4px; }
.chips.small .chip { height:30px; font-size:12.5px; padding:0 11px; }
.grid { display:grid; grid-template-columns:repeat(auto-fill, minmax(250px, 1fr)); gap:10px; margin:8px 0 16px; }
.mcard { display:flex; align-items:center; gap:12px; background:var(--card); border:1px solid var(--line); border-radius:14px; padding:12px; color:var(--ink); }
.mcard:hover { border-color:var(--c); }
.mcard img { width:44px; height:44px; border-radius:10px; object-fit:cover; background:var(--ct); flex:0 0 auto; }
.mcard b { display:block; font-size:14.5px; line-height:1.25; }
.mcard span { color:var(--mut); font-size:12.5px; }
#more { display:block; margin:0 auto; }

/* municipality */
#muni { max-width:1120px; margin:0 auto; padding:16px; }
.back { display:inline-block; margin:4px 0 12px; font-weight:600; }
.mhead { display:flex; align-items:center; gap:14px; margin-bottom:16px; }
.mhead img { width:64px; height:64px; border-radius:16px; object-fit:cover; background:var(--ct); }
.mhead h1 { margin:0; font-size:26px; line-height:1.2; }
.mhead p { margin:2px 0 0; }
.mhead .btn { margin-left:auto; }
.mgrid { display:grid; grid-template-columns:minmax(0, 1.6fr) minmax(0, 1fr); gap:16px; align-items:start; }
.mcol { display:flex; flex-direction:column; gap:16px; min-width:0; }
.map { height:360px; border-radius:16px; overflow:hidden; border:1px solid var(--line); background:#e8ecf1; z-index:1; }
.card { background:var(--card); border:1px solid var(--line); border-radius:16px; padding:16px; }
.card h2 { font-size:17px; margin:0 0 10px; }
.facts { display:grid; grid-template-columns:1fr 1fr; gap:10px; }
.fact b { display:block; font-size:18px; }
.fact span { color:var(--mut); font-size:12.5px; }
.emer { display:flex; flex-wrap:wrap; gap:8px; margin-top:12px; }
.emer a { display:inline-flex; align-items:center; gap:6px; height:32px; padding:0 12px; border-radius:16px; background:#fef2f2; color:var(--emer); font-weight:700; font-size:13px; }
.alert { display:flex; gap:10px; padding:10px 0; border-top:1px solid var(--line); }
.alert:first-child { border-top:0; padding-top:0; }
.alert .dot { width:10px; height:10px; border-radius:5px; margin-top:6px; flex:0 0 auto; background:var(--info); }
.alert b { display:block; }
.alert p { margin:2px 0; color:#344054; white-space:pre-line; }
.alert small { color:var(--mut); }
.st-emergency { background:var(--emer) !important; } .st-warning { background:var(--warn) !important; } .st-resolved { background:var(--ok) !important; } .st-notice { background:var(--c) !important; }
.post { padding:14px 0; border-top:1px solid var(--line); }
.post:first-child { border-top:0; padding-top:0; }
.post .ph { display:flex; align-items:center; gap:10px; }
.post .ph img { width:36px; height:36px; border-radius:9px; object-fit:cover; }
.post .ph small { display:block; color:var(--mut); }
.post p { margin:8px 0 0; white-space:pre-line; }
.post .media { display:grid; grid-template-columns:repeat(auto-fill, minmax(140px, 1fr)); gap:6px; margin-top:10px; }
.post .media img { width:100%; aspect-ratio:4/3; object-fit:cover; border-radius:10px; }
.person { display:flex; align-items:center; gap:10px; padding:8px 0; border-top:1px solid var(--line); }
.person:first-child { border-top:0; }
.av { width:36px; height:36px; border-radius:18px; display:flex; align-items:center; justify-content:center; color:#fff; font-weight:700; font-size:13px; flex:0 0 auto; }
.person b { display:block; font-size:14px; line-height:1.25; }
.person span { color:var(--mut); font-size:12.5px; }
.person .role { color:var(--c); font-weight:600; }
.inst { padding:10px 0; border-top:1px solid var(--line); }
.inst:first-of-type { border-top:0; }
.inst b { display:block; font-size:14px; line-height:1.3; }
.inst .addr { color:var(--mut); font-size:12.5px; }
.inst .acts { display:flex; flex-wrap:wrap; gap:6px; margin-top:6px; }
.inst .acts a { display:inline-flex; align-items:center; height:28px; padding:0 10px; border-radius:14px; background:var(--ct); color:var(--cd); font-size:12.5px; font-weight:600; }
.inst .acts a.em { background:#fef2f2; color:var(--emer); }
.inst .kind { display:inline-block; font-size:11px; font-weight:700; text-transform:uppercase; letter-spacing:.3px; color:var(--mut); margin-bottom:2px; }
#insts { max-height:620px; overflow:auto; margin-top:6px; }
.foot { max-width:1120px; margin:24px auto 32px; padding:0 16px; display:flex; justify-content:space-between; gap:12px; flex-wrap:wrap; font-size:13px; }
.leaflet-popup-content { font:13px/1.4 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif; }

@media (max-width: 900px) {
	.feats { grid-template-columns:1fr 1fr; }
	.mgrid { grid-template-columns:1fr; }
}
@media (max-width: 560px) {
	.hero { padding:36px 16px 56px; }
	.hero h1 { font-size:28px; }
	.lead { font-size:16px; }
	.feats { grid-template-columns:1fr; }
	.mhead { flex-wrap:wrap; }
	.mhead .btn { margin-left:0; width:100%; }
	.map { height:280px; }
	.store { min-width:0; flex:1 1 150px; }
}
