🎮ArcadeLab

ظلال الأبطال - Shadows of Heroes

by MegaOtter89
1017 lines19.8 KB
▶ Play
<!DOCTYPE html>
<html lang="ar" dir="rtl">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>ظلال الأبطال - Shadows of Heroes</title>
<style>
/* ============================================
   الأنماط الأساسية (Base Styles)
   ============================================ */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

html, body {
    width: 100%;
    height: 100%;
    overflow: hidden;
    background: #000;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: #fff;
}

body {
    display: flex;
    justify-content: center;
    align-items: center;
    background: radial-gradient(ellipse at center, #1a0033 0%, #000000 100%);
    position: relative;
}

/* ============================================
   حاوية اللعبة الرئيسية
   ============================================ */
#gameContainer {
    position: relative;
    width: 960px;
    height: 640px;
    border: 3px solid #4a2c7a;
    border-radius: 8px;
    box-shadow: 0 0 40px rgba(128, 0, 255, 0.5),
                inset 0 0 20px rgba(0, 0, 0, 0.8);
    overflow: hidden;
    background: #000;
}

#gameCanvas {
    display: block;
    width: 100%;
    height: 100%;
    image-rendering: pixelated;
    image-rendering: crisp-edges;
    cursor: crosshair;
}

/* ============================================
   شاشات القوائم
   ============================================ */
.screen {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: none;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    background: radial-gradient(ellipse at center, rgba(40, 0, 80, 0.95) 0%, rgba(0, 0, 0, 0.98) 100%);
    z-index: 100;
    animation: fadeIn 0.5s ease-out;
}

.screen.active {
    display: flex;
}

@keyframes fadeIn {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}

