:root {
    --primary: #F97316;
    /* Vibrant Premium Orange */
    --primary-dark: #EA580C;
    --secondary: #3B82F6;
    /* Premium Blue */
    --bg-light: #F8FAFC;
    --bg-white: #FFFFFF;
    --text-dark: #0F172A;
    --text-gray: #475569;
    --text-light: #94A3B8;
    --border: #E2E8F0;
    --shadow: rgba(0, 0, 0, 0.05);
    --shadow-hover: rgba(0, 0, 0, 0.1);
    --success: #10B981;
    --warning: #F59E0B;
    --star-color: #FBBF24;
    --mod-badge: #EF4444;
    --updated-badge: #22C55E;
}

/* Dark Mode Variables */
[data-theme="dark"] {
    --bg-light: #0F172A;
    --bg-white: #1E293B;
    --text-dark: #F8FAFC;
    --text-gray: #94A3B8;
    --text-light: #64748B;
    --border: #334155;
    --shadow: rgba(0, 0, 0, 0.3);
    --shadow-hover: rgba(0, 0, 0, 0.5);
}

/* Auto Dark Mode Detection */
@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) {
        --bg-light: #0F172A;
        --bg-white: #1E293B;
        --text-dark: #F8FAFC;
        --text-gray: #94A3B8;
        --text-light: #64748B;
        --border: #334155;
        --shadow: rgba(0, 0, 0, 0.3);
        --shadow-hover: rgba(0, 0, 0, 0.5);
    }
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--bg-light);
    color: var(--text-dark);
    margin: 0;
    padding: 0;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a {
    text-decoration: none;
    color: inherit;
    transition: all 0.3s ease;
}

a:hover {
    color: var(--primary);
}

/* Header */
.site-header {
    background: var(--bg-white);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 16px 0;
    box-shadow: 0 2px 8px var(--shadow);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-left,
.header-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-dark);
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo i {
    color: var(--primary);
    font-size: 28px;
}

.mobile-nav-toggle,
.search-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--text-dark);
    font-size: 20px;
    cursor: pointer;
    padding: 5px;
}

.search-bar {
    position: relative;
    flex: 0 1 400px;
}

.search-icon {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-gray);
}

.search-input {
    width: 100%;
    padding: 10px 15px 10px 40px;
    background: var(--bg-light);
    border: 1px solid var(--border);
    border-radius: 12px;
    font-size: 14px;
    transition: all 0.3s ease;
}

.search-input:focus {
    border-color: var(--primary);
    background: var(--bg-white);
    box-shadow: 0 0 0 4px rgba(249, 115, 22, 0.1);
}

.nav-links {
    display: flex;
    gap: 32px;
    align-items: center;
}

.nav-links a {
    font-weight: 500;
    color: var(--text-gray);
    font-size: 15px;
    position: relative;
    padding: 8px 0;
}

.nav-links a:hover {
    color: var(--primary);
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: width 0.3s ease;
}

.nav-links a:hover::after {
    width: 100%;
}

.theme-toggle-nav {
    background: var(--bg-light);
    border: 1px solid var(--border);
    color: var(--text-gray);
    width: 40px;
    height: 40px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 1.1rem;
    margin-left: 8px;
    outline: none;
}

.theme-toggle-nav:hover {
    background: var(--bg-white);
    border-color: var(--primary);
    color: var(--primary);
    transform: rotate(15deg) scale(1.1);
    box-shadow: 0 4px 12px var(--shadow);
}

.theme-toggle-nav.dark {
    color: #FBBF24;
    /* Sun/Moon Gold */
}

.theme-toggle-nav.light {
    color: #3B82F6;
    /* Desktop/Day Blue */
}

.search-bar {
    position: relative;
    flex: 1;
    max-width: 400px;
}

.search-input {
    background: var(--bg-light);
    border: 1px solid var(--border);
    padding: 10px 20px 10px 40px;
    border-radius: 24px;
    color: var(--text-dark);
    width: 100%;
    outline: none;
    transition: all 0.3s ease;
    font-size: 14px;
}

.search-input:focus {
    border-color: var(--primary);
    background: var(--bg-white);
    box-shadow: 0 0 0 3px rgba(255, 107, 53, 0.1);
}

.search-bar::before {
    content: '\f002';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-light);
    pointer-events: none;
}

/* Live Search Results Dropdown */
.search-results-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg-white);
    border: 1px solid var(--border);
    border-radius: 12px;
    margin-top: 10px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    z-index: 2000;
    display: none;
    overflow: hidden;
}

[data-theme="dark"] .search-results-dropdown {
    background: var(--bg-white);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.4);
}

.search-results-dropdown.active {
    display: block;
}

.search-result-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 15px;
    transition: all 0.2s ease;
    border-bottom: 1px solid var(--border);
}

.search-result-item:last-child {
    border-bottom: none;
}

.search-result-item:hover {
    background: var(--bg-light);
}

.search-result-icon {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    object-fit: cover;
}

.search-result-info {
    flex: 1;
    min-width: 0;
}

.search-result-title {
    display: block;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-dark);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.search-result-category {
    font-size: 0.75rem;
    color: var(--text-light);
}

.no-results-msg {
    padding: 15px;
    text-align: center;
    color: var(--text-gray);
    font-size: 0.9rem;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, #F97316 0%, #EA580C 100%);
    position: relative;
    padding: 80px 0;
    text-align: center;
    margin-bottom: 40px;
    overflow: hidden;
}

[data-theme="dark"] .hero {
    background: linear-gradient(135deg, #1E293B 0%, #0F172A 100%);
}

.hero::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 20% 30%, rgba(255, 255, 255, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(255, 255, 255, 0.05) 0%, transparent 50%);
    pointer-events: none;
}

.hero h1 {
    font-size: 2.8rem;
    margin-bottom: 12px;
    color: white;
    font-weight: 700;
}

