:root {
    --color-primary: #252771;
    --color-primary-rgb: 37, 39, 113;
    --color-secondary: #2f80ed;
    --color-secondary-rgb: 47, 128, 237;
    --color-background: #ffffff;
    --color-surface: #f3f6ff;
    --color-surface-darker: #e8eeff;
    --color-text: #1a2253;
    --color-muted: #5f6d9b;
    --color-border: #d8e1fb;
    --color-success: #16a34a;
    --color-error: #dc2626;
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --radius-card: 20px;
    --shadow-xs: 0 2px 8px rgba(37, 39, 113, 0.06);
    --shadow-sm: 0 6px 16px rgba(37, 39, 113, 0.08);
    --shadow-md: 0 14px 28px rgba(37, 39, 113, 0.12);
    --shadow-lg: 0 24px 44px rgba(37, 39, 113, 0.16);
    --space-1: 4px;
    --space-2: 8px;
    --space-3: 12px;
    --space-4: 16px;
    --space-5: 20px;
    --space-6: 24px;
    --space-7: 32px;
    --transition: 0.2s cubic-bezier(0.25, 0.8, 0.25, 1);
    --font-family-base: "Vazirmatn", "IRANSans", "Segoe UI", "Tahoma", sans-serif;
    --font-size-base: clamp(14px, 1.4vw, 16px);
    --font-size-sm: 13px;
    --font-size-lg: clamp(16px, 1.6vw, 18px);
    --line-height-base: 1.7;
    color-scheme: light;
}

/*--------------------------------------------------------------
# Bootstrap Overrides
--------------------------------------------------------------*/
.btn-primary {
    background-color: var(--color-primary) !important;
    border-color: var(--color-primary) !important;
}

.btn-primary:hover {
    /* A slightly darker version of primary for hover, or use secondary */
    filter: brightness(90%);
}

.btn-secondary {
    background-color: var(--color-secondary) !important;
    border-color: var(--color-secondary) !important;
    color: #fff !important;
}

.btn-secondary:hover {
    filter: brightness(90%);
    color: #fff !important;
}

.btn-outline-secondary {
    color: var(--color-secondary) !important;
    border-color: var(--color-secondary) !important;
}

.btn-outline-secondary:hover {
    background-color: var(--color-secondary) !important;
    color: #fff !important;
}

.text-primary {
    color: var(--color-primary) !important;
}

.bg-primary {
    background-color: var(--color-primary) !important;
}

.bg-surface {
    background-color: var(--color-surface) !important;
}

.border-primary {
    border-color: var(--color-primary) !important;
}

.text-secondary {
    color: var(--color-secondary) !important;
}


*,
*::before,
*::after {
    box-sizing: border-box;
}

@font-face {
    font-family: "Vazirmatn";
    src: url("../fonts/vazir-matn/Vazirmatn-Regular.woff2") format("woff2"),
    url("../fonts/vazir-matn/Vazirmatn-Regular.ttf") format("truetype");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "Vazirmatn";
    src: url("../fonts/vazir-matn/Vazirmatn-Bold.woff2") format("woff2"),
    url("../fonts/vazir-matn/Vazirmatn-Bold.ttf") format("truetype");
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "Vazirmatn";
    src: url("../fonts/vazir-matn/Vazirmatn-ExtraBold.woff2") format("woff2"),
    url("../fonts/vazir-matn/Vazirmatn-ExtraBold.ttf") format("truetype");
    font-weight: 800;
    font-style: normal;
    font-display: swap;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: var(--font-family-base);
    font-size: var(--font-size-base);
    line-height: var(--line-height-base);
    direction: rtl;
    background-color: var(--color-background);
    color: var(--color-text);
    -webkit-font-smoothing: antialiased;
}

a {
    color: inherit;
    text-decoration: none;
    transition: color var(--transition), background-color var(--transition), border-color var(--transition);
}

a:hover {
    color: var(--color-primary);
}

img {
    display: block;
    max-width: 100%;
    height: auto;
}

button {
    font-family: inherit;
}

.cursor-pointer {
    cursor: pointer;
}

.txt-primary {
    color: var(--color-primary);
}

.txt-secondary {
    color: var(--color-secondary);
}

a.btn > i.bx {
    vertical-align:middle;
}

/*--------------------------------------------------------------
# Header & Navigation
--------------------------------------------------------------*/
.site-header {
    /*position: relative; !* Needed for absolute positioning of search bar *!*/
    z-index: 1030;
}

/* Ensure icons are vertically centered */
.site-header .btn-link {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
}

/* Header Icons (Search & User) */
.header-icon-link {
    color: var(--color-muted); /* Neutral default color */
    transition: color var(--transition);
    text-decoration: none;
}

.header-icon-link:hover,
.header-icon-link.active {
    color: var(--color-primary); /* Primary on hover/active */
}

.header-icon-link i {
    display: block; /* Ensure proper alignment */
}

.header-icon-svg {
    width: 1.55rem;
    height: 1.55rem;
    stroke: currentColor;
    stroke-width: 1.85;
    fill: none;
    stroke-linecap: round;
    stroke-linejoin: round;
    display: block;
}

/* Fine tune visual balance between custom header SVG icons */
.header-icon-svg-search {
    transform: scale(0.95);
    transform-origin: center;
}

.header-icon-svg-download {
    /* transform: scale(0.93); */
    transform-origin: center;
}

