:root {
    --bg: rgb(17, 17, 20);
    --accent: #B0122E; /* col accent is crimson red */
    --accent-2: #B0122E;
    --card-bg: rgba(255, 255, 255, 0.03);
    --muted: #9AA3AF;
    --glass: rgba(255, 255, 255, 0.03);
}

html,
body {
    height: 100%;
}

body {
    background-color: var(--bg);
    color: var(--muted);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    margin: 0;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
    position: relative;
    overflow-x: hidden;
}

/* stronger, visible subtle pattern */
body::before {
    content: "";
    position: fixed;
    inset: 0;
    background-image: radial-gradient(rgba(255, 255, 255, 0.349) 1px, transparent 1px);
    background-size: 20px 20px;
    pointer-events: none;
    z-index: 0;
    opacity: 0.14;
}

.container-max {
    max-width: 1400px;
}

/* header */
.site-header {
    position: sticky;
    top: 0;
    z-index: 40;
    backdrop-filter: blur(8px);
    background: linear-gradient(180deg, rgba(17, 17, 20, 0.66), rgba(17, 17, 20, 0.50));
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.logo-mark {
    width: 38px;
    height: 38px;
    border-radius: 9px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    color: white;
    background: linear-gradient(135deg, var(--accent), var(--accent-2));
    box-shadow: 0 6px 18px rgba(220, 20, 60, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.04);
    transition: transform .18s ease;
}

.logo-mark:hover {
    transform: rotate(-6deg) scale(1.03);
}

.nav-link {
    color: rgba(255, 255, 255, 0.86);
    padding: 7px 12px;
    border-radius: 8px;
    font-weight: 600;
    transition: background .12s ease, color .12s ease, transform .12s ease;
}

.nav-link:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.03);
    transform: translateY(-1px);
}

.nav-link.active {
    color: #fff;
    background: linear-gradient(90deg, rgba(220, 20, 60, 0.14), rgba(220, 20, 60, 0.06));
    box-shadow: 0 6px 18px rgba(220, 20, 60, 0.06);
    border: 1px solid rgba(220, 20, 60, 0.14);
}

.search-input {
    width: 260px;
    max-width: 42vw;
    transition: width .18s ease;
}

@media (max-width: 640px) {
    .search-input {
        display: none;
    }
}

/* card */
.card-fixed {
    width: 100%;
    aspect-ratio: 460 / 250;
    max-width: 100%;
    display: block;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.02), rgba(0, 0, 0, 0.02));
    border: 1px solid rgba(255, 255, 255, 0.04);
    transition: transform .18s ease, box-shadow .18s ease;
}

.card-fixed:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.7);
}

.card-fixed img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    vertical-align: middle;
}

.card-overlay {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 12px 14px;
    background: linear-gradient(180deg,
            rgba(0, 0, 0, 0) 0%,
            rgba(0, 0, 0, 0.5) 30%,
            rgba(0, 0, 0, 0.9) 100%);
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 12px;
    box-sizing: border-box;
    min-height: 70px;
}

.game-title {
    font-weight: 700;
    color: #fff;
    font-size: 16px;
    line-height: 1.05;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.7);
}

.game-sub {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.88);
    margin-top: 6px;
}

/* badges with soft gradient tint */
.badge {
    font-size: 12px;
    padding: 6px 8px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.04);
    color: rgba(255, 255, 255, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.04);
    backdrop-filter: blur(6px);
    white-space: nowrap;
}

.badge.multiplayer {
    background: linear-gradient(90deg, rgba(220, 20, 60, 0.12), rgba(220, 20, 60, 0.04));
    border-color: rgba(220, 20, 60, 0.22);
    color: #ffdfe2;
}

.badge.singleplayer {
    background: linear-gradient(90deg, rgba(76, 14, 150, 0.08), rgba(76, 14, 150, 0.04));
    border-color: rgba(100, 80, 190, 0.12);
    color: #efe8ff;
}