.hero p {
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.9);
    max-width: 600px;
    margin: 0 auto;
    font-weight: 400;
}

/* Grid Layouts */
.section-title {
    font-size: 1.5rem;
    margin: 40px 0 24px;
    color: var(--text-dark);
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
}

.section-title i {
    font-size: 1.3rem;
}

.app-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px 24px;
    margin-top: 20px;
    margin-bottom: 50px;
}

@media (max-width: 992px) {
    .app-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .app-grid {
        grid-template-columns: 1fr;
    }
}

/* 3-column grid like APKMody */
.app-grid.grid-3 {
    grid-template-columns: repeat(3, 1fr);
}

/* Section Header with View All link */
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 40px 0 10px;
    gap: 15px;
}

.section-header .section-title {
    margin: 0;
    flex: 1;
    min-width: 0;
}

.section-description {
    color: var(--text-gray);
    font-size: 0.95rem;
    margin-bottom: 20px;
    opacity: 0.8;
}

.view-all {
    color: var(--primary);
    font-weight: 500;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.view-all:hover {
    color: var(--primary-dark);
    gap: 10px;
}

.view-all i {
    font-size: 0.8rem;
}

/* Category Pills Slider */
.category-pills-slider {
    margin-bottom: 30px;
    overflow: hidden;
    position: relative;
}

.category-pills-track {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding: 5px 0 15px;
    scrollbar-width: none;
    /* Firefox */
    -ms-overflow-style: none;
    /* IE/Edge */
}

.category-pills-track::-webkit-scrollbar {
    display: none;
    /* Chrome/Safari */
}

.cat-pill {
    display: inline-block;
    padding: 8px 20px;
    background: var(--bg-white);
    border: 1px solid var(--border);
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-dark);
    white-space: nowrap;
    transition: all 0.3s ease;
}

.cat-pill:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.cat-pill.active {
    background: var(--text-dark);
    color: white;
    border-color: var(--text-dark);
}

[data-theme="dark"] .cat-pill {
    background: var(--bg-white);
}

[data-theme="dark"] .cat-pill.active {
    background: var(--primary);
    border-color: var(--primary);
}