.header-icon-svg-support {
    transform: scale(0.9);
    transform-origin: center;
}

.mobile-brand {
    gap: 6px;
}

.mobile-brand-logo {
    width: 28px;
    height: 28px;
    object-fit: contain;
    flex-shrink: 0;
}

.mobile-brand-title {
    color: var(--color-text);
    font-weight: 700;
    font-size: 0.95rem;
    line-height: 1.2;
    white-space: nowrap;
}

/*--------------------------------------------------------------
# Header Search Bar
--------------------------------------------------------------*/

header .site-logo img {
    max-height: 36px;
    padding-top: 5px;
    padding-bottom: 5px;
}
@media screen and (max-width:767px) {
    header .site-logo a{
        display: flex;
        justify-content: center;
    }
    header .site-logo img {
        max-height: 36px;
        padding-top: 0;
        padding-bottom: 0;
    }

    .mobile-support-link {
        margin-right: 6px;
    }

    .mobile-brand-title {
        font-size: 0.9rem;
        max-width: 124px;
        overflow: hidden;
        text-overflow: ellipsis;
    }
}

@media screen and (min-width:768px) {
    header .site-logo img {
        max-height: 60px;
    }
}

.desktop-menu-link {
    color: var(--color-text);
    padding: 2px;
}

.desktop-menu-link.active {
    border-bottom: 2px solid var(--color-primary);
}

.mobile-menu-link {
    color: var(--color-text);
}

.mobile-menu-link.active {
    color: var(--color-primary);
    font-weight:bold;
}

#mobile-menu-toggle i {
    font-size: 45px;
}

#search-toggle i {
    font-size: 36px;
}

.header-notifications-wrapper {
    position: relative;
}

.header-notification-btn {
    min-width: 28px;
    min-height: 28px;
    position: relative;
}

.header-notification-btn i {
    font-size: 1.55rem;
    line-height: 1;
}

.header-notification-badge {
    position: absolute;
    top: -4px;
    left: -8px;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    border-radius: 999px;
    background: linear-gradient(180deg, #ef4444, #dc2626);
    color: #fff;
    font-size: 0.68rem;
    font-weight: 700;
    line-height: 18px;
    text-align: center;
    border: 1px solid #fff;
    box-shadow: 0 6px 16px rgba(220, 38, 38, 0.32);
    pointer-events: none;
}

.header-notifications-box {
    position: absolute;
    top: calc(100% + 14px);
    right: 0;
    width: min(360px, 88vw);
    background: var(--color-background);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
    z-index: 1040;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    text-align: center;
    transition: opacity var(--transition), transform var(--transition), visibility var(--transition);
}

.header-notifications-box.open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.header-notifications-inner {
    max-height: 320px;
    overflow-y: auto;
}

.header-notification-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-2);
    padding: 10px 12px;
    border-bottom: 1px solid var(--color-border);
}

.header-notification-row:last-child {
    border-bottom: none;
}

.header-notification-text {
    color: var(--color-text);
    font-size: var(--font-size-sm);
    text-align: right;
    line-height: 1.6;
}

.header-notification-date {
    color: var(--color-muted);
    font-size: 0.75rem;
    white-space: nowrap;
    flex-shrink: 0;
}

.header-notification-empty {
    color: var(--color-muted);
    padding: 14px 12px;
    font-size: var(--font-size-sm);
}

.header-search-bar {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    width: 100%;
    z-index: 1020;
    transition: all 0.05s;

    /* Overlay style */
    background-color: rgba(255, 255, 255, 0.85); /* 85% opacity white */
    backdrop-filter: blur(8px); /* Modern blur effect */
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    box-shadow: var(--shadow-sm);
}

.header-search-bar .search-form .input-group {
    position: relative;
}

.header-search-bar .search-field {
    /* The input field inside the form */
    width: 100%;
    padding: var(--space-2) 40px var(--space-2) 40px; /* Padding for icons (Left: Search, Right: Clear) */
    border: none;
    /* border-bottom: 2px solid var(--color-border); REMOVED as requested */
    background-color: transparent !important; /* Override bootstrap */
    color: var(--color-text);
    font-size: var(--font-size-lg);
    transition: border-color var(--transition);
    border-radius: 0; /* Modern flat look */
    -webkit-appearance: none; /* For iOS */
}

/* Hide the native clear button in WebKit browsers */
.header-search-bar .search-field::-webkit-search-cancel-button {
    -webkit-appearance: none;
    appearance: none;
    display: none;
}

.header-search-bar .search-field:focus {
    outline: none;
    box-shadow: none;
    border-color: var(--color-primary);
}

.header-search-bar .search-field::placeholder {
    color: var(--color-muted);
    opacity: 0.8;
}

.header-search-bar .search-submit {
    /* The search button */
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    font-size: 24px;
    color: var(--color-muted);
    transition: color var(--transition);
    padding: 0 var(--space-2) !important; /* Ensure padding is consistent */
    z-index: 5;
}

.header-search-bar .search-submit:hover {
    color: var(--color-primary);
}

/* Custom Clear Button Styling */
.header-search-bar .search-clear {
    display:flex;
    cursor:pointer;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    font-size: 24px;
    color: var(--color-muted);
    padding: 0 var(--space-2);
    z-index: 5;
    transition: color var(--transition);
}