.badge.tool {
    background: linear-gradient(90deg, rgba(14, 165, 233, 0.08), rgba(14, 165, 233, 0.04));
    border-color: rgba(14, 165, 233, 0.12);
    color: #e6f8ff;
}

/* accent gradient button */
.accent {
    background: linear-gradient(90deg, var(--accent), #b91c1c);
    color: #fff;
    text-decoration: none;
    box-shadow: 0 8px 28px rgba(220, 20, 60, 0.12);
}

/* small utility */
.muted {
    color: rgba(255, 255, 255, 0.68);
}

/* footer */
.site-footer {
    position: relative;
    z-index: 10;
    margin-top: 48px;
    color: rgba(255, 255, 255, 0.88);
}

.footer-top {
    background: rgba(10, 10, 14, 0.6);
    border-top: 1px solid rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(6px);
}

.footer-grid a {
    color: rgba(255, 255, 255, 0.9);
}

.social-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.03);
    transition: transform .12s ease, box-shadow .12s ease;
}

.social-icon:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
}

.footer-bottom {
    padding: 18px 0;
    display: flex;
    gap: 10px;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
}

@media (max-width: 768px) {
    .footer-bottom {
        text-align: center;
        justify-content: center;
        gap: 12px;
    }
}

.perspective-preview {
    transform: perspective(1400px) rotateY(-13deg) rotateX(5deg);
    transform-style: preserve-3d;
    transition: transform .3s ease, box-shadow .3s ease;
    border-radius: 18px;
    overflow: hidden;
    position: relative;
}

.perspective-preview:hover {
    transform: perspective(1400px) rotateY(-3deg) rotateX(2deg) scale(1.05);
    box-shadow:
        0 60px 120px rgba(0, 0, 0, 0.85),
        0 0 0 1px rgba(255, 255, 255, 0.08),
        inset 0 0 70px rgba(220, 20, 60, 0.12);
}

.perspective-preview img {
    filter: brightness(1.05) contrast(1.07) saturate(1.1);
    display: block;
    width: 100%;
    height: auto;
}

@media (hover: none) {
    .perspective-preview {
        transform: none;
        box-shadow: 0 16px 40px rgba(0, 0, 0, 0.6);
    }

    .perspective-preview:hover {
        transform: none;
        box-shadow: 0 16px 40px rgba(0, 0, 0, 0.6);
    }

    .preview-glow {
        bottom: -40px;
        width: 420px;
        height: 80px;
        opacity: 0.6;
        filter: blur(20px);
    }
}

/* responsive tweaks */
@media (max-width: 1024px) {
    .preview-mock {
        padding: 10px;
        border-radius: 14px;
    }

    .window-body::after {
        background: linear-gradient(180deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.5));
    }
}

.cheat-card {
    display: block;
    background: var(--card-bg);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
    transition:
        transform 0.25s ease,
        box-shadow 0.25s ease,
        background 0.25s ease;
    position: relative;
}

.cheat-card:hover {
    transform: translateY(-6px) scale(1.03);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.7);
    background: rgba(255, 255, 255, 0.05);
}

.blog-card-horizontal {
    display: flex;
    gap: 16px;
    align-items: stretch;
    background: var(--card-bg);
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.04);
    transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.blog-card-horizontal:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6);
    background: rgba(255, 255, 255, 0.04);
}

.blog-card-horizontal .card-image {
    flex: 0 0 40%;
    max-width: 420px;
    min-width: 160px;
    aspect-ratio: 16/9;
    overflow: hidden;
    background: #000;
}

.blog-card-horizontal .card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease, filter 0.4s ease;
}

.blog-card-horizontal:hover .card-image img {
    transform: scale(1.03);
}

.blog-card-horizontal .card-body {
    padding: 16px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.blog-card-horizontal .card-title {
    margin: 0 0 8px 0;
    font-size: 18px;
    font-weight: 700;
    color: #fff;
}

.blog-card-horizontal .card-meta {
    color: var(--muted);
    font-size: 13px;
    margin-bottom: 8px;
}

/* small category badge used on blog cards */
.post-category {
    display: inline-block;
    font-size: 12px;
    padding: 6px 8px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.03);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.04);
    margin-bottom: 8px;
}

