/* ============================================================
   KEBUN NUSANTARA - Stylesheet utama
   ============================================================ */
:root {
  --sky-1: #9fdcff;
  --sky-2: #e8f7ff;
  --grass-1: #8ed15c;
  --grass-2: #5cae43;
  --grass-3: #3f8a2e;
  --soil-1: #a06a45;
  --soil-2: #7d4e2d;
  --soil-3: #5f3a20;
  --wood-1: #fff8e7;
  --wood-2: #fdeeca;
  --wood-line: #e6cc93;
  --panel: #fffdf6;
  --ink: #2b3a2f;
  --ink-soft: #6b7c6f;
  --green: #4caf50;
  --green-dark: #2f7d27;
  --gold-1: #ffd54d;
  --gold-2: #f5a623;
  --gold-dark: #a16207;
  --gem-1: #b79cff;
  --gem-2: #7c3aed;
  --gem-dark: #5b21b6;
  --rp-1: #34d399;
  --rp-2: #0d9488;
  --rp-dark: #0f766e;
  --red: #ef4444;
  --amber: #f59e0b;
  --blue: #3b82f6;
  --radius: 16px;
  --font-head: 'Baloo 2', 'Nunito', system-ui, sans-serif;
  --font-body: 'Nunito', system-ui, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html { font-size: 16px; }
body {
  font-family: var(--font-body);
  color: var(--ink);
  background: #eef5e9;
  min-height: 100vh;
  overflow-x: hidden;
}
.hidden { display: none !important; }
h1, h2, h3, h4 { font-family: var(--font-head); }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }
input, select { font-family: inherit; font-size: 1rem; }
.num { font-family: var(--font-head); font-variant-numeric: tabular-nums; }