.header-search-bar .search-clear:hover {
    color: var(--color-error); /* Red color for clear action */
}

/* Remove the default input-group-append styling */
.header-search-bar .input-group-append {
    display: contents;
}

/* Update mobile submenu toggle icon */
.mobile-nav .menu-item-has-children .toggle-submenu i {
    transition: transform var(--transition);
}

.mobile-nav .menu-item-has-children .toggle-submenu.open i {
    transform: rotate(180deg);
}

/* Make the whole row clickable */
.mobile-nav .menu-item-has-children > div {
    cursor: pointer;
}

/*--------------------------------------------------------------
# Mobile Menu
--------------------------------------------------------------*/
.mobile-menu-container {
    position: fixed;
    right: -260px; /* Start hidden */
    width: 260px;
    background-color: var(--color-background);
    z-index: 1020; /* Below header (1030) */
    transition: right 0.3s ease-in-out;
    overflow-y: auto;
    box-shadow: var(--shadow-md);
}

.mobile-menu-container.open {
    right: 0;
}

/*--------------------------------------------------------------
# User Stats Section
--------------------------------------------------------------*/
.user-stats-section {
    background-color: var(--color-surface);
    border-bottom: 1px solid var(--color-border);
    padding: 1.5rem 0;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.5rem;
    background: var(--color-background);
    border-radius: var(--radius-card);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--color-surface-darker);
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    height: 100%;
}

.stat-item:hover {
    /*transform: translateY(-4px);*/
    /*box-shadow: var(--shadow-md);*/
    /*border-color: var(--color-primary);*/
}

.stat-icon-wrapper {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: rgba(var(--color-primary-rgb), 0.1); /* Primary with opacity */
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-primary);
    font-size: 1.6rem;
    flex-shrink: 0;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.stat-item:hover .stat-icon-wrapper {
    background-color: var(--color-primary);
    color: #fff;
}

.stat-icon-wrapper.icon-online {
    background-color: rgba(var(--color-secondary-rgb), 0.1); /* Secondary with opacity */
    color: var(--color-secondary);
}

.stat-item:hover .stat-icon-wrapper.icon-online {
    background-color: var(--color-secondary);
    color: #fff;
}

.stat-content {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.stat-value {
    font-weight: 800;
    font-size: 1.25rem;
    color: var(--color-text);
    line-height: 1.2;
    white-space: nowrap;
}

.stat-label {
    font-size: 0.875rem;
    color: var(--color-muted);
    font-weight: 500;
    white-space: nowrap;
}

/* Mobile Optimization */
@media (max-width: 575.98px) {
    .user-stats-section {
        padding: 0.5rem 0;
    }

    .user-stats-section .row {
        --bs-gutter-x: 0.5rem;
        --bs-gutter-y: 0.5rem;
    }

    .stat-item {
        flex-direction: row;
        text-align: right;
        align-items: center;
        justify-content: flex-start;
        padding: 0.45rem 0.55rem;
        gap: 0.45rem;
        min-height: 52px;
    }

    .stat-icon-wrapper {
        width: 30px;
        height: 30px;
        font-size: 1.05rem;
        margin-bottom: 0;
    }

    .stat-value {
        font-size: 0.78rem;
        line-height: 1.15;
    }

    .stat-label {
        font-size: 0.66rem;
        line-height: 1.1;
    }
}

/*--------------------------------------------------------------
# Front Page - Hero Slider
--------------------------------------------------------------*/
.hero-slider-section {
    background-color: var(--color-surface);
}

.hero-slide-item {
    text-decoration: none;
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: transform var(--transition), box-shadow var(--transition);
}

.hero-slide-item:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

.slide-image-wrapper {
    position: relative;
    overflow: hidden;
    border-radius: var(--radius-md);
    aspect-ratio: 16/9; /* Modern aspect ratio */
}

.slide-image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 0 34%;
    transition: transform 0.5s ease;
}

.hero-slide-item:hover .slide-image-wrapper img {
    transform: scale(1.05);
}

.slide-title {
    font-size: var(--font-size-lg);
    line-height: 1.4;
}