@media (max-width: 768px) {
    .section-header {
        display: flex !important;
        flex-direction: row !important;
        justify-content: space-between !important;
        align-items: center !important;
        flex-wrap: nowrap !important;
        gap: 10px;
        margin-bottom: 10px;
    }

    .section-header .section-title {
        font-size: 1.2rem;
        flex: 1;
        min-width: 0;
        margin: 0;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .view-all {
        font-size: 0.8rem;
        padding: 6px 10px;
        background: var(--bg-light);
        border-radius: 8px;
        border: 1px solid var(--border);
        flex-shrink: 0;
    }
}

@media (max-width: 480px) {
    .section-header .section-title {
        font-size: 1.1rem;
    }

    .section-description {
        font-size: 0.85rem;
    }
}



/* App category tag */
.app-category {
    font-size: 0.75rem;
    color: var(--secondary);
    margin-bottom: 4px;
    font-weight: 500;
}

/* MOD badge style */
.app-mod {
    display: inline-block;
    background: rgba(255, 107, 53, 0.1);
    color: var(--primary);
    font-size: 0.7rem;
    padding: 3px 8px;
    border-radius: 4px;
    font-weight: 600;
    margin-top: 6px;
}

.app-card {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    padding: 0;
    display: flex;
    align-items: flex-start;
    gap: 16px;
    transition: transform 0.2s ease;
}

.app-card:hover {
    transform: translateY(-4px);
}

/* App List View - Premium Layout */
.app-list-view {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 20px;
    margin-bottom: 40px;
}

.app-list-item {
    background: var(--bg-white);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    gap: 16px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 8px var(--shadow);
}

.app-list-item:hover {
    transform: translateX(6px);
    border-color: var(--primary);
    box-shadow: 0 4px 15px var(--shadow-hover);
    background: var(--bg-white);
}

.app-list-icon {
    flex-shrink: 0;
}

.app-list-icon img {
    width: 60px;
    height: 60px;
    border-radius: 14px;
    object-fit: cover;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.app-list-info {
    flex: 1;
    min-width: 0;
}

.app-list-title {
    font-size: 1rem;
    font-weight: 700;
    margin: 0 0 4px 0;
    color: var(--text-dark);
    display: -webkit-box;
    -webkit-line-clamp: 1;
    line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.app-list-meta {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;
    color: var(--text-light);
    font-weight: 500;
}

.app-list-meta .dot {
    color: var(--border);
    font-size: 0.6rem;
}

.app-list-meta .mod-text {
    color: var(--primary);
    font-weight: 600;
}

.app-list-action {
    flex-shrink: 0;
}

.btn-get {
    background: var(--bg-light);
    color: var(--primary);
    font-size: 0.75rem;
    font-weight: 800;
    padding: 6px 16px;
    border-radius: 20px;
    transition: all 0.3s ease;
    border: 1px solid var(--border);
}

.app-list-item:hover .btn-get {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

@media (max-width: 600px) {
    .app-list-meta span:nth-child(n+4) {
        display: none;
    }
}

/* Ultra Compact List Design */
.compact-list-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin-top: 20px;
    margin-bottom: 40px;
}

.compact-app-item {
    background: var(--bg-white);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 10px;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: all 0.2s ease;
    width: 100%;
}

.compact-app-item:hover {
    border-color: var(--primary);
    background: var(--bg-light);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px var(--shadow);
}

.compact-app-icon {
    width: 44px;
    height: 44px;
    border-radius: 10px;
    object-fit: cover;
    flex-shrink: 0;
}

.compact-app-details {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.compact-app-title {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--text-dark);
    display: -webkit-box;
    -webkit-line-clamp: 1;
    line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.compact-app-category {
    font-size: 0.75rem;
    color: var(--text-light);
    font-weight: 500;
}

.compact-arrow {
    font-size: 0.7rem;
    color: var(--border);
    transition: all 0.2s ease;
}

.compact-app-item:hover .compact-arrow {
    color: var(--primary);
    transform: translateX(3px);
}

@media (max-width: 768px) {
    .compact-list-grid {
        grid-template-columns: 1fr;
    }
}

/* Horizontal Premium Slider */
.app-slider-outer {
    position: relative;
    width: 100%;
    overflow: hidden;
    margin: 20px 0 40px;
    padding: 10px 0;
}

.app-slider-track {
    display: flex;
    overflow-x: auto;
    scroll-behavior: smooth;
    gap: 16px;
    padding: 10px 4px 20px;
    -ms-overflow-style: none;
    /* IE and Edge */
    scrollbar-width: none;
    /* Firefox */
}

.app-slider-track::-webkit-scrollbar {
    display: none;
    /* Chrome, Safari and Opera */
}

/* Slider Card Design */
.slider-app-card {
    flex: 0 0 140px;
    background: var(--bg-white);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 10px var(--shadow);
}

.slider-app-card:hover {
    transform: translateY(-8px);
    border-color: var(--primary);
    box-shadow: 0 10px 20px var(--shadow-hover);
}

.slider-icon-outer {
    width: 90px;
    height: 90px;
    margin-bottom: 12px;
    position: relative;
    border-radius: 22px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.slider-icon-outer img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.slider-app-info {
    width: 100%;
}

.slider-app-title {
    font-size: 0.85rem;
    font-weight: 700;
    margin: 0 0 4px 0;
    color: var(--text-dark);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.3;
}

.slider-app-cat {
    font-size: 0.7rem;
    color: var(--text-light);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

/* Mobile adjustments */
@media (max-width: 600px) {
    .slider-app-card {
        flex: 0 0 120px;
        padding: 10px;
    }

    .slider-icon-outer {
        width: 70px;
        height: 70px;
    }
}




.app-icon-wrapper {
    flex-shrink: 0;
}

.app-icon {
    width: 80px !important;
    height: 80px !important;
    min-width: 80px;
    min-height: 80px;
    border-radius: 20px;
    object-fit: cover;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.app-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding-top: 4px;
}

.app-title {
    font-size: 1.05rem;
    /* Perfect size */
    font-weight: 700;
    margin: 0;
    color: var(--text-dark);
    display: -webkit-box;
    -webkit-line-clamp: 1;
    line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
    letter-spacing: -0.01em;
}

.app-category-size-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* New Badge Style for Category */
.app-badge-category {
    display: inline-block;
    background: var(--border);
    /* Slightly darker than light bg */
    color: var(--text-gray);
    font-size: 0.85rem;
    padding: 3px 10px;
    border-radius: 6px;
    font-weight: 500;
    width: fit-content;
    opacity: 0.8;
}

[data-theme="dark"] .app-badge-category {
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-light);
}

.app-size-text {
    font-size: 0.85rem;
    color: var(--text-light);
    display: flex;
    align-items: center;
}

.app-size-text::before {
    content: '●';
    color: var(--primary);
    font-size: 0.5rem;
    margin-right: 8px;
    margin-left: 4px;
}

.app-meta-row {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
    color: #888;
    margin-top: 2px;
}

.app-meta-item {
    display: flex;
    align-items: center;
}

.app-meta-item::before {
    content: '●';
    color: var(--primary);
    /* Orange bullet */
    font-size: 0.5rem;
    margin-right: 8px;
}

.app-meta-item:not(:first-child)::before {
    margin-left: 8px;
}

/* App Details Page - Premium Hero */
.app-page-hero {
    position: relative;
    border-radius: 20px;
    padding: 40px;
    margin-bottom: 30px;
    color: white;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    overflow: hidden;
    min-height: 220px;
    display: flex;
    align-items: center;
}

.app-hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-size: cover;
    background-position: center;
    filter: blur(50px) brightness(0.7);
    transform: scale(1.2);
    z-index: 0;
}

.app-hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.7) 0%, rgba(15, 23, 42, 0.4) 100%);
    z-index: 1;
}

[data-theme="dark"] .app-hero-overlay {
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.9) 0%, rgba(15, 23, 42, 0.7) 100%);
}

.app-hero-container {
    position: relative;
    z-index: 2;
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    gap: 30px;
}

.app-hero-main {
    display: flex;
    gap: 24px;
    align-items: center;
    flex: 1;
}

.app-hero-icon {
    width: 120px;
    height: 120px;
    border-radius: 28px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
    object-fit: cover;
    border: 3px solid rgba(255, 255, 255, 0.1);
}

.app-hero-details {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.app-hero-title {
    font-size: 2rem;
    font-weight: 800;
    margin: 0;
    color: white;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

.app-hero-meta-row {
    display: flex;
    align-items: center;
    gap: 12px;
}

.app-hero-actions {
    display: flex;
    flex-direction: column;
    gap: 16px;
    min-width: 200px;
}

.btn-hero-download {
    background: var(--primary);
    color: white;
    padding: 14px 28px;
    border-radius: 14px;
    font-weight: 700;
    font-size: 1.05rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    box-shadow: 0 4px 15px rgba(249, 115, 22, 0.3);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-hero-download:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(249, 115, 22, 0.5);
    background: var(--primary-dark);
}

.app-hero-stats {
    display: flex;
    justify-content: center;
    gap: 20px;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.9);
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-weight: 500;
}

/* App Info Table - Restored Design */
.app-info-table {
    background: var(--bg-white);
    border-radius: 16px;
    padding: 0;
    margin-bottom: 30px;
    border: 1px solid var(--border);
    box-shadow: 0 4px 12px var(--shadow);
    overflow: hidden;
}

.info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 24px;
    border-bottom: 1px solid var(--border);
    transition: background 0.2s ease;
}

