/* Fazza Play Modern Store UI - 2025 Edition
   Inspired by Apple App Store & Google Play
*/
:root {
    --bg: #f8fafc;
    --card-bg: #ffffff;
    --text-main: #0f172a;
    --muted: #64748b;
    --accent: #2563eb; /* Blue Store Primary */
    --accent-light: #dbeafe;
    --accent-gradient: linear-gradient(135deg, #2563eb 0%, #06b6d4 100%);
    --success: #10b981;
    --radius-app: 22px; /* iOS Style Icon Radius */
    --radius-card: 20px;
    --shadow-soft: 0 4px 20px rgba(0, 0, 0, 0.05);
    --shadow-hover: 0 12px 30px rgba(37, 99, 235, 0.15);
}

/* Base Adjustments */
body {
    background: var(--bg);
    color: var(--text-main);
    font-family: 'Tajawal', sans-serif;
    line-height: 1.6;
    margin: 0;
    transition: background 0.3s ease;
}

/* Modern Glass Header */
header {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(0,0,0,0.05);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 12px 0;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* App Card - The Store Look */
.apps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
    padding: 20px 0;
}

.app-card {
    background: var(--card-bg);
    border-radius: var(--radius-card);
    padding: 20px;
    border: 1px solid rgba(0,0,0,0.03);
    box-shadow: var(--shadow-soft);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
}

.app-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-hover);
    border-color: var(--accent-light);
}

/* App Icon Style - The Most Important Part */
.app-card img {
    width: 80px;
    height: 80px;
    border-radius: var(--radius-app); /* Authentic App Icon Shape */
    object-fit: cover;
    box-shadow: 0 8px 16px rgba(0,0,0,0.1);
    margin-bottom: 15px;
    background: #fff;
    border: 1px solid #f1f5f9;
}

.app-card h3 {
    font-size: 1.2rem;
    font-weight: 700;
    margin: 10px 0 5px;
    color: var(--text-main);
}

.app-card p {
    color: var(--muted);
    font-size: 0.9rem;
    margin-bottom: 20px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Buttons - Call to Action */
.app-card-actions {
    margin-top: auto;
    display: flex;
    gap: 12px;
}

.btn {
    flex: 1;
    padding: 12px;
    border-radius: 12px;
    font-weight: 600;
    text-align: center;
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.2s;
}

.details-btn {
    background: #f1f5f9;
    color: var(--text-main);
}

.details-btn:hover {
    background: #e2e8f0;
}

.download-btn {
    background: var(--accent-gradient);
    color: #fff;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.2);
}

.download-btn:hover {
    opacity: 0.9;
    box-shadow: 0 6px 18px rgba(37, 99, 235, 0.3);
}

/* Dark Mode - Deep Blue & Professional */
body.dark-mode {
    --bg: #020617;
    --card-bg: #0f172a;
    --text-main: #f1f5f9;
    --muted: #94a3b8;
}

body.dark-mode .app-card {
    border-color: rgba(255,255,255,0.05);
}

body.dark-mode header {
    background: rgba(15, 23, 42, 0.8);
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

/* Responsive Fixes */
@media (max-width: 640px) {
    .apps-grid {
        grid-template-columns: 1fr; /* One card per row on mobile for better Ad placement */
    }
    .app-card {
        flex-direction: row; /* Horizontal style on mobile like App Store */
        align-items: center;
        gap: 15px;
    }
    .app-card img {
        width: 65px;
        height: 65px;
        margin-bottom: 0;
    }
    .