/* ============ Tombol ============ */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--font-head); font-weight: 700; font-size: 1rem;
  padding: 11px 20px; border-radius: 14px; color: #fff;
  background: linear-gradient(180deg, #6ecb51, #46a338);
  box-shadow: 0 4px 0 var(--green-dark), 0 6px 14px rgba(60, 130, 50, .25);
  transition: transform .08s, box-shadow .08s, filter .15s;
  user-select: none;
}
.btn:hover { filter: brightness(1.06); }
.btn:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--green-dark); }
.btn.btn-gold { background: linear-gradient(180deg, var(--gold-1), var(--gold-2)); box-shadow: 0 4px 0 var(--gold-dark), 0 6px 14px rgba(200, 140, 20, .3); color: #4a2c00; }
.btn.btn-gold:active { box-shadow: 0 1px 0 var(--gold-dark); }
.btn.btn-gem { background: linear-gradient(180deg, var(--gem-1), var(--gem-2)); box-shadow: 0 4px 0 var(--gem-dark), 0 6px 14px rgba(120, 70, 230, .3); }
.btn.btn-gem:active { box-shadow: 0 1px 0 var(--gem-dark); }
.btn.btn-ghost { background: #fff; color: var(--ink); box-shadow: 0 3px 0 #d5dcd3, 0 0 0 2px #e2e8e0 inset; }
.btn.btn-ghost:active { box-shadow: 0 1px 0 #d5dcd3; }
.btn.btn-danger { background: linear-gradient(180deg, #f87171, #dc2626); box-shadow: 0 4px 0 #991b1b; }
.btn:disabled { opacity: .5; filter: grayscale(.5); cursor: not-allowed; transform: none; }
.btn-block { width: 100%; }
.btn-sm { padding: 7px 13px; font-size: .86rem; border-radius: 11px; }
.btn-lg { padding: 14px 26px; font-size: 1.12rem; }

.icon-btn {
  width: 38px; height: 38px; border-radius: 12px; font-size: 1.05rem;
  background: #fff; box-shadow: 0 2px 0 #d8dfd5, 0 0 0 2px #e8ede6 inset;
  display: inline-flex; align-items: center; justify-content: center;
}
.icon-btn:active { transform: translateY(2px); box-shadow: none; }

/* ============ Chip mata uang ============ */
.chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 10px 5px 6px; border-radius: 999px;
  font-family: var(--font-head); font-weight: 700; font-size: .95rem;
  background: #fff; box-shadow: 0 2px 0 rgba(0, 0, 0, .12), 0 0 0 2px rgba(255, 255, 255, .6) inset;
  transition: transform .1s;
}
.chip:active { transform: scale(.95); }
.chip .chip-icon { width: 22px; height: 22px; display: inline-flex; }
.chip .chip-icon svg { width: 100%; height: 100%; }
.chip-koin { color: #8a5a00; }
.chip-permata { color: #5b21b6; }
.chip-rupiah { color: #0f766e; }
.chip-plus { font-size: 1.1rem; color: var(--green-dark); margin-left: 2px; }
.chip-value { min-width: 12px; text-align: right; font-variant-numeric: tabular-nums; }
.chip.chip-bump { animation: chipBump .4s cubic-bezier(.34, 1.56, .64, 1); }
@keyframes chipBump { 0% { transform: scale(1); } 40% { transform: scale(1.18); } 100% { transform: scale(1); } }

/* ============ Layar login ============ */
#auth-screen {
  position: fixed; inset: 0; display: flex; align-items: center; justify-content: center;
  padding: 20px; overflow: auto;
}
#auth-hero { position: absolute; inset: 0; }
#auth-hero svg { width: 100%; height: 100%; object-fit: cover; display: block; }
.auth-card {
  position: relative; z-index: 2; width: 100%; max-width: 400px;
  background: rgba(255, 253, 246, .96); backdrop-filter: blur(6px);
  border-radius: 24px; padding: 26px 26px 20px;
  box-shadow: 0 24px 60px rgba(30, 60, 40, .35), 0 0 0 3px rgba(255, 255, 255, .35);
  animation: popIn .5s cubic-bezier(.34, 1.4, .64, 1);
}
.brand-logo { width: 84px; height: 84px; margin: -64px auto 6px; filter: drop-shadow(0 6px 10px rgba(0, 0, 0, .25)); }
.brand-logo svg { width: 100%; height: 100%; }
.brand-title { text-align: center; font-size: 1.9rem; font-weight: 800; color: #24512c; letter-spacing: .5px; text-shadow: 0 2px 0 rgba(255, 255, 255, .7); }
.brand-tagline { text-align: center; color: var(--ink-soft); font-weight: 700; margin: 2px 0 16px; font-size: .95rem; }
.auth-tabs { display: flex; background: #eef3ea; border-radius: 14px; padding: 4px; margin-bottom: 16px; }
.auth-tab {
  flex: 1; padding: 9px; border-radius: 11px; font-family: var(--font-head);
  font-weight: 700; font-size: 1rem; color: var(--ink-soft); transition: all .2s;
}
.auth-tab.active { background: #fff; color: var(--green-dark); box-shadow: 0 2px 6px rgba(0, 0, 0, .12); }
.field { display: block; margin-bottom: 12px; }
.field span { display: block; font-weight: 800; font-size: .85rem; margin-bottom: 5px; color: var(--ink-soft); }
.field input {
  width: 100%; padding: 11px 14px; border-radius: 12px; border: 2px solid #dfe8da;
  background: #fff; outline: none; transition: border .15s, box-shadow .15s;
}
.field input:focus { border-color: var(--green); box-shadow: 0 0 0 4px rgba(76, 175, 80, .15); }
.auth-error { background: #fdecec; color: #b91c1c; border-radius: 10px; padding: 9px 12px; font-size: .86rem; font-weight: 700; margin-bottom: 10px; }
.auth-divider { display: flex; align-items: center; gap: 10px; margin: 14px 0; color: #a9b6a5; font-weight: 800; font-size: .8rem; }
.auth-divider::before, .auth-divider::after { content: ''; flex: 1; height: 2px; background: #e7eee3; border-radius: 2px; }
.auth-note { text-align: center; font-size: .74rem; color: #9aa895; margin-top: 12px; font-weight: 600; }

/* ============ HUD ============ */
#app { max-width: 1060px; margin: 0 auto; padding: 0 12px 96px; }
#hud {
  position: sticky; top: 0; z-index: 40;
  margin: 0 -12px 14px; padding: 10px 14px;
  background: linear-gradient(180deg, var(--wood-1), var(--wood-2));
  border-bottom: 3px solid var(--wood-line);
  border-radius: 0 0 18px 18px;
  box-shadow: 0 6px 18px rgba(120, 90, 30, .12);
  display: grid; align-items: center; gap: 9px 12px;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas:
    "left actions"
    "currencies currencies";
}
.hud-left { grid-area: left; display: flex; align-items: center; gap: 10px; min-width: 0; }
.avatar {
  width: 44px; height: 44px; border-radius: 14px; flex: none;
  background: linear-gradient(160deg, #7ed957, #2f8f4a);
  color: #fff; font-family: var(--font-head); font-weight: 800; font-size: 1.3rem;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 3px 0 #2a6b39, 0 0 0 3px #fff inset;
}
.hud-player { flex: 1; min-width: 0; }
.hud-name { font-family: var(--font-head); font-weight: 700; font-size: 1rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 150px; }
.hud-level { display: flex; align-items: center; gap: 6px; margin-top: 3px; }
.lvl-badge {
  font-family: var(--font-head); font-weight: 800; font-size: .72rem; flex: none;
  background: linear-gradient(180deg, #ffe08a, #f6b73c); color: #6b4200;
  padding: 1px 8px; border-radius: 999px; box-shadow: 0 2px 0 #c98f1f;
}
.xpbar { flex: 1; max-width: 132px; height: 7px; background: #eadfc0; border-radius: 99px; overflow: hidden; }
.xpbar-fill { height: 100%; width: 0; background: linear-gradient(90deg, #8dd35f, #4caf50); border-radius: 99px; transition: width .5s; }
.hud-currencies { grid-area: currencies; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 7px; }
.hud-currencies .chip { width: 100%; justify-content: center; }
.hud-actions { grid-area: actions; display: flex; align-items: center; gap: 7px; }
.icon-btn .ib-ico { display: flex; }
.icon-btn .ib-ico svg { width: 22px; height: 22px; display: block; }

/* Layar lebar: kembali ke satu baris yang rapi */
@media (min-width: 700px) {
  #hud {
    grid-template-columns: auto minmax(0, 1fr) auto;
    grid-template-areas: "left currencies actions";
  }
  .hud-currencies { display: flex; justify-self: end; align-items: center; }
  .hud-currencies .chip { width: auto; }
  .hud-actions { padding-left: 11px; border-left: 2px solid rgba(120, 90, 30, .16); }
  .xpbar { min-width: 84px; max-width: 150px; }
}

/* ============ Navigasi bawah ============ */
#nav {
  position: fixed; bottom: 0; left: 50%; transform: translateX(-50%);
  width: min(1060px, calc(100% - 16px)); z-index: 40;
  display: flex; justify-content: space-around; gap: 2px;
  background: rgba(255, 255, 255, .97); backdrop-filter: blur(8px);
  border-radius: 18px 18px 0 0; padding: 7px 8px calc(7px + env(safe-area-inset-bottom));
  box-shadow: 0 -8px 26px rgba(50, 80, 50, .16);
}
.nav-btn {
  position: relative; display: flex; flex-direction: column; align-items: center; gap: 2px;
  padding: 6px 10px; border-radius: 13px; color: #8d9a8a; font-size: .68rem; font-weight: 800;
  font-family: var(--font-head); transition: all .18s; min-width: 52px;
}
.nav-btn .nav-icon { width: 24px; height: 24px; }
.nav-btn .nav-icon svg { width: 100%; height: 100%; }
.nav-btn.active { color: var(--green-dark); background: #eaf7e4; }
.nav-btn.active .nav-icon { transform: translateY(-2px); }
.nav-badge {
  position: absolute; top: 2px; right: 8px; width: 17px; height: 17px;
  background: #ef4444; color: #fff; border-radius: 50%; font-size: .68rem;
  display: flex; align-items: center; justify-content: center; box-shadow: 0 0 0 2px #fff;
  animation: pulse 1.4s infinite;
}
@keyframes pulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.15); } }

/* ============ Kartu & layout umum ============ */
.card {
  background: var(--panel); border-radius: var(--radius);
  box-shadow: 0 3px 0 rgba(140, 160, 130, .25), 0 10px 26px rgba(90, 120, 80, .10);
  padding: 16px; margin-bottom: 14px;
}
.card h3.card-title {
  font-size: 1.12rem; font-weight: 800; display: flex; align-items: center; gap: 8px;
  margin-bottom: 12px; color: #2c4a30;
}
.card-title .card-title-icon { width: 24px; height: 24px; }
.card-title .card-title-icon svg { width: 100%; height: 100%; }
.section-sub { color: var(--ink-soft); font-size: .86rem; font-weight: 600; margin: -6px 0 12px; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.row { display: flex; align-items: center; gap: 10px; }
.row-between { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.muted { color: var(--ink-soft); }
.small { font-size: .84rem; }
.big-num { font-family: var(--font-head); font-weight: 800; font-size: 1.6rem; }

/* ============ Pemandangan kebun ============ */
.farm-scene {
  position: relative; border-radius: 22px; overflow: hidden;
  box-shadow: 0 10px 30px rgba(70, 110, 60, .22), 0 3px 0 rgba(120, 150, 100, .3);
  margin-bottom: 14px;
}
.farm-sky {
  position: relative; height: 128px;
  background: linear-gradient(180deg, var(--sky-1) 0%, var(--sky-2) 78%, #fefce8 100%);
  overflow: hidden;
}
.farm-sun { position: absolute; top: 14px; left: 22px; width: 74px; height: 74px; animation: sunPulse 5s ease-in-out infinite; }
@keyframes sunPulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.08); } }
.farm-cloud { position: absolute; opacity: .95; }
.farm-cloud.c1 { top: 16px; width: 110px; animation: drift 38s linear infinite; }
.farm-cloud.c2 { top: 52px; width: 76px; animation: drift 55s linear infinite; animation-delay: -20s; }
.farm-cloud.c3 { top: 34px; width: 92px; animation: drift 46s linear infinite; animation-delay: -33s; }
@keyframes drift { from { transform: translateX(-130px); } to { transform: translateX(1100px); } }
.farm-hills { position: absolute; bottom: -2px; left: 0; width: 100%; height: 64px; }
.farm-hills svg { width: 100%; height: 100%; display: block; }
.farm-field {
  position: relative; padding: 18px 16px 20px;
  background:
    radial-gradient(circle at 20% 0%, rgba(255, 255, 255, .16), transparent 55%),
    linear-gradient(180deg, var(--grass-1), var(--grass-2) 60%, var(--grass-3));
}
.farm-field::before {
  content: ''; position: absolute; inset: 0; opacity: .25; pointer-events: none;
  background-image: radial-gradient(#2d6b22 1px, transparent 1.4px);
  background-size: 18px 18px;
}
.plot-grid {
  position: relative; display: grid; gap: 12px;
  grid-template-columns: repeat(auto-fill, minmax(118px, 1fr));
  max-width: 760px; margin: 0 auto;
}
.plot {
  position: relative; aspect-ratio: 1; border-radius: 16px; cursor: pointer;
  background:
    radial-gradient(circle at 30% 22%, rgba(0, 0, 0, .12), transparent 42%),
    repeating-linear-gradient(0deg, var(--soil-1) 0 7px, var(--soil-2) 7px 14px);
  box-shadow: inset 0 4px 10px rgba(0, 0, 0, .3), 0 5px 0 var(--soil-3), 0 8px 14px rgba(0, 0, 0, .18);
  transition: transform .12s, box-shadow .12s;
  overflow: hidden;
}
.plot:hover { transform: translateY(-3px); }
.plot:active { transform: translateY(1px); }
.plot.empty { background:
    radial-gradient(circle at 30% 22%, rgba(0, 0, 0, .1), transparent 42%),
    repeating-linear-gradient(0deg, #96613d 0 7px, #74472a 7px 14px); }
.plot.empty::after {
  content: '+'; position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  font-family: var(--font-head); font-size: 2rem; font-weight: 700; color: rgba(255, 255, 255, .35);
}
.plot .crop-art {
  position: absolute; left: 50%; bottom: 12%; width: 74%; height: 74%;
  transform: translateX(-50%) scale(var(--crop-scale, 1));
  transform-origin: bottom center; transition: transform .4s cubic-bezier(.34, 1.3, .64, 1);
  animation: sway 3.2s ease-in-out infinite;
}
.plot .crop-art svg { width: 100%; height: 100%; display: block; filter: drop-shadow(0 3px 2px rgba(0, 0, 0, .22)); }
@keyframes sway { 0%, 100% { rotate: -2deg; } 50% { rotate: 2.5deg; } }
.plot.ready { animation: readyGlow 1.1s ease-in-out infinite; }
@keyframes readyGlow {
  0%, 100% { box-shadow: inset 0 4px 10px rgba(0, 0, 0, .3), 0 5px 0 var(--soil-3), 0 0 0 3px #ffe57a, 0 0 22px rgba(255, 214, 80, .85); }
  50% { box-shadow: inset 0 4px 10px rgba(0, 0, 0, .3), 0 5px 0 var(--soil-3), 0 0 0 5px #fff2a8, 0 0 34px rgba(255, 224, 100, 1); }
}
.plot .plot-progress {
  position: absolute; left: 10px; right: 10px; bottom: 8px; height: 7px;
  background: rgba(0, 0, 0, .4); border-radius: 99px; overflow: hidden;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, .4);
}
.plot .plot-progress .fill { height: 100%; width: 0%; background: linear-gradient(90deg, #a3e635, #22c55e); border-radius: 99px; transition: width .25s linear; }
.plot .plot-badge {
  position: absolute; top: 7px; right: 7px; min-width: 26px; height: 26px; padding: 0 5px;
  border-radius: 9px; display: flex; align-items: center; justify-content: center; gap: 3px;
  background: rgba(255, 255, 255, .94); font-family: var(--font-head); font-weight: 800; font-size: .66rem;
  box-shadow: 0 2px 5px rgba(0, 0, 0, .25); color: #33413a;
}
.plot .plot-badge svg { width: 15px; height: 15px; }
.plot .plot-badge.badge-need-water { background: #3b82f6; color: #fff; animation: pulse 1.2s infinite; }
.plot .plot-badge.badge-ready { background: linear-gradient(180deg, #ffe57a, #fbbf24); color: #6b4200; animation: pulse 1s infinite; }
.plot .plot-fert { position: absolute; top: 7px; left: 7px; width: 24px; height: 24px; background: rgba(255,255,255,.92); border-radius: 8px; display: flex; align-items: center; justify-content: center; box-shadow: 0 2px 5px rgba(0,0,0,.2); }
.plot .plot-fert svg { width: 16px; height: 16px; }
.plot.ripple::before {
  content: ''; position: absolute; inset: -40%; z-index: 3; pointer-events: none;
  background: radial-gradient(circle, rgba(96, 165, 250, .55) 0%, transparent 62%);
  animation: ripple .8s ease-out forwards;
}
@keyframes ripple { from { transform: scale(.2); opacity: 1; } to { transform: scale(1.1); opacity: 0; } }
.plot .sparkle-overlay { position: absolute; inset: 0; pointer-events: none; }

/* Kartu info kecil di atas kebun */
.stat-strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 14px; }
.stat-card {
  background: var(--panel); border-radius: 15px; padding: 10px 12px;
  box-shadow: 0 3px 0 rgba(140, 160, 130, .25); text-align: center;
}
.stat-card .stat-label { font-size: .72rem; font-weight: 800; color: var(--ink-soft); text-transform: uppercase; letter-spacing: .4px; }
.stat-card .stat-value { font-family: var(--font-head); font-weight: 800; font-size: 1.15rem; margin-top: 2px; }
.stat-card .stat-value.gold { color: #b45309; }
.stat-card .stat-value.gem { color: var(--gem-dark); }
.stat-card .stat-value.rp { color: var(--rp-dark); }
.mini-progress { height: 6px; background: #eee7d8; border-radius: 99px; overflow: hidden; margin-top: 6px; }
.mini-progress .fill { height: 100%; background: linear-gradient(90deg, var(--gem-1), var(--gem-2)); border-radius: 99px; transition: width .4s; }

/* ============ Daftar item umum (toko, paket topup, misi) ============ */
.item-card {
  display: flex; gap: 12px; align-items: center;
  background: #fff; border-radius: 15px; padding: 12px;
  box-shadow: 0 3px 0 rgba(140, 160, 130, .22); margin-bottom: 10px;
  border: 2px solid transparent; transition: border .15s, transform .12s;
}
.item-card:hover { transform: translateY(-1px); }
.item-card.locked { filter: grayscale(.55); opacity: .85; }
.item-art { width: 58px; height: 58px; flex: none; display: flex; align-items: center; justify-content: center; }
.item-art svg { width: 100%; height: 100%; }
.item-body { flex: 1; min-width: 0; }
.item-name { font-family: var(--font-head); font-weight: 800; font-size: 1.02rem; }
.item-desc { font-size: .8rem; color: var(--ink-soft); font-weight: 600; margin-top: 1px; }
.item-meta { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 5px; }
.meta-pill {
  font-size: .72rem; font-weight: 800; padding: 2px 8px; border-radius: 999px;
  background: #eef3ea; color: #4b5d4c; display: inline-flex; align-items: center; gap: 4px;
}
.meta-pill.gold { background: #fef3c7; color: #92400e; }
.meta-pill.gem { background: #ede9fe; color: #5b21b6; }
.meta-pill.blue { background: #dbeafe; color: #1d4ed8; }
.meta-pill.red { background: #fee2e2; color: #b91c1c; }
.item-action { flex: none; text-align: right; }

/* ============ Modal ============ */
#modal-root .modal-overlay {
  position: fixed; inset: 0; z-index: 80; background: rgba(24, 38, 28, .55);
  backdrop-filter: blur(3px); display: flex; align-items: center; justify-content: center;
  padding: 16px; animation: fadeIn .18s ease-out;
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.modal {
  width: 100%; max-width: 420px; max-height: 88vh; overflow-y: auto;
  background: var(--panel); border-radius: 22px; padding: 20px;
  box-shadow: 0 24px 70px rgba(0, 0, 0, .45), 0 0 0 4px rgba(255, 255, 255, .18);
  animation: popIn .32s cubic-bezier(.34, 1.5, .64, 1);
}
@keyframes popIn { from { transform: scale(.88) translateY(14px); opacity: 0; } to { transform: scale(1) translateY(0); opacity: 1; } }
.modal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.modal-title { font-family: var(--font-head); font-weight: 800; font-size: 1.25rem; color: #2c4a30; }
.modal-x { width: 34px; height: 34px; border-radius: 11px; background: #eef3ea; font-weight: 800; color: #5c6b5e; font-size: 1rem; }
.modal-x:hover { background: #e2ebdd; }
.modal-actions { display: flex; gap: 10px; margin-top: 16px; }
.modal-actions .btn { flex: 1; }

/* seed picker */
.seed-row { align-items: stretch; }
.seed-stats { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 6px; }
.seed-lock-msg { font-size: .78rem; font-weight: 800; color: #b45309; margin-top: 6px; }

/* form */
.form-row { margin-bottom: 12px; }
.form-row label { display: block; font-weight: 800; font-size: .85rem; color: var(--ink-soft); margin-bottom: 5px; }
.form-row input, .form-row select {
  width: 100%; padding: 11px 13px; border-radius: 12px; border: 2px solid #dfe8da;
  background: #fff; outline: none; font-weight: 700;
}
.form-row input:focus, .form-row select:focus { border-color: var(--green); box-shadow: 0 0 0 4px rgba(76, 175, 80, .13); }
.quick-amounts { display: flex; gap: 7px; flex-wrap: wrap; margin-top: 7px; }
.quick-btn {
  padding: 5px 11px; border-radius: 999px; background: #eef3ea; font-weight: 800; font-size: .8rem; color: #44584a;
}
.quick-btn:hover { background: #dff0d8; color: var(--green-dark); }

/* metode pembayaran */
.method-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; }
.method-card {
  border: 2px solid #e4ecdf; border-radius: 14px; padding: 10px 6px; text-align: center;
  background: #fff; transition: all .15s;
}
.method-card .method-icon { width: 40px; height: 40px; margin: 0 auto 5px; }
.method-card .method-icon svg { width: 100%; height: 100%; }
.method-card .method-name { font-size: .72rem; font-weight: 800; color: #44584a; line-height: 1.15; }
.method-card.active { border-color: var(--green); background: #f2fbee; box-shadow: 0 0 0 3px rgba(76, 175, 80, .16); }

/* QR pembayaran */
.qr-box { text-align: center; padding: 14px; background: #fff; border-radius: 16px; border: 2px dashed #d9e4d3; margin: 12px 0; }
.qr-box svg { width: 190px; height: 190px; }
.qr-label { font-weight: 800; font-size: .82rem; color: #92400e; background: #fef3c7; display: inline-block; padding: 3px 10px; border-radius: 999px; margin-top: 8px; }
.va-number {
  font-family: var(--font-head); font-weight: 800; font-size: 1.5rem; letter-spacing: 2px;
  color: #1e3a8a; background: #eff6ff; padding: 12px; border-radius: 12px; margin: 10px 0;
  display: flex; align-items: center; justify-content: center; gap: 10px;
}
.countdown { font-family: var(--font-head); font-weight: 800; color: #b91c1c; }
.countdown .cd-box { background: #fee2e2; padding: 2px 8px; border-radius: 8px; }

/* pembayaran sukses */
.pay-success { text-align: center; padding: 10px 0; }
.pay-success .check-circle { width: 92px; height: 92px; margin: 0 auto 10px; animation: popIn .4s cubic-bezier(.34, 1.6, .64, 1); }

/* ============ Dompet: kartu saldo ============ */
.balance-card {
  background: linear-gradient(135deg, #0f766e, #14b8a6 55%, #34d399);
  color: #fff; border-radius: 20px; padding: 20px;
  box-shadow: 0 8px 0 #0b5c55, 0 14px 30px rgba(15, 118, 110, .35);
  position: relative; overflow: hidden;
}
.balance-card::after {
  content: ''; position: absolute; right: -30px; top: -40px; width: 170px; height: 170px;
  border-radius: 50%; background: rgba(255, 255, 255, .12);
}
.balance-card .bc-label { font-weight: 800; font-size: .8rem; letter-spacing: 1px; text-transform: uppercase; opacity: .85; }
.balance-card .bc-value { font-family: var(--font-head); font-weight: 800; font-size: 2.3rem; margin: 2px 0 8px; text-shadow: 0 3px 0 rgba(0, 0, 0, .15); }
.balance-card .bc-sub { display: flex; gap: 14px; font-weight: 700; font-size: .82rem; opacity: .95; flex-wrap: wrap; }

/* withdraw status */
.status-chip {
  display: inline-flex; align-items: center; gap: 5px; padding: 3px 10px; border-radius: 999px;
  font-weight: 800; font-size: .74rem;
}
.status-chip.menunggu { background: #fef3c7; color: #92400e; }
.status-chip.diproses { background: #dbeafe; color: #1d4ed8; }
.status-chip.berhasil, .status-chip.sukses { background: #d1fae5; color: #047857; }
.status-chip.gagal { background: #fee2e2; color: #b91c1c; }
.status-dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.status-chip.menunggu .status-dot, .status-chip.diproses .status-dot { animation: pulse 1.2s infinite; }

.wd-item {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 11px 12px; background: #fff; border-radius: 14px; margin-bottom: 9px;
  box-shadow: 0 3px 0 rgba(140, 160, 130, .2);
}
.wd-main { min-width: 0; }
.wd-amount { font-family: var(--font-head); font-weight: 800; font-size: 1.05rem; }
.wd-sub { font-size: .76rem; color: var(--ink-soft); font-weight: 700; }

/* ============ Riwayat transaksi ============ */
.filter-chips { display: flex; gap: 7px; flex-wrap: wrap; margin-bottom: 13px; }
.filter-chip {
  padding: 6px 13px; border-radius: 999px; background: #fff; font-weight: 800; font-size: .8rem;
  color: #5c6b5e; box-shadow: 0 2px 0 rgba(140, 160, 130, .25); transition: all .15s;
}
.filter-chip.active { background: var(--green-dark); color: #fff; box-shadow: 0 2px 0 #1e5c18; }
.tx-item {
  display: flex; align-items: center; gap: 11px; padding: 10px 12px;
  background: #fff; border-radius: 14px; margin-bottom: 8px; box-shadow: 0 3px 0 rgba(140, 160, 130, .18);
}
.tx-icon { width: 40px; height: 40px; flex: none; border-radius: 12px; display: flex; align-items: center; justify-content: center; }
.tx-icon svg { width: 26px; height: 26px; }
.tx-icon.t-koin { background: #fef3c7; }
.tx-icon.t-permata { background: #ede9fe; }
.tx-icon.t-rupiah { background: #ccfbf1; }
.tx-body { flex: 1; min-width: 0; }
.tx-note { font-weight: 800; font-size: .86rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tx-time { font-size: .72rem; color: var(--ink-soft); font-weight: 700; }
.tx-amount { font-family: var(--font-head); font-weight: 800; font-size: .98rem; white-space: nowrap; }
.tx-amount.plus { color: #047857; }
.tx-amount.minus { color: #b91c1c; }
.tx-balance { font-size: .68rem; color: var(--ink-soft); font-weight: 700; text-align: right; }

/* ============ Toast & efek ============ */
#toast-root { position: fixed; bottom: 86px; left: 50%; transform: translateX(-50%); z-index: 95; display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; width: min(92vw, 420px); }
.toast {
  background: rgba(28, 40, 30, .93); color: #fff; padding: 10px 16px; border-radius: 14px;
  font-weight: 700; font-size: .88rem; display: flex; gap: 8px; align-items: center;
  box-shadow: 0 10px 26px rgba(0, 0, 0, .35); animation: toastIn .3s cubic-bezier(.34, 1.4, .64, 1);
  max-width: 100%; text-align: left;
}
.toast.t-success { background: rgba(22, 101, 52, .95); }
.toast.t-error { background: rgba(153, 27, 27, .95); }
.toast.t-info { background: rgba(30, 64, 175, .95); }
.toast.hide { animation: toastOut .25s ease-in forwards; }
@keyframes toastIn { from { transform: translateY(16px) scale(.92); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes toastOut { to { transform: translateY(12px); opacity: 0; } }

#fx-root { position: fixed; inset: 0; pointer-events: none; z-index: 90; overflow: hidden; }
.fx-float {
  position: absolute; font-family: var(--font-head); font-weight: 800; font-size: 1.15rem;
  text-shadow: 0 2px 0 rgba(0, 0, 0, .25); animation: floatUp 1.1s ease-out forwards; white-space: nowrap;
}
@keyframes floatUp { from { transform: translateY(0) scale(.8); opacity: 0; } 25% { opacity: 1; transform: translateY(-14px) scale(1.08); } to { transform: translateY(-64px) scale(1); opacity: 0; } }
.fx-coin { position: absolute; width: 30px; height: 30px; z-index: 91; }
.fx-coin svg { width: 100%; height: 100%; }
.fx-sparkle { position: absolute; animation: sparkle 0.9s ease-out forwards; }
@keyframes sparkle { from { transform: scale(0) rotate(0deg); opacity: 1; } 60% { opacity: 1; } to { transform: scale(1.25) rotate(160deg); opacity: 0; } }
.fx-confetti { position: absolute; width: 9px; height: 14px; border-radius: 3px; animation: confettiFall linear forwards; }
@keyframes confettiFall {
  from { transform: translateY(-30px) rotate(0deg); opacity: 1; }
  to { transform: translateY(105vh) rotate(760deg); opacity: .6; }
}
.fx-ping { position: absolute; border-radius: 50%; border: 3px solid #ffe57a; animation: ping .7s ease-out forwards; }
@keyframes ping { from { transform: scale(.3); opacity: 1; } to { transform: scale(1.9); opacity: 0; } }

/* ============ Kartu info khusus ============ */
.info-banner {
  display: flex; gap: 12px; align-items: center; padding: 13px 15px; border-radius: 16px;
  background: linear-gradient(120deg, #ecfdf5, #d1fae5); border: 2px solid #a7f3d0;
  color: #065f46; font-weight: 700; font-size: .86rem; margin-bottom: 14px;
}
.info-banner.amber { background: linear-gradient(120deg, #fffbeb, #fef3c7); border-color: #fde68a; color: #92400e; }
.info-banner.blue { background: linear-gradient(120deg, #eff6ff, #dbeafe); border-color: #bfdbfe; color: #1e40af; }
.info-banner .ib-icon { width: 34px; height: 34px; flex: none; }
.info-banner .ib-icon svg { width: 100%; height: 100%; }

.promo-banner {
  position: relative; border-radius: 18px; overflow: hidden; margin-bottom: 14px;
  background: linear-gradient(120deg, #065f46, #059669 55%, #34d399);
  padding: 16px 120px 16px 18px; color: #fff; min-height: 96px;
  box-shadow: 0 5px 0 #044e3a, 0 12px 26px rgba(6, 95, 70, .3);
}
.promo-banner h3 { font-size: 1.25rem; margin-bottom: 2px; }
.promo-banner p { font-size: .84rem; opacity: .92; font-weight: 600; }
.promo-art { position: absolute; right: -6px; top: 50%; transform: translateY(-50%); width: 130px; height: 130px; }

/* quest card */
.quest-card { display: flex; align-items: center; gap: 12px; background: #fff; border-radius: 15px; padding: 12px; box-shadow: 0 3px 0 rgba(140,160,130,.22); margin-bottom: 10px; }
.quest-icon { width: 46px; height: 46px; flex: none; border-radius: 13px; background: #eef3ea; display: flex; align-items: center; justify-content: center; }
.quest-icon svg { width: 30px; height: 30px; }
.quest-body { flex: 1; min-width: 0; }
.quest-name { font-family: var(--font-head); font-weight: 800; font-size: .98rem; }
.quest-reward { display: flex; gap: 6px; margin-top: 4px; flex-wrap: wrap; }
.quest-done .quest-name { color: #047857; }
.quest-claimed { opacity: .6; }

/* empty state */
.empty-state { text-align: center; padding: 34px 16px; color: var(--ink-soft); font-weight: 700; }
.empty-state .es-art { width: 90px; height: 90px; margin: 0 auto 10px; opacity: .8; }

/* ============ Responsif ============ */
@media (max-width: 720px) {
  html { font-size: 15px; }
  .hud-name { max-width: 110px; }
  .xpbar { max-width: 110px; }
  .chip { font-size: .82rem; padding: 4px 8px 4px 5px; }
  .chip .chip-icon { width: 18px; height: 18px; }
  .stat-strip { grid-template-columns: repeat(3, 1fr); gap: 7px; }
  .stat-card { padding: 8px 6px; }
  .stat-card .stat-value { font-size: .95rem; }
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .method-grid { grid-template-columns: repeat(3, 1fr); }
  .promo-banner { padding-right: 92px; }
  .promo-art { width: 96px; height: 96px; }
}
@media (max-width: 420px) {
  .nav-btn { min-width: 46px; padding: 5px 6px; font-size: .62rem; }
  .hud-actions { gap: 5px; }
  .hud-currencies { gap: 5px; }
  .icon-btn { width: 34px; height: 34px; }
  .plot-grid { grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 9px; }
}

/* ============================================================
   V2 - Peningkatan visual: dekorasi kebun, ranking, undangan,
   menu lainnya, panel admin, dan polesan layar login
   ============================================================ */

/* ============ Dekorasi kebun ============ */
.farm-field { padding-top: 34px; }
.farm-fence { position: absolute; top: 0; left: 0; width: 100%; height: 26px; opacity: .96; pointer-events: none; }
.farm-windmill { position: absolute; right: 26px; bottom: 6px; width: 62px; height: 78px; filter: drop-shadow(0 4px 5px rgba(40, 80, 30, .25)); }
.windmill-blades { transform-origin: 40px 32px; transform-box: view-box; animation: millSpin 9s linear infinite; }
@keyframes millSpin { to { transform: rotate(360deg); } }
.farm-birds { position: absolute; top: 12px; right: 16%; width: 84px; opacity: .8; animation: birdGlide 13s ease-in-out infinite; }
@keyframes birdGlide { 0%, 100% { transform: translate(0, 0); } 50% { transform: translate(-34px, -7px); } }
.farm-scarecrow { position: absolute; bottom: 8px; right: 10px; width: 52px; opacity: .95; pointer-events: none; }
.farm-butterfly { position: absolute; width: 22px; height: 22px; pointer-events: none; opacity: .9; }
.farm-butterfly svg { width: 100%; height: 100%; display: block; }
.farm-butterfly.b1 { top: 42px; left: 12%; animation: flutter1 11s ease-in-out infinite; }
.farm-butterfly.b2 { top: 46%; left: 82%; animation: flutter2 14s ease-in-out infinite; }
@keyframes flutter1 { 0%, 100% { transform: translate(0, 0) rotate(0); } 30% { transform: translate(46px, -26px) rotate(9deg); } 60% { transform: translate(10px, 22px) rotate(-7deg); } }
@keyframes flutter2 { 0%, 100% { transform: translate(0, 0) rotate(0); } 40% { transform: translate(-54px, 18px) rotate(-10deg); } 70% { transform: translate(-16px, -24px) rotate(8deg); } }
.sign-wrap { position: absolute; top: 2px; right: 14px; width: 138px; pointer-events: none; transform: rotate(-2deg); filter: drop-shadow(0 3px 3px rgba(60, 40, 10, .25)); }
.sign-wrap svg { width: 100%; height: auto; display: block; }
.plot-num { position: absolute; top: 5px; left: 7px; font-family: var(--font-head); font-weight: 800; font-size: .62rem; color: rgba(255, 255, 255, .88); background: rgba(0, 0, 0, .22); padding: 1px 6px; border-radius: 999px; pointer-events: none; }

/* ============ HUD: baris nama pemain ============ */
.hud-name-row { display: flex; align-items: center; gap: 5px; min-width: 0; }

/* ============ Layar login: kunang-kunang + fitur + undangan ============ */
#hero-fx { position: absolute; inset: 0; pointer-events: none; overflow: hidden; z-index: 1; }
.firefly { position: absolute; width: 7px; height: 7px; border-radius: 50%; background: radial-gradient(circle, #fffbe0, #ffe066 55%, rgba(255, 224, 102, 0) 78%); box-shadow: 0 0 10px 3px rgba(255, 232, 130, .75); opacity: 0; animation: fireflyFloat 6s ease-in-out infinite; }
@keyframes fireflyFloat {
  0%, 100% { opacity: 0; transform: translate(0, 0) scale(.6); }
  18% { opacity: .95; }
  45% { opacity: .3; transform: translate(7px, -15px) scale(1.05); }
  72% { opacity: .85; transform: translate(-5px, -26px) scale(.9); }
}
.field-opt { font-style: normal; color: var(--ink-soft); font-weight: 700; font-size: .78rem; }
.invite-note { display: flex; align-items: center; gap: 8px; background: #ecfdf5; border: 2px solid #a7f3d0; color: #065f46; font-weight: 700; font-size: .82rem; border-radius: 12px; padding: 9px 12px; margin: 2px 0 10px; }
.invite-note svg { width: 20px; height: 20px; flex: none; }
.auth-feats { display: flex; gap: 6px; margin-top: 12px; }
.afeat { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 4px; background: #f3f7ef; border: 2px solid #e2ecdc; border-radius: 12px; padding: 8px 4px; font-size: .68rem; font-weight: 800; color: #44584a; text-align: center; line-height: 1.15; }
.afeat .af-ico { width: 22px; height: 22px; }
.afeat .af-ico svg { width: 100%; height: 100%; }

/* ============ Ranking global ============ */
.rank-hero { display: flex; align-items: center; gap: 14px; background: linear-gradient(120deg, #1e3a8a, #3b82f6 60%, #60a5fa); color: #fff; border-radius: 18px; padding: 16px 18px; margin-bottom: 14px; box-shadow: 0 5px 0 #1e40af, 0 12px 26px rgba(30, 64, 175, .3); }
.rank-hero-art { width: 56px; height: 56px; flex: none; filter: drop-shadow(0 4px 6px rgba(0, 0, 0, .25)); }
.rank-hero-art svg { width: 100%; height: 100%; }
.rank-hero h2 { font-size: 1.4rem; }
.rank-hero p { font-size: .84rem; font-weight: 700; opacity: .92; }
.rank-tabs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 12px; }
.rank-tab { display: flex; align-items: center; justify-content: center; gap: 6px; padding: 9px 6px; border-radius: 13px; background: #fff; font-family: var(--font-head); font-weight: 800; font-size: .85rem; color: #5c6b5e; box-shadow: 0 3px 0 rgba(140, 160, 130, .25); transition: all .15s; }
.rank-tab .rt-ico { width: 20px; height: 20px; }
.rank-tab .rt-ico svg { width: 100%; height: 100%; }
.rank-tab.active { background: linear-gradient(180deg, #ffe27a, #f5a623); color: #5c3a00; box-shadow: 0 3px 0 #b45309; }
.podium { display: flex; align-items: flex-end; justify-content: center; gap: 8px; margin-bottom: 12px; padding: 18px 8px 0; background: linear-gradient(180deg, #eef7ff, #e3f0ff); border-radius: 18px; box-shadow: inset 0 0 0 2px #d6e8fb; }
.podium-col { flex: 1; max-width: 150px; display: flex; flex-direction: column; align-items: center; position: relative; }
.podium-crown { width: 30px; height: 30px; margin-bottom: -6px; animation: crownBob 2.4s ease-in-out infinite; }
@keyframes crownBob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-5px); } }
.podium-avatar { width: 54px; height: 54px; border-radius: 50%; background: linear-gradient(160deg, #94a3b8, #475569); color: #fff; font-family: var(--font-head); font-weight: 800; font-size: 1.4rem; display: flex; align-items: center; justify-content: center; box-shadow: 0 4px 0 rgba(0, 0, 0, .18), 0 0 0 3px #fff inset; }
.pav-1 { width: 64px; height: 64px; background: linear-gradient(160deg, #ffe27a, #f5a623); box-shadow: 0 4px 0 #b45309, 0 0 0 3px #fff inset; }
.pav-2 { background: linear-gradient(160deg, #e2e8f0, #94a3b8); box-shadow: 0 4px 0 #64748b, 0 0 0 3px #fff inset; }
.pav-3 { background: linear-gradient(160deg, #fcd9b8, #d97706); box-shadow: 0 4px 0 #92400e, 0 0 0 3px #fff inset; }
.podium-name { font-family: var(--font-head); font-weight: 800; font-size: .8rem; margin-top: 6px; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.podium-value { font-size: .72rem; font-weight: 800; color: #b45309; margin-bottom: 8px; }
.podium-step { width: 100%; border-radius: 10px 10px 0 0; background: linear-gradient(180deg, #cbd5e1, #94a3b8); display: flex; align-items: flex-start; justify-content: center; padding-top: 6px; font-family: var(--font-head); font-weight: 800; color: #fff; text-shadow: 0 1px 0 rgba(0, 0, 0, .2); }
.podium-col.p1 .podium-step { height: 64px; background: linear-gradient(180deg, #ffe27a, #f5a623); }
.podium-col.p2 .podium-step { height: 44px; }
.podium-col.p3 .podium-step { height: 30px; background: linear-gradient(180deg, #fcd9b8, #d97706); }
.podium-col.me .podium-name { color: #1d4ed8; }
.rank-list { display: flex; flex-direction: column; gap: 7px; }
.rank-row { display: flex; align-items: center; gap: 10px; background: #fff; border-radius: 14px; padding: 9px 12px; box-shadow: 0 3px 0 rgba(140, 160, 130, .22); }
.rank-row.me { background: linear-gradient(120deg, #eff6ff, #dbeafe); box-shadow: 0 3px 0 rgba(59, 130, 246, .35), 0 0 0 2px #bfdbfe inset; }
.rank-num { width: 26px; flex: none; text-align: center; font-family: var(--font-head); font-weight: 800; color: #6b7c6f; }
.rank-avatar { width: 40px; height: 40px; flex: none; border-radius: 12px; background: linear-gradient(160deg, #7ed957, #2f8f4a); color: #fff; font-family: var(--font-head); font-weight: 800; font-size: 1.05rem; display: flex; align-items: center; justify-content: center; box-shadow: 0 2px 0 rgba(0, 0, 0, .15), 0 0 0 2px #fff inset; }
.rank-avatar.sm { width: 34px; height: 34px; font-size: .9rem; border-radius: 10px; }
.rank-avatar.gold { background: linear-gradient(160deg, #ffe27a, #f5a623); color: #5c3a00; }
.rank-avatar.is-me { outline: 2px solid #3b82f6; }
.rank-info { flex: 1; min-width: 0; }
.rank-name { font-family: var(--font-head); font-weight: 800; font-size: .92rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rank-sub { font-size: .72rem; color: var(--ink-soft); font-weight: 700; }
.rank-value { text-align: right; flex: none; }
.rv-main { font-family: var(--font-head); font-weight: 800; font-size: .88rem; color: #b45309; }
.rv-sub { font-size: .68rem; color: var(--ink-soft); font-weight: 700; }
.you-tag { background: #3b82f6; color: #fff; font-size: .6rem; font-weight: 800; padding: 1px 7px; border-radius: 999px; vertical-align: 1px; }
.adm-tag { display: inline-flex; align-items: center; gap: 2px; background: #fee2e2; color: #991b1b; font-size: .6rem; font-weight: 800; padding: 1px 7px; border-radius: 999px; vertical-align: 1px; }
.rank-me-slot { margin-top: 12px; }
.rank-me-label { font-size: .74rem; font-weight: 800; color: #1d4ed8; margin: 0 4px 6px; }
.rank-footer { text-align: center; font-size: .74rem; font-weight: 700; color: var(--ink-soft); margin-top: 12px; }

/* ============ Undang teman ============ */
.invite-hero { position: relative; border-radius: 18px; overflow: hidden; background: linear-gradient(120deg, #065f46, #059669 55%, #34d399); color: #fff; padding: 18px; margin-bottom: 14px; box-shadow: 0 5px 0 #044e3a, 0 12px 26px rgba(6, 95, 70, .3); }
.invite-hero-art { position: absolute; right: 10px; top: 12px; width: 74px; height: 74px; opacity: .95; filter: drop-shadow(0 4px 8px rgba(0, 0, 0, .25)); }
.invite-hero-art svg { width: 100%; height: 100%; }
.invite-hero h2 { font-size: 1.35rem; margin-bottom: 3px; max-width: 72%; }
.invite-hero > p { font-size: .82rem; font-weight: 600; opacity: .94; max-width: 80%; margin-bottom: 12px; }
.invite-perks { display: flex; gap: 7px; flex-wrap: wrap; }
.perk { display: flex; align-items: center; gap: 7px; background: rgba(255, 255, 255, .16); border: 1px solid rgba(255, 255, 255, .35); border-radius: 12px; padding: 6px 10px; }
.perk-ico { width: 24px; height: 24px; flex: none; }
.perk-ico svg { width: 100%; height: 100%; }
.perk b { display: block; font-family: var(--font-head); font-size: .84rem; }
.perk span { display: block; font-size: .66rem; font-weight: 700; opacity: .9; }
.code-card { text-align: center; background: linear-gradient(180deg, #fffdf6, #fdf3d7); border: 2px dashed #f5c869; border-radius: 18px; padding: 16px; margin-bottom: 14px; box-shadow: 0 3px 0 rgba(200, 160, 60, .2); }
.code-label { font-size: .76rem; font-weight: 800; color: #92400e; text-transform: uppercase; letter-spacing: .8px; }
.code-box { margin: 8px auto 10px; display: inline-block; }
.code-box span { font-family: var(--font-head); font-weight: 800; font-size: 2rem; letter-spacing: 6px; color: #2c4a30; background: #fff; padding: 8px 18px 8px 24px; border-radius: 14px; box-shadow: 0 3px 0 #d5dcd3, 0 0 0 2px #e2e8e0 inset; }
.code-actions { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; }
.code-actions .btn { flex: 1; max-width: 210px; }
.code-actions .btn svg { width: 18px; height: 18px; flex: none; }
.btn.btn-wa { background: linear-gradient(180deg, #4ade80, #16a34a); box-shadow: 0 4px 0 #14532d, 0 6px 14px rgba(22, 101, 52, .3); }
.btn.btn-wa:active { box-shadow: 0 1px 0 #14532d; }
.code-link { margin-top: 10px; font-size: .72rem; font-weight: 700; color: #8a6a2f; word-break: break-all; }
.invite-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 14px; }
.istat { background: #fff; border-radius: 14px; padding: 10px 8px; text-align: center; box-shadow: 0 3px 0 rgba(140, 160, 130, .22); }
.istat-val { font-family: var(--font-head); font-weight: 800; font-size: 1.25rem; }
.istat-val.gold { color: #b45309; }
.istat-val.gem { color: #6d28d9; }
.istat-lbl { font-size: .7rem; font-weight: 800; color: var(--ink-soft); }
.ms-row { display: flex; align-items: center; gap: 11px; padding: 10px 0; border-bottom: 1.6px dashed #e7efe2; }
.ms-row:last-child { border-bottom: none; }
.ms-row.reached .ms-title { color: #047857; }
.ms-count { width: 40px; height: 40px; flex: none; border-radius: 12px; background: #eef3ea; display: flex; align-items: center; justify-content: center; font-family: var(--font-head); font-weight: 800; font-size: 1.05rem; color: #44584a; }
.ms-row.reached .ms-count { background: #d1fae5; color: #047857; }
.ms-body { flex: 1; min-width: 0; }
.ms-title { font-weight: 800; font-size: .85rem; display: flex; gap: 6px; align-items: center; flex-wrap: wrap; margin-bottom: 5px; }
.ms-status { width: 30px; height: 30px; flex: none; opacity: .5; }
.ms-status svg { width: 100%; height: 100%; }
.ms-row.reached .ms-status { opacity: 1; }
.friend-row { display: flex; align-items: center; gap: 10px; padding: 9px 0; border-bottom: 1.6px dashed #e7efe2; }
.friend-row:last-child { border-bottom: none; }
.friend-info { flex: 1; min-width: 0; }
.friend-name { font-family: var(--font-head); font-weight: 800; font-size: .92rem; }
.friend-sub { font-size: .72rem; color: var(--ink-soft); font-weight: 700; }
.steps { display: flex; flex-direction: column; gap: 10px; }
.step { display: flex; gap: 10px; align-items: flex-start; font-size: .86rem; font-weight: 600; }
.step-num { width: 26px; height: 26px; flex: none; border-radius: 50%; background: linear-gradient(180deg, #ffe27a, #f5a623); color: #5c3a00; font-family: var(--font-head); font-weight: 800; display: flex; align-items: center; justify-content: center; font-size: .85rem; box-shadow: 0 2px 0 #b45309; }

/* ============ Menu Lainnya ============ */
.more-head { display: flex; align-items: center; gap: 13px; margin-bottom: 14px; padding: 4px 2px; }
.more-head-art { width: 52px; height: 52px; flex: none; }
.more-head-art svg { width: 100%; height: 100%; }
.more-head h2 { font-size: 1.35rem; color: #2c4a30; }
.more-head p { font-size: .82rem; font-weight: 700; color: var(--ink-soft); }
.more-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 14px; }
.more-card { display: flex; align-items: center; gap: 10px; background: #fff; border-radius: 16px; padding: 13px 12px; text-align: left; box-shadow: 0 3px 0 rgba(140, 160, 130, .25); transition: transform .1s, box-shadow .1s; }
.more-card:active { transform: translateY(2px); box-shadow: 0 1px 0 rgba(140, 160, 130, .25); }
.mcard-ico { width: 42px; height: 42px; flex: none; border-radius: 12px; display: flex; align-items: center; justify-content: center; }
.mcard-ico svg { width: 30px; height: 30px; }
.mc-green .mcard-ico { background: #dcfce7; }
.mc-blue .mcard-ico { background: #dbeafe; }
.mc-amber .mcard-ico { background: #fef3c7; }
.mc-red .mcard-ico { background: #fee2e2; }
.mc-violet .mcard-ico { background: #ede9fe; }
.mcard-body { flex: 1; min-width: 0; }
.mcard-body b { display: block; font-family: var(--font-head); font-size: .95rem; }
.mcard-body small { display: block; font-size: .7rem; font-weight: 700; color: var(--ink-soft); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mcard-chev { width: 18px; height: 18px; flex: none; opacity: .7; }
.mcard-chev svg { width: 100%; height: 100%; }
.guide-list { display: flex; flex-direction: column; gap: 10px; margin-bottom: 14px; }
.guide-item { background: #f6faf3; border-radius: 12px; padding: 10px 12px; }
.guide-item b { font-family: var(--font-head); display: block; font-size: .9rem; color: #2c4a30; }
.guide-item span { font-size: .8rem; font-weight: 600; color: #5c6b5e; }

/* ============ Panel admin ============ */
.admin-head { display: flex; align-items: center; gap: 13px; margin-bottom: 14px; padding: 14px 16px; background: linear-gradient(120deg, #312e81, #4f46e5 60%, #818cf8); border-radius: 18px; color: #fff; box-shadow: 0 5px 0 #312e81, 0 12px 26px rgba(67, 56, 202, .3); }
.admin-head-art { width: 50px; height: 50px; flex: none; }
.admin-head-art svg { width: 100%; height: 100%; filter: drop-shadow(0 3px 6px rgba(0, 0, 0, .3)); }
.admin-head h2 { font-size: 1.35rem; }
.admin-head p { font-size: .8rem; font-weight: 700; opacity: .92; }
.admin-tabs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 12px; }
.admin-tab { position: relative; display: flex; align-items: center; justify-content: center; gap: 6px; padding: 10px 6px; border-radius: 13px; background: #fff; font-family: var(--font-head); font-weight: 800; font-size: .85rem; color: #5c6b5e; box-shadow: 0 3px 0 rgba(140, 160, 130, .25); }
.admin-tab svg { width: 18px; height: 18px; }
.admin-tab.active { background: linear-gradient(180deg, #818cf8, #4f46e5); color: #fff; box-shadow: 0 3px 0 #312e81; }
.tab-count { position: absolute; top: -6px; right: 4px; min-width: 18px; height: 18px; padding: 0 4px; border-radius: 999px; background: #ef4444; color: #fff; font-size: .66rem; display: flex; align-items: center; justify-content: center; box-shadow: 0 0 0 2px #fff; }
.admin-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; margin-bottom: 14px; }
.astat { background: #fff; border-radius: 15px; padding: 11px 12px; box-shadow: 0 3px 0 rgba(140, 160, 130, .25); border-top: 4px solid #94a3b8; }
.astat.a-blue { border-top-color: #3b82f6; }
.astat.a-green { border-top-color: #10b981; }
.astat.a-amber { border-top-color: #f59e0b; }
.astat.a-violet { border-top-color: #8b5cf6; }
.astat-lbl { font-size: .7rem; font-weight: 800; color: var(--ink-soft); }
.astat-val { font-family: var(--font-head); font-weight: 800; font-size: 1.06rem; margin: 2px 0; word-break: break-all; }
.astat-sub { font-size: .66rem; font-weight: 700; color: var(--ink-soft); }
.chart-bars { display: flex; align-items: flex-end; gap: 7px; height: 150px; padding: 4px 2px 0; }
.cbar-wrap { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; height: 100%; }
.cbar-val { font-size: .62rem; font-weight: 800; color: #44584a; margin-bottom: 3px; min-height: 12px; }
.cbar-track { flex: 1; width: 100%; display: flex; align-items: flex-end; }
.cbar { width: 100%; border-radius: 8px 8px 4px 4px; background: linear-gradient(180deg, #7ed957, #2f8f4a); box-shadow: 0 2px 0 rgba(0, 0, 0, .12); transform-origin: bottom; animation: barGrow .5s ease-out; }
@keyframes barGrow { from { transform: scaleY(.15); } to { transform: scaleY(1); } }
.cbar-lbl { font-size: .66rem; font-weight: 800; color: var(--ink-soft); margin-top: 4px; }
.mini-row { display: flex; align-items: center; gap: 9px; padding: 7px 0; border-bottom: 1.6px dashed #e7efe2; }
.mini-row:last-child { border-bottom: none; }
.mini-info { flex: 1; min-width: 0; }
.mini-name { font-family: var(--font-head); font-weight: 800; font-size: .88rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mini-sub { font-size: .7rem; color: var(--ink-soft); font-weight: 700; }
.admin-toolbar { display: flex; gap: 8px; margin-bottom: 12px; }
.admin-toolbar input, .admin-toolbar select { flex: 1; padding: 10px 13px; border-radius: 12px; border: 2px solid #dfe8da; background: #fff; font-weight: 700; outline: none; min-width: 0; }
.admin-toolbar input:focus, .admin-toolbar select:focus { border-color: var(--green); box-shadow: 0 0 0 4px rgba(76, 175, 80, .13); }
.au-row { display: flex; align-items: center; gap: 10px; background: #fff; border-radius: 14px; padding: 10px 12px; margin-bottom: 8px; box-shadow: 0 3px 0 rgba(140, 160, 130, .22); }
.au-row.is-admin { box-shadow: 0 3px 0 rgba(140, 160, 130, .22), 0 0 0 2px #fecaca inset; }
.au-info { flex: 1; min-width: 0; }
.au-name { font-family: var(--font-head); font-weight: 800; font-size: .92rem; }
.au-sub { font-size: .7rem; color: var(--ink-soft); font-weight: 700; margin-bottom: 3px; }
.au-pills { display: flex; gap: 5px; flex-wrap: wrap; }
.pager { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 10px; }
.pager-info { font-size: .8rem; font-weight: 800; color: var(--ink-soft); }
.admin-wd .wd-actions { display: flex; flex-direction: column; gap: 6px; align-items: flex-end; }
.wd-btn-row { display: flex; gap: 6px; }
.status-chip.ditolak { background: #fee2e2; color: #b91c1c; }

/* ============ Responsif V2 ============ */
@media (max-width: 720px) {
  .admin-stats { grid-template-columns: repeat(2, 1fr); }
  .rank-hero { padding: 14px; }
  .rank-hero h2 { font-size: 1.2rem; }
  .rank-hero-art { width: 46px; height: 46px; }
  .admin-head { padding: 12px 14px; }
}
@media (max-width: 560px) {
  .more-grid { grid-template-columns: 1fr; }
  .code-box span { font-size: 1.6rem; letter-spacing: 4px; }
  .invite-hero-art { width: 58px; height: 58px; }
  .invite-stats { grid-template-columns: repeat(3, 1fr); gap: 6px; }
  .istat-val { font-size: 1.05rem; }
  .podium { gap: 5px; padding: 14px 5px 0; }
  .podium-avatar { width: 46px; height: 46px; font-size: 1.15rem; }
  .pav-1 { width: 55px; height: 55px; }
}

/* ============================================================
   V3 - VIP: pay-to-win permata untuk pemain yang rajin deposit
   ============================================================ */

/* Badge VIP di HUD (samping nama pemain) */
.vip-tag { display: inline-flex; align-items: center; gap: 3px; flex: none; background: linear-gradient(180deg, #fde68a, #f59e0b); color: #78350f; font-family: var(--font-head); font-weight: 800; font-size: .6rem; padding: 1px 7px; border-radius: 999px; box-shadow: 0 1px 0 #b45309; }
.vip-tag svg { width: 11px; height: 11px; }
.vip-tag.hidden { display: none; }

/* Tag VIP kecil (ranking & stat kebun) */
.vip-rank-tag { display: inline-flex; align-items: center; background: linear-gradient(180deg, #fde68a, #f59e0b); color: #78350f; font-size: .6rem; font-weight: 800; padding: 1px 7px; border-radius: 999px; vertical-align: 1px; }
.vip-mini { display: inline-flex; align-items: center; background: linear-gradient(180deg, #fde68a, #f59e0b); color: #78350f; font-size: .58rem; font-weight: 800; padding: 1px 6px; border-radius: 999px; margin-left: 4px; vertical-align: 1px; }

/* Kartu status VIP di halaman Top Up */
.vip-card { background: linear-gradient(135deg, #fffbeb, #fef3c7); border: 2px solid #fcd34d; border-radius: 18px; padding: 14px; margin-bottom: 14px; box-shadow: 0 3px 0 rgba(200, 160, 60, .25); }
.vip-card.is-vip { background: linear-gradient(135deg, #fff7ed, #fde68a); border-color: #f59e0b; }
.vip-head { display: flex; align-items: center; gap: 10px; }
.vip-ico { width: 40px; height: 40px; flex: none; filter: drop-shadow(0 2px 3px rgba(180, 83, 9, .3)); }
.vip-ico svg { width: 100%; height: 100%; }
.vip-head-txt { display: flex; flex-direction: column; line-height: 1.25; min-width: 0; }
.vip-head-txt b { font-family: var(--font-head); font-size: 1.08rem; color: #78350f; }
.vip-head-txt small { font-weight: 700; color: #92400e; font-size: .78rem; }
.vip-track { height: 8px; background: rgba(255, 255, 255, .75); border-radius: 99px; overflow: hidden; margin-top: 11px; box-shadow: 0 1px 0 #fcd34d inset; }
.vip-track .fill { height: 100%; background: linear-gradient(90deg, #fbbf24, #b45309); border-radius: 99px; transition: width .4s; }
.vip-next-note { font-size: .78rem; font-weight: 700; color: #92400e; margin-top: 7px; }
.vip-tier-strip { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin-top: 11px; }
.vip-tier { display: flex; flex-direction: column; align-items: center; line-height: 1.3; background: rgba(255, 255, 255, .65); border: 1.5px solid #fcd34d; border-radius: 12px; padding: 6px 3px; text-align: center; }
.vip-tier b { font-family: var(--font-head); font-size: .68rem; color: #92400e; }
.vip-tier small { font-size: .62rem; font-weight: 700; color: var(--ink-soft); }
.vip-tier.on { background: linear-gradient(180deg, #fbbf24, #f59e0b); border-color: #b45309; box-shadow: 0 2px 0 #b45309; }
.vip-tier.on b, .vip-tier.on small { color: #fff; }

/* Catatan naik tier di layar sukses pembayaran */
.vip-up-note { display: flex; align-items: center; justify-content: center; gap: 8px; background: linear-gradient(135deg, #fffbeb, #fde68a); border: 2px solid #f59e0b; border-radius: 14px; padding: 10px 12px; margin-top: 12px; font-weight: 800; color: #78350f; font-size: .86rem; animation: popIn .35s cubic-bezier(.34, 1.6, .64, 1); }
.vip-up-note svg { width: 24px; height: 24px; flex: none; }

@media (max-width: 420px) {
  .vip-tier-strip { grid-template-columns: repeat(2, 1fr); }
  .vip-head-txt b { font-size: .98rem; }
}

/* V4 - Top up nominal bebas */
.custom-card { border: 2px dashed #c9b458; background: linear-gradient(180deg, #fffdf4, #fff9e3); }
.custom-input-row { display: flex; align-items: center; background: #fff; border: 2px solid #e4d9b8; border-radius: 14px; overflow: hidden; transition: border-color .15s; }
.custom-input-row:focus-within { border-color: #f5a623; box-shadow: 0 0 0 3px rgba(245, 166, 35, .18); }
.cir-prefix { font-family: var(--font-head); font-weight: 800; color: #92400e; background: #fef3c7; padding: 11px 12px; font-size: .95rem; }
.custom-input-row input { flex: 1; border: 0; outline: 0; padding: 11px 12px; font-family: var(--font-head); font-weight: 800; font-size: 1.05rem; color: #2c4a30; background: transparent; min-width: 0; }
.custom-preview { margin-top: 10px; background: #ecfdf5; border: 1.5px solid #6ee7b7; border-radius: 12px; padding: 9px 12px; font-weight: 700; font-size: .86rem; color: #065f46; }
.custom-preview b { color: #047857; }
.custom-preview.bad { background: #fef2f2; border-color: #fca5a5; color: #b91c1c; }
.custom-tier-note { margin-top: 10px; font-size: .72rem; font-weight: 700; color: #8a7a4a; text-align: center; }
.custom-card .btn-block { margin-top: 10px; }
