* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

:root {
    --primary-color: #ec0b8c;
    --secondary-color: #4c1d95;
    --background-dark: #161b22;
    --card-bg: #1e2836;
    --text-light: #f9fafb;
    --text-muted: #9ca3af;
}

body {
    background-color: var(--background-dark);
    color: var(--text-light);
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
}

/* Gradient header */
.header {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    padding: 40px 0;
    text-align: center;
    border-bottom: 5px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    position: relative;
    overflow: hidden;
}

/* Animated pattern in header */
.header::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 50% 150%, rgba(255, 255, 255, 0.2) 0%, rgba(255, 255, 255, 0) 70%);
    opacity: 0.4;
}

.logo {
    width: 100px;
    height: 100px;
    background-color: white;
    border-radius: 20px;
    margin: 0 auto 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
    position: relative;
    overflow: hidden;
}

.logo::after {
    content: "";
    position: absolute;
    top: -10px;
    left: -10px;
    right: -10px;
    bottom: -10px;
    background: linear-gradient(135deg, rgba(236, 11, 140, 0.3), rgba(76, 29, 149, 0.3));
    z-index: 1;
    border-radius: 20px;
}

.logo img {
    width: 100px;
    height: 100px;
    position: relative;
    z-index: 2;
}

.site-title {
    font-size: 3.5rem;
    font-weight: bold;
    margin-bottom: 10px;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    letter-spacing: 1px;
}

.tagline {
    font-size: 1.2rem;
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.section-title {
    padding: 30px 0 20px;
    font-size: 1.8rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    position: relative;
}

.section-title::before {
    content: "";
    width: 8px;
    height: 30px;
    background: linear-gradient(to bottom, var(--primary-color), var(--secondary-color));
    display: inline-block;
    margin-right: 15px;
    border-radius: 4px;
}

/* Featured apps section */
.featured-apps-container {
    position: relative;
    overflow: hidden;
    padding: 10px 0 30px;
    margin-bottom: 20px;
}

.featured-apps {
    display: flex;
    gap: 20px;
    transition: transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
    padding: 10px 5px;
}

.app-card {
    min-width: 220px;
    background-color: var(--card-bg);
    border-radius: 20px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-bottom: 20px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.app-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.25);
}

.app-image {
    width: 100%;
    height: 150px;
    background-size: cover;
    background-position: center;
    position: relative;
}

.app-image::before {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 50%;
    background: linear-gradient(to top, rgba(30, 40, 54, 1), rgba(30, 40, 54, 0));
}

.app-title {
    margin: 15px 0 5px;
    text-align: center;
    font-size: 1.2rem;
    font-weight: 600;
    padding: 0 10px;
}

.app-subtitle {
    font-size: 0.9rem;
    color: var(--primary-color);
    margin-bottom: 10px;
    font-weight: 500;
}

.rating {
    display: flex;
    align-items: center;
    color: #ffb400;
    background: rgba(0, 0, 0, 0.2);
    padding: 5px 12px;
    border-radius: 15px;
}

.rating span {
    margin-left: 5px;
    font-weight: 500;
}

/* All apps section */
.all-apps {
    padding: 20px 0 40px;
}

.search-wrapper {
    position: relative;
    margin-bottom: 30px;
}

.search-input {
    background-color: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 30px;
    padding: 15px 20px 15px 50px;
    color: white;
    width: 100%;
    font-size: 1rem;
    transition: all 0.3s ease;
    max-width: 500px;
    margin-left: auto;
}

.search-input:focus {
    background-color: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.2);
    outline: none;
    box-shadow: 0 0 0 3px rgba(236, 11, 140, 0.25);
}

.search-icon {
    position: absolute;
    top: 50%;
    left: 20px;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 1.2rem;
}

.apps-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 25px;
}

.app-card-horizontal {
    background-color: var(--card-bg);
    border-radius: 20px;
    display: flex;
    align-items: center;
    padding: 20px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.15);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.app-card-horizontal:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.25);
}

.app-card-horizontal::before {
    content: "";
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    height: 5px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    border-radius: 20px 20px 0 0;
}

.app-icon {
    width: 80px;
    height: 80px;
    border-radius: 18px;
    background-size: cover;
    background-position: center;
    margin-right: 20px;
    flex-shrink: 0;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
}

.app-info {
    flex-grow: 1;
    padding-right: 80px;
}

.app-desc {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin: 8px 0;
    line-height: 1.4;
}

.rating-horizontal {
    position: absolute;
    top: 20px;
    right: 20px;
    display: flex;
    align-items: center;
    color: #ffb400;
    background: rgba(0, 0, 0, 0.2);
    padding: 5px 12px;
    border-radius: 15px;
}

.platform-icons {
    position: absolute;
    bottom: 20px;
    right: 20px;
    display: flex;
}

