/* ================= FONTS ================= */

@font-face {
    font-family: "FixedsysExcelsior";
    src: url("./fonts/fixedsys_excelsior.ttf") format("truetype");
    font-weight: normal;
    font-style: normal;
}

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@400;500;600;700;800;900&display=swap');

/* ================= CSS VARIABLES ================= */

:root {
    --bg-primary: #080b12;
    --bg-elevated: #0f1219;
    --bg-card: #141822;
    --bg-card-face: #181d2a;
    --border-subtle: rgba(255, 255, 255, 0.04);
    --border-card: rgba(255, 255, 255, 0.06);
    --border-hover: rgba(0, 230, 118, 0.2);

    /* Green accent palette */
    --green: #00e676;
    --green-dark: #00c853;
    --green-darker: #009d3e;
    --green-shadow: #007a30;
    --green-glow: rgba(0, 230, 118, 0.35);
    --green-subtle: rgba(0, 230, 118, 0.08);

    --cyan: #00e5ff;
    --purple: #7c4dff;

    --text-primary: #eaecf2;
    --text-secondary: #6e7590;
    --text-muted: #3e4358;

    --radius-sm: 12px;
    --radius-md: 16px;
    --radius-lg: 22px;

    --transition-fast: 0.15s ease;
    --transition-smooth: 0.4s cubic-bezier(0.22, 1, 0.36, 1);
    --transition-bounce: 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* ================= BASE RESET ================= */

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    -webkit-tap-highlight-color: transparent;
}

html, body {
    height: 100%;
    margin: 0;
    background: var(--bg-primary);
    overflow: hidden;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

body { color: var(--text-primary); }

/* ================= SCROLLBAR ================= */

::-webkit-scrollbar { width: 3px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(0, 230, 118, 0.2); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: rgba(0, 230, 118, 0.4); }

/* ================= APP LAYOUT ================= */

.app-root {
    height: 100%;
    display: flex;
    flex-direction: column;
    background: var(--bg-primary);
    position: relative;
    overflow: hidden;
}

/* Ambient glow spots */
.app-root::before,
.app-root::after {
    content: "";
    position: fixed;
    border-radius: 50%;
    pointer-events: none;
    z-index: 0;
    filter: blur(80px);
}

.app-root::before {
    top: -15%;
    left: -10%;
    width: 500px;
    height: 500px;
    background: rgba(0, 230, 118, 0.03);
}

.app-root::after {
    bottom: -20%;
    right: -10%;
    width: 400px;
    height: 400px;
    background: rgba(0, 229, 255, 0.025);
}

/* ================= TOP BAR / SEARCH ================= */

.top-bar {
    padding: 14px 14px 6px;
    flex-shrink: 0;
    position: relative;
    z-index: 10;
}

.search-wrapper {
    position: relative;
}

.search-wrapper::before {
    content: "";
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%234a5068' stroke-width='2'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M21 21l-6-6m2-5a7 7 0 11-14 0 7 7 0 0114 0z'/%3E%3C/svg%3E");
    background-size: contain;
    pointer-events: none;
    z-index: 1;
    transition: opacity 0.2s;
}

.top-bar input {
    width: 100%;
    padding: 14px 16px 14px 44px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-subtle);
    font-size: 15px;
    font-weight: 400;
    font-family: 'Inter', sans-serif;
    background: var(--bg-elevated);
    color: var(--text-primary);
    outline: none;
    transition: all var(--transition-smooth);
    /* 3D inset */
    box-shadow:
        inset 0 2px 6px rgba(0,0,0,0.4),
        0 1px 0 rgba(255,255,255,0.02);
}

.top-bar input::placeholder { color: var(--text-muted); }

.top-bar input:focus {
    border-color: var(--green);
    box-shadow:
        inset 0 2px 6px rgba(0,0,0,0.3),
        0 0 0 3px rgba(0, 230, 118, 0.08),
        0 0 20px rgba(0, 230, 118, 0.06);
}

/* ================= STATS BAR ================= */

.stats-bar {
    display: flex;
    align-items: center;
    padding: 4px 18px 8px;
    flex-shrink: 0;
    z-index: 10;
}

