@import url('https://fonts.googleapis.com/css2?family=Sora:wght@400;600;700;800&family=DM+Sans:ital,wght@0,400;0,500;0,600;1,400&display=swap');

/* ── Goacle Brand Variables ─────────────────────────────────────────────── */
:root {
  --brand-blue: #00a8e8;
  --brand-green: #5ed000;
  --brand-mid: #00c878;
  --brand-grad: linear-gradient(135deg, #00a8e8 0%, #00c878 50%, #5ed000 100%);
  --brand-grad-text: linear-gradient(90deg, #00a8e8, #5ed000);

  --bg: #f2faf5;
  --surface: #ffffff;
  --surface2: #f5fbf7;
  --text: #09190f;
  --muted: #4a7060;
  --border: #d4ece0;

  --blue: #00a8e8;
  --blue-dark: #007db0;
  --blue-light: #e3f7ff;
  --green: #5ed000;
  --green-dark: #3fa000;
  --green-light: #edfad0;
  --red: #e03c3c;
  --red-light: #fff0f0;
  --gold: #f59e0b;

  --radius: 18px;
  --radius-sm: 10px;
  --shadow: 0 2px 12px rgba(9,25,15,.06), 0 1px 3px rgba(9,25,15,.04);
  --shadow-lg: 0 12px 40px rgba(9,25,15,.10), 0 2px 8px rgba(9,25,15,.06);
  --font-display: 'Sora', sans-serif;
  --font-body: 'DM Sans', sans-serif;
  --nav-h: 68px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: var(--font-body); color: var(--text); background: var(--bg); line-height: 1.6; -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button, input, textarea, select { font: inherit; }

.wrap { width: min(1160px, calc(100% - 48px)); margin: 0 auto; }
.wrap-sm { width: min(580px, calc(100% - 48px)); margin: 0 auto; }
.wrap-md { width: min(800px, calc(100% - 48px)); margin: 0 auto; }

.nav {
  position: sticky; top: 0; z-index: 100;
  height: var(--nav-h);
  background: rgba(242,250,245,.94);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
}
.nav-inner { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.brand { display: flex; align-items: center; gap: 10px; font-family: var(--font-display); font-weight: 800; font-size: 1.3rem; letter-spacing: -.03em; }
.brand-wordmark { background: var(--brand-grad-text); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.brand-logo-svg { width: 38px; height: 38px; flex-shrink: 0; }
.nav-links { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.nav-link { padding: 8px 14px; border-radius: 99px; font-weight: 500; font-size: .92rem; color: var(--muted); transition: color .15s, background .15s; }
.nav-link:hover { color: var(--text); background: rgba(9,25,15,.05); }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; padding: 11px 22px; border-radius: 99px; font-weight: 700; font-size: .92rem; border: 1.5px solid transparent; cursor: pointer; transition: transform .15s, box-shadow .15s, opacity .15s; white-space: nowrap; }
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn-primary { background: var(--brand-grad); color: white; box-shadow: 0 3px 12px rgba(0,168,232,.28); }
.btn-primary:hover { opacity: .9; box-shadow: 0 6px 20px rgba(0,168,232,.35); }
.btn-ghost { background: var(--surface); color: var(--text); border-color: var(--border); }
.btn-ghost:hover { border-color: #90c8a8; }
.btn-danger { background: var(--red); color: white; }
.btn-sm { padding: 8px 16px; font-size: .85rem; }
.btn-xs { padding: 6px 12px; font-size: .8rem; }
.btn-full { width: 100%; }

.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); }
.card-p { padding: 24px; }
.card-p-lg { padding: 32px; }
.card-hover { transition: box-shadow .2s, transform .2s, border-color .2s; }
.card-hover:hover { box-shadow: var(--shadow-lg); transform: translateY(-2px); border-color: #90c8a8; }

.progress-track { height: 10px; background: var(--border); border-radius: 99px; overflow: hidden; }
.progress-bar { height: 100%; border-radius: 99px; background: var(--brand-grad); transition: width .6s ease; }
.progress-bar.full { background: linear-gradient(90deg, var(--brand-mid), var(--brand-green)); }

.badge { display: inline-flex; align-items: center; gap: 5px; padding: 4px 10px; border-radius: 99px; font-size: .78rem; font-weight: 600; }
.badge-blue { background: var(--blue-light); color: var(--blue-dark); }
.badge-green { background: var(--green-light); color: var(--green-dark); }
.badge-gold { background: #fef9eb; color: #b45309; }
.badge-muted { background: var(--surface2); color: var(--muted); }
.badge-red { background: var(--red-light); color: var(--red); }
.badge-brand { background: var(--brand-grad); color: white; }

.avatar { width: 36px; height: 36px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: .82rem; color: white; flex-shrink: 0; font-family: var(--font-display); }
.avatar-sm { width: 28px; height: 28px; font-size: .72rem; }
.avatar-lg { width: 48px; height: 48px; font-size: 1rem; }

.form-group { display: grid; gap: 7px; }
.form-label { font-weight: 600; font-size: .88rem; color: var(--text); }
.form-input, .form-textarea { width: 100%; padding: 12px 16px; border: 1.5px solid var(--border); border-radius: 12px; background: var(--surface); color: var(--text); font-size: .95rem; transition: border-color .15s, box-shadow .15s; outline: none; }
.form-input:focus, .form-textarea:focus { border-color: var(--brand-blue); box-shadow: 0 0 0 3px rgba(0,168,232,.12); }
.form-textarea { resize: vertical; min-height: 90px; }
.form-hint { font-size: .8rem; color: var(--muted); }
.form-grid { display: grid; gap: 18px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }

.flash-list { display: grid; gap: 10px; }
.flash { display: flex; align-items: center; gap: 10px; padding: 13px 18px; border-radius: 12px; font-weight: 500; font-size: .92rem; }
.flash-success { background: var(--green-light); color: var(--green-dark); border: 1px solid #b8e87a; }
.flash-error { background: var(--red-light); color: #a82a2a; border: 1px solid #fcc; }
.flash-icon { font-size: 1rem; flex-shrink: 0; }

.stat { display: grid; gap: 2px; }
.stat-value { font-family: var(--font-display); font-size: 1.6rem; font-weight: 800; line-height: 1; letter-spacing: -.03em; color: var(--text); }
.stat-value.lg { font-size: 2.2rem; }
.stat-value.xl { font-size: 2.8rem; }
.stat-label { font-size: .82rem; color: var(--muted); font-weight: 500; }

.section { padding: 48px 0; }
.section-sm { padding: 28px 0; }
.section-title { font-family: var(--font-display); font-size: 1.1rem; font-weight: 700; letter-spacing: -.02em; color: var(--text); }
.section-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 20px; }

.member-row { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border: 1px solid var(--border); border-radius: 14px; background: var(--surface2); transition: border-color .15s; }
.member-row:hover { border-color: #90c8a8; }
.member-info { flex: 1; min-width: 0; }
.member-name { font-weight: 600; font-size: .95rem; }
.member-sub { font-size: .82rem; color: var(--muted); margin-top: 1px; }

.hero { padding: 80px 0 60px; background: radial-gradient(ellipse 80% 50% at 50% -10%, rgba(0,168,232,.07) 0%, transparent 70%); }
.hero-eyebrow { display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px; border-radius: 99px; background: var(--green-light); color: var(--green-dark); font-weight: 600; font-size: .82rem; border: 1px solid #b8e87a; margin-bottom: 22px; }
.hero-title { font-family: var(--font-display); font-size: clamp(2.4rem, 5vw, 3.8rem); font-weight: 800; line-height: 1.05; letter-spacing: -.04em; color: var(--text); max-width: 700px; margin-bottom: 18px; }
.hero-title .grad { background: var(--brand-grad-text); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.hero-sub { font-size: 1.05rem; color: var(--muted); max-width: 520px; line-height: 1.7; margin-bottom: 32px; }
.hero-actions { display: flex; gap: 10px; flex-wrap: wrap; }

.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.feature-card { padding: 28px; border-radius: var(--radius); border: 1px solid var(--border); background: var(--surface); transition: border-color .2s, box-shadow .2s; }
.feature-card:hover { border-color: #90c8a8; box-shadow: var(--shadow-lg); }
.feature-icon { font-size: 1.8rem; margin-bottom: 14px; }
.feature-title { font-family: var(--font-display); font-weight: 700; font-size: 1rem; margin-bottom: 8px; }
.feature-desc { font-size: .9rem; color: var(--muted); line-height: 1.6; }

.group-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 18px; }
.group-card { display: block; }
.group-card-emoji { font-size: 1.8rem; margin-bottom: 14px; }
.group-card-title { font-family: var(--font-display); font-weight: 700; font-size: 1.05rem; margin-bottom: 6px; }
.group-card-desc { font-size: .88rem; color: var(--muted); margin-bottom: 18px; line-height: 1.5; }
.group-card-meta { display: flex; justify-content: space-between; align-items: center; font-size: .82rem; color: var(--muted); margin-top: 12px; font-weight: 500; }

.page-header-inner { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; flex-wrap: wrap; margin-bottom: 28px; }
.page-title { font-family: var(--font-display); font-size: clamp(1.8rem, 4vw, 2.6rem); font-weight: 800; letter-spacing: -.04em; line-height: 1.1; }
.page-sub { color: var(--muted); margin-top: 6px; font-size: .95rem; }

.dash-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 14px; margin-bottom: 32px; }
.dash-stat { padding: 20px 22px; border-radius: var(--radius); border: 1px solid var(--border); background: var(--surface); }
.dash-stat-icon { font-size: 1.4rem; margin-bottom: 10px; }

.group-detail-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 24px; align-items: start; }
.content-grid { display: grid; gap: 20px; }
.sidebar-grid { display: grid; gap: 20px; }

.contrib-form { background: var(--brand-grad); color: white; border-radius: var(--radius); padding: 26px; box-shadow: 0 4px 20px rgba(0,168,232,.22); }
.contrib-form .form-label { color: rgba(255,255,255,.85); }
.contrib-form .form-input { background: rgba(255,255,255,.18); border-color: rgba(255,255,255,.25); color: white; }
.contrib-form .form-input::placeholder { color: rgba(255,255,255,.55); }
.contrib-form .form-input:focus { border-color: rgba(255,255,255,.7); box-shadow: 0 0 0 3px rgba(255,255,255,.12); }
.contrib-form-title { font-family: var(--font-display); font-weight: 700; font-size: 1.1rem; margin-bottom: 18px; }

.challenge-card { background: linear-gradient(135deg, #071a10, #0d2e1a); color: white; border-radius: var(--radius); padding: 26px; border: 1px solid rgba(94,208,0,.2); }
.challenge-tag { display: inline-flex; padding: 4px 10px; border-radius: 99px; background: rgba(94,208,0,.15); font-size: .78rem; font-weight: 600; color: #9cf04a; margin-bottom: 14px; border: 1px solid rgba(94,208,0,.2); }
.challenge-title { font-family: var(--font-display); font-weight: 800; font-size: 1.15rem; margin-bottom: 8px; color: white; }
.challenge-desc { font-size: .88rem; color: rgba(255,255,255,.6); line-height: 1.6; margin-bottom: 18px; }
.challenge-progress { height: 6px; background: rgba(255,255,255,.1); border-radius: 99px; overflow: hidden; margin: 14px 0; }
.challenge-bar { height: 100%; background: var(--brand-grad); border-radius: 99px; transition: width .5s ease; }
.challenge-meta { display: flex; gap: 16px; font-size: .82rem; color: rgba(255,255,255,.45); flex-wrap: wrap; }

.withdrawal-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 14px 16px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface2); flex-wrap: wrap; }
.status-pill { display: inline-flex; padding: 4px 10px; border-radius: 99px; font-size: .78rem; font-weight: 600; }
.status-pending { background: #fef9eb; color: #b45309; }
.status-approved { background: var(--green-light); color: var(--green-dark); }

.medal { font-size: 1.1rem; width: 26px; text-align: center; flex-shrink: 0; }
.action-row { display: flex; gap: 10px; flex-wrap: wrap; }

.emoji-picker { display: flex; gap: 8px; flex-wrap: wrap; }
.emoji-opt { width: 42px; height: 42px; border-radius: 10px; border: 1.5px solid var(--border); background: var(--surface); cursor: pointer; font-size: 1.3rem; display: flex; align-items: center; justify-content: center; transition: border-color .15s, background .15s; }
.emoji-opt:hover, .emoji-opt.selected { border-color: var(--brand-blue); background: var(--blue-light); }
#emoji-hidden { display: none; }

.auth-wrap { min-height: calc(100vh - var(--nav-h)); display: flex; align-items: center; justify-content: center; padding: 40px 20px; }
.auth-card { width: 100%; max-width: 460px; }
.auth-title { font-family: var(--font-display); font-size: 1.9rem; font-weight: 800; letter-spacing: -.04em; margin-bottom: 6px; }
.auth-sub { color: var(--muted); font-size: .92rem; margin-bottom: 28px; }
.auth-link { font-size: .88rem; color: var(--muted); margin-top: 18px; text-align: center; }
.auth-link a { color: var(--brand-blue); font-weight: 600; }

.text-muted { color: var(--muted); }
.text-sm { font-size: .88rem; }
.text-xs { font-size: .78rem; }
.font-display { font-family: var(--font-display); }
.font-bold { font-weight: 700; }
.font-semibold { font-weight: 600; }
.flex { display: flex; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.stack { display: grid; gap: 12px; }
.stack-sm { display: grid; gap: 8px; }
.stack-lg { display: grid; gap: 20px; }
.gap-sm { gap: 8px; }
.gap-md { gap: 14px; }
.mt-1{margin-top:4px}.mt-2{margin-top:8px}.mt-3{margin-top:14px}.mt-4{margin-top:20px}.mt-6{margin-top:32px}
.mb-1{margin-bottom:4px}.mb-2{margin-bottom:8px}.mb-3{margin-bottom:14px}.mb-4{margin-bottom:20px}.mb-6{margin-bottom:32px}
.w-full { width: 100%; }
.text-center { text-align: center; }
.text-right { text-align: right; }
.empty { padding: 32px; text-align: center; color: var(--muted); font-size: .9rem; }
.empty-icon { font-size: 2rem; margin-bottom: 8px; }

@keyframes fadeUp { from{opacity:0;transform:translateY(14px)} to{opacity:1;transform:translateY(0)} }
.anim-fade-up { animation: fadeUp .4s ease both; }
.anim-delay-1{animation-delay:.05s}.anim-delay-2{animation-delay:.1s}.anim-delay-3{animation-delay:.15s}

@media(max-width:900px){.group-detail-grid{grid-template-columns:1fr}.feature-grid{grid-template-columns:1fr 1fr}}
@media(max-width:640px){.feature-grid{grid-template-columns:1fr}.form-row{grid-template-columns:1fr}.hero{padding:50px 0 40px}.section-header{flex-direction:column;align-items:flex-start}.page-header-inner{flex-direction:column}.wrap{width:calc(100% - 32px)}}