.info-row:last-child {
    border-bottom: none;
}

.info-row:hover {
    background: var(--bg-light);
}

.info-label {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--text-light);
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.info-label i {
    color: var(--primary);
    font-size: 1.1rem;
    width: 24px;
    text-align: center;
}

.info-value {
    color: var(--text-dark);
    font-size: 1rem;
    font-weight: 600;
    text-align: right;
}

.info-link {
    color: var(--primary);
    text-decoration: none;
    transition: color 0.2s;
}

.info-link:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

.app-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 16px 0;
}

.badge {
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 500;
}

.badge-mod {
    background: rgba(255, 107, 53, 0.1);
    color: var(--primary);
    border: 1px solid rgba(255, 107, 53, 0.2);
}

.btn,
.btn-primary {
    background: var(--primary);
    color: white;
    font-weight: 600;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 0.95rem;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn:hover,
.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(255, 107, 53, 0.3);
    color: white;
}

/* Download Button */
.btn-download-main {
    background: linear-gradient(135deg, #E91E63 0%, #F06292 100%);
    color: white;
    font-weight: 600;
    padding: 16px;
    border-radius: 12px;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 16px;
    box-shadow: 0 4px 12px rgba(233, 30, 99, 0.3);
    transition: all 0.3s ease;
}

.btn-download-main:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(233, 30, 99, 0.4);
    color: white;
}

.btn-download-lg {
    background: var(--primary);
    color: white;
    font-weight: 600;
    padding: 14px 32px;
    border-radius: 10px;
    font-size: 1.05rem;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-top: 16px;
    box-shadow: 0 4px 12px rgba(255, 107, 53, 0.2);
}

.btn-download-lg:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(255, 107, 53, 0.3);
    background: var(--primary-dark);
    color: white;
}

/* MOD Info Section */
.mod-info-section {
    background: var(--bg-white);
    border-radius: 12px;
    margin-bottom: 24px;
    border: 1px solid var(--border);
    box-shadow: 0 2px 4px var(--shadow);
    overflow: hidden;
}

.mod-info-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
    cursor: pointer;
    color: var(--secondary);
    font-weight: 600;
    font-size: 0.95rem;
    transition: background 0.3s ease;
}

.mod-info-header:hover {
    background: var(--bg-light);
}

.mod-info-header i:first-child {
    color: var(--secondary);
}

.mod-info-header i:last-child {
    margin-left: auto;
    font-size: 0.8rem;
}

.mod-info-content {
    padding: 0 20px 20px;
    color: var(--text-gray);
    line-height: 1.6;
    font-size: 0.9rem;
    border-top: 1px solid var(--border);
}

.mod-info-content p {
    margin: 16px 0 0;
}

.content-box {
    background: var(--bg-white);
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 24px;
    border: 1px solid var(--border);
    box-shadow: 0 2px 4px var(--shadow);
}

.content-box h2 {
    color: var(--text-dark);
    margin: 0 0 20px 0;
    font-size: 1.3rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 12px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--border);
}

.content-box h2 i {
    color: var(--primary);
    font-size: 1.2rem;
}

.app-description {
    color: var(--text-gray);
    line-height: 1.8;
    font-size: 0.95rem;
}

/* Screenshots Slider */
.slider-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    border-bottom: 2px solid var(--bg-light);
    padding-bottom: 12px;
}

.slider-header h2 {
    margin: 0;
    border: none;
    padding: 0;
}

.slider-controls {
    display: flex;
    gap: 8px;
}

.slider-btn {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    border: 1px solid var(--border);
    background: var(--bg-white);
    color: var(--text-gray);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.slider-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: var(--bg-light);
}

.screenshots-slider {
    display: flex;
    overflow-x: auto;
    gap: 16px;
    padding-bottom: 12px;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    /* Firefox */
}

.screenshots-slider::-webkit-scrollbar {
    display: none;
    /* Chrome/Safari */
}

.slider-item {
    flex: 0 0 auto;
    scroll-snap-align: start;
}

.screenshot-img {
    width: auto;
    max-width: 500px;
    height: 300px;
    object-fit: cover;
    border-radius: 12px;
    border: 1px solid var(--border);
    box-shadow: 0 4px 10px var(--shadow);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: zoom-in;
}

.screenshot-img:hover {
    transform: scale(1.03);
    box-shadow: 0 8px 20px var(--shadow);
}

/* Lightbox Modal */
.lightbox-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(8px);
    justify-content: center;
    align-items: center;
    flex-direction: column;
}

