/* Melian Foundation — official project fundraising (public + supporter pages) */
:root { --fr-ink: #073b3a; --fr-teal: #0b7770; --fr-mint: #e7f3ef; --fr-orange: #f7b267; --fr-muted: #687875; --fr-line: #e3ebe7; --fr-bg: #f6f8f7; }

.fr-page { background: var(--fr-bg); padding-bottom: 70px; color: #213b39; }
.fr-shell { max-width: 1180px; margin: 0 auto; padding: 0 20px; }
.fr-eyebrow { color: var(--fr-orange); text-transform: uppercase; letter-spacing: .16em; font-size: 12px; font-weight: 700; margin-bottom: 14px; }
.fr-hero { background: var(--fr-ink); color: #fff; padding: 80px 0 70px; position: relative; overflow: hidden; }
.fr-hero.has-image { background-size: cover; background-position: center; }
.fr-hero.has-image:before { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(7,59,58,.94) 0%, rgba(7,59,58,.78) 55%, rgba(7,59,58,.45) 100%); }
.fr-hero > * { position: relative; }
.fr-hero h1 { color: #fff; font-size: clamp(32px, 4.6vw, 56px); line-height: 1.08; margin-bottom: 16px; max-width: 760px; }
.fr-hero p { color: rgba(255,255,255,.8); font-size: 18px; line-height: 1.7; max-width: 680px; margin: 0; }
.fr-official-tag { display: inline-flex; align-items: center; gap: 8px; background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.22); color: #fff; padding: 7px 12px; font-size: 12px; font-weight: 700; letter-spacing: .05em; margin-bottom: 18px; border-radius: 3px; }
.fr-official-tag img { height: 20px; background: #fff; padding: 2px 4px; border-radius: 2px; }

.fr-btn { display: inline-flex; align-items: center; justify-content: center; gap: 9px; padding: 14px 22px; font-weight: 700; border: 2px solid transparent; border-radius: 4px; cursor: pointer; text-decoration: none; transition: transform .15s ease, background .15s ease; font-size: 15px; line-height: 1.2; }
.fr-btn:hover { transform: translateY(-1px); text-decoration: none; }
.fr-btn-donate { background: var(--fr-orange); color: var(--fr-ink); }
.fr-btn-donate:hover { background: #f5a24a; color: var(--fr-ink); }
.fr-btn-primary { background: var(--fr-teal); color: #fff; }
.fr-btn-primary:hover { background: #096760; color: #fff; }
.fr-btn-outline { background: transparent; color: var(--fr-teal); border-color: var(--fr-teal); }
.fr-btn-outline:hover { background: var(--fr-teal); color: #fff; }
.fr-btn-light { background: #fff; color: var(--fr-ink); }
.fr-btn-ambassador { background: #fff; color: var(--fr-ink); border-color: var(--fr-orange); text-transform: uppercase; letter-spacing: .06em; font-size: 14px; }
.fr-btn-ambassador:hover { background: var(--fr-orange); color: var(--fr-ink); }
.fr-btn-sm { padding: 9px 14px; font-size: 13px; }
.fr-btn-block { width: 100%; }
.fr-btn[disabled] { opacity: .6; cursor: not-allowed; transform: none; }

.fr-grid { display: grid; grid-template-columns: minmax(0, 1.65fr) minmax(300px, 1fr); gap: 28px; margin-top: -40px; position: relative; z-index: 2; }
.fr-card { background: #fff; border: 1px solid var(--fr-line); padding: 28px; margin-bottom: 24px; border-radius: 4px; }
.fr-card h2 { color: var(--fr-ink); font-size: 24px; margin-bottom: 14px; }
.fr-card h3 { color: var(--fr-ink); font-size: 18px; margin-bottom: 10px; }
.fr-card p, .fr-prose { color: #45605c; line-height: 1.75; }
.fr-prose { white-space: pre-line; }
.fr-sticky { position: sticky; top: 110px; }
.fr-cover { width: 100%; aspect-ratio: 16/8; object-fit: cover; display: block; border-radius: 4px; margin-bottom: 22px; }

.fr-progress { margin: 18px 0; }
.fr-progress-track { height: 12px; background: var(--fr-mint); border-radius: 20px; overflow: hidden; }
.fr-progress-fill { height: 100%; background: linear-gradient(90deg, var(--fr-teal), #2fa38f); border-radius: 20px; transition: width .6s ease; }
.fr-progress-fill.personal { background: linear-gradient(90deg, #e38f37, var(--fr-orange)); }
.fr-progress-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 8px; gap: 10px; }
.fr-raised { font-size: 28px; font-weight: 800; color: var(--fr-ink); line-height: 1.1; }
.fr-raised small { display: block; font-size: 13px; font-weight: 600; color: var(--fr-muted); margin-top: 4px; }
.fr-percent { font-weight: 800; color: var(--fr-teal); font-size: 18px; }
.fr-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 16px 0 20px; }
.fr-stat { background: var(--fr-bg); padding: 12px; text-align: center; border-radius: 4px; }
.fr-stat strong { display: block; color: var(--fr-ink); font-size: 18px; }
.fr-stat span { color: var(--fr-muted); font-size: 12px; }

.fr-notice { background: var(--fr-mint); border-left: 4px solid var(--fr-teal); padding: 14px 16px; font-size: 13.5px; color: #2c4f4b; line-height: 1.6; border-radius: 0 4px 4px 0; }
.fr-notice i { color: var(--fr-teal); margin-right: 6px; }
.fr-notice.warn { background: #fff4e6; border-left-color: var(--fr-orange); color: #6b4517; }
.fr-notice.warn i { color: #d48523; }
.fr-flash { padding: 14px 18px; margin: 18px 0; border-radius: 4px; font-weight: 600; }
.fr-flash.success { background: #e3f4ec; color: #0b5e3c; }
.fr-flash.error { background: #fde8e8; color: #9b1c1c; }
.fr-flash.info { background: #e7f0fb; color: #1f4f8a; }

.fr-project-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin-top: 40px; }
.fr-project-card { background: #fff; border: 1px solid var(--fr-line); display: flex; flex-direction: column; border-radius: 4px; overflow: hidden; transition: transform .2s ease, box-shadow .2s ease; }
.fr-project-card:hover { transform: translateY(-4px); box-shadow: 0 14px 32px rgba(7,59,58,.10); }
.fr-project-card img { width: 100%; aspect-ratio: 16/10; object-fit: cover; }
.fr-project-card .body { padding: 22px; display: flex; flex-direction: column; flex: 1; }
.fr-project-card h3 { font-size: 20px; color: var(--fr-ink); margin-bottom: 8px; }
.fr-project-card h3 a { color: inherit; }
.fr-project-card p { color: var(--fr-muted); font-size: 14px; line-height: 1.6; }
.fr-project-card .actions { margin-top: auto; display: flex; gap: 8px; flex-wrap: wrap; padding-top: 12px; }
.fr-pill { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; font-size: 11.5px; font-weight: 700; border-radius: 20px; background: var(--fr-mint); color: var(--fr-teal); text-transform: uppercase; letter-spacing: .04em; }
.fr-pill.orange { background: #fff0e0; color: #a3611e; }
.fr-pill.grey { background: #eef1f0; color: #5b6b68; }
.fr-pill.red { background: #fde8e8; color: #9b1c1c; }

.fr-leaderboard { list-style: none; padding: 0; margin: 0; }
.fr-leaderboard li { display: flex; align-items: center; gap: 14px; padding: 12px 0; border-bottom: 1px solid #eef2f0; }
.fr-leaderboard li:last-child { border-bottom: 0; }
.fr-rank { width: 28px; height: 28px; display: grid; place-items: center; background: var(--fr-mint); color: var(--fr-teal); font-weight: 800; font-size: 13px; border-radius: 50%; flex: 0 0 28px; }
.fr-leaderboard .who { flex: 1; min-width: 0; }
.fr-leaderboard .who a, .fr-leaderboard .who strong { color: var(--fr-ink); font-weight: 700; }
.fr-leaderboard .who small { display: block; color: var(--fr-muted); font-size: 12px; }
.fr-leaderboard .amount { font-weight: 800; color: var(--fr-teal); white-space: nowrap; }
.fr-mini-track { height: 5px; background: var(--fr-mint); border-radius: 10px; margin-top: 6px; overflow: hidden; }
.fr-mini-track span { display: block; height: 100%; background: var(--fr-orange); }

.fr-avatar { width: 46px; height: 46px; border-radius: 50%; object-fit: cover; background: var(--fr-teal); color: #fff; display: inline-grid; place-items: center; font-weight: 800; flex: 0 0 46px; font-size: 16px; }
.fr-avatar.lg { width: 110px; height: 110px; flex-basis: 110px; font-size: 36px; border: 4px solid #fff; box-shadow: 0 8px 24px rgba(7,59,58,.18); }
.fr-ambassador-head { display: flex; gap: 22px; align-items: center; margin-bottom: 18px; }
.fr-ambassador-head h2 { margin-bottom: 4px; }
.fr-quote { border-left: 3px solid var(--fr-orange); padding: 4px 0 4px 16px; color: #45605c; font-style: italic; white-space: pre-line; }

.fr-supporters { list-style: none; padding: 0; margin: 0; }
.fr-supporters li { padding: 12px 0; border-bottom: 1px solid #eef2f0; display: flex; gap: 12px; }
.fr-supporters li:last-child { border-bottom: 0; }
.fr-supporters .heart { width: 34px; height: 34px; flex: 0 0 34px; border-radius: 50%; display: grid; place-items: center; background: #fff0e0; color: #d48523; }
.fr-supporters strong { color: var(--fr-ink); }
.fr-supporters small { color: var(--fr-muted); }
.fr-supporters p { margin: 4px 0 0; font-size: 14px; }

.fr-share { display: flex; flex-wrap: wrap; gap: 8px; }
.fr-share a, .fr-share button { display: inline-flex; align-items: center; gap: 7px; padding: 9px 13px; font-size: 13px; font-weight: 700; border: 1px solid var(--fr-line); background: #fff; color: var(--fr-ink); border-radius: 4px; cursor: pointer; text-decoration: none; }
.fr-share a:hover, .fr-share button:hover { border-color: var(--fr-teal); color: var(--fr-teal); }
.fr-share .wa i { color: #25d366; } .fr-share .fb i { color: #1877f2; } .fr-share .li i { color: #0a66c2; } .fr-share .x i { color: #000; } .fr-share .em i { color: #d48523; }
.fr-copy { display: flex; margin-top: 12px; border: 1px solid var(--fr-line); border-radius: 4px; overflow: hidden; }
.fr-copy input { flex: 1; border: 0; padding: 10px 12px; font-size: 13px; min-width: 0; background: var(--fr-bg); color: #345; }
.fr-copy button { border: 0; background: var(--fr-teal); color: #fff; font-weight: 700; padding: 0 16px; }

.fr-updates article { padding: 16px 0; border-bottom: 1px solid #eef2f0; }
.fr-updates article:last-child { border-bottom: 0; }
.fr-updates time { font-size: 12px; color: var(--fr-muted); font-weight: 700; text-transform: uppercase; letter-spacing: .06em; }
.fr-updates h4 { color: var(--fr-ink); font-size: 17px; margin: 4px 0 6px; }
.fr-updates img { max-width: 100%; border-radius: 4px; margin: 8px 0; }

.fr-gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.fr-gallery img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 4px; }
.fr-video { position: relative; padding-top: 56.25%; border-radius: 4px; overflow: hidden; background: #000; }
.fr-video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.fr-facts { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; margin: 0; }
.fr-facts div { background: var(--fr-bg); padding: 12px 14px; border-radius: 4px; }
.fr-facts dt { font-size: 12px; color: var(--fr-muted); font-weight: 600; text-transform: uppercase; letter-spacing: .05em; }
.fr-facts dd { margin: 3px 0 0; color: var(--fr-ink); font-weight: 700; }

/* Forms (auth, join, dashboard) */
.fr-form label { display: block; font-weight: 700; color: #244b49; font-size: 13.5px; margin-bottom: 6px; }
.fr-form .form-control, .fr-form .form-select { min-height: 46px; border-color: #d6e3de; border-radius: 4px; }
.fr-form textarea.form-control { min-height: 100px; }
.fr-form .hint { color: var(--fr-muted); font-size: 12.5px; margin-top: 5px; }
.fr-form .field { margin-bottom: 18px; }
.fr-form .invalid { color: #b42318; font-size: 12.5px; margin-top: 5px; }
.fr-auth { max-width: 520px; margin: -40px auto 0; position: relative; z-index: 2; }

.fr-steps { display: flex; gap: 6px; margin-bottom: 26px; counter-reset: step; flex-wrap: wrap; }
.fr-steps button { flex: 1; min-width: 120px; border: 0; background: var(--fr-bg); color: var(--fr-muted); padding: 12px 10px; font-weight: 700; font-size: 13px; text-align: left; border-bottom: 3px solid transparent; border-radius: 4px 4px 0 0; }
.fr-steps button span { display: block; font-size: 11px; text-transform: uppercase; letter-spacing: .08em; opacity: .8; }
.fr-steps button.active { color: var(--fr-ink); border-bottom-color: var(--fr-orange); background: #fff; }
.fr-steps button.done { color: var(--fr-teal); }
.fr-step { display: none; }
.fr-step.active { display: block; }
.fr-presets { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 14px; }
.fr-presets button { border: 2px solid var(--fr-line); background: #fff; color: var(--fr-ink); padding: 12px 18px; font-weight: 800; border-radius: 4px; }
.fr-presets button.active { border-color: var(--fr-teal); background: var(--fr-mint); color: var(--fr-teal); }
.fr-step-nav { display: flex; justify-content: space-between; gap: 10px; margin-top: 24px; padding-top: 20px; border-top: 1px solid #eef2f0; }
.fr-preview { border: 2px dashed #cfe0da; padding: 18px; border-radius: 6px; background: #fbfdfc; }

/* Dashboard */
.fr-dash-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.fr-dash-card { background: #fff; border: 1px solid var(--fr-line); border-top: 4px solid var(--fr-orange); padding: 24px; border-radius: 4px; }
.fr-dash-card.official { border-top-color: var(--fr-teal); }
.fr-dash-card h2 { font-size: 15px; text-transform: uppercase; letter-spacing: .1em; color: var(--fr-muted); margin-bottom: 4px; }
.fr-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.fr-table th { text-align: left; font-size: 11.5px; text-transform: uppercase; letter-spacing: .06em; color: var(--fr-muted); padding: 10px 8px; border-bottom: 2px solid var(--fr-line); }
.fr-table td { padding: 11px 8px; border-bottom: 1px solid #eef2f0; vertical-align: top; }
.fr-tabs { display: flex; gap: 4px; border-bottom: 2px solid var(--fr-line); margin-bottom: 20px; flex-wrap: wrap; }
.fr-tabs a { padding: 11px 16px; font-weight: 700; color: var(--fr-muted); border-bottom: 3px solid transparent; margin-bottom: -2px; text-decoration: none; }
.fr-tabs a.active, .fr-tabs a:hover { color: var(--fr-ink); border-bottom-color: var(--fr-orange); }

/* Donation modal */
.fr-modal { position: fixed; inset: 0; background: rgba(4,30,29,.62); z-index: 10000; display: none; align-items: flex-start; justify-content: center; padding: 30px 15px; overflow-y: auto; }
.fr-modal.open { display: flex; }
.fr-modal-box { background: #fff; width: 100%; max-width: 560px; border-radius: 6px; overflow: hidden; box-shadow: 0 30px 60px rgba(0,0,0,.3); }
.fr-modal-head { background: var(--fr-ink); color: #fff; padding: 20px 24px; position: relative; }
.fr-modal-head h3 { color: #fff; font-size: 20px; margin: 0 0 4px; padding-right: 30px; }
.fr-modal-head p { color: rgba(255,255,255,.75); margin: 0; font-size: 13.5px; }
.fr-modal-close { position: absolute; right: 16px; top: 14px; background: none; border: 0; color: #fff; font-size: 26px; line-height: 1; cursor: pointer; }
.fr-modal-body { padding: 22px 24px; }
.fr-pay-methods { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 14px; }
.fr-pay-methods label { border: 2px solid var(--fr-line); padding: 10px; text-align: center; border-radius: 4px; cursor: pointer; font-size: 13px; margin: 0; }
.fr-pay-methods input { display: none; }
.fr-pay-methods input:checked + span { color: var(--fr-teal); }
.fr-pay-methods label:has(input:checked) { border-color: var(--fr-teal); background: var(--fr-mint); }
.fr-bank { background: var(--fr-bg); padding: 12px 14px; font-size: 13px; border-radius: 4px; margin-bottom: 8px; }
.fr-bank p { margin: 2px 0; }
.fr-check { display: flex; gap: 8px; align-items: flex-start; font-weight: 500 !important; }
.fr-check input { margin-top: 4px; }

@media (max-width: 992px) {
    .fr-grid, .fr-dash-grid { grid-template-columns: 1fr; }
    .fr-sticky { position: static; }
    .fr-project-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
    .fr-hero { padding: 56px 0 60px; }
    .fr-project-grid, .fr-gallery { grid-template-columns: 1fr; }
    .fr-stats { grid-template-columns: repeat(3, 1fr); }
    .fr-card { padding: 20px; }
    .fr-ambassador-head { flex-direction: column; align-items: flex-start; }
    .fr-facts { grid-template-columns: 1fr; }
}
