/* ═══════════════════════════════════════════
   LV GAME HUB — Game App Styles [lv_game_hub]
   Desktop-first layout: header + sidebar + content
   Requires: global.css
   ═══════════════════════════════════════════ */

/* ── Reset ── */
#lv-game-hub * { box-sizing: border-box; margin: 0; padding: 0; }

/* ── Root Container ──
   Full width of whatever WordPress column it sits in.
   Internal content constrains itself where needed.
   ──────────────────────────────────────────────── */
#lv-game-hub {
    font-family: var(--font);
    color: var(--text-primary);
    background: var(--bg-primary);
    width: 100%;
    max-width: none;
    box-sizing: border-box;
    /* JS sets an exact height that fits the viewport; this is a safe fallback */
    height: 760px;
    max-height: 100vh;
    min-height: 0;
    display: flex;
    flex-direction: column;
    border-radius: 0;
    overflow: hidden;            /* outer box never scrolls — inner content does */
    box-shadow: none;
    -webkit-font-smoothing: antialiased;
    position: relative;
}

/* ── Garden Mode — full-screen scene, shell grows with it ── */
#lv-game-hub.mode-garden { height: auto !important; max-height: none; overflow: visible; }
#lv-game-hub.mode-garden .lvgh-sidebar { display: none !important; }
#lv-game-hub.mode-garden .lvgh-app-body { overflow: visible; }
#lv-game-hub.mode-garden .lvgh-content { padding: 0; flex: 1; display: flex; flex-direction: column; overflow: visible; }

/* ══════════════════════════════════════
   HEADER
   ══════════════════════════════════════ */
.lvgh-header {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 0 24px;
    height: 72px;
    background: linear-gradient(135deg, #0a140a, #0e1a0e);
    border-bottom: 1px solid var(--border-light);
    flex-shrink: 0;
    z-index: 20;
}
.lvgh-header-brand {
    font-size: 17px;
    font-weight: 800;
    letter-spacing: -0.3px;
    background: linear-gradient(135deg, var(--accent-green), var(--accent-gold));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    white-space: nowrap;
}
.lvgh-header-stats {
    display: flex;
    gap: 10px;
    flex: 1;
    justify-content: flex-end;
}
.lvgh-header-stat {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 8px 18px;
    background: linear-gradient(180deg, rgba(255,255,255,0.04), rgba(255,255,255,0.01));
    border: 1.5px solid var(--border-light);
    border-radius: 12px;
    min-width: 86px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.25);
}
.lvgh-header-stat-val {
    font-size: 19px;
    font-weight: 800;
    font-family: var(--font-mono);
    color: var(--accent-gold);
    line-height: 1.05;
}
.lvgh-header-stat-lbl {
    font-size: 9px;
    color: var(--text-muted);
    letter-spacing: 0.6px;
    text-transform: uppercase;
    margin-top: 3px;
    font-weight: 700;
}
.lvgh-header-avatar {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 9px 16px;
    background: linear-gradient(180deg, rgba(255,255,255,0.04), rgba(255,255,255,0.01));
    border: 1.5px solid var(--border-light);
    border-radius: 12px;
    color: var(--text-primary);
    font-family: var(--font);
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    white-space: nowrap;
    flex-shrink: 0;
    box-shadow: 0 2px 6px rgba(0,0,0,0.25);
}
.lvgh-header-avatar:hover {
    border-color: var(--accent-green);
    background: var(--bg-card-hover);
}

/* ── Language dropdown ── */
.lvgh-lang-dd {
    position: relative;
    flex-shrink: 0;
}
.lvgh-lang-toggle {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 9px 14px;
    background: linear-gradient(180deg, rgba(255,255,255,0.04), rgba(255,255,255,0.01));
    border: 1.5px solid var(--border-light);
    border-radius: 12px;
    color: var(--text-primary);
    font-family: var(--font);
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 2px 6px rgba(0,0,0,0.25);
    -webkit-tap-highlight-color: transparent;
}
.lvgh-lang-toggle:hover { border-color: var(--accent-green); }
.lvgh-lang-toggle .lang-globe { font-size: 15px; }
.lvgh-lang-toggle .lang-caret { font-size: 10px; color: var(--text-muted); transition: transform 0.2s ease; }
.lvgh-lang-dd.open .lang-caret { transform: rotate(180deg); }

.lvgh-lang-menu {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    min-width: 160px;
    background: var(--bg-secondary, #0e1a0e);
    border: 1px solid var(--border-light);
    border-radius: 12px;
    box-shadow: 0 12px 32px rgba(0,0,0,0.6);
    padding: 6px;
    display: none;
    flex-direction: column;
    gap: 2px;
    z-index: 300;
}
.lvgh-lang-dd.open .lvgh-lang-menu { display: flex; }
.lvgh-lang-opt {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 11px 14px;
    background: transparent;
    border: none;
    border-radius: 8px;
    color: var(--text-secondary);
    font-family: var(--font);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    text-align: left;
    -webkit-tap-highlight-color: transparent;
}
.lvgh-lang-opt:hover  { background: rgba(76,175,80,0.12); color: var(--text-primary); }
.lvgh-lang-opt.active { background: rgba(76,175,80,0.16); color: var(--accent-green); }
.lvgh-lang-opt .opt-check { color: var(--accent-green); font-weight: 800; }

/* ══════════════════════════════════════
   APP BODY — Sidebar + Content
   ══════════════════════════════════════ */
.lvgh-app-body {
    display: flex;
    flex: 1;
    min-height: 0;       /* allow children to size within the fixed shell */
    overflow: hidden;
}

/* ══════════════════════════════════════
   SIDEBAR NAV
   ══════════════════════════════════════ */
.lvgh-sidebar {
    width: 210px;
    flex-shrink: 0;
    background: rgba(0,0,0,0.25);
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    padding: 12px 0;
    overflow-y: auto;
}
.lvgh-sidebar-section-title {
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--text-muted);
    padding: 12px 16px 6px;
}
.lvgh-sidebar-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 11px 16px;
    border: none;
    background: transparent;
    color: var(--text-muted);
    font-family: var(--font);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    text-align: left;
    width: 100%;
    border-left: 2px solid transparent;
    -webkit-tap-highlight-color: transparent;
}
.lvgh-sidebar-item:hover { color: var(--text-secondary); background: rgba(255,255,255,0.04); }
.lvgh-sidebar-item.active {
    color: var(--accent-green);
    background: rgba(76,175,80,0.08);
    border-left-color: var(--accent-green);
}
.lvgh-sidebar-icon { font-size: 18px; flex-shrink: 0; }
.lvgh-sidebar-label { flex: 1; }

/* Boosts panel in sidebar */
.lvgh-sidebar-boosts {
    margin-top: auto;
    padding: 8px 0 4px;
    border-top: 1px solid var(--border);
}
.lvgh-boost-pill {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    font-size: 12px;
    font-weight: 600;
    color: var(--accent-green);
    position: relative;
}
.lvgh-boost-pill::before {
    content: '⚡';
    font-size: 10px;
}
.lvgh-boost-timer {
    margin-left: auto;
    font-size: 10px;
    font-family: var(--font-mono);
    color: var(--text-muted);
    background: var(--bg-card);
    padding: 2px 6px;
    border-radius: var(--radius-xs);
}

/* ══════════════════════════════════════
   MAIN CONTENT AREA
   ══════════════════════════════════════ */
.lvgh-content {
    flex: 1;
    padding: 24px;
    overflow-x: hidden;
    overflow-y: auto;        /* content scrolls inside the fixed shell */
    min-width: 0;
    min-height: 0;
    display: flex;
    flex-direction: column;
}
/* Game screens fill the content height so they fit without overflowing */
.lvgh-content > .lvgh-screen-inner { flex: 1; min-height: 0; display: flex; flex-direction: column; width: 100%; }

/* Screen fade-in */
.lvgh-screen-inner {
    animation: lvghFadeIn 0.25s ease-out;
}
@keyframes lvghFadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ══════════════════════════════════════
   AUTH SCREENS (no chrome, centered)
   ══════════════════════════════════════ */