.lightbox-content {
    position: relative;
    max-width: 90%;
    max-height: 85%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.lightbox-slide {
    display: none;
    animation: zoomIn 0.3s ease-out;
}

.lightbox-image {
    max-width: 100%;
    max-height: 80vh;
    border-radius: 12px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    object-fit: contain;
}

.lightbox-close {
    position: absolute;
    top: 30px;
    right: 30px;
    color: white;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    z-index: 10000;
    transition: color 0.2s;
}

.lightbox-close:hover {
    color: var(--primary);
}

.lightbox-prev,
.lightbox-next {
    cursor: pointer;
    position: absolute;
    top: 50%;
    width: auto;
    padding: 20px;
    margin-top: -30px;
    color: white;
    font-weight: bold;
    font-size: 30px;
    transition: 0.3s ease;
    border-radius: 0 3px 3px 0;
    user-select: none;
    -webkit-user-select: none;
    text-decoration: none;
}

.lightbox-next {
    right: -80px;
    border-radius: 3px 0 0 3px;
}

.lightbox-prev {
    left: -80px;
}

.lightbox-prev:hover,
.lightbox-next:hover {
    color: var(--primary);
    transform: scale(1.1);
}

@keyframes zoomIn {
    from {
        transform: scale(0.9);
        opacity: 0;
    }

    to {
        transform: scale(1);
        opacity: 1;
    }
}

@media (max-width: 900px) {

    .lightbox-prev,
    .lightbox-next {
        padding: 10px;
        font-size: 20px;
    }

    .lightbox-next {
        right: 0;
    }

    .lightbox-prev {
        left: 0;
    }
}

@media (max-width: 900px) {
    .app-page-hero {
        padding: 30px;
    }

    .app-hero-container {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
    }

    .app-hero-actions {
        width: 100%;
    }

    .app-quick-info {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .app-page-hero {
        padding: 24px;
        border-radius: 0;
        margin: -24px -16px 24px -16px;
        /* Bleed to edges on mobile */
    }

    .app-hero-main {
        flex-direction: row;
        /* Icon left, title right */
        text-align: left;
        align-items: center;
        width: 100%;
        gap: 16px;
    }

    .app-hero-icon {
        width: 70px;
        height: 70px;
        border-radius: 16px;
    }

    .app-hero-details {
        gap: 4px;
    }

    .app-hero-title {
        font-size: 1.2rem;
        font-weight: 700;
    }

    .app-hero-meta-row {
        justify-content: flex-start;
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 4px !important;
    }

    /* Hide Category and Developer on Mobile as requested */
    .app-badge-category,
    .hero-dev-meta .hero-dev {
        display: none !important;
    }

    /* Move hero-date-mod up since dev is hidden */
    .hero-dev-meta {
        gap: 0 !important;
    }

    .hero-date-mod {
        font-size: 0.8rem !important;
        gap: 8px !important;
        flex-wrap: wrap;
        margin-top: -4px;
    }

    .app-hero-container {
        gap: 15px;
    }

    .btn-hero-download {
        padding: 10px 20px;
        font-size: 0.95rem;
    }

    .slider-item {
        flex: 0 0 200px;
    }

    .screenshot-img {
        height: 400px;
    }

    /* Info Table Mobile Fix: Label: Value on one line */
    .app-info-table {
        border-radius: 12px;
        margin-bottom: 20px;
    }

    .info-row {
        display: flex !important;
        flex-direction: row !important;
        /* justify-content: flex-start !important; */
        align-items: center !important;
        padding: 12px 16px !important;
        gap: 8px !important;
        flex-wrap: nowrap !important;
    }

    .info-label {
        font-size: 0.8rem !important;
        flex-shrink: 0 !important;
        text-transform: none !important;
        /* Make it more readable as a label */
        color: var(--text-gray) !important;
    }

    .info-label i {
        display: none !important;
    }

    .info-label span {
        font-weight: 700 !important;
    }

    .info-label span::after {
        content: ":";
    }

    .info-value {
        text-align: left !important;
        font-size: 0.85rem !important;
        width: auto !important;
        color: var(--text-dark) !important;
    }
}

/* Mobile Header & Nav Fixes */
@media (max-width: 900px) {
    .site-header {
        padding: 12px 0;
    }

    .mobile-nav-toggle,
    .search-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 36px;
        height: 36px;
        background: var(--bg-light);
        border-radius: 10px;
    }

    .logo {
        font-size: 20px !important;
    }

    .logo span {
        display: inline-block !important;
        /* Keep site name but smaller */
        font-size: 18px;
    }

    .search-bar {
        position: fixed;
        top: 72px;
        left: 0;
        right: 0;
        background: var(--bg-white);
        padding: 15px;
        border-bottom: 1px solid var(--border);
        display: none;
        z-index: 999;
    }

    .search-bar.active {
        display: block;
    }

    .nav-links {
        position: fixed;
        top: 72px;
        left: -100%;
        width: 80%;
        height: calc(100vh - 72px);
        background: var(--bg-white);
        flex-direction: column;
        align-items: flex-start;
        padding: 30px;
        gap: 20px;
        transition: left 0.3s ease;
        box-shadow: 10px 0 30px rgba(0, 0, 0, 0.1);
        z-index: 1000;
    }

    .nav-links.active {
        left: 0;
    }

    .nav-links a {
        font-size: 18px;
        width: 100%;
        padding: 10px 0;
        border-bottom: 1px solid var(--border);
    }
}

/* Download Section */
.download-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.download-item {
    background: var(--bg-light);
    padding: 20px;
    border-radius: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    border: 1px solid var(--border);
    transition: all 0.3s ease;
}

.download-item:hover {
    border-color: var(--primary);
    box-shadow: 0 4px 12px var(--shadow);
}

.download-info {
    flex: 1;
}

.download-info h3 {
    color: var(--text-dark);
    margin: 0 0 8px 0;
    font-size: 1.1rem;
    font-weight: 600;
}

.download-meta {
    display: flex;
    gap: 16px;
    color: var(--text-gray);
    font-size: 0.85rem;
    margin-bottom: 8px;
}

.download-meta span {
    display: flex;
    align-items: center;
    gap: 6px;
}

.download-meta i {
    color: var(--text-light);
}

.download-changelog {
    color: var(--text-gray);
    font-size: 0.9rem;
    margin: 8px 0 0;
    line-height: 1.5;
}

.btn-download {
    flex-shrink: 0;
    padding: 12px 24px;
    white-space: nowrap;
}

.download-list .item {
    background: var(--bg-white);
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 1px solid var(--border);
    transition: all 0.3s ease;
}

.download-list .item:hover {
    border-color: var(--primary);
    box-shadow: 0 4px 12px var(--shadow);
    transform: translateX(4px);
}

.download-list .item h3 {
    color: var(--text-dark);
    margin: 0 0 4px 0;
    font-size: 1.1rem;
}

.download-list .item small {
    color: var(--text-light);
}

.download-list .item p {
    color: var(--primary);
    margin: 4px 0 0 0;
    font-size: 0.9rem;
}

/* Breadcrumb */
.breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 0;
    margin-bottom: 16px;
    font-size: 0.9rem;
    color: var(--text-gray);
}