.stats-count {
    font-size: 11px;
    font-weight: 600;
    color: var(--text-muted);
    letter-spacing: 1.5px;
    text-transform: uppercase;
}

.stats-count span {
    color: var(--green);
    text-shadow: 0 0 10px rgba(0, 230, 118, 0.3);
}

/* ================= CONTENT AREA ================= */

.content {
    flex: 1;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    position: relative;
    z-index: 1;
}

/* ================= GRID ================= */

.grid {
    padding: 0 10px 20px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

@media (min-width: 600px) {
    .grid { grid-template-columns: repeat(4, 1fr); gap: 12px; padding: 0 14px 20px; }
}
@media (min-width: 1024px) {
    .grid { grid-template-columns: repeat(5, 1fr); gap: 14px; padding: 0 20px 20px; max-width: 1400px; margin: 0 auto; }
}
@media (min-width: 1400px) {
    .grid { grid-template-columns: repeat(6, 1fr); max-width: 1700px; }
}

/* =========================================================
   🃏  3D GAME CARD — Full Depth Effect
   ========================================================= */

.card {
    background: var(--bg-card);
    border-radius: var(--radius-md);
    padding: 0;
    border: 1px solid var(--border-card);
    position: relative;
    cursor: pointer;
    transform-style: preserve-3d;
    will-change: transform, box-shadow;
    overflow: hidden;

    /* 3D raised platform */
    box-shadow:
        0 1px 0 rgba(255,255,255,0.04) inset,
        0 -1px 0 rgba(0,0,0,0.8) inset,
        0 4px 0 #0c0f16,
        0 5px 0 #090b11,
        0 6px 0 #070910,
        0 10px 20px rgba(0,0,0,0.4),
        0 20px 40px rgba(0,0,0,0.2);

    transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1),
                box-shadow 0.45s cubic-bezier(0.22, 1, 0.36, 1),
                border-color 0.3s ease;

    /* Scroll animation start state */
    opacity: 0;
    transform: translateY(60px) rotateX(12deg) scale(0.9);
}

.card-inner {
    padding: 8px 8px 10px;
    position: relative;
    z-index: 1;
}

/* Card reveal animation */
.card.in-view {
    opacity: 1;
    transform: translateY(0) rotateX(0deg) scale(1);
}

/* Hover lift */
.card:hover {
    border-color: var(--border-hover);
    box-shadow:
        0 1px 0 rgba(255,255,255,0.06) inset,
        0 -1px 0 rgba(0,0,0,0.6) inset,
        0 6px 0 #0c0f16,
        0 7px 0 #090b11,
        0 8px 0 #070910,
        0 16px 32px rgba(0,0,0,0.5),
        0 30px 60px rgba(0,0,0,0.25),
        0 0 40px rgba(0, 230, 118, 0.04);
    z-index: 5;
}

.card:active {
    box-shadow:
        0 1px 0 rgba(255,255,255,0.03) inset,
        0 -1px 0 rgba(0,0,0,0.8) inset,
        0 1px 0 #0c0f16,
        0 2px 4px rgba(0,0,0,0.5);
    transform: translateY(4px) scale(0.98) !important;
    transition: transform 0.08s ease, box-shadow 0.08s ease;
}

/* Top edge highlight */
.card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg,
        transparent 5%,
        rgba(255,255,255,0.06) 30%,
        rgba(255,255,255,0.1) 50%,
        rgba(255,255,255,0.06) 70%,
        transparent 95%
    );
    z-index: 2;
}

/* Green glow line on hover */
.card::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 20%;
    right: 20%;
    height: 2px;
    background: var(--green);
    border-radius: 2px 2px 0 0;
    opacity: 0;
    filter: blur(0px);
    transition: all 0.4s ease;
    z-index: 2;
    box-shadow: 0 0 12px var(--green-glow);
}

.card:hover::after {
    opacity: 1;
    left: 10%;
    right: 10%;
}

/* ================= CARD IMAGE ================= */