.blog-card-horizontal .card-excerpt {
    color: var(--muted);
    font-size: 14px;
    line-height: 1.45;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    overflow: hidden;
    text-overflow: ellipsis;
}

@media (max-width: 768px) {
    .blog-card-horizontal {
        flex-direction: column;
    }

    .blog-card-horizontal .card-image {
        width: 100%;
        height: 220px;
        flex: none;
    }
}

/* image zoom on hover */
.cheat-card img {
    transition: transform 0.4s ease, filter 0.4s ease;
    will-change: transform, filter;
}

.cheat-card:hover img {
    transform: scale(1.08);
    filter: brightness(1.1) contrast(1.05);
}

/* accent button subtle hover lift */
.cheat-card .accent {
    transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.cheat-card:hover .accent {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(220, 20, 60, 0.3);
}

/* soft overlay highlight */
.cheat-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at center, rgba(255, 255, 255, 0.06) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.cheat-card:hover::after {
    opacity: 1;
}

/* breadcrumbs small link style */
nav[aria-label="Breadcrumb"] .nav-link {
    color: var(--muted);
    text-decoration: none;
}

nav[aria-label="Breadcrumb"] .nav-link:hover {
    color: var(--accent);
    text-decoration: underline;
}

/* badge/tag */
.badge {
    background: rgba(255, 255, 255, 0.03);
    color: #fff;
    padding: 6px 10px;
    border-radius: 999px;
    text-decoration: none;
    display: inline-block;
    font-weight: 700;
    font-size: 13px;
}

/* App view styles */
.app-layout {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 24px;
    align-items: start;
}

/* App header */
.app-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.app-header h1 {
    margin: 0;
    font-size: 28px;
    color: #fff;
    font-weight: 800;
}

/* Status badge */
.status-badge {
    padding: 6px 10px;
    border-radius: 999px;
    font-weight: 700;
    font-size: 13px;
}

.status-badge.working,
.status-badge.stable,
.status-badge.released {
    background: #10B981;
    color: #012a13;
}

.status-badge.beta,
.status-badge.testing {
    background: #F59E0B;
    color: #2a1b00;
}

.status-badge.broken,
.status-badge.risky {
    background: #EF4444;
    color: #fff;
}

.status-badge.deprecated {
    background: #6B7280;
    color: #fff;
}

/* Screenshots grid */
.screenshots-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
    margin-bottom: 18px;
}

.screen-thumb {
    border: 0;
    background: transparent;
    padding: 0;
    cursor: pointer;
    border-radius: 8px;
    overflow: hidden;
}

.screen-thumb img {
    width: 100%;
    height: 160px;
    object-fit: cover;
    display: block;
}

.screen-placeholder {
    border-radius: 8px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.01), rgba(0, 0, 0, 0.02));
    min-height: 160px;
}

/* Description */
.app-description {
    background: rgba(255, 255, 255, 0.02);
    padding: 18px;
    border-radius: 12px;
    color: var(--muted);
    line-height: 1.6;
}

.app-description .prose {
    color: var(--muted);
    font-size: 1rem;
}

.app-description .prose h1,
.app-description .prose h2,
.app-description .prose h3 {
    color: #ffffff;
    margin: 0 0 0.6rem 0;
    line-height: 1.15;
}

.app-description .prose h1 {
    font-size: 1.8rem;
}

.app-description .prose h2 {
    font-size: 1.35rem;
}

.app-description .prose p {
    margin: 0 0 1rem 0;
    color: var(--muted);
}

.app-description .prose a {
    color: var(--accent);
    text-decoration: underline;
}

.app-description .prose ul,
.app-description .prose ol {
    margin: 0 0 1rem 1.2rem;
    color: var(--muted);
}

.app-description .prose pre {
    background: rgba(0, 0, 0, 0.2);
    padding: 12px;
    border-radius: 8px;
    overflow: auto;
    color: #e6eef8;
}

