/* Explain: Styles for gradient text, hover effects, animations, and social buttons. */
.gradient-text {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hover-card {
    transition: all 0.3s ease;
}

.hover-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
}

.tech-marquee {
    display: flex;
    overflow: hidden;
    user-select: none;
    gap: 2rem;
}

.tech-marquee-content {
    flex-shrink: 0;
    display: flex;
    justify-content: space-around;
    min-width: 100%;
    gap: 2rem;
    animation: scroll-left 25s linear infinite;
}

@keyframes scroll-left {
    from { transform: translateX(0); }
    to { transform: translateX(-100%); }
}

.social-3d-btn {
    position: relative;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 4px 0px rgba(0,0,0,0.2), 0 8px 15px rgba(0,0,0,0.2);
    border-bottom: 2px solid rgba(0,0,0,0.1);
}

.social-3d-btn:hover {
    transform: translateY(-4px) scale(1.05);
    box-shadow: 0 8px 0px rgba(0,0,0,0.2), 0 12px 20px rgba(0,0,0,0.3);
}

.social-3d-btn:active {
    transform: translateY(4px) scale(0.95);
    box-shadow: 0 0px 0px rgba(0,0,0,0.2), 0 2px 5px rgba(0,0,0,0.2);
}

@keyframes logo-float-glow {
    0%, 100% { 
        transform: translateY(0) scale(1); 
        filter: drop-shadow(0 0 0px transparent);
    }
    50% { 
        transform: translateY(-3px) scale(1.03); 
        filter: drop-shadow(0 5px 12px rgba(240, 122, 30, 0.45));
    }
}

.logo-attractive {
    animation: logo-float-glow 3.5s ease-in-out infinite;
    will-change: transform, filter;
}

/* أزرار التواصل العائمة بتأثير 3D احترافي */
.floating-contacts {
    position: fixed;
    bottom: 1.5rem;
    inset-inline-start: 1.5rem;
    z-index: 60;
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
    perspective: 600px;
}

.floating-contact {
    position: relative;
    width: 3.5rem;
    height: 3.5rem;
    border-radius: 9999px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.75rem;
    text-decoration: none;
    transform-style: preserve-3d;
    transition: transform 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.35s ease, filter 0.35s ease;
    animation: floating-bob 3.8s ease-in-out infinite;
    box-shadow:
        0 7px 0 rgba(0, 0, 0, 0.22),
        0 12px 22px rgba(0, 0, 0, 0.32),
        inset 0 2px 4px rgba(255, 255, 255, 0.55),
        inset 0 -5px 10px rgba(0, 0, 0, 0.28);
    border-top: 1px solid rgba(255, 255, 255, 0.55);
    will-change: transform;
}

.floating-contact::after {
    content: "";
    position: absolute;
    top: 7%;
    left: 18%;
    width: 50%;
    height: 34%;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0) 72%);
    pointer-events: none;
    opacity: 0.9;
}

.floating-contact:hover {
    animation: none;
    transform: translateY(-7px) scale(1.12) rotate(-4deg);
    filter: brightness(1.08);
    box-shadow:
        0 15px 0 rgba(0, 0, 0, 0.22),
        0 22px 38px rgba(0, 0, 0, 0.42),
        inset 0 2px 4px rgba(255, 255, 255, 0.6),
        inset 0 -5px 10px rgba(0, 0, 0, 0.28);
}

.floating-contact:active {
    animation: none;
    transform: translateY(4px) scale(0.94) rotate(0deg);
    box-shadow:
        0 2px 0 rgba(0, 0, 0, 0.22),
        0 5px 10px rgba(0, 0, 0, 0.3),
        inset 0 3px 8px rgba(0, 0, 0, 0.35);
}

.floating-contact--wa {
    background: radial-gradient(circle at 50% 28%, #4ee07a 0%, #25D366 55%, #128C7E 100%);
}

.floating-contact--ig {
    background: radial-gradient(circle at 50% 28%, #ffd36e 0%, #f09433 30%, #dc2743 65%, #bc1888 100%);
}

.floating-contact--tt {
    background: radial-gradient(circle at 50% 28%, #555 0%, #1a1a1a 55%, #000 100%);
}

.floating-contact--call {
    background: radial-gradient(circle at 50% 28%, #3a63b8 0%, #12275a 55%, #0b1b42 100%);
}

.floating-contact:nth-child(2) {
    animation-delay: 0.4s;
}

.floating-contact:nth-child(3) {
    animation-delay: 0.8s;
}

.floating-contact:nth-child(4) {
    animation-delay: 1.2s;
}

@keyframes floating-bob {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-7px); }
}

/* تنسيق محتوى المقالات */
.post-content {
    font-size: 1.125rem;
    line-height: 1.95;
    color: #334155;
}

.post-content h2 {
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--secondary-color);
    margin: 2.2rem 0 0.9rem;
    font-family: var(--font-heading);
    line-height: 1.4;
}

.post-content h3 {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--secondary-color);
    margin: 1.8rem 0 0.7rem;
    font-family: var(--font-heading);
}

.post-content p {
    margin-bottom: 1.1rem;
}

.post-content ul {
    list-style: disc;
    padding-inline-start: 1.6rem;
    margin-bottom: 1.1rem;
}