.card-image {
    border-radius: 10px;
    overflow: hidden;
    position: relative;
    background: #0a0d14;
    /* Inset 3D screen effect */
    box-shadow:
        inset 0 2px 8px rgba(0,0,0,0.7),
        inset 0 -1px 0 rgba(255,255,255,0.03);
    border: 1px solid rgba(0,0,0,0.4);
}

.card-image img {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: contain;
    display: block;
    transition: transform 0.6s cubic-bezier(0.22, 1, 0.36, 1),
                filter 0.4s ease;
}

.card:hover .card-image img {
    transform: scale(1.08);
}

/* Shine sweep on hover */
.card-image::after {
    content: "";
    position: absolute;
    top: 0;
    left: -120%;
    width: 60%;
    height: 100%;
    background: linear-gradient(
        100deg,
        transparent 20%,
        rgba(255,255,255,0.06) 45%,
        rgba(255,255,255,0.12) 50%,
        rgba(255,255,255,0.06) 55%,
        transparent 80%
    );
    transition: left 0.7s cubic-bezier(0.22, 1, 0.36, 1);
    z-index: 2;
    pointer-events: none;
}

.card:hover .card-image::after {
    left: 160%;
}

/* Platform badge */
.card-platform {
    position: absolute;
    top: 7px;
    left: 7px;
    padding: 3px 8px;
    border-radius: 6px;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    color: var(--green);
    border: 1px solid rgba(0, 230, 118, 0.15);
    z-index: 3;
    text-shadow: 0 0 6px rgba(0,230,118,0.3);
}

/* ================= CARD TITLE ================= */

.card-title {
    font-family: 'Outfit', sans-serif;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.1px;
    color: var(--text-primary);
    padding: 6px 2px 2px;
    line-height: 1.3;
    height: calc(1.3em * 2 + 8px);
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    text-overflow: ellipsis;
}

/* =========================================================
   🟢  DOWNLOAD BUTTON — 3D Push Button
   ========================================================= */

.card-download {
    margin-top: 4px;
    padding: 8px 8px;
    border-radius: 8px;
    color: #fff;
    font-family: 'Outfit', sans-serif;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    cursor: pointer;
    border: none;
    position: relative;
    overflow: hidden;

    /* 3D green button */
    background: var(--green-dark);
    box-shadow:
        0 1px 0 rgba(255,255,255,0.15) inset,
        0 -2px 0 rgba(0,0,0,0.2) inset,
        0 4px 0 var(--green-shadow),
        0 5px 0 #006828,
        0 7px 14px rgba(0, 230, 118, 0.15),
        0 2px 4px rgba(0,0,0,0.3);
    transform: translateY(0);
    transition: all 0.12s ease;
    text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

.card-download:hover {
    background: var(--green);
    color: #000;
    text-shadow: none;
    font-weight: 800;
    box-shadow:
        0 1px 0 rgba(255,255,255,0.25) inset,
        0 -2px 0 rgba(0,0,0,0.15) inset,
        0 4px 0 var(--green-dark),
        0 5px 0 var(--green-shadow),
        0 7px 14px rgba(0, 230, 118, 0.25),
        0 0 20px rgba(0, 230, 118, 0.15);
    transform: translateY(-1px);
}

.card-download:active {
    transform: translateY(4px);
    box-shadow:
        0 1px 0 rgba(255,255,255,0.1) inset,
        0 -1px 0 rgba(0,0,0,0.2) inset,
        0 0px 0 var(--green-shadow),
        0 1px 2px rgba(0,0,0,0.4);
    transition: all 0.05s ease;
}

/* Shine sweep */
.card-download::before {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 60%;
    height: 100%;
    background: linear-gradient(100deg, transparent 30%, rgba(255,255,255,0.2) 50%, transparent 70%);
    transition: left 0.5s ease;
    z-index: 1;
}

.card:hover .card-download::before {
    left: 160%;
}

.card-download svg {
    width: 14px;
    height: 14px;
    fill: none;
    stroke: currentColor;
    position: relative;
    z-index: 2;
}

/* ================= NOT FOUND ================= */

#notFound {
    display: none;
    height: 100%;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
    font-family: 'Outfit', sans-serif;
    font-size: 20px;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: var(--text-muted);
    padding: 40px;
}