.breadcrumb a {
    color: var(--text-gray);
    transition: color 0.3s ease;
}

.breadcrumb a:hover {
    color: var(--primary);
}

.breadcrumb-separator {
    color: var(--text-light);
    user-select: none;
}

.breadcrumb-current {
    color: var(--text-dark);
    font-weight: 500;
}

/* Page Header (for category/publisher pages) */
.page-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 16px;
    padding: 40px 32px;
    margin-bottom: 32px;
    color: white;
    box-shadow: 0 4px 16px var(--shadow);
}

.page-header-content {
    display: flex;
    align-items: center;
    gap: 24px;
}

.page-header-icon {
    width: 80px;
    height: 80px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    flex-shrink: 0;
}

.page-header-info h1 {
    font-size: 2rem;
    margin: 0 0 8px;
    color: white;
    font-weight: 600;
}

.page-header-info p {
    margin: 0;
    color: rgba(255, 255, 255, 0.9);
    font-size: 1rem;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 80px 20px;
    background: var(--bg-white);
    border-radius: 16px;
    border: 1px solid var(--border);
}

.empty-state i {
    font-size: 4rem;
    color: var(--text-light);
    margin-bottom: 20px;
}

.empty-state h3 {
    font-size: 1.5rem;
    color: var(--text-dark);
    margin: 0 0 12px;
}

.empty-state p {
    color: var(--text-gray);
    margin: 0 0 24px;
    font-size: 1rem;
}

/* Footer */
.site-footer {
    background: var(--bg-white);
    border-top: 1px solid var(--border);
    padding: 40px 0 24px;
    margin-top: 60px;
    text-align: center;
}

.site-footer .logo {
    justify-content: center;
    font-size: 20px;
    margin-bottom: 16px;
}

.site-footer p {
    color: var(--text-gray);
    font-size: 0.9rem;
    margin: 8px 0;
}

/* Pagination */
.pagination {
    display: flex;
    gap: 8px;
    justify-content: center;
    align-items: center;
    margin: 40px 0;
}

.pagination a,
.pagination span {
    padding: 8px 14px;
    border-radius: 6px;
    background: var(--bg-white);
    border: 1px solid var(--border);
    color: var(--text-dark);
    font-weight: 500;
    transition: all 0.3s ease;
}

.pagination a:hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.pagination .active {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

/* Utility Classes */
.text-warning {
    color: var(--warning);
}

.text-info {
    color: var(--secondary);
}

.text-primary {
    color: var(--primary);
}

.text-muted {
    color: var(--text-gray);
}

/* Responsive */
@media (max-width: 992px) {
    .app-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    }

    .app-grid.grid-3 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .header-inner {
        flex-wrap: wrap;
        gap: 16px;
    }

    .search-bar {
        order: 3;
        width: 100%;
        max-width: 100%;
    }

    .nav-links {
        gap: 20px;
    }

    .hero h1 {
        font-size: 2rem;
    }

    .hero p {
        font-size: 1rem;
    }

    .page-header {
        padding: 32px 24px;
    }

    .page-header-content {
        flex-direction: column;
        text-align: center;
    }

    .page-header-icon {
        width: 64px;
        height: 64px;
        font-size: 2rem;
    }

    .page-header-info h1 {
        font-size: 1.6rem;
    }

    .app-hero {
        padding: 24px 20px;
    }

    .app-hero-content {
        flex-direction: column;
        text-align: center;
        align-items: center;
    }

    .app-hero-info h1 {
        font-size: 1.4rem;
    }

    .app-hero-meta {
        justify-content: center;
    }

    .info-row {
        /* flex-direction: column; */
        align-items: flex-start;
        gap: 8px;
        padding: 14px 16px;
    }

    .info-value {
        text-align: left;
    }

    .download-item {
        flex-direction: column;
        align-items: stretch;
    }

    .btn-download {
        width: 100%;
        justify-content: center;
    }

    .screenshots-grid {
        grid-template-columns: 1fr;
    }

    .screenshot-img {
        height: 220px;
    }

    .app-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .app-grid.grid-3 {
        grid-template-columns: 1fr;
    }

    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .section-title {
        font-size: 1.3rem;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 16px;
    }

    .logo {
        font-size: 20px;
    }

    .nav-links {
        gap: 16px;
    }

    .nav-links a {
        font-size: 14px;
    }

    .hero {
        padding: 40px 0;
    }

    .hero h1 {
        font-size: 1.6rem;
    }
}

/* App Grid Styles */
.app-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 16px;
    margin-top: 24px;
}

.app-card {
    background: var(--bg-white);
    border-radius: 16px;
    padding: 16px;
    box-shadow: 0 2px 12px var(--shadow);
    transition: all 0.3s ease;
    text-decoration: none;
    color: inherit;
    display: flex;
    align-items: center;
    gap: 16px;
    border: 1px solid var(--border);
}

.app-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px var(--shadow-hover);
    text-decoration: none;
    color: inherit;
}