.post-content li {
    margin-bottom: 0.5rem;
}

.post-content a {
    color: var(--primary-color);
    font-weight: 700;
    text-decoration: underline;
}

.post-content strong {
    color: #0f172a;
    font-weight: 700;
}

/* خدماتنا — بطاقات متحركة وشكل مميز */
.service-card {
    position: relative;
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 0.7s ease, transform 0.7s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.4s ease, border-color 0.4s ease;
    will-change: transform, opacity;
}

.service-card.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.service-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(115deg, transparent 32%, rgba(255, 255, 255, 0.55) 50%, transparent 68%);
    transform: translateX(-130%);
    transition: transform 0.9s ease;
    pointer-events: none;
    z-index: 1;
}

.service-card:hover::after {
    transform: translateX(130%);
}

.service-card.is-visible:hover {
    transform: translateY(-8px);
    box-shadow: 0 26px 50px -22px rgba(18, 39, 90, 0.45);
    border-color: transparent;
}

.service-card .icon-tile {
    transition: transform 0.45s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.45s ease;
}

.service-card:hover .icon-tile {
    transform: translateY(-4px) rotate(-6deg) scale(1.08);
}

@media (prefers-reduced-motion: reduce) {
    .service-card {
        opacity: 1;
        transform: none;
        transition: none;
    }
    .service-card::after { display: none; }
    .service-card.is-visible:hover { transform: none; }
}

/* خلفية «وهج» متحركة لقسم الخدمات */
.services-glow {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
    z-index: 0;
}

.services-glow__aurora {
    position: absolute;
    inset: -20%;
    background:
        radial-gradient(60% 55% at 15% 20%, rgba(240, 122, 30, 0.38) 0%, transparent 62%),
        radial-gradient(55% 50% at 85% 25%, rgba(123, 47, 247, 0.34) 0%, transparent 62%),
        radial-gradient(60% 60% at 50% 88%, rgba(0, 169, 165, 0.32) 0%, transparent 64%),
        radial-gradient(50% 50% at 72% 62%, rgba(236, 28, 91, 0.28) 0%, transparent 62%),
        radial-gradient(48% 48% at 25% 75%, rgba(245, 166, 35, 0.30) 0%, transparent 62%);
    filter: blur(46px);
    animation: aurora-shift 22s ease-in-out infinite alternate;
    will-change: transform, opacity;
}

@keyframes aurora-shift {
    0%   { transform: translate3d(-7%, -4%, 0) scale(1.05) rotate(0deg); opacity: 0.85; }
    50%  { transform: translate3d(6%, 4%, 0) scale(1.18) rotate(4deg); opacity: 1; }
    100% { transform: translate3d(-4%, 7%, 0) scale(1.10) rotate(-4deg); opacity: 0.9; }
}

.services-glow__blob {
    position: absolute;
    border-radius: 9999px;
    filter: blur(72px);
    will-change: transform, opacity;
}

.services-glow__blob--1 {
    width: 22rem;
    height: 22rem;
    top: -6rem;
    inset-inline-start: -6rem;
    background: radial-gradient(circle, var(--accent-color) 0%, transparent 70%);
    opacity: 0.55;
    animation: glow-drift-1 14s ease-in-out infinite;
}

.services-glow__blob--2 {
    width: 26rem;
    height: 26rem;
    bottom: -8rem;
    inset-inline-end: -8rem;
    background: radial-gradient(circle, var(--primary-color) 0%, transparent 70%);
    opacity: 0.5;
    animation: glow-drift-2 18s ease-in-out infinite;
}

.services-glow__blob--3 {
    width: 18rem;
    height: 18rem;
    top: 28%;
    inset-inline-start: 40%;
    background: radial-gradient(circle, var(--accent-purple) 0%, transparent 70%);
    opacity: 0.4;
    animation: glow-drift-3 16s ease-in-out infinite;
}

.services-glow__blob--4 {
    width: 20rem;
    height: 20rem;
    top: 5%;
    inset-inline-end: 18%;
    background: radial-gradient(circle, var(--accent-lightblue) 0%, transparent 70%);
    opacity: 0.4;
    animation: glow-drift-4 20s ease-in-out infinite;
}

@keyframes glow-drift-1 {
    0%, 100% { transform: translate(0, 0) scale(1); opacity: 0.55; }
    50% { transform: translate(7rem, 4rem) scale(1.2); opacity: 0.8; }
}

@keyframes glow-drift-2 {
    0%, 100% { transform: translate(0, 0) scale(1); opacity: 0.5; }
    50% { transform: translate(-6rem, -3rem) scale(1.25); opacity: 0.75; }
}

@keyframes glow-drift-3 {
    0%, 100% { transform: translate(0, 0) scale(1); opacity: 0.35; }
    50% { transform: translate(-4rem, -5rem) scale(1.3); opacity: 0.6; }
}

@keyframes glow-drift-4 {
    0%, 100% { transform: translate(0, 0) scale(1); opacity: 0.35; }
    50% { transform: translate(4rem, 5rem) scale(1.2); opacity: 0.55; }
}

@media (prefers-reduced-motion: reduce) {
    .services-glow__blob,
    .services-glow__aurora {
        animation: none;
    }
}