.platform-icons span {
    margin-left: 5px;
    font-size: 1.2rem;
    color: var(--text-muted);
    background: rgba(255, 255, 255, 0.05);
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

/* Footer */
.footer {
    background-color: rgba(0, 0, 0, 0.3);
    padding: 25px 20px;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.85rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    margin-top: 40px;
}

/* Responsive design */
@media (max-width: 1024px) {
    .apps-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .apps-grid {
        grid-template-columns: 1fr;
    }

    .app-info {
        padding-right: 0;
    }

    .rating-horizontal {
        top: 15px;
        right: 15px;
    }

    .platform-icons {
        position: relative;
        bottom: auto;
        right: auto;
        margin-top: 10px;
        justify-content: flex-start;
    }

    .site-title {
        font-size: 2.5rem;
    }
}

/* Animation for featured apps */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.app-card {
    animation: fadeIn 0.5s ease-out forwards;
}

.app-card:nth-child(1) {
    animation-delay: 0.1s;
}

.app-card:nth-child(2) {
    animation-delay: 0.2s;
}

.app-card:nth-child(3) {
    animation-delay: 0.3s;
}

.app-card:nth-child(4) {
    animation-delay: 0.4s;
}

.app-card:nth-child(5) {
    animation-delay: 0.5s;
}

.app-card:nth-child(6) {
    animation-delay: 0.6s;
}

.app-card:nth-child(7) {
    animation-delay: 0.7s;
}

.app-card:nth-child(8) {
    animation-delay: 0.8s;
}







/* Modal styles */
.game-modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(5px);
}

.modal-content {
    background-color: var(--card-bg);
    margin: 15% auto;
    max-width: 500px;
    border-radius: 20px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.4);
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.1);
    animation: modalFadeIn 0.3s ease;
    overflow: hidden;
}

@keyframes modalFadeIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.close-modal {
    position: absolute;
    top: 15px;
    right: 15px;
    color: var(--text-muted);
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s ease;
    z-index: 10;
}

.close-modal:hover {
    background-color: rgba(255, 255, 255, 0.2);
    color: white;
}

.modal-game-details {
    display: flex;
    padding: 25px;
    align-items: center;
}

.modal-game-image {
    width: 100px;
    height: 100px;
    border-radius: 20px;
    object-fit: cover;
    margin-right: 20px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.modal-game-info {
    flex: 1;
}

.modal-game-info h2 {
    margin: 0 0 10px;
    font-size: 22px;
    color: var(--text-light);
}

.modal-game-info p {
    margin: 0 0 15px;
    color: var(--text-muted);
    font-size: 14px;
    line-height: 1.4;
}

.modal-rating-platform {
    display: flex;
    align-items: center;
    justify-content: flex-start;
}

.modal-platforms {
    display: flex;
    margin-right: 15px;
}

.modal-platforms span {
    background-color: rgba(0, 0, 0, 0.3);
    border-radius: 50%;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 5px;
}

.modal-rating {
    display: flex;
    align-items: center;
    background-color: rgba(0, 0, 0, 0.3);
    padding: 5px 12px;
    border-radius: 15px;
    color: #ffb400;
    margin-right: 15px;
}

.modal-rating .star {
    margin-right: 5px;
}

.modal-filesize {
    background-color: rgba(0, 0, 0, 0.3);
    padding: 5px 12px;
    border-radius: 15px;
    color: var(--text-muted);
}

.modal-instructions {
    padding: 0 25px 20px;
    text-align: center;
}

.modal-instructions h3 {
    color: var(--primary-color);
    margin-bottom: 10px;
    font-size: 20px;
}

.modal-instructions p {
    color: var(--text-muted);
    font-size: 14px;
    line-height: 1.4;
}

.install-buon {
    display: block;
    width: calc(100% - 50px);
    margin: 0 auto 25px;
    padding: 16px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border: none;
    border-radius: 30px;
    font-weight: bold;
    font-size: 16px;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 8px 20px rgba(236, 11, 140, 0.3);
    letter-spacing: 1px;
}

.install-buon:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 25px rgba(236, 11, 140, 0.5);
}

/* Mobile responsiveness */
@media (max-width: 600px) {
    .modal-content {
        width: 90%;
        margin: 20% auto;
    }

    .modal-game-details {
        flex-direction: column;
        text-align: center;
    }

    .modal-game-image {
        margin-right: 0;
        margin-bottom: 20px;
    }

    .modal-rating-platform {
        justify-content: center;
    }
}

/* Fix app title link style */
.app-title a {
    color: var(--text-light);
    text-decoration: none;
    transition: color 0.3s ease;
}

.app-title a:hover {
    color: var(--primary-color);
}

.app-card a, .app-card-horizontal a {
  text-decoration: none !important;
  color: inherit;
}


/* --- FIX: App card uniform style (Roblox like Watch Dogs) --- */

.app-card {
    color: var(--text-light);
    text-decoration: none;
}

.app-card .app-title {
    color: var(--text-light);
    font-size: 1.2rem;
    font-weight: 600;
    text-align: center;
    margin: 15px 0 5px;
    transition: color 0.3s ease;
}

.app-card .app-title:hover {
    color: var(--primary-color);
}

.app-card .app-subtitle {
    font-size: 0.9rem;
    color: var(--primary-color);
    margin-bottom: 10px;
    font-weight: 500;
    text-align: center;
}

.app-card a,
.app-card a:visited,
.app-card .app-title a {
    color: inherit;
    text-decoration: none !important;
}

.app-card .rating {
    margin-top: auto;
}

/* Optional: On hover make whole card change slightly */
.app-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.25);
}


/* --- FIX: Horizontal cards styling (ALL APPS) --- */

.app-card-horizontal {
  color: var(--text-light);
  text-decoration: none;
  position: relative;
}

.app-card-horizontal .app-title {
  color: var(--text-light);
  font-size: 1.2rem;
  font-weight: 600;
  text-decoration: none;
  margin-bottom: 4px;
}

.app-card-horizontal .app-title a {
  color: inherit;
  text-decoration: none !important;
}

.app-card-horizontal .app-title a:hover {
  color: var(--primary-color);
}

.app-card-horizontal .app-desc {
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.4;
}

/* Optional: on hover, change title color */
.app-card-horizontal:hover .app-title {
  color: var(--primary-color);
}