.app-description .prose code {
    background: rgba(255, 255, 255, 0.03);
    padding: 2px 6px;
    border-radius: 6px;
    color: #e6eef8;
}

.blog-layout {
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 28px;
    align-items: start;
}

.blog-main {
    min-width: 0;
}

.blog-sidebar {
    width: 100%;
}

.sidebar-card {
    background: var(--card-bg);
    border-radius: 10px;
    padding: 14px;
    margin-bottom: 14px;
    color: var(--muted);
}

.sidebar-card .small-title {
    color: #fff;
    margin-bottom: 6px;
    font-weight: 700;
}

@media (max-width: 980px) {
    .blog-layout {
        grid-template-columns: 1fr;
    }

    .blog-sidebar {
        order: 2;
    }
}

.recent-posts-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.recent-post-card {
    display: block;
    text-decoration: none;
    color: inherit;
    border-radius: 8px;
    overflow: hidden;
}

.recent-thumb {
    position: relative;
    width: 100%;
    height: 110px;
    overflow: hidden;
    border-radius: 8px;
}

.recent-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.recent-thumb .thumb-overlay {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 8px 10px;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.6) 100%);
}

.recent-title {
    color: #fff;
    font-weight: 700;
    font-size: 0.95rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.recent-date {
    color: var(--muted);
    font-size: 0.82rem;
    margin-top: 4px;
}

.blog-main .w-full.rounded-lg img {
    width: 100%;
    height: auto;
    max-height: 360px;
    object-fit: cover;
    display: block;
}

.comments-section .comments-wrap {
    margin: 0 auto;
}

.comment-card {
    background: var(--card-bg);
    border: 1px solid rgba(255, 255, 255, 0.03);
    padding: 12px 14px;
    border-radius: 10px;
    margin-bottom: 12px;
    color: var(--muted);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.25);
}

.comment-meta {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.95rem;
}

.comment-meta strong {
    color: #fff;
    font-weight: 700;
}

.comment-time {
    color: var(--muted);
    font-size: 0.85rem;
}

.comment-body {
    margin-top: 8px;
    color: var(--muted);
}

.comment-body p {
    margin: 0;
    line-height: 1.5;
}

.comment-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.03);
    display: inline-block;
    flex: 0 0 36px;
}

@media (max-width:640px) {
    .comments-section .comments-wrap {
        padding-left: 12px;
        padding-right: 12px;
    }

    .comment-card {
        padding: 10px;
    }
}

/* Replies indentation */
.comment-replies {
    margin-top: 10px;
    padding-left: 14px;
    border-left: 2px solid rgba(255, 255, 255, 0.02);
}

.reply-button {
    font-size: 0.9rem;
}

/* Profile popover */
.profile-card {
    background: var(--card-bg);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
    color: var(--muted);
}

.comment-replies .comment-card {
    background: transparent;
    border: none;
    box-shadow: none;
    padding-left: 0;
    margin-bottom: 10px;
}

.comment-replies .comment-meta {
    gap: 8px;
}

/* Comment form card */
.comments-section .comment-form {
    background: var(--card-bg);
    border: 1px solid rgba(255, 255, 255, 0.03);
    padding: 14px;
    border-radius: 10px;
    margin-top: 12px;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.35);
}

.comments-section .comment-form input,
.comments-section .comment-form textarea {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.03);
    color: var(--muted);
}

.comments-section .comment-form input:focus,
.comments-section .comment-form textarea:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(176, 18, 46, 0.06);
    border-color: var(--accent);
}

/* Related apps */
.related-apps {
    margin-top: 18px;
}

.related-apps h2 {
    color: #fff;
    font-size: 18px;
    margin-bottom: 8px;
}

/* Related apps grid */
.related-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 12px;
}

.related-card {
    display: block;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 8px;
    overflow: hidden;
    text-decoration: none;
    transition: transform 0.2s ease;
}

.related-card:hover {
    transform: translateY(-2px);
}

.related-card img {
    width: 100%;
    height: 80px;
    object-fit: cover;
    display: block;
}

