/* Modern Design System - Inspired by picturize-it-pro */

:root {
    /* Primary Colors */
    --color-teal: #14b8a6;
    --color-teal-dark: #0d9488;
    --color-orange: #ea580c;
    --color-orange-dark: #c2410c;

    /* Neutral Colors */
    --color-white: #ffffff;
    --color-gray-50: #f9fafb;
    --color-gray-100: #f3f4f6;
    --color-gray-300: #d1d5db;
    --color-gray-600: #4b5563;
    --color-gray-700: #374151;
    --color-gray-900: #111827;

    /* Success */
    --color-green: #10b981;

    /* Spacing */
    --radius-sm: 12px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --radius-xl: 32px;

    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1);

    /* Font */
    font-family: 'Tajawal', 'Cairo', -apple-system, sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: var(--color-white);
    color: var(--color-gray-900);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
}

/* Background Effect */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at top right, rgba(20, 184, 166, 0.05), transparent 50%),
        radial-gradient(circle at bottom left, rgba(234, 88, 12, 0.05), transparent 50%);
    pointer-events: none;
    z-index: -1;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Header */
.header {
    padding: 24px 0;
    position: relative;
    z-index: 100;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-section {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-icon {
    width: 48px;
    height: 48px;
    background: var(--color-teal);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 24px;
}

.logo-text h1 {
    font-size: 20px;
    font-weight: 700;
    color: var(--color-gray-900);
    margin: 0;
}

.logo-text p {
    font-size: 12px;
    color: var(--color-gray-600);
    margin: 0;
}

/* Wallet Widget */
.wallet-widget {
    background: white;
    border-radius: var(--radius-xl);
    padding: 12px 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    box-shadow: var(--shadow-md);
    border: 1px solid var(--color-gray-100);
}

.wallet-info {
    display: flex;
    align-items: center;
    gap: 8px;
}

.wallet-icon {
    font-size: 20px;
}

.wallet-balance {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.wallet-label {
    font-size: 11px;
    color: var(--color-gray-600);
}

.wallet-credits {
    font-size: 18px;
    font-weight: 700;
    color: var(--color-teal);
}

.wallet-credits span {
    font-size: 12px;
    color: var(--color-gray-600);
    font-weight: 400;
}

.wallet-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--color-orange);
    color: white;
    border: none;
    font-size: 20px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.wallet-btn:hover {
    background: var(--color-orange-dark);
    transform: scale(1.05);
}

/* Hero Section */
.hero {
    text-align: center;
    padding: 80px 0 120px;
    max-width: 700px;
    margin: 0 auto;
}

.hero-icon {
    width: 120px;
    height: 120px;
    background: var(--color-teal);
    border-radius: var(--radius-xl);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 32px;
    font-size: 56px;
    color: white;
}

.hero h1 {
    font-size: 48px;
    font-weight: 800;
    color: var(--color-gray-900);
    margin-bottom: 16px;
    line-height: 1.2;
}

.hero p {
    font-size: 20px;
    color: var(--color-gray-600);
    margin-bottom: 40px;
}

/* CTA Buttons */
.cta-buttons {
    display: flex;
    gap: 16px;
    justify-content: center;
    margin-bottom: 32px;
    flex-wrap: wrap;
}

.btn {
    padding: 16px 32px;
    border-radius: var(--radius-lg);
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: none;
    text-decoration: none;
}

.btn-primary {
    background: var(--color-orange);
    color: white;
    box-shadow: var(--shadow-md);
}

.btn-primary:hover {
    background: var(--color-orange-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    background: white;
    color: var(--color-teal);
    border: 2px solid var(--color-teal);
}

.btn-secondary:hover {
    background: var(--color-gray-50);
}

/* Features Badges */
.features-badges {
    display: flex;
    gap: 24px;
    justify-content: center;
    flex-wrap: wrap;
}

.feature-badge {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--color-gray-700);
    font-size: 14px;
}

.feature-badge::before {
    content: '';
    width: 8px;
    height: 8px;
    background: var(--color-green);
    border-radius: 50%;
}


/* Responsive */
@media (max-width: 768px) {
    .hero h1 {
        font-size: 32px;
    }

    .hero p {
        font-size: 16px;
    }

    .cta-buttons {
        flex-direction: column;
    }

    .btn {
        width: 100%;
        justify-content: center;
    }

    .wallet-widget {
        flex-direction: column;
        gap: 8px;
    }

    .nav-menu {
        display: none;
    }

    .header-right {
        gap: 8px;
    }

    .packages-grid {
        grid-template-columns: 1fr;
    }

    .features-grid {
        grid-template-columns: 1fr;
    }
}

/* Navigation Menu */
.nav-menu {
    display: flex;
    gap: 8px;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border-radius: var(--radius-md);
    color: var(--color-gray-600);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s;
}

.nav-link:hover {
    background: var(--color-gray-100);
    color: var(--color-gray-900);
}

.nav-link.active {
    background: var(--color-teal);
    color: white;
}

.nav-link i {
    font-size: 16px;
}

/* Header Right Section */
.header-right {
    display: flex;
    align-items: center;
    gap: 16px;
}

.btn-auth {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 20px;
    border-radius: var(--radius-md);
    background: white;
    border: 1px solid var(--color-gray-300);
    color: var(--color-gray-700);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-auth:hover {
    background: var(--color-gray-50);
    border-color: var(--color-gray-600);
}

/* Page Title */
.page-title {
    text-align: center;
    padding: 60px 0 40px;
}

.page-title h1 {
    font-size: 48px;
    font-weight: 800;
    background: linear-gradient(135deg, var(--color-teal), var(--color-orange));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 12px;
}

.page-title p {
    font-size: 20px;
    color: var(--color-gray-600);
}

/* Packages Grid */
.packages-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 32px;
    max-width: 1000px;
    margin: 0 auto 80px;
}

.package-card {
    background: white;
    border-radius: var(--radius-xl);
    padding: 32px;
    box-shadow: var(--shadow-lg);
    border: 2px solid transparent;
    transition: all 0.3s;
    position: relative;
    text-align: center;
}

.package-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.12);
}

