:root {
  --green: #1aa260;
  --green-dark: #138049;
  --green-light: #e6f6ee;
  --text: #2b2b2b;
  --muted: #6b7280;
  --border: #e5e7eb;
  --bg: #f5f6f7;
  --dark: #1f2328;
}

body {
  font-family: "Segoe UI", Roboto, Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
}

.no-scroll { overflow: hidden; }

.container {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 16px;
}

/* Header */
.header {
  background: #fff;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 10;
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 56px;
}

.header__actions {
  display: flex;
  gap: 8px;
}

.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  font-size: 20px;
  border-radius: 50%;
}

.icon-btn:hover {
  background: var(--bg);
}

.logo {
  font-size: 22px;
  font-weight: 700;
  color: var(--green);
}

.logo span {
  color: var(--text);
}

.logo--light,
.logo--light span {
  color: #fff;
}

/* Campaign */
.layout {
  padding-top: 16px;
  padding-bottom: 32px;
}

.campaign {
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--border);
}

.campaign__cover img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  background: var(--border);
}

.campaign__info {
  padding: 16px;
}

.campaign__title {
  font-size: 22px;
  line-height: 1.25;
  margin-bottom: 8px;
}

.badge {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  color: var(--green-dark);
  background: var(--green-light);
  padding: 2px 10px;
  border-radius: 999px;
}

.raised {
  margin-top: 16px;
  padding: 12px;
  background: var(--green-light);
  border-radius: 8px;
}

.raised__label {
  font-size: 12px;
  color: var(--muted);
}

.raised__value {
  font-size: 28px;
  font-weight: 700;
  color: var(--green-dark);
}

.raised__meta {
  font-size: 13px;
  color: var(--muted);
  margin-top: 6px;
}

.progress {
  height: 8px;
  background: #fff;
  border-radius: 999px;
  overflow: hidden;
  margin-top: 8px;
}

.progress__bar {
  height: 100%;
  background: var(--green);
  border-radius: 999px;
}

.cta {
  display: grid;
  gap: 10px;
  margin-top: 16px;
}

.btn {
  padding: 14px 20px;
  font-size: 16px;
  font-weight: 600;
  border-radius: 999px;
  transition: background 0.2s, color 0.2s;
}

.btn--primary {
  background: var(--green);
  color: #fff;
}

.btn--primary:hover {
  background: var(--green-dark);
}

.btn--outline {
  border: 2px solid var(--border);
  background: #fff;
}

.btn--outline:hover {
  border-color: var(--green);
  color: var(--green-dark);
}

.btn--sm { padding: 8px 16px; font-size: 14px; width: 100%; border-radius: 8px; }
.btn--block { display: block; width: 100%; }

/* Links usados como botão */
a.btn { display: inline-block; text-align: center; }
a.btn--block { display: block; }

/* Tabs */
.tabs {
  display: flex;
  gap: 8px;
  margin: 20px 0 12px;
  overflow-x: auto;
}

.tabs__item {
  padding: 8px 18px;
  font-weight: 600;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: #fff;
  white-space: nowrap;
}

.tabs__item.is-active {
  background: var(--green);
  border-color: var(--green);
  color: #fff;
}

/* Story */
.story {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px;
}

.story__meta {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 12px;
}

.story h2 {
  font-size: 20px;
  margin-bottom: 12px;
}

.story p + p {
  margin-top: 12px;
}

.organizer {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 20px;
  padding: 12px;
  background: var(--bg);
  border-radius: 8px;
}

.organizer__avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--border);
}

.organizer__role,
.organizer__note {
  font-size: 12px;
  color: var(--muted);
}

.organizer__name {
  font-weight: 700;
}

.story__hearts {
  margin-top: 20px;
  font-size: 14px;
}
.heart { color: var(--green-dark); }
.report {
  display: inline-block;
  margin-top: 16px;
  font-size: 13px;
  color: var(--muted);
  text-decoration: underline;
}