.slide-desc {
    display: -webkit-box;
    -webkit-line-clamp: 1; /* Limit to 1 line on mobile */
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Owl Carousel Custom Dots */
.hero-carousel .owl-dots {
    margin-top: var(--space-4) !important;
    text-align: center;
}

.hero-carousel .owl-dot span {
    width: 8px !important;
    height: 8px !important;
    margin: 5px 4px !important;
    background: var(--color-border) !important;
    transition: all var(--transition) !important;
}

.hero-carousel .owl-dot.active span,
.hero-carousel .owl-dot:hover span {
    background: var(--color-primary) !important;
    width: 20px !important; /* Elongate active dot */
}

/*--------------------------------------------------------------
# Front Page - Latest Apps Section
--------------------------------------------------------------*/
.latest-apps-section {
    background-color: var(--color-surface-darker); /* Updated to darker surface */
}

/* Native Horizontal Scroller Styles */
.latest-apps-scroller {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    gap: 20px;
    padding-bottom: 20px; /* Space for scrollbar */
    -webkit-overflow-scrolling: touch; /* Smooth scrolling on iOS */
    scrollbar-width: thin; /* Firefox */
    scrollbar-color: var(--color-border) transparent; /* Firefox */
}

/* Custom Scrollbar for Webkit */
.latest-apps-scroller::-webkit-scrollbar {
    height: 6px;
}

.latest-apps-scroller::-webkit-scrollbar-track {
    background: transparent;
}

.latest-apps-scroller::-webkit-scrollbar-thumb {
    background-color: var(--color-border);
    border-radius: 20px;
}

.app-group-column {
    flex: 0 0 85%; /* Mobile: Show 85% of one column */
    scroll-snap-align: start;
    /* Removed background and shadow from the group container */
    background-color: transparent;
    box-shadow: none;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 10px; /* Space between items */
}

@media (min-width: 480px) {
    .app-group-column {
        flex: 0 0 60%; /* Tablet small */
    }
}

@media (min-width: 768px) {
    .app-group-column {
        flex: 0 0 45%; /* Tablet */
    }
}

@media (min-width: 1024px) {
    .app-group-column {
        flex: 0 0 32%; /* Desktop: ~3 columns visible */
    }
}

.app-card-item {
    /* Added card styling to individual items */
    background-color: var(--color-background);
    border-radius: var(--radius-card);
    box-shadow: var(--shadow-xs);
    border: 1px solid transparent; /* For smooth transition */
    transition: all var(--transition);
}

.app-card-item:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    border-color: var(--color-border);
}

.app-icon-wrapper {
    width: 60px;
    height: 60px;
    border-radius: var(--radius-sm);
    overflow: hidden;
}

.app-icon {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.app-title {
    color: var(--color-text);
    font-size: var(--font-size-base);
}

.app-desc {
    color: var(--color-muted);
    font-size: var(--font-size-sm);
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.btn-download {
    color: var(--color-secondary);
    border: 1px solid var(--color-secondary);
    font-size: var(--font-size-sm);
    padding: 4px 12px;
    transition: all var(--transition);
}

.btn-download:hover {
    background-color: var(--color-secondary);
    color: #fff;
    box-shadow: 0 4px 12px rgba(var(--color-secondary-rgb), 0.2); /* Soft shadow matching secondary color */
}

/*--------------------------------------------------------------
# Front Page - Popular Apps Section
--------------------------------------------------------------*/
.popular-apps-section {
    background-color: var(--color-surface-darker); /* Changed to darker to alternate */
}

/*--------------------------------------------------------------
# Front Page - Lifestyle Section
--------------------------------------------------------------*/
.lifestyle-section {
    background-color: var(--color-surface); /* Changed to surface to alternate */
}

.lifestyle-scroller {
    display: grid; /* Changed to Grid */
    grid-auto-flow: column;
    grid-auto-columns: 45%; /* Show ~2 items on mobile */
    gap: 20px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    padding-bottom: 20px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: var(--color-border) transparent;
}

.lifestyle-scroller::-webkit-scrollbar {
    height: 6px;
}

.lifestyle-scroller::-webkit-scrollbar-track {
    background: transparent;
}

.lifestyle-scroller::-webkit-scrollbar-thumb {
    background-color: var(--color-border);
    border-radius: 20px;
}

.lifestyle-item {
    scroll-snap-align: start;
}

@media (min-width: 768px) {
    .lifestyle-scroller {
        grid-auto-columns: 20%;
    }
}

@media (min-width: 1024px) {
    .lifestyle-scroller {
        grid-auto-columns: 16.66%;
    }
}

.app-card-vertical {
    background-color: var(--color-background);
    border-radius: var(--radius-card);
    box-shadow: var(--shadow-xs);
    overflow: hidden;
    transition: transform var(--transition), box-shadow var(--transition);
    border: 1px solid transparent;
    height: 100%; /* Fill the grid cell */
    display: flex;
    flex-direction: column;
}

.app-card-vertical:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
    border-color: var(--color-border);
}

.category-row-item {
    border-radius: var(--radius-card) !important;
}

.card-image-wrapper {
    position: relative;
    width: 100%;
    aspect-ratio: 1/1; /* Square aspect ratio for consistent sizing */
    overflow: hidden;
    background-color: var(--color-surface);
    flex-shrink: 0; /* Prevent image from shrinking */
    display: flex;
    align-items: center;
    justify-content: center;
}

.card-img {
    width: 100%;
    height: 100%;
    object-fit: contain; /* Ensure image fits without cropping */
    padding: var(--space-2); /* Add padding to prevent edge touching */
    transition: transform 0.5s ease;
}

.app-card-vertical:hover .card-img {
    transform: scale(1.05);
}

.card-content {
    flex-grow: 1; /* Allow content to fill space */
    display: flex;
    flex-direction: column;
    justify-content: flex-start; /* Align text to top */
}

.card-title {
    color: var(--color-text);
    font-size: var(--font-size-base);
    transition: color var(--transition);
}

.app-card-vertical:hover .card-title {
    color: var(--color-primary);
}

.card-desc {
    color: var(--color-muted);
    font-size: var(--font-size-sm);
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/*--------------------------------------------------------------
# Front Page - Movies & Music Section
--------------------------------------------------------------*/
.movies-music-section {
    background-color: var(--color-surface);
}

.movies-scroller {
    display: grid; /* Changed to Grid */
    grid-auto-flow: column;
    grid-auto-columns: 30%; /* Show ~3 items on mobile */
    gap: 15px; /* Slightly smaller gap for denser items */
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    padding-bottom: 20px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: var(--color-border) transparent;
}

.movies-scroller::-webkit-scrollbar {
    height: 6px;
}

.movies-scroller::-webkit-scrollbar-track {
    background: transparent;
}

.movies-scroller::-webkit-scrollbar-thumb {
    background-color: var(--color-border);
    border-radius: 20px;
}

.movies-item {
    scroll-snap-align: start;
}

@media (min-width: 480px) {
    .movies-scroller {
        grid-auto-columns: 25%;
    }
}

@media (min-width: 768px) {
    .movies-scroller {
        grid-auto-columns: 20%;
    }
}

@media (min-width: 1024px) {
    .movies-scroller {
        grid-auto-columns: 16.66%;
    }
}

/*--------------------------------------------------------------
# Footer
--------------------------------------------------------------*/
.site-footer {
    background-color: var(--color-background);
    border-top: 1px solid var(--color-border);
}

.footer-links li a:hover {
    color: var(--color-primary) !important;
}

/* Minimal Social Icons */
.site-footer .footer-social-title,
.site-footer .footer-socials {
    display: none !important;
}

.social-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: auto; /* Remove fixed width */
    height: auto; /* Remove fixed height */
    background-color: transparent; /* Remove background */
    color: var(--color-primary); /* Default color changed to primary */
    transition: all var(--transition);
}

.social-icon:hover {
    color: var(--color-secondary); /* Hover color changed to secondary for contrast */
    transform: translateY(-2px) scale(1.1); /* Subtle lift and scale */
    background-color: transparent; /* Ensure no background on hover */
}

.leading-loose {
    line-height: 2;
}

/*--------------------------------------------------------------
# Sticky Footer Nav (Ver 2)
--------------------------------------------------------------*/
.sticky-footer-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background-color: var(--color-background);
    box-shadow: 0 -2px 10px rgba(0,0,0,0.05);
    height: 60px;
    z-index: 1040;
    border-top: 1px solid var(--color-border);
}