.package-card.popular {
    border-color: var(--color-teal);
    transform: scale(1.05);
}

.package-card.popular:hover {
    transform: scale(1.05) translateY(-8px);
}

.package-badge {
    position: absolute;
    top: -16px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, var(--color-orange), var(--color-orange-dark));
    color: white;
    padding: 6px 20px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 700;
    box-shadow: var(--shadow-md);
}

.package-header h3 {
    font-size: 24px;
    font-weight: 700;
    color: var(--color-gray-900);
    margin-bottom: 8px;
}

.package-description {
    font-size: 14px;
    color: var(--color-gray-600);
    margin-bottom: 24px;
    min-height: 40px;
}

.package-price {
    margin-bottom: 20px;
}

.price-amount {
    font-size: 56px;
    font-weight: 800;
    background: linear-gradient(135deg, var(--color-teal), var(--color-orange));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1;
}

.price-currency {
    font-size: 14px;
    color: var(--color-gray-500);
    margin-top: 4px;
}

.package-credits {
    background: rgba(20, 184, 166, 0.1);
    border-radius: var(--radius-md);
    padding: 20px;
    margin-bottom: 16px;
}

.credits-amount {
    font-size: 40px;
    font-weight: 700;
    color: var(--color-teal);
}

.credits-label {
    font-size: 14px;
    color: var(--color-gray-600);
}

.package-per-image {
    font-size: 13px;
    color: var(--color-gray-500);
    margin-bottom: 24px;
}

.package-btn {
    display: block;
    width: 100%;
    padding: 16px;
    background: var(--color-orange);
    color: white;
    border-radius: var(--radius-lg);
    font-size: 16px;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.2s;
    box-shadow: var(--shadow-md);
}

.package-btn:hover {
    background: var(--color-orange-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

/* Features Section */
.features-section {
    max-width: 900px;
    margin: 0 auto;
    background: white;
    border-radius: var(--radius-xl);
    padding: 40px;
    box-shadow: var(--shadow-md);
}

.features-section h2 {
    text-align: center;
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 32px;
    color: var(--color-gray-900);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 24px;
}

.feature-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.feature-icon {
    font-size: 32px;
    flex-shrink: 0;
}

.feature-item h3 {
    font-size: 16px;
    font-weight: 700;
    color: var(--color-gray-900);
    margin-bottom: 4px;
}

.feature-item p {
    font-size: 13px;
    color: var(--color-gray-600);
}

/* Loading Animation */
@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.loading {
    animation: spin 1s linear infinite;
}

/* Hidden Helper */
.hidden {
    display: none !important;
}

/* Glass Effect for Editor Page */
.glass-effect {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
}

/* Editor Page Body */
body:has(.glass-effect) {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(168, 85, 247, 0.1), rgba(236, 72, 153, 0.1));
    min-height: 100vh;
}

/* Loading Spinner */
.loading-spinner {
    border: 3px solid rgba(99, 102, 241, 0.2);
    border-top: 3px solid rgb(99, 102, 241);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}