@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;600;700&display=swap');

:root {
    --bg-color: #0f0f12;
    --sidebar-bg: #16161a;
    --card-bg: #1c1c21;
    --accent-color: #ff0055;
    --accent-glow: rgba(255, 0, 85, 0.3);
    --text-primary: #ffffff;
    --text-secondary: #a0a0a8;
    --border-color: rgba(255, 255, 255, 0.05);
    --card-hover-bg: #25252b;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-primary);
    display: flex;
    min-height: 100vh;
    overflow-x: hidden;
}

/* Sidebar Styling */
.sidebar {
    width: 280px;
    background-color: var(--sidebar-bg);
    height: 100vh;
    position: fixed;
    left: 0;
    top: 0;
    display: flex;
    flex-direction: column;
    padding: 40px 20px;
    border-right: 1px solid var(--border-color);
    z-index: 100;
}

.logo-container {
    text-align: center;
    margin-bottom: 50px;
}

.logo {
    font-size: 32px;
    font-weight: 800;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.logo span {
    color: var(--accent-color);
}

.logo-sub {
    font-size: 24px;
    display: block;
    color: var(--accent-color);
    font-weight: 700;
    margin-top: -10px;
}

.nav-menu {
    list-style: none;
    flex-grow: 1;
}

.nav-item {
    margin-bottom: 12px;
}

.nav-link {
    display: flex;
    align-items: center;
    padding: 14px 20px;
    color: var(--text-secondary);
    text-decoration: none;
    border-radius: 12px;
    font-weight: 600;
    transition: var(--transition);
    gap: 15px;
}

.nav-link i {
    font-size: 20px;
}

.nav-link:hover,
.nav-link.active {
    background: rgba(255, 0, 85, 0.1);
    color: var(--text-primary);
    box-shadow: inset 0 0 0 1px var(--accent-color);
}

.nav-link.active {
    background: var(--accent-color);
    box-shadow: 0 4px 20px var(--accent-glow);
}

.info-cards {
    margin-top: auto;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.info-card {
    background: var(--card-bg);
    padding: 20px;
    border-radius: 16px;
    border: 1px solid var(--border-color);
}

.info-card h4 {
    color: var(--text-primary);
    font-size: 14px;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 8px;
    text-transform: uppercase;
}

.info-card p {
    color: var(--text-secondary);
    font-size: 13px;
    line-height: 1.5;
}

.info-card .accent-text {
    color: var(--accent-color);
    font-weight: 600;
    margin-top: 10px;
    display: block;
    cursor: pointer;
}

/* Main Content Area */
.main-wrapper {
    margin-left: 280px;
    width: calc(100% - 280px);
    min-height: 100vh;
    padding: 40px;
}

.top-bar {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 40px;
}

.btn-cart {
    background: var(--card-bg);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    padding: 12px 24px;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: var(--transition);
    position: relative;
}

.btn-cart:hover {
    background: var(--card-hover-bg);
    border-color: var(--accent-color);
}

.cart-count {
    background: var(--accent-color);
    color: white;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
}

/* Section Management */
.content-section {
    display: block;
    animation: fadeIn 0.5s ease-out;
}

.content-section.hidden {
    display: none;
}

/* Home Section Styles */
.welcome-banner {
    text-align: center;
    padding: 60px 20px;
    background: linear-gradient(135deg, var(--card-bg) 0%, var(--sidebar-bg) 100%);
    border-radius: 20px;
    margin-bottom: 40px;
    border: 1px solid var(--border-color);
}

.welcome-title {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 15px;
}

.welcome-title span {
    color: var(--accent-color);
    text-shadow: 0 0 30px var(--accent-glow);
}

.welcome-subtitle {
    font-size: 20px;
    color: var(--text-secondary);
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 50px;
}

.stat-card {
    background: var(--card-bg);
    padding: 30px;
    border-radius: 16px;
    text-align: center;
    border: 1px solid var(--border-color);
    transition: var(--transition);
}

.stat-card:hover {
    border-color: var(--accent-color);
    transform: translateY(-5px);
}

.stat-card i {
    font-size: 40px;
    color: var(--accent-color);
    margin-bottom: 15px;
}

.stat-card h3 {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 10px;
}

.stat-card p {
    color: var(--text-secondary);
    font-size: 14px;
}

/* Featured Section */
.featured-section {
    margin-top: 50px;
}

.section-title {
    font-size: 28px;
    text-align: center;
    margin-bottom: 40px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
}

.feature-box {
    background: var(--card-bg);
    padding: 30px;
    border-radius: 16px;
    border: 1px solid var(--border-color);
    transition: var(--transition);
    text-align: center;
}

.feature-box:hover {
    border-color: var(--accent-color);
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.feature-box i {
    font-size: 48px;
    color: var(--accent-color);
    margin-bottom: 20px;
}

.feature-box h3 {
    font-size: 20px;
    margin-bottom: 15px;
}

.feature-box p {
    color: var(--text-secondary);
    line-height: 1.6;
    font-size: 14px;
}

.section-header {
    background: var(--card-bg);
    padding: 15px 30px;
    border-radius: 12px;
    margin-bottom: 30px;
}

.section-header h2 {
    font-size: 20px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Grid System */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 30px;
}

/* Card Styling */
.script-card {
    background: var(--card-bg);
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid var(--border-color);
    transition: var(--transition);
    position: relative;
}

.script-card:hover {
    transform: translateY(-10px);
    border-color: var(--accent-color);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

/* Shopping Cart Modal */
.cart-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    z-index: 1000;
    display: none;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease-out;
}

.cart-modal.active {
    display: flex;
}

/* Scroll fix for PayPal expanded form */
.cart-content {
    background: var(--sidebar-bg);
    width: 90%;
    max-width: 600px;
    max-height: 90vh;
    /* Increased height */
    overflow-y: auto;
    /* Global scroll for the modal content */
    border-radius: 20px;
    border: 1px solid var(--accent-color);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    animation: slideUp 0.4s ease-out;
}

@keyframes slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.cart-header {
    padding: 25px 30px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-shrink: 0;
    /* Header stays at top */
}

.cart-header h2 {
    font-size: 24px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.close-cart {
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-size: 24px;
    cursor: pointer;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.close-cart:hover {
    background: var(--card-bg);
    color: var(--accent-color);
}

.cart-items {
    padding: 20px 30px;
    /* Removed overflow-y: auto and max-height to let content grow */
}

.empty-cart {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-secondary);
}

.empty-cart i {
    font-size: 64px;
    margin-bottom: 20px;
    opacity: 0.3;
}

.empty-cart p {
    font-size: 18px;
}

.cart-item {
    display: flex;
    gap: 15px;
    padding: 15px;
    background: var(--card-bg);
    border-radius: 12px;
    margin-bottom: 15px;
    border: 1px solid var(--border-color);
}

.cart-item-image {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 8px;
}

.cart-item-info {
    flex-grow: 1;
}

.cart-item-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 8px;
}

.cart-item-price {
    color: var(--accent-color);
    font-weight: 700;
    font-size: 18px;
}

.cart-item-remove {
    background: transparent;
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    padding: 8px 12px;
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition);
}

.cart-item-remove:hover {
    border-color: #ff0055;
    color: #ff0055;
}

.cart-footer {
    padding: 25px 30px;
    border-top: 1px solid var(--border-color);
}

.cart-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    font-size: 20px;
    font-weight: 700;
}

.total-price {
    color: var(--accent-color);
    font-size: 28px;
}

.btn-checkout {
    width: 100%;
    background: var(--accent-color);
    color: white;
    border: none;
    padding: 16px;
    border-radius: 12px;
    font-weight: 700;
    font-size: 16px;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.btn-checkout:hover {
    background: #cc0044;
    box-shadow: 0 6px 25px var(--accent-glow);
    transform: translateY(-2px);
}

.card-banner {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-bottom: 1px solid var(--border-color);
}

.card-content {
    padding: 25px;
}

.card-title {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 15px;
    text-align: center;
    text-transform: uppercase;
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.card-price-row {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
}

.current-price {
    font-size: 22px;
    font-weight: 700;
}

.old-price {
    color: var(--text-secondary);
    text-decoration: line-through;
    font-size: 14px;
}

.discount-badge {
    position: absolute;
    top: 20px;
    right: 20px;
    background: var(--accent-color);
    color: white;
    padding: 5px 12px;
    border-radius: 8px;
    font-weight: 700;
    font-size: 12px;
    box-shadow: 0 4px 15px var(--accent-glow);
}

.btn-purchase {
    width: 100%;
    background: transparent;
    border: 2px solid var(--accent-color);
    color: var(--text-primary);
    padding: 12px;
    border-radius: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-bottom: 20px;
}

.btn-purchase:hover {
    background: var(--accent-color);
    box-shadow: 0 4px 20px var(--accent-glow);
}

.features-list {
    list-style: none;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-secondary);
    font-size: 13px;
    margin-bottom: 8px;
}

.feature-item i {
    color: #00ff88;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.script-card {
    animation: fadeIn 0.5s ease-out forwards;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-color);
}

::-webkit-scrollbar-thumb {
    background: var(--card-bg);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--accent-color);
}