.sticky-footer-nav .nav-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--color-muted);
    text-decoration: none;
    height: 100%;
    position: relative;
    transition: all var(--transition);
}

.sticky-footer-nav .nav-link i {
    font-size: 24px;
    margin-bottom: 2px;
}

.sticky-footer-nav .nav-text {
    font-size: 11px;
    font-weight: 600;
}

/* Active State */
.sticky-footer-nav .nav-item.active .nav-link {
    color: var(--color-primary);
}

.sticky-footer-nav .nav-item.active {
    position: relative;
}

.sticky-footer-nav .nav-item.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background-color: var(--color-primary);
    border-top-left-radius: 3px;
    border-top-right-radius: 3px;
}

/*--------------------------------------------------------------
# Modern Blog & Single Post Styles
--------------------------------------------------------------*/

/* Page Headers */
.page-header-modern {
    background-color: var(--color-surface);
    padding: 3rem 0;
    margin-bottom: 3rem;
    border-bottom: 1px solid var(--color-border);
    text-align: center;
}

.page-header-modern .page-title {
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 800;
    color: var(--color-text);
}

/* Modern Card */
.modern-card {
    background: var(--color-background);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    height: 100%;
    border: 1px solid var(--color-surface-darker);
    position: relative;
    display: flex;
    flex-direction: column;
}

.modern-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-md);
    border-color: var(--color-primary);
}

.modern-card-link {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1;
}

.modern-card-img-container {
    position: relative;
    padding-top: 60%; /* 16:9 Aspect Ratio */
    overflow: hidden;
    background-color: var(--color-surface);
}

.modern-card-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.modern-card:hover .modern-card-img {
    transform: scale(1.08);
}

.modern-card-body {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.modern-card-meta {
    font-size: 0.85rem;
    color: var(--color-muted);
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 12px;
}

.modern-card-meta i {
    font-size: 1.1em;
    vertical-align: middle;
    margin-left: 4px;
}

.modern-card-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    line-height: 1.4;
    color: var(--color-text);
    transition: color var(--transition);
}

.modern-card:hover .modern-card-title {
    color: var(--color-primary);
}

.modern-card-excerpt {
    font-size: 0.95rem;
    color: var(--color-muted);
    line-height: 1.6;
    margin-bottom: 1.5rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.modern-card-footer {
    margin-top: auto;
    padding-top: 1rem;
    border-top: 1px solid var(--color-surface-darker);
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    color: var(--color-primary);
    font-weight: 600;
}

/* Single Post Modern */
.single-hero {
    position: relative;
    padding: 3rem 0;
    background-color: var(--color-surface);
    margin-bottom: 2rem;
    border-bottom: 1px solid var(--color-border);
}

.single-post-container {
    max-width: 850px;
    margin: 0 auto;
}

.single-title {
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    font-weight: 800;
    line-height: 1.3;
    margin-bottom: 1.5rem;
    color: var(--color-text);
}

.single-meta-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    align-items: center;
    font-size: 0.9rem;
    color: var(--color-muted);
}

.single-meta-item {
    display: flex;
    align-items: center;
}

.single-meta-item i {
    font-size: 1.2em;
    margin-left: 6px;
    color: var(--color-primary);
}

.single-featured-image {
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    margin-bottom: 2rem;
}

.single-content {
    font-size: 0.95rem;
    /*line-height: 1.9;*/
    color: #374151;
}
.single-content .text-small{
    font-size:0.8rem;
}
.single-content .text-large{
    font-size:1.2rem;
}