.related-card h3 {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

@media (max-width: 768px) {
    .related-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    }
}

@media (max-width: 480px) {
    .related-grid {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    }

    .related-card img {
        height: 70px;
    }
}

/* Sidebar */
.sidebar-content {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    padding: 1.5rem;
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.sidebar-header {
    padding-bottom: 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.game-link {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    text-decoration: none;
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.stat-item {
    background: rgba(255, 255, 255, 0.03);
    padding: 1rem;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.stat-icon {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--accent);
    color: white;
    border-radius: 8px;
    font-size: 0.875rem;
}

.stat-data {
    display: flex;
    flex-direction: column;
}

.stat-value {
    color: white;
    font-weight: 600;
    font-size: 1.125rem;
}

.stat-label {
    color: #9CA3AF;
    font-size: 0.75rem;
}

/* Info List */
.info-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.info-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
}

.info-label {
    color: #9CA3AF;
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.info-value {
    color: white;
    font-weight: 500;
}

.status-pill {
    background: rgba(255, 255, 255, 0.05);
    padding: 0.25rem 0.75rem;
    border-radius: 999px;
    font-size: 0.875rem;
}

/* Action Buttons */
.action-buttons {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.btn-download {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(90deg, var(--accent), #b91c1c);
    color: white;
    padding: 0.875rem;
    border-radius: 8px;
    font-weight: 600;
    text-decoration: none;
    transition: transform 0.2s;
}

.btn-download:hover {
    transform: translateY(-1px);
}

.btn-extra {
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.05);
    color: #9CA3AF;
    padding: 0.875rem;
    border-radius: 8px;
    font-weight: 500;
    text-decoration: none;
    transition: background-color 0.2s;
}

.btn-extra:hover {
    background: rgba(255, 255, 255, 0.08);
}

/* Social Share */
.social-grid {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.social-icon {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    color: #9CA3AF;
    transition: all 0.2s;
}

.social-icon:hover {
    transform: translateY(-2px);
    background: rgba(255, 255, 255, 0.08);
    color: white;
}

/* Lightbox */
.lightbox {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.85);
    align-items: center;
    justify-content: center;
    z-index: 12000;
}

.lightbox.active {
    display: flex;
}

.lb-image {
    max-width: 90%;
    max-height: 90%;
    border-radius: 8px;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.8);
}

.lb-close,
.lb-prev,
.lb-next {
    position: absolute;
    background: transparent;
    border: 0;
    color: #fff;
    cursor: pointer;
    font-size: 24px;
}

.lb-close {
    top: 18px;
    right: 18px;
}

.lb-prev,
.lb-next {
    top: 50%;
    transform: translateY(-50%);
}

.lb-prev {
    left: 18px;
}

.lb-next {
    right: 18px;
}

/* Responsive */
@media (max-width: 900px) {
    .app-layout {
        grid-template-columns: 1fr;
    }

    .screenshots-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    .container-max {
        padding-left: 10px;
        padding-right: 10px;
    }
}

/* sidebar social buttons */
.share-btn {
    transition: transform .12s ease, box-shadow .12s ease;
}

.share-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.45);
}

.sidebar-card {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.02), rgba(0, 0, 0, 0.02));
    border: 1px solid rgba(255, 255, 255, 0.04);
    padding: 1rem;
    border-radius: 12px;
}

.accent {
    background: linear-gradient(90deg, var(--accent), #b91c1c);
    color: #fff;
    text-decoration: none;
}

/* status badges */
.status-badge {
    display: inline-block;
    padding: 6px 10px;
    border-radius: 999px;
    font-weight: 700;
    font-size: 13px;
    color: #fff;
    text-transform: capitalize;
}

/* mapped variants */
.status-undetected {
    background: #10B981;
    color: #fff;
}

.status-risky {
    background: #F59E0B;
    color: #ffffff;
}

.status-outdated {
    background: #EF4444;
    color: #fff;
}

.status-updating {
    background: #6B7280;
    color: #fff;
}

.status-unknown {
    background: rgba(255, 255, 255, 0.03);
    color: #fff;
}

.status-badge:focus {
    outline: 2px solid rgba(220, 38, 38, 0.25);
    outline-offset: 2px;
}

.download-hero {
    padding: 3.5rem 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 2rem;
    text-align: center;
}

.download-card {
    width: 100%;
    max-width: 920px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.02), rgba(255, 255, 255, 0.01));
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: 12px;
    padding: 2.25rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
}

