@font-face { font-family: "Gilroy"; src: url("/static/brand/fonts/Gilroy-Light.otf") format("opentype"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Gilroy"; src: url("/static/brand/fonts/Gilroy-ExtraBold.otf") format("opentype"); font-weight: 750 900; font-style: normal; font-display: swap; }
:root {
  --ink: #393536;
  --muted: #71696a;
  --olive: #a84851;
  --olive-dark: #7c3038;
  --cream: #f8f1ee;
  --paper: #fffdfc;
  --line: #e4d9d7;
  --red: #a33b32;
  --green-soft: #f4e2df;
  --shadow: 0 16px 45px rgba(92, 47, 51, .10);
}
* { box-sizing: border-box; }
body { margin: 0; color: var(--ink); background: #faf8f7; font: 16px/1.55 "Gilroy", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; }
a { color: inherit; }
.topbar { position: sticky; top: 0; z-index: 10; background: rgba(255,254,250,.94); border-bottom: 1px solid var(--line); backdrop-filter: blur(12px); }
.topbar-inner { max-width: 1240px; margin: auto; min-height: 68px; padding: 0 28px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { display: inline-flex; align-items: center; min-height: 58px; text-decoration: none; }
.brand img { display: block; width: auto; height: 46px; }
nav { display: flex; align-items: center; gap: 22px; }
nav a { color: var(--muted); text-decoration: none; font-size: 14px; font-weight: 650; }
nav a:hover { color: var(--ink); }
.nav-cta { border: 1px solid var(--olive); border-radius: 999px; padding: 8px 14px; color: var(--olive-dark); }
main { max-width: 1240px; margin: 0 auto; padding: 46px 28px 72px; }
footer { max-width: 1184px; margin: 0 auto; padding: 28px 0 45px; border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; }
.footer-copy { display: flex; justify-content: space-between; gap: 18px; margin-bottom: 26px; }
.funding-strip { display: block; width: 100%; height: auto; }
h1, h2, h3 { margin-top: 0; line-height: 1.12; font-family: "Gilroy", sans-serif; font-weight: 800; }
h1 { font-size: clamp(36px, 5vw, 64px); line-height: 1.02; letter-spacing: -.035em; }
h2 { font-size: 25px; }
p { color: var(--muted); }
.eyebrow { margin-bottom: 10px; color: var(--olive); font-size: 12px; letter-spacing: .14em; text-transform: uppercase; font-weight: 800; }
.button { display: inline-flex; justify-content: center; align-items: center; min-height: 44px; border: 0; border-radius: 10px; padding: 0 18px; background: var(--olive); color: white; text-decoration: none; font: 750 14px/1 system-ui, sans-serif; cursor: pointer; }
.button:hover { background: var(--olive-dark); }
.button-secondary { color: var(--olive-dark); background: var(--green-soft); }
.button-danger { background: var(--red); }
.button-danger:hover { background: #77251f; }
.button-small { min-height: 34px; padding: 0 11px; font-size: 12px; }
.text-link, .row-link { color: var(--olive-dark); font-weight: 750; text-decoration: none; }
.back { display: inline-block; margin-bottom: 24px; color: var(--muted); font-size: 14px; text-decoration: none; }
.public-hero { min-height: 310px; display: flex; align-items: flex-end; justify-content: space-between; gap: 40px; padding: 34px 0 52px; border-bottom: 1px solid var(--line); }
.public-hero p { max-width: 650px; font-size: 19px; }
.hero-stat { min-width: 180px; padding: 22px; border-radius: 18px; background: var(--olive); color: white; box-shadow: var(--shadow); }
.hero-stat strong, .hero-stat span { display: block; }
.hero-stat strong { font: 800 50px/1 "Gilroy", sans-serif; }
.hero-stat span { margin-top: 8px; opacity: .8; font-size: 13px; }
.card-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.public-grid { margin-top: 32px; }
.action-card { min-height: 270px; padding: 27px; background: var(--paper); border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 8px 25px rgba(92,47,51,.05); }
.action-card h2 { font-size: 24px; }
.action-card h2 a { text-decoration: none; }
.action-card .meta { font-weight: 700; color: var(--ink); font-size: 13px; }
.action-hero { max-width: 920px; padding: 20px 0 42px; }
.action-hero .lead { max-width: 850px; font: 19px/1.65 "Gilroy", sans-serif; color: #5f5758; }
.action-body { display: grid; grid-template-columns: 330px 1fr; align-items: start; gap: 44px; }
.facts { margin: 0; padding: 24px; background: var(--cream); border-radius: 15px; border: 1px solid #e5dfd2; }
.facts div + div { margin-top: 17px; padding-top: 17px; border-top: 1px solid #ded8ca; }
.facts dt { margin-bottom: 3px; color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .1em; font-weight: 800; }
.facts dd { margin: 0; font-weight: 700; }
.section-heading { display: flex; align-items: flex-end; justify-content: space-between; border-bottom: 1px solid var(--line); margin-bottom: 18px; }
.section-heading span { padding-bottom: 14px; color: var(--muted); font-size: 13px; }
.gallery { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.gallery figure, .admin-photo { margin: 0; overflow: hidden; border-radius: 13px; border: 1px solid var(--line); background: var(--paper); }
.gallery img { display: block; width: 100%; height: 310px; object-fit: cover; }
.gallery figcaption { padding: 10px 13px; color: var(--muted); font-size: 12px; }
.admin-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 30px; margin-bottom: 28px; }
.admin-head h1 { margin-bottom: 10px; }
.admin-head p { margin-bottom: 0; }
.admin-head.compact h1 { font-size: clamp(34px, 4vw, 50px); }
.metrics { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 22px; }
.metrics > div { padding: 22px; border-radius: 14px; background: var(--paper); border: 1px solid var(--line); }
.metrics strong, .metrics span { display: block; }
.metrics strong { font: 800 36px/1 "Gilroy", sans-serif; }
.metrics span { margin-top: 8px; color: var(--muted); font-size: 13px; }
.metrics .metric-alert { border-color: #e5b9b4; background: #fff8f6; }
.metrics .metric-alert strong { color: var(--red); }
.admin-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 20px; margin-bottom: 20px; }
.panel { margin-bottom: 20px; padding: 24px; background: var(--paper); border: 1px solid var(--line); border-radius: 15px; box-shadow: 0 8px 25px rgba(92,47,51,.04); }
.panel h2 { margin-bottom: 6px; font-size: 23px; }
.panel h3 { font-size: 16px; }
.panel > p, .panel-head p { margin: 0 0 18px; font-size: 14px; }
.panel-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; margin-bottom: 14px; }
.panel-head a { color: var(--olive-dark); font-size: 13px; font-weight: 750; text-decoration: none; }
.table-scroll { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th { padding: 10px 12px; text-align: left; color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .08em; border-bottom: 1px solid var(--line); }
td { padding: 15px 12px; vertical-align: middle; border-bottom: 1px solid #ecefe8; font-size: 13px; }
td strong { font-size: 12px; color: var(--olive); }
td span { font-weight: 650; color: var(--ink); }
.badge { display: inline-flex; align-items: center; min-height: 26px; border-radius: 999px; padding: 0 9px; white-space: nowrap; font-size: 11px; font-weight: 800; }
.badge-ok { color: #34521c; background: #e5efda; }
.badge-late { color: #842d25; background: #fae3df; }
.badge-neutral { color: #646a65; background: #eceeea; }
.badge-photo { color: #295166; background: #e0eef4; }
.badge-pending { color: #754f12; background: #fff0c9; }
.stack { display: grid; gap: 12px; }
label span { display: block; margin-bottom: 6px; color: var(--muted); font-size: 12px; font-weight: 750; }
input, textarea, select { width: 100%; border: 1px solid var(--line); border-radius: 9px; padding: 11px 12px; color: var(--ink); background: white; font: inherit; }
input:focus, textarea:focus { outline: 3px solid rgba(82,102,47,.14); border-color: var(--olive); }
input[readonly] { background: #f1f3ef; color: var(--muted); }
.file-drop { padding: 18px; border: 1px dashed #aab59b; border-radius: 10px; background: #f7f9f2; color: var(--olive-dark); text-align: center; font-size: 13px; font-weight: 750; cursor: pointer; }
.file-drop input { margin-top: 10px; padding: 0; border: 0; background: transparent; font-size: 12px; }
.search { display: flex; gap: 8px; margin-bottom: 17px; }
.search button { border: 0; border-radius: 9px; padding: 0 18px; background: var(--ink); color: white; font-weight: 750; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.full { grid-column: 1 / -1; }
.detail-title { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.detail-title h1 { margin-bottom: 4px; font-size: clamp(32px, 4vw, 48px); }
.detail-grid { align-items: start; }
.admin-gallery { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.admin-photo img { display: block; width: 100%; height: 190px; object-fit: cover; }
.admin-photo figcaption { padding: 10px; }
.admin-photo figcaption strong, .admin-photo figcaption span { display: block; overflow-wrap: anywhere; }
.admin-photo figcaption strong { font-size: 11px; }
.admin-photo figcaption span { margin-top: 3px; color: var(--muted); font-size: 11px; }
.photo-delete { display: inline-block; margin-top: 9px; color: var(--red); font-size: 11px; font-weight: 800; text-decoration: none; }
.settings-form { margin-bottom: 20px; }
.settings-grid { margin-top: 18px; }
.toggle { display: flex; align-items: center; gap: 10px; margin: 12px 0 18px; }
.toggle input { width: 18px; height: 18px; flex: 0 0 auto; }
.toggle span { margin: 0; color: var(--ink); }
.setup-box { display: grid; gap: 8px; margin-top: 20px; padding: 16px; border: 1px solid var(--line); border-radius: 10px; background: var(--cream); }
.setup-box code { overflow-wrap: anywhere; color: var(--olive-dark); }
.setup-box span { color: var(--muted); font-size: 12px; }
.form-actions { display: flex; justify-content: flex-end; margin: -4px 0 28px; }
.delete-confirm { display: grid; grid-template-columns: minmax(240px, 430px) 1fr; align-items: center; gap: 30px; }
.delete-confirm > img { display: block; width: 100%; max-height: 430px; object-fit: contain; border-radius: 12px; background: var(--cream); }
.alert { margin-bottom: 20px; border-radius: 10px; padding: 13px 16px; color: #30491d; background: #e6efd9; border: 1px solid #c8d7b5; }
.alert-error { color: #7e3028; background: #f9e4e1; border-color: #e8bcb7; }
.empty { grid-column: 1 / -1; padding: 42px; border: 1px dashed var(--line); border-radius: 14px; text-align: center; background: var(--paper); }
.empty h1, .empty h2 { font-size: 30px; }
.muted { color: var(--muted); }
.pairing-code { display: block; margin-top: 10px; border: 1px solid #e5c2bd; border-radius: 8px; padding: 10px 12px; color: var(--olive-dark); background: #fff7f5; font: 750 13px/1.4 ui-monospace, SFMono-Regular, Menlo, monospace; overflow-wrap: anywhere; }
hr { border: 0; border-top: 1px solid var(--line); margin: 24px 0; }
@media (max-width: 900px) {
  .card-grid, .metrics { grid-template-columns: repeat(2, 1fr); }
  .admin-grid, .action-body { grid-template-columns: 1fr; }
  .delete-confirm { grid-template-columns: 1fr; }
  .admin-gallery { grid-template-columns: repeat(2, 1fr); }
  .facts { order: 2; }
}
@media (max-width: 620px) {
  main { padding: 30px 17px 60px; }
  .topbar-inner { padding: 0 17px; }
  nav a:not(.nav-cta) { display: none; }
  .public-hero, .admin-head { align-items: flex-start; flex-direction: column; }
  .card-grid, .metrics, .gallery, .form-grid, .admin-gallery { grid-template-columns: 1fr; }
  .hero-stat { width: 100%; }
  footer { margin: 0 17px; }
  .footer-copy { flex-direction: column; gap: 6px; }
  td { min-width: 110px; }
}

/* Gastos y justificantes */
.num { text-align: right; white-space: nowrap; }
.group-row td { background: var(--cream); font-weight: 700; color: var(--ink); }
.sub-row td:first-child { padding-left: 1.6rem; }
.sub-row td { font-size: .94em; }
.issues { margin: .4rem 0 0; padding-left: 1.1rem; color: var(--red); }
.issues li + li { margin-top: .25rem; }
.head-actions { display: flex; flex-wrap: wrap; gap: .6rem; align-items: center; }
select { width: 100%; }
.panel-head a.button { color: white; }
.panel-head a.button-secondary { color: var(--olive-dark); }
td a strong { white-space: nowrap; }
.admin-grid > *, .form-grid > * { min-width: 0; }
select { max-width: 100%; text-overflow: ellipsis; }