.single-content p {
    margin-bottom: 0.8em;
}
.single-content h1,
.single-content h2, 
.single-content h3 {
    font-weight: 800;
    color: var(--color-text);
    margin-top: 1.5em;
    margin-bottom: 0.8em;
}

.single-content h1 { font-size: 1.8rem; }
.single-content h2 { font-size: 1.6rem; }
.single-content h3 { font-size: 1.3rem; }

.single-content ul, 
.single-content ol {
    margin-bottom: 0.8em;
    padding-right: 0.75em;
}

.single-content li {
    margin-bottom: 0.5em;
}

.single-content blockquote {
    border-right: 4px solid var(--color-primary);
    padding: 1em 1.2em;
    background-color: var(--color-surface);
    border-radius: var(--radius-sm);
    font-style: italic;
    margin: 1em 0;
    font-size: 0.95rem;
}

/* Author Box */
.author-box-modern {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: 2rem;
    margin-top: 4rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 1rem;
}

@media (min-width: 768px) {
    .author-box-modern {
        flex-direction: row;
        text-align: right;
        gap: 2rem;
    }
}

.author-avatar-img {
    width: 90px;
    height: 90px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid var(--color-background);
    box-shadow: var(--shadow-sm);
}

.author-name {
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

/* Comments Modern */
.comments-wrapper {
    max-width: 850px;
    margin: 4rem auto 0;
    padding-top: 2rem;
    border-top: 1px solid var(--color-border);
}

.comments-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 2rem;
}

.comment-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.comment-body {
    background: #fff;
    border: 1px solid var(--color-surface-darker);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    position: relative;
    transition: box-shadow var(--transition);
}

.comment-body:hover {
    box-shadow: var(--shadow-sm);
}

.comment-meta {
    display: flex;
    align-items: center;
    margin-bottom: 1rem;
}

.comment-author .avatar {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    margin-left: 1rem;
}

.fn {
    font-weight: 700;
    font-style: normal;
    font-size: 1rem;
    color: var(--color-text);
}

.comment-metadata {
    font-size: 0.8rem;
    color: var(--color-muted);
}

.comment-content p {
    margin-bottom: 1rem;
    font-size: 0.95rem;
    line-height: 1.6;
}

.reply {
    text-align: left;
}

.comment-reply-link {
    display: inline-flex;
    align-items: center;
    padding: 0.4rem 1rem;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--color-primary);
    background-color: rgba(111, 44, 145, 0.05);
    border-radius: var(--radius-sm);
    transition: all var(--transition);
}

.comment-reply-link:hover {
    background-color: var(--color-primary);
    color: #fff;
}

/* Comment Form */
.comment-respond {
    background-color: var(--color-surface);
    padding: 2.5rem;
    border-radius: var(--radius-lg);
    margin-top: 3rem;
    border: 1px solid var(--color-border);
}

.comment-reply-title {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    display: block;
}

.comment-form label {
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
    display: block;
}

.comment-form .form-control {
    width: 100%;
    padding: 0.8rem 1rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    background-color: var(--color-background);
    transition: all var(--transition);
    font-family: inherit;
}

.comment-form .form-control:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(111, 44, 145, 0.1);
}

.form-submit .submit {
    background-color: var(--color-primary);
    color: #fff;
    border: none;
    padding: 0.8rem 2.5rem;
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-weight: 700;
    font-size: 1rem;
    transition: all var(--transition);
    box-shadow: var(--shadow-sm);
}

.form-submit .submit:hover {
    background-color: var(--color-secondary);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

/* Pagination */
.pagination .nav-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
}

.pagination .page-numbers {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    margin: 0 4px;
    border-radius: 50%;
    background-color: var(--color-surface);
    color: var(--color-text);
    font-weight: 600;
    transition: all var(--transition);
    border: 1px solid transparent;
    text-decoration: none; /* Ensure no underline */
}

.pagination .page-numbers.current,
.pagination .page-numbers:hover {
    background-color: var(--color-primary);
    color: #fff;
    box-shadow: var(--shadow-sm);
}

.pagination .page-numbers.dots {
    background-color: transparent;
    color: var(--color-muted);
}

/*--------------------------------------------------------------
# Categories Page
--------------------------------------------------------------*/
/* Category Tabs */
.category-tabs {
    background-color: var(--color-surface);
    border-color: var(--color-border) !important;
}

.category-tab-item {
    color: var(--color-muted);
    transition: all 0.3s ease;
    text-decoration: none;
    min-width: 120px;
    text-align: center;
}

.category-tab-item:hover {
    color: var(--color-primary);
    background-color: rgba(111, 44, 145, 0.05);
}

.category-tab-item.active {
    background-color: var(--color-primary);
    color: #fff;
    box-shadow: var(--shadow-sm);
}

/* Category Card */
.category-card {
    background-color: var(--color-background);
    border-radius: var(--radius-md);
    border: 1px solid var(--color-border);
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    box-shadow: var(--shadow-xs);
}

.category-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
    border-color: var(--color-primary);
}

.category-icon-wrapper {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background-color: var(--color-surface);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: var(--color-primary);
    transition: all 0.3s ease;
}

.category-card:hover .category-icon-wrapper {
    background-color: var(--color-primary);
    color: #fff;
}