/* hero/grid for download page */
.hero-grid {
    display: flex;
    gap: 1.25rem;
    align-items: flex-start;
}

.hero-left {
    flex: 1;
}

.hero-right {
    width: 260px;
}

.total-num-xl {
    font-size: 2.25rem;
    color: #fff;
    font-weight: 800;
    margin-top: 0.6rem;
}

.total-label-sm {
    color: var(--muted);
    font-size: 0.92rem;
    margin-bottom: 0.8rem;
}

.requirements-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.03);
    padding: 12px;
    border-radius: 10px;
}

.req-title {
    font-weight: 700;
    color: #fff;
    margin-bottom: 0.5rem;
}

.req-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-bottom: 8px;
}

.req-item {
    background: rgba(0, 0, 0, 0.2);
    padding: 6px 8px;
    border-radius: 6px;
    color: var(--muted);
    font-weight: 700;
    font-size: 0.9rem;
}

.req-note {
    color: var(--muted);
    font-size: 0.82rem;
}

@media (max-width:980px) {
    .hero-grid {
        flex-direction: column
    }

    .hero-right {
        width: 100%
    }
}

.download-card h1 {
    margin: 0 0 0.5rem 0;
    font-size: 2rem;
    font-weight: 700;
    color: #fff;
}

.download-card p.lead {
    margin: 0 0 1rem 0;
    color: var(--muted);
}

.hero-ctas {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
    margin-top: 0.75rem;
    flex-wrap: wrap;
}

.server-grid {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-top: 1.25rem;
    justify-content: center;
}

.server-btn {
    min-width: 160px;
    padding: 0.65rem 0.9rem;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.03);
    color: var(--muted);
    border: 1px solid rgba(255, 255, 255, 0.03);
    text-decoration: none;
    font-weight: 600;
}

.server-btn.primary {
    background: linear-gradient(90deg, var(--accent), #b91c1c);
    color: #fff;
    border: none;
}

.meta-row {
    display: flex;
    gap: 1rem;
    align-items: center;
    justify-content: center;
    margin-top: 0.75rem;
    color: var(--muted);
    font-size: 0.95rem;
}

@media (max-width:720px) {
    .download-card {
        padding: 1.25rem
    }

    .download-card h1 {
        font-size: 1.5rem
    }

    .server-btn {
        min-width: 140px
    }
}

.download-container {
    max-width: 980px;
    margin: 0 auto;
    padding: 0 1rem 3.5rem;
}

.download-section {
    background: transparent;
    border: 0;
    border-radius: 10px;
    padding: 1.5rem 0 0 0;
}

.section-header {
    text-align: center;
    margin-bottom: 1rem;
}

.section-title {
    font-size: 1.15rem;
    color: #fff;
    margin: 0 0 0.25rem 0;
    font-weight: 700;
}

.section-subtitle {
    margin: 0;
    color: var(--muted);
    font-size: 0.95rem;
}

.info-box {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.03);
    padding: 1rem;
    border-radius: 8px;
    color: var(--muted);
    margin-top: 1.25rem;
}

.dl-count {
    color: var(--accent);
    font-weight: 700;
    margin-left: 0.35rem;
}

/* statistics layout */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-top: 1.25rem;
}

.stat-item {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.02), rgba(255, 255, 255, 0.01));
    border: 1px solid rgba(255, 255, 255, 0.04);
    padding: 0.9rem 0.9rem;
    border-radius: 10px;
    display: flex;
    gap: 0.9rem;
    align-items: center;
}

.stat-icon {
    width: 46px;
    height: 46px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    font-weight: 700;
    color: var(--muted);
}