/* Notification System */
.notification {
    position: fixed;
    top: 30px;
    right: 30px;
    background: var(--card-bg);
    border: 1px solid var(--accent-color);
    padding: 18px 24px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 12px;
    z-index: 1000;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5), 0 0 20px var(--accent-glow);
    transform: translateX(400px);
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.notification.show {
    transform: translateX(0);
    opacity: 1;
}

.notification i {
    color: var(--accent-color);
    font-size: 20px;
}

.notification span {
    color: var(--text-primary);
    font-weight: 600;
}

.notification-success {
    border-color: #00ff88;
}

.notification-success i {
    color: #00ff88;
}

/* Responsive Design */
@media (max-width: 1200px) {
    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    }

    .features-grid {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    }
}

@media (max-width: 768px) {
    .sidebar {
        width: 100%;
        height: auto;
        position: relative;
        padding: 20px;
    }

    .main-wrapper {
        margin-left: 0;
        width: 100%;
        padding: 20px;
    }

    .products-grid {
        grid-template-columns: 1fr;
    }

    .logo {
        font-size: 24px;
    }

    .notification {
        right: 10px;
        top: 10px;
        left: 10px;
    }

    .welcome-title {
        font-size: 32px;
    }

    .welcome-subtitle {
        font-size: 16px;
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .features-grid {
        grid-template-columns: 1fr;
    }

    .cart-content {
        width: 95%;
        max-height: 90vh;
    }

    .cart-text {
        display: none;
    }
}

/* Success Modal Styles */
.success-body {
    padding: 20px;
    flex-grow: 1;
    overflow-y: auto;
}

.success-message {
    text-align: center;
    color: var(--text-secondary);
    margin-bottom: 25px;
}

.download-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.download-item {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    padding: 15px;
    border-radius: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: var(--transition);
}

.download-item:hover {
    border-color: var(--success-color);
    background: rgba(0, 255, 136, 0.05);
}

.download-info h4 {
    color: var(--text-primary);
    font-size: 16px;
    margin-bottom: 4px;
}

.download-info span {
    color: var(--text-secondary);
    font-size: 12px;
}

.btn-download {
    background: var(--success-color);
    color: var(--bg-color);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: var(--transition);
    box-shadow: 0 4px 15px rgba(0, 255, 136, 0.3);
}

.btn-download:hover {
    transform: translateY(-2px) scale(1.1);
    box-shadow: 0 6px 20px rgba(0, 255, 136, 0.5);
}

.btn-download i {
    font-size: 18px;
}