.category-title {
    transition: color 0.3s ease;
}

.category-card:hover .category-title {
    color: var(--color-primary) !important;
}

.category-arrow{
    display:flex;
}
/*--------------------------------------------------------------
# Search Page
--------------------------------------------------------------*/

.input-group > button.btn{
    display:flex;
    justify-content:center;
    align-items:center;
}

.search-header-section {
    background-color: var(--color-surface);
    border-radius: var(--radius-lg);
    padding: 2rem;
    margin-bottom: 2rem;
}

.search-form-refined .input-group {
    box-shadow: var(--shadow-sm);
    transition: box-shadow var(--transition);
}

.search-form-refined .input-group:focus-within {
    box-shadow: var(--shadow-md);
    border-color: var(--color-primary) !important;
}

.search-form-refined .form-control {
    font-size: 1.1rem;
    padding: 1rem 1.5rem;
}

.search-form-refined .form-control:focus {
    box-shadow: none;
}

.search-form-refined .btn {
    padding-left: 1.5rem;
    padding-right: 1.5rem;
    border-top-left-radius: 50rem !important;
    border-bottom-left-radius: 50rem !important;
}

/*--------------------------------------------------------------
# 404 Page
--------------------------------------------------------------*/
.error-404-container {
    box-shadow: var(--shadow-lg);
}

.error-404-illustration {
    position: relative;
    display: inline-block;
}

.error-404-illustration .error-code {
    font-size: 10rem;
    font-weight: 800;
    color: var(--color-surface-darker);
    line-height: 1;
}

.error-404-illustration .error-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 8rem;
    opacity: 0.8;
    animation: ghost-float 3s ease-in-out infinite;
}

@keyframes ghost-float {
    0%, 100% {
        transform: translate(-50%, -45%);
    }
    50% {
        transform: translate(-50%, -55%);
    }
}

/*--------------------------------------------------------------
# Single App Page (Refactored)
--------------------------------------------------------------*/

/* Header Section */
.single-app-header .app-icon-wrapper {
    width: 72px;
    height: 72px;
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    flex-shrink: 0;
    background-color: var(--color-surface);
}

.single-app-header .app-icon-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.single-app-header .app-title {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--color-text);
    line-height: 1.3;
}

.single-app-header .app-developer-name {
    font-size: 0.9rem;
    color: var(--color-success);
    font-weight: 600;
}

.single-app-header .btn-download-header {
    padding: 0.6rem 1.5rem;
    font-weight: 700;
    border-radius: 50rem;
    box-shadow: 0 4px 14px rgba(111, 44, 145, 0.3);
    transition: all var(--transition);
}

.single-app-header .btn-download-header:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(111, 44, 145, 0.4);
}

@media (min-width: 768px) {
    .single-app-header .app-icon-wrapper {
        width: 96px;
        height: 96px;
        border-radius: var(--radius-lg);
    }
    
    .single-app-header .app-title {
        font-size: 1.75rem;
    }
    
    .single-app-header .app-developer-name {
        font-size: 1rem;
    }
    
    .single-app-header .btn-download-header {
        padding: 0.75rem 2.5rem;
        font-size: 1.1rem;
    }
}

/* Mobile Info Bar */
.mobile-info-bar .info-scroll-container {
    display: flex;
    overflow-x: auto;
    gap: 12px;
    padding-bottom: 5px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.mobile-info-bar .info-scroll-container::-webkit-scrollbar {
    display: none;
}

.mobile-info-bar .info-pill-vertical {
    flex: 0 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 80px;
    padding: 0.5rem 0.75rem;
    text-align: center;
}

.mobile-info-bar .pill-icon-top {
    font-size: 1.5rem;
    margin-bottom: 4px;
    color: var(--color-muted);
}

.mobile-info-bar .pill-value-middle {
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--color-text);
    margin-bottom: 2px;
    white-space: nowrap;
}

.mobile-info-bar .pill-label-bottom {
    font-size: 0.7rem;
    color: var(--color-muted);
    white-space: nowrap;
}

/* Gallery Section */
.gallery-scroll-wrapper {
    display: flex;
    overflow-x: auto;
    gap: 16px;
    padding-bottom: 16px;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: var(--color-border) transparent;
}

.gallery-scroll-wrapper::-webkit-scrollbar {
    height: 6px;
}

.gallery-scroll-wrapper::-webkit-scrollbar-track {
    background: transparent;
}

.gallery-scroll-wrapper::-webkit-scrollbar-thumb {
    background-color: var(--color-border);
    border-radius: 20px;
}

.gallery-slide {
    scroll-snap-align: start;
    flex: 0 0 auto;
    height: 450px;
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--color-surface-darker);
    transition: transform var(--transition);
}

.gallery-slide:hover {
    transform: translateY(-2px);
}

.gallery-image {
    height: 100%;
    width: auto;
    object-fit: cover;
    display: block;
}

@media (max-width: 576px) {
    .gallery-slide {
        height: 350px;
    }
}

/* General Content Sections */
.section-heading {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--color-text);
    position: relative;
    padding-right: 12px;
}

.section-heading::before {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 24px;
    background-color: var(--color-primary);
    border-radius: 4px;
}

/* Desktop Info Box */
.info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.8rem 0;
    border-bottom: 1px solid var(--color-border);
}

