:root {
    --bg: #050505; 
    --surface: #0f0f11;
    --primary: #00ff9d; 
    --secondary: #bc13fe; 
    --ios: #007aff;
    --android: #3ddc84;
    --text: #ffffff;
    --text-dim: #94a3b8;
    --border: rgba(255, 255, 255, 0.08);
    --glass: rgba(15, 15, 17, 0.7);
    --font: 'Space Grotesk', sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; font-family: var(--font); -webkit-tap-highlight-color: transparent; }
body { background-color: var(--bg); color: var(--text); overflow-x: hidden; min-height: 100vh; }

#particle-canvas { position: fixed; inset: 0; z-index: -2; opacity: 0.6; }
.vignette { position: fixed; inset: 0; background: radial-gradient(circle at center, transparent 20%, var(--bg) 100%); z-index: -1; pointer-events: none; }

.status-bar { background: #000; border-bottom: 1px solid var(--border); padding: 8px 20px; display: flex; justify-content: space-between; font-size: 0.7rem; color: var(--primary); letter-spacing: 1.5px; font-weight: 600; }
.status-item { display: flex; align-items: center; gap: 8px; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--primary); box-shadow: 0 0 10px var(--primary); }

.glass-nav { position: sticky; top: 0; padding: 18px 25px; background: var(--glass); backdrop-filter: blur(25px); border-bottom: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; z-index: 100; }
.logo { font-weight: 800; font-size: 1.6rem; letter-spacing: -1.5px; }
.highlight { color: var(--primary); }