.lvgh-auth {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 700px;
    padding: 48px 24px;
    animation: lvghFadeIn 0.3s ease-out;
}
.lvgh-auth-logo {
    font-size: 56px;
    margin-bottom: 10px;
    animation: lvghFloat 3s ease-in-out infinite;
}
@keyframes lvghFloat {
    0%, 100% { transform: translateY(0); }
    50%       { transform: translateY(-8px); }
}
.lvgh-auth h1 {
    font-size: 30px;
    font-weight: 800;
    letter-spacing: -0.5px;
    margin-bottom: 4px;
    background: linear-gradient(135deg, var(--accent-green), var(--accent-gold));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.lvgh-auth .subtitle {
    color: var(--text-muted);
    font-size: 14px;
    margin-bottom: 32px;
}
.lvgh-auth-form { width: 100%; max-width: 400px; }
.lvgh-input-group { margin-bottom: 16px; }
.lvgh-input-group label {
    display: block;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 6px;
}
.lvgh-input {
    width: 100%;
    padding: 14px 16px;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-family: var(--font);
    font-size: 16px;
    outline: none;
    transition: var(--transition);
}
.lvgh-input:focus { border-color: var(--accent-green); box-shadow: 0 0 0 3px var(--accent-green-glow); }
.lvgh-input::placeholder { color: var(--text-muted); }

.lvgh-btn {
    width: 100%;
    padding: 15px;
    border: none;
    border-radius: var(--radius-sm);
    font-family: var(--font);
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    -webkit-tap-highlight-color: transparent;
}
.lvgh-btn-primary {
    background: linear-gradient(135deg, #3a8f3d, #2d7a30);
    color: #fff;
    box-shadow: 0 4px 20px var(--accent-green-glow);
}
.lvgh-btn-primary:hover  { transform: translateY(-2px); box-shadow: 0 6px 30px var(--accent-green-glow); }
.lvgh-btn-primary:active { transform: translateY(0); }
.lvgh-btn-secondary {
    background: transparent;
    color: var(--accent-green);
    border: 1px solid var(--border);
    margin-top: 10px;
}
.lvgh-btn-secondary:hover { background: var(--bg-card); border-color: var(--accent-green); }
.lvgh-btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none !important; }
.lvgh-btn-sm { padding: 8px 16px; font-size: 12px; min-height: 36px; white-space: nowrap; flex-shrink: 0; }

.lvgh-error {
    background: rgba(231,76,60,0.1);
    border: 1px solid rgba(231,76,60,0.3);
    color: #e74c3c;
    padding: 12px 16px;
    border-radius: var(--radius-xs);
    font-size: 14px;
    margin-bottom: 16px;
    animation: lvghShake 0.3s ease;
}
@keyframes lvghShake {
    0%, 100% { transform: translateX(0); }
    25%       { transform: translateX(-5px); }
    75%       { transform: translateX(5px); }
}

/* Login hint after redirect */
.lvgh-auth-hint {
    background: rgba(74,170,74,0.1);
    border: 1px solid var(--accent-green);
    border-radius: 10px;
    padding: 10px 16px;
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 20px;
    text-align: center;
    width: 100%;
    max-width: 400px;
}
.lvgh-auth-hint b { color: var(--accent-green); }

/* ══════════════════════════════════════
   HUB SCREEN
   ══════════════════════════════════════ */
.lvgh-hub-layout {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 20px;
    align-items: start;
}
.lvgh-hub-games-title {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 14px;
}
.lvgh-hub-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 0;
}
.lvgh-hub-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 20px 16px;
    cursor: pointer;
    transition: var(--transition);
    -webkit-tap-highlight-color: transparent;
    position: relative;
    overflow: hidden;
}
.lvgh-hub-card::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, transparent, rgba(255,255,255,0.02));
    pointer-events: none;
}
.lvgh-hub-card:hover { border-color: var(--border-light); transform: translateY(-3px); box-shadow: 0 8px 24px rgba(0,0,0,0.3); }
.lvgh-hub-card:active { transform: translateY(0); }
.lvgh-hub-card .icon { font-size: 30px; display: block; margin-bottom: 10px; }
.lvgh-hub-card .name { font-size: 14px; font-weight: 700; margin-bottom: 5px; color: var(--text-primary); }
.lvgh-hub-card .desc { font-size: 11px; color: var(--text-muted); line-height: 1.5; }
.lvgh-hub-card .badge {
    display: inline-block;
    margin-top: 8px;
    padding: 3px 9px;
    font-size: 10px;
    font-weight: 700;
    border-radius: 100px;
    letter-spacing: 0.5px;
}
.badge-main  { background: rgba(76,175,80,0.15); color: var(--accent-green); border: 1px solid rgba(76,175,80,0.3); }
.badge-boost { background: rgba(212,168,67,0.12); color: var(--accent-gold); border: 1px solid rgba(212,168,67,0.25); }

/* Economy panel */
.lvgh-economy-panel {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.lvgh-econ-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 18px 16px;
}
.lvgh-econ-title {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 12px;
}
.lvgh-econ-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 0;
    border-bottom: 1px solid var(--border);
    font-size: 12px;
    line-height: 1.4;
}
.lvgh-econ-row:last-child { border-bottom: none; }
.lvgh-econ-icon { font-size: 20px; flex-shrink: 0; width: 28px; text-align: center; }
.lvgh-econ-text { flex: 1; color: var(--text-secondary); }
.lvgh-econ-val { font-family: var(--font-mono); font-size: 11px; font-weight: 700; color: var(--accent-gold); white-space: nowrap; }

.lvgh-guest-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    background: linear-gradient(135deg, rgba(74,170,74,0.1), rgba(212,175,55,0.1));
    border: 1px solid var(--accent-green);
    border-radius: var(--radius-sm);
    padding: 14px 18px;
    margin-bottom: 20px;
}
.lvgh-guest-banner-text { font-size: 13px; color: var(--text-secondary); line-height: 1.4; }

/* ══════════════════════════════════════
   GARDEN — PvZ2 Zen Garden Scene
   ══════════════════════════════════════ */