#notFound::before {
    content: "🎮";
    font-size: 56px;
    display: block;
    animation: float3d 3s ease-in-out infinite;
    filter: drop-shadow(0 8px 12px rgba(0,0,0,0.5));
}

@keyframes float3d {
    0%, 100% { transform: translateY(0) rotateY(0deg) rotateX(0deg); }
    25% { transform: translateY(-10px) rotateY(10deg) rotateX(5deg); }
    50% { transform: translateY(-16px) rotateY(0deg) rotateX(-3deg); }
    75% { transform: translateY(-10px) rotateY(-10deg) rotateX(5deg); }
}

/* ================= BOTTOM BAR / PAGINATION ================= */

.bottom-bar {
    padding: 8px 12px 12px;
    flex-shrink: 0;
    position: relative;
    z-index: 10;
}

#pagination {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    white-space: nowrap;
    justify-content: center;
    align-items: center;
    gap: 5px;
    padding: 4px;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
}

#pagination::-webkit-scrollbar { display: none; }

#pagination button {
    flex-shrink: 0;
    min-width: 38px;
    height: 38px;
    padding: 0 8px;
    border-radius: 10px;
    border: 1px solid var(--border-subtle);
    background: var(--bg-elevated);
    color: var(--text-secondary);
    font-family: 'Inter', sans-serif;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.12s ease;
    display: flex;
    align-items: center;
    justify-content: center;

    /* 3D button */
    box-shadow:
        0 1px 0 rgba(255,255,255,0.03) inset,
        0 2px 0 #080a10,
        0 3px 0 #060810,
        0 4px 8px rgba(0,0,0,0.25);
}

#pagination button:hover:not(:disabled) {
    background: #1a1f2e;
    border-color: var(--border-hover);
    color: var(--text-primary);
    transform: translateY(-1px);
    box-shadow:
        0 1px 0 rgba(255,255,255,0.04) inset,
        0 3px 0 #080a10,
        0 4px 0 #060810,
        0 6px 12px rgba(0,0,0,0.3);
}

#pagination button:active:not(:disabled) {
    transform: translateY(2px);
    box-shadow: 0 0px 0 #080a10, 0 1px 2px rgba(0,0,0,0.3);
}

#pagination button.active {
    background: var(--green-dark);
    border-color: transparent;
    color: #ffffff;
    font-weight: 700;
    text-shadow: 0 1px 2px rgba(0,0,0,0.3);
    box-shadow:
        0 1px 0 rgba(255,255,255,0.12) inset,
        0 3px 0 var(--green-shadow),
        0 4px 0 #006828,
        0 6px 14px rgba(0, 230, 118, 0.2);
}

#pagination button.active:hover {
    background: var(--green);
    color: #000;
}

#pagination button:disabled {
    opacity: 0.2;
    cursor: not-allowed;
    box-shadow: none;
}

#pagination .dots {
    color: var(--text-muted);
    font-size: 14px;
    padding: 0 2px;
    letter-spacing: 2px;
}

/* ================= DETAIL OVERLAY ================= */

.overlay {
    position: fixed;
    inset: 0;
    background: rgba(4, 6, 10, 0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 999;
    padding: 20px;
    animation: overlayIn 0.25s ease-out;
}

@keyframes overlayIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.detail-dialog {
    width: 100%;
    max-width: 400px;
    background: var(--bg-elevated);
    border-radius: var(--radius-lg);
    padding: 22px;
    border: 1px solid var(--border-card);
    color: var(--text-primary);
    text-align: center;
    position: relative;
    overflow: hidden;
    animation: dialogPop3d 0.45s cubic-bezier(0.34, 1.56, 0.64, 1);

    /* Heavy 3D elevation */
    box-shadow:
        0 1px 0 rgba(255,255,255,0.04) inset,
        0 -1px 0 rgba(0,0,0,0.6) inset,
        0 6px 0 #0a0c12,
        0 7px 0 #080a10,
        0 8px 0 #06080e,
        0 20px 60px rgba(0,0,0,0.6),
        0 0 60px rgba(0, 230, 118, 0.04);
}

@keyframes dialogPop3d {
    0% {
        opacity: 0;
        transform: perspective(800px) scale(0.7) translateY(60px) rotateX(20deg);
    }
    60% {
        transform: perspective(800px) scale(1.03) translateY(-8px) rotateX(-3deg);
    }
    100% {
        opacity: 1;
        transform: perspective(800px) scale(1) translateY(0) rotateX(0deg);
    }
}

/* Top shine */
.detail-dialog::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent 5%, rgba(0, 230, 118, 0.2) 50%, transparent 95%);
    z-index: 2;
}

