@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

:root{
  --bg:#f0f2f5;
  --card:#ffffff;
  --text:#0f172a;
  --muted:#6b7280;
  --primary:#1877f2;
  --border:#e5e7eb;
  --shadow:0 1px 2px rgba(0,0,0,.08);
  --radius:16px;
  --topbar:64px;
  --bottomnav:70px;
}

*{box-sizing:border-box}
html,body{height:100%}
body{
  font-family:'Inter',system-ui,-apple-system,Segoe UI,Roboto,Helvetica,Arial,sans-serif;
  background:var(--bg);
  color:var(--text);
}
a{color:var(--primary);text-decoration:none}
a:hover{text-decoration:underline}

.app-container{max-width:980px}

.app-topbar{
  position:fixed;
  top:0;left:0;right:0;
  height:var(--topbar);
  display:flex;
  align-items:center;
  background:var(--card);
  border-bottom:1px solid var(--border);
  z-index:1030;
}
.app-brand{display:flex;align-items:center;gap:10px}

.app-search{
  flex:1;
  max-width:520px;
  position:relative;
}
.app-search i{
  position:absolute;
  top:50%;
  left:12px;
  transform:translateY(-50%);
  color:var(--muted);
  pointer-events:none;
}
.app-search input{
  width:100%;
  border:1px solid var(--border);
  background:#f8fafc;
  border-radius:999px;
  padding:10px 12px 10px 36px;
  outline:none;
}
.app-search input:focus{border-color:rgba(24,119,242,.5);box-shadow:0 0 0 4px rgba(24,119,242,.12);background:#fff}

.app-avatar img{
  width:36px;height:36px;
  border-radius:999px;
  object-fit:cover;
  border:1px solid var(--border);
}

.app-main{
  padding-top:calc(var(--topbar) + 14px);
  padding-bottom:calc(var(--bottomnav) + 20px);
}

.app-alert{border-radius:12px;box-shadow:var(--shadow)}

.card-surface{
  background:var(--card);
  border:1px solid var(--border);
  border-radius:var(--radius);
  box-shadow:var(--shadow);
}

.post-card{overflow:hidden}
.post-header{padding:14px 14px 0 14px}
.post-meta{display:flex;align-items:center;gap:10px}
.post-meta .avatar{
  width:40px;height:40px;border-radius:999px;object-fit:cover;border:1px solid var(--border)
}
.post-meta .who{line-height:1.2}
.post-meta .who .name{font-weight:700;color:var(--text)}
.post-meta .who .sub{font-size:.85rem;color:var(--muted)}
.post-badge{
  font-size:.75rem;
  padding:6px 10px;
  border-radius:999px;
  font-weight:600;
}
.badge-lost{background:#fee2e2;color:#991b1b}
.badge-found{background:#dcfce7;color:#166534}
.badge-adopt{background:#dbeafe;color:#1d4ed8}

.post-title{padding:10px 14px 0 14px;font-weight:700;font-size:1.05rem;color:var(--text)}
.post-body{padding:8px 14px 12px 14px;color:#334155;font-size:.95rem}
.post-image{width:100%;height:260px;object-fit:cover;background:#e2e8f0}
@media(min-width:768px){.post-image{height:340px}}

.post-actions{
  display:flex;
  justify-content:space-between;
  gap:8px;
  padding:12px 14px;
  border-top:1px solid var(--border);
}
.post-actions a,.post-actions button{
  flex:1;
  border:none;
  background:#f8fafc;
  border-radius:12px;
  padding:10px 12px;
  font-weight:600;
  color:#111827;
}
.post-actions a:hover,.post-actions button:hover{background:#eef2ff;text-decoration:none}

.app-bottomnav{
  position:fixed;
  bottom:0;left:0;right:0;
  height:var(--bottomnav);
  background:var(--card);
  border-top:1px solid var(--border);
  display:grid;
  grid-template-columns:repeat(5,1fr);
  align-items:center;
  z-index:1030;
}
.app-bottomnav a{
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:4px;
  color:#334155;
  font-size:.75rem;
  text-decoration:none;
}
.app-bottomnav a i{font-size:1.1rem}
.app-bottomnav a.is-active{color:var(--primary)}
.app-bottomnav .app-add{
  width:54px;height:54px;
  margin:0 auto;
  border-radius:999px;
  background:var(--primary);
  color:#fff;
  transform:translateY(-18px);
  display:flex;
  align-items:center;
  justify-content:center;
  box-shadow:0 10px 25px rgba(24,119,242,.25);
}
.app-bottomnav .app-add span{display:none}
.app-bottomnav .app-add i{font-size:1.2rem}

.section-title{font-weight:800;color:#111827;font-size:1.2rem;margin:8px 0 12px 0}

.profile-cover{
  background:linear-gradient(135deg, rgba(24,119,242,.18), rgba(78,205,196,.18));
  border:1px solid var(--border);
  border-radius:var(--radius);
  padding:18px;
}
.profile-head{display:flex;gap:14px;align-items:center}
.profile-head .avatar{width:72px;height:72px;border-radius:999px;object-fit:cover;border:2px solid #fff;box-shadow:var(--shadow)}
.profile-head .u{flex:1}
.profile-head .u .name{font-weight:800;font-size:1.15rem}
.profile-stats{display:flex;gap:12px;margin-top:10px;color:var(--muted);font-size:.9rem}

.cookie-banner{position:fixed;left:0;right:0;bottom:calc(var(--bottomnav) + 10px);padding:12px;z-index:1040}
.cookie-banner__inner{
  max-width:980px;
  margin:0 auto;
  background:var(--card);
  border:1px solid var(--border);
  border-radius:16px;
  box-shadow:var(--shadow);
  padding:12px 12px;
  display:flex;
  gap:12px;
  align-items:center;
  justify-content:space-between;
}
.cookie-banner__inner a{color:var(--primary);font-weight:600}

.app-footer a{color:var(--muted)}

/* pequeños detalles */
.btn-primary{background:var(--primary);border-color:var(--primary)}
.btn-primary:hover{background:#1464cf;border-color:#1464cf}

.feed-tabs{
  display:flex;
  gap:8px;
  margin:8px 0 14px 0;
}
.feed-tabs a{
  flex:1;
  text-align:center;
  padding:10px 12px;
  border-radius:999px;
  background:#ffffffb3;
  border:1px solid var(--border);
  color:#111827;
  font-weight:700;
}
.feed-tabs a.is-active{background:var(--primary);border-color:var(--primary);color:#fff;text-decoration:none}