/* Pix */
.pix {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 20px;
  padding: 16px;
  background: #e2e2e2;
  border-radius: 4px;
}
.pix__icon { font-size: 28px; color: #000; }
.pix__text { flex: 1; font-size: 15px; overflow-wrap: anywhere; }
.pix__copy {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  font-size: 14px;
  font-weight: 700;
  text-decoration: underline;
  background: #ececec;
  border-radius: 4px;
  white-space: nowrap;
}

/* Related */
.related {
  margin-top: 24px;
}

.related h2 {
  font-size: 18px;
  margin-bottom: 12px;
}

.card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: 16px;
}

.card img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  background: var(--border);
}

.card__body {
  padding: 12px;
}

.card__body h3 {
  font-size: 16px;
  margin-bottom: 6px;
}

.card__value {
  font-weight: 700;
  color: var(--green-dark);
}

.card__value small {
  font-weight: 400;
  color: var(--muted);
}

.card .progress {
  background: var(--green-light);
}

/* Menu lateral */
.overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 40;
}
.overlay[hidden] { display: none; }

.drawer {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: min(88vw, 400px);
  background: #fff;
  padding: 16px;
  overflow-y: auto;
  transform: translateX(-100%);
  transition: transform 0.25s ease;
  z-index: 50;
}
.drawer.is-open { transform: translateX(0); }

.drawer__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.welcome {
  background: #f8f8f8;
  border-radius: 12px;
  padding: 16px;
  margin-bottom: 16px;
}
.welcome__title { font-weight: 700; font-size: 18px; }
.welcome__text { font-size: 13px; color: var(--muted); margin: 4px 0 12px; }

.acc summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 4px;
  font-weight: 700;
  cursor: pointer;
  list-style: none;
}
.acc summary::-webkit-details-marker { display: none; }
.acc summary::after {
  content: "\F282";
  font-family: "bootstrap-icons";
  font-size: 16px;
  transition: transform 0.2s;
}
.acc[open] summary::after { transform: rotate(180deg); }
.acc ul { padding: 0 4px 12px; display: grid; gap: 10px; color: var(--muted); }
.drawer .btn--block { margin-top: 20px; }

/* Footer */
.footer {
  background: var(--dark);
  color: #fff;
  padding-top: 24px;
}

.footer__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
}