/* Close button */
.detail-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #1e2130;
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #c0c4d4;
    font-size: 17px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s ease;
    z-index: 10;
    box-shadow: 0 2px 0 #0a0c12, 0 3px 8px rgba(0,0,0,0.4);
}

.detail-close:hover {
    background: #3a1a1a;
    border-color: rgba(255, 80, 80, 0.4);
    color: #ff5050;
    transform: translateY(-1px) scale(1.08);
    box-shadow: 0 3px 0 #0a0c12, 0 5px 12px rgba(0,0,0,0.35), 0 0 12px rgba(255,80,80,0.1);
}

.detail-close:active {
    transform: translateY(2px) scale(0.95);
    box-shadow: 0 0px 0 #0a0c12;
}

#detailImage {
    width: 100%;
    max-height: 240px;
    object-fit: contain;
    border-radius: var(--radius-sm);
    background: #060810;
    margin-top: 8px;
    border: 1px solid rgba(255,255,255,0.03);
    box-shadow: inset 0 2px 8px rgba(0,0,0,0.6), 0 4px 12px rgba(0,0,0,0.3);
}

#detailTitle {
    margin-top: 16px;
    font-family: 'Outfit', sans-serif;
    font-size: 20px;
    font-weight: 800;
    color: var(--text-primary);
    letter-spacing: -0.2px;
}

#detailExtra {
    margin-top: 10px;
    font-size: 13px;
    color: var(--text-secondary);
    display: flex;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
}

.detail-tag {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 5px 12px;
    border-radius: 8px;
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    font-size: 11px;
    font-weight: 600;
    color: var(--text-secondary);
    box-shadow: 0 2px 0 #0a0c12, 0 3px 6px rgba(0,0,0,0.2);
}

/* Download button in detail - 3D Green */
#detailDownload {
    display: block;
    margin-top: 20px;
    padding: 15px;
    border-radius: var(--radius-sm);
    color: #ffffff;
    font-family: 'Outfit', sans-serif;
    font-size: 15px;
    font-weight: 800;
    letter-spacing: 1px;
    text-transform: uppercase;
    text-decoration: none;
    cursor: pointer;
    border: none;
    transition: all 0.12s ease;

    background: var(--green-dark);
    box-shadow:
        0 1px 0 rgba(255,255,255,0.15) inset,
        0 -2px 0 rgba(0,0,0,0.15) inset,
        0 5px 0 var(--green-shadow),
        0 6px 0 #006828,
        0 8px 16px rgba(0, 230, 118, 0.2),
        0 0 30px rgba(0, 230, 118, 0.08);
    transform: translateY(0);
    text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

#detailDownload:hover {
    background: var(--green);
    color: #000;
    text-shadow: none;
    transform: translateY(-2px);
    box-shadow:
        0 1px 0 rgba(255,255,255,0.25) inset,
        0 -2px 0 rgba(0,0,0,0.1) inset,
        0 6px 0 var(--green-dark),
        0 7px 0 var(--green-shadow),
        0 10px 20px rgba(0, 230, 118, 0.3),
        0 0 40px rgba(0, 230, 118, 0.12);
}

#detailDownload:active {
    transform: translateY(5px);
    box-shadow:
        0 1px 0 rgba(255,255,255,0.1) inset,
        0 0px 0 var(--green-shadow),
        0 1px 3px rgba(0,0,0,0.4);
    transition: all 0.05s ease;
}

/* ================= DOWNLOADING OVERLAY ================= */

