/* Layout de "sistema" da página pública — sobrepõe o styles.css base */
body.app { background: #f7f2f1; }
.wrap { width: min(980px, 100% - 32px); margin-inline: auto; }

/* barra superior */
.topbar { position: sticky; top: 0; z-index: 50; background: var(--red-3); color: #fff; box-shadow: 0 2px 12px -4px rgba(74,3,9,.5); }
.topbar .wrap { display: flex; align-items: center; gap: 18px; height: 58px; }
.topbar .brand { font-size: 19px; }
.topbar .brand .dot { width: 30px; height: 30px; }
.topbar .brand .dot::after { display: none; }
.tabbar { display: flex; gap: 4px; margin-left: auto; height: 100%; }
.tabbar a {
  display: flex; align-items: center; gap: 7px; padding: 0 14px; text-decoration: none; font-weight: 700; font-size: 14px;
  color: rgba(255,255,255,.72); border-bottom: 3px solid transparent; transition: color .15s, border-color .15s;
}
.tabbar a:hover { color: #fff; }
.tabbar a.active { color: #fff; border-bottom-color: var(--star); }
.tabbar .ti svg { width: 18px; height: 18px; display: block; }
.tabbar .n { background: rgba(255,255,255,.18); border-radius: 999px; font-size: 11px; padding: 1px 7px; }
.tabbar .n:empty { display: none; }
.tabbar a.active .n { background: var(--star); color: var(--red-4); }

/* views */
.views { padding: 22px 0 60px; }
.view-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.view-head h1 { font-size: 24px; font-weight: 800; letter-spacing: -.4px; }
.view-sub { color: var(--muted); margin: -6px 0 16px; font-size: 14.5px; }
.seg { display: inline-flex; background: #eadede; border-radius: 10px; padding: 3px; }
.seg button { padding: 7px 14px; border-radius: 8px; font-weight: 700; font-size: 13px; color: var(--muted); }
.seg button.active { background: #fff; color: var(--red-2); box-shadow: 0 1px 3px rgba(0,0,0,.12); }

.filters { display: flex; gap: 8px; margin-bottom: 14px; }
.filters .search { height: 42px; border-radius: 10px; flex: 1; min-width: 0; padding: 0 14px; }
.filters .select { height: 42px; border-radius: 10px; padding: 0 32px 0 12px; font-size: 14px; background-position: right 12px center; }

/* linhas de evento */
.rows { display: grid; gap: 10px; }
.row {
  display: grid; grid-template-columns: 64px 1fr auto; gap: 14px; align-items: center;
  background: #fff; border: 1px solid #eddcdc; border-radius: 14px; padding: 12px 14px 12px 12px; cursor: pointer;
  transition: border-color .15s, box-shadow .15s; animation: rise .35s both;
}
.row:hover { border-color: #e2a9a9; box-shadow: 0 6px 18px -10px rgba(122,7,16,.4); }
.row.past { opacity: .62; }
.row .dt { background: var(--red); color: #fff; border-radius: 12px; text-align: center; padding: 8px 4px 6px; line-height: 1; }
.row .dt b { display: block; font-family: var(--font-display); font-weight: 400; font-size: 28px; }
.row .dt span { font-size: 11px; font-weight: 800; letter-spacing: 1px; text-transform: uppercase; opacity: .9; }
.row .dt small { display: block; font-size: 10px; font-weight: 600; margin-top: 3px; opacity: .8; text-transform: lowercase; }
.row.past .dt { background: #8e7a7b; }
.row .info-c { min-width: 0; display: grid; gap: 4px; }
.row h3 { font-size: 16px; font-weight: 800; line-height: 1.25; letter-spacing: -.2px; }
.row .pill { display: inline-block; font-size: 10.5px; font-weight: 800; text-transform: uppercase; letter-spacing: .6px; color: var(--red-2); background: #fde8e8; padding: 2px 7px; border-radius: 6px; margin-right: 6px; vertical-align: 2px; }
.row .pill.live { background: var(--red); color: #fff; }
.row .ln { display: flex; gap: 14px; flex-wrap: wrap; font-size: 13px; color: var(--muted); }
.row .ln span { display: inline-flex; gap: 5px; align-items: center; min-width: 0; }
.row .ln svg { width: 14px; height: 14px; color: var(--red); flex: none; }
.row .ln .addr { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 420px; }
.row .ln b { color: var(--ink); }
.row .side { display: flex; align-items: center; gap: 10px; }
.row .thumb-s { width: 58px; height: 58px; border-radius: 10px; object-fit: cover; }
.row .go { white-space: nowrap; }

.empty { padding: 44px 20px; background: #fff; }

/* composer & ideias mais compactos */
.composer { border-radius: 14px; padding: 14px; margin-bottom: 14px; box-shadow: none; border: 1px solid #eddcdc; }
.composer textarea { font-size: 15.5px; min-height: 44px; padding-top: 6px; }
.composer .avatar { width: 38px; height: 38px; }
.idea-list { grid-template-columns: 1fr; gap: 10px; }
.idea { border-radius: 14px; padding: 16px; box-shadow: none; border: 1px solid #eddcdc; }
.idea.hot::before { top: 12px; right: 14px; }
.idea-text { font-size: 15px; margin-bottom: 12px; }
.idea-actions { padding-top: 10px; }
.react { padding: 6px 12px; font-size: 13px; }

/* sugestão */
.suggest-card { border-radius: 14px; box-shadow: none; border: 1px solid #eddcdc; padding: 20px; }
.sf-row .sf.grow2 { flex: 2; }
.sug-imgs { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.sug-drop { width: 74px; height: 74px; display: grid; place-items: center; padding: 0; font-weight: 700; font-size: 13px; }
.sf-actions { display: flex; align-items: center; justify-content: flex-end; gap: 14px; }

/* modal mais enxuto */
.modal-box { border-radius: 18px; }
.gallery-main { aspect-ratio: 16/8; }
.modal-content h2 { font-family: var(--font); font-weight: 800; text-transform: none; font-size: clamp(22px, 3.4vw, 30px); line-height: 1.15; letter-spacing: -.5px; margin: 6px 0 16px; }
.info-grid { gap: 8px; margin-bottom: 16px; }
.info { padding: 10px 12px; border-radius: 12px; }
.info .ic { width: 34px; height: 34px; border-radius: 10px; }
.info .ic svg { width: 17px; }
.info b { font-size: 14px; }
.map-embed { height: 220px; }
.btn { padding: 11px 18px; font-size: 14px; }
.btn-sm { padding: 7px 13px; font-size: 13px; }

/* celular: abas viram barra inferior estilo app */
@media (max-width: 760px) {
  .topbar .wrap { height: 54px; }
  .tabbar {
    position: fixed; left: 0; right: 0; bottom: 0; height: calc(62px + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom);
    background: #fff; border-top: 1px solid #eddcdc; box-shadow: 0 -4px 16px -8px rgba(0,0,0,.2); margin: 0; gap: 0; z-index: 60;
  }
  .tabbar a { flex: 1; flex-direction: column; justify-content: center; gap: 3px; padding: 0; font-size: 11.5px; color: var(--muted); border-bottom: 0; border-top: 3px solid transparent; position: relative; }
  .tabbar a.active { color: var(--red); border-top-color: var(--red); border-bottom: 0; }
  .tabbar .ti svg { width: 22px; height: 22px; }
  .tabbar .n { position: absolute; top: 6px; left: calc(50% + 8px); background: var(--red); color: #fff; }
  .tabbar a.active .n { background: var(--red); color: #fff; }
  .me-chip { margin-left: auto; }
  .views { padding-bottom: 100px; }
  .row { grid-template-columns: 54px 1fr; gap: 12px; }
  .row .dt b { font-size: 24px; }
  .row .side { grid-column: 1 / -1; justify-content: flex-end; }
  .row .thumb-s { display: none; }
  .row .ln .addr { max-width: 100%; white-space: normal; }
  .filters { flex-wrap: wrap; }
  .filters .search { flex-basis: 100%; }
  .filters .select { flex: 1; }
  .sf-row { flex-wrap: wrap; }
  .sf-row .sf { flex: 1 1 130px; }
  .sf-actions { flex-direction: column-reverse; align-items: stretch; }
  .toast { bottom: 84px; }
}

/* grupos */
.groups { display: grid; gap: 10px; }
.group {
  display: flex; align-items: center; gap: 14px; background: #fff; border: 1px solid #eddcdc; border-radius: 14px;
  padding: 14px; text-decoration: none; transition: border-color .15s, box-shadow .15s; animation: rise .35s both;
}
.group:hover { border-color: #e2a9a9; box-shadow: 0 6px 18px -10px rgba(122,7,16,.4); }
.g-ic { width: 46px; height: 46px; border-radius: 12px; background: #25d366; color: #fff; display: grid; place-items: center; flex: none; }
.g-ic svg { width: 24px; height: 24px; }
.g-info { flex: 1; min-width: 0; display: grid; gap: 2px; }
.g-info b { font-size: 16px; }
.g-info small { color: var(--muted); font-size: 13px; }
.g-info .g-note { color: var(--ink); font-weight: 700; }
@media (max-width: 520px) {
  .group { flex-wrap: wrap; }
  .group .btn { width: 100%; }
}

/* ideia que virou evento */
.became {
  display: flex; gap: 10px; align-items: center; text-decoration: none; margin: -2px 0 12px;
  background: #fff8e1; border: 1px solid #f5d77a; color: #6b4e00; border-radius: 10px; padding: 9px 12px; font-size: 13.5px;
}
.became svg { width: 18px; height: 18px; flex: none; color: #b07d00; }
.became b { color: #4a3600; }
.became:hover { border-color: #e2b93b; }
.idea.has-event { border-color: #f5d77a; }

/* sugestão de evento no mural */
.sug-card { background: #fff6f6; border: 1px solid #f3cccc; border-radius: 12px; padding: 12px 14px; margin-bottom: 10px; display: grid; gap: 6px; }
.sug-tag { display: inline-flex; gap: 6px; align-items: center; font-size: 11px; font-weight: 800; letter-spacing: .6px; text-transform: uppercase; color: var(--red-2); }
.sug-tag svg { width: 14px; height: 14px; }
.sug-card h4 { font-size: 16.5px; line-height: 1.25; }
.sug-card .ln { display: flex; gap: 6px 14px; flex-wrap: wrap; font-size: 13px; color: var(--muted); }
.sug-card .ln > * { display: inline-flex; gap: 5px; align-items: center; }
.sug-card .ln svg { width: 14px; height: 14px; color: var(--red); flex: none; }
.sug-card .ln a { color: var(--red-2); font-weight: 700; }
.idea-imgs { display: flex; gap: 6px; margin-bottom: 12px; flex-wrap: wrap; }
.idea-imgs img { width: 92px; height: 92px; object-fit: cover; border-radius: 10px; }

/* ===== formulário Sugerir no celular ===== */
@media (max-width: 760px) {
  .suggest-card { padding: 16px 14px; gap: 14px; }
  .suggest-card .sf-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
  .suggest-card .sf-row .sf { min-width: 0; }
  .suggest-card .sf.grow2, .suggest-card .sf.full { grid-column: 1 / -1; }
  .suggest-card .sf.uf { flex: none; }
  .suggest-card .sf > span { font-size: 11px; letter-spacing: .4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .suggest-card .sf input, .suggest-card .sf select, .suggest-card .sf textarea {
    font-size: 16px; /* evita zoom automático no iPhone */
    min-width: 0; max-width: 100%; height: 46px; padding: 10px 12px;
  }
  .suggest-card .sf textarea { height: auto; min-height: 96px; }
  .suggest-card .sf input[type=date], .suggest-card .sf input[type=time] { -webkit-appearance: none; appearance: none; display: block; width: 100%; text-align: left; }
  .suggest-card .sf-actions .btn { width: 100%; }
  .sf-note { text-align: center; }
}

/* cabeçalho de dia na agenda */
.day-head { display: flex; align-items: baseline; gap: 10px; margin: 14px 2px 2px; flex-wrap: wrap; }
.day-head:first-child { margin-top: 0; }
.day-head b { font-size: 15px; font-weight: 800; letter-spacing: -.2px; }
.day-head span { font-size: 13px; color: var(--muted); }
.day-head em { font-style: normal; font-size: 11.5px; font-weight: 700; color: var(--red-2); background: #fde8e8; padding: 1px 8px; border-radius: 999px; margin-left: auto; }
.day-head.today b { color: var(--red); }
.day-head.today b::before { content: '●'; margin-right: 6px; animation: pulse-dot 1.6s infinite; }
@keyframes pulse-dot { 50% { opacity: .3; } }

/* ===== foguinho / destaque ===== */
.idea.hot::before { display: none; }
.fire-tags { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 8px; }
.row .fire-tags { margin-bottom: 0; }
.fire-tag {
  display: inline-flex; align-items: center; gap: 4px; font-size: 11.5px; font-weight: 800; letter-spacing: .3px;
  padding: 3px 10px; border-radius: 999px; color: #fff; background: linear-gradient(135deg, #ff7a18, #e5161f);
  box-shadow: 0 4px 12px -4px rgba(229, 22, 31, .6);
}
.fire-tag.mega {
  color: #4a2a00; background: linear-gradient(110deg, #ffd34d 0%, #fff1a8 40%, #ffc21a 60%, #ffd34d 100%);
  background-size: 200% 100%; animation: shine 2.6s linear infinite; box-shadow: 0 4px 14px -4px rgba(255, 180, 0, .8);
  text-transform: uppercase;
}
@keyframes shine { to { background-position: -200% 0; } }

.idea.top, .row.top { border-color: #ffb199; }
.idea.mega, .row.mega {
  border: 2px solid transparent;
  background: linear-gradient(#fff, #fff) padding-box, linear-gradient(135deg, #ffcc29, #ff7a18, #e5161f) border-box;
  box-shadow: 0 10px 28px -14px rgba(229, 22, 31, .55);
}
.row.mega .dt { background: linear-gradient(160deg, #ff7a18, #e5161f); }
@media (prefers-reduced-motion: reduce) { .fire-tag.mega { animation: none; } }