main { max-width: 650px; margin: 0 auto; padding: 20px; }
.hero-section { text-align: center; margin: 40px 0; }
.hero-section h1 { font-size: 3.5rem; line-height: 0.85; font-weight: 900; }
.gradient-text { background: linear-gradient(135deg, var(--primary), var(--secondary)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }

/* AD STYLES */
.pro-ad-wrapper { width: 100%; margin: 25px 0; padding: 15px; background: rgba(255,255,255,0.03); border: 1px solid var(--border); border-radius: 20px; text-align: center; min-height: 100px; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.ad-label { font-size: 0.6rem; font-weight: 800; color: #444; letter-spacing: 3px; margin-bottom: 10px; display: block; }
.ad-fallback { width: 100%; height: 100%; background: repeating-linear-gradient(45deg, #111, #111 10px, #151515 10px, #151515 20px); border: 1px dashed #333; color: #555; font-size: 0.7rem; font-family: monospace; display: flex; align-items: center; justify-content: center; padding: 20px; }

.search-container { background: #0d0d0f; border: 1px solid var(--border); padding: 15px; border-radius: 16px; display: flex; align-items: center; gap: 12px; margin-bottom: 30px; }
.search-container input { background: transparent; border: none; color: white; width: 100%; outline: none; }

.filters { display: flex; gap: 10px; overflow-x: auto; margin-bottom: 30px; scrollbar-width: none; }
.filter-btn { background: #1a1a1d; border: 1px solid var(--border); color: var(--text-dim); padding: 10px 24px; border-radius: 12px; font-weight: 700; cursor: pointer; }
.filter-btn.active { background: var(--primary); color: #000; }

.app-grid { display: flex; flex-direction: column; gap: 25px; }
.card { background: var(--surface); border-radius: 24px; border: 1px solid var(--border); cursor: pointer; transition: 0.3s; position: relative; }
.card:hover { transform: translateY(-5px); border-color: var(--primary); }
.card-border { position: absolute; top: 0; left: 0; width: 100%; height: 3px; background: linear-gradient(90deg, var(--primary), var(--secondary)); }
.card-content { padding: 24px; }

.card-top { display: flex; gap: 20px; margin-bottom: 20px; }
.app-icon { width: 75px; height: 75px; border-radius: 18px; object-fit: cover; }
.verify-icon { color: var(--primary); }

.data-grid { display: grid; grid-template-columns: 1fr 1fr 1fr; background: #000; padding: 15px; border-radius: 16px; text-align: center; }
.data-item span { font-size: 0.6rem; color: var(--text-dim); }
.green-text { color: var(--primary); }

.btn-mini { width: 100%; background: #1a1a1d; color: var(--primary); padding: 12px; border: 1px solid var(--border); border-radius: 12px; font-weight: 800; margin-top: 15px; cursor: pointer; }

.skeleton-card { height: 180px; background: #111; border-radius: 24px; animation: shimmer 2s infinite; }
@keyframes shimmer { 50% { opacity: 0.5; } }

/* --- MODAL UPDATES --- */
.modal-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.9); z-index: 1001; display: none; align-items: center; justify-content: center; padding: 20px; backdrop-filter: blur(10px); }
.detail-box { width: 100%; max-width: 500px; background: #0c0c0e; border: 1px solid var(--primary); border-radius: 32px; padding: 30px; position: relative; max-height: 90vh; overflow-y: auto; }

/* THE NEW BACK BUTTON */
.back-btn { background: rgba(255, 255, 255, 0.05); border: 1px solid var(--border); color: #fff; padding: 10px 20px; border-radius: 12px; font-weight: 700; font-size: 0.8rem; cursor: pointer; display: inline-flex; align-items: center; gap: 8px; transition: 0.3s; margin-bottom: 20px; }
.back-btn:hover { background: var(--primary); color: #000; }

/* THE FIXED HEADER & LOGO */
.detail-header { display: flex; align-items: center; gap: 20px; margin-bottom: 25px; padding-bottom: 20px; border-bottom: 1px solid var(--border); text-align: left; }
.popup-icon { width: 85px; height: 85px; border-radius: 20px; object-fit: cover; flex-shrink: 0; box-shadow: 0 5px 15px rgba(0,0,0,0.5); border: 1px solid var(--border); cursor: zoom-in; transition: transform 0.2s; }
.popup-icon:hover { transform: scale(1.05); }

.popup-stats { display: flex; justify-content: space-around; background: #111; padding: 20px; border-radius: 20px; margin: 20px 0; border: 1px solid var(--border); }
.popup-desc p { color: #ccc; line-height: 1.6; font-size: 0.95rem; }

.btn-group { display: flex; gap: 10px; margin-top: 15px; }
.btn { flex: 1; padding: 15px; border: none; border-radius: 12px; font-weight: 800; color: #fff; cursor: pointer; }
.btn-ios { background: var(--ios); }
.btn-android { background: var(--android); }

/* FULLSCREEN IMAGE OVERLAY */
.image-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.95); z-index: 2000; display: none; align-items: center; justify-content: center; cursor: zoom-out; }
#full-image { max-width: 90%; max-height: 90%; border-radius: 16px; box-shadow: 0 0 50px rgba(0, 255, 157, 0.2); animation: zoomIn 0.3s forwards; }
@keyframes zoomIn { from { transform: scale(0.9); opacity: 0; } to { transform: scale(1); opacity: 1; } }

.console-box { width: 100%; max-width: 400px; background: #0a0a0c; border: 1px solid var(--border); border-radius: 12px; padding: 20px; }
.progress-bar-container { width: 100%; height: 6px; background: #333; border-radius: 10px; margin: 20px 0; overflow: hidden; }
.progress-bar { height: 100%; background: var(--primary); width: 0%; transition: width 0.5s; }
.verify-btn { width: 100%; background: var(--primary); padding: 15px; border: none; border-radius: 12px; font-weight: 800; cursor: pointer;}
.disabled { opacity: 0.5; pointer-events: none; }

.ticker-wrap { position: fixed; bottom: 0; width: 100%; background: #000; padding: 10px; border-top: 1px solid var(--border); }
.ticker { display: flex; gap: 50px; white-space: nowrap; animation: ticker 25s linear infinite; }
@keyframes ticker { from { transform: translateX(100%); } to { transform: translateX(-100%); } }

@media (min-width: 768px) {
    main { max-width: 900px; }
    .app-grid { display: grid; grid-template-columns: 1fr 1fr; }
    .hero-section h1 { font-size: 5rem; }
    .desktop-only-ad { display: flex !important; }
}
@media (max-width: 768px) { .desktop-only-ad { display: none !important; } }