/* ==========================================================================
   زفلتة - صفحة الخدمات
   ========================================================================== */

/* ==========================================================================
   شبكة الخدمات
   ========================================================================== */
.svc-section { background: var(--white); }

.svc-card {
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
    border: 1px solid var(--border);
    border-radius: 24px;
    background: var(--white);
    scroll-margin-top: 110px;
    transition:
        clip-path 1.1s var(--ease),
        transform .5s var(--ease),
        box-shadow .5s var(--ease),
        border-color .5s var(--ease);
}

/* ظهور الكارت كأنه بيتسفلت: بيتكشف من اليمين لليسار وقدامه خط ذهبي */
/* الـ reveal على العمود (مش على الكارت) عشان الـ IntersectionObserver يشوفه وهو مخفي */
.reveal.reveal-pave { opacity: 1; transform: none; }
.reveal-pave .svc-card {
    clip-path: inset(0 0 0 100% round 24px);
    transition:
        clip-path 1.1s var(--ease) var(--rd, 0ms),
        transform .5s var(--ease),
        box-shadow .5s var(--ease),
        border-color .5s var(--ease);
}
.reveal-pave.is-visible .svc-card { clip-path: inset(-40px -40px -40px -40px round 24px); }
.reveal-pave .svc-card::before {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    right: 0;
    z-index: 6;
    width: 6px;
    border-radius: 6px;
    background: linear-gradient(180deg, var(--gold-light), var(--gold));
    box-shadow: 0 0 18px rgba(220, 154, 3, .8);
    opacity: 0;
    pointer-events: none;
}
.reveal-pave.is-visible .svc-card::before { animation: pave-line 1.1s var(--ease) var(--rd, 0ms) forwards; }

.svc-card:hover,
.svc-card.in-focus {
    transform: translateY(-10px);
    border-color: transparent;
    box-shadow: var(--shadow-lg);
}

.svc-media {
    position: relative;
    height: 200px;
    border-radius: 24px 24px 0 0;
    overflow: hidden;
    clip-path: polygon(0 0, 100% 0, 100% 80%, 0 100%);
}
.svc-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .9s var(--ease);
}
.svc-media::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(8, 29, 48, .55), rgba(8, 29, 48, .05) 60%);
    transition: background .5s var(--ease);
}
.svc-card:hover .svc-media img,
.svc-card.in-focus .svc-media img { transform: scale(1.12) rotate(-1deg); }
.svc-card:hover .svc-media::after,
.svc-card.in-focus .svc-media::after { background: linear-gradient(0deg, rgba(8, 29, 48, .75), rgba(220, 154, 3, .15)); }

.svc-num {
    position: absolute;
    top: 14px;
    left: 16px;
    z-index: 2;
    color: transparent;
    font-size: 3rem;
    font-weight: 900;
    line-height: 1;
    -webkit-text-stroke: 1.5px rgba(255, 255, 255, .8);
}

.svc-icon {
    position: relative;
    z-index: 3;
    display: grid;
    place-items: center;
    width: 66px;
    height: 66px;
    margin: -44px 22px 0 auto;
    border: 5px solid var(--white);
    border-radius: 50%;
    background: var(--gold);
    color: var(--navy);
    font-size: 1.6rem;
    box-shadow: var(--shadow);
    transition: transform .6s var(--ease), background .4s var(--ease), color .4s var(--ease);
}
.svc-icon::after {
    content: "";
    position: absolute;
    inset: -10px;
    border: 2px dashed var(--gold);
    border-radius: 50%;
    opacity: 0;
    transition: opacity .4s var(--ease);
}
.svc-card:hover .svc-icon,
.svc-card.in-focus .svc-icon { background: var(--navy); color: var(--gold); transform: rotate(360deg); }
.svc-card:hover .svc-icon::after,
.svc-card.in-focus .svc-icon::after { opacity: 1; animation: spin 8s linear infinite; }