.app-icon-wrapper {
    flex-shrink: 0;
    width: 72px;
    height: 72px;
    border-radius: 16px;
    overflow: hidden;
    background: var(--bg-light);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.app-icon {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 16px;
}

.app-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.app-title {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text-dark);
    margin: 0;
    line-height: 1.3;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.app-meta-row {
    display: flex;
    align-items: center;
    gap: 12px;
}

.app-category-row {
    display: flex;
    align-items: center;
    gap: 8px;
    justify-content: space-between;
}

.app-category {
    font-size: 0.85rem;
    color: var(--text-gray);
    font-weight: 500;
    margin: 0;
    background: var(--bg-light);
    padding: 4px 10px;
    border-radius: 12px;
    border: 1px solid var(--border);
    box-shadow: 0 1px 3px var(--shadow);
    transition: all 0.3s ease;
    text-decoration: none;
    cursor: pointer;
    flex-shrink: 0;
}

.app-category:hover {
    background: var(--primary);
    color: white;
    transform: translateY(-1px);
    box-shadow: 0 2px 6px rgba(255, 107, 53, 0.3);
}

.app-size {
    font-size: 0.85rem;
    color: var(--text-light);
    margin: 0;
    margin-left: auto;
}

.app-version-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.app-version {
    font-size: 0.85rem;
    color: var(--text-gray);
    font-weight: 600;
    margin: 0;
    flex-shrink: 0;
}

.app-mod-features {
    font-size: 0.8rem;
    color: var(--success);
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 4px;
    margin: 0;
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.app-mod-features::before {
    content: "●";
    color: var(--success);
    font-size: 0.6rem;
    flex-shrink: 0;
}

/* Dark Mode Toggle */
.theme-toggle {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
    background: var(--bg-white);
    border: 2px solid var(--border);
    border-radius: 50px;
    padding: 8px 16px;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px var(--shadow);
}

.theme-toggle:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 16px var(--shadow-hover);
}

.theme-toggle i {
    font-size: 1rem;
    color: var(--text-gray);
    transition: all 0.3s ease;
}

.theme-toggle.dark i.fa-moon {
    color: var(--primary);
}

.theme-toggle.light i.fa-sun {
    color: var(--warning);
}

.theme-toggle.system i.fa-desktop {
    color: var(--secondary);
}

.app-rating {
    display: flex;
    align-items: center;
    gap: 4px;
}

.stars {
    display: flex;
    gap: 1px;
}

.stars i {
    color: var(--star-color);
    font-size: 0.8rem;
}

/* Section Headers */
.section-header {
    display: flex;
    justify-content: between;
    align-items: center;
    margin: 40px 0 20px 0;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--border);
}

.section-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-dark);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.view-all {
    color: var(--primary);
    font-weight: 600;
    font-size: 0.9rem;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 4px;
    transition: all 0.3s ease;
}

.view-all:hover {
    color: var(--primary-dark);
    text-decoration: none;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    color: white;
    padding: 60px 0;
    text-align: center;
    margin-bottom: 40px;
}

.hero h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 16px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.hero p {
    font-size: 1.1rem;
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto;
}

/* Responsive Design */
@media (max-width: 768px) {
    .app-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .app-card {
        padding: 14px;
        gap: 14px;
    }

    .app-icon-wrapper {
        width: 64px;
        height: 64px;
    }

    .app-title {
        font-size: 1.1rem;
    }

    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .hero h1 {
        font-size: 2rem;
    }

    .hero {
        padding: 40px 0;
    }

    .theme-toggle {
        top: 15px;
        right: 15px;
        padding: 6px 12px;
    }
}

@media (max-width: 480px) {
    .app-card {
        padding: 12px;
        gap: 12px;
    }

    .app-icon-wrapper {
        width: 56px;
        height: 56px;
    }

    .app-title {
        font-size: 1rem;
    }

    .app-category-row {
        gap: 6px;
    }

    .app-version-row {
        gap: 6px;
    }

    .app-category {
        font-size: 0.8rem;
        padding: 3px 8px;
    }
}

/* Smooth Transitions for Theme Changes */
* {
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

/* Dark Mode Specific Adjustments */
[data-theme="dark"] .hero {
    background: linear-gradient(135deg, #2d2d2d 0%, #1a1a1a 100%);
}

[data-theme="dark"] .mod-badge {
    box-shadow: 0 2px 8px rgba(255, 71, 87, 0.5);
}

[data-theme="dark"] .updated-badge {
    box-shadow: 0 2px 8px rgba(46, 213, 115, 0.5);
}

@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) .hero {
        background: linear-gradient(135deg, #2d2d2d 0%, #1a1a1a 100%);
    }

    :root:not([data-theme="light"]) .mod-badge {
        box-shadow: 0 2px 8px rgba(255, 71, 87, 0.5);
    }

    :root:not([data-theme="light"]) .updated-badge {
        box-shadow: 0 2px 8px rgba(46, 213, 115, 0.5);
    }
}

/* Download Timer Styles */
.progress {
    background-color: #f0f0f0;
    border-radius: 4px;
    overflow: hidden;
    height: 8px;
}

.progress-bar {
    background-color: var(--primary);
    height: 100%;
    transition: width 0.3s ease;
}

#countdown {
    font-weight: bold;
    color: var(--primary);
    font-size: 1.2em;
}

.btn-lg {
    padding: 12px 30px;
    font-size: 1.1rem;
    border-radius: 8px;
}

.download-timer-container {
    max-width: 500px;
    margin: 0 auto;
    text-align: center;
}

.timer-icon {
    font-size: 3rem;
    color: var(--primary);
    margin-bottom: 20px;
}

.download-ready {
    color: var(--success);
}

.download-ready .timer-icon {
    color: var(--success);
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-gray);
}

.empty-state i {
    font-size: 3rem;
    color: var(--text-light);
    margin-bottom: 16px;
    display: block;
}

.empty-state h3 {
    font-size: 1.5rem;
    color: var(--text-dark);
    margin-bottom: 8px;
}

.empty-state p {
    font-size: 1rem;
    margin-bottom: 20px;
}

/* Button Styles */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: 8px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    font-size: 0.9rem;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(255, 107, 53, 0.3);
    color: white;
    text-decoration: none;
}

/* Page Header */
.page-header {
    background: var(--bg-white);
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 32px;
    box-shadow: 0 2px 8px var(--shadow);
}

.page-header-content {
    display: flex;
    align-items: center;
    gap: 16px;
}

.page-header-icon {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
}

.page-header-info h1 {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--text-dark);
    margin: 0 0 4px 0;
}

.page-header-info p {
    color: var(--text-gray);
    margin: 0;
    font-size: 1rem;
}

