/* ========== كود المصابيح (تم إصلاح المشكلة) ========== */
body {
    margin: 0;
    padding: 0;
    background: #000;
}

.lightrope-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100px;
    z-index: 1000; /* تأكد من أن المصابيح فوق كل العناصر */
}

.curved-rope {
    position: absolute;
    top: 15px;
    left: 0;
    width: 100%;
    height: 2px;
    background: transparent;
    border-bottom: 2px solid #222;
    border-radius: 50% 50% 0 0;
    z-index: 1;
}

.lightrope {
    position: absolute;
    top: 30px;
    left: 0;
    width: 100%;
    /* ===== التعديل هنا: استخدام Flexbox للتوزيع المتساوي (space-between) ===== */
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    /* تم إزالة: text-align: center; و white-space: nowrap; */
    
    pointer-events: none;
    z-index: 1001; /* زيادة z-index لتكون فوق كل شيء */
    transform: scale(1);
}

.lightrope li {
    display: block; /* تغيير من inline-block */
    /* ===== التعديل هنا: إزالة الهامش الأفقي للحصول على توزيع متساوٍ ===== */
    margin: 18px 0;
    position: relative;
}

/* انحناء الحبل للأسفل مع 8 مصابيح - تم تحسين الحركة */
.lightrope li:nth-child(1), .lightrope li:nth-child(8) {
    transform: translateY(-25px);
    animation: swing1 4s ease-in-out infinite;
}
.lightrope li:nth-child(2), .lightrope li:nth-child(7) {
    transform: translateY(-15px);
    animation: swing2 3.5s ease-in-out infinite;
}
.lightrope li:nth-child(3), .lightrope li:nth-child(6) {
    transform: translateY(-8px);
    animation: swing3 3s ease-in-out infinite;
}
.lightrope li:nth-child(4), .lightrope li:nth-child(5) {
    transform: translateY(0px);
    animation: swing4 2.5s ease-in-out infinite;
}

.lightrope li span {
    position: relative;
    display: block;
    width: 12px;
    height: 24px;
    border-radius: 50%;
    background: red;
    box-shadow: 0px 4px 20px 3px red;
    animation-name: rainbow-cycle;
    animation-duration: 2.4s; /* زيادة السرعة 40%: من 4s إلى 2.4s */
    animation-timing-function: linear;
    animation-iteration-count: infinite;
    z-index: 2;
}

.lightrope li:nth-child(4n+1) span { animation-delay: 0s; }
.lightrope li:nth-child(4n+2) span { animation-delay: 0.3s; } /* سرعة التأخير */
.lightrope li:nth-child(4n+3) span { animation-delay: 0.6s; } /* سرعة التأخير */
.lightrope li:nth-child(4n+4) span { animation-delay: 0.9s; } /* سرعة التأخير */

.lightrope li span::before {
    content: "";
    position: absolute;
    background: #222;
    width: 10px;
    height: 8px;
    border-radius: 2px;
    top: -4px;
    left: 1px;
    z-index: 3;
}

/* تم إزالة هذا بسبب استخدام Flexbox */
/* .lightrope li:first-child {
    margin-left: -12px;
} */

