/* Chagua 6.4 – records, seat rules, limits and money blocks (profiles, place pages, Compare). */
.chr-box, .chr-rules, .chr-hub { --r-green: #016b3f; --r-deep: #014d2e; --r-red: #bb0000; --r-gold: #f2b705; --r-ink: #0f1f17; --r-muted: #5b6b63; --r-line: #e3e9e5; --r-soft: #f4f8f5; color: var(--r-ink); }
.chr-box *, .chr-rules *, .chr-hub * { -webkit-text-fill-color: currentColor; }
.chr-k { margin: 0 0 8px !important; font-size: 12.5px !important; font-weight: 800 !important; letter-spacing: .07em; text-transform: uppercase; color: var(--r-deep) !important; }
.chr-note { margin: 10px 0 0 !important; font-size: 13.5px !important; line-height: 1.5 !important; color: var(--r-muted) !important; }
.chr-none { color: #8a9890; font-style: italic; }
.chr-src { display: inline-block; font-size: 12.5px; color: var(--r-muted); }
.chr-src a, .chr-srcl { color: var(--r-green) !important; font-weight: 700; text-decoration: none !important; background: none !important; padding: 0 !important; }
.chr-src a:hover, .chr-srcl:hover { text-decoration: underline !important; }

/* Stat tiles */
.chr-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin: 0; }
.chr-tile { position: relative; display: flex; flex-direction: column; gap: 2px; padding: 14px 14px 12px; border-radius: 14px; background: #fff; border: 1px solid var(--r-line); overflow: hidden; }
.chr-tile::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 4px; background: var(--r-green); }
.chr-tile b { font-size: 22px; line-height: 1.15; font-weight: 900; color: var(--r-ink); }
.chr-tile span { font-size: 13px; line-height: 1.35; color: var(--r-muted); }
.chr-tile--hero { grid-column: span 2; background: linear-gradient(155deg, #013a22, #016b3f 70%, #0a7d4c); border: 0; color: #fff; }
.chr-tile--hero::before { width: 100%; height: 5px; bottom: auto; background: linear-gradient(90deg, #000 0 33%, var(--r-red) 33% 66%, #fff 66%); }
.chr-tile--hero b { color: #fff; font-size: 28px; }
.chr-tile--hero span { color: rgba(255,255,255,.85); }
@media (max-width: 560px) { .chr-tile--hero { grid-column: auto; } .chr-tile b { font-size: 19px; } .chr-tile--hero b { font-size: 24px; } }

/* Party timeline */
.chr-tl { position: relative; list-style: none; margin: 0; padding: 0 0 0 22px; }
.chr-tl::before { content: ""; position: absolute; left: 6px; top: 6px; bottom: 6px; width: 2px; background: linear-gradient(180deg, var(--r-green), #cfdcd4); }
.chr-tl li { position: relative; display: flex; flex-wrap: wrap; gap: 4px 12px; margin: 0 0 12px; padding: 0; }
.chr-tl li::before { content: ""; position: absolute; left: -21px; top: 5px; width: 12px; height: 12px; border-radius: 50%; background: #fff; border: 3px solid var(--r-green); }
.chr-tl li.is-now::before { background: var(--r-gold); border-color: var(--r-gold); box-shadow: 0 0 0 3px rgba(242,183,5,.25); }
.chr-when { min-width: 92px; font-weight: 800; font-size: 14px; color: var(--r-deep); }
.chr-what { flex: 1; min-width: 180px; font-size: 15px; }
.chr-tl li.is-now .chr-what { font-weight: 800; }

/* Seat rules */
.chr-rules { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 18px; }
.chr-ticks, .chr-bars, .chr-plain { list-style: none !important; margin: 0 0 14px !important; padding: 0 !important; }
.chr-ticks li, .chr-bars li { position: relative; margin: 0 0 7px !important; padding: 0 0 0 28px !important; font-size: 15px; line-height: 1.45; }
.chr-ticks li::before, .chr-bars li::before { position: absolute; left: 0; top: 1px; display: grid; place-items: center; width: 19px; height: 19px; border-radius: 50%; font-size: 11px; font-weight: 900; }
.chr-ticks li::before { content: "✓"; background: #e3f4ea; color: var(--r-green); }
.chr-bars li::before { content: "×"; background: #fdeaea; color: var(--r-red); font-size: 14px; }
.chr-plain li { margin: 0 0 4px !important; font-size: 15px; }
.chr-degree { margin: 0 0 8px !important; padding: 10px 14px; border-radius: 12px; background: #fff7dc; border: 1px solid #f3dd8a; font-size: 14.5px; line-height: 1.5; }
.chr-degree b { color: #6b4b00; }
.chr-card { margin: 0 0 12px; padding: 14px 16px; border-radius: 14px; background: var(--r-soft); border: 1px solid var(--r-line); }
.chr-card--gold { background: #fffaf0; border-color: #f3dd8a; }
.chr-card--gold .chr-k { color: #6b4b00 !important; }
.chr-big { margin: 0 !important; font-size: 26px !important; font-weight: 900 !important; line-height: 1.15 !important; color: var(--r-ink); }
.chr-rules a { color: var(--r-green); font-weight: 700; }
@media (max-width: 760px) { .chr-rules { grid-template-columns: 1fr; } }

/* Place pages */
.chr-hub { margin: 18px 0; padding: 20px; border-radius: 18px; background: #fff; border: 1px solid var(--r-line); box-shadow: 0 1px 2px rgba(4,54,31,.05), 0 10px 26px rgba(4,54,31,.07); }
.chr-hub h2 { margin: 0 0 14px !important; font-size: 21px !important; font-weight: 800 !important; color: var(--r-ink) !important; background: none !important; padding: 0 !important; border-radius: 0 !important; box-shadow: none !important; display: block !important; }
.chr-limit { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; margin: 14px 0 0 !important; padding: 12px 14px; border-radius: 12px; background: #fffaf0; border: 1px solid #f3dd8a; font-size: 14.5px; }
.chr-hub > .chr-limit:only-child { margin: 0 !important; }
.chr-limit b { font-size: 17px; font-weight: 900; }
.chr-scroll { overflow-x: auto; margin-top: 14px; border: 1px solid var(--r-line); border-radius: 12px; }
.chr-table { width: 100%; min-width: 560px; border-collapse: collapse; font-size: 14px; }
.chr-table th, .chr-table td { padding: 9px 12px; text-align: left; border-bottom: 1px solid var(--r-line); background: #fff !important; color: var(--r-ink) !important; }
.chr-table thead th { font-size: 12px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--r-muted) !important; background: var(--r-soft) !important; }
.chr-table a { color: var(--r-green) !important; background: none !important; padding: 0 !important; }

/* Compare cells */
.chagua-el-cmp td small { display: block; margin-top: 3px; }

/* Dark mode */
html.cht-night .chr-tile, html.cht-night .chr-hub, html.cht-night .chr-table th, html.cht-night .chr-table td { background: #131c17 !important; border-color: #26332c; color: #e6efe9 !important; }
html.cht-night .chr-tile b, html.cht-night .chr-big, html.cht-night .chr-hub h2 { color: #eef3ef !important; }
html.cht-night .chr-card { background: #16221b; border-color: #26332c; }
html.cht-night .chr-card--gold, html.cht-night .chr-limit, html.cht-night .chr-degree { background: #2a2410; border-color: #5a4a12; color: #f4e7bf; }

/* Where they stand (/issues/) */
.chi-wrap .chi-step { display: flex; gap: 14px; margin: 0 0 18px; }
.chi-n { flex: none; display: grid; place-items: center; width: 34px; height: 34px; margin: 0 !important; border-radius: 50%; background: #f2b705; color: #1c1600; font-weight: 900; }
.chi-step > div { flex: 1; min-width: 0; }
.chi-wrap .chi-h { margin: 4px 0 10px !important; font-size: 18px !important; font-weight: 800 !important; color: #0f1f17 !important; }
.chi-sel { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.chi-sel label { display: flex; flex-direction: column; gap: 4px; font-size: 13px; font-weight: 700; color: #5b6b63; }
.chi-sel select { width: 100%; height: 48px; padding: 0 12px; border: 2px solid #d6e2db; border-radius: 12px; background: #fbfdfc; font: inherit; font-size: 15.5px; color: #0f1f17; }
.chi-sel select:focus { outline: 0; border-color: #016b3f; box-shadow: 0 0 0 4px rgba(1,107,63,.14); }
.chi-topics { display: flex; flex-wrap: wrap; gap: 8px; }
.chi-topic { position: relative; cursor: pointer; margin: 0; }
.chi-topic input { position: absolute; opacity: 0; }
.chi-topic span { display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: 999px; border: 2px solid #d6e2db; background: #fff; font-size: 14.5px; font-weight: 700; color: #3b4a42; transition: all .15s; }
.chi-topic input:checked + span { background: #016b3f; border-color: #016b3f; color: #fff; }
.chi-topic input:checked + span::before { content: "✓"; font-weight: 900; }
.chi-topic input:focus-visible + span { box-shadow: 0 0 0 4px rgba(1,107,63,.2); }
.chi-where { margin: 6px 0 12px !important; font-size: 13px; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; color: #014d2e; }
.chi-race { margin: 0 0 14px; border-radius: 18px; background: #fff; border: 1px solid #e3e9e5; box-shadow: 0 1px 2px rgba(4,54,31,.05), 0 10px 26px rgba(4,54,31,.07); overflow: hidden; }
.chi-race summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 20px; cursor: pointer; list-style: none; background: linear-gradient(90deg, #f4f8f5, #fff); border-left: 5px solid #016b3f; }
.chi-race summary::-webkit-details-marker { display: none; }
.chi-race summary::after { content: "▾"; color: #016b3f; font-size: 18px; transition: transform .15s; }
.chi-race[open] summary::after { transform: rotate(180deg); }
.chi-race-t { flex: 1; font-size: 18px; font-weight: 800; color: #0f1f17; }
.chi-race-n { flex: none; padding: 3px 10px; border-radius: 999px; background: #e3f4ea; color: #016b3f; font-size: 12.5px; font-weight: 800; }
.chi-q { padding: 16px 20px 4px; border-top: 1px solid #edf2ef; }
.chi-qt { margin: 0 0 10px !important; font-size: 15px; font-weight: 600; color: #0f1f17; }
.chi-qt span { display: inline-block; margin-right: 6px; padding: 2px 9px; border-radius: 6px; background: #014d2e; color: #fff; font-size: 12px; font-weight: 800; letter-spacing: .03em; }
.chi-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 10px; margin-bottom: 12px; }
.chi-a { padding: 12px 14px; border-radius: 12px; background: #f9fbfa; border: 1px solid #e3e9e5; }
.chi-a p { margin: 6px 0 0 !important; font-size: 14.5px; line-height: 1.5; }
.chi-a.is-empty p { color: #8a9890; font-style: italic; }
.chi-who { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px; text-decoration: none !important; background: none !important; padding: 0 !important; color: #0f1f17 !important; }
.chi-who b { font-size: 15px; }
.chi-who small { padding: 1px 8px; border-radius: 999px; background: #eef4f0; color: #5b6b63; font-size: 11.5px; font-weight: 700; }
.chi-more { margin: 0 !important; padding: 10px 20px 16px; display: flex; flex-wrap: wrap; gap: 6px 18px; }
.chi-more a, .chi-wrap .chi-note a { color: #016b3f !important; font-weight: 700; background: none !important; padding: 0 !important; }
.chi-empty { padding: 16px 20px; color: #5b6b63; }
.chi-note { font-size: 13.5px; color: #5b6b63; }
@media (max-width: 760px) { .chi-sel { grid-template-columns: 1fr; } .chi-race summary, .chi-q { padding-left: 14px; padding-right: 14px; } }

/* Photo drive */
.chpd-meter { height: 12px; margin: 0 0 12px; border-radius: 999px; background: rgba(255,255,255,.18); overflow: hidden; max-width: 520px; }
.chpd-meter span { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, #f2b705, #ffd65a); }
.chpd-filter { margin: 0 0 14px; }
.chpd-filter select { height: 44px; padding: 0 12px; border: 2px solid #d6e2db; border-radius: 12px; font: inherit; }
.chpd-grid { list-style: none !important; margin: 0 !important; padding: 0 !important; display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 12px; }
.chpd-grid li { display: flex; flex-direction: column; align-items: center; gap: 4px; margin: 0 !important; padding: 16px 12px 14px; border-radius: 16px; background: #fff; border: 1px solid #e3e9e5; text-align: center; }
.chpd-grid b { font-size: 15px; line-height: 1.25; }
.chpd-grid small { min-height: 2.4em; color: #5b6b63; font-size: 12.5px; }
.chpd-ph { display: grid; place-items: center; width: 64px; height: 64px; margin-bottom: 6px; border-radius: 50%; border: 2px dashed #c9d8cf; background: #f4f8f5; color: #8a9890; font-size: 20px; font-weight: 800; }
.chpd-add { display: inline-flex; align-items: center; gap: 4px; margin-top: 6px; padding: 7px 14px; border-radius: 999px; background: #016b3f !important; color: #fff !important; font-size: 13.5px; font-weight: 800; text-decoration: none !important; }
.chpd-add:hover { background: #014d2e !important; }
.chpd-pager { display: flex; gap: 10px; margin: 16px 0 0 !important; }
.chpd-field { margin: 0 0 16px !important; }
.chpd-field > label, .chpd-field legend { display: block; margin: 0 0 6px; font-weight: 800; font-size: 14.5px; color: #0f1f17; }
.chpd-field input[type=file], .chpd-field input[name=credit], .chpd-field input[type=url] { width: 100%; min-height: 48px; padding: 10px 14px; border: 2px solid #d6e2db; border-radius: 12px; background: #fbfdfc; font: inherit; }
.chpd-field fieldset, fieldset.chpd-field { border: 0; padding: 0; }
.chpd-radio, .chpd-check { display: flex; gap: 10px; align-items: flex-start; margin: 0 0 8px; padding: 10px 12px; border-radius: 12px; border: 1px solid #e3e9e5; background: #fff; font-size: 14.5px; line-height: 1.45; cursor: pointer; }
.chpd-radio input, .chpd-check input { margin-top: 3px; accent-color: #016b3f; }
.chpd-ok { border-left: 5px solid #016b3f !important; font-weight: 600; }
.chpd-err { border-left: 5px solid #bb0000 !important; color: #8a1f1f; font-weight: 600; }
.chpd-nudge { display: flex; align-items: center; gap: 14px; padding: 14px 16px; border-radius: 14px; background: #f4f8f5; border: 1px dashed #c9d8cf; }
.chpd-nudge .chpd-ph { width: 48px; height: 48px; margin: 0; font-size: 20px; }
.chpd-nudge div { flex: 1; }
.chpd-nudge p { margin: 2px 0 0 !important; font-size: 14px; color: #5b6b63; }
@media (max-width: 560px) { .chpd-nudge { flex-wrap: wrap; } }