.svc-body {
    display: flex;
    flex-direction: column;
    flex: 1;
    padding: 14px 24px 26px;
}
.svc-title {
    position: relative;
    display: inline-block;
    align-self: flex-start;
    padding-bottom: 8px;
    margin-bottom: 10px;
    font-size: 1.22rem;
}
.svc-title::after {
    content: "";
    position: absolute;
    bottom: 0;
    right: 0;
    width: 34px;
    height: 3px;
    border-radius: 3px;
    background: var(--gold);
    transition: width .5s var(--ease);
}
.svc-card:hover .svc-title::after,
.svc-card.in-focus .svc-title::after { width: 100%; }
.svc-text { flex: 1; color: var(--gray); font-size: .97rem; margin-bottom: 18px; }

.svc-actions { display: flex; align-items: center; gap: 10px; }
.svc-more {
    display: inline-flex;
    flex: 1;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 18px;
    border: 0;
    border-radius: 50px;
    background: var(--navy);
    color: var(--white);
    font-family: var(--font);
    font-weight: 700;
    transition: background .35s var(--ease), color .35s var(--ease);
}
.svc-more i { transition: transform .35s var(--ease); }
.svc-more:hover { background: var(--gold); color: var(--navy); }
.svc-more:hover i { transform: translateX(-5px); }
.svc-wa {
    display: grid;
    flex-shrink: 0;
    place-items: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(37, 211, 102, .12);
    color: var(--whatsapp);
    font-size: 1.2rem;
    transition: all .35s var(--ease);
}
.svc-wa:hover { background: var(--whatsapp); color: var(--white); transform: rotate(-12deg) scale(1.08); }

.svc-road {
    position: absolute;
    right: 24px;
    left: 24px;
    bottom: 0;
    height: 4px;
    background: repeating-linear-gradient(90deg, var(--gold) 0 24px, transparent 24px 40px);
    transform: scaleX(0);
    transition: transform .6s var(--ease);
}
.svc-card:hover .svc-road,
.svc-card.in-focus .svc-road { transform: scaleX(1); animation: road-move-sm 1.6s linear infinite; }

/* ==========================================================================
   تفاصيل الخدمات (تابات)
   ========================================================================== */
.details-section {
    position: relative;
    overflow: hidden;
    background:
        radial-gradient(circle at 90% 10%, rgba(220, 154, 3, .14), transparent 35%),
        repeating-linear-gradient(135deg, rgba(255, 255, 255, .025) 0 2px, transparent 2px 46px),
        var(--navy);
}

.details-box {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 26px;
}

.details-tabs { display: flex; flex-direction: column; gap: 10px; }
.details-tab {
    position: relative;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 18px;
    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: 16px;
    background: rgba(255, 255, 255, .04);
    color: rgba(255, 255, 255, .75);
    font-family: var(--font);
    font-size: 1rem;
    font-weight: 700;
    text-align: right;
    overflow: hidden;
    transition: all .35s var(--ease);
}
.details-tab i {
    display: grid;
    flex-shrink: 0;
    place-items: center;
    width: 38px;
    height: 38px;
    border-radius: 12px;
    background: rgba(220, 154, 3, .12);
    color: var(--gold);
    font-size: 1.1rem;
    transition: all .35s var(--ease);
}
.details-tab:hover { color: var(--white); background: rgba(255, 255, 255, .07); }
.details-tab.active {
    border-color: rgba(220, 154, 3, .6);
    background: rgba(220, 154, 3, .12);
    color: var(--white);
    transform: translateX(-8px);
}
.details-tab.active i { background: var(--gold); color: var(--navy); }

/* شريط التقدم للتنقل التلقائي */
.details-progress {
    position: absolute;
    right: 0;
    bottom: 0;
    height: 3px;
    width: 0;
    background: var(--gold);
}
.details-tab.active .details-progress { animation: tab-progress 7s linear forwards; }
.details-box:hover .details-progress,
.details-box.is-paused .details-progress { animation-play-state: paused !important; }

.details-panels {
    position: relative;
    border-radius: 26px;
    background: var(--white);
    overflow: hidden;
    box-shadow: 0 30px 60px rgba(0, 0, 0, .3);
}
.details-panel {
    display: none;
    grid-template-columns: 1fr 1.1fr;
    height: 100%;
}
.details-panel.active { display: grid; animation: panel-in .6s var(--ease); }