/* Scene wrapper fills the full app body */
.lvgh-garden-scene {
    position: relative;
    width: 100%;
    min-height: 100vh;
    overflow: hidden;
    /* Default = night */
    background: linear-gradient(180deg, #03060f 0%, #060c1c 20%, #071526 55%, #06180a 78%, #040e06 100%);
}
/* Dawn 5-7am */
.lvgh-garden-scene.time-dawn {
    background: linear-gradient(180deg, #1a0a2a 0%, #4a1a3a 25%, #c87860 55%, #2a5a30 78%, #0e2010 100%);
}
/* Morning 7-10am */
.lvgh-garden-scene.time-morning {
    background: linear-gradient(180deg, #1a3050 0%, #3060a0 30%, #60a0d0 60%, #2a6a38 80%, #0e3018 100%);
}
/* Day 10-17 */
.lvgh-garden-scene.time-day {
    background: linear-gradient(180deg, #1a508a 0%, #2878c0 25%, #50a0e0 55%, #208040 78%, #0a4020 100%);
}
/* Sunset 17-20 */
.lvgh-garden-scene.time-sunset {
    background: linear-gradient(180deg, #2a0a10 0%, #8a2010 20%, #e05820 45%, #c09040 65%, #183820 80%, #080e08 100%);
}
/* Dusk 20-22 */
.lvgh-garden-scene.time-dusk {
    background: linear-gradient(180deg, #080818 0%, #181040 25%, #301850 55%, #0e2018 78%, #060e08 100%);
}

/* Stars */
.lvgh-scene-stars { position: absolute; inset: 0; pointer-events: none; }
.lvgh-star {
    position: absolute;
    background: #fff;
    border-radius: 50%;
    animation: starPulse var(--dur, 3s) ease-in-out infinite;
    animation-delay: var(--delay, 0s);
}
@keyframes starPulse {
    0%, 100% { opacity: var(--min-op, 0.2); transform: scale(1); }
    50%       { opacity: var(--max-op, 0.8); transform: scale(1.4); }
}

/* Fireflies */
.lvgh-scene-fireflies { position: absolute; inset: 0; pointer-events: none; }
.lvgh-firefly {
    position: absolute;
    width: 4px;
    height: 4px;
    background: #aaee44;
    border-radius: 50%;
    box-shadow: 0 0 6px #aaee44, 0 0 14px rgba(170,238,68,0.5);
    animation: fireflyFloat var(--dur, 9s) ease-in-out infinite;
    animation-delay: var(--delay, 0s);
}
@keyframes fireflyFloat {
    0%   { transform: translate(0,0); opacity: 0; }
    15%  { opacity: 1; }
    50%  { transform: translate(var(--tx,30px), var(--ty,-40px)); opacity: 0.9; }
    85%  { opacity: 1; }
    100% { transform: translate(var(--tx2,60px), var(--ty2,10px)); opacity: 0; }
}

/* Sun (day/morning/sunset) */
.lvgh-scene-sun {
    position: absolute;
    top: 50px;
    right: 10%;
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: radial-gradient(circle at 50% 50%, #fff9c4, #ffee58 40%, #f9a825 80%);
    box-shadow: 0 0 40px rgba(255,220,0,0.6), 0 0 100px rgba(255,220,0,0.25), 0 0 200px rgba(255,200,0,0.1);
    animation: sunGlow 6s ease-in-out infinite;
}
@keyframes sunGlow {
    0%, 100% { box-shadow: 0 0 40px rgba(255,220,0,0.6), 0 0 100px rgba(255,220,0,0.25); }
    50%       { box-shadow: 0 0 60px rgba(255,220,0,0.8), 0 0 140px rgba(255,220,0,0.35); }
}
.time-sunset .lvgh-scene-sun { background: radial-gradient(circle at 50% 60%, #fff3, #ff8c00 50%, #c0390c 90%); top: auto; bottom: 180px; }

/* Moon */
.lvgh-scene-moon {
    position: absolute;
    top: 50px;
    right: 10%;
    width: 68px;
    height: 68px;
    border-radius: 50%;
    background: radial-gradient(circle at 38% 38%, #fffde7, #ffee58 40%, #f9a825 80%);
    box-shadow: 0 0 30px rgba(255,235,59,0.4), 0 0 80px rgba(255,235,59,0.15), 0 0 140px rgba(255,235,59,0.06);
    animation: moonGlow 5s ease-in-out infinite;
}
@keyframes moonGlow {
    0%, 100% { box-shadow: 0 0 30px rgba(255,235,59,0.4), 0 0 80px rgba(255,235,59,0.15); }
    50%       { box-shadow: 0 0 45px rgba(255,235,59,0.6), 0 0 110px rgba(255,235,59,0.25); }
}

/* Tree silhouettes left */
.lvgh-scene-trees-left,
.lvgh-scene-trees-right {
    position: absolute;
    bottom: 0;
    width: 180px;
    height: 320px;
    pointer-events: none;
}
.lvgh-scene-trees-left  { left: 0; }
.lvgh-scene-trees-right { right: 0; transform: scaleX(-1); }
.lvgh-scene-trees-left::before,
.lvgh-scene-trees-left::after,
.lvgh-scene-trees-right::before,
.lvgh-scene-trees-right::after {
    content: '';
    position: absolute;
    bottom: 0;
    background: #020b03;
}
.lvgh-scene-trees-left::before  { left: 10px;  width: 60px; height: 260px; clip-path: polygon(50% 0%, 90% 100%, 10% 100%); }
.lvgh-scene-trees-left::after   { left: 55px;  width: 50px; height: 200px; clip-path: polygon(50% 0%, 92% 100%, 8% 100%); opacity: 0.8; }
.lvgh-scene-trees-right::before { left: 10px;  width: 70px; height: 300px; clip-path: polygon(50% 0%, 88% 100%, 12% 100%); }
.lvgh-scene-trees-right::after  { left: 60px;  width: 55px; height: 220px; clip-path: polygon(50% 0%, 90% 100%, 10% 100%); opacity: 0.75; }

/* Atmospheric fog layer */
.lvgh-scene-fog {
    position: absolute;
    bottom: 150px;
    left: 0;
    right: 0;
    height: 100px;
    background: linear-gradient(180deg, transparent 0%, rgba(7,20,9,0.5) 100%);
    pointer-events: none;
}

/* Ground */
.lvgh-scene-ground {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 230px;
    background: linear-gradient(180deg, #0d2a10, #081a08, #040e04);
}
.lvgh-scene-ground-top {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 8px;
    background: repeating-linear-gradient(
        90deg,
        #1b561b 0px, #1b561b 10px,
        #268c26 10px, #268c26 20px,
        #1b561b 20px, #1b561b 24px
    );
}

/* Slots row centered on ground — wraps instead of cropping on narrow widths */
.lvgh-scene-slots {
    position: absolute;
    bottom: 36px;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 1320px;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: flex-end;
    gap: 28px 32px;
    padding: 0 40px;
    box-sizing: border-box;
}

/* Single slot */
.lvgh-scene-slot {
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: pointer;
    transition: transform 0.25s cubic-bezier(0.34, 1.5, 0.64, 1);
    position: relative;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}
.lvgh-scene-slot:hover         { transform: translateY(-10px) scale(1.05); }
.lvgh-scene-slot.active        { transform: translateY(-14px) scale(1.07); }
.lvgh-scene-slot.ready         { animation: potBounce 2.2s ease-in-out infinite; }
.lvgh-scene-slot.locked        { cursor: pointer; }
.lvgh-scene-slot.locked:hover  { transform: translateY(-6px) scale(1.03); }
.lvgh-scene-slot.dead          { cursor: pointer; }
.lvgh-scene-slot.dead:hover    { transform: translateY(-6px) scale(1.03); }
.lvgh-scene-slot.wilting       { animation: wiltWobble 3s ease-in-out infinite; }
@keyframes wiltWobble {
    0%,100% { transform: rotate(0deg); }
    30%     { transform: rotate(-2deg); }
    70%     { transform: rotate(2deg); }
}

@keyframes potBounce {
    0%, 100% { transform: translateY(0); }
    50%       { transform: translateY(-8px); }
}

/* Plant display area — bottom-aligned, overlaps pot rim so the plant grows out of it */
.slot-plant {
    min-height: 120px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    position: relative;
    z-index: 5;
    margin-bottom: -18px; /* base of plant enters the pot opening */
    pointer-events: none;
}
/* Empty slot — no space above pot */
.lvgh-scene-slot.empty .slot-plant { min-height: 0; margin-bottom: 0; }

/* SVG plant */
.plant-svg {
    display: block;
    width: 116px;
    height: auto;
    transform-origin: 50% 100%;
    filter: drop-shadow(0 6px 8px rgba(0,0,0,0.45));
    animation: plantSway 5.5s ease-in-out infinite;
}
.plant-stage-0 .plant-svg { width: 60px; }
.plant-stage-1 .plant-svg { width: 78px; }
.plant-stage-2 .plant-svg { width: 96px; }
.plant-stage-3 .plant-svg { width: 110px; }
.plant-stage-4 .plant-svg {
    width: 122px;
    animation: plantSway 5s ease-in-out infinite, harvestGlow 2s ease-in-out infinite;
}
@keyframes plantSway {
    0%,100% { transform: rotate(-1.2deg); }
    50%     { transform: rotate(1.2deg); }
}
@keyframes harvestGlow {
    0%,100% { filter: drop-shadow(0 6px 8px rgba(0,0,0,0.45)) drop-shadow(0 0 10px rgba(212,168,67,0.35)); }
    50%     { filter: drop-shadow(0 6px 8px rgba(0,0,0,0.45)) drop-shadow(0 0 20px rgba(212,168,67,0.7)); }
}
/* Dead & wilting visuals via filters (reuse the same SVG structure) */
.plant-stage-0.dead .plant-svg, .slot-plant.dead .plant-svg {
    filter: grayscale(1) brightness(0.5) drop-shadow(0 4px 6px rgba(0,0,0,0.5));
    animation: none;
    transform: rotate(8deg) scaleY(0.8);
    opacity: 0.7;
}
.slot-plant.wilting .plant-svg {
    filter: sepia(0.7) saturate(0.6) brightness(0.85) drop-shadow(0 5px 7px rgba(0,0,0,0.4));
    animation: wiltBob 2.4s ease-in-out infinite;
}
@keyframes wiltBob {
    0%,100% { transform: rotate(-4deg); }
    50%     { transform: rotate(2deg); }
}
/* Dead pot badge */
.slot-ready-badge.dead-badge {
    background: rgba(180,30,30,0.85);
    border-color: rgba(231,76,60,0.6);
    color: #ff8a8a;
}
/* Remove button for dead plants */
.lvgh-panel-btn.dead-remove {
    background: rgba(180,30,30,0.15);
    border-color: rgba(231,76,60,0.5);
    color: #ef5350;
}
.lvgh-panel-btn.dead-remove:hover { background: rgba(180,30,30,0.3); }

/* Care action buttons (water/feed/trim) */
.lvgh-panel-btn.care {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    line-height: 1.1;
}
.lvgh-panel-btn.care .care-state {
    font-size: 10px;
    font-weight: 700;
    font-family: var(--font-mono);
    opacity: 0.85;
}
.lvgh-panel-btn.care.needed {
    background: linear-gradient(135deg, rgba(76,175,80,0.22), rgba(76,175,80,0.1));
    border-color: var(--accent-green);
    color: #d6f5c8;
    animation: careGlow 1.8s ease-in-out infinite;
}
.lvgh-panel-btn.care.needed .care-state { color: #aee89a; }
.lvgh-panel-btn.care.needed:hover { background: rgba(76,175,80,0.3); }
.lvgh-panel-btn.care.ok {
    opacity: 0.5;
    cursor: default;
    border-color: var(--border);
    background: rgba(255,255,255,0.03);
}
.lvgh-panel-btn.care.ok .care-state { color: var(--accent-green); opacity: 1; }
@keyframes careGlow {
    0%,100% { box-shadow: 0 0 4px rgba(76,175,80,0.2); }
    50%     { box-shadow: 0 0 14px rgba(76,175,80,0.5); }
}
.lvgh-panel-hint {
    margin-top: 12px;
    text-align: center;
    font-size: 12px;
    color: var(--text-secondary);
    background: rgba(76,175,80,0.06);
    border: 1px solid rgba(76,175,80,0.15);
    border-radius: var(--radius-sm);
    padding: 10px 14px;
    line-height: 1.5;
}

.slot-plant-stem {
    width: 5px;
    border-radius: 3px;
    background: linear-gradient(180deg, #3a7a3a, #254e25);
    margin-top: 2px;
    transition: height 0.5s ease;
    flex-shrink: 0;
}

.slot-empty-hint {
    font-size: 12px;
    color: var(--text-muted);
    text-align: center;
    line-height: 1.5;
    animation: hintPulse 2.5s ease-in-out infinite;
}
@keyframes hintPulse {
    0%, 100% { opacity: 0.4; }
    50%       { opacity: 0.9; }
}

/* Ready badge */
.slot-ready-badge {
    position: absolute;
    top: -2px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #6d4c00, #a07418);
    border: 1px solid var(--accent-gold);
    border-radius: 20px;
    padding: 4px 12px;
    font-size: 11px;
    font-weight: 700;
    color: #ffd54f;
    white-space: nowrap;
    animation: readyBadge 1.6s ease-in-out infinite;
    z-index: 10;
}
@keyframes readyBadge {
    0%, 100% { box-shadow: 0 0 8px rgba(212,168,67,0.4); }
    50%       { box-shadow: 0 0 22px rgba(212,168,67,0.8); }
}

/* Time/progress label above pot */
.slot-progress {
    font-size: 11px;
    font-family: var(--font-mono);
    color: rgba(255,255,255,0.5);
    background: rgba(0,0,0,0.55);
    padding: 3px 10px;
    border-radius: 100px;
    margin-bottom: 4px;
}

/* Locked slot badge */
.slot-lock-badge {
    position: absolute;
    top: -4px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(8,15,10,0.92);
    border: 1px solid rgba(212,168,67,0.35);
    border-radius: 20px;
    padding: 4px 12px;
    font-size: 11px;
    font-weight: 700;
    color: var(--accent-gold);
    white-space: nowrap;
    z-index: 10;
    text-align: center;
}

/* ══════════════════════════════════════
   3D CERAMIC POT
   ══════════════════════════════════════ */
/* ══════════════════════════════════════
   CERAMIC POT  — realistic flower pot shape
   Wide at top, taper to base, thick rounded rim
   ══════════════════════════════════════ */
.slot-pot3d {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 116px;
    flex-shrink: 0;
    z-index: 3;
    filter: drop-shadow(0 7px 10px rgba(0,0,0,0.45));
}
.lvgh-scene-slot.locked .slot-pot3d { filter: brightness(0.28) saturate(0.15); }

/* ── RIM / LIP — wide terracotta ellipse band, the pot's mouth ── */
.pot3d-opening {
    width: 104px;
    height: 30px;
    border-radius: 50%;
    position: relative;
    z-index: 6;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    /* Solid terracotta lip with top sheen + bottom shade for thickness */
    background:
        linear-gradient(180deg,
            #e6ad55 0%,
            #d59640 22%,
            #bd7d2c 55%,
            #9c601c 100%);
    box-shadow:
        inset 0 -5px 7px rgba(80,40,8,0.55),   /* under-lip shade */
        inset 0 3px 4px rgba(255,228,160,0.55), /* top sheen */
        0 4px 9px rgba(0,0,0,0.4);
}

/* ── Soil surface — dark ellipse sitting inside the lip ── */
.pot3d-soil {
    width: 80px;
    height: 19px;
    margin-top: 4px;
    border-radius: 50%;
    position: relative;
    z-index: 7;
    background: radial-gradient(ellipse at 50% 32%, #4a2c0c, #2c1908, #160c04);
    box-shadow: inset 0 5px 11px rgba(0,0,0,0.92), inset 0 -1px 2px rgba(120,80,30,0.3);
}
/* Empty pot = no soil: show pale clay interior, not dark dirt */
.pot-soil-empty .pot3d-soil {
    background: radial-gradient(ellipse at 50% 32%, #b07a3a, #8a5a22, #5e3c14);
    box-shadow: inset 0 6px 12px rgba(50,28,8,0.75);
}
.pot-soil-basic   .pot3d-soil { background: radial-gradient(ellipse at 50% 32%, #4a2c0c, #2c1908, #160c04); }
.pot-soil-premium .pot3d-soil { background: radial-gradient(ellipse at 50% 32%, #553708, #331f06, #1a1004); box-shadow: inset 0 5px 11px rgba(0,0,0,0.9), 0 0 7px rgba(90,200,70,0.3); }
.pot-soil-super   .pot3d-soil { background: radial-gradient(ellipse at 50% 32%, #1d1a12, #11100a, #070604); box-shadow: inset 0 5px 11px rgba(0,0,0,0.95), 0 0 9px rgba(70,240,90,0.28); }

/* ── BODY — tapered terracotta vessel, top tucked up into the lip ── */
.pot3d-body {
    width: 98px;        /* almost lip width so the top edge meets the rim */
    height: 76px;
    margin-top: -17px;  /* raise the body so its top edge sits inside the rim */
    position: relative;
    z-index: 5;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    /* Wide at top (under the lip) → tapering to ~76% at the base */
    clip-path: polygon(3% 0%, 97% 0%, 86% 100%, 14% 100%);
    background:
        linear-gradient(105deg,
            rgba(255,224,150,0.32) 0%,
            rgba(255,205,120,0.12) 20%,
            transparent 46%,
            rgba(60,28,6,0.18) 72%,
            rgba(30,14,4,0.5) 100%),
        linear-gradient(180deg,
            #d98f3c 0%,
            #b5712a 40%,
            #8a521a 74%,
            #5e3510 100%);
}
/* dark seam where the body meets the underside of the rim */
.pot3d-body::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 16px;
    background: linear-gradient(180deg, rgba(0,0,0,0.35), transparent);
    pointer-events: none;
}
/* soft vertical sheen */
.pot3d-body::after {
    content: '';
    position: absolute;
    top: 6%; bottom: 14%;
    left: 24%; width: 9%;
    background: linear-gradient(180deg, rgba(255,255,255,0.2), rgba(255,255,255,0.05), transparent);
    border-radius: 50%;
    pointer-events: none;
}

/* ── SAUCER / base ── */
.pot3d-saucer {
    width: 100px;
    height: 14px;
    margin-top: -3px;
    position: relative;
    z-index: 4;
    border-radius: 8px 8px 50% 50% / 4px 4px 100% 100%;
    background: linear-gradient(180deg, #b3742a 0%, #8a521a 45%, #5a3210 100%);
    box-shadow: 0 7px 14px rgba(0,0,0,0.55), inset 0 2px 3px rgba(255,200,120,0.25);
}
.pot3d-saucer::after {
    content: '';
    position: absolute;
    top: 1px; left: 10%; right: 10%;
    height: 4px;
    background: radial-gradient(ellipse at 50% 50%, rgba(255,210,140,0.4), transparent 75%);
    border-radius: 50%;
}

/* Timer / hint text — centered in pot body */
.pot3d-timer {
    position: absolute;
    top: 44%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 86%;
    font-size: 9px;
    font-weight: 800;
    font-family: var(--font-mono);
    color: rgba(255,225,170,0.92);
    text-shadow: 0 0 8px rgba(0,0,0,1), 0 1px 3px rgba(0,0,0,0.95);
    white-space: nowrap;
    text-align: center;
    letter-spacing: 0.2px;
    z-index: 6;
    pointer-events: none;
}
.pot3d-timer.ready {
    color: #ffd54f;
    text-shadow: 0 0 8px rgba(255,200,60,0.6), 0 1px 3px rgba(0,0,0,0.95);
    letter-spacing: 1px;
    animation: timerPulse 1s ease-in-out infinite;
}
.lvgh-scene-slot.empty .pot3d-timer {
    color: rgba(255,200,120,0.45);
    font-size: 8px;
    font-weight: 600;
    letter-spacing: 0.2px;
    animation: hintPulse 2.5s ease-in-out infinite;
}
@keyframes timerPulse { 0%,100% { opacity: 1; } 50% { opacity: 0.5; } }
@keyframes hintPulse  { 0%,100% { opacity: 0.35; } 50% { opacity: 0.8; } }

/* Garden HUD — absolute inside scene, centered at top */
.lvgh-garden-hud {
    position: absolute;
    top: 16px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: center;
    z-index: 10;
    pointer-events: none;
    max-width: calc(100% - 280px);
}
.lvgh-garden-hud-pill {
    background: rgba(6,12,8,0.88);
    border: 1px solid rgba(76,175,80,0.3);
    border-radius: 100px;
    padding: 5px 12px;
    font-size: 11px;
    font-weight: 700;
    color: var(--accent-green);
    backdrop-filter: blur(10px);
}
.lvgh-garden-hud-pill.gold {
    border-color: rgba(212,168,67,0.35);
    color: var(--accent-gold);
}
.lvgh-garden-hud-pill.soil {
    border-color: rgba(76,175,80,0.5);
    color: #a5d6a7;
    background: rgba(76,175,80,0.12);
}

/* Inventory bar — always visible below HUD */
.lvgh-garden-inv-bar {
    position: absolute;
    top: 56px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    z-index: 10;
    max-width: calc(100% - 240px);
}
.lvgh-inv-empty {
    font-size: 10px;
    color: rgba(255,200,100,0.4);
    font-style: italic;
    white-space: nowrap;
}
.inv-qty {
    font-weight: 800;
    color: #ffd54f;
}
.lvgh-inv-pill {
    background: rgba(8,18,10,0.9);
    border: 1px solid rgba(212,168,67,0.45);
    border-radius: 100px;
    padding: 4px 11px;
    font-size: 11px;
    font-weight: 700;
    color: var(--accent-gold);
    cursor: pointer;
    transition: var(--transition);
    backdrop-filter: blur(10px);
    font-family: var(--font);
    -webkit-tap-highlight-color: transparent;
    white-space: nowrap;
}
.lvgh-inv-pill.kind-seed { border-color: rgba(76,175,80,0.5);  color: #a5d6a7; }
.lvgh-inv-pill.kind-soil { border-color: rgba(160,120,70,0.6); color: #d2a679; }
.lvgh-inv-pill.kind-use  { border-color: rgba(212,168,67,0.55); color: var(--accent-gold); animation: invPillGlow 2.2s ease-in-out infinite; }
.lvgh-inv-pill:hover  { transform: scale(1.06); filter: brightness(1.2); }
.lvgh-inv-pill:active { transform: scale(0.95); }
@keyframes invPillGlow {
    0%,100% { box-shadow: 0 0 4px rgba(212,168,67,0.2); }
    50%     { box-shadow: 0 0 11px rgba(212,168,67,0.55); }
}

/* Top-right button cluster (Bag + Shop) */
.lvgh-garden-topbtns {
    position: absolute;
    top: 16px;
    right: 20px;
    display: flex;
    gap: 8px;
    z-index: 60;
}
.lvgh-garden-shop-btn {
    background: rgba(6,12,8,0.9);
    border: 1px solid rgba(212,168,67,0.45);
    border-radius: var(--radius-sm);
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 700;
    color: var(--accent-gold);
    cursor: pointer;
    transition: var(--transition);
    backdrop-filter: blur(10px);
    font-family: var(--font);
    -webkit-tap-highlight-color: transparent;
}
.lvgh-garden-shop-btn:hover { background: rgba(212,168,67,0.15); border-color: var(--accent-gold); transform: translateY(-1px); }
.lvgh-garden-shop-btn:active { transform: scale(0.96); }
.lvgh-garden-shop-btn.bag { border-color: rgba(76,175,80,0.5); color: var(--accent-green); }
.lvgh-garden-shop-btn.bag:hover { background: rgba(76,175,80,0.15); border-color: var(--accent-green); }

/* Panel backdrop — fixed overlay, click to close slide-up panels */
/* ══════════════════════════════════════
   UNIFIED GARDEN BOTTOM SHEET
   Every garden popup (care / add-soil / pick seed / buy pot)
   uses this exact shell → all identical size & centered.
   ══════════════════════════════════════ */
.lvgh-gsheet-overlay {
    position: fixed;
    inset: 0;
    z-index: 150;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    background: rgba(0,0,0,0.4);
    opacity: 0;
    transition: opacity 0.3s ease;
}
.lvgh-gsheet-overlay.open { opacity: 1; }
.lvgh-gsheet {
    width: 100%;
    /* Sheet is appended to <body>, so set its own base text color & font
       (CSS vars from #lv-game-hub don't cascade out here). */
    color: var(--text-primary, #e8f0e8);
    font-family: var(--font, system-ui, sans-serif);
    background: rgba(6,13,8,0.985);
    backdrop-filter: blur(32px);
    -webkit-backdrop-filter: blur(32px);
    border-top: 1px solid rgba(76,175,80,0.22);
    border-radius: 22px 22px 0 0;
    box-shadow: 0 -10px 44px rgba(0,0,0,0.65);
    transform: translateY(100%);
    transition: transform 0.4s cubic-bezier(0.34, 1.2, 0.64, 1);
    max-height: 80vh;
    display: flex;
    flex-direction: column;
}
.lvgh-gsheet-overlay.open .lvgh-gsheet { transform: translateY(0); }
.lvgh-gsheet-handle {
    width: 44px; height: 4px;
    background: rgba(255,255,255,0.16);
    border-radius: 2px;
    margin: 12px auto 2px;
    flex-shrink: 0;
}
/* Inner wrapper — fixed comfortable width, perfectly centered */
.lvgh-gsheet-inner {
    width: 100%;
    max-width: 640px;
    margin: 0 auto;
    padding: 10px 24px 28px;
    display: flex;
    flex-direction: column;
    min-height: 0;
}
.lvgh-gsheet-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding-bottom: 15px;
    margin-bottom: 18px;
    border-bottom: 1px solid var(--border);
    flex-shrink: 0;
}
.lvgh-gsheet-titles { display: flex; align-items: center; gap: 13px; min-width: 0; }
.lvgh-gsheet-icon   { font-size: 30px; flex-shrink: 0; line-height: 1; }
.lvgh-gsheet-text   { min-width: 0; }
.lvgh-gsheet-title  { font-size: 19px; font-weight: 800; line-height: 1.2; color: var(--text-primary, #eef5ee); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lvgh-gsheet-sub    { font-size: 11px; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.7px; margin-top: 3px; }
.lvgh-gsheet-close {
    background: none;
    border: 1px solid var(--border);
    color: var(--text-muted);
    font-size: 15px;
    cursor: pointer;
    padding: 8px 12px;
    border-radius: 10px;
    transition: var(--transition);
    line-height: 1;
    flex-shrink: 0;
    -webkit-tap-highlight-color: transparent;
}
.lvgh-gsheet-close:hover { color: var(--text-primary); background: var(--bg-card); }
.lvgh-gsheet-body { overflow-y: auto; min-height: 0; -webkit-overflow-scrolling: touch; }

/* Centered empty / single-action states inside any sheet */
.lvgh-sheet-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    text-align: center;
    padding: 10px 0 4px;
}
.sheet-empty-icon { font-size: 44px; }
.sheet-empty-text { font-size: 14px; color: var(--text-secondary); line-height: 1.5; max-width: 340px; }
.lvgh-sheet-cta   { max-width: 280px; margin-top: 8px; }

/* Shared panel header pieces (kept for compatibility) */
.lvgh-panel-strain { display: flex; align-items: center; gap: 12px; }
.lvgh-panel-strain-name { font-size: 19px; font-weight: 800; line-height: 1.2; }
.lvgh-panel-strain-meta { font-size: 11px; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.8px; margin-top: 2px; }
.lvgh-panel-close {
    background: none; border: 1px solid var(--border); color: var(--text-muted);
    font-size: 15px; cursor: pointer; padding: 7px 11px; border-radius: 10px;
    transition: var(--transition); line-height: 1;
}
.lvgh-panel-close:hover { color: var(--text-primary); background: var(--bg-card); }

.lvgh-panel-bars {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px 28px;
    margin-bottom: 16px;
}
.lvgh-panel-bar-row   { display: flex; align-items: center; gap: 8px; }
.lvgh-panel-bar-label { width: 68px; font-size: 11px; font-weight: 600; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.5px; flex-shrink: 0; }
.lvgh-panel-bar       { flex: 1; height: 7px; background: rgba(255,255,255,0.07); border-radius: 100px; overflow: hidden; }
.lvgh-panel-bar-fill  { height: 100%; border-radius: 100px; transition: width 0.5s ease; }
.lvgh-panel-bar-val   { font-size: 11px; font-family: var(--font-mono); color: var(--text-muted); width: 30px; text-align: right; flex-shrink: 0; }

.lvgh-panel-actions { display: flex; gap: 10px; }
.lvgh-panel-btn {
    flex: 1;
    padding: 13px 8px;
    border-radius: var(--radius-sm);
    border: 1px solid rgba(255,255,255,0.1);
    background: rgba(255,255,255,0.05);
    color: var(--text-primary);
    font-family: var(--font);
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    text-align: center;
    -webkit-tap-highlight-color: transparent;
}
.lvgh-panel-btn:hover    { background: rgba(76,175,80,0.12); border-color: var(--accent-green); }
.lvgh-panel-btn:active   { transform: scale(0.96); }
.lvgh-panel-btn:disabled { opacity: 0.4; cursor: not-allowed; transform: none; }
.lvgh-panel-btn.harvest  {
    background: linear-gradient(135deg, rgba(100,70,0,0.5), rgba(160,120,10,0.5));
    border-color: var(--accent-gold);
    color: #ffd54f;
}
.lvgh-panel-btn.harvest:hover { background: linear-gradient(135deg, rgba(140,100,0,0.6), rgba(200,155,20,0.6)); }

/* Seed picker grid — lives inside the unified sheet body */
.lvgh-picker-grid  { display: grid; grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); gap: 10px; }
.lvgh-picker-item {
    padding: 12px 8px;
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    cursor: pointer;
    text-align: center;
    transition: var(--transition);
    -webkit-tap-highlight-color: transparent;
}
.lvgh-picker-item:hover  { border-color: var(--accent-green); background: rgba(76,175,80,0.09); }
.lvgh-picker-item.locked { opacity: 0.3; cursor: not-allowed; pointer-events: none; }
.lvgh-picker-item .p-emoji { font-size: 28px; display: block; margin-bottom: 5px; }
.lvgh-picker-item .p-name  { font-size: 11px; font-weight: 700; margin-bottom: 3px; color: var(--text-primary); }
.lvgh-picker-item .p-time  { font-size: 10px; color: var(--text-muted); }
.lvgh-picker-item .p-pts   { font-size: 10px; color: var(--accent-gold); font-family: var(--font-mono); font-weight: 700; }
.lvgh-picker-item .p-cost  { font-size: 10px; color: #ef9a9a; font-weight: 700; margin-top: 2px; }
.lvgh-picker-item .p-cost.free { color: var(--accent-green); }

/* Rarity badges (shared) */
.rarity-common    { background: rgba(76,175,80,0.15);  color: #81c784; }
.rarity-uncommon  { background: rgba(52,152,219,0.15); color: #5dade2; }
.rarity-rare      { background: rgba(156,39,176,0.15); color: #ce93d8; }
.rarity-legendary { background: rgba(212,168,67,0.15); color: var(--accent-gold); }

/* Generic bar (used outside garden too) */
.lvgh-bar {
    flex: 1;
    height: 6px;
    background: var(--bg-primary);
    border-radius: 100px;
    overflow: hidden;
}
.lvgh-bar-fill {
    height: 100%;
    border-radius: 100px;
    transition: width 0.5s ease;
}
.lvgh-bar-fill.water    { background: linear-gradient(90deg, #1565c0, #42a5f5); }
.lvgh-bar-fill.nutrient { background: linear-gradient(90deg, #558b2f, #9ccc65); }
.lvgh-bar-fill.health   { background: linear-gradient(90deg, #c62828, #ef5350); }
.lvgh-bar-fill.xp       { background: linear-gradient(90deg, #e65100, var(--accent-gold)); }

/* ══════════════════════════════════════
   PUFF CATCHER
   ══════════════════════════════════════ */
.lvgh-game-wrap {
    max-width: 560px;
    width: 100%;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
}
.lvgh-game-title {
    font-size: 20px;
    font-weight: 800;
    margin-bottom: 12px;
    flex-shrink: 0;
}
.lvgh-game-canvas-wrap {
    position: relative;
    width: 100%;
    flex: 1;                 /* take the remaining height */
    min-height: 0;
    border-radius: var(--radius);
    overflow: hidden;
    border: 1px solid var(--border);
    margin-bottom: 14px;
    background: #050a06;
    display: flex;
    align-items: center;
    justify-content: center;
}
.lvgh-game-canvas-wrap canvas {
    display: block;
    width: auto;
    height: auto;
    max-width: 100%;
    max-height: 100%;        /* scales down to fit the box, keeps aspect */
    touch-action: none;
}
.lvgh-game-hud {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    margin-bottom: 10px;
    flex-shrink: 0;
}
.lvgh-game-hud .score {
    font-size: 30px;
    font-weight: 800;
    font-family: var(--font-mono);
    color: var(--accent-gold);
}
.lvgh-game-hud .timer {
    font-size: 22px;
    font-weight: 700;
    font-family: var(--font-mono);
    color: var(--text-secondary);
}
.lvgh-game-hud .combo {
    font-size: 15px;
    font-weight: 700;
    color: var(--accent-purple);
}
.lvgh-game-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: rgba(8,10,8,0.92);
    backdrop-filter: blur(10px);
    z-index: 10;
    text-align: center;
    padding: 32px 24px;
}
.lvgh-game-overlay h2  { font-size: 28px; font-weight: 800; margin-bottom: 8px; }
.lvgh-game-overlay .final-score {
    font-size: 56px;
    font-weight: 800;
    font-family: var(--font-mono);
    color: var(--accent-gold);
    margin: 12px 0;
    line-height: 1;
}
.lvgh-game-overlay .reward {
    font-size: 14px;
    color: var(--accent-green);
    margin-bottom: 8px;
}
.lvgh-game-overlay .boost-info {
    font-size: 13px;
    color: var(--accent-gold);
    background: rgba(212,168,67,0.1);
    border: 1px solid rgba(212,168,67,0.25);
    border-radius: var(--radius-xs);
    padding: 8px 14px;
    margin-bottom: 16px;
}

/* ══════════════════════════════════════
   QUIZ
   ══════════════════════════════════════ */
.lvgh-quiz-wrap { max-width: 640px; width: 100%; margin: 0 auto; flex: 1; min-height: 0; overflow-y: auto; }
.lvgh-quiz-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}
.lvgh-quiz-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 28px 24px;
    text-align: center;
    margin-bottom: 16px;
}
.lvgh-quiz-card .question-num {
    font-size: 10px;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 14px;
}
.lvgh-quiz-card .question {
    font-size: 18px;
    font-weight: 600;
    line-height: 1.5;
    margin-bottom: 8px;
}
.lvgh-quiz-card .hint {
    font-size: 13px;
    color: var(--text-secondary);
    font-style: italic;
}
.lvgh-quiz-options   { display: flex; flex-direction: column; gap: 10px; }
.lvgh-quiz-option {
    padding: 15px 18px;
    border: 1px solid var(--border);
    background: var(--bg-secondary);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-family: var(--font);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    text-align: left;
    -webkit-tap-highlight-color: transparent;
}
.lvgh-quiz-option:hover   { border-color: var(--accent-green); background: var(--bg-card-hover); }
.lvgh-quiz-option.correct { border-color: var(--accent-green); background: rgba(76,175,80,0.15); color: #a5d6a7; }
.lvgh-quiz-option.wrong   { border-color: var(--accent-red);   background: rgba(231,76,60,0.1);  color: #ef9a9a; }

/* ══════════════════════════════════════
   MEMORY MATCH
   ══════════════════════════════════════ */
.lvgh-memory-wrap { max-width: 520px; width: 100%; margin: 0 auto; flex: 1; min-height: 0; overflow-y: auto; }
.lvgh-memory-hud {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}
.lvgh-memory-hud .pairs {
    font-size: 24px;
    font-weight: 800;
    font-family: var(--font-mono);
    color: var(--accent-green);
}
.lvgh-memory-hud .timer {
    font-size: 20px;
    font-weight: 700;
    font-family: var(--font-mono);
    color: var(--text-secondary);
}
.lvgh-memory-hud .moves { font-size: 14px; font-weight: 600; color: var(--text-muted); }
.lvgh-memory-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
    margin-bottom: 16px;
}
.lvgh-mem-card {
    aspect-ratio: 1;
    border-radius: var(--radius-sm);
    border: 2px solid var(--border);
    background: var(--bg-card);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
    cursor: pointer;
    transition: transform 0.15s ease, border-color 0.15s ease, background 0.15s ease;
    position: relative;
    overflow: hidden;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
}
.lvgh-mem-card:hover:not(.revealed):not(.matched) {
    border-color: var(--accent-green);
    background: var(--bg-card-hover);
}
.lvgh-mem-card:active:not(.revealed):not(.matched) { transform: scale(0.93); }
.lvgh-mem-card .card-back { font-size: 22px; color: var(--text-muted); }
.lvgh-mem-card .card-face { display: none; }
.lvgh-mem-card.revealed .card-back { display: none; }
.lvgh-mem-card.revealed .card-face { display: block; animation: lvghFlip 0.2s ease-out; }
.lvgh-mem-card.matched {
    border-color: var(--accent-green);
    background: rgba(76,175,80,0.12);
    cursor: default;
}
.lvgh-mem-card.matched .card-face { filter: drop-shadow(0 0 6px var(--accent-green-glow)); }
.lvgh-mem-card.wrong {
    border-color: var(--accent-red);
    background: rgba(231,76,60,0.1);
    animation: lvghWrong 0.4s ease;
}
@keyframes lvghFlip {
    from { transform: scale(0.7); opacity: 0.3; }
    to   { transform: scale(1);   opacity: 1; }
}
@keyframes lvghWrong {
    0%, 100% { transform: translateX(0); }
    25%       { transform: translateX(-4px); }
    75%       { transform: translateX(4px); }
}
.lvgh-memory-start-overlay {
    position: absolute;
    inset: 0;
    background: rgba(8,10,8,0.93);
    backdrop-filter: blur(8px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sm);
    z-index: 5;
    padding: 28px;
    text-align: center;
}

/* ══════════════════════════════════════
   MODALS (Profile + Leaderboard)
   ══════════════════════════════════════ */
.lvgh-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.75);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    z-index: 200;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.25s ease;
    padding: 24px;
}
.lvgh-modal-overlay.visible { opacity: 1; }
.lvgh-modal-overlay.fullscreen {
    align-items: flex-start;
    padding: 0;
}

/* Profile modal (centered dialog on desktop) */
.lvgh-bottom-sheet {
    width: 100%;
    max-width: 560px;
    max-height: 90vh;
    background: var(--bg-secondary);
    border-radius: var(--radius);
    border: 1px solid var(--border-light);
    overflow-y: auto;
    transform: translateY(40px) scale(0.97);
    transition: transform 0.3s cubic-bezier(0.34, 1.4, 0.64, 1), opacity 0.3s ease;
    opacity: 0;
    -webkit-overflow-scrolling: touch;
}
.lvgh-modal-overlay.visible .lvgh-bottom-sheet { transform: translateY(0) scale(1); opacity: 1; }

.lvgh-sheet-handle { display: none; }
.lvgh-sheet-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 22px 14px;
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    background: var(--bg-secondary);
    z-index: 1;
}
.lvgh-sheet-title { font-size: 18px; font-weight: 700; }
.lvgh-sheet-close {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 20px;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: var(--radius-xs);
    transition: var(--transition);
    line-height: 1;
}
.lvgh-sheet-close:hover { color: var(--text-primary); background: var(--bg-card); }
.lvgh-sheet-body { padding: 20px 22px; }

/* Leaderboard (full modal) */
.lvgh-full-modal {
    width: 100%;
    max-width: 560px;
    height: 100%;
    max-height: 90vh;
    background: var(--bg-primary);
    border-radius: var(--radius);
    border: 1px solid var(--border-light);
    display: flex;
    flex-direction: column;
    transform: translateY(30px) scale(0.97);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.3s ease;
    opacity: 0;
    overflow: hidden;
}
.lvgh-modal-overlay.visible .lvgh-full-modal { transform: translateY(0) scale(1); opacity: 1; }
.lvgh-modal-overlay.fullscreen { align-items: center; }
.lvgh-full-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 22px;
    border-bottom: 1px solid var(--border);
    flex-shrink: 0;
}
.lvgh-full-modal-body {
    flex: 1;
    overflow-y: auto;
    padding: 18px 22px;
    -webkit-overflow-scrolling: touch;
}

/* Tabs */
.lvgh-tabs {
    display: flex;
    gap: 6px;
    margin-bottom: 14px;
    background: var(--bg-card);
    border-radius: var(--radius-sm);
    padding: 4px;
}
.lvgh-tab {
    flex: 1;
    padding: 8px 6px;
    border: none;
    background: transparent;
    color: var(--text-muted);
    font-family: var(--font);
    font-size: 11px;
    font-weight: 600;
    border-radius: 7px;
    cursor: pointer;
    transition: var(--transition);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.lvgh-tab.active { background: var(--bg-secondary); color: var(--accent-green); box-shadow: 0 1px 4px rgba(0,0,0,0.3); }

.lvgh-period-btns { display: flex; gap: 6px; margin-bottom: 16px; }
.lvgh-period-btn {
    flex: 1;
    padding: 7px;
    border: 1px solid var(--border);
    background: transparent;
    color: var(--text-muted);
    font-family: var(--font);
    font-size: 12px;
    font-weight: 600;
    border-radius: var(--radius-xs);
    cursor: pointer;
    transition: var(--transition);
}
.lvgh-period-btn.active { border-color: var(--accent-green); color: var(--accent-green); background: rgba(76,175,80,0.08); }

.lvgh-lb-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
}
.lvgh-lb-rank { width: 28px; text-align: center; font-family: var(--font-mono); font-size: 14px; font-weight: 700; color: var(--text-muted); flex-shrink: 0; }
.lvgh-lb-rank.gold   { color: #ffd700; }
.lvgh-lb-rank.silver { color: #c0c0c0; }
.lvgh-lb-rank.bronze { color: #cd7f32; }
.lvgh-lb-avatar { width: 34px; height: 34px; border-radius: 50%; background: var(--bg-card); border: 1px solid var(--border); display: flex; align-items: center; justify-content: center; font-size: 18px; flex-shrink: 0; }
.lvgh-lb-name { flex: 1; font-size: 14px; font-weight: 600; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lvgh-lb-score { font-family: var(--font-mono); font-size: 15px; font-weight: 700; color: var(--accent-gold); flex-shrink: 0; }

/* Profile sheet internals */
.lvgh-profile-avatar-big {
    width: 76px;
    height: 76px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent-green), var(--accent-gold));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 36px;
    margin: 0 auto 12px;
    box-shadow: 0 0 28px var(--accent-green-glow);
    cursor: pointer;
    transition: var(--transition);
    position: relative;
}
.lvgh-profile-avatar-big:hover { transform: scale(1.05); }
.lvgh-profile-avatar-big .edit-badge {
    position: absolute;
    bottom: 0;
    right: 0;
    width: 24px;
    height: 24px;
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: 50%;
    font-size: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.lvgh-emoji-picker { display: grid; grid-template-columns: repeat(6, 1fr); gap: 6px; padding: 12px 0; }
.lvgh-emoji-option {
    aspect-ratio: 1;
    border-radius: var(--radius-xs);
    border: 1px solid var(--border);
    background: var(--bg-card);
    font-size: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
}
.lvgh-emoji-option:hover   { border-color: var(--accent-green); background: var(--bg-card-hover); }
.lvgh-emoji-option.selected { border-color: var(--accent-green); background: rgba(76,175,80,0.15); }

.lvgh-profile-stats-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 16px; }
.lvgh-pstat { text-align: center; padding: 12px 8px; background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-sm); }
.lvgh-pstat .val { font-size: 22px; font-weight: 800; font-family: var(--font-mono); color: var(--accent-gold); line-height: 1; }
.lvgh-pstat .lbl { font-size: 9px; text-transform: uppercase; letter-spacing: 1px; color: var(--text-muted); margin-top: 4px; }

.lvgh-stamps-bar-wrap { background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 14px; margin-bottom: 14px; }
.lvgh-stamps-bar { height: 10px; background: var(--bg-primary); border-radius: 100px; overflow: hidden; margin: 8px 0; }
.lvgh-stamps-fill { height: 100%; background: linear-gradient(90deg, var(--accent-gold), #ffd54f); border-radius: 100px; transition: width 0.6s ease; }

.lvgh-achievements-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.lvgh-ach-card { padding: 12px 10px; background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-sm); }
.lvgh-ach-card.earned { border-color: var(--accent-gold); background: rgba(212,168,67,0.06); }
.lvgh-ach-card .ach-emoji { font-size: 22px; margin-bottom: 6px; }
.lvgh-ach-card .ach-name  { font-size: 12px; font-weight: 700; margin-bottom: 2px; }
.lvgh-ach-card .ach-desc  { font-size: 10px; color: var(--text-muted); line-height: 1.3; }
.lvgh-ach-card.locked { opacity: 0.4; }

/* ══════════════════════════════════════
   GENERIC CARDS & UTILITIES
   ══════════════════════════════════════ */
.lvgh-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 20px;
    margin-bottom: 14px;
    transition: var(--transition);
}
.lvgh-card-title {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 14px;
}
.lvgh-section-title {
    font-size: 20px;
    font-weight: 800;
    margin-bottom: 20px;
}
.lvgh-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 120px;
}
.lvgh-spinner {
    width: 34px;
    height: 34px;
    border: 3px solid var(--border);
    border-top-color: var(--accent-green);
    border-radius: 50%;
    animation: lvghSpin 0.8s linear infinite;
}
@keyframes lvghSpin { to { transform: rotate(360deg); } }
.lvgh-empty {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-muted);
}
.lvgh-empty .icon { font-size: 48px; margin-bottom: 12px; opacity: 0.6; display: block; }
.lvgh-empty p { font-size: 14px; line-height: 1.6; }

.mt-16  { margin-top: 16px; }
.mb-16  { margin-bottom: 16px; }
.text-center { text-align: center; }
.text-gold   { color: var(--accent-gold); }
.text-green  { color: var(--accent-green); }
.text-muted  { color: var(--text-muted); }
.text-sm     { font-size: 13px; }

/* Scrollbar */
#lv-game-hub ::-webkit-scrollbar       { width: 4px; }
#lv-game-hub ::-webkit-scrollbar-track { background: transparent; }
#lv-game-hub ::-webkit-scrollbar-thumb { background: var(--border); border-radius: 4px; }

/* ══════════════════════════════════════
   RESPONSIVE — Tablet / Mobile
   ══════════════════════════════════════ */
@media (max-width: 900px) {
    .lvgh-hub-layout { grid-template-columns: 1fr; }
    .lvgh-hub-grid { grid-template-columns: 1fr 1fr; }
    .lvgh-scene-slots { gap: 20px; padding: 0 30px; }
    .slot-pot3d    { width: 90px; }
    .pot3d-opening { width: 76px; height: 22px; }
    .pot3d-soil    { width: 56px; height: 13px; }
    .pot3d-body    { width: 76px; height: 62px; }
    .pot3d-saucer  { width: 88px; height: 11px; }
    .slot-plant-emoji.stage-3 { font-size: 48px; }
    .slot-plant-emoji.stage-4 { font-size: 54px; }
}
@media (max-width: 640px) {
    #lv-game-hub { border-radius: 0; box-shadow: none; }
    .lvgh-sidebar { display: none; }
    .lvgh-content { padding: 16px; }
    .lvgh-header { padding: 0 16px; }
    .lvgh-header-stats { gap: 4px; }
    .lvgh-header-stat { padding: 4px 10px; min-width: 60px; }
    .lvgh-hub-grid { grid-template-columns: 1fr; }
    .lvgh-app-body { flex-direction: column; }
    .lvgh-scene-slots { gap: 10px; padding: 0 10px; }
    .slot-pot3d    { width: 72px; }
    .pot3d-opening { width: 60px; height: 18px; }
    .pot3d-soil    { width: 44px; height: 10px; }
    .pot3d-body    { width: 60px; height: 52px; }
    .pot3d-saucer  { width: 72px; height: 10px; }
    .pot3d-timer   { font-size: 7.5px; }
    .slot-plant    { min-height: 80px; margin-bottom: -10px; }
    .slot-plant-emoji.stage-2 { font-size: 38px; }
    .slot-plant-emoji.stage-3 { font-size: 46px; }
    .slot-plant-emoji.stage-4 { font-size: 52px; }
    .lvgh-panel-bars { grid-template-columns: 1fr; }
    .lvgh-gsheet-inner { padding: 8px 16px 22px; }
    .lvgh-picker-grid { grid-template-columns: repeat(auto-fill, minmax(88px, 1fr)); }
    .lvgh-garden-hud-pill { font-size: 10px; padding: 4px 8px; }
    .lvgh-garden-shop-btn { font-size: 11px; padding: 6px 12px; }
    .lvgh-garden-back-btn { font-size: 11px; padding: 6px 12px; }
    .lvgh-garden-hud { max-width: calc(100% - 220px); }
}

/* ══════════════════════════════════════
   GARDEN BACK BUTTON
   ══════════════════════════════════════ */
.lvgh-garden-back-btn {
    position: absolute;
    top: 16px;
    left: 20px;
    background: rgba(6,12,8,0.88);
    border: 1px solid rgba(76,175,80,0.35);
    border-radius: var(--radius-sm);
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 700;
    color: var(--accent-green);
    cursor: pointer;
    transition: var(--transition);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: 11;
    font-family: var(--font);
    -webkit-tap-highlight-color: transparent;
    line-height: 1;
    display: flex;
    align-items: center;
    gap: 6px;
}
.lvgh-garden-shop-btn { z-index: 11; }
.lvgh-garden-back-btn:hover { background: rgba(76,175,80,0.15); border-color: var(--accent-green); }
.lvgh-garden-back-btn:active { transform: scale(0.95); }

/* ══════════════════════════════════════
   GARDEN SHOP MODAL
   ══════════════════════════════════════ */
.lvgh-shop-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.8);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 200;  /* above fixed garden scene (z-index:50) */
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    transition: opacity 0.25s ease;
}
.lvgh-shop-overlay.visible { opacity: 1; }

.lvgh-shop-modal {
    width: 100%;
    max-width: 700px;
    max-height: 85vh;
    color: var(--text-primary, #e8f0e8);
    font-family: var(--font, system-ui, sans-serif);
    background: #070f0a;
    border: 1px solid rgba(76,175,80,0.25);
    border-radius: var(--radius);
    display: flex;
    flex-direction: column;
    box-shadow: 0 24px 80px rgba(0,0,0,0.85);
    transform: translateY(20px) scale(0.97);
    transition: transform 0.3s cubic-bezier(0.34, 1.2, 0.64, 1), opacity 0.3s ease;
    opacity: 0;
    overflow: hidden;
}
.lvgh-shop-overlay.visible .lvgh-shop-modal { transform: translateY(0) scale(1); opacity: 1; }

.lvgh-shop-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 22px 14px;
    border-bottom: 1px solid rgba(76,175,80,0.15);
    flex-shrink: 0;
}
.lvgh-shop-title {
    font-size: 20px;
    font-weight: 800;
    background: linear-gradient(135deg, var(--accent-green), var(--accent-gold));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.lvgh-shop-tabs {
    display: flex;
    gap: 0;
    flex-shrink: 0;
    border-bottom: 1px solid rgba(76,175,80,0.12);
    background: rgba(0,0,0,0.3);
}
.lvgh-shop-tab {
    flex: 1;
    padding: 12px 8px;
    border: none;
    background: transparent;
    color: var(--text-muted);
    font-family: var(--font);
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 2px solid transparent;
    -webkit-tap-highlight-color: transparent;
}
.lvgh-shop-tab:hover  { color: var(--text-secondary); background: rgba(255,255,255,0.03); }
.lvgh-shop-tab.active { color: var(--accent-green); border-bottom-color: var(--accent-green); background: rgba(76,175,80,0.05); }

.lvgh-shop-body {
    flex: 1;
    overflow-y: auto;
    padding: 20px 22px;
    -webkit-overflow-scrolling: touch;
}

.lvgh-shop-section-title {
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 6px;
}
.lvgh-shop-note {
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 16px;
    line-height: 1.5;
}

/* Inventory summary bar inside each shop tab */
.lvgh-shop-inventory-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 8px 12px;
    background: rgba(76,175,80,0.06);
    border: 1px solid rgba(76,175,80,0.15);
    border-radius: var(--radius-xs);
    margin-bottom: 12px;
}
.inv-item {
    font-size: 12px;
    font-weight: 600;
    color: var(--text-secondary);
}
.inv-item.active { color: var(--accent-green); }
.inv-item.muted  { color: var(--text-muted); font-weight: 400; }
.inv-item b      { color: var(--accent-gold); }

/* "Equipped" / "Owned" badge on shop items */
.shop-owned-badge {
    display: inline-block;
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    background: rgba(76,175,80,0.2);
    color: var(--accent-green);
    border: 1px solid rgba(76,175,80,0.4);
    border-radius: 4px;
    padding: 1px 5px;
    margin-left: 6px;
    vertical-align: middle;
}

/* Equipped item highlight */
.lvgh-shop-list-item.equipped {
    border-color: rgba(76,175,80,0.45);
    background: rgba(76,175,80,0.06);
}

/* Seeds grid */
.lvgh-shop-seeds-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    gap: 10px;
}
.lvgh-shop-seed-card {
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 14px 10px;
    text-align: center;
    transition: var(--transition);
}
.lvgh-shop-seed-card:hover:not(.locked) { border-color: var(--accent-green); background: rgba(76,175,80,0.06); }
.lvgh-shop-seed-card.locked { opacity: 0.35; }
.seed-rarity  { font-size: 9px; font-weight: 800; letter-spacing: 1px; margin-bottom: 6px; }
.seed-emoji   { font-size: 30px; margin-bottom: 6px; }
.seed-name    { font-size: 12px; font-weight: 700; margin-bottom: 3px; color: var(--text-primary); }
.seed-type    { font-size: 10px; color: var(--text-muted); margin-bottom: 6px; }
.seed-stats   { display: flex; justify-content: space-between; font-size: 10px; color: var(--accent-gold); font-weight: 700; margin-bottom: 8px; font-family: var(--font-mono); }
.seed-lock    { font-size: 10px; color: var(--accent-red); margin-top: 6px; }

/* Shop list (soil & boosters) */
.lvgh-shop-list { display: flex; flex-direction: column; gap: 10px; }
.lvgh-shop-list-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 16px;
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    transition: var(--transition);
}
.lvgh-shop-list-item:hover { border-color: rgba(76,175,80,0.3); }
.shop-item-icon { font-size: 28px; flex-shrink: 0; width: 40px; display: flex; align-items: center; justify-content: center; }
.shop-item-info { flex: 1; min-width: 0; }
.shop-item-name { font-size: 14px; font-weight: 700; margin-bottom: 3px; color: var(--text-primary); }

/* CSS-drawn soil swatches (reliable everywhere, no emoji needed) */
.soil-swatch {
    display: inline-block;
    width: 26px;
    height: 26px;
    border-radius: 6px;
    vertical-align: middle;
    border: 1px solid rgba(0,0,0,0.4);
    box-shadow: inset 0 2px 4px rgba(255,255,255,0.15), inset 0 -3px 5px rgba(0,0,0,0.4);
    position: relative;
}
.soil-swatch.sm { width: 18px; height: 18px; border-radius: 4px; }
.soil-swatch.basic   { background: radial-gradient(circle at 35% 30%, #8a5a2c, #5e3a14 70%, #3e2408); }
.soil-swatch.premium { background: radial-gradient(circle at 35% 30%, #6a4518, #3f2808 70%, #241404); box-shadow: inset 0 2px 4px rgba(120,200,90,0.25), inset 0 -3px 5px rgba(0,0,0,0.5); }
.soil-swatch.super   { background: radial-gradient(circle at 35% 30%, #2a2418, #14110a 70%, #080604); box-shadow: inset 0 2px 4px rgba(90,240,110,0.3), inset 0 -3px 5px rgba(0,0,0,0.6); }
.shop-item-desc { font-size: 12px; color: var(--text-muted); line-height: 1.4; margin-bottom: 4px; }
.shop-item-bonus { font-size: 11px; font-weight: 700; }
.shop-item-buy  { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; flex-shrink: 0; }
.shop-item-price { font-size: 14px; font-weight: 800; color: var(--accent-gold); font-family: var(--font-mono); white-space: nowrap; }
.shop-item-price.free { color: var(--accent-green); font-size: 11px; }

/* Common buy button */
.lvgh-shop-item-btn {
    padding: 7px 14px;
    background: rgba(76,175,80,0.1);
    border: 1px solid rgba(76,175,80,0.35);
    border-radius: var(--radius-xs);
    color: var(--accent-green);
    font-family: var(--font);
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    white-space: nowrap;
    -webkit-tap-highlight-color: transparent;
}
.lvgh-shop-item-btn:hover:not(:disabled) { background: rgba(76,175,80,0.2); border-color: var(--accent-green); }
.lvgh-shop-item-btn:active:not(:disabled) { transform: scale(0.95); }
.lvgh-shop-item-btn:disabled { opacity: 0.35; cursor: not-allowed; }

/* Pots grid */
.lvgh-shop-pots-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 10px;
}
.lvgh-shop-pot-card {
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 14px 10px;
    text-align: center;
    transition: var(--transition);
}
.lvgh-shop-pot-card.owned  { border-color: rgba(76,175,80,0.4); background: rgba(76,175,80,0.05); }
.lvgh-shop-pot-card.next   { border-color: rgba(212,168,67,0.45); background: rgba(212,168,67,0.05); }
.lvgh-shop-pot-card.locked { opacity: 0.3; }
.pot-card-icon   { font-size: 28px; margin-bottom: 6px; }
.pot-card-num    { font-size: 11px; font-weight: 700; color: var(--text-muted); margin-bottom: 6px; text-transform: uppercase; letter-spacing: 0.5px; }
.pot-card-status.owned  { font-size: 11px; color: var(--accent-green); font-weight: 700; }
.pot-card-status.locked { font-size: 10px; color: var(--text-muted); }
.pot-card-price  { font-size: 14px; font-weight: 800; color: var(--accent-gold); font-family: var(--font-mono); margin-bottom: 8px; }

@media (max-width: 640px) {
    .lvgh-shop-modal { max-height: 92vh; }
    .lvgh-shop-tab { font-size: 10px; padding: 10px 4px; letter-spacing: 0; }
    .lvgh-shop-seeds-grid { grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); }
    .lvgh-shop-pots-grid  { grid-template-columns: repeat(auto-fill, minmax(80px, 1fr)); }
    .lvgh-shop-list-item  { flex-wrap: wrap; }
    .shop-item-buy { flex-direction: row; align-items: center; }
}

/* ══════════════════════════════════════
   ADD-SOIL PANEL (choose owned soil for a pot)
   ══════════════════════════════════════ */
.lvgh-soil-choices {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 10px;
    padding: 6px 0 10px;
}
.lvgh-soil-choice {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    padding: 14px 10px;
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: var(--transition);
    font-family: var(--font);
    color: var(--text-primary);
    -webkit-tap-highlight-color: transparent;
}
.lvgh-soil-choice:hover  { border-color: var(--accent-green); background: rgba(76,175,80,0.08); transform: translateY(-2px); }
.lvgh-soil-choice:active { transform: scale(0.97); }
.lvgh-soil-choice:disabled { opacity: 0.5; }
.soil-choice-icon  { font-size: 30px; }
.soil-choice-name  { font-size: 13px; font-weight: 700; }
.soil-choice-bonus { font-size: 11px; color: var(--accent-green); }
.soil-choice-qty   { font-size: 10px; color: var(--text-muted); font-family: var(--font-mono); margin-top: 2px; }

/* Picker: owned-count badge + empty state */
.lvgh-picker-item { position: relative; }
.lvgh-picker-item .p-owned {
    position: absolute;
    top: 4px; right: 6px;
    font-size: 10px;
    font-weight: 800;
    color: #0a140a;
    background: var(--accent-green);
    border-radius: 100px;
    padding: 1px 7px;
    font-family: var(--font-mono);
}
.lvgh-picker-empty {
    grid-column: 1 / -1;
    text-align: center;
    padding: 24px 16px;
    color: var(--text-muted);
    font-size: 14px;
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* Seed shop owned badge */
.lvgh-shop-seed-card { position: relative; }
.seed-owned-badge {
    position: absolute;
    top: 6px; right: 6px;
    font-size: 10px;
    font-weight: 800;
    color: #0a140a;
    background: var(--accent-green);
    border-radius: 100px;
    padding: 1px 7px;
    font-family: var(--font-mono);
    z-index: 2;
}

/* ══════════════════════════════════════
   FULL INVENTORY MODAL
   ══════════════════════════════════════ */
.lvgh-inv-section { margin-bottom: 18px; }
.lvgh-inv-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(124px, 1fr));
    gap: 10px;
}
.lvgh-inv-card {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    padding: 14px 10px 12px;
    background: rgba(255,255,255,0.035);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    text-align: center;
}
.inv-card-qty {
    position: absolute;
    top: 6px; right: 8px;
    font-size: 11px;
    font-weight: 800;
    color: var(--accent-gold);
    font-family: var(--font-mono);
}
.inv-card-icon { font-size: 30px; line-height: 1; }
.inv-card-name { font-size: 12px; font-weight: 700; color: var(--text-primary); }
.inv-card-tip  { font-size: 10px; color: var(--text-muted); line-height: 1.3; min-height: 24px; }
.inv-card-hint { font-size: 10px; color: var(--text-secondary); font-style: italic; margin-top: 2px; }
.inv-use-btn   { margin-top: 4px; padding: 6px 16px; }
.lvgh-inv-empty-full {
    text-align: center;
    padding: 50px 20px;
    font-size: 22px;
    line-height: 1.5;
    color: var(--text-secondary);
}
.lvgh-inv-empty-full span { font-size: 13px; color: var(--text-muted); }

/* Empty-pot click hint pulse */
.lvgh-scene-slot.empty.no-soil  .pot3d-timer { color: rgba(255,210,140,0.55); }
.lvgh-scene-slot.empty.has-soil .pot3d-timer { color: rgba(150,230,150,0.7); }
.lvgh-scene-slot.empty:hover .slot-pot3d { transform: translateY(-4px); transition: transform 0.2s; }

/* ═══ AUTH: verification / reset code input & links ═══ */
.lvgh-input.lvgh-code-input {
    text-align: center;
    font-family: var(--font-mono);
    font-size: 26px;
    font-weight: 600;
    letter-spacing: 12px;
    padding-left: 12px; /* compensate trailing letter-spacing */
}
.lvgh-input.lvgh-code-input::placeholder {
    letter-spacing: 8px;
    font-size: 20px;
}
.lvgh-auth-links {
    text-align: center;
    margin-top: 14px;
    font-size: 13px;
    color: var(--text-muted);
}
.lvgh-auth-links a {
    color: var(--accent-green);
    text-decoration: none;
    font-weight: 600;
}
.lvgh-auth-links a:hover { text-decoration: underline; }