/* Breadcrumb */
.breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 20px;
    font-size: 0.9rem;
}

.breadcrumb a {
    color: var(--text-gray);
    text-decoration: none;
    transition: color 0.3s ease;
}

.breadcrumb a:hover {
    color: var(--primary);
}

.breadcrumb-separator {
    color: var(--text-light);
}

.breadcrumb-current {
    color: var(--text-dark);
    font-weight: 600;
}

/* Loading Animation */
@keyframes pulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.5;
    }
}

.loading {
    animation: pulse 1.5s ease-in-out infinite;
}

/* Hover Effects */
.app-card:hover .app-icon {
    transform: scale(1.05);
    transition: transform 0.3s ease;
}

.app-card:hover .app-mod {
    background: linear-gradient(135deg, var(--secondary), var(--primary));
}

/* Additional Responsive */
@media (max-width: 640px) {
    .page-header {
        padding: 16px;
    }

    .page-header-content {
        flex-direction: column;
        text-align: center;
        gap: 12px;
    }

    .page-header-icon {
        width: 48px;
        height: 48px;
        font-size: 1.2rem;
    }

    .page-header-info h1 {
        font-size: 1.5rem;
    }
}

/* Post Content Styling - Matches Quill Editor */
.post-content {
    line-height: 1.65;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 0.975rem;
    /* Slightly smaller, crisper font */
    color: #334155;
    /* Refined slate color for better readability */
}

.post-content p {
    margin-bottom: 1.1em;
}

/* Heading spacing - matches Quill editor */
.post-content h1 {
    font-size: 1.8em;
    font-weight: 700;
    margin: 1.5em 0 0.6em 0;
    line-height: 1.2;
    color: var(--text-dark);
}

.post-content h2 {
    font-size: 1.45em;
    font-weight: 700;
    margin: 1.4em 0 0.6em 0;
    line-height: 1.3;
    color: var(--text-dark);
}

.post-content h3 {
    font-size: 1.2em;
    font-weight: 700;
    margin: 1.25em 0 0.6em 0;
    line-height: 1.4;
    color: var(--text-dark);
}

.post-content h4 {
    font-size: 1.1em;
    font-weight: bold;
    margin: 1.1em 0 0.5em 0;
    line-height: 1.4;
    color: var(--text-dark);
}

.post-content h5 {
    font-size: 1em;
    font-weight: bold;
    margin: 1em 0 0.5em 0;
    line-height: 1.5;
    color: var(--text-dark);
}

.post-content h6 {
    font-size: 0.9em;
    font-weight: bold;
    margin: 1em 0 0.5em 0;
    line-height: 1.5;
    color: var(--text-dark);
}

/* Table of Contents Styling */
#tocContent {
    background: #fdfdfd;
    border-left: 3px solid var(--primary);
    padding: 20px 24px;
    border-radius: 4px 12px 12px 4px;
    margin-bottom: 30px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.02);
}

[data-theme="dark"] #tocContent {
    background: #1e293b;
    border-color: var(--primary);
    border-left-width: 3px;
}

#tocTitle {
    color: #94a3b8;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 12px;
    letter-spacing: 0.05em;
    font-family: 'Inter', sans-serif;
}

#tocList {
    list-style: none !important;
    padding: 0 !important;
    margin: 0 !important;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.toc-link {
    color: #475569;
    font-size: 0.9rem;
    text-decoration: none;
    font-weight: 500;
    display: block;
    transition: all 0.2s ease;
    padding: 6px 0;
    font-family: 'Inter', sans-serif;
}

[data-theme="dark"] .toc-link {
    color: #cbd5e1;
}

.toc-link:hover {
    color: var(--primary) !important;
    padding-left: 8px;
}

.post-content p {
    margin-bottom: 1.2em;
}

.post-content ul,
.post-content ol {
    margin-bottom: 1.2em;
    padding-left: 1.5em;
}

/* First heading has no top margin */
.post-content h1:first-child,
.post-content h2:first-child,
.post-content h3:first-child,
.post-content h4:first-child,
.post-content h5:first-child,
.post-content h6:first-child {
    margin-top: 0;
}

/* Paragraph spacing */
.post-content p {
    margin: 0.8em 0;
    line-height: 1.6;
    color: var(--text-dark);
}

.post-content p:first-child {
    margin-top: 0;
}

.post-content p:last-child {
    margin-bottom: 0;
}

/* List spacing */
.post-content ul,
.post-content ol {
    margin: 0.8em 0;
    padding-left: 1.5em;
}

.post-content li {
    margin: 0.3em 0;
    line-height: 1.6;
    color: var(--text-dark);
}

/* Blockquote */
.post-content blockquote {
    border-left: 4px solid var(--border);
    margin: 1em 0;
    padding-left: 1em;
    color: var(--text-gray);
    font-style: italic;
}

/* Code blocks */
.post-content pre {
    background: var(--bg-light);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 1em;
    margin: 1em 0;
    overflow-x: auto;
    font-family: 'Courier New', monospace;
    font-size: 0.9em;
    color: var(--text-dark);
}

/* Inline code */
.post-content code {
    background: var(--bg-light);
    padding: 0.2em 0.4em;
    border-radius: 3px;
    font-family: 'Courier New', monospace;
    font-size: 0.9em;
    color: var(--text-dark);
}

/* Links */
.post-content a {
    color: var(--secondary);
    text-decoration: underline;
}

.post-content a:hover {
    color: var(--primary);
}

/* Strong and emphasis */
.post-content strong {
    font-weight: bold;
    color: var(--text-dark);
}

.post-content em {
    font-style: italic;
    color: var(--text-dark);
}

/* Strikethrough */
.post-content s,
.post-content del {
    text-decoration: line-through;
    color: var(--text-gray);
}

/* Underline */
.post-content u {
    text-decoration: underline;
}