@keyframes slideIn {
    from { opacity: 0; transform: translateY(-20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes pulse {
    0%, 100% { transform: scale(1); text-shadow: 0 0 20px currentColor; }
    50% { transform: scale(1.05); text-shadow: 0 0 40px currentColor; }
}

@keyframes glow {
    0%, 100% { box-shadow: 0 0 20px rgba(255, 215, 0, 0.5); }
    50% { box-shadow: 0 0 40px rgba(255, 215, 0, 0.9); }
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

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

/* ============================================
   شاشة العنوان الرئيسية
   ============================================ */
.title {
    font-size: 72px;
    font-weight: bold;
    color: #ffd700;
    text-shadow: 0 0 20px #ff6600,
                 0 0 40px #ff0066,
                 4px 4px 0 #4a0000;
    margin-bottom: 20px;
    animation: pulse 2s infinite;
    letter-spacing: 4px;
}

.subtitle {
    font-size: 28px;
    color: #aaa;
    margin-bottom: 60px;
    font-style: italic;
    letter-spacing: 2px;
}

.menu-button {
    width: 300px;
    padding: 15px 30px;
    margin: 10px;
    font-size: 22px;
    font-weight: bold;
    color: #fff;
    background: linear-gradient(135deg, #4a2c7a 0%, #2a1850 100%);
    border: 2px solid #ffd700;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-shadow: 2px 2px 4px #000;
    letter-spacing: 1px;
}

.menu-button:hover {
    background: linear-gradient(135deg, #6a3c9a 0%, #4a2870 100%);
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 10px 30px rgba(255, 215, 0, 0.5);
    animation: glow 1.5s infinite;
}

.menu-button:active {
    transform: translateY(0) scale(0.98);
}

/* ============================================
   شاشة اختيار الشخصية
   ============================================ */
.character-select {
    display: flex;
    gap: 30px;
    margin: 40px 0;
}

.character-card {
    width: 200px;
    padding: 20px;
    background: linear-gradient(135deg, rgba(74, 44, 122, 0.8), rgba(42, 24, 80, 0.8));
    border: 3px solid #666;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
}

.character-card:hover {
    transform: translateY(-10px);
    border-color: #ffd700;
    box-shadow: 0 15px 40px rgba(255, 215, 0, 0.4);
}

.character-card.selected {
    border-color: #ffd700;
    background: linear-gradient(135deg, rgba(120, 80, 180, 0.9), rgba(60, 30, 120, 0.9));
    box-shadow: 0 0 30px rgba(255, 215, 0, 0.6);
}

.character-icon {
    width: 100px;
    height: 100px;
    margin: 0 auto 15px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 60px;
    border: 3px solid #fff;
}

.character-name {
    font-size: 24px;
    font-weight: bold;
    color: #ffd700;
    margin-bottom: 10px;
}

.character-desc {
    font-size: 14px;
    color: #ccc;
    line-height: 1.5;
    margin-bottom: 15px;
}

.character-stats {
    display: flex;
    flex-direction: column;
    gap: 5px;
    font-size: 12px;
}

.stat-row {
    display: flex;
    justify-content: space-between;
    padding: 3px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.stat-label {
    color: #aaa;
}

.stat-value {
    color: #ffd700;
    font-weight: bold;
}

/* ============================================
   شاشة الإعدادات
   ============================================ */
.settings-panel {
    width: 500px;
    padding: 30px;
    background: rgba(20, 10, 40, 0.95);
    border: 2px solid #ffd700;
    border-radius: 12px;
}

.settings-title {
    font-size: 36px;
    color: #ffd700;
    text-align: center;
    margin-bottom: 30px;
}

.setting-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
    border-bottom: 1px solid rgba(255, 215, 0, 0.2);
}

.setting-label {
    font-size: 18px;
    color: #fff;
}

.setting-control {
    display: flex;
    align-items: center;
    gap: 10px;
}

input[type="range"] {
    width: 200px;
    height: 6px;
    background: #333;
    border-radius: 3px;
    outline: none;
    -webkit-appearance: none;
}

input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    background: #ffd700;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 0 10px rgba(255, 215, 0, 0.8);
}

input[type="range"]::-moz-range-thumb {
    width: 20px;
    height: 20px;
    background: #ffd700;
    border-radius: 50%;
    cursor: pointer;
    border: none;
}

select {
    padding: 8px 15px;
    background: #2a1850;
    color: #fff;
    border: 2px solid #ffd700;
    border-radius: 6px;
    font-size: 16px;
    cursor: pointer;
    outline: none;
}

.toggle-switch {
    position: relative;
    width: 60px;
    height: 30px;
    background: #333;
    border-radius: 15px;
    cursor: pointer;
    transition: background 0.3s;
}

.toggle-switch.active {
    background: #4a2c7a;
}

.toggle-switch::after {
    content: '';
    position: absolute;
    top: 3px;
    left: 3px;
    width: 24px;
    height: 24px;
    background: #fff;
    border-radius: 50%;
    transition: transform 0.3s;
}

.toggle-switch.active::after {
    transform: translateX(30px);
    background: #ffd700;
}

/* ============================================
   واجهة المستخدم أثناء اللعب (HUD)
   ============================================ */
#hud {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 10;
}

.hud-element {
    position: absolute;
    pointer-events: auto;
}

/* شريط الصحة */
.health-bar-container {
    top: 20px;
    left: 20px;
    width: 250px;
}

.bar-label {
    font-size: 14px;
    font-weight: bold;
    color: #fff;
    margin-bottom: 5px;
    text-shadow: 2px 2px 4px #000;
    display: flex;
    justify-content: space-between;
}

.bar-outer {
    width: 100%;
    height: 25px;
    background: rgba(0, 0, 0, 0.7);
    border: 2px solid #fff;
    border-radius: 4px;
    overflow: hidden;
    position: relative;
}

.bar-inner {
    height: 100%;
    transition: width 0.3s ease;
    position: relative;
    overflow: hidden;
}

.health-bar {
    background: linear-gradient(90deg, #ff0000 0%, #ff6600 50%, #ffaa00 100%);
}

.mana-bar {
    background: linear-gradient(90deg, #0066ff 0%, #00aaff 50%, #66ffff 100%);
}

.stamina-bar {
    background: linear-gradient(90deg, #00aa00 0%, #66ff00 50%, #aaff66 100%);
}

.xp-bar {
    background: linear-gradient(90deg, #aa00ff 0%, #ff00ff 50%, #ff66ff 100%);
}

.boss-health-bar {
    background: linear-gradient(90deg, #880000 0%, #ff0000 50%, #ff6600 100%);
}

.bar-inner::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 50%;
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0.3), transparent);
}

.bar-inner::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    animation: shimmer 2s infinite;
}

/* شريط المانا */
.mana-bar-container {
    top: 75px;
    left: 20px;
    width: 250px;
}

/* شريط القدرة */
.stamina-bar-container {
    top: 130px;
    left: 20px;
    width: 250px;
}

/* شريط الخبرة */
.xp-bar-container {
    top: 185px;
    left: 20px;
    width: 250px;
}

/* معلومات المستوى */
.level-display {
    top: 20px;
    left: 280px;
    background: rgba(0, 0, 0, 0.7);
    border: 2px solid #ffd700;
    border-radius: 8px;
    padding: 10px 15px;
    min-width: 120px;
    text-align: center;
}

.level-text {
    font-size: 14px;
    color: #aaa;
}

.level-number {
    font-size: 32px;
    font-weight: bold;
    color: #ffd700;
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.8);
}

/* شريط صحة الزعيم */
.boss-health-container {
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 500px;
    display: none;
}

.boss-health-container.active {
    display: block;
    animation: slideIn 0.5s ease-out;
}

.boss-name {
    font-size: 20px;
    color: #ff0000;
    text-align: center;
    margin-bottom: 5px;
    text-shadow: 0 0 10px #ff0000;
    font-weight: bold;
}

/* عداد النقود */
.gold-display {
    top: 20px;
    right: 20px;
    background: rgba(0, 0, 0, 0.7);
    border: 2px solid #ffd700;
    border-radius: 8px;
    padding: 10px 15px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 20px;
    color: #ffd700;
    font-weight: bold;
}

.gold-icon {
    width: 30px;
    height: 30px;
    background: radial-gradient(circle, #ffd700 0%, #ff8800 100%);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    color: #000;
    font-weight: bold;
    box-shadow: 0 0 10px rgba(255, 215, 0, 0.8);
}

/* شريط الأسلحة */
.weapon-bar {
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    background: rgba(0, 0, 0, 0.7);
    padding: 10px;
    border-radius: 8px;
    border: 2px solid #ffd700;
}

.weapon-slot {
    width: 60px;
    height: 60px;
    background: rgba(40, 20, 80, 0.8);
    border: 2px solid #666;
    border-radius: 6px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 32px;
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
}

.weapon-slot.active {
    border-color: #ffd700;
    background: rgba(100, 60, 150, 0.9);
    box-shadow: 0 0 20px rgba(255, 215, 0, 0.6);
    transform: translateY(-5px);
}

.weapon-slot:hover {
    border-color: #ffd700;
}

.weapon-key {
    position: absolute;
    top: 2px;
    right: 2px;
    font-size: 12px;
    color: #ffd700;
    background: rgba(0, 0, 0, 0.8);
    padding: 2px 5px;
    border-radius: 3px;
    font-weight: bold;
}

.cooldown-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: rgba(0, 0, 0, 0.7);
    transition: height 0.1s linear;
}

/* أزرار المهارات */
.skill-bar {
    bottom: 100px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
}

.skill-slot {
    width: 50px;
    height: 50px;
    background: rgba(40, 20, 80, 0.8);
    border: 2px solid #666;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 24px;
    cursor: pointer;
    position: relative;
    transition: all 0.2s;
}

.skill-slot.ready {
    border-color: #00ff00;
    box-shadow: 0 0 15px rgba(0, 255, 0, 0.5);
}

.skill-slot.on-cooldown {
    border-color: #ff0000;
    opacity: 0.6;
}

/* الخريطة المصغرة */
.minimap {
    bottom: 20px;
    right: 20px;
    width: 180px;
    height: 180px;
    background: rgba(0, 0, 0, 0.7);
    border: 2px solid #ffd700;
    border-radius: 8px;
    overflow: hidden;
}

.minimap-canvas {
    width: 100%;
    height: 100%;
}

/* رسائل اللعبة */
.message-container {
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    pointer-events: none;
    z-index: 50;
}

.game-message {
    font-size: 48px;
    font-weight: bold;
    color: #ffd700;
    text-shadow: 0 0 20px #ff6600, 4px 4px 0 #000;
    animation: messageAppear 2s ease-out;
    opacity: 0;
}

@keyframes messageAppear {
    0% { opacity: 0; transform: scale(0.5); }
    20% { opacity: 1; transform: scale(1.2); }
    80% { opacity: 1; transform: scale(1); }
    100% { opacity: 0; transform: scale(1); }
}

/* صندوق الحوار */
.dialog-box {
    bottom: 100px;
    left: 50%;
    transform: translateX(-50%);
    width: 700px;
    background: rgba(20, 10, 40, 0.95);
    border: 3px solid #ffd700;
    border-radius: 12px;
    padding: 20px;
    display: none;
}

.dialog-box.active {
    display: block;
    animation: slideIn 0.3s ease-out;
}

.dialog-speaker {
    font-size: 20px;
    color: #ffd700;
    font-weight: bold;
    margin-bottom: 10px;
}

.dialog-text {
    font-size: 16px;
    color: #fff;
    line-height: 1.6;
    min-height: 60px;
}

.dialog-continue {
    text-align: left;
    color: #aaa;
    font-size: 14px;
    margin-top: 10px;
    animation: pulse 1.5s infinite;
}

/* المخزون */
.inventory-screen {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    display: none;
    z-index: 80;
    padding: 40px;
}

.inventory-screen.active {
    display: flex;
    gap: 20px;
}

.inventory-panel {
    flex: 1;
    background: rgba(40, 20, 80, 0.8);
    border: 2px solid #ffd700;
    border-radius: 8px;
    padding: 20px;
    overflow-y: auto;
}

.inventory-title {
    font-size: 24px;
    color: #ffd700;
    margin-bottom: 15px;
    text-align: center;
    border-bottom: 2px solid #ffd700;
    padding-bottom: 10px;
}

.inventory-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 8px;
}

.inventory-slot {
    aspect-ratio: 1;
    background: rgba(0, 0, 0, 0.5);
    border: 2px solid #666;
    border-radius: 4px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 24px;
    cursor: pointer;
    position: relative;
    transition: all 0.2s;
}

.inventory-slot:hover {
    border-color: #ffd700;
    background: rgba(100, 60, 150, 0.5);
}

.inventory-slot.has-item {
    border-color: #aaa;
}

.item-count {
    position: absolute;
    bottom: 2px;
    right: 2px;
    font-size: 12px;
    color: #fff;
    background: rgba(0, 0, 0, 0.8);
    padding: 2px 5px;
    border-radius: 3px;
}

.item-rarity-common { border-color: #aaa !important; }
.item-rarity-uncommon { border-color: #00ff00 !important; }
.item-rarity-rare { border-color: #0066ff !important; }
.item-rarity-epic { border-color: #aa00ff !important; }
.item-rarity-legendary { border-color: #ffd700 !important; box-shadow: 0 0 15px rgba(255, 215, 0, 0.5); }

.item-details {
    width: 300px;
    background: rgba(40, 20, 80, 0.8);
    border: 2px solid #ffd700;
    border-radius: 8px;
    padding: 20px;
}

.item-name {
    font-size: 22px;
    font-weight: bold;
    margin-bottom: 10px;
}

.item-type {
    font-size: 14px;
    color: #aaa;
    margin-bottom: 15px;
}

.item-description {
    font-size: 14px;
    color: #ccc;
    line-height: 1.5;
    margin-bottom: 15px;
    font-style: italic;
}

.item-stats {
    display: flex;
    flex-direction: column;
    gap: 5px;
    margin-bottom: 15px;
}

.item-stat {
    display: flex;
    justify-content: space-between;
    padding: 5px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 14px;
}

.item-use-button {
    width: 100%;
    padding: 10px;
    background: linear-gradient(135deg, #4a2c7a, #2a1850);
    border: 2px solid #ffd700;
    border-radius: 6px;
    color: #fff;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s;
}

.item-use-button:hover {
    background: linear-gradient(135deg, #6a3c9a, #4a2870);
    transform: translateY(-2px);
}

/* شاشة الإحصائيات */
.stats-panel {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.stat-item {
    display: flex;
    justify-content: space-between;
    padding: 10px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 4px;
    font-size: 16px;
}

.stat-name {
    color: #aaa;
}

.stat-val {
    color: #ffd700;
    font-weight: bold;
}

/* شاشة الترقية */
.level-up-screen {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(20, 10, 40, 0.98);
    border: 3px solid #ffd700;
    border-radius: 12px;
    padding: 40px;
    display: none;
    z-index: 90;
    min-width: 500px;
}

.level-up-screen.active {
    display: block;
    animation: slideIn 0.5s ease-out;
}

.level-up-title {
    font-size: 36px;
    color: #ffd700;
    text-align: center;
    margin-bottom: 20px;
    text-shadow: 0 0 20px rgba(255, 215, 0, 0.8);
}

.level-up-subtitle {
    text-align: center;
    color: #aaa;
    margin-bottom: 30px;
    font-size: 18px;
}

.upgrade-options {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.upgrade-option {
    padding: 15px 20px;
    background: rgba(40, 20, 80, 0.8);
    border: 2px solid #666;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 15px;
}

.upgrade-option:hover {
    border-color: #ffd700;
    background: rgba(100, 60, 150, 0.8);
    transform: translateX(-5px);
}

.upgrade-icon {
    width: 50px;
    height: 50px;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 8px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 28px;
}

.upgrade-info {
    flex: 1;
}

.upgrade-name {
    font-size: 18px;
    color: #ffd700;
    font-weight: bold;
    margin-bottom: 5px;
}

.upgrade-desc {
    font-size: 14px;
    color: #ccc;
}

/* شاشة الموت */
.death-screen {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(ellipse at center, rgba(100, 0, 0, 0.9) 0%, rgba(0, 0, 0, 0.98) 100%);
    display: none;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    z-index: 95;
}

.death-screen.active {
    display: flex;
    animation: fadeIn 1s ease-out;
}

.death-title {
    font-size: 96px;
    color: #ff0000;
    text-shadow: 0 0 30px #ff0000, 6px 6px 0 #440000;
    margin-bottom: 30px;
    animation: pulse 2s infinite;
}

.death-stats {
    background: rgba(0, 0, 0, 0.7);
    border: 2px solid #ff0000;
    border-radius: 8px;
    padding: 30px;
    margin-bottom: 30px;
    min-width: 400px;
}

.death-stat-row {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid rgba(255, 0, 0, 0.2);
    font-size: 18px;
}

/* شاشة الانتصار */
.victo

Game Source: ظلال الأبطال - Shadows of Heroes

Creator: MegaOtter89

Libraries: none

Complexity: complex (1017 lines, 19.8 KB)

The full source code is displayed above on this page.

Remix Instructions

To remix this game, copy the source code above and modify it. Add a ARCADELAB header at the top with "remix_of: shadows-of-heroes-megaotter89" to link back to the original. Then publish at arcadelab.ai/publish.