.stat-data {
    display: flex;
    flex-direction: column;
}

.stat-value {
    color: #fff;
    font-weight: 700;
    font-size: 1rem;
}

.stat-label {
    color: var(--muted);
    font-size: 0.85rem;
}

/* redesigned stats layout */
.stats-wrap {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 1rem;
    align-items: start;
    margin-top: 1.25rem;
}

.stats-header {
    margin-top: 1.25rem;
    margin-bottom: 0.5rem;
}

.stats-title {
    margin: 0 0 0.25rem 0;
    font-size: 1.25rem;
    color: #fff;
    font-weight: 800;
}

.stats-subtitle {
    margin: 0;
    color: var(--muted);
    font-size: 0.95rem;
}

.stats-main {
    background: transparent;
    padding: 0;
}

.total-num {
    font-size: 2.25rem;
    color: #fff;
    font-weight: 800;
}

.total-label {
    color: var(--muted);
    margin-bottom: 0.5rem;
}

.stats-side {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.small-title {
    color: var(--muted);
    font-size: 0.9rem;
    margin-bottom: 0.4rem;
}

.small-badges {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.small-badge {
    background: rgba(255, 255, 255, 0.02);
    color: #fff;
    padding: 6px 8px;
    border-radius: 999px;
    font-weight: 700;
    font-size: 0.85rem;
    display: inline-flex;
    gap: 0.5rem;
    align-items: center;
}

.small-badge-count {
    color: var(--muted);
    font-weight: 600;
    font-size: 0.82rem;
}

.country-chart {
    margin-top: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
}

@media (max-width: 980px) {
    .stats-wrap {
        grid-template-columns: 1fr;
    }
}

.stats-disclaimer {
    color: var(--muted);
    font-size: 0.88rem;
    line-height: 1.3;
}

/* sparkline info details */
details.spark-info {
    margin-top: 0.6rem;
}

details.spark-info summary {
    cursor: pointer;
    list-style: none;
    font-weight: 700;
    color: #fff;
    margin-bottom: 0.4rem;
}

details.spark-info .spark-info-body {
    padding: 0.5rem 0 0 0;
}

.spark-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
    max-height: 200px;
    overflow: auto;
}

.spark-row {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    padding: 4px 8px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.01);
}

.spark-date {
    color: var(--muted);
    font-size: 0.88rem;
}

.spark-val {
    color: #fff;
    font-weight: 700;
}

/* tooltip for sparkline */
.spark-tooltip {
    position: absolute;
    display: none;
    min-width: 88px;
    padding: 8px 10px;
    background: rgba(0, 0, 0, 0.7);
    color: #fff;
    border-radius: 8px;
    font-size: 0.9rem;
    pointer-events: none;
    transform: translateX(-50%);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
    z-index: 30;
}

.spark-tooltip .tt-date {
    color: var(--muted);
    font-size: 0.82rem;
}

.spark-tooltip .tt-val {
    font-weight: 800;
    margin-top: 4px;
}

@media (max-width: 900px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 520px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }

    .stat-item {
        gap: 0.6rem;
    }
}

/* sparkline */
.sparkline {
    display: inline-block;
    vertical-align: middle;
}

.sparkline-line {
    stroke: var(--accent);
    stroke-width: 1.6;
    fill: none;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.sparkline-area {
    fill: rgba(176, 18, 46, 0.06);
}

/* bar chart */
.bar-chart {
    margin-top: 0.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
}

.bar-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.bar-label {
    width: 100px;
    font-size: 0.9rem;
    color: var(--muted);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.bar {
    flex: 1;
    background: rgba(255, 255, 255, 0.02);
    height: 10px;
    border-radius: 6px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.02);
}

.bar-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--accent), #b91c1c);
}

.bar-val {
    width: 48px;
    text-align: right;
    font-size: 0.85rem;
    color: var(--muted);
}

@media (max-width:640px) {
    .bar-label {
        width: 80px
    }

    .bar-val {
        width: 40px;
        font-size: 0.78rem
    }
}