.details-media { position: relative; min-height: 420px; overflow: hidden; }
.details-media img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.details-panel.active .details-media img { animation: img-reveal 1s var(--ease); }
.details-media::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(270deg, rgba(8, 29, 48, .1), rgba(8, 29, 48, .45));
}
.details-media-icon {
    position: absolute;
    bottom: 22px;
    left: 22px;
    z-index: 2;
    display: grid;
    place-items: center;
    width: 64px;
    height: 64px;
    border-radius: 18px;
    background: var(--gold);
    color: var(--navy);
    font-size: 1.7rem;
    box-shadow: var(--shadow);
}
.details-panel.active .details-media-icon { animation: pop-in .6s var(--ease) .4s both; }

.details-content { padding: 36px 34px; }
.details-step { color: var(--gold); font-weight: 700; font-size: .9rem; }
.details-title { font-size: 1.7rem; margin: 4px 0 12px; }
.details-text { color: var(--gray); }
.details-sub { font-size: 1.05rem; margin: 18px 0 12px; }

.details-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    padding: 0;
    margin: 0 0 26px;
    list-style: none;
}
.details-list li {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 10px 12px;
    border-radius: 12px;
    background: var(--cream);
    font-weight: 500;
    font-size: .95rem;
}
.details-list i { color: var(--gold); font-size: 1.1rem; line-height: 1.5; }
.details-panel.active .details-list li { animation: item-in .5s var(--ease) both; animation-delay: calc(.35s + var(--i) * .1s); }

.details-buttons { display: flex; flex-wrap: wrap; gap: 10px; }
.btn-outline-light-gold { border-color: var(--navy); color: var(--navy); background: transparent; }
.btn-outline-light-gold:hover { background: var(--navy); color: var(--white); }

@media (max-width: 1199.98px) {
    .details-box { grid-template-columns: 1fr; }
    .details-tabs {
        flex-direction: row;
        overflow-x: auto;
        padding-bottom: 6px;
        scrollbar-width: thin;
    }
    .details-tab { flex-shrink: 0; }
    .details-tab.active { transform: none; }
}
@media (max-width: 767.98px) {
    .details-panel { grid-template-columns: 1fr; }
    .details-media { min-height: 220px; }
    .details-content { padding: 26px 22px; }
    .details-list { grid-template-columns: 1fr; }
}

/* ==========================================================================
   لماذا تختار خدماتنا
   ========================================================================== */
.why-svc-text { color: var(--gray); font-size: 1.05rem; }
.why-svc-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px 18px;
    padding: 0;
    margin: 22px 0 0;
    list-style: none;
    font-weight: 700;
}
.why-svc-list i { color: var(--gold); margin-left: 6px; }

.why-svc-media { position: relative; padding: 30px; }
.why-svc-media img {
    width: 100%;
    aspect-ratio: 5 / 4;
    object-fit: cover;
    border-radius: 28px;
    box-shadow: var(--shadow-lg);
}
.why-svc-media::before {
    content: "";
    position: absolute;
    inset: 0 60px 60px 0;
    z-index: -1;
    border-radius: 32px;
    background: repeating-linear-gradient(45deg, var(--gold) 0 14px, var(--navy) 14px 28px);
    opacity: .9;
}
.why-float {
    position: absolute;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 18px;
    border-radius: 16px;
    background: var(--white);
    font-weight: 700;
    box-shadow: var(--shadow);
    animation: float 5s ease-in-out infinite;
}
.why-float i { color: var(--gold); font-size: 1.3rem; }
.why-float-1 { top: 60px; right: 0; }
.why-float-2 { bottom: 70px; left: 0; animation-delay: 1.5s; }
.why-float-3 {
    flex-direction: column;
    gap: 0;
    top: 0;
    left: 40px;
    background: var(--navy);
    color: var(--white);
    line-height: 1.2;
    animation-delay: .8s;
}
.why-float-3 strong { color: var(--gold); font-size: 1.8rem; direction: ltr; }

@media (max-width: 575.98px) {
    .why-svc-list { grid-template-columns: 1fr; }
    .why-svc-media { padding: 20px 10px; }
    .why-float { font-size: .85rem; padding: 8px 12px; }
}

/* ==========================================================================
   المدن (رادار)
   ========================================================================== */
.cities-section {
    position: relative;
    overflow: hidden;
    scroll-margin-top: 80px;
    background: linear-gradient(160deg, var(--navy), var(--navy-dark));
}