.download-dialog {
    padding: 32px 40px 28px;
    border-radius: var(--radius-lg);
    background: var(--bg-elevated);
    border: 1px solid rgba(0, 230, 118, 0.12);
    text-align: center;
    min-width: 280px;
    max-width: 340px;
    position: relative;
    animation: dialogPop3d 0.45s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow:
        0 1px 0 rgba(255,255,255,0.04) inset,
        0 6px 0 #0a0c12,
        0 7px 0 #080a10,
        0 20px 60px rgba(0,0,0,0.6),
        0 0 50px rgba(0, 230, 118, 0.05);
}

.download-dialog::before {
    content: "";
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent 5%, var(--green) 50%, transparent 95%);
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}

#textStateDownload {
    font-family: 'Outfit', sans-serif;
    font-size: 18px;
    font-weight: 700;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    color: var(--green);
    text-shadow: 0 0 14px rgba(0, 230, 118, 0.3);
}

/* ================= LOADER / STATUS ICONS ================= */

.loader {
    width: 42px;
    height: 42px;
    border: 3px solid rgba(0, 230, 118, 0.1);
    border-top-color: var(--green);
    border-radius: 50%;
    animation: spin 0.65s linear infinite;
    margin: 0 auto;
    box-shadow: 0 0 16px rgba(0, 230, 118, 0.1);
}

@keyframes spin { to { transform: rotate(360deg); } }

.done-check {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--green);
    position: relative;
    margin: 0 auto;
    animation: pop3d 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow:
        0 4px 0 var(--green-shadow),
        0 5px 0 #006828,
        0 8px 24px rgba(0, 230, 118, 0.3),
        0 0 40px rgba(0, 230, 118, 0.15);
}

.done-check::after {
    content: "";
    position: absolute;
    width: 11px;
    height: 20px;
    border-right: 3.5px solid #000;
    border-bottom: 3.5px solid #000;
    transform: rotate(45deg);
    left: 16px;
    top: 10px;
}

@keyframes pop3d {
    0% { transform: scale(0.15) rotateY(90deg) rotateX(45deg); opacity: 0; }
    50% { transform: scale(1.2) rotateY(-15deg) rotateX(-5deg); }
    70% { transform: scale(0.95) rotateY(5deg); }
    100% { transform: scale(1) rotateY(0deg) rotateX(0deg); opacity: 1; }
}

.error-cross {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: #ff3b3b;
    position: relative;
    margin: 0 auto;
    animation: pop3d 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow:
        0 4px 0 #cc2020,
        0 5px 0 #aa1818,
        0 8px 24px rgba(255, 59, 59, 0.3);
}

.error-cross::before,
.error-cross::after {
    content: "";
    position: absolute;
    width: 22px;
    height: 3.5px;
    background: #fff;
    top: 50%;
    left: 50%;
    border-radius: 2px;
}
.error-cross::before { transform: translate(-50%, -50%) rotate(45deg); }
.error-cross::after { transform: translate(-50%, -50%) rotate(-45deg); }

/* ================= LOADING SKELETON ================= */

.skeleton-card {
    background: var(--bg-card);
    border-radius: var(--radius-md);
    padding: 10px;
    border: 1px solid var(--border-subtle);
    box-shadow: 0 4px 0 #0c0f16, 0 5px 0 #090b11, 0 8px 16px rgba(0,0,0,0.3);
}

.skeleton-img {
    width: 100%;
    aspect-ratio: 1 / 1;
    border-radius: 10px;
    background: linear-gradient(110deg, #141822 8%, #1c2130 18%, #141822 33%);
    background-size: 200% 100%;
    animation: shimmer 1.4s linear infinite;
}

.skeleton-text {
    height: 14px;
    border-radius: 6px;
    margin-top: 10px;
    background: linear-gradient(110deg, #141822 8%, #1c2130 18%, #141822 33%);
    background-size: 200% 100%;
    animation: shimmer 1.4s linear infinite;
}

.skeleton-btn {
    height: 38px;
    border-radius: 10px;
    margin-top: 8px;
    background: linear-gradient(110deg, #141822 8%, #1c2130 18%, #141822 33%);
    background-size: 200% 100%;
    animation: shimmer 1.4s linear infinite;
}

@keyframes shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}