.info-row:last-child {
    border-bottom: none;
}

.info-key {
    color: var(--color-muted);
    font-weight: 500;
}

.info-val {
    font-weight: 600;
    color: var(--color-text);
    text-align: left;
}

/* Download Cards */
.download-card {
    transition: all var(--transition);
}

.download-card:hover {
    border-color: var(--color-primary) !important;
    box-shadow: var(--shadow-sm);
}

.download-note {
    color: var(--color-muted) !important;
    font-size: 0.85rem;
}

.meta-badge {
    display: inline-flex;
    align-items: center;
    background-color: var(--color-surface-darker);
    padding: 4px 10px;
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    color: var(--color-muted);
    white-space: nowrap;
}

.meta-badge i {
    margin-left: 6px;
    font-size: 1.1em;
}

/* Related Apps Section (Using lifestyle-scroller styles) */
.related-apps-scroller {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: 45%;
    gap: 20px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    padding-bottom: 20px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: var(--color-border) transparent;
}

.related-apps-scroller::-webkit-scrollbar {
    height: 6px;
}

.related-apps-scroller::-webkit-scrollbar-track {
    background: transparent;
}

.related-apps-scroller::-webkit-scrollbar-thumb {
    background-color: var(--color-border);
    border-radius: 20px;
}

.related-app-item {
    scroll-snap-align: start;
}

@media (min-width: 768px) {
    .related-apps-scroller {
        grid-auto-columns: 20%;
    }
}

@media (min-width: 1024px) {
    .related-apps-scroller {
        grid-auto-columns: 16.66%;
    }
}
.appeman-banner img{
    margin-right: auto;
    margin-left: auto;
}

.enamad img{
    max-height:90px;
}


.pmpro_msg.pmpro_error {
    background-color: #eb3f3f;
    padding: 5px 10px;
    color: white;
    text-align: center;
}

.pmpro-levels-container .price-section > .h2 + .text-muted.small{
    display:none;
}

@media screen and (max-width: 768px) {
    #site-footer{
        display:none;
    }
    .header-notifications-wrapper {
        margin-bottom: 3px;
    }
}
@media screen and (min-width: 992px) {
    .header-notifications-box {
        left: -50px;
        right:unset;
    }
}


.pmpro-level-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border-radius: var(--radius-lg) !important;
    background: var(--color-surface);
    border: 1px solid var(--color-border) !important;
}

.pmpro-level-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md) !important;
    border-color: var(--color-primary) !important;
}

.pmpro-level-card.current-level {
    border: 2px solid var(--color-success) !important;
    background: #f0fdf4;
}

.pmpro-level-card .price-section .h2 {
    color: var(--color-primary);
}

.pmpro-level-card .original-price {
    font-size: 0.85rem;
    line-height: 1.2;
}

.pmpro-level-card .original-price del {
    color: #000;
    text-decoration-color: #dc2626;
    text-decoration-thickness: 1.2px;
}

.pmpro-level-card .level-description ul {
    list-style: none;
    padding: 0;
    text-align: right;
}

.pmpro-level-card .level-description li {
    margin-bottom: 10px;
    padding-right: 25px;
    position: relative;
}

.pmpro-level-card .level-description li:before {
    content: '\2713';
    position: absolute;
    right: 0;
    color: var(--color-secondary);
    font-weight: bold;
}

@media (max-width: 767.98px) {
    .pmpro-levels-container {
        padding-top: 12px !important;
        padding-bottom: 12px !important;
        margin-bottom: 50px !important;
    }
    .pmpro_msg.pmpro_error{
        margin-bottom: 30px !important;
    }

    .pmpro-levels-container .text-center.mb-5 {
        margin-top: 0.75rem !important;
        margin-bottom: 0.75rem !important;
    }

    .pmpro-levels-container .text-center.mb-5 p {
        display: none;
    }

    .pmpro-levels-container .text-center.mb-5 h2 {
        font-size: 1.05rem;
        margin-bottom: 0 !important;
        margin-top: -35px !important;
    }

    .pmpro-levels-container .row.g-4 {
        --bs-gutter-x: 0.65rem;
        --bs-gutter-y: 0.65rem;
    }

    .pmpro-levels-container .col-md-6 {
        width: 100%;
        flex: 0 0 auto;
    }

    .pmpro-level-card {
        border-radius: 10px !important;
    }

    .pmpro-level-card .card-body {
        padding: 0.85rem !important;
    }

    .pmpro-level-card .card-title {
        font-size: 0.95rem;
        line-height: 1.2;
        margin-bottom: 0.45rem !important;
    }

    .pmpro-level-card .current-plan-badge {
        margin-bottom: 0.45rem !important;
    }

    .pmpro-level-card .price-section {
        margin-bottom: 0.65rem !important;
    }

    .pmpro-level-card .original-price {
        font-size: 0.78rem;
        margin-bottom: 0.2rem !important;
    }

    .pmpro-level-card .price-section .h2,
    .pmpro-level-card .price-section .h3 {
        font-size: 1rem !important;
        margin: 0;
    }

    .pmpro-level-card .level-description {
        display: block !important;
        margin-bottom: 0.65rem !important;
        font-size: 0.82rem;
        line-height: 1.5;
    }

    .pmpro-level-card .action-button .btn {
        padding: 0.4rem 0.45rem !important;
        font-size: 0.78rem;
    }
}