.city-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 0;
    margin: 0 0 20px;
    list-style: none;
}
.city-chips li {
    padding: 6px 14px;
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: 30px;
    background: rgba(255, 255, 255, .04);
    color: rgba(255, 255, 255, .85);
    font-weight: 500;
    font-size: .93rem;
    transition: all .3s var(--ease);
}
.city-chips li:hover { border-color: var(--gold); color: var(--white); }
.city-chips i { color: var(--gold); font-size: .85rem; }
.city-note { color: rgba(255, 255, 255, .65); margin: 0; }
.city-note a { color: var(--gold); font-weight: 700; }
.city-note a:hover { color: var(--white); }

.radar-map {
    position: relative;
    aspect-ratio: 225 / 175;
    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: 28px;
    background:
        repeating-radial-gradient(circle at 56% 50%, transparent 0 58px, rgba(220, 154, 3, .1) 58px 59px),
        rgba(255, 255, 255, .02);
    overflow: hidden;
}
.radar-img { position: absolute; inset: 0; width: 100%; height: 100%; }

.radar-sweep {
    position: absolute;
    top: 50%;
    left: 56%;
    width: 150%;
    aspect-ratio: 1;
    border-radius: 50%;
    background: conic-gradient(from 0deg, rgba(220, 154, 3, .32), rgba(220, 154, 3, 0) 55deg, transparent 360deg);
    transform: translate(-50%, -50%);
    animation: radar-spin 6s linear infinite;
    pointer-events: none;
}

.radar-city {
    position: absolute;
    z-index: 2;
    width: 0;
    height: 0;
    opacity: 0;
}
.radar-map.is-visible .radar-city { animation: fade-in .5s var(--ease) forwards; animation-delay: var(--d); }

.radar-dot {
    position: absolute;
    top: -6px;
    left: -6px;
    width: 12px;
    height: 12px;
    border: 2px solid var(--white);
    border-radius: 50%;
    background: var(--gold);
}
.radar-dot::after {
    content: "";
    position: absolute;
    inset: -2px;
    border-radius: 50%;
    border: 2px solid var(--gold);
    animation: blip 2s ease-out infinite;
    animation-delay: inherit;
}
.radar-label {
    position: absolute;
    top: 0;
    padding: 2px 9px;
    border-radius: 20px;
    background: rgba(8, 29, 48, .85);
    color: var(--white);
    font-size: .78rem;
    font-weight: 700;
    white-space: nowrap;
    transform: translateY(-50%);
}
.radar-city.is-left .radar-label { right: 10px; }
.radar-city.is-right .radar-label { left: 10px; }

@media (max-width: 575.98px) {
    .radar-label { font-size: .62rem; padding: 1px 6px; }
    .radar-dot { width: 9px; height: 9px; top: -4.5px; left: -4.5px; }
}

/* ==========================================================================
   المقالات
   ========================================================================== */
.articles-section { background: var(--white); }

/* ==========================================================================
   Keyframes
   ========================================================================== */
@keyframes pave-line {
    0% { right: 0; opacity: 1; }
    85% { opacity: 1; }
    100% { right: calc(100% - 6px); opacity: 0; }
}
@keyframes tab-progress {
    from { width: 0; }
    to { width: 100%; }
}
@keyframes panel-in {
    from { opacity: 0; transform: translateY(16px); }
    to { opacity: 1; transform: none; }
}
@keyframes img-reveal {
    from { clip-path: inset(0 0 0 100%); transform: scale(1.15); }
    to { clip-path: inset(0); transform: scale(1); }
}
@keyframes pop-in {
    from { opacity: 0; transform: scale(.4) rotate(-30deg); }
    to { opacity: 1; transform: none; }
}
@keyframes item-in {
    from { opacity: 0; transform: translateX(-20px); }
    to { opacity: 1; transform: none; }
}
@keyframes radar-spin {
    to { transform: translate(-50%, -50%) rotate(360deg); }
}
@keyframes blip {
    0% { transform: scale(1); opacity: 1; }
    100% { transform: scale(3.2); opacity: 0; }
}
@keyframes fade-in {
    to { opacity: 1; }
}