@keyframes rainbow-cycle {
    0% { background: #FF0005; box-shadow: 0 4px 20px 3px #FF0005; }
    14% { background: #Ff00cd; box-shadow: 0 4px 20px 3px #FF00cd; }
    28% { background: #FFe100; box-shadow: 0 4px 20px 3px #ffff00; }
    42% { background: #08FF00; box-shadow: 0 4px 20px 3px #00FF00; }
    57% { background: #ff3900; box-shadow: 0 4px 20px 3px #ff3900; }
    100% {
        background: rgba(0, 0, 0, 0.6);
        box-shadow: 0 4px 20px 3px rgba(255, 255, 255, 0.1);
    }
}

/* أنيميشن حركة الرياح للمصابيح */
@keyframes swing1 {
    0%, 100% { transform: translateY(-25px) rotate(-2deg); }
    50% { transform: translateY(-23px) rotate(2deg); }
}

@keyframes swing2 {
    0%, 100% { transform: translateY(-15px) rotate(-1.5deg); }
    50% { transform: translateY(-13px) rotate(1.5deg); }
}

@keyframes swing3 {
    0%, 100% { transform: translateY(-8px) rotate(-1deg); }
    50% { transform: translateY(-6px) rotate(1deg); }
}

@keyframes swing4 {
    0%, 100% { transform: translateY(0px) rotate(-0.5deg); }
    50% { transform: translateY(2px) rotate(0.5deg); }
}

/* وسائط استعلام للهواتف الصغيرة */
@media (max-width: 480px) {
    .lightrope {
        top: 20px;
        padding: 0 8px; /* إضافة padding بسيط للحماية من الحواف */
    }
    .lightrope li {
        /* تم تعديل الهامش ليصبح عموديًا فقط */
        margin: 15px 0;
    }
}

/* ========== التعديلات الجديدة ========== */

/* إعدادات عامة مع لون خط جديد */
* {
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body {
    margin: 0;
    font-family: 'Poppins', 'Segoe UI', sans-serif;
    background-color: #282a36;
    color: #e2e8f0; /* تغيير لون الخط إلى لون أكثر تناسقاً مع الخلفية */
    text-align: center;
    direction: rtl;
    min-height: 100dvh;
    padding-top: 80px; /* إضافة padding لمنع تداخل المحتوى مع المصابيح */
}

/* واجهة الموقع */
.hero-section {
    padding: 40px 16px 24px; /* تقليل padding العلوي لأن المصابيح ثابتة */
    background-color: rgba(30, 30, 47, 0.85);
    position: relative;
    overflow: visible;
    border-bottom-left-radius: 12px;
    border-bottom-right-radius: 12px;
    margin-top: 0; /* إزالة margin-top لأن المصابيح ثابتة */
}

/* الصورة الشخصية - تكبير 35% مع هالة الطاقة */
.profile-wrapper {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 8px;
    z-index: 6;
}

.profile-img {
    width: 189px; /* تكبير 35%: من 140px إلى 189px */
    height: 189px; /* تكبير 35%: من 140px إلى 189px */
    border-radius: 50%;
    border: 3px solid rgba(255,255,255,0.06);
    z-index: 6;
    box-shadow: 0 10px 28px rgba(0,0,0,0.6), 0 0 40px rgba(0,0,0,0.4) inset;
    transition: transform 0.18s ease;
    object-fit: cover;
    position: relative;
}

.profile-img:hover {
    transform: scale(1.03);
}

/* هالة الطاقة النيونية حول الصورة */
.profile-wrapper::before {
    content: "";
    position: absolute;
    width: 240px;
    height: 240px;
    border-radius: 50%;
    background: conic-gradient(
        from 0deg,
        #ff0000,
        #fcf327,
        #00ffff,
        #0066ff,
        #ff00ff,
        #fc6a27
    );
    filter: blur(30px);
    animation: rotateRing 4s linear infinite, colorShift 6s ease-in-out infinite;
    z-index: 5;
    opacity: 0.8;
}

@keyframes rotateRing {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes colorShift {
    0% { filter: hue-rotate(0deg) blur(30px); }
    50% { filter: hue-rotate(180deg) blur(30px); }
    100% { filter: hue-rotate(360deg) blur(30px); }
}

/* اسمك مع تأثير هولوغرافي - تم التكبير وزيادة المسافة */
.name-glow {
    font-size: 42px; /* تكبير الخط من 32px إلى 42px */
    font-weight: 700;
    background: linear-gradient(90deg, #ff004c, #ff8a00, #ffea00, #00ff9f, #00d4ff, #7a00ff, #ff004c);
    background-size: 400% 100%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: nameGradient 6s linear infinite;
    text-shadow: 0 0 10px rgba(255,255,255,0.12);
    margin: 24px 0 6px; /* زيادة المسافة من 12px إلى 24px */
    z-index: 6;
    position: relative;
}

/* ========== الأزرار مع سرعة ضوء متزايدة ========== */

/* الخاصيات المخصصة للزوايا المتحركة */
@property --border-angle-1 {
    syntax: "<angle>";
    inherits: true;
    initial-value: 0deg;
}

@property --border-angle-2 {
    syntax: "<angle>";
    inherits: true;
    initial-value: 90deg;
}

@property --border-angle-3 {
    syntax: "<angle>";
    inherits: true;
    initial-value: 180deg;
}

/* الألوان */
:root {
    --bright-blue: rgb(0, 100, 255);
    --bright-green: rgb(0, 255, 0);
    --bright-red: rgb(255, 0, 0);
    --background: #000;
    --foreground: #e2e8f0; /* تحديث لون النص */
    --border-size: 2px;
    --border-radius: 0.75em;
}

/* Display-P3 color, when supported. */
@supports (color: color(display-p3 1 1 1)) {
    :root {
        --bright-blue: color(display-p3 0 0.2 1);
        --bright-green: color(display-p3 0.4 1 0);
        --bright-red: color(display-p3 1 0 0);
    }
}

/* Keyframes مع زيادة السرعة 40% إضافية */
@keyframes rotateBackground {
    to { --border-angle-1: 360deg; }
}

@keyframes rotateBackground2 {
    to { --border-angle-2: -270deg; }
}

@keyframes rotateBackground3 {
    to { --border-angle-3: 540deg; }
}

/* فصل الأزرار بفراغ متساوٍ */
.vertical-buttons {
    display: flex;
    flex-direction: column;
    gap: 16px;
    align-items: center;
    width: 100%;
    padding: 6px 12px;
    box-sizing: border-box;
    position: relative;
    z-index: 6;
}

/* الزر الأساسي الجديد مع سرعة متزايدة */
.neon-button,
.btn,
.glow-btn {
    --border-angle-1: 0deg;
    --border-angle-2: 90deg;
    --border-angle-3: 180deg;

    color: inherit;
    font-size: 17px;
    font-family: inherit;
    border: 0;
    padding: var(--border-size);
    display: flex;
    width: 100%;
    max-width: 420px;
    justify-content: center;
    border-radius: var(--border-radius);
    background-color: transparent;
    background-image:
        conic-gradient(
            from var(--border-angle-1) at 10% 15%,
            transparent,
            var(--bright-blue) 10%,
            transparent 30%,
            transparent
        ),
        conic-gradient(
            from var(--border-angle-2) at 70% 60%,
            transparent,
            var(--bright-green) 10%,
            transparent 60%,
            transparent
        ),
        conic-gradient(
            from var(--border-angle-3) at 50% 20%,
            transparent,
            var(--bright-red) 10%,
            transparent 50%,
            transparent
        );

    /* زيادة السرعة 40% إضافية: 1.8s -> 1.08s, 4.8s -> 2.88s, 7.8s -> 4.68s */
    animation:
        rotateBackground 1.08s linear infinite,
        rotateBackground2 2.88s linear infinite,
        rotateBackground3 4.68s linear infinite;

    cursor: pointer;
    text-decoration: none;
    position: relative;
    z-index: 6;
}

/* المحتوى الداخلي للزر */
.neon-button div,
.btn div,
.glow-btn div {
    background: var(--background);
    padding: 14px 18px;
    border-radius: calc(var(--border-radius) - var(--border-size));
    color: var(--foreground);
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-weight: 700;
    position: relative;
}

/* تأثير hover */
.neon-button:hover,
.btn:hover,
.glow-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.3);
}

/* أيقونات داخل الأزرار */
.neon-button svg,
.btn svg,
.glow-btn svg {
    width: 22px;
    height: 22px;
}

/* ألوان النص الداخلي للزر */
.neon-button.one div { color: #ffd166; }
.neon-button.two div { color: #6ee7b7; }
.neon-button.three div { color: #9ad0ff; }
.neon-button.four div { color: #ffb3d9; }

/* شارات داخل الأزرار */
.neon-button .badge {
    position: static;
    background-color: #9b50f6;
    color: #ffeb0c;
    font-size: 12px;
    padding: 4px 8px;
    border-radius: 6px;
    margin-right: 8px;
    display: inline-block;
}

/* أيقونات التواصل */
.social-icons {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 20px;
}

.icon {
    position: relative;
    width: 57px;
    height: 57px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #0b0b0b;
    box-shadow: 0 10px 30px rgba(0,0,0,0.6);
    transition: transform 0.16s ease;
    overflow: visible;
    text-decoration: none;
}

.icon::after {
    content: "";
    position: absolute;
    inset: -6px;
    border-radius: 50%;
    background: linear-gradient(90deg, #ff004c, #ff8a00, #ffea00, #00ff9f, #00d4ff, #7a00ff);
    background-size: 300% 100%;
    filter: blur(10px) saturate(1.1) opacity(0.9);
    animation: borderShift 4.2s linear infinite;
    z-index: -1;
}

.icon svg {
    width: 28px;
    height: 28px;
    fill: #fff;
}

.icon:hover {
    transform: scale(1.08);
}

/* الأقسام والبطاقات */
section {
    padding: 28px 16px;
    background-color: rgba(40, 42, 54, 0.85);
    margin: 16px;
    border-radius: 12px;
    position: relative;
    z-index: 5;
}

/* الفوتر */
footer {
    background-color: #282a36;
    padding: 18px;
    text-align: center;
    color: #9aa0c6;
    margin-top: 20px;
    position: relative;
    z-index: 5;
}

/* Keyframes إضافية */
@keyframes borderShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

@keyframes nameGradient {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* البريد الإلكتروني */
.email {
    color: #ffd166;
    font-weight: bold;
    font-size: 18px;
    direction: ltr;
    display: inline-block;
    margin: 10px 0;
}

/* استجابة الهواتف */
@media (max-width: 420px) {
    body {
        padding-top: 70px; /* تقليل padding للهواتف */
    }
    
    .profile-img {
        width: 162px; /* تكبير 35% للهواتف: من 120px إلى 162px */
        height: 162px;
    }
    .profile-wrapper::before {
        width: 200px;
        height: 200px;
    }
    .neon-button, .btn, .glow-btn {
        font-size: 16px;
        max-width: 92%;
    }
    .neon-button div, .btn div, .glow-btn div {
        padding: 12px 14px;
    }
    section { margin: 12px; padding: 22px 12px; }
    .lightrope { padding: 0 8px; top: 14px; }
    .lightrope li { margin: 15px 0; } /* تم تعديل الهامش */
    .lightrope li span { width: 10px; height: 20px; }
    .name-glow { font-size: 36px; margin: 20px 0 6px; } /* تكبير للهواتف أيضًا */
    
    .neon-button .badge {
        font-size: 10px;
        padding: 3px 6px;
    }
}