.social { display: flex; }
.social li + li { border-left: 1px solid #555; }
.social a { display: block; padding: 4px 12px; font-size: 16px; }

.footer__title {
  color: #1aa260;
  font-size: 18px;
  margin-bottom: 14px;
}

.footer__links {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px 16px;
  font-size: 13px;
  font-weight: 600;
  color: #fff;
}
.footer__links a:hover { color: #9be3bf; }

.footer__cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 32px;
}
.footer__strong { font-size: 13px; font-weight: 700; color: #fff; }
.footer__small { font-size: 13px; color: #d1d5db; margin-top: 16px; }
.footer__small--dim { color: #8b9098; }

.store {
  padding: 10px 14px;
  border: 1px solid #4b5563;
  border-radius: 8px;
  font-size: 14px;
  text-align: center;
  color: #fff;
}
.store i { margin-right: 6px; }
.store--light {
  display: block;
  margin-bottom: 10px;
  background: #000;
}

.footer__copy {
  margin: 24px -16px 0;
  padding: 16px;
  text-align: center;
  font-size: 12px;
  background: #555;
  color: #fff;
}

/* Barra fixa de doação (só mobile) */
.donate-bar { display: none; }
.donate-bar__pill i { margin-right: 2px; }

/* Valores sugeridos */
.amounts {
  margin-top: 16px;
  padding: 16px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 12px;
}
.amounts h2 { font-size: 18px; margin-bottom: 14px; }
/* Valores em grade: 3 por linha, lado a lado */
.amounts__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 16px;
}
.amount {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 20px 8px;
  font-size: 20px;
  font-weight: 700;
  color: var(--green-dark);
  background: #fff;
  border: 2px solid var(--border);
  border-radius: 12px;
  transition: border-color 0.15s, background 0.15s, color 0.15s, box-shadow 0.15s;
}
.amount small { font-size: 13px; font-weight: 600; }
.amount:hover { border-color: var(--green); background: var(--green-light); }
.amount[aria-checked="true"] {
  background: var(--green);
  border-color: var(--green);
  color: #fff;
  box-shadow: 0 4px 14px rgba(26, 162, 96, 0.3);
}
.amount:focus-visible { outline: 2px solid var(--text); outline-offset: 2px; }
/* "Personalizado" ocupa a linha inteira, no fim */
.amount--custom {
  grid-column: 1 / -1;
  font-size: 17px;
  color: var(--text);
  border-style: dashed;
}
.amount--custom[aria-checked="true"] { color: #fff; border-style: solid; }

/* Cabeçalho: itens só de desktop ficam ocultos por padrão */
.header__nav,
.header__desk { display: none; }
.btn--light { background: var(--green-light); color: var(--green-dark); }

/* ---------- Layout v3: cabeçalho da campanha, abas e história ---------- */
.campaign__meta {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 6px;
  font-size: 12px;
  font-weight: 600;
  color: #8a8f98;
  text-transform: uppercase;
}
.campaign__meta i { margin-right: 2px; }

.campaign__title { font-size: 26px; line-height: 1.15; margin-bottom: 8px; }
.campaign__id { font-weight: 700; font-size: 15px; margin-bottom: 14px; }

.campaign__excerpt {
  margin-bottom: 14px;
  font-size: 15px;
  line-height: 1.55;
  color: #555;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.campaign__more { font-weight: 700; color: #2a9db5; }

/* Abas sublinhadas */
.tabs {
  gap: 16px;
  margin: 20px 0 16px;
  padding-bottom: 2px;
  scrollbar-width: none;
}
.tabs::-webkit-scrollbar { display: none; }
.tabs__item {
  padding: 8px 8px 10px;
  font-size: 16px;
  font-weight: 400;
  color: #555;
  background: none;
  border: 0;
  border-bottom: 3px solid #e3e3e3;
  border-radius: 0;
}
.tabs__item.is-active {
  background: none;
  color: var(--green);
  font-weight: 700;
  border-bottom-color: var(--green);
}

/* História */
.story { padding: 20px 16px; border: 0; }
.story__pix {
  font-size: 15px;
  color: #555;
  overflow-wrap: anywhere;
}
.story__pix strong { color: var(--text); }
.story__pix .pix__copy {
  padding: 0 4px;
  font-size: 15px;
  text-decoration: none;
  background: none;
  vertical-align: middle;
}
.story__divider { border: 0; border-top: 1px solid var(--border); margin: 16px 0; }
.story__meta { font-size: 13px; margin-bottom: 12px; }
.story h2 { font-size: 26px; font-weight: 400; line-height: 1.2; margin-bottom: 10px; }
.story p { font-size: 14px; line-height: 1.55; }
.story p + p { margin-top: 14px; }
.story .story__meta + h2 { margin-top: 0; }

/* ---------- Layout v4: bloco Arrecadado ---------- */
.raised {
  margin-top: 16px;
  padding: 0;
  background: none;
  border-radius: 0;
}
.raised__progress {
  height: 5px;
  margin: 0 0 16px;
  background: #e9ecef;
}
.raised__label { font-size: 20px; font-weight: 700; color: var(--text); }
.raised__value { font-size: 40px; line-height: 1.1; font-weight: 800; color: #25cc6b; }
.raised__goal { font-size: 18px; color: #9aa0a6; margin-top: 2px; }

.stats {
  margin-top: 18px;
  padding: 12px 14px;
  background: var(--green-light);
  border-radius: 6px;
  display: grid;
  gap: 10px;
}
.stats div { display: flex; justify-content: space-between; font-size: 14px; }
.stats dt { color: var(--text); }
.stats dd { font-weight: 700; }

.cta { margin-top: 20px; }

.protect {
  margin-top: 20px;
  padding: 14px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.protect__pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 10px 3px 4px;
  font-size: 10px;
  font-weight: 700;
  color: var(--green-dark);
  background: #d4f7c5;
  border: 1px solid var(--green-dark);
  border-radius: 999px;
}
.protect__pill i {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  font-size: 13px;
  color: #fff;
  background: var(--green-dark);
  border-radius: 50%;
}

.owner {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 16px;
  padding: 14px;
  background: #f5f5f5;
  border-radius: 10px;
}
.owner__avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  font-size: 14px;
  font-weight: 700;
  color: #fff;
  background: #9b1c1c;
  border-radius: 50%;
}
.owner__name { font-size: 16px; font-weight: 600; }
.owner__since { font-size: 12px; color: var(--muted); }

/* ---------- Painéis das abas ---------- */
.tab-panel[hidden],
.empty[hidden] { display: none; }
.empty { padding: 24px 8px; text-align: center; color: var(--muted); font-size: 14px; }

/* Quem ajudou */
.helpcard {
  display: grid;
  gap: 22px;
  padding: 20px 16px;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 1px 6px rgba(0, 0, 0, 0.12);
}
.helpcard li { display: flex; align-items: center; gap: 14px; }
.helpcard strong { font-size: 15px; }
.helpcard p { font-size: 15px; color: #444; }
.helpcard__ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  font-size: 18px;
  color: #fff;
  border-radius: 50%;
}
.helpcard__ico--green { background: #25cc6b; }
.helpcard__ico--red { background: #9b0000; }

.supporters__title {
  margin: 40px 0 16px;
  text-align: center;
  font-size: 20px;
  color: #444;
}
.supporter {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
}
.supporter__avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 50px;
  flex-shrink: 0;
  font-size: 20px;
  color: #fff;
  border-radius: 50%;
}
.supporter__body { flex: 1; }
.supporter__body strong { font-size: 13px; }
.supporter__body p { font-size: 12px; margin-top: 8px; }
.supporter__when { font-size: 11px; color: #555; }

/* Perguntas frequentes */
.faqs { display: grid; gap: 12px; }
.faq {
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 1px 6px rgba(0, 0, 0, 0.12);
}
.faq summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 20px 16px;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "\F282";
  font-family: "bootstrap-icons";
  font-size: 14px;
  flex-shrink: 0;
}
.faq[open] summary::after { content: "\F286"; color: var(--green); }
.faq__body { padding: 0 16px 20px; font-size: 14px; line-height: 1.6; color: #777; }

/* O atributo hidden sempre vence (evita conflito com display: grid/flex) */
[hidden] { display: none !important; }
.owner__name { text-transform: uppercase; }

/* Botão e campo de valor personalizado */
.amount--custom {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: 15px;
}
.amount--custom i { font-size: 14px; }

.amounts__custom {
  margin: 12px 0 16px;
  display: grid;
  gap: 6px;
}
.amounts__custom[hidden] { display: none; }
.amounts__custom label { font-size: 13px; font-weight: 600; }
.amounts__custom .money { display: flex; }
.amounts__custom .money__prefix {
  display: flex;
  align-items: center;
  padding: 0 14px;
  background: #eee;
  border: 1px solid #cfd3d8;
  border-right: 0;
  border-radius: 8px 0 0 8px;
  color: var(--muted);
}
.amounts__custom input {
  flex: 1;
  min-width: 0;
  padding: 12px;
  font: inherit;
  font-size: 16px;
  border: 1px solid #cfd3d8;
  border-radius: 0 8px 8px 0;
}
.amounts__custom input:focus { outline: 2px solid var(--green); border-color: var(--green); }
